~ubuntu-sdk-team/qtcreator-plugin-remotelinux/trunk

« back to all changes in this revision

Viewing changes to src/qnx/blackberrycheckdevicestatusstep.h

  • Committer: CI bot
  • Author(s): Benjamin Zeller
  • Date: 2014-06-16 10:28:43 UTC
  • mfrom: (4.2.4 remotelinux)
  • Revision ID: ps-jenkins@lists.canonical.com-20140616102843-8juvmjvzwlzsboyw
Migrating to Qt5.3 and QtC 3.1 

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/**************************************************************************
 
2
**
 
3
** Copyright (C) 2014 BlackBerry Limited. All rights reserved.
 
4
**
 
5
** Contact: BlackBerry (qt@blackberry.com)
 
6
** Contact: KDAB (info@kdab.com)
 
7
**
 
8
** This file is part of Qt Creator.
 
9
**
 
10
** Commercial License Usage
 
11
** Licensees holding valid commercial Qt licenses may use this file in
 
12
** accordance with the commercial license agreement provided with the
 
13
** Software or, alternatively, in accordance with the terms contained in
 
14
** a written agreement between you and Digia.  For licensing terms and
 
15
** conditions see http://qt.digia.com/licensing.  For further information
 
16
** use the contact form at http://qt.digia.com/contact-us.
 
17
**
 
18
** GNU Lesser General Public License Usage
 
19
** Alternatively, this file may be used under the terms of the GNU Lesser
 
20
** General Public License version 2.1 as published by the Free Software
 
21
** Foundation and appearing in the file LICENSE.LGPL included in the
 
22
** packaging of this file.  Please review the following information to
 
23
** ensure the GNU Lesser General Public License version 2.1 requirements
 
24
** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
 
25
**
 
26
** In addition, as a special exception, Digia gives you certain additional
 
27
** rights.  These rights are described in the Digia Qt LGPL Exception
 
28
** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
 
29
**
 
30
****************************************************************************/
 
31
 
 
32
#ifndef QNX_INTERNAL_BLACKBERRYCHECKDEVICESTATUSSTEP_H
 
33
#define QNX_INTERNAL_BLACKBERRYCHECKDEVICESTATUSSTEP_H
 
34
 
 
35
#include "blackberrydeviceconfiguration.h"
 
36
 
 
37
#include <projectexplorer/buildstep.h>
 
38
 
 
39
QT_BEGIN_NAMESPACE
 
40
class QEventLoop;
 
41
QT_END_NAMESPACE
 
42
 
 
43
namespace Qnx {
 
44
namespace Internal {
 
45
 
 
46
class BlackBerryDeviceInformation;
 
47
class BlackBerryCheckDeviceStatusStep : public ProjectExplorer::BuildStep
 
48
{
 
49
    Q_OBJECT
 
50
    friend class BlackBerryCheckDeviceStatusStepFactory;
 
51
 
 
52
public:
 
53
    explicit BlackBerryCheckDeviceStatusStep(ProjectExplorer::BuildStepList *bsl);
 
54
 
 
55
    bool init();
 
56
    void run(QFutureInterface<bool> &fi);
 
57
    ProjectExplorer::BuildStepConfigWidget *createConfigWidget();
 
58
 
 
59
    void raiseError(const QString &error);
 
60
    void raiseWarning(const QString &warning);
 
61
 
 
62
    bool fromMap(const QVariantMap &map);
 
63
    QVariantMap toMap() const;
 
64
 
 
65
    bool debugTokenCheckEnabled () const;
 
66
    bool runtimeCheckEnabled() const;
 
67
 
 
68
protected:
 
69
    BlackBerryCheckDeviceStatusStep(ProjectExplorer::BuildStepList *bsl,
 
70
                                    BlackBerryCheckDeviceStatusStep *bs);
 
71
 
 
72
protected slots:
 
73
    void checkDeviceInfo(int status);
 
74
    void emitOutputInfo();
 
75
 
 
76
    void enableDebugTokenCheck(bool enable);
 
77
    void enableRuntimeCheck(bool enable);
 
78
 
 
79
    bool handleVersionMismatch(const QString &runtimeVersion, const QString &apiLevelVersion);
 
80
 
 
81
private:
 
82
    BlackBerryDeviceInformation *m_deviceInfo;
 
83
    BlackBerryDeviceConfiguration::ConstPtr m_device;
 
84
    QEventLoop *m_eventLoop;
 
85
 
 
86
    bool m_runtimeCheckEnabled;
 
87
    bool m_debugTokenCheckEnabled;
 
88
};
 
89
 
 
90
} // namespace Internal
 
91
} // namespace Qnx
 
92
 
 
93
#endif // QNX_INTERNAL_BLACKBERRYCHECKDEVICESTATUSSTEP_H