]> git.saurik.com Git - wxWidgets.git/blob - contrib/samples/animate/anitest.h
fix the sample icon (patch 1570974)
[wxWidgets.git] / contrib / samples / animate / anitest.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: anitest.cpp
3 // Purpose: anitest sample
4 // Author: Julian Smart
5 // Modified by:
6 // Created: 02/07/2001
7 // RCS-ID: $Id$
8 // Copyright: (c) Julian Smart
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
11
12 #include "wx/animate/animate.h"
13
14 // Define a new application
15 class MyApp : public wxApp
16 {
17 public:
18 bool OnInit();
19 };
20
21 class MyCanvas : public wxScrolledWindow
22 {
23 public:
24 MyCanvas(wxWindow *parent, const wxPoint& pos, const wxSize& size);
25 void OnPaint(wxPaintEvent& event);
26
27 private:
28
29 DECLARE_EVENT_TABLE()
30 };
31
32 // Define a new frame
33 class MyFrame : public wxFrame
34 {
35 public:
36
37 MyFrame(wxWindow *parent, const wxWindowID id, const wxString& title,
38 const wxPoint& pos, const wxSize& size, const long style);
39 ~MyFrame();
40
41 void OnAbout(wxCommandEvent& event);
42 void OnQuit(wxCommandEvent& event);
43
44 #if wxUSE_FILEDLG
45 void OnOpen(wxCommandEvent& event);
46 #endif // wxUSE_FILEDLG
47
48 MyCanvas* GetCanvas() const { return m_canvas; }
49 wxGIFAnimationCtrl* GetAnimationCtrl() const { return m_animationCtrl; }
50
51 #if 0
52 wxAnimationPlayer& GetPlayer() { return m_player; }
53 wxAnimationBase& GetAnimation() { return m_animation; }
54 #endif
55
56 DECLARE_EVENT_TABLE()
57
58 protected:
59 MyCanvas* m_canvas;
60 wxGIFAnimationCtrl* m_animationCtrl;
61 #if 0
62 wxAnimationPlayer m_player;
63 wxGIFAnimation m_animation;
64 #endif
65 };