OSDN Git Service

バグとり
authoryamat0jp <yamat0jp@yahoo.co.jp>
Sat, 25 Sep 2021 07:40:49 +0000 (16:40 +0900)
committeryamat0jp <yamat0jp@yahoo.co.jp>
Sat, 25 Sep 2021 07:40:49 +0000 (16:40 +0900)
Undo.pas
Unit1.pas
json_checker.dproj

index 7aff5b2..e84ab80 100644 (file)
--- a/Undo.pas
+++ b/Undo.pas
@@ -177,6 +177,7 @@ begin
   obj := TUnPaste.Create;
   obj.FPos := pos;
   obj.FLen := Length(str);
+  obj.FStr := str;
   obj.FMemo := FMemo;
   FStack.Push(obj);
 end;
index a8d9f36..7e10dcd 100644 (file)
--- a/Unit1.pas
+++ b/Unit1.pas
@@ -117,6 +117,7 @@ begin
   Memo1.SelStart := Memo1.SelStart - Length(s);
   Memo1.SelLength := Length(s);
   Undo.Pasted(Memo1.SelText, Memo1.SelStart);
+  ToolButton8.Enabled:=Undo.CanUndo;
 end;
 
 procedure TForm1.Action5Execute(Sender: TObject);
index 5ea5979..348f24e 100644 (file)
@@ -5,7 +5,7 @@
         <FrameworkType>VCL</FrameworkType>
         <MainSource>json_checker.dpr</MainSource>
         <Base>True</Base>
-        <Config Condition="'$(Config)'==''">Release</Config>
+        <Config Condition="'$(Config)'==''">Debug</Config>
         <Platform Condition="'$(Platform)'==''">Win64</Platform>
         <TargetedPlatforms>3</TargetedPlatforms>
         <AppType>Application</AppType>