This are the changes to geany that allow plugin signals to be used by GI-based plugins (e.g. through peasy).
- signal params must be boxed or gobject (I used gboxed) - the GType must be passed to g_signal_new() - since glib 2.30 there is a generic marshaller which can be used. otherwise we'd need a lot of duplicated, new marshaller code. I chosed to use the generic marshaller (by passing NULL to g_signal_new's marshall func) - geanyobject must be exposed to connect to. I chosed to implement a get_instance() function (singleton pattern)
Please review and comment You can view, comment on, or merge this pull request online at:
https://github.com/geany/geany/pull/1038
-- Commit Summary --
* plugin api: convert GeanyDocument to GBoxed internally * plugin api: convert GeanyFiletype to GBoxed internally * plugin api: convert GeanyEditor to GBoxed internally * plugin api: rename document_new_file to _create_file * plugin api: export geanyobject
-- File Changes --
M plugins/geanyplugin.h (1) M src/Makefile.am (1) M src/document.c (32) M src/document.h (4) M src/editor.c (11) M src/editor.h (4) M src/filetypes.c (11) M src/filetypes.h (3) M src/geanyobject.c (231) M src/geanyobject.h (3)
-- Patch Links --
https://github.com/geany/geany/pull/1038.patch https://github.com/geany/geany/pull/1038.diff
--- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/geany/geany/pull/1038