Add prefixEnabled
property to allow the prefix to be disabled
#415
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I ran in a weird bug with
TokenCompleteTextView.onRestoreInstanceState()
and so ended up not wanting to use the restored objects in onRestoreInstanceState (we have the state in our viewmodel. However the even though I'm not using the prefix thesetPrefix()
inonRestoreInstanceState()
the would clear the tokens I had already set in the TokenCompleteTextView in my activitiesonCreate()
. Specifically when it calledsetText()
.To resolve I've added the
prefixEnabled
property. This allows callers to disable the prefix behaviour and solve the issue I was seeing. However, there maybe an alternate way to solve this that doesn't involve and extra property. Open to suggestions.Also, apologies for the additional formatting changes it seems my code formatter got carried away. I can correct this if there's approval for this PR to the merged.