summaryrefslogtreecommitdiff
path: root/src/gui/shortcutwindow.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2013-08-28 22:45:19 +0300
committerAndrei Karas <akaras@inbox.ru>2013-08-29 00:18:57 +0300
commit3db999ff2d3324ffad6ba6a469ca224c8d864dc3 (patch)
tree78ecfd05c1267f7360e42876072ddb21efa1a096 /src/gui/shortcutwindow.cpp
parent57726c7324f165c70671fc5b05d6c0964f56b870 (diff)
downloadmanaverse-3db999ff2d3324ffad6ba6a469ca224c8d864dc3.tar.gz
manaverse-3db999ff2d3324ffad6ba6a469ca224c8d864dc3.tar.bz2
manaverse-3db999ff2d3324ffad6ba6a469ca224c8d864dc3.tar.xz
manaverse-3db999ff2d3324ffad6ba6a469ca224c8d864dc3.zip
add some more missing checks.
Diffstat (limited to 'src/gui/shortcutwindow.cpp')
-rw-r--r--src/gui/shortcutwindow.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/gui/shortcutwindow.cpp b/src/gui/shortcutwindow.cpp
index 87b43e758..8bd64c9ff 100644
--- a/src/gui/shortcutwindow.cpp
+++ b/src/gui/shortcutwindow.cpp
@@ -74,7 +74,8 @@ ShortcutWindow::ShortcutWindow(const std::string &title,
mDragOffsetY = 0;
content->setWidget2(this);
- setupWindow->registerWindowForReset(this);
+ if (setupWindow)
+ setupWindow->registerWindowForReset(this);
const int border = SCROLL_PADDING * 2 + getPadding() * 2;
setMinWidth(mItems->getBoxWidth() + border);
@@ -123,7 +124,8 @@ ShortcutWindow::ShortcutWindow(const std::string &title,
mDragOffsetX = 0;
mDragOffsetY = 0;
- setupWindow->registerWindowForReset(this);
+ if (setupWindow)
+ setupWindow->registerWindowForReset(this);
const int border = SCROLL_PADDING * 2 + getPadding() * 2;