I am having a RapaGUI window with a progressbar, which I am trying to fill up while CopyFile is copying files. I do this on Linux with Gnome 3.
I use the Callback for CopyFile, but it seems that while the CopyFile is working, although I get the right information in DebugMessages (copied and filesize), it seems that RapaGUI is freezed. I even get a Linux window that asks me to terminate the application, as it seems frozen.
Here is the callback I am using
Code: Select all
Function p_CopyCallback(msg)
Switch msg.action
Case #COPYFILE_STATUS:
Local percent = Ceil(msg.copied / msg.filesize * 100)
moai.Set("prgbarCopy", "Level", percent)
DebugPrint("Now copying", FilePart(msg.source), "to", PathPart(msg.destination), ": ", msg.Copied, " of ", msg.Filesize)
EndSwitch
Return(False)
EndFunction
Code: Select all
CopyFile(FullPath(srcPath$, fname$), destPath$, {Callback = p_CopyCallback})Does anyone know if I need to do something else to have it working properly, showing the progressbar moving while the file is copied?