Merged AppModule and AndroidModule.

This commit is contained in:
akwizgran
2016-04-05 14:16:42 +01:00
parent bbd14f1af4
commit dc1adc21ae
7 changed files with 31 additions and 56 deletions

View File

@@ -1,13 +1,13 @@
package org.briarproject.android;
import java.lang.Thread.UncaughtExceptionHandler;
import java.util.logging.Logger;
import android.app.Application;
import android.content.Context;
import org.briarproject.CoreModule;
import java.lang.Thread.UncaughtExceptionHandler;
import java.util.logging.Logger;
public class BriarApplication extends Application {
private static final Logger LOG =
@@ -18,7 +18,7 @@ public class BriarApplication extends Application {
@Override
public void onCreate() {
super.onCreate();
LOG.info("Application Created");
LOG.info("Created");
UncaughtExceptionHandler oldHandler =
Thread.getDefaultUncaughtExceptionHandler();
Context ctx = getApplicationContext();
@@ -26,8 +26,7 @@ public class BriarApplication extends Application {
Thread.setDefaultUncaughtExceptionHandler(newHandler);
applicationComponent = DaggerAndroidComponent.builder()
.appModule(new AppModule(this))
.androidModule(new AndroidModule())
.androidModule(new AndroidModule(this))
.build();
// We need to load the eager singletons directly after making the