Results 1 to 9 of 9

Thread: Treeview and custom model

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #5
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts

    Default Re: Treeview and custom model

    Remove DACanTreeModel::index(). It's incorrect and makes the model to not work properly. There should be no need to reimplement it.

    Edit: Sorry, forget what I just said. For some reason I read it as QAbstractTableModel. Some other thread must have confused me. For QAbstractItemModel you naturally need to implement index() since it's pure virtual. But do you really need a QAbstractItemModel? In some other thread your data looked flat to me, so maybe you should consider using QAbstractTableModel which makes things easier for you.
    Last edited by jpn; 15th May 2007 at 13:24.
    J-P Nurmi

Similar Threads

  1. TreeView custom model
    By steg90 in forum Newbie
    Replies: 1
    Last Post: 9th May 2007, 10:06

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.