home *** CD-ROM | disk | FTP | other *** search
- /*
- * File: mdi.h
- * Purpose: MDI demo for wxWindows class library
- *
- * wxWindows 1.40
- * Copyright (c) 1993 Artificial Intelligence Applications Institute,
- * The University of Edinburgh
- *
- * Author: Julian Smart
- * Date: 18-4-93
- *
- * Permission to use, copy, modify, and distribute this software and its
- * documentation for any purpose is hereby granted without fee, provided
- * that the above copyright notice, author statement and this permission
- * notice appear in all copies of this software and related documentation.
- *
- * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, EXPRESS,
- * IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF
- * MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL THE ARTIFICIAL INTELLIGENCE APPLICATIONS INSTITUTE OR THE
- * UNIVERSITY OF EDINBURGH BE LIABLE FOR ANY SPECIAL, INCIDENTAL, INDIRECT OR
- * CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY DAMAGES WHATSOEVER RESULTING FROM
- * LOSS OF USE, DATA OR PROFITS, WHETHER OR NOT ADVISED OF THE POSSIBILITY OF
- * DAMAGE, AND ON ANY THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH
- * THE USE OR PERFORMANCE OF THIS SOFTWARE.
- */
-
- // Define a new application
- class MyApp: public wxApp
- {
- public:
- wxFrame *OnInit(void);
- };
-
- class MyCanvas: public wxCanvas
- {
- public:
- MyCanvas(wxFrame *frame, int x, int y, int w, int h);
- void OnPaint(void);
- void OnEvent(wxEvent& event);
- };
-
- // Define a new frame
- class MyFrame: public wxFrame
- {
- public:
- MyFrame(wxFrame *frame, char *title, int x, int y, int w, int h, int type);
- Bool OnClose(void);
- void OnMenuCommand(int id);
- };
-
- class MyChild: public wxFrame
- {
- public:
- MyChild(wxFrame *frame, char *title, int x, int y, int w, int h, int type);
- ~MyChild(void);
- Bool OnClose(void);
- void OnMenuCommand(int id);
- };
-
- void GenericOk(wxButton& but, wxEvent& event);
-
- #define MDI_QUIT 1
- #define MDI_NEW_WINDOW 2
- #define MDI_REFRESH 3
- #define MDI_CHILD_QUIT 4
- #define MDI_ABOUT 5
-