mabbas007 / TagsEditText

Android EditText for view tags or chips
Apache License 2.0
694 stars 124 forks source link

How can I clean Collection<String> tags in onTagsChanged #23

Closed aldakur closed 7 years ago

aldakur commented 7 years ago

First, congratulation for your library.

I have a button which save the tags in data base and clear the TagsEditText. But the next time when I type new tags and I press return, in the TagsEditText appear old tags and new tags because when the user press save button I should clean Collection<String> tags but I don't know how do it.

Thanks

aldakur commented 7 years ago

I found a simple solution.

mTagsEditText.getText().clear();
String [] tags = {};
mTagsEditText.setTags(tags);