diff --git a/www/drive/main.js b/www/drive/main.js index 7ff151c1f..cad9973fd 100644 --- a/www/drive/main.js +++ b/www/drive/main.js @@ -383,6 +383,13 @@ define([ // Enter if (e.which === 13) { + var $allSelected = $content.find('.element.selected'); + if ($allSelected.length === 1) { + // Open the folder or the file + $allSelected.dblclick(); + return; + } + // If more than one, open only the files var $select = $content.find('.file-element.selected'); $select.each(function (idx, el) { $(el).dblclick();