From 2d67ea260ba0c26893b2e6f132700c586cb64b59 Mon Sep 17 00:00:00 2001 From: Colomban Wendling Date: Sat, 20 Feb 2016 18:17:57 +0100 Subject: [PATCH 1/2] codenav: Cleanup Geany includes --- codenav/src/codenavigation.h | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/codenav/src/codenavigation.h b/codenav/src/codenavigation.h index 9aa3419a5..380f49a67 100644 --- a/codenav/src/codenavigation.h +++ b/codenav/src/codenavigation.h @@ -23,27 +23,17 @@ #define CODENAVIGATION_H /* First */ -#include "geany.h" /* for the GeanyApp data type */ +#include /* Other includes */ -#include "editor.h" /* for the declaration of the GeanyEditor struct, not strictly necessary - as it will be also included by plugindata.h */ -#include "document.h" /* for the declaration of the GeanyDocument struct */ -#include "ui_utils.h" #include "Scintilla.h" /* for the SCNotification struct */ -#include "keybindings.h" -#include "filetypes.h" #include #include #include "switch_head_impl.h" -/* Last */ -#include "plugindata.h" /* this defines the plugin API */ -#include "geanyfunctions.h" /* this wraps geany_functions function pointers */ - /* Debug flag */ /*#define CODE_NAVIGATION_DEBUG*/ From 206b6e5c19bb041a72f6e0954dddfd1c7a8fc0b4 Mon Sep 17 00:00:00 2001 From: Colomban Wendling Date: Sat, 20 Feb 2016 18:23:36 +0100 Subject: [PATCH 2/2] codenav: Drop use of the most obvious deprecated Geany API --- codenav/src/codenavigation.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/codenav/src/codenavigation.c b/codenav/src/codenavigation.c index 84929d73c..4cef04d75 100644 --- a/codenav/src/codenavigation.c +++ b/codenav/src/codenavigation.c @@ -44,10 +44,6 @@ PLUGIN_SET_TRANSLATABLE_INFO( _( "This plugin adds features to facilitate navigation between source files."), CODE_NAVIGATION_VERSION, "Lionel Fuentes, Federico Reghenzani") -/* Declare "GeanyKeyGroupInfo plugin_key_group_info[1]" and "GeanyKeyGroup *plugin_key_group", - * for Geany to find the keybindings */ -PLUGIN_KEY_GROUP(code_navigation, NB_KEY_IDS) - /********************* Data types for the feature *********************/ /* Column for the configuration widget */ @@ -65,6 +61,8 @@ GeanyPlugin *geany_plugin; GeanyData *geany_data; GeanyFunctions *geany_functions; +GeanyKeyGroup *plugin_key_group; + static GtkListStore *list_store; /* for settings dialog */ @@ -101,6 +99,8 @@ void plugin_init(GeanyData *data) { log_func(); + plugin_key_group = plugin_set_key_group(geany_plugin, "code_navigation", NB_KEY_IDS, NULL); + /* Load configuration */ load_configuration(); /* Initialize the features */