Timeline
Jan 4, 2015:
- 9:11 PM Changeset in webkit [177884] by
-
- 2 edits in trunk/Source/WebCore
- dom/DocumentFragment.cpp:
(WebCore::DocumentFragment::parseXML):
Removed an incorrect assertion my last check-in added.
- 6:24 PM Changeset in webkit [177883] by
-
- 9 edits in trunk/Source/WebCore
Modernize and tighten up HTMLDocumentParser
https://bugs.webkit.org/show_bug.cgi?id=140041
Reviewed by Sam Weinig.
- dom/DocumentFragment.cpp:
(WebCore::DocumentFragment::parseHTML): Pass a reference instead of
a pointer for the context element.
- html/FTPDirectoryDocument.cpp: Removed unneeded includes, made more
things in FTPDirectoryDocumentParser private. Use Ref instead of RefPtr
in a could places. Initialize in class instead of in constructor.
(WebCore::FTPDirectoryDocumentParser::FTPDirectoryDocumentParser):
Less initialization here.
(WebCore::FTPDirectoryDocumentParser::createTDForFilename): More Ref here.
(WebCore::createTemplateDocumentData): Removed unneeded initialization
of RefPtr, which is initialized without explicitly asking for it.
(WebCore::FTPDirectoryDocumentParser::loadDocumentTemplate): Reworded
comment slightly.
- html/parser/HTMLDocumentParser.cpp: Cut down on includes.
(WebCore::tokenizerStateForContextElement): Fixed URL. Changed argument
to be a reference rather than a pointer.
(WebCore::HTMLDocumentParser::inPumpSession):
(WebCore::HTMLDocumentParser::shouldDelayEnd):
(WebCore::HTMLDocumentParser::HTMLDocumentParser): Marked constructors
inline. Updated for data members that are now objects instead of pointers.
Removed explicit initialization for scalars that are now initialized in
the class definition.
(WebCore::HTMLDocumentParser::create): Moved the private creation
functions in here, out of the header file.
(WebCore::HTMLDocumentParser::~HTMLDocumentParser): Removed unused
m_haveBackgroundParser.
(WebCore::HTMLDocumentParser::prepareToStopParsing): Updated URL and
removed m_haveBackgroundParser reference.
(WebCore::HTMLDocumentParser::processingData): Removed a check of
m_haveBackgroundParser.
(WebCore::HTMLDocumentParser::resumeParsingAfterYield): Tweak comment.
(WebCore::HTMLDocumentParser::runScriptsForPausedTreeBuilder): Added
a null check of the result of takeScriptToProcess, since there really
is no guarantee it's non-null.
(WebCore::HTMLDocumentParser::canTakeNextToken): Removed assertion
that was for m_haveBackgroundParser cases only. Rewrapped comment.
(WebCore::HTMLDocumentParser::contextForParsingSession): Use nullptr.
(WebCore::HTMLDocumentParser::pumpTokenizer): Rework comments,
remove assertions that no longer make sense, use auto instead of
repeating a long type name, update to use m_token and m_tokenizer.
(WebCore::HTMLDocumentParser::hasInsertionPoint): Rewrapped comment.
(WebCore::HTMLDocumentParser::insert): Got rid of braces around a
single-line if body.
(WebCore::HTMLDocumentParser::attemptToRunDeferredScriptsAndEnd):
Removed comment about incorrect m_haveBackgroundParser assertion.
(WebCore::HTMLDocumentParser::isExecutingScript): Use && style instead
of early exit for a null check.
(WebCore::HTMLDocumentParser::textPosition): Tightened up code a little.
(WebCore::HTMLDocumentParser::resumeParsingAfterScriptExecution): Added
a Ref to protect the parser, as is already done in every other function
that calls pumpTokenizerIfPossible.
(WebCore::HTMLDocumentParser::parseDocumentFragment): Take a reference
instead of a pointer. Also use auto so we get a Ref instead of a RefPtr.
- html/parser/HTMLDocumentParser.h: Removed unneeded includes.
Made private inheritance explicit instead of just omitting public.
Moved function bodies out of the class, and in some cases, out of the
header entirely. Return a reference from tokenizer(). Marked most
virtual functions final. Made DocumentFragment version of the
constructor private rather than protected. Made the functions
suspendScheduledTasks() and resumeScheduledTasks() private, since
they are always called through a base class. Removed the private
token function since it is better to get at m_token directly.
Removed m_haveBackgroundParser, since we don't have that any more
and it's always false. Also removed forcePlaintextForTextDocument
since the tokenizer is exposed and can be used directly to do that.
- html/parser/HTMLTreeBuilder.cpp:
(WebCore::HTMLTreeBuilder::HTMLTreeBuilder): Made the parser non-const.
It could only be const before because HTMLDocumentParser::tokenizer
took a const parser and returned a non-const tokenizer, but that doesn't
really make sense.
(WebCore::HTMLTreeBuilder::constructTree): Removed null check for
tokenizer, which was never null. Updated since tokenizer is a reference.
(WebCore::HTMLTreeBuilder::processStartTagForInBody): Ditto.
(WebCore::HTMLTreeBuilder::processStartTagForInTable): Ditto.
(WebCore::HTMLTreeBuilder::processEndTag): Ditto. Also fixed and removed
some assertions like the ones I did recently in the rest of this file.
(WebCore::HTMLTreeBuilder::processGenericRCDATAStartTag): Ditto.
(WebCore::HTMLTreeBuilder::processGenericRawTextStartTag): Ditto.
(WebCore::HTMLTreeBuilder::processScriptStartTag): Ditto.
- html/parser/HTMLTreeBuilder.h: Made HTMLDocumentParser& non-const.
- html/parser/TextDocumentParser.cpp: Removed unneeded include and
unneeded explicit destructor.
(WebCore::TextDocumentParser::TextDocumentParser): Updated since
treeBuilder() returns a reference now, and set the tokenizer state
directly since tokenizer() is exposed.
- html/parser/TextDocumentParser.h: Moved initialization of the
data member here instead of the constructor. Also removed unneeded
explicitly defined destructor.
- 5:08 PM Changeset in webkit [177882] by
-
- 2 edits in trunk/LayoutTests
fast/events/autoscroll-should-not-stop-on-keypress.html is flaky in debug builds
https://bugs.webkit.org/show_bug.cgi?id=140060
Reviewed by Darin Adler.
- fast/events/autoscroll-should-not-stop-on-keypress.html: Instead of waiting a
fixed amount of time, check if the test succeeded every 100ms. In addition to making
the test more reliable on slow builds, it makes the test faster in release mode.
- 4:46 PM Changeset in webkit [177881] by
-
- 2 edits in trunk/Source/WebCore
Remove GlyphPageTree
https://bugs.webkit.org/show_bug.cgi?id=140015
Follow-up to follow-up, fonts/font-fallback-prefers-pictographs.html is now failing.
- platform/graphics/FontGlyphs.cpp:
(WebCore::FontGlyphs::glyphDataForVariant):
(WebCore::FontGlyphs::glyphDataForNormalVariant):
Make the loop again go one past the last fallback index, the pictograph special case depends on it.
- 4:16 PM Changeset in webkit [177880] by
-
- 4 edits in trunk/LayoutTests
http/tests/security/cross-frame-access-put.html is racy
https://bugs.webkit.org/show_bug.cgi?id=140059
Reviewed by Darin Adler.
This test used to run some code in a subframe on a zero delay timer, and some more
code in a main frame in onload. The order was undefined.
- http/tests/security/cross-frame-access-put-expected.txt:
- http/tests/security/cross-frame-access-put.html:
- http/tests/security/resources/cross-frame-iframe-for-put-test.html:
- 4:04 PM Changeset in webkit [177879] by
-
- 2 edits in trunk/LayoutTests
REGRESSION: plugins/plugin-remove-readystatechange.html is failing on debug bots
https://bugs.webkit.org/show_bug.cgi?id=126169
Reviewed by Antti Koivisto.
- plugins/plugin-remove-readystatechange.html: Move the embed so that it's not the
last rendered element in the test. It's only a workaround, not a real fix - if
anyone is interested in fixing the issue for real, please file a new bug.
Also, demystified the test by using readyState instead of counting readystatechange
events.
- 3:38 PM Changeset in webkit [177878] by
-
- 2 edits in trunk/Source/WebCore
Remove GlyphPageTree
https://bugs.webkit.org/show_bug.cgi?id=140015
Follow-up to r177876 to fix mathml/opentype/munderover-layout-resize.html which is asserting in bots.
- platform/graphics/FontGlyphs.cpp:
(WebCore::FontGlyphs::glyphDataForVariant):
(WebCore::FontGlyphs::glyphDataForNormalVariant):
Always return system fallback if no glyph is found.
- 3:27 PM Changeset in webkit [177877] by
-
- 2 edits in trunk/Source/WebCore
iOS build fix.
- platform/graphics/SimpleFontData.cpp:
(WebCore::createAndFillGlyphPage):
- 1:26 PM Changeset in webkit [177876] by
-
- 28 edits1 move2 deletes in trunk/Source
Remove GlyphPageTree
https://bugs.webkit.org/show_bug.cgi?id=140015
Reviewed by Darin Adler.
GlyphPageTree is a global cache consisting of a tree of nodes that match SimpleFontData instances.
The tree levels correspond to font fallback lists so that higher levels fill holes (missing glyphs)
in the lower levels. This patch replaces it with a simpler and easier to understand caching scheme.
In particular the goal is to have clearer ownership relations and better control over mutability.
The new scheme looks like this:
SimpleFontData instances cache GlyphPages for themselves. These pages are immutable after construction
and may contain holes. This is a global cache (since SimpleFontDatas are cached globally) with the same
lifetime as the GlyphPageTree used to have.
FontGlyphs instances cache resolved GlyphPages for the normal font variant. These are build by traversing
the fallback list as necessary and collecting glyphs from SimpleFontDatas. As a common case case optimization
the page from the primary font is cached directly as long as it has the requested glyphs.
FontGlyphs are shared between sufficiently similar Font instances so this is a shared cache as well.
- CMakeLists.txt:
- WebCore.exp.in:
- WebCore.vcxproj/WebCore.vcxproj:
- WebCore.xcodeproj/project.pbxproj:
- platform/graphics/FontCache.h:
(WebCore::FontDescriptionFontDataCacheKey::makeFlagKey):
nonCJKGlyphOrientation matters for glyph selection too and needs to be part of the FontDescription cache key.
- platform/graphics/FontData.h:
(WebCore::FontData::FontData):
(WebCore::FontData::setMaxGlyphPageTreeLevel): Deleted.
(WebCore::FontData::maxGlyphPageTreeLevel): Deleted.
- platform/graphics/FontFastPath.cpp:
(WebCore::Font::primaryFontHasGlyphForCharacter):
- platform/graphics/FontGlyphs.cpp:
(WebCore::FontGlyphs::FontGlyphs):
(WebCore::glyphDataForCJKCharacterWithoutSyntheticItalic):
(WebCore::glyphDataForNonCJKCharacterWithGlyphOrientation):
(WebCore::FontGlyphs::glyphDataForSystemFallback):
(WebCore::FontGlyphs::glyphDataForVariant):
(WebCore::FontGlyphs::glyphDataForNormalCharacter):
Traverse the fallback list by using simple index instead of indirectly via GlyphPageTreeNode traversal.
(WebCore::pageFromFontData):
Fetch a page from the primary font and see if we can use it as-is.
Vertical fonts have special glyph selection and can't use this path.
(WebCore::FontGlyphs::createFlattenedGlyphPage):
Build a hole-free glyph page by pulling characters from the fallback list.
(WebCore::FontGlyphs::glyphDataForCharacter):
- platform/graphics/FontGlyphs.h:
(WebCore::FontGlyphs::primarySimpleFontData):
- platform/graphics/GlyphPage.h:
(WebCore::GlyphPage::createForMixedFontData):
(WebCore::GlyphPage::createCopyForMixedFontData):
Add copy version.
(WebCore::GlyphPage::createForSingleFontData):
Remove owner node field.
(WebCore::GlyphPage::~GlyphPage):
(WebCore::GlyphPage::count):
(WebCore::GlyphPage::GlyphPage):
(WebCore::GlyphPage::createCopiedSystemFallbackPage): Deleted.
(WebCore::GlyphPage::owner): Deleted.
- platform/graphics/GlyphPageTreeNode.cpp: Removed.
- platform/graphics/GlyphPageTreeNode.h: Removed.
- platform/graphics/SegmentedFontData.cpp:
(WebCore::SegmentedFontData::SegmentedFontData):
(WebCore::SegmentedFontData::~SegmentedFontData):
(WebCore::SegmentedFontData::simpleFontDataForCharacter):
Return null when there is no usable range so the client can tell the difference.
Rename for clarity.
(WebCore::SegmentedFontData::simpleFontDataForFirstRange):
Add a way to get the fallback font separately. This is always available.
(WebCore::SegmentedFontData::isLoading):
(WebCore::SegmentedFontData::fontDataForCharacter): Deleted.
- platform/graphics/SegmentedFontData.h:
(WebCore::SegmentedFontData::SegmentedFontData): Deleted.
- platform/graphics/SimpleFontData.cpp:
(WebCore::SimpleFontData::initCharWidths):
(WebCore::SimpleFontData::platformGlyphInit):
(WebCore::SimpleFontData::~SimpleFontData):
(WebCore::SimpleFontData::simpleFontDataForCharacter):
(WebCore::fillGlyphPage):
(WebCore::createAndFillGlyphPage):
Move code for initializing glyph pages here. The code is from GlyphPageTreeNode.
(WebCore::SimpleFontData::glyphPage):
Cache glyphs for this font. These pages may have holes.
(WebCore::SimpleFontData::glyphForCharacter):
(WebCore::SimpleFontData::glyphDataForCharacter):
(WebCore::SimpleFontData::DerivedFontData::~DerivedFontData):
Since the cache is now owned by the SimpleFontData all the custom pruning can go away.
The glyph page cache dies along with it owner.
(WebCore::SimpleFontData::fontDataForCharacter): Deleted.
- platform/graphics/SimpleFontData.h:
- platform/graphics/mac/ComplexTextControllerCoreText.mm:
(-[WebCascadeList objectAtIndex:]):
(WebCore::ComplexTextController::collectComplexTextRunsForCharacters):
- platform/graphics/mac/FontComplexTextMac.cpp:
(WebCore::Font::fontDataForCombiningCharacterSequence):
- platform/graphics/mac/GlyphPageMac.cpp: Copied from Source/WebCore/platform/graphics/mac/GlyphPageTreeNodeMac.cpp.
This was already misnamed.
(WebCore::GlyphPage::fill):
- platform/graphics/mac/GlyphPageTreeNodeMac.cpp: Removed.
- platform/graphics/mac/SimpleFontDataMac.mm:
(WebCore::SimpleFontData::platformInit):
- platform/graphics/win/GlyphPageTreeNodeCGWin.cpp:
- platform/graphics/win/GlyphPageTreeNodeCairoWin.cpp:
- platform/graphics/win/SimpleFontDataCGWin.cpp:
(WebCore::SimpleFontData::platformInit):
- platform/mac/DragImageMac.mm:
Add missing FontCachePurgePreventer.
(WebCore::createDragImageForLink):
- svg/SVGFontData.cpp:
(WebCore::SVGFontData::initializeFontData):
- svg/SVGFontElement.cpp:
- 12:14 PM Changeset in webkit [177875] by
-
- 33 edits in trunk/Source/WebKit2
Clean up some of the IPC code
https://bugs.webkit.org/show_bug.cgi?id=140057
Reviewed by Antti Koivisto.
Use std::mutex instead of WTF::Mutex. Change a couple of pointers to references in the connection client.
- DatabaseProcess/DatabaseProcess.cpp:
(WebKit::DatabaseProcess::didClose):
(WebKit::DatabaseProcess::didReceiveInvalidMessage):
- DatabaseProcess/DatabaseProcess.h:
- DatabaseProcess/DatabaseToWebProcessConnection.cpp:
(WebKit::DatabaseToWebProcessConnection::didClose):
(WebKit::DatabaseToWebProcessConnection::didReceiveInvalidMessage):
- DatabaseProcess/DatabaseToWebProcessConnection.h:
- NetworkProcess/NetworkConnectionToWebProcess.cpp:
(WebKit::NetworkConnectionToWebProcess::didClose):
(WebKit::NetworkConnectionToWebProcess::didReceiveInvalidMessage):
- NetworkProcess/NetworkConnectionToWebProcess.h:
- NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::didClose):
(WebKit::NetworkProcess::didReceiveInvalidMessage):
- NetworkProcess/NetworkProcess.h:
- Platform/IPC/Connection.cpp:
(IPC::Connection::sendMessage):
(IPC::Connection::waitForMessage):
(IPC::Connection::connectionDidClose):
(IPC::Connection::sendOutgoingMessages):
(IPC::Connection::dispatchDidReceiveInvalidMessage):
(IPC::Connection::enqueueIncomingMessage):
(IPC::Connection::dispatchMessage):
(IPC::Connection::dispatchOneMessage):
- Platform/IPC/Connection.h:
- PluginProcess/PluginProcess.cpp:
(WebKit::PluginProcess::didClose):
(WebKit::PluginProcess::didReceiveInvalidMessage):
- PluginProcess/PluginProcess.h:
- PluginProcess/WebProcessConnection.cpp:
(WebKit::WebProcessConnection::didClose):
(WebKit::WebProcessConnection::didReceiveInvalidMessage):
- PluginProcess/WebProcessConnection.h:
- UIProcess/Databases/DatabaseProcessProxy.cpp:
(WebKit::DatabaseProcessProxy::didClose):
(WebKit::DatabaseProcessProxy::didReceiveInvalidMessage):
- UIProcess/Databases/DatabaseProcessProxy.h:
- UIProcess/Network/NetworkProcessProxy.cpp:
(WebKit::NetworkProcessProxy::didClose):
(WebKit::NetworkProcessProxy::didReceiveInvalidMessage):
- UIProcess/Network/NetworkProcessProxy.h:
- UIProcess/Plugins/PluginProcessProxy.cpp:
(WebKit::PluginProcessProxy::didClose):
(WebKit::PluginProcessProxy::didReceiveInvalidMessage):
- UIProcess/Plugins/PluginProcessProxy.h:
- UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::didClose):
(WebKit::WebProcessProxy::didReceiveInvalidMessage):
- UIProcess/WebProcessProxy.h:
- WebProcess/Databases/WebToDatabaseProcessConnection.cpp:
(WebKit::WebToDatabaseProcessConnection::didClose):
(WebKit::WebToDatabaseProcessConnection::didReceiveInvalidMessage):
- WebProcess/Databases/WebToDatabaseProcessConnection.h:
- WebProcess/Network/NetworkProcessConnection.cpp:
(WebKit::NetworkProcessConnection::didClose):
(WebKit::NetworkProcessConnection::didReceiveInvalidMessage):
- WebProcess/Network/NetworkProcessConnection.h:
- WebProcess/Plugins/PluginProcessConnection.cpp:
(WebKit::PluginProcessConnection::didClose):
(WebKit::PluginProcessConnection::didReceiveInvalidMessage):
- WebProcess/Plugins/PluginProcessConnection.h:
- WebProcess/WebPage/WebInspector.h:
- WebProcess/WebPage/WebInspectorUI.h:
- WebProcess/WebProcess.cpp:
(WebKit::WebProcess::didClose):
(WebKit::WebProcess::didReceiveInvalidMessage):
- WebProcess/WebProcess.h:
- 11:39 AM Changeset in webkit [177874] by
-
- 5 edits in trunk/Source/WebCore
Remove an unused function
https://bugs.webkit.org/show_bug.cgi?id=140055
Reviewed by Sam Weinig.
- Modules/webdatabase/DatabaseAuthorizer.cpp:
(WebCore::DatabaseAuthorizer::setReadOnly): Deleted.
- Modules/webdatabase/DatabaseAuthorizer.h:
- Modules/webdatabase/DatabaseBackendBase.cpp:
(WebCore::DatabaseBackendBase::setAuthorizerReadOnly): Deleted.
- Modules/webdatabase/DatabaseBackendBase.h:
- 10:57 AM Changeset in webkit [177873] by
-
- 7 edits in trunk/Source/WebCore
Modernize parts of the database code
https://bugs.webkit.org/show_bug.cgi?id=140054
Reviewed by Antti Koivisto.
- Modules/webdatabase/Database.cpp:
(WebCore::Database::runTransaction):
- Modules/webdatabase/Database.h:
- Modules/webdatabase/SQLStatement.cpp:
(WebCore::SQLStatement::SQLStatement):
- Modules/webdatabase/SQLStatement.h:
- Modules/webdatabase/SQLTransaction.cpp:
(WebCore::SQLTransaction::create):
(WebCore::SQLTransaction::SQLTransaction):
(WebCore::SQLTransaction::deliverQuotaIncreaseCallback):
(WebCore::SQLTransaction::executeSQL):
- Modules/webdatabase/SQLTransaction.h:
(WebCore::SQLTransaction::database):
Jan 3, 2015:
- 10:35 PM Changeset in webkit [177872] by
-
- 6 edits in trunk/Source/WebCore
Move the CSS Grid properties to the new StyleBuilder
https://bugs.webkit.org/show_bug.cgi?id=140051
Reviewed by Sam Weinig.
Move the CSS Grid properties from StyleResolver to the new
StyleBuilder.
This patch adds support for "ConditionalConverter" parameter in
CSSPropertyNames.in to support cases where we only want to call the
property setter conditionally. The converter function is then expected
to return a boolean to indicate if the setter should be called by the
StyleBuilder or not.
- 7:47 PM Changeset in webkit [177871] by
-
- 3 edits3 adds in trunk
Crash in operationNewFunction when scrolling on Google+
https://bugs.webkit.org/show_bug.cgi?id=140033
Reviewed by Oliver Hunt.
Source/JavaScriptCore:
In DFG code, the scope register can be eliminated because all uses have been
dead code eliminated. In the case where one of the uses was creating a function
that is never used, the baseline code will still create the function. If we OSR
exit to a path where that function gets created, check the scope register value
and set the new, but dead, function to undefined instead of creating a new function.
- jit/JITOpcodes.cpp:
(JSC::JIT::emit_op_new_func_exp):
LayoutTests:
New regerssion test.
- js/regress-140033-expected.txt: Added.
- js/regress-140033.html: Added.
- js/script-tests/regress-140033.js: Added.
(.unused):
(defineADeadFunction):