Blind attempt to fix the OS/X build

This commit is contained in:
Pierre Krieger 2015-01-15 20:20:52 +01:00
parent 22a27767d5
commit 7652cc5860
3 changed files with 25 additions and 25 deletions

View file

@ -12,7 +12,7 @@ pub fn get_available_monitors() -> RingBuf<MonitorID> {
display::CGGetActiveDisplayList(max_displays,
&mut active_displays[0],
&mut display_count);
for i in range(0u, display_count as uint) {
for i in range(0us, display_count as usize) {
monitors.push_back(MonitorID(active_displays[i]));
}
}
@ -35,12 +35,12 @@ impl MonitorID {
Some(format!("Monitor #{}", screen_num))
}
pub fn get_dimensions(&self) -> (uint, uint) {
pub fn get_dimensions(&self) -> (u32, u32) {
let MonitorID(display_id) = *self;
let dimension = unsafe {
let height = display::CGDisplayPixelsHigh(display_id);
let width = display::CGDisplayPixelsWide(display_id);
(width as uint, height as uint)
(width as u32, height as u32)
};
dimension
}