X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/b156929dd096cb0c0c46cd4a5747556dde228675..278d7ab4469db37ed930b66ebb2fd962133fe49d:/include/wx/mac/carbon/window.h diff --git a/include/wx/mac/carbon/window.h b/include/wx/mac/carbon/window.h index 43368f9e3e..aee0e91ffa 100644 --- a/include/wx/mac/carbon/window.h +++ b/include/wx/mac/carbon/window.h @@ -15,9 +15,9 @@ #include "wx/brush.h" #include "wx/dc.h" -class WXDLLEXPORT wxButton; -class WXDLLEXPORT wxScrollBar; -class WXDLLEXPORT wxTopLevelWindowMac; +class WXDLLIMPEXP_FWD_CORE wxButton; +class WXDLLIMPEXP_FWD_CORE wxScrollBar; +class WXDLLIMPEXP_FWD_CORE wxTopLevelWindowMac; class wxMacControl ; @@ -55,7 +55,8 @@ public: virtual void Lower(); virtual bool Show( bool show = true ); - virtual bool Enable( bool enable = true ); + virtual void DoEnable( bool enable ); + virtual void OnEnabled( bool enabled ); virtual void SetFocus(); @@ -65,7 +66,8 @@ public: const wxRect *rect = NULL ); virtual void Freeze(); virtual void Thaw(); - + virtual bool IsFrozen() const; + virtual void Update() ; virtual void ClearBackground(); @@ -82,9 +84,9 @@ public: int *externalLeading = NULL, const wxFont *theFont = NULL ) const; - +protected: virtual bool DoPopupMenu( wxMenu *menu, int x, int y ); - +public: virtual void SetScrollbar( int orient, int pos, int thumbVisible, int range, bool refresh = true ); virtual void SetScrollPos( int orient, int pos, bool refresh = true ); @@ -121,11 +123,10 @@ public: virtual WXWidget GetHandle() const; -#if WXWIN_COMPATIBILITY_2_4 - bool GetTransparentBackground() const { return m_backgroundTransparent; } - void SetTransparent(bool t = true) { m_backgroundTransparent = t; } -#endif - + virtual bool SetTransparent(wxByte alpha); + virtual bool CanSetTransparent(); + virtual wxByte GetTransparent() const ; + // event handlers // -------------- void OnSetFocus( wxFocusEvent& event ); @@ -138,6 +139,8 @@ public: bool AcceptsFocus() const; + virtual bool IsDoubleBuffered() const { return true; } + public: static long MacRemoveBordersFromStyle( long style ) ; @@ -211,8 +214,13 @@ public: // returns true if the grandchildren need to be clipped to the children's content area // (e.g., splitter windows) virtual bool MacClipGrandChildren() const { return false ; } - bool MacIsWindowScrollbar( const wxScrollBar* sb ) - { return (m_hScrollBar == sb || m_vScrollBar == sb) ; } + bool MacIsWindowScrollbar( const wxWindow* sb ) const + { return ((wxWindow*)m_hScrollBar == sb || (wxWindow*)m_vScrollBar == sb) ; } + virtual bool IsClientAreaChild(const wxWindow *child) const + { + return !MacIsWindowScrollbar(child) && + wxWindowBase::IsClientAreaChild(child); + } virtual void MacInstallEventHandler(WXWidget native) ; void MacPostControlCreate(const wxPoint& pos, const wxSize& size) ; @@ -290,6 +298,7 @@ protected: // insets of the mac control from the wx top left corner wxPoint m_macTopLeftInset ; wxPoint m_macBottomRightInset ; + wxByte m_macAlpha ; wxScrollBar* m_hScrollBar ; wxScrollBar* m_vScrollBar ; @@ -307,13 +316,8 @@ protected: void MacUpdateControlFont() ; void MacPropagateVisibilityChanged() ; - void MacPropagateEnabledStateChanged() ; void MacPropagateHiliteChanged() ; -#if WXWIN_COMPATIBILITY_2_4 - bool m_backgroundTransparent ; -#endif - // implement the base class pure virtuals virtual wxSize DoGetBestSize() const; virtual wxSize DoGetSizeFromClientSize( const wxSize & size ) const;