diff options
Diffstat (limited to 'desktop/source/app/lockfile2.cxx')
-rw-r--r-- | desktop/source/app/lockfile2.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/desktop/source/app/lockfile2.cxx b/desktop/source/app/lockfile2.cxx index c590ab7cf799..7636431048a6 100644 --- a/desktop/source/app/lockfile2.cxx +++ b/desktop/source/app/lockfile2.cxx @@ -38,22 +38,22 @@ bool Lockfile_execWarning( Lockfile * that ) OString aTime = aConfig.ReadKey( LOCKFILE_TIMEKEY ); // display warning and return response - MessageDialog aBox(NULL, DesktopResId(STR_QUERY_USERDATALOCKED), - VCL_MESSAGE_QUESTION, VCL_BUTTONS_YES_NO); + ScopedVclPtrInstance<MessageDialog> aBox(nullptr, DesktopResId(STR_QUERY_USERDATALOCKED), + VCL_MESSAGE_QUESTION, VCL_BUTTONS_YES_NO); // set box title OUString aTitle = OUString( DesktopResId( STR_TITLE_USERDATALOCKED )); - aBox.SetText( aTitle ); + aBox->SetText( aTitle ); // insert values... - OUString aMsgText = aBox.get_primary_text(); + OUString aMsgText = aBox->get_primary_text(); aMsgText = aMsgText.replaceFirst( "$u", OStringToOUString( aUser, RTL_TEXTENCODING_ASCII_US) ); aMsgText = aMsgText.replaceFirst( "$h", OStringToOUString( aHost, RTL_TEXTENCODING_ASCII_US) ); aMsgText = aMsgText.replaceFirst( "$t", OStringToOUString( aTime, RTL_TEXTENCODING_ASCII_US) ); - aBox.set_primary_text(aMsgText); + aBox->set_primary_text(aMsgText); // do it - return aBox.Execute( ) == RET_YES; + return aBox->Execute( ) == RET_YES; } } |