File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -473,8 +473,8 @@ $.widget( "ui.autocomplete", {
473
473
this . search ( null , event ) ;
474
474
return ;
475
475
}
476
- if ( this . menu . first ( ) && / ^ p r e v i o u s / . test ( direction ) ||
477
- this . menu . last ( ) && / ^ n e x t / . test ( direction ) ) {
476
+ if ( this . menu . isFirstItem ( ) && / ^ p r e v i o u s / . test ( direction ) ||
477
+ this . menu . isLastItem ( ) && / ^ n e x t / . test ( direction ) ) {
478
478
this . _value ( this . term ) ;
479
479
this . menu . blur ( ) ;
480
480
return ;
Original file line number Diff line number Diff line change @@ -447,11 +447,11 @@ $.widget( "ui.menu", {
447
447
this . _move ( "prev" , "last" , event ) ;
448
448
} ,
449
449
450
- first : function ( ) {
450
+ isFirstItem : function ( ) {
451
451
return this . active && ! this . active . prevAll ( ".ui-menu-item" ) . length ;
452
452
} ,
453
453
454
- last : function ( ) {
454
+ isLastItem : function ( ) {
455
455
return this . active && ! this . active . nextAll ( ".ui-menu-item" ) . length ;
456
456
} ,
457
457
@@ -480,7 +480,7 @@ $.widget( "ui.menu", {
480
480
this . focus ( event , this . activeMenu . children ( ".ui-menu-item" ) . first ( ) ) ;
481
481
return ;
482
482
}
483
- if ( this . last ( ) ) {
483
+ if ( this . isLastItem ( ) ) {
484
484
return ;
485
485
}
486
486
if ( this . _hasScroll ( ) ) {
@@ -504,7 +504,7 @@ $.widget( "ui.menu", {
504
504
this . focus ( event , this . activeMenu . children ( ".ui-menu-item" ) . first ( ) ) ;
505
505
return ;
506
506
}
507
- if ( this . first ( ) ) {
507
+ if ( this . isFirstItem ( ) ) {
508
508
return ;
509
509
}
510
510
if ( this . _hasScroll ( ) ) {
You can’t perform that action at this time.
0 commit comments