]> git.saurik.com Git - wxWidgets.git/blobdiff - src/html/helpctrl.cpp
#11259: Correction for bad help button on OSX
[wxWidgets.git] / src / html / helpctrl.cpp
index 28e07592b7b2fa1bad8fafcfbc2db1be91cd1372..d1d37b38010397a0eb21fd43bbe886e26826b5ba 100644 (file)
@@ -115,12 +115,7 @@ void wxHtmlHelpController::SetTitleFormat(const wxString& title)
 // Find the top-most parent window
 wxWindow* wxHtmlHelpController::FindTopLevelWindow()
 {
-    wxWindow* parent = m_helpWindow;
-    while (parent && !parent->IsTopLevel())
-    {
-        parent = parent->GetParent();
-    }
-    return parent;
+    return wxGetTopLevelParent(m_helpWindow);
 }
 
 bool wxHtmlHelpController::AddBook(const wxFileName& book_file, bool show_wait_msg)
@@ -189,7 +184,7 @@ wxWindow* wxHtmlHelpController::CreateHelpWindow()
     {
         m_Config = wxConfigBase::Get(false);
         if (m_Config != NULL)
-            m_ConfigRoot = _T("wxWindows/wxHtmlHelpController");
+            m_ConfigRoot = wxT("wxWindows/wxHtmlHelpController");
     }
 
     if (m_FrameStyle & wxHF_DIALOG)