[xoops-cvslog 3374] CVS update: xoops2jp/html/modules/legacyRender/kernel

Back to archive index

Minahito minah****@users*****
2006年 6月 27日 (火) 18:12:51 JST


Index: xoops2jp/html/modules/legacyRender/kernel/Legacy_RenderSystem.class.php
diff -u xoops2jp/html/modules/legacyRender/kernel/Legacy_RenderSystem.class.php:1.1.2.16 xoops2jp/html/modules/legacyRender/kernel/Legacy_RenderSystem.class.php:1.1.2.17
--- xoops2jp/html/modules/legacyRender/kernel/Legacy_RenderSystem.class.php:1.1.2.16	Fri May 19 16:43:14 2006
+++ xoops2jp/html/modules/legacyRender/kernel/Legacy_RenderSystem.class.php	Tue Jun 27 18:12:50 2006
@@ -1,13 +1,12 @@
 <?php
 /**
- * @version $Id: Legacy_RenderSystem.class.php,v 1.1.2.16 2006/05/19 07:43:14 nobunobu Exp $
+ * @version $Id: Legacy_RenderSystem.class.php,v 1.1.2.17 2006/06/27 09:12:50 minahito Exp $
  */
 
 if (!defined('XOOPS_ROOT_PATH')) exit();
 
 require_once XOOPS_ROOT_PATH."/modules/legacyRender/kernel/Legacy_RenderTarget.class.php";
 
-
 /**
  * Compatible render system with XOOPS 2 Themes & Templates.
  *
@@ -16,7 +15,6 @@
  */
 class Legacy_RenderSystem extends XCube_RenderSystem
 {
-	var $mController;
 	var $mXoopsTpl;
 
 	var $mBlockShowFlags;
@@ -32,22 +30,17 @@
 	 */
 	var $mMainRenderTarget;
 	
-	var $_mContentsData=null;
+	var $_mContentsData = null;
 
 	function Legacy_RenderSystem()
 	{
 		parent::XCube_RenderSystem();
-		$this->mBlockContents=array();
-	}
-	
-	function setDialogRenderMode()
-	{
-		die("DEPRECATED");
+		$this->mBlockContents = array();
 	}
 	
 	function prepare(&$controller)
 	{
-		$this->mController =& $controller;
+		parent::prepare($controller);
 		
 		require_once XOOPS_ROOT_PATH . "/class/template.php";
 
@@ -55,7 +48,7 @@
 		$this->mXoopsTpl =& new XoopsTpl();
 		
 		// compatible
-		$GLOBALS['xoopsTpl']=&$this->mXoopsTpl;
+		$GLOBALS['xoopsTpl'] =& $this->mXoopsTpl;
 		
 		$this->mXoopsTpl->xoops_setCaching(2);
 
@@ -65,7 +58,7 @@
 								));
 
 		// If debugger request debugging to me, send debug mode signal by any methods.
-		if($controller->mDebugger->isDebugRenderSystem()) {
+		if ($controller->mDebugger->isDebugRenderSystem()) {
 			$this->mXoopsTpl->xoops_setDebugging(true);
 		}
 		
@@ -83,31 +76,34 @@
 		// If this site has the setting of banner.
 		// TODO this process depends on XOOPS 2.0.x.
 		//
-		if($this->mController->mConfig['banners']==1)
+		if ($this->mController->mConfig['banners'] == 1) {
 			$this->mXoopsTpl->assign('xoops_banner',xoops_getbanner());
-		else
+		}
+		else {
 			$this->mXoopsTpl->assign('xoops_banner','&nbsp;');
+		}
 
 		// --------------------------------------
 		// Meta tags
 		// --------------------------------------
-		$configHandler=&xoops_gethandler('config');
-
-//		$configs =& $configHandler->getConfigsByCat(XOOPS_CONF_METAFOOTER);
         $moduleHandler =& xoops_gethandler('module');
         $legacyRender =& $moduleHandler->getByDirname('legacyRender');
-		$configs =& $configHandler->getConfigsByCat(0, $legacyRender->getVar('mid'));
-
-    	foreach ($configs as $name=>$value) {
-		    // prefix each tag with 'xoops_'
-			$this->mXoopsTpl->assign('xoops_'.$name, $value);
-	    }
+		
+		if (is_object($legacyRender)) {
+			$configHandler =& xoops_gethandler('config');
+			$configs =& $configHandler->getConfigsByCat(0, $legacyRender->getVar('mid'));
+			
+			foreach ($configs as $name => $value) {
+				// prefix each tag with 'xoops_'
+				$this->mXoopsTpl->assign('xoops_' . $name, $value);
+			}
+		}
 
 		// --------------------------------------
 		// Add User
 		// --------------------------------------
-		$arr=null;
-		if(is_object($this->mController->mXoopsUser)) {
+		$arr = null;
+		if (is_object($this->mController->mXoopsUser)) {
 			$arr = array(
 				'xoops_isuser' => true,
 				'xoops_userid' => $this->mController->mXoopsUser->getVar('uid'),


xoops-cvslog メーリングリストの案内
Back to archive index