return true;
}
+bool wxToolBar::Cocoa_acceptsFirstMouse(bool &acceptsFirstMouse, WX_NSEvent theEvent)
+{
+ acceptsFirstMouse = true; return true;
+}
+
bool wxToolBar::Cocoa_drawRect(const NSRect &rect)
{
wxToolBarToolsList::compatibility_iterator node;
NSButtonCell *buttonCell = m_mouseDownTool->GetNSButtonCell();
if(buttonCell)
{
+ [buttonCell retain];
[buttonCell setHighlighted: YES];
if([buttonCell trackMouse: theEvent
inRect:AddToolPadding(m_mouseDownTool->GetFrameRect()) ofView:m_cocoaNSView
wxLogTrace(wxTRACE_COCOA,wxT("Button was clicked after drag!"));
}
[buttonCell setHighlighted: NO];
+ [buttonCell release];
}
}
return wxToolBarBase::Cocoa_mouseDragged(theEvent);
NSButtonCell *buttonCell = tool->GetNSButtonCell();
if(buttonCell)
{
+ [buttonCell retain];
m_mouseDownTool = tool;
[buttonCell setHighlighted: YES];
if([buttonCell trackMouse: theEvent
wxLogTrace(wxTRACE_COCOA,wxT("Button was clicked!"));
}
[buttonCell setHighlighted: NO];
+ [buttonCell release];
}
}
return wxToolBarBase::Cocoa_mouseDown(theEvent);