38bd01ef48ce25d348c64cbf0419d58ee6989162
[WebKit-https.git] / WebCore / ChangeLog
1 2007-11-29  Dan Bernstein  <mitz@apple.com>
2
3         Reviewed by Adam Roben and John Sullivan.
4
5         - make the recent searches popup extend only along the straight part of
6           the search field (unless it needs to be wider).
7
8         * platform/PopupMenuClient.h:
9           Added clientInsetLeft() and clientInsetRight() for clients to
10           specify desired horizontal insets for the menu.
11         * platform/win/PopupMenuWin.cpp:
12         (WebCore::PopupMenu::calculatePositionAndSize):
13         (WebCore::PopupMenu::paint):
14         * rendering/RenderMenuList.cpp:
15         (WebCore::RenderMenuList::clientInsetLeft): Added. Returns 0.
16         (WebCore::RenderMenuList::clientInsetRight): Ditto.
17         * rendering/RenderMenuList.h:
18         * rendering/RenderTextControl.cpp:
19         (WebCore::RenderTextControl::clientInsetLeft): Added. Returns half the
20         control's height, which is the radius of the cap on the left.
21         (WebCore::RenderTextControl::clientInsetRight): Added.
22         * rendering/RenderTextControl.h:
23
24 2007-11-30  Alp Toker  <alp@atoker.com>
25
26         Reviewed by Maciej.
27
28         http://bugs.webkit.org/show_bug.cgi?id=16173
29         Licensing change
30
31         Change license from BSD to LGPL.
32
33         This is being done to encourage vendors to contribute their fixes back
34         upstream.
35
36         * platform/graphics/gtk/ColorGtk.cpp:
37         * platform/graphics/gtk/IntPointGtk.cpp:
38         * platform/graphics/gtk/IntRectGtk.cpp:
39         * platform/graphics/svg/cairo/RenderPathCairo.cpp:
40         * platform/graphics/svg/cairo/SVGPaintServerCairo.cpp:
41         * platform/graphics/svg/cairo/SVGPaintServerGradientCairo.cpp:
42         * platform/graphics/svg/cairo/SVGPaintServerPatternCairo.cpp:
43         * platform/graphics/svg/cairo/SVGPaintServerSolidCairo.cpp:
44         * platform/graphics/svg/cairo/SVGResourceClipperCairo.cpp:
45         * platform/graphics/svg/cairo/SVGResourceMaskerCairo.cpp:
46         * platform/gtk/Language.cpp:
47         * platform/gtk/LoggingGtk.cpp:
48         * platform/gtk/SoundGtk.cpp:
49         * platform/gtk/SystemTimeGtk.cpp:
50         * platform/gtk/TextBreakIteratorInternalICUGtk.cpp:
51
52 2007-11-29  Darin Adler  <darin@apple.com>
53
54         Reviewed by Adele.
55
56         - fix http://bugs.webkit.org/show_bug.cgi?id=16191
57           REGRESSION: cannot tab to radio input after setting checked to false
58
59         Test: fast/forms/input-radio-checked-tab.html
60
61         * html/HTMLFormElement.cpp:
62         (WebCore::HTMLFormElement::CheckedRadioButtons::addButton): Fix this code
63         so that it doesn't call setChecked(false) until after the map has been updated.
64         Otherwise, we can end up deallocating the map before manipulating it. As long
65         as I was changing the function, I decided to make it do only a single hash
66         table lookup.
67
68         * html/HTMLInputElement.cpp: (WebCore::HTMLInputElement::setChecked):
69         Remove the button from the radio buttons set before changing the checked
70         state. This matches the idiom used elsewhere and fixes the problem where
71         setting checked to false would not remove it from the set.
72
73 2007-11-29  Justin Garcia  <justin.garcia@apple.com>
74
75         Reviewed by Darin Adler.
76
77         <rdar://problem/5620093> Brief hang when Safari caches page text of XML document
78
79         * editing/TextIterator.cpp:
80         (WebCore::TextIterator::representNodeOffsetZero): When we haven't been emitting any 
81         characters, shouldRepresentNodeOffsetZero() can create VisiblePositions, which is
82         expensive.  So, we perform the inexpensive checks on m_node to see if it necessitates 
83         emitting a character first and will early return before encountering 
84         shouldRepresentNodeOffsetZero()s worse case behavior.
85
86 2007-11-29  Anders Carlsson  <andersca@apple.com>
87
88         Reviewed by Sam.
89
90         Don't install event handlers or set the zoom cursor if auto-shrink has been disabled.
91
92         * loader/ImageDocument.cpp:
93         (WebCore::ImageDocument::createDocumentStructure):
94         (WebCore::ImageDocument::imageChanged):
95
96 2007-11-29  Beth Dakin  <bdakin@apple.com>
97
98         Reviewed by Geoff.
99
100         Fix for <rdar://problem/5620151> Disable JavaScript for SVG as 
101         image for <img> and CSS images
102
103         * platform/graphics/svg/SVGImage.cpp:
104         (WebCore::SVGImage::dataChanged): When we create the empty clients, 
105         explicitly disable JavaScript in the settings.
106
107 2007-11-29  Brady Eidson  <beidson@apple.com>
108
109         Reviewed by Anders
110
111         Support for <rdar://problem/5556381> and <rdar://problem/5556379>
112
113         The Database feature in the engine needs to support delegate calls for policy decisions and
114         also provide notifications when origins and databases change their state.
115
116         This patch also polishes off the missing features of the management API
117
118         * page/Chrome.cpp: Implement the two UIDelegate methods
119         (WebCore::Chrome::requestQuotaIncreaseForNewDatabase): Ask for more space to create a new database if it won't fit
120         (WebCore::Chrome::requestQuotaIncreaseForDatabaseOperation): Ask for more space to complete an in-progress operation
121         * page/Chrome.h:
122         * page/ChromeClient.h:
123         * platform/graphics/svg/SVGImageEmptyClients.h:
124         (WebCore::SVGEmptyChromeClient::requestQuotaIncreaseForNewDatabase):
125         (WebCore::SVGEmptyChromeClient::requestQuotaIncreaseForDatabaseOperation):
126
127         * storage/Database.cpp:
128         (WebCore::Database::openDatabase): Check to see if this database can be opened - the quota must be high 
129           enough and if it isn't, the UIDelegate should have a change to bump the quota.
130           Also update the UI-relevant details (display name and estimated size) upon successful opening of the database
131
132         * storage/DatabaseDetails.h: Remove the version parameter as it is a programatic detail of a
133           site database and is not important to API clients
134         (WebCore::DatabaseDetails::DatabaseDetails):
135         (WebCore::DatabaseDetails::isValid):
136         (WebCore::DatabaseDetails::name):
137
138         * storage/DatabaseTracker.cpp:
139         (WebCore::DatabaseTracker::openTrackerDatabase): Tweaked the schema here - there was a horrible bug with the old schema that would
140           prevent you from having two databases of the same name from two different origins.  Also simplify the origin-management schema
141         (WebCore::DatabaseTracker::canEstablishDatabase): Added.  Does some estimated size vs quota checks, and asks the UI delegate for 
142           more space if necessary
143         (WebCore::DatabaseTracker::hasEntryForOrigin):
144         (WebCore::DatabaseTracker::establishEntryForOrigin): Establishes a tracker entry for the given origin with the current default quota
145           Also notifies the client of the new origin
146         (WebCore::DatabaseTracker::setDatabaseDetails): Update the display name and estimated size for the given database
147         (WebCore::DatabaseTracker::fullPathForDatabase): Tweak to add the ability to get the path without creating it - for management purposes
148         (WebCore::DatabaseTracker::populateOrigins): Populate origins from the Origins table instead of the Databases table
149         (WebCore::DatabaseTracker::origins):
150         (WebCore::DatabaseTracker::detailsForNameAndOrigin): For API management
151         (WebCore::DatabaseTracker::usageForDatabase):
152         (WebCore::DatabaseTracker::usageForOrigin):
153         (WebCore::DatabaseTracker::quotaForOrigin):
154         (WebCore::DatabaseTracker::setQuota): Notify the client
155         (WebCore::DatabaseTracker::addDatabase): Notify the client 
156         (WebCore::DatabaseTracker::deleteAllDatabases):
157         (WebCore::DatabaseTracker::deleteDatabasesWithOrigin):
158         (WebCore::DatabaseTracker::deleteDatabase):
159         (WebCore::DatabaseTracker::deleteDatabaseFile):
160         * storage/DatabaseTracker.h:
161
162 2007-11-29  Dan Bernstein  <mitz@apple.com>
163
164         Reviewed by Beth Dakin and Darin Adler.
165
166         - manual test for <rdar://problem/5346394> Contextmenu event doesn't fire on body element inside frame
167
168         * manual-tests/context-click-unfocused-frame.html: Added.
169
170 2007-11-28  Antti Koivisto  <antti@apple.com>
171
172         Reviewed by Geoff.
173         
174         Fallback content inside media elements should not be rendered.
175
176         Test: media/fallback.html
177
178         * rendering/RenderMedia.h:
179         (WebCore::RenderMedia::canHaveChildren):
180
181 2007-11-28  Mark Rowe  <mrowe@apple.com>
182
183         Windows build fix.
184
185         * WebCore.vcproj/WebCore.vcproj:
186
187 2007-11-28  Mark Rowe  <mrowe@apple.com>
188
189         Gtk build fix.
190
191         * WebCore.pro:
192
193 2007-11-28  Antti Koivisto  <antti@apple.com>
194
195         Reviewed by Oliver.
196
197         Make QTMovieView fill color transparent. This behavior matches the specification
198         (and allows nice alpha blended video).
199
200         * platform/graphics/mac/MoviePrivateQTKit.mm:
201         (WebCore::MoviePrivate::createQTMovieView):
202
203 2007-11-28  Antti Koivisto  <antti@apple.com>
204
205         Reviewed by Darin.
206
207         Test: media/video-controls.html
208         
209         <rdar://problem/5605668>
210         Implement controls attribute for video element
211         
212         - Add RenderMedia and make RenderVideo its subclass. Controls code goes to RenderMedia while
213           video specific (painting etc) code stays in RenderVideo. For example audio controls can be implemented
214           later by just instantiating RenderMedia as renderer.
215         - Make media renderer hierarchy inherit from RenderBlock instead of RenderReplaced so it can 
216           have child nodes (for controls).
217         - Controls are implemented as a shadow DOM.
218         - Current look is a placeholder. It is defined purely in CSS.
219         - Some things like volume controls are not yet implemented.
220         - Fade-in/out is done manually, CSS animations don't work well in shadow trees.
221           
222         * WebCore.xcodeproj/project.pbxproj:
223         * css/html4.css:
224         * html/HTMLMediaElement.cpp:
225         (WebCore::HTMLMediaElement::attributeChanged):
226         (WebCore::HTMLMediaElement::updateMovie):
227         (WebCore::HTMLMediaElement::defaultEventHandler):
228         * html/HTMLMediaElement.h:
229         * rendering/RenderMedia.cpp: Added.
230         (WebCore::MediaControlShadowRootElement::MediaControlShadowRootElement):
231         (WebCore::MediaControlShadowRootElement::isShadowNode):
232         (WebCore::MediaControlShadowRootElement::shadowParentNode):
233         (WebCore::MediaControlInputElement::MediaControlInputElement):
234         (WebCore::MediaControlInputElement::attachToParent):
235         (WebCore::MediaControlPlayButtonElement::MediaControlPlayButtonElement):
236         (WebCore::MediaControlPlayButtonElement::inPausedState):
237         (WebCore::MediaControlPlayButtonElement::defaultEventHandler):
238         (WebCore::MediaControlPlayButtonElement::update):
239         (WebCore::MediaControlTimelineElement::MediaControlTimelineElement):
240         (WebCore::MediaControlTimelineElement::defaultEventHandler):
241         (WebCore::MediaControlTimelineElement::update):
242         (WebCore::RenderMedia::RenderMedia):
243         (WebCore::RenderMedia::~RenderMedia):
244         (WebCore::RenderMedia::mediaElement):
245         (WebCore::RenderMedia::movie):
246         (WebCore::RenderMedia::setStyle):
247         (WebCore::RenderMedia::createControlsShadowRoot):
248         (WebCore::RenderMedia::createPanel):
249         (WebCore::RenderMedia::createPlayButton):
250         (WebCore::RenderMedia::createTimeline):
251         (WebCore::RenderMedia::createTimeDisplay):
252         (WebCore::RenderMedia::updateFromElement):
253         (WebCore::RenderMedia::updateControls):
254         (WebCore::RenderMedia::timeUpdateTimerFired):
255         (WebCore::RenderMedia::updateTimeDisplay):
256         (WebCore::RenderMedia::updateControlVisibility):
257         (WebCore::RenderMedia::changeOpacity):
258         (WebCore::RenderMedia::opacityAnimationTimerFired):
259         (WebCore::RenderMedia::forwardEvent):
260         * rendering/RenderMedia.h: Added.
261         (WebCore::RenderMedia::renderName):
262         (WebCore::RenderMedia::isMedia):
263         (WebCore::RenderMedia::intrinsicSize):
264         * rendering/RenderObject.h:
265         (WebCore::RenderObject::isMedia):
266         * rendering/RenderVideo.cpp:
267         (WebCore::RenderVideo::RenderVideo):
268         (WebCore::RenderVideo::videoSizeChanged):
269         (WebCore::RenderVideo::paintObject):
270         (WebCore::RenderVideo::layout):
271         (WebCore::RenderVideo::updateFromElement):
272         (WebCore::RenderVideo::calcAspectRatioWidth):
273         (WebCore::RenderVideo::calcAspectRatioHeight):
274         * rendering/RenderVideo.h:
275
276 2007-11-28  Justin Garcia  <justin.garcia@apple.com>
277
278         Reviewed by Darin Adler.
279
280         <rdar://problem/5573879> GMail Beta: Crash in when undoing Remove Formating
281         
282         In the new beta, Google has added some custom code on top of our RemoveFormat
283         to work around a bug where fully selected lists aren't removed.  This code corrupts
284         the undo stack and causes crashes.  This change fixes two problems with RemoveFormat
285         so that Google doesn't have to have any custom code. After checking this in I'll 
286         work on bulletproofing the undo stack
287
288         * WebCore.xcodeproj/project.pbxproj: 
289         * editing/CompositeEditCommand.cpp:
290         (WebCore::CompositeEditCommand::insertLineBreak): Added this convenience method.
291         (WebCore::CompositeEditCommand::inputText): Added code to select all inserted text, not
292         just the last paragraph.  Added code to support an input string with '\n's.
293         * editing/CompositeEditCommand.h:
294         * editing/Editor.cpp:
295         (WebCore::Editor::removeFormattingAndStyle): Moved code to its own EditCommand.
296         * editing/RemoveFormatCommand.cpp: Added. Moved code from removeFormattingAndStyle here.
297         (WebCore::RemoveFormatCommand::RemoveFormatCommand):
298         (WebCore::RemoveFormatCommand::doApply): Added code to remove fully selected lists.
299         * editing/RemoveFormatCommand.h: Added.
300         (WebCore::RemoveFormatCommand::editingAction):
301
302 2007-11-28  Dan Bernstein  <mitz@apple.com>
303
304         Reviewed by Dave Hyatt.
305
306         - fix <rdar://problem/5612459> CrashTracer: [REGRESSION] 61 crashes in Safari at com.apple.WebCore: WebCore::AutoTableLayout::layout + 2046
307
308         Test: fast/table/empty-auto-column-zero-divide.html
309
310         * rendering/AutoTableLayout.cpp:
311         (WebCore::AutoTableLayout::recalcColumn):
312         (WebCore::AutoTableLayout::fullRecalc):
313         (WebCore::AutoTableLayout::calcEffectiveWidth):
314         (WebCore::AutoTableLayout::layout): When distributing the remaining
315         width among columns, skip those whose effective (rather than
316         specified) width is auto and contain only empty cells.
317
318 2007-11-28  Peter Kasting  <zerodpx@gmail.com>
319
320         Reviewed by Alp Toker.
321
322         http://bugs.webkit.org/show_bug.cgi?id=16169
323         GIF decoder needs to set hasAlpha() correctly on subsequent frames.
324         
325         This also removes the workaround for this problem in
326         ImageSourceCairo.cpp.
327
328         * platform/graphics/cairo/ImageSourceCairo.cpp:
329         (WebCore::ImageSource::frameHasAlphaAtIndex):
330         * platform/image-decoders/gif/GIFImageDecoder.cpp:
331         (WebCore::GIFImageDecoder::initFrameBuffer):
332
333 2007-11-28  Dan Bernstein  <mitz@apple.com>
334
335         Reviewed by Darin Adler and Adam Roben.
336
337         - <rdar://problem/5057218> Reenable "recent searches" search field menu when menu is fully implemented
338
339         * platform/win/SearchPopupMenuWin.cpp:
340         (WebCore::SearchPopupMenu::enabled): Changed to return true.
341         (WebCore::autosaveKey): Added. Returns a preferences key for the
342         autosave name by prefixing it with "com.apple.WebKit.searchField:".
343         (WebCore::SearchPopupMenu::saveRecentSearches): Implemented.
344         (WebCore::SearchPopupMenu::loadRecentSearches): Implemented.
345
346 2007-11-28  Alp Toker  <alp@atoker.com>
347
348         Reviewed by Mark Rowe.
349
350         http://bugs.webkit.org/show_bug.cgi?id=15689
351         [GTK] Background of loading images is always black
352
353         frameHasAlphaAtIndex() exists only to allow optimization for cases we
354         are certain the image can be blitted rather than composited.
355
356         Thus we need to be conservative, returning false only when we are
357         absolutely certain there is no need for composited copying, and true
358         otherwise.
359
360         CG doesn't even bother with this optimization at all and always
361         returns true.
362
363         Patch includes a workaround for
364           http://bugs.webkit.org/show_bug.cgi?id=16169
365           GIF ImageDecoder hasAlpha() return value incorrect
366
367         * platform/graphics/cairo/ImageSourceCairo.cpp:
368         (WebCore::ImageSource::frameHasAlphaAtIndex):
369
370 2007-11-27  Alp Toker  <alp@atoker.com>
371
372         Reviewed by Mark Rowe.
373
374         Install the JavaScriptCore headers as part of the GTK+ port.
375
376         * WebCore.pro:
377
378 2007-11-27  Beth Dakin  <bdakin@apple.com>
379
380         Reviewed by Oliver.
381
382         Fix for <rdar://problem/5616052> SVGs with width or height of 100% 
383         hang when used as a background-image (16164)
384
385         * platform/graphics/svg/SVGImage.cpp:
386         (WebCore::SVGImage::size): Use valueAsPercentage() for percents 
387         instead of valueInSpecifiedUnits(). valueInSpecifiedUnits() 
388         returns, for example, 50 for 50%, so multiplying percentages by the 
389         default size of 300 x 150 led to ridiculously huge dimensions for 
390         SVG images, and the subsequent hang. 
391
392 2007-11-27  Jon Honeycutt  <jhoneycutt@apple.com>
393
394         Reviewed by Adam.
395
396         Set haveRegisteredWindowClass when we register the window class.
397
398         * plugins/win/PluginViewWin.cpp:
399         (WebCore::registerPluginView):
400
401 2007-11-27  Timothy Hatcher  <timothy@apple.com>
402
403         Reviewed by Sam Weinig.
404
405         Bug 16165: Dragging the inspector toolbar should move the window
406         http://bugs.webkit.org/show_bug.cgi?id=16165
407
408         * page/inspector/DocumentPanel.js: Call the new drag functions, and cleanup code.
409         * page/inspector/inspector.css: Only make the toolbar transparent in detached mode.
410         * page/inspector/inspector.js: Call the new drag functions, and cleanup code. Add
411           toolbar drag functions that move the window.
412
413 2007-11-27  Antti Koivisto  <antti@apple.com>
414
415         Reviewed by Mitz.
416
417         Small changes to make RenderSlider a bit more generic so it can be used in video controls.
418
419         * html/HTMLInputElement.cpp:
420         (WebCore::HTMLInputElement::defaultEventHandler): Fix coordinates with forwarded events.
421         * rendering/RenderSlider.cpp:
422         (WebCore::HTMLSliderThumbElement::defaultEventHandler): Fix coordinates with forwarded events.
423         (WebCore::RenderSlider::setStyle):
424         (WebCore::RenderSlider::createThumbStyle): Copy thumb left and top from the orginal style so position does not reset.
425         (WebCore::RenderSlider::mouseEventIsInThumb): Make this work with forwarded events.
426         * rendering/RenderSlider.h:
427
428 2007-11-27  Antti Koivisto  <antti@apple.com>
429
430         Reviewed by Darin.
431
432         - Don't use hasPseudoId() optimization for pseudo styles used in shadow trees. These styles
433           generally exist when asked for so the optimization does not do much. This reverses the continuing
434           growth of the _pseudoBits bitfield in RenderStyle.
435         - Add some pseudo elements for media controls
436
437         * css/CSSSelector.cpp:
438         (WebCore::CSSSelector::extractPseudoType):
439         * css/CSSSelector.h:
440         (WebCore::CSSSelector::):
441         * css/CSSStyleSelector.cpp:
442         (WebCore::CSSStyleSelector::matchRulesForList):
443         (WebCore::CSSStyleSelector::checkOneSelector):
444         * rendering/RenderObject.cpp:
445         (WebCore::RenderObject::getPseudoStyle):
446         * rendering/RenderStyle.cpp:
447         (WebCore::pseudoBit):
448         (WebCore::RenderStyle::hasPseudoStyle):
449         (WebCore::RenderStyle::setHasPseudoStyle):
450         * rendering/RenderStyle.h:
451         (WebCore::RenderStyle::):
452
453 2007-11-27  Timothy Hatcher  <timothy@apple.com>
454
455         Reviewed by Kevin McCullough.
456
457         Bug 16161: window.moveBy(0, 0) moves the window by -22px vertically
458         http://bugs.webkit.org/show_bug.cgi?id=16161
459
460         Removed the "Adjust the window rect to be in the coordinate space of
461         the screen rect" step which was always adding (0,22) to the window
462         position (on the main screen). Instead, account for screen X and Y
463         in the bottom and right constrain step.
464
465         Added more test cases to: fast/dom/Window/window-resize.html
466
467         * bindings/js/kjs_window.cpp:
468         (KJS::adjustWindowRect):
469
470 2007-11-27  Timothy Hatcher  <timothy@apple.com>
471
472         Reviewed by Adam Roben.
473
474         * page/inspector/inspector.css: Make the text in the Network
475         panel legend more readable.
476
477 2007-11-27  Timothy Hatcher  <timothy@apple.com>
478
479         Reviewed by Adam Roben.
480
481         Don't call setNeedsReapplyStylesInAllFrames if the
482         authorAndUserStylesEnabled setting didn't change.
483
484         * page/Settings.cpp:
485         (WebCore::Settings::setAuthorAndUserStylesEnabled):
486
487 2007-11-27  Alp Toker  <alp@atoker.com>
488
489         Fix potential broken build due to a missing DEPENDPATH.
490
491         * WebCore.pro:
492
493 2007-11-26  Timothy Hatcher  <timothy@apple.com>
494
495         Reviewed by Dave Hyatt.
496
497         <rdar://problem/5569233> Add the ability to disable author and user CSS styles
498
499         * WebCore.base.exp: Add the Settings::setAuthorAndUserStylesEnabled symbol.
500         * css/CSSStyleSelector.cpp:
501         (WebCore::CSSStyleSelector::CSSStyleSelector): Add a new matchAuthorAndUserStyles parameter.
502         (WebCore::CSSStyleSelector::styleForElement): Check m_matchAuthorAndUserStyles before
503         matching user and author rules.
504         (WebCore::CSSStyleSelector::pseudoStyleForElement): Ditto.
505         (WebCore::CSSStyleSelector::styleRulesForElement): Ditto.
506         * css/CSSStyleSelector.h: Add m_matchAuthorAndUserStyles and new constructor parameter.
507         * dom/Document.cpp:
508         (WebCore::Document::Document): Pass Settings::authorAndUserStylesEnabled to the CSSStyleSelector.
509         (WebCore::Document::recalcStyleSelector): Skip collecting the author stylesheets if
510         Settings::authorAndUserStylesEnabled is false, and pass that to the CSSStyleSelector.
511         * page/Settings.cpp:
512         (WebCore::Settings::Settings): Initialize m_authorAndUserStylesEnabled to true.
513         (WebCore::Settings::setAuthorAndUserStylesEnabled): Recalc style in all the frames
514         when the setting changes.
515         * page/Settings.h: Add m_authorAndUserStylesEnabled.
516         (WebCore::Settings::authorAndUserStylesEnabled): Return m_authorAndUserStylesEnabled.
517
518 2007-11-27  Alp Toker  <alp@atoker.com>
519
520         Reviewed by Mark Rowe.
521
522         Based on changes by Mike Emmel.
523
524         CURL HTTP backend local file fixes:
525
526         Set a MIME type for local files based on the file extension.
527
528         Remove any HTTP query part sent to a local file.
529
530         * platform/network/curl/ResourceHandleManager.cpp:
531         (WebCore::ResourceHandleManager::startJob):
532
533 2007-11-26  Brady Eidson  <beidson@apple.com>
534
535         Reviewed by Mark Rowe
536
537         Allow setting the default storage quota per database origin
538
539         * WebCore.base.exp:
540
541         * page/Settings.cpp:
542         (WebCore::Settings::setDefaultDatabaseOriginQuota):
543         (WebCore::Settings::defaultDatabaseOriginQuota):
544         * page/Settings.h:
545
546         * storage/DatabaseTracker.cpp:
547         (WebCore::DatabaseTracker::DatabaseTracker):
548         (WebCore::DatabaseTracker::setDefaultOriginQuota):
549         (WebCore::DatabaseTracker::defaultOriginQuota):
550         * storage/DatabaseTracker.h:
551
552 2007-11-26  Peter Kasting  <zerodpx@gmail.com>
553
554         Reviewed by Alp Toker.
555
556         http://bugs.webkit.org/show_bug.cgi?id=15974
557         GIF decoding should respect frames' specified disposal methods.
558
559         * platform/image-decoders/ImageDecoder.h:
560         (WebCore::RGBA32Buffer::):
561         (WebCore::RGBA32Buffer::RGBA32Buffer):
562         (WebCore::RGBA32Buffer::disposalMethod):
563         (WebCore::RGBA32Buffer::setDisposalMethod):
564         * platform/image-decoders/gif/GIFImageDecoder.cpp:
565         (WebCore::GIFImageDecoder::frameBufferAtIndex):
566         (WebCore::GIFImageDecoder::initFrameBuffer):
567         (WebCore::GIFImageDecoder::prepEmptyFrameBuffer):
568         (WebCore::GIFImageDecoder::haveDecodedRow):
569         (WebCore::GIFImageDecoder::frameComplete):
570         * platform/image-decoders/gif/GIFImageDecoder.h:
571         * platform/image-decoders/gif/GIFImageReader.cpp:
572         (GIFImageReader::read):
573         * platform/image-decoders/gif/GIFImageReader.h:
574         (GIFFrameReader::GIFFrameReader):
575
576 2007-11-26  Adam Roben  <aroben@apple.com>
577
578         Add a Color(CGColorRef) constructor
579
580         Reviewed by Darin.
581
582         * platform/graphics/Color.h:
583         * platform/graphics/cg/ColorCG.cpp:
584         (WebCore::Color::Color): Added.
585
586 2007-11-26  Adele Peterson  <adele@apple.com>
587
588         Reviewed by Darin.
589
590         Update to last change.  Moved addPendingSheet call to within nil check for m_cachedSheet.
591
592         * page/Frame.cpp:
593         (WebCore::UserStyleSheetLoader::UserStyleSheetLoader):
594
595 2007-11-26  Adele Peterson  <adele@apple.com>
596
597         Reviewed by Darin.
598
599         Fix for <rdar://problem/5591583> CrashTracer: [USER] 157 in Mail crashes at -[WebCoreFrameBridge reapplyStylesForDeviceType:]
600
601         * page/Frame.cpp: Add nil checks since every other caller of requestCSSStyleSheet checks for nil.
602         (WebCore::UserStyleSheetLoader::UserStyleSheetLoader):
603         (WebCore::UserStyleSheetLoader::~UserStyleSheetLoader):
604
605 2007-11-26  Mark Rowe  <mrowe@apple.com>
606
607         GCC 4.2 build fix.
608
609         * xml/XSLTUnicodeSort.cpp: Add another WTF_ATTRIBUTE_PRINTF.
610
611 2007-11-26  Feng Qian <ian.eng.webkit@gmail.com>
612
613         Reviewed and touched up by Sam Weinig.
614
615         Fix for http://bugs.webkit.org/show_bug.cgi?id=16073
616
617         Test: http/tests/security/xss-DENIED-invalid-domain-change.html
618
619         * dom/Document.cpp:
620         (WebCore::Document::setDomain): Don't set the securityOrigin policy unless
621         the set succeeds.  Adds some early returns as well.
622
623 2007-11-26  Steve Falkenburg  <sfalken@apple.com>
624
625         Build fix.
626
627         * WebCore.vcproj/WebCore.make:
628         * WebCore.vcproj/migrate-idls.sh:
629
630 2007-11-26  Sam Weinig  <sam@webkit.org>
631
632         Fix potential null-dereference.
633
634         Reviewed by Adam Roben.
635
636         * page/FrameTree.cpp:
637         (WebCore::FrameTree::isDescendantOf):
638
639 2007-11-26  Sam Weinig  <sam@webkit.org>
640
641         Reviewed by Darin.
642
643         Fix for <rdar://problem/5592988>
644         - Enforce tighter restrictions on what frames in other domains
645           can be navigated.
646
647         Tests: http/tests/security/frameNavigation/xss-ALLOWED-parent-navigation-change.html
648                http/tests/security/frameNavigation/xss-ALLOWED-targeted-subframe-navigation-change.html
649
650         * bindings/js/kjs_window.cpp:
651         (KJS::Window::put):
652         (KJS::Location::put):
653         (KJS::LocationProtoFuncReplace::callAsFunction):
654         (KJS::LocationProtoFuncAssign::callAsFunction):
655         * loader/FrameLoader.cpp:
656         (WebCore::FrameLoader::createWindow):
657         (WebCore::FrameLoader::load):
658         (WebCore::FrameLoader::shouldAllowNavigation): Move and update logic from canTarget().
659         * loader/FrameLoader.h:
660         * page/FrameTree.cpp:
661         (WebCore::FrameTree::isDescendantOf): Make this O(1) in the case when both frames are not
662         in the same page.
663
664 2007-11-26  Steve Falkenburg  <sfalken@apple.com>
665
666         Build fix.
667
668         * WebCore.vcproj/migrate-idls.sh:
669
670 2007-11-26  Dan Bernstein  <mitz@apple.com>
671
672         Reviewed by Dave Hyatt.
673
674         - fix <rdar://problem/5609337> Making a float shorter does not remove it from the floating object list of a nested block it intruded into
675
676         Test: fast/dynamic/float-withdrawal-2.html
677
678         * rendering/RenderBlock.cpp:
679         (WebCore::RenderBlock::layoutBlockChildren): When a float may have
680         been withdrawn from a child, mark all descendants if necessary and not
681         just the child.
682
683 2007-11-26  Steve Falkenburg  <sfalken@apple.com>
684
685         Build fix.
686
687         * WebCore.vcproj/MigrateIDLAndScripts: Copied from WebCore.vcproj/MigrateIDLAndScripts.make.
688         * WebCore.vcproj/MigrateIDLAndScripts.make: Removed.
689         * WebCore.vcproj/migrate-idls.sh:
690
691 2007-11-26  Brady Eidson  <beidson@apple.com>
692
693         Reviewed by Anders (and typo lovingly found by Adam)
694
695         Change Databases to be stored in a per-origin directory hierarchy - this will make
696         storage quotas much easier to enforce
697
698         * platform/SecurityOriginData.cpp:
699         (WebCore::SecurityOriginData::SecurityOriginData): Parse string based on '_' instead of ':'
700         (WebCore::SecurityOriginData::stringIdentifier): Change to use '_' as a separator instead of ':'.  
701           '_' still works due to not being allowed in domain names, but also is a valid filename character '
702           on all filesystems we care about
703
704         * storage/DatabaseTracker.cpp:
705         (WebCore::DatabaseTracker::fullPathForDatabase): Create a per-origin directory hierarchy to categorize
706           databases by origin
707
708 2007-11-26  Timothy Hatcher  <timothy@apple.com>
709
710         Reviewed by Adam Roben.
711
712         Bug 16137: Web Inspector window on Leopard should have a unified toolbar and window title
713         http://bugs.webkit.org/show_bug.cgi?id=16137
714
715         On Leopard the toolbar background will be transparent, to allow the
716         window background to show through the transparent WebView. The 
717         search results divs needed to move inside the "main" div, so they
718         would be clipped and not show where the toolbar is.
719
720         * page/InspectorController.cpp:
721         (WebCore::platform): Return a string for which platform we are.
722         (WebCore::InspectorController::windowScriptObjectAvailable):
723         Define the platform function on the JavaScript class.
724         * page/inspector/Panel.js: Add panels to the panels div.
725         * page/inspector/inspector.css: On the Leopard platform make
726         the toolbar background transparent so the window background shows.
727         * page/inspector/inspector.html: Add a panels div and move search
728         result divs inside the main div.
729         * page/inspector/inspector.js: Tweak the resize code to acount for
730         the search results divs moving inside the main div.
731
732 2007-11-25  Rodney Dawes  <dobey@wayofthemonkey.com>
733
734         Reviewed by Maciej Stachowiak.
735
736         Remove the unneeded CFNETWORK #ifdefs.
737
738         * loader/NetscapePlugInStreamLoader.h:
739
740 2007-11-24  Laszlo Gombos  <laszlo.gombos@gmail.com>
741
742         Reviewed by Sam Weinig.
743
744         Add printf format attribute to several functions. Use the the new WTF_ATTRIBUTE_PRINTF define.
745
746         * dom/XMLTokenizer.cpp:
747         * dom/XMLTokenizer.h:
748         * platform/DeprecatedString.h:
749         * platform/PlatformString.h:
750
751 2007-11-25  Dan Bernstein  <mitz@apple.com>
752
753         Reviewed by Adam Roben.
754
755         - fix off-center error images
756
757         Covered by many pixel tests with missing images
758
759         * rendering/RenderImage.cpp:
760         (WebCore::RenderImage::paint): Account for the 1 pixel outline when
761         positioning the error image.
762
763 2007-11-25  Kevin Ollivier  <kevino@theolliviers.com>
764
765         wx build fix. Fix filename case for case-sensitive filesystems.
766
767         * WebCoreSources.bkl:
768
769 2007-11-22  Nikolas Zimmermann  <zimmermann@kde.org>
770
771         Reviewed by Adam Roben.
772
773         Fixes: http://bugs.webkit.org/show_bug.cgi?id=15564
774
775         Fix problems with hidden glyphs. They were taken into account for quite
776         some operations (hit testing, length calulcations etc..) except painting.
777         Especially fixes boundaries of <textPath> (see using Web Inspector) if
778         text-anchor isn't equal to 'start'.
779
780         Added testcase:
781         svg/text/textPathBoundsBug.svg
782
783         Fixed testcase: (all showed text selection problems on text paths)
784         svg/batik/text/textGlyphOrientationHorizontal.svg
785         svg/batik/text/textOnPath.svg
786         svg/batik/text/textOnPath3.svg
787         svg/batik/text/verticalTextOnPath.svg
788         svg/text/text-align-04-b.svg
789         svg/W3C-SVG-1.1/text-align-04-b.svg
790
791         * rendering/SVGCharacterLayoutInfo.cpp:
792         (WebCore::SVGChar::isHidden):
793         * rendering/SVGCharacterLayoutInfo.h:
794         (WebCore::SVGCharOnPath::SVGCharOnPath):
795         * rendering/SVGInlineTextBox.cpp:
796         (WebCore::SVGInlineTextBoxClosestCharacterToPositionWalker::chunkPortionCallback):
797         (WebCore::SVGInlineTextBoxSelectionRectWalker::chunkPortionCallback):
798         * rendering/SVGRootInlineBox.cpp:
799         (WebCore::topLeftPositionOfCharacterRange):
800         (WebCore::SVGRootInlineBoxPaintWalker::chunkPortionCallback):
801         (WebCore::cummulatedWidthOrHeightOfTextChunk):
802         (WebCore::applyTextAnchorToTextChunk):
803         (WebCore::applyTextLengthCorrectionToTextChunk):
804         (WebCore::SVGRootInlineBox::layoutInlineBoxes):
805         (WebCore::SVGRootInlineBox::buildLayoutInformationForTextBox):
806         (WebCore::SVGRootInlineBox::buildTextChunks):
807
808 2007-11-25  Alexey Proskuryakov  <ap@webkit.org>
809
810         Reviewed by Maciej.
811
812         http://bugs.webkit.org/show_bug.cgi?id=15919
813         XSLTProcessor.transformToFragment creates an extra not defined TEXT_NODE at the end
814
815         Test: fast/xsl/extra-lf-at-end.html
816
817         * xml/XSLTProcessor.cpp:
818         (WebCore::writeToVector): Changed to use Vector to avoid slow String::apend().
819         (WebCore::saveResultToString): Remove trailing line feed if present.
820
821 2007-11-24  Mark Rowe  <mrowe@apple.com>
822
823         Reviewed by Tim Hatcher.
824
825         Fix <rdar://problem/5432686> 333MB RPRVT seems to leak @ www.43folders.com (1hr plug-in stream).
826         http://bugs.webkit.org/show_bug.cgi?id=13705
827
828         Don't buffer the entire stream contents in memory in the ResourceLoader.
829
830         * loader/mac/NetscapePlugInStreamLoaderMac.mm:
831         (WebCore::NetscapePlugInStreamLoader::NetscapePlugInStreamLoader):
832         (WebCore::NetscapePlugInStreamLoader::didFinishLoading):
833         * loader/mac/WebPlugInStreamLoaderDelegate.h:
834
835 2007-11-23  Adam Roben  <aroben@apple.com>
836
837         Get rid of WebCoreSystemInterface on Windows
838
839         The one function defined in that file is now in WebKitSystemInterface.
840
841         Reviewed by Tim.
842
843         * WebCore.vcproj/WebCore.vcproj: Removed
844         WebCoreSystemInterface.{cpp,h}.
845         * platform/graphics/cg/ImageCG.cpp: Made #include of
846         WebCoreSystemInterface.h Mac-only.
847         * platform/win/GraphicsContextWin.cpp: Ditto.
848         * platform/win/WebCoreSystemInterface.cpp: Removed.
849         * platform/win/WebCoreSystemInterface.h: Removed.
850
851 2007-11-24  Adam Roben  <aroben@apple.com>
852
853         Replace uses of %@ with %s in the inspector
854
855         Rubberstamped by Tim.
856
857         * English.lproj/InspectorLocalizedStrings.js: Changed %@ to %s.
858         * page/inspector/DatabasePanel.js: Ditto.
859         * page/inspector/StylesSidebarPane.js: Ditto.
860         * page/inspector/inspector.js: Ditto.
861         * page/inspector/utilities.js:
862         (String.vsprintf): Removed @ as a format specifier.
863
864 2007-11-24  Adam Roben  <aroben@apple.com>
865
866         Windows build fix
867
868         Turn off the change made in r27984 on Windows for now.
869
870         * xml/XSLTProcessor.cpp:
871         (WebCore::XSLTProcessor::transformToString):
872         * xml/XSLTUnicodeSort.cpp:
873
874 2007-11-24  Timothy Hatcher  <timothy@apple.com>
875
876         Reviewed by Adam Roben.
877
878         Bug 16121: Web Inspector needs helper functions that pass a 'this' object to
879         addEventListener and setTimeout
880         http://bugs.webkit.org/show_bug.cgi?id=16121
881
882         Add Function.prototype.bind. This helper will return a wrapper function
883         that will call the original function with the supplied arguments
884         and using the supplied 'this' object.
885
886         * page/inspector/Database.js: Remove a use of setTimeout by
887           inheriting some common functions from Resource.
888         * page/inspector/DatabasePanel.js: Use the new bind function.
889         * page/inspector/ConsolePanel.js: Ditto.
890         * page/inspector/DocumentPanel.js: Ditto.
891         * page/inspector/NetworkPanel.js: Ditto.
892         * page/inspector/PropertiesSection.js: Ditto.
893         * page/inspector/Resource.js: Ditto.
894         * page/inspector/SidebarPane.js: Ditto.
895         * page/inspector/inspector.html: Moved Database.js after Resource.js,
896           now that Database.js uses it.
897         * page/inspector/inspector.js: Use the new bind function. Also
898           removed a setTimeout used for the localized strings code. There is
899           now a load event listener added to the localized strings script
900           element that will call WebInspector.loaded.
901         * page/inspector/utilities.js: Add Function.prototype.bind.
902
903 2007-11-24  Timothy Hatcher  <timothy@apple.com>
904
905         Reviewed by Adam Roben.
906
907         Bug 16112: Some Web Inspector UI elements use offsetWidth and offsetHeight before the stylesheet loads
908         http://bugs.webkit.org/show_bug.cgi?id=16112
909
910         In the places where we use offsetWidth and offsetHeight before
911         the stylesheet loads there is now a check. If the body's
912         offsetWidth is not greater than zero, then set a timeout
913         to do the updates requiring the stylesheet later.
914
915         The three places this happened:
916         - DOM tree selection highlight would show up at the wrong height
917           when using Inspect Element to open the inspector.
918         - DOM tree breadcrumbs would not collapse when using Inspect Element
919           to open the inspector.
920         - Network Timeline divider lines would not show when opening directly
921           into the timeline.
922
923         * page/inspector/DocumentPanel.js: Check if the stylesheet loaded.
924         * page/inspector/NetworkPanel.js: Ditto.
925         * page/inspector/inspector.html: Include the stylesheet before
926           any scripts, this will help get it loaded sooner.
927
928 2007-11-24  Kevin Ollivier  <kevino@theolliviers.com>
929
930         Add wx implementation for pathGetFilename
931
932         Reviewed by David D. Kilzer.
933
934         * html/HTMLFormElement.cpp:
935         (WebCore::pathGetFilename):
936
937 2007-11-23  Timothy Hatcher  <timothy@apple.com>
938
939         Reviewed by Adam Roben.
940
941         Bug 16110: Clicking inside the resource headers in the network timeline collapses them
942         http://bugs.webkit.org/show_bug.cgi?id=16110
943
944         Toggle the resource headers only if the click happens on the
945         resource row, not within the headers area.
946
947         * WebCore.xcodeproj/project.pbxproj:
948         * page/inspector/NetworkPanel.js:
949
950 2007-11-23  Kevin Ollivier  <kevino@theolliviers.com>
951
952         Win build fixes. CURL needs winsock, so don't disable it, and
953         include pthreads.h to get the threadsafe *_r functions.
954
955         Reviewed by Adam Roben.
956
957         * config.h:
958         * loader/FTPDirectoryDocument.cpp:
959         * loader/FTPDirectoryParser.cpp:
960
961 2007-11-23  Kevin Ollivier  <kevino@theolliviers.com>
962
963         wx build fix. Move wx settings to project build settings,
964         remove some old settings that were masking a build problem,
965         and fix include ordering to ensure proper config.h and
966         unicode/utf8.h headers are used. 
967
968         * webcore-base.bkl:
969         * webcore-wx.bkl:
970
971 2007-11-23  Simon Hausmann  <hausmann@webkit.org>
972
973         Reviewed by George Staikos <staikos@kde.org>.
974
975         Another build fix specific to trunk (instead of the stable branch) to fix make clean (which the buildbots call).
976
977         * WebCore.pro:
978
979 2007-11-23  Alexey Proskuryakov  <ap@webkit.org>
980
981         Not reviewed, trivial leak fix.
982
983         Fix xsltUnicodeSortFunction() memory leaks.
984
985         * xml/XSLTUnicodeSort.cpp:
986         (WebCore::xsltUnicodeSortFunction):
987
988 2007-11-23  Alexey Proskuryakov  <ap@webkit.org>
989
990         Reviewed by Maciej.
991
992         <rdar://problem/5539306> REGRESSION: redirect fails when subframe's document is opened but
993         not closed (affects digg.com)
994
995         Tests: fast/loader/meta-refresh-vs-open.html
996                fast/loader/redirect-with-open-subframe-2.html
997                fast/loader/redirect-with-open-subframe.html
998                http/tests/loading/onload-vs-immediate-refresh.pl
999
1000         * loader/FrameLoader.cpp:
1001         (WebCore::FrameLoader::scheduleRedirection): Only check whether the load is complete for
1002         HTTP redirects - JavaScript-initiated ones are effective immediately.
1003
1004 2007-11-23  Dan Bernstein  <mitz@apple.com>
1005
1006         Reviewed by Alexey Proskuryakov.
1007
1008         - apply matrix transforms on the correct side of the transformation
1009           matrix (not on the side where the vector is multiplied).
1010
1011         Test: fast/transforms/matrix-02.html
1012
1013         * rendering/RenderStyle.h:
1014         (WebCore::MatrixTransformOperation::apply):
1015
1016 2007-11-23  Alexey Proskuryakov  <ap@webkit.org>
1017
1018         Reviewed by Maciej.
1019
1020         http://bugs.webkit.org/show_bug.cgi?id=16077
1021         <rdar://problem/5609785> XSLT processor <xsl:sort> algorithm is incompatible with other
1022         browser implementations
1023
1024         Test: fast/xsl/sort-unicode.xml
1025
1026         * xml/XSLTProcessor.cpp:
1027         (WebCore::XSLTProcessor::transformToString): Set a custom sort function.
1028
1029         * xml/XSLTUnicodeSort.cpp: Added.
1030         (init_xsltTransformError):
1031         (xsltTransformError):
1032         (WebCore::xsltUnicodeSortFunction):
1033         * xml/XSLTUnicodeSort.h: Added.
1034         ICU-based implementation of xsl:sort, using an example from libxslt distribution.
1035         Only minimal coding style fixes to ease synchronization with upstream in the future.
1036
1037         * icu/unicode/ucol.h: Added.
1038         * icu/unicode/uset.h: Added.
1039         Taken from ICU 3.2
1040
1041         * WebCore.pro:
1042         * WebCore.vcproj/WebCore.vcproj:
1043         * WebCore.xcodeproj/project.pbxproj:
1044         * WebCoreSources.bkl:
1045         Added XSLTUnicodeSort.cpp.
1046
1047 2007-11-22  Alexey Proskuryakov  <ap@webkit.org>
1048
1049         Reviewed by Maciej.
1050
1051         http://bugs.webkit.org/show_bug.cgi?id=14977
1052         Hixie's DOM Core performance test shows insert >10x slower than append
1053
1054         Each invocation of Element.childNodes[n] was creating and registering a new ChildNodeList,
1055         which persisted and listened to notifications until GC.
1056
1057         A fix is to avoid registering child node lists for notifications - they don't need them, as
1058         they share a common cache in Node.
1059
1060         * dom/Node.cpp:
1061         (WebCore::Node::registerNodeList):
1062         (WebCore::Node::unregisterNodeList):
1063         (WebCore::Node::notifyLocalNodeListsAttributeChanged):
1064         (WebCore::Node::notifyLocalNodeListsChildrenChanged):
1065         * dom/NodeList.h:
1066         (WebCore::NodeList::needsNotifications):
1067
1068 2007-11-22  Dan Bernstein  <mitz@apple.com>
1069
1070         Reviewed by Antti Koivisto.
1071
1072         - fix http://bugs.webkit.org/show_bug.cgi?id=15811
1073           WebKit plug-ins can re-enter WebKit under attach()
1074           <rdar://problem/5577978>
1075
1076         Defer plug-in loading until after attach and recalcStyle using the
1077         post-attach callback mechanism. Netscape plug-ins are still loaded only
1078         after layout.
1079
1080         * dom/ContainerNode.cpp:
1081         Made NodeCallbackQueue elements retain the Node because callbacks might
1082         delete nodes that are in the callback queue.
1083         (WebCore::ContainerNode::suspendPostAttachCallbacks): Added. Needed to
1084         prevent post-attach callbacks from being dispatched under recalcStyle().
1085         (WebCore::ContainerNode::resumePostAttachCallbacks): Ditto.
1086         (WebCore::ContainerNode::dispatchPostAttachCallbacks): Factored out from
1087         attach().
1088         (WebCore::ContainerNode::attach):
1089         * dom/ContainerNode.h:
1090         * dom/Document.cpp:
1091         (WebCore::Document::recalcStyle): Added calls to
1092         suspendPostAttachCallbacks() and resumePostAttachCallbacks().
1093         * html/HTMLEmbedElement.cpp:
1094         (WebCore::HTMLEmbedElement::HTMLEmbedElement):
1095         (WebCore::HTMLEmbedElement::attach): Changed to queue the widget update
1096         for post-attach.
1097         (WebCore::HTMLEmbedElement::updateWidget): Added. Called by the
1098         post-attach callback.
1099         * html/HTMLEmbedElement.h: Added an m_needWidgetUpdate member needed to
1100         prevent a double update if another plug-in's post-attach updateWidget()
1101         triggers a layout which updates the widget before this plug-in's
1102         post-attach callback is invoked.
1103         (WebCore::HTMLEmbedElement::setNeedWidgetUpdate): Added a setter for
1104         m_needWidgetUpdate.
1105         * html/HTMLObjectElement.cpp:
1106         (WebCore::HTMLObjectElement::attach): Changed to queue the widget update
1107         for post-attach.
1108         (WebCore::HTMLObjectElement::updateWidget): Added. Called by the
1109         post-attach callback.
1110         * html/HTMLObjectElement.h:
1111         (WebCore::HTMLObjectElement::setNeedWidgetUpdate): Added a setter for
1112         m_needWidgetUpdate.
1113         * html/HTMLPlugInElement.cpp:
1114         (WebCore::HTMLPlugInElement::updateWidgetCallback): Added.
1115         * html/HTMLPlugInElement.h:
1116         (WebCore::HTMLPlugInElement::updateWidget):
1117         * rendering/RenderPartObject.cpp:
1118         (WebCore::RenderPartObject::updateWidget): Added calls to
1119         setNeedWidgetUpdate(false) so that if this method is called from
1120         FrameView::layout() during post-attach dispatch of another plug-in,
1121         it will not be called again when this plug-in's post-attach callback
1122         is dispatched.
1123         * rendering/RenderPartObject.h:
1124         (WebCore::RenderPartObject::updateWidget) Renamed argument to match
1125         the method definition.
1126
1127 2007-11-22  Timothy Hatcher  <timothy@apple.com>
1128
1129         Reviewed by Dan Bernstein.
1130
1131         Fix the Element.hasStyleClass and Element.removeStyleClass helpers
1132         to not find and replace substrings, but whole class names at the
1133         beginning or end of the string or surrounded by whitespace.
1134
1135         * page/inspector/utilities.js:
1136
1137 2007-11-22  Timothy Hatcher  <timothy@apple.com>
1138
1139         Revert part of my r27935 change that made the Tip balloons
1140         animate with CSS transitions. The balloon was only opacity 0,
1141         so it would cause its row to highlight when hovering over
1142         another row.
1143
1144         * page/inspector/NetworkPanel.js:
1145         * page/inspector/inspector.css:
1146
1147 2007-11-22  Dan Bernstein  <mitz@apple.com>
1148
1149         Reviewed by Maciej Stachowiak.
1150
1151         - fix http://bugs.webkit.org/show_bug.cgi?id=15943
1152           -webkit-transform matrix does not work
1153
1154         Test: fast/transforms/matrix-01.html
1155
1156         Parse all six matrix entries as numbers.
1157
1158         * css/CSSParser.cpp:
1159         (WebCore::TransformOperationInfo::TransformOperationInfo):
1160         (WebCore::CSSParser::parseTransform):
1161         * css/CSSStyleSelector.cpp:
1162         (WebCore::CSSStyleSelector::applyProperty):
1163         * rendering/RenderStyle.cpp:
1164         (WebCore::MatrixTransformOperation::blend):
1165         * rendering/RenderStyle.h:
1166         (WebCore::MatrixTransformOperation::MatrixTransformOperation):
1167         (WebCore::MatrixTransformOperation::apply):
1168
1169 2007-11-22  Laszlo Gombos  <laszlo.gombos@gmail.com>
1170
1171         Reviewed by Alp Toker.
1172
1173         Fix some compilation warnings.  Do not reference undefined (platform) specific type (WebCore::CachedFont::m_fontData)
1174
1175         * loader/CachedFont.cpp:
1176         (WebCore::CachedFont::~CachedFont):
1177         (WebCore::CachedFont::allReferencesRemoved):
1178
1179 2007-11-22  Alp Toker  <alp@atoker.com>
1180
1181         Reviewed by Mark Rowe.
1182
1183         GTK+ drawing fix.
1184
1185         Add a check to avoid crashing when the GraphicsContext is not
1186         associated with a GdkEventExpose. This was noticed when adding
1187         printing support but might be triggered in other situations too.
1188
1189         * platform/gtk/WidgetGtk.cpp:
1190         (WebCore::Widget::paint):
1191
1192 2007-11-22  Julien Chaffraix  <julien.chaffraix@gmail.com>
1193
1194         Reviewed by Alexey.
1195
1196         Bug 15530: XMLHttpRequest should not support certain methods
1197
1198         Test: http/tests/xmlhttprequest/xmlhttprequest-forbidden-methods-exception.html
1199
1200         * xml/XMLHttpRequest.cpp:
1201         (WebCore::XMLHttpRequest::open):
1202
1203 2007-11-22  Simon Hausmann  <hausmann@kde.org>
1204
1205         Reviewed by George.
1206
1207         For the build inside Qt include qbase.pri and don't duplicate what qbase.pri otherwise does (install targets, etc.)
1208
1209         * WebCore.pro:
1210
1211 2007-11-22  Simon Hausmann  <hausmann@kde.org>
1212
1213         Reviewed by George.
1214
1215         Don't set OBJECTS_DIR when building inside Qt
1216
1217         * WebCore.pro:
1218
1219 2007-11-22  Simon Hausmann  <hausmann@kde.org>
1220
1221         Reviewed by George.
1222
1223         Use ../generated as path for the generated sources for builds inside Qt
1224
1225         * WebCore.pro:
1226
1227 2007-11-22  Simon Hausmann  <hausmann@kde.org>
1228
1229         Reviewed by George.
1230
1231         Make the directory of where to put the generated sources configurable through the GENERATED_SOURCE_DIR variable
1232
1233         * WebCore.pro:
1234
1235 2007-11-22  Simon Hausmann  <hausmann@kde.org>
1236
1237         Reviewed by George.
1238
1239         Centralize the setup for all the extra compilers in a addExtraCompiler function.
1240         
1241         This allows adding a "generated_files" target that builds all generated files using "make generated_files".
1242         For the build inside Qt we do not generate actual rules for the extra compilers but instead
1243         do the variable substitution of compiler.output manually and add the generated sources to SOURCES.
1244
1245         * WebCore.pro:
1246
1247 2007-11-21  Timothy Hatcher  <timothy@apple.com>
1248
1249         Reviewed by Eric Seidel.
1250
1251         Show Fonts as Yellow in the network timeline.
1252
1253         * page/inspector/NetworkPanel.js:
1254         * page/inspector/inspector.css:
1255
1256 2007-11-21  Dan Bernstein  <mitz@apple.com>
1257
1258         Reviewed by Eric Seidel.
1259
1260         - fix <rdar://problem/5607037> REGRESSION (r27351): Departure date does not repaint when changed on Google Maps public transit planner (16034)
1261
1262         Test: fast/repaint/subtree-root-skipped.html
1263
1264         * page/FrameView.cpp:
1265         (WebCore::FrameViewPrivate::FrameViewPrivate): Initialize the layout
1266         root to 0.
1267         (WebCore::FrameView::layoutRoot): Changed to return a RenderObject
1268         instead of a Node.
1269         (WebCore::FrameView::layout): Changed for layout root being a renderer
1270         rather than a DOM node. Also replaced clearing the repaint rects
1271         set with asserting that it is empty if this is the top-level call to
1272         layout(). If it is not, the set may contain rects from enclosing
1273         layout() and those should not be removed.
1274         (WebCore::FrameView::scheduleRelayout): Changed for layout root being
1275         a renderer rather than a DOM node.
1276         (WebCore::isObjectAncestorContainerOf): Added this helper function that
1277         tests whether one object will be marked by calling
1278         markContainingBlocksForLayout() on the other.
1279         (WebCore::FrameView::scheduleRelayoutOfSubtree): Changed for layout
1280         root being a renderer rather than a DOM node. Changed the check if new
1281         and current layout roots are on the same path from the root to use
1282         the subgraph of the render tree defined by container()hood instead of
1283         the DOM tree and parenthood.
1284         * page/FrameView.h:
1285         * rendering/RenderBox.cpp: 
1286         (WebCore::RenderBox::calcWidth): Changed for layout root being a
1287         renderer rather than a DOM node.
1288         * rendering/RenderObject.cpp:
1289         (WebCore::RenderObject::~RenderObject): Added an assertion that the
1290         object being deleted is not currently the layout root.
1291         (WebCore::RenderObject::scheduleRelayout): Changed for layout root being
1292         a renderer rather than a DOM node.
1293
1294 2007-11-21  Mark Rowe  <mrowe@apple.com>
1295
1296         Reviewed by Eric.
1297
1298         Fix WebCore to build without warnings under GCC 4.2.
1299
1300         * Configurations/Base.xcconfig:
1301         * css/CSSRuleList.cpp:
1302         (WebCore::CSSRuleList::deleteRule):
1303         * css/CSSStyleSelector.cpp:
1304         (WebCore::CSSStyleSelector::locateSharedStyle):
1305         * html/HTMLParser.cpp:
1306         (WebCore::HTMLParser::allowNestedRedundantTag):
1307         * rendering/RenderBlock.cpp:
1308         (WebCore::RenderBlock::fillInlineSelectionGaps):
1309         (WebCore::RenderBlock::fillBlockSelectionGaps):
1310         * rendering/RenderLayer.cpp:
1311         (WebCore::RenderLayer::stackingContext):
1312         (WebCore::RenderLayer::enclosingPositionedAncestor):
1313         (WebCore::RenderLayer::transparentAncestor):
1314         * rendering/RenderStyle.cpp:
1315         (WebCore::BackgroundLayer::fillUnsetProperties):
1316         (WebCore::Transition::fillUnsetProperties):
1317         * rendering/RenderText.cpp:
1318         (WebCore::RenderText::containsOnlyWhitespace):
1319         * rendering/bidi.cpp:
1320         (WebCore::RenderBlock::determineStartPosition):
1321
1322 2007-11-21  Alp Toker  <alp@atoker.com>
1323
1324         Reviewed by Mark Rowe.
1325
1326         http://bugs.webkit.org/show_bug.cgi?id=16071
1327         Curl backend handles EINTR incorrectly
1328
1329         Defer timers during select() to avoid interruption by timer signals.
1330
1331         * platform/network/curl/ResourceHandleManager.cpp:
1332         (WebCore::ResourceHandleManager::downloadTimerCallback):
1333
1334 2007-11-21  Mark Rowe  <mrowe@apple.com>
1335
1336         Reviewed by Tim Hatcher.
1337
1338         Changes due to <rdar://problem/5602936> Need to resolve new GCC 4.2 warnings
1339
1340         Update format strings to use format specifiers that match the argument types.
1341
1342         * loader/icon/IconDatabase.cpp:
1343         (WebCore::IconDatabase::performURLImport):
1344         (WebCore::IconDatabase::writeToDatabase):
1345         * platform/mac/TextCodecMac.cpp:
1346         (WebCore::TextCodecMac::decode):
1347         * storage/Database.cpp:
1348         (WebCore::Database::deliverAllPendingCallbacks):
1349
1350 2007-11-21  Xan Lopez  <xan@gnome.org>
1351
1352         Reviewed by Alp Toker.
1353
1354         Clarify scroll event processing with a comment.
1355
1356         * platform/gtk/PlatformScrollBarGtk.cpp:
1357         (gtkScrollEventCallback):
1358
1359 2007-11-21  Timothy Hatcher  <timothy@apple.com>
1360
1361         Reviewed by Adam Roben.
1362
1363         Bug 16085: Web Inspector's Network Timeline graph code clean up and misc. fixes
1364         http://bugs.webkit.org/show_bug.cgi?id=16085
1365         
1366         Changes include:
1367         - Refactor the drawing code as nested functions instead of global functions.
1368         - Compute the segment percentages only once per call to drawSummaryGraph.
1369         - Account for percentages that rounded down to total less-than 100%.
1370         - Draw the pill shadow better using the canvas shadow drawing properties.
1371         - Removes a couple canvas context saves and restores.
1372
1373         * page/inspector/NetworkPanel.js:
1374
1375 2007-11-21  Alexey Proskuryakov  <ap@webkit.org>
1376
1377         Reviewed by Adam Roben.
1378
1379         http://bugs.webkit.org/show_bug.cgi?id=16056
1380         Unicode not being interpreted correctly in Web Inspector source view
1381
1382         Cannot be tested automatically.
1383
1384         * loader/CachedCSSStyleSheet.cpp:
1385         (WebCore::CachedCSSStyleSheet::encoding):
1386         * loader/CachedCSSStyleSheet.h:
1387         * loader/CachedResource.h:
1388         (WebCore::CachedResource::encoding):
1389         * loader/CachedScript.cpp:
1390         (WebCore::CachedScript::encoding):
1391         * loader/CachedScript.h:
1392         * loader/CachedXBLDocument.cpp:
1393         (WebCore::CachedXBLDocument::encoding):
1394         * loader/CachedXBLDocument.h:
1395         * loader/CachedXSLStyleSheet.cpp:
1396         (WebCore::CachedXSLStyleSheet::encoding):
1397         * loader/CachedXSLStyleSheet.h:
1398         Teach textual CachedResources to report their encodings.
1399
1400         * page/InspectorController.cpp:
1401         (WebCore::addSourceToFrame):
1402         (WebCore::updateResourceResponse):
1403         Use the actual encoding - the network layer has little idea about it.
1404
1405 2007-11-20  Mark Rowe  <mrowe@apple.com>
1406
1407         Reviewed by Maciej Stachowiak.
1408
1409         Fix <rdar://problem/5609579> (DOMParser().parseFromString() freezes Safari when parsing large nodes with XML entities)
1410         http://bugs.webkit.org/show_bug.cgi?id=16076
1411
1412         XMLTokenizer was calling CharacterData::appendData twice per entity in the fragment of XML being
1413         parsed (once for text before the entity, once for the entity itself).  This triggered O(n^2) copying
1414         of the CharacterData's string due to resizing.  We now prevent this happening by buffering all the
1415         content for a given Text node in the XMLTokenizer before sending it out to the node in a single go.
1416
1417         * dom/XMLTokenizer.cpp:
1418         (WebCore::XMLTokenizer::characters): Append the characters to the buffer.
1419         (WebCore::XMLTokenizer::endDocument): Ensure the buffer is flushed when the document has ended.
1420         (WebCore::endDocumentHandler):
1421         (WebCore::XMLTokenizer::enterText):
1422         (WebCore::XMLTokenizer::exitText): Append the contents of the buffer to the node.
1423         (WebCore::XMLTokenizer::initializeParserContext): Add the endDocument handler.
1424         (WebCore::parseXMLDocumentFragment): Force endDocument to be called when parsing a fragment to ensure
1425         that the buffer gets flushed to the node.
1426         * dom/XMLTokenizer.h:
1427
1428 2007-11-20  Timothy Hatcher  <timothy@apple.com>
1429
1430         Reviewed by Mark Rowe.
1431
1432         Animate the status area and tip balloons in the Web Inspector
1433         with CSS animations.
1434
1435         * page/inspector/NetworkPanel.js:
1436         * page/inspector/inspector.css:
1437         * page/inspector/inspector.js:
1438
1439 2007-11-20  Kevin Ollivier  <kevino@theolliviers.com>
1440
1441         wx build fix for Windows. Don't use WebCore/move-js-headers.sh as
1442         it indiscriminately copies any headers inside JavaScriptCore,
1443         which includes Tiger ICU headers. 
1444
1445         * webcore-base.bkl:
1446         Remove references to the WebCore/include dir generated by
1447         move-js-headers.sh, and also get headers from JavaScriptCore
1448         directly rather than from WebCore/ForwardingHeaders. 
1449
1450 2007-11-20  Alp Toker  <alp@atoker.com>
1451
1452         Reviewed by Mark Rowe.
1453
1454         Avoid pointlessly mallocing and freeing this transform matrix.
1455
1456         * platform/gtk/FontPlatformDataGtk.cpp:
1457         (WebCore::FontPlatformData::FontPlatformData):
1458
1459 2007-11-20  Naiem Shaik  <naiem.shaik@gmail.com>
1460
1461         Reviewed by Alp Toker.
1462
1463         http://bugs.webkit.org/show_bug.cgi?id=15763
1464         [GTK] Enter key does not take to the link highlighted.
1465
1466         Add missing keycode cases.
1467
1468         * platform/gtk/KeyEventGtk.cpp:
1469         (WebCore::keyIdentifierForGdkKeyCode):
1470         (WebCore::windowsKeyCodeForKeyEvent):
1471         (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
1472
1473 2007-11-20  Mark Rowe  <mrowe@apple.com>
1474
1475         Reviewed by Sam Weinig.
1476
1477         Fix http://bugs.webkit.org/show_bug.cgi?id=16074
1478         Bug 16074: execCommand("InsertHorizontalRule", false, "") results in id="" being inserted
1479
1480         For consistency with InsertOrderedList and InsertUnorderedList a value parameter of "" should
1481         not result in an id being set.
1482
1483         * editing/JSEditor.cpp: Don't set the id attribute if value is empty.
1484
1485 2007-11-20  Dan Bernstein  <mitz@apple.com>
1486
1487         Reviewed by Adam Roben.
1488
1489         - fix <rdar://problem/5090708> Textareas render broken-looking scrollbars when too short to show full scrollbar
1490
1491         * platform/win/PlatformScrollBar.h:
1492         * platform/win/PlatformScrollBarSafari.cpp:
1493         Added the "hit inset" constants (representing how far the track eats
1494         into the button).
1495         (WebCore::PlatformScrollbar::paint): Changed to paint the buttons and
1496         the thumb only if they should be showing.
1497         (WebCore::PlatformScrollbar::hasButtons): Added. Returns whether the
1498         arrows should be drawn.
1499         (WebCore::PlatformScrollbar::hasThumb): Added. Returns whether the thumb
1500         should be drawn.
1501         (WebCore::PlatformScrollbar::forwardButtonRect):
1502         (WebCore::PlatformScrollbar::trackRect): Changed to return the entire
1503         bounds of the scrollbar if the scrollbar has no buttons.
1504         (WebCore::PlatformScrollbar::paintTrack): Changed to paint a disabled
1505         track along the entire scrollbar if it has not buttons.
1506         (WebCore::PlatformScrollbar::hitTest): Changed to hit test only the
1507         parts that the scrollbar has in its current dimensions.
1508
1509 2007-11-20  Mark Rowe  <mrowe@apple.com>
1510
1511         Reviewed by Alp Toker.
1512
1513         * config.h: Change #if to #ifdef to silence warnings on non-Apple platforms.
1514
1515 2007-11-20  Simon Hausmann  <hausmann@kde.org>
1516
1517         Reviewed by Adam Treat <treat@kde.org>.
1518
1519         Remove static linkage of QtWebKit against the ICO image format plugin.
1520         Instead build the support for the ICO image format as a proper standalone qt image format plugin and install it.
1521
1522         * WebCore.pro:
1523         * platform/graphics/qt/ImageDecoderQt.cpp:
1524
1525 2007-11-20  David D. Kilzer  <ddkilzer@webkit.org>
1526
1527         no-svg build broken after r27278
1528         <http://bugs.webkit.org/show_bug.cgi?id=16061>
1529
1530         Reviewed by Eric.
1531
1532         * bindings/scripts/CodeGeneratorObjC.pm: Always generate DOMHTMLEmbedElementPrivate.h
1533         and DOMHTMLObjectElementPrivate.h for no-svg build.
1534
1535 2007-11-20  Adam Treat  <treat@kde.org>
1536
1537         Reviewed by Simon.
1538
1539         * Don't use so much heap memory.
1540
1541         * platform/graphics/qt/ImageDecoderQt.cpp:
1542         * platform/graphics/qt/ImageDecoderQt.h:
1543         * platform/graphics/qt/ImageSourceQt.cpp:
1544         (WebCore::ImageSource::createFrameAtIndex):
1545
1546 2007-11-20  Lars Knoll  <lars@trolltech.com>
1547
1548         Reviewed by Simon.
1549
1550         Fix text break interators.
1551         
1552         The break iterators where trying to be smart about the input
1553         string and caching their results. Unfortunately a pointer/string length
1554         comparison is not good enough in all cases (since some input is stack based
1555         temp strings). Removed the caching but at the same time started to use a more
1556         efficient constructor of QTextBoundaryFinder that doesn't need to malloc for
1557         most strings.
1558         
1559         Fixes two test cases that test "text-transform: capitalize".
1560
1561         * platform/qt/TextBreakIteratorQt.cpp:
1562         (WebCore::wordBreakIterator):
1563         (WebCore::characterBreakIterator):
1564         (WebCore::lineBreakIterator):
1565         (WebCore::sentenceBreakIterator):
1566
1567 2007-11-20  Adam Treat  <treat@kde.org>
1568
1569         Reviewed by George.
1570
1571         * Make gif animations work for instance.
1572
1573         * platform/graphics/qt/ImageDecoderQt.cpp:
1574         (WebCore::ImageDecoderQt::reset):
1575         (WebCore::ImageDecoderQt::setData):
1576         (WebCore::ImageDecoderQt::frameCount):
1577         (WebCore::ImageDecoderQt::repetitionCount):
1578         * platform/graphics/qt/ImageDecoderQt.h:
1579
1580 2007-11-20  Adam Treat  <treat@kde.org>
1581
1582         * Build in release mode
1583
1584         * platform/NotImplemented.h:
1585
1586 2007-11-20  Adam Treat  <treat@kde.org>
1587
1588         Reviewed by Simon and George.
1589
1590         * Be quiet and allow suppression of NotImplemented calls at runtime.
1591
1592         * platform/NotImplemented.h:
1593
1594 2007-11-19  Doug Turner  <dougt@meer.net>
1595
1596         Reviewed by Alp Toker.
1597
1598         http://bugs.webkit.org/show_bug.cgi?id=16054
1599         Crash when GlyphPage::fill is called with more than 256 bytes of data
1600
1601         http://bugs.webkit.org/show_bug.cgi?id=14446
1602         [GDK] Crash on http://www.wikipedia.org/
1603
1604         setGlyphDataForIndex() uses a fixed array of size 256 which we can't
1605         exceed. We need to return failure if the buffer has Unicode
1606         supplementary characters for now.
1607
1608         This strategy matches the Win port, which also doesn't support this
1609         case yet.
1610
1611         Add an assertion so nobody makes this mistake again.
1612
1613         * platform/GlyphPageTreeNode.h:
1614         (WebCore::GlyphPage::setGlyphDataForIndex):
1615         * platform/gtk/GlyphPageTreeNodeGtk.cpp:
1616         (WebCore::GlyphPage::fill):
1617
1618 2007-11-19  Doug Turner  <dougt@meer.net>
1619
1620         Reviewed by Timothy Hatcher.
1621
1622         http://bugs.webkit.org/show_bug.cgi?id=16050
1623         sqlite3_prepare16_v2 build bustage.
1624
1625         Using the correct SQLITE_VERSION_NUMBER around sqlite_prepare16_v2
1626         to fix build bustage.
1627
1628         * platform/sql/SQLiteStatement.cpp:
1629         (WebCore::SQLiteStatement::prepare):
1630
1631 2007-11-19  Mark Rowe  <mrowe@apple.com>
1632
1633         Build fix.  Don't over-qualify the constructor name.
1634
1635         * storage/DatabaseDetails.h:
1636
1637 2007-11-19  Brady Eidson <beidson@apple.com>
1638
1639         Reviewed by Maciej
1640
1641         Stub out the WebCore parts of the WebKit API
1642
1643         * WebCore.base.exp:
1644         * WebCore.xcodeproj/project.pbxproj:
1645
1646         * storage/DatabaseDetails.h: Added.  Simple container for vitals on a specific database
1647         (WebCore::DatabaseDetails::DatabaseDetails::DatabaseDetails):
1648         (WebCore::DatabaseDetails::DatabaseDetails):
1649         (WebCore::DatabaseDetails::isValid):
1650         (WebCore::DatabaseDetails::name):
1651         (WebCore::DatabaseDetails::version):
1652         (WebCore::DatabaseDetails::displayName):
1653         (WebCore::DatabaseDetails::expectedUsage):
1654         (WebCore::DatabaseDetails::currentUsage):
1655
1656         * storage/DatabaseTracker.cpp:  Added various methods for API usage
1657         (WebCore::DatabaseTracker::detailsForNameAndOrigin):
1658         (WebCore::DatabaseTracker::usageForOrigin):
1659         (WebCore::DatabaseTracker::quotaForOrigin):
1660         (WebCore::DatabaseTracker::setQuota):
1661         * storage/DatabaseTracker.h:
1662
1663 2007-11-19  Kevin Ollivier  <kevino@theolliviers.com>
1664
1665         wx port build fix.
1666
1667         * platform/graphics/wx/AffineTransformWx.cpp:
1668         (WebCore::AffineTransform::operator== ):
1669         m_transform is only available when using wxGraphicsContext.
1670
1671 2007-11-19  Alp Toker  <alp@atoker.com>
1672
1673         Reviewed by Mark Rowe.
1674
1675         GTK+ drawing fixes.
1676
1677         Add a check to avoid crashing when the GraphicsContext is not
1678         associated with a GdkDrawable. This was noticed when adding printing
1679         support but might be triggered in other situations too.
1680
1681         Do not render themes when painting is disabled. This is an
1682         optimisation for cases where GraphicsContext is used to calculate page
1683         dimensions etc. without actually rendering.
1684
1685         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1686         (WebCore::GraphicsContext::gdkDrawable):
1687         * platform/gtk/RenderThemeGtk.cpp:
1688         (WebCore::paintMozWidget):
1689
1690 2007-11-13  Rahul Abrol  <ra5ul@comcast.net>
1691
1692         Reviewed by Tim Hatcher.
1693
1694         http://bugs.webkit.org/show_bug.cgi?id=15977
1695         Resizing images preference now toggles default image state.
1696
1697         * loader/ImageDocument.cpp:
1698         (WebCore::ImageDocument::ImageDocument):
1699         (WebCore::ImageDocument::createDocumentStructure):
1700         (WebCore::ImageDocument::imageChanged):
1701
1702 2007-11-19  Kevin Ollivier  <kevino@theolliviers.com>
1703
1704         Update wx port build sources with recent changes, update
1705         wx FontPlatformData to be a class (MSVC7 gets confused
1706         otherwise...) and implement its hash() method.
1707
1708         Reviewed by Adam.
1709
1710         * WebCoreSources.bkl:
1711         * platform/wx/FontPlatformData.h:
1712         (WebCore::FontPlatformData::hash):
1713
1714 2007-11-19  Julien Chaffraix  <julien.chaffraix@gmail.com>
1715
1716         Reviewed by Darin.
1717
1718         http://bugs.webkit.org/show_bug.cgi?id=12194
1719         Bug 12194: Trying to access XMLHttpRequest.responseText or responseXML when they 
1720         are not available should raise an exception
1721
1722         Tests: http/tests/xmlhttprequest/xmlhttprequest-responseText-exception.html
1723                http/tests/xmlhttprequest/xmlhttprequest-responseXML-exception.html
1724
1725         * bindings/js/JSXMLHttpRequest.cpp:
1726         (KJS::JSXMLHttpRequest::getValueProperty):
1727         * xml/XMLHttpRequest.cpp:
1728         (WebCore::XMLHttpRequest::getResponseText):
1729         (WebCore::XMLHttpRequest::getResponseXML):
1730         * xml/XMLHttpRequest.h:
1731
1732 2007-11-19  Peter Kasting  <zerodpx@gmail.com>
1733
1734         Reviewed by Darin Adler.
1735
1736         http://bugs.webkit.org/show_bug.cgi?id=15971
1737         The GIF decoder should not fail decoding if the caller asks it to
1738         decode again when no new data has arrived since the last call.
1739
1740         * platform/image-decoders/gif/GIFImageReader.cpp:
1741         (GIFImageReader::read):
1742
1743 2007-11-18  Brady Eidson <beidson@apple.com>
1744
1745         Reviewed by Eric
1746
1747         Fix a crash hashing a default SecurityOriginData object 
1748
1749         * storage/DatabaseTracker.cpp:
1750         (WebCore::SecurityOriginDataHash::hash): The default object has some default strings with NULL
1751           StringImpls - don't try to hash those!
1752
1753 2007-11-18  Timothy Hatcher  <timothy@apple.com>
1754
1755         Reviewed by Sam Weinig.
1756
1757         Bug 16043: Remove InspectorController.log now that console.log works
1758         http://bugs.webkit.org/show_bug.cgi?id=16043
1759
1760         Remove the last uses of InspectorController.log. Once use was no longer needed,
1761         checking an erro case that can't happen anymore. The other case now uses console.error.
1762
1763         * page/InspectorController.cpp: Remove the log function.
1764         (WebCore::InspectorController::windowScriptObjectAvailable): Remove the log function from
1765         InspectorController script class.
1766         * page/inspector/DocumentPanel.js: Remove a use of InspectorController.log that isn't needed.
1767         * page/inspector/Panel.js: Change InspectorController.log to console.log and early return.
1768
1769 2007-11-18  Timothy Hatcher  <timothy@apple.com>
1770
1771         Reviewed by Brady.
1772
1773         Bug 16041: REGRESSION: the Database panel in the Inspector stopped showing errors
1774         http://bugs.webkit.org/show_bug.cgi?id=16041
1775
1776         * page/inspector/DatabasePanel.js: Implement error callbacks to pass to executeSql()
1777           and transaction(). Refactored some code for the success and error callbacks to use.
1778
1779 2007-11-18  Alexey Proskuryakov  <ap@webkit.org>
1780
1781         Reviewed by Maciej.
1782
1783         <rdar://problem/5546393> Whitespace handling doesn't match HTML5.
1784
1785         HTML5 definition is the same as MSIE's, with the exception that the latter strips null
1786         characters. Firefox also treats U+0008 as whitespace, but not U+000B or U+000C.
1787
1788         Test: fast/parser/html-whitespace.html
1789
1790         * html/HTMLTokenizer.cpp:
1791         (WebCore::HTMLTokenizer::parseSpecial):
1792         (WebCore::HTMLTokenizer::parseTag):
1793         Use isASCIISpace, which matches HTML5 definition of whitespace, and also what we use to
1794         check for whitespace almost everywhere.
1795
1796 2007-11-17  Mark Rowe  <mrowe@apple.com>
1797
1798         Reviewed by Darin Adler.
1799
1800         Fix: <rdar://problem/5607032> REGRESSION: testapi exits with assertion failure in debug build
1801              <rdar://problem/5440659> JSGlobalContextCreate throws away globalObjectClass's prototype
1802              http://bugs.webkit.org/show_bug.cgi?id=16033
1803
1804         Update for changes in Interpreter method signatures.
1805
1806         * bindings/js/kjs_binding.cpp:
1807         (KJS::ScriptInterpreter::ScriptInterpreter):
1808         * bindings/js/kjs_window.cpp:
1809         (KJS::Window::clear):
1810
1811 2007-11-17  Timothy Hatcher  <timothy@apple.com>
1812
1813         Reviewed by Mark Rowe.
1814
1815         Bug 13470: i18n: The Web Inspector is not localizable
1816         http://bugs.webkit.org/show_bug.cgi?id=13470
1817
1818         Add support for localization to the Web Inspector. Clients need to
1819         implement localizedStringsURL() to return the URL of the
1820         InspectorLocalizedStrings.js that best matches the user's language.
1821
1822         * English.lproj: Added.
1823         * English.lproj/InspectorLocalizedStrings.js: Added.
1824         * WebCore.xcodeproj/project.pbxproj: Add InspectorLocalizedStrings.js.
1825         * page/InspectorClient.h: Add localizedStringsURL.
1826         * page/InspectorController.cpp: Add localizedStringsURL that calls
1827           the client. Also added a version exposed to JavaScript.
1828         * page/InspectorController.h: Add localizedStringsURL.
1829         * page/inspector/ConsolePanel.js: Call WebInspector.UIString
1830           for user visible strings.
1831         * page/inspector/DatabasePanel.js: Ditto.
1832         * page/inspector/DocumentPanel.js: Ditto.
1833         * page/inspector/ImagePanel.js: Ditto.
1834         * page/inspector/MetricsSidebarPane.js: Ditto.
1835         * page/inspector/NetworkPanel.js: Ditto.
1836         * page/inspector/Panel.js: Ditto.
1837         * page/inspector/PropertiesSidebarPane.js: Ditto.
1838         * page/inspector/Resource.js: Ditto.
1839         * page/inspector/ResourceCategory.js: Ditto.
1840         * page/inspector/SourcePanel.js: Ditto.
1841         * page/inspector/StylesSidebarPane.js: Ditto.
1842         * page/inspector/inspector.css: Use pre-wrap so database errors can use \n.
1843         * page/inspector/inspector.html: Remove some user visible strings.
1844         * page/inspector/inspector.js: Added WebInspector.UIString and call
1845           WebInspector.UIString for user visible strings. Some code needed to be 
1846           moved to WebInspector.loaded to use UIString after the localized strings
1847           get loaded.
1848         * platform/graphics/svg/SVGImageEmptyClients.h:
1849         (WebCore::SVGEmptyFrameLoaderClient::redirectDataToPlugin): Remove WebCore:: prefix.
1850         (WebCore::SVGEmptyInspectorClient::createPage): Ditto.
1851         (WebCore::SVGEmptyInspectorClient::localizedStringsURL): Add empty stub.
1852         (WebCore::SVGEmptyInspectorClient::highlight): Remove WebCore:: prefix.
1853         (WebCore::SVGEmptyInspectorClient::inspectedURLChanged): Ditto.
1854
1855 2007-11-17  Timothy Hatcher  <timothy@apple.com>
1856
1857         Reviewed by Adam.
1858
1859         Reworte String.sprintf to fix many bad bugs and to not use RegExp. Also added
1860         String.vsprintf so it can be used later for the localization function.
1861
1862         This version only supports argument reordering, precision for floats, and these
1863         format characters: d, f, s and @. Any unsupported format characters are logged
1864         and substituted like strings.
1865
1866         * page/inspector/utilities.js:
1867
1868 2007-11-17  Alexey Proskuryakov  <ap@webkit.org>
1869
1870         Windows build fix.
1871
1872         * editing/Editor.h: Made canSmartCopyOrDelete public, as Windows WebView still needs it.
1873
1874 2007-11-17  Alexey Proskuryakov  <ap@webkit.org>
1875
1876         Reviewed by Darin.
1877
1878         http://bugs.webkit.org/show_bug.cgi?id=15969
1879         Eliminate Editor::deleteRange()
1880
1881         No change in functionality.
1882
1883         * editing/CompositeEditCommand.h: Removed unimplemented deleteKeyPressed().
1884
1885         * editing/Editor.cpp:
1886         (WebCore::Editor::deleteWithDirection):
1887         (WebCore::Editor::cut):
1888         (WebCore::Editor::performDelete):
1889         * editing/Editor.h:
1890         Moved relevant Editor::deleteRange() functionality to its callers.
1891         Removed deleteSelectionWithSmartDelete(void), which was more confusing than helpful
1892         in my opinion.
1893
1894         * editing/mac/EditorMac.mm:
1895         (WebCore::initializeKillRingIfNeeded):
1896         (WebCore::Editor::addToKillRing):
1897         (WebCore::Editor::yank):
1898         (WebCore::Editor::yankAndSelect):
1899         (WebCore::Editor::setMark):
1900         (WebCore::unionDOMRanges):
1901         (WebCore::Editor::deleteToMark):
1902         (WebCore::Editor::selectToMark):
1903         (WebCore::Editor::swapWithMark):
1904         Pushed kill ring handling down from WebCore.
1905
1906         * page/mac/WebCoreFrameBridge.h:
1907         * page/mac/WebCoreFrameBridge.mm:
1908         Removed setMarkDOMRange (the corresponding getter is still needed).
1909
1910         * WebCore.base.exp: No longer need to export Editor::deleteRange() and Editor::insertTextWithoutSendingTextEvent().
1911         Export the new kill ring functions.
1912
1913 2007-11-16  Ryan Leavengood  <leavengood@gmail.com>
1914
1915         Reviewed by David Kilzer.
1916
1917         Build fix: the needed headers for POSIX file functions were not
1918         included.
1919
1920         * platform/posix/FileSystemPOSIX.cpp:
1921
1922 2007-11-16  Dan Bernstein  <mitz@apple.com>
1923
1924         Reviewed by Darin Adler.
1925
1926         - fix the common case of <http://bugs.webkit.org/show_bug.cgi?id=15994>
1927           REGRESSION: Incomplete repaint of CSS image substitution
1928
1929         Test: fast/repaint/clip-with-layout-delta.html
1930
1931         * rendering/LayoutState.cpp:
1932         (WebCore::LayoutState::LayoutState): Account for layout delta when
1933         pushing additional clip.
1934
1935 2007-11-16  Antti Koivisto  <antti@apple.com>
1936
1937         Reviewed by Adele.
1938         
1939         Seeking related fixes, updates to match the latest specification
1940         - rename loopCount of HTMLMediaElement to playCount
1941         - add explicit seeking attribute to HTMLMediaElement to get semantics right
1942         - implement the specification behavior that currentTime must immediately return seeked position in HTMLMediaElement 
1943           instead of MoviePrivateQTKit 
1944         - fix broken behavior when seeking past end of the media, add tests
1945         - replace Movie didEnd callback with broader timeChanged callback (which gets called in didEnd case too)
1946         - use setDelayCallbacks: in various MoviePrivateQTKit methods to avoid bug prone synchronous callbacks from QT, make
1947           HTMLMediaElement not depend on synchronous callbacks
1948         - do some cleanups and simplifications in MoviePrivateQTKit, get rid of m_rateBeforeSeek and m_blockStateUpdate variables
1949
1950         Tests: http/tests/media/video-seekable-stall.html
1951                media/video-seeking.html
1952                media/video-seek-past-end-paused.html
1953                media/video-seek-past-end-playing.html
1954
1955         * html/HTMLAttributeNames.in: 
1956         * html/HTMLMediaElement.cpp:
1957         (WebCore::HTMLMediaElement::HTMLMediaElement):
1958         (WebCore::HTMLMediaElement::load):
1959         (WebCore::HTMLMediaElement::movieNetworkStateChanged):
1960         (WebCore::HTMLMediaElement::setReadyState):
1961         (WebCore::HTMLMediaElement::seek):
1962         (WebCore::HTMLMediaElement::seeking):
1963         (WebCore::HTMLMediaElement::currentTime):
1964         (WebCore::HTMLMediaElement::ended):
1965         (WebCore::HTMLMediaElement::play):
1966         (WebCore::HTMLMediaElement::pause):
1967         (WebCore::HTMLMediaElement::playCount):
1968         (WebCore::HTMLMediaElement::setPlayCount):
1969         (WebCore::HTMLMediaElement::checkIfSeekNeeded):
1970         (WebCore::HTMLMediaElement::movieTimeChanged):
1971         (WebCore::HTMLMediaElement::endedPlayback):
1972         (WebCore::HTMLMediaElement::updateMovie):
1973         * html/HTMLMediaElement.h:
1974         * html/HTMLMediaElement.idl:
1975         * platform/graphics/Movie.cpp:
1976         (WebCore::Movie::timeChanged):
1977         * platform/graphics/Movie.h:
1978         (WebCore::MovieClient::movieTimeChanged):
1979         * platform/graphics/mac/MoviePrivateQTKit.h:
1980         * platform/graphics/mac/MoviePrivateQTKit.mm:
1981         (WebCore::MoviePrivate::MoviePrivate):
1982         (WebCore::MoviePrivate::load):
1983         (WebCore::MoviePrivate::play):
1984         (WebCore::MoviePrivate::pause):
1985         (WebCore::MoviePrivate::currentTime):
1986         (WebCore::MoviePrivate::seek):
1987         (WebCore::MoviePrivate::doSeek):
1988         (WebCore::MoviePrivate::cancelSeek):
1989         (WebCore::MoviePrivate::seekTimerFired):
1990         (WebCore::MoviePrivate::startCuePointTimerIfNeeded):
1991         (WebCore::MoviePrivate::paused):
1992         (WebCore::MoviePrivate::updateStates):
1993         (WebCore::MoviePrivate::timeChanged):
1994         (WebCore::MoviePrivate::didEnd):
1995
1996 2007-11-16  Anders Carlsson  <andersca@apple.com>
1997
1998         Reviewed by Adam.
1999
2000         <rdar://problem/5603832>
2001         XMLHttpRequest readyState 3 & responseText buffer issues.
2002
2003         * platform/network/cf/ResourceHandleCFNet.cpp:
2004         (WebCore::makeFinalRequest):
2005         Add new parameter which controls whether content sniffing should be turned off.
2006         
2007         (WebCore::ResourceHandle::loadResourceSynchronously):
2008         Always content sniff sync loads.
2009         
2010         * platform/network/cf/ResourceRequestCFNet.cpp:
2011         (WebCore::ResourceRequest::doUpdatePlatformRequest):
2012         If the ResourceRequest already has a backing CFURLRequest, make a copy of it. This preserves
2013         any properties set on the CFURLRequest.
2014
2015 2007-11-16  Jon Honeycutt  <jhoneycutt@apple.com>
2016
2017         Reviewed by Ollie.
2018
2019         <rdar://problem/5605175> Crash closing or leaving window with ViewPoint 
2020         Media player plugin
2021
2022         ViewPoint plugin requires that we pass a valid NPSavedData* to
2023         NPP_Destroy.
2024
2025         * plugins/win/PluginViewWin.cpp: Pass a valid NPSavedData* to
2026         NPP_Destroy. If the plugin allocates data, discard it
2027
2028 2007-11-16  Mark Rowe  <mrowe@apple.com>
2029
2030         Reviewed by Tim Hatcher.
2031
2032         Build WebCore as a sub-framework of WebKit in all configurations.
2033
2034         * Configurations/WebCore.xcconfig:
2035         * WebCore.xcodeproj/project.pbxproj:
2036
2037 2007-11-16  Doug Turner  <dougt@meer.net>
2038
2039         Reviewed by Alp.
2040
2041         http://bugs.webkit.org/show_bug.cgi?id=16018
2042         build bustage when building on debian 4.0
2043
2044         Fix build bustage on GTK+ with older versions of Pango.
2045
2046         Don't cache the return value since the docs say it can change.
2047
2048         * platform/gtk/Language.cpp:
2049         (WebCore::defaultLanguage):
2050
2051 2007-11-16  Brady Eidson  <beidson@apple.com>
2052
2053         Build fix
2054
2055         * platform/SecurityOriginData.h:
2056         (WebCore::operator!=): Whoops!
2057
2058 2007-11-16  Brady Eidson  <beidson@apple.com>
2059
2060         Reviewed by Sam
2061
2062         Further purify DatabaseTracker to use SecurityOriginData instead of "a String"
2063
2064         * WebCore.base.exp:
2065         * WebCore.xcodeproj/project.pbxproj:
2066         * WebCore.vcproj/WebCore.vcproj
2067         * WebCore.pro
2068
2069         * platform/SecurityOriginData.cpp: Added.
2070         (WebCore::SecurityOriginData::SecurityOriginData): Add a constructor that takes a "stringIdentifier"-style string,
2071           since that form is what will be stored in the Databases.db on disk
2072         (WebCore::SecurityOriginData::stringIdentifier):
2073         * platform/SecurityOriginData.h:
2074         (WebCore::SecurityOriginData::protocol):
2075         (WebCore::SecurityOriginData::host):
2076         (WebCore::SecurityOriginData::port):
2077
2078         * storage/DatabaseTracker.cpp:
2079         (WebCore::SecurityOriginDataHash::hash): Follow the pattern Darin set in FontCache.cpp to make a decent hash for 
2080           a SecurityOriginData object
2081         (WebCore::SecurityOriginDataHash::equal):
2082         (WebCore::SecurityOriginDataTraits::deletedValue): "file::1" will never exist in normal operation
2083         (WebCore::SecurityOriginDataTraits::emptyValue): "file::2" will never exist in normal operation
2084         (WebCore::DatabaseTracker::fullPathForDatabase):
2085         (WebCore::DatabaseTracker::populateOrigins):
2086         (WebCore::DatabaseTracker::origins):
2087         (WebCore::DatabaseTracker::addDatabase):
2088         * storage/DatabaseTracker.h:
2089
2090 2007-11-16  Alexey Proskuryakov  <ap@webkit.org>
2091
2092         Windows build fix.
2093
2094         * WebCore.vcproj/WebCore.vcproj: Removed VoidCallback.cpp, added JSCustomVoidCallback.{h,cpp}.
2095
2096 2007-11-16  Nikolas Zimmermann  <zimmermann@kde.org>
2097
2098         Reviewed by Eric.
2099
2100         Fixes: http://bugs.webkit.org/show_bug.cgi?id=12290
2101
2102         Implement all SVGTextContentElement DOM methods.
2103         This is the last missing SVG text feature. SVG fonts is next.
2104
2105         Added testcase: svg/custom/text-dom-01-f.svg (tests all new methods)
2106
2107         * ksvg2/svg/SVGTextContentElement.cpp:
2108         (WebCore::cummulatedCharacterRangeLength):
2109         (WebCore::SVGInlineTextBoxQueryWalker::):
2110         (WebCore::SVGInlineTextBoxQueryWalker::SVGInlineTextBoxQueryWalker):
2111         (WebCore::SVGInlineTextBoxQueryWalker::chunkPortionCallback):
2112         (WebCore::SVGInlineTextBoxQueryWalker::setQueryInputParameters):
2113         (WebCore::SVGInlineTextBoxQueryWalker::longResult):
2114         (WebCore::SVGInlineTextBoxQueryWalker::floatResult):
2115         (WebCore::SVGInlineTextBoxQueryWalker::pointResult):
2116         (WebCore::SVGInlineTextBoxQueryWalker::rectResult):
2117         (WebCore::SVGInlineTextBoxQueryWalker::stopProcessing):
2118         (WebCore::findInlineTextBoxInTextChunks):
2119         (WebCore::rootInlineBoxForTextContentElement):
2120         (WebCore::executeTextQuery):
2121         (WebCore::SVGTextContentElement::getNumberOfChars):
2122         (WebCore::SVGTextContentElement::getComputedTextLength):
2123         (WebCore::SVGTextContentElement::getSubStringLength):
2124         (WebCore::SVGTextContentElement::getStartPositionOfChar):
2125         (WebCore::SVGTextContentElement::getEndPositionOfChar):
2126         (WebCore::SVGTextContentElement::getExtentOfChar):
2127         (WebCore::SVGTextContentElement::getRotationOfChar):
2128         (WebCore::SVGTextContentElement::getCharNumAtPosition):
2129         (WebCore::SVGTextContentElement::selectSubString):
2130         * ksvg2/svg/SVGTextContentElement.h:
2131         * rendering/SVGInlineTextBox.h:
2132
2133 2007-11-15  Adele Peterson  <adele@apple.com>
2134
2135         Reviewed by Oliver.
2136
2137         Fix for <rdar://problem/5566652> CrashTracer: [USER] 3 crashes in Safari at HTMLSelectElement::menuListDefaultEventHandler (reproducible on mactc30.com)
2138
2139         Test: fast/forms/menulist-no-renderer-onmousedown.html
2140
2141         * html/HTMLSelectElement.cpp:
2142         (WebCore::HTMLSelectElement::defaultEventHandler): Nil check the renderer here.  None of the default behavior makes sense if there's no renderer.
2143         (WebCore::HTMLSelectElement::listBoxDefaultEventHandler): Moved the nil check to the main defaultEventHandler.
2144
2145 2007-11-15  Antti Koivisto  <antti@apple.com>
2146
2147         Reviewed by Adele.
2148
2149         Fix <rdar://problem/5601598>
2150         The movie tag should do initialization on need and not during startup.
2151         
2152         Initialize Movie MIME type hash on demand
2153
2154         * platform/MIMETypeRegistry.cpp:
2155         (WebCore::initialiseSupportedMovieMIMETypes):
2156         (WebCore::initialiseMIMETypeRegistry):
2157         (WebCore::MIMETypeRegistry::isSupportedMovieMIMEType):
2158         (WebCore::MIMETypeRegistry::getSupportedMovieMIMETypes):
2159
2160 2007-11-15  Mark Rowe  <mrowe@apple.com>
2161
2162         Build fix for Qt on Windows.
2163
2164         * xml/XPathStep.cpp:
2165         (WebCore::XPath::Step::nodesInAxis):
2166
2167 2007-11-15  Timothy Hatcher  <timothy@apple.com>
2168
2169         Reviewed by Mark Rowe.
2170
2171         Bug 14761: Web Inspector leaks JS objects and DOM nodes
2172         http://bugs.webkit.org/show_bug.cgi?id=14761
2173
2174         * page/InspectorController.cpp:
2175         (WebCore::InspectorController::~InspectorController):
2176         Change the tear down order so that inspectorDestroyed() is called before
2177         InspectorController private data is set to Zero. The inspectorDestroyed()
2178         call ends up closing the WebView and triggering InspectorController::close()
2179         which unprotects m_scriptObject. This didn't happen when the private data
2180         was cleared before calling inspectorDestroyed().
2181
2182 2007-11-15  Mark Rowe  <mrowe@apple.com>
2183
2184         Gtk build fix.
2185
2186         * WebCore.pro:
2187
2188 2007-11-15  Alexey Proskuryakov  <ap@webkit.org>
2189
2190         Reviewed by Darin.
2191
2192         http://bugs.webkit.org/show_bug.cgi?id=15989
2193         XPath queries with predicates incorrectly retains the current node across unions
2194
2195         Test: fast/xpath/union-context-node.xhtml
2196
2197         * xml/XPathPath.cpp:
2198         (WebCore::XPath::LocationPath::evaluate): Restore context after evaluation.
2199         * xml/XPathStep.cpp:
2200         (WebCore::XPath::Step::evaluate): Do not backup context, as we can easily re-create it.
2201
2202 2007-11-15  Alexey Proskuryakov  <ap@webkit.org>
2203
2204         Reviewed by Darin.
2205
2206         http://bugs.webkit.org/show_bug.cgi?id=15988
2207         REGRESSION: XPath preceding-axis query misses nested elements
2208
2209         Test: fast/xpath/preceding-axis.xhtml
2210
2211         * xml/XPathStep.cpp:
2212         (WebCore::XPath::Step::nodesInAxis): Hopefully correct this time.
2213
2214 2007-11-15  Timothy Hatcher  <timothy@apple.com>
2215
2216         Reviewed by Mark Rowe and Sam.
2217
2218         This corrects a couple of issues in the Web Inspector where selected search results
2219         would not have the right text color when the window is inactive or the results are focused.
2220
2221         * page/inspector/inspector.css:
2222
2223 2007-11-15  Timothy Hatcher  <timothy@apple.com>
2224
2225         Reviewed by Sam.
2226
2227         Bug 16007: REGRESSION: Disclosure triangle click zone for resource categories is off by 10 pixels
2228         http://bugs.webkit.org/show_bug.cgi?id=16007
2229
2230         Makes the click width an option on TreeElement and make ResourceCategoryTreeElement
2231         a true subclass of TreeElement. The click width for ResourceCategoryTreeElement is 
2232         20 pixels, and the default is 10 pixels.
2233
2234         * page/inspector/ResourceCategory.js:
2235         * page/inspector/treeoutline.js:
2236
2237 2007-11-15  Anders Carlsson  <andersca@apple.com>
2238
2239         Reviewed by Brady.
2240
2241         Pass a VoidCallback to Database::transaction and Database::changeVersion.
2242         This is not yet hooked up to the database machinery.
2243         
2244         * WebCore.vcproj/WebCore.vcproj:
2245         * bindings/js/JSDatabaseCustom.cpp:
2246         (WebCore::JSDatabase::changeVersion):
2247         (WebCore::JSDatabase::transaction):
2248         * storage/Database.cpp:
2249         (WebCore::Database::changeVersion):
2250         (WebCore::Database::transaction):
2251         * storage/Database.h:
2252
2253 2007-11-15  Timothy Hatcher  <timothy@apple.com>
2254
2255         Reviewed by Adam.
2256
2257         Bug 16005: Hovering in the breadcrumbs causes jumpy behavior
2258         http://bugs.webkit.org/show_bug.cgi?id=16005
2259
2260         Hovering over cumbs no longer exposes new crumbs. Clicking on a collapsed
2261         crumb will expose as many hidden crumbs as possible to the user. Also crumbs
2262         that have ID attributes will compact to the ID over the tag name.
2263
2264         * page/inspector/DocumentPanel.js:
2265
2266 2007-11-15  Anders Carlsson  <andersca@apple.com>
2267
2268         Reviewed by Sam.
2269
2270         Make the VoidCallback DOM interface behave more like our other DOM interfaces.
2271         
2272         * bindings/js/JSCustomVoidCallback.h: Added.
2273         * bindings/js/JSCustomVoidCallback.cpp: Added.
2274         (WebCore::JSCustomVoidCallback::JSCustomVoidCallback):
2275         (WebCore::JSCustomVoidCallback::handleEvent):
2276         VoidCallback implementation that wraps a JS object.
2277         
2278         (WebCore::toVoidCallback):
2279         New method that creates a VoidCallback implementation given a JS object.
2280         
2281         * bindings/scripts/CodeGeneratorJS.pm:
2282         Specify that VoidCallback can fail conversion and add a custom conversion function.
2283         
2284         * html/HTMLMediaElement.cpp:
2285         (WebCore::HTMLMediaElement::movieCuePointReached):
2286         Call handleEvent on the callback.
2287         
2288         (WebCore::HTMLMediaElement::removeCuePoint):
2289         Comment out parts of this method, it has already been removed in the HTML5 spec and it relies
2290         on overriding VoidCallback equality.
2291         
2292         * html/VoidCallback.cpp: Removed.
2293         
2294         * html/VoidCallback.h:
2295         (WebCore::VoidCallback::VoidCallback):
2296         (WebCore::VoidCallback::~VoidCallback):
2297         Make this an abstract class with a pure virtual handleEvent method.
2298         
2299 2007-11-15  Adam Roben  <aroben@apple.com>
2300
2301         Fix <rdar://5485108> Type-select while a <select> menu is open doesn't work
2302
2303         There were two things broken here:
2304            - WebView now requires a WM_CHAR message to be sent before it will
2305              create a keyboard event with a charCode, but we were only sending
2306              a WM_KEYDOWN event.
2307            - The popup menu was not updating its focused index when the
2308              <select> element's selectedIndex changed.
2309
2310         Reviewed by Adele.
2311
2312         * platform/win/PopupMenuWin.cpp:
2313         (WebCore::PopupMenu::updateFromElement): Update the focused index from
2314         the client's selected index.
2315         (WebCore::PopupWndProc): When we receive a WM_CHAR message for a
2316         printable character, manufacture a WM_KEYDOWN message for it and post
2317         both that and the current WM_CHAR message to the WebView.
2318
2319 2007-11-15  Brady Eidson  <beidson@apple.com>
2320
2321         Build fix
2322
2323         * storage/DatabaseTracker.cpp:
2324         (WebCore::DatabaseTracker::fullPathForDatabase):
2325         (WebCore::DatabaseTracker::databaseNamesForOrigin):
2326
2327 2007-11-15  Brady Eidson  <beidson@apple.com>
2328
2329         Reviewed by John and Sam
2330
2331         Stubbing out everything required for a WebKit API for databases
2332
2333         Biggest change in WebCore is that we passed around SecurityOriginData as the representation
2334         of a SecurityOrigin, instead of a String or a SecurityOrigin itself (which is an opaque object
2335         that has a different purpose besides just hanging on to the data)
2336
2337         * WebCore.base.exp:
2338         * WebCore.xcodeproj/project.pbxproj:
2339
2340         * platform/SecurityOrigin.cpp:
2341         * platform/SecurityOrigin.h:
2342         * platform/SecurityOriginData.h: Added.  Simple object to encapsulate the 3
2343           pieces of data in the SecurityOrigin tuple
2344         (WebCore::SecurityOriginData::SecurityOriginData):
2345         (WebCore::SecurityOriginData::protocol):
2346         (WebCore::SecurityOriginData::host):
2347         (WebCore::SecurityOriginData::port):
2348         (WebCore::SecurityOriginData::toString): Simple concatenation of the 3 components,
2349           colon separated
2350
2351         * storage/Database.cpp:
2352         (WebCore::Database::Database): Use SecurityOriginData instead
2353
2354         * storage/DatabaseTracker.cpp:
2355         (WebCore::DatabaseTracker::fullPathForDatabase):
2356         (WebCore::DatabaseTracker::databaseNamesForOrigin):
2357         (WebCore::DatabaseTracker::deleteDatabasesWithOrigin):
2358         (WebCore::DatabaseTracker::deleteDatabase):
2359         * storage/DatabaseTracker.h:
2360
2361         * storage/DatabaseTrackerClient.h: Added.  For dispatching notifications up to WebKit
2362         (WebCore::DatabaseTrackerClient::~DatabaseTrackerClient):2007-11-15  Jon Honeycutt  <jhoneycutt@apple.com>
2363
2364 2007-11-15  Jon Honeycutt  <jhoneycutt@apple.com>
2365
2366         Reviewed by Anders.
2367
2368         NP_ASFILEONLY streams should not buffer data in m_deliveryData.
2369
2370         * plugins/win/PluginStreamWin.cpp:
2371         (WebCore::PluginStreamWin::didReceiveData):
2372
2373 2007-11-15  Justin Garcia  <justin.garcia@apple.com>
2374
2375         Reviewed by Adele Peterson.
2376
2377         <rdar://problem/5497643> Crash at Node::isDescendantOf when switching out of Edit HTML Source mode
2378         
2379         A textarea that contained the selection was removed but the selection wasn't cleared,
2380         and we'd crash in code that assumed a valid, in-document selection.
2381
2382         * editing/SelectionController.cpp:
2383         (WebCore::removingNodeRemovesPosition): Clear the selection if the node being removed is the
2384         shadowAncestorNode of the node that contains the position, not just if the node being removed
2385         contains that shadowAncestorNode.
2386
2387 2007-11-15  Nikolas Zimmermann  <zimmermann@kde.org>
2388
2389         Reviewed by Maciej.
2390
2391         Fix logic error: calculateGlyphBoundaries takes RTL text into account itself, no need to adjust offsets before.
2392
2393         * rendering/SVGInlineTextBox.cpp:
2394         (WebCore::SVGInlineTextBoxClosestCharacterToPositionWalker::chunkPortionCallback):
2395         (WebCore::SVGInlineTextBoxSelectionRectWalker::chunkPortionCallback):
2396
2397 2007-11-15  Anders Carlsson  <andersca@apple.com>
2398
2399         Reviewed by Brady.
2400
2401         <rdar://problem/5562470>
2402         openDatabase does not work when the version string is empty
2403
2404         If the string is empty, pass a real empty string to sqlite3_bind_text16.
2405         
2406         * platform/sql/SQLiteStatement.cpp:
2407         (WebCore::SQLiteStatement::bindText):
2408
2409 2007-11-15  Anders Carlsson  <andersca@apple.com>
2410
2411         Reviewed by Brady.
2412
2413         Get rid of SQLiteStatement::bindText and rename bindText16 to bindText.
2414         Remove the copy parameter from bindText and bindBlob and always copy passed in data instead.
2415
2416         * loader/icon/IconDatabase.cpp:
2417         (WebCore::IconDatabase::setIconIDForPageURLInSQLDatabase):
2418         (WebCore::IconDatabase::removePageURLFromSQLDatabase):
2419         (WebCore::IconDatabase::getIconIDForIconURLFromSQLDatabase):
2420         (WebCore::IconDatabase::addIconURLToSQLDatabase):
2421         (WebCore::IconDatabase::getImageDataForIconURLFromSQLDatabase):
2422         (WebCore::IconDatabase::writeIconSnapshotToSQLDatabase):
2423         * platform/sql/SQLiteStatement.cpp:
2424         (WebCore::SQLiteStatement::prepare):
2425         * platform/sql/SQLiteStatement.h:
2426         * storage/Database.cpp:
2427         (WebCore::setTextValueInDatabase):
2428         * storage/DatabaseTracker.cpp:
2429         (WebCore::DatabaseTracker::fullPathForDatabase):
2430         (WebCore::DatabaseTracker::databaseNamesForOrigin):
2431         (WebCore::DatabaseTracker::addDatabase):
2432
2433 2007-11-14  Brady Eidson <beidson@apple.com>
2434
2435         Rubberstamped by Sam
2436
2437         * platform/SecurityOrigin.h: Lets make this an unsigned short and *not* rule out half the possible ports?
2438
2439 2007-11-14  Alexey Proskuryakov  <ap@webkit.org>
2440
2441         Reviewed by Justin Garcia.
2442
2443         http://bugs.webkit.org/show_bug.cgi?id=15781
2444         REGRESSION: Ligatures fail to form when typing in Devanagari (because WebKit can't handle
2445         a marked range that covers half of a composed character sequence)
2446
2447         Test: platform/mac/editing/input/devanagari-ligature.html
2448
2449         This fix is somewhat of a hack, as it asks editing commands to work with invalid selections.
2450         However, this is not entirely new for them, as Roman accents are typed in a similar manner.
2451
2452         In the future, we probably want to make commands work with ranges (or Positions explicitly).
2453
2454         * editing/Editor.cpp:
2455         (WebCore::Editor::selectComposition): Force selection to composition range.
2456         * editing/InsertTextCommand.cpp:
2457         (WebCore::InsertTextCommand::input): Force ending selection to inserted text range.
2458
2459 2007-11-14  Beth Dakin  <bdakin@apple.com>
2460
2461         Reviewed by Hyatt.
2462
2463         Fix for <rdar://problem/5540855> REGRESSION: Combination of client-
2464         side image map and <a> tag is not working properly (15522)
2465
2466         * html/HTMLMapElement.cpp:
2467         (WebCore::HTMLMapElement::checkDTD): Allow <map> to have both block 
2468         and inline children rather than just block children. This matches 
2469         Firefox. 
2470
2471 2007-11-14  Justin Garcia  <justin.garcia@apple.com>
2472
2473         Reviewed by Alexey Proskuryakov.
2474
2475         <rdar://problem/5546763> CrashTracer: [USER] 362 crashes at WebCore::DeleteSelectionCommand::mergeParagraphs
2476
2477         * editing/DeleteSelectionCommand.cpp:
2478         (WebCore::DeleteSelectionCommand::handleGeneralDelete): 
2479         Removed an irrelevant FIXME.
2480         (WebCore::DeleteSelectionCommand::mergeParagraphs): If the block that contained the end of the selection
2481         hasn't been removed but has been emptied by deletion, we would to try and fail to create a VisiblePosition
2482         inside that block, which could lead to a crash.  If that happens, there's no content in the block to move,
2483         so just remove the block and return.
2484         Preserve m_needPlaceholder during the call to moveParagraphs, since it may change it and since it does
2485         its own placeholder insertion when necessary.
2486         (WebCore::DeleteSelectionCommand::doApply): No need to check m_needPlaceholder before calling mergeParagraphs,
2487         because it handles preserving m_needPlaceholder when it calls moveParagraphs.
2488         
2489 2007-11-14  Timothy Hatcher  <timothy@apple.com>
2490
2491         Reviewed by Adam.
2492
2493         Bug 14380: Long DOM ancestry breadcrumb lists get cut off
2494         http://bugs.webkit.org/show_bug.cgi?id=14380
2495
2496         The breadcumbs will now be compacted and collapsed if there isn't enough room
2497         to show everything. The collapsing algorithm always affects the crumbs that
2498         are farthest away from the selected or hovered crumb first.
2499
2500         * page/inspector/DocumentPanel.js:
2501         * page/inspector/inspector.css:
2502
2503 2007-11-14  Anders Carlsson  <andersca@apple.com>
2504
2505         Use the correct include path.
2506         
2507         * platform/Cursor.h:
2508         * plugins/win/PluginPackageWin.h:
2509         * plugins/win/PluginStreamWin.h:
2510
2511 2007-11-13  Brady Eidson  <beidson@apple.com>
2512
2513         Reviewed by Adam
2514
2515         http://bugs.webkit.org/show_bug.cgi?id=15976 - ASSERT/crash when SQLTransactionCallback throws an exception
2516
2517         * storage/SQLTransaction.cpp:
2518         (WebCore::SQLTransaction::deliverTransactionCallback): Make a transaction error for the case where the 
2519           SQLTransactionCallback fails
2520         (WebCore::SQLTransaction::deliverTransactionErrorCallback): Don't assert on the error callback, but null check it
2521           and make the commit/rollback decision accordingly
2522
2523 2007-11-13  Oliver Hunt  <oliver@apple.com>
2524
2525         Reviewed by Anders.
2526
2527         <rdar://problem/5365030> calling dataWithPDFInsideRect on an SVG with a gradient crashes (14780)
2528
2529         When drawing directly to PDF CG may delay the use of the gradient function until outside our
2530         standard drawing path, which in turn could let us invalidate the caches before they were used.
2531
2532         To work around this we now store the cached stops in a RefCounted object, so that we can ensure
2533         that cache exists as long as required.
2534         
2535         * platform/graphics/svg/SVGPaintServerGradient.cpp:
2536         (WebCore::SVGPaintServerGradient::SVGPaintServerGradient):
2537         * platform/graphics/svg/SVGPaintServerGradient.h:
2538         * platform/graphics/svg/cg/SVGPaintServerGradientCg.cpp:
2539         (WebCore::cgGradientCallback):
2540         (WebCore::CGShadingRefForLinearGradient):
2541         (WebCore::CGShadingRefForRadialGradient):
2542         (WebCore::SVGPaintServerGradient::updateQuartzGradientStopsCache):
2543
2544 2007-11-13  Anders Carlsson  <andersca@apple.com>
2545
2546         Fix Windows build.
2547         
2548         * platform/Cursor.h:
2549         * plugins/win/PluginPackageWin.h:
2550         * plugins/win/PluginStreamWin.h:
2551
2552 2007-11-13  Geoffrey Garen  <ggaren@apple.com>
2553
2554         Reviewed by Anders Carlsson.
2555
2556         Renamed Shared to RefCounted.
2557
2558         * ForwardingHeaders/wtf/RefCounted.h: Copied from WebCore/ForwardingHeaders/wtf/Shared.h.
2559         * ForwardingHeaders/wtf/Shared.h: Removed.
2560         * bindings/js/JSSVGPODTypeWrapper.h:
2561         * css/CSSFontFace.h:
2562         * css/CSSRuleList.h:
2563         * css/Counter.h:
2564         * css/Pair.h:
2565         * css/Rect.h:
2566         * css/StyleBase.h:
2567         * css/StyleSheetList.h:
2568         * dom/Attribute.h:
2569         * dom/Clipboard.h:
2570         * dom/DOMImplementation.h:
2571         * dom/Event.h:
2572         * dom/EventListener.h:
2573         * dom/NamedNodeMap.h:
2574         * dom/NodeFilter.h:
2575         * dom/NodeFilterCondition.h:
2576         * dom/NodeList.h:
2577         * dom/QualifiedName.h:
2578         * dom/Range.h:
2579         * dom/RangeException.h:
2580         * dom/RegisteredEventListener.h:
2581         * dom/Traversal.h:
2582         * editing/EditCommand.h:
2583         * history/BackForwardList.h:
2584         * history/CachedPage.h:
2585         * history/HistoryItem.cpp:
2586         (WebCore::HistoryItem::HistoryItem):
2587         * history/HistoryItem.h:
2588         * html/CanvasGradient.h:
2589         * html/CanvasPattern.h:
2590         * html/CanvasRenderingContext2D.h:
2591         * html/CanvasStyle.h:
2592         * html/HTMLCollection.h:
2593         * html/MediaError.h:
2594         * html/TimeRanges.h:
2595         * html/VoidCallback.h:
2596         * ksvg2/css/SVGRenderStyle.cpp:
2597         (WebCore::SVGRenderStyle::SVGRenderStyle):
2598         * ksvg2/css/SVGRenderStyle.h:
2599         * ksvg2/css/SVGRenderStyleDefs.cpp:
2600         (StyleFillData::StyleFillData):
2601         (StyleStrokeData::StyleStrokeData):
2602         (StyleStopData::StyleStopData):
2603         (StyleTextData::StyleTextData):
2604         (StyleClipData::StyleClipData):
2605         (StyleMaskData::StyleMaskData):
2606         (StyleMarkerData::StyleMarkerData):
2607         (StyleMiscData::StyleMiscData):
2608         * ksvg2/css/SVGRenderStyleDefs.h:
2609         * ksvg2/svg/SVGAngle.cpp:
2610         (WebCore::SVGAngle::SVGAngle):
2611         * ksvg2/svg/SVGAngle.h:
2612         * ksvg2/svg/SVGAnimatedTemplate.h:
2613         * ksvg2/svg/SVGElementInstanceList.h:
2614         * ksvg2/svg/SVGException.h:
2615         * ksvg2/svg/SVGList.h:
2616         * ksvg2/svg/SVGPathSeg.h:
2617         * ksvg2/svg/SVGPreserveAspectRatio.cpp:
2618         (WebCore::SVGPreserveAspectRatio::SVGPreserveAspectRatio):
2619         * ksvg2/svg/SVGPreserveAspectRatio.h:
2620         * ksvg2/svg/SVGRenderingIntent.h:
2621         * ksvg2/svg/SVGTransform.h:
2622         * ksvg2/svg/SVGUnitTypes.h:
2623         * loader/DocumentLoader.h:
2624         * loader/FormState.h:
2625         * loader/ResourceLoader.h:
2626         * loader/TextResourceDecoder.h:
2627         * loader/icon/IconRecord.h:
2628         * page/BarInfo.h:
2629         * page/Console.h:
2630         * page/DOMSelection.h:
2631         * page/DOMWindow.h:
2632         * page/Frame.h:
2633         * page/History.h:
2634         * page/InspectorController.cpp:
2635         * page/Plugin.h:
2636         * page/Screen.h:
2637         * platform/ArrayImpl.h:
2638         * platform/CString.h:
2639         * platform/Cursor.h:
2640         * platform/DeprecatedValueListImpl.cpp:
2641         (WebCore::DeprecatedValueListImpl::Private::Private):
2642         * platform/FileChooser.h:
2643         * platform/FontFallbackList.h:
2644         * platform/FontFamily.cpp:
2645         (WebCore::FontFamily::FontFamily):
2646         * platform/FontFamily.h:
2647         * platform/FontSelector.h:
2648         * platform/GlyphPageTreeNode.h:
2649         * platform/PopupMenu.h:
2650         * platform/RegularExpression.cpp:
2651         * platform/ScrollBar.h:
2652         * platform/SharedBuffer.h:
2653         * platform/StringImpl.h:
2654         * platform/graphics/Icon.h:
2655         * platform/graphics/svg/SVGResource.h:
2656         * platform/network/FormData.cpp:
2657         (WebCore::FormData::FormData):
2658         * platform/network/FormData.h:
2659         * platform/network/ResourceHandle.h:
2660         * platform/network/ResourceHandleClient.h:
2661         * rendering/RenderStyle.cpp:
2662         (WebCore::StyleSurroundData::StyleSurroundData):
2663         (WebCore::StyleBoxData::StyleBoxData):
2664         (WebCore::StyleVisualData::StyleVisualData):
2665         (WebCore::StyleBackgroundData::StyleBackgroundData):
2666         (WebCore::StyleMarqueeData::StyleMarqueeData):
2667         (WebCore::StyleFlexibleBoxData::StyleFlexibleBoxData):
2668         (WebCore::StyleMultiColData::StyleMultiColData):
2669         (WebCore::StyleTransformData::StyleTransformData):
2670         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
2671         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
2672         (WebCore::StyleInheritedData::StyleInheritedData):
2673         * rendering/RenderStyle.h:
2674         * rendering/SVGCharacterLayoutInfo.h:
2675         (WebCore::SVGCharOnPath::SVGCharOnPath):
2676         * storage/SQLResultSetRowList.h:
2677         * xml/DOMParser.h:
2678         * xml/XMLHttpRequest.h:
2679         * xml/XMLSerializer.h:
2680         * xml/XPathEvaluator.h:
2681         * xml/XPathExpression.h:
2682         * xml/XPathNSResolver.h:
2683         * xml/XPathResult.h:
2684         * xml/XPathValue.h:
2685         * xml/XSLTProcessor.h:
2686
2687 2007-11-13  Brady Eidson  <beidson@apple.com>
2688
2689         Reviewed by Mark Rowe
2690
2691         Remove errantly added files, and fix the idl (for reference's sake)
2692
2693         * storage/JSCustomSQLStatementCallback.h: Removed.
2694         * storage/JSCustomSQLStatementErrorCallback.h: Removed.
2695         * storage/JSCustomSQLTransactionCallback.h: Removed.
2696         * storage/JSCustomSQLTransactionErrorCallback.h: Removed.
2697         * storage/SQLStatementCallback.idl:
2698
2699 2007-11-13  Adam Roben  <aroben@apple.com>
2700
2701         Fix a bug and improve upon Brady's fix
2702
2703         Reviewed by Anders.
2704
2705         * bindings/js/JSSQLTransactionCustom.cpp:
2706         (WebCore::JSSQLTransaction::executeSql): Made the code a little
2707         clearer and more correct.
2708         * loader/icon/IconDatabase.cpp: Put parentheses around the expansion
2709         of IS_ICON_SYNC_THREAD() so that ASSERT_NOT_SYNC_THREAD() does the
2710         comparison it meant to.
2711
2712 2007-11-13  Sam Weinig  <sam@webkit.org>
2713
2714         Fix Qt and Gtk builds.
2715
2716         * WebCore.pro: Remove non-generated idl files.
2717
2718 2007-11-13  Mark Rowe  <mrowe@apple.com>
2719
2720         Remove removed file from the project.
2721
2722         * WebCore.pro:
2723
2724 2007-11-13  Brady Eidson  <beidson@apple.com>
2725
2726         Release build fix
2727
2728         * bindings/js/JSSQLTransactionCustom.cpp:
2729         (WebCore::JSSQLTransaction::executeSql):
2730
2731 2007-11-13  Adam Roben  <aroben@apple.com>
2732
2733         Add WindowMessageBroadcaster
2734
2735         This class is used to listen in on messages sent to HWNDs. Multiple
2736         WindowMessageListeners can be notified about messages sent to a single
2737         HWND, and one WindowMessageListener can listen to messages from
2738         multiple HWNDs.
2739
2740         Reviewed by Ada.
2741
2742         * WebCore.vcproj/WebCore.vcproj: Added new files to project.
2743         * platform/win/WindowMessageBroadcaster.cpp: Added.
2744         (WebCore::instancesMap): Static helper.
2745         (WebCore::WindowMessageBroadcaster::addListener): Registers a listener
2746         for a particular HWND.
2747         (WebCore::WindowMessageBroadcaster::removeListener): Removes a
2748         listener for a particular HWND.
2749         (WebCore::WindowMessageBroadcaster::WindowMessageBroadcaster):
2750         (WebCore::WindowMessageBroadcaster::~WindowMessageBroadcaster):
2751         (WebCore::WindowMessageBroadcaster::destroy): Removes this broadcaster
2752         from the instancesMap, removes all of its listeners, unsubclasses the
2753         window, and deletes the broadcaster.
2754         (WebCore::WindowMessageBroadcaster::unsubclassWindow): Unsubclasses
2755         the window (which means that SubclassedWndProc won't be called again
2756         for this window).
2757         (WebCore::WindowMessageBroadcaster::SubclassedWndProc): Notifies all
2758         the listeners about every message sent to the HWND
2759         * platform/win/WindowMessageBroadcaster.h: Added.
2760         (WebCore::WindowMessageBroadcaster::listeners):
2761         (WebCore::WindowMessageBroadcaster::originalWndProc):
2762         * platform/win/WindowMessageListener.h: Added.
2763
2764 2007-11-13  Geoffrey Garen  <ggaren@apple.com>
2765
2766         Reviewed by Sam Weinig.
2767
2768         Moved Shared.h into wtf so it could be used in more places. Retained 
2769         TreeShared, but moved it to its own file, TreeShared.h.
2770
2771         * ForwardingHeaders/wtf/Shared.h: Added.
2772         * WebCore.xcodeproj/project.pbxproj:
2773         * bindings/js/JSSVGPODTypeWrapper.h:
2774         * css/CSSFontFace.h:
2775         * css/CSSRuleList.h:
2776         * css/Counter.h:
2777         * css/Pair.h:
2778         * css/Rect.h:
2779         * css/StyleBase.h:
2780         * css/StyleSheetList.h:
2781         * dom/Clipboard.h:
2782         * dom/DOMImplementation.h:
2783         * dom/Event.h:
2784         * dom/EventListener.h:
2785         * dom/NamedNodeMap.h:
2786         * dom/NodeFilterCondition.h:
2787         * dom/NodeList.h:
2788         * dom/Range.h:
2789         * dom/RangeException.h:
2790         * dom/RegisteredEventListener.h:
2791         * dom/Traversal.h:
2792         * history/BackForwardList.h:
2793         * history/CachedPage.h:
2794         * history/HistoryItem.h:
2795         * html/CanvasGradient.h:
2796         * html/CanvasPattern.h:
2797         * html/HTMLCollection.h:
2798         * html/MediaError.h:
2799         * html/TimeRanges.h:
2800         * html/VoidCallback.h:
2801         * ksvg2/css/SVGRenderStyleDefs.h:
2802         * ksvg2/svg/SVGAnimatedTemplate.h:
2803         * ksvg2/svg/SVGElementInstanceList.h:
2804         * ksvg2/svg/SVGList.h:
2805         * ksvg2/svg/SVGPathSeg.h:
2806         * ksvg2/svg/SVGPreserveAspectRatio.h:
2807         * ksvg2/svg/SVGRenderingIntent.h:
2808         * ksvg2/svg/SVGTransform.h:
2809         * ksvg2/svg/SVGUnitTypes.h:
2810         * loader/DocumentLoader.h:
2811         * loader/FormState.h:
2812         * loader/ResourceLoader.h:
2813         * loader/TextResourceDecoder.h:
2814         * loader/icon/IconRecord.h:
2815         * page/BarInfo.h:
2816         * page/Console.h:
2817         * page/DOMSelection.h:
2818         * page/DOMWindow.h:
2819         * page/History.h:
2820         * page/InspectorController.cpp:
2821         * page/Plugin.h:
2822         * page/Screen.h:
2823         * platform/ArrayImpl.h:
2824         * platform/CString.h:
2825         * platform/DeprecatedValueListImpl.cpp:
2826         * platform/FontFallbackList.h:
2827         * platform/FontFamily.h:
2828         * platform/FontSelector.h:
2829         * platform/GlyphPageTreeNode.h:
2830         * platform/PopupMenu.h:
2831         * platform/RegularExpression.cpp:
2832         * platform/ScrollBar.h:
2833         * platform/Shared.h: Removed.
2834         * platform/SharedBuffer.h:
2835         * platform/StringImpl.h:
2836         * platform/graphics/Icon.h:
2837         * platform/graphics/svg/SVGResource.h:
2838         * platform/network/FormData.h:
2839         * platform/network/ResourceHandleClient.h:
2840         * rendering/RenderStyle.h:
2841         * rendering/SVGCharacterLayoutInfo.h:
2842         * storage/SQLResultSetRowList.h:
2843         * xml/DOMParser.h:
2844         * xml/XMLSerializer.h:
2845         * xml/XPathEvaluator.h:
2846         * xml/XPathExpression.h:
2847         * xml/XPathNSResolver.h:
2848         * xml/XPathResult.h:
2849
2850 2007-11-13  Brady Eidson  <beidson@apple.com>
2851
2852         JS bindings by Anders, reviewed by Brady
2853         WebCore changes by Brady, reviewed by Anders and Tim
2854
2855         Adapt to the new iteration of the HTML5 client-side storage spec.
2856
2857         Based largely on implementation feedback we generated in landing our first version of this API and also
2858         on the input of others in the community, the database spec went through a large overhaul that addresses
2859         many concerns.  Amongst other changes/improvements:
2860         - SQLTransaction object is added and all transactions are explicit.  In addition, since the API manages
2861           transactions explicitly, transaction-related language in SQL statements is disallowed
2862         - executeSql() is now on a transaction object instead of the database object.
2863         - Database.changeVersion() now takes place within the context of a transaction.  Therefore the version 
2864           change can be atomic along with the statements that modify the DB schema
2865
2866         Most of the logic now takes place during the "transaction steps," which the specification clearly lays out
2867         as a chain of events on the SQLTransaction object where processing is handed off between being processed 
2868         asynchronously and calling back up to javascript.  To accomplish this voodoo, SQLTransaction has a series of 
2869         methods that roughly match up with the "transaction steps" and it keeps a pointer to the next step.
2870
2871         * DerivedSources.make:
2872         * WebCore.xcodeproj/project.pbxproj:
2873
2874         * bindings/js/JSDatabaseCustom.cpp:
2875         (WebCore::JSDatabase::changeVersion): Adapt to the new API
2876         (WebCore::JSDatabase::transaction): Added
2877
2878         * bindings/js/JSSQLTransactionCustom.cpp: Added.
2879         (WebCore::JSSQLTransaction::executeSql): Added
2880
2881         * page/DOMWindow.cpp:
2882         (WebCore::DOMWindow::openDatabase): Add the new arguments
2883         * page/DOMWindow.h:
2884         * page/DOMWindow.idl:
2885
2886         * page/inspector/DatabasePanel.js: Use the new API
2887
2888         * storage/ChangeVersionWrapper.cpp: Added.  Implementation of "SQLTransactionWrapper" that enforces
2889           changing the version of the database
2890         (WebCore::ChangeVersionWrapper::ChangeVersionWrapper):
2891         (WebCore::ChangeVersionWrapper::performPreflight):
2892         (WebCore::ChangeVersionWrapper::performPostflight):
2893         * storage/ChangeVersionWrapper.h: Added.
2894         (WebCore::ChangeVersionWrapper::sqlError):
2895
2896         * storage/Database.cpp: Removed the "main thread" and "background thread" sqlite handles as all sqlite operations can now
2897           happen solely on the background thread - most of these changes result from that change
2898         (WebCore::Database::Database): Removed an obsolete FIXME
2899         (WebCore::Database::openAndVerifyVersion): 
2900         (WebCore::Database::getVersionFromDatabase):
2901         (WebCore::Database::setVersionInDatabase):
2902         (WebCore::Database::versionMatchesExpected): Atomically guarantee that the current version and expected version are the same
2903         (WebCore::Database::performOpenAndVerify):
2904         (WebCore::Database::performTransactionStep): Added, as a hook for the DatabaseTransactionTask on the DatabaseThread
2905         (WebCore::Database::changeVersion): Changed for the new API from JS
2906         (WebCore::Database::transaction): Added, for the new API from JS
2907         (WebCore::Database::scheduleTransaction): Add a transaction to this Database's transaction queue
2908         (WebCore::Database::scheduleTransactionStep): Schedule the current transaction to be called on the background thread
2909         (WebCore::Database::scheduleTransactionCallback): Schedule the current transaction to perform a callback on the main thread
2910         (WebCore::Database::performGetTableNames):
2911         (WebCore::Database::deliverAllPendingCallbacks):
2912         (WebCore::Database::deliverPendingCallback):
2913         (WebCore::Database::setExpectedVersion):
2914         * storage/Database.h: 
2915         * storage/Database.idl:
2916
2917         * storage/DatabaseTask.cpp:  Changed DatabaseTask to create a mutex on demand, and use the existence of that mutex
2918           to replace the m_synchronous flag
2919         (WebCore::DatabaseTask::performTask):
2920         (WebCore::DatabaseTask::lockForSynchronousScheduling):
2921         (WebCore::DatabaseTask::waitForSynchronousCompletion):
2922         (WebCore::DatabaseTransactionTask::DatabaseTransactionTask):
2923         * storage/DatabaseTask.h:
2924
2925         * storage/SQLError.h: New API object
2926
2927         * storage/SQLResultSet.cpp:
2928         (WebCore::SQLResultSet::SQLResultSet): Small changes to the API object
2929         * storage/SQLResultSet.h:
2930         * storage/SQLResultSet.idl:
2931
2932         * storage/SQLStatement.cpp: Added.
2933         (WebCore::SQLStatement::SQLStatement):
2934         (WebCore::SQLStatement::execute): Actually execute the sql statement on the SQLiteDatabase if it's still valid
2935         (WebCore::SQLStatement::setVersionMismatchedError): Flag this statement as bad before it even starts in case
2936           of an actual version vs. expected version mismatch
2937         (WebCore::SQLStatement::performCallback): Call the right callback (SQLStatement or SQLStatementError) for this statement
2938         * storage/SQLStatement.h: Added.
2939         (WebCore::SQLStatement::hasStatementCallback):
2940         (WebCore::SQLStatement::hasStatementErrorCallback):
2941         (WebCore::SQLStatement::sqlError): Get the error for this statement, if any
2942
2943         * storage/SQLTransaction.cpp: Added.
2944         (WebCore::SQLTransaction::SQLTransaction):
2945         (WebCore::SQLTransaction::executeSQL): Entry point for the API from JS
2946         (WebCore::SQLTransaction::enqueueStatement): Add a new statement onto the queue
2947         (WebCore::SQLTransaction::performNextStep): Call the method for the next step
2948         (WebCore::SQLTransaction::performPendingCallback): Call the method for the pending callback
2949         (WebCore::SQLTransaction::openTransactionAndPreflight): Open a transaction to the database and preflight 
2950           using the SQLTransactionWrapper, if any
2951         (WebCore::SQLTransaction::deliverTransactionCallback): Deliver the transaction callback to the javascript thread
2952         (WebCore::SQLTransaction::scheduleToRunStatements): Convinience to schedule this transaction on the database thread 
2953           and make runStatements() the next step
2954         (WebCore::SQLTransaction::runStatements): Start running the sql statements queued up for this transaction 
2955         (WebCore::SQLTransaction::getNextStatement): Bring the next statement off the queue
2956         (WebCore::SQLTransaction::runCurrentStatement): Execute the current statement
2957         (WebCore::SQLTransaction::deliverStatementCallback): Deliver the SQLStatementCallback for this statement
2958         (WebCore::SQLTransaction::postflightAndCommit): Postflight the transaction using SQLTransactionWrapper and commit it
2959         (WebCore::SQLTransaction::handleTransactionError): Make the right call for any error that occurred on the Transaction
2960         (WebCore::SQLTransaction::deliverTransactionErrorCallback): Deliver the SQLTransactionErrorCallback
2961         (WebCore::SQLTransaction::cleanupAfterTransactionErrorCallback): Either do a final commit or rollback to cleanup the
2962           transaction after it error'ed out
2963         * storage/SQLTransaction.h:
2964         (WebCore::SQLTransactionWrapper::~SQLTransactionWrapper): 
2965         (WebCore::SQLTransaction::database):
2966         * storage/SQLTransaction.idl:
2967
2968         The following were made obsolete by the new version of the API:
2969         * bindings/js/JSCustomSQLCallback.cpp: Removed.
2970         * bindings/js/JSCustomSQLCallback.h: Removed.
2971         * bindings/js/JSCustomVersionChangeCallback.cpp: Removed.
2972         * bindings/js/JSCustomVersionChangeCallback.h: Removed.
2973         * storage/DatabaseCallback.cpp: Removed.
2974         * storage/DatabaseCallback.h: Removed.
2975         * storage/SQLCallback.h: Removed.
2976         * storage/SQLCallback.idl: Removed.
2977         * storage/VersionChangeCallback.h: Removed.
2978         * storage/VersionChangeCallback.idl: Removed.
2979
2980 2007-11-13  Dan Bernstein  <mitz@apple.com>
2981
2982         Reviewed by Beth Dakin.
2983
2984         - fix <rdar://problem/5551163> REGRESSION: Cursor does not change to arrow on "X" button in google maps, making it hard to click
2985
2986         * css/html4.css: Added a 'cursor: auto' rule for links.
2987         * manual-tests/link-cursor-auto.html: Added.
2988
2989 2007-11-13  Dan Bernstein  <mitz@apple.com>
2990
2991         Reviewed by Beth Dakin.
2992
2993         - fix <rdar://problem/5516272> Reproducible crash in RenderObject::setStyle involving going Back from a non-HTML document (Bookmarks view, PDF view)
2994
2995         The root cause for the crash is that when a non-HTML view enters the
2996         frame, the frame's document pointer keeps pointing at the last HTML-type
2997         document it contained. This patch does not address the root cause, but
2998         makes changes to account for that condition.
2999
3000         * loader/FrameLoader.cpp:
3001         (WebCore::FrameLoader::receivedMainResourceError): Do not change the
3002         frame's current document's page cache state here.
3003         (WebCore::FrameLoader::invalidateCurrentItemCachedPage): If the frame's
3004         current document is in fact the history item being invalidated, then
3005         set its page cache state here.
3006
3007 2007-11-12  Antti Koivisto  <antti@apple.com>
3008
3009         Reviewed by Adele.
3010
3011         Fix that 'timeupdate' and 'waiting' events were never dispatched.
3012         
3013         Add explicit m_paused attribute instead of trying to derive paused state from
3014         underlying media. Call updatePlayState() to start/stop media playback
3015         when any attribute that affects active playback state changes. This matches 
3016         specification text.
3017         
3018         Test: http/tests/media/video-play-stall.html
3019
3020         * html/HTMLMediaElement.cpp:
3021         (WebCore::HTMLMediaElement::HTMLMediaElement):
3022         (WebCore::HTMLMediaElement::setReadyState):
3023         (WebCore::HTMLMediaElement::paused):
3024         (WebCore::HTMLMediaElement::play):
3025         (WebCore::HTMLMediaElement::pause):
3026         (WebCore::HTMLMediaElement::checkIfSeekNeeded):
3027         (WebCore::HTMLMediaElement::movieDidEnd):
3028         (WebCore::HTMLMediaElement::updatePlayState):
3029         * html/HTMLMediaElement.h:
3030
3031 2007-11-13  John Sullivan  <sullivan@apple.com>
3032
3033         Reviewed by Darin.
3034
3035         removed recently-added PreferredType concept; we found a better way to do what
3036         ths was accomplishing
3037
3038         * bridge/WindowFeatures.h:
3039         (WebCore::WindowFeatures::WindowFeatures):
3040         removed definition of PreferredType
3041                         
3042         * page/ContextMenuController.cpp:
3043         (WebCore::openNewWindow):
3044         removed use of PreferredType
3045
3046 2007-11-12  Alexey Proskuryakov  <ap@webkit.org>
3047
3048         Reviewed by Darin.
3049
3050         http://bugs.webkit.org/show_bug.cgi?id=15954
3051         Move DOM Selection operations out of SelectionController
3052
3053         No change in functionality.
3054
3055         * editing/SelectionController.cpp:
3056         (WebCore::SelectionController::setSelectedRange):
3057         * editing/SelectionController.h:
3058         * page/DOMSelection.cpp:
3059         (WebCore::DOMSelection::anchorNode):
3060         (WebCore::DOMSelection::baseNode):
3061         (WebCore::DOMSelection::anchorOffset):
3062         (WebCore::DOMSelection::baseOffset):
3063         (WebCore::DOMSelection::focusNode):
3064         (WebCore::DOMSelection::extentNode):
3065         (WebCore::DOMSelection::focusOffset):
3066         (WebCore::DOMSelection::extentOffset):
3067         (WebCore::DOMSelection::isCollapsed):
3068         (WebCore::DOMSelection::type):
3069         (WebCore::DOMSelection::rangeCount):
3070         (WebCore::DOMSelection::collapse):
3071         (WebCore::DOMSelection::collapseToEnd):
3072         (WebCore::DOMSelection::collapseToStart):
3073         (WebCore::DOMSelection::empty):
3074         (WebCore::DOMSelection::setBaseAndExtent):
3075         (WebCore::DOMSelection::setPosition):
3076         (WebCore::DOMSelection::modify):
3077         (WebCore::DOMSelection::extend):
3078         (WebCore::DOMSelection::getRangeAt):
3079         (WebCore::DOMSelection::removeAllRanges):
3080         (WebCore::DOMSelection::addRange):
3081         (WebCore::DOMSelection::deleteFromDocument):
3082         (WebCore::DOMSelection::containsNode):
3083         (WebCore::DOMSelection::selectAllChildren):
3084         (WebCore::DOMSelection::toString):
3085         * page/DOMSelection.h:
3086         Moved all DOM API methods to DOMSelection; changed SelectionController::setSelectedRange()
3087         to return its result directly instead of via an ExceptionCode that no caller wanted.
3088
3089         * editing/Editor.cpp:
3090         (WebCore::Editor::deleteRange):
3091         (WebCore::Editor::removeFormattingAndStyle):
3092         (WebCore::Editor::selectComposition):
3093         (WebCore::Editor::setComposition):
3094         * html/HTMLInputElement.cpp: (WebCore::HTMLInputElement::defaultEventHandler):
3095         Adapted for SelectionController::setSelectedRange() now returning a bool.
3096         SelectionController::toString() is no longer avasilable, use plainText() explicitly.
3097
3098         * WebCore.base.exp: Changed SelectionController::setSelectedRange() signature.
3099
3100 2007-11-12  Dan Bernstein  <mitz@apple.com>
3101
3102         Reviewed by Darin Adler.
3103
3104         - <http://bugs.webkit.org/show_bug.cgi?id=15890>
3105           Most of www.aol.com still redraws unnecessarily when headline/photo section changes
3106
3107         Test: fast/repaint/invisible-objects.html
3108
3109         Avoid repainting invisible blocks if they are enclosed in a layer that
3110         contains no visible objects.
3111
3112         * rendering/RenderBlock.cpp:
3113         (WebCore::RenderBlock::layoutBlock):
3114         * rendering/RenderBox.cpp:
3115         (WebCore::RenderBox::absoluteClippedOverflowRect):
3116
3117 2007-11-12  Timothy Hatcher  <timothy@apple.com>
3118
3119         Reviewed by Mark Rowe.
3120
3121         Prevent selecting a word in the breadcrumb or the styles section when double
3122         clicking on a DOM node in the outline tree.
3123
3124         * page/inspector/DocumentPanel.js: Call preventDefault() when a mousedown event
3125           with a detail of 2 or higher comes in. This prevents the selection.
3126         * page/inspector/inspector.css: Mark the breadcrumb as user-select: none.
3127
3128 2007-11-12  Oliver Hunt  <oliver@apple.com>
3129
3130         Reviewed by John S.
3131
3132         <rdar://problem/5537289> REGRESSION: Dragging a link or an image from an IFrame causes the page to not respond to clicks afterwards (15460)
3133         
3134         EventHandler needs to reset these fields when a drag terminates, otherwise
3135         EventHandler is left in an inconsistent state when a drag is initiated on a
3136         page with multiple frames.
3137
3138         * page/EventHandler.cpp:
3139         (WebCore::EventHandler::cancelDragAndDrop):
3140         (WebCore::EventHandler::performDragAndDrop):
3141         (WebCore::EventHandler::clearDragState):
3142         * page/EventHandler.h:
3143
3144 2007-11-12  Oliver Hunt  <oliver@apple.com>
3145
3146         Reviewed by Darin and Antti.
3147
3148         Return behaviour for 0 sized pattern back to what it was prior to r27704
3149
3150         This change in behaviour broke two layout tests in DRT, so correcting it
3151         corrects existing tests.
3152
3153         * platform/graphics/cg/ImageBufferCG.cpp:
3154
3155 2007-11-12  Timothy Hatcher  <timothy@apple.com>
3156
3157         Reviewed by John.
3158
3159         <rdar://problem/5268311> REGRESSION (Safari 2-3): Exception thrown when calling -[WebDataSource subresources]
3160
3161         * page/mac/WebCoreFrameBridge.mm:
3162         (-[WebCoreFrameBridge getAllResourceDatas:andResponses:]):
3163         If the SharedBuffer is null insert an empty NSData instead of nil.
3164
3165 2007-11-12  Darin Adler  <darin@apple.com>
3166
3167         Reviewed by Tim.
3168
3169         - http://bugs.webkit.org/show_bug.cgi?id=15947
3170           speed up page loading a bit by inlining
3171
3172         * loader/FrameLoader.cpp: (WebCore::FrameLoader::isLocationChange):
3173         Factored out the slow case of isScheduledLocationChangePending into this.
3174
3175         * loader/FrameLoader.h:
3176         (WebCore::FrameLoader::isScheduledLocationChangePending): Added an
3177         inline check of the far and away most common case, where m_scheduledRedirection
3178         is 0; the rest is in the isLocationChange function.
3179
3180 2007-11-12  George Staikos  <staikos@kde.org>
3181
3182         Reviewed by Tim.
3183
3184         Extract the text match marker highlight color into RenderTheme instead
3185         of the hardcoded yellow.
3186
3187         * rendering/InlineTextBox.cpp:
3188         (WebCore::InlineTextBox::paintTextMatchMarker):
3189         * rendering/RenderTheme.cpp:
3190         (WebCore::RenderTheme::platformTextSearchHighlightColor):
3191         * rendering/RenderTheme.h:
3192
3193 2007-11-12  Mark Rowe  <mrowe@apple.com>
3194
3195         Fix deadlock on launch on the Mac.
3196
3197         * loader/icon/IconDatabase.cpp:
3198         (WebCore::IconDatabase::open): Restore unlock that was mistakenly removed in r27717.
3199
3200 2007-11-12  Justin Haygood  <jhaygood@reaktix.com>
3201
3202         Reviewed by Brady.
3203
3204         http://bugs.webkit.org/show_bug.cgi?id=15955
3205         Reimplement threading functions in IconDatabase and SQLiteDatabase in terms of the threading abstractions
3206
3207         * loader/icon/IconDatabase.cpp:
3208         (WebCore::IconDatabase::open):
3209         (WebCore::IconDatabase::close):
3210         * loader/icon/IconDatabase.h:
3211         * platform/sql/SQLiteDatabase.cpp:
3212         (WebCore::SQLiteDatabase::SQLiteDatabase):
3213         (WebCore::SQLiteDatabase::open):
3214         (WebCore::SQLiteDatabase::close):
3215         * platform/sql/SQLiteDatabase.h:
3216
3217 2007-11-12  Adam Roben  <aroben@apple.com>
3218
3219         Windows build fix
3220
3221         * config.h: Touch because VS apparently can't figure out which files
3222         depend on ResourceResponse.h.
3223         * WebCore.vcproj/WebCore.vcproj: Add ResourceResponseBase files to
3224         project and remove old ResourceResponse files.
3225
3226 2007-11-12  Julien Chaffraix  <julien.chaffraix@gmail.com>
3227
3228         Reviewed by Darin.
3229
3230         http://bugs.webkit.org/show_bug.cgi?id=15334
3231         Split ResourceResponse into platform specific files
3232
3233         * WebCore.base.exp:
3234         * WebCore.pro:
3235         * WebCore.vcproj/WebCore.vcproj:
3236         * WebCore.xcodeproj/project.pbxproj:
3237         * platform/network/ResourceResponse.cpp: Removed.
3238         * platform/network/ResourceResponse.h: Removed.
3239         * platform/network/ResourceResponseBase.cpp: Copied from platform/network/ResourceResponse.cpp.
3240         (WebCore::ResourceResponseBase::asResourceResponse):
3241         (WebCore::ResourceResponseBase::isHTTP):
3242         (WebCore::ResourceResponseBase::url):
3243         (WebCore::ResourceResponseBase::setUrl):
3244         (WebCore::ResourceResponseBase::mimeType):
3245         (WebCore::ResourceResponseBase::setMimeType):
3246         (WebCore::ResourceResponseBase::expectedContentLength):
3247         (WebCore::ResourceResponseBase::setExpectedContentLength):
3248         (WebCore::ResourceResponseBase::textEncodingName):
3249         (WebCore::ResourceResponseBase::setTextEncodingName):
3250         (WebCore::ResourceResponseBase::suggestedFilename):
3251         (WebCore::ResourceResponseBase::setSuggestedFilename):
3252         (WebCore::ResourceResponseBase::httpStatusCode):
3253         (WebCore::ResourceResponseBase::setHTTPStatusCode):
3254         (WebCore::ResourceResponseBase::httpStatusText):
3255         (WebCore::ResourceResponseBase::setHTTPStatusText):
3256         (WebCore::ResourceResponseBase::httpHeaderField):
3257         (WebCore::ResourceResponseBase::setHTTPHeaderField):
3258         (WebCore::ResourceResponseBase::httpHeaderFields):
3259         (WebCore::ResourceResponseBase::isAttachment):
3260         (WebCore::ResourceResponseBase::setExpirationDate):
3261         (WebCore::ResourceResponseBase::expirationDate):
3262         (WebCore::ResourceResponseBase::setLastModifiedDate):
3263         (WebCore::ResourceResponseBase::lastModifiedDate):
3264         (WebCore::ResourceResponseBase::updateResourceResponse):
3265         * platform/network/ResourceResponseBase.h: Copied from platform/network/ResourceResponse.h.
3266         (WebCore::ResourceResponseBase::ResourceResponseBase):
3267         * platform/network/cf/ResourceResponse.h: Added.
3268         (WebCore::ResourceResponse::ResourceResponse):
3269         * platform/network/curl/ResourceResponse.h: Added.
3270         (WebCore::ResourceResponse::ResourceResponse):
3271         (WebCore::ResourceResponse::doUpdateResourceResponse):
3272         * platform/network/mac/ResourceResponse.h: Added.
3273         (WebCore::ResourceResponse::ResourceResponse):
3274         * platform/network/qt/ResourceResponse.h: Added.
3275         (WebCore::ResourceResponse::ResourceResponse):
3276         (WebCore::ResourceResponse::doUpdateResourceResponse):
3277
3278 2007-11-11  Justin Haygood  <jhaygood@reaktix.com>
3279
3280         Reviewed by Adam Roben.
3281
3282         http://bugs.webkit.org/show_bug.cgi?id=15939
3283         Adds a currentThread API for use by SQLiteDatabase, etc.
3284
3285         * platform/Threading.h:
3286         * platform/ThreadingNone.cpp:
3287         (WebCore::currentThread):
3288         * platform/gtk/ThreadingGtk.cpp:
3289         (WebCore::identifierByGthreadHandle):
3290         (WebCore::):
3291         * platform/pthreads/ThreadingPthreads.cpp:
3292         (WebCore::identifierByPthreadHandle):
3293         (WebCore::currentThread):
3294
3295 2007-11-11  Dan Bernstein  <mitz@apple.com>
3296
3297         Reviewed by Adam Roben.
3298
3299         - fix http://bugs.webkit.org/show_bug.cgi?id=15942
3300           REGRESSION: Selecting "Edit Html" tab in Blogger causes crash (Assertion failed: isRange())
3301
3302         Test: editing/selection/cleared-by-relayout.html
3303
3304         * editing/Selection.cpp:
3305         (WebCore::Selection::toRange): Check if the selection has been cleared
3306         by updating layout.
3307
3308 2007-11-11  Darin Adler  <darin@apple.com>
3309
3310         Reviewed by Mark Rowe.
3311
3312         - fix line numbers that were off since my recent patch
3313
3314         * platform/SegmentedString.h:
3315         (WebCore::SegmentedSubstring::SegmentedSubstring): Reversed the sense of m_excludeLineNumbers
3316         and rename it to m_doNotExcludeLineNumbers.
3317         (WebCore::SegmentedSubstring::excludeLineNumbers): Updated.
3318         (WebCore::SegmentedSubstring::doNotExcludeLineNumbers): Added.
3319         (WebCore::SegmentedSubstring::setExcludeLineNumbers): Updated.
3320         (WebCore::SegmentedString::advance): Use doNotExcludeLineNumbers to reverse the sense and fix
3321         the regression, but keep the speediness. I accidentally had removed a ! here.
3322
3323         * platform/SegmentedString.cpp:
3324         (WebCore::SegmentedString::advanceSlowCase): Use doNotExcludeLineNumbers.
3325
3326 2007-11-11  Oliver Hunt  <oliver@apple.com>
3327
3328         Reviewed by Darin.
3329
3330         Fix for <rdar://problem/5585334> numfuzz: integer overflows opening
3331         malformed SVG file in WebCore::ImageBuffer::create. Add protection
3332         against a potential overflow.
3333
3334         * platform/graphics/cg/ImageBufferCG.cpp:
3335
3336 2007-11-11  Antti Koivisto  <antti@apple.com>
3337
3338         Reviewed by Darin.
3339
3340         Fix a bunch of cases where the exception code is checked by the function but is not zeroed first.
3341
3342         * bindings/js/kjs_binding.cpp:
3343         (KJS::setDOMException):
3344         * dom/Attr.cpp:
3345         (WebCore::Attr::setPrefix):
3346         * dom/Document.cpp:
3347         (WebCore::Document::createElement):
3348         * dom/Element.cpp:
3349         (WebCore::Element::setPrefix):
3350         * dom/Range.cpp:
3351         (WebCore::Range::setStart):
3352         (WebCore::Range::setEnd):
3353         (WebCore::Range::isPointInRange):
3354         (WebCore::Range::comparePoint):
3355         (WebCore::Range::compareBoundaryPoints):
3356         (WebCore::Range::deleteContents):
3357         (WebCore::Range::processContents):
3358         (WebCore::Range::extractContents):
3359         (WebCore::Range::insertNode):
3360         (WebCore::Range::setStartAfter):
3361         (WebCore::Range::setEndBefore):
3362         (WebCore::Range::setEndAfter):
3363         (WebCore::Range::selectNode):
3364         (WebCore::Range::surroundContents):
3365         (WebCore::Range::setStartBefore):
3366         * editing/TextIterator.cpp:
3367         (WebCore::TextIterator::TextIterator):
3368         * html/CanvasRenderingContext2D.cpp:
3369         (WebCore::CanvasRenderingContext2D::createPattern):
3370         * html/HTMLMediaElement.cpp:
3371         (WebCore::HTMLMediaElement::play):
3372         (WebCore::HTMLMediaElement::pause):
3373         * html/HTMLSelectElement.cpp:
3374         (WebCore::HTMLSelectElement::add):
3375         (WebCore::HTMLSelectElement::setOption):
3376         * xml/XPathEvaluator.cpp:
3377         (WebCore::XPathEvaluator::evaluate):
3378
3379 2007-11-11  Darin Adler  <darin@apple.com>
3380
3381         Reviewed by Mitz.
3382
3383         - http://bugs.webkit.org/show_bug.cgi?id=15945
3384           speed up GraphicsContextCG typical case by skipping roundToDevicePixels
3385
3386         * platform/graphics/cg/GraphicsContextCG.cpp:
3387         (WebCore::GraphicsContext::restorePlatformState): Clear the flag since we no
3388         longer know if the transform is identity or not.
3389         (WebCore::GraphicsContext::strokeArc): Removed an extra set of redundant
3390         CGContextSave/RestoreGState.
3391         (WebCore::GraphicsContext::beginTransparencyLayer): Clear the flag since we no
3392         longer know if the transform is identity or not.
3393         (WebCore::GraphicsContext::endTransparencyLayer): Ditto.
3394         (WebCore::GraphicsContext::scale): Ditto.
3395         (WebCore::GraphicsContext::rotate): Ditto.
3396         (WebCore::GraphicsContext::translate): Ditto.
3397         (WebCore::GraphicsContext::concatCTM): Ditto.
3398         (WebCore::GraphicsContext::roundToDevicePixels): Return quickly if the transform
3399         is known to be identity, and record that fact when we discover it otherwise.
3400
3401         * platform/graphics/cg/GraphicsContextPlatformPrivate.h:
3402         (WebCore::GraphicsContextPlatformPrivate::GraphicsContextPlatformPrivate):
3403         Added a m_userToDeviceTransformKnownToBeIdentity flag, initialized to false.
3404
3405 2007-11-11  Darin Adler  <darin@apple.com>
3406
3407         Reviewed by Mitz.
3408
3409         - http://bugs.webkit.org/show_bug.cgi?id=15944
3410           streamline SegmentedString to speed up parsing
3411
3412         I measured a speed-up of the page load test while developing this patch. I don't
3413         have a precise figure, though.
3414
3415         * html/HTMLTokenizer.h: Removed unneeded lineNumberPtr() function. Also renamed
3416         lineno to m_lineNumber.
3417         * html/HTMLTokenizer.cpp:
3418         (WebCore::HTMLTokenizer::processListing): Don't pass 0 to the advance function
3419         since we don't want to update a line number.
3420         (WebCore::HTMLTokenizer::parseSpecial): Ditto.
3421         (WebCore::HTMLTokenizer::parseComment): Pass the line number data member directly
3422         instead of lineNumberPtr() since the advance function now takes a reference.
3423         (WebCore::HTMLTokenizer::parseServer): Ditto.
3424         (WebCore::HTMLTokenizer::parseProcessingInstruction): Ditto.
3425         (WebCore::HTMLTokenizer::parseText): Ditto.
3426         (WebCore::HTMLTokenizer::parseEntity): Ditto.
3427         (WebCore::HTMLTokenizer::parseTag): Ditto.
3428         (WebCore::HTMLTokenizer::write): Ditto.
3429
3430         * loader/FTPDirectoryDocument.cpp: (WebCore::FTPDirectoryTokenizer::write):
3431         * loader/TextDocument.cpp: (WebCore::TextTokenizer::write):
3432         Don't pass 0 to the advance function.
3433
3434         * platform/SegmentedString.h: (WebCore::SegmentedString::advance): Streamlined
3435         the most common case, and pushed less common cases into a separate function
3436         that is not inlined. Also got rid of a branch by separating the case with a
3437         line number from the case without one.
3438
3439         * platform/SegmentedString.cpp: (WebCore::SegmentedString::advanceSlowCase):
3440         Added. The aforementioned less common cases are here.
3441
3442 2007-11-11  Antti Koivisto  <antti@apple.com>
3443
3444         Forgot to do this review change (and test HTTP commit).
3445
3446         * html/HTMLMediaElement.cpp:
3447         (WebCore::HTMLMediaElement::play):
3448
3449 2007-11-11  Antti Koivisto  <antti@apple.com>
3450
3451         Reviewed by Darin.
3452         
3453         - Update play() and pause() to match current HTML5 draft
3454             - send events asynchronously
3455             - add timeupdate event to pause
3456             - rethrow load() exception, not others
3457         - Use list for async events to get ordering right
3458
3459         Tests: media/video-pause-empty-events.html
3460                media/video-play-empty-events.html
3461                media/video-play-pause-events.html
3462                media/video-play-pause-exception.html
3463
3464         * html/HTMLMediaElement.cpp:
3465         (WebCore::HTMLMediaElement::dispatchEventAsync): 
3466         (WebCore::HTMLMediaElement::asyncEventTimerFired):
3467         (WebCore::HTMLMediaElement::play):
3468         (WebCore::HTMLMediaElement::pause):
3469         * html/HTMLMediaElement.h:
3470
3471 2007-11-11  Nikolas Zimmermann  <zimmermann@kde.org>
3472
3473         Reviewed by Eric.
3474
3475         Fixes: http://bugs.webkit.org/show_bug.cgi?id=6424 (<text>, <tspan> dominant-baseline attribute is not respected)
3476
3477         Add (basic) support for dominant-baseline / alignment-baseline text properties.
3478         Note: there are no official testcases, and no-one implemented it before. Only ASV3
3479               supported dominant-baseline, but not correct it seems.
3480
3481         * rendering/SVGRootInlineBox.cpp:
3482         (WebCore::dominantBaselineToShift):
3483         (WebCore::alignmentBaselineToShift):
3484         (WebCore::SVGRootInlineBox::buildLayoutInformationForTextBox):
3485
3486 2007-11-11  Adam Roben  <aroben@apple.com>
3487
3488         Add wrappers around CoCreateInstance to COMPtr
3489
3490         I followed the example of the Query constructor and query method by
3491         adding a Create constructor and create method.
3492
3493         Reviewed by Darin.
3494
3495         * platform/win/COMPtr.h:
3496         (COMPtr::COMPtr): Added a new constructor that calls
3497         CoCreateInstance.
3498         (COMPtr::create): Added.
3499         (COMPtr::createInstance): Added.
3500
3501 2007-11-11  Alexey Proskuryakov  <ap@nypop.com>
3502
3503         Reviewed by Darin.
3504
3505         http://bugs.webkit.org/show_bug.cgi?id=15896
3506         More editing cleanup
3507
3508         No functionality changes.
3509
3510         * dom/Node.h: Moved several editing-related methods elsewhere.
3511         * dom/Node.cpp: (WebCore::Node::maxCharacterOffset): Renamed from maxOffset()
3512         to highlight that it is a match to offsetInCharacters(), and much different from other
3513         offset-related methods. Added ASSERT_NOT_REACHED(), as callers are supposed to check
3514         offsetInCharacters() before calling this.
3515
3516         * dom/CharacterData.cpp: (WebCore::CharacterData::maxCharacterOffset):
3517         * dom/CharacterData.h: (WebCore::CharacterData::isCharacterDataNode):
3518         Updated for above renamings.
3519
3520         * dom/Comment.{h,cpp}: Removed an override for offsetInCharacters(), which is already present in CharacterData.
3521
3522         * dom/Document.{h,cpp}: Folded updateSelection() into Frame::selectionLayoutChanged().
3523
3524         * dom/Position.h:
3525         * dom/Position.cpp:
3526         (WebCore::Position::uncheckedPreviousOffset): Moved from Node::previousOffset().
3527         (WebCore::Position::uncheckedNextOffset): Moved from Node::NextOffset().
3528         (WebCore::Position::previous): Adapted to the above move.
3529         (WebCore::Position::next): Ditto.
3530         (WebCore::Position::upstream): Removed an isBR() check, since a non-BR element cannot have a BR renderer (I think),
3531         and BR elements are covered by editingIgnoresContent().
3532         (WebCore::Position::downstream): Ditto.
3533         (WebCore::caretMaxRenderedOffset): Moved from Node::caretMaxRenderedOffset().
3534         (WebCore::Position::rendersInDifferentPosition): Updated for the above moves.
3535
3536         * dom/PositionIterator.h: Added a comment describing this class from the original check-in.
3537         * dom/PositionIterator.cpp:
3538         (WebCore::PositionIterator::increment): Updated for the above moves.
3539         (WebCore::PositionIterator::decrement): Ditto.
3540
3541         * dom/ProcessingInstruction.h:
3542         * dom/ProcessingInstruction.cpp: (WebCore::ProcessingInstruction::maxCharacterOffset):
3543         ProcessingInstruction was already returning true from offsetInCharacters(), but didn't override maxCharacterOffset().
3544         I think that implementing it has no actual effect, as PIs are not rendered, but it looks cleaner this way.
3545
3546         * dom/Range.cpp:
3547         (WebCore::Range::selectNodeContents):
3548         * editing/ApplyStyleCommand.cpp:
3549         (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
3550         (WebCore::ApplyStyleCommand::applyInlineStyle):
3551         (WebCore::maxRangeOffset):
3552         (WebCore::ApplyStyleCommand::removeInlineStyle):
3553         (WebCore::ApplyStyleCommand::splitTextAtStartIfNeeded):
3554         (WebCore::ApplyStyleCommand::splitTextAtEndIfNeeded):
3555         (WebCore::ApplyStyleCommand::splitTextElementAtStartIfNeeded):
3556         (WebCore::ApplyStyleCommand::splitTextElementAtEndIfNeeded):
3557         (WebCore::ApplyStyleCommand::mergeEndWithNextIfIdentical):
3558         * editing/CompositeEditCommand.cpp:
3559         (WebCore::CompositeEditCommand::insertNodeAt):
3560         (WebCore::CompositeEditCommand::positionOutsideTabSpan):
3561         * editing/DeleteSelectionCommand.cpp:
3562         (WebCore::DeleteSelectionCommand::handleGeneralDelete):
3563         * editing/InsertLineBreakCommand.cpp:
3564         (WebCore::InsertLineBreakCommand::doApply):
3565         * editing/InsertParagraphSeparatorCommand.cpp:
3566         (WebCore::InsertParagraphSeparatorCommand::doApply):
3567         * editing/InsertTextCommand.cpp:
3568         (WebCore::InsertTextCommand::insertTab):
3569         * editing/visible_units.cpp:
3570         (WebCore::previousLinePosition):
3571         (WebCore::nextLinePosition):
3572         Updated for the above moves.
3573
3574         * editing/Editor.cpp:
3575         (WebCore::Editor::advanceToNextMisspelling): Added a missing rangeCompliantEquivalent() call.
3576
3577         * editing/TextIterator.cpp:
3578         (WebCore::SimplifiedBackwardsTextIterator::SimplifiedBackwardsTextIterator): Changed the condition to obviously
3579         match a maxCharacterOffset() call made after it; hopefully, this doesn't break any border cases.
3580         (WebCore::SimplifiedBackwardsTextIterator::advance): Updated for the above moves.
3581
3582         * editing/htmlediting.h:
3583         * editing/htmlediting.cpp:
3584         (WebCore::canHaveChildrenForEditing): Removed a bogus comment: I don't thin BRs have a special ability to accept
3585         child nodes, other than via DOM manipulation, which is not specific to BRs.
3586         (WebCore::rangeCompliantEquivalent): Removed a check for BR, which is already covered by editingIgnoresContent().
3587         (WebCore::maxDeepOffset): Ditto.
3588         (WebCore::caretMinOffset): Moved from Node. Changed some runtime checks that seemingly cannot fail into assertions.
3589         (WebCore::caretMaxOffset): Ditto.
3590
3591         * page/EventHandler.cpp:
3592         (WebCore::EventHandler::handleMousePressEventSingleClick): Pass 0 to VisiblePosition constructor instead of
3593         caretMinOffset. I didn't want to include htmlediting.h here, and I think that VisiblePosition constructor
3594         will take care of adjusting the offset.
3595
3596         * page/Frame.cpp: (WebCore::Frame::selectionLayoutChanged): Folded Document::updateSelection() here.
3597         * page/mac/WebCoreFrameBridge.mm:
3598         (-[WebCoreFrameBridge smartDeleteRangeForProposedRange:]): Added missing rangeCompliantEquivalent() calls.
3599         * rendering/RenderBlock.cpp: (WebCore::RenderBlock::positionForRenderer): Changed to not round-trip via editing.
3600         Changed some runtime checks that seemingly cannot fail into assertions.
3601
3602 2007-11-11  Darin Adler  <darin@apple.com>
3603
3604         Reviewed by Sam.
3605
3606         - updated for JSRegExp function changes
3607
3608         * platform/RegularExpression.cpp:
3609         (WebCore::RegularExpression::Private::compile):
3610         (WebCore::RegularExpression::match):
3611
3612 2007-11-10  Mark Rowe  <mrowe@apple.com>
3613
3614         Qt Linux build fix.
3615
3616         * platform/UnicodeRange.h:
3617
3618 2007-11-10  Mark Rowe  <mrowe@apple.com>
3619
3620         Qt Windows build fix.
3621
3622         * platform/UnicodeRange.h:
3623
3624 2007-11-10  Nikolas Zimmermann  <zimmermann@kde.org>
3625
3626         Reviewed by Eric.
3627
3628         Fixes: http://bugs.webkit.org/show_bug.cgi?id=15937 (Add glyph-orientation-horizontal/vertical support)
3629         Fixes: http://bugs.webkit.org/show_bug.cgi?id=13971 (text-anchor support on vertical text seems slightly off)
3630
3631         Add glyph-orientation-* support for text & textPath. (90/180/270 and 'auto')
3632         Also fix all vertical text handling - for text & textPath! (especially latin1 characters auto orientation in vertical writing modes)
3633
3634         * WebCore.pro: Add platform/UnicodeRange.cpp to build
3635         * WebCore.xcodeproj/project.pbxproj: Dito.
3636         * rendering/SVGCharacterLayoutInfo.cpp: Respect orientationShiftX/Y & angle in characterTransform()
3637         (WebCore::SVGChar::characterTransform):
3638         * rendering/SVGCharacterLayoutInfo.h: New variables.
3639         (WebCore::SVGCharOnPath::SVGCharOnPath):
3640         (WebCore::SVGChar::SVGChar):
3641         * rendering/SVGRootInlineBox.cpp: Added glyph-orientation-* handling.
3642         (WebCore::glyphOrientationToAngle):
3643         (WebCore::glyphOrientationIsMultiplyOf180Degrees):
3644         (WebCore::calculateGlyphAdvanceAndShiftRespectingOrientation):
3645         (WebCore::cummulatedHeightOfInlineBoxCharacterRange):
3646         (WebCore::cummulatedWidthOrHeightOfTextChunk):
3647         (WebCore::SVGRootInlineBox::buildLayoutInformationForTextBox):
3648
3649 2007-11-10  Timothy Hatcher  <timothy@apple.com>
3650
3651         Reviewed by Sam Weinig.
3652
3653         * page/inspector/StylesSidebarPane.js: Fix the wording of a comment
3654           and switch over to use getUniqueProperties in another place.
3655
3656 2007-11-10  John Sullivan  <sullivan@apple.com>
3657
3658         Reviewed by Sam Weinig
3659
3660         Rest of fix for 5394877
3661
3662         * bindings/js/kjs_window.cpp:
3663         (KJS::Window::isSafeScript):
3664         Don't log unsafe JavaScript attempts in the other version of isSafeScript() if in
3665         private browsing mode either.
3666
3667 2007-11-10  Nikolas Zimmermann  <zimmermann@kde.org>
3668
3669         Reviewed by Oliver.
3670
3671         Fix function name difference - header said 'unicodeRangeForCharacter', actually
3672         implemented function is 'findCharUnicodeRange'. They are not compiled yet.
3673
3674         * platform/UnicodeRange.h:
3675
3676 2007-11-10  Dan Bernstein  <mitz@apple.com>
3677
3678         Reviewed by Darin Adler.
3679
3680         - fix <rdar://problem/5450655> Control-clicking text in a link can surprisingly select only part of the link, should select entire link
3681
3682         No test because context menu events cannot be tested in DumpRenderTree.
3683
3684         * page/EventHandler.cpp:
3685         (WebCore::EventHandler::selectClosestWordOrLinkFromMouseEvent): Added.
3686         If the click occurred in an active link, selects the entire link
3687         element. Otherwise selects the closest word.
3688         (WebCore::EventHandler::sendContextMenuEvent): Call
3689         selectClosestWordOrLinkFromMouseEvent().
3690         * page/EventHandler.h:
3691
3692 2007-11-10  John Sullivan  <sullivan@apple.com>
3693
3694         Reviewed by Tim Hatcher
3695
3696         - fixed <rdar://problem/5394877> Safari should not log unsafe JavaScript attempts when 
3697           in private browsing mode (only an issue if Log JavaScript Exceptions is turned on)
3698
3699         * bindings/js/kjs_window.cpp:
3700         (KJS::Window::isSafeScript):
3701         Don't log unsafe JavaScript attempts to console or chromeClient if in private browsing mode
3702
3703 2007-11-10  Alexey Proskuryakov  <ap@webkit.org>
3704
3705         Reviewed by Darin.
3706
3707         http://bugs.webkit.org/show_bug.cgi?id=15922
3708         Implement more of Mozilla Selection API
3709
3710         Tests: editing/selection/containsNode.html
3711                editing/selection/deleteFromDocument.html
3712                editing/selection/extend.html
3713                editing/selection/selectAllChildren.html
3714
3715         * editing/SelectionController.cpp:
3716         (WebCore::SelectionController::deleteFromDocument):
3717         (WebCore::SelectionController::containsNode):
3718         (WebCore::SelectionController::selectAllChildren):
3719         (WebCore::SelectionController::extend):
3720         * editing/SelectionController.h:
3721         Added deleteFromDocument(), containsNode(), and selectAllChildren(). Reimplemented extend(),
3722         which existed, but didn't match Firefox behavior and wasn't exposed via bindings.
3723         Removed a comment mentioning removeRange(), as this method makes no sense without multiple
3724         selection range support.
3725
3726         * page/DOMSelection.cpp:
3727         (WebCore::DOMSelection::extend):
3728         (WebCore::DOMSelection::deleteFromDocument):
3729         (WebCore::DOMSelection::containsNode):
3730         (WebCore::DOMSelection::selectAllChildren):
3731         * page/DOMSelection.h:
3732         * page/DOMSelection.idl:
3733         Exposed the new methods.
3734
3735 2007-11-10  Alexey Proskuryakov  <ap@webkit.org>
3736
3737         Reviewed by Darin.
3738
3739         http://bugs.webkit.org/show_bug.cgi?id=15892
3740         DOM Range operations are not implemented for ProcessingInstruction nodes
3741
3742         Test: fast/dom/Range/range-processing-instructions.html
3743
3744         * dom/Range.cpp:
3745         (WebCore::Range::processContents): Implemented ProcessingInstruction cases.
3746         (WebCore::Range::checkNodeWOffset): Removed a FIXME - yes, I think that we are supposed
3747         to use ProcessingInstruction.data.
3748
3749 2007-11-09  Timothy Hatcher  <timothy@apple.com>
3750
3751         Reviewed by Mark Rowe.
3752
3753         Bug 12054: Ability to serialize an element subtree (into clipboard?) from the DOM inspector
3754         http://bugs.webkit.org/show_bug.cgi?id=12054
3755
3756         - Add support code for routing copy events to the focused element.
3757         - Implement copying the currently selected DOM node. The node
3758           and it's subtree is copied to the clipboard. If the node has no
3759           outerHTML, the nodeValue is copied (text nodes, etc.)
3760         - Implement copy for the resource sidebar. The URL is copied for the
3761           currently selected resource.
3762
3763         * page/inspector/DocumentPanel.js:
3764         * page/inspector/inspector.js:
3765
3766 2007-11-09  Antti Koivisto  <antti@apple.com>
3767
3768         Reviewed by Adele.
3769
3770         Fix occasional blank video with poster attribute.
3771
3772         * ChangeLog:
3773         * html/HTMLMediaElement.cpp:
3774         (WebCore::HTMLMediaElement::load):
3775         (WebCore::HTMLMediaElement::didRestoreFromCache):
3776         Just calling updateFromElement() does the right thing for both poster image and video.
3777
3778 2007-11-04  Sam Weinig  <sam@webkit.org>
3779
3780         Reviewed by Adam Roben.
3781
3782         <rdar://problem/5435940>
3783         The COM bindings for the DOM should be autogenerated like the other DOM bindings
3784
3785         Initial commit of the autogeneration of the COM DOM Bindings.  No behavior change
3786         is being introduced in this patch and to insure that no conflicts arise, a temporary
3787         prefix of "GEN_" has been used for all the new classes.
3788
3789         The build architecture for these bindings differs slightly from the other autogenerated
3790         bindings.  Instead of building in WebCore and migrating the resuting code to WebKit (as
3791         is done for the Objective-C bindigs currently), the IDLs and generation scripts are
3792         migrated to WebKit and built there.  This is done with a series of scripts and Makefiles.
3793
3794         This commit includes:
3795             - Hand rolled root class/Interface GEN_DOMObject used to facilated object creation
3796               and ref-counting.
3797             - Generating all of the Core DOM and most of HTML and CSS
3798             - Generating Event, EventTarget, and EventListener
3799
3800         * WebCore.vcproj/MigrateIDLAndScripts.make: Added.
3801         * WebCore.vcproj/WebCore.vcproj:
3802         * WebCore.vcproj/migrate-idls.sh: Added.
3803         * bindings/scripts/CodeGenerator.pm:
3804         * bindings/scripts/CodeGeneratorCOM.pm: Added.
3805         * dom/EventListener.h: Make the isWindowEvent parameter default to false
3806         to allow autogeneration based on the IDL.
3807
3808 2007-11-09  Tristan O'Tierney  <tristan@apple.com>
3809
3810         Reviewed by Timothy Hatcher.
3811         
3812         This patch is for the WebKit side of <rdar://problem/5591115>.
3813         We need a way to tell context menu navigations, such as "Open in New Window"
3814         to override any sort of browser preference for tab based navigation.
3815
3816         * bridge/WindowFeatures.h:
3817         (WebCore::WindowFeatures::WindowFeatures):
3818         Added a new struct member var, preferredType
3819         and an accompanying enum type PreferredType
3820         to send a window type recommendation up to the Chrome. 
3821         
3822         * page/ContextMenuController.cpp:
3823         (WebCore::openNewWindow):
3824         Set the window features to recommend a new Window for
3825         "Open in New Window" context menu action.
3826
3827 2007-11-08  Adam Roben  <aroben@apple.com>
3828
3829         Fix <rdar://5483519> Pressing Enter on selected buttons should fire onclick
3830
3831         We now match the behavior of Firefox and IE, which is to always just
3832         send a click event to the focused button when the Enter key is pressed
3833         (previously we were submitting forms directly in some cases).
3834
3835         Reviewed by Adele.
3836
3837         Test: fast/forms/enter-clicks-buttons.html
3838
3839         * html/HTMLButtonElement.cpp:
3840         (WebCore::HTMLButtonElement::defaultEventHandler): Don't do anything
3841         fancy when Enter is pressed on a <button type=button> -- just send a
3842         click event like we do for other button types.
3843         * html/HTMLInputElement.cpp:
3844         (WebCore::HTMLInputElement::defaultEventHandler): Treat type=button
3845         the same way we treat type=submit and type=reset: just send a click
3846         event when Enter is pressed.
3847
3848 2007-11-09  Dan Bernstein  <mitz@apple.com>
3849
3850         Reviewed by Antti Koivisto.
3851
3852         - fix a bug in invisible layer culling: dynamically changing a 
3853           descendant of an invisible layer to be visible did not work
3854
3855         Test: fast/layers/layer-content-visibility-change.html
3856
3857         * rendering/RenderLayer.cpp:
3858         (WebCore::RenderLayer::setHasVisibleContent): If we got visible content,
3859         make sure that our stacking context rebuilds its z-order lists to
3860         include us.
3861
3862 2007-11-09  David Hyatt  <hyatt@apple.com>
3863
3864         Clean up matrix() parsing.  Make sure the first four arguments can be lengths or numbers.  The last two
3865         args can be lengths or numbers or percents.
3866
3867         Reviewed by Beth
3868
3869         * WebCore.xcodeproj/project.pbxproj:
3870         * css/CSSParser.cpp:
3871         (WebCore::TransformOperationInfo::TransformOperationInfo):
3872         (WebCore::CSSParser::parseTransform):
3873         * rendering/RenderStyle.h:
3874         (WebCore::MatrixTransformOperation::apply):
3875
3876 2007-11-09  Beth Dakin  <bdakin@apple.com>
3877
3878         Reviewed by Oliver.
3879
3880         Fix for <rdar://problem/5586370> CSS Transform - incorrect matrix 
3881         math leads to crazy problems
3882
3883         Transform matrices accept the first four parameters as CSS lengths. 
3884         CSS lengths get mapped into WebCore::Lengths as percents by 
3885         WebCore::convertToLength(). Percent lengths cannot call value(). It 
3886         does not yield a correct result and it asserts on Debug builds. 
3887
3888         * rendering/RenderStyle.h:
3889         (WebCore::MatrixTransformOperation::apply): Instead of calling 
3890         value() on the lengths, call calcValue. This fixes the assert and 
3891         the bad rendering. 
3892
3893 2007-11-09  Simon Hausmann  <hausmann@kde.org>
3894
3895         Reviewed by nobody, build/link fix for Qt/Windows.
3896
3897         userIdleTime() is stubbed in win/SystemTimeWin.cpp, so don't
3898         define it twice.
3899
3900         * platform/qt/TemporaryLinkStubs.cpp:
3901
3902 2007-11-09  Simon Hausmann  <hausmann@kde.org>
3903
3904         Reviewed by Holger.
3905
3906         Fix ContextMenu allocation in the Qt port.
3907
3908         Store all items and submenus value based in ContextMenu and ContextMenuItem.
3909         That fixes the crashes when the context menu was populated with sub-menus because
3910         of the use of temporary ContextMenu objects like this:
3911
3912         ContextMenu subMenu(...);
3913         subMenu.appendItem(...);
3914         subMenu.appendItem(...);
3915
3916         subMenuItem.setSubMenu(&subMenu); // temporary pointer, need to _copy_ contents
3917
3918         * platform/ContextMenu.h:
3919         * platform/ContextMenuItem.h:
3920         * platform/PlatformMenuDescription.h:
3921         * platform/qt/ContextMenuItemQt.cpp:
3922         (WebCore::ContextMenuItem::ContextMenuItem):
3923         (WebCore::ContextMenuItem::platformSubMenu):
3924         * platform/qt/ContextMenuQt.cpp:
3925         (WebCore::ContextMenu::ContextMenu):
3926         (WebCore::ContextMenu::~ContextMenu):
3927         (WebCore::ContextMenu::appendItem):
3928         (WebCore::ContextMenu::itemCount):
3929
3930 2007-11-09  Peter Kasting  <zerodpx@gmail.com>
3931
3932         Reviewed by Mark Rowe.
3933
3934         http://bugs.webkit.org/show_bug.cgi?id=15909
3935         Malformed GIFs should not result in memory corruption.
3936
3937         * platform/image-decoders/gif/GIFImageDecoder.cpp:
3938         (WebCore::GIFImageDecoder::haveDecodedRow):
3939
3940 2007-11-08  Timothy Hatcher  <timothy@apple.com>
3941
3942         Reviewed by Sam Weinig.
3943
3944         Some Web Inspector CSS editing changes.
3945         - Only delete the property if all the text is delete or the new user input correctly parses.
3946           This prevents deleting the existing property if the new text is invalid.
3947         - Intercept the Escape key and cancel editing, not saving any changes.
3948
3949         * page/inspector/StylesSidebarPane.js:
3950
3951 2007-11-08  Kevin Ollivier  <kevino@theolliviers.com>
3952
3953         Bakefiles for building WebCore, needed by wx port.
3954
3955         Reviewed by Mark Rowe.
3956
3957         * WebCoreSources.bkl: Added.
3958         * webcore-base.bkl: Added.
3959         * webcore-wx.bkl: Added.
3960
3961 2007-11-08  Justin Haygood  <jhaygood@reaktix.com>
3962
3963         Reviewed by Mark Rowe.
3964
3965         http://bugs.webkit.org/show_bug.cgi?id=15905
3966
3967         Fix builds with HTML 5 Storage support disabled.
3968         ENABLE(DATABASE) needs to be added in a few places.
3969
3970         * page/InspectorController.cpp:
3971         * storage/Database.h:
3972
3973 2007-11-08  Steve Falkenburg  <sfalken@apple.com>
3974
3975         <rdar://problem/5524082> Allow images to be dragged out directly into other apps
3976         
3977         We weren't including CF_HDROP in our image drops.  This broke drag of
3978         images out of the browser window directly into other apps (examples
3979         include notepad, mspaint, msword).
3980         
3981         Reviewed by Oliver, Ada.
3982
3983         * platform/win/ClipboardWin.cpp:
3984         (WebCore::createGlobalImageFileContent): Removed unused variable.
3985         (WebCore::createGlobalHDropContent): Added
3986         (WebCore::writeFileToDataObject): Write HDROP data if available.
3987         (WebCore::writeImageToDataObject): Write HDROP for dragged images.
3988         (WebCore::ClipboardWin::writeURL): Don't write HDROP for dragged URLs.
3989
3990 2007-11-08  Xan Lopez  <xan@gnome.org>
3991
3992         Reviewed by Alp.
3993
3994         http://bugs.webkit.org/show_bug.cgi?id=15908
3995         Use g_object_ref_sink when available
3996
3997         * platform/gtk/PopupMenuGtk.cpp:
3998         (WebCore::PopupMenu::show):
3999         * platform/gtk/ScrollViewGtk.cpp:
4000         (WebCore::ScrollView::setGtkAdjustments):
4001
4002 2007-11-08  Dan Bernstein  <mitz@apple.com>
4003
4004         Reviewed by Beth Dakin.
4005
4006         - fix <rdar://problem/5491922> REGRESSION (Safari 2-3): Flash-based "Cash Optimizer" on etrade.com does not draw completely
4007
4008         Test: fast/dom/length-attribute-mapping.html
4009
4010         * dom/StyledElement.cpp:
4011         (WebCore::StyledElement::addCSSLength): Changed the garbage-stripping
4012         logic to stop after the first "%" or "*" in the string. This allows for
4013         "100%25" to be mapped to "100%" like it is in Firefox and WinIE.
4014
4015 2007-11-08  Kevin McCullough  <kmccullough@apple.com>
4016
4017         - Build fix.
4018
4019         * loader/FrameLoaderClient.h:
4020         * platform/graphics/svg/SVGImageEmptyClients.h:
4021         (WebCore::SVGEmptyFrameLoaderClient::windowObjectCleared):
4022
4023 2007-11-08  Kevin McCullough  <kmccullough@apple.com>
4024
4025         Reviewed by Sam.
4026
4027         - windowObjectCleared() is no longer const.  It needs to setup the
4028         script debugger and cannot be const to do so.
4029
4030         * loader/FrameLoaderClient.h:
4031         * platform/graphics/svg/SVGImageEmptyClients.h:
4032         (WebCore::SVGEmptyFrameLoaderClient::windowObjectCleared):
4033
4034 2007-11-08  Adam Roben  <aroben@apple.com>
4035
4036         Hopeful Windows build fix
4037
4038         * rendering/RenderObject.cpp: Touch this file to make it recompile.
4039
4040 2007-11-08  Sam Weinig  <sam@webkit.org>
4041
4042         Reviewed by Darin.
4043
4044         Convert JavaScript internal function objects to use one class per
4045         function.  This avoids a switch statement inside what used to be
4046         the shared function classes and will allow Shark to better analyze
4047         the code.
4048
4049         To make this switch, the value property of the HashEntry was changed
4050         to a union of an intptr_t (which is used to continue handle valueGetters)
4051         and function pointer which points to a static constructor for the
4052         individual new function objects.
4053
4054         SunSpider claims this is a 1.0% speedup.
4055
4056         - On the WebCore side, I updated CodeGeneratorJS.pm to generate the
4057           new classes and hand updated the remain non-generated (groan) classes.
4058
4059         * bindings/js/JSDOMWindowCustom.cpp:
4060         (WebCore::JSDOMWindow::customGetOwnPropertySlot):
4061         * bindings/js/JSEventTargetNode.cpp:
4062         (WebCore::JSEventTargetNodePrototypeFunctionAddEventListener::callAsFunction):
4063         (WebCore::JSEventTargetNodePrototypeFunctionRemoveEventListener::callAsFunction):
4064         (WebCore::JSEventTargetNodePrototypeFunctionDispatchEvent::callAsFunction):
4065         * bindings/js/JSEventTargetNode.h:
4066         * bindings/js/JSHTMLInputElementBase.cpp:
4067         (WebCore::JSHTMLInputElementBaseFunctionSetSelectionRange::callAsFunction):
4068         (WebCore::JSHTMLInputElementBase::getOwnPropertySlot):
4069         * bindings/js/JSHTMLInputElementBase.h:
4070         (WebCore::JSHTMLInputElementBase::):
4071         * bindings/js/JSXMLHttpRequest.cpp:
4072         (KJS::JSXMLHttpRequestPrototypeFunctionAbort::callAsFunction):
4073         (KJS::JSXMLHttpRequestPrototypeFunctionGetAllResponseHeaders::callAsFunction):
4074         (KJS::JSXMLHttpRequestPrototypeFunctionGetResponseHeader::callAsFunction):
4075         (KJS::JSXMLHttpRequestPrototypeFunctionOpen::callAsFunction):
4076         (KJS::JSXMLHttpRequestPrototypeFunctionSend::callAsFunction):
4077         (KJS::JSXMLHttpRequestPrototypeFunctionSetRequestHeader::callAsFunction):
4078         (KJS::JSXMLHttpRequestPrototypeFunctionOverrideMIMEType::callAsFunction):
4079         (KJS::JSXMLHttpRequestPrototypeFunctionAddEventListener::callAsFunction):
4080         (KJS::JSXMLHttpRequestPrototypeFunctionRemoveEventListener::callAsFunction):
4081         (KJS::JSXMLHttpRequestPrototypeFunctionDispatchEvent::callAsFunction):
4082         * bindings/js/JSXMLHttpRequest.h:
4083         (KJS::JSXMLHttpRequest::impl):
4084         * bindings/js/JSXSLTProcessor.cpp:
4085         (KJS::JSXSLTProcessorPrototypeFunctionImportStylesheet::callAsFunction):
4086         (KJS::JSXSLTProcessorPrototypeFunctionTransformToFragment::callAsFunction):
4087         (KJS::JSXSLTProcessorPrototypeFunctionTransformToDocument::callAsFunction):
4088         (KJS::JSXSLTProcessorPrototypeFunctionSetParameter::callAsFunction):
4089         (KJS::JSXSLTProcessorPrototypeFunctionGetParameter::callAsFunction):
4090         (KJS::JSXSLTProcessorPrototypeFunctionRemoveParameter::callAsFunction):
4091         (KJS::JSXSLTProcessorPrototypeFunctionClearParameters::callAsFunction):
4092         (KJS::JSXSLTProcessorPrototypeFunctionReset::callAsFunction):
4093         * bindings/js/JSXSLTProcessor.h:
4094         * bindings/js/kjs_events.cpp:
4095         (WebCore::JSClipboardPrototypeFunctionClearData::callAsFunction):
4096         (WebCore::JSClipboardPrototypeFunctionGetData::callAsFunction):
4097         (WebCore::JSClipboardPrototypeFunctionSetData::callAsFunction):
4098         (WebCore::JSClipboardPrototypeFunctionSetDragImage::callAsFunction):
4099         * bindings/js/kjs_events.h:
4100         * bindings/js/kjs_navigator.cpp:
4101         (KJS::Plugins::):
4102         (KJS::Navigator::getOwnPropertySlot):
4103         (KJS::Plugins::getOwnPropertySlot):
4104         (KJS::PluginsFunctionRefresh::callAsFunction):
4105         (KJS::NavigatorProtoFuncJavaEnabled::callAsFunction):
4106         * bindings/js/kjs_navigator.h:
4107         (KJS::Navigator::):
4108         * bindings/js/kjs_window.cpp:
4109         (KJS::Window::getOwnPropertySlot):
4110         (KJS::Window::put):
4111         (KJS::WindowProtoFuncAToB::callAsFunction):
4112         (KJS::WindowProtoFuncBToA::callAsFunction):
4113         (KJS::WindowProtoFuncOpen::callAsFunction):
4114         (KJS::WindowProtoFuncScrollBy::callAsFunction):
4115         (KJS::WindowProtoFuncScrollTo::callAsFunction):
4116         (KJS::WindowProtoFuncMoveBy::callAsFunction):
4117         (KJS::WindowProtoFuncMoveTo::callAsFunction):
4118         (KJS::WindowProtoFuncResizeBy::callAsFunction):
4119         (KJS::WindowProtoFuncResizeTo::callAsFunction):
4120         (KJS::WindowProtoFuncSetTimeout::callAsFunction):
4121         (KJS::WindowProtoFuncClearTimeout::callAsFunction):
4122         (KJS::WindowProtoFuncSetInterval::callAsFunction):
4123         (KJS::WindowProtoFuncAddEventListener::callAsFunction):
4124         (KJS::WindowProtoFuncRemoveEventListener::callAsFunction):
4125         (KJS::WindowProtoFuncShowModalDialog::callAsFunction):
4126         (KJS::WindowProtoFuncNotImplemented::callAsFunction):
4127         (KJS::Location::getOwnPropertySlot):
4128         (KJS::Location::put):
4129         (KJS::LocationProtoFuncReplace::callAsFunction):
4130         (KJS::LocationProtoFuncReload::callAsFunction):
4131         (KJS::LocationProtoFuncAssign::callAsFunction):
4132         (KJS::LocationProtoFuncToString::callAsFunction):
4133         * bindings/js/kjs_window.h:
4134         (KJS::Window::):
4135         * bindings/scripts/CodeGeneratorJS.pm:
4136
4137 2007-11-08  Mark Rowe  <mrowe@apple.com>
4138
4139         Fix the Gtk, Qt and Wx builds.
4140
4141         * platform/gtk/TemporaryLinkStubs.cpp:
4142         * platform/qt/TemporaryLinkStubs.cpp:
4143         * platform/wx/TemporaryLinkStubs.cpp:
4144
4145 2007-11-08  Mark Rowe  <mrowe@apple.com>
4146
4147         Not reviewed.  Fix two instances of includes using the wrong case in the filename.
4148
4149         * platform/graphics/mac/MoviePrivateQTKit.mm:
4150         * platform/wx/MimeTypeRegistryWx.cpp:
4151
4152 2007-11-08  Darin Adler  <darin@apple.com>
4153
4154         Reviewed by Adam.
4155
4156         - fix <rdar://problem/5552943> accesskey does not focus <button> elements
4157
4158         Test: fast/forms/access-key.html
4159
4160         * html/HTMLButtonElement.cpp: (WebCore::HTMLButtonElement::accessKeyAction):
4161         Added a call to focus.
4162
4163 2007-11-07  Darin Adler  <darin@apple.com>
4164
4165         Reviewed by Steve.
4166
4167         - cut down on notImplemented() functions on Windows
4168
4169         * bridge/AXObjectCache.h: Put #if around the accessibility
4170         global.
4171
4172         * bridge/win/FrameWin.cpp: (WebCore::Frame::setNeedsReapplyStyles):
4173         Moved here from TemporaryLinkStubs.
4174
4175         * dom/Document.cpp: (WebCore::Document::lastModified): Re-implemented
4176         using the ResourceResponse that's now available from the DocumentLoader.
4177
4178         * editing/JSEditor.cpp: (execTranspose): Changed to call transpose() on
4179         the Editor instead of the obsolete one on the Frame.
4180
4181         * loader/DocumentLoader.h: Removed getResponseModifiedHeader.
4182         * loader/FrameLoader.h: Removed overrideMediaType.
4183
4184         * loader/gtk/DocumentLoaderGtk.cpp: Removed.
4185         * loader/mac/DocumentLoaderMac.mm: Removed.
4186         * loader/qt/DocumentLoaderQt.cpp: Removed.
4187
4188         * page/Frame.cpp: Removed transpose.
4189         * page/Frame.h: Ditto.
4190         * page/FrameView.h: Removed updateBorder.
4191         * page/gtk/FrameGtk.cpp: Removed issueTransposeCommand.
4192         * page/mac/FrameMac.mm: Ditto.
4193         * page/mac/WebCoreFrameBridge.h: Removed issueTransposeCommand and
4194         overrideMediaType.
4195         * page/qt/FrameQt.cpp: Removed issueTransposeCommand.
4196
4197         * platform/gtk/TemporaryLinkStubs.cpp: Removed gAccessibilityEnabled.
4198         * platform/qt/TemporaryLinkStubs.cpp: Ditto.
4199         * platform/win/TemporaryLinkStubs.cpp: Removed or moved all but 3 of the stubs.
4200         * platform/wx/TemporaryLinkStubs.cpp: Removed gAccessibilityEnabled,
4201         issueTransposeCommand, and overrideMediaType.
4202
4203         * platform/network/cf/ResourceHandleCFNet.cpp:
4204         (WebCore::ResourceHandle::loadsBlocked): Moved here from TemporaryLinkStubs.
4205         (WebCore::ResourceHandle::willLoadFromCache): Ditto.
4206         * platform/win/GraphicsContextWin.cpp:
4207         (WebCore::GraphicsContextPlatformPrivate::clip): Ditto.
4208         * platform/win/ScrollViewWin.cpp: (WebCore::ScrollView::inWindow): Ditto.
4209         * platform/win/SystemTimeWin.cpp: (WebCore::userIdleTime): Ditto.
4210         * platform/win/WidgetWin.cpp: (WebCore::Widget::setIsSelected): Ditto.
4211
4212         * WebCore.pro: Updated for removed files.
4213         * WebCore.xcodeproj/project.pbxproj: Updated for removed file.
4214
4215 2007-11-08  Mark Rowe  <mrowe@apple.com>
4216
4217        Build fix for case-sensitive file systems.  Fix case of file names
4218        in #include's.
4219
4220         * html/HTMLMediaElement.cpp:
4221         * platform/graphics/Movie.cpp:
4222
4223 2007-11-08  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
4224
4225         Reviewed by Lars Knoll <lars@trolltech.com>.
4226
4227         Remove some warnings about not implemented methods.
4228
4229         * ResourceHandle::loadsBlocked and ResourceHandle::supportsBufferedData are
4230         specific to the