Explorar o código

Fixed closing window bug of minimized windows #291

vurtun %!s(int64=8) %!d(string=hai) anos
pai
achega
020a562c2e
Modificáronse 1 ficheiros con 2 adicións e 1 borrados
  1. 2 1
      nuklear.h

+ 2 - 1
nuklear.h

@@ -16056,7 +16056,8 @@ nk_clear(struct nk_context *ctx)
     iter = ctx->begin;
     while (iter) {
         /* make sure minimized windows do not get removed */
-        if (iter->flags & NK_WINDOW_MINIMIZED) {
+        if ((iter->flags & NK_WINDOW_MINIMIZED) &&
+            !(iter)->flags & NK_WINDOW_CLOSED) {
             iter = iter->next;
             continue;
         }