Results 1 to 9 of 9

Thread: QListWidget QObject sender

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Feb 2011
    Location
    Latvia
    Posts
    139
    Thanks
    24
    Thanked 6 Times in 6 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default QListWidget QObject sender

    I have a list, that has multiple widgets in it (QListWidget with TaskItem's in it). The Task Item can produce a certain signal. How can i find out which one send it? I know I have to use QObject::sender, but I had no luck trying to connect(..., ..., ..., ...) with it... Can anyone, please, answer - what should i do?

  2. #2
    Join Date
    Mar 2011
    Location
    Hyderabad, India
    Posts
    1,882
    Thanks
    3
    Thanked 452 Times in 435 Posts
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows
    Wiki edits
    15

    Default Re: QListWidget QObject sender

    So, what is exactly is your problem
    1. You are not able to make connect() work ?
    or
    2. You are not able to know which QListWidgetItem has sent the signal ?

    byt the way what you mean by "TaskItem"

Similar Threads

  1. QObject::sender() in a Q_PRIVATE_SLOT
    By vfernandez in forum Qt Programming
    Replies: 13
    Last Post: 17th June 2010, 19:57
  2. problem in sender()
    By wagmare in forum Qt Programming
    Replies: 13
    Last Post: 15th July 2009, 10:04
  3. [solved] Which object type is QObject::sender()?
    By ricardo in forum Qt Programming
    Replies: 6
    Last Post: 8th May 2009, 21:03
  4. tip on using QObject::sender()
    By drhex in forum Qt Programming
    Replies: 1
    Last Post: 3rd April 2008, 20:01
  5. How to add an QObject to QListWidget
    By steg90 in forum Newbie
    Replies: 7
    Last Post: 14th May 2007, 15:53

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.