summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 3f18a09)
raw | patch | inline | side by side (parent: 3f18a09)
author | joncruz <joncruz@users.sourceforge.net> | |
Sat, 10 May 2008 19:38:34 +0000 (19:38 +0000) | ||
committer | joncruz <joncruz@users.sourceforge.net> | |
Sat, 10 May 2008 19:38:34 +0000 (19:38 +0000) |
Fixes Bug #227253.
src/dialogs/object-attributes.cpp | patch | blob | history |
index 475e8dce6300c7e7588fdd82170b6c1569dba342..e0c891ea1ad22c4aedf4f30eec1d88f610fc1238 100644 (file)
#include "macros.h"
#include "sp-anchor.h"
#include "sp-attribute-widget.h"
+#include "../xml/repr.h"
#include <sigc++/connection.h>
#include <sigc++/functors/ptr_fun.h>
{ NULL, NULL}
};
+static const SPAttrDesc image_nohref_desc[] = {
+ { N_("X:"), "x"},
+ { N_("Y:"), "y"},
+ { N_("Width:"), "width"},
+ { N_("Height:"), "height"},
+ { NULL, NULL}
+};
+
static void
object_released( SPObject */*object*/, GtkWidget *widget )
if (!strcmp (tag, "Link")) {
sp_object_attr_show_dialog (object, anchor_desc, tag);
} else if (!strcmp (tag, "Image")) {
- sp_object_attr_show_dialog (object, image_desc, tag);
+ Inkscape::XML::Node *ir = SP_OBJECT_REPR(object);
+ const gchar *href = ir->attribute("xlink:href");
+ if ( (!href) || ((strncmp(href, "data:", 5) == 0)) ) {
+ sp_object_attr_show_dialog (object, image_nohref_desc, tag);
+ } else {
+ sp_object_attr_show_dialog (object, image_desc, tag);
+ }
}
} // end of sp_object_attributes_dialog()