securitysettings/qtconfigutils/eapqtconfiginterface/src/eapqtvalidatorpacstorepasswordconfirm.cpp
equal
deleted
inserted
replaced
|
1 /* |
|
2 * Copyright (c) 2010 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 the License "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: |
|
15 * EAP method validator: PAC Store password confirmation |
|
16 * |
|
17 */ |
|
18 |
|
19 /* |
|
20 * %version: 3 % |
|
21 */ |
|
22 |
|
23 #include <HbEditorInterface> |
|
24 #include <HbLineEdit> |
|
25 #include "eapqtvalidatorpacstorepasswordconfirm.h" |
|
26 |
|
27 EapQtValidatorPacStorePasswordConfirm::EapQtValidatorPacStorePasswordConfirm() |
|
28 { |
|
29 } |
|
30 |
|
31 EapQtValidatorPacStorePasswordConfirm::~EapQtValidatorPacStorePasswordConfirm() |
|
32 { |
|
33 } |
|
34 |
|
35 EapQtValidator::Status EapQtValidatorPacStorePasswordConfirm::validate(QVariant value) |
|
36 { |
|
37 // TODO: implement this |
|
38 if (value == QVariant("1234")){ |
|
39 return EapQtValidator::StatusOk; |
|
40 } |
|
41 return EapQtValidator::StatusInvalid; |
|
42 } |
|
43 |
|
44 void EapQtValidatorPacStorePasswordConfirm::updateEditor(HbLineEdit *edit) |
|
45 { |
|
46 HbEditorInterface editInterface(edit); |
|
47 editInterface.setInputConstraints(HbEditorConstraintLatinAlphabetOnly); |
|
48 edit->setInputMethodHints(Qt::ImhNoPredictiveText | Qt::ImhPreferLowercase); |
|
49 // TODO: |
|
50 edit->setMaxLength(1000); |
|
51 } |