X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/303742724331746439b1d2a8236d42f2930779f5..404b319a85dadd7decf7a5a5331020520031a41c:/src/msw/filedlg.cpp?ds=inline diff --git a/src/msw/filedlg.cpp b/src/msw/filedlg.cpp index 4fa0e56e75..27dfd888e5 100644 --- a/src/msw/filedlg.cpp +++ b/src/msw/filedlg.cpp @@ -47,6 +47,7 @@ #include "wx/filename.h" #include "wx/scopeguard.h" #include "wx/tokenzr.h" +#include "wx/testing.h" // ---------------------------------------------------------------------------- // constants @@ -449,6 +450,8 @@ void wxFileDialog::MSWOnInitDialogHook(WXHWND hwnd) int wxFileDialog::ShowModal() { + WX_TESTING_SHOW_MODAL_HOOK(); + HWND hWnd = 0; if (m_parent) hWnd = (HWND) m_parent->GetHWND(); if (!hWnd && wxTheApp->GetTopWindow()) @@ -507,7 +510,7 @@ int wxFileDialog::ShowModal() of.lStructSize = gs_ofStructSize; of.hwndOwner = hWnd; - of.lpstrTitle = m_message.wx_str(); + of.lpstrTitle = m_message.t_str(); of.lpstrFileTitle = titleBuffer; of.nMaxFileTitle = wxMAXFILE + 1 + wxMAXEXT; @@ -609,7 +612,7 @@ int wxFileDialog::ShowModal() } } - of.lpstrFilter = (LPTSTR)filterBuffer.wx_str(); + of.lpstrFilter = filterBuffer.t_str(); of.nFilterIndex = m_filterIndex + 1; //=== Setting defaultFileName >>========================================= @@ -626,7 +629,7 @@ int wxFileDialog::ShowModal() wxString defextBuffer; // we need it to be alive until GetSaveFileName()! if (HasFdFlag(wxFD_SAVE)) { - const wxChar* extension = filterBuffer.wx_str(); + const wxChar* extension = filterBuffer.t_str(); int maxFilter = (int)(of.nFilterIndex*2L) - 1; for( int i = 0; i < maxFilter; i++ ) // get extension @@ -708,7 +711,7 @@ int wxFileDialog::ShowModal() (of.nFileExtension && fileNameBuffer[of.nFileExtension] == wxT('\0')) ) { // User has typed a filename without an extension: - const wxChar* extension = filterBuffer.wx_str(); + const wxChar* extension = filterBuffer.t_str(); int maxFilter = (int)(of.nFilterIndex*2L) - 1; for( int i = 0; i < maxFilter; i++ ) // get extension