Merge pull request #92 from SSheldon/core_graphics
Add core-graphics dependency
This commit is contained in:
@@ -14,4 +14,5 @@ crate-type = ["rlib"]
|
||||
[dependencies]
|
||||
bitflags = "0.1"
|
||||
libc = "*"
|
||||
core-graphics = "*"
|
||||
objc = "0.1"
|
||||
|
||||
+3
-11
@@ -14,6 +14,9 @@ use foundation::{NSInteger, NSUInteger, NSTimeInterval,
|
||||
NSPoint, NSSize, NSRect, NSRectEdge};
|
||||
use libc;
|
||||
|
||||
pub use core_graphics::base::CGFloat;
|
||||
pub use core_graphics::geometry::CGPoint;
|
||||
|
||||
pub use self::NSApplicationActivationPolicy::*;
|
||||
pub use self::NSWindowMask::*;
|
||||
pub use self::NSBackingStoreType::*;
|
||||
@@ -21,21 +24,10 @@ pub use self::NSOpenGLPixelFormatAttribute::*;
|
||||
pub use self::NSOpenGLPFAOpenGLProfiles::*;
|
||||
pub use self::NSEventType::*;
|
||||
|
||||
#[cfg(target_pointer_width = "32")]
|
||||
pub type CGFloat = f32;
|
||||
#[cfg(target_pointer_width = "64")]
|
||||
pub type CGFloat = f64;
|
||||
|
||||
pub type CGLContextObj = *mut libc::c_void;
|
||||
|
||||
pub type GLint = libc::int32_t;
|
||||
|
||||
#[repr(C)]
|
||||
pub struct CGPoint {
|
||||
pub x: CGFloat,
|
||||
pub y: CGFloat,
|
||||
}
|
||||
|
||||
#[link(name = "AppKit", kind = "framework")]
|
||||
extern {
|
||||
pub static NSAppKitVersionNumber: f64;
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
#[macro_use]
|
||||
extern crate bitflags;
|
||||
extern crate libc;
|
||||
extern crate core_graphics;
|
||||
#[macro_use]
|
||||
extern crate objc;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user