gnucash maint: Multiple changes pushed

Robert Fewell bobit at code.gnucash.org
Tue Apr 13 06:06:07 EDT 2021


Updated	 via  https://github.com/Gnucash/gnucash/commit/4e653729 (commit)
	 via  https://github.com/Gnucash/gnucash/commit/b9789b66 (commit)
	 via  https://github.com/Gnucash/gnucash/commit/48ebc24d (commit)
	from  https://github.com/Gnucash/gnucash/commit/a008a37b (commit)



commit 4e653729ba8f65b33dc5e1c916e70a07812462c1
Author: Robert Fewell <14uBobIT at gmail.com>
Date:   Tue Apr 13 11:01:36 2021 +0100

    ESC key was not working on load of Scheduled Transaction Editor
    
    This is due to trying to grab focus on the sheet when it was not
    realized so add a check for the sheet being realized before grabbing
    focus on it.

diff --git a/gnucash/gnome/gnc-split-reg.c b/gnucash/gnome/gnc-split-reg.c
index d27f34733..456cd36e9 100644
--- a/gnucash/gnome/gnc-split-reg.c
+++ b/gnucash/gnome/gnc-split-reg.c
@@ -1800,9 +1800,9 @@ gnc_split_reg_focus_on_sheet (GNCSplitReg *gsr)
     GnucashRegister *reg = gsr->reg;
     GnucashSheet *sheet = gnucash_register_get_sheet (reg);
 
-    // Make sure the sheet is the focus
-    if (!gtk_widget_has_focus(GTK_WIDGET (sheet)))
-        gtk_widget_grab_focus (GTK_WIDGET (sheet));
+    // Make sure the sheet is the focus only when it is realized
+    if (!gtk_widget_has_focus(GTK_WIDGET(sheet)) && gtk_widget_get_realized (GTK_WIDGET(sheet)))
+        gtk_widget_grab_focus (GTK_WIDGET(sheet));
 }
 
 void

commit b9789b66cabbc96feac5afabf9468b9d53ddea79
Author: Robert Fewell <14uBobIT at gmail.com>
Date:   Tue Apr 13 10:48:14 2021 +0100

    Fix an alignment of widgets in the schedule transaction editor

diff --git a/gnucash/gtkbuilder/dialog-sx.glade b/gnucash/gtkbuilder/dialog-sx.glade
index 1551d9131..b13052791 100644
--- a/gnucash/gtkbuilder/dialog-sx.glade
+++ b/gnucash/gtkbuilder/dialog-sx.glade
@@ -943,6 +943,7 @@
                             <property name="visible">True</property>
                             <property name="can_focus">False</property>
                             <property name="valign">start</property>
+                            <property name="spacing">6</property>
                             <child>
                               <object class="GtkSpinButton" id="remind_days">
                                 <property name="visible">True</property>
@@ -1002,6 +1003,7 @@
                             <property name="visible">True</property>
                             <property name="can_focus">False</property>
                             <property name="valign">start</property>
+                            <property name="spacing">6</property>
                             <child>
                               <object class="GtkSpinButton" id="advance_days">
                                 <property name="visible">True</property>
@@ -1063,6 +1065,8 @@
                             <property name="can_focus">True</property>
                             <property name="receives_default">False</property>
                             <property name="halign">start</property>
+                            <property name="margin_start">12</property>
+                            <property name="margin_end">12</property>
                             <property name="use_underline">True</property>
                             <property name="draw_indicator">True</property>
                           </object>
@@ -1173,6 +1177,7 @@
                             <property name="visible">True</property>
                             <property name="can_focus">False</property>
                             <property name="margin_start">12</property>
+                            <property name="margin_end">12</property>
                             <property name="row_spacing">3</property>
                             <property name="column_spacing">6</property>
                             <child>
@@ -1240,8 +1245,6 @@
                                 <property name="visible">True</property>
                                 <property name="can_focus">False</property>
                                 <property name="halign">start</property>
-                                <property name="margin_start">6</property>
-                                <property name="margin_end">6</property>
                                 <property name="label" translatable="yes">remaining</property>
                               </object>
                               <packing>

commit 48ebc24d99481cad056ee2c9cf67c317388db74f
Author: Robert Fewell <14uBobIT at gmail.com>
Date:   Tue Apr 13 10:42:30 2021 +0100

    Bug 798151 - SLR does not scroll to entry
    
    If a row requires an entry and is not visible when you press OK, the
    entry is detached from the row and is confusing so scroll the tree view
    to make the required row visible.

diff --git a/gnucash/gnome/dialog-sx-since-last-run.c b/gnucash/gnome/dialog-sx-since-last-run.c
index 67c87ee6b..2d435507d 100644
--- a/gnucash/gnome/dialog-sx-since-last-run.c
+++ b/gnucash/gnome/dialog-sx-since-last-run.c
@@ -1168,6 +1168,9 @@ dialog_response_cb (GtkDialog *dialog, gint response_id, GncSxSinceLastRunDialog
 
             gtk_tree_view_set_cursor (app_dialog->instance_view, variable_path, variable_col, start_editing);
 
+            gtk_tree_view_scroll_to_cell (app_dialog->instance_view, variable_path, variable_col,
+                                          TRUE, 0.5, 0.5);
+
             gtk_tree_path_free (variable_path);
             g_list_foreach (unbound_variables, (GFunc)g_free, NULL);
             g_list_free (unbound_variables);



Summary of changes:
 gnucash/gnome/dialog-sx-since-last-run.c | 3 +++
 gnucash/gnome/gnc-split-reg.c            | 6 +++---
 gnucash/gtkbuilder/dialog-sx.glade       | 7 +++++--
 3 files changed, 11 insertions(+), 5 deletions(-)



More information about the gnucash-changes mailing list