2 * Copyright (c) 2002-2008 Nokia Corporation and/or its subsidiary(-ies).
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".
9 * Initial Contributors:
10 * Nokia Corporation - initial contribution.
18 #ifndef __AKNGLOBALNOTENOTIFY_H__
19 #define __AKNGLOBALNOTENOTIFY_H__
22 #include <AknNotify.h>
23 #include <AknNotifyStd.h>
28 * This class handles the global notes.
32 NONSHARABLE_CLASS(CAknGlobalNote) : public CAknNotifyBase
36 * Two-phased constructor.
37 * @return Pointer to new global note object.
39 IMPORT_C static CAknGlobalNote* NewL();
42 * Two-phased constructor.
43 * @return Pointer to new global note object.
45 IMPORT_C static CAknGlobalNote* NewLC();
50 IMPORT_C ~CAknGlobalNote();
53 * Enable or disable all text processing done by the dialog.
54 * This includes text wrapping, text truncation
55 * and reordering of bidirectional text.
57 * By default, it is enabled.
59 * If text processing is disabled, lines are broken only at explicit line
60 * end characters and they are not truncated, but drawn as long as they
61 * fit. Also, the dialog does not handle reordering of bidirectional text.
64 * @param aEnabled Enable or disable all text processing.
66 IMPORT_C void SetTextProcessing(TBool aEnabled);
69 * Displays the global note.
70 * @param aType Note type.
71 * @param aNoteText Note text.
74 IMPORT_C TInt ShowNoteL(TAknGlobalNoteType aType, const TDesC& aNoteText);
77 * Displays the global note.
78 * @param aStatus Reference to request status.
79 * @param aType Note type.
80 * @param aNoteText Note text.
83 IMPORT_C TInt ShowNoteL(
84 TRequestStatus& aStatus,
85 TAknGlobalNoteType aType,
86 const TDesC& aNoteText);
89 * Cancels the global note.
90 * @param aNoteId Note ID.
92 IMPORT_C void CancelNoteL(TInt aNoteId);
96 * @param aPriority An integer specifying the new priority.
98 IMPORT_C void SetPriority(TInt aPriority);
101 * Sets the softkey ID. (Not used)
102 * @param aId softkey ID
104 IMPORT_C void SetSoftkeys(TInt aId);
107 * Sets the graphic ID and the graphic mask ID.
108 * @param aId Graphic ID
109 * @param aMaskId Graphic mask ID.
111 IMPORT_C void SetGraphic(TInt aId, TInt aMaskId=-1);
114 * Sets the animation.
115 * @param aResourceId Resource ID of the animation.
117 IMPORT_C void SetAnimation(TInt aResourceId);
121 * @param aTone New tone.
123 IMPORT_C void SetTone(TInt aTone); // must be specified in avkon.hrh
126 * Internal, please do not use.
129 IMPORT_C static void DoGlobaNoteBufferL(
138 TBool aTextProcessingEnabled,
139 const TDesC& aNoteText,
146 static void DoGlobalNoteBufferL(
155 TBool aTextProcessingEnabled,
156 const TDesC& aNoteText,
158 TInt32 aPreallocatedGlobalNoteId
166 TAknGlobalNoteType aType,
167 const TDesC& aNoteText,
168 TInt aPreallocatedGlobalNoteId = 0);
171 IMPORT_C void CAknNotifyBase_Reserved();
180 TBool iTextProcessing;
185 CBufFlat *iCancelBuffer;
186 TPtrC8 iCancelBufferPtr;
188 // Not really used, but needed to prevent buffer handling errors.
189 TPckgBuf<SAknGlobalNoteReturnParams> iRetPckg;
192 #endif // __AKNGLOBALNOTENOTIFY_H__