gtk-rs / gtk3-rs

Rust bindings for GTK 3
https://gtk-rs.org
MIT License
508 stars 90 forks source link

Skip init assertion for gdk::set_allowed_backends #791

Closed nardoor closed 1 year ago

nardoor commented 1 year ago

To my understanding gdk::set_allowed_backends() should be called (when needed) before the init()

https://docs.gtk.org/gdk3/func.set_allowed_backends.html

This call must happen prior to gdk_display_open(), gtk_init(), gtk_init_with_args() or gtk_init_check() in order to take effect.

The way I added the assertion skip might not be the way intended. Please let me know.

bilelmoussaoui commented 1 year ago

Would you mind sending a similar PR for gtk4-rs?

nardoor commented 1 year ago

Would you mind sending a similar PR for gtk4-rs?

Sure, https://github.com/gtk-rs/gtk4-rs/pull/1183