epoc32/include/mw/iclanimationdataprovider.h
author William Roberts <williamr@symbian.org>
Wed, 31 Mar 2010 12:33:34 +0100
branchSymbian3
changeset 4 837f303aceeb
parent 3 e1b950c65cb4
permissions -rw-r--r--
Current Symbian^3 public API header files (from PDK 3.0.h)
This is the epoc32/include tree with the "platform" subtrees removed, and
all but a selected few mbg and rsg files removed.
     1 // Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
     2 // All rights reserved.
     3 // This component and the accompanying materials are made available
     4 // under the terms of "Eclipse Public License v1.0"
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     7 //
     8 // Initial Contributors:
     9 // Nokia Corporation - initial contribution.
    10 //
    11 // Contributors:
    12 //
    13 // Description:
    14 //
    15 
    16 #ifndef __ICLANIMATIONDATAPROVIDER_H__
    17 #define __ICLANIMATIONDATAPROVIDER_H__
    18 
    19 #include <animationdataprovider.h>
    20 
    21 #include <e32std.h>
    22 #include <animationframe.h>
    23 #include <animationmixins.h>
    24 
    25 #ifndef SYMBIAN_ENABLE_SPLIT_HEADERS
    26 // For phase2 CICLAnimationDataProvider needs refactoring to convert it's derivation from
    27 // MICLAnimationDataLoaderObserver to having a CAnimationDataLoaderObserver* member
    28 #include <animationdataloaderobserver.h>
    29 #endif //SYMBIAN_ENABLE_SPLIT_HEADERS
    30 
    31 
    32 _LIT8(KBitmapAnimationDataType, "bitmap");
    33 
    34 class CICLAnimationDataLoader;
    35 
    36 /**
    37 Data provider for frame based animations.
    38 
    39 This data provider expects to be provided with a file which can be interpreted
    40 as an animation using the Image Conversion Library (ICL).  An example would be
    41 an animated GIF.  The default data type for this provider is "bitmap".
    42 
    43 @see CBitmapAnimator
    44 @publishedAll
    45 @released
    46 */
    47 class CICLAnimationDataProvider : public CAnimationDataProvider, public MICLAnimationDataLoaderObserver
    48 	{
    49 public:
    50     IMPORT_C CICLAnimationDataProvider();
    51     IMPORT_C ~CICLAnimationDataProvider();
    52     IMPORT_C void SetFileL(RFs & aFs, const TFileName& aFileName);
    53     IMPORT_C TPtrC8 DataType();
    54     virtual void StartL();
    55 protected:
    56 	IMPORT_C virtual void CICLAnimationDataProvider_Reserved1();
    57 	IMPORT_C virtual void CICLAnimationDataProvider_Reserved2();
    58 	// From CAnimationDataProvider
    59 	IMPORT_C virtual void CAnimationDataProvider_Reserved1();
    60 	IMPORT_C virtual void CAnimationDataProvider_Reserved2();
    61 private:
    62 	TInt iCICLAnimationDataProvider_Reserved;
    63 private:
    64     CAnimationFrame::THandles CurrentFrame() const;
    65     void DecodeImageL();
    66     void DataDeliveryL();
    67     void Reset();
    68     // From MICLAnimationDataLoaderObserver
    69     virtual void DataLoaderEventL(TDataLoaderEvent aEvent, TInt aError);
    70 private: 
    71 	CICLAnimationDataLoader* iDataLoader;
    72 	CAnimationFrame* iCurrentFrame;
    73 	TInt iFlags;
    74 	};
    75 
    76 #endif //__ICLANIMATIONDATAPROVIDER_H__
    77