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

Add HasRawWindowHandle for WindowHandle in druid (rebased against master) #1878

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions druid-shell/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ pub use image;
pub use kurbo;
pub use piet_common as piet;

// Reexport the version of `raw_window_handle` we are using.
#[cfg(feature = "raw-win-handle")]
pub use raw_window_handle;

#[macro_use]
mod util;

Expand Down
3 changes: 3 additions & 0 deletions druid/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ x11 = ["druid-shell/x11"]
crochet = []
serde = ["im/serde", "druid-shell/serde"]

# Implement HasRawWindowHandle for WindowHandle
raw-win-handle = ["druid-shell/raw-win-handle"]

# passing on all the image features. AVIF is not supported because it does not
# support decoding, and that's all we use `Image` for.
png = ["druid-shell/image_png"]
Expand Down
3 changes: 3 additions & 0 deletions druid/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,9 @@ pub use shell::{
WindowHandle, WindowLevel, WindowState,
};

#[cfg(feature = "raw-win-handle")]
pub use crate::shell::raw_window_handle::{HasRawWindowHandle, RawWindowHandle};

pub use crate::core::WidgetPod;
pub use app::{AppLauncher, WindowConfig, WindowDesc, WindowSizePolicy};
pub use app_delegate::{AppDelegate, DelegateCtx};
Expand Down