Merge remote-tracking branch 'origin/4.1'

Change-Id: Ia90424d479936a898705c433e5810c77ae088b2c
This commit is contained in:
Orgad Shaneh
2016-07-22 15:17:36 +03:00
203 changed files with 2781 additions and 2174 deletions

View File

@@ -35,6 +35,7 @@
#include <projectexplorer/projectexplorerconstants.h>
#include <utils/algorithm.h>
#include <utils/elidinglabel.h>
#include <utils/qtcassert.h>
#include <QBoxLayout>
@@ -278,7 +279,7 @@ QString CMakeGeneratorKitConfigWidget::toolTip() const
CMakeConfigurationKitConfigWidget::CMakeConfigurationKitConfigWidget(Kit *kit,
const KitInformation *ki) :
KitConfigWidget(kit, ki),
m_summaryLabel(new QLabel),
m_summaryLabel(new Utils::ElidingLabel),
m_manageButton(new QPushButton)
{
refresh();
@@ -303,13 +304,9 @@ void CMakeConfigurationKitConfigWidget::refresh()
{
const QStringList current = CMakeConfigurationKitInformation::toStringList(kit());
QString shortSummary = current.join(QLatin1String("; "));
QFontMetrics fm(m_summaryLabel->font());
shortSummary = fm.elidedText(shortSummary, Qt::ElideRight, m_summaryLabel->width());
m_summaryLabel->setText(current.isEmpty() ? tr("<No Changes to Apply>") : shortSummary);
m_summaryLabel->setText(current.join("; "));
if (m_editor)
m_editor->setPlainText(current.join(QLatin1Char('\n')));
m_editor->setPlainText(current.join('\n'));
}
QWidget *CMakeConfigurationKitConfigWidget::mainWidget() const
@@ -344,6 +341,7 @@ void CMakeConfigurationKitConfigWidget::editConfigurationChanges()
m_editor->setToolTip(tr("Enter one variable per line with the variable name "
"separated from the variable value by \"=\".<br>"
"You may provide a type hint by adding \":TYPE\" before the \"=\"."));
m_editor->setMinimumSize(800, 200);
auto chooser = new Core::VariableChooser(m_dialog);
chooser->addSupportedWidget(m_editor);

View File

@@ -153,7 +153,7 @@ QStringList CMakeTool::supportedGenerators() const
Utils::SynchronousProcessResponse response = run(QLatin1String("--help"));
if (response.result == Utils::SynchronousProcessResponse::Finished) {
bool inGeneratorSection = false;
const QStringList lines = response.stdOut.split(QLatin1Char('\n'));
const QStringList lines = response.stdOut().split(QLatin1Char('\n'));
foreach (const QString &line, lines) {
if (line.isEmpty())
continue;
@@ -188,19 +188,19 @@ TextEditor::Keywords CMakeTool::keywords()
Utils::SynchronousProcessResponse response;
response = run(QLatin1String("--help-command-list"));
if (response.result == Utils::SynchronousProcessResponse::Finished)
m_functions = response.stdOut.split(QLatin1Char('\n'));
m_functions = response.stdOut().split(QLatin1Char('\n'));
response = run(QLatin1String("--help-commands"));
if (response.result == Utils::SynchronousProcessResponse::Finished)
parseFunctionDetailsOutput(response.stdOut);
parseFunctionDetailsOutput(response.stdOut());
response = run(QLatin1String("--help-property-list"));
if (response.result == Utils::SynchronousProcessResponse::Finished)
m_variables = parseVariableOutput(response.stdOut);
m_variables = parseVariableOutput(response.stdOut());
response = run(QLatin1String("--help-variable-list"));
if (response.result == Utils::SynchronousProcessResponse::Finished) {
m_variables.append(parseVariableOutput(response.stdOut));
m_variables.append(parseVariableOutput(response.stdOut()));
m_variables = Utils::filteredUnique(m_variables);
Utils::sort(m_variables);
}