Skip to content

Commit d8aa781

Browse files
criticalAYBrayanDSO
authored andcommitted
refactor: remove old MyAccount activity
- update usage to new LoginFragment fix: multimedia uri security exception
1 parent b04e2ed commit d8aa781

File tree

8 files changed

+3
-551
lines changed

8 files changed

+3
-551
lines changed

AnkiDroid/build.gradle

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,6 @@ android {
143143
// make the icon red if in debug mode
144144
resValue 'color', 'anki_foreground_icon_color_0', "#FFFF0000"
145145
resValue 'color', 'anki_foreground_icon_color_1', "#FFFF0000"
146-
resValue "string", "applicationId", "${defaultConfig.applicationId}${applicationIdSuffix}"
147146
}
148147
named('release') {
149148
testCoverageEnabled = testReleaseBuild
@@ -157,9 +156,6 @@ android {
157156
if (project.hasProperty("customSuffix")) {
158157
// the suffix needs a '.' at the start
159158
applicationIdSuffix project.property("customSuffix").replaceFirst(/^\.*/, ".")
160-
resValue "string", "applicationId", "${defaultConfig.applicationId}${applicationIdSuffix}"
161-
} else {
162-
resValue "string", "applicationId", defaultConfig.applicationId
163159
}
164160
if (project.hasProperty("customName")) {
165161
resValue "string", "app_name", project.property("customName")

AnkiDroid/src/main/AndroidManifest.xml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -501,12 +501,6 @@
501501
android:configChanges="keyboardHidden|orientation|screenSize"
502502
android:label="@string/download_deck"
503503
android:theme="@style/Theme.MaterialComponents.NoActionBar" />
504-
<activity
505-
android:name="com.ichi2.anki.LoginActivity"
506-
android:label="@string/menu_my_account"
507-
android:exported="false"
508-
android:configChanges="keyboardHidden|orientation|screenSize"
509-
/>
510504

511505
<activity android:name=".IntroductionActivity"
512506
android:exported="false"

AnkiDroid/src/main/java/com/ichi2/anki/IntroductionActivity.kt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ import androidx.activity.result.ActivityResult
2424
import androidx.activity.result.contract.ActivityResultContracts
2525
import androidx.core.content.edit
2626
import androidx.core.os.BundleCompat
27+
import com.ichi2.anki.account.AccountActivity
2728
import com.ichi2.anki.common.annotations.NeedsTest
2829
import com.ichi2.anki.introduction.SetupCollectionFragment
2930
import com.ichi2.anki.introduction.SetupCollectionFragment.CollectionSetupOption
@@ -73,7 +74,8 @@ class IntroductionActivity : AnkiActivity() {
7374

7475
private fun openLoginDialog() {
7576
Timber.i("Opening login screen")
76-
onLoginResult.launch(Intent(this, LoginActivity::class.java))
77+
val intent = AccountActivity.getIntent(this)
78+
onLoginResult.launch(intent)
7779
}
7880

7981
private fun startDeckPicker(result: Int = RESULT_START_NEW) {

AnkiDroid/src/main/java/com/ichi2/anki/LoginActivity.kt

Lines changed: 0 additions & 80 deletions
This file was deleted.

0 commit comments

Comments
 (0)