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

Side by Side Diff: chrome/browser/tab_contents/interstitial_page.cc

Issue 235039: Fix conflicts between accelerator keys and HTML DOM accesskeys.... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 2 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 "chrome/browser/tab_contents/interstitial_page.h" 5 #include "chrome/browser/tab_contents/interstitial_page.h"
6 6
7 #include "base/compiler_specific.h" 7 #include "base/compiler_specific.h"
8 #include "base/message_loop.h" 8 #include "base/message_loop.h"
9 #include "base/string_util.h" 9 #include "base/string_util.h"
10 #include "base/thread.h" 10 #include "base/thread.h"
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 const GURL& creator_url); 90 const GURL& creator_url);
91 virtual void ShowCreatedWidget(int route_id, 91 virtual void ShowCreatedWidget(int route_id,
92 const gfx::Rect& initial_pos); 92 const gfx::Rect& initial_pos);
93 virtual void ShowContextMenu(const ContextMenuParams& params); 93 virtual void ShowContextMenu(const ContextMenuParams& params);
94 virtual void StartDragging(const WebDropData& drop_data, 94 virtual void StartDragging(const WebDropData& drop_data,
95 WebDragOperationsMask operations_allowed); 95 WebDragOperationsMask operations_allowed);
96 virtual void UpdateDragCursor(WebDragOperation operation); 96 virtual void UpdateDragCursor(WebDragOperation operation);
97 virtual void GotFocus(); 97 virtual void GotFocus();
98 virtual void TakeFocus(bool reverse); 98 virtual void TakeFocus(bool reverse);
99 virtual bool IsReservedAccelerator(const NativeWebKeyboardEvent& event); 99 virtual bool IsReservedAccelerator(const NativeWebKeyboardEvent& event);
100 virtual void HandleKeyboardEvent(const NativeWebKeyboardEvent& event); 100 virtual bool HandleKeyboardEvent(const NativeWebKeyboardEvent& event);
101 virtual void HandleMouseEvent(); 101 virtual void HandleMouseEvent();
102 virtual void HandleMouseLeave(); 102 virtual void HandleMouseLeave();
103 virtual void OnFindReply(int request_id, 103 virtual void OnFindReply(int request_id,
104 int number_of_matches, 104 int number_of_matches,
105 const gfx::Rect& selection_rect, 105 const gfx::Rect& selection_rect,
106 int active_match_ordinal, 106 int active_match_ordinal,
107 bool final_update); 107 bool final_update);
108 virtual void UpdatePreferredSize(const gfx::Size& pref_size); 108 virtual void UpdatePreferredSize(const gfx::Size& pref_size);
109 109
110 private: 110 private:
(...skipping 466 matching lines...) Expand 10 before | Expand all | Expand 10 after
577 bool reverse) { 577 bool reverse) {
578 if (interstitial_page_->tab() && interstitial_page_->tab()->GetViewDelegate()) 578 if (interstitial_page_->tab() && interstitial_page_->tab()->GetViewDelegate())
579 interstitial_page_->tab()->GetViewDelegate()->TakeFocus(reverse); 579 interstitial_page_->tab()->GetViewDelegate()->TakeFocus(reverse);
580 } 580 }
581 581
582 bool InterstitialPage::InterstitialPageRVHViewDelegate::IsReservedAccelerator( 582 bool InterstitialPage::InterstitialPageRVHViewDelegate::IsReservedAccelerator(
583 const NativeWebKeyboardEvent& event) { 583 const NativeWebKeyboardEvent& event) {
584 return false; 584 return false;
585 } 585 }
586 586
587 void InterstitialPage::InterstitialPageRVHViewDelegate::HandleKeyboardEvent( 587 bool InterstitialPage::InterstitialPageRVHViewDelegate::HandleKeyboardEvent(
588 const NativeWebKeyboardEvent& event) { 588 const NativeWebKeyboardEvent& event) {
589 if (interstitial_page_->tab() && interstitial_page_->tab()->GetViewDelegate()) 589 if (interstitial_page_->tab() && interstitial_page_->tab()->GetViewDelegate())
590 interstitial_page_->tab()->GetViewDelegate()->HandleKeyboardEvent(event); 590 return interstitial_page_->tab()->GetViewDelegate()->
591 HandleKeyboardEvent(event);
592 return false;
591 } 593 }
592 594
593 void InterstitialPage::InterstitialPageRVHViewDelegate::HandleMouseEvent() { 595 void InterstitialPage::InterstitialPageRVHViewDelegate::HandleMouseEvent() {
594 if (interstitial_page_->tab() && interstitial_page_->tab()->GetViewDelegate()) 596 if (interstitial_page_->tab() && interstitial_page_->tab()->GetViewDelegate())
595 interstitial_page_->tab()->GetViewDelegate()->HandleMouseEvent(); 597 interstitial_page_->tab()->GetViewDelegate()->HandleMouseEvent();
596 } 598 }
597 599
598 void InterstitialPage::InterstitialPageRVHViewDelegate::HandleMouseLeave() { 600 void InterstitialPage::InterstitialPageRVHViewDelegate::HandleMouseLeave() {
599 if (interstitial_page_->tab() && interstitial_page_->tab()->GetViewDelegate()) 601 if (interstitial_page_->tab() && interstitial_page_->tab()->GetViewDelegate())
600 interstitial_page_->tab()->GetViewDelegate()->HandleMouseLeave(); 602 interstitial_page_->tab()->GetViewDelegate()->HandleMouseLeave();
601 } 603 }
602 604
603 void InterstitialPage::InterstitialPageRVHViewDelegate::OnFindReply( 605 void InterstitialPage::InterstitialPageRVHViewDelegate::OnFindReply(
604 int request_id, int number_of_matches, const gfx::Rect& selection_rect, 606 int request_id, int number_of_matches, const gfx::Rect& selection_rect,
605 int active_match_ordinal, bool final_update) { 607 int active_match_ordinal, bool final_update) {
606 } 608 }
607 609
608 int InterstitialPage::GetBrowserWindowID() const { 610 int InterstitialPage::GetBrowserWindowID() const {
609 return tab_->GetBrowserWindowID(); 611 return tab_->GetBrowserWindowID();
610 } 612 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698