Skip to content

Commit

Permalink
Remove pagination-related properties and methods
Browse files Browse the repository at this point in the history
The GridTableView class no longer manages pagination properties such as PageCountCalculationStrategy, page count, and visible row count. This change streamlines the class by eliminating unused features and focusing on core functionalities.
  • Loading branch information
dlemmermann committed Sep 24, 2024
1 parent 727583c commit a4e220d
Showing 1 changed file with 0 additions and 117 deletions.
117 changes: 0 additions & 117 deletions gemsfx/src/main/java/com/dlsc/gemsfx/gridtable/GridTableView.java
Original file line number Diff line number Diff line change
Expand Up @@ -104,121 +104,4 @@ public final IntegerProperty minNumberOfRowsProperty() {
public final void setMinNumberOfRows(int minNumberOfRows) {
this.minNumberOfRows.set(minNumberOfRows);
}

/**
* Possible ways for the list view to calculate the total number of pages
* available.
*/
public enum PageCountCalculationStrategy {

/**
* The total number of pages is provided by an explicit call from outside the control
* to the {@link #setPageCount(int)} method.
*/
EXTERNAL,

/**
* The total number of pages shown by the list view is based on the number of items in
* the data and the number of visible rows.
*/
INTERNAL
}

private final ObjectProperty<PageCountCalculationStrategy> pageCountCalculationStrategy = new SimpleObjectProperty<>(this, "pageCountCalculationStrategy", PageCountCalculationStrategy.INTERNAL);

public final PageCountCalculationStrategy getPageCountCalculationStrategy() {
return pageCountCalculationStrategy.get();
}

public final ObjectProperty<PageCountCalculationStrategy> pageCountCalculationStrategyProperty() {
return pageCountCalculationStrategy;
}

public final void setPageCountCalculationStrategy(PageCountCalculationStrategy pageCountCalculationStrategy) {
this.pageCountCalculationStrategy.set(pageCountCalculationStrategy);
}

private final BooleanProperty usingScrollPane = new SimpleBooleanProperty(this, "usingScrollPane", false);

public final boolean isUsingScrollPane() {
return usingScrollPane.get();
}

public final BooleanProperty usingScrollPaneProperty() {
return usingScrollPane;
}

public final void setUsingScrollPane(boolean usingScrollPane) {
this.usingScrollPane.set(usingScrollPane);
}

private final BooleanProperty showItemCounter = new SimpleBooleanProperty(this, "showItemCounter", true);

public boolean isShowItemCounter() {
return showItemCounter.get();
}

public final BooleanProperty showItemCounterProperty() {
return showItemCounter;
}

public final void setShowItemCounter(boolean showItemCounter) {
this.showItemCounter.set(showItemCounter);
}

private final IntegerProperty pageCount = new SimpleIntegerProperty(this, "pageCount", 0);

public final int getPageCount() {
return pageCount.get();
}

public final IntegerProperty pageCountProperty() {
return pageCount;
}

public final void setPageCount(int pageCount) {
this.pageCount.set(pageCount);
}

private final IntegerProperty maxPageIndicatorCount = new SimpleIntegerProperty(this, "maxPageIndicatorCount", 5);

public final int getMaxPageIndicatorCount() {
return maxPageIndicatorCount.get();
}

public final IntegerProperty maxPageIndicatorCountProperty() {
return maxPageIndicatorCount;
}

public void setMaxPageIndicatorCount(int maxPageIndicatorCount) {
this.maxPageIndicatorCount.set(maxPageIndicatorCount);
}

private final IntegerProperty page = new SimpleIntegerProperty(this, "page", 0);

public final int getPage() {
return page.get();
}

public final IntegerProperty pageProperty() {
return page;
}

public void setPage(int page) {
this.page.set(page);
}

private final IntegerProperty visibleRowCount = new SimpleIntegerProperty(this, "visibleRowCount", 5);

public final int getVisibleRowCount() {
return visibleRowCount.get();
}

public final IntegerProperty visibleRowCountProperty() {
return visibleRowCount;
}

public final void setVisibleRowCount(int visibleRowCount) {
this.visibleRowCount.set(visibleRowCount);
}
}

0 comments on commit a4e220d

Please sign in to comment.