diff --git a/chrome/content/zotero/preferences/preferences_export.js b/chrome/content/zotero/preferences/preferences_export.js index ce1a302c77..41c94a5c52 100644 --- a/chrome/content/zotero/preferences/preferences_export.js +++ b/chrome/content/zotero/preferences/preferences_export.js @@ -145,6 +145,21 @@ Zotero_Preferences.Export = { checkbox.disabled = mode != 'bibliography'; }, + /** + * Disables UI buttons when no site-specific quick copy entries are selected + */ + disableQuickCopySiteButtons: function () { + document.getElementById('quickCopy-edit').disabled = true; + document.getElementById('quickCopy-delete').disabled = true; + }, + + /** + * Enables UI buttons when a site-specific quick copy entry is selected + */ + enableQuickCopySiteButtons: function () { + document.getElementById('quickCopy-edit').disabled = false; + document.getElementById('quickCopy-delete').disabled = false; + }, showQuickCopySiteEditor: function (index) { var treechildren = document.getElementById('quickCopy-siteSettings-rows'); @@ -212,6 +227,8 @@ Zotero_Preferences.Export = { treeitem.appendChild(treerow); treechildren.appendChild(treeitem); } + + this.disableQuickCopySiteButtons(); }, diff --git a/chrome/content/zotero/preferences/preferences_export_firefox.xul b/chrome/content/zotero/preferences/preferences_export_firefox.xul index 277ce4962b..6f913c31c8 100644 --- a/chrome/content/zotero/preferences/preferences_export_firefox.xul +++ b/chrome/content/zotero/preferences/preferences_export_firefox.xul @@ -23,7 +23,10 @@ ***** END LICENSE BLOCK ***** --> - + %preferencesDTD; + %zoteroDTD; +]> @@ -34,6 +37,7 @@