]> git.0d.be Git - empathy.git/blob - ubuntu-online-accounts/mc-plugin/mission-control-plugin.c
Merge branch 'gnome-3-8'
[empathy.git] / ubuntu-online-accounts / mc-plugin / mission-control-plugin.c
1 /*
2  * mission-control-plugin.c
3  *
4  * A Mission Control plugin to expose Ubuntu Online Accounts with chat
5  * capabilities (e.g. Facebook) to Mission Control
6  *
7  * Copyright (C) 2012 Collabora Ltd.
8  *
9  * This library is free software; you can redistribute it and/or
10  * modify it under the terms of the GNU Lesser General Public
11  * License as published by the Free Software Foundation; either
12  * version 2.1 of the License, or (at your option) any later version.
13  *
14  * This library is distributed in the hope that it will be useful,
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
17  * Lesser General Public License for more details.
18  *
19  * You should have received a copy of the GNU Lesser General Public
20  * License along with this library; if not, see <http://www.gnu.org/licenses/>.
21  *
22  * Authors: Xavier Claessens <xavier.claessens@collabora.co.uk>
23  */
24
25 #include "config.h"
26
27 #include <mission-control-plugins/mission-control-plugins.h>
28
29 #include "mcp-account-manager-uoa.h"
30
31 GObject *
32 mcp_plugin_ref_nth_object (guint n)
33 {
34   static void *plugin_0 = NULL;
35
36   switch (n)
37     {
38       case 0:
39         if (plugin_0 == NULL)
40           plugin_0 = g_object_new (MCP_TYPE_ACCOUNT_MANAGER_UOA, NULL);
41         else
42           g_object_ref (plugin_0);
43
44         return plugin_0;
45
46       default:
47         return NULL;
48     }
49 }