summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLukas Reschke <lukas@statuscode.ch>2017-03-24 19:41:49 +0100
committerLukas Reschke <lukas@statuscode.ch>2017-03-24 19:42:22 +0100
commitb70b138bdb6c59df8c94cb973155d7ab4a41113b (patch)
treedd7a8c806674290dca0bffeab2dc021eafc2c942
parent2cd79a8d3d6c160b9458327b1429eed9ec1a25a2 (diff)
downloadnextcloud-server-b70b138bdb6c59df8c94cb973155d7ab4a41113b.tar.gz
nextcloud-server-b70b138bdb6c59df8c94cb973155d7ab4a41113b.zip
Merge file view JS files
Removes 26 requests on the file list loading Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
-rw-r--r--apps/files/js/merged-index.json29
-rw-r--r--apps/files/lib/Controller/ViewController.php31
2 files changed, 30 insertions, 30 deletions
diff --git a/apps/files/js/merged-index.json b/apps/files/js/merged-index.json
new file mode 100644
index 00000000000..127bbb46b29
--- /dev/null
+++ b/apps/files/js/merged-index.json
@@ -0,0 +1,29 @@
+[
+ "app.js",
+ "file-upload.js",
+ "newfilemenu.js",
+ "jquery.fileupload.js",
+ "jquery-visibility.js",
+ "fileinfomodel.js",
+ "filesummary.js",
+ "breadcrumb.js",
+ "filelist.js",
+ "search.js",
+ "favoritesfilelist.js",
+ "recentfilelist.js",
+ "tagsplugin.js",
+ "gotoplugin.js",
+ "favoritesplugin.js",
+ "recentplugin.js",
+ "detailfileinfoview.js",
+ "sidebarpreviewmanager.js",
+ "sidebarpreviewtext.js",
+ "detailtabview.js",
+ "mainfileinfodetailview.js",
+ "detailsview.js",
+ "fileactions.js",
+ "fileactionsmenu.js",
+ "files.js",
+ "keyboardshortcuts.js",
+ "navigation.js"
+]
diff --git a/apps/files/lib/Controller/ViewController.php b/apps/files/lib/Controller/ViewController.php
index cfe66eb028b..499961ca2dc 100644
--- a/apps/files/lib/Controller/ViewController.php
+++ b/apps/files/lib/Controller/ViewController.php
@@ -152,37 +152,8 @@ class ViewController extends Controller {
$nav = new \OCP\Template('files', 'appnavigation', '');
// Load the files we need
- \OCP\Util::addScript('files', 'app');
- \OCP\Util::addScript('files', 'file-upload');
- \OCP\Util::addScript('files', 'newfilemenu');
- \OCP\Util::addScript('files', 'jquery.fileupload');
- \OCP\Util::addScript('files', 'jquery-visibility');
- \OCP\Util::addScript('files', 'fileinfomodel');
- \OCP\Util::addScript('files', 'filesummary');
- \OCP\Util::addScript('files', 'breadcrumb');
- \OCP\Util::addScript('files', 'filelist');
- \OCP\Util::addScript('files', 'search');
-
- \OCP\Util::addScript('files', 'favoritesfilelist');
- \OCP\Util::addScript('files', 'recentfilelist');
- \OCP\Util::addScript('files', 'tagsplugin');
- \OCP\Util::addScript('files', 'gotoplugin');
- \OCP\Util::addScript('files', 'favoritesplugin');
- \OCP\Util::addScript('files', 'recentplugin');
-
- \OCP\Util::addScript('files', 'detailfileinfoview');
- \OCP\Util::addScript('files', 'sidebarpreviewmanager');
- \OCP\Util::addScript('files', 'sidebarpreviewtext');
- \OCP\Util::addScript('files', 'detailtabview');
- \OCP\Util::addScript('files', 'mainfileinfodetailview');
- \OCP\Util::addScript('files', 'detailsview');
\OCP\Util::addStyle('files', 'merged');
-
- \OCP\Util::addScript('files', 'fileactions');
- \OCP\Util::addScript('files', 'fileactionsmenu');
- \OCP\Util::addScript('files', 'files');
- \OCP\Util::addScript('files', 'keyboardshortcuts');
- \OCP\Util::addScript('files', 'navigation');
+ \OCP\Util::addScript('files', 'merged-index');
// mostly for the home storage's free space
// FIXME: Make non static