Re: nm_device_disconnect

2014-04-02 Thread Manuel Yguel
network is not available anymore) and then that this not the function for my purpose. No, the callback is only called for the action that you initiated. Well, well, what I am looking for is the function that is called when in a GUI the user hit the disconnect button... Which is nm_device_disconnect

Re: nm_device_disconnect

2014-04-02 Thread Dan Winship
king for is the function that is called when in > a GUI the user hit the disconnect button... Which is nm_device_disconnect(). > I took a look at the sources of NetworkManager and I noted that there > are several files called nm-device.h that offer different interfaces. One

Re: nm_device_disconnect

2014-04-02 Thread Manuel Yguel
nm_device_disconnect (NMDevice *device, GError **error) { NMDevicePrivate *priv; g_return_val_if_fail (device != NULL, FALSE); g_return_val_if_fail (NM_IS_DEVICE (device), FALSE); priv = NM_DEVICE_GET_PRIVATE (device); if (priv->state <= NM_DEVICE_STATE_DISCON

Re: nm_device_disconnect

2014-04-01 Thread Manuel Yguel
/2014 08:16 PM, Dan Winship wrote: On 04/01/2014 01:18 PM, Manuel Yguel wrote: however in the include directory of libnm-glib the file nm-device.h contains only the following function: void nm_device_disconnect (NMDevice *device, NMDeviceDeactivateFn callback, gpointer user_data

Re: nm_device_disconnect

2014-04-01 Thread Dan Winship
On 04/01/2014 01:18 PM, Manuel Yguel wrote: > however in the include directory of libnm-glib the file nm-device.h > contains only the following function: >void nm_device_disconnect (NMDevice *device, > NMDeviceDeactivateFn callback, gpointer user_data); > >

nm_device_disconnect

2014-04-01 Thread Manuel Yguel
far I am able to create the adhoc network, scan and connect. I am stuck at the repeat part since I would like to disconnect the network but I do not find how to proceed. It seems that there exists a nm_device_disconnect function with the following prototype: gboolean