URI: 
       tqt requests/invoices: use TreeView.sortByColumn instead of model.sort - electrum - Electrum Bitcoin wallet
  HTML git clone https://git.parazyd.org/electrum
   DIR Log
   DIR Files
   DIR Refs
   DIR Submodules
       ---
   DIR commit d81110014e5a1d32ff424c7a325c7283cd895732
   DIR parent 9f9b0954e2868a0e0572f3b3b02e2beaaa028e2d
  HTML Author: SomberNight <somber.night@protonmail.com>
       Date:   Sat,  7 Dec 2019 04:28:08 +0100
       
       qt requests/invoices: use TreeView.sortByColumn instead of model.sort
       
       sort the view, not the model
       This way, qt will display the icon indicating the sort order on the relevant column header.
       
       Diffstat:
         M electrum/gui/qt/invoice_list.py     |       2 +-
         M electrum/gui/qt/request_list.py     |       2 +-
       
       2 files changed, 2 insertions(+), 2 deletions(-)
       ---
   DIR diff --git a/electrum/gui/qt/invoice_list.py b/electrum/gui/qt/invoice_list.py
       t@@ -129,7 +129,7 @@ class InvoiceList(MyTreeView):
        
                self.selectionModel().select(self.model().index(0,0), QItemSelectionModel.SelectCurrent)
                # sort requests by date
       -        self.model().sort(self.Columns.DATE)
       +        self.sortByColumn(self.Columns.DATE, Qt.AscendingOrder)
                # hide list if empty
                if self.parent.isVisible():
                    b = self.model().rowCount() > 0
   DIR diff --git a/electrum/gui/qt/request_list.py b/electrum/gui/qt/request_list.py
       t@@ -138,7 +138,7 @@ class RequestList(MyTreeView):
                    self.model().insertRow(self.model().rowCount(), items)
                self.filter()
                # sort requests by date
       -        self.model().sort(self.Columns.DATE)
       +        self.sortByColumn(self.Columns.DATE, Qt.AscendingOrder)
                # hide list if empty
                if self.parent.isVisible():
                    b = self.model().rowCount() > 0