[chronojump] Menu 2.2.2 with races and many other tweaks done!



commit d7553a1b6c86433a9300c820a731dc7ae789d03e
Author: Xavier de Blas <xaviblas gmail com>
Date:   Thu May 26 18:10:17 2022 +0200

    Menu 2.2.2 with races and many other tweaks done!

 glade/app1.glade           | 351 ++++++++++++++++++++++++++++++++++++++++-----
 src/Makefile.am            |   1 +
 src/gui/app1/chronojump.cs |   9 +-
 src/gui/app1/icons.cs      |   9 ++
 4 files changed, 330 insertions(+), 40 deletions(-)
---
diff --git a/glade/app1.glade b/glade/app1.glade
index 51bcb139f..7309980f2 100644
--- a/glade/app1.glade
+++ b/glade/app1.glade
@@ -4778,12 +4778,38 @@
                                                             <widget class="GtkVBox" id="vbox271">
                                                             <property name="visible">True</property>
                                                             <property name="can_focus">False</property>
+                                                            <property name="spacing">16</property>
+                                                            <child>
+                                                            <widget class="GtkHBox" id="hbox224">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <child>
+                                                            <widget class="GtkButton" id="button_menu_2_2_1">
+                                                            <property name="label">2.2.1 menu</property>
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">True</property>
+                                                            <property name="receives_default">True</property>
+                                                            <signal name="clicked" 
handler="on_button_view_menu_2_2_1_clicked" swapped="no"/>
+                                                            </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>
+                                                            </widget>
+                                                            <packing>
+                                                            <property name="expand">False</property>
+                                                            <property name="fill">False</property>
+                                                            <property name="position">0</property>
+                                                            </packing>
+                                                            </child>
                                                             <child>
                                                             <widget class="GtkAlignment" id="alignment88">
                                                             <property name="visible">True</property>
                                                             <property name="can_focus">False</property>
-                                                            <property name="top_padding">75</property>
-                                                            <property name="bottom_padding">75</property>
+                                                            <property name="top_padding">30</property>
                                                             <child>
                                                             <widget class="GtkHButtonBox" id="hbuttonbox27">
                                                             <property name="visible">True</property>
@@ -5112,7 +5138,7 @@
                                                             <packing>
                                                             <property name="expand">False</property>
                                                             <property name="fill">False</property>
-                                                            <property name="position">0</property>
+                                                            <property name="position">1</property>
                                                             </packing>
                                                             </child>
                                                             <child>
@@ -5127,7 +5153,7 @@
                                                             <property name="label_yalign">1</property>
                                                             <property name="shadow_type">none</property>
                                                             <child>
-                                                            <widget class="GtkVBox" id="vbox277">
+                                                            <widget class="GtkVBox" id="vbox280">
                                                             <property name="visible">True</property>
                                                             <property name="can_focus">False</property>
                                                             <property name="spacing">16</property>
@@ -5149,13 +5175,21 @@
                                                             <property name="show_tabs">False</property>
                                                             <property name="show_border">False</property>
                                                             <child>
+                                                            <widget class="GtkHBox" id="hbox271">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <child>
+                                                            <widget class="GtkVBox" id="vbox283">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <child>
                                                             <widget class="GtkTable" id="table25">
                                                             <property name="visible">True</property>
                                                             <property name="can_focus">False</property>
                                                             <property name="n_rows">2</property>
                                                             <property name="n_columns">2</property>
-                                                            <property name="column_spacing">20</property>
-                                                            <property name="row_spacing">20</property>
+                                                            <property name="column_spacing">16</property>
+                                                            <property name="row_spacing">16</property>
                                                             <child>
                                                             <widget class="GtkButton" id="button12">
                                                             <property name="height_request">60</property>
@@ -5164,7 +5198,7 @@
                                                             <property name="receives_default">True</property>
                                                             <signal name="clicked" 
handler="on_button_selector_start_jumps_simple_clicked" swapped="no"/>
                                                             <child>
-                                                            <widget class="GtkHBox" id="hbox271">
+                                                            <widget class="GtkHBox" id="hbox272">
                                                             <property name="visible">True</property>
                                                             <property name="can_focus">False</property>
                                                             <property name="spacing">10</property>
@@ -5209,7 +5243,7 @@
                                                             <property name="receives_default">True</property>
                                                             <signal name="clicked" 
handler="on_button_selector_start_jumps_reactive_clicked" swapped="no"/>
                                                             <child>
-                                                            <widget class="GtkHBox" id="hbox272">
+                                                            <widget class="GtkHBox" id="hbox558">
                                                             <property name="visible">True</property>
                                                             <property name="can_focus">False</property>
                                                             <property name="spacing">10</property>
@@ -5277,6 +5311,20 @@
                                                             </packing>
                                                             </child>
                                                             </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>
+                                                            <property name="fill">False</property>
+                                                            <property name="position">0</property>
+                                                            </packing>
+                                                            </child>
+                                                            </widget>
                                                             </child>
                                                             <child>
                                                             <widget class="GtkLabel" id="label670">
@@ -5290,10 +5338,266 @@
                                                             </packing>
                                                             </child>
                                                             <child>
+                                                            <widget class="GtkHBox" id="hbox275">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="spacing">30</property>
+                                                            <property name="homogeneous">True</property>
+                                                            <child>
+                                                            <widget class="GtkVBox" id="vbox281">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="spacing">16</property>
+                                                            <child>
+                                                            <widget class="GtkLabel" 
id="label_start_selector_races2">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="label">WICHRO or cabled 
photocells</property>
+                                                            </widget>
+                                                            <packing>
+                                                            <property name="expand">True</property>
+                                                            <property name="fill">True</property>
+                                                            <property name="position">0</property>
+                                                            </packing>
+                                                            </child>
+                                                            <child>
+                                                            <widget class="GtkTable" id="table26">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="n_rows">2</property>
+                                                            <property name="n_columns">2</property>
+                                                            <property name="column_spacing">16</property>
+                                                            <property name="row_spacing">16</property>
+                                                            <child>
+                                                            <widget class="GtkButton" id="button14">
+                                                            <property name="height_request">60</property>
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="receives_default">True</property>
+                                                            <signal name="clicked" 
handler="on_button_selector_start_runs_simple_clicked" swapped="no"/>
+                                                            <child>
+                                                            <widget class="GtkHBox" id="hbox502">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="spacing">10</property>
+                                                            <child>
+                                                            <widget class="GtkImage" 
id="image_mode_runs_small2">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="xpad">10</property>
+                                                            <property 
name="stock">gtk-missing-image</property>
+                                                            <property name="icon-size">2</property>
+                                                            </widget>
+                                                            <packing>
+                                                            <property name="expand">False</property>
+                                                            <property name="fill">True</property>
+                                                            <property name="position">0</property>
+                                                            </packing>
+                                                            </child>
+                                                            <child>
+                                                            <widget class="GtkLabel" id="label661">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="label" 
translatable="yes">Simple</property>
+                                                            </widget>
+                                                            <packing>
+                                                            <property name="expand">False</property>
+                                                            <property name="fill">True</property>
+                                                            <property name="position">1</property>
+                                                            </packing>
+                                                            </child>
+                                                            </widget>
+                                                            </child>
+                                                            </widget>
+                                                            <packing>
+                                                            <property name="x_options">GTK_FILL</property>
+                                                            <property name="y_options">GTK_EXPAND</property>
+                                                            </packing>
+                                                            </child>
+                                                            <child>
+                                                            <widget class="GtkButton" id="button15">
+                                                            <property name="height_request">60</property>
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="receives_default">True</property>
+                                                            <signal name="clicked" 
handler="on_button_selector_start_runs_intervallic_clicked" swapped="no"/>
+                                                            <child>
+                                                            <widget class="GtkHBox" id="hbox556">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="spacing">10</property>
+                                                            <child>
+                                                            <widget class="GtkImage" 
id="image_mode_runs_intervallic_small2">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="xpad">10</property>
+                                                            <property 
name="stock">gtk-missing-image</property>
+                                                            <property name="icon-size">2</property>
+                                                            </widget>
+                                                            <packing>
+                                                            <property name="expand">False</property>
+                                                            <property name="fill">True</property>
+                                                            <property name="position">0</property>
+                                                            </packing>
+                                                            </child>
+                                                            <child>
                                                             <widget class="GtkLabel" id="label674">
                                                             <property name="visible">True</property>
                                                             <property name="can_focus">False</property>
-                                                            <property name="label">races</property>
+                                                            <property name="label" 
translatable="yes">Intervallic</property>
+                                                            </widget>
+                                                            <packing>
+                                                            <property name="expand">False</property>
+                                                            <property name="fill">True</property>
+                                                            <property name="position">1</property>
+                                                            </packing>
+                                                            </child>
+                                                            </widget>
+                                                            </child>
+                                                            </widget>
+                                                            <packing>
+                                                            <property name="top_attach">1</property>
+                                                            <property name="bottom_attach">2</property>
+                                                            <property name="x_options">GTK_FILL</property>
+                                                            <property name="y_options">GTK_EXPAND</property>
+                                                            </packing>
+                                                            </child>
+                                                            <child>
+                                                            <widget class="GtkLabel" 
id="label_selector_start_runs_simple1">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="xalign">0</property>
+                                                            <property name="label" translatable="yes">Tests 
have 1 lap</property>
+                                                            </widget>
+                                                            <packing>
+                                                            <property name="left_attach">1</property>
+                                                            <property name="right_attach">2</property>
+                                                            <property name="x_options">GTK_FILL</property>
+                                                            <property name="y_options">GTK_EXPAND</property>
+                                                            </packing>
+                                                            </child>
+                                                            <child>
+                                                            <widget class="GtkLabel" 
id="label_selector_start_runs_intervallic1">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="xalign">0</property>
+                                                            <property name="label" translatable="yes">Tests 
have &gt;1 lap</property>
+                                                            </widget>
+                                                            <packing>
+                                                            <property name="left_attach">1</property>
+                                                            <property name="right_attach">2</property>
+                                                            <property name="top_attach">1</property>
+                                                            <property name="bottom_attach">2</property>
+                                                            <property name="x_options"/>
+                                                            <property name="y_options">GTK_EXPAND</property>
+                                                            </packing>
+                                                            </child>
+                                                            </widget>
+                                                            <packing>
+                                                            <property name="expand">True</property>
+                                                            <property name="fill">True</property>
+                                                            <property name="position">1</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="GtkHBox" id="hbox557">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <child>
+                                                            <widget class="GtkVBox" id="vbox282">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <child>
+                                                            <widget class="GtkLabel" 
id="label_start_selector_races3">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="label">Encoder</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="hbox559">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <child>
+                                                            <widget class="GtkButton" id="button16">
+                                                            <property name="height_request">60</property>
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="receives_default">True</property>
+                                                            <signal name="clicked" 
handler="on_button_selector_start_race_encoder_clicked" swapped="no"/>
+                                                            <child>
+                                                            <widget class="GtkHBox" id="hbox560">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="spacing">10</property>
+                                                            <child>
+                                                            <widget class="GtkImage" 
id="image_mode_race_encoder_small1">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="xpad">10</property>
+                                                            <property 
name="stock">gtk-missing-image</property>
+                                                            <property name="icon-size">2</property>
+                                                            </widget>
+                                                            <packing>
+                                                            <property name="expand">False</property>
+                                                            <property name="fill">True</property>
+                                                            <property name="position">0</property>
+                                                            </packing>
+                                                            </child>
+                                                            <child>
+                                                            <widget class="GtkLabel" id="label678">
+                                                            <property name="visible">True</property>
+                                                            <property name="can_focus">False</property>
+                                                            <property name="label">Race Analyzer</property>
+                                                            </widget>
+                                                            <packing>
+                                                            <property name="expand">False</property>
+                                                            <property name="fill">True</property>
+                                                            <property name="position">1</property>
+                                                            </packing>
+                                                            </child>
+                                                            </widget>
+                                                            </child>
+                                                            </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>
+                                                            <property name="fill">False</property>
+                                                            <property name="position">1</property>
+                                                            </packing>
+                                                            </child>
+                                                            </widget>
+                                                            <packing>
+                                                            <property name="expand">False</property>
+                                                            <property name="fill">False</property>
+                                                            <property name="position">0</property>
+                                                            </packing>
+                                                            </child>
+                                                            </widget>
+                                                            <packing>
+                                                            <property name="expand">False</property>
+                                                            <property name="fill">True</property>
+                                                            <property name="position">1</property>
+                                                            </packing>
+                                                            </child>
                                                             </widget>
                                                             <packing>
                                                             <property name="position">1</property>
@@ -5312,7 +5616,7 @@
                                                             </packing>
                                                             </child>
                                                             <child>
-                                                            <widget class="GtkVBox" id="vbox280">
+                                                            <widget class="GtkVBox" id="vbox284">
                                                             <property name="visible">True</property>
                                                             <property name="can_focus">False</property>
                                                             <child>
@@ -5425,33 +5729,6 @@
                                                             <packing>
                                                             <property name="expand">True</property>
                                                             <property name="fill">False</property>
-                                                            <property name="position">1</property>
-                                                            </packing>
-                                                            </child>
-                                                            <child>
-                                                            <widget class="GtkHBox" id="hbox224">
-                                                            <property name="visible">True</property>
-                                                            <property name="can_focus">False</property>
-                                                            <child>
-                                                            <widget class="GtkButton" id="button_menu_2_2_1">
-                                                            <property name="label">2.2.1 menu</property>
-                                                            <property name="visible">True</property>
-                                                            <property name="can_focus">True</property>
-                                                            <property name="receives_default">True</property>
-                                                            <signal name="clicked" 
handler="on_button_view_menu_2_2_1_clicked" swapped="no"/>
-                                                            </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>
-                                                            </widget>
-                                                            <packing>
-                                                            <property name="expand">False</property>
-                                                            <property name="fill">False</property>
-                                                            <property name="pack_type">end</property>
                                                             <property name="position">2</property>
                                                             </packing>
                                                             </child>
diff --git a/src/Makefile.am b/src/Makefile.am
index d3e069071..ebc2b9448 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -446,6 +446,7 @@ RESOURCES = \
        ../images/mini/plataforma_contactos.jpg,mini/plataforma_contactos.jpg \
        ../images/infrared.jpg,infrared.jpg \
        ../images/mini/infrared.jpg,mini/infrared.jpg \
+       ../images/md/start-24-blue.png,start.png \
        ../images/md/ic_notifications_blue_1x.png,stock_bell.png \
        ../images/md/ic_notifications_active_blue_1x.png,stock_bell_active.png \
        ../images/md/ic_notifications_none_blue_1x.png,stock_bell_none.png \
diff --git a/src/gui/app1/chronojump.cs b/src/gui/app1/chronojump.cs
index fc2419b15..6b44702e3 100644
--- a/src/gui/app1/chronojump.cs
+++ b/src/gui/app1/chronojump.cs
@@ -4405,7 +4405,8 @@ public partial class ChronoJumpWindow
 
                //TODO: depending on mode, force click on button_menu_2_2_2_clicked to ensure all widgets are 
updated
                //if no current mode, then jumps
-
+               radio_menu_2_2_2_jumps.Active = true;
+               on_button_menu_2_2_2_clicked (radio_menu_2_2_2_jumps, args);
        }
        private void on_button_view_menu_2_2_1_clicked (object o, EventArgs args)
        {
@@ -4424,6 +4425,7 @@ public partial class ChronoJumpWindow
        [Widget] Gtk.EventBox eventbox_radio_menu_2_2_2_elastic;
        [Widget] Gtk.EventBox eventbox_radio_menu_2_2_2_weights;
        [Widget] Gtk.EventBox eventbox_radio_menu_2_2_2_inertial;
+       [Widget] Gtk.EventBox eventbox_label_menu_2_2_2_title;
        [Widget] Gtk.Notebook notebook_menu_2_2_2; //0 jumps, 1 races, 2 isometric/elastic/weights/inertial
        [Widget] Gtk.Label label_selector_menu_2_2_2_title;
        [Widget] Gtk.Label label_selector_menu_2_2_2_desc;
@@ -4435,13 +4437,14 @@ public partial class ChronoJumpWindow
                if (o == (object) radio_menu_2_2_2_jumps)
                {
                        title = "Jumps";
-                       desc = "Jumps with contact platform";
+                       desc = "Measured by a contact platform";
                        notebook_menu_2_2_2.CurrentPage = 0;
                }
                else if (o == (object) radio_menu_2_2_2_races)
                {
                        title = "Races";
-                       desc = "Races with photocells (Wichro or wired), or RaceAnalyzer";
+                       //desc = "Races with photocells (Wichro or wired), or RaceAnalyzer";
+                       desc = "Measured by …";
                        notebook_menu_2_2_2.CurrentPage = 1;
                }
                else if (o == (object) radio_menu_2_2_2_isometric)
diff --git a/src/gui/app1/icons.cs b/src/gui/app1/icons.cs
index bbd7d5be1..a865f6611 100644
--- a/src/gui/app1/icons.cs
+++ b/src/gui/app1/icons.cs
@@ -104,6 +104,7 @@ public partial class ChronoJumpWindow
        [Widget] Gtk.Image image_selector_start_displ_weights;
        [Widget] Gtk.Image image_selector_start_inertial;
 
+       //[Widget] Gtk.Image image_down_menu_2_2_2;
        [Widget] Gtk.Image image_start;
        [Widget] Gtk.Image image_mode_jumps_small;
        [Widget] Gtk.Image image_mode_jumps_small1;
@@ -111,9 +112,12 @@ public partial class ChronoJumpWindow
        [Widget] Gtk.Image image_mode_jumps_reactive_small1;
        [Widget] Gtk.Image image_mode_runs_small;
        [Widget] Gtk.Image image_mode_runs_small1;
+       [Widget] Gtk.Image image_mode_runs_small2;
        [Widget] Gtk.Image image_mode_runs_intervallic_small;
        [Widget] Gtk.Image image_mode_runs_intervallic_small1;
+       [Widget] Gtk.Image image_mode_runs_intervallic_small2;
        [Widget] Gtk.Image image_mode_race_encoder_small;
+       [Widget] Gtk.Image image_mode_race_encoder_small1;
        [Widget] Gtk.Image image_mode_pulses_small;
        [Widget] Gtk.Image image_mode_multi_chronopic_small;
        [Widget] Gtk.Image image_mode_encoder_gravitatory;
@@ -574,6 +578,8 @@ public partial class ChronoJumpWindow
                pixbuf = new Pixbuf (null, Util.GetImagePath(false) + "image_down.png");
                image_persons_down.Pixbuf = pixbuf;
                */
+               //pixbuf = new Pixbuf (null, Util.GetImagePath(false) + "image_down.png");
+               //image_down_menu_2_2_2.Pixbuf = pixbuf;
                
                //persons buttons
                pixbuf = new Pixbuf (null, Util.GetImagePath(false) + "image_person_add.png");
@@ -689,14 +695,17 @@ public partial class ChronoJumpWindow
                pixbuf = new Pixbuf (null, Util.GetImagePath(false) + "image_run_simple.png");
                image_mode_runs_small.Pixbuf = pixbuf;
                image_mode_runs_small1.Pixbuf = pixbuf;
+               image_mode_runs_small2.Pixbuf = pixbuf;
                image_change_modes_contacts_runs_simple.Pixbuf = pixbuf;
                pixbuf = new Pixbuf (null, Util.GetImagePath(false) + "image_run_multiple.png");
                image_mode_runs_intervallic_small.Pixbuf = pixbuf;
                image_mode_runs_intervallic_small1.Pixbuf = pixbuf;
+               image_mode_runs_intervallic_small2.Pixbuf = pixbuf;
                image_change_modes_contacts_runs_intervallic.Pixbuf = pixbuf;
                image_change_modes_contacts_force_sensor.Pixbuf = new Pixbuf (null, Util.GetImagePath(false) 
+ "force_sensor_icon.png");
                pixbuf = new Pixbuf (null, Util.GetImagePath(false) + "race_encoder_icon.png");
                image_mode_race_encoder_small.Pixbuf = pixbuf;
+               image_mode_race_encoder_small1.Pixbuf = pixbuf;
                image_change_modes_contacts_runs_encoder.Pixbuf = pixbuf;
 
                pixbuf = new Pixbuf (null, Util.GetImagePath(false) + "run_2x.png");


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]