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

Unified Diff: shell/android/native_viewport_application_loader.cc

Issue 940293003: Add a Display and ContextProvider concept to mojom, use to recreate (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 10 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
Index: shell/android/native_viewport_application_loader.cc
diff --git a/shell/android/native_viewport_application_loader.cc b/shell/android/native_viewport_application_loader.cc
index 1adf00a95795b8fb3aa2a47b7d38ddb53f758cbe..9cd15371a244ceac2e025e5ff4e86eeed5b5613f 100644
--- a/shell/android/native_viewport_application_loader.cc
+++ b/shell/android/native_viewport_application_loader.cc
@@ -5,6 +5,7 @@
#include "shell/android/native_viewport_application_loader.h"
#include "mojo/public/cpp/application/application_impl.h"
+#include "services/gles2/gpu_state.h"
#include "services/native_viewport/native_viewport_impl.h"
#include "shell/android/keyboard_impl.h"
@@ -35,7 +36,10 @@ bool NativeViewportApplicationLoader::ConfigureIncomingConnection(
void NativeViewportApplicationLoader::Create(
ApplicationConnection* connection,
InterfaceRequest<NativeViewport> request) {
- new native_viewport::NativeViewportImpl(app_.get(), false, request.Pass());
+ if (!gpu_state_)
+ gpu_state_ = new gles2::GpuState;
+ new native_viewport::NativeViewportImpl(app_.get(), gpu_state_,
qsr 2015/03/04 10:33:18 This cuts android head. Or to be less cryptic, th
jamesr 2015/03/04 23:00:27 Ouch! Fixed.
+ request.Pass());
}
void NativeViewportApplicationLoader::Create(
@@ -47,7 +51,7 @@ void NativeViewportApplicationLoader::Create(
void NativeViewportApplicationLoader::Create(ApplicationConnection* connection,
InterfaceRequest<Gpu> request) {
if (!gpu_state_)
- gpu_state_ = new gles2::GpuImpl::State;
+ gpu_state_ = new gles2::GpuState;
new gles2::GpuImpl(request.Pass(), gpu_state_);
}

Powered by Google App Engine
This is Rietveld 408576698