disable user functions when user is me

This commit is contained in:
Morgan McMillian 2016-10-21 08:50:17 -07:00
parent 97cb8d41a5
commit 305457091e
3 changed files with 8 additions and 5 deletions

View file

@ -158,6 +158,7 @@ Page {
}
}
imageSource: (user.you_follow) ? "asset:///icons/minus-circle.png" : "asset:///icons/ic_add.png"
enabled: (_app.setting("username") === user.username) ? false : true
},
ActionItem {
title: (user.you_muted) ? qsTr("Unmute") : qsTr("Mute")
@ -170,6 +171,7 @@ Page {
}
}
imageSource: (user.you_muted) ? "asset:///icons/bell.png" : "asset:///icons/bell-slash.png"
enabled: (_app.setting("username") === user.username) ? false : true
},
ActionItem {
title: (user.you_blocked) ? qsTr("Unblock") : qsTr("Block")
@ -182,6 +184,7 @@ Page {
}
}
imageSource: "asset:///icons/ic_cancel.png"
enabled: (_app.setting("username") === user.username) ? false : true
}
]
}

View file

@ -1 +1 @@
126
128

View file

@ -98,22 +98,22 @@
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../assets/ProfilePage.qml" line="163"/>
<location filename="../assets/ProfilePage.qml" line="164"/>
<source>Unmute</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../assets/ProfilePage.qml" line="163"/>
<location filename="../assets/ProfilePage.qml" line="164"/>
<source>Mute</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../assets/ProfilePage.qml" line="175"/>
<location filename="../assets/ProfilePage.qml" line="177"/>
<source>Unblock</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../assets/ProfilePage.qml" line="175"/>
<location filename="../assets/ProfilePage.qml" line="177"/>
<source>Block</source>
<translation type="unfinished"></translation>
</message>