Bug 1374233 - Part 13: Use NonNegative{*} types for components of Shadow and Filter.

MozReview-Commit-ID: Im4KGy1n9IJ
This commit is contained in:
Boris Chiou 2017-07-24 18:08:27 +08:00
parent 6dd8b159d7
commit 8651acd94c
13 changed files with 84 additions and 53 deletions

View file

@ -2570,7 +2570,7 @@ impl Fragment {
// Box shadows cause us to draw outside our border box.
for box_shadow in &self.style().get_effects().box_shadow.0 {
let offset = Vector2D::new(box_shadow.base.horizontal, box_shadow.base.vertical);
let inflation = box_shadow.spread + box_shadow.base.blur * BLUR_INFLATION_FACTOR;
let inflation = box_shadow.spread + box_shadow.base.blur.0 * BLUR_INFLATION_FACTOR;
overflow.paint = overflow.paint.union(&border_box.translate(&offset)
.inflate(inflation, inflation))
}