diff options
author | Frank Schoenheit [fs] <frank.schoenheit@sun.com> | 2010-06-17 17:43:20 +0200 |
---|---|---|
committer | Frank Schoenheit [fs] <frank.schoenheit@sun.com> | 2010-06-17 17:43:20 +0200 |
commit | b7e22cc42678c00efe070f10320453bec8fc1ceb (patch) | |
tree | 1051a2eefa5f0dfd5a32f4255aa059fdbae3a5ae /toolkit | |
parent | 7f0993d43019a0ccb7f89c11fc23704c063b902f (diff) | |
parent | 34aaddf76fc80f377aff5fcf2c28d47b7842bc42 (diff) |
Automated merge with http://hg.services.openoffice.org/DEV300
Diffstat (limited to 'toolkit')
-rw-r--r-- | toolkit/source/awt/vclxwindows.cxx | 13 | ||||
-rw-r--r-- | toolkit/source/controls/unocontrol.cxx | 2 |
2 files changed, 7 insertions, 8 deletions
diff --git a/toolkit/source/awt/vclxwindows.cxx b/toolkit/source/awt/vclxwindows.cxx index 26e84905ee01..08e3ed286dd9 100644 --- a/toolkit/source/awt/vclxwindows.cxx +++ b/toolkit/source/awt/vclxwindows.cxx @@ -3010,16 +3010,15 @@ short VCLXFixedText::getAlignment() throw(::com::sun::star::uno::RuntimeExceptio return getMinimumSize(); } -::com::sun::star::awt::Size VCLXFixedText::calcAdjustedSize( const ::com::sun::star::awt::Size& rNewSize ) throw(::com::sun::star::uno::RuntimeException) +::com::sun::star::awt::Size VCLXFixedText::calcAdjustedSize( const ::com::sun::star::awt::Size& rMaxSize ) throw(::com::sun::star::uno::RuntimeException) { ::vos::OGuard aGuard( GetMutex() ); - ::com::sun::star::awt::Size aSz = rNewSize; - ::com::sun::star::awt::Size aMinSz = getMinimumSize(); - if ( aSz.Height != aMinSz.Height ) - aSz.Height = aMinSz.Height; - - return aSz; + Size aAdjustedSize( VCLUnoHelper::ConvertToVCLSize( rMaxSize ) ); + FixedText* pFixedText = (FixedText*)GetWindow(); + if ( pFixedText ) + aAdjustedSize = pFixedText->CalcMinimumSize( rMaxSize.Width ); + return VCLUnoHelper::ConvertToAWTSize( aAdjustedSize ); } // ---------------------------------------------------- diff --git a/toolkit/source/controls/unocontrol.cxx b/toolkit/source/controls/unocontrol.cxx index d91077823495..9254819f0b42 100644 --- a/toolkit/source/controls/unocontrol.cxx +++ b/toolkit/source/controls/unocontrol.cxx @@ -1463,7 +1463,7 @@ sal_Bool UnoControl::supportsService( const ::rtl::OUString& rServiceName ) thro Sequence< ::rtl::OUString > aSNL = getSupportedServiceNames(); const ::rtl::OUString* pArray = aSNL.getConstArray(); - const ::rtl::OUString* pArrayEnd = aSNL.getConstArray(); + const ::rtl::OUString* pArrayEnd = aSNL.getConstArray() + aSNL.getLength(); for (; pArray != pArrayEnd; ++pArray ) if( *pArray == rServiceName ) break; |