Re: Key event on hidden window
| From: | cohort | Date: | Fri, 20 Oct 2006 10:06:18 +0000 |
| Subject: | Re: Key event on hidden window | ||
| References: | 1 | Groups: | php.gtk.general |
| Request: | Send a blank email to php-gtk-general+get-7358@lists.php.net to get a copy of this message | ||
It seems to me that the event is being called only when that window is
in focus, so if you have a window that stays visible all the time (main
window?), you should set the 'on_key_press' handler to that window instead.
Thomas Munz wrote:
> I have a GtkWindow where i have connected the function 'on_key_press'
> with the signal key_press_event. I want now, that the window gets
> Shown/displayed when i press the F12 Key.
>
> So in case the status is hidden and i press the F12, the function
> 'on_key_press' gets called and display the window again. In case it
> is displayed and i press the F12, the function 'on_key_press' will
> hidde the window.
>
> This works fine in case the window is shown. But in case the window
> is hidden the function is not called, means the key_press_event event
> is not called.
> Is it somehow possible to fix this, or to make a workarround for that?