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

Unified Diff: third_party/WebKit/Source/core/css/CSSDefaultStyleSheets.cpp

Issue 1855203002: Revert of Improve DEFINE_STATIC_LOCAL()'s handling of Blink GCed objects. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 | « no previous file | third_party/WebKit/Source/core/css/CSSPathValue.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/css/CSSDefaultStyleSheets.cpp
diff --git a/third_party/WebKit/Source/core/css/CSSDefaultStyleSheets.cpp b/third_party/WebKit/Source/core/css/CSSDefaultStyleSheets.cpp
index faeb1f52624f3a9083e14cd4c6a68d4b6af6d91c..70c17aa36d26a7df52138edd09196094c67dd729 100644
--- a/third_party/WebKit/Source/core/css/CSSDefaultStyleSheets.cpp
+++ b/third_party/WebKit/Source/core/css/CSSDefaultStyleSheets.cpp
@@ -45,20 +45,20 @@
CSSDefaultStyleSheets& CSSDefaultStyleSheets::instance()
{
- DEFINE_STATIC_LOCAL(CSSDefaultStyleSheets, cssDefaultStyleSheets, (new CSSDefaultStyleSheets));
- return cssDefaultStyleSheets;
+ DEFINE_STATIC_LOCAL(Persistent<CSSDefaultStyleSheets>, cssDefaultStyleSheets, (new CSSDefaultStyleSheets()));
+ return *cssDefaultStyleSheets;
}
static const MediaQueryEvaluator& screenEval()
{
- DEFINE_STATIC_LOCAL(MediaQueryEvaluator, staticScreenEval, (new MediaQueryEvaluator("screen")));
- return staticScreenEval;
+ DEFINE_STATIC_LOCAL(Persistent<MediaQueryEvaluator>, staticScreenEval, (new MediaQueryEvaluator("screen")));
+ return *staticScreenEval;
}
static const MediaQueryEvaluator& printEval()
{
- DEFINE_STATIC_LOCAL(MediaQueryEvaluator, staticPrintEval, (new MediaQueryEvaluator("print")));
- return staticPrintEval;
+ DEFINE_STATIC_LOCAL(Persistent<MediaQueryEvaluator>, staticPrintEval, (new MediaQueryEvaluator("print")));
+ return *staticPrintEval;
}
static RawPtr<StyleSheetContents> parseUASheet(const String& str)
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/css/CSSPathValue.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698