29
|
1 |
/*
|
42
|
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 "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 |
*
|
|
16 |
*/
|
29
|
17 |
|
|
18 |
#ifndef BTCPUIBASEVIEW_H
|
|
19 |
#define BTCPUIBASEVIEW_H
|
|
20 |
|
|
21 |
#include <hbview.h>
|
|
22 |
#include <qglobal.h>
|
|
23 |
#include <cpbasesettingview.h>
|
31
|
24 |
#include <btsettingmodel.h>
|
|
25 |
#include <btdevicemodel.h>
|
29
|
26 |
|
|
27 |
/*!
|
|
28 |
\class BtUiBaseView
|
|
29 |
\brief the class is the base class for all views in btapplication.
|
|
30 |
|
|
31 |
*/
|
|
32 |
class BtCpUiBaseView : public CpBaseSettingView
|
|
33 |
{
|
|
34 |
Q_OBJECT
|
|
35 |
|
|
36 |
public:
|
|
37 |
|
|
38 |
virtual ~BtCpUiBaseView();
|
42
|
39 |
virtual void activateView( const QVariant& value, bool fromBackButton ) = 0;
|
29
|
40 |
virtual void deactivateView() = 0;
|
31
|
41 |
virtual void switchToPreviousView() = 0;
|
|
42 |
|
29
|
43 |
signals:
|
|
44 |
|
31
|
45 |
protected:
|
42
|
46 |
explicit BtCpUiBaseView(QGraphicsItem *parent = 0);
|
|
47 |
|
31
|
48 |
explicit BtCpUiBaseView(
|
|
49 |
BtSettingModel &settingModel,
|
|
50 |
BtDeviceModel &deviceModel,
|
|
51 |
QGraphicsItem *parent = 0);
|
|
52 |
|
29
|
53 |
virtual void setSoftkeyBack() = 0;
|
31
|
54 |
|
|
55 |
BtSettingModel &getSettingModel();
|
|
56 |
BtDeviceModel &getDeviceModel();
|
29
|
57 |
|
|
58 |
protected:
|
|
59 |
|
42
|
60 |
// owned
|
31
|
61 |
BtSettingModel *mSettingModel;
|
|
62 |
|
42
|
63 |
// owned
|
31
|
64 |
BtDeviceModel *mDeviceModel;
|
|
65 |
|
29
|
66 |
QGraphicsItem *mParent;
|
|
67 |
int mPreviousViewId;
|
|
68 |
|
|
69 |
Q_DISABLE_COPY(BtCpUiBaseView)
|
|
70 |
};
|
|
71 |
|
|
72 |
#endif // BTCPUIBASEVIEW_H
|