Why does Android Drawable Importer ignore selection in AS 3.5 onwards

℡╲_俬逩灬. 提交于 2020-02-26 03:42:38

问题


After right-click --> new Batch Drawable Import and selecting any .png from the Select Image Asset(s) box, the primary Batch Drawable Importer box remains empty (ie: the selection was ignored!).

First 2 lines of Event Log:

java.lang.NoSuchMethodError: org.jetbrains.android.facet.AndroidFacet.getAllResourceDirectories()Ljava/util/List;
    at de.mprengemann.intellij.plugin.androidicons.util.AndroidFacetUtils.getResourcesRoot(AndroidFacetUtils.java:48)

So apparently Android Drawable Importer is fundamentally broken under the more recent AS / intellij versions.

I downloaded and re-installed android-drawable-importer-intellij-plugin-0.5-81.zip to no effect. This plugin was last built in 2016.

This leaves me stuck, because the new Android Studio Resource Manager Import Drawables function does not allow me to pick an external 256x256 .png and then automatically resize for mdpi, hdpi, xdhpi etc.

I have noted the issue (see comment).

Any circumventions or alternatives?


回答1:


There were multiple issues preventing operation of this plugin in later releases of Android Studio.

Forked, fixed and tested under Android Studio 3.6 RC 1.

Guinea pigs may download the plugin installation zip from here.

( AS -> Settings -> Plugins -> Install from disk )



来源:https://stackoverflow.com/questions/59871334/why-does-android-drawable-importer-ignore-selection-in-as-3-5-onwards

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!