Bug 1007065 - Don't apply the special -moz-hidden-unscrollable clipping on nsTextControlFrame since it always has an anonymous scroll frame that deals with overflow. r=roc

This commit is contained in:
Mats Palmgren 2014-05-12 11:45:27 +00:00
parent 37dafacbce
commit ddbe5a9099
5 changed files with 37 additions and 0 deletions

View File

@ -0,0 +1,15 @@
<html class="reftest-wait">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body onload="start()">
<input type="text" style="text-align:right;">
<script>
function start() {
var input = document.querySelector("input");
input.focus();
document.documentElement.removeAttribute("class");
}
</script>
</body>
</html>

View File

@ -0,0 +1,15 @@
<html class="reftest-wait">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body onload="start()">
<input type="text" style="text-align:right; overflow:hidden;">
<script>
function start() {
var input = document.querySelector("input");
input.focus();
document.documentElement.removeAttribute("class");
}
</script>
</body>
</html>

View File

@ -157,6 +157,8 @@ support-files =
bug966992-2-ref.html
bug966992-3.html
bug966992-3-ref.html
bug1007065-1.html
bug1007065-1-ref.html
[test_bug514127.html]
[test_bug518777.html]
[test_bug548545.xhtml]

View File

@ -136,6 +136,7 @@ var tests = [
[ 'bug682712-1.html' , 'bug682712-1-ref.html' ] ,
function() {SpecialPowers.clearUserPref("bidi.browser.ui");} ,
[ 'bug746993-1.html' , 'bug746993-1-ref.html' ] ,
[ 'bug1007065-1.html' , 'bug1007065-1-ref.html' ] ,
];
if (navigator.appVersion.indexOf("Android") == -1 &&

View File

@ -583,6 +583,10 @@ public:
return true;
}
if (aFrame->IsFrameOfType(nsIFrame::eReplacedContainsBlock)) {
if (type == nsGkAtoms::textInputFrame) {
// It always has an anonymous scroll frame that handles any overflow.
return false;
}
return true;
}
}