mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-05-03 22:56:49 +00:00
feat(ui/views/App/InviteFriends): open url externally
This commit is contained in:
parent
28cf495abc
commit
f80b563c95
3 changed files with 28 additions and 1 deletions
|
|
@ -433,6 +433,14 @@ Server url not configured.</translation>
|
|||
<source>inviteFriendsTitle</source>
|
||||
<translation>Linphone - Invite Friends</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>defaultMessage</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>defaultSubject</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>MainWindow</name>
|
||||
|
|
|
|||
|
|
@ -432,6 +432,14 @@ Url du serveur non configurée.</translation>
|
|||
<source>inviteFriendsTitle</source>
|
||||
<translation>Linphone - Inviter des amis</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>defaultMessage</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>defaultSubject</source>
|
||||
<translation type="unfinished"></translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>MainWindow</name>
|
||||
|
|
|
|||
|
|
@ -18,7 +18,15 @@ DialogPlus {
|
|||
enabled: email.length && message.length
|
||||
text: qsTr('confirm')
|
||||
|
||||
onClicked: exit(0)
|
||||
onClicked: {
|
||||
Qt.openUrlExternally(
|
||||
'mailto:' + encodeURIComponent(email.text) +
|
||||
'?subject=' + encodeURIComponent(qsTr('defaultSubject')) +
|
||||
'&body=' + encodeURIComponent(message.text)
|
||||
)
|
||||
|
||||
exit(0)
|
||||
}
|
||||
}
|
||||
]
|
||||
|
||||
|
|
@ -61,6 +69,7 @@ DialogPlus {
|
|||
TextField {
|
||||
id: email
|
||||
|
||||
inputMethodHints: Qt.ImhEmailCharactersOnly
|
||||
width: parent.width
|
||||
}
|
||||
}
|
||||
|
|
@ -87,6 +96,8 @@ DialogPlus {
|
|||
|
||||
Layout.fillHeight: true
|
||||
Layout.fillWidth: true
|
||||
|
||||
text: qsTr('defaultMessage')
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue