d3697a6c3945a62c5868a9217dc7b32484f4e4d0
[WebKit-https.git] / WebCore / ChangeLog
1 2006-08-17  David Harrison  <harrison@apple.com>
2
3         Reviewed by Maciej.
4
5         <rdar://problem/4527201> REGRESSION: AXTextMarkerRangeForUnorderedTextMarkers returns out of order range
6
7         Test cases added: None.  Manual AX testing is way too awkward, and automated testing
8         is not possible.  See following bug...
9             <rdar://problem/4256882> Need automated testing support for accessibility APIs
10
11         * bridge/mac/AXObjectCacheMac.mm:
12         (WebCore::AXObjectCache::visiblePositionForTextMarker):
13         Validate the marker by comparing the node and offset to those of the resulting VisiblePosition.
14
15 2006-08-17  Nikolas Zimmermann  <zimmermann@kde.org>
16
17         Reviewed by Anders.
18
19         Fixes: http://bugzilla.opendarwin.org/show_bug.cgi?id=10447
20         AffineTransform should be multi-platform compatible
21
22         * platform/AffineTransform.h:
23         * platform/cg/AffineTransformCG.cpp:
24         (WebCore::AffineTransform::m11):
25         (WebCore::AffineTransform::m12):
26         (WebCore::AffineTransform::m21):
27         (WebCore::AffineTransform::m22):
28         (WebCore::AffineTransform::dx):
29         (WebCore::AffineTransform::dy):
30
31 2006-08-16  David Hyatt  <hyatt@apple.com>
32
33         Fix an issue with CSS2 system fonts where they did not respect text
34         zoom.  This was most visible with the new control fonts used for form
35         controls (they stopped swapping between small/mini/regular as you zoomed).
36
37         Reviewed by beth
38
39         * css/cssstyleselector.cpp:
40         (WebCore::CSSStyleSelector::applyProperty):
41
42 2006-08-15  Justin Garcia  <justin.garcia@apple.com>
43
44         Reviewed by thatcher
45         
46         First part of fix for:
47         <rdar://problem/4384589>
48         Mail hung on paste text
49         
50         Fixes:
51         <http://bugzilla.opendarwin.org/show_bug.cgi?id=8592>
52         Extra line left after deleting whitespace:pre text
53         <rdar://problem/4128080> Paste as HTML does not yield equivalent style
54         <rdar://problem/4046469> Box styles on first element aren't copied/pasted
55         Copy/paste of arstechnica.com
56         
57         Here's how we avoid adding redundant style information on paste: insert 
58         the fragment and do a test rendering, save away style information for 
59         every node in the fragment, remove all style information from the fragment, 
60         remove the fragment, insert it into the appropriate place in the document, 
61         then restore only those styles gathered during the test insertion that aren't
62         redundant.  Restoring the styles in this way results in an ApplyStyleCommand 
63         and a layout for nearly every inserted node.  
64         Instead we want to insert the fragment into the document without removing the 
65         style information, then mark style nodes and inline style declarations for 
66         removal if they are redundant, and sweep to remove them.  This means that we 
67         can't rely on ReplacementFragment::wasBlock anymore, because blocks will now 
68         have style spans around them.  This patch removes the use of wasBlock in 
69         ReplaceSelectionCommand.
70         
71         * editing/CompositeEditCommand.cpp:
72         (WebCore::CompositeEditCommand::moveParagraphs): Added code
73         to remove the line placeholder left after a move from preserveNewline text.
74         * editing/DeleteSelectionCommand.cpp:
75         (WebCore::DeleteSelectionCommand::doApply): Don't add a placeholder if 
76         we're deleting a paragraph in preserveNewline text.
77         * editing/JSEditor.cpp: Pass true to prevent nesting.
78         * editing/ReplaceSelectionCommand.cpp: Removed wasBlock and friends.
79         (WebCore::ReplacementFragment::ReplacementFragment): Ditto.
80         (WebCore::ReplacementFragment::saveRenderingInfo): Ditto.
81         (WebCore::RenderingInfo::RenderingInfo): Ditto.
82         (WebCore::ReplaceSelectionCommand::ReplaceSelectionCommand):
83         (WebCore::ReplaceSelectionCommand::shouldMergeStart): Combined the to/from
84         merging rules into one method.
85         (WebCore::ReplaceSelectionCommand::shouldMergeEnd):
86         (WebCore::ReplaceSelectionCommand::shouldMerge):
87         (WebCore::ReplaceSelectionCommand::doApply): 
88         Don't do nesting prevention when pasting into an empty paragraph, this
89         fixes 4046469, the common cause of paste fidelity bugs, but needs
90         to be tweaked a little because this can lead to margin/border build-up
91         on repeated copy/pastes.
92         Don't track startPos in addition to insertionPos.  It was never used.
93         Fixed a bug where a fragment starting with an interchange newline would
94         cause content to be put outside of an editable region when pasting at the 
95         very end of it.
96         Adjust insertionPos before insertion (not during) and do not consult wasBlock
97         to decide whether or not to do so.
98         Changed the way we do the start merge: insert the fragment, then stich 
99         paragraphs together, in the same way that we do the end merge.  This 
100         doesn't require wasBlock and fixes bugs.
101         Replaced some uses of insertionPos with endOfInsertedContent.
102         Fixed a bug in the expansion of the last incoming br (a "collapsed" br
103         is one where !isStartOfParagraph([br,0])).
104         Removed the special case code that did the end merge for the preserveNewline 
105         case, since this patch fixes the moveParagraph bug in the preserveNewline case.
106         Removed some unused variables.
107         (WebCore::ReplaceSelectionCommand::shouldRemoveEndBR): An endBR that was 
108         holding a line open should always be displaced by inserted content, unless 
109         the inserted content ends with a br.
110         (WebCore::ReplaceSelectionCommand::updateNodesInserted):
111         * editing/ReplaceSelectionCommand.h:
112         (WebCore::RenderingInfo::style):
113         * editing/markup.cpp:
114         (WebCore::createMarkup): Only add mail blockquotes and list/table/pre when
115         annotate is true (when we're creating markup for the pasteboard).
116
117 2006-08-16  John Sullivan  <sullivan@apple.com>
118
119         Reviewed by Brady Eidson
120         
121         - fixed <rdar://problem/4637156> underlines appearing in white selection text
122
123         * rendering/InlineFlowBox.cpp:
124         (WebCore::InlineFlowBox::paintDecorations):
125         bail out if phase is PaintPhaseSelection and forceWhiteText is true
126
127 2006-08-16  Brady Eidson  <beidson@apple.com>
128
129         Reviewed by John
130
131         Updated the DB version number and added a helpful comment explaining its meaning
132
133         * loader/icon/IconDatabase.cpp:
134
135 2006-08-16  Brady Eidson  <beidson@apple.com>
136
137         Reviewed by Maciej
138
139         Major refactoring of new iconDB:
140         -Instead of private browsing being handled by in-memory tables, it's now handled
141          by a separate in-memory database with the same table names.  This allows us to 
142          re-use the same SQL on either the main or private-browsing database
143         -So it follows, I broke out much of the SQL queries into seperate methods suffixed with
144          "Query" that take a database as the method's argument so the same language can run on
145          both private and main tables
146         -Now that we have two DBs, moved the retain/release count to the m_mainDB
147         -While I was at it, updated the schema to combine the Icon and IconResource table - cuts 
148          down on some high-usage, low value queries which were too expensive
149         -Ditched the _url -> url convention for escaping urls for SQL.  Now its url and escapedURL
150         -Pruned tons of unused methods from previous revisions
151
152      * bridge/mac/WebCoreIconDatabaseBridge.h: Removed isIconExpiredForPageURL as it was never used 
153         * bridge/mac/WebCoreIconDatabaseBridge.mm: Ditto
154         * loader/icon/IconDatabase.cpp:
155         (WebCore::IconDatabase::IconDatabase): Updated initializer list
156         (WebCore::IconDatabase::open): Sets up both databases
157         (WebCore::IconDatabase::close): Closes both databases
158         (WebCore::IconDatabase::isEmpty): Queries both databases for at least 1 record
159         (WebCore::IconDatabase::isValidDatabase): Reflect the updated schema
160         (WebCore::IconDatabase::clearDatabaseTables): Ditto - and takes DB as a parameter
161         (WebCore::IconDatabase::createDatabaseTables): Ditto
162         (WebCore::IconDatabase::imageDataForIconURL): style cleanup, and using a query-function
163         (WebCore::IconDatabase::setPrivateBrowsingEnabled): Resets private DB instead of private tables
164         (WebCore::IconDatabase::isIconExpiredForIconURL): Uses a query-function on each DB
165         (WebCore::IconDatabase::iconURLForPageURL): Uses a query-function on each DB
166         (WebCore::IconDatabase::retainIconForPageURL): Retain count DB changes 
167         (WebCore::IconDatabase::releaseIconForPageURL): Ditto
168         (WebCore::IconDatabase::isIconURLRetained): Determine if it's time to prune a released icon yet
169         (WebCore::IconDatabase::forgetIconForIconURLFromDatabase): Alot simpler
170         (WebCore::IconDatabase::setIconDataForIconURL): Style cleanup
171         (WebCore::IconDatabase::setHaveNoIconForIconURL): Ditto
172         (WebCore::IconDatabase::setIconURLForPageURL): Ditto - and using a query-function
173         (WebCore::IconDatabase::establishIconIDForIconURL): Style cleanup
174         (WebCore::IconDatabase::pruneUnreferencedIcons): DB name change
175         (WebCore::IconDatabase::pruneUnretainedIcons): Ditto
176         (WebCore::IconDatabase::hasIconForIconURL): Simpler, using a query-function
177         (WebCore::IconDatabase::~IconDatabase):
178         (WebCore::pageURLTableIsEmptyQuery): Self-explanatory SQL query
179         (WebCore::imageDataForIconURLQuery): Self-explanatory SQL query
180         (WebCore::timeStampForIconURLQuery): Self-explanatory SQL query
181         (WebCore::iconURLForPageURLQuery): Self-explanatory SQL query
182         (WebCore::forgetPageURLQuery): Self-explanatory SQL query
183         (WebCore::setIconIDForPageURLQuery): Self-explanatory SQL query
184         (WebCore::getIconIDForIconURLQuery): Self-explanatory SQL query
185         (WebCore::addIconForIconURLQuery): Self-explanatory SQL query
186         (WebCore::hasIconForIconURLQuery): Self-explanatory SQL query
187      * loader/icon/IconDatabase.h: Some new/changed methods, pruned methods, and new comments
188         (WebCore::IconDatabase::isOpen):  Changed our meaning of "isOpen" to reflect the 2 databases
189
190 2006-08-15  Jonas Witt <jonas.witt@gmail.com>
191
192         Reviewed by Darin.
193
194         - added ObjC wrappers for the KeyboardEvent and WheelEvent initializers
195           http://bugzilla.opendarwin.org/show_bug.cgi?id=9736
196
197         * bindings/objc/DOMEvents.mm:
198         (-[DOMKeyboardEvent initKeyboardEvent::::::::::]):
199         * bindings/objc/DOMEventsNonstandard.mm:
200         (-[DOMWheelEvent initWheelEvent:::::::::::]):
201         * bindings/objc/DOMPrivate.h:
202
203         - added an initializer for the WheelEvent
204
205         * dom/WheelEvent.cpp:
206         (WebCore::WheelEvent::initWheelEvent):
207         * dom/WheelEvent.h:
208
209 2006-08-15  Mark Rowe  <opendarwin.org@bdash.net.nz>
210
211         Reviewed by Tim H.
212
213         Build fix:  DWARF and -gfull are incompatible with symbol separation.
214
215         * WebCore.xcodeproj/project.pbxproj:
216
217 2006-08-15  Mark Rowe  <opendarwin.org@bdash.net.nz>
218
219         Reviewed by Tim H.
220
221         http://bugzilla.opendarwin.org/show_bug.cgi?id=10394
222         Bug 10394: WebKit Release and Production configurations should enable dead code stripping
223
224         * WebCore.xcodeproj/project.pbxproj:
225
226 2006-08-15  Geoffrey Garen  <ggaren@apple.com>
227
228         Reviewed by Darin.
229         
230         - This patch reworks a previous fix for <rdar://problem/3524912> repro 
231         crash in KHTMLParser::parseToken, due to parser's current element being 
232         destroyed (www.gnnetcom.dk), along with subsequent adjustments to fix
233         leaks.
234         
235         The previous solutions caused a ~2% performance regression on iBench HTML,
236         due to RefPtr churn. The optimizations here gain back that ~2% plus ~1% more,
237         for a total win of ~3% vs current TOT.
238         
239         We can merge this fix to the branch to fix <rdar://problem/4661982> 
240         (crash in KHTMLParser::popBlock).
241         
242         The solution here is:
243         (1) Don't let the parser ref document nodes -- that causes leaks.
244         (2) Handle ref/deref manually, to avoid RefPtr churn. Specifically, when 
245         moving a node between stacks or to/from 'current', rather than deref'ing
246         and then ref'ing again, simply move the node, along with its refcount, to
247         its new location, and overwrite its old location.
248  
249         * WebCore.xcodeproj/project.pbxproj:
250         * html/HTMLParser.cpp:
251         (WebCore::HTMLStackElem::HTMLStackElem):
252         (WebCore::HTMLStackElem::derefNode):
253         (WebCore::HTMLParser::HTMLParser):
254         (WebCore::HTMLParser::setCurrent):
255         (WebCore::HTMLParser::insertNode):
256         (WebCore::HTMLParser::popNestedHeaderTag):
257         (WebCore::HTMLParser::handleResidualStyleCloseTagAcrossBlocks):
258         (WebCore::HTMLParser::reopenResidualStyleTags):
259         (WebCore::HTMLParser::pushBlock):
260         (WebCore::HTMLParser::popBlock):
261         (WebCore::HTMLParser::popOneBlockCommon):
262         (WebCore::HTMLParser::popOneBlock):
263         (WebCore::HTMLParser::moveOneBlockToStack):
264         * html/HTMLParser.h:
265
266 2006-08-15  Mark Rowe  <opendarwin.org@bdash.net.nz>
267
268         Reviewed by Tim H.
269
270         http://bugzilla.opendarwin.org/show_bug.cgi?id=10384
271         Bug 10384: Switch to DWARF for Release configuration
272
273         * WebCore.xcodeproj/project.pbxproj:
274
275 2006-08-15  Mark Rowe  <opendarwin.org@bdash.net.nz>
276
277         Reviewed by Hyatt.
278         Tweaked and landed by Darin.
279
280         http://bugzilla.opendarwin.org/show_bug.cgi?id=10399
281         Bug 10399: RenderTextArea is unused
282
283         * WebCore.vcproj/WebCore/WebCore.vcproj:
284         * WebCore.xcodeproj/project.pbxproj:
285         * WebCoreSources.bkl:
286         Removed RenderTextArea source files.
287
288         * html/HTMLTextAreaElement.cpp: Removed include of RenderTextArea.h.
289         * html/HTMLTextAreaElement.h: Removed forward declaration of RenderTextArea.
290
291         * platform/mac/WidgetMac.mm: (WebCore::Widget::paint): Updated a comment.
292
293         * platform/TextBox.h: Removed.
294         * platform/mac/TextBoxMac.mm: Removed.
295         * platform/mac/WebCoreTextArea.h: Removed.
296         * platform/mac/WebCoreTextArea.mm: Removed.
297         * rendering/RenderTextArea.cpp: Removed.
298         * rendering/RenderTextArea.h: Removed.
299
300 2006-08-15  Brady Eidson  <beidson@apple.com>
301
302         Reviewed by THE OTHER Maciej...
303
304         Two small fixes -
305         1) Renamed retain/release methods to add PageUrl in - we're being consistent and clear in the WebCore API
306         2) Fixed a bug where a null SiteIcon reference would be added into the pageURLToSiteIcon map causing a
307         null dereference later
308
309         * bridge/mac/WebCoreIconDatabaseBridge.mm:
310         (-[WebCoreIconDatabaseBridge retainIconForURL:]):  Changed IconDatabase method name
311         (-[WebCoreIconDatabaseBridge releaseIconForURL:]):  ditto
312         * loader/icon/IconDatabase.cpp:
313         (WebCore::IconDatabase::retainIconForPageURL):  Name change
314         (WebCore::IconDatabase::releaseIconForPageURL):  ditto
315         (WebCore::IconDatabase::setIconURLForPageURL):  Added the null site-icon check when changing a PageURL's iconURL
316         * loader/icon/IconDatabase.h:  Some renames
317
318 2006-08-14  Eric Seidel  <eric@eseidel.com>
319
320         Reviewed by mjs.
321
322         <mask>, <marker>, <pattern> inside <defs> do not work
323         http://bugzilla.opendarwin.org/show_bug.cgi?id=6548
324
325         * ksvg2/svg/SVGDefsElement.cpp:
326         (WebCore::SVGDefsElement::SVGDefsElement): moved to .cpp file
327         (WebCore::SVGDefsElement::isValid): moved to .cpp file
328         (WebCore::SVGDefsElement::rendererIsNeeded): Added.
329         (WebCore::SVGDefsElement::createRenderer): Added.
330         * ksvg2/svg/SVGDefsElement.h:
331         * ksvg2/svg/SVGGElement.cpp:
332         (WebCore::SVGGElement::SVGGElement): adjusted spacing
333         (WebCore::SVGGElement::parseMappedAttribute): adjusted spacing
334         (WebCore::SVGDummyElement::SVGDummyElement): adjusted spacing
335
336 2006-08-14  Eric Seidel  <eric@eseidel.com>
337
338         Reviewed by darin and mjs.
339         
340         Add better SVGLoad event support.
341         http://bugzilla.opendarwin.org/show_bug.cgi?id=6010
342         There will still need to be additional support added for <link> and <script> elements.
343         Not all of the error -> loaded -> error transition cases work yet.
344
345         * dom/EventTargetNode.cpp:
346         (WebCore::EventTargetNode::dispatchGenericEvent):
347         * html/HTMLImageLoader.cpp:
348         (WebCore::HTMLImageLoader::dispatchLoadEvent):
349         * html/HTMLImageLoader.h:
350         (WebCore::HTMLImageLoader::haveFiredLoadEvent):
351         (WebCore::HTMLImageLoader::setHaveFiredLoadEvent):
352         * ksvg2/misc/SVGImageLoader.cpp:
353         (WebCore::SVGImageLoader::SVGImageLoader):
354         (WebCore::SVGImageLoader::dispatchLoadEvent):
355         * ksvg2/misc/SVGImageLoader.h:
356         * ksvg2/svg/SVGAElement.cpp:
357         (WebCore::SVGAElement::parseMappedAttribute):
358         * ksvg2/svg/SVGAnimatedBoolean.h:
359         * ksvg2/svg/SVGElement.cpp:
360         (WebCore::SVGElement::SVGElement):
361         (WebCore::SVGElement::parseMappedAttribute):
362         (WebCore::SVGElement::haveLoadedRequiredResources):
363         (WebCore::SVGElement::sendSVGLoadEventIfPossible):
364         (WebCore::SVGElement::closeRenderer):
365         * ksvg2/svg/SVGElement.h:
366         (WebCore::SVGElement::rendererIsNeeded):
367         (WebCore::svg_dynamic_cast):
368         * ksvg2/svg/SVGExternalResourcesRequired.h:
369         * ksvg2/svg/SVGImageElement.cpp:
370         (SVGImageElement::SVGImageElement):
371         (SVGImageElement::haveLoadedRequiredResources):
372         * ksvg2/svg/SVGImageElement.h:
373         * ksvg2/svg/SVGSVGElement.cpp:
374         (WebCore::SVGSVGElement::parseMappedAttribute):
375         * ksvg2/svg/SVGScriptElement.cpp:
376         (WebCore::SVGScriptElement::SVGScriptElement):
377         (WebCore::SVGScriptElement::parseMappedAttribute):
378         (WebCore::SVGScriptElement::executeScript):
379         * xml/xmlhttprequest.cpp:
380         (WebCore::XMLHttpRequest::callReadyStateChangeListener): use new Event() instead of createEvent
381
382 2006-08-14  Anders Carlsson  <acarlsson@apple.com>
383
384         Reviewed by Maciej.
385
386         http://bugzilla.opendarwin.org/show_bug.cgi?id=10393
387         Autogenerate NodeIterator and TreeWalker.
388         
389         * DerivedSources.make:
390         * WebCore.xcodeproj/project.pbxproj:
391         Add new files.
392         
393         * bindings/js/JSNodeIteratorCustom.cpp: Added.
394         (WebCore::JSNodeIterator::mark):
395         * bindings/js/JSTreeWalkerCustom.cpp: Added.
396         (WebCore::JSTreeWalker::mark):
397         
398         * bindings/js/kjs_traversal.cpp:
399         * bindings/js/kjs_traversal.h:
400         Remove implementations of DOMNodeIterator and DOMTreeWalker.
401
402         * bindings/scripts/CodeGeneratorJS.pm:
403         Add "CustomMarkFunction" attribute for classes where mark() needs to be overridden.
404         
405         * bindings/objc/DOM.mm:
406         (-[DOMNodeIterator detach]):
407         * dom/NodeIterator.cpp:
408         (WebCore::NodeIterator::detach):
409         * dom/NodeIterator.h:
410         Get rid of exception in detach, it isn't used at all and this function can't throw an exception according to the spec.
411         * dom/NodeIterator.idl: Added.
412         * dom/TreeWalker.idl: Added.
413
414 2006-08-14  Brady Eidson  <beidson@apple.com>
415
416         Reviewed by John
417
418         The changes are plentiful, but small, mostly to improve performance
419         1) Add a bool flag to SiteIcon to stop it from querying the database over and over
420         2) Added a pageURL->iconURL hashmap to cache database results, as an optimization
421         3) Fix a bug in setIconURLForPageURL code where the pageURL would still point to an old icon
422         4) Added isIconURLRetained() to optimize the retain count check
423         5) Prune old, unused code
424
425         * loader/icon/IconDatabase.cpp:
426         (WebCore::IconDatabase::imageDataForIconID): Removed unused code
427         (WebCore::IconDatabase::imageDataForIconURL): Removed unused code
428         (WebCore::IconDatabase::imageDataForPageURL): Removed unused code
429         (WebCore::IconDatabase::isIconExpiredForIconURL): Removed LOG msg
430         (WebCore::IconDatabase::isIconExpiredForPageURL): Removed LOG msg
431         (WebCore::IconDatabase::iconURLForPageURL): Added a hashmap cache to avoid common queries
432         (WebCore::IconDatabase::releaseIconForURL): Changed to is isRetained() instead of retainCount()
433         (WebCore::IconDatabase::isIconURLRetained): Added - we don't care about the actual retain count
434           for an icon so much as whether or not it is retained
435         (WebCore::IconDatabase::setIconURLForPageURL): If the new and old iconURLs are the same, skip the
436           SQLite code
437         * loader/icon/IconDatabase.h:  Added new methods/variables
438         * loader/icon/SiteIcon.cpp:
439         (SiteIcon::SiteIcon): Added a flag so it only queries the database for icon data once
440         (SiteIcon::getImage): Ditto
441
442 2006-08-14  David Hyatt  <hyatt@apple.com>
443
444         Fix for bug 10385, add more support for crappy pseudo-XML-in-HTML.
445
446         Reviewed by ggaren
447
448         Added fast/parser/bad-xml-slash.html
449
450         * html/HTMLTokenizer.cpp:
451         (WebCore::HTMLTokenizer::parseTag):
452
453 2006-08-14  Darin Adler  <darin@apple.com>
454
455         Reviewed by John Sullivan.
456
457         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=10204
458           REGRESSION: title tag parsing problem breaks Travelocity and Google Analytics pages
459
460         Test: fast/parser/title-error-test.html
461
462         * html/HTMLParser.cpp: (WebCore::HTMLParser::handleError): Fixed an error
463         handling case that was skipping until a </style> tag in code that was shared
464         between both <title> and <style>. Also rearranged the code a tiny bit.
465
466 2006-08-14  Darin Adler  <darin@apple.com>
467
468         Reviewed by Hyatt.
469
470         - fixed some storage leaks
471           (part of http://bugzilla.opendarwin.org/show_bug.cgi?id=10259)
472
473         * platform/mac/ResourceLoaderMac.mm: (WebCore::ResourceLoader::start):
474         Rearrange code so that "delete this" is called any time the function returns
475         false -- ownership was inconsistent before.
476
477         * rendering/RenderContainer.cpp: (WebCore::RenderContainer::removeChildNode):
478         Call deleteLineBoxWrapper even when documentBeingDestroyed() is true, because
479         some of what it does has to be done during destruction. A little awkward since
480         I preserved the order of operations. Perhaps we could structure this better later.
481
482 2006-08-14  David Harrison  <harrison@apple.com>
483
484         Reviewed by John Sullivan and Geoff Garen.
485
486         <rdar://problem/3854950> AX Seed: Blackboard Learning Systems - frame names need to be put in AXDescription AXAttribute
487
488         Test cases added: None.  Manual AX testing is way too awkward, and automated testing
489         is not possible.  See following bug...
490             <rdar://problem/4256882> Need automated testing support for accessibility APIs
491
492         * bridge/mac/WebCoreAXObject.mm:
493         (-[WebCoreAXObject accessibilityDescription]):
494         For a web area, return the name of the owning frame or iframe.
495         
496         (-[WebCoreAXObject accessibilityAttributeNames]):
497         Advertize NSAccessibilityDescriptionAttribute.
498         
499         (-[WebCoreAXObject rendererForView:]):
500         Clean up some old naming.
501
502 2006-08-11  Anders Carlsson  <acarlsson@apple.com>
503
504         Reviewed by Darin.
505
506         http://bugzilla.opendarwin.org/show_bug.cgi?id=10353
507         XMLSerializer and DOMParser should have real implementations
508         
509         Make real implementation files for DOMParser and XMLSerializer and wrap them
510         using our bindings generation.
511         
512         * DerivedSources.make:
513         * WebCore.xcodeproj/project.pbxproj:
514         * bindings/js/JSDOMParser.cpp: Removed.
515         * bindings/js/JSDOMParser.h: Removed.
516         * bindings/js/JSXMLSerializer.cpp: Removed.
517         * bindings/js/JSXMLSerializer.h: Removed.
518         * bindings/js/kjs_window.cpp:
519         (KJS::Window::getValueProperty):
520         * bindings/js/kjs_window.h:
521         (KJS::Window::):
522         * page/DOMWindow.idl:
523         * xml/DOMParser.cpp: Added.
524         (WebCore::DOMParser::parseFromString):
525         * xml/DOMParser.h: Added.
526         * xml/DOMParser.idl: Added.
527         * xml/XMLSerializer.cpp: Added.
528         (WebCore::XMLSerializer::serializeToString):
529         * xml/XMLSerializer.h: Added.
530         * xml/XMLSerializer.idl: Added.
531
532 2006-08-14  Maciej Stachowiak  <mjs@apple.com>
533
534         Reviewed by Brady.
535
536         - removed WebKit-level dependencies from WebFormDataStream. Use WebCore version of system interface
537
538         * WebCore.exp: export new functions
539         * platform/mac/WebCoreSystemInterface.h: Added CFReadStream related functions
540         * platform/mac/WebCoreSystemInterface.mm: ditto
541
542 2006-08-13  Maks Orlovich  <maksim@kde.org>
543
544         Reviewed (and tweaked a little) by Maciej.
545         
546         - shrank the size of JSObject by 8 bytes and made the corresponding reduction to the cell size, resulting
547         in a 1.2% speed improvement on JS iBench (and probably overall memory savings).
548
549         The WebCore part of this is to expect only FunctionImp to have a scope, not all JSObjects.
550         
551         * bindings/js/kjs_events.cpp:
552         (KJS::JSLazyEventListener::parseCode):
553
554 2006-08-12  Eric Seidel  <eric@eseidel.com>
555
556         Reviewed by hyatt and mjs.
557
558         Fix two missing null checks causing layout test crashes.
559
560         * css/cssstyleselector.cpp:
561         (WebCore::CSSStyleSelector::adjustRenderStyle): check e for null (null for pseudo styles)
562         * kcanvas/RenderSVGContainer.cpp:
563         (WebCore::RenderSVGContainer::requiresLayer): check parent()->element() for null
564
565
566 2006-08-11  Eric Seidel  <eric@eseidel.com>
567
568         Reviewed by andersca.
569
570         The outermost <svg> element needs to clip itself
571         http://bugzilla.opendarwin.org/show_bug.cgi?id=5358
572
573         * css/cssstyleselector.cpp:
574         (WebCore::CSSStyleSelector::adjustRenderStyle): adjust for SVG overflow rules
575         * kcanvas/RenderSVGContainer.cpp:
576         (WebCore::RenderSVGContainer::requiresLayer): only require layers for absolute/relative positioning of outermost SVG
577         (WebCore::RenderSVGContainer::paint):
578         * kcanvas/device/KRenderingDevice.h:
579         * kcanvas/device/quartz/KRenderingDeviceQuartz.h: remove dead methods
580         * kcanvas/device/quartz/KRenderingDeviceQuartz.mm: remove dead methods
581         (WebCore::KRenderingDeviceContextQuartz::KRenderingDeviceContextQuartz):
582         * ksvg2/svg/SVGPaint.cpp: spacing changes
583         (WebCore::SVGPaint::SVGPaint): spacing cleanup
584         * ksvg2/svg/SVGSVGElement.cpp:
585         (WebCore::SVGSVGElement::parseMappedAttribute): spacing cleanup
586         * platform/GraphicsContext.h: Added concatCTM
587         * platform/cg/GraphicsContextCG.cpp:
588         (WebCore::GraphicsContext::concatCTM): Added.
589
590 2006-08-11  Brady Eidson  <beidson@apple.com>
591
592         Reviewed by Maciej
593
594         Renamed a method/parameter for clarity and consistency, as well as some style
595         cleanups and removing some ridiculously verbose log messages.
596         Also added an _isEmpty method to the database and bridge for WebKit's use.
597         Finally, added a central way for both WebKit and WebCore to get the icon database filename
598
599         * bridge/mac/WebCoreIconDatabaseBridge.h:  Added _isEmpty and defaultDatabaseFilename
600         * bridge/mac/WebCoreIconDatabaseBridge.mm:  Removed an unnecessary semicolon off most of these methods
601         (-[WebCoreIconDatabaseBridge openSharedDatabaseWithPath:]):
602         (-[WebCoreIconDatabaseBridge closeSharedDatabase]):
603         (-[WebCoreIconDatabaseBridge isOpen]):
604         (-[WebCoreIconDatabaseBridge _isEmpty]):  Added
605         (-[WebCoreIconDatabaseBridge setPrivateBrowsingEnabled:]):
606         (-[WebCoreIconDatabaseBridge privateBrowsingEnabled]):
607         (-[WebCoreIconDatabaseBridge iconForPageURL:withSize:]):
608         (-[WebCoreIconDatabaseBridge iconURLForPageURL:]):
609         (-[WebCoreIconDatabaseBridge defaultIconWithSize:]):
610         (-[WebCoreIconDatabaseBridge retainIconForURL:]):
611         (-[WebCoreIconDatabaseBridge releaseIconForURL:]):
612         (-[WebCoreIconDatabaseBridge _setIconData:forIconURL:]):
613         (-[WebCoreIconDatabaseBridge _setHaveNoIconForIconURL:]):
614         (-[WebCoreIconDatabaseBridge _setIconURL:forPageURL:]):
615         (-[WebCoreIconDatabaseBridge _hasIconForIconURL:]):
616         (-[WebCoreIconDatabaseBridge defaultDatabaseFilename]):  Added
617
618         * loader/icon/IconDatabase.cpp:
619         (WebCore::IconDatabase::defaultDatabaseFilename):  Added
620         (WebCore::IconDatabase::open):  
621         (WebCore::IconDatabase::isEmpty):  Added
622         (WebCore::IconDatabase::retainIconForURL):  Removed log message
623         (WebCore::IconDatabase::releaseIconForURL):  Removed log message
624         * loader/icon/IconDatabase.h: 
625
626 2006-08-11  David Hyatt  <hyatt@apple.com>
627
628         Eliminate RenderImageButton.
629
630         Reviewed by darin
631
632         * WebCore.xcodeproj/project.pbxproj:
633         * bridge/mac/WebCoreAXObject.mm:
634         (-[WebCoreAXObject isImageButton]):
635         * html/HTMLInputElement.cpp:
636         (WebCore::HTMLInputElement::createRenderer):
637         * rendering/RenderImage.h:
638         (WebCore::RenderImage::isImage):
639
640 2006-08-11  Adele Peterson  <adele@apple.com>
641
642         Reviewed by Brady.
643
644         - Fix for <rdar://problem/4656274> 
645         REGRESSION: option elements are selected when added regardless of "selected" property
646
647         Test: fast/forms/option-constructor-selected.html
648
649         * html/HTMLSelectElement.cpp: (WebCore::HTMLSelectElement::setOption):
650         When adding an option element, check that the option element is selected before calling setSelectedIndex.
651
652 2006-08-11  David Hyatt  <hyatt@apple.com>
653
654         Fix for bug 10349, make sure to call setChanged when an anchor changes
655         from not being a link to being a link (and vice versa).
656
657         Test is in fast/dynamic/link-href-change.html
658
659         Reviewed by darin
660
661         * html/HTMLAnchorElement.cpp:
662         (WebCore::HTMLAnchorElement::HTMLAnchorElement):
663         (WebCore::HTMLAnchorElement::parseMappedAttribute):
664         * html/HTMLAnchorElement.h:
665         * html/HTMLAreaElement.cpp:
666         (WebCore::HTMLAreaElement::parseMappedAttribute):
667
668 2006-08-09  Rob Buis  <buis@kde.org>
669
670         Reviewed by Darin.
671
672         Revert an over-optimization step that messed up the HashSet lookup.
673
674         * dom/DOMImplementation.cpp:
675
676 2006-08-12  Oliver  <ojh16@student.canterbury.ac.nz>
677
678         Rubber stamped by tim
679
680         Removed commented out code
681
682         * kcanvas/RenderSVGImage.cpp:
683         (WebCore::RenderSVGImage::paint):
684
685 2006-08-12  Oliver  <ojh16@student.canterbury.ac.nz>
686
687         Reviewed by geoff
688
689         Fixed regression in SVG image layout
690         (see bug #10346)
691
692         * kcanvas/RenderSVGImage.cpp:
693         (WebCore::RenderSVGImage::paint):
694
695 2006-08-10  Anders Carlsson  <acarlsson@apple.com>
696
697         Rubber-stamped by Maciej.
698
699         Move xpath to xml.
700         
701         * DerivedSources.make:
702         * WebCore.vcproj/WebCore/WebCore.vcproj:
703         * WebCore.xcodeproj/project.pbxproj:
704         * xpath/XPathEvaluator.cpp: Removed.
705         * xpath/XPathEvaluator.h: Removed.
706         * xpath/XPathEvaluator.idl: Removed.
707         * xpath/XPathExpression.cpp: Removed.
708         * xpath/XPathExpression.h: Removed.
709         * xpath/XPathExpression.idl: Removed.
710         * xpath/XPathNSResolver.cpp: Removed.
711         * xpath/XPathNSResolver.h: Removed.
712         * xpath/XPathNSResolver.idl: Removed.
713         * xpath/XPathNamespace.cpp: Removed.
714         * xpath/XPathNamespace.h: Removed.
715         * xpath/XPathResult.cpp: Removed.
716         * xpath/XPathResult.h: Removed.
717         * xpath/XPathResult.idl: Removed.
718         * xpath/impl/XPathExpressionNode.cpp: Removed.
719         * xpath/impl/XPathExpressionNode.h: Removed.
720         * xpath/impl/XPathFunctions.cpp: Removed.
721         * xpath/impl/XPathFunctions.h: Removed.
722         * xpath/impl/XPathGrammar.y: Removed.
723         * xpath/impl/XPathParser.cpp: Removed.
724         * xpath/impl/XPathParser.h: Removed.
725         * xpath/impl/XPathPath.cpp: Removed.
726         * xpath/impl/XPathPath.h: Removed.
727         * xpath/impl/XPathPredicate.cpp: Removed.
728         * xpath/impl/XPathPredicate.h: Removed.
729         * xpath/impl/XPathStep.cpp: Removed.
730         * xpath/impl/XPathStep.h: Removed.
731         * xpath/impl/XPathUtil.cpp: Removed.
732         * xpath/impl/XPathUtil.h: Removed.
733         * xpath/impl/XPathValue.cpp: Removed.
734         * xpath/impl/XPathValue.h: Removed.
735         * xpath/impl/XPathVariableReference.cpp: Removed.
736         * xpath/impl/XPathVariableReference.h: Removed.
737
738 2006-08-10  David Harrison  <harrison@apple.com>
739
740         Reviewed by John Sullivan.
741
742         <rdar://problem/4600112> REGRESSION: VO no longer able to review text within an edit field on web pages
743
744         Test cases added: None.  Manual AX testing is way too awkward, and automated testing
745         is not possible.  See following bug...
746             <rdar://problem/4256882> Need automated testing support for accessibility APIs
747
748         * bridge/mac/WebCoreAXObject.mm:
749         (-[WebCoreAXObject value]):
750         Add handling for text input fields.
751
752 2006-08-09  Graham Dennis  <graham.dennis@gmail.com>
753
754         Reviewed by Darin.
755
756         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=10247
757         REGRESSION: Unable to build webkit without SVG/XPATH
758
759         * bindings/js/kjs_binding.cpp:
760         (KJS::setDOMException):
761         * bindings/js/kjs_dom.cpp:
762         (KJS::toJS):
763         * bindings/js/kjs_html.cpp:
764         (KJS::HTMLElementFunction::callAsFunction):
765         * bindings/js/kjs_proxy.cpp:
766         * bindings/js/kjs_proxy.h:
767         * bindings/objc/DOMInternal.h:
768         * bindings/objc/DOMInternal.mm:
769         (raiseDOMException):
770         * bindings/objc/DOMXPath.mm:
771         * bindings/objc/DOMXPathInternal.h:
772         * bindings/scripts/CodeGeneratorJS.pm:
773         * bridge/mac/WebCoreFrameBridge.mm:
774         (+[WebCoreFrameBridge supportedNonImageMIMETypes]):
775         * css/CSSGrammar.y:
776         * css/CSSStyleDeclaration.cpp:
777         (WebCore::propertyID):
778         * css/cssparser.cpp:
779         (WebCore::CSSParser::parseValue):
780         * css/cssparser.h:
781         * css/cssstyleselector.cpp:
782         (WebCore::CSSStyleSelector::loadDefaultStyle):
783         (WebCore::CSSStyleSelector::applyProperty):
784         * css/cssstyleselector.h:
785         * dom/Document.cpp:
786         (WebCore::Document::Document):
787         (WebCore::Document::~Document):
788         (WebCore::Document::createElementNS):
789         (WebCore::Document::implicitClose):
790         (WebCore::Document::recalcStyleSelector):
791         (WebCore::Document::createEvent):
792         * dom/Document.h:
793         * dom/Document.idl:
794         * dom/Node.cpp:
795         (WebCore::Node::createRendererIfNeeded):
796         * dom/Node.h:
797         * dom/XMLTokenizer.cpp:
798         (WebCore::XMLTokenizer::endElementNs):
799         (WebCore::XMLTokenizer::insertErrorMessageBlock):
800         * html/HTMLEmbedElement.cpp:
801         * html/HTMLEmbedElement.h:
802         * html/HTMLObjectElement.cpp:
803         * html/HTMLObjectElement.h:
804         * kcanvas/KCanvasCreator.cpp:
805         * kcanvas/KCanvasCreator.h:
806         * kcanvas/KCanvasFilters.cpp:
807         * kcanvas/KCanvasFilters.h:
808         * kcanvas/KCanvasImage.h:
809         * kcanvas/KCanvasMatrix.cpp:
810         * kcanvas/KCanvasMatrix.h:
811         * kcanvas/KCanvasPath.cpp:
812         * kcanvas/KCanvasPath.h:
813         * kcanvas/KCanvasResourceListener.h:
814         * kcanvas/KCanvasResources.cpp:
815         * kcanvas/KCanvasResources.h:
816         * kcanvas/KCanvasTreeDebug.cpp:
817         * kcanvas/RenderForeignObject.cpp:
818         * kcanvas/RenderForeignObject.h:
819         * kcanvas/RenderPath.cpp:
820         * kcanvas/RenderPath.h:
821         * kcanvas/RenderSVGContainer.cpp:
822         * kcanvas/RenderSVGContainer.h:
823         * kcanvas/RenderSVGImage.cpp:
824         * kcanvas/RenderSVGImage.h:
825         * kcanvas/RenderSVGText.cpp:
826         * kcanvas/RenderSVGText.h:
827         * kcanvas/device/KRenderingDevice.cpp:
828         * kcanvas/device/KRenderingDevice.h:
829         * kcanvas/device/KRenderingFillPainter.cpp:
830         * kcanvas/device/KRenderingFillPainter.h:
831         * kcanvas/device/KRenderingPaintServer.h:
832         * kcanvas/device/KRenderingPaintServerGradient.cpp:
833         * kcanvas/device/KRenderingPaintServerGradient.h:
834         * kcanvas/device/KRenderingPaintServerPattern.cpp:
835         * kcanvas/device/KRenderingPaintServerPattern.h:
836         * kcanvas/device/KRenderingPaintServerSolid.cpp:
837         * kcanvas/device/KRenderingPaintServerSolid.h:
838         * kcanvas/device/KRenderingStrokePainter.cpp:
839         * kcanvas/device/KRenderingStrokePainter.h:
840         * kcanvas/device/quartz/KCanvasFilterQuartz.h:
841         * kcanvas/device/quartz/KCanvasFilterQuartz.mm:
842         * kcanvas/device/quartz/KCanvasItemQuartz.mm:
843         * kcanvas/device/quartz/KCanvasMaskerQuartz.mm:
844         * kcanvas/device/quartz/KCanvasPathQuartz.mm:
845         * kcanvas/device/quartz/KCanvasResourcesQuartz.mm:
846         * kcanvas/device/quartz/KRenderingDeviceQuartz.h:
847         * kcanvas/device/quartz/KRenderingDeviceQuartz.mm:
848         * kcanvas/device/quartz/KRenderingPaintServerGradientQuartz.mm:
849         * kcanvas/device/quartz/KRenderingPaintServerQuartz.mm:
850         * kcanvas/device/quartz/QuartzSupport.h:
851         * kcanvas/device/quartz/QuartzSupport.mm:
852         * ksvg2/bindings/js/JSSVGElementWrapperFactory.cpp:
853         * ksvg2/bindings/js/JSSVGElementWrapperFactory.h:
854         * ksvg2/css/SVGCSSParser.cpp:
855         * ksvg2/css/SVGCSSStyleSelector.cpp:
856         * ksvg2/css/SVGRenderStyle.cpp:
857         * ksvg2/css/SVGRenderStyle.h:
858         * ksvg2/css/SVGRenderStyleDefs.cpp:
859         * ksvg2/css/SVGRenderStyleDefs.h:
860         * ksvg2/ecma/GlobalObject.cpp:
861         * ksvg2/ecma/GlobalObject.h:
862         * ksvg2/events/JSSVGLazyEventListener.cpp:
863         * ksvg2/events/JSSVGLazyEventListener.h:
864         * ksvg2/events/SVGZoomEvent.cpp:
865         * ksvg2/events/SVGZoomEvent.h:
866         * ksvg2/ksvg.h:
867         * ksvg2/misc/KCanvasRenderingStyle.cpp:
868         * ksvg2/misc/KCanvasRenderingStyle.h:
869         * ksvg2/misc/KSVGTimeScheduler.cpp:
870         * ksvg2/misc/KSVGTimeScheduler.h:
871         * ksvg2/misc/SVGDocumentExtensions.cpp:
872         * ksvg2/misc/SVGDocumentExtensions.h:
873         * ksvg2/misc/SVGImageLoader.cpp:
874         * ksvg2/misc/SVGImageLoader.h:
875         * ksvg2/svg/DOMList.h:
876         * ksvg2/svg/SVGAElement.cpp:
877         * ksvg2/svg/SVGAElement.h:
878         * ksvg2/svg/SVGAngle.cpp:
879         * ksvg2/svg/SVGAngle.h:
880         * ksvg2/svg/SVGAnimateColorElement.cpp:
881         * ksvg2/svg/SVGAnimateColorElement.h:
882         * ksvg2/svg/SVGAnimateElement.cpp:
883         * ksvg2/svg/SVGAnimateElement.h:
884         * ksvg2/svg/SVGAnimateTransformElement.cpp:
885         * ksvg2/svg/SVGAnimateTransformElement.h:
886         * ksvg2/svg/SVGAnimatedAngle.cpp:
887         * ksvg2/svg/SVGAnimatedAngle.h:
888         * ksvg2/svg/SVGAnimatedBoolean.cpp:
889         * ksvg2/svg/SVGAnimatedBoolean.h:
890         * ksvg2/svg/SVGAnimatedColor.cpp:
891         * ksvg2/svg/SVGAnimatedColor.h:
892         * ksvg2/svg/SVGAnimatedEnumeration.cpp:
893         * ksvg2/svg/SVGAnimatedEnumeration.h:
894         * ksvg2/svg/SVGAnimatedInteger.cpp:
895         * ksvg2/svg/SVGAnimatedInteger.h:
896         * ksvg2/svg/SVGAnimatedLength.cpp:
897         * ksvg2/svg/SVGAnimatedLength.h:
898         * ksvg2/svg/SVGAnimatedLengthList.cpp:
899         * ksvg2/svg/SVGAnimatedLengthList.h:
900         * ksvg2/svg/SVGAnimatedNumber.cpp:
901         * ksvg2/svg/SVGAnimatedNumber.h:
902         * ksvg2/svg/SVGAnimatedNumberList.cpp:
903         * ksvg2/svg/SVGAnimatedNumberList.h:
904         * ksvg2/svg/SVGAnimatedPathData.cpp:
905         * ksvg2/svg/SVGAnimatedPathData.h:
906         * ksvg2/svg/SVGAnimatedPoints.cpp:
907         * ksvg2/svg/SVGAnimatedPoints.h:
908         * ksvg2/svg/SVGAnimatedPreserveAspectRatio.cpp:
909         * ksvg2/svg/SVGAnimatedPreserveAspectRatio.h:
910         * ksvg2/svg/SVGAnimatedRect.cpp:
911         * ksvg2/svg/SVGAnimatedRect.h:
912         * ksvg2/svg/SVGAnimatedString.cpp:
913         * ksvg2/svg/SVGAnimatedString.h:
914         * ksvg2/svg/SVGAnimatedTemplate.h:
915         * ksvg2/svg/SVGAnimatedTransformList.cpp:
916         * ksvg2/svg/SVGAnimatedTransformList.h:
917         * ksvg2/svg/SVGAnimationElement.cpp:
918         * ksvg2/svg/SVGAnimationElement.h:
919         * ksvg2/svg/SVGCircleElement.cpp:
920         * ksvg2/svg/SVGCircleElement.h:
921         * ksvg2/svg/SVGClipPathElement.cpp:
922         * ksvg2/svg/SVGClipPathElement.h:
923         * ksvg2/svg/SVGColor.cpp:
924         * ksvg2/svg/SVGColor.h:
925         * ksvg2/svg/SVGComponentTransferFunctionElement.cpp:
926         * ksvg2/svg/SVGComponentTransferFunctionElement.h:
927         * ksvg2/svg/SVGCursorElement.cpp:
928         * ksvg2/svg/SVGCursorElement.h:
929         * ksvg2/svg/SVGDOMImplementation.cpp:
930         * ksvg2/svg/SVGDOMImplementation.h:
931         * ksvg2/svg/SVGDefsElement.cpp:
932         * ksvg2/svg/SVGDefsElement.h:
933         * ksvg2/svg/SVGDescElement.cpp:
934         * ksvg2/svg/SVGDescElement.h:
935         * ksvg2/svg/SVGDocument.cpp:
936         * ksvg2/svg/SVGDocument.h:
937         * ksvg2/svg/SVGElement.cpp:
938         * ksvg2/svg/SVGElement.h:
939         * ksvg2/svg/SVGElementInstance.cpp:
940         * ksvg2/svg/SVGElementInstance.h:
941         * ksvg2/svg/SVGElementInstanceList.cpp:
942         * ksvg2/svg/SVGElementInstanceList.h:
943         * ksvg2/svg/SVGEllipseElement.cpp:
944         * ksvg2/svg/SVGEllipseElement.h:
945         * ksvg2/svg/SVGExternalResourcesRequired.cpp:
946         * ksvg2/svg/SVGExternalResourcesRequired.h:
947         * ksvg2/svg/SVGFEBlendElement.cpp:
948         * ksvg2/svg/SVGFEBlendElement.h:
949         * ksvg2/svg/SVGFEColorMatrixElement.cpp:
950         * ksvg2/svg/SVGFEColorMatrixElement.h:
951         * ksvg2/svg/SVGFEComponentTransferElement.cpp:
952         * ksvg2/svg/SVGFEComponentTransferElement.h:
953         * ksvg2/svg/SVGFECompositeElement.cpp:
954         * ksvg2/svg/SVGFECompositeElement.h:
955         * ksvg2/svg/SVGFEDiffuseLightingElement.cpp:
956         * ksvg2/svg/SVGFEDiffuseLightingElement.h:
957         * ksvg2/svg/SVGFEDisplacementMapElement.cpp:
958         * ksvg2/svg/SVGFEDisplacementMapElement.h:
959         * ksvg2/svg/SVGFEDistantLightElement.cpp:
960         * ksvg2/svg/SVGFEDistantLightElement.h:
961         * ksvg2/svg/SVGFEFloodElement.cpp:
962         * ksvg2/svg/SVGFEFloodElement.h:
963         * ksvg2/svg/SVGFEFuncAElement.cpp:
964         * ksvg2/svg/SVGFEFuncAElement.h:
965         * ksvg2/svg/SVGFEFuncBElement.cpp:
966         * ksvg2/svg/SVGFEFuncBElement.h:
967         * ksvg2/svg/SVGFEFuncGElement.cpp:
968         * ksvg2/svg/SVGFEFuncGElement.h:
969         * ksvg2/svg/SVGFEFuncRElement.cpp:
970         * ksvg2/svg/SVGFEFuncRElement.h:
971         * ksvg2/svg/SVGFEGaussianBlurElement.cpp:
972         * ksvg2/svg/SVGFEGaussianBlurElement.h:
973         * ksvg2/svg/SVGFEImageElement.cpp:
974         * ksvg2/svg/SVGFEImageElement.h:
975         * ksvg2/svg/SVGFELightElement.cpp:
976         * ksvg2/svg/SVGFELightElement.h:
977         * ksvg2/svg/SVGFEMergeElement.cpp:
978         * ksvg2/svg/SVGFEMergeElement.h:
979         * ksvg2/svg/SVGFEMergeNodeElement.cpp:
980         * ksvg2/svg/SVGFEMergeNodeElement.h:
981         * ksvg2/svg/SVGFEOffsetElement.cpp:
982         * ksvg2/svg/SVGFEOffsetElement.h:
983         * ksvg2/svg/SVGFEPointLightElement.cpp:
984         * ksvg2/svg/SVGFEPointLightElement.h:
985         * ksvg2/svg/SVGFESpecularLightingElement.cpp:
986         * ksvg2/svg/SVGFESpecularLightingElement.h:
987         * ksvg2/svg/SVGFESpotLightElement.cpp:
988         * ksvg2/svg/SVGFESpotLightElement.h:
989         * ksvg2/svg/SVGFETileElement.cpp:
990         * ksvg2/svg/SVGFETileElement.h:
991         * ksvg2/svg/SVGFETurbulenceElement.cpp:
992         * ksvg2/svg/SVGFETurbulenceElement.h:
993         * ksvg2/svg/SVGFilterElement.cpp:
994         * ksvg2/svg/SVGFilterElement.h:
995         * ksvg2/svg/SVGFilterPrimitiveStandardAttributes.cpp:
996         * ksvg2/svg/SVGFilterPrimitiveStandardAttributes.h:
997         * ksvg2/svg/SVGFitToViewBox.cpp:
998         * ksvg2/svg/SVGFitToViewBox.h:
999         * ksvg2/svg/SVGForeignObjectElement.cpp:
1000         * ksvg2/svg/SVGForeignObjectElement.h:
1001         * ksvg2/svg/SVGGElement.cpp:
1002         * ksvg2/svg/SVGGElement.h:
1003         * ksvg2/svg/SVGGradientElement.cpp:
1004         * ksvg2/svg/SVGGradientElement.h:
1005         * ksvg2/svg/SVGHelper.cpp:
1006         * ksvg2/svg/SVGHelper.h:
1007         * ksvg2/svg/SVGImageElement.cpp:
1008         * ksvg2/svg/SVGImageElement.h:
1009         * ksvg2/svg/SVGLangSpace.cpp:
1010         * ksvg2/svg/SVGLangSpace.h:
1011         * ksvg2/svg/SVGLength.cpp:
1012         * ksvg2/svg/SVGLength.h:
1013         * ksvg2/svg/SVGLengthList.cpp:
1014         * ksvg2/svg/SVGLengthList.h:
1015         * ksvg2/svg/SVGLineElement.cpp:
1016         * ksvg2/svg/SVGLineElement.h:
1017         * ksvg2/svg/SVGLinearGradientElement.cpp:
1018         * ksvg2/svg/SVGLinearGradientElement.h:
1019         * ksvg2/svg/SVGList.h:
1020         * ksvg2/svg/SVGLocatable.cpp:
1021         * ksvg2/svg/SVGLocatable.h:
1022         * ksvg2/svg/SVGMarkerElement.cpp:
1023         * ksvg2/svg/SVGMarkerElement.h:
1024         * ksvg2/svg/SVGMaskElement.cpp:
1025         * ksvg2/svg/SVGMaskElement.h:
1026         * ksvg2/svg/SVGMatrix.cpp:
1027         * ksvg2/svg/SVGMatrix.h:
1028         * ksvg2/svg/SVGNumber.cpp:
1029         * ksvg2/svg/SVGNumber.h:
1030         * ksvg2/svg/SVGNumberList.cpp:
1031         * ksvg2/svg/SVGNumberList.h:
1032         * ksvg2/svg/SVGPaint.cpp:
1033         * ksvg2/svg/SVGPaint.h:
1034         * ksvg2/svg/SVGPathElement.cpp:
1035         * ksvg2/svg/SVGPathElement.h:
1036         * ksvg2/svg/SVGPathSeg.cpp:
1037         * ksvg2/svg/SVGPathSeg.h:
1038         * ksvg2/svg/SVGPathSegArc.cpp:
1039         * ksvg2/svg/SVGPathSegArc.h:
1040         * ksvg2/svg/SVGPathSegClosePath.cpp:
1041         * ksvg2/svg/SVGPathSegClosePath.h:
1042         * ksvg2/svg/SVGPathSegCurvetoCubic.cpp:
1043         * ksvg2/svg/SVGPathSegCurvetoCubic.h:
1044         * ksvg2/svg/SVGPathSegCurvetoCubicSmooth.cpp:
1045         * ksvg2/svg/SVGPathSegCurvetoCubicSmooth.h:
1046         * ksvg2/svg/SVGPathSegCurvetoQuadratic.cpp:
1047         * ksvg2/svg/SVGPathSegCurvetoQuadratic.h:
1048         * ksvg2/svg/SVGPathSegCurvetoQuadraticSmooth.cpp:
1049         * ksvg2/svg/SVGPathSegCurvetoQuadraticSmooth.h:
1050         * ksvg2/svg/SVGPathSegLineto.cpp:
1051         * ksvg2/svg/SVGPathSegLineto.h:
1052         * ksvg2/svg/SVGPathSegLinetoHorizontal.cpp:
1053         * ksvg2/svg/SVGPathSegLinetoHorizontal.h:
1054         * ksvg2/svg/SVGPathSegLinetoVertical.cpp:
1055         * ksvg2/svg/SVGPathSegLinetoVertical.h:
1056         * ksvg2/svg/SVGPathSegList.cpp:
1057         * ksvg2/svg/SVGPathSegList.h:
1058         * ksvg2/svg/SVGPathSegMoveto.cpp:
1059         * ksvg2/svg/SVGPathSegMoveto.h:
1060         * ksvg2/svg/SVGPatternElement.cpp:
1061         * ksvg2/svg/SVGPatternElement.h:
1062         * ksvg2/svg/SVGPoint.cpp:
1063         * ksvg2/svg/SVGPoint.h:
1064         * ksvg2/svg/SVGPointList.cpp:
1065         * ksvg2/svg/SVGPointList.h:
1066         * ksvg2/svg/SVGPolyElement.cpp:
1067         * ksvg2/svg/SVGPolyElement.h:
1068         * ksvg2/svg/SVGPolygonElement.cpp:
1069         * ksvg2/svg/SVGPolygonElement.h:
1070         * ksvg2/svg/SVGPolylineElement.cpp:
1071         * ksvg2/svg/SVGPolylineElement.h:
1072         * ksvg2/svg/SVGPreserveAspectRatio.cpp:
1073         * ksvg2/svg/SVGPreserveAspectRatio.h:
1074         * ksvg2/svg/SVGRadialGradientElement.cpp:
1075         * ksvg2/svg/SVGRadialGradientElement.h:
1076         * ksvg2/svg/SVGRect.cpp:
1077         * ksvg2/svg/SVGRect.h:
1078         * ksvg2/svg/SVGRectElement.cpp:
1079         * ksvg2/svg/SVGRectElement.h:
1080         * ksvg2/svg/SVGSVGElement.cpp:
1081         * ksvg2/svg/SVGSVGElement.h:
1082         * ksvg2/svg/SVGScriptElement.cpp:
1083         * ksvg2/svg/SVGScriptElement.h:
1084         * ksvg2/svg/SVGSetElement.cpp:
1085         * ksvg2/svg/SVGSetElement.h:
1086         * ksvg2/svg/SVGStopElement.cpp:
1087         * ksvg2/svg/SVGStopElement.h:
1088         * ksvg2/svg/SVGStringList.cpp:
1089         * ksvg2/svg/SVGStringList.h:
1090         * ksvg2/svg/SVGStylable.cpp:
1091         * ksvg2/svg/SVGStylable.h:
1092         * ksvg2/svg/SVGStyleElement.cpp:
1093         * ksvg2/svg/SVGStyleElement.h:
1094         * ksvg2/svg/SVGStyledElement.cpp:
1095         * ksvg2/svg/SVGStyledElement.h:
1096         * ksvg2/svg/SVGStyledLocatableElement.cpp:
1097         * ksvg2/svg/SVGStyledLocatableElement.h:
1098         * ksvg2/svg/SVGStyledTransformableElement.cpp:
1099         * ksvg2/svg/SVGStyledTransformableElement.h:
1100         * ksvg2/svg/SVGSwitchElement.cpp:
1101         * ksvg2/svg/SVGSwitchElement.h:
1102         * ksvg2/svg/SVGSymbolElement.cpp:
1103         * ksvg2/svg/SVGSymbolElement.h:
1104         * ksvg2/svg/SVGTRefElement.cpp:
1105         * ksvg2/svg/SVGTRefElement.h:
1106         * ksvg2/svg/SVGTSpanElement.cpp:
1107         * ksvg2/svg/SVGTSpanElement.h:
1108         * ksvg2/svg/SVGTests.cpp:
1109         * ksvg2/svg/SVGTests.h:
1110         * ksvg2/svg/SVGTextContentElement.cpp:
1111         * ksvg2/svg/SVGTextContentElement.h:
1112         * ksvg2/svg/SVGTextElement.cpp:
1113         * ksvg2/svg/SVGTextElement.h:
1114         * ksvg2/svg/SVGTextPositioningElement.cpp:
1115         * ksvg2/svg/SVGTextPositioningElement.h:
1116         * ksvg2/svg/SVGTitleElement.cpp:
1117         * ksvg2/svg/SVGTitleElement.h:
1118         * ksvg2/svg/SVGTransform.cpp:
1119         * ksvg2/svg/SVGTransform.h:
1120         * ksvg2/svg/SVGTransformList.cpp:
1121         * ksvg2/svg/SVGTransformList.h:
1122         * ksvg2/svg/SVGTransformable.cpp:
1123         * ksvg2/svg/SVGTransformable.h:
1124         * ksvg2/svg/SVGURIReference.cpp:
1125         * ksvg2/svg/SVGURIReference.h:
1126         * ksvg2/svg/SVGUseElement.cpp:
1127         * ksvg2/svg/SVGUseElement.h:
1128         * ksvg2/svg/SVGViewElement.cpp:
1129         * ksvg2/svg/SVGViewElement.h:
1130         * ksvg2/svg/SVGZoomAndPan.cpp:
1131         * ksvg2/svg/SVGZoomAndPan.h:
1132         * ksvg2/svg/svgpathparser.cpp:
1133         * ksvg2/svg/svgpathparser.h:
1134         * page/DOMWindow.idl:
1135         * page/Frame.cpp:
1136         (WebCore::Frame::Frame):
1137         (WebCore::Frame::begin):
1138         (WebCore::Frame::pauseTimeouts):
1139         (WebCore::Frame::resumeTimeouts):
1140         * platform/GraphicsContext.h:
1141         * platform/cg/GraphicsContextCG.cpp:
1142         * rendering/RenderLayer.cpp:
1143         (WebCore::RenderLayer::isTransparent):
1144         * rendering/RenderObject.cpp:
1145         (WebCore::RenderObject::containingBlock):
1146         * rendering/RenderObject.h:
1147         * rendering/RenderStyle.cpp:
1148         (WebCore::RenderStyle::RenderStyle):
1149         (WebCore::RenderStyle::inheritFrom):
1150         (WebCore::RenderStyle::operator==):
1151         (WebCore::RenderStyle::inheritedNotEqual):
1152         (WebCore::RenderStyle::diff):
1153         * rendering/RenderStyle.h:
1154         * rendering/RenderTreeAsText.cpp:
1155         (WebCore::write):
1156         (WebCore::externalRepresentation):
1157         * xpath/XPathEvaluator.cpp:
1158         * xpath/XPathEvaluator.h:
1159         * xpath/XPathExpression.cpp:
1160         * xpath/XPathExpression.h:
1161         * xpath/XPathNSResolver.cpp:
1162         * xpath/XPathNSResolver.h:
1163         * xpath/XPathNamespace.cpp:
1164         * xpath/XPathNamespace.h:
1165         * xpath/XPathResult.cpp:
1166         * xpath/XPathResult.h:
1167         * xpath/impl/XPathExpressionNode.cpp:
1168         * xpath/impl/XPathExpressionNode.h:
1169         * xpath/impl/XPathFunctions.cpp:
1170         * xpath/impl/XPathFunctions.h:
1171         * xpath/impl/XPathGrammar.y:
1172         * xpath/impl/XPathParser.cpp:
1173         * xpath/impl/XPathParser.h:
1174         * xpath/impl/XPathPath.cpp:
1175         * xpath/impl/XPathPath.h:
1176         * xpath/impl/XPathPredicate.cpp:
1177         * xpath/impl/XPathPredicate.h:
1178         * xpath/impl/XPathStep.cpp:
1179         * xpath/impl/XPathStep.h:
1180         * xpath/impl/XPathUtil.cpp:
1181         * xpath/impl/XPathUtil.h:
1182         * xpath/impl/XPathValue.cpp:
1183         * xpath/impl/XPathValue.h:
1184         * xpath/impl/XPathVariableReference.cpp:
1185         * xpath/impl/XPathVariableReference.h:
1186
1187         Change all #if SVG_SUPPORT to #ifdef SVG_SUPPORT and
1188         #if XPATH_SUPPORT to #ifdef XPATH_SUPPORT
1189         (except for one #if !SVG_SUPPORT to a #ifndef SVG_SUPPORT
1190         in RenderTreeAsText.cpp)
1191
1192 2006-08-08  Rob Buis  <buis@kde.org>
1193
1194         Reviewed by Darin.
1195
1196         http://bugzilla.opendarwin.org/show_bug.cgi?id=10230
1197         SVGDOMImplementation should die (and be rolled into DOMImplementation)
1198
1199         Delete SVGDOMImplementation and references to it. The
1200         svg specific functionality is now in DOMImplementation.
1201
1202         * WebCore.xcodeproj/project.pbxproj:
1203         * dom/DOMImplementation.cpp:
1204         (WebCore::svgFeatureSet):
1205         (WebCore::DOMImplementation::hasFeature):
1206         (WebCore::DOMImplementation::createDocument):
1207         (WebCore::DOMImplementation::createSVGDocument):
1208         * dom/DOMImplementation.h:
1209         * ksvg2/bindings/idl/svg/SVGDOMImplementation.idl: Removed.
1210         * ksvg2/misc/KSVGTimeScheduler.cpp:
1211         * ksvg2/svg/SVGColor.cpp:
1212         * ksvg2/svg/SVGComponentTransferFunctionElement.cpp:
1213         * ksvg2/svg/SVGDocument.cpp:
1214         (WebCore::SVGDocument::SVGDocument):
1215         * ksvg2/svg/SVGDocument.h:
1216         * ksvg2/svg/SVGElement.cpp:
1217         (WebCore::SVGElement::isSupported):
1218         * ksvg2/svg/SVGFEBlendElement.cpp:
1219         * ksvg2/svg/SVGFEColorMatrixElement.cpp:
1220         * ksvg2/svg/SVGFEComponentTransferElement.cpp:
1221         * ksvg2/svg/SVGFECompositeElement.cpp:
1222         * ksvg2/svg/SVGFEDiffuseLightingElement.cpp:
1223         * ksvg2/svg/SVGFEDisplacementMapElement.cpp:
1224         * ksvg2/svg/SVGFEFloodElement.cpp:
1225         * ksvg2/svg/SVGFEGaussianBlurElement.cpp:
1226         * ksvg2/svg/SVGFELightElement.cpp:
1227         * ksvg2/svg/SVGFEMergeElement.cpp:
1228         * ksvg2/svg/SVGFEOffsetElement.cpp:
1229         * ksvg2/svg/SVGFESpecularLightingElement.cpp:
1230         * ksvg2/svg/SVGFETileElement.cpp:
1231         * ksvg2/svg/SVGFETurbulenceElement.cpp:
1232         * ksvg2/svg/SVGGradientElement.cpp:
1233         * ksvg2/svg/SVGPatternElement.cpp:
1234         * ksvg2/svg/SVGPolyElement.cpp:
1235         * ksvg2/svg/SVGStopElement.cpp:
1236         * ksvg2/svg/SVGStyledElement.cpp:
1237         * ksvg2/svg/SVGStyledTransformableElement.cpp:
1238         * ksvg2/svg/SVGTests.cpp:
1239         (WebCore::SVGTests::isValid):
1240         * ksvg2/svg/SVGTransformable.cpp:
1241         * page/Frame.cpp:
1242         (WebCore::Frame::begin):
1243
1244 2006-08-07  Brady Eidson  <beidson@apple.com>
1245
1246         Reviewed by Anders and John
1247
1248         Icons can now refresh when new data is sent from WebKit, both on disk and in memory
1249
1250         * bridge/mac/WebCoreIconDatabaseBridge.h:
1251         * bridge/mac/WebCoreIconDatabaseBridge.mm:
1252         (WebCore::IconDatabase::loadIconFromURL):  Allows WebCore/Kit to kick off a load
1253         outside of any greater context
1254         (-[WebCoreIconDatabaseBridge isIconExpiredForIconURL:]):
1255         (-[WebCoreIconDatabaseBridge isIconExpiredForPageURL:]): Allows WebKit
1256         to get whether or not an icon has expired
1257
1258         * loader/icon/IconDatabase.cpp:
1259         (WebCore::IconDatabase::recreateDatabase): Changed database schema slightly
1260         (WebCore::IconDatabase::createPrivateTables): Changed database schema slightly
1261         (WebCore::IconDatabase::iconForPageURL): 
1262         (WebCore::IconDatabase::isIconExpiredForIconURL): Get if an icon has expired
1263         (WebCore::IconDatabase::isIconExpiredForPageURL): Get if an icon has expired
1264         (WebCore::IconDatabase::setIconDataForIconURL): Force a refresh of the in memory
1265         image when new icon data is loaded
1266         (WebCore::IconDatabase::setIconURLForPageURL): added a check for null iconID
1267
1268         * loader/icon/IconDatabase.h: added/changed some methods
1269         * loader/icon/SiteIcon.cpp:
1270         (SiteIcon::getImage): simplified/removed debugging code
1271         (SiteIcon::manuallySetImageData): allow the image data to be changed when new icon
1272         data is loaded
1273
1274 2006-08-05  Darin Adler  <darin@apple.com>
1275
1276         Reviewed by Eric Seidel.
1277
1278         - fix a storage leak
1279
1280         * rendering/RenderView.cpp: (WebCore::RenderView::setSelection):
1281         Delete the values if we are going to exit without using the maps.
1282         Otherwise all the values leak.
1283
1284 2006-08-05  Darin Adler  <darin@apple.com>
1285
1286         Reviewed by Hyatt.
1287
1288         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=10213
1289           REGRESSION: Crash in WebCore::RenderLayer::isTransparent involving <iframe> and <select>
1290
1291         Test: fast/frames/iframe-option-crash.xhtml
1292
1293         * rendering/RenderView.cpp: (WebCore::RenderView::paintBoxDecorations):
1294         Check for a nil renderer.
1295
1296 2006-08-04  David Hyatt  <hyatt@apple.com>
1297
1298         Fix for Radar bug #4644045, regression where dragging selection no longer
1299         works for floats contained inside layers.  I added an optimization to
1300         refine dirty rect checking for layers, and it incorrectly excluded floats
1301         from the paint bounds since PaintPhaseSelection was not considered when
1302         analyzing the floatRect().
1303
1304         Reviewed by beth
1305
1306         * rendering/RenderBlock.cpp:
1307         (WebCore::RenderBlock::paint):
1308
1309 2006-08-04  David Hyatt  <hyatt@apple.com>
1310
1311         Fix remove() so that it is equivalent to calling removeChild on the
1312         parent.  This involved moving three operations that remove did.
1313
1314         (1) Move the accessibility object cache removal into the destroy methods,
1315         since this really should just happen when a render object is going away.
1316
1317         (2) removeFromObjectLists shifted into removeChild, which means it will
1318         now be called more often (this is a correct change).  Note that there is
1319         also now a new guard on removeFromObjectLists so that it won't do any
1320         work unless the document is not being destroyed.
1321
1322         (3) The big one.  deleteLineBoxWrapper was not getting called to clean up
1323         the line box tree.  This moved right into RenderContainer's removeChildNode so
1324         that it is now done even in the lowest level RenderContainer removal primitive.
1325
1326         Reviewed by beth
1327
1328         * rendering/RenderContainer.cpp:
1329         (WebCore::RenderContainer::removeChildNode):
1330         (WebCore::RenderContainer::removeChild):
1331         * rendering/RenderObject.cpp:
1332         (WebCore::RenderObject::removeFromObjectLists):
1333         (WebCore::RenderObject::destroy):
1334         * rendering/RenderObject.h:
1335         (WebCore::RenderObject::remove):
1336         * rendering/RenderWidget.cpp:
1337         (WebCore::RenderWidget::destroy):
1338
1339 2006-08-04  David Hyatt  <hyatt@apple.com>
1340
1341         Back out the fix for list marker crashes.  The actual bug here is that
1342         there is a confusing mismatch between remove() and removeChild() in the
1343         render tree.  remove() does a little bit of extra work that removeChild
1344         should be doing instead (so that remove() can just be a shorthand for
1345         removeChild).
1346
1347         This conservative fix does not solve the remove/removeChild mismatch
1348         but instead just changes the list marker updating code to use remove
1349         instead.
1350
1351         Reviewed by beth
1352
1353         Test Case: fast/lists/dynamic-marker-crash.html
1354
1355         * rendering/ListMarkerBox.cpp:
1356         * rendering/ListMarkerBox.h:
1357         * rendering/RenderListItem.cpp:
1358         (WebCore::RenderListItem::updateMarkerLocation):
1359
1360 2006-08-04  Sam Weinig  <sam.weinig@gmail.com>
1361
1362         Reviewed by Darin.
1363
1364         - patch for http://bugzilla.opendarwin.org/show_bug.cgi?id=10192
1365           Make WebCore (and friends) compile with -Wshorten-64-to-32
1366
1367           * Adds -Wshorten-64-to-32 flag to Xcode project.
1368           * Adds 'f' to float literals where expecting a float.
1369           * Use cosf() instead of cos() when assigning to a float.
1370
1371         * WebCore.xcodeproj/project.pbxproj:
1372         * kcanvas/device/quartz/filters/WKDiffuseLightingFilter.m:
1373         (+[WKDiffuseLightingFilter initialize]):
1374         * kcanvas/device/quartz/filters/WKDiscreteTransferFilter.m:
1375         (-[WKDiscreteTransferFilter outputImage]):
1376         * kcanvas/device/quartz/filters/WKDisplacementMapFilter.m:
1377         (+[WKDisplacementMapFilter initialize]):
1378         * kcanvas/device/quartz/filters/WKSpecularLightingFilter.m:
1379         (+[WKSpecularLightingFilter initialize]):
1380         * kcanvas/device/quartz/filters/WKSpotLightFilter.m:
1381         (-[WKSpotLightFilter outputImage]):
1382         * kcanvas/device/quartz/filters/WKTableTransferFilter.m:
1383         (-[WKTableTransferFilter outputImage]):
1384
1385 2006-08-03  David Hyatt  <hyatt@apple.com>
1386
1387         Fix for bug 10229, don't bother trying to clear when no floats are
1388         present.  I suspect there's still a bug in the math that follows, but
1389         this fix is safer in that it just does the obvious thing (and doesn't
1390         compute any clearance if no floats are even around).
1391
1392         Reviewed by maciej
1393
1394         * ChangeLog:
1395         * rendering/RenderBlock.cpp:
1396         (WebCore::RenderBlock::getClearDelta):
1397
1398 2006-08-03  Justin Garcia  <justin.garcia@apple.com>
1399
1400         Reviewed by harrison
1401         
1402         <rdar://problem/4641033/4515463/4052426/4046570/4053718/4053724/4060115/4062858>
1403         Copy/Paste fidelity was bad.
1404
1405         * editing/ApplyStyleCommand.cpp:
1406         (WebCore::ApplyStyleCommand::applyInlineStyle):
1407         * editing/markup.cpp:
1408         (WebCore::startMarkup): We were not adding non-inheritable styles
1409         to the markup for an element unless they were in the elements inline
1410         style declaration.
1411
1412 2006-08-03  Sam Weinig  <sam.weinig@gmail.com>
1413
1414         Reviewed by Darin.
1415
1416         - patch for http://bugzilla.opendarwin.org/show_bug.cgi?id=10176
1417           Make WebCore compile with -Wundef
1418
1419           * Adds -Wundef flag to Xcode project
1420           * Converts #ifs to #ifdef and #ifndefs where needed.
1421           * Replaces #ifdef WIN32 with #if PLATFORM(WIN_OS) or PLATFORM(WIN)
1422             (and in one instance in config.h with #if !COMPILER(MSVC))
1423           * Added #define YYMAXDEPTH 10000 in XPathGrammar.y and CSSGrammar.y
1424             to fix a warning from within Bison.
1425           * Cleaned up style a little in surrounding code.
1426
1427         * WebCore.xcodeproj/project.pbxproj:
1428         * bridge/mac/WebCoreAXObject.mm:
1429         (-[WebCoreAXObject doAXTextMarkerRangeForUnorderedTextMarkers:]):
1430         * config.h:
1431         * css/CSSGrammar.y:
1432         * css/MediaFeatureNames.cpp:
1433         * css/MediaFeatureNames.h:
1434         * css/cssparser.cpp:
1435         * dom/ContainerNode.cpp:
1436         (WebCore::ContainerNode::setActive):
1437         * dom/Element.cpp:
1438         (WebCore::Element::attach):
1439         * dom/Element.h:
1440         * dom/EventNames.cpp:
1441         * dom/EventNames.h:
1442         * dom/NamedAttrMap.h:
1443         * dom/Position.cpp:
1444         * dom/QualifiedName.cpp:
1445         * dom/QualifiedName.h:
1446         * dom/Range.h:
1447         * dom/XMLTokenizer.cpp:
1448         (WebCore::XMLTokenizer::error):
1449         * html/HTMLTokenizer.cpp:
1450         (WebCore::HTMLTokenizer::scriptHandler):
1451         (WebCore::HTMLTokenizer::scriptExecution):
1452         (WebCore::HTMLTokenizer::parseTag):
1453         (WebCore::HTMLTokenizer::continueProcessing):
1454         (WebCore::HTMLTokenizer::write):
1455         (WebCore::HTMLTokenizer::timerFired):
1456         (WebCore::HTMLTokenizer::notifyFinished):
1457         * kcanvas/device/quartz/KCanvasFilterQuartz.h:
1458         * kcanvas/device/quartz/KRenderingDeviceQuartz.h:
1459         * ksvg2/css/SVGRenderStyle.h:
1460         * ksvg2/css/SVGRenderStyleDefs.h:
1461         * ksvg2/scripts/make_names.pl:
1462         * loader/CachedResource.h:
1463         * loader/LoaderFunctions.h:
1464         * loader/loader.h:
1465         * page/Frame.cpp:
1466         * page/FrameTree.cpp:
1467         * page/FrameView.cpp:
1468         (WebCore::FrameView::clear):
1469         (WebCore::FrameView::layout):
1470         (WebCore::FrameView::layoutTimerFired):
1471         (WebCore::FrameView::scheduleRelayout):
1472         (WebCore::FrameView::unscheduleRelayout):
1473         * platform/AtomicString.cpp:
1474         * platform/AtomicString.h:
1475         * platform/Cursor.h:
1476         * platform/DeprecatedArray.h:
1477         * platform/DeprecatedString.cpp:
1478         (WebCore::allocateHandle):
1479         (WebCore::initializeHandleNodeBlock):
1480         (WebCore::freeHandle):
1481         * platform/FloatPoint.h:
1482         * platform/FloatRect.h:
1483         * platform/FloatSize.h:
1484         * platform/GraphicsContext.h:
1485         * platform/Image.h:
1486         * platform/IntPoint.h:
1487         * platform/IntRect.h:
1488         (WebCore::IntRect::inflateX):
1489         (WebCore::IntRect::inflateY):
1490         * platform/IntSize.h:
1491         * platform/PlatformKeyboardEvent.h:
1492         * platform/PlatformMouseEvent.h:
1493         * platform/PlatformString.h:
1494         * platform/ResourceLoader.h:
1495         * platform/ResourceLoaderInternal.h:
1496         (WebCore::ResourceLoaderInternal::ResourceLoaderInternal):
1497         * platform/ScrollView.h:
1498         * platform/StaticConstructors.h:
1499         * platform/StreamingTextDecoderICU.cpp:
1500         (WebCore::StreamingTextDecoderICU::convert):
1501         * platform/StringImpl.h:
1502         * platform/Widget.h:
1503         * platform/mac/BlockExceptions.mm:
1504         * platform/mac/ColorMac.mm:
1505         (+[WebCoreControlTintObserver WebCore]):
1506         * platform/mac/FloatPointMac.mm:
1507         * platform/mac/FloatRectMac.mm:
1508         * platform/mac/FloatSizeMac.mm:
1509         * platform/mac/FontMac.mm:
1510         * platform/mac/GraphicsContextMac.mm:
1511         (WebCore::GraphicsContext::drawFocusRing):
1512         * platform/mac/IntPointMac.mm:
1513         * platform/mac/IntRectMac.mm:
1514         * platform/mac/IntSizeMac.mm:
1515         * platform/mac/WebCoreSystemInterface.h:
1516         * rendering/RenderBlock.h:
1517         * rendering/RenderTableCell.h:
1518         * rendering/bidi.cpp:
1519         (WebCore::appendRun):
1520         (WebCore::RenderBlock::layoutInlineChildren):
1521         * xml/XSLTProcessor.cpp:
1522         (WebCore::parseErrorFunc):
1523         * xpath/impl/XPathGrammar.y:
1524
1525 2006-08-03  Adam Roben  <aroben@apple.com>
1526
1527         Reviewed by Maciej and Beth.
1528
1529         Fix use-after-dispose heap corruption bug.
1530
1531         * rendering/ListMarkerBox.cpp:
1532         (WebCore::ListMarkerBox::destroy): Only call removeChild if we're not
1533         destroying the document
1534
1535 2006-08-03  Adam Roben  <aroben@apple.com>
1536
1537         Reviewed by Anders.
1538
1539         - Fixed Windows build.
1540
1541         * platform/Color.cpp:
1542         (WebCore::makeRGBAFromHSLA): Whitespace change
1543         * platform/win/TemporaryLinkStubs.cpp: Add new method stubs
1544         (PlatformScrollBar::PlatformScrollBar):
1545         (PlatformScrollBar::~PlatformScrollBar):
1546         (PlatformScrollBar::width):
1547         (PlatformScrollBar::height):
1548         (PlatformScrollBar::setEnabled):
1549         (PlatformScrollBar::paint):
1550         (PlatformScrollBar::setScrollBarValue):
1551         (PlatformScrollBar::setKnobProportion):
1552         (PlatformScrollBar::setRect):
1553         (ScrollBar::ScrollBar):
1554         (ScrollBar::scroll):
1555         (ScrollBar::setValue):
1556
1557 2006-08-02  Justin Garcia  <justin.garcia@apple.com>
1558
1559         Reviewed by mjs
1560         
1561         <http://bugzilla.opendarwin.org/show_bug.cgi?id=10225>
1562         GMail Editor: Change Hilite Color doesn't work
1563
1564         * editing/JSEditor.cpp: Added support for execCommand("HiliteColor", ...).
1565         It's what GMail uses to implement text hiliting.  It's just a synonym for BackColor.
1566         * editing/SelectionController.cpp:
1567         (WebCore::SelectionController::nodeWillBeRemoved): Moved a comment
1568         a more appropriate place.
1569
1570 2006-08-03  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1571
1572         Reviewed by Adele and Darin.
1573
1574         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=10177
1575           REGRESSION: Successfully dragging text into a disabled field
1576
1577         Test: fast/forms/textfield-drag-into-disabled.html
1578
1579         * rendering/RenderTextControl.cpp:
1580         (WebCore::RenderTextControl::createDivStyle): Changed to set -webkit-user-modify
1581         to read-only on the inner div if the control is disabled.       
1582         (WebCore::RenderTextControl::updateFromElement): Ditto.
1583
1584 2006-08-03  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1585
1586         Reviewed by Darin.
1587
1588         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=10198
1589           REGRESSION: WebKit r15750 crashes while loading anthem.com
1590
1591         Test: fast/overflow/generated-content-crash.html
1592
1593         * rendering/RenderLayer.cpp:
1594         (WebCore::RenderLayer::updateScrollInfoAfterLayout): Added a null check for
1595         the renderer's element. Generated content does not have an element and
1596         therefore does not need to maintain overflow status.
1597
1598 2006-08-03  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1599
1600         Reviewed by Anders.
1601
1602         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=10202
1603           REGRESSION: Repro crash when loading an empty image document
1604
1605         Test: fast/tokenizer/image-empty-crash.html
1606
1607         * loader/ImageDocument.cpp:
1608         (WebCore::ImageTokenizer::stopParsing): Added null check for m_imageElement.
1609         (WebCore::ImageTokenizer::finish): Ditto.
1610
1611 2006-08-03  Darin Adler  <darin@apple.com>
1612
1613         Reviewed by Anders.
1614
1615         - clean up "flip"-related code a tiny bit
1616
1617         * platform/Screen.h: Removed redundant parameter names.
1618         * platform/mac/ScreenMac.mm:
1619         (WebCore::flipScreenRect): Changed to call flipScreenPoint so we only have one
1620         copy of the flipping code.
1621         (WebCore::flipScreenPoint): Fixed indentation.
1622
1623         * bridge/mac/WebCoreFrameBridge.mm: (globalPoint): Removed type casts and
1624         simplified a bit.
1625
1626         * platform/mac/PlatformMouseEventMac.mm: (WebCore::globalPositionForEvent):
1627         * platform/mac/WheelEventMac.mm: (WebCore::globalPositionForEvent):
1628         Removed unneeded local variable.
1629
1630 2006-08-02  David Hyatt  <hyatt@apple.com>
1631
1632         Abstract RenderLayer scrollbar creation and destruction so that there
1633         is a clean spot in which to drop in engine scrollbar stuff.
1634
1635         Reviewed by timo
1636
1637         * platform/ScrollBar.h:
1638         (WebCore::ScrollBar::hasPlatformScrollBars):
1639         * rendering/RenderLayer.cpp:
1640         (WebCore::RenderLayer::createScrollbar):
1641         (WebCore::RenderLayer::destroyScrollbar):
1642         (WebCore::RenderLayer::setHasHorizontalScrollbar):
1643         (WebCore::RenderLayer::setHasVerticalScrollbar):
1644         * rendering/RenderLayer.h:
1645
1646 2006-08-02  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1647
1648         Reviewed by Darin.
1649
1650         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=3438
1651           incorrect display of transparent 1x1 PNGs
1652
1653         Test: fast/replaced/image-solid-color-with-alpha.html
1654
1655         * platform/mac/ImageMac.mm:
1656         (WebCore::Image::checkForSolidColor): Changed to divide each color component
1657         by the alpha component. You need to do that since the bitmap context has
1658         premultiplied alpha but m_solidColor should be non-premultiplied.
1659
1660 2006-08-02  Adam Roben  <aroben@apple.com>
1661
1662         Reviewed by Brady.
1663
1664         - Remove redundant #include
1665
1666         * loader/loader.cpp:
1667
1668 2006-07-31  Sam Weinig  <sam.weinig@gmail.com>
1669
1670         Reviewed by Darin.
1671
1672         - patch for http://bugzilla.opendarwin.org/show_bug.cgi?id=9955
1673         Colors scaled from [0, 1] range to [0, 255] incorrectly
1674         
1675         Fixes scaling issue and fixes Color to follow style guidelines.
1676
1677         * css/cssstyleselector.cpp:
1678         (WebCore::CSSStyleSelector::getColorFromPrimitiveValue):
1679         * platform/Color.cpp:
1680         (WebCore::calcHue):
1681         (WebCore::makeRGBAFromHSLA):
1682         (WebCore::Color::Color):
1683         (WebCore::Color::name):
1684         (WebCore::Color::setNamedColor):
1685         (WebCore::Color::light):
1686         (WebCore::Color::dark):
1687         (WebCore::blend):
1688         * platform/Color.h:
1689         (WebCore::Color::Color):
1690         (WebCore::Color::isValid):
1691         (WebCore::Color::red):
1692         (WebCore::Color::green):
1693         (WebCore::Color::blue):
1694         (WebCore::Color::alpha):
1695         (WebCore::Color::rgb):
1696         (WebCore::Color::setRGB):
1697         (WebCore::operator==):
1698         (WebCore::operator!=):
1699         * rendering/RenderObject.cpp:
1700         (WebCore::RenderObject::drawBorder):
1701
1702 2006-07-31  Mitz Pettel  <opendarwin.org@mitzpettel.com>
1703
1704         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=10158
1705           REGRESSION: Selection highlight is dark and opaque when solid-color images are used
1706
1707         Reviewed by Darin.
1708
1709         Pixel test: fast/backgrounds/solid-color-context-restore.html
1710
1711         * platform/mac/ImageMac.mm:
1712         (WebCore::Image::draw): Added calls to preserve the graphics context
1713         around the painting of a solid color image.
1714         (WebCore::Image::drawTiled): Ditto.
1715
1716 2006-07-31  Maciej Stachowiak  <mjs@apple.com>
1717
1718         Rubber-stamped by Tim Hatcher.
1719
1720         - renamed TransferJob to ResourceLoader
1721
1722         * Projects/gdk/webcore-gdk.bkl:
1723         * WebCore.vcproj/WebCore/WebCore.vcproj:
1724         * WebCore.xcodeproj/project.pbxproj:
1725         * WebCoreSources.bkl:
1726         * bridge/mac/FrameMac.mm:
1727         * bridge/mac/WebCoreResourceLoaderImp.h:
1728         * bridge/mac/WebCoreResourceLoaderImp.mm:
1729         (-[WebCoreResourceLoaderImp redirectedToURL:]):
1730         (-[WebCoreResourceLoaderImp addData:]):
1731         (-[WebCoreResourceLoaderImp finishJobAndHandle:]):
1732         * bridge/win/FrameWin.cpp:
1733         * dom/XMLTokenizer.cpp:
1734         (WebCore::openFunc):
1735         * loader/Cache.cpp:
1736         * loader/LoaderFunctions.h:
1737         * loader/loader.cpp:
1738         (WebCore::Loader::servePendingRequests):
1739         (WebCore::Loader::receivedAllData):
1740         (WebCore::Loader::receivedResponse):
1741         (WebCore::Loader::receivedData):
1742         (WebCore::Loader::cancelRequests):
1743         (WebCore::Loader::jobForRequest):
1744         * loader/loader.h:
1745         * loader/mac/LoaderFunctionsMac.mm:
1746         (WebCore::ServeSynchronousRequest):
1747         * platform/ResourceLoader.cpp: Added.
1748         (WebCore::ResourceLoader::ResourceLoader):
1749         (WebCore::ResourceLoader::isErrorPage):
1750         (WebCore::ResourceLoader::error):
1751         (WebCore::ResourceLoader::setError):
1752         (WebCore::ResourceLoader::queryMetaData):
1753         (WebCore::ResourceLoader::addMetaData):
1754         (WebCore::ResourceLoader::kill):
1755         (WebCore::ResourceLoader::url):
1756         (WebCore::ResourceLoader::postData):
1757         (WebCore::ResourceLoader::method):
1758         (WebCore::ResourceLoader::client):
1759         * platform/ResourceLoader.h: Added.
1760         (WebCore::ResourceLoader::getInternal):
1761         * platform/ResourceLoaderClient.h: Added.
1762         (WebCore::ResourceLoaderClient::~ResourceLoaderClient):
1763         (WebCore::ResourceLoaderClient::receivedRedirect):
1764         (WebCore::ResourceLoaderClient::receivedResponse):
1765         (WebCore::ResourceLoaderClient::receivedData):
1766         (WebCore::ResourceLoaderClient::receivedAllData):
1767         * platform/ResourceLoaderInternal.h: Added.
1768         (WebCore::ResourceLoaderInternal::ResourceLoaderInternal):
1769         * platform/TransferJob.cpp: Removed.
1770         * platform/TransferJob.h: Removed.
1771         * platform/TransferJobClient.h: Removed.
1772         * platform/TransferJobInternal.h: Removed.
1773         * platform/gdk/FrameGdk.cpp:
1774         (WebCore::FrameGdk::openURL):
1775         (WebCore::FrameGdk::urlSelected):
1776         (WebCore::FrameGdk::receivedData):
1777         (WebCore::FrameGdk::receivedAllData):
1778         * platform/gdk/FrameGdk.h:
1779         * platform/gdk/ResourceLoaderCurl.cpp: Added.
1780         (WebCore::ResourceLoaderInternal::~ResourceLoaderInternal):
1781         (WebCore::ResourceLoader::~ResourceLoader):
1782         (WebCore::ResourceLoader::start):
1783         (WebCore::ResourceLoader::cancel):
1784         * platform/gdk/ResourceLoaderManager.cpp: Added.
1785         (WebCore::ResourceLoaderManager::ResourceLoaderManager):
1786         (WebCore::ResourceLoaderManager::get):
1787         (WebCore::ResourceLoaderManager::useSimpleTransfer):
1788         (WebCore::writeCallback):
1789         (WebCore::ResourceLoaderManager::downloadTimerCallback):
1790         (WebCore::ResourceLoaderManager::remove):
1791         (WebCore::ResourceLoaderManager::add):
1792         (WebCore::ResourceLoaderManager::cancel):
1793         * platform/gdk/ResourceLoaderManager.h: Added.
1794         * platform/gdk/TemporaryLinkStubs.cpp:
1795         (WebCore::ServeSynchronousRequest):
1796         (WebCore::ResourceLoader::assembleResponseHeaders):
1797         (WebCore::ResourceLoader::retrieveCharset):
1798         * platform/gdk/TransferJobCurl.cpp: Removed.
1799         * platform/gdk/TransferJobManager.cpp: Removed.
1800         * platform/gdk/TransferJobManager.h: Removed.
1801         * platform/mac/ResourceLoaderMac.mm: Added.
1802         (WebCore::ResourceLoaderInternal::~ResourceLoaderInternal):
1803         (WebCore::ResourceLoader::~ResourceLoader):
1804         (WebCore::ResourceLoader::start):
1805         (WebCore::ResourceLoader::assembleResponseHeaders):
1806         (WebCore::ResourceLoader::retrieveCharset):
1807         (WebCore::ResourceLoader::setLoader):
1808         (WebCore::ResourceLoader::receivedResponse):
1809         (WebCore::ResourceLoader::cancel):
1810         * platform/mac/TransferJobMac.mm: Removed.
1811         * platform/win/ResourceLoaderWin.cpp: Added.
1812         (WebCore::addToOutstandingJobs):
1813         (WebCore::lookupResourceLoader):
1814         (WebCore::ResourceLoaderWndProc):
1815         (WebCore::initializeOffScreenResourceLoaderWindow):
1816         (WebCore::ResourceLoaderInternal::~ResourceLoaderInternal):
1817         (WebCore::ResourceLoader::~ResourceLoader):
1818         (WebCore::ResourceLoader::start):
1819         (WebCore::ResourceLoader::fileLoadTimer):
1820         (WebCore::ResourceLoader::cancel):
1821         * platform/win/ResourceLoaderWin.h: Added.
1822         * platform/win/TemporaryLinkStubs.cpp:
1823         (WebCore::ServeSynchronousRequest):
1824         (WebCore::ResourceLoader::assembleResponseHeaders):
1825         (WebCore::ResourceLoader::retrieveCharset):
1826         * platform/win/TransferJobWin.cpp: Removed.
1827         * platform/win/TransferJobWin.h: Removed.
1828         * xml/XSLTProcessor.cpp:
1829         (WebCore::docLoaderFunc):
1830         * xml/xmlhttprequest.cpp:
1831         (WebCore::XMLHttpRequest::send):
1832         (WebCore::XMLHttpRequest::receivedAllData):
1833         (WebCore::XMLHttpRequest::receivedRedirect):
1834         (WebCore::XMLHttpRequest::receivedData):
1835         * xml/xmlhttprequest.h:
1836
1837 2006-07-31  Darin Adler  <darin@apple.com>
1838
1839         Reviewed by Hyatt.
1840
1841         - removed obsolete cell margin hack
1842
1843         * rendering/RenderBox.cpp: (WebCore::RenderBox::calcVerticalMargins):
1844         Set top and bottom margins to 0 for table cells instead of -16384.
1845         No effect on layout (including layout tests).
1846
1847         * css/CSSComputedStyleDeclaration.cpp:
1848         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1849         Added a few comments about differences between this class and the
1850         what the CSS specification says about computed style.
1851
1852 2006-07-31  Mark Rowe  <opendarwin.org@bdash.net.nz>
1853
1854         Reviewed by Maciej.
1855
1856         http://bugzilla.opendarwin.org/show_bug.cgi?id=9738
1857         Bug 9738: Unqualified :hover selector ignored in strict parsing mode
1858
1859         * css/cssstyleselector.cpp:
1860         (WebCore::CSSStyleSelector::checkSelector): Restrict the :hover and :active
1861         exclusion based on onlyHoverActive to quirks mode.
1862
1863 2006-07-31  David Hyatt  <hyatt@apple.com>
1864
1865         Fix for bug 10179, digg.com scrolls slowly.  Improve fixed positioning
1866         and fixed backgrounds so that a count of them is kept on the FrameView.
1867         This allows us to switch slow scrolling on and off as these objects come
1868         and go.
1869
1870         * css/cssstyleselector.cpp:
1871         (WebCore::CSSStyleSelector::adjustRenderStyle):
1872         (WebCore::CSSStyleSelector::applyProperty):
1873         * page/FrameView.cpp:
1874         (WebCore::FrameViewPrivate::reset):
1875         (WebCore::FrameView::layout):
1876         (WebCore::FrameView::useSlowRepaints):
1877         (WebCore::FrameView::setUseSlowRepaints):
1878         (WebCore::FrameView::addSlowRepaintObject):
1879         (WebCore::FrameView::removeSlowRepaintObject):
1880         * page/FrameView.h:
1881         * rendering/RenderBox.cpp:
1882         (WebCore::RenderBox::paintBackgroundExtended):
1883         * rendering/RenderObject.cpp:
1884         (WebCore::RenderObject::setStyle):
1885         * rendering/RenderView.cpp:
1886         (WebCore::RenderView::paintBoxDecorations):
1887
1888 2006-07-31  David Hyatt  <hyatt@apple.com>
1889
1890         Begin disentangling of scrollbar logic in preparation for engine-implemented
1891         scrollbars.  Split ScrollBar into two classes, an abstract base (still named
1892         ScrollBar) and a new PlatformScrollBar subclass.  This subclass is used only
1893         by platforms that want to continue to use a platform scrollbar (rather than
1894         the engine one).
1895
1896         Reviewed by darin
1897
1898         * WebCore.xcodeproj/project.pbxproj:
1899         * html/HTMLCanvasElement.h:
1900         * page/Frame.cpp:
1901         * platform/PlatformScrollBar.h: Added.
1902         (WebCore::PlatformScrollBar::isWidget):
1903         * platform/ScrollBar.h:
1904         (WebCore::ScrollBarClient::~ScrollBarClient):
1905         (WebCore::ScrollBar::~ScrollBar):
1906         (WebCore::ScrollBar::orientation):
1907         (WebCore::ScrollBar::value):
1908         (WebCore::ScrollBar::client):
1909         * platform/mac/PlatformScrollBarMac.mm: Added.
1910         (-[WebCoreScrollBar initWithPlatformScrollBar:]):
1911         (-[WebCoreScrollBar detachPlatformScrollBar]):
1912         (-[WebCoreScrollBar scroll:]):
1913         (-[WebCoreScrollBar widget]):
1914         (-[WebCoreScrollBar mouseDown:]):
1915         (WebCore::PlatformScrollBar::PlatformScrollBar):
1916         (WebCore::PlatformScrollBar::~PlatformScrollBar):
1917         (WebCore::PlatformScrollBar::setScrollBarValue):
1918         (WebCore::PlatformScrollBar::setKnobProportion):
1919         (WebCore::PlatformScrollBar::scrollbarHit):
1920         (WebCore::PlatformScrollBar::width):
1921         (WebCore::PlatformScrollBar::height):
1922         (WebCore::PlatformScrollBar::setRect):
1923         (WebCore::PlatformScrollBar::setEnabled):
1924         (WebCore::PlatformScrollBar::paint):
1925         * platform/mac/ScrollBarMac.mm: Removed.
1926         * platform/mac/WebCoreTextArea.mm:
1927         * rendering/RenderBlock.cpp:
1928         (WebCore::RenderBlock::isPointInScrollbar):
1929         * rendering/RenderFormElement.cpp:
1930         * rendering/RenderLayer.cpp:
1931         (WebCore::RenderLayer::horizontalScrollbarWidget):
1932         (WebCore::RenderLayer::verticalScrollbarWidget):
1933         (WebCore::RenderLayer::valueChanged):
1934         (WebCore::RenderLayer::setHasHorizontalScrollbar):
1935         (WebCore::RenderLayer::setHasVerticalScrollbar):
1936         (WebCore::RenderLayer::positionScrollbars):
1937         * rendering/RenderLayer.h:
1938         * rendering/RenderWidget.h:
1939
1940 2006-07-31  Adele Peterson  <adele@apple.com>
1941
1942         Reviewed by John and Anders.
1943
1944         - Fix for <rdar://problem/4380576> onChange does not get called when field changed by return key
1945
1946         Test: fast/forms/onchange-enter-submit.html
1947
1948         Blur (which will fire onChange appropriately) before submitting a form when pressing Enter.
1949         This matches the sequence of events fired in WinIE.
1950
1951         * html/HTMLInputElement.cpp: (WebCore::HTMLInputElement::defaultEventHandler):
1952         * html/HTMLSelectElement.cpp: (WebCore::HTMLSelectElement::defaultEventHandler):
1953
1954 2006-07-31  Geoffrey Garen  <ggaren@apple.com>
1955
1956         Reviewed by Kevin.
1957
1958         Moved string debug function outside of the WebCore namespace so that it's
1959         easier to call in the debugger. I will never doubt Darin again (x100).
1960
1961         * platform/String.cpp:
1962         (string):
1963
1964 2006-07-31  David Hyatt  <hyatt@apple.com>
1965
1966         Partial fix for 5453.  Improve overflow so that when it changes
1967         dynamically from scroll/auto to hidden that we properly hide the
1968         scrollbars.  Also refine the dirty dashboard region updating so that
1969         it only happens if the scrollbars genuinely come and go.
1970
1971         Also eliminate the extra repaint of the entire block.  This should not be
1972         necessary, since the scrollbars repaint themselves already and children
1973         will repaint already if they move.
1974
1975         Reviewed by darin
1976
1977         Adding test case from bug into fast/overflow/dynamic-hidden.html
1978
1979         * rendering/RenderLayer.cpp:
1980         (WebCore::RenderLayer::setHasHorizontalScrollbar):
1981         (WebCore::RenderLayer::setHasVerticalScrollbar):
1982         (WebCore::RenderLayer::updateScrollInfoAfterLayout):
1983
1984 2006-07-31  Graham Dennis  <graham.dennis@gmail.com>
1985
1986         Reviewed by justin
1987         
1988         <http://bugzilla.opendarwin.org/show_bug.cgi?id=9507>
1989         Empty style spans created in applyInlineStyle
1990         
1991         Improves paste fidelity because some of these empty font/style spans had a non-zero
1992         size and were messing up the layout of pasted content:
1993         <rdar://problem/4515463>
1994         REGRESSION: Blot and Mail both do a very poor job of pasting the main www.apple.com page   
1995
1996         * editing/ApplyStyleCommand.cpp:
1997         (WebCore::ApplyStyleCommand::applyInlineStyle): Use the adjusted start node instead 
1998         of start.node().  Don't do any application if the endpoints are swapped.  Adjust
1999         endNode if the start node is a descendant of it, so that the pre-order traversal will
2000         terminate properly.
2001
2002 2006-07-31  Geoffrey Garen  <ggaren@apple.com>
2003
2004         Reviewed by Darin.
2005
2006         * platform/String.cpp:
2007         (WebCore::string): Added a debugging function to create a String from a
2008         const char*.
2009
2010 2006-07-31  Anders Carlsson  <acarlsson@apple.com>
2011
2012         * css/CSSPrimitiveValue.cpp:
2013         Fix windows build.
2014
2015 2006-07-31  Geoffrey Garen  <ggaren@apple.com>
2016
2017         Reinstating my last change. Everything builds now.
2018         
2019 2006-07-31  Geoffrey Garen  <ggaren@apple.com>
2020
2021         Backing out my last change because it causes a build failure in some
2022         configurations. This seems to be the cleanest way to get svn to cooperate.
2023
2024 2006-07-31  Geoffrey Garen  <ggaren@apple.com>
2025
2026         Reviewed by Maciej.
2027
2028         Moved files around to make WebCore's structure clearer
2029         and easier to explain.
2030
2031         DerivedSources/JS* -> bindings/js/DerivedSources/ (so JS* files
2032         show up when you search inside bindings/js/, but are marked, at
2033         the same time, as files that you should not edit manually)
2034
2035         WebCore+SVG/DOMList.h -> ksvg2/svg/ (only files inside ksvg2/svg/
2036         use DOMList.h)
2037
2038         icon -> loader/icon
2039
2040         I tested that everything still builds.
2041
2042 2006-07-30  Darin Adler  <darin@apple.com>
2043
2044         Reviewed by Tim Hatcher.
2045
2046         - some improvements for the benefit of the style pane of the inspector
2047
2048         * css/CSSComputedStyleDeclaration.cpp: Removed background-position
2049         and border-spacing from the list of properties that show up in
2050         computed style, because of background-position-x, background-position-y,
2051         -webkit-border-horizontal-spacing and -webkit-border-vertical-spacing.
2052         (WebCore::valueForLength): Added handling for undefinedLength, intrinsic,
2053         and min-intrinsic.
2054         (WebCore::primitiveValueFromLength): Removed code that would add a
2055         space to the string for no good reason.
2056         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): Added a
2057         special case for a line clamp of -1, which should come back as "none"
2058         rather than an actual "-1".
2059         (WebCore::CSSComputedStyleDeclaration::length): Return 0 if the
2060         declaration has no corresponding node or no renderer.
2061         (WebCore::CSSComputedStyleDeclaration::item): Check against length()
2062         so that the two stay consistent rather than using a constant.
2063
2064         * css/CSSPrimitiveValue.cpp:
2065         (WebCore::isCSSTokenizerIdentifier): Added.
2066         (WebCore::isCSSTokenizerURL): Added.
2067         (WebCore::quoteString): Added.
2068         (WebCore::quoteStringIfNeeded): Changed to quote strings in many more
2069         cases -- any cases where they would not parse in the CSS parser otherwise.
2070         The main case this affects is font names with spaces in them.
2071         (WebCore::quoteURLIfNeeded): Added.
2072         (WebCore::CSSPrimitiveValue::cssText): Use quoteURLIfNeeded in the case
2073         where we're making the text form of a URI.
2074
2075         * css/tokenizer.flex: Whitespace tweaks to line things up better.
2076
2077 2006-07-30  Eric Seidel  <eric@eseidel.com>
2078
2079         Reviewed by gramps!
2080
2081         Remove some unused SVG code.
2082
2083         * ksvg2/ecma/Ecma.cpp: Removed.
2084         * ksvg2/ecma/Ecma.h: Removed.
2085         * ksvg2/ecma/GlobalObject.cpp: remove a couple dead functions.
2086         * ksvg2/ecma/GlobalObject.h: add a comment about this dead code.
2087         * ksvg2/ecma/SVGLookup.h: Removed.
2088
2089 2006-07-29  Darin Adler  <darin@apple.com>
2090
2091         - Removed tabs from these source files that still had them.
2092           We don't use them; that way source files look fine in editors
2093           that have tabs set to 8 spaces or to 4 spaces.
2094         - Removed allow-tabs Subversion property from the files too.
2095
2096         * bindings/objc/WebScriptObject.h:
2097         * bindings/objc/WebScriptObject.mm:
2098         * platform/FontData.cpp:
2099
2100 2006-07-29  Sam Weinig  <sam.weinig@gmail.com>
2101
2102         Reviewed by Darin.
2103
2104         - patch for http://bugzilla.opendarwin.org/show_bug.cgi?id=10080
2105           Adopt pedantic changes from the Unity project to improve 
2106           cross-compiler compatibility
2107
2108           Changes include:
2109           * Removing trailing semicolon from namespace braces.
2110           * Removing trailing comma from last enum declaration.
2111           * Updating to match style guidelines.
2112           * Adding missing newline to the end of the file.
2113           * Turning on gcc warning for missing newline at the end of a source file
2114             (GCC_WARN_ABOUT_MISSING_NEWLINE in Xcode, -Wnewline in gcc).
2115           * Alphabetical sorting of Xcode source list files.
2116           * Use abs() function from <math.h> instead of ABS() macro.
2117           * Use C-style comments instead of C++ comments in files that might
2118             be included by either C or C++ files.
2119           * Use -numeric_limits<double>::infinity() instead of -HUGE_VAL.
2120
2121         * WebCore+SVG/DOMList.h:
2122         * WebCore.xcodeproj/project.pbxproj:
2123         * WebCorePrefix.h:
2124         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
2125         * bindings/js/JSXSLTProcessor.h:
2126         * bindings/js/kjs_domnode.h:
2127         (KJS::DOMNode::):
2128         * bindings/objc/DOMCSS.h:
2129         (-[DOMCSSValue enum]):
2130         * bindings/objc/DOMCore.h:
2131         (-[DOMImplementation createDocument:::]):
2132         * bindings/objc/DOMEvents.h:
2133         (-[DOMOverflowEvent enum]):
2134         * bindings/objc/DOMRange.h:
2135         * bindings/objc/DOMTraversal.h:
2136         * bindings/objc/DOMXPath.h:
2137         (-[DOMXPathNSResolver lookupNamespaceURI:]):
2138         * bridge/mac/WebCoreFrameBridge.h:
2139         * bridge/mac/WebCoreKeyboardAccess.h:
2140         * css/makeprop:
2141         * css/makevalues:
2142         * dom/ChildNodeList.h:
2143         * dom/DocPtr.h:
2144         * dom/Document.h:
2145         (WebCore::Document::):
2146         * dom/DocumentMarker.h:
2147         (WebCore::DocumentMarker::):
2148         (WebCore::DocumentMarker::operator==):
2149         (WebCore::DocumentMarker::operator!=):
2150         * dom/EventTargetNode.h:
2151         * dom/KeyboardEvent.h:
2152         (WebCore::KeyboardEvent::):
2153         * dom/NameNodeList.h:
2154         (WebCore::NameNodeList::rootNodeChildrenChanged):
2155         * dom/QualifiedName.cpp:
2156         * editing/TypingCommand.h:
2157         (WebCore::TypingCommand::):
2158         * editing/UnlinkCommand.h:
2159         (WebCore::UnlinkCommand::editingAction):
2160         * html/FormDataList.h:
2161         (WebCore::FormDataListItem::FormDataListItem):
2162         (WebCore::FormDataList::appendData):
2163         * html/HTMLBlockquoteElement.h:
2164         * html/HTMLDivElement.h:
2165         * html/HTMLFormElement.h:
2166         * html/HTMLHRElement.h:
2167         * html/HTMLHeadingElement.h:
2168         * html/HTMLMarqueeElement.h:
2169         * html/HTMLParagraphElement.h:
2170         * html/HTMLPlugInElement.h:
2171         * html/HTMLPreElement.h:
2172         * html/HTMLTokenizer.h:
2173         (WebCore::HTMLTokenizer::State::):
2174         * icon/IconDatabase.cpp:
2175         * icon/SQLStatement.cpp:
2176         * kcanvas/KCanvasFilters.h:
2177         (WebCore::):
2178         (WebCore::KCanvasPoint3F::KCanvasPoint3F):
2179         (WebCore::KCanvasFilter::KCanvasFilter):
2180         (WebCore::KCanvasFilter::~KCanvasFilter):
2181         (WebCore::KCanvasFilterEffect::~KCanvasFilterEffect):
2182         (WebCore::KCComponentTransferFunction::KCComponentTransferFunction):
2183         (WebCore::KCanvasFEConvolveMatrix::KCanvasFEConvolveMatrix):
2184         (WebCore::KCLightSource::KCLightSource):
2185         (WebCore::KCDistantLightSource::KCDistantLightSource):
2186         (WebCore::KCPointLightSource::KCPointLightSource):
2187         (WebCore::KCSpotLightSource::KCSpotLightSource):
2188         (WebCore::KCanvasFEDiffuseLighting::KCanvasFEDiffuseLighting):
2189         (WebCore::KCanvasFEDisplacementMap::KCanvasFEDisplacementMap):
2190         (WebCore::KCanvasFEImage::KCanvasFEImage):
2191         (WebCore::KCanvasFESpecularLighting::KCanvasFESpecularLighting):
2192         * kcanvas/RenderSVGImage.h:
2193         * kcanvas/device/quartz/KRenderingDeviceQuartz.h:
2194         * ksvg2/css/SVGRenderStyle.h:
2195         (WebCore::SVGRenderStyle::InheritedFlags::):
2196         (WebCore::SVGRenderStyle::NonInheritedFlags::):
2197         * ksvg2/css/SVGRenderStyleDefs.h:
2198         (WebCore::):
2199         * ksvg2/events/SVGZoomEvent.h:
2200         * ksvg2/ksvg.h:
2201         (WebCore::):
2202         * ksvg2/misc/KCanvasRenderingStyle.h:
2203         * ksvg2/misc/SVGImageLoader.h:
2204         * ksvg2/scripts/make_names.pl:
2205         * ksvg2/svg/SVGAElement.h:
2206         * ksvg2/svg/SVGAngle.h:
2207         * ksvg2/svg/SVGAnimateColorElement.h:
2208         * ksvg2/svg/SVGAnimateElement.h:
2209         * ksvg2/svg/SVGAnimateTransformElement.h:
2210         * ksvg2/svg/SVGAnimatedAngle.h:
2211         * ksvg2/svg/SVGAnimatedBoolean.h:
2212         * ksvg2/svg/SVGAnimatedColor.h:
2213         * ksvg2/svg/SVGAnimatedEnumeration.h:
2214         * ksvg2/svg/SVGAnimatedInteger.h:
2215         * ksvg2/svg/SVGAnimatedLength.h:
2216         * ksvg2/svg/SVGAnimatedLengthList.h:
2217         * ksvg2/svg/SVGAnimatedNumber.h:
2218         * ksvg2/svg/SVGAnimatedNumberList.h:
2219         * ksvg2/svg/SVGAnimatedPathData.h:
2220         * ksvg2/svg/SVGAnimatedPoints.h:
2221         * ksvg2/svg/SVGAnimatedPreserveAspectRatio.h:
2222         * ksvg2/svg/SVGAnimatedRect.h:
2223         * ksvg2/svg/SVGAnimatedString.h:
2224         * ksvg2/svg/SVGAnimatedTemplate.h:
2225         * ksvg2/svg/SVGAnimatedTransformList.h:
2226         * ksvg2/svg/SVGAnimationElement.cpp:
2227         (SVGAnimationElement::calculateCurrentValueItem):
2228         (SVGAnimationElement::calculateRelativeTimePercentage):
2229         * ksvg2/svg/SVGAnimationElement.h:
2230         (WebCore::):
2231         * ksvg2/svg/SVGCircleElement.h:
2232         * ksvg2/svg/SVGClipPathElement.h:
2233         * ksvg2/svg/SVGColor.h:
2234         * ksvg2/svg/SVGComponentTransferFunctionElement.h:
2235         * ksvg2/svg/SVGCursorElement.h:
2236         * ksvg2/svg/SVGDOMImplementation.h:
2237         * ksvg2/svg/SVGDefsElement.h:
2238         * ksvg2/svg/SVGDescElement.h:
2239         * ksvg2/svg/SVGDocument.h:
2240         * ksvg2/svg/SVGElement.h:
2241         (WebCore::SVGElement::rendererIsNeeded):
2242         (WebCore::svg_dynamic_cast):
2243         * ksvg2/svg/SVGElementInstance.h:
2244         * ksvg2/svg/SVGElementInstanceList.h:
2245         * ksvg2/svg/SVGEllipseElement.h:
2246         * ksvg2/svg/SVGExternalResourcesRequired.h:
2247         * ksvg2/svg/SVGFEBlendElement.h:
2248         * ksvg2/svg/SVGFEColorMatrixElement.h:
2249         * ksvg2/svg/SVGFEComponentTransferElement.h:
2250         * ksvg2/svg/SVGFECompositeElement.h:
2251         * ksvg2/svg/SVGFEDiffuseLightingElement.h:
2252         * ksvg2/svg/SVGFEDisplacementMapElement.h:
2253         * ksvg2/svg/SVGFEDistantLightElement.h:
2254         * ksvg2/svg/SVGFEFloodElement.h:
2255         * ksvg2/svg/SVGFEFuncAElement.h:
2256         * ksvg2/svg/SVGFEFuncBElement.h:
2257         * ksvg2/svg/SVGFEFuncGElement.h:
2258         * ksvg2/svg/SVGFEFuncRElement.h:
2259         * ksvg2/svg/SVGFEGaussianBlurElement.h:
2260         * ksvg2/svg/SVGFEImageElement.h:
2261         * ksvg2/svg/SVGFELightElement.h:
2262         * ksvg2/svg/SVGFEMergeElement.h:
2263         * ksvg2/svg/SVGFEMergeNodeElement.h:
2264         * ksvg2/svg/SVGFEOffsetElement.h:
2265         * ksvg2/svg/SVGFEPointLightElement.h:
2266         * ksvg2/svg/SVGFESpecularLightingElement.h:
2267         * ksvg2/svg/SVGFESpotLightElement.h:
2268         * ksvg2/svg/SVGFETileElement.h:
2269         * ksvg2/svg/SVGFETurbulenceElement.h:
2270         * ksvg2/svg/SVGFilterElement.h:
2271         * ksvg2/svg/SVGFilterPrimitiveStandardAttributes.h:
2272         * ksvg2/svg/SVGFitToViewBox.h:
2273         * ksvg2/svg/SVGForeignObjectElement.cpp:
2274         * ksvg2/svg/SVGForeignObjectElement.h:
2275         * ksvg2/svg/SVGGElement.h:
2276         * ksvg2/svg/SVGGradientElement.h:
2277         * ksvg2/svg/SVGHelper.h:
2278         (WebCore::):
2279         * ksvg2/svg/SVGImageElement.h:
2280         * ksvg2/svg/SVGLangSpace.h:
2281         * ksvg2/svg/SVGLength.h:
2282         * ksvg2/svg/SVGLengthList.h:
2283         * ksvg2/svg/SVGLineElement.h:
2284         * ksvg2/svg/SVGLinearGradientElement.h:
2285         * ksvg2/svg/SVGList.h:
2286         * ksvg2/svg/SVGLocatable.h:
2287         * ksvg2/svg/SVGMarkerElement.h:
2288         * ksvg2/svg/SVGMaskElement.h:
2289         * ksvg2/svg/SVGMatrix.h:
2290         * ksvg2/svg/SVGNumber.h:
2291         * ksvg2/svg/SVGNumberList.h:
2292         * ksvg2/svg/SVGPaint.h:
2293         * ksvg2/svg/SVGPathElement.h:
2294         * ksvg2/svg/SVGPathSeg.h:
2295         * ksvg2/svg/SVGPathSegArc.h:
2296         * ksvg2/svg/SVGPathSegClosePath.h:
2297         * ksvg2/svg/SVGPathSegCurvetoCubic.h:
2298         * ksvg2/svg/SVGPathSegCurvetoCubicSmooth.h:
2299         * ksvg2/svg/SVGPathSegCurvetoQuadratic.h:
2300         * ksvg2/svg/SVGPathSegCurvetoQuadraticSmooth.h:
2301         * ksvg2/svg/SVGPathSegLineto.h:
2302         * ksvg2/svg/SVGPathSegLinetoHorizontal.h:
2303         * ksvg2/svg/SVGPathSegLinetoVertical.h:
2304         * ksvg2/svg/SVGPathSegList.h:
2305         * ksvg2/svg/SVGPathSegMoveto.h:
2306         * ksvg2/svg/SVGPatternElement.h:
2307         * ksvg2/svg/SVGPoint.h:
2308         * ksvg2/svg/SVGPointList.h:
2309         * ksvg2/svg/SVGPolyElement.h:
2310         * ksvg2/svg/SVGPolygonElement.h:
2311         * ksvg2/svg/SVGPolylineElement.h:
2312         * ksvg2/svg/SVGPreserveAspectRatio.h:
2313         * ksvg2/svg/SVGRadialGradientElement.h:
2314         * ksvg2/svg/SVGRect.h:
2315         * ksvg2/svg/SVGRectElement.h:
2316         * ksvg2/svg/SVGSVGElement.h:
2317         * ksvg2/svg/SVGScriptElement.h:
2318         * ksvg2/svg/SVGSetElement.h:
2319         * ksvg2/svg/SVGStopElement.h:
2320         * ksvg2/svg/SVGStringList.h:
2321         * ksvg2/svg/SVGStylable.h:
2322         * ksvg2/svg/SVGStyleElement.h:
2323         * ksvg2/svg/SVGStyledElement.h:
2324         (WebCore::SVGStyledElement::rendererIsNeeded):
2325         (WebCore::SVGStyledElement::canvasResource):
2326         * ksvg2/svg/SVGStyledLocatableElement.h:
2327         * ksvg2/svg/SVGStyledTransformableElement.h:
2328         * ksvg2/svg/SVGSwitchElement.h:
2329         * ksvg2/svg/SVGSymbolElement.h:
2330         * ksvg2/svg/SVGTRefElement.h:
2331         * ksvg2/svg/SVGTSpanElement.h:
2332         * ksvg2/svg/SVGTests.h:
2333         * ksvg2/svg/SVGTextContentElement.h:
2334         * ksvg2/svg/SVGTextElement.h:
2335         * ksvg2/svg/SVGTextPositioningElement.h:
2336         * ksvg2/svg/SVGTitleElement.h:
2337         * ksvg2/svg/SVGTransform.h:
2338         * ksvg2/svg/SVGTransformList.h:
2339         * ksvg2/svg/SVGTransformable.h:
2340         * ksvg2/svg/SVGURIReference.h:
2341         * ksvg2/svg/SVGUseElement.h:
2342         * ksvg2/svg/SVGViewElement.h:
2343         * ksvg2/svg/SVGZoomAndPan.h:
2344         * ksvg2/svg/svgpathparser.h:
2345         * page/Frame.h:
2346         (WebCore::):
2347         * platform/AffineTransform.h:
2348         * platform/FontCache.cpp:
2349         (WebCore::FontPlatformDataCacheKey::FontPlatformDataCacheKey):
2350         * platform/FontData.cpp:
2351         (WebCore::FontData::FontData):
2352         * platform/FontData.h:
2353         * platform/TextBox.h:
2354         (WebCore::TextBox::):
2355         * platform/Timer.cpp:
2356         (WebCore::TimerBase::heapPop):
2357         * platform/mac/FontCacheMac.mm:
2358         * platform/mac/GlyphMapMac.cpp:
2359         * platform/mac/WebFontCache.mm:
2360         (betterChoice):
2361         * rendering/DeprecatedRenderSelect.cpp:
2362         (WebCore::DeprecatedRenderSelect::setWidgetWritingDirection):
2363         * rendering/EllipsisBox.h:
2364         * rendering/RenderBR.h:
2365         (WebCore::RenderBR::renderName):
2366         (WebCore::RenderBR::width):
2367         * rendering/RenderBlock.h:
2368         (WebCore::):
2369         * rendering/RenderFlexibleBox.h:
2370         * rendering/RenderFlow.h:
2371         (WebCore::RenderFlow::RenderFlow):
2372         * rendering/RenderFrame.cpp:
2373         * rendering/bidi.h:
2374         * rendering/break_lines.cpp:
2375
2376 2006-07-29  Rob Buis  <buis@kde.org>
2377
2378         Reviewed by Geoff.
2379
2380         http://bugzilla.opendarwin.org/show_bug.cgi?id=10151
2381         ghostmap XHTML + SVG fails due to javascript undefined exception
2382
2383         Make sure document.URL works when called from a non-HTML document.
2384
2385         * bindings/js/kjs_html.cpp:
2386         (KJS::JSHTMLDocument::getValueProperty):
2387         * bindings/js/kjs_html.h:
2388         (KJS::JSHTMLDocument::):
2389         * dom/Document.idl:
2390
2391 2006-07-29  Mike Emmel  <mike.emmel@gmail.com>
2392
2393         Reviewed and tweaked by Darin.
2394
2395         - fixes for Linux build
2396           (still might not compile, since Darin tweaked but was unable to test).
2397
2398         * WebCoreSources.bkl: Added some new sources, removed some obsolete ones.
2399         * Projects/gdk/webcore-gdk.bkl: Added RenderPopupMenuGdk.cpp
2400
2401         * html/HTMLPlugInElement.h: Removed incorrect syntax with class name
2402         before ::.
2403
2404         * platform/gdk/FrameGdk.h:
2405         * platform/gdk/FrameGdk.cpp: Updated parameters of constructor. Moved a couple stubs
2406         out of this file.
2407         * platform/gdk/RenderPopupMenuGdk.h: Added.
2408         * platform/gdk/RenderPopupMenuGdk.cpp: Added. Just a file full of empty stubs.
2409         * platform/gdk/RenderThemeGdk.h:
2410         * platform/gdk/RenderThemeGdk.cpp: (WebCore::RenderThemeGdk::createPopupMenu): Added.
2411
2412         * platform/gdk/TemporaryLinkStubs.cpp: Add some new stubs.
2413
2414 2006-07-29  Mark Rowe  <opendarwin.org@bdash.net.nz>
2415
2416         Reviewed by Darin.
2417
2418         http://bugzilla.opendarwin.org/show_bug.cgi?id=10022
2419         Bug 10022: REGRESSION: Crash in WebCore::XMLTokenizer::characters
2420
2421         * dom/XMLTokenizer.cpp:
2422         (WebCore::XMLTokenizer::resumeParsing): If the write() call resulted in new callbacks being
2423         added, don't call through to end() just yet.
2424
2425 2006-07-29  Mitz Pettel  <opendarwin.org@mitzpettel.com>
2426
2427         Reviewed by John Sullivan.
2428
2429         - manual test for http://bugzilla.opendarwin.org/show_bug.cgi?id=9984
2430           ASSERTION FAILURE: _private->mouseDownEvent != nil
2431           (WebKit/WebView/WebHTMLView.m:4863 -[WebHTMLView(WebInternal) _delegateDragSourceActionMask])
2432
2433         * manual-tests/subview-click-assertion.html: Added.
2434
2435 2006-07-29  Andrew Wellington  <proton@wiretapped.net>
2436
2437         Reviewed by Darin.
2438
2439         Fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=8587 / <rdar://problem/4631844>
2440         REGRESSION: {display:list-item} items outside an ol or ul element don't number correctly
2441
2442         * rendering/RenderListItem.cpp:
2443         (WebCore::enclosingList): If no real list element is found, use parent instead.
2444         (WebCore::previousListItem): Check list elements to see if they are list items -- the
2445         old code assumed that a list would never be a list item but this is entirely possible
2446         with CSS and especially with the new rule that means any DOM element could act as a list.
2447
2448 2006-07-29  Alexey Proskuryakov  <ap@nypop.com>
2449
2450         Reviewed by Darin.
2451
2452         Fix http://bugzilla.opendarwin.org/show_bug.cgi?id=10147
2453         REGRESSION: custom attribute values set via javascript are not persistent
2454
2455         Test: fast/dom/Element/setAttribute-case-insensitivity.html
2456
2457         * dom/Element.cpp:
2458         (WebCore::Element::setAttribute): Use the lowercased localName for retrieving the old value, too.
2459
2460 2006-07-28  Timothy Hatcher  <timothy@apple.com>
2461
2462         Suggested by Darin.
2463
2464         Moving the implementation of isContentEditable to the
2465         the WebPrivate category.
2466
2467         * bindings/objc/DOM.mm:
2468         (-[DOMNode isContentEditable]):
2469
2470 2006-07-28  Justin Garcia  <justin.garcia@apple.com>
2471
2472         Reviewed by levi
2473         
2474         First part of:
2475         <rdar://problem/4515463>
2476         REGRESSION: Blot and Mail both do a very poor job of pasting the main www.apple.com page
2477         
2478         Migrate to isBlock and enclosingBlock.
2479         Changed RendereringInfo::isBlock and ReplacementFragment::isBlock
2480         to wasBlock so that they don't conflict with isBlock and because
2481         it's more descriptive.
2482
2483         * editing/ReplaceSelectionCommand.cpp:
2484         (WebCore::ReplacementFragment::mergeStartNode):
2485         (WebCore::ReplacementFragment::wasBlock):
2486         (WebCore::ReplacementFragment::saveRenderingInfo):
2487         (WebCore::ReplacementFragment::renderedBlocks):
2488         (WebCore::RenderingInfo::RenderingInfo):
2489         (WebCore::ReplaceSelectionCommand::shouldMergeStart):
2490         (WebCore::ReplaceSelectionCommand::doApply):
2491         * editing/ReplaceSelectionCommand.h:
2492         (WebCore::RenderingInfo::wasBlock):
2493
2494 2006-07-27  Justin Garcia  <justin.garcia@apple.com>
2495
2496         Reviewed by levi
2497         
2498         More changes for:
2499         <rdar://problem/4242293>
2500         Poor paste fidelity of http://www.google.com/
2501
2502         * editing/markup.cpp:
2503         (WebCore::needInterchangeNewlineAfter): Added.
2504         (WebCore::createMarkup): 
2505         Only add an interchangeNewline if we're annotating for interchange.  Can't test 
2506         this until we expose createMarkup in non-annotate mode (I'd expose Range::toHTML).
2507         Remove the FIXME about prepending the interchangeNewline before creating the rest 
2508         of the markup.  Its correct to surround the interchangeNewline in ancestors of the
2509         adjusted startNode.
2510         Fixed the check to see if an interchangeNewline is needed (!inSameBlock).  This would
2511         add an interchangeNewline for a selection that started before a table.
2512         Removed the workaround for the bug where markup for a table was not included when 
2513         selecting the contents of a table, since this change fixes the general problem of 
2514         markup for ancestors of the startNode being left out.
2515         Don't leave out ancestors of the startNode as we leave their subtrees.  Execute the
2516         code to include them even if we closed ancestors in the ancestorsToClose list.
2517
2518 2006-07-28  Timothy Hatcher  <timothy@apple.com>
2519
2520         Reviewed by John.
2521
2522         Adding isContentEditable to DOMNode's private category. 
2523
2524         * bindings/objc/DOMPrivate.h:
2525
2526 2006-07-28  Alexey Proskuryakov  <ap@nypop.com>
2527
2528         Rolling out http://bugzilla.opendarwin.org/show_bug.cgi?id=6010 because of failing layout tests.
2529         Add better SVGLoad event support.
2530
2531         * dom/EventTargetNode.cpp:
2532         (WebCore::EventTargetNode::dispatchGenericEvent):
2533         * html/HTMLImageLoader.cpp:
2534         (WebCore::HTMLImageLoader::dispatchLoadEvent):
2535         * html/HTMLImageLoader.h:
2536         * ksvg2/misc/SVGImageLoader.cpp:
2537         (WebCore::SVGImageLoader::SVGImageLoader):
2538         * ksvg2/misc/SVGImageLoader.h:
2539         * ksvg2/svg/SVGAElement.cpp:
2540         (WebCore::SVGAElement::parseMappedAttribute):
2541         * ksvg2/svg/SVGAnimatedBoolean.h:
2542         * ksvg2/svg/SVGElement.cpp:
2543         (WebCore::SVGElement::SVGElement):
2544         (WebCore::SVGElement::parseMappedAttribute):
2545         * ksvg2/svg/SVGElement.h:
2546         (WebCore::SVGElement::adjustViewportClipping):
2547         (WebCore::SVGElement::closeRenderer):
2548         (WebCore::SVGElement::rendererIsNeeded):
2549         (WebCore::SVGElement::isClosed):
2550         (WebCore::svg_dynamic_cast):
2551         * ksvg2/svg/SVGExternalResourcesRequired.h:
2552         * ksvg2/svg/SVGImageElement.cpp:
2553         (SVGImageElement::SVGImageElement):
2554         * ksvg2/svg/SVGImageElement.h:
2555         * ksvg2/svg/SVGSVGElement.cpp:
2556         (WebCore::SVGSVGElement::parseMappedAttribute):
2557         * ksvg2/svg/SVGScriptElement.cpp:
2558         (SVGScriptElement::SVGScriptElement):
2559         (SVGScriptElement::parseMappedAttribute):
2560         (SVGScriptElement::executeScript):
2561         * xml/xmlhttprequest.cpp:
2562         (WebCore::XMLHttpRequest::callReadyStateChangeListener):
2563
2564 2006-07-28  Adele Peterson  <adele@apple.com>
2565
2566         Rolling out http://bugzilla.opendarwin.org/show_bug.cgi?id=9753 because of failing layout tests.
2567         SVG with width and height 100% leaves room for scrollbar on the right.
2568
2569         * kcanvas/RenderPath.cpp:
2570         * kcanvas/RenderPath.h:
2571         * kcanvas/RenderSVGContainer.cpp:
2572         (WebCore::RenderSVGContainer::layout):
2573         * ksvg2/svg/SVGCircleElement.cpp:
2574         * ksvg2/svg/SVGCircleElement.h:
2575         * ksvg2/svg/SVGEllipseElement.cpp:
2576         * ksvg2/svg/SVGEllipseElement.h:
2577         * ksvg2/svg/SVGLineElement.cpp:
2578         * ksvg2/svg/SVGLineElement.h:
2579         * ksvg2/svg/SVGRectElement.cpp:
2580         * ksvg2/svg/SVGRectElement.h:
2581         * ksvg2/svg/SVGStyledElement.h:
2582
2583 2006-07-27  Eric Seidel  <eric@eseidel.com>
2584
2585         Reviewed by darin.
2586         
2587         Add better SVGLoad event support.
2588         http://bugzilla.opendarwin.org/show_bug.cgi?id=6010
2589         There will still need to be additional support added for <link> and <script> elements.
2590         Not all of the error -> loaded -> error transition cases work yet.
2591
2592         * dom/EventTargetNode.cpp:
2593         (WebCore::EventTargetNode::dispatchGenericEvent):
2594         * html/HTMLImageLoader.cpp:
2595         (WebCore::HTMLImageLoader::dispatchLoadEvent):
2596         * html/HTMLImageLoader.h:
2597         (WebCore::HTMLImageLoader::haveFiredLoadEvent):
2598         (WebCore::HTMLImageLoader::setHaveFiredLoadEvent):
2599         * ksvg2/misc/SVGImageLoader.cpp:
2600         (WebCore::SVGImageLoader::SVGImageLoader):
2601         (WebCore::SVGImageLoader::dispatchLoadEvent):
2602         * ksvg2/misc/SVGImageLoader.h:
2603         * ksvg2/svg/SVGAElement.cpp:
2604         (WebCore::SVGAElement::parseMappedAttribute):
2605         * ksvg2/svg/SVGAnimatedBoolean.h:
2606         * ksvg2/svg/SVGElement.cpp:
2607         (WebCore::SVGElement::SVGElement):
2608         (WebCore::SVGElement::parseMappedAttribute):
2609         (WebCore::SVGElement::haveLoadedRequiredResources):
2610         (WebCore::SVGElement::sendSVGLoadEventIfPossible):
2611         (WebCore::SVGElement::closeRenderer):
2612         * ksvg2/svg/SVGElement.h:
2613         (WebCore::SVGElement::rendererIsNeeded):
2614         (WebCore::svg_dynamic_cast):
2615         * ksvg2/svg/SVGExternalResourcesRequired.h:
2616         * ksvg2/svg/SVGImageElement.cpp:
2617         (SVGImageElement::SVGImageElement):
2618         (SVGImageElement::haveLoadedRequiredResources):
2619         * ksvg2/svg/SVGImageElement.h:
2620         * ksvg2/svg/SVGSVGElement.cpp:
2621         (WebCore::SVGSVGElement::parseMappedAttribute):
2622         * ksvg2/svg/SVGScriptElement.cpp:
2623         (WebCore::SVGScriptElement::SVGScriptElement):
2624         (WebCore::SVGScriptElement::parseMappedAttribute):
2625         (WebCore::SVGScriptElement::executeScript):
2626         * xml/xmlhttprequest.cpp:
2627         (WebCore::XMLHttpRequest::callReadyStateChangeListener): use new Event() instead of createEvent
2628
2629 2006-07-27  Mitz Pettel  <opendarwin.org@mitzpettel.com>
2630
2631         Reviewed by Anders.
2632
2633         - http://bugzilla.opendarwin.org/show_bug.cgi?id=10135
2634           Cleanup: remove useless parameters from RenderObject::position()
2635
2636         No test possible (no functionality change)
2637
2638         * rendering/RenderBox.cpp:
2639         (WebCore::RenderBox::position):
2640         * rendering/RenderBox.h:
2641         * rendering/RenderObject.h:
2642         (WebCore::RenderObject::position):
2643         * rendering/RenderTableRow.h:
2644         (WebCore::RenderTableRow::position):
2645         * rendering/RenderTableSection.h:
2646         (WebCore::RenderTableSection::position):
2647         * rendering/RenderText.cpp:
2648         (WebCore::RenderText::position):
2649         * rendering/RenderText.h:
2650         * rendering/bidi.cpp:
2651         (WebCore::RenderBlock::constructLine):
2652         (WebCore::RenderBlock::computeVerticalPositionsForLine):
2653
2654 2006-07-27  Rob Buis  <buis@kde.org>
2655
2656         Reviewed by Maciej.
2657
2658         http://bugzilla.opendarwin.org/show_bug.cgi?id=9753
2659         SVG with width and height 100% leaves room for scrollbar on the right.
2660
2661         Relayout children of svg containers, except svg shapes that do not depend on percentages.
2662
2663         * kcanvas/RenderPath.cpp: (WebCore::RenderPath::hasPercentageValues):
2664         * kcanvas/RenderPath.h:
2665         * kcanvas/RenderSVGContainer.cpp: (WebCore::RenderSVGContainer::layout):
2666         * ksvg2/svg/SVGCircleElement.cpp: (SVGCircleElement::hasPercentageValues):
2667         * ksvg2/svg/SVGCircleElement.h:
2668         * ksvg2/svg/SVGEllipseElement.cpp: (WebCore::SVGEllipseElement::hasPercentageValues):
2669         * ksvg2/svg/SVGEllipseElement.h:
2670         * ksvg2/svg/SVGLineElement.cpp: (SVGLineElement::hasPercentageValues):
2671         * ksvg2/svg/SVGLineElement.h:
2672         * ksvg2/svg/SVGRectElement.cpp: (WebCore::SVGRectElement::hasPercentageValues):
2673         * ksvg2/svg/SVGRectElement.h:
2674         * ksvg2/svg/SVGStyledElement.h: (WebCore::SVGStyledElement::hasPercentageValues):
2675
2676 2006-07-27  Justin Garcia  <justin.garcia@apple.com>
2677
2678         Reviewed by levi
2679         
2680         <rdar://problem/4242293>
2681         Poor paste fidelity of http://www.google.com/
2682
2683         * editing/ApplyStyleCommand.cpp:
2684         (WebCore::ApplyStyleCommand::applyInlineStyle):  Fixed crasher with nil-check.
2685         * editing/markup.cpp:
2686         (WebCore::startMarkup): Style information wasn't added to an element if it had
2687         attributes but no style attribute.
2688
2689 2006-07-27  Alexander Kellett  <lypanov@kde.org>
2690
2691         Reviewed by Darin.
2692
2693         - fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=9867
2694           REGRESSION: code that modifies form element in Firefox modifies form attribute in WebKit
2695
2696         * bindings/scripts/CodeGeneratorJS.pm: add new attribute - HasOverridingNameGetter
2697         * html/HTMLFormElement.idl:
2698
2699 2006-07-27  Rob Buis  <buis@kde.org>
2700
2701         Reviewed by Anders.
2702
2703         http://bugzilla.opendarwin.org/show_bug.cgi?id=8992
2704         Some HTML DOM attributes have incorrect types
2705
2706         Adjust idl and dom source code for HTMLImageElement and
2707         HTMLBaseFontElement to choose correct type for
2708         HTMLImageElement::border and HTMLBaseFontElement::size
2709         attributes.
2710
2711         * html/HTMLBaseFontElement.cpp:
2712         (WebCore::HTMLBaseFontElement::size):
2713         (WebCore::HTMLBaseFontElement::setSize):
2714         * html/HTMLBaseFontElement.h:
2715         * html/HTMLBaseFontElement.idl:
2716         * html/HTMLImageElement.cpp:
2717         (WebCore::HTMLImageElement::border):
2718         (WebCore::HTMLImageElement::setBorder):
2719         * html/HTMLImageElement.h:
2720         * html/HTMLImageElement.idl:
2721
2722 2006-07-27  Justin Garcia  <justin.garcia@apple.com>
2723
2724         Reviewed by levi
2725         
2726         <rdar://problem/4628409>
2727         Safari crashes in CompositeEditCommand::removeBlockPlaceholder entering text in a web page form
2728
2729         * editing/CompositeEditCommand.cpp:
2730         (WebCore::CompositeEditCommand::removeBlockPlaceholder): 
2731         A script on the page shrinks the textarea down to zero rows just
2732         before insertion.  That gives the shadow div a zero height, removing
2733         [div, 0] as a candidate for a VisiblePosition.  Then 
2734         InsertTextCommand::input() tries to create a VisiblePosition from 
2735         [div, 0] and fails.  A nil check is a quick fix.  Another might
2736         be to make positions where there is a caret selection candidates.
2737         Another might be to make any [div, 0] where div is a shadow div inside
2738         a form element a candidate.
2739
2740 2006-07-27  Graham Dennis  <graham.dennis@gmail.com>
2741
2742         Reviewed by Darin.
2743
2744         - fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=10094
2745           Japanese characters improperly rendering in TOT
2746           
2747         Test: fast/encoding/denormalised-voiced-japanese-chars.html
2748
2749         * platform/Font.cpp:
2750         (WebCore::WidthIterator::advance): pass currentCharacter to normalizeVoicingMarks
2751         (WebCore::WidthIterator::normalizeVoicingMarks): turn the currentCharacter variable
2752         into an argument as WidthIterator::advance doesn't update m_currentCharacter while
2753         looping
2754
2755 2006-07-27  Eric Seidel  <eric@eseidel.com>
2756
2757         Reviewed by ap.
2758
2759         Complex entities seem to fail on TOT
2760         http://bugzilla.opendarwin.org/show_bug.cgi?id=6390
2761         Use an alternative work-around to an XML Entity parsing bug.
2762
2763         * dom/XMLTokenizer.cpp:
2764         (WebCore::XMLTokenizer::write):
2765         (WebCore::hackAroundLibXMLEntityBug): added.
2766         (WebCore::startElementNsHandler):
2767         (WebCore::endElementNsHandler):
2768         (WebCore::charactersHandler):
2769         (WebCore::processingInstructionHandler):
2770         (WebCore::cdataBlockHandler):
2771         (WebCore::commentHandler):
2772         (WebCore::getEntityHandler):
2773
2774 2006-07-27  Rob Buis  <buis@kde.org>
2775
2776         Reviewed by Darin.
2777
2778         http://bugzilla.opendarwin.org/show_bug.cgi?id=9938
2779         Fix viewBox issues in Hixie's test
2780
2781         Do a more accurate and quicker job of parsing the viewBox
2782         attribute. Handle properly on negative width/height and
2783         invalid syntax in general.
2784
2785         * ksvg2/svg/SVGFitToViewBox.cpp:
2786         (SVGFitToViewBox::parseViewBox):
2787
2788 2006-07-27  Eric Seidel  <eric@eseidel.com>
2789
2790         Reviewed by ap.
2791
2792         Enables getSVGDocument() support for HTMLObjectElement and HTMLEmbedElement
2793         http://bugzilla.opendarwin.org/show_bug.cgi?id=9237
2794         This patch does not try to autogenerate anything, but enables the SVG functionality.
2795         Also fix HTMLObjectElement vspace and hspace to be numbers instead of strings to match IE & Firefox.
2796
2797         * bindings/js/kjs_dom.cpp:
2798         (KJS::toJS):
2799         * bindings/js/kjs_html.cpp:
2800         (KJS::JSHTMLElement::objectGetter):
2801         (KJS::HTMLElementFunction::callAsFunction):
2802         (KJS::JSHTMLElement::objectSetter):
2803         * bindings/js/kjs_html.h:
2804         (KJS::JSHTMLElement::):
2805         * dom/Document.h:
2806         (WebCore::Document::isSVGDocument):
2807         * html/HTMLEmbedElement.cpp:
2808         (WebCore::HTMLEmbedElement::contentDocument):
2809         (WebCore::HTMLEmbedElement::getSVGDocument):
2810         * html/HTMLEmbedElement.h:
2811         * html/HTMLObjectElement.cpp:
2812         (WebCore::HTMLObjectElement::HTMLObjectElement):
2813         (WebCore::HTMLObjectElement::getInstance):
2814         (WebCore::HTMLObjectElement::parseMappedAttribute):
2815         (WebCore::HTMLObjectElement::contentDocument):
2816         (WebCore::HTMLObjectElement::rendererIsNeeded):
2817         (WebCore::HTMLObjectElement::createRenderer):
2818         (WebCore::HTMLObjectElement::setCode):
2819         (WebCore::HTMLObjectElement::setArchive):
2820         (WebCore::HTMLObjectElement::setBorder):
2821         (WebCore::HTMLObjectElement::setCodeBase):
2822         (WebCore::HTMLObjectElement::setCodeType):
2823         (WebCore::HTMLObjectElement::setData):
2824         (WebCore::HTMLObjectElement::hspace):
2825         (WebCore::HTMLObjectElement::setHspace):
2826         (WebCore::HTMLObjectElement::setStandby):
2827         (WebCore::HTMLObjectElement::setType):
2828         (WebCore::HTMLObjectElement::setUseMap):
2829         (WebCore::HTMLObjectElement::vspace):
2830         (WebCore::HTMLObjectElement::setVspace):
2831         (WebCore::HTMLObjectElement::getSVGDocument):
2832         * html/HTMLObjectElement.h:
2833         * ksvg2/svg/SVGDocument.h:
2834         (WebCore::SVGDocument::isSVGDocument):
2835         * rendering/RenderWidget.h:
2836         (WebCore::RenderWidget::frameView):
2837
2838 2006-07-26  Alexey Proskuryakov  <ap@nypop.com>
2839
2840         Reviewed by Darin.
2841
2842         Fix http://bugzilla.opendarwin.org/show_bug.cgi?id=9901
2843         XSLTProcessor cannot parse text nodes for INPUT ELEMENTS in an XSLT stylesheet
2844
2845         Test: fast/js/xhtml-serialize.html
2846
2847         * editing/markup.cpp:
2848         (WebCore::endMarkup): If the element has child nodes, write a closing tag even if it 
2849         is not permitted in HTML, to make it valid XML.
2850
2851 2006-07-26  Alice Liu  <alice.liu@apple.com>
2852
2853         Reviewed by John Sullivan (and Kevin and Timo).
2854
2855         landing this patch for John et al.  
2856         Fixed <rdar://problem/4651380> REGRESSION (9A232->9A234): existing web clips don't render if you restart Dashboard
2857
2858         * page/FrameView.cpp:
2859         (WebCore::FrameView::layout):
2860         moved the call to didFirstLayout to above the check for needsLayout
2861         because we need to call didFirstLayout for every webview, not just
2862         ones we think need layout.  
2863
2864 2006-07-26  Justin Garcia  <justin.garcia@apple.com>
2865
2866         Reviewed by darin
2867         
2868         <rdar://problem/4652788>
2869         REGRESSION: Can't change size or style of any text in message body
2870
2871         * dom/Node.cpp:
2872         (WebCore::Node::isContentRichlyEditable): Mimic Node::isContentEditable.
2873         * html/HTMLElement.cpp:
2874         (WebCore::HTMLElement::isContentRichlyEditable): First check
2875         the frame for editability, then userModify, like what
2876         HTMLElement::isContentEditable() does.
2877         * html/HTMLElement.h:
2878
2879 2006-07-26  Mitz Pettel  <opendarwin.org@mitzpettel.com>
2880
2881         Reviewed by ap.
2882
2883         - fix debug-only information() string for table cells
2884
2885         * rendering/RenderObject.cpp:
2886         (WebCore::RenderObject::information):
2887
2888 2006-07-25  David Harrison  <harrison@apple.com>
2889
2890         Reviewed by timo and Darin.
2891
2892         <rdar://problem/4618584> "Paste and Match Style" is not working in Mail (add SPI)
2893         
2894         * WebCore.xcodeproj/project.pbxproj:
2895         * bridge/mac/WebCoreFrameBridge.h:
2896         * bridge/mac/WebCoreFrameBridge.mm:
2897         (-[WebCoreFrameBridge replaceSelectionWithNode:selectReplacement:smartReplace:matchStyle:]):
2898         Add matchStyle parameter for use by WebKit.
2899
2900 2006-07-25  Justin Garcia  <justin.garcia@apple.com>
2901
2902         Reviewed by adele
2903         
2904         <rdar://problem/4649560>
2905         REGRESSION: Can't Select All when the body is contentEditable="true"
2906
2907         * editing/VisiblePosition.cpp:
2908         (WebCore::VisiblePosition::canonicalPosition): Allow descent from a non-editable html
2909         element into an editable body as a convenience.
2910
2911 2006-07-25  Justin Garcia  <justin.garcia@apple.com>
2912
2913         Reviewed by darin
2914         
2915         <rdar://problem/4468458> Incoming HTML message is editable <body contenteditable="true">
2916
2917         * dom/Document.cpp:
2918         (WebCore::Document::inDesignMode): Removed some spaces.
2919         * page/Frame.cpp:
2920         (WebCore::Frame::applyEditingStyleToElement): Just add CSS properties needed for editing.
2921         (WebCore::Frame::removeEditingStyleFromElement): Made this a no-op, we'll remove
2922         it eventually.
2923
2924 2006-07-25  David Kilzer  <ddkilzer@kilzer.net>
2925
2926         Reviewed by Darin.
2927
2928         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=9717
2929           Replace IDL ConvertUndefinedToTrue parameter attribute with Optional attribute
2930
2931         No test added because there is no change in functionality.
2932
2933         * bindings/js/kjs_binding.cpp: Removed valueToBooleanTreatUndefinedAsTrue() method.
2934         * bindings/js/kjs_binding.h: Ditto.
2935         * bindings/scripts/CodeGeneratorJS.pm: Removed support for ConvertUndefinedToTrue parameter attribute.
2936         * dom/Element.h: Set default value to true for scrollIntoView() and scrollIntoViewIfNeeded() arguments.
2937         * dom/Element.idl: Replaced ConvertUndefinedToTrue attribute with Optional attribute.
2938           Fixed name of scrollIntoViewIfNeeded() argument to match implementation.
2939         * page/DOMWindow.idl: Replaced ConvertUndefinedToTrue attribute with Optional attribute.
2940
2941 2006-07-24  Dan Waylonis  <waylonis@google.com>
2942
2943         Reviewed and tweaked a bunch by Darin.
2944
2945         Test: plugins/bindings-test.html
2946
2947         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=9902
2948           jsNull and NSNull not properly converted between JS and ObjC
2949
2950         * bindings/objc/WebScriptObject.mm:
2951         (+[WebScriptObject _convertValueToObjcValue:originExecutionContext:executionContext:]):
2952         Added case that converts jsNull to NSNull.
2953
2954 2006-07-24  Darin Adler  <darin@apple.com>
2955
2956         Reviewed by Adele and Justin.
2957
2958         - fix <rdar://problem/4613616> REGRESSION: some spaces typed in <textarea> are posted as non-breaking spaces (9630)
2959           http://bugzilla.opendarwin.org/show_bug.cgi?id=9630
2960         - also fixes http://bugzilla.opendarwin.org/show_bug.cgi?id=9939
2961           REGRESSION: Pasting text into native text area with newline at end does not preserve newline
2962         - removed some uses of DeprecatedPtrList in the markup code
2963
2964         Test: fast/forms/textarea-type-spaces.html
2965         Test: fast/forms/textarea-paste-newline.html
2966
2967         * bindings/objc/DOMHTML.mm: (-[DOMHTMLDocument createDocumentFragmentWithText:]):
2968         Updated call to pass a range -- in this case it is the range of the entire document,
2969         so this will not handle the whitespace properly.
2970
2971         * bridge/mac/WebCoreFrameBridge.h: Added range context parameter to the
2972         documentFragmentWithText: method, so we can handle whitespace properly.
2973         * bridge/mac/WebCoreFrameBridge.mm:
2974         (-[WebCoreFrameBridge nodesFromList:]): Changed from DeprecatedPtrList to Vector.
2975         (-[WebCoreFrameBridge markupStringFromNode:nodes:]): Ditto.
2976         (-[WebCoreFrameBridge markupStringFromRange:nodes:]): Ditto.
2977         (-[WebCoreFrameBridge documentFragmentWithText:inContext:]): Added range context
2978         parameter -- pass it on to createFragmentFromText.
2979         (-[WebCoreFrameBridge documentFragmentWithNodesAsParagraphs:]): Changed from
2980         DeprecatedPtrList to Vector.
2981         (-[WebCoreFrameBridge replaceSelectionWithText:selectReplacement:smartReplace:]):
2982         Pass the range of the current selection as context when creating the fragment.
2983
2984         * dom/Position.cpp: (WebCore::Position::inRenderedText): Replace range check with
2985         a call to the new containsCaretOffset function -- helps make the caret work right when
2986         it is past the end of the last line in a textarea.
2987
2988         * editing/CompositeEditCommand.cpp:
2989         (WebCore::CompositeEditCommand::rebalanceWhitespaceAt): Don't do anything if the
2990         style does not call for collapsing whitespace.
2991         (WebCore::CompositeEditCommand::rebalanceWhitespace): Call replaceWhitespaceAt
2992         to share code, including the new logic mentioned above.
2993
2994         * editing/InsertLineBreakCommand.cpp: (WebCore::InsertLineBreakCommand::doApply):
2995         Use a text node instead of a break element when inserting and the style is preserveNewline.
2996
2997         * editing/JSEditor.cpp: (WebCore::execRemoveFormat): Pass the selection range
2998         to createFragmentFromText.
2999
3000         * editing/RebalanceWhitespaceCommand.cpp: (WebCore::RebalanceWhitespaceCommand::doApply):
3001         Assert that we're in a style that collapses whitespace. It's the caller's responsibility
3002         not to call otherwise.
3003
3004         * editing/ReplaceSelectionCommand.h: Removed unused destructor, type, isSingleTextNode,
3005         isTreeFragment, m_type, and added a context parameter to inertFragmentForTestRendering.
3006         Also changed the constructor to take a selection rather than a pointer to the root
3007         editable element, replaced removeEndBRIfNeeded with shouldRemoveEndBR and removed an
3008         unused parameter from shouldMergeEnd.
3009         * editing/ReplaceSelectionCommand.cpp:
3010         (WebCore::ReplacementFragment::ReplacementFragment): Removed code to set up m_type.
3011         Compute root editable element from passed-in selection. Used the start of the selection
3012         as a base node for style purposes for the test rendering. Removed the special case
3013         "single text node" alternative to createFragmentFromText in the plain text case, since
3014         createFragmentFromText now handles that correctly.
3015         (WebCore::ReplacementFragment::insertFragmentForTestRendering): Copy the whitespace
3016         property from the source location when creating a temporary element for test rendering.
3017         (WebCore::ReplacementFragment::shouldMergeEnd): Removed unneeded boolean
3018         parameter fragmentHadInterchangeNewlineAtEnd, which is always false.
3019         (WebCore::ReplaceSelectionCommand::doApply): Update for ReplacementFragment changes,
3020         change code to not remove end BR when it can be re-used instead, don't call the
3021         paragraph separator insertion when the position is at the start of a paragraph already,
3022         removed redundant computation of identical "next" value, removed unneeded boolean
3023         parameter to shouldMergeEnd, add case for merging when all we need to do is to delete
3024         a newline character, removed unneeded code to set insertionPos after all code that uses
3025         it, and  use spaces instead of non-breaking spaces when doing smart paste if the
3026         context is one where we do not collapse white space.
3027         (WebCore::ReplaceSelectionCommand::shouldRemoveEndBR): Renamed and changed to return
3028         a boolean instead of doing the removal.
3029
3030         * editing/markup.h: Use Vector instead of DeprecatedPtrList. Change the
3031         createFragmentFromText function to take a range for context instead of a document.
3032         * editing/markup.cpp:
3033         (WebCore::markup): Use Vector instead of DeprecatedPtrList.
3034         (WebCore::createMarkup): Ditto.
3035         (WebCore::createParagraphContentsFromString): Remove unneeded document parameter
3036         and changed a couple places to use isEmpty instead of comparing with "".
3037         (WebCore::createFragmentFromText): Given the new context parameter, if the context
3038         is one that preserves newlines, then use "\n" instead of <br> elements.
3039         (WebCore::createFragmentFromNodes): Use Vector instead of DeprecatedPtrList.
3040
3041         * html/HTMLElement.cpp: (WebCore::HTMLElement::setInnerText): Do not use <br>
3042         elements if the context of this node is one where we preserve newlines.
3043
3044         * rendering/InlineTextBox.h:
3045         * rendering/InlineTextBox.cpp: (WebCore::InlineTextBox::containsCaretOffset):
3046         Added. Implements the appropriate rule for determining if a caret position is
3047         in this line or not. Returns true for both one line and the next in cases where
3048         affinity must be considered to determine which line the caret is on.
3049
3050         * rendering/RenderText.h: Make atLineWrap no longer be a member function.
3051         * rendering/RenderText.cpp:
3052         (WebCore::atLineWrap): Remove special rule about preserveNewline and isLineBreak,
3053         which will no longer apply due to the new containsCaretOffset function logic.
3054         (WebCore::RenderText::caretRect): Use containsCaretOffset.
3055         (WebCore::RenderText::inlineBox): Ditto.
3056
3057         * rendering/RenderTextControl.cpp:
3058         (WebCore::RenderTextControl::updateFromElement): Make a placeholder <br> element
3059         after calling setInnerText so that the last newline in the string has the effect
3060         we expect outside the HTML world (an additional line).
3061         (WebCore::RenderTextControl::setSelectionRange): Set granularity of the selection
3062         too. The layout tests caught this problem, which needs a better solution long term.
3063         (WebCore::RenderTextControl::text): Call textContent with the parameter false
3064         so it will not include newlines for <br> elements. Now the only <br> element
3065         that will ever be in the shadow DOM tree is the one to prevent collapsing, and
3066         that one should not show up in the text value.
3067
3068         * rendering/bidi.cpp: (WebCore::RenderBlock::findNextLineBreak): Took a rule
3069         that specifically called out the pre whitespace mode and made it work for all
3070         the modes that preserve newlines. This makes sure we get a last line box for
3071         text after the last "\n" even in cases where there is no <br> afterward.
3072
3073         * editing/DeleteSelectionCommand.cpp:
3074         (WebCore::DeleteSelectionCommand::fixupWhitespace):
3075         * editing/InsertParagraphSeparatorCommand.cpp:
3076         (WebCore::InsertParagraphSeparatorCommand::doApply):
3077         Added assertions to make sure we don't do anything when we're not collapsing
3078         whitespace.
3079
3080         * html/HTMLTextAreaElement.cpp: (WebCore::HTMLTextAreaElement::setDefaultValue):
3081         Changed to use Vector instead of DeprecatedPtrList.
3082
3083         * editing/HTMLInterchange.cpp: Removed obsolete comment.
3084
3085         * loader/Cache.h: Removed a stray include.
3086
3087 2006-07-24  Adele Peterson  <adele@apple.com>
3088
3089         Reviewed by Justin.
3090
3091         - Fix for <rdar://problem/4632132> Changing style of content with mixed editability fails
3092
3093         Test: * editing/style/apple-style-editable-mix.html
3094
3095         * dom/Node.cpp: (WebCore::Node::isContentRichlyEditable): Doesn't need to check the editable root.  It now just
3096           checks the user modify property of its own renderer, since that is inherited.
3097         * editing/ApplyStyleCommand.cpp: (WebCore::ApplyStyleCommand::applyInlineStyle): If the end position is in a table,
3098         Adjust the end node to the last descendant of the table, so we don't skip over any runs.
3099
3100 2006-07-24  Darin Adler  <darin@apple.com>
3101
3102         Reviewed by Hyatt.
3103
3104         - implement String::createCFString
3105
3106         * WebCore.xcodeproj/project.pbxproj: Added StringImplMac.mm and StringMac.mm.
3107
3108         * bindings/objc/DOMInternal.mm: Moved NSString conversion functions out of here.
3109
3110         * platform/mac/StringImplMac.mm: Added. Moved NSString conversion members here
3111         and added the CFStringRef ones.
3112         * platform/mac/StringMac.mm: Added. Ditto.
3113
3114 2006-07-24  David Hyatt  <hyatt@apple.com>
3115
3116         Two bug fixes.
3117
3118         (1) Make sure to mark positioned objects that depend on line position to
3119         mark themselves as needing layout when their line box placeholder gets
3120         repositioned.
3121
3122         * rendering/RenderBox.cpp:
3123         (WebCore::RenderBox::position):
3124        
3125         (2) Improve highlighting to factor the inflation into overflow so that
3126         invalidation and repainting will work properly.
3127
3128         * rendering/RootInlineBox.cpp:
3129         (WebCore::RootInlineBox::addHighlightOverflow):
3130         * rendering/RootInlineBox.h:
3131         * rendering/bidi.cpp:
3132         (WebCore::RenderBlock::layoutInlineChildren):
3133
3134 2006-07-24  Anders Carlsson  <acarlsson@apple.com>
3135
3136         Reviewed by Adele.
3137
3138         <rdar://problem/4641824> REGRESSION: Wikipedia widget fails to complete a search after pressing return key
3139         
3140         * html/HTMLInputElement.cpp:
3141         (WebCore::HTMLInputElement::defaultEventHandler):
3142         Don't eat enter events for search fields that have no enclosing form; they need to be passed to AppKit so
3143         that onsearch can be invoked.
3144         
3145         * manual-tests/onsearch-enter.html: Added.
3146
3147 2006-07-24  Dave MacLachlan  <dmaclach@mac.com>
3148
3149         Reviewed by Darin and Alexey.
3150         
3151         Fix for: <http://bugzilla.opendarwin.org/show_bug.cgi?id=8425> 
3152         and <http://bugzilla.opendarwin.org/show_bug.cgi?id=6947>
3153
3154         Test: svg/custom/non-opaque-filters.svg
3155
3156         * kcanvas/device/quartz/KCanvasFilterQuartz.mm:
3157         (WebCore::KCanvasFilterQuartz::prepareFilter):
3158         We create an autorelease pool so we can control the deallocation of the
3159         CIContext that we're creating. The CIContext retains the CGContext that 
3160         you pass it internally so when the CIContext is released, the 
3161         CGContext is released as well.
3162         This is all fine and dandy unless you wrap the creation of the CIFilter
3163         with a pair of CGBegin/EndTransparencyLayer calls which swap the context
3164         out from underneath you. So if you start with context A, 
3165         CGBeginTransparencyLayer swaps it out and gives you B. You create a CIFilter
3166         with it and add a reference to B. CGEndTransparencyLayer swaps out B and
3167         gives you back A. Autorelease pool comes and cleans up the Filter, and calls
3168         release on A, but A never got the refcount in the first place. B did. BOOM!
3169         So we create a pool, then do a retain, then release the pool so that we 
3170         don't have to worry about the pool releasing it at a later time.
3171         See <rdar://problem/4647735> for reduction of CGEndTransparencyLayer case
3172
3173 2006-07-24  Mitz Pettel  <opendarwin.org@mitzpettel.com>
3174
3175         Reviewed by Hyatt.
3176
3177         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=9669
3178           Incomplete repaint when changing an inline's border
3179
3180         Test: fast/repaint/line-overflow.html
3181
3182         * rendering/RenderBlock.h:
3183         * rendering/bidi.cpp:
3184         (WebCore::RenderBlock::layoutInlineChildren): Added repaintTop and repaintBottom
3185         variables to track the vertical edges of the area that changed, accounting for
3186         lines that were deleted, inserted or moved. Removed unnecessary updating of
3187         m_overflowHeight.
3188         (WebCore::RenderBlock::determineStartPosition): Removed unnecessary updating of
3189         m_overflowHeight.
3190         (WebCore::RenderBlock::determineEndPosition):
3191         (WebCore::RenderBlock::matchedEndLine): Added repaintTop and repaintBottom
3192         arguments, which this method updates to account for deleted lines.
3193         (WebCore::RenderBlock::checkLinesForOverflow): Removed outdated FIXME.
3194
3195 2006-07-24  Mitz Pettel  <opendarwin.org@mitzpettel.com>
3196
3197         Reviewed by Darin.
3198
3199         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=10075
3200           REGRESSION: Reversed pop-up text in visually-ordered Hebrew pages
3201
3202         Test: fast/forms/select-visual-hebrew.html
3203
3204         * css/html4.css: Set "-webkit-rtl-ordering: logical" on select elements.
3205
3206 2006-07-24  Alexey Proskuryakov  <ap@nypop.com>
3207
3208         Reviewed by Darin.
3209
3210         Fix http://bugzilla.opendarwin.org/show_bug.cgi?id=10009
3211         REGRESSION: Schubert-IT PDF Plug-in not working for full page (works in frames)
3212
3213         * page/Frame.cpp:
3214         (WebCore::Frame::begin): Give PDF plugins a chance to handle frame content, before ImageDocument
3215         claims it.
3216
3217 2006-07-24  Mitz Pettel  <opendarwin.org@mitzpettel.com>
3218
3219         Reviewed by Darin.
3220
3221         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=10083
3222           REGRESSION (r15584): editing/selection/select-from-textfield-outwards failing
3223
3224         * rendering/RenderBlock.cpp:
3225         (WebCore::RenderBlock::positionForCoordinates): Added back change from the fix
3226         for bug 9312: For coordinates outside a replaced object, return the position
3227         just before (after) the element if the coordinates are above or to the left (below
3228         or to the right).
3229
3230 2006-07-23  Mark Rowe  <opendarwin.org@bdash.net.nz>
3231
3232         Reviewed by maciej.
3233
3234         Bug 9686: [Drosera] Need the ability to break into Drosera on Javascript exceptions
3235         http://bugzilla.opendarwin.org/show_bug.cgi?id=9686
3236
3237         WebCore portion of the fix.
3238
3239         * bridge/mac/WebCoreScriptDebugger.h:
3240         (-[WebScriptDebugger exceptionRaised:sourceId:line::]): Add delegate method.
3241         * bridge/mac/WebCoreScriptDebugger.mm:
3242         (WebCoreScriptDebuggerImp::exception): Call delegate method when an exception is raised.
3243
3244 2006-07-23  Alice Liu  <alice.liu@apple.com>
3245
3246         Reviewed by Adele.
3247         Actually Adele figured out how to fix the layout test failures.  Landing this patch for her.  Layout test failures exposed but not caused by  r15584 (my patch earlier today).
3248
3249         * editing/visible_units.cpp:
3250         (WebCore::previousLinePosition):
3251         When setting selection endpoints, don't traverse down into nodes where editing would ignore its contents. Use the parent node instead.  
3252         (WebCore::nextLinePosition):
3253         same as above
3254
3255 2006-07-23  David Harrison  <harrison@apple.com>
3256
3257         Reviewed by timo.
3258
3259         <rdar://problem/4646759> Mail crash editing To Do - WebCore::InsertTextCommand::prepareForTextInsertion
3260         
3261         * Test: editing/deleting/delete-mixed-editable-content-001.html
3262
3263         * editing/visible_units.cpp:
3264         (WebCore::startOfParagraph):
3265         Respect editable boundary the same way endOfParagraph does.
3266
3267 2006-07-23  Beth Dakin  <bdakin@apple.com>
3268
3269         Reviewed by Maciej. (Patch by me, Maciej, and Harrison.)
3270
3271         Fix for <rdar://problem/4529398> WebCore crashes when pasting rich 
3272         text - WebCore::InlineBox::root()
3273
3274         The initial rendering crash was due to a render object having a 
3275         stale reference to an inline box that had already been deleted and 
3276         then recreated in the exact same location in memory. (Crazy, I 
3277         know.) The situation seemed pretty specific to list markers 
3278         according to Hyatt according to Maciej, so that is what I patched 
3279         specifically. Fixing this crash unearthed a separate editing crash 
3280         where we were trying to insert a block into itself. I worked on 
3281         that with Maciej and Harrison, and Harrison came up with a fix.
3282
3283         * editing/CompositeEditCommand.cpp:
3284         (WebCore::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary): This is the fix for the editing crash. If paragraphStart is an atomic 
3285         node, insert the new block into the parent instead.
3286         * rendering/InlineBox.cpp:
3287         (WebCore::InlineBox::isChildOfParent): This function is for 
3288         posterity. It will help keep the linebox tree in check.
3289         * rendering/InlineBox.h:
3290         * rendering/InlineFlowBox.cpp:
3291         (WebCore::InlineFlowBox::addToLine): Added assert.
3292         (WebCore::InlineFlowBox::deleteLine): Added assert.
3293         * rendering/ListMarkerBox.cpp:
3294         (WebCore::ListMarkerBox::destroy): If this has a parent, call 
3295         removeChild on this.
3296         (WebCore::ListMarkerBox::operator delete):
3297         * rendering/ListMarkerBox.h:
3298
3299 2006-07-23  Alice Liu  <alice.liu@apple.com>
3300
3301         Reviewed by Darin.
3302
3303         fixed <rdar://problem/4617841> REGRESSION (NativeTextField): You can move keyboard focus to a field without getting insertion point
3304
3305         * rendering/RenderBlock.cpp:
3306         (WebCore::RenderBlock::positionForCoordinates):
3307         removed some unnecessary vertical position checks and added a fudge factor to be more forgiving for clicks near lines.
3308         * rendering/RenderTextControl.cpp:
3309         (WebCore::RenderTextControl::nodeAtPoint):
3310         added implementation
3311         * rendering/RenderTextControl.h:
3312         added function protocol
3313
3314 2006-07-23  Adele Peterson  <adele@apple.com>
3315
3316         Reviewed by Darin.
3317
3318         Updating fix from last checkin.
3319
3320         * rendering/RenderFlexibleBox.cpp: (WebCore::RenderFlexibleBox::layoutVerticalBox):
3321         Only tell the view about this flexbox if there isn't another flexbox already cached.
3322
3323 2006-07-23  Adele Peterson  <adele@apple.com>
3324
3325         Reviewed by Maciej.
3326
3327         - Fix for <rdar://problem/4644614> REGRESSION: Typing, pasting or dragging in new text areas causes unnecessary scrolling
3328
3329         * rendering/RenderBlock.cpp: (WebCore::RenderBlock::layoutBlock): Don't updateScrollInfoAfterLayout if an ancestor flexible box is just on
3330         its first layout.
3331         * rendering/RenderFlexibleBox.cpp:
3332         (WebCore::RenderFlexibleBox::layoutBlock): ditto.
3333         (WebCore::RenderFlexibleBox::layoutVerticalBox): Let the view know if this flex box is doing its first pass at layout.
3334
3335         * rendering/RenderView.cpp: (WebCore::RenderView::RenderView): Caches a flexible box that's doing its first layout.
3336         * rendering/RenderView.h:
3337         (WebCore::RenderView::setFlexBoxInFirstLayout):
3338         (WebCore::RenderView::flexBoxInFirstLayout):
3339
3340 2006-07-22  Alexey Proskuryakov  <ap@nypop.com>
3341
3342         Reviewed by Darin.
3343
3344         Fix http://bugzilla.opendarwin.org/show_bug.cgi?id=10038
3345         REGRESSION: Length of navigator.mimeTypes collection returns number of installed plugins, not number 
3346         of registered mime types
3347
3348         * bindings/js/kjs_navigator.cpp:
3349         (KJS::MimeTypes::getValueProperty): Return the length of the mime types vector, not the plugins one.
3350         (KJS::MimeTypes::getOwnPropertySlot): Fixed another typo, which prevented MimeTypes::getValueProperty()
3351         from even being called.
3352
3353 2006-07-21  Maciej Stachowiak  <mjs@apple.com>
3354
3355         Reviewed by Adele and Tim Omernick.
3356
3357         <rdar://problem/4641004> 9A224: Safari crashes in WebCore::RenderMenuList::showPopup when changing a input select field to input text field
3358
3359         Couldn't figure out how to make layout test, here's a manual test:
3360         * manual-tests/remove-select-onchange.html: Added.
3361         
3362         * rendering/RenderMenuList.cpp:
3363         (WebCore::RenderMenuList::showPopup): Don't add the RenderPopupMenu to the render
3364         tree so it doesn't get destroyed if we do.
3365         
3366         The remaining changes are to let the RenderPopupMenu know its menu list w/o having
3367         to be in the render tree:
3368         
3369         * rendering/RenderPopupMenu.cpp:
3370         (WebCore::RenderPopupMenu::RenderPopupMenu):
3371         * rendering/RenderPopupMenu.h:
3372         (WebCore::RenderPopupMenu::menuList):
3373         * rendering/RenderPopupMenuMac.h:
3374         * rendering/RenderPopupMenuMac.mm:
3375         (WebCore::RenderPopupMenuMac::RenderPopupMenuMac):
3376         * rendering/RenderPopupMenuWin.h:
3377         (WebCore::RenderPopupMenuWin::RenderPopupMenuWin):
3378         * rendering/RenderTheme.h:
3379         * rendering/RenderThemeMac.h:
3380         * rendering/RenderThemeMac.mm:
3381         (WebCore::RenderThemeMac::createPopupMenu):
3382         * rendering/RenderThemeWin.cpp:
3383         (WebCore::RenderThemeWin::createPopupMenu):
3384         * rendering/RenderThemeWin.h:
3385
3386 2006-07-21  Adele Peterson  <adele@apple.com>
3387
3388         Reviewed by Darin.
3389
3390         Fix for: <rdar://problem/4643238> REGRESSION: Can't set insertion point at the end of a line of text
3391
3392         Test: fast/forms/textarea-scrolled-endline-caret.html
3393
3394         * rendering/RenderBlock.cpp: (WebCore::RenderBlock::positionForCoordinates):
3395         When looking for the closest line box, take the scroll offset into account.
3396
3397 2006-07-21  Tim Omernick  <timo@apple.com>
3398
3399         Reviewed by Geoff & Maciej.
3400
3401         <rdar://problem/4632505> REGRESSION: Crash at WebCore::Widget::getView() const + 6
3402
3403         Geoff is working on a layout test for this.
3404
3405         * bridge/mac/FrameMac.mm:
3406         (WebCore::FrameMac::focusWindow):
3407         (WebCore::FrameMac::unfocusWindow):
3408         Check for a NULL view.  The view can be NULL if the frame has not yet loaded any data.  This fixes the crash, but the behavior is still
3409         wrong -- we should focus the frame once it gets a view.  I've filed <rdar://problem/4645685> to track that.  It's not as urgent as this
3410         crasher.
3411         
3412 2006-07-21  Maciej Stachowiak  <mjs@apple.com>
3413
3414         Reviewed by Darin.
3415
3416         <rdar://problem/4523976> REGRESSION (NativeTextField): Crash occurs when choosing "Undo Typing" after typing and setting the value
3417
3418         * rendering/RenderTextControl.cpp:
3419         (WebCore::RenderTextControl::updateFromElement): Clear the undo
3420         chain when the text control contents have been set
3421         programmatically.
3422         * bridge/mac/FrameMac.mm:
3423         (WebCore::FrameMac::clearUndoRedoOperations): Before clearing undo
3424         stack, close all open undo groups and then open an equal number,
3425         since otherwise NSUndoManager ends up in an inconsistent state
3426         leading to uncaught ObjC exceptions.
3427
3428 2006-07-21  Beth Dakin  <bdakin@apple.com>
3429         
3430         Reviewed by Darin.
3431
3432         Just moving this assertion down a couple of lines. It was hitting 
3433         every time you try to print a page because we put it too early in 
3434         the function.
3435
3436         * bridge/mac/WebCoreFrameBridge.mm:
3437         (-[WebCoreFrameBridge drawRect:]):
3438
3439 2006-07-21  Justin Garcia  <justin.garcia@apple.com>
3440
3441         Reviewed by levi
3442         
3443         <rdar://problem/4548238>
3444         REGRESSION: Can't remove the first OL/UL list item in a Mail's compose window
3445
3446         * editing/CompositeEditCommand.cpp:
3447         (WebCore::CompositeEditCommand::breakOutOfEmptyListItem): 
3448         Moved from InsertParagraphSeparator.  Does its own typing style restoration.
3449         * editing/CompositeEditCommand.h:
3450         * editing/InsertParagraphSeparatorCommand.cpp:
3451         (WebCore::InsertParagraphSeparatorCommand::doApply): Call breakOutOfEmptyListItem.
3452         * editing/TypingCommand.cpp:
3453         (WebCore::TypingCommand::deleteKeyPressed): Call breakOutOfEmptyListItem if
3454         the endingSelection is at the start of an editable region.
3455         * editing/htmlediting.cpp:
3456         (WebCore::embeddedSublist): Moved from InsertParagraphSeparator.
3457         (WebCore::appendedSublist): Ditto.
3458         (WebCore::enclosingEmptyListItem): Ditto.
3459         * editing/htmlediting.h:
3460
3461 === Safari-521.20 ===
3462
3463 2006-07-21  Tim Omernick  <timo@apple.com>
3464
3465         Reviewed by Beth Dakin & John Sullivan.
3466
3467         <rdar://problem/4633717> 9A218: Reproducible crash in -[NSScroller mouseDown:]
3468
3469         Beth is in the middle of making a layout test for this; she will land it soon.
3470
3471         * platform/mac/ScrollBarMac.mm:
3472         (ScrollBar::~ScrollBar):
3473         Call Widget::removeFromSuperview() rather than -removeFromSuperview directly on the scroll bar view.
3474         Widget::removeFromSuperview() obeys the "mustStayInWindow" flag, which is set while tracking the mouse
3475         in view-based widgets to prevent their destruction while the tracking is in progress.
3476         I searched around WebCore and this is the only Widget subclass that directly removes its view rather
3477         than using removeFromSuperview().
3478
3479 2006-07-21  Mitz Pettel  <opendarwin.org@mitzpettel.com>
3480
3481         Reviewed by Darin.
3482
3483         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=9312
3484           REGRESSION: Selection bug in new text fields when selecting past the first letter
3485
3486         Test: editing/selection/select-from-textfield-outwards.html
3487
3488         * editing/Selection.cpp:
3489         (WebCore::Selection::adjustForEditableContent): Added code to handle the case
3490         where the selection starts (resp. ends) in the last (resp. first) visual position
3491         inside an editable root.
3492         * editing/htmlediting.cpp:
3493         (WebCore::comparePositions): Fixed the case of comparing a position inside a shadow
3494         tree with a position in the shadow ancestor.
3495         * rendering/RenderBlock.cpp:
3496         (WebCore::RenderBlock::positionForCoordinates): For coordinates outside a replaced
3497         object, return the position just before (after) the element if the coordinates are above or
3498         to the left (below or to the right).
3499         * rendering/RenderObject.cpp:
3500         (WebCore::RenderObject::caretMaxOffset): Changed to return 1 for replaced objects.
3501         * rendering/RenderText.cpp:
3502         (WebCore::RenderText::positionForCoordinates): Changed to return the last position
3503         in the lowest text box if the y coordinate is below all text boxes.
3504
3505 2006-07-21  Geoffrey Garen  <ggaren@apple.com>
3506
3507         Reviewed by Darin.
3508         
3509         - Fixed <rdar://problem/4507265> REGRESSION: overlays don't work on 
3510         HousingMaps.com (Google Maps-based site)
3511         
3512         - Made style.filter undetectable, like document.all.
3513         
3514         Unfortunately, the SVG spec-makers invented a CSS attribute named 'filter',
3515         which conflicts with IE's custom CSS attribute by the same name. Web programs 
3516         like the Google maps API test for style.filter, and assume it's the IE 
3517         style.filter if they find it, so we need to make style.filter undetectable 
3518         to avoid breaking them.
3519         
3520         An alternative solution would be to hotwire a delorean, go back in time,
3521         and beg the web standards makers to make standards that work on the web.
3522
3523         * bindings/js/kjs_css.cpp:
3524         (KJS::DOMCSSStyleDeclaration::cssPropertyGetter):
3525
3526 2006-07-20  Justin Garcia  <justin.garcia@apple.com>
3527
3528         Reviewed by john
3529         
3530         <rdar://problem/4641033>
3531         REGRESSION: Pasting from web pages into Mail (or Blot) often loses most of the content
3532         
3533         * editing/markup.cpp:
3534         (WebCore::createMarkup): We surround the currently accumulated markup with markup 
3535         for ancestors of the startNode when the pre-order traversal leaves the trees rooted 
3536         at those ancestors.  We assumed that any ancestors of the current node not in the 
3537         ancestorsToClose list were those kind of ancestors.  But we don't add renderer-less 
3538         containers to the ancestorsToClose list.  So, we were incorrectly surrounding the 
3539         currently accumulated markup with markup for render-less containers.  Most of the
3540         content at apple.com was being put inside an <optgroup> inside a <select> element.  
3541         Then on Paste createContextualFragment would drop it.
3542
3543 2006-07-21  Anders Carlsson  <acarlsson@apple.com>
3544
3545         Reviewed by Geoff.
3546
3547         * dom/Document.h:
3548         (WebCore::Document::):
3549         * dom/EventTargetNode.cpp:
3550         (WebCore::EventTargetNode::addEventListener):
3551         * page/FrameView.cpp:
3552         (WebCore::FrameView::layout):
3553         * rendering/RenderLayer.cpp:
3554         (WebCore::RenderLayer::updateScrollInfoAfterLayout):
3555         Only dispatch overflowchanged events if overflowchanged event listeners have been registered on the document.
3556
3557 2006-07-20  Anders Carlsson  <acarlsson@apple.com>
3558
3559         Reviewed by Geoff.
3560
3561         <rdar://problem/4637807> REGRESSION: "Features & Options" page at volvocars.us fails
3562
3563         * xml/XSLTProcessor.cpp:
3564         (WebCore::xsltParamArrayFromParameterMap):
3565         Turns out parameters never worked. String parameters need to be escaped so we create a transform context,
3566         add the parameters to it quoted and then use xsltApplyStylesheetUser which lets us pass the transform context to it.
3567         This also works around a bug in libxslt where a hash table isn't allocated.
3568
3569 2006-07-20  Alice Liu  <alice.liu@apple.com>
3570
3571         Reviewed by Tim Omernick.
3572
3573         Fixed <rdar://problem/4621649> repro crash: Upload link causes crash on pages.google.com in Frame::nodeForWidget
3574         added manual test because there is no way to change the value of an <input type=file> via the DOM.  It's not supported because it's a security risk. 
3575
3576         * manual-tests/remove-input-file-onchange.html: Added.
3577         * platform/mac/FileButtonMac.mm:
3578         (-[WebFileChooserButton chooseFilename:]):
3579         swapped the calls to changeFilename and bridgeForWidget because changeFilename will destroy the widget that is accessed in bridgeForWidget 
3580
3581 2006-07-20  Alice Liu  <alice.liu@apple.com>
3582
3583         Reviewed by Adele.
3584
3585         Fixed <rdar://problem/4532113> REGRESSION (NativeTextField): Crash occurs after modifying field then reloading page -[FormDelegate frameLayoutHasChanged:]
3586         added a manual test because of the need to use AutoFill.
3587
3588         * dom/Node.h:
3589         (WebCore::Node::aboutToUnload):
3590         added virtual function prototype
3591         * html/HTMLInputElement.cpp:
3592         (WebCore::HTMLInputElement::aboutToUnload):
3593         added implementation that sends textFieldDidEndEditing notification
3594         * html/HTMLInputElement.h:
3595         added virtual function prototype
3596         * manual-tests/input-type-file-autocomplete-frame-1.html: Added.
3597         * manual-tests/input-type-file-autocomplete-frame-2.html: Added.
3598         * manual-tests/input-type-file-autocomplete-refresh.html: Added.
3599         * page/Frame.cpp:
3600         (WebCore::Frame::stopLoading):
3601         before unloading, call aboutToUnload on the current focused node
3602
3603 2006-07-20  Brady Eidson  <beidson@apple.com>
3604
3605         Reviewed by Maciej
3606
3607         fixed <rdar://problem/4611303> REGRESSION: repro crash in WebCore::EventTargetNode::dispatchWindowEvent at aeropostale.com
3608         There was an attempt to deref an EventListener that got cleaned up in GC.  Changing Document's EventListener list from 
3609         vanilla ptrs to refptrs to prevent GC, following EventTargetNode's proven example.
3610
3611         * dom/Document.cpp:
3612         (WebCore::Document::Document):
3613         (WebCore::Document::clear):
3614         (WebCore::Document::handleWindowEvent):
3615         (WebCore::Document::getHTMLWindowEventListener):
3616         (WebCore::Document::removeHTMLWindowEventListener):
3617         (WebCore::Document::removeWindowEventListener):
3618         (WebCore::Document::hasWindowEventListener):
3619         Changed all of the list iterators to work with RefPtrs instead of vanilla ptrs
3620
3621         * dom/Document.h:
3622         Changed the EventListener list to be a vanilla pointer list to a refptr list
3623
3624 2006-07-20  John Sullivan  <sullivan@apple.com>
3625
3626         Reviewed by Maciej
3627
3628         - WebCore part of fix for:
3629         <rdar://problem/4557386> REGRESSION (419.3-521.19): repro Safari world leak involving 
3630         closing tabs after clicking in a web page
3631         
3632         * bridge/mac/WebCoreFrameBridge.h:
3633         (-[WebCoreFrameBridge textViewWasFirstResponderAtMouseDownTime:])
3634         renamed to be more specific (formerly wasFirstResponderAtMouseDownTime:)
3635         * bridge/mac/FrameMac.mm:
3636         (WebCore::FrameMac::passMouseDownEventToWidget):
3637         updated for name change
3638
3639 2006-07-19  Alexey Proskuryakov  <ap@nypop.com>
3640
3641         Reviewed by Darin.
3642
3643         Fix http://bugzilla.opendarwin.org/show_bug.cgi?id=8272
3644         Use of window.open & window.close can cause crash
3645
3646         * platform/PlatformMouseEvent.h:
3647         (WebCore::PlatformMouseEvent::PlatformMouseEvent):
3648         * platform/mac/PlatformMouseEventMac.mm:
3649         (WebCore::PlatformMouseEvent::PlatformMouseEvent):
3650         The default constructor now creates a "zero" event, and a new one was added to create the "current" one.
3651
3652         * bridge/mac/FrameMac.mm:
3653         (WebCore::FrameMac::handleMouseMoveEvent):
3654         * rendering/RenderFormElement.cpp:
3655         (WebCore::RenderFormElement::clicked): 
3656         Updated for the above changes.
3657
3658         * platform/gdk/MouseEventGdk.cpp:
3659         * platform/gdk/TemporaryLinkStubs.cpp:
3660         (PlatformMouseEvent::PlatformMouseEvent):
3661         * platform/win/MouseEventWin.cpp:
3662         * platform/win/TemporaryLinkStubs.cpp:
3663         (PlatformMouseEvent::PlatformMouseEvent):
3664         Trying not to break other platforms.
3665
3666         * manual-tests/invalid-mouse-event.html: Added.
3667
3668 2006-07-20  Maciej Stachowiak  <mjs@apple.com>
3669         
3670         Reviewed by Anders.
3671
3672         - delete line that I only commented in the last patch - meant to do this before landing
3673
3674         * html/HTMLFrameElement.cpp:
3675         (WebCore::HTMLFrameElement::close): 
3676
3677 2006-07-19  Maciej Stachowiak  <mjs@apple.com>
3678
3679         Reviewed by Geoff.
3680
3681         - fixed <rdar://problem/4634484> REGRESSION: Project Change Request form should have vertical scroll bar, but doesn't
3682         
3683         I couldn't figure out how to make an automated test case for this,
3684         or even a manual one. It seems to be timing-related in some way.
3685
3686         * html/HTMLFrameElement.cpp:
3687         (WebCore::HTMLFrameElement::close): detach the child frame from
3688         its element, not the frame containing this element.
3689
3690 2006-07-20  Anders Carlsson  <acarlsson@apple.com>
3691
3692         Reviewed by Darin.
3693
3694         * bridge/mac/FrameMac.mm:
3695         (WebCore::FrameMac::nextKeyViewInFrame):
3696         Hold a ref to the node in case it gets destroyed by an event handler.
3697
3698 2006-07-19  Mark Rowe  <opendarwin.org@bdash.net.nz>
3699
3700         Reviewed by Darin.
3701
3702         http://bugzilla.opendarwin.org/show_bug.cgi?id=10021
3703         Bug 10021: REGRESSION: Stack overflow due to infinite recursion in 
3704         Image::checkForSolidColor
3705
3706         * platform/Image.cpp:
3707         (WebCore::Image::cacheFrame): Don't call checkForSolidColor unless 
3708         the frame was decoded successfully.
3709
3710 2006-07-19  Adele Peterson  <adele@apple.com>
3711
3712         Reviewed by Maciej.
3713
3714         - Fix for: 
3715         <rdar://problem/4422657> REGRESSION: member name field or password field should have focus after loading webmail.mac.com (7405)
3716         http://bugzilla.opendarwin.org/show_bug.cgi?id=7405
3717
3718         <rdar://problem/4614181> REGRESSION: Crash in WebCore::RenderTextField::text() when quoting post at the Ars Technica forum (9707)
3719         http://bugzilla.opendarwin.org/show_bug.cgi?id=9707
3720
3721         Needs an http test. (http://bugzilla.opendarwin.org/show_bug.cgi?id=10020)
3722
3723         These bugs were both cases where focus() was called on an element which didn't have a renderer yet because stylesheets hadn't finished loading yet.
3724         Now, we detect this case and let setFocusNode be called.  And when the stylesheet finishes loading, and the element attaches, a timer will fire, 
3725         which will cause the correct selection & scrolling behavior to occur. 
3726
3727         This fix removes selection and scrolling behavior from the focus method.  This code is now in a new method, updateFocusAppearance.
3728         updateFocusAppearance can now be called directly from focus(), but it can also be called when a timer fires.  This timer gets set
3729         up when an element attaches, and its already been focused by the focus method.  We have to use a timer, because updateFocusAppearance can cause
3730         a layout to happen, and we don't want that to happen in the middle of attach().
3731
3732         * bindings/objc/DOM.mm: (-[DOMElement isFocused]): Added SPI for autofill.
3733         * bindings/objc/DOMPrivate.h:
3734
3735         * dom/Element.cpp:
3736         (WebCore::Element::Element): Initializes timer and needFocusAppearanceUpdate bool.
3737         (WebCore::Element::attach): Checks needsFocusAppearanceUpdate, and if the node is focused, then starts the timer.
3738         (WebCore::Element::focus): Updated to check supportsFocus before calling setFocusNode, 
3739         and only requiring the element to be focusable now before updating focus appearance.
3740         (WebCore::Element::updateFocusAppearance): Added. Separates the selection, and the scrolling from focusing the node.
3741         (WebCore::Element::updateFocusAppearanceTimerFired): Stops the timer, and if the element is focusable, calls updateFocusAppearance.
3742         (WebCore::Element::stopUpdateFocusAppearanceTimer):  Cancels timer, and setsNeedsFocusAppearanceUpdate(false).
3743         (WebCore::Element::detach): Calls stopUpdateFocusAppearanceTimer.
3744         (WebCore::Element::blur): ditto.
3745         * dom/Element.h:
3746         (WebCore::Element::needsFocusAppearanceUpdate): Added so the timer only fires when focus() methods have caused an element to be focused.
3747         (WebCore::Element::setNeedsFocusAppearanceUpdate): Added so focus methods can set this flag.
3748
3749         * dom/Node.h: (WebCore::Node::supportsFocus): Added.  Base class just calls isFocusable.
3750         * html/HTMLAnchorElement.h: Added supportsFocus.
3751         * html/HTMLAnchorElement.cpp: (WebCore::HTMLAnchorElement::supportsFocus): Added. Checks for the case where stylesheets haven't loaded yet,
3752         so we can still focus the node without a renderer, and when it gets a renderer, we'll update the focus appearance.
3753         * html/HTMLGenericFormElement.h: (WebCore::HTMLGenericFormElement::supportsFocus): ditto.
3754         * html/HTMLGenericFormElement.cpp: Removed include of Document.h since this is now in the header.
3755
3756         * html/HTMLInputElement.cpp:
3757         (WebCore::HTMLInputElement::focus): Updated to check supportsFocus before calling setFocusNode, 
3758         and only requiring the element to be focusable now before updating focus appearance.
3759         (WebCore::HTMLInputElement::updateFocusAppearance): Added. Separates the selection, and the scrolling from focusing the node.
3760         * html/HTMLInputElement.h:
3761
3762         * html/HTMLTextAreaElement.cpp:
3763         (WebCore::HTMLTextAreaElement::focus): Updated to check supportsFocus before calling setFocusNode, 
3764         and only requiring the element to be focusable now before updating focus appearance.
3765         (WebCore::HTMLTextAreaElement::updateFocusAppearance): Added. Separates the selection, and the scrolling from focusing the node.
3766         * html/HTMLTextAreaElement.h:
3767
3768 2006-07-19  Justin Garcia  <justin.garcia@apple.com>
3769
3770         Reviewed by levi
3771         
3772         <rdar://problem/4631972>
3773         REGRESSION: Mail crashes when pasting entire contents of http://www.apple.com/support/ into a new mail message
3774
3775         * dom/Position.cpp:
3776         (WebCore::Position::upstream): Deployed isBlock and enclosingBlock.
3777         (WebCore::Position::downstream): Ditto.
3778         * editing/CompositeEditCommand.cpp:
3779         (WebCore::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary): Ditto.
3780         * editing/htmlediting.cpp:
3781         (WebCore::canHaveChildrenForEditing): Added !iframe.
3782         (WebCore::isBlock): Added, returns !node->renderer()->isInline()
3783         (WebCore::enclosingBlock): Added.
3784         * editing/htmlediting.h:
3785
3786 2006-07-19  Anders Carlsson  <acarlsson@apple.com>
3787
3788         Reviewed by Adele.
3789
3790         <rdar://problem/4631272> REGRESSION: Crash tabbing out of hostname field at autorestore.apple.com
3791         
3792         * bridge/mac/FrameMac.mm:
3793         (WebCore::FrameMac::nextKeyViewInFrame):
3794         Take into account that focus handlers can cause a node's renderer to be destroyed.
3795         
3796 2006-07-19  David Hyatt  <hyatt@apple.com>
3797
3798         Fix for 4638376.  The 1x1 solid color image optimization was broken when
3799         I re-architected image.  This patch restores the optimization for CG.  Cairo
3800         will still need the optimization.
3801
3802         Reviewed by darin
3803
3804         WARNING: NO TEST CASES ADDED OR CHANGED (need test cases still)
3805
3806         * platform/Image.cpp:
3807         (WebCore::Image::Image):
3808         (WebCore::Image::invalidateData):
3809         (WebCore::Image::cacheFrame):
3810         * platform/Image.h:
3811         (WebCore::Image::setIsPDF):
3812         * platform/cairo/ImageCairo.cpp:
3813         (WebCore::Image::checkForSolidColor):
3814         * platform/mac/ImageMac.mm:
3815         (WebCore::Image::initNativeData):
3816         (WebCore::Image::invalidateNativeData):
3817         (WebCore::Image::checkForSolidColor):
3818         (WebCore::Image::draw):
3819         (WebCore::Image::drawTiled):
3820
3821 2006-07-19  Justin Garcia  <justin.garcia@apple.com>
3822
3823         Reviewed by levi
3824         
3825         <rdar://problem/4613519>
3826         REGRESSION: Pasting text in native text area inserts text one character before it should (9527)
3827
3828         * editing/InsertParagraphSeparatorCommand.cpp:
3829         (WebCore::InsertParagraphSeparatorCommand::doApply): Turn into an InsertLineBreakCommand instead of bailing
3830         if the enclosingBlockFlowElement doesn't have a parent.
3831
3832 2006-07-19  David Harrison  <harrison@apple.com>
3833
3834         Reviewed by Tim Hatcher.
3835
3836         <rdar://problem/4629307> -[DOMRange markupString] does not include the initial table element if it is at the beginning of the range
3837         <rdar://problem/4062218> pasting in contents of web.apple.com strips off the <table> element from the first table
3838         
3839         Better patch than previous checkin.
3840
3841         * test: editing/pasteboard/paste-table-003.html
3842         
3843         * editing/markup.cpp:
3844         (WebCore::createMarkup):
3845         Make sure to include the table when including a tbody.
3846
3847 === Safari-521.19 ===
3848
3849 2006-07-19  David Harrison  <harrison@apple.com>
3850
3851         Reviewed by Tim Hatcher.
3852
3853         <rdar://problem/4629307> -[DOMRange markupString] does not include the initial table element if it is at the beginning of the range
3854
3855         No test case as this can only be reproduced through ObjC APIs.
3856
3857         * editing/markup.cpp:
3858         (WebCore::createMarkup):
3859         Adjust the range for ancestor markup handling when main loop skips first node.
3860
3861 2006-07-18  David Hyatt  <hyatt@apple.com>
3862
3863         Fix for radar 4611287, make resizable text fields opt-in rather than
3864         opt-out.  Open source users will need to write the pref into their defaults
3865         to see the resizers on textareas now.
3866
3867         Reviewed by mjs and adele
3868
3869         * WebCore.xcodeproj/project.pbxproj:
3870         * bridge/mac/WebCoreSettings.mm:
3871         (-[WebCoreSettings setTextAreasAreResizable:]):
3872         * css/cssparser.cpp:
3873         (WebCore::CSSParser::parseValue):
3874         * css/cssstyleselector.cpp:
3875         (WebCore::CSSStyleSelector::applyProperty):
3876         * css/html4.css:
3877
3878 2006-07-18  Anders Carlsson  <acarlsson@apple.com>
3879
3880         Reviewed by Darin.
3881
3882         http://bugzilla.opendarwin.org/show_bug.cgi?id=9959
3883         REGRESSION: iframes stop rendering after 200th one on successive reloads
3884         
3885         * html/HTMLFrameElement.cpp:
3886         (WebCore::HTMLFrameElement::attach):
3887         (WebCore::HTMLFrameElement::close):
3888         * html/HTMLIFrameElement.cpp:
3889         (WebCore::HTMLIFrameElement::insertedIntoDocument):
3890         (WebCore::HTMLIFrameElement::willRemove):
3891         Remove calls to incrementFrameCount and decrementFrameCount.
3892         
3893         * page/Frame.cpp:
3894         (WebCore::Frame::Frame):
3895         Call incrementFrameCount here.
3896         
3897         (WebCore::Frame::~Frame):
3898         Call disconnectOwnerElement.
3899         
3900         (WebCore::Frame::disconnectOwnerElement):
3901         Call decrementFrameCount here.
3902         
3903 2006-07-18  Alexey Proskuryakov  <ap@nypop.com>
3904
3905         Reviewed by Darin.
3906
3907         Fix http://bugzilla.opendarwin.org/show_bug.cgi?id=9013
3908         Let correct CSS custom cursor declarations parse
3909
3910         * css/cssparser.cpp:
3911         (WebCore::CSSParser::parseValue): Ignore any values following a custom CSS cursor URI, instead of
3912         requiring that it is the only one in the list (which is actually illegal, according to the spec). 
3913         This is only a temporary hack, with a real implementation to follow in bug 6001/6002.
3914
3915         * manual-tests/custom-cursors.html: Added a test for this issue.
3916         * manual-tests/resources/helpCursor.tiff: A cursor image used in the test.
3917
3918 2006-07-18  Timothy Hatcher  <timothy@apple.com>
3919
3920         Reviewed by Anders.
3921         
3922         <rdar://problem/4636216> NetNewsWire fails to launch on 9A224 - missing symbols
3923         
3924         WebCore needs to add -sub_library libobjc to maintain
3925         backwards compatibility with binaries linked with WebKit
3926         before JavaScriptCore moved out of WebKit.
3927
3928         * WebCore.xcodeproj/project.pbxproj:
3929
3930 2006-07-18  Mitz Pettel  <opendarwin.org@mitzpettel.com>
3931
3932         Reviewed by Justin.
3933
3934         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=9978
3935           REGRESSION (r12949-r12988): Clicking the first letter on a line places the caret at the end of the previous line
3936
3937         Test: editing/selection/click-start-of-line.html
3938
3939         * rendering/RenderText.cpp:
3940         (WebCore::RenderText::positionForCoordinates): Changed to return downstream
3941         affinity if the x coordinate is to the left of the middle of the first character
3942         in the text box.
3943
3944 2006-07-18  Anders Carlsson  <acarlsson@apple.com>
3945
3946         Reviewed by Darin.
3947
3948         http://bugzilla.opendarwin.org/show_bug.cgi?id=9695
3949         <rdar://problem/4614085> 
3950         TOT REGRESSION: NativeTextArea: Text area does not respond to Cmd-UpArrow/Cmd-DownArrow (9695)
3951         
3952         * editing/SelectionController.cpp:
3953         (WebCore::SelectionController::modifyExtendingRightForward):
3954         (WebCore::SelectionController::modifyMovingRightForward):
3955         (WebCore::SelectionController::modifyExtendingLeftBackward):
3956         (WebCore::SelectionController::modifyMovingLeftBackward):
3957         If the caret is inside an editable region, the beginning/end of the document should actually be the
3958         beginning/end of the editable region.
3959
3960 2006-07-17  Tim Omernick  <timo@apple.com>
3961
3962         Reviewed by Maciej.
3963
3964         <rdar://problem/4612079> need a way to prevent pages from scrolling to reveal elements that are focused
3965         by script
3966
3967         * bridge/mac/WebCoreFrameBridge.h:
3968         * bridge/mac/WebCoreFrameBridge.mm:
3969         (-[WebCoreFrameBridge setProhibitsScrolling:]):
3970         * page/Frame.cpp:
3971         (WebCore::Frame::prohibitsScrolling):
3972         (WebCore::Frame::setProhibitsScrolling):
3973         * page/Frame.h:
3974         * page/FramePrivate.h:
3975         (WebCore::FramePrivate::FramePrivate):
3976         * page/FrameView.cpp:
3977         (WebCore::FrameView::scrollPointRecursively):
3978         (WebCore::FrameView::setContentsPos):
3979         * page/FrameView.h:
3980         * platform/ScrollView.h:
3981
3982 2006-07-17  Maciej Stachowiak  <mjs@apple.com>
3983
3984         Reviewed by Dave Harrison.
3985         
3986         - fixed <rdar://problem/4618089> Blot crashes when I paste in all the contents of http://www.apple.com/startpage/
3987
3988         * editing/htmlediting.cpp:
3989         (WebCore::editingIgnoresContent):
3990
3991 2006-07-17  Justin Garcia  <justin.garcia@apple.com>
3992
3993         Reviewed by levi
3994         
3995         <rdar://problem/4621728>
3996         REGRESSION: Selecting by dragging down creates selection in wrong direction, with certain steps
3997         <rdar://problem/4604932>
3998         REGRESSION: Dragging too far left on a line will select all lines above it.
3999  
4000         No layout test because of 9980.
4001
4002         * rendering/RenderBlock.cpp:
4003         (WebCore::RenderBlock::positionForCoordinates): Don't return positions inside editable roots
4004         for coordinates outside those roots, except for coordinates outside a document that is entirely 
4005         editable.
4006
4007 2006-07-17  Timothy Hatcher  <timothy@apple.com>
4008
4009         Reviewed by Darin.
4010
4011         <rdar://problem/4635281> JSCanvasRenderingContext2D::drawImage needs to initialize the exception code to zero
4012
4013         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
4014         (WebCore::JSCanvasRenderingContext2D::drawImage): initialize ec to zero
4015         * html/CanvasRenderingContext2D.cpp:
4016         (WebCore::CanvasRenderingContext2D::drawImage): initialize ec before earlier return
4017
4018 2006-07-17  Timothy Hatcher  <timothy@apple.com>
4019
4020         Reviewed by Maciej.
4021
4022         <rdar://problem/4634874> WebScriptObject and WebUndefined are no longer defined by WebKit
4023
4024         Moves WebScriptObject and WebUndefined to WebCore.
4025
4026         * WebCore.exp:
4027         * WebCore.xcodeproj/project.pbxproj:
4028         * bindings/objc/DOM.mm:
4029         * bindings/objc/DOMCore.h:
4030         * bindings/objc/DOMInternal.mm:
4031         * bindings/objc/DOMUtility.mm:
4032         * bindings/objc/WebScriptObject.mm: Added.
4033         (+[WebUndefined allocWithZone:]):
4034         (-[WebUndefined initWithCoder:]):
4035         (-[WebUndefined encodeWithCoder:]):
4036         (-[WebUndefined copyWithZone:]):
4037         * bindings/objc/WebScriptObjectPrivate.h: Added.
4038         * bridge/mac/FrameMac.mm:
4039         * bridge/mac/WebCoreScriptDebugger.mm:
4040
4041 2006-07-17  David Hyatt  <hyatt@apple.com>
4042
4043         Back out the fix for 5564, since it turns out font:x-small; is a pretty
4044         prominent IE-specific CSS hack.  Because Web sites rely on IE's incorrect
4045         font parsing as a means of also correcting IE's incorrect font size rules.
4046
4047         This fixes Yahoo.com.
4048
4049         Reviewed by darin
4050
4051         * css/cssparser.cpp:
4052         (WebCore::CSSParser::parseFont):
4053
4054 2006-07-17  Justin Garcia  <justin.garcia@apple.com>
4055
4056         Reviewed by levi
4057         
4058         <rdar://problem/4618389> REGRESSION: After applying a link to the last word of a sentence, a new selection is created at the start of the sentence
4059         
4060         * dom/Document.cpp:
4061         (WebCore::Document::updateSelection):
4062
4063 2006-07-17  Maciej Stachowiak  <mjs@apple.com>
4064
4065         Reviewed by Beth.
4066         
4067         <rdar://problem/4604946> REGRESSION: 'checkboxRef.checked = true' fires onchange event in Leopard
4068
4069         * html/HTMLInputElement.cpp:
4070         (WebCore::HTMLInputElement::setChecked):
4071         (WebCore::HTMLInputElement::preDispatchEventHandler):
4072         * html/HTMLInputElement.h:
4073
4074 2006-07-16  David Kilzer  <ddkilzer@kilzer.net>
4075
4076         Reviewed by Darin.
4077
4078         - fix for http://bugzilla.opendarwin.org/show_bug.cgi?id=9954
4079           REGRESSION: document.dir should return empty string in <head>
4080
4081         Test: fast/dom/document-dir-property.html
4082
4083         * bindings/js/kjs_html.cpp:
4084         (KJS::JSHTMLDocument::getValueProperty): Return an empty string instead of an
4085         undefined value for an unset document.dir property.
4086
4087 2006-07-16  David Kilzer  <ddkilzer@kilzer.net>
4088
4089         Reviewed by Darin.
4090
4091         * dom/NodeFilter.idl:
4092         Removed "No newline at end of file" that snuck in as part of the "apply patch" process.
4093         * manual-tests/input-empty-on-focus.html:
4094         Removed "Property changes" that snuck in as part of the "apply patch" process.
4095
4096 2006-07-16  Darin Adler  <darin@apple.com>
4097
4098         Reviewed by John Sullivan.
4099
4100         - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=9943
4101           <rdar://problem/4590613>
4102           REGRESSION (Tiger-TOT): menus are offset to the right at http://movies.aol.com/movie-photo-bts/superman-returns
4103
4104         The problem turns out to be the fact that body.offsetLeft is returning a non-zero value.
4105         I have no idea why the menus worked in Tiger Safari, because body.offsetLeft behavior has not changed.
4106         Presumably some other bug that we fixed had been compensating.
4107
4108         Test: fast/html/body-offset-properties.html
4109
4110         * rendering/RenderObject.cpp:
4111         (WebCore::RenderObject::offsetLeft): Always return 0 for any object without an offsetParent.
4112         (WebCore::RenderObject::offsetTop): Ditto.
4113         (WebCore::RenderObject::offsetParent): Return 0 for the body (treat as a special case).
4114
4115 2006-07-16  Beth Dakin  <bdakin@apple.com>
4116
4117         Reviewed by Maciej.
4118
4119         Fix for <rdar://problem/4616595> REGRESSION: Problems with world 
4120         clock widget clock hand motion on 9A211 + 4604574
4121
4122         The second hand on the widget was jiggling because the rotation was 
4123         messing up the use of the affine transformation matrix while 
4124         rounding to pixel boundaries in device space. We are mainly 
4125         concerned with rounding to pixel boundaries with the scale in mind, 
4126         so this patch extracts the scale to device space from the matrix, 
4127         and rounds to pixel boundaries using only the scale. This doesn't 
4128         seem like it is a perfect solution, but it definitely solves the 
4129         immediate problem. We will probably need to re-address what should 
4130         happen to avoid pixel cracks with rotations at non-integral scale 
4131         factors. 
4132
4133         * platform/cg/GraphicsContextCG.cpp:
4134         (WebCore::GraphicsContext::roundToDevicePixels):
4135
4136 2006-07-15  Darin Adler  <darin@apple.com>
4137
4138         - fix mistake from fix for 8952 that was breaking layout tests
4139
4140         * editing/SelectionController.cpp: (WebCore::SelectionController::nodeWillBeRemoved):
4141         Justin was right! I changed the behavior of the function by accident. Changed it
4142     &nbs