我有 dhtmlx 网格,并在其中附加了两个事件:
var click_flag = false;
dhxGrid.attachEvent("onRowDblClicked", function (rowId, cellIndex) {
click_flag = true;
...
});
dhxGrid.attachEvent("onRowSelect", function (rowId, cellIndex) {
if (!click_flag) {
...
}
});
但是 onRowSelect 总是被触发,即使我双击网格的一行。有没有办法阻止它执行?我尝试使用 click_flag 但它不起作用。