diff options
author | John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com> | 2018-10-04 15:14:15 +0200 |
---|---|---|
committer | Jan-Christoph Borchardt <hey@jancborchardt.net> | 2018-10-18 13:44:07 +0200 |
commit | c4cce1413487f5a0e870dd2139a4c624a97981fd (patch) | |
tree | 29fbd6c36d3ca8de130f37d9ce8b6ca376347eb0 /apps/files/templates/list.php | |
parent | 49fda8ba56860918d2e424ca07c94c08237846d4 (diff) | |
download | nextcloud-server-c4cce1413487f5a0e870dd2139a4c624a97981fd.tar.gz nextcloud-server-c4cce1413487f5a0e870dd2139a4c624a97981fd.zip |
Remember toggle and events handler
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
Diffstat (limited to 'apps/files/templates/list.php')
-rw-r--r-- | apps/files/templates/list.php | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/apps/files/templates/list.php b/apps/files/templates/list.php index c77cbb4d7c1..0c92cf8a1d4 100644 --- a/apps/files/templates/list.php +++ b/apps/files/templates/list.php @@ -24,7 +24,9 @@ <?php endif;?> <input type="hidden" class="max_human_file_size" value="(max <?php isset($_['uploadMaxHumanFilesize']) ? p($_['uploadMaxHumanFilesize']) : ''; ?>)"> - <button id="view-toggle" class="button view-toggle icon-toggle-pictures has-tooltip" title="<?php p($l->t('Toggle grid view'))?>"></button> + <input type="checkbox" class="hidden" id="showgridview" + <?php if($_['showgridview']) { ?>checked="checked" <?php } ?>/> + <label id="view-toggle" for="showgridview" class="button view-toggle <?php p($_['showgridview'] ? 'icon-toggle-filelist' : 'icon-toggle-pictures') ?> has-tooltip" title="<?php p($l->t('Toggle grid view'))?>"></label> </div> <div id="emptycontent" class="hidden"> @@ -39,7 +41,7 @@ <p></p> </div> -<table id="filestable" class="list-container view-grid" data-allow-public-upload="<?php p($_['publicUploadEnabled'])?>" data-preview-x="250" data-preview-y="250"> +<table id="filestable" class="list-container <?php p($_['showgridview'] ? 'view-grid' : '') ?>" data-allow-public-upload="<?php p($_['publicUploadEnabled'])?>" data-preview-x="250" data-preview-y="250"> <thead> <tr> <th id="headerSelection" class="hidden column-selection"> |