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

Unified Diff: services/ui/gpu/gpu_main.cc

Issue 2338483003: Revert of services/ui: Use new gpu::GpuInit to do the GPU initialization. (Closed)
Patch Set: Created 4 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « services/ui/gpu/gpu_main.h ('k') | services/ui/gpu/gpu_service_internal.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: services/ui/gpu/gpu_main.cc
diff --git a/services/ui/gpu/gpu_main.cc b/services/ui/gpu/gpu_main.cc
deleted file mode 100644
index ae5b4671981bce19280d55e2e5128356a483fc99..0000000000000000000000000000000000000000
--- a/services/ui/gpu/gpu_main.cc
+++ /dev/null
@@ -1,48 +0,0 @@
-// Copyright 2016 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "services/ui/gpu/gpu_main.h"
-
-#include "base/command_line.h"
-#include "gpu/ipc/common/gpu_memory_buffer_support.h"
-#include "gpu/ipc/service/gpu_memory_buffer_factory.h"
-#include "gpu/ipc/service/gpu_watchdog_thread.h"
-#include "services/ui/gpu/gpu_service_internal.h"
-
-namespace ui {
-
-GpuMain::GpuMain() {
- gpu_init_.set_sandbox_helper(this);
- bool success = gpu_init_.InitializeAndStartSandbox(
- *base::CommandLine::ForCurrentProcess());
- if (success) {
- if (gpu::GetNativeGpuMemoryBufferType() != gfx::EMPTY_BUFFER) {
- gpu_memory_buffer_factory_ =
- gpu::GpuMemoryBufferFactory::CreateNativeType();
- }
- gpu_service_internal_.reset(new GpuServiceInternal(
- gpu_init_.gpu_info(), gpu_init_.watchdog_thread(),
- gpu_memory_buffer_factory_.get()));
- }
-}
-
-GpuMain::~GpuMain() {
- gpu_init_.watchdog_thread()->Stop();
-}
-
-void GpuMain::Add(mojom::GpuServiceInternalRequest request) {
- if (gpu_service_internal_)
- gpu_service_internal_->Add(std::move(request));
-}
-
-void GpuMain::PreSandboxStartup() {
- // TODO(sad): https://crbug.com/645602
-}
-
-bool GpuMain::EnsureSandboxInitialized() {
- // TODO(sad): https://crbug.com/645602
- return true;
-}
-
-} // namespace ui
« no previous file with comments | « services/ui/gpu/gpu_main.h ('k') | services/ui/gpu/gpu_service_internal.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698