]>
git.saurik.com Git - wxWidgets.git/blob - interface/splash.h
1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: interface of wxSplashScreen
4 // Author: wxWidgets team
6 // Licence: wxWindows license
7 /////////////////////////////////////////////////////////////////////////////
13 wxSplashScreen shows a window with a thin border, displaying a bitmap
15 application. Show it in application initialisation, and then either explicitly
17 it or let it time-out.
23 if (bitmap.LoadFile("splash16.png", wxBITMAP_TYPE_PNG))
25 wxSplashScreen* splash = new wxSplashScreen(bitmap,
26 wxSPLASH_CENTRE_ON_SCREEN|wxSPLASH_TIMEOUT,
27 6000, @NULL, -1, wxDefaultPosition, wxDefaultSize,
28 wxBORDER_SIMPLE|wxSTAY_ON_TOP);
36 class wxSplashScreen
: public wxFrame
40 Construct the splash screen passing a bitmap, a style, a timeout, a window id,
42 and size, and a window style.
43 @a splashStyle is a bitlist of some of the following:
44 wxSPLASH_CENTRE_ON_PARENT
45 wxSPLASH_CENTRE_ON_SCREEN
49 @a milliseconds is the timeout in milliseconds.
51 wxSplashScreen(const wxBitmap
& bitmap
, long splashStyle
,
55 const wxPoint
& pos
= wxDefaultPosition
,
56 const wxSize
& size
= wxDefaultSize
,
57 long style
= wxBORDER_SIMPLE
|wxFRAME_NO_TASKBAR
|wxSTAY_ON_TOP
);
60 Destroys the splash screen.
65 Returns the splash style (see wxSplashScreen() for
68 long GetSplashStyle() const;
71 Returns the window used to display the bitmap.
73 wxSplashScreenWindow
* GetSplashWindow() const;
76 Returns the timeout in milliseconds.
78 int GetTimeout() const;
81 Reimplement this event handler if you want to set an application variable on
82 window destruction, for example.
84 void OnCloseWindow(wxCloseEvent
& event
);