diff --git a/src/cocoa/listbox.mm b/src/cocoa/listbox.mm index b1124035ab..94c42c40d8 100644 --- a/src/cocoa/listbox.mm +++ b/src/cocoa/listbox.mm @@ -23,12 +23,14 @@ #include "wx/cocoa/string.h" #include "wx/cocoa/autorelease.h" #include "wx/cocoa/ObjcRef.h" +#include "wx/cocoa/private/scrollview.h" #include "wx/cocoa/NSTableDataSource.h" #import #import #import #import +#import IMPLEMENT_DYNAMIC_CLASS(wxListBox, wxControl) BEGIN_EVENT_TABLE(wxListBox, wxListBoxBase) @@ -116,6 +118,9 @@ The listbox contents are sorted in alphabetical order. CocoaCreateNSScrollView(); SetInitialFrameRect(pos,size); + // Force showing of a vertical scrollbar + [m_wxCocoaScrollView->GetNSScrollView() setHasVerticalScroller:YES]; + // Set up extended/multiple selection flags if ((style & wxLB_EXTENDED) || (style & wxLB_MULTIPLE)) //diff is that mult requires shift down for multi selection