From afd14ae4b9295735b0c979535998fcf0caa5a59f Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Sat, 2 Nov 2013 02:46:22 -0400 Subject: [PATCH] Fix PDF tools prompt on pref window open if Search pane not yet loaded --- chrome/content/zotero/preferences/preferences.js | 4 ---- chrome/content/zotero/preferences/preferences_search.js | 6 ++++++ 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/chrome/content/zotero/preferences/preferences.js b/chrome/content/zotero/preferences/preferences.js index c2744ec87d..0e04413c75 100644 --- a/chrome/content/zotero/preferences/preferences.js +++ b/chrome/content/zotero/preferences/preferences.js @@ -43,10 +43,6 @@ var Zotero_Preferences = { if(io.pane) { var pane = document.getElementById(io.pane); document.getElementById('zotero-prefs').showPane(pane); - // Quick hack to support install prompt from PDF recognize option - if (io.action && io.action == 'pdftools-install') { - this.Search.checkPDFToolsDownloadVersion(); - } } } else if(document.location.hash == "#cite") { document.getElementById('zotero-prefs').showPane(document.getElementById("zotero-prefpane-cite")); diff --git a/chrome/content/zotero/preferences/preferences_search.js b/chrome/content/zotero/preferences/preferences_search.js index 6aec06d879..064a2064e9 100644 --- a/chrome/content/zotero/preferences/preferences_search.js +++ b/chrome/content/zotero/preferences/preferences_search.js @@ -34,6 +34,12 @@ Zotero_Preferences.Search = { this.updatePDFToolsStatus(); this.updateIndexStats(); + + // Quick hack to support install prompt from PDF recognize option + var io = window.arguments[0]; + if (io.action && io.action == 'pdftools-install') { + this.checkPDFToolsDownloadVersion(); + } }, /*