Current Room Messages
Make sure that message delegates are getting the room object directly rather than requiring the assumption that currentRoom is declared somewhere higher up.
This commit is contained in:
@@ -38,9 +38,6 @@ QQC2.ScrollView {
|
||||
QQC2.ScrollBar.horizontal.policy: QQC2.ScrollBar.AlwaysOff
|
||||
|
||||
ListView {
|
||||
// So that delegates can access current room properly.
|
||||
readonly property NeoChatRoom currentRoom: root.currentRoom
|
||||
|
||||
clip: true
|
||||
verticalLayoutDirection: ListView.BottomToTop
|
||||
|
||||
@@ -55,7 +52,7 @@ QQC2.ScrollView {
|
||||
alwaysShowAuthor: true
|
||||
alwaysMaxWidth: true
|
||||
cardBackground: false
|
||||
connection: root.connection
|
||||
room: root.currentRoom
|
||||
}
|
||||
}
|
||||
|
||||
@@ -65,7 +62,7 @@ QQC2.ScrollView {
|
||||
alwaysShowAuthor: true
|
||||
alwaysMaxWidth: true
|
||||
cardBackground: false
|
||||
connection: root.connection
|
||||
room: root.currentRoom
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user