How to fix "Organize Imports" in Android Studio for static imports

Viewed 13015

I'm using version 0.3.7 of Android Studio, and I'm trying out OpenGL ES programming. This requires a lot of imports from such classes as "android.opengl.GLES20"

Instead of auto importing GLES20 and accessing for example, the GL_COMPILE_STATUS variable like so:

glGetShaderiv(shaderObjectID, GLES20.GL_COMPILE_STATUS, compileStatus, 0);

I'd rather type in GL_COMPILE_STATUS and have it auto import the following:

import static android.opengl.GLES20.GL_COMPILE_STATUS;
...
glGetShaderiv(shaderObjectID, GL_COMPILE_STATUS, compileStatus, 0);

And have the above import found as I type in GL_COMPILE_STATUS.

But the current system will not know that GL_COMPILE_STATUS comes from the GLES20 class. So my question is this, is there a way to assist the organize imports functionality in Android Studio for finding these variable? I'd like to keep my code to a minimum, and having to write GLES20. in front of everything is a little off putting - and I won't use a wildcard import as I consider that bad practice.

1 Answers
Related