forked from qt-creator/qt-creator
ClangTools: Add QuickFixes to the editor
Change-Id: I9862231f0aa8e8274e8529e57e80eac5ececded9 Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
This commit is contained in:
@@ -25,6 +25,7 @@
|
||||
|
||||
#include "diagnosticmark.h"
|
||||
|
||||
#include "clangtoolsconstants.h"
|
||||
#include "clangtoolsutils.h"
|
||||
|
||||
#include <utils/utilsicons.h>
|
||||
@@ -35,7 +36,7 @@ namespace Internal {
|
||||
DiagnosticMark::DiagnosticMark(const Diagnostic &diagnostic)
|
||||
: TextEditor::TextMark(Utils::FilePath::fromString(diagnostic.location.filePath),
|
||||
diagnostic.location.line,
|
||||
Utils::Id("ClangTool.DiagnosticMark"))
|
||||
Utils::Id(Constants::DIAGNOSTIC_MARK_ID))
|
||||
, m_diagnostic(diagnostic)
|
||||
{
|
||||
if (diagnostic.type == "error" || diagnostic.type == "fatal")
|
||||
@@ -67,6 +68,11 @@ bool DiagnosticMark::enabled() const
|
||||
return m_enabled;
|
||||
}
|
||||
|
||||
Diagnostic DiagnosticMark::diagnostic() const
|
||||
{
|
||||
return m_diagnostic;
|
||||
}
|
||||
|
||||
} // namespace Internal
|
||||
} // namespace ClangTools
|
||||
|
||||
|
||||
Reference in New Issue
Block a user