Auto merge of #10197 - mbrubeck:force-repaint, r=pcwalton

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.

r? @pcwalton

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/10197)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2016-03-26 03:47:05 +05:30
commit 8984d95a28

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,