Thrive
Thrive copied to clipboard
Reduced lag when opening art gallery as the image cards now load in o…
…ne every 0.1 seconds
Brief Description of What This PR Does
All the cards in the first tab have a timer that determines when they should start loading, which eliminates most of the lag.
Related Issues closes #3464
Progress Checklist
Note: before starting this checklist the PR should be marked as non-draft.
- [x] PR author has checked that this PR works as intended and doesn't break existing features: https://wiki.revolutionarygamesstudio.com/wiki/Testing_Checklist (this is important as to not waste the time of Thrive team members reviewing this PR)
- [ ] Initial code review passed (this and further items should not be checked by the PR author)
- [ ] Functionality is confirmed working by another person (see above checklist link)
- [ ] Final code review is passed and code conforms to the styleguide.
Before merging all CI jobs should finish on this PR without errors, if there are automatically detected style issues they should be fixed by the PR author. Merging must follow our styleguide.
Not sure why its failing this test, because I didn't have any style warnings when I committed. Also, the log says "Code cleanup performed changes, please stage / check them before committing", but I'm not sure where to find the changes.
The jetbrains check shows the diff of what changes it wants you to perform:
--- a/src/gui_common/art_gallery/GalleryCard.cs
+++ b/src/gui_common/art_gallery/GalleryCard.cs
@@ -16,7 +16,7 @@ public class GalleryCard : Button
private Label? titleLabel;
private TextureRect? imagePreview;
private Texture? thumbnail;
- private bool isLoaded = false;
+ private bool isLoaded;
private float time;
[Signal]