diff options
Diffstat (limited to 'chart2/source/controller/main/ChartController_Window.cxx')
-rw-r--r-- | chart2/source/controller/main/ChartController_Window.cxx | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/chart2/source/controller/main/ChartController_Window.cxx b/chart2/source/controller/main/ChartController_Window.cxx index ef3c5678c795..ce6db7db7bef 100644 --- a/chart2/source/controller/main/ChartController_Window.cxx +++ b/chart2/source/controller/main/ChartController_Window.cxx @@ -7,7 +7,7 @@ * OpenOffice.org - a multi-platform office productivity suite * * $RCSfile: ChartController_Window.cxx,v $ - * $Revision: 1.32 $ + * $Revision: 1.31.24.2 $ * * This file is part of OpenOffice.org. * @@ -1328,16 +1328,14 @@ bool ChartController::impl_moveOrResizeObject( if( bNeedResize ) eActionType = ActionDescriptionProvider::RESIZE; - UndoGuard aUndoGuard( - ActionDescriptionProvider::createDescription( - eActionType, - ObjectNameProvider::getName( ObjectIdentifier::getObjectType( rCID ))), - m_xUndoManager, xChartModel ); + ObjectType eObjectType = ObjectIdentifier::getObjectType( rCID ); + UndoGuard aUndoGuard( ActionDescriptionProvider::createDescription( + eActionType, ObjectNameProvider::getName( eObjectType )), m_xUndoManager, xChartModel ); { ControllerLockGuard aCLGuard( xChartModel ); if( bNeedShift ) xObjProp->setPropertyValue( C2U("RelativePosition"), uno::makeAny( aRelPos )); - if( bNeedResize ) + if( bNeedResize || (eObjectType == OBJECTTYPE_DIAGRAM) )//Also set an explicat size at the diagram when an explicit position is set xObjProp->setPropertyValue( C2U("RelativeSize"), uno::makeAny( aRelSize )); } aUndoGuard.commitAction(); |