It is python/PySide2 interface related problem, as much as I tried, I couldn't make it sync (QListView and QTableView).
I will try to simplify it, instead of explaining the whole complicated thing which is much bigger with full of forms stuff in QT...
Just imagine to have a data structure (I guess, model) like the following:
dict_of_dicts={
'dict1':{'k1':'v1', 'k2':'v2', 'k3':'v3'},
'dict2':{'k4':'v4'},
'dict3':{'k5':'v5', 'k6':'v6', 'k7':'v7'},
}
I would like to have a form (or dialog), with 2 parts:
1) In the left of the form, to have a QListView to visualize the following:
*dict1
------
dict2
-----
dict3
NOTES:
The asterisk in the dict1 means that is selected.
The hyphens are just to separate between rows.
2) In the right of the form, to have a QTableView showing the following:
k1 | v1
-------
k2 | v2
-------
k3 | v3
NOTES:
The hyphens are just to separate between rows.
The pipes, are just to represent the columns separation.
Everytime you select the another element int the QListView, the QTableView must change to the one indicated by the original data structure.
I am sure it could be really easy for most of you guys, but I am just starting with UI stuff and MVC.