mirror of
https://git.jami.net/savoirfairelinux/jami-client-qt.git
synced 2025-09-10 12:03:18 +02:00
accessibility: fix the messagebar
Add proper labels to the messagebar and remove the existing keyboard trap in the showmore menu. Change-Id: Ib70ca29979dc3909585383d612d1062259df83a8
This commit is contained in:
parent
cb13d4f771
commit
c738caa3a4
4 changed files with 35 additions and 2 deletions
|
@ -22,6 +22,7 @@ import "contextmenu"
|
|||
|
||||
BaseContextMenu {
|
||||
id: root
|
||||
|
||||
property var modelList
|
||||
signal audioRecordMessageButtonClicked
|
||||
signal videoRecordMessageButtonClicked
|
||||
|
@ -31,35 +32,63 @@ BaseContextMenu {
|
|||
GeneralMenuItem {
|
||||
id: audioMessage
|
||||
|
||||
Accessible.role: Accessible.MenuItem
|
||||
Accessible.name: itemName
|
||||
focusPolicy: Qt.StrongFocus
|
||||
Keys.onReturnPressed: clicked()
|
||||
|
||||
canTrigger: true
|
||||
iconSource: JamiResources.message_audio_black_24dp_svg
|
||||
itemName: JamiStrings.leaveAudioMessage
|
||||
onClicked: {
|
||||
root.audioRecordMessageButtonClicked();
|
||||
root.close()
|
||||
}
|
||||
|
||||
KeyNavigation.tab: videoMessage
|
||||
KeyNavigation.backtab: shareLocation
|
||||
},
|
||||
GeneralMenuItem {
|
||||
id: videoMessage
|
||||
|
||||
Accessible.role: Accessible.MenuItem
|
||||
Accessible.name: itemName
|
||||
|
||||
focusPolicy: Qt.StrongFocus
|
||||
Keys.onReturnPressed: clicked()
|
||||
|
||||
canTrigger: true
|
||||
iconSource: JamiResources.message_video_black_24dp_svg
|
||||
itemName: JamiStrings.leaveVideoMessage
|
||||
|
||||
isActif: VideoDevices.listSize !== 0
|
||||
|
||||
onClicked: {
|
||||
root.videoRecordMessageButtonClicked();
|
||||
root.close()
|
||||
}
|
||||
|
||||
KeyNavigation.tab: shareLocation
|
||||
KeyNavigation.backtab: audioMessage
|
||||
},
|
||||
GeneralMenuItem {
|
||||
id: shareLocation
|
||||
|
||||
Accessible.role: Accessible.MenuItem
|
||||
Accessible.name: itemName
|
||||
|
||||
focusPolicy: Qt.StrongFocus
|
||||
Keys.onReturnPressed: clicked()
|
||||
|
||||
canTrigger: true
|
||||
iconSource: JamiResources.localisation_sharing_send_pin_svg
|
||||
itemName: JamiStrings.shareLocation
|
||||
onClicked: {
|
||||
root.showMapClicked();
|
||||
root.close()
|
||||
}
|
||||
|
||||
KeyNavigation.tab: audioMessage
|
||||
KeyNavigation.backtab: videoMessage
|
||||
}
|
||||
]
|
||||
|
||||
|
|
|
@ -45,7 +45,6 @@ TabButton {
|
|||
|
||||
Accessible.name: root.labelText
|
||||
Accessible.role: Accessible.Button
|
||||
Accessible.description: root.acceleratorSequence
|
||||
|
||||
Rectangle {
|
||||
id: contentRect
|
||||
|
|
|
@ -479,6 +479,9 @@ Rectangle {
|
|||
anchors.bottom: parent.bottom
|
||||
enabled: !showPreview
|
||||
hoverEnabled: !showPreview
|
||||
Accessible.name: JamiStrings.showMoreMessagingOptions
|
||||
Accessible.role: Accessible.ComboBox
|
||||
Accessible.description: JamiStrings.showMoreMessagingOptionsDescription
|
||||
|
||||
// Used to choose the correct color for the button.
|
||||
readonly property bool highlight: down || hovered
|
||||
|
|
|
@ -945,4 +945,6 @@ Item {
|
|||
property string closeApplication: qsTr("Close application")
|
||||
property string dismissTip: qsTr("Dismiss this tip")
|
||||
property string tipDescription: qsTr("Tips to help you use Jami more effectively")
|
||||
property string showMoreMessagingOptions: qsTr("Show more messaging options")
|
||||
property string showMoreMessagingOptionsDescription: qsTr("Open a menu that allows you to send voice and video messages as well as sharing your location")
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue