mirror of
https://github.com/wxWidgets/Phoenix.git
synced 2026-01-04 19:10:09 +01:00
Missing required explicit float->int type casting
Fixes missing type casting in the OwnerDrawnComboBox.py demo module.
This commit is contained in:
@@ -49,15 +49,15 @@ class PenStyleComboBox(wx.adv.OwnerDrawnComboBox):
|
|||||||
|
|
||||||
if flags & wx.adv.ODCB_PAINTING_CONTROL:
|
if flags & wx.adv.ODCB_PAINTING_CONTROL:
|
||||||
# for painting the control itself
|
# for painting the control itself
|
||||||
dc.DrawLine( r.x+5, int(r.y+r.height/2), r.x+r.width - 5, int(r.y+r.height/2) )
|
dc.DrawLine( int(r.x+5), int(r.y+r.height/2), int(r.x+r.width) - 5, int(r.y+r.height/2) )
|
||||||
|
|
||||||
else:
|
else:
|
||||||
# for painting the items in the popup
|
# for painting the items in the popup
|
||||||
dc.DrawText(self.GetString( item ),
|
dc.DrawText(self.GetString( item ),
|
||||||
r.x + 3,
|
int(r.x + 3),
|
||||||
int((r.y + 0) + ( (r.height/2) - dc.GetCharHeight() )/2)
|
int((r.y + 0) + ( (r.height/2) - dc.GetCharHeight() )/2)
|
||||||
)
|
)
|
||||||
dc.DrawLine( r.x+5, int(r.y+((r.height/4)*3)+1), r.x+r.width - 5, int(r.y+((r.height/4)*3)+1) )
|
dc.DrawLine( int(r.x+5), int(r.y+((r.height/4)*3)+1), int(r.x+r.width - 5), int(r.y+((r.height/4)*3)+1) )
|
||||||
|
|
||||||
|
|
||||||
# Overridden from OwnerDrawnComboBox, called for drawing the
|
# Overridden from OwnerDrawnComboBox, called for drawing the
|
||||||
|
|||||||
Reference in New Issue
Block a user