VeraCrypt
aboutsummaryrefslogtreecommitdiff
path: root/src/Main/Forms/PreferencesDialog.cpp
diff options
context:
space:
mode:
authorMounir IDRASSI <mounir.idrassi@idrix.fr>2014-10-26 16:28:59 (GMT)
committerMounir IDRASSI <mounir.idrassi@idrix.fr>2014-11-08 22:24:51 (GMT)
commit2c6e9fc15c6467d559cc5e212bd63b02f82640bb (patch)
tree5a37ed8dad3c6664d25f5858b143473c60655a05 /src/Main/Forms/PreferencesDialog.cpp
parentce7fab744bbb575dc29956254851b516c5cffc7f (diff)
downloadVeraCrypt-2c6e9fc15c6467d559cc5e212bd63b02f82640bb.zip
VeraCrypt-2c6e9fc15c6467d559cc5e212bd63b02f82640bb.tar.gz
Replace deprecated wxTextValidator::SetBellOnError whose logic whose inverted by the new wxTextValidator::SuppressBellOnError. Since its used in constructor only for TC_WINDOWS, we do the same in the destructor.
Diffstat (limited to 'src/Main/Forms/PreferencesDialog.cpp')
-rw-r--r--src/Main/Forms/PreferencesDialog.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/Main/Forms/PreferencesDialog.cpp b/src/Main/Forms/PreferencesDialog.cpp
index 50c9c30..e22e304 100644
--- a/src/Main/Forms/PreferencesDialog.cpp
+++ b/src/Main/Forms/PreferencesDialog.cpp
@@ -154,7 +154,7 @@ namespace VeraCrypt
Gui->SetListCtrlColumnWidths (HotkeyListCtrl, colPermilles);
RestoreValidatorBell = !wxTextValidator::IsSilent();
- wxTextValidator::SetBellOnError (true);
+ wxTextValidator::SuppressBellOnError (true);
HotkeyTextCtrl->SetValidator (wxTextValidator (wxFILTER_INCLUDE_CHAR_LIST));
UpdateHotkeyButtons();
@@ -203,8 +203,10 @@ namespace VeraCrypt
PreferencesDialog::~PreferencesDialog ()
{
+#ifdef TC_WINDOWS
if (RestoreValidatorBell)
- wxTextValidator::SetBellOnError (false);
+ wxTextValidator::SuppressBellOnError (false);
+#endif
}
void PreferencesDialog::SelectPage (wxPanel *page)