plugin api: convert GeanyEditor to GBoxed internally
GeanyObject signals require GTypes to be gobject-introspection compatible.
This commit is contained in:
parent
7702a4639b
commit
be64b177ca
12
src/editor.c
12
src/editor.c
@ -5309,3 +5309,15 @@ void editor_insert_snippet(GeanyEditor *editor, gint pos, const gchar *snippet)
|
||||
editor_insert_text_block(editor, pattern->str, pos, -1, -1, TRUE);
|
||||
g_string_free(pattern, TRUE);
|
||||
}
|
||||
|
||||
static void *copy_(void *src) { return src; }
|
||||
static void free_(void *doc) { }
|
||||
|
||||
/** @gironly
|
||||
* Gets the GType of GeanyEditor
|
||||
*
|
||||
* @return the GeanyEditor type */
|
||||
GEANY_API_SYMBOL
|
||||
GType editor_get_type (void);
|
||||
|
||||
G_DEFINE_BOXED_TYPE(GeanyEditor, editor, copy_, free_);
|
||||
|
@ -139,6 +139,10 @@ typedef struct GeanyEditorPrefs
|
||||
}
|
||||
GeanyEditorPrefs;
|
||||
|
||||
|
||||
#define GEANY_TYPE_EDITOR (editor_get_type())
|
||||
GType editor_get_type (void);
|
||||
|
||||
/** Editor-owned fields for each document. */
|
||||
typedef struct GeanyEditor
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user