mirror of
https://github.com/italicsjenga/winit-sonoma-fix.git
synced 2024-12-23 22:01:31 +11:00
Merge pull request #40 from DavidPartouche/master
Use the correct monitor when fullscreen for X11
This commit is contained in:
commit
795d04c123
|
@ -35,8 +35,9 @@ impl Window {
|
|||
display
|
||||
};
|
||||
|
||||
let screen_id = unsafe {
|
||||
ffi::XDefaultScreen(display)
|
||||
let screen_id = match builder.monitor {
|
||||
Some(MonitorID(monitor)) => monitor as i32,
|
||||
None => unsafe { ffi::XDefaultScreen(display) },
|
||||
};
|
||||
|
||||
// getting the FBConfig
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
use std::{ptr};
|
||||
use super::ffi;
|
||||
|
||||
pub struct MonitorID(uint);
|
||||
pub struct MonitorID(pub uint);
|
||||
|
||||
pub fn get_available_monitors() -> Vec<MonitorID> {
|
||||
let nb_monitors = unsafe {
|
||||
|
|
Loading…
Reference in a new issue