equal
deleted
inserted
replaced
101 CKmdDlg* dialog = CKmdDlg::NewL(aNotifier, iValue1, iValue2, aInput, CAknQueryDialog::ENoTone); |
101 CKmdDlg* dialog = CKmdDlg::NewL(aNotifier, iValue1, iValue2, aInput, CAknQueryDialog::ENoTone); |
102 dialog->ExecuteLD(R_KMD_CRACK_SID_QUERY); |
102 dialog->ExecuteLD(R_KMD_CRACK_SID_QUERY); |
103 return dialog; |
103 return dialog; |
104 } |
104 } |
105 |
105 |
|
106 CVpnMultiLineDialog* CVpnDialogShower::GetSecurIdPinDlgL(MVpnNotifierCallback* aNotifier, const TDesC8& aInput) |
|
107 { |
|
108 iValue1 = KNullDesC; |
|
109 iValue2 = KNullDesC; |
|
110 CKmdDlg* dialog = CKmdDlg::NewL(aNotifier, iValue1, iValue2, aInput, CAknQueryDialog::ENoTone); |
|
111 dialog->SetResourceId(R_KMD_CRACK_SID_PIN_QUERY); |
|
112 dialog->ExecuteLD(R_KMD_CRACK_SID_PIN_QUERY); |
|
113 return dialog; |
|
114 } |
|
115 |
106 CVpnMultiLineDialog* CVpnDialogShower::GetSecurIdNextDlgL(MVpnNotifierCallback* aNotifier, const TDesC8& aInput) |
116 CVpnMultiLineDialog* CVpnDialogShower::GetSecurIdNextDlgL(MVpnNotifierCallback* aNotifier, const TDesC8& aInput) |
107 { |
117 { |
108 iValue1 = KNullDesC; |
118 iValue1 = KNullDesC; |
109 iValue2 = KNullDesC; |
119 iValue2 = KNullDesC; |
110 CKmdDlg* dialog = CKmdDlg::NewL(aNotifier, iValue1, iValue2, aInput, CAknQueryDialog::ENoTone); |
120 CKmdDlg* dialog = CKmdDlg::NewL(aNotifier, iValue1, iValue2, aInput, CAknQueryDialog::ENoTone); |
487 |
497 |
488 // CKmdDlg |
498 // CKmdDlg |
489 |
499 |
490 CKmdDlg::CKmdDlg(MVpnNotifierCallback* aNotifier, const TTone& aTone) : CVpnMultiLineDialog(aNotifier, aTone) |
500 CKmdDlg::CKmdDlg(MVpnNotifierCallback* aNotifier, const TTone& aTone) : CVpnMultiLineDialog(aNotifier, aTone) |
491 { |
501 { |
|
502 iResourceId = 0; |
492 } |
503 } |
493 |
504 |
494 CKmdDlg::CKmdDlg(MVpnNotifierCallback* aNotifier, const TDesC8& aInput, const TTone& aTone) |
505 CKmdDlg::CKmdDlg(MVpnNotifierCallback* aNotifier, const TDesC8& aInput, const TTone& aTone) |
495 : CVpnMultiLineDialog(aNotifier, aTone) |
506 : CVpnMultiLineDialog(aNotifier, aTone) |
496 { |
507 { |
497 iInput.Set(aInput); |
508 iInput.Set(aInput); |
|
509 iResourceId = 0; |
498 } |
510 } |
499 |
511 |
500 CKmdDlg* CKmdDlg::NewL(MVpnNotifierCallback* aNotifier, TDes& aData1, TDes& aData2, TTone aTone) |
512 CKmdDlg* CKmdDlg::NewL(MVpnNotifierCallback* aNotifier, TDes& aData1, TDes& aData2, TTone aTone) |
501 { |
513 { |
502 CKmdDlg* self = new (ELeave) CKmdDlg(aNotifier, aTone); |
514 CKmdDlg* self = new (ELeave) CKmdDlg(aNotifier, aTone); |
519 self->SetDataL(aData1, aData2); |
531 self->SetDataL(aData1, aData2); |
520 CleanupStack::Pop(); |
532 CleanupStack::Pop(); |
521 return self; |
533 return self; |
522 } |
534 } |
523 |
535 |
|
536 void CKmdDlg::SetResourceId(TInt aResourceId) |
|
537 { |
|
538 iResourceId = aResourceId; |
|
539 } |
524 void CKmdDlg::PreLayoutDynInitL() |
540 void CKmdDlg::PreLayoutDynInitL() |
525 { |
541 { |
526 SetMaxLengthOfFirstEditor(KMaxAuthenticationInputLength); |
542 if (iResourceId == R_KMD_CRACK_SID_PIN_QUERY) |
527 SetMaxLengthOfSecondEditor(KMaxAuthenticationInputLength); |
543 { |
528 |
544 CAknQueryControl* secondControl = static_cast<CAknQueryControl*>(Control(EEikCidPasswordConfirm)); |
|
545 CEikSecretEditor* secretEditor = static_cast<CEikSecretEditor*>(secondControl->ControlByLayoutOrNull( EMultiDataSecondSecEd )); |
|
546 secretEditor->SetDefaultInputMode(EAknEditorNumericInputMode); |
|
547 } |
529 CAknMultiLineDataQueryDialog::PreLayoutDynInitL(); |
548 CAknMultiLineDataQueryDialog::PreLayoutDynInitL(); |
530 |
549 |
531 CAknQueryControl* usernameControl = static_cast<CAknQueryControl*>(Control(EEikCidPassword)); |
550 CAknQueryControl* usernameControl = static_cast<CAknQueryControl*>(Control(EEikCidPassword)); |
532 |
551 |
533 if (iInput.Length() > 0) |
552 if (iInput.Length() > 0) |
538 CleanupStack::PopAndDestroy(); // usernameTextH16 |
557 CleanupStack::PopAndDestroy(); // usernameTextH16 |
539 if (Layout_Meta_Data::IsLandscapeOrientation()) |
558 if (Layout_Meta_Data::IsLandscapeOrientation()) |
540 { |
559 { |
541 MakeLeftSoftkeyVisible(ETrue); |
560 MakeLeftSoftkeyVisible(ETrue); |
542 } |
561 } |
|
562 } |
|
563 } |
|
564 |
|
565 void CKmdDlg::UpdateLeftSoftKeyL() |
|
566 { |
|
567 |
|
568 CAknQueryControl* secondControl = static_cast<CAknQueryControl*>(Control(EEikCidPasswordConfirm)); |
|
569 if (iResourceId == R_KMD_CRACK_SID_PIN_QUERY) |
|
570 { |
|
571 if ( (0 == secondControl->GetTextLength()) || |
|
572 (KMinSecurIDPINLength <= secondControl->GetTextLength()) ) |
|
573 MakeLeftSoftkeyVisible(ETrue); |
|
574 else |
|
575 MakeLeftSoftkeyVisible(EFalse); |
|
576 } |
|
577 else |
|
578 { |
|
579 if (0 != secondControl->GetTextLength()) |
|
580 MakeLeftSoftkeyVisible(ETrue); |
|
581 else |
|
582 MakeLeftSoftkeyVisible(EFalse); |
543 } |
583 } |
544 } |
584 } |
545 |
585 |
546 void CKmdDlg::SetInitialCurrentLine() |
586 void CKmdDlg::SetInitialCurrentLine() |
547 { |
587 { |