Commit ee29b74d authored by Alexander Neundorf's avatar Alexander Neundorf Committed by Christoph Cullmann
Browse files

Search&Replace: add "Role" suffix to "MatchItem" role

So it is consistent with all the other roles.
parent ebff93e1
Pipeline #146556 passed with stage
in 5 minutes and 4 seconds
......@@ -1008,7 +1008,7 @@ QVariant MatchModel::data(const QModelIndex &index, int role) const
return match.replaceText;
case PlainTextRole:
return matchToPlainText(match);
case MatchItem:
case MatchItemRole:
return QVariant::fromValue(match);
case LastMatchedRangeInFileRole:
qWarning() << "Requested last matched line from a match item instead of file item1";
......@@ -60,7 +60,7 @@ public:
......@@ -58,7 +58,7 @@ static int lineNumAreaWidth(const QModelIndex &index, const QFontMetrics &fm)
void SearchResultsDelegate::paintMatchItem(QPainter *p, const QStyleOptionViewItem &opt, const QModelIndex &index) const
const KateSearchMatch match =<KateSearchMatch>();
const KateSearchMatch match =<KateSearchMatch>();
const int line = match.range.start().line() + 1;
const int col = match.range.start().column() + 1;
const QString lineCol = QStringLiteral("%1:%2").arg(line).arg(col);
Supports Markdown
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