From 3a2651bc8eed5ce5548f1c9628d58a319f641c3e Mon Sep 17 00:00:00 2001 From: dt Date: Tue, 19 Apr 2011 18:51:39 +0200 Subject: [PATCH 01/16] Target setup: Allow deployconfigurations to not do anything Task-Nr: QTCREATORBUG-4579 Reviewed-By: hunger --- src/plugins/projectexplorer/target.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/plugins/projectexplorer/target.cpp b/src/plugins/projectexplorer/target.cpp index 613863e49de..89c1ac6e0ac 100644 --- a/src/plugins/projectexplorer/target.cpp +++ b/src/plugins/projectexplorer/target.cpp @@ -459,8 +459,6 @@ bool Target::fromMap(const QVariantMap &map) if (i == activeConfiguration) setActiveDeployConfiguration(dc); } - if (deployConfigurations().isEmpty() && deployConfigurationFactory()) - return false; int rcCount(map.value(QLatin1String(RC_COUNT_KEY), 0).toInt(&ok)); if (!ok || rcCount < 0) From 3f6e418b6845142bfc8c1533df14ade513770945 Mon Sep 17 00:00:00 2001 From: dt Date: Tue, 19 Apr 2011 18:52:29 +0200 Subject: [PATCH 02/16] Symbian target: Fix availableBuildConfigurations Task-Nr: QTCREATORBUG-4561 Reviewed-By: hunger --- .../qt4projectmanager/qt-s60/qt4symbiantargetfactory.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugins/qt4projectmanager/qt-s60/qt4symbiantargetfactory.cpp b/src/plugins/qt4projectmanager/qt-s60/qt4symbiantargetfactory.cpp index e9797673dba..c59f7e725d2 100644 --- a/src/plugins/qt4projectmanager/qt-s60/qt4symbiantargetfactory.cpp +++ b/src/plugins/qt4projectmanager/qt-s60/qt4symbiantargetfactory.cpp @@ -174,7 +174,7 @@ QList Qt4SymbianTargetFactory::availableBuildConfigurati bool buildAll = version->defaultBuildConfig() & QtVersion::BuildAll; QtVersion::QmakeBuildConfigs config = buildAll ? QtVersion::BuildAll : QtVersion::QmakeBuildConfig(0); - QString dir = QFileInfo(proFilePath).absolutePath(), id; + QString dir = QFileInfo(proFilePath).absolutePath(); if (id == Constants::S60_EMULATOR_TARGET_ID) { infos.append(BuildConfigurationInfo(version, config | QtVersion::DebugBuild, QString(), dir)); } else { From c3e2fd9ed73730b4b55cc69a07c713c50924c506 Mon Sep 17 00:00:00 2001 From: Kai Koehne Date: Tue, 19 Apr 2011 11:07:34 +0200 Subject: [PATCH 03/16] Fix "File name case mismatch" error when debugging QML apps (Win) Work around QTBUG-17529 by normalizing the capitalization of the working directory (which we do already for launching apps without debugging). Task-number: QTCREATORBUG-4592 Reviewed-by: Friedemann Kleint --- src/libs/utils/winutils.cpp | 13 +++++++++++++ src/libs/utils/winutils.h | 3 +++ src/plugins/debugger/debuggerrunner.cpp | 7 +++++++ .../projectexplorer/applicationlauncher_win.cpp | 5 +---- .../qmlprojectrunconfiguration.cpp | 15 ++++----------- 5 files changed, 28 insertions(+), 15 deletions(-) diff --git a/src/libs/utils/winutils.cpp b/src/libs/utils/winutils.cpp index 7ed6909f2f1..f19bdfefbe4 100644 --- a/src/libs/utils/winutils.cpp +++ b/src/libs/utils/winutils.cpp @@ -163,6 +163,19 @@ QTCREATOR_UTILS_EXPORT QString getLongPathName(const QString &name) return rc; } +// makes sure that capitalization of directories is canonical. +// This mimics the logic in QDeclarative_isFileCaseCorrect +QTCREATOR_UTILS_EXPORT QString normalizePathName(const QString &name) +{ + QString canonicalName = getShortPathName(name); + if (canonicalName.isEmpty()) + return name; + canonicalName = getLongPathName(canonicalName); + if (canonicalName.isEmpty()) + return name; + return canonicalName; +} + QTCREATOR_UTILS_EXPORT unsigned long winQPidToPid(const Q_PID qpid) { const PROCESS_INFORMATION *processInfo = reinterpret_cast(qpid); diff --git a/src/libs/utils/winutils.h b/src/libs/utils/winutils.h index 92ca1f15783..caf9f9476a5 100644 --- a/src/libs/utils/winutils.h +++ b/src/libs/utils/winutils.h @@ -59,6 +59,9 @@ QTCREATOR_UTILS_EXPORT QString getShortPathName(const QString &name); // Returns long name QTCREATOR_UTILS_EXPORT QString getLongPathName(const QString &name); +// Returns long name with canonical capitalization. +QTCREATOR_UTILS_EXPORT QString normalizePathName(const QString &name); + QTCREATOR_UTILS_EXPORT unsigned long winQPidToPid(const Q_PID qpid); QTCREATOR_UTILS_EXPORT bool winIs64BitSystem(); diff --git a/src/plugins/debugger/debuggerrunner.cpp b/src/plugins/debugger/debuggerrunner.cpp index 752ef207110..93fd15cb6b6 100644 --- a/src/plugins/debugger/debuggerrunner.cpp +++ b/src/plugins/debugger/debuggerrunner.cpp @@ -46,6 +46,7 @@ #ifdef Q_OS_WIN # include "peutils.h" +# include #endif #include @@ -675,6 +676,12 @@ static DebuggerStartParameters localStartParameters(RunConfiguration *runConfigu sp.startMode = StartInternal; sp.environment = rc->environment(); sp.workingDirectory = rc->workingDirectory(); + +#if defined(Q_OS_WIN) + // Work around QTBUG-17529 (QtDeclarative fails with 'File name case mismatch' ...) + sp.workingDirectory = Utils::normalizePathName(sp.workingDirectory); +#endif + sp.executable = rc->executable(); sp.processArgs = rc->commandLineArguments(); sp.toolChainAbi = rc->abi(); diff --git a/src/plugins/projectexplorer/applicationlauncher_win.cpp b/src/plugins/projectexplorer/applicationlauncher_win.cpp index 5ecf5f5e5ed..8a726c92a5a 100644 --- a/src/plugins/projectexplorer/applicationlauncher_win.cpp +++ b/src/plugins/projectexplorer/applicationlauncher_win.cpp @@ -71,10 +71,7 @@ ApplicationLauncher::~ApplicationLauncher() void ApplicationLauncher::setWorkingDirectory(const QString &dir) { // Work around QTBUG-17529 (QtDeclarative fails with 'File name case mismatch' ...) - QString fixedPath = dir; - const QString longPath = Utils::getLongPathName(dir); - if (!longPath.isEmpty()) - fixedPath = longPath; + const QString fixedPath = Utils::normalizePathName(dir); d->m_winGuiProcess.setWorkingDirectory(fixedPath); d->m_consoleProcess.setWorkingDirectory(fixedPath); diff --git a/src/plugins/qmlprojectmanager/qmlprojectrunconfiguration.cpp b/src/plugins/qmlprojectmanager/qmlprojectrunconfiguration.cpp index 627ce5d331e..d53e8f7cbb4 100644 --- a/src/plugins/qmlprojectmanager/qmlprojectrunconfiguration.cpp +++ b/src/plugins/qmlprojectmanager/qmlprojectrunconfiguration.cpp @@ -45,7 +45,7 @@ #include #include -#ifdef Q_OS_WIN32 +#ifdef Q_OS_WIN #include #endif @@ -180,20 +180,13 @@ void QmlProjectRunConfiguration::setQtVersionId(int id) } /* QtDeclarative checks explicitly that the capitalization for any URL / path - is exactly like the capitalization on disk. This method is uses the same - native Windows API's to get the exact canonical path. */ + is exactly like the capitalization on disk.*/ QString QmlProjectRunConfiguration::canonicalCapsPath(const QString &fileName) { QString canonicalPath = QFileInfo(fileName).canonicalFilePath(); -#if defined(Q_OS_WIN32) - // don't know whether the shortpath step is really needed, - // but we do this in QtDeclarative too. - QString path = Utils::getShortPathName(canonicalPath); - if (!path.isEmpty()) - path = Utils::getLongPathName(canonicalPath); - if (!path.isEmpty()) - canonicalPath = path; +#if defined(Q_OS_WIN) + canonicalPath = Utils::normalizePathName(canonicalPath); #endif return canonicalPath; From 1b14f69628b9008e53e20be559136a933de2d2dd Mon Sep 17 00:00:00 2001 From: Leena Miettinen Date: Wed, 20 Apr 2011 16:20:18 +0200 Subject: [PATCH 04/16] Doc: known issue related to Okteta KDE custom widget plugin Task-number: QTCREATORBUG-4586 Reviewed-by: Friedemann Kleint --- doc/qtcreator.qdoc | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/doc/qtcreator.qdoc b/doc/qtcreator.qdoc index cb5257b01c5..67cd292cd2f 100644 --- a/doc/qtcreator.qdoc +++ b/doc/qtcreator.qdoc @@ -11022,6 +11022,24 @@ switch to the nfs-kernel-server, or create a symlink so that the settings are stored locally. + \o The Okteta KDE custom widget plugin might be installed as part of + some Linux distributions. It can cause Qt Designer to crash. For + more information, see: + + \list + + \o \l{https://bugs.launchpad.net/ubuntu/+source/kdeutils/+bug/662005}{Ubuntu bug 662005} + \o \l{http://bugreports.qt.nokia.com/browse/QTBUG-12025}{QTBUG-12025} + + \endlist + + To resolve the issue, enter the following command to remove the package: + \code + sudo apt-get remove okteta + \endcode + Or delete the following file: + \c /usr/lib/kde4/plugins/designer/oktetadesignerplugin.so. + \endlist \section1 Editing Issues From 0c1c7e1af04c9c8f9bb366d852183b07b13a69c9 Mon Sep 17 00:00:00 2001 From: Christian Kandeler Date: Thu, 21 Apr 2011 09:33:28 +0200 Subject: [PATCH 05/16] Maemo: Disable QML debugging for Harmattan and Meego. It's completely broken for the remote case in both pure QML and mixed mode. --- src/plugins/qt4projectmanager/qt-maemo/qt4maemotarget.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/plugins/qt4projectmanager/qt-maemo/qt4maemotarget.h b/src/plugins/qt4projectmanager/qt-maemo/qt4maemotarget.h index 8224688f056..baa01a1f73a 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/qt4maemotarget.h +++ b/src/plugins/qt4projectmanager/qt-maemo/qt4maemotarget.h @@ -203,7 +203,7 @@ public: virtual bool allowsRemoteMounts() const { return false; } virtual bool allowsPackagingDisabling() const { return false; } - virtual bool allowsQmlDebugging() const { return true; } + virtual bool allowsQmlDebugging() const { return false; } virtual QString projectVersion(QString *error = 0) const; virtual QString packageName() const; @@ -265,7 +265,7 @@ public: virtual bool allowsRemoteMounts() const { return false; } virtual bool allowsPackagingDisabling() const { return false; } - virtual bool allowsQmlDebugging() const { return true; } + virtual bool allowsQmlDebugging() const { return false; } static QString defaultDisplayName(); From 565c42a30e0d9203a5989549c1ccd7e8e464521d Mon Sep 17 00:00:00 2001 From: Kai Koehne Date: Wed, 20 Apr 2011 15:52:44 +0200 Subject: [PATCH 06/16] QmlDebug: Fix debugging for mixed projects on MinGW We've so far missed the 'QDeclarativeDebug: ' messages, because they were arriving on an unexpected channel. Task-number: QTCREATORBUG-4630 Reviewed-by: Friedemann Kleint --- src/plugins/debugger/qml/qmlcppengine.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugins/debugger/qml/qmlcppengine.cpp b/src/plugins/debugger/qml/qmlcppengine.cpp index 56950b7e704..c8ab05ec0de 100644 --- a/src/plugins/debugger/qml/qmlcppengine.cpp +++ b/src/plugins/debugger/qml/qmlcppengine.cpp @@ -665,7 +665,7 @@ void QmlCppEngine::handleRemoteSetupFailed(const QString &message) void QmlCppEngine::showMessage(const QString &msg, int channel, int timeout) const { - if (channel == AppOutput || channel == AppError) { + if (channel == AppOutput || channel == AppError || channel == AppStuff) { // message is from CppEngine, allow qml engine to process d->m_qmlEngine->filterApplicationMessage(msg, channel); } From 5645018b158427093946f3b6494599e4fdb49508 Mon Sep 17 00:00:00 2001 From: hjk Date: Thu, 21 Apr 2011 14:02:26 +0200 Subject: [PATCH 07/16] debugger: remove custom dumper location settings Reviewed-by: con --- src/plugins/debugger/commonoptionspage.cpp | 22 ------------------- src/plugins/debugger/debuggeractions.cpp | 14 ------------ src/plugins/debugger/debuggeractions.h | 2 -- src/plugins/debugger/debuggerengine.cpp | 9 -------- src/plugins/debugger/dumperoptionpage.ui | 25 ---------------------- 5 files changed, 72 deletions(-) diff --git a/src/plugins/debugger/commonoptionspage.cpp b/src/plugins/debugger/commonoptionspage.cpp index 36f5dd33e59..e991aa0b573 100644 --- a/src/plugins/debugger/commonoptionspage.cpp +++ b/src/plugins/debugger/commonoptionspage.cpp @@ -214,12 +214,6 @@ bool CommonOptionsPage::matches(const QString &s) const // /////////////////////////////////////////////////////////////////////// -static bool oxygenStyle() -{ - const ManhattanStyle *ms = qobject_cast(qApp->style()); - return ms && !qstrcmp("OxygenStyle", ms->baseStyle()->metaObject()->className()); -} - QString DebuggingHelperOptionPage::id() const { return _("Z.DebuggingHelper"); @@ -260,25 +254,11 @@ QWidget *DebuggingHelperOptionPage::createPage(QWidget *parent) QWidget *w = new QWidget(parent); m_ui.setupUi(w); - m_ui.dumperLocationChooser->setExpectedKind(Utils::PathChooser::Command); - m_ui.dumperLocationChooser->setPromptDialogTitle(QCoreApplication::translate - ("Debugger", "Choose DebuggingHelper Location")); - m_ui.dumperLocationChooser->setInitialBrowsePathBackup( - ICore::instance()->resourcePath() + "../../lib"); - m_group.clear(); DebuggerCore *dc = debuggerCore(); m_group.insert(dc->action(UseDebuggingHelpers), m_ui.debuggingHelperGroupBox); - m_group.insert(dc->action(UseCustomDebuggingHelperLocation), - m_ui.customLocationGroupBox); - // Suppress Oxygen style's giving flat group boxes bold titles. - if (oxygenStyle()) - m_ui.customLocationGroupBox->setStyleSheet(_("QGroupBox::title { font: ; }")); - - m_group.insert(dc->action(CustomDebuggingHelperLocation), - m_ui.dumperLocationChooser); m_group.insert(dc->action(UseCodeModel), m_ui.checkBoxUseCodeModel); @@ -299,8 +279,6 @@ QWidget *DebuggingHelperOptionPage::createPage(QWidget *parent) if (m_searchKeywords.isEmpty()) { QTextStream(&m_searchKeywords) << ' ' << m_ui.debuggingHelperGroupBox->title() - << ' ' << m_ui.customLocationGroupBox->title() - << ' ' << m_ui.dumperLocationLabel->text() << ' ' << m_ui.checkBoxUseCodeModel->text() << ' ' << m_ui.checkBoxShowThreadNames->text(); m_searchKeywords.remove(QLatin1Char('&')); diff --git a/src/plugins/debugger/debuggeractions.cpp b/src/plugins/debugger/debuggeractions.cpp index 74f8f36ea3c..bb8f8de0104 100644 --- a/src/plugins/debugger/debuggeractions.cpp +++ b/src/plugins/debugger/debuggeractions.cpp @@ -258,20 +258,6 @@ DebuggerSettings::DebuggerSettings(QSettings *settings) item->setValue(true); insertItem(UseDebuggingHelpers, item); - item = new SavedAction(this); - item->setSettingsKey(debugModeGroup, QLatin1String("UseCustomDebuggingHelperLocation")); - item->setCheckable(true); - item->setDefaultValue(false); - item->setValue(false); - insertItem(UseCustomDebuggingHelperLocation, item); - - item = new SavedAction(this); - item->setSettingsKey(debugModeGroup, QLatin1String("CustomDebuggingHelperLocation")); - item->setCheckable(true); - item->setDefaultValue(QString()); - item->setValue(QString()); - insertItem(CustomDebuggingHelperLocation, item); - item = new SavedAction(this); item->setSettingsKey(debugModeGroup, QLatin1String("UseCodeModel")); item->setText(tr("Use Code Model")); diff --git a/src/plugins/debugger/debuggeractions.h b/src/plugins/debugger/debuggeractions.h index eaa9c52d92a..fe5396a8d8c 100644 --- a/src/plugins/debugger/debuggeractions.h +++ b/src/plugins/debugger/debuggeractions.h @@ -100,8 +100,6 @@ enum DebuggerActionCode SwitchModeOnExit, UseDebuggingHelpers, - UseCustomDebuggingHelperLocation, - CustomDebuggingHelperLocation, UseCodeModel, ShowThreadNames, diff --git a/src/plugins/debugger/debuggerengine.cpp b/src/plugins/debugger/debuggerengine.cpp index 93f0eefffc5..b151f73f7d0 100644 --- a/src/plugins/debugger/debuggerengine.cpp +++ b/src/plugins/debugger/debuggerengine.cpp @@ -646,13 +646,6 @@ bool DebuggerEngine::qtDumperLibraryEnabled() const QStringList DebuggerEngine::qtDumperLibraryLocations() const { - if (debuggerCore()->action(UseCustomDebuggingHelperLocation)->value().toBool()) { - const QString customLocation = - debuggerCore()->action(CustomDebuggingHelperLocation)->value().toString(); - const QString location = - tr("%1 (explicitly set in the Debugger Options)").arg(customLocation); - return QStringList(location); - } return d->m_startParameters.dumperLibraryLocations; } @@ -663,8 +656,6 @@ void DebuggerEngine::showQtDumperLibraryWarning(const QString &details) QString DebuggerEngine::qtDumperLibraryName() const { - if (debuggerCore()->action(UseCustomDebuggingHelperLocation)->value().toBool()) - return debuggerCore()->action(CustomDebuggingHelperLocation)->value().toString(); return startParameters().dumperLibrary; } diff --git a/src/plugins/debugger/dumperoptionpage.ui b/src/plugins/debugger/dumperoptionpage.ui index 3dcf2478167..ff71eb9f697 100644 --- a/src/plugins/debugger/dumperoptionpage.ui +++ b/src/plugins/debugger/dumperoptionpage.ui @@ -50,31 +50,6 @@ true - - - - Use debugging helper from custom location - - - true - - - true - - - - - - Location: - - - - - - - - - From 92a3d9ba2ae8cb8c4c91df7390361d9274518d5b Mon Sep 17 00:00:00 2001 From: hjk Date: Thu, 21 Apr 2011 14:11:31 +0200 Subject: [PATCH 08/16] debugger: somewhat more verbose explanation of "UseCodeModel" Reviewed-by: con --- src/plugins/debugger/commonoptionspage.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/plugins/debugger/commonoptionspage.cpp b/src/plugins/debugger/commonoptionspage.cpp index e991aa0b573..07293704314 100644 --- a/src/plugins/debugger/commonoptionspage.cpp +++ b/src/plugins/debugger/commonoptionspage.cpp @@ -262,6 +262,8 @@ QWidget *DebuggingHelperOptionPage::createPage(QWidget *parent) m_group.insert(dc->action(UseCodeModel), m_ui.checkBoxUseCodeModel); + m_ui.checkBoxUseCodeModel->setToolTip(dc->action(UseCodeModel)->toolTip()); + m_group.insert(dc->action(ShowThreadNames), m_ui.checkBoxShowThreadNames); From a4c42ea4d9fafbefa84522ee7c7eaee5c430deab Mon Sep 17 00:00:00 2001 From: Robert Loehning Date: Thu, 21 Apr 2011 18:32:32 +0200 Subject: [PATCH 09/16] Added missing translation Reviewed-by: ossi --- share/qtcreator/translations/qtcreator_de.ts | 4 ++++ src/plugins/qt4projectmanager/qmakestep.cpp | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/share/qtcreator/translations/qtcreator_de.ts b/share/qtcreator/translations/qtcreator_de.ts index c02fc9b8436..923d6a79241 100644 --- a/share/qtcreator/translations/qtcreator_de.ts +++ b/share/qtcreator/translations/qtcreator_de.ts @@ -9544,6 +9544,10 @@ S60 emulator run configuration default display name, %1 is base pro-File name<b>qmake:</b> %1 %2 <b>qmake:</b> %1 %2 + + Might make the application vulnerable. Use only in a safe environment. + Kann die Anwendung angreifbar machen. Verwenden sie diese Option nur in sicherer Umgebung. + Qt4ProjectManager::Qt4Manager diff --git a/src/plugins/qt4projectmanager/qmakestep.cpp b/src/plugins/qt4projectmanager/qmakestep.cpp index 66549d7ed33..4c2c07f9f69 100644 --- a/src/plugins/qt4projectmanager/qmakestep.cpp +++ b/src/plugins/qt4projectmanager/qmakestep.cpp @@ -619,7 +619,7 @@ void QMakeStepConfigWidget::updateQmlDebuggingWarningsLabel() if (m_step->linkQmlDebuggingLibrary()) { if (m_step->isQmlDebuggingLibrarySupported()) { - m_ui.qmlDebuggingWarningText->setText("Might make your application vulnerable. Only use in a safe environment!"); + m_ui.qmlDebuggingWarningText->setText(tr("Might make the application vulnerable. Use only in a safe environment.")); } } From 444fd5ee191419af916bbc656583a38f38fdde14 Mon Sep 17 00:00:00 2001 From: Kai Koehne Date: Tue, 26 Apr 2011 09:18:49 +0200 Subject: [PATCH 10/16] QmlDebug: Make sure that right file is opened when hitting breakpoint Make the file search case insensitive on Windows, in case the projects directory has a different capitalization than what we store in the user settings. Reviewed-by: Robert Loehning --- src/plugins/debugger/qml/qmlengine.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/plugins/debugger/qml/qmlengine.cpp b/src/plugins/debugger/qml/qmlengine.cpp index 72df4e46c96..8df56ad9b86 100644 --- a/src/plugins/debugger/qml/qmlengine.cpp +++ b/src/plugins/debugger/qml/qmlengine.cpp @@ -1029,7 +1029,11 @@ QString QmlEngine::mangleFilenamePaths(const QString &filename, QFileInfo fileInfo(filename); if (oldBaseDir.exists() && newBaseDir.exists() && fileInfo.exists()) { - if (fileInfo.absoluteFilePath().startsWith(oldBaseDir.canonicalPath())) { + Qt::CaseSensitivity caseSensitive = Qt::CaseSensitive; +#ifdef Q_OS_WIN + caseSensitive = Qt::CaseInsensitive; +#endif + if (fileInfo.absoluteFilePath().startsWith(oldBaseDir.canonicalPath(), caseSensitive)) { QString fileRelativePath = fileInfo.canonicalFilePath().mid(oldBaseDir.canonicalPath().length()); QFileInfo projectFile(newBaseDir.canonicalPath() + QLatin1Char('/') + fileRelativePath); From 6c5647c18d81233fbc9737e89ba8eb696be4726e Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Tue, 26 Apr 2011 10:31:28 +0200 Subject: [PATCH 11/16] fix quoting of strings with spaces and backslashes at the end the regexp would match twice at the end, and thus insert a stray quote. so use a discrete loop instead. fixed the same thing in proparser/ioutils before ... Task-number: QTCREATORBUG-4291 --- src/libs/utils/abstractprocess_win.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/libs/utils/abstractprocess_win.cpp b/src/libs/utils/abstractprocess_win.cpp index 194c67e222c..4bc7c089529 100644 --- a/src/libs/utils/abstractprocess_win.cpp +++ b/src/libs/utils/abstractprocess_win.cpp @@ -81,7 +81,10 @@ static QString quoteWinArgument(const QString &arg) // The argument must not end with a \ since this would be interpreted // as escaping the quote -- rather put the \ behind the quote: e.g. // rather use "foo"\ than "foo\" - ret.replace(QRegExp(QLatin1String("(\\\\*)$")), QLatin1String("\"\\1")); + int i = ret.length(); + while (i > 0 && ret.at(i - 1) == QLatin1Char('\\')) + --i; + ret.insert(i, QLatin1Char('"')); ret.prepend(QLatin1Char('"')); } return ret; From 0f9334329de6db7511802e515d61223c1dacc955 Mon Sep 17 00:00:00 2001 From: Sergey Belyashov Date: Fri, 22 Apr 2011 18:30:13 +0400 Subject: [PATCH 12/16] Updated Russian translation --- share/qtcreator/translations/qtcreator_ru.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/share/qtcreator/translations/qtcreator_ru.ts b/share/qtcreator/translations/qtcreator_ru.ts index a5a8d779966..1f890406df8 100644 --- a/share/qtcreator/translations/qtcreator_ru.ts +++ b/share/qtcreator/translations/qtcreator_ru.ts @@ -21045,6 +21045,10 @@ Check if the phone is connected and App TRK is running. <b>qmake:</b> %1 %2 <b>qmake:</b> %1 %2 + + Might make the application vulnerable. Use only in a safe environment. + Может сделать приложение уязвимым. Используйте только в безопасных системах. + Qt4ProjectManager::QmlDebuggingLibrary From 5b97322a19321893eeb3c8b4cb27b0b121d96d9a Mon Sep 17 00:00:00 2001 From: Thomas Hartmann Date: Tue, 26 Apr 2011 13:11:23 +0200 Subject: [PATCH 13/16] QmlDesigner.qmlPuppet: fixes a bug when dragging in a WebView on KDE WebView object contains a QIcon property ("reload.icon"), which fails to be streamed from the puppet (client) to Qt Creator (server). The QIcon is created by a 'KIconEngine' in the KDE case. which isn't found on the QtCreator side. This leads operator>> in qicon.cpp to not read anything from the buffer at all ... leading to all following properties being invalid, since read from the wrong bytes in the stream. Solution: Since QIcon leads to problems and we have no current use case for a QIcon property in Bauhaus we just ignore properties of type QIcon. Reviewed-by: Marco Bubke Task-number: QTCREATORBUG-4596 --- .../designercore/instances/nodeinstanceserver.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/plugins/qmldesigner/designercore/instances/nodeinstanceserver.cpp b/src/plugins/qmldesigner/designercore/instances/nodeinstanceserver.cpp index 43849c096df..3d256b697a6 100644 --- a/src/plugins/qmldesigner/designercore/instances/nodeinstanceserver.cpp +++ b/src/plugins/qmldesigner/designercore/instances/nodeinstanceserver.cpp @@ -865,6 +865,11 @@ InformationChangedCommand NodeInstanceServer::createAllInformationChangedCommand return InformationChangedCommand(informationVector); } +static bool supportedVariantType(QVariant::Type type) +{ + return type < QVariant::UserType && type != QVariant::Icon; +} + ValuesChangedCommand NodeInstanceServer::createValuesChangedCommand(const QList &instanceList) const { QVector valueVector; @@ -872,7 +877,7 @@ ValuesChangedCommand NodeInstanceServer::createValuesChangedCommand(const QList< foreach(const ServerNodeInstance &instance, instanceList) { foreach(const QString &propertyName, instance.propertyNames()) { QVariant propertyValue = instance.property(propertyName); - if (propertyValue.type() < QVariant::UserType) + if (supportedVariantType(propertyValue.type())) valueVector.append(PropertyValueContainer(instance.instanceId(), propertyName, propertyValue, QString())); } } @@ -901,7 +906,7 @@ ValuesChangedCommand NodeInstanceServer::createValuesChangedCommand(const QVecto if( instance.isValid()) { QVariant propertyValue = instance.property(propertyName); - if (propertyValue.type() < QVariant::UserType) + if (supportedVariantType(propertyValue.type())) valueVector.append(PropertyValueContainer(instance.instanceId(), propertyName, propertyValue, QString())); } } From 30b7370f5b3612934a7b3d8131801eacd2e26a54 Mon Sep 17 00:00:00 2001 From: Christian Kamm Date: Tue, 26 Apr 2011 14:42:33 +0200 Subject: [PATCH 14/16] QmlJS: Disable unhelpful warning. (cherry picked from commit a03de5f717a033f35c5f701e865b2ac5a3c53898) --- src/libs/qmljs/qmljsinterpreter.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/libs/qmljs/qmljsinterpreter.cpp b/src/libs/qmljs/qmljsinterpreter.cpp index 1e00987a2fb..51388b6c996 100644 --- a/src/libs/qmljs/qmljsinterpreter.cpp +++ b/src/libs/qmljs/qmljsinterpreter.cpp @@ -2155,7 +2155,8 @@ QmlObjectValue *CppQmlTypes::getOrCreate(const QString &package, const QString & // first get the cpp object value QmlObjectValue *cppObject = typeByCppName(cppName); if (!cppObject) { - qWarning() << "QML type system: could not find '" << cppName << "'"; + // ### disabled for now, should be communicated to the user somehow. + //qWarning() << "QML type system: could not find '" << cppName << "'"; return 0; } From fc46f300201a98664f7dc403ac4a51e35e536e8d Mon Sep 17 00:00:00 2001 From: Tobias Hunger Date: Wed, 13 Apr 2011 15:50:14 +0200 Subject: [PATCH 15/16] Stop QTC_ASSERT from being triggered Set up UI elements before they are used. No crash since the elements are guarded by QTC_ASSERTs, but annoying output. (cherry picked from commit 1df460426b2e409cccdb38254261f75fa686e924) --- src/plugins/projectexplorer/gcctoolchain.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/plugins/projectexplorer/gcctoolchain.cpp b/src/plugins/projectexplorer/gcctoolchain.cpp index 60916585ac7..e7474de1339 100644 --- a/src/plugins/projectexplorer/gcctoolchain.cpp +++ b/src/plugins/projectexplorer/gcctoolchain.cpp @@ -567,14 +567,14 @@ Internal::GccToolChainConfigWidget::GccToolChainConfigWidget(GccToolChain *tc) : connect(m_compilerPath, SIGNAL(changed(QString)), this, SLOT(handlePathChange())); layout->addRow(tr("&Compiler path:"), m_compilerPath); + addDebuggerCommandControls(layout, gnuVersionArgs); + addErrorLabel(layout); + populateAbiList(tc->supportedAbis()); layout->addRow(tr("&ABI:"), m_abiComboBox); connect(m_abiComboBox, SIGNAL(currentIndexChanged(int)), this, SLOT(handleAbiChange())); - addDebuggerCommandControls(layout, gnuVersionArgs); - addErrorLabel(layout); - setFromToolchain(); } From a130ebf4131f13c30206d01731c62c4f530a3e69 Mon Sep 17 00:00:00 2001 From: con Date: Wed, 27 Apr 2011 09:25:16 +0200 Subject: [PATCH 16/16] Debug views menu would show after using the text marker menu. The right-click event that is handled by the extra text area for the marker menu needs to be accepted, so it's not propagated further as a context menu event. Reviewed-by: Friedemann Kleint --- src/plugins/texteditor/basetexteditor.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/plugins/texteditor/basetexteditor.cpp b/src/plugins/texteditor/basetexteditor.cpp index c66228a7e60..ef384da6dfb 100644 --- a/src/plugins/texteditor/basetexteditor.cpp +++ b/src/plugins/texteditor/basetexteditor.cpp @@ -4269,6 +4269,7 @@ void BaseTextEditorWidget::extraAreaMouseEvent(QMouseEvent *e) if (!contextMenu->isEmpty()) contextMenu->exec(e->globalPos()); delete contextMenu; + e->accept(); } } else if (d->extraAreaSelectionAnchorBlockNumber >= 0) { QTextCursor selection = cursor;