diff options
author | Milan Crha <mcrha@redhat.com> | 2011-02-25 23:20:41 +0800 |
---|---|---|
committer | Rodrigo Moya <rodrigo@gnome-db.org> | 2011-06-30 00:41:39 +0800 |
commit | c003c99a75587ba39a45d164272760c33f9666b5 (patch) | |
tree | ad6d0583fa9e8f078fb1c118f994371d2f1f79d8 /modules/addressbook/e-book-shell-backend.c | |
parent | f55aaa5e00a40a137f403a8d5c68dd508059b0b4 (diff) | |
download | gsoc2013-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 'modules/addressbook/e-book-shell-backend.c')
-rw-r--r-- | modules/addressbook/e-book-shell-backend.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/modules/addressbook/e-book-shell-backend.c b/modules/addressbook/e-book-shell-backend.c index 02d16d640b..b76764c81d 100644 --- a/modules/addressbook/e-book-shell-backend.c +++ b/modules/addressbook/e-book-shell-backend.c @@ -54,10 +54,6 @@ #include "smime/gui/certificate-manager.h" #endif -#define E_BOOK_SHELL_BACKEND_GET_PRIVATE(obj) \ - (G_TYPE_INSTANCE_GET_PRIVATE \ - ((obj), E_TYPE_BOOK_SHELL_BACKEND, EBookShellBackendPrivate)) - struct _EBookShellBackendPrivate { ESourceList *source_list; }; @@ -85,7 +81,7 @@ book_shell_backend_ensure_sources (EShellBackend *shell_backend) on_this_computer = NULL; personal = NULL; - priv = E_BOOK_SHELL_BACKEND_GET_PRIVATE (shell_backend); + priv = E_BOOK_SHELL_BACKEND (shell_backend)->priv; if (!e_book_get_addressbooks (&priv->source_list, NULL)) { g_warning ("Could not get addressbook sources from GConf!"); @@ -458,7 +454,7 @@ book_shell_backend_dispose (GObject *object) { EBookShellBackendPrivate *priv; - priv = E_BOOK_SHELL_BACKEND_GET_PRIVATE (object); + priv = E_BOOK_SHELL_BACKEND (object)->priv; if (priv->source_list != NULL) { g_object_unref (priv->source_list); @@ -553,8 +549,7 @@ book_shell_backend_class_init (EBookShellBackendClass *class) static void book_shell_backend_init (EBookShellBackend *book_shell_backend) { - book_shell_backend->priv = - E_BOOK_SHELL_BACKEND_GET_PRIVATE (book_shell_backend); + book_shell_backend->priv = G_TYPE_INSTANCE_GET_PRIVATE (book_shell_backend, E_TYPE_BOOK_SHELL_BACKEND, EBookShellBackendPrivate); } GType |