Commit 73dda11
fix(stealth): mark the opacity shield spent when it fires
Both arm sites assigned this.opacityTimeout and neither callback nulled it,
so after any win32 overlay/launcher show the field held an already-fired
Timeout forever. cancelOpacityShield()'s "nothing pending" early return
therefore never fired and every later minimize/close ran a restore pass —
harmless today (the shield and hideMainWindow are the only things that zero
those four windows, and hideMainWindow hides them first, so the isVisible()
guard skips them) but it made the guard, and the test asserting it, vacuous.
Also pins the platform gate on the chrome re-push: it may skip win32, but it
must never exclude darwin. reassertContentProtection() routes through
applyContentProtection after app.dock.hide()/show(), and that flip makes
WindowServer silently reset sharingType — the re-push is the only thing that
restores NSWindowSharingNone. Narrowing the gate the other way would
un-protect the overlay after every dock toggle with nothing to catch it.
Renames the per-window assertion, which said "unconditionally" while the
literal now sits inside a platform gate. The unconditional part is covered
by the CREATED/SHOWN tests.
Mutation probes confirmed failing: either callback's null removed; the gate
flipped to `!== 'darwin'`.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Si93L7isjy1GFkqzjb7gJy1 parent 86b5ad9 commit 73dda11
3 files changed
Lines changed: 54 additions & 2 deletions
File tree
- electron
- audio/__tests__
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2309 | 2309 | | |
2310 | 2310 | | |
2311 | 2311 | | |
| 2312 | + | |
| 2313 | + | |
| 2314 | + | |
| 2315 | + | |
| 2316 | + | |
2312 | 2317 | | |
2313 | 2318 | | |
2314 | 2319 | | |
| |||
2407 | 2412 | | |
2408 | 2413 | | |
2409 | 2414 | | |
| 2415 | + | |
| 2416 | + | |
2410 | 2417 | | |
2411 | 2418 | | |
2412 | 2419 | | |
| |||
Lines changed: 21 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
134 | 134 | | |
135 | 135 | | |
136 | 136 | | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
137 | 158 | | |
138 | 159 | | |
139 | 160 | | |
| |||
Lines changed: 26 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
123 | 123 | | |
124 | 124 | | |
125 | 125 | | |
126 | | - | |
| 126 | + | |
127 | 127 | | |
128 | 128 | | |
129 | 129 | | |
| |||
135 | 135 | | |
136 | 136 | | |
137 | 137 | | |
138 | | - | |
| 138 | + | |
139 | 139 | | |
140 | 140 | | |
141 | 141 | | |
142 | 142 | | |
143 | 143 | | |
144 | 144 | | |
145 | 145 | | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
146 | 170 | | |
147 | 171 | | |
148 | 172 | | |
| |||
0 commit comments