forked from qt-creator/qt-creator
Clang: Add brief comment support
Change-Id: I5af23b6694d3d0bf45ed0a30b4d91b350f0515df Reviewed-by: Nikolai Kosjar <nikolai.kosjar@theqtcompany.com>
This commit is contained in:
@@ -110,6 +110,16 @@ quint32 CodeCompletion::priority() const
|
||||
return priority_;
|
||||
}
|
||||
|
||||
void CodeCompletion::setBriefComment(const Utf8String &briefComment)
|
||||
{
|
||||
briefComment_ = briefComment;
|
||||
}
|
||||
|
||||
const Utf8String &CodeCompletion::briefComment() const
|
||||
{
|
||||
return briefComment_;
|
||||
}
|
||||
|
||||
quint32 &CodeCompletion::completionKindAsInt()
|
||||
{
|
||||
return reinterpret_cast<quint32&>(completionKind_);
|
||||
@@ -123,6 +133,7 @@ quint32 &CodeCompletion::availabilityAsInt()
|
||||
QDataStream &operator<<(QDataStream &out, const CodeCompletion &message)
|
||||
{
|
||||
out << message.text_;
|
||||
out << message.briefComment_;
|
||||
out << message.chunks_;
|
||||
out << message.priority_;
|
||||
out << message.completionKind_;
|
||||
@@ -135,6 +146,7 @@ QDataStream &operator<<(QDataStream &out, const CodeCompletion &message)
|
||||
QDataStream &operator>>(QDataStream &in, CodeCompletion &message)
|
||||
{
|
||||
in >> message.text_;
|
||||
in >> message.briefComment_;
|
||||
in >> message.chunks_;
|
||||
in >> message.priority_;
|
||||
in >> message.completionKindAsInt();
|
||||
|
||||
@@ -107,12 +107,16 @@ public:
|
||||
void setPriority(quint32 priority);
|
||||
quint32 priority() const;
|
||||
|
||||
void setBriefComment(const Utf8String &briefComment);
|
||||
const Utf8String &briefComment() const;
|
||||
|
||||
private:
|
||||
quint32 &completionKindAsInt();
|
||||
quint32 &availabilityAsInt();
|
||||
|
||||
private:
|
||||
Utf8String text_;
|
||||
Utf8String briefComment_;
|
||||
CodeCompletionChunks chunks_;
|
||||
quint32 priority_ = 0;
|
||||
Kind completionKind_ = Other;
|
||||
|
||||
Reference in New Issue
Block a user