Skip to content

Commit

Permalink
imgui-sys: Fix binding to igIsWindowFocused
Browse files Browse the repository at this point in the history
This commit adds the `ImGuiFocusedFlags' input flag that was missing.
  • Loading branch information
malikolivier committed Apr 29, 2018
1 parent a5ed022 commit 24c3729
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion imgui-sys/src/lib.rs
Expand Up @@ -314,6 +314,17 @@ bitflags!(
}
);

bitflags!(
/// Flags for window focus check
#[repr(C)]
pub struct ImGuiFocusedFlags: c_int {
const ChildWindows = 1 << 0;
const RootWindow = 1 << 1;
const RootAndChildWindows =
ImGuiFocusedFlags::RootWindow.bits | ImGuiFocusedFlags::ChildWindows.bits;
}
);

bitflags!(
/// Flags for hover checks
#[repr(C)]
Expand Down Expand Up @@ -1606,7 +1617,7 @@ extern "C" {
pub fn igGetItemRectMax(out: *mut ImVec2);
pub fn igGetItemRectSize(out: *mut ImVec2);
pub fn igSetItemAllowOverlap();
pub fn igIsWindowFocused() -> bool;
pub fn igIsWindowFocused(flags: ImGuiFocusedFlags) -> bool;
pub fn igIsWindowHovered(flags: ImGuiHoveredFlags) -> bool;
pub fn igIsRootWindowFocused() -> bool;
pub fn igIsRootWindowOrAnyChildFocused() -> bool;
Expand Down

0 comments on commit 24c3729

Please sign in to comment.