]>
git.saurik.com Git - wxWidgets.git/blob - contrib/applet/applet.cpp
1 /****************************************************************************
3 * wxWindows HTML Applet Package
5 * Copyright (C) 1991-2001 SciTech Software, Inc.
8 * ======================================================================
9 * |REMOVAL OR MODIFICATION OF THIS HEADER IS STRICTLY PROHIBITED BY LAW|
11 * |This copyrighted computer code is a proprietary trade secret of |
12 * |SciTech Software, Inc., located at 505 Wall Street, Chico, CA 95928 |
13 * |USA (www.scitechsoft.com). ANY UNAUTHORIZED POSSESSION, USE, |
14 * |VIEWING, COPYING, MODIFICATION OR DISSEMINATION OF THIS CODE IS |
15 * |STRICTLY PROHIBITED BY LAW. Unless you have current, express |
16 * |written authorization from SciTech to possess or use this code, you |
17 * |may be subject to civil and/or criminal penalties. |
19 * |If you received this code in error or you would like to report |
20 * |improper use, please immediately contact SciTech Software, Inc. at |
23 * |REMOVAL OR MODIFICATION OF THIS HEADER IS STRICTLY PROHIBITED BY LAW|
24 * ======================================================================
29 * Description: Main wxApplet class implementation
31 ****************************************************************************/
33 // For compilers that support precompilation
34 #include "wx/wxprec.h"
36 // Include private headers
37 #include "wx/applet/applet.h"
39 /*------------------------- Implementation --------------------------------*/
41 // Empty event handler. We include this event handler simply so that
42 // sub-classes of wxApplet can reference wxApplet in the event tables
43 // that they create as necessary.
44 BEGIN_EVENT_TABLE(wxApplet
, wxPanel
)
45 EVT_ERASE_BACKGROUND(wxApplet::OnEraseBackground
)
48 // Implement the abstract class functions
49 IMPLEMENT_ABSTRACT_CLASS(wxApplet
, wxPanel
);
51 /****************************************************************************
53 Psuedo virtual constructor for the wxApplet class.
54 ****************************************************************************/
55 bool wxApplet::Create(
56 wxHtmlAppletWindow
*parent
,
60 bool ret
= wxPanel::Create(parent
, -1, wxDefaultPosition
, size
, style
);
67 /****************************************************************************
69 Destructor for the wxApplet class.
70 ****************************************************************************/
73 m_Parent
->RemoveApplet(this);
76 /****************************************************************************
78 Special handler for background erase messages. We do nothing in here which
79 causes the background to not be erased which is exactly what we want. All
80 the wxApplet classes display over an HTML window, so we want the HTML
81 background to show through.
82 ****************************************************************************/
83 void wxApplet::OnEraseBackground(wxEraseEvent
&)