Re: [gtk-list] Item "deactivate"
- From: Tim Janik <timj gtk org>
- To: Alex Buoy <Alex Buoy eiffel com>
- cc: Gtk+ MList <gtk-list redhat com>
- Subject: Re: [gtk-list] Item "deactivate"
- Date: Wed, 23 Jun 1999 02:28:01 +0200 (CEST)
On Tue, 22 Jun 1999, Alex Buoy wrote:
> Hi,
>
> I want a command to be executed when deactivating the items (for instance a
> radio menu item) but I only saw the "activate" signal to connect to.
items only get selected and deselected. "deactivating" a radio menu item
actually gets toggled when it changes state, so you want to catch the
"toggled" signal introduced by the check menu item class and check the
current state.
> How can I do that?
static void
my_callback (GtkWidget *widget,
gpointer my_data)
{
if (GTK_CHECK_MENU_ITEM (widget)->active)
{
}
else
{
/* check (radio) menu item got "deactivated" */
}
}
gtk_signal_connect (GTK_OBJECT (widget),
"toggled",
GTK_SIGNAL_FUNC (my_callback),
NULL);
>
> Any help would be very appreciated.
>
> thank you.
>
> Alex.
>
---
ciaoTJ
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]