Best congratulations for the excellent 2.2! (i like to wokr with Lazarus a lot)
Nearly no problems at all ... except those remaining two (win x64):
No change here with 2.2, same as newly introduced with RC1 and RC2:
Virtual listview, MultiSelect: early reference to Selected object may cause performance problems
https://gitlab.com/freepascal.org/lazarus/lazarus/-/issues/39324The only thing i'd like to have is to be downward-compatible about basic objects and properties.
So that one can refer to "Selected" (or "SelCount") anywhere within the code.
Without time-consuming loops around all items - and without (and this is even more worse:) all items of the list are unintendedly instantiated at once bulk-wise!
ListView1.Items.Count := 20000;
// Probably somewhere later, but for demo in its elementary form here:
if ListView1.Selected = nil then -> boom! 20000 items will be instantiated at once, destroying virtualism
// Just saw that it is the same with "SelCount":
if ListView1.SelCount > 0 then -> boom! all 20000 items will be instantiated at once
"Ugly", because the instantiating "Selected" (or "SelCount") might be located anywhere.
For instance in some multi-called helper routines. Hard to find out what's going on here and old code breaks! Initially it did drive me crazy
until i found out what caused the drastic performance decrease in my app.
Remark: the windows folder "C:\Windows\WinSxS" does contain nearly 20000 items. that was causing my observation.
Question: how to decide under which circumstances one can refer to
"Selected" or "SelCount" without harm??
The problem did not exist with 2.0.12 and before, but with 2.2 RC1, 2.2 RC2 and 2.2.
Virtual listview, MultiSelect: problem: having only one item in the list: after click on empty space this single item keeps to stay selected
https://gitlab.com/freepascal.org/lazarus/lazarus/-/issues/39325After clicking on empty area, it should be possible to rely on the last item correctly being de-selected.
For instance for to achieve correct owner-drawing if one use that for specific paint of selected objects!
Imo, the evaluation should be done best without time-expensive loops along all 50000 items.
I'd highly wish to see, after four months, at least something like a status resp. label on these issues so that there is an indication that they don't will get forgotten.