mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-01-28 09:19:19 +00:00
fix(mainWindow/conversation): display contact actions
This commit is contained in:
parent
a2efc6fa55
commit
b729dfa395
4 changed files with 40 additions and 13 deletions
|
|
@ -31,6 +31,7 @@
|
|||
<file>imgs/led_do_not_disturb.svg</file>
|
||||
<file>imgs/conference.svg</file>
|
||||
<file>imgs/cam.svg</file>
|
||||
<file>imgs/chat.svg</file>
|
||||
<file>imgs/chat_attachment.svg</file>
|
||||
<file>imgs/led_connected.svg</file>
|
||||
<file>imgs/led_absent.svg</file>
|
||||
|
|
|
|||
|
|
@ -10,7 +10,6 @@ Window {
|
|||
default property alias content: content.data // Required.
|
||||
property alias buttons: buttons.data // Required.
|
||||
property alias descriptionText: description.text // Optionnal.
|
||||
|
||||
property bool centeredButtons // Optionnal.
|
||||
|
||||
modality: Qt.WindowModal
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
import QtQuick 2.7
|
||||
|
||||
// ===================================================================
|
||||
// Bar which can contains ActionButton.
|
||||
// Bar which can contains ActionButtons.
|
||||
// ===================================================================
|
||||
|
||||
Row {
|
||||
|
|
|
|||
|
|
@ -26,15 +26,14 @@ ColumnLayout {
|
|||
|
||||
TextField {
|
||||
Layout.fillWidth: true
|
||||
Layout.preferredHeight: parent.height
|
||||
background: Rectangle {
|
||||
color: '#EAEAEA'
|
||||
implicitHeight: 30
|
||||
}
|
||||
placeholderText: qsTr('searchContactPlaceholder')
|
||||
}
|
||||
|
||||
ExclusiveButtons {
|
||||
Layout.preferredHeight: parent.height
|
||||
texts: [
|
||||
qsTr('selectAllContacts'),
|
||||
qsTr('selectConnectedContacts')
|
||||
|
|
@ -42,7 +41,6 @@ ColumnLayout {
|
|||
}
|
||||
|
||||
LightButton {
|
||||
Layout.preferredHeight: parent.height
|
||||
text: qsTr('addContact')
|
||||
}
|
||||
}
|
||||
|
|
@ -156,6 +154,13 @@ ColumnLayout {
|
|||
id: contact
|
||||
width: parent.width
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
hoverEnabled: true
|
||||
onEntered: contact.state = 'hover'
|
||||
onExited: contact.state = ''
|
||||
}
|
||||
|
||||
Item {
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
height: 30
|
||||
|
|
@ -199,24 +204,46 @@ ColumnLayout {
|
|||
font.weight: Font.DemiBold
|
||||
text: $username
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
hoverEnabled: true
|
||||
onEntered: contact.state = 'hover'
|
||||
onExited: contact.state = ''
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Actions.
|
||||
// TODO.
|
||||
Row {
|
||||
Layout.fillHeight: true
|
||||
id: actions
|
||||
spacing: 50
|
||||
visible: false
|
||||
|
||||
ActionBar {
|
||||
iconSize: parent.height
|
||||
|
||||
ActionButton {
|
||||
icon: 'cam'
|
||||
}
|
||||
|
||||
ActionButton {
|
||||
icon: 'call'
|
||||
}
|
||||
|
||||
ActionButton {
|
||||
icon: 'chat'
|
||||
}
|
||||
}
|
||||
|
||||
ActionButton {
|
||||
iconSize: parent.height
|
||||
icon: 'delete'
|
||||
onClicked: console.log('toto')
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
states: State {
|
||||
name: 'hover'
|
||||
PropertyChanges { target: contact; color: '#D1D1D1' }
|
||||
PropertyChanges { target: actions; visible: true }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue