@@ -28,72 +28,72 @@ |
||
| 28 | 28 | |
| 29 | 29 | class FileChanges implements IFilter { |
| 30 | 30 | |
| 31 | - /** @var IL10N */ |
|
| 32 | - protected $l; |
|
| 31 | + /** @var IL10N */ |
|
| 32 | + protected $l; |
|
| 33 | 33 | |
| 34 | - /** @var IURLGenerator */ |
|
| 35 | - protected $url; |
|
| 34 | + /** @var IURLGenerator */ |
|
| 35 | + protected $url; |
|
| 36 | 36 | |
| 37 | - /** |
|
| 38 | - * @param IL10N $l |
|
| 39 | - * @param IURLGenerator $url |
|
| 40 | - */ |
|
| 41 | - public function __construct(IL10N $l, IURLGenerator $url) { |
|
| 42 | - $this->l = $l; |
|
| 43 | - $this->url = $url; |
|
| 44 | - } |
|
| 37 | + /** |
|
| 38 | + * @param IL10N $l |
|
| 39 | + * @param IURLGenerator $url |
|
| 40 | + */ |
|
| 41 | + public function __construct(IL10N $l, IURLGenerator $url) { |
|
| 42 | + $this->l = $l; |
|
| 43 | + $this->url = $url; |
|
| 44 | + } |
|
| 45 | 45 | |
| 46 | - /** |
|
| 47 | - * @return string Lowercase a-z only identifier |
|
| 48 | - * @since 11.0.0 |
|
| 49 | - */ |
|
| 50 | - public function getIdentifier() { |
|
| 51 | - return 'files'; |
|
| 52 | - } |
|
| 46 | + /** |
|
| 47 | + * @return string Lowercase a-z only identifier |
|
| 48 | + * @since 11.0.0 |
|
| 49 | + */ |
|
| 50 | + public function getIdentifier() { |
|
| 51 | + return 'files'; |
|
| 52 | + } |
|
| 53 | 53 | |
| 54 | - /** |
|
| 55 | - * @return string A translated string |
|
| 56 | - * @since 11.0.0 |
|
| 57 | - */ |
|
| 58 | - public function getName() { |
|
| 59 | - return $this->l->t('File changes'); |
|
| 60 | - } |
|
| 54 | + /** |
|
| 55 | + * @return string A translated string |
|
| 56 | + * @since 11.0.0 |
|
| 57 | + */ |
|
| 58 | + public function getName() { |
|
| 59 | + return $this->l->t('File changes'); |
|
| 60 | + } |
|
| 61 | 61 | |
| 62 | - /** |
|
| 63 | - * @return int |
|
| 64 | - * @since 11.0.0 |
|
| 65 | - */ |
|
| 66 | - public function getPriority() { |
|
| 67 | - return 30; |
|
| 68 | - } |
|
| 62 | + /** |
|
| 63 | + * @return int |
|
| 64 | + * @since 11.0.0 |
|
| 65 | + */ |
|
| 66 | + public function getPriority() { |
|
| 67 | + return 30; |
|
| 68 | + } |
|
| 69 | 69 | |
| 70 | - /** |
|
| 71 | - * @return string Full URL to an icon, empty string when none is given |
|
| 72 | - * @since 11.0.0 |
|
| 73 | - */ |
|
| 74 | - public function getIcon() { |
|
| 75 | - return $this->url->getAbsoluteURL($this->url->imagePath('core', 'places/files-dark.svg')); |
|
| 76 | - } |
|
| 70 | + /** |
|
| 71 | + * @return string Full URL to an icon, empty string when none is given |
|
| 72 | + * @since 11.0.0 |
|
| 73 | + */ |
|
| 74 | + public function getIcon() { |
|
| 75 | + return $this->url->getAbsoluteURL($this->url->imagePath('core', 'places/files-dark.svg')); |
|
| 76 | + } |
|
| 77 | 77 | |
| 78 | - /** |
|
| 79 | - * @param string[] $types |
|
| 80 | - * @return string[] An array of allowed apps from which activities should be displayed |
|
| 81 | - * @since 11.0.0 |
|
| 82 | - */ |
|
| 83 | - public function filterTypes(array $types) { |
|
| 84 | - return array_intersect([ |
|
| 85 | - 'file_created', |
|
| 86 | - 'file_changed', |
|
| 87 | - 'file_deleted', |
|
| 88 | - 'file_restored', |
|
| 89 | - ], $types); |
|
| 90 | - } |
|
| 78 | + /** |
|
| 79 | + * @param string[] $types |
|
| 80 | + * @return string[] An array of allowed apps from which activities should be displayed |
|
| 81 | + * @since 11.0.0 |
|
| 82 | + */ |
|
| 83 | + public function filterTypes(array $types) { |
|
| 84 | + return array_intersect([ |
|
| 85 | + 'file_created', |
|
| 86 | + 'file_changed', |
|
| 87 | + 'file_deleted', |
|
| 88 | + 'file_restored', |
|
| 89 | + ], $types); |
|
| 90 | + } |
|
| 91 | 91 | |
| 92 | - /** |
|
| 93 | - * @return string[] An array of allowed apps from which activities should be displayed |
|
| 94 | - * @since 11.0.0 |
|
| 95 | - */ |
|
| 96 | - public function allowedApps() { |
|
| 97 | - return ['files']; |
|
| 98 | - } |
|
| 92 | + /** |
|
| 93 | + * @return string[] An array of allowed apps from which activities should be displayed |
|
| 94 | + * @since 11.0.0 |
|
| 95 | + */ |
|
| 96 | + public function allowedApps() { |
|
| 97 | + return ['files']; |
|
| 98 | + } |
|
| 99 | 99 | } |
@@ -27,72 +27,72 @@ |
||
| 27 | 27 | |
| 28 | 28 | class FileChanged implements ISetting { |
| 29 | 29 | |
| 30 | - /** @var IL10N */ |
|
| 31 | - protected $l; |
|
| 30 | + /** @var IL10N */ |
|
| 31 | + protected $l; |
|
| 32 | 32 | |
| 33 | - /** |
|
| 34 | - * @param IL10N $l |
|
| 35 | - */ |
|
| 36 | - public function __construct(IL10N $l) { |
|
| 37 | - $this->l = $l; |
|
| 38 | - } |
|
| 33 | + /** |
|
| 34 | + * @param IL10N $l |
|
| 35 | + */ |
|
| 36 | + public function __construct(IL10N $l) { |
|
| 37 | + $this->l = $l; |
|
| 38 | + } |
|
| 39 | 39 | |
| 40 | - /** |
|
| 41 | - * @return string Lowercase a-z and underscore only identifier |
|
| 42 | - * @since 11.0.0 |
|
| 43 | - */ |
|
| 44 | - public function getIdentifier() { |
|
| 45 | - return 'file_changed'; |
|
| 46 | - } |
|
| 40 | + /** |
|
| 41 | + * @return string Lowercase a-z and underscore only identifier |
|
| 42 | + * @since 11.0.0 |
|
| 43 | + */ |
|
| 44 | + public function getIdentifier() { |
|
| 45 | + return 'file_changed'; |
|
| 46 | + } |
|
| 47 | 47 | |
| 48 | - /** |
|
| 49 | - * @return string A translated string |
|
| 50 | - * @since 11.0.0 |
|
| 51 | - */ |
|
| 52 | - public function getName() { |
|
| 53 | - return $this->l->t('A file or folder has been <strong>changed</strong> or <strong>renamed</strong>'); |
|
| 54 | - } |
|
| 48 | + /** |
|
| 49 | + * @return string A translated string |
|
| 50 | + * @since 11.0.0 |
|
| 51 | + */ |
|
| 52 | + public function getName() { |
|
| 53 | + return $this->l->t('A file or folder has been <strong>changed</strong> or <strong>renamed</strong>'); |
|
| 54 | + } |
|
| 55 | 55 | |
| 56 | - /** |
|
| 57 | - * @return int whether the filter should be rather on the top or bottom of |
|
| 58 | - * the admin section. The filters are arranged in ascending order of the |
|
| 59 | - * priority values. It is required to return a value between 0 and 100. |
|
| 60 | - * @since 11.0.0 |
|
| 61 | - */ |
|
| 62 | - public function getPriority() { |
|
| 63 | - return 1; |
|
| 64 | - } |
|
| 56 | + /** |
|
| 57 | + * @return int whether the filter should be rather on the top or bottom of |
|
| 58 | + * the admin section. The filters are arranged in ascending order of the |
|
| 59 | + * priority values. It is required to return a value between 0 and 100. |
|
| 60 | + * @since 11.0.0 |
|
| 61 | + */ |
|
| 62 | + public function getPriority() { |
|
| 63 | + return 1; |
|
| 64 | + } |
|
| 65 | 65 | |
| 66 | - /** |
|
| 67 | - * @return bool True when the option can be changed for the stream |
|
| 68 | - * @since 11.0.0 |
|
| 69 | - */ |
|
| 70 | - public function canChangeStream() { |
|
| 71 | - return true; |
|
| 72 | - } |
|
| 66 | + /** |
|
| 67 | + * @return bool True when the option can be changed for the stream |
|
| 68 | + * @since 11.0.0 |
|
| 69 | + */ |
|
| 70 | + public function canChangeStream() { |
|
| 71 | + return true; |
|
| 72 | + } |
|
| 73 | 73 | |
| 74 | - /** |
|
| 75 | - * @return bool True when the option can be changed for the stream |
|
| 76 | - * @since 11.0.0 |
|
| 77 | - */ |
|
| 78 | - public function isDefaultEnabledStream() { |
|
| 79 | - return true; |
|
| 80 | - } |
|
| 74 | + /** |
|
| 75 | + * @return bool True when the option can be changed for the stream |
|
| 76 | + * @since 11.0.0 |
|
| 77 | + */ |
|
| 78 | + public function isDefaultEnabledStream() { |
|
| 79 | + return true; |
|
| 80 | + } |
|
| 81 | 81 | |
| 82 | - /** |
|
| 83 | - * @return bool True when the option can be changed for the mail |
|
| 84 | - * @since 11.0.0 |
|
| 85 | - */ |
|
| 86 | - public function canChangeMail() { |
|
| 87 | - return true; |
|
| 88 | - } |
|
| 82 | + /** |
|
| 83 | + * @return bool True when the option can be changed for the mail |
|
| 84 | + * @since 11.0.0 |
|
| 85 | + */ |
|
| 86 | + public function canChangeMail() { |
|
| 87 | + return true; |
|
| 88 | + } |
|
| 89 | 89 | |
| 90 | - /** |
|
| 91 | - * @return bool True when the option can be changed for the stream |
|
| 92 | - * @since 11.0.0 |
|
| 93 | - */ |
|
| 94 | - public function isDefaultEnabledMail() { |
|
| 95 | - return false; |
|
| 96 | - } |
|
| 90 | + /** |
|
| 91 | + * @return bool True when the option can be changed for the stream |
|
| 92 | + * @since 11.0.0 |
|
| 93 | + */ |
|
| 94 | + public function isDefaultEnabledMail() { |
|
| 95 | + return false; |
|
| 96 | + } |
|
| 97 | 97 | } |
| 98 | 98 | |
@@ -27,72 +27,72 @@ |
||
| 27 | 27 | |
| 28 | 28 | class FileCreated implements ISetting { |
| 29 | 29 | |
| 30 | - /** @var IL10N */ |
|
| 31 | - protected $l; |
|
| 30 | + /** @var IL10N */ |
|
| 31 | + protected $l; |
|
| 32 | 32 | |
| 33 | - /** |
|
| 34 | - * @param IL10N $l |
|
| 35 | - */ |
|
| 36 | - public function __construct(IL10N $l) { |
|
| 37 | - $this->l = $l; |
|
| 38 | - } |
|
| 33 | + /** |
|
| 34 | + * @param IL10N $l |
|
| 35 | + */ |
|
| 36 | + public function __construct(IL10N $l) { |
|
| 37 | + $this->l = $l; |
|
| 38 | + } |
|
| 39 | 39 | |
| 40 | - /** |
|
| 41 | - * @return string Lowercase a-z and underscore only identifier |
|
| 42 | - * @since 11.0.0 |
|
| 43 | - */ |
|
| 44 | - public function getIdentifier() { |
|
| 45 | - return 'file_created'; |
|
| 46 | - } |
|
| 40 | + /** |
|
| 41 | + * @return string Lowercase a-z and underscore only identifier |
|
| 42 | + * @since 11.0.0 |
|
| 43 | + */ |
|
| 44 | + public function getIdentifier() { |
|
| 45 | + return 'file_created'; |
|
| 46 | + } |
|
| 47 | 47 | |
| 48 | - /** |
|
| 49 | - * @return string A translated string |
|
| 50 | - * @since 11.0.0 |
|
| 51 | - */ |
|
| 52 | - public function getName() { |
|
| 53 | - return $this->l->t('A new file or folder has been <strong>created</strong>'); |
|
| 54 | - } |
|
| 48 | + /** |
|
| 49 | + * @return string A translated string |
|
| 50 | + * @since 11.0.0 |
|
| 51 | + */ |
|
| 52 | + public function getName() { |
|
| 53 | + return $this->l->t('A new file or folder has been <strong>created</strong>'); |
|
| 54 | + } |
|
| 55 | 55 | |
| 56 | - /** |
|
| 57 | - * @return int whether the filter should be rather on the top or bottom of |
|
| 58 | - * the admin section. The filters are arranged in ascending order of the |
|
| 59 | - * priority values. It is required to return a value between 0 and 100. |
|
| 60 | - * @since 11.0.0 |
|
| 61 | - */ |
|
| 62 | - public function getPriority() { |
|
| 63 | - return 0; |
|
| 64 | - } |
|
| 56 | + /** |
|
| 57 | + * @return int whether the filter should be rather on the top or bottom of |
|
| 58 | + * the admin section. The filters are arranged in ascending order of the |
|
| 59 | + * priority values. It is required to return a value between 0 and 100. |
|
| 60 | + * @since 11.0.0 |
|
| 61 | + */ |
|
| 62 | + public function getPriority() { |
|
| 63 | + return 0; |
|
| 64 | + } |
|
| 65 | 65 | |
| 66 | - /** |
|
| 67 | - * @return bool True when the option can be changed for the stream |
|
| 68 | - * @since 11.0.0 |
|
| 69 | - */ |
|
| 70 | - public function canChangeStream() { |
|
| 71 | - return true; |
|
| 72 | - } |
|
| 66 | + /** |
|
| 67 | + * @return bool True when the option can be changed for the stream |
|
| 68 | + * @since 11.0.0 |
|
| 69 | + */ |
|
| 70 | + public function canChangeStream() { |
|
| 71 | + return true; |
|
| 72 | + } |
|
| 73 | 73 | |
| 74 | - /** |
|
| 75 | - * @return bool True when the option can be changed for the stream |
|
| 76 | - * @since 11.0.0 |
|
| 77 | - */ |
|
| 78 | - public function isDefaultEnabledStream() { |
|
| 79 | - return true; |
|
| 80 | - } |
|
| 74 | + /** |
|
| 75 | + * @return bool True when the option can be changed for the stream |
|
| 76 | + * @since 11.0.0 |
|
| 77 | + */ |
|
| 78 | + public function isDefaultEnabledStream() { |
|
| 79 | + return true; |
|
| 80 | + } |
|
| 81 | 81 | |
| 82 | - /** |
|
| 83 | - * @return bool True when the option can be changed for the mail |
|
| 84 | - * @since 11.0.0 |
|
| 85 | - */ |
|
| 86 | - public function canChangeMail() { |
|
| 87 | - return true; |
|
| 88 | - } |
|
| 82 | + /** |
|
| 83 | + * @return bool True when the option can be changed for the mail |
|
| 84 | + * @since 11.0.0 |
|
| 85 | + */ |
|
| 86 | + public function canChangeMail() { |
|
| 87 | + return true; |
|
| 88 | + } |
|
| 89 | 89 | |
| 90 | - /** |
|
| 91 | - * @return bool True when the option can be changed for the stream |
|
| 92 | - * @since 11.0.0 |
|
| 93 | - */ |
|
| 94 | - public function isDefaultEnabledMail() { |
|
| 95 | - return false; |
|
| 96 | - } |
|
| 90 | + /** |
|
| 91 | + * @return bool True when the option can be changed for the stream |
|
| 92 | + * @since 11.0.0 |
|
| 93 | + */ |
|
| 94 | + public function isDefaultEnabledMail() { |
|
| 95 | + return false; |
|
| 96 | + } |
|
| 97 | 97 | } |
| 98 | 98 | |
@@ -27,72 +27,72 @@ |
||
| 27 | 27 | |
| 28 | 28 | class FavoriteAction implements ISetting { |
| 29 | 29 | |
| 30 | - /** @var IL10N */ |
|
| 31 | - protected $l; |
|
| 30 | + /** @var IL10N */ |
|
| 31 | + protected $l; |
|
| 32 | 32 | |
| 33 | - /** |
|
| 34 | - * @param IL10N $l |
|
| 35 | - */ |
|
| 36 | - public function __construct(IL10N $l) { |
|
| 37 | - $this->l = $l; |
|
| 38 | - } |
|
| 33 | + /** |
|
| 34 | + * @param IL10N $l |
|
| 35 | + */ |
|
| 36 | + public function __construct(IL10N $l) { |
|
| 37 | + $this->l = $l; |
|
| 38 | + } |
|
| 39 | 39 | |
| 40 | - /** |
|
| 41 | - * @return string Lowercase a-z and underscore only identifier |
|
| 42 | - * @since 11.0.0 |
|
| 43 | - */ |
|
| 44 | - public function getIdentifier() { |
|
| 45 | - return 'favorite'; |
|
| 46 | - } |
|
| 40 | + /** |
|
| 41 | + * @return string Lowercase a-z and underscore only identifier |
|
| 42 | + * @since 11.0.0 |
|
| 43 | + */ |
|
| 44 | + public function getIdentifier() { |
|
| 45 | + return 'favorite'; |
|
| 46 | + } |
|
| 47 | 47 | |
| 48 | - /** |
|
| 49 | - * @return string A translated string |
|
| 50 | - * @since 11.0.0 |
|
| 51 | - */ |
|
| 52 | - public function getName() { |
|
| 53 | - return $this->l->t('A file has been added to or removed from your <strong>favorites</strong>'); |
|
| 54 | - } |
|
| 48 | + /** |
|
| 49 | + * @return string A translated string |
|
| 50 | + * @since 11.0.0 |
|
| 51 | + */ |
|
| 52 | + public function getName() { |
|
| 53 | + return $this->l->t('A file has been added to or removed from your <strong>favorites</strong>'); |
|
| 54 | + } |
|
| 55 | 55 | |
| 56 | - /** |
|
| 57 | - * @return int whether the filter should be rather on the top or bottom of |
|
| 58 | - * the admin section. The filters are arranged in ascending order of the |
|
| 59 | - * priority values. It is required to return a value between 0 and 100. |
|
| 60 | - * @since 11.0.0 |
|
| 61 | - */ |
|
| 62 | - public function getPriority() { |
|
| 63 | - return 5; |
|
| 64 | - } |
|
| 56 | + /** |
|
| 57 | + * @return int whether the filter should be rather on the top or bottom of |
|
| 58 | + * the admin section. The filters are arranged in ascending order of the |
|
| 59 | + * priority values. It is required to return a value between 0 and 100. |
|
| 60 | + * @since 11.0.0 |
|
| 61 | + */ |
|
| 62 | + public function getPriority() { |
|
| 63 | + return 5; |
|
| 64 | + } |
|
| 65 | 65 | |
| 66 | - /** |
|
| 67 | - * @return bool True when the option can be changed for the stream |
|
| 68 | - * @since 11.0.0 |
|
| 69 | - */ |
|
| 70 | - public function canChangeStream() { |
|
| 71 | - return true; |
|
| 72 | - } |
|
| 66 | + /** |
|
| 67 | + * @return bool True when the option can be changed for the stream |
|
| 68 | + * @since 11.0.0 |
|
| 69 | + */ |
|
| 70 | + public function canChangeStream() { |
|
| 71 | + return true; |
|
| 72 | + } |
|
| 73 | 73 | |
| 74 | - /** |
|
| 75 | - * @return bool True when the option can be changed for the stream |
|
| 76 | - * @since 11.0.0 |
|
| 77 | - */ |
|
| 78 | - public function isDefaultEnabledStream() { |
|
| 79 | - return true; |
|
| 80 | - } |
|
| 74 | + /** |
|
| 75 | + * @return bool True when the option can be changed for the stream |
|
| 76 | + * @since 11.0.0 |
|
| 77 | + */ |
|
| 78 | + public function isDefaultEnabledStream() { |
|
| 79 | + return true; |
|
| 80 | + } |
|
| 81 | 81 | |
| 82 | - /** |
|
| 83 | - * @return bool True when the option can be changed for the mail |
|
| 84 | - * @since 11.0.0 |
|
| 85 | - */ |
|
| 86 | - public function canChangeMail() { |
|
| 87 | - return true; |
|
| 88 | - } |
|
| 82 | + /** |
|
| 83 | + * @return bool True when the option can be changed for the mail |
|
| 84 | + * @since 11.0.0 |
|
| 85 | + */ |
|
| 86 | + public function canChangeMail() { |
|
| 87 | + return true; |
|
| 88 | + } |
|
| 89 | 89 | |
| 90 | - /** |
|
| 91 | - * @return bool True when the option can be changed for the stream |
|
| 92 | - * @since 11.0.0 |
|
| 93 | - */ |
|
| 94 | - public function isDefaultEnabledMail() { |
|
| 95 | - return false; |
|
| 96 | - } |
|
| 90 | + /** |
|
| 91 | + * @return bool True when the option can be changed for the stream |
|
| 92 | + * @since 11.0.0 |
|
| 93 | + */ |
|
| 94 | + public function isDefaultEnabledMail() { |
|
| 95 | + return false; |
|
| 96 | + } |
|
| 97 | 97 | } |
| 98 | 98 | |
@@ -27,72 +27,72 @@ |
||
| 27 | 27 | |
| 28 | 28 | class FileFavorite implements ISetting { |
| 29 | 29 | |
| 30 | - /** @var IL10N */ |
|
| 31 | - protected $l; |
|
| 30 | + /** @var IL10N */ |
|
| 31 | + protected $l; |
|
| 32 | 32 | |
| 33 | - /** |
|
| 34 | - * @param IL10N $l |
|
| 35 | - */ |
|
| 36 | - public function __construct(IL10N $l) { |
|
| 37 | - $this->l = $l; |
|
| 38 | - } |
|
| 33 | + /** |
|
| 34 | + * @param IL10N $l |
|
| 35 | + */ |
|
| 36 | + public function __construct(IL10N $l) { |
|
| 37 | + $this->l = $l; |
|
| 38 | + } |
|
| 39 | 39 | |
| 40 | - /** |
|
| 41 | - * @return string Lowercase a-z and underscore only identifier |
|
| 42 | - * @since 11.0.0 |
|
| 43 | - */ |
|
| 44 | - public function getIdentifier() { |
|
| 45 | - return 'file_favorite'; |
|
| 46 | - } |
|
| 40 | + /** |
|
| 41 | + * @return string Lowercase a-z and underscore only identifier |
|
| 42 | + * @since 11.0.0 |
|
| 43 | + */ |
|
| 44 | + public function getIdentifier() { |
|
| 45 | + return 'file_favorite'; |
|
| 46 | + } |
|
| 47 | 47 | |
| 48 | - /** |
|
| 49 | - * @return string A translated string |
|
| 50 | - * @since 11.0.0 |
|
| 51 | - */ |
|
| 52 | - public function getName() { |
|
| 53 | - return $this->l->t('Limit notifications about creation and changes to your <strong>favorite files</strong> <em>(Stream only)</em>'); |
|
| 54 | - } |
|
| 48 | + /** |
|
| 49 | + * @return string A translated string |
|
| 50 | + * @since 11.0.0 |
|
| 51 | + */ |
|
| 52 | + public function getName() { |
|
| 53 | + return $this->l->t('Limit notifications about creation and changes to your <strong>favorite files</strong> <em>(Stream only)</em>'); |
|
| 54 | + } |
|
| 55 | 55 | |
| 56 | - /** |
|
| 57 | - * @return int whether the filter should be rather on the top or bottom of |
|
| 58 | - * the admin section. The filters are arranged in ascending order of the |
|
| 59 | - * priority values. It is required to return a value between 0 and 100. |
|
| 60 | - * @since 11.0.0 |
|
| 61 | - */ |
|
| 62 | - public function getPriority() { |
|
| 63 | - return 2; |
|
| 64 | - } |
|
| 56 | + /** |
|
| 57 | + * @return int whether the filter should be rather on the top or bottom of |
|
| 58 | + * the admin section. The filters are arranged in ascending order of the |
|
| 59 | + * priority values. It is required to return a value between 0 and 100. |
|
| 60 | + * @since 11.0.0 |
|
| 61 | + */ |
|
| 62 | + public function getPriority() { |
|
| 63 | + return 2; |
|
| 64 | + } |
|
| 65 | 65 | |
| 66 | - /** |
|
| 67 | - * @return bool True when the option can be changed for the stream |
|
| 68 | - * @since 11.0.0 |
|
| 69 | - */ |
|
| 70 | - public function canChangeStream() { |
|
| 71 | - return true; |
|
| 72 | - } |
|
| 66 | + /** |
|
| 67 | + * @return bool True when the option can be changed for the stream |
|
| 68 | + * @since 11.0.0 |
|
| 69 | + */ |
|
| 70 | + public function canChangeStream() { |
|
| 71 | + return true; |
|
| 72 | + } |
|
| 73 | 73 | |
| 74 | - /** |
|
| 75 | - * @return bool True when the option can be changed for the stream |
|
| 76 | - * @since 11.0.0 |
|
| 77 | - */ |
|
| 78 | - public function isDefaultEnabledStream() { |
|
| 79 | - return false; |
|
| 80 | - } |
|
| 74 | + /** |
|
| 75 | + * @return bool True when the option can be changed for the stream |
|
| 76 | + * @since 11.0.0 |
|
| 77 | + */ |
|
| 78 | + public function isDefaultEnabledStream() { |
|
| 79 | + return false; |
|
| 80 | + } |
|
| 81 | 81 | |
| 82 | - /** |
|
| 83 | - * @return bool True when the option can be changed for the mail |
|
| 84 | - * @since 11.0.0 |
|
| 85 | - */ |
|
| 86 | - public function canChangeMail() { |
|
| 87 | - return false; |
|
| 88 | - } |
|
| 82 | + /** |
|
| 83 | + * @return bool True when the option can be changed for the mail |
|
| 84 | + * @since 11.0.0 |
|
| 85 | + */ |
|
| 86 | + public function canChangeMail() { |
|
| 87 | + return false; |
|
| 88 | + } |
|
| 89 | 89 | |
| 90 | - /** |
|
| 91 | - * @return bool True when the option can be changed for the stream |
|
| 92 | - * @since 11.0.0 |
|
| 93 | - */ |
|
| 94 | - public function isDefaultEnabledMail() { |
|
| 95 | - return false; |
|
| 96 | - } |
|
| 90 | + /** |
|
| 91 | + * @return bool True when the option can be changed for the stream |
|
| 92 | + * @since 11.0.0 |
|
| 93 | + */ |
|
| 94 | + public function isDefaultEnabledMail() { |
|
| 95 | + return false; |
|
| 96 | + } |
|
| 97 | 97 | } |
| 98 | 98 | |
@@ -29,23 +29,23 @@ |
||
| 29 | 29 | use OCP\Util; |
| 30 | 30 | |
| 31 | 31 | class SettingsController extends Controller { |
| 32 | - public function __construct($appName, IRequest $request) { |
|
| 33 | - parent::__construct($appName, $request); |
|
| 34 | - } |
|
| 32 | + public function __construct($appName, IRequest $request) { |
|
| 33 | + parent::__construct($appName, $request); |
|
| 34 | + } |
|
| 35 | 35 | |
| 36 | - /** |
|
| 37 | - * @param string $maxUploadSize |
|
| 38 | - * @return JSONResponse |
|
| 39 | - */ |
|
| 40 | - public function setMaxUploadSize($maxUploadSize) { |
|
| 41 | - $setMaxSize = \OC_Files::setUploadLimit(Util::computerFileSize($maxUploadSize)); |
|
| 36 | + /** |
|
| 37 | + * @param string $maxUploadSize |
|
| 38 | + * @return JSONResponse |
|
| 39 | + */ |
|
| 40 | + public function setMaxUploadSize($maxUploadSize) { |
|
| 41 | + $setMaxSize = \OC_Files::setUploadLimit(Util::computerFileSize($maxUploadSize)); |
|
| 42 | 42 | |
| 43 | - if ($setMaxSize === false) { |
|
| 44 | - return new JSONResponse([], Http::STATUS_BAD_REQUEST); |
|
| 45 | - } else { |
|
| 46 | - return new JSONResponse([ |
|
| 47 | - 'maxUploadSize' => Util::humanFileSize($setMaxSize) |
|
| 48 | - ]); |
|
| 49 | - } |
|
| 50 | - } |
|
| 43 | + if ($setMaxSize === false) { |
|
| 44 | + return new JSONResponse([], Http::STATUS_BAD_REQUEST); |
|
| 45 | + } else { |
|
| 46 | + return new JSONResponse([ |
|
| 47 | + 'maxUploadSize' => Util::humanFileSize($setMaxSize) |
|
| 48 | + ]); |
|
| 49 | + } |
|
| 50 | + } |
|
| 51 | 51 | } |
@@ -34,29 +34,29 @@ |
||
| 34 | 34 | * @package OCA\Files |
| 35 | 35 | */ |
| 36 | 36 | class Capabilities implements ICapability { |
| 37 | - /** @var IConfig */ |
|
| 38 | - protected $config; |
|
| 37 | + /** @var IConfig */ |
|
| 38 | + protected $config; |
|
| 39 | 39 | |
| 40 | - /** |
|
| 41 | - * Capabilities constructor. |
|
| 42 | - * |
|
| 43 | - * @param IConfig $config |
|
| 44 | - */ |
|
| 45 | - public function __construct(IConfig $config) { |
|
| 46 | - $this->config = $config; |
|
| 47 | - } |
|
| 40 | + /** |
|
| 41 | + * Capabilities constructor. |
|
| 42 | + * |
|
| 43 | + * @param IConfig $config |
|
| 44 | + */ |
|
| 45 | + public function __construct(IConfig $config) { |
|
| 46 | + $this->config = $config; |
|
| 47 | + } |
|
| 48 | 48 | |
| 49 | - /** |
|
| 50 | - * Return this classes capabilities |
|
| 51 | - * |
|
| 52 | - * @return array |
|
| 53 | - */ |
|
| 54 | - public function getCapabilities() { |
|
| 55 | - return [ |
|
| 56 | - 'files' => [ |
|
| 57 | - 'bigfilechunking' => true, |
|
| 58 | - 'blacklisted_files' => $this->config->getSystemValue('blacklisted_files', ['.htaccess']), |
|
| 59 | - ], |
|
| 60 | - ]; |
|
| 61 | - } |
|
| 49 | + /** |
|
| 50 | + * Return this classes capabilities |
|
| 51 | + * |
|
| 52 | + * @return array |
|
| 53 | + */ |
|
| 54 | + public function getCapabilities() { |
|
| 55 | + return [ |
|
| 56 | + 'files' => [ |
|
| 57 | + 'bigfilechunking' => true, |
|
| 58 | + 'blacklisted_files' => $this->config->getSystemValue('blacklisted_files', ['.htaccess']), |
|
| 59 | + ], |
|
| 60 | + ]; |
|
| 61 | + } |
|
| 62 | 62 | } |
@@ -39,21 +39,21 @@ |
||
| 39 | 39 | $templateManager->registerTemplate('application/vnd.oasis.opendocument.spreadsheet', 'core/templates/filetemplates/template.ods'); |
| 40 | 40 | |
| 41 | 41 | \OCA\Files\App::getNavigationManager()->add(function () use ($l) { |
| 42 | - return [ |
|
| 43 | - 'id' => 'files', |
|
| 44 | - 'appname' => 'files', |
|
| 45 | - 'script' => 'list.php', |
|
| 46 | - 'order' => 0, |
|
| 47 | - 'name' => $l->t('All files'), |
|
| 48 | - ]; |
|
| 42 | + return [ |
|
| 43 | + 'id' => 'files', |
|
| 44 | + 'appname' => 'files', |
|
| 45 | + 'script' => 'list.php', |
|
| 46 | + 'order' => 0, |
|
| 47 | + 'name' => $l->t('All files'), |
|
| 48 | + ]; |
|
| 49 | 49 | }); |
| 50 | 50 | |
| 51 | 51 | \OCA\Files\App::getNavigationManager()->add(function () use ($l) { |
| 52 | - return [ |
|
| 53 | - 'id' => 'recent', |
|
| 54 | - 'appname' => 'files', |
|
| 55 | - 'script' => 'recentlist.php', |
|
| 56 | - 'order' => 2, |
|
| 57 | - 'name' => $l->t('Recent'), |
|
| 58 | - ]; |
|
| 52 | + return [ |
|
| 53 | + 'id' => 'recent', |
|
| 54 | + 'appname' => 'files', |
|
| 55 | + 'script' => 'recentlist.php', |
|
| 56 | + 'order' => 2, |
|
| 57 | + 'name' => $l->t('Recent'), |
|
| 58 | + ]; |
|
| 59 | 59 | }); |
@@ -30,13 +30,13 @@ |
||
| 30 | 30 | * defines methods that are required by User class for LDAP interaction |
| 31 | 31 | */ |
| 32 | 32 | interface IUserTools { |
| 33 | - public function getConnection(); |
|
| 33 | + public function getConnection(); |
|
| 34 | 34 | |
| 35 | - public function readAttribute($dn, $attr, $filter = 'objectClass=*'); |
|
| 35 | + public function readAttribute($dn, $attr, $filter = 'objectClass=*'); |
|
| 36 | 36 | |
| 37 | - public function stringResemblesDN($string); |
|
| 37 | + public function stringResemblesDN($string); |
|
| 38 | 38 | |
| 39 | - public function dn2username($dn, $ldapname = null); |
|
| 39 | + public function dn2username($dn, $ldapname = null); |
|
| 40 | 40 | |
| 41 | - public function username2dn($name); |
|
| 41 | + public function username2dn($name); |
|
| 42 | 42 | } |