diff options
| author | tomaka <pierre.krieger1708@gmail.com> | 2015-01-08 13:44:26 +0100 | 
|---|---|---|
| committer | tomaka <pierre.krieger1708@gmail.com> | 2015-01-08 13:44:26 +0100 | 
| commit | 181e4a1d8f12136c73add790003f3372319f82f6 (patch) | |
| tree | 376f5ff328731fb4678c943ae70caa040e642ba3 /examples | |
| parent | 25b261975c6756a3e0f9ee36107f185103b35292 (diff) | |
| parent | 3920cd5e80e2ba9bae83dc2934b05453b848cc7d (diff) | |
| download | glutin-181e4a1d8f12136c73add790003f3372319f82f6.tar.gz glutin-181e4a1d8f12136c73add790003f3372319f82f6.zip | |
Merge pull request #187 from tomaka/update-rustc
Update for Rustc
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/fullscreen.rs | 4 | ||||
| -rw-r--r-- | examples/multiwindow.rs | 4 | ||||
| -rw-r--r-- | examples/support/mod.rs | 11 | ||||
| -rw-r--r-- | examples/window.rs | 4 | 
4 files changed, 7 insertions, 16 deletions
| diff --git a/examples/fullscreen.rs b/examples/fullscreen.rs index 6a2af2c..c77569f 100644 --- a/examples/fullscreen.rs +++ b/examples/fullscreen.rs @@ -1,7 +1,5 @@ -#![feature(phase)] -  #[cfg(target_os = "android")] -#[phase(plugin, link)] +#[macro_use]  extern crate android_glue;  extern crate glutin; diff --git a/examples/multiwindow.rs b/examples/multiwindow.rs index 1f390cd..fc01ef0 100644 --- a/examples/multiwindow.rs +++ b/examples/multiwindow.rs @@ -1,7 +1,5 @@ -#![feature(phase)] -  #[cfg(target_os = "android")] -#[phase(plugin, link)] +#[macro_use]  extern crate android_glue;  extern crate glutin; diff --git a/examples/support/mod.rs b/examples/support/mod.rs index 42ce6a4..7144952 100644 --- a/examples/support/mod.rs +++ b/examples/support/mod.rs @@ -1,8 +1,5 @@  #![cfg(feature = "window")] -#[phase(plugin)] -extern crate gl_generator; -  use glutin;  #[cfg(not(target_os = "android"))] @@ -23,12 +20,12 @@ pub struct Context {  pub fn load(window: &glutin::Window) -> Context {      let gl = gl::Gl::load(window); -    let version = { -        use std::c_str::CString; -        unsafe { CString::new(gl.GetString(gl::VERSION) as *const i8, false) } +    let version = unsafe { +        use std::ffi; +        ffi::c_str_to_bytes(&(gl.GetString(gl::VERSION) as *const i8)).to_string()      }; -    println!("OpenGL version {}", version.as_str().unwrap()); +    println!("OpenGL version {}", version);      Context { gl: gl }  } diff --git a/examples/window.rs b/examples/window.rs index 910d6e6..9cb59c8 100644 --- a/examples/window.rs +++ b/examples/window.rs @@ -1,7 +1,5 @@ -#![feature(phase)] -  #[cfg(target_os = "android")] -#[phase(plugin, link)] +#[macro_use]  extern crate android_glue;  extern crate glutin; | 
