2
* This file is part of the Code::Blocks IDE and licensed under the GNU Lesser General Public License, version 3
3
* http://www.gnu.org/licenses/lgpl-3.0.html
7
* Objects of type InfoWindow are autonomous and must therefore always be instantiated using operator new.
8
* In addition to this, InfoWindow does not have any non-static public class members.
10
* Since a (technically 100% correct) statement like
11
* new InfoWindow("foo", "bar");
12
* is unintuitive, confusing or even objective to some people, this class uses a variation of the "Named Constructor Idiom".
14
* InfoWindow::Display("foo", "bar");
15
* does the exact same thing as the above statement but looks a lot nicer.
23
#include <wx/string.h>
25
#include "settings.h" // DLLIMPORT
28
#include <wx/popupwin.h>
29
typedef wxPopupWindow wxInfoWindowBase;
31
#include "scrollingdialog.h"
32
typedef wxScrollingDialog wxInfoWindowBase;
39
class DLLIMPORT InfoWindow : public wxInfoWindowBase
41
InfoWindow(const wxString& title, const wxString& message, unsigned int delay, unsigned int hysteresis);
42
virtual ~InfoWindow();
43
void OnTimer(wxTimerEvent& e);
44
void OnMove(wxMouseEvent& e);
45
void OnClick(wxMouseEvent& e);
48
static void Display(const wxString& title, const wxString& message,
49
unsigned int delay = 5000, unsigned int hysteresis = 1);
59
std::list<wxString>::iterator my_message_iterator;