summaryrefslogtreecommitdiffstats
path: root/WebKit
diff options
context:
space:
mode:
Diffstat (limited to 'WebKit')
-rw-r--r--WebKit/android/WebCoreSupport/ChromiumInit.cpp5
-rw-r--r--WebKit/android/nav/CachedRoot.cpp5
2 files changed, 9 insertions, 1 deletions
diff --git a/WebKit/android/WebCoreSupport/ChromiumInit.cpp b/WebKit/android/WebCoreSupport/ChromiumInit.cpp
index 221704b..1872fb9 100644
--- a/WebKit/android/WebCoreSupport/ChromiumInit.cpp
+++ b/WebKit/android/WebCoreSupport/ChromiumInit.cpp
@@ -54,6 +54,10 @@ bool logMessageHandler(int severity, const char* file, int line, size_t message_
return false;
}
+namespace {
+ scoped_ptr<net::NetworkChangeNotifier> networkChangeNotifier;
+}
+
void initChromium()
{
static Lock lock;
@@ -61,6 +65,7 @@ void initChromium()
static bool initCalled = false;
if (!initCalled) {
logging::SetLogMessageHandler(logMessageHandler);
+ networkChangeNotifier.reset(net::NetworkChangeNotifier::Create());
net::HttpNetworkLayer::EnableSpdy("npn");
initCalled = true;
}
diff --git a/WebKit/android/nav/CachedRoot.cpp b/WebKit/android/nav/CachedRoot.cpp
index f5f8a71..64bf19a 100644
--- a/WebKit/android/nav/CachedRoot.cpp
+++ b/WebKit/android/nav/CachedRoot.cpp
@@ -89,6 +89,8 @@ public:
return doIRect(mUnion);
}
+ bool isEmpty() { return mUnion.isEmpty(); }
+
bool joinGlyphs(const SkIRect& rect) {
bool isGlyph = mType == kDrawGlyph_Type;
if (isGlyph)
@@ -188,7 +190,8 @@ public:
mBounder.setEmpty();
mBounder.setType(CommonCheck::kDrawGlyph_Type);
INHERITED::drawPosText(text, byteLength, pos, paint);
- mBounder.doRect(CommonCheck::kDrawPosText_Type);
+ if (!mBounder.isEmpty())
+ mBounder.doRect(CommonCheck::kDrawPosText_Type);
}
virtual void drawPosTextH(const void* text, size_t byteLength,