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

Unified Diff: ui/gl/gl_surface_x11.cc

Issue 1166463004: Revert of Adding status to swap complete (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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/gl/gl_surface_win.cc ('k') | ui/ozone/platform/cast/surface_ozone_egl_cast.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gl/gl_surface_x11.cc
diff --git a/ui/gl/gl_surface_x11.cc b/ui/gl/gl_surface_x11.cc
index 4e14a43b4d12f851b7b9497192d019d334d2839e..f7d6a41f3b637109c2dc16df3cbafebf9685be50 100644
--- a/ui/gl/gl_surface_x11.cc
+++ b/ui/gl/gl_surface_x11.cc
@@ -32,9 +32,9 @@
void Destroy() override;
bool Resize(const gfx::Size& new_size) override;
bool IsOffscreen() override;
- gfx::SwapResult SwapBuffers() override;
+ bool SwapBuffers() override;
bool SupportsPostSubBuffer() override;
- gfx::SwapResult PostSubBuffer(int x, int y, int width, int height) override;
+ bool PostSubBuffer(int x, int y, int width, int height) override;
protected:
~NativeViewGLSurfaceOSMesa() override;
@@ -181,7 +181,7 @@
return false;
}
-gfx::SwapResult NativeViewGLSurfaceOSMesa::SwapBuffers() {
+bool NativeViewGLSurfaceOSMesa::SwapBuffers() {
TRACE_EVENT2("gpu", "NativeViewGLSurfaceOSMesa:RealSwapBuffers",
"width", GetSize().width(),
"height", GetSize().height());
@@ -191,7 +191,7 @@
XWindowAttributes attributes;
if (!XGetWindowAttributes(xdisplay_, window_, &attributes)) {
LOG(ERROR) << "XGetWindowAttributes failed for window " << window_ << ".";
- return gfx::SwapResult::SWAP_FAILED;
+ return false;
}
// Copy the frame into the pixmap.
@@ -216,17 +216,15 @@
0,
0);
- return gfx::SwapResult::SWAP_ACK;
+ return true;
}
bool NativeViewGLSurfaceOSMesa::SupportsPostSubBuffer() {
return true;
}
-gfx::SwapResult NativeViewGLSurfaceOSMesa::PostSubBuffer(int x,
- int y,
- int width,
- int height) {
+bool NativeViewGLSurfaceOSMesa::PostSubBuffer(
+ int x, int y, int width, int height) {
gfx::Size size = GetSize();
// Move (0,0) from lower-left to upper-left
@@ -235,7 +233,7 @@
XWindowAttributes attributes;
if (!XGetWindowAttributes(xdisplay_, window_, &attributes)) {
LOG(ERROR) << "XGetWindowAttributes failed for window " << window_ << ".";
- return gfx::SwapResult::SWAP_FAILED;
+ return false;
}
// Copy the frame into the pixmap.
@@ -266,7 +264,7 @@
x,
y);
- return gfx::SwapResult::SWAP_ACK;
+ return true;
}
NativeViewGLSurfaceOSMesa::~NativeViewGLSurfaceOSMesa() {
« no previous file with comments | « ui/gl/gl_surface_win.cc ('k') | ui/ozone/platform/cast/surface_ozone_egl_cast.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698