0
0
mirror of https://github.com/ankidroid/Anki-Android.git synced 2024-09-20 20:03:05 +02:00
Commit Graph

16062 Commits

Author SHA1 Message Date
Damien Elmes
1f87d553ff CollectionV16.load() doesn't need to read from col table
scm/ls are fetched on demand now, since backend methods may mutate
them.
2022-07-21 19:06:57 -05:00
Damien Elmes
fd8557c286 Fix full sync not being forced in new backend
Closes #11732
2022-07-21 19:06:57 -05:00
Damien Elmes
43ff0cd0c1 Fix DB check in new backend
https://github.com/ankidroid/Anki-Android/pull/11644#issuecomment-1169380381

Closes #11735
2022-07-21 19:06:57 -05:00
Damien Elmes
46c4f4d501 Fix slow browser load in new backend
https://github.com/ankidroid/Anki-Android/pull/11644#issuecomment-1169380381

Closes #11733
2022-07-21 19:06:57 -05:00
shaiguelman
54c8426f8c
Fix crash during deck filtering (#11880)
Fixes a `ConcurrentModificationException`: the wrong list was modified

* Create copy of list when filtering

* Optimize containsFilterString

* Add error catching

* Remove whitespace

* Add comment and better naming

* Rename usage of childrenCopy variable I forgot to rename

* Change to more efficient solution

* Remove unecessary comment

* Add unit tests for DeckFilter

* Remove unused imports

* Add copywrite

* Remove whitespace

* Format fixes

* Add last name to dictionary

* Flipped actual and expected in assert statement

* Removed try/catch block in publishResults()

* Remove unused import

* Added null check

* Revert "Optimize containsFilterString"

This reverts commit 5b617b03f6.

* Reverting to using !! operator on results

* Rename test method
2022-07-21 12:36:37 +01:00
Brayan Oliveira
a84305ed25 Fix preferences textColorSecondary 2022-07-21 09:36:07 +01:00
David Allison
5e508ccbc4 fix: 'pureAnswer' works with well-formed HTML
previously "<hr id="answer">" failed due to the quotes

Fixes 11442
2022-07-20 16:15:48 -05:00
Mani
08873a7d36 return type for set graph prefs 2022-07-20 09:52:19 +01:00
Arthur Milchior
36c52773ef NF: findOneCardByNote
Allow to improve card browser's note mode by ensuring that one card by note is
directly queried.

This is temporary code, since back-end will ensure we get this feature
efficiently in Rust.
2022-07-19 18:06:19 -05:00
dorrin-sot
27ffca5a55 Migrate Atom to Kotlin 2022-07-19 18:33:02 +01:00
dorrin-sot
f955fa206f Rename .java to .kt 2022-07-19 18:33:02 +01:00
Mike Hardy
03c1af7503 Bumped version to 2.16alpha74 2022-07-19 16:27:40 +00:00
lukstbit
bfa4bf52b9 Migrate ForegroundTaskManager.java to kotlin 2022-07-19 10:27:43 -05:00
lukstbit
ee466a0ff6 Rename ForegroundTaskManager.java to .kt 2022-07-19 10:27:43 -05:00
AnkiDroid Translations
a67e902398 Updated strings from Crowdin 2022-07-19 10:26:54 -05:00
oyeraghib
805b5c6178 refactor: updated the comment for string "menu_add" 2022-07-19 02:24:56 -05:00
oyeraghib
ddcbb38eb9 refactor: Replace "Add Note" by "Add" at multiple places
replace string "Add Note" with "Add" for FAB, Note Editor, Card Browser menu etc
2022-07-19 02:24:56 -05:00
AnkiDroid Translations
a8d1031247 Updated strings from Crowdin 2022-07-19 02:24:43 -05:00
David Allison
925b5cef65 fix: deck_picker_dialog Layout Preview
Designer only:

* deck_picker_dialog_list_item now appears in context
* Menu has been added
* Toolbar title added
* 'summary' text added
2022-07-19 06:22:16 +01:00
David Allison
0e49406de8 fix: Set theme to Theme_Light for Layout Designer
Should only affect the Android Studio layout preview (designer).

If unset, the default is `Material.Light`, which does not
preview correctly (no blue menu bar at the top).

This has been tested and does not seem to have a functional effect on
the app.

If it does have a functional change, this change may be reverted

- the default theme for all activities, but we call `Themes.setTheme`
inside AnkiActivity, so this should only affect the layout designer.

https://developer.android.com/guide/topics/manifest/application-element#theme
2022-07-19 06:22:16 +01:00
lukstbit
3671b4d7b1 Fix disabled "Choose another" button in restore backup selection dialog 2022-07-18 19:30:37 -05:00
Arthur Milchior
700b0377e8
Add translators to the credits (#11828)
We don't interact with them a lot (and thanks for crowdin for it. Interacting with 1400 people would be a managerial nightmare), but they entirely deserve credits. Also, I can't cease to be amazed to have that many people spending their time to improve our app.
2022-07-18 19:20:07 -05:00
Akshit Sinha
41f2345192 Add getThemedColor() function in themes package 2022-07-18 19:41:56 +01:00
Akshit Sinha
35f74f018e Add SearchNotes() function 2022-07-17 16:20:33 -05:00
Brayan Oliveira
dafbbf7c19 Add summary providers for the custom buttons screen 2022-07-17 21:01:21 +01:00
Akshit Sinha
bcb9fdc209 Fix Flag Color 2022-07-17 14:27:54 -05:00
Brayan Oliveira
634737cc77
[GSoC] NF: Move all preferences keys to constants on preferences.xml (#11866)
* refactor: Organize reviewing constants

* refactor: Organize sync constants

* refactor: Organize general constants

* refactor: Organize appearance constants

* refactor: Organize controls constants

* refactor: Organize accessibility constants

* refactor: Organize advanced constants

* refactor: Organize App Bar buttons constants

* refactor: Organize Custom sync server constants

* refactor: Organize last Advanced screen constants

* refactor: Organize Headers constants

* refactor: Organize constants inside preferences.xml

Move the constants to be below their respective category headers
2022-07-17 14:19:46 -05:00
lukstbit
42c4d9fa17 Migrate DeckPickerTest.java to kotlin 2022-07-17 11:45:04 -05:00
lukstbit
4990d53d7f Rename DeckPickerTest.java to .kt 2022-07-17 11:45:04 -05:00
Brayan Oliveira
7b0067bd29 refactor: About layout and message
Join the `about_base_layout` and `about_scrollable_layout` as I've fixed the problem with previewing

Add a comment explaining why `dev_options_enabled_msg` isn't translated
2022-07-17 16:55:28 +01:00
Brayan Oliveira
38cde0f7f4 Add dev options secret on About screen's logo
tap 6 times to reveal it
2022-07-17 16:55:28 +01:00
Brayan Oliveira
3dbe585e6d Factorize dev options 2022-07-17 16:55:28 +01:00
Brayan Oliveira
47857d3ad0 Add new about section
And remove the code of the previous About section from `Info.kt`

The `Info.kt` activity can't be removed yet entirely because it is still used to show the changelog

Remove `InfoTestNoOnCreate.kt` because it was only used to check if the app wouldn't crash while building the HTML string for the old about screen
2022-07-17 16:55:28 +01:00
Akshit Sinha
9b077050c1 Fix Apply button crashing on no selection 2022-07-17 14:03:43 +01:00
Divyansh Kushwaha
b7583d13cd refactor: Convert Syncer to Kotlin
com.ichi2.libanki.sync.Syncer
2022-07-17 12:55:57 +01:00
Divyansh Kushwaha
287f341575 refactor: Rename Syncer.java to .kt
com.ichi2.libanki.sync.Syncer
2022-07-17 12:55:57 +01:00
Arthur Milchior
c0a9657a3a NF: Remove TaskOperations
It's last use was remove in 189886a782
2022-07-16 13:43:21 +05:30
Divyansh Kushwaha
e82e5fac00 refactor: Convert FullSyncer to Kotlin
com.ichi2.libanki.sync.FullSyncer
2022-07-16 13:39:11 +05:30
Divyansh Kushwaha
8cdcebece1 refactor: Rename FullSyncer.java to .kt
com.ichi2.libanki.sync.FullSyncer
2022-07-16 13:39:11 +05:30
Akshit Sinha
f0e4ceb623
[GSoC] Filter Sheet: Add filters for flags (#11713)
* Filter bottom sheet with filters for flags created

* Add `FilterItemFlag` class and add delay to avoid double tap

`FilterItemFlag` class makes it cleaner and easier to add search queries

* Delete unused resources

* Change class name to match File name, Update strings, remove `@Suppress("deprecated")`,
make DELAY_TIME const

* Use enum class to represent flags

* Use enum class to represent flags

* Add No Flag option, remove hungarian notation

* Use searchNodes to create query string, Add Flag Icons to options

change type of FlagNumber from Int to SearchNode.Flag

use .apply{ } to avoid repetition

Other minor fixes

* Change onFlagItemClicked, change variable name of flagNumber, Move no flag to first position, create isSelected boolean to check if a filter is selected
2022-07-15 16:54:49 +02:00
Nishant
3421f66cf0 Replaced String.format in Info
Signed-off-by: Nishant <getrooted0019@hotmail.com>
2022-07-14 22:32:09 -05:00
Divyansh Kushwaha
31cfbc914a refactor: Convert TaskManager to Kotlin
com.ichi2.async.TaskManager
2022-07-14 21:56:26 -05:00
Divyansh Kushwaha
184f5725e7 refactor: Rename TaskManager.java to .kt
com.ichi2.async.TaskManager
2022-07-14 21:56:26 -05:00
oyeraghib
9c96f8f155 cleanup: remove extra comment
The comment does not make sense here now, as this is handled in LoadPronunciation Activity.
2022-07-14 21:24:06 -05:00
Prince kushwaha
e4febacb0d Migrate DecksTest.java to kotlin 2022-07-14 21:23:07 -05:00
Prince kushwaha
b9d2182585 Rename DecksTest.java to DecksTest.kt 2022-07-14 21:23:07 -05:00
Arthur Milchior
b931e9667a Removing duplicate "contributor"
I also renamed it to "code contributor", as I feel it's a more exact description. Github is technically true, but not really interesting. Also, technically, translations also ends on github, and the authors are not listed
2022-07-14 21:13:01 -05:00
Divyansh Kushwaha
639cf0d0f9 refactor: Convert HttpSyncer to Kotlin
com.ichi2.libanki.sync.HttpSyncer
2022-07-14 21:08:50 -05:00
Divyansh Kushwaha
e3893d8231 refactor: Rename HttpSyncer.java to .kt
com.ichi2.libanki.sync.HttpSyncer
2022-07-14 21:08:50 -05:00
gradle-update-robot
67afbc3559 Update Gradle Wrapper from 7.4.2 to 7.5.
Signed-off-by: gradle-update-robot <gradle-update-robot@regolo.cc>
2022-07-14 21:06:24 -05:00