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

Side by Side Diff: components/html_viewer/global_state.cc

Issue 1406153004: components/mus/public/interfaces View => Window (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Yet another rebase Created 5 years, 2 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 | « components/html_viewer/global_state.h ('k') | components/html_viewer/html_document.h » ('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 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 "components/html_viewer/global_state.h" 5 #include "components/html_viewer/global_state.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
168 new MediaFactory(compositor_thread_.task_runner(), app_->shell())); 168 new MediaFactory(compositor_thread_.task_runner(), app_->shell()));
169 169
170 if (command_line->HasSwitch(kJavaScriptFlags)) { 170 if (command_line->HasSwitch(kJavaScriptFlags)) {
171 std::string flags(command_line->GetSwitchValueASCII(kJavaScriptFlags)); 171 std::string flags(command_line->GetSwitchValueASCII(kJavaScriptFlags));
172 v8::V8::SetFlagsFromString(flags.c_str(), static_cast<int>(flags.size())); 172 v8::V8::SetFlagsFromString(flags.c_str(), static_cast<int>(flags.size()));
173 } 173 }
174 } 174 }
175 175
176 // TODO(rjkroege): These two functions probably do not interoperate correctly 176 // TODO(rjkroege): These two functions probably do not interoperate correctly
177 // with MUS. 177 // with MUS.
178 const mojo::GpuInfo* GlobalState::GetGpuInfo() { 178 const mus::mojom::GpuInfo* GlobalState::GetGpuInfo() {
179 if (gpu_service_) 179 if (gpu_service_)
180 CHECK(gpu_service_.WaitForIncomingResponse()) <<"Get GPU info failed!"; 180 CHECK(gpu_service_.WaitForIncomingResponse()) <<"Get GPU info failed!";
181 return gpu_info_.get(); 181 return gpu_info_.get();
182 } 182 }
183 183
184 void GlobalState::GetGpuInfoCallback(mojo::GpuInfoPtr gpu_info) { 184 void GlobalState::GetGpuInfoCallback(mus::mojom::GpuInfoPtr gpu_info) {
185 CHECK(gpu_info); 185 CHECK(gpu_info);
186 gpu_info_ = gpu_info.Pass(); 186 gpu_info_ = gpu_info.Pass();
187 gpu_service_.reset(); 187 gpu_service_.reset();
188 } 188 }
189 189
190 } // namespace html_viewer 190 } // namespace html_viewer
OLDNEW
« no previous file with comments | « components/html_viewer/global_state.h ('k') | components/html_viewer/html_document.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698