]> git.saurik.com Git - wxWidgets.git/commitdiff
wxUSE_PROGRESSDLG is optional.
authorWłodzimierz Skiba <abx@abx.art.pl>
Fri, 11 Jun 2004 14:45:09 +0000 (14:45 +0000)
committerWłodzimierz Skiba <abx@abx.art.pl>
Fri, 11 Jun 2004 14:45:09 +0000 (14:45 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@27747 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/html/helpfrm.cpp

index 9e952b723a043e373b07cd56ea78a5ee0b60e494..ece0c36d9a46443f487882c01fd55cb247c7b150 100644 (file)
@@ -715,21 +715,29 @@ bool wxHtmlHelpFrame::KeywordSearch(const wxString& keyword,
                                   m_SearchWholeWords->GetValue(),
                                   book);
 
+#if wxUSE_PROGRESSDLG
         wxProgressDialog progress(_("Searching..."),
                                   _("No matching page found yet"),
                                   status.GetMaxIndex(), this,
                                   wxPD_APP_MODAL | wxPD_CAN_ABORT | wxPD_AUTO_HIDE);
+#endif
 
         int curi;
         while (status.IsActive())
         {
             curi = status.GetCurIndex();
-            if (curi % 32 == 0 && progress.Update(curi) == FALSE)
+            if (curi % 32 == 0 
+#if wxUSE_PROGRESSDLG
+                && progress.Update(curi) == FALSE
+#endif
+               )
                 break;
             if (status.Search())
             {
                 foundstr.Printf(_("Found %i matches"), ++foundcnt);
+#if wxUSE_PROGRESSDLG
                 progress.Update(status.GetCurIndex(), foundstr);
+#endif
                 m_SearchList->Append(status.GetName(), status.GetContentsItem());
             }
         }