Overlay an transparent image on screen

Put problem concerning Views, Layouts and other XML-Resources (like AndroidManifest) here.

Overlay an transparent image on screen

Postby florachan » Sun Jun 16, 2013 6:59 am

Hi Everyone ,

I am new here, I wanted to Overlay an transparent image on screen and still able to touch or interact
with the background. I found some code online but can't really understand.

I wonder if anyone can quickly write an example of "overlaying an transparent image on screen" by attaching
view to windowmanager?

Pointing me to correct direction or tutorial is fine too thanks

Regards
Flora



http://upshots.org/android/android-wind ... r-overlays

WindowManager.LayoutParams wlp = new WindowManager.LayoutParams();
wlp.gravity = Gravity.BOTTOM;
wlp.height = WindowManager.LayoutParams.WRAP_CONTENT;
wlp.width = WindowManager.LayoutParams.FILL_PARENT;
wlp.flags = WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON | WindowManager.LayoutParams.FLAG_LAYOUT_IN_SCREEN;
wlp.format = PixelFormat.RGBA_8888;

WindowManager wm = (WindowManager) getSystemService("window");
wm.addView(someView, wlp);
florachan
Freshman
Freshman
 
Posts: 2
Joined: Sun Jun 16, 2013 6:52 am

Top

Re: Overlay an transparent image on screen

Postby florachan » Sat Jun 22, 2013 8:17 am

anyone have any idea?
florachan
Freshman
Freshman
 
Posts: 2
Joined: Sun Jun 16, 2013 6:52 am

Top

Return to View, Layout & Resource Problems

Who is online

Users browsing this forum: No registered users and 4 guests