Re: Button patch (Was: enhancing GTK visual quality)
- From: Tim Janik <timj gtk org>
- To: Damon Chaplin <damon helixcode com>
- Cc: "gtk-devel-list gnome org" <gtk-devel-list gnome org>
- Subject: Re: Button patch (Was: enhancing GTK visual quality)
- Date: Mon, 28 Aug 2000 15:59:22 +0200 (CEST)
On Fri, 25 Aug 2000, Damon Chaplin wrote:
> Antonio Campos wrote:
> >
> > Derek Simkowiak wrote:
>
> [snip]
>
> > > -> 2) The long and interminable story of the buttons don't getting
> > > -> depressed (visually) when the users click on them using the keyboard
> > >
> > > This has come up before.
> > >
> >
> > Yes, but without any solutions.
> > Does anybody have one?
>
> I can't remember if there is already a patch floating around to do this.
> But anyway, I've had a quick go and a patch is attached (for 1.2.7, though
> it should be OK with 1.2.8).
>
> It makes sure the button's state is ACTIVE in the "clicked" signal,
> and uses a timeout callback to reset it.
>
> This means that it will also happen if you call gtk_button_clicked(),
> which we may not want. In that case we'd have to create another
> signal to use as the activate_signal, and do all this there.
hm, except for you using a timeout, the patch looks pretty sane.
what i don't like about using a timeout is that if e.g. a ::clicked
handler calls gtk_main() recursively, the button becomes depressed
after 100ms when activate via the keyboard, while it wouldn't do
that for mouse events.
i think we should be consistent there with cleaning up the ACTIVATED
state at the end of the signal emission (for 1.2.8, we'd have to do
that in an _after() handler which may impose problems for stopped
emission, but the patch has to be written against CVS HEAD anyways,
and there we'll have something like a cleanup class handler).
>
> Damon
---
ciaoTJ
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]