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

Side by Side Diff: content/shell/browser/shell.cc

Issue 1345343003: Remove lots of old blur plumbing. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase. Created 5 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
« no previous file with comments | « content/shell/browser/shell.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/shell/browser/shell.h" 5 #include "content/shell/browser/shell.h"
6 6
7 #include "base/auto_reset.h" 7 #include "base/auto_reset.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/location.h" 9 #include "base/location.h"
10 #include "base/single_thread_task_runner.h" 10 #include "base/single_thread_task_runner.h"
(...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after
395 if (!base::CommandLine::ForCurrentProcess()->HasSwitch( 395 if (!base::CommandLine::ForCurrentProcess()->HasSwitch(
396 switches::kRunLayoutTest)) 396 switches::kRunLayoutTest))
397 return; 397 return;
398 BlinkTestController::Get()->RendererUnresponsive(); 398 BlinkTestController::Get()->RendererUnresponsive();
399 } 399 }
400 400
401 void Shell::ActivateContents(WebContents* contents) { 401 void Shell::ActivateContents(WebContents* contents) {
402 contents->GetRenderViewHost()->GetWidget()->Focus(); 402 contents->GetRenderViewHost()->GetWidget()->Focus();
403 } 403 }
404 404
405 void Shell::DeactivateContents(WebContents* contents) {
406 contents->GetRenderViewHost()->GetWidget()->Blur();
407 }
408
409 bool Shell::HandleContextMenu(const content::ContextMenuParams& params) { 405 bool Shell::HandleContextMenu(const content::ContextMenuParams& params) {
410 return PlatformHandleContextMenu(params); 406 return PlatformHandleContextMenu(params);
411 } 407 }
412 408
413 gfx::Size Shell::GetShellDefaultSize() { 409 gfx::Size Shell::GetShellDefaultSize() {
414 static gfx::Size default_shell_size; 410 static gfx::Size default_shell_size;
415 if (!default_shell_size.IsEmpty()) 411 if (!default_shell_size.IsEmpty())
416 return default_shell_size; 412 return default_shell_size;
417 base::CommandLine* command_line = base::CommandLine::ForCurrentProcess(); 413 base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
418 if (command_line->HasSwitch(switches::kContentShellHostWindowSize)) { 414 if (command_line->HasSwitch(switches::kContentShellHostWindowSize)) {
(...skipping 24 matching lines...) Expand all
443 devtools_frontend_->Activate(); 439 devtools_frontend_->Activate();
444 devtools_frontend_->Focus(); 440 devtools_frontend_->Focus();
445 } 441 }
446 442
447 void Shell::OnDevToolsWebContentsDestroyed() { 443 void Shell::OnDevToolsWebContentsDestroyed() {
448 devtools_observer_.reset(); 444 devtools_observer_.reset();
449 devtools_frontend_ = NULL; 445 devtools_frontend_ = NULL;
450 } 446 }
451 447
452 } // namespace content 448 } // namespace content
OLDNEW
« no previous file with comments | « content/shell/browser/shell.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698