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

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

Issue 10837112: Add WebContents* to some more WebContentsDelegate methods (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased Created 8 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
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/web_contents_view_win.h" 5 #include "content/browser/web_contents/web_contents_view_win.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/memory/scoped_vector.h" 8 #include "base/memory/scoped_vector.h"
9 #include "content/browser/renderer_host/render_view_host_factory.h" 9 #include "content/browser/renderer_host/render_view_host_factory.h"
10 #include "content/browser/renderer_host/render_view_host_impl.h" 10 #include "content/browser/renderer_host/render_view_host_impl.h"
(...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after
296 drag_dest_->set_drag_cursor(operation); 296 drag_dest_->set_drag_cursor(operation);
297 } 297 }
298 298
299 void WebContentsViewWin::GotFocus() { 299 void WebContentsViewWin::GotFocus() {
300 if (web_contents_->GetDelegate()) 300 if (web_contents_->GetDelegate())
301 web_contents_->GetDelegate()->WebContentsFocused(web_contents_); 301 web_contents_->GetDelegate()->WebContentsFocused(web_contents_);
302 } 302 }
303 303
304 void WebContentsViewWin::TakeFocus(bool reverse) { 304 void WebContentsViewWin::TakeFocus(bool reverse) {
305 if (web_contents_->GetDelegate() && 305 if (web_contents_->GetDelegate() &&
306 !web_contents_->GetDelegate()->TakeFocus(reverse) && 306 !web_contents_->GetDelegate()->TakeFocus(web_contents_, reverse) &&
307 delegate_.get()) { 307 delegate_.get()) {
308 delegate_->TakeFocus(reverse); 308 delegate_->TakeFocus(reverse);
309 } 309 }
310 } 310 }
311 311
312 void WebContentsViewWin::EndDragging() { 312 void WebContentsViewWin::EndDragging() {
313 drag_handler_ = NULL; 313 drag_handler_ = NULL;
314 if (close_tab_after_drag_ends_) { 314 if (close_tab_after_drag_ends_) {
315 close_tab_timer_.Start(FROM_HERE, base::TimeDelta::FromMilliseconds(0), 315 close_tab_timer_.Start(FROM_HERE, base::TimeDelta::FromMilliseconds(0),
316 this, &WebContentsViewWin::CloseTab); 316 this, &WebContentsViewWin::CloseTab);
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after
487 si.nMin = 1; 487 si.nMin = 1;
488 si.nMax = 100; 488 si.nMax = 100;
489 si.nPage = 10; 489 si.nPage = 10;
490 si.nPos = 50; 490 si.nPos = 50;
491 491
492 ::SetScrollInfo(hwnd(), SB_HORZ, &si, FALSE); 492 ::SetScrollInfo(hwnd(), SB_HORZ, &si, FALSE);
493 ::SetScrollInfo(hwnd(), SB_VERT, &si, FALSE); 493 ::SetScrollInfo(hwnd(), SB_VERT, &si, FALSE);
494 494
495 return 1; 495 return 1;
496 } 496 }
OLDNEW
« no previous file with comments | « content/browser/web_contents/web_contents_view_gtk.cc ('k') | content/public/browser/web_contents_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698