|
@@ 190-201 (lines=12) @@
|
| 187 |
|
* @param array $styles |
| 188 |
|
* @return array |
| 189 |
|
*/ |
| 190 |
|
static public function findStylesheetFiles($styles) { |
| 191 |
|
// Read the selected theme from the config file |
| 192 |
|
$theme = \OC_Util::getTheme(); |
| 193 |
|
|
| 194 |
|
$locator = new \OC\Template\CSSResourceLocator( |
| 195 |
|
\OC::$server->getLogger(), |
| 196 |
|
$theme, |
| 197 |
|
array( \OC::$SERVERROOT => \OC::$WEBROOT ), |
| 198 |
|
array( \OC::$SERVERROOT => \OC::$WEBROOT )); |
| 199 |
|
$locator->find($styles); |
| 200 |
|
return $locator->getResources(); |
| 201 |
|
} |
| 202 |
|
|
| 203 |
|
/** |
| 204 |
|
* @param array $scripts |
|
@@ 207-218 (lines=12) @@
|
| 204 |
|
* @param array $scripts |
| 205 |
|
* @return array |
| 206 |
|
*/ |
| 207 |
|
static public function findJavascriptFiles($scripts) { |
| 208 |
|
// Read the selected theme from the config file |
| 209 |
|
$theme = \OC_Util::getTheme(); |
| 210 |
|
|
| 211 |
|
$locator = new \OC\Template\JSResourceLocator( |
| 212 |
|
\OC::$server->getLogger(), |
| 213 |
|
$theme, |
| 214 |
|
array( \OC::$SERVERROOT => \OC::$WEBROOT ), |
| 215 |
|
array( \OC::$SERVERROOT => \OC::$WEBROOT )); |
| 216 |
|
$locator->find($scripts); |
| 217 |
|
return $locator->getResources(); |
| 218 |
|
} |
| 219 |
|
|
| 220 |
|
/** |
| 221 |
|
* Converts the absolute file path to a relative path from \OC::$SERVERROOT |