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

Unified Diff: cc/proxy.h

Issue 11048044: cc: Switch to Chromium DCHECKs and LOGs (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/program_binding.cc ('k') | cc/proxy.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/proxy.h
diff --git a/cc/proxy.h b/cc/proxy.h
index cae128e51abf826733da2dbdfb149470fa899d41..1f475f05b3069281c5348bdf567f149ebf029981 100644
--- a/cc/proxy.h
+++ b/cc/proxy.h
@@ -6,6 +6,7 @@
#define CCProxy_h
#include "base/basictypes.h"
+#include "cc/dcheck.h"
#include <public/WebCompositorOutputSurface.h>
namespace cc {
@@ -81,7 +82,7 @@ public:
virtual void acquireLayerTextures() = 0;
// Debug hooks
-#ifndef NDEBUG
+#if CC_DCHECK_ENABLED()
static bool isMainThread();
static bool isImplThread();
static bool isMainThreadBlocked();
@@ -91,7 +92,7 @@ public:
// Testing hooks
virtual void loseContext() = 0;
-#ifndef NDEBUG
+#if CC_DCHECK_ENABLED()
static void setCurrentThreadIsImplThread(bool);
#endif
@@ -108,15 +109,15 @@ class DebugScopedSetMainThreadBlocked {
public:
DebugScopedSetMainThreadBlocked()
{
-#if !ASSERT_DISABLED
- ASSERT(!CCProxy::isMainThreadBlocked());
+#if CC_DCHECK_ENABLED()
+ CC_DCHECK(!CCProxy::isMainThreadBlocked());
CCProxy::setMainThreadBlocked(true);
#endif
}
~DebugScopedSetMainThreadBlocked()
{
-#if !ASSERT_DISABLED
- ASSERT(CCProxy::isMainThreadBlocked());
+#if CC_DCHECK_ENABLED()
+ CC_DCHECK(CCProxy::isMainThreadBlocked());
CCProxy::setMainThreadBlocked(false);
#endif
}
« no previous file with comments | « cc/program_binding.cc ('k') | cc/proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698