aboutsummaryrefslogtreecommitdiffstats
path: root/shell/e-shell-folder-title-bar.c
diff options
context:
space:
mode:
authorJP Rosevear <jpr@novell.com>2004-12-21 23:42:46 +0800
committerJP Rosevear <jpr@src.gnome.org>2004-12-21 23:42:46 +0800
commita0da580e7e2355b6f6e084cbd968dd6176156082 (patch)
treed902eddfe5429b7d8dc2e0fa1055f136f880561f /shell/e-shell-folder-title-bar.c
parent8cb1b7cf11da0d32a087f3f580fb76f0eb2aa212 (diff)
downloadgsoc2013-evolution-a0da580e7e2355b6f6e084cbd968dd6176156082.tar.gz
gsoc2013-evolution-a0da580e7e2355b6f6e084cbd968dd6176156082.tar.zst
gsoc2013-evolution-a0da580e7e2355b6f6e084cbd968dd6176156082.zip
Convert to G_DEFINE_TYPE
2004-12-21 JP Rosevear <jpr@novell.com> * e-corba-config-page.c: Convert to G_DEFINE_TYPE * e-history.c: ditto * e-shell-folder-title-bar.c: ditto * e-shell-offline-handler.c: ditto * e-shell-settings-dialog.c: ditto * e-shell-window.c: ditto * e-sidebar.c: ditto * e-user-creatable-items-handler.c: ditto * e-component-registry.c: ditto * importer/evolution-importer-client.c: ditto svn path=/trunk/; revision=28164
Diffstat (limited to 'shell/e-shell-folder-title-bar.c')
-rw-r--r--shell/e-shell-folder-title-bar.c22
1 files changed, 7 insertions, 15 deletions
diff --git a/shell/e-shell-folder-title-bar.c b/shell/e-shell-folder-title-bar.c
index 9871a9c1d1..c0dd2f4e6a 100644
--- a/shell/e-shell-folder-title-bar.c
+++ b/shell/e-shell-folder-title-bar.c
@@ -34,17 +34,11 @@
#include <libgnome/gnome-i18n.h>
#include <gdk-pixbuf/gdk-pixbuf.h>
-#include <gal/util/e-util.h>
-
#include "widgets/misc/e-clipped-label.h"
#include "e-shell-constants.h"
#include "e-shell-marshal.h"
#include "e-shell-folder-title-bar.h"
-
-#define PARENT_TYPE GTK_TYPE_HBOX
-static GtkHBox *parent_class = NULL;
-
struct _EShellFolderTitleBarPrivate {
GdkPixbuf *icon;
@@ -83,6 +77,8 @@ enum {
static guint signals[LAST_SIGNAL] = { 0 };
+G_DEFINE_TYPE (EShellFolderTitleBar, e_shell_folder_title_bar, GTK_TYPE_HBOX)
+
/* Utility functions for managing icons and icon widgets. */
@@ -323,7 +319,7 @@ impl_dispose (GObject *object)
priv->icon = NULL;
}
- (* G_OBJECT_CLASS (parent_class)->dispose) (object);
+ (* G_OBJECT_CLASS (e_shell_folder_title_bar_parent_class)->dispose) (object);
}
static void
@@ -337,7 +333,7 @@ impl_finalize (GObject *object)
g_free (priv);
- (* G_OBJECT_CLASS (parent_class)->finalize) (object);
+ (* G_OBJECT_CLASS (e_shell_folder_title_bar_parent_class)->finalize) (object);
}
@@ -394,14 +390,14 @@ impl_expose_event (GtkWidget *widget,
widget->allocation.width,
widget->allocation.height);
- (* GTK_WIDGET_CLASS (parent_class)->expose_event) (widget, event);
+ (* GTK_WIDGET_CLASS (e_shell_folder_title_bar_parent_class)->expose_event) (widget, event);
return FALSE;
}
static void
-class_init (EShellFolderTitleBarClass *klass)
+e_shell_folder_title_bar_class_init (EShellFolderTitleBarClass *klass)
{
GObjectClass *object_class;
GtkWidgetClass *widget_class;
@@ -414,8 +410,6 @@ class_init (EShellFolderTitleBarClass *klass)
widget_class->size_allocate = impl_size_allocate;
widget_class->expose_event = impl_expose_event;
- parent_class = g_type_class_ref(PARENT_TYPE);
-
signals[TITLE_TOGGLED]
= g_signal_new ("title_toggled",
G_OBJECT_CLASS_TYPE (object_class),
@@ -446,7 +440,7 @@ class_init (EShellFolderTitleBarClass *klass)
}
static void
-init (EShellFolderTitleBar *shell_folder_title_bar)
+e_shell_folder_title_bar_init (EShellFolderTitleBar *shell_folder_title_bar)
{
EShellFolderTitleBarPrivate *priv;
@@ -745,5 +739,3 @@ e_shell_folder_title_bar_update_navigation_buttons (EShellFolderTitleBar *folde
gtk_widget_set_sensitive (priv->forward_button, can_go_forward);
}
-
-E_MAKE_TYPE (e_shell_folder_title_bar, "EShellFolderTitleBar", EShellFolderTitleBar, class_init, init, PARENT_TYPE)