mirror of
https://github.com/Pathduck/gallery3.git
synced 2026-08-25 00:05:45 -04:00
Double clicking on an album switches to that album, selects it in the
tree and expands it if it's not already expanded.
This commit is contained in:
@@ -92,6 +92,13 @@
|
||||
new Ext.DataView.DragSelector({dragSafe: true})
|
||||
],
|
||||
listeners: {
|
||||
"dblclick": function(v, index, node, e) {
|
||||
node = Ext.get(node);
|
||||
if (node.hasClass("thumb-album")) {
|
||||
var id = node.getAttribute("rel");
|
||||
tree_panel.fireEvent("click", tree_panel.getNodeById(id))
|
||||
}
|
||||
},
|
||||
"render": function(v) {
|
||||
v.dragZone = new Ext.dd.DragZone(v.getEl(), {
|
||||
ddGroup: "organizeDD",
|
||||
@@ -307,6 +314,9 @@
|
||||
listeners: {
|
||||
"click": function(node) {
|
||||
load_album_data(node.id);
|
||||
if (node.isExpandable() && !node.isExpanded()) {
|
||||
node.expand();
|
||||
}
|
||||
},
|
||||
"afterrender": function(v) {
|
||||
// Override Ext.tree.TreeDragZone.onNodeOver to change the
|
||||
|
||||
Reference in New Issue
Block a user