mirror of
https://github.com/servo/servo.git
synced 2025-08-05 21:50:18 +01:00
Invert control flow, fix resizing, and improve checkerboarding
significantly by giving tiles some time to paint before we render unrendered content.
This commit is contained in:
parent
e483a189a3
commit
10f7b49cf7
27 changed files with 1195 additions and 678 deletions
|
@ -2,7 +2,7 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use dom::bindings::cell::{DOMRefCell, Ref};
|
||||
use dom::bindings::cell::{DOMRefCell, Ref, RefMut};
|
||||
use dom::bindings::codegen::Bindings::EventHandlerBinding::{OnErrorEventHandlerNonNull, EventHandlerNonNull};
|
||||
use dom::bindings::codegen::Bindings::WindowBinding;
|
||||
use dom::bindings::codegen::Bindings::WindowBinding::WindowMethods;
|
||||
|
@ -53,7 +53,7 @@ pub struct Window {
|
|||
location: MutNullableJS<Location>,
|
||||
navigator: MutNullableJS<Navigator>,
|
||||
image_cache_task: ImageCacheTask,
|
||||
compositor: Box<ScriptListener+'static>,
|
||||
compositor: DOMRefCell<Box<ScriptListener+'static>>,
|
||||
browser_context: DOMRefCell<Option<BrowserContext>>,
|
||||
page: Rc<Page>,
|
||||
performance: MutNullableJS<Performance>,
|
||||
|
@ -81,8 +81,8 @@ impl Window {
|
|||
&self.image_cache_task
|
||||
}
|
||||
|
||||
pub fn compositor<'a>(&'a self) -> &'a ScriptListener+'static {
|
||||
&*self.compositor
|
||||
pub fn compositor(&self) -> RefMut<Box<ScriptListener+'static>> {
|
||||
self.compositor.borrow_mut()
|
||||
}
|
||||
|
||||
pub fn browser_context(&self) -> Ref<Option<BrowserContext>> {
|
||||
|
@ -398,7 +398,7 @@ impl Window {
|
|||
script_chan: script_chan,
|
||||
control_chan: control_chan,
|
||||
console: Default::default(),
|
||||
compositor: compositor,
|
||||
compositor: DOMRefCell::new(compositor),
|
||||
page: page,
|
||||
location: Default::default(),
|
||||
navigator: Default::default(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue