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

Side by Side Diff: content/browser/web_contents/interstitial_page_impl.cc

Issue 11269022: Add Vector2d classes that represent offsets, instead of using Point. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: RenderText fixup Created 8 years, 1 month 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/web_contents/interstitial_page_impl.h" 5 #include "content/browser/web_contents/interstitial_page_impl.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 virtual void ShowPopupMenu(const gfx::Rect& bounds, 75 virtual void ShowPopupMenu(const gfx::Rect& bounds,
76 int item_height, 76 int item_height,
77 double item_font_size, 77 double item_font_size,
78 int selected_item, 78 int selected_item,
79 const std::vector<WebMenuItem>& items, 79 const std::vector<WebMenuItem>& items,
80 bool right_aligned, 80 bool right_aligned,
81 bool allow_multiple_selection) OVERRIDE; 81 bool allow_multiple_selection) OVERRIDE;
82 virtual void StartDragging(const WebDropData& drop_data, 82 virtual void StartDragging(const WebDropData& drop_data,
83 WebDragOperationsMask operations_allowed, 83 WebDragOperationsMask operations_allowed,
84 const gfx::ImageSkia& image, 84 const gfx::ImageSkia& image,
85 const gfx::Point& image_offset) OVERRIDE; 85 const gfx::Vector2d& image_offset) OVERRIDE;
86 virtual void UpdateDragCursor(WebDragOperation operation) OVERRIDE; 86 virtual void UpdateDragCursor(WebDragOperation operation) OVERRIDE;
87 virtual void GotFocus() OVERRIDE; 87 virtual void GotFocus() OVERRIDE;
88 virtual void TakeFocus(bool reverse) OVERRIDE; 88 virtual void TakeFocus(bool reverse) OVERRIDE;
89 virtual void OnFindReply(int request_id, 89 virtual void OnFindReply(int request_id,
90 int number_of_matches, 90 int number_of_matches,
91 const gfx::Rect& selection_rect, 91 const gfx::Rect& selection_rect,
92 int active_match_ordinal, 92 int active_match_ordinal,
93 bool final_update); 93 bool final_update);
94 94
95 private: 95 private:
(...skipping 606 matching lines...) Expand 10 before | Expand all | Expand 10 after
702 const std::vector<WebMenuItem>& items, 702 const std::vector<WebMenuItem>& items,
703 bool right_aligned, 703 bool right_aligned,
704 bool allow_multiple_selection) { 704 bool allow_multiple_selection) {
705 NOTREACHED() << "InterstitialPage does not support showing popup menus."; 705 NOTREACHED() << "InterstitialPage does not support showing popup menus.";
706 } 706 }
707 707
708 void InterstitialPageImpl::InterstitialPageRVHDelegateView::StartDragging( 708 void InterstitialPageImpl::InterstitialPageRVHDelegateView::StartDragging(
709 const WebDropData& drop_data, 709 const WebDropData& drop_data,
710 WebDragOperationsMask allowed_operations, 710 WebDragOperationsMask allowed_operations,
711 const gfx::ImageSkia& image, 711 const gfx::ImageSkia& image,
712 const gfx::Point& image_offset) { 712 const gfx::Vector2d& image_offset) {
713 NOTREACHED() << "InterstitialPage does not support dragging yet."; 713 NOTREACHED() << "InterstitialPage does not support dragging yet.";
714 } 714 }
715 715
716 void InterstitialPageImpl::InterstitialPageRVHDelegateView::UpdateDragCursor( 716 void InterstitialPageImpl::InterstitialPageRVHDelegateView::UpdateDragCursor(
717 WebDragOperation) { 717 WebDragOperation) {
718 NOTREACHED() << "InterstitialPage does not support dragging yet."; 718 NOTREACHED() << "InterstitialPage does not support dragging yet.";
719 } 719 }
720 720
721 void InterstitialPageImpl::InterstitialPageRVHDelegateView::GotFocus() { 721 void InterstitialPageImpl::InterstitialPageRVHDelegateView::GotFocus() {
722 } 722 }
723 723
724 void InterstitialPageImpl::InterstitialPageRVHDelegateView::TakeFocus( 724 void InterstitialPageImpl::InterstitialPageRVHDelegateView::TakeFocus(
725 bool reverse) { 725 bool reverse) {
726 if (!interstitial_page_->web_contents()) 726 if (!interstitial_page_->web_contents())
727 return; 727 return;
728 WebContentsImpl* web_contents = 728 WebContentsImpl* web_contents =
729 static_cast<WebContentsImpl*>(interstitial_page_->web_contents()); 729 static_cast<WebContentsImpl*>(interstitial_page_->web_contents());
730 if (!web_contents->GetDelegateView()) 730 if (!web_contents->GetDelegateView())
731 return; 731 return;
732 732
733 web_contents->GetDelegateView()->TakeFocus(reverse); 733 web_contents->GetDelegateView()->TakeFocus(reverse);
734 } 734 }
735 735
736 void InterstitialPageImpl::InterstitialPageRVHDelegateView::OnFindReply( 736 void InterstitialPageImpl::InterstitialPageRVHDelegateView::OnFindReply(
737 int request_id, int number_of_matches, const gfx::Rect& selection_rect, 737 int request_id, int number_of_matches, const gfx::Rect& selection_rect,
738 int active_match_ordinal, bool final_update) { 738 int active_match_ordinal, bool final_update) {
739 } 739 }
740 740
741 } // namespace content 741 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698