示例#1
0
 /**
  *  detects mobile platform and attaches all needed javascript files
  */
 protected function _Init()
 {
     if (self::$isAlreadyInit) {
         return;
     }
     $GLOBALS["BITRIX_PLATFORM"] = self::$platform;
     $GLOBALS["BITRIX_API_VERSION"] = self::$apiVersion;
     AddEventHandler("main", "OnBeforeEndBufferContent", array("CMobile", "initScripts"));
     self::$isAlreadyInit = true;
 }
示例#2
0
 /**
  *  detects mobile platform and attaches all needed javascript files
  */
 protected function _Init()
 {
     if (self::$isAlreadyInit) {
         return;
     }
     $GLOBALS["BITRIX_PLATFORM"] = self::$platform;
     $GLOBALS["BITRIX_API_VERSION"] = self::$apiVersion;
     AddEventHandler("main", "OnBeforeEndBufferContent", array("CMobile", "initScripts"));
     self::$isAlreadyInit = true;
     $db_events = GetModuleEvents("mobileapp", "OnMobileInit");
     while ($arEvent = $db_events->Fetch()) {
         ExecuteModuleEventEx($arEvent);
     }
 }