change: function ( event, ui ) {
ok( event, "change event fired on change" );
equal( event.type, "selectmenuchange", "event type set to selectmenuchange" );
- equal( ui.item.element[ 0 ].nodeName.toLowerCase(), "option", "ui.item.element[0] points to original option element" );
+ equal( ui.item.element[ 0 ].nodeName.toLowerCase(), "option", "ui.item.element[ 0 ] points to original option element" );
equal( ui.item.value, value, "ui.item.value property updated correctly" );
}
});
focus: function ( event, ui ) {
ok( event, "focus event fired on mouseover" );
equal( event.type, "selectmenufocus", "event type set to selectmenufocus" );
- equal( ui.item.element[0].nodeName.toLowerCase(), "option", "ui points to original option element" );
+ equal( ui.item.element[ 0 ].nodeName.toLowerCase(), "option", "ui points to original option element" );
}
});
select: function ( event, ui ) {
ok( event, "select event fired on item select" );
equal( event.type, "selectmenuselect", "event type set to selectmenuselect" );
- equal( ui.item.element[0].nodeName.toLowerCase(), "option", "ui points to original option element" );
+ equal( ui.item.element[ 0 ].nodeName.toLowerCase(), "option", "ui points to original option element" );
}
});
var detached = $( "<div>" ),
element = $( "#speed" ).selectmenu();
- equal( element.selectmenu( "menuWidget" ).parent().parent()[0], document.body, "defaults to body" );
+ equal( element.selectmenu( "menuWidget" ).parent().parent()[ 0 ], document.body, "defaults to body" );
element.selectmenu( "destroy" );
element.selectmenu({
appendTo: ".selectmenu-wrap"
});
- equal( element.selectmenu( "menuWidget" ).parent().parent()[0], $( "#selectmenu-wrap1" )[0], "first found element" );
+ equal( element.selectmenu( "menuWidget" ).parent().parent()[ 0 ], $( "#selectmenu-wrap1" )[ 0 ], "first found element" );
equal( $( "#selectmenu-wrap2 .ui-selectmenu" ).length, 0, "only appends to one element" );
element.selectmenu( "destroy" );
$( "#selectmenu-wrap2" ).addClass( "ui-front" );
element.selectmenu();
- equal( element.selectmenu( "menuWidget" ).parent().parent()[0], $( "#selectmenu-wrap2" )[0], "null, inside .ui-front" );
+ equal( element.selectmenu( "menuWidget" ).parent().parent()[ 0 ], $( "#selectmenu-wrap2" )[ 0 ], "null, inside .ui-front" );
element.selectmenu( "destroy" );
$( "#selectmenu-wrap2" ).removeClass( "ui-front" );
element.selectmenu().selectmenu( "option", "appendTo", "#selectmenu-wrap1" );
- equal( element.selectmenu( "menuWidget" ).parent().parent()[0], $( "#selectmenu-wrap1" )[0], "modified after init" );
+ equal( element.selectmenu( "menuWidget" ).parent().parent()[ 0 ], $( "#selectmenu-wrap1" )[ 0 ], "modified after init" );
element.selectmenu( "destroy" );
element.selectmenu({
appendTo: detached
});
- equal( element.selectmenu( "menuWidget" ).parent().parent()[0], detached[0], "detached jQuery object" );
+ equal( element.selectmenu( "menuWidget" ).parent().parent()[ 0 ], detached[ 0 ], "detached jQuery object" );
element.selectmenu( "destroy" );
element.selectmenu({
appendTo: detached[ 0 ]
});
- equal( element.selectmenu( "menuWidget" ).parent().parent()[0], detached[0], "detached DOM element" );
+ equal( element.selectmenu( "menuWidget" ).parent().parent()[ 0 ], detached[ 0 ], "detached DOM element" );
element.selectmenu( "destroy" );
element.selectmenu().selectmenu( "option", "appendTo", detached );
- equal( element.selectmenu( "menuWidget" ).parent().parent()[0], detached[0], "detached DOM element via option()" );
+ equal( element.selectmenu( "menuWidget" ).parent().parent()[ 0 ], detached[ 0 ], "detached DOM element via option()" );
element.selectmenu( "destroy" );
});