What I want to do:
1.Launch the application developed by myself.
2.Then the application will launch another designated app by clicking a certain button.
3.My application then keeps running in the background and only display a small floating window above all other windows.
4.By clicking the small floating window, my application will take a screenshot (programmatically) of the currently displayed window and save it to the external storage.
I've Googled around the internet, and found similar questions like this:
How to programmatically take a screenshot in Android?
Anyone knows if it's possible to do this kind of thing without Root privilege or if so how?
ADD: I may asked my question in the wrong way, actually I just want to know if it's possible to take a screenshot of the currently displayed window when my app is running in the background.