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

アーカイブの一覧に戻る

NobuNobu nobun****@users*****
2006年 1月 26日 (木) 00:22:23 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.10 xoops2jp/html/modules/legacyRender/kernel/Legacy_RenderSystem.class.php:1.1.2.11
--- xoops2jp/html/modules/legacyRender/kernel/Legacy_RenderSystem.class.php:1.1.2.10	Wed Jan 25 23:03:10 2006
+++ xoops2jp/html/modules/legacyRender/kernel/Legacy_RenderSystem.class.php	Thu Jan 26 00:22:23 2006
@@ -1,6 +1,6 @@
 <?php
 /**
- * @version $Id: Legacy_RenderSystem.class.php,v 1.1.2.10 2006/01/25 14:03:10 nobunobu Exp $
+ * @version $Id: Legacy_RenderSystem.class.php,v 1.1.2.11 2006/01/25 15:22:23 nobunobu Exp $
  */
 
 require_once XOOPS_ROOT_PATH."/modules/legacyRender/kernel/Legacy_RenderTarget.class.php";
@@ -261,7 +261,7 @@
 			);
 
 		foreach($assignNameMap as $key=>$val) {
-			$this->mXoopsTpl->assign($val['showflag'],(isset($this->mBlockShowFlags[$key])&&$this->mBlockShowFlags[$key]) ? 1 : 0);
+			$this->mXoopsTpl->assign($val['showflag'],$this->_getBlockShowFlag($val['showflag']));
 			if(isset($this->mBlockContents[$key])) {
 				foreach($this->mBlockContents[$key] as $result) {
 					$this->mXoopsTpl->append($val['block'],$result);
@@ -283,6 +283,26 @@
 		$target->setResult($result);
 	}
 
+	function _getBlockShowFlag($area) {
+		switch($area) {
+			case 'xoops_showrblock' :
+				if (isset($GLOBALS['show_rblock']) && empty($GLOBALS['show_rblock'])) return 0;
+				return (!empty($this->mBlockShowFlags[XOOPS_SIDEBLOCK_RIGHT])) ? 1 : 0;
+				break;
+			case 'xoops_showlblock' :
+				if (isset($GLOBALS['show_lblock']) && empty($GLOBALS['show_lblock'])) return 0;
+				return (!empty($this->mBlockShowFlags[XOOPS_SIDEBLOCK_LEFT])) ? 1 : 0;
+				break;
+			case 'xoops_showcblock' :
+				if (isset($GLOBALS['show_cblock']) && empty($GLOBALS['show_cblock'])) return 0;
+				return (!empty($this->mBlockShowFlags[XOOPS_CENTERBLOCK_LEFT])||
+				        !empty($this->mBlockShowFlags[XOOPS_CENTERBLOCK_RIGHT])||
+				        !empty($this->mBlockShowFlags[XOOPS_CENTERBLOCK_CENTER])) ? 1 : 0;
+				break;
+			default :
+				return 0;
+		}
+	}
 	//
 	// There must not be the following functions here!
 	//


xoops-cvslog メーリングリストの案内
アーカイブの一覧に戻る