@@ -31,161 +31,161 @@ |
||
| 31 | 31 | use OCP\Defaults; |
| 32 | 32 | |
| 33 | 33 | class Base { |
| 34 | - private $template; // The template |
|
| 35 | - private $vars; // Vars |
|
| 36 | - |
|
| 37 | - /** @var \OCP\IL10N */ |
|
| 38 | - private $l10n; |
|
| 39 | - |
|
| 40 | - /** @var Defaults */ |
|
| 41 | - private $theme; |
|
| 42 | - |
|
| 43 | - /** |
|
| 44 | - * @param string $template |
|
| 45 | - * @param string $requestToken |
|
| 46 | - * @param \OCP\IL10N $l10n |
|
| 47 | - * @param Defaults $theme |
|
| 48 | - */ |
|
| 49 | - public function __construct($template, $requestToken, $l10n, $theme ) { |
|
| 50 | - $this->vars = array(); |
|
| 51 | - $this->vars['requesttoken'] = $requestToken; |
|
| 52 | - $this->l10n = $l10n; |
|
| 53 | - $this->template = $template; |
|
| 54 | - $this->theme = $theme; |
|
| 55 | - } |
|
| 56 | - |
|
| 57 | - /** |
|
| 58 | - * @param string $serverRoot |
|
| 59 | - * @param string|false $app_dir |
|
| 60 | - * @param string $theme |
|
| 61 | - * @param string $app |
|
| 62 | - * @return string[] |
|
| 63 | - */ |
|
| 64 | - protected function getAppTemplateDirs($theme, $app, $serverRoot, $app_dir) { |
|
| 65 | - // Check if the app is in the app folder or in the root |
|
| 66 | - if( file_exists($app_dir.'/templates/' )) { |
|
| 67 | - return [ |
|
| 68 | - $serverRoot.'/themes/'.$theme.'/apps/'.$app.'/templates/', |
|
| 69 | - $app_dir.'/templates/', |
|
| 70 | - ]; |
|
| 71 | - } |
|
| 72 | - return [ |
|
| 73 | - $serverRoot.'/themes/'.$theme.'/'.$app.'/templates/', |
|
| 74 | - $serverRoot.'/'.$app.'/templates/', |
|
| 75 | - ]; |
|
| 76 | - } |
|
| 77 | - |
|
| 78 | - /** |
|
| 79 | - * @param string $serverRoot |
|
| 80 | - * @param string $theme |
|
| 81 | - * @return string[] |
|
| 82 | - */ |
|
| 83 | - protected function getCoreTemplateDirs($theme, $serverRoot) { |
|
| 84 | - return [ |
|
| 85 | - $serverRoot.'/themes/'.$theme.'/core/templates/', |
|
| 86 | - $serverRoot.'/core/templates/', |
|
| 87 | - ]; |
|
| 88 | - } |
|
| 89 | - |
|
| 90 | - /** |
|
| 91 | - * Assign variables |
|
| 92 | - * @param string $key key |
|
| 93 | - * @param array|bool|integer|string $value value |
|
| 94 | - * @return bool |
|
| 95 | - * |
|
| 96 | - * This function assigns a variable. It can be accessed via $_[$key] in |
|
| 97 | - * the template. |
|
| 98 | - * |
|
| 99 | - * If the key existed before, it will be overwritten |
|
| 100 | - */ |
|
| 101 | - public function assign( $key, $value) { |
|
| 102 | - $this->vars[$key] = $value; |
|
| 103 | - return true; |
|
| 104 | - } |
|
| 105 | - |
|
| 106 | - /** |
|
| 107 | - * Appends a variable |
|
| 108 | - * @param string $key key |
|
| 109 | - * @param mixed $value value |
|
| 110 | - * @return boolean|null |
|
| 111 | - * |
|
| 112 | - * This function assigns a variable in an array context. If the key already |
|
| 113 | - * exists, the value will be appended. It can be accessed via |
|
| 114 | - * $_[$key][$position] in the template. |
|
| 115 | - */ |
|
| 116 | - public function append( $key, $value ) { |
|
| 117 | - if( array_key_exists( $key, $this->vars )) { |
|
| 118 | - $this->vars[$key][] = $value; |
|
| 119 | - } |
|
| 120 | - else{ |
|
| 121 | - $this->vars[$key] = array( $value ); |
|
| 122 | - } |
|
| 123 | - } |
|
| 124 | - |
|
| 125 | - /** |
|
| 126 | - * Prints the proceeded template |
|
| 127 | - * @return bool |
|
| 128 | - * |
|
| 129 | - * This function proceeds the template and prints its output. |
|
| 130 | - */ |
|
| 131 | - public function printPage() { |
|
| 132 | - $data = $this->fetchPage(); |
|
| 133 | - if( $data === false ) { |
|
| 134 | - return false; |
|
| 135 | - } |
|
| 136 | - else{ |
|
| 137 | - print $data; |
|
| 138 | - return true; |
|
| 139 | - } |
|
| 140 | - } |
|
| 141 | - |
|
| 142 | - /** |
|
| 143 | - * Process the template |
|
| 144 | - * |
|
| 145 | - * @param array|null $additionalParams |
|
| 146 | - * @return string This function processes the template. |
|
| 147 | - * |
|
| 148 | - * This function processes the template. |
|
| 149 | - */ |
|
| 150 | - public function fetchPage($additionalParams = null) { |
|
| 151 | - return $this->load($this->template, $additionalParams); |
|
| 152 | - } |
|
| 153 | - |
|
| 154 | - /** |
|
| 155 | - * doing the actual work |
|
| 156 | - * |
|
| 157 | - * @param string $file |
|
| 158 | - * @param array|null $additionalParams |
|
| 159 | - * @return string content |
|
| 160 | - * |
|
| 161 | - * Includes the template file, fetches its output |
|
| 162 | - */ |
|
| 163 | - protected function load($file, $additionalParams = null) { |
|
| 164 | - // Register the variables |
|
| 165 | - $_ = $this->vars; |
|
| 166 | - $l = $this->l10n; |
|
| 167 | - $theme = $this->theme; |
|
| 168 | - |
|
| 169 | - if(!is_null($additionalParams)) { |
|
| 170 | - $_ = array_merge( $additionalParams, $this->vars ); |
|
| 171 | - foreach ($_ as $var => $value) { |
|
| 172 | - ${$var} = $value; |
|
| 173 | - } |
|
| 174 | - } |
|
| 175 | - |
|
| 176 | - // Include |
|
| 177 | - ob_start(); |
|
| 178 | - try { |
|
| 179 | - include $file; |
|
| 180 | - $data = ob_get_contents(); |
|
| 181 | - } catch (\Exception $e) { |
|
| 182 | - @ob_end_clean(); |
|
| 183 | - throw $e; |
|
| 184 | - } |
|
| 185 | - @ob_end_clean(); |
|
| 186 | - |
|
| 187 | - // Return data |
|
| 188 | - return $data; |
|
| 189 | - } |
|
| 34 | + private $template; // The template |
|
| 35 | + private $vars; // Vars |
|
| 36 | + |
|
| 37 | + /** @var \OCP\IL10N */ |
|
| 38 | + private $l10n; |
|
| 39 | + |
|
| 40 | + /** @var Defaults */ |
|
| 41 | + private $theme; |
|
| 42 | + |
|
| 43 | + /** |
|
| 44 | + * @param string $template |
|
| 45 | + * @param string $requestToken |
|
| 46 | + * @param \OCP\IL10N $l10n |
|
| 47 | + * @param Defaults $theme |
|
| 48 | + */ |
|
| 49 | + public function __construct($template, $requestToken, $l10n, $theme ) { |
|
| 50 | + $this->vars = array(); |
|
| 51 | + $this->vars['requesttoken'] = $requestToken; |
|
| 52 | + $this->l10n = $l10n; |
|
| 53 | + $this->template = $template; |
|
| 54 | + $this->theme = $theme; |
|
| 55 | + } |
|
| 56 | + |
|
| 57 | + /** |
|
| 58 | + * @param string $serverRoot |
|
| 59 | + * @param string|false $app_dir |
|
| 60 | + * @param string $theme |
|
| 61 | + * @param string $app |
|
| 62 | + * @return string[] |
|
| 63 | + */ |
|
| 64 | + protected function getAppTemplateDirs($theme, $app, $serverRoot, $app_dir) { |
|
| 65 | + // Check if the app is in the app folder or in the root |
|
| 66 | + if( file_exists($app_dir.'/templates/' )) { |
|
| 67 | + return [ |
|
| 68 | + $serverRoot.'/themes/'.$theme.'/apps/'.$app.'/templates/', |
|
| 69 | + $app_dir.'/templates/', |
|
| 70 | + ]; |
|
| 71 | + } |
|
| 72 | + return [ |
|
| 73 | + $serverRoot.'/themes/'.$theme.'/'.$app.'/templates/', |
|
| 74 | + $serverRoot.'/'.$app.'/templates/', |
|
| 75 | + ]; |
|
| 76 | + } |
|
| 77 | + |
|
| 78 | + /** |
|
| 79 | + * @param string $serverRoot |
|
| 80 | + * @param string $theme |
|
| 81 | + * @return string[] |
|
| 82 | + */ |
|
| 83 | + protected function getCoreTemplateDirs($theme, $serverRoot) { |
|
| 84 | + return [ |
|
| 85 | + $serverRoot.'/themes/'.$theme.'/core/templates/', |
|
| 86 | + $serverRoot.'/core/templates/', |
|
| 87 | + ]; |
|
| 88 | + } |
|
| 89 | + |
|
| 90 | + /** |
|
| 91 | + * Assign variables |
|
| 92 | + * @param string $key key |
|
| 93 | + * @param array|bool|integer|string $value value |
|
| 94 | + * @return bool |
|
| 95 | + * |
|
| 96 | + * This function assigns a variable. It can be accessed via $_[$key] in |
|
| 97 | + * the template. |
|
| 98 | + * |
|
| 99 | + * If the key existed before, it will be overwritten |
|
| 100 | + */ |
|
| 101 | + public function assign( $key, $value) { |
|
| 102 | + $this->vars[$key] = $value; |
|
| 103 | + return true; |
|
| 104 | + } |
|
| 105 | + |
|
| 106 | + /** |
|
| 107 | + * Appends a variable |
|
| 108 | + * @param string $key key |
|
| 109 | + * @param mixed $value value |
|
| 110 | + * @return boolean|null |
|
| 111 | + * |
|
| 112 | + * This function assigns a variable in an array context. If the key already |
|
| 113 | + * exists, the value will be appended. It can be accessed via |
|
| 114 | + * $_[$key][$position] in the template. |
|
| 115 | + */ |
|
| 116 | + public function append( $key, $value ) { |
|
| 117 | + if( array_key_exists( $key, $this->vars )) { |
|
| 118 | + $this->vars[$key][] = $value; |
|
| 119 | + } |
|
| 120 | + else{ |
|
| 121 | + $this->vars[$key] = array( $value ); |
|
| 122 | + } |
|
| 123 | + } |
|
| 124 | + |
|
| 125 | + /** |
|
| 126 | + * Prints the proceeded template |
|
| 127 | + * @return bool |
|
| 128 | + * |
|
| 129 | + * This function proceeds the template and prints its output. |
|
| 130 | + */ |
|
| 131 | + public function printPage() { |
|
| 132 | + $data = $this->fetchPage(); |
|
| 133 | + if( $data === false ) { |
|
| 134 | + return false; |
|
| 135 | + } |
|
| 136 | + else{ |
|
| 137 | + print $data; |
|
| 138 | + return true; |
|
| 139 | + } |
|
| 140 | + } |
|
| 141 | + |
|
| 142 | + /** |
|
| 143 | + * Process the template |
|
| 144 | + * |
|
| 145 | + * @param array|null $additionalParams |
|
| 146 | + * @return string This function processes the template. |
|
| 147 | + * |
|
| 148 | + * This function processes the template. |
|
| 149 | + */ |
|
| 150 | + public function fetchPage($additionalParams = null) { |
|
| 151 | + return $this->load($this->template, $additionalParams); |
|
| 152 | + } |
|
| 153 | + |
|
| 154 | + /** |
|
| 155 | + * doing the actual work |
|
| 156 | + * |
|
| 157 | + * @param string $file |
|
| 158 | + * @param array|null $additionalParams |
|
| 159 | + * @return string content |
|
| 160 | + * |
|
| 161 | + * Includes the template file, fetches its output |
|
| 162 | + */ |
|
| 163 | + protected function load($file, $additionalParams = null) { |
|
| 164 | + // Register the variables |
|
| 165 | + $_ = $this->vars; |
|
| 166 | + $l = $this->l10n; |
|
| 167 | + $theme = $this->theme; |
|
| 168 | + |
|
| 169 | + if(!is_null($additionalParams)) { |
|
| 170 | + $_ = array_merge( $additionalParams, $this->vars ); |
|
| 171 | + foreach ($_ as $var => $value) { |
|
| 172 | + ${$var} = $value; |
|
| 173 | + } |
|
| 174 | + } |
|
| 175 | + |
|
| 176 | + // Include |
|
| 177 | + ob_start(); |
|
| 178 | + try { |
|
| 179 | + include $file; |
|
| 180 | + $data = ob_get_contents(); |
|
| 181 | + } catch (\Exception $e) { |
|
| 182 | + @ob_end_clean(); |
|
| 183 | + throw $e; |
|
| 184 | + } |
|
| 185 | + @ob_end_clean(); |
|
| 186 | + |
|
| 187 | + // Return data |
|
| 188 | + return $data; |
|
| 189 | + } |
|
| 190 | 190 | |
| 191 | 191 | } |
@@ -46,7 +46,7 @@ discard block |
||
| 46 | 46 | * @param \OCP\IL10N $l10n |
| 47 | 47 | * @param Defaults $theme |
| 48 | 48 | */ |
| 49 | - public function __construct($template, $requestToken, $l10n, $theme ) { |
|
| 49 | + public function __construct($template, $requestToken, $l10n, $theme) { |
|
| 50 | 50 | $this->vars = array(); |
| 51 | 51 | $this->vars['requesttoken'] = $requestToken; |
| 52 | 52 | $this->l10n = $l10n; |
@@ -63,7 +63,7 @@ discard block |
||
| 63 | 63 | */ |
| 64 | 64 | protected function getAppTemplateDirs($theme, $app, $serverRoot, $app_dir) { |
| 65 | 65 | // Check if the app is in the app folder or in the root |
| 66 | - if( file_exists($app_dir.'/templates/' )) { |
|
| 66 | + if (file_exists($app_dir.'/templates/')) { |
|
| 67 | 67 | return [ |
| 68 | 68 | $serverRoot.'/themes/'.$theme.'/apps/'.$app.'/templates/', |
| 69 | 69 | $app_dir.'/templates/', |
@@ -98,7 +98,7 @@ discard block |
||
| 98 | 98 | * |
| 99 | 99 | * If the key existed before, it will be overwritten |
| 100 | 100 | */ |
| 101 | - public function assign( $key, $value) { |
|
| 101 | + public function assign($key, $value) { |
|
| 102 | 102 | $this->vars[$key] = $value; |
| 103 | 103 | return true; |
| 104 | 104 | } |
@@ -113,12 +113,12 @@ discard block |
||
| 113 | 113 | * exists, the value will be appended. It can be accessed via |
| 114 | 114 | * $_[$key][$position] in the template. |
| 115 | 115 | */ |
| 116 | - public function append( $key, $value ) { |
|
| 117 | - if( array_key_exists( $key, $this->vars )) { |
|
| 116 | + public function append($key, $value) { |
|
| 117 | + if (array_key_exists($key, $this->vars)) { |
|
| 118 | 118 | $this->vars[$key][] = $value; |
| 119 | 119 | } |
| 120 | - else{ |
|
| 121 | - $this->vars[$key] = array( $value ); |
|
| 120 | + else { |
|
| 121 | + $this->vars[$key] = array($value); |
|
| 122 | 122 | } |
| 123 | 123 | } |
| 124 | 124 | |
@@ -130,10 +130,10 @@ discard block |
||
| 130 | 130 | */ |
| 131 | 131 | public function printPage() { |
| 132 | 132 | $data = $this->fetchPage(); |
| 133 | - if( $data === false ) { |
|
| 133 | + if ($data === false) { |
|
| 134 | 134 | return false; |
| 135 | 135 | } |
| 136 | - else{ |
|
| 136 | + else { |
|
| 137 | 137 | print $data; |
| 138 | 138 | return true; |
| 139 | 139 | } |
@@ -166,8 +166,8 @@ discard block |
||
| 166 | 166 | $l = $this->l10n; |
| 167 | 167 | $theme = $this->theme; |
| 168 | 168 | |
| 169 | - if(!is_null($additionalParams)) { |
|
| 170 | - $_ = array_merge( $additionalParams, $this->vars ); |
|
| 169 | + if (!is_null($additionalParams)) { |
|
| 170 | + $_ = array_merge($additionalParams, $this->vars); |
|
| 171 | 171 | foreach ($_ as $var => $value) { |
| 172 | 172 | ${$var} = $value; |
| 173 | 173 | } |
@@ -37,124 +37,124 @@ |
||
| 37 | 37 | */ |
| 38 | 38 | class TemplateResponse extends Response { |
| 39 | 39 | |
| 40 | - /** |
|
| 41 | - * name of the template |
|
| 42 | - * @var string |
|
| 43 | - */ |
|
| 44 | - protected $templateName; |
|
| 45 | - |
|
| 46 | - /** |
|
| 47 | - * parameters |
|
| 48 | - * @var array |
|
| 49 | - */ |
|
| 50 | - protected $params; |
|
| 51 | - |
|
| 52 | - /** |
|
| 53 | - * rendering type (admin, user, blank) |
|
| 54 | - * @var string |
|
| 55 | - */ |
|
| 56 | - protected $renderAs; |
|
| 57 | - |
|
| 58 | - /** |
|
| 59 | - * app name |
|
| 60 | - * @var string |
|
| 61 | - */ |
|
| 62 | - protected $appName; |
|
| 63 | - |
|
| 64 | - /** |
|
| 65 | - * constructor of TemplateResponse |
|
| 66 | - * @param string $appName the name of the app to load the template from |
|
| 67 | - * @param string $templateName the name of the template |
|
| 68 | - * @param array $params an array of parameters which should be passed to the |
|
| 69 | - * template |
|
| 70 | - * @param string $renderAs how the page should be rendered, defaults to user |
|
| 71 | - * @since 6.0.0 - parameters $params and $renderAs were added in 7.0.0 |
|
| 72 | - */ |
|
| 73 | - public function __construct($appName, $templateName, array $params=array(), |
|
| 74 | - $renderAs='user') { |
|
| 75 | - $this->templateName = $templateName; |
|
| 76 | - $this->appName = $appName; |
|
| 77 | - $this->params = $params; |
|
| 78 | - $this->renderAs = $renderAs; |
|
| 79 | - } |
|
| 80 | - |
|
| 81 | - |
|
| 82 | - /** |
|
| 83 | - * Sets template parameters |
|
| 84 | - * @param array $params an array with key => value structure which sets template |
|
| 85 | - * variables |
|
| 86 | - * @return TemplateResponse Reference to this object |
|
| 87 | - * @since 6.0.0 - return value was added in 7.0.0 |
|
| 88 | - */ |
|
| 89 | - public function setParams(array $params){ |
|
| 90 | - $this->params = $params; |
|
| 91 | - |
|
| 92 | - return $this; |
|
| 93 | - } |
|
| 94 | - |
|
| 95 | - |
|
| 96 | - /** |
|
| 97 | - * Used for accessing the set parameters |
|
| 98 | - * @return array the params |
|
| 99 | - * @since 6.0.0 |
|
| 100 | - */ |
|
| 101 | - public function getParams(){ |
|
| 102 | - return $this->params; |
|
| 103 | - } |
|
| 104 | - |
|
| 105 | - |
|
| 106 | - /** |
|
| 107 | - * Used for accessing the name of the set template |
|
| 108 | - * @return string the name of the used template |
|
| 109 | - * @since 6.0.0 |
|
| 110 | - */ |
|
| 111 | - public function getTemplateName(){ |
|
| 112 | - return $this->templateName; |
|
| 113 | - } |
|
| 114 | - |
|
| 115 | - |
|
| 116 | - /** |
|
| 117 | - * Sets the template page |
|
| 118 | - * @param string $renderAs admin, user or blank. Admin also prints the admin |
|
| 119 | - * settings header and footer, user renders the normal |
|
| 120 | - * normal page including footer and header and blank |
|
| 121 | - * just renders the plain template |
|
| 122 | - * @return TemplateResponse Reference to this object |
|
| 123 | - * @since 6.0.0 - return value was added in 7.0.0 |
|
| 124 | - */ |
|
| 125 | - public function renderAs($renderAs){ |
|
| 126 | - $this->renderAs = $renderAs; |
|
| 127 | - |
|
| 128 | - return $this; |
|
| 129 | - } |
|
| 130 | - |
|
| 131 | - |
|
| 132 | - /** |
|
| 133 | - * Returns the set renderAs |
|
| 134 | - * @return string the renderAs value |
|
| 135 | - * @since 6.0.0 |
|
| 136 | - */ |
|
| 137 | - public function getRenderAs(){ |
|
| 138 | - return $this->renderAs; |
|
| 139 | - } |
|
| 140 | - |
|
| 141 | - |
|
| 142 | - /** |
|
| 143 | - * Returns the rendered html |
|
| 144 | - * @return string the rendered html |
|
| 145 | - * @since 6.0.0 |
|
| 146 | - */ |
|
| 147 | - public function render(){ |
|
| 148 | - // \OCP\Template needs an empty string instead of 'blank' for an unwrapped response |
|
| 149 | - $renderAs = $this->renderAs === 'blank' ? '' : $this->renderAs; |
|
| 150 | - |
|
| 151 | - $template = new \OCP\Template($this->appName, $this->templateName, $renderAs); |
|
| 152 | - |
|
| 153 | - foreach($this->params as $key => $value){ |
|
| 154 | - $template->assign($key, $value); |
|
| 155 | - } |
|
| 156 | - |
|
| 157 | - return $template->fetchPage($this->params); |
|
| 158 | - } |
|
| 40 | + /** |
|
| 41 | + * name of the template |
|
| 42 | + * @var string |
|
| 43 | + */ |
|
| 44 | + protected $templateName; |
|
| 45 | + |
|
| 46 | + /** |
|
| 47 | + * parameters |
|
| 48 | + * @var array |
|
| 49 | + */ |
|
| 50 | + protected $params; |
|
| 51 | + |
|
| 52 | + /** |
|
| 53 | + * rendering type (admin, user, blank) |
|
| 54 | + * @var string |
|
| 55 | + */ |
|
| 56 | + protected $renderAs; |
|
| 57 | + |
|
| 58 | + /** |
|
| 59 | + * app name |
|
| 60 | + * @var string |
|
| 61 | + */ |
|
| 62 | + protected $appName; |
|
| 63 | + |
|
| 64 | + /** |
|
| 65 | + * constructor of TemplateResponse |
|
| 66 | + * @param string $appName the name of the app to load the template from |
|
| 67 | + * @param string $templateName the name of the template |
|
| 68 | + * @param array $params an array of parameters which should be passed to the |
|
| 69 | + * template |
|
| 70 | + * @param string $renderAs how the page should be rendered, defaults to user |
|
| 71 | + * @since 6.0.0 - parameters $params and $renderAs were added in 7.0.0 |
|
| 72 | + */ |
|
| 73 | + public function __construct($appName, $templateName, array $params=array(), |
|
| 74 | + $renderAs='user') { |
|
| 75 | + $this->templateName = $templateName; |
|
| 76 | + $this->appName = $appName; |
|
| 77 | + $this->params = $params; |
|
| 78 | + $this->renderAs = $renderAs; |
|
| 79 | + } |
|
| 80 | + |
|
| 81 | + |
|
| 82 | + /** |
|
| 83 | + * Sets template parameters |
|
| 84 | + * @param array $params an array with key => value structure which sets template |
|
| 85 | + * variables |
|
| 86 | + * @return TemplateResponse Reference to this object |
|
| 87 | + * @since 6.0.0 - return value was added in 7.0.0 |
|
| 88 | + */ |
|
| 89 | + public function setParams(array $params){ |
|
| 90 | + $this->params = $params; |
|
| 91 | + |
|
| 92 | + return $this; |
|
| 93 | + } |
|
| 94 | + |
|
| 95 | + |
|
| 96 | + /** |
|
| 97 | + * Used for accessing the set parameters |
|
| 98 | + * @return array the params |
|
| 99 | + * @since 6.0.0 |
|
| 100 | + */ |
|
| 101 | + public function getParams(){ |
|
| 102 | + return $this->params; |
|
| 103 | + } |
|
| 104 | + |
|
| 105 | + |
|
| 106 | + /** |
|
| 107 | + * Used for accessing the name of the set template |
|
| 108 | + * @return string the name of the used template |
|
| 109 | + * @since 6.0.0 |
|
| 110 | + */ |
|
| 111 | + public function getTemplateName(){ |
|
| 112 | + return $this->templateName; |
|
| 113 | + } |
|
| 114 | + |
|
| 115 | + |
|
| 116 | + /** |
|
| 117 | + * Sets the template page |
|
| 118 | + * @param string $renderAs admin, user or blank. Admin also prints the admin |
|
| 119 | + * settings header and footer, user renders the normal |
|
| 120 | + * normal page including footer and header and blank |
|
| 121 | + * just renders the plain template |
|
| 122 | + * @return TemplateResponse Reference to this object |
|
| 123 | + * @since 6.0.0 - return value was added in 7.0.0 |
|
| 124 | + */ |
|
| 125 | + public function renderAs($renderAs){ |
|
| 126 | + $this->renderAs = $renderAs; |
|
| 127 | + |
|
| 128 | + return $this; |
|
| 129 | + } |
|
| 130 | + |
|
| 131 | + |
|
| 132 | + /** |
|
| 133 | + * Returns the set renderAs |
|
| 134 | + * @return string the renderAs value |
|
| 135 | + * @since 6.0.0 |
|
| 136 | + */ |
|
| 137 | + public function getRenderAs(){ |
|
| 138 | + return $this->renderAs; |
|
| 139 | + } |
|
| 140 | + |
|
| 141 | + |
|
| 142 | + /** |
|
| 143 | + * Returns the rendered html |
|
| 144 | + * @return string the rendered html |
|
| 145 | + * @since 6.0.0 |
|
| 146 | + */ |
|
| 147 | + public function render(){ |
|
| 148 | + // \OCP\Template needs an empty string instead of 'blank' for an unwrapped response |
|
| 149 | + $renderAs = $this->renderAs === 'blank' ? '' : $this->renderAs; |
|
| 150 | + |
|
| 151 | + $template = new \OCP\Template($this->appName, $this->templateName, $renderAs); |
|
| 152 | + |
|
| 153 | + foreach($this->params as $key => $value){ |
|
| 154 | + $template->assign($key, $value); |
|
| 155 | + } |
|
| 156 | + |
|
| 157 | + return $template->fetchPage($this->params); |
|
| 158 | + } |
|
| 159 | 159 | |
| 160 | 160 | } |
@@ -31,34 +31,34 @@ |
||
| 31 | 31 | */ |
| 32 | 32 | interface IMenuAction { |
| 33 | 33 | |
| 34 | - /** |
|
| 35 | - * @since 14.0.0 |
|
| 36 | - * @return string |
|
| 37 | - */ |
|
| 38 | - public function getId(): string; |
|
| 34 | + /** |
|
| 35 | + * @since 14.0.0 |
|
| 36 | + * @return string |
|
| 37 | + */ |
|
| 38 | + public function getId(): string; |
|
| 39 | 39 | |
| 40 | - /** |
|
| 41 | - * @since 14.0.0 |
|
| 42 | - * @return string |
|
| 43 | - */ |
|
| 44 | - public function getLabel(): string; |
|
| 40 | + /** |
|
| 41 | + * @since 14.0.0 |
|
| 42 | + * @return string |
|
| 43 | + */ |
|
| 44 | + public function getLabel(): string; |
|
| 45 | 45 | |
| 46 | - /** |
|
| 47 | - * @since 14.0.0 |
|
| 48 | - * @return string |
|
| 49 | - */ |
|
| 50 | - public function getLink(): string; |
|
| 46 | + /** |
|
| 47 | + * @since 14.0.0 |
|
| 48 | + * @return string |
|
| 49 | + */ |
|
| 50 | + public function getLink(): string; |
|
| 51 | 51 | |
| 52 | - /** |
|
| 53 | - * @since 14.0.0 |
|
| 54 | - * @return int |
|
| 55 | - */ |
|
| 56 | - public function getPriority(): int; |
|
| 52 | + /** |
|
| 53 | + * @since 14.0.0 |
|
| 54 | + * @return int |
|
| 55 | + */ |
|
| 56 | + public function getPriority(): int; |
|
| 57 | 57 | |
| 58 | - /** |
|
| 59 | - * @since 14.0.0 |
|
| 60 | - * @return string |
|
| 61 | - */ |
|
| 62 | - public function render(): string; |
|
| 58 | + /** |
|
| 59 | + * @since 14.0.0 |
|
| 60 | + * @return string |
|
| 61 | + */ |
|
| 62 | + public function render(): string; |
|
| 63 | 63 | |
| 64 | 64 | } |
| 65 | 65 | \ No newline at end of file |
@@ -68,7 +68,7 @@ discard block |
||
| 68 | 68 | public function getPrimaryAction(): IMenuAction { |
| 69 | 69 | $lowest = null; |
| 70 | 70 | foreach ($this->headerActions as $action) { |
| 71 | - if($lowest === null || $action->getPriority() < $lowest->getPriority()) { |
|
| 71 | + if ($lowest === null || $action->getPriority() < $lowest->getPriority()) { |
|
| 72 | 72 | $lowest = $action; |
| 73 | 73 | } |
| 74 | 74 | } |
@@ -86,7 +86,7 @@ discard block |
||
| 86 | 86 | $list = []; |
| 87 | 87 | $primary = $this->getPrimaryAction(); |
| 88 | 88 | foreach ($this->headerActions as $action) { |
| 89 | - if($primary !== $action) { |
|
| 89 | + if ($primary !== $action) { |
|
| 90 | 90 | $list[] = $action; |
| 91 | 91 | } |
| 92 | 92 | } |
@@ -33,123 +33,123 @@ |
||
| 33 | 33 | */ |
| 34 | 34 | class PublicTemplateResponse extends TemplateResponse { |
| 35 | 35 | |
| 36 | - private $headerTitle = ''; |
|
| 37 | - private $headerDetails = ''; |
|
| 38 | - private $headerActions = []; |
|
| 39 | - |
|
| 40 | - /** |
|
| 41 | - * PublicTemplateResponse constructor. |
|
| 42 | - * |
|
| 43 | - * @param string $appName |
|
| 44 | - * @param string $templateName |
|
| 45 | - * @param array $params |
|
| 46 | - * @since 14.0.0 |
|
| 47 | - */ |
|
| 48 | - public function __construct(string $appName, string $templateName, array $params = array()) { |
|
| 49 | - parent::__construct($appName, $templateName, $params, 'public'); |
|
| 50 | - \OC_Util::addScript('core', 'public/publicpage'); |
|
| 51 | - } |
|
| 52 | - |
|
| 53 | - /** |
|
| 54 | - * @param string $title |
|
| 55 | - * @since 14.0.0 |
|
| 56 | - */ |
|
| 57 | - public function setHeaderTitle(string $title) { |
|
| 58 | - $this->headerTitle = $title; |
|
| 59 | - } |
|
| 60 | - |
|
| 61 | - /** |
|
| 62 | - * @return string |
|
| 63 | - * @since 14.0.0 |
|
| 64 | - */ |
|
| 65 | - public function getHeaderTitle(): string { |
|
| 66 | - return $this->headerTitle; |
|
| 67 | - } |
|
| 68 | - |
|
| 69 | - /** |
|
| 70 | - * @param string $details |
|
| 71 | - * @since 14.0.0 |
|
| 72 | - */ |
|
| 73 | - public function setHeaderDetails(string $details) { |
|
| 74 | - $this->headerDetails = $details; |
|
| 75 | - } |
|
| 76 | - |
|
| 77 | - /** |
|
| 78 | - * @return string |
|
| 79 | - * @since 14.0.0 |
|
| 80 | - */ |
|
| 81 | - public function getHeaderDetails(): string { |
|
| 82 | - return $this->headerDetails; |
|
| 83 | - } |
|
| 84 | - |
|
| 85 | - /** |
|
| 86 | - * @param array $actions |
|
| 87 | - * @since 14.0.0 |
|
| 88 | - */ |
|
| 89 | - public function setHeaderActions(array $actions) { |
|
| 90 | - foreach ($actions as $action) { |
|
| 91 | - if ($actions instanceof IMenuAction) { |
|
| 92 | - throw new \InvalidArgumentException('Actions must be of type IMenuAction'); |
|
| 93 | - } |
|
| 94 | - $this->headerActions[] = $action; |
|
| 95 | - } |
|
| 96 | - } |
|
| 97 | - |
|
| 98 | - /** |
|
| 99 | - * @param IMenuAction $action |
|
| 100 | - * @since 14.0.0 |
|
| 101 | - */ |
|
| 102 | - public function addAction(IMenuAction $action) { |
|
| 103 | - $this->headerActions[] = $action; |
|
| 104 | - } |
|
| 105 | - |
|
| 106 | - /** |
|
| 107 | - * @return IMenuAction |
|
| 108 | - * @since 14.0.0 |
|
| 109 | - */ |
|
| 110 | - public function getPrimaryAction(): IMenuAction { |
|
| 111 | - $lowest = null; |
|
| 112 | - foreach ($this->headerActions as $action) { |
|
| 113 | - if($lowest === null || $action->getPriority() < $lowest->getPriority()) { |
|
| 114 | - $lowest = $action; |
|
| 115 | - } |
|
| 116 | - } |
|
| 117 | - return $lowest; |
|
| 118 | - } |
|
| 119 | - |
|
| 120 | - /** |
|
| 121 | - * @return int |
|
| 122 | - * @since 14.0.0 |
|
| 123 | - */ |
|
| 124 | - public function getActionCount(): int { |
|
| 125 | - return count($this->headerActions); |
|
| 126 | - } |
|
| 127 | - |
|
| 128 | - /** |
|
| 129 | - * @return IMenuAction[] |
|
| 130 | - * @since 14.0.0 |
|
| 131 | - */ |
|
| 132 | - public function getOtherActions(): array { |
|
| 133 | - $list = []; |
|
| 134 | - $primary = $this->getPrimaryAction(); |
|
| 135 | - foreach ($this->headerActions as $action) { |
|
| 136 | - if($primary !== $action) { |
|
| 137 | - $list[] = $action; |
|
| 138 | - } |
|
| 139 | - } |
|
| 140 | - return $list; |
|
| 141 | - } |
|
| 142 | - |
|
| 143 | - /** |
|
| 144 | - * @return string |
|
| 145 | - * @since 14.0.0 |
|
| 146 | - */ |
|
| 147 | - public function render() { |
|
| 148 | - $params = array_merge($this->getParams(), [ |
|
| 149 | - 'template' => $this, |
|
| 150 | - ]); |
|
| 151 | - $this->setParams($params); |
|
| 152 | - return parent::render(); |
|
| 153 | - } |
|
| 36 | + private $headerTitle = ''; |
|
| 37 | + private $headerDetails = ''; |
|
| 38 | + private $headerActions = []; |
|
| 39 | + |
|
| 40 | + /** |
|
| 41 | + * PublicTemplateResponse constructor. |
|
| 42 | + * |
|
| 43 | + * @param string $appName |
|
| 44 | + * @param string $templateName |
|
| 45 | + * @param array $params |
|
| 46 | + * @since 14.0.0 |
|
| 47 | + */ |
|
| 48 | + public function __construct(string $appName, string $templateName, array $params = array()) { |
|
| 49 | + parent::__construct($appName, $templateName, $params, 'public'); |
|
| 50 | + \OC_Util::addScript('core', 'public/publicpage'); |
|
| 51 | + } |
|
| 52 | + |
|
| 53 | + /** |
|
| 54 | + * @param string $title |
|
| 55 | + * @since 14.0.0 |
|
| 56 | + */ |
|
| 57 | + public function setHeaderTitle(string $title) { |
|
| 58 | + $this->headerTitle = $title; |
|
| 59 | + } |
|
| 60 | + |
|
| 61 | + /** |
|
| 62 | + * @return string |
|
| 63 | + * @since 14.0.0 |
|
| 64 | + */ |
|
| 65 | + public function getHeaderTitle(): string { |
|
| 66 | + return $this->headerTitle; |
|
| 67 | + } |
|
| 68 | + |
|
| 69 | + /** |
|
| 70 | + * @param string $details |
|
| 71 | + * @since 14.0.0 |
|
| 72 | + */ |
|
| 73 | + public function setHeaderDetails(string $details) { |
|
| 74 | + $this->headerDetails = $details; |
|
| 75 | + } |
|
| 76 | + |
|
| 77 | + /** |
|
| 78 | + * @return string |
|
| 79 | + * @since 14.0.0 |
|
| 80 | + */ |
|
| 81 | + public function getHeaderDetails(): string { |
|
| 82 | + return $this->headerDetails; |
|
| 83 | + } |
|
| 84 | + |
|
| 85 | + /** |
|
| 86 | + * @param array $actions |
|
| 87 | + * @since 14.0.0 |
|
| 88 | + */ |
|
| 89 | + public function setHeaderActions(array $actions) { |
|
| 90 | + foreach ($actions as $action) { |
|
| 91 | + if ($actions instanceof IMenuAction) { |
|
| 92 | + throw new \InvalidArgumentException('Actions must be of type IMenuAction'); |
|
| 93 | + } |
|
| 94 | + $this->headerActions[] = $action; |
|
| 95 | + } |
|
| 96 | + } |
|
| 97 | + |
|
| 98 | + /** |
|
| 99 | + * @param IMenuAction $action |
|
| 100 | + * @since 14.0.0 |
|
| 101 | + */ |
|
| 102 | + public function addAction(IMenuAction $action) { |
|
| 103 | + $this->headerActions[] = $action; |
|
| 104 | + } |
|
| 105 | + |
|
| 106 | + /** |
|
| 107 | + * @return IMenuAction |
|
| 108 | + * @since 14.0.0 |
|
| 109 | + */ |
|
| 110 | + public function getPrimaryAction(): IMenuAction { |
|
| 111 | + $lowest = null; |
|
| 112 | + foreach ($this->headerActions as $action) { |
|
| 113 | + if($lowest === null || $action->getPriority() < $lowest->getPriority()) { |
|
| 114 | + $lowest = $action; |
|
| 115 | + } |
|
| 116 | + } |
|
| 117 | + return $lowest; |
|
| 118 | + } |
|
| 119 | + |
|
| 120 | + /** |
|
| 121 | + * @return int |
|
| 122 | + * @since 14.0.0 |
|
| 123 | + */ |
|
| 124 | + public function getActionCount(): int { |
|
| 125 | + return count($this->headerActions); |
|
| 126 | + } |
|
| 127 | + |
|
| 128 | + /** |
|
| 129 | + * @return IMenuAction[] |
|
| 130 | + * @since 14.0.0 |
|
| 131 | + */ |
|
| 132 | + public function getOtherActions(): array { |
|
| 133 | + $list = []; |
|
| 134 | + $primary = $this->getPrimaryAction(); |
|
| 135 | + foreach ($this->headerActions as $action) { |
|
| 136 | + if($primary !== $action) { |
|
| 137 | + $list[] = $action; |
|
| 138 | + } |
|
| 139 | + } |
|
| 140 | + return $list; |
|
| 141 | + } |
|
| 142 | + |
|
| 143 | + /** |
|
| 144 | + * @return string |
|
| 145 | + * @since 14.0.0 |
|
| 146 | + */ |
|
| 147 | + public function render() { |
|
| 148 | + $params = array_merge($this->getParams(), [ |
|
| 149 | + 'template' => $this, |
|
| 150 | + ]); |
|
| 151 | + $this->setParams($params); |
|
| 152 | + return parent::render(); |
|
| 153 | + } |
|
| 154 | 154 | |
| 155 | 155 | } |
| 156 | 156 | \ No newline at end of file |
@@ -34,17 +34,23 @@ |
||
| 34 | 34 | <div id="preview"> |
| 35 | 35 | <?php if (isset($_['folder'])): ?> |
| 36 | 36 | <?php print_unescaped($_['folder']); ?> |
| 37 | - <?php else: ?> |
|
| 37 | + <?php else { |
|
| 38 | + : ?> |
|
| 38 | 39 | <?php if ($_['previewEnabled'] && substr($_['mimetype'], 0, strpos($_['mimetype'], '/')) == 'audio'): ?> |
| 39 | 40 | <div id="imgframe"> |
| 40 | - <audio tabindex="0" controls="" preload="none" style="width: 100%; max-width: <?php p($_['previewMaxX']); ?>px; max-height: <?php p($_['previewMaxY']); ?>px"> |
|
| 41 | + <audio tabindex="0" controls="" preload="none" style="width: 100%; max-width: <?php p($_['previewMaxX']); |
|
| 42 | +} |
|
| 43 | +?>px; max-height: <?php p($_['previewMaxY']); ?>px"> |
|
| 41 | 44 | <source src="<?php p($_['downloadURL']); ?>" type="<?php p($_['mimetype']); ?>" /> |
| 42 | 45 | </audio> |
| 43 | 46 | </div> |
| 44 | - <?php else: ?> |
|
| 47 | + <?php else { |
|
| 48 | + : ?> |
|
| 45 | 49 | <!-- Preview frame is filled via JS to support SVG images for modern browsers --> |
| 46 | 50 | <div id="imgframe"></div> |
| 47 | - <?php endif; ?> |
|
| 51 | + <?php endif; |
|
| 52 | +} |
|
| 53 | +?> |
|
| 48 | 54 | <?php if ($_['previewURL'] === $_['downloadURL']): ?> |
| 49 | 55 | <div class="directDownload"> |
| 50 | 56 | <a href="<?php p($_['downloadURL']); ?>" id="downloadFile" class="button"> |
@@ -40,15 +40,15 @@ |
||
| 40 | 40 | } |
| 41 | 41 | |
| 42 | 42 | public function render(): string { |
| 43 | - return '<li>' . |
|
| 44 | - '<a id="save" data-protected="false" data-owner-display-name="' . Util::sanitizeHTML($this->displayname) . '" data-owner="' . Util::sanitizeHTML($this->owner) . '" data-name="' . Util::sanitizeHTML($this->shareName) . '">' . |
|
| 45 | - '<span class="icon ' . Util::sanitizeHTML($this->getIcon()) . '"></span>' . |
|
| 46 | - '<span id="save-button">' . Util::sanitizeHTML($this->getLabel()) . '</span>' . |
|
| 47 | - '<form class="save-form hidden" action="#">' . |
|
| 48 | - '<input type="text" id="remote_address" placeholder="[email protected]">' . |
|
| 49 | - '<button id="save-button-confirm" class="icon-confirm svg" disabled=""></button>' . |
|
| 50 | - '</form>' . |
|
| 51 | - '</a>' . |
|
| 43 | + return '<li>'. |
|
| 44 | + '<a id="save" data-protected="false" data-owner-display-name="'.Util::sanitizeHTML($this->displayname).'" data-owner="'.Util::sanitizeHTML($this->owner).'" data-name="'.Util::sanitizeHTML($this->shareName).'">'. |
|
| 45 | + '<span class="icon '.Util::sanitizeHTML($this->getIcon()).'"></span>'. |
|
| 46 | + '<span id="save-button">'.Util::sanitizeHTML($this->getLabel()).'</span>'. |
|
| 47 | + '<form class="save-form hidden" action="#">'. |
|
| 48 | + '<input type="text" id="remote_address" placeholder="[email protected]">'. |
|
| 49 | + '<button id="save-button-confirm" class="icon-confirm svg" disabled=""></button>'. |
|
| 50 | + '</form>'. |
|
| 51 | + '</a>'. |
|
| 52 | 52 | '</li>'; |
| 53 | 53 | } |
| 54 | 54 | } |
| 55 | 55 | \ No newline at end of file |
@@ -28,41 +28,41 @@ |
||
| 28 | 28 | |
| 29 | 29 | class ExternalShareMenuAction extends SimpleMenuAction { |
| 30 | 30 | |
| 31 | - /** @var string */ |
|
| 32 | - private $owner; |
|
| 31 | + /** @var string */ |
|
| 32 | + private $owner; |
|
| 33 | 33 | |
| 34 | - /** @var string */ |
|
| 35 | - private $displayname; |
|
| 34 | + /** @var string */ |
|
| 35 | + private $displayname; |
|
| 36 | 36 | |
| 37 | - /** @var string */ |
|
| 38 | - private $shareName; |
|
| 37 | + /** @var string */ |
|
| 38 | + private $shareName; |
|
| 39 | 39 | |
| 40 | - /** |
|
| 41 | - * ExternalShareMenuAction constructor. |
|
| 42 | - * |
|
| 43 | - * @param string $label |
|
| 44 | - * @param string $icon |
|
| 45 | - * @param string $owner |
|
| 46 | - * @param string $displayname |
|
| 47 | - * @param string $shareName |
|
| 48 | - */ |
|
| 49 | - public function __construct(string $label, string $icon, string $owner, string $displayname, string $shareName) { |
|
| 50 | - parent::__construct('save', $label, $icon); |
|
| 51 | - $this->owner = $owner; |
|
| 52 | - $this->displayname = $displayname; |
|
| 53 | - $this->shareName = $shareName; |
|
| 54 | - } |
|
| 40 | + /** |
|
| 41 | + * ExternalShareMenuAction constructor. |
|
| 42 | + * |
|
| 43 | + * @param string $label |
|
| 44 | + * @param string $icon |
|
| 45 | + * @param string $owner |
|
| 46 | + * @param string $displayname |
|
| 47 | + * @param string $shareName |
|
| 48 | + */ |
|
| 49 | + public function __construct(string $label, string $icon, string $owner, string $displayname, string $shareName) { |
|
| 50 | + parent::__construct('save', $label, $icon); |
|
| 51 | + $this->owner = $owner; |
|
| 52 | + $this->displayname = $displayname; |
|
| 53 | + $this->shareName = $shareName; |
|
| 54 | + } |
|
| 55 | 55 | |
| 56 | - public function render(): string { |
|
| 57 | - return '<li>' . |
|
| 58 | - '<a id="save" data-protected="false" data-owner-display-name="' . Util::sanitizeHTML($this->displayname) . '" data-owner="' . Util::sanitizeHTML($this->owner) . '" data-name="' . Util::sanitizeHTML($this->shareName) . '">' . |
|
| 59 | - '<span class="icon ' . Util::sanitizeHTML($this->getIcon()) . '"></span>' . |
|
| 60 | - '<span id="save-button">' . Util::sanitizeHTML($this->getLabel()) . '</span>' . |
|
| 61 | - '<form class="save-form hidden" action="#">' . |
|
| 62 | - '<input type="text" id="remote_address" placeholder="[email protected]">' . |
|
| 63 | - '<button id="save-button-confirm" class="icon-confirm svg" disabled=""></button>' . |
|
| 64 | - '</form>' . |
|
| 65 | - '</a>' . |
|
| 66 | - '</li>'; |
|
| 67 | - } |
|
| 56 | + public function render(): string { |
|
| 57 | + return '<li>' . |
|
| 58 | + '<a id="save" data-protected="false" data-owner-display-name="' . Util::sanitizeHTML($this->displayname) . '" data-owner="' . Util::sanitizeHTML($this->owner) . '" data-name="' . Util::sanitizeHTML($this->shareName) . '">' . |
|
| 59 | + '<span class="icon ' . Util::sanitizeHTML($this->getIcon()) . '"></span>' . |
|
| 60 | + '<span id="save-button">' . Util::sanitizeHTML($this->getLabel()) . '</span>' . |
|
| 61 | + '<form class="save-form hidden" action="#">' . |
|
| 62 | + '<input type="text" id="remote_address" placeholder="[email protected]">' . |
|
| 63 | + '<button id="save-button-confirm" class="icon-confirm svg" disabled=""></button>' . |
|
| 64 | + '</form>' . |
|
| 65 | + '</a>' . |
|
| 66 | + '</li>'; |
|
| 67 | + } |
|
| 68 | 68 | } |
| 69 | 69 | \ No newline at end of file |
@@ -6,76 +6,76 @@ |
||
| 6 | 6 | |
| 7 | 7 | class ComposerStaticInitFiles_Sharing |
| 8 | 8 | { |
| 9 | - public static $prefixLengthsPsr4 = array ( |
|
| 9 | + public static $prefixLengthsPsr4 = array( |
|
| 10 | 10 | 'O' => |
| 11 | - array ( |
|
| 11 | + array( |
|
| 12 | 12 | 'OCA\\Files_Sharing\\' => 18, |
| 13 | 13 | ), |
| 14 | 14 | ); |
| 15 | 15 | |
| 16 | - public static $prefixDirsPsr4 = array ( |
|
| 16 | + public static $prefixDirsPsr4 = array( |
|
| 17 | 17 | 'OCA\\Files_Sharing\\' => |
| 18 | - array ( |
|
| 19 | - 0 => __DIR__ . '/..' . '/../lib', |
|
| 18 | + array( |
|
| 19 | + 0 => __DIR__.'/..'.'/../lib', |
|
| 20 | 20 | ), |
| 21 | 21 | ); |
| 22 | 22 | |
| 23 | - public static $classMap = array ( |
|
| 24 | - 'OCA\\Files_Sharing\\Activity\\Filter' => __DIR__ . '/..' . '/../lib/Activity/Filter.php', |
|
| 25 | - 'OCA\\Files_Sharing\\Activity\\Providers\\Base' => __DIR__ . '/..' . '/../lib/Activity/Providers/Base.php', |
|
| 26 | - 'OCA\\Files_Sharing\\Activity\\Providers\\Downloads' => __DIR__ . '/..' . '/../lib/Activity/Providers/Downloads.php', |
|
| 27 | - 'OCA\\Files_Sharing\\Activity\\Providers\\Groups' => __DIR__ . '/..' . '/../lib/Activity/Providers/Groups.php', |
|
| 28 | - 'OCA\\Files_Sharing\\Activity\\Providers\\PublicLinks' => __DIR__ . '/..' . '/../lib/Activity/Providers/PublicLinks.php', |
|
| 29 | - 'OCA\\Files_Sharing\\Activity\\Providers\\RemoteShares' => __DIR__ . '/..' . '/../lib/Activity/Providers/RemoteShares.php', |
|
| 30 | - 'OCA\\Files_Sharing\\Activity\\Providers\\Users' => __DIR__ . '/..' . '/../lib/Activity/Providers/Users.php', |
|
| 31 | - 'OCA\\Files_Sharing\\Activity\\Settings\\PublicLinks' => __DIR__ . '/..' . '/../lib/Activity/Settings/PublicLinks.php', |
|
| 32 | - 'OCA\\Files_Sharing\\Activity\\Settings\\RemoteShare' => __DIR__ . '/..' . '/../lib/Activity/Settings/RemoteShare.php', |
|
| 33 | - 'OCA\\Files_Sharing\\Activity\\Settings\\Shared' => __DIR__ . '/..' . '/../lib/Activity/Settings/Shared.php', |
|
| 34 | - 'OCA\\Files_Sharing\\AppInfo\\Application' => __DIR__ . '/..' . '/../lib/AppInfo/Application.php', |
|
| 35 | - 'OCA\\Files_Sharing\\Cache' => __DIR__ . '/..' . '/../lib/Cache.php', |
|
| 36 | - 'OCA\\Files_Sharing\\Capabilities' => __DIR__ . '/..' . '/../lib/Capabilities.php', |
|
| 37 | - 'OCA\\Files_Sharing\\Collaboration\\ShareRecipientSorter' => __DIR__ . '/..' . '/../lib/Collaboration/ShareRecipientSorter.php', |
|
| 38 | - 'OCA\\Files_Sharing\\Command\\CleanupRemoteStorages' => __DIR__ . '/..' . '/../lib/Command/CleanupRemoteStorages.php', |
|
| 39 | - 'OCA\\Files_Sharing\\Controller\\ExternalSharesController' => __DIR__ . '/..' . '/../lib/Controller/ExternalSharesController.php', |
|
| 40 | - 'OCA\\Files_Sharing\\Controller\\PublicPreviewController' => __DIR__ . '/..' . '/../lib/Controller/PublicPreviewController.php', |
|
| 41 | - 'OCA\\Files_Sharing\\Controller\\RemoteController' => __DIR__ . '/..' . '/../lib/Controller/RemoteController.php', |
|
| 42 | - 'OCA\\Files_Sharing\\Controller\\ShareAPIController' => __DIR__ . '/..' . '/../lib/Controller/ShareAPIController.php', |
|
| 43 | - 'OCA\\Files_Sharing\\Controller\\ShareController' => __DIR__ . '/..' . '/../lib/Controller/ShareController.php', |
|
| 44 | - 'OCA\\Files_Sharing\\Controller\\ShareInfoController' => __DIR__ . '/..' . '/../lib/Controller/ShareInfoController.php', |
|
| 45 | - 'OCA\\Files_Sharing\\Controller\\ShareesAPIController' => __DIR__ . '/..' . '/../lib/Controller/ShareesAPIController.php', |
|
| 46 | - 'OCA\\Files_Sharing\\DeleteOrphanedSharesJob' => __DIR__ . '/..' . '/../lib/DeleteOrphanedSharesJob.php', |
|
| 47 | - 'OCA\\Files_Sharing\\Exceptions\\BrokenPath' => __DIR__ . '/..' . '/../lib/Exceptions/BrokenPath.php', |
|
| 48 | - 'OCA\\Files_Sharing\\Exceptions\\S2SException' => __DIR__ . '/..' . '/../lib/Exceptions/S2SException.php', |
|
| 49 | - 'OCA\\Files_Sharing\\ExpireSharesJob' => __DIR__ . '/..' . '/../lib/ExpireSharesJob.php', |
|
| 50 | - 'OCA\\Files_Sharing\\External\\Cache' => __DIR__ . '/..' . '/../lib/External/Cache.php', |
|
| 51 | - 'OCA\\Files_Sharing\\External\\Manager' => __DIR__ . '/..' . '/../lib/External/Manager.php', |
|
| 52 | - 'OCA\\Files_Sharing\\External\\Mount' => __DIR__ . '/..' . '/../lib/External/Mount.php', |
|
| 53 | - 'OCA\\Files_Sharing\\External\\MountProvider' => __DIR__ . '/..' . '/../lib/External/MountProvider.php', |
|
| 54 | - 'OCA\\Files_Sharing\\External\\Scanner' => __DIR__ . '/..' . '/../lib/External/Scanner.php', |
|
| 55 | - 'OCA\\Files_Sharing\\External\\Storage' => __DIR__ . '/..' . '/../lib/External/Storage.php', |
|
| 56 | - 'OCA\\Files_Sharing\\External\\Watcher' => __DIR__ . '/..' . '/../lib/External/Watcher.php', |
|
| 57 | - 'OCA\\Files_Sharing\\Helper' => __DIR__ . '/..' . '/../lib/Helper.php', |
|
| 58 | - 'OCA\\Files_Sharing\\Hooks' => __DIR__ . '/..' . '/../lib/Hooks.php', |
|
| 59 | - 'OCA\\Files_Sharing\\ISharedStorage' => __DIR__ . '/..' . '/../lib/ISharedStorage.php', |
|
| 60 | - 'OCA\\Files_Sharing\\Middleware\\OCSShareAPIMiddleware' => __DIR__ . '/..' . '/../lib/Middleware/OCSShareAPIMiddleware.php', |
|
| 61 | - 'OCA\\Files_Sharing\\Middleware\\ShareInfoMiddleware' => __DIR__ . '/..' . '/../lib/Middleware/ShareInfoMiddleware.php', |
|
| 62 | - 'OCA\\Files_Sharing\\Middleware\\SharingCheckMiddleware' => __DIR__ . '/..' . '/../lib/Middleware/SharingCheckMiddleware.php', |
|
| 63 | - 'OCA\\Files_Sharing\\Migration\\OwncloudGuestShareType' => __DIR__ . '/..' . '/../lib/Migration/OwncloudGuestShareType.php', |
|
| 64 | - 'OCA\\Files_Sharing\\Migration\\SetPasswordColumn' => __DIR__ . '/..' . '/../lib/Migration/SetPasswordColumn.php', |
|
| 65 | - 'OCA\\Files_Sharing\\MountProvider' => __DIR__ . '/..' . '/../lib/MountProvider.php', |
|
| 66 | - 'OCA\\Files_Sharing\\Scanner' => __DIR__ . '/..' . '/../lib/Scanner.php', |
|
| 67 | - 'OCA\\Files_Sharing\\ShareBackend\\File' => __DIR__ . '/..' . '/../lib/ShareBackend/File.php', |
|
| 68 | - 'OCA\\Files_Sharing\\ShareBackend\\Folder' => __DIR__ . '/..' . '/../lib/ShareBackend/Folder.php', |
|
| 69 | - 'OCA\\Files_Sharing\\SharedMount' => __DIR__ . '/..' . '/../lib/SharedMount.php', |
|
| 70 | - 'OCA\\Files_Sharing\\SharedStorage' => __DIR__ . '/..' . '/../lib/SharedStorage.php', |
|
| 71 | - 'OCA\\Files_Sharing\\Template\\ExternalShareMenuAction' => __DIR__ . '/..' . '/../lib/Template/ExternalShareMenuAction.php', |
|
| 72 | - 'OCA\\Files_Sharing\\Template\\LinkMenuAction' => __DIR__ . '/..' . '/../lib/Template/LinkMenuAction.php', |
|
| 73 | - 'OCA\\Files_Sharing\\Updater' => __DIR__ . '/..' . '/../lib/Updater.php', |
|
| 23 | + public static $classMap = array( |
|
| 24 | + 'OCA\\Files_Sharing\\Activity\\Filter' => __DIR__.'/..'.'/../lib/Activity/Filter.php', |
|
| 25 | + 'OCA\\Files_Sharing\\Activity\\Providers\\Base' => __DIR__.'/..'.'/../lib/Activity/Providers/Base.php', |
|
| 26 | + 'OCA\\Files_Sharing\\Activity\\Providers\\Downloads' => __DIR__.'/..'.'/../lib/Activity/Providers/Downloads.php', |
|
| 27 | + 'OCA\\Files_Sharing\\Activity\\Providers\\Groups' => __DIR__.'/..'.'/../lib/Activity/Providers/Groups.php', |
|
| 28 | + 'OCA\\Files_Sharing\\Activity\\Providers\\PublicLinks' => __DIR__.'/..'.'/../lib/Activity/Providers/PublicLinks.php', |
|
| 29 | + 'OCA\\Files_Sharing\\Activity\\Providers\\RemoteShares' => __DIR__.'/..'.'/../lib/Activity/Providers/RemoteShares.php', |
|
| 30 | + 'OCA\\Files_Sharing\\Activity\\Providers\\Users' => __DIR__.'/..'.'/../lib/Activity/Providers/Users.php', |
|
| 31 | + 'OCA\\Files_Sharing\\Activity\\Settings\\PublicLinks' => __DIR__.'/..'.'/../lib/Activity/Settings/PublicLinks.php', |
|
| 32 | + 'OCA\\Files_Sharing\\Activity\\Settings\\RemoteShare' => __DIR__.'/..'.'/../lib/Activity/Settings/RemoteShare.php', |
|
| 33 | + 'OCA\\Files_Sharing\\Activity\\Settings\\Shared' => __DIR__.'/..'.'/../lib/Activity/Settings/Shared.php', |
|
| 34 | + 'OCA\\Files_Sharing\\AppInfo\\Application' => __DIR__.'/..'.'/../lib/AppInfo/Application.php', |
|
| 35 | + 'OCA\\Files_Sharing\\Cache' => __DIR__.'/..'.'/../lib/Cache.php', |
|
| 36 | + 'OCA\\Files_Sharing\\Capabilities' => __DIR__.'/..'.'/../lib/Capabilities.php', |
|
| 37 | + 'OCA\\Files_Sharing\\Collaboration\\ShareRecipientSorter' => __DIR__.'/..'.'/../lib/Collaboration/ShareRecipientSorter.php', |
|
| 38 | + 'OCA\\Files_Sharing\\Command\\CleanupRemoteStorages' => __DIR__.'/..'.'/../lib/Command/CleanupRemoteStorages.php', |
|
| 39 | + 'OCA\\Files_Sharing\\Controller\\ExternalSharesController' => __DIR__.'/..'.'/../lib/Controller/ExternalSharesController.php', |
|
| 40 | + 'OCA\\Files_Sharing\\Controller\\PublicPreviewController' => __DIR__.'/..'.'/../lib/Controller/PublicPreviewController.php', |
|
| 41 | + 'OCA\\Files_Sharing\\Controller\\RemoteController' => __DIR__.'/..'.'/../lib/Controller/RemoteController.php', |
|
| 42 | + 'OCA\\Files_Sharing\\Controller\\ShareAPIController' => __DIR__.'/..'.'/../lib/Controller/ShareAPIController.php', |
|
| 43 | + 'OCA\\Files_Sharing\\Controller\\ShareController' => __DIR__.'/..'.'/../lib/Controller/ShareController.php', |
|
| 44 | + 'OCA\\Files_Sharing\\Controller\\ShareInfoController' => __DIR__.'/..'.'/../lib/Controller/ShareInfoController.php', |
|
| 45 | + 'OCA\\Files_Sharing\\Controller\\ShareesAPIController' => __DIR__.'/..'.'/../lib/Controller/ShareesAPIController.php', |
|
| 46 | + 'OCA\\Files_Sharing\\DeleteOrphanedSharesJob' => __DIR__.'/..'.'/../lib/DeleteOrphanedSharesJob.php', |
|
| 47 | + 'OCA\\Files_Sharing\\Exceptions\\BrokenPath' => __DIR__.'/..'.'/../lib/Exceptions/BrokenPath.php', |
|
| 48 | + 'OCA\\Files_Sharing\\Exceptions\\S2SException' => __DIR__.'/..'.'/../lib/Exceptions/S2SException.php', |
|
| 49 | + 'OCA\\Files_Sharing\\ExpireSharesJob' => __DIR__.'/..'.'/../lib/ExpireSharesJob.php', |
|
| 50 | + 'OCA\\Files_Sharing\\External\\Cache' => __DIR__.'/..'.'/../lib/External/Cache.php', |
|
| 51 | + 'OCA\\Files_Sharing\\External\\Manager' => __DIR__.'/..'.'/../lib/External/Manager.php', |
|
| 52 | + 'OCA\\Files_Sharing\\External\\Mount' => __DIR__.'/..'.'/../lib/External/Mount.php', |
|
| 53 | + 'OCA\\Files_Sharing\\External\\MountProvider' => __DIR__.'/..'.'/../lib/External/MountProvider.php', |
|
| 54 | + 'OCA\\Files_Sharing\\External\\Scanner' => __DIR__.'/..'.'/../lib/External/Scanner.php', |
|
| 55 | + 'OCA\\Files_Sharing\\External\\Storage' => __DIR__.'/..'.'/../lib/External/Storage.php', |
|
| 56 | + 'OCA\\Files_Sharing\\External\\Watcher' => __DIR__.'/..'.'/../lib/External/Watcher.php', |
|
| 57 | + 'OCA\\Files_Sharing\\Helper' => __DIR__.'/..'.'/../lib/Helper.php', |
|
| 58 | + 'OCA\\Files_Sharing\\Hooks' => __DIR__.'/..'.'/../lib/Hooks.php', |
|
| 59 | + 'OCA\\Files_Sharing\\ISharedStorage' => __DIR__.'/..'.'/../lib/ISharedStorage.php', |
|
| 60 | + 'OCA\\Files_Sharing\\Middleware\\OCSShareAPIMiddleware' => __DIR__.'/..'.'/../lib/Middleware/OCSShareAPIMiddleware.php', |
|
| 61 | + 'OCA\\Files_Sharing\\Middleware\\ShareInfoMiddleware' => __DIR__.'/..'.'/../lib/Middleware/ShareInfoMiddleware.php', |
|
| 62 | + 'OCA\\Files_Sharing\\Middleware\\SharingCheckMiddleware' => __DIR__.'/..'.'/../lib/Middleware/SharingCheckMiddleware.php', |
|
| 63 | + 'OCA\\Files_Sharing\\Migration\\OwncloudGuestShareType' => __DIR__.'/..'.'/../lib/Migration/OwncloudGuestShareType.php', |
|
| 64 | + 'OCA\\Files_Sharing\\Migration\\SetPasswordColumn' => __DIR__.'/..'.'/../lib/Migration/SetPasswordColumn.php', |
|
| 65 | + 'OCA\\Files_Sharing\\MountProvider' => __DIR__.'/..'.'/../lib/MountProvider.php', |
|
| 66 | + 'OCA\\Files_Sharing\\Scanner' => __DIR__.'/..'.'/../lib/Scanner.php', |
|
| 67 | + 'OCA\\Files_Sharing\\ShareBackend\\File' => __DIR__.'/..'.'/../lib/ShareBackend/File.php', |
|
| 68 | + 'OCA\\Files_Sharing\\ShareBackend\\Folder' => __DIR__.'/..'.'/../lib/ShareBackend/Folder.php', |
|
| 69 | + 'OCA\\Files_Sharing\\SharedMount' => __DIR__.'/..'.'/../lib/SharedMount.php', |
|
| 70 | + 'OCA\\Files_Sharing\\SharedStorage' => __DIR__.'/..'.'/../lib/SharedStorage.php', |
|
| 71 | + 'OCA\\Files_Sharing\\Template\\ExternalShareMenuAction' => __DIR__.'/..'.'/../lib/Template/ExternalShareMenuAction.php', |
|
| 72 | + 'OCA\\Files_Sharing\\Template\\LinkMenuAction' => __DIR__.'/..'.'/../lib/Template/LinkMenuAction.php', |
|
| 73 | + 'OCA\\Files_Sharing\\Updater' => __DIR__.'/..'.'/../lib/Updater.php', |
|
| 74 | 74 | ); |
| 75 | 75 | |
| 76 | 76 | public static function getInitializer(ClassLoader $loader) |
| 77 | 77 | { |
| 78 | - return \Closure::bind(function () use ($loader) { |
|
| 78 | + return \Closure::bind(function() use ($loader) { |
|
| 79 | 79 | $loader->prefixLengthsPsr4 = ComposerStaticInitFiles_Sharing::$prefixLengthsPsr4; |
| 80 | 80 | $loader->prefixDirsPsr4 = ComposerStaticInitFiles_Sharing::$prefixDirsPsr4; |
| 81 | 81 | $loader->classMap = ComposerStaticInitFiles_Sharing::$classMap; |
@@ -6,54 +6,54 @@ |
||
| 6 | 6 | $baseDir = $vendorDir; |
| 7 | 7 | |
| 8 | 8 | return array( |
| 9 | - 'OCA\\Files_Sharing\\Activity\\Filter' => $baseDir . '/../lib/Activity/Filter.php', |
|
| 10 | - 'OCA\\Files_Sharing\\Activity\\Providers\\Base' => $baseDir . '/../lib/Activity/Providers/Base.php', |
|
| 11 | - 'OCA\\Files_Sharing\\Activity\\Providers\\Downloads' => $baseDir . '/../lib/Activity/Providers/Downloads.php', |
|
| 12 | - 'OCA\\Files_Sharing\\Activity\\Providers\\Groups' => $baseDir . '/../lib/Activity/Providers/Groups.php', |
|
| 13 | - 'OCA\\Files_Sharing\\Activity\\Providers\\PublicLinks' => $baseDir . '/../lib/Activity/Providers/PublicLinks.php', |
|
| 14 | - 'OCA\\Files_Sharing\\Activity\\Providers\\RemoteShares' => $baseDir . '/../lib/Activity/Providers/RemoteShares.php', |
|
| 15 | - 'OCA\\Files_Sharing\\Activity\\Providers\\Users' => $baseDir . '/../lib/Activity/Providers/Users.php', |
|
| 16 | - 'OCA\\Files_Sharing\\Activity\\Settings\\PublicLinks' => $baseDir . '/../lib/Activity/Settings/PublicLinks.php', |
|
| 17 | - 'OCA\\Files_Sharing\\Activity\\Settings\\RemoteShare' => $baseDir . '/../lib/Activity/Settings/RemoteShare.php', |
|
| 18 | - 'OCA\\Files_Sharing\\Activity\\Settings\\Shared' => $baseDir . '/../lib/Activity/Settings/Shared.php', |
|
| 19 | - 'OCA\\Files_Sharing\\AppInfo\\Application' => $baseDir . '/../lib/AppInfo/Application.php', |
|
| 20 | - 'OCA\\Files_Sharing\\Cache' => $baseDir . '/../lib/Cache.php', |
|
| 21 | - 'OCA\\Files_Sharing\\Capabilities' => $baseDir . '/../lib/Capabilities.php', |
|
| 22 | - 'OCA\\Files_Sharing\\Collaboration\\ShareRecipientSorter' => $baseDir . '/../lib/Collaboration/ShareRecipientSorter.php', |
|
| 23 | - 'OCA\\Files_Sharing\\Command\\CleanupRemoteStorages' => $baseDir . '/../lib/Command/CleanupRemoteStorages.php', |
|
| 24 | - 'OCA\\Files_Sharing\\Controller\\ExternalSharesController' => $baseDir . '/../lib/Controller/ExternalSharesController.php', |
|
| 25 | - 'OCA\\Files_Sharing\\Controller\\PublicPreviewController' => $baseDir . '/../lib/Controller/PublicPreviewController.php', |
|
| 26 | - 'OCA\\Files_Sharing\\Controller\\RemoteController' => $baseDir . '/../lib/Controller/RemoteController.php', |
|
| 27 | - 'OCA\\Files_Sharing\\Controller\\ShareAPIController' => $baseDir . '/../lib/Controller/ShareAPIController.php', |
|
| 28 | - 'OCA\\Files_Sharing\\Controller\\ShareController' => $baseDir . '/../lib/Controller/ShareController.php', |
|
| 29 | - 'OCA\\Files_Sharing\\Controller\\ShareInfoController' => $baseDir . '/../lib/Controller/ShareInfoController.php', |
|
| 30 | - 'OCA\\Files_Sharing\\Controller\\ShareesAPIController' => $baseDir . '/../lib/Controller/ShareesAPIController.php', |
|
| 31 | - 'OCA\\Files_Sharing\\DeleteOrphanedSharesJob' => $baseDir . '/../lib/DeleteOrphanedSharesJob.php', |
|
| 32 | - 'OCA\\Files_Sharing\\Exceptions\\BrokenPath' => $baseDir . '/../lib/Exceptions/BrokenPath.php', |
|
| 33 | - 'OCA\\Files_Sharing\\Exceptions\\S2SException' => $baseDir . '/../lib/Exceptions/S2SException.php', |
|
| 34 | - 'OCA\\Files_Sharing\\ExpireSharesJob' => $baseDir . '/../lib/ExpireSharesJob.php', |
|
| 35 | - 'OCA\\Files_Sharing\\External\\Cache' => $baseDir . '/../lib/External/Cache.php', |
|
| 36 | - 'OCA\\Files_Sharing\\External\\Manager' => $baseDir . '/../lib/External/Manager.php', |
|
| 37 | - 'OCA\\Files_Sharing\\External\\Mount' => $baseDir . '/../lib/External/Mount.php', |
|
| 38 | - 'OCA\\Files_Sharing\\External\\MountProvider' => $baseDir . '/../lib/External/MountProvider.php', |
|
| 39 | - 'OCA\\Files_Sharing\\External\\Scanner' => $baseDir . '/../lib/External/Scanner.php', |
|
| 40 | - 'OCA\\Files_Sharing\\External\\Storage' => $baseDir . '/../lib/External/Storage.php', |
|
| 41 | - 'OCA\\Files_Sharing\\External\\Watcher' => $baseDir . '/../lib/External/Watcher.php', |
|
| 42 | - 'OCA\\Files_Sharing\\Helper' => $baseDir . '/../lib/Helper.php', |
|
| 43 | - 'OCA\\Files_Sharing\\Hooks' => $baseDir . '/../lib/Hooks.php', |
|
| 44 | - 'OCA\\Files_Sharing\\ISharedStorage' => $baseDir . '/../lib/ISharedStorage.php', |
|
| 45 | - 'OCA\\Files_Sharing\\Middleware\\OCSShareAPIMiddleware' => $baseDir . '/../lib/Middleware/OCSShareAPIMiddleware.php', |
|
| 46 | - 'OCA\\Files_Sharing\\Middleware\\ShareInfoMiddleware' => $baseDir . '/../lib/Middleware/ShareInfoMiddleware.php', |
|
| 47 | - 'OCA\\Files_Sharing\\Middleware\\SharingCheckMiddleware' => $baseDir . '/../lib/Middleware/SharingCheckMiddleware.php', |
|
| 48 | - 'OCA\\Files_Sharing\\Migration\\OwncloudGuestShareType' => $baseDir . '/../lib/Migration/OwncloudGuestShareType.php', |
|
| 49 | - 'OCA\\Files_Sharing\\Migration\\SetPasswordColumn' => $baseDir . '/../lib/Migration/SetPasswordColumn.php', |
|
| 50 | - 'OCA\\Files_Sharing\\MountProvider' => $baseDir . '/../lib/MountProvider.php', |
|
| 51 | - 'OCA\\Files_Sharing\\Scanner' => $baseDir . '/../lib/Scanner.php', |
|
| 52 | - 'OCA\\Files_Sharing\\ShareBackend\\File' => $baseDir . '/../lib/ShareBackend/File.php', |
|
| 53 | - 'OCA\\Files_Sharing\\ShareBackend\\Folder' => $baseDir . '/../lib/ShareBackend/Folder.php', |
|
| 54 | - 'OCA\\Files_Sharing\\SharedMount' => $baseDir . '/../lib/SharedMount.php', |
|
| 55 | - 'OCA\\Files_Sharing\\SharedStorage' => $baseDir . '/../lib/SharedStorage.php', |
|
| 56 | - 'OCA\\Files_Sharing\\Template\\ExternalShareMenuAction' => $baseDir . '/../lib/Template/ExternalShareMenuAction.php', |
|
| 57 | - 'OCA\\Files_Sharing\\Template\\LinkMenuAction' => $baseDir . '/../lib/Template/LinkMenuAction.php', |
|
| 58 | - 'OCA\\Files_Sharing\\Updater' => $baseDir . '/../lib/Updater.php', |
|
| 9 | + 'OCA\\Files_Sharing\\Activity\\Filter' => $baseDir.'/../lib/Activity/Filter.php', |
|
| 10 | + 'OCA\\Files_Sharing\\Activity\\Providers\\Base' => $baseDir.'/../lib/Activity/Providers/Base.php', |
|
| 11 | + 'OCA\\Files_Sharing\\Activity\\Providers\\Downloads' => $baseDir.'/../lib/Activity/Providers/Downloads.php', |
|
| 12 | + 'OCA\\Files_Sharing\\Activity\\Providers\\Groups' => $baseDir.'/../lib/Activity/Providers/Groups.php', |
|
| 13 | + 'OCA\\Files_Sharing\\Activity\\Providers\\PublicLinks' => $baseDir.'/../lib/Activity/Providers/PublicLinks.php', |
|
| 14 | + 'OCA\\Files_Sharing\\Activity\\Providers\\RemoteShares' => $baseDir.'/../lib/Activity/Providers/RemoteShares.php', |
|
| 15 | + 'OCA\\Files_Sharing\\Activity\\Providers\\Users' => $baseDir.'/../lib/Activity/Providers/Users.php', |
|
| 16 | + 'OCA\\Files_Sharing\\Activity\\Settings\\PublicLinks' => $baseDir.'/../lib/Activity/Settings/PublicLinks.php', |
|
| 17 | + 'OCA\\Files_Sharing\\Activity\\Settings\\RemoteShare' => $baseDir.'/../lib/Activity/Settings/RemoteShare.php', |
|
| 18 | + 'OCA\\Files_Sharing\\Activity\\Settings\\Shared' => $baseDir.'/../lib/Activity/Settings/Shared.php', |
|
| 19 | + 'OCA\\Files_Sharing\\AppInfo\\Application' => $baseDir.'/../lib/AppInfo/Application.php', |
|
| 20 | + 'OCA\\Files_Sharing\\Cache' => $baseDir.'/../lib/Cache.php', |
|
| 21 | + 'OCA\\Files_Sharing\\Capabilities' => $baseDir.'/../lib/Capabilities.php', |
|
| 22 | + 'OCA\\Files_Sharing\\Collaboration\\ShareRecipientSorter' => $baseDir.'/../lib/Collaboration/ShareRecipientSorter.php', |
|
| 23 | + 'OCA\\Files_Sharing\\Command\\CleanupRemoteStorages' => $baseDir.'/../lib/Command/CleanupRemoteStorages.php', |
|
| 24 | + 'OCA\\Files_Sharing\\Controller\\ExternalSharesController' => $baseDir.'/../lib/Controller/ExternalSharesController.php', |
|
| 25 | + 'OCA\\Files_Sharing\\Controller\\PublicPreviewController' => $baseDir.'/../lib/Controller/PublicPreviewController.php', |
|
| 26 | + 'OCA\\Files_Sharing\\Controller\\RemoteController' => $baseDir.'/../lib/Controller/RemoteController.php', |
|
| 27 | + 'OCA\\Files_Sharing\\Controller\\ShareAPIController' => $baseDir.'/../lib/Controller/ShareAPIController.php', |
|
| 28 | + 'OCA\\Files_Sharing\\Controller\\ShareController' => $baseDir.'/../lib/Controller/ShareController.php', |
|
| 29 | + 'OCA\\Files_Sharing\\Controller\\ShareInfoController' => $baseDir.'/../lib/Controller/ShareInfoController.php', |
|
| 30 | + 'OCA\\Files_Sharing\\Controller\\ShareesAPIController' => $baseDir.'/../lib/Controller/ShareesAPIController.php', |
|
| 31 | + 'OCA\\Files_Sharing\\DeleteOrphanedSharesJob' => $baseDir.'/../lib/DeleteOrphanedSharesJob.php', |
|
| 32 | + 'OCA\\Files_Sharing\\Exceptions\\BrokenPath' => $baseDir.'/../lib/Exceptions/BrokenPath.php', |
|
| 33 | + 'OCA\\Files_Sharing\\Exceptions\\S2SException' => $baseDir.'/../lib/Exceptions/S2SException.php', |
|
| 34 | + 'OCA\\Files_Sharing\\ExpireSharesJob' => $baseDir.'/../lib/ExpireSharesJob.php', |
|
| 35 | + 'OCA\\Files_Sharing\\External\\Cache' => $baseDir.'/../lib/External/Cache.php', |
|
| 36 | + 'OCA\\Files_Sharing\\External\\Manager' => $baseDir.'/../lib/External/Manager.php', |
|
| 37 | + 'OCA\\Files_Sharing\\External\\Mount' => $baseDir.'/../lib/External/Mount.php', |
|
| 38 | + 'OCA\\Files_Sharing\\External\\MountProvider' => $baseDir.'/../lib/External/MountProvider.php', |
|
| 39 | + 'OCA\\Files_Sharing\\External\\Scanner' => $baseDir.'/../lib/External/Scanner.php', |
|
| 40 | + 'OCA\\Files_Sharing\\External\\Storage' => $baseDir.'/../lib/External/Storage.php', |
|
| 41 | + 'OCA\\Files_Sharing\\External\\Watcher' => $baseDir.'/../lib/External/Watcher.php', |
|
| 42 | + 'OCA\\Files_Sharing\\Helper' => $baseDir.'/../lib/Helper.php', |
|
| 43 | + 'OCA\\Files_Sharing\\Hooks' => $baseDir.'/../lib/Hooks.php', |
|
| 44 | + 'OCA\\Files_Sharing\\ISharedStorage' => $baseDir.'/../lib/ISharedStorage.php', |
|
| 45 | + 'OCA\\Files_Sharing\\Middleware\\OCSShareAPIMiddleware' => $baseDir.'/../lib/Middleware/OCSShareAPIMiddleware.php', |
|
| 46 | + 'OCA\\Files_Sharing\\Middleware\\ShareInfoMiddleware' => $baseDir.'/../lib/Middleware/ShareInfoMiddleware.php', |
|
| 47 | + 'OCA\\Files_Sharing\\Middleware\\SharingCheckMiddleware' => $baseDir.'/../lib/Middleware/SharingCheckMiddleware.php', |
|
| 48 | + 'OCA\\Files_Sharing\\Migration\\OwncloudGuestShareType' => $baseDir.'/../lib/Migration/OwncloudGuestShareType.php', |
|
| 49 | + 'OCA\\Files_Sharing\\Migration\\SetPasswordColumn' => $baseDir.'/../lib/Migration/SetPasswordColumn.php', |
|
| 50 | + 'OCA\\Files_Sharing\\MountProvider' => $baseDir.'/../lib/MountProvider.php', |
|
| 51 | + 'OCA\\Files_Sharing\\Scanner' => $baseDir.'/../lib/Scanner.php', |
|
| 52 | + 'OCA\\Files_Sharing\\ShareBackend\\File' => $baseDir.'/../lib/ShareBackend/File.php', |
|
| 53 | + 'OCA\\Files_Sharing\\ShareBackend\\Folder' => $baseDir.'/../lib/ShareBackend/Folder.php', |
|
| 54 | + 'OCA\\Files_Sharing\\SharedMount' => $baseDir.'/../lib/SharedMount.php', |
|
| 55 | + 'OCA\\Files_Sharing\\SharedStorage' => $baseDir.'/../lib/SharedStorage.php', |
|
| 56 | + 'OCA\\Files_Sharing\\Template\\ExternalShareMenuAction' => $baseDir.'/../lib/Template/ExternalShareMenuAction.php', |
|
| 57 | + 'OCA\\Files_Sharing\\Template\\LinkMenuAction' => $baseDir.'/../lib/Template/LinkMenuAction.php', |
|
| 58 | + 'OCA\\Files_Sharing\\Updater' => $baseDir.'/../lib/Updater.php', |
|
| 59 | 59 | ); |
@@ -4,9 +4,9 @@ discard block |
||
| 4 | 4 | <meta charset="utf-8"> |
| 5 | 5 | <title> |
| 6 | 6 | <?php |
| 7 | - p(!empty($_['application'])?$_['application'].' - ':''); |
|
| 8 | - p($theme->getTitle()); |
|
| 9 | - ?> |
|
| 7 | + p(!empty($_['application'])?$_['application'].' - ':''); |
|
| 8 | + p($theme->getTitle()); |
|
| 9 | + ?> |
|
| 10 | 10 | </title> |
| 11 | 11 | <meta http-equiv="X-UA-Compatible" content="IE=edge"> |
| 12 | 12 | <meta name="referrer" content="never"> |
@@ -42,11 +42,11 @@ discard block |
||
| 42 | 42 | </div> |
| 43 | 43 | |
| 44 | 44 | <?php |
| 45 | - /** @var \OCP\AppFramework\Http\Template\PublicTemplateResponse $template */ |
|
| 46 | - if($template->getActionCount() !== 0) { |
|
| 47 | - $primary = $template->getPrimaryAction(); |
|
| 48 | - $others = $template->getOtherActions(); |
|
| 49 | - ?> |
|
| 45 | + /** @var \OCP\AppFramework\Http\Template\PublicTemplateResponse $template */ |
|
| 46 | + if($template->getActionCount() !== 0) { |
|
| 47 | + $primary = $template->getPrimaryAction(); |
|
| 48 | + $others = $template->getOtherActions(); |
|
| 49 | + ?> |
|
| 50 | 50 | <div class="header-right"> |
| 51 | 51 | <span id="header-primary-action" class="<?php if($template->getActionCount() === 1) { p($primary->getIcon()); } ?>"> |
| 52 | 52 | <a href="<?php p($primary->getLink()); ?>"> |
@@ -58,11 +58,11 @@ discard block |
||
| 58 | 58 | <div id="share-menu" class="popovermenu menu"> |
| 59 | 59 | <ul> |
| 60 | 60 | <?php |
| 61 | - /** @var \OCP\AppFramework\Http\Template\IMenuAction $action */ |
|
| 62 | - foreach($template->getOtherActions() as $action) { |
|
| 63 | - print_unescaped($action->render()); |
|
| 64 | - } |
|
| 65 | - ?> |
|
| 61 | + /** @var \OCP\AppFramework\Http\Template\IMenuAction $action */ |
|
| 62 | + foreach($template->getOtherActions() as $action) { |
|
| 63 | + print_unescaped($action->render()); |
|
| 64 | + } |
|
| 65 | + ?> |
|
| 66 | 66 | </ul> |
| 67 | 67 | </div> |
| 68 | 68 | <?php } ?> |
@@ -4,7 +4,7 @@ discard block |
||
| 4 | 4 | <meta charset="utf-8"> |
| 5 | 5 | <title> |
| 6 | 6 | <?php |
| 7 | - p(!empty($_['application'])?$_['application'].' - ':''); |
|
| 7 | + p(!empty($_['application']) ? $_['application'].' - ' : ''); |
|
| 8 | 8 | p($theme->getTitle()); |
| 9 | 9 | ?> |
| 10 | 10 | </title> |
@@ -14,7 +14,7 @@ discard block |
||
| 14 | 14 | <meta name="apple-itunes-app" content="app-id=<?php p($theme->getiTunesAppId()); ?>"> |
| 15 | 15 | <meta name="apple-mobile-web-app-capable" content="yes"> |
| 16 | 16 | <meta name="apple-mobile-web-app-status-bar-style" content="black"> |
| 17 | - <meta name="apple-mobile-web-app-title" content="<?php p((!empty($_['application']) && $_['appid']!='files')? $_['application']:$theme->getTitle()); ?>"> |
|
| 17 | + <meta name="apple-mobile-web-app-title" content="<?php p((!empty($_['application']) && $_['appid'] != 'files') ? $_['application'] : $theme->getTitle()); ?>"> |
|
| 18 | 18 | <meta name="mobile-web-app-capable" content="yes"> |
| 19 | 19 | <meta name="theme-color" content="<?php p($theme->getColorPrimary()); ?>"> |
| 20 | 20 | <link rel="icon" href="<?php print_unescaped(image_path($_['appid'], 'favicon.ico')); /* IE11+ supports png */ ?>"> |
@@ -25,7 +25,7 @@ discard block |
||
| 25 | 25 | <?php emit_script_loading_tags($_); ?> |
| 26 | 26 | <?php print_unescaped($_['headers']); ?> |
| 27 | 27 | </head> |
| 28 | -<body id="<?php p($_['bodyid']);?>"> |
|
| 28 | +<body id="<?php p($_['bodyid']); ?>"> |
|
| 29 | 29 | <?php include('layout.noscript.warning.php'); ?> |
| 30 | 30 | <header> |
| 31 | 31 | <div id="header" class="<?php p($_['header-classes']); ?>"> |
@@ -43,23 +43,23 @@ discard block |
||
| 43 | 43 | |
| 44 | 44 | <?php |
| 45 | 45 | /** @var \OCP\AppFramework\Http\Template\PublicTemplateResponse $template */ |
| 46 | - if($template->getActionCount() !== 0) { |
|
| 46 | + if ($template->getActionCount() !== 0) { |
|
| 47 | 47 | $primary = $template->getPrimaryAction(); |
| 48 | 48 | $others = $template->getOtherActions(); |
| 49 | 49 | ?> |
| 50 | 50 | <div class="header-right"> |
| 51 | - <span id="header-primary-action" class="<?php if($template->getActionCount() === 1) { p($primary->getIcon()); } ?>"> |
|
| 51 | + <span id="header-primary-action" class="<?php if ($template->getActionCount() === 1) { p($primary->getIcon()); } ?>"> |
|
| 52 | 52 | <a href="<?php p($primary->getLink()); ?>"> |
| 53 | 53 | <span class="share-menutoggle-text"><?php p($primary->getLabel()) ?></span> |
| 54 | 54 | </a> |
| 55 | 55 | </span> |
| 56 | - <?php if($template->getActionCount()>1) { ?> |
|
| 56 | + <?php if ($template->getActionCount() > 1) { ?> |
|
| 57 | 57 | <span class="menutoggle icon-more-white"></span> |
| 58 | 58 | <div id="share-menu" class="popovermenu menu"> |
| 59 | 59 | <ul> |
| 60 | 60 | <?php |
| 61 | 61 | /** @var \OCP\AppFramework\Http\Template\IMenuAction $action */ |
| 62 | - foreach($template->getOtherActions() as $action) { |
|
| 62 | + foreach ($template->getOtherActions() as $action) { |
|
| 63 | 63 | print_unescaped($action->render()); |
| 64 | 64 | } |
| 65 | 65 | ?> |