From: Vadim Zeitlin <vadim@wxwidgets.org>
Date: Wed, 3 Mar 2010 14:19:05 +0000 (+0000)
Subject: Fix wxCommandProcessor compilation with wxUSE_ACCEL==0.
X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/d98c269bb4f58f400208a61635cceddece8c6b4e

Fix wxCommandProcessor compilation with wxUSE_ACCEL==0.

Leave the accelerator strings empty in this case.

Closes #11783.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63614 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
---

diff --git a/src/common/cmdproc.cpp b/src/common/cmdproc.cpp
index 2ab9be0b0d..789e950f95 100644
--- a/src/common/cmdproc.cpp
+++ b/src/common/cmdproc.cpp
@@ -60,8 +60,11 @@ wxCommandProcessor::wxCommandProcessor(int maxCommands)
 #if wxUSE_MENUS
     m_commandEditMenu = NULL;
 #endif // wxUSE_MENUS
+
+#if wxUSE_ACCEL
     m_undoAccelerator = '\t' + wxAcceleratorEntry(wxACCEL_CTRL, 'Z').ToString();
     m_redoAccelerator = '\t' + wxAcceleratorEntry(wxACCEL_CTRL, 'Y').ToString();
+#endif // wxUSE_ACCEL
 
     m_lastSavedCommand =
     m_currentCommand = wxList::compatibility_iterator();