summaryrefslogtreecommitdiffstats
path: root/core/js
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2017-11-13 12:19:05 +0100
committerGitHub <noreply@github.com>2017-11-13 12:19:05 +0100
commitff2d4432d8af7f8d1d17d9740f985bb36db531fc (patch)
tree3bae3c8530c0e1cf9bce78e2b1d02966660e6be4 /core/js
parent26bcf40e9e0b35b851ff1aecab8dd9fd2b1be80e (diff)
parent8c2dbeb13a71ca320f6953302f75ce491c4f1aff (diff)
downloadnextcloud-server-ff2d4432d8af7f8d1d17d9740f985bb36db531fc.tar.gz
nextcloud-server-ff2d4432d8af7f8d1d17d9740f985bb36db531fc.zip
Merge pull request #7051 from nextcloud/breadcrumbs-refactor
Breadcrumbs refactor
Diffstat (limited to 'core/js')
-rw-r--r--core/js/js.js33
-rw-r--r--core/js/oc-dialogs.js2
2 files changed, 1 insertions, 34 deletions
diff --git a/core/js/js.js b/core/js/js.js
index 1f84b40a35a..730586713a0 100644
--- a/core/js/js.js
+++ b/core/js/js.js
@@ -1625,39 +1625,6 @@ function initCore() {
// initial call
toggleSnapperOnSize();
- // adjust controls bar width
- var adjustControlsWidth = function() {
- if($('#controls').length) {
- var controlsWidth;
- // if there is a scrollbar …
- if($('#app-content').get(0).scrollHeight > $('#app-content').height()) {
- if($(window).width() > 768) {
- controlsWidth = $('#content').width() - $('#app-navigation').width() - getScrollBarWidth();
- if (!$('#app-sidebar').hasClass('hidden') && !$('#app-sidebar').hasClass('disappear')) {
- controlsWidth -= $('#app-sidebar').width();
- }
- } else {
- controlsWidth = $('#content').width() - getScrollBarWidth();
- }
- } else { // if there is none
- if($(window).width() > 768) {
- controlsWidth = $('#content').width() - $('#app-navigation').width();
- if (!$('#app-sidebar').hasClass('hidden') && !$('#app-sidebar').hasClass('disappear')) {
- controlsWidth -= $('#app-sidebar').width();
- }
- } else {
- controlsWidth = $('#content').width();
- }
- }
- $('#controls').css('width', controlsWidth);
- $('#controls').css('min-width', controlsWidth);
- }
- };
-
- $(window).resize(_.debounce(adjustControlsWidth, 250));
-
- $('body').delegate('#app-content', 'apprendered appresized', _.debounce(adjustControlsWidth, 150));
-
}
// Update live timestamps every 30 seconds
diff --git a/core/js/oc-dialogs.js b/core/js/oc-dialogs.js
index 1bc1399466d..9cd806720b8 100644
--- a/core/js/oc-dialogs.js
+++ b/core/js/oc-dialogs.js
@@ -929,7 +929,7 @@ var OCdialogs = {
*/
_handleTreeListSelect:function(event, type) {
var self = event.data;
- var dir = $(event.target).parent().data('dir');
+ var dir = $(event.target).closest('.crumb').data('dir');
self._fillFilePicker(dir);
var getOcDialog = (event.target).closest('.oc-dialog');
var buttonEnableDisable = $('.primary', getOcDialog);