Skip to content

Commit 4023cbe

Browse files
authored
Update Settings: Update sub-screens (#5334)
Task/Issue URL: https://app.asana.com/0/1207908166761516/1208785622935234/f ### Description Makes design changes to all the settings sub-screens, including: - Copy changes - Padding/Margin changes - Adding/Updating new header images - Rearranging items (Data clearing screen only) ### Steps to test this PR Prerequisites: `newSettings` flag is on Designs: ### _Private Search_ - [Designs](https://www.figma.com/design/BOHDESHODUXK7wSRNBOHdu/%F0%9F%A4%96-Android-Components?node-id=12993-10537&m=dev) - [x] Open Private Search screen - [x] Screen should default to device transition and no longer crossfade - [x] Check new header image is visible - [x] Check Status Indicator is visible and "Always On" - [x] Check copy has been updated - [x] Check against designs #### UI changes | Before | After | | - | - | <img src="https://github.com/user-attachments/assets/adab34f4-e03f-4b81-a066-2b1b5b80fbd6" alt="Alt Text" width="300">|<img src="https://github.com/user-attachments/assets/355bc950-c7d0-4a90-9289-2f05182c66c2" alt="Alt Text" width="300"> ### _Web Tracking Protection_ - [Designs](https://www.figma.com/design/BOHDESHODUXK7wSRNBOHdu/%F0%9F%A4%96-Android-Components?node-id=12993-10580&m=dev) - [x] Open Web Tracking Protection screen - [x] Screen should default to device transition and no longer crossfade - [x] Check new header image is visible - [x] Check Status Indicator is visible and "Always On" - [x] Check copy has been updated - [x] Check against designs #### UI changes | Before | After | | - | - | <img src="https://github.com/user-attachments/assets/7550238e-cc4e-429f-9d6f-12360f6c77b7" alt="Alt Text" width="300">|<img src="https://github.com/user-attachments/assets/6b0ec787-f8f3-477e-bed3-c7e6deb27291" alt="Alt Text" width="300"> ### _Cookie Pop-Up Protection_ - [Designs](https://www.figma.com/design/BOHDESHODUXK7wSRNBOHdu/%F0%9F%A4%96-Android-Components?node-id=13010-29805&m=dev) - [x] Open Cookie Pop-Up Protection screen - [x] Screen should default to device transition and no longer crossfade - [x] Check new header image is visible - [x] Check Status Indicator is visible and is "On" or "Off" depending on the toggle - [x] Turn toggle on/off - [x] Check header image changes to either on/off version - [x] Check Status Indicator turns to on/off - [x] Check copy - [x] Press "Learn More" - [x] Tracking Protections website should open - [x] Press back - [x] Check against designs #### UI changes | Before | After | | - | - | <img src="https://github.com/user-attachments/assets/3cb8424e-c1a7-4f93-a494-01f5d5b2852e" width="300">|<img src="https://github.com/user-attachments/assets/104f2f29-d3dd-4646-a429-89f1efaa4131" width="300"> ### _App Tracking Protection_ - [x] Open App Tracking Protection screen - [x] Screen should default to device transition and no longer crossfade - No other changes made to this screen ### _Email Protection_ - [x] Open Email Protection screen - [x] Screen should default to device transition and no longer crossfade - No other changes made to this screen ### _General_ - [x] Open General screen - [x] Screen should default to device transition and no longer crossfade - No other changes made to this screen ### _Sync & Backup_ - [Designs](https://www.figma.com/design/BOHDESHODUXK7wSRNBOHdu/%F0%9F%A4%96-Android-Components?node-id=13280-39196&m=dev) - [x] Open Sync & Backup screen - [x] Screen should default to device transition and no longer crossfade - [x] Check "Single Device Setup" heading is now "Other Options" - [x] Check against designs #### UI changes | Before | After | | - | - | <img src="https://github.com/user-attachments/assets/cb5a57b3-0355-4da4-bc48-6daf9d6a767e" width="300">|<img src="https://github.com/user-attachments/assets/5f742629-3b64-4b92-8b1f-6769bcc29f85" width="300"> ### _Appearance_ - [Designs](https://www.figma.com/design/BOHDESHODUXK7wSRNBOHdu/%F0%9F%A4%96-Android-Components?node-id=12441-20931&m=dev) - [x] Open Appearance screen - [x] Screen should default to device transition and no longer crossfade - [x] The App Icon should now be aligned to the right of the screen #### UI changes | Before | After | | - | - | <img src="https://github.com/user-attachments/assets/c005bc33-ebc2-47a4-9fff-7dfe086b055a" width="300">|<img src="https://github.com/user-attachments/assets/10b1593b-3b3a-411d-939f-af4165497b3f" width="300"> ### _Passwords & Autofill_ - [x] Open Passwords & Autofill screen - [x] Screen should default to device transition and no longer crossfade - [x] The toolbar title should be "Passwords & Autofill" #### UI changes | Before | After | | - | - | <img src="https://github.com/user-attachments/assets/6d8ca108-529a-478d-96ca-83be998ca296" width="300">|<img src="https://github.com/user-attachments/assets/ebbc844d-99a9-4b47-bffa-c626a6d7ff5a" width="300"> ### _Accessibility_ - [Designs](https://www.figma.com/design/BOHDESHODUXK7wSRNBOHdu/%F0%9F%A4%96-Android-Components?node-id=11073-14078&m=dev) - [x] Open Accessibility screen - [x] Screen should default to device transition and no longer crossfade - [x] Check screen top padding has been increased #### UI changes | Before | After | | - | - | <img src="https://github.com/user-attachments/assets/40d78b41-35dc-4e04-9634-cf239943a077" width="300">|<img src="https://github.com/user-attachments/assets/d42670de-a6e2-4829-a777-3898fd1772d8" width="300"> ### _Permissions_ - [x] Open Permissions screen - [x] Screen should default to device transition and no longer crossfade - No other changes made to this screen ### _Data Clearing_ - [Designs](https://www.figma.com/design/BOHDESHODUXK7wSRNBOHdu/%F0%9F%A4%96-Android-Components?node-id=12993-12784&m=dev) - [x] Open Data Clearing screen - [x] Screen should default to device transition and no longer crossfade - [x] Order of items should be 1. "Fire Button Animation" 2. Divider 3. "Fireproof Sites" 4. "Automatically Clear Data..." 5. "Clear On..." - [x] Check against designs #### UI changes | Before | After | | - | - | <img src="https://github.com/user-attachments/assets/c0e6fd1e-a221-48c8-bc51-39cc22ce475b" width="300">|<img src="https://github.com/user-attachments/assets/59ac1832-4ab9-4e77-a6af-15ddfba843e4" width="300"> ### _Duck Player_ - [ ] Open Duck Player screen - [ ] Screen should default to device transition and no longer crossfade - No other changes made to this screen ### _About_ - [Designs](https://www.figma.com/design/BOHDESHODUXK7wSRNBOHdu/%F0%9F%A4%96-Android-Components?node-id=12993-10920&m=dev) - [ ] Open About screen - [ ] Screen should default to device transition and no longer crossfade - [ ] Title in toolbar should be "About" - [ ] Check about copy matches designs - [ ] Check against designs #### UI changes | Before | After | | - | - | <img src="https://github.com/user-attachments/assets/367f4768-4e9e-4395-b44f-e7c082bab1b8" width="300">|<img src="https://github.com/user-attachments/assets/434ccb4f-ab8a-4f56-a9fa-8d5d1ff557fc" width="300"> _LegacySettings Screen_ Prerequisites: `newSettings` flag is off - [ ] Smoke test, run through each item an ensure there are no major visual changes e.g. two header images instead of 1 ## Demo https://github.com/user-attachments/assets/8c256538-816c-4ef5-a01b-d31260f6cb41
1 parent 15ab4b7 commit 4023cbe

File tree

36 files changed

+808
-198
lines changed

36 files changed

+808
-198
lines changed

app/src/main/java/com/duckduckgo/app/about/AboutDuckDuckGoActivity.kt

Lines changed: 25 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ import android.text.style.ForegroundColorSpan
2727
import android.text.style.UnderlineSpan
2828
import android.view.View
2929
import androidx.core.view.isGone
30+
import androidx.core.view.isVisible
3031
import androidx.lifecycle.Lifecycle
3132
import androidx.lifecycle.flowWithLifecycle
3233
import androidx.lifecycle.lifecycleScope
@@ -80,7 +81,13 @@ class AboutDuckDuckGoActivity : DuckDuckGoActivity() {
8081
setContentView(binding.root)
8182
setupToolbar(binding.includeToolbar.toolbar)
8283

83-
binding.includeContent.aboutProvideFeedback.isGone = settingsFeature.self().isEnabled()
84+
if (settingsFeature.self().isEnabled()) {
85+
supportActionBar?.setTitle(R.string.aboutActivityTitleNew)
86+
binding.includeContent.aboutTextNew.isVisible = true
87+
88+
binding.includeContent.aboutText.isGone = true
89+
binding.includeContent.aboutProvideFeedback.isGone = true
90+
}
8491

8592
configureUiEventHandlers()
8693
observeViewModel()
@@ -93,14 +100,27 @@ class AboutDuckDuckGoActivity : DuckDuckGoActivity() {
93100
}
94101

95102
private fun configureClickableLinks() {
96-
with(binding.includeContent.aboutText) {
97-
text = addClickableLinks()
98-
movementMethod = LinkMovementMethod.getInstance()
103+
if (settingsFeature.self().isEnabled()) {
104+
with(binding.includeContent.aboutTextNew) {
105+
text = addClickableLinks()
106+
movementMethod = LinkMovementMethod.getInstance()
107+
}
108+
} else {
109+
with(binding.includeContent.aboutText) {
110+
text = addClickableLinks()
111+
movementMethod = LinkMovementMethod.getInstance()
112+
}
99113
}
100114
}
101115

102116
private fun addClickableLinks(): SpannableString {
103-
val fullText = getText(R.string.aboutDescription) as SpannedString
117+
val fullText = getText(
118+
if (settingsFeature.self().isEnabled()) {
119+
R.string.aboutDescriptionNew
120+
} else {
121+
R.string.aboutDescription
122+
},
123+
) as SpannedString
104124
val spannableString = SpannableString(fullText)
105125
val annotations = fullText.getSpans(0, fullText.length, Annotation::class.java)
106126

app/src/main/java/com/duckduckgo/app/firebutton/FireButtonActivity.kt

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ import androidx.lifecycle.lifecycleScope
2525
import com.duckduckgo.anvil.annotations.ContributeToActivityStarter
2626
import com.duckduckgo.anvil.annotations.InjectWith
2727
import com.duckduckgo.app.browser.R
28+
import com.duckduckgo.app.browser.databinding.ActivityDataClearingBinding
2829
import com.duckduckgo.app.browser.databinding.ActivityFireButtonBinding
2930
import com.duckduckgo.app.fire.fireproofwebsite.ui.FireproofWebsitesActivity
3031
import com.duckduckgo.app.firebutton.FireButtonViewModel.AutomaticallyClearData
@@ -43,6 +44,7 @@ import com.duckduckgo.common.ui.DuckDuckGoActivity
4344
import com.duckduckgo.common.ui.view.dialog.RadioListAlertDialogBuilder
4445
import com.duckduckgo.common.ui.viewbinding.viewBinding
4546
import com.duckduckgo.di.scopes.ActivityScope
47+
import com.duckduckgo.settings.api.NewSettingsFeature
4648
import javax.inject.Inject
4749
import kotlinx.coroutines.flow.launchIn
4850
import kotlinx.coroutines.flow.onEach
@@ -58,20 +60,35 @@ class FireButtonActivity : DuckDuckGoActivity() {
5860
@Inject
5961
lateinit var appBuildConfig: AppBuildConfig
6062

63+
@Inject
64+
lateinit var newSettingsFeature: NewSettingsFeature
65+
6166
private val viewModel: FireButtonViewModel by bindViewModel()
62-
private val binding: ActivityFireButtonBinding by viewBinding()
67+
private val legacyBinding: ActivityFireButtonBinding by viewBinding() // TODO remove
68+
private val binding: ActivityDataClearingBinding by viewBinding()
6369

6470
override fun onCreate(savedInstanceState: Bundle?) {
6571
super.onCreate(savedInstanceState)
6672

67-
setContentView(binding.root)
68-
setupToolbar(binding.includeToolbar.toolbar)
73+
if (newSettingsFeature.self().isEnabled()) {
74+
setContentView(binding.root)
75+
setupToolbar(binding.includeToolbar.toolbar)
76+
supportActionBar?.setTitle(R.string.dataClearingActivityTitle)
77+
} else {
78+
setContentView(legacyBinding.root)
79+
setupToolbar(legacyBinding.includeToolbar.toolbar)
80+
}
6981

7082
configureUiEventHandlers()
7183
observeViewModel()
7284
}
7385

7486
private fun configureUiEventHandlers() {
87+
legacyBinding.fireproofWebsites.setClickListener { viewModel.onFireproofWebsitesClicked() }
88+
legacyBinding.automaticallyClearWhatSetting.setClickListener { viewModel.onAutomaticallyClearWhatClicked() }
89+
legacyBinding.automaticallyClearWhenSetting.setClickListener { viewModel.onAutomaticallyClearWhenClicked() }
90+
legacyBinding.selectedFireAnimationSetting.setClickListener { viewModel.userRequestedToChangeFireAnimation() }
91+
7592
binding.fireproofWebsites.setClickListener { viewModel.onFireproofWebsitesClicked() }
7693
binding.automaticallyClearWhatSetting.setClickListener { viewModel.onAutomaticallyClearWhatClicked() }
7794
binding.automaticallyClearWhenSetting.setClickListener { viewModel.onAutomaticallyClearWhenClicked() }
@@ -96,17 +113,21 @@ class FireButtonActivity : DuckDuckGoActivity() {
96113

97114
private fun updateAutomaticClearDataOptions(automaticallyClearData: AutomaticallyClearData) {
98115
val clearWhatSubtitle = getString(automaticallyClearData.clearWhatOption.nameStringResourceId())
116+
legacyBinding.automaticallyClearWhatSetting.setSecondaryText(clearWhatSubtitle)
99117
binding.automaticallyClearWhatSetting.setSecondaryText(clearWhatSubtitle)
100118

101119
val clearWhenSubtitle = getString(automaticallyClearData.clearWhenOption.nameStringResourceId())
120+
legacyBinding.automaticallyClearWhenSetting.setSecondaryText(clearWhenSubtitle)
102121
binding.automaticallyClearWhenSetting.setSecondaryText(clearWhenSubtitle)
103122

104123
val whenOptionEnabled = automaticallyClearData.clearWhenOptionEnabled
124+
legacyBinding.automaticallyClearWhenSetting.isEnabled = whenOptionEnabled
105125
binding.automaticallyClearWhenSetting.isEnabled = whenOptionEnabled
106126
}
107127

108128
private fun updateSelectedFireAnimation(fireAnimation: FireAnimation) {
109129
val subtitle = getString(fireAnimation.nameResId)
130+
legacyBinding.selectedFireAnimationSetting.setSecondaryText(subtitle)
110131
binding.selectedFireAnimationSetting.setSecondaryText(subtitle)
111132
}
112133

app/src/main/java/com/duckduckgo/app/privatesearch/PrivateSearchActivity.kt

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ package com.duckduckgo.app.privatesearch
1818

1919
import android.os.Bundle
2020
import android.widget.CompoundButton
21+
import androidx.core.view.isGone
2122
import androidx.core.view.isVisible
2223
import androidx.lifecycle.Lifecycle
2324
import androidx.lifecycle.flowWithLifecycle
@@ -32,6 +33,7 @@ import com.duckduckgo.common.ui.DuckDuckGoActivity
3233
import com.duckduckgo.common.ui.viewbinding.viewBinding
3334
import com.duckduckgo.di.scopes.ActivityScope
3435
import com.duckduckgo.navigation.api.GlobalActivityStarter
36+
import com.duckduckgo.settings.api.NewSettingsFeature
3537
import javax.inject.Inject
3638
import kotlinx.coroutines.flow.launchIn
3739
import kotlinx.coroutines.flow.onEach
@@ -43,6 +45,9 @@ class PrivateSearchActivity : DuckDuckGoActivity() {
4345
@Inject
4446
lateinit var globalActivityStarter: GlobalActivityStarter
4547

48+
@Inject
49+
lateinit var newSettingsFeature: NewSettingsFeature
50+
4651
private val viewModel: PrivateSearchViewModel by bindViewModel()
4752
private val binding: ActivityPrivateSearchBinding by viewBinding()
4853

@@ -60,6 +65,20 @@ class PrivateSearchActivity : DuckDuckGoActivity() {
6065
setContentView(binding.root)
6166
setupToolbar(binding.includeToolbar.toolbar)
6267

68+
if (newSettingsFeature.self().isEnabled()) {
69+
with(binding) {
70+
privateSearchHeaderImage.isGone = true
71+
privateSearchTitle.isGone = true
72+
privateSearchDescription.isGone = true
73+
privateSearchHeadingSearchSettings.isGone = true
74+
75+
privateSearchHeaderImageNew.isVisible = true
76+
privateSearchTitleNew.isVisible = true
77+
statusIndicator.isVisible = true
78+
privateSearchDescriptionNew.isVisible = true
79+
}
80+
}
81+
6382
configureUiEventHandlers()
6483
observeViewModel()
6584
}

app/src/main/java/com/duckduckgo/app/settings/NewSettingsActivity.kt

Lines changed: 26 additions & 102 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616

1717
package com.duckduckgo.app.settings
1818

19-
import android.app.ActivityOptions
2019
import android.content.Context
2120
import android.content.Intent
2221
import android.os.Bundle
@@ -81,6 +80,7 @@ import com.duckduckgo.internal.features.api.InternalFeaturePlugin
8180
import com.duckduckgo.mobile.android.app.tracking.ui.AppTrackingProtectionScreens.AppTrackerActivityWithEmptyParams
8281
import com.duckduckgo.mobile.android.app.tracking.ui.AppTrackingProtectionScreens.AppTrackerOnboardingActivityWithEmptyParamsParams
8382
import com.duckduckgo.navigation.api.GlobalActivityStarter
83+
import com.duckduckgo.navigation.api.GlobalActivityStarter.ActivityParams
8484
import com.duckduckgo.settings.api.DuckPlayerSettingsPlugin
8585
import com.duckduckgo.settings.api.ProSettingsPlugin
8686
import com.duckduckgo.subscriptions.api.PrivacyProFeedbackScreens.GeneralPrivacyProFeedbackScreenNoParams
@@ -305,29 +305,28 @@ class NewSettingsActivity : DuckDuckGoActivity() {
305305
viewsPrivacy.cookiePopupProtectionSetting.setStatus(isOn = enabled)
306306
}
307307

308-
private fun processCommand(it: Command?) {
308+
private fun processCommand(it: Command) {
309309
when (it) {
310310
is LaunchDefaultBrowser -> launchDefaultAppScreen()
311-
is LaunchAutofillSettings -> launchAutofillSettings()
312-
is LaunchAccessibilitySettings -> launchAccessibilitySettings()
313-
is LaunchAppTPTrackersScreen -> launchAppTPTrackersScreen()
314-
is LaunchAppTPOnboarding -> launchAppTPOnboardingScreen()
315-
is LaunchEmailProtection -> launchEmailProtectionScreen(it.url)
316-
is LaunchEmailProtectionNotSupported -> launchEmailProtectionNotSupported()
311+
is LaunchAutofillSettings -> launchScreen(AutofillSettingsScreen(source = AutofillSettingsLaunchSource.SettingsActivity))
312+
is LaunchAccessibilitySettings -> launchScreen(AccessibilityScreens.Default)
313+
is LaunchAppTPTrackersScreen -> launchScreen(AppTrackerActivityWithEmptyParams)
314+
is LaunchAppTPOnboarding -> launchScreen(AppTrackerOnboardingActivityWithEmptyParamsParams)
315+
is LaunchEmailProtection -> launchActivityAndFinish(BrowserActivity.intent(this, it.url, interstitialScreen = true))
316+
is LaunchEmailProtectionNotSupported -> launchScreen(EmailProtectionUnsupportedScreenNoParams)
317317
is LaunchAddHomeScreenWidget -> launchAddHomeScreenWidget()
318-
is LaunchSyncSettings -> launchSyncSettings()
319-
is LaunchPrivateSearchWebPage -> launchPrivateSearchScreen()
320-
is LaunchWebTrackingProtectionScreen -> launchWebTrackingProtectionScreen()
321-
is LaunchCookiePopupProtectionScreen -> launchCookiePopupProtectionScreen()
322-
is LaunchFireButtonScreen -> launchFireButtonScreen()
323-
is LaunchPermissionsScreen -> launchPermissionsScreen()
324-
is LaunchAppearanceScreen -> launchAppearanceScreen()
325-
is LaunchAboutScreen -> launchAboutScreen()
326-
is LaunchGeneralSettingsScreen -> launchGeneralSettingsScreen()
318+
is LaunchSyncSettings -> launchScreen(SyncActivityWithEmptyParams)
319+
is LaunchPrivateSearchWebPage -> launchScreen(PrivateSearchScreenNoParams)
320+
is LaunchWebTrackingProtectionScreen -> launchScreen(WebTrackingProtectionScreenNoParams)
321+
is LaunchCookiePopupProtectionScreen -> launchActivity(AutoconsentSettingsActivity.intent(this))
322+
is LaunchFireButtonScreen -> launchScreen(FireButtonScreenNoParams)
323+
is LaunchPermissionsScreen -> launchScreen(PermissionsScreenNoParams)
324+
is LaunchAppearanceScreen -> launchScreen(AppearanceScreen.Default)
325+
is LaunchAboutScreen -> launchScreen(AboutScreenNoParams)
326+
is LaunchGeneralSettingsScreen -> launchScreen(GeneralSettingsScreenNoParams)
327327
is LaunchFeedback -> launchFeedback()
328-
is LaunchPproUnifiedFeedback -> launchPproUnifiedFeedback()
329-
is LaunchOtherPlatforms -> launchOtherPlatforms()
330-
null -> TODO()
328+
is LaunchPproUnifiedFeedback -> launchScreen(GeneralPrivacyProFeedbackScreenNoParams)
329+
is LaunchOtherPlatforms -> launchActivityAndFinish(BrowserActivity.intent(context = this, queryExtra = OTHER_PLATFORMS_URL))
331330
}
332331
}
333332

@@ -350,103 +349,28 @@ class NewSettingsActivity : DuckDuckGoActivity() {
350349
launchDefaultAppActivity()
351350
}
352351

353-
private fun launchAutofillSettings() {
354-
val options = ActivityOptions.makeSceneTransitionAnimation(this).toBundle()
355-
globalActivityStarter.start(this, AutofillSettingsScreen(source = AutofillSettingsLaunchSource.SettingsActivity), options)
352+
private fun launchScreen(activityParams: ActivityParams) {
353+
globalActivityStarter.start(this, activityParams)
356354
}
357355

358-
private fun launchAccessibilitySettings() {
359-
val options = ActivityOptions.makeSceneTransitionAnimation(this).toBundle()
360-
globalActivityStarter.start(this, AccessibilityScreens.Default, options)
356+
private fun launchActivity(intent: Intent) {
357+
startActivity(intent)
361358
}
362359

363-
private fun launchEmailProtectionScreen(url: String) {
364-
val options = ActivityOptions.makeSceneTransitionAnimation(this).toBundle()
365-
startActivity(BrowserActivity.intent(this, url, interstitialScreen = true), options)
366-
this.finish()
367-
}
368-
369-
private fun launchEmailProtectionNotSupported() {
370-
val options = ActivityOptions.makeSceneTransitionAnimation(this).toBundle()
371-
globalActivityStarter.start(this, EmailProtectionUnsupportedScreenNoParams, options)
372-
}
373-
374-
private fun launchSyncSettings() {
375-
val options = ActivityOptions.makeSceneTransitionAnimation(this).toBundle()
376-
globalActivityStarter.start(this, SyncActivityWithEmptyParams, options)
377-
}
378-
379-
private fun launchAppTPTrackersScreen() {
380-
val options = ActivityOptions.makeSceneTransitionAnimation(this).toBundle()
381-
globalActivityStarter.start(this, AppTrackerActivityWithEmptyParams, options)
382-
}
383-
384-
private fun launchAppTPOnboardingScreen() {
385-
val options = ActivityOptions.makeSceneTransitionAnimation(this).toBundle()
386-
globalActivityStarter.start(this, AppTrackerOnboardingActivityWithEmptyParamsParams, options)
360+
private fun launchActivityAndFinish(intent: Intent) {
361+
launchActivity(intent)
362+
finish()
387363
}
388364

389365
private fun launchAddHomeScreenWidget() {
390366
pixel.fire(AppPixelName.SETTINGS_ADD_HOME_SCREEN_WIDGET_CLICKED)
391367
addWidgetLauncher.launchAddWidget(this)
392368
}
393369

394-
private fun launchPrivateSearchScreen() {
395-
val options = ActivityOptions.makeSceneTransitionAnimation(this).toBundle()
396-
globalActivityStarter.start(this, PrivateSearchScreenNoParams, options)
397-
}
398-
399-
private fun launchWebTrackingProtectionScreen() {
400-
val options = ActivityOptions.makeSceneTransitionAnimation(this).toBundle()
401-
globalActivityStarter.start(this, WebTrackingProtectionScreenNoParams, options)
402-
}
403-
404-
private fun launchCookiePopupProtectionScreen() {
405-
val options = ActivityOptions.makeSceneTransitionAnimation(this).toBundle()
406-
startActivity(AutoconsentSettingsActivity.intent(this), options)
407-
}
408-
409-
private fun launchFireButtonScreen() {
410-
val options = ActivityOptions.makeSceneTransitionAnimation(this).toBundle()
411-
globalActivityStarter.start(this, FireButtonScreenNoParams, options)
412-
}
413-
414-
private fun launchPermissionsScreen() {
415-
val options = ActivityOptions.makeSceneTransitionAnimation(this).toBundle()
416-
globalActivityStarter.start(this, PermissionsScreenNoParams, options)
417-
}
418-
419-
private fun launchAppearanceScreen() {
420-
val options = ActivityOptions.makeSceneTransitionAnimation(this).toBundle()
421-
globalActivityStarter.start(this, AppearanceScreen.Default, options)
422-
}
423-
424-
private fun launchAboutScreen() {
425-
val options = ActivityOptions.makeSceneTransitionAnimation(this).toBundle()
426-
globalActivityStarter.start(this, AboutScreenNoParams, options)
427-
}
428-
429-
private fun launchGeneralSettingsScreen() {
430-
val options = ActivityOptions.makeSceneTransitionAnimation(this).toBundle()
431-
globalActivityStarter.start(this, GeneralSettingsScreenNoParams, options)
432-
}
433-
434370
private fun launchFeedback() {
435371
feedbackFlow.launch(null)
436372
}
437373

438-
private fun launchPproUnifiedFeedback() {
439-
globalActivityStarter.start(
440-
this,
441-
GeneralPrivacyProFeedbackScreenNoParams,
442-
)
443-
}
444-
445-
private fun launchOtherPlatforms() {
446-
startActivity(BrowserActivity.intent(context = this, queryExtra = OTHER_PLATFORMS_URL))
447-
finish()
448-
}
449-
450374
companion object {
451375
const val LAUNCH_FROM_NOTIFICATION_PIXEL_NAME = "LAUNCH_FROM_NOTIFICATION_PIXEL_NAME"
452376

0 commit comments

Comments
 (0)