Skip to content

Commit

Permalink
Fixed issue with Movable + Transformed items
Browse files Browse the repository at this point in the history
  • Loading branch information
AmonRaNet committed Jan 14, 2022
1 parent 26e13f4 commit 44fbffc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion demo/samples/flags.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,8 @@ void FlagsDemo::onInit()
{ "Custom selectable(cyan)", new Rectangle(randRect(target, size), QGV::ItemFlag::SelectCustom, Qt::cyan) },
{ "Clickable by mouse(magenta)", new Rectangle(randRect(target, size), QGV::ItemFlag::Clickable, Qt::magenta) },
{ "Custom transform(yellow)", new Rectangle(randRect(target, size), QGV::ItemFlag::Transformed, Qt::yellow) },
{ "Movable(darkCyan)", new Rectangle(randRect(target, size), QGV::ItemFlag::Movable, Qt::darkCyan) },
{ "Movable(darkCyan)",
new Rectangle(randRect(target, size), QGV::ItemFlag::Movable | QGV::ItemFlag::Transformed, Qt::darkCyan) },
};
/*
* Layers will be owned by map.
Expand Down
2 changes: 1 addition & 1 deletion demo/samples/rectangle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ void Rectangle::projOnObjectMovePos(const QPointF& projPos)
{
mProjRect.moveCenter(projPos);
mGeoRect = getMap()->getProjection()->projToGeo(mProjRect);
resetBoundary();
refresh();
qInfo() << "object moved" << mGeoRect;
}

Expand Down

0 comments on commit 44fbffc

Please sign in to comment.