forked from qt-creator/qt-creator
Axivion: Inline AxivionTextMark
Change-Id: I2f20e8644587bd92db814588c14c14b41a8eeba0 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
@@ -156,12 +156,9 @@ static AxivionPluginPrivate *dd = nullptr;
|
|||||||
class AxivionTextMark : public TextEditor::TextMark
|
class AxivionTextMark : public TextEditor::TextMark
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
AxivionTextMark(const FilePath &filePath, const ShortIssue &issue);
|
AxivionTextMark(const FilePath &filePath, const ShortIssue &issue)
|
||||||
};
|
|
||||||
|
|
||||||
AxivionTextMark::AxivionTextMark(const FilePath &filePath, const ShortIssue &issue)
|
|
||||||
: TextEditor::TextMark(filePath, issue.lineNumber, {Tr::tr("Axivion"), AxivionTextMarkId})
|
: TextEditor::TextMark(filePath, issue.lineNumber, {Tr::tr("Axivion"), AxivionTextMarkId})
|
||||||
{
|
{
|
||||||
const QString markText = issue.entity.isEmpty() ? issue.message
|
const QString markText = issue.entity.isEmpty() ? issue.message
|
||||||
: issue.entity + ": " + issue.message;
|
: issue.entity + ": " + issue.message;
|
||||||
setToolTip(issue.errorNumber + " " + markText);
|
setToolTip(issue.errorNumber + " " + markText);
|
||||||
@@ -175,7 +172,8 @@ AxivionTextMark::AxivionTextMark(const FilePath &filePath, const ShortIssue &iss
|
|||||||
QObject::connect(action, &QAction::triggered, dd, [id] { dd->fetchIssueInfo(id); });
|
QObject::connect(action, &QAction::triggered, dd, [id] { dd->fetchIssueInfo(id); });
|
||||||
return QList{action};
|
return QList{action};
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
};
|
||||||
|
|
||||||
void fetchProjectInfo(const QString &projectName)
|
void fetchProjectInfo(const QString &projectName)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user