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

Side by Side Diff: mandoline/ui/omnibox/omnibox_impl.cc

Issue 1135933003: Get the omnibox to show up again. Sky's changes from yesterday removed the window manager interface… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 5 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 | « mandoline/ui/omnibox/omnibox_impl.h ('k') | no next file » | 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 "mandoline/ui/omnibox/omnibox_impl.h" 5 #include "mandoline/ui/omnibox/omnibox_impl.h"
6 6
7 #include "base/strings/string16.h" 7 #include "base/strings/string16.h"
8 #include "components/view_manager/public/cpp/view_manager_client_factory.h" 8 #include "components/view_manager/public/cpp/view_manager_client_factory.h"
9 #include "mandoline/ui/aura/aura_init.h" 9 #include "mandoline/ui/aura/aura_init.h"
10 #include "mandoline/ui/aura/native_widget_view_manager.h" 10 #include "mandoline/ui/aura/native_widget_view_manager.h"
(...skipping 21 matching lines...) Expand all
32 void OmniboxImpl::Initialize(mojo::ApplicationImpl* app) { 32 void OmniboxImpl::Initialize(mojo::ApplicationImpl* app) {
33 app_impl_ = app; 33 app_impl_ = app;
34 view_manager_client_factory_.reset( 34 view_manager_client_factory_.reset(
35 new mojo::ViewManagerClientFactory(app->shell(), this)); 35 new mojo::ViewManagerClientFactory(app->shell(), this));
36 } 36 }
37 37
38 bool OmniboxImpl::ConfigureIncomingConnection( 38 bool OmniboxImpl::ConfigureIncomingConnection(
39 mojo::ApplicationConnection* connection) { 39 mojo::ApplicationConnection* connection) {
40 connection->AddService<Omnibox>(this); 40 connection->AddService<Omnibox>(this);
41 connection->AddService(view_manager_client_factory_.get()); 41 connection->AddService(view_manager_client_factory_.get());
42 connection->ConnectToService(&view_embedder_);
42 return true; 43 return true;
43 } 44 }
44 45
45 bool OmniboxImpl::ConfigureOutgoingConnection( 46 bool OmniboxImpl::ConfigureOutgoingConnection(
46 mojo::ApplicationConnection* connection) { 47 mojo::ApplicationConnection* connection) {
47 return true; 48 return true;
48 } 49 }
49 50
50 //////////////////////////////////////////////////////////////////////////////// 51 ////////////////////////////////////////////////////////////////////////////////
51 // OmniboxImpl, mojo::ViewManagerDelegate implementation: 52 // OmniboxImpl, mojo::ViewManagerDelegate implementation:
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
127 128
128 //////////////////////////////////////////////////////////////////////////////// 129 ////////////////////////////////////////////////////////////////////////////////
129 // OmniboxImpl, Omnibox implementation: 130 // OmniboxImpl, Omnibox implementation:
130 131
131 void OmniboxImpl::SetClient(OmniboxClientPtr client) { 132 void OmniboxImpl::SetClient(OmniboxClientPtr client) {
132 client_ = client.Pass(); 133 client_ = client.Pass();
133 } 134 }
134 135
135 void OmniboxImpl::ShowForURL(const mojo::String& url) { 136 void OmniboxImpl::ShowForURL(const mojo::String& url) {
136 url_ = url; 137 url_ = url;
137 // TODO: get embedding working. 138
139 view_embedder_->Embed("mojo:omnibox", nullptr, nullptr);
138 } 140 }
139 141
140 } // namespace mandoline 142 } // namespace mandoline
OLDNEW
« no previous file with comments | « mandoline/ui/omnibox/omnibox_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698