/** * Returns class instance * * @return UHEADER_CLASS_NewsfeedBridge */ public static function getInstance() { if (!isset(self::$classInstance)) { self::$classInstance = new self(); } return self::$classInstance; }
public function onCollectActions(BASE_CLASS_EventCollector $e) { $e->add(array('section' => $this->plugin->getKey(), 'action' => self::ACTION_COMMENT, 'sectionIcon' => 'ow_ic_picture', 'sectionLabel' => OW::getLanguage()->text($this->plugin->getKey(), 'notifications_section_label'), 'description' => OW::getLanguage()->text($this->plugin->getKey(), 'notifications_setting_comment'), 'selected' => true)); if (UHEADER_CLASS_NewsfeedBridge::getInstance()->isActive()) { $e->add(array('section' => $this->plugin->getKey(), 'action' => self::ACTION_LIKE, 'sectionIcon' => 'ow_ic_picture', 'sectionLabel' => OW::getLanguage()->text($this->plugin->getKey(), 'notifications_section_label'), 'description' => OW::getLanguage()->text($this->plugin->getKey(), 'notifications_setting_like'), 'selected' => true)); } }
<?php /** * Copyright (c) 2012, Sergey Kambalin * All rights reserved. * ATTENTION: This commercial software is intended for use with Oxwall Free Community Software http://www.oxwall.org/ * and is licensed under Oxwall Store Commercial License. * Full text of this license can be found at http://www.oxwall.org/store/oscl */ $plugin = OW::getPluginManager()->getPlugin('uheader'); //Routs $router = OW::getRouter(); $router->addRoute(new OW_Route('uheader-settings-page', 'admin/plugins/profile-cover', 'UHEADER_CTRL_Admin', 'index')); $router->addRoute(new OW_Route('uheader-settings-gallery', 'admin/plugins/profile-cover/gallery', 'UHEADER_CTRL_Templates', 'index')); $router->addRoute(new OW_Route('uheader-settings-gallery-item', 'admin/plugins/profile-cover/gallery/:tplId', 'UHEADER_CTRL_Templates', 'index')); // Bridges UHEADER_CLASS_PhotoBridge::getInstance()->init(); UHEADER_CLASS_NewsfeedBridge::getInstance()->init(); UHEADER_CLASS_PrivacyBridge::getInstance()->init(); UHEADER_CLASS_NotificationsBridge::getInstance()->init(); UHEADER_CLASS_CommentsBridge::getInstance()->init(); UHEADER_CLASS_CreditsBridge::getInstance()->init(); UHEADER_CLASS_UavatarsBridge::getInstance()->init(); UHEADER_CLASS_BaseBridge::getInstance()->init(); //Event handler UHEADER_CLASS_EventHandler::getInstance()->init();