src/View/ThemeResourceLoader.php
public function findThemedJavascript($name, $themes = null)
    {
        if ($themes === null) {
            $themes = SSViewer::get_themes();
        }

        if (substr($name, -3) !== '.js') {
            $name .= '.js';
        }

        $filename = $this->findThemedResource("javascript/$name", $themes);
        if ($filename === null) {
            $filename = $this->findThemedResource($name, $themes);
        }

        return $filename;
    }
public function findThemedJavascript($name, $themes = null)
    {
        if ($themes === null) {
            $themes = SSViewer::get_themes();
        }

        if (substr($name, -3) !== '.js') {
            $name .= '.js';
        }

        $filename = $this->findThemedResource("javascript/$name", $themes);
        if ($filename === null) {
            $filename = $this->findThemedResource($name, $themes);
        }

        return $filename;
    }
public function findThemedJavascript ( $ name , $ themes = null ) { if ( $ themes === null ) { $ themes = SSViewer :: get_themes ( ) ; } if ( substr ( $ name , - 3 ) !== '.js' ) { $ name .= '.js' ; } $ filename = $ this -> findThemedResource ( "javascript/$name" , $ themes ) ; if ( $ filename === null ) { $ filename = $ this -> findThemedResource ( $ name , $ themes ) ; } return $ filename ; }
Resolve themed javascript path

A javascript file in the current theme path name 'themename/javascript/$name.js' is first searched for,
and it that doesn't exist and the module parameter is set then a javascript file with that name in
the module is used.

@param string $name The name of the file - eg '/js/File.js' would have the name 'File'
@param array $themes List of themes, Defaults to {@see SSViewer::get_themes()}
@return string Path to resolved javascript file (relative to base dir)
Resolve themed javascript path