List of usage examples for android.graphics NinePatch isNinePatchChunk
public native static boolean isNinePatchChunk(byte[] chunk);
From source file:com.example.image.ImageWorker.java
protected Drawable getLoadingDrawable() { byte[] chunk = mLoadingBitmap.getNinePatchChunk(); if (NinePatch.isNinePatchChunk(chunk)) { return new NinePatchDrawable(mResources, mLoadingBitmap, chunk, new Rect(), null); } else {/*from w w w .j a va 2 s . c o m*/ return new BitmapDrawable(mResources, mLoadingBitmap); } }