mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2025-01-12 10:55:49 +01:00
remove unused getPrimaryActivity() from coodinators, mark Mi Band HRX as non-heartrate
This commit is contained in:
parent
67f4ab53fa
commit
495ba81edc
@ -123,15 +123,6 @@ public interface DeviceCoordinator {
|
|||||||
@Nullable
|
@Nullable
|
||||||
Class<? extends Activity> getPairingActivity();
|
Class<? extends Activity> getPairingActivity();
|
||||||
|
|
||||||
/**
|
|
||||||
* Returns the Activity class that will be used as the primary activity
|
|
||||||
* for the given device.
|
|
||||||
*
|
|
||||||
* @return the primary activity class, or null if none
|
|
||||||
*/
|
|
||||||
@Nullable
|
|
||||||
Class<? extends Activity> getPrimaryActivity();
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns true if activity data fetching is supported by the device
|
* Returns true if activity data fetching is supported by the device
|
||||||
* (with this coordinator).
|
* (with this coordinator).
|
||||||
|
@ -112,11 +112,6 @@ public class UnknownDeviceCoordinator extends AbstractDeviceCoordinator {
|
|||||||
return ControlCenterv2.class;
|
return ControlCenterv2.class;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public Class<? extends Activity> getPrimaryActivity() {
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public SampleProvider<?> getSampleProvider(GBDevice device, DaoSession session) {
|
public SampleProvider<?> getSampleProvider(GBDevice device, DaoSession session) {
|
||||||
return new UnknownSampleProvider();
|
return new UnknownSampleProvider();
|
||||||
|
@ -108,11 +108,6 @@ public class HPlusCoordinator extends AbstractDeviceCoordinator {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public Class<? extends Activity> getPrimaryActivity() {
|
|
||||||
return ChartsActivity.class;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public InstallHandler findInstallHandler(Uri uri, Context context) {
|
public InstallHandler findInstallHandler(Uri uri, Context context) {
|
||||||
return null;
|
return null;
|
||||||
|
@ -25,6 +25,7 @@ import org.slf4j.Logger;
|
|||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.InstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.devices.InstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
|
||||||
@ -50,4 +51,10 @@ public class MiBand2HRXCoordinator extends MiBand2Coordinator {
|
|||||||
public InstallHandler findInstallHandler(Uri uri, Context context) {
|
public InstallHandler findInstallHandler(Uri uri, Context context) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean supportsHeartRateMeasurement(GBDevice device) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -94,11 +94,6 @@ public class TeclastH30Coordinator extends AbstractDeviceCoordinator {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public Class<? extends Activity> getPrimaryActivity() {
|
|
||||||
return ChartsActivity.class;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public InstallHandler findInstallHandler(Uri uri, Context context) {
|
public InstallHandler findInstallHandler(Uri uri, Context context) {
|
||||||
return null;
|
return null;
|
||||||
|
@ -54,11 +54,6 @@ public class LiveviewCoordinator extends AbstractDeviceCoordinator {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public Class<? extends Activity> getPrimaryActivity() {
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public InstallHandler findInstallHandler(Uri uri, Context context) {
|
public InstallHandler findInstallHandler(Uri uri, Context context) {
|
||||||
return null;
|
return null;
|
||||||
|
@ -110,11 +110,6 @@ public class MiBandCoordinator extends AbstractDeviceCoordinator {
|
|||||||
return MiBandPairingActivity.class;
|
return MiBandPairingActivity.class;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public Class<? extends Activity> getPrimaryActivity() {
|
|
||||||
return ChartsActivity.class;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public SampleProvider<? extends AbstractActivitySample> getSampleProvider(GBDevice device, DaoSession session) {
|
public SampleProvider<? extends AbstractActivitySample> getSampleProvider(GBDevice device, DaoSession session) {
|
||||||
return new MiBandSampleProvider(device, session);
|
return new MiBandSampleProvider(device, session);
|
||||||
|
@ -82,12 +82,6 @@ public class No1F1Coordinator extends AbstractDeviceCoordinator {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Nullable
|
|
||||||
@Override
|
|
||||||
public Class<? extends Activity> getPrimaryActivity() {
|
|
||||||
return ChartsActivity.class;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean supportsActivityDataFetching() {
|
public boolean supportsActivityDataFetching() {
|
||||||
return true;
|
return true;
|
||||||
|
@ -66,11 +66,6 @@ public class PebbleCoordinator extends AbstractDeviceCoordinator {
|
|||||||
return PebblePairingActivity.class;
|
return PebblePairingActivity.class;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public Class<? extends Activity> getPrimaryActivity() {
|
|
||||||
return AppManagerActivity.class;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) throws GBException {
|
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) throws GBException {
|
||||||
Long deviceId = device.getId();
|
Long deviceId = device.getId();
|
||||||
|
@ -55,11 +55,6 @@ public class VibratissimoCoordinator extends AbstractDeviceCoordinator {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public Class<? extends Activity> getPrimaryActivity() {
|
|
||||||
return VibrationActivity.class;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public InstallHandler findInstallHandler(Uri uri, Context context) {
|
public InstallHandler findInstallHandler(Uri uri, Context context) {
|
||||||
return null;
|
return null;
|
||||||
|
Loading…
Reference in New Issue
Block a user