forked from notsecure/uTox
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathui_i18n_decls.h
144 lines (122 loc) · 3.03 KB
/
ui_i18n_decls.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
enum {
LANG_BG,
LANG_DE,
LANG_EN,
LANG_ES,
LANG_FR,
LANG_HI, //5
LANG_JA,
LANG_IT,
LANG_LV,
LANG_NL,
LANG_NO, //10
LANG_BR,
LANG_PL,
LANG_RO,
LANG_RU,
LANG_TR, //15
LANG_UA,
LANG_CN,
LANG_TW,
LANG_CS,
LANG_DK,
//Do NOT add new values beyond this point, or alter LANGS_MAX accordingly.
LANGS_MAX = LANG_DK
};
enum {
//This ensures that all statically initialized to zero UI_STRING_ID vars
//will render as canary "BUG. PLEASE REPORT." strings.
UI_STRING_ID_INVALID = 0,
STR_REQ_SENT,
STR_REQ_RESOLVE,
STR_REQ_INVALID_ID,
STR_REQ_EMPTY_ID,
STR_REQ_LONG_MSG,
STR_REQ_NO_MSG,
STR_REQ_SELF_ID,
STR_REQ_ALREADY_FRIENDS,
STR_REQ_UNKNOWN,
STR_REQ_BAD_CHECKSUM,
STR_REQ_BAD_NOSPAM,
STR_REQ_NO_MEMORY,
STR_TRANSFER_NEW,
STR_TRANSFER_STARTED,
STR_TRANSFER___,
STR_TRANSFER_PAUSED,
STR_TRANSFER_BROKEN,
STR_TRANSFER_CANCELLED,
STR_TRANSFER_COMPLETE,
STR_CALL_CANCELLED,
STR_CALL_INVITED,
STR_CALL_RINGING,
STR_CALL_STARTED,
STR_ADDFRIENDS,
STR_TOXID,
STR_MESSAGE,
STR_SEARCHFRIENDS,
STR_ADD, STR_BUTTON_ADD_FRIEND = STR_ADD, STR_BUTTON_ACCEPT_FRIEND = STR_ADD,
STR_SWITCHPROFILE,
STR_FRIENDREQUEST,
STR_USERSETTINGS,
STR_NAME,
STR_STATUSMESSAGE,
STR_PREVIEW,
STR_DEVICESELECTION,
STR_AUDIOINPUTDEVICE,
STR_AUDIOOUTPUTDEVICE,
STR_VIDEOINPUTDEVICE,
STR_OTHERSETTINGS,
STR_DPI,
STR_SAVELOCATION,
STR_LANGUAGE,
STR_NETWORK,
STR_IPV6,
STR_UDP,
STR_PROXY,
STR_WARNING,
STR_LOGGING,
STR_AUDIONOTIFICATIONS,
STR_IS_TYPING,
STR_COPY, STR_COPY_TOX_ID = STR_COPY,
STR_COPYWITHOUTNAMES,
STR_CUT,
STR_PASTE,
STR_DELETE,
STR_SELECTALL,
STR_REMOVE, STR_REMOVE_FRIEND = STR_REMOVE,
STR_LEAVE, STR_REMOVE_GROUP = STR_LEAVE,
STR_ACCEPT, STR_REQ_ACCEPT = STR_ACCEPT,
STR_IGNORE, STR_REQ_DECLINE = STR_IGNORE,
STR_CLICKTOSAVE,
STR_CLICKTOOPEN,
STR_CANCELLED,
STR_DPI_TINY,
STR_DPI_NORMAL,
STR_DPI_BIG,
STR_DPI_LARGE,
STR_DPI_HUGE,
STR_CONTACTS_FILTER_ALL,
STR_CONTACTS_FILTER_ONLINE,
STR_CONTACTS_FILTER_EDIT_HINT,
STR_PROXY_DISABLED,
STR_PROXY_FALLBACK,
STR_PROXY_ALWAYS_USE,
STR_PROXY_EDIT_HINT_IP,
STR_PROXY_EDIT_HINT_PORT,
STR_NO,
STR_YES,
STR_VIDEO_IN_NONE, STR_AUDIO_IN_NONE = STR_VIDEO_IN_NONE,
STR_VIDEO_IN_DESKTOP,
STR_AUDIO_IN_DEFAULT_LOOPBACK,
STR_DEFAULT_FRIEND_REQUEST_MESSAGE,
STR_WINDOW_TITLE_VIDEO_PREVIEW,
STR_LANG_NATIVE_NAME,
STR_LANG_ENGLISH_NAME,
//Do NOT add new values beyond this point, or alter STRS_MAX accordingly.
STRS_MAX = STR_LANG_ENGLISH_NAME
};
typedef uint8_t UI_LANG_ID;
typedef uint16_t UI_STRING_ID;
STRING* ui_gettext(UI_LANG_ID lang, UI_STRING_ID string_id);
UI_LANG_ID ui_guess_lang_by_posix_locale(const char* locale, UI_LANG_ID deflt);
UI_LANG_ID ui_guess_lang_by_windows_lang_id(uint16_t lang_id, UI_LANG_ID deflt);