Move wxTopLevelWindow::SetShape() down to wxNonOwnedWindow.
Also add wxNonOwnedWindow for wxMSW (which previously simply typedef'd it to wxWindow) and document this class now that it provides some user-visible functionality. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69364 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -12,15 +12,35 @@
|
||||
#ifndef _WX_NONOWNEDWND_H_
|
||||
#define _WX_NONOWNEDWND_H_
|
||||
|
||||
#include "wx/window.h"
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// wxNonOwnedWindow: a window that is not a child window of another one.
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
class wxNonOwnedWindowBase : public wxWindow
|
||||
{
|
||||
public:
|
||||
// Set the shape of the window to the given region.
|
||||
// Returns true if the platform supports this feature (and the
|
||||
// operation is successful.)
|
||||
virtual bool SetShape(const wxRegion& WXUNUSED(region)) { return false; }
|
||||
|
||||
};
|
||||
|
||||
#if defined(__WXDFB__)
|
||||
#include "wx/dfb/nonownedwnd.h"
|
||||
#elif defined(__WXMAC__)
|
||||
#include "wx/osx/nonownedwnd.h"
|
||||
#elif defined(__WXMSW__)
|
||||
#include "wx/msw/nonownedwnd.h"
|
||||
#else
|
||||
// other ports can derive both wxTLW and wxPopupWindow directly
|
||||
// from wxWindow:
|
||||
#include "wx/window.h"
|
||||
typedef wxWindow wxNonOwnedWindow;
|
||||
// No special class needed in other ports, they can derive both wxTLW and
|
||||
// wxPopupWindow directly from wxWindow and don't implement SetShape() (at
|
||||
// least at this level, wxGTK does do it in wxTLW).
|
||||
class wxNonOwnedWindow : public wxNonOwnedWindowBase
|
||||
{
|
||||
};
|
||||
#endif
|
||||
|
||||
#endif // _WX_NONOWNEDWND_H_
|
||||
|
Reference in New Issue
Block a user