Settings

Settings — Helper functions for reading and writing settings

Synopsis

#define             OSSO_ABOOK_SETTINGS_KEY_CONTACT_ORDER
#define             OSSO_ABOOK_SETTINGS_KEY_HOME_APPLETS
#define             OSSO_ABOOK_SETTINGS_KEY_LAST_IMSI
#define             OSSO_ABOOK_SETTINGS_KEY_NAME_ORDER
#define             OSSO_ABOOK_SETTINGS_KEY_SELF_CARD
#define             OSSO_ABOOK_SETTINGS_KEY_SELF_AVATAR_IMPORTED
#define             OSSO_ABOOK_SETTINGS_KEY_VOICEMAIL_VCARD
#define             OSSO_ABOOK_SETTINGS_KEY_SPEED_DIAL_DIR
#define             OSSO_ABOOK_SETTINGS_KEY_VOICEMAIL_INDEX
enum                OssoABookContactOrder;
enum                OssoABookNameOrder;
GConfClient*        osso_abook_get_gconf_client         (void);
OssoABookContactOrder osso_abook_settings_get_contact_order
                                                        (void);
GSList*             osso_abook_settings_get_home_applets
                                                        (void);
OssoABookNameOrder  osso_abook_settings_get_name_order  (void);
const char*         osso_abook_settings_get_picture_folder
                                                        (void);
gboolean            osso_abook_settings_set_contact_order
                                                        (OssoABookContactOrder order);
gboolean            osso_abook_settings_set_home_applets
                                                        (GSList *list);
gboolean            osso_abook_settings_set_name_order  (OssoABookNameOrder order);
gboolean            osso_abook_settings_get_self_avatar_imported
                                                        (void);
gboolean            osso_abook_settings_set_self_avatar_imported
                                                        (gboolean imported);

Description

This module provides functions that allow you to access and modify the settings of the addressbook

Details

OSSO_ABOOK_SETTINGS_KEY_CONTACT_ORDER

#define             OSSO_ABOOK_SETTINGS_KEY_CONTACT_ORDER

OSSO_ABOOK_SETTINGS_KEY_HOME_APPLETS

#define             OSSO_ABOOK_SETTINGS_KEY_HOME_APPLETS

OSSO_ABOOK_SETTINGS_KEY_LAST_IMSI

#define             OSSO_ABOOK_SETTINGS_KEY_LAST_IMSI

OSSO_ABOOK_SETTINGS_KEY_NAME_ORDER

#define             OSSO_ABOOK_SETTINGS_KEY_NAME_ORDER

OSSO_ABOOK_SETTINGS_KEY_SELF_CARD

#define             OSSO_ABOOK_SETTINGS_KEY_SELF_CARD

OSSO_ABOOK_SETTINGS_KEY_SELF_AVATAR_IMPORTED

#define             OSSO_ABOOK_SETTINGS_KEY_SELF_AVATAR_IMPORTED

OSSO_ABOOK_SETTINGS_KEY_VOICEMAIL_VCARD

#define             OSSO_ABOOK_SETTINGS_KEY_VOICEMAIL_VCARD

OSSO_ABOOK_SETTINGS_KEY_SPEED_DIAL_DIR

#define             OSSO_ABOOK_SETTINGS_KEY_SPEED_DIAL_DIR

OSSO_ABOOK_SETTINGS_KEY_VOICEMAIL_INDEX

#define             OSSO_ABOOK_SETTINGS_KEY_VOICEMAIL_INDEX

enum OssoABookContactOrder

typedef enum {
        OSSO_ABOOK_CONTACT_ORDER_NONE = -1,
        OSSO_ABOOK_CONTACT_ORDER_NAME,     /* Sort by name */
        OSSO_ABOOK_CONTACT_ORDER_PRESENCE, /* Sort by presence, then name */
        OSSO_ABOOK_CONTACT_ORDER_CUSTOM,
} OssoABookContactOrder;

The sorting modes of a OssoABookListStore.

OSSO_ABOOK_CONTACT_ORDER_NONE Don't sort at all.
OSSO_ABOOK_CONTACT_ORDER_NAME Sort by (display) name.
OSSO_ABOOK_CONTACT_ORDER_PRESENCE Sort by presence, then name.
OSSO_ABOOK_CONTACT_ORDER_CUSTOM Use custom OssoABookListStoreCompareFunc for sorting.

enum OssoABookNameOrder

typedef enum {
        OSSO_ABOOK_NAME_ORDER_FIRST,
        OSSO_ABOOK_NAME_ORDER_LAST,
        OSSO_ABOOK_NAME_ORDER_LAST_SPACE,
        OSSO_ABOOK_NAME_ORDER_NICK,
} OssoABookNameOrder;

Preferred order for name components for sorting and display.

OSSO_ABOOK_NAME_ORDER_FIRST Display given name first
OSSO_ABOOK_NAME_ORDER_LAST Display family name first, separated by comma
OSSO_ABOOK_NAME_ORDER_LAST_SPACE Display family name first, separated by space
OSSO_ABOOK_NAME_ORDER_NICK Display nickname only

osso_abook_get_gconf_client ()

GConfClient*        osso_abook_get_gconf_client         (void);

Retrieves the GConf client used by the library.


osso_abook_settings_get_contact_order ()

OssoABookContactOrder osso_abook_settings_get_contact_order
                                                        (void);

Retrieves the stored sort key for OssoABookListStore.


osso_abook_settings_get_home_applets ()

GSList*             osso_abook_settings_get_home_applets
                                                        (void);

Gets the list of contacts to be displayed as shortcuts on the desktop. Third-party applications should not generally need to use this function. Use osso_abook_contact_shortcut_exists() to check whether a particular contact already is in the list.

Returns : An allocated list of strings representing contacts that are displayed on the desktop. The list and its contents should be freed when no longer needed.

osso_abook_settings_get_name_order ()

OssoABookNameOrder  osso_abook_settings_get_name_order  (void);

Retrieves the stored display name format for contacts in the addressbook


osso_abook_settings_get_picture_folder ()

const char*         osso_abook_settings_get_picture_folder
                                                        (void);

Find the prefered picuture folder. First checks the Camera application's settings and resorts to the safe image folder if the camera folder is not available.

Returns : The path of the prefered image folder when available, and NULL otherwise. This string is owned by the library and must not be freed.

osso_abook_settings_set_contact_order ()

gboolean            osso_abook_settings_set_contact_order
                                                        (OssoABookContactOrder order);

Sets up the sort key for OssoABookListStore.

mode : OssoABookContactOrder
Returns : TRUE if the operation was successful, FALSE otherwise.

osso_abook_settings_set_home_applets ()

gboolean            osso_abook_settings_set_home_applets
                                                        (GSList *list);

Sets the list of contacts to displayed as shortcuts on the desktop. Third-party applications should not need to use this function, use osso_abook_contact_shortcut_create() instead.

Returns : TRUE if successful, else FALSE

osso_abook_settings_set_name_order ()

gboolean            osso_abook_settings_set_name_order  (OssoABookNameOrder order);

Sets up the display name format for contacts in the addressbook

order : OssoABookNameOrder
Returns : TRUE if the operation was successful, FALSE otherwise.

osso_abook_settings_get_self_avatar_imported ()

gboolean            osso_abook_settings_get_self_avatar_imported
                                                        (void);

Warning

osso_abook_settings_get_self_avatar_imported is deprecated and should not be used in newly-written code.


osso_abook_settings_set_self_avatar_imported ()

gboolean            osso_abook_settings_set_self_avatar_imported
                                                        (gboolean imported);

Warning

osso_abook_settings_set_self_avatar_imported is deprecated and should not be used in newly-written code.