equal
deleted
inserted
replaced
|
1 /* |
|
2 * Copyright (c) 2002 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: This class is used to post events to the java. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 // INCLUDE FILES |
|
20 #include <logger.h> |
|
21 |
|
22 #include "cmmaevent.h" |
|
23 |
|
24 CMMAEvent::CMMAEvent(jobject aNotifyObject, |
|
25 jmethodID aHandleEventMethod, |
|
26 TDisposability /*aDisposable*/): |
|
27 iListenerObject(aNotifyObject), |
|
28 iHandleEventMethod(aHandleEventMethod) |
|
29 { |
|
30 } |
|
31 |
|
32 |
|
33 CMMAEvent::CMMAEvent(TDisposability /*aDisposable*/) |
|
34 { |
|
35 } |
|
36 |
|
37 |
|
38 void CMMAEvent::SetEventData(TInt aEventData) |
|
39 { |
|
40 iEventData = aEventData; |
|
41 } |
|
42 |
|
43 |
|
44 // from CJavaEvent |
|
45 void CMMAEvent::Dispatch(JNIEnv& aJni) |
|
46 { |
|
47 LOG1(EJavaMMAPI, EInfo, "MMA::CMMAEvent::Dispatch iEventData=%d", iEventData); |
|
48 LOG1(EJavaMMAPI, EInfo, "MMA::CMMAEvent::Dispatch iListenerObject=%d", iEventData); |
|
49 |
|
50 aJni.CallVoidMethod(iListenerObject, |
|
51 iHandleEventMethod, |
|
52 iEventData); |
|
53 } |
|
54 |
|
55 // END OF FILE |