Summary: | merge MarkupAccumulator and MarkupAccumulatorWrapper | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Ryosuke Niwa <rniwa> | ||||||
Component: | HTML Editing | Assignee: | Ryosuke Niwa <rniwa> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Enhancement | CC: | abarth, darin, enrica, ojan, tkent, tony | ||||||
Priority: | P2 | ||||||||
Version: | 528+ (Nightly build) | ||||||||
Hardware: | All | ||||||||
OS: | All | ||||||||
Bug Depends on: | 43227 | ||||||||
Bug Blocks: | 43936 | ||||||||
Attachments: |
|
Description
Ryosuke Niwa
2010-08-11 00:42:25 PDT
Created attachment 64084 [details]
first attempt to merge
This is my first attempt to merge the two classes. I merged MarkupAccumulator::appendMarkup and serializeNodes to centralize all serializations in one place. But I feel like this approach is wrong because serializations done in two different versions of createMarkup are so different. I should probably add a recursive serializeNodesWithNamespace to replace MarkupAccumulator::appendMarkup instead. serializeNodesWithNamespace can take MarkupAccumulatorWrapper as an argument and this will allow us to merge two classes.
Created attachment 64148 [details]
Patch
(In reply to comment #2) > Created an attachment (id=64148) [details] > Patch In this patch, I didn't try to merge two serializations. But instead, I added serializeNodeWithNamespaces which uses MarkupAccumulatorWrapper for the node version of createMarkup. I'm intending to put most of functions in markup.cpp into MarkupAccumulatorWrapper and rename it to MarkupAccumulator once this patch is landed. Comment on attachment 64148 [details]
Patch
Looks good.
Committed r65265: <http://trac.webkit.org/changeset/65265> |