]> Shamusworld >> Repos - architektonas/blobdiff - src/actions/actionlayersedit.cpp
In the middle of major refactoring...
[architektonas] / src / actions / actionlayersedit.cpp
similarity index 56%
rename from src/actions/rs_actionlayersedit.cpp
rename to src/actions/actionlayersedit.cpp
index 85ebe069a540158703688bcb7ee5bc0c4802e524..187fb7592416ec11a35a377993b1fba6d33cf98a 100644 (file)
@@ -1,4 +1,4 @@
-// rs_actionlayersedit.cpp
+// actionlayersedit.cpp
 //
 // Part of the Architektonas Project
 // Originally part of QCad Community Edition by Andrew Mustun
 // JLH  06/04/2010  Added this text. :-)
 //
 
-#include "rs_actionlayersedit.h"
+#include "actionlayersedit.h"
 
 #include "rs_dialogfactory.h"
 #include "graphicview.h"
 #include "drawing.h"
 
-RS_ActionLayersEdit::RS_ActionLayersEdit(RS_EntityContainer & container, GraphicView & graphicView):
-       RS_ActionInterface("Edit Layer", container, graphicView)
+ActionLayersEdit::ActionLayersEdit(RS_EntityContainer & container, GraphicView & graphicView):
+       ActionInterface("Edit Layer", container, graphicView)
 {
 }
 
-RS_ActionLayersEdit::~RS_ActionLayersEdit()
+ActionLayersEdit::~ActionLayersEdit()
 {
 }
 
-void RS_ActionLayersEdit::trigger()
+void ActionLayersEdit::trigger()
 {
-       RS_DEBUG->print("RS_ActionLayersEdit::trigger");
+       RS_DEBUG->print("ActionLayersEdit::trigger");
        RS_Layer * layer = NULL;
 
-       if (graphic != NULL)
+       if (graphic)
        {
                layer = RS_DIALOGFACTORY->requestEditLayerDialog(graphic->getLayerList());
 
-               if (layer != NULL)
+               if (layer)
                {
                        graphic->editLayer(graphic->getActiveLayer(), *layer);
 
                        // update updateable entities on the layer that has changed
-                       for (RS_Entity * e = graphic->firstEntity(RS2::ResolveNone);
-                            e != NULL; e = graphic->nextEntity(RS2::ResolveNone))
+                       for(RS_Entity * e=graphic->firstEntity(RS2::ResolveNone);
+                               e!=NULL; e=graphic->nextEntity(RS2::ResolveNone))
                        {
                                RS_Layer * l = e->getLayer();
 
-                               if (l != NULL && l->getName() == layer->getName())
+                               if (l && l->getName() == layer->getName())
                                        e->update();
                        }
                }
@@ -56,10 +56,8 @@ void RS_ActionLayersEdit::trigger()
        graphicView->redraw();
 }
 
-void RS_ActionLayersEdit::init(int status)
+void ActionLayersEdit::init(int status)
 {
-       RS_ActionInterface::init(status);
+       ActionInterface::init(status);
        trigger();
 }
-
-// EOF