summaryrefslogtreecommitdiffstats
path: root/WebCore
diff options
context:
space:
mode:
authorAndroid (Google) Code Review <android-gerrit@google.com>2009-08-31 11:37:31 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2009-08-31 11:37:31 -0700
commite7f607ca3a06ec0129f0f95a529df91146876fff (patch)
tree5cbd8c00ac8ed67cd1555ccbaeb0fbd0ac63bcd4 /WebCore
parente82bfaed324e92bd56df404d85f0af4f7763ec6d (diff)
parent0f11606c89c49176758ed567ace0bd2e481fdca1 (diff)
downloadexternal_webkit-e7f607ca3a06ec0129f0f95a529df91146876fff.zip
external_webkit-e7f607ca3a06ec0129f0f95a529df91146876fff.tar.gz
external_webkit-e7f607ca3a06ec0129f0f95a529df91146876fff.tar.bz2
Merge change 23308 into eclair
* changes: change our hasCurrentPoint() to call skia's getPoints() instead of isEmpty(), as the latter returns true even if moveTo() has already been called on it, and webkit wants to treat that as non-empty.
Diffstat (limited to 'WebCore')
-rw-r--r--WebCore/platform/graphics/android/PathAndroid.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/WebCore/platform/graphics/android/PathAndroid.cpp b/WebCore/platform/graphics/android/PathAndroid.cpp
index a643fc0..90cd2db 100644
--- a/WebCore/platform/graphics/android/PathAndroid.cpp
+++ b/WebCore/platform/graphics/android/PathAndroid.cpp
@@ -68,7 +68,11 @@ bool Path::isEmpty() const
bool Path::hasCurrentPoint() const
{
- return !isEmpty();
+ // webkit wants to know if we have any points, including any moveTos.
+ // Skia's empty() will return true if it has just a moveTo, so we need to
+ // call getPoints(NULL), which returns the number of points,
+ // including moveTo.
+ return m_path->getPoints(0, 0) > 0;
}
bool Path::contains(const FloatPoint& point, WindRule rule) const