mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-09-06 05:08:29 +02:00
keyinput: outsource keytables into own header file
for better common usage
Origin commit data
------------------
Commit: 81c7d5c4a2
Author: Thilo Graf <dbt@novatux.de>
Date: 2019-03-12 (Tue, 12 Mar 2019)
This commit is contained in:
@@ -39,63 +39,8 @@
|
||||
#include <gui/widget/msgbox.h>
|
||||
|
||||
#include <system/helpers.h>
|
||||
#include <gui/widget/keyboard_input.h>
|
||||
|
||||
static std::string keys_english[2][KEY_ROWS][KEY_COLUMNS] =
|
||||
{
|
||||
{
|
||||
{ "`", "1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "-", "=", "§" },
|
||||
{ "q", "w", "e", "r", "t", "y", "u", "i", "o", "p", "[", "]", "{", "}" },
|
||||
{ "a", "s", "d", "f", "g", "h", "j", "k", "l", ";", "\'", "\\", ":", "\"" },
|
||||
{ "z", "x", "c", "v", "b", "n", "m", ",", ".", "/", "<", ">", "?", " " }
|
||||
},
|
||||
{
|
||||
{ "~", "!", "@", "#", "$", "%", "^", "&", "*", "(", ")", "_", "+", "§", },
|
||||
{ "Q", "W", "E", "R", "T", "Y", "U", "I", "O", "P", "{", "}", "{", "}" },
|
||||
{ "A", "S", "D", "F", "G", "H", "J", "K", "L", ";", "\'", "\\", ":", "\"" },
|
||||
{ "Z", "X", "C", "V", "B", "N", "M", ",", ".", "/", "<", ">", "?", " " }
|
||||
}
|
||||
};
|
||||
|
||||
static std::string keys_deutsch[2][KEY_ROWS][KEY_COLUMNS] =
|
||||
{
|
||||
{
|
||||
{ "°", "1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "ß", "´", "@" },
|
||||
{ "q", "w", "e", "r", "t", "z", "u", "i", "o", "p", "ü", "+", "~", "/" },
|
||||
{ "a", "s", "d", "f", "g", "h", "j", "k", "l", "ö", "ä", "#", "[", "]" },
|
||||
{ "y", "x", "c", "v", "b", "n", "m", ",", ".", "-", "|", "<", ">", " " }
|
||||
},
|
||||
{
|
||||
{ "^", "!", "\"","§", "$", "%", "&", "/", "(", ")", "=", "?", "`", "€" },
|
||||
{ "Q", "W", "E", "R", "T", "Z", "U", "I", "O", "P", "Ü", "*", "\\","/" },
|
||||
{ "A", "S", "D", "F", "G", "H", "J", "K", "L", "Ö", "Ä", "\'","{", "}" },
|
||||
{ "Y", "X", "C", "V", "B", "N", "M", ";", ":", "_", "²", "³", "µ", " " }
|
||||
}
|
||||
};
|
||||
|
||||
static std::string keys_russian[2][KEY_ROWS][KEY_COLUMNS] =
|
||||
{
|
||||
{
|
||||
{ "ё", "1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "-", "=", "§" },
|
||||
{ "й", "ц", "у", "к", "е", "н", "г", "ш", "щ", "з", "х", "ъ", "[", "]" },
|
||||
{ "ф", "ы", "в", "а", "п", "р", "о", "л", "д", "ж", "э", "\\", ":", "\"" },
|
||||
{ "я", "ч", "с", "м", "и", "т", "ь", "б", "ю", "/", ".", ",", "?", " " }
|
||||
},
|
||||
{
|
||||
{ "Ё", "!", "@", "#", "$", "%", "^", "&", "*", "(", ")", "_", "+", "§" },
|
||||
{ "Й", "Ц", "У", "К", "Е", "Н", "Г", "Ш", "Щ", "З", "Х", "Х", "{", "}" },
|
||||
{ "Ф", "Ы", "В", "А", "П", "Р", "О", "Л", "Д", "Ж", "Э", "|", ";", "~" },
|
||||
{ "Я", "Ч", "С", "М", "И", "Т", "Ь", "Б", "Ю", "?", "<", ">", "?", " " }
|
||||
}
|
||||
};
|
||||
|
||||
struct keyboard_layout keyboards[] =
|
||||
{
|
||||
{ "English", "english", keys_english },
|
||||
{ "Deutsch", "deutsch", keys_deutsch },
|
||||
//NI { "Русский", "russkij", keys_russian },
|
||||
};
|
||||
#define LAYOUT_COUNT (sizeof(keyboards)/sizeof(struct keyboard_layout))
|
||||
#include "keyboard_input.h"
|
||||
#include "keyboard_keys.h"
|
||||
|
||||
std::string UTF8ToString(const char * &text)
|
||||
{
|
||||
|
Reference in New Issue
Block a user