summaryrefslogtreecommitdiff
path: root/framework/Web/UI/TClientScriptManager.php
diff options
context:
space:
mode:
Diffstat (limited to 'framework/Web/UI/TClientScriptManager.php')
-rw-r--r--framework/Web/UI/TClientScriptManager.php13
1 files changed, 10 insertions, 3 deletions
diff --git a/framework/Web/UI/TClientScriptManager.php b/framework/Web/UI/TClientScriptManager.php
index 5546ed3f..30009c63 100644
--- a/framework/Web/UI/TClientScriptManager.php
+++ b/framework/Web/UI/TClientScriptManager.php
@@ -121,7 +121,7 @@ class TClientScriptManager extends TApplicationComponent
$this->_registeredPradoScripts[$name]=true;
if(!isset(self::$_pradoScripts[$name]))
throw new TInvalidOperationException('csmanager_pradoscript_invalid',$name);
- $basePath=$this->getPradoBaseScriptPath();
+ $basePath=$this->getPradoScriptBasePath();
foreach(self::$_pradoScripts[$name] as $script)
{
if(!isset($this->_registeredPradoFiles[$script]))
@@ -133,7 +133,10 @@ class TClientScriptManager extends TApplicationComponent
}
}
- protected function getPradoBaseScriptPath()
+ /**
+ * @return string the directory containing the PRADO js script files
+ */
+ protected function getPradoScriptBasePath()
{
$basePath = Prado::getFrameworkPath().'/'.self::SCRIPT_PATH;
if($this->getApplication()->getMode()===TApplication::STATE_DEBUG)
@@ -142,6 +145,10 @@ class TClientScriptManager extends TApplicationComponent
return $basePath.'/compressed';
}
+ /**
+ * Renders the HTML tags for PRADO js files
+ * @param THtmlWriter writer
+ */
protected function renderPradoScripts($writer)
{
$files='';
@@ -155,7 +162,7 @@ class TClientScriptManager extends TApplicationComponent
}
if($files!=='')
{
- $basePath=$this->getPradoBaseScriptPath();
+ $basePath=$this->getPradoScriptBasePath();
$scriptLoader=$basePath.'/'.self::SCRIPT_LOADER;
$url=$this->publishFilePath($scriptLoader).'?js='.trim($files,',');
if($this->getApplication()->getMode()===TApplication::STATE_DEBUG)