Updating Display name reflects in Messages

Fixes: #416
This commit is contained in:
Sarah Jamie Lewis 2020-11-26 14:09:12 -08:00
parent ef58f002b3
commit 1d86c3d326
1 changed files with 7 additions and 0 deletions

View File

@ -60,7 +60,14 @@ Opaque.SettingsList { // settingsPane
onClicked: {
gcd.savePeerSettings(txtOnion.text, txtDisplayName.text)
toolbar.setTitle(txtDisplayName.text)
// FIXME this is kind of a hack as ideally we could just update the peer name
// and have that change broadcast to each message - but there isn't an easy way to do that
// with our current message model setup. As such we simply reset and reload the message pane
gcd.broadcast("ResetMessagePane")
theStack.pane = theStack.messagePane
mm.setHandle(txtOnion.text)
gcd.loadMessagesPane(txtOnion.text)
}
}
}