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

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

Issue 2811793005: Rename LocalFrame::Script() to GetScriptController() (Closed)
Patch Set: Created 3 years, 8 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
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 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights
6 * reserved. 6 * reserved.
7 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) 7 * (C) 2006 Alexey Proskuryakov (ap@nypop.com)
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 425 matching lines...) Expand 10 before | Expand all | Expand 10 after
436 "permission is not set.")); 436 "permission is not set."));
437 return; 437 return;
438 } 438 }
439 439
440 if (!GetDocument().GetContentSecurityPolicy()->AllowFormAction( 440 if (!GetDocument().GetContentSecurityPolicy()->AllowFormAction(
441 submission->Action())) { 441 submission->Action())) {
442 return; 442 return;
443 } 443 }
444 444
445 if (submission->Action().ProtocolIsJavaScript()) { 445 if (submission->Action().ProtocolIsJavaScript()) {
446 GetDocument().GetFrame()->Script().ExecuteScriptIfJavaScriptURL( 446 GetDocument()
447 submission->Action(), this); 447 .GetFrame()
448 ->GetScriptController()
449 .ExecuteScriptIfJavaScriptURL(submission->Action(), this);
448 return; 450 return;
449 } 451 }
450 452
451 Frame* target_frame = GetDocument().GetFrame()->FindFrameForNavigation( 453 Frame* target_frame = GetDocument().GetFrame()->FindFrameForNavigation(
452 submission->Target(), *GetDocument().GetFrame()); 454 submission->Target(), *GetDocument().GetFrame());
453 if (!target_frame) { 455 if (!target_frame) {
454 if (!LocalDOMWindow::AllowPopUp(*GetDocument().GetFrame()) && 456 if (!LocalDOMWindow::AllowPopUp(*GetDocument().GetFrame()) &&
455 !UserGestureIndicator::UtilizeUserGesture()) 457 !UserGestureIndicator::UtilizeUserGesture())
456 return; 458 return;
457 target_frame = GetDocument().GetFrame(); 459 target_frame = GetDocument().GetFrame();
(...skipping 381 matching lines...) Expand 10 before | Expand all | Expand 10 after
839 for (const auto& control : ListedElements()) { 841 for (const auto& control : ListedElements()) {
840 if (!control->IsFormControlElement()) 842 if (!control->IsFormControlElement())
841 continue; 843 continue;
842 if (ToHTMLFormControlElement(control)->CanBeSuccessfulSubmitButton()) 844 if (ToHTMLFormControlElement(control)->CanBeSuccessfulSubmitButton())
843 ToHTMLFormControlElement(control)->PseudoStateChanged( 845 ToHTMLFormControlElement(control)->PseudoStateChanged(
844 CSSSelector::kPseudoDefault); 846 CSSSelector::kPseudoDefault);
845 } 847 }
846 } 848 }
847 849
848 } // namespace blink 850 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/html/HTMLDocument.cpp ('k') | third_party/WebKit/Source/core/html/HTMLFrameElementBase.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698