From 7bfa1b6195342c00cab471e3eb9b4a2a84c93943 Mon Sep 17 00:00:00 2001 From: SpaiR Date: Sun, 23 Aug 2020 17:00:23 +0300 Subject: [PATCH] Remove *New versions of methods, since now is possible to change the pointer explicitly --- imgui-binding/src/main/java/imgui/ImGui.java | 49 -------------------- 1 file changed, 49 deletions(-) diff --git a/imgui-binding/src/main/java/imgui/ImGui.java b/imgui-binding/src/main/java/imgui/ImGui.java index 32740cb..3495e45 100644 --- a/imgui-binding/src/main/java/imgui/ImGui.java +++ b/imgui-binding/src/main/java/imgui/ImGui.java @@ -477,24 +477,12 @@ public final class ImGui { /** * Get draw list associated to the current window, to append your own drawing primitives - *

- * BINDING NOTICE: to minimize overhead, method ALWAYS returns the same object, but changes its underlying pointer. - * If you need to get an object with constant pointer (which will point to the same window all the time) use {@link #getWindowDrawListNew()}. */ public static ImDrawList getWindowDrawList() { WINDOW_DRAW_LIST.ptr = nGetWindowDrawList(); return WINDOW_DRAW_LIST; } - /** - * Get draw list associated to the current window, to append your own drawing primitives - *

- * BINDING NOTICE: returns {@link ImDrawList} for current window with constant pointer to it. Prefer to use {@link #getWindowDrawList()}. - */ - public static ImDrawList getWindowDrawListNew() { - return new ImDrawList(nGetWindowDrawList()); - } - private static native long nGetWindowDrawList(); /* return (intptr_t)ImGui::GetWindowDrawList(); */ @@ -4907,25 +4895,12 @@ public final class ImGui { /** * Get background draw list for the viewport associated to the current window. * This draw list will be the first rendering one. Useful to quickly draw shapes/text behind dear imgui contents. - *

- * BINDING NOTICE: to minimize overhead, method ALWAYS returns the same object, but changes its underlying pointer. - * If you need to get an object with constant pointer (which will point to the same background all the time) use {@link #getBackgroundDrawListNew()}. */ public static ImDrawList getBackgroundDrawList() { BACKGROUND_DRAW_LIST.ptr = nGetBackgroundDrawList(); return BACKGROUND_DRAW_LIST; } - /** - * Get background draw list for the viewport associated to the current window. - * This draw list will be the first rendering one. Useful to quickly draw shapes/text behind dear imgui contents. - *

- * BINDING NOTICE: returns {@link ImDrawList} for current background with constant pointer to it. Prefer to use {@link #getBackgroundDrawList()}. - */ - public static ImDrawList getBackgroundDrawListNew() { - return new ImDrawList(nGetBackgroundDrawList()); - } - private static native long nGetBackgroundDrawList(); /* return (intptr_t)ImGui::GetBackgroundDrawList(); */ @@ -4933,25 +4908,12 @@ public final class ImGui { /** * Get foreground draw list for the viewport associated to the current window. * This draw list will be the first rendering one. Useful to quickly draw shapes/text behind dear imgui contents. - *

- * BINDING NOTICE: to minimize overhead, method ALWAYS returns the same object, but changes its underlying pointer. - * If you need to get an object with constant pointer (which will point to the same foreground all the time) use {@link #getForegroundDrawListNew()}. */ public static ImDrawList getForegroundDrawList() { FOREGROUND_DRAW_LIST.ptr = nGetForegroundDrawList(); return FOREGROUND_DRAW_LIST; } - /** - * Get foreground draw list for the viewport associated to the current window. - * This draw list will be the first rendering one. Useful to quickly draw shapes/text behind dear imgui contents. - *

- * BINDING NOTICE: returns {@link ImDrawList} for current foreground with constant pointer to it. Prefer to use {@link #getForegroundDrawList()}. - */ - public static ImDrawList getForegroundDrawListNew() { - return new ImDrawList(nGetForegroundDrawList()); - } - private static native long nGetForegroundDrawList(); /* return (intptr_t)ImGui::GetForegroundDrawList(); */ @@ -4976,22 +4938,11 @@ public final class ImGui { ImGui::SetStateStorage((ImGuiStorage*)imGuiStoragePtr); */ - /** - * BINDING NOTICE: to minimize overhead, method ALWAYS returns the same object, but changes its underlying pointer. - * If you need to get an object with constant pointer (which will point to the same window all the time) use {@link #getStateStorageNew()}. - */ public static ImGuiStorage getStateStorage() { IMGUI_STORAGE.ptr = nGetStateStorage(); return IMGUI_STORAGE; } - /** - * BINDING NOTICE: returns {@link ImGuiStorage} for current window with constant pointer to it. Prefer to use {@link #getStateStorage()}. - */ - public static ImGuiStorage getStateStorageNew() { - return new ImGuiStorage(nGetStateStorage()); - } - private static native long nGetStateStorage(); /* return (intptr_t)ImGui::GetStateStorage(); */