applets/kicker: keep currentindex when scrolling list

ItemListDelegate may show tooltips. When you scroll the list, this may
interfere with the list view's hovered check and unset the currentitem.

Instead, also check whether the delegate containsMouse, which is still
true when scrolling. This makes both wheel and touchpad scrolling work
properly, and selects the item the pointer lands on.
This commit is contained in:
Christoph Wolk 2026-10-29 13:31:14 +01:00
parent ebfd56d594
commit ed750e4cef

View file

@ -95,7 +95,7 @@ PlasmaComponents3.ScrollView {
Qt.callLater( () =>{
if (ActionMenu.opened) {
return
} else if (hovered || (listView.currentItem as ItemListDelegate).dragActive) {
} else if (hovered || (listView.currentItem as ItemListDelegate).dragActive || (listView.currentItem as ItemListDelegate).containsMouse) {
resetIndexTimer.stop();
} else {
resetIndexTimer.start();