aboutsummaryrefslogtreecommitdiffstats
path: root/e-util
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2010-01-03 12:46:23 +0800
committerMatthew Barnes <mbarnes@redhat.com>2010-01-04 02:15:01 +0800
commite77ee5d5d38ad95bce550db62bf4105f43cf88c6 (patch)
tree3b4c275b086d3f49360c551e686f62140a8ee4d4 /e-util
parent3cfd5d640908b6441769341c764de70006262c6e (diff)
downloadgsoc2013-evolution-e77ee5d5d38ad95bce550db62bf4105f43cf88c6.tar
gsoc2013-evolution-e77ee5d5d38ad95bce550db62bf4105f43cf88c6.tar.gz
gsoc2013-evolution-e77ee5d5d38ad95bce550db62bf4105f43cf88c6.tar.bz2
gsoc2013-evolution-e77ee5d5d38ad95bce550db62bf4105f43cf88c6.tar.lz
gsoc2013-evolution-e77ee5d5d38ad95bce550db62bf4105f43cf88c6.tar.xz
gsoc2013-evolution-e77ee5d5d38ad95bce550db62bf4105f43cf88c6.tar.zst
gsoc2013-evolution-e77ee5d5d38ad95bce550db62bf4105f43cf88c6.zip
Coding style and whitespace cleanup.
Diffstat (limited to 'e-util')
-rw-r--r--e-util/e-pilot-map.c10
-rw-r--r--e-util/e-plugin.c16
-rw-r--r--e-util/e-unicode.c3
-rw-r--r--e-util/gconf-bridge.c64
4 files changed, 61 insertions, 32 deletions
diff --git a/e-util/e-pilot-map.c b/e-util/e-pilot-map.c
index 83517197fd..e557388352 100644
--- a/e-util/e-pilot-map.c
+++ b/e-util/e-pilot-map.c
@@ -53,7 +53,11 @@ typedef struct
} EPilotMapWriteData;
static void
-real_e_pilot_map_insert (EPilotMap *map, guint32 pid, const gchar *uid, gboolean archived, gboolean touch)
+real_e_pilot_map_insert (EPilotMap *map,
+ guint32 pid,
+ const gchar *uid,
+ gboolean archived,
+ gboolean touch)
{
gchar *new_uid;
guint32 *new_pid = NULL;
@@ -371,7 +375,9 @@ e_pilot_map_write (const gchar *filename, EPilotMap *map)
g_warning ("Pilot map file could not be created\n");
return -1;
}
- xmlDocSetRootElement (doc, xmlNewDocNode(doc, NULL, (const guchar *)"PilotMap", NULL));
+ xmlDocSetRootElement (
+ doc, xmlNewDocNode (
+ doc, NULL, (const guchar *)"PilotMap", NULL));
map->since = time (NULL);
map_set_node_timet (xmlDocGetRootElement (doc), "timestamp", map->since);
diff --git a/e-util/e-plugin.c b/e-util/e-plugin.c
index dff49d4e3f..82437e8bb4 100644
--- a/e-util/e-plugin.c
+++ b/e-util/e-plugin.c
@@ -163,7 +163,10 @@ ep_construct (EPlugin *ep, xmlNodePtr root)
gchar *class = e_plugin_xml_prop(node, "class");
if (class == NULL) {
- g_warning("Plugin '%s' load failed in '%s', missing class property for hook", ep->id, ep->path);
+ g_warning (
+ "Plugin '%s' load failed in '%s', "
+ "missing class property for hook",
+ ep->id, ep->path);
goto fail;
}
@@ -382,7 +385,8 @@ ep_load_plugin(xmlNodePtr root, struct _plugin_doc *pdoc)
return NULL;
}
- /* If we can't find a plugin, add it to a pending list which is checked when a new type is registered */
+ /* If we can't find a plugin, add it to a pending list
+ * which is checked when a new type is registered. */
class = g_hash_table_lookup(ep_types, prop);
if (class == NULL) {
pd(printf("Delaying loading of plugin '%s' unknown type '%s'\n", id, prop));
@@ -991,7 +995,9 @@ e_plugin_hook_enable (EPluginHook *eph, gint state)
* integer values of the corresponding string id's stored in the @map.
**/
guint32
-e_plugin_hook_mask(xmlNodePtr root, const struct _EPluginHookTargetKey *map, const gchar *prop)
+e_plugin_hook_mask (xmlNodePtr root,
+ const struct _EPluginHookTargetKey *map,
+ const gchar *prop)
{
gchar *val, *p, *start, c;
guint32 mask = 0;
@@ -1042,7 +1048,9 @@ e_plugin_hook_mask(xmlNodePtr root, const struct _EPluginHookTargetKey *map, con
* integer value, if not, then ~0.
**/
guint32
-e_plugin_hook_id(xmlNodePtr root, const struct _EPluginHookTargetKey *map, const gchar *prop)
+e_plugin_hook_id (xmlNodePtr root,
+ const struct _EPluginHookTargetKey *map,
+ const gchar *prop)
{
gchar *val;
gint i;
diff --git a/e-util/e-unicode.c b/e-util/e-unicode.c
index 84c0a1d7b8..88f6d0605a 100644
--- a/e-util/e-unicode.c
+++ b/e-util/e-unicode.c
@@ -281,7 +281,8 @@ e_unicode_get_utf8 (const gchar *text, gunichar *out)
}
gchar *
-e_xml_get_translated_utf8_string_prop_by_name (const xmlNode *parent, const xmlChar *prop_name)
+e_xml_get_translated_utf8_string_prop_by_name (const xmlNode *parent,
+ const xmlChar *prop_name)
{
xmlChar *prop;
gchar *ret_val = NULL;
diff --git a/e-util/gconf-bridge.c b/e-util/gconf-bridge.c
index 8405c682ff..7f35d0b404 100644
--- a/e-util/gconf-bridge.c
+++ b/e-util/gconf-bridge.c
@@ -70,7 +70,7 @@ typedef struct {
GtkWindow *window;
gulong configure_event_id;
- gulong window_state_event_id;
+ gulong window_state_event_id;
gulong unmap_id;
guint sync_timeout_id;
} WindowBinding;
@@ -551,41 +551,55 @@ gconf_bridge_bind_property_full (GConfBridge *bridge,
}
static void
-prop_binding_block_cb (gpointer hkey, PropBinding *binding, const gchar *key)
+prop_binding_block_cb (gpointer hkey,
+ PropBinding *binding,
+ const gchar *key)
{
- g_return_if_fail (binding != NULL);
- g_return_if_fail (key != NULL);
+ g_return_if_fail (binding != NULL);
+ g_return_if_fail (key != NULL);
- if (binding->type == BINDING_PROP && binding->key && g_ascii_strcasecmp (binding->key, key) == 0)
- g_signal_handler_block (binding->object, binding->prop_notify_id);
+ if (binding->type == BINDING_PROP && binding->key &&
+ g_ascii_strcasecmp (binding->key, key) == 0)
+ g_signal_handler_block (
+ binding->object, binding->prop_notify_id);
}
static void
-prop_binding_unblock_cb (gpointer hkey, PropBinding *binding, const gchar *key)
+prop_binding_unblock_cb (gpointer hkey,
+ PropBinding *binding,
+ const gchar *key)
{
- g_return_if_fail (binding != NULL);
- g_return_if_fail (key != NULL);
+ g_return_if_fail (binding != NULL);
+ g_return_if_fail (key != NULL);
- if (binding->type == BINDING_PROP && binding->key && g_ascii_strcasecmp (binding->key, key) == 0)
- g_signal_handler_unblock (binding->object, binding->prop_notify_id);
+ if (binding->type == BINDING_PROP && binding->key &&
+ g_ascii_strcasecmp (binding->key, key) == 0)
+ g_signal_handler_unblock (
+ binding->object, binding->prop_notify_id);
}
void
-gconf_bridge_block_property_bindings (GConfBridge *bridge, const gchar *key)
+gconf_bridge_block_property_bindings (GConfBridge *bridge,
+ const gchar *key)
{
g_return_if_fail (bridge != NULL);
g_return_if_fail (key != NULL);
- g_hash_table_foreach (bridge->bindings, (GHFunc) prop_binding_block_cb, (gpointer)key);
+ g_hash_table_foreach (
+ bridge->bindings, (GHFunc)
+ prop_binding_block_cb, (gpointer)key);
}
void
-gconf_bridge_unblock_property_bindings (GConfBridge *bridge, const gchar *key)
+gconf_bridge_unblock_property_bindings (GConfBridge *bridge,
+ const gchar *key)
{
g_return_if_fail (bridge != NULL);
g_return_if_fail (key != NULL);
- g_hash_table_foreach (bridge->bindings, (GHFunc) prop_binding_unblock_cb, (gpointer)key);
+ g_hash_table_foreach (
+ bridge->bindings, (GHFunc)
+ prop_binding_unblock_cb, (gpointer)key);
}
/* Unbinds a property binding */
@@ -687,16 +701,16 @@ window_binding_configure_event_cb (GtkWindow *window,
GdkEventConfigure *event,
WindowBinding *binding)
{
- /* re-postpone by cancel of the previous request */
- if (binding->sync_timeout_id > 0)
- g_source_remove (binding->sync_timeout_id);
+ /* re-postpone by cancel of the previous request */
+ if (binding->sync_timeout_id > 0)
+ g_source_remove (binding->sync_timeout_id);
- /* Schedule a sync */
- binding->sync_timeout_id = g_timeout_add_seconds (WINDOW_BINDING_SYNC_DELAY,
- (GSourceFunc) window_binding_perform_scheduled_sync,
- binding);
+ /* Schedule a sync */
+ binding->sync_timeout_id = g_timeout_add_seconds (WINDOW_BINDING_SYNC_DELAY,
+ (GSourceFunc) window_binding_perform_scheduled_sync,
+ binding);
- return FALSE;
+ return FALSE;
}
/* Called when the window state is being changed */
@@ -897,7 +911,7 @@ window_binding_unbind (WindowBinding *binding)
g_signal_handler_disconnect (binding->window,
binding->configure_event_id);
g_signal_handler_disconnect (binding->window,
- binding->window_state_event_id);
+ binding->window_state_event_id);
g_signal_handler_disconnect (binding->window,
binding->unmap_id);
@@ -1276,7 +1290,7 @@ error_handler (GConfClient *client,
gtk_widget_destroy (dlg);
shown_dialog = TRUE;
- }
+ }
}
/**