2007-09-14 18:46 UTC+0100 Viktor Szakats (harbour.01 syenar.hu)

* harbour/source/rtl/tbrowse.prg
     ! Fixed cell color. This was needed because the oCol:colorBlock() 
       now always contains a block (it cannot be NIL) to be CA-Cl*pper 
       compatible, so the logic had to be adjusted in :DispCell() 
       accordingly.
This commit is contained in:
Viktor Szakats
2007-09-14 16:48:10 +00:00
parent 6da76ef2e1
commit 1596493ade
2 changed files with 14 additions and 1 deletions

View File

@@ -8,6 +8,13 @@
2002-12-01 13:30 UTC+0100 Foo Bar <foo.bar@foobar.org>
*/
2007-09-14 18:46 UTC+0100 Viktor Szakats (harbour.01 syenar.hu)
* harbour/source/rtl/tbrowse.prg
! Fixed cell color. This was needed because the oCol:colorBlock()
now always contains a block (it cannot be NIL) to be CA-Cl*pper
compatible, so the logic had to be adjusted in :DispCell()
accordingly.
2007-09-14 07:30 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbsxdef.ch
* harbour/contrib/pdflib/pdflib.h

View File

@@ -1458,6 +1458,7 @@ METHOD DispCell( nRow, nCol, nMode ) CLASS TBrowse
local ftmp := Eval( oCol:block )
local cType := ValType( ftmp )
local cPict := iif( Empty( oCol:Picture ), "", oCol:Picture )
local aDefColor
local tmp
@@ -1471,7 +1472,12 @@ METHOD DispCell( nRow, nCol, nMode ) CLASS TBrowse
! Empty( ::aRectColor )
cColor := tbr_GetColor( ::cColorSpec, ::aRectColor, nMode )
else
cColor := tbr_GetColor( ::cColorSpec, iif( oCol:ColorBlock == NIL, oCol:defColor, Eval( oCol:ColorBlock, ftmp ) ), nMode )
/* NOTE: Not very optimal that we're evaluating this block all the time.
But CA-Cl*pper always has a block here, and there is no other way
to tell if the code in it is NIL (the default) or something valuable.
[vszakats] */
aDefColor := Eval( oCol:colorBlock, ftmp )
cColor := tbr_GetColor( ::cColorSpec, iif( ISARRAY( aDefColor ), aDefColor, oCol:defColor ), nMode )
endif
do case