From 93305d9d16186bcbcbcaaba4357456ec24b543cc Mon Sep 17 00:00:00 2001 From: iaom Date: Tue, 21 Nov 2023 10:03:53 +0800 Subject: [PATCH] =?UTF-8?q?perf(frontend):=E6=90=9C=E7=B4=A2=E7=BB=93?= =?UTF-8?q?=E6=9E=9C=E5=88=97=E8=A1=A8=E4=BD=BF=E7=94=A8=E4=B8=BB=E9=A2=98?= =?UTF-8?q?=E7=9A=84=E9=BB=98=E8=AE=A4=E8=A1=8C=E9=AB=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/view/result-view-delegate.cpp | 7 ------- frontend/view/result-view-delegate.h | 1 - 2 files changed, 8 deletions(-) diff --git a/frontend/view/result-view-delegate.cpp b/frontend/view/result-view-delegate.cpp index 25db800..c5f2f98 100644 --- a/frontend/view/result-view-delegate.cpp +++ b/frontend/view/result-view-delegate.cpp @@ -36,13 +36,6 @@ void ResultViewDelegate::setSearchKeyword(const QString ®FindKeyWords) m_hightLightEffectHelper->setExpression(regFindKeyWords); } -QSize ResultViewDelegate::sizeHint(const QStyleOptionViewItem &option, const QModelIndex &index) const -{ - QSize size = QStyledItemDelegate::sizeHint(option,index); - size.setHeight(size.height() + 10); - return size; -} - void ResultViewDelegate::paint(QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const { QStyleOptionViewItem opt = option; diff --git a/frontend/view/result-view-delegate.h b/frontend/view/result-view-delegate.h index ed915a8..8c09951 100644 --- a/frontend/view/result-view-delegate.h +++ b/frontend/view/result-view-delegate.h @@ -55,7 +55,6 @@ public: ~ResultViewDelegate() = default; void setSearchKeyword(const QString &); protected: - QSize sizeHint(const QStyleOptionViewItem &option, const QModelIndex &index) const; void paint(QPainter *, const QStyleOptionViewItem &, const QModelIndex &) const override; private: