Commit graph

3772 commits

Author SHA1 Message Date
Dan Stillman
bf0de6e02f Tidy up some debug messages at startup 2013-08-12 03:10:09 -04:00
Dan Stillman
4a861ef5ea Use promise to get addon version, and remove ZOTERO_CONFIG.VERSION
(This patch is small without whitespace changes.)
2013-08-12 03:06:54 -04:00
Dan Stillman
391b2085b3 Tie bundled files update to initialization rather than timeout 2013-08-12 02:49:26 -04:00
Dan Stillman
5787b230f7 Use asynchronous DB and file access for schema checks/updates
This change should improve Firefox startup time. If the Zotero pane is
opened before Zotero has initialized, the pane will be blocked with a
progress bar until it's done. Standalone currently does the same, but it
should be changed to just delay opening the window if possible.

The upgrade wizard has been disabled for schema upgrades, in the hope
that upgrades can be done in a way that won't break compatibility with
earlier versions (or that can at least be done in a way such that we can
put out point releases of the last major version that provide
compatibility during beta/post-upgrade periods).

This patch likely breaks many things, and definitely breaks connector
mode.

This change also removes upgrade steps for databases from Zotero 2.1b2
and earlier. Users with such databases will need to upgrade via Zotero
4.0.x first or delete their data directories and start anew. This should
only affect users who haven't opened Zotero since Nov. 2010.
2013-08-11 21:53:41 -04:00
Dan Stillman
2b4de89aaf Add Zotero.File.getContentsFromURLAsync(url) for local text files 2013-08-11 20:49:18 -04:00
Dan Stillman
43978624de Better error messages for async DB 2013-08-11 20:48:10 -04:00
Dan Stillman
9e2d872900 Support nested async DB transactions 2013-08-11 20:47:53 -04:00
Dan Stillman
a2816a10ca Return a Q promise from all async DB methods
With send() removed from Q, we can yield Q promises within
executeTransaction() instead of Mozilla promises.
2013-08-10 04:17:34 -04:00
Dan Stillman
957b649fa8 Remove another <Fx23 test 2013-08-10 00:02:57 -04:00
Dan Stillman
2c424c2b58 Take out unnecessary <Fx23 test 2013-08-10 00:00:05 -04:00
Dan Stillman
b2d46ee2fe Merge branch '4.0'
Conflicts:
	chrome/content/zotero/xpcom/db.js
	chrome/content/zotero/xpcom/zotero.js
	install.rdf
	update.rdf
2013-08-09 12:48:44 -04:00
Dan Stillman
2dc8fc6912 Update versions 2013-08-09 11:50:10 -04:00
Simon Kornblith
a723c85999 Return a promise from Zotero.shutdown() 2013-08-09 11:11:01 -04:00
Simon Kornblith
8a8093028d Check if callback exists before calling 2013-08-09 11:00:55 -04:00
Simon Kornblith
2069b5b396 Fix switching in and out of connector mode
Broken by 9d3f55be51
2013-08-09 10:55:56 -04:00
Dan Stillman
8f0dac0eb4 Update version and styles 2013-08-08 15:24:47 -04:00
Dan Stillman
a954d94027 Add missing semicolon 2013-08-08 15:21:11 -04:00
Dan Stillman
d5fcde0612 Disable OS.File for file syncs on Windows <Fx25
stat.lastModificationDate returns the last access date
instead of the modification date due to bug
https://bugzilla.mozilla.org/show_bug.cgi?id=899436
2013-08-08 15:19:37 -04:00
Dan Stillman
84c5a1bffa Tweak error message for OS.File errors during file sync 2013-08-08 14:32:54 -04:00
Dan Stillman
c29720743a Fix file sync error in Gecko 23+ if local file path is too long 2013-08-08 14:31:53 -04:00
Dan Stillman
610017e4df Fix file sync error on Windows 2013-08-08 14:15:41 -04:00
Dan Stillman
4af73f4a52 Fix file sync error in Fx23+ for empty attachment paths
And fix reporting of non-OS.File file sync errors
2013-08-08 13:41:34 -04:00
Dan Stillman
bfaa0f1172 Merge branch '4.0'
Conflicts:
	chrome/content/zotero/xpcom/db.js
	chrome/content/zotero/xpcom/zotero.js
	install.rdf
	update.rdf
2013-08-08 01:06:35 -04:00
Dan Stillman
8bdac7015b Focus title on shortcut key new item even if item type isn't changed 2013-08-07 20:28:17 -04:00
Simon Kornblith
e132787774 Move root check to before DB initialization 2013-08-07 18:32:40 -04:00
Simon Kornblith
0957f8de02 Merge branch 'zap-cache' into 4.0 2013-08-07 18:00:40 -04:00
Simon Kornblith
517ca6f342 Force quit after zapping cache files to prevent destroying prefs 2013-08-07 18:00:25 -04:00
Dan Stillman
2bd0019261 'let' is valid in XBL, just not in event attributes, I guess 2013-08-07 17:09:41 -04:00
Dan Stillman
a3375d540b Fix comment that broke 7572eebcd 2013-08-07 17:06:48 -04:00
Dan Stillman
7572eebcd1 Offer autocomplete of same creator for different creator types
If a creator exists on an item but is a different creator type than the
one being entered, show creator in autocomplete list.
2013-08-07 15:25:15 -04:00
Dan Stillman
39e92bacb3 Focus title field when creating new item via menu or shortcut key 2013-08-07 13:17:25 -04:00
Dan Stillman
9d3f55be51 Use async DB for autocomplete
This was probably hanging previously because I was passing a JS function for
onProgress, which apparently isn't allowed.
2013-08-07 11:01:12 -04:00
Dan Stillman
08296b06a5 Include libraryID in file sync debug message 2013-08-06 16:03:03 -04:00
Dan Stillman
b20a7a572c Disable some debug logging for file syncing 2013-08-06 16:02:49 -04:00
Dan Stillman
8b918b21ad Capitalize Q library in About pane 2013-08-06 15:49:45 -04:00
Dan Stillman
795211fb40 Focus Close button by default in About pane 2013-08-06 15:49:26 -04:00
Dan Stillman
5b09b1e2be Update submodules, repotime, and versions 2013-08-06 15:23:04 -04:00
Dan Stillman
97f662fe67 Fix note resetting in external note window during file syncing
https://forums.zotero.org/discussion/29008
2013-08-05 20:47:50 -04:00
Dan Stillman
675fde2f1a Use async I/O for attachment (blue dot) column file check in Fx23+ 2013-08-05 16:31:23 -04:00
Dan Stillman
f341bb1ae0 Fix error exporting linked HTML file
https://forums.zotero.org/discussion/29392/#Item_14
2013-08-04 23:30:28 -04:00
Dan Stillman
1117332177 Merge branch '4.0'
Conflicts:
	chrome/content/zotero/xpcom/zotero.js
2013-08-03 18:12:36 -04:00
Dan Stillman
1267c4d659 Closes #77, Create linked files with drag and drop
The cursor effect doesn't work reliably anywhere other than on Linux,
but external files can now be linked instead of stored with
Cmd-Option-drag on OS X and Ctrl-Shift-drag on Win/Linux.
2013-08-03 18:08:09 -04:00
Dan Stillman
84d9963e14 File sync optimizations 2013-08-02 01:13:27 -04:00
Dan Stillman
e177e3e718 Optimize local file modification checks during file syncs
- On manual sync or the first auto-sync of a session, check all files
- During other auto-syncs, check only files previously modified or
  opened externally via Zotero (including Show File) within the last 3
  hours
- Every 3 hours, do a full check of all files even if it's an auto-sync
- Spin event loop during synchronous file checks to avoid hanging the UI
- Zotero.Sync.Runner.sync() now takes an options object (e.g.,
  options.background)

Todo:

- Provide feedback on last full check in sync icon tooltip?
- Auto-sync on app focus, if this speeds up syncs enough?
2013-08-02 00:45:26 -04:00
Dan Stillman
dc8998c5bc Add Firefox-wide shortcut (Ctrl/Cmd-Shift-S) for "Save to Zotero"
Also: Don't show Firefox-specific shortcut keys in Standalone prefs
2013-07-31 23:19:19 -04:00
Dan Stillman
f0c5c50bd4 Blacklist Firefox HealthReport errors 2013-07-30 15:48:53 -04:00
Dan Stillman
ec47a31000 Fix warning in Nightly about yield without a value 2013-07-29 02:26:09 -04:00
Dan Stillman
2736e7e6d1 Use Ctrl-Shift for all shortcuts on Windows/Linux instead of Ctrl-Alt
https://forums.zotero.org/discussion/25927/#Item_5
2013-07-28 20:18:24 -04:00
Simon Kornblith
670f272b32 Alter message on auto-update
Avoid ambiguously implying that Linux users should be running Zotero as
root, and tell them to fix the permissions on the Zotero executable instead.

See https://forums.zotero.org/discussion/31020/
2013-07-27 01:46:13 -04:00
Dan Stillman
b059b2abde Fix shortcut keys on Windows and Linux 2013-07-26 15:35:06 -04:00