diff --git a/Ink Canvas/Windows/SettingsViews/SettingsViews/SecurityPanel.xaml b/Ink Canvas/Windows/SettingsViews/SettingsViews/SecurityPanel.xaml
index 66d85eb0..9d5a199c 100644
--- a/Ink Canvas/Windows/SettingsViews/SettingsViews/SecurityPanel.xaml
+++ b/Ink Canvas/Windows/SettingsViews/SettingsViews/SecurityPanel.xaml
@@ -66,7 +66,6 @@
-
diff --git a/Ink Canvas/Windows/SettingsViews/SettingsViews/SecurityPanel.xaml.cs b/Ink Canvas/Windows/SettingsViews/SettingsViews/SecurityPanel.xaml.cs
index 0dddbfe8..ed3284a6 100644
--- a/Ink Canvas/Windows/SettingsViews/SettingsViews/SecurityPanel.xaml.cs
+++ b/Ink Canvas/Windows/SettingsViews/SettingsViews/SecurityPanel.xaml.cs
@@ -43,7 +43,6 @@ namespace Ink_Canvas.Windows.SettingsViews
var enabled = sec != null && sec.PasswordEnabled;
if (BtnSetOrChangePassword != null) BtnSetOrChangePassword.IsEnabled = enabled;
- if (BtnDisablePassword != null) BtnDisablePassword.IsEnabled = enabled;
// 用途开关:仅在启用密码功能时可操作
var usageEnabled = enabled;
@@ -155,21 +154,6 @@ namespace Ink_Canvas.Windows.SettingsViews
}
}
- private void BtnDisablePassword_Click(object sender, RoutedEventArgs e)
- {
- // 触发和开关一致的逻辑
- if (FindToggleSwitch("ToggleSwitchPasswordEnabled") is Border b)
- {
- // 模拟点击到 off
- if (MainWindow.Settings?.Security?.PasswordEnabled == true)
- {
- _isLoaded = true;
- SetToggleSwitchState(b, false);
- HandleToggleSwitchChange("PasswordEnabled", false);
- }
- }
- }
-
public event EventHandler IsTopBarNeedShadowEffect;
public event EventHandler IsTopBarNeedNoShadowEffect;