Removing no-longer-necessary methods from the platform adapters.

This commit is contained in:
Rodrigo Damazio
2011-06-01 01:40:12 -03:00
parent 3e773ef94b
commit be096b9657
3 changed files with 1 additions and 22 deletions
@@ -19,7 +19,6 @@ import android.app.Notification;
import android.app.NotificationManager;
import android.app.Service;
import android.content.SharedPreferences;
import android.os.HandlerThread;
/**
* A set of methods that may be implemented in a platform specific way.
@@ -51,14 +50,6 @@ public interface ApiPlatformAdapter {
void stopForeground(Service service, NotificationManager notificationManager,
int id);
/**
* Terminates the given handler thread.
*
* @param handlerThread the thread to be terminated.
* @return true whether the handler has been stopped or not.
*/
boolean stopHandlerThread(HandlerThread handlerThread);
/**
* Applies all changes done to the given preferences editor.
* Changes may or may not be applied immediately.
@@ -16,11 +16,11 @@
package com.google.android.apps.mytracks.util;
import static com.google.android.apps.mytracks.Constants.TAG;
import android.app.Notification;
import android.app.NotificationManager;
import android.app.Service;
import android.content.SharedPreferences.Editor;
import android.os.HandlerThread;
import android.util.Log;
import java.lang.reflect.InvocationTargetException;
@@ -70,12 +70,6 @@ public class CupcakePlatformAdapter implements ApiPlatformAdapter {
}
}
@Override
public boolean stopHandlerThread(HandlerThread handlerThread) {
// Do nothing, as Cupcake doesn't provide quit().
return false;
}
@Override
public void applyPreferenceChanges(Editor editor) {
editor.commit();
@@ -19,7 +19,6 @@ import android.app.Notification;
import android.app.NotificationManager;
import android.app.Service;
import android.content.SharedPreferences.Editor;
import android.os.HandlerThread;
/**
* The Eclair (API level 5) specific implementation of the
@@ -42,11 +41,6 @@ public class EclairPlatformAdapter implements ApiPlatformAdapter {
service.stopForeground(id != -1);
}
@Override
public boolean stopHandlerThread(HandlerThread handlerThread) {
return handlerThread.quit();
}
@Override
public void applyPreferenceChanges(Editor editor) {
editor.commit();