Show screenshots in search list#2272
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
jeremypw
left a comment
There was a problem hiding this comment.
The screenshot is often not the correct one. Also makes list visually jumpy.
|
@jeremypw can you elaborate on what you mean by "the correct one"? Are there certain apps you're reproducing a problem with? For the jumpiness, we could always preserve the height and have a image missing placeholder instead of showing nothing 🤔 |
|
@danirabbit I ran the search "term" and I noticed that many (50%?) of the screenshots did not correspond to any of the screenshots shown in the app details page and appeared to be of a different app entirely. For example the "Blackbox" app.
|
|
|
||
| var screenshots = package.get_screenshots (); | ||
| foreach (unowned var screenshot in screenshots) { | ||
| screenshot_url = screenshot.get_image (-1, SCREENSHOT_HEIGHT, scale_factor).get_url (); |
There was a problem hiding this comment.
Need null check for screenshot and `screenshot.get_image() else appcenter crashes for some searches.
|
@danirabbit I found this to crash on search now, due to missing null checks (see note). I am not sure if you are interested in pursuing this but I am not sure it adds much. Loading the screenshots is slow, moreover restarts for every change in search term. This could be amerliorated by only loading screenshots that will actually be visible in the same way Files does and having similar size placeholder images so the display does not jump about. But as the screenshots are easily accessible by clicking on those items that look interesting it hardly seems worth the effort. |

Uh oh!
There was an error while loading. Please reload this page.