mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2024-11-05 17:57:03 +01:00
removed Toast.makeText
This commit is contained in:
parent
f4d484f698
commit
32a2402048
@ -70,6 +70,7 @@ import nodomain.freeyourgadget.gadgetbridge.service.devices.qhybrid.requests.Set
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.qhybrid.requests.SetVibrationStrengthRequest;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.qhybrid.requests.SetVibrationStrengthRequest;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.qhybrid.requests.UploadFileRequest;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.qhybrid.requests.UploadFileRequest;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.qhybrid.requests.VibrateRequest;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.qhybrid.requests.VibrateRequest;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.util.GB;
|
||||||
|
|
||||||
public class QHybridSupport extends QHybridBaseSupport {
|
public class QHybridSupport extends QHybridBaseSupport {
|
||||||
public static final String QHYBRID_COMMAND_CONTROL = "qhybrid_command_control";
|
public static final String QHYBRID_COMMAND_CONTROL = "qhybrid_command_control";
|
||||||
@ -250,11 +251,11 @@ public class QHybridSupport extends QHybridBaseSupport {
|
|||||||
public void onFindDevice(boolean start) {
|
public void onFindDevice(boolean start) {
|
||||||
try {
|
try {
|
||||||
if (start && !supportsExtendedVibration()) {
|
if (start && !supportsExtendedVibration()) {
|
||||||
Toast.makeText(getContext(), "Device does not support brr brr", Toast.LENGTH_SHORT).show();
|
GB.toast("Device does not support brr brr", Toast.LENGTH_SHORT, GB.INFO);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}catch (UnsupportedOperationException e){
|
}catch (UnsupportedOperationException e){
|
||||||
Toast.makeText(getContext(), "Please contact dakhnod@gmail.com\n" + modelNumber, Toast.LENGTH_SHORT).show();
|
GB.toast("Please contact dakhnod@gmail.com\n", Toast.LENGTH_SHORT, GB.INFO);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (start && searchDevice) return;
|
if (start && searchDevice) return;
|
||||||
@ -351,12 +352,7 @@ public class QHybridSupport extends QHybridBaseSupport {
|
|||||||
try {
|
try {
|
||||||
gbDevice.addDeviceInfo(new GenericItem(ITEM_EXTENDED_VIBRATION_SUPPORT, String.valueOf(supportsExtendedVibration())));
|
gbDevice.addDeviceInfo(new GenericItem(ITEM_EXTENDED_VIBRATION_SUPPORT, String.valueOf(supportsExtendedVibration())));
|
||||||
}catch (UnsupportedOperationException e){
|
}catch (UnsupportedOperationException e){
|
||||||
new Handler(Looper.getMainLooper()).post(new Runnable() {
|
GB.toast("Please contact dakhnod@gmail.com\n", Toast.LENGTH_SHORT, GB.INFO);
|
||||||
@Override
|
|
||||||
public void run() {
|
|
||||||
Toast.makeText(getContext(), "Please contact dakhnod@gmail.com\n" + modelNumber, Toast.LENGTH_SHORT).show();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
gbDevice.addDeviceInfo(new GenericItem(ITEM_EXTENDED_VIBRATION_SUPPORT, String.valueOf(supportsExtendedVibration())));
|
gbDevice.addDeviceInfo(new GenericItem(ITEM_EXTENDED_VIBRATION_SUPPORT, String.valueOf(supportsExtendedVibration())));
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user