View Issue Details

IDProjectCategoryView StatusLast Update
0038266LazarusIDEpublic2021-03-08 08:28
ReporterMichl Assigned ToJuha Manninen  
PrioritynormalSeverityminorReproducibilityalways
Status assignedResolutionopen 
Product Version2.1 (SVN) 
Summary0038266: Closing of Code Browser doesn't stop background searching
DescriptionIf you close Code Browser while it is searching, the background searching process isn't stopped. The IDE react then very slow, till this process is finished.

Normally I use Cody for searching, but if I accidentally click on "Search identifier", it is annoying, that I can't work further as expected.

So it would be nice that the background searching process is stopped when the Code Browser window is closed.
Steps To ReproduceCreate a new Application.

Do in OnCreate:
procedure TForm1.FormCreate(Sender: TObject);
begin
  Foo;
end;

Compile project and right-click in Message window "Search identifier".
Close Code Browser

Try to write something in Source Editor and see the slowness
Additional InformationLazarus 2.1.0 r64287:64288 FPC 3.0.4 i386-win32-win32/win64
TagsNo tags attached.
Fixed in Revisionr64754
LazTarget-
Widgetset
Attached Files

Activities

Juha Manninen

2021-03-06 10:49

developer   ~0129423

Disconnecting the OnIdle handler in Form.OnClose seems to do it.
Does it cause problems in other situations? I didn't notice any. Please test.

Michl

2021-03-06 22:17

developer   ~0129453

No, here it is not solved. The behaviour is the same as before. The search thread isn't stopped. I can hear my HDD and fan are in high usage and the editor reacts only slow. Tested with revision 64760.

Juha Manninen

2021-03-08 08:28

developer   ~0129503

Actually it is not a thread. It is all done in OnIdle handler in many phases.
I guess the effect of closing depends on what phase is running.
I will study it later more...

Issue History

Date Modified Username Field Change
2020-12-27 22:49 Michl New Issue
2021-03-06 10:46 Juha Manninen Assigned To => Juha Manninen
2021-03-06 10:46 Juha Manninen Status new => assigned
2021-03-06 10:49 Juha Manninen Status assigned => resolved
2021-03-06 10:49 Juha Manninen Resolution open => fixed
2021-03-06 10:49 Juha Manninen Fixed in Revision => r64754
2021-03-06 10:49 Juha Manninen LazTarget => -
2021-03-06 10:49 Juha Manninen Note Added: 0129423
2021-03-06 22:17 Michl Status resolved => assigned
2021-03-06 22:17 Michl Resolution fixed => open
2021-03-06 22:17 Michl Note Added: 0129453
2021-03-08 08:28 Juha Manninen Note Added: 0129503