change: closing the window minimizes to the tray, no popup #107
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/close-to-tray"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
Closing the window raised a confirmation popup with a five-second countdown that defaulted to quitting. #85 wants what every tray-resident app does: close = minimize to tray, quit lives in the tray menu, with an option for those who want close-means-quit.
Fix
closeEventhides to the tray and ignores the event when the tray is usable and the newclose_to_traysetting (default on) is set; otherwise it quits via the existingshutdown(). The popup and its countdown (change_timeout,exit_timer) are gone. Without a usable tray, closing always quits — hiding with no tray entry to come back from would strand the app.close_to_trayadded todefault_settings(anddefault_config.jsonfor the CLI's restore path) —load_configlayers defaults under existing configs, so current installs get the new default and a correctly-checked box. New checkbox + description in the Options tab via the existingconfig_listmachinery.TrayIcon.window_visible(visible)+showEvent/hideEventoverrides keep the tray's Hide/Show label truthful however the window was hidden — the latent label-desync quirk noted in #106, which this default would have promoted into a daily annoyance.Verification
Three new
closeEventpolicy tests (default hides + ignores the event; option off quits; unusable tray quits regardless) and twoTrayIconlabel-sync tests (follows visibility; harmless before populate). Full suite: 185 passed.Closes #85
🤖 Generated with Claude Code