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

Unified Diff: mojo/examples/sample_app/gles2_client_impl.cc

Issue 536153002: mojo: Fix window resizing in mojo_sample_app and mojo_demo_launcher. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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 | « mojo/examples/sample_app/DEPS ('k') | mojo/services/view_manager/display_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/examples/sample_app/gles2_client_impl.cc
diff --git a/mojo/examples/sample_app/gles2_client_impl.cc b/mojo/examples/sample_app/gles2_client_impl.cc
index 1723b16bddc279262659a4ad472d68f33ee561fa..6cdd87a2a20024246e83c979117a832297c0f0a3 100644
--- a/mojo/examples/sample_app/gles2_client_impl.cc
+++ b/mojo/examples/sample_app/gles2_client_impl.cc
@@ -9,6 +9,7 @@
#include <math.h>
#include <stdlib.h>
+#include "gpu/command_buffer/client/gles2_interface.h"
#include "mojo/public/c/gles2/gles2.h"
#include "mojo/public/cpp/environment/environment.h"
#include "mojo/public/cpp/utility/run_loop.h"
@@ -45,6 +46,10 @@ void GLES2ClientImpl::SetSize(const mojo::Size& size) {
size_ = size;
if (size_.width == 0 || size_.height == 0)
return;
+ static_cast<gpu::gles2::GLES2Interface*>(
+ MojoGLES2GetGLES2Interface(context_))->ResizeCHROMIUM(size_.width,
+ size_.height,
+ 1);
cube_.Init(size_.width, size_.height);
WantToDraw();
}
« no previous file with comments | « mojo/examples/sample_app/DEPS ('k') | mojo/services/view_manager/display_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698