FoxToPhone 1.2b2.Compatibility with Https Everywhere, updated translations. Reset max version to a valid one.

This commit is contained in:
amla70
2011-07-18 14:22:43 +00:00
parent 7144924853
commit e0a66f24a1
10 changed files with 52 additions and 20 deletions

View File

@@ -25,6 +25,14 @@ sendtophone.init = function()
document.getElementById("contentAreaContextMenu"). document.getElementById("contentAreaContextMenu").
addEventListener("popupshowing", function (e){ sendtophone.showFirefoxContextMenu(e); }, false); addEventListener("popupshowing", function (e){ sendtophone.showFirefoxContextMenu(e); }, false);
// Hide URL bar and other chrome on the uploads window
var prevFunc = XULBrowserWindow.hideChromeForLocation;
XULBrowserWindow.hideChromeForLocation = function(aLocation) {
return (aLocation=='chrome://sendtophone/content/uploads.xul') || prevFunc.apply(XULBrowserWindow, [aLocation]);
}
} }
sendtophone.installToolbarButton = function() sendtophone.installToolbarButton = function()

View File

@@ -1,14 +1,10 @@
"use strict"; "use strict";
let Cc = Components.classes; Components.utils.import("resource://gre/modules/DownloadUtils.jsm");
let Ci = Components.interfaces; Components.utils.import("resource://gre/modules/PluralForm.jsm");
let Cu = Components.utils; Components.utils.import("resource://sendtophone/uploadsManager.js");
Cu.import("resource://gre/modules/DownloadUtils.jsm"); let FoxToPhoneUploadListener = {
Cu.import("resource://gre/modules/PluralForm.jsm");
Cu.import("resource://sendtophone/uploadsManager.js");
let gUploadListener = {
UploadsView: null, UploadsView: null,
fileAdded: function(data) fileAdded: function(data)
@@ -36,8 +32,8 @@ let gUploadListener = {
// Use a 0 ms timeout to avoid flicker while compress -> upload a folder // Use a 0 ms timeout to avoid flicker while compress -> upload a folder
// The trick won't work if in order to upload the file itself we have to perform an extra request before // The trick won't work if in order to upload the file itself we have to perform an extra request before
// (like creating a gallery in min.us) // (like creating a gallery in min.us)
let checkTimer = Cc["@mozilla.org/timer;1"].createInstance(Ci.nsITimer); let checkTimer = Components.classes["@mozilla.org/timer;1"].createInstance(Components.interfaces.nsITimer);
checkTimer.initWithCallback( this.checkTimerEvent, 0, Ci.nsITimer.TYPE_ONE_SHOT ); checkTimer.initWithCallback( this.checkTimerEvent, 0, Components.interfaces.nsITimer.TYPE_ONE_SHOT );
}, },
checkTimerEvent : checkTimerEvent :
@@ -46,7 +42,7 @@ let gUploadListener = {
{ {
if (!sendtophoneUploadsManager.isWindowNeeded(true)) if (!sendtophoneUploadsManager.isWindowNeeded(true))
{ {
if (gUploadListener.UploadsView.children.length==0) if (FoxToPhoneUploadListener.UploadsView.children.length==0)
window.close(); window.close();
} }
} }
@@ -83,17 +79,17 @@ let FoxToPhoneUploadWindow = {
{ {
this.UploadManager = sendtophoneUploadsManager; this.UploadManager = sendtophoneUploadsManager;
gUploadListener.UploadsView = document.getElementById("UploadsBox"); FoxToPhoneUploadListener.UploadsView = document.getElementById("UploadsBox");
this.UploadManager.addListener(gUploadListener); this.UploadManager.addListener(FoxToPhoneUploadListener);
for (let id in this.UploadManager.uploads) for (let id in this.UploadManager.uploads)
gUploadListener.addFile( this.UploadManager.uploads[id] ); FoxToPhoneUploadListener.addFile( this.UploadManager.uploads[id] );
}, },
Shutdown: function() Shutdown: function()
{ {
this.UploadManager.removeListener(gUploadListener); this.UploadManager.removeListener(FoxToPhoneUploadListener);
}, },
performCancelCommand: function(aItem) performCancelCommand: function(aItem)

View File

@@ -8,7 +8,9 @@
<window xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" <window xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
id="sendtophoneUploadsWindow" id="sendtophoneUploadsWindow"
onload="FoxToPhoneUploadWindow.Startup();" onunload="FoxToPhoneUploadWindow.Shutdown();" onload="FoxToPhoneUploadWindow.Startup();" onunload="FoxToPhoneUploadWindow.Shutdown();"
onclose="return closeWindow(false);"> onclose="return closeWindow(false);"
title="Fox To Phone - &sendtophoneFileTransfers.label;"
>
<script type="application/javascript" src="chrome://sendtophone/content/uploads.js"/> <script type="application/javascript" src="chrome://sendtophone/content/uploads.js"/>

View File

@@ -22,3 +22,8 @@
<!ENTITY sendtophoneContextSendClipboard.accesskey "C"> <!ENTITY sendtophoneContextSendClipboard.accesskey "C">
<!ENTITY sendtophoneContextVideo.label "Odeslat video do telefonu"> <!ENTITY sendtophoneContextVideo.label "Odeslat video do telefonu">
<!ENTITY sendtophoneContextVideo.accesskey "V"> <!ENTITY sendtophoneContextVideo.accesskey "V">
<!ENTITY sendtophoneFileTransfers.label "Přenos souborů">
<!ENTITY sendtophoneFileServer.label "Server">
<!ENTITY sendtophoneFileServer.None "Žádný">
<!ENTITY sendtophoneFileServer.Custom "Vlastní">
<!ENTITY sendtophoneFileServer.Disclaimer "Upozornění: My (vývojáři FoxToPhone) nejsme spojeni s žádným z provozovatelů hostingových služeb. Měli by jste si přečíst Právní Podmínky před použitím jejich služeb.">

View File

@@ -22,3 +22,8 @@
<!ENTITY sendtophoneContextSendClipboard.accesskey "K"> <!ENTITY sendtophoneContextSendClipboard.accesskey "K">
<!ENTITY sendtophoneContextVideo.label "Video naar Android verzenden"> <!ENTITY sendtophoneContextVideo.label "Video naar Android verzenden">
<!ENTITY sendtophoneContextVideo.accesskey "V"> <!ENTITY sendtophoneContextVideo.accesskey "V">
<!ENTITY sendtophoneFileTransfers.label "Bestandsoverdrachten">
<!ENTITY sendtophoneFileServer.label "Server">
<!ENTITY sendtophoneFileServer.None "Geen">
<!ENTITY sendtophoneFileServer.Custom "Aangepast">
<!ENTITY sendtophoneFileServer.Disclaimer "Disclaimer: Wij (de ontwikkelaars van FoxToPhone) zijn niet gelieerd aan de hier genoemde externe hostingdiensten. U dient de erbij behorende servicevoorwaarden te lezen voordat u er gebruik van maakt.">

View File

@@ -22,3 +22,8 @@
<!ENTITY sendtophoneContextSendClipboard.accesskey "C"> <!ENTITY sendtophoneContextSendClipboard.accesskey "C">
<!ENTITY sendtophoneContextVideo.label "Отправить видео в телефон"> <!ENTITY sendtophoneContextVideo.label "Отправить видео в телефон">
<!ENTITY sendtophoneContextVideo.accesskey "V"> <!ENTITY sendtophoneContextVideo.accesskey "V">
<!ENTITY sendtophoneFileTransfers.label "Передача файла">
<!ENTITY sendtophoneFileServer.label "Сервет">
<!ENTITY sendtophoneFileServer.None "Ничего">
<!ENTITY sendtophoneFileServer.Custom "Произвольный">
<!ENTITY sendtophoneFileServer.Disclaimer "Мы, разработчики Fox To Phone, никак не связаны с владельцами сервисов перечисленными здесь. Прочитайте их условия использования перед использованием.">

View File

@@ -22,3 +22,8 @@
<!ENTITY sendtophoneContextSendClipboard.accesskey "Т"> <!ENTITY sendtophoneContextSendClipboard.accesskey "Т">
<!ENTITY sendtophoneContextVideo.label "Пошаљи видео на Андроид"> <!ENTITY sendtophoneContextVideo.label "Пошаљи видео на Андроид">
<!ENTITY sendtophoneContextVideo.accesskey "Д"> <!ENTITY sendtophoneContextVideo.accesskey "Д">
<!ENTITY sendtophoneFileTransfers.label "Пренос датотека">
<!ENTITY sendtophoneFileServer.label "Сервер">
<!ENTITY sendtophoneFileServer.None "Ниједан">
<!ENTITY sendtophoneFileServer.Custom "Прилагођени">
<!ENTITY sendtophoneFileServer.Disclaimer "Напомена: ми, аутори додатка FoxToPhone, нсимо повезани ни са једним хостингом наведеним овде. Требало би да прочитате њихове услове коришћења пре него што их почнете користити.">

View File

@@ -13,6 +13,12 @@
} }
} }
#UploadsBox {
-moz-appearance: none;
background-color: ThreeDFace;
border:none;
}
/* Upload View Items */ /* Upload View Items */
richlistitem[type="upload"] { richlistitem[type="upload"] {
padding: 4px 8px 4px 4px; padding: 4px 8px 4px 4px;

View File

@@ -4,7 +4,7 @@
<em:id>sendtophone@martinezdelizarrondo.com</em:id> <em:id>sendtophone@martinezdelizarrondo.com</em:id>
<em:type>2</em:type> <em:type>2</em:type>
<em:name>Fox To Phone</em:name> <em:name>Fox To Phone</em:name>
<em:version>1.2beta1</em:version> <em:version>1.2beta2</em:version>
<em:creator>Alfonso &amp; Patrick</em:creator> <em:creator>Alfonso &amp; Patrick</em:creator>
<em:description>Send links to your Android 2.2 phone using the new C2DM service. Based on the ChromeToPhone extension.</em:description> <em:description>Send links to your Android 2.2 phone using the new C2DM service. Based on the ChromeToPhone extension.</em:description>
@@ -28,7 +28,7 @@
<Description> <Description>
<em:id>{ec8030f7-c20a-464f-9b0e-13a3a9e97384}</em:id> <!-- Firefox --> <em:id>{ec8030f7-c20a-464f-9b0e-13a3a9e97384}</em:id> <!-- Firefox -->
<em:minVersion>3.5</em:minVersion> <em:minVersion>3.5</em:minVersion>
<em:maxVersion>8.*</em:maxVersion> <em:maxVersion>7.*</em:maxVersion>
</Description> </Description>
</em:targetApplication> </em:targetApplication>

View File

@@ -25,7 +25,7 @@ var sendtophoneCore = {
req : null, req : null,
apiVersion : 6, apiVersion : 6,
apkUrl : "http://code.google.com/p/chrometophone/wiki/AndroidApp", apkUrl : "http://code.google.com/p/chrometophone/wiki/AndroidApp",
returnOAuthUrl : "http://code.google.com/p/chrometophone/logo", returnOAuthUrl : "https://code.google.com/p/chrometophone/logo",
retryCount : 0, retryCount : 0,
init: function() init: function()