aboutsummaryrefslogtreecommitdiffstats
path: root/src/ephy-window.c
diff options
context:
space:
mode:
authorChristian Persch <chpe@cvs.gnome.org>2005-04-18 22:53:54 +0800
committerChristian Persch <chpe@src.gnome.org>2005-04-18 22:53:54 +0800
commit7a23d5fb25b5675ef1a952abe4e7d43f62b3cd8d (patch)
treef51670f458dbbb6c6f3f31591e09c5ddc9d436ed /src/ephy-window.c
parentab2413f51a0497c1ac4f99569fdb725ccdcbb3cd (diff)
downloadgsoc2013-epiphany-7a23d5fb25b5675ef1a952abe4e7d43f62b3cd8d.tar
gsoc2013-epiphany-7a23d5fb25b5675ef1a952abe4e7d43f62b3cd8d.tar.gz
gsoc2013-epiphany-7a23d5fb25b5675ef1a952abe4e7d43f62b3cd8d.tar.bz2
gsoc2013-epiphany-7a23d5fb25b5675ef1a952abe4e7d43f62b3cd8d.tar.lz
gsoc2013-epiphany-7a23d5fb25b5675ef1a952abe4e7d43f62b3cd8d.tar.xz
gsoc2013-epiphany-7a23d5fb25b5675ef1a952abe4e7d43f62b3cd8d.tar.zst
gsoc2013-epiphany-7a23d5fb25b5675ef1a952abe4e7d43f62b3cd8d.zip
Constify the action entries. Fixes bug #301065, patch by Paolo Borelli.
2005-04-18 Christian Persch <chpe@cvs.gnome.org> * src/ephy-window.c: (setup_ui_manager): Constify the action entries. Fixes bug #301065, patch by Paolo Borelli.
Diffstat (limited to 'src/ephy-window.c')
-rw-r--r--src/ephy-window.c15
1 files changed, 6 insertions, 9 deletions
diff --git a/src/ephy-window.c b/src/ephy-window.c
index f14b9810b..2f57ae5b9 100644
--- a/src/ephy-window.c
+++ b/src/ephy-window.c
@@ -108,7 +108,7 @@ static void sync_tab_zoom (EphyTab *tab,
GParamSpec *pspec,
EphyWindow *window);
-static GtkActionEntry ephy_menu_entries [] = {
+static const GtkActionEntry ephy_menu_entries [] = {
/* Toplevel */
@@ -273,9 +273,8 @@ static GtkActionEntry ephy_menu_entries [] = {
N_("Display credits for the web browser creators"),
G_CALLBACK (window_cmd_help_about) },
};
-static guint ephy_menu_n_entries = G_N_ELEMENTS (ephy_menu_entries);
-static GtkToggleActionEntry ephy_menu_toggle_entries [] =
+static const GtkToggleActionEntry ephy_menu_toggle_entries [] =
{
/* File Menu */
@@ -304,9 +303,8 @@ static GtkToggleActionEntry ephy_menu_toggle_entries [] =
"",
G_CALLBACK (window_cmd_browse_with_caret), FALSE }
};
-static guint ephy_menu_n_toggle_entries = G_N_ELEMENTS (ephy_menu_toggle_entries);
-static GtkActionEntry ephy_popups_entries [] = {
+static const GtkActionEntry ephy_popups_entries [] = {
/* Document */
{ "SaveBackgroundAs", NULL, N_("_Save Background As..."), NULL,
@@ -361,7 +359,6 @@ static GtkActionEntry ephy_popups_entries [] = {
{ "CopyImageLocation", NULL, N_("Copy I_mage Address"), NULL,
NULL, G_CALLBACK (popup_cmd_copy_image_location) },
};
-static guint ephy_popups_n_entries = G_N_ELEMENTS (ephy_popups_entries);
#ifdef HAVE_X11_XF86KEYSYM_H
static const struct
@@ -1141,10 +1138,10 @@ setup_ui_manager (EphyWindow *window)
action_group = gtk_action_group_new ("WindowActions");
gtk_action_group_set_translation_domain (action_group, NULL);
gtk_action_group_add_actions (action_group, ephy_menu_entries,
- ephy_menu_n_entries, window);
+ G_N_ELEMENTS (ephy_menu_entries), window);
gtk_action_group_add_toggle_actions (action_group,
ephy_menu_toggle_entries,
- ephy_menu_n_toggle_entries,
+ G_N_ELEMENTS (ephy_menu_toggle_entries),
window);
gtk_ui_manager_insert_action_group (manager, action_group, 0);
window->priv->action_group = action_group;
@@ -1172,7 +1169,7 @@ setup_ui_manager (EphyWindow *window)
action_group = gtk_action_group_new ("PopupsActions");
gtk_action_group_set_translation_domain (action_group, NULL);
gtk_action_group_add_actions (action_group, ephy_popups_entries,
- ephy_popups_n_entries, window);
+ G_N_ELEMENTS (ephy_popups_entries), window);
gtk_ui_manager_insert_action_group (manager, action_group, 0);
window->priv->popups_action_group = action_group;