From 8a13851da8906a4eed3c7b59d01f5a172c90371c Mon Sep 17 00:00:00 2001 From: Julius Härtl Date: Thu, 25 Jan 2018 18:53:09 +0100 Subject: Use PublicTemplateResponse for files_sharing MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Julius Härtl --- apps/files_sharing/lib/Template/LinkMenuAction.php | 47 ++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 apps/files_sharing/lib/Template/LinkMenuAction.php (limited to 'apps/files_sharing/lib/Template/LinkMenuAction.php') diff --git a/apps/files_sharing/lib/Template/LinkMenuAction.php b/apps/files_sharing/lib/Template/LinkMenuAction.php new file mode 100644 index 00000000000..af5fda94455 --- /dev/null +++ b/apps/files_sharing/lib/Template/LinkMenuAction.php @@ -0,0 +1,47 @@ + + * + * @author Julius Härtl + * + * @license GNU AGPL version 3 or any later version + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Affero General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see . + * + */ + +namespace OCA\Files_Sharing\Template; + +use OCP\AppFramework\Http\Template\SimpleMenuAction; + +class LinkMenuAction extends SimpleMenuAction { + + public function __construct($label, $icon, $link) { + parent::__construct('directLink-container', $label, $icon, $link); + } + + /** + * @since 14.0.0 + * @return string + */ + public function render(): string { + return '
  • ' . + '' . + '' . + '' . + '' . + '' . + '
  • '; + } +} \ No newline at end of file -- cgit v1.2.3