From 3a33b07f4e91295c65a6f766fe3840aacd77d7cc Mon Sep 17 00:00:00 2001 From: twanvl Date: Thu, 6 Jan 2011 12:51:55 +0000 Subject: [PATCH] fixed DropDownList in wx2.8: should use wxPopupWindow::Show instead of wxWindow::Show git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@1581 0fc631ac-6414-0410-93d0-97cfa31319b6 --- src/gui/drop_down_list.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gui/drop_down_list.cpp b/src/gui/drop_down_list.cpp index 6a04bed9..df1d0a4e 100644 --- a/src/gui/drop_down_list.cpp +++ b/src/gui/drop_down_list.cpp @@ -136,7 +136,7 @@ void DropDownList::show(bool in_place, wxPoint pos, RealRect* rect) { item_size.width = virtual_size.width - marginW * 2; // is there enough room for all items, or do we need a scrollbar? int room_below = wxGetDisplaySize().y - border_size.height - pos.y - parent_height - 50; - int max_height = max(200, room_below); + int max_height = max(300, room_below); if (size.height > max_height) { size.height = max_height; size.width += wxSystemSettings::GetMetric(wxSYS_VSCROLL_ARROW_X); // width of scrollbar @@ -160,7 +160,7 @@ void DropDownList::show(bool in_place, wxPoint pos, RealRect* rect) { if (selected_item == NO_SELECTION && itemCount() > 0) selected_item = 0; // select first item by default mouse_down = false; close_on_mouse_out = false; - Window::Show(); + wxPopupWindow::Show(); if (isRoot() && GetParent()->HasCapture()) { // release capture on parent GetParent()->ReleaseMouse();