mirror of
https://github.com/electronicarts/CNC_TS_and_RA2_Mission_Editor.git
synced 2025-07-18 04:06:42 -04:00
L10n/chinese translation (#5)
* hotkey tips using \t . * simplified edit menu translation (ZH_CN) * refactored GetLanguageStringACP and implemented 'TranslateDlgItem' and 'TranslateWindowCaption' helper function . --------- Co-authored-by: shuiping233 <49360196+shuiping233@users.noreply.github.com>
This commit is contained in:
parent
1672fd8901
commit
f0d808a912
45 changed files with 1162 additions and 533 deletions
|
@ -25,6 +25,7 @@
|
|||
#include "finalsun.h"
|
||||
#include "SearchWaypointDlg.h"
|
||||
#include "variables.h"
|
||||
#include "functions.h"
|
||||
|
||||
#ifdef _DEBUG
|
||||
#define new DEBUG_NEW
|
||||
|
@ -66,6 +67,8 @@ BOOL CSearchWaypointDlg::OnInitDialog()
|
|||
{
|
||||
CDialog::OnInitDialog();
|
||||
|
||||
translateUI();
|
||||
|
||||
CListBox& ctrl = *(CListBox*)GetDlgItem(IDC_WAYPOINTS);
|
||||
|
||||
while (ctrl.DeleteString(0) != LB_ERR);
|
||||
|
@ -91,10 +94,20 @@ void CSearchWaypointDlg::OnOK()
|
|||
|
||||
int sel = ctrl.GetCurSel();
|
||||
|
||||
if (sel < 0) m_WaypointIndex = -1;
|
||||
else {
|
||||
if (sel < 0) {
|
||||
m_WaypointIndex = -1;
|
||||
} else {
|
||||
m_WaypointIndex = ctrl.GetItemData(sel);
|
||||
}
|
||||
|
||||
CDialog::OnOK();
|
||||
}
|
||||
|
||||
void CSearchWaypointDlg::translateUI()
|
||||
{
|
||||
TranslateWindowCaption(*this, "SearchWaypointDlgCaption");
|
||||
|
||||
TranslateDlgItem(*this, IDC_SEARCH_WP_WP, "SearchWaypointDlgWaypoints");
|
||||
TranslateDlgItem(*this, IDOK, "SearchWaypointDlgOk");
|
||||
TranslateDlgItem(*this, IDCANCEL, "SearchWaypointDlgCancel");
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue