File tree 3 files changed +18
-9
lines changed
src/main/java/dev/spiegl/flyingcarpet
3 files changed +18
-9
lines changed Original file line number Diff line number Diff line change @@ -8,10 +8,10 @@ android {
8
8
9
9
defaultConfig {
10
10
applicationId " dev.spiegl.flyingcarpet"
11
- minSdk 23
11
+ minSdk 26
12
12
targetSdk 34
13
- versionCode 13
14
- versionName " 8.0.1 "
13
+ versionCode 14
14
+ versionName " 8.0.2 "
15
15
16
16
testInstrumentationRunner " androidx.test.runner.AndroidJUnitRunner"
17
17
}
Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ class About : DialogFragment() {
33
33
34
34
const val AboutMessage = """
35
35
https://flyingcarpet.spiegl.dev
36
- Version 8.0.1
36
+ Version 8.0.2
37
37
38
38
Copyright 2024, Theron Spiegl, all rights reserved.
39
39
Original file line number Diff line number Diff line change @@ -69,13 +69,22 @@ class MainActivity : AppCompatActivity() {
69
69
return
70
70
}
71
71
72
- val info = viewModel.reservation.softApConfiguration
73
- if (Build .VERSION .SDK_INT >= Build .VERSION_CODES .TIRAMISU ) {
74
- info.wifiSsid?.let { viewModel.ssid = it.toString() }
72
+ // get ssid and password
73
+ if (Build .VERSION .SDK_INT < Build .VERSION_CODES .R ) {
74
+ val info = viewModel.reservation.wifiConfiguration
75
+ info?.let {
76
+ viewModel.ssid = it.SSID
77
+ viewModel.password = it.preSharedKey
78
+ }
75
79
} else {
76
- info.ssid?.let { viewModel.ssid = it }
80
+ val info = viewModel.reservation.softApConfiguration
81
+ if (Build .VERSION .SDK_INT >= Build .VERSION_CODES .TIRAMISU ) {
82
+ info.wifiSsid?.let { viewModel.ssid = it.toString() }
83
+ } else {
84
+ info.ssid?.let { viewModel.ssid = it }
85
+ }
86
+ info.passphrase?.let { viewModel.password = it }
77
87
}
78
- info.passphrase?.let { viewModel.password = it }
79
88
80
89
// ensure no quotes around the ssid, not sure why this is necessary
81
90
viewModel.ssid = viewModel.ssid.replace(" \" " , " " )
You can’t perform that action at this time.
0 commit comments