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

Side by Side Diff: Source/core/html/HTMLFormElement.cpp

Issue 334283004: Rename DOMWindow to LocalDOMWindow (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase Created 6 years, 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 19 matching lines...) Expand all
30 #include "bindings/v8/ScriptEventListener.h" 30 #include "bindings/v8/ScriptEventListener.h"
31 #include "core/HTMLNames.h" 31 #include "core/HTMLNames.h"
32 #include "core/dom/Attribute.h" 32 #include "core/dom/Attribute.h"
33 #include "core/dom/Document.h" 33 #include "core/dom/Document.h"
34 #include "core/dom/ElementTraversal.h" 34 #include "core/dom/ElementTraversal.h"
35 #include "core/dom/IdTargetObserverRegistry.h" 35 #include "core/dom/IdTargetObserverRegistry.h"
36 #include "core/events/AutocompleteErrorEvent.h" 36 #include "core/events/AutocompleteErrorEvent.h"
37 #include "core/events/Event.h" 37 #include "core/events/Event.h"
38 #include "core/events/GenericEventQueue.h" 38 #include "core/events/GenericEventQueue.h"
39 #include "core/events/ScopedEventQueue.h" 39 #include "core/events/ScopedEventQueue.h"
40 #include "core/frame/DOMWindow.h" 40 #include "core/frame/LocalDOMWindow.h"
41 #include "core/frame/LocalFrame.h" 41 #include "core/frame/LocalFrame.h"
42 #include "core/frame/UseCounter.h" 42 #include "core/frame/UseCounter.h"
43 #include "core/frame/csp/ContentSecurityPolicy.h" 43 #include "core/frame/csp/ContentSecurityPolicy.h"
44 #include "core/html/HTMLCollection.h" 44 #include "core/html/HTMLCollection.h"
45 #include "core/html/HTMLDialogElement.h" 45 #include "core/html/HTMLDialogElement.h"
46 #include "core/html/HTMLImageElement.h" 46 #include "core/html/HTMLImageElement.h"
47 #include "core/html/HTMLInputElement.h" 47 #include "core/html/HTMLInputElement.h"
48 #include "core/html/HTMLObjectElement.h" 48 #include "core/html/HTMLObjectElement.h"
49 #include "core/html/RadioNodeList.h" 49 #include "core/html/RadioNodeList.h"
50 #include "core/html/forms/FormController.h" 50 #include "core/html/forms/FormController.h"
(...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after
394 394
395 if (protocolIsJavaScript(submission->action())) { 395 if (protocolIsJavaScript(submission->action())) {
396 if (!document().contentSecurityPolicy()->allowFormAction(submission->act ion())) 396 if (!document().contentSecurityPolicy()->allowFormAction(submission->act ion()))
397 return; 397 return;
398 document().frame()->script().executeScriptIfJavaScriptURL(submission->ac tion()); 398 document().frame()->script().executeScriptIfJavaScriptURL(submission->ac tion());
399 return; 399 return;
400 } 400 }
401 401
402 LocalFrame* targetFrame = document().frame()->loader().findFrameForNavigatio n(submission->target(), submission->state()->sourceDocument()); 402 LocalFrame* targetFrame = document().frame()->loader().findFrameForNavigatio n(submission->target(), submission->state()->sourceDocument());
403 if (!targetFrame) { 403 if (!targetFrame) {
404 if (!DOMWindow::allowPopUp(*document().frame()) && !UserGestureIndicator ::processingUserGesture()) 404 if (!LocalDOMWindow::allowPopUp(*document().frame()) && !UserGestureIndi cator::processingUserGesture())
405 return; 405 return;
406 targetFrame = document().frame(); 406 targetFrame = document().frame();
407 } else { 407 } else {
408 submission->clearTarget(); 408 submission->clearTarget();
409 } 409 }
410 if (!targetFrame->page()) 410 if (!targetFrame->page())
411 return; 411 return;
412 412
413 if (MixedContentChecker::isMixedContent(document().securityOrigin(), submiss ion->action())) { 413 if (MixedContentChecker::isMixedContent(document().securityOrigin(), submiss ion->action())) {
414 UseCounter::count(document(), UseCounter::MixedContentFormsSubmitted); 414 UseCounter::count(document(), UseCounter::MixedContentFormsSubmitted);
(...skipping 383 matching lines...) Expand 10 before | Expand all | Expand 10 after
798 } 798 }
799 799
800 void HTMLFormElement::setDemoted(bool demoted) 800 void HTMLFormElement::setDemoted(bool demoted)
801 { 801 {
802 if (demoted) 802 if (demoted)
803 UseCounter::count(document(), UseCounter::DemotedFormElement); 803 UseCounter::count(document(), UseCounter::DemotedFormElement);
804 m_wasDemoted = demoted; 804 m_wasDemoted = demoted;
805 } 805 }
806 806
807 } // namespace 807 } // namespace
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698