Commit 3011413f authored by Csoregi Natalia's avatar Csoregi Natalia
Browse files

Merge inbound to mozilla-central. a=merge

parents 4ae2fa64 582b8ef5
Loading
Loading
Loading
Loading
+12 −11
Original line number Diff line number Diff line
@@ -145,6 +145,7 @@ var TabsInTitlebar = {

    let titlebar = $("titlebar");
    let titlebarContent = $("titlebar-content");
    let titlebarButtons = $("titlebar-buttonbox");
    let menubar = $("toolbar-menubar");

    if (allowed) {
@@ -155,10 +156,13 @@ var TabsInTitlebar = {

      // Reset the custom titlebar height if the menubar is shown,
      // because we will want to calculate its original height.
      if (AppConstants.isPlatformAndVersionAtLeast("win", "10.0") &&
      let buttonsShouldMatchTabHeight =
        AppConstants.isPlatformAndVersionAtLeast("win", "10.0") ||
        AppConstants.platform == "linux";
      if (buttonsShouldMatchTabHeight &&
          (menubar.getAttribute("inactive") != "true" ||
           menubar.getAttribute("autohide") != "true")) {
        $("titlebar-buttonbox").style.removeProperty("height");
        titlebarButtons.style.removeProperty("height");
      }

      // Try to avoid reflows in this code by calculating dimensions first and
@@ -168,7 +172,7 @@ var TabsInTitlebar = {
      let fullTabsHeight = rect($("TabsToolbar")).height;

      // Buttons first:
      let captionButtonsBoxWidth = rect($("titlebar-buttonbox")).width;
      let captionButtonsBoxWidth = rect(titlebarButtons).width;

      let secondaryButtonsWidth, menuHeight, fullMenuHeight, menuStyles;
      if (AppConstants.platform == "macosx") {
@@ -188,12 +192,11 @@ var TabsInTitlebar = {

      // Begin setting CSS properties which will cause a reflow

      // On Windows 10, adjust the window controls to span the entire
      // Adjust the window controls to span the entire
      // tab strip height if we're not showing a menu bar.
      if (AppConstants.isPlatformAndVersionAtLeast("win", "10.0") &&
          !menuHeight) {
      if (buttonsShouldMatchTabHeight && !menuHeight) {
        titlebarContentHeight = fullTabsHeight;
        $("titlebar-buttonbox").style.height = titlebarContentHeight + "px";
        titlebarButtons.style.height = titlebarContentHeight + "px";
      }

      // If the menubar is around (menuHeight is non-zero), try to adjust
@@ -260,9 +263,7 @@ var TabsInTitlebar = {
        this._sizePlaceholder("fullscreen-button", secondaryButtonsWidth);
      }

      // Reset the margins and padding that might have been modified:
      titlebarContent.style.marginTop = "";
      titlebarContent.style.marginBottom = "";
      // Reset styles that might have been modified:
      titlebar.style.marginBottom = "";
      menubar.style.paddingBottom = "";
    }
+0 −6
Original line number Diff line number Diff line
@@ -315,12 +315,6 @@ toolbarpaletteitem {
.titlebar-placeholder[type="fullscreen-button"]:-moz-locale-dir(rtl) {
  -moz-box-ordinal-group: 0;
}

%else
/* On non-OSX, these should be start-aligned */
#titlebar-buttonbox-container {
  -moz-box-align: start;
}
%endif

%ifdef XP_WIN
+1 −1
Original line number Diff line number Diff line
@@ -6076,7 +6076,7 @@ function stripUnsafeProtocolOnPaste(pasteData) {
    try {
      scheme = Services.io.extractScheme(pasteData);
    } catch (ex) { }
    if (scheme != "javascript") {
    if (scheme.toLowerCase() != "javascript") {
      break;
    }

+2 −0
Original line number Diff line number Diff line
@@ -13,6 +13,8 @@ var pairs = [
  ["http://\nexample.com", "http://example.com"],
  ["http://\nexample.com\n", "http://example.com"],
  ["data:text/html,<body>hi</body>", "data:text/html,<body>hi</body>"],
  ["javaScript:foopy", "foopy"],
  ["javaScript:javaScript:alert('hi')", "alert('hi')"],
  // Nested things get confusing because some things don't parse as URIs:
  ["javascript:javascript:alert('hi!')", "alert('hi!')"],
  ["data:data:text/html,<body>hi</body>", "data:data:text/html,<body>hi</body>"],
+3 −1
Original line number Diff line number Diff line
@@ -7,7 +7,9 @@ add_task(async function test_policy_disable_shield() {
  const { RecipeRunner } = ChromeUtils.import("resource://shield-recipe-client/lib/RecipeRunner.jsm", {});

  await SpecialPowers.pushPrefEnv({ set: [["extensions.shield-recipe-client.api_url",
                                            "https://localhost/selfsupport-dummy/"]] });
                                            "https://localhost/selfsupport-dummy/"],
                                          ["datareporting.healthreport.uploadEnabled",
                                            true]]});

  ok(RecipeRunner, "RecipeRunner exists");
  RecipeRunner.checkPrefs();
Loading