Im trying to figure out how apps like swipe pad (https://market.android.com/details?id=mobi.conduction.swipepad.android) can hook guestures regardless of what window/app is on top, and how its able to draw and interact without stopping the background apps below it.
I have been able to create apps like dialogs and popup windows, but i cannot get them to show without stopping/freezing the background application.
UPDATE: found a suitable solution.
in your service's onCreate add this
WindowManager.LayoutParams params = new WindowManager.LayoutParams(
WindowManager.LayoutParams.WRAP_CONTENT,
WindowManager.LayoutParams.WRAP_CONTENT,
WindowManager.LayoutParams.TYPE_SYSTEM_ALERT,
WindowManager.LayoutParams.FLAG_NOT_TOUCH_MODAL|WindowManager.LayoutParams.FLAG_NOT_FOCUSABLE,
PixelFormat.TRANSLUCENT);
params.setTitle("title");
WindowManager wm = (WindowManager) getSystemService(WINDOW_SERVICE);
wm.addView(layout, params);
touch events are handled just like regular except when you dont touch an element of the services gui, then the service doesnt read the touch and its dropped through to the underlying program