]> Shamusworld >> Repos - architektonas/blobdiff - src/actions/actionmodifydeletefree.cpp
Removed unnecessary RS_ prefix from classes and whatnot.
[architektonas] / src / actions / actionmodifydeletefree.cpp
index c37207851132fa63010a6eede442e877df872630..8a8c19690b2e03084366162507104d9c3f389352 100644 (file)
@@ -22,7 +22,7 @@
 #include "polyline.h"
 #include "undo.h"
 
-ActionModifyDeleteFree::ActionModifyDeleteFree(RS_EntityContainer & container,
+ActionModifyDeleteFree::ActionModifyDeleteFree(EntityContainer & container,
        GraphicView & graphicView):
        ActionInterface("Delete Entities Freehand", container, graphicView)
 {
@@ -45,7 +45,7 @@ void ActionModifyDeleteFree::trigger()
 {
        if (e1 && e2)
        {
-               RS_EntityContainer * parent = e2->getParent();
+               EntityContainer * parent = e2->getParent();
 
                if (parent)
                {
@@ -56,13 +56,13 @@ void ActionModifyDeleteFree::trigger()
 #warning "!!! Old rendering path need upgrade !!!"
 #if 0
                                        // deletes whole polyline on screen:
-                                       graphicView->deleteEntity((RS_Entity *)polyline);
+                                       graphicView->deleteEntity((Entity *)polyline);
 #endif
 
                                        // splits up the polyline in the container:
-                                       RS_Polyline * pl1;
-                                       RS_Polyline * pl2;
-                                       RS_Modification m(*container);
+                                       Polyline * pl1;
+                                       Polyline * pl2;
+                                       Modification m(*container);
                                        m.splitPolyline(*polyline, *e1, v1, *e2, v2, &pl1, &pl2);
 
                                        if (document)
@@ -75,25 +75,25 @@ void ActionModifyDeleteFree::trigger()
                                        }
 
                                        // draws the new polylines on the screen:
-                                       graphicView->drawEntity((RS_Entity *)pl1);
-                                       graphicView->drawEntity((RS_Entity *)pl2);
+                                       graphicView->drawEntity((Entity *)pl1);
+                                       graphicView->drawEntity((Entity *)pl2);
 
                                        init();
 
-                                       RS_DIALOGFACTORY->updateSelectionWidget(
+                                       DIALOGFACTORY->updateSelectionWidget(
                                                container->countSelected());
                                }
                                else
-                                       RS_DIALOGFACTORY->commandMessage(tr("Entities not in the same polyline."));
+                                       DIALOGFACTORY->commandMessage(tr("Entities not in the same polyline."));
                        }
                        else
-                               RS_DIALOGFACTORY->commandMessage(tr("Parent of second entity is not a polyline"));
+                               DIALOGFACTORY->commandMessage(tr("Parent of second entity is not a polyline"));
                }
                else
-                       RS_DIALOGFACTORY->commandMessage(tr("Parent of second entity is NULL"));
+                       DIALOGFACTORY->commandMessage(tr("Parent of second entity is NULL"));
        }
        else
-               RS_DIALOGFACTORY->commandMessage(tr("One of the chosen entities is NULL"));
+               DIALOGFACTORY->commandMessage(tr("One of the chosen entities is NULL"));
 }
 
 void ActionModifyDeleteFree::mouseReleaseEvent(QMouseEvent * e)
@@ -111,25 +111,25 @@ void ActionModifyDeleteFree::mouseReleaseEvent(QMouseEvent * e)
 
                        if (e1)
                        {
-                               RS_EntityContainer * parent = e1->getParent();
+                               EntityContainer * parent = e1->getParent();
 
                                if (parent)
                                {
                                        if (parent->rtti() == RS2::EntityPolyline)
                                        {
-                                               polyline = (RS_Polyline *)parent;
+                                               polyline = (Polyline *)parent;
                                                setStatus(1);
                                        }
                                        else
-                                               RS_DIALOGFACTORY->commandMessage(
+                                               DIALOGFACTORY->commandMessage(
                                                        tr("Parent of first entity is not a polyline"));
                                }
                                else
-                                       RS_DIALOGFACTORY->commandMessage(
+                                       DIALOGFACTORY->commandMessage(
                                                tr("Parent of first entity is NULL"));
                        }
                        else
-                               RS_DIALOGFACTORY->commandMessage(
+                               DIALOGFACTORY->commandMessage(
                                        tr("First entity is NULL"));
 
                        break;
@@ -142,7 +142,7 @@ void ActionModifyDeleteFree::mouseReleaseEvent(QMouseEvent * e)
                        if (e2)
                                trigger();
                        else
-                               RS_DIALOGFACTORY->commandMessage(tr("Second entity is NULL"));
+                               DIALOGFACTORY->commandMessage(tr("Second entity is NULL"));
 
                        break;
                }
@@ -154,17 +154,17 @@ void ActionModifyDeleteFree::updateMouseButtonHints()
        switch (getStatus())
        {
        case 0:
-               RS_DIALOGFACTORY->updateMouseWidget(tr("Specify first break point "
+               DIALOGFACTORY->updateMouseWidget(tr("Specify first break point "
                        "on a polyline"), tr("Cancel"));
                break;
 
        case 1:
-               RS_DIALOGFACTORY->updateMouseWidget(tr("Specify second break point "
+               DIALOGFACTORY->updateMouseWidget(tr("Specify second break point "
                        "on the same polyline"), tr("Back"));
                break;
 
        default:
-               RS_DIALOGFACTORY->updateMouseWidget("", "");
+               DIALOGFACTORY->updateMouseWidget("", "");
                break;
        }
 }