]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/html/about/about.cpp
Make a couple virtuals protected so they can be overridden.
[wxWidgets.git] / samples / html / about / about.cpp
index 282eb378353b9a0cfb91e46757e0d9b63cefbb9d..22ebb1555caaa9876929eee59eeb13e2854c8ae0 100644 (file)
@@ -1,6 +1,12 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        test.cpp
-// Purpose:     wxHtml testing example
+// Name:        about.cpp
+// Purpose:     wxHtml sample: about dialog test
+// Author:      ?
+// Modified by:
+// Created:     ?
+// RCS-ID:      $Id$
+// Copyright:   (c) wxWidgets team
+// Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
 // For compilers that support precompilation, includes "wx/wx.h".
 #include "wx/wxhtml.h"
 #include "wx/statline.h"
 
+#ifndef wxHAS_IMAGES_IN_RESOURCES
+    #include "../../sample.xpm"
+#endif
+
+
 // ----------------------------------------------------------------------------
 // private classes
 // ----------------------------------------------------------------------------
@@ -85,6 +96,9 @@ IMPLEMENT_APP(MyApp)
 // `Main program' equivalent: the program execution "starts" here
 bool MyApp::OnInit()
 {
+    if ( !wxApp::OnInit() )
+        return false;
+
     // we use a PNG image in our HTML page
     wxImage::AddHandler(new wxPNGHandler);
 
@@ -106,6 +120,8 @@ bool MyApp::OnInit()
 MyFrame::MyFrame(const wxString& title)
        : wxFrame((wxFrame *)NULL, wxID_ANY, title)
 {
+    SetIcon(wxICON(sample));
+
     // create a menu bar
     wxMenu *menuFile = new wxMenu;