fixed a 'variable could be used uninitialized' warning
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@23470 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -740,21 +740,29 @@ bool wxHtmlHelpFrame::KeywordSearch(const wxString& keyword,
|
|||||||
if (foundcnt)
|
if (foundcnt)
|
||||||
{
|
{
|
||||||
wxHtmlContentsItem *it;
|
wxHtmlContentsItem *it;
|
||||||
if (mode == wxHELP_SEARCH_ALL)
|
switch ( mode )
|
||||||
{
|
{
|
||||||
it = (wxHtmlContentsItem*) m_SearchList->GetClientData(0);
|
default:
|
||||||
}
|
wxFAIL_MSG( _T("unknown help search mode") );
|
||||||
else if (mode == wxHELP_SEARCH_INDEX)
|
// fall back
|
||||||
{
|
|
||||||
it = (wxHtmlContentsItem*) m_IndexList->GetClientData(0);
|
case wxHELP_SEARCH_ALL:
|
||||||
|
it = (wxHtmlContentsItem*) m_SearchList->GetClientData(0);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case wxHELP_SEARCH_INDEX:
|
||||||
|
it = (wxHtmlContentsItem*) m_IndexList->GetClientData(0);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (it)
|
if (it)
|
||||||
{
|
{
|
||||||
m_HtmlWin->LoadPage(it->GetFullPath());
|
m_HtmlWin->LoadPage(it->GetFullPath());
|
||||||
NotifyPageChanged();
|
NotifyPageChanged();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return (foundcnt > 0);
|
|
||||||
|
return foundcnt > 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxHtmlHelpFrame::CreateContents()
|
void wxHtmlHelpFrame::CreateContents()
|
||||||
|
Reference in New Issue
Block a user