Skip to content

Commit 4e1bfec

Browse files
committed
refactor: remove old MyAccount activity
- update usage to new LoginFragment fix: multimedia uri security exception
1 parent 34ef2d0 commit 4e1bfec

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
@@ -142,7 +142,6 @@ android {
142142
// make the icon red if in debug mode
143143
resValue 'color', 'anki_foreground_icon_color_0', "#FFFF0000"
144144
resValue 'color', 'anki_foreground_icon_color_1', "#FFFF0000"
145-
resValue "string", "applicationId", "${defaultConfig.applicationId}${applicationIdSuffix}"
146145
}
147146
named('release') {
148147
testCoverageEnabled = testReleaseBuild
@@ -156,9 +155,6 @@ android {
156155
if (project.hasProperty("customSuffix")) {
157156
// the suffix needs a '.' at the start
158157
applicationIdSuffix project.property("customSuffix").replaceFirst(/^\.*/, ".")
159-
resValue "string", "applicationId", "${defaultConfig.applicationId}${applicationIdSuffix}"
160-
} else {
161-
resValue "string", "applicationId", defaultConfig.applicationId
162158
}
163159
if (project.hasProperty("customName")) {
164160
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)