]> git.saurik.com Git - wxWidgets.git/blame - samples/docvwmdi/docview.h
const added to GetBitmap it was my fault.
[wxWidgets.git] / samples / docvwmdi / docview.h
CommitLineData
2108f33a
JS
1/////////////////////////////////////////////////////////////////////////////
2// Name: docview.h
3// Purpose: Document/view demo
4// Author: Julian Smart
5// Modified by:
6// Created: 04/01/98
7// RCS-ID: $Id$
8// Copyright: (c) Julian Smart and Markus Holzem
9// Licence: wxWindows license
10/////////////////////////////////////////////////////////////////////////////
11
12#ifdef __GNUG__
13// #pragma interface "docview.h"
14#endif
15
16#ifndef __DOCVIEWSAMPLEH__
17#define __DOCVIEWSAMPLEH__
18
19#include "wx/docmdi.h"
20
21class wxDocManager;
22
23// Define a new application
24class MyApp: public wxApp
25{
26 public:
27 MyApp(void);
28 bool OnInit(void);
29 int OnExit(void);
30
9746a2ba 31 wxMDIChildFrame *CreateChildFrame(wxDocument *doc, wxView *view, bool isCanvas);
2108f33a
JS
32
33 protected:
34 wxDocManager* m_docManager;
35};
36
37DECLARE_APP(MyApp)
38
39// Define a new frame
40class MyCanvas;
41class MyFrame: public wxDocMDIParentFrame
42{
43 DECLARE_CLASS(MyFrame)
44 public:
45 wxMenu *editMenu;
46
47 MyFrame(wxDocManager *manager, wxFrame *frame, const wxString& title, const wxPoint& pos, const wxSize& size,
48 const long type);
49
50 void OnAbout(wxCommandEvent& event);
51 MyCanvas *CreateCanvas(wxView *view, wxFrame *parent);
52
53DECLARE_EVENT_TABLE()
54};
55
56extern MyFrame *GetMainFrame(void);
57
58#define DOCVIEW_CUT 1
59#define DOCVIEW_ABOUT 2
60
61extern bool singleWindowMode;
62
63#endif