function _pagingNumbers(page, pages, buttons) {
		var
			numbers = [],
			half = Math.floor(buttons / 2);

		if (pages <= buttons) {
			numbers = _range(0, pages);
		}
		else if (buttons === 1) {
			// Single button - current page only
			numbers = [page];
		}
		else if (buttons === 3) {
			// Special logic for just three buttons
			if (page <= 1) {
				numbers = [0, 1, 'ellipsis'];
			}
			else if (page >= pages - 2) {
				numbers = _range(pages - 2, pages);
				numbers.unshift('ellipsis');
			}
			else {
				numbers = ['ellipsis', page, 'ellipsis'];
			}
		}
		else if (page <= half) {
			numbers = _range(0, buttons - 2);
			numbers.push('ellipsis', pages - 1);
		}
		else if (page >= pages - 1 - half) {
			numbers = _range(pages - (buttons - 2), pages);
			numbers.unshift(0, 'ellipsis');
		}
		else {
			numbers = _range(page - half + 2, page + half - 1);
			numbers.push('ellipsis', pages - 1);
			numbers.unshift(0, 'ellipsis');
		}

		return numbers;
	}
Compute what number buttons to show in the paging control

@param {*} page Current page
@param {*} pages Total number of pages
@param {*} buttons Target number of number buttons
@returns Buttons to show