Skip to content
Permalink
Browse files

UI Tabs: update selected property after add/remove, fixes #3065

  • Loading branch information
Klaus Hartl
Klaus Hartl committed Aug 15, 2008
1 parent 23167f8 commit 2675acc088d8efd4cfe5489cad3cfcc021de51ce
Showing with 4 additions and 0 deletions.
  1. +4 −0 ui/ui.tabs.js
@@ -73,6 +73,7 @@ $.widget("ui.tabs", {
o.disabled.push(i + 1);
});

// initialization from scratch
if (init) {

// attach necessary classes for styling if not present
@@ -153,6 +154,9 @@ $.widget("ui.tabs", {
});

}
// update selected after add/remove
else
o.selected = this.$lis.index( this.$lis.filter('.' + o.selectedClass)[0] );

// disable tabs
for (var i = 0, li; li = this.$lis[i]; i++)

0 comments on commit 2675acc

Please sign in to comment.
You can’t perform that action at this time.