diff options
Diffstat (limited to 'components/script/task_source/file_reading.rs')
-rw-r--r-- | components/script/task_source/file_reading.rs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/components/script/task_source/file_reading.rs b/components/script/task_source/file_reading.rs index 8f4cdd80ac3..e94f957234c 100644 --- a/components/script/task_source/file_reading.rs +++ b/components/script/task_source/file_reading.rs @@ -4,17 +4,18 @@ use dom::domexception::DOMErrorName; use dom::filereader::{FileReader, TrustedFileReader, GenerationId, ReadMetaData}; +use msg::constellation_msg::PipelineId; use script_runtime::{CommonScriptMsg, ScriptThreadEventCategory, ScriptChan}; use std::sync::Arc; use task::{TaskCanceller, TaskOnce}; use task_source::TaskSource; #[derive(JSTraceable)] -pub struct FileReadingTaskSource(pub Box<ScriptChan + Send + 'static>); +pub struct FileReadingTaskSource(pub Box<ScriptChan + Send + 'static>, pub PipelineId); impl Clone for FileReadingTaskSource { fn clone(&self) -> FileReadingTaskSource { - FileReadingTaskSource(self.0.clone()) + FileReadingTaskSource(self.0.clone(), self.1.clone()) } } @@ -30,7 +31,7 @@ impl TaskSource for FileReadingTaskSource { self.0.send(CommonScriptMsg::Task( ScriptThreadEventCategory::FileRead, Box::new(canceller.wrap_task(task)), - None //TODO + Some(self.1), )) } } |