]> git.saurik.com Git - wxWidgets.git/blame - contrib/samples/ogl/ogledit/ogledit.h
Regenerated makefiles
[wxWidgets.git] / contrib / samples / ogl / ogledit / ogledit.h
CommitLineData
1fc25a89
JS
1/////////////////////////////////////////////////////////////////////////////
2// Name: ogledit.h
3// Purpose: OGL sample
4// Author: Julian Smart
5// Modified by:
6// Created: 12/07/98
7// RCS-ID: $Id$
8// Copyright: (c) Julian Smart
2ba06d5a 9// Licence: wxWindows licence
1fc25a89
JS
10/////////////////////////////////////////////////////////////////////////////
11
ab7ce33c 12#if defined(__GNUG__) && !defined(__APPLE__)
1fc25a89
JS
13// #pragma interface
14#endif
15
16#ifndef _OGLSAMPLE_OGLEDIT_H_
17#define _OGLSAMPLE_OGLEDIT_H_
18
19#include <wx/docview.h>
34f7e40f 20#include <wx/deprecated/setup.h>
1fc25a89
JS
21
22// Define a new application
23class MyFrame;
24class EditorToolPalette;
25class MyApp: public wxApp
26{
27 public:
28 MyFrame *frame;
29 wxDocManager* myDocManager;
30
31 MyApp(void);
32 bool OnInit(void);
33 int OnExit(void);
34
35 // Palette stuff
36 EditorToolPalette *CreatePalette(wxFrame *parent);
37};
38
39DECLARE_APP(MyApp)
40
41// Define a new frame
42class MyCanvas;
43class MyFrame: public wxDocParentFrame
44{
45 DECLARE_CLASS(MyFrame)
46 public:
47 wxMenu *editMenu;
48
49 MyCanvas *canvas;
50 EditorToolPalette *palette;
51
52 MyFrame(wxDocManager *manager, wxFrame *parent, const wxString& title,
53 const wxPoint& pos = wxDefaultPosition,
54 const wxSize& size = wxDefaultSize,
55 long style = wxDEFAULT_FRAME_STYLE);
56
57 MyCanvas *CreateCanvas(wxView *view, wxFrame *parent);
58 void OnSize(wxSizeEvent& event);
59 void OnCloseWindow(wxCloseEvent& event);
60 void OnAbout(wxCommandEvent& event);
61
62DECLARE_EVENT_TABLE()
63};
64
65extern MyFrame *GetMainFrame(void);
66
67// Menu/undo/redo commands
68
69#define OGLEDIT_CUT 1
70#define OGLEDIT_ADD_SHAPE 2
71#define OGLEDIT_ADD_LINE 3
72#define OGLEDIT_EDIT_LABEL 4
73#define OGLEDIT_CHANGE_BACKGROUND_COLOUR 5
74
75#define OGLEDIT_ABOUT 100
76
77#endif
78 // _OGLSAMPLE_OGLEDIT_H_