Modified: trunk/Source/WebKit/blackberry/ChangeLog (134652 => 134653)
--- trunk/Source/WebKit/blackberry/ChangeLog 2012-11-14 20:48:52 UTC (rev 134652)
+++ trunk/Source/WebKit/blackberry/ChangeLog 2012-11-14 20:51:45 UTC (rev 134653)
@@ -1,3 +1,19 @@
+2012-11-14 Rob Buis <rb...@rim.com>
+
+ [BlackBerry] Improve debug functionality in FatFingers
+ https://bugs.webkit.org/show_bug.cgi?id=102263
+
+ Reviewed by Antonio Gomes.
+
+ - use logAlways to log even in release.
+ - dump shadow tree info if available.
+
+ * WebKitSupport/FatFingers.cpp:
+ (BlackBerry::WebKit::FatFingers::isElementClickable):
+ (BlackBerry::WebKit::FatFingers::checkFingerIntersection):
+ (BlackBerry::WebKit::FatFingers::findIntersectingRegions):
+ (BlackBerry::WebKit::FatFingers::checkForText):
+
2012-11-14 Adam Treat <atr...@rim.com>
[BlackBerry] Break suspend/resume of the backingstore and screen into separate methods
Modified: trunk/Source/WebKit/blackberry/WebKitSupport/FatFingers.cpp (134652 => 134653)
--- trunk/Source/WebKit/blackberry/WebKitSupport/FatFingers.cpp 2012-11-14 20:48:52 UTC (rev 134652)
+++ trunk/Source/WebKit/blackberry/WebKitSupport/FatFingers.cpp 2012-11-14 20:51:45 UTC (rev 134653)
@@ -94,6 +94,7 @@
|| element->isMediaControlElement()
|| (element->isContentEditable() && !element->isInShadowTree())
|| element->shadowPseudoId() == "-webkit-search-cancel-button";
+
}
case MadeClickableByTheWebpage:
@@ -278,7 +279,13 @@
nodeName = String::format("%s node", toElement(node)->tagName().latin1().data());
else
nodeName = "unknown node";
- BBLOG(LogLevelInfo, "%s has region %s, intersecting at %s (area %d)", nodeName.latin1().data(),
+ if (node->isInShadowTree()) {
+ nodeName = nodeName + "(in shadow tree";
+ if (node->isElementNode() && !toElement(node)->shadowPseudoId().isEmpty())
+ nodeName = nodeName + ", pseudo id " + toElement(node)->shadowPseudoId();
+ nodeName = nodeName + ")";
+ }
+ logAlways(LogLevelInfo, "%s has region %s, intersecting at %s (area %d)", nodeName.latin1().data(),
regionCopy.toString().c_str(), intersection.toString().c_str(), intersection.area());
#endif
@@ -303,7 +310,7 @@
#if DEBUG_FAT_FINGERS
IntRect fingerRect(fingerRectForPoint(frameContentPos));
IntRect screenFingerRect = m_webPage->mapToTransformed(fingerRect);
- BBLOG(LogLevelInfo, "fat finger rect now %d, %d, %d, %d", screenFingerRect.x(), screenFingerRect.y(), screenFingerRect.width(), screenFingerRect.height());
+ logAlways(LogLevelInfo, "fat finger rect now %d, %d, %d, %d", screenFingerRect.x(), screenFingerRect.y(), screenFingerRect.width(), screenFingerRect.height());
// only record the first finger rect
if (document == m_webPage->m_mainFrame->document())
@@ -433,7 +440,7 @@
RefPtr<Range> range = Range::create(document, curText, lastOffset, curText, offset);
if (!range->text().stripWhiteSpace().isEmpty()) {
#if DEBUG_FAT_FINGERS
- BBLOG(LogLevelInfo, "Checking word '%s'", range->text().latin1().data());
+ logAlways(LogLevelInfo, "Checking word '%s'", range->text().latin1().data());
#endif
IntRectRegion rangeRegion(DOMSupport::transformedBoundingBoxForRange(*range));
foundOne |= checkFingerIntersection(rangeRegion, fingerRegion, curNode, intersectingRegions);