Merge remote-tracking branch 'origin/drive-tree-ui' into 2026.2-rc

This commit is contained in:
yflory 2026-02-05 18:15:08 +01:00
commit 0cc63e0f2c

View File

@ -962,7 +962,7 @@ define([
// Replace a file/folder name by an input to change its value
var displayRenameInput = function ($element, path) {
// NOTE: setTimeout(f, 0) otherwise the "rename" button in the toolbar is not working
window.setTimeout(function () {
var renameInput = function () {
if (!APP.editable) { return; }
if (!path || path.length < 2) {
logError("Renaming a top level element (root, trash or filesData) is forbidden.");
@ -1057,7 +1057,12 @@ define([
e.stopPropagation();
$input.parents('.cp-app-drive-element-row').attr("draggable", true);
});
},0);
};
if (APP.mobile()) {
renameInput();
} else {
window.setTimeout(renameInput, 0);
}
};