Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
jamorham committed Jun 11, 2024
2 parents 4bda343 + 8309dae commit 1958827
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 6 deletions.
10 changes: 10 additions & 0 deletions app/proguard-rules.pro
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,16 @@
-keep class android.support.v7.widget.SearchView { *; }
-keep class kotlinx.serialization.Serializable { *; }

# As long as we only deserialize (from a JSON string into an `NSDeviceStatus`
# object in the class `AAPSStatusHandler`) we can simply ignore warnings related
# to kotlinx serialization.
# These rule should not cause problems: if a project actually relies on
# serialization, then much more than just this class will be required,
# so telling Proguard not to worry if this is missing will not prevent it
# from emitting errors for code that does use serialization but somehow forgot
# to depend on it.
-dontwarn kotlinx.serialization.Serializable

-dontwarn java.util.concurrent.**

-keep class rx.schedulers.Schedulers {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public enum CalibrationState {

private static final SparseArray<CalibrationState> lookup = new SparseArray<>();
private static final ImmutableSet<CalibrationState> failed = ImmutableSet.of(SensorFailed, SensorFailed2, SensorFailed3, SensorFailed4, SensorFailed5, SensorFailed6, SensorFailedStart);
private static final ImmutableSet<CalibrationState> stopped = ImmutableSet.of(Stopped, Ended, SensorFailed, SensorFailed2, SensorFailed3, SensorFailed4, SensorFailed5, SensorFailed6, SensorFailedStart, SensorStopped);
private static final ImmutableSet<CalibrationState> stopped = ImmutableSet.of(Stopped, Ended, SensorExpired, SensorFailed, SensorFailed2, SensorFailed3, SensorFailed4, SensorFailed5, SensorFailed6, SensorFailedStart, SensorStopped);
private static final ImmutableSet<CalibrationState> transitional = ImmutableSet.of(WarmingUp, SensorStarted, SensorStopped, CalibrationSent);


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -303,6 +303,7 @@ public static SensorType getSensorType(byte[] SensorInfo) {
return SensorType.LibreUS14Day;
case 0x9d0830:
case 0xc50930:
case 0xc60931:
return SensorType.Libre2;
case 0x700010:
return SensorType.LibreProH;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1153,7 +1153,7 @@ public int onStartCommand(Intent intent, int flags, int startId) {
}

minimize_scanning = Pref.getBooleanDefaultFalse("ob1_minimize_scanning");
// allow_scan_by_mac = Build.VERSION.SDK_INT >= 32 && shortTxId();
// allow_scan_by_mac = Build.VERSION.SDK_INT >= 32 && shortTxId();
automata(); // sequence logic

UserError.Log.d(TAG, "Releasing service start");
Expand Down
6 changes: 2 additions & 4 deletions app/src/main/res/layout/activity_home.xml
Original file line number Diff line number Diff line change
Expand Up @@ -540,21 +540,19 @@

<TextView
android:id="@+id/nanoStatusText"
android:layout_width="0dp"
android:layout_width="wrap_content"
android:layout_marginTop="2dp"
android:layout_marginStart="5dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@{nano.color_watch, default=`Nano Status`}"
app:showIfTrue="@{nano.color_watch.length() > 0}"/>

<TextView
android:id="@+id/ExpiryStatusText"
android:layout_width="0dp"
android:layout_width="wrap_content"
android:layout_marginTop="2dp"
android:layout_marginStart="5dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@{expiry.color_watch, default=`Expiry Status`}"
app:showIfTrue="@{(safeUnbox(vs.included[`sensor_expiry`])) &amp;&amp; (expiry.color_watch.length() > 0)}"/>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -303,6 +303,7 @@ public static SensorType getSensorType(byte[] SensorInfo) {
return SensorType.LibreUS14Day;
case 0x9d0830:
case 0xc50930:
case 0xc60931:
return SensorType.Libre2;
case 0x700010:
return SensorType.LibreProH;
Expand Down

0 comments on commit 1958827

Please sign in to comment.