diff options
author | tomaka <pierre.krieger1708@gmail.com> | 2014-11-24 20:51:59 +0100 |
---|---|---|
committer | tomaka <pierre.krieger1708@gmail.com> | 2014-11-24 20:51:59 +0100 |
commit | d7a7765638d4638c48e4b76477b32da6be7957b3 (patch) | |
tree | 49cbbce62bec8a6203ab731df87001b32cd7c81d /src/win32/mod.rs | |
parent | 9668878f266dc23f8be353d804f7c99fb96767ac (diff) | |
parent | 4c0413bc7cbf83066014ca2334827fd8ccfbcfa7 (diff) | |
download | glutin-d7a7765638d4638c48e4b76477b32da6be7957b3.tar.gz glutin-d7a7765638d4638c48e4b76477b32da6be7957b3.zip |
Merge pull request #134 from tomaka/share-lists
Implement lists sharing
Diffstat (limited to 'src/win32/mod.rs')
-rw-r--r-- | src/win32/mod.rs | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/win32/mod.rs b/src/win32/mod.rs index 4dad1eb..ef2e3ea 100644 --- a/src/win32/mod.rs +++ b/src/win32/mod.rs @@ -25,8 +25,9 @@ impl HeadlessContext { /// See the docs in the crate root file. pub fn new(builder: HeadlessRendererBuilder) -> Result<HeadlessContext, CreationError> { let HeadlessRendererBuilder { dimensions, gl_version, gl_debug } = builder; - init::new_window(Some(dimensions), "".to_string(), None, gl_version, gl_debug, false, true) - .map(|w| HeadlessContext(w)) + init::new_window(Some(dimensions), "".to_string(), None, gl_version, gl_debug, false, true, + None) + .map(|w| HeadlessContext(w)) } /// See the docs in the crate root file. @@ -69,8 +70,9 @@ impl Window { /// See the docs in the crate root file. pub fn new(builder: WindowBuilder) -> Result<Window, CreationError> { let WindowBuilder { dimensions, title, monitor, gl_version, - gl_debug, vsync, visible } = builder; - init::new_window(dimensions, title, monitor, gl_version, gl_debug, vsync, !visible) + gl_debug, vsync, visible, sharing } = builder; + init::new_window(dimensions, title, monitor, gl_version, gl_debug, vsync, + !visible, sharing.map(|w| w.window.context)) } } |