]> git.saurik.com Git - wxWidgets.git/blob - include/wx/univ/custombgwin.h
wxDialogBase only has one ctor, so just do initialization in ctor instead of Init()
[wxWidgets.git] / include / wx / univ / custombgwin.h
1 ///////////////////////////////////////////////////////////////////////////////
2 // Name: wx/univ/custombgwin.h
3 // Purpose: wxUniv implementation of wxCustomBackgroundWindow.
4 // Author: Vadim Zeitlin
5 // Created: 2011-10-10
6 // Copyright: (c) 2011 Vadim Zeitlin <vadim@wxwidgets.org>
7 // Licence: wxWindows licence
8 ///////////////////////////////////////////////////////////////////////////////
9
10 #ifndef _WX_UNIV_CUSTOMBGWIN_H_
11 #define _WX_UNIV_CUSTOMBGWIN_H_
12
13 // ----------------------------------------------------------------------------
14 // wxCustomBackgroundWindow
15 // ----------------------------------------------------------------------------
16
17 template <class W>
18 class wxCustomBackgroundWindow : public W,
19 public wxCustomBackgroundWindowBase
20 {
21 public:
22 typedef W BaseWindowClass;
23
24 wxCustomBackgroundWindow() { }
25
26 protected:
27 virtual void DoSetBackgroundBitmap(const wxBitmap& bmp)
28 {
29 // We have support for background bitmap even at the base class level.
30 BaseWindowClass::SetBackground(bmp, wxALIGN_NOT, wxTILE);
31 }
32
33 wxDECLARE_NO_COPY_TEMPLATE_CLASS(wxCustomBackgroundWindow, W);
34 };
35
36 #endif // _WX_UNIV_CUSTOMBGWIN_H_