We don't need two labels for "Toggle QuickMask". Fixes bug #316569.

2005-09-17  Michael Natterer  <mitch@gimp.org>

	We don't need two labels for "Toggle QuickMask".
	Fixes bug #316569.

	* app/actions/qmask-actions.c: removed "qmask-active" action.

	* menus/qmask-menu.xml: use "qmask-toggle" instead.
This commit is contained in:
Michael Natterer 2005-09-17 21:38:37 +00:00 committed by Michael Natterer
parent f731cb666a
commit 1763b76918
4 changed files with 12 additions and 35 deletions

View File

@ -1,3 +1,12 @@
2005-09-17 Michael Natterer <mitch@gimp.org>
We don't need two labels for "Toggle QuickMask".
Fixes bug #316569.
* app/actions/qmask-actions.c: removed "qmask-active" action.
* menus/qmask-menu.xml: use "qmask-toggle" instead.
2005-09-17 Michael Natterer <mitch@gimp.org>
* app/widgets/gimpactionview.c (gimp_action_view_new): skip

View File

@ -50,18 +50,11 @@ static GimpActionEntry qmask_actions[] =
static GimpToggleActionEntry qmask_toggle_actions[] =
{
{ "qmask-active", NULL,
N_("_Quick Mask Active"), NULL, NULL,
G_CALLBACK (qmask_toggle_cmd_callback),
FALSE,
GIMP_HELP_QMASK_TOGGLE },
{ "qmask-toggle", GIMP_STOCK_QMASK_ON,
N_("Toggle _Quick Mask"), "<shift>Q", NULL,
G_CALLBACK (qmask_toggle_cmd_callback),
FALSE,
GIMP_HELP_QMASK_TOGGLE }
};
static GimpRadioActionEntry qmask_invert_actions[] =
@ -81,8 +74,6 @@ static GimpRadioActionEntry qmask_invert_actions[] =
void
qmask_actions_setup (GimpActionGroup *group)
{
GtkAction *action;
gimp_action_group_add_actions (group,
qmask_actions,
G_N_ELEMENTS (qmask_actions));
@ -96,10 +87,6 @@ qmask_actions_setup (GimpActionGroup *group)
G_N_ELEMENTS (qmask_invert_actions),
FALSE,
G_CALLBACK (qmask_invert_cmd_callback));
action = gtk_action_group_get_action (GTK_ACTION_GROUP (group),
"qmask-active");
gtk_action_set_accel_path (action, "<Actions>/qmask/qmask-toggle");
}
void
@ -115,11 +102,8 @@ qmask_actions_update (GimpActionGroup *group,
#define SET_COLOR(action,color) \
gimp_action_group_set_action_color (group, action, (color), FALSE)
SET_SENSITIVE ("qmask-active", gimage);
SET_SENSITIVE ("qmask-toggle", gimage);
SET_ACTIVE ("qmask-active", gimage && gimage->qmask_state);
SET_ACTIVE ("qmask-toggle", gimage && gimage->qmask_state);
SET_ACTIVE ("qmask-toggle", gimage && gimage->qmask_state);
SET_SENSITIVE ("qmask-invert-on", gimage);
SET_SENSITIVE ("qmask-invert-off", gimage);

View File

@ -50,18 +50,11 @@ static GimpActionEntry qmask_actions[] =
static GimpToggleActionEntry qmask_toggle_actions[] =
{
{ "qmask-active", NULL,
N_("_Quick Mask Active"), NULL, NULL,
G_CALLBACK (qmask_toggle_cmd_callback),
FALSE,
GIMP_HELP_QMASK_TOGGLE },
{ "qmask-toggle", GIMP_STOCK_QMASK_ON,
N_("Toggle _Quick Mask"), "<shift>Q", NULL,
G_CALLBACK (qmask_toggle_cmd_callback),
FALSE,
GIMP_HELP_QMASK_TOGGLE }
};
static GimpRadioActionEntry qmask_invert_actions[] =
@ -81,8 +74,6 @@ static GimpRadioActionEntry qmask_invert_actions[] =
void
qmask_actions_setup (GimpActionGroup *group)
{
GtkAction *action;
gimp_action_group_add_actions (group,
qmask_actions,
G_N_ELEMENTS (qmask_actions));
@ -96,10 +87,6 @@ qmask_actions_setup (GimpActionGroup *group)
G_N_ELEMENTS (qmask_invert_actions),
FALSE,
G_CALLBACK (qmask_invert_cmd_callback));
action = gtk_action_group_get_action (GTK_ACTION_GROUP (group),
"qmask-active");
gtk_action_set_accel_path (action, "<Actions>/qmask/qmask-toggle");
}
void
@ -115,11 +102,8 @@ qmask_actions_update (GimpActionGroup *group,
#define SET_COLOR(action,color) \
gimp_action_group_set_action_color (group, action, (color), FALSE)
SET_SENSITIVE ("qmask-active", gimage);
SET_SENSITIVE ("qmask-toggle", gimage);
SET_ACTIVE ("qmask-active", gimage && gimage->qmask_state);
SET_ACTIVE ("qmask-toggle", gimage && gimage->qmask_state);
SET_ACTIVE ("qmask-toggle", gimage && gimage->qmask_state);
SET_SENSITIVE ("qmask-invert-on", gimage);
SET_SENSITIVE ("qmask-invert-off", gimage);

View File

@ -3,7 +3,7 @@
<ui>
<popup action="qmask-popup">
<menuitem action="qmask-active" />
<menuitem action="qmask-toggle" />
<separator />
<menuitem action="qmask-invert-on" />
<menuitem action="qmask-invert-off" />