HScrollBar Question : Solved

md5Crypt

04-03-2010 05:36:50

Hello everyone,

I'm new to Ogre3d and QuickGUI, I'm having a problem with the event WIDGET_EVENT_SCROLL_CHANGED for the HScrollBar, when I change the scroll, the event is not being called. Here is how I am creating the object and set the event.

QuickGUI::HScrollBar * sliderConfig = mySheet->createHScrollBar(QuickGUI::Rect(50,100,100,25));
sliderConfig->addWidgetEventHandler(QuickGUI::WIDGET_EVENT_SCROLL_CHANGED, &App::changeConfig, this);


Thank you for your help!

md5Crypt

04-03-2010 13:29:27

Solved.
Changing the EventHandler addWidgetEventHandler to addScrollBarEventHandler with the event SCROLLBAR_EVENT_ON_SCROLLED.
sliderConfig->addScrollBarEventHandler(QuickGUI::SCROLLBAR_EVENT_ON_SCROLLED, &App::changeConfig, this);

:)

kungfoomasta

04-03-2010 20:07:39

Yep, that would do it. :)