| 1 |
/* cloudprovidersaccount.h |
| 2 |
* |
| 3 |
* Copyright (C) 2015 Carlos Soriano <[email protected]> |
| 4 |
* Copyright (C) 2017 Julius Haertl <[email protected]> |
| 5 |
* |
| 6 |
* This file is free software; you can redistribute it and/or modify it |
| 7 |
* under the terms of the GNU Lesser General Public License as |
| 8 |
* published by the Free Software Foundation; either version 3 of the |
| 9 |
* License, or (at your option) any later version. |
| 10 |
* |
| 11 |
* This file is distributed in the hope that it will be useful, but |
| 12 |
* WITHOUT ANY WARRANTY; without even the implied warranty of |
| 13 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 14 |
* Lesser General Public License for more details. |
| 15 |
* |
| 16 |
* You should have received a copy of the GNU General Public License |
| 17 |
* along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 18 |
*/ |
| 19 |
|
| 20 |
#ifndef CLOUD_PROVIDERS_ACCOUNT_H |
| 21 |
#define CLOUD_PROVIDERS_ACCOUNT_H |
| 22 |
|
| 23 |
#include <gio/gio.h> |
| 24 |
|
| 25 |
G_BEGIN_DECLS |
| 26 |
|
| 27 |
#define CLOUD_PROVIDERS_ACCOUNT_DBUS_IFACE "org.freedesktop.CloudProviders.Account" |
| 28 |
|
| 29 |
/** |
| 30 |
* CloudProviderStatus: |
| 31 |
* @CLOUD_PROVIDERS_ACCOUNT_STATUS_INVALID: Set if the initial state of the account is unknown |
| 32 |
* @CLOUD_PROVIDERS_ACCOUNT_STATUS_IDLE: Set if the account is in idle mode |
| 33 |
* @CLOUD_PROVIDERS_ACCOUNT_STATUS_SYNCING: Set if the account is currently synchronizing data |
| 34 |
* @CLOUD_PROVIDERS_ACCOUNT_STATUS_ERROR: Set if an error occurred |
| 35 |
* |
| 36 |
* Enum values used to describe the sync status of a cloud providers account |
| 37 |
**/ |
| 38 |
typedef enum { |
| 39 |
CLOUD_PROVIDERS_ACCOUNT_STATUS_INVALID, |
| 40 |
CLOUD_PROVIDERS_ACCOUNT_STATUS_IDLE, |
| 41 |
CLOUD_PROVIDERS_ACCOUNT_STATUS_SYNCING, |
| 42 |
CLOUD_PROVIDERS_ACCOUNT_STATUS_ERROR |
| 43 |
} CloudProvidersAccountStatus; |
| 44 |
|
| 45 |
#define CLOUD_PROVIDERS_TYPE_ACCOUNT (cloud_providers_account_get_type()) |
| 46 |
G_DECLARE_FINAL_TYPE (CloudProvidersAccount, cloud_providers_account, CLOUD_PROVIDERS, ACCOUNT, GObject) |
| 47 |
|
| 48 |
struct _CloudProvidersAccountClass |
| 49 |
{ |
| 50 |
GObjectClass parent_class; |
| 51 |
}; |
| 52 |
|
| 53 |
CloudProvidersAccount *cloud_providers_account_new (GDBusProxy *proxy); |
| 54 |
|
| 55 |
const gchar* cloud_providers_account_get_name (CloudProvidersAccount *self); |
| 56 |
CloudProvidersAccountStatus cloud_providers_account_get_status (CloudProvidersAccount *self); |
| 57 |
const gchar* cloud_providers_account_get_status_details (CloudProvidersAccount *self); |
| 58 |
GIcon *cloud_providers_account_get_icon (CloudProvidersAccount *self); |
| 59 |
GMenuModel *cloud_providers_account_get_menu_model (CloudProvidersAccount *self); |
| 60 |
GActionGroup* cloud_providers_account_get_action_group (CloudProvidersAccount *self); |
| 61 |
const gchar *cloud_providers_account_get_path (CloudProvidersAccount *self); |
| 62 |
G_END_DECLS |
| 63 |
|
| 64 |
|
| 65 |
#endif /* CLOUD_PROVIDERS_ACCOUNT_H */ |