michael@0: michael@0: /* michael@0: * Copyright 2006 The Android Open Source Project michael@0: * michael@0: * Use of this source code is governed by a BSD-style license that can be michael@0: * found in the LICENSE file. michael@0: */ michael@0: michael@0: michael@0: #ifndef SkAnimatorView_DEFINED michael@0: #define SkAnimatorView_DEFINED michael@0: michael@0: #include "SkView.h" michael@0: #include "SkAnimator.h" michael@0: michael@0: class SkAnimatorView : public SkView { michael@0: public: michael@0: SkAnimatorView(); michael@0: virtual ~SkAnimatorView(); michael@0: michael@0: SkAnimator* getAnimator() const { return fAnimator; } michael@0: michael@0: bool decodeFile(const char path[]); michael@0: bool decodeMemory(const void* buffer, size_t size); michael@0: bool decodeStream(SkStream* stream); michael@0: michael@0: protected: michael@0: // overrides michael@0: virtual bool onEvent(const SkEvent&); michael@0: virtual void onDraw(SkCanvas*); michael@0: virtual void onInflate(const SkDOM&, const SkDOM::Node*); michael@0: michael@0: private: michael@0: SkAnimator* fAnimator; michael@0: michael@0: typedef SkView INHERITED; michael@0: }; michael@0: michael@0: #endif