Rename ImBool to ImBoolean
This commit is contained in:
1 parent
ebd1e69f89
commit
2de7a25e99
3 files changed
+29
-29
No files matched your search
@@ -1,7 +1,7 @@
|
|||||||
package imgui;
|
package imgui;
|
||||||
|
|
||||||
import imgui.flag.ImGuiInputTextFlags;
|
import imgui.flag.ImGuiInputTextFlags;
|
||||||
import imgui.type.ImBool;
|
import imgui.type.ImBoolean;
|
||||||
import imgui.type.ImDouble;
|
import imgui.type.ImDouble;
|
||||||
import imgui.type.ImFloat;
|
import imgui.type.ImFloat;
|
||||||
import imgui.type.ImInt;
|
import imgui.type.ImInt;
|
||||||
@@ -220,7 +220,7 @@ public final class ImGui {
|
|||||||
ImGui::ShowDemoWindow();
|
ImGui::ShowDemoWindow();
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public static void showDemoWindow(ImBool pOpen) {
|
public static void showDemoWindow(ImBoolean pOpen) {
|
||||||
nShowDemoWindow(pOpen.getData());
|
nShowDemoWindow(pOpen.getData());
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -235,7 +235,7 @@ public final class ImGui {
|
|||||||
ImGui::ShowAboutWindow();
|
ImGui::ShowAboutWindow();
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public static void showAboutWindow(ImBool pOpen) {
|
public static void showAboutWindow(ImBoolean pOpen) {
|
||||||
nShowAboutWindow(pOpen.getData());
|
nShowAboutWindow(pOpen.getData());
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -255,7 +255,7 @@ public final class ImGui {
|
|||||||
* Create Debug/Metrics window.
|
* Create Debug/Metrics window.
|
||||||
* Display Dear ImGui internals: draw commands (with individual draw calls and vertices), window list, basic internal state, etc.
|
* Display Dear ImGui internals: draw commands (with individual draw calls and vertices), window list, basic internal state, etc.
|
||||||
*/
|
*/
|
||||||
public static void showMetricsWindow(ImBool pOpen) {
|
public static void showMetricsWindow(ImBoolean pOpen) {
|
||||||
nShowMetricsWindow(pOpen.getData());
|
nShowMetricsWindow(pOpen.getData());
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -370,7 +370,7 @@ public final class ImGui {
|
|||||||
return ImGui::Begin(title);
|
return ImGui::Begin(title);
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public static boolean begin(String title, ImBool pOpen) {
|
public static boolean begin(String title, ImBoolean pOpen) {
|
||||||
return nBegin(title, pOpen.getData(), 0);
|
return nBegin(title, pOpen.getData(), 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -378,7 +378,7 @@ public final class ImGui {
|
|||||||
return nBegin(title, imGuiWindowFlags);
|
return nBegin(title, imGuiWindowFlags);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean begin(String title, ImBool pOpen, int imGuiWindowFlags) {
|
public static boolean begin(String title, ImBoolean pOpen, int imGuiWindowFlags) {
|
||||||
return nBegin(title, pOpen.getData(), imGuiWindowFlags);
|
return nBegin(title, pOpen.getData(), imGuiWindowFlags);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1495,7 +1495,7 @@ public final class ImGui {
|
|||||||
return ImGui::Checkbox(label, &flag);
|
return ImGui::Checkbox(label, &flag);
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public static boolean checkbox(String label, ImBool active) {
|
public static boolean checkbox(String label, ImBoolean active) {
|
||||||
return nCheckbox(label, active.getData());
|
return nCheckbox(label, active.getData());
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3451,14 +3451,14 @@ public final class ImGui {
|
|||||||
/**
|
/**
|
||||||
* When 'pOpen' isn't NULL, display an additional small close button on upper right of the header
|
* When 'pOpen' isn't NULL, display an additional small close button on upper right of the header
|
||||||
*/
|
*/
|
||||||
public static boolean collapsingHeader(String label, ImBool pOpen) {
|
public static boolean collapsingHeader(String label, ImBoolean pOpen) {
|
||||||
return nCollapsingHeader(label, pOpen.getData(), 0);
|
return nCollapsingHeader(label, pOpen.getData(), 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* When 'pOpen' isn't NULL, display an additional small close button on upper right of the header
|
* When 'pOpen' isn't NULL, display an additional small close button on upper right of the header
|
||||||
*/
|
*/
|
||||||
public static boolean collapsingHeader(String label, ImBool pOpen, int imGuiTreeNodeFlags) {
|
public static boolean collapsingHeader(String label, ImBoolean pOpen, int imGuiTreeNodeFlags) {
|
||||||
return nCollapsingHeader(label, pOpen.getData(), imGuiTreeNodeFlags);
|
return nCollapsingHeader(label, pOpen.getData(), imGuiTreeNodeFlags);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3500,15 +3500,15 @@ public final class ImGui {
|
|||||||
return ImGui::Selectable(label, selected, imGuiSelectableFlags, ImVec2(sizeX, sizeY));
|
return ImGui::Selectable(label, selected, imGuiSelectableFlags, ImVec2(sizeX, sizeY));
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public static boolean selectable(String label, ImBool selected) {
|
public static boolean selectable(String label, ImBoolean selected) {
|
||||||
return nSelectable(label, selected.getData(), 0, 0, 0);
|
return nSelectable(label, selected.getData(), 0, 0, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean selectable(String label, ImBool selected, int imGuiSelectableFlags) {
|
public static boolean selectable(String label, ImBoolean selected, int imGuiSelectableFlags) {
|
||||||
return nSelectable(label, selected.getData(), imGuiSelectableFlags, 0, 0);
|
return nSelectable(label, selected.getData(), imGuiSelectableFlags, 0, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean selectable(String label, ImBool selected, int imGuiSelectableFlags, float sizeX, float sizeY) {
|
public static boolean selectable(String label, ImBoolean selected, int imGuiSelectableFlags, float sizeX, float sizeY) {
|
||||||
return nSelectable(label, selected.getData(), imGuiSelectableFlags, sizeX, sizeY);
|
return nSelectable(label, selected.getData(), imGuiSelectableFlags, sizeX, sizeY);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3735,14 +3735,14 @@ public final class ImGui {
|
|||||||
/**
|
/**
|
||||||
* Return true when activated + toggle (*pSelected) if pSelected != NULL
|
* Return true when activated + toggle (*pSelected) if pSelected != NULL
|
||||||
*/
|
*/
|
||||||
public static boolean menuItem(String label, String shortcut, ImBool pSelected) {
|
public static boolean menuItem(String label, String shortcut, ImBoolean pSelected) {
|
||||||
return nMenuItem(label, shortcut, pSelected.getData(), true);
|
return nMenuItem(label, shortcut, pSelected.getData(), true);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return true when activated + toggle (*pSelected) if pSelected != NULL
|
* Return true when activated + toggle (*pSelected) if pSelected != NULL
|
||||||
*/
|
*/
|
||||||
public static boolean menuItem(String label, String shortcut, ImBool pSelected, boolean enabled) {
|
public static boolean menuItem(String label, String shortcut, ImBoolean pSelected, boolean enabled) {
|
||||||
return nMenuItem(label, shortcut, pSelected.getData(), enabled);
|
return nMenuItem(label, shortcut, pSelected.getData(), enabled);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3891,7 +3891,7 @@ public final class ImGui {
|
|||||||
/**
|
/**
|
||||||
* Modal dialog (regular window with title bar, block interactions behind the modal window, can't close the modal window by clicking outside)
|
* Modal dialog (regular window with title bar, block interactions behind the modal window, can't close the modal window by clicking outside)
|
||||||
*/
|
*/
|
||||||
public static boolean beginPopupModal(String name, ImBool pOpen) {
|
public static boolean beginPopupModal(String name, ImBoolean pOpen) {
|
||||||
return nBeginPopupModal(name, pOpen.getData(), 0);
|
return nBeginPopupModal(name, pOpen.getData(), 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3905,7 +3905,7 @@ public final class ImGui {
|
|||||||
/**
|
/**
|
||||||
* Modal dialog (regular window with title bar, block interactions behind the modal window, can't close the modal window by clicking outside)
|
* Modal dialog (regular window with title bar, block interactions behind the modal window, can't close the modal window by clicking outside)
|
||||||
*/
|
*/
|
||||||
public static boolean beginPopupModal(String name, ImBool pOpen, int imGuiWindowFlags) {
|
public static boolean beginPopupModal(String name, ImBoolean pOpen, int imGuiWindowFlags) {
|
||||||
return nBeginPopupModal(name, pOpen.getData(), imGuiWindowFlags);
|
return nBeginPopupModal(name, pOpen.getData(), imGuiWindowFlags);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -4078,7 +4078,7 @@ public final class ImGui {
|
|||||||
/**
|
/**
|
||||||
* Create a Tab. Returns true if the Tab is selected.
|
* Create a Tab. Returns true if the Tab is selected.
|
||||||
*/
|
*/
|
||||||
public static boolean beginTabItem(String label, ImBool pOpen) {
|
public static boolean beginTabItem(String label, ImBoolean pOpen) {
|
||||||
return nBeginTabItem(label, pOpen.getData(), 0);
|
return nBeginTabItem(label, pOpen.getData(), 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -4092,7 +4092,7 @@ public final class ImGui {
|
|||||||
/**
|
/**
|
||||||
* Create a Tab. Returns true if the Tab is selected.
|
* Create a Tab. Returns true if the Tab is selected.
|
||||||
*/
|
*/
|
||||||
public static boolean beginTabItem(String label, ImBool pOpen, int imGuiTabBarFlags) {
|
public static boolean beginTabItem(String label, ImBoolean pOpen, int imGuiTabBarFlags) {
|
||||||
return nBeginTabItem(label, pOpen.getData(), imGuiTabBarFlags);
|
return nBeginTabItem(label, pOpen.getData(), imGuiTabBarFlags);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+9
-9
@@ -2,17 +2,17 @@ package imgui.type;
|
|||||||
|
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
|
||||||
public final class ImBool implements Cloneable {
|
public final class ImBoolean implements Cloneable {
|
||||||
private final boolean[] data = new boolean[]{false};
|
private final boolean[] data = new boolean[]{false};
|
||||||
|
|
||||||
public ImBool() {
|
public ImBoolean() {
|
||||||
}
|
}
|
||||||
|
|
||||||
public ImBool(final ImBool imBool) {
|
public ImBoolean(final ImBoolean imBoolean) {
|
||||||
this.data[0] = imBool.data[0];
|
this.data[0] = imBoolean.data[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
public ImBool(final boolean value) {
|
public ImBoolean(final boolean value) {
|
||||||
data[0] = value;
|
data[0] = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -41,8 +41,8 @@ public final class ImBool implements Cloneable {
|
|||||||
if (o == null || getClass() != o.getClass()) {
|
if (o == null || getClass() != o.getClass()) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
final ImBool imBool = (ImBool) o;
|
final ImBoolean imBoolean = (ImBoolean) o;
|
||||||
return data[0] == imBool.data[0];
|
return data[0] == imBoolean.data[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@@ -51,7 +51,7 @@ public final class ImBool implements Cloneable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ImBool clone() {
|
public ImBoolean clone() {
|
||||||
return new ImBool(this);
|
return new ImBoolean(this);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
import imgui.type.ImBool;
|
import imgui.type.ImBoolean;
|
||||||
import imgui.ImColor;
|
import imgui.ImColor;
|
||||||
import imgui.ImGui;
|
import imgui.ImGui;
|
||||||
import imgui.type.ImString;
|
import imgui.type.ImString;
|
||||||
@@ -32,7 +32,7 @@ final class ExampleUi {
|
|||||||
|
|
||||||
// Resizable input example
|
// Resizable input example
|
||||||
private final ImString resizableStr = new ImString(5);
|
private final ImString resizableStr = new ImString(5);
|
||||||
private final ImBool showDemoWindow = new ImBool();
|
private final ImBoolean showDemoWindow = new ImBoolean();
|
||||||
|
|
||||||
// Attach image example
|
// Attach image example
|
||||||
private int dukeTexture;
|
private int dukeTexture;
|
||||||
|
|||||||
Reference in new issue
Block a user