diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/content/common.js releases/unplug-2.038/source/chrome/content/common.js
135c135
< version : 2.037,
---
> version : 2.038,
139c139
< revision : 201011212112,
---
> revision : 201011292108,
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/content/config/config.xul releases/unplug-2.038/source/chrome/content/config/config.xul
8,9d7
<
< %dtdunplugresult;
122,123c120,121
<
<
---
>
>
124a123,126
>
>
>
>
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/content/config/extern.js releases/unplug-2.038/source/chrome/content/config/extern.js
0a1,105
> /*
> * _ ___
> * /\ / /___ / _ \ /\ /\ _ ___
> * / // // _ \ / // // // // // _ \
> * / // // // / / ___// // // // // /
> * \___//_//_/ /_/ /_/ \___/ \_ /
> * \___/
> *
> * Compunach UnPlug
> * Copyright (C) 2010 David Batley
> *
> * This program is free software: you can redistribute it and/or modify
> * it under the terms of the GNU Affero General Public License as
> * published by the Free Software Foundation, either version 3 of the
> * License, or (at your option) any later version.
> *
> * This program is distributed in the hope that it will be useful,
> * but WITHOUT ANY WARRANTY; without even the implied warranty of
> * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
> * GNU General Public License for more details.
> *
> * You should have received a copy of the GNU Affero General Public License
> * along with this program. If not, see .
> *
> */
>
> var get_config_name = (function () {
> return (window.arguments && window.arguments[0]) || "ERROR";
> });
>
> var is_valid_file = (function (fname) {
> var f = Components.classes["@mozilla.org/file/local;1"]
> .createInstance(Components.interfaces.nsILocalFile);
> f.initWithPath(fname);
> return (f.exists() && f.isExecutable());
> });
>
> var onload = (function () {
> var config_name = get_config_name();
> var config_info = UnPlug2DownloadMethods.getinfo(config_name);
>
> var setup_dialog = (function () {
> document.getElementById("need-to-install").setAttribute("value",
> UnPlug2.str("need_to_install").replace("%s", UnPlug2.str("dmethod." + config_name)));
> document.getElementById("location-of").setAttribute("value",
> UnPlug2.str("location_of").replace("%s", UnPlug2.str("dmethod." + config_name)));
> if (config_info && config_info.weblinks) {
> var linkbox = document.getElementById("link-box");
> for (var i = 0; i < config_info.weblinks.length; ++i) {
> var l = document.createElement("label");
> l.className = "text-link";
> l.setAttribute("href", config_info.weblinks[i].url);
> l.setAttribute("value", config_info.weblinks[i].label);
> linkbox.appendChild(l);
> }
> }
> });
> var search_usual_places = (function () {
> var value = UnPlug2.get_pref("dmethod." + config_name) || "";
> document.getElementById("execfile").value = "";
> if (value && is_valid_file(value)) {
> document.getElementById("execfile").value = value;
> } else {
> if (config_info && config_info.exec_file_list) {
> for (var i = 0; i < config_info.exec_file_list.length; ++i) {
> if (is_valid_file(config_info.exec_file_list[i])) {
> document.getElementById("execfile").value = config_info.exec_file_list[i];
> break;
> }
> }
> }
> }
> document.getElementById("execfile").disabled = false;
> document.getElementById("browsebutton").disabled = false;
> });
> setup_dialog();
> window.setTimeout(search_usual_places, 2);
> });
> window.addEventListener("load", onload, false);
>
> var onaccept = (function () {
> var config_name = get_config_name();
> var elem = document.getElementById("execfile");
> if (!elem.value || is_valid_file(elem.value)) {
> UnPlug2.set_pref("dmethod." + config_name, elem.value);
> } else {
> alert("Not an executable file: " + elem.value);
> elem.focus();
> return false; // inhibit closing of page
> }
> });
>
>
> var dobrowse = (function () {
> var filepicker = Components.classes["@mozilla.org/filepicker;1"]
> .createInstance(Components.interfaces.nsIFilePicker);
> filepicker.init(window, "Location of progam",
> Components.interfaces.nsIFilePicker.modeOpen);
>
> var ret = filepicker.show()
> if (ret == Components.interfaces.nsIFilePicker.returnOK) {
> document.getElementById("execfile").value = filepicker.file.path;
> }
> });
>
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/content/config/extern.xul releases/unplug-2.038/source/chrome/content/config/extern.xul
0a1,65
>
>
>
> %dtdcommon;
>
> %dtdlocal;
> ]>
>
>
>
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/content/display/download.js releases/unplug-2.038/source/chrome/content/display/download.js
1c1,27
< UnPlug2DownloadMethods = {
---
> /*
> * _ ___
> * /\ / /___ / _ \ /\ /\ _ ___
> * / // // _ \ / // // // // // _ \
> * / // // // / / ___// // // // // /
> * \___//_//_/ /_/ /_/ \___/ \_ /
> * \___/
> *
> * Compunach UnPlug
> * Copyright (C) 2010 David Batley
> *
> * This program is free software: you can redistribute it and/or modify
> * it under the terms of the GNU Affero General Public License as
> * published by the Free Software Foundation, either version 3 of the
> * License, or (at your option) any later version.
> *
> * This program is distributed in the hope that it will be useful,
> * but WITHOUT ANY WARRANTY; without even the implied warranty of
> * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
> * GNU General Public License for more details.
> *
> * You should have received a copy of the GNU Affero General Public License
> * along with this program. If not, see .
> *
> */
>
> var UnPlug2DownloadMethods = {
69c95,104
< if (data.exec_fp) {
---
> if (data.signal_get_argv) {
> var exec_file = UnPlug2.get_pref("dmethod." + name);
> if (!this._nsifile_if_exec(exec_file)) {
> window.openDialog("chrome://unplug/content/config/extern.xul", "chrome,modal", "unplug_extern", name);
> return; // note: signal to downloader won't get sent
> }
> UnPlug2ExternDownloader.signal({
> result: result,
> name : name });
> } else if (data.exec_fp) {
72d106
< // TODO move this _save_as_box code here
82a117,162
> exec_from_signal : (function (signal) {
> /*
> * This code is executed from display/extern/extern.xul
> * and is triggered by sending that window a postMessage.
> *
> * IMPORTANT
> * Currently this shows a save-as dialog, but future versions
> * may start a download without asking. In practice this means
> * data may be saved to an arbitary location on disk, so this
> * should only be called based on a response from priviliged
> * code.
> */
> var data = this._button_lookup[signal.name];
> if (!data) {
> throw "Unknown button name " + signal.name;
> }
> var file = this._save_as_box(signal.result.details.name, signal.result.details.file_ext);
> if (!file) {
> return null;
> }
>
> var exec_file = UnPlug2.get_pref("dmethod." + signal.name);
> exec_file = this._nsifile_if_exec(exec_file);
> if (!exec_file) {
> throw "UnPlug display - this is not an exec_file"
> }
> var argv = data.signal_get_argv(signal.result, file);
> var process = Components.classes["@mozilla.org/process/util;1"]
> .createInstance(Components.interfaces.nsIProcess);
> process.init(exec_file);
> // we use runwAsync and use utf-16 strings, otherwise you get junk for
> // filenames due to the unicode encoding conversions
> if (!process.runwAsync) {
> alert("Firefox 4 required");
> throw "nsIProcess.runwAsync is not implemented";
> }
> process.runwAsync(
> argv,
> argv.length,
> null, // we could use an nsIObserver here, but we'll just poll process.isRunning for now
> false );
> return {
> process : process,
> file : file.file }
> }),
>
137a218,227
> }),
>
> _nsifile_if_exec : (function (fname) {
> if (!fname) {
> return null;
> }
> var f = Components.classes["@mozilla.org/file/local;1"]
> .createInstance(Components.interfaces.nsILocalFile);
> f.initWithPath(fname);
> return (f.exists() && f.isExecutable()) ? f : null;
140a231,266
> var UnPlug2ExternDownloader = {
> window_name : "x-unplug-exten-dld",
> url : "chrome://unplug/content/display/extern/extern.xul",
> get_window : (function () {
> var wm = Components.classes["@mozilla.org/appshell/window-mediator;1"]
> .getService(Components.interfaces.nsIWindowMediator);
> // var wl = wm.getEnumerator("dialog");
> var wl = wm.getEnumerator(null);
> while (wl.hasMoreElements()) {
> var win = wl.getNext().QueryInterface(Components.interfaces.nsIDOMWindow);
> if (win.location == this.url) {
> return win;
> }
> }
> return null;
> }),
> signal : (function (action) {
> var action = window.JSON.stringify(action);
> var extern_window = this.get_window();
> if (extern_window) {
> extern_window.postMessage(action, "*");
> } else {
> extern_window = window.openDialog(this.url, "", "chrome");
> var onload = (function (action) {
> return (function () {
> this.postMessage(action, "*");
> });
> })(action);
> extern_window.addEventListener("load", onload, false);
> }
> })
> }
>
>
> // ----- download method definitions follow -----
>
272,274c398,408
< exec : (function (res) {
< alert("Sorry, this feature is not available yet");
< }),
---
> signal_get_argv : (function (res, savefile) {
> return [
> "--rtmp", res.download.url,
> "--pageUrl", res.download.referer,
> "--swfUrl", res.download.referer, // this is invalid, but good enough most of the time.
> "--flv", savefile.file.path ];
> }),
> exec_file_list : [
> "/usr/bin/rtmpdump" ],
> weblinks : [
> { url : "http://rtmpdump.mplayerhq.hu/", label : "rtmpdump.mplayerhq.hu" }],
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/content/display/extern/extern.js releases/unplug-2.038/source/chrome/content/display/extern/extern.js
0a1,112
> /*
> * _ ___
> * /\ / /___ / _ \ /\ /\ _ ___
> * / // // _ \ / // // // // // _ \
> * / // // // / / ___// // // // // /
> * \___//_//_/ /_/ /_/ \___/ \_ /
> * \___/
> *
> * Compunach UnPlug
> * Copyright (C) 2010 David Batley
> *
> * This program is free software: you can redistribute it and/or modify
> * it under the terms of the GNU Affero General Public License as
> * published by the Free Software Foundation, either version 3 of the
> * License, or (at your option) any later version.
> *
> * This program is distributed in the hope that it will be useful,
> * but WITHOUT ANY WARRANTY; without even the implied warranty of
> * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
> * GNU General Public License for more details.
> *
> * You should have received a copy of the GNU Affero General Public License
> * along with this program. If not, see .
> *
> */
>
> UnPlug2Extern = {
> watching : [],
>
> add_program_box : (function (download_method, filename) {
> var template = document.getElementById("program-template");
> var container = document.getElementById("program-container");
> var dupe = template.cloneNode(true);
> var labels = dupe.getElementsByTagName("label");
> dupe.setAttribute("collapsed", false);
> dupe.getElementsByTagName("description")[0].setAttribute("value", filename);
> labels[0].setAttribute("value", UnPlug2.str("dmethod." + download_method));
> container.appendChild(dupe);
> this.set_program_box_status(dupe, 0, "running");
> return dupe;
> }),
>
> set_program_box_status : (function (doc, file_size, process_status) {
> var labels = doc.getElementsByTagName("label");
> file_size = (file_size / (1024 * 1024)).toPrecision(2) + " MiB";
> labels[1].setAttribute("value", file_size);
> labels[2].setAttribute("value", UnPlug2.str("proc.status." + process_status));
> doc.className = "process process-status-" + process_status;
> }),
>
> receive_signal_callback : (function () {
> var extern = this;
> return (function (event) {
> /*
> * IMPORTANT
> * Anyone can send signals to this window, so it is
> * vitally important to check the message comes from
> * privilidged code (chrome).
> */
> if (event.origin.indexOf("chrome:") != 0) {
> return;
> }
> var msg = window.JSON.parse(event.data);
> var rtn = UnPlug2DownloadMethods.exec_from_signal(msg);
> if (rtn) {
> rtn.node = extern.add_program_box(msg.name, rtn.file.leafName);
> extern.setup_kill_button(rtn);
> extern.watching.push(rtn);
> }
> });
> }),
>
> setup_kill_button : (function (rtn) {
> rtn.node.getElementsByTagName("button")[0].addEventListener("command", (function () {
> rtn.was_killed = true;
> rtn.process.kill();
> }), false);
> }),
>
> remove_kill_button : (function (doc) {
> var n = doc.getElementsByTagName("button")[0];
> n.parentNode.removeChild(n);
> }),
>
> poll : (function () {
> var extern = this;
> extern.watching.filter(function (item, idx, arr) {
> var file_size = 0;
> if (item.file.exists()) {
> file_size = item.file.fileSize;
> }
> if (item.process.isRunning) {
> extern.set_program_box_status(item.node, file_size, "running");
> } else {
> if (item.was_killed || item.process.exitValue) {
> extern.set_program_box_status(item.node, file_size, "error");
> } else {
> extern.set_program_box_status(item.node, file_size, "done");
> }
> // remove from array
> extern.remove_kill_button(item.node);
> return false;
> }
> return true;
> });
> })
> }
>
> window.addEventListener("message", UnPlug2Extern.receive_signal_callback(), false);
> window.setInterval((function () { UnPlug2Extern.poll() }), 3000);
>
>
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/content/display/extern/extern.xul releases/unplug-2.038/source/chrome/content/display/extern/extern.xul
0a1,67
>
>
>
>
> %dtdcommon;
> ]>
>
>
>
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/content/rules.xml releases/unplug-2.038/source/chrome/content/rules.xml
39c39
< adxpansion.com
---
> adtechus.com
40a41
> adxpansion.com
291,292c292,293
<
<
---
>
>
472a474,482
>
>
>
>
>
>
>
>
>
873a884,900
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/locale/de-DE/strings.txt releases/unplug-2.038/source/chrome/locale/de-DE/strings.txt
56a57,59
> proc.status.error=Fehler
> proc.status.running=Läufen
> proc.status.done=Fertig
57a61,63
> # external download methods
> need_to_install=You need to install %s to download this file
> location_of=Location of %s
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/locale/en-US/strings.txt releases/unplug-2.038/source/chrome/locale/en-US/strings.txt
57a58,65
> proc.status.error=Error
> proc.status.running=Running
> proc.status.done=Done
>
> # external download methods
> need_to_install=You need to install %s to download this file
> location_of=Location of %s
>
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/locale/hu-HU/common.dtd releases/unplug-2.038/source/chrome/locale/hu-HU/common.dtd
0a1,35
>
>
>
>
>
>
>
>
>
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/locale/hu-HU/config.dtd releases/unplug-2.038/source/chrome/locale/hu-HU/config.dtd
0a1,75
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/locale/hu-HU/overlay.dtd releases/unplug-2.038/source/chrome/locale/hu-HU/overlay.dtd
0a1,12
>
>
>
>
>
>
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/locale/hu-HU/searchpage.dtd releases/unplug-2.038/source/chrome/locale/hu-HU/searchpage.dtd
0a1,39
>
>
>
>
>
>
>
>
>
>
>
>
>
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/locale/hu-HU/strings.txt releases/unplug-2.038/source/chrome/locale/hu-HU/strings.txt
0a1,64
> extensions.{unplug@compunach}.description=Beágyazott média letöltés
>
> # Confirmation after clicking on "Nothing found" button
> nothing_found_send_data=Akarsz információt küldeni az Unplug fejlesztőinek erről a weboldalról?
>
> # Short status strings during/after clicking "Nothing found" button
> nothing_found_sending=Küldés...
> nothing_found_done=Köszönet!
> nothing_found_failed=Hiba
>
> # for below the search box
> search_done=Kész
> search_busy=Dolgozik
> search_1_active_download=1 oldal keresés
> search_n_active_downloads=# oldal keresés
> search_no_results_yet=Nincs találat
> search_1_result=1 találat
> search_n_results=# találat
> search_no_results=Nincs találat
> cannot_download_this_kind=Nem lehet letölteni ezt a típusú fájlt
>
>
> # for rules.xml
> high_quality=Magas minőség
> low_quality=Alacsony minőség
> mid_quality=Normál minőség
> hd_quality=Nagy felbontás
> embedplayer=Beágyazott objektum (valószínűleg médialejátszó, nem video)
>
> # download methods
> dmethod.open-tab=Megnyitás új fülön
> dmethod.open-tab.a=f
> dmethod.open-tab.tip=Megnyitás új fülön.
> dmethod.open-new=Megnyitás új ablakban
> dmethod.open-new.a=a
> dmethod.open-new.tip=Megnyitás új ablakban.
> dmethod.open-over=Megnyitás a jelenlegi ablakban
> dmethod.open-over.a=j
> dmethod.open-over.tip=Egyenértékű a weboldalon lévő média linkjére kattintással.
> dmethod.saveas=Mentés másként
> dmethod.saveas.a=M
> dmethod.saveas.tip=A Firefox alapértelmezett letöltéskezelőjének használata.
> dmethod.dta=DownThemAll
> dmethod.dta.a=A
> dmethod.dta.tip=Letöltés a DownThemAll kiegészítővel.
> dmethod.flashgot=FlashGot
> dmethod.flashgot.a=F
> dmethod.flashgot.tip=Letöltés a FlashGot kiegészítővel.
> dmethod.copyurl=Link másolása
> dmethod.copyurl.a=L
> dmethod.copyurl.tip=Média címének másolása a vágólapra.
> dmethod.rtmpdump=Rtmpdump
> dmethod.rtmpdump.a=R
> dmethod.rtmpdump.tip=Eszköz (rtmpdump) beszerzése vagy futtatása.
> dmethod.unavailable.tip=Nem lehet letölteni ezt a fájlt.
>
> proc.status.error=Error
> proc.status.running=Running
> proc.status.done=Done
>
> # external download methods
> need_to_install=You need to install %s to download this file
> location_of=Location of %s
>
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/locale/pl-PL/strings.txt releases/unplug-2.038/source/chrome/locale/pl-PL/strings.txt
56a57,63
> proc.status.error=Error
> proc.status.running=Running
> proc.status.done=Done
>
> # external download methods
> need_to_install=You need to install %s to download this file
> location_of=Location of %s
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome/skin/extern.css releases/unplug-2.038/source/chrome/skin/extern.css
0a1,20
>
> .process .filename {
> overflow: hidden;
> }
>
> .process .status {
> font-weight: bold;
> }
>
> .process-status-done .status {
> color: #00cc00;
> }
>
> .process-status-error .status {
> color: #cc0000;
> }
>
> .process-status-running .status {
> color: #000000;
> }
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/chrome.manifest releases/unplug-2.038/source/chrome.manifest
12a13
> locale unplug hu-HU chrome/locale/hu-HU/
diff --new-file --recursive --suppress-common-lines --exclude changes.txt --exclude diff.txt releases/unplug-2.037/source/install.rdf releases/unplug-2.038/source/install.rdf
8c8
< em:maxVersion="4.0b6" />
---
> em:maxVersion="4.0b7" />
11c11
< em:version="2.037"
---
> em:version="2.038"
Binary files releases/unplug-2.037/unplug.xpi and releases/unplug-2.038/unplug.xpi differ