[gedit] spell: declare action_entries inside function
- From: Sébastien Wilmet <swilmet src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gedit] spell: declare action_entries inside function
- Date: Thu, 7 Jan 2016 17:13:57 +0000 (UTC)
commit 396b86bc7dc13e52ab2d0e5eed4fcce875e19ece
Author: Sébastien Wilmet <swilmet gnome org>
Date: Thu Jan 7 17:53:03 2016 +0100
spell: declare action_entries inside function
To avoid the function prototypes.
plugins/spell/gedit-spell-plugin.c | 19 +++++++------------
1 files changed, 7 insertions(+), 12 deletions(-)
---
diff --git a/plugins/spell/gedit-spell-plugin.c b/plugins/spell/gedit-spell-plugin.c
index dc4a71d..4b48351 100644
--- a/plugins/spell/gedit-spell-plugin.c
+++ b/plugins/spell/gedit-spell-plugin.c
@@ -81,18 +81,6 @@ G_DEFINE_DYNAMIC_TYPE_EXTENDED (GeditSpellPlugin,
gedit_window_activatable_iface_init)
G_ADD_PRIVATE_DYNAMIC (GeditSpellPlugin))
-static void spell_cb (GSimpleAction *action, GVariant *parameter, gpointer data);
-static void set_language_cb (GSimpleAction *action, GVariant *parameter, gpointer data);
-static void inline_checker_activate_cb (GSimpleAction *action, GVariant *parameter, gpointer data);
-static void inline_checker_change_state_cb (GSimpleAction *action, GVariant *state, gpointer data);
-
-static GActionEntry action_entries[] =
-{
- { "check-spell", spell_cb },
- { "config-spell", set_language_cb },
- { "inline-checker", inline_checker_activate_cb, NULL, "false", inline_checker_change_state_cb }
-};
-
static void
gedit_spell_plugin_init (GeditSpellPlugin *plugin)
{
@@ -608,6 +596,13 @@ gedit_spell_plugin_activate (GeditWindowActivatable *activatable)
GtkStatusbar *statusbar;
GList *views, *l;
+ const GActionEntry action_entries[] =
+ {
+ { "check-spell", spell_cb },
+ { "config-spell", set_language_cb },
+ { "inline-checker", inline_checker_activate_cb, NULL, "false", inline_checker_change_state_cb
}
+ };
+
gedit_debug (DEBUG_PLUGINS);
plugin = GEDIT_SPELL_PLUGIN (activatable);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]