Skip to content
This repository has been archived by the owner on Aug 4, 2022. It is now read-only.

Commit

Permalink
Merge mozilla-central into birch
Browse files Browse the repository at this point in the history
  • Loading branch information
ehsan committed Apr 22, 2012
2 parents 6c9ba7a + 4c91386 commit 08cbbae
Show file tree
Hide file tree
Showing 270 changed files with 5,929 additions and 2,457 deletions.
2 changes: 0 additions & 2 deletions browser/app/macbuild/Contents/Info.plist.in
Original file line number Diff line number Diff line change
Expand Up @@ -203,8 +203,6 @@
<string>%APP_VERSION%</string>
<key>NSAppleScriptEnabled</key>
<true/>
<key>CGDisableCoalescedUpdates</key>
<true/>
<key>LSMinimumSystemVersion</key>
<string>10.5</string>
<key>LSMinimumSystemVersionByArchitecture</key>
Expand Down
9 changes: 5 additions & 4 deletions browser/app/profile/firefox.js
Original file line number Diff line number Diff line change
Expand Up @@ -877,7 +877,7 @@ pref("browser.ssl_override_behavior", 2);
// 0 - do not show domain
// 1 - show effectiveTLD + 1 (e.g. mozilla.org)
// 2 - show full domain (e.g. bugzilla.mozilla.org)
pref("browser.identity.ssl_domain_display", 1);
pref("browser.identity.ssl_domain_display", 0);

// True if the user should be prompted when a web application supports
// offline apps.
Expand Down Expand Up @@ -980,7 +980,6 @@ pref("services.sync.prefs.sync.browser.download.manager.scanWhenDone", true);
pref("services.sync.prefs.sync.browser.download.manager.showWhenStarting", true);
pref("services.sync.prefs.sync.browser.formfill.enable", true);
pref("services.sync.prefs.sync.browser.link.open_newwindow", true);
pref("services.sync.prefs.sync.browser.newtabpage.enabled", true);
pref("services.sync.prefs.sync.browser.offline-apps.notify", true);
pref("services.sync.prefs.sync.browser.safebrowsing.enabled", true);
pref("services.sync.prefs.sync.browser.safebrowsing.malware.enabled", true);
Expand All @@ -996,7 +995,6 @@ pref("services.sync.prefs.sync.browser.tabs.warnOnClose", true);
pref("services.sync.prefs.sync.browser.tabs.warnOnOpen", true);
pref("services.sync.prefs.sync.browser.tabs.onTop", true);
pref("services.sync.prefs.sync.browser.urlbar.autocomplete.enabled", true);
pref("services.sync.prefs.sync.browser.urlbar.autoFill", true);
pref("services.sync.prefs.sync.browser.urlbar.default.behavior", true);
pref("services.sync.prefs.sync.browser.urlbar.maxRichResults", true);
pref("services.sync.prefs.sync.dom.disable_open_during_load", true);
Expand All @@ -1005,7 +1003,6 @@ pref("services.sync.prefs.sync.dom.disable_window_move_resize", true);
pref("services.sync.prefs.sync.dom.event.contextmenu.enabled", true);
pref("services.sync.prefs.sync.extensions.personas.current", true);
pref("services.sync.prefs.sync.extensions.update.enabled", true);
pref("services.sync.prefs.sync.general.smoothScroll", true);
pref("services.sync.prefs.sync.intl.accept_languages", true);
pref("services.sync.prefs.sync.javascript.enabled", true);
pref("services.sync.prefs.sync.layout.spellcheckDefault", true);
Expand Down Expand Up @@ -1055,6 +1052,10 @@ pref("devtools.inspector.htmlPanelOpen", false);
pref("devtools.inspector.sidebarOpen", false);
pref("devtools.inspector.activeSidebar", "ruleview");
// Enable the Layout View
pref("devtools.layoutview.enabled", false);
pref("devtools.layoutview.open", false);
// Enable the Debugger
pref("devtools.debugger.enabled", false);
Expand Down
4 changes: 2 additions & 2 deletions browser/base/content/abouthome/aboutHome.css
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,6 @@ html {
font: message-box;
font-size: 100%;
background-color: hsl(0,0%,90%);
background-image: url(chrome://browser/content/abouthome/noise.png),
-moz-linear-gradient(hsla(0,0%,100%,.7), hsla(0,0%,100%,.4));
color: #000;
height: 100%;
}
Expand All @@ -57,6 +55,8 @@ body {
-moz-box-orient: vertical;
width: 100%;
height: 100%;
background-image: url(chrome://browser/content/abouthome/noise.png),
-moz-linear-gradient(hsla(0,0%,100%,.7), hsla(0,0%,100%,.4));
}

input,
Expand Down
24 changes: 0 additions & 24 deletions browser/base/content/browser.js
Original file line number Diff line number Diff line change
Expand Up @@ -2686,30 +2686,11 @@ function SetPageProxyState(aState)
if (aState == "valid") {
gLastValidURLStr = gURLBar.value;
gURLBar.addEventListener("input", UpdatePageProxyState, false);

PageProxySetIcon(gBrowser.getIcon());
} else if (aState == "invalid") {
gURLBar.removeEventListener("input", UpdatePageProxyState, false);
PageProxyClearIcon();
}
}

function PageProxySetIcon (aURL)
{
if (!gProxyFavIcon)
return;

if (!aURL)
PageProxyClearIcon();
else if (gProxyFavIcon.getAttribute("src") != aURL)
gProxyFavIcon.setAttribute("src", aURL);
}

function PageProxyClearIcon ()
{
gProxyFavIcon.removeAttribute("src");
}

function PageProxyClickHandler(aEvent)
{
if (aEvent.button == 1 && gPrefService.getBoolPref("middlemouse.paste"))
Expand Down Expand Up @@ -4629,11 +4610,6 @@ var XULBrowserWindow = {
return "_blank";
},

onLinkIconAvailable: function (aIconURL) {
if (gProxyFavIcon && gBrowser.userTypedValue === null)
PageProxySetIcon(aIconURL); // update the favicon in the URL bar
},

onProgressChange: function (aWebProgress, aRequest,
aCurSelfProgress, aMaxSelfProgress,
aCurTotalProgress, aMaxTotalProgress) {
Expand Down
5 changes: 2 additions & 3 deletions browser/base/content/browser.xul
Original file line number Diff line number Diff line change
Expand Up @@ -542,9 +542,8 @@
<hbox id="identity-box-inner" align="center">
<hbox id="page-proxy-stack"
onclick="PageProxyClickHandler(event);">
<image id="page-proxy-favicon" validate="never"
pageproxystate="invalid"
onerror="this.removeAttribute('src');"/>
<image id="page-proxy-favicon"
pageproxystate="invalid"/>
</hbox>
<hbox id="identity-icon-labels">
<label id="identity-icon-label" class="plain" flex="1"/>
Expand Down
12 changes: 12 additions & 0 deletions browser/base/content/highlighter.css
Original file line number Diff line number Diff line change
Expand Up @@ -100,3 +100,15 @@ html|*#highlighter-nodeinfobar-tagname {
.devtools-toolbarbutton:not([label]) > .toolbarbutton-text {
display: none;
}

#inspector-layoutview-container > iframe {
-moz-transition-property: height;
-moz-transition-duration: 0.1s;
/* header size */
height: 22px;
}

#inspector-layoutview-container > iframe[open] {
/* header size + layout view size: 22px + 155px */
height: 177px;
}
10 changes: 9 additions & 1 deletion browser/base/content/nsContextMenu.js
Original file line number Diff line number Diff line change
Expand Up @@ -528,8 +528,16 @@ nsContextMenu.prototype = {
this.onCanvas = true;
}
else if (this.target instanceof HTMLVideoElement) {
this.onVideo = true;
this.mediaURL = this.target.currentSrc || this.target.src;
// Firefox always creates a HTMLVideoElement when loading an ogg file
// directly. If the media is actually audio, be smarter and provide a
// context menu with audio operations.
if (this.target.readyState >= this.target.HAVE_METADATA &&
(this.target.videoWidth == 0 || this.target.videoHeight == 0)) {
this.onAudio = true;
} else {
this.onVideo = true;
}
}
else if (this.target instanceof HTMLAudioElement) {
this.onAudio = true;
Expand Down
1 change: 1 addition & 0 deletions browser/base/content/test/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ _TEST_FILES = \
# test_contextmenu.html is disabled on Linux due to bug 513558
ifneq (gtk2,$(MOZ_WIDGET_TOOLKIT))
_TEST_FILES += \
audio.ogg \
test_contextmenu.html \
subtst_contextmenu.html \
$(NULL)
Expand Down
Binary file added browser/base/content/test/audio.ogg
Binary file not shown.
59 changes: 38 additions & 21 deletions browser/base/content/test/browser_identity_UI.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
/* Tests for correct behaviour of getEffectiveHost on identity handler */
function test() {
waitForExplicitFinish();
registerCleanupFunction(function() {
Services.prefs.clearUserPref("browser.identity.ssl_domain_display");
});

ok(gIdentityHandler, "gIdentityHandler should exist");

Expand Down Expand Up @@ -72,34 +75,48 @@ let gCurrentTest, gCurrentTestIndex = -1, gTestDesc;
// Go through the tests in both directions, to add additional coverage for
// transitions between different states.
let gForward = true;
let gCheckETLD = false;
function nextTest() {
if (gForward)
gCurrentTestIndex++;
else
gCurrentTestIndex--;
if (!gCheckETLD) {
if (gForward)
gCurrentTestIndex++;
else
gCurrentTestIndex--;

if (gCurrentTestIndex == tests.length) {
// Went too far, reverse
gCurrentTestIndex--;
gForward = false;
}
if (gCurrentTestIndex == tests.length) {
// Went too far, reverse
gCurrentTestIndex--;
gForward = false;
}

if (gCurrentTestIndex == -1) {
gBrowser.selectedBrowser.removeEventListener("load", checkResult, true);
gBrowser.removeCurrentTab();
finish();
return;
}
if (gCurrentTestIndex == -1) {
gBrowser.selectedBrowser.removeEventListener("load", checkResult, true);
gBrowser.removeCurrentTab();
finish();
return;
}

gCurrentTest = tests[gCurrentTestIndex];
gTestDesc = "#" + gCurrentTestIndex + " (" + gCurrentTest.name + ")";
if (!gForward)
gTestDesc += " (second time)";
content.location = gCurrentTest.location;
gCurrentTest = tests[gCurrentTestIndex];
gTestDesc = "#" + gCurrentTestIndex + " (" + gCurrentTest.name + ")";
if (!gForward)
gTestDesc += " (second time)";
if (gCurrentTest.isHTTPS) {
gCheckETLD = true;
Services.prefs.setIntPref("browser.identity.ssl_domain_display", 1);
}
content.location = gCurrentTest.location;
} else {
gCheckETLD = false;
gTestDesc = "#" + gCurrentTestIndex + " (" + gCurrentTest.name + " without eTLD in identity icon label)";
if (!gForward)
gTestDesc += " (second time)";
Services.prefs.clearUserPref("browser.identity.ssl_domain_display");
content.location.reload(true);
}
}

function checkResult() {
if (gCurrentTest.isHTTPS) {
if (gCurrentTest.isHTTPS && Services.prefs.getIntPref("browser.identity.ssl_domain_display") == 1) {
// Check that the effective host is displayed in the UI
let label = document.getElementById("identity-icon-label");
is(label.value, gCurrentTest.effectiveHost, "effective host is displayed in identity icon label for test " + gTestDesc);
Expand Down
1 change: 1 addition & 0 deletions browser/base/content/test/subtst_contextmenu.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
<img id="test-image" src="ctxmenu-image.png">
<canvas id="test-canvas" width="100" height="100" style="background-color: blue"></canvas>
<video controls id="test-video-ok" src="video.ogg" width="100" height="100" style="background-color: green"></video>
<video id="test-audio-in-video" src="audio.ogg" width="100" height="100" style="background-color: red"></video>
<video controls id="test-video-bad" src="bogus.duh" width="100" height="100" style="background-color: orange"></video>
<video controls id="test-video-bad2" width="100" height="100" style="background-color: yellow">
<source src="bogus.duh" type="video/durrrr;">
Expand Down
Loading

0 comments on commit 08cbbae

Please sign in to comment.