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

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

Issue 3201008: Revert 57094 - Making window.focus()/blur() work only when there is a user ge... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years, 4 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
« no previous file with comments | « chrome/browser/sidebar/sidebar_container.h ('k') | chrome/browser/tab_contents/tab_contents.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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/match_preview.h" 5 #include "chrome/browser/tab_contents/match_preview.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "chrome/browser/tab_contents/navigation_controller.h" 10 #include "chrome/browser/tab_contents/navigation_controller.h"
(...skipping 19 matching lines...) Expand all
30 virtual void NavigationStateChanged(const TabContents* source, 30 virtual void NavigationStateChanged(const TabContents* source,
31 unsigned changed_flags) {} 31 unsigned changed_flags) {}
32 virtual void AddNewContents(TabContents* source, 32 virtual void AddNewContents(TabContents* source,
33 TabContents* new_contents, 33 TabContents* new_contents,
34 WindowOpenDisposition disposition, 34 WindowOpenDisposition disposition,
35 const gfx::Rect& initial_pos, 35 const gfx::Rect& initial_pos,
36 bool user_gesture) {} 36 bool user_gesture) {}
37 virtual void ActivateContents(TabContents* contents) { 37 virtual void ActivateContents(TabContents* contents) {
38 match_preview_->CommitCurrentPreview(); 38 match_preview_->CommitCurrentPreview();
39 } 39 }
40 virtual void DeactivateContents(TabContents* contents) {}
41 virtual void LoadingStateChanged(TabContents* source) {} 40 virtual void LoadingStateChanged(TabContents* source) {}
42 virtual void CloseContents(TabContents* source) {} 41 virtual void CloseContents(TabContents* source) {}
43 virtual void MoveContents(TabContents* source, const gfx::Rect& pos) {} 42 virtual void MoveContents(TabContents* source, const gfx::Rect& pos) {}
44 virtual void DetachContents(TabContents* source) {} 43 virtual void DetachContents(TabContents* source) {}
45 virtual bool IsPopup(const TabContents* source) const { 44 virtual bool IsPopup(const TabContents* source) const {
46 return false; 45 return false;
47 } 46 }
48 virtual TabContents* GetConstrainingContents(TabContents* source) { 47 virtual TabContents* GetConstrainingContents(TabContents* source) {
49 return NULL; 48 return NULL;
50 } 49 }
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
183 void MatchPreview::CommitCurrentPreview() { 182 void MatchPreview::CommitCurrentPreview() {
184 DCHECK(preview_contents_.get()); 183 DCHECK(preview_contents_.get());
185 if (host_->delegate()) 184 if (host_->delegate())
186 host_->delegate()->CommitMatchPreview(host_); 185 host_->delegate()->CommitMatchPreview(host_);
187 } 186 }
188 187
189 TabContents* MatchPreview::ReleasePreviewContents() { 188 TabContents* MatchPreview::ReleasePreviewContents() {
190 url_ = GURL(); 189 url_ = GURL();
191 return preview_contents_.release(); 190 return preview_contents_.release();
192 } 191 }
OLDNEW
« no previous file with comments | « chrome/browser/sidebar/sidebar_container.h ('k') | chrome/browser/tab_contents/tab_contents.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698