Creating a complex tree model in Qt

Posted by Zeke on Stack Overflow See other posts from Stack Overflow or by Zeke
Published on 2010-05-22T18:23:36Z Indexed on 2010/05/22 18:30 UTC
Read the original article Hit count: 245

Filed under:
|
|

I'm writing an IRC Client (yes another one). Long story short. I'm writing a Server dialogue that keeps a list of this:

Identity
    Networks
        Channels
        Addresses

I have 3 different list views that will be for the Networks, Channels and Addresses. When the user changes the Identity (combo box). The network listview will lookup all the networks for that specific Identity. After it loads up the Networks it will automatically select the first network and then load all the channels and addresses for that specific network.

The problem is I want to have 3 views for 1 model, to minimise all the memory and the loading of data. So that it makes it much easier to manage and not do a bunch of work.

If you'd look at QColumnView it's the same exact thing. But I don't need it to be on one exact page since the views are on entirely different tabs to make it easier to go through the Server dialogue.

I'm wondering what will be the best way to go about handling this complexity. The information is stored in a SQLite database. I already have the classes written to extract and store it. Just the modelling is the painful part of this solution.

© Stack Overflow or respective owner

Related posts about c++

Related posts about qt