android - Blur Background when fragment Show and when API < 23? -


is way blur background when fragment show?
every ways tried.
when called getforeground in:

(container.getforeground().setalpha(5)).. 

it show me error under (getforeground)

(must api >=23)

and application minsdkversion = 14

any way implement method or class blur background when sdk < 23 or when sdk = 14?

you can try using getforeground() method within framelayout:

container = (framelayout) findviewbyid( r.id.container);  container.getforeground().setalpha(5); // 0 (opaque) -> 255 (invisible) 

or using view.setalpha(float):

your_view_name.setalpha(0.5); // 0 (transparent) -> 1 (opaque) 

Comments

Popular posts from this blog

angular - Ionic slides - dynamically add slides before and after -

minify - Minimizing css files -

Add a dynamic header in angular 2 http provider -