[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: branches/KDE/4.1/kdelibs/khtml
From: Maks Orlovich <maksim () kde ! org>
Date: 2008-10-19 18:48:11
Message-ID: 1224442091.357789.27302.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 873587 by orlovich:
DocumentImpl::unsubmittedChanges actually relied on modified things having 'M' at the \
end of their state serialization, which broke notification of changes when the \
N/null flag got added. Fix this by adding an appropriate abstraction.
BUG:173159
M +3 -0 html/html_formimpl.h
M +4 -2 xml/dom_docimpl.cpp
--- branches/KDE/4.1/kdelibs/khtml/html/html_formimpl.h #873586:873587
@@ -175,6 +175,8 @@
virtual void defaultEventHandler(EventImpl *evt);
virtual bool isEditable();
+ virtual bool unsubmittedFormChanges() const { return false; }
+
protected:
HTMLFormElementImpl *getForm() const;
@@ -309,6 +311,7 @@
void activate();
void setUnsubmittedFormChange(bool unsubmitted) { m_unsubmittedFormChange = \
unsubmitted; } + virtual bool unsubmittedFormChanges() const { return \
m_unsubmittedFormChange; }
//Mozilla extensions.
long selectionStart();
--- branches/KDE/4.1/kdelibs/khtml/xml/dom_docimpl.cpp #873586:873587
@@ -1166,9 +1166,11 @@
bool DocumentImpl::unsubmittedFormChanges()
{
- for (QListIterator<NodeImpl*> it(m_maintainsState); it.hasNext();)
- if (it.next()->state().endsWith('M'))
+ for (QListIterator<NodeImpl*> it(m_maintainsState); it.hasNext();) {
+ NodeImpl* node = it.next();
+ if (node->isGenericFormElement() && \
static_cast<HTMLGenericFormElementImpl*>(node)->unsubmittedFormChanges()) return \
true; + }
return false;
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic