Commit Graph

42 Commits

Author SHA1 Message Date
Damien Elmes
8e944c6a02 fix schema not being modified on backup import 2019-02-14 15:22:57 +10:00
Damien Elmes
372d5ed6e8 update copyright and clarify licenses 2019-02-05 14:01:33 +10:00
Damien Elmes
429cb2ce7f fix import screen appearing before progress dialog closes 2018-12-01 13:37:26 +10:00
Damien Elmes
8489f84937 catch .anki(2) imports 2018-09-27 11:35:21 +10:00
Damien Elmes
53f0793b9e clean up deck chooser hook on importer close
fixes
https://anki.tenderapp.com/discussions/ankidesktop/20841-editingimport-limitation#comment_44777511
2018-03-01 14:20:30 +10:00
Damien Elmes
8a15bc897b fix importing of v2 colpkg files 2018-02-05 15:30:57 +10:00
Damien Elmes
0cce540d83 enforce schema version; allow importing+exporting v2 scheduler
To avoid all sorts of problems, we need to ensure cards scheduled with
the V2 scheduler are not studied in older clients. Unfortunately we
can't just bump the file's schema version, as the existing clients will
freely import files created with newer versions. This patch changes
that, so things should be a bit easier in the future.

In the mean time, we need a way to prevent older clients from importing
files created with the V2 scheduler. To do this, we switch to using a
'collection.anki21' file in the archive, and include a dummy collection
.anki2 file.

The code has been tested with both deck and collection packages, but
exporting deck packages w/ scheduling info will remain disabled until
the V2 scheduler has had more testing.
2018-01-29 14:12:04 +10:00
Damien Elmes
fad6b244cd normalize filenames in colpkg import 2017-09-30 19:29:21 +10:00
Damien Elmes
0c80b5454f use separate .colpkg extension for collection exports
- allows translations of filename
- allows users to keep multiple collection exports in the same folder
- provides a clearer distinction between deck and collection packages
- the collection/backup .apkg special cases will continue to work in
future 2.1.x releases
2017-09-10 16:58:55 +10:00
Damien Elmes
a66c5f555f revamp profile manager
- use a main window instead of a dialog, so the menu items of the main
window don't appear while the profile window is active on OS X
- the profile manager now has a button to automatic restoring from
backup, which will prevent old backups from being clobbered
- drop support for profile passwords
- do the right thing when user quits from the menu in profile manager
mode
2017-08-16 19:45:39 +10:00
luoliyan
e892a30728 Fix error caused by converting delimiter to bytes 2017-02-15 18:45:04 +09:30
luoliyan
7002a2a4f8 Handle invalid delimiters more gracefully 2017-02-13 21:42:19 +09:30
noobie
90128cf2d5 Fix the lambda function for changing the mapping of the fields
The connect signal passes a bool to the given function by default, we need to ignore it.

use underscore for the sake of idiomology
2016-10-19 22:45:46 +02:00
Damien Elmes
44457e78d2 fix import of media 2016-07-11 14:56:58 +10:00
Damien Elmes
de7e40537d port majority of code to qt5.5+
- a few issues to work out still, and editor changes not done yet
- for communication between webengine and python code, we set window
.location to 'http://anki/<something>' - the leading http is
necessary for qt to call the link handler, which was introduced
in qt5.5
- the designer files now use a promoted qobject to create instances
of AnkiWebView
- we use the css zoom property to alter webengine font size based on
system dpi
- prefs and addons folder stored in new location (at least for now)
2016-05-31 18:51:40 +10:00
Damien Elmes
15b349e3a8 start port to python 3
unit tests pass and main screens of GUI load
2016-05-12 14:45:35 +10:00
Damien Elmes
3bbd0bca7e zip64 support, and import/export improvements
- we now allow exports over 2gb/64k files - AnkiMobile and AnkiDroid
will need to be updated to support this
- avoid compressing media files in export, as in the common case of
jpg/mp3 it's much faster with no increase in size
- exports and imports now show # of files processed
- mw.progress.update() now limits # of updates per sec
2016-02-26 10:01:46 +10:00
Soren I. Bjornstad
9ec91724bf catch more invalid zip file errors 2014-09-27 10:19:43 -05:00
Soren I. Bjornstad
a479bc7c48 change "discard field" to "ignore" in text importer
A user pointed out that once selected it said "ignore" and that
"discard" threatened that the information might be deleted.
2014-08-11 10:31:48 -05:00
Damien Elmes
0abcc7412f initial zip check should display same zip error message 2014-06-29 05:55:01 +09:00
Soren I. Bjornstad
ebcab2122d more helpful error message for corrupt collection package 2014-06-17 16:55:55 -05:00
Soren I. Bjornstad
6771af40b1 fix error handling for selecting invalid file type
(The error was never appearing because the test was missing quotation
marks.)
2014-06-17 08:31:38 -05:00
Houssam Salem
068a63270d Changed location of import button (#1018).
Also updated help link in same window to point to a valid anchor.
2014-02-22 21:30:32 +11:00
Damien Elmes
b97f913ba1 catch another invalidTempFolder msg 2014-02-03 01:51:51 +09:00
Damien Elmes
1f05392113 change default import mode to ignore updates 2013-11-26 18:19:54 +09:00
Damien Elmes
be81d282ac catch temp folder issue when importing 2013-11-07 21:57:23 +09:00
Damien Elmes
4a9c08014e return of the evil bytestring windows exceptions 2013-10-20 11:01:57 +09:00
Damien Elmes
bd8707f54c support import of renamed .apkg files 2013-09-11 15:56:59 +09:00
Damien Elmes
31c42a4f75 fix import when dyn deck selected (#959) 2013-09-04 03:13:02 +09:00
Damien Elmes
9d173f4c83 default to allowing HTML on import 2013-06-10 15:03:26 +09:00
Damien Elmes
400571306a better warning when apkg invalid 2013-05-17 14:22:49 +09:00
ospalh
4ff2c76ecf Turn method importing.ImportDialog._unicodeWarning() into a function. 2013-05-03 14:39:48 +02:00
Damien Elmes
ce9e09d4c5 changes for qt5 on mac
- setShown() -> setVisible()
- qt_mac_set_menubar_icons() no longer exported, use alternative method
2013-04-15 13:46:07 +09:00
Damien Elmes
8f8e3c3587 fix ext reference 2013-02-27 14:06:10 +09:00
Andreas Klauer
6562188ae8 Support combined file extensions (*.pau.gz instead of just *.gz) 2013-02-24 02:09:03 +01:00
Damien Elmes
3048a8e137 catch more unicode errors on import, and improve error msg 2013-01-15 07:10:26 +09:00
Damien Elmes
df961cc509 remember import mode 2013-01-08 10:32:41 +09:00
Damien Elmes
289f0a6452 automatically fix 1.2 errors when upgrading 2013-01-08 09:43:29 +09:00
Damien Elmes
be7b293b15 remember allowHTML setting 2012-12-22 13:18:28 +09:00
Damien Elmes
b2457811a2 optimize imports 2012-12-22 09:17:10 +09:00
Damien Elmes
73f8d1a457 force full sync when restoring from backup 2012-12-22 08:34:11 +09:00
Damien Elmes
d477df8c28 merged libanki and ankiqt into single distro 2012-12-21 16:51:59 +09:00