Speak-status: drop the double-press-copy Preferences toggle
Andre confirmed (via NVDA speech history) that holding the speak-status hotkey doesn't repeat or spam — so the defensive toggle that let users disable the double-press-to-copy was needless configurability. Removed the Preferences checkbox and the DoublePressStatusToCopy setting; double-press-to-copy (Andre's own idea) stays, now simply always on. There was never any debounce/anti-spam code to remove — the only timing is the 600 ms double-tap detection window, which is the feature itself. Manual updated to drop the toggle line. Held for the next release (the toggle never shipped). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
6c36369806
commit
843be9b7fb
@@ -3370,10 +3370,9 @@ public sealed class MainForm : Form
|
||||
var text = statusReadout.Text;
|
||||
if (string.IsNullOrWhiteSpace(text)) text = "No status information available.";
|
||||
|
||||
// Double press copies to the clipboard — but only if the user has left that on (Preferences →
|
||||
// General). Read the flag only when the timing already qualifies, so a normal single press never
|
||||
// touches the config file.
|
||||
if (withinDoublePressWindow && AppConfig.Load().DoublePressStatusToCopy)
|
||||
// A quick second press copies the status to the clipboard instead of reading it again, so it can
|
||||
// be shared. This is a deliberate double-tap, not a key repeat — a single press never reaches here.
|
||||
if (withinDoublePressWindow)
|
||||
{
|
||||
// Second quick press: copy the status to the clipboard so it can be shared. Clipboard access
|
||||
// needs the UI thread — this runs on it (the hotkey is marshalled onto the owner form).
|
||||
|
||||
@@ -210,15 +210,6 @@ internal sealed class PreferencesDialog : Form
|
||||
AutoSize = true,
|
||||
};
|
||||
|
||||
// Screen-reader convenience (machine-wide, AppConfig). On by default. When off, a double press of
|
||||
// the speak-status hotkey just reads the status again rather than copying it.
|
||||
private readonly AccessibleCheckBox doublePressCopyBox = new()
|
||||
{
|
||||
Text = "Double-press the speak-status hotkey to copy the status to the clipboard (Alt+&C)",
|
||||
AccessibleName = "Double-press the speak-status hotkey to copy the status to the clipboard",
|
||||
AutoSize = true,
|
||||
};
|
||||
|
||||
// Update settings — startup-check checkbox, frequency dropdown, manual check button,
|
||||
// silent-install checkbox. Sits above the logging row so users meet it during setup; the
|
||||
// canonical order in the dialog is "things related to the program staying current" before
|
||||
@@ -575,15 +566,6 @@ internal sealed class PreferencesDialog : Form
|
||||
silentlyInstallUpdatesBox.Checked = cfgForLoad.SilentlyInstallUpdates;
|
||||
upnpEnabledBox.Checked = cfgForLoad.UpnpEnabled;
|
||||
|
||||
// Double-press-the-speak-status-hotkey-to-copy toggle (machine-wide, AppConfig). On by default.
|
||||
doublePressCopyBox.Checked = cfgForLoad.DoublePressStatusToCopy;
|
||||
doublePressCopyBox.CheckedChanged += (_, _) =>
|
||||
{
|
||||
var cfg = AppConfig.Load();
|
||||
cfg.DoublePressStatusToCopy = doublePressCopyBox.Checked;
|
||||
try { cfg.Save(); } catch { /* harmless — choice just won't survive a restart */ }
|
||||
};
|
||||
|
||||
checkForUpdatesOnStartupBox.CheckedChanged += (_, _) =>
|
||||
{
|
||||
var cfg = AppConfig.Load();
|
||||
@@ -816,7 +798,7 @@ internal sealed class PreferencesDialog : Form
|
||||
// is a field (declared above) so OnShown can focus it when the dialog opens. Logging is its
|
||||
// own tab (2026-06-19); the two logging controls moved off the General tab to lead it.
|
||||
tabs.TabPages.Add(MakeTab("General",
|
||||
browseProfilesFolderButton, acceptRemoteVolumeBox, upnpEnabledBox, upnpStatusLabel, doublePressCopyBox));
|
||||
browseProfilesFolderButton, acceptRemoteVolumeBox, upnpEnabledBox, upnpStatusLabel));
|
||||
tabs.TabPages.Add(MakeTab("Audio cues", cueGroup));
|
||||
tabs.TabPages.Add(MakeTab("Startup behaviour",
|
||||
startMinimisedBox, startWithUserBox, startWithProfileBox, startupListPanel));
|
||||
|
||||
@@ -196,11 +196,6 @@ public sealed class AppConfig
|
||||
public bool? UntickOthersWhenUsingDefaultOutput { get; set; }
|
||||
public bool? UntickOthersWhenUsingDefaultInput { get; set; }
|
||||
|
||||
/// <summary>If true, pressing the "speak status" global hotkey twice in quick succession copies the
|
||||
/// status text to the clipboard (instead of just reading it again). On by default; the user can turn
|
||||
/// it off on the Preferences General tab. Machine-wide; a screen-reader convenience (Andre's idea).</summary>
|
||||
public bool DoublePressStatusToCopy { get; set; } = true;
|
||||
|
||||
/// <summary>If non-null and a profile with this title exists, RemSound skips the
|
||||
/// startup profile picker and loads this profile directly. Combine with
|
||||
/// <see cref="StartMinimised"/> + the Windows auto-start registry entry
|
||||
|
||||
Reference in New Issue
Block a user