diff options
author | Tor Andersson <tor@ccxvii.net> | 2024-11-04 23:59:49 +0100 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2024-11-05 01:48:00 +0100 |
commit | ce86e2afb83461ccff20101884c39aeb3ff3b109 (patch) | |
tree | 4920275ba9454345ae68eb922f4a5d1462792994 /play.js | |
parent | 346f21024b62b0ec3abfa19423854ab83ef230b6 (diff) | |
download | maria-ce86e2afb83461ccff20101884c39aeb3ff3b109.tar.gz |
fix elector layout
Diffstat (limited to 'play.js')
-rw-r--r-- | play.js | 14 |
1 files changed, 6 insertions, 8 deletions
@@ -1216,14 +1216,12 @@ function layout_elector(s, pow) { } function layout_electoral_college(ix, pow) { - for (let s of all_electoral_colleges) { - let e = ui.elector[pow][used_elector[pow]++] - let x = ELECTORAL_COLLEGE_X + ELECTORAL_COLLEGE_DX * ix - let y = ELECTORAL_COLLEGE_Y - e.style.left = (x - 16) + "px" - e.style.top = (y - 16) + "px" - ui.markers_element.appendChild(e) - } + let e = ui.elector[pow][used_elector[pow]++] + let x = ELECTORAL_COLLEGE_X + ELECTORAL_COLLEGE_DX * ix + let y = ELECTORAL_COLLEGE_Y + e.style.left = (x - 16) + "px" + e.style.top = (y - 16) + "px" + ui.markers_element.appendChild(e) } function update_favicon() { |