From a930b6831d0c70b6c5d34e548e6b1dceaa6529a0 Mon Sep 17 00:00:00 2001 From: Mohammad Shamsi Date: Tue, 2 Nov 2010 01:04:20 +0800 Subject: code cleanup. unused imports, local variabls and static constans removed from com.android.bluetooth.opp package. Change-Id: I0fd682a190221e216fac71723c05d3828b9fa42d --- src/com/android/bluetooth/opp/BluetoothOppBatch.java | 1 - src/com/android/bluetooth/opp/BluetoothOppManager.java | 1 - src/com/android/bluetooth/opp/BluetoothOppNotification.java | 1 - src/com/android/bluetooth/opp/BluetoothOppPreference.java | 1 - src/com/android/bluetooth/opp/BluetoothOppReceiver.java | 1 - src/com/android/bluetooth/opp/BluetoothOppRfcommListener.java | 2 -- src/com/android/bluetooth/opp/BluetoothOppSendFileInfo.java | 1 - src/com/android/bluetooth/opp/BluetoothOppService.java | 4 +--- src/com/android/bluetooth/opp/BluetoothOppTransfer.java | 6 ------ src/com/android/bluetooth/opp/BluetoothOppTransferActivity.java | 1 - src/com/android/bluetooth/opp/BluetoothOppTransferHistory.java | 4 +--- src/com/android/bluetooth/opp/TestActivity.java | 2 -- 12 files changed, 2 insertions(+), 23 deletions(-) diff --git a/src/com/android/bluetooth/opp/BluetoothOppBatch.java b/src/com/android/bluetooth/opp/BluetoothOppBatch.java index 5913b4cb3..7f51fe21a 100644 --- a/src/com/android/bluetooth/opp/BluetoothOppBatch.java +++ b/src/com/android/bluetooth/opp/BluetoothOppBatch.java @@ -61,7 +61,6 @@ import com.google.android.collect.Lists; public class BluetoothOppBatch { private static final String TAG = "BtOppBatch"; - private static final boolean D = Constants.DEBUG; private static final boolean V = Constants.VERBOSE; public int mId; diff --git a/src/com/android/bluetooth/opp/BluetoothOppManager.java b/src/com/android/bluetooth/opp/BluetoothOppManager.java index 73411d926..8fdab0452 100644 --- a/src/com/android/bluetooth/opp/BluetoothOppManager.java +++ b/src/com/android/bluetooth/opp/BluetoothOppManager.java @@ -55,7 +55,6 @@ import java.util.ArrayList; */ public class BluetoothOppManager { private static final String TAG = "BluetoothOppManager"; - private static final boolean D = Constants.DEBUG; private static final boolean V = Constants.VERBOSE; private static BluetoothOppManager INSTANCE; diff --git a/src/com/android/bluetooth/opp/BluetoothOppNotification.java b/src/com/android/bluetooth/opp/BluetoothOppNotification.java index 310a289a5..ed0d40220 100644 --- a/src/com/android/bluetooth/opp/BluetoothOppNotification.java +++ b/src/com/android/bluetooth/opp/BluetoothOppNotification.java @@ -53,7 +53,6 @@ import java.util.HashMap; */ class BluetoothOppNotification { private static final String TAG = "BluetoothOppNotification"; - private static final boolean D = Constants.DEBUG; private static final boolean V = Constants.VERBOSE; static final String status = "(" + BluetoothShare.STATUS + " == '192'" + ")"; diff --git a/src/com/android/bluetooth/opp/BluetoothOppPreference.java b/src/com/android/bluetooth/opp/BluetoothOppPreference.java index 787422293..8e7b7ebfb 100644 --- a/src/com/android/bluetooth/opp/BluetoothOppPreference.java +++ b/src/com/android/bluetooth/opp/BluetoothOppPreference.java @@ -46,7 +46,6 @@ import android.util.Log; */ public class BluetoothOppPreference { private static final String TAG = "BluetoothOppPreference"; - private static final boolean D = Constants.DEBUG; private static final boolean V = Constants.VERBOSE; private static BluetoothOppPreference INSTANCE; diff --git a/src/com/android/bluetooth/opp/BluetoothOppReceiver.java b/src/com/android/bluetooth/opp/BluetoothOppReceiver.java index 98800d477..436100728 100644 --- a/src/com/android/bluetooth/opp/BluetoothOppReceiver.java +++ b/src/com/android/bluetooth/opp/BluetoothOppReceiver.java @@ -54,7 +54,6 @@ import android.widget.Toast; */ public class BluetoothOppReceiver extends BroadcastReceiver { private static final String TAG = "BluetoothOppReceiver"; - private static final boolean D = Constants.DEBUG; private static final boolean V = Constants.VERBOSE; @Override diff --git a/src/com/android/bluetooth/opp/BluetoothOppRfcommListener.java b/src/com/android/bluetooth/opp/BluetoothOppRfcommListener.java index c33cb66dc..9d9fa18b3 100644 --- a/src/com/android/bluetooth/opp/BluetoothOppRfcommListener.java +++ b/src/com/android/bluetooth/opp/BluetoothOppRfcommListener.java @@ -49,8 +49,6 @@ import android.util.Log; public class BluetoothOppRfcommListener { private static final String TAG = "BtOppRfcommListener"; - private static final boolean D = Constants.DEBUG; - private static final boolean V = Constants.VERBOSE; public static final int MSG_INCOMING_BTOPP_CONNECTION = 100; diff --git a/src/com/android/bluetooth/opp/BluetoothOppSendFileInfo.java b/src/com/android/bluetooth/opp/BluetoothOppSendFileInfo.java index 44ca9bdd4..a9d0578d0 100644 --- a/src/com/android/bluetooth/opp/BluetoothOppSendFileInfo.java +++ b/src/com/android/bluetooth/opp/BluetoothOppSendFileInfo.java @@ -43,7 +43,6 @@ import android.content.Context; import android.database.Cursor; import android.net.Uri; import android.provider.OpenableColumns; -import android.provider.ContactsContract.Contacts; /** * This class stores information about a single sending file It will only be diff --git a/src/com/android/bluetooth/opp/BluetoothOppService.java b/src/com/android/bluetooth/opp/BluetoothOppService.java index 51b282c9f..02bc5d588 100644 --- a/src/com/android/bluetooth/opp/BluetoothOppService.java +++ b/src/com/android/bluetooth/opp/BluetoothOppService.java @@ -37,9 +37,7 @@ import javax.obex.ObexTransport; import android.app.Service; import android.bluetooth.BluetoothAdapter; -import android.bluetooth.BluetoothDevice; import android.content.BroadcastReceiver; -import android.content.ContentUris; import android.content.ContentValues; import android.content.Context; import android.content.Intent; @@ -263,7 +261,7 @@ public class BluetoothOppService extends Service { } catch (IOException e) { Log.e(TAG, "close tranport error"); } - } else if (Constants.USE_TCP_DEBUG && !Constants.USE_TCP_SIMPLE_SERVER){ + } else if (Constants.USE_TCP_DEBUG && !Constants.USE_TCP_SIMPLE_SERVER) { Log.i(TAG, "Start Obex Server in TCP DEBUG mode"); createServerSession(transport); } else { diff --git a/src/com/android/bluetooth/opp/BluetoothOppTransfer.java b/src/com/android/bluetooth/opp/BluetoothOppTransfer.java index d892e70dc..3b763519f 100644 --- a/src/com/android/bluetooth/opp/BluetoothOppTransfer.java +++ b/src/com/android/bluetooth/opp/BluetoothOppTransfer.java @@ -100,18 +100,12 @@ public class BluetoothOppTransfer implements BluetoothOppBatch.BluetoothOppBatch private EventHandler mSessionHandler; - /* - * TODO check if we need PowerManager here - */ - private PowerManager mPowerManager; - private long mTimestamp; public BluetoothOppTransfer(Context context, PowerManager powerManager, BluetoothOppBatch batch, BluetoothOppObexSession session) { mContext = context; - mPowerManager = powerManager; mBatch = batch; mSession = session; diff --git a/src/com/android/bluetooth/opp/BluetoothOppTransferActivity.java b/src/com/android/bluetooth/opp/BluetoothOppTransferActivity.java index d63a6faa4..e36df0bcd 100644 --- a/src/com/android/bluetooth/opp/BluetoothOppTransferActivity.java +++ b/src/com/android/bluetooth/opp/BluetoothOppTransferActivity.java @@ -36,7 +36,6 @@ import com.android.bluetooth.R; import android.bluetooth.BluetoothAdapter; import android.bluetooth.BluetoothDevice; -import android.content.Context; import android.content.DialogInterface; import android.content.Intent; import android.net.Uri; diff --git a/src/com/android/bluetooth/opp/BluetoothOppTransferHistory.java b/src/com/android/bluetooth/opp/BluetoothOppTransferHistory.java index 1f5d9d984..767954428 100644 --- a/src/com/android/bluetooth/opp/BluetoothOppTransferHistory.java +++ b/src/com/android/bluetooth/opp/BluetoothOppTransferHistory.java @@ -62,8 +62,6 @@ public class BluetoothOppTransferHistory extends Activity implements View.OnCreateContextMenuListener, OnItemClickListener { private static final String TAG = "BluetoothOppTransferHistory"; - private static final boolean D = Constants.DEBUG; - private static final boolean V = Constants.VERBOSE; private ListView mListView; @@ -242,7 +240,7 @@ public class BluetoothOppTransferHistory extends Activity implements * android.widget.AdapterView.OnItemClickListener#onItemClick(android.widget * .AdapterView, android.view.View, int, long) */ - public void onItemClick(AdapterView parent, View view, int position, long id) { + public void onItemClick(AdapterView parent, View view, int position, long id) { // Open the selected item mTransferCursor.moveToPosition(position); openCompleteTransfer(); diff --git a/src/com/android/bluetooth/opp/TestActivity.java b/src/com/android/bluetooth/opp/TestActivity.java index 4266f6850..ed8226b65 100644 --- a/src/com/android/bluetooth/opp/TestActivity.java +++ b/src/com/android/bluetooth/opp/TestActivity.java @@ -455,8 +455,6 @@ class TestTcpListener { class TestTcpServer extends ServerRequestHandler implements Runnable { private static final String TAG = "ServerRequestHandler"; - private static final boolean D = Constants.DEBUG; - private static final boolean V = Constants.VERBOSE; static final int port = 6500; -- cgit v1.2.3