diff options
author | Kirill Volinsky <mataes2007@gmail.com> | 2013-04-29 21:26:28 +0000 |
---|---|---|
committer | Kirill Volinsky <mataes2007@gmail.com> | 2013-04-29 21:26:28 +0000 |
commit | 53a415159610fdc005db6c3289bf614d25c3d78e (patch) | |
tree | 68ce63a44a12f53c1d5b114416b15966e7922371 /protocols/Skype/src/skype_dialogs.cpp | |
parent | 792732d7ef1ec4445f02e0b9c0b6eda6879db3a6 (diff) |
language only one
current version doesn't working
git-svn-id: http://svn.miranda-ng.org/main/trunk@4570 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Skype/src/skype_dialogs.cpp')
-rw-r--r-- | protocols/Skype/src/skype_dialogs.cpp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/protocols/Skype/src/skype_dialogs.cpp b/protocols/Skype/src/skype_dialogs.cpp index 1b7542f0bf..db11fcf337 100644 --- a/protocols/Skype/src/skype_dialogs.cpp +++ b/protocols/Skype/src/skype_dialogs.cpp @@ -420,12 +420,12 @@ INT_PTR CALLBACK CSkypeProto::SkypeDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam static INT_PTR CALLBACK PersonalSkypeDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam)
{
const unsigned long iPageId = 0;
- CSkypeProto* ppro = (CSkypeProto*)GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
+ CSkypeProto *ppro = (CSkypeProto *)GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
switch (msg) {
case WM_INITDIALOG:
if (lParam) {
- ppro = (CSkypeProto*)lParam;
+ ppro = (CSkypeProto *)lParam;
TranslateDialogDefault(hwndDlg);
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam);
@@ -453,12 +453,14 @@ static INT_PTR CALLBACK PersonalSkypeDlgProc(HWND hwndDlg, UINT msg, WPARAM wPar }
+ wchar_t *lang = ::db_get_wsa(NULL, ppro->m_szModuleName, "Language1");
for (std::map<std::wstring, std::wstring>::iterator it = CSkypeProto::languages.begin(); it != CSkypeProto::languages.end(); ++it)
{
const wchar_t* value = it->second.c_str();
- SendMessage(GetDlgItem(hwndDlg, IDC_LANGUAGE1), CB_ADDSTRING, 0, (LPARAM)value);
- SendMessage(GetDlgItem(hwndDlg, IDC_LANGUAGE2), CB_ADDSTRING, 0, (LPARAM)value);
- SendMessage(GetDlgItem(hwndDlg, IDC_LANGUAGE3), CB_ADDSTRING, 0, (LPARAM)value);
+ SendMessage(GetDlgItem(hwndDlg, IDC_LANGUAGE), CB_ADDSTRING, 0, (LPARAM)TranslateTS(value));
+ if ( !lang || !::wcslen(lang))
+ if ( !lstrcmp(lang, value))
+ SetDlgItemText(hwndDlg, IDC_LANGUAGE, TranslateTS(value));
}
DBVARIANT dbv;
if ( !db_get_ts(NULL, ppro->m_szModuleName, "Nick", &dbv)) {
|