]>
git.saurik.com Git - wxWidgets.git/blob - src/generic/busyinfo.cpp
1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: Information window when app is busy
4 // Author: Vaclav Slavik
5 // Copyright: (c) 1999 Vaclav Slavik
6 // Licence: wxWindows Licence
7 /////////////////////////////////////////////////////////////////////////////
10 #pragma implementation
13 #include <wx/wxprec.h>
23 #include "wx/busyinfo.h"
29 wxInfoFrame::wxInfoFrame(wxWindow
*parent
, const wxString
& message
)
30 : wxFrame(parent
, -1, "", wxPoint(0, 0), wxSize(400, 80), wxTHICK_FRAME
| wxSIMPLE_BORDER
| wxFRAME_TOOL_WINDOW
)
32 wxPanel
*p
= new wxPanel(this);
33 wxStaticText
*s
= new wxStaticText(p
, -1, message
, wxPoint(20, 20), wxSize(360, 40), wxALIGN_CENTER
);
35 p
-> SetCursor(*wxHOURGLASS_CURSOR
);
36 s
-> SetCursor(*wxHOURGLASS_CURSOR
);
42 wxBusyInfo::wxBusyInfo(const wxString
& message
) : wxObject()
44 m_InfoFrame
= new wxInfoFrame(NULL
, message
);
45 m_InfoFrame
-> Show(TRUE
);
47 m_InfoFrame
-> Refresh();
53 wxBusyInfo::~wxBusyInfo()
55 m_InfoFrame
-> Show(FALSE
);
56 m_InfoFrame
-> Close();