1
/* -*- Mode: C; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */
2
/* NetworkManager Wireless Applet -- Display wireless access points and allow user control
4
* This program is free software; you can redistribute it and/or modify
5
* it under the terms of the GNU General Public License as published by
6
* the Free Software Foundation; either version 2 of the License, or
7
* (at your option) any later version.
9
* This program is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU General Public License for more details.
14
* You should have received a copy of the GNU General Public License along
15
* with this program; if not, write to the Free Software Foundation, Inc.,
16
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18
* (C) Copyright 2008 Novell, Inc.
19
* (C) Copyright 2008 Red Hat, Inc.
22
#ifndef NMA_GCONF_CONNECTION_H
23
#define NMA_GCONF_CONNECTION_H
25
#include <gconf/gconf-client.h>
26
#include <dbus/dbus-glib.h>
27
#include <nm-connection.h>
28
#include <nm-exported-connection.h>
29
#include <nm-settings-connection-interface.h>
33
#define NMA_TYPE_GCONF_CONNECTION (nma_gconf_connection_get_type ())
34
#define NMA_GCONF_CONNECTION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), NMA_TYPE_GCONF_CONNECTION, NMAGConfConnection))
35
#define NMA_GCONF_CONNECTION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), NMA_TYPE_GCONF_CONNECTION, NMAGConfConnectionClass))
36
#define NMA_IS_GCONF_CONNECTION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), NMA_TYPE_GCONF_CONNECTION))
37
#define NMA_IS_GCONF_CONNECTION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((obj), NMA_TYPE_GCONF_CONNECTION))
38
#define NMA_GCONF_CONNECTION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), NMA_TYPE_GCONF_CONNECTION, NMAGConfConnectionClass))
40
#define NMA_GCONF_CONNECTION_CLIENT "client"
41
#define NMA_GCONF_CONNECTION_DIR "dir"
44
NMExportedConnection parent;
47
typedef void (*NMANewSecretsRequestedFunc) (NMSettingsConnectionInterface *connection,
53
NMExportedConnectionClass parent;
56
void (*new_secrets_requested) (NMAGConfConnection *self,
57
const char *setting_name,
60
NMANewSecretsRequestedFunc callback,
61
gpointer callback_data);
62
} NMAGConfConnectionClass;
64
GType nma_gconf_connection_get_type (void);
66
NMAGConfConnection *nma_gconf_connection_new (GConfClient *client,
67
const char *conf_dir);
69
NMAGConfConnection *nma_gconf_connection_new_from_connection (GConfClient *client,
71
NMConnection *connection);
73
gboolean nma_gconf_connection_gconf_changed (NMAGConfConnection *self);
75
const char *nma_gconf_connection_get_gconf_path (NMAGConfConnection *self);
77
void nma_gconf_connection_update (NMAGConfConnection *self,
78
gboolean ignore_secrets);
82
#endif /* NMA_GCONF_CONNECTION_H */