[gnome-photos] embed: Connect to the "query-error" signal
- From: Debarshi Ray <debarshir src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-photos] embed: Connect to the "query-error" signal
- Date: Tue, 13 Nov 2012 01:06:20 +0000 (UTC)
commit 058ac2a128e0865b405daf6853ce70bb8a6af7bb
Author: Debarshi Ray <debarshir gnome org>
Date: Tue Nov 13 01:50:30 2012 +0100
embed: Connect to the "query-error" signal
src/photos-embed.c | 28 ++++++++++++++++++----------
1 files changed, 18 insertions(+), 10 deletions(-)
---
diff --git a/src/photos-embed.c b/src/photos-embed.c
index 1753163..f33d14b 100644
--- a/src/photos-embed.c
+++ b/src/photos-embed.c
@@ -173,6 +173,23 @@ photos_embed_prepare_for_preview (PhotosEmbed *self)
void
+photos_embed_set_error (PhotosEmbed *self, const gchar *primary, const gchar *secondary)
+{
+ PhotosEmbedPrivate *priv = self->priv;
+
+ photos_error_box_update (PHOTOS_ERROR_BOX (priv->error_box), primary, secondary);
+ photos_error_box_move_in (PHOTOS_ERROR_BOX (priv->error_box));
+}
+
+
+static void
+photos_embed_query_error (PhotosEmbed *self, const gchar *primary, const gchar *secondary)
+{
+ photos_embed_set_error (self, primary, secondary);
+}
+
+
+void
photos_embed_query_status_changed (PhotosTrackerController *trk_cntrlr, gboolean querying, gpointer user_data)
{
PhotosEmbed *self = PHOTOS_EMBED (user_data);
@@ -188,16 +205,6 @@ photos_embed_query_status_changed (PhotosTrackerController *trk_cntrlr, gboolean
}
-void
-photos_embed_set_error (PhotosEmbed *self, const gchar *primary, const gchar *secondary)
-{
- PhotosEmbedPrivate *priv = self->priv;
-
- photos_error_box_update (PHOTOS_ERROR_BOX (priv->error_box), primary, secondary);
- photos_error_box_move_in (PHOTOS_ERROR_BOX (priv->error_box));
-}
-
-
static void
photos_embed_window_mode_change_flash_completed (PhotosEmbed *self)
{
@@ -353,6 +360,7 @@ photos_embed_init (PhotosEmbed *self)
self);
priv->trk_cntrlr = photos_tracker_controller_new ();
+ g_signal_connect_swapped (priv->trk_cntrlr, "query-error", G_CALLBACK (photos_embed_query_error), self);
g_signal_connect (priv->trk_cntrlr,
"query-status-changed",
G_CALLBACK (photos_embed_query_status_changed),
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]