зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1517385 - Use "visibility: hidden" to keep the frame of AccessibleCaret alive. r=TYLin
Differential Revision: https://phabricator.services.mozilla.com/D94072
This commit is contained in:
Родитель
8b352f1843
Коммит
87625add43
|
@ -114,9 +114,11 @@ nsAutoString AccessibleCaret::AppearanceString(Appearance aAppearance) {
|
|||
nsAutoString string;
|
||||
switch (aAppearance) {
|
||||
case Appearance::None:
|
||||
case Appearance::NormalNotShown:
|
||||
string = u"none"_ns;
|
||||
break;
|
||||
case Appearance::NormalNotShown:
|
||||
string = u"hidden"_ns;
|
||||
break;
|
||||
case Appearance::Normal:
|
||||
string = u"normal"_ns;
|
||||
break;
|
||||
|
|
|
@ -0,0 +1,18 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<meta charset="utf-8">
|
||||
|
||||
<style>
|
||||
#content {
|
||||
position: absolute;
|
||||
font-size: 20px;
|
||||
width: 20px;
|
||||
top: 0;
|
||||
right: 0;
|
||||
}
|
||||
</style>
|
||||
|
||||
<body>
|
||||
<div id="content">A</div>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,28 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<meta charset="utf-8">
|
||||
<title>Bug 1517385: Test AccessibleCaret doesn't occupied space when its appearance is Appearance::None.</title>
|
||||
|
||||
<style>
|
||||
#content {
|
||||
position: absolute;
|
||||
font-size: 20px;
|
||||
width: 20px;
|
||||
top: 0;
|
||||
right: 0;
|
||||
}
|
||||
</style>
|
||||
|
||||
<script>
|
||||
function runTest() {
|
||||
let sel = window.getSelection();
|
||||
let content = document.getElementById("content");
|
||||
sel.selectAllChildren(content);
|
||||
sel.removeAllRanges();
|
||||
}
|
||||
</script>
|
||||
|
||||
<body onload="runTest()">
|
||||
<div id="content">A</div>
|
||||
</body>
|
||||
</html>
|
|
@ -2072,6 +2072,7 @@ pref(layout.css.supports-selector.enabled,false) != 1499386.html 1499386-ref.htm
|
|||
fuzzy-if(winWidget&&!webrender,0-104,0-1423) == 1513423-1.html 1513423-1-ref.html
|
||||
fuzzy-if(winWidget&&!webrender,0-89,0-1420) == 1513423-2.html 1513423-2-ref.html
|
||||
== 1513423-3.html 1513423-3-ref.html
|
||||
pref(layout.accessiblecaret.enabled,true) == 1517385.html 1517385-ref.html
|
||||
fuzzy-if(!webrender,1-5,66-547) fuzzy-if(geckoview&&!webrender,1-2,64-141) == 1529992-1.html 1529992-1-ref.html
|
||||
fuzzy-if(!webrender,0-6,0-34) fuzzy-if(Android,9-14,44-60) fails-if(webrender) == 1529992-2.html 1529992-2-ref.html
|
||||
== 1535040-1.html 1535040-1-ref.html
|
||||
|
|
|
@ -455,6 +455,10 @@ div:-moz-native-anonymous.moz-accessiblecaret.none {
|
|||
display: none;
|
||||
}
|
||||
|
||||
div:-moz-native-anonymous.moz-accessiblecaret.hidden {
|
||||
visibility: hidden;
|
||||
}
|
||||
|
||||
@media (min-resolution: 1.5dppx) {
|
||||
div:-moz-native-anonymous.moz-accessiblecaret.normal > #image {
|
||||
background-image: url("resource://gre-resources/accessiblecaret-normal@1.5x.png");
|
||||
|
|
Загрузка…
Ссылка в новой задаче