Commit graph

8 commits

Author SHA1 Message Date
Dan Stillman
ede03f4366 Update some Sinon reset() calls
In Sinon 2, reset() now resets both behavior and history, so if a stub
specifies behavior and we want to use it again, we have to call
resetHistory().
2017-06-01 15:39:42 -04:00
Dan Stillman
2320385fa8 Sync pane caption: "Zotero Data Sync" -> "Data Syncing" 2016-09-24 02:29:20 -04:00
Dan Stillman
f68ee60524 Follow-ups to getAPIKey() changes in 008321bb89
Addresses #1086
2016-09-05 04:00:55 -04:00
Adomas Ven
11e7cef057 Show hard warning dialog when unlinking or linking to a different account (#1047)
And give option to delete local data when unlinking

This removes the old behavior of merging accounts when syncing with a different username.
2016-06-27 12:40:38 -04:00
Dan Stillman
098655d913 Prompt about username change at sync time, not just in prefs
This is necessary because you can copy a database synced with a
different account into the data directory without affecting the stored
pref.

Also tweak the text to use proper quotes and remove quaint references to
"the server".
2016-04-26 18:12:20 -04:00
Dan Stillman
daf4a8fe4d Deasyncification 🔙 😢
While trying to get translation and citing working with asynchronously
generated data, we realized that drag-and-drop support was going to
be...problematic. Firefox only supports synchronous methods for
providing drag data (unlike, it seems, the DataTransferItem interface
supported by Chrome), which means that we'd need to preload all relevant
data on item selection (bounded by export.quickCopy.dragLimit) and keep
the translate/cite methods synchronous (or maintain two separate
versions).

What we're trying instead is doing what I said in #518 we weren't going
to do: loading most object data on startup and leaving many more
functions synchronous. Essentially, this takes the various load*()
methods described in #518, moves them to startup, and makes them operate
on entire libraries rather than individual objects.

The obvious downside here (other than undoing much of the work of the
last many months) is that it increases startup time, potentially quite a
lot for larger libraries. On my laptop, with a 3,000-item library, this
adds about 3 seconds to startup time. I haven't yet tested with larger
libraries. But I'm hoping that we can optimize this further to reduce
that delay. Among other things, this is loading data for all libraries,
when it should be able to load data only for the library being viewed.
But this is also fundamentally just doing some SELECT queries and
storing the results, so it really shouldn't need to be that slow (though
performance may be bounded a bit here by XPCOM overhead).

If we can make this fast enough, it means that third-party plugins
should be able to remain much closer to their current designs. (Some
things, including saving, will still need to be made asynchronous.)
2016-03-07 17:03:58 -05:00
Dan Stillman
aff8e35a0e Fix stuck checkUser prompt in sync prefs tests on Ubuntu
For some reason the confirmEx prompt behaves differently (as a modal
window?) on Ubuntu if it's the only window open, preventing the
setTimeout() callback within support.js::waitForWindow() from being run.
(Passing -c to the test runner fixed it.) This removes a win.close() in
the middle of the file, which was probably a mistake anyway, so that the
pref window stays open until the end of the file.
2016-01-25 18:22:25 -05:00
Adomas Venčkauskas
ffd9a07164 Restores sync credential functionality of 4.0.
Improves UX of sync authentication.
The account is now linked and unlinked and an API key related to
the client is generated transparently in the background.
The API key is deleted on unlinking.
No sync options are allowed before linking an account.
2015-12-14 23:55:28 +00:00