Fix forced repaint on image load

After #10021, `LayoutThread::repaint` no longer forced a repaint because of
the `restyle_damage` check.  This patch adds the correct restyle damage and
fixes #10163.
This commit is contained in:
Matt Brubeck 2016-03-25 14:54:00 -07:00
parent d77c7b21ae
commit afb36ec8de

View file

@ -593,6 +593,11 @@ impl LayoutThread {
fn repaint<'a, 'b>(&mut self, possibly_locked_rw_data: &mut RwData<'a, 'b>) -> bool {
let mut rw_data = possibly_locked_rw_data.lock();
if let Some(mut root_flow) = self.root_flow.clone() {
let flow = flow::mut_base(flow_ref::deref_mut(&mut root_flow));
flow.restyle_damage.insert(REPAINT);
}
let reflow_info = Reflow {
goal: ReflowGoal::ForDisplay,
page_clip_rect: MAX_RECT,