Skip to content

Commit

Permalink
Update to use CGL crate for mac.
Browse files Browse the repository at this point in the history
  • Loading branch information
gw3583 committed Oct 29, 2014
1 parent f632f64 commit 2efcbd8
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 5 deletions.
8 changes: 8 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 9 additions & 0 deletions ports/android/glut_app/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 9 additions & 1 deletion ports/cef/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions ports/glfw/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,5 +29,5 @@ path = "../../components/msg"
[dependencies.util]
path = "../../components/util"

[dependencies.opengles]
git = "https://github.com/servo/rust-opengles"
[dependencies.cgl]
git = "https://github.com/servo/rust-cgl"
3 changes: 2 additions & 1 deletion ports/glfw/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
#![deny(unused_imports, unused_variable)]

extern crate alert;
#[cfg(target_os="macos")]
extern crate cgl;
extern crate compositing;
extern crate geom;
extern crate glfw;
Expand All @@ -17,7 +19,6 @@ extern crate libc;
extern crate msg;
extern crate time;
extern crate util;
extern crate opengles;

use geom::scale_factor::ScaleFactor;
use std::rc::Rc;
Expand Down
2 changes: 1 addition & 1 deletion ports/glfw/window.rs
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ impl WindowMethods for Window {

#[cfg(target_os="macos")]
fn native_metadata(&self) -> NativeGraphicsMetadata {
use opengles::cgl::{CGLGetCurrentContext, CGLGetPixelFormat};
use cgl::{CGLGetCurrentContext, CGLGetPixelFormat};
unsafe {
NativeGraphicsMetadata {
pixel_format: CGLGetPixelFormat(CGLGetCurrentContext()),
Expand Down

0 comments on commit 2efcbd8

Please sign in to comment.