From 9c16df4339a4908e11b8af900f7d2d8efa645d01 Mon Sep 17 00:00:00 2001 From: FellippeHeitor Date: Mon, 25 Jun 2018 22:36:50 -0300 Subject: [PATCH] Prevents __UI_DestroyControl from destroying the __UI_Type_Form control. --- InForm/InForm.ui | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/InForm/InForm.ui b/InForm/InForm.ui index 612c81f..4c75d98 100644 --- a/InForm/InForm.ui +++ b/InForm/InForm.ui @@ -4348,6 +4348,7 @@ SUB __UI_DestroyControl (This AS __UI_ControlTYPE) __UI_AutoRefresh = False IF This.ID > 0 THEN + IF This.Type = __UI_Type_Form THEN EXIT SUB Caption(This.ID) = "" __UI_TempCaptions(This.ID) = "" Text(This.ID) = "" @@ -4386,7 +4387,7 @@ SUB __UI_DestroyControl (This AS __UI_ControlTYPE) END IF END IF - DIM noti AS __ui_ControlTYPE + DIM EmptyControl AS __UI_ControlTYPE IF This.Canvas <> 0 THEN _FREEIMAGE This.Canvas: This.Canvas = 0 IF This.HelperCanvas <> 0 THEN _FREEIMAGE This.HelperCanvas: This.HelperCanvas = 0 @@ -4394,7 +4395,7 @@ SUB __UI_DestroyControl (This AS __UI_ControlTYPE) uw& = GetControlDrawOrder(This.ID) ControlDrawOrder(uw&) = 0 - This = noti + This = EmptyControl __UI_HasMenuBar = (__UI_FirstMenuBarControl > 0)