mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2026-02-20 19:19:58 +01:00
Diagram image item fix : At opening of diagram, position is wrong if image was saved with is_movable to false;
git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@3483 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
@@ -198,7 +198,6 @@ bool DiagramImageItem::fromXml(const QDomElement &e) {
|
||||
if (e.tagName() != "image") return (false);
|
||||
QDomNode image_node = e.firstChild();
|
||||
if (!image_node.isText()) return (false);
|
||||
is_movable_ = (e.attribute("is_movable").toInt());
|
||||
|
||||
//load xml image to QByteArray
|
||||
QByteArray array;
|
||||
@@ -212,6 +211,7 @@ bool DiagramImageItem::fromXml(const QDomElement &e) {
|
||||
setScale(e.attribute("size").toDouble());
|
||||
applyRotation(e.attribute("rotation").toDouble());
|
||||
setPos(e.attribute("x").toDouble(), e.attribute("y").toDouble());
|
||||
is_movable_ = (e.attribute("is_movable").toInt());
|
||||
|
||||
return (true);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user