From 4bb7f7d08be8a29dd921f9a1d0d88c5d4a6ff4b1 Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Tue, 1 May 2012 20:00:35 -0400 Subject: [PATCH] Show data directory properly on Linux Previously used a custom selectable alert when reveal() failed, but we can just launch the directory, as we do for attachments --- .../content/zotero/preferences/preferences.js | 9 +++----- chrome/content/zotero/selectableAlert.xul | 23 ------------------- 2 files changed, 3 insertions(+), 29 deletions(-) delete mode 100644 chrome/content/zotero/selectableAlert.xul diff --git a/chrome/content/zotero/preferences/preferences.js b/chrome/content/zotero/preferences/preferences.js index f08f363b01..24996db419 100644 --- a/chrome/content/zotero/preferences/preferences.js +++ b/chrome/content/zotero/preferences/preferences.js @@ -1234,12 +1234,9 @@ function revealDataDirectory() { dataDir.reveal(); } catch (e) { - // On platforms that don't support nsILocalFile.reveal() (e.g. Linux), we - // open a small window with a selected read-only textbox containing the - // file path, so the user can open it, Control-c, Control-w, Alt-Tab, and - // Control-v the path into another app - var io = {alertText: dataDir.path}; - window.openDialog('chrome://zotero/content/selectableAlert.xul', "zotero-reveal-window", "chrome", io); + // On platforms that don't support nsILocalFile.reveal() (e.g. Linux), + // launch the directory + window.opener.ZoteroPane_Local.launchFile(dataDir); } } diff --git a/chrome/content/zotero/selectableAlert.xul b/chrome/content/zotero/selectableAlert.xul deleted file mode 100644 index 950353ed4f..0000000000 --- a/chrome/content/zotero/selectableAlert.xul +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - - - - - - - - -