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

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

Issue 11434074: browser: Move FindBrowserWithWebContents() into chrome namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years 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 "chrome/browser/tab_contents/web_drag_bookmark_handler_aura.h" 5 #include "chrome/browser/tab_contents/web_drag_bookmark_handler_aura.h"
6 6
7 #include "chrome/browser/bookmarks/bookmark_node_data.h" 7 #include "chrome/browser/bookmarks/bookmark_node_data.h"
8 #include "chrome/browser/ui/browser.h" 8 #include "chrome/browser/ui/browser.h"
9 #include "chrome/browser/ui/browser_finder.h" 9 #include "chrome/browser/ui/browser_finder.h"
10 #include "chrome/browser/ui/browser_window.h" 10 #include "chrome/browser/ui/browser_window.h"
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 void WebDragBookmarkHandlerAura::OnDrop() { 62 void WebDragBookmarkHandlerAura::OnDrop() {
63 if (bookmark_tab_helper_) { 63 if (bookmark_tab_helper_) {
64 if (bookmark_tab_helper_->GetBookmarkDragDelegate()) { 64 if (bookmark_tab_helper_->GetBookmarkDragDelegate()) {
65 if (bookmark_drag_data_.is_valid()) { 65 if (bookmark_drag_data_.is_valid()) {
66 bookmark_tab_helper_->GetBookmarkDragDelegate()->OnDrop( 66 bookmark_tab_helper_->GetBookmarkDragDelegate()->OnDrop(
67 bookmark_drag_data_); 67 bookmark_drag_data_);
68 } 68 }
69 } 69 }
70 70
71 // Focus the target browser. 71 // Focus the target browser.
72 Browser* browser = browser::FindBrowserWithWebContents(web_contents_); 72 Browser* browser = chrome::FindBrowserWithWebContents(web_contents_);
73 if (browser) 73 if (browser)
74 browser->window()->Show(); 74 browser->window()->Show();
75 } 75 }
76 76
77 bookmark_drag_data_.Clear(); 77 bookmark_drag_data_.Clear();
78 } 78 }
79 79
80 void WebDragBookmarkHandlerAura::OnDragLeave() { 80 void WebDragBookmarkHandlerAura::OnDragLeave() {
81 if (bookmark_tab_helper_ && bookmark_tab_helper_->GetBookmarkDragDelegate()) { 81 if (bookmark_tab_helper_ && bookmark_tab_helper_->GetBookmarkDragDelegate()) {
82 if (bookmark_drag_data_.is_valid()) 82 if (bookmark_drag_data_.is_valid())
83 bookmark_tab_helper_->GetBookmarkDragDelegate()->OnDragLeave( 83 bookmark_tab_helper_->GetBookmarkDragDelegate()->OnDragLeave(
84 bookmark_drag_data_); 84 bookmark_drag_data_);
85 } 85 }
86 86
87 bookmark_drag_data_.Clear(); 87 bookmark_drag_data_.Clear();
88 } 88 }
OLDNEW
« no previous file with comments | « chrome/browser/tab_contents/render_view_context_menu.cc ('k') | chrome/browser/tab_contents/web_drag_bookmark_handler_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698