Skip to content

Latest commit

 

History

History
67 lines (50 loc) · 1.46 KB

README.md

File metadata and controls

67 lines (50 loc) · 1.46 KB

Watcher

Build Status

Installation

Step 1. Add the JitPack repository to your build file

Add it in your root build.gradle at the end of repositories:

allprojects {
	repositories {
		...
		maven { url 'https://jitpack.io' }
	}
}

Step 2. Add the dependency

dependencies {
	compile 'com.github.xcc3641:watcher:1.0'
}

Usage

Step 1. Add the WatcherService in your AndroidManifest

<service android:name="com.hugo.watcher.WatcherService"/>

Step 2. Start the Watcher

In your Application onCreate :

@Override
public void onCreate() {
	super.onCreate();
	// default
	Watcher.getInstance().start(this);
}

Update at 17.4.22

Watcher has used TYPE_PHONE instead of TYPE_TOAST . Make sure enable "Draw over other apps permission".

Prevent apps to overlay other apps via toast windows

More configuration

// custom
WatcherConfig watcherConfig = new WatcherConfig();
watcherConfig.enableFps = false;
// ....
Watcher.getInstance().setWatcherConfig(watcherConfig).start(this);

Step 3. Enjoy it

The Watcher will stop itself back to the background