Closed Bug 1130964 Opened 9 years ago Closed 9 years ago

[Stingray] Enqueue card swapping request during swapping

Categories

(Firefox OS Graveyard :: Gaia::TV::Home, defect)

x86
macOS
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: dwi2, Assigned: dwi2)

References

Details

(Whiteboard: [ft:conndevices][partner-interest])

Attachments

(1 file)

This is a follow-up of bug 1130701. 
When user hit left/right key too frequently in edit mode, we will ignore those event if we are busy in processing card swapping.

However, instead of ignoring this event, we should further improve user experience by enqueuing event and process them when card manager is no longer busy.
Assignee: nobody → tzhuang
Comment on attachment 8583582 [details] [review]
[gaia] dwi2:bug1130964 > mozilla-b2g:master

Hi Rex,

Please help to review this patch. Thanks

We introduce a 'swapQueue' in edit.js now. It enqueues all 'onMove' actions in it. And we start consuming these 'onMove' when there is no ongoing animation. 

Also, we let scrollable to emit 'nodeTransformEnd' event to notify when animation ends, which is actually based on 'transmissionend' event. However, 'transmissionend' event could be cancelled in some circumstance, we also have a _swapTimer to handle the case when 'nodeTransformEnd' ('transmissionend') is not emitted.
Attachment #8583582 - Flags: review?(rexboy)
Comment on attachment 8583582 [details] [review]
[gaia] dwi2:bug1130964 > mozilla-b2g:master

Looks good to me.
Attachment #8583582 - Flags: review?(rexboy) → review+
Keywords: checkin-needed
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Whiteboard: [ft:conndevices] → [ft:conndevices][partner-interest]
You need to log in before you can comment on or make changes to this bug.