Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/desktop.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClaudio Cambra <claudio.cambra@gmail.com>2022-07-08 17:49:27 +0300
committerClaudio Cambra <claudio.cambra@gmail.com>2022-07-15 17:47:17 +0300
commit539ba93fd167c63269cc7fc7cb157cd4143e130b (patch)
tree574c2b14ddf8598257c1125f8d0c39f993cd04f1 /src/gui/tray/UserLine.qml
parent3271653412e90a0c750baa5b79add7bc2e4ee6ae (diff)
QMLify the UserModel, use properties rather than setter methods
Signed-off-by: Claudio Cambra <claudio.cambra@gmail.com>
Diffstat (limited to 'src/gui/tray/UserLine.qml')
-rw-r--r--src/gui/tray/UserLine.qml7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/gui/tray/UserLine.qml b/src/gui/tray/UserLine.qml
index 02deaccf1..e3d88888d 100644
--- a/src/gui/tray/UserLine.qml
+++ b/src/gui/tray/UserLine.qml
@@ -36,10 +36,9 @@ MenuItem {
Accessible.role: Accessible.Button
Accessible.name: qsTr("Switch to account") + " " + name
- onClicked: if (!isCurrentUser) {
- UserModel.switchCurrentUser(id)
- } else {
- accountMenu.close()
+ onClicked: {
+ UserModel.currentUserId = id;
+ accountMenu.close();
}
background: Item {