Merge lp:~tiagosh/messaging-app/show_notification_mic_icon into lp:messaging-app

Proposed by Tiago Salem Herrmann
Status: Merged
Approved by: Gustavo Pichorim Boiko
Approved revision: 520
Merged at revision: 532
Proposed branch: lp:~tiagosh/messaging-app/show_notification_mic_icon
Merge into: lp:messaging-app
Diff against target: 58 lines (+41/-0)
1 file modified
src/qml/ComposeBar.qml (+41/-0)
To merge this branch: bzr merge lp:~tiagosh/messaging-app/show_notification_mic_icon
Reviewer Review Type Date Requested Status
Gustavo Pichorim Boiko (community) Approve
PS Jenkins bot continuous-integration Needs Fixing
Review via email: mp+287212@code.launchpad.net

Commit message

Show notification when the the record icon is only clicked.

Description of the change

Show notification when the the record icon is only clicked.

To post a comment you must log in.
517. By Tiago Salem Herrmann

Show notification when the the record icon is only clicked

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
518. By Tiago Salem Herrmann

Use popover instead of notification

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
519. By Tiago Salem Herrmann

Avoid dismissing the osk

520. By Tiago Salem Herrmann

Close popup when text changes

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
Gustavo Pichorim Boiko (boiko) wrote :

Can you make the background of the popup dark? (maybe follow the translucent black scheme used by the notifications?)?
The contrast between the hint and the rest of the content on screen is really bad, which makes it hard to notice.

review: Needs Fixing
Revision history for this message
Gustavo Pichorim Boiko (boiko) wrote :

Looks good!

review: Approve
521. By Tiago Salem Herrmann

Fix osk focus on new message screen

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/qml/ComposeBar.qml'
2--- src/qml/ComposeBar.qml 2016-03-07 21:16:20 +0000
3+++ src/qml/ComposeBar.qml 2016-03-17 18:41:13 +0000
4@@ -138,6 +138,32 @@
5 }
6 }
7
8+ Component {
9+ id: microphoneWarningPopover
10+
11+ Popover {
12+ id: popover
13+ Column {
14+ id: containerLayout
15+ anchors {
16+ left: parent.left
17+ top: parent.top
18+ right: parent.right
19+ }
20+ ListItem.Standard {
21+ text: i18n.tr("You have to press and hold the record icon")
22+ onClicked: {
23+ PopupUtils.close(popover)
24+ }
25+ }
26+ Connections {
27+ target: composeBar
28+ onTextChanged: PopupUtils.close(popover)
29+ }
30+ }
31+ }
32+ }
33+
34 ListItem.ThinDivider {
35 anchors.top: parent.top
36 }
37@@ -551,6 +577,21 @@
38 iconColor: composeBar.recording ? "black" : "gray"
39 iconName: "audio-input-microphone-symbolic"
40
41+ onClicked: {
42+ if (!composeBar.audioAttached) {
43+ var oskFocus = null
44+ if (textEntry.activeFocus) {
45+ oskFocus = composeBar.forceFocus
46+ } else if (multiRecipient.activeFocus) {
47+ oskFocus = multiRecipient.forceActiveFocus
48+ }
49+ PopupUtils.open(microphoneWarningPopover, recordButton)
50+ // avoid dismissing the osk
51+ if (oskFocus) {
52+ oskFocus()
53+ }
54+ }
55+ }
56 onPressed: audioRecordingBar.startRecording()
57 onReleased: {
58 audioRecordingBar.stopRecording()

Subscribers

People subscribed via source and target branches