| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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/child/blink_platform_impl.h" | 5 #include "content/child/blink_platform_impl.h" |
| 6 | 6 |
| 7 #include <math.h> | 7 #include <math.h> |
| 8 | 8 |
| 9 #include <memory> | 9 #include <memory> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 776 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 787 void BlinkPlatformImpl::bindServiceConnector( | 787 void BlinkPlatformImpl::bindServiceConnector( |
| 788 mojo::ScopedMessagePipeHandle remote_handle) { | 788 mojo::ScopedMessagePipeHandle remote_handle) { |
| 789 if (!ChildThreadImpl::current()) | 789 if (!ChildThreadImpl::current()) |
| 790 return; | 790 return; |
| 791 | 791 |
| 792 service_manager::mojom::ConnectorRequest chromium_request; | 792 service_manager::mojom::ConnectorRequest chromium_request; |
| 793 chromium_request.Bind(std::move(remote_handle)); | 793 chromium_request.Bind(std::move(remote_handle)); |
| 794 ChildThreadImpl::current() | 794 ChildThreadImpl::current() |
| 795 ->GetServiceManagerConnection() | 795 ->GetServiceManagerConnection() |
| 796 ->GetConnector() | 796 ->GetConnector() |
| 797 ->BindRequest(std::move(chromium_request)); | 797 ->BindConnectorRequest(std::move(chromium_request)); |
| 798 } | 798 } |
| 799 | 799 |
| 800 size_t BlinkPlatformImpl::actualMemoryUsageMB() { | 800 size_t BlinkPlatformImpl::actualMemoryUsageMB() { |
| 801 return GetMemoryUsageKB() >> 10; | 801 return GetMemoryUsageKB() >> 10; |
| 802 } | 802 } |
| 803 | 803 |
| 804 size_t BlinkPlatformImpl::numberOfProcessors() { | 804 size_t BlinkPlatformImpl::numberOfProcessors() { |
| 805 return static_cast<size_t>(base::SysInfo::NumberOfProcessors()); | 805 return static_cast<size_t>(base::SysInfo::NumberOfProcessors()); |
| 806 } | 806 } |
| 807 | 807 |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 850 return WebString::fromUTF8(ui::KeycodeConverter::DomKeyToKeyString( | 850 return WebString::fromUTF8(ui::KeycodeConverter::DomKeyToKeyString( |
| 851 static_cast<ui::DomKey>(dom_key))); | 851 static_cast<ui::DomKey>(dom_key))); |
| 852 } | 852 } |
| 853 | 853 |
| 854 int BlinkPlatformImpl::domKeyEnumFromString(const WebString& key_string) { | 854 int BlinkPlatformImpl::domKeyEnumFromString(const WebString& key_string) { |
| 855 return static_cast<int>( | 855 return static_cast<int>( |
| 856 ui::KeycodeConverter::KeyStringToDomKey(key_string.utf8())); | 856 ui::KeycodeConverter::KeyStringToDomKey(key_string.utf8())); |
| 857 } | 857 } |
| 858 | 858 |
| 859 } // namespace content | 859 } // namespace content |
| OLD | NEW |