popfile and poppath make output window slow to disappear

Discuss GUI programming with the RapaGUI plugin here
Post Reply
djg
Posts: 27
Joined: Wed Feb 12, 2020 10:37 pm

popfile and poppath make output window slow to disappear

Post by djg »

On Linux, when I create an object that has a popfile or poppath widget in it and then close the window of the app, the output window of the interpreter only closes after a second or so instead of immediately. The delay does not happen with a popcolor or popfont widget. Not a big deal, but slightly annoying and maybe it causes other problems that I don't know of.

Code: Select all

@REQUIRE "RapaGUI"

moai.CreateApp([[
<?xml version="1.0" encoding="iso-8859-1"?>
<application id="app">
<window id="appWindow" notify="closerequest">
	<vgroup>
		<hgroup>
			<button id="button">Button</button>
		</hgroup>
		<rectangle/>
	</vgroup>
</window>
	 
</application>
]])

moai.CreateObject([[
	<window>
		<vgroup>
			<popfile/>
		</vgroup>
	</window>
	]])

Function p_EventFunc(msg)
		Switch msg.attribute
			Case "CloseRequest":
				moai.Set("appWindow","Open",False)
				End
		EndSwitch
EndFunction

InstallEventHandler({RapaGUI = p_EventFunc})
Repeat
	WaitEvent
Forever

End
Post Reply