|
1 <?xml version="1.0" encoding="utf-8"?> |
|
2 <!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. --> |
|
3 <!-- This component and the accompanying materials are made available under the terms of the License |
|
4 "Eclipse Public License v1.0" which accompanies this distribution, |
|
5 and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". --> |
|
6 <!-- Initial Contributors: |
|
7 Nokia Corporation - initial contribution. |
|
8 Contributors: |
|
9 --> |
|
10 <!DOCTYPE concept |
|
11 PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd"> |
|
12 <concept id="GUID-A15EDC87-A6EF-40D8-AA78-B52449465FEA" xml:lang="en"><title>Receiving |
|
13 long-tap events</title><prolog><metadata><keywords/></metadata></prolog><conbody> |
|
14 <p>To receive long-tap events in your application using the Touch UI utilities |
|
15 API, follow the steps below:</p> |
|
16 <ol> |
|
17 <li id="GUID-4726E563-99AA-42E8-8AED-63BC9F176A83"><p>Link the Avkon libraries <codeph>avkon.lib</codeph> and <codeph>eikcoctl.lib</codeph> to |
|
18 the project file of the application.</p></li> |
|
19 <li id="GUID-95DE053E-A494-4C33-8FDB-125C77370EC1"><p>Provide an observer |
|
20 class that implements the <codeph>MAknLongTapDetectorCallBack</codeph> interface.</p></li> |
|
21 <li id="GUID-3E2B0808-78F8-48B6-8A58-B1A41C8DB5D6"><p>Create an instance of |
|
22 the class <codeph>CAknLongTapDetector</codeph> and pass pointer events to |
|
23 the long-tap detector.</p></li> |
|
24 <li id="GUID-C7E73EDE-6BC3-4E51-9E18-675FD3B32881"><p>Receive long-tap events |
|
25 through the observer interface.</p></li> |
|
26 <li id="GUID-04839B40-D170-484E-A4BC-C724FB715814"><p>Delete the long-tap |
|
27 detector.</p></li> |
|
28 </ol> |
|
29 <p>Use cases for the long-tap detector are shown in the figure below.</p> |
|
30 <fig id="GUID-1439445E-81AB-4AA4-86E0-00F53CD46D8F"> |
|
31 <title>Touch UI utilities API use cases</title> |
|
32 <image href="GUID-B4834A49-587E-41AD-B0D3-0622B173B2AD_d0e75730_href.png" scale="70" placement="inline"/> |
|
33 </fig> |
|
34 <p>To use the Touch UI utilities long-tap detector in your application, implement |
|
35 the following use cases.</p> |
|
36 <ul> |
|
37 <li><p><xref href="GUID-4102F39E-6215-44AD-9E30-6D8E86114D7D.dita">Creating the |
|
38 long-tap detector</xref></p></li> |
|
39 <li><p><xref href="GUID-C0C93B8A-C63C-424E-9C30-5D69C1578660.dita">Handling long-tap |
|
40 events</xref></p></li> |
|
41 <li><p><xref href="GUID-96228425-F2C8-4767-95AD-520C655B73C5.dita">Deleting long-tap |
|
42 detector</xref></p></li> |
|
43 </ul> |
|
44 <p>The following use cases are optional, allowing you to set additional properties |
|
45 for your long-tap detector.</p> |
|
46 <ul> |
|
47 <li><p><xref href="GUID-92281C52-4F2E-4D9A-9D5A-E0C5F0433339.dita">Enabling and |
|
48 disabling the long-tap detector</xref></p></li> |
|
49 <li><p><xref href="GUID-BEA5E4F1-B355-47A1-99DC-8E8EDB7B1CB3.dita">Setting the |
|
50 time after which the long-tap event is sent</xref></p></li> |
|
51 <li><p><xref href="GUID-BF3767E9-054E-4894-9216-00866FC9C3D8.dita">Setting the |
|
52 time before the long-tap animation starts</xref></p></li> |
|
53 </ul> |
|
54 </conbody></concept> |