diff --git a/third_party/firefox_sendtophone/chrome.manifest b/third_party/firefox_sendtophone/chrome.manifest index 923d869..f9df281 100644 --- a/third_party/firefox_sendtophone/chrome.manifest +++ b/third_party/firefox_sendtophone/chrome.manifest @@ -24,3 +24,5 @@ overlay chrome://navigator/content/navigator.xul chrome://sendtophone/content/ff style chrome://global/content/customizeToolbar.xul chrome://sendtophone/skin/overlay.css +# Support for Mac +override chrome://sendtophone/skin/uploads.css chrome://sendtophone/skin/uploads-mac.css os=Darwin diff --git a/third_party/firefox_sendtophone/chrome/content/ff-overlay.js b/third_party/firefox_sendtophone/chrome/content/ff-overlay.js index 935f328..504e510 100644 --- a/third_party/firefox_sendtophone/chrome/content/ff-overlay.js +++ b/third_party/firefox_sendtophone/chrome/content/ff-overlay.js @@ -181,7 +181,7 @@ sendtophone.pickFile = function(folder) else { fp.init(window, this.getString("SendFileToPhone"), Ci.nsIFilePicker.modeOpenMultiple); - fp.appendFilters(Ci.nsIFilePicker.filterAll | Ci.nsIFilePicker.filterImages); + fp.appendFilters( Ci.nsIFilePicker.filterAll ); } var rv = fp.show(); diff --git a/third_party/firefox_sendtophone/chrome/content/options.js b/third_party/firefox_sendtophone/chrome/content/options.js new file mode 100644 index 0000000..2fb34c2 --- /dev/null +++ b/third_party/firefox_sendtophone/chrome/content/options.js @@ -0,0 +1,55 @@ +"use strict"; + +let foxToPhonePreferences = +{ + load: function() + { + let fileServerUrl = document.getElementById("extensions.sendtophone.fileServerUrl").value; + + let fileserverMenuList = document.getElementById("extensionsSendToPhoneFileServer") ; + + switch (fileServerUrl) + { + case '': + fileserverMenuList.value = fileServerUrl; + break; + + case 'http://min.us': + fileserverMenuList.value = fileServerUrl; + break; + + default: + fileserverMenuList.value = 'Custom'; + break; + } + + fileserverMenuList.addEventListener("command", function () { + let fileServer = fileserverMenuList.value; + switch (fileServer) + { + case '': + document.getElementById("extensions.sendtophone.fileServerUrl").value = ''; + break; + + case 'Custom': + break; + + default: + document.getElementById("extensions.sendtophone.fileServerUrl").value = fileServer; + break; + } + + document.getElementById("hboxFileServerUrl").hidden = ( fileServer != 'Custom'); + + window.sizeToContent(); + }, false); + + document.getElementById("hboxFileServerUrl").hidden = ( fileserverMenuList.value != 'Custom'); + + window.sizeToContent(); + + } +} ; + + +this.addEventListener("load", function () {foxToPhonePreferences.load(); }, false); diff --git a/third_party/firefox_sendtophone/chrome/content/options.xul b/third_party/firefox_sendtophone/chrome/content/options.xul index c77cffd..efe6266 100644 --- a/third_party/firefox_sendtophone/chrome/content/options.xul +++ b/third_party/firefox_sendtophone/chrome/content/options.xul @@ -12,6 +12,7 @@ + @@ -29,6 +30,35 @@ label="tel:" /> + + + + + + + + + + + +