1
1
Submodule Loop contains modified content
2
- Submodule Loop 0258326..f083293 :
2
+ Submodule Loop 36617b2..98e221e :
3
3
diff --git a/Loop/Loop.xcodeproj/project.pbxproj b/Loop/Loop.xcodeproj/project.pbxproj
4
- index ba7f9464..b2efab9c 100644
4
+ index 9c95453a..5f46c3d4 100644
5
5
--- a/Loop/Loop.xcodeproj/project.pbxproj
6
6
+++ b/Loop/Loop.xcodeproj/project.pbxproj
7
- @@ -520,6 +520,10 @@
7
+ @@ -517,6 +517,11 @@
8
+ C1FB428D21791D2500FAB378 /* PumpManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = 43C3B6F620BBCAA30026CAFA /* PumpManager.swift */; };
9
+ C1FB428F217921D600FAB378 /* PumpManagerUI.swift in Sources */ = {isa = PBXBuildFile; fileRef = C1FB428E217921D600FAB378 /* PumpManagerUI.swift */; };
8
10
C1FB4290217922A100FAB378 /* PumpManagerUI.swift in Sources */ = {isa = PBXBuildFile; fileRef = C1FB428E217921D600FAB378 /* PumpManagerUI.swift */; };
9
- DD3DBD272A33AEC8000F8B5B /* SettingsView+algorithmExperimentsSection.swift in Sources */ = {isa = PBXBuildFile; fileRef = DD3DBD262A33AEC8000F8B5B /* SettingsView+algorithmExperimentsSection.swift */; };
10
- DD3DBD292A33AFE9000F8B5B /* IntegralRetrospectiveCorrectionSelectionView.swift in Sources */ = {isa = PBXBuildFile; fileRef = DD3DBD282A33AFE9000F8B5B /* IntegralRetrospectiveCorrectionSelectionView.swift */; };
11
11
+ DDC389F62A2B61750066E2E8 /* ApplicationFactorStrategy.swift in Sources */ = {isa = PBXBuildFile; fileRef = DDC389F52A2B61750066E2E8 /* ApplicationFactorStrategy.swift */; };
12
12
+ DDC389F82A2B620B0066E2E8 /* GlucoseBasedApplicationFactorStrategy.swift in Sources */ = {isa = PBXBuildFile; fileRef = DDC389F72A2B620B0066E2E8 /* GlucoseBasedApplicationFactorStrategy.swift */; };
13
13
+ DDC389FA2A2B62470066E2E8 /* ConstantDosingStrategy.swift in Sources */ = {isa = PBXBuildFile; fileRef = DDC389F92A2B62470066E2E8 /* ConstantDosingStrategy.swift */; };
14
+ + DDC389FC2A2BC6670066E2E8 /* SettingsView+algorithmExperimentsSection.swift in Sources */ = {isa = PBXBuildFile; fileRef = DDC389FB2A2BC6670066E2E8 /* SettingsView+algorithmExperimentsSection.swift */; };
14
15
+ DDC389FE2A2C4C830066E2E8 /* GlucoseBasedApplicationFactorSelectionView.swift in Sources */ = {isa = PBXBuildFile; fileRef = DDC389FD2A2C4C830066E2E8 /* GlucoseBasedApplicationFactorSelectionView.swift */; };
15
16
E90909D124E34AC500F963D2 /* high_and_rising_with_cob_momentum_effect.json in Resources */ = {isa = PBXBuildFile; fileRef = E90909CC24E34AC500F963D2 /* high_and_rising_with_cob_momentum_effect.json */; };
16
17
E90909D224E34AC500F963D2 /* high_and_rising_with_cob_insulin_effect.json in Resources */ = {isa = PBXBuildFile; fileRef = E90909CD24E34AC500F963D2 /* high_and_rising_with_cob_insulin_effect.json */; };
17
18
E90909D324E34AC500F963D2 /* high_and_rising_with_cob_predicted_glucose.json in Resources */ = {isa = PBXBuildFile; fileRef = E90909CE24E34AC500F963D2 /* high_and_rising_with_cob_predicted_glucose.json */; };
18
- @@ -1691,6 +1695,10 @@
19
+ @@ -1685,6 +1690,11 @@
20
+ C1FF3D4B29C786A900BDC1EC /* he */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = he; path = he.lproj/Localizable.strings; sourceTree = "<group>"; };
21
+ C1FF3D4C29C786A900BDC1EC /* he */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = he; path = he.lproj/Localizable.strings; sourceTree = "<group>"; };
19
22
C1FF3D4D29C786A900BDC1EC /* he */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = he; path = he.lproj/InfoPlist.strings; sourceTree = "<group>"; };
20
- DD3DBD262A33AEC8000F8B5B /* SettingsView+algorithmExperimentsSection.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "SettingsView+algorithmExperimentsSection.swift"; sourceTree = "<group>"; };
21
- DD3DBD282A33AFE9000F8B5B /* IntegralRetrospectiveCorrectionSelectionView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = IntegralRetrospectiveCorrectionSelectionView.swift; sourceTree = "<group>"; };
22
23
+ DDC389F52A2B61750066E2E8 /* ApplicationFactorStrategy.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ApplicationFactorStrategy.swift; sourceTree = "<group>"; };
23
24
+ DDC389F72A2B620B0066E2E8 /* GlucoseBasedApplicationFactorStrategy.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GlucoseBasedApplicationFactorStrategy.swift; sourceTree = "<group>"; };
24
25
+ DDC389F92A2B62470066E2E8 /* ConstantDosingStrategy.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ConstantDosingStrategy.swift; sourceTree = "<group>"; };
26
+ + DDC389FB2A2BC6670066E2E8 /* SettingsView+algorithmExperimentsSection.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "SettingsView+algorithmExperimentsSection.swift"; sourceTree = "<group>"; };
25
27
+ DDC389FD2A2C4C830066E2E8 /* GlucoseBasedApplicationFactorSelectionView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GlucoseBasedApplicationFactorSelectionView.swift; sourceTree = "<group>"; };
26
28
E90909CC24E34AC500F963D2 /* high_and_rising_with_cob_momentum_effect.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = high_and_rising_with_cob_momentum_effect.json; sourceTree = "<group>"; };
27
29
E90909CD24E34AC500F963D2 /* high_and_rising_with_cob_insulin_effect.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = high_and_rising_with_cob_insulin_effect.json; sourceTree = "<group>"; };
28
30
E90909CE24E34AC500F963D2 /* high_and_rising_with_cob_predicted_glucose.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = high_and_rising_with_cob_predicted_glucose.json; sourceTree = "<group>"; };
29
- @@ -2407,6 +2415,7 @@
31
+ @@ -2312,6 +2322,7 @@
32
+ isa = PBXGroup;
33
+ children = (
34
+ A98556842493F901000FD662 /* AlertStore+SimulatedCoreData.swift */,
35
+ + DDC389FB2A2BC6670066E2E8 /* SettingsView+algorithmExperimentsSection.swift */,
36
+ C1D289B422F90A52003FFBD9 /* BasalDeliveryState.swift */,
37
+ A9F703722489BC8500C98AD8 /* CarbStore+SimulatedCoreData.swift */,
38
+ C17824991E1999FA00D9D25C /* CaseCountable.swift */,
39
+ @@ -2398,6 +2409,7 @@
40
+ 43F64DD81D9C92C900D24DC6 /* TitleSubtitleTableViewCell.swift */,
30
41
4311FB9A1F37FE1B00D4C0A7 /* TitleSubtitleTextFieldTableViewCell.swift */,
31
42
C1AF062229426300002C1B19 /* ManualGlucoseEntryRow.swift */,
32
- DD3DBD282A33AFE9000F8B5B /* IntegralRetrospectiveCorrectionSelectionView.swift */,
33
43
+ DDC389FD2A2C4C830066E2E8 /* GlucoseBasedApplicationFactorSelectionView.swift */,
34
44
);
35
45
path = Views;
36
46
sourceTree = "<group>";
37
- @@ -2448 ,6 +2457 ,9 @@
47
+ @@ -2439 ,6 +2451 ,9 @@
38
48
C1F2075B26D6F9B0007AB7EB /* ProfileExpirationAlerter.swift */,
39
49
A96DAC2B2838F31200D94E38 /* SharedLogging.swift */,
40
50
7E69CFFB2A16A77E00203CBD /* ResetLoopManager.swift */,
@@ -44,31 +54,39 @@ index ba7f9464..b2efab9c 100644
44
54
);
45
55
path = Managers;
46
56
sourceTree = "<group>";
47
- @@ -3880 ,6 +3892 ,7 @@
57
+ @@ -3870 ,6 +3885 ,7 @@
48
58
C1201E2C23ECDBD0002DA84A /* WatchContextRequestUserInfo.swift in Sources */,
49
59
1D49795824E7289700948F05 /* ServicesViewModel.swift in Sources */,
50
60
1D4A3E2D2478628500FD601B /* StoredAlert+CoreDataClass.swift in Sources */,
51
61
+ DDC389FA2A2B62470066E2E8 /* ConstantDosingStrategy.swift in Sources */,
52
62
892D7C5123B54A15008A9656 /* CarbEntryViewController.swift in Sources */,
53
63
B4E202302661063E009421B5 /* AutomaticDosingStatus.swift in Sources */,
54
64
C191D2A125B3ACAA00C26C0B /* DosingStrategySelectionView.swift in Sources */,
55
- @@ -3913 ,6 +3926 ,7 @@
65
+ @@ -3901 ,6 +3917 ,7 @@
56
66
1DB619AC270BAD3D006C9D07 /* VersionUpdateViewModel.swift in Sources */,
57
67
A9C62D882331703100535612 /* Service.swift in Sources */,
58
68
89CAB36324C8FE96009EE3CE /* PredictedGlucoseChartView.swift in Sources */,
59
69
+ DDC389F82A2B620B0066E2E8 /* GlucoseBasedApplicationFactorStrategy.swift in Sources */,
60
70
4F6663941E905FD2009E74FC /* ChartColorPalette+Loop.swift in Sources */,
61
71
A9F703732489BC8500C98AD8 /* CarbStore+SimulatedCoreData.swift in Sources */,
62
72
4328E0351CFC0AE100E199AA /* WatchDataManager.swift in Sources */,
63
- @@ -3976,6 +3990,7 @@
73
+ @@ -3930,6 +3947,7 @@
74
+ E9B080B1253BDA6300BAD8F8 /* UserDefaults+LoopIntents.swift in Sources */,
75
+ C1AF062329426300002C1B19 /* ManualGlucoseEntryRow.swift in Sources */,
76
+ C148CEE724FD91BD00711B3B /* DeliveryUncertaintyAlertManager.swift in Sources */,
77
+ + DDC389FC2A2BC6670066E2E8 /* SettingsView+algorithmExperimentsSection.swift in Sources */,
78
+ 1D12D3B92548EFDD00B53E8B /* main.swift in Sources */,
79
+ 435400341C9F878D00D5819C /* SetBolusUserInfo.swift in Sources */,
80
+ A9DCF32A25B0FABF00C89088 /* LoopUIColorPalette+Default.swift in Sources */,
81
+ @@ -3964,6 +3982,7 @@
64
82
A97F250825E056D500F0EE19 /* OnboardingManager.swift in Sources */,
65
83
438D42F91D7C88BC003244B0 /* PredictionInputEffect.swift in Sources */,
66
84
892A5D692230C41D008961AB /* RangeReplaceableCollection.swift in Sources */,
67
85
+ DDC389F62A2B61750066E2E8 /* ApplicationFactorStrategy.swift in Sources */,
68
86
4F70C2101DE8FAC5006380B7 /* ExtensionDataManager.swift in Sources */,
69
87
43DFB62320D4CAE7008A7BAE /* PumpManager.swift in Sources */,
70
88
A9FB75F1252BE320004C7D3F /* BolusDosingDecision.swift in Sources */,
71
- @@ -3983 ,6 +3998 ,7 @@
89
+ @@ -3971 ,6 +3990 ,7 @@
72
90
431A8C401EC6E8AB00823B9C /* CircleMaskView.swift in Sources */,
73
91
1D05219D2469F1F5000EBBDE /* AlertStore.swift in Sources */,
74
92
439897371CD2F80600223065 /* AnalyticsServicesManager.swift in Sources */,
@@ -77,40 +95,37 @@ index ba7f9464..b2efab9c 100644
77
95
895FE0952201234000FCF18A /* OverrideSelectionViewController.swift in Sources */,
78
96
C1EF747228D6A44A00C8C083 /* CrashRecoveryManager.swift in Sources */,
79
97
diff --git a/Loop/Loop/Extensions/SettingsView+algorithmExperimentsSection.swift b/Loop/Loop/Extensions/SettingsView+algorithmExperimentsSection.swift
80
- index b6f07ba1..b3a5091e 100644
81
- --- a/Loop/Loop/Extensions/SettingsView+algorithmExperimentsSection.swift
98
+ new file mode 100644
99
+ index 00000000..811a2f33
100
+ --- /dev/null
82
101
+++ b/Loop/Loop/Extensions/SettingsView+algorithmExperimentsSection.swift
83
- @@ -5,6 +5,7 @@
84
- // Created by Jonas Björkert on 2023-06-03.
85
- // Copyright © 2023 LoopKit Authors. All rights reserved.
86
- //
102
+ @@ -0,0 +1,26 @@
103
+ + //
104
+ + // SettingsView+algorithmExperimentsSection.swift
105
+ + // Loop
106
+ + //
107
+ + // Created by Jonas Björkert on 2023-06-03.
108
+ + // Copyright © 2023 LoopKit Authors. All rights reserved.
109
+ + //
110
+ +
111
+ + import Foundation
112
+ + import SwiftUI
113
+ + import LoopKitUI
114
+ +
115
+ + extension SettingsView {
116
+ + internal var algorithmExperimentsSection: some View {
117
+ + Section(header: SectionHeader(label: NSLocalizedString("Algorithm Experiments ⚠️", comment: "The title of the Algorithm Experiments section in settings"))) {
87
118
+
88
- import Foundation
89
- import SwiftUI
90
- import LoopKitUI
91
- @@ -12,7 +13,13 @@ import LoopKitUI
92
- extension SettingsView {
93
- internal var algorithmExperimentsSection: some View {
94
- Section(header: SectionHeader(label: NSLocalizedString("Algorithm Experiments ⚠️", comment: "The title of the Algorithm Experiments section in settings"))) {
95
- -
96
119
+ NavigationLink(destination: GlucoseBasedApplicationFactorSelectionView(isGlucoseBasedApplicationFactorEnabled: $isGlucoseBasedApplicationFactorEnabled)) {
97
120
+ HStack {
98
121
+ Text("Glucose Based Partial Application")
99
122
+ Spacer()
100
123
+ Text(isGlucoseBasedApplicationFactorEnabled ? "On" : "Off")
101
124
+ }
102
125
+ }
103
- NavigationLink(destination: IntegralRetrospectiveCorrectionSelectionView(isIntegralRetrospectiveCorrectionEnabled: $isIntegralRetrospectiveCorrectionEnabled)) {
104
- HStack {
105
- Text("Integral Retrospective Correction")
106
- @@ -20,6 +27,6 @@ extension SettingsView {
107
- Text(isIntegralRetrospectiveCorrectionEnabled ? "On" : "Off")
108
- }
109
- }
110
- - }
111
126
+ }
112
- }
113
- }
127
+ + }
128
+ + }
114
129
diff --git a/Loop/Loop/Managers/ApplicationFactorStrategy.swift b/Loop/Loop/Managers/ApplicationFactorStrategy.swift
115
130
new file mode 100644
116
131
index 00000000..bf67935c
@@ -224,7 +239,7 @@ index 00000000..41caa3d7
224
239
+ }
225
240
+ }
226
241
diff --git a/Loop/Loop/Managers/LoopDataManager.swift b/Loop/Loop/Managers/LoopDataManager.swift
227
- index 7db36fc7..8133aa84 100644
242
+ index 085b2420..1b1bab1f 100644
228
243
--- a/Loop/Loop/Managers/LoopDataManager.swift
229
244
+++ b/Loop/Loop/Managers/LoopDataManager.swift
230
245
@@ -1692,42 +1692,29 @@ extension LoopDataManager {
@@ -305,7 +320,7 @@ index 7db36fc7..8133aa84 100644
305
320
306
321
let temp = predictedGlucose.recommendedTempBasal(
307
322
to: glucoseTargetRange!,
308
- @@ -2159 ,6 +2146 ,7 @@ extension LoopDataManager {
323
+ @@ -2157 ,6 +2144 ,7 @@ extension LoopDataManager {
309
324
"insulinOnBoard: \(String(describing: manager.insulinOnBoard))",
310
325
"error: \(String(describing: state.error))",
311
326
"overrideInUserDefaults: \(String(describing: UserDefaults.appGroup?.intentExtensionOverrideToSet))",
@@ -375,19 +390,27 @@ index 00000000..1e78c81e
375
390
+ }
376
391
+ }
377
392
diff --git a/Loop/Loop/Views/SettingsView.swift b/Loop/Loop/Views/SettingsView.swift
378
- index 2615596c..12255a62 100644
393
+ index dc3f6ec3..24032203 100644
379
394
--- a/Loop/Loop/Views/SettingsView.swift
380
395
+++ b/Loop/Loop/Views/SettingsView.swift
381
- @@ -31,7 +31,8 @@ public struct SettingsView: View {
396
+ @@ -30,6 +30,7 @@ public struct SettingsView: View {
397
+ @State private var therapySettingsIsPresented: Bool = false
382
398
@State private var deletePumpDataAlertIsPresented = false
383
399
@State private var deleteCGMDataAlertIsPresented = false
384
- @State internal var isIntegralRetrospectiveCorrectionEnabled = UserDefaults.standard.bool(forKey: "isExperimentalIntegralRetrospectiveCorrectionEnabled")
385
- -
386
400
+ @State internal var isGlucoseBasedApplicationFactorEnabled = UserDefaults.standard.bool(forKey: "applyExperimentalGlucoseBasedApplicationFactor")
387
- +
401
+
388
402
var localizedAppNameAndVersion: String
389
403
390
- public init(viewModel: SettingsViewModel, localizedAppNameAndVersion: String) {
404
+ @@ -50,6 +51,9 @@ public struct SettingsView: View {
405
+ if FeatureFlags.automaticBolusEnabled {
406
+ dosingStrategySection
407
+ }
408
+ + // Note: Experimental Section
409
+ + algorithmExperimentsSection
410
+ + //
411
+ alertManagementSection
412
+ if viewModel.pumpManagerSettingsViewModel.isSetUp() {
413
+ configurationSection
391
414
diff --git a/Loop/Settings.bundle/Root.plist b/Loop/Settings.bundle/Root.plist
392
415
index a176bd16..0df628c0 100644
393
416
--- a/Loop/Settings.bundle/Root.plist
0 commit comments