mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2025-01-26 17:47:34 +01:00
Pebble: if untested features option is enabled use Gadgetbridge sample provider insted of Morpheuz
This commit is contained in:
parent
5884684cad
commit
0be251e83d
@ -2,22 +2,30 @@ package nodomain.freeyourgadget.gadgetbridge.devices.pebble;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.content.Context;
|
||||
import android.content.SharedPreferences;
|
||||
import android.net.Uri;
|
||||
import android.preference.PreferenceManager;
|
||||
|
||||
import nodomain.freeyourgadget.gadgetbridge.GBApplication;
|
||||
import nodomain.freeyourgadget.gadgetbridge.activities.AppManagerActivity;
|
||||
import nodomain.freeyourgadget.gadgetbridge.devices.DeviceCoordinator;
|
||||
import nodomain.freeyourgadget.gadgetbridge.devices.InstallHandler;
|
||||
import nodomain.freeyourgadget.gadgetbridge.devices.SampleProvider;
|
||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||
import nodomain.freeyourgadget.gadgetbridge.devices.SampleProvider;
|
||||
|
||||
public class PebbleCoordinator implements DeviceCoordinator {
|
||||
private MorpheuzSampleProvider sampleProvider;
|
||||
|
||||
public PebbleCoordinator() {
|
||||
//sampleProvider = new MorpheuzSampleProvider();
|
||||
sampleProvider = new PebbleGadgetBridgeSampleProvider();
|
||||
// FIXME: make this configurable somewhere else
|
||||
SharedPreferences sharedPrefs = PreferenceManager.getDefaultSharedPreferences(GBApplication.getContext());
|
||||
if (sharedPrefs.getBoolean("pebble_force_untested", false)) {
|
||||
sampleProvider = new PebbleGadgetBridgeSampleProvider();
|
||||
} else {
|
||||
sampleProvider = new MorpheuzSampleProvider();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Loading…
x
Reference in New Issue
Block a user