[SCM] WebKit Debian packaging branch, webkit-1.3, updated. upstream/1.3.7-4207-g178b198

andersca at apple.com andersca at apple.com
Sun Feb 20 23:16:59 UTC 2011


The following commit has been merged in the webkit-1.3 branch:
commit a5d54f73da5afcd15738bd00141fbce8927f6006
Author: andersca at apple.com <andersca at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Wed Jan 19 18:18:00 2011 +0000

    2011-01-19  Anders Carlsson  <andersca at apple.com>
    
            Reviewed by Darin Adler.
    
            Pass WebPageCreationParameters to DrawingArea::create
            https://bugs.webkit.org/show_bug.cgi?id=52726
    
            * WebProcess/WebPage/DrawingArea.cpp:
            (WebKit::DrawingArea::create):
            * WebProcess/WebPage/DrawingArea.h:
            * WebProcess/WebPage/DrawingAreaImpl.cpp:
            (WebKit::DrawingAreaImpl::create):
            (WebKit::DrawingAreaImpl::DrawingAreaImpl):
            * WebProcess/WebPage/DrawingAreaImpl.h:
            * WebProcess/WebPage/WebPage.cpp:
            (WebKit::WebPage::WebPage):
            (WebKit::WebPage::changeAcceleratedCompositingMode):
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@76135 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/Source/WebKit2/ChangeLog b/Source/WebKit2/ChangeLog
index dca4f08..81aa69c 100644
--- a/Source/WebKit2/ChangeLog
+++ b/Source/WebKit2/ChangeLog
@@ -1,3 +1,21 @@
+2011-01-19  Anders Carlsson  <andersca at apple.com>
+
+        Reviewed by Darin Adler.
+
+        Pass WebPageCreationParameters to DrawingArea::create
+        https://bugs.webkit.org/show_bug.cgi?id=52726
+
+        * WebProcess/WebPage/DrawingArea.cpp:
+        (WebKit::DrawingArea::create):
+        * WebProcess/WebPage/DrawingArea.h:
+        * WebProcess/WebPage/DrawingAreaImpl.cpp:
+        (WebKit::DrawingAreaImpl::create):
+        (WebKit::DrawingAreaImpl::DrawingAreaImpl):
+        * WebProcess/WebPage/DrawingAreaImpl.h:
+        * WebProcess/WebPage/WebPage.cpp:
+        (WebKit::WebPage::WebPage):
+        (WebKit::WebPage::changeAcceleratedCompositingMode):
+
 2011-01-19  Csaba Osztrogonác  <ossy at webkit.org>
 
         Reviewed by Laszlo Gombos and Tor Arne Vestbø.
diff --git a/Source/WebKit2/WebProcess/WebPage/DrawingArea.cpp b/Source/WebKit2/WebProcess/WebPage/DrawingArea.cpp
index 3b76aaf..ea5b443 100644
--- a/Source/WebKit2/WebProcess/WebPage/DrawingArea.cpp
+++ b/Source/WebKit2/WebProcess/WebPage/DrawingArea.cpp
@@ -40,31 +40,33 @@
 #include "TiledDrawingArea.h"
 #endif
 
+#include "WebPageCreationParameters.h"
+
 namespace WebKit {
 
-PassRefPtr<DrawingArea> DrawingArea::create(DrawingAreaInfo::Type type, DrawingAreaInfo::Identifier identifier, WebPage* webPage)
+PassRefPtr<DrawingArea> DrawingArea::create(WebPage* webPage, const WebPageCreationParameters& parameters)
 {
-    switch (type) {
+    switch (parameters.drawingAreaInfo.type) {
         case DrawingAreaInfo::None:
             ASSERT_NOT_REACHED();
             break;
 
         case DrawingAreaInfo::Impl:
 #ifdef __APPLE__
-            return DrawingAreaImpl::create(identifier, webPage);
+            return DrawingAreaImpl::create(webPage, parameters);
 #else
             return 0;
 #endif
         case DrawingAreaInfo::ChunkedUpdate:
-            return adoptRef(new ChunkedUpdateDrawingArea(identifier, webPage));
+            return adoptRef(new ChunkedUpdateDrawingArea(parameters.drawingAreaInfo.identifier, webPage));
 
 #if USE(ACCELERATED_COMPOSITING) && PLATFORM(MAC)
         case DrawingAreaInfo::LayerBacked:
-            return adoptRef(new LayerBackedDrawingArea(identifier, webPage));
+            return adoptRef(new LayerBackedDrawingArea(parameters.drawingAreaInfo.identifier, webPage));
 #endif
 #if ENABLE(TILED_BACKING_STORE)
         case DrawingAreaInfo::Tiled:
-            return adoptRef(new TiledDrawingArea(identifier, webPage));
+            return adoptRef(new TiledDrawingArea(parameters.drawingAreaInfo.identifier, webPage));
 #endif
     }
 
diff --git a/Source/WebKit2/WebProcess/WebPage/DrawingArea.h b/Source/WebKit2/WebProcess/WebPage/DrawingArea.h
index f8ffa4a..fb39bff 100644
--- a/Source/WebKit2/WebProcess/WebPage/DrawingArea.h
+++ b/Source/WebKit2/WebProcess/WebPage/DrawingArea.h
@@ -40,11 +40,12 @@ namespace WebCore {
 namespace WebKit {
 
 class WebPage;
+class WebPageCreationParameters;
 
 class DrawingArea : public RefCounted<DrawingArea> {
 public:
     // FIXME: It might make sense to move this create function into a factory style class. 
-    static PassRefPtr<DrawingArea> create(DrawingAreaInfo::Type, DrawingAreaInfo::Identifier, WebPage*);
+    static PassRefPtr<DrawingArea> create(WebPage*, const WebPageCreationParameters&);
     virtual ~DrawingArea();
     
 #ifdef __APPLE__
diff --git a/Source/WebKit2/WebProcess/WebPage/DrawingAreaImpl.cpp b/Source/WebKit2/WebProcess/WebPage/DrawingAreaImpl.cpp
index 04fccb7..fc484e5 100644
--- a/Source/WebKit2/WebProcess/WebPage/DrawingAreaImpl.cpp
+++ b/Source/WebKit2/WebProcess/WebPage/DrawingAreaImpl.cpp
@@ -29,6 +29,7 @@
 #include "ShareableBitmap.h"
 #include "UpdateInfo.h"
 #include "WebPage.h"
+#include "WebPageCreationParameters.h"
 #include "WebProcess.h"
 #include <WebCore/GraphicsContext.h>
 
@@ -40,17 +41,17 @@ using namespace WebCore;
 
 namespace WebKit {
 
-PassRefPtr<DrawingAreaImpl> DrawingAreaImpl::create(DrawingAreaInfo::Identifier identifier, WebPage* webPage)
+PassRefPtr<DrawingAreaImpl> DrawingAreaImpl::create(WebPage* webPage, const WebPageCreationParameters& parameters)
 {
-    return adoptRef(new DrawingAreaImpl(identifier, webPage));
+    return adoptRef(new DrawingAreaImpl(webPage, parameters));
 }
 
 DrawingAreaImpl::~DrawingAreaImpl()
 {
 }
 
-DrawingAreaImpl::DrawingAreaImpl(DrawingAreaInfo::Identifier identifier, WebPage* webPage)
-    : DrawingArea(DrawingAreaInfo::Impl, identifier, webPage)
+DrawingAreaImpl::DrawingAreaImpl(WebPage* webPage, const WebPageCreationParameters& parameters)
+    : DrawingArea(DrawingAreaInfo::Impl, parameters.drawingAreaInfo.identifier, webPage)
     , m_isWaitingForDidUpdate(false)
     , m_displayTimer(WebProcess::shared().runLoop(), this, &DrawingAreaImpl::display)
 {
diff --git a/Source/WebKit2/WebProcess/WebPage/DrawingAreaImpl.h b/Source/WebKit2/WebProcess/WebPage/DrawingAreaImpl.h
index 01273b7..fc640eb 100644
--- a/Source/WebKit2/WebProcess/WebPage/DrawingAreaImpl.h
+++ b/Source/WebKit2/WebProcess/WebPage/DrawingAreaImpl.h
@@ -36,11 +36,11 @@ struct UpdateInfo;
 
 class DrawingAreaImpl : public DrawingArea {
 public:
-    static PassRefPtr<DrawingAreaImpl> create(DrawingAreaInfo::Identifier, WebPage*);
+    static PassRefPtr<DrawingAreaImpl> create(WebPage*, const WebPageCreationParameters&);
     virtual ~DrawingAreaImpl();
 
 private:
-    DrawingAreaImpl(DrawingAreaInfo::Identifier, WebPage*);
+    DrawingAreaImpl(WebPage*, const WebPageCreationParameters&);
 
     // DrawingArea
     virtual void setNeedsDisplay(const WebCore::IntRect&);
diff --git a/Source/WebKit2/WebProcess/WebPage/WebPage.cpp b/Source/WebKit2/WebProcess/WebPage/WebPage.cpp
index 242d599..f66a598 100644
--- a/Source/WebKit2/WebProcess/WebPage/WebPage.cpp
+++ b/Source/WebKit2/WebProcess/WebPage/WebPage.cpp
@@ -182,7 +182,7 @@ WebPage::WebPage(uint64_t pageID, const WebPageCreationParameters& parameters)
     platformInitialize();
     Settings::setMinDOMTimerInterval(0.004);
 
-    m_drawingArea = DrawingArea::create(parameters.drawingAreaInfo.type, parameters.drawingAreaInfo.identifier, this);
+    m_drawingArea = DrawingArea::create(this, parameters);
     m_mainFrame = WebFrame::createMainFrame(this);
 
     setDrawsBackground(parameters.drawsBackground);
@@ -322,7 +322,9 @@ void WebPage::changeAcceleratedCompositingMode(WebCore::GraphicsLayer* layer)
     if (newDrawingAreaInfo.type != drawingArea()->info().type) {
         m_drawingArea = 0;
         if (newDrawingAreaInfo.type != DrawingAreaInfo::None) {
-            m_drawingArea = DrawingArea::create(newDrawingAreaInfo.type, newDrawingAreaInfo.identifier, this);
+            WebPageCreationParameters parameters;
+            parameters.drawingAreaInfo = newDrawingAreaInfo;
+            m_drawingArea = DrawingArea::create(this, parameters);
             m_drawingArea->setNeedsDisplay(IntRect(IntPoint(0, 0), m_viewSize));
         }
     }

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list