diff --git a/code/nel/tools/3d/plugin_max/nel_export/nel_export_node_properties.cpp b/code/nel/tools/3d/plugin_max/nel_export/nel_export_node_properties.cpp index 68436304c..949395d14 100644 --- a/code/nel/tools/3d/plugin_max/nel_export/nel_export_node_properties.cpp +++ b/code/nel/tools/3d/plugin_max/nel_export/nel_export_node_properties.cpp @@ -508,41 +508,41 @@ INT_PTR CALLBACK AccelDialogCallback ( { for (uint i=0; _MaterialNames[i] != 0; ++i) { - SendMessage (GetDlgItem (hwndDlg, IDC_OCC_MODEL), CB_ADDSTRING, 0, (LPARAM)(_MaterialNames[i])); - SendMessage (GetDlgItem (hwndDlg, IDC_OPEN_OCC_MODEL), CB_ADDSTRING, 0, (LPARAM)(_MaterialNames[i])); + SendMessage (GetDlgItem (hwndDlg, IDC_OCC_MODEL), CB_ADDSTRING, 0, (LPARAM)_MaterialNames[i]); + SendMessage (GetDlgItem (hwndDlg, IDC_OPEN_OCC_MODEL), CB_ADDSTRING, 0, (LPARAM)_MaterialNames[i]); } } { for (uint i =0; _EnvironmentNames[i] != 0; ++i) { - SendMessage (GetDlgItem (hwndDlg, IDC_ENV_FX), CB_ADDSTRING, 0, (LPARAM)(_EnvironmentNames[i])); + SendMessage (GetDlgItem (hwndDlg, IDC_ENV_FX), CB_ADDSTRING, 0, (LPARAM)_EnvironmentNames[i]); } } { std::set::iterator first(_KnownSoundGroups.begin()), last(_KnownSoundGroups.end()); for (; first != last; ++first) { - SendMessage (GetDlgItem (hwndDlg, IDC_SOUND_GROUP), CB_ADDSTRING, 0, (LPARAM)(first->c_str())); + SendMessage (GetDlgItem (hwndDlg, IDC_SOUND_GROUP), CB_ADDSTRING, 0, (LPARAM)utf8ToTStr(*first)); } } // set the combo and edit box - if (SendMessage (GetDlgItem (hwndDlg, IDC_OCC_MODEL), CB_SELECTSTRING, -1, (LPARAM)(currentParam->OcclusionModel.c_str())) == CB_ERR) + if (SendMessage (GetDlgItem (hwndDlg, IDC_OCC_MODEL), CB_SELECTSTRING, -1, (LPARAM)utf8ToTStr(currentParam->OcclusionModel)) == CB_ERR) { // nlassert(false); } - if (SendMessage (GetDlgItem (hwndDlg, IDC_OPEN_OCC_MODEL), CB_SELECTSTRING, -1, (LPARAM)(currentParam->OpenOcclusionModel.c_str())) == CB_ERR) + if (SendMessage (GetDlgItem (hwndDlg, IDC_OPEN_OCC_MODEL), CB_SELECTSTRING, -1, (LPARAM)utf8ToTStr(currentParam->OpenOcclusionModel)) == CB_ERR) { // nlassert(false); } - if (SendMessage (GetDlgItem (hwndDlg, IDC_ENV_FX), CB_SELECTSTRING, -1, (LPARAM)(currentParam->EnvironmentFX.c_str())) == CB_ERR) + if (SendMessage (GetDlgItem (hwndDlg, IDC_ENV_FX), CB_SELECTSTRING, -1, (LPARAM)utf8ToTStr(currentParam->EnvironmentFX)) == CB_ERR) { // nlassert(false); } - if (SendMessage (GetDlgItem (hwndDlg, IDC_SOUND_GROUP), CB_SELECTSTRING, -1, (LPARAM)(currentParam->SoundGroup.c_str())) == CB_ERR) + if (SendMessage (GetDlgItem (hwndDlg, IDC_SOUND_GROUP), CB_SELECTSTRING, -1, (LPARAM)utf8ToTStr(currentParam->SoundGroup)) == CB_ERR) { // nlassert(false); } -// SendMessage(GetDlgItem(hwndDlg, IDC_SOUND_GROUP), WM_SETTEXT, 0, (LONG)(currentParam->SoundGroup.c_str())); +// SendMessage(GetDlgItem(hwndDlg, IDC_SOUND_GROUP), WM_SETTEXT, 0, (LPARAM)utf8ToTStr(currentParam->SoundGroup)); bool accelerator = (currentParam->AcceleratorType != -1); CheckRadioButton (hwndDlg, IDC_RADIOACCELNO, IDC_RADIOACCELCLUSTER, accelerator?(IDC_RADIOACCELNO+(currentParam->AcceleratorType&NEL3D_APPDATA_ACCEL_TYPE)):0); @@ -1789,8 +1789,8 @@ INT_PTR CALLBACK VertexProgramDialogCallBack ( if(currentParam->VertexProgramId>=0) { // Init DropList. - SendDlgItemMessage(hwndDlg, IDC_COMBO_VP, CB_ADDSTRING, 0, (LPARAM)"Disable"); - SendDlgItemMessage(hwndDlg, IDC_COMBO_VP, CB_ADDSTRING, 0, (LPARAM)"Wind Tree"); + SendDlgItemMessage(hwndDlg, IDC_COMBO_VP, CB_ADDSTRING, 0, (LPARAM)_T("Disable")); + SendDlgItemMessage(hwndDlg, IDC_COMBO_VP, CB_ADDSTRING, 0, (LPARAM)_T("Wind Tree")); SendDlgItemMessage(hwndDlg, IDC_COMBO_VP, CB_SETCURSEL, currentParam->VertexProgramId, 0); EnableWindow( GetDlgItem(hwndDlg, IDC_COMBO_VP), TRUE); } diff --git a/code/nel/tools/3d/plugin_max/nel_vertex_tree_paint/vertex_tree_paint.cpp b/code/nel/tools/3d/plugin_max/nel_vertex_tree_paint/vertex_tree_paint.cpp index 3a513683a..664ec0868 100644 --- a/code/nel/tools/3d/plugin_max/nel_vertex_tree_paint/vertex_tree_paint.cpp +++ b/code/nel/tools/3d/plugin_max/nel_vertex_tree_paint/vertex_tree_paint.cpp @@ -119,9 +119,9 @@ static INT_PTR CALLBACK VertexPaintDlgProc(HWND hWnd, UINT msg, WPARAM wParam, L // Init comboBox - SendDlgItemMessage(hWnd, IDC_COMBO_TYPE, CB_ADDSTRING, 0, (LPARAM)"Tree Weight"); - SendDlgItemMessage(hWnd, IDC_COMBO_TYPE, CB_ADDSTRING, 0, (LPARAM)"Phase Level 1"); - SendDlgItemMessage(hWnd, IDC_COMBO_TYPE, CB_ADDSTRING, 0, (LPARAM)"Phase Level 2"); + SendDlgItemMessage(hWnd, IDC_COMBO_TYPE, CB_ADDSTRING, 0, (LPARAM)_T("Tree Weight")); + SendDlgItemMessage(hWnd, IDC_COMBO_TYPE, CB_ADDSTRING, 0, (LPARAM)_T("Phase Level 1")); + SendDlgItemMessage(hWnd, IDC_COMBO_TYPE, CB_ADDSTRING, 0, (LPARAM)_T("Phase Level 2")); SendDlgItemMessage(hWnd, IDC_COMBO_TYPE, CB_SETCURSEL, mod->getEditionType(), 0); // If paint mode at last edit. diff --git a/code/nel/tools/3d/plugin_max/tile_utility/tile_utility.cpp b/code/nel/tools/3d/plugin_max/tile_utility/tile_utility.cpp index c9d5ca7f0..893f44eea 100644 --- a/code/nel/tools/3d/plugin_max/tile_utility/tile_utility.cpp +++ b/code/nel/tools/3d/plugin_max/tile_utility/tile_utility.cpp @@ -337,7 +337,7 @@ void Tile_utility::SetupUI () std::string name=Bank.getLand(nLand)->getName(); if (hCombo) { - SendMessage (hCombo, CB_INSERTSTRING, -1, (LPARAM) name.c_str()); + SendMessage (hCombo, CB_INSERTSTRING, -1, (LPARAM)utf8ToTStr(name)); } }