@Override
    public void toggleSortOrder(int column) {
        if (isSortable(column)) {
            List<? extends SortKey> sortKeys = getSortKeys();
            if (!sortKeys.isEmpty()) {
                SortKey primarySortKey = sortKeys.get(0);
                if (primarySortKey.getColumn() == column
                        && primarySortKey.getSortOrder() == SortOrder.DESCENDING) {
                    setSortKeys(null);
                    return;
                }
            }
            super.toggleSortOrder(column);
        }
    }