0013372: doubleclick should open edit dialog
authorPhilipp Schüle <p.schuele@metaways.de>
Tue, 8 Aug 2017 08:48:17 +0000 (10:48 +0200)
committerMichael Spahn <m.spahn@metaways.de>
Wed, 9 Aug 2017 09:31:18 +0000 (11:31 +0200)
https://forge.tine20.org/view.php?id=13372

Change-Id: I0d96192bf6957290463480ec0ecdede64f2fdab9
Reviewed-on: http://gerrit.tine20.com/customers/5417
Tested-by: Philipp Schüle <p.schuele@metaways.de>
Reviewed-by: Michael Spahn <m.spahn@metaways.de>
tine20/MailFiler/js/NodeGridPanel.js

index b25df55..63cabaa 100644 (file)
@@ -534,6 +534,25 @@ Tine.MailFiler.NodeGridPanel = Ext.extend(Tine.Filemanager.NodeGridPanel, {
     },
 
     /**
+     * grid row doubleclick handler
+     *
+     * @param {Tine.MailFiler.NodeGridPanel} grid
+     * @param {} row record
+     * @param {Ext.EventObjet} e
+     */
+    onRowDblClick: function (grid, row, e) {
+        var rowRecord = grid.getStore().getAt(row);
+
+        if (rowRecord.data.type == 'file') {
+            Tine.MailFiler.NodeEditDialog.openWindow({
+                record: rowRecord
+            });
+        } else if (rowRecord.data.type == 'folder') {
+            Tine.MailFiler.NodeGridPanel.superclass.onRowDblClick.call(this, grid, row, e);
+        }
+    },
+
+    /**
      * get action toolbar
      *
      * @return {Ext.Toolbar}