mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-04-28 14:43:09 +00:00
autoscroll only at the very edges
This commit is contained in:
parent
ba9babb186
commit
d54a63ba04
2 changed files with 4 additions and 4 deletions
|
|
@ -78,10 +78,10 @@ ContainmentLayoutManager.ItemContainer {
|
||||||
|
|
||||||
var pos = plasmoid.fullRepresentationItem.mapFromItem(delegate, dragCenter.x, dragCenter.y);
|
var pos = plasmoid.fullRepresentationItem.mapFromItem(delegate, dragCenter.x, dragCenter.y);
|
||||||
//SCROLL UP
|
//SCROLL UP
|
||||||
if (pos.y < plasmoid.fullRepresentationItem.height / 4) {
|
if (pos.y < plasmoid.availableScreenRect.y + units.gridUnit) {
|
||||||
plasmoid.fullRepresentationItem.scrollUp();
|
plasmoid.fullRepresentationItem.scrollUp();
|
||||||
//SCROLL DOWN
|
//SCROLL DOWN
|
||||||
} else if (pos.y > 3 * (plasmoid.fullRepresentationItem.height / 4)) {
|
} else if (pos.y > plasmoid.availableScreenRect.y + plasmoid.availableScreenRect.height - units.gridUnit) {
|
||||||
plasmoid.fullRepresentationItem.scrollDown();
|
plasmoid.fullRepresentationItem.scrollDown();
|
||||||
//DON't SCROLL
|
//DON't SCROLL
|
||||||
} else {
|
} else {
|
||||||
|
|
|
||||||
|
|
@ -321,8 +321,8 @@ Item {
|
||||||
ScrollIndicator {
|
ScrollIndicator {
|
||||||
id: scrollDownIndicator
|
id: scrollDownIndicator
|
||||||
anchors {
|
anchors {
|
||||||
bottom: parent.bottom
|
bottom: favoriteStrip.top
|
||||||
bottomMargin: units.gridUnit * 2
|
bottomMargin: units.gridUnit
|
||||||
}
|
}
|
||||||
elementId: "down-arrow"
|
elementId: "down-arrow"
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue