Minahito
minah****@users*****
2006年 9月 28日 (木) 14:03:55 JST
Index: xoops2jp/html/modules/base/preload/ThemeSelect.class.php diff -u xoops2jp/html/modules/base/preload/ThemeSelect.class.php:1.1.2.8 xoops2jp/html/modules/base/preload/ThemeSelect.class.php:1.1.2.8.2.1 --- xoops2jp/html/modules/base/preload/ThemeSelect.class.php:1.1.2.8 Thu Sep 7 16:21:13 2006 +++ xoops2jp/html/modules/base/preload/ThemeSelect.class.php Thu Sep 28 14:03:55 2006 @@ -1,7 +1,7 @@ <?php /** * @package Legacy - * @version $Id: ThemeSelect.class.php,v 1.1.2.8 2006/09/07 07:21:13 minahito Exp $ + * @version $Id: ThemeSelect.class.php,v 1.1.2.8.2.1 2006/09/28 05:03:55 minahito Exp $ */ if (!defined('XOOPS_ROOT_PATH')) exit(); @@ -28,7 +28,7 @@ $this->mIsSelectableTheme =& new XCube_Delegate(); $this->mIsSelectableTheme->register('Base_ThemeSelect.IsSelectableTheme'); - $controller->mSiteLogin->add(array(&$this, 'doChangeTheme')); + $controller->mSetupUser->add(array(&$this, 'doChangeTheme')); } function preBlockFilter() @@ -42,13 +42,13 @@ * * @param XoopsUser $xoopsUser Must parameter, because this is added to login event. */ - function doChangeTheme(&$xoopsUser) + function doChangeTheme(&$principal, &$controller, &$context) { if (!empty($_POST['xoops_theme_select']) && $this->_isSelectableTheme($_POST['xoops_theme_select'])) { - $this->mController->setMainTheme($_POST['xoops_theme_select']); + $this->mController->setTheme($_POST['xoops_theme_select']); $_SESSION['xoopsUserTheme'] = $_POST['xoops_theme_select']; } elseif (!empty($_SESSION['xoopsUserTheme']) && $this->_isSelectableTheme($_SESSION['xoopsUserTheme'])) { - $this->mController->setMainTheme($_SESSION['xoopsUserTheme']); + $this->mController->setTheme($_SESSION['xoopsUserTheme']); } }