Results 1 to 2 of 2

Thread: slot sequence to handle http signals

  1. #1
    Join Date
    Jun 2010
    Posts
    7
    Qt products
    Qt3 Qt4

    Default slot sequence to handle http signals

    I have two handles to hand these two signals:

    connect(myhttp, SIGNAL(requestFinished(int, bool)),
    this, SLOT(httpRequestFinished(int, bool)));

    connect( myhttp, SIGNAL(responseHeaderReceived(const QHttpResponseHeader &)),
    this, SLOT(readResponseHeader(const QHttpResponseHeader &)));

    It looks like that the signal generated in this sequence:
    1)responseHeaderReceived
    2)requestFinished

    The slots appeared to be called in sequence:
    readResponseHeader (interrupted)
    requestFinished(until finish the routine)
    readResponseHeader(continue until finished)

    The problem I have is that before I can finish handling the problem in readResponseHeader(), and requestFinished() is called with error=true?

    Any suggestions?

  2. #2
    Join Date
    Jun 2010
    Posts
    7
    Qt products
    Qt3 Qt4

    Default Re: slot sequence to handle http signals

    Hi,

    Just found out the abort() is not the normal member but a slot. The behavior I saw is the because I called abort() in the first slot, that triggers the second slot.

Similar Threads

  1. Signals and Slots and HTTP
    By weaver4 in forum Qt Programming
    Replies: 3
    Last Post: 11th January 2010, 22:44
  2. http request without signals and slots
    By whites11 in forum Newbie
    Replies: 6
    Last Post: 7th January 2010, 16:39
  3. Many signals one slot
    By ^Nisok^ in forum Newbie
    Replies: 7
    Last Post: 18th April 2009, 15:05
  4. Replies: 3
    Last Post: 27th January 2009, 21:41
  5. QHttp and readyRead signals emit sequence
    By balitong in forum Qt Programming
    Replies: 4
    Last Post: 19th June 2006, 05:22

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.