Excuse me,
in these days I'm under pressure.
I've forgot to tell you that I tested your samples
It's a valid solution except for a little visual effect
There is a little flickering in your sample and in this (rewritten by me) there are
other problems that I am not able to resolve.
This is the only one working solution at the moment.
In my opinion to load into an array only visible cells would be a first step to improve browsing classes
include "fivewin.ch"
xtranslate DelObj <o> => If <o> != nil; DeleteObject( <o> ); endif; <o> := nil
REQUEST HB_GT_GUI_DEFAULT
ANNOUNCE RDDSYS
FUNCTION MAIN()
LOCAL oDlg
LOCAL oBrw
LOCAL aRec := {}
LOCAL nIni
LOCAL nRig
LOCAL nFin
LOCAL nCur := 1
SET DELETED ON
SET EXCLUSIVE OFF
USE customer
SET INDEX TO customer
nRig := 20
nIni := 1
nFin := 1
DEFINE DIALOG oDlg RESOURCE "DIALOGO"
oBrw := TXBR3():Redefine( 101, , oDlg )
ACTIVATE DIALOG oDlg
RETURN NIL
CLASS TXBR3 FROM TWBROWSE
CLASSDATA lRegistered AS LOGICAL // used internally
DATA hSaveScr
METHOD Paint()
METHOD Destroy()
ENDCLASS
METHOD Paint() CLASS TXBR3
local aInfo
if ::hSaveScr != nil .and. GetFocus() != ::hWnd
aInfo := ::DispBegin()
DrawBitmap( ::hDC, ::hSaveScr, 0, 0 )
::DispEnd( aInfo )
else
Super:Paint()
DelObj ::hSaveScr
::hSaveScr := WndBitMap( ::hWnd )
endif
return nil
METHOD Destroy() CLASS TXBR3
DelObj ::hSaveScr
return Super:Destroy()
INIT PROCEDURE RddInit
REQUEST DBFFPT
REQUEST DBFCDX
rddSetDefault( "DBFCDX" )