Bug 759568 - Part 4. mochitest for background-clip:text; r=heycom

MozReview-Commit-ID: 8DrBq8nNWfu
This commit is contained in:
CJKu 2016-04-14 16:28:07 +08:00
Родитель 45fda349c6
Коммит 1cbaa6fc28
2 изменённых файлов: 29 добавлений и 1 удалений

Просмотреть файл

@ -94,7 +94,7 @@ function do_test() {
"snow", "springgreen", "steelblue", "tan", "teal", "thistle", "tomato", "transparent", "turquoise",
"violet", "wheat", "white", "whitesmoke", "yellow", "yellowgreen", "no-repeat", "repeat",
"repeat-x", "repeat-y", "fixed", "scroll", "local", "center", "top", "bottom", "left", "right",
"border-box", "padding-box", "content-box", "border-box", "padding-box", "content-box", "contain",
"border-box", "padding-box", "content-box", "border-box", "padding-box", "content-box", "text", "contain",
"cover", "rgb", "hsl", "rgba", "hsla", "none", "-moz-element", "-moz-image-rect", "url", "linear-gradient",
"radial-gradient", "repeating-linear-gradient", "repeating-radial-gradient", "-moz-linear-gradient",
"-moz-radial-gradient", "-moz-repeating-linear-gradient", "-moz-repeating-radial-gradient" ];

Просмотреть файл

@ -2229,6 +2229,10 @@ var gCSSProperties = {
/* error inside functions */
"-moz-image-rect(url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAKElEQVR42u3NQQ0AAAgEoNP+nTWFDzcoQE1udQQCgUAgEAgEAsGTYAGjxAE/G/Q2tQAAAABJRU5ErkJggg==), rubbish, 50%, 30%, 0) transparent",
"-moz-element(#a rubbish) black",
"text",
"text border-box",
"content-box text text",
"padding-box text url(404.png) text",
]
},
"background-attachment": {
@ -7392,6 +7396,30 @@ if (IsCSSPropertyPrefEnabled("layout.css.text-emphasis.enabled")) {
};
}
if (IsCSSPropertyPrefEnabled("layout.css.background-clip-text.enabled")) {
gCSSProperties["background-clip"].other_values.push(
"text",
"content-box, text",
"text, border-box",
"text, text"
);
gCSSProperties["background"].other_values.push(
"url(404.png) green padding-box text",
"content-box text url(404.png) blue"
);
} else {
gCSSProperties["background-clip"].invalid_values.push(
"text",
"content-box, text",
"text, border-box",
"text, text"
);
gCSSProperties["background"].invalid_values.push(
"url(404.png) green padding-box text",
"content-box text url(404.png) blue"
);
}
// Copy aliased properties' fields from their alias targets.
for (var prop in gCSSProperties) {
var entry = gCSSProperties[prop];