[PATCH 3/8] SymbolView: Qt docu recommends to populate view with disabled sorting

loh.tar loh.tar at googlemail.com
Sun Jul 22 14:04:09 BST 2018


---
 addons/symbolviewer/plugin_katesymbolviewer.cpp | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/addons/symbolviewer/plugin_katesymbolviewer.cpp b/addons/symbolviewer/plugin_katesymbolviewer.cpp
index adead662b..1e08d0a2c 100644
--- a/addons/symbolviewer/plugin_katesymbolviewer.cpp
+++ b/addons/symbolviewer/plugin_katesymbolviewer.cpp
@@ -305,6 +305,9 @@ void KatePluginSymbolViewerView::slotShowContextMenu(const QPoint &p)
 void KatePluginSymbolViewerView::parseSymbols(void)
 {
    m_symbols->clear();
+   // Qt docu recommends to populate view with disabled sorting
+   // https://doc.qt.io/qt-5/qtreeview.html#sortingEnabled-prop
+   m_symbols->setSortingEnabled(false);
 
   if (!m_mainWindow->activeView())
     return;
-- 
2.18.0



More information about the KWrite-Devel mailing list