[webkit-qt] Does WebKit have http connecting module?
Yanke (Yon) Hu
huyanke at gmail.com
Wed May 11 11:57:30 PDT 2011
Sorry, Markus, I just directly reply your answer and forget about the
mailing thread, here is my asking:
>From my understanding about the Qt source code, It looks
like QNetworkAccessManager handles QNetworkRequest/QNetworkReply specified
by developers. and QNetworkAccessManager will comunicate with QApplication
maybe through singal-slot mechanism, and thus the state of QApplication will
change. And this will initialize System level http call ? I see there are
system level http call implemented in
src/network/socket/qnativesocktengine_win.cpp
and src/network/socket/qnativesocktengine_unix.cpp, but just don't know how
does QApplication connect to the APIs in src/network.
Thanks for any help!!
Yanke
On Wed, May 11, 2011 at 1:08 AM, Markus Goetz <Markus.Goetz at nokia.com>wrote:
> Hi Yanke,
>
> Sorry, please ask on the mailing list :-)
>
> Thank you,
> Markus
>
> On Wednesday, May 11, 2011 12:29:27 AM ext Yanke (Yon) Hu wrote:
> > hi, Markus,
> >
> > Thank you for your quick answer. I single stepped in QT program(e.g. a
> > sample browser) , even you pass QNetworkAccessManager or webpage->load,
> > the webpage will still not show up. Only when it pass app.exec() in the
> > main function, the page will fully show up.
> >
> > Do that mean QNetworkAccessManager only make some setting (for http
> call),
> > but don't make system level http call? I guess the real http call is
> > inside QApplication(or QCoreApplication). It will go to the url directly
> > or through a proxy according the setting of QNetworkAccessManager or
> > QNetworkProxy::setApplicationProxy(*proxy). If it is this case , what is
> > the exact API QApplication use to make a http call?
> >
> > Thanks again, and have a great day!!
> >
> > Yanke
> >
> >
> >
> > On Tue, May 10, 2011 at 12:46 PM,
> > <markus.goetz at nokia.com<mailto:markus.goetz at nokia.com>> wrote: By
> default,
> > QtWebKit is using a QNetworkAccessManager, which is the HTTP stack of
> > QtNetwork. If you want to replace it, you can set a custom
> > QNetworkAccessManager.
> > http://doc.qt.nokia.com/latest/qwebpage.html#setNetworkAccessManager
> >
> > ________________________________________
> > From:
> > webkit-qt-bounces at lists.webkit.org<mailto:
> webkit-qt-bounces at lists.webkit.o
> > rg>
> > [webkit-qt-bounces at lists.webkit.org<mailto:
> webkit-qt-bounces at lists.webkit.
> > org>] On Behalf Of ext Yanke (Yon) Hu
> > [huyanke at gmail.com<mailto:huyanke at gmail.com>] Sent: Tuesday, May 10,
> 2011
> > 9:36 PM
> > To: webkit-qt at lists.webkit.org<mailto:webkit-qt at lists.webkit.org>
> > Subject: [webkit-qt] Does WebKit have http connecting module?
> >
> > hi,
> >
> > I am a beginner of WebKit. It looks like WebKit doesn't have an API about
> > setting proxy.
> >
> > Previously when I was using Molliza sdk, I can set proxy by:
> >
> > nsCOMPtr<nsIProtocolProxyService> proxyService =
> >
> > do_GetService("@mozilla.org/network/protocol-proxy-service;1<
> http://mozill
> > a.org/network/protocol-proxy-service;1><
> http://mozilla.org/network/protocol
> > -proxy-service;1>", &nrv);
> >
> > An interesting thing is: When you want to set proxy in Chrome or Safari,
> > actually you are setting system level proxy. I guess the proxy module in
> > Chrome and Safari is not related to WebKit module, but not sure.
> >
> > I find in QT, you can set proxy in application by :
> >
> > #include <QNetworkProxy>
> > ……
> > QNetworkProxy * proxy = new QNetworkProxy();
> > proxy->setHostName("localhost");
> > proxy->setPort(8888);
> > proxy->setType(QNetworkProxy::HttpProxy);
> > QNetworkProxy::setApplicationProxy(*proxy);
> >
> > Many QtWebKit based open source browser implement the proxy in this way.
> > This module looks not related to QtWebKit, but belongs to QtCore.
> >
> > So does this mean WebKit is just for rendering, and it doesn't have
> module
> > for http conecting? I previously thought WebKit should have every module
> > like Molliza Gecko. Browsers based on WebKit will just need to implement
> > UI. But the thing doesn't look like this..
> >
> > Thanks for any help!!
> >
> > Cheers,
> > Yanke
> >
> >
> > --
> >
> > Yanke Hu
> > phone: (469) 644-8799<tel:%28469%29%20644-8799>
> > email:
> > huyanke at gmail.com<mailto:huyanke at gmail.com><mailto:huyanke at gmail.com
> <mailt
> > o:huyanke at gmail.com>>
> >
> >
> >
> > --
> >
> > Yanke Hu
> > phone: (469) 644-8799<tel:%28469%29%20644-8799>
> > email: huyanke at gmail.com<mailto:huyanke at gmail.com>
>
--
Yanke Hu
phone: (469) 644-8799
email: huyanke at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-qt/attachments/20110511/eabf9e53/attachment.html>
More information about the webkit-qt
mailing list