aboutsummaryrefslogtreecommitdiffstats
path: root/src/window.rs
diff options
context:
space:
mode:
authorPierre Krieger <pierre.krieger1708@gmail.com>2015-06-22 17:58:32 +0200
committerPierre Krieger <pierre.krieger1708@gmail.com>2015-06-22 19:42:03 +0200
commitdbaca24cde140052fb08fbe00924da4a528ea7cf (patch)
treebc86121c21cbe715826f67a749f3e5a1abb50c5a /src/window.rs
parent1aedc828c55e94d6f301a100f958ffa1106a0a25 (diff)
downloadglutin-dbaca24cde140052fb08fbe00924da4a528ea7cf.tar.gz
glutin-dbaca24cde140052fb08fbe00924da4a528ea7cf.zip
Add with_robustness and handle robustness on all implementations
Diffstat (limited to 'src/window.rs')
-rw-r--r--src/window.rs7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/window.rs b/src/window.rs
index 485ba58..9685287 100644
--- a/src/window.rs
+++ b/src/window.rs
@@ -12,6 +12,7 @@ use GlProfile;
use GlRequest;
use MouseCursor;
use PixelFormat;
+use Robustness;
use native_monitor::NativeMonitorId;
use gl_common;
@@ -84,6 +85,12 @@ impl<'a> WindowBuilder<'a> {
self
}
+ /// Sets the robustness of the OpenGL context. See the docs of `Robustness`.
+ pub fn with_gl_robustness(mut self, robustness: Robustness) -> WindowBuilder<'a> {
+ self.attribs.gl_robustness = robustness;
+ self
+ }
+
/// Requests that the window has vsync enabled.
pub fn with_vsync(mut self) -> WindowBuilder<'a> {
self.attribs.vsync = true;