summaryrefslogtreecommitdiff
path: root/framework/Web/UI/TTemplateManager.php
diff options
context:
space:
mode:
authorxue <>2006-02-17 05:19:25 +0000
committerxue <>2006-02-17 05:19:25 +0000
commit7b38480de52c1d042ea542e2d06913a8c9b645fc (patch)
tree67ff025fb171a5325ac8fdc75a281ce8a19a2bd5 /framework/Web/UI/TTemplateManager.php
parentae1c1995b2fec431afe7cca23b2697e1bef17baf (diff)
Add TApplicationComponent class and adjusted the relevant classes.
Diffstat (limited to 'framework/Web/UI/TTemplateManager.php')
-rw-r--r--framework/Web/UI/TTemplateManager.php12
1 files changed, 6 insertions, 6 deletions
diff --git a/framework/Web/UI/TTemplateManager.php b/framework/Web/UI/TTemplateManager.php
index e87a23eb..67bda1b2 100644
--- a/framework/Web/UI/TTemplateManager.php
+++ b/framework/Web/UI/TTemplateManager.php
@@ -50,7 +50,7 @@ class TTemplateManager extends TModule
*/
public function init($config)
{
- $this->getApplication()->getPageService()->setTemplateManager($this);
+ $this->getService()->setTemplateManager($this);
}
/**
@@ -259,7 +259,7 @@ class TTemplate extends TComponent implements ITemplate
public function instantiateIn($tplControl)
{
if(($page=$tplControl->getPage())===null)
- $page=Prado::getApplication()->getPageService()->getRequestedPage();
+ $page=$this->getService()->getRequestedPage();
$controls=array();
foreach($this->_tpl as $key=>$object)
{
@@ -371,11 +371,11 @@ class TTemplate extends TComponent implements ITemplate
$component->$setter($value[1]);
break;
case self::CONFIG_ASSET: // asset URL
- $url=Prado::getApplication()->getAssetManager()->publishFilePath($this->_contextPath.'/'.$value[1]);
+ $url=$this->publishFilePath($this->_contextPath.'/'.$value[1]);
$component->$setter($url);
break;
case self::CONFIG_PARAMETER: // application parameter
- $component->$setter(Prado::getApplication()->getParameters()->itemAt($value[1]));
+ $component->$setter($this->getApplication()->getParameters()->itemAt($value[1]));
break;
case self::CONFIG_LOCALIZATION:
Prado::using('System.I18N.Translation');
@@ -411,11 +411,11 @@ class TTemplate extends TComponent implements ITemplate
$component->setSubProperty($name,$value[1]);
break;
case self::CONFIG_ASSET: // asset URL
- $url=Prado::getApplication()->getAssetManager()->publishFilePath($this->_contextPath.'/'.$value[1]);
+ $url=$this->publishFilePath($this->_contextPath.'/'.$value[1]);
$component->setSubProperty($name,$url);
break;
case self::CONFIG_PARAMETER: // application parameter
- $component->setSubProperty($name,Prado::getApplication()->getParameters()->itemAt($value[1]));
+ $component->setSubProperty($name,$this->getApplication()->getParameters()->itemAt($value[1]));
break;
case self::CONFIG_LOCALIZATION:
$component->setSubProperty($name,localize($value[1]));