Kaydet (Commit) d8d971ea authored tarafından Nick Treleaven's avatar Nick Treleaven

Apply patch from blackdog to add document_save_file() to the plugin

API (thanks).
Add document_open_file() to plugin API.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1796 ea778897-0a13-0410-b9d1-a72fbfd435f5
üst 0f3ffc3b
...@@ -14,6 +14,10 @@ ...@@ -14,6 +14,10 @@
* HACKING: * HACKING:
Add more information for adding a filetype. Add more information for adding a filetype.
2 minor edits. 2 minor edits.
* src/plugindata.h, src/plugins.c:
Apply patch from blackdog to add document_save_file() to the plugin
API (thanks).
Add document_open_file() to plugin API.
2007-08-13 Enrico Tröger <enrico(dot)troeger(at)uvena(dot)de> 2007-08-13 Enrico Tröger <enrico(dot)troeger(at)uvena(dot)de>
......
...@@ -68,7 +68,7 @@ ...@@ -68,7 +68,7 @@
/* The API version should be incremented whenever any plugin data types below are /* The API version should be incremented whenever any plugin data types below are
* modified. */ * modified. */
static const gint api_version = 9; static const gint api_version = 10;
/* The ABI version should be incremented whenever existing fields in the plugin /* The ABI version should be incremented whenever existing fields in the plugin
* data types below have to be changed or reordered. It should stay the same if fields * data types below have to be changed or reordered. It should stay the same if fields
...@@ -160,6 +160,9 @@ typedef struct DocumentFuncs ...@@ -160,6 +160,9 @@ typedef struct DocumentFuncs
gint (*new_file) (const gchar *filename, struct filetype *ft); gint (*new_file) (const gchar *filename, struct filetype *ft);
gint (*get_cur_idx) (); gint (*get_cur_idx) ();
struct document* (*get_current) (); struct document* (*get_current) ();
gboolean (*save_file)(gint idx, gboolean force);
gboolean (*open_file)(gint idx, const gchar *filename, gint pos, gboolean readonly,
struct filetype *ft, const gchar *forced_enc);
} }
DocumentFuncs; DocumentFuncs;
......
...@@ -73,7 +73,9 @@ static GList *plugin_list = NULL; ...@@ -73,7 +73,9 @@ static GList *plugin_list = NULL;
static DocumentFuncs doc_funcs = { static DocumentFuncs doc_funcs = {
&document_new_file, &document_new_file,
&document_get_cur_idx, &document_get_cur_idx,
&document_get_current &document_get_current,
&document_save_file,
&document_open_file
}; };
static ScintillaFuncs sci_funcs = { static ScintillaFuncs sci_funcs = {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment