diff options
| author | Simon Hausmann <simon.hausmann@nokia.com> | 2012-09-10 19:10:20 +0200 |
|---|---|---|
| committer | Simon Hausmann <simon.hausmann@nokia.com> | 2012-09-10 19:10:20 +0200 |
| commit | 284837daa07b29d6a63a748544a90b1f5842ac5c (patch) | |
| tree | ecd258180bde91fe741e0cfd2638beb3c6da7e8e /Source/WebKit/blackberry/WebKitSupport/SelectionHandler.cpp | |
| parent | 2e2ba8ff45915f40ed3e014101269c175f2a89a0 (diff) | |
| download | qtwebkit-284837daa07b29d6a63a748544a90b1f5842ac5c.tar.gz | |
Imported WebKit commit 68645295d2e3e09af2c942f092556f06aa5f8b0d (http://svn.webkit.org/repository/webkit/trunk@128073)
New snapshot
Diffstat (limited to 'Source/WebKit/blackberry/WebKitSupport/SelectionHandler.cpp')
| -rw-r--r-- | Source/WebKit/blackberry/WebKitSupport/SelectionHandler.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/Source/WebKit/blackberry/WebKitSupport/SelectionHandler.cpp b/Source/WebKit/blackberry/WebKitSupport/SelectionHandler.cpp index 3b04247be..1e150c33e 100644 --- a/Source/WebKit/blackberry/WebKitSupport/SelectionHandler.cpp +++ b/Source/WebKit/blackberry/WebKitSupport/SelectionHandler.cpp @@ -159,7 +159,7 @@ static VisiblePosition visiblePositionForPointIgnoringClipping(const Frame& fram // outside the visible rect. To work around the bug, this is a copy of // visiblePositionAtPoint which which passes ignoreClipping=true. // See RIM Bug #4315. - HitTestResult result = frame.eventHandler()->hitTestResultAtPoint(framePoint, true /* allowShadowContent */, true /* ignoreClipping */); + HitTestResult result = frame.eventHandler()->hitTestResultAtPoint(framePoint, HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::AllowShadowContent | HitTestRequest::IgnoreClipping); Node* node = result.innerNode(); if (!node || node->document() != frame.document()) @@ -738,6 +738,8 @@ static void adjustCaretRects(WebCore::IntRect& startCaret, bool isStartCaretClip else { startCaret = rectList[0]; startCaret.setLocation(caretLocationForRect(startCaret, true, isRTL)); + // Reset width to 1 as we are strictly interested in caret location. + startCaret.setWidth(1); } if (isEndCaretClippedOut) @@ -745,15 +747,13 @@ static void adjustCaretRects(WebCore::IntRect& startCaret, bool isStartCaretClip else { endCaret = rectList[0]; endCaret.setLocation(caretLocationForRect(endCaret, false, isRTL)); + // Reset width to 1 as we are strictly interested in caret location. + endCaret.setWidth(1); } if (isStartCaretClippedOut && isEndCaretClippedOut) return; - // Reset width to 1 as we are strictly interested in caret location. - startCaret.setWidth(1); - endCaret.setWidth(1); - for (unsigned i = 1; i < rectList.size(); i++) { WebCore::IntRect currentRect(rectList[i]); @@ -874,8 +874,8 @@ void SelectionHandler::selectionPositionChanged(bool forceUpdateWithoutChange) SelectionTimingLog(LogLevelInfo, "SelectionHandler::selectionPositionChanged starting at %f", m_timer.elapsed()); - WebCore::IntRect startCaret; - WebCore::IntRect endCaret; + WebCore::IntRect startCaret(DOMSupport::InvalidPoint, WebCore::IntSize()); + WebCore::IntRect endCaret(DOMSupport::InvalidPoint, WebCore::IntSize()); // Get the text rects from the selections range. Vector<FloatQuad> quads; |
