mirror of
https://github.com/Gnucash/gnucash.git
synced 2024-11-25 18:30:23 -06:00
bug798712 Regional Decimal Point not recognized in budgets
This commit is contained in:
parent
1020bde89c
commit
70693d133e
@ -72,6 +72,7 @@
|
||||
#include "gnc-recurrence.h"
|
||||
#include "Recurrence.h"
|
||||
#include "gnc-tree-model-account-types.h"
|
||||
#include "gnc-locale-utils.h"
|
||||
|
||||
|
||||
/* This static indicates the debugging module that this .o belongs to. */
|
||||
@ -775,8 +776,22 @@ gbv_key_press_cb (GtkWidget *widget, GdkEventKey *event, gpointer user_data)
|
||||
if (event->type != GDK_KEY_PRESS || !priv->temp_cr)
|
||||
return FALSE;
|
||||
|
||||
#ifdef G_OS_WIN32
|
||||
/* gdk never sends GDK_KEY_KP_Decimal on win32. See #486658 */
|
||||
if (event->hardware_keycode == VK_DECIMAL)
|
||||
event->keyval = GDK_KEY_KP_Decimal;
|
||||
#endif
|
||||
|
||||
switch (event->keyval)
|
||||
{
|
||||
case GDK_KEY_KP_Decimal:
|
||||
if (event->keyval == GDK_KEY_KP_Decimal)
|
||||
{
|
||||
struct lconv *lc = gnc_localeconv ();
|
||||
event->keyval = lc->mon_decimal_point[0];
|
||||
event->string[0] = lc->mon_decimal_point[0];
|
||||
}
|
||||
return FALSE;
|
||||
case GDK_KEY_Tab:
|
||||
case GDK_KEY_ISO_Left_Tab:
|
||||
case GDK_KEY_KP_Tab:
|
||||
|
Loading…
Reference in New Issue
Block a user