mirror of
https://github.com/dashr9230/SA-MP.git
synced 2026-10-10 11:43:04 +08:00
[saco] Implement/match CDXUTListBox::InsertItem
This commit is contained in:
@@ -4288,7 +4288,7 @@ HRESULT CDXUTListBox::AddItem( const TCHAR *wszText, void *pData, D3DCOLOR TextC
|
||||
|
||||
|
||||
//--------------------------------------------------------------------------------------
|
||||
HRESULT CDXUTListBox::InsertItem( int nIndex, const TCHAR *wszText, void *pData )
|
||||
HRESULT CDXUTListBox::InsertItem( int nIndex, const TCHAR *wszText, void *pData, D3DCOLOR TextColor )
|
||||
{
|
||||
DXUTListBoxItem *pNewItem = new DXUTListBoxItem;
|
||||
if( !pNewItem )
|
||||
@@ -4298,6 +4298,7 @@ HRESULT CDXUTListBox::InsertItem( int nIndex, const TCHAR *wszText, void *pData
|
||||
pNewItem->pData = pData;
|
||||
SetRect( &pNewItem->rcActive, 0, 0, 0, 0 );
|
||||
pNewItem->bSelected = false;
|
||||
pNewItem->TextColor = TextColor;
|
||||
|
||||
HRESULT hr = m_Items.Insert( nIndex, pNewItem );
|
||||
if( SUCCEEDED( hr ) )
|
||||
|
||||
@@ -625,7 +625,7 @@ public:
|
||||
void SetScrollBarWidth( int nWidth ) { m_nSBWidth = nWidth; UpdateRects(); }
|
||||
void SetBorder( int nBorder, int nMargin ) { m_nBorder = nBorder; m_nMargin = nMargin; }
|
||||
HRESULT AddItem( const TCHAR *wszText, void *pData, D3DCOLOR TextColor );
|
||||
HRESULT InsertItem( int nIndex, const TCHAR *wszText, void *pData );
|
||||
HRESULT InsertItem( int nIndex, const TCHAR *wszText, void *pData, D3DCOLOR TextColor );
|
||||
void RemoveItem( int nIndex );
|
||||
void RemoveItemByText( TCHAR *wszText );
|
||||
void RemoveItemByData( void *pData );
|
||||
|
||||
Reference in New Issue
Block a user