Skip to content
Snippets Groups Projects
Commit dee49508 authored by Nicolas Werner's avatar Nicolas Werner
Browse files

Simplify scroll logic

parent 8c44c5e2
No related branches found
No related tags found
No related merge requests found
......@@ -58,10 +58,6 @@ Item {
onWheel: {
if (wheel.angleDelta != 0) {
chat.contentY = chat.contentY - wheel.angleDelta.y
if (wheel.angleDelta.y > 0 && chat.contentY > chat.contentHeight - chat.height)
chat.contentY = chat.contentHeight - chat.height
else if (wheel.angleDelta < 0 && chat.contentY < 0)
chat.contentY = 0
wheel.accepted = true
chat.forceLayout()
chat.updatePosition()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment