How can I detect whether the mouse is over a combobox - specifically during a mouse click so that the normal behaviour of the mouse is not run.
You can disable combobox. (setEnabled(false)) if you want to disable normal behaviour.
Or tell me what you want to have as result?
Sorry for late reply - compute troubles :S.
I have a function that normally runs when the mouse is clicked. It selects and deselects objects. But when I click on one of the widgets (this now needs to be for combo box and edit) I don't want the selected object to be deselected - i.e. the function not to be run. How do I check if the mouse was clicked over these widgets. For buttons, I use eventMouseButtonPressed which seems to work, but combobox and edit dont seem to call this when they are clicked on.
Oh, so you want to check if you clicked on GUI or not?
virtual bool mousePressed( const OIS::MouseEvent &arg, OIS::MouseButtonID id )All inject*** functions return true if event was handled MyGUI and else if it wasn't.
if ( mGUI->injectMousePress(arg, id) ) return true;
// your not related to GUI code here
P.S. MyGUI is awesome, much prefer it to CEGUI. Keep up the good work.