Implement wxWindow::ShowWithEffect() for wxOSX/Cocoa.
This version animates the window asynchronously and is being checked in just to preserve it in svn if we later decide to return to this semantics. It will be replaced by synchronous animation in the next commit. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@62304 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -73,6 +73,17 @@ public :
|
||||
virtual bool IsVisible() const ;
|
||||
virtual void SetVisibility(bool);
|
||||
|
||||
// we provide a static function which can be reused from
|
||||
// wxNonOwnedWindowCocoaImpl too
|
||||
static bool ShowViewOrWindowWithEffect(wxWindow *win,
|
||||
bool show,
|
||||
wxShowEffect effect,
|
||||
unsigned timeout);
|
||||
|
||||
virtual bool ShowWithEffect(bool show,
|
||||
wxShowEffect effect,
|
||||
unsigned timeout);
|
||||
|
||||
virtual void Raise();
|
||||
|
||||
virtual void Lower();
|
||||
@@ -190,7 +201,10 @@ public :
|
||||
void Raise();
|
||||
void Lower();
|
||||
bool Show(bool show);
|
||||
bool ShowWithEffect(bool show, wxShowEffect effect, unsigned timeout);
|
||||
|
||||
virtual bool ShowWithEffect(bool show,
|
||||
wxShowEffect effect,
|
||||
unsigned timeout);
|
||||
|
||||
void Update();
|
||||
bool SetTransparent(wxByte alpha);
|
||||
|
@@ -188,6 +188,13 @@ public :
|
||||
// set the visibility of this widget (maybe latent)
|
||||
virtual void SetVisibility( bool visible ) = 0;
|
||||
|
||||
virtual bool ShowWithEffect(bool WXUNUSED(show),
|
||||
wxShowEffect WXUNUSED(effect),
|
||||
unsigned WXUNUSED(timeout))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
virtual void Raise() = 0;
|
||||
|
||||
virtual void Lower() = 0;
|
||||
|
@@ -85,12 +85,6 @@ public:
|
||||
virtual void Lower();
|
||||
virtual bool Show( bool show = true );
|
||||
|
||||
virtual bool ShowWithEffect(wxShowEffect effect,
|
||||
unsigned timeout = 0) ;
|
||||
|
||||
virtual bool HideWithEffect(wxShowEffect effect,
|
||||
unsigned timeout = 0) ;
|
||||
|
||||
virtual void SetExtraStyle(long exStyle) ;
|
||||
|
||||
virtual bool SetBackgroundColour( const wxColour &colour );
|
||||
@@ -118,6 +112,10 @@ protected:
|
||||
virtual void DoMoveWindow(int x, int y, int width, int height);
|
||||
virtual void DoGetClientSize(int *width, int *height) const;
|
||||
|
||||
virtual bool OSXShowWithEffect(bool show,
|
||||
wxShowEffect effect,
|
||||
unsigned timeout);
|
||||
|
||||
wxNonOwnedWindowImpl* m_nowpeer ;
|
||||
|
||||
// wxWindowMac* m_macFocus ;
|
||||
|
@@ -63,6 +63,16 @@ public:
|
||||
virtual void Lower();
|
||||
|
||||
virtual bool Show( bool show = true );
|
||||
virtual bool ShowWithEffect(wxShowEffect effect,
|
||||
unsigned timeout = 0)
|
||||
{
|
||||
return OSXShowWithEffect(true, effect, timeout);
|
||||
}
|
||||
virtual bool HideWithEffect(wxShowEffect effect,
|
||||
unsigned timeout = 0)
|
||||
{
|
||||
return OSXShowWithEffect(false, effect, timeout);
|
||||
}
|
||||
|
||||
virtual bool IsShownOnScreen() const;
|
||||
|
||||
@@ -341,6 +351,11 @@ protected:
|
||||
virtual void DoSetToolTip( wxToolTip *tip );
|
||||
#endif
|
||||
|
||||
// common part of Show/HideWithEffect()
|
||||
virtual bool OSXShowWithEffect(bool show,
|
||||
wxShowEffect effect,
|
||||
unsigned timeout);
|
||||
|
||||
private:
|
||||
// common part of all ctors
|
||||
void Init();
|
||||
@@ -349,7 +364,6 @@ private:
|
||||
// AlwaysShowScrollbars()
|
||||
void DoUpdateScrollbarVisibility();
|
||||
|
||||
|
||||
wxDECLARE_NO_COPY_CLASS(wxWindowMac);
|
||||
DECLARE_EVENT_TABLE()
|
||||
};
|
||||
|
Reference in New Issue
Block a user