diff options
Diffstat (limited to 'CPP/7zip/UI/FileManager/ProgressDialog2.cpp')
-rwxr-xr-x | CPP/7zip/UI/FileManager/ProgressDialog2.cpp | 17 |
1 files changed, 5 insertions, 12 deletions
diff --git a/CPP/7zip/UI/FileManager/ProgressDialog2.cpp b/CPP/7zip/UI/FileManager/ProgressDialog2.cpp index 3d878a61..bd77d20d 100755 --- a/CPP/7zip/UI/FileManager/ProgressDialog2.cpp +++ b/CPP/7zip/UI/FileManager/ProgressDialog2.cpp @@ -146,6 +146,7 @@ bool CProgressDialog::OnInit() m_ProgressBar.Attach(GetItem(IDC_PROGRESS1)); _messageList.Attach(GetItem(IDC_PROGRESS_LIST)); + _messageList.SetUnicodeFormat(); _wasCreated = true; _dialogCreatedEvent.Set(); @@ -154,7 +155,6 @@ bool CProgressDialog::OnInit() LangSetDlgItemsText(HWND(*this), kIDLangPairs, sizeof(kIDLangPairs) / sizeof(kIDLangPairs[0])); #endif - CWindow window(GetItem(IDC_BUTTON_PROGRESS_PRIORITY)); window.GetText(backgroundString); backgroundedString = backgroundString; @@ -171,11 +171,6 @@ bool CProgressDialog::OnInit() SetPauseText(); SetPriorityText(); - - #ifndef UNDER_CE - _messageList.SetUnicodeFormat(true); - #endif - _messageList.InsertColumn(0, L"", 30); const UString s = LangStringSpec(IDS_MESSAGES_DIALOG_MESSAGE_COLUMN, 0x02000A80); @@ -957,10 +952,8 @@ UString HResultToMessage(HRESULT errorCode) UString message; if (errorCode == E_OUTOFMEMORY) message = LangStringSpec(IDS_MEM_ERROR, 0x0200060B); - else if (!NError::MyFormatMessage(errorCode, message)) - message.Empty(); - if (message.IsEmpty()) - message = L"Error"; + else + message = NError::MyFormatMessageW(errorCode); return message; } @@ -989,8 +982,8 @@ void CProgressThreadVirt::Process() m = HResultToMessage(Result); } AddMessageToString(m, ErrorMessage); - AddMessageToString(m, ErrorPath1); - AddMessageToString(m, ErrorPath2); + AddMessageToString(m, fs2us(ErrorPath1)); + AddMessageToString(m, fs2us(ErrorPath2)); if (m.IsEmpty()) { |