зеркало из https://github.com/mozilla/pjs.git
Backing out bug 458898 to try to fix Windows orange
This commit is contained in:
Коммит
5a78a8065f
|
@ -417,7 +417,7 @@ public:
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the visible area associated with this presentation context.
|
* Get the visible area associated with this presentation context.
|
||||||
* This is the size of the visible area that is used for
|
* This is the size of the visiable area that is used for
|
||||||
* presenting the document. The returned value is in the standard
|
* presenting the document. The returned value is in the standard
|
||||||
* nscoord units (as scaled by the device context).
|
* nscoord units (as scaled by the device context).
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -94,7 +94,6 @@ _TEST_FILES = \
|
||||||
test_bug445810.html \
|
test_bug445810.html \
|
||||||
test_bug449781.html \
|
test_bug449781.html \
|
||||||
test_bug450930.xhtml \
|
test_bug450930.xhtml \
|
||||||
test_bug458898.html \
|
|
||||||
$(NULL)
|
$(NULL)
|
||||||
# test_bug396024.html is currently disabled because it interacts badly with
|
# test_bug396024.html is currently disabled because it interacts badly with
|
||||||
# the "You can't print-preview while the page is loading" dialog.
|
# the "You can't print-preview while the page is loading" dialog.
|
||||||
|
|
|
@ -1,38 +0,0 @@
|
||||||
<!DOCTYPE HTML>
|
|
||||||
<html>
|
|
||||||
<!--
|
|
||||||
https://bugzilla.mozilla.org/show_bug.cgi?id=458898
|
|
||||||
-->
|
|
||||||
<head>
|
|
||||||
<title>Test for Bug 458898</title>
|
|
||||||
<script type="text/javascript" src="/MochiKit/MochiKit.js"></script>
|
|
||||||
<script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
|
|
||||||
<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
|
|
||||||
<script type="application/javascript" src="/tests/SimpleTest/EventUtils.js"></script>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=458898">Mozilla Bug 458898</a>
|
|
||||||
<p id="display"></p>
|
|
||||||
<div id="content" style="display: none">
|
|
||||||
</div>
|
|
||||||
<pre id="test">
|
|
||||||
<script class="testbody" type="text/javascript">
|
|
||||||
|
|
||||||
SimpleTest.waitForExplicitFinish();
|
|
||||||
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
|
|
||||||
var win = window.openDialog("data:text/html,<div style='height:200px; width:100px;'>");
|
|
||||||
|
|
||||||
function loaded() {
|
|
||||||
win.sizeToContent();
|
|
||||||
ok(win.innerWidth >= 100, "innerWidth");
|
|
||||||
ok(win.innerHeight >= 200, "innerHeight");
|
|
||||||
win.close();
|
|
||||||
SimpleTest.finish();
|
|
||||||
}
|
|
||||||
|
|
||||||
win.addEventListener("load", loaded, false);
|
|
||||||
|
|
||||||
</script>
|
|
||||||
</pre>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -709,16 +709,9 @@ CanvasFrame::Reflow(nsPresContext* aPresContext,
|
||||||
viewport->Invalidate(nsRect(nsPoint(0, 0), viewport->GetSize()));
|
viewport->Invalidate(nsRect(nsPoint(0, 0), viewport->GetSize()));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Return our desired size. Normally it's what we're told, but
|
// Return our desired size (which doesn't matter)
|
||||||
// sometimes we can be given an unconstrained height (when a window
|
|
||||||
// is sizing-to-content), and we should compute our desired height.
|
|
||||||
aDesiredSize.width = aReflowState.ComputedWidth();
|
aDesiredSize.width = aReflowState.ComputedWidth();
|
||||||
if (aReflowState.ComputedHeight() == NS_UNCONSTRAINEDSIZE) {
|
aDesiredSize.height = aReflowState.ComputedHeight();
|
||||||
aDesiredSize.height = kidFrame->GetRect().height +
|
|
||||||
kidReflowState.mComputedMargin.TopBottom();
|
|
||||||
} else {
|
|
||||||
aDesiredSize.height = aReflowState.ComputedHeight();
|
|
||||||
}
|
|
||||||
|
|
||||||
aDesiredSize.mOverflowArea.UnionRect(
|
aDesiredSize.mOverflowArea.UnionRect(
|
||||||
nsRect(0, 0, aDesiredSize.width, aDesiredSize.height),
|
nsRect(0, 0, aDesiredSize.width, aDesiredSize.height),
|
||||||
|
|
Загрузка…
Ссылка в новой задаче