[SCM] WebKit Debian packaging branch, webkit-1.2, updated. upstream/1.1.90-6072-g9a69373

eric at webkit.org eric at webkit.org
Thu Apr 8 01:56:40 UTC 2010


The following commit has been merged in the webkit-1.2 branch:
commit 93e9cd2d247c7ad9b45f5971719d86b5a9df4c8c
Author: eric at webkit.org <eric at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Tue Feb 23 10:53:49 2010 +0000

    2010-02-23  Dmitriy Belenko  <dbelenko at google.com>
    
            Reviewed by Darin Fisher.
    
            Chromium: Need to be able to get the bounds of selection
            rectangle(s)
            https://bugs.webkit.org/show_bug.cgi?id=34915
    
            This change will enable about 30 test cases to pass in Chromium.
            All of these test cases are related to selection rect boundaries.
            This change will enable the test cases to retrieve the selection
            rect boundary rectangle for the current selection.
    
            * public/WebFrame.h:
            * src/WebFrameImpl.cpp:
            (WebKit::WebFrameImpl::selectionBoundsRect):
            * src/WebFrameImpl.h:
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@55137 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKit/chromium/ChangeLog b/WebKit/chromium/ChangeLog
index 1d86d98..8b3c162 100644
--- a/WebKit/chromium/ChangeLog
+++ b/WebKit/chromium/ChangeLog
@@ -1,3 +1,21 @@
+2010-02-23  Dmitriy Belenko  <dbelenko at google.com>
+
+        Reviewed by Darin Fisher.
+
+        Chromium: Need to be able to get the bounds of selection
+        rectangle(s)
+        https://bugs.webkit.org/show_bug.cgi?id=34915
+
+        This change will enable about 30 test cases to pass in Chromium.
+        All of these test cases are related to selection rect boundaries.
+        This change will enable the test cases to retrieve the selection
+        rect boundary rectangle for the current selection.
+
+        * public/WebFrame.h:
+        * src/WebFrameImpl.cpp:
+        (WebKit::WebFrameImpl::selectionBoundsRect):
+        * src/WebFrameImpl.h:
+
 2010-02-23  Steve Block  <steveblock at google.com>
 
         Reviewed by Darin Adler.
diff --git a/WebKit/chromium/public/WebFrame.h b/WebKit/chromium/public/WebFrame.h
index f193b9e..0170a4f 100644
--- a/WebKit/chromium/public/WebFrame.h
+++ b/WebKit/chromium/public/WebFrame.h
@@ -492,6 +492,12 @@ public:
                                          float pageWidthInPixels,
                                          float pageHeightInPixels) const = 0;
 
+    // Returns the bounds rect for current selection. If selection is performed
+    // on transformed text, the rect will still bound the selection but will
+    // not be transformed itself. If no selection is present, the rect will be
+    // empty ((0,0), (0,0)).
+    virtual WebRect selectionBoundsRect() const = 0;
+
 protected:
     ~WebFrame() { }
 };
diff --git a/WebKit/chromium/src/WebFrameImpl.cpp b/WebKit/chromium/src/WebFrameImpl.cpp
index 665f6a3..1292629 100644
--- a/WebKit/chromium/src/WebFrameImpl.cpp
+++ b/WebKit/chromium/src/WebFrameImpl.cpp
@@ -1534,6 +1534,14 @@ int WebFrameImpl::pageNumberForElementById(const WebString& id,
     return PrintContext::pageNumberForElement(element, pageSize);
 }
 
+WebRect WebFrameImpl::selectionBoundsRect() const
+{
+    if (hasSelection())
+        return IntRect(frame()->selectionBounds(false));
+
+    return WebRect();
+}
+
 // WebFrameImpl public ---------------------------------------------------------
 
 PassRefPtr<WebFrameImpl> WebFrameImpl::create(WebFrameClient* client)
diff --git a/WebKit/chromium/src/WebFrameImpl.h b/WebKit/chromium/src/WebFrameImpl.h
index f23106c..f41e1f5 100644
--- a/WebKit/chromium/src/WebFrameImpl.h
+++ b/WebKit/chromium/src/WebFrameImpl.h
@@ -167,6 +167,7 @@ public:
     virtual int pageNumberForElementById(const WebString& id,
                                          float pageWidthInPixels,
                                          float pageHeightInPixels) const;
+    virtual WebRect selectionBoundsRect() const;
 
     static PassRefPtr<WebFrameImpl> create(WebFrameClient* client);
     ~WebFrameImpl();

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list