BUG-139 - Clean Exit Can Leave The Shell Tray Icon Behind¶
Summary¶
A normal clean shutdown could leave the eMuleBB notification-area icon visible
until Explorer refreshed the tray. The tray icon was removed from
CTrayDialog::OnDestroy, but that handler deleted it after forwarding destroy
handling to the base window class. That made the shell cleanup depend on an
owner window handle that was already being torn down.
Fix¶
CemuleDlg::OnClosenow callsTrayHide()during the final clean shutdown phase, while the main dialog window and its tray icon handles are still valid.CTrayDialog::OnDestroynow callsTrayHide()before base destruction as an idempotent fallback for nonstandard destroy paths.
Acceptance Criteria¶
- [x] Clean shutdown removes the shell tray icon before the main dialog window is destroyed.
- [x] Destroy-path fallback also attempts tray deletion before base window teardown.
- [x] Tray deletion is idempotent and clears the internal visible/callback state.
Implementation Evidence¶
6314bbb5BUG-139 dispose tray icon before clean exit
Validation Evidence¶
python -m emule_workspace validate- Debug x64 app build through
python -m emule_workspace build app --variant main --config Debug --platform x64 --build-output-mode ErrorsOnlyat20260530T160540Z-build-app. - Release x64 app build through
python -m emule_workspace build app --variant main --config Release --platform x64 --build-output-mode ErrorsOnlyat20260530T160553Z-build-app.