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

Side by Side Diff: chrome/browser/automation/automation_provider_win.cc

Issue 3210007: Add support for a "split" incognito behavior for extensions. (Closed)
Patch Set: latest Created 10 years, 3 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 | « chrome/app/generated_resources.grd ('k') | chrome/browser/browser.cc » ('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) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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/automation/automation_provider.h" 5 #include "chrome/browser/automation/automation_provider.h"
6 6
7 #include "base/json/json_reader.h" 7 #include "base/json/json_reader.h"
8 #include "base/keyboard_codes.h" 8 #include "base/keyboard_codes.h"
9 #include "base/trace_event.h" 9 #include "base/trace_event.h"
10 #include "base/utf_string_conversions.h" 10 #include "base/utf_string_conversions.h"
(...skipping 469 matching lines...) Expand 10 before | Expand all | Expand 10 after
480 } 480 }
481 481
482 std::string json_args; 482 std::string json_args;
483 if (!args->GetString(1, &json_args)) { 483 if (!args->GetString(1, &json_args)) {
484 LOG(WARNING) << "No browser event args specified through automation"; 484 LOG(WARNING) << "No browser event args specified through automation";
485 return false; 485 return false;
486 } 486 }
487 487
488 if (profile()->GetExtensionMessageService()) { 488 if (profile()->GetExtensionMessageService()) {
489 profile()->GetExtensionMessageService()->DispatchEventToRenderers( 489 profile()->GetExtensionMessageService()->DispatchEventToRenderers(
490 event_name, json_args, profile()->IsOffTheRecord(), GURL()); 490 event_name, json_args, profile(), GURL());
491 } 491 }
492 492
493 return true; 493 return true;
494 } 494 }
495 495
496 void AutomationProvider::NavigateInExternalTab( 496 void AutomationProvider::NavigateInExternalTab(
497 int handle, const GURL& url, const GURL& referrer, 497 int handle, const GURL& url, const GURL& referrer,
498 AutomationMsg_NavigationResponseValues* status) { 498 AutomationMsg_NavigationResponseValues* status) {
499 *status = AUTOMATION_MSG_NAVIGATION_ERROR; 499 *status = AUTOMATION_MSG_NAVIGATION_ERROR;
500 500
(...skipping 27 matching lines...) Expand all
528 528
529 void AutomationProvider::OnSetZoomLevel(int handle, int zoom_level) { 529 void AutomationProvider::OnSetZoomLevel(int handle, int zoom_level) {
530 if (tab_tracker_->ContainsHandle(handle)) { 530 if (tab_tracker_->ContainsHandle(handle)) {
531 NavigationController* tab = tab_tracker_->GetResource(handle); 531 NavigationController* tab = tab_tracker_->GetResource(handle);
532 if (tab->tab_contents() && tab->tab_contents()->render_view_host()) { 532 if (tab->tab_contents() && tab->tab_contents()->render_view_host()) {
533 tab->tab_contents()->render_view_host()->Zoom( 533 tab->tab_contents()->render_view_host()->Zoom(
534 static_cast<PageZoom::Function>(zoom_level)); 534 static_cast<PageZoom::Function>(zoom_level));
535 } 535 }
536 } 536 }
537 } 537 }
OLDNEW
« no previous file with comments | « chrome/app/generated_resources.grd ('k') | chrome/browser/browser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698