Commit 282864bd authored by hjk's avatar hjk

CodeAssist: Remove needless indirection in item access

Change-Id: Ibcb6c4898b34ecab52de28485befdf589bb880d7
Reviewed-by: default avatarNikolai Kosjar <nikolai.kosjar@digia.com>
parent 866a99b6
......@@ -1033,7 +1033,7 @@ void QmlJSAssistProposalModel::filter(const QString &prefix)
void QmlJSAssistProposalModel::sort(const QString &prefix)
{
std::sort(currentItems().first, currentItems().second, QmlJSLessThan(prefix));
std::sort(m_currentItems.begin(), m_currentItems.end(), QmlJSLessThan(prefix));
}
bool QmlJSAssistProposalModel::keepPerfectMatch(AssistReason reason) const
......
......@@ -326,10 +326,3 @@ AssistProposalItem *GenericProposalModel::proposalItem(int index) const
{
return m_currentItems.at(index);
}
QPair<QList<AssistProposalItem *>::iterator,
QList<AssistProposalItem *>::iterator>
GenericProposalModel::currentItems()
{
return qMakePair(m_currentItems.begin(), m_currentItems.end());
}
......@@ -74,8 +74,6 @@ public:
bool isSortingAllowed() const;
protected:
typedef QList<AssistProposalItem *>::iterator ItemIterator;
QPair<ItemIterator, ItemIterator> currentItems();
QList<AssistProposalItem *> m_currentItems;
private:
......
Markdown is supported
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