summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorMathias Bauer <mbauer@apache.org>2011-09-18 20:15:37 +0000
committerMathias Bauer <mbauer@apache.org>2011-09-18 20:15:37 +0000
commitfc5f1e42716956a3de681e523a4c75a28d382759 (patch)
tree5ead21211a821f4be986f1e2f78e711ad1207851 /sfx2
parentbb3168e559ed381291e6c73d12b71fdc03dcc845 (diff)
cws mba34issues01: #i117708#: status indicator for inactive documents
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/doc/objserv.cxx10
1 files changed, 4 insertions, 6 deletions
diff --git a/sfx2/source/doc/objserv.cxx b/sfx2/source/doc/objserv.cxx
index 73d836938183..c0cc276a38c3 100644
--- a/sfx2/source/doc/objserv.cxx
+++ b/sfx2/source/doc/objserv.cxx
@@ -530,18 +530,16 @@ void SfxObjectShell::ExecFile_Impl(SfxRequest &rReq)
{
// get statusindicator
uno::Reference< task::XStatusIndicator > xStatusIndicator;
- SfxViewFrame *pFrame = GetFrame();
- if ( pFrame )
+ uno::Reference < frame::XController > xCtrl( GetModel()->getCurrentController() );
+ if ( xCtrl.is() )
{
- uno::Reference< task::XStatusIndicatorFactory > xStatFactory(
- pFrame->GetFrame().GetFrameInterface(),
- uno::UNO_QUERY );
+ uno::Reference< task::XStatusIndicatorFactory > xStatFactory( xCtrl->getFrame(), uno::UNO_QUERY );
if( xStatFactory.is() )
xStatusIndicator = xStatFactory->createStatusIndicator();
}
-
OSL_ENSURE( xStatusIndicator.is(), "Can not retrieve default status indicator!\n" );
+
if ( xStatusIndicator.is() )
{
SfxUnoAnyItem aStatIndItem( SID_PROGRESS_STATUSBAR_CONTROL, uno::makeAny( xStatusIndicator ) );