|
1 /* |
|
2 * Copyright (c) 2007 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: Declaration of CSAnimSvgPluginBase class |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef SANIMSVGPLUGINBASE_H |
|
20 #define SANIMSVGPLUGINBASE_H |
|
21 |
|
22 #include "sanimimageplugin.h" |
|
23 #include <SVGRequestObserver.h> |
|
24 |
|
25 class CSvgEngineInterfaceImpl; |
|
26 class MSvgError; |
|
27 |
|
28 /** |
|
29 * Base class for different Start-up Image plug-ins that use SVGT engine. |
|
30 * |
|
31 * @lib None |
|
32 * @since S60 3.2 |
|
33 */ |
|
34 NONSHARABLE_CLASS( CSAnimSvgPluginBase ) |
|
35 : public CSAnimImagePlugin, |
|
36 public MSvgRequestObserver |
|
37 { |
|
38 |
|
39 public: |
|
40 |
|
41 /** |
|
42 * First phase constructor. |
|
43 * |
|
44 * @since S60 3.2 |
|
45 * |
|
46 * @param aConstructionParameters Construction parameters from ECom. |
|
47 * May NOT be NULL. |
|
48 */ |
|
49 CSAnimSvgPluginBase( TAny* aConstructionParameters ); |
|
50 |
|
51 /** |
|
52 * Destructor. |
|
53 * |
|
54 * @since S60 3.2 |
|
55 */ |
|
56 virtual ~CSAnimSvgPluginBase(); |
|
57 |
|
58 private: |
|
59 |
|
60 /** |
|
61 * From MSvgRequestObserver |
|
62 * |
|
63 * @since S60 3.2 |
|
64 */ |
|
65 virtual TBool ScriptCall( |
|
66 const TDesC& aScript, |
|
67 CSvgElementImpl* aCallerElement ); |
|
68 |
|
69 /** |
|
70 * From MSvgRequestObserver |
|
71 * |
|
72 * @since S60 3.2 |
|
73 */ |
|
74 virtual TInt FetchImage( |
|
75 const TDesC& aUri, |
|
76 RFs& aSession, |
|
77 RFile& aFileHandle ); |
|
78 |
|
79 /** |
|
80 * From MSvgRequestObserver |
|
81 * |
|
82 * @since S60 3.2 |
|
83 */ |
|
84 virtual TInt FetchFont( |
|
85 const TDesC& aUri, |
|
86 RFs& aSession, |
|
87 RFile& aFileHandle ); |
|
88 |
|
89 /** |
|
90 * From MSvgRequestObserver |
|
91 * |
|
92 * @since S60 3.2 |
|
93 */ |
|
94 virtual void GetSmilFitValue( TDes& aSmilValue ); |
|
95 |
|
96 /** |
|
97 * From MSvgRequestObserver |
|
98 * |
|
99 * @since S60 3.2 |
|
100 */ |
|
101 virtual void UpdatePresentation( const TInt32& aNoOfAnimation ); |
|
102 |
|
103 protected: |
|
104 |
|
105 /** |
|
106 * Convert SVG engine error code to one of the Symbian system-wide error codes. |
|
107 * |
|
108 * @since S60 3.2 |
|
109 * |
|
110 * @return One of the Symbian system-wide error codes or KErrNone. |
|
111 */ |
|
112 TInt SvgToSymbianErr( MSvgError* aError ); |
|
113 |
|
114 protected: // data |
|
115 |
|
116 /** Default font spec to give to the engine. */ |
|
117 TFontSpec iFontSpec; |
|
118 |
|
119 /** SVGT engine which generates the image / animation frames. Owned. May be NULL. */ |
|
120 CSvgEngineInterfaceImpl* iEngine; |
|
121 |
|
122 }; |
|
123 |
|
124 #endif // SANIMSVGPLUGINBASE_H |