Remove ToastController.
Wasn't meant to be submitted.
Change-Id: Icc94daaf47ed85cefb59f20928241ef38d5ee2ca
(cherry picked from commit 17047d19396b9c01dd7d3daf92ef327f1eafc650)
diff --git a/src/com/android/settings/SettingsActivity.java b/src/com/android/settings/SettingsActivity.java
index 066e26e..176ab7e 100644
--- a/src/com/android/settings/SettingsActivity.java
+++ b/src/com/android/settings/SettingsActivity.java
@@ -682,9 +682,6 @@
}
}
- // Will remove this line before submitting.
- FeatureFactory.getFactory(this).createToastController().makeToast(this);
-
if (DEBUG_TIMING) Log.d(LOG_TAG, "onCreate took " + (System.currentTimeMillis() - startTime)
+ " ms");
}
diff --git a/src/com/android/settings/overlay/FeatureFactory.java b/src/com/android/settings/overlay/FeatureFactory.java
index a5e779d..b0b2a3f 100644
--- a/src/com/android/settings/overlay/FeatureFactory.java
+++ b/src/com/android/settings/overlay/FeatureFactory.java
@@ -59,13 +59,7 @@
return sFactory;
}
- /**
- * Creates stub controller that makes {@link android.widget.Toast}s.
- * Will be removed before submitting.
- */
- public abstract ToastController createToastController();
-
- public static class FactoryNotFoundException extends RuntimeException {
+ public static final class FactoryNotFoundException extends RuntimeException {
public FactoryNotFoundException(Throwable throwable) {
super("Unable to create factory. Did you misconfigure Proguard?", throwable);
}
diff --git a/src/com/android/settings/overlay/FeatureFactoryImpl.java b/src/com/android/settings/overlay/FeatureFactoryImpl.java
index 4220bc0..036b4e7 100644
--- a/src/com/android/settings/overlay/FeatureFactoryImpl.java
+++ b/src/com/android/settings/overlay/FeatureFactoryImpl.java
@@ -16,20 +16,8 @@
package com.android.settings.overlay;
-import android.content.Context;
-import android.widget.Toast;
-
/**
* {@link FeatureFactory} implementation for AOSP Settings.
*/
public class FeatureFactoryImpl extends FeatureFactory {
- @Override
- public ToastController createToastController() {
- return new ToastController() {
- @Override
- public void makeToast(Context context) {
- Toast.makeText(context, "Here's a piece of AOSP toast", Toast.LENGTH_LONG).show();
- }
- };
- }
}
diff --git a/src/com/android/settings/overlay/ToastController.java b/src/com/android/settings/overlay/ToastController.java
deleted file mode 100644
index d009ce2..0000000
--- a/src/com/android/settings/overlay/ToastController.java
+++ /dev/null
@@ -1,10 +0,0 @@
-package com.android.settings.overlay;
-
-import android.content.Context;
-
-/**
- * Will be removed before submitting. Just a proof of concept for review.
- */
-public interface ToastController {
- void makeToast(Context context);
-}