Merge lp:~naaando/wingpanel-indicator-network/wingpanel-indicator-network into lp:~wingpanel-devs/wingpanel-indicator-network/trunk

Proposed by Fernando da Silva Sousa
Status: Merged
Merged at revision: 218
Proposed branch: lp:~naaando/wingpanel-indicator-network/wingpanel-indicator-network
Merge into: lp:~wingpanel-devs/wingpanel-indicator-network/trunk
Diff against target: 97 lines (+17/-8)
4 files modified
src/Widgets/DisplayWidget.vala (+4/-1)
src/Widgets/EtherInterface.vala (+2/-2)
src/common/Utils.vala (+10/-4)
src/common/Widgets/AbstractEtherInterface.vala (+1/-1)
To merge this branch: bzr merge lp:~naaando/wingpanel-indicator-network/wingpanel-indicator-network
Reviewer Review Type Date Requested Status
Fernando da Silva Sousa (community) Abstain
Leonardo Lemos (community) Approve
Review via email: mp+313318@code.launchpad.net

Commit message

Use "network-wireless-offline-symbolic" icon when no ethernet card available (lp:1507360)

Description of the change

Shows wireless offline symbol as default network offline symbol if any ethernet card can be found.

p.s.: The truly "default" symbol still is "network-offline-symbolic", which is triggered if any case match(means no wireless card was found too), should I change this too?

To post a comment you must log in.
Revision history for this message
Leonardo Lemos (leonardolemos) :
review: Approve
Revision history for this message
RabbitBot (rabbitbot-a) wrote :

Attempt to merge into lp:wingpanel-indicator-network failed due to conflicts:

text conflict in src/common/Utils.vala

Revision history for this message
Cody Garver (codygarver) wrote :

Thanks you for this contribution!

This bug had a $15 bounty attached to it, you can claim it here: https://www.bountysource.com/issues/27504720-use-network-wireless-offline-symbolic-when-no-ethernet-card-available

Revision history for this message
Fernando da Silva Sousa (naaando) wrote :

Due to text conflict I rewrote the code based on the last updates, can I abort this merge and resubmit? The branch was already overwritten with the newer.

review: Needs Fixing
Revision history for this message
Cody Garver (codygarver) wrote :

Hi Fernando,

Because the bot complained, I manually merged this code and resolve the conflicts myself.

You can see the final result of the merge here: http://bazaar.launchpad.net/~wingpanel-devs/wingpanel-indicator-network/trunk/revision/218

If you have improvements to the final result's code, please start a new branch and merge proposal.

Revision history for this message
Fernando da Silva Sousa (naaando) :
review: Abstain

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/Widgets/DisplayWidget.vala'
2--- src/Widgets/DisplayWidget.vala 2016-11-21 02:42:01 +0000
3+++ src/Widgets/DisplayWidget.vala 2016-12-15 08:32:46 +0000
4@@ -84,7 +84,10 @@
5 });
6 break;
7 case Network.State.DISCONNECTED:
8- image.icon_name = "network-offline-symbolic";
9+ image.icon_name = "network-wireless-offline-symbolic";
10+ break;
11+ case Network.State.WIRED_UNPLUGGED:
12+ image.icon_name = "network-wired-offline-symbolic";
13 break;
14 default:
15 image.icon_name = "network-offline-symbolic";
16
17=== modified file 'src/Widgets/EtherInterface.vala'
18--- src/Widgets/EtherInterface.vala 2016-11-04 16:42:19 +0000
19+++ src/Widgets/EtherInterface.vala 2016-12-15 08:32:46 +0000
20@@ -56,12 +56,12 @@
21 case NM.DeviceState.UNAVAILABLE:
22 ethernet_item.sensitive = false;
23 ethernet_item.set_active (false);
24- state = State.DISCONNECTED;
25+ state = State.WIRED_UNPLUGGED;
26 break;
27 case NM.DeviceState.DISCONNECTED:
28 ethernet_item.sensitive = true;
29 ethernet_item.set_active (false);
30- state = State.DISCONNECTED;
31+ state = State.WIRED_UNPLUGGED;
32 break;
33
34 case NM.DeviceState.PREPARE:
35
36=== modified file 'src/common/Utils.vala'
37--- src/common/Utils.vala 2016-11-03 19:48:54 +0000
38+++ src/common/Utils.vala 2016-12-15 08:32:46 +0000
39@@ -18,8 +18,10 @@
40
41 public enum Network.State {
42 DISCONNECTED,
43- DISCONNECTED_WIRED,
44+ WIRED_UNPLUGGED,
45+ DISCONNECTED_WIRED, //Deprecated
46 CONNECTED_WIRED,
47+ CONNECTED_VPN,
48 CONNECTED_WIFI,
49 CONNECTED_WIFI_WEAK,
50 CONNECTED_WIFI_OK,
51@@ -27,8 +29,10 @@
52 CONNECTED_WIFI_EXCELLENT,
53 CONNECTING_WIFI,
54 CONNECTING_WIRED,
55+ CONNECTING_VPN,
56 FAILED_WIRED,
57- FAILED_WIFI
58+ FAILED_WIFI,
59+ FAILED_VPN
60 }
61
62 namespace Network.Common.Utils {
63@@ -42,17 +46,19 @@
64 case Network.State.CONNECTED_WIFI_GOOD:
65 case Network.State.CONNECTED_WIFI_EXCELLENT:
66 case Network.State.CONNECTED_WIRED:
67+ case Network.State.CONNECTED_VPN:
68 return _("Connected");
69 case Network.State.FAILED_WIRED:
70 case Network.State.FAILED_WIFI:
71+ case Network.State.FAILED_VPN:
72 return _("Failed");
73 case Network.State.CONNECTING_WIFI:
74 case Network.State.CONNECTING_WIRED:
75+ case Network.State.CONNECTING_VPN:
76 return _("Connecting");
77- case Network.State.DISCONNECTED_WIRED:
78+ case Network.State.WIRED_UNPLUGGED:
79 return _("Cable unplugged");
80 }
81 return _("Unknown");
82 }
83 }
84-
85
86=== modified file 'src/common/Widgets/AbstractEtherInterface.vala'
87--- src/common/Widgets/AbstractEtherInterface.vala 2016-11-03 22:24:46 +0000
88+++ src/common/Widgets/AbstractEtherInterface.vala 2016-12-15 08:32:46 +0000
89@@ -39,7 +39,7 @@
90 case NM.DeviceState.UNKNOWN:
91 case NM.DeviceState.UNMANAGED:
92 case NM.DeviceState.UNAVAILABLE:
93- state = State.DISCONNECTED_WIRED;
94+ state = State.WIRED_UNPLUGGED;
95 break;
96
97 /* virtually not working */

Subscribers

People subscribed via source and target branches