diff --git a/src/webdrop_bridge/ui/bridge_script_intercept.js b/src/webdrop_bridge/ui/bridge_script_intercept.js index e600d0d..6469811 100644 --- a/src/webdrop_bridge/ui/bridge_script_intercept.js +++ b/src/webdrop_bridge/ui/bridge_script_intercept.js @@ -82,10 +82,6 @@ originalAddEventListener.call(document, 'dragstart', function(e) { currentDragUrl = null; // Reset - // Check once per drag if native DnD is disabled via URL param (e.g. ?disablednd=true) - var disabledNativeDnD = /[?&]disablednd=true/i.test(window.location.search); - console.log('%c[Intercept] dragstart', 'background: #FF9800; color: white; padding: 2px 6px;', 'ALT:', e.altKey, '| disablednd:', disabledNativeDnD); - // Call Angular's handlers first to let them set the data var handled = 0; for (var i = 0; i < angularDragHandlers.length; i++) { @@ -104,8 +100,8 @@ console.log('[Intercept] Called', handled, 'Angular handlers, URL:', currentDragUrl ? currentDragUrl.substring(0, 60) : 'none'); // NOW check if we should intercept - // Intercept when: Alt key held (normal mode) OR native DnD disabled via URL param - if ((e.altKey || disabledNativeDnD) && currentDragUrl) { + // Intercept any drag with a URL that matches our configured mappings + if (currentDragUrl) { var shouldIntercept = false; // Check against configured URL mappings @@ -191,7 +187,7 @@ }); } - console.log('%c[WebDrop Intercept] Ready! ALT-drag or ?disablednd=true will use Qt file drag.', + console.log('%c[WebDrop Intercept] Ready! URL-mapped drags will use Qt file drag.', 'background: #4CAF50; color: white; font-weight: bold; padding: 4px 8px;'); } catch(e) { console.error('[WebDrop Intercept] FATAL ERROR in bridge script:', e);