public static function __run(AppExecutionContext $context, MMapResponse $response) { // Kill "login" process if any $PM = ProcManager::getInstance(); $procList = $PM->getProcessesTable(); foreach ($procList as $proc) { switch ($proc->getName()) { case 'init': break; case 'session': break; default: try { $PM->kill($proc); } catch (Exception $e) { Logger::getLogger('eyeosmobile.session')->warn('Cannot kill login process ' . $proc . ': ' . $e->getMessage()); } break; } } $args = $context->getArgs(); // User information (cached in eyeos.js) $args[0] = EyeosApplicationExecutable::__callModule('UserInfo', 'getCurrentUserInfo', array()); // Initial application(s) to launch (= static list $initApps excluding already running processes) // $procList = ProcManager::getInstance()->getProcessesList(); //$args[1] = array_diff(self::$initApps, $procList); // $args[1] = array_values(array_diff(self::$initApps, $procList)); //For the moment we just restore init application $args[1] = self::$initApps; }
public static function __run(AppExecutionContext $context, MMapResponse $response) { $currentUser = $context->getProcess()->getLoginContext()->getEyeosUser(); $files = EyeosApplicationExecutable::__callModule('FileSystem', 'browsePath', array('home:///Desktop/', null, null)); $context->getArgs()->offsetSet(0, $currentUser->getName()); $context->getArgs()->offsetSet(1, $files); if ($context->getIncludeBody()) { $buffer = ''; $itemsPath = EYE_ROOT . '/' . APPS_DIR . '/desktop/'; $buffer .= file_get_contents($itemsPath . '/desktop.WidgetManager.js'); $buffer .= file_get_contents($itemsPath . '/desktop.SelectionManager.js'); $buffer .= file_get_contents($itemsPath . '/desktop.actionManager.js'); $buffer .= file_get_contents($itemsPath . '/desktop.chatManager.js'); $buffer .= file_get_contents($itemsPath . '/widgets/desktop.widget.events.js'); $buffer .= file_get_contents($itemsPath . '/widgets/desktop.widget.favorites.js'); $buffer .= file_get_contents($itemsPath . '/widgets/desktop.widget.files.js'); $buffer .= file_get_contents($itemsPath . '/widgets/desktop.widget.groups.js'); $buffer .= file_get_contents($itemsPath . '/widgets/desktop.widget.notes.js'); $buffer .= file_get_contents($itemsPath . '/widgets/desktop.widget.desktop.js'); $response->appendToBody($buffer); } }
public static function close($params) { EyeosApplicationExecutable::close($params); }
public static function close($params) { setcookie('roundcube_sessid', 'invalid', 0, '/'); EyeosApplicationExecutable::close($params); }