equal
deleted
inserted
replaced
|
1 /* |
|
2 * Copyright (c) 2008 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: Declares main application class. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef __DECODE_H |
|
20 #define __DECODE_H |
|
21 |
|
22 // INCLUDES |
|
23 #include "hidkeys.h" |
|
24 |
|
25 // FORWARD DECLARATIONS |
|
26 |
|
27 class CScanCodeStore; |
|
28 class CKeyboardLayout; |
|
29 class TDecodedKeyInfo; |
|
30 class TKeyEventInfo; |
|
31 |
|
32 // CLASS DECLARATION |
|
33 class CKeyboardDecoder : public CBase |
|
34 { |
|
35 public: |
|
36 static CKeyboardDecoder* NewL(); |
|
37 virtual ~CKeyboardDecoder(); |
|
38 |
|
39 void Event(const TKeyEventInfo& aKeyEvent, TDecodedKeyInfo &aDecodedKeys); |
|
40 void SetLayout(CKeyboardLayout* aLayout); |
|
41 void Reset(); |
|
42 |
|
43 private: |
|
44 CKeyboardDecoder(); |
|
45 void ConstructL(); |
|
46 |
|
47 void ProcessDeadKeys(TUint16 aUnicodeKey, TInt aHidKey, TInt aUsagePage, |
|
48 TDecodedKeyInfo &aDecodedKeys); |
|
49 TBool HandleRightAlt(const TKeyEventInfo &aEvent, |
|
50 TDecodedKeyInfo& aDecodedKeys); |
|
51 |
|
52 private: |
|
53 TTranslatedKey iDeadKey; |
|
54 CKeyboardLayout* iLayout; |
|
55 CScanCodeStore* iScanCodes; |
|
56 |
|
57 TBool iAltGrSequence; |
|
58 TInt iNumKeysDown; |
|
59 }; |
|
60 |
|
61 #endif |