Skip to main content

Bug Tracker

Side navigation

#12278 closed bug (fixed)

Opened August 13, 2012 11:40AM UTC

Closed August 20, 2012 01:53AM UTC

.promise(type) not working for non-default queue

Reported by: creativecouple Owned by: gnarf
Priority: high Milestone: 1.8.1
Component: queue Version: 1.6.3
Keywords: Cc:
Blocked by: Blocking:
Description

On http://jsfiddle.net/creativecouple/3Y63M/1/ I have an example with .promise(type).

There is one element animated (.delay) with the default queue 'fx' and the other one with another queue 'foo'.

As you can see .promise(type) don't wait for the non-default queue to finish, but it does for the default case.

Why?

This is the same for any jQuery version from 1.6.0 up to 1.8.0

Attachments (0)
Change History (7)

Changed August 13, 2012 03:39PM UTC by timmywil comment:1

component: unfileddeferred
priority: undecidedlow
resolution: → invalid
status: newclosed

This is a forum question. If this is a bug or enhancement request, it needs to be fleshed out more.

Changed August 13, 2012 03:51PM UTC by creativecouple comment:2

Why is this not a bug?

Ok, minimal example:

$('span').animate{{left:'+=100px'},{queue:'myfx'}).dequeue('myfx');

$('span').promise('myfx') is now resolved. This is a bug!

$('span').promise('myfx') must resolve only after the animation finished.

But it is resolved immediately.

Changed August 13, 2012 04:37PM UTC by jaubourg comment:3

resolution: invalid
status: closedreopened

It's actually a bug.

Changed August 13, 2012 04:38PM UTC by jaubourg comment:4

component: deferredqueue
owner: → jaubourg
priority: lowhigh
status: reopenedassigned

Changed August 13, 2012 05:40PM UTC by gnarf comment:5

owner: jaubourggnarf

Changed August 13, 2012 06:03PM UTC by gnarf comment:6

milestone: None1.8.1
version: 1.8.01.6.3

https://github.com/jquery/jquery/pull/893 should fix this - It requires editing some of our unit tests though, so we should take some care with it.

Changed August 20, 2012 01:53AM UTC by Corey Frang comment:7

resolution: → fixed
status: assignedclosed

Fix #12278. Promises on non-default queue wait until a dequeue is attempted on an empty queue. Close gh-893.

Changeset: 3812f9436da09d9f31ca4a61a14cd70f3e8cbeaf