Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Creating a screensaver in Android

Is it poosible to program a screensaver for a android (not lock screen)?

I am looking for a tutorial on programming a screen saver. The screen saver will activate as the user does nothing more. If the user touches the screen, the screensaver will disappear. Is this possible?

like image 432
goojr Avatar asked Oct 10 '22 08:10

goojr


1 Answers

You can receive ACTION_SCREEN_OFF in your App with a BroadcastReceiver.In the onReceive method of this BroadcastReceiver, start an activity as the screensaver.And you can register a listener for touch events and when this event occured,finish your App.

like image 158
hasanghaforian Avatar answered Oct 14 '22 01:10

hasanghaforian