Commit Graph

638 Commits

Author SHA1 Message Date
Oliver Scott
d9d285909a Fix system locale
System locale update API isn't deprecated. Call was erroneously replaced in https://review.lineageos.org/c/LineageOS/android_packages_apps_SetupWizard/+/379324/12/src/org/lineageos/setupwizard/LocaleActivity.java#b65

Issue: calyxos#2265
Change-Id: Ic4b4e7ce70f0eb9106401da95feabc576954e381
2024-04-09 19:45:23 +00:00
LineageOS Infra
10343a5e1f Automatic translation import
Change-Id: Ifd4ac5636c1a8d87e6ca8d365f64e1fab11d2b1f
2024-03-27 09:21:50 +00:00
Michael Bestas
79e9f1cdbd Fix QPR2 build
Change-Id: I03bdfacf5d8432ac9e4c66723ecacbf5a4464154
2024-03-20 19:06:16 +00:00
Timi Rautamäki
935ba6902d SUW: center welcome text on TV
Change-Id: I4c984d78137b65e29f60769d3c5a368568c7e79c
2024-03-05 15:20:42 -05:00
Aaron Kling
6cb268b222 BluetoothSetupActivity: ignore cancel results
Change-Id: I9e7f62b2a11d8b2af0c075b0151a29c4485e8931
2024-03-05 15:19:43 -05:00
Aaron Kling
a09594c415 WelcomeActivity: do nothing on back press
Devices with a hardware back button, such as atv remotes, can press back
on the welcome screen and trigger a transition to a waiting screen then
back to welcome. This should not be allowed.

Change-Id: I2273d0d74fb1ef018074d4facc8e3793e7470f6f
2024-03-05 15:14:58 -05:00
razorloves
112f926f77 fixup! Remove unused colors
Change-Id: Id28f03acaa50663748617d94bc1c390424348e60
2024-03-01 21:48:40 -06:00
Chirayu Desai
2b605d17bb welcome: Use a separate string for work profile start
* Intentionally not touching this for secondary users
  so that it doesn't look different from the main user.
* We don't explicitly support that, but let's also not
  go out of our way to break something like this.

Change-Id: I374b45feb7d6dd17e5d03d0f7fbaf6d9e22f1d55
2024-03-02 03:39:05 +02:00
Michael Bestas
db86c22c41 Remove unused View
Change-Id: I2625cd9a3d59afded84621f0ceea4984d755eb5a
2024-03-02 03:39:05 +02:00
Michael Bestas
b69c30c4ed Remove unused colors
Change-Id: I91f16a43c935d8c6d52e6d3ff665145df1466a88
2024-03-02 03:39:05 +02:00
Michael Bestas
f3d2943c38 Remove unused import
Change-Id: I7660d5e51aa8a063ba118caa57d7d6898e5211f4
2024-03-02 03:39:04 +02:00
Tom Pratt
ab27e602cb Don't disable mobile data, AOSP has props for this
Mobile data during and after setupwizard can be controlled with:

ro.com.android.mobiledata
ro.com.android.prov_mobiledata

Change-Id: Ia4ef25f55ab32e8c13f9683b5db73438a29a192b
2024-02-28 17:05:26 +02:00
Michael Bestas
95cf350cc0 SetupWizard: Update backup page description
Seedvault backups can be restored from any OS that includes Seedvault,
they are not restricted to LineageOS.

Change-Id: Ie3d896d0377c8d2fe47558ae6a2bb54a0864498c
2024-02-26 00:25:44 +02:00
Michael Bestas
ee0104638c Match U setupdesign dark theme
Change-Id: Ifac33e5fc792e4a19cee645dbc355f56fcfada89
2024-02-26 00:25:44 +02:00
Michael Bestas
965cd0c223 Specify theme when launching external activities
Change-Id: Ia2db8a1b3753bdc3d9bd646be68e98367c2aed39
2024-02-26 00:25:44 +02:00
Michael Bestas
ec05005cfe SetupWizard: Make it REUSE compliant
* Ignored all the strings.xml since they are auto-synced

Change-Id: I5d9e7aa5ae7b0079f792450f7e6dbf83216ebac4
2024-02-26 00:25:43 +02:00
Oliver Scott
1db317b962 Remove old tests
Change-Id: I4344408d7e72093606e0cf90ada4f6bc02831a6b
2024-02-26 00:25:43 +02:00
Oliver Scott
feadacc46b Cleanup exit code
Change-Id: I5fe6165d87afa63887025c3635eafae9f968c062
2024-02-26 00:22:27 +02:00
Oliver Scott
fd0fdb8a49 Fix various java warnings
Change-Id: I4c4381e1755831df2c4f41279800fd6af173e4ed
2024-02-26 00:22:03 +02:00
Oliver Scott
7664461e5f Reformat code
Run automated code reformatting in Android Studio and manually fix
unwanted/broken style changes

Change-Id: Iaf14a08a275f9b11e1ae17f69201ab61a9c6ade1
2024-02-26 00:22:02 +02:00
Michael Bestas
f609cd21c8 SetupWizard: Remove unused resources
Change-Id: I42513b52e97c4f6fdf7ead2d2fa0f3bc6147755c
2024-02-26 00:19:23 +02:00
Jake Florence
9e8aa8c9ff SetupWizard: skip missing subactivities
when a subactivity is missing the setup wizard crashes and puts the user back to the previous page

this patch allows the user to continue as if they skipped

Change-Id: Icb4937b1751d9612c32cb3012f9fc05de2640891
2024-02-26 00:19:23 +02:00
Tommy Webb
ed1a968160 Revamp outro animation
Use the wallpaper as part of the window background rather than trying
to replicate it with WallpaperManager. This allows us to perform a
circular hide to whatever the wallpaper currently looks like exactly,
rather than needing to obtain the wallpaper Bitmap or Drawable and
guess. Display the Finish activity edge-to-edge. Fade out rather
than slide out.

Change-Id: I1154043178a04ca0ced7e8365e338dc10f3377cb
2024-02-26 00:19:23 +02:00
Tommy Webb
63bbec0258 Only finish Setup Wizard Activity when fully done
Wait for the ACTION_FINISHED broadcast before finishing the Activity.
This prevents the Setup Wizard from being re-launched when it is still
set as the default home screen, which it continues to be until the
exit worker changes as part of its finishSetupWizard call.

Skip SetupWizardExitActivity during the normal finish process, moving
common exit operations to SetupWizardUtils.

Change-Id: I1c59553e7dcaf934fb81dce9bf901ec0f2bb7b59
2024-02-26 00:19:22 +02:00
Oliver Scott
f58c0f4b83 Update deprecated code
Change-Id: I1b128b0f8b654c5c76464c12145d927ec10da26e
2024-02-25 23:45:38 +02:00
Tommy Webb
83338c4ae6 Consolidate PhoneMonitor into SetupWizardUtils
Moved and refactored missingSim and its helper functions into
SetupWizardUtils, making them static. This was the only part of
PhoneMonitor that was used anymore.

Change-Id: I220e82e83bdb301206c4286b562f69c223de56e2
2024-02-25 23:45:38 +02:00
Oliver Scott
51fde0aa49 Automated code cleanup + copyright update
Change-Id: I6deb788643d639f11ce9a5dc09eda701a2664c4a
2024-02-25 23:45:38 +02:00
Michael Bestas
bd92956625 SetupWizard: Remove unused strings
Change-Id: I774fb1c4b06922dbbc7e2cacb7edf3c99df57b31
2024-02-25 23:45:38 +02:00
Oliver Scott
973660d02e Optimize imports
Change-Id: I8e47e86d7c92a7e1a824cf0c052ac9eb9d1a3605
2024-02-25 23:45:38 +02:00
Oliver Scott
f515276ebd Launch restore step early
During restore, Settings which the user may have set earlier during setup may be overwritten. Avoid this by restoring before allowing the user to set new values

Change-Id: Id64378fb44e00da1c666cba7a737f03f9f0b88b8
2024-02-25 23:45:38 +02:00
Oliver Scott
554f63530a SetupWizard: Add step for changing theme
Change-Id: Ib28e752583926e9740dd7e954d208d4fe62e3c08
2024-02-25 23:45:37 +02:00
Oliver Scott
04c9f463d5 Use WizardManagerHelper NEXT intent and result codes
The helper function copies all relevant extras

Change-Id: I1ebb48dd2e2a2ba0881c6a3382996c2243d84140
2024-02-25 23:02:28 +02:00
Oliver Scott
86ed621eff Launch Settings activities for lockscreen and biometrics setup
Issue: calyxos#1420
Change-Id: If6145a7f5a8bd0acc648a3b3ce4aa0d59a5157e0
2024-02-25 23:02:28 +02:00
LineageOS Infra
11e55ab3b2 Automatic translation import
Change-Id: Ie570df0326ae7b6ff4a30a4fe7fac9e3b9e4a19d
2024-02-18 19:38:54 +00:00
LineageOS Infra
11b7f4cb1b Automatic translation import
Change-Id: If4b7687e49f569487802eb901fad259982ce2a60
2024-02-10 19:04:54 +00:00
Oliver Scott
0dc2e90fad fixup! Simplify biometric detection
Change-Id: Idff88839377f78b86f469dd744115ba0d55f9d46
2024-01-05 11:12:24 -05:00
Oliver Scott
9b3f1afb50 fixup! Simplify biometric detection
Change-Id: I2964746a5d648dc51328bac28e4fe5893341d1a6
2023-12-27 11:50:53 -05:00
Oliver Scott
e54fdc16cc Validate URI intent scheme in WizardAction
Change-Id: If6b2553737e08e906145aef9f4a310e075161849
2023-12-11 19:23:36 -05:00
Oliver Scott
4959595167 Always set EXTRA_IS_SETUP_FLOW when starting activities
Some activities behave differently if launched during setup (e.g. https://cs.android.com/android/platform/superproject/main/+/main:packages/apps/Settings/src/com/android/settings/biometrics/BiometricUtils.java;l=203;drc=7f8197da822dea3ce92d3aedb61715d372d7a8e1 https://cs.android.com/android/platform/superproject/main/+/main:external/setupcompat/main/java/com/google/android/setupcompat/util/WizardManagerHelper.java;l=243;drc=d4035b6eb1192f71af7adae47bf17d22c7356fa1)
This change defaults to using the setup flow variant of all launched activities (if applicable)

Change-Id: I0448f2ec5b2789a094d69b1614596d96260edbf5
2023-12-11 19:23:36 -05:00
Oliver Scott
5fb7fc2f4b Simplify biometric detection
Change-Id: I078c269d1463fbbb69685970d32702715ad325ac
2023-12-11 19:23:32 -05:00
Oliver Scott
3a685cceed Fix PhoneMonitor unregistered receiver crash
Fix crash caused by attempting to unregister an unregistered broadcast receiver when the instance is registered but the broadcast receiver is not during setup finish

Change-Id: I0e85492fe5c3a273ed6a2d16fe41bdd7539ffb4b
2023-12-11 17:58:28 -05:00
Michael Bestas
ec63fcccc1 SetupWizard: Set package name for com.android.wizard.LOAD intent
https://developer.android.com/about/versions/14/behavior-changes-14#safer-intents

Fixes:
java.lang.RuntimeException: Unable to start activity ComponentInfo{
org.lineageos.setupwizard/org.lineageos.setupwizard.SetupWizardActivity}:
android.content.ActivityNotFoundException: No Activity found to handle Intent
{ act=com.android.wizard.LOAD flg=0x10000001 (has extras) }

Change-Id: Ia15bc000011acb05b2db06299d142cabdf4e30c8
2023-10-28 23:50:20 +03:00
LuK1337
c98b8c2c11 SetupWizard: Update wizard scripts for 14
Change-Id: Ic82c0c955e7b26f1a13b54e40d1685afc61e9de0
2023-10-24 17:03:39 +02:00
Michael Bestas
0ace5b6bd4 SetupWizard: Fix build after getDefaultDataPhoneId removal
40dfa97392

Change-Id: Ie853c7e789023814c83fed5f318c4910a1169a04
2023-10-22 12:33:26 +00:00
LineageOS Infra
2e8785ecb9 Automatic translation import
Change-Id: Ic702daf6f872e711e844522ac92bf769315a0549
2023-10-15 20:43:21 +00:00
Bruno Martins
cb5f357b1c SuW: Remove obsolete dimension resources
These are no longer used.

Change-Id: I139b1fe80c597ae88d28a78fbab741210375ac4b
2023-10-13 10:04:47 +00:00
Bruno Martins
0a77fdb0e9 WelcomeActivity: Only show emergency call button if supported
Change-Id: I569af46dfd3a026439817bb43ee55fdc855c6298
2023-10-09 23:46:40 +01:00
Bruno Martins
0e05ffc9d0 SuW: Make restore apps and data subtitle generic
Change-Id: Ie8fd2e5105154bebda5cc01cf07030ac7f1ebcd0
2023-10-08 11:09:05 +00:00
Bruno Martins
a40c802d0c SuW: Add lockscreen setup title string for "device" product type
Change-Id: I8d5cc849b12adb1041a123d4ab348317942b716a
2023-10-08 11:09:05 +00:00
LineageOS Infra
cfa23a111a Automatic translation import
Change-Id: I110a82f0f851a639950754893c3750b7cf5f73ba
2023-10-01 16:32:58 +00:00