mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-04-27 10:40:43 +02:00
* src/nm-manager.c:
* src/nm-manager.h:
Implement device activation through NMManager.
Implement "pending device activation" here - If the connection
isn't found,
we try to wait for up to 5 seconds for the connection to be
provided.
Add NMConnectionType argument to "connection-added" and
"connection-removed"
signals.
(nm_manager_get): Remove. Finally.
* src/nm-activation-request.c:
* src/nm-activation-request.h:
Remove all the deferred activation code.
* src/nm-device.c: Remove all the deferred activation code. Once
* the device
activation is started, it's started. Update the activation
virtual function
signature.
* src/nm-device-interface.c:
* src/nm-device-interface.h:
Device activation now takes only NMActRequest argument.
Don't expose device activation directly on dbus, it's supposed
to go through
NMManager now.
* src/NetworkManagerPolicy.c (nm_policy_device_change_check):
* Make the code
a bit more compact.
Use the new device activation methods through NMManager.
* introspection/nm-manager-client.xml:
* introspection/nm-manager.xml:
* libnm-glib/nm-client.c:
* libnm-glib/nm-client.h:
Add device activation method.
* libnm-glib/nm-device.c:
* libnm-glib/nm-device.h:
* introspection/nm-device.xml:
Remove device activation method. It's done through NMManager
now.
* src/vpn-manager/nm-vpn-manager.c (impl_vpn_manager_connect):
* Use the shiny
new (nm_manager_get_device_by_path) function, get rid of our own
)find_device).
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2915 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
55 lines
1.9 KiB
C
55 lines
1.9 KiB
C
#ifndef NM_DEVICE_H
|
|
#define NM_DEVICE_H
|
|
|
|
#include <glib/gtypes.h>
|
|
#include <glib-object.h>
|
|
#include <dbus/dbus-glib.h>
|
|
#include "nm-object.h"
|
|
#include "NetworkManager.h"
|
|
#include "nm-ip4-config.h"
|
|
#include "nm-connection.h"
|
|
|
|
G_BEGIN_DECLS
|
|
|
|
#define NM_TYPE_DEVICE (nm_device_get_type ())
|
|
#define NM_DEVICE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), NM_TYPE_DEVICE, NMDevice))
|
|
#define NM_DEVICE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), NM_TYPE_DEVICE, NMDeviceClass))
|
|
#define NM_IS_DEVICE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), NM_TYPE_DEVICE))
|
|
#define NM_IS_DEVICE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((obj), NM_TYPE_DEVICE))
|
|
#define NM_DEVICE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), NM_TYPE_DEVICE, NMDeviceClass))
|
|
|
|
typedef struct {
|
|
NMObject parent;
|
|
} NMDevice;
|
|
|
|
typedef struct {
|
|
NMObjectClass parent;
|
|
|
|
/* Signals */
|
|
void (*state_changed) (NMDevice *device, NMDeviceState state);
|
|
void (*carrier_changed) (NMDevice *device, gboolean carrier);
|
|
} NMDeviceClass;
|
|
|
|
GType nm_device_get_type (void);
|
|
|
|
NMDevice *nm_device_new (DBusGConnection *connection,
|
|
const char *path);
|
|
|
|
void nm_device_deactivate (NMDevice *device);
|
|
|
|
char *nm_device_get_iface (NMDevice *device);
|
|
char *nm_device_get_udi (NMDevice *device);
|
|
char *nm_device_get_driver (NMDevice *device);
|
|
guint32 nm_device_get_capabilities (NMDevice *device);
|
|
guint32 nm_device_get_ip4_address (NMDevice *device);
|
|
NMIP4Config *nm_device_get_ip4_config (NMDevice *device);
|
|
NMDeviceState nm_device_get_state (NMDevice *device);
|
|
char *nm_device_get_description (NMDevice *device);
|
|
gboolean nm_device_get_carrier (NMDevice *device);
|
|
|
|
NMDeviceType nm_device_type_for_path (DBusGConnection *connection,
|
|
const char *path);
|
|
|
|
G_END_DECLS
|
|
|
|
#endif /* NM_DEVICE_H */
|