]> Shamusworld >> Repos - architektonas/blob - src/actions/rs_actionfilesave.cpp
Major refactoring of actions: Moved implementation from header files
[architektonas] / src / actions / rs_actionfilesave.cpp
1 // rs_actionfilesave.cpp
2 //
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
7 //
8 // JLH = James L. Hammons <jlhamm@acm.org>
9 //
10 // Who  When        What
11 // ---  ----------  -----------------------------------------------------------
12 // JLH  06/04/2010  Added this text. :-)
13 //
14
15 #include "rs_actionfilesave.h"
16
17 #include "drawing.h"
18
19 RS_ActionFileSave::RS_ActionFileSave(RS_EntityContainer & container, RS_GraphicView & graphicView):
20         RS_ActionInterface("File Save", container, graphicView)
21 {
22 }
23
24 RS_ActionFileSave::~RS_ActionFileSave()
25 {
26 }
27
28 void RS_ActionFileSave::trigger()
29 {
30         RS_DEBUG->print("RS_ActionFileSave::trigger");
31
32         if (graphic != NULL)
33                 graphic->save();
34
35         finish();
36 }
37
38 void RS_ActionFileSave::init(int status)
39 {
40         RS_ActionInterface::init(status);
41         trigger();
42 }
43