author | hgs |
Fri, 23 Jul 2010 12:55:58 +0300 | |
changeset 52 | a49bfe5190e4 |
parent 46 | bc5a64e5bc3c |
child 51 | f39ed5e045e0 |
child 65 | 2a5d4ab426d3 |
permissions | -rw-r--r-- |
37 | 1 |
/*! |
2 |
* Copyright (c) 2009 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: Buttons controller for storing and getting |
|
15 |
* buttons' states |
|
16 |
* |
|
17 |
*/ |
|
18 |
||
19 |
#ifndef PHONEUIQTBUTTONSCONTROLLER_H |
|
20 |
#define PHONEUIQTBUTTONSCONTROLLER_H |
|
21 |
||
22 |
#include <QObject> |
|
23 |
||
24 |
class PhoneUIQtButtonsController : public QObject |
|
25 |
{ |
|
26 |
Q_OBJECT |
|
27 |
||
28 |
public: |
|
29 |
||
30 |
enum PhoneButtonFlag |
|
31 |
{ |
|
45
6b911d05207e
Revision: 201023
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
37
diff
changeset
|
32 |
Hold = 0x02, // Hold |
6b911d05207e
Revision: 201023
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
37
diff
changeset
|
33 |
Ihf = 0x04, // Ihf |
6b911d05207e
Revision: 201023
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
37
diff
changeset
|
34 |
Wired = 0x08, // Wired |
6b911d05207e
Revision: 201023
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
37
diff
changeset
|
35 |
Btaa = 0x10, // Btaa |
6b911d05207e
Revision: 201023
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
37
diff
changeset
|
36 |
DisableJoin = 0x20, // Should join option be disabled |
6b911d05207e
Revision: 201023
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
37
diff
changeset
|
37 |
Conference = 0x40, // Conference call active |
6b911d05207e
Revision: 201023
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
37
diff
changeset
|
38 |
Mute = 0x80, // Mute |
6b911d05207e
Revision: 201023
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
37
diff
changeset
|
39 |
MultiCall = 0x100, // Multi call |
6b911d05207e
Revision: 201023
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
37
diff
changeset
|
40 |
FullConference = 0x200, // Max member count in conference |
46
bc5a64e5bc3c
Revision: 201025
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
45
diff
changeset
|
41 |
Outgoing = 0x400, // Outgoing call |
bc5a64e5bc3c
Revision: 201025
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
45
diff
changeset
|
42 |
IhfAsPushButton = 0x800, // Speaker as push button in bubble |
bc5a64e5bc3c
Revision: 201025
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
45
diff
changeset
|
43 |
BluetoothAvailable = 0x1000 // Bluetooth available |
37 | 44 |
}; |
45 |
Q_DECLARE_FLAGS(PhoneButtonFlags, PhoneButtonFlag) |
|
46 |
||
47 |
/** |
|
48 |
* Constructor |
|
49 |
*/ |
|
50 |
PhoneUIQtButtonsController (); |
|
51 |
||
52 |
/** |
|
53 |
* Destructor |
|
54 |
*/ |
|
55 |
virtual ~PhoneUIQtButtonsController (); |
|
56 |
||
57 |
/*! |
|
58 |
\fn void PhoneUIQtButtonsController::setButtonFlags (PhoneButtonFlags flag,bool set) |
|
59 |
||
60 |
This method is called when audio path or hold status is changed |
|
61 |
*/ |
|
62 |
void setButtonFlags (PhoneButtonFlags flag,bool set); |
|
63 |
||
64 |
/*! |
|
65 |
\fn bool PhoneUIQtButtonsController::getButtonFlags (PhoneButtonFlags flag) |
|
66 |
||
67 |
This method is called when audio path or hold status is enquired |
|
68 |
*/ |
|
69 |
inline bool getButtonFlags (PhoneButtonFlags flag) {return m_buttonFlags & flag;}; |
|
70 |
||
71 |
private: |
|
72 |
PhoneButtonFlags m_buttonFlags; |
|
73 |
}; |
|
74 |
||
75 |
Q_DECLARE_OPERATORS_FOR_FLAGS(PhoneUIQtButtonsController::PhoneButtonFlags) |
|
76 |
||
77 |
#endif // PHONEUIQTBUTTONSCONTROLLER_H |