summaryrefslogtreecommitdiff
path: root/src/gui/widgets/popuplist.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/widgets/popuplist.cpp')
-rw-r--r--src/gui/widgets/popuplist.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/gui/widgets/popuplist.cpp b/src/gui/widgets/popuplist.cpp
index 211de45e5..260dcb6a9 100644
--- a/src/gui/widgets/popuplist.cpp
+++ b/src/gui/widgets/popuplist.cpp
@@ -45,8 +45,8 @@ PopupList::PopupList(DropDown *const widget,
mScrollArea->setPosition(mPadding, mPadding);
add(mScrollArea);
- if (getParent())
- getParent()->addFocusListener(this);
+// if (getParent())
+// getParent()->addFocusListener(this);
if (gui)
gui->addGlobalFocusListener(this);
@@ -57,6 +57,8 @@ PopupList::PopupList(DropDown *const widget,
PopupList::~PopupList()
{
+ if (getParent())
+ getParent()->removeFocusListener(this);
if (gui)
gui->removeGlobalFocusListener(this);
removeKeyListener(mDropDown);