}
}
-function launch( str, args, dir ) {
+async function launch( str, args, dir ) {
+ while(System.launchLock) await System.ajaxWait();
+ System.launchLock = true;
+
let _pid = pid;
System.args[_pid] = args;
- System.launchpath[_pid] = dir || System.appdir + str;
+ let _path = dir || System.appdir + str;
+ System.launchpath[_pid] = _path;
- if( System.appCache[str] ) {
+ if( System.appCache[_path] ) {
if( KWS.fullscreen.pid ) KWS.unmax(KWS.fullscreen.pid);
- appData( System.appCache[str] );
+ appData( System.appCache[_path] );
}
else {
try{