osso-abook-init

osso-abook-init — Library initialization functions.

Synopsis

gboolean            osso_abook_init                     (int *argc,
                                                         char ***argv,
                                                         osso_context_t *osso_context);
gboolean            osso_abook_init_with_args           (int *argc,
                                                         char ***argv,
                                                         osso_context_t *osso_context,
                                                         char *parameter_string,
                                                         GOptionEntry *entries,
                                                         char *translation_domain,
                                                         GError **error);
gboolean            osso_abook_init_with_name           (const char *name,
                                                         osso_context_t *osso_context);
osso_context_t*     osso_abook_get_osso_context         (void);
void                osso_abook_make_resident            (void);

Description

This module provides some entry hooks for the libosso-abook library.

Details

osso_abook_init ()

gboolean            osso_abook_init                     (int *argc,
                                                         char ***argv,
                                                         osso_context_t *osso_context);

Initializes the OssoABook API.

argc : Address of the argc parameter of your main() function. Changed if any arguments were handled.
argv : Address of the argv parameter of main(). Any parameters understood by gtk_init() are stripped before return.
osso_context : The osso_context_t of this application.
Returns : TRUE on success, FALSE otherwise.

osso_abook_init_with_args ()

gboolean            osso_abook_init_with_args           (int *argc,
                                                         char ***argv,
                                                         osso_context_t *osso_context,
                                                         char *parameter_string,
                                                         GOptionEntry *entries,
                                                         char *translation_domain,
                                                         GError **error);

Initializes the OssoABook API.

argc : Address of the argc parameter of your main() function. Changed if any arguments were handled.
argv : Address of the argv parameter of main(). Any parameters understood by gtk_init() are stripped before return.
osso_context : The osso_context_t of this application.
parameter_string : a string which is displayed in the first line of --help output, after programname [OPTION...]
entries : a NULL-terminated array of GOptionEntrys describing the options of your program
translation_domain : a translation domain to use for translating the --help output for the options in entries with gettext(), or NULL
error : a return location for errors
Returns : TRUE on success, FALSE otherwise.

osso_abook_init_with_name ()

gboolean            osso_abook_init_with_name           (const char *name,
                                                         osso_context_t *osso_context);

Initializes the OssoABook API. This form is to be used by plugins or any other situation where argc and argv are either incorrect or unavailable.

name : The name of this application.
osso_context : The osso_context_t of this application.
Returns : TRUE on success, FALSE otherwise.

osso_abook_get_osso_context ()

osso_context_t*     osso_abook_get_osso_context         (void);

Obtains the osso_context_t for this instance.

Returns : An osso_context_t

osso_abook_make_resident ()

void                osso_abook_make_resident            (void);

This function is a workaround for problems with libosso-abook getting loaded twice into the same process, such as when the control panel loads a plugin which uses libosso-abook after it has already been loaded and unloaded. In order to prevent g_type_register_static being called twice, this function can be called to make mc be redident in memory for the lifetime of the process.