diff --git a/src/components/main/compositing/compositor.rs b/src/components/main/compositing/compositor.rs index 27cdb40e39c..e328a5201f9 100644 --- a/src/components/main/compositing/compositor.rs +++ b/src/components/main/compositing/compositor.rs @@ -117,7 +117,7 @@ impl IOCompositor { port: Receiver, constellation_chan: ConstellationChan, profiler_chan: ProfilerChan) -> IOCompositor { - let window: Rc = WindowMethods::new(app); + let window: Rc = WindowMethods::new(app, opts.output_file.is_none()); // Create an initial layer tree. // diff --git a/src/components/main/platform/common/glfw_windowing.rs b/src/components/main/platform/common/glfw_windowing.rs index d200e5c9443..e5571ad757a 100644 --- a/src/components/main/platform/common/glfw_windowing.rs +++ b/src/components/main/platform/common/glfw_windowing.rs @@ -103,8 +103,9 @@ pub struct Window { impl WindowMethods for Window { /// Creates a new window. - fn new(app: &Application) -> Rc { + fn new(app: &Application, is_foreground: bool) -> Rc { // Create the GLFW window. + app.glfw.window_hint(glfw::Visible(is_foreground)); let (glfw_window, events) = app.glfw.create_window(800, 600, "Servo", glfw::Windowed) .expect("Failed to create GLFW window"); glfw_window.make_current(); diff --git a/src/components/main/platform/common/glut_windowing.rs b/src/components/main/platform/common/glut_windowing.rs index 09894d249d9..359eeb4bbc3 100644 --- a/src/components/main/platform/common/glut_windowing.rs +++ b/src/components/main/platform/common/glut_windowing.rs @@ -61,7 +61,7 @@ pub struct Window { impl WindowMethods for Window { /// Creates a new window. - fn new(_: &Application) -> Rc { + fn new(_: &Application, _: bool) -> Rc { // Create the GLUT window. glut::init_window_size(800, 600); let glut_window = glut::create_window("Servo".to_owned()); diff --git a/src/components/main/windowing.rs b/src/components/main/windowing.rs index b376eb90d24..1a66a90181a 100644 --- a/src/components/main/windowing.rs +++ b/src/components/main/windowing.rs @@ -56,7 +56,7 @@ pub trait ApplicationMethods { pub trait WindowMethods { /// Creates a new window. - fn new(app: &A) -> Rc; + fn new(app: &A, is_foreground: bool) -> Rc; /// Returns the size of the window. fn size(&self) -> Size2D; /// Presents the window to the screen (perhaps by page flipping). diff --git a/src/support/glfw/glfw b/src/support/glfw/glfw index c2bf133193a..bf90cb8b336 160000 --- a/src/support/glfw/glfw +++ b/src/support/glfw/glfw @@ -1 +1 @@ -Subproject commit c2bf133193a10d02334a413d40091a15ebca6cc1 +Subproject commit bf90cb8b336b2cfb49572dd964c5d2c23297502e