-Fixed display_name
-Open links in external browser
This commit is contained in:
molan-git 2020-01-15 21:30:48 +00:00 committed by GitHub
parent db19fb254b
commit 3dc6145743
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -55,7 +55,7 @@ BackgroundItem {
anchors.fill: parent anchors.fill: parent
onClicked: { onClicked: {
pageStack.push(Qt.resolvedUrl("../Profile.qml"), { pageStack.push(Qt.resolvedUrl("../Profile.qml"), {
"displayname": model.account_username, "display_name": model.account_display_name,
"username": model.account_acct, "username": model.account_acct,
"user_id": model.account_id, "user_id": model.account_id,
"profileImage": model.account_avatar "profileImage": model.account_avatar
@ -140,7 +140,7 @@ BackgroundItem {
"profileImage": "" "profileImage": ""
}) })
} else { } else {
pageStack.push(Qt.resolvedUrl("../Browser.qml"), {"href" : link}) Qt.openUrlExternally(link);
} }
} }
text: content.replace(new RegExp("<a ", 'g'), '<a style="text-decoration: none; color:'+(pressed ? Theme.secondaryColor : Theme.highlightColor)+'" ') text: content.replace(new RegExp("<a ", 'g'), '<a style="text-decoration: none; color:'+(pressed ? Theme.secondaryColor : Theme.highlightColor)+'" ')