mirror of
https://github.com/overte-org/overte.git
synced 2025-08-10 23:03:12 +02:00
Removed dead / commented code.
Better id name.
This commit is contained in:
parent
fb43abc636
commit
7c8ca85b5e
1 changed files with 4 additions and 7 deletions
|
@ -152,7 +152,7 @@ Rectangle {
|
||||||
contentWidth: parent.width
|
contentWidth: parent.width
|
||||||
contentHeight: listview.height
|
contentHeight: listview.height
|
||||||
clip: true
|
clip: true
|
||||||
id: testflickable
|
id: messageViewFlickable
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: listview
|
id: listview
|
||||||
|
@ -466,8 +466,6 @@ Rectangle {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
property var channels: {
|
property var channels: {
|
||||||
"local": local,
|
"local": local,
|
||||||
"domain": domain,
|
"domain": domain,
|
||||||
|
@ -475,7 +473,7 @@ Rectangle {
|
||||||
|
|
||||||
function scrollToBottom(bypassDistanceCheck = false, extraMoveDistance = 0) {
|
function scrollToBottom(bypassDistanceCheck = false, extraMoveDistance = 0) {
|
||||||
const totalHeight = listview.height; // Total height of the content
|
const totalHeight = listview.height; // Total height of the content
|
||||||
const currentPosition = testflickable.contentY; // Current position of the view
|
const currentPosition = messageViewFlickable.contentY; // Current position of the view
|
||||||
const windowHeight = listview.parent.parent.height; // Total height of the window
|
const windowHeight = listview.parent.parent.height; // Total height of the window
|
||||||
const bottomPosition = currentPosition + windowHeight;
|
const bottomPosition = currentPosition + windowHeight;
|
||||||
|
|
||||||
|
@ -485,9 +483,8 @@ Rectangle {
|
||||||
if (totalHeight < windowHeight) return; // No reason to scroll, we don't have an overflow.
|
if (totalHeight < windowHeight) return; // No reason to scroll, we don't have an overflow.
|
||||||
if (bottomPosition == totalHeight) return; // At the bottom, do nothing.
|
if (bottomPosition == totalHeight) return; // At the bottom, do nothing.
|
||||||
|
|
||||||
testflickable.contentY = listview.height - listview.parent.parent.height
|
messageViewFlickable.contentY = listview.height - listview.parent.parent.height;
|
||||||
// testflickable.flick(0, -1000)
|
messageViewFlickable.returnToBounds();
|
||||||
testflickable.returnToBounds();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue