gnucash maint: Bug 796665 - Backspace Key Inoperable After Ctrl+V
John Ralls
jralls at code.gnucash.org
Mon Jun 25 16:48:01 EDT 2018
Updated via https://github.com/Gnucash/gnucash/commit/60117491 (commit)
from https://github.com/Gnucash/gnucash/commit/246257de (commit)
commit 6011749151793399727371db335a0e3dd9723d81
Author: John Ralls <jralls at ceridwen.us>
Date: Mon Jun 25 13:42:45 2018 -0700
Bug 796665 - Backspace Key Inoperable After Ctrl+V
Remove the gtk_editable_set_editable toggles in
gnc_item_edit_cut_keyboard and gnc_item_edit_paste_keyboard. These were
added as a work-around to gnucash_sheet_key_press_event_internal leaving
the sheet not-editable after a regular key event. That was removed to
fix input-method key handling.
The original addition of that enable/disable toggle was apparently a
hack to fix the date-field accelerators and the use of the account
separator in the transfer field. Both seem to work fine with the
protection removed.
diff --git a/gnucash/register/register-gnome/gnucash-item-edit.c b/gnucash/register/register-gnome/gnucash-item-edit.c
index d62e4f2..f4cabb7 100644
--- a/gnucash/register/register-gnome/gnucash-item-edit.c
+++ b/gnucash/register/register-gnome/gnucash-item-edit.c
@@ -371,9 +371,7 @@ gnc_item_edit_configure (GncItemEdit *item_edit)
void
gnc_item_edit_cut_clipboard (GncItemEdit *item_edit)
{
- gtk_editable_set_editable(GTK_EDITABLE(item_edit->editor), TRUE);
gtk_editable_cut_clipboard(GTK_EDITABLE(item_edit->editor));
- gtk_editable_set_editable(GTK_EDITABLE(item_edit->editor), FALSE);
}
void
@@ -385,9 +383,7 @@ gnc_item_edit_copy_clipboard (GncItemEdit *item_edit)
void
gnc_item_edit_paste_clipboard (GncItemEdit *item_edit)
{
- gtk_editable_set_editable(GTK_EDITABLE(item_edit->editor), TRUE);
gtk_editable_paste_clipboard(GTK_EDITABLE(item_edit->editor));
- gtk_editable_set_editable(GTK_EDITABLE(item_edit->editor), FALSE);
}
diff --git a/gnucash/register/register-gnome/gnucash-sheet.c b/gnucash/register/register-gnome/gnucash-sheet.c
index bb32e93..3b54bb4 100644
--- a/gnucash/register/register-gnome/gnucash-sheet.c
+++ b/gnucash/register/register-gnome/gnucash-sheet.c
@@ -1810,7 +1810,6 @@ gnucash_sheet_key_press_event_internal (GtkWidget *widget, GdkEventKey *event)
if (pass_on)
{
gboolean result = FALSE;
-
// If sheet is readonly, entry is not realized
if (gtk_widget_get_realized (GTK_WIDGET(sheet->entry)))
result = gtk_widget_event (sheet->entry, (GdkEvent *) event);
Summary of changes:
gnucash/register/register-gnome/gnucash-item-edit.c | 4 ----
gnucash/register/register-gnome/gnucash-sheet.c | 1 -
2 files changed, 5 deletions(-)
More information about the gnucash-changes
mailing list