[chronojump] Encoder inertial ecc/con icons on right to show disc position
- From: Xavier de Blas <xaviblas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [chronojump] Encoder inertial ecc/con icons on right to show disc position
- Date: Tue, 8 Sep 2020 10:12:09 +0000 (UTC)
commit 03d7b032cd587c6cec04c36c73a234e9a72438e4
Author: Xavier de Blas <xaviblas gmail com>
Date: Tue Sep 8 12:10:38 2020 +0200
Encoder inertial ecc/con icons on right to show disc position
glade/app1.glade | 89 +++++++++++++++++---------------------------
images/muscle-excentric.png | Bin 0 -> 3633 bytes
src/Makefile.am | 1 +
src/gui/app1/encoder.cs | 18 ++++-----
src/gui/app1/icons.cs | 7 ++++
5 files changed, 50 insertions(+), 65 deletions(-)
---
diff --git a/glade/app1.glade b/glade/app1.glade
index 1ad8fdb5..19640bab 100644
--- a/glade/app1.glade
+++ b/glade/app1.glade
@@ -24879,6 +24879,9 @@ Concentric</property>
<child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
</widget>
<packing>
<property name="expand">False</property>
@@ -27735,6 +27738,18 @@ Concentric</property>
<property name="can_focus">False</property>
<property name="spacing">6</property>
<child>
+ <widget class="GtkLabel"
id="label_video_encoder_tests_will_be_filmed">
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Tests
will be filmed</property>
+ </widget>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
<widget class="GtkHBox"
id="hbox_video_encoder_capturing">
<property name="can_focus">False</property>
<property name="spacing">4</property>
@@ -27771,18 +27786,6 @@ Concentric</property>
</packing>
</child>
<child>
- <widget class="GtkLabel"
id="label_video_encoder_tests_will_be_filmed">
- <property name="can_focus">False</property>
- <property name="label" translatable="yes">Tests
will be filmed</property>
- </widget>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- <property name="pack_type">end</property>
- <property name="position">0</property>
- </packing>
- </child>
- <child>
<widget class="GtkHBox"
id="hbox_video_encoder_no_capturing">
<property name="visible">True</property>
<property name="can_focus">False</property>
@@ -28536,35 +28539,6 @@ then click this button.</property>
</packing>
</child>
<child>
- <widget class="GtkHBox" id="hbox56">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <child>
- <widget class="GtkVBox" id="vbox53">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <child>
- <widget class="GtkLabel"
id="label_encoder_capture_inertial_ecc">
- <property name="visible">True</property>
- <property name="sensitive">False</property>
- <property name="can_focus">False</property>
- <property name="label"
translatable="yes">Eccentric</property>
- <property name="angle">90</property>
- </widget>
- <packing>
- <property name="expand">True</property>
- <property name="fill">False</property>
- <property name="position">0</property>
- </packing>
- </child>
- </widget>
- <packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- <property name="position">0</property>
- </packing>
- </child>
- <child>
<widget class="GtkVScale"
id="vscale_encoder_capture_inertial_angle_now">
<property name="visible">True</property>
<property name="sensitive">False</property>
@@ -28578,20 +28552,17 @@ then click this button.</property>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
- <property name="position">1</property>
+ <property name="position">2</property>
</packing>
</child>
<child>
- <widget class="GtkVBox" id="vbox140">
+ <widget class="GtkHBox" id="hbox50">
<property name="visible">True</property>
<property name="can_focus">False</property>
<child>
- <widget class="GtkLabel"
id="label_encoder_capture_inertial_con">
- <property name="visible">True</property>
- <property name="sensitive">False</property>
+ <widget class="GtkImage"
id="image_encoder_capture_inertial_ecc">
<property name="can_focus">False</property>
- <property name="label"
translatable="yes">Concentric</property>
- <property name="angle">90</property>
+ <property
name="stock">gtk-missing-image</property>
</widget>
<packing>
<property name="expand">True</property>
@@ -28599,18 +28570,22 @@ then click this button.</property>
<property name="position">0</property>
</packing>
</child>
+ <child>
+ <widget class="GtkImage"
id="image_encoder_capture_inertial_con">
+ <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">2</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
</packing>
</child>
</widget>
<packing>
- <property name="expand">True</property>
- <property name="fill">True</property>
- <property name="position">2</property>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">3</property>
</packing>
</child>
<child>
@@ -28621,7 +28596,8 @@ then click this button.</property>
<packing>
<property name="expand">False</property>
<property name="fill">False</property>
- <property name="position">3</property>
+ <property name="padding">2</property>
+ <property name="position">4</property>
</packing>
</child>
<child>
@@ -28635,7 +28611,7 @@ then click this button.</property>
<property name="expand">False</property>
<property name="fill">False</property>
<property name="pack_type">end</property>
- <property name="position">4</property>
+ <property name="position">5</property>
</packing>
</child>
</widget>
@@ -35817,6 +35793,9 @@ then click this button.</property>
<child>
<placeholder/>
</child>
+ <child>
+ <placeholder/>
+ </child>
</widget>
<packing>
<property name="expand">False</property>
diff --git a/images/muscle-excentric.png b/images/muscle-excentric.png
new file mode 100644
index 00000000..d2be166f
Binary files /dev/null and b/images/muscle-excentric.png differ
diff --git a/src/Makefile.am b/src/Makefile.am
index d4f73614..f3cfbe12 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -599,6 +599,7 @@ RESOURCES = \
../images/chronojump-logo-2013.png,chronojump-logo-2013.png \
../images/muscle-concentric.png,muscle-concentric.png \
../images/extra-mass.png,extra-mass.png \
+ ../images/muscle-excentric.png,muscle-excentric.png \
../images/muscle-excentric-concentric.png,muscle-excentric-concentric.png \
../images/laterality-both.png,laterality-both.png \
../images/laterality-right.png,laterality-right.png \
diff --git a/src/gui/app1/encoder.cs b/src/gui/app1/encoder.cs
index 4ec08a80..c4699e84 100644
--- a/src/gui/app1/encoder.cs
+++ b/src/gui/app1/encoder.cs
@@ -78,8 +78,6 @@ public partial class ChronoJumpWindow
[Widget] Gtk.VScale vscale_encoder_capture_inertial_angle_now;
[Widget] Gtk.VBox vbox_angle_now;
[Widget] Gtk.Label label_encoder_capture_inertial_angle_now;
- [Widget] Gtk.Label label_encoder_capture_inertial_ecc;
- [Widget] Gtk.Label label_encoder_capture_inertial_con;
[Widget] Gtk.Button button_encoder_capture;
@@ -2858,8 +2856,8 @@ public partial class ChronoJumpWindow
EncoderCaptureInertialBackgroundStatic.Abort();
eCaptureInertialBG = null;
vscale_encoder_capture_inertial_angle_now.Value = 0;
- label_encoder_capture_inertial_ecc.Sensitive = false;
- label_encoder_capture_inertial_con.Sensitive = false;
+ image_encoder_capture_inertial_ecc.Visible = false;
+ image_encoder_capture_inertial_con.Visible = false;
}
//this is called by non gtk thread. Don't do gtk stuff here
@@ -6126,18 +6124,18 @@ public partial class ChronoJumpWindow
int newValue = eCaptureInertialBG.AngleNow;
if(eCaptureInertialBG.Phase == EncoderCaptureInertialBackground.Phases.ATCALIBRATEDPOINT)
{
- label_encoder_capture_inertial_ecc.Sensitive = false;
- label_encoder_capture_inertial_con.Sensitive = false;
+ image_encoder_capture_inertial_ecc.Visible = false;
+ image_encoder_capture_inertial_con.Visible = false;
}
else if(eCaptureInertialBG.Phase == EncoderCaptureInertialBackground.Phases.CON)
{
- label_encoder_capture_inertial_ecc.Sensitive = false;
- label_encoder_capture_inertial_con.Sensitive = true;
+ image_encoder_capture_inertial_ecc.Visible = false;
+ image_encoder_capture_inertial_con.Visible = true;
}
else if(eCaptureInertialBG.Phase == EncoderCaptureInertialBackground.Phases.ECC)
{
- label_encoder_capture_inertial_ecc.Sensitive = true;
- label_encoder_capture_inertial_con.Sensitive = false;
+ image_encoder_capture_inertial_ecc.Visible = true;
+ image_encoder_capture_inertial_con.Visible = false;
}
/*
else if(eCaptureInertialBG.Phase == EncoderCaptureInertialBackground.Phases.NOTMOVED)
diff --git a/src/gui/app1/icons.cs b/src/gui/app1/icons.cs
index 9f5bf75b..ab7d41f9 100644
--- a/src/gui/app1/icons.cs
+++ b/src/gui/app1/icons.cs
@@ -156,6 +156,8 @@ public partial class ChronoJumpWindow
[Widget] Gtk.Image image_encoder_analyze_image_compujump_send_email_image;
[Widget] Gtk.Image image_encoder_analyze_image_compujump_send_email_send;
[Widget] Gtk.Image image_encoder_analyze_check;
+ [Widget] Gtk.Image image_encoder_capture_inertial_ecc;
+ [Widget] Gtk.Image image_encoder_capture_inertial_con;
//force sensor
[Widget] Gtk.Image image_selector_start_force_sensor;
@@ -275,14 +277,19 @@ public partial class ChronoJumpWindow
image_message_permissions_at_boot.Pixbuf = pixbuf;
image_button_force_sensor_stiffness_problem.Pixbuf = pixbuf;
+ pixbuf = new Pixbuf (null, Util.GetImagePath(false) + "muscle-excentric.png");
+ image_encoder_capture_inertial_ecc.Pixbuf = pixbuf;
+
pixbuf = new Pixbuf (null, Util.GetImagePath(false) + "muscle-concentric.png");
image_top_eccon.Pixbuf = pixbuf;
+ image_encoder_capture_inertial_con.Pixbuf = pixbuf;
pixbuf = new Pixbuf (null, Util.GetImagePath(false) + "muscle-concentric.png");
image_encoder_eccon_concentric.Pixbuf = pixbuf;
pixbuf = new Pixbuf (null, Util.GetImagePath(false) + "muscle-excentric-concentric.png");
image_encoder_eccon_eccentric_concentric.Pixbuf = pixbuf;
+
pixbuf = new Pixbuf (null, Util.GetImagePath(false) + "laterality-both.png");
image_top_laterality.Pixbuf = pixbuf;
image_encoder_laterality_both.Pixbuf = pixbuf;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]