Make TunnelManager the point of asynchronicity

Signed-off-by: Samuel Holland <samuel@sholland.org>
This commit is contained in:
Samuel Holland
2018-01-07 00:24:56 -06:00
parent 5a2f692d73
commit be8b6017d5
6 changed files with 125 additions and 154 deletions
@@ -81,17 +81,15 @@ public class Application extends android.app.Application {
@ApplicationScope
@Provides
public static Backend getBackend(final AsyncWorker asyncWorker,
@ApplicationContext final Context context,
public static Backend getBackend(@ApplicationContext final Context context,
final RootShell rootShell) {
return new WgQuickBackend(asyncWorker, context, rootShell);
return new WgQuickBackend(context, rootShell);
}
@ApplicationScope
@Provides
public static ConfigStore getConfigStore(final AsyncWorker asyncWorker,
@ApplicationContext final Context context) {
return new FileConfigStore(asyncWorker, context);
public static ConfigStore getConfigStore(@ApplicationContext final Context context) {
return new FileConfigStore(context);
}