OLD | NEW |
(Empty) | |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #include "ios/web/shell/shell_web_client.h" |
| 6 |
| 7 #include "ios/web/public/user_agent.h" |
| 8 #include "ios/web/shell/shell_web_main_parts.h" |
| 9 |
| 10 namespace web { |
| 11 |
| 12 ShellWebClient::ShellWebClient() { |
| 13 } |
| 14 |
| 15 ShellWebClient::~ShellWebClient() { |
| 16 } |
| 17 |
| 18 WebMainParts* ShellWebClient::CreateWebMainParts() { |
| 19 web_main_parts_.reset(new ShellWebMainParts); |
| 20 return web_main_parts_.get(); |
| 21 } |
| 22 |
| 23 ShellBrowserState* ShellWebClient::browser_state() const { |
| 24 return web_main_parts_->browser_state(); |
| 25 } |
| 26 |
| 27 std::string ShellWebClient::GetProduct() const { |
| 28 return "CriOS/36.77.34.45"; |
| 29 } |
| 30 |
| 31 std::string ShellWebClient::GetUserAgent(bool desktop_user_agent) const { |
| 32 std::string product = GetProduct(); |
| 33 return web::BuildUserAgentFromProduct(product); |
| 34 } |
| 35 |
| 36 } // namespace web |
OLD | NEW |