Closed
Bug 86270
Opened 23 years ago
Closed 23 years ago
implement default templates using code
Categories
(Core :: XSLT, defect)
Core
XSLT
Tracking
()
VERIFIED
FIXED
mozilla0.9.2
People
(Reporter: sicking, Assigned: sicking)
References
Details
Attachments
(2 files)
9.18 KB,
patch
|
Details | Diff | Splinter Review | |
8.15 KB,
patch
|
Details | Diff | Splinter Review |
we should implement default templates using code instead of inserting them into the xsl document. There is two advantages with this: 1. All default templates can't be implemented by inserting nodes in the xslt-dom 2. We don't have to modify the xslt document given to us
Assignee | ||
Comment 1•23 years ago
|
||
Assignee | ||
Comment 2•23 years ago
|
||
Assignee | ||
Comment 3•23 years ago
|
||
The patch basically does two things. It removes the code that adds the default templates to the xslt document, and it adds an extra |else processDefaultTemplate(...);| to each |if(xslTemplate) processTemplate(...);|
Status: NEW → ASSIGNED
Keywords: review
Comment 4•23 years ago
|
||
I like it, but we now have this every time: if (xslTemplate) processTemplate(node, xslTemplate, ps); else processDefaultTemplate(node, ps, mode); Do you think we could put the NULL check and processDefaultTemplate inside processTemplate? So that we (I?) don't forget adding the processDefaultTemplate after every processTemplate. Then again, it might be too much trouble for the few cases.
Assignee | ||
Comment 5•23 years ago
|
||
I originally did it that way (see attachment 34255 [details] [diff] [review]), but I wasn't quite happy with it. First of all I had to send |mode| to processTemplate which would only be used by the default-template code. Second, there is code that calls processTemplate but _should't_ invoke default templates (the code for xsl:call- template). So, could I convince you to the current flow?
Comment 6•23 years ago
|
||
r=peterv.
Updated•23 years ago
|
Whiteboard: Fix in hand. Have r=peterv. Need sr=, a=.
Target Milestone: --- → mozilla0.9.2
Comment 7•23 years ago
|
||
sr=jst
Comment 8•23 years ago
|
||
a= asa@mozilla.org for checkin to the trunk. (on behalf of drivers)
Blocks: 83989
Assignee | ||
Comment 9•23 years ago
|
||
checked in
Status: ASSIGNED → RESOLVED
Closed: 23 years ago
Keywords: review
Resolution: --- → FIXED
Whiteboard: Fix in hand. Have r=peterv. Need sr=, a=.
You need to log in
before you can comment on or make changes to this bug.
Description
•