Commit graph

98 commits

Author SHA1 Message Date
Simon Kornblith
67c81db102 Fix IPC on Windows by making SendMessage() call return immediately 2011-07-03 03:07:01 +00:00
Simon Kornblith
5710fbc530 Don't initialize Zotero just to figure out if Standalone is running 2011-07-03 00:07:56 +00:00
Simon Kornblith
c40ba095ea Move command line handler to zotero-service.js so that it will have access to zContext even before Zotero is finished initializing. This is necessary for automatic connector switching on Windows. 2011-07-02 22:04:04 +00:00
Simon Kornblith
00fdeb3bf9 Focus window in command line handler 2011-07-02 20:36:44 +00:00
Simon Kornblith
7b41d76b75 Move standalone.xul to separate standalone directory 2011-07-02 04:27:57 +00:00
Simon Kornblith
b114266fb3 - Closes #1832, Connectors should be able to retrieve translator data and code from server in the absence of Zotero Standalone
- Closes #1831, Connectors should be able to save via API in the absence of Zotero Standalone
- Fixes Zotero.Utilities.deepCopy() for arrays
- Fixes some circumstances where an error would not be saved for future error reporting
- Fixes connector status checking
2011-06-30 01:08:30 +00:00
Simon Kornblith
acfd317de9 - Addresses #1828, Ensure any code that uses nsITimer directly maintains a global reference until callback executes
- Adds an optional runWhenWaiting argument to Zotero.setTimeout(), so that code can be set to run even if Zotero.wait() is in progress
2011-06-14 21:26:48 +00:00
Simon Kornblith
8268d1b01c Zotero Everywhere megacommit
- Implement connector for Firefox (should switch in/out of connector mode automatically when Standalone is launched or closed, although this has only been tested extensively on OS X)
- Share core translation code between Zotero and connectors

Still to be done:

- Run translators in non-Fx connectors (this works in theory, but it's not currently enabled for any translators)
- Show translation results in non-Fx connectors
- Ability to translate to server when Zotero Standalone is not running
2011-06-14 00:36:21 +00:00
Simon Kornblith
3f69b8b9c0 Don't allow functions queued with setTimeout() to execute during Zotero.wait()
Fixes fatal error during import
2011-05-31 19:59:07 +00:00
Dan Stillman
51f8c11ea0 Switch client code license to Affero GPL version 3 2011-05-18 18:34:22 +00:00
Dan Stillman
824eb06c73 Add temporary workaround for XML parsing errors on imported notes in generated reports
Still invalid XML, but serve as text/html to avoid error
2011-04-27 21:33:01 +00:00
Simon Kornblith
5951768ada Fix compatibility with latest Minefield 2011-04-18 23:29:12 +00:00
Dan Stillman
ab9ae36135 Fix date-based sorting in reports 2011-04-12 14:47:44 +00:00
Dan Stillman
6b2b08cd1b Group library support for Timeline 2011-03-05 04:28:54 +00:00
Dan Stillman
f94242f7ad Fix Date Published in Timeline 2011-03-05 04:10:29 +00:00
Simon Kornblith
3fd0523b6e - fix preference links
- fix tab mode tooltip
- zotero://fullscreen opens standalone
2011-02-09 06:42:08 +00:00
Simon Kornblith
1486132626 Add flexible locate menu, based on a (very heavily modified) copy of the pubget patch. Documentation is forthcoming. 2011-02-09 03:22:06 +00:00
Simon Kornblith
90b7380563 more tab code changes 2011-02-03 07:17:55 +00:00
Simon Kornblith
ecf0f3397c Zotero as a tab. This may need to be backed out for 2.1 depending on the amount of trouble it generates. 2011-01-30 09:44:01 +00:00
Dan Stillman
1747f19009 Don't load nsDragAndDrop.js 2010-12-26 19:05:52 +00:00
Simon Kornblith
ac9d524a9f update to citeproc-js 1.0.88
From 1.0.82:

Fixes to cs:if and cs:else-if logic.  Was failing to set the match
attribute on singleton nodes, among other things.

Treat greek letters as part of the "romanesque" character set,  for
name formatting purposes.

If cs:number input has numbers separated by spaces, but also
extraneous non-comma, non-ampersand, non-hyphen characters, then
render as literal.

From 1.0.83:

Use en-dash rather than hyphen in formatted page range joins.

From 1.0.84:

Preserve explicit double spaces in HTML output.

From 1.0.85:

Pass full suite of double space suppression tests.

Language switching within a style works, for both localized dates and
terms.  (This functionality is not yet valid in CSL.)

From 1.0.86:

Address bug that caused unreasonable delays with large namesets.

From 1.0.87:

Where et-al-min, et-al-subsequent-min or names-min are set to some
value larger than zero, and the number of names in a nameset exceeds
an arbitrary threshold of 50, truncate author lists that are longer
than the *-min value (plus a buffer value of 2), to raise performance
to a  reasonable level with large namesets.

From 1.0.88:

Adjustments to language condition logic, to use only the base language
name for matching, while applying the full locale specified in the
conditional to node children.

Refinements to the recently introduced handling of brace-enclosed
leading characters as initialized form of names.

Adjustments to print statement arbitration, with a view to playing
nice with various systems.
2010-12-10 07:12:08 +00:00
Simon Kornblith
a1f52aede4 slightly less ugly hack for opening cite preferences 2010-11-07 04:36:39 +00:00
Simon Kornblith
a1f327a97a tweaks to prefs window opening 2010-11-07 04:18:58 +00:00
Simon Kornblith
3f2a8a39ab - Overhaul of Zotero.Translate instance. New code should use new Zotero.Translate.Web, Zotero.Translate.Import, etc. The core Translate class is now abstracted away from data access, read/write IO, and the sandbox API. This all needs more testing.
- Translators now use configOptions and displayOptions properties in their metadata instead of Zotero.configure() and Zotero.addOption() to specify interfaces.
- Replaced now broken Zotero.Utilities.inArray() appearances in MODS.js with proper indexOf() calls
2010-11-02 21:39:54 +00:00
Simon Kornblith
e61dd60024 move Zotero.Date and Zotero.OpenURL to independent files 2010-10-27 00:36:20 +00:00
Simon Kornblith
d22ccf2219 Zotero.Utilities changes:
- Zotero.Utilities is now a singleton
- Zotero.Utilities.HTTP is now Zotero.HTTP
- Zotero.Utilities.md5 and Zotero.Utilities.Base64 are now located under Zotero.Utilities.Internal
- Zotero.Utilities.AutoComplete has been eliminated

This needs testing to make sure there is no associated breakage.
2010-10-25 00:58:47 +00:00
Simon Kornblith
5c88810ec0 add zotero://preferences URI scheme to allow links to prefs from add-ons 2010-10-18 23:12:04 +00:00
Simon Kornblith
d06a19b6a8 add Zotero Connector 2010-09-23 04:14:19 +00:00
Dan Stillman
84cf9d8cbe Closes #1037, Remove Firefox 2.0/3.0–specific code 2010-07-09 20:10:43 +00:00
Simon Kornblith
63e08cd714 addresses #1690, Modify all XPCOM components for Firefox 4.0b2+ 2010-07-06 09:02:35 +00:00
Simon Kornblith
303f980954 Fix for "The command is not available because no document is open" error (part 2) 2010-06-20 10:48:38 +00:00
Simon Kornblith
bd0a4a3b96 Use citeproc-js as CSL parser. There is an issue with multiple citations in numbered styles that I will probably need Frank's help to track down, but otherwise, this seems to work. Many things are completely untested, including EndNote style support. Currently requires CSL 1.0 styles. In the near future, I hope to use the XSLT stylesheet to transform CSL 0.8 to CSL 1.0.
closes #1650: suppress author does not work for multiple sources
closes #1505: Edit Biblography Button Strips Year Disambiguation
closes #1503: Editing a bibliography resets all reference numbers to 1 (new)
closes #1262: Broken pluralization with et al. + other issues
closes #1238: Localize quotation marks
closes #1191: Harmonize 'plural/pluralize' label attribute with CSL schema
closes #1154: Only one works page numbers are added to the citation are when citing multiple works by the same author
closes #1097: Disambiguation issues
closes #1083: Defect in IEEE CSL with Multiple Citations
closes #993: more sophisticated subsequent-author-substitute
closes #833: text-transform doesn't work with name
2010-05-30 11:25:25 +00:00
Dan Stillman
8560710463 - Fix autocomplete date searches (broken since autocomplete speedup)
- Fix search for January dates
- Support 'yesterday'/'today'/'tomorrow' and localized equivalents (case-insensitive) in date searches (e.g., [Date Added] [is] ['yesterday'])
2010-01-12 23:06:26 +00:00
Dan Stillman
94e279e034 ECL 1.0 -> GPLv3 2009-12-28 09:47:49 +00:00
Dan Stillman
01e9bea66e Support library-key hashes in zotero://timeline and zotero://select URLs 2009-12-05 20:16:42 +00:00
Dan Stillman
f6c8494a6b - Use keys rather than ids for report URLs
- Collection report sorting was backwards (since Fx3.5, probably)
- Return full Zotero.Search objects from Zotero.Searches.getAll()
2009-12-05 04:26:22 +00:00
Dan Stillman
884e5474fe Zotero File Storage megacommit
- Group file sync via Zotero File Storage
- Split file syncing into separate modules for ZFS and WebDAV
- Dragging items between libraries copies child notes, snapshots/files, and links based on checkboxes for each (enabled by default) in the Zotero preferences
- Sync errors now trigger an exclamation/error icon separate from the sync icon, with a popup window displaying the error and an option to report it
- Various errors that could cause perpetual sync icon spinning now stop the sync properly
- Zotero.Utilities.md5(str) is now md5(strOrFile, base64)
- doPost(), doHead(), and retrieveSource() now takes a headers parameter instead of requestContentType
- doHead() can now accept an nsIURI (with login credentials), is a background request, and isn't cached
- When library access or file writing access is denied during sync, display a warning and then reset local group to server version
- Perform additional steps (e.g., removing local groups) when switching sync users to prevent errors
- Compare hash as well as mod time when checking for modified local files
- Don't trigger notifications when removing groups from the client
- Clear relation links to items in removed groups
- Zotero.Item.attachmentHash property to get file MD5
- importFromFile() now takes libraryID as a third parameter
- Zotero.Attachments.getNumFiles() returns the number of files in the attachment directory
- Zotero.Attachments.copyAttachmentToLibrary() copies an attachment item, including files, to another library
- Removed Zotero.File.getFileHash() in favor of updated Zotero.Utilities.md5()
- Zotero.File.copyDirectory(dir, newDir) copies all files from dir into newDir
- Preferences shuffling: OpenURL to Advanced, import/export character set options to Export, "Include URLs of paper articles in references" to Styles
- Other stuff I don't remember

Suffice it to say, this could use testing.
2009-09-13 07:23:29 +00:00
Dan Stillman
a7ef8f2339 Disable asynchronous autocomplete for now, because it causes hangs (sorry Elena) 2009-09-01 19:50:50 +00:00
Dan Stillman
ae88cbd0ce - Workaround for apparent async DB call brokenness in autocomplete -- and only occasionally permanently hang Firefox
- Restore (non-asynchronous) Fx3.0 support
2009-08-28 05:56:29 +00:00
Dan Stillman
4912e9d09c Asynchronous DB queries for autocomplete -- for Elena, although I'm not sure this actually speeds things up. Needs testing with massive databases on slow machines. 2009-08-25 01:44:04 +00:00
Simon Kornblith
136c47be5f Integration megacommit, part 2: Zotero code
Closes #884, final period missing when a citation is first added in note styles
Closes #1298, issues with footnotes and citations in OOo
Closes #1069, Use async HTTP calls for integration requests
Closes #1027, User-customizable integration port number
Closes #698, Migration away from VBA
Closes #1085, Migrate VBA plug-in to new XML-based API
Closes #792, Auto-updating of OO plugins
2009-08-20 05:02:55 +00:00
Ben Parr
ac79b1d05f Add Zotero Commons feature (integration between Zotero and Internet Archive).
- dropping Zotero items into a bucket puts them in that IA bucket
- double clicking a bucket takes you to that IA bucket

In order to enable Zotero Commons:
1) Get an access key and secret key at http://www.archive.org/account/s3.php
2) Go to about:config
3) Search "commons" (no quotes)
4) Set "extensions.zotero.commons.enabled" to true
5) Enter your S3 access key into "extensions.zotero.commons.accessKey"
6) Enter your S3 secret key into "extensions.zotero.commons.secretKey"
7) Enter your buckets into "extensions.zotero.commons.buckets" as a comma separated list

Note: Steps 4-7 take effect in new windows
2009-08-13 10:56:47 +00:00
Dan Stillman
5f9e39f959 In-memory debug logging, configurable in Advanced pane of preferences, with ability to send output to zotero.org 2009-08-10 16:44:15 +00:00
Dan Stillman
9b7070ad38 zotero://fullscreen patch from Ben Parr, with a tweak to properly restore unmaximized Zotero pane height when using as home page
Known issue: Window title isn't set correctly

Says Ben:

===========================================

Some uses for this feature include:
- people who don't want to use Firefox as their main browser could set their Firefox homepage to zotero://fullscreen, making Zotero act as a standalone application
- people who do use Firefox could add the link to their Bookmarks Toolbar, and simply Shift-click it to have a Zotero "standalone application"

===========================================
2009-07-27 11:12:42 +00:00
Dan Stillman
41437738b0 - Add triggers for full sync on various errors
- Add Zotero.Error(message, error) constructor to create a throwable error object with an error code
- Allow only one automatic client reset between manual syncs
- Fix "Source item for keyed source doesn't exist in Zotero.Item.getSource()" error
- Object produced by item.serialize() now contains .sourceItemKey instead of .sourceItemID
- Better error logging for missing XPCOM files
2009-07-06 10:13:02 +00:00
Simon Kornblith
7da8c036d7 Use RDF store from Tabulator (http://www.w3.org/2005/ajar/tab) instead of Mozilla RDF support, along with a modified version of their RDF serializer. Our RDF export should now be much cleaner, but still backward compatible with 1.0. 2009-06-24 20:42:41 +00:00
Ben Parr
8437a55e3e Fixes #1470 and makes sure the requested XML url is clean. 2009-05-18 15:48:45 +00:00
Dan Stillman
91459f95f7 2.0b3 megacommit
- Support for group libraries
- General support for multiple libraries of different types
- Streamlined sync support
  - Using solely libraryID and key rather than itemID, and removed all itemID-changing code
  - Combined two requests for increased performance and decreased server load
  - Added warning on user account change
  - Provide explicit error message on SSL failure
- Removed snapshot and link toolbar buttons and changed browser context menu options and drags to create parent items + snapshots
- Closes #786, Add numPages field
- Fixes #1063, Duplicate item with tags broken in Sync Preview
- Added better purging of deleted tags
- Added local user key before first sync
- Add clientDateModified to all objects for more flexibility in syncing
- Added new triples-based Relation object type, currently used to store links between items copied between local and group libraries
- Updated zotero.org translator for groups
- Additional trigger-based consistency checks
- Fixed broken URL drag in Firefox 3.5
- Disabled zeroconf menu option (no longer functional)

Developer-specific changes:

- Overhauled data layer
  - Data object constructors no longer take arguments (return to 1.0-like API)
  - Existing objects can be retrieved by setting id or library/key properties
  - id/library/key must be set for new objects before other fields
- New methods:
  - ZoteroPane.getSelectedLibraryID()
  - ZoteroPane.getSelectedGroup(asID)
  - ZoteroPane.addItemFromDocument(doc, itemType, saveSnapshot)
  - ZoteroPane.addItemFromURL(url, itemType)
  - ZoteroPane.canEdit()
  - Zotero.CollectionTreeView.selectLibrary(libraryID)
  - New Zotero.URI methods
- Changed methods
  - Many data object methods now take a libraryID
  - ZoteroPane.addAttachmentFromPage(link, itemID)
- Removed saveItem and saveAttachments parameters from Zotero.Translate constructor
- translate() now takes a libraryID, null for local library, or false to not save items (previously on constructor)
- saveAttachments is now a translate() parameter
- Zotero.flattenArguments() better handles passed objects
- Zotero.File.getFileHash() (not currently used)
2009-05-14 18:23:40 +00:00
Dan Stillman
f96d5c1cac Addresses #1146, Check for duplicate items functionality
Actually load duplicate detection code
2009-03-06 21:45:49 +00:00
Dan Stillman
337b16361a Merge [3617-3838] from branch to trunk 2008-11-30 20:18:48 +00:00