summaryrefslogtreecommitdiff
path: root/svtools/source
diff options
context:
space:
mode:
authorJens-Heiner Rechtien <hr@openoffice.org>2004-08-02 13:35:56 +0000
committerJens-Heiner Rechtien <hr@openoffice.org>2004-08-02 13:35:56 +0000
commitbcd4c5cdc3cab79febe4a75ab6dd71c50dec3488 (patch)
tree593e3ec5f7d4cdf035f50aa9db5f55a03e73a4de /svtools/source
parent65583459cd924823422e1946c73235f77575265d (diff)
INTEGRATION: CWS insight01 (1.4.290); FILE MERGED
2004/05/28 19:41:59 oj 1.4.290.3: RESYNC: (1.4-1.5); FILE MERGED 2004/04/27 10:28:12 oj 1.4.290.2: impl disabling of this control 2004/04/27 10:26:51 oj 1.4.290.1: impl disabling of this control
Diffstat (limited to 'svtools/source')
-rw-r--r--svtools/source/contnr/svlbitm.cxx26
1 files changed, 19 insertions, 7 deletions
diff --git a/svtools/source/contnr/svlbitm.cxx b/svtools/source/contnr/svlbitm.cxx
index af748268f39d..a1727eb5fe77 100644
--- a/svtools/source/contnr/svlbitm.cxx
+++ b/svtools/source/contnr/svlbitm.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: svlbitm.cxx,v $
*
- * $Revision: 1.6 $
+ * $Revision: 1.7 $
*
- * last change: $Author: hr $ $Date: 2004-07-23 11:56:13 $
+ * last change: $Author: hr $ $Date: 2004-08-02 14:35:56 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -266,10 +266,17 @@ USHORT SvLBoxString::IsA()
}
void SvLBoxString::Paint( const Point& rPos, SvLBox& rDev, USHORT /* nFlags */,
- SvLBoxEntry* )
+ SvLBoxEntry* _pEntry)
{
DBG_CHKTHIS(SvLBoxString,0);
- rDev.DrawText( rPos, aStr );
+ if ( _pEntry )
+ {
+ USHORT nStyle = rDev.IsEnabled() ? 0 : TEXT_DRAW_DISABLE;
+ rDev.DrawText( Rectangle(rPos,GetSize(&rDev,_pEntry)),aStr,nStyle);
+ }
+ else
+ rDev.DrawText( rPos, aStr);
+
}
SvLBoxItem* SvLBoxString::Create() const
@@ -347,7 +354,8 @@ void SvLBoxBmp::Paint( const Point& rPos, SvLBox& rDev, USHORT /* nFlags */,
SvLBoxEntry* )
{
DBG_CHKTHIS(SvLBoxBmp,0);
- rDev.DrawImage( rPos, aBmp );
+ USHORT nStyle = rDev.IsEnabled() ? 0 : IMAGE_DRAW_DISABLE;
+ rDev.DrawImage( rPos, aBmp ,nStyle);
}
SvLBoxItem* SvLBoxBmp::Create() const
@@ -425,7 +433,8 @@ void SvLBoxButton::Paint( const Point& rPos, SvLBox& rDev, USHORT /* nFlags */,
{
DBG_CHKTHIS(SvLBoxButton,0);
USHORT nIndex = pData->GetIndex( nItemFlags );
- rDev.DrawImage( rPos, pData->aBmps[nIndex + nBaseOffs] );
+ USHORT nStyle = rDev.IsEnabled() ? 0 : IMAGE_DRAW_DISABLE;
+ rDev.DrawImage( rPos, pData->aBmps[nIndex + nBaseOffs] ,nStyle);
}
SvLBoxItem* SvLBoxButton::Create() const
@@ -577,7 +586,10 @@ void SvLBoxContextBmp::Paint( const Point& _rPos, SvLBox& _rDev,
sal_Bool _bSemiTransparent = _pEntry && ( 0 != ( SV_ENTRYFLAG_SEMITRANSPARENT & _pEntry->GetFlags( ) ) );
// draw
- _rDev.DrawImage( _rPos, rImage, _bSemiTransparent ? IMAGE_DRAW_SEMITRANSPARENT : 0 );
+ USHORT nStyle = _rDev.IsEnabled() ? 0 : IMAGE_DRAW_DISABLE;
+ if ( _bSemiTransparent )
+ nStyle |= IMAGE_DRAW_SEMITRANSPARENT;
+ _rDev.DrawImage( _rPos, rImage, nStyle);
}
SvLBoxItem* SvLBoxContextBmp::Create() const