Skip to content
This repository has been archived by the owner on Apr 5, 2024. It is now read-only.

Commit

Permalink
add Log statements for schicking if bl is enabled
Browse files Browse the repository at this point in the history
  • Loading branch information
fabiberlin committed Feb 9, 2017
1 parent 7f3a014 commit 0db79c8
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ public class MainActivity extends AppCompatActivity
private Fragment dbTestFragment;
private Fragment testSuiteFragment;

private String TAG = getClass().getSimpleName();

public MainActivity() {

}
Expand Down Expand Up @@ -178,6 +180,8 @@ public void onDrawerStateChanged(int newState) {
this.mBluetoothAdapter = mBluetoothManager.getAdapter();

// ensure bluetooth is available and enabled
Log.d(TAG, "mBluetoothAdapter.isEnabled() " + mBluetoothAdapter.isEnabled());
Log.d(TAG, String.valueOf("mBluetoothAdapter == null " + mBluetoothAdapter == null));
if (mBluetoothAdapter == null || !mBluetoothAdapter.isEnabled()) {
Intent enableBtIntent = new Intent(BluetoothAdapter.ACTION_REQUEST_ENABLE);
startActivityForResult(enableBtIntent, REQUEST_ENABLE_BT);
Expand Down

0 comments on commit 0db79c8

Please sign in to comment.