summaryrefslogtreecommitdiff
path: root/patches/vba/vba-interior-object-fix.diff
diff options
context:
space:
mode:
Diffstat (limited to 'patches/vba/vba-interior-object-fix.diff')
-rw-r--r--patches/vba/vba-interior-object-fix.diff52
1 files changed, 0 insertions, 52 deletions
diff --git a/patches/vba/vba-interior-object-fix.diff b/patches/vba/vba-interior-object-fix.diff
deleted file mode 100644
index 0318b9194..000000000
--- a/patches/vba/vba-interior-object-fix.diff
+++ /dev/null
@@ -1,52 +0,0 @@
-diff --git sc/source/ui/vba/vbainterior.cxx sc/source/ui/vba/vbainterior.cxx
-index 99f1bd7..e9f538a 100644
---- sc/source/ui/vba/vbainterior.cxx
-+++ sc/source/ui/vba/vbainterior.cxx
-@@ -162,11 +162,19 @@ ScVbaInterior::setColorIndex( const css::uno::Any& _colorindex ) throw (css::uno
- {
- sal_Int32 nIndex = 0;
- _colorindex >>= nIndex;
--
-- // setColor expects colors in XL RGB values
-- // #FIXME this is daft we convert OO RGB val to XL RGB val and
-- // then back again to OO RGB value
-- setColor( OORGBToXLRGB( GetIndexColor( nIndex ) ) );
-+
-+ // hackly for excel::XlColorIndex::xlColorIndexNone
-+ if( nIndex == excel::XlColorIndex::xlColorIndexNone )
-+ {
-+ m_xProps->setPropertyValue( BACKCOLOR, uno::makeAny( sal_Int32( -1 ) ) );
-+ }
-+ else
-+ {
-+ // setColor expects colors in XL RGB values
-+ // #FIXME this is daft we convert OO RGB val to XL RGB val and
-+ // then back again to OO RGB value
-+ setColor( OORGBToXLRGB( GetIndexColor( nIndex ) ) );
-+ }
- }
- uno::Any
- ScVbaInterior::GetIndexColor( const sal_Int32& nColorIndex )
-@@ -204,13 +212,21 @@ uno::Any SAL_CALL
- ScVbaInterior::getColorIndex() throw ( css::uno::RuntimeException )
- {
- sal_Int32 nColor = 0;
-+ // hackly for excel::XlColorIndex::xlColorIndexNone
-+ uno::Any aColor = m_xProps->getPropertyValue( BACKCOLOR );
-+ if( ( aColor >>= nColor ) && ( nColor == -1 ) )
-+ {
-+ nColor = excel::XlColorIndex::xlColorIndexNone;
-+ return uno::makeAny( nColor );
-+ }
-+
- // getColor returns Xl ColorValue, need to convert it to OO val
- // as the palette deals with OO RGB values
- // #FIXME this is daft in getColor we convert OO RGB val to XL RGB val
- // and then back again to OO RGB value
- XLRGBToOORGB( getColor() ) >>= nColor;
-
-- return uno::makeAny( GetIndexColor( nColor ) );
-+ return uno::makeAny( GetColorIndex( nColor ) );
- }
- Color
- ScVbaInterior::GetPatternColor( const Color& rPattColor, const Color& rBackColor, sal_uInt32 nXclPattern )