Commit a6ce0ea8 authored by Fabian-Andree Heidemann's avatar Fabian-Andree Heidemann
Browse files

[file] disable drag and drop on touch

[file] fix #2184, prevent double open on desktop via modal loading
[platform] fix shim of JQuery TouchPuch with dependency of JQuery UI
parent bdcb77d5
......@@ -21,6 +21,7 @@ define(["jquery", "jclass"], function($, JClass) {
newPath = this.FileBase.selections.entries[newPath]
.data()
.data.realpath || newPath;
this.FileBase.instance.setLoading(true, 0);
this.FileBase.instance.setState("path", newPath);
},
......
......@@ -137,6 +137,7 @@ define([
self.instance.close();
return;
}
self.instance.setLoading(false);
if (data.count < 0) {
self.instance.setLoading(true);
self.instance.getTemplate("html/alert.html",
......
......@@ -203,6 +203,8 @@ define(["jquery", "jclass"], function($, JClass) {
},
dragAndDrop: function(node, data) {
if (vispa.device.hasTouch) return;
var self = this;
$(node).draggable({
......@@ -260,6 +262,8 @@ define(["jquery", "jclass"], function($, JClass) {
},
dragAndDropBkg: function(node) {
if (vispa.device.hasTouch) return;
var self = this;
var $bkg = $(".file-list", node);
......@@ -274,6 +278,8 @@ define(["jquery", "jclass"], function($, JClass) {
},
enableDragAndDropUpload: function () {
if (vispa.device.hasTouch) return;
var self = this;
var $bkg = $(".file-list", self.FileBase.view.fileContentContainer);
......@@ -304,6 +310,8 @@ define(["jquery", "jclass"], function($, JClass) {
},
disableDragAndDropUpload: function () {
if (vispa.device.hasTouch) return;
$(document).off(".dragAndDropUpload");
},
......
......@@ -38,7 +38,7 @@
styles : "css"
},
shim: {
"vendor/jquery/plugins/touchpunch/jquery.touchpunch": ["jquery"],
"vendor/jquery/plugins/touchpunch/jquery.touchpunch": ["jquery", "vendor/jquery/plugins/ui/jquery.ui"],
"vendor/jquery/plugins/history/jquery.history": ["jquery"],
"vendor/jquery/plugins/hotkeys/jquery.hotkeys": ["jquery"],
"vendor/jquery/plugins/fileupload/jquery.fileupload": ["jquery"],
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment