<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en_US" lang="en_US"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <!-- qwebhistoryinterface.cpp --> <title>QWebHistoryInterface Class | QtWebKit 5.2</title> <link rel="stylesheet" type="text/css" href="style/offline.css" /> </head> <body> <div class="header" id="qtdocheader"> <div class="main"> <div class="main-rounded"> <div class="navigationbar"> <ul> <li><a href="../qtdoc/index.html">Qt 5.2</a></li> <li>QWebHistoryInterface</li> <li id="buildversion"> Qt 5.2.1 Reference Documentation</li> </ul> </div> </div> <div class="content"> <div class="line"> <div class="content mainContent"> <div class="toc"> <h3><a name="toc">Contents</a></h3> <ul> <li class="level1"><a href="#public-functions">Public Functions</a></li> <li class="level1"><a href="#static-public-members">Static Public Members</a></li> <li class="level1"><a href="#details">Detailed Description</a></li> </ul> </div> <h1 class="title">QWebHistoryInterface Class</h1> <!-- $$$QWebHistoryInterface-brief --> <p>The QWebHistoryInterface class provides an interface to implement link history. <a href="#details">More...</a></p> <!-- @@@QWebHistoryInterface --> <table class="alignedsummary"> <tr><td class="memItemLeft rightAlign topAlign"> Header:</td><td class="memItemRight bottomAlign"> </b><tt><span class="preprocessor">#include <QWebHistoryInterface></span> </tt></td></tr><tr><td class="memItemLeft rightAlign topAlign"> Since:</td><td class="memItemRight bottomAlign"> Qt 4.4</td></tr><tr><td class="memItemLeft rightAlign topAlign"> Inherits:</td><td class="memItemRight bottomAlign"> <a href="../qtcore/qobject.html">QObject</a>.</td></tr></table><ul> <li><a href="qwebhistoryinterface-members.html">List of all members, including inherited members</a></li> </ul> <a name="public-functions"></a> <h2>Public Functions</h2> <table class="alignedsummary"> <tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qwebhistoryinterface.html#QWebHistoryInterface">QWebHistoryInterface</a></b>(QObject *<i> parent</i> = 0)</td></tr> <tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qwebhistoryinterface.html#dtor.QWebHistoryInterface">~QWebHistoryInterface</a></b>()</td></tr> <tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="qwebhistoryinterface.html#addHistoryEntry">addHistoryEntry</a></b>(const QString &<i> url</i>) = 0</td></tr> <tr><td class="memItemLeft rightAlign topAlign"> virtual bool </td><td class="memItemRight bottomAlign"><b><a href="qwebhistoryinterface.html#historyContains">historyContains</a></b>(const QString &<i> url</i>) const = 0</td></tr> </table> <ul> <li class="fn">31 public functions inherited from <a href="../qtcore/qobject.html#public-functions">QObject</a></li> </ul> <a name="static-public-members"></a> <h2>Static Public Members</h2> <table class="alignedsummary"> <tr><td class="memItemLeft rightAlign topAlign"> QWebHistoryInterface * </td><td class="memItemRight bottomAlign"><b><a href="qwebhistoryinterface.html#defaultInterface">defaultInterface</a></b>()</td></tr> <tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwebhistoryinterface.html#setDefaultInterface">setDefaultInterface</a></b>(QWebHistoryInterface *<i> defaultInterface</i>)</td></tr> </table> <ul> <li class="fn">10 static public members inherited from <a href="../qtcore/qobject.html#static-public-members">QObject</a></li> </ul> <h3>Additional Inherited Members</h3> <ul> <li class="fn">1 property inherited from <a href="../qtcore/qobject.html#properties">QObject</a></li> <li class="fn">1 public slot inherited from <a href="../qtcore/qobject.html#public-slots">QObject</a></li> <li class="fn">2 signals inherited from <a href="../qtcore/qobject.html#signals">QObject</a></li> <li class="fn">1 public variable inherited from <a href="../qtcore/qobject.html#public-variables">QObject</a></li> <li class="fn">9 protected functions inherited from <a href="../qtcore/qobject.html#protected-functions">QObject</a></li> <li class="fn">2 protected variables inherited from <a href="../qtcore/qobject.html#protected-variables">QObject</a></li> </ul> <a name="details"></a> <!-- $$$QWebHistoryInterface-description --> <div class="descr"> <h2>Detailed Description</h2> <p>The QWebHistoryInterface class provides an interface to implement link history.</p> <p>The QWebHistoryInterface is an interface that can be used to keep track of visited links. It contains two pure virtual methods that are called by the WebKit engine: <a href="qwebhistoryinterface.html#addHistoryEntry">addHistoryEntry</a>() is used to add urls that have been visited to the interface, while <a href="qwebhistoryinterface.html#historyContains">historyContains</a>() is used to query whether the given url has been visited by the user. By default the QWebHistoryInterface is not set, so WebKit does not keep track of visited links.</p> <p><b>Note: </b>The history tracked by QWebHistoryInterface is not specific to an instance of <a href="qwebpage.html">QWebPage</a> but applies to all pages.</p></div> <!-- @@@QWebHistoryInterface --> <div class="func"> <h2>Member Function Documentation</h2> <!-- $$$QWebHistoryInterface[overload1]$$$QWebHistoryInterfaceQObject* --> <h3 class="fn"><a name="QWebHistoryInterface"></a>QWebHistoryInterface::<span class="name">QWebHistoryInterface</span>(<span class="type"><a href="../qtcore/qobject.html">QObject</a></span> *<i> parent</i> = 0)</h3> <p>Constructs a new <a href="qwebhistoryinterface.html">QWebHistoryInterface</a> with parent <i>parent</i>.</p> <!-- @@@QWebHistoryInterface --> <!-- $$$~QWebHistoryInterface[overload1]$$$~QWebHistoryInterface --> <h3 class="fn"><a name="dtor.QWebHistoryInterface"></a>QWebHistoryInterface::<span class="name">~QWebHistoryInterface</span>()</h3> <p>Destroys the interface. If this is currently the default interface it will be unset.</p> <!-- @@@~QWebHistoryInterface --> <!-- $$$addHistoryEntry[overload1]$$$addHistoryEntryconstQString& --> <h3 class="fn"><a name="addHistoryEntry"></a><span class="type">void</span> QWebHistoryInterface::<span class="name">addHistoryEntry</span>(const <span class="type"><a href="../qtcore/qstring.html">QString</a></span> &<i> url</i>)<tt> [pure virtual]</tt></h3> <p>Called by WebKit to add another <i>url</i> to the list of visited pages.</p> <!-- @@@addHistoryEntry --> <!-- $$$defaultInterface[overload1]$$$defaultInterface --> <h3 class="fn"><a name="defaultInterface"></a><span class="type">QWebHistoryInterface</span> * QWebHistoryInterface::<span class="name">defaultInterface</span>()<tt> [static]</tt></h3> <p>Returns the default interface that will be used by WebKit. If no default interface has been set, WebKit will not keep track of visited links and a null pointer will be returned.</p> <p><b>See also </b><a href="qwebhistoryinterface.html#setDefaultInterface">setDefaultInterface</a>().</p> <!-- @@@defaultInterface --> <!-- $$$historyContains[overload1]$$$historyContainsconstQString& --> <h3 class="fn"><a name="historyContains"></a><span class="type">bool</span> QWebHistoryInterface::<span class="name">historyContains</span>(const <span class="type"><a href="../qtcore/qstring.html">QString</a></span> &<i> url</i>) const<tt> [pure virtual]</tt></h3> <p>Called by the WebKit engine to query whether a certain <i>url</i> has been visited by the user already. Returns true if the <i>url</i> is part of the history of visited links; otherwise returns false.</p> <!-- @@@historyContains --> <!-- $$$setDefaultInterface[overload1]$$$setDefaultInterfaceQWebHistoryInterface* --> <h3 class="fn"><a name="setDefaultInterface"></a><span class="type">void</span> QWebHistoryInterface::<span class="name">setDefaultInterface</span>(<span class="type">QWebHistoryInterface</span> *<i> defaultInterface</i>)<tt> [static]</tt></h3> <p>Sets a new default interface, <i>defaultInterface</i>, that will be used by all of WebKit to keep track of visited links.</p> <p>If an interface without a parent has already been set, the old interface will be deleted. When the application exists <a href="qwebhistoryinterface.html">QWebHistoryInterface</a> will automatically delete the <i>defaultInterface</i> if it does not have a parent.</p> <p><b>See also </b><a href="qwebhistoryinterface.html#defaultInterface">defaultInterface</a>().</p> <!-- @@@setDefaultInterface --> </div> </div> </div> </div> </div> </div> <div class="footer"> <p> <acronym title="Copyright">©</acronym> 2013 Digia Plc and/or its subsidiaries. Documentation contributions included herein are the copyrights of their respective owners.<br> The documentation provided herein is licensed under the terms of the <a href="http://www.gnu.org/licenses/fdl.html">GNU Free Documentation License version 1.3</a> as published by the Free Software Foundation.<br> Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide. All other trademarks are property of their respective owners. </p> </div> </body> </html>