Disable wxHAS_MSW_TASKDIALOG because as of wxW svn r70933,

there is a bug with the wxPD_AUTO_HIDE style which can cause a non-dolphin
window to come to the foreground after auto-closing of the TaskDialog.
This commit is contained in:
Shawn Hoffman 2012-03-24 20:59:20 -07:00
parent e0941828f5
commit 7d57b925e6
4 changed files with 54 additions and 61 deletions

View file

@ -19,7 +19,10 @@
// by the task dialogs only. Also notice that task dialogs are available for // by the task dialogs only. Also notice that task dialogs are available for
// Unicode applications only. // Unicode applications only.
#if defined(TD_WARNING_ICON) && wxUSE_UNICODE #if defined(TD_WARNING_ICON) && wxUSE_UNICODE
#define wxHAS_MSW_TASKDIALOG // (shuffle2) This is turned off because as of wxW svn r70933,
// there is a bug with the wxPD_AUTO_HIDE style which can cause a non-dolphin
// window to come to the foreground after auto-closing of the TaskDialog.
// #define wxHAS_MSW_TASKDIALOG
#endif #endif
// Provides methods for creating a task dialog. // Provides methods for creating a task dialog.

View file

@ -1375,17 +1375,13 @@ void CFrame::OnInstallWAD(wxCommandEvent& event)
wxProgressDialog dialog(_("Installing WAD..."), wxProgressDialog dialog(_("Installing WAD..."),
_("Working..."), _("Working..."),
1000, // range 1000,
this, // parent this,
wxPD_APP_MODAL | wxPD_APP_MODAL |
wxPD_ELAPSED_TIME | wxPD_ELAPSED_TIME | wxPD_ESTIMATED_TIME | wxPD_REMAINING_TIME |
wxPD_ESTIMATED_TIME | wxPD_SMOOTH
wxPD_REMAINING_TIME |
wxPD_SMOOTH // - makes indeterminate mode bar on WinXP very small
); );
dialog.CenterOnParent();
u64 titleID = DiscIO::CNANDContentManager::Access().Install_WiiWAD(fileName); u64 titleID = DiscIO::CNANDContentManager::Access().Install_WiiWAD(fileName);
if (titleID == TITLEID_SYSMENU) if (titleID == TITLEID_SYSMENU)
{ {

View file

@ -557,17 +557,17 @@ void CGameListCtrl::ScanForISOs()
if (rFilenames.size() > 0) if (rFilenames.size() > 0)
{ {
wxProgressDialog dialog(_("Scanning for ISOs"), wxProgressDialog dialog(
_("Scanning..."), _("Scanning for ISOs"),
(int)rFilenames.size(), // range _("Scanning..."),
this, // parent (int)rFilenames.size() - 1,
wxPD_APP_MODAL | this,
wxPD_ELAPSED_TIME | wxPD_APP_MODAL |
wxPD_ESTIMATED_TIME | wxPD_AUTO_HIDE |
wxPD_REMAINING_TIME | wxPD_CAN_ABORT |
wxPD_SMOOTH // - makes indeterminate mode bar on WinXP very small wxPD_ELAPSED_TIME | wxPD_ESTIMATED_TIME | wxPD_REMAINING_TIME |
); wxPD_SMOOTH // - makes updates as small as possible (down to 1px)
dialog.CenterOnParent(); );
for (u32 i = 0; i < rFilenames.size(); i++) for (u32 i = 0; i < rFilenames.size(); i++)
{ {
@ -575,9 +575,9 @@ void CGameListCtrl::ScanForISOs()
SplitPath(rFilenames[i], NULL, &FileName, NULL); SplitPath(rFilenames[i], NULL, &FileName, NULL);
// Update with the progress (i) and the message // Update with the progress (i) and the message
bool Cont = dialog.Update(i, dialog.Update(i, wxString::Format(_("Scanning %s"),
wxString::Format(_("Scanning %s"), wxString(FileName.c_str(), *wxConvCurrent).c_str())); wxString(FileName.c_str(), *wxConvCurrent).c_str()));
if (!Cont) if (dialog.WasCancelled())
break; break;
std::auto_ptr<GameListItem> iso_file(new GameListItem(rFilenames[i])); std::auto_ptr<GameListItem> iso_file(new GameListItem(rFilenames[i]));
@ -1089,20 +1089,15 @@ void CGameListCtrl::CompressSelection(bool _compress)
if (browseDialog.ShowModal() != wxID_OK) if (browseDialog.ShowModal() != wxID_OK)
return; return;
wxProgressDialog progressDialog(_compress ? wxProgressDialog progressDialog(
_("Compressing ISO") : _("Decompressing ISO"), _compress ? _("Compressing ISO") : _("Decompressing ISO"),
_("Working..."), _("Working..."),
1000, // range 1000,
this, // parent this,
wxPD_APP_MODAL | wxPD_APP_MODAL |
wxPD_ELAPSED_TIME | wxPD_ELAPSED_TIME | wxPD_ESTIMATED_TIME | wxPD_REMAINING_TIME |
wxPD_ESTIMATED_TIME | wxPD_SMOOTH
wxPD_REMAINING_TIME | );
wxPD_SMOOTH // - makes indeterminate mode bar on WinXP very small
);
progressDialog.SetSize(wxSize(340, 180));
progressDialog.CenterOnParent();
m_currentItem = 0; m_currentItem = 0;
m_numberItem = GetSelectedItemCount(); m_numberItem = GetSelectedItemCount();
@ -1222,20 +1217,15 @@ void CGameListCtrl::OnCompressGCM(wxCommandEvent& WXUNUSED (event))
_("Confirm File Overwrite"), _("Confirm File Overwrite"),
wxYES_NO) == wxNO); wxYES_NO) == wxNO);
wxProgressDialog dialog(iso->IsCompressed() ? wxProgressDialog dialog(
_("Decompressing ISO") : _("Compressing ISO"), iso->IsCompressed() ? _("Decompressing ISO") : _("Compressing ISO"),
_("Working..."), _("Working..."),
1000, // range 1000,
this, // parent this,
wxPD_APP_MODAL | wxPD_APP_MODAL |
wxPD_ELAPSED_TIME | wxPD_ELAPSED_TIME | wxPD_ESTIMATED_TIME | wxPD_REMAINING_TIME |
wxPD_ESTIMATED_TIME | wxPD_SMOOTH
wxPD_REMAINING_TIME | );
wxPD_SMOOTH // - makes indeterminate mode bar on WinXP very small
);
dialog.SetSize(wxSize(340, 180));
dialog.CenterOnParent();
if (iso->IsCompressed()) if (iso->IsCompressed())
DiscIO::DecompressBlobToFile(iso->GetFileName().c_str(), DiscIO::DecompressBlobToFile(iso->GetFileName().c_str(),

View file

@ -718,22 +718,26 @@ void CISOProperties::ExportDir(const char* _rFullPath, const char* _rExportFolde
} }
wxString dialogTitle = index[0] ? _("Extracting Directory") : _("Extracting All Files"); wxString dialogTitle = index[0] ? _("Extracting Directory") : _("Extracting All Files");
wxProgressDialog dialog(dialogTitle, wxProgressDialog dialog(
_("Extracting..."), dialogTitle,
index[1], // range _("Extracting..."),
this, // parent index[1] - 1,
wxPD_APP_MODAL | wxPD_AUTO_HIDE | wxPD_CAN_ABORT | this,
wxPD_ELAPSED_TIME | wxPD_ESTIMATED_TIME | wxPD_REMAINING_TIME | wxPD_APP_MODAL | wxPD_AUTO_HIDE | wxPD_CAN_ABORT |
wxPD_SMOOTH // - makes indeterminate mode bar on WinXP very small wxPD_ELAPSED_TIME | wxPD_ESTIMATED_TIME | wxPD_REMAINING_TIME |
); wxPD_SMOOTH
dialog.CenterOnParent(); );
// Extraction // Extraction
for (u32 i = index[0]; i < index[1]; i++) for (u32 i = index[0]; i < index[1]; i++)
{ {
dialog.SetTitle(wxString::Format(wxT("%s : %d%%"), dialogTitle.c_str(), dialog.SetTitle(wxString::Format(wxT("%s : %d%%"), dialogTitle.c_str(),
(u32)(((float)(i - index[0]) / (float)(index[1] - index[0])) * 100))); (u32)(((float)(i - index[0]) / (float)(index[1] - index[0])) * 100)));
if (!dialog.Update(i, wxString::Format(_("Extracting %s"), wxString(fst[i]->m_FullPath, *wxConvCurrent).c_str())))
dialog.Update(i, wxString::Format(_("Extracting %s"),
wxString(fst[i]->m_FullPath, *wxConvCurrent).c_str()));
if (dialog.WasCancelled())
break; break;
if (fst[i]->IsDirectory()) if (fst[i]->IsDirectory())