Miscellaneous

Name

Miscellaneous -- Other miscellaneous functions

Synopsis


#include <applet-widget.h>


int         applet_widget_get_applet_count  (void);
void        applet_widget_sync_config       (AppletWidget *applet);
void        applet_widget_queue_resize      (AppletWidget *applet);
void        applet_widget_panel_quit        (void);

Description

Details

applet_widget_get_applet_count ()

int         applet_widget_get_applet_count  (void);

Gets the number of applets loaded in this this process. If this is a shared lib applet it will return the total number of shared lib applets loaded.

Returns : The number of applets loaded.


applet_widget_sync_config ()

void        applet_widget_sync_config       (AppletWidget *applet);

Tell the panel to save our session here (just saves, no shutdown). This should be done when you change some of your config and want the panel to save it's config, you should NOT call this in the session_save handler as it will result in a locked panel, as it will actually trigger another session_save signal for you. However it also asks for a complete panel save, so you should not do this too often, and only when the user has changed some preferences and you want to sync them to disk. Theoretically you don't even need to do that if you don't mind loosing settings on a panel crash or when the user kills the session without logging out properly, since the panel will always save your session when it exists.

applet : AppletWidget to work on.


applet_widget_queue_resize ()

void        applet_widget_queue_resize      (AppletWidget *applet);

For shared library applets this calls gtk_widget_queue_resize on the internal panel eventbox, for external applets this just calls this on the AppletWidget itself, but in both cases it forces a resize of the socket on the panel

applet : AppletWidget to work on


applet_widget_panel_quit ()

void        applet_widget_panel_quit        (void);

Trigger 'Log out' on the panel. This shouldn't be used in normal applets, as it is not normal for applets to trigger a logout.