Remove the unused PipelineExitType field from ConstellationControlMsg::ExitPipeline.

This commit is contained in:
Ms2ger 2015-11-05 16:29:07 +01:00
parent ef20972023
commit 85a762a31a
3 changed files with 5 additions and 7 deletions

View file

@ -248,13 +248,13 @@ impl Pipeline {
let _ = self.chrome_to_paint_chan.send(ChromeToPaintMsg::PaintPermissionRevoked); let _ = self.chrome_to_paint_chan.send(ChromeToPaintMsg::PaintPermissionRevoked);
} }
pub fn exit(&self, exit_type: PipelineExitType) { pub fn exit(&self, _: PipelineExitType) {
debug!("pipeline {:?} exiting", self.id); debug!("pipeline {:?} exiting", self.id);
// Script task handles shutting down layout, and layout handles shutting down the painter. // Script task handles shutting down layout, and layout handles shutting down the painter.
// For now, if the script task has failed, we give up on clean shutdown. // For now, if the script task has failed, we give up on clean shutdown.
if self.script_chan if self.script_chan
.send(ConstellationControlMsg::ExitPipeline(self.id, exit_type)) .send(ConstellationControlMsg::ExitPipeline(self.id))
.is_ok() { .is_ok() {
// Wait until all slave tasks have terminated and run destructors // Wait until all slave tasks have terminated and run destructors
// NOTE: We don't wait for script task as we don't always own it // NOTE: We don't wait for script task as we don't always own it
@ -275,9 +275,7 @@ impl Pipeline {
} }
pub fn force_exit(&self) { pub fn force_exit(&self) {
let _ = self.script_chan.send( let _ = self.script_chan.send(ConstellationControlMsg::ExitPipeline(self.id)).unwrap();
ConstellationControlMsg::ExitPipeline(self.id,
PipelineExitType::PipelineOnly)).unwrap();
let _ = self.chrome_to_paint_chan.send(ChromeToPaintMsg::Exit( let _ = self.chrome_to_paint_chan.send(ChromeToPaintMsg::Exit(
PipelineExitType::PipelineOnly)); PipelineExitType::PipelineOnly));
let LayoutControlChan(ref layout_channel) = self.layout_chan; let LayoutControlChan(ref layout_channel) = self.layout_chan;

View file

@ -839,7 +839,7 @@ impl ScriptTask {
let result = self.profile_event(category, move || { let result = self.profile_event(category, move || {
match msg { match msg {
MixedMessage::FromConstellation(ConstellationControlMsg::ExitPipeline(id, _)) => { MixedMessage::FromConstellation(ConstellationControlMsg::ExitPipeline(id)) => {
if self.handle_exit_pipeline_msg(id) { if self.handle_exit_pipeline_msg(id) {
return Some(false) return Some(false)
} }

View file

@ -115,7 +115,7 @@ pub enum ConstellationControlMsg {
/// Notifies script that window has been resized but to not take immediate action. /// Notifies script that window has been resized but to not take immediate action.
ResizeInactive(PipelineId, WindowSizeData), ResizeInactive(PipelineId, WindowSizeData),
/// Notifies the script that a pipeline should be closed. /// Notifies the script that a pipeline should be closed.
ExitPipeline(PipelineId, PipelineExitType), ExitPipeline(PipelineId),
/// Sends a DOM event. /// Sends a DOM event.
SendEvent(PipelineId, CompositorEvent), SendEvent(PipelineId, CompositorEvent),
/// Notifies script of the viewport. /// Notifies script of the viewport.