3dcf213fb7dddcc962314c9c264ad7177809efee
[WebKit-https.git] / WebCore / ChangeLog
1 2008-09-04  Adam Roben  <aroben@apple.com>
2
3         Windows build fix
4
5         * platform/graphics/win/FontPlatformData.h: Added a missing #include
6         of PassRefPtr.h, and corrected the capitalization of RefCounted.h.
7         * platform/text/PlatformString.h: Added a missing #include of
8         PassRefPtr.h.
9
10 2008-09-04  Tor Arne Vestbø  <tavestbo@trolltech.com>
11
12         Reviewed by Simon.
13
14         Fix the QtWebKit build to match changes in r36016
15
16         * WebCore.pro:
17         * bridge/qt/qt_instance.cpp:
18         (KJS::Bindings::QtInstance::getRuntimeObject):
19         * bridge/qt/qt_runtime.cpp:
20         (KJS::Bindings::convertQVariantToValue):
21         (KJS::Bindings::QtConnectionObject::execute):
22
23 2008-09-04  Tor Arne Vestbø  <tavestbo@trolltech.com>
24
25         Reviewed by Simon.
26
27         Re-enable support for user stylesheets in QtWebKit
28         
29         QtWebKit now follows the FRAME_LOADS_USER_STYLESHEET
30         code path, which allows us to keep API support for
31         loading user style sheets from remote URLs.
32         
33         As part of the change UserStyleSheetLoader.cpp/h was
34         moved from WebCore/loader/mac to WebCore/loader.
35
36         * WebCore.pro:
37         * WebCore.xcodeproj/project.pbxproj:
38         * dom/Document.h:
39         * loader/UserStyleSheetLoader.cpp: Renamed from WebCore/loader/mac/UserStyleSheetLoader.cpp.
40         (UserStyleSheetLoader::UserStyleSheetLoader):
41         (UserStyleSheetLoader::~UserStyleSheetLoader):
42         * loader/UserStyleSheetLoader.h: Renamed from WebCore/loader/mac/UserStyleSheetLoader.h.
43         * page/qt/FrameQt.cpp:
44         (WebCore::Frame::setUserStyleSheetLocation):
45         (WebCore::Frame::setUserStyleSheet):
46
47 2008-09-04  Alp Toker  <alp@nuanti.com>
48
49         Reviewed by Eric.
50
51         Remove left-over QT and CAIRO platform checks.
52
53         * html/CanvasRenderingContext2D.cpp:
54
55 2008-09-04  Eric Seidel  <eric@webkit.org>
56
57         Reviewed by Mark Rowe.
58
59         Fix leak of TextMetrics due to over-ref as see on buildbot.
60
61         * html/TextMetrics.h: use adoptRef since RefCounted starts @ refcount 1 instead of 0 now.
62
63 2008-09-04  Dan Bernstein  <mitz@apple.com>
64
65         Reviewed by Dave Hyatt.
66
67         - fix https://bugs.webkit.org/show_bug.cgi?id=19717
68           <rdar://problem/6026832> REGRESSION (r31876): menu items render horizontally at the Economist
69
70         * rendering/RenderBlock.cpp:
71         (WebCore::RenderBlock::layoutOnlyPositionedObjects): In the
72         positioned movement only case, call
73         tryLayoutDoingPositionedMovementOnly() and fall back on doing a full
74         layout if that fails.
75         (WebCore::RenderBlock::layoutPositionedObjects): Ditto.
76         * rendering/RenderBox.h:
77         (WebCore::RenderBox::tryLayoutDoingPositionedMovementOnly): Renamed
78         layoutDoingPositionedMovementOnly to this, and made this function
79         check if the width changed. If it did, return, leaving the object
80         dirty. The caller can then call layout(). The width can change even
81         in the "positioned movement only" case if the object is shrink-to-fit
82         and the available width constraint is met. (This was the case in the
83         bug).
84         * rendering/RenderObject.h:
85         (WebCore::RenderObject::tryLayoutDoingPositionedMovementOnly):
86         Renamed layoutDoingPositionedMovementOnly() to this.
87
88 2008-09-03  Eric Seidel  <eric@webkit.org>
89
90         No review, build fix only.
91
92         Attempt to fix the Qt build.
93
94         * WebCore.pro: add page/animation to include path
95
96 2008-09-03  Mark Rowe  <mrowe@apple.com>
97
98         Mac build fix.  Correctly detect whether dashboard support is enabled.
99
100         * DerivedSources.make:
101
102 2008-09-03  Eric Seidel  <eric@webkit.org>
103
104         Reviewed by Sam.
105
106         Clean up Platform.h and add PLATFORM(CHROMIUM), PLATFORM(SKIA) and USE(V8_BINDINGS)
107
108         * Configurations/WebCore.xcconfig: add missing ENABLE_*
109         * config.h: add rules for V8_BINDINGS
110
111 2008-09-03  Eric Seidel  <eric@webkit.org>
112
113         Reviewed by Sam.
114
115         https://bugs.webkit.org/show_bug.cgi?id=20620
116
117         Add #if USE(JSC) around KJS dependencies
118         Remove !USE(JAVASCRIPTCORE_BINDINGS) support for 3 reasons:
119         1. Most platforms have it on anyway
120         2. V8 is going to want to share some of that code
121         3. Those platforms which want it off, should have a separate file instead of an #ifdef in our .cpp
122
123         * bindings/js/JSPluginElementFunctions.cpp: remove !USE(JAVASCRIPTCORE_BINDINGS) support
124         * config.h: change JAVASCRIPTCORE_BINDINGS to JSC and add USE(V8)
125         * html/HTMLAppletElement.cpp: remove USE(JAVASCRIPTCORE_BINDINGS) wrappers
126         * html/HTMLAppletElement.h: remove USE(JAVASCRIPTCORE_BINDINGS) wrappers
127         * html/HTMLEmbedElement.cpp: remove USE(JAVASCRIPTCORE_BINDINGS) wrappers
128         * html/HTMLEmbedElement.h: remove USE(JAVASCRIPTCORE_BINDINGS) wrappers
129         * html/HTMLObjectElement.cpp: remove USE(JAVASCRIPTCORE_BINDINGS) wrappers
130         * html/HTMLObjectElement.h: remove USE(JAVASCRIPTCORE_BINDINGS) wrappers
131         * html/HTMLPlugInElement.cpp: replace USE(JAVASCRIPTCORE_BINDINGS) with USE(JSC) where needed
132         * html/HTMLPlugInElement.h: replace USE(JAVASCRIPTCORE_BINDINGS) with USE(JSC) where needed
133         * platform/text/AtomicString.cpp: add USE(JSC)
134         * platform/text/AtomicString.h: add USE(JSC)
135         * platform/text/PlatformString.h: add USE(JSC)
136         * platform/text/String.cpp: add USE(JSC)
137         * platform/text/StringImpl.cpp: add USE(JSC)
138         * platform/text/StringImpl.h: add USE(JSC)
139
140 2008-09-03  Dean McNamee  <deanm@chromium.org>
141
142         Reviewed by Darin Adler.
143
144         Fix https://bugs.webkit.org/show_bug.cgi?id=20511
145         Bug 20511: Remove static initializers on Windows
146
147         Avoid static initializers on Windows by forcing Visual C++ to put
148         all static initializers in a code segment that is never executed.
149
150         * config.h:
151         * css/MediaFeatureNames.cpp:
152         * dom/EventNames.cpp:
153         * dom/QualifiedName.cpp:
154         * dom/make_names.pl:
155         * platform/StaticConstructors.h:
156         * platform/text/AtomicString.cpp:
157
158 2008-09-03  Dirk Schulze  <vbs85@gmx.de>
159
160         Reviewed by Dave Hyatt.
161
162         Make FontCairo draw TextStroke and TextFill separately.
163
164         [CAIRO] draw TextFill and TextStroke separately.
165         [https://bugs.webkit.org/show_bug.cgi?id=20631]
166
167         * platform/graphics/cairo/FontCairo.cpp:
168         (WebCore::Font::drawGlyphs):
169
170 2008-09-03  Peter Kasting  <zerodpx@gmail.com>
171
172         Reviewed by Dave Hyatt.
173
174         https://bugs.webkit.org/show_bug.cgi?id=19663
175         Account for paint and timer lag when animating images.  Also pretend
176         that images whose animations were paused (by becoming invisible)
177         continued to animate, by "catching up" to the correct frame when they're
178         shown again.
179
180         * platform/graphics/BitmapImage.cpp:
181         (WebCore::BitmapImage::BitmapImage):
182         (WebCore::BitmapImage::startAnimation):
183         (WebCore::BitmapImage::advanceAnimation):
184         (WebCore::BitmapImage::internalAdvanceAnimation):
185         (WebCore::BitmapImage::notifyObserverAndTrimDecodedData):
186         * platform/graphics/BitmapImage.h:
187         * platform/graphics/cairo/ImageCairo.cpp:
188         (WebCore::BitmapImage::draw):
189         * platform/graphics/cg/ImageCG.cpp:
190         (WebCore::BitmapImage::draw):
191         * platform/graphics/qt/ImageQt.cpp:
192         (WebCore::BitmapImage::draw):
193         * platform/graphics/wx/ImageWx.cpp:
194         (WebCore::BitmapImage::draw):
195
196 2008-09-03  Kevin McCullough  <kmccullough@apple.com>
197
198         Reviewed by Tim.
199
200         Remove the rest of the "zombie" code from the profiler.
201         - There is no longer a need for the ProfilerClient callback mechanism.
202
203         * page/Console.cpp: 
204         (WebCore::Console::Console):
205         (WebCore::Console::profile):
206         (WebCore::Console::profileEnd): Move the variables from the header to
207         here since we don't have to wait for a callback to use them.
208         * page/Console.h:
209         * page/InspectorController.cpp:
210         (WebCore::InspectorController::startUserInitiatedProfiling):
211         (WebCore::InspectorController::stopUserInitiatedProfiling):
212         * page/InspectorController.h:
213
214 2008-09-03  Ada Chan  <adachan@apple.com>
215
216         Windows build fix.
217
218         * WebCore.vcproj/WebCore.vcproj: Added JSWebKitCSSKeyframeRule.cpp and JSWebKitCSSKeyframesRule.cpp to the project.
219
220 2008-09-01  Dean Jackson  <dino@apple.com>
221
222         Reviewed by Dave Hyatt.
223
224         https://bugs.webkit.org/show_bug.cgi?id=20594
225         Add DOM interfaces for WebKitCSSKeyframeRule
226         and WebKitCSSKeyframesRule.
227
228         TEST: LayoutTests/css3/keyframes-rule.html
229
230         * css/WebKitCSSKeyframeRule.idl: Added
231         * css/WebKitCSSKeyframesRule.idl: Added
232
233         * bindings/js/JSCSSRuleCustom.cpp:
234         (WebCore::toJS):
235             Add return of new JS Keyframe rules
236         * bindings/objc/DOMInternal.h:
237             Include new internal header
238
239         * DerivedSources.make:
240         * GNUmakefile.am:
241         * WebCore.pro:
242         * WebCore.vcproj/WebCore.vcproj:
243         * WebCore.xcodeproj/project.pbxproj:
244         * WebCoreSources.bkl:
245             Build configs for new files
246
247 2008-09-03  Adam Roben  <aroben@apple.com>
248
249         Windows build fix
250
251         * DerivedSources.cpp: Add JSTextMetrics.cpp to fix the build.
252         * WebCore.vcproj/WebCore.vcproj: Add JSTextMetrics.h for
253         convenience/consistency.
254
255 2008-09-03  Adele Peterson  <adele@apple.com>
256
257         Build fix.
258
259         * WebCore.vcproj/WebCore.vcproj:
260
261 2008-09-03  David Hyatt  <hyatt@apple.com>
262
263         Fix for bug 18203, right floats should be allowed to overflow past the left border edge.
264
265         Reviewed by Darin (ages ago)
266
267         Added fast/block/float/clamped-right-float.html
268
269         * rendering/RenderBlock.cpp:
270         (WebCore::RenderBlock::positionNewFloats):
271
272 2008-09-02  David Hyatt  <hyatt@apple.com>
273
274         Add support for canvas text drawing APIs.
275
276         Reviewed by olliej
277
278         Tests added as fast/canvas/canvas-text-*.html
279
280         * DerivedSources.make:
281         * WebCore.xcodeproj/project.pbxproj:
282         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
283         (WebCore::JSCanvasRenderingContext2D::fillText):
284         (WebCore::JSCanvasRenderingContext2D::strokeText):
285         * css/CSSStyleSelector.cpp:
286         (WebCore::CSSStyleSelector::initForStyleResolve):
287         (WebCore::CSSStyleSelector::applyPropertyToStyle):
288         * css/CSSStyleSelector.h:
289         * html/CanvasRenderingContext2D.cpp:
290         (WebCore::CanvasRenderingContext2D::State::State):
291         (WebCore::CanvasRenderingContext2D::font):
292         (WebCore::CanvasRenderingContext2D::setFont):
293         (WebCore::CanvasRenderingContext2D::textAlign):
294         (WebCore::CanvasRenderingContext2D::setTextAlign):
295         (WebCore::CanvasRenderingContext2D::textBaseline):
296         (WebCore::CanvasRenderingContext2D::setTextBaseline):
297         (WebCore::CanvasRenderingContext2D::fillText):
298         (WebCore::CanvasRenderingContext2D::strokeText):
299         (WebCore::CanvasRenderingContext2D::measureText):
300         (WebCore::CanvasRenderingContext2D::drawTextInternal):
301         (WebCore::CanvasRenderingContext2D::accessFont):
302         * html/CanvasRenderingContext2D.h:
303         * html/CanvasRenderingContext2D.idl:
304         * html/TextMetrics.h: Added.
305         (WebCore::TextMetrics::create):
306         (WebCore::TextMetrics::width):
307         (WebCore::TextMetrics::setWidth):
308         (WebCore::TextMetrics::TextMetrics):
309         * html/TextMetrics.idl: Added.
310         * platform/graphics/Font.cpp:
311         (WebCore::Font::lineGap):
312         * platform/graphics/Font.h:
313         * platform/graphics/GraphicsContext.cpp:
314         (WebCore::GraphicsContext::drawBidiText):
315         * platform/graphics/GraphicsContext.h:
316         * platform/graphics/GraphicsTypes.cpp:
317         (WebCore::textAlignName):
318         (WebCore::parseTextAlign):
319         (WebCore::textBaselineName):
320         (WebCore::parseTextBaseline):
321         * platform/graphics/GraphicsTypes.h:
322         (WebCore::):
323
324 2008-09-03  John Sullivan  <sullivan@apple.com>
325
326         Fixed <rdar://problem/6193022> <rdar://problem/6193022> Crash occurs at WebCore::AnimationBase::propertiesEqual () after certain steps
327
328         Fixed by Darin, reviewed by me
329
330         * page/animation/AnimationBase.cpp:
331         (WebCore::AnimationBase::propertiesEqual):
332         added ensurePropertyMap() to this static function
333         (WebCore::AnimationBase::getPropertyAtIndex):
334         ditto
335         (WebCore::AnimationBase::getNumProperties):
336         ditto
337
338 2008-09-03  Kevin McCullough  <kmccullough@apple.com>
339
340         Reviewed by Darin and Tim.
341
342         Remove most of the "zombie" mode from the profiler.  Next we will need
343         to remove the client callback mechanism in profiles.
344         - These changes are a result of changes to JSCore.
345
346         * manual-tests/inspector/profiler-test-nested-start-and-stop-profiler.html:
347         * page/Console.cpp:
348         (WebCore::retrieveLastCaller):
349         (WebCore::Console::profileEnd):
350         * page/InspectorController.cpp:
351         (WebCore::InspectorController::stopUserInitiatedProfiling):
352
353 2008-09-03  Adele Peterson  <adele@apple.com>
354
355         Reviewed by Darin Adler.
356
357         Test: fast/forms/search-display-none-cancel-button.html
358
359         Allow display:none to work on a search field's cancel button.  Prepare for adding more style-ability for the results button too.
360
361         * css/html4.css: Set display:inline-block for these buttons.  Now they can be overridden by a web author.
362
363         * rendering/RenderTextControl.cpp:
364         (WebCore::RenderTextControl::setStyle): Add nil checks for the button renderers.
365         (WebCore::RenderTextControl::createResultsButtonStyle): Don't set the display explicitly.  This is now done in html4.css.
366         (WebCore::RenderTextControl::createCancelButtonStyle): ditto.
367         (WebCore::RenderTextControl::createSubtreeIfNeeded):
368         Reorganize this code so our complicated way of adding shadow nodes is abstracted out into the TextControlInnerElement class.
369         (WebCore::RenderTextControl::updateFromElement): Added nil checks for the button renderers.
370         (WebCore::RenderTextControl::subtreeHasChanged): ditto.
371         (WebCore::RenderTextControl::calcHeight): ditto.
372         (WebCore::RenderTextControl::nodeAtPoint): ditto.
373         (WebCore::RenderTextControl::layout): ditto.
374         (WebCore::RenderTextControl::calcPrefWidths): ditto.
375         (WebCore::RenderTextControl::clientPaddingLeft): ditto.
376         (WebCore::RenderTextControl::clientPaddingRight): ditto.
377
378         * rendering/TextControlInnerElements.cpp:
379         (WebCore::RenderTextControlInnerBlock::RenderTextControlInnerBlock): Moved from RenderTextControl.cpp.
380         (WebCore::RenderTextControlInnerBlock::nodeAtPoint): ditto.
381         (WebCore::TextControlInnerElement::attachInnerElement): Added.
382          This does all the separate steps of attaching a shadow node that used to be repeated in RenderTextControl::createSubtreeIfNeeded for each element.
383         (WebCore::TextControlInnerTextElement::createRenderer): Added.  Creates a RenderTextControlInnerBlock.
384         * rendering/TextControlInnerElements.h:
385
386 2008-08-28  Alexey Proskuryakov  <ap@webkit.org>
387
388         Reviewed by Maciej.
389
390         Elminate SQLiteAuthorizer class.
391
392         * WebCore.xcodeproj/project.pbxproj:
393         * WebCore.vcproj/WebCore.vcproj:
394         * GNUmakefile.am
395         Removed SQLiteAuthorizer.h.
396
397         * platform/sql/SQLiteAuthorizer.cpp:
398         * platform/sql/SQLiteAuthorizer.h: Removed.
399         * platform/sql/SQLiteDatabase.cpp:
400         (WebCore::SQLiteDatabase::authorizerFunction):
401         (WebCore::SQLiteDatabase::setAuthorizer):
402         * platform/sql/SQLiteDatabase.h:
403         * storage/DatabaseAuthorizer.h:
404         (WebCore::DatabaseAuthorizer::create):
405         (WebCore::DatabaseAuthorizer::createView):
406         (WebCore::DatabaseAuthorizer::createTempView):
407         (WebCore::DatabaseAuthorizer::dropView):
408         (WebCore::DatabaseAuthorizer::dropTempView):
409         (WebCore::DatabaseAuthorizer::allowSelect):
410         (WebCore::DatabaseAuthorizer::allowReindex):
411         Merge SQLiteAuthorizer and DatabaseAuthorizer, as keeping them separate serves no purpose.
412
413 2008-09-03  Dirk Schulze  <vbs85@gmx.de>
414
415         Reviewed by Mark Rowe.
416
417         WebKitGtk build fix.
418
419         * GNUmakefile.am:
420         * page/animation/AnimationController.h:
421
422 2008-09-02  Robert Blaut  <webkit@blaut.biz>
423
424         Reviewed by Geoff Garen.
425
426         Fix for <https://bugs.webkit.org/show_bug.cgi?id=16913>
427         Misplaced elements should not close DL lists.
428
429         Test: fast/invalid/test-case-tr-th-td-should-not-close-dl-list.html
430
431         * html/HTMLParser.cpp:
432         (WebCore::HTMLParser::handleError):
433
434 2008-09-02  Glenn Wilson  <wilsong@gmail.com>
435
436         Reviewed by Darin Adler.
437
438         Fix for <https://bugs.webkit.org/show_bug.cgi?id=15360>
439         Bug 15360: color:#{predefined colorName} is treated as colorName in Safari
440
441         We would inappropriately interpret and apply an invalid CSS "color" property
442         when the value is a predefined color preceded by a '#' symbol.  For example,
443         style="color:#gray;" would apply the color gray when it should not.
444
445         In the bison template, "hexcolor" was defined as both "HEX maybe_space" OR "IDENT maybe_space".
446         This caused identifiers not fitting the appropriate hex format but preceded by a '#' to be 
447         interpreted as a valid color (CSSPrimitiveValue::CSS_PARSER_HEXCOLOR), when it was really just
448         an ignorable token.
449
450         To correct this, "IDENT maybe_space" was removed from "hexcolor" and added under "term" as
451         '#' IDENT maybe_space, which is then processed as a CSSPrimitiveValue::CSS_STRING instead of
452         CSSPrimitiveValue::CSS_PARSER_HEXCOLOR.
453
454         Test: css1/color_and_background/invalid_color.html
455
456         * css/CSSGrammar.y:
457
458 2008-09-02  Mihnea Ovidenie  <mihnea@adobe.com>
459
460         Reviewed by Darin Adler.
461
462         Fix for https://bugs.webkit.org/show_bug.cgi?id=19964
463         Bug 19964: Divide by zero crash in RenderBox::calculateBackgroundSize with 0,0 bmp background image
464
465         Add a check to RenderBox::repaintLayerRectsForImage to make sure the current layer image can be rendered.
466
467         Test: css3/khtml-background-size-0x0-bmp.html
468
469         * rendering/RenderBox.cpp:
470         (WebCore::RenderBox::repaintLayerRectsForImage):
471
472 2008-09-02  Glenn Wilson  <wilsong@gmail.com>
473
474         Reviewed by Eric Seidel.
475
476         Fix https://bugs.webkit.org/show_bug.cgi?id=20397
477         Bug 20397: Invalid webkit-border-bottom-left-radius property causes crash
478
479         The function checkForOrphanedUnits() would change the length of a list whose size was
480         was already determined before the call to checkForOrphanedUnits was made.  Later in
481         the caller, the old size was being used for boundary management.
482
483         This has been fixed by moving the call to checkForOrphanedUnits() earlier in the
484         calling function, before the size of the list is determined.
485
486         Test: fast/css/orphaned_units_crash.html
487
488         * css/CSSParser.cpp:
489         (WebCore::CSSParser::parseValue):  Moved call to checkForOrphanedUnits() earlier in the function.
490
491 2008-09-02  Dirk Schulze  <vbs85@gmx.de>
492
493         Reviewed by Darin Adler.
494
495         Fallback on invalid fill or stroke styles in Canvas was
496         transparent black. Changed it to last valid style.
497
498         Canvas fillStyle() and strokeStyle() needs fallback
499         https://bugs.webkit.org/show_bug.cgi?id=20474
500
501         Tests: fast/canvas/canvas-invalid-fillstyle.html
502                fast/canvas/canvas-invalid-strokestyle.html
503
504         * html/CanvasStyle.cpp:
505         (WebCore::CanvasStyle::applyStrokeColor):
506         (WebCore::CanvasStyle::applyFillColor):
507
508 2008-09-02  Dirk Schulze  <vbs85@gmx.de>
509
510         Reviewed by Darin Adler.
511
512         Fix https://bugs.webkit.org/show_bug.cgi?id=20468
513         Updated drawImage() in canvas to match the current specification.
514
515         Test: fast/canvas/drawImage-with-negative-source-destination.html
516
517         * html/CanvasRenderingContext2D.cpp:
518         (WebCore::normalizeRect):
519         (WebCore::CanvasRenderingContext2D::drawImage):
520
521 2008-08-26  Mark Rowe  <mrowe@apple.com>
522
523         Reviewed by Darin Adler.
524
525         <rdar://problem/5768210> Switch back to the system version of SQLite
526
527         Use the system version of SQLite when it is new enough to provide the functionality
528         that WebCore requires.
529
530         * Configurations/Base.xcconfig:
531         * Configurations/DebugRelease.xcconfig:
532         * Configurations/WebCore.xcconfig:
533
534 2008-09-02  Dan Bernstein  <mitz@apple.com>
535
536         - build fix
537
538         * page/animation/AnimationBase.h:
539
540 2008-09-02  Chris Marrin  <cmarrin@apple.com>
541
542         Reviewed by Dave Hyatt.
543
544         AnimationController.cpp should be split into separate files
545         https://bugs.webkit.org/show_bug.cgi?id=20604
546         
547         Note: All makefiles, except WebCore.xcodeproj have been changed without testing, upon
548         recommendation of Dave Hyatt.
549
550         * GNUmakefile.am:
551         * WebCore.pro:
552         * WebCore.vcproj/WebCore.vcproj:
553         * WebCore.xcodeproj/project.pbxproj:
554         * WebCoreSources.bkl:
555             Build files.
556         
557         * page/AnimationController.cpp: Removed.
558         * page/AnimationController.h: Removed.
559         * page/animation: Added.
560         * page/animation/AnimationBase.cpp: Added.
561         * page/animation/AnimationBase.h: Added.
562         * page/animation/AnimationController.cpp: Copied from WebCore/page/AnimationController.cpp.
563         * page/animation/AnimationController.h: Copied from WebCore/page/AnimationController.h.
564         * page/animation/CompositeAnimation.cpp: Added.
565         * page/animation/CompositeAnimation.h: Added.
566         * page/animation/ImplicitAnimation.cpp: Added.
567         * page/animation/ImplicitAnimation.h: Added.
568         * page/animation/KeyframeAnimation.cpp: Added.
569         * page/animation/KeyframeAnimation.h: Added.
570
571 2008-09-02  Dan Bernstein  <mitz@apple.com>
572
573         - release build fix
574
575         * platform/graphics/cg/GraphicsContextCG.cpp:
576         (WebCore::calculateDrawingMode):
577
578 2008-09-02  Timothy Hatcher  <timothy@apple.com>
579
580         Make console functions log the correct resource URL and
581         line number for where the call originated.
582
583         https://bugs.webkit.org/show_bug.cgi?id=17234
584         <rdar://problem/5732837>
585
586         Reviewed by Kevin McCullough.
587
588         Test: manual-tests/inspector/console-call-line-numbers.html
589
590         * bindings/js/JSConsoleCustom.cpp:
591         (WebCore::JSConsole::count): Call the impl.
592         (WebCore::JSConsole::timeEnd): Ditto.
593         * manual-tests/inspector/console-call-line-numbers.html: Added.
594         * manual-tests/inspector/resources/script-console-calls.js: Added.
595         * page/Console.cpp:
596         (WebCore::retrieveLastCaller): Helper to get the URL and line.
597         (WebCore::Console::error): Call retrieveLastCaller to get the URL and
598         line number to pass to addMessageToConsole.
599         (WebCore::Console::info): Ditto.
600         (WebCore::Console::log): Ditto.
601         (WebCore::Console::assertCondition): Ditto.
602         (WebCore::Console::count): Ditto.
603         (WebCore::Console::timeEnd): Ditto.
604         (WebCore::Console::warn): Ditto.
605         * page/Console.h:
606         * page/Console.idl: Make count and timeEnd custom.
607
608 2008-09-02  Timothy Hatcher  <timothy@apple.com>
609
610         Removed IDL files from WebCore's framework resources.
611
612         * WebCore.xcodeproj/project.pbxproj:
613
614 2008-09-02  Dan Bernstein  <mitz@apple.com>
615
616         Reviewed by Dave Hyatt.
617
618         - <rdar://problem/5681647> pages at http://www.stendmarsofa.com/ are so slow to calculate style it seems like a hang
619
620         * html/HTMLParser.cpp:
621         (WebCore::HTMLParser::handleResidualStyleCloseTagAcrossBlocks): Added a
622         cap on the number of consecutive identical residual style tags to
623         reopen.
624         (WebCore::HTMLParser::popBlock): Ditto.
625
626 2008-09-02  Alexey Proskuryakov  <ap@webkit.org>
627
628         Reviewed by Adam Roben.
629
630         A little database quota management cleanup.
631
632         * storage/OriginQuotaManager.cpp:
633         (WebCore::OriginQuotaManager::OriginQuotaManager):
634         (WebCore::OriginQuotaManager::lock):
635         (WebCore::OriginQuotaManager::unlock):
636         (WebCore::OriginQuotaManager::trackOrigin):
637         (WebCore::OriginQuotaManager::tracksOrigin):
638         (WebCore::OriginQuotaManager::addDatabase):
639         (WebCore::OriginQuotaManager::removeDatabase):
640         (WebCore::OriginQuotaManager::removeOrigin):
641         (WebCore::OriginQuotaManager::markDatabase):
642         (WebCore::OriginQuotaManager::diskUsage):
643         * storage/OriginQuotaManager.h:
644         Changed to assert that a lock is taken more directly and reliably. Removed comments about
645         main/background threads, as this is likely to stop being true with synchronous Database calls
646         being made on worker threads.
647
648         * storage/OriginUsageRecord.cpp:
649         (WebCore::OriginUsageRecord::OriginUsageRecord):
650         (WebCore::OriginUsageRecord::addDatabase):
651         (WebCore::OriginUsageRecord::removeDatabase):
652         (WebCore::OriginUsageRecord::markDatabase):
653         (WebCore::OriginUsageRecord::diskUsage):
654         * storage/OriginUsageRecord.h:
655         (WebCore::OriginUsageRecord::DatabaseEntry::DatabaseEntry):
656         Don't use a magic value for unknown. It is totally unnecessary for DatabaseEntry, and
657         can be replaced with a single boolean for OriginUsageRecord.
658         Added assertions for string parameters being unshared.
659
660
661 2008-09-01  Adam Barth  <abarth@webkit.org>
662
663         Reviewed by Sam Weinig.
664
665         https://bugs.webkit.org/show_bug.cgi?id=19760
666
667         Make granting LoadLocalResources conditional on a policy.
668
669         * WebCore.base.exp:
670         * dom/Document.cpp:
671         (WebCore::Document::initSecurityContext):
672         * loader/FrameLoader.cpp:
673         (WebCore::FrameLoader::setLocalLoadPolicy):
674         (WebCore::FrameLoader::restrictAccessToLocal):
675         * loader/FrameLoader.h:
676         (WebCore::FrameLoader::):
677         * platform/SecurityOrigin.cpp:
678         (WebCore::SecurityOrigin::grantLoadLocalResources):
679         * platform/SecurityOrigin.h:
680
681 2008-09-01  Dean Jackson  <dino@apple.com>
682
683         Reviewed by Sam Weinig.
684
685         https://bugs.webkit.org/show_bug.cgi?id=20571
686         Make sure Window object can assign Animation/Transition event
687         listeners via attributes.
688
689         Also added a bunch of transition event tests, although
690         only transition-end-event-window is directly relevant to this patch.
691
692         (WebCore::JSDOMWindowBase::put):
693
694         Tests: transitions/transition-end-event-all-properties.html
695                transitions/transition-end-event-attributes.html
696                transitions/transition-end-event-container.html
697                transitions/transition-end-event-left.html
698                transitions/transition-end-event-multiple-01.html
699                transitions/transition-end-event-multiple-02.html
700                transitions/transition-end-event-multiple-03.html
701                transitions/transition-end-event-multiple-04.html
702                transitions/transition-end-event-nested.html
703                transitions/transition-end-event-transform.html
704                transitions/transition-end-event-window.html
705
706 2008-09-01  Dean Jackson  <dino@apple.com>
707
708         Reviewed by Sam Weinig
709
710         Code styling cleanup.
711
712         * bindings/js/JSDOMWindowBase.cpp:
713         (WebCore::JSDOMWindowBase::getValueProperty):
714         (WebCore::JSDOMWindowBase::put):
715
716 2008-09-01  Geoffrey Garen  <ggaren@apple.com>
717
718         Reviewed by Darin Adler.
719
720         First cut at inline caching for access to vanilla JavaScript properties.
721
722         Updated for JavaScriptCore changes. Mostly mechanical addition of StructureIDs
723         to WebCore classes, and PutPropertySlot& arguments to put functions.
724
725         (WebCore::JSCSSStyleDeclaration::customPut): Be sure to play nice with
726         inline caching for global properties, so global assignment can be optimized.
727
728         * ForwardingHeaders/kjs/StructureID.h: Added.
729         * bindings/js/JSDOMBinding.h:
730         (WebCore::DOMObject::DOMObject):
731         * bindings/js/JSDOMWindowBase.cpp:
732         (WebCore::JSDOMWindowBase::put):
733         * bindings/js/JSDOMWindowBase.h:
734         * bindings/js/JSDOMWindowCustom.h:
735         (WebCore::JSDOMWindow::customPut):
736         * bindings/js/JSDOMWindowShell.cpp:
737         (WebCore::JSDOMWindowShell::JSDOMWindowShell):
738         (WebCore::JSDOMWindowShell::put):
739         * bindings/js/JSDOMWindowShell.h:
740         * bindings/js/JSEventTargetBase.h:
741         (WebCore::JSEventTargetBase::put):
742         * bindings/js/JSEventTargetNode.h:
743         (WebCore::JSEventTargetNode::put):
744         * bindings/js/JSHTMLAppletElementCustom.cpp:
745         (WebCore::JSHTMLAppletElement::customPut):
746         * bindings/js/JSHTMLEmbedElementCustom.cpp:
747         (WebCore::JSHTMLEmbedElement::customPut):
748         * bindings/js/JSHTMLInputElementBase.cpp:
749         (WebCore::JSHTMLInputElementBase::put):
750         * bindings/js/JSHTMLInputElementBase.h:
751         * bindings/js/JSHTMLObjectElementCustom.cpp:
752         (WebCore::JSHTMLObjectElement::customPut):
753         * bindings/js/JSHistoryCustom.cpp:
754         (WebCore::JSHistory::customPut):
755         * bindings/js/JSInspectedObjectWrapper.cpp:
756         (WebCore::JSInspectedObjectWrapper::wrap):
757         (WebCore::JSInspectedObjectWrapper::JSInspectedObjectWrapper):
758         * bindings/js/JSInspectedObjectWrapper.h:
759         * bindings/js/JSInspectorCallbackWrapper.cpp:
760         (WebCore::JSInspectorCallbackWrapper::wrap):
761         (WebCore::JSInspectorCallbackWrapper::JSInspectorCallbackWrapper):
762         * bindings/js/JSInspectorCallbackWrapper.h:
763         * bindings/js/JSLocationCustom.cpp:
764         (WebCore::JSLocation::customPut):
765         * bindings/js/JSPluginElementFunctions.cpp:
766         (WebCore::runtimeObjectCustomPut):
767         * bindings/js/JSPluginElementFunctions.h:
768         * bindings/js/JSQuarantinedObjectWrapper.cpp:
769         (WebCore::JSQuarantinedObjectWrapper::JSQuarantinedObjectWrapper):
770         (WebCore::JSQuarantinedObjectWrapper::put):
771         * bindings/js/JSQuarantinedObjectWrapper.h:
772         * bindings/js/JSStorageCustom.cpp:
773         (WebCore::JSStorage::customPut):
774         * bindings/objc/WebScriptObject.mm:
775         (-[WebScriptObject setValue:forKey:]):
776         * bindings/scripts/CodeGeneratorJS.pm:
777         * bridge/NP_jsobject.cpp:
778         (_NPN_SetProperty):
779         * bridge/jni/jni_jsobject.mm:
780         (JavaJSObject::setMember):
781         * bridge/objc/objc_class.mm:
782         (KJS::Bindings::ObjcClass::fallbackObject):
783         * bridge/objc/objc_runtime.h:
784         * bridge/objc/objc_runtime.mm:
785         (ObjcFallbackObjectImp::ObjcFallbackObjectImp):
786         (ObjcFallbackObjectImp::put):
787         * bridge/runtime.cpp:
788         (KJS::Bindings::Instance::createRuntimeObject):
789         * bridge/runtime_array.cpp:
790         (RuntimeArray::put):
791         * bridge/runtime_array.h:
792         * bridge/runtime_object.cpp:
793         (RuntimeObjectImp::RuntimeObjectImp):
794         (RuntimeObjectImp::put):
795         * bridge/runtime_object.h:
796
797 2008-09-01  Dirk Schulze  <vbs85@gmx.de>
798
799         Reviewed by Eric Seidel.
800
801         Fixed border-radius for Cairo.
802
803         * platform/graphics/cairo/GraphicsContextCairo.cpp:
804         (WebCore::GraphicsContext::strokeArc):
805
806 2008-09-01  Dirk Schulze  <vbs85@gmx.de>
807
808         Reviewed by Eric Seidel.
809
810         Added canvas's globalAlpha to cairo.
811
812         * platform/graphics/GraphicsContext.h:
813         * platform/graphics/cairo/GraphicsContextCairo.cpp:
814         (WebCore::GraphicsContext::fillPath):
815         (WebCore::GraphicsContext::strokePath):
816         (WebCore::GraphicsContext::setAlpha):
817         (WebCore::GraphicsContext::getAlpha):
818         * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h:
819         (WebCore::GraphicsContextPlatformPrivate::GraphicsContextPlatformPrivate):
820         * platform/graphics/cairo/ImageCairo.cpp:
821         (WebCore::BitmapImage::draw):
822
823 2008-08-31  Simon Hausmann  <hausmann@webkit.org>
824
825         Unreviewed Qt build fix.
826
827         * WebCore.pro: Add TextControlInnerElements.cpp to SOURCES instead of
828         the .h file
829
830 2008-08-30  Darin Adler  <darin@apple.com>
831
832         Reviewed by Maciej.
833
834         - adopt some new JavaScriptCore functions where appropriate
835
836         * bindings/js/JSDOMWindowBase.cpp:
837         (WebCore::windowProtoFuncAToB): Adopted jsEmptyString.
838         (WebCore::windowProtoFuncBToA): Ditto.
839         * bindings/js/JSEventListener.cpp:
840         (WebCore::JSLazyEventListener::eventParameterName): Adopted
841         jsNontrivialString.
842         * bindings/js/JSSVGLazyEventListener.cpp:
843         (WebCore::JSSVGLazyEventListener::eventParameterName): Ditto.
844
845 2008-08-29  Brady Eidson  <beidson@apple.com>
846
847         Reviewed by Anders' rubberstamp
848
849         Style cleanup to match MediaTokenizer::writeRawData()
850
851         * loader/PluginDocument.cpp:
852         (WebCore::PluginTokenizer::writeRawData):
853
854 2008-08-29  Brady Eidson  <beidson@apple.com>
855
856         Reviewed by Anders
857
858         Fix regression I introducted in 35946
859         Already covered by media/video-click-dlbclick-standalone.html
860
861         * loader/MediaDocument.cpp:
862         (WebCore::MediaTokenizer::createDocumentStructure): Don't cancel the load here - too early!
863         (WebCore::MediaTokenizer::writeRawData): Call finish() here so onload() can be called.  Also add
864           an ASSERT signifying that this method should only be called once, to more closely follow the
865           PluginDocument case.
866
867 2008-08-29  Beth Dakin  <bdakin@apple.com>
868
869         Reviewed by Sam Weinig.
870
871         Fix for <rdar://problem/6181588>
872
873         This patch makes hit testing take into account the new concept of a 
874         disconnected frame, in which some of the content may not be 
875         visible. The current hit testing mechanism starts at a target frame 
876         and drills down for a HitTestResult. In some cases, drilling down 
877         will find a non-visible result. When this happens, we need to try 
878         again, starting at a higher level -- namely, starting at the main 
879         frame.
880
881         * editing/Editor.cpp:
882         (WebCore::Editor::insideVisibleArea): New function that tests if a 
883         point is inside the visible area for a disconnected frame.
884         * editing/Editor.h:
885         * page/EventHandler.cpp:
886         (WebCore::EventHandler::hitTestResultAtPoint):
887
888 2008-08-29  Adele Peterson  <adele@apple.com>
889
890         Reviewed by Adam Roben. 
891
892         Rename HTMLTextFieldInnerElement.h/.cpp to TextControlInnerElements.h/.cpp
893
894         * GNUmakefile.am:
895         * WebCore.pro:
896         * WebCore.vcproj/WebCore.vcproj:
897         * WebCore.xcodeproj/project.pbxproj:
898         * WebCoreSources.bkl:
899         * html/HTMLTextFieldInnerElement.cpp: Removed.
900         * html/HTMLTextFieldInnerElement.h: Removed.
901         * rendering/RenderTextControl.cpp:
902         (WebCore::RenderTextControl::createSubtreeIfNeeded):
903         * rendering/RenderTextControl.h:
904         * rendering/TextControlInnerElements.cpp: Copied from html/HTMLTextFieldInnerElement.cpp.
905         (WebCore::TextControlInnerElement::TextControlInnerElement):
906         (WebCore::TextControlInnerTextElement::TextControlInnerTextElement):
907         (WebCore::TextControlInnerTextElement::defaultEventHandler):
908         (WebCore::SearchFieldResultsButtonElement::SearchFieldResultsButtonElement):
909         (WebCore::SearchFieldResultsButtonElement::defaultEventHandler):
910         (WebCore::SearchFieldCancelButtonElement::SearchFieldCancelButtonElement):
911         (WebCore::SearchFieldCancelButtonElement::defaultEventHandler):
912         * rendering/TextControlInnerElements.h: Copied from html/HTMLTextFieldInnerElement.h.
913
914 2008-08-29  Eric Seidel  <eric@webkit.org>
915
916         Rubber-stamped by aroben.
917
918         Add GraphicsContext.h include to GraphcisContextPrivate.h
919
920         GraphicsContextPrivate uses StrokeStyle which is defined
921         in GraphicsContext.h but it doesn't include that header.
922         CoreGraphics build doesn't fail here due to the order
923         it happens to include files.
924
925         * platform/graphics/GraphicsContextPrivate.h:
926
927 2008-08-29  Eric Seidel  <eric@webkit.org>
928
929         Reviewed by hyatt.
930
931         Fix GeneratedImage to respect Image's refcounting
932         Fixing potential crashers (future if not current)
933         https://bugs.webkit.org/show_bug.cgi?id=20567
934         
935         I don't know if it's possible to make the current code
936         crash, thus I've not made a test.
937
938         * css/CSSGradientValue.cpp:
939         (WebCore::CSSGradientValue::image):
940         * css/CSSImageGeneratorValue.cpp:
941         (WebCore::CSSImageGeneratorValue::removeClient):
942         (WebCore::CSSImageGeneratorValue::getImage):
943         * css/CSSImageGeneratorValue.h:
944         * platform/graphics/GeneratedImage.h:
945         (WebCore::GeneratedImage::GeneratedImage):
946         * rendering/style/RenderStyle.cpp:
947         (WebCore::RenderStyle::setContent):
948         * rendering/style/RenderStyle.h:
949
950 2008-08-29  Eric Carlson  <eric.carlson@apple.com>
951
952         Reviewed by Adele.
953
954         Fix for <rdar://problem/6093767>
955         https://bugs.webkit.org/show_bug.cgi?id=20526
956
957         Don't allow video to render until unsupported track types have been disabled.
958
959         * platform/graphics/win/QTMovieWin.cpp:
960         (QTMovieWinPrivate::task):
961         (QTMovieWinPrivate::drawingComplete):
962         (QTMovieWinPrivate::clearGWorld):
963
964 2008-08-29  Eric Carlson  <eric.carlson@apple.com>
965
966         Reviewed by Adele.
967
968         Fix for https://bugs.webkit.org/show_bug.cgi?id=20525
969         <rdar://problem/6169301>
970         
971         Return the size of the movie data instead of 1000.
972         
973         Test: media/progress-event-total.html
974
975         * platform/graphics/win/QTMovieWin.cpp:
976         (QTMovieWin::dataSize):
977
978 2008-08-29  Holger Hans Peter Freyther  <zecke@selfish.org>
979
980         Reviewed by Eric Seidel.
981
982         [janitor/qt] Start replacing port specific getters with the generic native getter
983         To get the native presentation of an image we currently have platform
984         specific #ifdef's and a generic getter using NativeImagePtr. This patch
985         extends this to the ImageBuffer and updates the Qt platform to get rid
986         of the special #ifdefs.
987
988         https://bugs.webkit.org/attachment.cgi?id=22861
989
990         * platform/graphics/BitmapImage.h:
991         * platform/graphics/Image.h:
992         * platform/graphics/qt/ImageQt.cpp:
993         * platform/graphics/qt/StillImageQt.cpp:
994         * platform/graphics/qt/StillImageQt.h:
995         * platform/qt/ClipboardQt.cpp:
996         (WebCore::ClipboardQt::createDragImage):
997         (WebCore::ClipboardQt::declareAndWriteDragImage):
998         * platform/qt/CursorQt.cpp:
999         * platform/qt/PasteboardQt.cpp:
1000         (WebCore::Pasteboard::writeImage):
1001
1002 2008-08-29  Holger Hans Peter Freyther  <zecke@selfish.org>
1003
1004         Reviewed by Simon.
1005
1006         [svg/qt] Stop crashing... when no RenderPath/RenderObject is given...
1007
1008         * svg/graphics/qt/SVGPaintServerQt.cpp:
1009         (WebCore::SVGPaintServer::renderPath):
1010         * svg/graphics/qt/SVGPaintServerSolidQt.cpp:
1011         (WebCore::SVGPaintServerSolid::setup):
1012
1013 2008-08-29  Holger Hans Peter Freyther  <zecke@selfish.org>
1014
1015         Reviewed by Simon.
1016
1017         [network/qt] Implement defering of loading ResourceHandle's
1018         This is needed otherwise we end in an ASSERT in the MainResourceLoader. The
1019         implementation is simply not forwarding anything to the
1020         ResourceHandleClient until we are allowed to. This might lead to a deadlock
1021         in Qt as we do not empty the QNetworkReply input buffer and wait until we
1022         are allowed to read. If that happens we are forced to buffer the data
1023         within QNetworkReplyHandler, for now this is not done.
1024
1025         Manual test:
1026         - Open http://acid3.acidtests.org
1027         - Wait for the test to complete
1028         - Click on the Reference Rendering link
1029         - Be fast and see the results of acid3
1030         => assert
1031
1032         * platform/network/qt/QNetworkReplyHandler.cpp:
1033         (WebCore::QNetworkReplyHandler::QNetworkReplyHandler):
1034         (WebCore::QNetworkReplyHandler::setLoadMode):
1035         (WebCore::QNetworkReplyHandler::finish):
1036         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
1037         (WebCore::QNetworkReplyHandler::forwardData):
1038         (WebCore::QNetworkReplyHandler::start):
1039         (WebCore::QNetworkReplyHandler::resetState):
1040         (WebCore::QNetworkReplyHandler::sendQueuedItems):
1041         * platform/network/qt/QNetworkReplyHandler.h:
1042         (WebCore::QNetworkReplyHandler::):
1043         * platform/network/qt/ResourceHandleQt.cpp:
1044         (WebCore::ResourceHandle::start):
1045         (WebCore::ResourceHandle::loadResourceSynchronously):
1046         (WebCore::ResourceHandle::setDefersLoading):
1047
1048 2008-08-29  Simon Hausmann  <hausmann@webkit.org>
1049
1050         Reviewed by Holger.
1051
1052         Don't crash when drawing patterns with the HTML canvas. Patterns
1053         remain unimplemented but at least they don't crash anymore. This is
1054         done by changing the PlatformPatternPtr to be a brush for the Qt
1055         platform.
1056
1057         * platform/graphics/Pattern.h:
1058         * platform/graphics/qt/GraphicsContextQt.cpp:
1059         (WebCore::GraphicsContext::fillPath):
1060         (WebCore::GraphicsContext::strokePath):
1061         (WebCore::GraphicsContext::fillRect):
1062         * platform/graphics/qt/PatternQt.cpp:
1063         (WebCore::Pattern::createPlatformPattern):
1064
1065 2008-08-29  Simon Hausmann  <hausmann@webkit.org>
1066
1067         Fix the Qt build, fontSelector() is not used by the Qt port yet
1068         and we just return 0 in Font::fontSelector().
1069
1070         * platform/graphics/Font.h:
1071
1072 2008-08-28  Alp Toker  <alp@nuanti.com>
1073
1074         GTK+ dist/build fix. List newly added header files.
1075
1076         * GNUmakefile.am:
1077
1078 2008-08-28  Simon Fraser  <simon.fraser@apple.com>
1079
1080         Reviewed by Dave Hyatt
1081
1082         Various WebKitCSSTransformValue-related fixes
1083         https://bugs.webkit.org/show_bug.cgi?id=20562
1084
1085         Test: css3/transform-value-types.html
1086
1087         * bindings/js/JSCSSValueCustom.cpp:
1088         (WebCore::toJS):
1089         * css/CSSValue.h:
1090         * css/WebKitCSSTransformValue.cpp:
1091         (WebCore::WebKitCSSTransformValue::cssText):
1092         * css/WebKitCSSTransformValue.h:
1093         (WebCore::WebKitCSSTransformValue::):
1094         * css/WebKitCSSTransformValue.idl:
1095
1096 2008-08-28  Dan Bernstein  <mitz@apple.com>
1097
1098         Reviewed by Steve Falkenburg.
1099
1100         - do not let the "last chance" WM_TIMER trigger WebCore timers when they should be deferred
1101
1102         * platform/win/SharedTimerWin.cpp:
1103         (WebCore::TimerWindowWndProc):
1104
1105 2008-08-28  David Hyatt  <hyatt@apple.com>
1106
1107         RenderStyle cleanup.
1108
1109         Break out StyleImage, StyleGeneratedImage, StyleCachedImage and NinePieceImage into separate files.
1110
1111         Reviewed by Adam
1112
1113         * css/CSSImageGeneratorValue.cpp:
1114         * css/CSSImageValue.cpp:
1115         * css/CSSStyleSelector.cpp:
1116         * rendering/RenderImageGeneratedContent.cpp:
1117         * rendering/style/NinePieceImage.cpp: Added.
1118         * rendering/style/NinePieceImage.h: Added.
1119         * rendering/style/RenderStyle.cpp:
1120         (WebCore::FillLayer::operator==):
1121         (WebCore::FillLayer::containsImage):
1122         (WebCore::StyleInheritedData::operator==):
1123         (WebCore::RenderStyle::contentDataEquivalent):
1124         * rendering/style/RenderStyle.h:
1125         * rendering/style/StyleCachedImage.cpp: Added.
1126         * rendering/style/StyleCachedImage.h: Added.
1127         * rendering/style/StyleGeneratedImage.cpp: Added.
1128         * rendering/style/StyleGeneratedImage.h: Added.
1129         * rendering/style/StyleImage.h: Added.
1130
1131 2008-08-28  Simon Fraser  <simon.fraser@apple.com>
1132
1133         Reviewed by Dave Hyatt
1134
1135         Make all the 'isFoo()' methods on CSSValue const,
1136         and fix the subclasses.
1137         
1138         https://bugs.webkit.org/show_bug.cgi?id=20561
1139         
1140         * css/CSSTimingFunctionValue.h:
1141         * css/CSSValue.h:
1142         (WebCore::CSSValue::isFontValue):
1143         (WebCore::CSSValue::isImageGeneratorValue):
1144         (WebCore::CSSValue::isImageValue):
1145         (WebCore::CSSValue::isImplicitInitialValue):
1146         * css/CSSValueList.h:
1147         * css/FontValue.h:
1148
1149 2008-08-28  David Hyatt  <hyatt@apple.com>
1150
1151         The great RenderStyle cleanup begins!
1152
1153         Move LengthBox and LengthSize out of RenderStyle and into Length.
1154
1155         Reviewed by Adam
1156
1157         * rendering/Length.h:
1158         (WebCore::):
1159         (WebCore::Length::Length):
1160         (WebCore::Length::operator==):
1161         (WebCore::Length::operator!=):
1162         (WebCore::Length::value):
1163         (WebCore::Length::rawValue):
1164         (WebCore::Length::percent):
1165         (WebCore::Length::type):
1166         (WebCore::Length::quirk):
1167         (WebCore::Length::setValue):
1168         (WebCore::Length::setRawValue):
1169         (WebCore::Length::calcValue):
1170         (WebCore::Length::calcMinValue):
1171         (WebCore::Length::calcFloatValue):
1172         (WebCore::Length::isUndefined):
1173         (WebCore::Length::isZero):
1174         (WebCore::Length::isPositive):
1175         (WebCore::Length::isNegative):
1176         (WebCore::Length::isAuto):
1177         (WebCore::Length::isRelative):
1178         (WebCore::Length::isPercent):
1179         (WebCore::Length::isFixed):
1180         (WebCore::Length::isStatic):
1181         (WebCore::Length::isIntrinsicOrAuto):
1182         (WebCore::Length::blend):
1183         (WebCore::LengthBox::LengthBox):
1184         (WebCore::LengthBox::operator=):
1185         (WebCore::LengthBox::operator==):
1186         (WebCore::LengthBox::operator!=):
1187         (WebCore::LengthBox::nonZero):
1188         (WebCore::LengthSize::LengthSize):
1189         * rendering/style/RenderStyle.h:
1190
1191 2008-08-28  David Hyatt  <hyatt@apple.com>
1192
1193         Reviewed by Darin
1194
1195         https://bugs.webkit.org/show_bug.cgi?id=18091
1196
1197         font-size should be animatable using -webkit-transition.
1198
1199         * page/AnimationController.cpp:
1200         (WebCore::AnimationControllerPrivate::ensurePropertyMap):
1201         * rendering/style/RenderStyle.h:
1202         (WebCore::RenderStyle::setFontSize):
1203
1204 2008-08-28  Brad Garcia  <bgarcia@google.com>
1205
1206         Reviewed by Dan Bernstein.
1207
1208         https://bugs.webkit.org/show_bug.cgi?id=20549
1209         Correctly determine when cursor is over a resizable border within
1210         a nested frameset.
1211
1212         * rendering/RenderFrameSet.cpp:
1213         (WebCore::RenderFrameSet::canResizeRow):
1214         (WebCore::RenderFrameSet::canResizeColumn):
1215
1216 2008-08-28  Simon Fraser  <simon.fraser@apple.com>
1217
1218         Reviewed by Eric Seidel
1219
1220         Add RuleTypes to CSSRule.idl for keyframes and keyframe rules.
1221         https://bugs.webkit.org/show_bug.cgi?id=20552
1222
1223         Test: animations/animation-css-rule-types.html
1224
1225         * css/CSSRule.idl:
1226
1227 2008-08-28  Anders Carlsson  <andersca@apple.com>
1228
1229         Reviewed by Kevin and Darin.
1230
1231         <rdar://problem/6182541>
1232         https://bugs.webkit.org/show_bug.cgi?id=20202
1233         Missing http status line from the http headers.
1234         
1235         Add a status line to the header string.
1236         
1237         * plugins/PluginStream.cpp:
1238         (WebCore::PluginStream::startStream):
1239
1240 2008-08-28  Holger Hans Peter Freyther  <zecke@selfish.org>
1241
1242         Rubber-stamped by Darin Adler.
1243
1244         https://bugs.webkit.org/show_bug.cgi?id=17261
1245
1246         Make it possible to theme the default Url icon and enable this for
1247         the Qt port. To have a minimal usage of #ifdef in the code the setting
1248         of the icon was moved to a new method which comes in two flavors.
1249
1250         * loader/icon/IconDatabase.cpp:
1251         (WebCore::loadDefaultIconRecord): Load or set the default icon
1252         (WebCore::IconDatabase::defaultIcon):
1253
1254 2008-08-28  Holger Hans Peter Freyther <zecke@selfish.org>
1255
1256         Unreviewed compile fix
1257
1258         * platform/graphics/qt/GraphicsContextQt.cpp: Remove redefinitions
1259
1260 2008-08-28  Adam Roben  <aroben@apple.com>
1261
1262         Windows (and others?) build fix
1263
1264         * page/Chrome.cpp: Added a missing #include.
1265         (WebCore::PageGroupLoadDeferrer::PageGroupLoadDeferrer): Fixed typo.
1266
1267 2008-08-27  Eric Seidel  <eric@webkit.org>
1268
1269         Reviewed by Oliver Hunt.
1270
1271         Qt and Cairo support from krit (and blind stab @ wx compile support)
1272         https://bugs.webkit.org/show_bug.cgi?id=20373
1273
1274         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1275         (WebCore::GraphicsContext::fillPath):
1276         (WebCore::GraphicsContext::strokePath):
1277         (WebCore::GraphicsContext::drawPath):
1278         (WebCore::GraphicsContext::fillRect):
1279         (WebCore::GraphicsContext::setPlatformFillColor):
1280         (WebCore::GraphicsContext::setPlatformStrokeColor):
1281         (WebCore::GraphicsContext::setPlatformStrokeStyle):
1282         (WebCore::GraphicsContext::strokeRect):
1283         (WebCore::GraphicsContext::setImageInterpolationQuality):
1284         (WebCore::GraphicsContext::imageInterpolationQuality):
1285         (WebCore::GraphicsContext::setPlatformFillPattern):
1286         (WebCore::GraphicsContext::setPlatformStrokePattern):
1287         (WebCore::GraphicsContext::setPlatformFillGradient):
1288         (WebCore::GraphicsContext::setPlatformStrokeGradient):
1289         * platform/graphics/qt/GraphicsContextQt.cpp:
1290         (WebCore::GraphicsContext::fillPath):
1291         (WebCore::GraphicsContext::strokePath):
1292         (WebCore::GraphicsContext::fillRect):
1293         (WebCore::GraphicsContext::strokeRect):
1294         (WebCore::GraphicsContext::clipToImageBuffer):
1295         (WebCore::GraphicsContext::setPlatformFillPattern):
1296         (WebCore::GraphicsContext::setPlatformStrokePattern):
1297         (WebCore::GraphicsContext::setPlatformFillGradient):
1298         (WebCore::GraphicsContext::setPlatformStrokeGradient):
1299         (WebCore::GraphicsContext::setImageInterpolationQuality):
1300         (WebCore::GraphicsContext::imageInterpolationQuality):
1301         * platform/graphics/wx/GraphicsContextWx.cpp:
1302         (WebCore::GraphicsContext::clipToImageBuffer):
1303         (WebCore::GraphicsContext::setImageInterpolationQuality):
1304         (WebCore::GraphicsContext::imageInterpolationQuality):
1305         (WebCore::GraphicsContext::fillPath):
1306         (WebCore::GraphicsContext::strokePath):
1307         (WebCore::GraphicsContext::drawPath):
1308         (WebCore::GraphicsContext::fillRect):
1309         (WebCore::GraphicsContext::setPlatformFillPattern):
1310         (WebCore::GraphicsContext::setPlatformStrokePattern):
1311         (WebCore::GraphicsContext::setPlatformFillGradient):
1312
1313 2008-08-27  Eric Seidel  <eric@webkit.org>
1314
1315         Reviewed by Oliver Hunt.
1316
1317         Add stroke/fill Gradient and Pattern support to GraphicsContext and update <canvas> to use it.
1318         https://bugs.webkit.org/show_bug.cgi?id=20373
1319
1320         Changed pattern() to canvasPattern() on CanvasStyle to match canvasGradient()
1321         
1322         Made Generator (aka Gradient) RefCounted so that GraphicsContext didn't
1323         have to store large Gradient objects in the GraphicsContextState
1324         
1325         Made Pattern RefCounted for the same reason.
1326         
1327         Many updates to GraphicsContext to support easier drawing with
1328         Patterns and Gradients.
1329
1330         * WebCore.xcodeproj/project.pbxproj: Add pre-existing GraphicsContextPrivate.h
1331         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
1332         (WebCore::toJS):
1333         * css/CSSGradientValue.cpp:
1334         (WebCore::CSSGradientValue::createGradient):
1335         * css/CSSGradientValue.h:
1336         * html/CanvasGradient.cpp:
1337         (WebCore::CanvasGradient::CanvasGradient):
1338         * html/CanvasGradient.h:
1339         (WebCore::CanvasGradient::gradient):
1340         (WebCore::CanvasGradient::addColorStop):
1341         (WebCore::CanvasGradient::getColor):
1342         * html/CanvasPattern.cpp:
1343         * html/CanvasPattern.h:
1344         (WebCore::CanvasPattern::pattern):
1345         (WebCore::CanvasPattern::originClean):
1346         * html/CanvasRenderingContext2D.cpp:
1347         (WebCore::CanvasRenderingContext2D::State::State):
1348         (WebCore::CanvasRenderingContext2D::setStrokeStyle):
1349         (WebCore::CanvasRenderingContext2D::setFillStyle):
1350         (WebCore::CanvasRenderingContext2D::fill):
1351         (WebCore::CanvasRenderingContext2D::stroke):
1352         (WebCore::CanvasRenderingContext2D::fillRect):
1353         (WebCore::CanvasRenderingContext2D::strokeRect):
1354         * html/CanvasRenderingContext2D.h:
1355         * html/CanvasStyle.cpp:
1356         (WebCore::CanvasStyle::applyStrokeColor):
1357         (WebCore::CanvasStyle::applyFillColor):
1358         * html/CanvasStyle.h:
1359         * platform/graphics/GeneratedImage.h:
1360         (WebCore::GeneratedImage::GeneratedImage):
1361         * platform/graphics/Generator.h:
1362         * platform/graphics/Gradient.h:
1363         (WebCore::Gradient::create):
1364         * platform/graphics/GraphicsContext.cpp:
1365         (WebCore::GraphicsContext::fillRule):
1366         (WebCore::GraphicsContext::setFillRule):
1367         (WebCore::GraphicsContext::setStrokePattern):
1368         (WebCore::GraphicsContext::setFillPattern):
1369         (WebCore::GraphicsContext::setStrokeGradient):
1370         (WebCore::GraphicsContext::setFillGradient):
1371         * platform/graphics/GraphicsContext.h:
1372         * platform/graphics/GraphicsContextPrivate.h:
1373         (WebCore::):
1374         (WebCore::GraphicsContextState::GraphicsContextState):
1375         * platform/graphics/GraphicsTypes.h:
1376         * platform/graphics/Path.h:
1377         * platform/graphics/Pattern.h:
1378         (WebCore::Pattern::create):
1379         (WebCore::Pattern::tileImage):
1380         * platform/graphics/cg/GraphicsContextCG.cpp:
1381         (WebCore::GraphicsContext::drawRect):
1382         (WebCore::GraphicsContext::drawEllipse):
1383         (WebCore::GraphicsContext::drawConvexPolygon):
1384         (WebCore::calculateDrawingMode):
1385         (WebCore::GraphicsContext::drawPath):
1386         (WebCore::fillPathWithFillRule):
1387         (WebCore::GraphicsContext::fillPath):
1388         (WebCore::GraphicsContext::strokePath):
1389         (WebCore::GraphicsContext::fillRect):
1390         (WebCore::GraphicsContext::fillRoundedRect):
1391         (WebCore::GraphicsContext::setPlatformStrokePattern):
1392         (WebCore::GraphicsContext::setPlatformFillPattern):
1393         (WebCore::GraphicsContext::setPlatformStrokeGradient):
1394         (WebCore::GraphicsContext::setPlatformFillGradient):
1395
1396 2008-08-20  Eric Seidel  <eric@webkit.org>
1397
1398         Reviewed by Darin and Alexey.
1399
1400         Close a leak of PausedTimeouts if the JavaScriptDebugServer was destroyed
1401         with timeouts paused.
1402         https://bugs.webkit.org/show_bug.cgi?id=20469
1403         
1404         I attempted to clean up the memory management of PausedTimeouts, I'm not
1405         sure the solution I came up with is "cleaner", but it's in some ways
1406         "safer", since it no longer uses raw pointers and manual new/delete.
1407         
1408         This also now prevents CachedPage from needlessly creating Window
1409         objects when caching pages which didn't already have one. :)
1410         
1411         I also made Chrome.cpp no longer depend on the JavaScript bindings
1412         (aka JSDOMWindowBase.h), since there was no real reason for it to.
1413
1414         * bindings/js/JSDOMWindowBase.cpp:
1415         (WebCore::JSDOMWindowBase::pauseTimeouts):
1416         (WebCore::JSDOMWindowBase::resumeTimeouts):
1417         * bindings/js/JSDOMWindowBase.h:
1418         * bindings/js/ScriptController.cpp:
1419         (WebCore::ScriptController::pauseTimeouts):
1420         (WebCore::ScriptController::resumeTimeouts):
1421         * bindings/js/ScriptController.h:
1422         * history/CachedPage.cpp:
1423         (WebCore::CachedPage::CachedPage):
1424         (WebCore::CachedPage::restore):
1425         * page/Chrome.cpp:
1426         (WebCore::PageGroupLoadDeferrer::PageGroupLoadDeferrer):
1427         (WebCore::PageGroupLoadDeferrer::~PageGroupLoadDeferrer):
1428         * page/JavaScriptDebugServer.cpp:
1429         (WebCore::JavaScriptDebugServer::~JavaScriptDebugServer):
1430         (WebCore::JavaScriptDebugServer::setJavaScriptPaused):
1431
1432 2008-08-27  Holger Hans Peter Freyther <zecke@selfish.org>
1433
1434         Unreviewed compile fix
1435
1436         Add the stub for the Qt port.
1437
1438         * WebCore.pro:
1439         * page/qt/AccessibilityObjectQt.cpp: Added.
1440         (WebCore::AccessibilityObject::accessibilityIgnoreAttachment):
1441
1442 2008-08-27  Alp Toker  <alp@nuanti.com>
1443
1444         Reviewed by Eric.
1445
1446         https://bugs.webkit.org/show_bug.cgi?id=20551
1447         [GTK] search popup crash
1448
1449         * platform/gtk/SearchPopupMenuGtk.cpp:
1450         (WebCore::SearchPopupMenu::enabled):
1451         Fix a search popup crasher by disabling the history popup since we
1452         don't support this feature yet in the GTK+ port.
1453
1454 2008-08-27  Alp Toker  <alp@nuanti.com>
1455
1456         Reviewed by Eric.
1457
1458         https://bugs.webkit.org/show_bug.cgi?id=20551
1459         [GTK] curl crashers
1460
1461         * platform/network/curl/ResourceHandleManager.cpp:
1462         (WebCore::ResourceHandleManager::startScheduledJobs):
1463         Remove the resource handle from the pending list before starting the
1464         job, not afterwards. Fixes crashers in the test suite.
1465
1466         Test: fast/dom/clientWidthAfterDocumentIsRemoved.html
1467         Test: fast/encoding/char-encoding.html
1468
1469 2008-08-27  Dirk Schulze  <vbs85@gmx.de>
1470
1471         Reviewed by eseidel.
1472
1473         Fix canvas drawImage to support composite operations.
1474         Composite had no effect on canvas elements like these:
1475         http://philip.html5.org/tests/canvas/suite/tests/index.2d.composite.canvas.html
1476
1477         [CAIRO] Canvas composite don't work on canvas-elements.
1478         https://bugs.webkit.org/show_bug.cgi?id=20548
1479
1480         * html/CanvasRenderingContext2D.cpp:
1481         (WebCore::CanvasRenderingContext2D::drawImage): pass the current composite operator to the drawImage call
1482
1483 2008-08-27  Mario Bensi  <mbensi@pleyo.com>
1484
1485         Reviewed by Eric Seidel.
1486         
1487         Fix the data content of an image with a base64.
1488
1489         * platform/network/curl/ResourceHandleManager.cpp:
1490         (WebCore::parseDataUrl): Remove the String and use only the data
1491         Vector because the data.latin1().data() convert the data content and
1492         the image test ( https://bugs.webkit.org/attachment.cgi?id=21726 ) is
1493         not drawn correctly.
1494
1495 2008-08-27  Antti Koivisto  <antti@apple.com>
1496
1497         Reviewed by Eric Seidel.
1498
1499         Crash after OK in dialog box and reloading page in secure mode
1500         https://bugs.webkit.org/show_bug.cgi?id=20493
1501         
1502         The new run loop spawned by a modal dialog causes a timer in the loader to run 
1503         synchronously inside didFinishLoading() deleting "this" object.
1504         
1505         Defer all WebCore timers when a modal dialog is up. They are not
1506         safe to execute.
1507
1508         * page/Chrome.cpp:
1509         (WebCore::PageGroupLoadDeferrer::PageGroupLoadDeferrer):
1510         (WebCore::PageGroupLoadDeferrer::~PageGroupLoadDeferrer):
1511
1512 2008-08-27  Chris Marrin  <cmarrin@apple.com>
1513
1514         Reviewed by Dave Hyatt
1515
1516         Memory leaks when animating transforms
1517         https://bugs.webkit.org/show_bug.cgi?id=20532
1518
1519         * rendering/style/RenderStyle.cpp:
1520         (WebCore::ScaleTransformOperation::blend):
1521         (WebCore::RotateTransformOperation::blend):
1522         (WebCore::SkewTransformOperation::blend):
1523         (WebCore::TranslateTransformOperation::blend):
1524         (WebCore::MatrixTransformOperation::blend):
1525         * rendering/style/RenderStyle.h:
1526
1527 2008-08-27  Timothy Hatcher  <timothy@apple.com>
1528
1529         Add support for support for -webkit-appearance: default-button on the Mac platform.
1530
1531         <rdar://problem/6173530>
1532
1533         Reviewed by Dave Hyatt.
1534
1535         * WebCore.base.exp: Export new symbols.
1536         * platform/mac/WebCoreSystemInterface.h: Add wkAdvanceDefaultButtonPulseAnimation.
1537         * platform/mac/WebCoreSystemInterface.mm: Ditto.
1538         * rendering/RenderButton.cpp:
1539         (WebCore::RenderButton::RenderButton): Remove #if PLATFORM(WIN).
1540         (WebCore::RenderButton::setStyle): Ditto.
1541         * rendering/RenderButton.h: Ditto.
1542         * rendering/RenderThemeMac.mm:
1543         (WebCore::RenderThemeMac::adjustRepaintRect): Add a case for DefaultButtonAppearance.
1544         (WebCore::RenderThemeMac::setButtonCellState): Set the key equivalent to the return
1545         key if the button is default, otherwise reset the key equivalent.
1546         (WebCore::RenderThemeMac::paintButton): If the button is default call setDefaultButtonCell:
1547         on the window, then wkAdvanceDefaultButtonPulseAnimation before painting. Restore
1548         the window's previous default button cell when finished.
1549
1550 2008-08-26  David Hyatt  <hyatt@apple.com>
1551
1552         First cut at making form controls on OS X respect full page zoom.  There are lots of bugs.
1553
1554         Reviewed by weinig
1555
1556         Added fast/forms/zoomed-controls.html
1557
1558         * css/CSSStyleSelector.cpp:
1559         (WebCore::addIntrinsicMargins):
1560         * rendering/RenderSlider.cpp:
1561         (WebCore::RenderSlider::calcPrefWidths):
1562         * rendering/RenderThemeMac.h:
1563         * rendering/RenderThemeMac.mm:
1564         (WebCore::RenderThemeMac::adjustRepaintRect):
1565         (WebCore::RenderThemeMac::inflateRect):
1566         (WebCore::RenderThemeMac::baselinePosition):
1567         (WebCore::RenderThemeMac::setControlSize):
1568         (WebCore::RenderThemeMac::sizeForFont):
1569         (WebCore::RenderThemeMac::sizeForSystemFont):
1570         (WebCore::RenderThemeMac::setFontFromControlSize):
1571         (WebCore::RenderThemeMac::paintCheckbox):
1572         (WebCore::RenderThemeMac::setCheckboxCellState):
1573         (WebCore::RenderThemeMac::paintRadio):
1574         (WebCore::RenderThemeMac::setRadioCellState):
1575         (WebCore::RenderThemeMac::setButtonPaddingFromControlSize):
1576         (WebCore::RenderThemeMac::adjustButtonStyle):
1577         (WebCore::RenderThemeMac::setButtonCellState):
1578         (WebCore::RenderThemeMac::paintButton):
1579         (WebCore::RenderThemeMac::paintMenuList):
1580         (WebCore::RenderThemeMac::paintMenuListButton):
1581         (WebCore::RenderThemeMac::popupInternalPaddingLeft):
1582         (WebCore::RenderThemeMac::popupInternalPaddingRight):
1583         (WebCore::RenderThemeMac::popupInternalPaddingTop):
1584         (WebCore::RenderThemeMac::popupInternalPaddingBottom):
1585         (WebCore::RenderThemeMac::setPopupButtonCellState):
1586         (WebCore::RenderThemeMac::paintSliderTrack):
1587         (WebCore::RenderThemeMac::paintSliderThumb):
1588         (WebCore::RenderThemeMac::adjustSliderThumbSize):
1589         (WebCore::RenderThemeMac::paintSearchField):
1590         (WebCore::RenderThemeMac::adjustSearchFieldStyle):
1591         (WebCore::RenderThemeMac::paintSearchFieldCancelButton):
1592         (WebCore::RenderThemeMac::paintSearchFieldResultsButton):
1593
1594 2008-08-27  Brady Eidson  <beidson@apple.com>
1595
1596         Reviewed by Anders
1597
1598         <rdar://problem/6134133> - Crash when loading large movie as a standalone document
1599
1600         We hand off these loads to Quicktime which manages and spools the data itself, but we also continued
1601         to load and buffer the data for the movie in WebCore.  With large media files, this results in blowing
1602         away the virtual address space and a crash.
1603
1604         * loader/EmptyClients.h:
1605         (WebCore::EmptyFrameLoaderClient::pluginWillHandleLoadError):
1606         * loader/FrameLoaderClient.h:  Added client method to get platform specific error for
1607           "plugin will handle load"
1608
1609         * loader/MediaDocument.cpp:
1610         (WebCore::MediaTokenizer::createDocumentStructure): Tell the MainResourceLoader to not buffer data,
1611           and cancel the WebCore-managed load
1612         (WebCore::MediaTokenizer::writeRawData):
1613         (WebCore::MediaTokenizer::finish):
1614
1615 2008-08-26  Simon Fraser  <simon.fraser@apple.com>
1616
1617         Reviewed by Eric Seidel
1618
1619         Linear timing functions should have control points 0, 0, 1, 1.
1620         https://bugs.webkit.org/show_bug.cgi?id=20535
1621
1622         * css/CSSStyleSelector.cpp:
1623         (WebCore::CSSStyleSelector::mapAnimationTimingFunction):
1624         * rendering/style/RenderStyle.h:
1625
1626 2008-08-27  Adam Roben  <aroben@apple.com>
1627
1628         Windows build fix
1629
1630         * WebCore.vcproj/WebCore.vcproj: Fix file extension.
1631
1632 2008-08-26  Chris Fleizach  <cfleizach@apple.com>
1633
1634         Reviewed by Beth Dakin.
1635
1636         <rdar://problem/6069462> REGRESSION: webkit is returning flash objects as AXUnknown
1637
1638         Added platform-specific accessibilityIgnoreAttachment, which allows the platform
1639         to determine if an attachment is ignored through accessibility. Added equivalent
1640         methods in Gtk, Win and Mac
1641
1642         Test: accessibility/plugin.html
1643
1644         * GNUmakefile.am:
1645         * WebCore.vcproj/WebCore.vcproj:
1646         * WebCore.xcodeproj/project.pbxproj:
1647         * page/AccessibilityObject.h:
1648         * page/AccessibilityRenderObject.cpp:
1649         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
1650         * page/gtk/AccessibilityObjectAtk.cpp: Added.
1651         (WebCore::AccessibilityObject::accessibilityIgnoreAttachment):
1652         * page/mac/AccessibilityObjectMac.mm: Added.
1653         (WebCore::AccessibilityObject::accessibilityIgnoreAttachment):
1654         * page/mac/AccessibilityObjectWrapper.h:
1655         * page/win/AccessibilityObjectWin.cpp: Added.
1656         (WebCore::AccessibilityObject::accessibilityIgnoreAttachment):
1657
1658 2008-08-26  Chris Fleizach  <cfleizach@apple.com>
1659
1660         Reviewed by Beth Dakin.
1661
1662         <rdar://problem/5817770> can't bring up contextual menu for embedded objects in WebText
1663
1664         * page/mac/AccessibilityObjectWrapper.mm:
1665         (-[AccessibilityObjectWrapper accessibilityPerformShowMenuAction]):
1666         (-[AccessibilityObjectWrapper accessibilityShowContextMenu]):
1667
1668 2008-08-26  Chris Fleizach  <cfleizach@apple.com>
1669
1670         Reviewed by Darin Adler.
1671
1672         <rdar://problem/6176924> CrashTracer: [USER] 4 crashes in Safari at com.apple.WebCore: WebCore::RenderTableSection::numColumns
1673
1674         Tests: accessibility/table-notbody.html
1675
1676         * page/AccessibilityTable.cpp:
1677         (WebCore::AccessibilityTable::isTableExposableThroughAccessibility):
1678
1679 2008-08-26  Sam Weinig  <sam@webkit.org>
1680
1681         Reviewed by Beth Dakin.
1682
1683         Fix typo.
1684
1685         * dom/DOMCoreException.h:
1686
1687 2008-08-26  Sam Weinig  <sam@webkit.org>
1688
1689         Reviewed by Oliver Hunt.
1690
1691         Fix https://bugs.webkit.org/show_bug.cgi?id=20479
1692         <rdar://problem/6167660>
1693         Take image redirects into account when tainting the canvas.
1694
1695         Test: http/tests/security/canvas-remote-read-redirect-to-remote-image.html
1696
1697         * html/CanvasRenderingContext2D.cpp:
1698         (WebCore::CanvasRenderingContext2D::drawImage):
1699         (WebCore::CanvasRenderingContext2D::drawImageFromRect):
1700
1701 2008-08-26  Sam Weinig  <sam@webkit.org>
1702
1703         Reviewed by Darin Adler.
1704
1705         Change canvas tainting logic to ask the image if it contains
1706         any resources outside of its own origin. Since there is no 
1707         way to determine if SVG images contain any resources outside its
1708         origin, we always assume it does.
1709
1710         * html/CanvasRenderingContext2D.cpp:
1711         (WebCore::CanvasRenderingContext2D::drawImage):
1712         (WebCore::CanvasRenderingContext2D::drawImageFromRect):
1713         * platform/graphics/BitmapImage.h:
1714         (WebCore::BitmapImage::hasSingleSecurityOrigin):
1715         * platform/graphics/GeneratedImage.h:
1716         (WebCore::GeneratedImage::hasSingleSecurityOrigin):
1717         * platform/graphics/Image.h:
1718         (WebCore::Image::hasSingleSecurityOrigin):
1719         * platform/graphics/cg/PDFDocumentImage.h:
1720         (WebCore::PDFDocumentImage::hasSingleSecurityOrigin):
1721         * svg/graphics/SVGImage.h:
1722
1723 2008-08-26  Maxime Britto  <britto@apple.com>
1724
1725         Reviewed by Adele.
1726
1727         <rdar://6159244> Pan-scrolling does not work on particular sites (starmagazine.com, nytimes.com)
1728         This patch fixes the issues and modify the behavior of the panscroll by allowing it to jump to a parent layer when it reaches the end of its scrollable area.
1729         This is matching the behavior of the mouse wheel when trying to scroll in a smaller layer of the page (div, textarea, ...) and when we reach the edge and keep scrolling then the whole page scrolls.
1730
1731         * page/EventHandler.cpp:
1732         (WebCore::EventHandler::updateAutoscrollRenderer): if we switch to the parent layer to do the scroll we want to change the renderer for the panning
1733         * page/EventHandler.h:
1734         * rendering/RenderLayer.cpp:
1735         (WebCore::RenderLayer::panScrollFromPoint): now calls the scrollByRecursively method when it has computed the xDelta and yDelta
1736         (WebCore::RenderLayer::scrollByRecursively): try to scroll the current layer by the xDelta and yDelta provided, if it can't it ask its parent layer to do so.
1737         * rendering/RenderLayer.h:
1738         * rendering/RenderObject.cpp:
1739         (WebCore::RenderObject::canBeProgramaticallyScrolled): a RenderObject must have a RenderLayer to be programatically scrolled
1740         (WebCore::RenderObject::autoscroll): No need to check for the layer anymore since we verify it's present in the upmentionned method
1741         (WebCore::RenderObject::panScroll): No need to check for the layer anymore too.
1742
1743 2008-08-25  Julien Chaffraix  <jchaffraix@webkit.org>
1744
1745         Reviewed by Darin.
1746
1747         Bug 20247: setAttributeNode() does not work when attribute name has a capital letter in it
1748         https://bugs.webkit.org/show_bug.cgi?id=20247
1749
1750         <rdar://problem/6118218>
1751
1752         Add a boolean parameter to getAttributeItem to choose between case sensitive and case insensitive
1753         check. This keeps the behaviour for setAttribute / hasAttribute (case sensitive) and getAttribute
1754         (case insensitive for HTML elements).
1755
1756         Test: fast/dom/Element/getAttribute-check-case-sensitivity.html
1757
1758         * dom/Element.cpp:
1759         (WebCore::Element::getAttribute):
1760         * dom/NamedAttrMap.cpp:
1761         (WebCore::NamedAttrMap::getNamedItem):
1762         (WebCore::NamedAttrMap::getAttributeItem):
1763         * dom/NamedAttrMap.h:
1764
1765 2008-08-25  Sam Weinig  <sam@webkit.org>
1766
1767         Reviewed by Oliver Hunt.
1768
1769         Fix for https://bugs.webkit.org/show_bug.cgi?id=20514
1770         <rdar://problem/6174096>
1771         Treat SVG images as dirty when drawing to a canvas.
1772
1773         Test: http/tests/security/canvas-remote-read-svg-image.html
1774
1775         * html/CanvasRenderingContext2D.cpp:
1776         (WebCore::CanvasRenderingContext2D::drawImage):
1777         (WebCore::CanvasRenderingContext2D::drawImageFromRect):
1778         * platform/graphics/Image.h:
1779         (WebCore::Image::isSVGImage):
1780         * svg/graphics/SVGImage.h:
1781         (WebCore::SVGImage::isSVGImage):
1782
1783 2008-08-25  Sam Weinig  <sam@webkit.org>
1784
1785         Reviewed by Mark Rowe.
1786
1787         Fix https://bugs.webkit.org/show_bug.cgi?id=20377
1788         Leak in XMLHttpRequest.
1789
1790         * xml/XMLHttpRequest.cpp:
1791         (WebCore::XMLHttpRequest::makeCrossSiteAccessRequestWithPreflight):
1792
1793 2008-08-25  Brady Eidson  <beidson@apple.com>
1794
1795         Reviewed by Anders
1796
1797         Speculative fix for <rdar://problem/6173217>
1798
1799         Moves the "clearArchivedResources()" call to exactly where it used to be in the old version of WebArchive code.
1800         Also, adds a null check for m_documentLoader since DocumentLoader::stopLoading() can end up clearing it, rendering
1801         the first null check invalid.
1802
1803         * loader/FrameLoader.cpp:
1804         (WebCore::FrameLoader::stopAllLoaders):
1805
1806
1807 2008-08-25  Kevin McCullough  <kmccullough@apple.com>
1808
1809         Reviewed by Tim.
1810
1811         <rdar://problem/6157711> Heavy/Tree view selector is not grayed out if
1812         there is no profile, can cause crash
1813
1814         * page/inspector/ProfilesPanel.js:
1815
1816 2008-08-25  Dean Jackson  <dino@apple.com>
1817
1818         Reviewed by Dave Hyatt
1819
1820         Make sure 'inherit' is handled by transition property.
1821         https://bugs.webkit.org/show_bug.cgi?id=20513
1822
1823         Test: transitions/inherit.html
1824         Test: transitions/inherit-other-props.html
1825
1826         * css/CSSStyleSelector.cpp:
1827           fix macro to check existence of list before getting size
1828
1829 2008-08-25  Anders Carlsson  <andersca@apple.com>
1830
1831         Reviewed by Mark.
1832
1833         <rdar://problem/6149787> crash @ com.apple.JavaScriptCore: WTF::callOnMainThread + 37.
1834         
1835         Initialize threading in the call to WebCoreObjCFinalizeOnMainThread. We currently assume 
1836         (safely) that any class that needs finalization on the main thread will also need to be deallocated
1837         on the main thread, and calling initializeThreading from WebCoreObjCFinalizeOnMainThread instead of
1838         calling it from WebCoreObjCScheduleDeallocateOnMainThread seems safer.
1839
1840         * platform/mac/WebCoreObjCExtras.c:
1841         (WebCoreObjCFinalizeOnMainThread):
1842
1843 2008-08-25  Antti Koivisto  <antti@apple.com>
1844
1845         Reviewed by Dan Bernstein.
1846
1847         Rename CachedResource::referenced() to CachedResource::hasClients() to
1848         match previous ref() -> addClient() rename.
1849
1850         * loader/Cache.cpp:
1851         (WebCore::Cache::pruneLiveResources):
1852         (WebCore::Cache::pruneDeadResources):
1853         (WebCore::Cache::remove):
1854         (WebCore::Cache::getStatistics):
1855         (WebCore::Cache::dumpLRULists):
1856         * loader/CachedResource.cpp:
1857         (WebCore::CachedResource::addClient):
1858         (WebCore::CachedResource::removeClient):
1859         (WebCore::CachedResource::setDecodedSize):
1860         (WebCore::CachedResource::setEncodedSize):
1861         * loader/CachedResource.h:
1862         (WebCore::CachedResource::hasClients):
1863         (WebCore::CachedResource::canDelete):
1864
1865 2008-08-25  Anthony Ricaud  <rik24d@gmail.com>
1866
1867         Add a missing Inspector localized string for "other".
1868
1869         https://bugs.webkit.org/show_bug.cgi?id=20509
1870
1871         Reviewed by Tim Hatcher.
1872
1873         * English.lproj/localizedStrings.js:
1874
1875 2008-08-22  Kevin McCullough  <kmccullough@apple.com>
1876
1877         Reviewed by Geoff, Mark and Tim.
1878
1879         <rdar://problem/6150623> JSProfiler: It would be nice if the profiles
1880         in the console said what file and line number they came from
1881         - Lay the foundation for getting line numbers and other data from the
1882         JavaScript engine.
1883
1884         * ForwardingHeaders/VM: Added.
1885         * ForwardingHeaders/VM/Machine.h: Added.
1886         * page/Console.cpp: Gather the line number and file information when 
1887         profileEnd has been called, but don't use it until didFinishProfiling is
1888         called.  We won't need to wait once we remove the profiler "zombie" mode
1889         which this patch helps pave the foundation for.
1890         (WebCore::Console::Console):
1891         (WebCore::Console::profileEnd):
1892         (WebCore::Console::finishedProfiling):
1893         * page/Console.h:
1894         * page/InspectorController.cpp: Modify calls to
1895         addProfileMessageToConsole to satisfy the new arguments it takes.
1896         (WebCore::InspectorController::finishedProfiling):
1897         (WebCore::InspectorController::addProfile):
1898         (WebCore::InspectorController::addProfileMessageToConsole):
1899         (WebCore::InspectorController::finishedProfiling):
1900         * page/InspectorController.h:
1901
1902 2008-08-25  Holger Hans Peter Freyther  <zecke@selfish.org>
1903
1904         Reviewed by Simon.
1905
1906         [inspector] Update the WebKit.qrc Qt resources file
1907         Catchup with the changes in the directory.
1908
1909         * page/inspector/WebKit.qrc:
1910
1911 2008-08-25  Dirk Schulze  <vbs85@gmx.de>
1912
1913         Reviewed by Simon.
1914
1915         Transformed the radian to degree, to get rotate()
1916         in canvas work as expected.
1917
1918         [Qt] Canvas.rotate() doesn't work
1919         https://bugs.webkit.org/show_bug.cgi?id=20496
1920
1921         * platform/graphics/qt/GraphicsContextQt.cpp:
1922         (WebCore::GraphicsContext::rotate):
1923
1924 2008-08-24  Steve Falkenburg  <sfalken@apple.com>
1925
1926         Add a "last chance" WM_TIMER to the Windows shared timer.
1927         
1928         The last chance timer fires every 5 seconds to run any lost WM_TIMER based timers.
1929         Failure to fire a timer is fatal to the cross-platform Timer code, since it won't re-schedule
1930         timers if a timer with an earlier expiration is already pending. This results in no timers
1931         firing from that point on.
1932         
1933         We lose WM_TIMER messages occasionally (in the neighborhood of 1 per hour) probably due to a
1934         buggy window message hook.
1935         
1936         This timer will start when the first WM_TIMER is scheduled, and will
1937         fire every 5 seconds thereafter, causing any lost timers to be fired.
1938         
1939         Found this via one of its symptoms: leaking WebFrames. The fix prevents timers from stalling
1940         and prevents the WebFrame leak.
1941         
1942         Reviewed by Darin Adler, Geoff Garen.
1943
1944         * platform/win/SharedTimerWin.cpp:
1945         (WebCore::):
1946         (WebCore::TimerWindowWndProc):
1947         (WebCore::setSharedTimerFireTime):
1948
1949 2008-08-24  Dan Bernstein  <mitz@apple.com>
1950
1951         Reviewed by Darin Adler.
1952
1953         - fix <rdar://problem/6065547> REGRESSION (r34879): "Subject" in unread emails in Yahoo mail is not shown in bold
1954
1955         Test: fast/css/font-property-priority.html
1956
1957         * css/CSSParser.cpp:
1958         (WebCore::CSSParser::parseValue): Changed to pass the 'important' flag
1959         to the font-property-parsing functions.
1960         (WebCore::CSSParser::parseFontStyle): Added an 'important' argument and
1961         changed to use it rather than the m_important member.
1962         (WebCore::CSSParser::parseFontVariant): Ditto.
1963         (WebCore::CSSParser::parseFontWeight): Ditto.
1964         * css/CSSParser.h:
1965
1966 2008-08-24  Timothy Hatcher  <timothy@apple.com>
1967
1968         Fixes a bug where the Inspector's UI would not animate or
1969         fully function because JavaScript timeouts, intervals and
1970         CSS animation timers where not firing while paused at a
1971         a breakpoint in the inspected page.
1972
1973         https://bugs.webkit.org/show_bug.cgi?id=20042
1974
1975         Reviewed by Darin Adler.
1976
1977         Test: manual-tests/inspector/forzen-ui-while-paused.html
1978
1979         * page/JavaScriptDebugServer.cpp:
1980         (WebCore::JavaScriptDebugServer::pauseIfNeeded):
1981         Add a call to TimerBase::fireTimersInNestedEventLoop before
1982         spinning the EventLoop.
1983
1984 2008-08-24  Rob Buis  <buis@kde.org>
1985
1986         Reviewed by Sam Weinig.
1987
1988         https://bugs.webkit.org/show_bug.cgi?id=20324
1989         A change in SVG Glyph wont show up
1990
1991         Invalidate the glyph cache when the d attribute is set.
1992
1993         Test: svg/custom/glyph-setting-d-attribute.svg
1994
1995         * svg/SVGGlyphElement.cpp:
1996         (WebCore::SVGGlyphElement::invalidateGlyphCache):
1997         (WebCore::SVGGlyphElement::parseMappedAttribute):
1998         (WebCore::SVGGlyphElement::insertedIntoDocument):
1999         (WebCore::SVGGlyphElement::removedFromDocument):
2000         * svg/SVGGlyphElement.h:
2001
2002 2008-08-24  Dan Bernstein  <mitz@apple.com>
2003
2004         Reviewed by Sam Weinig.
2005
2006         - fix https://bugs.webkit.org/show_bug.cgi?id=13864
2007           <rdar://problem/5451470> REGRESSION: Uninitialized value in RenderBlock::calcInlinePrefWidths()
2008
2009         * rendering/RenderText.cpp:
2010         (WebCore::RenderText::trimmedPrefWidths): Moved the assignment to
2011         beginWS and endWS before the early return to ensure that they are
2012         initialized in that case.
2013
2014 2008-08-23  Cameron Zwarich  <cwzwarich@uwaterloo.ca>
2015
2016         Rubber-stamped by Mark Rowe.
2017
2018         Remove modelines.
2019
2020         * WebCore.pro:
2021         * bridge/testbindings.cpp:
2022         * dom/DocPtr.h:
2023         * loader/SubstituteData.h:
2024         * page/Chrome.cpp:
2025         * page/Chrome.h:
2026         * page/ChromeClient.h:
2027         * page/Frame.h:
2028         * page/FrameLoadRequest.h:
2029         * page/FrameTree.cpp:
2030         * page/FrameTree.h:
2031         * page/Page.h:
2032         * page/mac/ChromeMac.mm:
2033         * platform/network/HTTPHeaderMap.h:
2034         * platform/network/ResourceErrorBase.cpp:
2035         * platform/network/ResourceErrorBase.h:
2036         * platform/network/ResourceHandleInternal.h:
2037         * platform/network/ResourceRequestBase.cpp:
2038         * platform/network/ResourceRequestBase.h:
2039         * platform/network/ResourceResponseBase.cpp:
2040         * platform/network/ResourceResponseBase.h:
2041         * platform/network/cf/ResourceError.h:
2042         * platform/network/cf/ResourceRequest.h:
2043         * platform/network/cf/ResourceRequestCFNet.h:
2044         * platform/network/cf/ResourceResponse.h:
2045         * platform/network/cf/ResourceResponseCFNet.h:
2046         * platform/network/curl/ResourceError.h:
2047         * platform/network/curl/ResourceRequest.h:
2048         * platform/network/curl/ResourceResponse.h:
2049         * platform/network/mac/ResourceError.h:
2050         * platform/network/mac/ResourceErrorMac.mm:
2051         * platform/network/mac/ResourceRequest.h:
2052         * platform/network/mac/ResourceRequestMac.mm:
2053         * platform/network/mac/ResourceResponse.h:
2054         * platform/network/mac/ResourceResponseMac.mm:
2055         * platform/network/qt/ResourceError.h:
2056         * platform/network/qt/ResourceRequest.h:
2057         * platform/network/qt/ResourceResponse.h:
2058         * platform/network/soup/CookieJarSoup.cpp:
2059         * platform/network/soup/ResourceError.h:
2060         * platform/network/soup/ResourceRequest.h:
2061         * platform/network/soup/ResourceResponse.h:
2062
2063 2008-08-23  Dan Bernstein  <mitz@apple.com>
2064
2065         Reviewed by Dave Hyatt.
2066
2067         - fix <rdar://problem/6065143> Reflowed image in first line of table doesn't affect baseline
2068
2069         Test: fast/table/vertical-align-baseline.html
2070
2071         * rendering/RenderTable.cpp:
2072         (WebCore::RenderTable::getBaselineOfFirstLineBox): Added. Returns the
2073         baseline of the first table row, if there is one, -1 otherwise.
2074         * rendering/RenderTable.h:
2075         * rendering/RenderTableCell.cpp:
2076         (WebCore::RenderTableCell::baselinePosition): Changed to follow the
2077         CSS2.1 definition of the baseline of a table cell.
2078         * rendering/RenderTableSection.cpp:
2079         (WebCore::RenderTableSection::getBaselineOfFirstLineBox): Added. Returns
2080         the baseline of the first row in the section.
2081         * rendering/RenderTableSection.h:
2082
2083 2008-08-18  Jon Honeycutt  <jhoneycutt@apple.com>
2084
2085         Add SPI to make a Windows WebView transparent.
2086
2087         Reviewed by Dan Bernstein.
2088
2089         * platform/graphics/GraphicsContext.h: Add a parameter, hasAlpha, that
2090         determines whether the created context has an alpha channel.
2091         * platform/graphics/win/GraphicsContextCGWin.cpp:
2092         (WebCore::CGContextWithHDC):
2093
2094 2008-08-22  Timothy Hatcher  <timothy@apple.com>
2095
2096         Rolls out r35834 because it caused a regression in the Inspector's
2097         Console where some expressions always threw a syntax error.
2098
2099         https://bugs.webkit.org/show_bug.cgi?id=20487
2100
2101         * page/inspector/Console.js:
2102         (Console.prototype._evalInInspectedWindow): Removes parenthesis
2103         around the expression.
2104
2105 2008-08-22  Timothy Hatcher  <timothy@apple.com>
2106
2107         Makes getStyleProperty return a value for the overflow property
2108         when overflow-x and overflow-y are equal.
2109
2110         https://bugs.webkit.org/show_bug.cgi?id=20485
2111
2112         Reviewed by Dan Bernstein.
2113
2114         Test: fast/css/overflow-property.html
2115
2116         * css/CSSMutableStyleDeclaration.cpp:
2117         (WebCore::CSSMutableStyleDeclaration::getPropertyValue):
2118
2119 2008-08-22  Timothy Hatcher  <timothy@apple.com>
2120
2121         Fixes a bug where while editing in the Inspector the
2122         sidebar scroll position would jump to the top.
2123
2124         https://bugs.webkit.org/show_bug.cgi?id=20484
2125
2126         Reviewed by Darin Adler.
2127
2128         * page/inspector/treeoutline.js:
2129         (TreeOutline._removeChildren): Remove the offsetTop call that
2130         was forcing a layout, since layout causes scroll positions
2131         to be clamped to the new scrollHeight/Width. Layout will happen
2132         normally when needed.
2133
2134 2008-08-22  Kevin Ollivier  <kevino@theolliviers.com>
2135
2136         wx build fix. Add AccessibilityTable sources.
2137
2138         * WebCoreSources.bkl:
2139
2140 2008-08-21  Dan Bernstein  <mitz@apple.com>
2141
2142         Reviewed by Jon Honeycutt and Alexey Proskuryakov.
2143
2144         - fix <rdar://problem/6162701> WebKit should correct Geeza Pro's font metrics
2145
2146         Test: platform/mac/fast/text/international/Geeza-Pro-vertical-metrics-adjustment.html
2147
2148         * platform/graphics/mac/SimpleFontDataMac.mm:
2149         (WebCore::SimpleFontData::platformInit): Add 8% to Geeza Pro's reported
2150         ascent and 100% to its reported descent.
2151
2152 2008-08-21  Kalle Vahlman  <kalle.vahlman@movial.com>
2153
2154         Reviewed by Darin Adler.
2155
2156         https://bugs.webkit.org/show_bug.cgi?id=20267
2157         [GTK] Crash on some pages due to a plugin
2158
2159         Fix handling of badly formatted and empty plugin mime descriptions
2160
2161         * plugins/gtk/PluginPackageGtk.cpp:
2162         (WebCore::PluginPackage::fetchInfo):
2163
2164 2008-08-21  Kevin Watters  <kevinwatters@gmail.com>
2165
2166         Reviewed by Darin Adler.
2167
2168         Follow other ports (and IE) in ImageSourceWx.cpp never to return an
2169         animated GIF frame duration of less than 50ms.
2170
2171         * platform/graphics/wx/ImageSourceWx.cpp:
2172         (WebCore::ImageSource::frameDurationAtIndex):
2173
2174 2008-08-21  Maxime Britto  <britto@apple.com>
2175
2176         Reviewed by Kevin McCullough.
2177
2178         Test: fast/events/autoscroll-nonscrollable-iframe-in-scrollable-div.html
2179         https://bugs.webkit.org/show_bug.cgi?id=20451
2180    
2181         rdar://problem/6166435 Inspector doesn't auto scroll when selecting text (20451)
2182         When we climb up the rendering tree looking for a scrollable renderer, we need to be able to jump outside of an iframe.
2183         This way we can see if what is embedding the iframe can be scrolled even if the iframe content can't.
2184
2185         * page/EventHandler.cpp:
2186         (WebCore::EventHandler::handleMouseDraggedEvent): when we reach the document node and it can't be scrolled we set the next parent as the document's owner element if it exists.
2187
2188         (WebCore::EventHandler::handleMousePressEvent): ditto
2189
2190 2008-08-21  Anthony Ricaud  <rik24d@gmail.com>
2191
2192         Small optimization for when the dividers in the Inspector's
2193         Resources panel are updated.
2194
2195         Reviewed by Tim Hatcher.
2196
2197         * page/inspector/ResourcesPanel.js:
2198         (WebInsector.ResourcesPanel.prototype._updateGraphDividersIfNeeded):
2199         Combind a for loop and clone the divider element.
2200
2201 2008-08-21  Chris Marrin  <cmarrin@apple.com>
2202
2203         Allow 0 (without units) for Time eg. duration
2204         Fix for https://bugs.webkit.org/show_bug.cgi?id=20467
2205
2206         Reviewed by Dave Hyatt.
2207
2208         Test: css1/units/zero-duration-without-units.html
2209
2210         * css/CSSParser.cpp:
2211         (WebCore::CSSParser::validUnit):
2212
2213 2008-08-21  Timothy Hatcher  <timothy@apple.com>
2214
2215         Make deleting all text while editing a DOM attribute in
2216         the Inspector delete the attribute. This also fixes
2217         an exception that would happen before.
2218
2219         https://bugs.webkit.org/show_bug.cgi?id=20472
2220
2221         Reviewed by Kevin McCullough.
2222
2223         * page/inspector/ElementsPanel.js:
2224         (WebInspector.DOMNodeTreeElement.prototype._attributeEditingCommitted):
2225         Don't check for hasAttributes on the parseElement, continuing
2226         through the function will correctly remove the attribute.
2227         If the parseElement is null, call _editingCancelled not
2228         editingCancelled, this fixes an exception.
2229
2230 2008-08-21  Timothy Hatcher  <timothy@apple.com>
2231
2232         Update the Inspector's Metrics pane when editing in
2233         the Styles pane. This makes sure the metrics shown
2234         always match what the Styles pane shows.
2235
2236         https://bugs.webkit.org/show_bug.cgi?id=20470
2237
2238         Reviewed by Kevin McCullough.
2239
2240         * page/inspector/ElementsPanel.js:
2241         (WebInspector.ElementsPanel): Add event listeners for
2242         the "style edited" and "style property toggled" events,
2243         so the Metrics pane is updated.
2244         (WebInspector.ElementsPanel.prototype._stylesPaneEdited):
2245         Update the Metrics pane.
2246         * page/inspector/StylesSidebarPane.js:
2247         (WebInspector.StylePropertyTreeElement.prototype.toggleEnabled):
2248         Dispatch the "style property toggled" event.
2249         (WebInspector.StylePropertyTreeElement.prototype.editingCancelled):
2250         Dispatch the "style edited" event when the CSS text is restored.
2251         (WebInspector.StylePropertyTreeElement.prototype.applyStyleText):
2252         Dispatch the "style edited" event.
2253
2254 2008-08-21  Timothy Hatcher  <timothy@apple.com>
2255
2256         Make the Inspector's Metrics sidebar pane editable.
2257
2258         https://bugs.webkit.org/show_bug.cgi?id=17218
2259         rdar://problem/5732818
2260
2261         Reviewed by Kevin McCullough.
2262
2263         * page/inspector/ElementsPanel.js:
2264         (WebInspector.ElementsPanel): Add an event listener for
2265         the "metrics edited" event, so the Styles pane is updated.
2266         * page/inspector/MetricsSidebarPane.js:
2267         (WebInspector.MetricsSidebarPane.prototype.update): Remember the node
2268         so future updates work. Add a double click event listener for the
2269         metric values to start editing.
2270         (WebInspector.MetricsSidebarPane.prototype.startEditing):
2271         Call WebInspector.startEditing with some context.
2272         (WebInspector.MetricsSidebarPane.prototype.editingCancelled):
2273         (WebInspector.MetricsSidebarPane.prototype.editingCommitted):
2274         Set the user input on the elements inline style. Fire the
2275         "metrics edited" event.
2276
2277 2008-08-21  Steve Falkenburg  <sfalken@apple.com>
2278
2279         Fix a race condition in Windows timer code.
2280         Timer function could end up being called with a 0 timer, leading to a Windows exception.
2281         
2282         Don't post a timer message if one is already pending.
2283         
2284         Reviewed by Ada Chan.
2285
2286         * platform/win/SharedTimerWin.cpp:
2287         (WebCore::TimerWindowWndProc):
2288         (WebCore::clearTimer):
2289         (WebCore::queueTimerProc):
2290         (WebCore::setSharedTimerFireTime):
2291
2292 2008-08-21  Anthony Ricaud  <rik24d@gmail.com>
2293
2294         After trying to add the expression, try again with quotes for
2295         easier edition.
2296
2297         https://bugs.webkit.org/show_bug.cgi?id=20466
2298
2299         Reviewed by Tim Hatcher.
2300
2301         * page/inspector/ObjectPropertiesSection.js: Added an
2302         evaluateExpression function.
2303
2304 2008-08-21  Anthony Ricaud  <rik24d@gmail.com>
2305
2306         Perform Inspector searches on search event to clear results when
2307         clicking the cross to empty it. Delete the lastQuery when the field
2308         is emptied in order to perform the search if exactly the same query
2309         is entered next.
2310
2311         https://bugs.webkit.org/show_bug.cgi?id=20462
2312
2313         Reviewed by Tim Hatcher.
2314
2315         * page/inspector/inspector.js:
2316
2317 2008-08-21  Marco Barisione  <marco.barisione@collabora.co.uk>
2318
2319         Reviewed by Mark Rowe.
2320
2321         http://bugs.webkit.org/show_bug.cgi?id=19656
2322         [SOUP] The gio code should call didFail() instead of
2323         didFinishLoading() in case of error
2324
2325         In case of error call didFail() instead of didReceiveResponse() and
2326         didFinishLoading().
2327
2328         * platform/network/soup/ResourceHandleSoup.cpp:
2329         (WebCore::networkErrorForFile):
2330         (WebCore::readCallback):
2331         (WebCore::openCallback):
2332         (WebCore::queryInfoCallback):
2333
2334 2008-08-20  Mark Rowe  <mrowe@apple.com>
2335
2336         Reviewed by Jon Honeycutt.
2337
2338         Fix build failure.
2339
2340         * bridge/c/c_instance.cpp:
2341         (KJS::Bindings::CInstance::getPropertyNames): Declare count as uint32_t rather than unsigned
2342         as that is what NPEnumerationFunctionPtr is declared as accepting.
2343
2344 2008-08-20  Mark Rowe  <mrowe@apple.com>
2345
2346         Reviewed by Dan Bernstein.
2347
2348         Build fix.  Handle kCGInterpolationMedium in switch statements if it is available.
2349
2350         * platform/graphics/GraphicsContext.h:
2351         (WebCore::):
2352         * platform/graphics/cg/GraphicsContextCG.cpp:
2353         (WebCore::GraphicsContext::setImageInterpolationQuality):
2354         (WebCore::GraphicsContext::imageInterpolationQuality):
2355
2356 2008-08-20  Dan Bernstein  <mitz@apple.com>
2357
2358         Rubber-stamped by John Sullivan.
2359
2360         - rename shouldUpdateWhileHidden to shouldUpdateWhileOffscreen and
2361           rename related methods and variables accordingly.
2362
2363         * WebCore.base.exp:
2364         * page/FrameView.cpp:
2365         (WebCore::FrameViewPrivate::FrameViewPrivate):
2366         (WebCore::FrameView::shouldUpdateWhileOffscreen):
2367         (WebCore::FrameView::setShouldUpdateWhileOffscreen):
2368         * page/FrameView.h:
2369         * platform/ScrollView.h:
2370         * platform/mac/ScrollViewMac.mm:
2371         (WebCore::ScrollView::updateContents):
2372
2373 2008-08-20  Brady Eidson  <beidson@apple.com>
2374
2375         Reviewed by Mitzpettel
2376
2377         <rdar://problem/6163636> - Many images broken in Mail
2378
2379         This can be traced back to the preload scanner.  With that change, CachedResources are created a lot 
2380         sooner than before and confuse the WebArchive machinery.  
2381
2382         When referencing WebArchive subresources directly through the WebKit API it is appropriate to ignore 
2383         such CachedResources since they are placeholders and have not been submitted to the ResourceLoadDelegate 
2384         machinery and nothing is known about where the data will eventually come from.
2385
2386         * loader/DocumentLoader.cpp:
2387         (WebCore::DocumentLoader::subresource):  Ignore a CachedResource if its preloadResult is 
2388           CachedResource::PreloadReferenced.
2389
2390 2008-08-20  Holger Hans Peter Freyther  <zecke@selfish.org>
2391
2392         Unreviewed compile fix
2393
2394         Catch up with the JSValue::type elimination.
2395
2396         * bridge/qt/qt_instance.cpp:
2397         (KJS::Bindings::QtRuntimeObjectImp::construct):
2398         (KJS::Bindings::QtInstance::defaultValue):
2399         * bridge/qt/qt_runtime.cpp:
2400         (KJS::Bindings::QtRuntimeConnectionMethod::call):
2401
2402 2008-08-20  Chris Teague  <chris.teague@gmail.com>
2403
2404         Reviewed by Mark Rowe.
2405
2406         Fix https://bugs.webkit.org/show_bug.cgi?id=20449
2407         Bug 20449: Build fails if LOW_BANDWIDTH_DISPLAY is defined
2408
2409         * ChangeLog:
2410         * loader/FrameLoader.cpp:
2411         (WebCore::FrameLoader::switchOutLowBandwidthDisplayIfReady):
2412
2413 2008-08-20  Simon Fraser  <simon.fraser@apple.com>
2414
2415         Reviewed by Dave Hyatt
2416
2417         getComputedStyle() for webkitTransform should return a transform
2418         that does not have the transform origin baked into it.
2419         https://bugs.webkit.org/show_bug.cgi?id=20464
2420         
2421         Test: fast/css/getComputedStyle-transform.html
2422
2423         * css/CSSComputedStyleDeclaration.cpp:
2424         (WebCore::computedTransform):
2425         * rendering/style/RenderStyle.cpp:
2426         (WebCore::RenderStyle::applyTransform):
2427         * rendering/style/RenderStyle.h:
2428
2429 2008-08-20  Josh Aas  <joshmoz@gmail.com>
2430
2431         Reviewed and landed by Anders.
2432
2433         <rdar://problem/6163636> 
2434         rename NPCocoaEvent's "event" struct to "data" (20446)
2435         
2436         * bridge/npapi.h:
2437         (_NPCocoaEvent::):
2438
2439 2008-08-20  Beth Dakin  <bdakin@apple.com>
2440
2441         Reviewed by Darin.
2442
2443         Fix for <rdar://problem/6145626> 
2444         This patch fixes a number of remaining problems getting 
2445         disconnected frames to work correctly with markAllMatchesForText() 
2446         and findString(). Details inline. 
2447
2448         This was a static helper function in Frame, but this patch requires 
2449         the same functionality in Editor, so I just added it as a function 
2450         on Node.
2451         * dom/Node.cpp:
2452         (WebCore::Node::isInShadowTree):
2453         * dom/Node.h:
2454
2455         * editing/Editor.cpp:
2456         (WebCore::Editor::insideVisibleArea): Returns false if 
2457         excludeFromTextSearch() is true.
2458
2459         In a normal (non-disconnected) frame, findString returns a range of 
2460         the document node if the text is not found in the frame. I changed 
2461         firstVisibleRange and lastVisibleRange to match that behavior when 
2462         the text is not found
2463         (WebCore::Editor::firstVisibleRange):
2464         (WebCore::Editor::lastVisibleRange):
2465
2466         Here are the bulk of the changes in the patch. A lot of text was 
2467         not being found in disconnected frames because I failed to account 
2468         for all of the possible problems associated with shadow trees. That 
2469         is fixed here.
2470         (WebCore::Editor::nextVisibleRange):
2471         * editing/Editor.h:
2472
2473         excludeFromTextSearch() is new. It allows a WebKit client to mark a 
2474         frame as not-text-searchable through SPI. 
2475         * WebCore.base.exp:
2476         * page/Frame.cpp:
2477         (WebCore::Frame::excludeFromTextSearch):
2478         (WebCore::Frame::setExcludeFromTextSearch):
2479         (WebCore::FramePrivate::FramePrivate):
2480         * page/Frame.h:
2481         * page/FramePrivate.h:
2482
2483         (WebCore::Frame::findString):
2484         (WebCore::Frame::markAllMatchesForText):  I kept running into an 
2485         assertion failure in paining code because of the forced paint on 
2486         empty visible rects.
2487
2488 2008-08-20  Timothy Hatcher  <timothy@apple.com>
2489
2490         Adds a positon box to the Inspector's Metrics sidebar
2491         pane. When an element is not statically positioned, there
2492         is now a position box that show top, right, bottom and
2493         left computed values.
2494
2495         Reviewed by Kevin McCullough.
2496
2497         * English.lproj/localizedStrings.js: Updated the strings.
2498         * page/inspector/MetricsSidebarPane.js:
2499         (WebInspector.MetricsSidebarPane.prototype.update):
2500         Renamed the boxPartValue function to createBoxPartElement
2501         and made it create the entire element. Made it understand
2502         how to get position style properties. Don't use the figure dash
2503         when 0px is used for positions, since the 0 is meaningful there.
2504         Instead use the figure dash when a position is auto.
2505         * page/inspector/inspector.css: Added a new rule for position.
2506
2507 2008-08-20  Chris Fleizach  <cfleizach@apple.com>
2508
2509         Reviewed by Beth Dakin
2510
2511         Qt build fix
2512
2513         * WebCore.pro:
2514
2515 2008-08-20  Dan Bernstein  <mitz@apple.com>
2516
2517         Reviewed by Anders Carlsson.
2518
2519         - avoid using a deprecated NSScroller method on Leopard
2520
2521         * platform/mac/PlatformScrollBarMac.mm:
2522         (WebCore::PlatformScrollbar::updateThumbPosition):
2523         (WebCore::PlatformScrollbar::updateThumbProportion):
2524
2525 2008-08-20  Jan Michael Alonzo  <jmalonzo@webkit.org>
2526
2527         Reviewed by Oliver Hunt.
2528
2529         Gtk build fix
2530
2531         * GNUmakefile.am:
2532         * page/AccessibilityTable.cpp: Change nil to 0
2533         (WebCore::AccessibilityTable::cellForColumnAndRow):
2534
2535 2008-08-19  Alexey Proskuryakov  <ap@webkit.org>
2536
2537         Reviewed by Geoff Garen.
2538
2539         Bring back shared JSGlobalData and implicit locking, because too many clients rely on it.
2540
2541         * ForwardingHeaders/kjs/JSLock.h: Added.
2542         * WebCore.vcproj/WebCore.vcproj:
2543         * bindings/js/GCController.cpp:
2544         (WebCore::collect):
2545         (WebCore::GCController::gcTimerFired):
2546         (WebCore::GCController::garbageCollectNow):
2547         * bindings/js/JSCustomSQLStatementCallback.cpp:
2548         (WebCore::JSCustomSQLStatementCallback::handleEvent):
2549         * bindings/js/JSCustomSQLStatementErrorCallback.cpp:
2550         (WebCore::JSCustomSQLStatementErrorCallback::handleEvent):
2551         * bindings/js/JSCustomSQLTransactionCallback.cpp:
2552         (WebCore::JSCustomSQLTransactionCallback::handleEvent):
2553         * bindings/js/JSCustomSQLTransactionErrorCallback.cpp:
2554         (WebCore::JSCustomSQLTransactionErrorCallback::handleEvent):
2555         * bindings/js/JSCustomVoidCallback.cpp:
2556         (WebCore::JSCustomVoidCallback::handleEvent):
2557         * bindings/js/JSCustomXPathNSResolver.cpp:
2558         (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
2559         * bindings/js/JSDOMWindowBase.cpp:
2560         (WebCore::DOMWindowTimer::~DOMWindowTimer):
2561         (WebCore::JSDOMWindowBase::clear):
2562         (WebCore::JSDOMWindowBase::timerFired):
2563         * bindings/js/JSEventCustom.cpp:
2564         (WebCore::toJS):
2565         * bindings/js/JSEventListener.cpp:
2566         (WebCore::JSAbstractEventListener::handleEvent):
2567         * bindings/js/JSNSResolver.cpp:
2568         (WebCore::JSNSResolver::lookupNamespaceURI):
2569         * bindings/js/JSNodeFilterCondition.cpp:
2570         (WebCore::JSNodeFilterCondition::acceptNode):
2571         * bindings/js/ScheduledAction.cpp:
2572         (WebCore::ScheduledAction::execute):
2573         * bindings/js/ScriptController.cpp:
2574         (WebCore::ScriptController::evaluate):
2575         (WebCore::ScriptController::clearWindowShell):
2576         (WebCore::ScriptController::createHTMLEventHandler):
2577         (WebCore::ScriptController::createSVGEventHandler):
2578         (WebCore::ScriptController::initScript):
2579         (WebCore::ScriptController::updateDocument):
2580         (WebCore::ScriptController::bindingRootObject):
2581         (WebCore::ScriptController::windowScriptNPObject):
2582         (WebCore::ScriptController::createScriptObjectForPluginElement):
2583         (WebCore::ScriptController::clearScriptObjects):
2584         * bindings/js/ScriptControllerMac.mm:
2585         (WebCore::ScriptController::windowScriptObject):
2586         * bindings/objc/WebScriptObject.mm:
2587         (_didExecute):
2588         (-[WebScriptObject callWebScriptMethod:withArguments:]):
2589         (-[WebScriptObject evaluateWebScript:]):
2590         (-[WebScriptObject setValue:forKey:]):
2591         (-[WebScriptObject valueForKey:]):
2592         (-[WebScriptObject removeWebScriptKey:]):
2593         (-[WebScriptObject stringRepresentation]):
2594         (-[WebScriptObject webScriptValueAtIndex:]):
2595         (-[WebScriptObject setWebScriptValueAtIndex:value:]):
2596         (+[WebScriptObject _convertValueToObjcValue:originRootObject:rootObject:]):
2597         * bridge/NP_jsobject.cpp:
2598         (_NPN_InvokeDefault):
2599         (_NPN_Invoke):
2600         (_NPN_Evaluate):
2601         (_NPN_GetProperty):
2602         (_NPN_SetProperty):
2603         (_NPN_RemoveProperty):
2604         (_NPN_HasProperty):
2605         (_NPN_HasMethod):
2606         (_NPN_Enumerate):
2607         * bridge/c/c_class.cpp:
2608         (KJS::Bindings::CClass::~CClass):
2609         (KJS::Bindings::CClass::methodsNamed):
2610         (KJS::Bindings::CClass::fieldNamed):
2611         * bridge/c/c_instance.cpp:
2612         (KJS::Bindings::CInstance::invokeMethod):
2613         (KJS::Bindings::CInstance::invokeDefaultMethod):
2614         (KJS::Bindings::CInstance::getPropertyNames):
2615         * bridge/c/c_runtime.cpp:
2616         (KJS::Bindings::CField::valueFromInstance):
2617         (KJS::Bindings::CField::setValueToInstance):
2618         * bridge/c/c_utility.cpp:
2619         (KJS::Bindings::convertValueToNPVariant):
2620         (KJS::Bindings::convertNPVariantToValue):
2621         * bridge/jni/jni_class.cpp:
2622         (JavaClass::JavaClass):
2623         (JavaClass::~JavaClass):
2624         * bridge/jni/jni_instance.cpp:
2625         (JavaInstance::stringValue):
2626         * bridge/jni/jni_jsobject.mm:
2627         (JavaJSObject::call):
2628         (JavaJSObject::eval):
2629         (JavaJSObject::getMember):
2630         (JavaJSObject::setMember):
2631         (JavaJSObject::removeMember):
2632         (JavaJSObject::getSlot):
2633         (JavaJSObject::setSlot):
2634         (JavaJSObject::toString):
2635         (JavaJSObject::convertValueToJObject):
2636         (JavaJSObject::convertJObjectToValue):
2637         * bridge/jni/jni_objc.mm:
2638         (KJS::Bindings::dispatchJNICall):
2639         * bridge/jni/jni_runtime.cpp:
2640         (appendClassName):
2641         (JavaMethod::signature):
2642         * bridge/jni/jni_runtime.h:
2643         (KJS::Bindings::JavaString::JavaString):
2644         (KJS::Bindings::JavaString::_commonInit):
2645         (KJS::Bindings::JavaString::~JavaString):
2646         (KJS::Bindings::JavaString::UTF8String):
2647         * bridge/jni/jni_utility.cpp:
2648         (KJS::Bindings::convertValueToJValue):
2649         * bridge/npruntime.cpp:
2650         (_NPN_GetStringIdentifier):
2651         * bridge/objc/objc_instance.mm:
2652         (ObjcInstance::moveGlobalExceptionToExecState):
2653         (ObjcInstance::invokeMethod):
2654         (ObjcInstance::invokeDefaultMethod):
2655         (ObjcInstance::setValueOfUndefinedField):
2656         (ObjcInstance::getValueOfUndefinedField):
2657         * bridge/objc/objc_runtime.mm:
2658         (ObjcField::valueFromInstance):
2659         (ObjcField::setValueToInstance):
2660         * bridge/objc/objc_utility.mm:
2661         (KJS::Bindings::convertValueToObjcValue):
2662         (KJS::Bindings::convertNSStringToString):
2663         (KJS::Bindings::convertObjcValueToValue):
2664         * bridge/qt/qt_instance.cpp:
2665         (KJS::Bindings::QtRuntimeObjectImp::removeFromCache):
2666         (KJS::Bindings::QtInstance::~QtInstance):
2667         (KJS::Bindings::QtInstance::getQtInstance):
2668         (KJS::Bindings::QtInstance::getRuntimeObject):
2669         * bridge/qt/qt_runtime.cpp:
2670         (KJS::Bindings::convertValueToQVariant):
2671         (KJS::Bindings::convertQVariantToValue):
2672         (KJS::Bindings::QtRuntimeMetaMethod::call):
2673         (KJS::Bindings::QtRuntimeConnectionMethod::call):
2674         (KJS::Bindings::QtConnectionObject::QtConnectionObject):
2675         (KJS::Bindings::QtConnectionObject::execute):
2676         * bridge/runtime.cpp:
2677         (KJS::Bindings::Instance::createRuntimeObject):
2678         * bridge/testbindings.cpp:
2679         (main):
2680         * bridge/testbindings.mm:
2681         (main):
2682         * bridge/testqtbindings.cpp:
2683         (main):
2684         * dom/Document.cpp:
2685         (WebCore::Document::~Document):
2686         * dom/Node.cpp:
2687         (WebCore::Node::setDocument):
2688         * history/CachedPage.cpp:
2689         (WebCore::CachedPage::CachedPage):
2690         (WebCore::CachedPage::restore):
2691         (WebCore::CachedPage::clear):
2692         * loader/FrameLoader.cpp:
2693         (WebCore::getString):
2694         * page/InspectorController.cpp:
2695         (WebCore::ConsoleMessage::ConsoleMessage):
2696         (WebCore::XMLHttpRequestResource::XMLHttpRequestResource):
2697         (WebCore::XMLHttpRequestResource::~XMLHttpRequestResource):
2698         (WebCore::getResourceDocumentNode):
2699         (WebCore::search):
2700         (WebCore::inspectedWindow):
2701         (WebCore::wrapCallback):
2702         (WebCore::currentCallFrame):
2703         (WebCore::profiles):
2704         (WebCore::InspectorController::focusNode):
2705         (WebCore::InspectorController::inspectedWindowScriptObjectCleared):
2706         (WebCore::InspectorController::addDatabaseScriptResource):
2707         (WebCore::InspectorController::addScriptProfile):
2708         * page/JavaScriptCallFrame.cpp:
2709         (WebCore::JavaScriptCallFrame::evaluate):
2710         * page/JavaScriptProfileNode.cpp:
2711         (WebCore::getTotalTime):
2712         (WebCore::getSelfTime):
2713         (WebCore::getTotalPercent):
2714         (WebCore::getSelfPercent):
2715         (WebCore::getNumberOfCalls):
2716         (WebCore::getChildren):
2717         (WebCore::getVisible):
2718         * page/Page.cpp:
2719         * page/mac/FrameMac.mm:
2720         * plugins/PluginView.cpp:
2721         (WebCore::PluginView::start):
2722         (WebCore::getString):
2723         (WebCore::PluginView::performRequest):
2724         (WebCore::PluginView::bindingInstance):
2725         * plugins/gtk/PluginViewGtk.cpp:
2726         (WebCore::PluginView::paint):
2727         (WebCore::PluginView::handleKeyboardEvent):
2728         (WebCore::PluginView::handleMouseEvent):
2729         (WebCore::PluginView::setNPWindowRect):
2730         (WebCore::PluginView::stop):
2731         (WebCore::PluginView::init):
2732         * plugins/qt/PluginViewQt.cpp:
2733         (WebCore::PluginView::setNPWindowRect):
2734         (WebCore::PluginView::stop):
2735         (WebCore::PluginView::init):
2736         * plugins/win/PluginViewWin.cpp:
2737         (WebCore::PluginView::dispatchNPEvent):
2738         (WebCore::PluginView::handleKeyboardEvent):
2739         (WebCore::PluginView::handleMouseEvent):
2740         (WebCore::PluginView::setNPWindowRect):
2741         (WebCore::PluginView::stop):
2742         * xml/XMLHttpRequest.cpp:
2743         (WebCore::XMLHttpRequest::clearResponse):
2744         (WebCore::XMLHttpRequest::didFinishLoading):
2745         (WebCore::XMLHttpRequest::didReceiveData):
2746
2747 2008-08-19  Eric Seidel  <eric@webkit.org>
2748
2749         Reviewed by Geoff Garen.
2750
2751         Add the beginnings of Skia graphics support to WebCore
2752         as I try to begin the long process of un-forking the changes
2753         needed to WebCore to make Andriod's WebCore build.
2754
2755         I'll follow this up with actual *Skia.cpp files in a separate patch.
2756
2757         * platform/graphics/AffineTransform.h:
2758         * platform/graphics/FloatPoint.h:
2759         * platform/graphics/FloatRect.h:
2760         * platform/graphics/Gradient.h:
2761         * platform/graphics/GraphicsContext.h:
2762         * platform/graphics/Image.h:
2763         * platform/graphics/ImageBuffer.h:
2764         * platform/graphics/ImageSource.h:
2765         * platform/graphics/IntPoint.h:
2766         * platform/graphics/IntRect.h:
2767         * platform/graphics/Path.h:
2768         * platform/graphics/Pattern.h:
2769         * svg/graphics/SVGPaintServerPattern.h:
2770         * svg/graphics/SVGPaintServerSolid.h:
2771
2772 2008-08-19  Steve Falkenburg  <sfalken@apple.com>
2773
2774         Fix Windows build more.
2775
2776         * WebCore.vcproj/WebCore.vcproj:
2777
2778 2008-08-19  Steve Falkenburg  <sfalken@apple.com>
2779
2780         Fix Windows build.
2781
2782         * page/AccessibilityRenderObject.cpp:
2783         (WebCore::AccessibilityRenderObject::canSetFocusAttribute):
2784
2785 2008-08-19  Chris Fleizach  <cfleizach@apple.com>
2786
2787         Reviewed by Beth Dakin.
2788
2789         <rdar://problem/4003764> Expose tables as AXTables
2790  
2791         Tests: accessibility/table-attributes.html
2792                accessibility/table-cell-spans.html
2793                accessibility/table-cells.html
2794                accessibility/table-detection.html
2795                accessibility/table-sections.html
2796                accessibility/table-with-rules.html
2797
2798         * WebCore.xcodeproj/project.pbxproj:
2799         * page/AXObjectCache.cpp:
2800         (WebCore::AXObjectCache::get):
2801         * page/AccessibilityObject.h:
2802         (WebCore::):
2803         (WebCore::AccessibilityObject::isDataTable):
2804         (WebCore::AccessibilityObject::isTableRow):
2805         (WebCore::AccessibilityObject::isTableColumn):
2806         (WebCore::AccessibilityObject::isTableCell):
2807         * page/AccessibilityRenderObject.cpp:
2808         (WebCore::AccessibilityRenderObject::canSetFocusAttribute):
2809         * page/AccessibilityTable.cpp: Added.
2810         (WebCore::AccessibilityTable::AccessibilityTable):
2811         (WebCore::AccessibilityTable::~AccessibilityTable):
2812         (WebCore::AccessibilityTable::create):
2813         (WebCore::AccessibilityTable::isTableExposableThroughAccessibility):
2814         (WebCore::AccessibilityTable::clearChildren):
2815         (WebCore::AccessibilityTable::addChildren):
2816         (WebCore::AccessibilityTable::headerContainer):
2817         (WebCore::AccessibilityTable::columns):
2818         (WebCore::AccessibilityTable::rows):
2819         (WebCore::AccessibilityTable::rowHeaders):
2820         (WebCore::AccessibilityTable::columnHeaders):
2821         (WebCore::AccessibilityTable::cells):
2822         (WebCore::AccessibilityTable::columnCount):
2823         (WebCore::AccessibilityTable::rowCount):
2824         (WebCore::AccessibilityTable::cellForColumnAndRow):
2825         (WebCore::AccessibilityTable::roleValue):
2826         (WebCore::AccessibilityTable::accessibilityIsIgnored):
2827         (WebCore::AccessibilityTable::title):
2828         (WebCore::AccessibilityTable::isDataTable):
2829         * page/AccessibilityTable.h: Added.
2830         * page/AccessibilityTableCell.cpp: Added.
2831         (WebCore::AccessibilityTableCell::AccessibilityTableCell):
2832         (WebCore::AccessibilityTableCell::~AccessibilityTableCell):
2833         (WebCore::AccessibilityTableCell::create):
2834         (WebCore::AccessibilityTableCell::accessibilityIsIgnored):
2835         (WebCore::AccessibilityTableCell::rowIndexRange):
2836         (WebCore::AccessibilityTableCell::columnIndexRange):
2837         * page/AccessibilityTableCell.h: Added.
2838         (WebCore::AccessibilityTableCell::isTableCell):
2839         (WebCore::AccessibilityTableCell::roleValue):
2840         * page/AccessibilityTableColumn.cpp: Added.
2841         (WebCore::AccessibilityTableColumn::AccessibilityTableColumn):
2842         (WebCore::AccessibilityTableColumn::~AccessibilityTableColumn):
2843         (WebCore::AccessibilityTableColumn::create):
2844         (WebCore::AccessibilityTableColumn::setParentTable):
2845         (WebCore::AccessibilityTableColumn::elementRect):
2846         (WebCore::AccessibilityTableColumn::size):
2847         (WebCore::AccessibilityTableColumn::children):
2848         (WebCore::AccessibilityTableColumn::headerObject):
2849         (WebCore::AccessibilityTableColumn::headerObjectForSection):
2850         (WebCore::AccessibilityTableColumn::addChildren):
2851         * page/AccessibilityTableColumn.h: Added.
2852         (WebCore::AccessibilityTableColumn::parentObject):
2853         (WebCore::AccessibilityTableColumn::roleValue):
2854         (WebCore::AccessibilityTableColumn::accessibilityIsIgnored):
2855         (WebCore::AccessibilityTableColumn::isTableColumn):
2856         (WebCore::AccessibilityTableColumn::setColumnIndex):
2857         (WebCore::AccessibilityTableColumn::columnIndex):
2858         * page/AccessibilityTableHeaderContainer.cpp: Added.
2859         (WebCore::AccessibilityTableHeaderContainer::AccessibilityTableHeaderContainer):
2860         (WebCore::AccessibilityTableHeaderContainer::~AccessibilityTableHeaderContainer):
2861         (WebCore::AccessibilityTableHeaderContainer::create):
2862         (WebCore::AccessibilityTableHeaderContainer::children):
2863         (WebCore::AccessibilityTableHeaderContainer::elementRect):
2864         (WebCore::AccessibilityTableHeaderContainer::size):
2865         (WebCore::AccessibilityTableHeaderContainer::addChildren):
2866         * page/AccessibilityTableHeaderContainer.h: Added.
2867         (WebCore::AccessibilityTableHeaderContainer::roleValue):
2868         (WebCore::AccessibilityTableHeaderContainer::setParentTable):
2869         (WebCore::AccessibilityTableHeaderContainer::parentObject):
2870         (WebCore::AccessibilityTableHeaderContainer::accessibilityIsIgnored):
2871         * page/AccessibilityTableRow.cpp: Added.
2872         (WebCore::AccessibilityTableRow::AccessibilityTableRow):
2873         (WebCore::AccessibilityTableRow::~AccessibilityTableRow):
2874         (WebCore::AccessibilityTableRow::create):
2875         (WebCore::AccessibilityTableRow::accessibilityIsIgnored):
2876         (WebCore::AccessibilityTableRow::headerObject):
2877         * page/AccessibilityTableRow.h: Added.
2878         (WebCore::AccessibilityTableRow::isTableRow):
2879         (WebCore::AccessibilityTableRow::roleValue):
2880         (WebCore::AccessibilityTableRow::setRowIndex):
2881         (WebCore::AccessibilityTableRow::rowIndex):
2882         * page/mac/AccessibilityObjectWrapper.mm:
2883         (-[AccessibilityObjectWrapper accessibilityAttributeNames]):
2884         (RoleEntry::):
2885         (-[AccessibilityObjectWrapper roleDescription]):
2886         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
2887         (-[AccessibilityObjectWrapper accessibilityParameterizedAttributeNames]):
2888         (-[AccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]):
2889
2890 2008-08-19  Steve Falkenburg  <sfalken@apple.com>
2891
2892         Build fix.
2893         Add buildfailed support to stop builds early (preventing inaccurate error messages).
2894         Add missing post-build rule to Release.
2895
2896         * WebCore.vcproj/QTMovieWin.vcproj:
2897
2898 2008-08-19  Keishi Hattori  <casey.hattori@gmail.com>
2899
2900         Added support for console.count in the inspector.
2901
2902         Reviewed by Geoff Garen.
2903
2904         * page/Console.cpp:
2905         (WebCore::Console::count):
2906         * page/Console.h:
2907         * page/Console.idl: Added console.count.
2908         * page/InspectorController.cpp:
2909         (WebCore::InspectorController::didCommitLoad): Clears m_counts.
2910         (WebCore::InspectorController::count): Updates the count number
2911         sing "title@source:line" as the identifier, and adds a
2912         message to the console.
2913         * page/InspectorController.h: Added m_counts.
2914
2915 2008-08-19  Keishi Hattori  <casey.hattori@gmail.com>
2916
2917         Clear console.time timers when changing page.
2918
2919         Reviewed by Geoff Garen.
2920
2921         * page/InspectorController.cpp:
2922         (WebCore::InspectorController::didCommitLoad):
2923
2924 2008-08-19  Eric Carlson  <eric.carlson@apple.com>
2925
2926         Reviewed by Adele.
2927
2928         Fix for <rdar://problem/6154695> Full-page movies flicker while playing
2929         https://bugs.webkit.org/show_bug.cgi?id=20404
2930
2931         Ignore setVisible() when visibility doesn't change.
2932
2933         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
2934         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
2935         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
2936         (WebCore::MediaPlayerPrivate::setVisible):
2937
2938 2008-08-19  Timothy Hatcher  <timothy@apple.com>
2939
2940         Fixes a bug in the Profile view where switching sort order, then
2941         switching from heavy to tree mode would show the tree in the
2942         previous sort order.
2943
2944         https://bugs.webkit.org/show_bug.cgi?id=20441
2945
2946         Reviewed by Kevin McCullough.
2947
2948         * page/inspector/ProfileView.js:
2949         (WebInspector.ProfileView.prototype._changeView): Call _sortProfile
2950         on the next profile before assigning it to this.profile.
2951         (WebInspector.ProfileView.prototype._sortData): Call _sortProfile.
2952         (WebInspector.ProfileView.prototype._sortProfile): Moves from
2953         _sortData and takes a profile argument. If the profile passed in
2954         matches the this.profile, then call refresh.
2955
2956 2008-08-18  Timothy Hatcher  <timothy@apple.com>
2957
2958         Changed the default sort order now that heavy view is the default.
2959         Also fixes a bug where the heavy profile was not sorted at first.
2960
2961         https://bugs.webkit.org/show_bug.cgi?id=20440
2962
2963         Reviewed by Kevin McCullough.
2964
2965         * page/inspector/ProfileView.js:
2966         (WebInspector.ProfileView): Changed the default sort column. Also assign
2967         heavyProfile to profile, so the sortSelfTimeDescending call happens
2968         on the heavy profile before assigning to this.profile.
2969
2970 2008-08-18  Timothy Hatcher  <timothy@apple.com>
2971
2972         Add support for editing DOM properties and scope variables by double
2973         clicking a property to enter edit mode.
2974
2975         https://bugs.webkit.org/show_bug.cgi?id=20415
2976
2977         Reviewed by Kevin McCullough.
2978
2979         * page/inspector/ObjectPropertiesSection.js:
2980         (WebInspector.ObjectPropertiesSection): Set editable to true by default.
2981         (WebInspector.ObjectPropertiesSection.prototype.onpopulate):
2982         Factored out code into update, and calls update.
2983         (WebInspector.ObjectPropertiesSection.prototype.update): Moved from onpopulate.
2984         Call removeChildren since this method can be called multiple times now.
2985         (WebInspector.ObjectPropertyTreeElement): Pass an empty title, the title
2986         gets made later in onattach.
2987         (WebInspector.ObjectPropertyTreeElement.prototype.onpopulate): Don't return early
2988         if shouldRefreshChildren is true. Call removeChildren since this method can be
2989         called multiple times now.
2990         (WebInspector.ObjectPropertyTreeElement.prototype.ondblclick): Call startEditing.
2991         (WebInspector.ObjectPropertyTreeElement.prototype.onattach): Call update.
2992         (WebInspector.ObjectPropertyTreeElement.prototype.update): Update the title for
2993         this element (code moved from the constructor.)
2994         (WebInspector.ObjectPropertyTreeElement.prototype.updateSiblings): Recreate all
2995         sibling property elements.
2996         (WebInspector.ObjectPropertyTreeElement.prototype.startEditing): Call
2997         WebInspector.startEditing after rememebring some context.
2998         (WebInspector.ObjectPropertyTreeElement.prototype.editingEnded): Reset the scrollLeft
2999         for the list element, since it might have scrolled during editing.
3000         (WebInspector.ObjectPropertyTreeElement.prototype.editingCancelled): Call editingEnded
3001         then restore the state from the context. Then call update to restore the title.
3002         (WebInspector.ObjectPropertyTreeElement.prototype.editingCommitted): Call editingCancelled
3003         if the user input and the previous input are the same. Call editingEnded, then call applyExpression
3004         to commit the user input.
3005         (WebInspector.ObjectPropertyTreeElement.prototype.applyExpression): Evaluates the input expression
3006         and stores the result on the object for the property name of this element. If the expression is
3007         empty, delete the property and remove the tree element.
3008         * page/inspector/ScopeChainSidebarPane.js:
3009         (WebInspector.ScopeChainSidebarPane.prototype.update): Set the editInSelectedCallFrameWhenPaused
3010         property on each ObjectPropertiesSection.
3011         (WebInspector.ScopeVariableTreeElement.prototype.onattach): Call ObjectPropertyTreeElement's onattach
3012         since it is now implemented.
3013         * page/inspector/ScriptsPanel.js:
3014         (WebInspector.ScriptsPanel.prototype.evaluateInSelectedCallFrame): Added an updateInterface argument
3015         that defaults to true if omitted. It specifies whether to call update on the scope chain.
3016         * page/inspector/inspector.css: New styles.
3017         * page/inspector/treeoutline.js:
3018         (TreeElement.prototype._attach): Fixed an exception that fired when handling the shouldRefreshChildren
3019         change. The nextSibling would exist but have a _listItemNode that didn't match the new parent.
3020
3021 2008-08-18  Timothy Hatcher  <timothy@apple.com>
3022
3023         Surround the expression to be evaluated in parenthesis so the
3024         result of the eval is the result of the whole expression not
3025         the last potential sub-expression. So evaluating {x: 123}
3026         will show the Object not 123.
3027
3028         https://bugs.webkit.org/show_bug.cgi?id=20428
3029
3030         Reviewed by Kevin McCullough.
3031
3032         * page/inspector/Console.js:
3033         (Console.prototype._evalInInspectedWindow): Add parenthesis
3034         around the expression. And add couple comments.
3035
3036 2008-08-19 Kevin McCullough <kmccullough@apple.com>
3037
3038         Reviewed by Geoff.
3039
3040         -Implement a page() function to extract a common code pattern.
3041
3042         * WebCore.xcodeproj/project.pbxproj:
3043         * page/Console.cpp:
3044         (WebCore::Console::addMessage):
3045         (WebCore::Console::error):
3046         (WebCore::Console::info):
3047         (WebCore::Console::log):
3048         (WebCore::Console::dir):
3049         (WebCore::Console::assertCondition):
3050         (WebCore::Console::time):
3051         (WebCore::Console::timeEnd):
3052         (WebCore::Console::group):
3053         (WebCore::Console::groupEnd):
3054         (WebCore::Console::finishedProfiling):
3055         (WebCore::Console::warn):
3056         (WebCore::Console::framePage):
3057         * page/Console.h:
3058
3059 2008-08-12  Darin Adler  <darin@apple.com>
3060
3061         Reviewed by Geoff.
3062
3063         - eliminate JSValue::type()
3064
3065         * bridge/c/c_instance.cpp:
3066         (KJS::Bindings::CInstance::defaultValue): Take PreferredPrimitiveType
3067         argument instead of JSType argument. Removed unneeded code to handle
3068         boolean, since that's never passed.
3069         * bridge/c/c_instance.h: Ditto.
3070
3071         * bridge/c/c_utility.cpp:
3072         (KJS::Bindings::convertValueToNPVariant): Use JSValue::is functions
3073         instead of JSValue::type(). Removed unneeded code to handle
3074         "unspecified".
3075
3076         * bridge/jni/jni_instance.cpp:
3077         (JavaInstance::defaultValue): Take PreferredPrimitiveType argument
3078         instead of JSType argument. Removed unneeded code to handle boolean.
3079         * bridge/jni/jni_instance.h: Ditto.
3080
3081         * bridge/jni/jni_jsobject.mm:
3082         (JavaJSObject::convertValueToJObject): Use JSValue::is functions
3083         instead of JSValue::type().
3084
3085         * bridge/objc/objc_instance.h: Take PreferredPrimitiveType argument
3086         instead of JSType argument. Removed unused argument.
3087         * bridge/objc/objc_instance.mm:
3088         (ObjcInstance::getValueOfUndefinedField): Removed unused argument.
3089         (ObjcInstance::defaultValue): Take PreferredPrimitiveType argument
3090         instead of JSType argument. Removed unneeded code to handle boolean
3091         and another dead code path for unknown types.
3092
3093         * bridge/objc/objc_runtime.h: Take PreferredPrimitiveType argument
3094         instead of JSType argument. Removed override of type() that caused
3095         the fallback object to return "UndefinedType" when there is no
3096         invokeUndefinedMethodFromWebScript:withArguments: method defined.
3097         That didn't accomplish much, since most checks for undefined don't
3098         ever call type().
3099         * bridge/objc/objc_runtime.mm:
3100         (ObjcFallbackObjectImp::defaultValue): Ditto.
3101
3102         * bridge/qt/qt_instance.cpp:
3103         (KJS::Bindings::QtInstance::defaultValue): Take PreferredPrimitiveType
3104         argument instead of JSType argument. Removed unneeded code to handle
3105         boolean.
3106         * bridge/qt/qt_instance.h: Ditto.
3107
3108         * bridge/runtime.h:
3109         (KJS::Bindings::Instance::getValueOfUndefinedField): Removed
3110         unsed argument.
3111         * bridge/runtime_object.cpp:
3112         (RuntimeObjectImp::defaultValue): Take PreferredPrimitiveType
3113         argument instead of JSType argument.
3114         * bridge/runtime_object.h: Ditto.
3115
3116 2008-08-18  Maxime Britto  <britto@apple.com>
3117
3118         Reviewed by Adele.
3119
3120         <rdar://6157207> Mouse pointer does not change when new window is opened after pan-scrolling original window
3121         Related to the discussion from rdar://6102511 , we should disable every key event (except for the esc key which stops the panning).
3122         We shouldn't be able to create another window while we are in pan scrolling.
3123         Other browsers behaviors :
3124           FF3 : Most of the keys are disabled, there is no way to create another window while in panscroll mode
3125           IE7 : Keys are not disabled but stops immediately the panning.
3126         This patch matches FF3 behavior by disabling every key but the esc key.
3127
3128         * page/EventHandler.cpp:
3129         (WebCore::EventHandler::stopAutoscrollTimer): Change the cursor back to the regular arrow cursor when the pannning is stopped.
3130         (WebCore::EventHandler::keyEvent): When a key event is received while in panning or autoscroll we swallow the event early.
3131
3132 2008-08-18  Dan Bernstein  <mitz@apple.com>
3133
3134         Reviewed by Dave Hyatt.
3135
3136         - fix <rdar://problem/5862634> REGRESSION (3.1.1): In iChat, inline image not resizable past current size after another IM is received
3137
3138         Test: fast/replaced/max-width-percent.html
3139
3140         Added an includeMaxWidth boolean to RenderBox::calcReplaedWidth().
3141         When false, max-width is not factored into the
3142         calculation.
3143         Changed RenderReplaced and subclasses' calcPrefWidths() to call
3144         calcReplacedWidth(false) and then apply max-width only if it has a
3145         fixed, positive value.
3146
3147         * rendering/RenderBox.cpp:
3148         (WebCore::RenderBox::calcReplacedWidth):
3149         * rendering/RenderBox.h:
3150         * rendering/RenderImage.cpp:
3151         (WebCore::RenderImage::calcReplacedWidth):
3152         (WebCore::RenderImage::calcPrefWidths): 
3153         * rendering/RenderImage.h:
3154         * rendering/RenderReplaced.cpp:
3155         (WebCore::RenderReplaced::calcPrefWidths):
3156         * rendering/RenderSVGRoot.cpp:
3157         (WebCore::RenderSVGRoot::calcPrefWidths):
3158         * rendering/RenderVideo.cpp:
3159         (WebCore::RenderVideo::calcReplacedWidth):
3160         (WebCore::RenderVideo::calcPrefWidths):
3161         * rendering/RenderVideo.h:
3162
3163 2008-08-18  Daniel Macks  <dmacks@netspace.org>
3164
3165         Reviewed by Mark Rowe.
3166
3167         https://bugs.webkit.org/show_bug.cgi?id=20410
3168         More portable/self-documenting replacement for SIZE_MAX.
3169
3170         * platform/network/curl/FormDataStreamCurl.cpp:
3171         (WebCore::FormDataStream::read):
3172
3173 2008-08-18  Simon Fraser  <simon.fraser@apple.com>
3174
3175         Reviewed by Dave Hyatt
3176
3177         Need to make sure we have an Animation in the AnimationList
3178         before setting the initial value.
3179         https://bugs.webkit.org/show_bug.cgi?id=20408
3180
3181         Test: fast/css/transition_shorthand_parsing.html
3182
3183         * css/CSSStyleSelector.cpp:
3184
3185 2008-08-18  Kevin McCullough  <kmccullough@apple.com>
3186
3187         Reviewed by Tim.
3188
3189         <rdar://problem/6150593> JSProfiler: Empty profiles disappear when there
3190         is another profile.
3191
3192         * page/inspector/ProfilesPanel.js:
3193
3194 2008-08-18  Kevin McCullough  <kmccullough@apple.com>
3195
3196         Reviewed by Geoff.
3197
3198         <rdar://problem/6150642> REGRESSION: Closing the Web Inspector clears
3199         all console messages
3200
3201         * page/inspector/Console.js:
3202
3203 2008-08-18  Dirk Schulze  <vbs85@gmx.de>
3204
3205         Reviewed by Eric Seidel.
3206
3207         Fixed Canvas for Cairo. Stroke and fill colors didn't work after
3208         the canvas clean up.
3209
3210         https://bugs.webkit.org/show_bug.cgi?id=20405
3211
3212         * html/CanvasRenderingContext2D.cpp:
3213         (WebCore::CanvasRenderingContext2D::fill):
3214         (WebCore::CanvasRenderingContext2D::stroke):
3215         (WebCore::CanvasRenderingContext2D::fillRect):
3216
3217 2008-08-17  Timothy Hatcher  <timothy@apple.com>
3218
3219         Complete in scope variables in the Console when paused.
3220
3221         https://bugs.webkit.org/show_bug.cgi?id=19115
3222
3223         Reviewed by Geoffrey Garen.
3224
3225         * page/inspector/Console.js:
3226         (WebInspector.Console.prototype.completions): If the expressionString
3227         is null or empty and the debugger is paused, call variablesInScopeForSelectedCallFrame
3228         to get an object that declares all the in scope variables. That way
3229         "top level" expressions are completed.
3230         * page/inspector/ScriptsPanel.js:
3231         (WebInspector.ScriptsPanel.prototype.variablesInScopeForSelectedCallFrame):
3232         Return an object that has all the variables that are in scope for the
3233         selected call frame. The value of each property is just true.
3234         The return object is useful for quick lookups or auto completion.
3235
3236 2008-08-17  Cameron Zwarich  <cwzwarich@uwaterloo.ca>
3237
3238         Not reviewed.
3239
3240         Speculative Qt build fix.
3241
3242         * bridge/qt/qt_runtime.cpp:
3243         (KJS::Bindings::convertValueToQVariant):
3244         (KJS::Bindings::QtRuntimeMethod::QtRuntimeMethod):
3245
3246 2008-08-17  Geoffrey Garen  <ggaren@apple.com>
3247
3248         Reviewed by Cameron Zwarich.
3249         
3250         Updated project files to XCode 3.1.
3251
3252         * manual-tests/NPN_Invoke/NPN_Invoke.xcodeproj/project.pbxproj:
3253
3254 2008-08-17  Geoffrey Garen  <ggaren@apple.com>
3255
3256         Reviewed by Cameron Zwarich.
3257
3258         Made room for a free word in JSCell.
3259         
3260         Changed JSDOMWindowBase to store its auxiliary data in a subclass of
3261         JSGlobalData, so the two could share a pointer.
3262         
3263         Added a bunch of ASSERTs, to help catch over-sized objects.
3264
3265 2008-08-15  Mark Rowe  <mrowe@apple.com>
3266
3267         Reviewed by Dan Bernstein.
3268
3269         Disable dead code stripping in debug builds.
3270
3271         * Configurations/Base.xcconfig:
3272         * WebCore.xcodeproj/project.pbxproj:
3273
3274 2008-08-15  Mark Rowe  <mrowe@apple.com>
3275
3276         Rubber-stamped by Geoff Garen.
3277
3278         <rdar://problem/6139914> Please include a _debug version of JavaScriptCore framework
3279
3280         * Configurations/Base.xcconfig: Factor out the debug-only settings so that they can shared
3281         between the Debug configuration and debug Production variant.
3282         * WebCore.xcodeproj/project.pbxproj: Enable the debug variant.
3283
3284 2008-08-15  Antti Koivisto  <antti@apple.com>
3285
3286         Reviewed by Anders.
3287
3288         Don't start preloading body resources before the head is complete. This prevents
3289         body preloads from slowing down initial display when there is limited amount
3290         of bandwidth available.
3291         
3292         Works by queuing up found body preloads to DocLoader and only issuing them
3293         after document has rendering.
3294         
3295         With bandwidth capped to 300kbit/s this speeds up cnn.com initial display by ~25% or 5s
3296         without affecting complete load time.
3297
3298         * html/PreloadScanner.cpp:
3299         (WebCore::PreloadScanner::PreloadScanner):
3300         (WebCore::PreloadScanner::scanningBody):
3301         (WebCore::PreloadScanner::emitTag):
3302         (WebCore::PreloadScanner::emitCSSRule):
3303         * html/PreloadScanner.h:
3304         * loader/DocLoader.cpp:
3305         (WebCore::DocLoader::preload):
3306         (WebCore::DocLoader::checkForPendingPreloads):
3307         (WebCore::DocLoader::requestPreload):
3308         * loader/DocLoader.h:
3309         * loader/loader.cpp:
3310         (WebCore::Loader::Host::didFinishLoading):
3311         (WebCore::Loader::Host::didFail):
3312
3313 2008-08-15  Ada Chan  <adachan@apple.com>
3314
3315         Use item's computed style if the render style is 0 before falling back to the <select>'s style.
3316         This way style set on an <hr> within a <select> will be honored.
3317
3318         Reviewed by Dave Hyatt and Dan Bernstein.
3319
3320         * rendering/RenderMenuList.cpp:
3321         (WebCore::RenderMenuList::itemStyle):
3322
3323 2008-08-15  Antti Koivisto  <antti@apple.com>
3324
3325         Reviewed by Oliver.
3326
3327         Some loader performance tweaks:
3328         - Make stylesheets highest priority instead of scripts. We block script execution on stylesheets.
3329           Especially if a stylesheet @imports other stylesheets it is important to get them to the front of the queue 
3330           to not delay rendering.
3331         - Issue the first resource load for a host immediately even if the resource is low priority. TCP connection setup
3332           can take long time when latency is high so it is good to get started early.
3333         - When the document is fully parsed and stylesheets have been loaded there is no need to keep managing the
3334           load queues. Issue remaining loads to the network layer.
3335
3336         * loader/loader.cpp:
3337         (WebCore::Loader::determinePriority):
3338         (WebCore::Loader::load):
3339         (WebCore::Loader::Host::servePendingRequests):
3340         * loader/loader.h:
3341
3342 2008-08-15  Timothy Hatcher  <timothy@apple.com>
3343
3344         Detach the script debugger when the Web Inspector's window closes.
3345         This has always been the intended design, but never fully implemented.
3346
3347         https://bugs.webkit.org/show_bug.cgi?id=20402
3348
3349         Reviewed by Adam Roben.
3350
3351         * page/InspectorController.cpp:
3352         (WebCore::InspectorController::setWindowVisible): Call stopDebugging()
3353         if the window is no longer visible.
3354
3355 2008-08-15  Håvard Wall  <hwall@trolltech.com>
3356
3357         Reviewed by Simon.
3358
3359         Fixes:    compile with QT_NO_CONTEXTMENU
3360
3361         * platform/qt/PlatformMouseEventQt.cpp:
3362         (WebCore::PlatformMouseEvent::PlatformMouseEvent):
3363         * platform/qt/PlatformScrollBarQt.cpp:
3364         (WebCore::PlatformScrollbar::handleMouseMoveEvent):
3365         (WebCore::PlatformScrollbar::handleContextMenuEvent):
3366
3367 2008-08-15  Håvard Wall  <hwall@trolltech.com>
3368
3369         Reviewed by Simon.
3370
3371         Fixes: compile with QT_NO_WHEELEVENT
3372
3373         * platform/qt/WheelEventQt.cpp:
3374         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
3375
3376 2008-08-15  Keishi Hattori  <casey.hattori@gmail.com>
3377
3378         Fixed Bug 20210: Console groups are incorrect when closing and reopening the Inspector
3379
3380         https://bugs.webkit.org/show_bug.cgi?id=20210
3381
3382         Reviewed by Tim Hatcher.
3383
3384         * page/Console.cpp:
3385         (WebCore::Console::group):
3386         (WebCore::Console::groupEnd):
3387         * page/Console.h:
3388         (WebCore::): Removed GroupTitleMessageLevel. Added StartGroupMessaageLevel and EndGroupMessageLevel.
3389         * page/InspectorController.cpp:
3390         (WebCore::InspectorController::startGroup): Increments group level by
3391         one and adds console message with StartGroupMessaageLevel.
3392         (WebCore::InspectorController::endGroup): Decrements group level by one
3393         and adds console message with EndGroupMessaageLevel.
3394         * page/InspectorController.h:
3395         * page/inspector/Console.js:
3396         (WebInspector.Console.prototype.addMessage): Creates new ConsoleGroup
3397         if the message is StartGroupMessaageLevel.
3398         (WebInspector.ConsoleMessage.prototype.toMessageElement):
3399         (WebInspector.ConsoleGroup.prototype.addMessage):
3400         * page/inspector/inspector.js:
3401
3402 2008-08-15  Keishi Hattori  <casey.hattori@gmail.com>
3403
3404         Adds support for console.dir to the Inspector
3405
3406         https://bugs.webkit.org/show_bug.cgi?id=19155
3407
3408         Reviewed by Tim Hatcher.
3409
3410         * bindings/js/JSConsoleCustom.cpp:
3411         (WebCore::JSConsole::dir):
3412         * page/Console.cpp:
3413         (WebCore::Console::dir):
3414         * page/Console.h: Added ObjectMessageLevel.
3415         * page/Console.idl: Added console.dir.
3416         * page/inspector/Console.js:
3417         (WebInspector.ConsoleMessage.prototypet.toMessageElement): Creates an
3418         ObjectPropertiesSection if the MessageLevel is Object.
3419         * page/inspector/ObjectPropertiesSection.js: "in" operator can't be
3420         used on primitive data types.
3421         * page/inspector/inspector.css:
3422
3423 2008-08-15  Keishi Hattori  <casey.hattori@gmail.com>
3424
3425         Adds support for clear() in the Inspector console.
3426
3427         https://bugs.webkit.org/show_bug.cgi?id=19873
3428
3429         Reviewed by Tim Hatcher.
3430
3431         * page/inspector/Console.js:
3432
3433 2008-08-15  Anthony Ricaud  <rik24d@gmail.com>
3434
3435         Cmd-F on Mac or Ctrl-F on other platforms now focus the search field.
3436
3437         Platform distinction and modifier key matching adjusted
3438         by Daniel Jalkut <jalkut@red-sweater.com>
3439
3440         Bug 16313: text search (find) keybindings should work in the Web Inspector
3441         https://bugs.webkit.org/show_bug.cgi?id=16313
3442
3443         Reviewed by Tim Hatcher.
3444
3445         * page/inspector/inspector.js: Added a case for the F key
3446
3447 2008-08-15  Keishi Hattori  <casey.hattori@gmail.com>
3448
3449         Fix for error when the string doesn't contain a webkit-profile link.
3450
3451         https://bugs.webkit.org/show_bug.cgi?id=20399
3452
3453         Reviewed by Tim Hatcher.
3454
3455         * page/inspector/inspector.js:
3456
3457 2008-08-15  Timothy Hatcher  <timothy@apple.com>
3458
3459         Fixes two bugs where JavaScript could be executed from the page
3460         while the debugger is paused.
3461
3462         The first issue was JSLazyEventListener not checking the paused
3463         state before parsing the code.
3464
3465         The second issue was with the PageGroup version of
3466         JavaScriptDebugServer::setJavaScriptPaused always passing false
3467         to the Page version of JavaScriptDebugServer::setJavaScriptPaused,
3468         and not the paused argument.
3469
3470         https://bugs.webkit.org/show_bug.cgi?id=20284
3471
3472         Reviewed by Adam Roben.
3473
3474         * bindings/js/JSEventListener.cpp:
3475         (WebCore::JSLazyEventListener::parseCode): Check the paused
3476         state of the ScriptController. Return early if paused.
3477         * manual-tests/inspector/debugger-execution-while-paused.html: Added.
3478         * page/JavaScriptDebugServer.cpp:
3479         (WebCore::JavaScriptDebugServer::setJavaScriptPaused):
3480         Pass the paused argument to the Page version of setJavaScriptPaused.
3481
3482 2008-08-15  Alexey Proskuryakov  <ap@webkit.org>
3483
3484         Reviewed by Geoff Garen.
3485
3486         JSStringRef is created context-free, but can get linked to one via an identifier table,
3487         breaking an implicit API contract.
3488
3489         * page/InspectorController.cpp:
3490         (WebCore::jsStringRef):
3491         (WebCore::InspectorController::didParseSource):
3492         (WebCore::InspectorController::failedToParseSource):
3493         * page/JavaScriptProfile.cpp:
3494         (WebCore::getTitleCallback):
3495         Updated for JavaScriptCore changes.
3496
3497 2008-08-14  Kevin Ollivier  <kevino@theolliviers.com>
3498
3499         wx !USE(WXGC) build fix. This is necessary until we find a way to replace GDI with
3500         an alternative that performs reasonably well. (GDI+ is too slow in many cases.)
3501
3502         * platform/graphics/AffineTransform.h:
3503
3504 2008-08-14  Eric Carlson  <eric.carlson@apple.com>
3505
3506         Reviewed by Adele.
3507
3508         Fix for https://bugs.webkit.org/show_bug.cgi?id=20388
3509         <video> elements on Windows never becomes visible when a page is restored from the cache
3510
3511         Always pass "set" calls down to MediaPlayerPrivate instead of only when the
3512         value is different from the cached value. Let the implementation decide when
3513         to avoid work because nothing has changed.
3514
3515         * platform/graphics/MediaPlayer.cpp:
3516         (WebCore::MediaPlayer::setVolume):
3517         (WebCore::MediaPlayer::setRate):
3518         (WebCore::MediaPlayer::setRect):
3519         (WebCore::MediaPlayer::setVisible):
3520
3521 2008-08-14  Keishi Hattori  <casey.hattori@gmail.com>
3522
3523         Make Firebug command line API respect predefined variables.
3524
3525         https://bugs.webkit.org/show_bug.cgi?id=20385
3526
3527         Reviewed by Tim Hatcher.
3528
3529         * page/inspector/Console.js:
3530
3531 2008-08-14  Sam Weinig  <sam@webkit.org>
3532
3533         Reviewed by Geoffrey Garen and Timothy Hatcher.
3534
3535         Allow programatically setting the HTMLTokenizers time delay and chunk size
3536         which are used for determining how aggressively we yield.
3537
3538         * WebCore.base.exp:
3539         * html/HTMLTokenizer.cpp:
3540         (WebCore::HTMLTokenizer::begin):
3541         (WebCore::HTMLTokenizer::continueProcessing):
3542         * html/HTMLTokenizer.h:
3543         * page/Page.cpp:
3544         (WebCore::Page::Page):
3545         (WebCore::Page::setCustomHTMLTokenizerTimeDelay):
3546         (WebCore::Page::setCustomHTMLTokenizerChunkSize):
3547         * page/Page.h:
3548         (WebCore::Page::hasCustomHTMLTokenizerTimeDelay):
3549         (WebCore::Page::customHTMLTokenizerTimeDelay):
3550         (WebCore::Page::hasCustomHTMLTokenizerChunkSize):
3551         (WebCore::Page::customHTMLTokenizerChunkSize):
3552
3553 2008-08-14  Eric Seidel  <eric@webkit.org>
3554
3555         Reviewed by Beth.
3556
3557         Move us one step closer to cross-platform svg/graphics code
3558
3559         * WebCore.xcodeproj/project.pbxproj:
3560         * html/CanvasStyle.cpp:
3561         * platform/graphics/Color.cpp:
3562         (WebCore::colorWithOverrideAlpha):
3563         * platform/graphics/Color.h:
3564         * svg/graphics/cg/CgSupport.cpp:
3565         (WebCore::applyStrokeStyleToContext):
3566         (WebCore::strokeBoundingBox):
3567         * svg/graphics/cg/SVGPaintServerSolidCg.cpp:
3568         (WebCore::SVGPaintServerSolid::setup):
3569
3570 2008-08-14  Eric Seidel  <eric@webkit.org>
3571
3572         Reviewed by Alexey.
3573
3574         Remove un-need includes from HTMLCanvas and use the
3575         Gradient platform abstraction in one place in CanvasStyle
3576
3577         * html/CanvasRenderingContext2D.cpp:
3578         (WebCore::CanvasRenderingContext2D::fillRect):
3579         * html/CanvasStyle.cpp:
3580         * html/HTMLCanvasElement.cpp:
3581
3582 2008-08-14  Eric Seidel  <eric@webkit.org>
3583
3584         Reviewed by Alexey.
3585
3586         Clean up GlyphBuffer.h, removing more #ifdefs
3587
3588         * platform/graphics/GlyphBuffer.h:
3589         (WebCore::GlyphBuffer::glyphAt):
3590         (WebCore::GlyphBuffer::advanceAt):
3591         (WebCore::GlyphBuffer::add):
3592
3593 2008-08-14  Eric Seidel  <eric@webkit.org>
3594
3595         Reviewed by Sam.
3596
3597         Clean up AffineTransform.h, removing #ifdefs
3598
3599         * platform/graphics/AffineTransform.h:
3600         * platform/graphics/cairo/AffineTransformCairo.cpp:
3601         * platform/graphics/cg/AffineTransformCG.cpp:
3602         * platform/graphics/qt/AffineTransformQt.cpp:
3603         * platform/graphics/wx/AffineTransformWx.cpp:
3604
3605 2008-08-14  Dan Bernstein  <mitz@apple.com>
3606
3607         - fix non-CG builds by adding an ImageSource::frameSizeAtIndex() that returns size().
3608
3609         * platform/graphics/cairo/ImageSourceCairo.cpp:
3610         (WebCore::ImageSource::frameSizeAtIndex):
3611         * platform/graphics/qt/ImageSourceQt.cpp:
3612         (WebCore::ImageSource::frameSizeAtIndex):
3613         * platform/graphics/wx/ImageSourceWx.cpp:
3614         (WebCore::ImageSource::frameSizeAtIndex):
3615
3616 2008-08-14  Dan Bernstein  <mitz@apple.com>
3617
3618         Reviewed by Brady Eidson.
3619
3620         - fix <rdar://problem/5993323> REGRESSION (r34210): Apple.com favicon appears stretched/clipped
3621
3622         * platform/graphics/BitmapImage.cpp: 
3623         (WebCore::BitmapImage::BitmapImage): Added initialization of
3624         m_hasUniformFrameSize.
3625         (WebCore::BitmapImage::cacheFrame): Added code to get the size of the
3626         cached frame for use in decoded size computation and for setting
3627         m_hasUniformFrameSize.
3628         (WebCore::BitmapImage::currentFrameSize): Added.
3629         (WebCore::BitmapImage::dataChanged): Added code to reset
3630         m_hasUniformFrameSize.
3631         * platform/graphics/BitmapImage.h: Added currentFrameSize() and
3632         m_hasUniformFrameSize.
3633         * platform/graphics/ImageSource.h: Added frameSizeAtIndex().
3634         * platform/graphics/cg/ImageCG.cpp:
3635         (WebCore::BitmapImage::draw): Changed to use currentFrameSize(). This
3636         fixes the bug, which resulted from assuming that the frame being drawn 
3637         was the same size as the first frame.
3638         * platform/graphics/cg/ImageSourceCG.cpp:
3639         (WebCore::ImageSource::frameSizeAtIndex): Renamed size() to this and
3640         changed to get the size of the frame at the given index.
3641         (WebCore::ImageSource::size): Added. Returns frameSizeAtIndex(0).
3642
3643 2008-08-13  Simon Fraser  <simon.fraser@apple.com>
3644
3645         Reviewed by Eric Seidel
3646
3647         Fix @font-face inside @media rule crash.
3648         https://bugs.webkit.org/show_bug.cgi?id=20367
3649
3650         Test: fast/css/font-face-in-media-rule.html
3651
3652         * css/CSSStyleSelector.cpp:
3653         (WebCore::CSSRuleSet::addRulesFromSheet):
3654
3655 2008-08-14  Kevin Ollivier  <kevino@theolliviers.com>
3656
3657         wx build fixes after recent changes to Canvas and Image classes.
3658
3659         * platform/graphics/Pattern.h:
3660         * platform/graphics/wx/GradientWx.cpp:
3661         (WebCore::Gradient::fill):
3662         * platform/graphics/wx/GraphicsContextWx.cpp:
3663         (WebCore::GraphicsContext::applyFillPattern):
3664         (WebCore::GraphicsContext::applyStrokePattern):
3665         * platform/graphics/wx/ImageBufferWx.cpp:
3666         (WebCore::ImageBuffer::image):
3667         * platform/graphics/wx/ImageWx.cpp:
3668         (WebCore::Image::loadPlatformResource):
3669
3670 2008-08-14  Maxime Britto  <britto@apple.com>
3671
3672         Reviewed by Sam Weinig.
3673
3674         rdar://6102511
3675         When pan-scrolling, typing on the keyboard should either stop the pan scroll or be ignored
3676         IE and FF are both preventing the keyboard event to interact with the page while scrolling.
3677         Some differences exist between them concerning the kind of key which is pressed :
3678         IE7 : every key leads to a stop of the panning
3679         FF3 : the ESC and TAB keys leads to a stop, the other keys are inactive.
3680         For WebKit this patch is adopting the FF3 behavior except for the TAB key which is inactive too.
3681
3682         * page/EventHandler.cpp:
3683         (WebCore::EventHandler::keyEvent): Verifies which key has been hit and decide either to stop the pan scroll or to swallow the key event.
3684
3685 2008-08-14  Christian Dywan  <christian@twotoasts.de>
3686
3687         Gtk+/ Cairo build fix, patch by Dirk Schulze.
3688
3689         * html/CanvasStyle.cpp:
3690         * platform/graphics/cairo/PatternCairo.cpp:
3691         (WebCore::Pattern::createPlatformPattern):
3692         * svg/graphics/cairo/SVGResourceMaskerCairo.cpp:
3693
3694 2008-08-14  Kevin McCullough  <kmccullough@apple.com>
3695
3696         Reviewed by Tim.
3697
3698         <rdar://problem/6115819> Notify of profile in console
3699
3700         * page/InspectorController.cpp:
3701         (WebCore::InspectorController::addProfile):
3702         (WebCore::InspectorController::addProfileMessageToConsole): Called by
3703         addProfile this is the function that adds a message to the console that
3704         a profile finished.
3705         * page/InspectorController.h:
3706         * page/JavaScriptProfile.cpp: Expose the profiler's unique ID to match
3707         the console log to the profile in the web inspector.
3708         (WebCore::getUniqueIdCallback):
3709         (WebCore::ProfileClass):
3710         * page/inspector/ProfilesPanel.js: Created a map of all the profiles by
3711         Id to bring up the requested profile.  Also select and reveal the
3712         profile in the profile panel.  And created displayTitleForProfileLink()
3713         which formats a title taking into account if it's user initiated or if
3714         there are multiples. Lasty, I put the user initiated profile in a
3715         variable.
3716         * page/inspector/inspector.js: Make the profile title be a clickable
3717         link that will take the user to the identified profile.  Also expose
3718         the count of user initiated profiles so they can be displayed in the
3719         console with the correct count.
3720
3721 2008-08-14  Timothy Hatcher  <timothy@apple.com>
3722
3723         Avoid formating ConsoleMessages twice unless the message will be
3724         displayed in bubbles of a SourceFrame.
3725
3726         Reviewed by Kevin McCullough.
3727
3728         * page/inspector/Console.js:
3729         (WebInspector.ConsoleMessage): Only format the plain text message
3730         if the URL and line are valid and the level is error or warning.
3731         (WebInspector.ConsoleMessage.prototype.isErrorOrWarning): Added.
3732         Helper to test for error or warning level.
3733         * page/inspector/SourceFrame.js:
3734         (WebInspector.SourceFrame.prototype.addMessage): Don't add the
3735         message if there is no message or valid line or if the msg
3736         isn't an error or warning.
3737
3738 2008-08-14  Jan Michael Alonzo  <jmalonzo@webkit.org>
3739
3740         partial Gtk build fix, not reviewed
3741
3742         * platform/graphics/cairo/PatternCairo.cpp:
3743
3744 2008-08-13  Sam Weinig  <sam@webkit.org>
3745
3746         Reviewed by Anders Carlson.
3747
3748         Fix style issue.
3749
3750         * html/HTMLMediaElement.cpp:
3751         (WebCore::HTMLMediaElement::pickMedia):
3752
3753 2008-08-13  Nikolas Zimmermann  <zimmermann@kde.org>
3754
3755         Build fix for Cairo, not reviewed. (exposed by gtk build slave)
3756         Continue Erics build fixes, after the Image cleanup.
3757
3758         * platform/graphics/cairo/ImageBufferCairo.cpp:
3759         (WebCore::ImageBuffer::image):
3760
3761 2008-08-13  Nikolas Zimmermann  <zimmermann@kde.org>
3762
3763         Build fix for Qt, not reviewed.
3764         Don't declare eventuallyMarkAsParserCreated in a block wrapped by !USE_QXMLSTREAM.
3765
3766         * dom/XMLTokenizer.cpp:
3767         (WebCore::eventuallyMarkAsParserCreated): Was erre
3768
3769 2008-08-13  Nikolas Zimmermann  <zimmermann@kde.org>
3770
3771         Build fix, not reviewed.
3772         Add ScriptElement.cpp to Gtk build.
3773
3774         * GNUmakefile.am:
3775
3776 2008-08-13  Nikolas Zimmermann  <zimmermann@kde.org>
3777
3778         Reviewed by Eric.
3779
3780         Fixes: https://bugs.webkit.org/show_bug.cgi?id=20372
3781
3782         Refactor HTMLScriptElement's code into a common base class: ScriptElement.
3783         SVGScriptElement will be converted to use ScriptElement in a follow-up patch.
3784
3785         This resolves code duplications and allows us to completly replace the old
3786         SVGScriptElement (which doesn't use CachedScript, no dynamic injected scripts etc..)
3787
3788         As ScriptElement, doesn't actually inherit from Element, we may want to rename
3789         it, though StyleElement uses the same naming convention, so I left it as is for now.
3790         Eventually we'll rename both files in future.
3791
3792         No functional changes yet, as SVGScriptElement doesn't yet use the new base class.
3793
3794         * WebCore.pro: Add new ScriptElement.cpp to build.
3795         * WebCore.vcproj/WebCore.vcproj: Ditto.
3796         * WebCore.xcodeproj/project.pbxproj: Ditto.
3797         * WebCoreSources.bkl: Dutto.
3798         * dom/ScriptElement.cpp: Added. 1:1 based on HTMLScriptElement
3799         (WebCore::ScriptElement::insertedIntoDocument):
3800         (WebCore::ScriptElement::removedFromDocument):
3801         (WebCore::ScriptElement::childrenChanged):
3802         (WebCore::ScriptElement::finishParsingChildren):
3803         (WebCore::ScriptElement::handleSourceAttribute):
3804         (WebCore::isSupportedJavaScriptLanguage):
3805         (WebCore::ScriptElementData::ScriptElementData):
3806         (WebCore::ScriptElementData::~ScriptElementData):
3807         (WebCore::ScriptElementData::requestScript):
3808         (WebCore::ScriptElementData::evaluateScript):
3809         (WebCore::ScriptElementData::stopLoadRequest):
3810         (WebCore::ScriptElementData::notifyFinished):
3811         (WebCore::ScriptElementData::ignoresLoadRequest):
3812         (WebCore::ScriptElementData::shouldExecuteAsJavaScript):
3813         (WebCore::ScriptElementData::scriptCharset):
3814         (WebCore::ScriptElementData::scriptContent):
3815         * dom/ScriptElement.h: Added.
3816         (WebCore::ScriptElement::ScriptElement):
3817         (WebCore::ScriptElement::~ScriptElement):
3818         (WebCore::ScriptElementData::element):
3819         (WebCore::ScriptElementData::createdByParser):
3820         (WebCore::ScriptElementData::setCreatedByParser):
3821         * dom/XMLTokenizer.cpp:
3822         (WebCore::isScriptElement):
3823         (WebCore::castToScriptElement):
3824         (WebCore::eventuallyMarkAsParserCreated):
3825         (WebCore::XMLTokenizer::startElementNs):
3826         (WebCore::XMLTokenizer::endElementNs):
3827         (WebCore::createXHTMLParserErrorHeader):
3828         (WebCore::XMLTokenizer::insertErrorMessageBlock):
3829         * html/HTMLScriptElement.cpp: Refactored code, pushed most code down to ScriptElement.
3830         (WebCore::HTMLScriptElement::HTMLScriptElement):
3831         (WebCore::HTMLScriptElement::~HTMLScriptElement):
3832         (WebCore::HTMLScriptElement::isURLAttribute):
3833         (WebCore::HTMLScriptElement::setCreatedByParser):
3834         (WebCore::HTMLScriptElement::shouldExecuteAsJavaScript):
3835         (WebCore::HTMLScriptElement::childrenChanged):
3836         (WebCore::HTMLScriptElement::parseMappedAttribute):
3837         (WebCore::HTMLScriptElement::finishParsingChildren):
3838         (WebCore::HTMLScriptElement::insertedIntoDocument):
3839         (WebCore::HTMLScriptElement::removedFromDocument):
3840         (WebCore::HTMLScriptElement::text):
3841         (WebCore::HTMLScriptElement::setText):
3842         (WebCore::HTMLScriptElement::setHtmlFor):
3843         (WebCore::HTMLScriptElement::setEvent):
3844         (WebCore::HTMLScriptElement::charset):
3845         (WebCore::HTMLScriptElement::src):
3846         (WebCore::HTMLScriptElement::type):
3847         (WebCore::HTMLScriptElement::scriptCharset):
3848         (WebCore::HTMLScriptElement::scriptContent):
3849         (WebCore::HTMLScriptElement::sourceAttributeValue):
3850         (WebCore::HTMLScriptElement::charsetAttributeValue):
3851         (WebCore::HTMLScriptElement::typeAttributeValue):
3852         (WebCore::HTMLScriptElement::languageAttributeValue):
3853         (WebCore::HTMLScriptElement::dispatchLoadEvent):
3854         (WebCore::HTMLScriptElement::dispatchErrorEvent):
3855         * html/HTMLScriptElement.h:
3856         * svg/SVGScriptElement.cpp: Inherit from ScriptElement, don't actually use it yet.
3857         * svg/SVGScriptElement.cpp:
3858         (WebCore::SVGScriptElement::SVGScriptElement):
3859         (WebCore::SVGScriptElement::scriptContent):
3860         (WebCore::SVGScriptElement::sourceAttributeValue):
3861         (WebCore::SVGScriptElement::charsetAttributeValue):
3862         (WebCore::SVGScriptElement::typeAttributeValue):
3863         (WebCore::SVGScriptElement::languageAttributeValue):
3864         (WebCore::SVGScriptElement::dispatchLoadEvent):
3865         (WebCore::SVGScriptElement::dispatchErrorEvent):
3866         * svg/SVGScriptElement.h:
3867         (WebCore::SVGScriptElement::setCreatedByParser):
3868
3869 2008-08-13  Eric Seidel  <eric@webkit.org>
3870
3871         Attempt to fix the Gtk build, no review.
3872
3873         I removed the bogus GraphicsContext::translatePoint() hack for Gtk in the process.
3874
3875         * platform/graphics/GraphicsContext.h:
3876         * platform/graphics/cairo/GraphicsContextCairo.cpp:
3877         * platform/graphics/qt/GradientQt.cpp:
3878         * platform/graphics/qt/GraphicsContextQt.cpp:
3879         * platform/gtk/RenderThemeGtk.cpp:
3880         (WebCore::paintMozWidget):
3881
3882 2008-08-13  Eric Seidel  <eric@webkit.org>
3883
3884         Yet another attempt to fix the Qt build, no review.
3885
3886         * platform/graphics/qt/GradientQt.cpp:
3887         * platform/graphics/qt/GraphicsContextQt.cpp:
3888         (WebCore::GraphicsContext::applyStrokePattern):
3889         (WebCore::GraphicsContext::applyFillPattern):
3890
3891 2008-08-13  Eric Seidel  <eric@webkit.org>
3892
3893         Attempt to fix the Windows build, no review.
3894
3895         * platform/win/CursorWin.cpp:
3896         (WebCore::loadCursorByName):
3897         * platform/win/ScrollViewWin.cpp:
3898         (WebCore::ScrollView::paint):
3899
3900 2008-08-13  Eric Seidel  <eric@webkit.org>
3901
3902         Attempt to fix the Windows build, no review.
3903
3904         * platform/win/CursorWin.cpp:
3905         (WebCore::loadCursorByName):
3906         * platform/win/ScrollViewWin.cpp:
3907         (WebCore::ScrollView::paint):
3908
3909 2008-08-13  Eric Seidel  <eric@webkit.org>
3910
3911         Attempt to fix the Qt build, no review.
3912
3913         * platform/graphics/qt/ImageBufferQt.cpp:
3914         (WebCore::ImageBuffer::image):
3915
3916 2008-08-13  Eric Seidel  <eric@webkit.org>
3917
3918         Attempt to fix the Windows build, no review.
3919
3920         * platform/graphics/win/ImageWin.cpp:
3921         (WebCore::Image::loadPlatformResource):
3922         * plugins/win/PluginViewWin.cpp:
3923         (WebCore::PluginView::paintMissingPluginIcon):
3924
3925 2008-08-13  Eric Seidel  <eric@webkit.org>
3926
3927         Another attempt to fix the Qt build, no review.
3928
3929         * platform/graphics/qt/ImageQt.cpp:
3930         * platform/graphics/qt/StillImageQt.h:
3931
3932 2008-08-13  Eric Seidel  <eric@webkit.org>
3933
3934         No review, build fix only.
3935
3936         Fix mac build, due to change in new code since my patch was written.
3937
3938         * svg/graphics/cg/SVGResourceMaskerCg.mm:
3939         (WebCore::SVGResourceMasker::applyMask):
3940
3941 2008-08-13  Eric Seidel  <eric@webkit.org>
3942
3943         Build fix only, no review.
3944
3945         Attempt to fix the Qt build.
3946
3947         * platform/graphics/qt/ImageBufferQt.cpp:
3948         * platform/graphics/qt/StillImageQt.h:
3949         (WebCore::StillImage::create):
3950         (WebCore::StillImage::destroyDecodedData):
3951         (WebCore::StillImage::decodedSize):
3952
3953 2008-08-13  Eric Seidel  <eric@webkit.org>
3954
3955         Build fix only, no review.
3956
3957         Attempt to fix the Qt build.
3958
3959         * html/CanvasStyle.cpp:
3960         (WebCore::CanvasStyle::applyStrokeColor):
3961         (WebCore::CanvasStyle::applyFillColor):
3962
3963 2008-08-13  Eric Seidel  <eric@webkit.org>
3964
3965         Reviewed by Sam.
3966
3967         Match HTML5 spec by throwing INVALID_STATE_ERR when
3968         createPattern is called and the HTMLImageElement is not
3969         yet done loading the image (!isComplete)
3970         https://bugs.webkit.org/show_bug.cgi?id=20351
3971
3972         Test: http/misc/canvas-pattern-from-incremental-image.html
3973
3974         * html/CanvasRenderingContext2D.cpp:
3975         (WebCore::CanvasRenderingContext2D::createPattern):
3976
3977 2008-08-13  Eric Seidel  <eric@webkit.org>
3978
3979         Reviewed by Niko.
3980
3981         Split out a Pattern class from CanvasPattern
3982         and remove all the Pattern-related #ifdefs
3983         (This will break non-mac platforms!  I will fix them.)
3984         https://bugs.webkit.org/show_bug.cgi?id=20351
3985
3986         * GNUmakefile.am:
3987         * WebCore.pro:
3988         * WebCore.vcproj/WebCore.vcproj:
3989         * WebCore.xcodeproj/project.pbxproj:
3990         * WebCoreSources.bkl:
3991         * html/CanvasPattern.cpp:
3992         (WebCore::CanvasPattern::parseRepetitionType):
3993         (WebCore::CanvasPattern::CanvasPattern):
3994         * html/CanvasPattern.h:
3995         (WebCore::CanvasPattern::create):
3996         (WebCore::CanvasPattern::pattern):
3997         (WebCore::CanvasPattern::originClean):
3998         * html/CanvasRenderingContext2D.cpp:
3999         (WebCore::CanvasRenderingContext2D::createPattern):
4000         (WebCore::CanvasRenderingContext2D::applyStrokePattern):
4001         (WebCore::CanvasRenderingContext2D::applyFillPattern):
4002         * html/CanvasRenderingContext2D.h:
4003         * html/HTMLCanvasElement.cpp:
4004         * html/HTMLCanvasElement.h:
4005         * loader/FrameLoader.cpp:
4006         (WebCore::FrameLoader::createHistoryItem):
4007         * platform/graphics/GraphicsContext.h:
4008         * platform/graphics/cairo/GraphicsContextCairo.cpp:
4009         (WebCore::GraphicsContext::applyStrokePattern):
4010         (WebCore::GraphicsContext::applyFillPattern):
4011         * platform/graphics/cg/GraphicsContextCG.cpp:
4012         (WebCore::GraphicsContext::clipToImageBuffer):
4013         (WebCore::GraphicsContext::applyStrokePattern):
4014         (WebCore::GraphicsContext::applyFillPattern):
4015
4016 2008-08-13  Eric Seidel  <eric@webkit.org>
4017
4018         Reviewed by Niko.
4019
4020         Make Images RefCounted (and clean up callers)
4021         https://bugs.webkit.org/show_bug.cgi?id=20351
4022
4023         * editing/DeleteButtonController.cpp:
4024         (WebCore::DeleteButtonController::createDeletionUI):
4025         * loader/CachedImage.cpp:
4026         (WebCore::CachedImage::CachedImage):
4027         (WebCore::brokenImage):
4028         (WebCore::nullImage):
4029         (WebCore::CachedImage::image):
4030         (WebCore::CachedImage::notifyObservers):
4031         (WebCore::CachedImage::createImage):
4032         * loader/CachedImage.h:
4033         * loader/icon/IconRecord.cpp:
4034         (WebCore::IconRecord::setImageData):
4035         (WebCore::IconRecord::loadImageFromResource):
4036         * loader/icon/IconRecord.h:
4037         * platform/graphics/BitmapImage.h:
4038         (WebCore::BitmapImage::create):
4039         * platform/graphics/GeneratedImage.h:
4040         * platform/graphics/Gradient.cpp:
4041         * platform/graphics/Gradient.h:
4042         * platform/graphics/Image.cpp:
4043         (WebCore::Image::nullImage):
4044         * platform/graphics/Image.h:
4045         * platform/graphics/ImageBuffer.h:
4046         * platform/graphics/cairo/ImageBufferCairo.cpp:
4047         (WebCore::ImageBuffer::image):
4048         * platform/graphics/cg/ImageBufferCG.cpp:
4049         (WebCore::ImageBuffer::image):
4050         (WebCore::ImageBuffer::getImageData):
4051         (WebCore::ImageBuffer::putImageData):
4052         * platform/graphics/cg/PDFDocumentImage.h:
4053         (WebCore::PDFDocumentImage::create):
4054         (WebCore::PDFDocumentImage::destroyDecodedData):
4055         (WebCore::PDFDocumentImage::decodedSize):
4056         * platform/graphics/gtk/ImageGtk.cpp:
4057         (WebCore::Image::loadPlatformResource):
4058         * platform/graphics/mac/ImageMac.mm:
4059         (WebCore::Image::loadPlatformResource):
4060         * rendering/RenderImage.cpp:
4061         * rendering/RenderLayer.cpp:
4062         (WebCore::RenderLayer::paintOverflowControls):
4063         * svg/graphics/SVGImage.cpp:
4064         (WebCore::SVGImage::nativeImageForCurrentFrame):
4065         * svg/graphics/SVGImage.h:
4066         (WebCore::SVGImage::create):
4067         (WebCore::SVGImage::destroyDecodedData):
4068         (WebCore::SVGImage::decodedSize):
4069         (WebCore::SVGImage::frameAtIndex):
4070         * svg/graphics/cairo/SVGPaintServerPatternCairo.cpp:
4071         (WebCore::SVGPaintServerPattern::setup):
4072         * svg/graphics/cairo/SVGResourceMaskerCairo.cpp:
4073         (WebCore::SVGResourceMasker::applyMask):
4074         * svg/graphics/cg/SVGPaintServerPatternCg.cpp:
4075         (WebCore::patternCallback):
4076         * svg/graphics/cg/SVGResourceMaskerCg.mm:
4077         (WebCore::SVGResourceMasker::applyMask):
4078
4079 2008-08-13  Eric Seidel  <eric@webkit.org>
4080
4081         Reviewed by Niko.
4082
4083         Remove #ifdefs from CanvasStyle by using platform/Color.h
4084         https://bugs.webkit.org/show_bug.cgi?id=20351
4085
4086         There are some down-sides to this commit.
4087         This commit limits us to 255 levels of grey for calls like:
4088         context.setStrokeStyle(.37, 1.0)
4089         previously CG might have used up to 32bits to store the grey level
4090         Since setStrokeStyle is not part of HTML5, I don't suspect the web will notice.
4091
4092         Likewise, setStrokeStyle/setFillStyle calls which used float colors are now limited
4093         to RGBA32 (like all the rest of colors in WebCore), thus:
4094         context.setStrokStyle(.37, .24, .456, .99) will now have the same precision as:
4095         context.strokeStyle = "rgba(.37, .24, .456, .99)", which is to say RGBA32
4096
4097         If this is a problem for Dashboard, we can either roll out this commit
4098         or add a beefier Color abstraction, which can be used internally by GraphicsContext
4099         when keeping state, and then GraphicsContext can grow some additional set* routines
4100         for setting the a grey/float/whatever fill and stroke.
4101
4102         * html/CanvasRenderingContext2D.cpp:
4103         (WebCore::CanvasRenderingContext2D::setFillStyle):
4104         * html/CanvasStyle.cpp:
4105         (WebCore::CanvasStyle::CanvasStyle):
4106         (WebCore::colorWithOverrideAlpha):
4107         (WebCore::CanvasStyle::applyStrokeColor):
4108         (WebCore::CanvasStyle::applyFillColor):
4109         * html/CanvasStyle.h:
4110         * platform/graphics/Color.cpp:
4111         (WebCore::colorFloatToRGBAByte):
4112         (WebCore::makeRGBA32FromFloats):
4113         * platform/graphics/Color.h:
4114
4115 2008-08-13  Eric Carlson  <eric.carlson@apple.com>
4116
4117         Reviewed by Adele Peterson.
4118
4119         Fix for <rdar://problem/6137931>
4120         https://bugs.webkit.org/show_bug.cgi?id=20360
4121         Remove all parameters from the MIME type before checking with the MIME type registry
4122
4123         Tests: media/video-source-type-params.html
4124
4125         * html/HTMLMediaElement.cpp:
4126         (WebCore::HTMLMediaElement::pickMedia): only pass the portion before the first ';' 
4127         to isSupportedMediaMIMEType()
4128
4129 2008-08-13  Beth Dakin  <bdakin@apple.com>
4130
4131         Reviewed by Sam Weinig.
4132
4133         Fix for <rdar://problem/6141345>
4134
4135         This patch refines findString and markAllMatchesForText functions' 
4136         interactions with disconnected frames. They no longer rely on 
4137         knowing where a range is relative to the visible region and work 
4138         with disconnected frames that contain frames.
4139
4140         * editing/Editor.cpp:
4141         (WebCore::Editor::insideVisibleArea): Now returns a bool instead of 
4142         the visiblity enum.
4143         (WebCore::Editor::firstVisibleRange): This now returns the very 
4144         first visible range in the document. It's no longer dependent on 
4145         searching forward.
4146         (WebCore::Editor::lastVisibleRange): This now returns the very last 
4147         visible range in the document. It's no longer dependent on 
4148         searching backwards.
4149         (WebCore::Editor::nextVisibleRange): This returns the next visible 
4150         range in the appropriate direction from the current range.
4151         * editing/Editor.h:
4152         * page/Frame.cpp:
4153         (WebCore::Frame::findString):
4154         (WebCore::Frame::markAllMatchesForText):
4155
4156 2008-08-13  Kevin Ollivier  <kevino@theolliviers.com>
4157
4158         wx build fix for case-sensitive platforms, like Linux.
4159
4160         * WebCoreSources.bkl:
4161
4162 2008-08-13  Marco Barisione  <marco.barisione@collabora.co.uk>
4163
4164         Reviewed by Holger Freyther.
4165
4166         http://bugs.webkit.org/show_bug.cgi?id=16881
4167         [GTK] PlatformScreenGtk is unimplemented
4168
4169         Original patch by Christian Dywan.
4170
4171         * platform/gtk/PlatformScreenGtk.cpp:
4172         (WebCore::screenDepth):
4173         (WebCore::screenDepthPerComponent):
4174         (WebCore::screenIsMonochrome):
4175         (WebCore::screenRect):
4176         (WebCore::screenAvailableRect):
4177
4178 2008-08-13  Jan Michael Alonzo  <jmalonzo@webkit.org>
4179
4180         Reviewed by Holger Freyther.
4181
4182         http://bugs.webkit.org/show_bug.cgi?id=20318
4183         SharedTimerGtk should use G_PRIORITY_DEFAULT_IDLE for g_idle_add
4184
4185         g_idle_add is the same as g_idle_add_full with a priority of
4186         G_PRIORITY_DEFAULT_IDLE, so we can safely use that.
4187
4188         * platform/gtk/SharedTimerGtk.cpp:
4189         (WebCore::setSharedTimerFireTime):
4190
4191 2008-08-13  Timothy Hatcher  <timothy@apple.com>
4192
4193         Changed the InspectorController so it can be notified when the
4194         attached state of the Inspector changes in WebKit.
4195
4196         Reviewed by Kevin McCullough.
4197
4198         * WebCore.base.exp: Updated the symbol for setWindowVisible.
4199         * page/InspectorController.cpp:
4200         (WebCore::InspectorController::setWindowVisible): Added an attached argument,
4201         that defaults to false.Call setAttachedWindow with the attached argument.
4202         (WebCore::InspectorController::setAttachedWindow): Call the script version
4203         of setAttachedWindow.
4204         * page/InspectorController.h:
4205         * page/inspector/inspector.js:
4206         (WebInspector.setAttachedWindow): Set the attached property.
4207
4208 2008-08-12  Timothy Hatcher  <timothy@apple.com>
4209
4210         Added a close button to the Inspector's toolbar when docked.
4211
4212         https://bugs.webkit.org/show_bug.cgi?id=14270
4213
4214         Reviewed by Kevin McCullough.
4215
4216         * page/InspectorController.cpp:
4217         (WebCore::closeWindow): Call InspectorController::closeWindow.
4218         (WebCore::InspectorController::windowScriptObjectAvailable):
4219         Added closeWindow to the script class.
4220         * page/InspectorController.h:
4221         * page/inspector/Images/closeButtons.png: Added.
4222         * page/inspector/inspector.css: Added and changed styles.
4223         * page/inspector/inspector.html: Added the close button.
4224         * page/inspector/inspector.js:
4225         (WebInspector.loaded): Added click event listener to the close button.
4226         (WebInspector.close): Call InspectorController.closeWindow.
4227
4228 2008-08-12  Timothy Hatcher  <timothy@apple.com>
4229
4230         Make the docked Web Inspector resizable. This is the cross platform
4231         portion of the code. Each InspectorClient needs to implement the
4232         real resize code.
4233
4234         https://bugs.webkit.org/show_bug.cgi?id=14282
4235
4236         Reviewed by Kevin McCullough.
4237
4238         * loader/EmptyClients.h: Added an empty setAttachedWindowHeight.
4239         * page/InspectorClient.h: Added setAttachedWindowHeight.
4240         * page/InspectorController.cpp:
4241         (WebCore::setAttachedWindowHeight): Call setAttachedWindowHeight
4242         on the InspectorController.
4243         (WebCore::InspectorController::setAttachedWindowHeight): Call
4244         setAttachedWindowHeight on the client.
4245         (WebCore::InspectorController::windowScriptObjectAvailable):
4246         Added setAttachedWindowHeight to the script class.
4247         * page/InspectorController.h:
4248         * page/inspector/inspector.css: Make the cursor on the toolbar be
4249         row-resize when docked.
4250         * page/inspector/inspector.js:
4251         (WebInspector.loaded): Always add the toolbarDragStart event listener.
4252         (WebInspector.toolbarDragStart): Return early if we are not attached
4253         and not on Leopard. Call WebInspector.elementDragStart.
4254         (WebInspector.toolbarDragEnd): Call WebInspector.elementDragEnd.
4255         (WebInspector.toolbarDrag): When attached call setAttachedWindowHeight,
4256         otherwise call moveByUnrestricted.
4257
4258 2008-08-13  Simon Hausmann  <hausmann@webkit.org>
4259
4260         Reviewed by Holger.
4261
4262         Initialize m_zoomsTextOnly in the Settings constructor.
4263
4264         * page/Settings.cpp:
4265         (WebCore::Settings::Settings):
4266
4267 2008-08-13  Brad Hughes <bhughes@trolltech.com>
4268
4269         Reviewed by Simon.
4270
4271         Fix compiling of QtWebKit in release mode with the Intel C++ Compiler for Linux
4272
4273         The latest upgrade of the intel compiler allows us to compile all of
4274         Qt with optimizations enabled (yay!).
4275
4276         * WebCore.pro:
4277
4278 2008-08-13  Prasanth Ullattil  <prasanth.ullattil@trolltech.com>
4279
4280         Reviewed by Simon.
4281
4282         Fix QtWebKit not displaying content on 403 HTTP responses
4283
4284         Just like with 404 responses also display content with 403, as