(listElement, resolutionList)
| 3080 | ///// Init resolutions dropdown |
| 3081 | |
| 3082 | function makeResolutionButtons(listElement, resolutionList) { |
| 3083 | listElement.innerHTML = "" |
| 3084 | resolutionList.forEach((el) => { |
| 3085 | let button = createElement("button", { style: "width: 8em;" }, "tertiaryButton", `${el.w}×${el.h}`) |
| 3086 | button.addEventListener("click", () => { |
| 3087 | customWidthField.value = el.w |
| 3088 | customHeightField.value = el.h |
| 3089 | hidePopup() |
| 3090 | }) |
| 3091 | listElement.appendChild(button) |
| 3092 | listElement.appendChild(document.createElement("br")) |
| 3093 | }) |
| 3094 | } |
| 3095 | |
| 3096 | enlargeButtons.querySelectorAll("button").forEach((button) => |
| 3097 | button.addEventListener("click", (e) => { |
no test coverage detected