[Kde-hardware-devel] Re: KDE networkmanagement plasma applet and disconnect issue

Lamarque Vieira Souza lamarque at gmail.com
Tue Jan 18 23:14:50 CET 2011


	Hi,

	After applying those two patches (one for Solid and one for Plasma NM) 
the disconnect works as expected, at least in my tests. The Solid patch 
changes the API, it will have to wait until KDE SC 4.7, which is going to be 
released in the middle of this year.

	Can you add your patch and my two patches to 
http://git.reviewboard.kde.org? This way anybody can improve it until we apply 
it to KDE's trunk. If you do not have a reviewboard account I can add them for 
you.

Em Thursday 13 January 2011, Gökçen Eraslan escreveu:
> Hello,
> 
> Yesterday, I have spent all my day to fix disconnect issue of KNM. The
> issue is, when you disconnect using plasmoid, something automatically
> reconnects interface. In current Solid::Control::NetworkManager we have a
> DeactivateConnection method[1], and this method is used in KNM. But this
> method just deactivate the connection and then NM tries to reconnect to
> another connection which is set as autoconnect.
> 
> The bug here is using DeactivateConnection method of NM[2], here is another
> guy mentioning about the same problem[3]. Solution is to call Disconnect
> method of the according interface instead[4], which is added in NM 0.8.
> Unfortunately this method does not exist in current Solid.
> 
> Attached patch (created against KDe 4.5.5) tries to implement this method
> in Solid by updating solid/networkmanager-0.7/dbus/nm-deviceinterface.h
> file which is autogenerated using qdbusxml2cpp and adding method to:
> 
> * libs/solid/control/ifaces/networkinterface.*
> * libs/solid/control/backends/fakenet/fakenetworkinterface.*
> * solid/networkmanager-0.7/networkinterface.*
> * solid/wicd/networkinterface.*
> 
> However when I try to call it using:
> 
> Solid::Control::NetworkInterface* iface =
> Solid::Control::NetworkManager::findNetworkInterface(deviceUni);
> 
> if (iface)
>   iface->disconnect();
> 
> 
> the method is not called. I put debug lines to every method I've
> implemented, but nothing is printed and connection is not disconnected.
> 
> Any ideas about that? I'm not familiar with solid, the patch may have
> mistakes.
> 
> Cheers.
> 
> [1] http://api.kde.org/4.5-api/kdebase-workspace-
> apidocs/libs/solid/html/namespaceSolid_1_1Control_1_1NetworkManager.html#db
> d96918b07abc71b8618b96aad9814d
> 
> [2]
> http://projects.gnome.org/NetworkManager/developers/spec-08.html#org.freede
> sktop.NetworkManager
> 
> [3] http://osdir.com/ml/networkmanager-list/2011-01/msg00007.html
> 
> [4]
> http://projects.gnome.org/NetworkManager/developers/spec-08.html#org.freede
> sktop.NetworkManager.Device


-- 
Lamarque V. Souza
http://www.geographicguide.com/brazil.htm
Linux User #57137 - http://counter.li.org/
http://www.kde-mg.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: solid-4.5.4-disconnect_fix.patch
Type: text/x-patch
Size: 1522 bytes
Desc: not available
Url : http://mail.kde.org/pipermail/kde-hardware-devel/attachments/20110118/4cf3eafa/attachment.patch 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: knetworkmanager-disconnect_fix.patch
Type: text/x-patch
Size: 1216 bytes
Desc: not available
Url : http://mail.kde.org/pipermail/kde-hardware-devel/attachments/20110118/4cf3eafa/attachment-0001.patch 


More information about the Kde-hardware-devel mailing list