Multiple slider

Are you writing your own components and need help with how to set them up or have questions about the components you are deriving from ? Ask them here.
Post Reply
sy6502
In need of some credit
In need of some credit
Posts: 1
Joined: Sun Oct 18, 2015 7:42 pm

Multiple slider

Post by sy6502 »

Hello,
I am writing a new widget mslider (multiple slider).
The widget is derived from wxPanel. In the panel there are
four indipenedent draggable sliders (boxes). In the method
"void mouseMoved(wxMouseEvent& event);" the widget is redrawn.
I need to create a new event like EVT_SCROLL for wxSlider
to comunicate the changes in the slider position to the parent
window. The event shoul be triggered inside the method
"void mouseMoved(wxMouseEvent& event);".

Thx,
sy6502
User avatar
doublemax
Moderator
Moderator
Posts: 19116
Joined: Fri Apr 21, 2006 8:03 pm
Location: $FCE2

Re: Multiple slider

Post by doublemax »

What's the question? How to create a new event type?
http://docs.wxwidgets.org/trunk/overvie ... nts_custom

BTW:
"In the method void mouseMoved(wxMouseEvent& event);" the widget is redrawn.
I recommend to just change the internal state of the control in the mouse event handler and then call Refresh().
Use the source, Luke!
Post Reply