forked from 0x2620/oxjs
remove Ox.Break
This commit is contained in:
parent
4139e171ca
commit
bda90f6b6b
44 changed files with 152 additions and 165 deletions
|
|
@ -652,7 +652,7 @@ Ox.List = function(options, self) {
|
|||
Ox.forEach(self.$items, function($item, i) {
|
||||
if ($item.options('data')[self.options.unique] == id) {
|
||||
pos = i;
|
||||
Ox.Break();
|
||||
return false; // break
|
||||
}
|
||||
});
|
||||
return pos;
|
||||
|
|
@ -744,7 +744,7 @@ Ox.List = function(options, self) {
|
|||
ids.push(self.$items[pos].options('data')[self.options.unique]);
|
||||
} else {
|
||||
notFound = true;
|
||||
Ox.Break();
|
||||
return false; // break
|
||||
}
|
||||
});
|
||||
if (notFound) {
|
||||
|
|
@ -1195,7 +1195,7 @@ Ox.List = function(options, self) {
|
|||
if (Ox.toLatin(v.title).toUpperCase().indexOf(str) == 0) {
|
||||
select(i);
|
||||
scrollToPosition(i);
|
||||
Ox.Break();
|
||||
return false; // break
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
@ -1428,7 +1428,9 @@ Ox.List = function(options, self) {
|
|||
if (oldIds.indexOf(item.id) > -1) {
|
||||
newIds.push(item.id);
|
||||
}
|
||||
newIds.length == oldIds.length && Ox.Break();
|
||||
if (newIds.length == oldIds.length) {
|
||||
return false; // break
|
||||
}
|
||||
});
|
||||
setSelected(newIds);
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue