diff options
| author | George Mount <mount@google.com> | 2012-04-10 12:34:14 -0700 |
|---|---|---|
| committer | Android (Google) Code Review <android-gerrit@google.com> | 2012-04-10 12:34:14 -0700 |
| commit | db8579a73b67ad35cf3ae8794c4a9604320f3ede (patch) | |
| tree | aec0287f49134a0a528f346622231f273f84bbf4 /Source/WebKit/android/nav | |
| parent | 04ea32d2a76ad3bc3bf87474369a8517aabc3854 (diff) | |
| parent | 76a09fb547aa97b2f0e9cbb1e4a800d61b30a477 (diff) | |
| download | external_webkit-db8579a73b67ad35cf3ae8794c4a9604320f3ede.zip external_webkit-db8579a73b67ad35cf3ae8794c4a9604320f3ede.tar.gz external_webkit-db8579a73b67ad35cf3ae8794c4a9604320f3ede.tar.bz2 | |
Merge "Keep selection handles in edit fields."
Diffstat (limited to 'Source/WebKit/android/nav')
| -rw-r--r-- | Source/WebKit/android/nav/WebView.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/WebKit/android/nav/WebView.cpp b/Source/WebKit/android/nav/WebView.cpp index a4381e6..3bd0bdc 100644 --- a/Source/WebKit/android/nav/WebView.cpp +++ b/Source/WebKit/android/nav/WebView.cpp @@ -602,8 +602,8 @@ int getHandleLayerId(SelectText::HandleId handleId, SkIPoint& cursorPoint, IntRect textRect = selectText->textRect(handleId); // Rects exclude the last pixel on right/bottom. We want only included pixels. cursorPoint.set(cursorRect.x(), cursorRect.maxY() - 1); - textRect.setHeight(textRect.height() - 1); - textRect.setWidth(textRect.width() - 1); + textRect.setHeight(std::max(1, textRect.height() - 1)); + textRect.setWidth(std::max(1, textRect.width() - 1)); textBounds = FloatQuad(textRect); if (layerId != -1) { |
