Results 1 to 4 of 4

Thread: Custom Model Help PLz

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #3
    Join Date
    Aug 2007
    Posts
    4
    Thanks
    1

    Default Re: Custom Model Help PLz

    Thank very much... but my list still empty

    I've post a compilable project.

    The empty list is called lstFileRemote ( le right treeview )
    The bugged model RemoteModel
    The List is populated in this method (from a ftp connection) :



    Qt Code:
    1. void MainWindow::addToList(const QUrlInfo & urlInfo) {
    2. RemoteModel::FileList addMe;
    3. addMe.name = urlInfo.name();
    4. addMe.size = QString::number(urlInfo.size());
    5. ftp_model->insertRows(0, 1);
    6. ftp_model->setData(ftp_model->index(-1), QVariant::fromValue(addMe));
    7. }
    To copy to clipboard, switch view to plain text mode 
    Attached Files Attached Files

Similar Threads

  1. hierarchical model in a flat view
    By gniking in forum Qt Programming
    Replies: 4
    Last Post: 10th November 2009, 21:17
  2. Coin3d + Qt: SIGLNALs and SLOTs
    By vonCZ in forum Newbie
    Replies: 26
    Last Post: 15th May 2009, 08:34
  3. Help with getting my custom model working
    By thomaspu in forum Qt Programming
    Replies: 19
    Last Post: 29th July 2007, 19:35
  4. Treeview and custom model
    By steg90 in forum Qt Programming
    Replies: 8
    Last Post: 15th May 2007, 14:54
  5. TreeView custom model
    By steg90 in forum Newbie
    Replies: 1
    Last Post: 9th May 2007, 11: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.