|
|
@ -15,7 +15,7 @@ ApplicationWindow { |
|
|
|
minimumHeight: 420 |
|
|
|
minimumHeight: 420 |
|
|
|
palette: colors |
|
|
|
palette: colors |
|
|
|
color: colors.window |
|
|
|
color: colors.window |
|
|
|
title: profile.globalUserProfile ? "Global User Profile" : "Room User Profile" |
|
|
|
title: profile.isGlobalUserProfile ? "Global User Profile" : "Room User Profile" |
|
|
|
|
|
|
|
|
|
|
|
ColumnLayout { |
|
|
|
ColumnLayout { |
|
|
|
id: contentL |
|
|
|
id: contentL |
|
|
@ -44,19 +44,19 @@ ApplicationWindow { |
|
|
|
Layout.alignment: Qt.AlignHCenter |
|
|
|
Layout.alignment: Qt.AlignHCenter |
|
|
|
selectByMouse: true |
|
|
|
selectByMouse: true |
|
|
|
|
|
|
|
|
|
|
|
Keys.priority: Keys.BeforeItem |
|
|
|
onAccepted: profile.changeUsername(displayUsername.text) |
|
|
|
Keys.onReturnPressed: profile.changeUsername(displayUsername.text) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ImageButton { |
|
|
|
ImageButton { |
|
|
|
|
|
|
|
visible: profile.isSelf |
|
|
|
anchors.leftMargin: 5 |
|
|
|
anchors.leftMargin: 5 |
|
|
|
anchors.left: displayUsername.right |
|
|
|
anchors.left: displayUsername.right |
|
|
|
anchors.verticalCenter: displayUsername.verticalCenter |
|
|
|
anchors.verticalCenter: displayUsername.verticalCenter |
|
|
|
image: profile.isUsernameEditingAllowed ? ":/icons/icons/ui/checkmark.png" : ":/icons/icons/ui/edit.png" |
|
|
|
image: profile.isUsernameEditingAllowed ? ":/icons/icons/ui/checkmark.png" : ":/icons/icons/ui/edit.png" |
|
|
|
|
|
|
|
|
|
|
|
onClicked: { |
|
|
|
onClicked: { |
|
|
|
if(profile.isUsernameEditingAllowed) { |
|
|
|
if (profile.isUsernameEditingAllowed) { |
|
|
|
profile.changeUsername(displayUsername.text) |
|
|
|
profile.changeUsername(displayUsername.text) |
|
|
|
}else{ |
|
|
|
} else { |
|
|
|
profile.allowUsernameEditing(true) |
|
|
|
profile.allowUsernameEditing(true) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|