Skip to content
Browse files

Fixed long lock after pausing the program for too long.

  • Loading branch information...
1 parent 8176e9f commit 86400fc4eeedd024e481031527d1fc1a41aa97f6 Kostas Michalopoulos committed Apr 21, 2012
Showing with 11 additions and 6 deletions.
  1. +9 −5 dcpustud.lpi
  2. +2 −1 mainunit.pas
View
14 dcpustud.lpi
@@ -94,10 +94,11 @@
<ComponentName Value="Main"/>
<ResourceBaseClass Value="Form"/>
<UnitName Value="MainUnit"/>
+ <IsVisibleTab Value="True"/>
<EditorIndex Value="0"/>
<WindowIndex Value="0"/>
- <TopLine Value="307"/>
- <CursorPos X="68" Y="311"/>
+ <TopLine Value="657"/>
+ <CursorPos X="65" Y="674"/>
<UsageCount Value="58"/>
<Loaded Value="True"/>
<LoadedDesigner Value="True"/>
@@ -106,11 +107,10 @@
<Filename Value="dcpu16.pas"/>
<IsPartOfProject Value="True"/>
<UnitName Value="DCPU16"/>
- <IsVisibleTab Value="True"/>
<EditorIndex Value="2"/>
<WindowIndex Value="0"/>
<TopLine Value="530"/>
- <CursorPos X="7" Y="556"/>
+ <CursorPos X="19" Y="533"/>
<UsageCount Value="58"/>
<Loaded Value="True"/>
</Unit2>
@@ -336,7 +336,7 @@
<UsageCount Value="10"/>
</Unit31>
</Units>
- <JumpHistory Count="29" HistoryIndex="28">
+ <JumpHistory Count="30" HistoryIndex="29">
<Position1>
<Filename Value="mainunit.pas"/>
<Caret Line="458" Column="3" TopLine="458"/>
@@ -453,6 +453,10 @@
<Filename Value="dcpu16.pas"/>
<Caret Line="199" Column="11" TopLine="173"/>
</Position29>
+ <Position30>
+ <Filename Value="mainunit.pas"/>
+ <Caret Line="322" Column="26" TopLine="307"/>
+ </Position30>
</JumpHistory>
</ProjectOptions>
<CompilerOptions>
View
3 mainunit.pas
@@ -671,6 +671,7 @@ procedure TMain.ApplicationProperties1Idle(Sender: TObject; var Done: Boolean);
for Reg:=crA to crO do
SpinEditByReg[Reg].Color:=clDefault;
try
+ if NowTicks - LastTicks > 5000 then LastTicks:=NowTicks;
while NowTicks - LastTicks > 10 do begin
CyclesToRun:=1000;
while CyclesToRun > 1 do begin
@@ -1070,4 +1071,4 @@ procedure TMain.KeyWasTyped(Ch: Char);
end;
end.
-
+

0 comments on commit 86400fc

Please sign in to comment.
Something went wrong with that request. Please try again.