wxMacControlActionUPP = NewControlDefUPP( wxMacControlDefintion ) ;
}
#if TARGET_CARBON
+/*
+ only working under classic carbon
m_macControlAction = *(**(ControlHandle)m_macControl).contrlDefProc ;
(**(ControlHandle)m_macControl).contrlDefProc = (Handle) &wxMacControlActionUPP ;
+*/
#else
m_macControlAction = *(**(ControlHandle)m_macControl).contrlDefProc ;
SetSize(pos.x, pos.y, new_size.x, new_size.y);
UMAShowControl( (ControlHandle) m_macControl ) ;
+
+ SetCursor( *wxSTANDARD_CURSOR ) ;
+
Refresh() ;
}
void wxControl::MacRedrawControl()
{
- if ( (ControlHandle) m_macControl && MacGetRootWindow() )
+ if ( (ControlHandle) m_macControl && MacGetRootWindow() && m_macControlIsShown )
{
wxClientDC dc(this) ;
wxMacPortSetter helper(&dc) ;
void wxControl::OnPaint(wxPaintEvent& event)
{
- if ( IsKindOf( CLASSINFO( wxBitmapButton ) ) )
- {
- int i ;
- i = 0 ;
- }
if ( (ControlHandle) m_macControl )
{
wxPaintDC dc(this) ;
ControlHandle control ;
Point localwhere ;
SInt16 controlpart ;
- WindowRef window = (WindowRef) MacGetRootWindow() ;
localwhere.h = x ;
localwhere.v = y ;
if ( event.m_metaDown )
modifiers |= cmdKey ;
-/*
-#if TARGET_CARBON
- control = FindControlUnderMouse( localwhere , window , &controlpart ) ;
-#else
- controlpart = FindControl( localwhere , window , &control ) ;
-#endif
-*/
{
- /*
- if ( AcceptsFocus() && FindFocus() != this )
- {
- SetFocus() ;
- }
- */
control = (ControlHandle) m_macControl ;
if ( control && ::IsControlActive( control ) )
{