diff options
author | Matt A. Tobin <email@mattatobin.com> | 2020-02-25 19:45:39 -0500 |
---|---|---|
committer | wolfbeast <mcwerewolf@wolfbeast.com> | 2020-04-14 12:56:02 +0200 |
commit | d20ca24a070d547be3bce4d513ef151b6be5f955 (patch) | |
tree | b0b56d41c3f41db217e8f894c0545a0217dbba4f /toolkit/content | |
parent | b2ca17a29814f6aaf043240cd1ec2f86ca989419 (diff) | |
download | UXP-d20ca24a070d547be3bce4d513ef151b6be5f955.tar UXP-d20ca24a070d547be3bce4d513ef151b6be5f955.tar.gz UXP-d20ca24a070d547be3bce4d513ef151b6be5f955.tar.lz UXP-d20ca24a070d547be3bce4d513ef151b6be5f955.tar.xz UXP-d20ca24a070d547be3bce4d513ef151b6be5f955.zip |
Issue #1053 - Remove android support from toolkit
Note: Does not remove support completely from toolkit/mozapps/installer or from telemetry or AppConstants.jsm
Diffstat (limited to 'toolkit/content')
-rw-r--r-- | toolkit/content/aboutSupport.js | 10 | ||||
-rw-r--r-- | toolkit/content/aboutSupport.xhtml | 5 | ||||
-rw-r--r-- | toolkit/content/aboutTelemetry.js | 8 | ||||
-rw-r--r-- | toolkit/content/buildconfig.html | 4 | ||||
-rw-r--r-- | toolkit/content/contentAreaUtils.js | 34 | ||||
-rw-r--r-- | toolkit/content/jar.mn | 2 | ||||
-rw-r--r-- | toolkit/content/moz.build | 3 |
7 files changed, 1 insertions, 65 deletions
diff --git a/toolkit/content/aboutSupport.js b/toolkit/content/aboutSupport.js index f49172230..f9a0abcb0 100644 --- a/toolkit/content/aboutSupport.js +++ b/toolkit/content/aboutSupport.js @@ -599,16 +599,6 @@ function copyContentsToClipboard() { let clipboard = Cc["@mozilla.org/widget/clipboard;1"] .getService(Ci.nsIClipboard); clipboard.setData(transferable, null, clipboard.kGlobalClipboard); - -#ifdef MOZ_WIDGET_ANDROID - // Present a toast notification. - let message = { - type: "Toast:Show", - message: stringBundle().GetStringFromName("textCopied"), - duration: "short" - }; - Services.androidBridge.handleGeckoMessage(message); -#endif } // Return the plain text representation of an element. Do a little bit diff --git a/toolkit/content/aboutSupport.xhtml b/toolkit/content/aboutSupport.xhtml index 0b7b52164..8afee1867 100644 --- a/toolkit/content/aboutSupport.xhtml +++ b/toolkit/content/aboutSupport.xhtml @@ -101,7 +101,6 @@ <td id="buildid-box"></td> </tr> -#ifndef ANDROID #ifdef MOZ_UPDATER <tr class="no-copy"> <th class="column"> @@ -115,7 +114,6 @@ </td> </tr> #endif -#endif #ifdef MOZ_UPDATER <tr> @@ -240,7 +238,6 @@ </td> </tr> -#ifndef ANDROID <tr class="no-copy"> <th class="column"> &aboutSupport.appBasicsProfiles; @@ -250,8 +247,6 @@ <a href="about:profiles">about:profiles</a> </td> </tr> -#endif - </tbody> </table> diff --git a/toolkit/content/aboutTelemetry.js b/toolkit/content/aboutTelemetry.js index 0829fe7e2..97dcba9e2 100644 --- a/toolkit/content/aboutTelemetry.js +++ b/toolkit/content/aboutTelemetry.js @@ -233,17 +233,9 @@ var Settings = { let elements = document.getElementsByClassName("change-data-choices-link"); for (let el of elements) { el.addEventListener("click", function() { -#ifdef MOZ_WIDGET_ANDROID - Cu.import("resource://gre/modules/Messaging.jsm"); - Messaging.sendRequest({ - type: "Settings:Show", - resource: "preferences_privacy", - }); -#else // Show the data choices preferences on desktop. let mainWindow = getMainWindowWithPreferencesPane(); mainWindow.openAdvancedPreferences("dataChoicesTab"); -#endif }, false); } }, diff --git a/toolkit/content/buildconfig.html b/toolkit/content/buildconfig.html index d3373f54c..322208189 100644 --- a/toolkit/content/buildconfig.html +++ b/toolkit/content/buildconfig.html @@ -58,9 +58,5 @@ </table> <h2>Configure options</h2> <p>@MOZ_CONFIGURE_OPTIONS@</p> -#ifdef ANDROID -<h2>Package name</h2> -<p>@ANDROID_PACKAGE_NAME@</p> -#endif </body> </html> diff --git a/toolkit/content/contentAreaUtils.js b/toolkit/content/contentAreaUtils.js index 2512804fa..17e463325 100644 --- a/toolkit/content/contentAreaUtils.js +++ b/toolkit/content/contentAreaUtils.js @@ -1115,40 +1115,8 @@ function validateFileName(aFileName) aFileName = aFileName.replace(/[\<]+/g, "("); aFileName = aFileName.replace(/[\>]+/g, ")"); } - else if (navigator.appVersion.indexOf("Macintosh") != -1) + else if (navigator.appVersion.indexOf("Macintosh") != -1) { re = /[\:\/]+/g; - else if (navigator.appVersion.indexOf("Android") != -1) { - // On mobile devices, the filesystem may be very limited in what - // it considers valid characters. To avoid errors, we sanitize - // conservatively. - const dangerousChars = "*?<>|\":/\\[];,+="; - var processed = ""; - for (var i = 0; i < aFileName.length; i++) - processed += aFileName.charCodeAt(i) >= 32 && - !(dangerousChars.indexOf(aFileName[i]) >= 0) ? aFileName[i] - : "_"; - - // Last character should not be a space - processed = processed.trim(); - - // If a large part of the filename has been sanitized, then we - // will use a default filename instead - if (processed.replace(/_/g, "").length <= processed.length/2) { - // We purposefully do not use a localized default filename, - // which we could have done using - // ContentAreaUtils.stringBundle.GetStringFromName("DefaultSaveFileName") - // since it may contain invalid characters. - var original = processed; - processed = "download"; - - // Preserve a suffix, if there is one - if (original.indexOf(".") >= 0) { - var suffix = original.split(".").slice(-1)[0]; - if (suffix && suffix.indexOf("_") < 0) - processed += "." + suffix; - } - } - return processed; } return aFileName.replace(re, "_"); diff --git a/toolkit/content/jar.mn b/toolkit/content/jar.mn index 96c559bb2..c73427a31 100644 --- a/toolkit/content/jar.mn +++ b/toolkit/content/jar.mn @@ -19,10 +19,8 @@ toolkit.jar: #endif content/global/aboutNetworking.js content/global/aboutNetworking.xhtml -#ifndef ANDROID * content/global/aboutProfiles.js content/global/aboutProfiles.xhtml -#endif content/global/aboutServiceWorkers.js content/global/aboutServiceWorkers.xhtml #ifdef MOZ_WEBRTC diff --git a/toolkit/content/moz.build b/toolkit/content/moz.build index b1f6b6419..0a08483b4 100644 --- a/toolkit/content/moz.build +++ b/toolkit/content/moz.build @@ -14,9 +14,6 @@ for var in ('target', DEFINES['CFLAGS'] = CONFIG['OS_CFLAGS'] DEFINES['TOPOBJDIR'] = TOPOBJDIR -if CONFIG['OS_TARGET'] == 'Android': - DEFINES['ANDROID_PACKAGE_NAME'] = CONFIG['ANDROID_PACKAGE_NAME'] - if CONFIG['MOZ_ANDROID_CXX_STL'] == 'libc++': DEFINES['MOZ_USE_LIBCXX'] = True |