void update_undo_sensitivity (void) { /* Unfortunately, this does not change the state of undo button in app menu :( */ gboolean enable = UndoVisible (); gboolean result = g_action_group_query_action (G_ACTION_GROUP (application), "Undo", &enable, NULL, NULL, NULL, NULL); }
void update_undo_sensitivity (void) { g_simple_action_set_enabled (((GSimpleAction *) undo_action), UndoVisible ()); }