forked from AuroraMiddleware/gtk
widget factory: Add an example for an insensitive model button
This will make it easier to make insensitive model buttons appear properly in other themes.
This commit is contained in:
parent
4e930ada32
commit
d5d28a5062
@ -1336,6 +1336,7 @@ int
|
||||
main (int argc, char *argv[])
|
||||
{
|
||||
GtkApplication *app;
|
||||
GAction *action;
|
||||
static GActionEntry app_entries[] = {
|
||||
{ "about", activate_about, NULL, NULL, NULL },
|
||||
{ "quit", activate_quit, NULL, NULL, NULL },
|
||||
@ -1353,6 +1354,8 @@ main (int argc, char *argv[])
|
||||
g_action_map_add_action_entries (G_ACTION_MAP (app),
|
||||
app_entries, G_N_ELEMENTS (app_entries),
|
||||
app);
|
||||
action = g_action_map_lookup_action (G_ACTION_MAP (app), "wine");
|
||||
g_simple_action_set_enabled (G_SIMPLE_ACTION (action), FALSE);
|
||||
|
||||
g_signal_connect (app, "activate", G_CALLBACK (activate), NULL);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user