forked from qt-creator/qt-creator
Merge remote-tracking branch 'origin/2.6'
Conflicts: src/libs/utils/tooltip/tips.cpp src/plugins/coreplugin/versiondialog.cpp src/plugins/projectexplorer/kitinformationconfigwidget.cpp src/plugins/qnx/blackberryapplicationrunner.cpp src/plugins/qnx/blackberrydeployconfiguration.cpp src/plugins/qnx/blackberrydeployconfiguration.h src/plugins/qt4projectmanager/qmakekitconfigwidget.cpp Change-Id: I7886ec971942d9e0a9da237dcf4ceb1687abd71b
This commit is contained in:
Vendored
+129
@@ -0,0 +1,129 @@
|
||||
|
||||
Qt Creator version 2.6.2 is a bugfix release.
|
||||
|
||||
The most important changes are listed in this document. For a complete
|
||||
list of changes, see the Git log for the Qt Creator sources that
|
||||
you can check out from the public Git repository. For example:
|
||||
|
||||
git clone git://gitorious.org/qt-creator/qt-creator.git
|
||||
git log --cherry-pick --pretty=oneline v2.6.1..v2.6.2
|
||||
|
||||
General
|
||||
* Fixed Qt version in VersionDialog
|
||||
* Improved kits set up (QTCREATORBUG-8576, QTCREATORBUG-8081)
|
||||
* Fixed editing of kits sysroot and mkspec (QTCREATORBUG-8586)
|
||||
* Fixed excessive emission of change signals from KitManager
|
||||
* Fixed display of Visual Studio compiler installations
|
||||
(QTCREATORBUG-8487)
|
||||
* Fixed integrity of device settings when closing option page
|
||||
* Fixed update of examples when default kit changes
|
||||
|
||||
Editing
|
||||
* Fixed crash when closing some editors while tooltip is active
|
||||
(QTCREATORBUG-8630)
|
||||
* Fixed warning about empty file in memory editor
|
||||
|
||||
Managing Projects
|
||||
* Added check if file is readable when determining its ABI
|
||||
* Fixed warning about running processes with empty environment
|
||||
|
||||
QMake Projects
|
||||
* Fixed display of directories in warnings (QTCREATORBUG-8585)
|
||||
* Added QMAKE_INCDIR to headers search paths
|
||||
|
||||
CMake Projects
|
||||
|
||||
Debugging
|
||||
* Sped up disassembly retrieval
|
||||
* Updated documentation of command-line arguments
|
||||
* Fixed visibility of Debugging Helper Dialog (QTCREATORBUG-8440)
|
||||
|
||||
Analyzer
|
||||
|
||||
C++ Support
|
||||
* Fixed invalid common prefix calculation which led to freezes
|
||||
(QTCREATORBUG-8472, QTCREATORBUG-8532)
|
||||
|
||||
QML/JS Support
|
||||
* Fixed Qt version in qmlobserver
|
||||
|
||||
GLSL Support
|
||||
|
||||
Help
|
||||
|
||||
Qt Designer
|
||||
|
||||
Qt Quick Designer
|
||||
* Fixed some parts of the tutorial
|
||||
|
||||
Version control plugins
|
||||
|
||||
Git
|
||||
|
||||
SVN
|
||||
|
||||
ClearCase
|
||||
* Fixed focus on Check Out dialog
|
||||
|
||||
FakeVim
|
||||
|
||||
Platform Specific
|
||||
|
||||
Mac
|
||||
|
||||
Linux
|
||||
|
||||
Windows
|
||||
|
||||
Remote Linux Support
|
||||
* Documented deployment settings for generic Linux devices
|
||||
|
||||
QNX
|
||||
* Fixed log output
|
||||
* Fixed update of path chooser model when browsing finishes
|
||||
* Fixed saving of changes to BlackBerry deploy information
|
||||
* Fixed QML_IMPORT_PATH setting in shipped bar-descriptor.xml files
|
||||
|
||||
Android
|
||||
* Fixed crash when pressing stop button
|
||||
|
||||
Madde
|
||||
|
||||
Pastebin:
|
||||
* Fixed pasting of .cpp files
|
||||
|
||||
Testing
|
||||
* Enabled squish tests with MSVC again
|
||||
* Fixed some squish tests
|
||||
* Added test for QML outline
|
||||
|
||||
Tools
|
||||
* Fixed addQt test in SDKTool
|
||||
* Fixed creation of group/world readable files in SDKTool
|
||||
(QTCREATORBUG-8458)
|
||||
* Fixed leak in zeroconf
|
||||
|
||||
Packaging
|
||||
* Use x86 instead of i386 for file names
|
||||
|
||||
|
||||
|
||||
Credits for these changes go to:
|
||||
|
||||
Aurindam Jana
|
||||
BogDan Vatra
|
||||
Christian Stenger
|
||||
Daniel Teske
|
||||
David Schulz
|
||||
Eike Ziller
|
||||
Erik Verbruggen
|
||||
Friedemann Kleint
|
||||
André Pönitz
|
||||
Leena Miettinen
|
||||
Mehdi Fekari
|
||||
Montel Laurent
|
||||
Orgad Shaneh
|
||||
Robert Loehning
|
||||
Sergey Belyashov
|
||||
Tobias Hunger
|
||||
Tobias Nätterlund
|
||||
@@ -5,7 +5,8 @@ headerdirs =
|
||||
sourcedirs = $SRCDIR/src
|
||||
imagedirs = $SRCDIR/images $SRCDIR/templates/images
|
||||
outputdir = $OUTDIR
|
||||
exampledirs = $SRCDIR/examples
|
||||
exampledirs = $SRCDIR/examples \
|
||||
$SRCDIR/snippets
|
||||
indexes = qt.index
|
||||
|
||||
include(compat.qdocconf)
|
||||
|
||||
Executable
BIN
Binary file not shown.
|
After Width: | Height: | Size: 35 KiB |
@@ -1,17 +1,11 @@
|
||||
\section2 Specifying Run Settings for Linux-Based Devices
|
||||
|
||||
To run an application on a Linux-based device (embedded Linux, MeeGo
|
||||
Harmattan, or Maemo), create and select a device configuration in the
|
||||
\l{glossary-buildandrun-kit}{kit} that is used for building and running the project and set its
|
||||
device type correspondingly.
|
||||
You can also pass command line arguments to your application.
|
||||
|
||||
\image qtcreator-screenshot-run-settings-maemo.png "Run settings for Linux-based devices"
|
||||
|
||||
To run and debug applications on Linux-based devices, you must
|
||||
create connections from the development PC to the devices. Click
|
||||
\gui {Manage device configurations} to create connections. For more
|
||||
information, see \l{Configuring Connections to Maemo Devices},
|
||||
To run and debug an application on a Linux-based device (embedded Linux,
|
||||
MeeGo Harmattan, or Maemo), you must create connections from the development
|
||||
host to the device and add the device configurations to
|
||||
\l{glossary-buildandrun-kit}{kits}. Click \gui {Manage Kits} to add devices
|
||||
to kits. For more information, see
|
||||
\l{Configuring Connections to Maemo Devices},
|
||||
\l{Configuring Connections to Harmattan Devices}, and
|
||||
\l {Connecting Embedded Linux Devices}.
|
||||
|
||||
@@ -23,3 +17,14 @@
|
||||
on devices that are of the same type and run the same firmware as the
|
||||
connected device. For more information, see
|
||||
\l{Deploying Applications to Linux-Based Devices}.
|
||||
|
||||
For generic embedded Linux devices, the run settings display the path to the
|
||||
executable file on the development host and on the device. To specify that
|
||||
another application launches your application, for example, enter the
|
||||
command in the \gui {Alternate executable on device} field and select the
|
||||
\gui {Use this command instead} check box.
|
||||
|
||||
\image qtcreator-run-settings-linux.png "Run settings for Linux-based devices"
|
||||
|
||||
You can specify command line arguments to pass to your application in the
|
||||
\gui Arguments field.
|
||||
|
||||
@@ -293,7 +293,7 @@
|
||||
expressions for the x and y properties, as illustrated by the
|
||||
following code snippet:
|
||||
|
||||
\snippet snippets/qml/states-properties.qml states
|
||||
\snippet qml/states-properties.qml states
|
||||
|
||||
\image qmldesigner-tutorial-state1.png "States"
|
||||
|
||||
@@ -319,7 +319,7 @@
|
||||
moving to State1, the x and y coordinates of the Qt logo change
|
||||
linearly over a duration of 1 second:
|
||||
|
||||
\snippet snippets/qml/list-of-transitions.qml first transition
|
||||
\snippet qml/list-of-transitions.qml first transition
|
||||
|
||||
\o You can use the Qt Quick toolbar for animation to change the easing
|
||||
curve type from linear to OutBounce:
|
||||
@@ -342,13 +342,13 @@
|
||||
and y coordinates of the Qt logo change over a duration of 2
|
||||
seconds, and an InOutQuad easing function is used:
|
||||
|
||||
\snippet snippets/qml/list-of-transitions.qml second transition
|
||||
\snippet qml/list-of-transitions.qml second transition
|
||||
|
||||
\o Add the following code to specify that for any other state changes,
|
||||
the x and y coordinates of the Qt logo change linearly over a
|
||||
duration of 200 milliseconds:
|
||||
|
||||
\snippet snippets/qml/list-of-transitions.qml default transition
|
||||
\snippet qml/list-of-transitions.qml default transition
|
||||
|
||||
\o Press \key {Ctrl+R} to run the application.
|
||||
|
||||
|
||||
@@ -337,7 +337,7 @@ static void parseCommandLineOptions(const QStringList &arguments)
|
||||
if (lastArg) usage();
|
||||
qApp->setStartDragDistance(arguments.at(++i).toInt());
|
||||
} else if (arg == QLatin1String("-v") || arg == QLatin1String("-version")) {
|
||||
qWarning("Qt QML Viewer version %s", QT_VERSION_STR);
|
||||
qWarning("Qt QML Viewer version %s", qVersion());
|
||||
exitApp(0);
|
||||
} else if (arg == "-translation") {
|
||||
if (lastArg) usage();
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
</initialWindow>
|
||||
<publisher>PUBLISHER</publisher>
|
||||
<copyright>COPYRIGHT</copyright>
|
||||
<env var="QML_IMPORT_PATH" value="app/native/imports"/>
|
||||
<env var="QML_IMPORT_PATH" value="app/native/imports:/usr/lib/qt4/imports"/>
|
||||
<env var="QT_PLUGIN_PATH" value="app/native/plugins:/usr/lib/qt4/plugins"/>
|
||||
<env var="LD_LIBRARY_PATH" value="app/native/lib:/usr/lib/qt4/lib/"/>
|
||||
<arg>-style</arg>
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
<aspectRatio>landscape</aspectRatio>
|
||||
</initialWindow>
|
||||
|
||||
<env var="QML_IMPORT_PATH" value="app/native/imports"/>
|
||||
<env var="QML_IMPORT_PATH" value="app/native/imports:/usr/lib/qt4/imports"/>
|
||||
<env var="QT_PLUGIN_PATH" value="app/native/plugins:/usr/lib/qt4/plugins"/>
|
||||
<env var="LD_LIBRARY_PATH" value="app/native/lib:/usr/lib/qt4/lib/"/>
|
||||
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
<aspectRatio>landscape</aspectRatio>
|
||||
</initialWindow>
|
||||
|
||||
<env var="QML_IMPORT_PATH" value="app/native/imports"/>
|
||||
<env var="QML_IMPORT_PATH" value="app/native/imports:/usr/lib/qt4/imports"/>
|
||||
<env var="QT_PLUGIN_PATH" value="app/native/plugins:/usr/lib/qt4/plugins"/>
|
||||
<env var="LD_LIBRARY_PATH" value="app/native/lib:/usr/lib/qt4/lib/"/>
|
||||
|
||||
|
||||
@@ -72,7 +72,9 @@ QTipLabel::QTipLabel(QWidget *parent) :
|
||||
|
||||
QTipLabel::~QTipLabel()
|
||||
{
|
||||
delete m_tipContent;
|
||||
Utils::TipContent *tmpTipContent = m_tipContent;
|
||||
m_tipContent = 0;
|
||||
delete tmpTipContent;
|
||||
}
|
||||
|
||||
bool QTipLabel::isInteractive() const
|
||||
|
||||
@@ -322,12 +322,12 @@ public:
|
||||
DNSServiceErrorType createConnection(MainConnection *mainConnection, ConnectionRef *sdRef) {
|
||||
if (!m_simplePollNew || !m_clientNew || !m_simplePollSetFunc)
|
||||
return kDNSServiceErr_Unknown;
|
||||
MyAvahiConnection *connection = new MyAvahiConnection;
|
||||
connection->lib = this;
|
||||
if (sdRef == 0) {
|
||||
qDebug() << "Error: sdRef is null in createConnection";
|
||||
return kDNSServiceErr_Unknown;
|
||||
}
|
||||
MyAvahiConnection *connection = new MyAvahiConnection;
|
||||
connection->lib = this;
|
||||
/* Allocate main loop object */
|
||||
connection->simple_poll = m_simplePollNew();
|
||||
if (!connection->simple_poll) {
|
||||
|
||||
@@ -49,7 +49,7 @@ using namespace Core;
|
||||
using namespace Core::Internal;
|
||||
|
||||
CorePlugin::CorePlugin() :
|
||||
m_mainWindow(new MainWindow), m_editMode(0)
|
||||
m_mainWindow(new MainWindow), m_editMode(0), m_designMode(0)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
@@ -86,7 +86,7 @@ VersionDialog::VersionDialog(QWidget *parent)
|
||||
"INCLUDING THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A "
|
||||
"PARTICULAR PURPOSE.<br/>")
|
||||
.arg(version,
|
||||
QLatin1String(QT_VERSION_STR), QString::number(QSysInfo::WordSize),
|
||||
QLatin1String(qVersion()), QString::number(QSysInfo::WordSize),
|
||||
QLatin1String(__DATE__), QLatin1String(__TIME__), QLatin1String(Constants::IDE_YEAR),
|
||||
(QLatin1String(Constants::IDE_AUTHOR)), ideVersionDescription,
|
||||
ideRev);
|
||||
|
||||
@@ -82,6 +82,7 @@ static inline QByteArray format(Protocol::ContentType ct)
|
||||
break;
|
||||
case Protocol::Cpp:
|
||||
format += "cpp-qt";
|
||||
break;
|
||||
case Protocol::JavaScript:
|
||||
format += "javascript";
|
||||
break;
|
||||
|
||||
@@ -199,6 +199,11 @@ DebuggerKitInformation::DebuggerItem DebuggerKitInformation::autoDetectItem(cons
|
||||
return result;
|
||||
}
|
||||
|
||||
void DebuggerKitInformation::setup(Kit *k)
|
||||
{
|
||||
setDebuggerItem(k, autoDetectItem(k));
|
||||
}
|
||||
|
||||
// Check the configuration errors and return a flag mask. Provide a quick check and
|
||||
// a verbose one with a list of errors.
|
||||
|
||||
|
||||
@@ -65,6 +65,8 @@ public:
|
||||
QList<ProjectExplorer::Task> validate(const ProjectExplorer::Kit *k) const
|
||||
{ return DebuggerKitInformation::validateDebugger(k); }
|
||||
|
||||
void setup(ProjectExplorer::Kit *k);
|
||||
|
||||
static QList<ProjectExplorer::Task> validateDebugger(const ProjectExplorer::Kit *k);
|
||||
static bool isValidDebugger(const ProjectExplorer::Kit *k);
|
||||
|
||||
|
||||
@@ -4484,11 +4484,15 @@ void GdbEngine::fetchDisassemblerByCliPointMixed(const DisassemblerAgentCookie &
|
||||
|
||||
void GdbEngine::fetchDisassemblerByCliPointPlain(const DisassemblerAgentCookie &ac0)
|
||||
{
|
||||
DisassemblerAgentCookie ac = ac0;
|
||||
QTC_ASSERT(ac.agent, return);
|
||||
postCommand(disassemblerCommand(ac.agent->location(), false), Discardable,
|
||||
CB(handleFetchDisassemblerByCliPointPlain),
|
||||
QVariant::fromValue(ac));
|
||||
// This here
|
||||
// DisassemblerAgentCookie ac = ac0;
|
||||
// QTC_ASSERT(ac.agent, return);
|
||||
// postCommand(disassemblerCommand(ac.agent->location(), false), Discardable,
|
||||
// CB(handleFetchDisassemblerByCliPointPlain),
|
||||
// QVariant::fromValue(ac));
|
||||
// takes far too long if function boundaries are not hit.
|
||||
// Skip this feature and immediately fall back to the 'range' version:
|
||||
fetchDisassemblerByCliRangePlain(ac0);
|
||||
}
|
||||
|
||||
void GdbEngine::fetchDisassemblerByCliRangeMixed(const DisassemblerAgentCookie &ac0)
|
||||
|
||||
@@ -71,7 +71,6 @@ public:
|
||||
void emitConfigurationChanged();
|
||||
|
||||
private:
|
||||
bool m_enabled;
|
||||
PerforcePlugin *m_plugin;
|
||||
};
|
||||
|
||||
|
||||
@@ -676,7 +676,9 @@ QList<Abi> Abi::abisOfBinary(const Utils::FileName &path)
|
||||
if (!f.exists())
|
||||
return tmp;
|
||||
|
||||
f.open(QFile::ReadOnly);
|
||||
if (!f.open(QFile::ReadOnly))
|
||||
return tmp;
|
||||
|
||||
QByteArray data = f.read(1024);
|
||||
if (data.size() >= 67
|
||||
&& getUint8(data, 0) == '!' && getUint8(data, 1) == '<' && getUint8(data, 2) == 'a'
|
||||
|
||||
@@ -200,6 +200,21 @@ void Kit::fix()
|
||||
i->fix(this);
|
||||
}
|
||||
|
||||
void Kit::setup()
|
||||
{
|
||||
KitGuard g(this);
|
||||
QHash<Core::Id, QVariant> data = d->m_data;
|
||||
for (int i = 0; i < 5; ++i) {
|
||||
// Allow for some retries to settle down in a good configuration
|
||||
// This is necessary for the Qt version to pick its preferred tool chain
|
||||
// and that to pick a working debugger afterwards.
|
||||
foreach (KitInformation *i, KitManager::instance()->kitInformation())
|
||||
i->setup(this);
|
||||
if (d->m_data == data)
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
QString Kit::displayName() const
|
||||
{
|
||||
return d->m_displayName;
|
||||
|
||||
@@ -67,7 +67,8 @@ public:
|
||||
|
||||
bool isValid() const;
|
||||
QList<Task> validate() const;
|
||||
void fix();
|
||||
void fix(); // Fix the individual kit information.
|
||||
void setup(); // Apply advanced magic(TM). Used only once on each kit during initial setup.
|
||||
|
||||
QString displayName() const;
|
||||
void setDisplayName(const QString &name);
|
||||
|
||||
@@ -181,6 +181,23 @@ void ToolChainKitInformation::fix(Kit *k)
|
||||
setToolChain(k, 0); // make sure to clear out no longer known tool chains
|
||||
}
|
||||
|
||||
void ToolChainKitInformation::setup(Kit *k)
|
||||
{
|
||||
const QString id = k->value(Core::Id(TOOLCHAIN_INFORMATION)).toString();
|
||||
if (id.isEmpty())
|
||||
return;
|
||||
|
||||
ToolChain *tc = ToolChainManager::instance()->findToolChain(id);
|
||||
if (tc)
|
||||
return;
|
||||
|
||||
// ID is not found: Might be an ABI string...
|
||||
foreach (ToolChain *current, ToolChainManager::instance()->toolChains()) {
|
||||
if (current->targetAbi().toString() == id)
|
||||
return setToolChain(k, current);
|
||||
}
|
||||
}
|
||||
|
||||
KitConfigWidget *ToolChainKitInformation::createConfigWidget(Kit *k) const
|
||||
{
|
||||
return new Internal::ToolChainInformationConfigWidget(k);
|
||||
@@ -217,20 +234,8 @@ ToolChain *ToolChainKitInformation::toolChain(const Kit *k)
|
||||
{
|
||||
if (!k)
|
||||
return 0;
|
||||
const QString id = k->value(Core::Id(TOOLCHAIN_INFORMATION)).toString();
|
||||
if (id.isEmpty())
|
||||
return 0;
|
||||
|
||||
ToolChain *tc = ToolChainManager::instance()->findToolChain(id);
|
||||
if (tc)
|
||||
return tc;
|
||||
|
||||
// ID is not found: Might be an ABI string...
|
||||
foreach (ToolChain *current, ToolChainManager::instance()->toolChains()) {
|
||||
if (current->targetAbi().toString() == id)
|
||||
return current;
|
||||
}
|
||||
return 0;
|
||||
return ToolChainManager::instance()
|
||||
->findToolChain(k->value(Core::Id(TOOLCHAIN_INFORMATION)).toString());
|
||||
}
|
||||
|
||||
void ToolChainKitInformation::setToolChain(Kit *k, ToolChain *tc)
|
||||
|
||||
@@ -104,6 +104,7 @@ public:
|
||||
|
||||
QList<Task> validate(const Kit *k) const;
|
||||
void fix(Kit *k);
|
||||
void setup(Kit *k);
|
||||
|
||||
KitConfigWidget *createConfigWidget(Kit *k) const;
|
||||
|
||||
|
||||
@@ -56,7 +56,8 @@ namespace Internal {
|
||||
// --------------------------------------------------------------------------
|
||||
|
||||
SysRootInformationConfigWidget::SysRootInformationConfigWidget(Kit *k) :
|
||||
KitConfigWidget(k)
|
||||
KitConfigWidget(k),
|
||||
m_ignoreChange(false)
|
||||
{
|
||||
m_chooser = new Utils::PathChooser;
|
||||
m_chooser->setExpectedKind(Utils::PathChooser::ExistingDirectory);
|
||||
@@ -77,7 +78,8 @@ QString SysRootInformationConfigWidget::toolTip() const
|
||||
|
||||
void SysRootInformationConfigWidget::refresh()
|
||||
{
|
||||
m_chooser->setFileName(SysRootKitInformation::sysRoot(m_kit));
|
||||
if (!m_ignoreChange)
|
||||
m_chooser->setFileName(SysRootKitInformation::sysRoot(m_kit));
|
||||
}
|
||||
|
||||
void SysRootInformationConfigWidget::makeReadOnly()
|
||||
@@ -97,7 +99,9 @@ QWidget *SysRootInformationConfigWidget::buttonWidget() const
|
||||
|
||||
void SysRootInformationConfigWidget::pathWasChanged()
|
||||
{
|
||||
m_ignoreChange = true;
|
||||
SysRootKitInformation::setSysRoot(m_kit, m_chooser->fileName());
|
||||
m_ignoreChange = false;
|
||||
}
|
||||
|
||||
// --------------------------------------------------------------------------
|
||||
|
||||
@@ -71,6 +71,7 @@ private slots:
|
||||
|
||||
private:
|
||||
Utils::PathChooser *m_chooser;
|
||||
bool m_ignoreChange;
|
||||
};
|
||||
|
||||
// --------------------------------------------------------------------------
|
||||
|
||||
@@ -148,9 +148,11 @@ void KitManager::restoreKits()
|
||||
QFileInfo kitFile(systemSettingsFile.absolutePath() + QLatin1String(KIT_FILENAME));
|
||||
if (kitFile.exists()) {
|
||||
KitList system = restoreKits(Utils::FileName(kitFile));
|
||||
// make sure we mark these as autodetected!
|
||||
foreach (Kit *k, system.kits)
|
||||
// make sure we mark these as autodetected and run additional setup logic
|
||||
foreach (Kit *k, system.kits) {
|
||||
k->setAutoDetected(true);
|
||||
k->setup();
|
||||
}
|
||||
|
||||
// SDK kits are always considered to be up for validation since they might have been
|
||||
// extended with additional information by creator in the meantime:
|
||||
@@ -202,6 +204,8 @@ void KitManager::restoreKits()
|
||||
defaultKit->setAutoDetected(false);
|
||||
defaultKit->setIconPath(QLatin1String(":///DESKTOP///"));
|
||||
|
||||
defaultKit->setup();
|
||||
|
||||
addKit(defaultKit);
|
||||
}
|
||||
|
||||
|
||||
@@ -75,8 +75,12 @@ public:
|
||||
virtual bool visibleIn(Kit *) { return true; }
|
||||
virtual QVariant defaultValue(Kit *) const = 0;
|
||||
|
||||
// called to find issues with the kit
|
||||
virtual QList<Task> validate(const Kit *) const = 0;
|
||||
// called to fix issues with this kitinformation. Does not modify the rest of the kit.
|
||||
virtual void fix(Kit *) { return; }
|
||||
// called on initial setup of a kit.
|
||||
virtual void setup(Kit *) { return; }
|
||||
|
||||
virtual ItemList toUserOutput(Kit *) const = 0;
|
||||
|
||||
|
||||
@@ -322,12 +322,14 @@ Kit *KitModel::markForAddition(Kit *baseKit)
|
||||
beginInsertRows(index(m_manualRoot), pos, pos);
|
||||
|
||||
KitNode *node = createNode(m_manualRoot, 0);
|
||||
Kit *k = node->widget->workingCopy();
|
||||
KitGuard g(k);
|
||||
if (baseKit) {
|
||||
Kit *k = node->widget->workingCopy();
|
||||
KitGuard g(k);
|
||||
k->copyFrom(baseKit);
|
||||
k->setAutoDetected(false); // Make sure we have a manual kit!
|
||||
k->setDisplayName(tr("Clone of %1").arg(k->displayName()));
|
||||
} else {
|
||||
k->setup();
|
||||
}
|
||||
|
||||
if (!m_defaultNode)
|
||||
@@ -335,7 +337,7 @@ Kit *KitModel::markForAddition(Kit *baseKit)
|
||||
|
||||
endInsertRows();
|
||||
|
||||
return node->widget->workingCopy();
|
||||
return k;
|
||||
}
|
||||
|
||||
QModelIndex KitModel::index(KitNode *node, int column) const
|
||||
|
||||
@@ -576,7 +576,9 @@ void ToolChainOptionsPage::toolChainSelectionChanged()
|
||||
if (!m_container)
|
||||
return;
|
||||
QModelIndex current = currentIndex();
|
||||
(void)m_container->takeWidget(); // Prevent deletion.
|
||||
QWidget *oldWidget = m_container->takeWidget(); // Prevent deletion.
|
||||
if (oldWidget)
|
||||
oldWidget->setVisible(false);
|
||||
QWidget *currentTcWidget = current.isValid() ? m_model->widget(current) : 0;
|
||||
m_container->setWidget(currentTcWidget);
|
||||
m_container->setVisible(currentTcWidget != 0);
|
||||
|
||||
@@ -234,6 +234,7 @@ QVariant read(int variantType, const QString &str)
|
||||
break;
|
||||
case QMetaType::QVector3D:
|
||||
value = vector3DFromString(str, &conversionOk);
|
||||
break;
|
||||
default: {
|
||||
value = QVariant(str);
|
||||
value.convert(static_cast<QVariant::Type>(variantType));
|
||||
|
||||
@@ -93,6 +93,7 @@ BlackBerryApplicationRunner::BlackBerryApplicationRunner(bool debugMode, BlackBe
|
||||
, m_stopProcess(0)
|
||||
, m_tailProcess(0)
|
||||
, m_testSlog2Process(0)
|
||||
, m_launchDateTimeProcess(0)
|
||||
, m_runningStateTimer(new QTimer(this))
|
||||
, m_runningStateProcess(0)
|
||||
{
|
||||
@@ -269,7 +270,11 @@ void BlackBerryApplicationRunner::killTailProcess()
|
||||
|
||||
void BlackBerryApplicationRunner::tailApplicationLog()
|
||||
{
|
||||
// TODO: Reading the log using qconn instead?
|
||||
QSsh::SshRemoteProcessRunner *process = qobject_cast<QSsh::SshRemoteProcessRunner *>(sender());
|
||||
QTC_ASSERT(process, return);
|
||||
|
||||
m_launchDateTime = QDateTime::fromString(QString::fromLatin1(process->readAllStandardOutput()).trimmed(),
|
||||
QString::fromLatin1("dd HH:mm:ss"));
|
||||
|
||||
if (m_stopping || (m_tailProcess && m_tailProcess->isProcessRunning()))
|
||||
return;
|
||||
@@ -289,7 +294,7 @@ void BlackBerryApplicationRunner::tailApplicationLog()
|
||||
|
||||
QString command;
|
||||
if (m_slog2infoFound) {
|
||||
command = QString::fromLatin1("slog2info -w");
|
||||
command = QString::fromLatin1("slog2info -w -b ") + m_appId;
|
||||
} else {
|
||||
command = QLatin1String("tail -c +1 -f /accounts/1000/appdata/") + m_appId
|
||||
+ QLatin1String("/logs/log");
|
||||
@@ -307,6 +312,15 @@ void BlackBerryApplicationRunner::handleSlog2InfoFound()
|
||||
tailApplicationLog();
|
||||
}
|
||||
|
||||
void BlackBerryApplicationRunner::readLaunchTime()
|
||||
{
|
||||
m_launchDateTimeProcess = new QSsh::SshRemoteProcessRunner(this);
|
||||
connect(m_launchDateTimeProcess, SIGNAL(processClosed(int)),
|
||||
this, SLOT(tailApplicationLog()));
|
||||
|
||||
m_launchDateTimeProcess->run("date +\"%d %H:%M:%S\"", m_sshParams);
|
||||
}
|
||||
|
||||
void BlackBerryApplicationRunner::handleTailOutput()
|
||||
{
|
||||
QSsh::SshRemoteProcessRunner *process = qobject_cast<QSsh::SshRemoteProcessRunner *>(sender());
|
||||
@@ -316,7 +330,9 @@ void BlackBerryApplicationRunner::handleTailOutput()
|
||||
if (m_slog2infoFound) {
|
||||
const QStringList multiLine = message.split(QLatin1Char('\n'));
|
||||
Q_FOREACH (const QString &line, multiLine) {
|
||||
if ( line.contains(m_appId) ) {
|
||||
QDateTime dateTime = QDateTime::fromString(line.split(m_appId).first().mid(4).trimmed(),
|
||||
QString::fromLatin1("dd HH:mm:ss.zzz"));
|
||||
if (dateTime >= m_launchDateTime) {
|
||||
QStringList validLineBeginnings;
|
||||
validLineBeginnings << QLatin1String("qt-msg 0 ")
|
||||
<< QLatin1String("qt-msg* 0 ")
|
||||
|
||||
@@ -39,6 +39,7 @@
|
||||
|
||||
#include <QObject>
|
||||
#include <QProcess>
|
||||
#include <QDateTime>
|
||||
|
||||
namespace QSsh {
|
||||
class SshRemoteProcessRunner;
|
||||
@@ -89,6 +90,7 @@ private slots:
|
||||
void readRunningStateStandardOutput();
|
||||
|
||||
void handleSlog2InfoFound();
|
||||
void readLaunchTime();
|
||||
|
||||
private:
|
||||
void reset();
|
||||
@@ -97,6 +99,8 @@ private:
|
||||
bool m_debugMode;
|
||||
bool m_slog2infoFound;
|
||||
|
||||
QDateTime m_launchDateTime;
|
||||
|
||||
qint64 m_pid;
|
||||
QString m_appId;
|
||||
|
||||
@@ -114,6 +118,7 @@ private:
|
||||
QProcess *m_stopProcess;
|
||||
QSsh::SshRemoteProcessRunner *m_tailProcess;
|
||||
QSsh::SshRemoteProcessRunner *m_testSlog2Process;
|
||||
QSsh::SshRemoteProcessRunner *m_launchDateTimeProcess;
|
||||
QTimer *m_runningStateTimer;
|
||||
QProcess *m_runningStateProcess;
|
||||
};
|
||||
|
||||
@@ -50,7 +50,8 @@ using namespace Qnx;
|
||||
using namespace Qnx::Internal;
|
||||
|
||||
namespace {
|
||||
const char DEPLOYMENT_INFO_SETTING[] = "QNX.BlackBerry.DeploymentInfo";
|
||||
const char DEPLOYMENT_INFO_SETTING[] = "Qnx.BlackBerry.DeploymentInfo";
|
||||
const char DEPLOYMENT_INFO_KEY[] = "Qnx.BlackBerry.DeployInformation";
|
||||
}
|
||||
|
||||
BlackBerryDeployConfiguration::BlackBerryDeployConfiguration(ProjectExplorer::Target *parent)
|
||||
@@ -165,3 +166,20 @@ ProjectExplorer::NamedWidget *BlackBerryDeployConfiguration::createConfigWidget(
|
||||
{
|
||||
return new BlackBerryDeployConfigurationWidget(this);
|
||||
}
|
||||
|
||||
QVariantMap BlackBerryDeployConfiguration::toMap() const
|
||||
{
|
||||
QVariantMap map(ProjectExplorer::DeployConfiguration::toMap());
|
||||
map.insert(QLatin1String(DEPLOYMENT_INFO_KEY), deploymentInfo()->toMap());
|
||||
return map;
|
||||
}
|
||||
|
||||
bool BlackBerryDeployConfiguration::fromMap(const QVariantMap &map)
|
||||
{
|
||||
if (!ProjectExplorer::DeployConfiguration::fromMap(map))
|
||||
return false;
|
||||
|
||||
QVariantMap deployInfoMap = map.value(QLatin1String(DEPLOYMENT_INFO_KEY)).toMap();
|
||||
deploymentInfo()->fromMap(deployInfoMap);
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -58,9 +58,13 @@ public:
|
||||
|
||||
BlackBerryDeployInformation *deploymentInfo() const;
|
||||
|
||||
QVariantMap toMap() const;
|
||||
|
||||
protected:
|
||||
BlackBerryDeployConfiguration(ProjectExplorer::Target *parent, BlackBerryDeployConfiguration *source);
|
||||
|
||||
bool fromMap(const QVariantMap &map);
|
||||
|
||||
private slots:
|
||||
void setupBarDescriptor();
|
||||
|
||||
|
||||
@@ -41,11 +41,21 @@
|
||||
using namespace Qnx;
|
||||
using namespace Qnx::Internal;
|
||||
|
||||
namespace {
|
||||
const char COUNT_KEY[] = "Qnx.BlackBerry.DeployInformationCount";
|
||||
const char DEPLOYINFO_KEY[] = "Qnx.BlackBerry.DeployInformation.%1";
|
||||
|
||||
const char ENABLED_KEY[] = "Qnx.BlackBerry.DeployInformation.Enabled";
|
||||
const char APPDESCRIPTOR_KEY[] = "Qnx.BlackBerry.DeployInformation.AppDescriptor";
|
||||
const char PACKAGE_KEY[] = "Qnx.BlackBerry.DeployInformation.Package";
|
||||
const char PROFILE_KEY[] = "Qnx.BlackBerry.DeployInformation.ProFile";
|
||||
}
|
||||
|
||||
BlackBerryDeployInformation::BlackBerryDeployInformation(Qt4ProjectManager::Qt4Project *project)
|
||||
: QAbstractTableModel(project)
|
||||
, m_project(project)
|
||||
{
|
||||
connect(m_project, SIGNAL(proFilesEvaluated()), this, SLOT(initModel()));
|
||||
connect(m_project, SIGNAL(proFilesEvaluated()), this, SLOT(updateModel()));
|
||||
}
|
||||
|
||||
int BlackBerryDeployInformation::rowCount(const QModelIndex &parent) const
|
||||
@@ -152,8 +162,78 @@ QList<BarPackageDeployInformation> BlackBerryDeployInformation::enabledPackages(
|
||||
return result;
|
||||
}
|
||||
|
||||
QVariantMap BlackBerryDeployInformation::toMap() const
|
||||
{
|
||||
QVariantMap outerMap;
|
||||
outerMap[QLatin1String(COUNT_KEY)] = m_deployInformation.size();
|
||||
|
||||
for (int i = 0; i < m_deployInformation.size(); ++i) {
|
||||
const BarPackageDeployInformation &deployInfo = m_deployInformation[i];
|
||||
|
||||
QVariantMap deployInfoMap;
|
||||
deployInfoMap[QLatin1String(ENABLED_KEY)] = deployInfo.enabled;
|
||||
deployInfoMap[QLatin1String(APPDESCRIPTOR_KEY)] = deployInfo.appDescriptorPath;
|
||||
deployInfoMap[QLatin1String(PACKAGE_KEY)] = deployInfo.packagePath;
|
||||
deployInfoMap[QLatin1String(PROFILE_KEY)] = deployInfo.proFilePath;
|
||||
|
||||
outerMap[QString::fromLatin1(DEPLOYINFO_KEY).arg(i)] = deployInfoMap;
|
||||
}
|
||||
|
||||
return outerMap;
|
||||
}
|
||||
|
||||
void BlackBerryDeployInformation::fromMap(const QVariantMap &map)
|
||||
{
|
||||
beginResetModel();
|
||||
m_deployInformation.clear();
|
||||
|
||||
int count = map.value(QLatin1String(COUNT_KEY)).toInt();
|
||||
for (int i = 0; i < count; ++i) {
|
||||
QVariantMap innerMap = map.value(QString::fromLatin1(DEPLOYINFO_KEY).arg(i)).toMap();
|
||||
|
||||
const bool enabled = innerMap.value(QLatin1String(ENABLED_KEY)).toBool();
|
||||
const QString appDescriptorPath = innerMap.value(QLatin1String(APPDESCRIPTOR_KEY)).toString();
|
||||
const QString packagePath = innerMap.value(QLatin1String(PACKAGE_KEY)).toString();
|
||||
const QString proFilePath = innerMap.value(QLatin1String(PROFILE_KEY)).toString();
|
||||
|
||||
m_deployInformation << BarPackageDeployInformation(enabled, appDescriptorPath, packagePath, proFilePath);
|
||||
}
|
||||
|
||||
endResetModel();
|
||||
}
|
||||
|
||||
void BlackBerryDeployInformation::updateModel()
|
||||
{
|
||||
if (m_deployInformation.isEmpty()) {
|
||||
initModel();
|
||||
return;
|
||||
}
|
||||
|
||||
beginResetModel();
|
||||
QList<BarPackageDeployInformation> keep;
|
||||
QList<Qt4ProjectManager::Qt4ProFileNode *> appNodes = m_project->applicationProFiles();
|
||||
foreach (Qt4ProjectManager::Qt4ProFileNode *node, appNodes) {
|
||||
bool nodeFound = false;
|
||||
for (int i = 0; i < m_deployInformation.size(); ++i) {
|
||||
if (m_deployInformation[i].proFilePath == node->path()) {
|
||||
keep << m_deployInformation[i];
|
||||
nodeFound = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (!nodeFound)
|
||||
keep << deployInformationFromNode(node);
|
||||
}
|
||||
m_deployInformation = keep;
|
||||
endResetModel();
|
||||
}
|
||||
|
||||
void BlackBerryDeployInformation::initModel()
|
||||
{
|
||||
if (!m_deployInformation.isEmpty())
|
||||
return;
|
||||
|
||||
ProjectExplorer::Target *target = m_project->activeTarget();
|
||||
if (!target
|
||||
|| !target->activeDeployConfiguration()
|
||||
@@ -172,23 +252,28 @@ void BlackBerryDeployInformation::initModel()
|
||||
if (!rootNode || rootNode->parseInProgress()) // Can be null right after project creation by wizard.
|
||||
return;
|
||||
|
||||
disconnect(m_project, SIGNAL(proFilesEvaluated()), this, SLOT(initModel()));
|
||||
disconnect(m_project, SIGNAL(proFilesEvaluated()), this, SLOT(updateModel()));
|
||||
|
||||
beginResetModel();
|
||||
m_deployInformation.clear();
|
||||
|
||||
QList<Qt4ProjectManager::Qt4ProFileNode *> appNodes = m_project->applicationProFiles();
|
||||
foreach (Qt4ProjectManager::Qt4ProFileNode *node, appNodes) {
|
||||
Qt4ProjectManager::TargetInformation ti = node->targetInformation();
|
||||
|
||||
QFileInfo fi(node->path());
|
||||
const QString appDescriptorPath = QDir::toNativeSeparators(fi.absolutePath() + QLatin1String("/bar-descriptor.xml"));
|
||||
QString barPackagePath;
|
||||
if (!ti.buildDir.isEmpty())
|
||||
barPackagePath = QDir::toNativeSeparators(ti.buildDir + QLatin1Char('/') + ti.target + QLatin1String(".bar"));
|
||||
|
||||
m_deployInformation << BarPackageDeployInformation(true, appDescriptorPath, barPackagePath, node->path());
|
||||
}
|
||||
foreach (Qt4ProjectManager::Qt4ProFileNode *node, appNodes)
|
||||
m_deployInformation << deployInformationFromNode(node);
|
||||
|
||||
endResetModel();
|
||||
connect(m_project, SIGNAL(proFilesEvaluated()), SLOT(initModel()));
|
||||
connect(m_project, SIGNAL(proFilesEvaluated()), this, SLOT(updateModel()));
|
||||
}
|
||||
|
||||
BarPackageDeployInformation BlackBerryDeployInformation::deployInformationFromNode(Qt4ProjectManager::Qt4ProFileNode *node) const
|
||||
{
|
||||
Qt4ProjectManager::TargetInformation ti = node->targetInformation();
|
||||
|
||||
QFileInfo fi(node->path());
|
||||
const QString appDescriptorPath = QDir::toNativeSeparators(fi.absolutePath() + QLatin1String("/bar-descriptor.xml"));
|
||||
QString barPackagePath;
|
||||
if (!ti.buildDir.isEmpty())
|
||||
barPackagePath = QDir::toNativeSeparators(ti.buildDir + QLatin1Char('/') + ti.target + QLatin1String(".bar"));
|
||||
|
||||
return BarPackageDeployInformation(true, appDescriptorPath, barPackagePath, node->path());
|
||||
}
|
||||
|
||||
@@ -34,6 +34,7 @@
|
||||
#include <QAbstractTableModel>
|
||||
|
||||
namespace Qt4ProjectManager {
|
||||
class Qt4ProFileNode;
|
||||
class Qt4Project;
|
||||
}
|
||||
|
||||
@@ -74,8 +75,11 @@ public:
|
||||
|
||||
QList<BarPackageDeployInformation> enabledPackages() const;
|
||||
|
||||
QVariantMap toMap() const;
|
||||
void fromMap(const QVariantMap &map);
|
||||
|
||||
private slots:
|
||||
void initModel();
|
||||
void updateModel();
|
||||
|
||||
private:
|
||||
enum Columns {
|
||||
@@ -85,6 +89,9 @@ private:
|
||||
ColumnCount // Always have last
|
||||
};
|
||||
|
||||
void initModel();
|
||||
BarPackageDeployInformation deployInformationFromNode(Qt4ProjectManager::Qt4ProFileNode *node) const;
|
||||
|
||||
Qt4ProjectManager::Qt4Project *m_project;
|
||||
|
||||
QList<BarPackageDeployInformation> m_deployInformation;
|
||||
|
||||
@@ -64,6 +64,8 @@ QWidget *PathChooserDelegate::createEditor(QWidget *parent, const QStyleOptionVi
|
||||
editor->setAutoFillBackground(true); // To hide the text beneath the editor widget
|
||||
editor->lineEdit()->setMinimumWidth(0);
|
||||
|
||||
connect(editor, SIGNAL(browsingFinished()), this, SLOT(emitCommitData()));
|
||||
|
||||
return editor;
|
||||
}
|
||||
|
||||
@@ -95,3 +97,8 @@ void PathChooserDelegate::updateEditorGeometry(QWidget *editor, const QStyleOpti
|
||||
|
||||
editor->setGeometry(option.rect);
|
||||
}
|
||||
|
||||
void PathChooserDelegate::emitCommitData()
|
||||
{
|
||||
emit commitData(qobject_cast<QWidget*>(sender()));
|
||||
}
|
||||
|
||||
@@ -60,6 +60,9 @@ public:
|
||||
void updateEditorGeometry(QWidget *editor,
|
||||
const QStyleOptionViewItem &option, const QModelIndex &index) const;
|
||||
|
||||
private slots:
|
||||
void emitCommitData();
|
||||
|
||||
private:
|
||||
Utils::PathChooser::Kind m_kind;
|
||||
QString m_filter;
|
||||
|
||||
@@ -42,7 +42,8 @@ namespace Internal {
|
||||
|
||||
QmakeKitConfigWidget::QmakeKitConfigWidget(ProjectExplorer::Kit *k) :
|
||||
ProjectExplorer::KitConfigWidget(k),
|
||||
m_lineEdit(new QLineEdit)
|
||||
m_lineEdit(new QLineEdit),
|
||||
m_ignoreChange(false)
|
||||
{
|
||||
refresh(); // set up everything according to kit
|
||||
connect(m_lineEdit, SIGNAL(textEdited(QString)), this, SLOT(mkspecWasChanged(QString)));
|
||||
@@ -71,12 +72,15 @@ void QmakeKitConfigWidget::makeReadOnly()
|
||||
|
||||
void QmakeKitConfigWidget::refresh()
|
||||
{
|
||||
m_lineEdit->setText(QmakeKitInformation::mkspec(m_kit).toString());
|
||||
if (!m_ignoreChange)
|
||||
m_lineEdit->setText(QmakeKitInformation::mkspec(m_kit).toUserOutput());
|
||||
}
|
||||
|
||||
void QmakeKitConfigWidget::mkspecWasChanged(const QString &text)
|
||||
{
|
||||
m_ignoreChange = true;
|
||||
QmakeKitInformation::setMkspec(m_kit, Utils::FileName::fromString(text));
|
||||
m_ignoreChange = false;
|
||||
}
|
||||
|
||||
} // namespace Internal
|
||||
|
||||
@@ -60,6 +60,7 @@ private:
|
||||
int findQtVersion(const int id) const;
|
||||
|
||||
QLineEdit *m_lineEdit;
|
||||
bool m_ignoreChange;
|
||||
};
|
||||
|
||||
} // namespace Internal
|
||||
|
||||
@@ -84,7 +84,7 @@ QList<ProjectExplorer::Task> QmakeKitInformation::validate(const ProjectExplorer
|
||||
return result;
|
||||
}
|
||||
|
||||
void QmakeKitInformation::fix(ProjectExplorer::Kit *k)
|
||||
void QmakeKitInformation::setup(ProjectExplorer::Kit *k)
|
||||
{
|
||||
QtSupport::BaseQtVersion *version = QtSupport::QtKitInformation::qtVersion(k);
|
||||
if (!version)
|
||||
|
||||
@@ -50,7 +50,7 @@ public:
|
||||
QVariant defaultValue(ProjectExplorer::Kit *k) const;
|
||||
|
||||
QList<ProjectExplorer::Task> validate(const ProjectExplorer::Kit *k) const;
|
||||
void fix(ProjectExplorer::Kit *k);
|
||||
void setup(ProjectExplorer::Kit *k);
|
||||
|
||||
ProjectExplorer::KitConfigWidget *createConfigWidget(ProjectExplorer::Kit *k) const;
|
||||
|
||||
|
||||
@@ -274,12 +274,12 @@ void Qt4ProjectConfigWidget::updateProblemLabel()
|
||||
} else if (targetMismatch) {
|
||||
setProblemLabel(shadowBuildWarning + tr("A build for a different project exists in %1, which will be overwritten.",
|
||||
"%1 build directory")
|
||||
.arg(m_ui->shadowBuildDirEdit->path()));
|
||||
.arg(m_buildConfiguration->buildDirectory()));
|
||||
return;
|
||||
} else if (incompatibleBuild) {
|
||||
setProblemLabel(shadowBuildWarning +tr("An incompatible build exists in %1, which will be overwritten.",
|
||||
"%1 build directory")
|
||||
.arg(m_ui->shadowBuildDirEdit->path()));
|
||||
.arg(m_buildConfiguration->buildDirectory()));
|
||||
return;
|
||||
} else if (!shadowBuildWarning.isEmpty()) {
|
||||
setProblemLabel(shadowBuildWarning);
|
||||
|
||||
@@ -111,7 +111,6 @@ private:
|
||||
ProjectExplorer::KitMatcher *m_preferredMatcher;
|
||||
QLayout *m_baseLayout;
|
||||
bool m_importSearch;
|
||||
bool m_useScrollArea;
|
||||
bool m_ignoreUpdates;
|
||||
QString m_proFilePath;
|
||||
QString m_defaultShadowBuildLocation;
|
||||
|
||||
@@ -119,7 +119,7 @@ QtOptionsPageWidget::QtOptionsPageWidget(QWidget *parent)
|
||||
{
|
||||
QWidget *versionInfoWidget = new QWidget();
|
||||
m_versionUi->setupUi(versionInfoWidget);
|
||||
m_versionUi->editPathPushButton->setText(tr(Utils::PathChooser::browseButtonLabel));
|
||||
m_versionUi->editPathPushButton->setText(QCoreApplication::translate("Utils::PathChooser", Utils::PathChooser::browseButtonLabel));
|
||||
|
||||
QWidget *debuggingHelperDetailsWidget = new QWidget();
|
||||
m_debuggingHelperUi->setupUi(debuggingHelperDetailsWidget);
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
#include <QScrollArea>
|
||||
#include <QDesktopServices>
|
||||
#include <QPainter>
|
||||
#include <QHBoxLayout>
|
||||
#include <QVBoxLayout>
|
||||
|
||||
#include <QCoreApplication>
|
||||
#include <QDir>
|
||||
@@ -127,7 +127,6 @@ private:
|
||||
|
||||
QWidget *m_modeWidget;
|
||||
QDeclarativeView *m_welcomePage;
|
||||
QHBoxLayout * buttonLayout;
|
||||
QList<QObject*> m_pluginList;
|
||||
int m_activePlugin;
|
||||
NetworkAccessManagerFactory *m_networkAccessManagerFactory;
|
||||
|
||||
@@ -195,7 +195,7 @@ bool AddQtOperation::test() const
|
||||
|| !version0.contains(QLatin1String(AUTODETECTED))
|
||||
|| version0.value(QLatin1String(AUTODETECTED)).toBool() != true
|
||||
|| !version0.contains(QLatin1String(AUTODETECTION_SOURCE))
|
||||
|| version0.value(QLatin1String(AUTODETECTION_SOURCE)).toString() != QLatin1String("testId")
|
||||
|| version0.value(QLatin1String(AUTODETECTION_SOURCE)).toString() != QLatin1String("SDK.testId")
|
||||
|| !version0.contains(QLatin1String(TYPE))
|
||||
|| version0.value(QLatin1String(TYPE)).toString() != QLatin1String("testType")
|
||||
|| !version0.contains(QLatin1String(QMAKE))
|
||||
@@ -234,7 +234,7 @@ bool AddQtOperation::test() const
|
||||
|| !version1.contains(QLatin1String(AUTODETECTED))
|
||||
|| version1.value(QLatin1String(AUTODETECTED)).toBool() != true
|
||||
|| !version1.contains(QLatin1String(AUTODETECTION_SOURCE))
|
||||
|| version1.value(QLatin1String(AUTODETECTION_SOURCE)).toString() != QLatin1String("testId2")
|
||||
|| version1.value(QLatin1String(AUTODETECTION_SOURCE)).toString() != QLatin1String("SDK.testId2")
|
||||
|| !version1.contains(QLatin1String(TYPE))
|
||||
|| version1.value(QLatin1String(TYPE)).toString() != QLatin1String("testType3")
|
||||
|| !version1.contains(QLatin1String(QMAKE))
|
||||
|
||||
@@ -85,12 +85,14 @@
|
||||
:Qt Creator.Search for:_QLabel {text='Search for:' type='QLabel' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator.Stop_QToolButton {text='Stop' type='QToolButton' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator.replaceEdit_Utils::FilterLineEdit {name='replaceEdit' type='Utils::FilterLineEdit' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator.scrollArea_QScrollArea {name='scrollArea' type='QScrollArea' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator_AppOutput_Core::Internal::OutputPaneToggleButton {occurrence='3' type='Core::Internal::OutputPaneToggleButton' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator_Bookmarks_TreeView {type='TreeView' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator_CloseButton {type='CloseButton' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator_CompileOutput_Core::Internal::OutputPaneToggleButton {occurrence='4' type='Core::Internal::OutputPaneToggleButton' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator_Core::Internal::CommandComboBox {type='Core::Internal::CommandComboBox' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator_Core::Internal::MainWindow {type='Core::Internal::MainWindow' visible='1' windowTitle?='*Qt Creator'}
|
||||
:Qt Creator_Core::Internal::NavComboBox {type='Core::Internal::NavComboBox' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator_CppEditor::Internal::CPPEditorWidget {type='CppEditor::Internal::CPPEditorWidget' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator_FilenameQComboBox {type='QComboBox' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator_Find::Internal::SearchResultTreeView {type='Find::Internal::SearchResultTreeView' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
@@ -101,6 +103,7 @@
|
||||
:Qt Creator_QDeclarativeView {type='QDeclarativeView' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator_QHelpContentWidget {type='QHelpContentWidget' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator_QTableView {type='QTableView' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator_QmlJSEditor::Internal::QmlJSOutlineTreeView {type='QmlJSEditor::Internal::QmlJSOutlineTreeView' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator_QmlJSEditor::QmlJSTextEditorWidget {type='QmlJSEditor::QmlJSTextEditorWidget' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator_SearchResult_Core::Internal::OutputPaneToggleButton {occurrence='2' type='Core::Internal::OutputPaneToggleButton' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
:Qt Creator_SystemSettings.Details_Utils::DetailsButton {occurrence='4' text='Details' type='Utils::DetailsButton' unnamed='1' visible='1' window=':Qt Creator_Core::Internal::MainWindow'}
|
||||
@@ -126,6 +129,7 @@
|
||||
:headerFileLineEdit_Utils::FileNameValidatingLineEdit {buddy=':Qt Gui Application.Header file:_QLabel' name='headerFileLineEdit' type='Utils::FileNameValidatingLineEdit' visible='1'}
|
||||
:popupFrame_Proposal_QListView {container=':popupFrame_TextEditor::GenericProposalWidget' type='QListView' unnamed='1' visible='1'}
|
||||
:popupFrame_TextEditor::GenericProposalWidget {name='m_popupFrame' type='TextEditor::GenericProposalWidget' visible='1'}
|
||||
:qmakeCallEdit {container=':Qt Creator.scrollArea_QScrollArea' text?='<b>qmake:</b> qmake*' type='QLabel' unnamed='1' visible='1'}
|
||||
:qt_tabwidget_stackedwidget.Core__Internal__GeneralSettings_QWidget {container=':Options.qt_tabwidget_stackedwidget_QStackedWidget' name='Core__Internal__GeneralSettings' type='QWidget' visible='1'}
|
||||
:qt_tabwidget_stackedwidget.CppTools__Internal__CompletionSettingsPage_QWidget {container=':Options.qt_tabwidget_stackedwidget_QStackedWidget' name='CppTools__Internal__CompletionSettingsPage' type='QWidget' visible='1'}
|
||||
:qt_tabwidget_stackedwidget.Form_QWidget {container=':Options.qt_tabwidget_stackedwidget_QStackedWidget' name='Help__Internal__GeneralSettingsPage' type='QWidget' visible='1' windowTitle='Form'}
|
||||
|
||||
@@ -13,6 +13,13 @@ class QtQuickConstants:
|
||||
EMBEDDED_LINUX = 16
|
||||
DESKTOP_474_MSVC2008 = 32
|
||||
|
||||
@staticmethod
|
||||
def desktopTargetClasses():
|
||||
desktopTargets = QtQuickConstants.Targets.DESKTOP_474_GCC
|
||||
if platform.system() in ('Windows', 'Microsoft'):
|
||||
desktopTargets |= QtQuickConstants.Targets.DESKTOP_474_MSVC2008
|
||||
return desktopTargets
|
||||
|
||||
@staticmethod
|
||||
def getStringForComponents(components):
|
||||
if components==QtQuickConstants.Components.BUILTIN:
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import re
|
||||
|
||||
def handleDebuggerWarnings(config):
|
||||
if "MSVC" in config:
|
||||
def handleDebuggerWarnings(config, isMsvcBuild=False):
|
||||
if isMsvcBuild:
|
||||
try:
|
||||
popup = waitForObject("{text?='<html><head/><body>*' type='QLabel' unnamed='1' visible='1' window=':Symbol Server_Utils::CheckableMessageBox'}", 10000)
|
||||
symServerNotConfiged = ("<html><head/><body><p>The debugger is not configured to use the public "
|
||||
@@ -99,16 +99,19 @@ def removeOldBreakpoints():
|
||||
return test.compare(model.rowCount(), 0, "Check if all breakpoints have been removed.")
|
||||
|
||||
# function to do simple debugging of the current (configured) project
|
||||
# param kitCount specifies the number of kits currently defined (must be correct!)
|
||||
# param currentKit specifies the target to use (zero based index)
|
||||
# param currentConfigName is the name of the configuration that should be used
|
||||
# param pressContinueCount defines how often it is expected to press
|
||||
# the 'Continue' button while debugging
|
||||
# param expectedBPOrder holds a list of dicts where the dicts contain always
|
||||
# only 1 key:value pair - the key is the name of the file, the value is
|
||||
# line number where the debugger should stop
|
||||
def doSimpleDebugging(currentConfigName, pressContinueCount=1, expectedBPOrder=[]):
|
||||
def doSimpleDebugging(kitCount, currentKit, currentConfigName, pressContinueCount=1, expectedBPOrder=[]):
|
||||
expectedLabelTexts = ['Stopped\.', 'Stopped at breakpoint \d+ \(\d+\) in thread \d+\.']
|
||||
if len(expectedBPOrder) == 0:
|
||||
expectedLabelTexts.append("Running\.")
|
||||
if not __startDebugger__(currentConfigName):
|
||||
if not __startDebugger__(kitCount, currentKit, currentConfigName):
|
||||
return False
|
||||
statusLabel = findObject(":Debugger Toolbar.StatusText_Utils::StatusLabel")
|
||||
test.log("Continuing debugging %d times..." % pressContinueCount)
|
||||
@@ -139,9 +142,22 @@ def doSimpleDebugging(currentConfigName, pressContinueCount=1, expectedBPOrder=[
|
||||
# if stopping failed - debugger had already stopped
|
||||
return True
|
||||
|
||||
def __startDebugger__(config):
|
||||
# param kitCount specifies the number of kits currently defined (must be correct!)
|
||||
# param currentKit specifies the target to use (zero based index)
|
||||
def isMsvcConfig(kitCount, currentKit):
|
||||
switchViewTo(ViewConstants.PROJECTS)
|
||||
switchToBuildOrRunSettingsFor(kitCount, currentKit, ProjectSettings.BUILD)
|
||||
isMsvc = " -spec win32-msvc" in str(waitForObject(":qmakeCallEdit").text)
|
||||
switchViewTo(ViewConstants.EDIT)
|
||||
return isMsvc
|
||||
|
||||
# param kitCount specifies the number of kits currently defined (must be correct!)
|
||||
# param currentKit specifies the target to use (zero based index)
|
||||
# param config is the name of the configuration that should be used
|
||||
def __startDebugger__(kitCount, currentKit, config):
|
||||
isMsvcBuild = isMsvcConfig(kitCount, currentKit)
|
||||
clickButton(waitForObject(":*Qt Creator.Start Debugging_Core::Internal::FancyToolButton"))
|
||||
handleDebuggerWarnings(config)
|
||||
handleDebuggerWarnings(config, isMsvcBuild)
|
||||
hasNotTimedOut = waitFor("object.exists(':Debugger Toolbar.Continue_QToolButton')", 60000)
|
||||
try:
|
||||
mBox = findObject(":Failed to start application_QMessageBox")
|
||||
|
||||
@@ -68,17 +68,12 @@ def openContextMenuOnTextCursorPosition(editor):
|
||||
waitFor("menuVisibleAtEditor(editor, menuInList)", 5000)
|
||||
return menuInList[0]
|
||||
|
||||
# this function marks/selects the text inside the given editor from position
|
||||
# startPosition to endPosition (both inclusive)
|
||||
def markText(editor, startPosition, endPosition):
|
||||
cursor = editor.textCursor()
|
||||
cursor.setPosition(startPosition)
|
||||
cursor.movePosition(QTextCursor.StartOfLine)
|
||||
editor.setTextCursor(cursor)
|
||||
cursor.movePosition(QTextCursor.Right, QTextCursor.KeepAnchor, endPosition-startPosition)
|
||||
cursor.movePosition(QTextCursor.EndOfLine, QTextCursor.KeepAnchor)
|
||||
cursor.setPosition(endPosition, QTextCursor.KeepAnchor)
|
||||
editor.setTextCursor(cursor)
|
||||
# this function marks/selects the text inside the given editor from current cursor position
|
||||
# param direction is one of "Left", "Right", "Up", "Down", but "End" and combinations work as well
|
||||
# param typeCount defines how often the cursor will be moved in the given direction (while marking)
|
||||
def markText(editor, direction, typeCount=1):
|
||||
for i in range(typeCount):
|
||||
type(editor, "<Shift+%s>" % direction)
|
||||
|
||||
# works for all standard editors
|
||||
def replaceEditorContent(editor, newcontent):
|
||||
@@ -294,6 +289,7 @@ def invokeFindUsage(editor, line, typeOperation, n=1):
|
||||
|
||||
def openDocument(treeElement):
|
||||
try:
|
||||
selectFromCombo(":Qt Creator_Core::Internal::NavComboBox", "Open Documents")
|
||||
navigator = waitForObject(":Qt Creator_Utils::NavigationTreeView")
|
||||
fileName = waitForObjectItem(navigator, treeElement).text
|
||||
doubleClickItem(navigator, treeElement, 5, 5, 0, Qt.LeftButton)
|
||||
|
||||
@@ -12,7 +12,7 @@ def __handleProcessExited__(object, exitCode):
|
||||
global processExited
|
||||
processExited = True
|
||||
|
||||
def openQmakeProject(projectPath, targets = QtQuickConstants.Targets.DESKTOP_474_GCC, fromWelcome = False):
|
||||
def openQmakeProject(projectPath, targets=QtQuickConstants.desktopTargetClasses(), fromWelcome=False):
|
||||
cleanUpUserFiles(projectPath)
|
||||
if fromWelcome:
|
||||
mouseClick(waitForObject(":OpenProject_QStyleItem"), 5, 5, 0, Qt.LeftButton)
|
||||
@@ -29,10 +29,11 @@ def openQmakeProject(projectPath, targets = QtQuickConstants.Targets.DESKTOP_474
|
||||
clickButton(waitForObject("{text='Yes' type='QPushButton' unnamed='1' visible='1'}"))
|
||||
except:
|
||||
pass
|
||||
__chooseTargets__(targets)
|
||||
checkedTargets = __chooseTargets__(targets)
|
||||
configureButton = waitForObject("{text='Configure Project' type='QPushButton' unnamed='1' visible='1'"
|
||||
"window=':Qt Creator_Core::Internal::MainWindow'}")
|
||||
clickButton(configureButton)
|
||||
return checkedTargets
|
||||
|
||||
def openCmakeProject(projectPath, buildDir):
|
||||
invokeMenuItem("File", "Open File or Project...")
|
||||
@@ -44,17 +45,18 @@ def openCmakeProject(projectPath, buildDir):
|
||||
mkspec = __getMkspecFromQmake__("qmake")
|
||||
test.log("Using mkspec '%s'" % mkspec)
|
||||
|
||||
generatorText = "Unix Generator (Desktop 474 GCC)"
|
||||
if "win32-" in mkspec:
|
||||
generatorName = {"win32-g++" : "MinGW Generator (MinGW from SDK)",
|
||||
"win32-msvc2008" : "NMake Generator (Microsoft Visual C++ Compiler 9.0 (x86))",
|
||||
"win32-msvc2010" : "NMake Generator (Microsoft Visual C++ Compiler 10.0 (x86))"}
|
||||
index = -1
|
||||
generatorName = {"win32-g++" : "MinGW Generator (Desktop 474 GCC)",
|
||||
"win32-msvc2008" : "NMake Generator (Desktop 474 MSVC2008)",
|
||||
"win32-msvc2010" : "NMake Generator (Desktop 474 MSVC2010)"}
|
||||
if mkspec in generatorName:
|
||||
index = generatorCombo.findText(generatorName[mkspec])
|
||||
if index == -1:
|
||||
test.warning("No matching CMake generator for mkspec '%s' found." % mkspec)
|
||||
else:
|
||||
generatorCombo.setCurrentIndex(index)
|
||||
generatorText = generatorName[mkspec]
|
||||
index = generatorCombo.findText(generatorText)
|
||||
if index == -1:
|
||||
test.warning("No matching CMake generator for mkspec '%s' found." % mkspec)
|
||||
else:
|
||||
generatorCombo.setCurrentIndex(index)
|
||||
|
||||
clickButton(waitForObject(":CMake Wizard.Run CMake_QPushButton"))
|
||||
try:
|
||||
@@ -110,13 +112,14 @@ def __createProjectSetNameAndPath__(path, projectName = None, checks = True):
|
||||
# param checks turns tests in the function on if set to True
|
||||
# param available a list holding the available targets
|
||||
def __selectQtVersionDesktop__(checks, available=None):
|
||||
__chooseTargets__(QtQuickConstants.Targets.DESKTOP_474_GCC, available)
|
||||
checkedTargets = __chooseTargets__(QtQuickConstants.desktopTargetClasses(), available)
|
||||
if checks:
|
||||
cbObject = ("{type='QCheckBox' text='%s' unnamed='1' visible='1' "
|
||||
"container={type='Utils::DetailsWidget' visible='1' unnamed='1'}}")
|
||||
verifyChecked(cbObject % "Debug")
|
||||
verifyChecked(cbObject % "Release")
|
||||
clickButton(waitForObject(":Next_QPushButton"))
|
||||
return checkedTargets
|
||||
|
||||
def __createProjectHandleLastPage__(expectedFiles = None):
|
||||
if expectedFiles != None:
|
||||
@@ -144,7 +147,7 @@ def createProject_Qt_GUI(path, projectName, checks = True):
|
||||
template = "Qt Gui Application"
|
||||
available = __createProjectOrFileSelectType__(" Applications", template)
|
||||
__createProjectSetNameAndPath__(path, projectName, checks)
|
||||
__selectQtVersionDesktop__(checks, available)
|
||||
checkedTargets = __selectQtVersionDesktop__(checks, available)
|
||||
|
||||
if checks:
|
||||
exp_filename = "mainwindow"
|
||||
@@ -174,6 +177,7 @@ def createProject_Qt_GUI(path, projectName, checks = True):
|
||||
|
||||
waitForSignal("{type='CppTools::Internal::CppModelManager' unnamed='1'}", "sourceFilesRefreshed(QStringList)", 20000)
|
||||
__verifyFileCreation__(path, expectedFiles)
|
||||
return checkedTargets
|
||||
|
||||
# Creates a Qt Console project
|
||||
# param path specifies where to create the project
|
||||
@@ -182,7 +186,7 @@ def createProject_Qt_GUI(path, projectName, checks = True):
|
||||
def createProject_Qt_Console(path, projectName, checks = True):
|
||||
available = __createProjectOrFileSelectType__(" Applications", "Qt Console Application")
|
||||
__createProjectSetNameAndPath__(path, projectName, checks)
|
||||
__selectQtVersionDesktop__(checks, available)
|
||||
checkedTargets = __selectQtVersionDesktop__(checks, available)
|
||||
|
||||
expectedFiles = None
|
||||
if checks:
|
||||
@@ -197,9 +201,10 @@ def createProject_Qt_Console(path, projectName, checks = True):
|
||||
|
||||
waitForSignal("{type='CppTools::Internal::CppModelManager' unnamed='1'}", "sourceFilesRefreshed(QStringList)", 10000)
|
||||
__verifyFileCreation__(path, expectedFiles)
|
||||
return checkedTargets
|
||||
|
||||
def createNewQtQuickApplication(workingDir, projectName = None, templateFile = None,
|
||||
targets = QtQuickConstants.Targets.DESKTOP_474_GCC, qtQuickVersion=1,
|
||||
targets=QtQuickConstants.desktopTargetClasses(), qtQuickVersion=1,
|
||||
fromWelcome=False):
|
||||
if templateFile:
|
||||
if qtQuickVersion == 2:
|
||||
@@ -215,12 +220,12 @@ def createNewQtQuickApplication(workingDir, projectName = None, templateFile = N
|
||||
type(baseLineEd, templateFile)
|
||||
nextButton = waitForObject(":Next_QPushButton")
|
||||
clickButton(nextButton)
|
||||
__chooseTargets__(targets, available)
|
||||
checkedTargets = __chooseTargets__(targets, available)
|
||||
snooze(1)
|
||||
nextButton = waitForObject(":Next_QPushButton")
|
||||
clickButton(nextButton)
|
||||
__createProjectHandleLastPage__()
|
||||
return projectName
|
||||
return checkedTargets, projectName
|
||||
|
||||
def createNewQtQuickUI(workingDir):
|
||||
__createProjectOrFileSelectType__(" Applications", "Qt Quick 1 UI")
|
||||
@@ -235,7 +240,7 @@ def createNewQmlExtension(workingDir):
|
||||
if workingDir == None:
|
||||
workingDir = tempDir()
|
||||
__createProjectSetNameAndPath__(workingDir)
|
||||
__chooseTargets__(QtQuickConstants.Targets.DESKTOP_474_GCC, available)
|
||||
checkedTargets = __chooseTargets__(QtQuickConstants.Targets.DESKTOP_474_GCC, available)
|
||||
nextButton = waitForObject(":Next_QPushButton")
|
||||
clickButton(nextButton)
|
||||
nameLineEd = waitForObject("{buddy={type='QLabel' text='Object Class-name:' unnamed='1' visible='1'} "
|
||||
@@ -246,6 +251,7 @@ def createNewQmlExtension(workingDir):
|
||||
replaceEditorContent(uriLineEd, "org.qt-project.test.qmlcomponents")
|
||||
clickButton(nextButton)
|
||||
__createProjectHandleLastPage__()
|
||||
return checkedTargets
|
||||
|
||||
# parameter components can only be one of the Constants defined in QtQuickConstants.Components
|
||||
def __chooseComponents__(components=QtQuickConstants.Components.BUILTIN):
|
||||
@@ -272,11 +278,14 @@ def __chooseTargets__(targets=QtQuickConstants.Targets.DESKTOP_474_GCC, availabl
|
||||
if platform.system() in ('Windows', 'Microsoft'):
|
||||
available.remove(QtQuickConstants.Targets.EMBEDDED_LINUX)
|
||||
available.append(QtQuickConstants.Targets.DESKTOP_474_MSVC2008)
|
||||
checkedTargets = []
|
||||
for current in available:
|
||||
mustCheck = targets & current == current
|
||||
try:
|
||||
ensureChecked("{type='QCheckBox' text='%s' visible='1'}" % QtQuickConstants.getStringForTarget(current),
|
||||
mustCheck, 3000)
|
||||
if (mustCheck):
|
||||
checkedTargets.append(current)
|
||||
except LookupError:
|
||||
if mustCheck:
|
||||
test.fail("Failed to check target '%s'." % QtQuickConstants.getStringForTarget(current))
|
||||
@@ -284,6 +293,7 @@ def __chooseTargets__(targets=QtQuickConstants.Targets.DESKTOP_474_GCC, availabl
|
||||
# Simulator has been added without knowing whether configured or not - so skip warning here?
|
||||
if current != QtQuickConstants.Targets.SIMULATOR:
|
||||
test.warning("Target '%s' is not set up correctly." % QtQuickConstants.getStringForTarget(current))
|
||||
return checkedTargets
|
||||
|
||||
# run and close an application
|
||||
# withHookInto - if set to True the function tries to attach to the sub-process instead of simply pressing Stop inside Creator
|
||||
|
||||
@@ -14,16 +14,17 @@ def verifyBuildAndRun():
|
||||
"Verifying if built app started and closed successfully.")
|
||||
|
||||
# run project for debug and release
|
||||
def runVerify():
|
||||
availableConfigs = iterateBuildConfigs(1)
|
||||
def runVerify(checkedTargets):
|
||||
availableConfigs = iterateBuildConfigs(len(checkedTargets))
|
||||
if not availableConfigs:
|
||||
test.fatal("Haven't found build configurations, quitting")
|
||||
invokeMenuItem("File", "Save All")
|
||||
invokeMenuItem("File", "Exit")
|
||||
# select debug configuration
|
||||
for kit, config in availableConfigs:
|
||||
selectBuildConfig(1, kit, config)
|
||||
selectBuildConfig(len(checkedTargets), kit, config)
|
||||
test.log("Using build config '%s'" % config)
|
||||
runAndCloseApp()
|
||||
if not runAndCloseApp():
|
||||
return
|
||||
verifyBuildAndRun()
|
||||
mouseClick(waitForObject(":*Qt Creator.Clear_QToolButton"))
|
||||
|
||||
@@ -5,8 +5,8 @@ source("../shared/aptw.py")
|
||||
# test New Qt Gui Application build and run for release and debug option
|
||||
def main():
|
||||
startApplication("qtcreator" + SettingsPath)
|
||||
createProject_Qt_GUI(tempDir(), "SampleApp")
|
||||
checkedTargets = createProject_Qt_GUI(tempDir(), "SampleApp")
|
||||
# run project for debug and release and verify results
|
||||
runVerify()
|
||||
runVerify(checkedTargets)
|
||||
#close Qt Creator
|
||||
invokeMenuItem("File", "Exit")
|
||||
|
||||
@@ -5,9 +5,9 @@ source("../shared/aptw.py")
|
||||
# test New Qt Quick Application build and run for release and debug option
|
||||
def main():
|
||||
startApplication("qtcreator" + SettingsPath)
|
||||
createNewQtQuickApplication(tempDir(), "SampleApp")
|
||||
checkedTargets, projectName = createNewQtQuickApplication(tempDir(), "SampleApp")
|
||||
waitForSignal("{type='CppTools::Internal::CppModelManager' unnamed='1'}", "sourceFilesRefreshed(QStringList)")
|
||||
# run project for debug and release and verify results
|
||||
runVerify()
|
||||
runVerify(checkedTargets)
|
||||
#close Qt Creator
|
||||
invokeMenuItem("File", "Exit")
|
||||
|
||||
@@ -13,13 +13,13 @@ def main():
|
||||
examplePath = os.path.join(templateDir, proFile)
|
||||
startApplication("qtcreator" + SettingsPath)
|
||||
# open example project
|
||||
openQmakeProject(examplePath)
|
||||
checkedTargets = openQmakeProject(examplePath)
|
||||
# build and wait until finished - on all build configurations
|
||||
availableConfigs = iterateBuildConfigs(1)
|
||||
availableConfigs = iterateBuildConfigs(len(checkedTargets))
|
||||
if not availableConfigs:
|
||||
test.fatal("Haven't found a suitable Qt version - leaving without building.")
|
||||
for kit, config in availableConfigs:
|
||||
selectBuildConfig(1, kit, config)
|
||||
selectBuildConfig(len(checkedTargets), kit, config)
|
||||
# try to build project
|
||||
test.log("Testing build configuration: " + config)
|
||||
invokeMenuItem("Build", "Build All")
|
||||
|
||||
@@ -28,8 +28,7 @@ def main():
|
||||
invokeMenuItem("File", "Exit")
|
||||
return
|
||||
type(editorWidget, "<Left>")
|
||||
for i in range(6):
|
||||
type(editorWidget, "<Shift+Left>")
|
||||
markText(editorWidget, "Left", 6)
|
||||
type(editorWidget, "<Ctrl+F>")
|
||||
# verify if find toolbar exists and if search text contains selected word
|
||||
test.verify(checkIfObjectExists(":*Qt Creator.Find_Find::Internal::FindToolBar"),
|
||||
@@ -49,8 +48,7 @@ def main():
|
||||
placeCursorToLine(editorWidget, "find.setOrientation(QmlApplicationfind::ScreenOrientationAuto);")
|
||||
for i in range(25):
|
||||
type(editorWidget, "<Left>")
|
||||
for i in range(18):
|
||||
type(editorWidget, "<Shift+Left>")
|
||||
markText(editorWidget, "Left", 18)
|
||||
invokeMenuItem("Edit", "Find/Replace", "Find/Replace")
|
||||
replaceEditorContent(waitForObject(":Qt Creator.replaceEdit_Utils::FilterLineEdit"), "QmlApplicationViewer")
|
||||
oldCodeText = str(editorWidget.plainText)
|
||||
|
||||
@@ -18,7 +18,7 @@ def main():
|
||||
placeCursorToLine(editorArea, testingCodeLine)
|
||||
for i in range(14):
|
||||
type(editorArea, "<Left>")
|
||||
type(editorArea, "<Shift+Right>")
|
||||
markText(editorArea, "Right")
|
||||
type(editorArea, "c")
|
||||
# invoke QML parsing
|
||||
invokeMenuItem("Tools", "QML/JS", "Run Checks")
|
||||
|
||||
@@ -5,13 +5,13 @@ source("../../shared/suites_qtta.py")
|
||||
def main():
|
||||
startApplication("qtcreator" + SettingsPath)
|
||||
# create qt quick application
|
||||
createNewQtQuickApplication(tempDir(), "SampleApp")
|
||||
checkedTargets, projectName = createNewQtQuickApplication(tempDir(), "SampleApp")
|
||||
# build it - on all build configurations
|
||||
availableConfigs = iterateBuildConfigs(1)
|
||||
availableConfigs = iterateBuildConfigs(len(checkedTargets))
|
||||
if not availableConfigs:
|
||||
test.fatal("Haven't found a suitable Qt version - leaving without building.")
|
||||
for kit, config in availableConfigs:
|
||||
selectBuildConfig(1, kit, config)
|
||||
selectBuildConfig(len(checkedTargets), kit, config)
|
||||
# try to compile
|
||||
test.log("Testing build configuration: " + config)
|
||||
clickButton(waitForObject(":*Qt Creator.Build Project_Core::Internal::FancyToolButton"))
|
||||
|
||||
@@ -8,7 +8,7 @@ def main():
|
||||
"'SyntaxError' : undeclared identifier"]
|
||||
startApplication("qtcreator" + SettingsPath)
|
||||
# create qt quick application
|
||||
createNewQtQuickApplication(tempDir(), "SampleApp")
|
||||
checkedTargets, projectName = createNewQtQuickApplication(tempDir(), "SampleApp")
|
||||
# create syntax error in cpp file
|
||||
doubleClickItem(":Qt Creator_Utils::NavigationTreeView", "SampleApp.Sources.main\\.cpp", 5, 5, 0, Qt.LeftButton)
|
||||
if not appendToLine(waitForObject(":Qt Creator_CppEditor::Internal::CPPEditorWidget"), "viewer.showExpanded();", "SyntaxError"):
|
||||
@@ -17,11 +17,11 @@ def main():
|
||||
# save all
|
||||
invokeMenuItem("File", "Save All")
|
||||
# build it - on all build configurations
|
||||
availableConfigs = iterateBuildConfigs(1)
|
||||
availableConfigs = iterateBuildConfigs(len(checkedTargets))
|
||||
if not availableConfigs:
|
||||
test.fatal("Haven't found a suitable Qt version - leaving without building.")
|
||||
for kit, config in availableConfigs:
|
||||
selectBuildConfig(1, kit, config)
|
||||
selectBuildConfig(len(checkedTargets), kit, config)
|
||||
# try to compile
|
||||
test.log("Testing build configuration: " + config)
|
||||
clickButton(waitForObject(":*Qt Creator.Build Project_Core::Internal::FancyToolButton"))
|
||||
|
||||
@@ -4,12 +4,13 @@ project = "SquishProject"
|
||||
|
||||
def main():
|
||||
startApplication("qtcreator" + SettingsPath)
|
||||
createProject_Qt_Console(tempDir(), project)
|
||||
availableConfigs = iterateBuildConfigs(1)
|
||||
checkedTargets = createProject_Qt_Console(tempDir(), project)
|
||||
availableConfigs = iterateBuildConfigs(len(checkedTargets))
|
||||
if not availableConfigs:
|
||||
test.fatal("Haven't found a suitable Qt version - leaving without building.")
|
||||
for kit, config in availableConfigs:
|
||||
selectBuildConfig(1, kit, config)
|
||||
selectBuildConfig(len(checkedTargets), kit, config)
|
||||
test.log("Testing build configuration: " + config)
|
||||
runAndCloseApp()
|
||||
if not runAndCloseApp():
|
||||
return
|
||||
invokeMenuItem("File", "Exit")
|
||||
|
||||
@@ -17,7 +17,7 @@ def main():
|
||||
startApplication("qtcreator" + SettingsPath)
|
||||
installLazySignalHandler("{type='ProjectExplorer::Internal::ProjectExplorerPlugin' unnamed='1'}",
|
||||
"runControlFinished(ProjectExplorer::RunControl*)", "__handlerunControlFinished__")
|
||||
createProject_Qt_Console(tempDir(), project)
|
||||
checkedTargets = createProject_Qt_Console(tempDir(), project)
|
||||
|
||||
mainEditor = waitForObject(":Qt Creator_CppEditor::Internal::CPPEditorWidget")
|
||||
replaceEditorContent(mainEditor, "")
|
||||
@@ -33,38 +33,44 @@ def main():
|
||||
selectFromLocator(project + ".pro")
|
||||
proEditor = waitForObject(":Qt Creator_ProFileEditorWidget")
|
||||
test.verify("CONFIG += console" in str(proEditor.plainText), "Verifying that program is configured with console")
|
||||
setRunInTerminal(1, 0, False)
|
||||
|
||||
availableConfigs = iterateBuildConfigs(1)
|
||||
availableConfigs = iterateBuildConfigs(len(checkedTargets))
|
||||
if not availableConfigs:
|
||||
test.fatal("Haven't found a suitable Qt version - leaving without building.")
|
||||
for kit, config in availableConfigs:
|
||||
selectBuildConfig(1, kit, config)
|
||||
selectBuildConfig(len(checkedTargets), kit, config)
|
||||
test.log("Testing build configuration: " + config)
|
||||
|
||||
test.log("Running application")
|
||||
setRunInTerminal(len(checkedTargets), kit, False)
|
||||
runControlFinished = False
|
||||
clickButton(waitForObject("{type='Core::Internal::FancyToolButton' text='Run' visible='1'}"))
|
||||
waitFor("runControlFinished==True", 20000)
|
||||
if not runControlFinished:
|
||||
test.warning("Waiting for runControlFinished timed out")
|
||||
appOutput = str(waitForObject("{type='Core::OutputWindow' unnamed='1' visible='1'}").plainText)
|
||||
verifyOutput(appOutput, outputStdOut, "std::cout", "Application Output")
|
||||
verifyOutput(appOutput, outputStdErr, "std::cerr", "Application Output")
|
||||
verifyOutput(appOutput, outputQDebug, "qDebug()", "Application Output")
|
||||
clickButton(waitForObject(":Qt Creator_CloseButton"))
|
||||
ensureChecked(":Qt Creator_AppOutput_Core::Internal::OutputPaneToggleButton")
|
||||
try:
|
||||
appOutput = str(waitForObject("{type='Core::OutputWindow' unnamed='1' visible='1'}").plainText)
|
||||
verifyOutput(appOutput, outputStdOut, "std::cout", "Application Output")
|
||||
verifyOutput(appOutput, outputStdErr, "std::cerr", "Application Output")
|
||||
verifyOutput(appOutput, outputQDebug, "qDebug()", "Application Output")
|
||||
clickButton(waitForObject(":Qt Creator_CloseButton"))
|
||||
except:
|
||||
test.fatal("Could not find Application Output Window",
|
||||
"Did the application run at all?")
|
||||
|
||||
test.log("Debugging application")
|
||||
isMsvc = isMsvcConfig(len(checkedTargets), kit)
|
||||
runControlFinished = False
|
||||
invokeMenuItem("Debug", "Start Debugging", "Start Debugging")
|
||||
JIRA.performWorkaroundIfStillOpen(6853, JIRA.Bug.CREATOR, config)
|
||||
handleDebuggerWarnings(config)
|
||||
handleDebuggerWarnings(config, isMsvc)
|
||||
waitFor("runControlFinished==True", 20000)
|
||||
if not runControlFinished:
|
||||
test.warning("Waiting for runControlFinished timed out")
|
||||
try:
|
||||
debuggerLog = takeDebuggerLog()
|
||||
if not "MSVC" in config:
|
||||
if not isMsvc:
|
||||
# cout works with MSVC, too, but we don't check it since it's not supported
|
||||
verifyOutput(debuggerLog, outputStdOut, "std::cout", "Debugger Log")
|
||||
verifyOutput(debuggerLog, outputStdErr, "std::cerr", "Debugger Log")
|
||||
@@ -78,11 +84,16 @@ def main():
|
||||
else:
|
||||
test.fatal("Debugger log did not behave as expected. Please check manually.")
|
||||
switchViewTo(ViewConstants.EDIT)
|
||||
appOutput = str(waitForObject("{type='Core::OutputWindow' unnamed='1' visible='1'}").plainText)
|
||||
if not "MSVC" in config:
|
||||
verifyOutput(appOutput, outputStdOut, "std::cout", "Application Output")
|
||||
verifyOutput(appOutput, outputStdErr, "std::cerr", "Application Output")
|
||||
verifyOutput(appOutput, outputQDebug, "qDebug()", "Application Output")
|
||||
clickButton(waitForObject(":Qt Creator_CloseButton"))
|
||||
ensureChecked(":Qt Creator_AppOutput_Core::Internal::OutputPaneToggleButton")
|
||||
try:
|
||||
appOutput = str(waitForObject("{type='Core::OutputWindow' unnamed='1' visible='1'}").plainText)
|
||||
if not isMsvc:
|
||||
verifyOutput(appOutput, outputStdOut, "std::cout", "Application Output")
|
||||
verifyOutput(appOutput, outputStdErr, "std::cerr", "Application Output")
|
||||
verifyOutput(appOutput, outputQDebug, "qDebug()", "Application Output")
|
||||
clickButton(waitForObject(":Qt Creator_CloseButton"))
|
||||
except:
|
||||
test.fatal("Could not find Application Output Window",
|
||||
"Did the application run at all?")
|
||||
|
||||
invokeMenuItem("File", "Exit")
|
||||
|
||||
@@ -5,13 +5,16 @@ workingDir = None
|
||||
def main():
|
||||
global workingDir
|
||||
startApplication("qtcreator" + SettingsPath)
|
||||
if not checkDebuggingLibrary([QtQuickConstants.Targets.DESKTOP_474_GCC]):
|
||||
targets = [QtQuickConstants.Targets.DESKTOP_474_GCC]
|
||||
if platform.system() in ('Windows', 'Microsoft'):
|
||||
targets.append(QtQuickConstants.Targets.DESKTOP_474_MSVC2008)
|
||||
if not checkDebuggingLibrary(targets):
|
||||
test.fatal("Error while checking debugging libraries - leaving this test.")
|
||||
invokeMenuItem("File", "Exit")
|
||||
return
|
||||
# using a temporary directory won't mess up a potentially existing
|
||||
workingDir = tempDir()
|
||||
projectName = createNewQtQuickApplication(workingDir, targets = QtQuickConstants.Targets.DESKTOP_474_GCC)
|
||||
checkedTargets, projectName = createNewQtQuickApplication(workingDir)
|
||||
# wait for parsing to complete
|
||||
waitForSignal("{type='CppTools::Internal::CppModelManager' unnamed='1'}",
|
||||
"sourceFilesRefreshed(QStringList)")
|
||||
@@ -33,13 +36,13 @@ def main():
|
||||
if result:
|
||||
expectedBreakpointsOrder = [{"main.cpp":10}, {"main.qml":13}]
|
||||
# Only use 4.7.4 to work around QTBUG-25187
|
||||
availableConfigs = iterateBuildConfigs(1, "Debug")
|
||||
availableConfigs = iterateBuildConfigs(len(checkedTargets), "Debug")
|
||||
if not availableConfigs:
|
||||
test.fatal("Haven't found a suitable Qt version (need Qt 4.7.4) - leaving without debugging.")
|
||||
for kit, config in availableConfigs:
|
||||
test.log("Selecting '%s' as build config" % config)
|
||||
selectBuildConfig(1, kit, config)
|
||||
verifyBuildConfig(1, kit, True, enableQmlDebug=True)
|
||||
selectBuildConfig(len(checkedTargets), kit, config)
|
||||
verifyBuildConfig(len(checkedTargets), kit, True, enableQmlDebug=True)
|
||||
# explicitly build before start debugging for adding the executable as allowed program to WinFW
|
||||
invokeMenuItem("Build", "Rebuild All")
|
||||
waitForSignal("{type='ProjectExplorer::BuildManager' unnamed='1'}",
|
||||
@@ -48,7 +51,8 @@ def main():
|
||||
test.fatal("Compile had errors... Skipping current build config")
|
||||
continue
|
||||
allowAppThroughWinFW(workingDir, projectName, False)
|
||||
if not doSimpleDebugging(config, 2, expectedBreakpointsOrder):
|
||||
if not doSimpleDebugging(len(checkedTargets), kit, config,
|
||||
2, expectedBreakpointsOrder):
|
||||
try:
|
||||
stopB = findObject(':Qt Creator.Stop_QToolButton')
|
||||
if stopB.enabled:
|
||||
|
||||
@@ -25,13 +25,19 @@ def prepareQmlFile():
|
||||
for i in range(3):
|
||||
content = "%s" % editor.plainText
|
||||
start = content.find("Text {")
|
||||
end = content.rfind("}")
|
||||
end = content.rfind("}", end-1)
|
||||
if start==-1 or end==-1:
|
||||
if not placeCursorToLine(editor, "Text {"):
|
||||
test.fatal("Couldn't find line(s) I'm looking for - QML file seems to "
|
||||
"have changed!\nLeaving test...")
|
||||
return False
|
||||
markText(editor, start, end)
|
||||
type(editor, "<Right>")
|
||||
type(editor, "<Up>")
|
||||
# mark until the end of file
|
||||
if platform.system() == 'Darwin':
|
||||
markText(editor, "End")
|
||||
else:
|
||||
markText(editor, "Ctrl+End")
|
||||
# unmark the last line
|
||||
type(editor, "<Shift+Up>")
|
||||
type(editor, "<Ctrl+C>")
|
||||
for j in range(10):
|
||||
type(editor, "<Ctrl+V>")
|
||||
|
||||
@@ -27,8 +27,7 @@ def testRenameMacroAfterSourceModification():
|
||||
type(cppEditorStr, "<Command+Left>")
|
||||
else:
|
||||
type(cppEditorStr, "<Home>")
|
||||
for i in range(5):
|
||||
type(cppEditorStr, "<Shift+Down>")
|
||||
markText(cppEditorStr, "Down", 5)
|
||||
type(cppEditorStr, "<Delete>")
|
||||
|
||||
test.log("Testing rename macro after modifying source.")
|
||||
@@ -54,8 +53,7 @@ def testRenameMacroAfterSourceMoving():
|
||||
type(cppEditorStr, "<Command+Left>")
|
||||
else:
|
||||
type(cppEditorStr, "<Home>")
|
||||
for i in range(4):
|
||||
type(cppEditorStr, "<Shift+Down>")
|
||||
markText(cppEditorStr, "Down", 4)
|
||||
invokeMenuItem("Edit", "Cut")
|
||||
|
||||
def __paste__():
|
||||
|
||||
@@ -62,8 +62,7 @@ def __modifyHeader__():
|
||||
global cppEditorStr, homeShortCut, endShortCut
|
||||
if placeCursorToLine(cppEditorStr, "class.+", True):
|
||||
type(cppEditorStr, homeShortCut)
|
||||
for i in range(5):
|
||||
type(cppEditorStr, "<Shift+Down>")
|
||||
markText(cppEditorStr, "Down", 5)
|
||||
invokeMenuItem("Edit", "Cut")
|
||||
type(cppEditorStr, endShortCut)
|
||||
type(cppEditorStr, "<Return>")
|
||||
@@ -74,12 +73,11 @@ def __modifySource__():
|
||||
global cppEditorStr, homeShortCut
|
||||
if placeCursorToLine(cppEditorStr, "void function1(int a);"):
|
||||
type(cppEditorStr, homeShortCut)
|
||||
type(cppEditorStr, "<Shift+Down>")
|
||||
markText(cppEditorStr, "Down")
|
||||
type(cppEditorStr, "<Delete>")
|
||||
if placeCursorToLine(cppEditorStr, "bool function1(int a) {"):
|
||||
type(cppEditorStr, homeShortCut)
|
||||
for i in range(4):
|
||||
type(cppEditorStr, "<Shift+Down>")
|
||||
markText(cppEditorStr, "Down", 4)
|
||||
type(cppEditorStr, "<Delete>")
|
||||
|
||||
def revertChanges(files):
|
||||
|
||||
@@ -15,16 +15,16 @@ def main():
|
||||
if not neededFilePresent(SpeedCrunchPath):
|
||||
return
|
||||
startApplication("qtcreator" + SettingsPath)
|
||||
openQmakeProject(SpeedCrunchPath)
|
||||
checkedTargets = openQmakeProject(SpeedCrunchPath)
|
||||
waitForSignal("{type='CppTools::Internal::CppModelManager' unnamed='1'}", "sourceFilesRefreshed(QStringList)")
|
||||
|
||||
fancyToolButton = waitForObject(":*Qt Creator_Core::Internal::FancyToolButton")
|
||||
|
||||
availableConfigs = iterateBuildConfigs(1, "Release")
|
||||
availableConfigs = iterateBuildConfigs(len(checkedTargets), "Release")
|
||||
if not availableConfigs:
|
||||
test.fatal("Haven't found a suitable Qt version (need Release build) - leaving without building.")
|
||||
for kit, config in availableConfigs:
|
||||
selectBuildConfig(1, kit, config)
|
||||
selectBuildConfig(len(checkedTargets), kit, config)
|
||||
buildConfig = buildConfigFromFancyToolButton(fancyToolButton)
|
||||
if buildConfig != config:
|
||||
test.fatal("Build configuration %s is selected instead of %s" % (buildConfig, config))
|
||||
|
||||
@@ -7,6 +7,6 @@ HOOK_SUB_PROCESSES=false
|
||||
IMPLICITAUTSTART=0
|
||||
LANGUAGE=Python
|
||||
OBJECTMAP=../objects.map
|
||||
TEST_CASES=tst_qtquick_creation tst_qtquick_creation2 tst_qtquick_creation3 tst_qtquick_creation4
|
||||
TEST_CASES=tst_qml_outline tst_qtquick_creation tst_qtquick_creation2 tst_qtquick_creation3 tst_qtquick_creation4
|
||||
VERSION=2
|
||||
WRAPPERS=Qt
|
||||
|
||||
@@ -0,0 +1,121 @@
|
||||
source("../../shared/qtcreator.py")
|
||||
|
||||
qmlEditor = ":Qt Creator_QmlJSEditor::QmlJSTextEditorWidget"
|
||||
outline = ":Qt Creator_QmlJSEditor::Internal::QmlJSOutlineTreeView"
|
||||
|
||||
def main():
|
||||
sourceExample = os.path.abspath(os.path.join(sdkPath, "Examples", "4.7", "declarative",
|
||||
"keyinteraction", "focus"))
|
||||
proFile = "focus.pro"
|
||||
if not neededFilePresent(os.path.join(sourceExample, proFile)):
|
||||
return
|
||||
templateDir = prepareTemplate(sourceExample)
|
||||
startApplication("qtcreator" + SettingsPath)
|
||||
openQmakeProject(os.path.join(templateDir, proFile))
|
||||
qmlFiles = ["focus.QML.qml.focus\\.qml", "focus.QML.qml.Core.ListMenu\\.qml"]
|
||||
checkOutlineFor(qmlFiles)
|
||||
testModify()
|
||||
invokeMenuItem("File", "Save All")
|
||||
invokeMenuItem("File", "Exit")
|
||||
|
||||
def checkOutlineFor(qmlFiles):
|
||||
for qmlFile in qmlFiles:
|
||||
if not openDocument(qmlFile):
|
||||
test.fatal("Failed to open file '%s'" % simpleFileName(qmlFile))
|
||||
continue
|
||||
selectFromCombo(":Qt Creator_Core::Internal::NavComboBox", "Outline")
|
||||
pseudoTree = buildTreeFromOutline()
|
||||
# __writeOutlineFile__(pseudoTree, simpleFileName(qmlFile)+"_outline.tsv")
|
||||
verifyOutline(pseudoTree, simpleFileName(qmlFile) + "_outline.tsv")
|
||||
|
||||
def buildTreeFromOutline():
|
||||
global outline
|
||||
model = waitForObject(outline).model()
|
||||
waitFor("model.rowCount() > 0")
|
||||
return processChildren(model, QModelIndex(), 0)
|
||||
|
||||
def processChildren(model, startIndex, level):
|
||||
children = []
|
||||
for index in dumpIndices(model, startIndex):
|
||||
annotationData = str(index.data(Qt.UserRole + 3)) # HACK - taken from source
|
||||
children.append((str(index.data()), level, annotationData))
|
||||
if model.hasChildren(index):
|
||||
children.extend(processChildren(model, index, level + 1))
|
||||
return children
|
||||
|
||||
def testModify():
|
||||
global qmlEditor, outline
|
||||
if not openDocument("focus.QML.qml.focus\\.qml"):
|
||||
test.fatal("Failed to open file focus.qml")
|
||||
return
|
||||
test.log("Testing whether modifications show up inside outline.")
|
||||
if not placeCursorToLine(qmlEditor, 'color: "#3E606F"'):
|
||||
return
|
||||
test.log("Modification: adding a QML element")
|
||||
typeLines(qmlEditor, ['', '', 'Text {', 'id: addedText', 'text: "Squish QML outline test"',
|
||||
'color: "darkcyan"', 'font.bold: true', 'anchors.centerIn: parent'])
|
||||
selectFromCombo(":Qt Creator_Core::Internal::NavComboBox", "Outline")
|
||||
snooze(1) # no way to wait for a private signal
|
||||
pseudoTree = buildTreeFromOutline()
|
||||
# __writeOutlineFile__(pseudoTree, "focus.qml_mod1_outline.tsv")
|
||||
verifyOutline(pseudoTree, "focus.qml_mod1_outline.tsv")
|
||||
test.log("Modification: change existing content")
|
||||
performModification('color: "#3E606F"', "<Left>", 7, "Left", "white")
|
||||
performModification('color: "black"', "<Left>", 5, "Left", "#cc00bb")
|
||||
performModification('rotation: 90', None, 2, "Left", "180")
|
||||
snooze(1) # no way to wait for a private signal
|
||||
pseudoTree = buildTreeFromOutline()
|
||||
# __writeOutlineFile__(pseudoTree, "focus.qml_mod2_outline.tsv")
|
||||
verifyOutline(pseudoTree, "focus.qml_mod2_outline.tsv")
|
||||
test.log("Modification: add special elements")
|
||||
placeCursorToLine(qmlEditor, 'id: window')
|
||||
typeLines(qmlEditor, ['', '', 'property string txtCnt: "Property"', 'signal clicked', '',
|
||||
'function clicked() {','console.log("click")'])
|
||||
performModification('onClicked: contextMenu.focus = true', None, 24, "Left", '{')
|
||||
performModification('onClicked: {contextMenu.focus = true}', "<Left>", 0, None,
|
||||
';window.clicked()')
|
||||
snooze(1) # no way to wait for a private signal
|
||||
pseudoTree = buildTreeFromOutline()
|
||||
# __writeOutlineFile__(pseudoTree, "focus.qml_mod3_outline.tsv")
|
||||
verifyOutline(pseudoTree, "focus.qml_mod3_outline.tsv")
|
||||
|
||||
def performModification(afterLine, typing, markCount, markDirection, newText):
|
||||
global qmlEditor
|
||||
if not placeCursorToLine(qmlEditor, afterLine):
|
||||
return
|
||||
if typing:
|
||||
type(qmlEditor, typing)
|
||||
markText(qmlEditor, markDirection, markCount)
|
||||
type(qmlEditor, newText)
|
||||
|
||||
# used to create the tsv file(s)
|
||||
def __writeOutlineFile__(outlinePseudoTree, filename):
|
||||
f = open(filename, "w+")
|
||||
f.write('"element"\t"nestinglevel"\t"value"\n')
|
||||
for elem in outlinePseudoTree:
|
||||
f.write('"%s"\t"%s"\t"%s"\n' % (elem[0], elem[1], elem[2].replace('"', '\"\"')))
|
||||
f.close()
|
||||
|
||||
def retrieveData(record):
|
||||
return (testData.field(record, "element"),
|
||||
__builtin__.int(testData.field(record, "nestinglevel")),
|
||||
testData.field(record, "value"))
|
||||
|
||||
def verifyOutline(outlinePseudoTree, datasetFileName):
|
||||
fileName = datasetFileName[:datasetFileName.index("_")]
|
||||
expected = map(retrieveData, testData.dataset(datasetFileName))
|
||||
if len(expected) != len(outlinePseudoTree):
|
||||
test.fail("Mismatch in length of expected and found elements of outline. Skipping "
|
||||
"verification of nodes.",
|
||||
"Found %d elements, but expected %d" % (len(outlinePseudoTree), len(expected)))
|
||||
return
|
||||
for counter, (expectedItem, foundItem) in enumerate(zip(expected, outlinePseudoTree)):
|
||||
if expectedItem != foundItem:
|
||||
test.fail("Mismatch in element number %d for '%s'" % (counter + 1, fileName),
|
||||
"%s != %s" % (str(expectedItem), str(foundItem)))
|
||||
return
|
||||
test.passes("All nodes (%d) inside outline match expected nodes for '%s'."
|
||||
% (len(expected), fileName))
|
||||
|
||||
def simpleFileName(navigatorFileName):
|
||||
return ".".join(navigatorFileName.split(".")[-2:]).replace("\\", "")
|
||||
@@ -0,0 +1,85 @@
|
||||
"element" "nestinglevel" "value"
|
||||
"FocusScope" "0" ""
|
||||
"clip" "1" "true"
|
||||
"onActiveFocusChanged" "1" ""
|
||||
"ListView" "1" ""
|
||||
"id" "2" "list1"
|
||||
"y" "2" "activeFocus ? 10 : 40"
|
||||
"width" "2" "parent.width / 3"
|
||||
"height" "2" "parent.height - 20"
|
||||
"focus" "2" "true"
|
||||
"KeyNavigation.up" "2" "gridMenu"
|
||||
"KeyNavigation.left" "2" "contextMenu"
|
||||
"KeyNavigation.right" "2" "list2"
|
||||
"model" "2" "10"
|
||||
"cacheBuffer" "2" "200"
|
||||
"delegate" "2" ""
|
||||
"ListViewDelegate" "3" ""
|
||||
"y" "2" ""
|
||||
"Behavior" "3" ""
|
||||
"NumberAnimation" "4" ""
|
||||
"duration" "5" "600"
|
||||
"easing.type" "5" "Easing.OutQuint"
|
||||
"ListView" "1" ""
|
||||
"id" "2" "list2"
|
||||
"y" "2" "activeFocus ? 10 : 40"
|
||||
"x" "2" "parseInt(parent.width / 3)"
|
||||
"width" "2" "parent.width / 3"
|
||||
"height" "2" "parent.height - 20"
|
||||
"KeyNavigation.up" "2" "gridMenu"
|
||||
"KeyNavigation.left" "2" "list1"
|
||||
"KeyNavigation.right" "2" "list3"
|
||||
"model" "2" "10"
|
||||
"cacheBuffer" "2" "200"
|
||||
"delegate" "2" ""
|
||||
"ListViewDelegate" "3" ""
|
||||
"y" "2" ""
|
||||
"Behavior" "3" ""
|
||||
"NumberAnimation" "4" ""
|
||||
"duration" "5" "600"
|
||||
"easing.type" "5" "Easing.OutQuint"
|
||||
"ListView" "1" ""
|
||||
"id" "2" "list3"
|
||||
"y" "2" "activeFocus ? 10 : 40"
|
||||
"x" "2" "parseInt(2 * parent.width / 3)"
|
||||
"width" "2" "parent.width / 3"
|
||||
"height" "2" "parent.height - 20"
|
||||
"KeyNavigation.up" "2" "gridMenu"
|
||||
"KeyNavigation.left" "2" "list2"
|
||||
"model" "2" "10"
|
||||
"cacheBuffer" "2" "200"
|
||||
"delegate" "2" ""
|
||||
"ListViewDelegate" "3" ""
|
||||
"y" "2" ""
|
||||
"Behavior" "3" ""
|
||||
"NumberAnimation" "4" ""
|
||||
"duration" "5" "600"
|
||||
"easing.type" "5" "Easing.OutQuint"
|
||||
"Rectangle" "1" ""
|
||||
"width" "2" "parent.width"
|
||||
"height" "2" "1"
|
||||
"color" "2" """#D1DBBD"""
|
||||
"Rectangle" "1" ""
|
||||
"y" "2" "1"
|
||||
"width" "2" "parent.width"
|
||||
"height" "2" "10"
|
||||
"gradient" "2" ""
|
||||
"Gradient" "3" ""
|
||||
"GradientStop" "4" ""
|
||||
"position" "5" "0.0"
|
||||
"color" "5" """#3E606F"""
|
||||
"GradientStop" "4" ""
|
||||
"position" "5" "1.0"
|
||||
"color" "5" """transparent"""
|
||||
"Rectangle" "1" ""
|
||||
"y" "2" "parent.height - 10"
|
||||
"width" "2" "parent.width"
|
||||
"height" "2" "10"
|
||||
"gradient" "2" ""
|
||||
"Gradient" "3" ""
|
||||
"GradientStop" "4" ""
|
||||
"position" "5" "1.0"
|
||||
"color" "5" """#3E606F"""
|
||||
"GradientStop" "4" ""
|
||||
"position" "5" "0.0"
|
||||
"color" "5" """transparent"""
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
"element" "nestinglevel" "value"
|
||||
"Rectangle" "0" ""
|
||||
"id" "1" "window"
|
||||
"width" "1" "800"
|
||||
"height" "1" "480"
|
||||
"color" "1" """#3E606F"""
|
||||
"Text" "1" ""
|
||||
"id" "2" "addedText"
|
||||
"text" "2" """Squish QML outline test"""
|
||||
"color" "2" """darkcyan"""
|
||||
"font.bold" "2" "true"
|
||||
"anchors.centerIn" "2" "parent"
|
||||
"FocusScope" "1" ""
|
||||
"id" "2" "mainView"
|
||||
"width" "2" "parent.width"
|
||||
"height" "2" "parent.height"
|
||||
"focus" "2" "true"
|
||||
"GridMenu" "2" ""
|
||||
"id" "3" "gridMenu"
|
||||
"width" "3" "parent.width"
|
||||
"height" "3" "320"
|
||||
"focus" "3" "true"
|
||||
"interactive" "3" "parent.activeFocus"
|
||||
"ListMenu" "2" ""
|
||||
"id" "3" "listMenu"
|
||||
"y" "3" "320"
|
||||
"width" "3" "parent.width"
|
||||
"height" "3" "320"
|
||||
"Rectangle" "2" ""
|
||||
"id" "3" "shade"
|
||||
"anchors.fill" "3" "parent"
|
||||
"color" "3" """black"""
|
||||
"opacity" "3" "0"
|
||||
"states" "2" ""
|
||||
"State" "3" ""
|
||||
"name" "4" """showListViews"""
|
||||
"PropertyChanges" "4" ""
|
||||
"target" "5" "gridMenu"
|
||||
"y" "5" "-160"
|
||||
"PropertyChanges" "4" ""
|
||||
"target" "5" "listMenu"
|
||||
"y" "5" "160"
|
||||
"transitions" "2" ""
|
||||
"Transition" "3" ""
|
||||
"NumberAnimation" "4" ""
|
||||
"properties" "5" """y"""
|
||||
"duration" "5" "600"
|
||||
"easing.type" "5" "Easing.OutQuint"
|
||||
"Image" "1" ""
|
||||
"source" "2" """Core/images/arrow.png"""
|
||||
"rotation" "2" "90"
|
||||
"anchors.verticalCenter" "2" "parent.verticalCenter"
|
||||
"MouseArea" "2" ""
|
||||
"anchors.fill" "3" "parent"
|
||||
"anchors.margins" "3" "-10"
|
||||
"onClicked" "3" "contextMenu.focus = true"
|
||||
"ContextMenu" "1" ""
|
||||
"id" "2" "contextMenu"
|
||||
"x" "2" "-265"
|
||||
"width" "2" "260"
|
||||
"height" "2" "parent.height"
|
||||
"states" "1" ""
|
||||
"State" "2" ""
|
||||
"name" "3" """contextMenuOpen"""
|
||||
"when" "3" "!mainView.activeFocus"
|
||||
"PropertyChanges" "3" ""
|
||||
"target" "4" "contextMenu"
|
||||
"x" "4" "0"
|
||||
"open" "4" "true"
|
||||
"PropertyChanges" "3" ""
|
||||
"target" "4" "mainView"
|
||||
"x" "4" "130"
|
||||
"PropertyChanges" "3" ""
|
||||
"target" "4" "shade"
|
||||
"opacity" "4" "0.25"
|
||||
"transitions" "1" ""
|
||||
"Transition" "2" ""
|
||||
"NumberAnimation" "3" ""
|
||||
"properties" "4" """x,opacity"""
|
||||
"duration" "4" "600"
|
||||
"easing.type" "4" "Easing.OutQuint"
|
||||
|
+81
@@ -0,0 +1,81 @@
|
||||
"element" "nestinglevel" "value"
|
||||
"Rectangle" "0" ""
|
||||
"id" "1" "window"
|
||||
"width" "1" "800"
|
||||
"height" "1" "480"
|
||||
"color" "1" """white"""
|
||||
"Text" "1" ""
|
||||
"id" "2" "addedText"
|
||||
"text" "2" """Squish QML outline test"""
|
||||
"color" "2" """darkcyan"""
|
||||
"font.bold" "2" "true"
|
||||
"anchors.centerIn" "2" "parent"
|
||||
"FocusScope" "1" ""
|
||||
"id" "2" "mainView"
|
||||
"width" "2" "parent.width"
|
||||
"height" "2" "parent.height"
|
||||
"focus" "2" "true"
|
||||
"GridMenu" "2" ""
|
||||
"id" "3" "gridMenu"
|
||||
"width" "3" "parent.width"
|
||||
"height" "3" "320"
|
||||
"focus" "3" "true"
|
||||
"interactive" "3" "parent.activeFocus"
|
||||
"ListMenu" "2" ""
|
||||
"id" "3" "listMenu"
|
||||
"y" "3" "320"
|
||||
"width" "3" "parent.width"
|
||||
"height" "3" "320"
|
||||
"Rectangle" "2" ""
|
||||
"id" "3" "shade"
|
||||
"anchors.fill" "3" "parent"
|
||||
"color" "3" """#cc00bb"""
|
||||
"opacity" "3" "0"
|
||||
"states" "2" ""
|
||||
"State" "3" ""
|
||||
"name" "4" """showListViews"""
|
||||
"PropertyChanges" "4" ""
|
||||
"target" "5" "gridMenu"
|
||||
"y" "5" "-160"
|
||||
"PropertyChanges" "4" ""
|
||||
"target" "5" "listMenu"
|
||||
"y" "5" "160"
|
||||
"transitions" "2" ""
|
||||
"Transition" "3" ""
|
||||
"NumberAnimation" "4" ""
|
||||
"properties" "5" """y"""
|
||||
"duration" "5" "600"
|
||||
"easing.type" "5" "Easing.OutQuint"
|
||||
"Image" "1" ""
|
||||
"source" "2" """Core/images/arrow.png"""
|
||||
"rotation" "2" "180"
|
||||
"anchors.verticalCenter" "2" "parent.verticalCenter"
|
||||
"MouseArea" "2" ""
|
||||
"anchors.fill" "3" "parent"
|
||||
"anchors.margins" "3" "-10"
|
||||
"onClicked" "3" "contextMenu.focus = true"
|
||||
"ContextMenu" "1" ""
|
||||
"id" "2" "contextMenu"
|
||||
"x" "2" "-265"
|
||||
"width" "2" "260"
|
||||
"height" "2" "parent.height"
|
||||
"states" "1" ""
|
||||
"State" "2" ""
|
||||
"name" "3" """contextMenuOpen"""
|
||||
"when" "3" "!mainView.activeFocus"
|
||||
"PropertyChanges" "3" ""
|
||||
"target" "4" "contextMenu"
|
||||
"x" "4" "0"
|
||||
"open" "4" "true"
|
||||
"PropertyChanges" "3" ""
|
||||
"target" "4" "mainView"
|
||||
"x" "4" "130"
|
||||
"PropertyChanges" "3" ""
|
||||
"target" "4" "shade"
|
||||
"opacity" "4" "0.25"
|
||||
"transitions" "1" ""
|
||||
"Transition" "2" ""
|
||||
"NumberAnimation" "3" ""
|
||||
"properties" "4" """x,opacity"""
|
||||
"duration" "4" "600"
|
||||
"easing.type" "4" "Easing.OutQuint"
|
||||
|
+84
@@ -0,0 +1,84 @@
|
||||
"element" "nestinglevel" "value"
|
||||
"Rectangle" "0" ""
|
||||
"id" "1" "window"
|
||||
"txtCnt" "1" """Property"""
|
||||
"clicked" "1" ""
|
||||
"clicked" "1" ""
|
||||
"width" "1" "800"
|
||||
"height" "1" "480"
|
||||
"color" "1" """white"""
|
||||
"Text" "1" ""
|
||||
"id" "2" "addedText"
|
||||
"text" "2" """Squish QML outline test"""
|
||||
"color" "2" """darkcyan"""
|
||||
"font.bold" "2" "true"
|
||||
"anchors.centerIn" "2" "parent"
|
||||
"FocusScope" "1" ""
|
||||
"id" "2" "mainView"
|
||||
"width" "2" "parent.width"
|
||||
"height" "2" "parent.height"
|
||||
"focus" "2" "true"
|
||||
"GridMenu" "2" ""
|
||||
"id" "3" "gridMenu"
|
||||
"width" "3" "parent.width"
|
||||
"height" "3" "320"
|
||||
"focus" "3" "true"
|
||||
"interactive" "3" "parent.activeFocus"
|
||||
"ListMenu" "2" ""
|
||||
"id" "3" "listMenu"
|
||||
"y" "3" "320"
|
||||
"width" "3" "parent.width"
|
||||
"height" "3" "320"
|
||||
"Rectangle" "2" ""
|
||||
"id" "3" "shade"
|
||||
"anchors.fill" "3" "parent"
|
||||
"color" "3" """#cc00bb"""
|
||||
"opacity" "3" "0"
|
||||
"states" "2" ""
|
||||
"State" "3" ""
|
||||
"name" "4" """showListViews"""
|
||||
"PropertyChanges" "4" ""
|
||||
"target" "5" "gridMenu"
|
||||
"y" "5" "-160"
|
||||
"PropertyChanges" "4" ""
|
||||
"target" "5" "listMenu"
|
||||
"y" "5" "160"
|
||||
"transitions" "2" ""
|
||||
"Transition" "3" ""
|
||||
"NumberAnimation" "4" ""
|
||||
"properties" "5" """y"""
|
||||
"duration" "5" "600"
|
||||
"easing.type" "5" "Easing.OutQuint"
|
||||
"Image" "1" ""
|
||||
"source" "2" """Core/images/arrow.png"""
|
||||
"rotation" "2" "180"
|
||||
"anchors.verticalCenter" "2" "parent.verticalCenter"
|
||||
"MouseArea" "2" ""
|
||||
"anchors.fill" "3" "parent"
|
||||
"anchors.margins" "3" "-10"
|
||||
"onClicked" "3" ""
|
||||
"ContextMenu" "1" ""
|
||||
"id" "2" "contextMenu"
|
||||
"x" "2" "-265"
|
||||
"width" "2" "260"
|
||||
"height" "2" "parent.height"
|
||||
"states" "1" ""
|
||||
"State" "2" ""
|
||||
"name" "3" """contextMenuOpen"""
|
||||
"when" "3" "!mainView.activeFocus"
|
||||
"PropertyChanges" "3" ""
|
||||
"target" "4" "contextMenu"
|
||||
"x" "4" "0"
|
||||
"open" "4" "true"
|
||||
"PropertyChanges" "3" ""
|
||||
"target" "4" "mainView"
|
||||
"x" "4" "130"
|
||||
"PropertyChanges" "3" ""
|
||||
"target" "4" "shade"
|
||||
"opacity" "4" "0.25"
|
||||
"transitions" "1" ""
|
||||
"Transition" "2" ""
|
||||
"NumberAnimation" "3" ""
|
||||
"properties" "4" """x,opacity"""
|
||||
"duration" "4" "600"
|
||||
"easing.type" "4" "Easing.OutQuint"
|
||||
|
@@ -0,0 +1,75 @@
|
||||
"element" "nestinglevel" "value"
|
||||
"Rectangle" "0" ""
|
||||
"id" "1" "window"
|
||||
"width" "1" "800"
|
||||
"height" "1" "480"
|
||||
"color" "1" """#3E606F"""
|
||||
"FocusScope" "1" ""
|
||||
"id" "2" "mainView"
|
||||
"width" "2" "parent.width"
|
||||
"height" "2" "parent.height"
|
||||
"focus" "2" "true"
|
||||
"GridMenu" "2" ""
|
||||
"id" "3" "gridMenu"
|
||||
"width" "3" "parent.width"
|
||||
"height" "3" "320"
|
||||
"focus" "3" "true"
|
||||
"interactive" "3" "parent.activeFocus"
|
||||
"ListMenu" "2" ""
|
||||
"id" "3" "listMenu"
|
||||
"y" "3" "320"
|
||||
"width" "3" "parent.width"
|
||||
"height" "3" "320"
|
||||
"Rectangle" "2" ""
|
||||
"id" "3" "shade"
|
||||
"anchors.fill" "3" "parent"
|
||||
"color" "3" """black"""
|
||||
"opacity" "3" "0"
|
||||
"states" "2" ""
|
||||
"State" "3" ""
|
||||
"name" "4" """showListViews"""
|
||||
"PropertyChanges" "4" ""
|
||||
"target" "5" "gridMenu"
|
||||
"y" "5" "-160"
|
||||
"PropertyChanges" "4" ""
|
||||
"target" "5" "listMenu"
|
||||
"y" "5" "160"
|
||||
"transitions" "2" ""
|
||||
"Transition" "3" ""
|
||||
"NumberAnimation" "4" ""
|
||||
"properties" "5" """y"""
|
||||
"duration" "5" "600"
|
||||
"easing.type" "5" "Easing.OutQuint"
|
||||
"Image" "1" ""
|
||||
"source" "2" """Core/images/arrow.png"""
|
||||
"rotation" "2" "90"
|
||||
"anchors.verticalCenter" "2" "parent.verticalCenter"
|
||||
"MouseArea" "2" ""
|
||||
"anchors.fill" "3" "parent"
|
||||
"anchors.margins" "3" "-10"
|
||||
"onClicked" "3" "contextMenu.focus = true"
|
||||
"ContextMenu" "1" ""
|
||||
"id" "2" "contextMenu"
|
||||
"x" "2" "-265"
|
||||
"width" "2" "260"
|
||||
"height" "2" "parent.height"
|
||||
"states" "1" ""
|
||||
"State" "2" ""
|
||||
"name" "3" """contextMenuOpen"""
|
||||
"when" "3" "!mainView.activeFocus"
|
||||
"PropertyChanges" "3" ""
|
||||
"target" "4" "contextMenu"
|
||||
"x" "4" "0"
|
||||
"open" "4" "true"
|
||||
"PropertyChanges" "3" ""
|
||||
"target" "4" "mainView"
|
||||
"x" "4" "130"
|
||||
"PropertyChanges" "3" ""
|
||||
"target" "4" "shade"
|
||||
"opacity" "4" "0.25"
|
||||
"transitions" "1" ""
|
||||
"Transition" "2" ""
|
||||
"NumberAnimation" "3" ""
|
||||
"properties" "4" """x,opacity"""
|
||||
"duration" "4" "600"
|
||||
"easing.type" "4" "Easing.OutQuint"
|
||||
|
@@ -4,7 +4,8 @@ def main():
|
||||
startApplication("qtcreator" + SettingsPath)
|
||||
# using a temporary directory won't mess up a potentially existing
|
||||
workingDir = tempDir()
|
||||
projectName = createNewQtQuickApplication(workingDir, targets = QtQuickConstants.Targets.DESKTOP_474_GCC)
|
||||
checkedTargets, projectName = createNewQtQuickApplication(workingDir,
|
||||
targets = QtQuickConstants.Targets.DESKTOP_474_GCC)
|
||||
# wait for parsing to complete
|
||||
waitForSignal("{type='CppTools::Internal::CppModelManager' unnamed='1'}", "sourceFilesRefreshed(QStringList)")
|
||||
test.log("Building project")
|
||||
|
||||
@@ -8,7 +8,9 @@ def main():
|
||||
startApplication("qtcreator" + SettingsPath)
|
||||
# using a temporary directory won't mess up a potentially existing
|
||||
workingDir = tempDir()
|
||||
projectName = createNewQtQuickApplication(workingDir, None, os.path.join(prepareTemplate(sourceExample), qmlFile))
|
||||
checkedTargets, projectName = createNewQtQuickApplication(workingDir, None,
|
||||
os.path.join(prepareTemplate(sourceExample), qmlFile),
|
||||
QtQuickConstants.Targets.DESKTOP_474_GCC)
|
||||
# wait for parsing to complete
|
||||
waitForSignal("{type='CppTools::Internal::CppModelManager' unnamed='1'}", "sourceFilesRefreshed(QStringList)")
|
||||
test.log("Building project")
|
||||
|
||||
Reference in New Issue
Block a user