nonownedwnd.h 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. ///////////////////////////////////////////////////////////////////////////////
  2. // Name: wx/gtk/nonownedwnd.h
  3. // Purpose: wxGTK-specific wxNonOwnedWindow declaration.
  4. // Author: Vadim Zeitlin
  5. // Created: 2011-10-12
  6. // Copyright: (c) 2011 Vadim Zeitlin <vadim@wxwidgets.org>
  7. // Licence: wxWindows licence
  8. ///////////////////////////////////////////////////////////////////////////////
  9. #ifndef _WX_GTK_NONOWNEDWND_H_
  10. #define _WX_GTK_NONOWNEDWND_H_
  11. class wxNonOwnedWindowShapeImpl;
  12. // ----------------------------------------------------------------------------
  13. // wxNonOwnedWindow contains code common to wx{Popup,TopLevel}Window in wxGTK.
  14. // ----------------------------------------------------------------------------
  15. class WXDLLIMPEXP_CORE wxNonOwnedWindow : public wxNonOwnedWindowBase
  16. {
  17. public:
  18. wxNonOwnedWindow() { m_shapeImpl = NULL; }
  19. virtual ~wxNonOwnedWindow();
  20. // Overridden to actually set the shape when the window becomes realized.
  21. virtual void GTKHandleRealized();
  22. protected:
  23. virtual bool DoClearShape();
  24. virtual bool DoSetRegionShape(const wxRegion& region);
  25. #if wxUSE_GRAPHICS_CONTEXT
  26. virtual bool DoSetPathShape(const wxGraphicsPath& path);
  27. #endif // wxUSE_GRAPHICS_CONTEXT
  28. private:
  29. // If non-NULL, contains information about custom window shape.
  30. wxNonOwnedWindowShapeImpl* m_shapeImpl;
  31. wxDECLARE_NO_COPY_CLASS(wxNonOwnedWindow);
  32. };
  33. #endif // _WX_GTK_NONOWNEDWND_H_