summaryrefslogtreecommitdiffstats
path: root/src/ui
diff options
context:
space:
mode:
authorTomasz Boczkowski <penginsbacon@gmail.com>2015-05-11 22:31:26 +0000
committerTomasz Boczkowski <penginsbacon@gmail.com>2015-05-11 22:31:26 +0000
commit4e55fa746207d1f03334a8636cc8488af15a7f5e (patch)
tree8e2ec06145b1a2c4750b1599342b472382c32b36 /src/ui
parentfixed color selector not remembering it's last open tab (diff)
parentpatch by tbnorth for Bug 1277649 (diff)
downloadinkscape-4e55fa746207d1f03334a8636cc8488af15a7f5e.tar.gz
inkscape-4e55fa746207d1f03334a8636cc8488af15a7f5e.zip
merged trunk
(bzr r14059.1.26)
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/dialog/layers.cpp12
-rw-r--r--src/ui/dialog/object-properties.cpp6
2 files changed, 14 insertions, 4 deletions
diff --git a/src/ui/dialog/layers.cpp b/src/ui/dialog/layers.cpp
index 65351cb68..c6888386f 100644
--- a/src/ui/dialog/layers.cpp
+++ b/src/ui/dialog/layers.cpp
@@ -713,13 +713,21 @@ bool LayersPanel::_handleDragDrop(const Glib::RefPtr<Gdk::DragContext>& /*contex
*/
void LayersPanel::_doTreeMove( )
{
- if (_dnd_source ) {
+ if (_dnd_source && _dnd_source->getRepr() ) {
+ if(!_dnd_target){
+ _dnd_source->doWriteTransform(_dnd_source->getRepr(), _dnd_source->document->getRoot()->i2doc_affine().inverse() * _dnd_source->i2doc_affine());
+ }else{
+ SPItem* parent = _dnd_into ? _dnd_target : dynamic_cast<SPItem*>(_dnd_target->parent);
+ if(parent){
+ Geom::Affine move = parent->i2doc_affine().inverse() * _dnd_source->i2doc_affine();
+ _dnd_source->doWriteTransform(_dnd_source->getRepr(), move);
+ }
+ }
_dnd_source->moveTo(_dnd_target, _dnd_into);
_selectLayer(_dnd_source);
_dnd_source = NULL;
DocumentUndo::done( _desktop->doc() , SP_VERB_NONE,
_("Moved layer"));
-
}
}
diff --git a/src/ui/dialog/object-properties.cpp b/src/ui/dialog/object-properties.cpp
index fc21a30d4..75430ed44 100644
--- a/src/ui/dialog/object-properties.cpp
+++ b/src/ui/dialog/object-properties.cpp
@@ -529,10 +529,12 @@ void ObjectProperties::_imageRenderingChanged()
SPCSSAttr *css = sp_repr_css_attr_new();
sp_repr_css_set_property(css, "image-rendering", scale.c_str());
Inkscape::XML::Node *image_node = item->getRepr();
- if( image_node ) {
+ if (image_node) {
sp_repr_css_change(image_node, css, "style");
+ DocumentUndo::done(SP_ACTIVE_DOCUMENT, SP_VERB_DIALOG_ITEM,
+ _("Set image rendering option"));
}
- sp_repr_css_attr_unref( css );
+ sp_repr_css_attr_unref(css);
_blocked = false;
}