Fix the reply an edit text being shown in all chat rooms when multiple windows are open

Fix the reply an edit text being shown in all chat rooms when multiple windows are open. This is done by changing chatBoxHelper from a singleton to being instantiated for each instance of roompage.

BUG: 454963
This commit is contained in:
James Graham
2022-08-26 19:33:20 +00:00
parent fdb424e65e
commit 6748a2d21d
8 changed files with 39 additions and 35 deletions

View File

@@ -127,8 +127,8 @@ Item {
ReplyPane {
id: replyPane
visible: ChatBoxHelper.isReplying || ChatBoxHelper.isEditing
user: ChatBoxHelper.replyUser
visible: chatBoxHelper.isReplying || chatBoxHelper.isEditing
user: chatBoxHelper.replyUser
width: parent.width
height: visible ? implicitHeight : 0
anchors.bottom: attachmentSeparator.top
@@ -154,7 +154,7 @@ Item {
AttachmentPane {
id: attachmentPane
visible: ChatBoxHelper.hasAttachment
visible: chatBoxHelper.hasAttachment
width: parent.width
height: visible ? implicitHeight : 0
anchors.bottom: chatBarSeparator.top
@@ -248,7 +248,7 @@ Item {
}
Connections {
target: ChatBoxHelper
target: chatBoxHelper
function onShouldClearText() {
root.inputFieldText = "";
@@ -277,7 +277,7 @@ Item {
}
function closeAll() {
ChatBoxHelper.clear();
chatBoxHelper.clear();
chatBar.emojiPaneOpened = false;
}
}