forked from 0x2620/oxjs
adding symbols
This commit is contained in:
parent
b55ade5687
commit
6da40d325c
9 changed files with 54 additions and 16 deletions
|
|
@ -554,6 +554,11 @@ Ox.List = function(options, self) {
|
|||
return Math.ceil(self.pageLength * (self.options.itemHeight + self.itemMargin) / self.rowLength);
|
||||
}
|
||||
|
||||
function getPageLength(page) {
|
||||
var mod = self.listLength % self.pageLength;
|
||||
return page < self.pages - 1 || mod == 0 ? self.pageLength : mod;
|
||||
}
|
||||
|
||||
function getPositionById(id) {
|
||||
// fixme: is this really needed?
|
||||
var pos = -1;
|
||||
|
|
@ -679,11 +684,9 @@ Ox.List = function(options, self) {
|
|||
self.$items[pos].appendTo(that.$content);
|
||||
});
|
||||
self.selected.length && scrollToPosition(self.selected[0]);
|
||||
}
|
||||
|
||||
function getPageLength(page) {
|
||||
var mod = self.listLength % self.pageLength;
|
||||
return page < self.pages - 1 || mod == 0 ? self.pageLength : mod;
|
||||
// that.triggerEvent('init', {items: self.options.items.length});
|
||||
// fixme: do async lists need to trigger init?
|
||||
// will this only be reached in async lists?
|
||||
}
|
||||
|
||||
function loadPage(page, callback) {
|
||||
|
|
|
|||
|
|
@ -422,7 +422,7 @@ Ox.TextList = function(options, self) {
|
|||
} else if (format) {
|
||||
value = Ox.isObject(format) ?
|
||||
Ox['format' + Ox.toTitleCase(format.type)]
|
||||
.apply(this, $.merge([value], format.args)) :
|
||||
.apply(this, Ox.merge([value], format.args || [])) :
|
||||
format(value, data);
|
||||
} else if (Ox.isArray(value)) {
|
||||
value = value.join(', ');
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue