Added a number of additional speed gains (we now hold our own against Dojo and DOMQuery), touched up some of the selector code, fixed some minor bugs, fixed a bug with triggerEvent in Opera, fixed some more test case bugs.
This commit is contained in:
parent
3446c3af76
commit
9c94ef4c41
4 changed files with 868 additions and 863 deletions
|
@ -264,13 +264,12 @@ function equals(expected, actual, message) {
|
|||
* @param String type
|
||||
*/
|
||||
function triggerEvent( elem, type, event ) {
|
||||
if ( jQuery.browser.mozilla ) {
|
||||
if ( jQuery.browser.mozilla || jQuery.browser.opera ) {
|
||||
event = document.createEvent("MouseEvents");
|
||||
event.initMouseEvent(type, true, true, elem.ownerDocument.defaultView,
|
||||
0, 0, 0, 0, 0, false, false, false, false, 0, null);
|
||||
elem.dispatchEvent( event );
|
||||
} else if ( jQuery.browser.msie || jQuery.browser.opera ) {
|
||||
event = document.createEventObject();
|
||||
elem.fireEvent("on"+type, event);
|
||||
} else if ( jQuery.browser.msie ) {
|
||||
elem.fireEvent("on"+type);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue