1
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
6
* Copyright (C) 2010 Free Software Foundation, Inc.
8
* This program is free software; you can redistribute it and/or modify
9
* it under the terms of the GNU General Public License as published by
10
* the Free Software Foundation; either version 2 of the License, or
11
* (at your option) any later version.
13
* This program is distributed in the hope that it will be useful,
14
* but WITHOUT ANY WARRANTY; without even the implied warranty of
15
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
* GNU General Public License for more details.
18
* You should have received a copy of the GNU General Public License
19
* along with this program. If not, see <http://www.gnu.org/licenses/>.
22
#ifndef FLICKR_AUTHENTICATION_H
23
#define FLICKR_AUTHENTICATION_H
26
#include <glib-object.h>
27
#include "flickr-account.h"
28
#include "flickr-connection.h"
29
#include "flickr-service.h"
30
#include "flickr-user.h"
34
#define FLICKR_TYPE_AUTHENTICATION (flickr_authentication_get_type ())
35
#define FLICKR_AUTHENTICATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), FLICKR_TYPE_AUTHENTICATION, FlickrAuthentication))
36
#define FLICKR_AUTHENTICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), FLICKR_TYPE_AUTHENTICATION, FlickrAuthenticationClass))
37
#define FLICKR_IS_AUTHENTICATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), FLICKR_TYPE_AUTHENTICATION))
38
#define FLICKR_IS_AUTHENTICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), FLICKR_TYPE_AUTHENTICATION))
39
#define FLICKR_AUTHENTICATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), FLICKR_TYPE_AUTHENTICATION, FlickrAuthenticationClass))
41
typedef struct _FlickrAuthentication FlickrAuthentication;
42
typedef struct _FlickrAuthenticationClass FlickrAuthenticationClass;
43
typedef struct _FlickrAuthenticationPrivate FlickrAuthenticationPrivate;
45
struct _FlickrAuthentication {
46
GObject parent_instance;
47
FlickrAuthenticationPrivate *priv;
50
struct _FlickrAuthenticationClass {
51
GObjectClass parent_class;
55
void (*ready) (FlickrAuthentication *auth,
57
void (*accounts_changed) (FlickrAuthentication *auth);
60
GType flickr_authentication_get_type (void);
61
FlickrAuthentication * flickr_authentication_new (FlickrConnection *conn,
62
FlickrService *service,
63
GCancellable *cancellable,
66
void flickr_authentication_auto_connect (FlickrAuthentication *auth);
67
void flickr_authentication_connect (FlickrAuthentication *auth,
68
FlickrAccount *account);
69
FlickrAccount * flickr_authentication_get_account (FlickrAuthentication *auth);
70
GList * flickr_authentication_get_accounts (FlickrAuthentication *auth);
71
void flickr_authentication_edit_accounts (FlickrAuthentication *auth,
76
#endif /* FLICKR_AUTHENTICATION_H */