Slightly better wxStockCursor usage

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@55875 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Jaakko Salli 2008-09-25 16:31:01 +00:00
parent e58eaff761
commit 2399c87cce

View File

@ -1470,13 +1470,14 @@ void wxCursorProperty::OnCustomPaint( wxDC& dc,
if ( paintdata.m_choiceItem < NUM_CURSORS )
{
int cursorindex = gs_cp_es_syscursors_values[paintdata.m_choiceItem];
wxStockCursor cursorIndex =
(wxStockCursor) gs_cp_es_syscursors_values[paintdata.m_choiceItem];
{
if ( cursorindex == wxCURSOR_NONE )
cursorindex = wxCURSOR_ARROW;
if ( cursorIndex == wxCURSOR_NONE )
cursorIndex = wxCURSOR_ARROW;
wxCursor cursor( (wxStockCursor)cursorindex );
wxCursor cursor( cursorIndex );
#ifdef __WXMSW__
HDC hDc = (HDC)((const wxMSWDCImpl *)dc.GetImpl())->GetHDC();