Results 1 to 2 of 2

Thread: QWebKit: Difference between a link-clicked vs meta-refresh at loadStarted() signal

  1. #1
    Join Date
    Oct 2009
    Posts
    38
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60

    Default QWebKit: Difference between a link-clicked vs meta-refresh at loadStarted() signal

    Hi all,

    I am modifying software for my company, written around QWebKit, and have a very specific question about the use of the QWebPage::loadStarted() signal. I can see 2 ways I could get that signal sent to me: Link clicked or meta-refresh (using the tag <meta http-equiv="refresh" content="5"> in the head area). The problem I am having is I need to know the difference, but am connecting to a signal that has no parameters. Can anyone tell me how I can find out whether the signal was received as a result of a clicked link versus a meta refresh? This is pretty important. I need to react differently (if ever so slightly) in each case.

    Thanks...

  2. #2
    Join Date
    Oct 2009
    Posts
    38
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60

    Thumbs up Re: QWebKit: Difference between a link-clicked vs meta-refresh at loadStarted() signa

    Turns out that I just needed to subclass from QWebPage and override the virtual function acceptNavigationRequest() which passes in a QWebPage::NavigationType as one of the parameters.

Similar Threads

  1. clicked() signal for QLineEdit
    By smarinr in forum Qt Programming
    Replies: 10
    Last Post: 26th June 2019, 16:35
  2. QTreeWidget clicked signal
    By ^NyAw^ in forum Qt Programming
    Replies: 41
    Last Post: 30th January 2010, 11:42
  3. How to follow a link in QWebKit?
    By piotr.dobrogost in forum Qt Programming
    Replies: 2
    Last Post: 3rd August 2009, 14:05
  4. signal mapping on pushbutton signal clicked
    By wagmare in forum Qt Programming
    Replies: 2
    Last Post: 17th March 2009, 07:54
  5. QListWidget clicked signal
    By asieriko in forum Qt Programming
    Replies: 12
    Last Post: 10th August 2007, 15:37

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.