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

Side by Side Diff: third_party/WebKit/Source/core/frame/LocalFrameView.cpp

Issue 2929493003: Move handling of DraggableRegionsChanged notification from "view" to "frame". (Closed)
Patch Set: Also add main frame filtering to the browser-side. Created 3 years, 6 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org> 2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org>
3 * 1999 Lars Knoll <knoll@kde.org> 3 * 1999 Lars Knoll <knoll@kde.org>
4 * 1999 Antti Koivisto <koivisto@kde.org> 4 * 1999 Antti Koivisto <koivisto@kde.org>
5 * 2000 Dirk Mueller <mueller@kde.org> 5 * 2000 Dirk Mueller <mueller@kde.org>
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved.
7 * (C) 2006 Graham Dennis (graham.dennis@gmail.com) 7 * (C) 2006 Graham Dennis (graham.dennis@gmail.com)
8 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) 8 * (C) 2006 Alexey Proskuryakov (ap@nypop.com)
9 * Copyright (C) 2009 Google Inc. All rights reserved. 9 * Copyright (C) 2009 Google Inc. All rights reserved.
10 * 10 *
(...skipping 2804 matching lines...) Expand 10 before | Expand all | Expand 10 after
2815 2815
2816 void LocalFrameView::UpdateDocumentAnnotatedRegions() const { 2816 void LocalFrameView::UpdateDocumentAnnotatedRegions() const {
2817 Document* document = frame_->GetDocument(); 2817 Document* document = frame_->GetDocument();
2818 if (!document->HasAnnotatedRegions()) 2818 if (!document->HasAnnotatedRegions())
2819 return; 2819 return;
2820 Vector<AnnotatedRegionValue> new_regions; 2820 Vector<AnnotatedRegionValue> new_regions;
2821 CollectAnnotatedRegions(*(document->GetLayoutBox()), new_regions); 2821 CollectAnnotatedRegions(*(document->GetLayoutBox()), new_regions);
2822 if (new_regions == document->AnnotatedRegions()) 2822 if (new_regions == document->AnnotatedRegions())
2823 return; 2823 return;
2824 document->SetAnnotatedRegions(new_regions); 2824 document->SetAnnotatedRegions(new_regions);
2825 if (Page* page = frame_->GetPage()) 2825
2826 page->GetChromeClient().AnnotatedRegionsChanged(); 2826 DCHECK(frame_->Client());
2827 frame_->Client()->AnnotatedRegionsChanged();
2827 } 2828 }
2828 2829
2829 void LocalFrameView::DidAttachDocument() { 2830 void LocalFrameView::DidAttachDocument() {
2830 Page* page = frame_->GetPage(); 2831 Page* page = frame_->GetPage();
2831 DCHECK(page); 2832 DCHECK(page);
2832 2833
2833 DCHECK(frame_->GetDocument()); 2834 DCHECK(frame_->GetDocument());
2834 2835
2835 if (frame_->IsMainFrame()) { 2836 if (frame_->IsMainFrame()) {
2836 ScrollableArea& visual_viewport = frame_->GetPage()->GetVisualViewport(); 2837 ScrollableArea& visual_viewport = frame_->GetPage()->GetVisualViewport();
(...skipping 2561 matching lines...) Expand 10 before | Expand all | Expand 10 after
5398 void LocalFrameView::SetAnimationHost( 5399 void LocalFrameView::SetAnimationHost(
5399 std::unique_ptr<CompositorAnimationHost> host) { 5400 std::unique_ptr<CompositorAnimationHost> host) {
5400 animation_host_ = std::move(host); 5401 animation_host_ = std::move(host);
5401 } 5402 }
5402 5403
5403 LayoutUnit LocalFrameView::CaretWidth() const { 5404 LayoutUnit LocalFrameView::CaretWidth() const {
5404 return LayoutUnit(GetChromeClient()->WindowToViewportScalar(1)); 5405 return LayoutUnit(GetChromeClient()->WindowToViewportScalar(1));
5405 } 5406 }
5406 5407
5407 } // namespace blink 5408 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698