ecore_cocoa: switch keys to map correctly on OS-X.

os-x is notoriously switching the meaning of those keys
calling "BackSpace" "Delete, and "Delete" "Forward Delete"

Original patch by Pierre Tardy
This commit is contained in:
Nicolas Aguirre 2014-01-11 10:23:50 +01:00 committed by Cedric BAIL
parent e4538b94d1
commit 6d7caf9450
1 changed files with 5 additions and 3 deletions

View File

@ -14,7 +14,8 @@ static const struct _ecore_cocoa_keys_s keystable[] =
{ 0, "0x00", "" },
{ 0, "First", "" },
{ 3, "Return", "\015" },
{ 8, "BackSpace", "\010" },
// OS-X's backspace and Delete are reversed!
{ 8, "Delete", "\010" },
{ 9, "Tab", "\011" },
{ 12, "Clear", "" },
{ 13, "Return", "\015" },
@ -90,10 +91,11 @@ static const struct _ecore_cocoa_keys_s keystable[] =
{ 123, "braceleft", "" },
{ 124, "pipe", "" },
{ 125, "braceright", "" },
{ 127, "Delete", "\177" },
// OS-X's backspace and Delete are reversed!
{ 127, "BackSpace", "\177" },
{ 126, "asciitilde", "~" },
{ 160, "w0", "" },
{ 160, "w0", "" },
{ 161, "w1", "" },
{ 162, "w2", "" },
{ 163, "w3", "" },