summaryrefslogtreecommitdiff
path: root/sw/source/core/unocore/unodraw.cxx
diff options
context:
space:
mode:
authorKurt Zenker <kz@openoffice.org>2010-01-15 15:13:13 +0100
committerKurt Zenker <kz@openoffice.org>2010-01-15 15:13:13 +0100
commitdeac05f7518a25ecde94454fbc21adef0de92682 (patch)
tree034e41aec963af62bc5f68655ff11b7d2c6993bb /sw/source/core/unocore/unodraw.cxx
parent8b0e9229226eb39868112df6d62f59a66fc65ccb (diff)
parent296fef7e82f0bf842428eaa97dff207399dc563e (diff)
CWS-TOOLING: integrate CWS fwk120
Diffstat (limited to 'sw/source/core/unocore/unodraw.cxx')
-rw-r--r--sw/source/core/unocore/unodraw.cxx24
1 files changed, 14 insertions, 10 deletions
diff --git a/sw/source/core/unocore/unodraw.cxx b/sw/source/core/unocore/unodraw.cxx
index 4f1b2c1770e3..3a22c81daaab 100644
--- a/sw/source/core/unocore/unodraw.cxx
+++ b/sw/source/core/unocore/unodraw.cxx
@@ -2737,12 +2737,14 @@ void SwXShape::_AdjustPositionProperties( const awt::Point _aPosition )
rtl::OUString aHoriOrientPropStr( RTL_CONSTASCII_USTRINGPARAM("HoriOrient") );
uno::Any aHoriOrient( getPropertyValue( aHoriOrientPropStr ) );
sal_Int16 eHoriOrient;
- aHoriOrient >>= eHoriOrient;
- if ( eHoriOrient != text::HoriOrientation::NONE )
+ if (aHoriOrient >>= eHoriOrient) // may be void
{
- eHoriOrient = text::HoriOrientation::NONE;
- aHoriOrient <<= eHoriOrient;
- setPropertyValue( aHoriOrientPropStr, aHoriOrient );
+ if ( eHoriOrient != text::HoriOrientation::NONE )
+ {
+ eHoriOrient = text::HoriOrientation::NONE;
+ aHoriOrient <<= eHoriOrient;
+ setPropertyValue( aHoriOrientPropStr, aHoriOrient );
+ }
}
// set x-position attribute
aHoriPos <<= _aPosition.X;
@@ -2765,12 +2767,14 @@ void SwXShape::_AdjustPositionProperties( const awt::Point _aPosition )
rtl::OUString aVertOrientPropStr( RTL_CONSTASCII_USTRINGPARAM("VertOrient") );
uno::Any aVertOrient( getPropertyValue( aVertOrientPropStr ) );
sal_Int16 eVertOrient;
- aVertOrient >>= eVertOrient;
- if ( eVertOrient != text::VertOrientation::NONE )
+ if (aVertOrient >>= eVertOrient) // may be void
{
- eVertOrient = text::VertOrientation::NONE;
- aVertOrient <<= eVertOrient;
- setPropertyValue( aVertOrientPropStr, aVertOrient );
+ if ( eVertOrient != text::VertOrientation::NONE )
+ {
+ eVertOrient = text::VertOrientation::NONE;
+ aVertOrient <<= eVertOrient;
+ setPropertyValue( aVertOrientPropStr, aVertOrient );
+ }
}
// set y-position attribute
aVertPos <<= _aPosition.Y;