Index: Source/core/dom/Document.cpp |
diff --git a/Source/core/dom/Document.cpp b/Source/core/dom/Document.cpp |
index 94af56c0c40277a1b7c5976aefe59891e6418b9f..3163af1a419d824a7448c4a8e47fb4a06d38f0ec 100644 |
--- a/Source/core/dom/Document.cpp |
+++ b/Source/core/dom/Document.cpp |
@@ -427,7 +427,6 @@ Document::Document(const DocumentInit& initializer, DocumentClassFlags documentC |
, m_visuallyOrdered(false) |
, m_readyState(Complete) |
, m_isParsing(false) |
- , m_historyItemDocumentStateDirty(false) |
, m_gotoAnchorNeededAfterStylesheetsLoad(false) |
, m_containsValidityStyleRules(false) |
, m_updateFocusAppearanceRestoresSelection(false) |
@@ -1465,15 +1464,18 @@ Node::NodeType Document::nodeType() const |
FormController& Document::formController() |
{ |
- if (!m_formController) |
+ if (!m_formController) { |
m_formController = FormController::create(); |
+ if (m_frame && m_frame->loader().currentItem() && m_frame->loader().currentItem()->isCurrentDocument(this)) |
+ m_frame->loader().currentItem()->setDocumentState(m_formController->formElementsState()); |
abarth-chromium
2014/04/17 23:41:24
It seems slightly odd that getting the formControl
Nate Chapin
2014/04/17 23:48:19
Right. I didn't see a cleaner way to hook this up.
|
+ } |
return *m_formController; |
} |
-Vector<String> Document::formElementsState() const |
+DocumentState* Document::formElementsState() const |
{ |
if (!m_formController) |
- return Vector<String>(); |
+ return 0; |
return m_formController->formElementsState(); |
} |