Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,8 @@ public abstract class ComboBoxBase<TComponent extends ComboBoxBase<TComponent, T
HasListDataView<TItem, ComboBoxListDataView<TItem>>, HasTheme,
HasValidationProperties, HasValidator<TValue>, HasPlaceholder {

private String lastKnownFilter;

/**
* Registration for custom value listeners that disallows entering custom
* values as soon as there are no more listeners for the custom value event
Expand Down Expand Up @@ -345,9 +347,8 @@ public void setAllowCustomValue(boolean allowCustomValue) {
*
* @return the filter string
*/
@Synchronize(property = "filter", value = "filter-changed")
protected String getFilter() {
return getElement().getProperty("filter");
return lastKnownFilter;
}

/**
Expand All @@ -358,7 +359,11 @@ protected String getFilter() {
* @param filter
* the String value to set
*/
@Deprecated
protected void setFilter(String filter) {
lastKnownFilter = filter;
// MT 20250-02-21 I assume client side never uses this, probably the
// whole method is obsolete
getElement().setProperty("filter", filter == null ? "" : filter);
}

Expand Down Expand Up @@ -1344,6 +1349,7 @@ private void confirmUpdate(int id) {
*/
@ClientCallable
private void setRequestedRange(int start, int length, String filter) {
this.lastKnownFilter = filter;
dataController.setRequestedRange(start, length, filter);
}

Expand Down