Commit 9e5fc323 authored by cerf's avatar cerf Committed by Tobias Hunger

vcsbase: remove facility tool buttons in EditorParameterWidget

Because diff options are VCS-specific, these methods were removed :
  VCSBaseEditorParameterWidget::addIgnoreWhiteSpaceButton()
  VCSBaseEditorParameterWidget::addIgnoreBlankLinesButton()
  Associated msg*Label() and msg*ToolTip()
This impacts cvs, hg, perforce, svn and bzr plugins

Change-Id: I8d213ed3915653b78bae9ba8b6cbbd65fa269ce2
Merge-request: 340
Reviewed-by: default avatarTobias Hunger <tobias.hunger@nokia.com>
Reviewed-on: http://codereview.qt.nokia.com/323Reviewed-by: default avatarQt Sanity Bot <qt_sanity_bot@ovi.com>
parent 16ae1d73
......@@ -302,8 +302,8 @@ private:
BazaarDiffParameterWidget::BazaarDiffParameterWidget(const BazaarDiffParameters &p, QWidget *parent) :
VCSBase::VCSBaseEditorParameterWidget(parent), m_parameters(p)
{
addIgnoreWhiteSpaceButton(QLatin1String("-w"));
addIgnoreBlankLinesButton(QLatin1String("-B"));
addToggleButton(QLatin1String("-w"), tr("Ignore whitespace"));
addToggleButton(QLatin1String("-B"), tr("Ignore blank lines"));
connect(this, SIGNAL(argumentsChanged()), this, SLOT(triggerReRun()));
}
......
......@@ -552,8 +552,8 @@ CvsDiffParameterWidget::CvsDiffParameterWidget(const CvsDiffParameters &p, QWidg
VCSBase::VCSBaseEditorParameterWidget(parent), m_parameters(p)
{
setBaseArguments(p.arguments);
addIgnoreWhiteSpaceButton(QLatin1String("-w"));
addIgnoreBlankLinesButton(QLatin1String("-B"));
addToggleButton(QLatin1String("-w"), tr("Ignore whitespace"));
addToggleButton(QLatin1String("-B"), tr("Ignore blank lines"));
connect(this, SIGNAL(argumentsChanged()),
this, SLOT(triggerReRun()));
}
......
......@@ -501,8 +501,8 @@ private:
MercurialDiffParameterWidget::MercurialDiffParameterWidget(const MercurialDiffParameters &p, QWidget *parent) :
VCSBase::VCSBaseEditorParameterWidget(parent), m_parameters(p)
{
addIgnoreWhiteSpaceButton(QLatin1String("-w"));
addIgnoreBlankLinesButton(QLatin1String("-B"));
addToggleButton(QLatin1String("-w"), tr("Ignore whitespace"));
addToggleButton(QLatin1String("-B"), tr("Ignore blank lines"));
connect(this, SIGNAL(argumentsChanged()), this, SLOT(triggerReRun()));
}
......
......@@ -1244,7 +1244,7 @@ PerforceDiffParameterWidget::PerforceDiffParameterWidget(const PerforceDiffParam
VCSBase::VCSBaseEditorParameterWidget(parent), m_parameters(p)
{
setBaseArguments(p.diffArguments);
addIgnoreWhiteSpaceButton(QString(QLatin1Char('w')));
addToggleButton(QLatin1String("w"), tr("Ignore whitespace"));
connect(this, SIGNAL(argumentsChanged()), this, SLOT(triggerReRun()));
}
......
......@@ -558,7 +558,7 @@ SubversionDiffParameterWidget::SubversionDiffParameterWidget(const SubversionDif
VCSBase::VCSBaseEditorParameterWidget(parent), m_parameters(p)
{
setBaseArguments(p.arguments);
addIgnoreWhiteSpaceButton(QString(QLatin1Char('w')));
addToggleButton(QLatin1String("w"), tr("Ignore whitespace"));
connect(this, SIGNAL(argumentsChanged()), this, SLOT(triggerReRun()));
}
......
......@@ -121,16 +121,6 @@ QToolButton *VCSBaseEditorParameterWidget::addToggleButton(const QString &option
return tb;
}
QToolButton *VCSBaseEditorParameterWidget::addIgnoreWhiteSpaceButton(const QString &option)
{
return addToggleButton(option, msgIgnoreWhiteSpaceLabel(), msgIgnoreWhiteSpaceToolTip());
}
QToolButton *VCSBaseEditorParameterWidget::addIgnoreBlankLinesButton(const QString &option)
{
return addToggleButton(option, msgIgnoreBlankLinesLabel(), msgIgnoreBlankLinesToolTip());
}
QComboBox *VCSBaseEditorParameterWidget::addComboBox(const QString &option,
const QList<ComboBoxItem> &items)
{
......@@ -167,26 +157,6 @@ void VCSBaseEditorParameterWidget::setComboBoxOptionTemplate(const QStringList &
d->m_comboBoxOptionTemplate = optTemplate;
}
QString VCSBaseEditorParameterWidget::msgIgnoreWhiteSpaceLabel()
{
return tr("Ignore whitespace");
}
QString VCSBaseEditorParameterWidget::msgIgnoreWhiteSpaceToolTip()
{
return tr("Ignore whitespace only changes");
}
QString VCSBaseEditorParameterWidget::msgIgnoreBlankLinesLabel()
{
return tr("Ignore blank lines ");
}
QString VCSBaseEditorParameterWidget::msgIgnoreBlankLinesToolTip()
{
return tr("Ignore changes in blank lines");
}
void VCSBaseEditorParameterWidget::executeCommand()
{
}
......
......@@ -68,8 +68,6 @@ public:
QToolButton *addToggleButton(const QString &option, const QString &label,
const QString &tooltip = QString());
QToolButton *addIgnoreWhiteSpaceButton(const QString &option);
QToolButton *addIgnoreBlankLinesButton(const QString &option);
QComboBox *addComboBox(const QString &option, const QList<ComboBoxItem> &items);
QStringList comboBoxOptionTemplate() const;
......@@ -78,12 +76,6 @@ public:
// Return the effective arguments according to setting.
virtual QStringList arguments() const;
// Standard texts
static QString msgIgnoreWhiteSpaceLabel();
static QString msgIgnoreWhiteSpaceToolTip();
static QString msgIgnoreBlankLinesLabel();
static QString msgIgnoreBlankLinesToolTip();
public slots:
virtual void executeCommand();
virtual void handleArgumentsChanged();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment