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

Side by Side Diff: components/contextual_search/contextual_search_api_service_impl.cc

Issue 1385663002: [Contextual Search] Add Mojo-enabled API component. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Reworked to use a new Contextual Search component and Mojo communication, removed CS Manager stuff. Created 5 years, 1 month 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
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "components/contextual_search/contextual_search_api_service_impl.h"
6
7 #include "components/contextual_search/contextual_search_ui_handle.h"
8
9 namespace contextual_search {
10
11 ContextualSearchApiServiceImpl::ContextualSearchApiServiceImpl(
12 ContextualSearchUIHandle* contextual_search_ui_handle,
13 mojo::InterfaceRequest<ContextualSearchApiService> request)
14 : binding_(this, request.Pass()),
15 contextual_search_ui_handle_(contextual_search_ui_handle) {}
16
17 ContextualSearchApiServiceImpl::~ContextualSearchApiServiceImpl() {}
18
19 void ContextualSearchApiServiceImpl::HandleSetCaption(
20 const mojo::String& caption) {
21 contextual_search_ui_handle_->SetCaption(caption);
22 }
23
24 // static
25 void CreateContextualSearchApiService(
26 ContextualSearchUIHandle* contextual_search_ui_handle,
27 mojo::InterfaceRequest<ContextualSearchApiService> request) {
28 // This is strongly bound and owned by the pipe.
29 new ContextualSearchApiServiceImpl(contextual_search_ui_handle,
30 request.Pass());
31 }
32
33 } // namespace contextual_search
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698