diff options
author | Michael Meeks <michael.meeks@collabora.com> | 2015-03-16 13:25:26 +0000 |
---|---|---|
committer | Michael Meeks <michael.meeks@collabora.com> | 2015-04-10 11:04:36 +0100 |
commit | 122577ba7888edded1456e8c8210b1945e037cd0 (patch) | |
tree | e48a37be3f0b9ce2502e57aaa2f4a3183958acf0 /framework | |
parent | 3b416a7f845e7fda384951c1ac37ac9d47fe9354 (diff) |
framework: fix for toolkit updates.
Change-Id: I1629cb6574361d6dd855140d61f38229ab593ed7
Diffstat (limited to 'framework')
-rw-r--r-- | framework/source/layoutmanager/toolbarlayoutmanager.cxx | 14 | ||||
-rw-r--r-- | framework/source/uielement/popuptoolbarcontroller.cxx | 6 |
2 files changed, 10 insertions, 10 deletions
diff --git a/framework/source/layoutmanager/toolbarlayoutmanager.cxx b/framework/source/layoutmanager/toolbarlayoutmanager.cxx index f40b98d068f2..1b1b9fc41948 100644 --- a/framework/source/layoutmanager/toolbarlayoutmanager.cxx +++ b/framework/source/layoutmanager/toolbarlayoutmanager.cxx @@ -1031,14 +1031,14 @@ void ToolbarLayoutManager::setParentWindow( if ( xParentWindow.is() ) { SolarMutexGuard aGuard; - ::DockingAreaWindow* pWindow = dynamic_cast< ::DockingAreaWindow* >(VCLUnoHelper::GetWindow( xTopDockWindow ) ); + VclPtr< ::DockingAreaWindow > pWindow = dynamic_cast< ::DockingAreaWindow* >(VCLUnoHelper::GetWindow( xTopDockWindow ).get() ); if( pWindow ) pWindow->SetAlign( WINDOWALIGN_TOP ); - pWindow = dynamic_cast< ::DockingAreaWindow* >(VCLUnoHelper::GetWindow( xBottomDockWindow ) ); - if( pWindow ) pWindow->SetAlign( WINDOWALIGN_BOTTOM ); - pWindow = dynamic_cast< ::DockingAreaWindow* >(VCLUnoHelper::GetWindow( xLeftDockWindow ) ); - if( pWindow ) pWindow->SetAlign( WINDOWALIGN_LEFT ); - pWindow = dynamic_cast< ::DockingAreaWindow* >(VCLUnoHelper::GetWindow( xRightDockWindow ) ); - if( pWindow ) pWindow->SetAlign( WINDOWALIGN_RIGHT ); + pWindow = dynamic_cast< ::DockingAreaWindow* >(VCLUnoHelper::GetWindow( xBottomDockWindow ).get() ); + if( pWindow ) pWindow->SetAlign( WINDOWALIGN_BOTTOM ); + pWindow = dynamic_cast< ::DockingAreaWindow* >(VCLUnoHelper::GetWindow( xLeftDockWindow ).get() ); + if( pWindow ) pWindow->SetAlign( WINDOWALIGN_LEFT ); + pWindow = dynamic_cast< ::DockingAreaWindow* >(VCLUnoHelper::GetWindow( xRightDockWindow ).get() ); + if( pWindow ) pWindow->SetAlign( WINDOWALIGN_RIGHT ); implts_reparentToolbars(); } else diff --git a/framework/source/uielement/popuptoolbarcontroller.cxx b/framework/source/uielement/popuptoolbarcontroller.cxx index 259601ea8855..c2e324717825 100644 --- a/framework/source/uielement/popuptoolbarcontroller.cxx +++ b/framework/source/uielement/popuptoolbarcontroller.cxx @@ -146,7 +146,7 @@ throw ( css::uno::Exception, css::uno::RuntimeException, std::exception ) } SolarMutexGuard aSolarLock; - ToolBox* pToolBox = static_cast< ToolBox* >( VCLUnoHelper::GetWindow( getParent() ) ); + VclPtr< ToolBox > pToolBox = static_cast< ToolBox* >( VCLUnoHelper::GetWindow( getParent() ).get() ); if ( pToolBox ) { ToolBoxItemBits nCurStyle( pToolBox->GetItemBits( m_nToolBoxId ) ); @@ -181,7 +181,7 @@ PopupMenuToolbarController::createPopupWindow() createPopupMenuController(); SolarMutexGuard aSolarLock; - ToolBox* pToolBox = static_cast< ToolBox* >( VCLUnoHelper::GetWindow( getParent() ) ); + VclPtr< ToolBox > pToolBox = static_cast< ToolBox* >( VCLUnoHelper::GetWindow( getParent() ).get() ); if ( !pToolBox ) return xRet; @@ -540,7 +540,7 @@ static bool Impl_ExistURLInMenu( void NewToolbarController::setItemImage( const OUString &rCommand ) { SolarMutexGuard aSolarLock; - ToolBox* pToolBox = static_cast< ToolBox* >( VCLUnoHelper::GetWindow( getParent() ) ); + VclPtr< ToolBox> pToolBox = static_cast< ToolBox* >( VCLUnoHelper::GetWindow( getParent() ).get() ); if ( !pToolBox ) return; |