Document::settings() should return a const Settings&.
authorakling@apple.com <akling@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 9 Feb 2017 20:32:27 +0000 (20:32 +0000)
committerakling@apple.com <akling@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 9 Feb 2017 20:32:27 +0000 (20:32 +0000)
commit27374f795ce92b56dceaa7ac4b7fabb6d44de4c2
tree95ad40bf4aa0cd3d96e8294017c7bb3c6ea869ce
parent9749d15aec3a86bc385b71b3bdf13d84634e6afa
Document::settings() should return a const Settings&.
<https://webkit.org/b/168061>

Reviewed by Geoffrey Garen.

- Make Document::settings() return a const reference.
- Added Document::mutableSettings() for all your non-const needs.
- Fixed up settings generator to produce const getters.
- Simplify a few settings() call sites that exposed themselves.

* Modules/applepay/ApplePaySession.cpp:
(WebCore::shouldDiscloseApplePayCapability):
* Modules/mediastream/UserMediaRequest.cpp:
(WebCore::canCallGetUserMedia):
* css/CSSFontFace.cpp:
(WebCore::CSSFontFace::appendSources):
* css/CSSFontSelector.cpp:
(WebCore::resolveGenericFamily):
* css/StyleResolver.h:
(WebCore::StyleResolver::settings):
* dom/Document.h:
(WebCore::Document::settings):
(WebCore::Document::mutableSettings):
* html/FTPDirectoryDocument.cpp:
(WebCore::createTemplateDocumentData):
* html/HTMLCanvasElement.cpp:
(WebCore::shouldEnableWebGL):
* html/HTMLEmbedElement.cpp:
(WebCore::HTMLEmbedElement::rendererIsNeeded):
* html/HTMLSelectElement.cpp:
(WebCore::HTMLSelectElement::menuListDefaultEventHandler):
* html/ImageDocument.cpp:
(WebCore::ImageDocument::updateDuringParsing):
* page/csp/ContentSecurityPolicy.cpp:
(WebCore::ContentSecurityPolicy::allowContentSecurityPolicySourceStarToMatchAnyProtocol):
* page/make_settings.pl:
(printGetterAndSetter):
* rendering/SimpleLineLayout.cpp:
(WebCore::SimpleLineLayout::toggleSimpleLineLayout):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@211979 268f45cc-cd09-0410-ab3c-d52691b4dbfc
15 files changed:
Source/WebCore/ChangeLog
Source/WebCore/Modules/applepay/ApplePaySession.cpp
Source/WebCore/Modules/mediastream/UserMediaRequest.cpp
Source/WebCore/css/CSSFontFace.cpp
Source/WebCore/css/CSSFontSelector.cpp
Source/WebCore/css/StyleResolver.h
Source/WebCore/dom/Document.h
Source/WebCore/html/FTPDirectoryDocument.cpp
Source/WebCore/html/HTMLCanvasElement.cpp
Source/WebCore/html/HTMLEmbedElement.cpp
Source/WebCore/html/HTMLSelectElement.cpp
Source/WebCore/html/ImageDocument.cpp
Source/WebCore/page/csp/ContentSecurityPolicy.cpp
Source/WebCore/page/make_settings.pl
Source/WebCore/rendering/SimpleLineLayout.cpp