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

Side by Side Diff: headless/lib/browser/headless_browser_context_impl.cc

Issue 2863953003: Headless: Remove obsolete Mojo code and some other obsolete APIs (Closed)
Patch Set: Rebased Created 3 years, 7 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 | « headless/app/headless_shell.cc ('k') | headless/lib/browser/headless_web_contents_impl.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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "headless/lib/browser/headless_browser_context_impl.h" 5 #include "headless/lib/browser/headless_browser_context_impl.h"
6 6
7 #include <memory> 7 #include <memory>
8 #include <string> 8 #include <string>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 371 matching lines...) Expand 10 before | Expand all | Expand 10 after
382 return *this; 382 return *this;
383 } 383 }
384 384
385 HeadlessBrowserContext::Builder& 385 HeadlessBrowserContext::Builder&
386 HeadlessBrowserContext::Builder::SetIncognitoMode(bool incognito_mode) { 386 HeadlessBrowserContext::Builder::SetIncognitoMode(bool incognito_mode) {
387 options_->incognito_mode_ = incognito_mode; 387 options_->incognito_mode_ = incognito_mode;
388 return *this; 388 return *this;
389 } 389 }
390 390
391 HeadlessBrowserContext::Builder& 391 HeadlessBrowserContext::Builder&
392 HeadlessBrowserContext::Builder::AddJsMojoBindings(
393 const std::string& mojom_name,
394 const std::string& js_bindings) {
395 mojo_bindings_.emplace_back(mojom_name, js_bindings);
396 return *this;
397 }
398
399 HeadlessBrowserContext::Builder&
400 HeadlessBrowserContext::Builder::AddTabSocketMojoBindings() { 392 HeadlessBrowserContext::Builder::AddTabSocketMojoBindings() {
401 std::string js_bindings = 393 std::string js_bindings =
402 ui::ResourceBundle::GetSharedInstance() 394 ui::ResourceBundle::GetSharedInstance()
403 .GetRawDataResource(IDR_HEADLESS_TAB_SOCKET_MOJOM_JS) 395 .GetRawDataResource(IDR_HEADLESS_TAB_SOCKET_MOJOM_JS)
404 .as_string(); 396 .as_string();
405 mojo_bindings_.emplace_back("headless/lib/tab_socket.mojom", js_bindings); 397 mojo_bindings_.emplace_back("headless/lib/tab_socket.mojom", js_bindings);
406 return *this; 398 return *this;
407 } 399 }
408 400
409 HeadlessBrowserContext::Builder& 401 HeadlessBrowserContext::Builder&
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
451 HeadlessBrowserContext::Builder::MojoBindings::MojoBindings() {} 443 HeadlessBrowserContext::Builder::MojoBindings::MojoBindings() {}
452 444
453 HeadlessBrowserContext::Builder::MojoBindings::MojoBindings( 445 HeadlessBrowserContext::Builder::MojoBindings::MojoBindings(
454 const std::string& mojom_name, 446 const std::string& mojom_name,
455 const std::string& js_bindings) 447 const std::string& js_bindings)
456 : mojom_name(mojom_name), js_bindings(js_bindings) {} 448 : mojom_name(mojom_name), js_bindings(js_bindings) {}
457 449
458 HeadlessBrowserContext::Builder::MojoBindings::~MojoBindings() {} 450 HeadlessBrowserContext::Builder::MojoBindings::~MojoBindings() {}
459 451
460 } // namespace headless 452 } // namespace headless
OLDNEW
« no previous file with comments | « headless/app/headless_shell.cc ('k') | headless/lib/browser/headless_web_contents_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698