Lines Matching full:sort
761 // its models in sort order, as they're added and removed.
864 var sort = false;
865 var sortable = this.comparator && at == null && options.sort !== false;
883 if (sortable && !sort) sort = existing.hasChanged(sortAttr);
923 if (sortable) sort = true;
928 // Silently sort the collection if appropriate.
929 if (sort) this.sort({silent: true});
931 // Unless silenced, it's time to fire all appropriate add/sort/update events.
938 if (sort || orderChanged) this.trigger('sort', this, options);
1028 // Force the collection to re-sort itself. You don't need to call this under
1029 // normal circumstances, as the set will maintain sort order as each item
1031 sort: function(options) {
1033 if (!comparator) throw new Error('Cannot sort a set without a comparator');
1039 // Run sort based on type of `comparator`.
1043 this.models.sort(comparator);
1045 if (!options.silent) this.trigger('sort', this, options);