Commit ebb63d4e authored by Alberto Garcia's avatar Alberto Garcia
Browse files

Imported Upstream version 2.12.2

parent ad6298da
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -14,7 +14,7 @@
<div class="titlepage">
<div>
<div><table class="navigation" id="top" width="100%" cellpadding="2" cellspacing="0"><tr><th valign="middle"><p class="title">WebKit2GTK+ Reference Manual</p></th></tr></table></div>
<div><p class="releaseinfo">for WebKit2GTK+ 2.12.1</p></div>
<div><p class="releaseinfo">for WebKit2GTK+ 2.12.2</p></div>
</div>
<hr>
</div>
......
......@@ -177,7 +177,7 @@ against at application run time.</p>
<hr>
<div class="refsect2">
<a name="WEBKIT-MICRO-VERSION:CAPS"></a><h3>WEBKIT_MICRO_VERSION</h3>
<pre class="programlisting">#define WEBKIT_MICRO_VERSION (1)
<pre class="programlisting">#define WEBKIT_MICRO_VERSION (2)
</pre>
<p>Like <a class="link" href="webkit2gtk-4.0-WebKitVersion.html#webkit-get-micro-version" title="webkit_get_micro_version ()"><code class="function">webkit_get_micro_version()</code></a>, but from the headers used at
application compile time, rather than from the library linked
......
......@@ -14,7 +14,7 @@
<div class="titlepage">
<div>
<div><table class="navigation" id="top" width="100%" cellpadding="2" cellspacing="0"><tr><th valign="middle"><p class="title">WebKitDOMGTK+ Reference Manual</p></th></tr></table></div>
<div><p class="releaseinfo">for WebKitDOMGTK+ 2.12.1</p></div>
<div><p class="releaseinfo">for WebKitDOMGTK+ 2.12.2</p></div>
</div>
<hr>
</div>
......
==================
WebKitGTK+ 2.12.2
==================
What's new in WebKitGTK+ 2.12.2?
- Fix rendering of scrollbars with GTK themes using stepper buttons.
- Fix compatibility issue with 2.12.1 regarding local storage access from file URLs.
- Make menu list buttons use the text color from the theme.
- Do not show resize grip in non-resizable text fields.
- Fix accessibility events causing Orca to echo key presses instead of speaking the
inserted characters in password fields.
- Fix an off by one error in hyphenation.
- Fix several crashes and rendering issues.
- Fix the build with libjpeg v9.
- Translation updates: Bulgarian, Finnish, Greek, Italian, Turkish.
==================
WebKitGTK+ 2.12.1
==================
......
......@@ -993,7 +993,7 @@ public:
{
switch (nearCall.callMode()) {
case NearCallMode::Tail:
AssemblerType::relinkJump(nearCall.dataLocation(), destination.executableAddress());
AssemblerType::relinkJump(nearCall.dataLocation(), destination.dataLocation());
return;
case NearCallMode::Regular:
AssemblerType::relinkCall(nearCall.dataLocation(), destination.executableAddress());
......
......@@ -864,8 +864,11 @@ void linkPolymorphicCall(
RELEASE_ASSERT(callCases.size() == calls.size());
for (CallToCodePtr callToCodePtr : calls) {
// Tail call special-casing ensures proper linking on ARM Thumb2, where a tail call jumps to an address
// with a non-decorated bottom bit but a normal call calls an address with a decorated bottom bit.
bool isTailCall = callToCodePtr.call.isFlagSet(CCallHelpers::Call::Tail);
patchBuffer.link(
callToCodePtr.call, FunctionPtr(callToCodePtr.codePtr.executableAddress()));
callToCodePtr.call, FunctionPtr(isTailCall ? callToCodePtr.codePtr.dataLocation() : callToCodePtr.codePtr.executableAddress()));
}
if (JITCode::isOptimizingJIT(callerCodeBlock->jitType()))
patchBuffer.link(done, callLinkInfo.callReturnLocation().labelAtOffset(0));
......
......@@ -95,7 +95,7 @@ class IncludeFile
end
def self.processIncludeOptions()
while ARGV[0][/-I/]
while ARGV[0][/^-I/]
path = ARGV.shift[2..-1]
if not path
path = ARGV.shift
......
......@@ -196,6 +196,66 @@ private:
typename std::aligned_storage<sizeof(T), std::alignment_of<T>::value>::type m_value;
};
template<typename T>
constexpr bool operator==(const Optional<T>& lhs, const Optional<T>& rhs)
{
return static_cast<bool>(lhs) == static_cast<bool>(rhs) && (!static_cast<bool>(lhs) || lhs.value() == rhs.value());
}
template<typename T>
constexpr bool operator!=(const Optional<T>& lhs, const Optional<T>& rhs)
{
return !(lhs == rhs);
}
template<typename T>
constexpr bool operator==(const Optional<T>& opt, NulloptTag)
{
return !opt;
}
template<typename T>
constexpr bool operator!=(const Optional<T>& opt, NulloptTag)
{
return static_cast<bool>(opt);
}
template<typename T>
constexpr bool operator==(NulloptTag, const Optional<T>& opt)
{
return !opt;
}
template<typename T>
constexpr bool operator!=(NulloptTag, const Optional<T>& opt)
{
return static_cast<bool>(opt);
}
template<typename T>
constexpr bool operator==(const Optional<T>& opt, const T& value)
{
return opt && opt.value() == value;
}
template<typename T>
constexpr bool operator!=(const Optional<T>& opt, const T& value)
{
return !(opt == value);
}
template<typename T>
constexpr bool operator==(const T& value, const Optional<T>& opt)
{
return opt && opt.value() == value;
}
template<typename T>
constexpr bool operator!=(const T& value, const Optional<T>& opt)
{
return !(value == opt);
}
template<typename T>
Optional<typename std::decay<T>::type>
makeOptional(T&& value)
......
......@@ -68,6 +68,13 @@ void AudioDestinationNode::render(AudioBus*, AudioBus* destinationBus, size_t nu
return;
}
ASSERT(numberOfFrames);
if (!numberOfFrames) {
destinationBus->zero();
setIsSilent(true);
return;
}
// Let the context take care of any business at the start of each render quantum.
context().handlePreRenderTasks();
......
......@@ -2604,7 +2604,7 @@ AccessibilityRole AccessibilityRenderObject::determineAccessibilityRole()
return GroupRole;
if (isStyleFormatGroup())
return GroupRole;
return is<RenderInline>(*m_renderer) ? InlineRole : GroupRole;
#if ENABLE(MATHML)
if (node && node->hasTagName(MathMLNames::mathTag))
......
......@@ -24,6 +24,7 @@
#include "HTMLElement.h"
#include "HTMLNames.h"
#include "RenderText.h"
#include "TextControlInnerElements.h"
#include <glib-object.h>
#if HAVE(ACCESSIBILITY)
......@@ -96,6 +97,13 @@ AccessibilityObjectInclusion AccessibilityObject::accessibilityPlatformIncludesO
if (node && node->hasTagName(HTMLNames::spanTag) && !canSetFocusAttribute() && !hasAttributesRequiredForInclusion())
return IgnoreObject;
// If we include TextControlInnerTextElement children, changes to those children
// will result in focus and text notifications that suggest the user is no longer
// in the control. This can be especially problematic for screen reader users with
// key echo enabled when typing in a password input.
if (is<TextControlInnerTextElement>(node))
return IgnoreObject;
// Given a paragraph or div containing a non-nested anonymous block, WebCore
// ignores the paragraph or div and includes the block. We want the opposite:
// ATs are expecting accessible objects associated with textual elements. They
......
......@@ -570,10 +570,11 @@ static AtkRole atkRole(AccessibilityObject* coreObject)
case ApplicationRole:
return ATK_ROLE_APPLICATION;
case DocumentRegionRole:
case GroupRole:
case RadioGroupRole:
case TabPanelRole:
return ATK_ROLE_PANEL;
case GroupRole:
return coreObject->isStyleFormatGroup() ? ATK_ROLE_SECTION : ATK_ROLE_PANEL;
case RowHeaderRole:
return ATK_ROLE_ROW_HEADER;
case ColumnHeaderRole:
......
......@@ -194,6 +194,8 @@ bool CSSCrossfadeValue::traverseSubresources(const std::function<bool (const Cac
RefPtr<CSSCrossfadeValue> CSSCrossfadeValue::blend(const CSSCrossfadeValue& from, double progress) const
{
ASSERT(equalInputImages(from));
if (!m_cachedToImage || !m_cachedFromImage)
return nullptr;
RefPtr<StyleCachedImage> toStyledImage = StyleCachedImage::create(m_cachedToImage.get());
RefPtr<StyleCachedImage> fromStyledImage = StyleCachedImage::create(m_cachedFromImage.get());
......
......@@ -84,11 +84,11 @@ void RuleFeatureSet::recursivelyCollectFeaturesFromSelector(SelectorFeatures& se
} while (selector);
}
static std::pair<AtomicStringImpl*, unsigned> makeAttributeSelectorKey(const CSSSelector& selector)
static RuleFeatureSet::AttributeRules::SelectorKey makeAttributeSelectorKey(const CSSSelector& selector)
{
bool caseInsensitive = selector.attributeValueMatchingIsCaseInsensitive();
unsigned matchAndCase = static_cast<unsigned>(selector.match()) << 1 | caseInsensitive;
return std::make_pair(selector.attributeCanonicalLocalName().impl(), matchAndCase);
return std::make_pair(selector.attributeCanonicalLocalName().impl(), std::make_pair(selector.value().impl(), matchAndCase));
}
void RuleFeatureSet::collectFeatures(const RuleData& ruleData)
......@@ -100,16 +100,16 @@ void RuleFeatureSet::collectFeatures(const RuleData& ruleData)
if (ruleData.containsUncommonAttributeSelector())
uncommonAttributeRules.append(RuleFeature(ruleData.rule(), ruleData.selectorIndex(), ruleData.hasDocumentSecurityOrigin()));
for (auto* className : selectorFeatures.classesMatchingAncestors) {
auto addResult = ancestorClassRules.add(className, nullptr);
if (addResult.isNewEntry)
addResult.iterator->value = std::make_unique<Vector<RuleFeature>>();
auto addResult = ancestorClassRules.ensure(className, [] {
return std::make_unique<Vector<RuleFeature>>();
});
addResult.iterator->value->append(RuleFeature(ruleData.rule(), ruleData.selectorIndex(), ruleData.hasDocumentSecurityOrigin()));
}
for (auto* selector : selectorFeatures.attributeSelectorsMatchingAncestors) {
// Hashing by attributeCanonicalLocalName makes this HTML specific.
auto addResult = ancestorAttributeRulesForHTML.add(selector->attributeCanonicalLocalName().impl(), nullptr);
if (addResult.isNewEntry)
addResult.iterator->value = std::make_unique<AttributeRules>();
auto addResult = ancestorAttributeRulesForHTML.ensure(selector->attributeCanonicalLocalName().impl(), [] {
return std::make_unique<AttributeRules>();
});
auto& rules = *addResult.iterator->value;
rules.features.append(RuleFeature(ruleData.rule(), ruleData.selectorIndex(), ruleData.hasDocumentSecurityOrigin()));
// Deduplicate selectors.
......@@ -127,16 +127,15 @@ void RuleFeatureSet::add(const RuleFeatureSet& other)
siblingRules.appendVector(other.siblingRules);
uncommonAttributeRules.appendVector(other.uncommonAttributeRules);
for (auto& keyValuePair : other.ancestorClassRules) {
auto addResult = ancestorClassRules.add(keyValuePair.key, nullptr);
if (addResult.isNewEntry)
addResult.iterator->value = std::make_unique<Vector<RuleFeature>>(*keyValuePair.value);
else
addResult.iterator->value->appendVector(*keyValuePair.value);
auto addResult = ancestorClassRules.ensure(keyValuePair.key, [] {
return std::make_unique<Vector<RuleFeature>>();
});
addResult.iterator->value->appendVector(*keyValuePair.value);
}
for (auto& keyValuePair : other.ancestorAttributeRulesForHTML) {
auto addResult = ancestorAttributeRulesForHTML.add(keyValuePair.key, nullptr);
if (addResult.isNewEntry)
addResult.iterator->value = std::make_unique<AttributeRules>();
auto addResult = ancestorAttributeRulesForHTML.ensure(keyValuePair.key, [] {
return std::make_unique<AttributeRules>();
});
auto& rules = *addResult.iterator->value;
rules.features.appendVector(keyValuePair.value->features);
for (auto& selectorPair : keyValuePair.value->selectors)
......
......@@ -61,7 +61,8 @@ struct RuleFeatureSet {
HashMap<AtomicStringImpl*, std::unique_ptr<Vector<RuleFeature>>> ancestorClassRules;
struct AttributeRules {
HashMap<std::pair<AtomicStringImpl*, unsigned>, const CSSSelector*> selectors;
using SelectorKey = std::pair<AtomicStringImpl*, std::pair<AtomicStringImpl*, unsigned>>;
HashMap<SelectorKey, const CSSSelector*> selectors;
Vector<RuleFeature> features;
};
HashMap<AtomicStringImpl*, std::unique_ptr<AttributeRules>> ancestorAttributeRulesForHTML;
......
......@@ -3247,15 +3247,9 @@ void Document::processHttpEquiv(const String& equiv, const String& content)
unsigned long requestIdentifier = 0;
if (frameLoader.activeDocumentLoader() && frameLoader.activeDocumentLoader()->mainResourceLoader())
requestIdentifier = frameLoader.activeDocumentLoader()->mainResourceLoader()->identifier();
if (frameLoader.shouldInterruptLoadForXFrameOptions(content, url(), requestIdentifier)) {
String message = "Refused to display '" + url().stringCenterEllipsizedToLength() + "' in a frame because it set 'X-Frame-Options' to '" + content + "'.";
frameLoader.stopAllLoaders();
// Stopping the loader isn't enough, as we're already parsing the document; to honor the header's
// intent, we must navigate away from the possibly partially-rendered document to a location that
// doesn't inherit the parent's SecurityOrigin.
frame->navigationScheduler().scheduleLocationChange(this, securityOrigin(), SecurityOrigin::urlWithUniqueSecurityOrigin(), String());
addConsoleMessage(MessageSource::Security, MessageLevel::Error, message, requestIdentifier);
}
String message = "The X-Frame-Option '" + content + "' supplied in a <meta> element was ignored. X-Frame-Options may only be provided by an HTTP header sent with the document.";
addConsoleMessage(MessageSource::Security, MessageLevel::Error, message, requestIdentifier);
}
break;
......
......@@ -708,9 +708,9 @@ private:
Node* m_next { nullptr };
// When a node has rare data we move the renderer into the rare data.
union DataUnion {
RenderObject* m_renderer { nullptr };
RenderObject* m_renderer;
NodeRareDataBase* m_rareData;
} m_data;
} m_data { nullptr };
protected:
bool isParsingChildrenFinished() const { return getFlag(IsParsingChildrenFinishedFlag); }
......
......@@ -273,6 +273,8 @@ void AlternativeTextController::applyAlternativeTextToRange(const Range* range,
applyCommand(SpellingCorrectionCommand::create(rangeWithAlternative.ptr(), alternative));
// Recalculate pragraphRangeContainingCorrection, since SpellingCorrectionCommand modified the DOM, such that the original paragraphRangeContainingCorrection is no longer valid. Radar: 10305315 Bugzilla: 89526
paragraphRangeContainingCorrection = TextIterator::rangeFromLocationAndLength(&rootNode, paragraphStartIndex, correctionStartOffsetInParagraph + alternative.length());
if (!paragraphRangeContainingCorrection)
return;
setEnd(paragraphRangeContainingCorrection.get(), m_frame.selection().selection().start());
RefPtr<Range> replacementRange = TextIterator::subrange(paragraphRangeContainingCorrection.get(), correctionStartOffsetInParagraph, alternative.length());
......
......@@ -923,6 +923,7 @@ void HTMLInputElement::copyNonAttributePropertiesFromElement(const Element& sour
HTMLTextFormControlElement::copyNonAttributePropertiesFromElement(source);
updateValidity();
setFormControlValueMatchesRenderer(false);
m_inputType->updateInnerTextValue();
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment