コード例 #1
0
 public static function getInstance()
 {
     if (!isset(self::$classInstance)) {
         self::$classInstance = new self();
     }
     return self::$classInstance;
 }
コード例 #2
0
ファイル: event_handler.php プロジェクト: hardikamutech/hammu
 public function init()
 {
     if (!OW::getPluginManager()->isPluginActive('mailbox')) {
         return;
     }
     $eventManager = OW::getEventManager();
     $eventManager->bind(BASE_CMP_ProfileActionToolbar::EVENT_NAME, array($this, 'addProfileActionToolbar'));
     $eventManager->bind(OW_EventManager::ON_FINALIZE, array($this, 'onFinalize'));
     $eventManager->bind('wink.renderWink', array($this, 'onRenderWink'));
     $eventManager->bind('wink.renderWinkBack', array($this, 'onRenderWinkBack'));
     $eventManager->bind(OW_EventManager::ON_USER_UNREGISTER, array($this, 'baseUserUnregister'));
     $eventManager->bind(OW_EventManager::ON_USER_SUSPEND, array($this, 'baseUserSuspend'));
     $eventManager->bind('winks.isWinkSent', array($this, 'getIsWinkSent'));
     $eventManager->bind('notifications.collect_actions', array($this, 'onNotifyActions'));
     WINKS_CLASS_ConsoleEventHandler::getInstance()->init();
 }