|
1 /* |
|
2 * Copyright (c) 2002 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 "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: Implementation of class CQosDialog. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 // INCLUDE FILES |
|
20 #include "QosDialog.h" |
|
21 #include "ConnDlgPlugin.h" |
|
22 #include "ExpiryTimer.h" |
|
23 |
|
24 #include <uikon/eiksrvui.h> |
|
25 |
|
26 |
|
27 // CONSTANTS |
|
28 #if defined(_DEBUG) |
|
29 _LIT( KErrNullPointer, "NULL pointer" ); |
|
30 #endif |
|
31 |
|
32 |
|
33 // ================= MEMBER FUNCTIONS ======================= |
|
34 // |
|
35 // --------------------------------------------------------- |
|
36 // CQosDialog::CQosDialog |
|
37 // --------------------------------------------------------- |
|
38 // |
|
39 CQosDialog::CQosDialog( CConnDlgQosPlugin* aPlugin, TBool& aBool ) |
|
40 : iPlugin( aPlugin ), |
|
41 iBool( aBool ) |
|
42 { |
|
43 } |
|
44 |
|
45 |
|
46 // --------------------------------------------------------- |
|
47 // CQosDialog::~CQosDialog |
|
48 // --------------------------------------------------------- |
|
49 // |
|
50 CQosDialog::~CQosDialog() |
|
51 { |
|
52 STATIC_CAST( CEikServAppUi*, |
|
53 CCoeEnv::Static()->AppUi() )->SuppressAppSwitching( EFalse ); |
|
54 delete iExpiryTimer; |
|
55 } |
|
56 |
|
57 |
|
58 // --------------------------------------------------------- |
|
59 // CQosDialog::PreLayoutDynInitL() |
|
60 // --------------------------------------------------------- |
|
61 // |
|
62 void CQosDialog::PreLayoutDynInitL() |
|
63 { |
|
64 CAknQueryDialog::PreLayoutDynInitL(); |
|
65 |
|
66 iExpiryTimer = CExpiryTimer::NewL( *this ); |
|
67 iExpiryTimer->Start(); |
|
68 |
|
69 STATIC_CAST( CEikServAppUi*, |
|
70 CCoeEnv::Static()->AppUi() )->SuppressAppSwitching( ETrue ); |
|
71 } |
|
72 |
|
73 |
|
74 // --------------------------------------------------------- |
|
75 // CQosDialog::OkToExitL |
|
76 // --------------------------------------------------------- |
|
77 // |
|
78 TBool CQosDialog::OkToExitL( TInt aButtonId ) |
|
79 { |
|
80 iBool = EFalse; |
|
81 if ( aButtonId == EAknSoftkeyYes || aButtonId == EAknSoftkeyDone || |
|
82 aButtonId == EAknSoftkeyOk ) |
|
83 { |
|
84 iBool = ETrue; |
|
85 } |
|
86 |
|
87 |
|
88 __ASSERT_DEBUG( iPlugin, User::Panic( KErrNullPointer, KErrNone ) ); |
|
89 iPlugin->CompleteL( KErrNone ); |
|
90 |
|
91 return ETrue; |
|
92 } |
|
93 |
|
94 void CQosDialog::HandleTimedOut() |
|
95 { |
|
96 TRAP_IGNORE( TryExitL(EAknSoftkeyCancel) ); |
|
97 } |
|
98 |
|
99 // End of File |