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

Side by Side Diff: third_party/WebKit/Source/core/dom/PendingScript.h

Issue 2060853002: Remove ineffective PendingScript prefinalizer (2nd attempt.) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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 unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/dom/PendingScript.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google, Inc. All Rights Reserved. 2 * Copyright (C) 2010 Google, Inc. All Rights Reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 29 matching lines...) Expand all
40 class ScriptSourceCode; 40 class ScriptSourceCode;
41 41
42 // A container for an external script which may be loaded and executed. 42 // A container for an external script which may be loaded and executed.
43 // 43 //
44 // TODO(kochi): The comment below is from pre-oilpan age and may not be correct now. 44 // TODO(kochi): The comment below is from pre-oilpan age and may not be correct now.
45 // A RefPtr alone does not prevent the underlying Resource 45 // A RefPtr alone does not prevent the underlying Resource
46 // from purging its data buffer. This class holds a dummy client open for its 46 // from purging its data buffer. This class holds a dummy client open for its
47 // lifetime in order to guarantee that the data buffer will not be purged. 47 // lifetime in order to guarantee that the data buffer will not be purged.
48 class CORE_EXPORT PendingScript final : public GarbageCollectedFinalized<Pending Script>, public ResourceOwner<ScriptResource> { 48 class CORE_EXPORT PendingScript final : public GarbageCollectedFinalized<Pending Script>, public ResourceOwner<ScriptResource> {
49 USING_GARBAGE_COLLECTED_MIXIN(PendingScript); 49 USING_GARBAGE_COLLECTED_MIXIN(PendingScript);
50 USING_PRE_FINALIZER(PendingScript, dispose);
51 WTF_MAKE_NONCOPYABLE(PendingScript); 50 WTF_MAKE_NONCOPYABLE(PendingScript);
52 public: 51 public:
53 static PendingScript* create(Element*, ScriptResource*); 52 static PendingScript* create(Element*, ScriptResource*);
54 ~PendingScript() override; 53 ~PendingScript() override;
55 54
56 TextPosition startingPosition() const { return m_startingPosition; } 55 TextPosition startingPosition() const { return m_startingPosition; }
57 void setStartingPosition(const TextPosition& position) { m_startingPosition = position; } 56 void setStartingPosition(const TextPosition& position) { m_startingPosition = position; }
58 void markParserBlockingLoadStartTime(); 57 void markParserBlockingLoadStartTime();
59 // Returns the time the load of this script started blocking the parser, or 58 // Returns the time the load of this script started blocking the parser, or
60 // zero if this script hasn't yet blocked the parser, in 59 // zero if this script hasn't yet blocked the parser, in
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 bool m_integrityFailure; 94 bool m_integrityFailure;
96 double m_parserBlockingLoadStartTime; 95 double m_parserBlockingLoadStartTime;
97 96
98 Member<ScriptStreamer> m_streamer; 97 Member<ScriptStreamer> m_streamer;
99 Member<ScriptResourceClient> m_client; 98 Member<ScriptResourceClient> m_client;
100 }; 99 };
101 100
102 } // namespace blink 101 } // namespace blink
103 102
104 #endif // PendingScript_h 103 #endif // PendingScript_h
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/dom/PendingScript.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698