home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / wxos2233.zip / wxOS2-2_3_3.zip / wxWindows-2.3.3 / utils / hhp2cached / hhp2cached.cpp next >
C/C++ Source or Header  |  2002-01-21  |  728b  |  43 lines

  1. /*
  2.   Converts hhp (HTML Help Workshop) files into cached
  3.   version for faster reading
  4.  
  5.   Usage: hhp2cached file.hhp [file2.hhp ...]
  6.  
  7. */
  8.  
  9. // For compilers that support precompilation, includes "wx/wx.h".
  10. #include "wx/wxprec.h"
  11.  
  12. #ifdef __BORLANDC__
  13. #pragma hdrstop
  14. #endif
  15.  
  16. #ifndef WX_PRECOMP
  17. #include "wx/wx.h"
  18. #endif
  19.  
  20. #include "wx/html/helpdata.h"
  21.  
  22.  
  23. class MyApp : public wxApp
  24. {
  25. public:
  26.     virtual bool OnInit();
  27. };
  28.  
  29. IMPLEMENT_APP(MyApp);
  30.  
  31. bool MyApp::OnInit()
  32. {
  33.     for (int i = 1; i < argc; i++)
  34.     {
  35.         wxHtmlHelpData data;
  36.         wxPrintf("Processing %s...\n", argv[i]);
  37.         data.SetTempDir(wxPathOnly(argv[i]));
  38.         data.AddBook(argv[i]);
  39.     }
  40.  
  41.     return FALSE;
  42. }
  43.