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

Unified Diff: third_party/WebKit/Source/core/frame/FrameView.cpp

Issue 2151933003: Change WTF::TemporaryChange to be an alias for AutoReset (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: TemporaryChange -> AutoReset Created 4 years, 5 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: third_party/WebKit/Source/core/frame/FrameView.cpp
diff --git a/third_party/WebKit/Source/core/frame/FrameView.cpp b/third_party/WebKit/Source/core/frame/FrameView.cpp
index dd43de21ee964dcb6b99e61db1c51629f77acefd..00e0c8228670b22c82a6bfc253d1167863f2579f 100644
--- a/third_party/WebKit/Source/core/frame/FrameView.cpp
+++ b/third_party/WebKit/Source/core/frame/FrameView.cpp
@@ -115,7 +115,6 @@
#include "wtf/CurrentTime.h"
#include "wtf/PtrUtil.h"
#include "wtf/StdLibExtras.h"
-#include "wtf/TemporaryChange.h"
#include <memory>
namespace blink {
@@ -560,7 +559,7 @@ void FrameView::adjustViewSizeAndLayout()
{
adjustViewSize();
if (needsLayout()) {
- TemporaryChange<bool> suppressAdjustViewSize(m_suppressAdjustViewSize, true);
+ AutoReset<bool> suppressAdjustViewSize(&m_suppressAdjustViewSize, true);
layout();
}
}
@@ -788,7 +787,7 @@ void FrameView::performPreLayoutTasks()
lifecycle().advanceTo(DocumentLifecycle::InPreLayout);
// Don't schedule more layouts, we're in one.
- TemporaryChange<bool> changeSchedulingEnabled(m_layoutSchedulingEnabled, false);
+ AutoReset<bool> changeSchedulingEnabled(&m_layoutSchedulingEnabled, false);
if (!m_nestedLayoutCount && !m_inSynchronousPostLayout && m_postLayoutTasksTimer.isActive()) {
// This is a new top-level layout. If there are any remaining tasks from the previous layout, finish them now.
@@ -966,7 +965,7 @@ void FrameView::layout()
FontCachePurgePreventer fontCachePurgePreventer;
{
- TemporaryChange<bool> changeSchedulingEnabled(m_layoutSchedulingEnabled, false);
+ AutoReset<bool> changeSchedulingEnabled(&m_layoutSchedulingEnabled, false);
m_nestedLayoutCount++;
updateCounters();
@@ -2522,7 +2521,7 @@ void FrameView::updateLifecyclePhasesInternal(DocumentLifecycle::LifecycleState
if (!m_frame->document()->isActive())
return;
- TemporaryChange<DocumentLifecycle::LifecycleState> targetStateScope(m_currentUpdateLifecyclePhasesTargetState, targetState);
+ AutoReset<DocumentLifecycle::LifecycleState> targetStateScope(&m_currentUpdateLifecyclePhasesTargetState, targetState);
if (shouldThrottleRendering()) {
updateViewportIntersectionsForSubtree(std::min(targetState, DocumentLifecycle::CompositingClean));
« no previous file with comments | « third_party/WebKit/Source/core/frame/FrameView.h ('k') | third_party/WebKit/Source/core/frame/FrameViewAutoSizeInfo.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698