Commit graph

12 commits

Author SHA1 Message Date
Dan Williams 8f4d4c0463 manager: add WWAN enable/disable support 2009-12-23 01:30:54 -08:00
Dan Williams 8d65515435 manager: automatically pick a base connection for VPNs
If let callers pass "/" for the specific object, and NM will
automatically pick the default device.
2009-10-16 11:52:27 -07:00
Dan Williams 393685203f 2008-03-20 Dan Williams <dcbw@redhat.com>
* introspection/nm-manager.xml
	  introspection/nm-manager-client.xml
		- (ActivateConnection): return the object path of the active connection
			on success
		- (GetActiveConnections): remove
		- (DeactivateConnection): new function; deactivate a currently active
			connection
		- Add an ActiveConnections property which returns an array of
			active connection object paths

	* introspection/nm-device.xml
		- (Deactivate): remove

	* introspection/all.xml
		- Add ActiveConnection introspection

	* introspection/nm-active-connection.xml
		- Add the ActiveConnection object

	* include/NetworkManager.h
		- Add the Connection.Active D-Bus interface

	* src/nm-device-interface.c
		- (impl_device_deactivate): remove

	* src/nm-activation-request.c
	  src/nm-activation-request.c
	  src/Makefile.am
		- Implement the Connection.Active D-Bus interface

	* src/nm-manager.c
		- (get_property, nm_manager_class_init): add ACTIVE_CONNECTIONS property
		- (nm_manager_activate_device): return the active connection path
		- (connection_added_default_handler, impl_manager_activate_connection):
			return the active connection to the caller
		- (add_one_connection_element, impl_manager_get_active_connections):
			remove
		- (impl_manager_deactivate_connection): new function; deactivate an
			active connection

	* libnm-glib/nm-device.c
	  libnm-glib/nm-device.h
		- Remove Deactivate() function



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3484 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-03-20 19:56:12 +00:00
Dan Williams fbb5062271 2008-03-19 Dan Williams <dcbw@redhat.com>
* introspection/nm-manager.xml
	  introspection/nm-manager-client.xml
		- Rename the ActivateDevice method to ActivateConnection to better
			reflect it's usage; it's arguments get reordered a bit too
		- Convert GetActiveConnections method return from a struct to a dict

	* include/NetworkManager.h
		- Define the dict keys for return value of GetActiveConnections

	* src/nm-manager.c
		- impl_manager_activate_device -> impl_manager_activate_connection
		- (add_one_connection_element): return a populated hash table, not
			a structure

	* libnm-glib/nm-client.c
	  libnm-glib/nm-client.h
		- nm_client_activate_device -> nm_client_activate_connection
		- nm_client_free_active_connection_element -> nm_client_free_active_connections_element
		- (nm_client_get_active_connections): return a GSList of GHashTables,
			instead of the custom structures.  Each element of the returned list
			must be freed with nm_client_free_active_connections_element()



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3482 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-03-19 20:58:21 +00:00
Dan Williams bf974b6aa4 2008-03-07 Dan Williams <dcbw@redhat.com>
Change manager's StateChange signal to StateChanged for consistency.

	* introspection/nm-manager.xml
		- Add 'StateChanged' signal
		- Move 'StateChange' down to the deprecated section

	* src/nm-hal-manager.c
		- (nm_hal_manager_new): connect to 'state-changed' instead

	* src/NetworkManagerPolicy.c
		- (nm_policy_new): connect to 'state-changed' instead

	* src/nm-manager.c
	  src/nm-manager.h
		- (nm_manager_update_state): emit both 'state-changed' and 'state-change'
		- (nm_manager_class_init): add 'state-changed' and not the deprecation
			of 'state-change'

	* libnm-glib/nm-client.c
	  libnm-glib/nm-client.h
		- (constructor, nm_client_class_init, client_state_changed_proxy):
			track and proxy 'state-changed' instead of 'state-change'



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3393 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-03-07 23:17:48 +00:00
Dan Williams 8ffe21b65f 2008-02-27 Dan Williams <dcbw@redhat.com>
Patch from Will Stephenson <wstephenson@kde.org>

	* Makefile.am
	  configure.in
		- Set up spec autogeneration infrastructure

	* docs/NetworkManager DBUS API.txt
		- Note how old this doc is and where to look for the canonical
			D-Bus specification

	* introspection/*
		- Add annotations and comments



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3345 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-02-28 02:07:21 +00:00
Tambet Ingo 7e2a621f0a 2007-10-15 Tambet Ingo <tambet@gmail.com>
Implement killswitch polling through HAL.

        * src/nm-manager.c: Add wireless hardware status property. Add 
        'properties-changed' signal for changes in wireless and wireless
hardware
        state changes.

        * src/nm-hal-manager.c: Poll hal for killswitch statuses in
        * every 6 seconds
        and update NMManager's wireless hardware state when it has
changed.
        (nm_hal_manager_new): Don't try to add initial devices here -
(hal_init)
        already does that.

        * libnm-glib/nm-client.c: Add wireless hardware status property.
        * Cache the
        values of wireless state and wireless hardware state. Listen for
the
        'properties-changed' signals, update the cached values and emit
notify.

        * include/NetworkManager.h: Fix a typo in a comment.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2975 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-10-15 14:46:37 +00:00
Dan Williams f9fd8667d1 2007-10-03 Dan Williams <dcbw@redhat.com>
Add a GetActiveConnections() method on the Manager object.

	* src/nm-manager.c
	  src/nm-manager.h
	  introspection/nm-manager.xml
		- (connection_get_settings_cb): keep connection type around too
		- (impl_manager_get_active_connections, add_one_connection_element):
			implement; returns all active connections and what devices they
			apply to

	* libnm-glib/nm-client.c
	  libnm-glib/nm-client.h
	  introspection/nm-manager-client.xml
		- (nm_client_get_devices): GPtrArray elements are allocated and owned
			by the caller; free here to avoid memory leak
		- (nm_client_get_active_connections): implement; return the list of
			active connections
		- (nm_client_free_active_connection_element): implement; free an element
			of the GSList returned by nm_client_get_active_connections()



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2927 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-10-03 14:48:25 +00:00
Tambet Ingo 485bcfe571 2007-09-28 Tambet Ingo <tambet@gmail.com>
* 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
2007-10-01 15:38:39 +00:00
Dan Williams 9496e413c7 2007-09-24 Dan Williams <dcbw@redhat.com>
* introspection/nm-manager.xml
	  src/nm-manager.c
		- (impl_manager_legacy_state): fix 'state' method call return value



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2865 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-24 21:26:56 +00:00
Tambet Ingo 8bed6ff2de 2007-08-14 Tambet Ingo <tambet@gmail.com>
* libnm-glib/Makefile.am: Use nm-manager-client.xml to produce
        * nm-client-bindings.

        * introspection/nm-manager-client.xml: Add a horrible horrbile
        * hack to work around
        an issue with dbus-glib bindings generator. The issue is, the
generated C caller
        functions for dbus methods "Sleep(bool)" and "sleep()" both have
the same function
        name and different arguments and it won't compile anymore. To
fix this, we now have
        two copies of nm-manager.xml file. nm-manager.xml contains the
actual interface,
        that is new API + compatibility API and used by the daemon. The
other, 
        nm-manager-client.xml is only the new API without compatibility
bits and is used
        by libnm-glib to make it compile.

        * introspection/nm-manager.xml: Define compatibility methods
        * (sleep, wake, state).

        * src/nm-manager.c (impl_manager_legacy_sleep)
        (impl_manager_legacy_wake, impl_manager_legacy_state): Implement
the compatibility
        interface functions for 0.6 branch.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2688 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-08-15 07:52:25 +00:00
Tambet Ingo 8a4c57f631 2007-02-12 Tambet Ingo <tambet@ximian.com>
Totally break NetworkManager. Please use 0.6 branch until futher notice.

	* src/:
		- Remove old low-level dbus interface implementations and replace them
		  with dbus-glib one.

	* configure.in:
		- Require dbus-glib >= 0.72.
		- Plug in new sources to build.

	* libnm-glib/:
		- Implement GObject wrappers on top of DBUS glib auto-generated bindings
		  to make it more convenient to use from GObject based programs.

	* introspection/:
		- Implement DBUS XML introspection files, used by both NM and libnm-glib.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2309 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-02-12 09:23:43 +00:00