@Test public void lockViewTest() { blurLayout.lockView(); }
public void lockView() { mViewLocked = true; if (mActivityView != null && mActivityView.get() != null) { View view = mActivityView.get().getRootView(); try { super.setAlpha(0f); mLockedBitmap = getDownscaledBitmapForView(view, new Rect(0, 0, view.getWidth(), view.getHeight()), mDownscaleFactor); if (Float.isNaN(mAlpha)) { super.setAlpha(1); } else { super.setAlpha(mAlpha); } mLockedBitmap = BlurKit.getInstance().blur(mLockedBitmap, mBlurRadius); } catch (Exception e) { } } }
BlurLayout extends FrameLayout { public void lockView() { mViewLocked = true; if (mActivityView != null && mActivityView.get() != null) { View view = mActivityView.get().getRootView(); try { super.setAlpha(0f); mLockedBitmap = getDownscaledBitmapForView(view, new Rect(0, 0, view.getWidth(), view.getHeight()), mDownscaleFactor); if (Float.isNaN(mAlpha)) { super.setAlpha(1); } else { super.setAlpha(mAlpha); } mLockedBitmap = BlurKit.getInstance().blur(mLockedBitmap, mBlurRadius); } catch (Exception e) { } } } }
BlurLayout extends FrameLayout { public void lockView() { mViewLocked = true; if (mActivityView != null && mActivityView.get() != null) { View view = mActivityView.get().getRootView(); try { super.setAlpha(0f); mLockedBitmap = getDownscaledBitmapForView(view, new Rect(0, 0, view.getWidth(), view.getHeight()), mDownscaleFactor); if (Float.isNaN(mAlpha)) { super.setAlpha(1); } else { super.setAlpha(mAlpha); } mLockedBitmap = BlurKit.getInstance().blur(mLockedBitmap, mBlurRadius); } catch (Exception e) { } } } BlurLayout(Context context);  BlurLayout(Context context, AttributeSet attrs); }
BlurLayout extends FrameLayout { public void lockView() { mViewLocked = true; if (mActivityView != null && mActivityView.get() != null) { View view = mActivityView.get().getRootView(); try { super.setAlpha(0f); mLockedBitmap = getDownscaledBitmapForView(view, new Rect(0, 0, view.getWidth(), view.getHeight()), mDownscaleFactor); if (Float.isNaN(mAlpha)) { super.setAlpha(1); } else { super.setAlpha(mAlpha); } mLockedBitmap = BlurKit.getInstance().blur(mLockedBitmap, mBlurRadius); } catch (Exception e) { } } } BlurLayout(Context context);  BlurLayout(Context context, AttributeSet attrs); void startBlur(); void pauseBlur(); @Override void invalidate(); void setDownscaleFactor(float downscaleFactor); float getDownscaleFactor(); void setBlurRadius(int blurRadius); int getBlurRadius(); void setFPS(int fps); int getFPS(); void setCornerRadius(float cornerRadius); float getCornerRadius(); void setAlpha(float alpha); float getAlpha(); void lockView(); void unlockView(); boolean getViewLocked(); void lockPosition(); void unlockPosition(); boolean getPositionLocked(); }
BlurLayout extends FrameLayout { public void lockView() { mViewLocked = true; if (mActivityView != null && mActivityView.get() != null) { View view = mActivityView.get().getRootView(); try { super.setAlpha(0f); mLockedBitmap = getDownscaledBitmapForView(view, new Rect(0, 0, view.getWidth(), view.getHeight()), mDownscaleFactor); if (Float.isNaN(mAlpha)) { super.setAlpha(1); } else { super.setAlpha(mAlpha); } mLockedBitmap = BlurKit.getInstance().blur(mLockedBitmap, mBlurRadius); } catch (Exception e) { } } } BlurLayout(Context context);  BlurLayout(Context context, AttributeSet attrs); void startBlur(); void pauseBlur(); @Override void invalidate(); void setDownscaleFactor(float downscaleFactor); float getDownscaleFactor(); void setBlurRadius(int blurRadius); int getBlurRadius(); void setFPS(int fps); int getFPS(); void setCornerRadius(float cornerRadius); float getCornerRadius(); void setAlpha(float alpha); float getAlpha(); void lockView(); void unlockView(); boolean getViewLocked(); void lockPosition(); void unlockPosition(); boolean getPositionLocked(); static final float DEFAULT_DOWNSCALE_FACTOR; static final int DEFAULT_BLUR_RADIUS; static final int DEFAULT_FPS; static final float DEFAULT_CORNER_RADIUS; static final float DEFAULT_ALPHA; }