EVT_SET_FOCUS(wxVListBox::OnSetOrKillFocus)
EVT_KILL_FOCUS(wxVListBox::OnSetOrKillFocus)
+
+ EVT_SIZE(wxVListBox::OnSize)
END_EVENT_TABLE()
// ============================================================================
// ============================================================================
IMPLEMENT_ABSTRACT_CLASS(wxVListBox, wxVScrolledWindow)
+const char wxVListBoxNameStr[] = "wxVListBox";
// ----------------------------------------------------------------------------
// wxVListBox creation
flags |= wxCONTROL_SELECTED;
if ( IsCurrent(n) )
flags |= wxCONTROL_CURRENT;
- if ( wxWindow::FindFocus() == wx_const_cast(wxVListBox*, this) )
+ if ( wxWindow::FindFocus() == const_cast<wxVListBox*>(this) )
flags |= wxCONTROL_FOCUSED;
wxRendererNative::Get().DrawItemSelectionRect(
- wx_const_cast(wxVListBox *, this), dc, rect, flags);
+ const_cast<wxVListBox *>(this), dc, rect, flags);
}
}
RefreshSelected();
}
+void wxVListBox::OnSize(wxSizeEvent& event)
+{
+ UpdateScrollbar();
+ event.Skip();
+}
// ============================================================================
// wxVListBox keyboard/mouse handling