0

i found solution ,and i replace new 2.3.3 as ,and use 1.0.2

all of the question render problem solved!!!

Cause the problem that IDE AS 1.0.2 use actionbar ! But as2 etc looks like OLD ACTIONBAR DEPRECIATED!

I am making an Android app and trying to use an ActionBar.

I am getting the following error in the log:

UnsupportedMethodException Unsupported method: AndroidProject.getPluginGeneration(). The version of Gradle you connect to does not support that method. To resolve the problem you can change/upgrade the target version of Gradle you connect to. Alternatively, you can ignore this exception and read other information from the model.

And this error for the layout:

Rendering Problems Unable to find the layout for Action Bar. Consider updating to a more recent version of appcompat, or switch the rendering library in the IDE down to API 21 (Details) Tip: Try to refresh the layout.

When I tried reducing the SDK version to 20 or 21 it did not help.

Has anyone been able to solve this?

The details about action bar? I guess it is ,but I am not sure?

 Rendering Problems (Details)

java.lang.RuntimeException: Unable to find the layout for Action Bar.
    at com.android.layoutlib.bridge.bars.BridgeActionBar.<init>(BridgeActionBar.java:57)
    at com.android.layoutlib.bridge.bars.AppCompatActionBar.<init>(AppCompatActionBar.java:59)
    at com.android.layoutlib.bridge.impl.Layout.createActionBar(Layout.java:238)
    at com.android.layoutlib.bridge.impl.Layout.<init>(Layout.java:150)
    at com.android.layoutlib.bridge.impl.RenderSessionImpl.inflate(RenderSessionImpl.java:301)
    at com.android.layoutlib.bridge.Bridge.createSession(Bridge.java:429)
    at com.android.ide.common.rendering.LayoutLibrary.createSession(LayoutLibrary.java:389)
    at com.android.tools.idea.rendering.RenderTask$2.compute(RenderTask.java:548)
    at com.android.tools.idea.rendering.RenderTask$2.compute(RenderTask.java:533)
    at com.intellij.openapi.application.impl.ApplicationImpl.runReadAction(ApplicationImpl.java:966)
    at com.android.tools.idea.rendering.RenderTask.createRenderSession(RenderTask.java:533)
    at com.android.tools.idea.rendering.RenderTask.lambda$inflate$70(RenderTask.java:659)
    at java.util.concurrent.FutureTask.run(FutureTask.java:266)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    at java.lang.Thread.run(Thread.java:745)
John Joe
  • 12,412
  • 16
  • 70
  • 135
xxxman
  • 11
  • 1
  • 5
  • 1
    If you are starting a new project consider using ToolBar instead of ActionBar – firegloves Jan 13 '17 at 16:43
  • 1
    `To resolve the problem you can change/upgrade the target version of Gradle you connect to` ... What version **are** you using? – OneCricketeer Jan 13 '17 at 16:47
  • android { compileSdkVersion 20 buildToolsVersion '20.0.0' defaultConfig { applicationId 'estagreen.com.funbike' minSdkVersion 10 targetSdkVersion 20 versionCode 8 versionName '1.7' } – xxxman Jan 13 '17 at 16:54
  • Can you share your layout? – Doron Yakovlev Golani Jan 13 '17 at 16:56
  • Possible duplicate of [UnsupportedMethodException Android Studio 2.2](http://stackoverflow.com/questions/39675848/unsupportedmethodexception-android-studio-2-2) – Charuක Jan 13 '17 at 16:57
  • Possible duplicate of [Unsupported method: AndroidProject.getPluginGeneration() while running project](http://stackoverflow.com/questions/39591531/unsupported-method-androidproject-getplugingeneration-while-running-project) – Ilya Gazman Jan 13 '17 at 16:58
  • I GUESS THE PROJECT LOST – xxxman Jan 14 '17 at 18:08
  • https://cloud.seu.edu.cn/gitlab/frederickjoe/aosp-frameworks-base/blame/186fe7b10f475fdccb3bcab19461bd2900347b71/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/BridgeActionBar.java – xxxman Jan 14 '17 at 18:08
  • actionbar libs ,so the problem cause me trouble – xxxman Jan 14 '17 at 18:09

0 Answers0