diff options
author | Arno <arno@disconnect.de> | 2016-11-27 06:52:50 +0100 |
---|---|---|
committer | Arno <arno@disconnect.de> | 2016-11-27 06:52:50 +0100 |
commit | 9c89e2f83415c876f28f15ebff31c8325754a936 (patch) | |
tree | 81262fcd178af3071187cf89b415fc70cdb8d977 /globals.cpp | |
parent | d1cf6c418855004a249d44fd383c889cbd1e7662 (diff) | |
download | ShemovCleaner-9c89e2f83415c876f28f15ebff31c8325754a936.tar.gz ShemovCleaner-9c89e2f83415c876f28f15ebff31c8325754a936.tar.bz2 ShemovCleaner-9c89e2f83415c876f28f15ebff31c8325754a936.zip |
Add picture viewer
Opens on doubleclick when it's image/*.
Diffstat (limited to 'globals.cpp')
-rw-r--r-- | globals.cpp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/globals.cpp b/globals.cpp index 2bdb175..53bd1f0 100644 --- a/globals.cpp +++ b/globals.cpp @@ -1,6 +1,7 @@ #include <QAction> #include "globals.h" +#include "viewer.h" Globals *Globals::mInstance = nullptr; @@ -19,4 +20,11 @@ QAction *Globals::action(int actionType){ return mActions.value(actionType); } -Globals::Globals(){} +Viewer *Globals::viewer(){ + if(!mViewer){ + mViewer = new Viewer; + } + return mViewer; +} + +Globals::Globals() : mViewer(nullptr) {} |