Closed sghpjuikit closed 5 years ago
'stuck' scrolling & similar layout pass issues
Exact cause is unknown, but I have already fixed most of them. I have also made layout reqests much more lazy (no more calling layout()
as well as improved grid cell reuse, so during layout the cells are aware that they 'moved' (e.g. when scrolling) and will not change content.
performance
I have:
while(...) sleep(...)
for ContDownLatch
to synchronize cell loadingFut
in an atomic reference.some cell covers are not displayed, non-deterministic
After long and exhausting effort to identify the cause of certain cells not displaying their cover, I have finally figured out the exact problem - interplay between updateItem()
, which is no-op if item did not change and loadCover()
, which checks item validity (on bgr thread) before image is loaded, can in up/down scrolling lead to image loaded but not displayed.
composed cover not displaying the covers properly
Error in the sub-cover position calculation.
navigation hover effect is bizarre
Sscaling must be absolute, not relative.
ConcurrentModificationErrors due to cell's children being accessed on multiple threads (necessary), which clashes with disposal and other mechanisms. finally fixed this problem by materializing (defensive copy) the collections on access.
Locations source editing not working
Locations source list contaminated by null in certain cases
Caused by improper nullability handling in ListConfigField. I have improved this support, which led to also using Type instead of Class in certain scenarios in order to be able to detect the generic type of the collection. There are more places where such improvement is desirable actually.
2-pass image loading for heavy content (psd files)
This is a tricky one. This worked before, although it interfered with 'low quality' image loading performance. There are multiple issues in regards to design, as of now this feature is broken, and I removed it. It does make a difference though, so it will come back. Right now psd thumbnails have lower quality (still sufficient imo). The upside is removal of a lot of state checks, large threadpools and lq/hq image loading performance interference due to running in parallel.
legacy code
Majority of the related code is in Java and this makes it really hard to tackle this. In fact this is the most difficult code in the entire code base. I plan on fixing all the 'big' issues first and then porting certain classes to Kotlin.
All these changes make working with the GridView much nicer and the performance improved dramatically.
Done, mostly in: 3d20511 e448390
I can still reproduce a weird initial layout issue, but I'll tackle that separately in the future. It's annoying but harmless.
There are multiple issues in this component in regards to cell updating and cover displaying. This issue is an umbrella for design and ux issues plaguing GridView/DirView in practice.
Things this issue is not targeting