[Pkg-mozext-commits] [automatic-save-folder] 68/133: Add : New option to automatically set the radio choice to "Save File" when using the automatic saving feature. Prevent the file to be opened. Fix : Now use the full URL when falling back to website URL if no filter is found.
David Prévot
taffit at moszumanska.debian.org
Mon Apr 27 20:33:53 UTC 2015
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch wip
in repository automatic-save-folder.
commit f1303076e4e829b1bb6a3fb8d4d20e525f978e34
Author: Cyan <Cyan at d0063192-6b2e-11de-89a9-0b20f3e2dceb>
Date: Sat May 22 14:50:14 2010 +0000
Add : New option to automatically set the radio choice to "Save File" when using
the automatic saving feature. Prevent the file to be opened.
Fix : Now use the full URL when falling back to website URL if no filter is
found.
git-svn-id: http://automatic-save-folder.googlecode.com/svn/trunk@74 d0063192-6b2e-11de-89a9-0b20f3e2dceb
---
content/asf.js | 4 ++++
content/asf_download.js | 9 ++++++++-
content/help/about.xhtml | 4 ++++
content/options.xul | 4 +++-
defaults/preferences/asf.js | 1 +
locale/en-US/about.dtd | 7 ++++++-
locale/en-US/asf.dtd | 3 ++-
locale/fr/about.dtd | 7 ++++++-
locale/fr/asf.dtd | 3 ++-
locale/it/about.dtd | 7 ++++++-
locale/it/asf.dtd | 3 ++-
locale/ru/about.dtd | 7 ++++++-
locale/ru/asf.dtd | 3 ++-
13 files changed, 52 insertions(+), 10 deletions(-)
diff --git a/content/asf.js b/content/asf.js
index f518cb1..20973eb 100644
--- a/content/asf.js
+++ b/content/asf.js
@@ -374,6 +374,7 @@ var automatic_save_folder = {
var viewpathlist = document.getElementById("asf-viewpathselect");
var dialogaccept = document.getElementById("asf-dialogaccept");
var dialogacceptFiltered = document.getElementById("asf-dialogacceptFiltered");
+ var dialogacceptForceSavefile = document.getElementById("asf-dialogacceptForceSavefile");
var useDownloadDir = document.getElementById("asf-useDownloadDir");
var asf_userightclick = document.getElementById("asf-userightclick");
var asf_rightclicktimeout = document.getElementById("asf-rightclicktimeout");
@@ -396,10 +397,13 @@ var automatic_save_folder = {
{
dialogacceptFiltered.checked = false;
dialogacceptFiltered.disabled = true;
+ dialogacceptForceSavefile.checked = false;
+ dialogacceptForceSavefile.disabled = true;
}
if (dialogaccept.checked == true)
{
dialogacceptFiltered.disabled = false;
+ dialogacceptForceSavefile.disabled = false;
}
// if the option window is opened from the saving window, disable the autosave feature (Not working when set from here.)
diff --git a/content/asf_download.js b/content/asf_download.js
index 891617c..17a621b 100644
--- a/content/asf_download.js
+++ b/content/asf_download.js
@@ -130,7 +130,7 @@ Copyright (C) 2007-2010 Éric Cassar (Cyan).
var uCT = document.getElementById("unknownContentType");
try
{
- var currentURL = uCT.parentNode.defaultView.opener.location.host; // look for the current website URL in the DOM.
+ var currentURL = uCT.parentNode.defaultView.opener.location.href; // look for the current website URL in the DOM.
dom_regexp = this.test_regexp(filters[i][0], currentURL); // check the filter domain with the current website URL only if the hosted domain doesn't match
}
catch (e) { } // if there is no location.host data (tab is closed or script redirection), use the default folder as there are no filter's domain or current URL domain.
@@ -228,6 +228,13 @@ Copyright (C) 2007-2010 Éric Cassar (Cyan).
if (dialogacceptFiltered && idx < 0) dialogaccept = false; // no filter matched, do not autoaccept the dialog
if (dialogaccept)
{
+ // select "Save file" automatically
+ if (this.prefManager.getBoolPref("extensions.asf.dialogacceptForceSavefile"))
+ {
+ var radiosavemode = document.getElementById("mode");
+ radiosavemode.selectedItem = document.getElementById("save");
+ //alert(document.getElementById("save").selected);
+ }
window.close();
return dialog.onOK();
}
diff --git a/content/help/about.xhtml b/content/help/about.xhtml
index 57f4dcc..96f7b81 100644
--- a/content/help/about.xhtml
+++ b/content/help/about.xhtml
@@ -32,6 +32,10 @@
! &about.fix;
+<strong>&about.version.title; 1.0.2b :</strong> (2010 xx xx)
+&about.version.102;
+
+
<strong>&about.version.title; 1.0.1 :</strong> (2010 02 11)
&about.version.101;
diff --git a/content/options.xul b/content/options.xul
index 41166ea..60de174 100644
--- a/content/options.xul
+++ b/content/options.xul
@@ -33,6 +33,7 @@
<preference id="asf_variablemode" name="extensions.asf.variablemode" type="bool"/>
<preference id="asf_dialogaccept" name="extensions.asf.dialogaccept" type="bool"/>
<preference id="asf_dialogacceptFiltered" name="extensions.asf.dialogacceptFiltered" type="bool"/>
+ <preference id="asf_dialogacceptForceSavefile" name="extensions.asf.dialogacceptForceSavefile" type="bool"/>
<preference id="asf_userightclick" name="extensions.asf.userightclick" type="bool"/>
<preference id="asf_rightclicktimeout" name="extensions.asf.rightclicktimeout" type="bool"/>
<preference id="asf_usecurrenturl" name="extensions.asf.usecurrenturl" type="bool"/>
@@ -154,7 +155,8 @@
</menulist>
</hbox>
<checkbox id="asf-dialogaccept" preference="asf_dialogaccept" label="&asf.dialogaccept.bool;" oncommand="automatic_save_folder.toggle_options();"/>
- <checkbox id="asf-dialogacceptFiltered" preference="asf_dialogacceptFiltered" label="&asf.dialogacceptFiltered.bool;" tooltip="tooltip_dialogacceptFiltered" style="margin-left:25px;"/>
+ <checkbox id="asf-dialogacceptFiltered" preference="asf_dialogacceptFiltered" label="&asf.dialogacceptFiltered.bool;" tooltip="tooltip_dialogacceptFiltered" style="margin-left:25px;"/>
+ <checkbox id="asf-dialogacceptForceSavefile" preference="asf_dialogacceptForceSavefile" label="&asf.dialogacceptForceSavefile.bool;" style="margin-left:25px;"/>
<hbox>
<checkbox id="asf-viewdloption" preference="asf_viewdloption" label="&asf.viewdloption.bool;" tooltip="tooltip_viewdloption" oncommand="automatic_save_folder.toggle_options();"/>
<menulist id="asf-viewdloptionType" preference="asf_viewdloptionType">
diff --git a/defaults/preferences/asf.js b/defaults/preferences/asf.js
index 5f2a664..e559790 100644
--- a/defaults/preferences/asf.js
+++ b/defaults/preferences/asf.js
@@ -17,6 +17,7 @@ pref("extensions.asf at mangaheart.org.description", "chrome://asf/locale/asf.prope
pref("browser.download.folderList", 2);
pref("extensions.asf.dialogaccept", false);
pref("extensions.asf.dialogacceptFiltered", false);
+ pref("extensions.asf.dialogacceptForceSavefile", false);
pref("extensions.asf.userightclick", true);
pref("extensions.asf.rightclicktimeout", true);
pref("browser.download.saveLinkAsFilenameTimeout", 0); // set the default value to userpref.js to prevent main pref.js modification and restore default value on ASF uninstall.
diff --git a/locale/en-US/about.dtd b/locale/en-US/about.dtd
index f3647a9..820281a 100644
--- a/locale/en-US/about.dtd
+++ b/locale/en-US/about.dtd
@@ -1,5 +1,5 @@
<!-- ASF -->
-<!ENTITY asf.version "1.0.2b Rev73">
+<!ENTITY asf.version "1.0.2b Rev74">
<!-- Mini about box from addon manager -->
<!ENTITY about "About Automatic Save Folder">
@@ -26,6 +26,11 @@
<!ENTITY about.version.title "Version">
<!-- Keep the newline intact as it uses the < pre > tag, keep the 2 begining spaces to create indentation -->
+<!ENTITY about.version.102 "+ Added an option to force the radio choice to "Save file" when using the automatic download option.
+! Fixed a bug where checking the Regexp option when a filter ended by a slash didn't add a second slash.
+! Fixed a bug where no data were returned if a download was initiated from the URL bar or from an external software which resulted in no filters in the filter's list if the preferences window was opened from the saving dialog "+ Add or edit a filter". (Thanks to MrCOLOMBO)
+! ASF now uses the full URL instead of the domain when falling back to current website URL if no filter is found, when using single click (Right-click already used full URL).">
+
<!ENTITY about.version.101 "! Fixed a spelling error preventing ASF to work when no filter matched.
! Added a missing Russian string on the filter's tab.">
diff --git a/locale/en-US/asf.dtd b/locale/en-US/asf.dtd
index adc659a..27bcfc4 100644
--- a/locale/en-US/asf.dtd
+++ b/locale/en-US/asf.dtd
@@ -1,5 +1,5 @@
<!-- ASF -->
-<!ENTITY asf.version "1.0.2b Rev73">
+<!ENTITY asf.version "1.0.2b Rev74">
<!-- browser and save dialog-->
<!ENTITY prefwindow.title "Automatic Save Folder Preferences">
@@ -43,6 +43,7 @@
<!ENTITY asf.dialogaccept.bool "Automatically accept the "What should Firefox do with this file" dialog windows.">
<!ENTITY asf.dialogacceptFiltered.bool "Only if a filter is found">
<!ENTITY asf.dialogacceptFiltered.tooltip "Will not automatically accept the "What should Firefox do with this file" dialog windows if no filter matches.">
+<!ENTITY asf.dialogacceptForceSavefile.bool "Force the radio choice to "Save File" before automatically accepting the save dialog.">
<!ENTITY asf.viewdloption.bool "View options when downloading">
<!ENTITY asf.viewdloption.tooltip "Allow you to see the last two destination folders and a link to add or edit the filters">
<!ENTITY asf.viewdloptionType0.label "Always show">
diff --git a/locale/fr/about.dtd b/locale/fr/about.dtd
index 05eead8..99ac156 100644
--- a/locale/fr/about.dtd
+++ b/locale/fr/about.dtd
@@ -1,5 +1,5 @@
<!-- ASF -->
-<!ENTITY asf.version "1.0.2b Rev73">
+<!ENTITY asf.version "1.0.2b Rev74">
<!-- Mini about box from addon manager -->
<!ENTITY about "À Propos d'Automatic save folder">
@@ -26,6 +26,11 @@
<!ENTITY about.version.title "Version">
<!-- Conserver les retour à la ligne car le tag < pre > est utilisé, gardez les deux espaces en début de ligne pour l'indentation -->
+<!ENTITY about.version.102 "+ Ajout d'une option permettant de forcer le choix sur "Enregistrer le fichier" lorsque l'enregistrement automatique est sélectionné.
+! Correction du script permettant de rajouter les slashs aux expressions régulières si le filtre contient déjà un slash aux extrémités.
+! Correction d'un bug où les données d'un lien direct entré dans la barre d'adresse ou initialisé par un autre programme n'étaient pas lu correctement, empêchant d'afficher la liste des filtres lorsque la fenêtre de préférences était ouverte à partir du lien "+ Ajouter ou éditer un filtre" de la fenêtre d'enregistrement. (Merci à MrCOLOMBO)
+! ASF utilise maintenant l'URL complète du site courant au lieu de son domaine lorsque qu'aucun filtre n'est trouvé. (Le clic-droit utilisait déjà l'URL complète).">
+
<!ENTITY about.version.101 "! Correction d'une erreur de frape empêchant ASF de fonctionner si aucun filtre n'était trouvé.
! Ajout d'une traduction russe manquante dans l'onglet des filtres.">
diff --git a/locale/fr/asf.dtd b/locale/fr/asf.dtd
index 846991e..50f17c1 100644
--- a/locale/fr/asf.dtd
+++ b/locale/fr/asf.dtd
@@ -1,5 +1,5 @@
<!-- ASF -->
-<!ENTITY asf.version "1.0.2b Rev73">
+<!ENTITY asf.version "1.0.2b Rev74">
<!-- browser and save dialog-->
<!ENTITY prefwindow.title "Préférences pour Automatic Save Folder">
@@ -43,6 +43,7 @@
<!ENTITY asf.dialogaccept.bool "Valider automatiquement la fenêtre "Que doit faire Firefox avec ce fichier ?".">
<!ENTITY asf.dialogacceptFiltered.bool "Seulement si un filtre est trouvé">
<!ENTITY asf.dialogacceptFiltered.tooltip "Ne valide pas automatiquement la fenêtre "Que doit faire Firefox avec ce fichier ?" si aucun filtre ne correspond.">
+<!ENTITY asf.dialogacceptForceSavefile.bool "Forcer le choix sur "Enregistrer le fichier" avant de valider automatiquement la fenêtre d'enregistrement.">
<!ENTITY asf.viewdloption.bool "Afficher les options lors de l'enregistrement">
<!ENTITY asf.viewdloption.tooltip "Permet de voir les deux derniers dossiers d'enregistrement et un lien pour éditer ou ajouter de nouveaux filtres.">
<!ENTITY asf.viewdloptionType0.label "Toujours afficher">
diff --git a/locale/it/about.dtd b/locale/it/about.dtd
index e080abe..e8ba6a2 100644
--- a/locale/it/about.dtd
+++ b/locale/it/about.dtd
@@ -1,5 +1,5 @@
<!-- ASF -->
-<!ENTITY asf.version "1.0.2b Rev73">
+<!ENTITY asf.version "1.0.2b Rev74">
<!-- Mini about box from addon manager -->
<!ENTITY about "Informazioni su Automatic Save Folder">
@@ -26,6 +26,11 @@
<!ENTITY about.version.title "Versione">
<!-- Keep the newline intact as it uses the < pre > tag, keep the 2 begining spaces to create indentation -->
+<!ENTITY about.version.102 "+ Added an option to force the radio choice to "Save file" when using the automatic download option.
+! Fixed a bug where checking the Regexp option when a filter ended by a slash didn't add a second slash.
+! Fixed a bug where no data were returned if a download was initiated from the URL bar or from an external software which resulted in no filters in the filter's list if the preferences window was opened from the saving dialog "+ Add or edit a filter". (Thanks to MrCOLOMBO)
+! ASF now uses the full URL instead of the domain when falling back to current website URL if no filter is found, when using single click (Right-click already used full URL).">
+
<!ENTITY about.version.101 "! Fixed a spelling error preventing ASF to work when no filter matched.
! Added a missing Russian string on the filter's tab.">
diff --git a/locale/it/asf.dtd b/locale/it/asf.dtd
index 709b08e..c31e68f 100644
--- a/locale/it/asf.dtd
+++ b/locale/it/asf.dtd
@@ -1,5 +1,5 @@
<!-- ASF -->
-<!ENTITY asf.version "1.0.2b Rev73">
+<!ENTITY asf.version "1.0.2b Rev74">
<!-- browser and save dialog-->
<!ENTITY prefwindow.title "Preferenze di Automatic Save Folder">
@@ -43,6 +43,7 @@
<!ENTITY asf.dialogaccept.bool "Automatically accept the "What should Firefox do with this file" dialog windows.">
<!ENTITY asf.dialogacceptFiltered.bool "Only if a filter is found">
<!ENTITY asf.dialogacceptFiltered.tooltip "Will not automatically accept the "What should Firefox do with this file" dialog windows if no filter matches.">
+<!ENTITY asf.dialogacceptForceSavefile.bool "Force the radio choice to "Save File" before automatically accepting the save dialog.">
<!ENTITY asf.viewdloption.bool "Vedere le opzioni mentre scarica">
<!ENTITY asf.viewdloption.tooltip "permette di vedere le due ultime cartelle di destinazione e un collegamento per aggiungere o modificare filtri.">
<!ENTITY asf.viewdloptionType0.label "Always show">
diff --git a/locale/ru/about.dtd b/locale/ru/about.dtd
index c5b4903..1645ece 100644
--- a/locale/ru/about.dtd
+++ b/locale/ru/about.dtd
@@ -1,5 +1,5 @@
<!-- ASF -->
-<!ENTITY asf.version "1.0.2b Rev73">
+<!ENTITY asf.version "1.0.2b Rev74">
<!-- Mini about box from addon manager -->
<!ENTITY about "О Automatic Save Folder">
@@ -26,6 +26,11 @@
<!ENTITY about.version.title "Версия">
<!-- Keep the newline intact as it uses the < pre > tag, keep the 2 begining spaces to create indentation -->
+<!ENTITY about.version.102 "+ Added an option to force the radio choice to "Save file" when using the automatic download option.
+! Fixed a bug where checking the Regexp option when a filter ended by a slash didn't add a second slash.
+! Fixed a bug where no data were returned if a download was initiated from the URL bar or from an external software which resulted in no filters in the filter's list if the preferences window was opened from the saving dialog "+ Add or edit a filter". (Thanks to MrCOLOMBO)
+! ASF now uses the full URL instead of the domain when falling back to current website URL if no filter is found, when using single click (Right-click already used full URL).">
+
<!ENTITY about.version.101 "! Fixed a spelling error preventing ASF to work when no filter matched.
! Added a missing Russian string on the filter's tab.">
diff --git a/locale/ru/asf.dtd b/locale/ru/asf.dtd
index d81af84..09f9237 100644
--- a/locale/ru/asf.dtd
+++ b/locale/ru/asf.dtd
@@ -1,5 +1,5 @@
<!-- ASF -->
-<!ENTITY asf.version "1.0.2b Rev73">
+<!ENTITY asf.version "1.0.2b Rev74">
<!-- browser and save dialog-->
<!ENTITY prefwindow.title "Настройки Automatic Save Folder">
@@ -43,6 +43,7 @@
<!ENTITY asf.dialogaccept.bool "Автоматически использовать настройку "Как FireFox следует обработать это файл".">
<!ENTITY asf.dialogacceptFiltered.bool "Только если найден фильтр">
<!ENTITY asf.dialogacceptFiltered.tooltip "Не будет автоматически использовать настройку "Как FireFox следует обработать это файл" если не найдено подходящего фильтра.">
+<!ENTITY asf.dialogacceptForceSavefile.bool "Force the radio choice to "Save File" before automatically accepting the save dialog.">
<!ENTITY asf.viewdloption.bool "Показывать опции при загрузке">
<!ENTITY asf.viewdloption.tooltip "Показывать две последних использованных папки и кнопку для добавления и редактирования фильтров">
<!ENTITY asf.viewdloptionType0.label "Всегда показывать">
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/automatic-save-folder.git
More information about the Pkg-mozext-commits
mailing list