Remove static linkage of QtWebKit against the ICO image format plugin.
[WebKit-https.git] / WebCore / ChangeLog
1 2007-11-20  Simon Hausmann  <hausmann@kde.org>
2
3         Reviewed by Adam Treat <treat@kde.org>.
4
5         Remove static linkage of QtWebKit against the ICO image format plugin.
6         Instead build the support for the ICO image format as a proper standalone qt image format plugin and install it.
7
8         * WebCore.pro:
9         * platform/graphics/qt/ImageDecoderQt.cpp:
10
11 2007-11-20  David D. Kilzer  <ddkilzer@webkit.org>
12
13         no-svg build broken after r27278
14         <http://bugs.webkit.org/show_bug.cgi?id=16061>
15
16         Reviewed by Eric.
17
18         * bindings/scripts/CodeGeneratorObjC.pm: Always generate DOMHTMLEmbedElementPrivate.h
19         and DOMHTMLObjectElementPrivate.h for no-svg build.
20
21 2007-11-20  Adam Treat  <treat@kde.org>
22
23         Reviewed by Simon.
24
25         * Don't use so much heap memory.
26
27         WARNING: NO TEST CASES ADDED OR CHANGED
28
29         * platform/graphics/qt/ImageDecoderQt.cpp:
30         * platform/graphics/qt/ImageDecoderQt.h:
31         * platform/graphics/qt/ImageSourceQt.cpp:
32         (WebCore::ImageSource::createFrameAtIndex):
33
34 2007-11-20  Lars Knoll  <lars@trolltech.com>
35
36         Reviewed by Simon.
37
38         Fix text break interators.
39         
40         The break iterators where trying to be smart about the input
41         string and caching their results. Unfortunately a pointer/string length
42         comparison is not good enough in all cases (since some input is stack based
43         temp strings). Removed the caching but at the same time started to use a more
44         efficient constructor of QTextBoundaryFinder that doesn't need to malloc for
45         most strings.
46         
47         Fixes two test cases that test "text-transform: capitalize".
48
49         * platform/qt/TextBreakIteratorQt.cpp:
50         (WebCore::wordBreakIterator):
51         (WebCore::characterBreakIterator):
52         (WebCore::lineBreakIterator):
53         (WebCore::sentenceBreakIterator):
54
55 2007-11-20  Adam Treat  <treat@kde.org>
56
57         Reviewed by George.
58
59         * Make gif animations work for instance.
60
61         WARNING: NO TEST CASES ADDED OR CHANGED
62
63         * platform/graphics/qt/ImageDecoderQt.cpp:
64         (WebCore::ImageDecoderQt::reset):
65         (WebCore::ImageDecoderQt::setData):
66         (WebCore::ImageDecoderQt::frameCount):
67         (WebCore::ImageDecoderQt::repetitionCount):
68         * platform/graphics/qt/ImageDecoderQt.h:
69
70 2007-11-20  Adam Treat  <treat@kde.org>
71
72         * Build in release mode
73
74         WARNING: NO TEST CASES ADDED OR CHANGED
75
76         * platform/NotImplemented.h:
77
78 2007-11-20  Adam Treat  <treat@kde.org>
79
80         Reviewed by Simon and George.
81
82         * Be quiet and allow suppression of NotImplemented calls at runtime.
83
84         WARNING: NO TEST CASES ADDED OR CHANGED
85
86         * platform/NotImplemented.h:
87
88 2007-11-19  Doug Turner  <dougt@meer.net>
89
90         Reviewed by Alp Toker.
91
92         http://bugs.webkit.org/show_bug.cgi?id=16054
93         Crash when GlyphPage::fill is called with more than 256 bytes of data
94
95         http://bugs.webkit.org/show_bug.cgi?id=14446
96         [GDK] Crash on http://www.wikipedia.org/
97
98         setGlyphDataForIndex() uses a fixed array of size 256 which we can't
99         exceed. We need to return failure if the buffer has Unicode
100         supplementary characters for now.
101
102         This strategy matches the Win port, which also doesn't support this
103         case yet.
104
105         Add an assertion so nobody makes this mistake again.
106
107         * platform/GlyphPageTreeNode.h:
108         (WebCore::GlyphPage::setGlyphDataForIndex):
109         * platform/gtk/GlyphPageTreeNodeGtk.cpp:
110         (WebCore::GlyphPage::fill):
111
112 2007-11-19  Doug Turner  <dougt@meer.net>
113
114         Reviewed by Timothy Hatcher.
115
116         http://bugs.webkit.org/show_bug.cgi?id=16050
117         sqlite3_prepare16_v2 build bustage.
118
119         Using the correct SQLITE_VERSION_NUMBER around sqlite_prepare16_v2
120         to fix build bustage.
121
122         * platform/sql/SQLiteStatement.cpp:
123         (WebCore::SQLiteStatement::prepare):
124
125 2007-11-19  Mark Rowe  <mrowe@apple.com>
126
127         Build fix.  Don't over-qualify the constructor name.
128
129         * storage/DatabaseDetails.h:
130
131 2007-11-19  Brady Eidson <beidson@apple.com>
132
133         Reviewed by Maciej
134
135         Stub out the WebCore parts of the WebKit API
136
137         * WebCore.base.exp:
138         * WebCore.xcodeproj/project.pbxproj:
139
140         * storage/DatabaseDetails.h: Added.  Simple container for vitals on a specific database
141         (WebCore::DatabaseDetails::DatabaseDetails::DatabaseDetails):
142         (WebCore::DatabaseDetails::DatabaseDetails):
143         (WebCore::DatabaseDetails::isValid):
144         (WebCore::DatabaseDetails::name):
145         (WebCore::DatabaseDetails::version):
146         (WebCore::DatabaseDetails::displayName):
147         (WebCore::DatabaseDetails::expectedUsage):
148         (WebCore::DatabaseDetails::currentUsage):
149
150         * storage/DatabaseTracker.cpp:  Added various methods for API usage
151         (WebCore::DatabaseTracker::detailsForNameAndOrigin):
152         (WebCore::DatabaseTracker::usageForOrigin):
153         (WebCore::DatabaseTracker::quotaForOrigin):
154         (WebCore::DatabaseTracker::setQuota):
155         * storage/DatabaseTracker.h:
156
157 2007-11-19  Kevin Ollivier  <kevino@theolliviers.com>
158
159         wx port build fix.
160
161         * platform/graphics/wx/AffineTransformWx.cpp:
162         (WebCore::AffineTransform::operator== ):
163         m_transform is only available when using wxGraphicsContext.
164
165 2007-11-19  Alp Toker  <alp@atoker.com>
166
167         Reviewed by Mark Rowe.
168
169         GTK+ drawing fixes.
170
171         Add a check to avoid crashing when the GraphicsContext is not
172         associated with a GdkDrawable. This was noticed when adding printing
173         support but might be triggered in other situations too.
174
175         Do not render themes when painting is disabled. This is an
176         optimisation for cases where GraphicsContext is used to calculate page
177         dimensions etc. without actually rendering.
178
179         * platform/graphics/cairo/GraphicsContextCairo.cpp:
180         (WebCore::GraphicsContext::gdkDrawable):
181         * platform/gtk/RenderThemeGtk.cpp:
182         (WebCore::paintMozWidget):
183
184 2007-11-13  Rahul Abrol  <ra5ul@comcast.net>
185
186         Reviewed by Tim Hatcher.
187
188         http://bugs.webkit.org/show_bug.cgi?id=15977
189         Resizing images preference now toggles default image state.
190
191         * loader/ImageDocument.cpp:
192         (WebCore::ImageDocument::ImageDocument):
193         (WebCore::ImageDocument::createDocumentStructure):
194         (WebCore::ImageDocument::imageChanged):
195
196 2007-11-19  Kevin Ollivier  <kevino@theolliviers.com>
197
198         Update wx port build sources with recent changes, update
199         wx FontPlatformData to be a class (MSVC7 gets confused
200         otherwise...) and implement its hash() method.
201
202         Reviewed by Adam.
203
204         * WebCoreSources.bkl:
205         * platform/wx/FontPlatformData.h:
206         (WebCore::FontPlatformData::hash):
207
208 2007-11-19  Julien Chaffraix  <julien.chaffraix@gmail.com>
209
210         Reviewed by Darin.
211
212         http://bugs.webkit.org/show_bug.cgi?id=12194
213         Bug 12194: Trying to access XMLHttpRequest.responseText or responseXML when they 
214         are not available should raise an exception
215
216         Tests: http/tests/xmlhttprequest/xmlhttprequest-responseText-exception.html
217                http/tests/xmlhttprequest/xmlhttprequest-responseXML-exception.html
218
219         * bindings/js/JSXMLHttpRequest.cpp:
220         (KJS::JSXMLHttpRequest::getValueProperty):
221         * xml/XMLHttpRequest.cpp:
222         (WebCore::XMLHttpRequest::getResponseText):
223         (WebCore::XMLHttpRequest::getResponseXML):
224         * xml/XMLHttpRequest.h:
225
226 2007-11-19  Peter Kasting  <zerodpx@gmail.com>
227
228         Reviewed by Darin Adler.
229
230         http://bugs.webkit.org/show_bug.cgi?id=15971
231         The GIF decoder should not fail decoding if the caller asks it to
232         decode again when no new data has arrived since the last call.
233
234         * platform/image-decoders/gif/GIFImageReader.cpp:
235         (GIFImageReader::read):
236
237 2007-11-18  Brady Eidson <beidson@apple.com>
238
239         Reviewed by Eric
240
241         Fix a crash hashing a default SecurityOriginData object 
242
243         * storage/DatabaseTracker.cpp:
244         (WebCore::SecurityOriginDataHash::hash): The default object has some default strings with NULL
245           StringImpls - don't try to hash those!
246
247 2007-11-18  Timothy Hatcher  <timothy@apple.com>
248
249         Reviewed by Sam Weinig.
250
251         Bug 16043: Remove InspectorController.log now that console.log works
252         http://bugs.webkit.org/show_bug.cgi?id=16043
253
254         Remove the last uses of InspectorController.log. Once use was no longer needed,
255         checking an erro case that can't happen anymore. The other case now uses console.error.
256
257         * page/InspectorController.cpp: Remove the log function.
258         (WebCore::InspectorController::windowScriptObjectAvailable): Remove the log function from
259         InspectorController script class.
260         * page/inspector/DocumentPanel.js: Remove a use of InspectorController.log that isn't needed.
261         * page/inspector/Panel.js: Change InspectorController.log to console.log and early return.
262
263 2007-11-18  Timothy Hatcher  <timothy@apple.com>
264
265         Reviewed by Brady.
266
267         Bug 16041: REGRESSION: the Database panel in the Inspector stopped showing errors
268         http://bugs.webkit.org/show_bug.cgi?id=16041
269
270         * page/inspector/DatabasePanel.js: Implement error callbacks to pass to executeSql()
271           and transaction(). Refactored some code for the success and error callbacks to use.
272
273 2007-11-18  Alexey Proskuryakov  <ap@webkit.org>
274
275         Reviewed by Maciej.
276
277         <rdar://problem/5546393> Whitespace handling doesn't match HTML5.
278
279         HTML5 definition is the same as MSIE's, with the exception that the latter strips null
280         characters. Firefox also treats U+0008 as whitespace, but not U+000B or U+000C.
281
282         Test: fast/parser/html-whitespace.html
283
284         * html/HTMLTokenizer.cpp:
285         (WebCore::HTMLTokenizer::parseSpecial):
286         (WebCore::HTMLTokenizer::parseTag):
287         Use isASCIISpace, which matches HTML5 definition of whitespace, and also what we use to
288         check for whitespace almost everywhere.
289
290 2007-11-17  Mark Rowe  <mrowe@apple.com>
291
292         Reviewed by Darin Adler.
293
294         Fix: <rdar://problem/5607032> REGRESSION: testapi exits with assertion failure in debug build
295              <rdar://problem/5440659> JSGlobalContextCreate throws away globalObjectClass's prototype
296              http://bugs.webkit.org/show_bug.cgi?id=16033
297
298         Update for changes in Interpreter method signatures.
299
300         * bindings/js/kjs_binding.cpp:
301         (KJS::ScriptInterpreter::ScriptInterpreter):
302         * bindings/js/kjs_window.cpp:
303         (KJS::Window::clear):
304
305 2007-11-17  Timothy Hatcher  <timothy@apple.com>
306
307         Reviewed by Mark Rowe.
308
309         Bug 13470: i18n: The Web Inspector is not localizable
310         http://bugs.webkit.org/show_bug.cgi?id=13470
311
312         Add support for localization to the Web Inspector. Clients need to
313         implement localizedStringsURL() to return the URL of the
314         InspectorLocalizedStrings.js that best matches the user's language.
315
316         * English.lproj: Added.
317         * English.lproj/InspectorLocalizedStrings.js: Added.
318         * WebCore.xcodeproj/project.pbxproj: Add InspectorLocalizedStrings.js.
319         * page/InspectorClient.h: Add localizedStringsURL.
320         * page/InspectorController.cpp: Add localizedStringsURL that calls
321           the client. Also added a version exposed to JavaScript.
322         * page/InspectorController.h: Add localizedStringsURL.
323         * page/inspector/ConsolePanel.js: Call WebInspector.UIString
324           for user visible strings.
325         * page/inspector/DatabasePanel.js: Ditto.
326         * page/inspector/DocumentPanel.js: Ditto.
327         * page/inspector/ImagePanel.js: Ditto.
328         * page/inspector/MetricsSidebarPane.js: Ditto.
329         * page/inspector/NetworkPanel.js: Ditto.
330         * page/inspector/Panel.js: Ditto.
331         * page/inspector/PropertiesSidebarPane.js: Ditto.
332         * page/inspector/Resource.js: Ditto.
333         * page/inspector/ResourceCategory.js: Ditto.
334         * page/inspector/SourcePanel.js: Ditto.
335         * page/inspector/StylesSidebarPane.js: Ditto.
336         * page/inspector/inspector.css: Use pre-wrap so database errors can use \n.
337         * page/inspector/inspector.html: Remove some user visible strings.
338         * page/inspector/inspector.js: Added WebInspector.UIString and call
339           WebInspector.UIString for user visible strings. Some code needed to be 
340           moved to WebInspector.loaded to use UIString after the localized strings
341           get loaded.
342         * platform/graphics/svg/SVGImageEmptyClients.h:
343         (WebCore::SVGEmptyFrameLoaderClient::redirectDataToPlugin): Remove WebCore:: prefix.
344         (WebCore::SVGEmptyInspectorClient::createPage): Ditto.
345         (WebCore::SVGEmptyInspectorClient::localizedStringsURL): Add empty stub.
346         (WebCore::SVGEmptyInspectorClient::highlight): Remove WebCore:: prefix.
347         (WebCore::SVGEmptyInspectorClient::inspectedURLChanged): Ditto.
348
349 2007-11-17  Timothy Hatcher  <timothy@apple.com>
350
351         Reviewed by Adam.
352
353         Reworte String.sprintf to fix many bad bugs and to not use RegExp. Also added
354         String.vsprintf so it can be used later for the localization function.
355
356         This version only supports argument reordering, precision for floats, and these
357         format characters: d, f, s and @. Any unsupported format characters are logged
358         and substituted like strings.
359
360         * page/inspector/utilities.js:
361
362 2007-11-17  Alexey Proskuryakov  <ap@webkit.org>
363
364         Windows build fix.
365
366         * editing/Editor.h: Made canSmartCopyOrDelete public, as Windows WebView still needs it.
367
368 2007-11-17  Alexey Proskuryakov  <ap@webkit.org>
369
370         Reviewed by Darin.
371
372         http://bugs.webkit.org/show_bug.cgi?id=15969
373         Eliminate Editor::deleteRange()
374
375         No change in functionality.
376
377         * editing/CompositeEditCommand.h: Removed unimplemented deleteKeyPressed().
378
379         * editing/Editor.cpp:
380         (WebCore::Editor::deleteWithDirection):
381         (WebCore::Editor::cut):
382         (WebCore::Editor::performDelete):
383         * editing/Editor.h:
384         Moved relevant Editor::deleteRange() functionality to its callers.
385         Removed deleteSelectionWithSmartDelete(void), which was more confusing than helpful
386         in my opinion.
387
388         * editing/mac/EditorMac.mm:
389         (WebCore::initializeKillRingIfNeeded):
390         (WebCore::Editor::addToKillRing):
391         (WebCore::Editor::yank):
392         (WebCore::Editor::yankAndSelect):
393         (WebCore::Editor::setMark):
394         (WebCore::unionDOMRanges):
395         (WebCore::Editor::deleteToMark):
396         (WebCore::Editor::selectToMark):
397         (WebCore::Editor::swapWithMark):
398         Pushed kill ring handling down from WebCore.
399
400         * page/mac/WebCoreFrameBridge.h:
401         * page/mac/WebCoreFrameBridge.mm:
402         Removed setMarkDOMRange (the corresponding getter is still needed).
403
404         * WebCore.base.exp: No longer need to export Editor::deleteRange() and Editor::insertTextWithoutSendingTextEvent().
405         Export the new kill ring functions.
406
407 2007-11-16  Ryan Leavengood  <leavengood@gmail.com>
408
409         Reviewed by David Kilzer.
410
411         Build fix: the needed headers for POSIX file functions were not
412         included.
413
414         * platform/posix/FileSystemPOSIX.cpp:
415
416 2007-11-16  Dan Bernstein  <mitz@apple.com>
417
418         Reviewed by Darin Adler.
419
420         - fix the common case of <http://bugs.webkit.org/show_bug.cgi?id=15994>
421           REGRESSION: Incomplete repaint of CSS image substitution
422
423         Test: fast/repaint/clip-with-layout-delta.html
424
425         * rendering/LayoutState.cpp:
426         (WebCore::LayoutState::LayoutState): Account for layout delta when
427         pushing additional clip.
428
429 2007-11-16  Antti Koivisto  <antti@apple.com>
430
431         Reviewed by Adele.
432         
433         Seeking related fixes, updates to match the latest specification
434         - rename loopCount of HTMLMediaElement to playCount
435         - add explicit seeking attribute to HTMLMediaElement to get semantics right
436         - implement the specification behavior that currentTime must immediately return seeked position in HTMLMediaElement 
437           instead of MoviePrivateQTKit 
438         - fix broken behavior when seeking past end of the media, add tests
439         - replace Movie didEnd callback with broader timeChanged callback (which gets called in didEnd case too)
440         - use setDelayCallbacks: in various MoviePrivateQTKit methods to avoid bug prone synchronous callbacks from QT, make
441           HTMLMediaElement not depend on synchronous callbacks
442         - do some cleanups and simplifications in MoviePrivateQTKit, get rid of m_rateBeforeSeek and m_blockStateUpdate variables
443
444         Tests: http/tests/media/video-seekable-stall.html
445                media/video-seeking.html
446                media/video-seek-past-end-paused.html
447                media/video-seek-past-end-playing.html
448
449         * html/HTMLAttributeNames.in: 
450         * html/HTMLMediaElement.cpp:
451         (WebCore::HTMLMediaElement::HTMLMediaElement):
452         (WebCore::HTMLMediaElement::load):
453         (WebCore::HTMLMediaElement::movieNetworkStateChanged):
454         (WebCore::HTMLMediaElement::setReadyState):
455         (WebCore::HTMLMediaElement::seek):
456         (WebCore::HTMLMediaElement::seeking):
457         (WebCore::HTMLMediaElement::currentTime):
458         (WebCore::HTMLMediaElement::ended):
459         (WebCore::HTMLMediaElement::play):
460         (WebCore::HTMLMediaElement::pause):
461         (WebCore::HTMLMediaElement::playCount):
462         (WebCore::HTMLMediaElement::setPlayCount):
463         (WebCore::HTMLMediaElement::checkIfSeekNeeded):
464         (WebCore::HTMLMediaElement::movieTimeChanged):
465         (WebCore::HTMLMediaElement::endedPlayback):
466         (WebCore::HTMLMediaElement::updateMovie):
467         * html/HTMLMediaElement.h:
468         * html/HTMLMediaElement.idl:
469         * platform/graphics/Movie.cpp:
470         (WebCore::Movie::timeChanged):
471         * platform/graphics/Movie.h:
472         (WebCore::MovieClient::movieTimeChanged):
473         * platform/graphics/mac/MoviePrivateQTKit.h:
474         * platform/graphics/mac/MoviePrivateQTKit.mm:
475         (WebCore::MoviePrivate::MoviePrivate):
476         (WebCore::MoviePrivate::load):
477         (WebCore::MoviePrivate::play):
478         (WebCore::MoviePrivate::pause):
479         (WebCore::MoviePrivate::currentTime):
480         (WebCore::MoviePrivate::seek):
481         (WebCore::MoviePrivate::doSeek):
482         (WebCore::MoviePrivate::cancelSeek):
483         (WebCore::MoviePrivate::seekTimerFired):
484         (WebCore::MoviePrivate::startCuePointTimerIfNeeded):
485         (WebCore::MoviePrivate::paused):
486         (WebCore::MoviePrivate::updateStates):
487         (WebCore::MoviePrivate::timeChanged):
488         (WebCore::MoviePrivate::didEnd):
489
490 2007-11-16  Anders Carlsson  <andersca@apple.com>
491
492         Reviewed by Adam.
493
494         <rdar://problem/5603832>
495         XMLHttpRequest readyState 3 & responseText buffer issues.
496
497         * platform/network/cf/ResourceHandleCFNet.cpp:
498         (WebCore::makeFinalRequest):
499         Add new parameter which controls whether content sniffing should be turned off.
500         
501         (WebCore::ResourceHandle::loadResourceSynchronously):
502         Always content sniff sync loads.
503         
504         * platform/network/cf/ResourceRequestCFNet.cpp:
505         (WebCore::ResourceRequest::doUpdatePlatformRequest):
506         If the ResourceRequest already has a backing CFURLRequest, make a copy of it. This preserves
507         any properties set on the CFURLRequest.
508
509 2007-11-16  Jon Honeycutt  <jhoneycutt@apple.com>
510
511         Reviewed by Ollie.
512
513         <rdar://problem/5605175> Crash closing or leaving window with ViewPoint 
514         Media player plugin
515
516         ViewPoint plugin requires that we pass a valid NPSavedData* to
517         NPP_Destroy.
518
519         * plugins/win/PluginViewWin.cpp: Pass a valid NPSavedData* to
520         NPP_Destroy. If the plugin allocates data, discard it
521
522 2007-11-16  Mark Rowe  <mrowe@apple.com>
523
524         Reviewed by Tim Hatcher.
525
526         Build WebCore as a sub-framework of WebKit in all configurations.
527
528         * Configurations/WebCore.xcconfig:
529         * WebCore.xcodeproj/project.pbxproj:
530
531 2007-11-16  Doug Turner  <dougt@meer.net>
532
533         Reviewed by Alp.
534
535         http://bugs.webkit.org/show_bug.cgi?id=16018
536         build bustage when building on debian 4.0
537
538         Fix build bustage on GTK+ with older versions of Pango.
539
540         Don't cache the return value since the docs say it can change.
541
542         * platform/gtk/Language.cpp:
543         (WebCore::defaultLanguage):
544
545 2007-11-16  Brady Eidson  <beidson@apple.com>
546
547         Build fix
548
549         * platform/SecurityOriginData.h:
550         (WebCore::operator!=): Whoops!
551
552 2007-11-16  Brady Eidson  <beidson@apple.com>
553
554         Reviewed by Sam
555
556         Further purify DatabaseTracker to use SecurityOriginData instead of "a String"
557
558         * WebCore.base.exp:
559         * WebCore.xcodeproj/project.pbxproj:
560         * WebCore.vcproj/WebCore.vcproj
561         * WebCore.pro
562
563         * platform/SecurityOriginData.cpp: Added.
564         (WebCore::SecurityOriginData::SecurityOriginData): Add a constructor that takes a "stringIdentifier"-style string,
565           since that form is what will be stored in the Databases.db on disk
566         (WebCore::SecurityOriginData::stringIdentifier):
567         * platform/SecurityOriginData.h:
568         (WebCore::SecurityOriginData::protocol):
569         (WebCore::SecurityOriginData::host):
570         (WebCore::SecurityOriginData::port):
571
572         * storage/DatabaseTracker.cpp:
573         (WebCore::SecurityOriginDataHash::hash): Follow the pattern Darin set in FontCache.cpp to make a decent hash for 
574           a SecurityOriginData object
575         (WebCore::SecurityOriginDataHash::equal):
576         (WebCore::SecurityOriginDataTraits::deletedValue): "file::1" will never exist in normal operation
577         (WebCore::SecurityOriginDataTraits::emptyValue): "file::2" will never exist in normal operation
578         (WebCore::DatabaseTracker::fullPathForDatabase):
579         (WebCore::DatabaseTracker::populateOrigins):
580         (WebCore::DatabaseTracker::origins):
581         (WebCore::DatabaseTracker::addDatabase):
582         * storage/DatabaseTracker.h:
583
584 2007-11-16  Alexey Proskuryakov  <ap@webkit.org>
585
586         Windows build fix.
587
588         * WebCore.vcproj/WebCore.vcproj: Removed VoidCallback.cpp, added JSCustomVoidCallback.{h,cpp}.
589
590 2007-11-16  Nikolas Zimmermann  <zimmermann@kde.org>
591
592         Reviewed by Eric.
593
594         Fixes: http://bugs.webkit.org/show_bug.cgi?id=12290
595
596         Implement all SVGTextContentElement DOM methods.
597         This is the last missing SVG text feature. SVG fonts is next.
598
599         Added testcase: svg/custom/text-dom-01-f.svg (tests all new methods)
600
601         * ksvg2/svg/SVGTextContentElement.cpp:
602         (WebCore::cummulatedCharacterRangeLength):
603         (WebCore::SVGInlineTextBoxQueryWalker::):
604         (WebCore::SVGInlineTextBoxQueryWalker::SVGInlineTextBoxQueryWalker):
605         (WebCore::SVGInlineTextBoxQueryWalker::chunkPortionCallback):
606         (WebCore::SVGInlineTextBoxQueryWalker::setQueryInputParameters):
607         (WebCore::SVGInlineTextBoxQueryWalker::longResult):
608         (WebCore::SVGInlineTextBoxQueryWalker::floatResult):
609         (WebCore::SVGInlineTextBoxQueryWalker::pointResult):
610         (WebCore::SVGInlineTextBoxQueryWalker::rectResult):
611         (WebCore::SVGInlineTextBoxQueryWalker::stopProcessing):
612         (WebCore::findInlineTextBoxInTextChunks):
613         (WebCore::rootInlineBoxForTextContentElement):
614         (WebCore::executeTextQuery):
615         (WebCore::SVGTextContentElement::getNumberOfChars):
616         (WebCore::SVGTextContentElement::getComputedTextLength):
617         (WebCore::SVGTextContentElement::getSubStringLength):
618         (WebCore::SVGTextContentElement::getStartPositionOfChar):
619         (WebCore::SVGTextContentElement::getEndPositionOfChar):
620         (WebCore::SVGTextContentElement::getExtentOfChar):
621         (WebCore::SVGTextContentElement::getRotationOfChar):
622         (WebCore::SVGTextContentElement::getCharNumAtPosition):
623         (WebCore::SVGTextContentElement::selectSubString):
624         * ksvg2/svg/SVGTextContentElement.h:
625         * rendering/SVGInlineTextBox.h:
626
627 2007-11-15  Adele Peterson  <adele@apple.com>
628
629         Reviewed by Oliver.
630
631         Fix for <rdar://problem/5566652> CrashTracer: [USER] 3 crashes in Safari at HTMLSelectElement::menuListDefaultEventHandler (reproducible on mactc30.com)
632
633         Test: fast/forms/menulist-no-renderer-onmousedown.html
634
635         * html/HTMLSelectElement.cpp:
636         (WebCore::HTMLSelectElement::defaultEventHandler): Nil check the renderer here.  None of the default behavior makes sense if there's no renderer.
637         (WebCore::HTMLSelectElement::listBoxDefaultEventHandler): Moved the nil check to the main defaultEventHandler.
638
639 2007-11-15  Antti Koivisto  <antti@apple.com>
640
641         Reviewed by Adele.
642
643         Fix <rdar://problem/5601598>
644         The movie tag should do initialization on need and not during startup.
645         
646         Initialize Movie MIME type hash on demand
647
648         * platform/MIMETypeRegistry.cpp:
649         (WebCore::initialiseSupportedMovieMIMETypes):
650         (WebCore::initialiseMIMETypeRegistry):
651         (WebCore::MIMETypeRegistry::isSupportedMovieMIMEType):
652         (WebCore::MIMETypeRegistry::getSupportedMovieMIMETypes):
653
654 2007-11-15  Mark Rowe  <mrowe@apple.com>
655
656         Build fix for Qt on Windows.
657
658         * xml/XPathStep.cpp:
659         (WebCore::XPath::Step::nodesInAxis):
660
661 2007-11-15  Timothy Hatcher  <timothy@apple.com>
662
663         Reviewed by Mark Rowe.
664
665         Bug 14761: Web Inspector leaks JS objects and DOM nodes
666         http://bugs.webkit.org/show_bug.cgi?id=14761
667
668         * page/InspectorController.cpp:
669         (WebCore::InspectorController::~InspectorController):
670         Change the tear down order so that inspectorDestroyed() is called before
671         InspectorController private data is set to Zero. The inspectorDestroyed()
672         call ends up closing the WebView and triggering InspectorController::close()
673         which unprotects m_scriptObject. This didn't happen when the private data
674         was cleared before calling inspectorDestroyed().
675
676 2007-11-15  Mark Rowe  <mrowe@apple.com>
677
678         Gtk build fix.
679
680         * WebCore.pro:
681
682 2007-11-15  Alexey Proskuryakov  <ap@webkit.org>
683
684         Reviewed by Darin.
685
686         http://bugs.webkit.org/show_bug.cgi?id=15989
687         XPath queries with predicates incorrectly retains the current node across unions
688
689         Test: fast/xpath/union-context-node.xhtml
690
691         * xml/XPathPath.cpp:
692         (WebCore::XPath::LocationPath::evaluate): Restore context after evaluation.
693         * xml/XPathStep.cpp:
694         (WebCore::XPath::Step::evaluate): Do not backup context, as we can easily re-create it.
695
696 2007-11-15  Alexey Proskuryakov  <ap@webkit.org>
697
698         Reviewed by Darin.
699
700         http://bugs.webkit.org/show_bug.cgi?id=15988
701         REGRESSION: XPath preceding-axis query misses nested elements
702
703         Test: fast/xpath/preceding-axis.xhtml
704
705         * xml/XPathStep.cpp:
706         (WebCore::XPath::Step::nodesInAxis): Hopefully correct this time.
707
708 2007-11-15  Timothy Hatcher  <timothy@apple.com>
709
710         Reviewed by Mark Rowe and Sam.
711
712         This corrects a couple of issues in the Web Inspector where selected search results
713         would not have the right text color when the window is inactive or the results are focused.
714
715         * page/inspector/inspector.css:
716
717 2007-11-15  Timothy Hatcher  <timothy@apple.com>
718
719         Reviewed by Sam.
720
721         Bug 16007: REGRESSION: Disclosure triangle click zone for resource categories is off by 10 pixels
722         http://bugs.webkit.org/show_bug.cgi?id=16007
723
724         Makes the click width an option on TreeElement and make ResourceCategoryTreeElement
725         a true subclass of TreeElement. The click width for ResourceCategoryTreeElement is 
726         20 pixels, and the default is 10 pixels.
727
728         * page/inspector/ResourceCategory.js:
729         * page/inspector/treeoutline.js:
730
731 2007-11-15  Anders Carlsson  <andersca@apple.com>
732
733         Reviewed by Brady.
734
735         Pass a VoidCallback to Database::transaction and Database::changeVersion.
736         This is not yet hooked up to the database machinery.
737         
738         * WebCore.vcproj/WebCore.vcproj:
739         * bindings/js/JSDatabaseCustom.cpp:
740         (WebCore::JSDatabase::changeVersion):
741         (WebCore::JSDatabase::transaction):
742         * storage/Database.cpp:
743         (WebCore::Database::changeVersion):
744         (WebCore::Database::transaction):
745         * storage/Database.h:
746
747 2007-11-15  Timothy Hatcher  <timothy@apple.com>
748
749         Reviewed by Adam.
750
751         Bug 16005: Hovering in the breadcrumbs causes jumpy behavior
752         http://bugs.webkit.org/show_bug.cgi?id=16005
753
754         Hovering over cumbs no longer exposes new crumbs. Clicking on a collapsed
755         crumb will expose as many hidden crumbs as possible to the user. Also crumbs
756         that have ID attributes will compact to the ID over the tag name.
757
758         * page/inspector/DocumentPanel.js:
759
760 2007-11-15  Anders Carlsson  <andersca@apple.com>
761
762         Reviewed by Sam.
763
764         Make the VoidCallback DOM interface behave more like our other DOM interfaces.
765         
766         * bindings/js/JSCustomVoidCallback.h: Added.
767         * bindings/js/JSCustomVoidCallback.cpp: Added.
768         (WebCore::JSCustomVoidCallback::JSCustomVoidCallback):
769         (WebCore::JSCustomVoidCallback::handleEvent):
770         VoidCallback implementation that wraps a JS object.
771         
772         (WebCore::toVoidCallback):
773         New method that creates a VoidCallback implementation given a JS object.
774         
775         * bindings/scripts/CodeGeneratorJS.pm:
776         Specify that VoidCallback can fail conversion and add a custom conversion function.
777         
778         * html/HTMLMediaElement.cpp:
779         (WebCore::HTMLMediaElement::movieCuePointReached):
780         Call handleEvent on the callback.
781         
782         (WebCore::HTMLMediaElement::removeCuePoint):
783         Comment out parts of this method, it has already been removed in the HTML5 spec and it relies
784         on overriding VoidCallback equality.
785         
786         * html/VoidCallback.cpp: Removed.
787         
788         * html/VoidCallback.h:
789         (WebCore::VoidCallback::VoidCallback):
790         (WebCore::VoidCallback::~VoidCallback):
791         Make this an abstract class with a pure virtual handleEvent method.
792         
793 2007-11-15  Adam Roben  <aroben@apple.com>
794
795         Fix <rdar://5485108> Type-select while a <select> menu is open doesn't work
796
797         There were two things broken here:
798            - WebView now requires a WM_CHAR message to be sent before it will
799              create a keyboard event with a charCode, but we were only sending
800              a WM_KEYDOWN event.
801            - The popup menu was not updating its focused index when the
802              <select> element's selectedIndex changed.
803
804         Reviewed by Adele.
805
806         * platform/win/PopupMenuWin.cpp:
807         (WebCore::PopupMenu::updateFromElement): Update the focused index from
808         the client's selected index.
809         (WebCore::PopupWndProc): When we receive a WM_CHAR message for a
810         printable character, manufacture a WM_KEYDOWN message for it and post
811         both that and the current WM_CHAR message to the WebView.
812
813 2007-11-15  Brady Eidson  <beidson@apple.com>
814
815         Build fix
816
817         * storage/DatabaseTracker.cpp:
818         (WebCore::DatabaseTracker::fullPathForDatabase):
819         (WebCore::DatabaseTracker::databaseNamesForOrigin):
820
821 2007-11-15  Brady Eidson  <beidson@apple.com>
822
823         Reviewed by John and Sam
824
825         Stubbing out everything required for a WebKit API for databases
826
827         Biggest change in WebCore is that we passed around SecurityOriginData as the representation
828         of a SecurityOrigin, instead of a String or a SecurityOrigin itself (which is an opaque object
829         that has a different purpose besides just hanging on to the data)
830
831         * WebCore.base.exp:
832         * WebCore.xcodeproj/project.pbxproj:
833
834         * platform/SecurityOrigin.cpp:
835         * platform/SecurityOrigin.h:
836         * platform/SecurityOriginData.h: Added.  Simple object to encapsulate the 3
837           pieces of data in the SecurityOrigin tuple
838         (WebCore::SecurityOriginData::SecurityOriginData):
839         (WebCore::SecurityOriginData::protocol):
840         (WebCore::SecurityOriginData::host):
841         (WebCore::SecurityOriginData::port):
842         (WebCore::SecurityOriginData::toString): Simple concatenation of the 3 components,
843           colon separated
844
845         * storage/Database.cpp:
846         (WebCore::Database::Database): Use SecurityOriginData instead
847
848         * storage/DatabaseTracker.cpp:
849         (WebCore::DatabaseTracker::fullPathForDatabase):
850         (WebCore::DatabaseTracker::databaseNamesForOrigin):
851         (WebCore::DatabaseTracker::deleteDatabasesWithOrigin):
852         (WebCore::DatabaseTracker::deleteDatabase):
853         * storage/DatabaseTracker.h:
854
855         * storage/DatabaseTrackerClient.h: Added.  For dispatching notifications up to WebKit
856         (WebCore::DatabaseTrackerClient::~DatabaseTrackerClient):2007-11-15  Jon Honeycutt  <jhoneycutt@apple.com>
857
858 2007-11-15  Jon Honeycutt  <jhoneycutt@apple.com>
859
860         Reviewed by Anders.
861
862         NP_ASFILEONLY streams should not buffer data in m_deliveryData.
863
864         * plugins/win/PluginStreamWin.cpp:
865         (WebCore::PluginStreamWin::didReceiveData):
866
867 2007-11-15  Justin Garcia  <justin.garcia@apple.com>
868
869         Reviewed by Adele Peterson.
870
871         <rdar://problem/5497643> Crash at Node::isDescendantOf when switching out of Edit HTML Source mode
872         
873         A textarea that contained the selection was removed but the selection wasn't cleared,
874         and we'd crash in code that assumed a valid, in-document selection.
875
876         * editing/SelectionController.cpp:
877         (WebCore::removingNodeRemovesPosition): Clear the selection if the node being removed is the
878         shadowAncestorNode of the node that contains the position, not just if the node being removed
879         contains that shadowAncestorNode.
880
881 2007-11-15  Nikolas Zimmermann  <zimmermann@kde.org>
882
883         Reviewed by Maciej.
884
885         Fix logic error: calculateGlyphBoundaries takes RTL text into account itself, no need to adjust offsets before.
886
887         * rendering/SVGInlineTextBox.cpp:
888         (WebCore::SVGInlineTextBoxClosestCharacterToPositionWalker::chunkPortionCallback):
889         (WebCore::SVGInlineTextBoxSelectionRectWalker::chunkPortionCallback):
890
891 2007-11-15  Anders Carlsson  <andersca@apple.com>
892
893         Reviewed by Brady.
894
895         <rdar://problem/5562470>
896         openDatabase does not work when the version string is empty
897
898         If the string is empty, pass a real empty string to sqlite3_bind_text16.
899         
900         * platform/sql/SQLiteStatement.cpp:
901         (WebCore::SQLiteStatement::bindText):
902
903 2007-11-15  Anders Carlsson  <andersca@apple.com>
904
905         Reviewed by Brady.
906
907         Get rid of SQLiteStatement::bindText and rename bindText16 to bindText.
908         Remove the copy parameter from bindText and bindBlob and always copy passed in data instead.
909
910         * loader/icon/IconDatabase.cpp:
911         (WebCore::IconDatabase::setIconIDForPageURLInSQLDatabase):
912         (WebCore::IconDatabase::removePageURLFromSQLDatabase):
913         (WebCore::IconDatabase::getIconIDForIconURLFromSQLDatabase):
914         (WebCore::IconDatabase::addIconURLToSQLDatabase):
915         (WebCore::IconDatabase::getImageDataForIconURLFromSQLDatabase):
916         (WebCore::IconDatabase::writeIconSnapshotToSQLDatabase):
917         * platform/sql/SQLiteStatement.cpp:
918         (WebCore::SQLiteStatement::prepare):
919         * platform/sql/SQLiteStatement.h:
920         * storage/Database.cpp:
921         (WebCore::setTextValueInDatabase):
922         * storage/DatabaseTracker.cpp:
923         (WebCore::DatabaseTracker::fullPathForDatabase):
924         (WebCore::DatabaseTracker::databaseNamesForOrigin):
925         (WebCore::DatabaseTracker::addDatabase):
926
927 2007-11-14  Brady Eidson <beidson@apple.com>
928
929         Rubberstamped by Sam
930
931         * platform/SecurityOrigin.h: Lets make this an unsigned short and *not* rule out half the possible ports?
932
933 2007-11-14  Alexey Proskuryakov  <ap@webkit.org>
934
935         Reviewed by Justin Garcia.
936
937         http://bugs.webkit.org/show_bug.cgi?id=15781
938         REGRESSION: Ligatures fail to form when typing in Devanagari (because WebKit can't handle
939         a marked range that covers half of a composed character sequence)
940
941         Test: platform/mac/editing/input/devanagari-ligature.html
942
943         This fix is somewhat of a hack, as it asks editing commands to work with invalid selections.
944         However, this is not entirely new for them, as Roman accents are typed in a similar manner.
945
946         In the future, we probably want to make commands work with ranges (or Positions explicitly).
947
948         * editing/Editor.cpp:
949         (WebCore::Editor::selectComposition): Force selection to composition range.
950         * editing/InsertTextCommand.cpp:
951         (WebCore::InsertTextCommand::input): Force ending selection to inserted text range.
952
953 2007-11-14  Beth Dakin  <bdakin@apple.com>
954
955         Reviewed by Hyatt.
956
957         Fix for <rdar://problem/5540855> REGRESSION: Combination of client-
958         side image map and <a> tag is not working properly (15522)
959
960         * html/HTMLMapElement.cpp:
961         (WebCore::HTMLMapElement::checkDTD): Allow <map> to have both block 
962         and inline children rather than just block children. This matches 
963         Firefox. 
964
965 2007-11-14  Justin Garcia  <justin.garcia@apple.com>
966
967         Reviewed by Alexey Proskuryakov.
968
969         <rdar://problem/5546763> CrashTracer: [USER] 362 crashes at WebCore::DeleteSelectionCommand::mergeParagraphs
970
971         * editing/DeleteSelectionCommand.cpp:
972         (WebCore::DeleteSelectionCommand::handleGeneralDelete): 
973         Removed an irrelevant FIXME.
974         (WebCore::DeleteSelectionCommand::mergeParagraphs): If the block that contained the end of the selection
975         hasn't been removed but has been emptied by deletion, we would to try and fail to create a VisiblePosition
976         inside that block, which could lead to a crash.  If that happens, there's no content in the block to move,
977         so just remove the block and return.
978         Preserve m_needPlaceholder during the call to moveParagraphs, since it may change it and since it does
979         its own placeholder insertion when necessary.
980         (WebCore::DeleteSelectionCommand::doApply): No need to check m_needPlaceholder before calling mergeParagraphs,
981         because it handles preserving m_needPlaceholder when it calls moveParagraphs.
982         
983 2007-11-14  Timothy Hatcher  <timothy@apple.com>
984
985         Reviewed by Adam.
986
987         Bug 14380: Long DOM ancestry breadcrumb lists get cut off
988         http://bugs.webkit.org/show_bug.cgi?id=14380
989
990         The breadcumbs will now be compacted and collapsed if there isn't enough room
991         to show everything. The collapsing algorithm always affects the crumbs that
992         are farthest away from the selected or hovered crumb first.
993
994         * page/inspector/DocumentPanel.js:
995         * page/inspector/inspector.css:
996
997 2007-11-14  Anders Carlsson  <andersca@apple.com>
998
999         Use the correct include path.
1000         
1001         * platform/Cursor.h:
1002         * plugins/win/PluginPackageWin.h:
1003         * plugins/win/PluginStreamWin.h:
1004
1005 2007-11-13  Brady Eidson  <beidson@apple.com>
1006
1007         Reviewed by Adam
1008
1009         http://bugs.webkit.org/show_bug.cgi?id=15976 - ASSERT/crash when SQLTransactionCallback throws an exception
1010
1011         * storage/SQLTransaction.cpp:
1012         (WebCore::SQLTransaction::deliverTransactionCallback): Make a transaction error for the case where the 
1013           SQLTransactionCallback fails
1014         (WebCore::SQLTransaction::deliverTransactionErrorCallback): Don't assert on the error callback, but null check it
1015           and make the commit/rollback decision accordingly
1016
1017 2007-11-13  Oliver Hunt  <oliver@apple.com>
1018
1019         Reviewed by Anders.
1020
1021         <rdar://problem/5365030> calling dataWithPDFInsideRect on an SVG with a gradient crashes (14780)
1022
1023         When drawing directly to PDF CG may delay the use of the gradient function until outside our
1024         standard drawing path, which in turn could let us invalidate the caches before they were used.
1025
1026         To work around this we now store the cached stops in a RefCounted object, so that we can ensure
1027         that cache exists as long as required.
1028         
1029         * platform/graphics/svg/SVGPaintServerGradient.cpp:
1030         (WebCore::SVGPaintServerGradient::SVGPaintServerGradient):
1031         * platform/graphics/svg/SVGPaintServerGradient.h:
1032         * platform/graphics/svg/cg/SVGPaintServerGradientCg.cpp:
1033         (WebCore::cgGradientCallback):
1034         (WebCore::CGShadingRefForLinearGradient):
1035         (WebCore::CGShadingRefForRadialGradient):
1036         (WebCore::SVGPaintServerGradient::updateQuartzGradientStopsCache):
1037
1038 2007-11-13  Anders Carlsson  <andersca@apple.com>
1039
1040         Fix Windows build.
1041         
1042         * platform/Cursor.h:
1043         * plugins/win/PluginPackageWin.h:
1044         * plugins/win/PluginStreamWin.h:
1045
1046 2007-11-13  Geoffrey Garen  <ggaren@apple.com>
1047
1048         Reviewed by Anders Carlsson.
1049
1050         Renamed Shared to RefCounted.
1051
1052         * ForwardingHeaders/wtf/RefCounted.h: Copied from WebCore/ForwardingHeaders/wtf/Shared.h.
1053         * ForwardingHeaders/wtf/Shared.h: Removed.
1054         * bindings/js/JSSVGPODTypeWrapper.h:
1055         * css/CSSFontFace.h:
1056         * css/CSSRuleList.h:
1057         * css/Counter.h:
1058         * css/Pair.h:
1059         * css/Rect.h:
1060         * css/StyleBase.h:
1061         * css/StyleSheetList.h:
1062         * dom/Attribute.h:
1063         * dom/Clipboard.h:
1064         * dom/DOMImplementation.h:
1065         * dom/Event.h:
1066         * dom/EventListener.h:
1067         * dom/NamedNodeMap.h:
1068         * dom/NodeFilter.h:
1069         * dom/NodeFilterCondition.h:
1070         * dom/NodeList.h:
1071         * dom/QualifiedName.h:
1072         * dom/Range.h:
1073         * dom/RangeException.h:
1074         * dom/RegisteredEventListener.h:
1075         * dom/Traversal.h:
1076         * editing/EditCommand.h:
1077         * history/BackForwardList.h:
1078         * history/CachedPage.h:
1079         * history/HistoryItem.cpp:
1080         (WebCore::HistoryItem::HistoryItem):
1081         * history/HistoryItem.h:
1082         * html/CanvasGradient.h:
1083         * html/CanvasPattern.h:
1084         * html/CanvasRenderingContext2D.h:
1085         * html/CanvasStyle.h:
1086         * html/HTMLCollection.h:
1087         * html/MediaError.h:
1088         * html/TimeRanges.h:
1089         * html/VoidCallback.h:
1090         * ksvg2/css/SVGRenderStyle.cpp:
1091         (WebCore::SVGRenderStyle::SVGRenderStyle):
1092         * ksvg2/css/SVGRenderStyle.h:
1093         * ksvg2/css/SVGRenderStyleDefs.cpp:
1094         (StyleFillData::StyleFillData):
1095         (StyleStrokeData::StyleStrokeData):
1096         (StyleStopData::StyleStopData):
1097         (StyleTextData::StyleTextData):
1098         (StyleClipData::StyleClipData):
1099         (StyleMaskData::StyleMaskData):
1100         (StyleMarkerData::StyleMarkerData):
1101         (StyleMiscData::StyleMiscData):
1102         * ksvg2/css/SVGRenderStyleDefs.h:
1103         * ksvg2/svg/SVGAngle.cpp:
1104         (WebCore::SVGAngle::SVGAngle):
1105         * ksvg2/svg/SVGAngle.h:
1106         * ksvg2/svg/SVGAnimatedTemplate.h:
1107         * ksvg2/svg/SVGElementInstanceList.h:
1108         * ksvg2/svg/SVGException.h:
1109         * ksvg2/svg/SVGList.h:
1110         * ksvg2/svg/SVGPathSeg.h:
1111         * ksvg2/svg/SVGPreserveAspectRatio.cpp:
1112         (WebCore::SVGPreserveAspectRatio::SVGPreserveAspectRatio):
1113         * ksvg2/svg/SVGPreserveAspectRatio.h:
1114         * ksvg2/svg/SVGRenderingIntent.h:
1115         * ksvg2/svg/SVGTransform.h:
1116         * ksvg2/svg/SVGUnitTypes.h:
1117         * loader/DocumentLoader.h:
1118         * loader/FormState.h:
1119         * loader/ResourceLoader.h:
1120         * loader/TextResourceDecoder.h:
1121         * loader/icon/IconRecord.h:
1122         * page/BarInfo.h:
1123         * page/Console.h:
1124         * page/DOMSelection.h:
1125         * page/DOMWindow.h:
1126         * page/Frame.h:
1127         * page/History.h:
1128         * page/InspectorController.cpp:
1129         * page/Plugin.h:
1130         * page/Screen.h:
1131         * platform/ArrayImpl.h:
1132         * platform/CString.h:
1133         * platform/Cursor.h:
1134         * platform/DeprecatedValueListImpl.cpp:
1135         (WebCore::DeprecatedValueListImpl::Private::Private):
1136         * platform/FileChooser.h:
1137         * platform/FontFallbackList.h:
1138         * platform/FontFamily.cpp:
1139         (WebCore::FontFamily::FontFamily):
1140         * platform/FontFamily.h:
1141         * platform/FontSelector.h:
1142         * platform/GlyphPageTreeNode.h:
1143         * platform/PopupMenu.h:
1144         * platform/RegularExpression.cpp:
1145         * platform/ScrollBar.h:
1146         * platform/SharedBuffer.h:
1147         * platform/StringImpl.h:
1148         * platform/graphics/Icon.h:
1149         * platform/graphics/svg/SVGResource.h:
1150         * platform/network/FormData.cpp:
1151         (WebCore::FormData::FormData):
1152         * platform/network/FormData.h:
1153         * platform/network/ResourceHandle.h:
1154         * platform/network/ResourceHandleClient.h:
1155         * rendering/RenderStyle.cpp:
1156         (WebCore::StyleSurroundData::StyleSurroundData):
1157         (WebCore::StyleBoxData::StyleBoxData):
1158         (WebCore::StyleVisualData::StyleVisualData):
1159         (WebCore::StyleBackgroundData::StyleBackgroundData):
1160         (WebCore::StyleMarqueeData::StyleMarqueeData):
1161         (WebCore::StyleFlexibleBoxData::StyleFlexibleBoxData):
1162         (WebCore::StyleMultiColData::StyleMultiColData):
1163         (WebCore::StyleTransformData::StyleTransformData):
1164         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
1165         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
1166         (WebCore::StyleInheritedData::StyleInheritedData):
1167         * rendering/RenderStyle.h:
1168         * rendering/SVGCharacterLayoutInfo.h:
1169         (WebCore::SVGCharOnPath::SVGCharOnPath):
1170         * storage/SQLResultSetRowList.h:
1171         * xml/DOMParser.h:
1172         * xml/XMLHttpRequest.h:
1173         * xml/XMLSerializer.h:
1174         * xml/XPathEvaluator.h:
1175         * xml/XPathExpression.h:
1176         * xml/XPathNSResolver.h:
1177         * xml/XPathResult.h:
1178         * xml/XPathValue.h:
1179         * xml/XSLTProcessor.h:
1180
1181 2007-11-13  Brady Eidson  <beidson@apple.com>
1182
1183         Reviewed by Mark Rowe
1184
1185         Remove errantly added files, and fix the idl (for reference's sake)
1186
1187         * storage/JSCustomSQLStatementCallback.h: Removed.
1188         * storage/JSCustomSQLStatementErrorCallback.h: Removed.
1189         * storage/JSCustomSQLTransactionCallback.h: Removed.
1190         * storage/JSCustomSQLTransactionErrorCallback.h: Removed.
1191         * storage/SQLStatementCallback.idl:
1192
1193 2007-11-13  Adam Roben  <aroben@apple.com>
1194
1195         Fix a bug and improve upon Brady's fix
1196
1197         Reviewed by Anders.
1198
1199         * bindings/js/JSSQLTransactionCustom.cpp:
1200         (WebCore::JSSQLTransaction::executeSql): Made the code a little
1201         clearer and more correct.
1202         * loader/icon/IconDatabase.cpp: Put parentheses around the expansion
1203         of IS_ICON_SYNC_THREAD() so that ASSERT_NOT_SYNC_THREAD() does the
1204         comparison it meant to.
1205
1206 2007-11-13  Sam Weinig  <sam@webkit.org>
1207
1208         Fix Qt and Gtk builds.
1209
1210         * WebCore.pro: Remove non-generated idl files.
1211
1212 2007-11-13  Mark Rowe  <mrowe@apple.com>
1213
1214         Remove removed file from the project.
1215
1216         * WebCore.pro:
1217
1218 2007-11-13  Brady Eidson  <beidson@apple.com>
1219
1220         Release build fix
1221
1222         * bindings/js/JSSQLTransactionCustom.cpp:
1223         (WebCore::JSSQLTransaction::executeSql):
1224
1225 2007-11-13  Adam Roben  <aroben@apple.com>
1226
1227         Add WindowMessageBroadcaster
1228
1229         This class is used to listen in on messages sent to HWNDs. Multiple
1230         WindowMessageListeners can be notified about messages sent to a single
1231         HWND, and one WindowMessageListener can listen to messages from
1232         multiple HWNDs.
1233
1234         Reviewed by Ada.
1235
1236         * WebCore.vcproj/WebCore.vcproj: Added new files to project.
1237         * platform/win/WindowMessageBroadcaster.cpp: Added.
1238         (WebCore::instancesMap): Static helper.
1239         (WebCore::WindowMessageBroadcaster::addListener): Registers a listener
1240         for a particular HWND.
1241         (WebCore::WindowMessageBroadcaster::removeListener): Removes a
1242         listener for a particular HWND.
1243         (WebCore::WindowMessageBroadcaster::WindowMessageBroadcaster):
1244         (WebCore::WindowMessageBroadcaster::~WindowMessageBroadcaster):
1245         (WebCore::WindowMessageBroadcaster::destroy): Removes this broadcaster
1246         from the instancesMap, removes all of its listeners, unsubclasses the
1247         window, and deletes the broadcaster.
1248         (WebCore::WindowMessageBroadcaster::unsubclassWindow): Unsubclasses
1249         the window (which means that SubclassedWndProc won't be called again
1250         for this window).
1251         (WebCore::WindowMessageBroadcaster::SubclassedWndProc): Notifies all
1252         the listeners about every message sent to the HWND
1253         * platform/win/WindowMessageBroadcaster.h: Added.
1254         (WebCore::WindowMessageBroadcaster::listeners):
1255         (WebCore::WindowMessageBroadcaster::originalWndProc):
1256         * platform/win/WindowMessageListener.h: Added.
1257
1258 2007-11-13  Geoffrey Garen  <ggaren@apple.com>
1259
1260         Reviewed by Sam Weinig.
1261
1262         Moved Shared.h into wtf so it could be used in more places. Retained 
1263         TreeShared, but moved it to its own file, TreeShared.h.
1264
1265         * ForwardingHeaders/wtf/Shared.h: Added.
1266         * WebCore.xcodeproj/project.pbxproj:
1267         * bindings/js/JSSVGPODTypeWrapper.h:
1268         * css/CSSFontFace.h:
1269         * css/CSSRuleList.h:
1270         * css/Counter.h:
1271         * css/Pair.h:
1272         * css/Rect.h:
1273         * css/StyleBase.h:
1274         * css/StyleSheetList.h:
1275         * dom/Clipboard.h:
1276         * dom/DOMImplementation.h:
1277         * dom/Event.h:
1278         * dom/EventListener.h:
1279         * dom/NamedNodeMap.h:
1280         * dom/NodeFilterCondition.h:
1281         * dom/NodeList.h:
1282         * dom/Range.h:
1283         * dom/RangeException.h:
1284         * dom/RegisteredEventListener.h:
1285         * dom/Traversal.h:
1286         * history/BackForwardList.h:
1287         * history/CachedPage.h:
1288         * history/HistoryItem.h:
1289         * html/CanvasGradient.h:
1290         * html/CanvasPattern.h:
1291         * html/HTMLCollection.h:
1292         * html/MediaError.h:
1293         * html/TimeRanges.h:
1294         * html/VoidCallback.h:
1295         * ksvg2/css/SVGRenderStyleDefs.h:
1296         * ksvg2/svg/SVGAnimatedTemplate.h:
1297         * ksvg2/svg/SVGElementInstanceList.h:
1298         * ksvg2/svg/SVGList.h:
1299         * ksvg2/svg/SVGPathSeg.h:
1300         * ksvg2/svg/SVGPreserveAspectRatio.h:
1301         * ksvg2/svg/SVGRenderingIntent.h:
1302         * ksvg2/svg/SVGTransform.h:
1303         * ksvg2/svg/SVGUnitTypes.h:
1304         * loader/DocumentLoader.h:
1305         * loader/FormState.h:
1306         * loader/ResourceLoader.h:
1307         * loader/TextResourceDecoder.h:
1308         * loader/icon/IconRecord.h:
1309         * page/BarInfo.h:
1310         * page/Console.h:
1311         * page/DOMSelection.h:
1312         * page/DOMWindow.h:
1313         * page/History.h:
1314         * page/InspectorController.cpp:
1315         * page/Plugin.h:
1316         * page/Screen.h:
1317         * platform/ArrayImpl.h:
1318         * platform/CString.h:
1319         * platform/DeprecatedValueListImpl.cpp:
1320         * platform/FontFallbackList.h:
1321         * platform/FontFamily.h:
1322         * platform/FontSelector.h:
1323         * platform/GlyphPageTreeNode.h:
1324         * platform/PopupMenu.h:
1325         * platform/RegularExpression.cpp:
1326         * platform/ScrollBar.h:
1327         * platform/Shared.h: Removed.
1328         * platform/SharedBuffer.h:
1329         * platform/StringImpl.h:
1330         * platform/graphics/Icon.h:
1331         * platform/graphics/svg/SVGResource.h:
1332         * platform/network/FormData.h:
1333         * platform/network/ResourceHandleClient.h:
1334         * rendering/RenderStyle.h:
1335         * rendering/SVGCharacterLayoutInfo.h:
1336         * storage/SQLResultSetRowList.h:
1337         * xml/DOMParser.h:
1338         * xml/XMLSerializer.h:
1339         * xml/XPathEvaluator.h:
1340         * xml/XPathExpression.h:
1341         * xml/XPathNSResolver.h:
1342         * xml/XPathResult.h:
1343
1344 2007-11-13  Brady Eidson  <beidson@apple.com>
1345
1346         JS bindings by Anders, reviewed by Brady
1347         WebCore changes by Brady, reviewed by Anders and Tim
1348
1349         Adapt to the new iteration of the HTML5 client-side storage spec.
1350
1351         Based largely on implementation feedback we generated in landing our first version of this API and also
1352         on the input of others in the community, the database spec went through a large overhaul that addresses
1353         many concerns.  Amongst other changes/improvements:
1354         - SQLTransaction object is added and all transactions are explicit.  In addition, since the API manages
1355           transactions explicitly, transaction-related language in SQL statements is disallowed
1356         - executeSql() is now on a transaction object instead of the database object.
1357         - Database.changeVersion() now takes place within the context of a transaction.  Therefore the version 
1358           change can be atomic along with the statements that modify the DB schema
1359
1360         Most of the logic now takes place during the "transaction steps," which the specification clearly lays out
1361         as a chain of events on the SQLTransaction object where processing is handed off between being processed 
1362         asynchronously and calling back up to javascript.  To accomplish this voodoo, SQLTransaction has a series of 
1363         methods that roughly match up with the "transaction steps" and it keeps a pointer to the next step.
1364
1365         * DerivedSources.make:
1366         * WebCore.xcodeproj/project.pbxproj:
1367
1368         * bindings/js/JSDatabaseCustom.cpp:
1369         (WebCore::JSDatabase::changeVersion): Adapt to the new API
1370         (WebCore::JSDatabase::transaction): Added
1371
1372         * bindings/js/JSSQLTransactionCustom.cpp: Added.
1373         (WebCore::JSSQLTransaction::executeSql): Added
1374
1375         * page/DOMWindow.cpp:
1376         (WebCore::DOMWindow::openDatabase): Add the new arguments
1377         * page/DOMWindow.h:
1378         * page/DOMWindow.idl:
1379
1380         * page/inspector/DatabasePanel.js: Use the new API
1381
1382         * storage/ChangeVersionWrapper.cpp: Added.  Implementation of "SQLTransactionWrapper" that enforces
1383           changing the version of the database
1384         (WebCore::ChangeVersionWrapper::ChangeVersionWrapper):
1385         (WebCore::ChangeVersionWrapper::performPreflight):
1386         (WebCore::ChangeVersionWrapper::performPostflight):
1387         * storage/ChangeVersionWrapper.h: Added.
1388         (WebCore::ChangeVersionWrapper::sqlError):
1389
1390         * storage/Database.cpp: Removed the "main thread" and "background thread" sqlite handles as all sqlite operations can now
1391           happen solely on the background thread - most of these changes result from that change
1392         (WebCore::Database::Database): Removed an obsolete FIXME
1393         (WebCore::Database::openAndVerifyVersion): 
1394         (WebCore::Database::getVersionFromDatabase):
1395         (WebCore::Database::setVersionInDatabase):
1396         (WebCore::Database::versionMatchesExpected): Atomically guarantee that the current version and expected version are the same
1397         (WebCore::Database::performOpenAndVerify):
1398         (WebCore::Database::performTransactionStep): Added, as a hook for the DatabaseTransactionTask on the DatabaseThread
1399         (WebCore::Database::changeVersion): Changed for the new API from JS
1400         (WebCore::Database::transaction): Added, for the new API from JS
1401         (WebCore::Database::scheduleTransaction): Add a transaction to this Database's transaction queue
1402         (WebCore::Database::scheduleTransactionStep): Schedule the current transaction to be called on the background thread
1403         (WebCore::Database::scheduleTransactionCallback): Schedule the current transaction to perform a callback on the main thread
1404         (WebCore::Database::performGetTableNames):
1405         (WebCore::Database::deliverAllPendingCallbacks):
1406         (WebCore::Database::deliverPendingCallback):
1407         (WebCore::Database::setExpectedVersion):
1408         * storage/Database.h: 
1409         * storage/Database.idl:
1410
1411         * storage/DatabaseTask.cpp:  Changed DatabaseTask to create a mutex on demand, and use the existence of that mutex
1412           to replace the m_synchronous flag
1413         (WebCore::DatabaseTask::performTask):
1414         (WebCore::DatabaseTask::lockForSynchronousScheduling):
1415         (WebCore::DatabaseTask::waitForSynchronousCompletion):
1416         (WebCore::DatabaseTransactionTask::DatabaseTransactionTask):
1417         * storage/DatabaseTask.h:
1418
1419         * storage/SQLError.h: New API object
1420
1421         * storage/SQLResultSet.cpp:
1422         (WebCore::SQLResultSet::SQLResultSet): Small changes to the API object
1423         * storage/SQLResultSet.h:
1424         * storage/SQLResultSet.idl:
1425
1426         * storage/SQLStatement.cpp: Added.
1427         (WebCore::SQLStatement::SQLStatement):
1428         (WebCore::SQLStatement::execute): Actually execute the sql statement on the SQLiteDatabase if it's still valid
1429         (WebCore::SQLStatement::setVersionMismatchedError): Flag this statement as bad before it even starts in case
1430           of an actual version vs. expected version mismatch
1431         (WebCore::SQLStatement::performCallback): Call the right callback (SQLStatement or SQLStatementError) for this statement
1432         * storage/SQLStatement.h: Added.
1433         (WebCore::SQLStatement::hasStatementCallback):
1434         (WebCore::SQLStatement::hasStatementErrorCallback):
1435         (WebCore::SQLStatement::sqlError): Get the error for this statement, if any
1436
1437         * storage/SQLTransaction.cpp: Added.
1438         (WebCore::SQLTransaction::SQLTransaction):
1439         (WebCore::SQLTransaction::executeSQL): Entry point for the API from JS
1440         (WebCore::SQLTransaction::enqueueStatement): Add a new statement onto the queue
1441         (WebCore::SQLTransaction::performNextStep): Call the method for the next step
1442         (WebCore::SQLTransaction::performPendingCallback): Call the method for the pending callback
1443         (WebCore::SQLTransaction::openTransactionAndPreflight): Open a transaction to the database and preflight 
1444           using the SQLTransactionWrapper, if any
1445         (WebCore::SQLTransaction::deliverTransactionCallback): Deliver the transaction callback to the javascript thread
1446         (WebCore::SQLTransaction::scheduleToRunStatements): Convinience to schedule this transaction on the database thread 
1447           and make runStatements() the next step
1448         (WebCore::SQLTransaction::runStatements): Start running the sql statements queued up for this transaction 
1449         (WebCore::SQLTransaction::getNextStatement): Bring the next statement off the queue
1450         (WebCore::SQLTransaction::runCurrentStatement): Execute the current statement
1451         (WebCore::SQLTransaction::deliverStatementCallback): Deliver the SQLStatementCallback for this statement
1452         (WebCore::SQLTransaction::postflightAndCommit): Postflight the transaction using SQLTransactionWrapper and commit it
1453         (WebCore::SQLTransaction::handleTransactionError): Make the right call for any error that occurred on the Transaction
1454         (WebCore::SQLTransaction::deliverTransactionErrorCallback): Deliver the SQLTransactionErrorCallback
1455         (WebCore::SQLTransaction::cleanupAfterTransactionErrorCallback): Either do a final commit or rollback to cleanup the
1456           transaction after it error'ed out
1457         * storage/SQLTransaction.h:
1458         (WebCore::SQLTransactionWrapper::~SQLTransactionWrapper): 
1459         (WebCore::SQLTransaction::database):
1460         * storage/SQLTransaction.idl:
1461
1462         The following were made obsolete by the new version of the API:
1463         * bindings/js/JSCustomSQLCallback.cpp: Removed.
1464         * bindings/js/JSCustomSQLCallback.h: Removed.
1465         * bindings/js/JSCustomVersionChangeCallback.cpp: Removed.
1466         * bindings/js/JSCustomVersionChangeCallback.h: Removed.
1467         * storage/DatabaseCallback.cpp: Removed.
1468         * storage/DatabaseCallback.h: Removed.
1469         * storage/SQLCallback.h: Removed.
1470         * storage/SQLCallback.idl: Removed.
1471         * storage/VersionChangeCallback.h: Removed.
1472         * storage/VersionChangeCallback.idl: Removed.
1473
1474 2007-11-13  Dan Bernstein  <mitz@apple.com>
1475
1476         Reviewed by Beth Dakin.
1477
1478         - fix <rdar://problem/5551163> REGRESSION: Cursor does not change to arrow on "X" button in google maps, making it hard to click
1479
1480         * css/html4.css: Added a 'cursor: auto' rule for links.
1481         * manual-tests/link-cursor-auto.html: Added.
1482
1483 2007-11-13  Dan Bernstein  <mitz@apple.com>
1484
1485         Reviewed by Beth Dakin.
1486
1487         - fix <rdar://problem/5516272> Reproducible crash in RenderObject::setStyle involving going Back from a non-HTML document (Bookmarks view, PDF view)
1488
1489         The root cause for the crash is that when a non-HTML view enters the
1490         frame, the frame's document pointer keeps pointing at the last HTML-type
1491         document it contained. This patch does not address the root cause, but
1492         makes changes to account for that condition.
1493
1494         * loader/FrameLoader.cpp:
1495         (WebCore::FrameLoader::receivedMainResourceError): Do not change the
1496         frame's current document's page cache state here.
1497         (WebCore::FrameLoader::invalidateCurrentItemCachedPage): If the frame's
1498         current document is in fact the history item being invalidated, then
1499         set its page cache state here.
1500
1501 2007-11-12  Antti Koivisto  <antti@apple.com>
1502
1503         Reviewed by Adele.
1504
1505         Fix that 'timeupdate' and 'waiting' events were never dispatched.
1506         
1507         Add explicit m_paused attribute instead of trying to derive paused state from
1508         underlying media. Call updatePlayState() to start/stop media playback
1509         when any attribute that affects active playback state changes. This matches 
1510         specification text.
1511         
1512         Test: http/tests/media/video-play-stall.html
1513
1514         * html/HTMLMediaElement.cpp:
1515         (WebCore::HTMLMediaElement::HTMLMediaElement):
1516         (WebCore::HTMLMediaElement::setReadyState):
1517         (WebCore::HTMLMediaElement::paused):
1518         (WebCore::HTMLMediaElement::play):
1519         (WebCore::HTMLMediaElement::pause):
1520         (WebCore::HTMLMediaElement::checkIfSeekNeeded):
1521         (WebCore::HTMLMediaElement::movieDidEnd):
1522         (WebCore::HTMLMediaElement::updatePlayState):
1523         * html/HTMLMediaElement.h:
1524
1525 2007-11-13  John Sullivan  <sullivan@apple.com>
1526
1527         Reviewed by Darin.
1528
1529         removed recently-added PreferredType concept; we found a better way to do what
1530         ths was accomplishing
1531
1532         * bridge/WindowFeatures.h:
1533         (WebCore::WindowFeatures::WindowFeatures):
1534         removed definition of PreferredType
1535                         
1536         * page/ContextMenuController.cpp:
1537         (WebCore::openNewWindow):
1538         removed use of PreferredType
1539
1540 2007-11-12  Alexey Proskuryakov  <ap@webkit.org>
1541
1542         Reviewed by Darin.
1543
1544         http://bugs.webkit.org/show_bug.cgi?id=15954
1545         Move DOM Selection operations out of SelectionController
1546
1547         No change in functionality.
1548
1549         * editing/SelectionController.cpp:
1550         (WebCore::SelectionController::setSelectedRange):
1551         * editing/SelectionController.h:
1552         * page/DOMSelection.cpp:
1553         (WebCore::DOMSelection::anchorNode):
1554         (WebCore::DOMSelection::baseNode):
1555         (WebCore::DOMSelection::anchorOffset):
1556         (WebCore::DOMSelection::baseOffset):
1557         (WebCore::DOMSelection::focusNode):
1558         (WebCore::DOMSelection::extentNode):
1559         (WebCore::DOMSelection::focusOffset):
1560         (WebCore::DOMSelection::extentOffset):
1561         (WebCore::DOMSelection::isCollapsed):
1562         (WebCore::DOMSelection::type):
1563         (WebCore::DOMSelection::rangeCount):
1564         (WebCore::DOMSelection::collapse):
1565         (WebCore::DOMSelection::collapseToEnd):
1566         (WebCore::DOMSelection::collapseToStart):
1567         (WebCore::DOMSelection::empty):
1568         (WebCore::DOMSelection::setBaseAndExtent):
1569         (WebCore::DOMSelection::setPosition):
1570         (WebCore::DOMSelection::modify):
1571         (WebCore::DOMSelection::extend):
1572         (WebCore::DOMSelection::getRangeAt):
1573         (WebCore::DOMSelection::removeAllRanges):
1574         (WebCore::DOMSelection::addRange):
1575         (WebCore::DOMSelection::deleteFromDocument):
1576         (WebCore::DOMSelection::containsNode):
1577         (WebCore::DOMSelection::selectAllChildren):
1578         (WebCore::DOMSelection::toString):
1579         * page/DOMSelection.h:
1580         Moved all DOM API methods to DOMSelection; changed SelectionController::setSelectedRange()
1581         to return its result directly instead of via an ExceptionCode that no caller wanted.
1582
1583         * editing/Editor.cpp:
1584         (WebCore::Editor::deleteRange):
1585         (WebCore::Editor::removeFormattingAndStyle):
1586         (WebCore::Editor::selectComposition):
1587         (WebCore::Editor::setComposition):
1588         * html/HTMLInputElement.cpp: (WebCore::HTMLInputElement::defaultEventHandler):
1589         Adapted for SelectionController::setSelectedRange() now returning a bool.
1590         SelectionController::toString() is no longer avasilable, use plainText() explicitly.
1591
1592         * WebCore.base.exp: Changed SelectionController::setSelectedRange() signature.
1593
1594 2007-11-12  Dan Bernstein  <mitz@apple.com>
1595
1596         Reviewed by Darin Adler.
1597
1598         - <http://bugs.webkit.org/show_bug.cgi?id=15890>
1599           Most of www.aol.com still redraws unnecessarily when headline/photo section changes
1600
1601         Test: fast/repaint/invisible-objects.html
1602
1603         Avoid repainting invisible blocks if they are enclosed in a layer that
1604         contains no visible objects.
1605
1606         * rendering/RenderBlock.cpp:
1607         (WebCore::RenderBlock::layoutBlock):
1608         * rendering/RenderBox.cpp:
1609         (WebCore::RenderBox::absoluteClippedOverflowRect):
1610
1611 2007-11-12  Timothy Hatcher  <timothy@apple.com>
1612
1613         Reviewed by Mark Rowe.
1614
1615         Prevent selecting a word in the breadcrumb or the styles section when double
1616         clicking on a DOM node in the outline tree.
1617
1618         * page/inspector/DocumentPanel.js: Call preventDefault() when a mousedown event
1619           with a detail of 2 or higher comes in. This prevents the selection.
1620         * page/inspector/inspector.css: Mark the breadcrumb as user-select: none.
1621
1622 2007-11-12  Oliver Hunt  <oliver@apple.com>
1623
1624         Reviewed by John S.
1625
1626         <rdar://problem/5537289> REGRESSION: Dragging a link or an image from an IFrame causes the page to not respond to clicks afterwards (15460)
1627         
1628         EventHandler needs to reset these fields when a drag terminates, otherwise
1629         EventHandler is left in an inconsistent state when a drag is initiated on a
1630         page with multiple frames.
1631
1632         * page/EventHandler.cpp:
1633         (WebCore::EventHandler::cancelDragAndDrop):
1634         (WebCore::EventHandler::performDragAndDrop):
1635         (WebCore::EventHandler::clearDragState):
1636         * page/EventHandler.h:
1637
1638 2007-11-12  Oliver Hunt  <oliver@apple.com>
1639
1640         Reviewed by Darin and Antti.
1641
1642         Return behaviour for 0 sized pattern back to what it was prior to r27704
1643
1644         This change in behaviour broke two layout tests in DRT, so correcting it
1645         corrects existing tests.
1646
1647         * platform/graphics/cg/ImageBufferCG.cpp:
1648
1649 2007-11-12  Timothy Hatcher  <timothy@apple.com>
1650
1651         Reviewed by John.
1652
1653         <rdar://problem/5268311> REGRESSION (Safari 2-3): Exception thrown when calling -[WebDataSource subresources]
1654
1655         * page/mac/WebCoreFrameBridge.mm:
1656         (-[WebCoreFrameBridge getAllResourceDatas:andResponses:]):
1657         If the SharedBuffer is null insert an empty NSData instead of nil.
1658
1659 2007-11-12  Darin Adler  <darin@apple.com>
1660
1661         Reviewed by Tim.
1662
1663         - http://bugs.webkit.org/show_bug.cgi?id=15947
1664           speed up page loading a bit by inlining
1665
1666         * loader/FrameLoader.cpp: (WebCore::FrameLoader::isLocationChange):
1667         Factored out the slow case of isScheduledLocationChangePending into this.
1668
1669         * loader/FrameLoader.h:
1670         (WebCore::FrameLoader::isScheduledLocationChangePending): Added an
1671         inline check of the far and away most common case, where m_scheduledRedirection
1672         is 0; the rest is in the isLocationChange function.
1673
1674 2007-11-12  George Staikos  <staikos@kde.org>
1675
1676         Reviewed by Tim.
1677
1678         Extract the text match marker highlight color into RenderTheme instead
1679         of the hardcoded yellow.
1680
1681         * rendering/InlineTextBox.cpp:
1682         (WebCore::InlineTextBox::paintTextMatchMarker):
1683         * rendering/RenderTheme.cpp:
1684         (WebCore::RenderTheme::platformTextSearchHighlightColor):
1685         * rendering/RenderTheme.h:
1686
1687 2007-11-12  Mark Rowe  <mrowe@apple.com>
1688
1689         Fix deadlock on launch on the Mac.
1690
1691         * loader/icon/IconDatabase.cpp:
1692         (WebCore::IconDatabase::open): Restore unlock that was mistakenly removed in r27717.
1693
1694 2007-11-12  Justin Haygood  <jhaygood@reaktix.com>
1695
1696         Reviewed by Brady.
1697
1698         http://bugs.webkit.org/show_bug.cgi?id=15955
1699         Reimplement threading functions in IconDatabase and SQLiteDatabase in terms of the threading abstractions
1700
1701         * loader/icon/IconDatabase.cpp:
1702         (WebCore::IconDatabase::open):
1703         (WebCore::IconDatabase::close):
1704         * loader/icon/IconDatabase.h:
1705         * platform/sql/SQLiteDatabase.cpp:
1706         (WebCore::SQLiteDatabase::SQLiteDatabase):
1707         (WebCore::SQLiteDatabase::open):
1708         (WebCore::SQLiteDatabase::close):
1709         * platform/sql/SQLiteDatabase.h:
1710
1711 2007-11-12  Adam Roben  <aroben@apple.com>
1712
1713         Windows build fix
1714
1715         * config.h: Touch because VS apparently can't figure out which files
1716         depend on ResourceResponse.h.
1717         * WebCore.vcproj/WebCore.vcproj: Add ResourceResponseBase files to
1718         project and remove old ResourceResponse files.
1719
1720 2007-11-12  Julien Chaffraix  <julien.chaffraix@gmail.com>
1721
1722         Reviewed by Darin.
1723
1724         http://bugs.webkit.org/show_bug.cgi?id=15334
1725         Split ResourceResponse into platform specific files
1726
1727         * WebCore.base.exp:
1728         * WebCore.pro:
1729         * WebCore.vcproj/WebCore.vcproj:
1730         * WebCore.xcodeproj/project.pbxproj:
1731         * platform/network/ResourceResponse.cpp: Removed.
1732         * platform/network/ResourceResponse.h: Removed.
1733         * platform/network/ResourceResponseBase.cpp: Copied from platform/network/ResourceResponse.cpp.
1734         (WebCore::ResourceResponseBase::asResourceResponse):
1735         (WebCore::ResourceResponseBase::isHTTP):
1736         (WebCore::ResourceResponseBase::url):
1737         (WebCore::ResourceResponseBase::setUrl):
1738         (WebCore::ResourceResponseBase::mimeType):
1739         (WebCore::ResourceResponseBase::setMimeType):
1740         (WebCore::ResourceResponseBase::expectedContentLength):
1741         (WebCore::ResourceResponseBase::setExpectedContentLength):
1742         (WebCore::ResourceResponseBase::textEncodingName):
1743         (WebCore::ResourceResponseBase::setTextEncodingName):
1744         (WebCore::ResourceResponseBase::suggestedFilename):
1745         (WebCore::ResourceResponseBase::setSuggestedFilename):
1746         (WebCore::ResourceResponseBase::httpStatusCode):
1747         (WebCore::ResourceResponseBase::setHTTPStatusCode):
1748         (WebCore::ResourceResponseBase::httpStatusText):
1749         (WebCore::ResourceResponseBase::setHTTPStatusText):
1750         (WebCore::ResourceResponseBase::httpHeaderField):
1751         (WebCore::ResourceResponseBase::setHTTPHeaderField):
1752         (WebCore::ResourceResponseBase::httpHeaderFields):
1753         (WebCore::ResourceResponseBase::isAttachment):
1754         (WebCore::ResourceResponseBase::setExpirationDate):
1755         (WebCore::ResourceResponseBase::expirationDate):
1756         (WebCore::ResourceResponseBase::setLastModifiedDate):
1757         (WebCore::ResourceResponseBase::lastModifiedDate):
1758         (WebCore::ResourceResponseBase::updateResourceResponse):
1759         * platform/network/ResourceResponseBase.h: Copied from platform/network/ResourceResponse.h.
1760         (WebCore::ResourceResponseBase::ResourceResponseBase):
1761         * platform/network/cf/ResourceResponse.h: Added.
1762         (WebCore::ResourceResponse::ResourceResponse):
1763         * platform/network/curl/ResourceResponse.h: Added.
1764         (WebCore::ResourceResponse::ResourceResponse):
1765         (WebCore::ResourceResponse::doUpdateResourceResponse):
1766         * platform/network/mac/ResourceResponse.h: Added.
1767         (WebCore::ResourceResponse::ResourceResponse):
1768         * platform/network/qt/ResourceResponse.h: Added.
1769         (WebCore::ResourceResponse::ResourceResponse):
1770         (WebCore::ResourceResponse::doUpdateResourceResponse):
1771
1772 2007-11-11  Justin Haygood  <jhaygood@reaktix.com>
1773
1774         Reviewed by Adam Roben.
1775
1776         http://bugs.webkit.org/show_bug.cgi?id=15939
1777         Adds a currentThread API for use by SQLiteDatabase, etc.
1778
1779         * platform/Threading.h:
1780         * platform/ThreadingNone.cpp:
1781         (WebCore::currentThread):
1782         * platform/gtk/ThreadingGtk.cpp:
1783         (WebCore::identifierByGthreadHandle):
1784         (WebCore::):
1785         * platform/pthreads/ThreadingPthreads.cpp:
1786         (WebCore::identifierByPthreadHandle):
1787         (WebCore::currentThread):
1788
1789 2007-11-11  Dan Bernstein  <mitz@apple.com>
1790
1791         Reviewed by Adam Roben.
1792
1793         - fix http://bugs.webkit.org/show_bug.cgi?id=15942
1794           REGRESSION: Selecting "Edit Html" tab in Blogger causes crash (Assertion failed: isRange())
1795
1796         Test: editing/selection/cleared-by-relayout.html
1797
1798         * editing/Selection.cpp:
1799         (WebCore::Selection::toRange): Check if the selection has been cleared
1800         by updating layout.
1801
1802 2007-11-11  Darin Adler  <darin@apple.com>
1803
1804         Reviewed by Mark Rowe.
1805
1806         - fix line numbers that were off since my recent patch
1807
1808         * platform/SegmentedString.h:
1809         (WebCore::SegmentedSubstring::SegmentedSubstring): Reversed the sense of m_excludeLineNumbers
1810         and rename it to m_doNotExcludeLineNumbers.
1811         (WebCore::SegmentedSubstring::excludeLineNumbers): Updated.
1812         (WebCore::SegmentedSubstring::doNotExcludeLineNumbers): Added.
1813         (WebCore::SegmentedSubstring::setExcludeLineNumbers): Updated.
1814         (WebCore::SegmentedString::advance): Use doNotExcludeLineNumbers to reverse the sense and fix
1815         the regression, but keep the speediness. I accidentally had removed a ! here.
1816
1817         * platform/SegmentedString.cpp:
1818         (WebCore::SegmentedString::advanceSlowCase): Use doNotExcludeLineNumbers.
1819
1820 2007-11-11  Oliver Hunt  <oliver@apple.com>
1821
1822         Reviewed by Darin.
1823
1824         Fix for <rdar://problem/5585334> numfuzz: integer overflows opening
1825         malformed SVG file in WebCore::ImageBuffer::create. Add protection
1826         against a potential overflow.
1827
1828         * platform/graphics/cg/ImageBufferCG.cpp:
1829
1830 2007-11-11  Antti Koivisto  <antti@apple.com>
1831
1832         Reviewed by Darin.
1833
1834         Fix a bunch of cases where the exception code is checked by the function but is not zeroed first.
1835
1836         * bindings/js/kjs_binding.cpp:
1837         (KJS::setDOMException):
1838         * dom/Attr.cpp:
1839         (WebCore::Attr::setPrefix):
1840         * dom/Document.cpp:
1841         (WebCore::Document::createElement):
1842         * dom/Element.cpp:
1843         (WebCore::Element::setPrefix):
1844         * dom/Range.cpp:
1845         (WebCore::Range::setStart):
1846         (WebCore::Range::setEnd):
1847         (WebCore::Range::isPointInRange):
1848         (WebCore::Range::comparePoint):
1849         (WebCore::Range::compareBoundaryPoints):
1850         (WebCore::Range::deleteContents):
1851         (WebCore::Range::processContents):
1852         (WebCore::Range::extractContents):
1853         (WebCore::Range::insertNode):
1854         (WebCore::Range::setStartAfter):
1855         (WebCore::Range::setEndBefore):
1856         (WebCore::Range::setEndAfter):
1857         (WebCore::Range::selectNode):
1858         (WebCore::Range::surroundContents):
1859         (WebCore::Range::setStartBefore):
1860         * editing/TextIterator.cpp:
1861         (WebCore::TextIterator::TextIterator):
1862         * html/CanvasRenderingContext2D.cpp:
1863         (WebCore::CanvasRenderingContext2D::createPattern):
1864         * html/HTMLMediaElement.cpp:
1865         (WebCore::HTMLMediaElement::play):
1866         (WebCore::HTMLMediaElement::pause):
1867         * html/HTMLSelectElement.cpp:
1868         (WebCore::HTMLSelectElement::add):
1869         (WebCore::HTMLSelectElement::setOption):
1870         * xml/XPathEvaluator.cpp:
1871         (WebCore::XPathEvaluator::evaluate):
1872
1873 2007-11-11  Darin Adler  <darin@apple.com>
1874
1875         Reviewed by Mitz.
1876
1877         - http://bugs.webkit.org/show_bug.cgi?id=15945
1878           speed up GraphicsContextCG typical case by skipping roundToDevicePixels
1879
1880         * platform/graphics/cg/GraphicsContextCG.cpp:
1881         (WebCore::GraphicsContext::restorePlatformState): Clear the flag since we no
1882         longer know if the transform is identity or not.
1883         (WebCore::GraphicsContext::strokeArc): Removed an extra set of redundant
1884         CGContextSave/RestoreGState.
1885         (WebCore::GraphicsContext::beginTransparencyLayer): Clear the flag since we no
1886         longer know if the transform is identity or not.
1887         (WebCore::GraphicsContext::endTransparencyLayer): Ditto.
1888         (WebCore::GraphicsContext::scale): Ditto.
1889         (WebCore::GraphicsContext::rotate): Ditto.
1890         (WebCore::GraphicsContext::translate): Ditto.
1891         (WebCore::GraphicsContext::concatCTM): Ditto.
1892         (WebCore::GraphicsContext::roundToDevicePixels): Return quickly if the transform
1893         is known to be identity, and record that fact when we discover it otherwise.
1894
1895         * platform/graphics/cg/GraphicsContextPlatformPrivate.h:
1896         (WebCore::GraphicsContextPlatformPrivate::GraphicsContextPlatformPrivate):
1897         Added a m_userToDeviceTransformKnownToBeIdentity flag, initialized to false.
1898
1899 2007-11-11  Darin Adler  <darin@apple.com>
1900
1901         Reviewed by Mitz.
1902
1903         - http://bugs.webkit.org/show_bug.cgi?id=15944
1904           streamline SegmentedString to speed up parsing
1905
1906         I measured a speed-up of the page load test while developing this patch. I don't
1907         have a precise figure, though.
1908
1909         * html/HTMLTokenizer.h: Removed unneeded lineNumberPtr() function. Also renamed
1910         lineno to m_lineNumber.
1911         * html/HTMLTokenizer.cpp:
1912         (WebCore::HTMLTokenizer::processListing): Don't pass 0 to the advance function
1913         since we don't want to update a line number.
1914         (WebCore::HTMLTokenizer::parseSpecial): Ditto.
1915         (WebCore::HTMLTokenizer::parseComment): Pass the line number data member directly
1916         instead of lineNumberPtr() since the advance function now takes a reference.
1917         (WebCore::HTMLTokenizer::parseServer): Ditto.
1918         (WebCore::HTMLTokenizer::parseProcessingInstruction): Ditto.
1919         (WebCore::HTMLTokenizer::parseText): Ditto.
1920         (WebCore::HTMLTokenizer::parseEntity): Ditto.
1921         (WebCore::HTMLTokenizer::parseTag): Ditto.
1922         (WebCore::HTMLTokenizer::write): Ditto.
1923
1924         * loader/FTPDirectoryDocument.cpp: (WebCore::FTPDirectoryTokenizer::write):
1925         * loader/TextDocument.cpp: (WebCore::TextTokenizer::write):
1926         Don't pass 0 to the advance function.
1927
1928         * platform/SegmentedString.h: (WebCore::SegmentedString::advance): Streamlined
1929         the most common case, and pushed less common cases into a separate function
1930         that is not inlined. Also got rid of a branch by separating the case with a
1931         line number from the case without one.
1932
1933         * platform/SegmentedString.cpp: (WebCore::SegmentedString::advanceSlowCase):
1934         Added. The aforementioned less common cases are here.
1935
1936 2007-11-11  Antti Koivisto  <antti@apple.com>
1937
1938         Forgot to do this review change (and test HTTP commit).
1939
1940         * html/HTMLMediaElement.cpp:
1941         (WebCore::HTMLMediaElement::play):
1942
1943 2007-11-11  Antti Koivisto  <antti@apple.com>
1944
1945         Reviewed by Darin.
1946         
1947         - Update play() and pause() to match current HTML5 draft
1948             - send events asynchronously
1949             - add timeupdate event to pause
1950             - rethrow load() exception, not others
1951         - Use list for async events to get ordering right
1952
1953         Tests: media/video-pause-empty-events.html
1954                media/video-play-empty-events.html
1955                media/video-play-pause-events.html
1956                media/video-play-pause-exception.html
1957
1958         * html/HTMLMediaElement.cpp:
1959         (WebCore::HTMLMediaElement::dispatchEventAsync): 
1960         (WebCore::HTMLMediaElement::asyncEventTimerFired):
1961         (WebCore::HTMLMediaElement::play):
1962         (WebCore::HTMLMediaElement::pause):
1963         * html/HTMLMediaElement.h:
1964
1965 2007-11-11  Nikolas Zimmermann  <zimmermann@kde.org>
1966
1967         Reviewed by Eric.
1968
1969         Fixes: http://bugs.webkit.org/show_bug.cgi?id=6424 (<text>, <tspan> dominant-baseline attribute is not respected)
1970
1971         Add (basic) support for dominant-baseline / alignment-baseline text properties.
1972         Note: there are no official testcases, and no-one implemented it before. Only ASV3
1973               supported dominant-baseline, but not correct it seems.
1974
1975         * rendering/SVGRootInlineBox.cpp:
1976         (WebCore::dominantBaselineToShift):
1977         (WebCore::alignmentBaselineToShift):
1978         (WebCore::SVGRootInlineBox::buildLayoutInformationForTextBox):
1979
1980 2007-11-11  Adam Roben  <aroben@apple.com>
1981
1982         Add wrappers around CoCreateInstance to COMPtr
1983
1984         I followed the example of the Query constructor and query method by
1985         adding a Create constructor and create method.
1986
1987         Reviewed by Darin.
1988
1989         * platform/win/COMPtr.h:
1990         (COMPtr::COMPtr): Added a new constructor that calls
1991         CoCreateInstance.
1992         (COMPtr::create): Added.
1993         (COMPtr::createInstance): Added.
1994
1995 2007-11-11  Alexey Proskuryakov  <ap@nypop.com>
1996
1997         Reviewed by Darin.
1998
1999         http://bugs.webkit.org/show_bug.cgi?id=15896
2000         More editing cleanup
2001
2002         No functionality changes.
2003
2004         * dom/Node.h: Moved several editing-related methods elsewhere.
2005         * dom/Node.cpp: (WebCore::Node::maxCharacterOffset): Renamed from maxOffset()
2006         to highlight that it is a match to offsetInCharacters(), and much different from other
2007         offset-related methods. Added ASSERT_NOT_REACHED(), as callers are supposed to check
2008         offsetInCharacters() before calling this.
2009
2010         * dom/CharacterData.cpp: (WebCore::CharacterData::maxCharacterOffset):
2011         * dom/CharacterData.h: (WebCore::CharacterData::isCharacterDataNode):
2012         Updated for above renamings.
2013
2014         * dom/Comment.{h,cpp}: Removed an override for offsetInCharacters(), which is already present in CharacterData.
2015
2016         * dom/Document.{h,cpp}: Folded updateSelection() into Frame::selectionLayoutChanged().
2017
2018         * dom/Position.h:
2019         * dom/Position.cpp:
2020         (WebCore::Position::uncheckedPreviousOffset): Moved from Node::previousOffset().
2021         (WebCore::Position::uncheckedNextOffset): Moved from Node::NextOffset().
2022         (WebCore::Position::previous): Adapted to the above move.
2023         (WebCore::Position::next): Ditto.
2024         (WebCore::Position::upstream): Removed an isBR() check, since a non-BR element cannot have a BR renderer (I think),
2025         and BR elements are covered by editingIgnoresContent().
2026         (WebCore::Position::downstream): Ditto.
2027         (WebCore::caretMaxRenderedOffset): Moved from Node::caretMaxRenderedOffset().
2028         (WebCore::Position::rendersInDifferentPosition): Updated for the above moves.
2029
2030         * dom/PositionIterator.h: Added a comment describing this class from the original check-in.
2031         * dom/PositionIterator.cpp:
2032         (WebCore::PositionIterator::increment): Updated for the above moves.
2033         (WebCore::PositionIterator::decrement): Ditto.
2034
2035         * dom/ProcessingInstruction.h:
2036         * dom/ProcessingInstruction.cpp: (WebCore::ProcessingInstruction::maxCharacterOffset):
2037         ProcessingInstruction was already returning true from offsetInCharacters(), but didn't override maxCharacterOffset().
2038         I think that implementing it has no actual effect, as PIs are not rendered, but it looks cleaner this way.
2039
2040         * dom/Range.cpp:
2041         (WebCore::Range::selectNodeContents):
2042         * editing/ApplyStyleCommand.cpp:
2043         (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
2044         (WebCore::ApplyStyleCommand::applyInlineStyle):
2045         (WebCore::maxRangeOffset):
2046         (WebCore::ApplyStyleCommand::removeInlineStyle):
2047         (WebCore::ApplyStyleCommand::splitTextAtStartIfNeeded):
2048         (WebCore::ApplyStyleCommand::splitTextAtEndIfNeeded):
2049         (WebCore::ApplyStyleCommand::splitTextElementAtStartIfNeeded):
2050         (WebCore::ApplyStyleCommand::splitTextElementAtEndIfNeeded):
2051         (WebCore::ApplyStyleCommand::mergeEndWithNextIfIdentical):
2052         * editing/CompositeEditCommand.cpp:
2053         (WebCore::CompositeEditCommand::insertNodeAt):
2054         (WebCore::CompositeEditCommand::positionOutsideTabSpan):
2055         * editing/DeleteSelectionCommand.cpp:
2056         (WebCore::DeleteSelectionCommand::handleGeneralDelete):
2057         * editing/InsertLineBreakCommand.cpp:
2058         (WebCore::InsertLineBreakCommand::doApply):
2059         * editing/InsertParagraphSeparatorCommand.cpp:
2060         (WebCore::InsertParagraphSeparatorCommand::doApply):
2061         * editing/InsertTextCommand.cpp:
2062         (WebCore::InsertTextCommand::insertTab):
2063         * editing/visible_units.cpp:
2064         (WebCore::previousLinePosition):
2065         (WebCore::nextLinePosition):
2066         Updated for the above moves.
2067
2068         * editing/Editor.cpp:
2069         (WebCore::Editor::advanceToNextMisspelling): Added a missing rangeCompliantEquivalent() call.
2070
2071         * editing/TextIterator.cpp:
2072         (WebCore::SimplifiedBackwardsTextIterator::SimplifiedBackwardsTextIterator): Changed the condition to obviously
2073         match a maxCharacterOffset() call made after it; hopefully, this doesn't break any border cases.
2074         (WebCore::SimplifiedBackwardsTextIterator::advance): Updated for the above moves.
2075
2076         * editing/htmlediting.h:
2077         * editing/htmlediting.cpp:
2078         (WebCore::canHaveChildrenForEditing): Removed a bogus comment: I don't thin BRs have a special ability to accept
2079         child nodes, other than via DOM manipulation, which is not specific to BRs.
2080         (WebCore::rangeCompliantEquivalent): Removed a check for BR, which is already covered by editingIgnoresContent().
2081         (WebCore::maxDeepOffset): Ditto.
2082         (WebCore::caretMinOffset): Moved from Node. Changed some runtime checks that seemingly cannot fail into assertions.
2083         (WebCore::caretMaxOffset): Ditto.
2084
2085         * page/EventHandler.cpp:
2086         (WebCore::EventHandler::handleMousePressEventSingleClick): Pass 0 to VisiblePosition constructor instead of
2087         caretMinOffset. I didn't want to include htmlediting.h here, and I think that VisiblePosition constructor
2088         will take care of adjusting the offset.
2089
2090         * page/Frame.cpp: (WebCore::Frame::selectionLayoutChanged): Folded Document::updateSelection() here.
2091         * page/mac/WebCoreFrameBridge.mm:
2092         (-[WebCoreFrameBridge smartDeleteRangeForProposedRange:]): Added missing rangeCompliantEquivalent() calls.
2093         * rendering/RenderBlock.cpp: (WebCore::RenderBlock::positionForRenderer): Changed to not round-trip via editing.
2094         Changed some runtime checks that seemingly cannot fail into assertions.
2095
2096 2007-11-11  Darin Adler  <darin@apple.com>
2097
2098         Reviewed by Sam.
2099
2100         - updated for JSRegExp function changes
2101
2102         * platform/RegularExpression.cpp:
2103         (WebCore::RegularExpression::Private::compile):
2104         (WebCore::RegularExpression::match):
2105
2106 2007-11-10  Mark Rowe  <mrowe@apple.com>
2107
2108         Qt Linux build fix.
2109
2110         * platform/UnicodeRange.h:
2111
2112 2007-11-10  Mark Rowe  <mrowe@apple.com>
2113
2114         Qt Windows build fix.
2115
2116         * platform/UnicodeRange.h:
2117
2118 2007-11-10  Nikolas Zimmermann  <zimmermann@kde.org>
2119
2120         Reviewed by Eric.
2121
2122         Fixes: http://bugs.webkit.org/show_bug.cgi?id=15937 (Add glyph-orientation-horizontal/vertical support)
2123         Fixes: http://bugs.webkit.org/show_bug.cgi?id=13971 (text-anchor support on vertical text seems slightly off)
2124
2125         Add glyph-orientation-* support for text & textPath. (90/180/270 and 'auto')
2126         Also fix all vertical text handling - for text & textPath! (especially latin1 characters auto orientation in vertical writing modes)
2127
2128         * WebCore.pro: Add platform/UnicodeRange.cpp to build
2129         * WebCore.xcodeproj/project.pbxproj: Dito.
2130         * rendering/SVGCharacterLayoutInfo.cpp: Respect orientationShiftX/Y & angle in characterTransform()
2131         (WebCore::SVGChar::characterTransform):
2132         * rendering/SVGCharacterLayoutInfo.h: New variables.
2133         (WebCore::SVGCharOnPath::SVGCharOnPath):
2134         (WebCore::SVGChar::SVGChar):
2135         * rendering/SVGRootInlineBox.cpp: Added glyph-orientation-* handling.
2136         (WebCore::glyphOrientationToAngle):
2137         (WebCore::glyphOrientationIsMultiplyOf180Degrees):
2138         (WebCore::calculateGlyphAdvanceAndShiftRespectingOrientation):
2139         (WebCore::cummulatedHeightOfInlineBoxCharacterRange):
2140         (WebCore::cummulatedWidthOrHeightOfTextChunk):
2141         (WebCore::SVGRootInlineBox::buildLayoutInformationForTextBox):
2142
2143 2007-11-10  Timothy Hatcher  <timothy@apple.com>
2144
2145         Reviewed by Sam Weinig.
2146
2147         * page/inspector/StylesSidebarPane.js: Fix the wording of a comment
2148           and switch over to use getUniqueProperties in another place.
2149
2150 2007-11-10  John Sullivan  <sullivan@apple.com>
2151
2152         Reviewed by Sam Weinig
2153
2154         Rest of fix for 5394877
2155
2156         * bindings/js/kjs_window.cpp:
2157         (KJS::Window::isSafeScript):
2158         Don't log unsafe JavaScript attempts in the other version of isSafeScript() if in
2159         private browsing mode either.
2160
2161 2007-11-10  Nikolas Zimmermann  <zimmermann@kde.org>
2162
2163         Reviewed by Oliver.
2164
2165         Fix function name difference - header said 'unicodeRangeForCharacter', actually
2166         implemented function is 'findCharUnicodeRange'. They are not compiled yet.
2167
2168         * platform/UnicodeRange.h:
2169
2170 2007-11-10  Dan Bernstein  <mitz@apple.com>
2171
2172         Reviewed by Darin Adler.
2173
2174         - fix <rdar://problem/5450655> Control-clicking text in a link can surprisingly select only part of the link, should select entire link
2175
2176         No test because context menu events cannot be tested in DumpRenderTree.
2177
2178         * page/EventHandler.cpp:
2179         (WebCore::EventHandler::selectClosestWordOrLinkFromMouseEvent): Added.
2180         If the click occurred in an active link, selects the entire link
2181         element. Otherwise selects the closest word.
2182         (WebCore::EventHandler::sendContextMenuEvent): Call
2183         selectClosestWordOrLinkFromMouseEvent().
2184         * page/EventHandler.h:
2185
2186 2007-11-10  John Sullivan  <sullivan@apple.com>
2187
2188         Reviewed by Tim Hatcher
2189
2190         - fixed <rdar://problem/5394877> Safari should not log unsafe JavaScript attempts when 
2191           in private browsing mode (only an issue if Log JavaScript Exceptions is turned on)
2192
2193         * bindings/js/kjs_window.cpp:
2194         (KJS::Window::isSafeScript):
2195         Don't log unsafe JavaScript attempts to console or chromeClient if in private browsing mode
2196
2197 2007-11-10  Alexey Proskuryakov  <ap@webkit.org>
2198
2199         Reviewed by Darin.
2200
2201         http://bugs.webkit.org/show_bug.cgi?id=15922
2202         Implement more of Mozilla Selection API
2203
2204         Tests: editing/selection/containsNode.html
2205                editing/selection/deleteFromDocument.html
2206                editing/selection/extend.html
2207                editing/selection/selectAllChildren.html
2208
2209         * editing/SelectionController.cpp:
2210         (WebCore::SelectionController::deleteFromDocument):
2211         (WebCore::SelectionController::containsNode):
2212         (WebCore::SelectionController::selectAllChildren):
2213         (WebCore::SelectionController::extend):
2214         * editing/SelectionController.h:
2215         Added deleteFromDocument(), containsNode(), and selectAllChildren(). Reimplemented extend(),
2216         which existed, but didn't match Firefox behavior and wasn't exposed via bindings.
2217         Removed a comment mentioning removeRange(), as this method makes no sense without multiple
2218         selection range support.
2219
2220         * page/DOMSelection.cpp:
2221         (WebCore::DOMSelection::extend):
2222         (WebCore::DOMSelection::deleteFromDocument):
2223         (WebCore::DOMSelection::containsNode):
2224         (WebCore::DOMSelection::selectAllChildren):
2225         * page/DOMSelection.h:
2226         * page/DOMSelection.idl:
2227         Exposed the new methods.
2228
2229 2007-11-10  Alexey Proskuryakov  <ap@webkit.org>
2230
2231         Reviewed by Darin.
2232
2233         http://bugs.webkit.org/show_bug.cgi?id=15892
2234         DOM Range operations are not implemented for ProcessingInstruction nodes
2235
2236         Test: fast/dom/Range/range-processing-instructions.html
2237
2238         * dom/Range.cpp:
2239         (WebCore::Range::processContents): Implemented ProcessingInstruction cases.
2240         (WebCore::Range::checkNodeWOffset): Removed a FIXME - yes, I think that we are supposed
2241         to use ProcessingInstruction.data.
2242
2243 2007-11-09  Timothy Hatcher  <timothy@apple.com>
2244
2245         Reviewed by Mark Rowe.
2246
2247         Bug 12054: Ability to serialize an element subtree (into clipboard?) from the DOM inspector
2248         http://bugs.webkit.org/show_bug.cgi?id=12054
2249
2250         - Add support code for routing copy events to the focused element.
2251         - Implement copying the currently selected DOM node. The node
2252           and it's subtree is copied to the clipboard. If the node has no
2253           outerHTML, the nodeValue is copied (text nodes, etc.)
2254         - Implement copy for the resource sidebar. The URL is copied for the
2255           currently selected resource.
2256
2257         * page/inspector/DocumentPanel.js:
2258         * page/inspector/inspector.js:
2259
2260 2007-11-09  Antti Koivisto  <antti@apple.com>
2261
2262         Reviewed by Adele.
2263
2264         Fix occasional blank video with poster attribute.
2265
2266         * ChangeLog:
2267         * html/HTMLMediaElement.cpp:
2268         (WebCore::HTMLMediaElement::load):
2269         (WebCore::HTMLMediaElement::didRestoreFromCache):
2270         Just calling updateFromElement() does the right thing for both poster image and video.
2271
2272 2007-11-04  Sam Weinig  <sam@webkit.org>
2273
2274         Reviewed by Adam Roben.
2275
2276         <rdar://problem/5435940>
2277         The COM bindings for the DOM should be autogenerated like the other DOM bindings
2278
2279         Initial commit of the autogeneration of the COM DOM Bindings.  No behavior change
2280         is being introduced in this patch and to insure that no conflicts arise, a temporary
2281         prefix of "GEN_" has been used for all the new classes.
2282
2283         The build architecture for these bindings differs slightly from the other autogenerated
2284         bindings.  Instead of building in WebCore and migrating the resuting code to WebKit (as
2285         is done for the Objective-C bindigs currently), the IDLs and generation scripts are
2286         migrated to WebKit and built there.  This is done with a series of scripts and Makefiles.
2287
2288         This commit includes:
2289             - Hand rolled root class/Interface GEN_DOMObject used to facilated object creation
2290               and ref-counting.
2291             - Generating all of the Core DOM and most of HTML and CSS
2292             - Generating Event, EventTarget, and EventListener
2293
2294         * WebCore.vcproj/MigrateIDLAndScripts.make: Added.
2295         * WebCore.vcproj/WebCore.vcproj:
2296         * WebCore.vcproj/migrate-idls.sh: Added.
2297         * bindings/scripts/CodeGenerator.pm:
2298         * bindings/scripts/CodeGeneratorCOM.pm: Added.
2299         * dom/EventListener.h: Make the isWindowEvent parameter default to false
2300         to allow autogeneration based on the IDL.
2301
2302 2007-11-09  Tristan O'Tierney  <tristan@apple.com>
2303
2304         Reviewed by Timothy Hatcher.
2305         
2306         This patch is for the WebKit side of <rdar://problem/5591115>.
2307         We need a way to tell context menu navigations, such as "Open in New Window"
2308         to override any sort of browser preference for tab based navigation.
2309
2310         * bridge/WindowFeatures.h:
2311         (WebCore::WindowFeatures::WindowFeatures):
2312         Added a new struct member var, preferredType
2313         and an accompanying enum type PreferredType
2314         to send a window type recommendation up to the Chrome. 
2315         
2316         * page/ContextMenuController.cpp:
2317         (WebCore::openNewWindow):
2318         Set the window features to recommend a new Window for
2319         "Open in New Window" context menu action.
2320
2321 2007-11-08  Adam Roben  <aroben@apple.com>
2322
2323         Fix <rdar://5483519> Pressing Enter on selected buttons should fire onclick
2324
2325         We now match the behavior of Firefox and IE, which is to always just
2326         send a click event to the focused button when the Enter key is pressed
2327         (previously we were submitting forms directly in some cases).
2328
2329         Reviewed by Adele.
2330
2331         Test: fast/forms/enter-clicks-buttons.html
2332
2333         * html/HTMLButtonElement.cpp:
2334         (WebCore::HTMLButtonElement::defaultEventHandler): Don't do anything
2335         fancy when Enter is pressed on a <button type=button> -- just send a
2336         click event like we do for other button types.
2337         * html/HTMLInputElement.cpp:
2338         (WebCore::HTMLInputElement::defaultEventHandler): Treat type=button
2339         the same way we treat type=submit and type=reset: just send a click
2340         event when Enter is pressed.
2341
2342 2007-11-09  Dan Bernstein  <mitz@apple.com>
2343
2344         Reviewed by Antti Koivisto.
2345
2346         - fix a bug in invisible layer culling: dynamically changing a 
2347           descendant of an invisible layer to be visible did not work
2348
2349         Test: fast/layers/layer-content-visibility-change.html
2350
2351         * rendering/RenderLayer.cpp:
2352         (WebCore::RenderLayer::setHasVisibleContent): If we got visible content,
2353         make sure that our stacking context rebuilds its z-order lists to
2354         include us.
2355
2356 2007-11-09  David Hyatt  <hyatt@apple.com>
2357
2358         Clean up matrix() parsing.  Make sure the first four arguments can be lengths or numbers.  The last two
2359         args can be lengths or numbers or percents.
2360
2361         Reviewed by Beth
2362
2363         * WebCore.xcodeproj/project.pbxproj:
2364         * css/CSSParser.cpp:
2365         (WebCore::TransformOperationInfo::TransformOperationInfo):
2366         (WebCore::CSSParser::parseTransform):
2367         * rendering/RenderStyle.h:
2368         (WebCore::MatrixTransformOperation::apply):
2369
2370 2007-11-09  Beth Dakin  <bdakin@apple.com>
2371
2372         Reviewed by Oliver.
2373
2374         Fix for <rdar://problem/5586370> CSS Transform - incorrect matrix 
2375         math leads to crazy problems
2376
2377         Transform matrices accept the first four parameters as CSS lengths. 
2378         CSS lengths get mapped into WebCore::Lengths as percents by 
2379         WebCore::convertToLength(). Percent lengths cannot call value(). It 
2380         does not yield a correct result and it asserts on Debug builds. 
2381
2382         * rendering/RenderStyle.h:
2383         (WebCore::MatrixTransformOperation::apply): Instead of calling 
2384         value() on the lengths, call calcValue. This fixes the assert and 
2385         the bad rendering. 
2386
2387 2007-11-09  Simon Hausmann  <hausmann@kde.org>
2388
2389         Reviewed by nobody, build/link fix for Qt/Windows.
2390
2391         userIdleTime() is stubbed in win/SystemTimeWin.cpp, so don't
2392         define it twice.
2393
2394         * platform/qt/TemporaryLinkStubs.cpp:
2395
2396 2007-11-09  Simon Hausmann  <hausmann@kde.org>
2397
2398         Reviewed by Holger.
2399
2400         Fix ContextMenu allocation in the Qt port.
2401
2402         Store all items and submenus value based in ContextMenu and ContextMenuItem.
2403         That fixes the crashes when the context menu was populated with sub-menus because
2404         of the use of temporary ContextMenu objects like this:
2405
2406         ContextMenu subMenu(...);
2407         subMenu.appendItem(...);
2408         subMenu.appendItem(...);
2409
2410         subMenuItem.setSubMenu(&subMenu); // temporary pointer, need to _copy_ contents
2411
2412         * platform/ContextMenu.h:
2413         * platform/ContextMenuItem.h:
2414         * platform/PlatformMenuDescription.h:
2415         * platform/qt/ContextMenuItemQt.cpp:
2416         (WebCore::ContextMenuItem::ContextMenuItem):
2417         (WebCore::ContextMenuItem::platformSubMenu):
2418         * platform/qt/ContextMenuQt.cpp:
2419         (WebCore::ContextMenu::ContextMenu):
2420         (WebCore::ContextMenu::~ContextMenu):
2421         (WebCore::ContextMenu::appendItem):
2422         (WebCore::ContextMenu::itemCount):
2423
2424 2007-11-09  Peter Kasting  <zerodpx@gmail.com>
2425
2426         Reviewed by Mark Rowe.
2427
2428         http://bugs.webkit.org/show_bug.cgi?id=15909
2429         Malformed GIFs should not result in memory corruption.
2430
2431         * platform/image-decoders/gif/GIFImageDecoder.cpp:
2432         (WebCore::GIFImageDecoder::haveDecodedRow):
2433
2434 2007-11-08  Timothy Hatcher  <timothy@apple.com>
2435
2436         Reviewed by Sam Weinig.
2437
2438         Some Web Inspector CSS editing changes.
2439         - Only delete the property if all the text is delete or the new user input correctly parses.
2440           This prevents deleting the existing property if the new text is invalid.
2441         - Intercept the Escape key and cancel editing, not saving any changes.
2442
2443         * page/inspector/StylesSidebarPane.js:
2444
2445 2007-11-08  Kevin Ollivier  <kevino@theolliviers.com>
2446
2447         Bakefiles for building WebCore, needed by wx port.
2448
2449         Reviewed by Mark Rowe.
2450
2451         * WebCoreSources.bkl: Added.
2452         * webcore-base.bkl: Added.
2453         * webcore-wx.bkl: Added.
2454
2455 2007-11-08  Justin Haygood  <jhaygood@reaktix.com>
2456
2457         Reviewed by Mark Rowe.
2458
2459         http://bugs.webkit.org/show_bug.cgi?id=15905
2460
2461         Fix builds with HTML 5 Storage support disabled.
2462         ENABLE(DATABASE) needs to be added in a few places.
2463
2464         * page/InspectorController.cpp:
2465         * storage/Database.h:
2466
2467 2007-11-08  Steve Falkenburg  <sfalken@apple.com>
2468
2469         <rdar://problem/5524082> Allow images to be dragged out directly into other apps
2470         
2471         We weren't including CF_HDROP in our image drops.  This broke drag of
2472         images out of the browser window directly into other apps (examples
2473         include notepad, mspaint, msword).
2474         
2475         Reviewed by Oliver, Ada.
2476
2477         * platform/win/ClipboardWin.cpp:
2478         (WebCore::createGlobalImageFileContent): Removed unused variable.
2479         (WebCore::createGlobalHDropContent): Added
2480         (WebCore::writeFileToDataObject): Write HDROP data if available.
2481         (WebCore::writeImageToDataObject): Write HDROP for dragged images.
2482         (WebCore::ClipboardWin::writeURL): Don't write HDROP for dragged URLs.
2483
2484 2007-11-08  Xan Lopez  <xan@gnome.org>
2485
2486         Reviewed by Alp.
2487
2488         http://bugs.webkit.org/show_bug.cgi?id=15908
2489         Use g_object_ref_sink when available
2490
2491         * platform/gtk/PopupMenuGtk.cpp:
2492         (WebCore::PopupMenu::show):
2493         * platform/gtk/ScrollViewGtk.cpp:
2494         (WebCore::ScrollView::setGtkAdjustments):
2495
2496 2007-11-08  Dan Bernstein  <mitz@apple.com>
2497
2498         Reviewed by Beth Dakin.
2499
2500         - fix <rdar://problem/5491922> REGRESSION (Safari 2-3): Flash-based "Cash Optimizer" on etrade.com does not draw completely
2501
2502         Test: fast/dom/length-attribute-mapping.html
2503
2504         * dom/StyledElement.cpp:
2505         (WebCore::StyledElement::addCSSLength): Changed the garbage-stripping
2506         logic to stop after the first "%" or "*" in the string. This allows for
2507         "100%25" to be mapped to "100%" like it is in Firefox and WinIE.
2508
2509 2007-11-08  Kevin McCullough  <kmccullough@apple.com>
2510
2511         - Build fix.
2512
2513         * loader/FrameLoaderClient.h:
2514         * platform/graphics/svg/SVGImageEmptyClients.h:
2515         (WebCore::SVGEmptyFrameLoaderClient::windowObjectCleared):
2516
2517 2007-11-08  Kevin McCullough  <kmccullough@apple.com>
2518
2519         Reviewed by Sam.
2520
2521         - windowObjectCleared() is no longer const.  It needs to setup the
2522         script debugger and cannot be const to do so.
2523
2524         * loader/FrameLoaderClient.h:
2525         * platform/graphics/svg/SVGImageEmptyClients.h:
2526         (WebCore::SVGEmptyFrameLoaderClient::windowObjectCleared):
2527
2528 2007-11-08  Adam Roben  <aroben@apple.com>
2529
2530         Hopeful Windows build fix
2531
2532         * rendering/RenderObject.cpp: Touch this file to make it recompile.
2533
2534 2007-11-08  Sam Weinig  <sam@webkit.org>
2535
2536         Reviewed by Darin.
2537
2538         Convert JavaScript internal function objects to use one class per
2539         function.  This avoids a switch statement inside what used to be
2540         the shared function classes and will allow Shark to better analyze
2541         the code.
2542
2543         To make this switch, the value property of the HashEntry was changed
2544         to a union of an intptr_t (which is used to continue handle valueGetters)
2545         and function pointer which points to a static constructor for the
2546         individual new function objects.
2547
2548         SunSpider claims this is a 1.0% speedup.
2549
2550         - On the WebCore side, I updated CodeGeneratorJS.pm to generate the
2551           new classes and hand updated the remain non-generated (groan) classes.
2552
2553         * bindings/js/JSDOMWindowCustom.cpp:
2554         (WebCore::JSDOMWindow::customGetOwnPropertySlot):
2555         * bindings/js/JSEventTargetNode.cpp:
2556         (WebCore::JSEventTargetNodePrototypeFunctionAddEventListener::callAsFunction):
2557         (WebCore::JSEventTargetNodePrototypeFunctionRemoveEventListener::callAsFunction):
2558         (WebCore::JSEventTargetNodePrototypeFunctionDispatchEvent::callAsFunction):
2559         * bindings/js/JSEventTargetNode.h:
2560         * bindings/js/JSHTMLInputElementBase.cpp:
2561         (WebCore::JSHTMLInputElementBaseFunctionSetSelectionRange::callAsFunction):
2562         (WebCore::JSHTMLInputElementBase::getOwnPropertySlot):
2563         * bindings/js/JSHTMLInputElementBase.h:
2564         (WebCore::JSHTMLInputElementBase::):
2565         * bindings/js/JSXMLHttpRequest.cpp:
2566         (KJS::JSXMLHttpRequestPrototypeFunctionAbort::callAsFunction):
2567         (KJS::JSXMLHttpRequestPrototypeFunctionGetAllResponseHeaders::callAsFunction):
2568         (KJS::JSXMLHttpRequestPrototypeFunctionGetResponseHeader::callAsFunction):
2569         (KJS::JSXMLHttpRequestPrototypeFunctionOpen::callAsFunction):
2570         (KJS::JSXMLHttpRequestPrototypeFunctionSend::callAsFunction):
2571         (KJS::JSXMLHttpRequestPrototypeFunctionSetRequestHeader::callAsFunction):
2572         (KJS::JSXMLHttpRequestPrototypeFunctionOverrideMIMEType::callAsFunction):
2573         (KJS::JSXMLHttpRequestPrototypeFunctionAddEventListener::callAsFunction):
2574         (KJS::JSXMLHttpRequestPrototypeFunctionRemoveEventListener::callAsFunction):
2575         (KJS::JSXMLHttpRequestPrototypeFunctionDispatchEvent::callAsFunction):
2576         * bindings/js/JSXMLHttpRequest.h:
2577         (KJS::JSXMLHttpRequest::impl):
2578         * bindings/js/JSXSLTProcessor.cpp:
2579         (KJS::JSXSLTProcessorPrototypeFunctionImportStylesheet::callAsFunction):
2580         (KJS::JSXSLTProcessorPrototypeFunctionTransformToFragment::callAsFunction):
2581         (KJS::JSXSLTProcessorPrototypeFunctionTransformToDocument::callAsFunction):
2582         (KJS::JSXSLTProcessorPrototypeFunctionSetParameter::callAsFunction):
2583         (KJS::JSXSLTProcessorPrototypeFunctionGetParameter::callAsFunction):
2584         (KJS::JSXSLTProcessorPrototypeFunctionRemoveParameter::callAsFunction):
2585         (KJS::JSXSLTProcessorPrototypeFunctionClearParameters::callAsFunction):
2586         (KJS::JSXSLTProcessorPrototypeFunctionReset::callAsFunction):
2587         * bindings/js/JSXSLTProcessor.h:
2588         * bindings/js/kjs_events.cpp:
2589         (WebCore::JSClipboardPrototypeFunctionClearData::callAsFunction):
2590         (WebCore::JSClipboardPrototypeFunctionGetData::callAsFunction):
2591         (WebCore::JSClipboardPrototypeFunctionSetData::callAsFunction):
2592         (WebCore::JSClipboardPrototypeFunctionSetDragImage::callAsFunction):
2593         * bindings/js/kjs_events.h:
2594         * bindings/js/kjs_navigator.cpp:
2595         (KJS::Plugins::):
2596         (KJS::Navigator::getOwnPropertySlot):
2597         (KJS::Plugins::getOwnPropertySlot):
2598         (KJS::PluginsFunctionRefresh::callAsFunction):
2599         (KJS::NavigatorProtoFuncJavaEnabled::callAsFunction):
2600         * bindings/js/kjs_navigator.h:
2601         (KJS::Navigator::):
2602         * bindings/js/kjs_window.cpp:
2603         (KJS::Window::getOwnPropertySlot):
2604         (KJS::Window::put):
2605         (KJS::WindowProtoFuncAToB::callAsFunction):
2606         (KJS::WindowProtoFuncBToA::callAsFunction):
2607         (KJS::WindowProtoFuncOpen::callAsFunction):
2608         (KJS::WindowProtoFuncScrollBy::callAsFunction):
2609         (KJS::WindowProtoFuncScrollTo::callAsFunction):
2610         (KJS::WindowProtoFuncMoveBy::callAsFunction):
2611         (KJS::WindowProtoFuncMoveTo::callAsFunction):
2612         (KJS::WindowProtoFuncResizeBy::callAsFunction):
2613         (KJS::WindowProtoFuncResizeTo::callAsFunction):
2614         (KJS::WindowProtoFuncSetTimeout::callAsFunction):
2615         (KJS::WindowProtoFuncClearTimeout::callAsFunction):
2616         (KJS::WindowProtoFuncSetInterval::callAsFunction):
2617         (KJS::WindowProtoFuncAddEventListener::callAsFunction):
2618         (KJS::WindowProtoFuncRemoveEventListener::callAsFunction):
2619         (KJS::WindowProtoFuncShowModalDialog::callAsFunction):
2620         (KJS::WindowProtoFuncNotImplemented::callAsFunction):
2621         (KJS::Location::getOwnPropertySlot):
2622         (KJS::Location::put):
2623         (KJS::LocationProtoFuncReplace::callAsFunction):
2624         (KJS::LocationProtoFuncReload::callAsFunction):
2625         (KJS::LocationProtoFuncAssign::callAsFunction):
2626         (KJS::LocationProtoFuncToString::callAsFunction):
2627         * bindings/js/kjs_window.h:
2628         (KJS::Window::):
2629         * bindings/scripts/CodeGeneratorJS.pm:
2630
2631 2007-11-08  Mark Rowe  <mrowe@apple.com>
2632
2633         Fix the Gtk, Qt and Wx builds.
2634
2635         * platform/gtk/TemporaryLinkStubs.cpp:
2636         * platform/qt/TemporaryLinkStubs.cpp:
2637         * platform/wx/TemporaryLinkStubs.cpp:
2638
2639 2007-11-08  Mark Rowe  <mrowe@apple.com>
2640
2641         Not reviewed.  Fix two instances of includes using the wrong case in the filename.
2642
2643         * platform/graphics/mac/MoviePrivateQTKit.mm:
2644         * platform/wx/MimeTypeRegistryWx.cpp:
2645
2646 2007-11-08  Darin Adler  <darin@apple.com>
2647
2648         Reviewed by Adam.
2649
2650         - fix <rdar://problem/5552943> accesskey does not focus <button> elements
2651
2652         Test: fast/forms/access-key.html
2653
2654         * html/HTMLButtonElement.cpp: (WebCore::HTMLButtonElement::accessKeyAction):
2655         Added a call to focus.
2656
2657 2007-11-07  Darin Adler  <darin@apple.com>
2658
2659         Reviewed by Steve.
2660
2661         - cut down on notImplemented() functions on Windows
2662
2663         * bridge/AXObjectCache.h: Put #if around the accessibility
2664         global.
2665
2666         * bridge/win/FrameWin.cpp: (WebCore::Frame::setNeedsReapplyStyles):
2667         Moved here from TemporaryLinkStubs.
2668
2669         * dom/Document.cpp: (WebCore::Document::lastModified): Re-implemented
2670         using the ResourceResponse that's now available from the DocumentLoader.
2671
2672         * editing/JSEditor.cpp: (execTranspose): Changed to call transpose() on
2673         the Editor instead of the obsolete one on the Frame.
2674
2675         * loader/DocumentLoader.h: Removed getResponseModifiedHeader.
2676         * loader/FrameLoader.h: Removed overrideMediaType.
2677
2678         * loader/gtk/DocumentLoaderGtk.cpp: Removed.
2679         * loader/mac/DocumentLoaderMac.mm: Removed.
2680         * loader/qt/DocumentLoaderQt.cpp: Removed.
2681
2682         * page/Frame.cpp: Removed transpose.
2683         * page/Frame.h: Ditto.
2684         * page/FrameView.h: Removed updateBorder.
2685         * page/gtk/FrameGtk.cpp: Removed issueTransposeCommand.
2686         * page/mac/FrameMac.mm: Ditto.
2687         * page/mac/WebCoreFrameBridge.h: Removed issueTransposeCommand and
2688         overrideMediaType.
2689         * page/qt/FrameQt.cpp: Removed issueTransposeCommand.
2690
2691         * platform/gtk/TemporaryLinkStubs.cpp: Removed gAccessibilityEnabled.
2692         * platform/qt/TemporaryLinkStubs.cpp: Ditto.
2693         * platform/win/TemporaryLinkStubs.cpp: Removed or moved all but 3 of the stubs.
2694         * platform/wx/TemporaryLinkStubs.cpp: Removed gAccessibilityEnabled,
2695         issueTransposeCommand, and overrideMediaType.
2696
2697         * platform/network/cf/ResourceHandleCFNet.cpp:
2698         (WebCore::ResourceHandle::loadsBlocked): Moved here from TemporaryLinkStubs.
2699         (WebCore::ResourceHandle::willLoadFromCache): Ditto.
2700         * platform/win/GraphicsContextWin.cpp:
2701         (WebCore::GraphicsContextPlatformPrivate::clip): Ditto.
2702         * platform/win/ScrollViewWin.cpp: (WebCore::ScrollView::inWindow): Ditto.
2703         * platform/win/SystemTimeWin.cpp: (WebCore::userIdleTime): Ditto.
2704         * platform/win/WidgetWin.cpp: (WebCore::Widget::setIsSelected): Ditto.
2705
2706         * WebCore.pro: Updated for removed files.
2707         * WebCore.xcodeproj/project.pbxproj: Updated for removed file.
2708
2709 2007-11-08  Mark Rowe  <mrowe@apple.com>
2710
2711        Build fix for case-sensitive file systems.  Fix case of file names
2712        in #include's.
2713
2714         * html/HTMLMediaElement.cpp:
2715         * platform/graphics/Movie.cpp:
2716
2717 2007-11-08  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2718
2719         Reviewed by Lars Knoll <lars@trolltech.com>.
2720
2721         Remove some warnings about not implemented methods.
2722
2723         * ResourceHandle::loadsBlocked and ResourceHandle::supportsBufferedData are
2724         specific to the NS API and won't be implemented on Qt.
2725         * ResourceHandle::bufferedData can not be reached as we return false in
2726         ResourceHandle::supportsBufferedData.
2727
2728
2729         * platform/network/qt/ResourceHandleQt.cpp:
2730         (WebCore::ResourceHandle::supportsBufferedData):
2731
2732 2007-11-08  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2733
2734         Reviewed by Lars Knoll <lars@trolltech.com>.
2735
2736         Cleanup checking for the request method.
2737
2738         * Check the request method only in QWebNetworkManager::add.
2739         * Currently HEAD, GET, POST are allowed and for everything else
2740         QWebNetworkManager::add returns false.
2741         * Returning false is compatible with ResourceHandle::start and it
2742         can be used in ResourceHandle::loadResourceSynchronously to generate
2743         a ResourceError
2744
2745
2746         * platform/network/qt/ResourceHandleQt.cpp:
2747         (WebCore::ResourceHandle::start):
2748         (WebCore::ResourceHandle::loadResourceSynchronously):
2749
2750 2007-11-08  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2751
2752         Reviewed by Lars Knoll <lars@trolltech.com>.
2753
2754         Implement WebCore::callOnMainThread
2755
2756         Implemented using a global QObject, that is moved to the main thread
2757         and then sending a custom event to it.
2758         Picked a number below QEvent::User but above any other documented value.
2759
2760
2761         * platform/qt/ThreadingQt.cpp:
2762         (WebCore::PerformFunctionEvent::PerformFunctionEvent):
2763         (WebCore::MainThreadInvoker::MainThreadInvoker):
2764         (WebCore::MainThreadInvoker::event):
2765         (WebCore::callOnMainThread):
2766
2767 2007-11-08  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2768
2769         Reviewed by Lars Knoll <lars@trolltech.com>.
2770
2771         Avoid problems with calling QPainter::begin() on an already active paintdevice
2772
2773         * Partial pick from 6200e04c3e0a77873c3b3f3969b65bc701020326 to avoid getting
2774         crashes on Qt/Mac 4.4 with QPainter::begin to fail because we already draw.
2775         * If we are in a layout or need one do not paint. This can happen for the PlatformScrollBar
2776         used by the ScrollView on a layout triggered by QWebPage::paintEvent.
2777
2778
2779         * platform/qt/WidgetQt.cpp:
2780         (WebCore::Widget::invalidateRect):
2781
2782 2007-11-08  Eric Seidel  <eric@webkit.org>
2783
2784         No review.
2785
2786         * ksvg2/svg/SVGPathElement.h: remove old comment
2787
2788 2007-11-07  Antti Koivisto  <antti@apple.com>
2789
2790         Reviewed by Ollie.
2791
2792         Ensure video renderer has correct size if video has already been loaded
2793         when it is constructed.
2794
2795         * rendering/RenderVideo.cpp:
2796         (WebCore::RenderVideo::RenderVideo):
2797
2798 2007-11-07  Antti Koivisto  <antti@apple.com>
2799
2800         Reviewed by Ollie.
2801
2802         Ensure video is visible when it should be.
2803
2804         * rendering/RenderVideo.cpp:
2805         (WebCore::RenderVideo::updateMovie):
2806
2807 2007-11-07  Dan Bernstein  <mitz@apple.com>
2808
2809         Reviewed by Darin Adler.
2810
2811         - fix <rdar://problem/5523503> Safari crashes clicking scroll bar in FaceBook 'Trips'
2812
2813         Layers and listboxes are two kinds of ScrollBarClient that can be
2814         removed while the scrollbar is tracking the mouse. The scrollbar is not
2815         destroyed until later, and meanwhile it can try to call the client,
2816         which results in a crash.
2817
2818         * manual-tests/stale-scrollbar-client-crash.html: Added.
2819         * platform/ScrollBar.h:
2820         (WebCore::Scrollbar::setClient): Added.
2821         * rendering/RenderLayer.cpp:
2822         (WebCore::RenderLayer::destroyScrollbar): Call Scrollbar::setClient().
2823         * rendering/RenderListBox.cpp:
2824         (WebCore::RenderListBox::~RenderListBox): Ditto.
2825
2826 2007-11-07  Adam Roben  <aroben@apple.com>
2827
2828         Fix <rdar://5569268> Crash when opening any FTP site in second tab/window
2829
2830         Reviewed by Sam.
2831
2832         No test possible.
2833
2834         * platform/win/SharedBufferWin.cpp:
2835         (WebCore::SharedBuffer::createWithContentsOfFile): Bail if we get an
2836         empty path, because _wfopen_s will crash if we pass it a null pointer.
2837
2838 2007-11-07  David Kilzer  <ddkilzer@apple.com>
2839
2840         WebKit confuses width/height for Media Queries device-aspect-ratio evaluation
2841         <http://bugs.webkit.org/show_bug.cgi?id=14893>
2842         <rdar://problem/5380295>
2843
2844         Reviewed by Darin.
2845
2846         Tests: fast/css/device-aspect-ratio.html
2847                fast/css/max-device-aspect-ratio.html
2848                fast/css/min-device-aspect-ratio.html
2849
2850         * css/MediaQueryEvaluator.cpp:
2851         (WebCore::parseAspectRatio): Renamed method parameters from a/b to h/v.
2852         (WebCore::device_aspect_ratioMediaFeatureEval): Renamed local variables from
2853         a/b to h/v.  Switched first two arguments of the call to cmpvalue() to fix
2854         the bug.
2855
2856 2007-11-07  Dan Bernstein  <mitz@apple.com>
2857
2858         Reviewed by Dave Hyatt.
2859
2860         - fix http://bugs.webkit.org/show_bug.cgi?id=15887
2861           REGRESSION (r27576): Crash in RenderStyle::affectedByHoverRules clicking link on Digg
2862
2863         Test: fast/css/display-none-inline-style-change-crash.html
2864
2865         * dom/Element.cpp:
2866         (WebCore::Element::recalcStyle): Fixed the crash by null-checking
2867         the current style and removed other checks that are not strictly
2868         necessary.
2869
2870 2007-11-07  Brady Eidson  <beidson@apple.com>
2871
2872         Rubberstamped by Sam
2873
2874         Remove FrameLoaderClient methods from SVG that were pruned awhile ago
2875
2876         * platform/graphics/svg/SVGImageEmptyClients.h:
2877
2878 2007-11-07  Dan Bernstein  <mitz@apple.com>
2879
2880         Reviewed by Darin Adler.
2881
2882         - fix a bug where CSS rules with :hover in the ancestor chain stopped
2883           working after changing the inline style declaration of the ancestor
2884
2885         Test: fast/css/affected-by-hover-after-style-change.html
2886
2887         * dom/Element.cpp:
2888         (WebCore::Element::recalcStyle): If we are not forcing style
2889         recalculation for all descendants, preserve any "affected by
2890         {hover|active|drag} bits that we may have acquired from them.
2891         Also renamed _style to currentStyle.
2892
2893 2007-11-06  Timothy Hatcher  <timothy@apple.com>
2894
2895         Reviewed by Adam.
2896
2897         Bug 11920: Web Inspector should have Firebug-like CSS editing
2898         http://bugs.webkit.org/show_bug.cgi?id=11920
2899
2900         * css/CSSComputedStyleDeclaration.h:
2901           (WebCore::CSSComputedStyleDeclaration::isPropertyImplicit): Return false. I'm not sure why
2902           this was true, but computed style has no concept of implicit. So false makes more sense
2903           and makes the code simpler in the inspector. This function was added for the inspector,
2904           so this isn't a compatibility change.
2905         * page/inspector/PropertiesSection.js: Add a getter/setter to reset populated status.
2906         * page/inspector/StylesSidebarPane.js: Some refactoring along with the main support for
2907           style editing.
2908         * page/inspector/inspector.css: Style changes for propery editing and focus correctness.
2909         * page/inspector/inspector.js: Look for a handleKeyEvent function of the focus element before
2910           trying to call a function based on the element's id. Call focused and blurred on the focused
2911           element when currentFocusElement is changed. Use the new listItemElement getter instead of
2912           the private property.
2913         * page/inspector/treeoutline.js: No longer expand on double click if ondblclick is implemented.
2914           Shrink the toggle zone to 10px to better match the size of the arrow. Add an onattach call
2915           to allow generation of the title using the DOM element. Add listItemElement and
2916           childrenListElement getters.
2917         * page/inspector/utilities.js: Add new helper prototype methods on CSSStyleDeclaration.
2918         * page/inspector/DocumentPanel.js: Use the new listItemElement getter instead of the private
2919           property. Also expand the DOM node on double click now that the TreeOutline dosen't do it.
2920         * page/inspector/Resource.js: Use the new listItemElement and childrenListElement getters
2921           instead of the private properties.
2922
2923 2007-11-07  Simon Hausmann  <hausmann@kde.org>
2924
2925         Reviewed by Alexey Proskuryakov.
2926
2927         Coding style fix, don't use inline explicitly.
2928
2929         * bridge/WindowFeatures.h:
2930
2931 2007-11-07  Simon Hausmann  <hausmann@kde.org>
2932
2933         Reviewed by Maciej.
2934
2935         For safety provide a default constructor for WindowFeatures().
2936         ContextMenuController.cpp: createNewWindow as well as QWebPage need to
2937         create a default initialized WindowFeatures object on the fly.
2938
2939         * bridge/WindowFeatures.h:
2940         (WebCore::WindowFeatures::WindowFeatures):
2941
2942 2007-11-07  Simon Hausmann  <shausman@trolltech.com>
2943
2944         Reviewed by Lars.
2945
2946         Fix "nmake clean" for the Qt/Windows build by replacing tmp/ with a variable that ends with the correct type of slash/backslash depending on the choice of compiler/make tool.
2947
2948         * WebCore.pro:
2949
2950 2007-11-07  Simon Hausmann  <hausmann@kde.org>
2951
2952         Reviewed by Lars.
2953
2954         Made the QWebSettings::webGraphic functions static. The implementation was using QWebSettings::global() anyway.
2955
2956         * platform/graphics/qt/ImageQt.cpp:
2957         (loadResourcePixmap):
2958
2959 2007-11-07  Simon Hausmann  <hausmann@kde.org>
2960
2961         Reviewed by Lars.
2962
2963         Moved the WebCore::Image specific function loadResourcePixmap from qwebsettings.cpp to ImageQt.cpp and made it static.
2964
2965         * platform/graphics/qt/ImageQt.cpp:
2966         (loadResourcePixmap):
2967
2968 2007-11-07  Simon Hausmann  <hausmann@kde.org>
2969
2970         Reviewed by Lars.
2971
2972         Restructure the context menu classes for the Qt port. ContextMenu and ContextMenuItem don't store
2973         QActions/QMenus anymore but just store the action type, tag, title and optionally submenu as created
2974         in ContextMenu::populate().
2975         For the actual Qt context menu we traverse this structure after sendContextMenuEvent and create a QMenu
2976         out of it. That menu is currently not functional anymore though.
2977
2978         * platform/ContextMenu.h:
2979         * platform/ContextMenuItem.h:
2980         (WebCore::PlatformMenuItemDescription::PlatformMenuItemDescription):
2981         * platform/PlatformMenuDescription.h:
2982         * platform/qt/ContextMenuItemQt.cpp:
2983         (WebCore::ContextMenuItem::ContextMenuItem):
2984         (WebCore::ContextMenuItem::type):
2985         (WebCore::ContextMenuItem::setType):
2986         (WebCore::ContextMenuItem::action):
2987         (WebCore::ContextMenuItem::setAction):
2988         (WebCore::ContextMenuItem::title):
2989         (WebCore::ContextMenuItem::setTitle):
2990         (WebCore::ContextMenuItem::platformSubMenu):
2991         (WebCore::ContextMenuItem::setSubMenu):
2992         (WebCore::ContextMenuItem::setChecked):
2993         (WebCore::ContextMenuItem::setEnabled):
2994         * platform/qt/ContextMenuQt.cpp:
2995         (WebCore::ContextMenu::ContextMenu):
2996         (WebCore::ContextMenu::~ContextMenu):
2997         (WebCore::ContextMenu::appendItem):
2998         (WebCore::ContextMenu::itemCount):
2999         (WebCore::ContextMenu::insertItem):
3000         (WebCore::ContextMenu::setPlatformDescription):
3001         (WebCore::ContextMenu::platformDescription):
3002
3003 2007-11-07  Simon Hausmann  <hausmann@kde.org>
3004
3005         Reviewed by Lars.
3006
3007         Changed ContextMenu::setPlatformDescription for the Qt port to not show the qmenu right away
3008         but instead just behave as a normal setter that takes ownership of the platform menu description (the qmenu).
3009         Instead now QWebPage::contextMenuEvent() retrieves the QMenu after calling sendContextMenuEvent and calls exec()
3010         on it.
3011
3012         * platform/qt/ContextMenuQt.cpp:
3013
3014 2007-11-07  Simon Hausmann  <hausmann@kde.org>
3015
3016         Reviewed by Lars.
3017
3018         Changed to PlatformMouseEvent constructor to allow construction from a QContextMenuEvent.
3019         Call sendContextMenuEvent on the event handler from a QWidget::contextMenuEvent re-implementation instead of in mousePressEvent.
3020
3021         * platform/PlatformMouseEvent.h:
3022         * platform/qt/PlatformMouseEventQt.cpp:
3023         (WebCore::PlatformMouseEvent::PlatformMouseEvent):
3024
3025 2007-11-07  Lars Knoll  <lars@trolltech.com>
3026
3027         Reviewed by Simon.
3028
3029         don't put nbsp's into the plan text paste
3030         
3031         Fix both ClipboardQt and PasteboardQt to replace
3032         nbsp's with spaces before putting the text onto the
3033         native clipboard. This is consistent with Mac and Win
3034         and fixes at least editing/pasteboard/4076267-3.html
3035
3036         * platform/qt/ClipboardQt.cpp:
3037         (WebCore::ClipboardQt::writeRange):
3038         * platform/qt/PasteboardQt.cpp:
3039         (WebCore::Pasteboard::writeSelection):
3040
3041 2007-11-07  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
3042
3043         Reviewed by Lars Knoll <lars@trolltech.com>.
3044
3045         Implement Pasteboard::writeImage()
3046         
3047         * Pasteboard is now fully implemented. Copying of Images into the Clipboard
3048         is now supported.
3049         * As with URLs we only copy into the Clipboard (and not additionally to the
3050         Selection)
3051         
3052
3053         WARNING: NO TEST CASES ADDED OR CHANGED
3054
3055         * platform/qt/PasteboardQt.cpp:
3056         (WebCore::Pasteboard::writeImage):
3057
3058 2007-11-07  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
3059
3060         Reviewed by Lars Knoll <lars@trolltech.com>.
3061
3062         Apple CodingStyle fixes
3063         
3064
3065         WARNING: NO TEST CASES ADDED OR CHANGED
3066
3067         * platform/qt/PasteboardQt.cpp:
3068         (WebCore::Pasteboard::documentFragment):
3069
3070 2007-11-07  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
3071
3072         Reviewed by Lars Knoll <lars@trolltech.com>.
3073
3074         Implement Pasteboard::writeURL()
3075         * The URL currently gets written as text/plain and text/uri-list.
3076         The win and mac port have some more types which we currently do
3077         not support. When supporting them we can use the 'titleString'
3078         as well.
3079         * As with writeSelection we only copy into the Clipboard. We could
3080         consider copying into the Selection as well.
3081         
3082
3083         WARNING: NO TEST CASES ADDED OR CHANGED
3084
3085         * platform/qt/PasteboardQt.cpp:
3086         (WebCore::Pasteboard::writeURL):
3087
3088 2007-11-07  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
3089
3090         Reviewed by Lars Knoll <lars@trolltech.com>.
3091
3092         Kill whitespace
3093         
3094
3095         WARNING: NO TEST CASES ADDED OR CHANGED
3096
3097         * platform/qt/PasteboardQt.cpp:
3098         (WebCore::Pasteboard::documentFragment):
3099
3100 2007-11-07  Lars Knoll  <lars@trolltech.com>
3101
3102         Reviewed by Simon.
3103
3104         Use the correct function calls to convert a selection to
3105         HTML or plain text.
3106
3107         WARNING: NO TEST CASES ADDED OR CHANGED
3108
3109         * platform/qt/ClipboardQt.cpp:
3110         (WebCore::ClipboardQt::setData):
3111         (WebCore::ClipboardQt::writeRange):
3112         * platform/qt/PasteboardQt.cpp:
3113         (WebCore::Pasteboard::writeSelection):
3114
3115 2007-11-07  Lars Knoll  <lars@trolltech.com>
3116
3117         Reviewed by Simon.
3118
3119         Some more clipboard fixes.
3120         
3121         We have to set things immediately on the QClipBoard if the
3122         Clipboard object is not for dragging.
3123         
3124         This is due to the fact that the Clipboard object might be
3125         rather long lived if accessed through javascript (it'll only
3126         get deleted by JS garbage collection). We have to transfer
3127         the data over to the QClipboard before that to make things work.
3128         
3129         Fixes editing/execCommand/copy-without-selection.html
3130
3131         * platform/qt/ClipboardQt.cpp:
3132         (WebCore::ClipboardQt::ClipboardQt):
3133         (WebCore::ClipboardQt::~ClipboardQt):
3134         (WebCore::ClipboardQt::clearData):
3135         (WebCore::ClipboardQt::clearAllData):
3136         (WebCore::ClipboardQt::getData):
3137         (WebCore::ClipboardQt::setData):
3138         (WebCore::ClipboardQt::declareAndWriteDragImage):
3139         (WebCore::ClipboardQt::writeURL):
3140         (WebCore::ClipboardQt::writeRange):
3141
3142 2007-11-07  Simon Hausmann  <hausmann@kde.org>
3143
3144         Reviewed by Mark.
3145
3146         Fix compilation on Windows with non-cygwin perl. open FILE, "|-" is
3147         not supported due to implicit forks, use IPC::Open2 instead.
3148
3149         * bindings/scripts/IDLParser.pm:
3150
3151 2007-11-07  Dan Bernstein  <mitz@apple.com>
3152
3153         Reviewed by Brady Eidson.
3154
3155         - fix http://bugs.webkit.org/show_bug.cgi?id=15877
3156           REGRESSION: r27486 caused a layout regression at my bank's website
3157
3158         Test: fast/block/float/overhanging-after-height-decrease-offsets.html
3159
3160         * rendering/RenderBlock.cpp:
3161         (WebCore::RenderBlock::layoutBlock):
3162
3163 2007-11-06  Beth Dakin  <bdakin@apple.com>
3164
3165         Reviewed by Sam.
3166
3167         <rdar://problem/5575812> REGRESSION:When using absolute positioning 
3168         with overflow:auto div, WebKit seems to add an additional 15px
3169
3170         * rendering/RenderBox.cpp:
3171         (WebCore::RenderBox::containingBlockWidthForPositioned): We need to 
3172         subtract off the vertical scrollbar width too.
3173
3174 2007-11-06  Justin Garcia  <justin.garcia@apple.com>
3175
3176         Reviewed by Dan Bernstein.
3177         
3178         <rdar://problem/5583387> ASSERTION FAILED: !refChild->hasTagName(bodyTag) when pasting newline in plain text into rich text Mail
3179         <rdar://problem/5583362> REGRESSION (5523.10.3-TOT): Newlines stripped when pasting plain text in Mail
3180
3181         * editing/markup.cpp:
3182         (WebCore::createFragmentFromText): Put paragraphs of text into clones of the block
3183         that encloses the input context, unless that block is the body, which shouldn't
3184         be cloned.  In that case, use regular divs, as we did before r27369.
3185
3186 2007-11-06  Christian Dywan  <christian@twotoasts.de>
3187
3188         Reviewed by Darin.
3189
3190         Fix http://bugs.webkit.org/show_bug.cgi?id=15828
3191         Bug 15828: WebKit GTK include and lib directory is installed in qt4-named directory
3192
3193         * WebCore.pro: Use sane default install paths for the gtk port.
3194
3195 2007-11-06  Justin Garcia  <justin.garcia@apple.com>
3196
3197         Reviewed by Darin Adler.
3198         
3199         <rdar://problem/5576619> 
3200         REGRESSION: Caret disappears after deleting the last character in inline hole (15714)
3201
3202         * editing/TypingCommand.cpp:
3203         (WebCore::TypingCommand::deleteSelection): Like the other TypingCommands, including
3204         both of the other deletion commands, call typingAddedToOpenCommand(), which takes 
3205         the command's endingSelection and sets it as selection.
3206
3207 2007-11-06  Dan Bernstein  <mitz@apple.com>
3208
3209         Reviewed by Antti Koivisto and Dave Hyatt.
3210
3211         - fix <rdar://problem/5582961> Incorrect layout and floating object list corruption when CSS decreases a block's height
3212
3213         Test: fast/block/float/overhanging-after-height-decrease.html
3214
3215         * rendering/RenderBlock.cpp:
3216         (WebCore::RenderBlock::layoutBlock): If after calculating the height
3217         it turns out that there are overhanging floats that were not overhanging
3218         before, rescan children with overhanging floats and add them. 
3219         (WebCore::RenderBlock::layoutBlockChildren): Added a parameter that
3220         returns the lowest float bottom of any of the children.
3221         (WebCore::RenderBlock::addOverhangingFloats): Changed to return the
3222         lowest float bottom.
3223         * rendering/RenderBlock.h:
3224
3225 2007-11-06  Adele Peterson  <adele@apple.com>
3226
3227         Reviewed by Darin.
3228
3229         Switched all uses of HTMLImageLoader to use OwnPtrs.
3230
3231         * html/HTMLInputElement.h:
3232         * html/HTMLInputElement.cpp:
3233         (WebCore::HTMLInputElement::init):
3234         (WebCore::HTMLInputElement::~HTMLInputElement):
3235         (WebCore::HTMLInputElement::setInputType):
3236         (WebCore::HTMLInputElement::parseMappedAttribute):
3237         (WebCore::HTMLInputElement::attach):
3238         * html/HTMLObjectElement.h:
3239         * html/HTMLObjectElement.cpp:
3240         (WebCore::HTMLObjectElement::HTMLObjectElement):
3241         (WebCore::HTMLObjectElement::~HTMLObjectElement):
3242         (WebCore::HTMLObjectElement::parseMappedAttribute):
3243         (WebCore::HTMLObjectElement::attach):
3244         * html/HTMLVideoElement.h:
3245         * html/HTMLVideoElement.cpp:
3246         (WebCore::HTMLVideoElement::HTMLVideoElement):
3247         (WebCore::HTMLVideoElement::attach):
3248         (WebCore::HTMLVideoElement::detach):
3249         (WebCore::HTMLVideoElement::parseMappedAttribute):
3250
3251 2007-11-06  Antti Koivisto  <antti@apple.com>
3252
3253         Reviewed by Darin.
3254         
3255         Trigger media load on on src attribute changes as specified in new HTML5 draft.
3256
3257         Tests: media/video-src-change.html
3258                media/video-src-remove.html
3259                media/video-src-set.html
3260
3261         * html/HTMLMediaElement.cpp:
3262         (WebCore::HTMLMediaElement::attributeChanged):
3263         * html/HTMLMediaElement.h:
3264
3265 2007-11-06  Dan Bernstein  <mitz@apple.com>
3266
3267         Reviewed by Darin Adler.
3268
3269         - fix http://bugs.webkit.org/show_bug.cgi?id=15838
3270           Incomplete repaint toggling "How you know this person" on Facebook
3271
3272         Test: fast/repaint/make-children-non-inline.html
3273
3274         * rendering/RenderBlock.cpp:
3275         (WebCore::RenderBlock::makeChildrenNonInline): Repaint the block. This
3276         is needed because the inline children may be repositioned as they move
3277         into new anonymous blocks, but those blocks have no knowledge of where
3278         their children used to be, so they cannot invalidate those areas.
3279
3280 2007-11-06  Alexey Proskuryakov  <ap@webkit.org>
3281
3282         Reviewed by Darin.
3283
3284         http://bugs.webkit.org/show_bug.cgi?id=15847
3285         Some editing cleanup
3286
3287         No change in functionality.
3288
3289         * editing/TextIterator.cpp:
3290         (WebCore::plainText):
3291         * editing/TextIterator.h:
3292         Made WebCore::plainText() return String instead of DeprecatedString.
3293
3294         * bridge/mac/WebCoreAXObject.mm:
3295         (-[WebCoreAXObject textUnderElement]):
3296         (-[WebCoreAXObject value]):
3297         (-[WebCoreAXObject doAXBoundsForTextMarkerRange:]):
3298         (-[WebCoreAXObject doAXNextSentenceEndTextMarkerForTextMarker:]):
3299         (-[WebCoreAXObject doAXPreviousSentenceStartTextMarkerForTextMarker:]):
3300         Updated for the above change. There is no need to explicitly convert to NSString now.
3301
3302         * editing/EditCommand.cpp:
3303         (WebCore::EditCommand::EditCommand): m_startingSelection and m_endingSelection are actually
3304         initialized in constructor body, so the work done in initializer list was wasted.
3305
3306         (WebCore::EditCommand::apply): Moved some stars.
3307         (WebCore::EditCommand::unapply): Ditto.
3308         (WebCore::EditCommand::reapply): Ditto.
3309         (WebCore::EditCommand::setStartingSelection): The loop exit condition was evaluated twice,
3310         removed one of the checks.
3311
3312         * editing/SelectionController.cpp:
3313         (WebCore::SelectionController::toString): plainText() result type now matches what we need here.
3314
3315         * page/mac/WebCoreFrameBridge.h:
3316         * page/mac/WebCoreFrameBridge.mm:
3317         Removed unused -[WebCoreFrameBridge deleteKeyPressedWithSmartDelete:granularity:] and
3318         -[WebCoreFrameBridge forwardDeleteKeyPressedWithSmartDelete:granularity:].
3319
3320 2007-11-05  Mark Rowe  <mrowe@apple.com>
3321
3322         Mac build fix.
3323
3324         * bindings/js/JSHTMLDocumentCustom.cpp:
3325         (WebCore::writeHelper):
3326
3327 2007-11-05  Adam Roben  <aroben@apple.com>
3328
3329         Don't crash if SafariTheme can't be loaded
3330
3331         PlatformScrollBarSafari and RenderThemeSafari were not checking
3332         whether SafariTheme was successfully loaded. All other uses of
3333         SafariTheme already check this.
3334
3335         Reviewed by Steve.
3336
3337         * platform/win/PlatformScrollBarSafari.cpp: Don't paint if SafariTheme
3338         couldn't be loaded.
3339         (WebCore::PlatformScrollbar::paintButton):
3340         (WebCore::PlatformScrollbar::paintTrack):
3341         (WebCore::PlatformScrollbar::paintThumb):
3342         * rendering/RenderThemeSafari.cpp:
3343         (WebCore::RenderThemeSafari::isControlStyled): Always return true if
3344         we couldn't load SafariTheme. This way we should never try to paint
3345         themed controls (and we assert as such in the paint functions).
3346         (WebCore::RenderThemeSafari::paintCheckbox):
3347         (WebCore::RenderThemeSafari::paintRadio):
3348         (WebCore::RenderThemeSafari::paintButton):
3349         (WebCore::RenderThemeSafari::paintTextField):
3350         (WebCore::RenderThemeSafari::paintCapsLockIndicator):
3351         (WebCore::RenderThemeSafari::paintTextArea):
3352         (WebCore::RenderThemeSafari::paintMenuList):
3353         (WebCore::RenderThemeSafari::paintSliderThumb):
3354         (WebCore::RenderThemeSafari::paintSearchField):
3355         (WebCore::RenderThemeSafari::paintSearchFieldCancelButton):
3356         (WebCore::RenderThemeSafari::paintSearchFieldResultsDecoration):
3357         (WebCore::RenderThemeSafari::paintSearchFieldResultsButton):
3358
3359 2007-11-05  Kevin Ollivier  <kevino@theolliviers.com>
3360
3361         Adding the rest of wx port's graphics impl. 
3362
3363         Rubber-stamped by Maciej Stachowiak.
3364
3365         * platform/graphics/wx/AffineTransformWx.cpp: Added.
3366         * platform/graphics/wx/GraphicsContextWx.cpp: Added.
3367         * platform/graphics/wx/ImageBufferWx.cpp: Added.
3368         * platform/graphics/wx/ImageSourceWx.cpp: Added.
3369         * platform/graphics/wx/ImageWx.cpp: Added.
3370         * platform/graphics/wx/PathWx.cpp: Added.
3371
3372 2007-11-05  Kevin Ollivier  <kevino@theolliviers.com>
3373
3374         wx port bug fixes and new files to get platform/wx building on trunk.
3375
3376         Rubber-stamped by Maciej Stachowiak.
3377
3378         * platform/wx/CursorWx.cpp:
3379         * platform/wx/FileSystemWx.cpp: Added.
3380         * platform/wx/FontCacheWx.cpp:
3381         * platform/wx/FontPlatformDataWx.cpp:
3382         * platform/wx/FontWx.cpp:
3383         * platform/wx/KeyboardEventWx.cpp:
3384         * platform/wx/LocalizedStringsWx.cpp: Added.
3385         * platform/wx/LoggingWx.cpp: Added.
3386         * platform/wx/RenderThemeWx.cpp:
3387         * platform/wx/ScrollViewWx.cpp:
3388         * platform/wx/SharedTimerWx.cpp:
3389         * platform/wx/StringWx.cpp:
3390         * platform/wx/ThreadingWx.cpp: Added.
3391         * platform/wx/WidgetWx.cpp:
3392
3393 2007-11-05  Adele Peterson  <adele@apple.com>
3394
3395         Reviewed by Maciej.
3396
3397         Fix for <rdar://problem/5579999> Add poster attribute for video element
3398
3399         * html/HTMLAttributeNames.in: Added poster attribute.
3400
3401         * html/HTMLImageLoader.cpp: (WebCore::HTMLImageLoader::updateFromElement):
3402           Calls imageSourceAttributeName instead of having special cases for the different kinds of elements. 
3403         * dom/Element.cpp: (WebCore::Element::imageSourceAttributeName): Added.
3404         * dom/Element.h:
3405         * html/HTMLObjectElement.cpp: (WebCore::HTMLObjectElement::imageSourceAttributeName): Added.
3406         * html/HTMLObjectElement.h:
3407
3408         * html/HTMLMediaElement.cpp: (WebCore::HTMLMediaElement::movieNetworkStateChanged):
3409           Calls updatePosterImage when the network state is empty and when the first frame has been loaded.
3410         * html/HTMLMediaElement.h: (WebCore::HTMLMediaElement::rendererIsNeeded): Made this inline.  HTMLVideoElement now also implements this.
3411
3412         * html/HTMLVideoElement.idl: Added case for poster attribute.
3413         * html/HTMLVideoElement.h: Added image loader and flag to keep track of whether or not the poster image should be shown.
3414         * html/HTMLVideoElement.cpp:
3415         (WebCore::HTMLVideoElement::HTMLVideoElement): Initialize m_imageLoader and m_shouldShowPosterImage.
3416         (WebCore::HTMLVideoElement::rendererIsNeeded): Calls HTMLElement::rendererIsNeeded since HTMLMediaElements have renderer by default.
3417         (WebCore::HTMLVideoElement::createRenderer): Create a RenderImage or RenderVideo depending on whether or not the poster image should be shown.
3418         (WebCore::HTMLVideoElement::attach): Set up image loader and RenderImage if necessary.
3419         (WebCore::HTMLVideoElement::detach): Delete image loader if its no longer needed.
3420         (WebCore::HTMLVideoElement::parseMappedAttribute): Added case to process poster attribute.
3421         (WebCore::HTMLVideoElement::poster): Added getter for poster attribute.
3422         (WebCore::HTMLVideoElement::setPoster): Added setter for poster attribute.
3423         (WebCore::HTMLVideoElement::isURLAttribute): Added.
3424         (WebCore::HTMLVideoElement::imageSourceAttributeName): Added.
3425         (WebCore::HTMLVideoElement::updatePosterImage): Added.  Updates m_shouldShowPosterImage and if its changed, detaches and attaches so the renderer is correct.
3426
3427 2007-11-05  Adam Roben  <aroben@apple.com>
3428
3429         Fix <rdar://5563572> SVG image support is turned off
3430
3431         Turned on SVG images for all platforms.
3432
3433         Reviewed by Eric.
3434
3435         * WebCore.vcproj/WebCore.vcproj: Added SVGImage.{cpp,h}
3436         * loader/CachedImage.cpp:
3437         (WebCore::CachedImage::createImage): Removed platform checks for
3438         SVGImage.
3439
3440 2007-11-05  Antti Koivisto  <antti@apple.com>
3441
3442         Reviewed by Darin.
3443
3444         QTMovieView can generate callbacks during paint. This can lead to crashes.
3445         
3446         Delay callbacks so they get handled after painting is completed. No test case,
3447         I don't know how to reliably reproduce this.
3448
3449         * platform/graphics/mac/MoviePrivateQTKit.mm:
3450         (WebCore::MoviePrivate::MoviePrivate):
3451         (WebCore::MoviePrivate::~MoviePrivate):
3452         (WebCore::MoviePrivate::paint):
3453         (-[WebCoreMovieObserver initWithCallback:WebCore::]):
3454         (-[WebCoreMovieObserver disconnect]):
3455         (-[WebCoreMovieObserver loadStateChanged:]):
3456         (-[WebCoreMovieObserver rateChanged:]):
3457         (-[WebCoreMovieObserver sizeChanged:]):
3458         (-[WebCoreMovieObserver timeChanged:]):
3459         (-[WebCoreMovieObserver volumeChanged:]):
3460         (-[WebCoreMovieObserver didEnd:]):
3461         (-[WebCoreMovieObserver setDelayCallbacks:]):
3462
3463 2007-11-05  Antti Koivisto  <antti@apple.com>
3464
3465         Reviewed by Adam.
3466
3467         Add some missing WebCore* prefixes to ObjC classes
3468
3469         * platform/mac/FileChooserMac.mm:
3470         (WebCore::FileChooser::FileChooser):
3471         * platform/mac/SharedBufferMac.mm:
3472         (WebCore::SharedBuffer::createNSData):
3473         (WebCore::SharedBuffer::createCFData):
3474         * platform/mac/SharedTimerMac.cpp:
3475         (WebCore::setSharedTimerFireTime):
3476
3477 2007-11-05  Ada Chan  <adachan@apple.com>
3478
3479         <rdar://problem/5579772> Regression: AltGr does not work
3480         We now store the system key event info in PlatforkKeyboardEvent().
3481
3482         Reviewed by Oliver.
3483
3484         * platform/PlatformKeyboardEvent.h:
3485         (WebCore::PlatformKeyboardEvent::isSystemKey):
3486         * platform/win/KeyEventWin.cpp:
3487         (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
3488
3489 2007-11-02  Tristan O'Tierney  <tristan@apple.com>
3490
3491         Reviewed by Darin Adler.
3492
3493         * WebCore.xcodeproj/project.pbxproj:
3494         Set WindowFeatures.h as a Private header.
3495         
3496         * loader/FrameLoader.cpp:
3497         (WebCore::FrameLoader::createWindow):
3498         Revised to use a single createWindow function instead of
3499         two createWindow functions and one createModalDialog function.
3500         The logic for this is now addressed in WebKit in an effort
3501         to make this easier to follow.
3502         
3503         * page/Chrome.cpp:
3504         (WebCore::Chrome::createWindow):
3505         * page/Chrome.h:
3506         * page/ChromeClient.h:
3507         * page/ContextMenuController.cpp:
3508         (WebCore::openNewWindow):
3509         * platform/graphics/svg/SVGImageEmptyClients.h:
3510         (WebCore::SVGEmptyChromeClient::createWindow):
3511         Revised to take new additional windowFeatures parameter.
3512
3513 2007-11-04  Geoffrey Garen  <ggaren@apple.com>
3514
3515         Reviewed by Darin Adler.
3516         
3517         http://bugs.webkit.org/show_bug.cgi?id=15835
3518
3519         Small adaptations to new KJS::List class.
3520
3521         * bindings/js/kjs_window.cpp:
3522         (KJS::WindowFunc::callAsFunction):
3523         (KJS::ScheduledAction::ScheduledAction):
3524
3525 2007-11-05  Adam Roben  <aroben@apple.com>
3526
3527         Allow passing a base class pointer to COMPtr::copyRefTo
3528
3529         Reviewed by Sam.
3530
3531         * platform/win/COMPtr.h:
3532
3533 2007-11-05  Dan Bernstein  <mitz@apple.com>
3534
3535         Reviewed by Oliver Hunt.
3536
3537         - fix ASSERTION FAILED: !HashTranslator::equal(KeyTraits::emptyValue(), key) when a class attribute is all-whitespace
3538
3539         Test: fast/dom/class-all-whitespace.html
3540
3541         * dom/StyledElement.cpp:
3542         (WebCore::StyledElement::parseMappedAttribute): Check if there is any
3543         non-whitespace character in the class attribute.
3544
3545 2007-11-05  Brady Eidson  <beidson@apple.com>
3546
3547         Reviewed by Sam
3548
3549         Add transaction blocking to the DatabaseAuthorizer in preparation for the new version
3550         of the sql storage API
3551
3552         * storage/DatabaseAuthorizer.cpp:
3553         (WebCore::DatabaseAuthorizer::allowTransaction):
3554         * storage/DatabaseAuthorizer.h:
3555
3556 2007-11-05  Mark Rowe  <mrowe@apple.com>
3557
3558         Reviewed by Alp Toker.
3559
3560         Have getMIMETypeForExtension return a null string when no MIME type is known
3561         for the extension rather than returning "text/plain".  This prevents plugin data
3562         being dumped into object elements when plugins are disabled.
3563
3564         * platform/gtk/MIMETypeRegistryGtk.cpp:
3565         (WebCore::MIMETypeRegistry::getMIMETypeForExtension):
3566
3567 2007-11-04  Sam Weinig  <sam@webkit.org>
3568
3569         Rubber-stamped by Adam Roben.
3570
3571         Rename SecurityOrigin::allowsAccessFrom to SecurityOrigin::canAccess to 
3572         clear up ambiguity.
3573
3574         * bindings/js/kjs_window.cpp:
3575         (KJS::Window::isSafeScript):
3576         * platform/SecurityOrigin.cpp:
3577         (WebCore::SecurityOrigin::canAccess):
3578         * platform/SecurityOrigin.h:
3579
3580 2007-11-04  Timothy Hatcher  <timothy@apple.com>
3581
3582         Reviewed by Adam.
3583
3584         Bug 15834: There are many subtle bugs in the Styles pane of the Web Inspector
3585         http://bugs.webkit.org/show_bug.cgi?id=15834
3586
3587         - Broke up DocumentPanel and added three SidebarPane sub-classes.
3588         - Fixed many Style pane bugs, including:
3589           * Poor handling of duplicate properties in the same rule. Some of this can't be
3590             fixed since we can't only get th