[gnome-boxes] list-view-row: Tie dimming of status label to state
- From: Zeeshan Ali Khattak <zeeshanak src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-boxes] list-view-row: Tie dimming of status label to state
- Date: Mon, 14 Sep 2015 15:44:36 +0000 (UTC)
commit 920c457ec40d71505c3d1795d681423709fc21dc
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date: Thu Sep 10 19:26:48 2015 +0100
list-view-row: Tie dimming of status label to state
Simply tie the dimming to machine's state, regardless of the status
message.
src/list-view-row.vala | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
---
diff --git a/src/list-view-row.vala b/src/list-view-row.vala
index 6592ae2..d878aa6 100644
--- a/src/list-view-row.vala
+++ b/src/list-view-row.vala
@@ -113,36 +113,36 @@ private class Boxes.ListViewRow: Gtk.Box {
}
private void update_status () {
+ if (machine is RemoteMachine)
+ update_status_label_style (!machine.is_connected);
+ else
+ update_status_label_style (!machine.is_on);
+
if (machine.status != null) {
status_label.label = machine.status;
- update_status_label_style (false);
return;
}
if (machine is RemoteMachine) {
status_label.label = machine.is_connected ? _("Connected"): _("Disconnected");
- update_status_label_style (!machine.is_connected);
return;
}
if (machine.is_running) {
status_label.label = _("Running");
- update_status_label_style (false);
return;
}
if (machine.is_on) {
status_label.label = _("Paused");
- update_status_label_style (true);
return;
}
status_label.label = _("Powered Off");
- update_status_label_style (true);
}
private void update_status_label_style (bool dim) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]