[gnome-control-center] network: Add status label and icon to wifi header
- From: Dan Winship <danw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-control-center] network: Add status label and icon to wifi header
- Date: Wed, 30 Jan 2013 18:06:08 +0000 (UTC)
commit 96caacc136b293242fd15d09941f34e8f0632916
Author: Matthias Clasen <mclasen redhat com>
Date: Sun Dec 9 02:17:49 2012 -0500
network: Add status label and icon to wifi header
This is part of the design refresh for the network panel.
panels/network/net-device-wifi.c | 4 ++
panels/network/network-wifi.ui | 61 ++++++++++++++++++++++++++++++-------
2 files changed, 53 insertions(+), 12 deletions(-)
---
diff --git a/panels/network/net-device-wifi.c b/panels/network/net-device-wifi.c
index a626d72..65b553e 100644
--- a/panels/network/net-device-wifi.c
+++ b/panels/network/net-device-wifi.c
@@ -657,6 +657,10 @@ nm_device_wifi_refresh_ui (NetDeviceWifi *device_wifi)
else
panel_set_device_widget_details (priv->builder, "last_used", NULL);
+ widget = GTK_WIDGET (gtk_builder_get_object (device_wifi->priv->builder, "heading_status"));
+ gtk_label_set_label (GTK_LABEL (widget),
+ panel_device_state_to_localized_string (nm_device));
+
/* update list of APs */
populate_ap_list (device_wifi);
}
diff --git a/panels/network/network-wifi.ui b/panels/network/network-wifi.ui
index c56ad4e..ab985ce 100644
--- a/panels/network/network-wifi.ui
+++ b/panels/network/network-wifi.ui
@@ -143,16 +143,11 @@
<property name="margin_top">12</property>
<property name="margin_bottom">12</property>
<child>
- <object class="GtkLabel" id="heading_list">
+ <object class="GtkImage" id="heading_image">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="halign">start</property>
- <property name="hexpand">True</property>
- <property name="label" translatable="yes">Wi-Fi</property>
- <attributes>
- <attribute name="weight" value="bold"/>
- <attribute name="scale" value="1.2"/>
- </attributes>
+ <property name="icon_name">network-wireless</property>
+ <property name="icon-size">6</property>
</object>
<packing>
<property name="expand">False</property>
@@ -161,21 +156,63 @@
</packing>
</child>
<child>
+ <object class="GtkBox" id="box4">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkLabel" id="heading_list">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="halign">start</property>
+ <property name="label" translatable="yes">Wi-Fi</property>
+ <attributes>
+ <attribute name="weight" value="bold"/>
+ <attribute name="scale" value="1.2"/>
+ </attributes>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="heading_status">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="halign">start</property>
+ <property name="label">Connected</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
<object class="GtkSwitch" id="device_off_switch">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="halign">end</property>
- <property name="valign">start</property>
+ <property name="valign">center</property>
</object>
<packing>
- <property name="expand">False</property>
+ <property name="expand">True</property>
<property name="fill">True</property>
- <property name="position">1</property>
+ <property name="position">2</property>
</packing>
</child>
</object>
<packing>
- <property name="expand">False</property>
+ <property name="expand">True</property>
<property name="fill">False</property>
<property name="position">0</property>
</packing>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]