summaryrefslogtreecommitdiff
path: root/src/gui/setup_input.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/setup_input.cpp
parent57726c7324f165c70671fc5b05d6c0964f56b870 (diff)
downloadplus-3db999ff2d3324ffad6ba6a469ca224c8d864dc3.tar.gz
plus-3db999ff2d3324ffad6ba6a469ca224c8d864dc3.tar.bz2
plus-3db999ff2d3324ffad6ba6a469ca224c8d864dc3.tar.xz
plus-3db999ff2d3324ffad6ba6a469ca224c8d864dc3.zip
add some more missing checks.
Diffstat (limited to 'src/gui/setup_input.cpp')
-rw-r--r--src/gui/setup_input.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/gui/setup_input.cpp b/src/gui/setup_input.cpp
index fa77996dd..d4d86ce61 100644
--- a/src/gui/setup_input.cpp
+++ b/src/gui/setup_input.cpp
@@ -125,10 +125,9 @@ Setup_Input::Setup_Input(const Widget2 *const widget) :
refreshKeys();
mKeyList->addActionListener(this);
- ScrollArea *const scrollArea = new ScrollArea(mKeyList,
+ mScrollArea = new ScrollArea(mKeyList,
true, "setup_input_background.xml");
- scrollArea->setHorizontalScrollPolicy(ScrollArea::SHOW_NEVER);
-
+ mScrollArea->setHorizontalScrollPolicy(ScrollArea::SHOW_NEVER);
mAssignKeyButton->addActionListener(this);
mAssignKeyButton->setEnabled(false);
mUnassignKeyButton->addActionListener(this);
@@ -152,7 +151,7 @@ Setup_Input::Setup_Input(const Widget2 *const widget) :
ContainerPlacer place = h.getPlacer(0, 0);
place(0, 0, mTabs, 5);
- place(0, 1, scrollArea, 5, 5).setPadding(2);
+ place(0, 1, mScrollArea, 5, 5).setPadding(2);
place(0, 6, mResetKeysButton);
place(2, 6, mAssignKeyButton);
place(3, 6, mUnassignKeyButton);
@@ -180,6 +179,8 @@ Setup_Input::~Setup_Input()
mResetKeysButton = nullptr;
delete [] mActionDataSize;
mActionDataSize = nullptr;
+ delete mScrollArea;
+ mScrollArea = nullptr;
}
void Setup_Input::apply()