mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-29 00:59:44 -06:00
Import r67258 of the wxWidgets trunk, which I expect will before
long become wxWidgets 2.9.2, which in turn is expected to be the last 2.9 release before the 3.0 stable release. Since the full wxWidgets distribution is rather large, I have imported only the parts that we use, on a subdirectory basis: art include/wx/*.* include/wx/aui include/wx/cocoa include/wx/generic include/wx/gtk include/wx/meta include/wx/msw include/wx/osx include/wx/persist include/wx/private include/wx/protocol include/wx/unix src/aui src/common src/generic src/gtk src/msw src/osx src/unix git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7380 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
126
Externals/wxWidgets3/include/wx/animate.h
vendored
Normal file
126
Externals/wxWidgets3/include/wx/animate.h
vendored
Normal file
@ -0,0 +1,126 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: wx/animate.h
|
||||
// Purpose: wxAnimation and wxAnimationCtrl
|
||||
// Author: Julian Smart and Guillermo Rodriguez Garcia
|
||||
// Modified by: Francesco Montorsi
|
||||
// Created: 13/8/99
|
||||
// RCS-ID: $Id: animate.h 56651 2008-11-02 22:16:14Z FM $
|
||||
// Copyright: (c) Julian Smart and Guillermo Rodriguez Garcia
|
||||
// Licence: wxWindows licence
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef _WX_ANIMATE_H_
|
||||
#define _WX_ANIMATE_H_
|
||||
|
||||
#include "wx/defs.h"
|
||||
|
||||
#if wxUSE_ANIMATIONCTRL
|
||||
|
||||
#include "wx/animdecod.h"
|
||||
#include "wx/control.h"
|
||||
#include "wx/timer.h"
|
||||
#include "wx/bitmap.h"
|
||||
|
||||
class WXDLLIMPEXP_FWD_ADV wxAnimation;
|
||||
|
||||
extern WXDLLIMPEXP_DATA_ADV(wxAnimation) wxNullAnimation;
|
||||
extern WXDLLIMPEXP_DATA_ADV(const char) wxAnimationCtrlNameStr[];
|
||||
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// wxAnimationBase
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
class WXDLLIMPEXP_ADV wxAnimationBase : public wxObject
|
||||
{
|
||||
public:
|
||||
wxAnimationBase() {}
|
||||
|
||||
virtual bool IsOk() const = 0;
|
||||
|
||||
// can be -1
|
||||
virtual int GetDelay(unsigned int frame) const = 0;
|
||||
|
||||
virtual unsigned int GetFrameCount() const = 0;
|
||||
virtual wxImage GetFrame(unsigned int frame) const = 0;
|
||||
virtual wxSize GetSize() const = 0;
|
||||
|
||||
virtual bool LoadFile(const wxString& name,
|
||||
wxAnimationType type = wxANIMATION_TYPE_ANY) = 0;
|
||||
virtual bool Load(wxInputStream& stream,
|
||||
wxAnimationType type = wxANIMATION_TYPE_ANY) = 0;
|
||||
|
||||
protected:
|
||||
DECLARE_ABSTRACT_CLASS(wxAnimationBase)
|
||||
};
|
||||
|
||||
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// wxAnimationCtrlBase
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
// do not autoresize to the animation's size when SetAnimation() is called
|
||||
#define wxAC_NO_AUTORESIZE (0x0010)
|
||||
|
||||
// default style does not include wxAC_NO_AUTORESIZE, that is, the control
|
||||
// auto-resizes by default to fit the new animation when SetAnimation() is called
|
||||
#define wxAC_DEFAULT_STYLE (wxBORDER_NONE)
|
||||
|
||||
class WXDLLIMPEXP_ADV wxAnimationCtrlBase : public wxControl
|
||||
{
|
||||
public:
|
||||
wxAnimationCtrlBase() { }
|
||||
|
||||
// public API
|
||||
virtual bool LoadFile(const wxString& filename,
|
||||
wxAnimationType type = wxANIMATION_TYPE_ANY) = 0;
|
||||
virtual bool Load(wxInputStream& stream,
|
||||
wxAnimationType type = wxANIMATION_TYPE_ANY) = 0;
|
||||
|
||||
virtual void SetAnimation(const wxAnimation &anim) = 0;
|
||||
virtual wxAnimation GetAnimation() const = 0;
|
||||
|
||||
virtual bool Play() = 0;
|
||||
virtual void Stop() = 0;
|
||||
|
||||
virtual bool IsPlaying() const = 0;
|
||||
|
||||
virtual void SetInactiveBitmap(const wxBitmap &bmp);
|
||||
|
||||
// always return the original bitmap set in this control
|
||||
wxBitmap GetInactiveBitmap() const
|
||||
{ return m_bmpStatic; }
|
||||
|
||||
protected:
|
||||
// the inactive bitmap as it was set by the user
|
||||
wxBitmap m_bmpStatic;
|
||||
|
||||
// the inactive bitmap currently shown in the control
|
||||
// (may differ in the size from m_bmpStatic)
|
||||
wxBitmap m_bmpStaticReal;
|
||||
|
||||
// updates m_bmpStaticReal from m_bmpStatic if needed
|
||||
virtual void UpdateStaticImage();
|
||||
|
||||
// called by SetInactiveBitmap
|
||||
virtual void DisplayStaticImage() = 0;
|
||||
|
||||
private:
|
||||
DECLARE_ABSTRACT_CLASS(wxAnimationCtrlBase)
|
||||
};
|
||||
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// include the platform-specific version of the wxAnimationCtrl class
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
#if defined(__WXGTK20__) && !defined(__WXUNIVERSAL__)
|
||||
#include "wx/gtk/animate.h"
|
||||
#else
|
||||
#include "wx/generic/animate.h"
|
||||
#endif
|
||||
|
||||
#endif // wxUSE_ANIMATIONCTRL
|
||||
|
||||
#endif // _WX_ANIMATE_H_
|
Reference in New Issue
Block a user