00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025 #ifndef __AKNTEXTSETTINGPAGE_H__
00026 #define __AKNTEXTSETTINGPAGE_H__
00027
00028
00029 #include <coecntrl.h>
00030 #include <coecobs.h>
00031
00032 #include <eikdef.h>
00033 #include <eikedwin.h>
00034 #include "aknsettingpage.h"
00035 #include "aknnumedwin.h"
00036
00043 class CAknEdwinSettingPage : public CAknSettingPage
00044 {
00045
00046 public:
00047
00053 IMPORT_C CEikEdwin* TextControl();
00054
00059 IMPORT_C void HandlePointerEventL(const TPointerEvent& aPointerEvent);
00060
00061 protected:
00067 IMPORT_C CAknEdwinSettingPage( TInt ResourceId );
00100 IMPORT_C CAknEdwinSettingPage(
00101 const TDesC* aSettingTitleText,
00102 TInt aSettingNumber,
00103 TInt aControlType,
00104 TInt aEditorResourceId,
00105 TInt aSettingPageResourceId );
00106
00107
00108
00109
00110 protected:
00115 virtual void SizeChanged() = 0;
00116
00124 IMPORT_C void Draw(const TRect& aRect) const;
00125
00126 private:
00130 IMPORT_C void* ExtensionInterface( TUid aInterface );
00131
00132 private:
00137 IMPORT_C virtual void CAknEdwinSettingPage_Reserved_1();
00138
00139 protected:
00143 TAknLayoutRect iEdwinLayoutRect;
00144
00148 TAknLayoutRect iHorizontalShadow;
00149
00153 TAknLayoutRect iVerticalShadow;
00154
00158 TAknLayoutRect iOutlineFrame;
00159
00160 private:
00161 TInt iSpare;
00162 };
00163
00169 class CAknTextSettingPageExtension;
00170
00171 class CAknTextSettingPage : public CAknEdwinSettingPage
00172 {
00173 public:
00174
00175
00176 enum TAknTextSettingPageFlags
00177 {
00178 EZeroLengthNotOffered = 0x0,
00179 EPutCursorAtEnd = 0x0,
00180 EZeroLengthAllowed = 0x0000001,
00181 ENoInitialSelection = 0x0000004,
00182 EPutCursorAtBeginning = 0x0000008,
00183
00184 EUseEdwinCursorAndSelectionFlags = 0x0000010,
00185 EPredictiveTextEntryPermitted = 0x0020
00186 };
00187
00188 public:
00197 IMPORT_C CAknTextSettingPage(TInt aResourceID, TDes& aText, TInt aTextSettingPageFlags = 0 );
00231 IMPORT_C CAknTextSettingPage( const TDesC* aSettingTitleText,
00232 TInt aSettingNumber,
00233 TInt aControlType,
00234 TInt aEditorResourceId,
00235 TInt aSettingPageResourceId,
00236 TDes& aText,
00237 TInt aTextSettingPageFlags = 0);
00238
00251 IMPORT_C virtual void ConstructL();
00252
00257 IMPORT_C void HandlePointerEventL(const TPointerEvent& aPointerEvent);
00258
00259
00260 protected:
00265 IMPORT_C virtual ~CAknTextSettingPage();
00266
00267
00268
00269
00270 protected:
00271
00277 IMPORT_C virtual void DynamicInitL();
00278
00283 IMPORT_C virtual void UpdateSettingL();
00284
00289 IMPORT_C virtual void AcceptSettingL();
00290
00296 IMPORT_C virtual void RestoreOriginalSettingL();
00297
00306 IMPORT_C virtual void HandleControlEventL(CCoeControl* aControl, TCoeEvent aEventType );
00307
00308
00314 IMPORT_C virtual void CheckAndSetDataValidity();
00315
00320 IMPORT_C virtual void UpdateTextL();
00321
00327 IMPORT_C virtual void UpdateCbaL();
00328
00339 IMPORT_C virtual TBool OkToExitL(TBool aAccept);
00340
00349 IMPORT_C TKeyResponse OfferKeyEventL( const TKeyEvent& aKeyEvent, TEventCode aType);
00350
00351
00355 private:
00356 IMPORT_C virtual void CAknSettingPage_Reserved_1();
00357 IMPORT_C virtual void CAknSettingPage_Reserved_2();
00358
00359
00360
00361
00362
00363 protected:
00364
00371 IMPORT_C virtual void SizeChanged();
00372
00380 IMPORT_C virtual void WriteInternalStateL(RWriteStream& aWriteStream) const;
00381
00382 private:
00386 IMPORT_C virtual void Reserved_2();
00387
00388 private:
00392 IMPORT_C void* ExtensionInterface( TUid aInterface );
00393
00398 IMPORT_C virtual void CAknEdwinSettingPage_Reserved_1();
00399
00400 private:
00401
00402 void RestartMultitapWaitTimer();
00403
00404 private:
00405 HBufC* iBackupText;
00406 TDes& iText;
00407 TInt iTextSettingPageFlags;
00408 CAknTextSettingPageExtension* iExtension;
00409 };
00410
00411
00416 class CAknIntegerSettingPage : public CAknEdwinSettingPage
00417 {
00418 public:
00419
00420
00421 enum TAknIntegerSettingPageFlags
00422 {
00423 EInvalidValueNotOffered = 0x0,
00424 EEmptyValueAllowed = 0x0000001,
00425 EInvalidValueAllowed = 0x0000002,
00426 ENoInitialSelection = 0x0000004,
00427 EPutCursorAtBeginning = 0x0000008
00428 };
00429
00430 public:
00431 IMPORT_C CAknIntegerSettingPage(TInt aResourceID, TInt& aValue, TInt aTextSettingPageFlags = 0 );
00464 IMPORT_C CAknIntegerSettingPage( const TDesC* aSettingTitleText,
00465 TInt aSettingNumber,
00466 TInt aControlType,
00467 TInt aEditorResourceId,
00468 TInt aSettingPageResourceId,
00469 TInt& aValue,
00470 TInt aIntegerSettingPageFlags = 0);
00471
00476 IMPORT_C virtual void ConstructL();
00477
00483 IMPORT_C CAknIntegerEdwin* IntegerEditorControl();
00484
00489 IMPORT_C void HandlePointerEventL(const TPointerEvent& aPointerEvent);
00490
00491
00492
00493
00494 protected:
00495
00501 IMPORT_C virtual void DynamicInitL();
00502
00507 IMPORT_C virtual void UpdateSettingL();
00508
00509
00514 IMPORT_C virtual void RestoreOriginalSettingL();
00515
00522 IMPORT_C virtual void CheckAndSetDataValidity();
00523
00530 IMPORT_C virtual void UpdateCbaL();
00531
00535 private:
00536 IMPORT_C virtual void CAknSettingPage_Reserved_1();
00537 IMPORT_C virtual void CAknSettingPage_Reserved_2();
00538
00539
00540
00541
00542
00543
00544
00545 protected:
00546
00558 IMPORT_C virtual void HandleControlEventL(CCoeControl* aControl, TCoeEvent aEventType );
00559
00560
00561
00562
00563 protected:
00564
00571 IMPORT_C virtual void SizeChanged();
00572
00573
00581 IMPORT_C virtual void WriteInternalStateL(RWriteStream& aWriteStream) const;
00582
00583 private:
00587 IMPORT_C virtual void Reserved_2();
00588
00589 private:
00593 IMPORT_C void* ExtensionInterface( TUid aInterface );
00594
00595 private:
00596
00601 IMPORT_C virtual void CAknEdwinSettingPage_Reserved_1();
00602
00603 private:
00604 TInt iBackupValue;
00605 TInt& iValue;
00606 TInt iIntegerSettingPageFlags;
00607 TInt iSpare_1;
00608 };
00609
00610
00611 #endif