Damien Elmes
e764e68324
store sync state in a struct, and reuse ctx across methods
2020-02-17 08:40:16 +10:00
Damien Elmes
78bfbef863
media sync working, but unpolished
2020-02-17 08:40:16 +10:00
Damien Elmes
b2b8370477
bump nightly for the unwrap source line fix
2020-02-17 08:40:16 +10:00
Damien Elmes
973d8c56d6
more refactoring
2020-02-17 08:40:16 +10:00
Damien Elmes
7430d3c64f
rearrange some methods to make structure clearer
2020-02-17 08:40:16 +10:00
Damien Elmes
1acb3b86b9
backend init can now fail, and update media db when file is added
...
- Adding files inside Anki now updates the media DB, so a full file
scan at sync time is no longer required if no other changes have been
made.
- Use a protobuf message for backend initialization, and return a
string error if initialization fails.
2020-02-17 08:40:16 +10:00
Damien Elmes
6bf4b9e83e
port change tracking
2020-02-17 08:40:16 +10:00
Damien Elmes
4f08ae9e27
make sure results are checked
2020-02-17 08:40:16 +10:00
Damien Elmes
9bc38647e6
initial rs implementation of media database
2020-02-17 08:40:16 +10:00
Damien Elmes
05e269e20f
run rs checks before setting up py env
2020-02-17 08:40:16 +10:00
Damien Elmes
9a280897d3
drop support for vfat
2020-02-17 08:40:16 +10:00
Damien Elmes
c8ea895cae
drop support for the early 2.0 release media db format
2020-02-17 08:40:16 +10:00
Damien Elmes
1102983a4e
drop the clean* funcs
2020-02-17 08:40:16 +10:00
Damien Elmes
c9a5ed3cc6
add add_file() and write_data()
2020-02-17 08:40:16 +10:00
Damien Elmes
9ec6d26db7
add another implementation of media.addFile() and cleanFilename() et al
...
Instead of adding an incrementing number in the conflict case,
the file hash is appended.
2020-02-17 08:40:16 +10:00
Damien Elmes
dee114df63
put head text after css/js imports so it can override them
...
as discussed in PR #438
2020-02-17 08:38:59 +10:00
Damien Elmes
2085bb1a99
bump version
2020-02-16 08:50:10 +10:00
Damien Elmes
415cb15661
Merge pull request #447 from glutanimate/browser-sidebar-tree-hooks
...
Add browser_will_build_tree filter
2020-02-16 08:36:28 +10:00
Damien Elmes
f6bad7b9c3
Merge pull request #445 from glutanimate/new-html-view-hooks-2
...
Allow add-on authors to easily inject their own content into Anki's web views – take 3
2020-02-16 08:32:34 +10:00
Glutanimate
b7e0d4388a
Add browser_will_build_tree filter
...
Allows add-ons to populate the browser sidebar tree with their own
items, and/or take over specific construction stages in their
entirety
2020-02-15 21:03:15 +01:00
Glutanimate
356eda66f4
Update documentation for webview_will_set_content and WebContent
2020-02-15 15:03:58 +01:00
Glutanimate
28a394a074
Assume that web assets without a specified subpath are under /_anki
...
Maintains compatibility with existing add-ons
2020-02-15 15:03:43 +01:00
Damien Elmes
36393aa7a5
Merge pull request #444 from Arthur-Milchior/preFlushHooks
...
Pre flush hooks
2020-02-15 12:39:15 +10:00
Arthur Milchior
16f40c9a01
Hook card_is_being_flushed
...
It often arrives that I want to know when a card is going to be
flushed and in this case change it.
This could be the case if I want to change the scheduler without
implementing a whole scheduler. It simply reads the card history and
change interval and due date.
It's also the case for the "'trigger -> action' rules", which apply
some coded actions when some event occurs. E.g. suspend/unsuspend a
sibling when card become mature/is forgotten.
2020-02-14 00:59:32 -08:00
Arthur Milchior
347523b442
Factorizing card's flush
2020-02-14 00:59:32 -08:00
Arthur Milchior
4b632b398e
hook note_is_being_flushed
...
I created multiple add-ons which want to transform a note before it is
being saved. For example, one add-on trim it, and remove useless line
break which arrived by accident.
Another add-on want to compile LaTeX as soon as the note is done, and
warn the user if LaTeX can't be compiled.
Having a hook in pre-flush would be useful here
2020-02-14 00:57:27 -08:00
Damien Elmes
3d1e89f014
Merge pull request #433 from Arthur-Milchior/ints
...
Constants
2020-02-14 08:37:31 +10:00
Damien Elmes
edc37c991b
Merge pull request #446 from ijgnd/patch-1
...
small fix: store return value for hook in preview
2020-02-14 07:14:18 +10:00
ijgnd
e39d18647f
small fix: store return value for hook in preview
2020-02-13 18:51:11 +01:00
Glutanimate
f2f16903b6
Fix "js" parameter type
2020-02-12 22:20:30 +01:00
Glutanimate
ffdafaee6d
Fix missing "Optional" import and lint
2020-02-12 22:15:44 +01:00
Glutanimate
7e213bdcd5
Pass CardInfoDialog context to stdHtml
2020-02-12 22:12:45 +01:00
Glutanimate
d7836e3af8
Add webview_will_set_content hook & update supporting code accordingly
2020-02-12 22:00:13 +01:00
Glutanimate
88b5d94513
Refactor web view title setting and add titles to all web views
...
Simplifies debugging web views
2020-02-12 21:03:11 +01:00
Damien Elmes
5faaf35eec
fix odd outline in replay button, and center align
...
https://anki.tenderapp.com/discussions/beta-testing/1708-anki-2120-beta#comment_48079637
2020-02-12 09:18:32 +10:00
Damien Elmes
faded8f56d
study screen -> overview screen wording
...
This is a test change to see how Crowdin handles wording tweaks
2020-02-12 09:02:48 +10:00
Damien Elmes
369c810778
update translations
2020-02-12 08:59:14 +10:00
Damien Elmes
084e059508
constrain editor and reviewer image width to container width
...
view height still makes more sense in the reviewing screen so images
are relative to the window instead of the document
2020-02-12 08:33:55 +10:00
Damien Elmes
89f926f177
night mode fix for find dupes screen
2020-02-12 08:28:33 +10:00
Damien Elmes
e64b1e0ca2
provide easy access to browser from preview/dupes handlers
2020-02-12 08:28:21 +10:00
Damien Elmes
27dabaeaa6
tweak wording
2020-02-12 08:14:16 +10:00
Damien Elmes
f8338b094d
move export notes action to the notes menu
2020-02-12 08:09:12 +10:00
Damien Elmes
5e44fb0304
remove redundant declaration
2020-02-12 08:06:35 +10:00
Damien Elmes
ce6a9ed17a
document annotations
2020-02-12 08:05:40 +10:00
Damien Elmes
846fa49b51
Merge pull request #443 from Arthur-Milchior/exportFromBrowserInAnki
...
Export from browser in anki
2020-02-12 08:05:26 +10:00
Arthur Milchior
097e6d4b46
Adding export option in Browser
2020-02-11 10:50:59 -08:00
Arthur Milchior
c16a3954fa
browser._exporting
2020-02-11 10:50:59 -08:00
Arthur Milchior
078a10ae55
Replace list of deck by "Browser Selection"
2020-02-11 10:50:59 -08:00
Arthur Milchior
9c158e615e
if cards are selected, default is apkg
2020-02-11 10:50:59 -08:00
Arthur Milchior
48339784cc
deckIds return deck of selected cards
2020-02-11 10:50:59 -08:00