Remove border collapse argument from compute_border_and_padding

This commit is contained in:
Keith Yeung 2017-08-25 23:41:55 -07:00
parent 3c42792efa
commit 1df72ba935
6 changed files with 12 additions and 33 deletions

View file

@ -1305,14 +1305,10 @@ impl Fragment {
/// Computes the border and padding in both inline and block directions from the containing
/// block inline-size and the style. After this call, the `border_padding` field will be
/// correct.
///
/// TODO(pcwalton): Remove `border_collapse`; we can figure it out from our style and specific
/// fragment info.
pub fn compute_border_and_padding(&mut self,
containing_block_inline_size: Au,
border_collapse: border_collapse::T) {
containing_block_inline_size: Au) {
// Compute border.
let border = match border_collapse {
let border = match self.style.get_inheritedtable().border_collapse {
border_collapse::T::separate => self.border_width(),
border_collapse::T::collapse => LogicalMargin::zero(self.style.writing_mode),
};