mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-01-31 02:49:21 +00:00
feat(app): do not display camera icons when video is not available
This commit is contained in:
parent
36d55d2fb8
commit
eca7a39732
10 changed files with 70 additions and 64 deletions
|
|
@ -1,15 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<svg width="40px" height="40px" viewBox="0 0 40 40" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
<!-- Generator: Sketch 40.3 (33839) - http://www.bohemiancoding.com/sketch -->
|
||||
<title>video_call_default</title>
|
||||
<desc>Created with Sketch.</desc>
|
||||
<defs></defs>
|
||||
<g id="Symbols" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
||||
<g id="video_call_default">
|
||||
<path d="M20,40 C31.045695,40 40,31.045695 40,20 C40,8.954305 31.045695,0 20,0 C8.954305,0 0,8.954305 0,20 C0,31.045695 8.954305,40 20,40 Z" fill="#D0D8DE"></path>
|
||||
<g id="videocall_icon" transform="translate(9.000000, 13.000000)" stroke-linecap="round" stroke-width="1.5" stroke="#FFFFFF" stroke-linejoin="round">
|
||||
<polygon points="21.9033897 6.53341215 21.9033897 0.673601511 16.1289093 5.25958769 16.1289093 0.333333333 0.333333333 0.333333333 0.333333333 12.9483398 16.1289093 12.9483398 16.1289093 8.02208543 21.9033897 12.6080716"></polygon>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
Before Width: | Height: | Size: 1.1 KiB |
|
|
@ -1,15 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<svg width="40px" height="40px" viewBox="0 0 40 40" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
<!-- Generator: Sketch 40.3 (33839) - http://www.bohemiancoding.com/sketch -->
|
||||
<title>video_call_default</title>
|
||||
<desc>Created with Sketch.</desc>
|
||||
<defs></defs>
|
||||
<g id="Symbols" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
||||
<g id="video_call_default">
|
||||
<path d="M20,40 C31.045695,40 40,31.045695 40,20 C40,8.954305 31.045695,0 20,0 C8.954305,0 0,8.954305 0,20 C0,31.045695 8.954305,40 20,40 Z" fill="#D0D8DE"></path>
|
||||
<g id="videocall_icon" transform="translate(9.000000, 13.000000)" stroke-linecap="round" stroke-width="1.5" stroke="#FFFFFF" stroke-linejoin="round">
|
||||
<polygon points="21.9033897 6.53341215 21.9033897 0.673601511 16.1289093 5.25958769 16.1289093 0.333333333 0.333333333 0.333333333 0.333333333 12.9483398 16.1289093 12.9483398 16.1289093 8.02208543 21.9033897 12.6080716"></polygon>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
Before Width: | Height: | Size: 1.1 KiB |
|
|
@ -193,11 +193,9 @@
|
|||
<file>assets/images/transfer_normal.svg</file>
|
||||
<file>assets/images/transfer_pressed.svg</file>
|
||||
<file>assets/images/update_sign.svg</file>
|
||||
<file>assets/images/video_call_accept_disabled.svg</file>
|
||||
<file>assets/images/video_call_accept_hovered.svg</file>
|
||||
<file>assets/images/video_call_accept_normal.svg</file>
|
||||
<file>assets/images/video_call_accept_pressed.svg</file>
|
||||
<file>assets/images/video_call_disabled.svg</file>
|
||||
<file>assets/images/video_call_hovered.svg</file>
|
||||
<file>assets/images/video_call_normal.svg</file>
|
||||
<file>assets/images/video_call_pressed.svg</file>
|
||||
|
|
|
|||
|
|
@ -49,13 +49,19 @@ Notification {
|
|||
Layout.fillWidth: true
|
||||
|
||||
ActionBar {
|
||||
id: acceptActionBar
|
||||
|
||||
anchors.centerIn: parent
|
||||
iconSize: NotificationReceivedCallStyle.actionArea.iconSize
|
||||
|
||||
ActionButton {
|
||||
enabled: SettingsModel.videoSupported
|
||||
icon: 'video_call_accept'
|
||||
onClicked: notification._close(notification.call.acceptWithVideo)
|
||||
Loader {
|
||||
active: SettingsModel.videoSupported
|
||||
sourceComponent: ActionButton {
|
||||
icon: 'video_call_accept'
|
||||
iconSize: acceptActionBar.iconSize
|
||||
|
||||
onClicked: notification._close(notification.call.acceptWithVideo)
|
||||
}
|
||||
}
|
||||
|
||||
ActionButton {
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ SearchBox {
|
|||
id: view
|
||||
|
||||
actions: [{
|
||||
enabled: SettingsModel.videoSupported,
|
||||
active: SettingsModel.videoSupported,
|
||||
icon: 'video_call',
|
||||
handler: function (entry) {
|
||||
searchBox.closeMenu()
|
||||
|
|
|
|||
|
|
@ -91,20 +91,26 @@ ScrollableListView {
|
|||
}
|
||||
|
||||
ActionBar {
|
||||
id: defaultContactActionBar
|
||||
|
||||
iconSize: SipAddressesViewStyle.entry.iconSize
|
||||
|
||||
Repeater {
|
||||
model: sipAddressesView.actions
|
||||
|
||||
ActionButton {
|
||||
enabled: {
|
||||
var status = sipAddressesView.actions[index].enabled
|
||||
return status === undefined || status
|
||||
Loader {
|
||||
active: {
|
||||
var active = sipAddressesView.actions[index].active
|
||||
return active === undefined || active
|
||||
}
|
||||
sourceComponent: ActionButton {
|
||||
icon: modelData.icon
|
||||
iconSize: defaultContactActionBar.iconSize
|
||||
|
||||
onClicked: sipAddressesView.actions[index].handler({
|
||||
sipAddress: sipAddressesView.interpretableSipAddress
|
||||
})
|
||||
}
|
||||
icon: modelData.icon
|
||||
onClicked: sipAddressesView.actions[index].handler({
|
||||
sipAddress: sipAddressesView.interpretableSipAddress
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -227,18 +233,24 @@ ScrollableListView {
|
|||
// ---------------------------------------------------------------------
|
||||
|
||||
ActionBar {
|
||||
id: actionBar
|
||||
|
||||
iconSize: SipAddressesViewStyle.entry.iconSize
|
||||
|
||||
Repeater {
|
||||
model: sipAddressesView.actions
|
||||
|
||||
ActionButton {
|
||||
enabled: {
|
||||
var status = sipAddressesView.actions[index].enabled
|
||||
return status === undefined || status
|
||||
Loader {
|
||||
active: {
|
||||
var active = sipAddressesView.actions[index].active
|
||||
return active === undefined || active
|
||||
}
|
||||
sourceComponent: ActionButton {
|
||||
icon: modelData.icon
|
||||
iconSize: actionBar.iconSize
|
||||
|
||||
onClicked: sipAddressesView.actions[index].handler($sipAddress)
|
||||
}
|
||||
icon: modelData.icon
|
||||
onClicked: sipAddressesView.actions[index].handler($sipAddress)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -59,7 +59,7 @@ DialogPlus {
|
|||
anchors.fill: parent
|
||||
|
||||
actions: [{
|
||||
enabled: SettingsModel.videoSupported,
|
||||
active: SettingsModel.videoSupported,
|
||||
icon: 'video_call',
|
||||
handler: function (entry) {
|
||||
CallsListModel.launchVideoCall(entry.sipAddress)
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
import QtQuick 2.7
|
||||
|
||||
import Common 1.0
|
||||
import Linphone 1.0
|
||||
|
||||
|
|
@ -7,13 +9,19 @@ import App.Styles 1.0
|
|||
|
||||
AbstractStartingCall {
|
||||
ActionBar {
|
||||
id: actionBar
|
||||
|
||||
anchors.centerIn: parent
|
||||
iconSize: CallStyle.actionArea.iconSize
|
||||
|
||||
ActionButton {
|
||||
enabled: SettingsModel.videoSupported
|
||||
icon: 'video_call_accept'
|
||||
onClicked: call.acceptWithVideo()
|
||||
Loader {
|
||||
active: SettingsModel.videoSupported
|
||||
sourceComponent: ActionButton {
|
||||
icon: 'video_call_accept'
|
||||
iconSize: actionBar.iconSize
|
||||
|
||||
onClicked: call.acceptWithVideo()
|
||||
}
|
||||
}
|
||||
|
||||
ActionButton {
|
||||
|
|
|
|||
|
|
@ -124,16 +124,22 @@ ColumnLayout {
|
|||
|
||||
Item {
|
||||
ActionBar {
|
||||
id: actionBar
|
||||
|
||||
anchors {
|
||||
left: parent.left
|
||||
verticalCenter: parent.verticalCenter
|
||||
}
|
||||
iconSize: ContactsStyle.contact.actionButtonsSize
|
||||
|
||||
ActionButton {
|
||||
enabled: SettingsModel.videoSupported
|
||||
icon: 'video_call'
|
||||
onClicked: actions.itemAt(0).open()
|
||||
Loader {
|
||||
active: SettingsModel.videoSupported
|
||||
sourceComponent: ActionButton {
|
||||
icon: 'video_call'
|
||||
iconSize: actionBar.iconSize
|
||||
|
||||
onClicked: actions.itemAt(0).open()
|
||||
}
|
||||
}
|
||||
|
||||
ActionButton {
|
||||
|
|
|
|||
|
|
@ -70,13 +70,19 @@ ColumnLayout {
|
|||
spacing: ConversationStyle.bar.actions.spacing
|
||||
|
||||
ActionBar {
|
||||
id: actionBar
|
||||
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
iconSize: ConversationStyle.bar.actions.call.iconSize
|
||||
|
||||
ActionButton {
|
||||
enabled: SettingsModel.videoSupported
|
||||
icon: 'video_call'
|
||||
onClicked: CallsListModel.launchVideoCall(conversation.sipAddress)
|
||||
Loader {
|
||||
active: SettingsModel.videoSupported
|
||||
sourceComponent: ActionButton {
|
||||
icon: 'video_call'
|
||||
iconSize: actionBar.iconSize
|
||||
|
||||
onClicked: CallsListModel.launchVideoCall(conversation.sipAddress)
|
||||
}
|
||||
}
|
||||
|
||||
ActionButton {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue