Minahito
minah****@users*****
2006年 7月 20日 (木) 17:20:42 JST
Index: xoops2jp/html/modules/base/admin/actions/HelpAction.class.php diff -u xoops2jp/html/modules/base/admin/actions/HelpAction.class.php:1.1.2.8 xoops2jp/html/modules/base/admin/actions/HelpAction.class.php:1.1.2.9 --- xoops2jp/html/modules/base/admin/actions/HelpAction.class.php:1.1.2.8 Mon Jun 12 12:55:14 2006 +++ xoops2jp/html/modules/base/admin/actions/HelpAction.class.php Thu Jul 20 17:20:42 2006 @@ -1,6 +1,6 @@ <?php /** - * @version $Id: HelpAction.class.php,v 1.1.2.8 2006/06/12 03:55:14 minahito Exp $ + * @version $Id: HelpAction.class.php,v 1.1.2.9 2006/07/20 08:20:42 minahito Exp $ */ if (!defined('XOOPS_ROOT_PATH')) exit(); @@ -93,6 +93,20 @@ */ var $_mDirname = null; + /** + * @var XCube_NewDelegate + */ + var $mCreateHelpSmarty = null; + + function Legacy_HelpAction($flag) + { + parent::Legacy_Action($flag); + + $this->mCreateHelpSmarty =& new XCube_NewDelegate(); + $this->mCreateHelpSmarty->add(array(&$this, '_createHelpSmarty')); + $this->mCreateHelpSmarty->register('Legacy_HelpAction.CreateHelpSmarty'); + } + function hasPerm(&$controller, &$xoopsUser) { $this->_mDirname = xoops_getrequest('dirname'); @@ -120,7 +134,8 @@ // // Smarty // - $smarty =& new Legacy_HelpSmarty(); + $smarty = null; + $this->mCreateHelpSmarty->call(new XCube_Ref($smarty)); $smarty->setDirname($this->_mDirname); // @@ -141,6 +156,13 @@ return LEGACY_FRAME_VIEW_SUCCESS; } + function _createHelpSmarty(&$smarty) + { + if (!is_object($smarty)) { + $smarty = new Legacy_HelpSmarty(); + } + } + function executeViewSuccess(&$controller, &$xoopsUser, &$renderer) { $renderer->setTemplateName("help.html");