Revert "Translate GDK_KEY_KP_Decimal according to locale"
This reverts commit 3b65a6a42e
.
Too much controversy for this minor improvement.
See https://bugzilla.gnome.org/show_bug.cgi?id=756751
This commit is contained in:
@ -28,8 +28,6 @@
|
|||||||
#include "gdk.h"
|
#include "gdk.h"
|
||||||
#include "gdkalias.h"
|
#include "gdkalias.h"
|
||||||
|
|
||||||
#include <locale.h>
|
|
||||||
|
|
||||||
/* Thanks to Markus G. Kuhn <mkuhn@acm.org> for the ksysym<->Unicode
|
/* Thanks to Markus G. Kuhn <mkuhn@acm.org> for the ksysym<->Unicode
|
||||||
* mapping functions, from the xterm sources.
|
* mapping functions, from the xterm sources.
|
||||||
*/
|
*/
|
||||||
@ -1656,23 +1654,6 @@ static const struct {
|
|||||||
{ 0x0ef7, 0x318e }, /* Hangul_AraeAE ㆎ HANGUL LETTER ARAEAE */
|
{ 0x0ef7, 0x318e }, /* Hangul_AraeAE ㆎ HANGUL LETTER ARAEAE */
|
||||||
};
|
};
|
||||||
|
|
||||||
static gunichar
|
|
||||||
get_decimal_point (void)
|
|
||||||
{
|
|
||||||
struct lconv *locale_data;
|
|
||||||
const gchar *decimal_point;
|
|
||||||
gunichar ret;
|
|
||||||
|
|
||||||
locale_data = localeconv ();
|
|
||||||
decimal_point = locale_data->decimal_point;
|
|
||||||
|
|
||||||
ret = g_utf8_get_char_validated (decimal_point, -1);
|
|
||||||
if (ret != (gunichar)-2 && ret != (gunichar)-1)
|
|
||||||
return ret;
|
|
||||||
|
|
||||||
return (gunichar) '.';
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* gdk_unicode_to_keyval:
|
* gdk_unicode_to_keyval:
|
||||||
* @wc: a ISO10646 encoded character
|
* @wc: a ISO10646 encoded character
|
||||||
@ -1695,9 +1676,6 @@ gdk_unicode_to_keyval (guint32 wc)
|
|||||||
(wc >= 0x00a0 && wc <= 0x00ff))
|
(wc >= 0x00a0 && wc <= 0x00ff))
|
||||||
return wc;
|
return wc;
|
||||||
|
|
||||||
if (wc == 0xffae)
|
|
||||||
return (guint32) get_decimal_point ();
|
|
||||||
|
|
||||||
/* Binary search in table */
|
/* Binary search in table */
|
||||||
while (max >= min) {
|
while (max >= min) {
|
||||||
mid = (min + max) / 2;
|
mid = (min + max) / 2;
|
||||||
|
Reference in New Issue
Block a user