Add QJsonModel.clear
This also fixed the test.
This commit is contained in:
parent
58776505f9
commit
2922fb0e27
@ -131,6 +131,9 @@ class QJsonModel(QtCore.QAbstractItemModel):
|
||||
self._rootItem = QJsonTreeItem()
|
||||
self._headers = ("key", "value")
|
||||
|
||||
def clear(self):
|
||||
self.load({})
|
||||
|
||||
def load(self, document):
|
||||
"""Load from dictionary
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user