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

Side by Side Diff: ios/web/webui/mojo_facade.mm

Issue 2666093002: Remove base::FundamentalValue (Closed)
Patch Set: Rebase Created 3 years, 9 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 | « ios/web/web_state/ui/web_view_js_utils.mm ('k') | ipc/ipc_message_unittest.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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #import "ios/web/webui/mojo_facade.h" 5 #import "ios/web/webui/mojo_facade.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #import <Foundation/Foundation.h> 9 #import <Foundation/Foundation.h>
10 10
(...skipping 14 matching lines...) Expand all
25 #endif 25 #endif
26 26
27 namespace web { 27 namespace web {
28 28
29 namespace { 29 namespace {
30 30
31 // Wraps an integer into |base::Value| as |Type::INTEGER|. 31 // Wraps an integer into |base::Value| as |Type::INTEGER|.
32 template <typename IntegerT> 32 template <typename IntegerT>
33 std::unique_ptr<base::Value> ValueFromInteger(IntegerT handle) { 33 std::unique_ptr<base::Value> ValueFromInteger(IntegerT handle) {
34 return std::unique_ptr<base::Value>( 34 return std::unique_ptr<base::Value>(
35 new base::FundamentalValue(static_cast<int>(handle))); 35 new base::Value(static_cast<int>(handle)));
36 } 36 }
37 37
38 } // namespace 38 } // namespace
39 39
40 MojoFacade::MojoFacade( 40 MojoFacade::MojoFacade(
41 service_manager::mojom::InterfaceProvider* interface_provider, 41 service_manager::mojom::InterfaceProvider* interface_provider,
42 id<CRWJSInjectionEvaluator> script_evaluator) 42 id<CRWJSInjectionEvaluator> script_evaluator)
43 : interface_provider_(interface_provider), 43 : interface_provider_(interface_provider),
44 script_evaluator_(script_evaluator) { 44 script_evaluator_(script_evaluator) {
45 DCHECK_CURRENTLY_ON(WebThread::UI); 45 DCHECK_CURRENTLY_ON(WebThread::UI);
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after
267 267
268 std::unique_ptr<base::Value> MojoFacade::HandleSupportCancelWatch( 268 std::unique_ptr<base::Value> MojoFacade::HandleSupportCancelWatch(
269 const base::DictionaryValue* args) { 269 const base::DictionaryValue* args) {
270 int watch_id = 0; 270 int watch_id = 0;
271 CHECK(args->GetInteger("watchId", &watch_id)); 271 CHECK(args->GetInteger("watchId", &watch_id));
272 watchers_.erase(watch_id); 272 watchers_.erase(watch_id);
273 return nullptr; 273 return nullptr;
274 } 274 }
275 275
276 } // namespace web 276 } // namespace web
OLDNEW
« no previous file with comments | « ios/web/web_state/ui/web_view_js_utils.mm ('k') | ipc/ipc_message_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698