mirror of
https://github.com/eliasstepanik/imgui-rs.git
synced 2026-01-11 05:28:35 +00:00
Merge pull request #529 from sanbox-irl/feature-gate-tables-api
decided to feature gate the tables API
This commit is contained in:
commit
5f441b7b1d
@ -13,6 +13,6 @@ publish = false
|
||||
clipboard = "0.5"
|
||||
glium = { version = "0.30", default-features = true }
|
||||
image = "0.23"
|
||||
imgui = { path = "../imgui" }
|
||||
imgui = { path = "../imgui", features = ["tables-api"] }
|
||||
imgui-glium-renderer = { path = "../imgui-glium-renderer" }
|
||||
imgui-winit-support = { path = "../imgui-winit-support" }
|
||||
|
||||
@ -23,6 +23,9 @@ default = ["min-const-generics"]
|
||||
wasm = ["imgui-sys/wasm"]
|
||||
freetype = ["imgui-sys/freetype"]
|
||||
min-const-generics = []
|
||||
# this api is in beta in the upstream imgui crate. See issue #524 for more info.
|
||||
# it should be stable and fine to use though.
|
||||
tables-api = []
|
||||
|
||||
[dev-dependencies]
|
||||
memoffset = "0.6"
|
||||
|
||||
@ -34,6 +34,8 @@ pub use self::render::renderer::*;
|
||||
pub use self::stacks::*;
|
||||
pub use self::string::*;
|
||||
pub use self::style::*;
|
||||
|
||||
#[cfg(feature = "tables-api")]
|
||||
pub use self::tables::*;
|
||||
pub use self::utils::*;
|
||||
pub use self::widget::color_editors::*;
|
||||
@ -77,6 +79,7 @@ mod popups;
|
||||
mod render;
|
||||
mod stacks;
|
||||
mod style;
|
||||
#[cfg(feature = "tables-api")]
|
||||
mod tables;
|
||||
#[cfg(test)]
|
||||
mod test;
|
||||
@ -289,6 +292,9 @@ impl<T> From<*mut T> for Id<'static> {
|
||||
}
|
||||
|
||||
impl<'a> Id<'a> {
|
||||
// this is used in the tables-api and possibly elsewhere,
|
||||
// but not with just default features...
|
||||
#[allow(dead_code)]
|
||||
fn as_imgui_id(&self) -> sys::ImGuiID {
|
||||
unsafe {
|
||||
match self {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user