3 // Part of the Architektonas Project
4 // Originally part of QCad Community Edition by Andrew Mustun
5 // Extensively rewritten and refactored by James L. Hammons
6 // (C) 2010 Underground Software
8 // JLH = James L. Hammons <jlhamm@acm.org>
11 // --- ---------- -----------------------------------------------------------
12 // JLH 06/04/2010 Added this text. :-)
15 #include "actionlayersadd.h"
17 #include "rs_dialogfactory.h"
20 ActionLayersAdd::ActionLayersAdd(RS_EntityContainer & container, GraphicView & graphicView):
21 ActionInterface("Add Layer", container, graphicView)
25 ActionLayersAdd::~ActionLayersAdd()
29 void ActionLayersAdd::trigger()
31 RS_DEBUG->print("add layer");
33 if (RS_DIALOGFACTORY != NULL && graphic)
35 RS_Layer * layer = RS_DIALOGFACTORY->requestNewLayerDialog(graphic->getLayerList());
38 graphic->addLayer(layer);
44 void ActionLayersAdd::init(int status)
46 ActionInterface::init(status);