|
1 /* |
|
2 * Copyright (c) 2002-2004 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: Wrapper class for Netscape plugin implementation. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef _XNNPPLUGINADAPTER_H |
|
21 #define _XNNPPLUGINADAPTER_H |
|
22 |
|
23 // INCLUDES |
|
24 #include "xncontroladapter.h" |
|
25 #include "xnnpplugincontroladapter.h" |
|
26 #include <npupp.h> |
|
27 |
|
28 |
|
29 // FORWARD DECLARATIONS |
|
30 class CXnNodePluginIf; |
|
31 class CXnNPPluginHandler; |
|
32 |
|
33 // CLASS DECLARATION |
|
34 |
|
35 /** |
|
36 * @ingroup group_xnnppluginfactory |
|
37 * |
|
38 * Wrapper class for Netscape plugin implementation. |
|
39 * |
|
40 * @lib xn3nppluginfactory.lib |
|
41 * @since Series 60 3.1 |
|
42 */ |
|
43 class CXnNPPluginAdapter : public CXnControlAdapter |
|
44 { |
|
45 public: // Constructors and destructor |
|
46 /** |
|
47 * Two-phased constructor. |
|
48 * @param aParent Parent of the adapter. |
|
49 * @param aNode Corresponding DOM-node |
|
50 */ |
|
51 static CXnNPPluginAdapter* NewL( CXnControlAdapter* aParent, CXnNodePluginIf& aNode ); |
|
52 |
|
53 /** |
|
54 * Destructor. |
|
55 */ |
|
56 virtual ~CXnNPPluginAdapter(); |
|
57 |
|
58 public: // Functions from base classes |
|
59 |
|
60 /** |
|
61 * From CCoeControl Responds to changes to the size and position |
|
62 * of the contents of this control. |
|
63 * @since Series 60 3.1 |
|
64 * @return void |
|
65 */ |
|
66 void SizeChanged(); |
|
67 |
|
68 /** |
|
69 * Enter power save mode. This is done when application goes to background or lights go off. |
|
70 * Derived classes should override this function and stop animations, timers etc. when the function is called. |
|
71 */ |
|
72 void DoEnterPowerSaveModeL(TModeEvent aEvent); |
|
73 |
|
74 /** |
|
75 * Exit power save mode. This is done when application comes to foreground or lights go on. |
|
76 * Derived classes should override this function and restart animations, timers etc. when the function is called. |
|
77 */ |
|
78 void DoExitPowerSaveModeL(TModeEvent aEvent); |
|
79 |
|
80 private: |
|
81 /** |
|
82 * C++ default constructor. |
|
83 */ |
|
84 CXnNPPluginAdapter(); |
|
85 |
|
86 /** |
|
87 * By default Symbian 2nd phase constructor is private. |
|
88 */ |
|
89 void ConstructL( CXnControlAdapter* aParent, CXnNodePluginIf& aNode ); |
|
90 |
|
91 TInt ConstructPluginL( CXnControlAdapter* aParent ); |
|
92 |
|
93 private: // Data |
|
94 //Node interface, not owned |
|
95 CXnNodePluginIf* iNode; |
|
96 //File server handle, owned |
|
97 RFs iFs; |
|
98 //CFileman instance, owned |
|
99 CFileMan* iFileman; |
|
100 //Stores the content file name, owned |
|
101 HBufC* iContentFile; |
|
102 //Pointer to plugin controller, owned |
|
103 CXnNPPluginControlAdapter* iPluginController; |
|
104 //Pointer to plugin handler, owned |
|
105 CXnNPPluginHandler* iPluginHandler; |
|
106 //Pointer to NPP instance, owned |
|
107 NPP iInstance; |
|
108 //Pointer to NPN functions, owned |
|
109 NPPluginFuncs* iPluginFuncs; |
|
110 }; |
|
111 |
|
112 #endif // _XNNPPLUGINADAPTER_H |
|
113 |
|
114 // End of File |