Añadi correcciones para translations para plugins.. y arreglo en la clase G

This commit is contained in:
Brayan Osmar Pereyra Suxo
2013-06-06 16:33:05 -04:00
parent 1d6eda27eb
commit 9cd8f4922f

View File

@@ -474,14 +474,23 @@ class headPublisher
$aux = explode(PATH_SEP, $filename);
//check if G_PLUGIN_CLASS is defined, because publisher can be called without an environment
if (count($aux) > 2 && defined('G_PLUGIN_CLASS')) {
$flagPlugin = false;
$keyPlugin = count($aux)-2;
$oPluginRegistry = & PMPluginRegistry::getSingleton();
if (!($oPluginRegistry->isRegisteredFolder($aux[$keyPlugin]))) {
if ($oPluginRegistry->isRegisteredFolder($aux[$keyPlugin])) {
$flagPlugin = true;
} else {
$keyPlugin --;
if ($oPluginRegistry->isRegisteredFolder($aux[$keyPlugin]))) {
$flagPlugin = true;
}
}
if ($flagPlugin) {
array_push($this->extJsLibrary, 'translation.' . trim($aux[$keyPlugin]) . '.' . SYS_LANG);
$sPath = PATH_PLUGINS;
}
array_push($this->extJsLibrary, 'translation.' . trim($aux[$keyPlugin]) . '.' . SYS_LANG);
$sPath = PATH_PLUGINS;
}
}