![]() |
Trottinette Électrique Connectée
0.8
BTS SN-IR La Salle Avignon 2018
|
Fonctions membres publiques | |
ReceveurBluetooth () | |
void | onReceive (Context context, Intent intent) |
Created by iris on 22/03/18.
void com.example.iris.myapplication.ReceveurBluetooth.onReceive | ( | Context | context, |
Intent | intent | ||
) |
{ String action = intent.getAction(); if (BluetoothDevice.ACTION_FOUND.equals(action)) { BluetoothDevice device = intent.getParcelableExtra(BluetoothDevice.EXTRA_DEVICE); Toast.makeText(context, "Nouveau périphérique : " + device.getName(), Toast.LENGTH_SHORT).show(); } }