Results 1 to 3 of 3

Thread: QListView::connect

  1. #1
    Join Date
    Nov 2009
    Posts
    15

    Default QListView::connect

    OK. Ihave this little piece of example code:

    Qt Code:
    1. QListView *seriesList = new QListView;
    2. QPushButton *bt001 = new QPushButton("001");
    3. seriesList->show();
    4. bt001->show();
    5. QListView::connect(seriesList, SIGNAL(clicked()), seriesList, SLOT(updateProbe()));
    6. QPushButton::connect(bt001, SIGNAL(clicked()), bt001, SLOT(updateProble()));
    To copy to clipboard, switch view to plain text mode 

    When I run the project, debug messaging system sends a warning:

    Qt Code:
    1. Object::connect: No such signal QListView::clicked()
    To copy to clipboard, switch view to plain text mode 

    QPushButton::connect
    works correctly. I've tried with another signals from QListView::connect but always I obtain the same message and connect doesn't work.


  2. #2
    Join Date
    Jan 2006
    Location
    Germany
    Posts
    4,380
    Thanks
    19
    Thanked 1,005 Times in 913 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60
    Wiki edits
    5

    Default Re: QListView::connect

    Try:

    Qt Code:
    1. connect(seriesList, SIGNAL(clicked(const QModelIndex &)), seriesList, SLOT(updateProbe()));
    To copy to clipboard, switch view to plain text mode 

  3. #3
    Join Date
    Nov 2009
    Posts
    15

    Default Re: QListView::connect

    Quote Originally Posted by Lykurg View Post
    Try:

    Qt Code:
    1. connect(seriesList, SIGNAL(clicked(const QModelIndex &)), seriesList, SLOT(updateProbe()));
    To copy to clipboard, switch view to plain text mode 
    Thank You very much.
    QT Documentation is not clear at this point. Or I haven't known to search it .

Tags for this Thread

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.