Enable consumption of old 1.6 built root bundles

Fixes #17398.

(cherry picked from commit 2e59e88d38a047c70a10f9594ecc7b875a38fa3d)
Make SimpleQueryEngine sort Dates correctly

Fixes #17068.

(cherry picked from commit 682f5d0dfeb4833842d476e6d8da946f6eb97e0f)
Fix emit events on 'window' and 'document' objects
(cherry picked from commit 3beccffc21fbcd3e21681fc74a29b0c56a31572f)

Conflicts:

	tests/on/on.js
Fix star mapping, aliasing, and pathing for built layers.

Fixes #17475
Fixes #17621.  Backport 560b804f-0ae3-0310-86f3-f6aa0a117693 to 1.8.
improve i18n preload to take advantage of partially flattened locales, fixes #17155

(cherry picked from commit 341e41f1797739449d883e8951cda54bde53417e)
Revert "Fix IE11 sniffing. Fixes #17311."

This reverts commit f58c0e19ce509398985908688a768c8fb41191b8.

(cherry picked from commit 477d62923e7cd1e32799395301f21c008dc55de6)
(cherry picked from commit 788afa04681010da261850e81f847089826c7dba)
Add Microsoft-recommended UA sniff for IE11

Fixes #17311

(cherry picked from commit 28c2050cbb7f69daa57bd66e3b740a16bb19fd75)
(cherry picked from commit bad851981604b4978e406edf11ab0a23b019a859)

Conflicts:
	sniff.js
Add Trident UA to match every other UA

Refs #17311

(cherry picked from commit bbe72ecd13f5604802b2498f3623e7c5961069f4)
(cherry picked from commit 769bfce2141826ed873d3eba3302227a08a43052)
Always return QueryResults from map and filter (1.8 backport)

Fixes #17681

(cherry picked from commit bdd52aceb1319e919aa8a5157156c36170bcc098)
Use IE's native focusin/focusout support for IE9+ too, avoiding asynchronous focus notification, fixes #16968,  #16970, and refs #16926, #16972 !strict.

git-svn-id: http://svn.dojotoolkit.org/src/dojo/trunk@31152 560b804f-0ae3-0310-86f3-f6aa0a117693
(cherry picked from commit 74f1af634dff02139086221b69b6066c34546e18)

Conflicts:
	on.js
Correct detection of focusin support

Fixes #17599

(cherry picked from commit e245ce5c80b85351642fd1ffc18a2d77bbbb0770)
(cherry picked from commit ca391f932e3a3f032dd8b84566c4176857eb8ac3)
Improve focusin detection support

This change prevents unintentional scrolling and unfocusing of
whatever element was in focus before the feature detect in browsers
that need to do the long feature detect.

Adds test case.

Refs #17599

(cherry picked from commit 2536e5cd0935cc7356d584bab6ac2c73d3ad6164)

Conflicts:
	tests/on/on.js

(cherry picked from commit f774568707ea95b9a56bf646b2ce46e1c57907f8)

Conflicts:
	tests/on/on.js
Position test element so it is actually fixed to viewport

Fixes #17626

(cherry picked from commit 65e989efbcda628e72c9616faf11d480aacebf2f)
(cherry picked from commit ab088a9741a6383495a20bc34e84403e2962ed03)
Remove dumb speed test that compares against an old API we will never restore

Fixes #11200

(cherry picked from commit a3dd7a47aa01315e601525b0d8217a8408237149)
Make selective fixes to the date/locale tests based on what Mark Hays did for 1.9
Refactor robot so initRobot() is implemented as an asynchronous test fixture, rather than using monkey patching code that doesn't work well, having two places calling doh._run() in a race condition.   This design also makes better code separation between vanilla DOH and robot.

I plan to do the same for startRobot() in the next check in.

Also fixes priority of ready() call inside DOH.   The default priority is 1000, so we need to be higher than that, so that DOH doesn't execute until the iframe's dojo.ready() call has finished executing.

Fixes #16386 !strict.

git-svn-id: http://svn.dojotoolkit.org/src/dojo/trunk@30060 560b804f-0ae3-0310-86f3-f6aa0a117693
(cherry picked from commit 6698b8f5f307bd1c8ded908e22b8b91e1b1a6047)
Refactor robot so startRobot() is implemented as an asynchronous test fixture, rather than monkey patching doh.run().  This design makes better code separation between vanilla DOH and robot.

Refs #16386 !strict.

git-svn-id: http://svn.dojotoolkit.org/src/dojo/trunk@30074 560b804f-0ae3-0310-86f3-f6aa0a117693
(cherry picked from commit 28f564e8186eb26efc4f99746ac1d0c7d3038bb0)
Do not execute dojo/on until DOM is ready

This ensures that the focusin/out feature detection operates
properly even when people do not follow best practices and put
their code in the <head> instead of before </body>.

Refs #17599.

(cherry picked from commit 08187b88273f09326e5ebc8ea03eecd592e7eaca)
(cherry picked from commit 31aab4cc1bb93592d1cb6a3c4e34f612f36d525a)

Conflicts:
	on.js
Fix emit events on 'window' and 'document' objects