Changeset 131305 in webkit
- Timestamp:
- Oct 15, 2012 8:53:26 AM (11 years ago)
- Location:
- trunk/Source/WebKit/blackberry
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebKit/blackberry/ChangeLog
r131257 r131305 1 2012-10-15 Antonio Gomes <agomes@rim.com> 2 3 [BlackBerry] Clean up BackingStoreClient (part I) 4 https://bugs.webkit.org/show_bug.cgi?id=99327 5 6 Reviewed by Yong Li. 7 8 Now that we won't use the BackingStoreClient code path to scroll inner frames at all 9 (instead we use AC layers!), we can remove all "!isMainFrame" code paths. 10 11 No behavior change, since the code path being removed was not in use. 12 13 * WebKitSupport/BackingStoreClient.cpp: 14 (BlackBerry::WebKit::BackingStoreClient::absoluteRect): 15 (BlackBerry::WebKit::BackingStoreClient::transformedActualVisibleSize): 16 (BlackBerry::WebKit::BackingStoreClient::viewportSize): 17 (BlackBerry::WebKit::BackingStoreClient::transformedViewportSize): 18 (BlackBerry::WebKit::BackingStoreClient::visibleContentsRect): 19 (BlackBerry::WebKit::BackingStoreClient::transformedVisibleContentsRect): 20 (BlackBerry::WebKit::BackingStoreClient::checkOriginOfCurrentScrollOperation): 21 1 22 2012-10-13 Jakob Petsovits <jpetsovits@rim.com> 2 23 -
trunk/Source/WebKit/blackberry/WebKitSupport/BackingStoreClient.cpp
r120463 r131305 127 127 IntRect rect = IntRect(IntPoint::zero(), viewportSize()); 128 128 129 if (!isMainFrame()) { 130 // It is possible that the owner HTML element has been removed at this point, 131 // especially when the frame is loading a JavaScript URL. 132 if (Element* elt = m_frame->ownerElement()) { 133 if (RenderBox* obj = elt->renderBox()) 134 rect.move(obj->borderLeft() + obj->paddingLeft(), obj->borderTop() + obj->paddingTop()); 135 } 136 } 137 129 // FIXME: Speed it up! 138 130 Frame* frame = m_frame; 139 131 while (frame) { … … 222 214 IntSize BackingStoreClient::transformedActualVisibleSize() const 223 215 { 224 if (isMainFrame()) 225 return m_webPage->d->transformedActualVisibleSize(); 226 227 return transformedViewportSize(); 216 ASSERT(isMainFrame()); 217 return m_webPage->d->transformedActualVisibleSize(); 228 218 } 229 219 … … 234 224 return IntSize(); 235 225 236 if (isMainFrame()) 237 return m_webPage->d->viewportSize(); 238 239 return m_frame->view()->visibleContentRect().size(); 226 ASSERT(isMainFrame()); 227 return m_webPage->d->viewportSize(); 240 228 } 241 229 … … 246 234 return IntSize(); 247 235 248 if (isMainFrame()) 249 return m_webPage->d->transformedViewportSize(); 250 251 const IntSize untransformedViewportSize = m_frame->view()->visibleContentRect().size(); 252 const FloatPoint transformedBottomRight = m_webPage->d->m_transformationMatrix->mapPoint( 253 FloatPoint(untransformedViewportSize.width(), untransformedViewportSize.height())); 254 return IntSize(floorf(transformedBottomRight.x()), floorf(transformedBottomRight.y())); 236 ASSERT(isMainFrame()); 237 return m_webPage->d->transformedViewportSize(); 255 238 } 256 239 … … 262 245 263 246 IntRect visibleContentRect = m_frame->view()->visibleContentRect(); 264 if (isMainFrame()) 265 return visibleContentRect; 266 267 IntPoint offset = absoluteLocation(); 268 visibleContentRect.move(offset.x(), offset.y()); 269 if (m_parent) 270 visibleContentRect.intersect(m_parent->visibleContentsRect()); 271 247 ASSERT(isMainFrame()); 272 248 return visibleContentRect; 273 249 } … … 282 258 // always cover the whole widget/screen. 283 259 IntRect visibleContentsRect = IntRect(transformedScrollPosition(), transformedViewportSize()); 284 if (isMainFrame()) 285 return visibleContentsRect; 286 287 IntPoint offset = transformedAbsoluteLocation(); 288 visibleContentsRect.move(offset.x(), offset.y()); 260 ASSERT(isMainFrame()); 289 261 return visibleContentsRect; 290 262 } … … 411 383 return; 412 384 413 if (isMainFrame()) 414 m_webPage->d->notifyTransformedScrollChanged(); 415 else 416 m_backingStore->d->scrollChanged(transformedScrollPosition()); 417 } 418 419 } 420 } 385 ASSERT(isMainFrame()); 386 m_webPage->d->notifyTransformedScrollChanged(); 387 } 388 389 } 390 }
Note: See TracChangeset
for help on using the changeset viewer.