Planeshift
pawsokbox.h
Go to the documentation of this file.
1 /*
2  * pawsokbox.h - Author: Andrew Craig
3  *
4  * Copyright (C) 2003 Atomic Blue (info@planeshift.it, http://www.atomicblue.org)
5  *
6  *
7  * This program is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU General Public License
9  * as published by the Free Software Foundation (version 2 of the License)
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  * You should have received a copy of the GNU General Public License
15  * along with this program; if not, write to the Free Software
16  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
17  *
18  */
19 
20 #ifndef PAWS_OK_BOX_HEADER
21 #define PAWS_OK_BOX_HEADER
22 
23 #include "pawswidget.h"
25 
30 // GUI BUTTONS
33 #define OK_BUTTON -30
34 
36 
39 class pawsOkBox : public pawsWidget
40 {
41 public:
42 
43  pawsOkBox();
44  pawsOkBox(const pawsOkBox &origin);
45  virtual ~pawsOkBox();
46 
47  bool OnButtonPressed(int mouseButton, int keyModifier, pawsWidget* widget);
48  void SetNotify(pawsWidget* widget);
49 
50  bool PostSetup();
51  void SetText(const char* text);
52 
53 
54 private:
55 
57 
58  pawsWidget* okButton;
59  pawsWidget* notify;
60 };
61 
63 
66 #endif
67 
68 
CREATE_PAWS_FACTORY(pawsOkBox)
The main base widget that all other widgets should inherit from.
Definition: pawswidget.h:116
This is an ok button window box.
Definition: pawsokbox.h:39
bool PostSetup()
This is called after the widget and all of it's children have been created.
void SetNotify(pawsWidget *widget)
void SetText(const char *text)
bool OnButtonPressed(int mouseButton, int keyModifier, pawsWidget *widget)
Called whenever a button is pressed.
virtual ~pawsOkBox()