diff options
author | enricoturri1966 <enricoturri@seznam.cz> | 2022-07-19 13:57:26 +0300 |
---|---|---|
committer | supermerill <merill@free.fr> | 2022-08-11 00:44:59 +0300 |
commit | 206d8e72536bacd85f36864eca5db4f739328404 (patch) | |
tree | 0f886427bd93fa987ebb0e45fd321e09c3696674 | |
parent | 0b787183b9c0921e3a65881b90fac44cc96350d8 (diff) |
Fixed GLGizmoBase::render_input_window() to properly require for an extra frame the first time an imgui window is shown
-rw-r--r-- | src/slic3r/GUI/Gizmos/GLGizmoBase.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/slic3r/GUI/Gizmos/GLGizmoBase.cpp b/src/slic3r/GUI/Gizmos/GLGizmoBase.cpp index 393be1a4e..30f303dee 100644 --- a/src/slic3r/GUI/Gizmos/GLGizmoBase.cpp +++ b/src/slic3r/GUI/Gizmos/GLGizmoBase.cpp @@ -225,9 +225,12 @@ void GLGizmoBase::render_input_window(float x, float y, float bottom_limit) { on_render_input_window(x, y, bottom_limit); if (m_first_input_window_render) { - // for some reason, the imgui dialogs are not shown on screen in the 1st frame where they are rendered, but show up only with the 2nd rendered frame - // so, we forces another frame rendering the first time the imgui window is shown + // imgui windows that don't have an initial size needs to be processed once to get one + // and are not rendered in the first frame + // so, we forces to render another frame the first time the imgui window is shown + // https://github.com/ocornut/imgui/issues/2949 m_parent.set_as_dirty(); + m_parent.request_extra_frame(); m_first_input_window_render = false; } } |