Skip to content

Commit

Permalink
Auto merge of #10993 - pcwalton:fix-animations, r=glennw
Browse files Browse the repository at this point in the history
compositing: Perform animation-related compositing operations in WebRender.

I accidentally removed this code in #10936.

Fixes transitions.

r? @glennw

<!-- 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/10993)
<!-- Reviewable:end -->
  • Loading branch information
bors-servo committed May 4, 2016
2 parents b4f573d + 62c6d8b commit d5a64a9
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions components/compositing/compositor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -633,7 +633,7 @@ impl<Window: WindowMethods> IOCompositor<Window> {
debug!("delayed composition timeout!");
if let CompositionRequest::DelayedComposite(this_timestamp) =
self.composition_request {
if timestamp == this_timestamp && !opts::get().use_webrender {
if timestamp == this_timestamp {
self.composition_request = CompositionRequest::CompositeNow(
CompositingReason::DelayedCompositeTimeout)
}
Expand Down Expand Up @@ -752,7 +752,7 @@ impl<Window: WindowMethods> IOCompositor<Window> {
match animation_state {
AnimationState::AnimationsPresent => {
self.pipeline_details(pipeline_id).animations_running = true;
self.composite_if_necessary_if_not_using_webrender(CompositingReason::Animation);
self.composite_if_necessary(CompositingReason::Animation);
}
AnimationState::AnimationCallbacksPresent => {
if !self.pipeline_details(pipeline_id).animation_callbacks_running {
Expand Down Expand Up @@ -1662,9 +1662,12 @@ impl<Window: WindowMethods> IOCompositor<Window> {
/// necessary.
fn perform_updates_after_scroll(&mut self) {
self.send_updated_display_ports_to_layout();
if opts::get().use_webrender {
return
}
if self.send_buffer_requests_for_all_layers() {
self.schedule_delayed_composite_if_necessary();
} else if !opts::get().use_webrender {
} else {
self.channel_to_self.send(Msg::Recomposite(CompositingReason::ContinueScroll));
}
}
Expand Down

0 comments on commit d5a64a9

Please sign in to comment.