예제 #1
0
 /** tost一个message */
 private void toastMessage(String message) {
   try {
     ToastUtils.toast(this, message);
   } catch (Exception e) {
     LogUtils.e(tag, "toast message error");
   }
 }
예제 #2
0
 /** 判断蓝牙是否打开 */
 public boolean isBlueToothEnable() {
   if (isBlueToothSupport()) {
     return BluetoothAdapter.getDefaultAdapter().isEnabled();
   } else {
     ToastUtils.toast(context, context.getString(R.string.not_support_bluetooth));
     return false;
   }
 }