forked from qt-creator/qt-creator
Merge branch '2.4' of ssh://codereview.qt-project.org/qt-creator/qt-creator into 2.4
This commit is contained in:
@@ -147,6 +147,11 @@ def lookupType(typestring):
|
|||||||
type = gdb.lookup_type(ts)
|
type = gdb.lookup_type(ts)
|
||||||
except RuntimeError, error:
|
except RuntimeError, error:
|
||||||
#warn("LOOKING UP '%s': %s" % (ts, error))
|
#warn("LOOKING UP '%s': %s" % (ts, error))
|
||||||
|
if type is None:
|
||||||
|
pos = typestring.find("<unnamed>")
|
||||||
|
if pos != -1:
|
||||||
|
# See http://sourceware.org/bugzilla/show_bug.cgi?id=13269
|
||||||
|
return lookupType(typestring.replace("<unnamed>", "(anonymous namespace)"))
|
||||||
# See http://sourceware.org/bugzilla/show_bug.cgi?id=11912
|
# See http://sourceware.org/bugzilla/show_bug.cgi?id=11912
|
||||||
exp = "(class '%s'*)0" % ts
|
exp = "(class '%s'*)0" % ts
|
||||||
try:
|
try:
|
||||||
|
|||||||
@@ -288,7 +288,9 @@ bool CMakeProject::parseCMakeLists()
|
|||||||
allIncludePaths.append(cbpparser.includeFiles());
|
allIncludePaths.append(cbpparser.includeFiles());
|
||||||
|
|
||||||
QStringList allFrameworkPaths;
|
QStringList allFrameworkPaths;
|
||||||
QList<ProjectExplorer::HeaderPath> allHeaderPaths = activeBC->toolChain()->systemHeaderPaths();
|
QList<ProjectExplorer::HeaderPath> allHeaderPaths;
|
||||||
|
if (activeBC->toolChain())
|
||||||
|
allHeaderPaths = activeBC->toolChain()->systemHeaderPaths();
|
||||||
foreach (const ProjectExplorer::HeaderPath &headerPath, allHeaderPaths) {
|
foreach (const ProjectExplorer::HeaderPath &headerPath, allHeaderPaths) {
|
||||||
if (headerPath.kind() == ProjectExplorer::HeaderPath::FrameworkHeaderPath)
|
if (headerPath.kind() == ProjectExplorer::HeaderPath::FrameworkHeaderPath)
|
||||||
allFrameworkPaths.append(headerPath.path());
|
allFrameworkPaths.append(headerPath.path());
|
||||||
@@ -302,12 +304,12 @@ bool CMakeProject::parseCMakeLists()
|
|||||||
CPlusPlus::CppModelManagerInterface::ProjectInfo pinfo = modelmanager->projectInfo(this);
|
CPlusPlus::CppModelManagerInterface::ProjectInfo pinfo = modelmanager->projectInfo(this);
|
||||||
if (pinfo.includePaths != allIncludePaths
|
if (pinfo.includePaths != allIncludePaths
|
||||||
|| pinfo.sourceFiles != m_files
|
|| pinfo.sourceFiles != m_files
|
||||||
|| pinfo.defines != activeBC->toolChain()->predefinedMacros()
|
|| pinfo.defines != (activeBC->toolChain() ? activeBC->toolChain()->predefinedMacros() : QByteArray())
|
||||||
|| pinfo.frameworkPaths != allFrameworkPaths) {
|
|| pinfo.frameworkPaths != allFrameworkPaths) {
|
||||||
pinfo.includePaths = allIncludePaths;
|
pinfo.includePaths = allIncludePaths;
|
||||||
// TODO we only want C++ files, not all other stuff that might be in the project
|
// TODO we only want C++ files, not all other stuff that might be in the project
|
||||||
pinfo.sourceFiles = m_files;
|
pinfo.sourceFiles = m_files;
|
||||||
pinfo.defines = activeBC->toolChain()->predefinedMacros(); // TODO this is to simplistic
|
pinfo.defines = (activeBC->toolChain() ? activeBC->toolChain()->predefinedMacros() : QByteArray()); // TODO this is to simplistic
|
||||||
pinfo.frameworkPaths = allFrameworkPaths;
|
pinfo.frameworkPaths = allFrameworkPaths;
|
||||||
modelmanager->updateProjectInfo(pinfo);
|
modelmanager->updateProjectInfo(pinfo);
|
||||||
m_codeModelFuture.cancel();
|
m_codeModelFuture.cancel();
|
||||||
|
|||||||
@@ -142,7 +142,10 @@ bool MakeStep::init()
|
|||||||
pp->setMacroExpander(bc->macroExpander());
|
pp->setMacroExpander(bc->macroExpander());
|
||||||
pp->setEnvironment(bc->environment());
|
pp->setEnvironment(bc->environment());
|
||||||
pp->setWorkingDirectory(bc->buildDirectory());
|
pp->setWorkingDirectory(bc->buildDirectory());
|
||||||
pp->setCommand(bc->toolChain()->makeCommand());
|
if (bc->toolChain())
|
||||||
|
pp->setCommand(bc->toolChain()->makeCommand());
|
||||||
|
else
|
||||||
|
pp->setCommand(QLatin1String("make"));
|
||||||
pp->setArguments(arguments);
|
pp->setArguments(arguments);
|
||||||
|
|
||||||
setOutputParser(new ProjectExplorer::GnuMakeParser());
|
setOutputParser(new ProjectExplorer::GnuMakeParser());
|
||||||
|
|||||||
@@ -659,10 +659,13 @@ static void buildContextProperties(
|
|||||||
typeScope = scope; // incorrect but may be an ok fallback
|
typeScope = scope; // incorrect but may be an ok fallback
|
||||||
ClassOrNamespace *binding = typeOf.context().lookupType(namedType->name(), typeScope);
|
ClassOrNamespace *binding = typeOf.context().lookupType(namedType->name(), typeScope);
|
||||||
if (binding && !binding->symbols().isEmpty()) {
|
if (binding && !binding->symbols().isEmpty()) {
|
||||||
Class *klass = binding->symbols().first()->asClass();
|
// find the best 'Class' symbol
|
||||||
if (klass) {
|
for (int i = binding->symbols().size() - 1; i >= 0; --i) {
|
||||||
FakeMetaObject::Ptr fmo = buildFakeMetaObject(klass, fakeMetaObjects, typeOf);
|
if (Class *klass = binding->symbols().at(i)->asClass()) {
|
||||||
typeName = fmo->className();
|
FakeMetaObject::Ptr fmo = buildFakeMetaObject(klass, fakeMetaObjects, typeOf);
|
||||||
|
typeName = fmo->className();
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -38,6 +38,7 @@
|
|||||||
:Qt Gui Application_Qt4ProjectManager::Internal::GuiAppWizardDialog {type='Qt4ProjectManager::Internal::GuiAppWizardDialog' unnamed='1' visible='1' windowTitle='Qt Gui Application'}
|
:Qt Gui Application_Qt4ProjectManager::Internal::GuiAppWizardDialog {type='Qt4ProjectManager::Internal::GuiAppWizardDialog' unnamed='1' visible='1' windowTitle='Qt Gui Application'}
|
||||||
:QtCreator.MenuBar_ProjectExplorer::Internal::MiniProjectTargetSelector {type='ProjectExplorer::Internal::MiniProjectTargetSelector'}
|
:QtCreator.MenuBar_ProjectExplorer::Internal::MiniProjectTargetSelector {type='ProjectExplorer::Internal::MiniProjectTargetSelector'}
|
||||||
:QtCreator.MenuBar_ProjectExplorer::Internal::ProjectListWidget {type='ProjectExplorer::Internal::ProjectListWidget' window=':QtCreator.MenuBar_ProjectExplorer::Internal::MiniProjectTargetSelector'}
|
:QtCreator.MenuBar_ProjectExplorer::Internal::ProjectListWidget {type='ProjectExplorer::Internal::ProjectListWidget' window=':QtCreator.MenuBar_ProjectExplorer::Internal::MiniProjectTargetSelector'}
|
||||||
|
:addToVersionControlComboBox_QComboBox {name='addToVersionControlComboBox' type='QComboBox' visible='1'}
|
||||||
:formFileLineEdit_Utils::FileNameValidatingLineEdit {buddy=':Qt Gui Application.Form file:_QLabel' name='formFileLineEdit' type='Utils::FileNameValidatingLineEdit' visible='1'}
|
:formFileLineEdit_Utils::FileNameValidatingLineEdit {buddy=':Qt Gui Application.Form file:_QLabel' name='formFileLineEdit' type='Utils::FileNameValidatingLineEdit' visible='1'}
|
||||||
:frame.nameLineEdit_Utils::ProjectNameValidatingLineEdit {container=':Qt Gui Application.frame_QFrame' name='nameLineEdit' type='Utils::ProjectNameValidatingLineEdit' visible='1'}
|
:frame.nameLineEdit_Utils::ProjectNameValidatingLineEdit {container=':Qt Gui Application.frame_QFrame' name='nameLineEdit' type='Utils::ProjectNameValidatingLineEdit' visible='1'}
|
||||||
:frame_Utils::BaseValidatingLineEdit {container=':Qt Gui Application.frame_QFrame' type='Utils::BaseValidatingLineEdit' unnamed='1' visible='1'}
|
:frame_Utils::BaseValidatingLineEdit {container=':Qt Gui Application.frame_QFrame' type='Utils::BaseValidatingLineEdit' unnamed='1' visible='1'}
|
||||||
|
|||||||
@@ -112,6 +112,7 @@ def createProject_Qt_GUI(path, projectName, qtVersion, checks):
|
|||||||
test.verify(ui_found > cpp_found, "'" + ui_file + "' found at index " + str(ui_found))
|
test.verify(ui_found > cpp_found, "'" + ui_file + "' found at index " + str(ui_found))
|
||||||
test.verify(pro_found > ui_found, "'" + pro_file + "' found at index " + str(pro_found))
|
test.verify(pro_found > ui_found, "'" + pro_file + "' found at index " + str(pro_found))
|
||||||
|
|
||||||
|
selectFromCombo(":addToVersionControlComboBox_QComboBox", "<None>")
|
||||||
clickButton(waitForObject(":Qt Gui Application.Finish_QPushButton"))
|
clickButton(waitForObject(":Qt Gui Application.Finish_QPushButton"))
|
||||||
|
|
||||||
if checks:
|
if checks:
|
||||||
@@ -159,4 +160,5 @@ def createNewQtQuickApplication(workingDir, projectName = None, templateFile = N
|
|||||||
chooseDestination(destination)
|
chooseDestination(destination)
|
||||||
snooze(1)
|
snooze(1)
|
||||||
clickButton(nextButton)
|
clickButton(nextButton)
|
||||||
|
selectFromCombo(":addToVersionControlComboBox_QComboBox", "<None>")
|
||||||
clickButton(waitForObject("{type='QPushButton' text~='(Finish|Done)' visible='1'}", 20000))
|
clickButton(waitForObject("{type='QPushButton' text~='(Finish|Done)' visible='1'}", 20000))
|
||||||
|
|||||||
@@ -30,6 +30,7 @@ def createNewQtQuickUI():
|
|||||||
clickButton(cbDefaultLocation)
|
clickButton(cbDefaultLocation)
|
||||||
# now there's the 'untitled' project inside a temporary directory - step forward...!
|
# now there's the 'untitled' project inside a temporary directory - step forward...!
|
||||||
clickButton(waitForObject("{text~='(Next.*|Continue)' type='QPushButton' visible='1'}", 20000))
|
clickButton(waitForObject("{text~='(Next.*|Continue)' type='QPushButton' visible='1'}", 20000))
|
||||||
|
selectFromCombo(":addToVersionControlComboBox_QComboBox", "<None>")
|
||||||
clickButton(waitForObject("{type='QPushButton' text~='(Finish|Done)' visible='1'}", 20000))
|
clickButton(waitForObject("{type='QPushButton' text~='(Finish|Done)' visible='1'}", 20000))
|
||||||
|
|
||||||
def cleanup():
|
def cleanup():
|
||||||
|
|||||||
@@ -45,6 +45,7 @@ def createNewQmlExtension():
|
|||||||
"type='QLineEdit' unnamed='1' visible='1'}", 20000)
|
"type='QLineEdit' unnamed='1' visible='1'}", 20000)
|
||||||
replaceEditorContent(uriLineEd, "com.nokia.test.qmlcomponents")
|
replaceEditorContent(uriLineEd, "com.nokia.test.qmlcomponents")
|
||||||
clickButton(nextButton)
|
clickButton(nextButton)
|
||||||
|
selectFromCombo(":addToVersionControlComboBox_QComboBox", "<None>")
|
||||||
clickButton(waitForObject("{type='QPushButton' text~='(Finish|Done)' visible='1'}", 20000))
|
clickButton(waitForObject("{type='QPushButton' text~='(Finish|Done)' visible='1'}", 20000))
|
||||||
|
|
||||||
def cleanup():
|
def cleanup():
|
||||||
|
|||||||
Reference in New Issue
Block a user