[gnome-photos/wip/facebook] base-item: Style fixes
- From: Álvaro Peña <alvaropg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-photos/wip/facebook] base-item: Style fixes
- Date: Fri, 22 Nov 2013 21:54:33 +0000 (UTC)
commit 904e6ca071a625f8131e55a4c84d6a2a191cdc97
Author: Debarshi Ray <debarshir gnome org>
Date: Tue Aug 20 09:36:15 2013 +0200
base-item: Style fixes
src/photos-base-item.c | 32 ++++++++++++++++----------------
src/photos-base-item.h | 1 +
2 files changed, 17 insertions(+), 16 deletions(-)
---
diff --git a/src/photos-base-item.c b/src/photos-base-item.c
index ad1be25..b20ab00 100644
--- a/src/photos-base-item.c
+++ b/src/photos-base-item.c
@@ -302,6 +302,21 @@ photos_base_item_default_open (PhotosBaseItem *self, GdkScreen *screen, guint32
static void
+photos_base_item_default_update_type_description (PhotosBaseItem *self)
+{
+ PhotosBaseItemPrivate *priv = self->priv;
+ gchar *description = NULL;
+
+ if (priv->collection)
+ description = g_strdup (_("Album"));
+ else if (priv->mime_type != NULL)
+ description = g_content_type_get_description (priv->mime_type);
+
+ priv->type_description = description;
+}
+
+
+static void
photos_base_item_download_in_thread_func (GTask *task,
gpointer source_object,
gpointer task_data,
@@ -775,21 +790,6 @@ photos_base_item_print_load (GObject *source_object, GAsyncResult *res, gpointer
static void
-photos_base_item_update_type_description (PhotosBaseItem *self)
-{
- PhotosBaseItemPrivate *priv = self->priv;
- gchar *description = NULL;
-
- if (priv->collection)
- description = g_strdup (_("Album"));
- else if (priv->mime_type != NULL)
- description = g_content_type_get_description (priv->mime_type);
-
- priv->type_description = description;
-}
-
-
-static void
photos_base_item_constructed (GObject *object)
{
PhotosBaseItem *self = PHOTOS_BASE_ITEM (object);
@@ -913,7 +913,7 @@ photos_base_item_class_init (PhotosBaseItemClass *class)
object_class->set_property = photos_base_item_set_property;
class->open = photos_base_item_default_open;
class->set_favorite = photos_base_item_default_set_favorite;
- class->update_type_description = photos_base_item_update_type_description;
+ class->update_type_description = photos_base_item_default_update_type_description;
g_object_class_install_property (object_class,
PROP_CURSOR,
diff --git a/src/photos-base-item.h b/src/photos-base-item.h
index ec3f5bd..f9325a2 100644
--- a/src/photos-base-item.h
+++ b/src/photos-base-item.h
@@ -68,6 +68,7 @@ struct _PhotosBaseItemClass
{
GObjectClass parent_class;
+ /* virtual methods */
gboolean (*create_thumbnail) (PhotosBaseItem *self, GCancellable *cancellable, GError **error);
gchar *(*download) (PhotosBaseItem *self, GCancellable *cancellable, GError **error);
const gchar *(*get_source_name) (PhotosBaseItem *self);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]