foo_spider_monkey_panel icon indicating copy to clipboard operation
foo_spider_monkey_panel copied to clipboard

Link effect not working on drag drop

Open regorxxx opened this issue 1 year ago • 0 comments

window.DefineScript('bug', {features: {drag_n_drop: true, grab_focus: true}});

function on_drag_drop(action, x, y, mask) {
	console.log('enter', action);
}

function on_drag_over(action, x, y, mask) {
    if ((mask & 32) === 32) {action.Effect = dropEffect.link;}
}

function on_drag_leave() {
	console.log('leave');
}


const dropEffect = {
	none:   0,
	copy:   1,
	move:   2,
	link:   4,
	scroll: 0x80000000
};

Console will always report on_drag_leave firing when pressing alt, instead of on_drag_drop. It works properly for all other effects. The drag n drop sample doesn't work too. Win 10.

regorxxx avatar Jun 13 '23 09:06 regorxxx