[chronojump] Networks: show "new" icon if there are tasks on other stations
- From: Xavier de Blas <xaviblas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [chronojump] Networks: show "new" icon if there are tasks on other stations
- Date: Wed, 7 Aug 2019 10:23:18 +0000 (UTC)
commit 22b61bb4e3769b5a6e8159a2a9cc84cdbb4edb40
Author: Xavier de Blas <xaviblas gmail com>
Date: Wed Aug 7 12:22:39 2019 +0200
Networks: show "new" icon if there are tasks on other stations
glade/dialog_person_popup.glade | 49 +++++++++++++++++++-------
images/md/baseline_new_releases_blue_24dp.png | Bin 0 -> 3056 bytes
src/Makefile.am | 1 +
src/gui/dialogPersonPopup.cs | 6 ++++
4 files changed, 43 insertions(+), 13 deletions(-)
---
diff --git a/glade/dialog_person_popup.glade b/glade/dialog_person_popup.glade
index 644e9bfb..e48e280a 100644
--- a/glade/dialog_person_popup.glade
+++ b/glade/dialog_person_popup.glade
@@ -49,17 +49,6 @@
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="spacing">20</property>
- <child>
- <widget class="GtkLabel" id="label_rfid">
- <property name="can_focus">False</property>
- <property name="label" translatable="yes">label</property>
- </widget>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">0</property>
- </packing>
- </child>
<child>
<widget class="GtkHBox" id="hbox3">
<property name="visible">True</property>
@@ -283,6 +272,17 @@
<property name="position">0</property>
</packing>
</child>
+ <child>
+ <widget class="GtkLabel" id="label_rfid">
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">label</property>
+ </widget>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
</widget>
<packing>
<property name="expand">True</property>
@@ -383,10 +383,33 @@
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label4">
+ <widget class="GtkHBox" id="hbox7">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="label" translatable="yes">Other stations with assigned tasks</property>
+ <property name="spacing">4</property>
+ <child>
+ <widget class="GtkLabel" id="label4">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Other stations with assigned
tasks</property>
+ </widget>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <widget class="GtkImage" id="image_new_tasks_other_stations">
+ <property name="can_focus">False</property>
+ <property name="stock">gtk-missing-image</property>
+ </widget>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
</widget>
<packing>
<property name="position">1</property>
diff --git a/images/md/baseline_new_releases_blue_24dp.png b/images/md/baseline_new_releases_blue_24dp.png
new file mode 100644
index 00000000..b8d61283
Binary files /dev/null and b/images/md/baseline_new_releases_blue_24dp.png differ
diff --git a/src/Makefile.am b/src/Makefile.am
index f57eb9da..93ee7192 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -475,6 +475,7 @@ RESOURCES = \
../images/md/baseline_check_box_blue_24dp.png,image_check.png \
../images/md/baseline_save_blue_24dp.png,save.png \
../images/md/baseline_grid_on_blue_24dp.png,grid.png \
+ ../images/md/baseline_new_releases_blue_24dp.png,new.png \
../images/chronojump_icon.png,chronojump_icon.png \
../images/chronojump_icon_graph.png,chronojump_icon_graph.png \
../images/stock_right.png,stock_right.png \
diff --git a/src/gui/dialogPersonPopup.cs b/src/gui/dialogPersonPopup.cs
index 408b9d8f..2fe58988 100644
--- a/src/gui/dialogPersonPopup.cs
+++ b/src/gui/dialogPersonPopup.cs
@@ -31,6 +31,7 @@ public class DialogPersonPopup
[Widget] Gtk.Label label_name;
[Widget] Gtk.Image image_person;
[Widget] Gtk.Image image_person_logout;
+ [Widget] Gtk.Image image_new_tasks_other_stations;
[Widget] Gtk.CheckButton checkbutton_autologout;
[Widget] Gtk.Image image_close;
[Widget] Gtk.Label label_rfid;
@@ -80,6 +81,8 @@ public class DialogPersonPopup
pixbuf = new Pixbuf (null, Util.GetImagePath(false) + "image_person_logout.png");
image_person_logout.Pixbuf = pixbuf;
+ pixbuf = new Pixbuf (null, Util.GetImagePath(false) + "new.png");
+ image_new_tasks_other_stations.Pixbuf = pixbuf;
pixbuf = new Pixbuf (null, Util.GetImagePath(false) + "gtk-apply.png");
image_server_connected_yes.Pixbuf = pixbuf;
@@ -196,8 +199,11 @@ public class DialogPersonPopup
if(stationsString == "")
label_other_stations.Text = "There are no tasks at other stations";
else
+ {
//label_other_stations.Text = "There are task at this stations:" + "\n\n" +
stationsString;
label_other_stations.Text = stationsString;
+ image_new_tasks_other_stations.Visible = true;
+ }
}
private Gtk.HBox createHBoxStartAndLabel(Task t, Pixbuf pixbuf)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]