[chronojump] Ensure check_menu_session is ok even starting without session



commit 9564baa3edd4dd30342b3021fc4f896e11933725
Author: Xavier de Blas <xaviblas gmail com>
Date:   Wed Jul 28 13:32:45 2021 +0200

    Ensure check_menu_session is ok even starting without session

 glade/app1.glade           | 31 ++++++++++++++++++-------------
 src/gui/app1/chronojump.cs |  8 ++++++--
 2 files changed, 24 insertions(+), 15 deletions(-)
---
diff --git a/glade/app1.glade b/glade/app1.glade
index 02bd04110..5f7d794c4 100644
--- a/glade/app1.glade
+++ b/glade/app1.glade
@@ -482,7 +482,6 @@
                                                         <property name="can_focus">True</property>
                                                         <property name="receives_default">False</property>
                                                         <property name="tooltip" 
translatable="yes">Session</property>
-                                                        <property name="active">True</property>
                                                         <property name="draw_indicator">False</property>
                                                         <signal name="clicked" 
handler="on_check_menu_session_or_persons_clicked" swapped="no"/>
                                                         <child>
@@ -25793,6 +25792,9 @@ Concentric</property>
                                                             <child>
                                                             <placeholder/>
                                                             </child>
+                                                            <child>
+                                                            <placeholder/>
+                                                            </child>
                                                             </widget>
                                                             <packing>
                                                             <property name="expand">False</property>
@@ -32104,18 +32106,6 @@ 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>
@@ -32152,6 +32142,18 @@ 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>
@@ -41395,6 +41397,9 @@ then click this button.</property>
                                                             <child>
                                                             <placeholder/>
                                                             </child>
+                                                            <child>
+                                                            <placeholder/>
+                                                            </child>
                                                             </widget>
                                                             <packing>
                                                             <property name="expand">False</property>
diff --git a/src/gui/app1/chronojump.cs b/src/gui/app1/chronojump.cs
index 3e837aa66..cddcb3046 100644
--- a/src/gui/app1/chronojump.cs
+++ b/src/gui/app1/chronojump.cs
@@ -789,8 +789,12 @@ public partial class ChronoJumpWindow
 
                                // 3) put preference to true again
                                SqlitePreferences.Update(SqlitePreferences.LoadLastSessionAtStart, true, 
false);
-                       }
-               }
+                       } else
+                               if(! check_menu_session.Active)
+                                       check_menu_session.Click(); //have session menu opened
+               } else
+                       if(! check_menu_session.Active)
+                               check_menu_session.Click(); //have sesion menu opened
 
                if(! showSendLog && ! showSocialNetworkPoll && preferences.loadLastModeAtStart &&
                                preferences.lastMode != Constants.Menuitem_modes.UNDEFINED && ! 
configChronojump.Compujump)


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