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

Unified Diff: Source/core/html/imports/HTMLImport.cpp

Issue 234063004: Refactoring: Get rid of HTMLImportRoot. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 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 | « Source/core/html/imports/HTMLImport.h ('k') | Source/core/html/imports/HTMLImportChild.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/imports/HTMLImport.cpp
diff --git a/Source/core/html/imports/HTMLImport.cpp b/Source/core/html/imports/HTMLImport.cpp
index 3717e8bbecfc6b7afe2cea48a791454c6680c07e..4e4dda227c2211a9f4b37c5c594ddf0c3a031666 100644
--- a/Source/core/html/imports/HTMLImport.cpp
+++ b/Source/core/html/imports/HTMLImport.cpp
@@ -36,6 +36,14 @@
namespace WebCore {
+HTMLImport* HTMLImport::root()
+{
+ HTMLImport* i = this;
+ while (i->parent())
+ i = i->parent();
+ return i;
+}
+
void HTMLImport::appendChild(HTMLImport* child)
{
TreeNode<HTMLImport>::appendChild(child);
@@ -56,15 +64,8 @@ void HTMLImport::stateDidChange()
}
}
-void HTMLImport::stateWillChange()
-{
- root()->scheduleRecalcState();
-}
-
void HTMLImport::recalcTreeState(HTMLImport* root)
{
- ASSERT(root == root->root());
-
HashMap<HTMLImport*, HTMLImportState> snapshot;
Vector<HTMLImport*> updated;
« no previous file with comments | « Source/core/html/imports/HTMLImport.h ('k') | Source/core/html/imports/HTMLImportChild.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698