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.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/gui/widgets/popuplist.cpp b/src/gui/widgets/popuplist.cpp
index 17f026388..d5adb1dcf 100644
--- a/src/gui/widgets/popuplist.cpp
+++ b/src/gui/widgets/popuplist.cpp
@@ -22,6 +22,7 @@
#include "gui/gui.h"
+#include "gui/widgets/createwidget.h"
#include "gui/widgets/dropdown.h"
#include "gui/widgets/extendedlistbox.h"
#include "gui/widgets/scrollarea.h"
@@ -35,15 +36,15 @@ PopupList::PopupList(DropDown *const widget,
Popup("PopupList", "popuplist.xml"),
FocusListener(),
mListModel(listModel),
- mListBox(extended ? new ExtendedListBox(
+ mListBox(extended ? CREATEWIDGETR(ExtendedListBox,
widget, listModel, "extendedlistbox.xml", 0) :
- new ListBox(widget, listModel, "popuplistbox.xml")),
+ CREATEWIDGETR(ListBox,
+ widget, listModel, "popuplistbox.xml")),
mScrollArea(new ScrollArea(this, mListBox, false)),
mDropDown(widget),
mPressedIndex(-2),
mModal(modal)
{
- mListBox->postInit();
mListBox->setMouseConsume(false);
mScrollArea->setMouseConsume(false);
mAllowLogic = false;