Merge remote-tracking branch 'origin/4.1' into 4.2

Change-Id: Ibe4cd5522e1d87d56d2aae7a429282b41bf18647
This commit is contained in:
Eike Ziller
2016-10-12 16:02:23 +02:00
10 changed files with 2741 additions and 1608 deletions

72
dist/changes-4.1.1.md vendored Normal file
View File

@@ -0,0 +1,72 @@
Qt Creator version 4.1.1 contains bug fixes.
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://code.qt.io/qt-creator/qt-creator.git
git log --cherry-pick --pretty=oneline v4.1.0..v4.1.1
General
* Fixed issues with output pane height
(QTCREATORBUG-15986, QTCREATORBUG-16829)
Editing
* Fixed performance of cleaning whitespace (QTCREATORBUG-16420)
* Fixed selection color in help viewer for dark theme (QTCREATORBUG-16375)
Help
* Fixed that no results could be shown in Locator (QTCREATORBUG-16753)
QMake Projects
* Fixed issue with make steps in deploy configurations (QTCREATORBUG-16795)
Qbs Projects
* Fixed handling of generated files (QTCREATORBUG-16976)
QML Support
* Fixed handling of circular dependencies (QTCREATORBUG-16585)
Debugging
* Fixed scrolling in memory editor (QTCREATORBUG-16751)
* Fixed expansion of items in tool tip (QTCREATORBUG-16947)
* GDB
* Fixed handling of built-in pretty printers from new versions of GDB
(QTCREATORBUG-16758)
* Fixed that remote working directory was used for local process
(QTCREATORBUG-16211)
* CDB
* Fixed display order of vectors in vectors (QTCREATORBUG-16813)
* Fixed display of QList contents (QTCREATORBUG-16750)
QML Profiler
* Separated compile events from other QML/JS events in statistics and
flamegraph, since compilation can happen asynchronously
Beatifier
* Fixed that beautifier was not enabled for Objective-C/C++ files
(QTCREATORBUG-16806)
Platform Specific
macOS
* Fixed issue with detecting LLDB through `xcrun`
Android
* Added API level 24 for Android 7
* Fixed debugging on Android 6+ with NDK r11+ (QTCREATORBUG-16721)
iOS
* Fixed QML debugging on device (QTCREATORBUG-15812)

File diff suppressed because it is too large Load Diff

View File

@@ -269,7 +269,8 @@ QStringList Environment::appendExeExtensions(const QString &executable) const
} }
FileName Environment::searchInPath(const QString &executable, FileName Environment::searchInPath(const QString &executable,
const QStringList &additionalDirs) const const QStringList &additionalDirs,
bool (*func)(const QString &name)) const
{ {
if (executable.isEmpty()) if (executable.isEmpty())
return FileName(); return FileName();
@@ -292,7 +293,7 @@ FileName Environment::searchInPath(const QString &executable,
continue; continue;
alreadyChecked.insert(dir); alreadyChecked.insert(dir);
FileName tmp = searchInDirectory(execs, dir); FileName tmp = searchInDirectory(execs, dir);
if (!tmp.isEmpty()) if (!tmp.isEmpty() && (!func || func(tmp.toString())))
return tmp; return tmp;
} }
@@ -304,7 +305,7 @@ FileName Environment::searchInPath(const QString &executable,
continue; continue;
alreadyChecked.insert(p); alreadyChecked.insert(p);
FileName tmp = searchInDirectory(execs, QDir::fromNativeSeparators(p)); FileName tmp = searchInDirectory(execs, QDir::fromNativeSeparators(p));
if (!tmp.isEmpty()) if (!tmp.isEmpty() && (!func || func(tmp.toString())))
return tmp; return tmp;
} }
return FileName(); return FileName();

View File

@@ -100,7 +100,9 @@ public:
Environment::const_iterator constFind(const QString &name) const; Environment::const_iterator constFind(const QString &name) const;
FileName searchInPath(const QString &executable, FileName searchInPath(const QString &executable,
const QStringList &additionalDirs = QStringList()) const; const QStringList &additionalDirs = QStringList(),
bool (*func)(const QString &name) = nullptr) const;
QStringList path() const; QStringList path() const;
QStringList appendExeExtensions(const QString &executable) const; QStringList appendExeExtensions(const QString &executable) const;

View File

@@ -237,7 +237,7 @@ QList<TestConfiguration *> QuickTestTreeItem::getSelectedTestConfigurations() co
int grandChildCount = child->childCount(); int grandChildCount = child->childCount();
for (int grandChildRow = 0; grandChildRow < grandChildCount; ++grandChildRow) { for (int grandChildRow = 0; grandChildRow < grandChildCount; ++grandChildRow) {
const TestTreeItem *grandChild = child->childItem(grandChildRow); const TestTreeItem *grandChild = child->childItem(grandChildRow);
if (grandChild->type() != TestFunctionOrSet) if (grandChild->checked() != Qt::Checked || grandChild->type() != TestFunctionOrSet)
continue; continue;
testFunctions << child->name() + "::" + grandChild->name(); testFunctions << child->name() + "::" + grandChild->name();
} }

View File

@@ -2374,6 +2374,7 @@ void QmlEnginePrivate::insertSubItems(WatchItem *parent, const QVariantList &pro
QTC_ASSERT(parent, return); QTC_ASSERT(parent, return);
LookupItems itemsToLookup; LookupItems itemsToLookup;
const QSet<QString> expandedINames = engine->watchHandler()->expandedINames();
foreach (const QVariant &property, properties) { foreach (const QVariant &property, properties) {
QmlV8ObjectData propertyData = extractData(property); QmlV8ObjectData propertyData = extractData(property);
auto item = new WatchItem; auto item = new WatchItem;
@@ -2395,7 +2396,7 @@ void QmlEnginePrivate::insertSubItems(WatchItem *parent, const QVariantList &pro
item->id = propertyData.handle; item->id = propertyData.handle;
item->type = propertyData.type; item->type = propertyData.type;
item->value = propertyData.value.toString(); item->value = propertyData.value.toString();
if (item->type.isEmpty()) if (item->type.isEmpty() || expandedINames.contains(item->iname))
itemsToLookup.insert(propertyData.handle, {item->iname, item->name, item->exp}); itemsToLookup.insert(propertyData.handle, {item->iname, item->name, item->exp});
item->setHasChildren(propertyData.properties.count() > 0); item->setHasChildren(propertyData.properties.count() > 0);
parent->appendChild(item); parent->appendChild(item);

View File

@@ -208,7 +208,16 @@ Utils::FileName AbstractMsvcToolChain::compilerCommand() const
{ {
Utils::Environment env = Utils::Environment::systemEnvironment(); Utils::Environment env = Utils::Environment::systemEnvironment();
addToEnvironment(env); addToEnvironment(env);
return env.searchInPath(QLatin1String("cl.exe"));
Utils::FileName clexe = env.searchInPath(QLatin1String("cl.exe"), QStringList(), [](const QString &name) {
QDir dir(QDir::cleanPath(QFileInfo(name).absolutePath() + QStringLiteral("/..")));
do {
if (QFile::exists(dir.absoluteFilePath(QStringLiteral("vcvarsall.bat"))))
return true;
} while (dir.cdUp() && !dir.isRoot());
return false;
});
return clexe;
} }
IOutputParser *AbstractMsvcToolChain::outputParser() const IOutputParser *AbstractMsvcToolChain::outputParser() const

View File

@@ -1477,7 +1477,9 @@ void QmakeProject::collectLibraryData(const QmakeProFileNode *node, DeploymentDa
destDir.append(QLatin1Char('/')).append(ti.target) destDir.append(QLatin1Char('/')).append(ti.target)
.append(QLatin1String(".framework")); .append(QLatin1String(".framework"));
} else { } else {
targetFileName.prepend(QLatin1String("lib")); if (!(isPlugin && config.contains(QLatin1String("no_plugin_name_prefix"))))
targetFileName.prepend(QLatin1String("lib"));
if (!isPlugin) { if (!isPlugin) {
targetFileName += QLatin1Char('.'); targetFileName += QLatin1Char('.');
const QString version = node->singleVariableValue(VersionVar); const QString version = node->singleVariableValue(VersionVar);
@@ -1496,7 +1498,9 @@ void QmakeProject::collectLibraryData(const QmakeProFileNode *node, DeploymentDa
case Abi::LinuxOS: case Abi::LinuxOS:
case Abi::BsdOS: case Abi::BsdOS:
case Abi::UnixOS: case Abi::UnixOS:
targetFileName.prepend(QLatin1String("lib")); if (!(isPlugin && config.contains(QLatin1String("no_plugin_name_prefix"))))
targetFileName.prepend(QLatin1String("lib"));
targetFileName += QLatin1Char('.'); targetFileName += QLatin1Char('.');
if (isStatic) { if (isStatic) {
targetFileName += QLatin1Char('a'); targetFileName += QLatin1Char('a');

View File

@@ -647,6 +647,8 @@ def openVcsLog():
"window=':Qt Creator_Core::Internal::MainWindow'}", 2000) "window=':Qt Creator_Core::Internal::MainWindow'}", 2000)
if className(foundObj) != 'Core::OutputWindow': if className(foundObj) != 'Core::OutputWindow':
raise Exception("Found derived class, but not a pure QPlainTextEdit.") raise Exception("Found derived class, but not a pure QPlainTextEdit.")
waitForObject("{text='Version Control' type='QLabel' unnamed='1' visible='1' "
"window=':Qt Creator_Core::Internal::MainWindow'}", 2000)
except: except:
invokeMenuItem("Window", "Output Panes", "Version Control") invokeMenuItem("Window", "Output Panes", "Version Control")

View File

@@ -25,8 +25,8 @@
source("../../shared/qtcreator.py") source("../../shared/qtcreator.py")
cloneUrl = "https://codereview.qt-project.org/p/qt-labs/jom" cloneUrl = "https://code.qt.io/installer-framework/installer-framework.git"
cloneDir = "myCloneOfJom" cloneDir = "myCloneOfIfw"
def verifyCloneLog(targetDir, canceled): def verifyCloneLog(targetDir, canceled):
if canceled: if canceled:
@@ -39,8 +39,7 @@ def verifyCloneLog(targetDir, canceled):
test.warning("Cloning failed outside Creator.") test.warning("Cloning failed outside Creator.")
return False return False
# test for QTCREATORBUG-10112 # test for QTCREATORBUG-10112
test.compare(cloneLog.count("remote: Counting objects:"), 1) test.compare(cloneLog.count("remote: Total"), 1)
test.compare(cloneLog.count("remote: Finding sources:"), 1)
test.compare(cloneLog.count("Receiving objects:"), 1) test.compare(cloneLog.count("Receiving objects:"), 1)
test.compare(cloneLog.count("Resolving deltas:"), 1) test.compare(cloneLog.count("Resolving deltas:"), 1)
test.verify(not "Stopping..." in cloneLog, test.verify(not "Stopping..." in cloneLog,
@@ -75,9 +74,9 @@ def verifyVersionControlView(targetDir, canceled):
clickButton(waitForObject(":*Qt Creator.Clear_QToolButton")) clickButton(waitForObject(":*Qt Creator.Clear_QToolButton"))
def verifyFiles(targetDir): def verifyFiles(targetDir):
for file in [".gitignore", "CMakeLists.txt", "jom.pro", for file in [".gitignore", "LGPL_EXCEPTION.txt", "installerfw.pro",
os.path.join("bin", "ibjom.bat"), os.path.join("tests", "test-installer", "create-test-installer.bat"),
os.path.join("src", "app", "main.cpp")]: os.path.join("src", "sdk", "main.cpp")]:
test.verify(os.path.exists(os.path.join(targetDir, cloneDir, file)), test.verify(os.path.exists(os.path.join(targetDir, cloneDir, file)),
"Verify the existence of %s" % file) "Verify the existence of %s" % file)
@@ -95,7 +94,7 @@ def main():
replaceEditorContent(waitForObject(":Working Copy_Utils::BaseValidatingLineEdit"), replaceEditorContent(waitForObject(":Working Copy_Utils::BaseValidatingLineEdit"),
targetDir) targetDir)
cloneDirEdit = waitForObject("{name='Dir' type='QLineEdit' visible='1'}") cloneDirEdit = waitForObject("{name='Dir' type='QLineEdit' visible='1'}")
test.compare(cloneDirEdit.text, "jom") test.compare(cloneDirEdit.text, "installer-framework")
replaceEditorContent(cloneDirEdit, cloneDir) replaceEditorContent(cloneDirEdit, cloneDir)
clickButton(waitForObject(":Next_QPushButton")) clickButton(waitForObject(":Next_QPushButton"))
cloneLog = waitForObject(":Git Repository Clone.logPlainTextEdit_QPlainTextEdit", 1000) cloneLog = waitForObject(":Git Repository Clone.logPlainTextEdit_QPlainTextEdit", 1000)
@@ -129,7 +128,7 @@ def main():
except: except:
clickButton(waitForObject(":Cannot Open Project.Show Details..._QPushButton")) clickButton(waitForObject(":Cannot Open Project.Show Details..._QPushButton"))
test.fail("The checked out project was not being opened.", test.fail("The checked out project was not being opened.",
waitForObject(":Cannot Open Project_QTextEdit").plainText) str(waitForObject(":Cannot Open Project_QTextEdit").plainText))
clickButton(waitForObject(":Cannot Open Project.OK_QPushButton")) clickButton(waitForObject(":Cannot Open Project.OK_QPushButton"))
verifyVersionControlView(targetDir, button == "Cancel immediately") verifyVersionControlView(targetDir, button == "Cancel immediately")
invokeMenuItem("File", "Exit") invokeMenuItem("File", "Exit")