move sorting code to ns.Box.prototype._sortViewNodes
refactor _sortViewNodes