]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/html/helpview/helpview.cpp
store CodeWarrior 5.3 projects as xml instead of binary projects
[wxWidgets.git] / samples / html / helpview / helpview.cpp
index 5992be07a6be6fc905d05009af90b3108c18393d..3e1e1b1d215e5eb10b1f533945805dc8bf0a320b 100644 (file)
@@ -10,7 +10,7 @@
 #endif
 
 // For compilers that support precompilation, includes "wx/wx.h".
-#include <wx/wxprec.h>
+#include "wx/wxprec.h"
 
 #ifdef __BORLANDC__
 #pragma hdrstop
@@ -48,7 +48,6 @@ class MyApp : public wxApp
 
     private:
         wxHtmlHelpController *help;
-        wxConfig* config;
 };
 
 
@@ -64,13 +63,15 @@ bool MyApp::OnInit()
     wxInitAllImageHandlers();
     wxFileSystem::AddHandler(new wxZipFSHandler);
 
-    config = new wxConfig("wxHTMLhelp");
+    SetVendorName("wxWindows");
+    SetAppName("wxHTMLHelp"); 
+    wxConfig::Get(); // create an instance
+
     help = new wxHtmlHelpController;
-    help -> UseConfig(config);
     
     if (argc < 2) {
-        wxLogError("Usage : helpview <helpfile> [<more helpfiles>]");
-        wxLogError("  helpfile may be .hhp, .zip or .htb");
+        wxLogError(wxT("Usage : helpview <helpfile> [<more helpfiles>]"));
+        wxLogError(wxT("  helpfile may be .hhp, .zip or .htb"));
         return FALSE;
     }
 
@@ -90,7 +91,7 @@ bool MyApp::OnInit()
 int MyApp::OnExit()
 {
     delete help;
-    delete config;
+    delete wxConfig::Set(NULL);
 
     return 0;
 }