Plugin changes



I've done a big rewrite of Conglomerate's "plugin" code.

My hope is to eventually use the libgnomeoffice plugin framework, I aim
for this to happen for our 1.0.0 release, rather than for 0.8.0.

Conglomerate's internal plugin API is now very similar to that of
libgnomeoffice (in Gnome's CVS), so it should now be easy for us to
start using that, in theory anyway.

I've cross-posted to the gnome-office list to let them know I haven't
forgotted them.

Conglomerate-specific stuff follows:

I've split up the monolithic cong-plugin.[hc] into multiple files, which
should reduce the huge rebuild times I get when I make changes (sigh)

I've done the following renaming along the way:
s/CongFunctionality/CongService (for consistency with libgnomeoffice)
s/CongCustomPropertyDialog/CongServiceNodePropertyDialog
s/CongDocumentFactory/CongServiceDocumentFactory
s/CongImporter/CongServiceImporter
s/CongExporter/CongServiceExporter
s/CongPrintMethod/CongServicePrintMethod
s/CongTool/CongServiceTool
s/CongDocTool/CongServiceDocTool
s/CongNodeTool/CongServiceNodeTool
s/CongPluginEditorNodeFactory/CongServiceEditorNodeFactory/
s/CongThumbnailer/CongServiceThumbnailer (doesn't do anything though)

with corresponding changes to object names, casting macros etc.

All of the above are now GObjects rather than plain structs; CongPlugin
is also now a GObject.  I've added a new file src/cong-object.h which
has a load of boilerplate macros for creating GObjects.

CongService objects no longer store internally which CongPlugin they are
in and hence can't use this when calculating their GConf path for
storing/retrieving configuration options.  They now store these things
in "/apps/conglomerate/services/SERVICE-ID/", and so any existing
settings (e.g. preferred export path, template locations) will be lost.

The benefits of these changes:
- it should now be very easy to use libgnomeoffice for plugin management
(e.g. shared dialogs for configuring plugin paths, enabling/disabling
plugins and other such things etc)
- it's much easier to add new types of plugin
- the code should be easier to maintain

-- 
David Malcolm
www.conglomerate.org




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]