[gnome-chat] embed: Set the avatar in the status area to be 32x32



commit 44f6bb18201a3ef6e00de0efecf5f3c525981bbf
Author: Debarshi Ray <debarshir gnome org>
Date:   Fri Sep 13 11:51:24 2013 +0200

    embed: Set the avatar in the status area to be 32x32

 src/Makefile.am      |    1 +
 src/chat-constants.h |   35 +++++++++++++++++++++++++++++++++++
 src/chat-embed.c     |    3 ++-
 3 files changed, 38 insertions(+), 1 deletions(-)
---
diff --git a/src/Makefile.am b/src/Makefile.am
index 79cba81..caee1d0 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -27,6 +27,7 @@ gnome_chat_SOURCES = \
        chat-application.h \
        chat-client-factory.c \
        chat-client-factory.h \
+       chat-constants.h \
        chat-contacts-list-dialog.c \
        chat-contacts-list-dialog.h \
        chat-conversation-view.c \
diff --git a/src/chat-constants.h b/src/chat-constants.h
new file mode 100644
index 0000000..2994cdc
--- /dev/null
+++ b/src/chat-constants.h
@@ -0,0 +1,35 @@
+/*
+ * Chat - instant messaging client for GNOME
+ * Copyright © 2013 Red Hat, Inc.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 2.1
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301, USA.
+ */
+
+
+#ifndef CHAT_CONSTANTS_H
+#define CHAT_CONSTANTS_H
+
+G_BEGIN_DECLS
+
+enum
+{
+  CHAT_SELF_AVATAR_SIZE = 32 /* pixels */
+};
+
+G_END_DECLS
+
+#endif /* CHAT_CONSTANTS_H */
+
diff --git a/src/chat-embed.c b/src/chat-embed.c
index b7f9303..ef938d6 100644
--- a/src/chat-embed.c
+++ b/src/chat-embed.c
@@ -26,6 +26,7 @@
 #include <tp-account-widgets/tpaw-avatar-chooser.h>
 
 #include "chat-application.h"
+#include "chat-constants.h"
 #include "chat-conversation-view.h"
 #include "chat-conversations-list.h"
 #include "chat-embed.h"
@@ -139,7 +140,7 @@ chat_embed_row_activated (ChatEmbed *self, GtkListBoxRow *row)
 
   if (priv->avatar_chooser != NULL)
     gtk_widget_destroy (priv->avatar_chooser);
-  priv->avatar_chooser = tpaw_avatar_chooser_new (account);
+  priv->avatar_chooser = tpaw_avatar_chooser_new (account, CHAT_SELF_AVATAR_SIZE);
   gtk_button_set_relief (GTK_BUTTON (priv->avatar_chooser), GTK_RELIEF_NONE);
   gtk_grid_attach_next_to (GTK_GRID (priv->status_area_grid0),
                            priv->avatar_chooser,


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