Implement wxListBox::EnsureVisible() for wxMSW.

Manually check whether the item is currently visible and scroll the listbox
just enough if it isn't.

Closes #3224.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77653 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2014-09-10 16:51:17 +00:00
parent ed1e48b1ed
commit 9a377ec117
4 changed files with 37 additions and 6 deletions

View File

@@ -285,12 +285,8 @@ public:
/**
Ensure that the item with the given index is currently shown.
Scroll the listbox if necessary.
This method is currently only implemented in wxGTK and wxOSX and does
nothing in other ports.
@see SetFirstItem()
This method scrolls the listbox only if necessary and doesn't do
anything if this item is already shown, unlike SetFirstItem().
*/
virtual void EnsureVisible(int n);