Bug 440437

Summary: Button to scroll left shows when no scroll-able area exists
Product: [Applications] Discover Reporter: kingofgamesyami
Component: discoverAssignee: Dan Leinir Turthra Jensen <leinir>
Status: RESOLVED FIXED    
Severity: normal CC: aleixpol, nate
Priority: NOR    
Version: 5.22.4   
Target Milestone: ---   
Platform: Neon   
OS: Linux   
Latest Commit: Version Fixed In: 5.23
Attachments: Screenshot of IntelliJ IDEA Community package in Discover

Description kingofgamesyami 2021-07-31 02:58:59 UTC
Created attachment 140419 [details]
Screenshot of IntelliJ IDEA Community package in Discover

SUMMARY
When viewing a package in Discover (in my example, IntelliJ IDEA Community Flatpak) that has few pictures, there is no scroll area for the pictures.

However, the button to scroll to the next position within the scroll area still exists. Clicking the button removes it and adds a button to scroll to the previous position, which functions similarly.

STEPS TO REPRODUCE
1. Open discover on a large display
2. Open the description for IntelliJ IDEA Community

OBSERVED RESULT
Button exists

EXPECTED RESULT
No button

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: KDE Neon 5.22
(available in About System)
KDE Plasma Version: 5.22.4
KDE Frameworks Version: 5.84.0
Qt Version: 5.15.3

ADDITIONAL INFORMATION
Comment 1 Nate Graham 2021-08-02 20:13:13 UTC
Can confirm.
Comment 2 Nate Graham 2021-08-02 20:29:16 UTC
Git commit 1c28a1ccc9cdcbbf77a1cab870e102503c4500d1 by Nate Graham.
Committed on 02/08/2021 at 20:28.
Pushed by ngraham into branch 'master'.

Only show screenshot arrow buttons when the view is visibly scrollable

This does not affect the popup, where we always want to show the arrow
buttons because only one screenshot is visible at a time.
FIXED-IN: 5.23

M  +2    -2    discover/qml/ApplicationScreenshots.qml

https://invent.kde.org/plasma/discover/commit/1c28a1ccc9cdcbbf77a1cab870e102503c4500d1