Simon Hausmann <hausmann@webkit.org>
[WebKit-https.git] / WebCore / ChangeLog
1 2008-04-25  Simon Hausmann  <hausmann@webkit.org>
2
3         Reviewed by Holger.
4
5         When we encounter a new/unknown HTTP request type report it back to WebCore as loading error.
6
7         * platform/network/qt/QNetworkReplyHandler.cpp:
8         (WebCore::QNetworkReplyHandler::start):
9
10 2008-04-25  Benjamin Meyer  <bmeyer@trolltech.com>
11
12         Reviewed by Simon.
13
14         Fix crash in the networking layer.
15
16         Set the m_reply to null right after calling deleteLater().
17
18         * platform/network/qt/QNetworkReplyHandler.cpp:
19         (WebCore::QNetworkReplyHandler::finish):
20
21 2008-04-24  Mark Rowe  <mrowe@apple.com>
22
23         Rubber-stamped by Oliver Hunt.
24
25         * WebCore.base.exp: Remove two symbols from the export list that don't need to be exported.
26
27 2008-04-24  Dan Bernstein  <mitz@apple.com>
28
29         Reviewed by Dave Hyatt.
30
31         - fix https://bugs.webkit.org/show_bug.cgi?id=18722
32           <rdar://problem/5888360> REGRESSION (3.1 -> TOT): Webkit Nightly Build crashes when visiting i has a hotdog
33
34         Test: fast/dynamic/float-remove-above-line.html
35
36         * rendering/bidi.cpp:
37         (WebCore::RenderBlock::layoutInlineChildren): Avoid adding floats that
38         do not intrude into the line to its floats vector. When such floats go
39         away, they do not dirty the line (because they do not intersect with it)
40         and having it keep them in its floats vector is what caused the crash.
41
42 2008-04-24  Justin Garcia  <justin.garcia@apple.com>
43
44         Reviewed by John Sullivan.
45         
46         It is possible, despite our safeguards, for createMarkup to iterate past the end of the Range
47         that is passed to it.  Added a null check to prevent crashes in this situation (we won't crash but
48         we will create too much markup), and added an ASSERT to hopefully catch the scenario in a debugger 
49         and help us understand what's going on.
50
51         * editing/markup.cpp:
52         (WebCore::createMarkup):
53
54 2008-04-24  Mark Rowe  <mrowe@apple.com>
55
56         Reviewed by Sam Weinig.
57
58         Remove code for calculating the glyph cache size.
59
60         * WebCore.base.exp: Remove unused symbol.
61         * platform/graphics/mac/FontCacheMac.mm: Remove code that is unused now that we do not compute the glyph cache size.
62         * platform/mac/WebCoreSystemInterface.h: Remove unused symbol.
63         * platform/mac/WebCoreSystemInterface.mm: Ditto.
64
65 2008-04-24  Mark Rowe  <mrowe@apple.com>
66
67         Reviewed by Sam Weinig.
68
69         Add a definition of BUILDING_ON_LEOPARD to complement BUILDING_ON_TIGER.
70
71         * WebCorePrefix.h:
72
73 2008-04-24  Cameron McCormack  <cam@mcc.id.au>
74
75         Reviewed by Maciej Stachowiak.
76
77         Ensure that changes to rx="" and ry="" attributes on an SVG <rect>
78         element cause a relayout.
79
80         Test: svg/dom/SVGRectElement/rect-modify-rx.svg
81
82         * svg/SVGRectElement.cpp:
83         (WebCore::SVGRectElement::svgAttributeChanged): Call needsLayout()
84         when the attribute is rx or ry.
85         (WebCore::SVGRectElement::hasRelativeValues): Return true when the
86         attribute is rx or ry, since they also can have relative values.
87
88 2008-04-24  Adam Barth  <hk9565@gmail.com>
89
90         Reviewed by Sam Weinig.
91
92         Update the XMLHttpRequest header black list to match the spec.
93
94         * xml/XMLHttpRequest.cpp:
95         (WebCore::isSafeRequestHeader):
96
97 2008-04-22  Feng Qian  <ian.eng.webkit@gmail.com>
98
99         Reviewed by Geoff Garen.
100
101         Fix https://bugs.webkit.org/show_bug.cgi?id=18677
102         Bug 18677: Synchronous event dispatch confuses the popup blocker into incorrectly blocking chat popups in gmail.com.
103
104         Test: fast/events/nested-window-event.html
105
106         * bindings/js/kjs_events.cpp:
107         (WebCore::JSAbstractEventListener::handleEvent): Save and restore the current event around the event dispatch.
108
109 2008-04-24  Brady Eidson  <beidson@apple.com>
110
111         Reviewed by Teh Mitzpettel
112
113         Make it so PageGroups know what their own name is.
114
115         * WebCore.base.exp:
116
117         * page/Page.cpp:
118         (WebCore::Page::setGroupName):
119         (WebCore::Page::groupName):
120         * page/Page.h:
121
122         * page/PageGroup.cpp: Move the PageGroupMap into the PageGroup class.
123         (WebCore::PageGroup::PageGroup): Added a c'tor that takes the group name as an argument instead of
124           the initial Page.
125         (WebCore::PageGroup::pageGroup): Handles creating and mapping names to groups
126         * page/PageGroup.h:
127         (WebCore::PageGroup::name):
128
129 2008-04-24  Adele Peterson  <adele@apple.com>
130
131         Reviewed by Darin.
132
133         Consolidate two versions of pathGetFileName.
134
135         * html/HTMLFormElement.cpp: (WebCore::HTMLFormElement::formData): Call FileSystem.h version of pathGetFileName and removed the static helper function.
136         * platform/posix/FileSystemPOSIX.cpp: (WebCore::pathGetFileName): Moved general case from HTMLFormElement version here.
137           If other platforms relied on that default they should implement this function for their platform specific version of FileSystem.cpp
138         * platform/win/FileSystemWin.cpp: (WebCore::pathGetFileName): Moved win implementation from HTMLFormElement here.
139         * platform/wx/FileSystemWx.cpp: (WebCore::pathGetFileName): Moved wx implementation from HTMLFormElement here.
140
141 2008-04-24  Anders Carlsson  <andersca@apple.com>
142
143         Windows build fix.
144         
145         * html/HTMLFormElement.cpp:
146         (WebCore::pathGetFilename):
147
148 2008-04-24  Anders Carlsson  <andersca@apple.com>
149
150         Don't crash when the string is empty.
151         
152         * html/HTMLMediaElement.cpp:
153         (WebCore::parseTimeOffset):
154
155 2008-04-24  Dan Bernstein  <mitz@apple.com>
156
157         Reviewed by Darin Adler.
158
159         - preparation for https://bugs.webkit.org/show_bug.cgi?id=3729
160           <rdar://problem/4036353> REGRESSION: arrow keys move insertion bar backwards in RTL text
161
162         The three main changes in this patch are:
163
164         1) Making all inline boxes know their bidi level, instead of just text
165            boxes knowing whether their bidi level is odd or even. This is
166            required for the next change.
167
168         2) Replacing RenderObject::inlineBox() with
169            Position::getInlineBoxAndOffset() in recognition of the fact that the
170            inline box containing the primary caret for a position in a given
171            node may belong to a different node's renderer.
172
173         3) Changing RenderObject::caretRect() to take an InlineBox parameter,
174            and changing callers to call VisiblePosition::caretRect(), which
175            locates the inline box, then calls caretRect() on the renderer for
176            that box. This, combined with the previous change, ensures that the
177            primary caret is rendered at the right place for positions that
178            lie on a directionality boundary.
179
180         Test: platform/mac/editing/input/caret-primary-bidi.html
181
182         * WebCore.base.exp: Added the VisiblePosition(Node*, int, EAffinity)
183         constructor and VisiblePosition::caretRect(), and sorted.
184
185         * dom/Position.cpp:
186         (WebCore::nextRenderedEditable): Adjusted for the removal of
187         RenderObject::inlineBox().
188         (WebCore::previousRenderedEditable): Ditto.
189         (WebCore::Position::rendersInDifferentPosition): Ditto.
190         (WebCore::Position::getInlineBoxAndOffset): Added. Gets the inline box
191         and the offset within that box at which the primary caret for this
192         position should render.
193
194         * dom/Position.h:
195
196         * editing/DeleteSelectionCommand.cpp:
197         (WebCore::DeleteSelectionCommand::mergeParagraphs): Changed to call
198         VisiblePosition::caretRect() instead of calling the RenderObject method.
199
200         * editing/SelectionController.cpp:
201         (WebCore::caretY): Ditto.
202         (WebCore::SelectionController::xPosForVerticalArrowNavigation): Ditto.
203         (WebCore::SelectionController::layout): Ditto.
204
205         * editing/VisiblePosition.cpp:
206         (WebCore::VisiblePosition::caretRect): Changed to call
207         getInlineBoxAndOffset() to get the correct inline box and call the
208         renderer for that box.
209
210         * editing/VisiblePosition.h:
211         (WebCore::VisiblePosition::getInlineBoxAndOffset): Added convenience
212         methods for getting the inline box and caret offset for a visible
213         position, accounting for its affinity.
214
215         * editing/visible_units.cpp:
216         (WebCore::rootBoxForLine): Changed to use getInlineBoxAndOffset()
217         instead of RenderObject::inlineBox().
218         (WebCore::startPositionForLine):
219         (WebCore::endPositionForLine):
220         (WebCore::previousLinePosition): Ditto.
221         (WebCore::nextLinePosition): Ditto.
222
223         * page/AccessibilityObject.cpp:
224         (WebCore::updateAXLineStartForVisiblePosition): Ditto.
225
226         * page/Frame.cpp:
227         (WebCore::Frame::firstRectForRange): Ditto.
228
229         * rendering/InlineBox.cpp:
230         (WebCore::InlineBox::caretMinOffset): Changed to forward to the
231         renderer.
232         (WebCore::InlineBox::caretMaxOffset): Ditto.
233         * rendering/InlineBox.h: Replaced the m_reversed bit, intended for use
234         in InlineTextBox only, with six bits of the bidi level of the box,
235         intended for use in all leaf inline boxes.
236         (WebCore::InlineBox::InlineBox): Added missing initializer for
237         m_dirOverride and initialized the bidi level.
238         (WebCore::InlineBox::bidiLevel): Added this accessor.
239         (WebCore::InlineBox::setBidiLevel): Ditto.
240         (WebCore::InlineBox::direction): Ditto.
241         (WebCore::InlineBox::caretLeftmostOffset): Added this convenience
242         method.
243         (WebCore::InlineBox::caretRightmostOffset): Ditto.
244
245         * rendering/InlineTextBox.cpp: Replaced all references to m_reversed
246         with checking of direction().
247         (WebCore::InlineTextBox::selectionRect):
248         (WebCore::InlineTextBox::placeEllipsisBox):
249         (WebCore::InlineTextBox::paint):
250         (WebCore::InlineTextBox::paintSelection):
251         (WebCore::InlineTextBox::paintCompositionBackground):
252         (WebCore::InlineTextBox::paintSpellingOrGrammarMarker):
253         (WebCore::InlineTextBox::paintTextMatchMarker):
254         (WebCore::InlineTextBox::textPos):
255         (WebCore::InlineTextBox::offsetForPosition):
256         (WebCore::InlineTextBox::positionForOffset):
257
258         * rendering/RenderBR.cpp: Removed inlineBox().
259         * rendering/RenderBR.h: Ditto.
260
261         * rendering/RenderBox.cpp:
262         (WebCore::RenderBox::caretRect): Changed to take an inline box and
263         account for the direction of the box (or the renderer) in positioning
264         the caret: in right-to-left boxes, the "before" position is to the right
265         while "after" is to the left.
266         * rendering/RenderBox.h:
267
268         * rendering/RenderFlow.cpp:
269         (WebCore::RenderFlow::caretRect): Updated the signature.
270         * rendering/RenderFlow.h:
271
272         * rendering/RenderObject.cpp:
273         (WebCore::RenderObject::caretRect): Updated the signature.
274         (WebCore::RenderObject::caretMaxOffset): Changed to return the child
275         node count (or 1 if there are no children) for replaced elements, such
276         as <select>s.
277         * rendering/RenderObject.h:
278
279         * rendering/RenderReplaced.cpp: Removed caretMinOffset() and
280         caretMaxOffset() because the base class implementation does the right
281         thing for replaced objects now.
282         * rendering/RenderReplaced.h:
283
284         * rendering/RenderSVGInlineText.cpp:
285         (WebCore::RenderSVGInlineText::caretRect): Updated the signature.
286         (WebCore::RenderSVGInlineText::positionForCoordinates): Updated for
287         the change from m_reversed to direction().
288         * rendering/RenderSVGInlineText.h:
289
290         * rendering/RenderText.cpp:
291         (WebCore::RenderText::caretRect): Changed to take an inline box and
292         removed the code that used to find the inline for the given position.
293         Changed use of m_reversed to use direction().
294         (WebCore::RenderText::position): Changed use of m_reversed to use
295         direction().
296         * rendering/RenderText.h:
297
298         * rendering/RenderTextControl.cpp:
299         (WebCore::RenderTextControl::textWithHardLineBreaks): Adjusted for the
300         removal of RenderObject::inlineBox().
301
302         * rendering/RenderTreeAsText.cpp:
303         (WebCore::writeTextRun): Changed to use direction() instead of
304         m_reversed.
305
306         * rendering/SVGInlineTextBox.cpp: Ditto.
307         (WebCore::SVGInlineTextBox::calculateGlyphBoundaries):
308         (WebCore::SVGInlineTextBoxClosestCharacterToPositionWalker::chunkPortionCallback):
309         (WebCore::SVGInlineTextBox::svgCharacterHitsPosition):
310
311         * rendering/SVGRenderTreeAsText.cpp: Ditto.
312         (WebCore::writeSVGInlineTextBox):
313
314         * rendering/SVGRootInlineBox.cpp: Ditto.
315         (WebCore::svgTextRunForInlineTextBox):
316         (WebCore::cummulatedWidthOrHeightOfTextChunk):
317         (WebCore::SVGRootInlineBox::buildLayoutInformationForTextBox):
318
319         * rendering/bidi.cpp:
320         (WebCore::RenderBlock::constructLine): Made this function set the
321         bidi level on all leaf boxes.
322
323         * svg/SVGTextContentElement.cpp: Changed to use direction() instead of
324         m_reversed.
325         (WebCore::cumulativeCharacterRangeLength):
326         (WebCore::SVGInlineTextBoxQueryWalker::chunkPortionCallback):
327
328 2008-04-24  Sam Weinig  <sam@webkit.org>
329
330         Fix the world.
331
332         * bindings/js/kjs_proxy.cpp:
333         (WebCore::KJSProxy::clear):
334
335 2008-04-24  Darin Adler  <darin@apple.com>
336
337         Reviewed by Geoff.
338
339         - fix crash in regression test where we'd ask a frame for a user agent string
340           after the WebView was already closed
341
342         * loader/FrameLoader.cpp:
343         (WebCore::FrameLoader::scheduleHTTPRedirection): Quietly do nothing if this is
344         called on a frame that's already detached from its page.
345         (WebCore::FrameLoader::scheduleLocationChange): Ditto.
346         (WebCore::FrameLoader::scheduleRefresh): Ditto.
347         (WebCore::FrameLoader::scheduleHistoryNavigation): Ditto.
348         (WebCore::FrameLoader::redirectionTimerFired): Assert that this is never called
349         for a frame that's already detached from its page.
350         (WebCore::FrameLoader::scheduleRedirection): Ditto.
351         (WebCore::FrameLoader::startRedirectionTimer): Ditto.
352
353 2008-04-23  Timothy Hatcher  <timothy@apple.com>
354
355         Add a new callFunction helper function to remove duplicate code
356         for calling JavaScript functions with arguments.
357
358         Reviewed by Darin Adler.
359
360         * page/InspectorController.cpp:
361         (WebCore::InspectorController::callSimpleFunction): Call callFunction.
362         (WebCore::InspectorController::callFunction): Extended version of the original
363         callSimpleFunction, with script function arguments and an exception argument.
364         (WebCore::InspectorController::focusNode): Use callFunction.
365         (WebCore::InspectorController::addScriptResource): Ditto.
366         (WebCore::InspectorController::removeScriptResource): Ditto.
367         (WebCore::InspectorController::addDatabaseScriptResource): Ditto.
368         (WebCore::InspectorController::removeDatabaseScriptResource): Ditto.
369         (WebCore::InspectorController::addScriptConsoleMessage): Ditto.
370         * page/InspectorController.h: Add callFunction.
371
372 2008-04-24  Anders Carlsson  <andersca@apple.com>
373
374         Reviewed by Sam.
375
376         Change some String arguments to be const references instead.
377         
378         * css/CSSRule.cpp:
379         (WebCore::CSSRule::setCssText):
380         * css/CSSRule.h:
381         * html/HTMLFormElement.cpp:
382         (WebCore::pathGetFilename):
383         * html/HTMLMediaElement.cpp:
384         (WebCore::parseTimeOffset):
385         * page/EditorClient.h:
386         * platform/SecurityOrigin.cpp:
387         (WebCore::isDefaultPortForProtocol):
388         * platform/graphics/MediaPlayer.cpp:
389         (WebCore::MediaPlayer::load):
390         * platform/graphics/MediaPlayer.h:
391         * rendering/MediaControlElements.cpp:
392         (WebCore::MediaControlInputElement::MediaControlInputElement):
393         * rendering/MediaControlElements.h:
394         * svg/animation/SVGSMILElement.cpp:
395         (WebCore::SVGSMILElement::Condition::Condition):
396         * svg/animation/SVGSMILElement.h:
397         * svg/graphics/SVGImageEmptyClients.h:
398         (WebCore::SVGEmptyEditorClient::shouldInsertText):
399         * xml/XSLTProcessor.cpp:
400         (WebCore::createFragmentFromSource):
401
402 2008-04-24  Justin Garcia  <justin.garcia@apple.com>
403
404         Reviewed by Darin Adler.
405
406         <rdar://problem/5604313> FormatBlock to apply an h1 also inserts a style span around the first letter (16004)
407         
408         * editing/TextIterator.cpp:
409         (WebCore::TextIterator::advance): We emit an extra newline when leaving a
410         block element that has atypical margin/padding. When we emit the extra newline, 
411         it needs to be positioned after that block's contents, not after the block. 
412         This is how we position the first newline, too, since the range for emitted newlines 
413         should start where the line break begins visually.
414
415 2008-04-24  Anders Carlsson  <andersca@apple.com>
416
417         Reviewed by Adam.
418
419         Only avoid implicit entries when doing the initial caching.
420         
421         * loader/appcache/ApplicationCacheGroup.cpp:
422         (WebCore::ApplicationCacheGroup::didReceiveResponse):
423         (WebCore::ApplicationCacheGroup::startLoadingEntry):
424
425 2008-04-24  Kevin McCullough  <kmccullough@apple.com>
426
427         Reviewed by Adam and Sam.
428
429         -<rdar://problem/5770054> JavaScript profiler (10928)
430         -Only profile the page group that starts profiling to avoid profiling
431         tools that shouldn't be profiled unless explicitly requested to.
432
433         * bindings/js/kjs_proxy.cpp: When a new global object is created set its
434         page group identifier.
435         (WebCore::KJSProxy::clear):
436         (WebCore::KJSProxy::initScript):
437         * page/Console.cpp: When calling console.profile set the identifier of
438         the page group being profiled.
439         (WebCore::Console::profile):
440         * page/PageGroup.cpp: Implement unique identifiers.
441         (WebCore::getUniqueIdentifier):
442         (WebCore::PageGroup::PageGroup):
443         * page/PageGroup.h: Ditto.
444         (WebCore::PageGroup::identifier):
445
446 2008-04-24  John Sullivan  <sullivan@apple.com>
447
448         Mac buid fix
449
450         * page/mac/WebCoreViewFactory.h:
451         add declarations of six new AX methods that were added to LocalizedStrings.h
452         
453         * platform/mac/LocalizedStringsMac.mm:
454         (WebCore::AXButtonActionVerb):
455         implement by calling through to WebCoreViewFactory as we do with the other functions here
456         (WebCore::AXRadioButtonActionVerb):
457         ditto
458         (WebCore::AXTextFieldActionVerb):
459         ditto
460         (WebCore::AXCheckedCheckBoxActionVerb):
461         ditto
462         (WebCore::AXUncheckedCheckBoxActionVerb):
463         ditto
464         (WebCore::AXLinkActionVerb):
465         ditto
466
467 2008-04-24  Simon Hausmann  <hausmann@webkit.org>
468
469         Rubber-stamped by Lars
470
471         Fix text rendering in -reverse mode on Qt/Mac.
472
473         For Font::width() don't use a plain QFontMetrics object but also the properly
474         setup QTextLayout that has the RTL/LTR force flags set.
475
476         * platform/graphics/qt/FontQt.cpp:
477         (WebCore::Font::width):
478
479 2008-04-24  Tor Arne Vestbø  <tavestbo@trolltech.com>
480
481         Reviewed by Simon.
482
483         Don't do anti-aliasing for arcs, lines and rects, but continue to anti-alias
484         all drawing primitives in the HTML Canvas element.
485
486         This speeds up drawing of dashed outlines significantly.
487
488         Also preserve the anti-aliasing renderhint for transparency layers and
489         get rid of the mostly unused device pointer.
490
491         * platform/graphics/qt/GraphicsContextQt.cpp:
492         (WebCore::TransparencyLayer::TransparencyLayer):
493         (WebCore::GraphicsContextPlatformPrivate::p):
494         (WebCore::GraphicsContextPlatformPrivate::GraphicsContextPlatformPrivate):
495         (WebCore::GraphicsContext::beginTransparencyLayer):
496         (WebCore::GraphicsContext::drawRect):
497         (WebCore::GraphicsContext::drawLine):
498         (WebCore::GraphicsContext::strokeArc):
499
500 2008-04-24  Paul Olav Tvete <paul@trolltech.com>
501
502         Reviewed by Simon.
503
504         Fix various compiler warnings related to QString(const char *)
505         construction by using QLatin1String.
506
507         * bridge/qt/qt_instance.cpp:
508         (KJS::Bindings::QtField::valueFromInstance):
509         (KJS::Bindings::QtField::setValueToInstance):
510         * dom/XMLTokenizer.cpp:
511         (WebCore::):
512         * platform/graphics/qt/PathQt.cpp:
513         (WebCore::Path::debugString):
514
515 2008-04-24  Morten Johan Sørvig  <msorvig@trolltech.com>
516
517         Reviewed by Simon.
518
519         Work around QMacStyle bug in repainting the vertical scrollbar.
520
521         We draw the scrollbar using HITheme but somehow the translation and the
522         clipping we previously set using ClipCGContextToRegion is ignored. Drawing
523         without the translation fixes the clip.
524
525         * platform/qt/PlatformScrollBarQt.cpp:
526         (WebCore::PlatformScrollbar::paint):
527
528 2008-04-24  Holger Hans Peter Freyther  <zecke@selfish.org>
529
530         Reviewed by Simon.
531
532         * Set an expiration date for local files as we do not know what will happen
533         to these files (in contrast to a http server with max-age and other headers)
534         * Remember the time when we started the job and use that for the expiration date
535         * QNetworkManager does not handle expiration at all, we might want to set the
536         expiration for all downloads but this will be a performance nightmare.
537
538         * platform/network/qt/QNetworkReplyHandler.cpp:
539         (WebCore::QNetworkReplyHandler::QNetworkReplyHandler):
540         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
541         (WebCore::QNetworkReplyHandler::start):
542         * platform/network/qt/QNetworkReplyHandler.h:
543
544 2008-04-24  Simon Hausmann  <hausmann@webkit.org>
545
546         Fix the Gtk and Qt builds.
547
548         Added missing localization stubs for accessibility.
549
550         * platform/gtk/LocalizedStringsGtk.cpp:
551         (WebCore::AXButtonActionVerb):
552         (WebCore::AXRadioButtonActionVerb):
553         (WebCore::AXTextFieldActionVerb):
554         (WebCore::AXCheckedCheckBoxActionVerb):
555         (WebCore::AXUncheckedCheckBoxActionVerb):
556         (WebCore::AXLinkActionVerb):
557         * platform/qt/Localizations.cpp:
558         (WebCore::AXButtonActionVerb):
559         (WebCore::AXRadioButtonActionVerb):
560         (WebCore::AXTextFieldActionVerb):
561         (WebCore::AXCheckedCheckBoxActionVerb):
562         (WebCore::AXUncheckedCheckBoxActionVerb):
563         (WebCore::AXLinkActionVerb):
564
565 2008-04-24  Olivier Goffart  <ogoffart@trolltech.com>
566
567         Reviewed by Simon
568
569         Fix various compiler warnings in the Qt port.
570
571         * platform/graphics/qt/ImageQt.cpp:
572         (loadResourcePixmap):
573         * platform/qt/CookieJarQt.cpp:
574         (WebCore::cookies):
575         * platform/qt/ScrollViewQt.cpp:
576         (WebCore::ScrollView::wheelEvent):
577         * plugins/qt/PluginDataQt.cpp:
578         (WebCore::PluginData::initPlugins):
579
580 2008-04-24  Andre Poenitz  <andre.poenitz@trolltech.com>
581
582         Reviewed by Simon.
583
584         Removed spurious QHideEvent forward declaration.
585
586         * platform/qt/QWebPopup.h:
587
588 2008-04-24  Tor Arne Vestbø  <tavestbo@trolltech.com>
589
590         Reviewed by Simon.
591
592         Render text areas using Qt (ensures proper style).
593
594         * platform/qt/RenderThemeQt.cpp:
595         (WebCore::RenderThemeQt::paintTextField):
596         (WebCore::RenderThemeQt::adjustTextFieldStyle):
597         (WebCore::RenderThemeQt::paintTextArea):
598         (WebCore::RenderThemeQt::supportsFocus):
599         * platform/qt/RenderThemeQt.h:
600
601 2008-04-24  Tor Arne Vestbø  <tavestbo@trolltech.com>
602
603         Reviewed by Simon.
604
605         Make mouse wheel events over scrollbars behave the same as in Qt, i.e. both
606         horizontal and vertical wheel events will scroll the view in the orientation
607         of the scrollbar underneath the cursor.
608
609         * platform/qt/ScrollViewQt.cpp:
610         (WebCore::ScrollView::paint):
611         (WebCore::ScrollView::wheelEvent):
612
613 2008-04-23  Jon Honeycutt  <jhoneycutt@apple.com>
614
615         Reviewed by Brady.
616
617         * page/AccessibilityObject.cpp:
618         (WebCore::AccessibilityObject::press): Return false if this object
619         doesn't have an action element associated with it.
620         * page/AccessibilityObject.h: Added a performDefaultAction() method,
621         which just calls press(). Marked press() const and changed its return
622         type to bool.
623
624 2008-04-23  Jon Honeycutt  <jhoneycutt@apple.com>
625
626         Reviewed by Adam.
627
628         Don't allow a hit test to return an AccessibilityObject that should be
629         ignored.
630
631         * page/AccessibilityObject.cpp:
632         (WebCore::AccessibilityObject::doAccessibilityHitTest): If this result
633         object's accessibility is ignored, return the parent unignored object.
634
635 2008-04-23  Jon Honeycutt  <jhoneycutt@apple.com>
636
637         Reviewed by Adam.
638
639         Fix a crash when performing a hit test on an AccessibilityObject with
640         no layer (e.g., an AccessibilityObject for a RenderText object).
641
642         * page/AccessibilityObject.cpp:
643         (WebCore::AccessibilityObject::doAccessibilityHitTest): Added a null
644         check for layer. Removed a null check for m_renderer, which shouldn't
645         occur.
646
647 2008-04-23  Jon Honeycutt  <jhoneycutt@apple.com>
648
649         * page/AccessibilityObject.cpp:
650         (WebCore::AccessibilityObject::boundingBoxRect): Added FIXME about this
651         method not working correctly for objects with CSS transforms applied.
652
653 2008-04-23  Jon Honeycutt  <jhoneycutt@apple.com>
654
655         Reviewed by Adam.
656
657         Implement contentsToScreen() and screenToContents() on Windows.
658
659         * platform/ScrollView.h: Make these declarations conditional on
660         HAVE(ACCESSIBILITY) instead of PLATFORM(MAC).
661         * platform/win/ScrollViewWin.cpp:
662         (WebCore::ScrollView::contentsToScreen): Translate from coordinates
663         relative to the ScrollView to coordinates relative to the screen. Do
664         this by getting the offset of the ScrollView in screen coordinates and
665         moving the rect by this amount.
666         (WebCore::ScrollView::screenToContents): Translate from coordinates
667         relative to the screen to coordinates relative to the ScrollView.
668
669 2008-04-23  Jon Honeycutt  <jhoneycutt@apple.com>
670
671         Reviewed by Oliver.
672
673         Add a method to get a localized, human-readable string stating this
674         object's default action, e.g., a button's default action is "press."
675
676         * page/AccessibilityObject.cpp:
677         (WebCore::AccessibilityObject::actionVerb): Added.
678         * page/AccessibilityObject.h: Added declaration for actionVerb().
679         * platform/LocalizedStrings.h: Added declarations for:
680             AXButtonActionVerb()
681             AXRadioButtonActionVerb()
682             AXTextFieldActionVerb()
683             AXCheckedCheckBoxActionVerb()
684             AXUncheckedCheckBoxActionVerb()
685             AXLinkActionVerb()
686
687 2008-04-24  Tor Arne Vestbø  <tavestbo@trolltech.com>
688
689         Reviewed by Simon.
690
691         Cleaned up copyright headers in the Qt port (removed misplaced class
692         descriptions and fixed inconsistent whitespace and indentation).
693
694         * platform/graphics/qt/FontQt.cpp:
695         * platform/qt/WheelEventQt.cpp:
696
697 2008-04-24  Tor Arne Vestbø  <tavestbo@trolltech.com>
698
699         Reviewed by Simon.
700
701         Disable vanlilla focus rings since Qt provides this as part of the style.
702
703         * platform/qt/RenderThemeQt.cpp:
704
705 2008-04-24  George Staikos  <george@staikos.net>
706
707         Reviewed by Simon.
708
709         This optimization in BitmapImage::drawPattern for the identity
710         transform is bogus and causes incorrect results on sites like youtube.
711
712         * platform/graphics/qt/ImageQt.cpp:
713         (WebCore::BitmapImage::drawPattern):
714
715 2008-04-23  Brady Eidson  <beidson@apple.com>
716
717         Reviewed by Jon Honeycutt
718
719         Preparing for making LocalStorageAreas persistent.
720
721         Since LocalStorageAreas will need to do a lot of additional work for each of the basic
722         operations a Storage object supports, this patch makes the API entry points virtual so
723         LocalStorageArea can override them.  The behavior for both Local and Session StorageAreas
724         is unchanged with this patch, but LocalStorageArea will override them in the future.
725
726         * storage/StorageArea.cpp: Rename the implementations to internalFoo
727         (WebCore::StorageArea::internalLength):
728         (WebCore::StorageArea::internalKey):
729         (WebCore::StorageArea::internalGetItem):
730         (WebCore::StorageArea::internalSetItem):
731         (WebCore::StorageArea::internalRemoveItem):
732         (WebCore::StorageArea::internalContains):
733
734         * storage/StorageArea.h: Call internalFoo variants
735         (WebCore::StorageArea::length):
736         (WebCore::StorageArea::key):
737         (WebCore::StorageArea::getItem):
738         (WebCore::StorageArea::setItem):
739         (WebCore::StorageArea::removeItem):
740         (WebCore::StorageArea::contains):
741
742 2008-04-23  David Hyatt  <hyatt@apple.com>
743
744         Implement getComputedStyle for border-image.
745
746         Reviewed by Dan Bernstein
747
748         Added fast/css/getComputedStyle-border-image.html
749
750         * css/CSSComputedStyleDeclaration.cpp:
751         (WebCore::):
752         (WebCore::valueForRepeatRule):
753         (WebCore::valueForNinePieceImage):
754         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
755
756 2008-04-22  Darin Adler  <darin@apple.com>
757
758         Reviewed by Anders.
759
760         - simplify use of HashTraits to prepare for some upcoming hash table changes
761
762         * page/AXObjectCache.h: Removed uneeded AXIDHashTraits, which are no different
763         from the default hash traits for unsigned.
764         * page/mac/AXObjectCacheMac.mm:
765         (WebCore::AXObjectCache::removeAXID): Remove assertion that's already done
766         by HashTable that the value is not the deleted value.
767
768         * platform/graphics/StringTruncator.cpp: Removed unneeded include.
769         * svg/SVGFontFaceElement.cpp: Removed unneeded include.
770
771 2008-04-23  Kevin Ollivier  <kevino@theolliviers.com>
772
773         wx build fixes. Changing BackgroundLayer -> FillLayer and adding
774         Frame::disconnectPlatformScriptObjects().
775
776         * platform/wx/RenderThemeWx.cpp:
777         (WebCore::RenderThemeWx::isControlStyled):
778         * platform/wx/TemporaryLinkStubs.cpp:
779         (Frame::disconnectPlatformScriptObjects):
780
781 2008-04-23  David Hyatt  <hyatt@apple.com>
782
783         Add support for mask-box-image (similar to border-image).  This property enables a single image
784         to overlay the entire mask area (with nine-piece slicing rules similar to border image).
785
786         Reviewed by Dan Bernstein
787
788         Added inline-mask-overlay.html, block-mask-overlay.html
789
790         * css/CSSComputedStyleDeclaration.cpp:
791         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
792         * css/CSSParser.cpp:
793         (WebCore::CSSParser::parseValue):
794         (WebCore::CSSParser::parseBorderImage):
795         * css/CSSPropertyNames.in:
796         * css/CSSStyleSelector.cpp:
797         (WebCore::CSSStyleSelector::applyProperty):
798         * rendering/InlineFlowBox.cpp:
799         (WebCore::InlineFlowBox::paintMask):
800         * rendering/RenderBox.cpp:
801         (WebCore::RenderBox::paintMask):
802         * rendering/RenderFlow.cpp:
803         (WebCore::RenderFlow::paintLines):
804         * rendering/RenderObject.cpp:
805         (WebCore::RenderObject::paintNinePieceImage):
806         (WebCore::RenderObject::paintBorder):
807         * rendering/RenderObject.h:
808         * rendering/RenderStyle.cpp:
809         (WebCore::NinePieceImage::operator==):
810         * rendering/RenderStyle.h:
811         (WebCore::):
812         (WebCore::NinePieceImage::m_verticalRule):
813         (WebCore::NinePieceImage::horizontalRule):
814         (WebCore::NinePieceImage::verticalRule):
815         (WebCore::RenderStyle::borderImage):
816         (WebCore::RenderStyle::maskOverlayImage):
817         (WebCore::RenderStyle::hasMask):
818         (WebCore::RenderStyle::resetBorderImage):
819         (WebCore::RenderStyle::setBorderImage):
820         (WebCore::RenderStyle::setMaskOverlayImage):
821         (WebCore::RenderStyle::initialNinePieceImage):
822         * rendering/RenderTable.cpp:
823         (WebCore::RenderTable::paintMask):
824         * rendering/RenderTableCell.cpp:
825         (WebCore::RenderTableCell::paintMask):
826
827 2008-04-23  Justin Garcia  <justin.garcia@apple.com>
828
829         Reviewed by Darin Adler.
830
831         <rdar://problem/5825350> OWA: Caret disappears when navigating with arrows keys in contenteditable div
832
833         * editing/htmlediting.cpp:
834         (WebCore::firstEditablePositionAfterPositionInRoot): Return a null VisiblePosition if
835         this function moves out of highestRoot.  Re-wrote so as to not duplicate code inside
836         and outside of the while loop.
837         (WebCore::lastEditablePositionBeforePositionInRoot): Ditto.
838
839 2008-04-23  Daniel Zucker  <zucker@wake3.com>
840
841         Reviewed by Adam Roben.
842
843         Fix build errors needed to compile Curl in Cairo build.  Add stubs for
844         didReceiveAuthenticationChallenge, receivedCredential,
845         receivedRequestToContinueWithoutCredential, and receivedCancellation.
846         <https://bugs.webkit.org/show_bug.cgi?id=18468>
847
848         * platform/network/ResourceHandle.h:  
849         * platform/network/curl/ResourceHandleCurl.cpp:
850         (WebCore::ResourceHandle::didReceiveAuthenticationChallenge):
851         (WebCore::ResourceHandle::receivedCredential):
852         (WebCore::ResourceHandle::receivedRequestToContinueWithoutCredential):
853         (WebCore::ResourceHandle::receivedCancellation):
854
855 2008-04-23  Dan Bernstein  <mitz@apple.com>
856
857         Reviewed by Darin Adler.
858
859         - fix a bug where moving forward in bidirectional text skips over the
860           position after the end of the line
861
862         Test: editing/selection/move-past-trailing-space.html
863
864         * dom/Position.cpp:
865         (WebCore::Position::upstream): Changed the logic for identifying when a
866         position is after the last character of a text box of a text node that
867         continues on the next line, to make it work correctly when boxes are not
868         laid out in logical order.
869         (WebCore::Position::downstream): Ditto.
870
871 2008-04-23  Brad Hughes  <bhughes@trolltech.com>
872
873         Reviewed by Simon.
874
875         Fix release build with the intel compiler
876
877         Intel compiler can't compile qtwebkit with -O2 or -O1, so we're left with -O0
878
879         * WebCore.pro:
880
881 2008-04-22  Dan Bernstein  <mitz@apple.com>
882
883         Reviewed by Anders Carlsson.
884
885         - remove unused calls to Position::upstream()
886
887         * editing/InsertLineBreakCommand.cpp:
888         (WebCore::InsertLineBreakCommand::insertNodeAfterPosition):
889         (WebCore::InsertLineBreakCommand::insertNodeBeforePosition):
890
891 2008-04-22  Jon Honeycutt  <jhoneycutt@apple.com>
892
893         Reviewed by Sam.
894
895         Add a method to query which modifier keys the platform uses for access
896         key actions.
897
898         * page/EventHandler.cpp:
899         (WebCore::EventHandler::handleAccessKey): Bitwise and the event's
900         modifier keys with the platform's access key modifier mask to determine
901         whether this event can perform an access key action.
902         * page/EventHandler.h: Added s_accessKeyModifiers, a platform-defined
903         mask of modifier keys used for access key actions, and a getter.
904         * page/mac/EventHandlerMac.mm: Use PlatformKeyboardEvent::CtrlKey for
905         access key actions.
906         * page/qt/EventHandlerQt.cpp: Same.
907         * page/gtk/EventHandlerGtk.cpp: Use AltKey.
908         * page/win/EventHandlerWin.cpp: Same.
909         * page/wx/EventHandlerWx.cpp: Same.
910         * platform/PlatformKeyboardEvent.h: Added an enum, ModifierKey.
911         (WebCore::PlatformKeyboardEvent::):
912         (WebCore::PlatformKeyboardEvent::modifiers): Return which modifier keys
913         were active, a combination of ModifierKey values.
914
915 2008-04-22  Sam Weinig  <sam@webkit.org>
916
917         Reviewed by Maciej Stachowiak.
918
919         Make the KJSProxy and FrameLoader member variables instead of pointers
920         in FramePrivate in a bid to do a little clean up before the last of the
921         split window patches.  Also, make the KJSProxy not lazily created, as the
922         real benefit comes from lazily creating the JSDOMWindowWrapper, which we
923         still do.
924
925         * page/Frame.cpp:
926         (WebCore::Frame::~Frame):
927         (WebCore::Frame::init):
928         (WebCore::Frame::loader):
929         (WebCore::Frame::scriptProxy):
930         (WebCore::Frame::document):
931         (WebCore::Frame::setDocument):
932         (WebCore::Frame::clearScriptProxy):
933         (WebCore::Frame::pageDestroyed):
934         (WebCore::FramePrivate::FramePrivate):
935         (WebCore::FramePrivate::~FramePrivate):
936         * page/FramePrivate.h:
937
938 2008-04-22  Anatoli Papirovski  <apapirovski@mac.com>
939
940         Reviewed by Dan Bernstein.
941
942         - fix https://bugs.webkit.org/show_bug.cgi?id=18584
943         border-color, outline-color, column-color, -webkit-text-stroke-color,
944         and -webkit-text-fill-color inheritance to correctly use parent's color
945         if the parent's corresponding (border, outline, etc.)-color property
946         wasn't set.
947
948         Test: fast/borders/border-color-inherit.html
949
950         * css/CSSStyleSelector.cpp:
951         (WebCore::CSSStyleSelector::applyProperty):
952
953 2008-04-22  Alp Toker  <alp@nuanti.com>
954
955         Rubber-stamped by Dave Hyatt.
956
957         Move GraphicsContext::clipToImageBuffer() notImplemented() stub to
958         GraphicsContextCairo.
959
960         * platform/graphics/GraphicsContext.cpp:
961         * platform/graphics/cairo/GraphicsContextCairo.cpp:
962         (WebCore::GraphicsContext::clipToImageBuffer):
963
964 2008-04-22  David Hyatt  <hyatt@apple.com>
965
966         Add support for mask-composite to match background-composite.
967
968         Reviewed by Sam Weinig
969
970         Added fast/backgrounds/mask-composite.html
971
972         * css/CSSComputedStyleDeclaration.cpp:
973         (WebCore::):
974         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
975         * css/CSSParser.cpp:
976         (WebCore::CSSParser::parseValue):
977         (WebCore::CSSParser::parseFillProperty):
978         * css/CSSPropertyNames.in:
979         * css/CSSStyleSelector.cpp:
980         (WebCore::CSSStyleSelector::applyProperty):
981         * rendering/InlineFlowBox.cpp:
982         (WebCore::InlineFlowBox::paintMask):
983
984 2008-04-22  David Hyatt  <hyatt@apple.com>
985
986         Fix for bug 18688, background-color stopped painting on inlines.  Fix a virtual function
987         misnaming that led to the derived class not getting called properly.
988
989         Reviewed by Mark Rowe
990
991         * ChangeLog:
992         * rendering/InlineFlowBox.cpp:
993         (WebCore::InlineFlowBox::paintFillLayer):
994         * rendering/RenderObject.h:
995         (WebCore::RenderObject::paintFillLayerExtended):
996
997 2008-04-22  Brady Eidson  <beidson@apple.com>
998
999         Reviewed by Sam Weinig
1000
1001         <rdar://problem/5733282> and https://bugs.webkit.org/show_bug.cgi?id=18680
1002         Always loads default shortcut icon URL when an external <script> is referenced before the icon URL is set.
1003
1004         * dom/Document.cpp:
1005         (WebCore::Document::implicitClose): Call FrameLoader->startIconLoader() here, when the document is
1006           finished parsing.
1007
1008         * loader/FrameLoader.cpp:
1009         (WebCore::FrameLoader::endIfNotLoadingMainResource):  Don't start the icon load here, when the
1010           document is finished parsing.  This was often too early, as document parsing may be blocked
1011           on an external script and therefore the correct iconURL is not set yet.
1012           The isLoadingFromCachedPage() check was when we started the icon load based on *loading* instead parsing,
1013           and is now irrelevant.
1014         * loader/FrameLoader.h:  Make startIconLoader() public
1015
1016 2008-04-22  Antti Koivisto  <antti@apple.com>
1017
1018         Reviewed by Oliver.
1019
1020         Support keyPoints attribute of <animateMotion>.
1021         
1022         Tested by SVG test suite test
1023         animate-elem-33-t.svg
1024
1025         * svg/SVGAnimateMotionElement.cpp:
1026         (WebCore::SVGAnimateMotionElement::parseMappedAttribute):
1027         * svg/SVGAnimationElement.cpp:
1028         (WebCore::parseKeyTimes):
1029         (WebCore::SVGAnimationElement::parseMappedAttribute):
1030         (WebCore::SVGAnimationElement::calculatePercentForSpline):
1031         (WebCore::SVGAnimationElement::calculatePercentFromKeyPoints):
1032         (WebCore::SVGAnimationElement::currentValuesFromKeyPoints):
1033         (WebCore::SVGAnimationElement::currentValuesForValuesAnimation):
1034         (WebCore::SVGAnimationElement::startedActiveInterval):
1035         (WebCore::SVGAnimationElement::updateAnimation):
1036         * svg/SVGAnimationElement.h:
1037
1038 2008-04-22  Holger Hans Peter Freyther  <zecke@selfish.org>
1039
1040         Unreviewed build fix.
1041
1042         Update WebKit.qrc to catch up with the addition and removal of images
1043         from page/inspector/Images in recent commits.
1044
1045         * page/inspector/WebKit.qrc:
1046
1047 2008-04-22  David Hyatt  <hyatt@apple.com>
1048
1049         Fix for <rdar://5589634>.
1050
1051         Implement CSS alpha masks.  The syntax is very similar to that used for backgrounds.  Multiple mask images
1052         can be specified, and each one can be tiled, positioned, etc.  The following new properties have been
1053         added (all of which are analogous to their background-* counterparts).
1054
1055         mask, mask-image, mask-clip, mask-origin, mask-repeat, mask-attachment, mask-position
1056
1057         The alpha values in the final composite image are used to determine how the mask applies (alpha of 1 = show,
1058         alpha of 0 = don't show).
1059
1060         SVG images and CSS gradients can also be used as masks.
1061
1062         Reviewed by Dan
1063
1064         Added fast/backgrounds/repeat/mask-negative-offset-repeat.html, fast/backgrounds/svg-as-mask.html
1065
1066         * css/CSSMutableStyleDeclaration.cpp:
1067         (WebCore::CSSMutableStyleDeclaration::getPropertyValue):
1068         (WebCore::initShorthandMap):
1069         * css/CSSParser.cpp:
1070         (WebCore::CSSParser::parseFillProperty):
1071         (WebCore::CSSParser::parseTransformOrigin):
1072         * css/CSSStyleSelector.cpp:
1073         (WebCore::CSSStyleSelector::adjustRenderStyle):
1074         (WebCore::CSSStyleSelector::applyProperty):
1075         * rendering/InlineFlowBox.cpp:
1076         (WebCore::InlineFlowBox::paint):
1077         (WebCore::InlineFlowBox::paintFillLayers):
1078         (WebCore::InlineFlowBox::paintFillLayer):
1079         (WebCore::InlineFlowBox::paintBoxDecorations):
1080         (WebCore::InlineFlowBox::paintMask):
1081         * rendering/InlineFlowBox.h:
1082         * rendering/RenderBlock.cpp:
1083         (WebCore::RenderBlock::paint):
1084         (WebCore::RenderBlock::paintObject):
1085         * rendering/RenderBox.cpp:
1086         (WebCore::RenderBox::paintRootBoxDecorations):
1087         (WebCore::RenderBox::paintBoxDecorations):
1088         (WebCore::RenderBox::paintMask):
1089         (WebCore::RenderBox::paintFillLayers):
1090         (WebCore::RenderBox::paintFillLayer):
1091         (WebCore::RenderBox::paintFillLayerExtended):
1092         * rendering/RenderBox.h:
1093         * rendering/RenderFieldset.cpp:
1094         (WebCore::RenderFieldset::paintBoxDecorations):
1095         (WebCore::RenderFieldset::paintMask):
1096         * rendering/RenderFieldset.h:
1097         * rendering/RenderInline.cpp:
1098         (WebCore::RenderInline::requiresLayer):
1099         * rendering/RenderLayer.cpp:
1100         (WebCore::RenderLayer::isTransparent):
1101         (WebCore::RenderLayer::paintLayer):
1102         * rendering/RenderObject.cpp:
1103         (WebCore::RenderObject::requiresLayer):
1104         (WebCore::mustRepaintFillLayers):
1105         (WebCore::RenderObject::mustRepaintBackgroundOrBorder):
1106         (WebCore::RenderObject::setStyle):
1107         (WebCore::RenderObject::updateFillImages):
1108         * rendering/RenderObject.h:
1109         (WebCore::):
1110         (WebCore::RenderObject::hasMask):
1111         (WebCore::RenderObject::paintMask):
1112         (WebCore::RenderObject::paintFillExtended):
1113         * rendering/RenderReplaced.cpp:
1114         (WebCore::RenderReplaced::paint):
1115         * rendering/RenderStyle.cpp:
1116         (WebCore::FillLayer::FillLayer):
1117         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
1118         * rendering/RenderStyle.h:
1119         (WebCore::FillLayer::initialFillComposite):
1120         (WebCore::FillLayer::initialFillSize):
1121         (WebCore::FillLayer::FillLayer):
1122         (WebCore::RenderStyle::hasMask):
1123         * rendering/RenderTable.cpp:
1124         (WebCore::RenderTable::paint):
1125         (WebCore::RenderTable::paintBoxDecorations):
1126         (WebCore::RenderTable::paintMask):
1127         * rendering/RenderTable.h:
1128         * rendering/RenderTableCell.cpp:
1129         (WebCore::RenderTableCell::requiresLayer):
1130         (WebCore::RenderTableCell::paintBackgroundsBehindCell):
1131         (WebCore::RenderTableCell::paintMask):
1132         * rendering/RenderTableCell.h:
1133         * rendering/RenderWidget.cpp:
1134         (WebCore::RenderWidget::paint):
1135         * svg/graphics/SVGImage.cpp:
1136         (WebCore::SVGImage::draw):
1137         (WebCore::SVGImage::dataChanged):
1138
1139 2008-04-22  Sam Weinig  <sam@webkit.org>
1140
1141         Reviewed by Geoffrey Garen.
1142
1143         Make DOMAbstractView have a weak reference to the Frame instead of ref'ing
1144         the DOMWindow.
1145
1146         To ensure that the WindowScriptObject (which is a DOMAbstractView) stays valid
1147         after a navigation once the split window is completed, the DOMAbstractView must
1148         wrap the Frame instead of a DOMWindow since the DOMWindow will change.
1149
1150         * WebCore.xcodeproj/project.pbxproj:
1151         * bindings/objc/DOMAbstractView.mm: Added.
1152         (-[DOMAbstractView dealloc]):
1153         (-[DOMAbstractView finalize]):
1154         (-[DOMAbstractView document]):
1155         (-[DOMAbstractView _disconnectFrame]):
1156         (-[DOMAbstractView WebCore::]):
1157         (-[DOMAbstractView _initWithFrame:WebCore::]):
1158         (+[DOMAbstractView _wrapAbstractView:WebCore::]):
1159         Add custom implementation to implement weak reference semantics.
1160
1161         * bindings/objc/DOMAbstractViewFrame.h: Added.
1162         Declare the [DOMAbstractView _disconectFrame] selector.
1163         * bindings/objc/DOMInternal.h:
1164         Remove DOMRGBColor Internal category since it is now generated.
1165
1166         * bindings/objc/DOMUtility.mm:
1167         (KJS::createDOMWrapper):
1168         Don't ever create a DOMAbstractView from a JSDOMWindow, only from JSDOMWindowWrapper.
1169
1170         * bindings/scripts/CodeGeneratorObjC.pm:
1171         Generate internal header for IDLs that want custom implementations.
1172
1173         * css/RGBColor.idl:
1174         Make this a PODType as it really is in the implementation.
1175
1176         * page/AbstractView.idl:
1177         This now needs a custom objective-c binding implementation.
1178
1179         * page/Frame.cpp:
1180         (WebCore::Frame::~Frame):
1181         disconnect the weak frame reference in the WindowScriptObject.
1182
1183         * page/Frame.h:
1184         * page/gtk/FrameGtk.cpp:
1185         (WebCore::Frame::disconnectPlatformScriptObjects): Dummy implementation.
1186         * page/mac/FrameMac.mm:
1187         (WebCore::Frame::windowScriptObject): ASSERT that the windowScriptObject is a DOMAbstractView.
1188         (WebCore::Frame::disconnectPlatformScriptObjects): Disconnect the frame pointer from the windowScriptObject.
1189         * page/qt/FrameQt.cpp:
1190         (WebCore::Frame::disconnectPlatformScriptObjects): Dummy implementation.
1191         * page/win/FrameWin.cpp:
1192         (WebCore::Frame::disconnectPlatformScriptObjects): Ditto.
1193
1194 2008-04-22  Dan Bernstein  <mitz@apple.com>
1195
1196         Reviewed by Sam Weinig.
1197
1198         - preparation for https://bugs.webkit.org/show_bug.cgi?id=3729
1199           <rdar://problem/4036353> REGRESSION: arrow keys move insertion bar backwards in RTL text
1200
1201         * rendering/bidi.cpp:
1202         (WebCore::RenderBlock::layoutInlineChildren): Make sure to give the
1203         trailing white space a bidi level consistent with its position.
1204
1205 2008-04-22  Timothy Hatcher  <timothy@apple.com>
1206
1207         Remove many unused Web Inspector images.
1208
1209         Rubber-stamped by Adam Roben and Sam Weinig.
1210
1211         * page/inspector/Images/attachedShadow.png: Removed.
1212         * page/inspector/Images/backNormal.png: Removed.
1213         * page/inspector/Images/bottomShadow.png: Removed.
1214         * page/inspector/Images/breadcrumbBackground.png: Removed.
1215         * page/inspector/Images/console.png: Removed.
1216         * page/inspector/Images/databaseBrowserViewNormal.png: Removed.
1217         * page/inspector/Images/databaseBrowserViewNormalSelected.png: Removed.
1218         * page/inspector/Images/databaseBrowserViewSmall.png: Removed.
1219         * page/inspector/Images/databaseBrowserViewSmallSelected.png: Removed.
1220         * page/inspector/Images/databaseQueryViewNormal.png: Removed.
1221         * page/inspector/Images/databaseQueryViewNormalSelected.png: Removed.
1222         * page/inspector/Images/databaseQueryViewSmall.png: Removed.
1223         * page/inspector/Images/databaseQueryViewSmallSelected.png: Removed.
1224         * page/inspector/Images/disclosureDownPressed.png: Removed.
1225         * page/inspector/Images/disclosureRightDown.png: Removed.
1226         * page/inspector/Images/disclosureRightPressed.png: Removed.
1227         * page/inspector/Images/document.png: Removed.
1228         * page/inspector/Images/domViewNormal.png: Removed.
1229         * page/inspector/Images/domViewNormalSelected.png: Removed.
1230         * page/inspector/Images/domViewSmall.png: Removed.
1231         * page/inspector/Images/domViewSmallSelected.png: Removed.
1232         * page/inspector/Images/downTriangle.png: Removed.
1233         * page/inspector/Images/folder.png: Removed.
1234         * page/inspector/Images/forwardNormal.png: Removed.
1235         * page/inspector/Images/gradient.png: Removed.
1236         * page/inspector/Images/gradientHighlight.png: Removed.
1237         * page/inspector/Images/gradientHighlightBottom.png: Removed.
1238         * page/inspector/Images/hideStatusWidget.png: Removed.
1239         * page/inspector/Images/hideStatusWidgetPressed.png: Removed.
1240         * page/inspector/Images/network.png: Removed.
1241         * page/inspector/Images/plainDocument.png: Removed.
1242         * page/inspector/Images/popupArrows.png: Removed.
1243         * page/inspector/Images/popupArrowsBlack.png: Removed.
1244         * page/inspector/Images/reload.png: Removed.
1245         * page/inspector/Images/rightTriangle.png: Removed.
1246         * page/inspector/Images/showStatusWidget.png: Removed.
1247         * page/inspector/Images/showStatusWidgetPressed.png: Removed.
1248         * page/inspector/Images/sidbarItemBackground.png: Removed.
1249         * page/inspector/Images/sidebarActionWidget.png: Removed.
1250         * page/inspector/Images/sidebarActionWidgetPressed.png: Removed.
1251         * page/inspector/Images/sidebarAttachWidget.png: Removed.
1252         * page/inspector/Images/sidebarAttachWidgetPressed.png: Removed.
1253         * page/inspector/Images/sidebarDetachWidget.png: Removed.
1254         * page/inspector/Images/sidebarDetachWidgetPressed.png: Removed.
1255         * page/inspector/Images/sidebarResizeWidget.png: Removed.
1256         * page/inspector/Images/sidebarStatusAreaBackground.png: Removed.
1257         * page/inspector/Images/sourceViewNormal.png: Removed.
1258         * page/inspector/Images/sourceViewNormalSelected.png: Removed.
1259         * page/inspector/Images/sourceViewSmall.png: Removed.
1260         * page/inspector/Images/sourceViewSmallSelected.png: Removed.
1261         * page/inspector/Images/tab.png: Removed.
1262         * page/inspector/Images/tabSelected.png: Removed.
1263         * page/inspector/Images/toggleDown.png: Removed.
1264         * page/inspector/Images/toggleUp.png: Removed.
1265         * page/inspector/Images/toolbarButtonNormal.png: Removed.
1266         * page/inspector/Images/toolbarButtonNormalInactive.png: Removed.
1267         * page/inspector/Images/toolbarButtonNormalPressed.png: Removed.
1268         * page/inspector/Images/toolbarButtonNormalSelected.png: Removed.
1269         * page/inspector/Images/toolbarButtonNormalSelectedInactive.png: Removed.
1270         * page/inspector/Images/toolbarButtonSmall.png: Removed.
1271         * page/inspector/Images/toolbarButtonSmallInactive.png: Removed.
1272         * page/inspector/Images/toolbarButtonSmallPressed.png: Removed.
1273         * page/inspector/Images/toolbarButtonSmallSelected.png: Removed.
1274         * page/inspector/Images/toolbarButtonSmallSelectedInactive.png: Removed.
1275         * page/inspector/Images/toolbarPopupButtonNormal.png: Removed.
1276         * page/inspector/Images/toolbarPopupButtonNormalInactive.png: Removed.
1277         * page/inspector/Images/toolbarPopupButtonNormalPressed.png: Removed.
1278         * page/inspector/Images/toolbarPopupButtonSmall.png: Removed.
1279         * page/inspector/Images/toolbarPopupButtonSmallInactive.png: Removed.
1280         * page/inspector/Images/toolbarPopupButtonSmallPressed.png: Removed.
1281         * page/inspector/Images/toolbarSplitButtonDividerNormal.png: Removed.
1282         * page/inspector/Images/toolbarSplitButtonDividerNormalInactive.png: Removed.
1283         * page/inspector/Images/toolbarSplitButtonDividerSmall.png: Removed.
1284         * page/inspector/Images/toolbarSplitButtonDividerSmallInactive.png: Removed.
1285         * page/inspector/Images/treeLeftTriangleBlack.png: Removed.
1286
1287 2008-04-22  Anders Carlsson  <andersca@apple.com>
1288
1289         Reviewed by Darin.
1290
1291         Add NPN_Construct and NPN_PluginThreadAsyncCall declarations.
1292
1293         * bridge/npapi.h:
1294         * bridge/npruntime.h:
1295         * plugins/npfunctions.h:
1296
1297 2008-04-22  Alice Liu  <alice.liu@apple.com>
1298
1299         Reviewed by John Sullivan and Adam Roben.
1300
1301         Test: fast/events/tabindex-focus-chain.html
1302
1303         * dom/Document.cpp:
1304         (WebCore::Document::nextFocusableNode):
1305         (WebCore::Document::previousFocusableNode):
1306         If the focused node has been removed from the normal tabbing order,
1307         advancing focus from this node should advance to the next focusable
1308         node in tree order, and not start over at the beginning of the focus
1309         chain. 
1310
1311 2008-04-22  Timothy Hatcher  <timothy@apple.com>
1312
1313         Adds a debugger toggle button to the scripts status bar that will start
1314         and stop debugging of the inspected page.
1315
1316         Reviewed by Adam Roben.
1317
1318         * English.lproj/InspectorLocalizedStrings.js: Adds the two new tooltip strings.
1319         * page/InspectorController.cpp:
1320         (WebCore::debuggerAttached): Call InspectorController::debuggerAttached.
1321         (WebCore::InspectorController::InspectorController): Initialize
1322         m_debuggerAttached to false.
1323         (WebCore::InspectorController::windowScriptObjectAvailable): Add the debuggerAttached
1324         property to the InspectorController class.
1325         (WebCore::InspectorController::startDebuggingAndReloadInspectedPage):
1326         Set m_debuggerAttached to true.
1327         (WebCore::InspectorController::stopDebugging): Set m_debuggerAttached to false.
1328         * page/InspectorController.h:
1329         * page/inspector/Images/debuggingButtons.png: Added.
1330         * page/inspector/ScriptsPanel.js:
1331         (WebInspector.ScriptsPanel): Disable the pause button. Create the debugging
1332         button and setup the id, className and event listener. Call reset.
1333         (WebInspector.ScriptsPanel.prototype.get statusBarItems): Return an array
1334         (WebInspector.ScriptsPanel.prototype.reset): Call _updateDebuggerButtons.
1335         (WebInspector.ScriptsPanel.prototype._updateDebuggerButtons): Adjust the title of
1336         the debugging button to match what will happen when clicked. Change the style class,
1337         and toggle the disabled state of the pause button.
1338         (WebInspector.ScriptsPanel.prototype._toggleDebugging): Start or stop debugging
1339         depending on InspectorController.debuggerAttached().
1340         * page/inspector/inspector.css: Added style rules for the debugger button.
1341
1342 2008-04-21  Adam Roben  <aroben@apple.com>
1343
1344         Change PlatformWheelEvent to use GET_WHEEL_DELTA_WPARAM
1345
1346         Reviewed by Dan Bernstein.
1347
1348         * platform/win/WheelEventWin.cpp:
1349         (WebCore::PlatformWheelEvent::PlatformWheelEvent): Use
1350         GET_WHEEL_DELTA_WPARAM, which is documented way of getting the wheel
1351         delta (it is equivalent to what we were previously doing, however).
1352
1353 2008-04-22  Simon Hausmann  <hausmann@webkit.org>
1354
1355         Qt build fix.
1356
1357         Adjust the Qt resource file to removed image files.
1358
1359         * page/inspector/WebKit.qrc:
1360
1361 2008-04-21  Timothy Hatcher  <timothy@apple.com>
1362
1363         Use CSS gradients to replace many image files in the Web Inspector.
1364
1365         Rubber-stamped by Adam Roben.
1366
1367         * page/inspector/Images/alternateTableRows.png: Removed.
1368         * page/inspector/Images/darkShadow.png: Removed.
1369         * page/inspector/Images/paneHeader.png: Removed.
1370         * page/inspector/Images/paneHeaderActive.png: Removed.
1371         * page/inspector/Images/sidebarSelection.png: Removed.
1372         * page/inspector/Images/sidebarSelectionBackground.png: Removed.
1373         * page/inspector/Images/sidebarSelectionBackgroundFocused.png: Removed.
1374         * page/inspector/Images/sidebarSelectionBackgroundInactive.png: Removed.
1375         * page/inspector/Images/sidebarSelectionBlurred.png: Removed.
1376         * page/inspector/Images/sidebarSelectionBlurredTall.png: Removed.
1377         * page/inspector/Images/sidebarSelectionGray.png: Removed.
1378         * page/inspector/Images/sidebarSelectionGrayTall.png: Removed.
1379         * page/inspector/Images/sidebarSelectionTall.png: Removed.
1380         * page/inspector/Images/sidebarSmallSelectionBackground.png: Removed.
1381         * page/inspector/Images/sidebarSmallSelectionBackgroundFocused.png: Removed.
1382         * page/inspector/Images/sidebarSmallSelectionBackgroundInactive.png: Removed.
1383         * page/inspector/Images/toolbarBackground.png: Removed.
1384         * page/inspector/Images/toolbarBackgroundInactive.png: Removed.
1385         * page/inspector/inspector.css:
1386
1387 2008-04-22  Andre Poenitz  <andre.poenitz@trolltech.com>
1388
1389         Reviewed by Simon.
1390
1391         Remove compiler warnings on string literals used to construct QStrings
1392         in webkit.
1393
1394         * bridge/qt/qt_instance.cpp:
1395         (KJS::Bindings::QtField::valueFromInstance):
1396         (KJS::Bindings::QtField::setValueToInstance):
1397         * bridge/qt/qt_runtime.cpp:
1398         (KJS::Bindings::convertValueToQVariant):
1399         (KJS::Bindings::QtRuntimeConnectionMethod::callAsFunction):
1400
1401 2008-04-22  Tor Arne Vestbø  <tavestbo@trolltech.com>
1402
1403         Reviewed by Simon.
1404
1405         Fall back to last path component for suggested filename if the HTTP content disposition is not set.
1406
1407         * platform/network/qt/QNetworkReplyHandler.cpp:
1408         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
1409
1410 2008-04-22  Tor Arne Vestbø  <tavestbo@trolltech.com>
1411
1412         Reviewed by Simon.
1413
1414         Implemented the generation of the title string for images.
1415
1416         * platform/qt/Localizations.cpp:
1417
1418 2008-04-22  Simon Hausmann  <hausmann@webkit.org>
1419
1420         Qt build fix.
1421
1422         * platform/qt/RenderThemeQt.cpp: Adjust isControlStyled signature to
1423         the signature in the base class.
1424         * platform/qt/RenderThemeQt.h: Ditto.
1425
1426 2008-04-19  Jon Honeycutt  <jhoneycutt@apple.com>
1427
1428         Reviewed by Darin.
1429
1430         Add a method to get the AccessibilityObject's access key,
1431
1432         * page/AccessibilityObject.cpp:
1433         (WebCore::AccessibilityObject::accessKey): Added; returns the object's
1434         access key attribute.
1435         * page/AccessibilityObject.h: Added declaration for accessKey().
1436
1437 2008-04-21  Sam Weinig  <sam@webkit.org>
1438
1439         Reviewed by Anders Carlsson.
1440
1441         Fix numerous crashing tests.
1442
1443         * html/HTMLHtmlElement.cpp:
1444         (WebCore::HTMLHtmlElement::insertedIntoDocument): Null check document->frame().
1445
1446 2008-04-21  Dan Bernstein  <mitz@apple.com>
1447
1448         Reviewed by Darin Adler.
1449
1450         Tests: fast/media/implicit-media-all.html
1451                fast/media/monochrome.html
1452
1453         - allow implicit "all" media in media queries
1454         - use a value of 0 for the monochrome media feature on color displays
1455
1456         * css/CSSGrammar.y:
1457         * css/CSSParser.cpp:
1458         (WebCore::CSSParser::createFloatingMediaQuery):
1459         * css/CSSParser.h:
1460         * css/MediaQueryEvaluator.cpp:
1461         (WebCore::monochromeMediaFeatureEval):
1462
1463 2008-04-21  Brady Eidson  <beidson@apple.com>
1464
1465         Rockingly reviewed by Adele
1466
1467         Small StorageArea cleanups
1468
1469         * storage/SessionStorageArea.cpp:
1470         (WebCore::SessionStorageArea::copy): Pass "this" instead of the StorageMap belonging to this
1471         (WebCore::SessionStorageArea::SessionStorageArea):
1472         * storage/SessionStorageArea.h:
1473
1474         * storage/StorageArea.cpp:  Changed to not expose the StorageMap at all - it's dangerous to expose
1475           it since we rely explicitly on its ref-count
1476         (WebCore::StorageArea::StorageArea): Take another StorageArea as the c'tor argument and get the 
1477           StorageMap from that.
1478         (WebCore::StorageArea::setItem):  The previous comment/code here was bogus.  All JS objects passed in
1479           to this API are stringified, so there's no such thing as "null" for setItem()
1480         * storage/StorageArea.h:
1481
1482 2008-04-21  Justin Garcia  <justin.garcia@apple.com>
1483
1484         Reviewed by John Sullivan.
1485
1486         <rdar://problem/5803706> Pressing return at the end of a header doesn't break out of header (17460)
1487         
1488         If we're doing InsertParagraphSeparator at the end of a header element, do not clone it.
1489         Renamed m_useDefaultParagraphElement to m_mustUseDefaultParagraphElement, since now,
1490         when it is false, that does not necessarily mean that a default paragraph element
1491         will not be used.  Callers that passed false for this argument are OK with this.
1492
1493         * editing/InsertParagraphSeparatorCommand.cpp:
1494         (WebCore::InsertParagraphSeparatorCommand::InsertParagraphSeparatorCommand): 
1495         (WebCore::InsertParagraphSeparatorCommand::shouldUseDefaultParagraphElement):
1496         (WebCore::InsertParagraphSeparatorCommand::doApply):
1497         * editing/InsertParagraphSeparatorCommand.h:
1498
1499 2008-04-21  Anders Carlsson  <andersca@apple.com>
1500
1501         Reviewed by Adam.
1502
1503         Perform cache selection. If a main resource has a URL that exists in a cache, load it from there.
1504         
1505         * html/HTMLAttributeNames.in:
1506         Add manifest attribute.
1507         
1508         * html/HTMLHtmlElement.cpp:
1509         (WebCore::HTMLHtmlElement::insertedIntoDocument):
1510         * html/HTMLHtmlElement.h:
1511         Perform cache selection.
1512         
1513         * loader/MainResourceLoader.cpp:
1514         (WebCore::MainResourceLoader::load):
1515         * loader/appcache/ApplicationCacheGroup.cpp:
1516         (WebCore::cacheHostSet):
1517         (WebCore::urlHostHash):
1518         (WebCore::ApplicationCacheGroup::cacheForRequest):
1519         (WebCore::ApplicationCacheGroup::selectCache):
1520         * loader/appcache/ApplicationCacheGroup.h:
1521         * platform/KURL.h:
1522         (WebCore::KURL::hostStart):
1523         (WebCore::KURL::hostEnd):
1524
1525 2008-04-21  Mike Belshe  <mike@belshe.com>
1526
1527         Reviewed by eseidel and darin.  Landed by eseidel.
1528
1529         Fix broken optimization in createStrippingNullCharacters.
1530
1531         * platform/text/StringImpl.cpp:
1532         (WebCore::StringImpl::createStrippingNullCharacters):
1533
1534 2008-04-21  David Hyatt  <hyatt@apple.com>
1535
1536         Make the back end parsing of background properties generic.  Rename all the parsing functions from
1537         background -> fill.
1538
1539         Add a new set of properties for doing masks.  The code is now refactored so that the mask properties
1540         and the background properties share parsing routines.
1541
1542         Reviewed by Dan
1543
1544         * css/CSSComputedStyleDeclaration.cpp:
1545         (WebCore::):
1546         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1547         * css/CSSParser.cpp:
1548         (WebCore::CSSParser::parseValue):
1549         (WebCore::CSSParser::addFillValue):
1550         (WebCore::CSSParser::parseFillShorthand):
1551         (WebCore::CSSParser::parseFillImage):
1552         (WebCore::CSSParser::parseFillPositionXY):
1553         (WebCore::CSSParser::parseFillPosition):
1554         (WebCore::CSSParser::parseFillSize):
1555         (WebCore::CSSParser::parseFillProperty):
1556         (WebCore::CSSParser::parseTransformOrigin):
1557         * css/CSSParser.h:
1558         * css/CSSPropertyNames.in:
1559         * css/CSSStyleSelector.cpp:
1560         (WebCore::CSSStyleSelector::CSSStyleSelector):
1561         (WebCore::CSSStyleSelector::mapFillAttachment):
1562         (WebCore::CSSStyleSelector::mapFillClip):
1563         (WebCore::CSSStyleSelector::mapFillComposite):
1564         (WebCore::CSSStyleSelector::mapFillOrigin):
1565         (WebCore::CSSStyleSelector::mapFillImage):
1566         (WebCore::CSSStyleSelector::mapFillRepeat):
1567         (WebCore::CSSStyleSelector::mapFillSize):
1568         (WebCore::CSSStyleSelector::mapFillXPosition):
1569         (WebCore::CSSStyleSelector::mapFillYPosition):
1570         * rendering/RenderStyle.cpp:
1571         (WebCore::FillLayer::FillLayer):
1572         (WebCore::FillLayer::operator=):
1573         (WebCore::FillLayer::operator==):
1574         (WebCore::StyleBackgroundData::StyleBackgroundData):
1575         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
1576         (WebCore::StyleRareNonInheritedData::operator==):
1577         (WebCore::RenderStyle::diff):
1578         * rendering/RenderStyle.h:
1579         (WebCore::LengthSize::LengthSize):
1580         (WebCore::):
1581         (WebCore::FillLayer::type):
1582         (WebCore::FillLayer::initialFillAttachment):
1583         (WebCore::FillLayer::initialFillClip):
1584         (WebCore::FillLayer::initialFillOrigin):
1585         (WebCore::FillLayer::initialFillRepeat):
1586         (WebCore::FillLayer::initialFillComposite):
1587         (WebCore::FillLayer::initialFillSize):
1588         (WebCore::FillLayer::initialFillXPosition):
1589         (WebCore::FillLayer::initialFillYPosition):
1590         (WebCore::FillLayer::initialFillImage):
1591         (WebCore::RenderStyle::maskImage):
1592         (WebCore::RenderStyle::maskRepeat):
1593         (WebCore::RenderStyle::maskComposite):
1594         (WebCore::RenderStyle::maskAttachment):
1595         (WebCore::RenderStyle::maskClip):
1596         (WebCore::RenderStyle::maskOrigin):
1597         (WebCore::RenderStyle::maskXPosition):
1598         (WebCore::RenderStyle::maskYPosition):
1599         (WebCore::RenderStyle::maskSize):
1600         (WebCore::RenderStyle::accessMaskLayers):
1601         (WebCore::RenderStyle::maskLayers):
1602         (WebCore::RenderStyle::clearBackgroundLayers):
1603         (WebCore::RenderStyle::clearMaskLayers):
1604         (WebCore::RenderStyle::inheritMaskLayers):
1605
1606 2008-04-21  Timothy Hatcher  <timothy@apple.com>
1607
1608         Fixes the issue were a Database view could still be visible after navigating to a new page.
1609
1610         Reviewed by Darin Adler.
1611
1612         * page/inspector/DatabasesPanel.js:
1613         (WebInspector.DatabasesPanel.prototype.reset): Delete the _tableViews and _queryView properties
1614         from all databases. Remove all the children from databaseViews.
1615
1616 2008-04-21  Timothy Hatcher  <timothy@apple.com>
1617
1618         Adds the ability to enter multi-line commands in the console by holding the
1619         alt/option key when pressing enter/return.
1620
1621         https://bugs.webkit.org/show_bug.cgi?id=18454
1622
1623         Reviewed by Darin Adler.
1624
1625         * page/inspector/Console.js:
1626         (WebInspector.Console.prototype._enterKeyPressed): Return early if the
1627         alt/option key is held when enter is pressed.
1628         * page/inspector/inspector.css:
1629         (.console-message-text): Added. Set white-space: pre-wrap.
1630
1631 2008-04-21  Timothy Hatcher  <timothy@apple.com>
1632
1633         Fixes the bug where the Database table names do not update when
1634         running the CREATE TABLE or DROP TABLE queries. Also makes the
1635         table names update every time the database is collapsed and expanded.
1636
1637         https://bugs.webkit.org/show_bug.cgi?id=18453
1638
1639         Reviewed by Darin Adler.
1640
1641         * page/inspector/DatabasesPanel.js:
1642         (WebInspector.DatabasesPanel.prototype.updateDatabaseTables):
1643         Set shouldRefreshChildren to true on the Database's tree element.
1644         The refreshChildren property was renamed to shouldRefreshChildren.
1645         (WebInspector.DatabaseSidebarTreeElement.prototype.oncollapse):
1646         Request a refresh after every collapse so the next expand will
1647         have an updated table list.
1648
1649 2008-04-21  Timothy Hatcher  <timothy@apple.com>
1650
1651         Adds INDEX to the list of completion words for the Databases query view.
1652
1653         https://bugs.webkit.org/show_bug.cgi?id=18452
1654
1655         Reviewed by Darin Adler.
1656
1657         * page/inspector/DatabaseQueryView.js:
1658         (WebInspector.DatabaseQueryView.prototype.completions): Split up "CREATE TABLE "
1659         and "DROP TABLE " into "CREATE ", "DROP ", "TABLE ". And added "INDEX ".
1660
1661 2008-04-21  Timothy Hatcher  <timothy@apple.com>
1662
1663         Adds the UI portions of the Scripts panel to the Web Inspector.
1664         The Scripts panel has not been added to the toolbar yet.
1665
1666         https://bugs.webkit.org/show_bug.cgi?id=18601
1667
1668         Reviewed by Adam Roben.
1669
1670         * English.lproj/InspectorLocalizedStrings.js: Changed "Show inherited properties"
1671         to "Show inherited". Adds new strings for the Scripts' panel tooltips.
1672         * page/inspector/BreakpointsSidebarPane.js: Added.
1673         * page/inspector/CallStackSidebarPane.js: Added.
1674         * page/inspector/Images/back.png: Added.
1675         * page/inspector/Images/debuggerContinue.png: Added.
1676         * page/inspector/Images/debuggerPause.png: Added.
1677         * page/inspector/Images/debuggerStepInto.png: Added.
1678         * page/inspector/Images/debuggerStepOut.png: Added.
1679         * page/inspector/Images/debuggerStepOver.png: Added.
1680         * page/inspector/Images/forward.png: Added.
1681         * page/inspector/Images/statusbarResizerHorizontal.png: Added.
1682         * page/inspector/PropertiesSection.js:
1683         (WebInspector.PropertiesSection): Flip the order the subtile is appended
1684         so it can float right in the CSS.
1685         * page/inspector/ScriptsPanel.js: Added.
1686         * page/inspector/StylesSidebarPane.js:
1687         (WebInspector.StylePropertiesSection): Changed "Show inherited properties"
1688         to "Show inherited".
1689         * page/inspector/inspector.css: Added new CSS rules for the Scripts panel. 
1690         Also changes the look of the section to match the mockup, this affects
1691         Styles and Properties in Elements.
1692         * page/inspector/inspector.html: Import new files.
1693         * page/inspector/inspector.js:
1694         (Preferences.minScriptsSidebarWidth): Added.
1695
1696 2008-04-21  Kevin McCullough  <kmccullough@apple.com>
1697
1698         Reviewed by Adam.
1699
1700         <rdar://problem/5770054> JavaScript profiler (10928)
1701         Took out debugging printing since we really want to hook into the
1702         inspector and not to print to the terminal.
1703
1704         * page/Console.cpp:
1705         (WebCore::Console::profileEnd):
1706
1707 2008-04-21  Sam Weinig  <sam@webkit.org>
1708
1709         Reviewed by Alexey Proskuryakov.
1710
1711         Fix up XMLHttpRequestProgressEvent.
1712
1713         * bindings/js/JSEventCustom.cpp:
1714         (WebCore::toJS):
1715         * xml/XMLHttpRequestProgressEvent.cpp:
1716         * xml/XMLHttpRequestProgressEvent.h:
1717
1718 2008-04-21  Adam Roben  <aroben@apple.com>
1719
1720         Fix Bug 18615: Crash in PluginPackage::hash
1721
1722         <https://bugs.webkit.org/show_bug.cgi?id=18615>
1723
1724         Reviewed by Anders Carlsson.
1725
1726         * plugins/PluginDatabase.cpp:
1727         (WebCore::PluginDatabase::refresh): Don't pass a null PluginPackage*
1728         to add().
1729
1730 2008-04-21  Anders Carlsson  <andersca@apple.com>
1731
1732         Reviewed by Adam.
1733
1734         Add cache group implementation.
1735
1736         * loader/DocumentLoader.cpp:
1737         (WebCore::DocumentLoader::scheduleApplicationCacheLoad):
1738         * loader/appcache/ApplicationCache.cpp:
1739         (WebCore::ApplicationCache::requestIsHTTPOrHTTPSGet):
1740         (WebCore::ApplicationCache::resourceForRequest):
1741         * loader/appcache/ApplicationCache.h:
1742         * loader/appcache/ApplicationCacheGroup.cpp:
1743         (WebCore::cacheGroupMap):
1744         (WebCore::ApplicationCacheGroup::ApplicationCacheGroup):
1745         (WebCore::ApplicationCacheGroup::selectCache):
1746         (WebCore::ApplicationCacheGroup::selectCacheWithoutManifestURL):
1747         (WebCore::ApplicationCacheGroup::finishedLoadingMainResource):
1748         (WebCore::ApplicationCacheGroup::documentLoaderDestroyed):
1749         (WebCore::ApplicationCacheGroup::cacheDestroyed):
1750         (WebCore::ApplicationCacheGroup::update):
1751         (WebCore::ApplicationCacheGroup::didReceiveResponse):
1752         (WebCore::ApplicationCacheGroup::didReceiveData):
1753         (WebCore::ApplicationCacheGroup::didFinishLoading):
1754         (WebCore::ApplicationCacheGroup::didFail):
1755         (WebCore::ApplicationCacheGroup::didReceiveManifestResponse):
1756         (WebCore::ApplicationCacheGroup::didReceiveManifestData):
1757         (WebCore::ApplicationCacheGroup::didFinishLoadingManifest):
1758         (WebCore::ApplicationCacheGroup::cacheUpdateFailed):
1759         (WebCore::ApplicationCacheGroup::didFailToLoadManifest):
1760         (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete):
1761         (WebCore::ApplicationCacheGroup::startLoadingEntry):
1762         (WebCore::ApplicationCacheGroup::addEntry):
1763         (WebCore::ApplicationCacheGroup::associateDocumentLoaderWithCache):
1764         (WebCore::ApplicationCacheGroup::callListenersOnAssociatedDocuments):
1765         (WebCore::ApplicationCacheGroup::callListeners):
1766         * loader/appcache/ApplicationCacheGroup.h:
1767         (WebCore::ApplicationCacheGroup::status):
1768         (WebCore::ApplicationCacheGroup::newestCache):
1769         * platform/KURL.h:
1770         (WebCore::KURL::hostStart):
1771         (WebCore::KURL::hostEnd):
1772
1773 2008-04-21  David Hyatt  <hyatt@apple.com>
1774
1775         Rename BackgroundLayer -> FillLayer in preparation for it being used for other types of fills.
1776
1777         Reviewed by Dan
1778
1779         * css/CSSComputedStyleDeclaration.cpp:
1780         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1781         * css/CSSPrimitiveValueMappings.h:
1782         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
1783         (WebCore::CSSPrimitiveValue::operator EFillBox):
1784         (WebCore::CSSPrimitiveValue::operator EFillRepeat):
1785         * css/CSSStyleSelector.cpp:
1786         (WebCore::CSSStyleSelector::applyProperty):
1787         (WebCore::CSSStyleSelector::mapFillAttachment):
1788         (WebCore::CSSStyleSelector::mapFillClip):
1789         (WebCore::CSSStyleSelector::mapFillComposite):
1790         (WebCore::CSSStyleSelector::mapFillOrigin):
1791         (WebCore::CSSStyleSelector::mapFillImage):
1792         (WebCore::CSSStyleSelector::mapFillRepeat):
1793         (WebCore::CSSStyleSelector::mapFillSize):
1794         (WebCore::CSSStyleSelector::mapFillXPosition):
1795         (WebCore::CSSStyleSelector::mapFillYPosition):
1796         (WebCore::CSSStyleSelector::mapTransitionDuration):
1797         (WebCore::CSSStyleSelector::mapTransitionRepeatCount):
1798         (WebCore::CSSStyleSelector::mapTransitionTimingFunction):
1799         (WebCore::CSSStyleSelector::mapTransitionProperty):
1800         * css/CSSStyleSelector.h:
1801         * page/AnimationController.cpp:
1802         (WebCore::ImplicitAnimation::ImplicitAnimation):
1803         (WebCore::CompositeImplicitAnimation::animate):
1804         * rendering/InlineFlowBox.cpp:
1805         (WebCore::InlineFlowBox::paintBackgrounds):
1806         (WebCore::InlineFlowBox::paintBackground):
1807         * rendering/InlineFlowBox.h:
1808         * rendering/RenderBox.cpp:
1809         (WebCore::RenderBox::paintRootBoxDecorations):
1810         (WebCore::RenderBox::paintBackgrounds):
1811         (WebCore::RenderBox::paintBackground):
1812         (WebCore::RenderBox::calculateBackgroundSize):
1813         (WebCore::RenderBox::imageChanged):
1814         (WebCore::RenderBox::calculateBackgroundImageGeometry):
1815         (WebCore::RenderBox::paintBackgroundExtended):
1816         * rendering/RenderBox.h:
1817         * rendering/RenderObject.cpp:
1818         (WebCore::RenderObject::mustRepaintBackgroundOrBorder):
1819         (WebCore::RenderObject::updateBackgroundImages):
1820         (WebCore::RenderObject::arenaDelete):
1821         * rendering/RenderObject.h:
1822         (WebCore::RenderObject::paintBackgroundExtended):
1823         * rendering/RenderStyle.cpp:
1824         (WebCore::FillLayer::FillLayer):
1825         (WebCore::FillLayer::~FillLayer):
1826         (WebCore::FillLayer::operator=):
1827         (WebCore::FillLayer::operator==):
1828         (WebCore::FillLayer::fillUnsetProperties):
1829         (WebCore::FillLayer::cullEmptyLayers):
1830         (WebCore::Transition::fillUnsetProperties):
1831         * rendering/RenderStyle.h:
1832         (WebCore::):
1833         (WebCore::FillLayer::image):
1834         (WebCore::FillLayer::xPosition):
1835         (WebCore::FillLayer::yPosition):
1836         (WebCore::FillLayer::attachment):
1837         (WebCore::FillLayer::clip):
1838         (WebCore::FillLayer::origin):
1839         (WebCore::FillLayer::repeat):
1840         (WebCore::FillLayer::composite):
1841         (WebCore::FillLayer::size):
1842         (WebCore::FillLayer::next):
1843         (WebCore::FillLayer::isImageSet):
1844         (WebCore::FillLayer::isXPositionSet):
1845         (WebCore::FillLayer::isYPositionSet):
1846         (WebCore::FillLayer::isAttachmentSet):
1847         (WebCore::FillLayer::isClipSet):
1848         (WebCore::FillLayer::isOriginSet):
1849         (WebCore::FillLayer::isRepeatSet):
1850         (WebCore::FillLayer::isCompositeSet):
1851         (WebCore::FillLayer::isSizeSet):
1852         (WebCore::FillLayer::setImage):
1853         (WebCore::FillLayer::setXPosition):
1854         (WebCore::FillLayer::setYPosition):
1855         (WebCore::FillLayer::setAttachment):
1856         (WebCore::FillLayer::setClip):
1857         (WebCore::FillLayer::setOrigin):
1858         (WebCore::FillLayer::setRepeat):
1859         (WebCore::FillLayer::setComposite):
1860         (WebCore::FillLayer::setSize):
1861         (WebCore::FillLayer::clearImage):
1862         (WebCore::FillLayer::clearXPosition):
1863         (WebCore::FillLayer::clearYPosition):
1864         (WebCore::FillLayer::clearAttachment):
1865         (WebCore::FillLayer::clearClip):
1866         (WebCore::FillLayer::clearOrigin):
1867         (WebCore::FillLayer::clearRepeat):
1868         (WebCore::FillLayer::clearComposite):
1869         (WebCore::FillLayer::clearSize):
1870         (WebCore::FillLayer::setNext):
1871         (WebCore::FillLayer::operator!=):
1872         (WebCore::FillLayer::hasFixedImage):
1873         (WebCore::Transition::isDurationSet):
1874         (WebCore::Transition::isRepeatCountSet):
1875         (WebCore::Transition::isTimingFunctionSet):
1876         (WebCore::Transition::isPropertySet):
1877         (WebCore::Transition::clearDuration):
1878         (WebCore::Transition::clearRepeatCount):
1879         (WebCore::Transition::clearTimingFunction):
1880         (WebCore::Transition::clearProperty):
1881         (WebCore::Transition::duration):
1882         (WebCore::Transition::repeatCount):
1883         (WebCore::Transition::timingFunction):
1884         (WebCore::Transition::property):
1885         (WebCore::Transition::setDuration):
1886         (WebCore::Transition::setRepeatCount):
1887         (WebCore::Transition::setTimingFunction):
1888         (WebCore::Transition::setProperty):
1889         (WebCore::RenderStyle::NonInheritedFlags::operator==):
1890         (WebCore::RenderStyle::setBitDefaults):
1891         (WebCore::RenderStyle::backgroundRepeat):
1892         (WebCore::RenderStyle::backgroundComposite):
1893         (WebCore::RenderStyle::backgroundAttachment):
1894         (WebCore::RenderStyle::backgroundClip):
1895         (WebCore::RenderStyle::backgroundOrigin):
1896         (WebCore::RenderStyle::backgroundSize):
1897         (WebCore::RenderStyle::accessBackgroundLayers):
1898         (WebCore::RenderStyle::backgroundLayers):
1899         (WebCore::RenderStyle::clearBackgroundLayers):
1900         (WebCore::RenderStyle::inheritBackgroundLayers):
1901         (WebCore::RenderStyle::initialFillAttachment):
1902         (WebCore::RenderStyle::initialFillClip):
1903         (WebCore::RenderStyle::initialFillOrigin):
1904         (WebCore::RenderStyle::initialFillRepeat):
1905         (WebCore::RenderStyle::initialFillComposite):
1906         (WebCore::RenderStyle::initialFillSize):
1907         (WebCore::RenderStyle::initialFillXPosition):
1908         (WebCore::RenderStyle::initialFillYPosition):
1909         (WebCore::RenderStyle::initialFillImage):
1910         (WebCore::RenderStyle::initialWhiteSpace):
1911         (WebCore::RenderStyle::initialColor):
1912         * rendering/RenderTableCell.cpp:
1913         (WebCore::RenderTableCell::paintBackgroundsBehindCell):
1914         * rendering/RenderTheme.cpp:
1915         (WebCore::RenderTheme::adjustStyle):
1916         (WebCore::RenderTheme::isControlStyled):
1917         * rendering/RenderTheme.h:
1918         * rendering/RenderThemeMac.h:
1919         * rendering/RenderThemeMac.mm:
1920         (WebCore::RenderThemeMac::isControlStyled):
1921
1922 2008-04-21  Julien Chaffraix  <jchaffraix@webkit.org>
1923
1924         Rubber-stamped by Ap.
1925
1926         Add 2 explicit casts.
1927         Fixes built on 64-bit machines (64-bit to 32-bit conversion warning).
1928
1929         * xml/XMLHttpRequest.cpp:
1930         (WebCore::XMLHttpRequest::dispatchProgressEvent):
1931
1932 2008-04-21  Anders Carlsson  <andersca@apple.com>
1933
1934         Reviewed by Adam.
1935
1936         Make it possible to load resources from the cache. 
1937         (Currently no documents are ever associated with a cache though.)
1938         
1939         * loader/DocumentLoader.cpp:
1940         (WebCore::DocumentLoader::setPrimaryLoadComplete):
1941         (WebCore::DocumentLoader::mainResourceApplicationCache):
1942         (WebCore::DocumentLoader::scheduleApplicationCacheLoad):
1943         * loader/DocumentLoader.h:
1944         * loader/MainResourceLoader.cpp:
1945         (WebCore::MainResourceLoader::didFinishLoading):
1946         (WebCore::MainResourceLoader::load):
1947         * loader/MainResourceLoader.h:
1948         (WebCore::MainResourceLoader::applicationCache):
1949         * loader/ResourceLoader.cpp:
1950         (WebCore::ResourceLoader::ResourceLoader):
1951         (WebCore::ResourceLoader::load):
1952         * loader/ResourceLoader.h:
1953         * loader/appcache/ApplicationCacheGroup.h:
1954         (WebCore::ApplicationCacheGroup::finishedLoadingMainResource):
1955
1956 2008-04-21  MorganL  <morganl.webkit@yahoo.com>
1957
1958         Reviewed by eseidel.  Landed by eseidel.
1959
1960         Add FrameLoader::policyDocumentLoader, and change
1961         provisionalDocumentLoader to have a const signature to be
1962         consistent with documentLoader and activeDocumentLoader.
1963
1964         * WebCore.base.exp:
1965         * WebCore.order:
1966         * loader/FrameLoader.cpp:
1967         (WebCore::FrameLoader::policyDocumentLoader):
1968         (WebCore::FrameLoader::provisionalDocumentLoader):
1969         * loader/FrameLoader.h:
1970
1971 2008-04-21  Julien Chaffraix  <jchaffraix@webkit.org>
1972
1973         Not reviewed, add missing files in my previous commit.
1974
1975         Test: http/tests/xmlhttprequest/infoOnProgressEvent.html
1976
1977         * xml/XMLHttpRequestProgressEvent.cpp: Added.
1978         (WebCore::XMLHttpRequestProgressEvent::XMLHttpRequestProgressEvent):
1979         (WebCore::XMLHttpRequestProgressEvent::position):
1980         (WebCore::XMLHttpRequestProgressEvent::totalSize):
1981         * xml/XMLHttpRequestProgressEvent.h: Added.
1982         (WebCore::XMLHttpRequestProgressEvent::isXMLHttpRequestProgressEvent):
1983         (WebCore::XMLHttpRequestProgressEvent::isProgressEvent):
1984         (WebCore::XMLHttpRequestProgressEvent::lengthComputable):
1985         (WebCore::XMLHttpRequestProgressEvent::loaded):
1986         (WebCore::XMLHttpRequestProgressEvent::total):
1987         * xml/XMLHttpRequestProgressEvent.idl: Added.
1988
1989 2008-04-21  Julien Chaffraix  <jchaffraix@webkit.org>
1990
1991         Reviewed by Ap.
1992
1993         Bug 13596: Implement .onprogress handler on XMLHttpRequest objects to support
1994         progressive download content length information.
1995
1996         - Add the onprogress attribute to XMLHttpRequest and the necessary bindings.
1997
1998         - We use a custom event XMLHttpRequestProgressEvent that is derived from ProgressEvent
1999          (as specified by the XHR2 specification) but also implement LSProgressEvent interface
2000          (to be compliant with Firefox event).
2001
2002         Test: http/tests/xmlhttprequest/infoOnProgressEvent.html
2003
2004         * DerivedSources.make:
2005         * GNUmakefile.am:
2006         * WebCore.pro:
2007         * WebCore.vcproj/WebCore.vcproj:
2008         * WebCore.xcodeproj/project.pbxproj:
2009         * WebCoreSources.bkl:
2010         * bindings/js/JSEventCustom.cpp:
2011         (WebCore::toJS):
2012         * bindings/js/JSXMLHttpRequestCustom.cpp:
2013         (WebCore::JSXMLHttpRequest::mark):
2014         (WebCore::JSXMLHttpRequest::onprogress):
2015         (WebCore::JSXMLHttpRequest::setOnprogress):
2016         * dom/Event.cpp:
2017         (WebCore::Event::isXMLHttpRequestProgressEvent):
2018         * dom/Event.h:
2019         * dom/ProgressEvent.h: Replaced 'private' by 'protected' to enable derivation.
2020         * xml/XMLHttpRequest.cpp:
2021         (WebCore::XMLHttpRequest::onProgressListener): onprogress getter.
2022         (WebCore::XMLHttpRequest::setOnProgressListener): onprogress setter.
2023         (WebCore::XMLHttpRequest::XMLHttpRequest): initialize m_receivedLength.
2024         (WebCore::XMLHttpRequest::internalAbort): reset m_receivedLength on abort.
2025         (WebCore::XMLHttpRequest::didReceiveData): add updateAndDispatchOnProgress call.
2026         (WebCore::XMLHttpRequest::updateAndDispatchOnProgress):
2027         (WebCore::XMLHttpRequest::dispatchProgressEvent):
2028         * xml/XMLHttpRequest.h:
2029         * xml/XMLHttpRequest.idl: Add onprogress event handler.
2030         * xml/XMLHttpRequestProgressEvent.cpp: Added.
2031         (WebCore::XMLHttpRequestProgressEvent::XMLHttpRequestProgressEvent):
2032         (WebCore::XMLHttpRequestProgressEvent::position):
2033         (WebCore::XMLHttpRequestProgressEvent::totalSize):
2034         The two previous methods are used for Firefox compatibility and map to the
2035         same value as the ProgressEvent methods (but they are deprecated and display
2036
2037         * xml/XMLHttpRequestProgressEvent.h: Added.
2038         (WebCore::XMLHttpRequestProgressEvent::isXMLHttpRequestProgressEvent):
2039         (WebCore::XMLHttpRequestProgressEvent::isProgressEvent):
2040         (WebCore::XMLHttpRequestProgressEvent::lengthComputable):
2041         (WebCore::XMLHttpRequestProgressEvent::loaded):
2042         (WebCore::XMLHttpRequestProgressEvent::total):
2043         * xml/XMLHttpRequestProgressEvent.idl: Added.
2044
2045 2008-04-21  Michael Goddard  <michael.goddard@trolltech.com>
2046
2047         Reviewed by Simon.
2048
2049         Better handle Qt binding object lifetime in JS.
2050         Add explicit marking of JS objects created for Qt
2051         bindings, and remove the gcProtect calls.
2052
2053         * bridge/qt/qt_class.cpp:
2054         (KJS::Bindings::QtClass::fallbackObject):
2055         * bridge/qt/qt_instance.cpp:
2056         (KJS::Bindings::QtRuntimeObjectImp::mark):
2057         (KJS::Bindings::QtInstance::~QtInstance):
2058         (KJS::Bindings::QtInstance::mark):
2059         (KJS::Bindings::QtInstance::invokeDefaultMethod):
2060         (KJS::Bindings::QtField::valueFromInstance):
2061         * bridge/qt/qt_instance.h:
2062
2063 2008-04-21  Michael Goddard  <michael.goddard@trolltech.com>
2064
2065         Reviewed by Simon.
2066
2067         Add better support for RuntimeArray type conversions.
2068         It seems that RuntimeArray claims to inherit ArrayInstance
2069         (in the JS sense), but the C++ class doesn't, so properly
2070         access RuntimeArrays.  Also, properly support turning
2071         a JS object into a QVariantMap, since we support the
2072         reverse.
2073
2074         * bridge/qt/qt_runtime.cpp:
2075         (KJS::Bindings::):
2076         (KJS::Bindings::operator<<):
2077         (KJS::Bindings::valueRealType):
2078         (KJS::Bindings::convertValueToQVariant):
2079         (KJS::Bindings::convertQVariantToValue):
2080
2081 2008-04-21  Simon Hausmann  <hausmann@webkit.org>
2082
2083         Reviewed by Holger.
2084
2085         Fix painting of text fields in the CleanLooks style.
2086
2087         The CleanLooks style calls painter->drawRect() and expects a painter
2088         that has no brush set. This is a fairly common assumption and therefore
2089         we now always set the brush to NoBrush before calling a style. This
2090         is done by centralizing the painter setup code into StylePainter
2091         and restore the old brush in the StylePainter destructor.
2092
2093         In addition for textfields it is not necessary anymore to draw
2094         PE_FrameLineEdit as we set the lineWidth in the style option correctly
2095         and it's the style responsibility (QCommonStyle usually) to draw
2096         PE_FrameLineEdit.
2097
2098         * platform/qt/RenderThemeQt.cpp:
2099         (WebCore::RenderThemeQt::paintButton):
2100         (WebCore::RenderThemeQt::paintTextField):
2101         (WebCore::RenderThemeQt::paintMenuList):
2102         (WebCore::StylePainter::StylePainter):
2103         (WebCore::StylePainter::~StylePainter):
2104         * platform/qt/RenderThemeQt.h:
2105         (WebCore::StylePainter::isValid):
2106         (WebCore::StylePainter::drawPrimitive):
2107         (WebCore::StylePainter::drawControl):
2108         (WebCore::StylePainter::drawComplexControl):
2109
2110 2008-04-21  Olivier Goffart  <ogoffart@trolltech.com>
2111
2112         Reviewed by Simon.
2113
2114         Fixes copy and paste of international characters.
2115
2116         When exporting HTML to the clipboard we need meta tags for now that confirm the
2117         conversion to utf-8 done inside QClipboard.
2118
2119         * platform/qt/PasteboardQt.cpp:
2120         (WebCore::Pasteboard::writeSelection):
2121
2122 2008-04-21  Olivier Goffart  <ogoffart@trolltech.com>
2123
2124         Reviewed by Simon.
2125
2126         Fixes: Copying on X11 doesn't always work in webkit
2127
2128         Calling QClipboard::clear right before QClipboard::setData create a race condition with klipper. So don't call QClipboard::clear since it's not required.
2129
2130         * platform/qt/PasteboardQt.cpp:
2131
2132 2008-04-21  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2133
2134         Reviewed by Simon.
2135
2136         * Assume that our lineedit has a frame. This is needed for the motif style
2137
2138         * platform/qt/RenderThemeQt.cpp:
2139         (WebCore::RenderThemeQt::paintTextField):
2140
2141 2008-04-21  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2142
2143         Reviewed by Simon.
2144
2145         * Follow the windows render theme when determining whether to style
2146         listboxes or not.
2147
2148         * platform/qt/RenderThemeQt.cpp:
2149         (WebCore::RenderThemeQt::isControlStyled):
2150
2151 2008-04-21  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2152
2153         Reviewed by Simon.
2154
2155         * Try to bring the notImplemented implementations closer together. This will
2156         print each unimplemted method name only once.
2157
2158         * We might want to change wtf/Assertions.cpp to use qDebug
2159
2160         * platform/NotImplemented.h:
2161
2162 2008-04-21  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2163
2164         Reviewed by Simon.
2165
2166         * Remove the special Qt ctor of BitmapImage as it did not work. The Bitmap returned
2167         0 as width and after intialising drawing would fail. BitmapImage relies on a proper
2168         ImageSource.
2169         * Instead of adding more special cases to BitmapImage create a new class called StillImage
2170         which is getting one QPixmap and is implementing Image::draw and Image::size. This is
2171         working well for the images created using Image::loadPlatformResource.
2172
2173         * platform/graphics/BitmapImage.h:
2174         * platform/graphics/qt/ImageQt.cpp:
2175         (WebCore::BitmapImage::initPlatformData):
2176         (WebCore::BitmapImage::getPixmap):
2177         (WebCore::StillImage::StillImage):
2178         (WebCore::StillImage::size):
2179         (WebCore::StillImage::getPixmap):
2180         (WebCore::StillImage::draw):
2181
2182 2008-04-21  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2183
2184         Reviewed by Simon.
2185
2186         * Package the Resources into a qrc
2187
2188         * Resources/WebKitResources.qrc: Added.
2189         * WebCore.pro:
2190
2191 2008-04-21  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
2192
2193         Reviewed by Simon.
2194
2195         * Make sure every resource is available als png as well.
2196
2197         * Resources/deleteButton.png: Added.
2198         * Resources/deleteButtonPressed.png: Added.
2199         * Resources/missingImage.png: Added.
2200         * Resources/nullPlugin.png: Copied from WebKit/win/WebKit.vcproj/nullplugin.png.
2201         * Resources/textAreaResizeCorner.png: Added.
2202         * Resources/urlIcon.png: Copied from WebKit/win/WebKit.vcproj/urlIcon.png.
2203
2204 2008-04-20  Sriram Neelakandan  <sriram.neelakandan@gmail.com>
2205
2206         Reviewed by Alp Toker.
2207
2208         Implement FileSystemGtk's getFileModificationTime() with GLib.
2209
2210         * platform/gtk/FileSystemGtk.cpp:
2211         (WebCore::getFileModificationTime):
2212
2213 2008-04-20  Christian Persch  <chpe@gnome.org>
2214
2215         Reviewed by Alp Toker.
2216
2217         Bundle GTK+ Xt compatibility code from Mozilla. These files are used
2218         by all currently proposed GTK+ plugin patches and will make the
2219         proposed patches smaller and easier to review.
2220
2221         These files should be kept as close to the upstream versions as
2222         possible so fixes can be shared between projects and to ensure
2223         compatibility with the reference implementation.
2224
2225         * plugins/gtk/gtk2xtbin.c: Added.
2226         (xt_event_prepare):
2227         (xt_event_check):
2228         (xt_event_dispatch):
2229         (xt_event_polling_timer_callback):
2230         (gtk_xtbin_get_type):
2231         (gtk_xtbin_class_init):
2232         (gtk_xtbin_init):
2233         (gtk_xtbin_realize):
2234         (gtk_xtbin_new):
2235         (gtk_xtbin_set_position):
2236         (gtk_xtbin_resize):
2237         (gtk_xtbin_unrealize):
2238         (gtk_xtbin_destroy):
2239         (xt_client_init):
2240         (xt_client_create):
2241         (xt_client_unrealize):
2242         (xt_client_destroy):
2243         (xt_client_set_info):
2244         (xt_client_handle_xembed_message):
2245         (xt_client_event_handler):
2246         (send_xembed_message):
2247         (error_handler):
2248         (trap_errors):
2249         (untrap_error):
2250         (xt_client_focus_listener):
2251         (xt_add_focus_listener):
2252         (xt_remove_focus_listener):
2253         (xt_add_focus_listener_tree):
2254         * plugins/gtk/gtk2xtbin.h: Added.
2255
2256 2008-04-20  Dirk Schulze  <vbs85@gmx.de>
2257
2258         Reviewed by Alp Toker.
2259
2260         http://bugs.webkit.org/show_bug.cgi?id=15449
2261         [CAIRO] SVG gradients do not work properly
2262
2263         Fixed SVG-gradients in Cairo.
2264
2265         * svg/graphics/cairo/SVGPaintServerGradientCairo.cpp:
2266         (WebCore::SVGPaintServerGradient::setup):
2267
2268 2008-04-20  Simon Hausmann  <hausmann@webkit.org>
2269
2270         Reviewed by Alp Toker.
2271
2272         http://bugs.webkit.org/show_bug.cgi?id=18578
2273         Share the printing code between the Gtk and the Qt port
2274
2275         Share the printing code between the Gtk and the Qt port
2276         and added printing to the Qt WebKit API.
2277
2278         * GNUmakefile.am:
2279         * WebCore.pro:
2280         * page/PrintContext.cpp: Added.
2281         (WebCore::PrintContext::PrintContext):
2282         (WebCore::PrintContext::~PrintContext):
2283         (WebCore::PrintContext::pageCount):
2284         (WebCore::PrintContext::computePageRects):
2285         (WebCore::PrintContext::begin):
2286         (WebCore::PrintContext::spoolPage):
2287         * page/PrintContext.h: Added.
2288
2289 2008-04-19  Alp Toker  <alp@nuanti.com>
2290
2291         Reviewed by Mark Rowe.
2292
2293         Complete the Cairo (CSS) gradient implementation.
2294
2295         * platform/graphics/Gradient.h:
2296         * platform/graphics/cairo/GradientCairo.cpp:
2297         (WebCore::Gradient::platformDestroy):
2298         (WebCore::Gradient::fill):
2299
2300 2008-04-19  Alp Toker  <alp@nuanti.com>
2301
2302         Reviewed by Dave Hyatt.
2303
2304         Restore Cairo canvas support following the recent changes in
2305         BitmapImage and ImageBuffer integrating canvas with CSS. Some
2306         drawing regressions remain unfixed.
2307
2308         * platform/graphics/BitmapImage.h:
2309         * platform/graphics/ImageBuffer.h:
2310         * platform/graphics/cairo/ImageBufferCairo.cpp:
2311         (WebCore::ImageBuffer::image):
2312         * platform/graphics/cairo/ImageCairo.cpp:
2313         (WebCore::BitmapImage::BitmapImage):
2314         (WebCore::BitmapImage::draw):
2315         * platform/graphics/cairo/ImageSourceCairo.cpp:
2316         (WebCore::ImageSource::createFrameAtIndex):
2317
2318 2008-04-19  Dan Bernstein  <mitz@apple.com>
2319
2320         Reviewed by Dave Hyatt.
2321
2322         - fix additional cases of https://bugs.webkit.org/show_bug.cgi?id=17921
2323           namely cases where the trailing white space is already in a separate
2324           run but still needs to be re-ordered.
2325
2326         Test: fast/text/trailing-white-space-2.html
2327
2328         * platform/text/BidiResolver.h:
2329         (WebCore::::moveRunToEnd):
2330         (WebCore::::moveRunToBeginning):
2331         * rendering/bidi.cpp:
2332         (WebCore::RenderBlock::layoutInlineChildren):
2333
2334 2008-04-19  Alp Toker  <alp@nuanti.com>
2335
2336         Reviewed by Nikolas.
2337
2338         Add text shadow support for simple text in FontCairo.
2339
2340         * platform/graphics/cairo/FontCairo.cpp:
2341         (WebCore::Font::drawGlyphs):
2342
2343 2008-04-19  David Hyatt  <hyatt@apple.com>
2344
2345         Fix a minor typo in CSSGradientValue's cssText() method.
2346
2347         Reviewed by olliej
2348
2349         * css/CSSGradientValue.cpp:
2350         (WebCore::CSSGradientValue::cssText):
2351
2352 2008-04-19  Brady Eidson  <beidson@apple.com>
2353
2354         Reviewed by Tim Hatcher
2355
2356         Add LocalStorageDatabasePath to the settings for the location of persistent local storage.
2357
2358         * WebCore.base.exp:
2359
2360         * page/Settings.cpp:
2361         (WebCore::Settings::setLocalStorageDatabasePath):
2362         * page/Settings.h:
2363         (WebCore::Settings::localStorageDatabasePath):
2364
2365 2008-04-18 Jan  Michael Alonzo  <jmalonzo@unpluggable.com>
2366
2367         Reviewed by Alp Toker.
2368
2369         http://bugs.webkit.org/show_bug.cgi?id=16620
2370         [GTK] Autotools make dist and make check support
2371
2372         Cleanups.
2373
2374         * GNUmakefile.am:
2375
2376 2008-04-18  Jon Honeycutt  <jhoneycutt@apple.com>
2377
2378         Reviewed by Ollie.
2379
2380         Change when AccessibilityObject children are added.
2381
2382         Children are now added when children() is called if the children vector
2383         is not up to date. This removes the need for addChildren() and
2384         hasChildren() to be called from outside of AccessibilityObject.
2385
2386         * page/AccessibilityObject.cpp:
2387         (WebCore::AccessibilityObject::AccessibilityObject): Initialize
2388         m_haveChildren to false.
2389         (WebCore::AccessibilityObject::clearChildren): Set m_haveChildren to
2390         false.
2391         (WebCore::AccessibilityObject::children): If m_haveChildren is false,
2392         call addChildren().
2393         (WebCore::AccessibilityObject::addChildren): Set m_haveChildren to true.
2394         * page/AccessibilityObject.h: Removed hasChildren(). Made addChildren()
2395         private and const. Added m_haveChildren. Made m_children mutable so
2396         children() could modify it.
2397         * page/mac/AccessibilityObjectWrapper.mm:
2398         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]): Don't
2399         call hasChildren() or addChildren().
2400
2401 2008-04-18  Marco Barisione  <marco.barisione@collabora.co.uk>
2402
2403         Reviewed by Alexey.
2404
2405         http://bugs.webkit.org/show_bug.cgi?id=18357
2406         [GTK] Enter on buttons doesn't work
2407
2408         * platform/gtk/KeyEventGtk.cpp:
2409         (WebCore::singleCharacterString): Set the text of a keyboard event for
2410         GDK_ISO_Enter, GDK_KP_Enter, GDK_Return to "\r" instead of an empty
2411         string.
2412
2413 2008-04-18  Marco Barisione  <marco@barisione.org>
2414
2415         Reviewed by Alp Toker.
2416
2417         https://bugs.webkit.org/show_bug.cgi?id=18576
2418         [GTK] windowsKeyCodeForKeyEvent doesn't handle GDK_ISO_Enter and
2419         GDK_KP_Enter
2420
2421         * platform/gtk/KeyEventGtk.cpp:
2422         (WebCore::windowsKeyCodeForKeyEvent): handle GDK_ISO_Enter and
2423         GDK_KP_Enter in windowsKeyCodeForKeyEvent.
2424
2425 2008-04-18  Jan Michael Alonzo  <jmalonzo@unpluggable.com>
2426
2427         Reviewed by Mark Rowe.
2428
2429         Gtk build fix.  Profiler.h does not live inside the kjs directory of JavaScriptCore
2430         so it doesn't make sense to include it as kjs/Profiler.h from WebCore.
2431
2432         * ForwardingHeaders/profiler/Profiler.h: Renamed from WebCore/ForwardingHeaders/kjs/Profiler.h.
2433         * page/Console.cpp:
2434
2435 2008-04-18  Antti Koivisto  <antti@apple.com>
2436
2437         Reviewed by Oliver.
2438
2439         Implement path animation for <animateMotion>.
2440         
2441         SVG test suite tests
2442         animate-elem-07-t.svg
2443         animate-elem-08-t.svg
2444         animate-elem-24-t.svg
2445         animate-elem-30-t.svg
2446
2447         * svg/SVGAnimateMotionElement.cpp:
2448         (WebCore::SVGAnimateMotionElement::SVGAnimateMotionElement):
2449         (WebCore::SVGAnimateMotionElement::hasValidTarget):
2450         (WebCore::SVGAnimateMotionElement::parseMappedAttribute):
2451         (WebCore::SVGAnimateMotionElement::rotateMode):
2452         (WebCore::SVGAnimateMotionElement::animationPath):
2453         (WebCore::SVGAnimateMotionElement::calculateAnimatedValue):
2454         (WebCore::SVGAnimateMotionElement::applyResultsToTarget):
2455         * svg/SVGAnimateMotionElement.h:
2456         (WebCore::SVGAnimateMotionElement::):
2457         * svg/SVGAnimationElement.cpp:
2458         (WebCore::SVGAnimationElement::animationMode):
2459         (WebCore::SVGAnimationElement::startedActiveInterval):
2460         * svg/SVGAnimationElement.h:
2461         (WebCore::SVGAnimationElement::):
2462         (WebCore::SVGAnimationElement::calculateDistance):
2463         (WebCore::SVGAnimationElement::animationPath):
2464
2465 2008-04-11  Mark Rowe  <mrowe@apple.com>
2466
2467         Rubber-stamped by Antti Koivisto.
2468
2469         Silence GCC 4.3 warnings by removing extraneous consts.
2470
2471         * platform/graphics/Font.h:
2472         * platform/network/ResourceRequestBase.cpp:
2473         * platform/network/ResourceRequestBase.h:
2474
2475 2008-04-18  Brady Eidson  <beidson@apple.com>
2476
2477         Rubberstamped by Mark Rowe
2478
2479         Roll out http://trac.webkit.org/projects/webkit/changeset/32204 as it was an incorrect build fix.
2480         The feature in question was NOT database support.
2481
2482         The proper build fix was later applied by Mark in http://trac.webkit.org/projects/webkit/changeset/32225
2483
2484         * page/PageGroup.cpp:
2485         (WebCore::PageGroup::localStorage):
2486
2487 2008-04-18  Brady Eidson  <beidson@apple.com>
2488
2489         Reviewed by Darin and Sam
2490
2491         Don't forget PageGroups when their last Page goes away, as this hurts visited links and anything
2492         else that will be per-PageGroup in the future (such as LocalStorage).
2493
2494         This also fixes a leak, since PageGroups are ref-counted and therefore clearing the raw pointer out
2495         of the PageGroups map without manual deletion leaked it!
2496
2497         * page/Page.cpp:
2498         (WebCore::Page::setGroupName):
2499
2500 2008-04-18  Dan Bernstein  <mitz@apple.com>
2501
2502         Reviewed by Brady Eidson.
2503
2504         - fix <rdar://problem/5872671> REGRESSION (3.1.1-TOT): Repro crash going to Ortega Park home page
2505
2506         Test: fast/dynamic/5872671.html
2507
2508         * rendering/bidi.cpp:
2509         (WebCore::RenderBlock::layoutInlineChildren): Added a missing null
2510         check.
2511
2512 2008-04-18  Sam Weinig  <sam@webkit.org>
2513
2514         Rubber-stamped by Mark Rowe.
2515
2516         responseText and responseXML don't throw exceptions so they don't need an ExceptionCode parameter.
2517
2518         * bindings/js/JSXMLHttpRequestCustom.cpp:
2519         * xml/XMLHttpRequest.cpp:
2520         (WebCore::XMLHttpRequest::responseText):
2521         (WebCore::XMLHttpRequest::responseXML):
2522         * xml/XMLHttpRequest.h:
2523         * xml/XMLHttpRequest.idl:
2524
2525 2008-04-18  Kevin McCullough  <kmccullough@apple.com>
2526
2527         Reviewed by Sam.
2528
2529         - Build fix.
2530
2531         * page/Console.cpp:
2532         (WebCore::Console::profile):
2533         * page/Console.h:
2534         * page/Console.idl:
2535
2536 2008-04-18  Eric Seidel  <eric@webkit.org>
2537
2538         Reviewed by darin.
2539
2540         Fix probable crasher caused by invalid static_cast
2541         https://bugs.webkit.org/show_bug.cgi?id=18585
2542
2543         * page/Frame.cpp:
2544         (WebCore::Frame::contentRenderer):
2545         (WebCore::Frame::ownerRenderer):
2546         * rendering/RenderObject.h: sort the "is*" functions
2547         (WebCore::RenderObject::isApplet):
2548         (WebCore::RenderObject::isBR):
2549         (WebCore::RenderObject::isBlockFlow):
2550         (WebCore::RenderObject::isCounter):
2551         (WebCore::RenderObject::isFrame):
2552         (WebCore::RenderObject::isFrameSet):
2553         (WebCore::RenderObject::isImage):
2554         (WebCore::RenderObject::isInlineBlockOrInlineTable):
2555         (WebCore::RenderObject::isInlineFlow):
2556         (WebCore::RenderObject::isListBox):
2557         (WebCore::RenderObject::isListItem):
2558         (WebCore::RenderObject::isListMarker):
2559         (WebCore::RenderObject::isMedia):
2560         (WebCore::RenderObject::isMenuList):
2561         (WebCore::RenderObject::isRenderBlock):
2562         (WebCore::RenderObject::isRenderImage):
2563         (WebCore::RenderObject::isRenderInline):
2564         (WebCore::RenderObject::isRenderPart):
2565         (WebCore::RenderObject::isRenderView):
2566         (WebCore::RenderObject::isSlider):
2567         (WebCore::RenderObject::isTable):
2568         (WebCore::RenderObject::isTableCell):
2569         (WebCore::RenderObject::isTableCol):
2570         (WebCore::RenderObject::isTableRow):
2571         (WebCore::RenderObject::isTableSection):
2572         (WebCore::RenderObject::isTextArea):
2573         * rendering/RenderPart.h:
2574
2575 2008-04-17  Eric Seidel  <eric@webkit.org>
2576
2577         Reviewed by beth.
2578
2579         Rename Frame::renderer() to contentRenderer() and fix uses.
2580
2581         * WebCore.base.exp:
2582         * editing/Editor.cpp:
2583         (WebCore::Editor::respondToChangedContents):
2584         * loader/FrameLoader.cpp:
2585         (WebCore::FrameLoader::gotoAnchor):
2586         * page/DragController.cpp:
2587         (WebCore::DragController::canProcessDrag):
2588         (WebCore::DragController::mayStartDragAtEventLocation):
2589         (WebCore::DragController::startDrag):
2590         * page/EventHandler.cpp:
2591         (WebCore::EventHandler::eventMayStartDrag):
2592         (WebCore::EventHandler::updateSelectionForMouseDrag):
2593         (WebCore::EventHandler::hitTestResultAtPoint):
2594         (WebCore::EventHandler::hoverTimerFired):
2595         (WebCore::EventHandler::handleDrag):
2596         * page/Frame.cpp:
2597         (WebCore::Frame::selectionLayoutChanged):
2598         (WebCore::Frame::contentRenderer):
2599         (WebCore::Frame::paint):
2600         (WebCore::Frame::markAllMatchesForText):
2601         (WebCore::Frame::documentAtPoint):
2602         * page/Frame.h:
2603         * page/FrameView.cpp:
2604         (WebCore::FrameView::~FrameView):
2605         (WebCore::FrameView::adjustViewSize):
2606         (WebCore::FrameView::layout):
2607         (WebCore::FrameView::scheduleRelayoutOfSubtree):
2608         (WebCore::FrameView::needsLayout):
2609         (WebCore::FrameView::setNeedsLayout):
2610         (WebCore::FrameView::updateControlTints):
2611         * rendering/RenderTreeAsText.cpp:
2612         (WebCore::write):
2613         * svg/graphics/SVGImage.cpp:
2614         (WebCore::SVGImage::nativeImageForCurrentFrame):
2615
2616 2008-04-18  Antti Koivisto  <antti@apple.com>
2617
2618         Reviewed by Oliver.
2619
2620         https://bugs.webkit.org/show_bug.cgi?id=18551
2621         REGRESSION (r31801?): Crash in ContainerNode::removedFromDocument on many SVG tests
2622         
2623         Fix for test svg/W3C-SVG-1.1/animate-elem-62-t.svg which was still
2624         crashing under guard malloc after the previous fix.
2625         
2626         If the event base element was a parent of the current element, dereffing it during 
2627         removedFromDocument() would cause problems. Avoid this by not holding ref pointer
2628         to the event base but instead checking from the ref count of the event listener whether
2629         it is still alive and in need for unregistering.
2630         
2631         This shold not be a problem for syncbase pointers since those are always animation elements
2632         and leaf nodes.
2633
2634         * svg/animation/SVGSMILElement.cpp:
2635         (WebCore::ConditionEventListener::ConditionEventListener):
2636         (WebCore::ConditionEventListener::unregister):
2637         (WebCore::ConditionEventListener::handleEvent):
2638         (WebCore::SVGSMILElement::connectConditions):
2639         (WebCore::SVGSMILElement::disconnectConditions):
2640         (WebCore::SVGSMILElement::createInstanceTimesFromSyncbase):
2641         * svg/animation/SVGSMILElement.h:
2642
2643 2008-04-18  Kevin McCullough  <kmccullough@apple.com>
2644
2645         Reviewed by Sam and Adam.
2646
2647         -<rdar://problem/5770054> JavaScript profiler (10928)
2648         - Added support for console.profile() and console.profileEnd().
2649
2650         * ForwardingHeaders/kjs/FunctionCallProfile.h: Added.
2651         * ForwardingHeaders/kjs/Profiler.h: Added.
2652         * page/Console.cpp:
2653         (WebCore::Console::profile):
2654         (WebCore::Console::profileEnd):
2655         * page/Console.h:
2656         * page/Console.idl:
2657
2658 2008-04-18  Kevin Ollivier  <kevino@theolliviers.com>
2659
2660         wx build fix. Add the new loader/appcache files.
2661
2662         * WebCoreSources.bkl:
2663
2664 2008-04-18  Dan Bernstein  <mitz@apple.com>
2665
2666         Reviewed by Darin Adler.
2667
2668         - fix https://bugs.webkit.org/show_bug.cgi?id=17921
2669           Extra white space at the end of right-aligned or justified text with -webkit-line-break: after-white-space
2670
2671         Test: fast/text/trailing-white-space.html
2672
2673         Made trailing white space on the line always behave like it has the base
2674         bidi level of the block, meaning it will always go on the right (left)
2675         of the line in a left-to-right (right-to-left) block. Made the trailing
2676         white space vanish when it is next to a margin that the text should
2677         be touching, and made its width not count when computing the center
2678         point for center alignment.
2679
2680         * platform/text/BidiResolver.h:
2681         (WebCore::::prependRun): Added.
2682         * rendering/RenderBlock.h:
2683         * rendering/bidi.cpp:
2684         (WebCore::RenderBlock::computeHorizontalPositionsForLine): Changed the
2685         logicallyLastRun parameter to an optional trailingSpaceRun and changed
2686         the alignment logic to implement the above rules.
2687         (WebCore::RenderBlock::layoutInlineChildren): Added code to identify
2688         when there is trailing white space that needs to be split into its own
2689         run and optionally re-ordered.
2690         (WebCore::RenderBlock::findNextLineBreak): Removed code that split some
2691         trailing space into a separate run in one special case.
2692
2693 2008-04-10  Mark Rowe  <mrowe@apple.com>
2694
2695         Rubber-stamped by Brady Eidson.
2696
2697         Fix builds that do not have DOM storage enabled.
2698
2699         * page/DOMWindow.cpp:
2700         * page/Page.cpp:
2701         * page/PageGroup.cpp:
2702         * page/PageGroup.h:
2703
2704 2008-04-18  Timothy Hatcher  <timothy@apple.com>
2705
2706         Fixes the regression where style rules in the Inspector always show "inline stylesheet"
2707         for the source of the rule and not the URL or other sources.
2708
2709         https://bugs.webkit.org/show_bug.cgi?id=18592
2710
2711         Reviewed by Dan Bernstein.
2712
2713         * page/inspector/StylesSidebarPane.js:
2714         (WebInspector.StylesSidebarPane.prototype.update): Add parentStyleSheet to the anonymous obejct
2715         that we make for each matched rule. The parentStyleSheet property is used later to make the subtitle.
2716
2717 2008-04-18  Dean Jackson <dino@apple.com>
2718
2719         Fixed marquee suspension on wrong document. Passes current
2720         document into Frame::clearTimers.
2721
2722         Reviewed by hyatt.
2723
2724         * history/CachedPage.cpp:
2725         (WebCore::CachedPage::clear):
2726         * page/Frame.cpp:
2727         (WebCore::Frame::clearTimers):
2728         * page/Frame.h:
2729
2730 2008-04-18  Dean Jackson <dino@apple.com>
2731
2732         Add 'ease' timing function to transitions and
2733         make it the default. See latest specification proposal at:
2734         http://webkit.org/specs/CSSVisualEffects/CSSTransitions.html
2735
2736         Reviewed by hyatt.
2737
2738         NOTE: still working on a way to test animating/transitioning content
2739
2740         * css/CSSParser.cpp:
2741         (WebCore::CSSParser::parseTransitionTimingFunction):
2742         * css/CSSStyleSelector.cpp:
2743         (WebCore::CSSStyleSelector::mapTransitionTimingFunction):
2744         * css/CSSValueKeywords.in:
2745
2746 2008-04-18  Adam Roben  <aroben@apple.com>
2747
2748         Change JavaScriptDebugListener to use KJS::UString instead of
2749         WebCore::String
2750
2751         This should reduce the number of string allocations performed while
2752         debugging.
2753
2754         Reviewed by Tim Hatcher.
2755
2756         * page/InspectorController.cpp: Updated JavaScriptDebugListener
2757         functions.
2758         * page/InspectorController.h: Ditto.
2759         * page/JavaScriptDebugListener.h: Changed to use KJS::UString instead
2760         of WebCore::String.
2761         * page/JavaScriptDebugServer.cpp: Ditto.
2762         * platform/win/BString.cpp:
2763         (WebCore::BString::BString): Added a constructor that takes a
2764         KJS::UString.
2765         * platform/win/BString.h:
2766
2767 2008-04-18  Adam Roben  <aroben@apple.com>
2768
2769         Mac build fix
2770
2771         * WebCore.xcodeproj/project.pbxproj: Mark JavaScriptDebugListener.h
2772         private.
2773
2774 2008-04-18  Adam Roben  <aroben@apple.com>
2775
2776         Make InspectorController a JavaScriptDebugListener
2777
2778         I added two new functions to the InspectorController JS object:
2779         reloadInspectedPageAndStartDebugging and stopDebugging. These control
2780         when the InspectorController adds/removes itself to/from the
2781         JavaScriptDebugServer.
2782
2783         Reviewed by Tim Hatcher.
2784
2785         * page/InspectorController.cpp:
2786         (WebCore::reloadInspectedPageAndStartDebugging): Added. Just calls
2787         through to InspectorController.
2788         (WebCore::stopDebugging): Ditto.
2789         (WebCore::InspectorController::~InspectorController): Make sure we
2790         stop debugging before we are destroyed so the JavaScriptDebugServer
2791         won't be left with a stale pointer.
2792         (WebCore::InspectorController::windowScriptObjectAvailable): Added two
2793         new functions to our JS object.
2794         (WebCore::InspectorController::closeWindow): Stop debugging when the
2795         window closes.
2796         (WebCore::InspectorController::reloadInspectedPageAndStartDebugging):
2797         Added.
2798         (WebCore::InspectorController::stopDebugging): Added.
2799
2800         (WebCore::InspectorController::didParseSource):
2801         (WebCore::InspectorController::failedToParseSource):
2802         (WebCore::InspectorController::didEnterCallFrame):
2803         (WebCore::InspectorController::willExecuteStatement):
2804         (WebCore::InspectorController::willLeaveCallFrame):
2805         Added empty implementations of the JavaScriptDebugListener functions.
2806
2807         * page/InspectorController.h:
2808
2809 2008-04-17  Adam Roben  <aroben@apple.com>
2810
2811         Rename ExecState* instances from state to exec
2812
2813         Requested by Darin Adler and Sam Weinig.
2814
2815         * bindings/js/JSConsoleCustom.cpp:
2816
2817 2008-04-17  Adam Roben  <aroben@apple.com>
2818
2819         Clean up InspectorController's use of JSStringRef
2820
2821         All JSStringRef creation now happens through a helper function,
2822         jsStringRef, which takes either a const char* or a const String& and
2823         returns a JSRetainPtr<JSStringRef>.
2824
2825         Reviewed by Mitz Pettel.
2826
2827         * page/InspectorController.cpp:
2828         Added jsStringRef and converted all callers to
2829         JSStringCreateWithUTF8CString or JSStringCreateWithCharacters to use
2830         it.
2831
2832 2008-04-17  Adam Roben  <aroben@apple.com>
2833
2834         Add wrappers around InspectorClient::{show,close}Window
2835
2836         This will let us perform actions when the window is actually
2837         showing/closing (InspectorController::show doesn't always directly
2838         show the window).
2839
2840         Reviewed by Tim Hatcher.
2841
2842         * page/InspectorController.cpp:
2843         (WebCore::InspectorController::scriptObjectReady): Call showWindow()
2844         instead of m_client->showWindow().
2845         (WebCore::InspectorController::show): Ditto.
2846         (WebCore::InspectorController::close): Ditto for closeWindow().
2847         (WebCore::InspectorController::showWindow):
2848         (WebCore::InspectorController::closeWindow):
2849         * page/InspectorController.h:
2850
2851 2008-04-18  Simon Hausmann  <hausmann@webkit.org>
2852
2853         Reviewed by Holger.
2854
2855         Adapt to the API changes in WebKit/qt/
2856
2857         * platform/graphics/qt/ImageQt.cpp:
2858         (loadResourcePixmap):
2859
2860 2008-04-18  Ariya Hidayat  <ariya.hidayat@trolltech.com>
2861
2862         Reviewed by Adam Roben.
2863
2864         https://bugs.webkit.org/show_bug.cgi?id=18477
2865
2866         No resize indication is shown when moving/hovering over the frame
2867         border/splitter.
2868
2869         * page/EventHandler.cpp:
2870         (WebCore::EventHandler::selectCursor):
2871
2872 2008-04-18  Adam Roben  <aroben@apple.com>
2873
2874         Windows build fix
2875
2876         Same as before, but for fabs/fabsf.
2877
2878         * svg/SVGAnimateTransformElement.cpp:
2879         (WebCore::SVGAnimateTransformElement::calculateDistance): Changed to
2880         use fabsf and removed narrowPrecisionToFloat.
2881
2882 2008-04-18  Adam Roben  <aroben@apple.com>
2883
2884         Windows build fix
2885
2886         In MSVC, sqrt() has three overloads: float, double, and long
2887         double. In GCC, sqrt() is only for doubles. Both MSVC and GCC have
2888         sqrtf() to operate explicitly on floats.
2889
2890         * svg/SVGAnimateMotionElement.cpp:
2891         (WebCore::SVGAnimateMotionElement::calculateDistance): Changed to use
2892         sqrtf and removed narrowPrecisionToFloat.
2893         * svg/SVGAnimateTransformElement.cpp:
2894         (WebCore::SVGAnimateTransformElement::calculateDistance): Ditto.
2895
2896 2008-04-18  Simon Hausmann  <hausmann@webkit.org>
2897
2898         Fix the build without Database support (fixes the Qt/win build).
2899
2900         * page/PageGroup.cpp:
2901         (WebCore::PageGroup::localStorage):
2902
2903 2008-04-18  Simon Hausmann  <hausmann@webkit.org>
2904
2905         Fix the Gtk build on the build bot.
2906
2907         * GNUmakefile.am: Back out the previous LocalStorage, etc. additions
2908         as they're already listed in another sources group that wasn't used
2909         due to a local configure error.
2910
2911 2008-04-18  Simon Hausmann  <hausmann@webkit.org>
2912
2913         Prospective wx build fix.
2914
2915         * webcore-base.bkl: Add loader/appcache to include paths.
2916
2917 2008-04-18  Simon Hausmann  <hausmann@webkit.org>
2918
2919         Build fix. Back out previous #include fix for PageGroup.h as it broke
2920         the Mac build due to forwarding headers.
2921
2922         * page/PageGroup.h:
2923
2924 2008-04-18  Simon Hausmann  <hausmann@webkit.org>
2925
2926         Build fix for Qt and gcc 4.3.
2927
2928         * WebCore.pro: Added missing files and include paths, re-ordered
2929         the storage/ include path to avoid conflict of storage/LocalStorage.h
2930         with kjs/LocalStorage.h
2931         * page/PageGroup.h: Include LocalStorage.h instead of forward
2932         declaration to fix compilation with gcc 4.3.
2933
2934 2008-04-18  Simon Hausmann  <hausmann@webkit.org>
2935
2936         Build fix for Gtk and gcc 4.3.
2937
2938         * GNUmakefile.am: Added missing files and include paths.
2939         * storage/LocalStorage.h: Include LocalStorageArea.h instead of
2940         forward declaring it due to the HashMap use where gcc 4.3 needs to
2941         see the class.
2942
2943 2008-04-17  Antti Koivisto  <antti@apple.com>
2944
2945         Reviewed by Oliver.
2946         
2947         https://bugs.webkit.org/show_bug.cgi?id=18573
2948
2949         Implement supplemental transforms and use them for <animateMotion> instead of the transform list.
2950         This will allow <animateTransform> and <animateMotion> combine properly.
2951
2952         * svg/SVGAnimateMotionElement.cpp:
2953         (WebCore::SVGAnimateMotionElement::resetToBaseValue):
2954         (WebCore::SVGAnimateMotionElement::calculateAnimatedValue):
2955         (WebCore::SVGAnimateMotionElement::applyResultsToTarget):
2956         * svg/SVGElement.h:
2957         (WebCore::SVGElement::supplementalTransform):
2958         * svg/SVGStyledTransformableElement.cpp:
2959         (WebCore::SVGStyledTransformableElement::animatedLocalTransform):
2960         * svg/SVGStyledTransformableElement.h:
2961         (WebCore::SVGStyledTransformableElement::supplementalTransform):
2962         * svg/SVGTextElement.cpp:
2963         (WebCore::SVGTextElement::animatedLocalTransform):
2964         * svg/SVGTextElement.h:
2965         (WebCore::SVGTextElement::supplementalTransform):
2966
2967 2008-04-17  Antti Koivisto  <antti@apple.com>
2968
2969         Reviewed by Oliver.
2970
2971         Implement calcMode=paced.
2972         
2973         Tested by SVG testsuite tests
2974         animate-elem-11-t.svg
2975         animate-elem-15-t.svg
2976         animate-elem-82-t.svg
2977
2978         * svg/SVGAnimateElement.cpp:
2979         (WebCore::SVGAnimateElement::calculateDistance):
2980         * svg/SVGAnimateElement.h:
2981         * svg/SVGAnimateMotionElement.cpp:
2982         (WebCore::SVGAnimateMotionElement::calculateDistance):
2983         * svg/SVGAnimateMotionElement.h:
2984         * svg/SVGAnimateTransformElement.cpp:
2985         (WebCore::SVGAnimateTransformElement::calculateDistance):
2986         * svg/SVGAnimateTransformElement.h:
2987         * svg/SVGAnimationElement.cpp:
2988         (WebCore::SVGAnimationElement::calculateKeyTimesForCalcModePaced):
2989         (WebCore::SVGAnimationElement::startedActiveInterval):
2990         * svg/SVGAnimationElement.h:
2991         (WebCore::SVGAnimationElement::calculateDistance):
2992
2993 2008-04-17  David Hyatt  <hyatt@apple.com>
2994
2995         Fix a leak in ImageBuffer's clearImage method.
2996
2997         Reviewed by olliej
2998
2999         * platform/graphics/ImageBuffer.h:
3000         (WebCore::ImageBuffer::clearImage):
3001
3002 2008-04-17  Antti Koivisto  <antti@apple.com>
3003
3004         Reviewed by Eric.
3005         
3006         https://bugs.webkit.org/show_bug.cgi?id=12438
3007
3008         More SVG animation:
3009         
3010         - Make multiple additive animations work
3011         - Support animating <use> instance trees
3012
3013         * svg/SVGAnimateColorElement.cpp:
3014         (WebCore::SVGAnimateColorElement::SVGAnimateColorElement):
3015         * svg/SVGAnimateColorElement.h:
3016         
3017         Made this AnimateElement subclass. All functionality is now provided by AnimateElement.
3018         
3019         * svg/SVGAnimateElement.cpp:
3020         (WebCore::SVGAnimateElement::determinePropertyType):
3021         (WebCore::SVGAnimateElement::calculateAnimatedValue):
3022         (WebCore::SVGAnimateElement::calculateFromAndToValues):
3023         (WebCore::SVGAnimateElement::calculateFromAndByValues):
3024         (WebCore::SVGAnimateElement::resetToBaseValue):
3025         (WebCore::SVGAnimateElement::applyResultsToTarget):
3026         * svg/SVGAnimateElement.h:
3027         * svg/SVGAnimateMotionElement.cpp:
3028         (WebCore::SVGAnimateMotionElement::resetToBaseValue):
3029         (WebCore::SVGAnimateMotionElement::calculateAnimatedValue):
3030         (WebCore::SVGAnimateMotionElement::applyResultsToTarget):
3031         * svg/SVGAnimateMotionElement.h:
3032         * svg/SVGAnimateTransformElement.cpp:
3033         (WebCore::SVGAnimateTransformElement::resetToBaseValue):
3034         (WebCore::SVGAnimateTransformElement::calculateAnimatedValue):
3035         (WebCore::SVGAnimateTransformElement::calculateFromAndByValues):
3036         (WebCore::SVGAnimateTransformElement::applyResultsToTarget):
3037         * svg/SVGAnimateTransformElement.h:
3038         
3039         Switch to new model where
3040         - resetToBaseValue() resets the animated value back to the base value
3041         - calculateAnimatedValue() computes the value and adds it to the element used for accumulation
3042         - applyResultsToTarget() sets the computed value the target element
3043         
3044         * svg/SVGAnimationElement.cpp:
3045         (WebCore::SVGAnimationElement::fromValue):
3046         (WebCore::SVGAnimationElement::attributeIsCSS):
3047         (WebCore::SVGAnimationElement::targetAttributeIsCSS):
3048         (WebCore::SVGAnimationElement::setTargetAttributeAnimatedValue):
3049         
3050         Update instances too.
3051         
3052         (WebCore::SVGAnimationElement::startedActiveInterval):
3053         (WebCore::SVGAnimationElement::updateAnimation):
3054         (WebCore::SVGAnimationElement::endedActiveInterval):
3055         * svg/SVGAnimationElement.h:
3056         * svg/SVGSVGElement.cpp:
3057         (WebCore::SVGSVGElement::SVGSVGElement):
3058         * svg/SVGSetElement.cpp:
3059         (WebCore::SVGSetElement::SVGSetElement):
3060         * svg/SVGSetElement.h:
3061         
3062         Made this AnimateElement subclass. All functionality is now provided by AnimateElement.
3063         
3064         * svg/animation/SMILTimeContainer.cpp:
3065         (WebCore::SMILTimeContainer::SMILTimeContainer):
3066         (WebCore::SMILTimeContainer::unschedule):
3067         (WebCore::SMILTimeContainer::updateDocumentOrderIndexes):
3068         (WebCore::PriorityCompare::PriorityCompare):
3069         (WebCore::PriorityCompare::operator()):
3070         (WebCore::SMILTimeContainer::sortByPriority):
3071         (WebCore::applyOrderSortFunction):
3072         (WebCore::sortByApplyOrder):
3073         (WebCore::SMILTimeContainer::baseValueFor):
3074         (WebCore::SMILTimeContainer::updateAnimations):
3075         * svg/animation/SMILTimeContainer.h:
3076         (WebCore::SMILTimeContainer::create):
3077         (WebCore::SMILTimeContainer::setDocumentOrderIndexesDirty):
3078         
3079         Do additive animation with the following steps
3080         - sort active animations based on their priority (begin time, document order).
3081         - if not yet saved for each (element, attribute) pair save the base value.
3082         - lowest priority animation for each (element, attribute) acts as the result element.
3083         - animation results are resolved in priority order and results are accumulated to the result element.
3084         - after all active animations have been processed the values in result elements are applied to the target elements.
3085         
3086         * svg/animation/SVGSMILElement.cpp:
3087         (WebCore::SVGSMILElement::SVGSMILElement):
3088         (WebCore::SVGSMILElement::insertedIntoDocument):
3089         
3090         Invalidate document order index.
3091         
3092         (WebCore::SVGSMILElement::attributeName):
3093         (WebCore::SVGSMILElement::isInactive):
3094         (WebCore::SVGSMILElement::isFrozen):
3095         (WebCore::SVGSMILElement::beginListChanged):
3096         (WebCore::SVGSMILElement::determineActiveState):
3097         (WebCore::SVGSMILElement::isContributing):
3098         (WebCore::SVGSMILElement::progress):
3099         
3100         Take care that animations in frozen state still contribute to the total. Since we now build the result starting
3101         from the base value, fill="replace" works magically simply by not contributing anything.
3102         
3103         * svg/animation/SVGSMILElement.h:
3104         (WebCore::SVGSMILElement::previousIntervalBegin):
3105         (WebCore::SVGSMILElement::documentOrderIndex):
3106         (WebCore::SVGSMILElement::setDocumentOrderIndex):
3107
3108 2008-04-17  Jon Honeycutt  <jhoneycutt@apple.com>
3109
3110         Reviewed by Darin, Alice.
3111
3112         Implement AXObjectCache::detachWrapper() on Windows.
3113
3114         * page/win/AXObjectCacheWin.cpp:
3115         (WebCore::AXObjectCache::detachWrapper): If this object has a wrapper,
3116         call its detach() method.
3117
3118 2008-04-17  Jon Honeycutt  <jhoneycutt@apple.com>
3119
3120         Reviewed by mrowe.
3121
3122         Define HAVE_ACCESSIBILITY in a way that WebKit and WebCore can see it.
3123
3124         * config.h: Remove HAVE_ACCESSIBILITY.
3125         * page/AccessibilityObject.h: Include wtf/Platform.h to pick up
3126         HAVE_ACCESSIBILITY.
3127
3128 2008-04-17  Jon Honeycutt  <jhoneycutt@apple.com>
3129
3130         Reviewed by aliu.
3131
3132         * page/AccessibilityObject.cpp:
3133         (WebCore::AccessibilityObject::layoutCount): Check isRenderView() before
3134         casting to RenderView.
3135
3136 2008-04-17  Antti Koivisto  <antti@apple.com>
3137
3138         Reviewed by Oliver.
3139         
3140         Fix https://bugs.webkit.org/show_bug.cgi?id=18551
3141         Bug 18551: REGRESSION (r31801?): Crash in ContainerNode::removedFromDocument on many SVG tests under guard malloc
3142         
3143         Freeing a RefPtr that is the last ref to the parent from removedFromDocument() is a bad idea.
3144
3145         Caching the target element is too dangerous, let's simply not do it. Getting it is very cheap anyway.
3146
3147         * svg/animation/SVGSMILElement.cpp:
3148         (WebCore::SVGSMILElement::removedFromDocument):
3149         (WebCore::SVGSMILElement::attributeChanged):
3150         (WebCore::SVGSMILElement::targetElement):
3151         * svg/animation/SVGSMILElement.h:
3152
3153 2008-04-17  Sam Weinig  <sam@webkit.org>
3154
3155         Reviewed by Anders Carlsson.
3156
3157         Autogenerate the XMLHttpRequest javascript binding.
3158
3159         * GNUmakefile.am:
3160         * WebCore.pro:
3161         * WebCore.vcproj/WebCore.vcproj:
3162         * WebCoreSources.bkl:
3163         * DerivedSources.make:
3164         * WebCore.xcodeproj/project.pbxproj:
3165         * bindings/js/JSDOMWindowBase.cpp:
3166         * bindings/js/JSXMLHttpRequest.cpp: Removed.
3167         * bindings/js/JSXMLHttpRequest.h: Removed.
3168         * bindings/js/JSXMLHttpRequestConstructor.cpp: Added.
3169         (WebCore::JSXMLHttpRequestConstructor::JSXMLHttpRequestConstructor):
3170         (WebCore::JSXMLHttpRequestConstructor::implementsConstruct):
3171         (WebCore::JSXMLHttpRequestConstructor::construct):
3172         * bindings/js/JSXMLHttpRequestConstructor.h: Added.
3173         (WebCore::JSXMLHttpRequestConstructor::classInfo):
3174         * bindings/js/JSXMLHttpRequestCustom.cpp: Added.
3175         (WebCore::JSXMLHttpRequest::mark):
3176         (WebCore::JSXMLHttpRequest::onreadystatechange):
3177         (WebCore::JSXMLHttpRequest::setOnreadystatechange):
3178         (WebCore::JSXMLHttpRequest::onload):
3179         (WebCore::JSXMLHttpRequest::setOnload):
3180         (WebCore::JSXMLHttpRequest::responseXML):
3181         (WebCore::JSXMLHttpRequest::open):
3182         (WebCore::JSXMLHttpRequest::setRequestHeader):
3183         (WebCore::JSXMLHttpRequest::send):
3184         (WebCore::JSXMLHttpRequest::getResponseHeader):
3185         (WebCore::JSXMLHttpRequest::overrideMimeType):
3186         (WebCore::JSXMLHttpRequest::addEventListener):
3187         (WebCore::JSXMLHttpRequest::removeEventListener):
3188         (WebCore::JSXMLHttpRequest::dispatchEvent):
3189         * xml/XMLHttpRequest.cpp:
3190         (WebCore::XMLHttpRequest::readyState):
3191         (WebCore::XMLHttpRequest::responseText):
3192         * xml/XMLHttpRequest.h:
3193         * xml/XMLHttpRequest.idl: Added.
3194
3195 2008-04-17  Brady Eidson  <beidson@apple.com>
3196
3197         Reviewed by Anders
3198
3199         The SessionStorage for a Page has to be copied every time a new Page is created.
3200
3201         I thought I had the right choke point for creating new Pages at FrameLoader::createWindow(),
3202         but it just so happens there was another - in the ContextMenuController.
3203
3204         The *real* choke point for this, then, is in the Chrome itself.
3205
3206         * loader/FrameLoader.cpp:
3207         (WebCore::FrameLoader::createWindow): Don't do the SessionStorage copy here...
3208
3209         * page/Chrome.cpp:
3210         (WebCore::Chrome::createWindow): Do it here, instead!
3211
3212 2008-04-17  Alice Liu  <alice.liu@apple.com>
3213
3214         Reviewed by Jon Honeycutt.
3215
3216         Added some asserts to catch undesirable usage of setWrapper and addChildren.
3217         * page/AccessibilityObject.cpp:
3218         (WebCore::AccessibilityObject::addChildren):
3219         * page/AccessibilityObject.h:
3220         (WebCore::AccessibilityObject::setWrapper):
3221
3222 2008-04-17  Brady Eidson  <beidson@apple.com>
3223
3224         Reviewed by the Mitzpettel
3225
3226         Before things get much more intertwined, move away from a global LocalStorage model
3227         to a per-PageGroup LocalStorage model.
3228
3229         * page/DOMWindow.cpp:
3230         (WebCore::DOMWindow::localStorage): Get it from the current PageGroup, not the global
3231           LocalStorage (which doesn't exist anymore).
3232
3233         * page/Page.cpp:
3234         * page/PageGroup.cpp:
3235         (WebCore::PageGroup::localStorage): Create a LocalStorage object on demand.
3236         * page/PageGroup.h:
3237
3238         * storage/LocalStorage.cpp:
3239         (WebCore::LocalStorage::LocalStorage): Hold a back pointer to the owning PageGroup.
3240         (WebCore::LocalStorage::storageArea):
3241         * storage/LocalStorage.h:
3242         (WebCore::LocalStorage::create):
3243
3244         * storage/LocalStorageArea.cpp:
3245         (WebCore::LocalStorageArea::LocalStorageArea): Hold a back pointer to the owning LocalStorage.
3246         * storage/LocalStorageArea.h:
3247         (WebCore::LocalStorageArea::create):
3248
3249 2008-04-17  Anders Carlsson  <andersca@apple.com>
3250
3251         Fix indentation.
3252         
3253         * loader/DocumentLoader.cpp:
3254         (WebCore::DocumentLoader::scheduleArchiveLoad):
3255
3256 2008-04-17  Anders Carlsson  <andersca@apple.com>
3257
3258         Reviewed by Brady.
3259
3260         When in the web archive debug mode, don't call didFail immediately. Instead,
3261         add the loader to the substitute resource map, but with a null resource, which
3262         indicates to substituteResourceDeliveryTimerFired that the load should fail.
3263         
3264         * loader/DocumentLoader.cpp:
3265         (WebCore::DocumentLoader::substituteResourceDeliveryTimerFired):
3266         (WebCore::DocumentLoader::scheduleArchiveLoad):
3267         * loader/ResourceLoader.cpp:
3268         (WebCore::ResourceLoader::load):
3269
3270 2008-04-17  Anders Carlsson  <andersca@apple.com>
3271
3272         Reviewed by Sam.
3273
3274         Add JS bindings for the DOMApplicationCache object.
3275         
3276         * bindings/js/JSDOMApplicationCacheCustom.cpp:
3277         (WebCore::JSDOMApplicationCache::add):
3278         (WebCore::JSDOMApplicationCache::remove):
3279         (WebCore::JSDOMApplicationCache::addEventListener):
3280         (WebCore::JSDOMApplicationCache::removeEventListener):
3281         (WebCore::JSDOMApplicationCache::dispatchEvent):
3282         (WebCore::JSDOMApplicationCache::setOnchecking):
3283         (WebCore::JSDOMApplicationCache::onchecking):
3284         (WebCore::JSDOMApplicationCache::setOnerror):
3285         (WebCore::JSDOMApplicationCache::onerror):
3286         (WebCore::JSDOMApplicationCache::setOnnoupdate):
3287         (WebCore::JSDOMApplicationCache::onnoupdate):
3288         (WebCore::JSDOMApplicationCache::setOndownloading):
3289         (WebCore::JSDOMApplicationCache::ondownloading):
3290         (WebCore::JSDOMApplicationCache::setOnprogress):
3291         (WebCore::JSDOMApplicationCache::onprogress):
3292         (WebCore::JSDOMApplicationCache::setOnupdateready):
3293         (WebCore::JSDOMApplicationCache::onupdateready):
3294         (WebCore::JSDOMApplicationCache::setOncached):
3295         (WebCore::JSDOMApplicationCache::oncached):
3296         (WebCore::JSDOMApplicationCache::mark):
3297         * bindings/js/JSDOMWindowCustom.cpp:
3298         (WebCore::JSDOMWindow::mark):
3299         * bindings/js/JSEventTargetBase.cpp:
3300         (WebCore::toJS):
3301         * loader/appcache/DOMApplicationCache.idl:
3302         * page/DOMWindow.idl:
3303
3304 2008-04-17 Eric Carlson  <eric.carlson@apple.com> 
3305
3306         Reviewed by Adele. 
3307
3308         Fix for <rdar://problem/5861642> QTMovieWin returns uninitialized values
3309
3310         * platform/graphics/win/QTMovieWin.cpp:
3311         (QTMovieWin::rate):
3312         (QTMovieWin::setRate):
3313         (QTMovieWin::setVolume):
3314         (QTMovieWin::getNaturalSize):
3315
3316 2008-04-17  Marco Barisione  <marco.barisione@collabora.co.uk>
3317
3318         Reviewed by Alp Toker.
3319
3320         http://bugs.webkit.org/show_bug.cgi?id=18335
3321         Pango font backend unable to display japanese properly
3322
3323         Different fonts can have different glyph indices, so we need to pass
3324         the right font when retrieving a glyph index.
3325
3326         * platform/graphics/gtk/GlyphPageTreeNodePango.cpp:
3327         (WebCore::pango_font_get_glyph): Temporarily override the font in the
3328         PangoAnalysis passed to pango_shape.
3329
3330 2008-04-17  Anders Carlsson  <andersca@apple.com>
3331
3332         According to Sam and David, it's "topLevel", not "toplevel".
3333         
3334         * loader/DocumentLoader.cpp:
3335         (WebCore::DocumentLoader::topLevelApplicationCache):
3336         * loader/DocumentLoader.h:
3337         * loader/appcache/DOMApplicationCache.cpp:
3338         (WebCore::DOMApplicationCache::associatedCache):
3339
3340 2008-04-17  Anders Carlsson  <andersca@apple.com>
3341
3342         Reviewed by Sam.
3343
3344         Add DOMApplicationCache implementation.
3345         
3346         * dom/EventNames.h:
3347         Add new event names.
3348         
3349         * dom/EventTarget.cpp:
3350         (WebCore::EventTarget::toDOMApplicationCache):
3351         * dom/EventTarget.h:
3352         Add EventTarget conversion method.
3353         
3354         * loader/appcache/ApplicationCacheGroup.h:
3355         (WebCore::ApplicationCacheGroup::):
3356         (WebCore::ApplicationCacheGroup::status):
3357         (WebCore::ApplicationCacheGroup::update):
3358         (WebCore::ApplicationCacheGroup::newestCache):
3359         Add more stubs.
3360         
3361         * loader/appcache/DOMApplicationCache.cpp:
3362         * loader/appcache/DOMApplicationCache.h:
3363
3364         * page/DOMWindow.cpp:
3365         (WebCore::DOMWindow::clear):
3366         (WebCore::DOMWindow::applicationCache):
3367         * page/DOMWindow.h:
3368         (WebCore::DOMWindow::optionalApplicationCache):
3369         Add ApplicationCache member.
3370         
3371 2008-04-17  Anders Carlsson  <andersca@apple.com>
3372
3373         Build fix.
3374
3375         * WebCore.vcproj/WebCore.vcproj:
3376
3377 2008-04-17  Dean Jackson  <dino@apple.com>
3378
3379         Reviewed by Hyatt.
3380
3381         Fix for <rdar://problem/5849968> translate method should have Y=0 when only X is present
3382
3383         Test: fast/css/transform-default-parameter.html
3384
3385         * css/CSSStyleSelector.cpp: (WebCore::CSSStyleSelector::applyProperty):
3386         translate function with only X parameter now leaves the Y parameter as zero.
3387
3388 2008-04-17  Anders Carlsson  <andersca@apple.com>
3389
3390         Reviewed by Sam.
3391         
3392         Add plumbing for associating document loaders with application caches.
3393         
3394         * loader/DocumentLoader.cpp:
3395         (WebCore::DocumentLoader::DocumentLoader):
3396         (WebCore::DocumentLoader::~DocumentLoader):
3397         (WebCore::DocumentLoader::originalURL):
3398         (WebCore::DocumentLoader::requestURL):
3399         (WebCore::DocumentLoader::responseURL):
3400         (WebCore::DocumentLoader::responseMIMEType):
3401         (WebCore::DocumentLoader::setCandidateApplicationCacheGroup):
3402         (WebCore::DocumentLoader::setApplicationCache):
3403         (WebCore::DocumentLoader::toplevelApplicationCache):
3404         * loader/DocumentLoader.h:
3405         (WebCore::DocumentLoader::candidateApplicationCacheGroup):
3406         (WebCore::DocumentLoader::applicationCache):
3407         * loader/appcache/ApplicationCacheGroup.h:
3408         (WebCore::ApplicationCacheGroup::documentLoaderDestroyed):
3409
3410 2008-04-17  Adam Roben  <aroben@apple.com>
3411
3412         Fix Bug 18544: REGRESSION (r31951): Two fast/xsl tests crash
3413
3414         <https://bugs.webkit.org/show_bug.cgi?id=18544>
3415
3416         r31951 changed XSLTProcessor::parseErrorFunc to expect a Console* as
3417         the context parameter. The caller in XSLTProcessor was changed, but
3418         the one in XSLStyleSheet was missed.
3419
3420         Reviewed by Alexey Proskuryakov.
3421
3422         * xml/XSLStyleSheet.cpp:
3423         (WebCore::XSLStyleSheet::parseString): Pass the Console as the context
3424         to parseErrorFunc.
3425
3426 2008-04-17  Adam Roben  <aroben@apple.com>
3427
3428         Windows build fix after r31981
3429
3430         * dom/Document.idl: Omit getCSSCanvasContext from the COM bindings.
3431
3432 2008-04-17  Ariya Hidayat  <ariya.hidayat@trolltech.com>
3433
3434         Reviewed by Simon.
3435
3436         Implemented getFileModificationTime and pathGetFileName for the Qt port.
3437
3438         * platform/qt/FileSystemQt.cpp:
3439         (WebCore::getFileModificationTime):
3440
3441 2008-04-17  Mark Rowe  <mrowe@apple.com>
3442
3443         Fix the non-Mac builds that I broke with my Mac build fix.
3444
3445         * css/CSSMutableStyleDeclaration.cpp:
3446         (WebCore::CSSMutableStyleDeclaration::getLayeredShorthandValue): Explicitly use the size_t version of max
3447         to avoid making assumptions about sizeof(size_t).
3448
3449 2008-04-17  Mark Rowe  <mrowe@apple.com>
3450
3451         Rubber-stamped by Dan Bernstein.
3452
3453         Fix the Mac build.
3454
3455         * css/CSSMutableStyleDeclaration.cpp:
3456         (WebCore::CSSMutableStyleDeclaration::getLayeredShorthandValue): Update to use size_t in place of unsigned.
3457         * dom/NamedNodeMap.h: Ditto.
3458         * page/AccessibilityObject.h: Forward-declare AccessibilityObjectWrapper in the non-Objective-C case too.
3459
3460 2008-04-16  Jon Honeycutt  <jhoneycutt@apple.com>
3461
3462         Reviewed by Darin.
3463
3464         Use size_t instead of unsigned where appropriate.
3465
3466         * css/CSSValueList.h:
3467         * dom/NamedAttrMap.h:
3468         * rendering/RenderStyle.h:
3469
3470 2008-04-15  Jon Honeycutt  <jhoneycutt@apple.com>
3471
3472         Reviewed by Darin.
3473
3474         Add some methods to check AccessibilityObject state.
3475
3476         * page/AccessibilityObject.cpp:
3477         (WebCore::AccessibilityObject::AccessibilityObject): Assert that the
3478         passed renderer is not null.
3479         (WebCore::AccessibilityObject::isPasswordField): Refactored to use early
3480         return.
3481         (WebCore::AccessibilityObject::isPressed): Return true if this is a
3482         button in the pressed state.
3483         (WebCore::AccessibilityObject::isIndeterminate): Return true if this is
3484         a tri-state checkbox in the indeterminate state.
3485         (WebCore::AccessibilityObject::isChecked): True if this is a radio
3486         button or checkbox in the checked state.
3487         (WebCore::AccessibilityObject::isHovered): True if object is currently
3488         under the mouse cursor.
3489         (WebCore::AccessibilityObject::isMultiSelect): True if this is a select
3490         element capable of multi-select.
3491         (WebCore::AccessibilityObject::isReadOnly): False if this object has
3492         editable content.
3493         (WebCore::AccessibilityObject::isOffScreen): True if this object is not
3494         in the visible portion of the view.
3495         * page/AccessibilityObject.h: Grouped methods into is-state and is-kind.
3496
3497 2008-04-15  Jon Honeycutt  <jhoneycutt@apple.com>
3498
3499         Reviewed by Darin.
3500
3501         Add AccessibilityObjectWrapper to Windows.
3502
3503         * WebCore.vcproj/WebCore.vcproj: Add AccessibilityObjectWrapperWin.h
3504         * page/AccessibilityObject.h: Include COMPtr.h,
3505         AccessibilityObjectWrapperWin.h on Windows. Define wrapper() and
3506         setWrapper() if accessibility is present. Add an m_wrapper on Windows.
3507         * page/AccessibilityObject.cpp:
3508         (WebCore::AccessibilityObject::detach): Clear m_wrapper if
3509         accessibility is present.
3510         * page/win/AccessibilityObjectWrapperWin.h: Added; defines a wrapper for
3511         AccessibilityObjects on Windows.
3512         (WebCore::AccessibilityObjectWrapper::attached): Return true if attached
3513         to an object.
3514         (WebCore::AccessibilityObjectWrapper::accessibilityObject): Return the
3515         wrapped object.
3516         (WebCore::AccessibilityObjectWrapper::AccessibilityObjectWrapper):
3517
3518 2008-04-15  Jon Honeycutt  <jhoneycutt@apple.com>
3519
3520         Reviewed by Darin.
3521
3522         Add AXObjectCache to Windows.
3523
3524         * WebCore.vcproj/WebCore.vcproj: Add AXObjectCacheWin.cpp.
3525         * page/AXObjectCache.h: Add handleFocusedUIElementChanged definition to
3526         non-Mac platforms, and added stub for it. Replace PLATFORM(MAC)
3527         conditional with HAVE(ACCESSIBILITY) for stubs.
3528         (WebCore::AXObjectCache::enableAccessibility):
3529         (WebCore::AXObjectCache::accessibilityEnabled):
3530         * page/win/AXObjectCacheWin.cpp: Added; contains stubs for the methods
3531         below.
3532         (WebCore::AXObjectCache::detachWrapper):
3533         (WebCore::AXObjectCache::attachWrapper):
3534         (WebCore::AXObjectCache::postNotification):
3535         (WebCore::AXObjectCache::postNotificationToElement):
3536         * config.h: Define HAVE_ACCESSIBILITY on Mac and Windows.
3537
3538 2008-04-15  Jon Honeycutt  <jhoneycutt@apple.com>
3539
3540         Reviewed by Darin.
3541
3542         * WebCore.vcproj/WebCore.vcproj: Fix path to AXObjectCache.h.
3543
3544 2008-04-16  Brady Eidson  <beidson@apple.com>
3545
3546         Reviewed by Darin Adler
3547
3548         Merge the StorageAreaClient into the StorageArea class itself as pure virtual methods.
3549         Add "LocalStorageArea" and "SessionStorageArea" implementations, and have SessionStorage
3550         and LocalStorage instantiate the appropriate type of StorageArea object.
3551
3552         This purpose of this change is because while adding the persistent store to LocalStorage,
3553         it became obvious that the client approach wasn't scaling well.  Additionally, a StorageArea
3554         backing a local storage area required vastly different data members compared to one backing
3555         a session storage area.
3556
3557         This will be much cleaner going forward.
3558
3559         * GNUmakefile.am:
3560         * WebCore.pro:
3561         * WebCore.vcproj/WebCore.vcproj:
3562         * WebCore.xcodeproj/project.pbxproj:
3563         * WebCoreSources.bkl:
3564
3565         * storage/LocalStorage.cpp:
3566         (WebCore::LocalStorage::storageArea):
3567         * storage/LocalStorage.h:
3568
3569         * storage/LocalStorageArea.cpp: Added.
3570         (WebCore::LocalStorageArea::LocalStorageArea):
3571         (WebCore::LocalStorageArea::itemChanged):
3572         (WebCore::LocalStorageArea::itemRemoved):
3573         (WebCore::LocalStorageArea::dispatchStorageEvent):
3574         * storage/LocalStorageArea.h: Added.
3575         (WebCore::LocalStorageArea::create):
3576
3577         * storage/SessionStorage.cpp:
3578         (WebCore::SessionStorage::copy):
3579         (WebCore::SessionStorage::storageArea):
3580         * storage/SessionStorage.h:
3581
3582         * storage/SessionStorageArea.cpp: Added.
3583         (WebCore::SessionStorageArea::copy):
3584         (WebCore::SessionStorageArea::SessionStorageArea):
3585         (WebCore::SessionStorageArea::itemChanged):
3586         (WebCore::SessionStorageArea::itemRemoved):
3587         (WebCore::SessionStorageArea::dispatchStorageEvent):
3588         * storage/SessionStorageArea.h: Added.
3589         (WebCore::SessionStorageArea::create):
3590         (WebCore::SessionStorageArea::page):
3591
3592         * storage/StorageArea.cpp:
3593         (WebCore::StorageArea::StorageArea):
3594         (WebCore::StorageArea::setItem):
3595         (WebCore::StorageArea::removeItem):
3596         (WebCore::StorageArea::storageMap):
3597         * storage/StorageArea.h:
3598
3599         * storage/StorageAreaClient.h: Removed.
3600
3601 2008-04-16  David Hyatt  <hyatt@apple.com>
3602
3603         Add support for the ability to draw directly into CSS images using CanvasRenderingContext2D.
3604
3605         Reviewed by olliej
3606
3607         Added fast/canvas/canvas-bg.html
3608
3609         * GNUmakefile.am:
3610         * WebCore.pro:
3611         * WebCore.vcproj/WebCore.vcproj:
3612         * WebCore.xcodeproj/project.pbxproj:
3613         * WebCoreSources.bkl:
3614         * css/CSSCanvasValue.cpp: Added.
3615         (WebCore::CSSCanvasValue::~CSSCanvasValue):
3616         (WebCore::CSSCanvasValue::cssText):
3617         (WebCore::CSSCanvasValue::canvasChanged):
3618         (WebCore::CSSCanvasValue::canvasResized):
3619         (WebCore::CSSCanvasValue::fixedSize):
3620         (WebCore::CSSCanvasValue::element):
3621         (WebCore::CSSCanvasValue::image):
3622         * css/CSSCanvasValue.h: Added.
3623         (WebCore::CSSCanvasValue::CSSCanvasValue):
3624         (WebCore::CSSCanvasValue::isFixedSize):
3625         (WebCore::CSSCanvasValue::setName):
3626         * css/CSSGradientValue.cpp:
3627         * css/CSSGradientValue.h:
3628         * css/CSSImageGeneratorValue.cpp:
3629         (WebCore::CSSImageGeneratorValue::generatedImage):
3630         * css/CSSImageGeneratorValue.h:
3631         (WebCore::CSSImageGeneratorValue::isFixedSize):
3632         (WebCore::CSSImageGeneratorValue::fixedSize):
3633         * css/CSSParser.cpp:
3634         (WebCore::CSSParser::parseContent):
3635         (WebCore::CSSParser::parseBackgroundImage):
3636         (WebCore::CSSParser::parseBorderImage):
3637         (WebCore::CSSParser::parseCanvas):
3638         * css/CSSParser.h:
3639         * dom/Document.cpp:
3640         (WebCore::Document::getCSSCanvasContext):
3641         (WebCore::Document::getCSSCanvasElement):
3642         * dom/Document.h:
3643         * dom/Document.idl:
3644         * html/HTMLCanvasElement.cpp:
3645         (WebCore::HTMLCanvasElement::HTMLCanvasElement):
3646         (WebCore::HTMLCanvasElement::reset):
3647         * html/HTMLCanvasElement.h:
3648         (WebCore::HTMLCanvasElement::setSize):
3649         * rendering/RenderBox.cpp:
3650         (WebCore::RenderBox::calculateBackgroundSize):
3651         (WebCore::RenderBox::imageChanged):
3652         * rendering/RenderBox.h:
3653         * rendering/RenderImage.cpp:
3654         (WebCore::RenderImage::imageChanged):
3655         * rendering/RenderImage.h:
3656         (WebCore::RenderImage::imagePtr):
3657         (WebCore::RenderImage::intrinsicSizeChanged):
3658         * rendering/RenderImageGeneratedContent.h:
3659         (WebCore::RenderImageGeneratedContent::imageSize):
3660         (WebCore::RenderImageGeneratedContent::imagePtr):
3661         * rendering/RenderListMarker.cpp:
3662         (WebCore::RenderListMarker::layout):
3663         (WebCore::RenderListMarker::imageChanged):
3664         (WebCore::RenderListMarker::calcPrefWidths):
3665         (WebCore::RenderListMarker::getRelativeMarkerRect):
3666         * rendering/RenderListMarker.h:
3667         * rendering/RenderObject.cpp:
3668         (WebCore::RenderObject::paintBorderImage):
3669         (WebCore::RenderObject::imageChanged):
3670         * rendering/RenderObject.h:
3671         (WebCore::RenderObject::imageChanged):
3672         * rendering/RenderSVGImage.cpp:
3673         (WebCore::RenderSVGImage::imageChanged):
3674         * rendering/RenderSVGImage.h:
3675         * rendering/RenderStyle.cpp:
3676         (WebCore::StyleCachedImage::imageSize):
3677         (WebCore::StyleGeneratedImage::imageSize):
3678         * rendering/RenderStyle.h:
3679         (WebCore::StyleCachedImage::data):
3680         (WebCore::StyleGeneratedImage::StyleGeneratedImage):
3681         (WebCore::StyleGeneratedImage::data):
3682         (WebCore::StyleGeneratedImage::imageHasRelativeWidth):
3683         (WebCore::StyleGeneratedImage::imageHasRelativeHeight):
3684         (WebCore::StyleGeneratedImage::usesImageContainerSize):
3685         * rendering/RenderTableCol.cpp:
3686         (WebCore::RenderTableCol::imageChanged):
3687         * rendering/RenderTableCol.h:
3688         * rendering/RenderTableRow.cpp:
3689         (WebCore::RenderTableRow::imageChanged):
3690         * rendering/RenderTableRow.h:
3691         * rendering/RenderTableSection.cpp:
3692         (WebCore::RenderTableSection::imageChanged):
3693         * rendering/RenderTableSection.h:
3694
3695 2008-04-16  Anders Carlsson  <andersca@apple.com>
3696
3697         Reviewed by Darin.
3698
3699         Add manifest parser.
3700
3701         * loader/appcache/ManifestParser.cpp:
3702         (WebCore::):
3703         (WebCore::parseManifest):
3704         * loader/appcache/ManifestParser.h:
3705         * platform/text/CharacterNames.h:
3706
3707 2008-04-16  Darin Adler  <darin@apple.com>
3708
3709         Reviewed by Mitz.
3710
3711         - fix <rdar://problem/5858617> REGRESSION (r21452-Safari 3.1):
3712           Safari does not find words containing ß (German letter sharp-s)
3713
3714         Test: fast/text/find-case-folding.html
3715
3716         * platform/text/StringImpl.cpp:
3717         (WebCore::StringImpl::foldCase):
3718         Pass the folded length to foldCase rather than the original string length.
3719         Without this, we get an error code every time.
3720
3721 2008-04-16  Anders Carlsson  <andersca@apple.com>
3722
3723         Fix build.
3724         
3725         * loader/appcache/ApplicationCache.cpp:
3726         (WebCore::ApplicationCache::ApplicationCache):
3727         (WebCore::ApplicationCache::setManifestResource):
3728         (WebCore::ApplicationCache::addResource):
3729
3730 2008-04-16  Anders Carlsson  <andersca@apple.com>
3731
3732         Reviewed by Darin.
3733
3734         Add new protocolHostAndPortAreEqual function.
3735         
3736         * platform/KURL.cpp:
3737         (WebCore::KURL::host):
3738         (WebCore::KURL::setHost):
3739         (WebCore::KURL::setHostAndPort):
3740         (WebCore::protocolHostAndPortAreEqual):
3741         * platform/KURL.h:
3742         (WebCore::KURL::hostStart):
3743
3744 2008-04-16  Anders Carlsson  <andersca@apple.com>
3745
3746         Reviewed by Sam.
3747         
3748         Fix some style nits.
3749         
3750         * loader/appcache/ApplicationCache.cpp:
3751         (WebCore::ApplicationCache::ApplicationCache):
3752         (WebCore::ApplicationCache::setManifestResource):
3753         (WebCore::ApplicationCache::addResource):
3754         (WebCore::ApplicationCache::removeResource):
3755         (WebCore::ApplicationCache::dump):
3756         * loader/appcache/ApplicationCacheGroup.h:
3757
3758 2008-04-16  Anders Carlsson  <andersca@apple.com>
3759
3760         Reviewed by Brady and Sam.
3761
3762         Add ApplicationCache implementation. Stub out ApplicationCacheGroup methods
3763         needed by ApplicationCache.
3764         
3765         * loader/appcache/ApplicationCache.cpp:
3766         (WebCore::ApplicationCache::ApplicationCache):
3767         (WebCore::ApplicationCache::~ApplicationCache):
3768         (WebCore::ApplicationCache::setManifestResource):
3769         (WebCore::ApplicationCache::addResource):
3770         (WebCore::ApplicationCache::removeResource):
3771         (WebCore::ApplicationCache::resourceForURL):
3772         (WebCore::ApplicationCache::resourceForRequest):
3773         (WebCore::ApplicationCache::numDynamicEntries):
3774         (WebCore::ApplicationCache::dynamicEntry):
3775         (WebCore::ApplicationCache::addDynamicEntry):
3776         (WebCore::ApplicationCache::removeDynamicEntry):
3777         (WebCore::ApplicationCache::setOnlineWhitelist):
3778         (WebCore::ApplicationCache::isURLInOnlineWhitelist):
3779         (WebCore::ApplicationCache::dump):
3780         * loader/appcache/ApplicationCache.h:
3781         (WebCore::ApplicationCache::create):
3782         (WebCore::ApplicationCache::manifestResource):
3783         (WebCore::ApplicationCache::group):
3784         (WebCore::ApplicationCache::begin):
3785         (WebCore::ApplicationCache::end):
3786         * loader/appcache/ApplicationCacheGroup.h:
3787         (WebCore::ApplicationCacheGroup::manifestURL):
3788         (WebCore::ApplicationCacheGroup::cacheDestroyed):
3789
3790 2008-04-16  Adam Roben  <aroben@apple.com>
3791
3792         Fix Bug 18505: REGRESSION: Search is disabled and not functional
3793
3794         <https://bugs.webkit.org/show_bug.cgi?id=18505>
3795
3796         Reviewed by Tim Hatcher.
3797
3798         * page/inspector/ResourcesPanel.js:
3799         (WebInspector.ResourcesPanel.sourceFrameForResource): Added.
3800         * page/inspector/inspector.css: Added back rules for the search field
3801         that were removed in r31736.
3802         * page/inspector/inspector.html:
3803           - Removed the disabled attribute from the search field
3804           - Added back the #searchResults and #searchResultsResizer divs which
3805             were removed in r31736
3806         * page/inspector/inspector.js:
3807         (WebInspector.set showingSearchResults): Updated for class rename
3808         panels -> main-panels.
3809         (WebInspector.loaded): Added back the mousedown event listener for the
3810         search results resizer that was removed in r31736.
3811         (WebInspector.searchResultsResizerDrag): Updated for class rename
3812         panels -> main-panels.
3813         (WebInspector.performSearch):
3814           - Changed to use sourceFrameForResource
3815           - Changed to use showResource
3816           - Changed to save/restore the focused element around the setting of
3817             the current panel
3818           - Changed to get the source document from the match range instead of
3819             by crawling back up to the source view
3820           - Changed to bind the onselect handlers to this so that we can
3821             access the Elements/Resources panels
3822
3823 2008-04-16  Brady Eidson  <beidson@apple.com>
3824
3825         Reviewed by Sam Weinig
3826
3827         Changing ThreadSafeShared to start with a ref count of 1, so updating all users to
3828         adoptRef() that initial reference.
3829
3830         * bindings/js/JSCustomSQLStatementCallback.h:
3831         (WebCore::JSCustomSQLStatementCallback::create):
3832         * bindings/js/JSCustomSQLStatementErrorCallback.h:
3833         (WebCore::JSCustomSQLStatementErrorCallback::create):
3834         * bindings/js/JSCustomSQLTransactionCallback.h:
3835         (WebCore::JSCustomSQLTransactionCallback::create):
3836         * bindings/js/JSCustomSQLTransactionErrorCallback.h:
3837         (WebCore::JSCustomSQLTransactionErrorCallback::create):
3838
3839         * bindings/js/JSDatabaseCustom.cpp:
3840         (WebCore::JSDatabase::changeVersion):
3841         (WebCore::JSDatabase::transaction):
3842
3843         * bindings/js/JSSQLTransactionCustom.cpp:
3844         (WebCore::JSSQLTransaction::executeSql):
3845
3846         * dom/Document.cpp:
3847         (WebCore::Document::databaseThread):
3848
3849         * platform/SecurityOrigin.cpp:
3850         (WebCore::SecurityOrigin::create):
3851
3852         * platform/sql/SQLiteAuthorizer.h:
3853         (WebCore::SQLiteAuthorizer::create):
3854         (WebCore::SQLiteAuthorizer::SQLiteAuthorizer):
3855
3856         * storage/ChangeVersionWrapper.cpp:
3857         (WebCore::ChangeVersionWrapper::performPreflight):
3858         (WebCore::ChangeVersionWrapper::performPostflight):
3859         * storage/ChangeVersionWrapper.h:
3860         (WebCore::ChangeVersionWrapper::create):
3861
3862         * storage/Database.cpp:
3863         (WebCore::Database::openAndVerifyVersion):
3864         (WebCore::Database::markAsDeletedAndClose):
3865         (WebCore::Database::changeVersion):
3866         (WebCore::Database::transaction):
3867         (WebCore::Database::scheduleTransaction):
3868         (WebCore::Database::scheduleTransactionStep):
3869         (WebCore::Database::tableNames):
3870
3871         * storage/DatabaseAuthorizer.h:
3872         (WebCore::DatabaseAuthorizer::create):
3873
3874         * storage/DatabaseTask.h:
3875         (WebCore::DatabaseOpenTask::create):
3876         (WebCore::DatabaseCloseTask::create):
3877         (WebCore::DatabaseTransactionTask::create):
3878         (WebCore::DatabaseTableNamesTask::create):
3879
3880         * storage/DatabaseThread.cpp:
3881         (WebCore::DatabaseThread::scheduleTask): Change to take a PassRefPtr instead of raw
3882         (WebCore::DatabaseThread::scheduleImmediateTask): Ditto
3883         * storage/DatabaseThread.h:
3884         (WebCore::DatabaseThread::create):
3885
3886         * storage/SQLError.h:
3887         (WebCore::SQLError::create):
3888         (WebCore::SQLError::SQLError):
3889
3890         * storage/SQLResultSet.h:
3891         (WebCore::SQLResultSet::create):
3892
3893         * storage/SQLStatement.cpp:
3894         (WebCore::SQLStatement::create):
3895         (WebCore::SQLStatement::execute):
3896         (WebCore::SQLStatement::setDatabaseDeletedError):
3897         (WebCore::SQLStatement::setVersionMismatchedError):
3898         (WebCore::SQLStatement::setFailureDueToQuota):
3899         * storage/SQLStatement.h:
3900
3901         * storage/SQLTransaction.cpp:
3902         (WebCore::SQLTransaction::create):
3903         (WebCore::SQLTransaction::executeSQL):
3904         (WebCore::SQLTransaction::openTransactionAndPreflight):
3905         (WebCore::SQLTransaction::deliverTransactionCallback):
3906         (WebCore::SQLTransaction::handleCurrentStatementError):
3907         (WebCore::SQLTransaction::deliverStatementCallback):
3908         (WebCore::SQLTransaction::postflightAndCommit):
3909         * storage/SQLTransaction.h:
3910
3911 2008-04-16  Anders Carlsson  <andersca@apple.com>
3912
3913         Reviewed by Adam and Brady.
3914         
3915         Add implementation of ApplicationCacheResource.
3916         
3917         * loader/appcache/ApplicationCacheResource.cpp:
3918         (WebCore::ApplicationCacheResource::ApplicationCacheResource):
3919         (WebCore::ApplicationCacheResource::dumpType):
3920         * loader/appcache/ApplicationCacheResource.h:
3921         (WebCore::ApplicationCacheResource::):
3922         (WebCore::ApplicationCacheResource::create):
3923         (WebCore::ApplicationCacheResource::type):
3924         (WebCore::ApplicationCacheResource::addType):
3925
3926 2008-04-16  Timothy Hatcher  <timothy@apple.com>
3927
3928         Fixes an issue where the source for a resource that had errors would
3929         not be shown because the view was created before the resource load
3930         finished. The right view is now created, even if the resource isn't 
3931         finished. The SourceView just makes sure to not load the source until
3932         the resource is finished. Only if the category changes, does the view
3933         need to be recreated.
3934
3935         Reviewed by Adam Roben.
3936
3937         * page/inspector/Resource.js:
3938         (WebInspector.Resource.prototype.set category): Call recreateViewForResourceIfNeeded.
3939         * page/inspector/ResourcesPanel.js:
3940         (WebInspector.ResourcesPanel.prototype.recreateViewForResourceIfNeeded):
3941         Added. Tries to make a new view, if the view is the same prototype of the
3942         previous view, return early. If they differ, close and detach the old view
3943         and associate the resource with the new view. Calling updateErrorsAndWarnings
3944         is needed, because the errors and warnings that might have been added to the
3945         previous view will be lost, so make the tree element match.
3946         (WebInspector.Resource.prototype._createResourceView): Always create a view
3947         that matches the resource category. Ignore the loading and failed status.
3948         * page/inspector/SourceView.js:
3949         (WebInspector.SourceView.prototype.setupSourceFrameIfNeeded): Don't setup the
3950         frame if the resource hasn't finished or if the load failed.
3951
3952 2008-04-16  Timothy Hatcher  <timothy@apple.com>
3953
3954         Adds a console formatter for Error objects. So typing a expression in the
3955         console that ends in an exception will print meaningful info. Also calling
3956         console.{log,error,warn,info} with an error object will output nicely.
3957
3958         Reviewed by Adam Roben.
3959
3960         * page/inspector/Console.js:
3961         (WebInspector.Console.prototype._formaterror): Added. Formats an error
3962         object by showing it like other exceptions, with a clickable file URL.
3963
3964 2008-04-16  Timothy Hatcher  <timothy@apple.com>
3965
3966         Refactors code that updates the errors and warnings count in the
3967         resources sidebar so other functions can easily trigger updates.
3968
3969         Reviewed by Adam Roben.
3970
3971         * page/inspector/ResourcesPanel.js:
3972         (WebInspector.ResourcesPanel.prototype.addMessageToResource): Call updateErrorsAndWarnings.
3973         Removes code that updates the bubbleText and class names.
3974         (WebInspector.ResourcesPanel.prototype.clearMessages): Ditto.
3975         (WebInspector.ResourceSidebarTreeElement.prototype.updateErrorsAndWarnings):
3976         Added. Updates the bubbleText and adds or removes the class names
3977         depending on if the values are zero.
3978
3979 2008-04-16  Antti Koivisto  <antti@apple.com>
3980
3981         Reviewed by Alexey.
3982         
3983         Fix <rdar://problem/5863728>
3984         REGRESSION: Garbage character shown in temperatures in the Weather widget (encoding issue with degree symbol)
3985         
3986         Parse the encoding attribute in PreloadScanner.
3987
3988         Test: fast/encoding/script-preload-encoding.html
3989
3990         * html/PreloadScanner.cpp:
3991         (WebCore::PreloadScanner::processAttribute):
3992         (WebCore::PreloadScanner::emitTag):
3993         (WebCore::PreloadScanner::emitCSSRule):
3994         * html/PreloadScanner.h:
3995         * loader/DocLoader.cpp:
3996         (WebCore::DocLoader::preload):
3997         * loader/DocLoader.h:
3998
3999 2008-04-16  Anders Carlsson  <andersca@apple.com>
4000
4001         Reviewed by Adam.
4002
4003         Generate the DOMApplicationCache JS wrapper, add JSDOMApplicationCacheCustom.cpp and 
4004         fix typos in the #if line.
4005         
4006         * DerivedSources.make:
4007         * WebCore.vcproj/WebCore.vcproj:
4008         * WebCore.xcodeproj/project.pbxproj:
4009         * bindings/js/JSDOMApplicationCacheCustom.cpp: Added.
4010         * loader/appcache/ApplicationCache.cpp:
4011         * loader/appcache/ApplicationCache.h:
4012         * loader/appcache/ApplicationCacheGroup.cpp:
4013         * loader/appcache/ApplicationCacheGroup.h:
4014         * loader/appcache/ApplicationCacheResource.cpp:
4015         * loader/appcache/ApplicationCacheResource.h:
4016         * loader/appcache/DOMApplicationCache.cpp:
4017         * loader/appcache/DOMApplicationCache.h:
4018         * loader/appcache/DOMApplicationCache.idl:
4019         * loader/appcache/ManifestParser.cpp:
4020         * loader/appcache/ManifestParser.h:
4021
4022 2008-04-16  Sam Weinig  <sam@webkit.org>
4023
4024         Reviewed by Geoffrey Garen.
4025
4026         - To keep the behavior of the WebKit and JavaScriptCore API's the same,
4027           we need to hide the fact that the global object and the window object
4028           are no longer the same thing, and the the global object now changes on
4029           navigations.  To do this, only the wrapper should ever be exposed.  This
4030           fixes the two remaining spots where the internal global object is exposed,
4031           the windowScriptObject returned from [WebFrame windowObject] and the object
4032           return by calling JSContextGetGlobalObject on [WebFrame globalContext]
4033
4034         * bindings/js/JSDOMWindowWrapper.cpp:
4035         (WebCore::JSDOMWindowWrapper::putWithAttributes):
4036         * bindings/js/JSDOMWindowWrapper.h:
4037         Forward this new method so that JSObjectSetProperty doesn't set properties on the 
4038         wrapper.
4039
4040         * page/mac/FrameMac.mm:
4041         (WebCore::Frame::windowScriptObject):
4042         Return the wrapper instead of the global object.
4043
4044 2008-04-16  David Hyatt  <hyatt@apple.com>
4045
4046         Eliminate the paintBuffer and drawImage(ImageBuffer*) methods from GraphicsContext* in favor of just
4047         snagging an Image* from the ImageBuffer and drawing that instead.
4048
4049         Enhance canvas with a CanvasObserver so that notifications of dirtying or resizing can be tracked by
4050         a consumer.
4051
4052         Reviewed by olliej
4053
4054         * html/CanvasRenderingContext2D.cpp:
4055         (WebCore::CanvasRenderingContext2D::drawImage):
4056         * html/HTMLCanvasElement.cpp:
4057         (WebCore::HTMLCanvasElement::HTMLCanvasElement):
4058         (WebCore::HTMLCanvasElement::willDraw):
4059         (WebCore::HTMLCanvasElement::reset):
4060         (WebCore::HTMLCanvasElement::paint):
4061         * html/HTMLCanvasElement.h:
4062         (WebCore::CanvasObserver::~CanvasObserver):
4063         (WebCore::HTMLCanvasElement::setSize):
4064         (WebCore::HTMLCanvasElement::setObserver):
4065         * platform/graphics/GraphicsContext.cpp:
4066         (WebCore::GraphicsContext::drawImage):
4067         (WebCore::GraphicsContext::drawTiledImage):
4068         * platform/graphics/GraphicsContext.h:
4069         * platform/graphics/ImageBuffer.h:
4070         (WebCore::ImageBuffer::clearImage):
4071         * platform/graphics/cairo/GraphicsContextCairo.cpp:
4072         * platform/graphics/cg/GraphicsContextCG.cpp:
4073         * platform/graphics/cg/ImageCG.cpp:
4074         (WebCore::BitmapImage::draw):
4075         (WebCore::Image::drawPattern):
4076         * platform/graphics/cg/ImageSourceCG.cpp:
4077         (WebCore::ImageSource::createFrameAtIndex):
4078         * platform/graphics/qt/GraphicsContextQt.cpp:
4079         * platform/graphics/wx/GraphicsContextWx.cpp:
4080
4081 2008-04-16  Steve Falkenburg  <sfalken@apple.com>
4082
4083         Improve timer latency/resolution.
4084                 
4085         The primary timing mechanism is now CreateTimerQueueTimer, with a PostMessage from
4086         the callback proc.  This event will be delivered sooner than if we used SetTimer(),
4087         since it is higher priority than other messages.
4088         
4089         If there is an input message pending, we'll use we SetTimer() based timers to avoid
4090         starving user input.
4091
4092         Don't call PostMessage immediately on all timers < 10ms.  Only call immediately if
4093         timer is already expired.  This avoids the case where no timers would be processed,
4094         causing the timer to be re-posted via the slower SetTimer method.
4095
4096         Don't call PostMessage immediately if there's a pending WM_PAINT, since
4097         we don't want to starve all paints when bombarded with a continuous stream of low
4098         duration timers.
4099
4100         Removed reentrancy check, since we're now looking for specific starvation cases,
4101         and will typically defer non-expired timers through CreateTimerQueueTimer.
4102
4103         The reason Windows wouldn't starve paints in favor of timers with the old code:
4104         When we went to reset the timer when it fired, the timer reset code treated this as a
4105         reentrant timer, causing us to hit the slow SetTimer code rather than calling PostMessage,
4106         even for timers expiring in < 10ms.  I corrected that, exposing the paint starvation problem.
4107
4108         Use timeBeginPeriod/timeEndPeriod to improve resolution of system timers.
4109         Limit this resolution change to within 20ms of the last high resolution timer request.
4110                         
4111         Corrected GetQueueStatus to check for specific input (and paint) messages rather than
4112         checking QS_ALLINPUT.  Contrary to its name, QS_ALLINPUT actually indicates interest
4113         in ALL queued messages, not just input messages.
4114         
4115         Fix SetTimer/KillTimer calls to pass our window handle.
4116
4117         Reviewed by Brady.
4118
4119         * platform/win/SharedTimerWin.cpp:
4120         (WebCore::):
4121         (WebCore::TimerWindowWndProc):
4122         (WebCore::queueTimerProc):
4123         (WebCore::setSharedTimerFireTime):
4124         (WebCore::stopSharedTimer):
4125
4126 2008-04-16  Adam Roben  <aroben@apple.com>
4127
4128         Fix console-log-formatting to truly test formatting an undefined value
4129
4130         Exceptions thrown by the test will also now be shown as errors.
4131
4132         Reviewed by Tim Hatcher.
4133
4134         * manual-tests/inspector/console-log-formatting.html:
4135         (test): Use console.error to report exceptions.
4136         (runTests): Use window.noSuchVariable instead of just noSuchVariable
4137         to avoid an exception.
4138
4139 2008-04-16  Anatoli Papirovski  <apapirovski@mac.com>
4140
4141         Reviewed by David.
4142
4143         Optimized the calculation of background-size.
4144
4145         * rendering/RenderBox.cpp:
4146         (WebCore::RenderBox::calculateBackgroundSize):
4147
4148 2008-04-16  Adam Roben  <aroben@apple.com>
4149
4150         Fix Bug 17228: console.{log,warn,info,error} should support format
4151         strings, variable arguments
4152
4153         <https://bugs.webkit.org/show_bug.cgi?id=17228>
4154         <rdar://problem/5732828>
4155
4156         Reviewed by Tim Hatcher.
4157
4158         Test: manual-tests/inspector/console-log-formatting.html
4159
4160         * page/inspector/Console.js:
4161         (WebInspector.ConsoleMessage): Pass any extra arguments down to
4162         _format.
4163         (WebInspector.ConsoleMessage._format): This method constructs
4164         this.formattedMessage. We treat the first parameter as a format
4165         string. Any parameters that have not been used after substituting into
4166         the format string are concatenated together, separated by spaces.
4167         (WebInspector.ConsoleMessage.toMessageElement): Updated to use
4168         this.formattedMessage.
4169         (WebInspector.ConsoleMessage.toString): Ditto.
4170
4171 2008-04-15  Adam Roben  <aroben@apple.com>
4172
4173         Make String.format return an array of unused substitutions
4174
4175         String.format now returns an object with two properties:
4176         formattedResult and unusedSubstitutions.
4177
4178         Reviewed by Tim Hatcher.
4179
4180         * page/inspector/utilities.js:
4181         (String.vsprintf): Updated for changes to String.format. We throw away
4182         the array of unused substitutions.
4183         (String.format): Changed to keep track of which substitutions are used
4184         when formatting. We then return both the formatted result and the
4185         array of unused substitutions.
4186
4187 2008-04-15  Adam Roben  <aroben@apple.com>
4188
4189         Generalize String.format some more
4190
4191         String.format now takes an initial value and an append function which
4192         it uses to build the result. Each time a token is processed,
4193         append(valueSoFar, newValue) is called.
4194
4195         Reviewed by Tim Hatcher.
4196
4197         * page/inspector/utilities.js:
4198         (String.vsprintf): Pass the empty string for the initial value, and
4199         a function that concatenates two strings as the append function.
4200         (String.format): Use initialValue and append to build the result
4201         instead of only working with strings.
4202
4203 2008-04-15  Adam Roben  <aroben@apple.com>
4204
4205         Add String.format
4206
4207         String.format is a more generic form of String.vsprintf that takes a
4208         set of formatter functions, one for each supported format specifier.
4209         Each formatter function is passed the relevant token and substitution
4210         value, and returns the formatted result.
4211
4212         Reviewed by Tim Hatcher.
4213
4214         * page/inspector/utilities.js:
4215         (String.standardFormatters): Added.
4216         (String.vsprintf): Changed to call through to String.format.
4217         (String.format): Added. Most of the code came from String.vsprintf,
4218         except that we use the passed-in formatters to format the
4219         substitutions rather than hard-coding how to handle each format
4220         specifier.
4221
4222 2008-04-15  Adam Roben  <aroben@apple.com>
4223
4224         Refactor String.vsprintf to separate tokenizing and substituting
4225
4226         This will eventually be useful for the various console methods that
4227         take a format string.
4228
4229         Reviewed by Tim Hatcher.
4230
4231         * page/inspector/utilities.js:
4232         (String.tokenizeFormatString): Added. This uses the format parsing
4233         code from String.vsprintf but just returns an array of "string" and
4234         "specifier" tokens.
4235         (String.vsprintf): Now calls String.tokenizeFormatString and processes
4236         the tokens one at a time.
4237
4238 2008-04-15  Adam Roben  <aroben@apple.com>
4239
4240         Pass all arguments to console.{log,warn,info,error} into the Inspector's JS
4241
4242     &n