[tracker/nautilus-extension: 6/7] Fixed indentation, braces, etc..



commit cfec6267d5dae75170f1b727737e89321935529f
Author: Debarshi Ray <debarshir src gnome org>
Date:   Thu Dec 10 02:12:14 2009 +0200

    Fixed indentation, braces, etc..

 src/plugins/nautilus/tracker-tags-add-dialog.c |   10 ++-
 src/plugins/nautilus/tracker-tags-add-dialog.h |   22 +++---
 src/plugins/nautilus/tracker-tags-extension.c  |   86 ++++++++++++++---------
 src/plugins/nautilus/tracker-tags-utils.h      |    4 +-
 src/plugins/nautilus/tracker-tags-view.c       |   45 +++++++++---
 src/plugins/nautilus/tracker-tags-view.h       |   20 +++---
 6 files changed, 112 insertions(+), 75 deletions(-)
---
diff --git a/src/plugins/nautilus/tracker-tags-add-dialog.c b/src/plugins/nautilus/tracker-tags-add-dialog.c
index 6b0b442..8af3daa 100644
--- a/src/plugins/nautilus/tracker-tags-add-dialog.c
+++ b/src/plugins/nautilus/tracker-tags-add-dialog.c
@@ -21,9 +21,8 @@
 
 #include "tracker-tags-add-dialog.h"
 
-struct _TrackerTagsAddDialogPrivate
-{
-	GtkWidget	*entry;
+struct _TrackerTagsAddDialogPrivate {
+	GtkWidget      *entry;
 };
 
 G_DEFINE_TYPE (TrackerTagsAddDialog, tracker_tags_add_dialog, GTK_TYPE_DIALOG)
@@ -113,7 +112,10 @@ tracker_tags_add_dialog_init (TrackerTagsAddDialog *add_dialog)
 
 	add_dialog->priv->entry = gtk_entry_new ();
 	gtk_box_pack_start (GTK_BOX (hbox), add_dialog->priv->entry, TRUE, TRUE, 0);
-	g_signal_connect (add_dialog->priv->entry, "changed", G_CALLBACK (tracker_tags_add_dialog_entry_changed_cb), add_dialog);
+	g_signal_connect (add_dialog->priv->entry,
+                          "changed",
+                          G_CALLBACK (tracker_tags_add_dialog_entry_changed_cb),
+                          add_dialog);
 
 	gtk_widget_show_all (vbox);
 }
diff --git a/src/plugins/nautilus/tracker-tags-add-dialog.h b/src/plugins/nautilus/tracker-tags-add-dialog.h
index bc813e5..2743401 100644
--- a/src/plugins/nautilus/tracker-tags-add-dialog.h
+++ b/src/plugins/nautilus/tracker-tags-add-dialog.h
@@ -28,26 +28,24 @@
 #define TRACKER_IS_TAGS_ADD_DIALOG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_TYPE_TAGS_ADD_DIALOG))
 #define TRACKER_IS_TAGS_ADD_DIALOG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_TYPE_TAGS_ADD_DIALOG))
 
-typedef struct _TrackerTagsAddDialogPrivate	TrackerTagsAddDialogPrivate;
+typedef struct _TrackerTagsAddDialogPrivate    TrackerTagsAddDialogPrivate;
 
-typedef struct _TrackerTagsAddDialog		TrackerTagsAddDialog;
-typedef struct _TrackerTagsAddDialogClass	TrackerTagsAddDialogClass;
+typedef struct _TrackerTagsAddDialog           TrackerTagsAddDialog;
+typedef struct _TrackerTagsAddDialogClass      TrackerTagsAddDialogClass;
 
-struct _TrackerTagsAddDialog
-{
-	GtkDialog parent;
+struct _TrackerTagsAddDialog {
+	GtkDialog                   parent;
 	TrackerTagsAddDialogPrivate *priv;
 };
 
-struct _TrackerTagsAddDialogClass
-{
+struct _TrackerTagsAddDialogClass {
 	GtkDialogClass parent;
 };
 
-GType	tracker_tags_add_dialog_get_type	(void);
-void	tracker_tags_add_dialog_register_type	(GTypeModule *module);
+GType   tracker_tags_add_dialog_get_type        (void);
+void    tracker_tags_add_dialog_register_type   (GTypeModule *module);
 
-GtkWidget	*tracker_tags_add_dialog_new		(void);
-const gchar	*tracker_tags_add_dialog_get_text	(TrackerTagsAddDialog *add_dialog);
+GtkWidget   *tracker_tags_add_dialog_new          (void);
+const gchar *tracker_tags_add_dialog_get_text     (TrackerTagsAddDialog *add_dialog);
 
 #endif /* TRACKER_TAGS_ADD_DIALOG_H */
diff --git a/src/plugins/nautilus/tracker-tags-extension.c b/src/plugins/nautilus/tracker-tags-extension.c
index 778b2a7..d55eec9 100644
--- a/src/plugins/nautilus/tracker-tags-extension.c
+++ b/src/plugins/nautilus/tracker-tags-extension.c
@@ -33,35 +33,32 @@
 #define TRACKER_IS_TAGS_EXTENSION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_TYPE_TAGS_EXTENSION))
 #define TRACKER_IS_TAGS_EXTENSION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_TYPE_TAGS_EXTENSION))
 
-typedef struct _TrackerTagsExtensionPrivate	TrackerTagsExtensionPrivate;
+typedef struct _TrackerTagsExtensionPrivate    TrackerTagsExtensionPrivate;
 
-typedef struct _TrackerTagsExtension		TrackerTagsExtension;
-typedef struct _TrackerTagsExtensionClass		TrackerTagsExtensionClass;
+typedef struct _TrackerTagsExtension           TrackerTagsExtension;
+typedef struct _TrackerTagsExtensionClass      TrackerTagsExtensionClass;
 
-struct _TrackerTagsExtension
-{
-	GObject parent;
+struct _TrackerTagsExtension {
+	GObject                     parent;
 	TrackerTagsExtensionPrivate *priv;
 };
 
-struct _TrackerTagsExtensionClass
-{
+struct _TrackerTagsExtensionClass {
 	GObjectClass parent;
 };
 
-struct _TrackerTagsExtensionPrivate
-{
-	TrackerClient	*tracker_client;
+struct _TrackerTagsExtensionPrivate {
+	TrackerClient *tracker_client;
 };
 
-static void	tracker_tags_extension_menu_provider_iface_init	(NautilusMenuProviderIface *iface);
-static void	tracker_tags_extension_property_page_provider_iface_init	(NautilusPropertyPageProviderIface *iface);
+static void tracker_tags_extension_menu_provider_iface_init (NautilusMenuProviderIface *iface);
+static void tracker_tags_extension_property_page_provider_iface_init (NautilusPropertyPageProviderIface *iface);
 
 G_DEFINE_DYNAMIC_TYPE_EXTENDED (TrackerTagsExtension, tracker_tags_extension, G_TYPE_OBJECT, 0,
-				G_IMPLEMENT_INTERFACE (NAUTILUS_TYPE_MENU_PROVIDER,
-						       tracker_tags_extension_menu_provider_iface_init)
-				G_IMPLEMENT_INTERFACE (NAUTILUS_TYPE_PROPERTY_PAGE_PROVIDER,
-						       tracker_tags_extension_property_page_provider_iface_init));
+                                G_IMPLEMENT_INTERFACE (NAUTILUS_TYPE_MENU_PROVIDER,
+                                                       tracker_tags_extension_menu_provider_iface_init)
+                                G_IMPLEMENT_INTERFACE (NAUTILUS_TYPE_PROPERTY_PAGE_PROVIDER,
+                                                       tracker_tags_extension_property_page_provider_iface_init));
 
 #define TRACKER_TAGS_EXTENSION_GET_PRIVATE(obj) (G_TYPE_INSTANCE_GET_PRIVATE((obj), TRACKER_TYPE_TAGS_EXTENSION, TrackerTagsExtensionPrivate))
 
@@ -74,7 +71,12 @@ tracker_tags_extension_update_finished (GError *error, gpointer user_data)
 		{
 			GtkWidget *error_dialog;
 
-			error_dialog = gtk_message_dialog_new (NULL, GTK_DIALOG_NO_SEPARATOR, GTK_MESSAGE_ERROR, GTK_BUTTONS_OK, "%s", error->message);
+			error_dialog = gtk_message_dialog_new (NULL,
+                                                               GTK_DIALOG_NO_SEPARATOR,
+                                                               GTK_MESSAGE_ERROR,
+                                                               GTK_BUTTONS_OK,
+                                                               "%s",
+                                                               error->message);
 			g_signal_connect (error_dialog, "response", G_CALLBACK (gtk_widget_destroy), NULL);
 			gtk_dialog_run (GTK_DIALOG (error_dialog));
 		}
@@ -100,7 +102,10 @@ tracker_tags_extension_add_dialog_response_cb (GtkDialog *dialog, gint response_
 
 		tag_label = tracker_tags_add_dialog_get_text (TRACKER_TAGS_ADD_DIALOG (dialog));
 		query = tracker_tags_utils_add_query (tag_label);
-		tracker_resources_sparql_update_async (extension->priv->tracker_client, query, tracker_tags_extension_update_finished, NULL);
+		tracker_resources_sparql_update_async (extension->priv->tracker_client,
+                                                       query,
+                                                       tracker_tags_extension_update_finished,
+                                                       NULL);
 		g_free ((gpointer) query);
 		break;
 	}
@@ -140,7 +145,11 @@ tracker_tags_extension_manage_activate_cb (NautilusMenuItem *menu_item, gpointer
 
 	/* g_free (arg); */
 
-	manage_dialog = gtk_dialog_new_with_buttons (N_("Manage Tags"), window, GTK_DIALOG_MODAL | GTK_DIALOG_DESTROY_WITH_PARENT | GTK_DIALOG_NO_SEPARATOR, GTK_STOCK_CLOSE, NULL);
+	manage_dialog = gtk_dialog_new_with_buttons (N_("Manage Tags"),
+                                                     window,
+                                                     GTK_DIALOG_MODAL | GTK_DIALOG_DESTROY_WITH_PARENT | GTK_DIALOG_NO_SEPARATOR,
+                                                     GTK_STOCK_CLOSE,
+                                                     NULL);
 	gtk_container_set_border_width (GTK_CONTAINER (manage_dialog), 5);
 	gtk_window_set_default_size (GTK_WINDOW (manage_dialog), 250, 375);
 	gtk_window_set_resizable (GTK_WINDOW (manage_dialog), TRUE);
@@ -160,9 +169,9 @@ tracker_tags_extension_manage_activate_cb (NautilusMenuItem *menu_item, gpointer
 }
 
 static GList *
-tracker_tags_extension_get_background_items (NautilusMenuProvider	*provider,
-					  GtkWidget		*window,
-					  NautilusFileInfo	*current_folder)
+tracker_tags_extension_get_background_items (NautilusMenuProvider *provider,
+                                             GtkWidget            *window,
+                                             NautilusFileInfo     *current_folder)
 {
 	GList *menu_items = NULL;
 	NautilusMenuItem *menu_item;
@@ -171,7 +180,10 @@ tracker_tags_extension_get_background_items (NautilusMenuProvider	*provider,
 	if (NULL == current_folder)
 		return NULL;
 
-	menu_item = nautilus_menu_item_new ("tracker-tags-new", N_("Create Tag..."), N_("Create a new tag for this desktop"), NULL);
+	menu_item = nautilus_menu_item_new ("tracker-tags-new",
+                                            N_("Create Tag..."),
+                                            N_("Create a new tag for this desktop"),
+                                            NULL);
 	menu_items = g_list_append (menu_items, menu_item);
 	arg = g_new (void *, 2);
 	arg[0] = provider;
@@ -182,9 +194,9 @@ tracker_tags_extension_get_background_items (NautilusMenuProvider	*provider,
 }
 
 static GList *
-tracker_tags_extension_get_file_items (NautilusMenuProvider	*provider,
-				    GtkWidget			*window,
-				    GList			*files)
+tracker_tags_extension_get_file_items (NautilusMenuProvider *provider,
+                                       GtkWidget            *window,
+                                       GList                *files)
 {
 	GList *menu_items = NULL;
 	NautilusMenuItem *menu_item;
@@ -193,14 +205,20 @@ tracker_tags_extension_get_file_items (NautilusMenuProvider	*provider,
 	if (NULL == files)
 		return NULL;
 
-	menu_item = nautilus_menu_item_new ("tracker-tags-new", N_("Create Tag..."), N_("Create a new tag for this desktop"), NULL);
+	menu_item = nautilus_menu_item_new ("tracker-tags-new",
+                                            N_("Create Tag..."),
+                                            N_("Create a new tag for this desktop"),
+                                            NULL);
 	menu_items = g_list_append (menu_items, menu_item);
 	arg = g_new (void *, 2);
 	arg[0] = provider;
 	arg[1] = window;
 	g_signal_connect (menu_item, "activate", G_CALLBACK (tracker_tags_extension_add_activate_cb), arg);
 
-	menu_item = nautilus_menu_item_new ("tracker-tags-manage", N_("Manage Tags..."), N_("Change the tags attached to the selected objects"), NULL);
+	menu_item = nautilus_menu_item_new ("tracker-tags-manage",
+                                            N_("Manage Tags..."),
+                                            N_("Change the tags attached to the selected objects"),
+                                            NULL);
 	menu_items = g_list_append (menu_items, menu_item);
 	arg = g_new (void *, 2);
 	arg[0] = g_list_copy (files);
@@ -211,8 +229,8 @@ tracker_tags_extension_get_file_items (NautilusMenuProvider	*provider,
 }
 
 static GList *
-tracker_tags_extension_get_pages (NautilusPropertyPageProvider	*provider,
-			       GList				*files)
+tracker_tags_extension_get_pages (NautilusPropertyPageProvider *provider,
+                                  GList                        *files)
 {
 	GList *property_pages = NULL;
 	GtkWidget *label;
@@ -231,9 +249,9 @@ tracker_tags_extension_get_pages (NautilusPropertyPageProvider	*provider,
 }
 
 static GList *
-tracker_tags_extension_get_toolbar_items (NautilusMenuProvider	*provider,
-				       GtkWidget		*window,
-				       NautilusFileInfo		*current_folder)
+tracker_tags_extension_get_toolbar_items (NautilusMenuProvider *provider,
+                                          GtkWidget            *window,
+                                          NautilusFileInfo     *current_folder)
 {
 	return NULL;
 }
diff --git a/src/plugins/nautilus/tracker-tags-utils.h b/src/plugins/nautilus/tracker-tags-utils.h
index 8b1a599..090d1ee 100644
--- a/src/plugins/nautilus/tracker-tags-utils.h
+++ b/src/plugins/nautilus/tracker-tags-utils.h
@@ -22,7 +22,7 @@
 
 #include <glib.h>
 
-const gchar	*tracker_tags_utils_add_query	(const gchar *tag_label);
-const gchar	*tracker_tags_utils_remove_query	(const gchar *tag_label);
+const gchar     *tracker_tags_utils_add_query    (const gchar *tag_label);
+const gchar     *tracker_tags_utils_remove_query (const gchar *tag_label);
 
 #endif /* TRACKER_TAGS_UTILS_H */
diff --git a/src/plugins/nautilus/tracker-tags-view.c b/src/plugins/nautilus/tracker-tags-view.c
index d955564..2708dd4 100644
--- a/src/plugins/nautilus/tracker-tags-view.c
+++ b/src/plugins/nautilus/tracker-tags-view.c
@@ -40,13 +40,12 @@ enum
 	SELECTED_TRUE
 };
 
-struct _TrackerTagsViewPrivate
-{
-	TrackerClient	*tracker_client;
-	GList		*files;
-	GtkListStore	*list_store;
-	GtkWidget	*remove_button;
-	gchar		*selected_tag_label;
+struct _TrackerTagsViewPrivate {
+	TrackerClient   *tracker_client;
+	GList           *files;
+	GtkListStore    *list_store;
+	GtkWidget       *remove_button;
+	gchar           *selected_tag_label;
 };
 
 G_DEFINE_TYPE (TrackerTagsView, tracker_tags_view, GTK_TYPE_VBOX);
@@ -232,7 +231,10 @@ tracker_tags_view_append_foreach (gpointer data, gpointer user_data)
 	arg = g_new (void *, 2);
 	arg[0] = view;
 	arg[1] = gtk_tree_iter_copy (&iter);
-	tracker_resources_sparql_query_async (view->priv->tracker_client, query, tracker_tags_view_query_each_tag_finished, arg);
+	tracker_resources_sparql_query_async (view->priv->tracker_client,
+                                              query,
+                                              tracker_tags_view_query_each_tag_finished,
+                                              arg);
 	g_free (query);
 }
 
@@ -247,7 +249,12 @@ tracker_tags_view_query_all_tags_finished (GPtrArray *result, GError *error, gpo
 		{
 			GtkWidget *error_dialog;
 
-			error_dialog = gtk_message_dialog_new (NULL, GTK_DIALOG_NO_SEPARATOR, GTK_MESSAGE_ERROR, GTK_BUTTONS_OK, "%s", error->message);
+			error_dialog = gtk_message_dialog_new (NULL,
+                                                               GTK_DIALOG_NO_SEPARATOR,
+                                                               GTK_MESSAGE_ERROR,
+                                                               GTK_BUTTONS_OK,
+                                                               "%s",
+                                                               error->message);
 			g_signal_connect (error_dialog, "response", G_CALLBACK (gtk_widget_destroy), NULL);
 			gtk_dialog_run (GTK_DIALOG (error_dialog));
 		}
@@ -287,7 +294,12 @@ tracker_tags_view_update_finished (GError *error, gpointer user_data)
 		{
 			GtkWidget *error_dialog;
 
-			error_dialog = gtk_message_dialog_new (NULL, GTK_DIALOG_NO_SEPARATOR, GTK_MESSAGE_ERROR, GTK_BUTTONS_OK, "%s", error->message);
+			error_dialog = gtk_message_dialog_new (NULL,
+                                                               GTK_DIALOG_NO_SEPARATOR,
+                                                               GTK_MESSAGE_ERROR,
+                                                               GTK_BUTTONS_OK,
+                                                               "%s",
+                                                               error->message);
 			g_signal_connect (error_dialog, "response", G_CALLBACK (gtk_widget_destroy), NULL);
 			gtk_dialog_run (GTK_DIALOG (error_dialog));
 		}
@@ -313,7 +325,10 @@ tracker_tags_view_add_dialog_response_cb (GtkDialog *dialog, gint response_id, g
 
 		tag_label = tracker_tags_add_dialog_get_text (TRACKER_TAGS_ADD_DIALOG (dialog));
 		query = tracker_tags_utils_add_query (tag_label);
-		tracker_resources_sparql_update_async (view->priv->tracker_client, query, tracker_tags_view_update_finished, NULL);
+		tracker_resources_sparql_update_async (view->priv->tracker_client,
+                                                       query,
+                                                       tracker_tags_view_update_finished,
+                                                       NULL);
 		g_free ((gpointer) query);
 		break;
 	}
@@ -377,7 +392,13 @@ tracker_tags_view_row_activated_cb (GtkTreeView *tree_view, GtkTreePath *path, G
 	if (FALSE == gtk_tree_model_get_iter (tree_model, &iter, path))
 		return;
 
-	gtk_tree_model_get (tree_model, &iter, COLUMN_SELECTED, &selected, COLUMN_TAG_NAME, &view->priv->selected_tag_label, -1);
+	gtk_tree_model_get (tree_model,
+                            &iter,
+                            COLUMN_SELECTED,
+                            &selected,
+                            COLUMN_TAG_NAME,
+                            &view->priv->selected_tag_label,
+                            -1);
 	selected = (SELECTED_FALSE == selected) ? SELECTED_TRUE : SELECTED_FALSE;
 	gtk_list_store_set (view->priv->list_store, &iter, COLUMN_SELECTED, selected, -1);
 
diff --git a/src/plugins/nautilus/tracker-tags-view.h b/src/plugins/nautilus/tracker-tags-view.h
index b12810b..150bf7f 100644
--- a/src/plugins/nautilus/tracker-tags-view.h
+++ b/src/plugins/nautilus/tracker-tags-view.h
@@ -28,25 +28,23 @@
 #define TRACKER_IS_TAGS_VIEW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_TYPE_TAGS_VIEW))
 #define TRACKER_IS_TAGS_VIEW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_TYPE_TAGS_VIEW))
 
-typedef struct _TrackerTagsViewPrivate	TrackerTagsViewPrivate;
+typedef struct _TrackerTagsViewPrivate  TrackerTagsViewPrivate;
 
-typedef struct _TrackerTagsView		TrackerTagsView;
-typedef struct _TrackerTagsViewClass	TrackerTagsViewClass;
+typedef struct _TrackerTagsView         TrackerTagsView;
+typedef struct _TrackerTagsViewClass    TrackerTagsViewClass;
 
-struct _TrackerTagsView
-{
-	GtkVBox parent;
+struct _TrackerTagsView {
+	GtkVBox                parent;
 	TrackerTagsViewPrivate *priv;
 };
 
-struct _TrackerTagsViewClass
-{
+struct _TrackerTagsViewClass {
 	GtkVBoxClass parent;
 };
 
-GType	tracker_tags_view_get_type	(void);
-void	tracker_tags_view_register_type	(GTypeModule *module);
+GType   tracker_tags_view_get_type      (void);
+void    tracker_tags_view_register_type (GTypeModule *module);
 
-GtkWidget	*tracker_tags_view_new	(GList *files);
+GtkWidget *tracker_tags_view_new        (GList *files);
 
 #endif /* TRACKER_TAGS_VIEW_H */



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