[Plasma-NM] Don't emit connection deactivated message on suspending
Review Request #126748 - Created Jan. 14, 2016 and submitted
|Kai Uwe Broulik|
It's quite natural that the connection goes away when we're about to suspend :) Watch for this and then don't emit the notification.
While I still think Plasma-NM is waaaaaay too verbose about everything, at least it doesn't tell me that I just disconnected when I suspend.
I still get the notification when I turn off Wifi manually.
I also still get the notification that I'm connected again shortly after resuming.
- Remember which connections were active before suspending and don't show a "notification activated" message for those
- If there is no active or activating connection 5s after resuming, show a message that you're no longer connected to a network
I connected to a Wifi, suspended (no disconnect notification), resumed (no connect notification)
I enabled a hotspot on my phone and connected to it, suspended (no disconnect notification), turned the hotspot off, resumed, it connected to my regular Wifi and showed a notification that I'm now connected to this one instead
I couldn't test the "you are not connected" notification as when I remove my regular Wifi connection it tries to activate the hotspot (ie. there's an activating connection) I disabled in the meantime and is stuck at "configuring interface" until it times out. We could only look for active connections but that might take longer than 5 seconds?
Revision 2 (+100)
Looks good to me, maybe just change what I pointed out (storing just UUIDs as strings instead active connections). I don't have time right now to test it, but I trust you that it works.
Looking only for active connections would probably require increasing the time at least to 10 seconds, just leave it as it is for now.