mirror of
https://github.com/servo/servo.git
synced 2025-08-03 20:50:07 +01:00
Unconditionally remove repaint damage for table cells/rows/rgs
This commit is contained in:
parent
c2de3eb9ac
commit
180b29ae66
4 changed files with 15 additions and 8 deletions
|
@ -1147,6 +1147,8 @@ impl<'table> Iterator for TableCellStyleIterator<'table> {
|
||||||
|
|
||||||
impl<'table> TableCellStyleInfo<'table> {
|
impl<'table> TableCellStyleInfo<'table> {
|
||||||
fn build_display_list(&self, mut state: &mut DisplayListBuildState) {
|
fn build_display_list(&self, mut state: &mut DisplayListBuildState) {
|
||||||
|
use style::computed_values::visibility::T as Visibility;
|
||||||
|
|
||||||
if !self.cell.visible || self.cell.block_flow.fragment.style()
|
if !self.cell.visible || self.cell.block_flow.fragment.style()
|
||||||
.get_inheritedbox().visibility != Visibility::Visible {
|
.get_inheritedbox().visibility != Visibility::Visible {
|
||||||
return
|
return
|
||||||
|
|
|
@ -251,11 +251,9 @@ impl Flow for TableCellFlow {
|
||||||
// This is handled by TableCellStyleInfo::build_display_list()
|
// This is handled by TableCellStyleInfo::build_display_list()
|
||||||
// when the containing table builds its display list
|
// when the containing table builds its display list
|
||||||
|
|
||||||
if self.visible {
|
// we skip setting the damage in TableCellStyleInfo::build_display_list()
|
||||||
// we skip setting the damage in TableCellStyleInfo::build_display_list()
|
// because we only have immutable access
|
||||||
// because we only have immutable access
|
self.block_flow.fragment.restyle_damage.remove(ServoRestyleDamage::REPAINT);
|
||||||
self.block_flow.fragment.restyle_damage.remove(ServoRestyleDamage::REPAINT);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fn collect_stacking_contexts(&mut self, state: &mut StackingContextCollectionState) {
|
fn collect_stacking_contexts(&mut self, state: &mut StackingContextCollectionState) {
|
||||||
|
|
|
@ -467,7 +467,11 @@ impl Flow for TableRowFlow {
|
||||||
}
|
}
|
||||||
|
|
||||||
fn build_display_list(&mut self, _: &mut DisplayListBuildState) {
|
fn build_display_list(&mut self, _: &mut DisplayListBuildState) {
|
||||||
|
use style::servo::restyle_damage::ServoRestyleDamage;
|
||||||
// handled in TableCellStyleInfo::build_display_list
|
// handled in TableCellStyleInfo::build_display_list
|
||||||
|
// we skip setting the damage in TableCellStyleInfo::build_display_list()
|
||||||
|
// because we only have immutable access
|
||||||
|
self.block_flow.fragment.restyle_damage.remove(ServoRestyleDamage::REPAINT);
|
||||||
}
|
}
|
||||||
|
|
||||||
fn collect_stacking_contexts(&mut self, state: &mut StackingContextCollectionState) {
|
fn collect_stacking_contexts(&mut self, state: &mut StackingContextCollectionState) {
|
||||||
|
|
|
@ -176,9 +176,12 @@ impl Flow for TableRowGroupFlow {
|
||||||
self.block_flow.update_late_computed_block_position_if_necessary(block_position)
|
self.block_flow.update_late_computed_block_position_if_necessary(block_position)
|
||||||
}
|
}
|
||||||
|
|
||||||
fn build_display_list(&mut self, state: &mut DisplayListBuildState) {
|
fn build_display_list(&mut self, _: &mut DisplayListBuildState) {
|
||||||
debug!("build_display_list_table_rowgroup: same process as block flow");
|
use style::servo::restyle_damage::ServoRestyleDamage;
|
||||||
self.block_flow.build_display_list(state);
|
|
||||||
|
// we skip setting the damage in TableCellStyleInfo::build_display_list()
|
||||||
|
// because we only have immutable access
|
||||||
|
self.block_flow.fragment.restyle_damage.remove(ServoRestyleDamage::REPAINT);
|
||||||
}
|
}
|
||||||
|
|
||||||
fn collect_stacking_contexts(&mut self, state: &mut StackingContextCollectionState) {
|
fn collect_stacking_contexts(&mut self, state: &mut StackingContextCollectionState) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue