DC - Digimobile

Allow player to write digicode on DreadCast

目前為 2019-11-06 提交的版本,檢視 最新版本

// ==UserScript==
// @name         DC - Digimobile
// @namespace    http://tampermonkey.net/
// @version      0.5
// @description  Allow player to write digicode on DreadCast
// @author       Ajira
// @match        https://www.dreadcast.net/Main
// @grant        none
// ==/UserScript==

(function() {
    'use strict';
    document.getElementById("zone_lightBox").addEventListener('DOMNodeInserted', function() {
        var digiInput = document.getElementById("lb_textinput_digicode");
        if (digiInput == null) { return; }
        var digiForm = digiInput.parentNode.parentNode;
        if (digiForm == null) { return; }
        var digiBox = digiForm.parentNode.parentNode;
        digiBox.addEventListener("mousedown", function (event) {
            event.stopPropagation();
        }, true);
    }, false);
})();