From 2ced428da5cbbc332afb0ad76503a06d381d228f Mon Sep 17 00:00:00 2001 From: martin Date: Sat, 5 Apr 2014 23:35:41 +0000 Subject: [PATCH] LazDebuggerFp (pure): start watches framework git-svn-id: trunk@44616 - --- .../lazdebuggerfp/fpdebugdebugger.pas | 29 +++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/components/lazdebuggers/lazdebuggerfp/fpdebugdebugger.pas b/components/lazdebuggers/lazdebuggerfp/fpdebugdebugger.pas index 8d6dd527b5..a42b6b64d8 100644 --- a/components/lazdebuggers/lazdebuggerfp/fpdebugdebugger.pas +++ b/components/lazdebuggers/lazdebuggerfp/fpdebugdebugger.pas @@ -41,6 +41,7 @@ type procedure FDbgControllerProcessExitEvent(AExitCode: DWord); procedure FDbgControllerExceptionEvent(var continue: boolean); protected + function CreateWatches: TWatchesSupplier; override; function RequestCommand(const ACommand: TDBGCommand; const AParams: array of const): Boolean; override; function ChangeFileName: Boolean; override; @@ -57,6 +58,17 @@ type function GetSupportedCommands: TDBGCommands; override; end; + { TFPWatches } + + TFPWatches = class(TWatchesSupplier) + private + protected + function FpDebugger: TFpDebugDebugger; + //procedure DoStateChange(const AOldState: TDBGState); override; + procedure InternalRequestData(AWatchValue: TWatchValue); override; + public + end; + procedure Register; implementation @@ -66,6 +78,18 @@ begin RegisterDebugger(TFpDebugDebugger); end; +{ TFPWatches } + +function TFPWatches.FpDebugger: TFpDebugDebugger; +begin + Result := TFpDebugDebugger(Debugger); +end; + +procedure TFPWatches.InternalRequestData(AWatchValue: TWatchValue); +begin + AWatchValue.Validity := ddsInvalid; +end; + { TFpDebugThread } procedure TFpDebugThread.DoDebugLoopFinishedASync(Data: PtrInt); @@ -109,6 +133,11 @@ begin end; end; +function TFpDebugDebugger.CreateWatches: TWatchesSupplier; +begin + Result := TFPWatches.Create(Self); +end; + procedure TFpDebugDebugger.FDbgControllerHitBreakpointEvent(var continue: boolean); begin BreakPoints[0].Hit(continue);