PartialTextChanged stops shooting on MvxAutoCompleteTextView after selecting an item

I use the MVVMCross wrapper around the Xallarin Android AutoCompleteTextView.

I am using the PartialTextChanged event to report that I need to call the ViewModel from the view to get additional suggestions.

This works fine until the user selects an item from the list. After that, no changes to the text will raise the PartialTextChanged event. It is as if filtering was disabled after selection.

There is a SetText method in AutoCompleteTextView that seems to enable filtering on \ off, but I'm not sure if you can use it.

TextChangedEvent still triggers the control, like AfterTextChanged, not PartialTextChanged, and this is what controls the updates.

I have debugged the source of MVVMCross and can't see the solution. Does anyone have any ideas?

Where can I view their mondroid \ xamarin android code?

thank

+3
source share
1 answer

After attaching the MVVMCross source code and debugging all the events that I found that under certain circumstances I did not update the ItemsSource after changing the PartialText property

The FilteringAdapter uses ManualResetEvent around the change in PartialText, and this is only signaled \ set by the NotifyDataSetChanged method.

, @slodge MVVM Java Castings Java.Lang.Object ViewModel. , .

, - Threading Android , PartialText ItemsSource - .

+3

Source: https://habr.com/ru/post/1537657/


All Articles