Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1162)

Unified Diff: third_party/WebKit/Source/platform/scroll/ScrollableArea.h

Issue 2832883003: Remove unneeded Convert* methods and move many from FrameViewBase to FrameView (Closed)
Patch Set: fix ScrollableArea::ConvertFromScrollbarToContainingFrameViewBase and remove dchecks Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/platform/scroll/ScrollableArea.h
diff --git a/third_party/WebKit/Source/platform/scroll/ScrollableArea.h b/third_party/WebKit/Source/platform/scroll/ScrollableArea.h
index 03ba7c48dabf4fe8e069a4bbea0e6d2149630b58..40eb97c745918efc5318f416f04dd445e1ef3ba5 100644
--- a/third_party/WebKit/Source/platform/scroll/ScrollableArea.h
+++ b/third_party/WebKit/Source/platform/scroll/ScrollableArea.h
@@ -184,28 +184,22 @@ class PLATFORM_EXPORT ScrollableArea : public GarbageCollectedMixin,
virtual IntRect ConvertFromScrollbarToContainingFrameViewBase(
const Scrollbar& scrollbar,
const IntRect& scrollbar_rect) const {
- return scrollbar.FrameViewBase::ConvertToContainingFrameViewBase(
- scrollbar_rect);
+ IntRect local_rect = scrollbar_rect;
+ local_rect.MoveBy(scrollbar.Location());
+ return local_rect;
}
- virtual IntRect ConvertFromContainingFrameViewBaseToScrollbar(
+ virtual IntPoint ConvertFromContainingFrameViewBaseToScrollbar(
const Scrollbar& scrollbar,
- const IntRect& parent_rect) const {
- return scrollbar.FrameViewBase::ConvertFromContainingFrameViewBase(
- parent_rect);
+ const IntPoint& parent_point) const {
+ NOTREACHED();
+ return parent_point;
}
virtual IntPoint ConvertFromScrollbarToContainingFrameViewBase(
const Scrollbar& scrollbar,
const IntPoint& scrollbar_point) const {
- return scrollbar.FrameViewBase::ConvertToContainingFrameViewBase(
- scrollbar_point);
+ NOTREACHED();
+ return scrollbar_point;
}
- virtual IntPoint ConvertFromContainingFrameViewBaseToScrollbar(
- const Scrollbar& scrollbar,
- const IntPoint& parent_point) const {
- return scrollbar.FrameViewBase::ConvertFromContainingFrameViewBase(
- parent_point);
- }
-
virtual Scrollbar* HorizontalScrollbar() const { return nullptr; }
virtual Scrollbar* VerticalScrollbar() const { return nullptr; }
« no previous file with comments | « third_party/WebKit/Source/platform/FrameViewBase.cpp ('k') | third_party/WebKit/Source/platform/scroll/Scrollbar.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698