scrolling fix
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@49301 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -2265,7 +2265,15 @@ void * wxMacDataItemBrowserControl::MacGetClientData( unsigned int n) const
|
||||
|
||||
void wxMacDataItemBrowserControl::MacScrollTo( unsigned int n )
|
||||
{
|
||||
RevealItem( GetItemFromLine( n) , kDataBrowserRevealWithoutSelecting );
|
||||
UInt32 top , left ;
|
||||
GetScrollPosition( &top , &left ) ;
|
||||
wxMacDataItem * item = (wxMacDataItem*) GetItemFromLine( n );
|
||||
|
||||
UInt16 height ;
|
||||
GetRowHeight( (DataBrowserItemID) item , &height ) ;
|
||||
SetScrollPosition( n * ((UInt32)height) , left ) ;
|
||||
|
||||
RevealItem( item , kDataBrowserRevealWithoutSelecting );
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user