Debug events tagCo

Debug TC events

目前为 2018-11-15 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name Debug events tagCo
  3. // @namespace http://leroymerlin.fr/
  4. // @version 0.2
  5. // @description Debug TC events
  6. // @author BAMF Consulting
  7. // @match *://*/*
  8. // @grant none
  9. // @noframes
  10. // ==/UserScript==
  11.  
  12. function overrideTcEvents(){
  13. console.log("%c---------------------","color:#44FF44;background-color:#000000;");
  14. console.log(window.orinterval);
  15. if(typeof window.tc_events_global !='undefined'){
  16. window.old_tc_events_global = window.tc_events_global;
  17. window.tc_events_global = function(){
  18. console.log("%c------ TC EVENT ------","color:#FF4444;background-color:#000000;");
  19. console.log(arguments);
  20. window.old_tc_events_global.apply(this,arguments);
  21. }
  22. console.log("%c------ OVERRIDE TC EVENT ------","color:#44FF44;background-color:#000000;");
  23. window.clearInterval(window.orinterval);
  24. }
  25. }
  26.  
  27. (function() {
  28. console.log("here");
  29. window.orinterval = window.setInterval(overrideTcEvents,100);
  30. })();
  31.