forked from qt-creator/qt-creator
VcsBase: Modernize headers
* Use pragma once * Use override * Remove Q_DECLARE_PRIVATE as that makes no sense for QtCreator Change-Id: Ic31d4868c172a0b8fcb50cc9a71a6e95639cf84c Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
@@ -51,43 +51,31 @@ namespace VcsBase {
|
||||
|
||||
class BaseAnnotationHighlighterPrivate
|
||||
{
|
||||
BaseAnnotationHighlighter *q_ptr;
|
||||
Q_DECLARE_PUBLIC(BaseAnnotationHighlighter)
|
||||
public:
|
||||
enum Formats {
|
||||
BackgroundFormat // C_TEXT
|
||||
};
|
||||
|
||||
BaseAnnotationHighlighterPrivate();
|
||||
BaseAnnotationHighlighterPrivate(BaseAnnotationHighlighter *q_) : q(q_) { }
|
||||
|
||||
void updateOtherFormats();
|
||||
|
||||
ChangeNumberFormatMap m_changeNumberMap;
|
||||
QColor m_background;
|
||||
BaseAnnotationHighlighter *const q;
|
||||
};
|
||||
|
||||
BaseAnnotationHighlighterPrivate::BaseAnnotationHighlighterPrivate()
|
||||
: q_ptr(0)
|
||||
{
|
||||
}
|
||||
|
||||
void BaseAnnotationHighlighterPrivate::updateOtherFormats()
|
||||
{
|
||||
Q_Q(BaseAnnotationHighlighter);
|
||||
m_background = q->formatForCategory(BackgroundFormat).brushProperty(QTextFormat::BackgroundBrush).color();
|
||||
q->setChangeNumbers(m_changeNumberMap.keys().toSet());
|
||||
}
|
||||
|
||||
|
||||
BaseAnnotationHighlighter::BaseAnnotationHighlighter(const ChangeNumbers &changeNumbers,
|
||||
QTextDocument *document) :
|
||||
TextEditor::SyntaxHighlighter(document),
|
||||
d_ptr(new BaseAnnotationHighlighterPrivate())
|
||||
d(new BaseAnnotationHighlighterPrivate(this))
|
||||
{
|
||||
d_ptr->q_ptr = this;
|
||||
|
||||
Q_D(BaseAnnotationHighlighter);
|
||||
|
||||
static QVector<TextEditor::TextStyle> categories;
|
||||
if (categories.isEmpty())
|
||||
categories << TextEditor::C_TEXT;
|
||||
@@ -100,11 +88,11 @@ BaseAnnotationHighlighter::BaseAnnotationHighlighter(const ChangeNumbers &change
|
||||
|
||||
BaseAnnotationHighlighter::~BaseAnnotationHighlighter()
|
||||
{
|
||||
delete d;
|
||||
}
|
||||
|
||||
void BaseAnnotationHighlighter::setChangeNumbers(const ChangeNumbers &changeNumbers)
|
||||
{
|
||||
Q_D(BaseAnnotationHighlighter);
|
||||
d->m_changeNumberMap.clear();
|
||||
if (!changeNumbers.isEmpty()) {
|
||||
// Assign a color gradient to annotation change numbers. Give
|
||||
@@ -125,7 +113,6 @@ void BaseAnnotationHighlighter::setChangeNumbers(const ChangeNumbers &changeNumb
|
||||
|
||||
void BaseAnnotationHighlighter::highlightBlock(const QString &text)
|
||||
{
|
||||
Q_D(BaseAnnotationHighlighter);
|
||||
if (text.isEmpty() || d->m_changeNumberMap.empty())
|
||||
return;
|
||||
const QString change = changeNumber(text);
|
||||
@@ -136,7 +123,6 @@ void BaseAnnotationHighlighter::highlightBlock(const QString &text)
|
||||
|
||||
void BaseAnnotationHighlighter::setFontSettings(const TextEditor::FontSettings &fontSettings)
|
||||
{
|
||||
Q_D(BaseAnnotationHighlighter);
|
||||
SyntaxHighlighter::setFontSettings(fontSettings);
|
||||
d->updateOtherFormats();
|
||||
}
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef BASEANNOTATIONHIGHLIGHTER_H
|
||||
#define BASEANNOTATIONHIGHLIGHTER_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
@@ -36,27 +35,26 @@ class BaseAnnotationHighlighterPrivate;
|
||||
class VCSBASE_EXPORT BaseAnnotationHighlighter : public TextEditor::SyntaxHighlighter
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_DECLARE_PRIVATE(BaseAnnotationHighlighter)
|
||||
|
||||
public:
|
||||
typedef QSet<QString> ChangeNumbers;
|
||||
|
||||
explicit BaseAnnotationHighlighter(const ChangeNumbers &changeNumbers,
|
||||
QTextDocument *document = 0);
|
||||
virtual ~BaseAnnotationHighlighter();
|
||||
~BaseAnnotationHighlighter() override;
|
||||
|
||||
void setChangeNumbers(const ChangeNumbers &changeNumbers);
|
||||
|
||||
virtual void highlightBlock(const QString &text);
|
||||
virtual void highlightBlock(const QString &text) override;
|
||||
|
||||
virtual void setFontSettings(const TextEditor::FontSettings &fontSettings);
|
||||
virtual void setFontSettings(const TextEditor::FontSettings &fontSettings) override;
|
||||
|
||||
private:
|
||||
// Implement this to return the change number of a line
|
||||
virtual QString changeNumber(const QString &block) const = 0;
|
||||
|
||||
QScopedPointer<BaseAnnotationHighlighterPrivate> d_ptr;
|
||||
BaseAnnotationHighlighterPrivate *const d;
|
||||
friend class BaseAnnotationHighlighterPrivate;
|
||||
};
|
||||
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // BASEANNOTATIONHIGHLIGHTER_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef BASEVCSEDITORFACTORY_H
|
||||
#define BASEVCSEDITORFACTORY_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
@@ -48,6 +47,3 @@ public:
|
||||
};
|
||||
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // BASEVCSEDITORFACTORY_H
|
||||
|
||||
|
@@ -37,10 +37,6 @@ VcsSubmitEditorFactory::VcsSubmitEditorFactory
|
||||
addMimeType(parameters->mimeType);
|
||||
}
|
||||
|
||||
VcsSubmitEditorFactory::~VcsSubmitEditorFactory()
|
||||
{
|
||||
}
|
||||
|
||||
Core::IEditor *VcsSubmitEditorFactory::createEditor()
|
||||
{
|
||||
return m_editorCreator();
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef BASEVCSSUBMITEDITORFACTORY_H
|
||||
#define BASEVCSSUBMITEDITORFACTORY_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
@@ -46,14 +45,11 @@ public:
|
||||
typedef std::function<VcsBaseSubmitEditor *()> EditorCreator;
|
||||
|
||||
VcsSubmitEditorFactory(const VcsBaseSubmitEditorParameters *parameters, const EditorCreator &editorCreator);
|
||||
~VcsSubmitEditorFactory();
|
||||
|
||||
Core::IEditor *createEditor();
|
||||
Core::IEditor *createEditor() override;
|
||||
|
||||
private:
|
||||
EditorCreator m_editorCreator;
|
||||
};
|
||||
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // BASEVCSSUBMITEDITORFACTORY_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef CLEANDIALOG_H
|
||||
#define CLEANDIALOG_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
@@ -44,19 +43,19 @@ class VCSBASE_EXPORT CleanDialog : public QDialog
|
||||
|
||||
public:
|
||||
explicit CleanDialog(QWidget *parent = 0);
|
||||
~CleanDialog();
|
||||
~CleanDialog() override;
|
||||
|
||||
void setFileList(const QString &workingDirectory, const QStringList &files, const QStringList &ignoredFiles);
|
||||
void setFileList(const QString &workingDirectory, const QStringList &files,
|
||||
const QStringList &ignoredFiles);
|
||||
|
||||
public slots:
|
||||
void accept();
|
||||
void accept() override;
|
||||
|
||||
private slots:
|
||||
private:
|
||||
void slotDoubleClicked(const QModelIndex &);
|
||||
void selectAllItems(bool checked);
|
||||
void updateSelectAllCheckBox();
|
||||
|
||||
private:
|
||||
QStringList checkedFiles() const;
|
||||
bool promptToDelete();
|
||||
void addFile(const QString &workingDirectory, QString fileName, bool checked);
|
||||
@@ -65,5 +64,3 @@ private:
|
||||
};
|
||||
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // CLEANDIALOG_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef COMMONSETTINGSPAGE_H
|
||||
#define COMMONSETTINGSPAGE_H
|
||||
#pragma once
|
||||
|
||||
#include "commonvcssettings.h"
|
||||
|
||||
@@ -44,15 +43,14 @@ class CommonSettingsWidget : public QWidget
|
||||
|
||||
public:
|
||||
explicit CommonSettingsWidget(QWidget *parent = 0);
|
||||
~CommonSettingsWidget();
|
||||
~CommonSettingsWidget() override;
|
||||
|
||||
CommonVcsSettings settings() const;
|
||||
void setSettings(const CommonVcsSettings &s);
|
||||
|
||||
private slots:
|
||||
private:
|
||||
void updatePath();
|
||||
|
||||
private:
|
||||
Ui::CommonSettingsPage *m_ui;
|
||||
};
|
||||
|
||||
@@ -63,9 +61,9 @@ class CommonOptionsPage : public VcsBaseOptionsPage
|
||||
public:
|
||||
explicit CommonOptionsPage(QObject *parent = 0);
|
||||
|
||||
QWidget *widget();
|
||||
void apply();
|
||||
void finish();
|
||||
QWidget *widget() override;
|
||||
void apply() override;
|
||||
void finish() override;
|
||||
|
||||
CommonVcsSettings settings() const { return m_settings; }
|
||||
|
||||
@@ -79,5 +77,3 @@ private:
|
||||
|
||||
} // namespace Internal
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // COMMONSETTINGSPAGE_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef COMMONVCSSETTINGS_H
|
||||
#define COMMONVCSSETTINGS_H
|
||||
#pragma once
|
||||
|
||||
#include <QString>
|
||||
|
||||
@@ -66,5 +65,3 @@ QDebug operator<<(QDebug, const CommonVcsSettings &);
|
||||
|
||||
} // namespace Internal
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // COMMONVCSSETTINGS_H
|
||||
|
@@ -97,14 +97,25 @@ static inline QTextCharFormat invertedColorFormat(const QTextCharFormat &in)
|
||||
// --- DiffAndLogHighlighterPrivate
|
||||
class DiffAndLogHighlighterPrivate
|
||||
{
|
||||
DiffAndLogHighlighter *q_ptr;
|
||||
Q_DECLARE_PUBLIC(DiffAndLogHighlighter)
|
||||
public:
|
||||
DiffAndLogHighlighterPrivate(const QRegExp &filePattern, const QRegExp &changePattern);
|
||||
DiffAndLogHighlighterPrivate(DiffAndLogHighlighter *q_, const QRegExp &filePattern,
|
||||
const QRegExp &changePattern) :
|
||||
q(q_),
|
||||
m_filePattern(filePattern),
|
||||
m_changePattern(changePattern),
|
||||
m_locationIndicator(QLatin1String("@@")),
|
||||
m_diffInIndicator(QLatin1Char('+')),
|
||||
m_diffOutIndicator(QLatin1Char('-')),
|
||||
m_foldingState(Internal::StartOfFile)
|
||||
{
|
||||
QTC_CHECK(filePattern.isValid());
|
||||
}
|
||||
|
||||
Internal::DiffFormats analyzeLine(const QString &block) const;
|
||||
void updateOtherFormats();
|
||||
|
||||
DiffAndLogHighlighter *const q;
|
||||
|
||||
mutable QRegExp m_filePattern;
|
||||
mutable QRegExp m_changePattern;
|
||||
const QString m_locationIndicator;
|
||||
@@ -115,18 +126,6 @@ public:
|
||||
Internal::FoldingState m_foldingState;
|
||||
};
|
||||
|
||||
DiffAndLogHighlighterPrivate::DiffAndLogHighlighterPrivate(const QRegExp &filePattern, const QRegExp &changePattern) :
|
||||
q_ptr(0),
|
||||
m_filePattern(filePattern),
|
||||
m_changePattern(changePattern),
|
||||
m_locationIndicator(QLatin1String("@@")),
|
||||
m_diffInIndicator(QLatin1Char('+')),
|
||||
m_diffOutIndicator(QLatin1Char('-')),
|
||||
m_foldingState(Internal::StartOfFile)
|
||||
{
|
||||
QTC_CHECK(filePattern.isValid());
|
||||
}
|
||||
|
||||
Internal::DiffFormats DiffAndLogHighlighterPrivate::analyzeLine(const QString &text) const
|
||||
{
|
||||
// Do not match on git "--- a/" as a deleted line, check
|
||||
@@ -146,7 +145,6 @@ Internal::DiffFormats DiffAndLogHighlighterPrivate::analyzeLine(const QString &t
|
||||
|
||||
void DiffAndLogHighlighterPrivate::updateOtherFormats()
|
||||
{
|
||||
Q_Q(DiffAndLogHighlighter);
|
||||
m_addedTrailingWhiteSpaceFormat =
|
||||
invertedColorFormat(q->formatForCategory(Internal::DiffInFormat));
|
||||
|
||||
@@ -155,11 +153,8 @@ void DiffAndLogHighlighterPrivate::updateOtherFormats()
|
||||
// --- DiffAndLogHighlighter
|
||||
DiffAndLogHighlighter::DiffAndLogHighlighter(const QRegExp &filePattern, const QRegExp &changePattern) :
|
||||
TextEditor::SyntaxHighlighter(static_cast<QTextDocument *>(0)),
|
||||
d_ptr(new DiffAndLogHighlighterPrivate(filePattern, changePattern))
|
||||
d(new DiffAndLogHighlighterPrivate(this, filePattern, changePattern))
|
||||
{
|
||||
d_ptr->q_ptr = this;
|
||||
Q_D(DiffAndLogHighlighter);
|
||||
|
||||
static QVector<TextEditor::TextStyle> categories;
|
||||
if (categories.isEmpty()) {
|
||||
categories << TextEditor::C_TEXT
|
||||
@@ -175,6 +170,7 @@ DiffAndLogHighlighter::DiffAndLogHighlighter(const QRegExp &filePattern, const Q
|
||||
|
||||
DiffAndLogHighlighter::~DiffAndLogHighlighter()
|
||||
{
|
||||
delete d;
|
||||
}
|
||||
|
||||
// Check trailing spaces
|
||||
@@ -194,7 +190,6 @@ static inline int trimmedLength(const QString &in)
|
||||
*/
|
||||
void DiffAndLogHighlighter::highlightBlock(const QString &text)
|
||||
{
|
||||
Q_D(DiffAndLogHighlighter);
|
||||
if (text.isEmpty())
|
||||
return;
|
||||
|
||||
@@ -274,7 +269,6 @@ void DiffAndLogHighlighter::highlightBlock(const QString &text)
|
||||
|
||||
void DiffAndLogHighlighter::setFontSettings(const TextEditor::FontSettings &fontSettings)
|
||||
{
|
||||
Q_D(DiffAndLogHighlighter);
|
||||
SyntaxHighlighter::setFontSettings(fontSettings);
|
||||
d->updateOtherFormats();
|
||||
}
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef DIFFANDLOGHIGHLIGHTER_H
|
||||
#define DIFFANDLOGHIGHLIGHTER_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
@@ -45,19 +44,18 @@ class DiffAndLogHighlighterPrivate;
|
||||
class VCSBASE_EXPORT DiffAndLogHighlighter : public TextEditor::SyntaxHighlighter
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_DECLARE_PRIVATE(DiffAndLogHighlighter)
|
||||
|
||||
public:
|
||||
explicit DiffAndLogHighlighter(const QRegExp &filePattern, const QRegExp &changePattern);
|
||||
~DiffAndLogHighlighter();
|
||||
~DiffAndLogHighlighter() override;
|
||||
|
||||
void highlightBlock(const QString &text);
|
||||
void highlightBlock(const QString &text) override;
|
||||
|
||||
virtual void setFontSettings(const TextEditor::FontSettings &fontSettings);
|
||||
virtual void setFontSettings(const TextEditor::FontSettings &fontSettings) override;
|
||||
|
||||
private:
|
||||
QScopedPointer<DiffAndLogHighlighterPrivate> d_ptr;
|
||||
friend class DiffAndLogHighlighterPrivate;
|
||||
DiffAndLogHighlighterPrivate *const d;
|
||||
};
|
||||
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // DIFFANDLOGHIGHLIGHTER_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef NICKNAMEDIALOG_H
|
||||
#define NICKNAMEDIALOG_H
|
||||
#pragma once
|
||||
|
||||
#include <QDialog>
|
||||
|
||||
@@ -46,7 +45,7 @@ class NickNameDialog : public QDialog
|
||||
|
||||
public:
|
||||
explicit NickNameDialog(QStandardItemModel *model, QWidget *parent = 0);
|
||||
virtual ~NickNameDialog();
|
||||
~NickNameDialog() override;
|
||||
|
||||
QString nickName() const;
|
||||
|
||||
@@ -59,11 +58,10 @@ public:
|
||||
// Return a list for a completer on the field line edits
|
||||
static QStringList nickNameList(const QStandardItemModel *model);
|
||||
|
||||
private slots:
|
||||
private:
|
||||
void slotCurrentItemChanged(const QModelIndex &);
|
||||
void slotActivated(const QModelIndex &);
|
||||
|
||||
private:
|
||||
QPushButton *okButton() const;
|
||||
|
||||
Ui::NickNameDialog *m_ui;
|
||||
@@ -73,5 +71,3 @@ private:
|
||||
|
||||
} // namespace Internal
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // NICKNAMEDIALOG_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef SUBMITEDITORFILE_H
|
||||
#define SUBMITEDITORFILE_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbasesubmiteditor.h"
|
||||
|
||||
@@ -60,8 +59,5 @@ private:
|
||||
VcsBaseSubmitEditor *m_editor;
|
||||
};
|
||||
|
||||
|
||||
} // namespace Internal
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // SUBMITEDITORFILE_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef SUBMITEDITORWIDGET_H
|
||||
#define SUBMITEDITORWIDGET_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
@@ -54,7 +53,7 @@ class VCSBASE_EXPORT SubmitEditorWidget : public QWidget
|
||||
|
||||
public:
|
||||
SubmitEditorWidget();
|
||||
~SubmitEditorWidget();
|
||||
~SubmitEditorWidget() override;
|
||||
|
||||
// Register/Unregister actions that are managed by ActionManager with this widget.
|
||||
// The submit action should have Core::Command::CA_UpdateText set as its text will
|
||||
@@ -101,18 +100,15 @@ public:
|
||||
void setUpdateInProgress(bool value);
|
||||
bool updateInProgress() const;
|
||||
|
||||
public slots:
|
||||
void updateSubmitAction();
|
||||
|
||||
signals:
|
||||
void diffSelected(const QList<int> &);
|
||||
void fileSelectionChanged(bool someFileSelected);
|
||||
void submitActionTextChanged(const QString &);
|
||||
void submitActionEnabledChanged(bool);
|
||||
|
||||
private slots:
|
||||
void updateCheckAllComboBox();
|
||||
void checkAllToggled();
|
||||
void checkAll();
|
||||
void uncheckAll();
|
||||
|
||||
protected:
|
||||
virtual QString cleanupDescription(const QString &) const;
|
||||
virtual QString commitName() const;
|
||||
@@ -124,10 +120,12 @@ protected:
|
||||
protected slots:
|
||||
void descriptionTextChanged();
|
||||
|
||||
public slots:
|
||||
void updateSubmitAction();
|
||||
private:
|
||||
void updateCheckAllComboBox();
|
||||
void checkAllToggled();
|
||||
void checkAll();
|
||||
void uncheckAll();
|
||||
|
||||
private slots:
|
||||
void triggerDiffSelected();
|
||||
void diffActivated(const QModelIndex &index);
|
||||
void diffActivatedDelayed();
|
||||
@@ -136,7 +134,6 @@ private slots:
|
||||
void editorCustomContextMenuRequested(const QPoint &);
|
||||
void fileListCustomContextMenuRequested(const QPoint & pos);
|
||||
|
||||
private:
|
||||
bool hasSelection() const;
|
||||
int checkedFilesCount() const;
|
||||
void wrapDescription();
|
||||
@@ -146,5 +143,3 @@ private:
|
||||
};
|
||||
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // SUBMITEDITORWIDGET_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef SUBMITFIELDWIDGET_H
|
||||
#define SUBMITFIELDWIDGET_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
@@ -47,7 +46,7 @@ class VCSBASE_EXPORT SubmitFieldWidget : public QWidget
|
||||
|
||||
public:
|
||||
explicit SubmitFieldWidget(QWidget *parent = 0);
|
||||
virtual ~SubmitFieldWidget();
|
||||
~SubmitFieldWidget() override;
|
||||
|
||||
QStringList fields() const;
|
||||
void setFields(const QStringList&);
|
||||
@@ -70,12 +69,11 @@ public:
|
||||
signals:
|
||||
void browseButtonClicked(int pos, const QString &field);
|
||||
|
||||
private slots:
|
||||
private:
|
||||
void slotRemove();
|
||||
void slotComboIndexChanged(int);
|
||||
void slotBrowseButtonClicked();
|
||||
|
||||
private:
|
||||
void removeField(int index);
|
||||
bool comboIndexChange(int fieldNumber, int index);
|
||||
void createField(const QString &f);
|
||||
@@ -84,5 +82,3 @@ private:
|
||||
};
|
||||
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // SUBMITFIELDWIDGET_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSBASEGLOBAL_H
|
||||
#define VCSBASEGLOBAL_H
|
||||
#pragma once
|
||||
|
||||
#include <qglobal.h>
|
||||
|
||||
@@ -33,5 +32,3 @@
|
||||
#else
|
||||
# define VCSBASE_EXPORT Q_DECL_IMPORT
|
||||
#endif
|
||||
|
||||
#endif // VCSBASEGLOBAL_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSBASECLIENT_H
|
||||
#define VCSBASECLIENT_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
@@ -46,7 +45,7 @@ namespace Core { class Id; }
|
||||
namespace Utils {
|
||||
struct SynchronousProcessResponse;
|
||||
class ExitCodeInterpreter;
|
||||
}
|
||||
} // namespace Utils
|
||||
|
||||
namespace VcsBase {
|
||||
|
||||
@@ -64,7 +63,7 @@ class VCSBASE_EXPORT VcsBaseClientImpl : public QObject
|
||||
|
||||
public:
|
||||
explicit VcsBaseClientImpl(VcsBaseClientSettings *settings);
|
||||
~VcsBaseClientImpl();
|
||||
~VcsBaseClientImpl() override;
|
||||
|
||||
VcsBaseClientSettings &settings() const;
|
||||
|
||||
@@ -137,14 +136,14 @@ public:
|
||||
class VCSBASE_EXPORT StatusItem
|
||||
{
|
||||
public:
|
||||
StatusItem() {}
|
||||
StatusItem() = default;
|
||||
StatusItem(const QString &s, const QString &f);
|
||||
QString flags;
|
||||
QString file;
|
||||
};
|
||||
|
||||
explicit VcsBaseClient(VcsBaseClientSettings *settings);
|
||||
~VcsBaseClient();
|
||||
~VcsBaseClient() override;
|
||||
virtual bool synchronousCreateRepository(const QString &workingDir,
|
||||
const QStringList &extraOptions = QStringList());
|
||||
virtual bool synchronousClone(const QString &workingDir,
|
||||
@@ -164,9 +163,9 @@ public:
|
||||
virtual bool synchronousPush(const QString &workingDir,
|
||||
const QString &dstLocation,
|
||||
const QStringList &extraOptions = QStringList());
|
||||
virtual void annotate(const QString &workingDir, const QString &file,
|
||||
void annotate(const QString &workingDir, const QString &file,
|
||||
const QString &revision = QString(), int lineNumber = -1,
|
||||
const QStringList &extraOptions = QStringList());
|
||||
const QStringList &extraOptions = QStringList()) override;
|
||||
virtual void diff(const QString &workingDir, const QStringList &files = QStringList(),
|
||||
const QStringList &extraOptions = QStringList());
|
||||
virtual void log(const QString &workingDir, const QStringList &files = QStringList(),
|
||||
@@ -241,5 +240,3 @@ private:
|
||||
};
|
||||
|
||||
} //namespace VcsBase
|
||||
|
||||
#endif // VCSBASECLIENT_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSBASECLIENTSETTINGS_H
|
||||
#define VCSBASECLIENTSETTINGS_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
@@ -103,5 +102,3 @@ inline bool operator!=(const VcsBaseClientSettings &s1, const VcsBaseClientSetti
|
||||
{ return !s1.equals(s2); }
|
||||
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // VCSBASECLIENTSETTINGS_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSBASE_CONSTANTS_H
|
||||
#define VCSBASE_CONSTANTS_H
|
||||
#pragma once
|
||||
|
||||
#include <QtGlobal>
|
||||
|
||||
@@ -51,5 +50,3 @@ const char VAR_VCS_TOPLEVELPATH[] = "CurrentProject:VcsTopLevelPath";
|
||||
|
||||
} // namespace Constants
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // VCSBASE_CONSTANTS_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSBASEEDITOR_H
|
||||
#define VCSBASEEDITOR_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
@@ -43,7 +42,7 @@ namespace VcsBase {
|
||||
namespace Internal {
|
||||
class ChangeTextCursorHandler;
|
||||
class VcsBaseEditorWidgetPrivate;
|
||||
}
|
||||
} // namespace Internal
|
||||
|
||||
class BaseAnnotationHighlighter;
|
||||
class VcsBaseEditorWidget;
|
||||
@@ -83,7 +82,7 @@ class VCSBASE_EXPORT VcsBaseEditor : public TextEditor::BaseTextEditor
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
explicit VcsBaseEditor();
|
||||
VcsBaseEditor();
|
||||
|
||||
// Utility to find a parameter set by type in an array.
|
||||
static const VcsBaseEditorParameters *
|
||||
@@ -231,19 +230,6 @@ protected:
|
||||
void mouseDoubleClickEvent(QMouseEvent *e) override;
|
||||
void keyPressEvent(QKeyEvent *) override;
|
||||
|
||||
private slots:
|
||||
void slotActivateAnnotation();
|
||||
void slotPopulateDiffBrowser();
|
||||
void slotPopulateLogBrowser();
|
||||
void slotJumpToEntry(int);
|
||||
void slotCursorPositionChanged() override;
|
||||
void slotAnnotateRevision();
|
||||
void slotApplyDiffChunk();
|
||||
void slotPaste();
|
||||
void showProgressIndicator();
|
||||
void hideProgressIndicator();
|
||||
|
||||
protected:
|
||||
/* A helper that can be used to locate a file in a diff in case it
|
||||
* is relative. Tries to derive the directory from base directory,
|
||||
* source and version control. */
|
||||
@@ -275,6 +261,17 @@ protected:
|
||||
virtual QString revisionSubject(const QTextBlock &inBlock) const;
|
||||
|
||||
private:
|
||||
void slotActivateAnnotation();
|
||||
void slotPopulateDiffBrowser();
|
||||
void slotPopulateLogBrowser();
|
||||
void slotJumpToEntry(int);
|
||||
void slotCursorPositionChanged() override;
|
||||
void slotAnnotateRevision();
|
||||
void slotApplyDiffChunk();
|
||||
void slotPaste();
|
||||
void showProgressIndicator();
|
||||
void hideProgressIndicator();
|
||||
|
||||
bool canApplyDiffChunk(const DiffChunk &dc) const;
|
||||
// Revert a patch chunk. Default implementation uses patch.exe
|
||||
bool applyDiffChunk(const DiffChunk &dc, bool revert = false) const;
|
||||
@@ -302,5 +299,3 @@ public:
|
||||
} // namespace VcsBase
|
||||
|
||||
Q_DECLARE_METATYPE(VcsBase::DiffChunk)
|
||||
|
||||
#endif // VCSBASEEDITOR_H
|
||||
|
@@ -226,11 +226,6 @@ void VcsBaseEditorParameterWidget::executeCommand()
|
||||
emit commandExecutionRequested();
|
||||
}
|
||||
|
||||
VcsBaseEditorParameterWidget::OptionMapping::OptionMapping() :
|
||||
widget(0)
|
||||
{
|
||||
}
|
||||
|
||||
VcsBaseEditorParameterWidget::OptionMapping::OptionMapping(const QString &option, QWidget *w) :
|
||||
widget(w)
|
||||
{
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSBASE_VCSBASEEDITORPARAMETERWIDGET_H
|
||||
#define VCSBASE_VCSBASEEDITORPARAMETERWIDGET_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
@@ -48,11 +47,12 @@ class VCSBASE_EXPORT VcsBaseEditorParameterWidget : public QWidget
|
||||
|
||||
public:
|
||||
explicit VcsBaseEditorParameterWidget(QWidget *parent = 0);
|
||||
~VcsBaseEditorParameterWidget();
|
||||
~VcsBaseEditorParameterWidget() override;
|
||||
|
||||
struct VCSBASE_EXPORT ComboBoxItem
|
||||
class VCSBASE_EXPORT ComboBoxItem
|
||||
{
|
||||
ComboBoxItem() {}
|
||||
public:
|
||||
ComboBoxItem() = default;
|
||||
ComboBoxItem(const QString &text, const QVariant &val);
|
||||
QString displayText;
|
||||
QVariant value;
|
||||
@@ -85,13 +85,14 @@ signals:
|
||||
void argumentsChanged();
|
||||
|
||||
protected:
|
||||
struct OptionMapping
|
||||
class OptionMapping
|
||||
{
|
||||
OptionMapping();
|
||||
public:
|
||||
OptionMapping() = default;
|
||||
OptionMapping(const QString &option, QWidget *w);
|
||||
OptionMapping(const QStringList &optionList, QWidget *w);
|
||||
QStringList options;
|
||||
QWidget *widget;
|
||||
QWidget *widget = nullptr;
|
||||
};
|
||||
|
||||
const QList<OptionMapping> &optionMappings() const;
|
||||
@@ -104,5 +105,3 @@ private:
|
||||
};
|
||||
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // VCSBASE_VCSBASEEDITORPARAMETERWIDGET_H
|
||||
|
@@ -51,9 +51,6 @@ VcsBaseOptionsPage::VcsBaseOptionsPage(QObject *parent) : Core::IOptionsPage(par
|
||||
setCategoryIcon(QLatin1String(Constants::SETTINGS_CATEGORY_VCS_ICON));
|
||||
}
|
||||
|
||||
VcsBaseOptionsPage::~VcsBaseOptionsPage()
|
||||
{ }
|
||||
|
||||
VcsClientOptionsPageWidget::VcsClientOptionsPageWidget(QWidget *parent) : QWidget(parent)
|
||||
{ }
|
||||
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSBASEOPTIONSPAGE_H
|
||||
#define VCSBASEOPTIONSPAGE_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
@@ -44,7 +43,6 @@ class VCSBASE_EXPORT VcsBaseOptionsPage : public Core::IOptionsPage
|
||||
{
|
||||
public:
|
||||
explicit VcsBaseOptionsPage(QObject *parent = 0);
|
||||
~VcsBaseOptionsPage();
|
||||
};
|
||||
|
||||
class VcsBaseClientImpl;
|
||||
@@ -69,9 +67,9 @@ public:
|
||||
|
||||
explicit VcsClientOptionsPage(Core::IVersionControl *control, VcsBaseClientImpl *client, QObject *parent = 0);
|
||||
|
||||
VcsClientOptionsPageWidget *widget();
|
||||
virtual void apply();
|
||||
virtual void finish();
|
||||
VcsClientOptionsPageWidget *widget() override;
|
||||
virtual void apply() override;
|
||||
virtual void finish() override;
|
||||
|
||||
signals:
|
||||
void settingsChanged();
|
||||
@@ -86,5 +84,3 @@ private:
|
||||
};
|
||||
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // VCSBASEOPTIONSPAGE_H
|
||||
|
@@ -353,12 +353,13 @@ public:
|
||||
*/
|
||||
|
||||
VcsBasePluginState::VcsBasePluginState() : data(new VcsBasePluginStateData)
|
||||
{
|
||||
}
|
||||
{ }
|
||||
|
||||
|
||||
VcsBasePluginState::VcsBasePluginState(const VcsBasePluginState &rhs) : data(rhs.data)
|
||||
{
|
||||
}
|
||||
{ }
|
||||
|
||||
VcsBasePluginState::~VcsBasePluginState() = default;
|
||||
|
||||
VcsBasePluginState &VcsBasePluginState::operator=(const VcsBasePluginState &rhs)
|
||||
{
|
||||
@@ -367,10 +368,6 @@ VcsBasePluginState &VcsBasePluginState::operator=(const VcsBasePluginState &rhs)
|
||||
return *this;
|
||||
}
|
||||
|
||||
VcsBasePluginState::~VcsBasePluginState()
|
||||
{
|
||||
}
|
||||
|
||||
QString VcsBasePluginState::currentFile() const
|
||||
{
|
||||
return data->m_state.currentFile;
|
||||
@@ -546,8 +543,7 @@ Internal::StateListener *VcsBasePluginPrivate::m_listener = 0;
|
||||
|
||||
VcsBasePlugin::VcsBasePlugin() :
|
||||
d(new VcsBasePluginPrivate())
|
||||
{
|
||||
}
|
||||
{ }
|
||||
|
||||
VcsBasePlugin::~VcsBasePlugin()
|
||||
{
|
||||
|
@@ -23,16 +23,15 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSBASEPLUGIN_H
|
||||
#define VCSBASEPLUGIN_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
#include <extensionsystem/iplugin.h>
|
||||
|
||||
#include <QSharedDataPointer>
|
||||
#include <QList>
|
||||
#include <QProcessEnvironment>
|
||||
#include <QSharedDataPointer>
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
class QAction;
|
||||
@@ -131,10 +130,10 @@ protected:
|
||||
explicit VcsBasePlugin();
|
||||
|
||||
void initializeVcs(Core::IVersionControl *vc, const Core::Context &context);
|
||||
void extensionsInitialized();
|
||||
void extensionsInitialized() override;
|
||||
|
||||
public:
|
||||
~VcsBasePlugin();
|
||||
~VcsBasePlugin() override;
|
||||
|
||||
const VcsBasePluginState ¤tState() const;
|
||||
Core::IVersionControl *versionControl() const;
|
||||
@@ -202,14 +201,11 @@ protected:
|
||||
// Returns whether actions should be set up further.
|
||||
bool enableMenuAction(ActionState as, QAction *in) const;
|
||||
|
||||
private slots:
|
||||
private:
|
||||
void slotSubmitEditorAboutToClose(VcsBaseSubmitEditor *submitEditor, bool *result);
|
||||
void slotStateChanged(const VcsBase::Internal::State &s, Core::IVersionControl *vc);
|
||||
|
||||
private:
|
||||
VcsBasePluginPrivate *d;
|
||||
};
|
||||
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // VCSBASEPLUGIN_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSBASE_SUBMITEDITOR_H
|
||||
#define VCSBASE_SUBMITEDITOR_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
@@ -33,8 +32,8 @@
|
||||
#include <QAbstractItemView>
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
class QIcon;
|
||||
class QAction;
|
||||
class QIcon;
|
||||
QT_END_NAMESPACE
|
||||
|
||||
namespace ProjectExplorer { class Project; }
|
||||
@@ -44,6 +43,7 @@ namespace Internal {
|
||||
class CommonVcsSettings;
|
||||
class SubmitEditorFile;
|
||||
} // namespace Internal
|
||||
|
||||
class SubmitEditorWidget;
|
||||
class SubmitFileModel;
|
||||
class VcsBaseSubmitEditorPrivate;
|
||||
@@ -132,13 +132,6 @@ signals:
|
||||
void diffSelectedRows(const QList<int> &rows);
|
||||
void fileContentsChanged();
|
||||
|
||||
private slots:
|
||||
void slotDiffSelectedVcsFiles(const QList<int> &rawList);
|
||||
void slotCheckSubmitMessage();
|
||||
void slotInsertNickName();
|
||||
void slotSetFieldNickName(int);
|
||||
void slotUpdateEditorSettings(const VcsBase::Internal::CommonVcsSettings &);
|
||||
|
||||
protected:
|
||||
/* These hooks allow for modifying the contents that goes to
|
||||
* the file. The default implementation uses the text
|
||||
@@ -153,6 +146,12 @@ protected:
|
||||
bool isDescriptionMandatory() const;
|
||||
|
||||
private:
|
||||
void slotDiffSelectedVcsFiles(const QList<int> &rawList);
|
||||
void slotCheckSubmitMessage();
|
||||
void slotInsertNickName();
|
||||
void slotSetFieldNickName(int);
|
||||
void slotUpdateEditorSettings(const VcsBase::Internal::CommonVcsSettings &);
|
||||
|
||||
void createUserFields(const QString &fieldConfigFile);
|
||||
bool checkSubmitMessage(QString *errorMessage) const;
|
||||
bool runSubmitMessageCheckScript(const QString &script, QString *errorMessage) const;
|
||||
@@ -164,5 +163,3 @@ private:
|
||||
};
|
||||
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // VCSBASE_SUBMITEDITOR_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSBASE_COMMAND_H
|
||||
#define VCSBASE_COMMAND_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
@@ -44,25 +43,23 @@ public:
|
||||
|
||||
VcsCommand(const QString &defaultWorkingDirectory, const QProcessEnvironment &environment);
|
||||
|
||||
const QProcessEnvironment processEnvironment() const;
|
||||
const QProcessEnvironment processEnvironment() const override;
|
||||
|
||||
Utils::SynchronousProcessResponse runCommand(const Utils::FileName &binary,
|
||||
const QStringList &arguments, int timeoutS,
|
||||
const QString &workDirectory = QString(),
|
||||
Utils::ExitCodeInterpreter *interpreter = 0);
|
||||
Utils::ExitCodeInterpreter *interpreter = 0) override;
|
||||
|
||||
bool runFullySynchronous(const Utils::FileName &binary, const QStringList &arguments,
|
||||
int timeoutS, QByteArray *outputData, QByteArray *errorData,
|
||||
const QString &workingDirectory = QString());
|
||||
const QString &workingDirectory = QString()) override;
|
||||
private:
|
||||
unsigned processFlags() const;
|
||||
unsigned processFlags() const override;
|
||||
void emitRepositoryChanged(const QString &workingDirectory);
|
||||
|
||||
void coreAboutToClose();
|
||||
void coreAboutToClose() override;
|
||||
|
||||
bool m_preventRepositoryChanged;
|
||||
};
|
||||
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // VCSBASE_COMMAND_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSOUTPUTWINDOW_H
|
||||
#define VCSOUTPUTWINDOW_H
|
||||
#pragma once
|
||||
|
||||
#include "vcsbase_global.h"
|
||||
|
||||
@@ -39,26 +38,26 @@ class VCSBASE_EXPORT VcsOutputWindow : public Core::IOutputPane
|
||||
Q_PROPERTY(QString repository READ repository WRITE setRepository)
|
||||
|
||||
public:
|
||||
~VcsOutputWindow();
|
||||
~VcsOutputWindow() override;
|
||||
|
||||
QWidget *outputWidget(QWidget *parent);
|
||||
QList<QWidget *> toolBarWidgets() const;
|
||||
QString displayName() const;
|
||||
QWidget *outputWidget(QWidget *parent) override;
|
||||
QList<QWidget *> toolBarWidgets() const override;
|
||||
QString displayName() const override;
|
||||
|
||||
int priorityInStatusBar() const;
|
||||
int priorityInStatusBar() const override;
|
||||
|
||||
void clearContents();
|
||||
void visibilityChanged(bool visible);
|
||||
void clearContents() override;
|
||||
void visibilityChanged(bool visible) override;
|
||||
|
||||
void setFocus();
|
||||
bool hasFocus() const;
|
||||
bool canFocus() const;
|
||||
void setFocus() override;
|
||||
bool hasFocus() const override;
|
||||
bool canFocus() const override;
|
||||
|
||||
bool canNavigate() const;
|
||||
bool canNext() const;
|
||||
bool canPrevious() const;
|
||||
void goToNext();
|
||||
void goToPrev();
|
||||
bool canNavigate() const override;
|
||||
bool canNext() const override;
|
||||
bool canPrevious() const override;
|
||||
void goToNext() override;
|
||||
void goToPrev() override;
|
||||
|
||||
static VcsOutputWindow *instance();
|
||||
|
||||
@@ -120,5 +119,3 @@ private:
|
||||
};
|
||||
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // VCSOUTPUTWINDOW_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSPLUGIN_H
|
||||
#define VCSPLUGIN_H
|
||||
#pragma once
|
||||
|
||||
#include <extensionsystem/iplugin.h>
|
||||
|
||||
@@ -49,11 +48,11 @@ class VcsPlugin : public ExtensionSystem::IPlugin
|
||||
|
||||
public:
|
||||
VcsPlugin();
|
||||
~VcsPlugin();
|
||||
~VcsPlugin() override;
|
||||
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage);
|
||||
bool initialize(const QStringList &arguments, QString *errorMessage) override;
|
||||
|
||||
void extensionsInitialized();
|
||||
void extensionsInitialized() override;
|
||||
|
||||
static VcsPlugin *instance();
|
||||
|
||||
@@ -68,10 +67,9 @@ signals:
|
||||
void settingsChanged(const VcsBase::Internal::CommonVcsSettings &s);
|
||||
void submitEditorAboutToClose(VcsBase::VcsBaseSubmitEditor *e, bool *result);
|
||||
|
||||
private slots:
|
||||
private:
|
||||
void slotSettingsChanged();
|
||||
|
||||
private:
|
||||
void populateNickNameModel();
|
||||
|
||||
static VcsPlugin *m_instance;
|
||||
@@ -81,5 +79,3 @@ private:
|
||||
|
||||
} // namespace Internal
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // VCSPLUGIN_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSBASE_PROJECTCACHE_H
|
||||
#define VCSBASE_PROJECTCACHE_H
|
||||
#pragma once
|
||||
|
||||
#include <utils/fileutils.h>
|
||||
|
||||
@@ -44,7 +43,7 @@ public:
|
||||
|
||||
private:
|
||||
VcsProjectCache();
|
||||
~VcsProjectCache();
|
||||
~VcsProjectCache() override;
|
||||
|
||||
static void invalidate();
|
||||
static ProjectExplorer::Project *projectForToplevel(const Utils::FileName &vcsTopLevel);
|
||||
@@ -69,5 +68,3 @@ private:
|
||||
|
||||
} // namespace Internal
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // VCSBASE_PROJECTCACHE_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSCOMMANDPAGE_H
|
||||
#define VCSCOMMANDPAGE_H
|
||||
#pragma once
|
||||
|
||||
#include "../vcsbase_global.h"
|
||||
|
||||
@@ -45,8 +44,8 @@ public:
|
||||
VcsCommandPageFactory();
|
||||
|
||||
Utils::WizardPage *create(ProjectExplorer::JsonWizard *wizard, Core::Id typeId,
|
||||
const QVariant &data);
|
||||
bool validateData(Core::Id typeId, const QVariant &data, QString *errorMessage);
|
||||
const QVariant &data) override;
|
||||
bool validateData(Core::Id typeId, const QVariant &data, QString *errorMessage) override;
|
||||
};
|
||||
|
||||
class VcsCommandPage : public Utils::ShellCommandPage
|
||||
@@ -56,7 +55,7 @@ class VcsCommandPage : public Utils::ShellCommandPage
|
||||
public:
|
||||
VcsCommandPage();
|
||||
|
||||
void initializePage();
|
||||
void initializePage() override;
|
||||
|
||||
void setCheckoutData(const QString &repo, const QString &baseDir, const QString &name,
|
||||
const QStringList &args);
|
||||
@@ -92,5 +91,3 @@ private:
|
||||
|
||||
} // namespace Internal
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // VCSCOMMANDPAGE_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSCONFIGURATIONPAGE_H
|
||||
#define VCSCONFIGURATIONPAGE_H
|
||||
#pragma once
|
||||
|
||||
#include "../vcsbase_global.h"
|
||||
|
||||
@@ -36,17 +35,17 @@ namespace Core { class IVersionControl; }
|
||||
|
||||
namespace VcsBase {
|
||||
|
||||
namespace Internal { class VcsConfigurationPagePrivate; }
|
||||
|
||||
namespace Internal {
|
||||
class VcsConfigurationPagePrivate;
|
||||
|
||||
class VcsConfigurationPageFactory : public ProjectExplorer::JsonWizardPageFactory
|
||||
{
|
||||
public:
|
||||
VcsConfigurationPageFactory();
|
||||
|
||||
Utils::WizardPage *create(ProjectExplorer::JsonWizard *wizard, Core::Id typeId, const QVariant &data);
|
||||
bool validateData(Core::Id typeId, const QVariant &data, QString *errorMessage);
|
||||
Utils::WizardPage *create(ProjectExplorer::JsonWizard *wizard, Core::Id typeId,
|
||||
const QVariant &data) override;
|
||||
bool validateData(Core::Id typeId, const QVariant &data, QString *errorMessage) override;
|
||||
};
|
||||
|
||||
} // namespace Internal
|
||||
@@ -57,21 +56,18 @@ class VCSBASE_EXPORT VcsConfigurationPage : public Utils::WizardPage
|
||||
|
||||
public:
|
||||
VcsConfigurationPage();
|
||||
~VcsConfigurationPage();
|
||||
~VcsConfigurationPage() override;
|
||||
|
||||
void setVersionControl(const Core::IVersionControl *vc);
|
||||
void setVersionControlId(const QString &id);
|
||||
|
||||
void initializePage();
|
||||
bool isComplete() const;
|
||||
|
||||
private slots:
|
||||
void openConfiguration();
|
||||
void initializePage() override;
|
||||
bool isComplete() const override;
|
||||
|
||||
private:
|
||||
void openConfiguration();
|
||||
|
||||
Internal::VcsConfigurationPagePrivate *const d;
|
||||
};
|
||||
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // VCSCONFIGURATIONPAGE_H
|
||||
|
@@ -23,8 +23,7 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef VCSJSEXTENSION_H
|
||||
#define VCSJSEXTENSION_H
|
||||
#pragma once
|
||||
|
||||
#include <QObject>
|
||||
|
||||
@@ -42,5 +41,3 @@ public:
|
||||
|
||||
} // namespace Internal
|
||||
} // namespace VcsBase
|
||||
|
||||
#endif // VCSJSEXTENSION_H
|
||||
|
Reference in New Issue
Block a user