Remove reference counting from the Runtime implementation.

This commit is contained in:
Ms2ger 2015-05-10 17:02:32 +02:00
parent 9abe47b76f
commit cfe240d117
7 changed files with 17 additions and 15 deletions

View file

@ -134,7 +134,7 @@ pub struct Window {
dom_static: GlobalStaticData,
/// The JavaScript runtime.
js_runtime: DOMRefCell<Option<Runtime>>,
js_runtime: DOMRefCell<Option<Rc<Runtime>>>,
/// A handle for communicating messages to the layout task.
layout_chan: LayoutChan,
@ -883,7 +883,7 @@ impl<'a> WindowHelpers for JSRef<'a, Window> {
}
impl Window {
pub fn new(runtime: Runtime,
pub fn new(runtime: Rc<Runtime>,
page: Rc<Page>,
script_chan: Box<ScriptChan+Send>,
image_cache_chan: ImageCacheChan,