| 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 405 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 416 | 416 |
| 417 if (protocolIsJavaScript(submission->action())) { | 417 if (protocolIsJavaScript(submission->action())) { |
| 418 if (!document().contentSecurityPolicy()->allowFormAction(KURL(submission
->action()))) | 418 if (!document().contentSecurityPolicy()->allowFormAction(KURL(submission
->action()))) |
| 419 return; | 419 return; |
| 420 document().frame()->script().executeScriptIfJavaScriptURL(submission->ac
tion()); | 420 document().frame()->script().executeScriptIfJavaScriptURL(submission->ac
tion()); |
| 421 return; | 421 return; |
| 422 } | 422 } |
| 423 | 423 |
| 424 LocalFrame* targetFrame = document().frame()->loader().findFrameForNavigatio
n(submission->target(), submission->state()->sourceDocument()); | 424 LocalFrame* targetFrame = document().frame()->loader().findFrameForNavigatio
n(submission->target(), submission->state()->sourceDocument()); |
| 425 if (!targetFrame) { | 425 if (!targetFrame) { |
| 426 if (!DOMWindow::allowPopUp(document().frame()) && !UserGestureIndicator:
:processingUserGesture()) | 426 if (!DOMWindow::allowPopUp(*document().frame()) && !UserGestureIndicator
::processingUserGesture()) |
| 427 return; | 427 return; |
| 428 targetFrame = document().frame(); | 428 targetFrame = document().frame(); |
| 429 } else { | 429 } else { |
| 430 submission->clearTarget(); | 430 submission->clearTarget(); |
| 431 } | 431 } |
| 432 if (!targetFrame->page()) | 432 if (!targetFrame->page()) |
| 433 return; | 433 return; |
| 434 | 434 |
| 435 submission->setReferrer(Referrer(document().outgoingReferrer(), document().r
eferrerPolicy())); | 435 submission->setReferrer(Referrer(document().outgoingReferrer(), document().r
eferrerPolicy())); |
| 436 submission->setOrigin(document().outgoingOrigin()); | 436 submission->setOrigin(document().outgoingOrigin()); |
| (...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 816 } | 816 } |
| 817 | 817 |
| 818 void HTMLFormElement::setDemoted(bool demoted) | 818 void HTMLFormElement::setDemoted(bool demoted) |
| 819 { | 819 { |
| 820 if (demoted) | 820 if (demoted) |
| 821 UseCounter::count(document(), UseCounter::DemotedFormElement); | 821 UseCounter::count(document(), UseCounter::DemotedFormElement); |
| 822 m_wasDemoted = demoted; | 822 m_wasDemoted = demoted; |
| 823 } | 823 } |
| 824 | 824 |
| 825 } // namespace | 825 } // namespace |
| OLD | NEW |