132b3986cSPhilippe Houdoin /* 205cf63e3SJohn Scipione * Copyright 2009 Vincent Duvert, vincent.duvert@free.fr 305cf63e3SJohn Scipione * Copyright 2014 Haiku, Inc. All rights reserved. 405cf63e3SJohn Scipione * 505cf63e3SJohn Scipione * Distributed under the terms of the MIT License. 605cf63e3SJohn Scipione * 705cf63e3SJohn Scipione * Authors: 8*1c56a03cSJohn Scipione * Vincent Duvert, vincent.duvert@free.fr 905cf63e3SJohn Scipione * John Scipione, jscipione@gmail.com 1032b3986cSPhilippe Houdoin */ 1132b3986cSPhilippe Houdoin #ifndef ICON_DISPLAY_H 1232b3986cSPhilippe Houdoin #define ICON_DISPLAY_H 1332b3986cSPhilippe Houdoin 143cbb1132SJohn Scipione 1532b3986cSPhilippe Houdoin #include <Rect.h> 1632b3986cSPhilippe Houdoin 170def0b0dSJohn Scipione 18*1c56a03cSJohn Scipione struct vector_icon; 1932b3986cSPhilippe Houdoin 2032b3986cSPhilippe Houdoin 2132b3986cSPhilippe Houdoin class BBitmap; 22*1c56a03cSJohn Scipione class BView; 2332b3986cSPhilippe Houdoin 2432b3986cSPhilippe Houdoin 2532b3986cSPhilippe Houdoin class IconDisplay { 2632b3986cSPhilippe Houdoin public: 2732b3986cSPhilippe Houdoin IconDisplay(); 2832b3986cSPhilippe Houdoin ~IconDisplay(); 2932b3986cSPhilippe Houdoin 300def0b0dSJohn Scipione void Run(vector_icon* icon, BRect frame); IsRunning()310def0b0dSJohn Scipione inline bool IsRunning() const { return fIsRunning; }; GetFrame()320def0b0dSJohn Scipione inline BRect GetFrame() const { return fFrame; }; 3332b3986cSPhilippe Houdoin 3432b3986cSPhilippe Houdoin void ClearOn(BView* view); 3532b3986cSPhilippe Houdoin void DrawOn(BView* view, uint32 delta); 3632b3986cSPhilippe Houdoin 3732b3986cSPhilippe Houdoin private: 3832b3986cSPhilippe Houdoin bool fIsRunning; 3932b3986cSPhilippe Houdoin uint8 fState; 4032b3986cSPhilippe Houdoin 4132b3986cSPhilippe Houdoin int32 fTicks; 4232b3986cSPhilippe Houdoin int32 fDelay; 4332b3986cSPhilippe Houdoin 4432b3986cSPhilippe Houdoin BBitmap* fBitmap; 4532b3986cSPhilippe Houdoin BRect fFrame; 4632b3986cSPhilippe Houdoin }; 4732b3986cSPhilippe Houdoin 483cbb1132SJohn Scipione 493cbb1132SJohn Scipione #endif // ICON_DISPLAY_H 50