X-Git-Url: http://shamusworld.gotdns.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Factions%2Factionmodifymove.cpp;h=9801c799106910bf32e1f379a3bf2058cecccbc0;hb=f62cebc26c7c3af447f0e4e4c43331f8589dce22;hp=b0df30477e2b8287b55aa65765e3b246022bb4a9;hpb=d774c2655ba2c3657a565f325411144452392277;p=architektonas diff --git a/src/actions/actionmodifymove.cpp b/src/actions/actionmodifymove.cpp index b0df304..9801c79 100644 --- a/src/actions/actionmodifymove.cpp +++ b/src/actions/actionmodifymove.cpp @@ -3,7 +3,9 @@ // Part of the Architektonas Project // Originally part of QCad Community Edition by Andrew Mustun // Extensively rewritten and refactored by James L. Hammons -// (C) 2010 Underground Software +// Portions copyright (C) 2001-2003 RibbonSoft +// Copyright (C) 2010 Underground Software +// See the README and GPLv2 files for licensing and warranty information // // JLH = James L. Hammons // @@ -14,10 +16,11 @@ #include "actionmodifymove.h" -#include "rs_dialogfactory.h" -#include "rs_preview.h" +#include "debug.h" +#include "dialogfactory.h" +#include "preview.h" -ActionModifyMove::ActionModifyMove(RS_EntityContainer & container, +ActionModifyMove::ActionModifyMove(EntityContainer & container, GraphicView & graphicView): ActionInterface("Move Entities", container, graphicView) { @@ -34,17 +37,17 @@ void ActionModifyMove::init(int status) void ActionModifyMove::trigger() { - RS_DEBUG->print("ActionModifyMove::trigger()"); + DEBUG->print("ActionModifyMove::trigger()"); - RS_Modification m(*container, graphicView); + Modification m(*container, graphicView); m.move(data); - RS_DIALOGFACTORY->updateSelectionWidget(container->countSelected()); + DIALOGFACTORY->updateSelectionWidget(container->countSelected()); } void ActionModifyMove::mouseMoveEvent(QMouseEvent * e) { - RS_DEBUG->print("ActionModifyMove::mouseMoveEvent begin"); + DEBUG->print("ActionModifyMove::mouseMoveEvent begin"); if (getStatus() == SetReferencePoint || getStatus() == SetTargetPoint) @@ -76,7 +79,7 @@ void ActionModifyMove::mouseMoveEvent(QMouseEvent * e) } } - RS_DEBUG->print("ActionModifyMove::mouseMoveEvent end"); + DEBUG->print("ActionModifyMove::mouseMoveEvent end"); } void ActionModifyMove::mouseReleaseEvent(QMouseEvent * e) @@ -114,7 +117,7 @@ void ActionModifyMove::coordinateEvent(Vector * e) graphicView->moveRelativeZero(targetPoint); setStatus(ShowDialog); - if (RS_DIALOGFACTORY->requestMoveDialog(data)) + if (DIALOGFACTORY->requestMoveDialog(data)) { data.offset = targetPoint - referencePoint; trigger(); @@ -132,21 +135,21 @@ void ActionModifyMove::updateMouseButtonHints() switch (getStatus()) { /*case Select: - RS_DIALOGFACTORY->updateMouseWidget(tr("Pick entities to move"), + DIALOGFACTORY->updateMouseWidget(tr("Pick entities to move"), tr("Cancel")); break;*/ case SetReferencePoint: - RS_DIALOGFACTORY->updateMouseWidget(tr("Specify reference point"), + DIALOGFACTORY->updateMouseWidget(tr("Specify reference point"), tr("Cancel")); break; case SetTargetPoint: - RS_DIALOGFACTORY->updateMouseWidget(tr("Specify target point"), + DIALOGFACTORY->updateMouseWidget(tr("Specify target point"), tr("Back")); break; default: - RS_DIALOGFACTORY->updateMouseWidget("", ""); + DIALOGFACTORY->updateMouseWidget("", ""); break; } } @@ -161,15 +164,15 @@ void ActionModifyMove::updateToolBar() switch (getStatus()) { /*case Select: - RS_DIALOGFACTORY->requestToolBar(RS2::ToolBarSelect); + DIALOGFACTORY->requestToolBar(RS2::ToolBarSelect); break;*/ case SetReferencePoint: case SetTargetPoint: - RS_DIALOGFACTORY->requestToolBar(RS2::ToolBarSnap); + DIALOGFACTORY->requestToolBar(RS2::ToolBarSnap); break; default: - RS_DIALOGFACTORY->requestToolBar(RS2::ToolBarModify); + DIALOGFACTORY->requestToolBar(RS2::ToolBarModify); break; } }