diff --git a/apps/files_trashbin/index.php b/apps/files_trashbin/index.php
index d8661e170a58cd69ebde886cb0fa92192969916f..d079af3fb6d185ddf58bf3dfa7a840cedac18995 100644
--- a/apps/files_trashbin/index.php
+++ b/apps/files_trashbin/index.php
@@ -5,7 +5,6 @@ OCP\User::checkLoggedIn();
 
 OCP\App::setActiveNavigationEntry('files_index');
 
-OCP\Util::addScript('files_trashbin', 'trash');
 OCP\Util::addScript('files_trashbin', 'disableDefaultActions');
 OCP\Util::addScript('files', 'fileactions');
 $tmpl = new OCP\Template('files_trashbin', 'index', 'user');
@@ -15,6 +14,7 @@ OCP\Util::addScript('files', 'filelist');
 // filelist overrides
 OCP\Util::addScript('files_trashbin', 'filelist');
 OCP\Util::addscript('files', 'files');
+OCP\Util::addScript('files_trashbin', 'trash');
 
 $dir = isset($_GET['dir']) ? stripslashes($_GET['dir']) : '';
 
diff --git a/apps/files_trashbin/js/trash.js b/apps/files_trashbin/js/trash.js
index d73eadb6011d40ac73797b617e4e26bb493e5c45..4e83afcdb06f3b67eac9c05707bc685ef83e8e45 100644
Binary files a/apps/files_trashbin/js/trash.js and b/apps/files_trashbin/js/trash.js differ
diff --git a/apps/files_trashbin/templates/index.php b/apps/files_trashbin/templates/index.php
index 82ba0608834c95e6fcdc2632dd694235c90613b7..9b01a2589a5fa3f914e6d7952ec86c497a70bdd4 100644
--- a/apps/files_trashbin/templates/index.php
+++ b/apps/files_trashbin/templates/index.php
@@ -17,7 +17,9 @@
 	<thead>
 		<tr>
 			<th id='headerName'>
+				<div id="headerName-container">
 				<input type="checkbox" id="select_all" />
+				<label for="select_all"></label>
 				<span class='name'><?php p($l->t( 'Name' )); ?></span>
 				<span class='selectedActions'>
 						<a href="" class="undelete">
@@ -26,6 +28,7 @@
 							<?php p($l->t('Restore'))?>
 						</a>
 				</span>
+				</div>
 			</th>
 			<th id="headerDate">
 				<span id="modified"><?php p($l->t( 'Deleted' )); ?></span>