mirror of
https://github.com/servo/servo.git
synced 2025-08-04 05:00:08 +01:00
dereference via * instead of RefMut
This commit is contained in:
parent
14ac1ef75a
commit
7758f81ffd
1 changed files with 6 additions and 6 deletions
|
@ -97,7 +97,7 @@ use url::{Url, UrlParser};
|
||||||
use libc;
|
use libc;
|
||||||
use std::any::Any;
|
use std::any::Any;
|
||||||
use std::borrow::ToOwned;
|
use std::borrow::ToOwned;
|
||||||
use std::cell::{Cell, RefCell, RefMut};
|
use std::cell::{Cell, RefCell};
|
||||||
use std::collections::HashSet;
|
use std::collections::HashSet;
|
||||||
use std::io::{stdout, Write};
|
use std::io::{stdout, Write};
|
||||||
use std::mem as std_mem;
|
use std::mem as std_mem;
|
||||||
|
@ -1329,7 +1329,7 @@ impl ScriptTask {
|
||||||
// TODO(tkuehn): currently there is only one window,
|
// TODO(tkuehn): currently there is only one window,
|
||||||
// so this can afford to be naive and just shut down the
|
// so this can afford to be naive and just shut down the
|
||||||
// compositor. In the future it'll need to be smarter.
|
// compositor. In the future it'll need to be smarter.
|
||||||
(*(RefMut::map(self.compositor.borrow_mut(), |t| t))).send(ScriptToCompositorMsg::Exit).unwrap();
|
(*(self.compositor.borrow_mut())).send(ScriptToCompositorMsg::Exit).unwrap();
|
||||||
}
|
}
|
||||||
|
|
||||||
/// We have received notification that the response associated with a load has completed.
|
/// We have received notification that the response associated with a load has completed.
|
||||||
|
@ -1506,7 +1506,7 @@ impl ScriptTask {
|
||||||
MainThreadScriptChan(sender.clone()),
|
MainThreadScriptChan(sender.clone()),
|
||||||
self.image_cache_channel.clone(),
|
self.image_cache_channel.clone(),
|
||||||
self.control_chan.clone(),
|
self.control_chan.clone(),
|
||||||
(*(RefMut::map(self.compositor.borrow_mut(), |t| t))).clone(),
|
(*(self.compositor.borrow_mut())).clone(),
|
||||||
self.image_cache_task.clone(),
|
self.image_cache_task.clone(),
|
||||||
self.resource_task.clone(),
|
self.resource_task.clone(),
|
||||||
self.storage_task.clone(),
|
self.storage_task.clone(),
|
||||||
|
@ -1601,8 +1601,8 @@ impl ScriptTask {
|
||||||
// Really what needs to happen is that this needs to go through layout to ask which
|
// Really what needs to happen is that this needs to go through layout to ask which
|
||||||
// layer the element belongs to, and have it send the scroll message to the
|
// layer the element belongs to, and have it send the scroll message to the
|
||||||
// compositor.
|
// compositor.
|
||||||
(*(RefMut::map(self.compositor.borrow_mut(), |t| t))).send(
|
(*(self.compositor.borrow_mut())).send(ScriptToCompositorMsg::ScrollFragmentPoint(
|
||||||
ScriptToCompositorMsg::ScrollFragmentPoint(pipeline_id, LayerId::null(), point)).unwrap();
|
pipeline_id, LayerId::null(), point)).unwrap();
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Reflows non-incrementally, rebuilding the entire layout tree in the process.
|
/// Reflows non-incrementally, rebuilding the entire layout tree in the process.
|
||||||
|
@ -1700,7 +1700,7 @@ impl ScriptTask {
|
||||||
let page = get_page(&self.root_page(), pipeline_id);
|
let page = get_page(&self.root_page(), pipeline_id);
|
||||||
let document = page.document();
|
let document = page.document();
|
||||||
document.r().dispatch_key_event(
|
document.r().dispatch_key_event(
|
||||||
key, state, modifiers, &mut *(RefMut::map(self.compositor.borrow_mut(), |t| t)));
|
key, state, modifiers, &mut (*(self.compositor.borrow_mut())) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue