mirror of
https://github.com/NuSkooler/enigma-bbs.git
synced 2025-07-25 12:08:21 +02:00
* SEXYZ: XModem & YModem
* Explicit sort avail to protocols * MenuView.removeItem() * Natural sort for more things * Fix some issues with HorizontalMenuView redraw/update * Sanatize non-blind upload filename (security) * Validator on non-blind upload filename
This commit is contained in:
parent
8261881e3e
commit
ff64a7aed5
10 changed files with 161 additions and 45 deletions
|
@ -77,6 +77,20 @@ MenuView.prototype.setItems = function(items) {
|
|||
}
|
||||
};
|
||||
|
||||
MenuView.prototype.removeItem = function(index) {
|
||||
this.items.splice(index, 1);
|
||||
|
||||
if(this.focusItems) {
|
||||
this.focusItems.splice(index, 1);
|
||||
}
|
||||
|
||||
if(this.focusedItemIndex >= index) {
|
||||
this.focusedItemIndex = Math.max(this.focusedItemIndex - 1, 0);
|
||||
}
|
||||
|
||||
this.positionCacheExpired = true;
|
||||
};
|
||||
|
||||
MenuView.prototype.getCount = function() {
|
||||
return this.items.length;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue