]>
git.saurik.com Git - wxWidgets.git/blob - wxPython/contrib/activex/wxie/wxIEApp.cpp
   2                 wxActiveX Library Licence, Version 3 
   3                 ==================================== 
   5   Copyright (C) 2003 Lindsay Mathieson [, ...] 
   7   Everyone is permitted to copy and distribute verbatim copies 
   8   of this licence document, but changing it is not allowed. 
  10                        wxActiveX LIBRARY LICENCE 
  11      TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 
  13   This library is free software; you can redistribute it and/or modify it 
  14   under the terms of the GNU Library General Public Licence as published by 
  15   the Free Software Foundation; either version 2 of the Licence, or (at 
  16   your option) any later version. 
  18   This library is distributed in the hope that it will be useful, but 
  19   WITHOUT ANY WARRANTY; without even the implied warranty of 
  20   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Library 
  21   General Public Licence for more details. 
  23   You should have received a copy of the GNU Library General Public Licence 
  24   along with this software, usually in a file named COPYING.LIB.  If not, 
  25   write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, 
  26   Boston, MA 02111-1307 USA. 
  30   1. As a special exception, the copyright holders of this library give 
  31   permission for additional uses of the text contained in this release of 
  32   the library as licenced under the wxActiveX Library Licence, applying 
  33   either version 3 of the Licence, or (at your option) any later version of 
  34   the Licence as published by the copyright holders of version 3 of the 
  37   2. The exception is that you may use, copy, link, modify and distribute 
  38   under the user's own terms, binary object code versions of works based 
  41   3. If you copy code from files distributed under the terms of the GNU 
  42   General Public Licence or the GNU Library General Public Licence into a 
  43   copy of this library, as this licence permits, the exception does not 
  44   apply to the code that you add in this way.  To avoid misleading anyone as 
  45   to the status of such modified files, you must delete this exception 
  46   notice from such code and/or adjust the licensing conditions notice 
  49   4. If you write modifications of your own for this library, it is your 
  50   choice whether to permit this exception to apply to your modifications.  
  51   If you do not wish that, you must delete the exception notice from such 
  52   code and/or adjust the licensing conditions notice accordingly. 
  55 // ---------------------------------------------------------------------------- 
  57 // ---------------------------------------------------------------------------- 
  58 // For compilers that support precompilation, includes "wx/wx.h". 
  59 #if defined(__WXGTK__) || defined(__WXMOTIF__) 
  62 #include "wx/wxprec.h" 
  69 // Create a new application object: this macro will allow wxWindows to create 
  70 // the application object during program execution (it's better than using a 
  71 // static object for many reasons) and also declares the accessor function 
  72 // wxGetApp() which will return the reference of the right type (i.e. wxIEApp and 
  74 IMPLEMENT_APP(wxIEApp
) 
  76 // ============================================================================ 
  78 // ============================================================================ 
  80 // ---------------------------------------------------------------------------- 
  81 // the application class 
  82 // ---------------------------------------------------------------------------- 
  84 // 'Main program' equivalent: the program execution "starts" here 
  85 bool wxIEApp::OnInit() 
  87     // create the main application window 
  88     wxIEFrame 
*frame 
= new wxIEFrame(wxT("IE Test")); 
  90     // and show it (the frames, unlike simple controls, are not shown when 
  94     // success: wxApp::OnRun() will be called which will enter the main message 
  95     // loop and the application will run. If we returned FALSE here, the 
  96     // application would exit immediately.