diff options
Diffstat (limited to 'app/src/main/assets/js/click_debugger.js')
-rw-r--r-- | app/src/main/assets/js/click_debugger.js | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/app/src/main/assets/js/click_debugger.js b/app/src/main/assets/js/click_debugger.js new file mode 100644 index 00000000..71db586a --- /dev/null +++ b/app/src/main/assets/js/click_debugger.js @@ -0,0 +1,20 @@ +'use strict'; + +(function () { + // for desktop only + var _frostAContext; + + _frostAContext = function _frostAContext(e) { + /* + * Commonality; check for valid target + */ + var element; + element = e.target || e.currentTarget || e.srcElement; + if (!element) { + return; + } + console.log('Clicked element: ' + element.tagName + ' ' + element.className); + }; + + document.addEventListener('contextmenu', _frostAContext, true); +}).call(undefined);
\ No newline at end of file |