OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * (C) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserv
ed. | 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserv
ed. |
6 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) | 6 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) |
7 * | 7 * |
8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
(...skipping 709 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
720 } | 720 } |
721 } | 721 } |
722 return hasInvalidControls; | 722 return hasInvalidControls; |
723 } | 723 } |
724 | 724 |
725 Element* HTMLFormElement::elementFromPastNamesMap(const AtomicString& pastName) | 725 Element* HTMLFormElement::elementFromPastNamesMap(const AtomicString& pastName) |
726 { | 726 { |
727 if (pastName.isEmpty() || !m_pastNamesMap) | 727 if (pastName.isEmpty() || !m_pastNamesMap) |
728 return 0; | 728 return 0; |
729 Element* element = m_pastNamesMap->get(pastName); | 729 Element* element = m_pastNamesMap->get(pastName); |
730 #if ASSERT_ENABLED | 730 #if ENABLE(ASSERT) |
731 if (!element) | 731 if (!element) |
732 return 0; | 732 return 0; |
733 ASSERT_WITH_SECURITY_IMPLICATION(toHTMLElement(element)->formOwner() == this
); | 733 ASSERT_WITH_SECURITY_IMPLICATION(toHTMLElement(element)->formOwner() == this
); |
734 if (isHTMLImageElement(*element)) { | 734 if (isHTMLImageElement(*element)) { |
735 ASSERT_WITH_SECURITY_IMPLICATION(imageElements().find(element) != kNotFo
und); | 735 ASSERT_WITH_SECURITY_IMPLICATION(imageElements().find(element) != kNotFo
und); |
736 } else if (isHTMLObjectElement(*element)) { | 736 } else if (isHTMLObjectElement(*element)) { |
737 ASSERT_WITH_SECURITY_IMPLICATION(associatedElements().find(toHTMLObjectE
lement(element)) != kNotFound); | 737 ASSERT_WITH_SECURITY_IMPLICATION(associatedElements().find(toHTMLObjectE
lement(element)) != kNotFound); |
738 } else { | 738 } else { |
739 ASSERT_WITH_SECURITY_IMPLICATION(associatedElements().find(toHTMLFormCon
trolElement(element)) != kNotFound); | 739 ASSERT_WITH_SECURITY_IMPLICATION(associatedElements().find(toHTMLFormCon
trolElement(element)) != kNotFound); |
740 } | 740 } |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
826 } | 826 } |
827 | 827 |
828 void HTMLFormElement::setDemoted(bool demoted) | 828 void HTMLFormElement::setDemoted(bool demoted) |
829 { | 829 { |
830 if (demoted) | 830 if (demoted) |
831 UseCounter::count(document(), UseCounter::DemotedFormElement); | 831 UseCounter::count(document(), UseCounter::DemotedFormElement); |
832 m_wasDemoted = demoted; | 832 m_wasDemoted = demoted; |
833 } | 833 } |
834 | 834 |
835 } // namespace | 835 } // namespace |
OLD | NEW |