|
@@ 172-183 (lines=12) @@
|
| 169 |
|
* @param array $styles |
| 170 |
|
* @return array |
| 171 |
|
*/ |
| 172 |
|
static public function findStylesheetFiles($styles) { |
| 173 |
|
// Read the selected theme from the config file |
| 174 |
|
$theme = \OC_Util::getTheme(); |
| 175 |
|
|
| 176 |
|
$locator = new \OC\Template\CSSResourceLocator( |
| 177 |
|
\OC::$server->getLogger(), |
| 178 |
|
$theme, |
| 179 |
|
array( \OC::$SERVERROOT => \OC::$WEBROOT ), |
| 180 |
|
array( \OC::$SERVERROOT => \OC::$WEBROOT )); |
| 181 |
|
$locator->find($styles); |
| 182 |
|
return $locator->getResources(); |
| 183 |
|
} |
| 184 |
|
|
| 185 |
|
/** |
| 186 |
|
* @param array $scripts |
|
@@ 189-200 (lines=12) @@
|
| 186 |
|
* @param array $scripts |
| 187 |
|
* @return array |
| 188 |
|
*/ |
| 189 |
|
static public function findJavascriptFiles($scripts) { |
| 190 |
|
// Read the selected theme from the config file |
| 191 |
|
$theme = \OC_Util::getTheme(); |
| 192 |
|
|
| 193 |
|
$locator = new \OC\Template\JSResourceLocator( |
| 194 |
|
\OC::$server->getLogger(), |
| 195 |
|
$theme, |
| 196 |
|
array( \OC::$SERVERROOT => \OC::$WEBROOT ), |
| 197 |
|
array( \OC::$SERVERROOT => \OC::$WEBROOT )); |
| 198 |
|
$locator->find($scripts); |
| 199 |
|
return $locator->getResources(); |
| 200 |
|
} |
| 201 |
|
|
| 202 |
|
/** |
| 203 |
|
* Converts the absolute file path to a relative path from \OC::$SERVERROOT |