From 9c796670eb2d50b23e1794fb18032e578c32682f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20Kijewski?= Date: Tue, 10 Jan 2017 22:48:35 +0100 Subject: [PATCH] Fix wxWindowAccessible compilation with wxUSE_HELP==0 wxWindow::GetHelpTextAtPoint() can't be used in this case, add missing checks for wxUSE_HELP around it. --- src/common/wincmn.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/common/wincmn.cpp b/src/common/wincmn.cpp index f9cb00a5db..7d7b6b4755 100644 --- a/src/common/wincmn.cpp +++ b/src/common/wincmn.cpp @@ -3886,12 +3886,15 @@ wxAccStatus wxWindowAccessible::GetDescription(int WXUNUSED(childId), wxString* { wxCHECK( GetWindow() != NULL, wxACC_FAIL ); +#if wxUSE_HELP wxString ht(GetWindow()->GetHelpTextAtPoint(wxDefaultPosition, wxHelpEvent::Origin_Keyboard)); if (!ht.empty()) { *description = ht; return wxACC_OK; } +#endif // wxUSE_HELP + return wxACC_NOT_IMPLEMENTED; } @@ -3900,12 +3903,15 @@ wxAccStatus wxWindowAccessible::GetHelpText(int WXUNUSED(childId), wxString* hel { wxCHECK( GetWindow() != NULL, wxACC_FAIL ); +#if wxUSE_HELP wxString ht(GetWindow()->GetHelpTextAtPoint(wxDefaultPosition, wxHelpEvent::Origin_Keyboard)); if (!ht.empty()) { *helpText = ht; return wxACC_OK; } +#endif // wxUSE_HELP + return wxACC_NOT_IMPLEMENTED; }