Merge lp:~unity-team/unity8/fix-slide-to-accept-call into lp:unity8

Proposed by Michael Zanetti
Status: Merged
Approved by: Mirco Müller
Approved revision: 1420
Merged at revision: 1423
Proposed branch: lp:~unity-team/unity8/fix-slide-to-accept-call
Merge into: lp:unity8
Diff against target: 44 lines (+10/-10)
2 files modified
qml/Notifications/Notification.qml (+4/-4)
tests/qmltests/Notifications/tst_SwipeToAct.qml (+6/-6)
To merge this branch: bzr merge lp:~unity-team/unity8/fix-slide-to-accept-call
Reviewer Review Type Date Requested Status
PS Jenkins bot (community) continuous-integration Approve
Mirco Müller (community) Approve
Review via email: mp+240726@code.launchpad.net

Commit message

fix positive/negative answer order on the new swipe notification

Description of the change

 * Are there any related MPs required for this MP to build/function as expected? Please list.

no

 * Did you perform an exploratory manual test run of your code change and any related functionality?

yes

 * Did you make sure that your branch does not contain spurious tags?

yes

 * If you changed the packaging (debian), did you subscribe the ubuntu-unity team to this MP?

n/a

 * If you changed the UI, has there been a design review?

n/a

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
Mirco Müller (macslow) wrote :

That's looking good.

review: Approve
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'qml/Notifications/Notification.qml'
--- qml/Notifications/Notification.qml 2014-10-31 10:08:38 +0000
+++ qml/Notifications/Notification.qml 2014-11-05 14:30:44 +0000
@@ -477,11 +477,11 @@
477 width: buttonRow.width477 width: buttonRow.width
478 leftIconName: "call-end"478 leftIconName: "call-end"
479 rightIconName: "call-start"479 rightIconName: "call-start"
480 onRightTriggered: {
481 notification.notification.invokeAction(notification.actions.data(0, ActionModel.RoleActionId))
482 }
483
480 onLeftTriggered: {484 onLeftTriggered: {
481 notification.notification.invokeAction(notification.actions.data(0, ActionModel.RoleActionId))
482 }
483
484 onRightTriggered: {
485 notification.notification.invokeAction(notification.actions.data(1, ActionModel.RoleActionId))485 notification.notification.invokeAction(notification.actions.data(1, ActionModel.RoleActionId))
486 }486 }
487 }487 }
488488
=== modified file 'tests/qmltests/Notifications/tst_SwipeToAct.qml'
--- tests/qmltests/Notifications/tst_SwipeToAct.qml 2014-10-31 10:45:40 +0000
+++ tests/qmltests/Notifications/tst_SwipeToAct.qml 2014-11-05 14:30:44 +0000
@@ -259,14 +259,14 @@
259 var x = swipeMouseArea.width / 2259 var x = swipeMouseArea.width / 2
260 var y = swipeMouseArea.height / 2260 var y = swipeMouseArea.height / 2
261261
262 if(data.checkSwipeToActAccept) {
263 tryCompareFunction(function() { mouseDrag(slider, x, y, (swipeMouseArea.width / 2) - slider.width, 0); return actionSpy.signalArguments.length > 0; }, true);
264 compare(actionSpy.signalArguments[0][0], data.actions.data(0, ActionModel.RoleActionId), "got wrong id for positive action")
265 actionSpy.clear()
266 }
262 if(data.checkSwipeToActReject) {267 if(data.checkSwipeToActReject) {
263 tryCompareFunction(function() { mouseDrag(slider, x, y, -(swipeMouseArea.width / 2), 0); return actionSpy.signalArguments.length > 0; }, true);268 tryCompareFunction(function() { mouseDrag(slider, x, y, -(swipeMouseArea.width / 2), 0); return actionSpy.signalArguments.length > 0; }, true);
264 compare(actionSpy.signalArguments[0][0], data.actions.data(0, ActionModel.RoleActionId), "got wrong id for negative action")269 compare(actionSpy.signalArguments[0][0], data.actions.data(1, ActionModel.RoleActionId), "got wrong id for negative action")
265 actionSpy.clear()
266 }
267 if(data.checkSwipeToActAccept) {
268 tryCompareFunction(function() { mouseDrag(slider, x, y, (swipeMouseArea.width / 2) - slider.width, 0); return actionSpy.signalArguments.length > 0; }, true);
269 compare(actionSpy.signalArguments[0][0], data.actions.data(1, ActionModel.RoleActionId), "got wrong id for positive action")
270 actionSpy.clear()270 actionSpy.clear()
271 }271 }
272 }272 }

Subscribers

People subscribed via source and target branches