소스 검색

Tentatively fixed buttons/etc from being enabled when turned on in a category that is collapsed

tags/v1.0.0
Fen Dweller 6 년 전
부모
커밋
20ecf0e085
No known key found for this signature in database GPG 키 ID: E80B35A6F11C3656
1개의 변경된 파일29개의 추가작업 그리고 1개의 파일을 삭제
  1. +29
    -1
      game.js

+ 29
- 1
game.js 파일 보기

@@ -4273,6 +4273,35 @@ function loadPreset() {
}

function grabFormData(form, warnings, panels, buttons, stats) {

// verify that this input box is in something we enabled


let parent = form.parentElement;


while(true) {
if (parent.id == "custom-species")
{
break;
}

if (parent.classList.contains("reveal-if-active"))
{
let sib = parent.previousSibling.previousSibling;

if (!sib.checked) {
console.log("aborting " + form.id);
return;
}

}

parent = parent.parentElement;


}

if (form.hasAttribute("data-warning")) {
warnings.push(form.getAttribute("data-warning"));
}
@@ -4487,7 +4516,6 @@ function enable_victim(category) {
}

function enable_button(name) {
console.log(name);
document.getElementById("button-action-" + name).style.display = "inline";
}



불러오는 중...
취소
저장