[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

commit-queue at webkit.org commit-queue at webkit.org
Wed Dec 22 14:12:21 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit 0a19d6519717047a2c569cfc91bef100fa0c3a73
Author: commit-queue at webkit.org <commit-queue at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Tue Oct 5 15:02:45 2010 +0000

    2010-10-05  Kimmo Kinnunen  <kimmo.t.kinnunen at nokia.com>
    
            Reviewed by Kenneth Rohde Christiansen.
    
            Implement API call for setting custom user agent
            (QWKPage::setCustomUserAgent)
    
            [Qt] Ability to set custom userAgent for WebKit2/WebKit
            https://bugs.webkit.org/show_bug.cgi?id=44265
    
            * UIProcess/API/qt/qwkpage.cpp:
            (QWKPage::setCustomUserAgent): Added.
            * UIProcess/API/qt/qwkpage.h: Add setCustomUserAgent.
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@69108 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKit2/ChangeLog b/WebKit2/ChangeLog
index 29bf68d..fd4bbfa 100644
--- a/WebKit2/ChangeLog
+++ b/WebKit2/ChangeLog
@@ -1,3 +1,17 @@
+2010-10-05  Kimmo Kinnunen  <kimmo.t.kinnunen at nokia.com>
+
+        Reviewed by Kenneth Rohde Christiansen.
+
+        Implement API call for setting custom user agent
+        (QWKPage::setCustomUserAgent)
+
+        [Qt] Ability to set custom userAgent for WebKit2/WebKit
+        https://bugs.webkit.org/show_bug.cgi?id=44265
+
+        * UIProcess/API/qt/qwkpage.cpp:
+        (QWKPage::setCustomUserAgent): Added.
+        * UIProcess/API/qt/qwkpage.h: Add setCustomUserAgent.
+
 2010-10-05  Sheriff Bot  <webkit.review.bot at gmail.com>
 
         Unreviewed, rolling out r69103.
diff --git a/WebKit2/UIProcess/API/qt/qwkpage.cpp b/WebKit2/UIProcess/API/qt/qwkpage.cpp
index 5c816f3..644ff1f 100644
--- a/WebKit2/UIProcess/API/qt/qwkpage.cpp
+++ b/WebKit2/UIProcess/API/qt/qwkpage.cpp
@@ -382,6 +382,12 @@ void QWKPage::setCreateNewPageFunction(CreateNewPageFn function)
     d->createNewPageFn = function;
 }
 
+void QWKPage::setCustomUserAgent(const QString& userAgent)
+{
+    WKRetainPtr<WKStringRef> wkUserAgent(WKStringCreateWithQString(userAgent));
+    WKPageSetCustomUserAgent(pageRef(), wkUserAgent.get());
+}
+
 void QWKPage::load(const QUrl& url)
 {
     WKRetainPtr<WKURLRef> wkurl(WKURLCreateWithQUrl(url));
diff --git a/WebKit2/UIProcess/API/qt/qwkpage.h b/WebKit2/UIProcess/API/qt/qwkpage.h
index b96e04a..0bb9db9 100644
--- a/WebKit2/UIProcess/API/qt/qwkpage.h
+++ b/WebKit2/UIProcess/API/qt/qwkpage.h
@@ -87,6 +87,8 @@ public:
     typedef QWKPage* (*CreateNewPageFn)(QWKPage*);
     void setCreateNewPageFunction(CreateNewPageFn function);
 
+    void setCustomUserAgent(const QString&);
+
 public:
     Q_SIGNAL void statusBarMessage(const QString&);
     Q_SIGNAL void titleChanged(const QString&);

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list