aboutsummaryrefslogtreecommitdiffstats
path: root/composer/e-composer-name-header.c
diff options
context:
space:
mode:
authorMilan Crha <mcrha@redhat.com>2011-02-25 23:20:41 +0800
committerRodrigo Moya <rodrigo@gnome-db.org>2011-06-30 00:41:39 +0800
commitc003c99a75587ba39a45d164272760c33f9666b5 (patch)
treead6d0583fa9e8f078fb1c118f994371d2f1f79d8 /composer/e-composer-name-header.c
parentf55aaa5e00a40a137f403a8d5c68dd508059b0b4 (diff)
downloadgsoc2013-evolution-c003c99a75587ba39a45d164272760c33f9666b5.tar
gsoc2013-evolution-c003c99a75587ba39a45d164272760c33f9666b5.tar.gz
gsoc2013-evolution-c003c99a75587ba39a45d164272760c33f9666b5.tar.bz2
gsoc2013-evolution-c003c99a75587ba39a45d164272760c33f9666b5.tar.lz
gsoc2013-evolution-c003c99a75587ba39a45d164272760c33f9666b5.tar.xz
gsoc2013-evolution-c003c99a75587ba39a45d164272760c33f9666b5.tar.zst
gsoc2013-evolution-c003c99a75587ba39a45d164272760c33f9666b5.zip
Bug #614480 - Avoid using G_TYPE_INSTANCE_GET_PRIVATE repeatedly
Diffstat (limited to 'composer/e-composer-name-header.c')
-rw-r--r--composer/e-composer-name-header.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/composer/e-composer-name-header.c b/composer/e-composer-name-header.c
index 057266c707..a8cdc6fca4 100644
--- a/composer/e-composer-name-header.c
+++ b/composer/e-composer-name-header.c
@@ -27,10 +27,6 @@
#include "addressbook/gui/contact-editor/e-contact-editor.h"
#include "addressbook/gui/contact-list-editor/e-contact-list-editor.h"
-#define E_COMPOSER_NAME_HEADER_GET_PRIVATE(obj) \
- (G_TYPE_INSTANCE_GET_PRIVATE \
- ((obj), E_TYPE_COMPOSER_NAME_HEADER, EComposerNameHeaderPrivate))
-
/* Convenience macro */
#define E_COMPOSER_NAME_HEADER_GET_ENTRY(header) \
(E_NAME_SELECTOR_ENTRY (E_COMPOSER_HEADER (header)->input_widget))
@@ -123,7 +119,7 @@ composer_name_header_constructor (GType type,
e_composer_name_header_parent_class)->constructor (
type, n_construct_properties, construct_properties);
- priv = E_COMPOSER_NAME_HEADER_GET_PRIVATE (object);
+ priv = E_COMPOSER_NAME_HEADER (object)->priv;
g_assert (E_IS_NAME_SELECTOR (priv->name_selector));
model = e_name_selector_peek_model (priv->name_selector);
@@ -171,7 +167,7 @@ composer_name_header_set_property (GObject *object,
{
EComposerNameHeaderPrivate *priv;
- priv = E_COMPOSER_NAME_HEADER_GET_PRIVATE (object);
+ priv = E_COMPOSER_NAME_HEADER (object)->priv;
switch (property_id) {
case PROP_NAME_SELECTOR: /* construct only */
@@ -206,7 +202,7 @@ composer_name_header_dispose (GObject *object)
{
EComposerNameHeaderPrivate *priv;
- priv = E_COMPOSER_NAME_HEADER_GET_PRIVATE (object);
+ priv = E_COMPOSER_NAME_HEADER (object)->priv;
if (priv->name_selector != NULL) {
g_object_unref (priv->name_selector);
@@ -223,7 +219,7 @@ composer_name_header_clicked (EComposerHeader *header)
EComposerNameHeaderPrivate *priv;
ENameSelectorDialog *dialog;
- priv = E_COMPOSER_NAME_HEADER_GET_PRIVATE (header);
+ priv = E_COMPOSER_NAME_HEADER (header)->priv;
dialog = e_name_selector_peek_dialog (priv->name_selector);
e_name_selector_dialog_set_destination_index (
@@ -265,7 +261,7 @@ e_composer_name_header_class_init (EComposerNameHeaderClass *class)
static void
e_composer_name_header_init (EComposerNameHeader *header)
{
- header->priv = E_COMPOSER_NAME_HEADER_GET_PRIVATE (header);
+ header->priv = G_TYPE_INSTANCE_GET_PRIVATE (header, E_TYPE_COMPOSER_NAME_HEADER, EComposerNameHeaderPrivate);
}
EComposerHeader *