Fixed bug on browsing vars
This commit is contained in:
@@ -492,10 +492,10 @@ METHOD Colors() CLASS TDebugger
|
||||
endif
|
||||
oBrwColors:Cargo :={ 1,{}} // Actual highligthed row
|
||||
oBrwColors:ColorSpec := ::ClrModal()
|
||||
oBrwColors:GOTOPBLOCK := { || oBrwColors:cargo[ 1 ]:= 1 }
|
||||
oBrwColors:GoBottomBlock := { || oBrwColors:cargo[ 1 ]:= Len(oBrwColors:cargo[ 2 ][ 1 ])}
|
||||
oBrwColors:GOTOPBLOCK := { || oBrwColors:cargo[ 1 ]:= 1 }
|
||||
oBrwColors:GoBottomBlock := { || oBrwColors:cargo[ 1 ]:= Len(oBrwColors:cargo[ 2 ][ 1 ])}
|
||||
oBrwColors:SKIPBLOCK := { |nPos| ( nPos:= ArrayBrowseSkip(nPos, oBrwColors), oBrwColors:cargo[ 1 ]:= ;
|
||||
oBrwColors:cargo[ 1 ] + nPos,nPos ) }
|
||||
oBrwColors:cargo[ 1 ] + nPos,nPos ) }
|
||||
|
||||
oBrwColors:AddColumn( ocol := TBColumnNew( "", { || PadR( aColors[ oBrwColors:Cargo[1] ], 14 ) } ) )
|
||||
oCol:DefColor:={1,2}
|
||||
@@ -505,7 +505,7 @@ METHOD Colors() CLASS TDebugger
|
||||
aadd(oBrwColors:Cargo[2],acolors)
|
||||
oCol:DefColor:={1,3}
|
||||
ocol:width:=50
|
||||
oBrwColors:autolite:=.f.
|
||||
oBrwColors:autolite:=.f.
|
||||
|
||||
oWndColors:bPainted := { || oBrwColors:ForceStable(),RefreshVarsS(oBrwColors)}
|
||||
|
||||
@@ -1004,7 +1004,7 @@ METHOD ShowCallStack() CLASS TDebugger
|
||||
|
||||
::oBrwStack:AddColumn( oCol:=TBColumnNew( "", { || PadC( ::aCallStack[ n ][ 1 ], 14 ) } ) )
|
||||
ocol:ColorBlock := { || { iif( n == ::oBrwStack:Cargo, 2, 1 ), 3 } }
|
||||
ocol:Defcolor := { 2,1 }
|
||||
ocol:Defcolor := { 2,1 }
|
||||
|
||||
::oWndStack:bPainted := { || ::oBrwStack:ColorSpec := __DbgColors()[ 2 ] + "," + ;
|
||||
__DbgColors()[ 5 ] + "," + __DbgColors()[ 4 ],;
|
||||
@@ -1128,10 +1128,14 @@ METHOD ShowVars() CLASS TDebugger
|
||||
::oWndStack:nWidth(), 0 ) - 1 )
|
||||
::oBrwVars:Cargo :={ 1,{}} // Actual highligthed row
|
||||
::oBrwVars:ColorSpec := ::aColors[ 2 ] + "," + ::aColors[ 5 ] + "," + ::aColors[ 3 ]
|
||||
::oBrwVars:GOTOPBLOCK := { || ::oBrwVars:cargo[ 1 ]:= 1 }
|
||||
::oBrwVars:GoBottomBlock := { || ::oBrwVars:cargo[ 1 ]:= Len(::oBrwVars:cargo[ 2 ][ 1 ])}
|
||||
::oBrwVars:SKIPBLOCK := { |nPos| ( nPos:= ArrayBrowseSkip(nPos, ::oBrwVars), ::oBrwVars:cargo[ 1 ]:= ;
|
||||
::oBrwVars:cargo[ 1 ] + nPos,nPos ) }
|
||||
::oBrwVars:GOTOPBLOCK := { || ::oBrwVars:cargo[ 1 ]:= 1 }
|
||||
::oBrwVars:GoBottomBlock := { || ::oBrwVars:cargo[ 1 ]:= Len(::oBrwVars:cargo[ 2 ][ 1 ])}
|
||||
::oBrwVars:SkipBlock = { | nSkip, nOld | nOld := ::oBrwVars:Cargo[ 1 ],;
|
||||
::oBrwVars:Cargo[ 1 ] += nSkip,;
|
||||
::oBrwVars:Cargo[ 1 ] := Min( Max( ::oBrwVars:Cargo[ 1 ], 1 ),;
|
||||
Len( ::aVars ) ),;
|
||||
::oBrwVars:Cargo[ 1 ] - nOld }
|
||||
|
||||
|
||||
::oWndVars:bKeyPressed := { | nKey | ( iif( nKey == K_DOWN ;
|
||||
, ::oBrwVars:Down(), nil ), iif( nKey == K_UP, ::oBrwVars:Up(), nil ) ;
|
||||
@@ -1537,10 +1541,10 @@ METHOD ViewSets() CLASS TDebugger
|
||||
oBrwSets:Cargo :={ 1,{}} // Actual highligthed row
|
||||
oBrwSets:autolite:=.f.
|
||||
oBrwSets:ColorSpec := ::ClrModal()
|
||||
oBrwSets:GOTOPBLOCK := { || oBrwSets:cargo[ 1 ]:= 1 }
|
||||
oBrwSets:GoBottomBlock := { || oBrwSets:cargo[ 1 ]:= Len(oBrwSets:cargo[ 2 ][ 1 ])}
|
||||
oBrwSets:GOTOPBLOCK := { || oBrwSets:cargo[ 1 ]:= 1 }
|
||||
oBrwSets:GoBottomBlock := { || oBrwSets:cargo[ 1 ]:= Len(oBrwSets:cargo[ 2 ][ 1 ])}
|
||||
oBrwSets:SKIPBLOCK := { |nPos| ( nPos:= ArrayBrowseSkip(nPos, oBrwSets), oBrwSets:cargo[ 1 ]:= ;
|
||||
oBrwSets:cargo[ 1 ] + nPos,nPos ) }
|
||||
oBrwSets:cargo[ 1 ] + nPos,nPos ) }
|
||||
oBrwSets:AddColumn( ocol := TBColumnNew( "", { || PadR( aSets[ oBrwSets:cargo[ 1 ] ], 12 ) } ) )
|
||||
aadd(oBrwSets:Cargo[2],asets)
|
||||
ocol:defcolor:={1,2}
|
||||
@@ -1613,7 +1617,7 @@ static procedure SetsKeyPressed( nKey, oBrwSets, nSets, oWnd, cCaption, bEdit )
|
||||
|
||||
oWnd:SetCaption( cCaption + "[" + AllTrim( Str( oBrwSets:Cargo[1] ) ) + ;
|
||||
".." + AllTrim( Str( nSets ) ) + "]" )
|
||||
|
||||
|
||||
return
|
||||
static procedure SetsKeyVarPressed( nKey, oBrwSets, nSets, oWnd, bEdit )
|
||||
Local nRectoMove
|
||||
@@ -1782,10 +1786,10 @@ static procedure RefreshVarsS( oBrowse )
|
||||
if ( nLen == 2 )
|
||||
oBrowse:hilite():colpos:=1
|
||||
endif
|
||||
oBrowse:hilite()
|
||||
oBrowse:hilite()
|
||||
return
|
||||
static function ArrayBrowseSkip( nPos, oBrwSets,n )
|
||||
|
||||
return iif( oBrwSets:cargo[ 1 ] + nPos < 1, 0 - oBrwSets:cargo[ 1 ] + 1 , ;
|
||||
iif( oBrwSets:cargo[ 1 ] + nPos > Len(oBrwSets:cargo[ 2 ][ 1 ]), ;
|
||||
Len(oBrwSets:cargo[ 2 ][ 1 ]) - oBrwSets:cargo[ 1 ], nPos ) )
|
||||
Len(oBrwSets:cargo[ 2 ][ 1 ]) - oBrwSets:cargo[ 1 ], nPos ) )
|
||||
Reference in New Issue
Block a user