Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

glutin breaks after using azul #57

Open
CryZe opened this issue Nov 14, 2018 · 3 comments
Open

glutin breaks after using azul #57

CryZe opened this issue Nov 14, 2018 · 3 comments

Comments

@CryZe
Copy link

CryZe commented Nov 14, 2018

Description

This is a very strange bug. But the scenario is that I open an azul window, close it and then use glutin to create another window. Even minimal usage of glutin (without even initializing gl) completely breaks.

Version / OS

  • azul version: 8586f0f
  • Operating system: Windows 10 (this likely is specific to Windows)

Steps to Reproduce

app.run(Window::new(window_options, css).unwrap()).unwrap();

let events_loop = glutin::EventsLoop::new();
let window = glutin::WindowBuilder::new().build(&events_loop).unwrap();

Expected Behavior

The second window shows up.

Actual Behavior

The code panics deep within winit.

Additional Information

If you replace glutin with winit it works. So this must be something that glutin does in addition to winit's logic.

@CryZe
Copy link
Author

CryZe commented Nov 14, 2018

It seems to work if I use the same glutin version as azul (0.17.0). Both 0.18.0 and 0.19.0 cause this bug. So that's either because of the version mismatch or because they "broke" something in 0.18.0. Although shouldn't a version mismatch mean that they are fully distinct and thus no global variables or whatever could influence each other? The panic is a lazy_static that is a None when it shouldn't be. So I don't think a version mismatch could cause that.

@fschutt
Copy link
Owner

fschutt commented Nov 15, 2018

This is likely a bug with winit, because winit uses a static global cache for pushing messages around. This is likely not a bug in azul itself.

@fschutt
Copy link
Owner

fschutt commented Dec 3, 2018

@CryZe Rust recognizes two major crate versions as two different things. I have now updated glutin and winit (to 0.19 and 0.18 respectively), maybe try again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants