klinker41 / android-chips

Chips in your AutoCompleteTextView on Android

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

com.android.ex.chips.RecipientEditTextView cannot be instantiated - Rendering issues

opened this issue · comments

I'm having Rendering issues using this library. Here's the reported log from the Android Studio 2.2.2 preview:
java.lang.ClassCastException: com.android.layoutlib.bridge.android.view.WindowManagerImpl cannot be cast to android.view.WindowManagerImpl   at android.view.Window.setWindowManager(Window.java:743)   at android.view.Window.setWindowManager(Window.java:724)   at android.app.Dialog.<init>(Dialog.java:187)   at android.app.Dialog.<init>(Dialog.java:147)   at com.android.ex.chips.RecipientEditTextView.<init>(RecipientEditTextView.java:244)   at java.lang.reflect.Constructor.newInstance(Constructor.java:423)   at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:727)   at android.view.LayoutInflater.rInflate_Original(LayoutInflater.java:858)   at android.view.LayoutInflater_Delegate.rInflate(LayoutInflater_Delegate.java:70)   at android.view.LayoutInflater.rInflate(LayoutInflater.java:834)   at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:821)   at android.view.LayoutInflater.rInflate_Original(LayoutInflater.java:861)   at android.view.LayoutInflater_Delegate.rInflate(LayoutInflater_Delegate.java:70)   at android.view.LayoutInflater.rInflate(LayoutInflater.java:834)   at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:821)   at android.view.LayoutInflater.rInflate_Original(LayoutInflater.java:861)   at android.view.LayoutInflater_Delegate.rInflate(LayoutInflater_Delegate.java:70)   at android.view.LayoutInflater.rInflate(LayoutInflater.java:834)   at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:821)   at android.view.LayoutInflater.inflate(LayoutInflater.java:518)   at android.view.LayoutInflater.inflate(LayoutInflater.java:397)

I've tried syncing, cleaning, rebuilding, invalidating caches and restarting, changing api level, changing theme, but it doesn't work. If I remove the RecipientEditTextView the error goes. Here's the view:
<com.android.ex.chips.RecipientEditTextView android:layout_width="match_parent" android:layout_height="wrap_content" />

What type of Activity are you binding it to? Not really sure what the problem is. Is the sample app working for you?

Seems like an android studio bug. Thanks anyways. But I'd appreciate it if you look at this issue: #42