2012-07-03 16:57:44 +03:00
|
|
|
/**************************************************************************
|
|
|
|
**
|
|
|
|
** This file is part of Qt Creator
|
|
|
|
**
|
|
|
|
** Copyright (c) 2012 BogDan Vatra <bog_dan_ro@yahoo.com>
|
|
|
|
**
|
2012-07-19 12:26:56 +02:00
|
|
|
** Contact: http://www.qt-project.org/
|
2012-07-03 16:57:44 +03:00
|
|
|
**
|
|
|
|
**
|
|
|
|
** GNU Lesser General Public License Usage
|
|
|
|
**
|
|
|
|
** This file may be used under the terms of the GNU Lesser General Public
|
|
|
|
** License version 2.1 as published by the Free Software Foundation and
|
|
|
|
** appearing in the file LICENSE.LGPL included in the packaging of this file.
|
|
|
|
** Please review the following information to ensure the GNU Lesser General
|
|
|
|
** Public License version 2.1 requirements will be met:
|
|
|
|
** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
|
|
|
|
**
|
|
|
|
** In addition, as a special exception, Nokia gives you certain additional
|
|
|
|
** rights. These rights are described in the Nokia Qt LGPL Exception
|
|
|
|
** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
|
|
|
|
**
|
|
|
|
** Other Usage
|
|
|
|
**
|
|
|
|
** Alternatively, this file may be used in accordance with the terms and
|
|
|
|
** conditions contained in a signed written agreement between you and Nokia.
|
|
|
|
**
|
|
|
|
**
|
|
|
|
**************************************************************************/
|
|
|
|
|
|
|
|
#include "androiddevice.h"
|
|
|
|
#include "androidconstants.h"
|
|
|
|
|
|
|
|
#include <QCoreApplication>
|
|
|
|
|
2012-07-26 17:41:52 +02:00
|
|
|
using namespace ProjectExplorer;
|
|
|
|
|
2012-07-03 16:57:44 +03:00
|
|
|
namespace Android {
|
|
|
|
namespace Internal {
|
|
|
|
|
2012-07-26 17:41:52 +02:00
|
|
|
AndroidDevice::AndroidDevice()
|
|
|
|
: IDevice(Core::Id(Constants::ANDROID_DEVICE_TYPE),
|
2012-07-25 17:10:20 +02:00
|
|
|
IDevice::AutoDetected,
|
|
|
|
IDevice::Hardware,
|
2012-07-03 16:57:44 +03:00
|
|
|
Core::Id(Constants::ANDROID_DEVICE_ID))
|
|
|
|
{
|
2012-07-27 15:43:00 +02:00
|
|
|
setDisplayName(QCoreApplication::translate("Android::Internal::AndroidDevice", "Run on Android"));
|
2012-07-03 16:57:44 +03:00
|
|
|
setDeviceState(DeviceReadyToUse);
|
|
|
|
}
|
|
|
|
|
2012-07-26 17:41:52 +02:00
|
|
|
AndroidDevice::AndroidDevice(const AndroidDevice &other)
|
|
|
|
: ProjectExplorer::IDevice(other)
|
2012-07-03 16:57:44 +03:00
|
|
|
{ }
|
|
|
|
|
|
|
|
|
2012-07-26 17:41:52 +02:00
|
|
|
IDevice::DeviceInfo AndroidDevice::deviceInformation() const
|
2012-07-03 16:57:44 +03:00
|
|
|
{
|
2012-07-26 17:41:52 +02:00
|
|
|
return IDevice::DeviceInfo();
|
2012-07-03 16:57:44 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
QString AndroidDevice::displayType() const
|
|
|
|
{
|
2012-07-27 15:43:00 +02:00
|
|
|
return QCoreApplication::translate("Android::Internal::AndroidDevice", "Android");
|
2012-07-03 16:57:44 +03:00
|
|
|
}
|
|
|
|
|
2012-07-26 17:41:52 +02:00
|
|
|
IDeviceWidget *AndroidDevice::createWidget()
|
2012-07-03 16:57:44 +03:00
|
|
|
{
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
QList<Core::Id> AndroidDevice::actionIds() const
|
|
|
|
{
|
|
|
|
return QList<Core::Id>()<<Core::Id(Constants::ANDROID_DEVICE_ID);
|
|
|
|
}
|
|
|
|
|
|
|
|
QString AndroidDevice::displayNameForActionId(Core::Id actionId) const
|
|
|
|
{
|
|
|
|
Q_UNUSED(actionId)
|
|
|
|
return QString();
|
|
|
|
}
|
|
|
|
|
|
|
|
void AndroidDevice::executeAction(Core::Id actionId, QWidget *parent) const
|
|
|
|
{
|
|
|
|
Q_UNUSED(actionId)
|
|
|
|
Q_UNUSED(parent)
|
|
|
|
}
|
|
|
|
|
2012-07-26 17:41:52 +02:00
|
|
|
IDevice::Ptr AndroidDevice::clone() const
|
|
|
|
{
|
|
|
|
return IDevice::Ptr(new AndroidDevice(*this));
|
|
|
|
}
|
|
|
|
|
2012-07-03 16:57:44 +03:00
|
|
|
} // namespace Internal
|
|
|
|
} // namespace Android
|