]> Shamusworld >> Repos - architektonas/blobdiff - src/actions/actionmodifytrimamount.cpp
In the middle of major refactoring...
[architektonas] / src / actions / actionmodifytrimamount.cpp
similarity index 70%
rename from src/actions/rs_actionmodifytrimamount.cpp
rename to src/actions/actionmodifytrimamount.cpp
index 94a3ad8aca6d3f8869b8d64828f9d4cd3b7939c0..41a25dfb3dd8e8dd12a26b1f743f5839c4f0470c 100644 (file)
@@ -1,4 +1,4 @@
-// rs_actionmodifytrimamount.cpp
+// actionmodifytrimamount.cpp
 //
 // Part of the Architektonas Project
 // Originally part of QCad Community Edition by Andrew Mustun
 // JLH  06/04/2010  Added this text. :-)
 //
 
-#include "rs_actionmodifytrimamount.h"
+#include "actionmodifytrimamount.h"
 
 #include "rs_commandevent.h"
 #include "rs_dialogfactory.h"
 #include "rs_modification.h"
 
-RS_ActionModifyTrimAmount::RS_ActionModifyTrimAmount(
+ActionModifyTrimAmount::ActionModifyTrimAmount(
        RS_EntityContainer & container, GraphicView & graphicView):
-       RS_ActionInterface("Trim Entity by a given amount",
+       ActionInterface("Trim Entity by a given amount",
                container, graphicView)
 {
        trimEntity = NULL;
@@ -28,26 +28,26 @@ RS_ActionModifyTrimAmount::RS_ActionModifyTrimAmount(
        distance = 0.0;
 }
 
-RS_ActionModifyTrimAmount::~RS_ActionModifyTrimAmount()
+ActionModifyTrimAmount::~ActionModifyTrimAmount()
 {
 }
 
-/*virtual*/ RS2::ActionType RS_ActionModifyTrimAmount::rtti()
+/*virtual*/ RS2::ActionType ActionModifyTrimAmount::rtti()
 {
        return RS2::ActionModifyTrimAmount;
 }
 
-void RS_ActionModifyTrimAmount::init(int status)
+void ActionModifyTrimAmount::init(int status)
 {
-       RS_ActionInterface::init(status);
+       ActionInterface::init(status);
 
-       snapMode = RS2::SnapFree;
-       snapRes = RS2::RestrictNothing;
+/*     snapMode = RS2::SnapFree;
+       snapRes = RS2::RestrictNothing;*/
 }
 
-void RS_ActionModifyTrimAmount::trigger()
+void ActionModifyTrimAmount::trigger()
 {
-       RS_DEBUG->print("RS_ActionModifyTrimAmount::trigger()");
+       RS_DEBUG->print("ActionModifyTrimAmount::trigger()");
 
        if (trimEntity != NULL && trimEntity->isAtomic())
        {
@@ -61,7 +61,7 @@ void RS_ActionModifyTrimAmount::trigger()
        }
 }
 
-void RS_ActionModifyTrimAmount::mouseReleaseEvent(QMouseEvent * e)
+void ActionModifyTrimAmount::mouseReleaseEvent(QMouseEvent * e)
 {
        trimCoord = graphicView->toGraph(e->x(), e->y());
        trimEntity = catchEntity(e);
@@ -101,7 +101,7 @@ void RS_ActionModifyTrimAmount::mouseReleaseEvent(QMouseEvent * e)
        }
 }
 
-void RS_ActionModifyTrimAmount::commandEvent(RS_CommandEvent * e)
+void ActionModifyTrimAmount::commandEvent(RS_CommandEvent * e)
 {
        QString c = e->getCommand().toLower();
 
@@ -132,7 +132,7 @@ void RS_ActionModifyTrimAmount::commandEvent(RS_CommandEvent * e)
        }
 }
 
-QStringList RS_ActionModifyTrimAmount::getAvailableCommands()
+QStringList ActionModifyTrimAmount::getAvailableCommands()
 {
        QStringList cmd;
 
@@ -148,28 +148,27 @@ QStringList RS_ActionModifyTrimAmount::getAvailableCommands()
        return cmd;
 }
 
-void RS_ActionModifyTrimAmount::showOptions()
+void ActionModifyTrimAmount::showOptions()
 {
-       RS_ActionInterface::showOptions();
+       ActionInterface::showOptions();
 
        RS_DIALOGFACTORY->requestOptions(this, true);
 }
 
-void RS_ActionModifyTrimAmount::hideOptions()
+void ActionModifyTrimAmount::hideOptions()
 {
-       RS_ActionInterface::hideOptions();
+       ActionInterface::hideOptions();
 
        RS_DIALOGFACTORY->requestOptions(this, false);
 }
 
-void RS_ActionModifyTrimAmount::updateMouseButtonHints()
+void ActionModifyTrimAmount::updateMouseButtonHints()
 {
        switch (getStatus())
        {
        case ChooseTrimEntity:
                RS_DIALOGFACTORY->updateMouseWidget(
-                       tr("Select entity to trim or enter distance:"),
-                       tr("Back"));
+                       tr("Select entity to trim or enter distance:"), tr("Back"));
                break;
 
        default:
@@ -178,22 +177,22 @@ void RS_ActionModifyTrimAmount::updateMouseButtonHints()
        }
 }
 
-void RS_ActionModifyTrimAmount::updateMouseCursor()
+void ActionModifyTrimAmount::updateMouseCursor()
 {
        graphicView->setMouseCursor(RS2::CadCursor);
 }
 
-void RS_ActionModifyTrimAmount::updateToolBar()
+void ActionModifyTrimAmount::updateToolBar()
 {
        RS_DIALOGFACTORY->requestToolBar(RS2::ToolBarModify);
 }
 
-double RS_ActionModifyTrimAmount::getDistance()
+double ActionModifyTrimAmount::getDistance()
 {
        return distance;
 }
 
-void RS_ActionModifyTrimAmount::setDistance(double d)
+void ActionModifyTrimAmount::setDistance(double d)
 {
        distance = d;
 }