diff options
author | Milan Crha <mcrha@redhat.com> | 2011-02-25 23:20:41 +0800 |
---|---|---|
committer | Milan Crha <mcrha@redhat.com> | 2011-02-25 23:20:41 +0800 |
commit | 1301cf02efdacd20fb5ce3e2554ae15b8f146e8a (patch) | |
tree | 8d5f3985a82ec7d330af27ee0a29a79a2f0ecfa3 /calendar/gui/dialogs/memo-editor.c | |
parent | 1a4be6c521d674c4a60e54203521e2721b81b921 (diff) | |
download | gsoc2013-evolution-1301cf02efdacd20fb5ce3e2554ae15b8f146e8a.tar gsoc2013-evolution-1301cf02efdacd20fb5ce3e2554ae15b8f146e8a.tar.gz gsoc2013-evolution-1301cf02efdacd20fb5ce3e2554ae15b8f146e8a.tar.bz2 gsoc2013-evolution-1301cf02efdacd20fb5ce3e2554ae15b8f146e8a.tar.lz gsoc2013-evolution-1301cf02efdacd20fb5ce3e2554ae15b8f146e8a.tar.xz gsoc2013-evolution-1301cf02efdacd20fb5ce3e2554ae15b8f146e8a.tar.zst gsoc2013-evolution-1301cf02efdacd20fb5ce3e2554ae15b8f146e8a.zip |
Bug #614480 - Avoid using G_TYPE_INSTANCE_GET_PRIVATE repeatedly
Diffstat (limited to 'calendar/gui/dialogs/memo-editor.c')
-rw-r--r-- | calendar/gui/dialogs/memo-editor.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/calendar/gui/dialogs/memo-editor.c b/calendar/gui/dialogs/memo-editor.c index 0e3cfc5dcf..50f862aa7a 100644 --- a/calendar/gui/dialogs/memo-editor.c +++ b/calendar/gui/dialogs/memo-editor.c @@ -38,10 +38,6 @@ #include "cancel-comp.h" #include "memo-editor.h" -#define MEMO_EDITOR_GET_PRIVATE(obj) \ - (G_TYPE_INSTANCE_GET_PRIVATE \ - ((obj), TYPE_MEMO_EDITOR, MemoEditorPrivate)) - struct _MemoEditorPrivate { MemoPage *memo_page; @@ -73,7 +69,7 @@ memo_editor_show_categories (CompEditor *editor, { MemoEditorPrivate *priv; - priv = MEMO_EDITOR_GET_PRIVATE (editor); + priv = MEMO_EDITOR (editor)->priv; memo_page_set_show_categories (priv->memo_page, visible); } @@ -83,7 +79,7 @@ memo_editor_dispose (GObject *object) { MemoEditorPrivate *priv; - priv = MEMO_EDITOR_GET_PRIVATE (object); + priv = MEMO_EDITOR (object)->priv; if (priv->memo_page) { g_object_unref (priv->memo_page); @@ -100,7 +96,7 @@ memo_editor_constructed (GObject *object) MemoEditorPrivate *priv; CompEditor *editor; - priv = MEMO_EDITOR_GET_PRIVATE (object); + priv = MEMO_EDITOR (object)->priv; editor = COMP_EDITOR (object); priv->memo_page = memo_page_new (editor); @@ -140,7 +136,7 @@ memo_editor_init (MemoEditor *me) const gchar *id; GError *error = NULL; - me->priv = MEMO_EDITOR_GET_PRIVATE (me); + me->priv = G_TYPE_INSTANCE_GET_PRIVATE (me, TYPE_MEMO_EDITOR, MemoEditorPrivate); me->priv->updating = FALSE; ui_manager = comp_editor_get_ui_manager (editor); |