Merge remote-tracking branch 'origin/4.0'

Conflicts:
	qtcreator.pri
	qtcreator.qbs

Change-Id: I6217662f0c51d04a83f7a85dc5d7c7f25e78e09a
This commit is contained in:
Eike Ziller
2016-05-13 16:24:37 +02:00
8 changed files with 58 additions and 20 deletions

View File

@@ -96,6 +96,7 @@ Debugging
* LLDB * LLDB
* Fixed issues with Xcode 7.3 * Fixed issues with Xcode 7.3
(QTCREATORBUG-15965, QTCREATORBUG-15945, QTCREATORBUG-15949) (QTCREATORBUG-15965, QTCREATORBUG-15945, QTCREATORBUG-15949)
* Fixed breakpoint commands (QTCREATORBUG-15585)
QML Profiler QML Profiler
@@ -182,6 +183,11 @@ Android
* Fixed issues with `Select Android Device` * Fixed issues with `Select Android Device`
(QTCREATORBUG-15338, QTCREATORBUG-15422) (QTCREATORBUG-15338, QTCREATORBUG-15422)
iOS
* Fixed building for device with Qt 5.7 (QTCREATORBUG-16102)
* Fixed brief freezes while handling build output (QTCREATORBUG-15613)
Credits for these changes go to: Credits for these changes go to:
Alessandro Portale Alessandro Portale
Alexandru Croitor Alexandru Croitor

View File

@@ -125,6 +125,9 @@ def fix_rpaths(path, qt_deploy_path, qt_install_info, chrpath=None):
new_rpath = filter(lambda path: not path.startswith(qt_install_prefix) and not path.startswith(qt_install_libs), new_rpath = filter(lambda path: not path.startswith(qt_install_prefix) and not path.startswith(qt_install_libs),
rpath) rpath)
# check for Qt linking
lddOutput = subprocess.check_output(['ldd', filepath])
if lddOutput.find('libQt5') >= 0 or lddOutput.find('libicu') >= 0:
# add Qt RPATH if necessary # add Qt RPATH if necessary
relative_path = os.path.relpath(qt_deploy_path, os.path.dirname(filepath)) relative_path = os.path.relpath(qt_deploy_path, os.path.dirname(filepath))
if relative_path == '.': if relative_path == '.':

View File

@@ -1455,9 +1455,13 @@ class DumperBase:
self.put('keyencoded="latin1",') self.put('keyencoded="latin1",')
self.putItem(v) self.putItem(v)
propertyCount += 1 propertyCount += 1
self.putItemCount(propertyCount)
self.putValue(str('<%s items>' % propertyCount if propertyCount else '<>0 items>')) else:
# We need a handle to [x] for the user to expand the item
# before we know whether there are actual children. Counting
# them is too expensive.
self.putNumChild(1) self.putNumChild(1)
self.putSpecialValue("minimumitemcount", 0)
with SubItem(self, "[methods]"): with SubItem(self, "[methods]"):
methodCount = self.staticQObjectMethodCount(smo) methodCount = self.staticQObjectMethodCount(smo)

View File

@@ -214,8 +214,8 @@ void BuildDirManager::parse()
void BuildDirManager::clearCache() void BuildDirManager::clearCache()
{ {
auto cmakeCache = Utils::FileName(buildDirectory()).appendPath(QLatin1String("CMakeCache.txt")); auto cmakeCache = Utils::FileName(workDirectory()).appendPath(QLatin1String("CMakeCache.txt"));
auto cmakeFiles = Utils::FileName(buildDirectory()).appendPath(QLatin1String("CMakeFiles")); auto cmakeFiles = Utils::FileName(workDirectory()).appendPath(QLatin1String("CMakeFiles"));
const bool mustCleanUp = cmakeCache.exists() || cmakeFiles.exists(); const bool mustCleanUp = cmakeCache.exists() || cmakeFiles.exists();
if (!mustCleanUp) if (!mustCleanUp)

View File

@@ -931,6 +931,7 @@ QString BaseQtVersion::findQtBinary(Binaries binary) const
case Linguist: case Linguist:
if (HostOsInfo::isMacHost()) if (HostOsInfo::isMacHost())
possibleCommands << QLatin1String("Linguist.app/Contents/MacOS/Linguist"); possibleCommands << QLatin1String("Linguist.app/Contents/MacOS/Linguist");
else
possibleCommands << HostOsInfo::withExecutableSuffix(QLatin1String("linguist")); possibleCommands << HostOsInfo::withExecutableSuffix(QLatin1String("linguist"));
break; break;
case Uic: case Uic:

View File

@@ -29,4 +29,10 @@ QtcTool {
cpp.includePaths: base.concat(["ipcsource", llvmIncludeDir]) cpp.includePaths: base.concat(["ipcsource", llvmIncludeDir])
cpp.libraryPaths: base.concat(llvmLibDir) cpp.libraryPaths: base.concat(llvmLibDir)
cpp.dynamicLibraries: base.concat(llvmLibs) cpp.dynamicLibraries: base.concat(llvmLibs)
cpp.rpaths: base.concat(llvmLibDir)
Properties {
condition: qbs.targetOS.contains("unix") && !qbs.targetOS.contains("osx")
cpp.linkerFlags: base.concat(["-z", "origin"])
}
} }

View File

@@ -176,10 +176,17 @@ def invokeMenuItem(menu, item, *subItems):
waitForObject(":Qt Creator.QtCreator.MenuBar_QMenuBar", 2000) waitForObject(":Qt Creator.QtCreator.MenuBar_QMenuBar", 2000)
except: except:
nativeMouseClick(waitForObject(":Qt Creator_Core::Internal::MainWindow", 1000), 20, 20, 0, Qt.LeftButton) nativeMouseClick(waitForObject(":Qt Creator_Core::Internal::MainWindow", 1000), 20, 20, 0, Qt.LeftButton)
# HACK to avoid squish crash using Qt5.2 on Squish 5.0.1 - remove asap # HACK as Squish fails to provide a proper way to access the system menu
if platform.system() == "Darwin": if platform.system() == "Darwin":
if menu == "Tools" and item == "Options...": if menu == "Tools" and item == "Options...":
nativeType("<Command+,>") #nativeType("<Command+,>")
# the following is a pure HACK because using the default key sequence seems to be broken
# when running from inside Squish
menuBar = waitForObject(":Qt Creator.QtCreator.MenuBar_QMenuBar", 500)
nativeMouseClick(menuBar, 75, 5, 0, Qt.LeftButton)
for _ in range(3):
nativeType("<Down>")
nativeType("<Return>")
return return
if menu == "File" and item == "Exit": if menu == "File" and item == "Exit":
nativeType("<Command+q>") nativeType("<Command+q>")

View File

@@ -53,11 +53,14 @@ def checkQtCreatorHelpVersion(expectedVersion):
switchViewTo(ViewConstants.HELP) switchViewTo(ViewConstants.HELP)
try: try:
helpContentWidget = waitForObject(':Qt Creator_QHelpContentWidget', 5000) helpContentWidget = waitForObject(':Qt Creator_QHelpContentWidget', 5000)
waitFor("helpContentWidget.model().rowCount > 0", 2000)
items = dumpItems(helpContentWidget.model()) items = dumpItems(helpContentWidget.model())
test.compare(filter(lambda x: x.startswith('Qt Creator Manual'), items)[0], test.compare(filter(lambda x: x.startswith('Qt Creator Manual'), items)[0],
'Qt Creator Manual %s' % expectedVersion, 'Qt Creator Manual %s' % expectedVersion,
'Verifying whether manual uses expected version.') 'Verifying whether manual uses expected version.')
except: except:
t, v = sys.exc_info()[:2]
test.log("Exception caught", "%s(%s)" % (str(t), str(v)))
test.fail("Missing Qt Creator Manual.") test.fail("Missing Qt Creator Manual.")
def setKeyboardShortcutForAboutQtC(): def setKeyboardShortcutForAboutQtC():
@@ -74,11 +77,19 @@ def setKeyboardShortcutForAboutQtC():
"container={column='0' text='QtCreator' type='QModelIndex' " "container={column='0' text='QtCreator' type='QModelIndex' "
"container=%s}}" % objectMap.realName(treewidget)) "container=%s}}" % objectMap.realName(treewidget))
mouseClick(modelIndex, 5, 5, 0, Qt.LeftButton) mouseClick(modelIndex, 5, 5, 0, Qt.LeftButton)
shortcut = waitForObject("{container={title='Shortcut' type='QGroupBox' unnamed='1' " shortcutGB = "{title='Shortcut' type='QGroupBox' unnamed='1' visible='1'}"
"visible='1'} type='Utils::FancyLineEdit' unnamed='1' visible='1' " record = waitForObject("{container=%s type='Core::Internal::ShortcutButton' unnamed='1' "
"placeHolderText='Type to set shortcut'}") "visible='1' text~='(Stop Recording|Record)'}" % shortcutGB)
mouseClick(shortcut, 5, 5, 0, Qt.LeftButton) shortcut = ("{container=%s type='Utils::FancyLineEdit' unnamed='1' visible='1' "
"placeHolderText='Enter key sequence as text'}" % shortcutGB)
clickButton(record)
nativeType("<Ctrl+Alt+a>") nativeType("<Ctrl+Alt+a>")
clickButton(record)
expected = 'Ctrl+Alt+A'
if platform.system() == 'Darwin':
expected = 'Ctrl+Opt+A'
test.verify(waitFor("str(findObject(shortcut).text) == expected", 5000),
"Expected key sequence is displayed.")
clickButton(waitForObject(":Options.OK_QPushButton")) clickButton(waitForObject(":Options.OK_QPushButton"))
def main(): def main():