Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to resolve attribute at index 6 #5

Closed
FrancisShi opened this issue Jun 3, 2015 · 4 comments
Closed

Failed to resolve attribute at index 6 #5

FrancisShi opened this issue Jun 3, 2015 · 4 comments

Comments

@FrancisShi
Copy link

Caused by: java.lang.RuntimeException: Failed to resolve attribute at index 6
at android.content.res.TypedArray.getColorStateList(TypedArray.java:425)
at android.support.design.widget.FloatingActionButton.(FloatingActionButton.java:91)
at android.support.design.widget.FloatingActionButton.(FloatingActionButton.java:79)
at android.support.design.widget.FloatingActionButton.(FloatingActionButton.java:75)
at com.race604.flyrefresh.PullHeaderLayout.setActionDrawable(PullHeaderLayout.java:151)
at com.race604.flyrefresh.FlyRefreshLayout.onFinishInflate(FlyRefreshLayout.java:58)

@FrancisShi
Copy link
Author

java.lang.ArrayIndexOutOfBoundsException: 1
at android.view.animation.PathInterpolator.initPath(PathInterpolator.java:161)
at android.view.animation.PathInterpolator.initQuad(PathInterpolator.java:147)
at android.view.animation.PathInterpolator.(PathInterpolator.java:72)
at android.support.v4.view.animation.PathInterpolatorCompatApi21.create(PathInterpolatorCompatApi21.java:37)
at android.support.v4.view.animation.PathInterpolatorCompat.create(PathInterpolatorCompat.java:63)
at com.race604.flyrefresh.internal.MountanScenceView.updateTreePath(MountanScenceView.java:152)
at com.race604.flyrefresh.internal.MountanScenceView.init(MountanScenceView.java:105)
at com.race604.flyrefresh.internal.MountanScenceView.(MountanScenceView.java:62)
at com.race604.flyrefresh.FlyRefreshLayout.init(FlyRefreshLayout.java:47)
at com.race604.flyrefresh.FlyRefreshLayout.(FlyRefreshLayout.java:33)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
at org.jetbrains.android.uipreview.ViewLoader.createNewInstance(ViewLoader.java:413)
at org.jetbrains.android.uipreview.ViewLoader.loadView(ViewLoader.java:105)
at com.android.tools.idea.rendering.LayoutlibCallback.loadView(LayoutlibCallback.java:176)
at android.view.BridgeInflater.loadCustomView(BridgeInflater.java:214)
at android.view.BridgeInflater.createViewFromTag(BridgeInflater.java:142)
at android.view.LayoutInflater.rInflate_Original(LayoutInflater.java:806)
at android.view.LayoutInflater_Delegate.rInflate(LayoutInflater_Delegate.java:64)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:782)
at android.view.LayoutInflater.inflate(LayoutInflater.java:504)
at android.view.LayoutInflater.inflate(LayoutInflater.java:385)
at com.android.layoutlib.bridge.impl.RenderSessionImpl.inflate(RenderSessionImpl.java:413)
at com.android.layoutlib.bridge.Bridge.createSession(Bridge.java:321)
at com.android.ide.common.rendering.LayoutLibrary.createSession(LayoutLibrary.java:350)
at com.android.tools.idea.rendering.RenderService$5.compute(RenderService.java:708)
at com.android.tools.idea.rendering.RenderService$5.compute(RenderService.java:697)
at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:932)
at com.android.tools.idea.rendering.RenderService.createRenderSession(RenderService.java:697)
at com.android.tools.idea.rendering.RenderService.render(RenderService.java:816)
at com.intellij.android.designer.designSurface.AndroidDesignerEditorPanel$6.run(AndroidDesignerEditorPanel.java:480)
at com.intellij.util.ui.update.MergingUpdateQueue.execute(MergingUpdateQueue.java:320)
at com.intellij.util.ui.update.MergingUpdateQueue.execute(MergingUpdateQueue.java:310)
at com.intellij.util.ui.update.MergingUpdateQueue$2.run(MergingUpdateQueue.java:254)
at com.intellij.util.ui.update.MergingUpdateQueue.flush(MergingUpdateQueue.java:269)
at com.intellij.util.ui.update.MergingUpdateQueue.flush(MergingUpdateQueue.java:227)
at com.intellij.util.ui.update.MergingUpdateQueue.run(MergingUpdateQueue.java:217)
at com.intellij.util.concurrency.QueueProcessor.runSafely(QueueProcessor.java:238)
at com.intellij.util.Alarm$Request$1.run(Alarm.java:327)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:439)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
at java.lang.Thread.run(Thread.java:695)

@race604
Copy link
Owner

race604 commented Jun 3, 2015

Did you use the FlyRefresh library in your own project, or just run the sample? What's the android api level of your device?
Please check if this help: http://stackoverflow.com/questions/30595187/android-xml-runtimeexception-failed-to-resolve-attribute-at-index-6

@FrancisShi
Copy link
Author

I use "flyrefresh:library:1.0.1" through gradle, and if I add "com.race604.flyrefresh.FlyRefreshLayout" in my layout xml,it will crash.
My device is API 22 and 21

@race604
Copy link
Owner

race604 commented Jun 4, 2015

What's the Theme you use for your Application or Activity? You MUST use theme based on an AppCompat Theme. Please take a look at this: http://stackoverflow.com/a/30557995/1260562

@race604 race604 closed this as completed Jun 7, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants