[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
andersca at apple.com
andersca at apple.com
Wed Dec 22 14:50:24 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit 8e27d1f6c4331d8ae4296fc2f919dcedf10fe522
Author: andersca at apple.com <andersca at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Thu Oct 21 20:24:22 2010 +0000
Find indicator does not draw found text in WebKit2 when page is not scrolled to top
<rdar://problem/8562647>
https://bugs.webkit.org/show_bug.cgi?id=48089
Reviewed by John Sullivan.
We always want the selection rectangle in "WebCore window coordinates" which is the same
as WKView coordinates in WebKit2.
* WebProcess/WebPage/FindController.cpp:
(WebKit::FindController::updateFindIndicator):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@70261 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebKit2/ChangeLog b/WebKit2/ChangeLog
index 0eefb02..f5ad058 100644
--- a/WebKit2/ChangeLog
+++ b/WebKit2/ChangeLog
@@ -1,5 +1,19 @@
2010-10-21 Anders Carlsson <andersca at apple.com>
+ Reviewed by John Sullivan.
+
+ Find indicator does not draw found text in WebKit2 when page is not scrolled to top
+ <rdar://problem/8562647>
+ https://bugs.webkit.org/show_bug.cgi?id=48089
+
+ We always want the selection rectangle in "WebCore window coordinates" which is the same
+ as WKView coordinates in WebKit2.
+
+ * WebProcess/WebPage/FindController.cpp:
+ (WebKit::FindController::updateFindIndicator):
+
+2010-10-21 Anders Carlsson <andersca at apple.com>
+
Reviewed by David Hyatt.
Always clear the selection when the find string isn't found
diff --git a/WebKit2/WebProcess/WebPage/FindController.cpp b/WebKit2/WebProcess/WebPage/FindController.cpp
index 228c5ad..c1047fd 100644
--- a/WebKit2/WebProcess/WebPage/FindController.cpp
+++ b/WebKit2/WebProcess/WebPage/FindController.cpp
@@ -143,29 +143,28 @@ bool FindController::updateFindIndicator(Frame* selectedFrame, bool isShowingOve
if (!selectedFrame)
return false;
- IntRect selectionRect = enclosingIntRect(selectedFrame->selection()->bounds());
+ // We want the selection rect in window coordinates.
+ IntRect selectionRectInWindowCoordinates = selectedFrame->view()->contentsToWindow(enclosingIntRect(selectedFrame->selection()->bounds()));
+
Vector<FloatRect> textRects;
selectedFrame->selection()->getClippedVisibleTextRectangles(textRects);
// Create a backing store and paint the find indicator text into it.
- RefPtr<BackingStore> findIndicatorTextBackingStore = BackingStore::createSharable(selectionRect.size());
+ RefPtr<BackingStore> findIndicatorTextBackingStore = BackingStore::createSharable(selectionRectInWindowCoordinates.size());
OwnPtr<GraphicsContext> graphicsContext = findIndicatorTextBackingStore->createGraphicsContext();
- graphicsContext->translate(-selectionRect.x(), -selectionRect.y());
+ graphicsContext->translate(-selectionRectInWindowCoordinates.x(), -selectionRectInWindowCoordinates.y());
selectedFrame->view()->setPaintBehavior(PaintBehaviorSelectionOnly | PaintBehaviorForceBlackText | PaintBehaviorFlattenCompositingLayers);
selectedFrame->document()->updateLayout();
-
- graphicsContext->clip(selectionRect);
- selectedFrame->view()->paint(graphicsContext.get(), selectionRect);
+
+ graphicsContext->clip(selectionRectInWindowCoordinates);
+ selectedFrame->view()->paint(graphicsContext.get(), selectionRectInWindowCoordinates);
selectedFrame->view()->setPaintBehavior(PaintBehaviorNormal);
SharedMemory::Handle handle;
if (!findIndicatorTextBackingStore->createHandle(handle))
return false;
- // We want the selection rect in window coordinates.
- IntRect selectionRectInWindowCoordinates = selectedFrame->view()->contentsToWindow(selectionRect);
-
// We want the text rects in selection rect coordinates.
Vector<FloatRect> textRectsInSelectionRectCoordinates;
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list