mirror of
https://github.com/FellippeHeitor/InForm.git
synced 2025-01-15 03:49:56 +00:00
Properly displays a Wait message while relaunching the preview.
This commit is contained in:
parent
dc870e19bf
commit
7c40916bf9
2 changed files with 17 additions and 4 deletions
|
@ -1395,15 +1395,15 @@ SUB __UI_UpdateDisplay
|
|||
_PRINTMODE _KEEPBACKGROUND
|
||||
NoInputMessage$ = "Please wait..."
|
||||
COLOR _RGB32(0, 0, 0)
|
||||
__UI_PrintString _WIDTH / 2 - __UI_PrintWidth(NoInputMessage$) / 2 + 1, _HEIGHT \ 2 - _FONTWIDTH + 1, NoInputMessage$
|
||||
__UI_PrintString _WIDTH / 2 - __UI_PrintWidth(NoInputMessage$) / 2 + 1, _HEIGHT \ 2 - uspacing + 1, NoInputMessage$
|
||||
COLOR _RGB32(255, 255, 255)
|
||||
__UI_PrintString _WIDTH / 2 - __UI_PrintWidth(NoInputMessage$) / 2, _HEIGHT \ 2 - _FONTWIDTH, NoInputMessage$
|
||||
__UI_PrintString _WIDTH / 2 - __UI_PrintWidth(NoInputMessage$) / 2, _HEIGHT \ 2 - uspacing, NoInputMessage$
|
||||
IF LEN(__UI_WaitMessage) > 0 THEN
|
||||
IF LEFT$(__UI_WaitMessage, 1) <> "(" THEN __UI_WaitMessage = "(" + __UI_WaitMessage + ")"
|
||||
COLOR _RGB32(0, 0, 0)
|
||||
__UI_PrintString _WIDTH / 2 - __UI_PrintWidth(NoInputMessage$) / 2 + 1, _HEIGHT \ 2 + 4, __UI_WaitMessage
|
||||
__UI_PrintString _WIDTH / 2 - __UI_PrintWidth(__UI_WaitMessage) / 2 + 1, _HEIGHT \ 2 + uspacing + 1, __UI_WaitMessage
|
||||
COLOR _RGB32(255, 255, 255)
|
||||
__UI_PrintString _WIDTH / 2 - __UI_PrintWidth(NoInputMessage$) / 2, _HEIGHT \ 2 + 3, __UI_WaitMessage
|
||||
__UI_PrintString _WIDTH / 2 - __UI_PrintWidth(__UI_WaitMessage) / 2, _HEIGHT \ 2 + uspacing, __UI_WaitMessage
|
||||
END IF
|
||||
_DEST PrevDest
|
||||
__UI_MakeHardwareImage __UI_WaitMessageHandle
|
||||
|
|
|
@ -3077,6 +3077,8 @@ SUB CheckPreview
|
|||
CLOSE Client
|
||||
Client = 0
|
||||
|
||||
__UI_UpdateDisplay
|
||||
|
||||
SHELL _DONTWAIT ".\InForm\UiEditorPreview.exe " + HostPort
|
||||
|
||||
DO
|
||||
|
@ -3114,6 +3116,8 @@ SUB CheckPreview
|
|||
CLOSE Client
|
||||
Client = 0
|
||||
|
||||
__UI_UpdateDisplay
|
||||
|
||||
SHELL _DONTWAIT "./InForm/UiEditorPreview " + HostPort
|
||||
|
||||
DO
|
||||
|
@ -3126,6 +3130,15 @@ SUB CheckPreview
|
|||
|
||||
Handshake
|
||||
|
||||
IF LEN(LastFormData$) THEN
|
||||
b$ = "RESTORECRASH>" + LastFormData$ + "<END>"
|
||||
PUT #Client, , b$
|
||||
prevScreenX = -1
|
||||
prevScreenY = -1
|
||||
UndoPointer = 0
|
||||
TotalUndoImages = 0
|
||||
END IF
|
||||
|
||||
TIMER(__UI_EventsTimer) ON
|
||||
ELSE
|
||||
'Preview is active.
|
||||
|
|
Loading…
Reference in a new issue