Commit graph

6239 commits

Author SHA1 Message Date
Dan Stillman
168e4e4b45 Default month/day to 01 in Timeline if missing
This causes any item with just a year to show up at the start of the
year (instead of just not showing up, which I think was the case
before). Unfortunately they can then go out of view, and it's not
possible to scroll to view more, though that could probably be fixed.
2017-07-29 22:17:08 -04:00
Dan Stillman
23d4992265 Fix Zotero.Utilities.Internal.getAsyncInputStream(), used by Timeline 2017-07-29 22:11:56 -04:00
Dan Stillman
a6564e92d7 Update proxy authentication URLs
And try all, since it doesn't do any of this unless there's a PAC file,
it's not actually a network request unless the site should be proxied,
and it should only make a single HEAD request unless a previous one
fails.

There's a possibility some proxies are limited to HTTP, in which case
changing these to HTTPS might stop this from working. If so, we'd need
to add back HTTP addresses.

Closes #1273
2017-07-28 20:41:10 -04:00
Dan Stillman
884d03b12a Remove prompt when adding style manually
(And prompt was showing "(null)")
2017-07-28 19:34:20 -04:00
Dan Stillman
d252a09cd3 Update Quick Copy menu options based on current settings and URL
Show "Copy Citation" and "Copy Bibliography" when a bib format is
selected and "Copy as BibTeX", etc., when an export is selected. If a
site-specific setting is in effect from the last active URL, use that
instead.

If no regular items are selected in bib mode, the menu options are
disabled.

This also now filters non-regular items out when in bib mode -- before
if you selected a combination it would include a bunch of 'n.d.' lines.

Closes #1155, Disable Copy Citation menu option when a translator is
selected for Quick Copy
2017-07-28 19:11:39 -04:00
Dan Stillman
72fbee5523 Fix crash switching from Notes tab to feed item 2017-07-27 00:11:13 -04:00
Dan Stillman
c110e64293 Consider fulltextItems with SYNC_STATE_MISSING as unindexed
The items will still match full-text word searches, but they won't match
phrase searches (because those require cache files for non-text
attachments) and the full-text won't sync to other computers, so they
should really be reindexed.
2017-07-26 22:16:01 -04:00
Dan Stillman
67ccb632b4 Don't keep looking for unsynced full-text content that isn't available
This can happen if cache files are deleted for PDF attachments or if
text files are missing.
2017-07-26 22:16:01 -04:00
Dan Stillman
10637ca9ea Switch to OS.File for most full-text file access 2017-07-26 22:16:01 -04:00
Dan Stillman
61f8a2c3c5 Fix various problems with fulltextContent searches
Including finding items in the wrong library and not finding any items
when paired with the checkboxes in ANY mode
2017-07-26 22:16:01 -04:00
Dan Stillman
36371630b5 Restore auto-expanding of search matches except in My Publications
Saved searches and the trash should automatically expand items to show
matching child items, but that was broken in d47275210.
2017-07-26 22:16:01 -04:00
Dan Stillman
46531a4c69 Remove non-matching parent items when deleting items from trash
Fixes #866, Trash doesn't refresh properly when emptying deleted
attachments
2017-07-26 22:16:01 -04:00
Dan Stillman
e475b22f1d Add intl.accept_languages from Mozilla language packs 2017-07-25 16:27:31 -04:00
Dan Stillman
d8b201487d Allow clearing global prefs 2017-07-25 15:44:49 -04:00
Dan Stillman
521f291b84 Fix PluralForm support
The library was using the plural rule defined in the built-in
intl.properties, but that was always en-US in the standalone app.
2017-07-25 15:20:23 -04:00
Dan Stillman
d01366a2f1 Remove line from Report Errors about messages possibly unrelated to Zotero 2017-07-25 03:01:45 -04:00
Dan Stillman
c2bb4ac10b Move debug output logging to the Help menu
Adds a submenu for quickly generating and submitting debug output, with
a button to copy the Debug ID to the clipboard and a one-click option to
restart with logging enabled. Debug output can also now be viewed in
real-time using the new debug output viewer window (previously available
only via a command-line flag).

The locale switcher has moved to the top of the Advanced prefpane (where
Debug Output Logging used to go) in a Miscellaneous section, and there's
a new "Advanced Configuration" section (mirroring Thunderbird) at the
bottom for "Config Editor".

Closes #1108
2017-07-25 03:00:39 -04:00
Dan Stillman
e3947e7b45 Debug output viewer tweaks
- Decrease font size
- Do a better job of pinning to bottom
- Disable submit button when clearing output
- Filter ANSI color codes from slow lines
2017-07-25 02:41:50 -04:00
Dan Stillman
a9594360cd Deprecate Zotero.Utilities.Internal.quitZotero() in favor of quit() 2017-07-25 02:29:26 -04:00
Dan Stillman
695dd4e65d Don't omit first line in debug output when submitting 2017-07-24 22:49:17 -04:00
Dan Stillman
6ae2b58d3f Update submodules 2017-07-24 08:59:23 -04:00
Dan Stillman
34d039ba48 Fix a whole mess of issues with data directory migration
- If an error occurred while moving the database file, the data
  directory could end up pointing to the new, empty directory after a
  restart
- The error message for a full failure was missing the second half that
  actually explained that you were supposed to move the data directory
- The check for different-drive migrations didn't work if the new
  directory didn't exist (at least on macOS), swallowed some errors, and
  interfered with manual migrations from the prefs
- The manual migration button would say that the new directory wasn't
  empty even if it just contained .DS_Store
- Don't show "Database migration in progress" after not restarting after
  a migration failure

Additionally, after a full failure the migration is now attempted on
every restart and displays a warning each time, since otherwise people
will never move their directories out of the Firefox profile (which is
when it's going to fail the most, due to security software).
2017-07-24 08:51:02 -04:00
Dan Stillman
05ea309e2e Use proper locale format for dates in items list
2addf6b27b fixed the date order used when automatic locale detection was
enabled, but this fixes the format (e.g., dots instead of slashes). It
should now match the item pane. I'm not sure why we weren't doing this
before, but hopefully we didn't have a good reason.
2017-07-23 15:12:09 -04:00
Dan Stillman
ef71a2c77c Use HTTPS for Google Scholar in Retrieve Metadata for PDF 2017-07-23 00:57:04 -04:00
Dan Stillman
225215842d Fix auto-syncing of unchecked groups after object change 2017-07-21 19:39:37 -04:00
Dan Stillman
6d2c72fb54 Fix revealing parent directory of missing file
Updates Zotero.File.getClosestDirectory() to take a path rather than an
nsIFile
2017-07-21 18:33:36 -04:00
Dan Stillman
b033dedddc Fix broken WebDAV orphaned-file purging after 39a8e8fb0c 2017-07-21 08:39:43 -04:00
Dan Stillman
faecefa375 Rename/reorganize Advanced prefs buttons
- Move csledit and cslpreview to a Tools section of the Cite pane as
  Style Editor and Style Preview
- Rename "Open about:config" to "Config Editor"
- Hide about:memory unless devtools.errorconsole.enabled is enabled,
  which isn't particularly appropriate and maybe we can find something
  better, but about:memory doesn't really need to be visible by default

Closes #1264
2017-07-21 07:53:50 -04:00
Dan Stillman
33b40829b8 Add locale switcher to Advanced prefs
Closes https://www.zotero.org/trac/ticket/1733 (!)
2017-07-21 07:51:57 -04:00
Dan Stillman
2addf6b27b Get Zotero.locale from loaded locale, not from pref
It was previously set from general.useragent.locale, but that's not used
by default, meaning that date interpretation and some other things might
have been incorrect for everyone who didn't set a locale explicitly and
toggle matchOS...
2017-07-21 07:51:57 -04:00
Adomas Venčkauskas
40c84ecbc0 Report automaticSnapshots pref to connector.
Part of zotero/zotero-connectors#151
2017-07-21 11:36:36 +03:00
Dan Stillman
39a8e8fb0c Send Content-Type: text/xml header for WebDAV PROPFIND 2017-07-21 04:05:12 -04:00
Dan Stillman
a7be5444ea Fix tag selector search (broken in 6de7fdedf) 2017-07-20 16:51:50 -04:00
Dan Stillman
6de7fdedf9 Take tag selector out of the tab order, for now
This restores the 4.0 behavior. It's not ideal, but neither is having to
tab through thousands of items to get to the items pane (unless you
toggle the tag selector closed first). Hopefully we can come up with a
better solution to make the tags accessible.
2017-07-20 03:46:56 -04:00
Dan Stillman
cbc05baf02 Fix error on connector ping before site-specific Quick Copy load 2017-07-20 03:46:56 -04:00
Adomas Venčkauskas
ece3491e21 Connector server: respond with collection editability status 2017-07-19 11:40:55 +03:00
Dan Stillman
a158e8a71b Alter Quick Copy preferences text
Closes #1022

Could try to explain site-specific settings, but it's somewhat
complicated (requires the Zotero Connector, uses the last active tab
regardless of drag destination), so maybe enough to explain on the
linked documentation page.
2017-07-19 03:57:39 -04:00
Dan Stillman
b3ce918dfb Sort export translators in Quick Copy settings drop-downs 2017-07-19 03:39:51 -04:00
Dan Stillman
6d265f448f Restore site-specific Quick Copy settings
Using the last URL passed by a connector

Closes https://github.com/zotero/zotero-connectors/issues/145
2017-07-19 03:39:27 -04:00
Dan Stillman
2928752d19 Clear attachment data change marker when loading primary data
Fixes a regression from ef7da3486a in which attachment data still shows
as changed after a save.
2017-07-18 18:50:28 -04:00
Dan Stillman
cff84a71ed Simplify an array check 2017-07-18 17:32:38 -04:00
Dan Stillman
df353bdc05 Optimistic updates for item tags box
Add/update/remove rows immediately and save after. If there's an error
during saving, reload the pane.
2017-07-18 17:32:38 -04:00
Dan Stillman
ef7da3486a New state-handling approach for item tag changes
If this works out I think we'll want to use this approach for
all data layer changes.

Previously, an unsaved change on an object would update its state
immediately, which was fine for synchronous code but breaks down if a
save involves multiple asynchronous calls, because modifying state after
the relevant data has been saved to the DB but before the `_changed`
object has been cleared would mean that new changes would be lost. Now,
changes are written to _changedData, and a get for the data first checks
_changedData before checking the state property (e.g., _tags) directly.
The changedData property is cleared as it's written, and once the object
is saved, the reload updates the state property with the new data.
2017-07-18 17:31:40 -04:00
Dan Stillman
09a859d7e3 Allow an array of strings in Zotero.Item::setTags()
New tags will all be of type 0 (manual)
2017-07-18 17:21:36 -04:00
Dan Stillman
3715c8da1b Fix use of multiple search translators
It was stopping after the first translator, which meant that some ISBN
lookups failed if the ISBN wasn't in Library of Congress.

Regression from 6da0845f4b, which hopefully didn't have a good reason
for this
2017-07-18 07:13:03 -04:00
Dan Stillman
5268060802 Move Tools -> Options to Edit -> Preferences on Windows
Closes #1167
2017-07-18 04:14:17 -04:00
Dan Stillman
76030d2c4a Fix tag selector font on Windows 2017-07-18 04:14:17 -04:00
Adomas Venčkauskas
6d7dcc44bc Add connector endpoint to retrieve proxies. Closes #1265 2017-07-18 10:25:54 +03:00
Dan Stillman
78dd1e132e Fix calculation of last WebDAV orphaned-file-purge time
Purging was happening after every download.
2017-07-17 16:53:11 -04:00
Dan Stillman
ba514b80d9 Add "Remove All Tags…" option to item tags box context menu 2017-07-17 16:34:52 -04:00