Re: Can't use a scale widget inside a GtkList widget.




Michael Babcock <mbabcock@la.creatureshop.henson.com> writes:

> Hello,
> 
> I'm having a problem using a GtkList widget. I'm putting GtkListItems in
> it that contain an hbox that contains a label and a scale widget. (I may
> add additional widgets later.) The problem is you can't grab the slider
> with the left mouse button and drag it left and right, unless you keep
> your pointer exactly inside the trough area, which is impossible.
> Apparently, the list widget is using the left button for item selection
> and it conflicts with the scale's pointer grab. Using the middle or
> right button to drag the slider works, but I can't ask my users to
> remember to use that workaround in this context. (Besides we will
> eventually be using a Mac PowerBook with only one mouse button.)

Sounds like a bug in the scale - it isn't correctly marking
the pointer press events as handled.

If my guess is right, the following should be a workaround:

 gtk_signal_connect_after (GTK_WIDGET (scale), "button_press_event",
                           GTK_SIGNAL_FUNC (gtk_true), NULL);
 
Regards,
                                        Owen



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]