From 4a2c5737c045ad40fbabfcf78f9fea4ee9e02edc Mon Sep 17 00:00:00 2001 From: sudonim1 Date: Fri, 28 May 2010 15:55:32 +0000 Subject: [PATCH] Fix decision memory for a few dialogs including disc swapping and drag and drop loading. git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3099 96395faa-99c1-11dd-bbfe-3dabce05a288 --- pcsx2/gui/Dialogs/ConfirmationDialogs.cpp | 24 +++++++++++++++++++---- 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/pcsx2/gui/Dialogs/ConfirmationDialogs.cpp b/pcsx2/gui/Dialogs/ConfirmationDialogs.cpp index fd74db1b2b..e37e7e7385 100644 --- a/pcsx2/gui/Dialogs/ConfirmationDialogs.cpp +++ b/pcsx2/gui/Dialogs/ConfirmationDialogs.cpp @@ -39,11 +39,18 @@ bool MsgButtons::Allows( wxWindowID id ) const // [TODO] : maybe add in an Ignore All? case wxID_IGNORE: return HasIgnore(); + + case wxID_RESET: return HasReset(); + case wxID_CLOSE: return HasClose(); } + + if (id <= wxID_LOWEST) + return HasCustom(); + return false; } -static wxString ResultToString( int result ) +static wxString ResultToString( int result, const MsgButtons& buttons ) { switch( result ) { @@ -60,8 +67,14 @@ static wxString ResultToString( int result ) // [TODO] : maybe add in an Ignore All? case wxID_IGNORE: return L"ignore"; + + case wxID_RESET: return L"reset"; + case wxID_CLOSE: return L"close"; } + if (result <= wxID_LOWEST) + return buttons.GetCustomLabel(); + return wxEmptyString; } @@ -76,15 +89,18 @@ static wxWindowID ParseThatResult( const wxString& src, const MsgButtons& validT wxID_YESTOALL, wxID_NOTOALL, wxID_ABORT, wxID_RETRY, wxID_IGNORE, + + wxID_RESET, + wxID_ANY, }; for( int i=0; iIsChecked() && !cfgResult.IsEmpty() ) { cfg->SetPath( L"/PopupDisablers" );