Fixed unexpected scaling of items at tool "unpin" operation.

preferencesAboutTextFull
Aleksei Kanash 12 years ago
parent bce6799593
commit b1c00c052a
  1. 2
      src/board/UBBoardController.cpp

@ -2333,6 +2333,8 @@ void UBBoardController::moveToolWidgetToScene(UBToolWidget* toolWidget)
{ {
UBGraphicsWidgetItem *widgetToScene = toolWidget->toolWidget(); UBGraphicsWidgetItem *widgetToScene = toolWidget->toolWidget();
widgetToScene->resetTransform();
QPoint mainWindowCenter = toolWidget->mapTo(mMainWindow, QPoint(toolWidget->width(), toolWidget->height()) / 2); QPoint mainWindowCenter = toolWidget->mapTo(mMainWindow, QPoint(toolWidget->width(), toolWidget->height()) / 2);
QPoint controlViewCenter = mControlView->mapFrom(mMainWindow, mainWindowCenter); QPoint controlViewCenter = mControlView->mapFrom(mMainWindow, mainWindowCenter);
QPointF scenePos = mControlView->mapToScene(controlViewCenter); QPointF scenePos = mControlView->mapToScene(controlViewCenter);

Loading…
Cancel
Save