Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sync changes from mozilla-central #3824

Merged
merged 1 commit into from Jan 8, 2020
Merged
Changes from all commits
Commits
File filter...
Filter file types
Jump to…
Jump to file
Failed to load files.

Always

Just for now

@@ -1302,12 +1302,14 @@ impl BorderRadius {
}
}

/// Return whether, in each corner, the radius in *either* direction is zero.
/// This means that none of the corners are rounded.
pub fn is_zero(&self) -> bool {
if let Some(radius) = self.is_uniform() {
radius == 0.0
} else {
false
}
let corner_is_zero = |corner: &LayoutSize| corner.width == 0.0 || corner.height == 0.0;
corner_is_zero(&self.top_left) &&
corner_is_zero(&self.top_right) &&
corner_is_zero(&self.bottom_right) &&
corner_is_zero(&self.bottom_left)
}
}

ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.