mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge.git
synced 2026-07-31 07:44:24 +02:00
fix to ensure targetCompatibility is effective for Android
PR #4735 inadvertently turned Android's targetCompatibility into Java's targetCompatibility thereby rendering it ineffective for Android. As a result Android used the toolchain version (17) instead of targetCompatibility 1.8 to create *.class files. See also: https://developer.android.com/build/jdks
This commit is contained in:
+2
-2
@@ -62,14 +62,14 @@ def getGitHashShort = { ->
|
||||
}
|
||||
|
||||
java {
|
||||
sourceCompatibility = JavaVersion.VERSION_1_8
|
||||
targetCompatibility = JavaVersion.VERSION_1_8
|
||||
toolchain.languageVersion = JavaLanguageVersion.of(17)
|
||||
}
|
||||
|
||||
android {
|
||||
compileOptions {
|
||||
coreLibraryDesugaringEnabled = true
|
||||
sourceCompatibility = JavaVersion.VERSION_1_8
|
||||
targetCompatibility = JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
namespace = 'nodomain.freeyourgadget.gadgetbridge'
|
||||
|
||||
+1
-1
@@ -72,7 +72,7 @@ public class UltrahumanDeviceCoordinator extends AbstractBLEDeviceCoordinator {
|
||||
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) throws GBException {
|
||||
final Long deviceId = device.getId();
|
||||
|
||||
final Map<AbstractDao<?, ?>, Property> daoMap = new HashMap<>() {{
|
||||
final Map<AbstractDao<?, ?>, Property> daoMap = new HashMap<AbstractDao<?,?>,Property>() {{
|
||||
put(session.getGenericHeartRateSampleDao(), GenericHeartRateSampleDao.Properties.DeviceId);
|
||||
put(session.getGenericHrvValueSampleDao(), GenericHrvValueSampleDao.Properties.DeviceId);
|
||||
put(session.getGenericSpo2SampleDao(), GenericSpo2SampleDao.Properties.DeviceId);
|
||||
|
||||
+1
-1
@@ -199,7 +199,7 @@ public class ZeppOsSupport extends HuamiSupport implements ZeppOsFileTransferSer
|
||||
private final ZeppOsStepsService stepsService = new ZeppOsStepsService(this);
|
||||
|
||||
private final Set<Short> mSupportedServices = new HashSet<>();
|
||||
private final Map<Short, AbstractZeppOsService> mServiceMap = new LinkedHashMap<>() {{
|
||||
private final Map<Short, AbstractZeppOsService> mServiceMap = new LinkedHashMap<Short, AbstractZeppOsService>() {{
|
||||
put(servicesService.getEndpoint(), servicesService);
|
||||
put(authenticationService.getEndpoint(), authenticationService);
|
||||
put(batteryService.getEndpoint(), batteryService);
|
||||
|
||||
Reference in New Issue
Block a user