From 9facfc2731a6e57e4d6a4d32914633b5689d7fb8 Mon Sep 17 00:00:00 2001 From: Steve Checkoway Date: Mon, 25 Sep 2006 02:14:41 +0000 Subject: [PATCH] Dialogs can be thrown before INPUTFILTER is constructed. --- stepmania/src/arch/Dialog/DialogDriver_Cocoa.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/stepmania/src/arch/Dialog/DialogDriver_Cocoa.cpp b/stepmania/src/arch/Dialog/DialogDriver_Cocoa.cpp index a352d239ed..3880001f2f 100644 --- a/stepmania/src/arch/Dialog/DialogDriver_Cocoa.cpp +++ b/stepmania/src/arch/Dialog/DialogDriver_Cocoa.cpp @@ -17,9 +17,12 @@ static CFOptionFlags ShowAlert( CFOptionFlags flags, const RString& sMessage, CF CFRelease( text ); // Flush all input that's accumulated while the dialog box was up. - vector dummy; - INPUTFILTER->Reset(); - INPUTFILTER->GetInputEvents( dummy ); + if( INPUTFILTER ) + { + vector dummy; + INPUTFILTER->Reset(); + INPUTFILTER->GetInputEvents( dummy ); + } return result; }