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

Unified Diff: cc/surfaces/display.cc

Issue 2425923003: Replaced is_null() with is_valid in SurfaceId and related classes. (Closed)
Patch Set: Removed added printf statements; LocalFrameId::is_valid() no longer checks if nonce is 0. Created 4 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
Index: cc/surfaces/display.cc
diff --git a/cc/surfaces/display.cc b/cc/surfaces/display.cc
index 3550a39efda0071a17fe5a195c511c171bf4916a..55da4f890bb3ff0c2364751add660719c3c37dc5 100644
--- a/cc/surfaces/display.cc
+++ b/cc/surfaces/display.cc
@@ -116,7 +116,7 @@ void Display::SetVisible(bool visible) {
if (!visible) {
// Damage tracker needs a full reset as renderer resources are dropped when
// not visible.
- if (aggregator_ && !current_surface_id_.is_null())
+ if (aggregator_ && current_surface_id_.is_valid())
aggregator_->SetFullDamageForSurface(current_surface_id_);
}
}
@@ -154,7 +154,7 @@ void Display::SetOutputIsSecure(bool secure) {
if (aggregator_) {
aggregator_->set_output_is_secure(secure);
// Force a redraw.
- if (!current_surface_id_.is_null())
+ if (current_surface_id_.is_valid())
aggregator_->SetFullDamageForSurface(current_surface_id_);
}
}
@@ -221,7 +221,7 @@ void Display::UpdateRootSurfaceResourcesLocked() {
bool Display::DrawAndSwap() {
TRACE_EVENT0("cc", "Display::DrawAndSwap");
- if (current_surface_id_.is_null()) {
+ if (!current_surface_id_.is_valid()) {
TRACE_EVENT_INSTANT0("cc", "No root surface.", TRACE_EVENT_SCOPE_THREAD);
return false;
}

Powered by Google App Engine
This is Rietveld 408576698