2009-03-12 Xan Lopez <xlopez@igalia.com>
[WebKit-https.git] / WebCore / ChangeLog
1 2009-03-12  Xan Lopez  <xlopez@igalia.com>
2
3         Reviewed by Alexey Proskuryakov.
4
5         https://bugs.webkit.org/show_bug.cgi?id=24544
6         Rename setUrl to setURL
7
8         Use proper case for setUrl method, rename it to setURL.
9
10         * platform/network/ResourceResponseBase.cpp:
11         (WebCore::ResourceResponseBase::adopt):
12         * platform/network/ResourceResponseBase.h:
13         * platform/network/curl/ResourceHandleManager.cpp:
14         (WebCore::writeCallback):
15         (WebCore::headerCallback):
16         * platform/network/soup/ResourceHandleSoup.cpp:
17         (WebCore::fillResponseFromMessage):
18         (WebCore::queryInfoCallback):
19
20 2009-03-12  Xan Lopez  <xlopez@igalia.com>
21
22         Reviewed by Alexey Proskuryakov.
23
24         https://bugs.webkit.org/show_bug.cgi?id=24519
25         [GTK] Use two argument KURL ctor in ResourceHandleSoup
26
27         Use two argument KURL ctor, the single argument ctor expects its
28         input to be the output of a previous KURL::parse call, which is
29         not the case here.
30
31         * platform/network/soup/ResourceHandleSoup.cpp:
32         (WebCore::fillResponseFromMessage):
33         (WebCore::queryInfoCallback):
34
35 2009-03-11  Jon Honeycutt  <jhoneycutt@apple.com>
36
37         Fix for <rdar://6418681>
38         https://bugs.webkit.org/show_bug.cgi?id=22644
39
40         Reviewed by Steve Falkenburg.
41
42         * plugins/win/PluginPackageWin.cpp:
43         (WebCore::PluginPackage::isPluginBlacklisted): Add the Citrix ICA
44         Client plug-in to the blacklist; it requires a Mozilla-based browser.
45
46 2009-03-12  Oliver Hunt  <oliver@apple.com>
47
48         Reviewed by NOBODY (build fix).
49
50         build fix.
51
52         * html/CanvasRenderingContext2D.h:
53
54 2009-03-11  Oliver Hunt  <oliver@apple.com>
55
56         Reviewed by Adele Peterson.
57
58         <rdar://problem/6673852> Widget "Simple World Clock" does not display with Safari 4
59
60         A number of dashboard widgets rely on canvas failing silently when given invalid
61         colors for gradient stops, but both the spec and firefox throw exceptions here.
62         So we work around this by creating a dashboard quirk that will only suppress the
63         exception in dashboard compatibility mode.
64
65         Test: fast/canvas/canvas-gradient-addStop-error.html
66
67         * html/CanvasGradient.cpp:
68         (WebCore::CanvasGradient::CanvasGradient):
69         (WebCore::CanvasGradient::addColorStop):
70         * html/CanvasGradient.h:
71         (WebCore::CanvasGradient::setDashboardCompatibilityMode):
72         * html/CanvasRenderingContext2D.cpp:
73         (WebCore::CanvasRenderingContext2D::prepareGradientForDashboard):
74         (WebCore::CanvasRenderingContext2D::createLinearGradient):
75         (WebCore::CanvasRenderingContext2D::createRadialGradient):
76         * html/CanvasRenderingContext2D.h:
77
78 2009-03-11  David Kilzer  <ddkilzer@apple.com>
79
80         Clarify comments regarding order of FEATURE_DEFINES
81
82         Rubber-stamped by Mark Rowe.
83
84         * Configurations/WebCore.xcconfig: Added warning about the
85         consequences when FEATURE_DEFINES are not kept in sync.
86
87 2009-03-11  Gustavo Noronha Silva  <gns@gnome.org>
88
89         Reviewed by Holger Freyther.
90
91         https://bugs.webkit.org/show_bug.cgi?id=24515
92         [GTK] soup backend should use GMappedFile instead of mmap directly
93
94         Rewrite mmap code used to upload files to use GMappedFile, so that
95         it is platform-independent.
96
97         * platform/network/soup/ResourceHandleSoup.cpp:
98         (WebCore::ResourceHandle::startHttp):
99
100 2009-03-11  Dan Bernstein  <mitz@apple.com>
101
102         Reviewed by Darin Adler.
103
104         - WebCore part of fixing <rdar://problem/3919124> Thai text selection
105           in Safari is incorrect
106
107         Test: platform/mac/editing/selection/word-thai.html
108
109         Tested on Mac, but should work on all ICU platforms (or more precisely
110         on all platforms that implement
111         WTF::Unicode::hasLineBreakingPropertyComplexContext() correctly).
112
113         * editing/TextIterator.cpp:
114         (WebCore::BackwardsCharacterIterator::BackwardsCharacterIterator):
115         Added.
116         (WebCore::BackwardsCharacterIterator::range): Added.
117         (WebCore::BackwardsCharacterIterator::advance): Added.
118
119         * editing/TextIterator.h: Added BackwardsCharacterIterator with the
120         minimal functionality required for this patch.
121         (WebCore::BackwardsCharacterIterator::atEnd): Added.
122
123         * editing/visible_units.cpp:
124         (WebCore::firstNonComplexContextLineBreak): Added this helper function
125         that returns the index of the first character in the string whose
126         Unicode line breaking property value is not SA ("Complex Context"), or
127         the length of the string if there is no such character.
128         (WebCore::lastNonComplexContextLineBreak): Added this helper function
129         that returns the index of the last character in the string whose
130         Unicode line breaking property value is not SA ("Complex Context"), or
131         -1 if there is no such character.
132         (WebCore::previousBoundary): Changed the signature of the search
133         function to include an offset parameter. Renamed the 'exception' local
134         variable to 'ec' and changed its type to ExceptionCode. Extend the
135         string forwards until the first character with Unicode line breaking
136         property value other than SA. This gives the boundary search function
137         enough context in the forward direction. Changed to use a
138         BackwardsCharacterIterator for translating the backwards offset into
139         a position.
140         (WebCore::nextBoundary): Changed the signature of the search
141         function to include an offset parameter. Extend the string backwards
142         until the first character with Unicode line breaking property value
143         other than SA. This gives the boundary search function enough context in
144         the backwards direction. Restricted the workaround for <rdar://5192593>
145         only to the line break case, because it was causing an extra character
146         to be selected following a word that ended with a combining mark.
147         (WebCore::startWordBoundary): Added an offset parameter. Check that
148         going backwards from the given offset, there is a character with Unicode
149         line breaking property value other than SA, and otherwise return 0 to
150         request more context.
151         (WebCore::endWordBoundary): Similar, but in reverse.
152         (WebCore::previousWordPositionBoundary): Similar.
153         (WebCore::nextWordPositionBoundary): Similar.
154         (WebCore::startSentenceBoundary): Updated for the new search function
155         signature.
156         (WebCore::endSentenceBoundary): Ditto.
157         (WebCore::previousSentencePositionBoundary): Ditto.
158         (WebCore::nextSentencePositionBoundary): Ditto.
159
160 2009-03-11  Darin Adler  <darin@apple.com>
161
162         Reviewed by Mark Rowe.
163
164         Don't use "::" in thread names because it is ugly!
165
166         * loader/icon/IconDatabase.cpp:
167         (WebCore::IconDatabase::open): Use "WebCore: " instead of "WebCore::".
168         * platform/network/cf/ResourceHandleCFNet.cpp:
169         (WebCore::ResourceHandle::loaderRunLoop): Call this "WebCore: CFNetwork Loader" to make
170         it clear this is a WebCore-created thread.
171         * storage/DatabaseThread.cpp:
172         (WebCore::DatabaseThread::start): Use "WebCore: " instead of "WebCore::".
173         * storage/LocalStorageThread.cpp:
174         (WebCore::LocalStorageThread::start): Use "WebCore: " instead of "WebCore::".
175         * workers/WorkerThread.cpp:
176         (WebCore::WorkerThread::start): Use "WebCore: " instead of "WebCore::".
177
178 2009-03-11  Mark Rowe  <mrowe@apple.com>
179
180         Rubber-stamped by Darin Adler.
181
182         <rdar://problem/6653286> WebCore's implementation of screenIsMonochrome is needlessly complex
183
184         * platform/mac/PlatformScreenMac.mm:
185         (WebCore::screenIsMonochrome): Return false.
186
187 2009-03-11  Beth Dakin  <bdakin@apple.com>
188
189         Reviewed by Dan Bernstein.
190
191         Fix for https://bugs.webkit.org/show_bug.cgi?id=14749 percentage 
192         top value on position:relative child not calculated correctly if 
193         parent has percentage height
194         - and corresponding -
195         <rdar://problem/6172925>
196
197         * rendering/RenderBoxModelObject.cpp:
198         (WebCore::RenderBoxModelObject::relativePositionOffsetY):
199
200 2009-03-11  Jian Li  <jianli@chromium.org>
201
202         Reviewed by Dimitri Glazkov.
203
204         Implement ScriptValue::hasNoValue for V8.
205         https://bugs.webkit.org/show_bug.cgi?id=24507
206
207         * bindings/v8/ScriptValue.h:
208         (WebCore::ScriptValue::hasNoValue):
209
210 2009-03-11  David Levin  <levin@chromium.org>
211
212         Reviewed by Dimitri Glazkov.
213
214         Bug 24459: Add v8 bindings for event.
215         <https://bugs.webkit.org/show_bug.cgi?id=24459>
216
217         Adding custom event bindings.
218
219         * bindings/v8/custom/V8AbstractEventListener.cpp: Added.
220         * bindings/v8/custom/V8AbstractEventListener.h: Added.
221         * bindings/v8/custom/V8AttrCustom.cpp:
222         Fixed messed up copyright header.
223         * bindings/v8/custom/V8CustomEventListener.cpp: Added.
224         * bindings/v8/custom/V8CustomEventListener.h:
225         Replaced forwarding header with the real implementation.
226         * bindings/v8/custom/V8ElementCustom.cpp:
227         * bindings/v8/custom/V8LazyEventListener.cpp: Added.
228         * bindings/v8/custom/V8LazyEventListener.h: Added.
229         * bindings/v8/custom/V8ObjectEventListener.cpp: Added.
230         * bindings/v8/custom/V8ObjectEventListener.h: Added.
231         * bindings/v8/custom/V8WorkerContextEventListener.cpp: Added.
232         * bindings/v8/custom/V8WorkerContextEventListener.h: Added.
233
234 2009-03-11  Darin Fisher  <darin@chromium.org>
235
236         Reviewed by Dimitri Glazkov.
237
238         https://bugs.webkit.org/show_bug.cgi?id=24521
239         Add some missing includes for the non-JSC build.
240
241         * platform/text/PlatformString.h: added OwnPtr.h
242         * xml/XMLHttpRequest.cpp: added SecurityOrigin.h
243
244 2009-03-11  Simon Fraser  <simon.fraser@apple.com>
245
246         Reviewed by Darin Adler
247
248         https://bugs.webkit.org/show_bug.cgi?id=24531
249         
250         Make sure that AnimationControllerPrivate::getAnimatedStyleForRenderer() never
251         returns a null style if it has a valid renderer, which could happen if a
252         CompositeAnimation existed, but wasn't running any animations or transitions.
253
254         * page/animation/AnimationController.cpp:
255         (WebCore::AnimationControllerPrivate::getAnimatedStyleForRenderer):
256
257 2009-03-11  Simon Fraser  <simon.fraser@apple.com>
258
259         Fix Scons build. Patch from Alexander Guy.
260
261         * WebCore.scons:
262
263 2009-03-11  Simon Fraser  <simon.fraser@apple.com>
264
265         Reviewed by Dan Bernstein
266        
267         https://bugs.webkit.org/show_bug.cgi?id=23093
268         
269         When the cancel button in the search field is shown or hidden,
270         we need to explicitly setStyle() on the cancel button's renderer,
271         to ensure that repaint happens. Changing the style without telling
272         the renderer won't work.
273
274         Test: fast/repaint/search-field-cancel.html
275
276         * rendering/RenderTextControlSingleLine.cpp:
277         (WebCore::RenderTextControlSingleLine::subtreeHasChanged):
278         (WebCore::RenderTextControlSingleLine::updateFromElement):
279         (WebCore::RenderTextControlSingleLine::createCancelButtonStyle):
280         (WebCore::RenderTextControlSingleLine::updateCancelButtonVisibility):
281         (WebCore::RenderTextControlSingleLine::visibilityForCancelButton):
282         * rendering/RenderTextControlSingleLine.h:
283
284 2009-03-11  Hironori Bono  <hbono@chromium.org>
285
286         Reviewed by Alexey Proskuryakov.
287
288         https://bugs.webkit.org/show_bug.cgi?id=15790
289         Ligatures aren't accounted for when manipulating VisiblePositions
290
291         Changed cursorMovementIterator rules to prevent a cursor from moving in the middle of an
292         Indic ligature which uses a virama sign.
293         
294         Test: editing/deleting/skip-virama-001.html
295
296         * platform/text/TextBreakIteratorICU.cpp:
297         (WebCore::cursorMovementIterator):
298
299 2009-03-11  Alexey Proskuryakov  <ap@webkit.org>
300
301         Reviewed by George Staikos.
302
303         https://bugs.webkit.org/show_bug.cgi?id=24513
304         REGRESSION: Cursor movement doesn't work on Tiger (ICU 3.2)
305
306         Fixes existing tests on Tiger.
307
308         * platform/text/TextBreakIteratorICU.cpp: (WebCore::cursorMovementIterator):
309         Use characterBreakIterator on Tiger (like we used to do).
310
311 2009-03-11  Alexey Proskuryakov  <ap@webkit.org>
312
313         Reviewed by Oliver Hunt.
314
315         <rdar://problem/4072827> Downloaded non-ASCII file name becomes garbled
316
317         * platform/network/mac/ResourceRequestMac.mm:
318         (WebCore::ResourceRequest::doUpdatePlatformRequest): Correct selector name
319         in instancesRespondToSelector.
320
321 2009-03-11  Jan Michael Alonzo  <jmalonzo@webkit.org>
322
323         Reviewed by Holger Freyther.
324
325         [GTK]DumpRenderTree doesn't compile for non-X11 GTK ports anymore
326         https://bugs.webkit.org/show_bug.cgi?id=2260
327
328         Add missing stdio.h include to get the build going
329
330         * plugins/gtk/PluginPackageGtk.cpp:
331
332 2009-03-10  Justin Garcia  <justin.garcia@apple.com>
333
334         Reviewed by Ken Kocienda.
335
336         * dom/Range.cpp:
337         (WebCore::Range::addLineBoxRects): If the range ended at [div, 0], addLineBoxRects
338         would include rects for the divs contents.  Set the correct RenderObject to stop at.
339
340 2009-03-10  Alexey Proskuryakov  <ap@webkit.org>
341
342         Reviewed by Sam Weinig.
343
344         <rdar://problem/6123770> Restrict access to document.cookie when making a cross-site XHR
345
346         * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::responseXML): Removed an incorrect
347         comment about cookie support. Firefox doesn't expose cookies on responseXML at all, and
348         there are security concerns with exposing them for cross-origin requests, so it's not clear
349         if we want to change anything here.
350
351 2009-03-10  Simon Fraser  <simon.fraser@apple.com>
352
353         Reviewed by Darin Adler
354
355         https://bugs.webkit.org/show_bug.cgi?id=24503
356         
357         Fix hit testing of absolutely positioned single line text controls by
358         ensuring that we set result.innerNode() correctly. If the hit node is
359         a descendant of the inner text element or if it is the <input> itself,
360         then we say we hit the innerTextElement.
361         
362         Rename hitInnerTextBlock() to hitInnerTextElement() to match the
363         'innerTextElement' terminology used elsewhere.
364         
365         Assert that if renderer()->hitTest() returns false, no-one set
366         result.innerNode().
367
368         Test: fast/forms/search-abs-pos-cancel-button.html
369
370         * rendering/RenderLayer.cpp:
371         (WebCore::RenderLayer::hitTestContents):
372         * rendering/RenderTextControl.cpp:
373         (WebCore::RenderTextControl::hitInnerTextElement):
374         * rendering/RenderTextControl.h:
375         * rendering/RenderTextControlMultiLine.cpp:
376         (WebCore::RenderTextControlMultiLine::nodeAtPoint):
377         * rendering/RenderTextControlSingleLine.cpp:
378         (WebCore::RenderTextControlSingleLine::nodeAtPoint):
379
380 2009-03-10  Antti Koivisto  <antti@apple.com>
381
382         Reviewed by Mark Rowe.
383
384         <rdar://problem/6668238> WebCore is registering text encodings needlessly from KURL constructor.
385         
386         Another case where we would trigger extended encoding loading needlessly.
387
388         * platform/text/TextEncoding.cpp:
389         (WebCore::TextEncoding::isNonByteBasedEncoding):
390
391 2009-03-10  Beth Dakin  <bdakin@apple.com>
392
393         Reviewed by Darin Adler.
394
395         Fix for <rdar://problem/6624769> REGRESSION (Safari 4 PB): No 
396         scroll bar appears for long line of text with NOWRAP set
397
398         This is a regression from http://trac.webkit.org/changeset/32226
399         I talked with Dan about the original change, and we decided that 
400         the best fix was to remove his small potential-optimization that 
401         only created a separate line box for whitespace under certain 
402         circumstances. This new code will always create a separate line 
403         box.
404
405         * rendering/bidi.cpp:
406         (WebCore::RenderBlock::layoutInlineChildren):
407
408 2009-03-10  Sam Weinig  <sam@webkit.org>
409
410         Reviewed by Geoffrey Garen.
411
412         Fix for <rdar://problem/6166844>
413         https://bugs.webkit.org/show_bug.cgi?id=24495
414
415         Use same rule for loading java applets as we do for images.
416
417         * html/HTMLAppletElement.cpp:
418         (WebCore::HTMLAppletElement::createRenderer):
419         * loader/FrameLoader.cpp:
420         (WebCore::FrameLoader::loadItem):
421
422 2009-03-10  Justin Garcia  <justin.garcia@apple.com>
423
424         Reviewed by David Kilzer.
425
426         Get rid of revealCaret and use revealSelection instead.
427
428         * WebCore.base.exp:
429         * editing/SelectionController.cpp:
430         (WebCore::SelectionController::setSelection):
431         * page/Frame.cpp:
432         (WebCore::Frame::revealSelection):
433         * page/Frame.h:
434
435 2009-03-10  Cameron Zwarich  <cwzwarich@uwaterloo.ca>
436
437         Reviewed by Geoff Garen.
438
439         Bug 23736: WebKit Crashes on http://g-conquest.fr/~server2
440         <https://bugs.webkit.org/show_bug.cgi?id=23736>
441         <rdar://problem/6560278>
442
443         Before replacing the document, FrameLoader::executeIfJavaScriptURL()
444         should call stopAllLoaders(), just like continueLoadAfterNavigationPolicy().
445
446         * loader/FrameLoader.cpp:
447         (WebCore::FrameLoader::executeIfJavaScriptURL):
448
449 2009-03-10  Darin Adler  <darin@apple.com>
450
451         Reviewed by Alexey Proskuryakov.
452
453         Bug 24494: crash when deleting at end of document and merging paragraphs
454         https://bugs.webkit.org/show_bug.cgi?id=24494
455         rdar://problem/6571537
456
457         Test: editing/deleting/merge-at-end-of-document.html
458
459         * dom/Range.cpp:
460         (WebCore::Range::compareBoundaryPoints): Split out assertion. It's better not to
461         use && in assertions since we'd like to know which condition is failing.
462
463         * editing/ApplyStyleCommand.cpp:
464         (WebCore::ApplyStyleCommand::applyInlineStyleToRange): Added a null check before
465         calling compareBoundaryPoints, since a 0 for the node is ambiguous and so the
466         function doesn't know which value to return.
467
468 2009-03-10  Dirk Schulze  <krit@webkit.org>
469
470         Reviewed by Eric Seidel. Math checked by Oliver Hunt.
471
472         Implement the Cairo version of the checkForSolidColor() method. This halfes the
473         time to draw on 1x1 px background images.
474         I added two new calls to Color for the pixel manipulation on cairo_surface's.
475         They are neede to premultiply/unpremultiply the colors of the surface.
476
477         [CAIRO] Introduce single-pixel image optimizations
478         https://bugs.webkit.org/show_bug.cgi?id=17284
479
480         * platform/graphics/Color.cpp:
481         (WebCore::colorFromPremultipliedARGB):
482         (WebCore::premultipliedARGBFromColor):
483         * platform/graphics/Color.h:
484         * platform/graphics/cairo/ImageBufferCairo.cpp:
485         (WebCore::ImageBuffer::getImageData):
486         (WebCore::ImageBuffer::putImageData):
487         * platform/graphics/cairo/ImageCairo.cpp:
488         (WebCore::BitmapImage::checkForSolidColor):
489
490 2009-03-06  Darin Fisher  <darin@chromium.org>
491
492         Reviewed by Sam Weinig.
493
494         https://bugs.webkit.org/show_bug.cgi?id=24437
495
496         Add support for registering noAccess URL schemes:
497         1-  Add FrameLoader::registerURLSchemeAsNoAccess, and have SecurityOrigin check
498         that list upon construction (similar to how isLocal is implemented).
499         2-  Make InspectorController call grantUniversalAccess on its Document's
500         SecurityOrigin at the time when windowScriptObjectAvailable is called.
501
502         This enables content such as the inspector to be loaded from a custom (non-file)
503         URL, which is how Chromium loads the inspector.  It also allows other URL schemes
504         to be treated like data: URLs, which Chromium utilizes for its various HTML-based
505         UI panels.
506
507         * inspector/InspectorController.cpp:
508         (WebCore::InspectorController::windowScriptObjectAvailable):
509         * loader/FrameLoader.cpp:
510         (WebCore::localSchemes):
511         (WebCore::noAccessSchemes):
512         (WebCore::FrameLoader::loadItem):
513         * loader/FrameLoader.h:
514         * page/SecurityOrigin.cpp:
515         (WebCore::SecurityOrigin::SecurityOrigin):
516         (WebCore::SecurityOrigin::isLocal):
517
518 2009-03-10  Xan Lopez  <xlopez@igalia.com>
519
520         Build fix, no review
521
522         * page/mac/AccessibilityObjectWrapper.mm:
523         (textMarkerForVisiblePosition):
524         (visiblePositionForTextMarker):
525
526 2009-03-10  Xan Lopez  <xlopez@igalia.com>
527
528         Reviewed by Darin Adler.
529
530         https://bugs.webkit.org/show_bug.cgi?id=24491
531         Rename posOffset to m_offset, get rid of accessor
532
533         As suggested in dom/Position.h, this patch gets rid of the
534         'offset()' accessor and renames posOffset to m_offset. I've used
535         m_offset instead of offset to follow the style guide lines, since
536         Position is still a class and not a structure. If the long term
537         plan is still to make it a structure it would be pretty easy to
538         just s/m_offset/offset/ globally when that is achieved.
539
540         * dom/Position.cpp:
541         (WebCore::Position::previous):
542         (WebCore::Position::next):
543         (WebCore::Position::atStart):
544         (WebCore::Position::atEnd):
545         (WebCore::Position::renderedOffset):
546         (WebCore::Position::isCandidate):
547         (WebCore::Position::inRenderedText):
548         (WebCore::Position::isRenderedCharacter):
549         (WebCore::Position::rendersInDifferentPosition):
550         (WebCore::Position::leadingWhitespacePosition):
551         (WebCore::Position::debugPosition):
552         (WebCore::Position::formatForDebugger):
553         * dom/Position.h:
554         (WebCore::Position::Position):
555         * dom/PositionIterator.h:
556         (WebCore::PositionIterator::PositionIterator):
557         * dom/Range.cpp:
558         * dom/RangeBoundaryPoint.h:
559         (WebCore::RangeBoundaryPoint::position):
560         (WebCore::RangeBoundaryPoint::set):
561         (WebCore::RangeBoundaryPoint::setOffset):
562         (WebCore::RangeBoundaryPoint::setToChild):
563         (WebCore::RangeBoundaryPoint::setToStart):
564         (WebCore::RangeBoundaryPoint::setToEnd):
565         (WebCore::RangeBoundaryPoint::childBeforeWillBeRemoved):
566         * editing/ApplyStyleCommand.cpp:
567         (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
568         (WebCore::ApplyStyleCommand::applyInlineStyleToRange):
569         (WebCore::ApplyStyleCommand::removeInlineStyle):
570         (WebCore::ApplyStyleCommand::nodeFullySelected):
571         (WebCore::ApplyStyleCommand::nodeFullyUnselected):
572         (WebCore::ApplyStyleCommand::splitTextAtStartIfNeeded):
573         (WebCore::ApplyStyleCommand::splitTextAtEndIfNeeded):
574         (WebCore::ApplyStyleCommand::splitTextElementAtStartIfNeeded):
575         (WebCore::ApplyStyleCommand::splitTextElementAtEndIfNeeded):
576         (WebCore::ApplyStyleCommand::mergeStartWithPreviousIfIdentical):
577         (WebCore::ApplyStyleCommand::mergeEndWithNextIfIdentical):
578         (WebCore::ApplyStyleCommand::joinChildTextNodes):
579         * editing/BreakBlockquoteCommand.cpp:
580         (WebCore::BreakBlockquoteCommand::doApply):
581         * editing/CompositeEditCommand.cpp:
582         (WebCore::CompositeEditCommand::insertNodeAt):
583         (WebCore::CompositeEditCommand::positionOutsideTabSpan):
584         (WebCore::CompositeEditCommand::rebalanceWhitespaceAt):
585         (WebCore::CompositeEditCommand::prepareWhitespaceAtPositionForSplit):
586         (WebCore::CompositeEditCommand::deleteInsignificantText):
587         (WebCore::CompositeEditCommand::removePlaceholderAt):
588         (WebCore::CompositeEditCommand::moveParagraphs):
589         (WebCore::CompositeEditCommand::breakOutOfEmptyMailBlockquotedParagraph):
590         * editing/DeleteSelectionCommand.cpp:
591         (WebCore::updatePositionForNodeRemoval):
592         (WebCore::updatePositionForTextRemoval):
593         (WebCore::DeleteSelectionCommand::handleGeneralDelete):
594         (WebCore::DeleteSelectionCommand::fixupWhitespace):
595         * editing/Editor.cpp:
596         (WebCore::Editor::setComposition):
597         (WebCore::Editor::advanceToNextMisspelling):
598         (WebCore::Editor::getCompositionSelection):
599         * editing/InsertLineBreakCommand.cpp:
600         (WebCore::InsertLineBreakCommand::doApply):
601         * editing/InsertParagraphSeparatorCommand.cpp:
602         (WebCore::InsertParagraphSeparatorCommand::doApply):
603         * editing/InsertTextCommand.cpp:
604         (WebCore::InsertTextCommand::performTrivialReplace):
605         (WebCore::InsertTextCommand::input):
606         (WebCore::InsertTextCommand::insertTab):
607         * editing/MoveSelectionCommand.cpp:
608         (WebCore::MoveSelectionCommand::doApply):
609         * editing/ReplaceSelectionCommand.cpp:
610         (WebCore::ReplaceSelectionCommand::doApply):
611         * editing/SelectionController.cpp:
612         (WebCore::SelectionController::debugRenderer):
613         * editing/TextIterator.cpp:
614         (WebCore::TextIterator::rangeFromLocationAndLength):
615         * editing/TypingCommand.cpp:
616         (WebCore::TypingCommand::deleteKeyPressed):
617         (WebCore::TypingCommand::forwardDeleteKeyPressed):
618         * editing/VisiblePosition.cpp:
619         (WebCore::VisiblePosition::characterAfter):
620         (WebCore::VisiblePosition::debugPosition):
621         (WebCore::makeRange):
622         (WebCore::setStart):
623         (WebCore::setEnd):
624         * editing/VisibleSelection.cpp:
625         (WebCore::VisibleSelection::toNormalizedRange):
626         (WebCore::makeSearchRange):
627         (WebCore::VisibleSelection::debugPosition):
628         (WebCore::VisibleSelection::showTreeForThis):
629         * editing/htmlediting.cpp:
630         (WebCore::comparePositions):
631         (WebCore::rangeCompliantEquivalent):
632         (WebCore::isFirstPositionAfterTable):
633         (WebCore::isLastPositionBeforeTable):
634         * editing/visible_units.cpp:
635         (WebCore::previousBoundary):
636         (WebCore::nextBoundary):
637         (WebCore::startPositionForLine):
638         (WebCore::startOfLine):
639         (WebCore::endPositionForLine):
640         (WebCore::nextLinePosition):
641         (WebCore::startOfParagraph):
642         (WebCore::endOfParagraph):
643         * page/AccessibilityObject.cpp:
644         (WebCore::updateAXLineStartForVisiblePosition):
645         * page/AccessibilityRenderObject.cpp:
646         (WebCore::AccessibilityRenderObject::indexForVisiblePosition):
647         * page/DOMSelection.cpp:
648         (WebCore::DOMSelection::anchorOffset):
649         (WebCore::DOMSelection::baseOffset):
650         (WebCore::DOMSelection::focusOffset):
651         (WebCore::DOMSelection::extentOffset):
652         * page/EventHandler.cpp:
653         (WebCore::EventHandler::handleMousePressEventSingleClick):
654         * page/Frame.cpp:
655         (WebCore::Frame::selectionLayoutChanged):
656         * rendering/RenderTextControl.cpp:
657         (WebCore::RenderTextControl::indexForVisiblePosition):
658         * rendering/RenderTreeAsText.cpp:
659         (WebCore::writeSelection):
660
661 2009-03-10  Darin Adler  <darin@apple.com>
662
663         Reviewed by Dan Bernstein.
664
665         Bug 23564: REGRESSION (r39230-39286): crash loading page that changes <input> display type and then calls innerHTML
666         https://bugs.webkit.org/show_bug.cgi?id=23564
667         rdar://problem/6537238
668
669         Test: fast/dom/HTMLElement/innerHTML-selection-crash.html
670
671         * editing/markup.cpp: (WebCore::createMarkup): Added updateLayoutIgnorePendingStylesheets
672         call to the one of the two overloads of this function that wasn't calling it. This fixes
673         this crash and other possible crashes inside innerHTML.
674
675 2009-03-10  Alexey Proskuryakov  <ap@webkit.org>
676
677         Reviewed by Darin Adler.
678
679         https://bugs.webkit.org/show_bug.cgi?id=24285
680         Text resource loading checks for BOM twice
681
682         This removes TextDecoder class, since its only purpose was to check for BOM, which is
683         already done in TextResourceDecoder. Callers that use TextEncoding::decode() won't get
684         BOM checked, but I didn't find any cases where it would significantly change behavior.
685
686         * GNUmakefile.am:
687         * WebCore.pro:
688         * WebCore.scons:
689         * WebCore.vcproj/WebCore.vcproj:
690         * WebCore.xcodeproj/project.pbxproj:
691         * WebCoreSources.bkl:
692         Remove TextDecoder.{h,cpp}.
693
694         * platform/text/TextDecoder.cpp: Removed.
695         * platform/text/TextDecoder.h: Removed.
696
697         * loader/TextResourceDecoder.h: Instead of a TextDecoder object, keep TextEncoding and
698         TextCodec separately.
699
700         * loader/TextResourceDecoder.cpp:
701         (WebCore::TextResourceDecoder::TextResourceDecoder): Updated for m_encoding being a member.
702         (WebCore::TextResourceDecoder::setEncoding): Ditto.
703         (WebCore::TextResourceDecoder::checkForBOM): Removed a FIXME saying that a BOM could override
704         even a user-chosen encoding - this is how it already worked due to TextDecoder checking for
705         BOM again. Made this function return the detected BOM length.
706         (WebCore::TextResourceDecoder::decode): Skip the BOM if it was found at the beginning of
707         a text resource.
708         (WebCore::TextResourceDecoder::flush): Reset m_checkedForBOM, so that re-decoding the same
709         resource again (as frequently done by CachedResource subclasses) will skip the BOM correctly.
710
711         * platform/text/TextEncoding.cpp: (WebCore::TextEncoding::decode):
712         Use TextCodec directly without a TextDecoder wrapper. This means that this method no longer
713         checks for BOM, which was a counter-intuitive feature.
714
715         * loader/CachedScript.cpp:
716         (WebCore::CachedScript::CachedScript):
717         (WebCore::CachedScript::setEncoding):
718         (WebCore::CachedScript::encoding):
719         (WebCore::CachedScript::script):
720         * loader/CachedScript.h:
721         * loader/appcache/ManifestParser.cpp:
722         (WebCore::parseManifest):
723         Use TextResourceDecoder, as TextEncoding::decode() no longer checks for BOM.
724         A side effect of this is that these resources will now be subject to encoding auto-detection.
725
726         * loader/CachedFont.cpp: (WebCore::CachedFont::ensureSVGFontData):
727         * page/Page.cpp: (WebCore::Page::userStyleSheet):
728         Be sure to flush TextResourceDecoder, pushing any remaining bytes out, and making the decoder
729         re-usable (for repeated decoding of the same resource).
730
731         * platform/text/TextEncodingRegistry.h: Updated comments for newTextCodec().
732
733 2009-03-10  Alexey Proskuryakov  <ap@webkit.org>
734
735         Reviewed by Darin Adler.
736
737         https://bugs.webkit.org/show_bug.cgi?id=24488
738         An assertion failure when updating an offline application cache after emptying caches
739
740         Emptying appcache cannot be performed automatically, so no test.
741
742         * loader/appcache/ApplicationCacheGroup.cpp:
743         (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete): Ensure that the cache is in disk
744         storage, even if the application wasn't updated server side.
745
746 2009-03-10  Oliver Hunt  <oliver@apple.com>
747
748         Reviewed by Alexey Proskuryakov.
749
750         <rdar://problem/6425807> Implement WorkerUtils.importScripts()
751         <https://bugs.webkit.org/show_bug.cgi?id=22721>
752
753         Implement importScripts, currently uses a series of synchronous loads
754         to fetch the scripts, but this is simpler than a synchronous load of
755         multiple loads in parallel.  In future we'll want to switch to parallel
756         loading, but this will do for now.
757         
758         Test: http/tests/workers/worker-importScripts.html
759
760         * GNUmakefile.am:
761         * WebCore.vcproj/WebCore.vcproj:
762         * WebCore.xcodeproj/project.pbxproj:
763         * bindings/js/JSWorkerContextCustom.cpp:
764         (WebCore::JSWorkerContext::importScripts):
765         * bindings/js/ScriptValue.h:
766         (WebCore::ScriptValue::hasNoValue):
767         * bindings/js/WorkerScriptController.cpp:
768         (WebCore::WorkerScriptController::evaluate):
769         (WebCore::WorkerScriptController::setException):
770         * bindings/js/WorkerScriptController.h:
771         * dom/Document.cpp:
772         (WebCore::Document::scriptImported):
773         * dom/Document.h:
774         * dom/ScriptExecutionContext.h:
775         * inspector/InspectorController.cpp:
776         (WebCore::InspectorController::scriptImported):
777         * inspector/InspectorController.h:
778         * inspector/InspectorResource.cpp:
779         (WebCore::InspectorResource::setScriptProperties):
780         * inspector/InspectorResource.h:
781         * workers/WorkerContext.cpp:
782         (WebCore::WorkerContext::scriptImported):
783         (WebCore::WorkerContext::importScripts):
784         * workers/WorkerContext.h:
785         * workers/WorkerContext.idl:
786         * workers/WorkerImportScriptsClient.cpp: Added.
787         (WebCore::WorkerImportScriptsClient::didReceiveResponse):
788         (WebCore::WorkerImportScriptsClient::didReceiveData):
789         (WebCore::WorkerImportScriptsClient::didFinishLoading):
790         (WebCore::WorkerImportScriptsClient::didFail):
791         (WebCore::WorkerImportScriptsClient::didFailRedirectCheck):
792         (WebCore::WorkerImportScriptsClient::didReceiveAuthenticationCancellation):
793         * workers/WorkerImportScriptsClient.h: Added.
794         (WebCore::WorkerImportScriptsClient::WorkerImportScriptsClient):
795         (WebCore::WorkerImportScriptsClient::script):
796         (WebCore::WorkerImportScriptsClient::failed):
797
798 2009-03-10  Alexey Proskuryakov  <ap@webkit.org>
799
800         Reviewed by Darin Adler.
801
802         https://bugs.webkit.org/show_bug.cgi?id=24462
803         Move cross-origin access control code out of XMLHttpRequest
804
805         Step 1: move preflight result cache and access control helper functions.
806
807         No change in behavior, so no test.
808
809         * GNUmakefile.am:
810         * WebCore.pro:
811         * WebCore.scons:
812         * WebCore.vcproj/WebCore.vcproj:
813         * WebCore.xcodeproj/project.pbxproj:
814         * WebCoreSources.bkl:
815         * loader/CrossOriginAccessControl.cpp: Added.
816         (WebCore::isOnAccessControlSimpleRequestHeaderWhitelist):
817         (WebCore::isSimpleCrossOriginAccessRequest):
818         (WebCore::createAllowedCrossOriginResponseHeadersSet):
819         (WebCore::isOnAccessControlResponseHeaderWhitelist):
820         (WebCore::passesAccessControlCheck):
821         * loader/CrossOriginAccessControl.h: Added.
822         * loader/CrossOriginPreflightResultCache.cpp: Added.
823         (WebCore::parseAccessControlMaxAge):
824         (WebCore::addToAccessControlAllowList):
825         (WebCore::parseAccessControlAllowList):
826         (WebCore::CrossOriginPreflightResultCacheItem::parse):
827         (WebCore::CrossOriginPreflightResultCacheItem::allowsCrossOriginMethod):
828         (WebCore::CrossOriginPreflightResultCacheItem::allowsCrossOriginHeaders):
829         (WebCore::CrossOriginPreflightResultCacheItem::allowsRequest):
830         (WebCore::CrossOriginPreflightResultCache::shared):
831         (WebCore::CrossOriginPreflightResultCache::appendEntry):
832         (WebCore::CrossOriginPreflightResultCache::canSkipPreflight):
833         * loader/CrossOriginPreflightResultCache.h: Added.
834         (WebCore::CrossOriginPreflightResultCacheItem::CrossOriginPreflightResultCacheItem):
835         (WebCore::CrossOriginPreflightResultCache::CrossOriginPreflightResultCache):
836         * xml/XMLHttpRequest.cpp:
837         (WebCore::XMLHttpRequestStaticData::XMLHttpRequestStaticData):
838         (WebCore::XMLHttpRequest::createRequest):
839         (WebCore::XMLHttpRequest::makeCrossOriginAccessRequest):
840         (WebCore::XMLHttpRequest::makeSimpleCrossOriginAccessRequest):
841         (WebCore::XMLHttpRequest::makeCrossOriginAccessRequestWithPreflight):
842         (WebCore::XMLHttpRequest::didReceiveResponse):
843         (WebCore::XMLHttpRequest::didReceiveResponsePreflight):
844         * xml/XMLHttpRequest.h:
845
846 2009-03-10  Alexey Proskuryakov  <ap@webkit.org>
847
848         Reviewed by Darin Adler.
849
850         https://bugs.webkit.org/show_bug.cgi?id=19797
851         Bring the list of forbidden headers in sync with XMLHttpRequest spec draft
852
853         Added new checks to http/tests/xmlhttprequest/set-dangerous-headers.html.
854
855         * xml/XMLHttpRequest.cpp:
856         (WebCore::XMLHttpRequestStaticData::XMLHttpRequestStaticData): Added all headers from
857         XMLHttpRequest 2 draft.
858
859 2009-03-10  Dan Bernstein  <mitz@apple.com>
860
861         Reviewed by Adele Peterson.
862
863         - fix https://bugs.webkit.org/show_bug.cgi?id=23975
864           <rdar://problem/6593610> REGRESSION: Scrollbar arrow not repainted
865
866         * rendering/RenderLayer.cpp:
867         (WebCore::RenderLayer::invalidateScrollbarRect): Corrected the vertical
868         scrollbar rect calculation.
869
870 2009-03-09  Simon Fraser  <simon.fraser@apple.com>
871
872         Reviewed by Dan Bernstein, Oliver Hunt
873
874         https://bugs.webkit.org/show_bug.cgi?id=24475
875         
876         When repainting replaced elements, need to union the selection
877         and overflow rects because either may extend outside the other.
878         
879         Test: fast/repaint/transform-replaced-shadows.html
880
881         * rendering/RenderReplaced.cpp:
882         (WebCore::RenderReplaced::clippedOverflowRectForRepaint):
883
884 2009-03-09  Stephanie Lewis  <slewis@apple.com>
885
886         Fix build.
887
888         * editing/Editor.cpp:
889         (WebCore::Editor::advanceToNextMisspelling):
890         (WebCore::markAllMisspellingsAndBadGrammarInRanges):
891
892 2009-03-09  Kim Christensen  <kimworking@gmail.com>
893
894         Reviewed by Darin Fisher.
895
896         https://bugs.webkit.org/show_bug.cgi?id=24276
897         Dropdown / select boxes do not consider the windows task bar in Chromium.
898
899         * platform/chromium/PopupMenuChromium.cpp:
900         (WebCore::PopupContainer::showPopup):
901
902 2009-03-09  Dan Bernstein  <mitz@apple.com>
903
904         Reviewed by Adele Peterson and Dave Hyatt.
905
906         - fix <rdar://problem/6654344> REGRESSION (r41041): Zillow.com has
907           misaligned edit fields
908
909         Test: fast/forms/legend-display-none.html
910
911         * css/CSSStyleSelector.cpp:
912         (WebCore::CSSStyleSelector::adjustRenderStyle): Change the display
913         property of legend elements to 'block' unless it is 'none'.
914         * css/html4.css: Do not force the display property of legend elements to
915         'block' using CSS, because that prevents style rules from setting it to
916         'none'.
917
918 2009-03-09  Alpha Lam  <hclam@chromium.org>
919
920         Reviewed by Dave Hyatt.
921
922         https://bugs.webkit.org/show_bug.cgi?id=23024
923
924         Fix an incorrect criteria in the if statement that leaves references to
925         deleted floating objects in RenderBlock.
926
927         Test: fast/block/float/crash-on-absolute-positioning.html
928
929         * rendering/RenderBlock.cpp:
930         (WebCore::RenderBlock::markAllDescendantsWithFloatsForLayout):
931
932 2009-03-09  Mike Belshe  <mike@belshe.com>
933
934         Reviewed by Eric Seidel.
935
936         Unify JSC/V8 idl file.
937         https://bugs.webkit.org/show_bug.cgi?id=24424
938
939         * page/Location.idl:
940
941 2009-03-09  Mike Belshe  <mike@belshe.com>
942
943         Reviewed by Eric Seidel.
944
945         Unify JSC/V8 for History.idl.
946
947         * page/History.idl:
948
949 2009-03-09  Mike Belshe  <mike@belshe.com>
950
951         Reviewed by Eric Seidel.
952
953         Unify JSC/V8 implementations of DOMWindow.idl.
954
955         * page/DOMWindow.idl:
956
957 2009-03-09  Simon Fraser  <simon.fraser@apple.com>
958
959         Reviewed by Dave Hyatt
960
961         https://bugs.webkit.org/show_bug.cgi?id=24163
962         
963         Implement mapping of FloatQuads through 3D transforms.
964         
965         Removed the redundant localToContainerQuad() methods, which can now 
966         shared code with the old mapLocalToAbsolutePoint(), which was
967         renamed to mapLocalToContainer(). This can now convert a point,
968         and optionally a FloatQuad, which are carried along in the TransformState.
969         
970         Optimized TransformState to reduce to simple FloatPoint.move()
971         if there are no transforms, and to heap-allocate a transform only if
972         necessary to accumulate transforms (when using preserve-3d).
973         
974         Tested by 3d point mapping tests, and the inspector highlight (which now shows
975         the correct quads for 3d-transformed elements).
976
977         * platform/graphics/transforms/TransformationMatrix.cpp:
978         (WebCore::TransformationMatrix::projectQuad):
979         (WebCore::TransformationMatrix::translateRight):
980         (WebCore::TransformationMatrix::translateRight3d):
981         * platform/graphics/transforms/TransformationMatrix.h:
982         * rendering/RenderBox.cpp:
983         (WebCore::RenderBox::mapLocalToContainer):
984         (WebCore::RenderBox::mapAbsoluteToLocalPoint):
985         * rendering/RenderBox.h:
986         * rendering/RenderObject.cpp:
987         (WebCore::RenderObject::localToAbsolute):
988         (WebCore::RenderObject::absoluteToLocal):
989         (WebCore::RenderObject::mapLocalToContainer):
990         (WebCore::RenderObject::localToContainerQuad):
991         * rendering/RenderObject.h:
992         * rendering/RenderTableCell.cpp:
993         (WebCore::RenderTableCell::mapLocalToContainer):
994         * rendering/RenderTableCell.h:
995         * rendering/RenderView.cpp:
996         (WebCore::RenderView::mapLocalToContainer):
997         * rendering/RenderView.h:
998         * rendering/TransformState.cpp:
999         (WebCore::TransformState::move):
1000         (WebCore::TransformState::applyTransform):
1001         (WebCore::TransformState::flatten):
1002         (WebCore::TransformState::mappedPoint):
1003         (WebCore::TransformState::mappedQuad):
1004         (WebCore::TransformState::flattenWithTransform):
1005         (WebCore::HitTestingTransformState::mappedQuad):
1006         * rendering/TransformState.h:
1007         (WebCore::TransformState::TransformState):
1008         (WebCore::TransformState::move):
1009         (WebCore::TransformState::lastPlanarPoint):
1010         (WebCore::TransformState::lastPlanarQuad):
1011         * rendering/style/RenderStyle.h:
1012         (WebCore::InheritedFlags::preserves3D):
1013
1014 2009-03-09  Simon Fraser  <simon.fraser@apple.com>
1015
1016         Reviewed by Dave Hyatt
1017
1018         https://bugs.webkit.org/show_bug.cgi?id=24433
1019         
1020         During hit testing with transforms, if a layer has backface-visibility: hidden,
1021         we need to check for it whether or not the layer has a transform, because it
1022         might be an ancestor that is transformed.
1023
1024         Test: transforms/3d/hit-testing/backface-no-transform-hit-test.html
1025
1026         * rendering/RenderLayer.cpp:
1027         (WebCore::RenderLayer::hitTestLayer):
1028
1029 2009-03-09  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
1030
1031         Reviewed by George Staikos.
1032
1033         https://bugs.webkit.org/show_bug.cgi?id=24353
1034         Allow to overrule default build options for Qt build.
1035
1036         * WebCore.pro: Allow to overrule ENABLE_VIDEO and ENABLE_NETSCAPE_PLUGIN_API
1037
1038 2009-03-09  Adam Treat  <adam.treat@torchmobile.com>
1039
1040         Reviewed by George Staikos.
1041
1042         https://bugs.webkit.org/show_bug.cgi?id=24463
1043         WebCore::qstring is detaching and copying twice for every single
1044         WebCore::TextRun that is processed and drawn.  This elevates this method
1045         to one of the top-ten most expensive methods in all of QtWebKit according
1046         to profiling.  This changes the method so that QString only detaches
1047         when absolutely necessary.
1048
1049         * platform/graphics/qt/FontQt.cpp:
1050         (WebCore::qstring):
1051         (WebCore::fixSpacing):
1052         (WebCore::Font::drawComplexText):
1053         (WebCore::Font::floatWidthForComplexText):
1054         (WebCore::Font::offsetForPositionForComplexText):
1055         (WebCore::Font::selectionRectForComplexText):
1056
1057 2009-03-08  Mark Rowe  <mrowe@apple.com>
1058
1059         Reviewed by Oliver Hunt.
1060
1061         Split ScrollAlignment and ScrollBehavior out of RenderLayer.h so that
1062         Frame.h no longer needs to include it.  This cuts the size of the symbols
1063         for a debug build by around 3%.
1064
1065         * dom/Element.cpp:
1066         (WebCore::Element::scrollIntoView):
1067         (WebCore::Element::scrollIntoViewIfNeeded):
1068         * editing/Editor.cpp:
1069         (WebCore::Editor::insertTextWithoutSendingTextEvent):
1070         (WebCore::Editor::revealSelectionAfterEditingOperation):
1071         * editing/SelectionController.cpp:
1072         (WebCore::SelectionController::setSelection):
1073         * loader/FrameLoader.cpp:
1074         (WebCore::FrameLoader::gotoAnchor):
1075         * page/ContextMenuController.cpp:
1076         (WebCore::ContextMenuController::contextMenuItemSelected):
1077         * page/Frame.cpp:
1078         (WebCore::Frame::revealSelection):
1079         (WebCore::Frame::revealCaret):
1080         * page/Frame.h:
1081         * rendering/RenderLayer.cpp:
1082         (WebCore::RenderLayer::getRectToExpose):
1083         (WebCore::RenderLayer::autoscroll):
1084         * rendering/RenderLayer.h:
1085         * rendering/ScrollBehavior.cpp: Added.
1086         (WebCore::):
1087         * rendering/ScrollBehavior.h: Added.
1088         (WebCore::):
1089         (WebCore::ScrollAlignment::getVisibleBehavior):
1090         (WebCore::ScrollAlignment::getPartialBehavior):
1091         (WebCore::ScrollAlignment::getHiddenBehavior):
1092
1093         Add the new files to the build systems:
1094         * GNUmakefile.am:
1095         * WebCore.base.exp:
1096         * WebCore.pro:
1097         * WebCore.scons:
1098         * WebCore.vcproj/WebCore.vcproj:
1099         * WebCore.xcodeproj/project.pbxproj:
1100         * WebCoreSources.bkl:
1101
1102         Add includes that were previously pulled in by way of RenderLayer.h from Frame.h:
1103         * dom/Clipboard.cpp:
1104         * editing/EditorCommand.cpp:
1105         * editing/InsertLineBreakCommand.cpp:
1106         * editing/TypingCommand.cpp:
1107         * html/HTMLFormControlElement.cpp:
1108         * loader/archive/cf/LegacyWebArchive.cpp:
1109         * loader/icon/IconLoader.cpp:
1110         * page/animation/AnimationController.cpp:
1111         * rendering/RenderSlider.cpp:
1112         * rendering/RenderTextControl.cpp:
1113
1114
1115 2009-03-08  Mark Rowe  <mrowe@apple.com>
1116
1117         Reviewed Dan Bernstein.
1118
1119         Push the include of Frame.h out of RenderView.h and down to those files
1120         that need it.  This cuts the size of symbols for RenderFoo object files
1121         by around 15% in a debug build.
1122
1123         * bindings/objc/DOM.mm:
1124         * rendering/RenderFileUploadControl.cpp:
1125         * rendering/RenderInline.cpp:
1126         * rendering/RenderObject.cpp:
1127         * rendering/RenderReplaced.cpp:
1128         * rendering/RenderText.cpp:
1129         * rendering/RenderView.cpp:
1130         (WebCore::RenderView::zoomFactor):
1131         * rendering/RenderView.h:
1132
1133 2009-03-08  Mark Rowe  <mrowe@apple.com>
1134
1135         Rubber-stamped by Dan Bernstein.
1136
1137         Remove some unnecessary or redundant includes from files related to the JS bindings.
1138         This cuts the size of the symbols for a debug build by around 3%.
1139
1140         * bindings/js/JSCustomPositionCallback.cpp:
1141         * bindings/js/JSCustomPositionErrorCallback.cpp:
1142         * bindings/js/JSCustomSQLStatementCallback.cpp:
1143         * bindings/js/JSCustomSQLStatementErrorCallback.cpp:
1144         * bindings/js/JSCustomSQLTransactionCallback.cpp:
1145         * bindings/js/JSCustomSQLTransactionErrorCallback.cpp:
1146         * bindings/js/JSCustomVoidCallback.cpp:
1147         * bindings/js/JSCustomXPathNSResolver.cpp:
1148         * bindings/js/JSDocumentCustom.cpp:
1149         * bindings/js/JSPluginElementFunctions.cpp:
1150         * bindings/js/JSSVGPODTypeWrapper.h:
1151
1152 2009-03-08  Cameron Zwarich  <cwzwarich@uwaterloo.ca>
1153
1154         Reviewed by Oliver Hunt.
1155
1156         Remove the unused methods previousHistoryItem(), setPreviousHistoryItem()
1157         and provisionalHistoryItem() from FrameLoader.
1158
1159         * WebCore.base.exp:
1160         * WebCore.order:
1161         * loader/FrameLoader.cpp:
1162         (WebCore::FrameLoader::frameLoadCompleted):
1163         (WebCore::FrameLoader::loadItem):
1164         * loader/FrameLoader.h:
1165
1166 2009-03-08  Gustavo Noronha Silva  <gns@gnome.org>
1167
1168         Reviewed by Holger Freyther.
1169
1170         Implement proper logging for the GTK+ port, inspired by the one in
1171         Qt. We use the WEBKIT_DEBUG environment variable which was already
1172         being used to decide whether to setup a logger for soup or not.
1173
1174         * platform/gtk/LoggingGtk.cpp:
1175         (WebCore::getChannelFromName):
1176         (WebCore::InitializeLoggingChannelsIfNecessary):
1177         * platform/network/soup/ResourceHandleSoup.cpp:
1178         (WebCore::ensureSessionIsInitialized):
1179
1180 2009-03-07  Dan Bernstein  <mitz@apple.com>
1181
1182         Reviewed by Mark Rowe.
1183
1184         - WebCore part of removing build-time and run-time support for legacy
1185           versions of CFNetwork and Core Graphics
1186
1187         * platform/graphics/win/FontCGWin.cpp:
1188         (WebCore::Font::drawGlyphs):
1189         * platform/graphics/win/FontCustomPlatformData.cpp:
1190         (WebCore::FontCustomPlatformData::fontPlatformData):
1191         * platform/graphics/win/FontPlatformDataCGWin.cpp:
1192         (WebCore::FontPlatformData::platformDataInit):
1193         * platform/network/cf/FormDataStreamCFNet.cpp:
1194         (WebCore::setHTTPBody):
1195         (WebCore::httpBodyFromRequest):
1196         * platform/network/cf/ResourceHandleCFNet.cpp:
1197         (WebCore::didSendBodyData):
1198         (WebCore::shouldUseCredentialStorageCallback):
1199         (WebCore::ResourceHandle::start):
1200         * platform/network/win/CookieJarCFNetWin.cpp:
1201         (WebCore::filterCookies):
1202
1203 2009-03-07  Adele Peterson  <adele@apple.com>
1204
1205         Reviewed by Dan Bernstein.
1206
1207         Fix for https://bugs.webkit.org/show_bug.cgi?id=24444
1208         No multiple JS property for <input type="file" multiple />
1209
1210         * html/HTMLInputElement.cpp:
1211         (WebCore::HTMLInputElement::multiple):
1212         (WebCore::HTMLInputElement::setMultiple):
1213         * html/HTMLInputElement.h:
1214         * html/HTMLInputElement.idl:
1215
1216 2009-03-07  Xan Lopez  <xan@gnome.org>
1217
1218         Reviewed by Holger Freyther.
1219
1220         https://bugs.webkit.org/show_bug.cgi?id=24358
1221         [GTK] Scrollbars not clipped correctly
1222
1223         ScrollView scrollbars in subframes are *not* native, so take that
1224         into account again.
1225
1226         * platform/gtk/ScrollbarGtk.cpp:
1227         (ScrollbarGtk::getLocationInParentWindow):
1228         (ScrollbarGtk::frameRectsChanged):
1229         (ScrollbarGtk::paint):
1230         * platform/gtk/ScrollbarGtk.h:
1231
1232 2009-03-06  Peter Kasting  <pkasting@google.com>
1233
1234         Reviewed by Darin Fisher.
1235
1236         https://bugs.webkit.org/show_bug.cgi?id=24405
1237         Horizontal scrolling on Windows was reversed from Mac (and intuition).
1238
1239         * platform/gtk/WheelEventGtk.cpp:
1240         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1241         * platform/win/WheelEventWin.cpp:
1242         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1243
1244 2009-03-06  Peter Kasting  <pkasting@google.com>
1245
1246         Reviewed by Sam Weinig.
1247
1248         Convert some C-style casts to static_cast<>()s.
1249
1250         * platform/gtk/WheelEventGtk.cpp:
1251         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1252         * platform/mac/WheelEventMac.mm:
1253         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1254         * platform/win/WheelEventWin.cpp:
1255         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1256         * platform/wx/MouseWheelEventWx.cpp:
1257         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1258
1259 2009-03-06  Adele Peterson  <adele@apple.com>
1260
1261         Reviewed by Oliver Hunt.
1262
1263         Fix for <rdar://problem/6607524> REGRESSION (Safari 3-4): I can't tab back to the URL field in an empty window (key loop is broken)
1264
1265         I haven't been able to make a test for this since the problem is not reproducible within an empty iframe.
1266
1267         * page/EventHandler.cpp: (WebCore::eventTargetNodeForDocument): We used to ensure that every html document had a body element.
1268           That is no longer true, so we should return the document element for a truly empty document.
1269
1270 2009-03-06  Jay Campan  <jcampan@google.com>
1271
1272         Reviewed by Darin Fisher.
1273
1274         https://bugs.webkit.org/show_bug.cgi?id=24306
1275
1276         Adding a flag to ResourceRequestBase to indicate whether or not upload
1277         progress notifications are needed for a resource. This is useful to
1278         avoid sending these notifications when there are no consumers
1279         (especially in the Chromium case where IPC is involved). 
1280
1281         * platform/network/ResourceRequestBase.h:
1282         (WebCore::ResourceRequestBase::reportUploadProgress):
1283         (WebCore::ResourceRequestBase::setReportUploadProgress):
1284         (WebCore::ResourceRequestBase::ResourceRequestBase):
1285         * xml/XMLHttpRequest.cpp:
1286         (WebCore::XMLHttpRequest::loadRequestAsynchronously):
1287
1288 2009-03-06  Dmitry Titov  <dimich@chromium.org>
1289
1290         Reviewed by Alexey Proskuryakov.
1291
1292         https://bugs.webkit.org/show_bug.cgi?id=24150
1293         Add virtual ScriptExecutionContext::encoding()
1294
1295         Test: http/tests/workers/text-encoding.html
1296
1297         * dom/Document.cpp:
1298         (WebCore::Document::encoding):
1299         * dom/Document.h:
1300         (WebCore::Document::inputEncoding):
1301         (WebCore::Document::charset):
1302         (WebCore::Document::characterSet):
1303         Add new virtual method and route DOM synonym functions on Document through it.
1304
1305         * dom/ScriptExecutionContext.h:
1306         * workers/Worker.cpp:
1307         (WebCore::Worker::Worker):
1308         (WebCore::Worker::notifyFinished):
1309         * workers/WorkerContext.cpp:
1310         (WebCore::WorkerContext::WorkerContext):
1311         (WebCore::WorkerContext::encoding):
1312         (WebCore::WorkerContext::completeURL): Added comment on why this is different from Document::completeURL
1313         * workers/WorkerContext.h:
1314         (WebCore::WorkerContext::create):
1315         * workers/WorkerContextProxy.h:
1316         * workers/WorkerMessagingProxy.cpp:
1317         (WebCore::WorkerMessagingProxy::startWorkerContext):
1318         * workers/WorkerMessagingProxy.h:
1319         * workers/WorkerThread.cpp:
1320         (WebCore::WorkerThreadStartupData::create):
1321         (WebCore::WorkerThreadStartupData::WorkerThreadStartupData):
1322         (WebCore::WorkerThread::create):
1323         (WebCore::WorkerThread::WorkerThread):
1324         (WebCore::WorkerThread::workerThread):
1325         * workers/WorkerThread.h:
1326         All of the above route the 'encoding' parameter of parent context to the new
1327         instance of WorkerContext - from Worker::notifyFinished() via WorkerMessagingProxy
1328         through WorkerThread through WorkerThreadStartupData and into constructor of WorkerContext.
1329
1330 2009-03-06  Peter Kasting  <pkasting@google.com>
1331
1332         Build bustage fix.
1333
1334         * dom/Node.cpp:
1335         (WebCore::Node::dispatchWheelEvent):
1336
1337 2009-03-06  Eric Carlson  <eric.carlson@apple.com>
1338
1339         Reviewed by Antti Koivisto.
1340
1341         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
1342         (WebCore::MediaPlayerPrivate::createQTMovieView):  Delay callback while setting up movieview.
1343
1344 2009-03-06  Douglas R. Davidson  <ddavidso@apple.com>
1345
1346         Reviewed by Justin Garcia.
1347         
1348         https://bugs.webkit.org/show_bug.cgi?id=24108
1349
1350         Update spelling and grammar checking to use the new combined text 
1351         checking (with automatic language identification) on Snow Leopard. 
1352         Tested manually in Mail and Safari; automated tests to come later. 
1353         
1354         * editing/Editor.cpp:
1355         (WebCore::findFirstMisspellingOrBadGrammarInRange):
1356         (WebCore::Editor::advanceToNextMisspelling):
1357         (WebCore::guessesForMisspelledOrUngrammaticalRange):
1358         (WebCore::Editor::guessesForMisspelledOrUngrammaticalSelection):
1359         (WebCore::Editor::markMisspellingsAfterTypingToPosition):
1360         (WebCore::markAllMisspellingsAndBadGrammarInRanges):
1361         (WebCore::Editor::markMisspellingsAndBadGrammar):
1362         * editing/Editor.h:
1363         * loader/EmptyClients.h:
1364         (WebCore::EmptyEditorClient::checkSpellingAndGrammarOfParagraph):
1365         * page/EditorClient.h:
1366         * page/Frame.cpp:
1367         (WebCore::Frame::respondToChangedSelection):
1368         * platform/ContextMenu.cpp:
1369         (WebCore::ContextMenu::populate):
1370
1371 2009-03-06  Peter Kasting  <pkasting@google.com>
1372
1373         Reviewed by Darin Fisher.
1374
1375         https://bugs.webkit.org/show_bug.cgi?id=24407
1376         Windows scroll amount was too small, and wheel scroll distance
1377         conversion code was overly complex.
1378
1379         * page/EventHandler.cpp:
1380         (WebCore::scrollAndAcceptEvent):
1381         * platform/PlatformWheelEvent.h:
1382         (WebCore::):
1383         * platform/ScrollView.cpp:
1384         (WebCore::ScrollView::wheelEvent):
1385         * platform/Scrollbar.h:
1386         * platform/gtk/WheelEventGtk.cpp:
1387         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1388         * platform/mac/WheelEventMac.mm:
1389         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1390         * platform/qt/WheelEventQt.cpp:
1391         * platform/win/WheelEventWin.cpp:
1392         (WebCore::horizontalScrollChars):
1393         (WebCore::verticalScrollLines):
1394         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1395         * platform/wx/MouseWheelEventWx.cpp:
1396         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1397
1398 2009-03-06  Dimitri Glazkov  <dglazkov@chromium.org>
1399
1400         Reviewed by Adam Roben.
1401
1402         Generate valid bindings with HTML5 database support disabled. 
1403
1404         * inspector/InspectorController.idl: Added feature guard around 
1405         databaseTableNames definition.
1406
1407 2009-03-04  Xan Lopez  <xan@gnome.org>
1408
1409         Reviewed by Holger Freyther.
1410
1411         https://bugs.webkit.org/show_bug.cgi?id=24358
1412         [GTK] Scrollbars not clipped correctly
1413
1414         Do not take into account the case of being a ScrollView scrollbar,
1415         since those are native in our case.
1416
1417         * platform/gtk/ScrollbarGtk.cpp:
1418         (ScrollbarGtk::frameRectsChanged):
1419
1420 2009-03-04  Xan Lopez  <xan@gnome.org>
1421
1422         Reviewed by Holger Freyther.
1423
1424         https://bugs.webkit.org/show_bug.cgi?id=24358
1425         [GTK] Scrollbars not clipped correctly
1426
1427         Move Widget::paint to ScrollbarGtk::paint, since it's scrollbar
1428         specific and it's our only Widget anyway.
1429
1430         * platform/gtk/ScrollbarGtk.cpp:
1431         (ScrollbarGtk::paint):
1432         * platform/gtk/ScrollbarGtk.h:
1433         * platform/gtk/WidgetGtk.cpp:
1434
1435 2009-03-04  Xan Lopez  <xan@gnome.org>
1436
1437         Reviewed by Holger Freyther.
1438
1439         https://bugs.webkit.org/show_bug.cgi?id=24358
1440         [GTK] Scrollbars not clipped correctly
1441
1442         Use correct clip rectangle and apply coordinate translation needed
1443         for non-ScrollView scrollbars.
1444
1445         We were ignoring the clip rectangle passed as parameter, which is
1446         wrong in the case of non coalesced expose events. This, in turn,
1447         uncovers the fact that we were not applying coordinate translation
1448         to our position.
1449
1450         * platform/gtk/WidgetGtk.cpp:
1451         (WebCore::Widget::paint):
1452
1453 2009-03-06  Eric Carlson  <eric.carlson@apple.com>
1454
1455         Build fix, no review
1456
1457         * platform/graphics/chromium/MediaPlayerPrivateChromium.h: fix setSize declaration
1458
1459 2009-03-06  Eric Carlson  <eric.carlson@apple.com>
1460
1461         Reviewed by Simon Fraser.
1462
1463         https://bugs.webkit.org/show_bug.cgi?id=22790
1464         Bug 22790: [Transforms] MediaPlayer::setRect() makes no sense with transforms
1465         Replace media engine setRect with setSize since they don't use about the 
1466         position anyway.
1467
1468         * platform/graphics/MediaPlayer.cpp:
1469         (WebCore::NullMediaPlayerPrivate::setSize): Changed from setRect.
1470         (WebCore::MediaPlayer::setSize): Ditto.
1471         * platform/graphics/MediaPlayer.h:
1472         (WebCore::MediaPlayer::size): Changed from rect().
1473
1474         * platform/graphics/MediaPlayerPrivate.h: Changed setRect to setSize.
1475
1476         * platform/graphics/chromium/MediaPlayerPrivateChromium.h: Ditto.
1477
1478         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp: 
1479         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate): Initialize m_size instead of m_rect
1480         (WebCore::MediaPlayerPrivate::setSize): Changed from setRect
1481         (WebCore::MediaPlayerPrivate::paint): update comment
1482         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.h: m_rect -> m_size.
1483
1484         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:  m_rect
1485         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
1486         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate): Initialize m_rect.
1487         (WebCore::MediaPlayerPrivate::createQTMovieView): setRect-> setSize.
1488         (WebCore::MediaPlayerPrivate::setSize): Changed from setRect
1489         (WebCore::MediaPlayerPrivate::paint): Call view:setFrame: when in a media document so 
1490         the movie is drawn in the correct location.
1491
1492         * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
1493         (WebCore::MediaPlayerPrivate::setSize):  Changed from setRect
1494         * platform/graphics/qt/MediaPlayerPrivatePhonon.h:
1495
1496         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.cpp:
1497         (WebCore::MediaPlayerPrivate::setSize):  Changed from setRect
1498         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.h:
1499
1500         * rendering/RenderVideo.cpp:
1501         (WebCore::RenderVideo::updatePlayer): Call setSize instead of setRect.
1502
1503 2009-03-06  Darin Adler  <darin@apple.com>
1504
1505         Reviewed by Darin Fisher.
1506
1507         Bug 24422: REGRESSION: null-URL crash in FrameLoader setting location.hash on new window
1508         https://bugs.webkit.org/show_bug.cgi?id=24422
1509         rdar://problem/6402208
1510
1511         Test: fast/dom/location-new-window-no-crash.html
1512
1513         The issue here is empty (or null) URLs. I picked the "schedule navigation" bottleneck
1514         to add some checks for empty URLs. We could also put the empty URL checks at some
1515         other bottleneck level and add more assertions over time. I tried adding a few more
1516         assertions to functions like loadURL and hit them while running the regression tests,
1517         so it's probably going to be a bit tricky to clean this up throughout the loader.
1518
1519         * loader/FrameLoader.cpp:
1520         (WebCore::ScheduledRedirection::ScheduledRedirection): Explicitly marked this struct
1521         immutable by making all its members const. Added assertions about the arguments,
1522         including that the URL is not empty. Initialized one uninitialized member in one of
1523         the constructors.
1524         (WebCore::FrameLoader::scheduleHTTPRedirection): Added an early exit to make this
1525         a no-op if passed an empty URL.
1526         (WebCore::FrameLoader::scheduleLocationChange): Ditto.
1527         (WebCore::FrameLoader::scheduleRefresh): Ditto.
1528
1529 2009-03-06  Gustavo Noronha Silva  <gns@gnome.org>
1530
1531         Reviewed by Holger Freyther.
1532
1533         https://bugs.webkit.org/show_bug.cgi?id=24423
1534         Use new soup_message_body_set_accumulate API in soup backend
1535
1536         Disable accumulating chunks for request_body on file uploads,
1537         using the new soup API.
1538
1539         * platform/network/soup/ResourceHandleSoup.cpp:
1540         (WebCore::ResourceHandle::startHttp):
1541
1542 2009-03-06  Gustavo Noronha Silva  <gns@gnome.org>
1543
1544         Reviewed by Holger Freyther.
1545
1546         Replace use of deprecated SOUP_MESSAGE_OVERWRITE_CHUNKS flag with
1547         the new soup_message_body_set_accumulate API in soup.
1548
1549         * platform/network/soup/ResourceHandleSoup.cpp:
1550         (WebCore::gotHeadersCallback):
1551         (WebCore::ResourceHandle::startHttp):
1552
1553 2009-03-06  Gustavo Noronha Silva  <gns@gnome.org>
1554
1555         Reviewed by Holger Freyther.
1556
1557         https://bugs.webkit.org/show_bug.cgi?id=24051
1558         Soup backend needs content sniffing capabilities
1559
1560         Perform content sniffing when using soup, so that we have a chance
1561         of figuring out the Content-Type of the file if it's not sent by
1562         the server.
1563
1564         * platform/network/ResourceHandleInternal.h:
1565         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
1566         * platform/network/soup/ResourceHandleSoup.cpp:
1567         (WebCore::gotHeadersCallback):
1568         (WebCore::gotChunkCallback):
1569
1570 2009-03-06  Hironori Bono  <hbono@chromium.org>
1571
1572         Reviewed by Alexey Proskuryakov.
1573
1574         https://bugs.webkit.org/show_bug.cgi?id=24342
1575         Cannot insert a Thai character after a Thai prepend character when using ICU 4.0
1576
1577         This change creates a new break iterator "cursorMovementIterator" for
1578         moving cursors and use it when moving an input cursor.
1579         In "TextBreakIteratorICU.cpp", this break iterator uses custom ruleset
1580         based on the one of ICU 3.8.
1581         On the other hand, in "TextBreakIteratorQt.cpp", this break iterator
1582         just calls the characterBreakIterator() function.
1583
1584         Test: editing/inserting/insert-thai-characters-001.html
1585
1586         * platform/text/TextBreakIterator.h: Added a new function cursorMovementIterator().
1587         * platform/text/TextBreakIteratorICU.cpp: Implemented the cursorMovementIterator() function for ICU.
1588         (WebCore::setUpIteratorWithRules): Ditto.
1589         (WebCore::cursorMovementIterator): Ditto.
1590         * platform/text/qt/TextBreakIteratorQt.cpp: Implemented the cursorMovementIterator() function for Qt.
1591         (WebCore::cursorMovementIterator): Ditto.
1592         * rendering/RenderText.cpp: Call the cursorMovementIterator() function when moving an input cursor.
1593         (WebCore::RenderText::previousOffset): Ditto.
1594         (WebCore::RenderText::nextOffset): Ditto.
1595
1596 2009-03-05  Alexey Proskuryakov  <ap@webkit.org>
1597
1598         Reviewed by Oliver Hunt.
1599
1600         <rdar://problem/6621701> Safari 4 Beta Breaks XMLHttpRequest Response Text With Special
1601         Characters (a compatibility issue with widgets).
1602
1603         Test: http/tests/xmlhttprequest/broken-xml-encoding.html
1604
1605         Revert part of an Acid 3 fix - now we are no longer strict when decoding XMLHttpRequest XML
1606         responses.
1607
1608         * loader/TextResourceDecoder.cpp:
1609         (WebCore::TextResourceDecoder::TextResourceDecoder):
1610         (WebCore::TextResourceDecoder::decode):
1611         (WebCore::TextResourceDecoder::flush):
1612         * loader/TextResourceDecoder.h:
1613         (WebCore::TextResourceDecoder::useLenientXMLDecoding):
1614         Don't stop on XML decoding errors if useLenientXMLDecoding() was called.
1615
1616         * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::didReceiveData): Don't stop on XML
1617         decoding errors. This behavior is now limited to other kinds of XML content.
1618
1619 2009-03-05  Simone Fiorentino  <simone.fiorentino@consulenti.fastweb.it>
1620
1621         Bug 24382: request to add SH4 platform
1622
1623         <https://bugs.webkit.org/show_bug.cgi?id=24382>
1624
1625         Reviewed by David Kilzer.
1626
1627         * platform/text/AtomicString.cpp:
1628         (WebCore::equal): Aligned memory access on SH4 platform.
1629
1630 2009-03-05  Jeremy Moskovich  <jeremy@chromium.org>
1631
1632         Reviewed by Simon Fraser.
1633
1634         Fix for https://bugs.webkit.org/show_bug.cgi?id=24215
1635
1636         Gears expects an object tag with display:none to instantiate the plugin,
1637         so we add a workaround to make this work and fix Gears on WebKit trunk.
1638
1639         * html/HTMLObjectElement.cpp:
1640         (WebCore::HTMLObjectElement::rendererIsNeeded):
1641
1642 2009-03-05  Avi Drissman  <avi@chromium.org>
1643
1644         Reviewed by Darin Fisher.
1645
1646         Need to have Chromium Mac match Safari Mac's accesskey handling
1647         https://bugs.webkit.org/show_bug.cgi?id=24404
1648
1649         * page/chromium/EventHandlerChromium.cpp:
1650         (WebCore::EventHandler::accessKeyModifiers): Share access key modifiers with Mac Safari when building for the Mac.
1651
1652 2009-03-05  Simon Fraser  <simon.fraser@apple.com>
1653
1654         Reviewed by Dave Hyatt
1655
1656         https://bugs.webkit.org/show_bug.cgi?id=24412
1657         
1658         Fix crash when hit-testing elements with -webkit-transform-style: preserve-3d
1659         but no transform. We need to make localTransformState if we see preserve-3d.
1660         Also need to call update3DTransformedDescendantStatus() before we test
1661         m_has3DTransformedDescendant.
1662
1663         Test: transforms/3d/hit-testing/hit-preserves-3d.html
1664
1665         * rendering/RenderLayer.cpp:
1666         (WebCore::RenderLayer::hitTestLayer):
1667
1668 2009-03-05  Eric Seidel  <eric@webkit.org>
1669
1670         Reviewed by David Hyatt.
1671
1672         Changes to RenderLayer destruction to hopefully help catch an elusive crasher
1673         https://bugs.webkit.org/show_bug.cgi?id=24409
1674         
1675         Added a new RenderBoxModelObject::destroyLayer() call which is
1676         now the only way which RenderLayers should ever be destroyed.
1677         This ensures that the pointer to the layer is cleared in the
1678         RenderObject after destruction, allowing us to ASSERT in the
1679         RenderBoxModelObject destructor.
1680
1681         * rendering/RenderBox.cpp:
1682         (WebCore::RenderBox::calcAbsoluteHorizontalReplaced):
1683         * rendering/RenderBoxModelObject.cpp:
1684         (WebCore::RenderBoxModelObject::~RenderBoxModelObject):
1685         (WebCore::RenderBoxModelObject::destroyLayer):
1686         (WebCore::RenderBoxModelObject::destroy):
1687         (WebCore::RenderBoxModelObject::styleDidChange):
1688         * rendering/RenderBoxModelObject.h:
1689         * rendering/RenderLayer.cpp:
1690         (WebCore::RenderLayer::stackingContext):
1691         (WebCore::RenderLayer::destroy):
1692         (WebCore::RenderLayer::removeOnlyThisLayer):
1693         * rendering/RenderLayer.h:
1694         * rendering/RenderObject.cpp:
1695         (WebCore::RenderObject::destroy):
1696         * rendering/RenderWidget.cpp:
1697         (WebCore::RenderWidget::destroy):
1698
1699 2009-03-05  Eric Seidel  <eric@webkit.org>
1700
1701         Reviewed by David Hyatt.
1702
1703         Remove old, unused IE 5.5 scrollbar-* CSS properties.
1704         Sort the unimplemented getComputedStyle properties so it's
1705         easier to see which ones actually need implementation.
1706
1707         * css/CSSComputedStyleDeclaration.cpp:
1708         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1709         * css/CSSParser.cpp:
1710         (WebCore::CSSParser::parseValue):
1711         * css/CSSPropertyNames.in:
1712         * css/CSSStyleSelector.cpp:
1713         (WebCore::CSSStyleSelector::applyProperty):
1714
1715 2009-03-05  Justin Garcia  <justin.garcia@apple.com>
1716
1717         Reviewed by Darin Adler.
1718         
1719         WebViewDidChangeSelectionNotifications weren't being sent for commands that change the selection's position
1720         within the document without changing its position in the DOM.  For example, pressing return in (caret marked by ^):
1721         <div contentEditable="true"><div>^Hello</div></div>
1722         Undo was being enabled, shouldDeleteDOMRange called, etc. when doing no-op deletes (a delete in an empty document 
1723         for example). 
1724
1725         Changes to layout tests demonstrate fix.
1726         
1727         * editing/EditCommand.cpp:
1728         (WebCore::EditCommand::apply): Don't call applyEditing for a TypingCommand.  The TypingCommand knows whether or
1729         not it did work that needs to be applied.
1730         * editing/Editor.cpp:
1731         (WebCore::Editor::appliedEditing): Moved code (but did not alter) to changeSelectionAfterCommand.
1732         (WebCore::Editor::unappliedEditing): Ditto.
1733         (WebCore::Editor::reappliedEditing): Ditto.
1734         (WebCore::Editor::changeSelectionAfterCommand): Moved code from *appliedEditing into here.  Also call out to
1735         EditorClient::respondToChangedSelection() for commands that changed the selection's position in the document
1736         even if they did not change it's position in the DOM.  Any TypingCommand that gets this far changed it's position
1737         in the document.
1738         * editing/Editor.h:
1739         * editing/TypingCommand.cpp:
1740         (WebCore::TypingCommand::TypingCommand): Removed unused m_appliedEditing.
1741         (WebCore::TypingCommand::typingAddedToOpenCommand): Always apply editing.  We won't get this far if we don't need to.
1742         (WebCore::TypingCommand::deleteKeyPressed): Don't do any of the things that only make sense for Range selections, like
1743         adding to the killring and responding to a change in selections if the delete was a no-op.
1744         (WebCore::TypingCommand::forwardDeleteKeyPressed): Ditto.
1745         * editing/TypingCommand.h:
1746
1747 2009-03-05  Dimitri Glazkov  <dglazkov@chromium.org>
1748
1749         Reviewed by Adam Roben.
1750
1751         Eliminate a ref-counting leak in InspectorController.
1752
1753         * inspector/InspectorController.h: Made constructor private, added static create method.
1754         * page/Page.cpp:
1755         (WebCore::Page::Page): Change initializer to use static create method.
1756
1757 2009-03-05  Dimitri Glazkov  <dglazkov@chromium.org>
1758
1759         Reviewed by Timothy Hatcher.
1760
1761         https://bugs.webkit.org/show_bug.cgi?id=24355
1762         Add InspectorController.idl and convert InspectorController.cpp to use
1763         JSC bindings.
1764
1765         * DerivedSources.make: Added InspectorController.idl
1766         * WebCore.xcodeproj/project.pbxproj: Added idl, bindings files.
1767         * bindings/js/JSInspectorControllerCustom.cpp: Added.
1768         * bindings/scripts/CodeGeneratorJS.pm: Added Array to no-header types.
1769         * inspector/InspectorController.cpp: Removed hand-rolled bindings.
1770         * inspector/InspectorController.h: Added platform and addSourceToFrame methods.
1771         * inspector/InspectorController.idl: Added.
1772         * page/Page.h: Changed member to RefPtr since InspectorController is now ref-counted.
1773
1774 2009-03-05  Eric Carlson  <eric.carlson@apple.com>
1775
1776         Reviewed by Simon Fraser.
1777
1778         https://bugs.webkit.org/show_bug.cgi?id=24400
1779         Bug 24400: Remove "start", "end", "loopStart", "loopEnd", "currentLoop", and "playCount" 
1780         media element attributes
1781
1782         Test: media/video-loop.html
1783
1784         * html/HTMLMediaElement.cpp:
1785         (WebCore::HTMLMediaElement::HTMLMediaElement):
1786         (WebCore::HTMLMediaElement::loadInternal):
1787         (WebCore::HTMLMediaElement::setNetworkState):
1788         (WebCore::HTMLMediaElement::seek):
1789         (WebCore::HTMLMediaElement::playInternal):
1790         (WebCore::HTMLMediaElement::loop):
1791         (WebCore::HTMLMediaElement::setLoop):
1792         (WebCore::HTMLMediaElement::mediaPlayerTimeChanged):
1793         (WebCore::HTMLMediaElement::endedPlayback):
1794         (WebCore::HTMLMediaElement::updatePlayState):
1795         * html/HTMLMediaElement.h:
1796         * html/HTMLMediaElement.idl:
1797
1798 2009-03-05  Steve Falkenburg  <sfalken@apple.com>
1799
1800         <rdar://problem/6651112> Safari asks about re-posting a form even when page is cached
1801         
1802         Reviewed by Ada Chan.
1803
1804         * platform/network/cf/ResourceHandleCFNet.cpp:
1805         (WebCore::ResourceHandle::willLoadFromCache): Ported from Mac version.
1806
1807 2009-03-05  David Hyatt  <hyatt@apple.com>
1808
1809         Reviewed by Eric Seidel
1810
1811         https://bugs.webkit.org/show_bug.cgi?id=24248
1812
1813         Make sure painting of overflow controls checks that visibility:visible is set on the block before
1814         painting.  Pixel tests caught this regression.
1815
1816         Make sure resizer painting pushes a clip of the corner rect.  It was relying on the clip layers happened
1817         to do to their bounds (which had nothing to do with overflow).
1818
1819         * rendering/RenderBlock.cpp:
1820         (WebCore::RenderBlock::paint):
1821         * rendering/RenderLayer.cpp:
1822         (WebCore::RenderLayer::paintResizer):
1823
1824 2009-03-05  Yong Li  <yong.li@torchmobile.com>
1825
1826         Reviewed by Simon Fraser.
1827
1828         https://bugs.webkit.org/show_bug.cgi?id=24386
1829         A faster implementation of extractMIMETypeFromMediaType.
1830
1831         * platform/network/HTTPParsers.cpp:
1832         (WebCore::extractMIMETypeFromMediaType):
1833
1834 2009-03-05  Yong Li  <yong.li@torchmobile.com>
1835
1836         Reviewed by Antti Koivisto.
1837
1838         https://bugs.webkit.org/show_bug.cgi?id=24392
1839         Do not get the current time for unless we're doing PRELOAD_DEBUG as this
1840         can be unnecessarily expensive.
1841
1842         * html/PreloadScanner.cpp:
1843         (WebCore::PreloadScanner::write):
1844
1845 2009-03-04  Simon Fraser  <simon.fraser@apple.com>
1846
1847         Reviewed by Dave Hyatt
1848
1849         https://bugs.webkit.org/show_bug.cgi?id=24327
1850         
1851         When mapping points and hit testing through transforms, work
1852         correctly when acclerated animations of transforms are running.
1853         
1854         Tested by LayoutTests/animations/animation-hit-test-transform.html,
1855         which only failed when ACCELERATED_COMPOSITING was turned on.
1856
1857         * rendering/RenderLayer.cpp:
1858         (WebCore::RenderLayer::currentTransform):
1859         * rendering/RenderLayer.h:
1860         * rendering/RenderObject.cpp:
1861         (WebCore::RenderObject::transformFromContainer):
1862
1863 2009-03-05  Mike Belshe  <mike@belshe.com>
1864
1865         Reviewed by Darin Fisher.
1866
1867         https://bugs.webkit.org/show_bug.cgi?id=24391
1868         Frame.cpp uses JSC specific includes
1869
1870         * page/Frame.cpp:
1871
1872 2009-03-05  Gustavo Noronha Silva  <gns@gnome.org>
1873
1874         Reviewed by Alexey Proskuryakov.
1875
1876         https://bugs.webkit.org/show_bug.cgi?id=24389
1877         WebKitGTK+ crashes when cancelling plugin loads
1878
1879         Remove bogus calls to the client's didFinishLoading method from
1880         our ResourceHandle::cancel implementation. Calling
1881         didFinishLoading here is mostly inoffensive for most loads, but
1882         causes crashes when plugin loads are cancelled.
1883
1884         * platform/network/soup/ResourceHandleSoup.cpp:
1885         (WebCore::ResourceHandle::cancel):
1886
1887 2009-03-05  Steve Falkenburg  <sfalken@apple.com>
1888
1889         Windows build fix.
1890         
1891         * WebCore.vcproj/QTMovieWin.vcproj:
1892
1893 2009-03-05  Adam Treat  <adam.treat@torchmobile.com>
1894
1895         Build fix for when ENABLE_NETSCAPE_PLUGIN_API = 0.  The method
1896         ScriptController::jsObjectForPluginElement(HTMLPlugInElement*); is not
1897         protected by an #if and uses HTMLPlugInElement so it must be included.
1898
1899         * bindings/js/ScriptController.cpp:
1900
1901 2009-03-05  Dimitri Glazkov  <dglazkov@chromium.org>
1902
1903         GTK Build fix.
1904
1905         * inspector/ConsoleMessage.h: Use proper header.
1906
1907 2009-03-05  Dimitri Glazkov  <dglazkov@chromium.org>
1908
1909         Reviewed by Timothy Hatcher.
1910
1911         https://bugs.webkit.org/show_bug.cgi?id=24376
1912         Split InspectorController.cpp file into separate classes.
1913
1914         * GNUmakefile.am: Modified to include new files.
1915         * WebCore.pro: Ditto.
1916         * WebCore.scons: Ditto.
1917         * WebCore.vcproj/WebCore.vcproj: Ditto.
1918         * WebCore.xcodeproj/project.pbxproj: Ditto.
1919         * WebCoreSources.bkl: Ditto.
1920         * inspector/ConsoleMessage.cpp: Added.
1921         * inspector/ConsoleMessage.h: Added.
1922         * inspector/InspectorController.cpp:
1923         * inspector/InspectorDOMStorageResource.cpp: Added.
1924         * inspector/InspectorDOMStorageResource.h: Added.
1925         * inspector/InspectorDatabaseResource.cpp: Added.
1926         * inspector/InspectorDatabaseResource.h: Added.
1927         * inspector/InspectorResource.cpp: Added.
1928         * inspector/InspectorResource.h: Added.
1929
1930 2009-03-05  Eric Carlson  <eric.carlson@apple.com>
1931
1932         Reviewed by Darin Adler
1933
1934         https://bugs.webkit.org/show_bug.cgi?id=24387
1935         Remove media element bufferingRate attribute. No test necessary as there
1936         were none for this attribute.
1937
1938         * html/HTMLMediaElement.cpp:
1939         (WebCore::HTMLMediaElement::HTMLMediaElement): Don't initialize m_bufferingRate.
1940         (WebCore::HTMLMediaElement::loadInternal): Ditto.
1941         (WebCore::HTMLMediaElement::setNetworkState): Ditto.
1942         (WebCore::HTMLMediaElement::progressEventTimerFired): Don't calculate m_bufferingRate.
1943         * html/HTMLMediaElement.h: Remove m_bufferingRate.
1944         * html/HTMLMediaElement.idl: Ditto.
1945
1946 2009-03-05  Xan Lopez  <xan@gnome.org>
1947
1948         Reviewed by Mark Rowe.
1949
1950         https://bugs.webkit.org/show_bug.cgi?id=24377
1951         [GTK] Comply better with coding style guidelines in ResourceHandleSoup
1952
1953         Use C++ booleans, 0 instead of NULL, prefix boolean variables with
1954         'is', do not use 'else if' if the previous if had a return, delete
1955         trailing whitespace, etc.
1956
1957         * platform/network/ResourceHandleInternal.h:
1958         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
1959         * platform/network/soup/ResourceHandleSoup.cpp:
1960         (WebCore::WebCoreSynchronousLoader::WebCoreSynchronousLoader):
1961         (WebCore::fillResponseFromMessage):
1962         (WebCore::restartedCallback):
1963         (WebCore::finishedCallback):
1964         (WebCore::parseDataUrl):
1965         (WebCore::ensureSessionIsInitialized):
1966         (WebCore::ResourceHandle::startHttp):
1967         (WebCore::reportUnknownProtocolError):
1968         (WebCore::ResourceHandle::start):
1969         (WebCore::cleanupGioOperation):
1970         (WebCore::closeCallback):
1971         (WebCore::readCallback):
1972         (WebCore::openCallback):
1973         (WebCore::queryInfoCallback):
1974         (WebCore::ResourceHandle::startGio):
1975
1976 2009-03-04  Simon Fraser  <simon.fraser@apple.com>
1977
1978         Reviewed by Eric Seidel
1979
1980         https://bugs.webkit.org/show_bug.cgi?id=24328
1981         
1982         If an element has backface-visibility: hidden, hit testing should not
1983         hit the back sides of elements. Test for that by inverting the accumulated
1984         transform and looking at the z vector.
1985
1986         Tested by transforms/3d/hit-testing/backface-hit-test.html
1987         
1988         * rendering/RenderLayer.cpp:
1989         (WebCore::RenderLayer::hitTestLayer):
1990
1991 2009-03-04  Adam Langley  <agl@google.com>
1992
1993         Reviewed by Darin Fisher.
1994
1995         r41362 mistakenly added functions "RenderThemeWin::" into
1996         RenderThemeChromiumGtk.cpp. When correcting this, I somehow changed
1997         them to void return types. This patch switches them back to ints.
1998
1999         https://bugs.webkit.org/show_bug.cgi?id=24360
2000
2001         * rendering/RenderThemeChromiumLinux.cpp:
2002         (WebCore::RenderThemeChromiumLinux::buttonInternalPaddingLeft):
2003         (WebCore::RenderThemeChromiumLinux::buttonInternalPaddingRight):
2004         (WebCore::RenderThemeChromiumLinux::buttonInternalPaddingTop):
2005         (WebCore::RenderThemeChromiumLinux::buttonInternalPaddingBottom):
2006
2007 2009-03-04  Adam Langley  <agl@google.com>
2008
2009         Reviewed by Darin Fisher.
2010
2011         Chromium Linux: change some metrics to better match Windows after
2012         r41416. Aesthetically this may be worse, but web-compat is king.
2013
2014         Also, the previous code had an off by one error when drawing
2015         scrollbars which caused the scrollbar to overflow it's bounds by 1px
2016         at the right and bottom edges.
2017
2018         https://bugs.webkit.org/show_bug.cgi?id=24369
2019
2020         * rendering/RenderThemeChromiumLinux.cpp:
2021         (WebCore::):
2022         (WebCore::RenderThemeChromiumLinux::systemFont):
2023         * platform/chromium/ScrollbarThemeChromiumLinux.cpp:
2024         (WebCore::ScrollbarThemeChromium::paintTrackPiece):
2025
2026 2009-03-04  Eric Seidel  <eric@webkit.org>
2027
2028         Reviewed by Adam Roben.
2029
2030         Add an ASSERT to better demonstrate the cause of the crash in
2031         https://bugs.webkit.org/show_bug.cgi?id=23736
2032
2033         * loader/DocLoader.cpp:
2034         (WebCore::DocLoader::~DocLoader):
2035
2036 2009-03-04  David Levin  <levin@chromium.org>
2037
2038         Reviewed by Alexey Proskuryakov.
2039
2040         Bug 24337: Assert when doing sync XHR in a worker for a cacheable response.
2041         <https://bugs.webkit.org/show_bug.cgi?id=24337>
2042
2043         Tests: http/tests/xmlhttprequest/access-control-basic-denied-preflight-cache.html
2044                http/tests/xmlhttprequest/workers/xmlhttprequest-file-not-found.html
2045
2046         * loader/mac/ResourceLoaderMac.mm:
2047         (WebCore::ResourceLoader::willCacheResponse):
2048         An identifier is only asssigned if resource load callbacks are done.  So don't send
2049         willCacheResponse which uses identifier if resource load callbacks aren't being sent.
2050
2051 2009-03-04  David Levin  <levin@chromium.org>
2052
2053         Reviewed by Alexey Proskuryakov.
2054
2055         Bug 24330: Sync xhr in workers should send an abort exception when the worker is terminated.
2056         <https://bugs.webkit.org/show_bug.cgi?id=24330>
2057
2058         Test: http/tests/xmlhttprequest/workers/abort-exception-assert.html
2059
2060         * dom/ExceptionCode.cpp:
2061         (WebCore::xmlHttpRequestExceptionNames):
2062         Added missing ABORT_ERR whose absence caused an assert.
2063
2064         * loader/WorkerThreadableLoader.cpp:
2065         (WebCore::WorkerThreadableLoader::loadResourceSynchronously):
2066         (WebCore::WorkerThreadableLoader::MainThreadBridge::cancel):
2067         Add more logic to handle the termination case for sync xhr.
2068
2069 2009-03-04  Eric Carlson  <eric.carlson@apple.com>
2070
2071         Reviewed by Antti Koivisto.
2072
2073         https://bugs.webkit.org/show_bug.cgi?id=24364
2074         Add support for HTMLMediaElement canPlayType method. Make
2075         MediaPlayer::supportsType take a ContentType instead of a
2076         separate mime type and codecs parameter.
2077
2078         Test: media/video-can-play-type.html
2079
2080         * dom/DOMImplementation.cpp:
2081         (WebCore::DOMImplementation::createDocument):
2082         * html/HTMLMediaElement.cpp:
2083         (WebCore::HTMLMediaElement::canPlayType): Add canPlayType method.
2084         (WebCore::HTMLMediaElement::loadInternal): selectMediaURL returns a ContentType.
2085         (WebCore::HTMLMediaElement::selectMediaURL): Return a ContentType instead of raw MIME type.
2086         (WebCore::HTMLMediaElement::initialURL): selectMediaURL returns a ContentType.
2087         * html/HTMLMediaElement.h: Add prototype.
2088         * html/HTMLMediaElement.idl: Ditto.
2089         * platform/graphics/MediaPlayer.cpp:
2090         (WebCore::MediaPlayer::load): Take a ContentType instead of raw MIME type.
2091         (WebCore::MediaPlayer::supportsType): Ditto.
2092         * platform/graphics/MediaPlayer.h:
2093
2094 2009-03-04  Antti Koivisto  <antti@apple.com>
2095
2096         Reviewed by Dave Hyatt.
2097
2098         https://bugs.webkit.org/show_bug.cgi?id=24359
2099         Repaint throttling mechanism
2100         
2101         Excessive repainting can slow down page loadind. This implements a timer
2102         based throttling mechanism. It is behind ENABLE(REPAINT_THROTTLING) and not 
2103         enabled by default.
2104
2105         * loader/FrameLoader.cpp:
2106         (WebCore::FrameLoader::checkCompleted):
2107         * page/EventHandler.cpp:
2108         (WebCore::EventHandler::dispatchDragEvent):
2109         (WebCore::EventHandler::dispatchMouseEvent):
2110         (WebCore::EventHandler::keyEvent):
2111         (WebCore::EventHandler::handleTextInputEvent):
2112         * page/FrameView.cpp:
2113         (WebCore::FrameView::FrameView):
2114         (WebCore::FrameView::reset):
2115         (WebCore::FrameView::repaintContentRectangle):
2116         (WebCore::FrameView::beginDeferredRepaints):
2117         (WebCore::FrameView::endDeferredRepaints):
2118         (WebCore::FrameView::checkStopDelayingDeferredRepaints):
2119         (WebCore::FrameView::doDeferredRepaints):
2120         (WebCore::FrameView::updateDeferredRepaintDelay):
2121         (WebCore::FrameView::resetDeferredRepaintDelay):
2122         (WebCore::FrameView::adjustedDeferredRepaintDelay):
2123         (WebCore::FrameView::deferredRepaintTimerFired):
2124         (WebCore::FrameView::paintContents):
2125         * page/FrameView.h:
2126
2127 2009-03-04  Sam Weinig  <sam@webkit.org>
2128
2129         Rubber-stamped by Antti Koivisto.
2130
2131         Remove LOW_BANDWIDTH_DISPLAY as it is not being used by any platforms.
2132
2133         * dom/Document.cpp:
2134         (WebCore::Document::Document):
2135         * dom/Document.h:
2136         (WebCore::Document::haveStylesheetsLoaded):
2137         * html/HTMLTokenizer.cpp:
2138         (WebCore::HTMLTokenizer::scriptHandler):
2139         * loader/Cache.cpp:
2140         (WebCore::Cache::requestResource):
2141         * loader/CachedCSSStyleSheet.cpp:
2142         (WebCore::CachedCSSStyleSheet::checkNotify):
2143         * loader/DocLoader.h:
2144         * loader/FrameLoader.cpp:
2145         (WebCore::FrameLoader::FrameLoader):
2146         (WebCore::FrameLoader::requestFrame):
2147         (WebCore::FrameLoader::stopLoading):
2148         (WebCore::FrameLoader::begin):
2149         (WebCore::FrameLoader::write):
2150         (WebCore::FrameLoader::endIfNotLoadingMainResource):
2151         (WebCore::FrameLoader::checkCompleted):
2152         (WebCore::FrameLoader::requestObject):
2153         (WebCore::FrameLoader::loadItem):
2154         * loader/FrameLoader.h:
2155
2156 2009-03-02  Xan Lopez  <xan@gnome.org>
2157
2158         Reviewed by Mark Rowe.
2159
2160         https://bugs.webkit.org/show_bug.cgi?id=24287
2161         [GTK] Move auth dialog feature to WebKit/
2162
2163         Remove WebKitSoupAuthDialog files from build and stop using it.
2164
2165         * GNUmakefile.am:
2166         * platform/network/soup/ResourceHandleSoup.cpp:
2167         (WebCore::ensureSessionIsInitialized):
2168         * platform/network/soup/webkit-soup-auth-dialog.c: Removed.
2169         * platform/network/soup/webkit-soup-auth-dialog.h: Removed.
2170
2171 2009-03-04  Simon Fraser  <simon.fraser@apple.com>
2172
2173         Reviewed by Dave Hyatt
2174         
2175         https://bugs.webkit.org/show_bug.cgi?id=24361
2176         
2177         Reinstate code that sets result.innerNode when hitTest() returns true,
2178         but never filled in the innerNode. Fixes hit testing of generated content.
2179
2180         Test: fast/css-generated-content/hit-test-generated-content.html
2181
2182         * rendering/RenderLayer.cpp:
2183         (WebCore::RenderLayer::hitTestContents):
2184
2185 2009-03-04  Adam Barth  <abath@webkit.org>
2186
2187         Reviewed by Alexey Proskuryakov.
2188
2189         https://bugs.webkit.org/show_bug.cgi?id=24356
2190
2191         Fix WebKit style for allowUniversalAccessFromFileURLs.
2192
2193         * WebCore.base.exp:
2194         * dom/Document.cpp:
2195         (WebCore::Document::initSecurityContext):
2196         * page/Settings.cpp:
2197         (WebCore::Settings::Settings):
2198         (WebCore::Settings::setAllowUniversalAccessFromFileURLs):
2199         * page/Settings.h:
2200         (WebCore::Settings::allowUniversalAccessFromFileURLs):
2201
2202 2009-03-04  Brady Eidson  <beidson@apple.com>
2203
2204         Reviewed by Darin Adler
2205
2206         <rdar://problem/6619630> Quick Look of vCards stuck on image of first card opened.
2207
2208         I narrowed this down to http://trac.webkit.org/changeset/39304 which, among other things,
2209         consolidated some of the various decision making pieces of the Cache into the new method
2210         FrameLoader::cachePolicy().
2211
2212         Before 39304, when deciding whether to use an existing CachedResource, we checked if the FrameLoader 
2213         is reloading.  If it is, we'd evict any existing resource then recreate it.  Quick looks uses the
2214         same URL for this image every time and expects it to be reloaded with each new card.
2215
2216         The FrameLoader::isReloading() check did one thing - Ask the DocumentLoader if it's cache policy
2217         is "ReloadIgnoringCacheData".  This check was lost in the consolidation to the new method.  
2218
2219         * loader/FrameLoader.cpp:
2220         (WebCore::FrameLoader::cachePolicy): Restore the DocumentLoader's cachePolicy check as a possible
2221           condition for returning CachePolicyReload.
2222
2223 2009-03-04  Timothy Hatcher  <timothy@apple.com>
2224
2225         * English.lproj/localizedStrings.js: Update strings to include "DATABASES",
2226         "LOCAL STORAGE" and "SESSION STORAGE".
2227
2228 2009-03-04  Timothy Hatcher  <timothy@apple.com>
2229
2230         Fix a regression where the Web Inspector console would not animate
2231         in or out correctly.
2232
2233         Reviewed by Anders Carlsson.
2234
2235         * inspector/front-end/inspector.css: Move a z-index to a child element
2236         to get the correct stacking order during the animation.
2237
2238 2009-03-03  David Hyatt  <hyatt@apple.com>
2239
2240         https://bugs.webkit.org/show_bug.cgi?id=24201, pathologically bad block layout.
2241
2242         Make sure to factor clear deltas into y position estimates.  Also avoid doing the comparison of
2243         the final position against the y position estimate until after the clear has happened.  This gets rid
2244         of some duplicated cut/pasted code and also ensures a layout delta only has to be put in once.
2245
2246         Reviewed by Dan Bernstein
2247
2248         Added fast/block/float/nested-clearance.html
2249
2250         * rendering/RenderBlock.cpp:
2251         (WebCore::RenderBlock::collapseMargins):
2252         (WebCore::RenderBlock::clearFloatsIfNeeded):
2253         (WebCore::RenderBlock::estimateVerticalPosition):
2254         (WebCore::RenderBlock::layoutBlockChildren):
2255         (WebCore::RenderBlock::getClearDelta):
2256         * rendering/RenderBlock.h:
2257
2258 2009-03-02  Kim Grönholm  <kim.gronholm@nomovok.com>
2259
2260         Reviewed by Simon Hausmann.
2261
2262         Improvement to 3d transformations rendering in QtWebKit. QTransform is used
2263         instead of QMatrix. This allows perspective transformations since QTransform is
2264         a true 3x3 matrix.
2265
2266         * platform/graphics/qt/GraphicsContextQt.cpp: Use QTransform instead of QMatrix everywhere.
2267         (WebCore::GraphicsContext::getCTM):
2268         (WebCore::GraphicsContext::restorePlatformState):
2269         (WebCore::GraphicsContext::fillPath):
2270         (WebCore::GraphicsContext::strokePath):
2271         (WebCore::GraphicsContext::fillRect):
2272         (WebCore::GraphicsContext::translate):
2273         (WebCore::GraphicsContext::rotate):
2274         (WebCore::GraphicsContext::scale):
2275         (WebCore::GraphicsContext::concatCTM):
2276         * platform/graphics/qt/ImageQt.cpp:
2277         (WebCore::Image::drawPattern):
2278         * platform/graphics/qt/PathQt.cpp:
2279         (WebCore::Path::translate):
2280         (WebCore::Path::transform):
2281         * platform/graphics/qt/PatternQt.cpp:
2282         (WebCore::Pattern::createPlatformPattern):
2283         * platform/graphics/qt/TransformationMatrixQt.cpp:
2284         (WebCore::TransformationMatrix::operator QTransform): Replace the conversion operator
2285         to QMatrix with one to QTransform.
2286         * platform/graphics/transforms/TransformationMatrix.h:
2287         * platform/graphics/qt/FontQt.cpp:
2288
2289 2009-02-24  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
2290
2291         Reviewed by Simon Hausmann.
2292
2293         https://bugs.webkit.org/show_bug.cgi?id=24151
2294         Fix Qt/S60 build break
2295
2296         * platform/FileSystem.h: Create a default case for non-win and non-mac Qt builds
2297         * platform/qt/FileSystemQt.cpp: Ditto
2298         (WebCore::unloadModule):
2299
2300 2009-03-03  Mike Belshe  <mike@belshe.com>
2301
2302         Reviewed by Alexey Proskuryakov.
2303
2304         https://bugs.webkit.org/show_bug.cgi?id=21939
2305         Uninitialized ExceptionCode in DOMWindow::postMessage
2306
2307         * dom/MessagePort.cpp:
2308         (WebCore::MessagePort::postMessage):
2309
2310 2009-03-03  David Kilzer  <ddkilzer@apple.com>
2311
2312         <rdar://problem/6581203> WebCore and WebKit should install the same set of headers during installhdrs phase as build phase
2313
2314         Reviewed by Mark Rowe.
2315
2316         The fix is to add INSTALLHDRS_COPY_PHASE = YES and
2317         INSTALLHDRS_SCRIPT_PHASE = YES to WebCore.xcconfig, then to make
2318         sure various build phase scripts work with the installhdrs build
2319         phase.
2320
2321         * Configurations/Base.xcconfig: Defined REAL_PLATFORM_NAME
2322         based on PLATFORM_NAME to work around the missing definition on
2323         Tiger.
2324         * Configurations/WebCore.xcconfig: Added
2325         JAVASCRIPTCORE_PRIVATE_HEADERS_DIR variable to simplify logic in
2326         the "Generate Derived Sources" script.  Added
2327         INSTALLHDRS_COPY_PHASE = YES and INSTALLHDRS_SCRIPT_PHASE = YES.
2328
2329         * WebCore.xcodeproj/project.pbxproj:
2330         - Added shell code to prevent running "Check For Global
2331           Initializers", "Check For Exit Time Destructors" and "Check
2332           For Weak VTables" scripts during the installhdrs build phase.
2333         - Made "Generate Derived Sources" work for the installhdrs build
2334           phase.  Also simplified setting of CREATE_HASH_TABLE by using
2335           JAVASCRIPTCORE_PRIVATE_HEADERS_DIR.
2336
2337 2009-03-02  Adam Langley  <agl@google.com>
2338
2339         Reviewed by Darin Fisher.
2340
2341         Chromium Linux: Switch to using Skia to render widgets.
2342
2343         In order to sandbox the Chromium renderer on Linux we need to remove
2344         the X connection. GTK cannot render without an X connection so, for
2345         now, we render widgets ourselves.
2346
2347         Previously didn't use anti-alias fonts in order to match Windows font
2348         rendering exactly. This was helpful when bootstrapping our layout
2349         tests. Now, however, we are ready to enable it.
2350
2351         https://bugs.webkit.org/show_bug.cgi?id=24244
2352
2353         * platform/chromium/ScrollbarThemeChromium.cpp:
2354         (WebCore::ScrollbarThemeChromium::buttonSize):
2355         * platform/chromium/ScrollbarThemeChromiumLinux.cpp:
2356         (WebCore::ScrollbarThemeChromium::scrollbarThickness):
2357         (WebCore::ScrollbarThemeChromium::paintTrackPiece):
2358         (WebCore::ScrollbarThemeChromium::paintButton):
2359         (WebCore::ScrollbarThemeChromium::paintThumb):
2360         * platform/graphics/chromium/FontPlatformDataLinux.cpp:
2361         (WebCore::FontPlatformData::setupPaint):
2362         * platform/graphics/skia/PlatformContextSkia.cpp:
2363         (PlatformContextSkia::PlatformContextSkia):
2364         (PlatformContextSkia::~PlatformContextSkia):
2365         * platform/graphics/skia/PlatformContextSkia.h:
2366         * rendering/RenderThemeChromiumGtk.cpp: Removed.
2367         * rendering/RenderThemeChromiumGtk.h: Removed.
2368         * rendering/RenderThemeChromiumLinux.cpp: Added.
2369         * rendering/RenderThemeChromiumLinux.h: Added.
2370
2371 2009-03-03  Dimitri Glazkov  <dglazkov@chromium.org>
2372
2373         Reviewed by Darin Fisher.
2374
2375         https://bugs.webkit.org/show_bug.cgi?id=24261
2376         Fix return types.
2377
2378         Test: LayoutTests/dom/svg/level3/xpath/XPathEvaluator_evaluate_TYPE_ERR.svg
2379
2380         * bindings/v8/V8Binding.h:
2381         (WebCore::toInt32): change return type to int
2382         (WebCore::toFloat): change return type to float.
2383
2384 2009-03-03  Anders Carlsson  <andersca@apple.com>
2385
2386         Reviewed by John Sullivan.
2387
2388         https://bugs.webkit.org/show_bug.cgi?id=22884
2389         <rdar://problem/6449783>
2390         modified layout test crashes Safari
2391
2392         Null check NPStream before dereferencing it.
2393         
2394         * plugins/PluginView.cpp:
2395         (WebCore::PluginView::destroyStream):
2396
2397 2009-03-03  Eric Carlson  <eric.carlson@apple.com>
2398
2399         Reviewed by Simon Fraser.
2400
2401         Fix for <rdar://problem/6641045>
2402         Don't call QTKit to get movie properties until movie metadata has been loaded.
2403
2404         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
2405         (WebCore::MediaPlayerPrivate::metaDataAvailable): defined
2406         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
2407         (WebCore::MediaPlayerPrivate::createQTTime): return default if !metaDataAvailable.
2408         (WebCore::MediaPlayerPrivate::play): Ditto.
2409         (WebCore::MediaPlayerPrivate::pause): Ditto.
2410         (WebCore::MediaPlayerPrivate::duration): Ditto.
2411         (WebCore::MediaPlayerPrivate::currentTime): Ditto.
2412         (WebCore::MediaPlayerPrivate::seek): Ditto.
2413         (WebCore::MediaPlayerPrivate::seekTimerFired): Ditto.
2414         (WebCore::MediaPlayerPrivate::paused): Ditto.
2415         (WebCore::MediaPlayerPrivate::seeking): Ditto.
2416         (WebCore::MediaPlayerPrivate::naturalSize): Ditto.
2417         (WebCore::MediaPlayerPrivate::hasVideo): Ditto.
2418         (WebCore::MediaPlayerPrivate::setVolume): Ditto.
2419         (WebCore::MediaPlayerPrivate::setRate): Ditto.
2420         (WebCore::MediaPlayerPrivate::dataRate): Ditto.
2421         (WebCore::MediaPlayerPrivate::maxTimeLoaded): Ditto.
2422         (WebCore::MediaPlayerPrivate::totalBytes): Ditto.
2423
2424 2009-03-03  Kevin McCullough  <kmccullough@apple.com>
2425
2426         - Spelling fix.
2427
2428         * page/Console.cpp:
2429         (WebCore::Console::profile):
2430
2431 2009-03-03  Dimitri Glazkov  <dglazkov@chromium.org>
2432
2433         Reviewed by Darin Fisher.
2434
2435         https://bugs.webkit.org/show_bug.cgi?id=23657
2436         Remove Database API callback IDLs from the project. 
2437         They were removed in r40633.
2438
2439         * WebCore.xcodeproj/project.pbxproj: Removed IDL files from the project.
2440
2441 2009-03-03  Kevin McCullough  <kmccullough@apple.com>
2442
2443         Reviewed by Oliver Hunt.
2444
2445         <rdar://problem/6639110> console.profile() doesn't work without a title
2446
2447         * page/Console.cpp:
2448         (WebCore::Console::profile): If there is no title assume this is a user
2449         initiated profile and give it the next incremented title name.
2450
2451 2009-03-03  Timothy Hatcher  <timothy@apple.com>
2452
2453         Fix a regression that broke dirxml and caused an ASSERT in debug builds. Also simplified
2454         the console code and refactored things to have fewer code paths and duplication.
2455
2456         rdar://problem/6367127
2457         https://bugs.webkit.org/show_bug.cgi?id=24329
2458
2459         Reviewed by Kevin McCullough.
2460
2461         Test: manual-tests/inspector/console-dir.html
2462
2463         * bindings/js/JSInspectedObjectWrapper.cpp:
2464         (WebCore::JSInspectedObjectWrapper::wrap): Use the lexicalGlobalObject instead of dynamicGlobalObject
2465         to fix an ASSERT about using a wrapper from the wrong ExecState.
2466         * bindings/js/JSQuarantinedObjectWrapper.cpp:
2467         (WebCore::JSQuarantinedObjectWrapper::JSQuarantinedObjectWrapper): Ditto.
2468         (WebCore::JSQuarantinedObjectWrapper::allowsUnwrappedAccessFrom): Ditto.
2469         * inspector/front-end/Console.js:
2470         (WebInspector.Console.prototype._format): Remove the inline argument and add forceObjectFormat.
2471         When forceObjectFormat is true, the only formatter used is _formatobject.
2472         (WebInspector.Console.prototype._formatvalue): Remove the inline argument.
2473         (WebInspector.Console.prototype._formatstring): Ditto.
2474         (WebInspector.Console.prototype._formatregexp): Ditto.
2475         (WebInspector.Console.prototype._formatarray): Ditto.
2476         (WebInspector.Console.prototype._formatnode): Remove the inline argument and make a DOM tree instead of an anchor.
2477         (WebInspector.Console.prototype._formatobject): Remove the inline argument and always make a property graph.
2478         (WebInspector.Console.prototype._formaterror): Remove the inline argument.
2479         (WebInspector.ConsoleMessage): Remove the case for MessageLevel.Node and
2480         simplify the case for MessageLevel.Object to use the normal _format code path with the %O formatter.
2481         (WebInspector.ConsoleMessage.prototype._format.formatForConsole): Don't pass an additional true argument for inline.
2482         (WebInspector.ConsoleMessage.prototype._format.formatAsObjectForConsole): Added. Pass a true argument for forceObjectFormat.
2483         (WebInspector.ConsoleMessage.prototype._format): Added support for the %O formatter. Use formatForConsole for all arguments.
2484         (WebInspector.ConsoleMessage.prototype.toString): Add the other message levels.
2485         * inspector/front-end/inspector.css: Tweak styles to look and work correctly.
2486         * inspector/front-end/utilities.js:
2487         (Object.type): Return "node" for Node objects.
2488         (Object.describe): Handle the "node" type.
2489         * page/Console.cpp:
2490         (WebCore::printMessageSourceAndLevelPrefix): Fix an assert by adding the other message level types.
2491         (WebCore::Console::dirxml): Use the standard log fuction since it prints a DOM tree for nodes by default.
2492         * page/Console.h:
2493         (WebCore::enum MessageLevel): Removed NodeMessageLevel. Added a FIXME.
2494
2495 2009-03-03  Scott Violet  <sky@google.com>
2496
2497         Reviewed by Eric Seidel.
2498
2499         https://bugs.webkit.org/show_bug.cgi?id=24325
2500         Crash on replacing document contents during drop.
2501
2502         Makes sure a node is in the document during a move before using it.
2503
2504         Test: fast/events/crash-on-mutate-during-drop.html
2505
2506         * editing/MoveSelectionCommand.cpp:
2507         (WebCore::MoveSelectionCommand::doApply):
2508
2509 2009-03-03  Jungshik Shin <jshin@chromium.org>
2510
2511         Reviewed by Eric Seidel.
2512
2513         https://bugs.webkit.org/show_bug.cgi?id=23028
2514         Enable dynamic web font support to Chromium on Windows.
2515         Files that were omitted by mistake in the latest patch
2516         that was landed.
2517
2518         * loader/CachedFont.cpp:
2519         (WebCore::CachedFont::~CachedFont):
2520         (WebCore::CachedFont::ensureCustomFontData):
2521         (WebCore::CachedFont::platformDataFromCustomData):
2522         (WebCore::CachedFont::allClientsRemoved):
2523         * platform/graphics/chromium/FontCustomPlatformData.cpp:
2524         (WebCore::EOTStream::EOTStream):
2525         (WebCore::createFontCustomPlatformData):
2526         * platform/graphics/win/FontCustomPlatformData.cpp:
2527         (WebCore::EOTStream::EOTStream):
2528         (WebCore::createFontCustomPlatformData):
2529
2530 2009-03-03  Gustavo Noronha Silva  <gns@gnome.org>
2531
2532         Reviewed by Alexey Proskuryakov.
2533
2534         https://bugs.webkit.org/show_bug.cgi?id=16826
2535         [Gtk] Implement WebKitDownload
2536
2537         Make the Soup backend able to handle requests without a frame,
2538         since we may have such things now that we support downloads.
2539
2540         * platform/network/ResourceHandleInternal.h:
2541         * platform/network/soup/ResourceHandleSoup.cpp:
2542         (WebCore::ResourceHandle::start):
2543
2544 2009-03-03  Dimitri Glazkov  <dglazkov@chromium.org>
2545
2546         Reviewed by Eric Seidel.
2547
2548         https://bugs.webkit.org/show_bug.cgi?id=24331
2549         Add custom V8 bindings for Element, Attr, HTMLFrame, and HTMLIFrame.
2550
2551         * bindings/v8/custom/V8AttrCustom.cpp: Added.
2552         * bindings/v8/custom/V8CustomBinding.cpp: Added.
2553         * bindings/v8/custom/V8CustomBinding.h: Added attribute-checking helpers.
2554         * bindings/v8/custom/V8ElementCustom.cpp: Added.
2555         * bindings/v8/custom/V8HTMLFrameElementCustom.cpp: Added.
2556         * bindings/v8/custom/V8HTMLIFrameElementCustom.cpp: Added.
2557
2558 2009-03-03  Brady Eidson  <beidson@apple.com>
2559
2560         Reviewed by Darin Adler
2561
2562         <rdar://problem/6616664> - Quick looks of various file types is broken
2563
2564         In http://trac.webkit.org/changeset/40553 there was an attempt to prevent NSURLRequest churn
2565         for non-HTTP loads when the underlying ResourceRequest changed.  Unfortunately it was a little
2566         overzealous as the mainDocumentURL is relevant for all loads, not only HTTP/HTTPS loads.
2567
2568         Partially reverted behavior to always set the mainDocumentURL in situations when we would've
2569         before that patch.
2570
2571         * loader/FrameLoader.cpp:
2572         (WebCore::FrameLoader::addExtraFieldsToRequest):
2573
2574         * platform/network/ResourceRequestBase.cpp:
2575         (WebCore::ResourceRequestBase::setMainDocumentURL):
2576
2577 2009-03-03  Chris Marrin  <cmarrin@apple.com>
2578
2579         Reviewed by Simon Fraser.
2580
2581         https://bugs.webkit.org/show_bug.cgi?id=24256
2582
2583         Added a WebCoreForceSoftwareAnimation flag.
2584
2585         * platform/graphics/mac/GraphicsLayerCA.mm:
2586         (WebCore::forceSoftwareAnimation):
2587         (WebCore::GraphicsLayerCA::setOpacity):
2588         (WebCore::GraphicsLayerCA::animateTransform):
2589         (WebCore::GraphicsLayerCA::animateFloat):
2590
2591 2009-03-02  Chris Marrin  <cmarrin@apple.com>
2592
2593         Reviewed by Sam Weinig.
2594
2595         https://bugs.webkit.org/show_bug.cgi?id=24257
2596
2597         Added prototype properties for several classes with constructors that
2598         were missing them, including the one mentioned in the bug.
2599
2600         Test: fast/dom/Window/custom-constructors.html
2601
2602         * bindings/js/JSAudioConstructor.cpp:
2603         (WebCore::JSAudioConstructor::JSAudioConstructor):
2604         * bindings/js/JSDOMWindowBase.cpp:
2605         (jsDOMWindowBaseWebKitCSSMatrix):
2606         * bindings/js/JSImageConstructor.cpp:
2607         (WebCore::JSImageConstructor::JSImageConstructor):
2608         * bindings/js/JSOptionConstructor.cpp:
2609         (WebCore::JSOptionConstructor::JSOptionConstructor):
2610         * bindings/js/JSWebKitCSSMatrixConstructor.cpp:
2611         (WebCore::JSWebKitCSSMatrixConstructor::JSWebKitCSSMatrixConstructor):
2612         * bindings/js/JSWebKitCSSMatrixConstructor.h:
2613         * bindings/js/JSWebKitPointConstructor.cpp:
2614         (WebCore::JSWebKitPointConstructor::JSWebKitPointConstructor):
2615         * bindings/js/JSWorkerConstructor.cpp:
2616         (WebCore::JSWorkerConstructor::JSWorkerConstructor):
2617
2618 2009-03-03  Dimitri Glazkov  <dglazkov@chromium.org>
2619
2620         Reviewed by Darin Fisher.
2621
2622         https://bugs.webkit.org/show_bug.cgi?id=24321
2623         Add V8 bindings headers.
2624
2625         * bindings/v8/V8Binding.h: Added.
2626         * bindings/v8/V8Proxy.h: Added.
2627         * bindings/v8/custom/V8CustomBinding.h: Added.
2628         * bindings/v8/custom/V8CustomEventListener.h: Added.
2629
2630 2009-03-03  Jungshik Shin <jshin@chromium.org>
2631
2632         Reviewed by Eric Seidel.
2633
2634         https://bugs.webkit.org/show_bug.cgi?id=23803
2635         Fix an 'off-by-1' error in ChromiumWin's font fallback.
2636
2637         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
2638         (WebCore::FontCache::getFontDataForCharacters):
2639
2640 2009-03-03  Jungshik Shin  <jshin@chromium.org>
2641
2642         Reviewed by Eric Seidel.
2643
2644         http://bugs.webkit.org/show_bug.cgi?id=23028
2645         Enable dynamic web font support to Chromium on Windows: Part 1
2646         - Move OpenTypeUtilities.{cpp,h} to platform/graphics/opentype
2647           from platform/graphics/win because both Windows port and Chromium Windows
2648           port will use them.
2649         - Adjust WebCore.vcproj accordingly.
2650
2651         * WebCore.vcproj/WebCore.vcproj:
2652         * platform/graphics/opentype: Added.
2653         * platform/graphics/opentype/OpenTypeUtilities.cpp: Copied from WebCore/platform/graphics/win/OpenTypeUtilities.cpp.
2654         * platform/graphics/opentype/OpenTypeUtilities.h: Copied from WebCore/platform/graphics/win/OpenTypeUtilities.h.
2655         * platform/graphics/win/OpenTypeUtilities.cpp: Removed.
2656         * platform/graphics/win/OpenTypeUtilities.h: Removed.
2657
2658 2009-03-03  Simon Fraser  <simon.fraser@apple.com>
2659
2660         Reviewed by Dave Hyatt
2661
2662         https://bugs.webkit.org/show_bug.cgi?id=24312
2663         
2664         Take 3D transforms into account when hit testing:
2665         
2666         1. Maintain a bit on each RenderLayer that is set when the layer
2667            has 3d descendants, so that we know when to fall into the slow
2668            hit testing path.
2669            
2670         2. Make a ref-counted HitTestingTransformState, which is used to store
2671            an accumulated transform, and the hit test point, and hitTestRect
2672            in the plane of the ancestor non-3d ('flattening') layer.
2673            
2674            It's ref-counted so we can heap allocate it (to avoid stack bloat),
2675            and avoid copying when hitTestLayer calls itself after applying the transform.
2676            
2677         3. Add logic to hitTestLayer to depth-test just direct descendants, if any have
2678            3D transforms, or to do deep depth-testing when traversing a preserves-3d
2679            hierarchy. When hit, layers compute a z-offset from the ancestor flattening
2680            layer, which allows for correct depth testing.
2681            
2682            The existing early-return codepath is unaffected when there are no 3d transforms
2683            and no preserve-3d.
2684
2685         * rendering/RenderLayer.cpp:
2686         (WebCore::RenderLayer::RenderLayer):
2687         (WebCore::RenderLayer::updateTransform):
2688         (WebCore::RenderLayer::dirty3DTransformedDescendantStatus):
2689         (WebCore::RenderLayer::update3DTransformedDescendantStatus):
2690         (WebCore::RenderLayer::hitTest):
2691         (WebCore::computeZOffset):
2692         (WebCore::RenderLayer::createLocalTransformState):
2693         (WebCore::RenderLayer::hitTestLayer):
2694         (WebCore::RenderLayer::hitTestContents):
2695         * rendering/RenderLayer.h:
2696         (WebCore::RenderLayer::preserves3D):
2697         (WebCore::RenderLayer::has3DTransform):
2698         (WebCore::RenderLayer::setHas3DTransformedDescendant):
2699         (WebCore::RenderLayer::has3DTransformedDescendant):
2700         * rendering/RenderLayerBacking.cpp:
2701         * rendering/TransformState.cpp:
2702         (WebCore::TransformState::flatten):
2703         (WebCore::TransformState::mappedPoint):
2704         (WebCore::HitTestingTransformState::move):
2705         (WebCore::HitTestingTransformState::applyTransform):
2706         (WebCore::HitTestingTransformState::flatten):
2707         (WebCore::HitTestingTransformState::mappedPoint):
2708         (WebCore::HitTestingTransformState::mappedQuad):
2709         * rendering/TransformState.h:
2710         (WebCore::TransformState::TransformState):
2711         (WebCore::HitTestingTransformState::create):
2712         (WebCore::HitTestingTransformState::move):
2713         (WebCore::HitTestingTransformState::HitTestingTransformState):
2714
2715 2009-03-03  Brett Wilson  <brettw@chromium.org>
2716
2717         Fix uninitialized memory reads in the Chromium Windows transparency
2718         code that were identified by Purify,
2719
2720         Reviewed by Darin Fisher.
2721
2722         * platform/graphics/chromium/TransparencyWin.cpp:
2723         (WebCore::TransparencyWin::OwnedBuffers::OwnedBuffers):
2724         (WebCore::TransparencyWin::initializeNewContext):
2725
2726 2009-03-03  Simon Fraser  <simon.fraser@apple.com>
2727
2728         Reviewed by Dave Hyatt
2729
2730         https://bugs.webkit.org/show_bug.cgi?id=24312
2731         
2732         Factor the code that compute a transform relative to the container
2733         into RenderObject::transformFromContainer().
2734         
2735         * rendering/RenderBox.cpp:
2736         (WebCore::RenderBox::mapLocalToAbsolutePoint):
2737         (WebCore::RenderBox::mapAbsoluteToLocalPoint):
2738         * rendering/RenderObject.cpp:
2739         (WebCore::RenderObject::transformFromContainer):
2740         * rendering/RenderObject.h:
2741
2742 2009-03-03  Simon Fraser  <simon.fraser@apple.com>
2743
2744         Reviewed by Dave Hyatt
2745
2746         https://bugs.webkit.org/show_bug.cgi?id=24317
2747         
2748         Always return |true| from RenderTextControlMultiLine::nodeAtPoint() if
2749         the superclass found a node, otherwise we set the innerNode of the
2750         HitTestResult, but don't actually report that we found a hit.
2751
2752         * rendering/RenderTextControlMultiLine.cpp:
2753         (WebCore::RenderTextControlMultiLine::nodeAtPoint):
2754
2755 2009-03-03  Onne Gorter  <onne.gorter@avinity.net>
2756
2757         Reviewed by Anders Carlsson.
2758
2759         https://bugs.webkit.org/show_bug.cgi?id=23707
2760         resizing plugins does not work, because the plugin never gets informed
2761
2762         Make gtk plugins resize correctly, by sending them the setwindow event
2763         correctly. Also ensure that all plugin eventing is done with correct
2764         locking/calling. Mostly copied from mac implementation.
2765
2766         manual test: manual-tests/gtk/plugin-resize-scroll.html
2767
2768         * plugins/PluginView.h:
2769         * plugins/gtk/PluginViewGtk.cpp:
2770         (WebCore::PluginView::dispatchNPEvent):
2771         ensure locking/calling for NPEvents
2772         (WebCore::PluginView::updatePluginWidget):
2773         if something changed, let setNPWindowIfNeeded handle it
2774         (WebCore::PluginView::paint):
2775         (WebCore::PluginView::handleKeyboardEvent):
2776         (WebCore::PluginView::handleMouseEvent):
2777         ensure calling conventions
2778         (WebCore::PluginView::setNPWindowRect):
2779         just pass control to setNPWindowIfNeeded
2780         (WebCore::PluginView::setNPWindowIfNeeded):
2781         event the plugin correctly of new window
2782         (WebCore::PluginView::init):
2783         init through the new setup
2784
2785 2009-03-03  Mike Belshe  <mike@belshe.com>
2786
2787         Reviewed by Darin Fisher.
2788
2789         https://bugs.webkit.org/show_bug.cgi?id=24311
2790         Make IDL returning DOMObject use [V8Custom]
2791
2792         * dom/Document.idl:
2793         * html/HTMLCanvasElement.idl:
2794
2795 2009-03-02  Simon Fraser  <simon.fraser@apple.com>
2796
2797         Reviewed by Adele Peterson
2798
2799         https://bugs.webkit.org/show_bug.cgi?id=24313
2800         
2801         If RenderTextControlSingleLine::nodeAtPoint() pokes a node into the
2802         HitTestResult, then it had better well return |true|. And m_innerBlock
2803         could never have been set as the hit node by the superclass, because
2804         the superclass knows nothing about m_innerBlock.
2805         
2806         Test: fast/forms/input-hit-test-border.html
2807
2808         * rendering/RenderTextControlSingleLine.cpp:
2809         (WebCore::RenderTextControlSingleLine::nodeAtPoint):
2810
2811 2009-03-02  Sam Weinig  <sam@webkit.org>
2812
2813         Reviewed by Mark Rowe.
2814
2815         Enable Geolocation (except on Tiger and Leopard).
2816
2817         * Configurations/WebCore.xcconfig:
2818
2819 2009-03-02  Ojan Vafai  <ojan@chromium.org>
2820
2821         Reviewed by Adele Peterson.
2822
2823         Fix https://bugs.webkit.org/show_bug.cgi?id=24307
2824         Null out m_highlightedNode on hideHighlight().
2825         Ran WebCore/manual-tests/inspector/highlight-nodes.html.
2826
2827         * inspector/InspectorController.cpp:
2828         (WebCore::InspectorController::hideHighlight):
2829
2830 2009-03-02  Sam Weinig  <sam@webkit.org>
2831
2832         Reviewed by Geoffrey Garen.
2833
2834         Fix for <rdar://problem/6507404> Add Geolocation support.
2835
2836         This is not yet turned on for any Mac platform.
2837
2838         * WebCore.xcodeproj/project.pbxproj:
2839         * page/Chrome.cpp:
2840         (WebCore::Chrome::shouldAllowGeolocationForFrame):
2841         * page/Chrome.h:
2842         * page/ChromeClient.h:
2843         (WebCore::ChromeClient::shouldAllowGeolocationForFrame):
2844         * page/Geolocation.cpp:
2845         (WebCore::Geolocation::Geolocation):
2846         (WebCore::Geolocation::disconnectFrame): Remove call to setUsingGeolocation as the document
2847         will not be alive at this point.
2848         (WebCore::Geolocation::getCurrentPosition): Check if the embedding app allows geolocation and
2849         return a PERMISSION_DENIED if not.
2850         (WebCore::Geolocation::watchPosition): Ditto.
2851         (WebCore::Geolocation::shouldAllowGeolocation): Perform request to embedding layer of whether
2852         to allow geolocation and cache the result. 
2853         * page/Geolocation.h:
2854         (WebCore::Geolocation::):
2855         * platform/GeolocationService.cpp:
2856         * platform/GeolocationService.h:
2857         (WebCore::GeolocationService::~GeolocationService):
2858         (WebCore::GeolocationService::stopUpdating):
2859         * platform/mac/GeolocationServiceMac.h: Added.
2860         (WebCore::GeolocationServiceMac::lastPosition):
2861         (WebCore::GeolocationServiceMac::lastError):
2862         * platform/mac/GeolocationServiceMac.mm: Added.
2863         (WebCore::GeolocationService::create):
2864         (WebCore::GeolocationServiceMac::GeolocationServiceMac):
2865         (WebCore::GeolocationServiceMac::~GeolocationServiceMac):
2866         (WebCore::GeolocationServiceMac::startUpdating):
2867         (WebCore::GeolocationServiceMac::stopUpdating):
2868         (WebCore::GeolocationServiceMac::suspend):
2869         (WebCore::GeolocationServiceMac::resume):
2870         (WebCore::GeolocationServiceMac::positionChanged):
2871         (WebCore::GeolocationServiceMac::errorOccurred):
2872         (-[WebCoreCoreLocationObserver initWithCallback:]):
2873         (-[WebCoreCoreLocationObserver locationManager:didUpdateToLocation:fromLocation:]):
2874         (-[WebCoreCoreLocationObserver locationManager:didFailWithError:]):
2875
2876 2009-03-02  Kevin Ollivier  <kevino@theolliviers.com>
2877
2878         Build fixes for wxWidgets Mac trunk build.
2879
2880         * platform/wx/wxcode/mac/carbon/fontprops.cpp:
2881         (wxFontProperties::wxFontProperties):
2882         (GetTextExtent):
2883         * webcore-wx.bkl:
2884
2885 2009-03-02  Kevin Ollivier  <kevino@theolliviers.com>
2886
2887         wxGTK missing header build fix.
2888
2889         * platform/wx/wxcode/gtk/fontprops.cpp:
2890
2891 2009-03-02  Dan Bernstein  <mitz@apple.com>
2892
2893         Reviewed by Adam Roben.
2894
2895         - fix https://bugs.webkit.org/show_bug.cgi?id=21811
2896           REGRESSION: Windows Build Not Selecting Proper Font
2897
2898         * platform/graphics/win/FontCacheWin.cpp:
2899         (WebCore::createGDIFont): Added back code to verify that the created
2900         HFONT has the requested face name.
2901
2902 2009-03-02  Timothy Hatcher  <timothy@apple.com>
2903
2904         Fixes a regression caused by splitting the input and output of console commands.
2905
2906         https://bugs.webkit.org/show_bug.cgi?id=24293
2907
2908         Reviewed by Kevin McCullough.
2909
2910         * inspector/front-end/Console.js:
2911         (WebInspector.Console.prototype.addMessage): Don't treat ConsoleCommandResult as a
2912         normal ConsoleMessage when appending. This prevents resetting repeatCounts incorrectly.
2913
2914 2009-03-02  Timothy Hatcher  <timothy@apple.com>
2915
2916         Make exception messages and logged Error objects display consistently.
2917
2918         https://bugs.webkit.org/show_bug.cgi?id=18983
2919
2920         Reviewed by Adam Roben.
2921
2922         * English.lproj/localizedStrings.js: Remove a string for line numbers.
2923         * inspector/front-end/Console.js:
2924         (WebInspector.Console.prototype._enterKeyPressed): Pass the exception
2925         boolean to the ConsoleCommandResult constructor and don't pass level.
2926         (WebInspector.Console.prototype._formatnode): Fix a className typo.
2927         (WebInspector.Console.prototype._formaterror): Add an error-message
2928         classed span around the message to show in red and remove the
2929         console-message-url class from the link so it doesn't float right.
2930         Instead enclose the link in parentheses and use displayNameForURL
2931         to shorten the URL in the link.
2932         (WebInspector.ConsoleMessage.prototype.toMessageElement): Simplify
2933         how line numbers are shown since link underlining a string with
2934         parentheses looks bad.
2935         (WebInspector.ConsoleCommandResult): Take an exception boolean flag
2936         instead of a level and get line and URL based on that flag.
2937         * inspector/front-end/inspector.css: Tweaks to the styles.
2938
2939 2009-03-02  Ojan Vafai  <ojan@chromium.org>
2940
2941         Reviewed by Adele Peterson.
2942
2943         Bug 24048: extra windows button padding doesn't apply when there's no appearance
2944         <https://bugs.webkit.org/show_bug.cgi?id=24048>
2945
2946         Replace adjustButtonInnerStyle with buttonInternalPaddingLeft/Right/Top/Bottom.
2947
2948         No tests added as existing tests already cover this behavior.
2949
2950         * rendering/RenderButton.cpp:
2951         (WebCore::RenderButton::setupInnerStyle):
2952         * rendering/RenderTheme.cpp:
2953         * rendering/RenderTheme.h:
2954         (WebCore::RenderTheme::buttonInternalPaddingLeft):
2955         (WebCore::RenderTheme::buttonInternalPaddingRight):
2956         (WebCore::RenderTheme::buttonInternalPaddingTop):
2957         * rendering/RenderThemeChromiumGtk.cpp:
2958         (WebCore::RenderThemeWin::buttonInternalPaddingLeft):
2959         (WebCore::RenderThemeWin::buttonInternalPaddingRight):
2960         (WebCore::RenderThemeWin::buttonInternalPaddingTop):
2961         (WebCore::RenderThemeWin::buttonInternalPaddingBottom):
2962         * rendering/RenderThemeChromiumGtk.h:
2963         * rendering/RenderThemeChromiumWin.cpp:
2964         (WebCore::RenderThemeChromiumWin::buttonInternalPaddingLeft):
2965         (WebCore::RenderThemeChromiumWin::buttonInternalPaddingRight):
2966         (WebCore::RenderThemeChromiumWin::buttonInternalPaddingTop):
2967         (WebCore::RenderThemeChromiumWin::buttonInternalPaddingBottom):
2968         * rendering/RenderThemeChromiumWin.h:
2969         * rendering/RenderThemeWin.cpp:
2970         (WebCore::RenderThemeWin::buttonInternalPaddingLeft):
2971         (WebCore::RenderThemeWin::buttonInternalPaddingRight):
2972         (WebCore::RenderThemeWin::buttonInternalPaddingTop):
2973         (WebCore::RenderThemeWin::buttonInternalPaddingBottom):
2974         * rendering/RenderThemeWin.h:
2975
2976 2009-03-02  Adam Treat  <adam.treat@torchmobile.com>
2977
2978         Build fix for Qt port.  Remove unnecessary assert.
2979
2980         * platform/graphics/qt/ImageBufferQt.cpp:
2981         (WebCore::ImageBuffer::putImageData):
2982
2983 2009-03-02  Adam Treat  <adam.treat@torchmobile.com>
2984
2985         Reviewed by Adam Roben and previously by Eric Seidel and Simon Fraser.
2986
2987         https://bugs.webkit.org/show_bug.cgi?id=24227
2988         Ensure that the checkForSolidColor() optimization is correctly triggered
2989         for all cases of drawPattern.  Currently, the optimization was not triggered
2990         when the check had not been previously performed via a request for the
2991         image's NativeImagePtr.
2992
2993         Implement the Qt version of the checkForSolidColor() method.  Combined with
2994         the bug fix this reduces the time it takes to draw a repeating background
2995         of a 1x1 image from ~50msecs to ~0msecs on my machine.
2996
2997         * platform/graphics/BitmapImage.cpp:
2998         (WebCore::BitmapImage::BitmapImage):
2999         * platform/graphics/BitmapImage.h:
3000         (WebCore::BitmapImage::mayFillWithSolidColor):
3001         * platform/graphics/Image.h:
3002         (WebCore::Image::mayFillWithSolidColor):
3003         * platform/graphics/cairo/ImageCairo.cpp:
3004         (WebCore::BitmapImage::BitmapImage):
3005         (WebCore::BitmapImage::checkForSolidColor):
3006         * platform/graphics/cg/ImageCG.cpp:
3007         (WebCore::BitmapImage::BitmapImage):
3008         (WebCore::BitmapImage::checkForSolidColor):
3009         * platform/graphics/qt/ImageQt.cpp:
3010         (WebCore::BitmapImage::checkForSolidColor):
3011         * platform/graphics/skia/ImageSkia.cpp:
3012         (WebCore::BitmapImage::checkForSolidColor):
3013         * platform/graphics/wx/ImageWx.cpp:
3014         (WebCore::BitmapImage::checkForSolidColor):
3015
3016 2009-03-02  Gustavo Noronha Silva  <gns@gnome.org>
3017
3018         Unreviewed build fix; adding missing files to EXTRA_DIST, so that
3019         they show up in the tarball.
3020
3021         * GNUmakefile.am:
3022
3023 2009-03-02  Dirk Schulze  <krit@webkit.org>
3024
3025         Reviewed by Holger Freyther.
3026
3027         Added putImageData to Qt. Discussed with Ariya Hidayat.
3028
3029         [Qt] lacks putImageData support in Canvas
3030         https://bugs.webkit.org/show_bug.cgi?id=22186
3031
3032         * platform/graphics/qt/ImageBufferQt.cpp:
3033         (WebCore::ImageBuffer::putImageData):
3034
3035 2009-03-02  Timothy Hatcher  <timothy@apple.com>
3036
3037         Show exception messages again when evaluating bad expressions in the
3038         Web Inspector's console.
3039
3040         https://bugs.webkit.org/show_bug.cgi?id=19890
3041
3042         Reviewed by Oliver Hunt.
3043
3044         * bindings/js/JSQuarantinedObjectWrapper.cpp:
3045         (WebCore::JSQuarantinedObjectWrapper::transferExceptionToExecState):
3046         Fix the order in which the exception is set and cleared now that the
3047         exception is stored in the shared GlobalData, not per ExecState.
3048
3049 2009-02-28  Timothy Hatcher  <timothy@apple.com>
3050
3051         Make input in the Web Inspector console print before any output
3052         that might be added by the called function.
3053
3054         https://bugs.webkit.org/show_bug.cgi?id=19931
3055
3056         Reviewed by Oliver Hunt.
3057
3058         * inspector/front-end/Console.js:
3059         (WebInspector.Console.prototype._enterKeyPressed): Add the command
3060         message before evaluating the result. Associate the originating
3061         command to the result, so if they are adjacent there is no divider.
3062         (WebInspector.ConsoleCommand): No longer take a result.
3063         (WebInspector.ConsoleCommand.prototype.toMessageElement): Result
3064         code removed since it isn't used now.
3065         (WebInspector.ConsoleCommandResult): Subclass ConsoleMessage.
3066         (WebInspector.ConsoleCommandResult.prototype.toMessageElement):
3067         Call the ConsoleMessage toMessageElement and add a style class.
3068         * inspector/front-end/inspector.css: Add a new style class for
3069         adjacent results to hide the divider. Also tweak the position of
3070         the disclosure triangle for objects to not use the left margin.
3071
3072 2009-03-01  Chris Fleizach  <cfleizach@apple.com>
3073
3074         Reviewed by Oliver Hunt.
3075
3076         Bug 24282: AX Palindrome error when asking for a specific index of the AXChildren array
3077         <https://bugs.webkit.org/show_bug.cgi?id=24282>
3078
3079         When fetching an array of elements with a range, attachment views need to be returned
3080         instead of the actual attachment.
3081
3082         * page/mac/AccessibilityObjectWrapper.mm:
3083         (-[AccessibilityObjectWrapper accessibilityIndexOfChild:]):
3084         (-[AccessibilityObjectWrapper accessibilityArrayAttributeValues:index:maxCount:]):
3085
3086 2009-03-01  Ojan Vafai  <ojan@chromium.org>
3087
3088         Reviewed by Eric Seidel.
3089
3090         Bug 24251: Cleanup: replace positionForCoordinates with positionForPoint
3091         <https://bugs.webkit.org/show_bug.cgi?id=24251>
3092         
3093         Make RenderObject::positionForCoordinate non-virtual and
3094         RenderObject::positionForPoint virtual in preparation for
3095         removing positionFor* from RenderObject/RenderText.
3096
3097         * page/Frame.cpp:
3098         (WebCore::Frame::visiblePositionForPoint):
3099         * rendering/RenderBR.cpp:
3100         (WebCore::RenderBR::positionForPoint):
3101         * rendering/RenderBR.h:
3102         * rendering/RenderBlock.cpp:
3103         (WebCore::RenderBlock::positionForPoint):
3104         * rendering/RenderBlock.h:
3105         * rendering/RenderBox.cpp:
3106         (WebCore::RenderBox::positionForPoint):
3107         * rendering/RenderBox.h:
3108         * rendering/RenderInline.cpp:
3109         (WebCore::RenderInline::positionForPoint):
3110         * rendering/RenderInline.h:
3111         * rendering/RenderObject.cpp:
3112         (WebCore::RenderObject::positionForCoordinates):
3113         (WebCore::RenderObject::positionForPoint):
3114         * rendering/RenderObject.h:
3115         * rendering/RenderReplaced.cpp:
3116         (WebCore::RenderReplaced::positionForPoint):
3117         * rendering/RenderReplaced.h:
3118         * rendering/RenderSVGInlineText.cpp:
3119         (WebCore::RenderSVGInlineText::positionForPoint):
3120         * rendering/RenderSVGInlineText.h:
3121         * rendering/RenderText.cpp:
3122         (WebCore::RenderText::positionForPoint):
3123         * rendering/RenderText.h:
3124
3125 2009-03-01  Larry Ewing  <lewing@novell.com>
3126
3127         Reviewed by Alexey Proskuryakov.
3128
3129         https://bugs.webkit.org/show_bug.cgi?id=24080
3130         NPN_GetValue casting to the wrong type and writing outside bounds
3131
3132         Make sure to cast the value to the correct type so that only
3133         memory owned by the value is written to.
3134
3135         * plugins/gtk/PluginViewGtk.cpp (PluginView::getValueStatic): 
3136         * plugins/qt/PluginViewQt.cpp (PluginView::getValueStatic):
3137         * plugins/mac/PluginViewMac.cpp (PluginView::getValueStatic): 
3138         (PluginView::getValue):
3139
3140 2009-03-01  Jeremy Moskovich  <jeremy@chromium.org>
3141
3142         Reviewed by Simon Fraser.
3143
3144         https://bugs.webkit.org/show_bug.cgi?id=24197 and
3145         https://bugs.webkit.org/show_bug.cgi?id=23512
3146
3147         The Windows version of cgColor() is conditionally compiled using
3148         !PLATFORM(MAC) change this to PLATFORM(WIN_OS) so that Chrome
3149         can use the OS X version instead of the Windows version.
3150
3151         Also rename cgColor() -> createCGColor()
3152
3153         No observable change in behavior, so no test.
3154
3155         * platform/graphics/Color.h:
3156         * platform/graphics/cg/ColorCG.cpp:
3157         (WebCore::createCGColor):
3158         * platform/graphics/cg/GraphicsContextCG.cpp:
3159         (WebCore::GraphicsContext::setPlatformShadow):
3160         * platform/graphics/mac/ColorMac.mm:
3161         (WebCore::createCGColor):
3162         * platform/graphics/mac/GraphicsContextMac.mm:
3163         (WebCore::GraphicsContext::drawFocusRing):
3164         * platform/graphics/mac/GraphicsLayerCA.mm:
3165         (WebCore::setLayerBorderColor):
3166         (WebCore::setLayerBackgroundColor):
3167         (WebCore::GraphicsLayerCA::setBackgroundColor):
3168         * platform/graphics/win/GraphicsContextCGWin.cpp:
3169         (WebCore::GraphicsContext::drawFocusRing):
3170         * svg/graphics/filters/cg/SVGFEHelpersCg.mm:
3171         (WebCore::ciColor):
3172
3173 2009-03-01  David Levin  <levin@chromium.org>
3174
3175         Reviewed by Alexey Proskuryakov.
3176
3177         Bug 24271: XMLHttpRequest needs js bindings for Workers.
3178         <https://bugs.webkit.org/show_bug.cgi?id=24271>
3179
3180         Tests: http/tests/xmlhttprequest/workers/methods-async.html
3181                http/tests/xmlhttprequest/workers/methods.html
3182
3183         * bindings/js/JSWorkerContextBase.cpp:
3184         (WebCore::JSWorkerContextBase::getOwnPropertySlot):
3185         (jsWorkerContextBaseXMLHttpRequest):
3186         (setJSWorkerContextBaseXMLHttpRequest):
3187         Expose XMLHttpRequest to Workers.
3188
3189         * bindings/js/JSWorkerContextBase.h:
3190
3191         * bindings/js/JSXMLHttpRequestConstructor.cpp:
3192         (WebCore::JSXMLHttpRequestConstructor::JSXMLHttpRequestConstructor):
3193         (WebCore::constructXMLHttpRequest):
3194         (WebCore::JSXMLHttpRequestConstructor::mark):
3195         Removed the dependencies on Document.
3196
3197         * bindings/js/JSXMLHttpRequestConstructor.h:
3198         (WebCore::JSXMLHttpRequestConstructor::scriptExecutionContext):
3199         * dom/EventException.idl:
3200         * dom/EventListener.idl:
3201         Change to have the NoStaticTables attribute since they are used from XHR.
3202
3203         * loader/WorkerThreadableLoader.cpp:
3204         (WebCore::workerContextDidFinishLoading):
3205         (WebCore::WorkerThreadableLoader::MainThreadBridge::didFinishLoading):
3206         Fixed identifier to be unsigned long.
3207
3208         * loader/WorkerThreadableLoader.h:
3209         * workers/WorkerThread.cpp:
3210         (WebCore::WorkerThread::workerThread):
3211         Stop active objects when the thread is getting shutdown so that xhr gets properly shutdown.
3212
3213         * xml/XMLHttpRequestUpload.cpp:
3214
3215         * xml/XMLHttpRequest.idl:
3216         * xml/XMLHttpRequestException.idl:
3217         * xml/XMLHttpRequestProgressEvent.idl:
3218         * xml/XMLHttpRequestUpload.idl:
3219         Change to have the NoStaticTables attribute since they are used from XHR.
3220
3221 2009-03-01  Horia Olaru  <olaru@adobe.com>
3222
3223         Adding manual debugger test cases for bug.
3224
3225         https://bugs.webkit.org/show_bug.cgi?id=21073
3226
3227         Reviewed by Kevin McCullough.
3228
3229         * manual-tests/inspector/debugger-step-on-do-while-statements.html: Added.
3230         * manual-tests/inspector/debugger-step-on-for-in-statements.html: Added.
3231         * manual-tests/inspector/debugger-step-on-for-statements.html: Added.
3232         * manual-tests/inspector/debugger-step-on-while-statements.html: Added.
3233         * manual-tests/inspector/resources/loop-statements.js: Added.
3234
3235 2009-03-01  Dan Bernstein  <mitz@apple.com>
3236
3237         Reviewed by Darin Adler.
3238
3239         - fix <rdar://problem/6634768> Reproducible crash in RenderLayer::updateScrollCornerStyle() using full-page zoom at MobileMe Contacts
3240
3241         Test: fast/events/scroll-during-zoom-change.html
3242
3243         * dom/Document.cpp:
3244         (WebCore::Document::recalcStyle): Pause scheduled events during style
3245         reclaculation. Changes to the zoom property result in scroll events
3246         being generated during style recalc, and those events need to be
3247         deferred until the render tree is consistent.
3248         * page/FrameView.cpp:
3249         (WebCore::FrameView::layout): Changed to account for a case in which the
3250         post-layout tasks trigger a nested layout, which reactivates the
3251         post-layout task timer.
3252
3253 2009-03-01  Ross Boucher  <rboucher@gmail.com>
3254
3255         Alphabetically sort scripts in the Script's panel file popup menu.
3256
3257         https://bugs.webkit.org/show_bug.cgi?id=23395
3258
3259         Reviewed by Timothy Hatcher.
3260
3261         * inspector/front-end/ScriptsPanel.js:
3262         (WebInspector.ScriptsPanel.prototype._addScriptToFilesMenu):
3263         * inspector/front-end/utilities.js:
3264         (insertionIndexForObjectInListSortedByFunction):
3265         (indexOfObjectInListSortedByFunction):
3266
3267 2009-03-01  Yael Aharon  <yael.aharon@nokia.com>
3268
3269         Pass securityOrigin->host() instead of securityOrigin->domain() to WebInspector
3270         when creating databases, localStorage or sessionStorage. Changing document.domain
3271         should have no affect on databases, localStorage and sessionStorage in Web Inspector.
3272
3273         https://bugs.webkit.org/show_bug.cgi?id=23844
3274
3275         Reviewed by Timothy Hatcher.
3276
3277         * inspector/InspectorController.cpp:
3278         (WebCore::InspectorController::addDOMStorageScriptResource):
3279         (WebCore::InspectorController::didUseDOMStorage):
3280         * storage/Database.cpp:
3281         (WebCore::Database::openDatabase):
3282
3283 2009-03-01  Gustavo Noronha Silva  <gns@gnome.org>
3284
3285         Reviewed by Holger Freyther.
3286
3287         Avoid leaking errors when reporting GIO errors.
3288
3289         * platform/network/soup/ResourceHandleSoup.cpp:
3290         (WebCore::readCallback):
3291         (WebCore::openCallback):
3292         (WebCore::queryInfoCallback):
3293
3294 2009-03-01  Gustavo Noronha Silva  <gns@gnome.org>
3295
3296         Reviewed by Holger Freyther.
3297
3298         Fixes crash when the GIO backend is given the URI for a directory.
3299
3300         * platform/network/soup/ResourceHandleSoup.cpp:
3301         (WebCore::networkErrorForFile):
3302
3303 2009-02-28  Dimitri Glazkov  <dglazkov@chromium.org>
3304
3305         Reviewed by Darin Fisher.
3306
3307         https://bugs.webkit.org/show_bug.cgi?id=24261
3308         Fix V8 custom binding scrubbing error.
3309
3310         Test: fast/dom/TreeWalker/TreeWalker-currentNode.html
3311         Test: traversal/exception-forwarding.html
3312         TesT: traversal/stay-within-root.html
3313
3314         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp:
3315         * bindings/v8/custom/V8NodeIteratorCustom.cpp:
3316         (WebCore::toV8): Replace v8::Undefined() return value with v8::Null().
3317         * bindings/v8/custom/V8TreeWalkerCustom.cpp:
3318         (WebCore::toV8): Ditto.
3319
3320 2009-02-28  Dimitri Glazkov  <dglazkov@chromium.org>
3321
3322         Reviewed by Darin Fisher.
3323
3324         https://bugs.webkit.org/show_bug.cgi?id=24261
3325         Fix V8 custom binding scrubbing error.
3326
3327         Test: fast/dom/CSSStyleDeclaration/css-properties-case-sensitive.html
3328
3329         * WebCore.xcodeproj/project.pbxproj:
3330         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp:
3331         (WebCore::cssPropertyName):  Remove dubious checks, left over from
3332             incomplete conversion of parameter from pointer to pass-by-ref.
3333         (WebCore::NAMED_PROPERTY_GETTER): Initialize parameter.
3334         (WebCore::NAMED_PROPERTY_SETTER): Ditto.
3335
3336 2009-02-28  Xan Lopez  <xan@gnome.org>
3337
3338         Reviewed by Holger Freyther.
3339
3340         https://bugs.webkit.org/show_bug.cgi?id=24263
3341         [GTK] ref ResourceHandle until we are finished with it
3342
3343         Add a ref to the ResourceHandle in startHttp so we can keep it
3344         alive untill all callbacks have been executed, and unref it when
3345         soup tells us it's done with the SoupMessage (in
3346         finishedCallback). Fixes a number of crashes when calling
3347         didReceiveData whould crash because of the handle dying.
3348
3349         * platform/network/soup/ResourceHandleSoup.cpp:
3350         (WebCore::finishedCallback):
3351         (WebCore::ResourceHandle::startHttp):
3352
3353 2009-02-28  Adam Bergkvist <adam.bergkvist@ericsson.com>
3354
3355         Reviewed by Alexey Proskuryakov.
3356
3357         https://bugs.webkit.org/show_bug.cgi?id=24226
3358         [SOUP] HTTP status text is never set
3359
3360         Set HTTP status text to SoupMessage reason_phrase.
3361
3362         * platform/network/soup/ResourceHandleSoup.cpp:
3363         (WebCore::fillResponseFromMessage):
3364
3365 2009-02-28  Dan Bernstein  <mitz@apple.com>
3366
3367         - fix malformed project file
3368
3369         * WebCore.xcodeproj/project.pbxproj:
3370
3371 2009-02-28  Dan Bernstein  <mitz@apple.com>
3372
3373         Reviewed by Oliver Hunt.
3374
3375         - fix https://bugs.webkit.org/show_bug.cgi?id=23848
3376           <rdar://problem/6573250> REGRESSION: Crash when mouse cursor moves over a link on www.opportuno.de
3377
3378         Test: fast/layers/inline-dirty-z-order-lists.html
3379
3380         * rendering/RenderBox.cpp:
3381         (WebCore::RenderBox::styleWillChange): Moved the code that dirties a
3382         layer's and its stacking context's z-order lists when the layer's
3383         z-index or visibility change from here...
3384         * rendering/RenderBoxModelObject.cpp:
3385         (WebCore::RenderBoxModelObject::styleWillChange): ...to here, so that
3386         it will apply to RenderInline too.
3387
3388 2009-02-27  Alexey Proskuryakov  <ap@webkit.org>
3389
3390         Reviewed by David Hyatt.
3391
3392         Don't include TextResourceDecoder.h in Document.h
3393
3394         This undoes inlining of Document::displayStringModifiedByEncoding() to avoid world rebuilds
3395         when TextResourceDecoder.h is modified. Performance impact is expected to be negligible.
3396
3397         * dom/Document.cpp:
3398         (WebCore::Document::displayStringModifiedByEncoding):
3399         (WebCore::Document::displayBufferModifiedByEncoding):
3400         * dom/Document.h:
3401         * WebCore.base.exp:
3402
3403 2009-02-27  Matt Pennig  <pennig@apple.com>
3404
3405         Reviewed by David Hyatt.
3406
3407         Resolves: https://bugs.webkit.org/show_bug.cgi?id=24107
3408         "Fixed elements have 0 as an offsetLeft property"
3409         
3410         Code also brings offsetLeft/Top in full conformance with the spec.
3411         Added two tests, one for fixed-position elements, and one for <html>.
3412         
3413         Tests: fast/dom/Element/fixed-position-offset-parent.html
3414                fast/dom/Element/offsetLeft-offsetTop-html.html
3415
3416         * rendering/RenderBoxModelObject.cpp:
3417         (WebCore::RenderBoxModelObject::offsetLeft):
3418         (WebCore::RenderBoxModelObject::offsetTop):
3419
3420 2009-02-27  Dean Jackson  <dino@apple.com>
3421
3422         Reviewed by Simon Fraser.
3423
3424         renderer()->hasTransform() returns true for elements
3425         with perspective, but no transform, so test for transform
3426         when hit testing. This fixes ASSERT from
3427         https://bugs.webkit.org/show_bug.cgi?id=24252
3428
3429         Test: transforms/no_transform_hit_testing.html
3430
3431         * rendering/RenderLayer.cpp:
3432         (WebCore::RenderLayer::hitTestLayer):
3433
3434 2009-02-27  Dimitri Glazkov  <dglazkov@chromium.org>
3435
3436         Reviewed by Darin Fisher.
3437
3438         Fix scrubbing error -- a reversed condition.
3439
3440         * bindings/v8/ScriptValue.h:
3441         (WebCore::ScriptValue::clear): Change early exit for empty value, not the opposite.
3442
3443 2009-02-27  Jian Li  <jianli@chromium.org>
3444
3445         Reviewed by Alexey Proskuryakov.
3446
3447         Add confirmMessageFromWorkerObject to WorkerObjectProxy.
3448         https://bugs.webkit.org/show_bug.cgi?id=24152
3449
3450         * workers/WorkerMessagingProxy.cpp:
3451         (WebCore::MessageWorkerContextTask::performTask):
3452         (WebCore::WorkerMessagingProxy::confirmMessageFromWorkerObject):
3453         * workers/WorkerMessagingProxy.h:
3454         * workers/WorkerObjectProxy.h:
3455
3456 2009-02-27  Anders Carlsson  <andersca@apple.com>
3457
3458         Reviewed by David Hyatt.
3459
3460         Revert r41295, the fix for https://bugs.webkit.org/show_bug.cgi?id=24227 
3461         because it leads to assertion failures in the Mac port.
3462         
3463         * platform/graphics/BitmapImage.cpp:
3464         (WebCore::BitmapImage::BitmapImage):
3465         * platform/graphics/BitmapImage.h:
3466         (WebCore::BitmapImage::mayFillWithSolidColor):
3467         * platform/graphics/Image.h:
3468         (WebCore::Image::mayFillWithSolidColor):
3469         * platform/graphics/cairo/ImageCairo.cpp:
3470         (WebCore::BitmapImage::BitmapImage):
3471         * platform/graphics/cg/ImageCG.cpp:
3472         (WebCore::BitmapImage::BitmapImage):
3473         (WebCore::BitmapImage::checkForSolidColor):
3474         * platform/graphics/qt/ImageQt.cpp:
3475         (WebCore::BitmapImage::checkForSolidColor):
3476         * platform/graphics/skia/ImageSkia.cpp:
3477         (WebCore::BitmapImage::checkForSolidColor):
3478         * platform/graphics/wx/ImageWx.cpp:
3479         (WebCore::BitmapImage::checkForSolidColor):
3480
3481 2009-02-27  Adam Barth  <abarth@webkit.org>
3482
3483         Reviewed by Eric Seidel.
3484
3485         https://bugs.webkit.org/show_bug.cgi?id=20249
3486
3487         Add a preference to allow universal access from local URLs to mitigate
3488         some attacks.  Some clients still want to allow this access, so we
3489         expose this as a preference.
3490
3491         * WebCore.base.exp:
3492         * dom/Document.cpp:
3493         (WebCore::Document::initSecurityContext):
3494         * page/SecurityOrigin.cpp:
3495         (WebCore::SecurityOrigin::SecurityOrigin):
3496         * page/Settings.cpp:
3497         (WebCore::Settings::Settings):
3498         (WebCore::Settings::setAllowUniversalAccessFromFileUrls):
3499         * page/Settings.h:
3500         (WebCore::Settings::allowUniversalAccessFromFileUrls):
3501
3502 2009-02-27  Adam Treat  <adam.treat@torchmobile.com>
3503
3504         Reviewed by Eric Seidel.
3505
3506         https://bugs.webkit.org/show_bug.cgi?id=24229
3507         If an image has no alpha channel there is no reason to use SourceOver.
3508
3509         * platform/graphics/qt/ImageQt.cpp:
3510         (WebCore::Image::drawPattern):
3511         (WebCore::BitmapImage::draw):
3512
3513 2009-02-27  Adam Treat  <adam.treat@torchmobile.com>
3514
3515         Reviewed by Eric Seidel and Simon Fraser.
3516
3517         https://bugs.webkit.org/show_bug.cgi?id=24227
3518         Ensure that the checkForSolidColor() optimization is correctly triggered
3519         for all cases of drawPattern.  Currently, the optimization was not triggered
3520         when the check had not been previously performed via a request for the
3521         image's NativeImagePtr.
3522
3523         Implement the Qt version of the checkForSolidColor() method.  Combined with
3524         the bug fix this reduces the time it takes to draw a repeating background
3525         of a 1x1 image from ~50msecs to ~0msecs on my machine.
3526
3527         * platform/graphics/BitmapImage.cpp:
3528         (WebCore::BitmapImage::BitmapImage):
3529         * platform/graphics/BitmapImage.h:
3530         (WebCore::BitmapImage::mayFillWithSolidColor):
3531         * platform/graphics/Image.h:
3532         (WebCore::Image::mayFillWithSolidColor):
3533         * platform/graphics/cairo/ImageCairo.cpp:
3534         (WebCore::BitmapImage::BitmapImage):
3535         * platform/graphics/cg/ImageCG.cpp:
3536         (WebCore::BitmapImage::BitmapImage):
3537         (WebCore::BitmapImage::checkForSolidColor):
3538         * platform/graphics/qt/ImageQt.cpp:
3539         (WebCore::BitmapImage::checkForSolidColor):
3540         * platform/graphics/skia/ImageSkia.cpp:
3541         (WebCore::BitmapImage::checkForSolidColor):
3542         * platform/graphics/wx/ImageWx.cpp:
3543         (WebCore::BitmapImage::checkForSolidColor):
3544
3545 2009-02-27  Dirk Schulze  <krit@webkit.org>
3546
3547         Reviewed by Zack Rusin.
3548
3549         Added support for gradients and pattern on Fonts for Qt.
3550
3551         [Qt] gradients and patterns for FontQt
3552         https://bugs.webkit.org/show_bug.cgi?id=24243
3553
3554         * platform/graphics/qt/FontQt.cpp:
3555         (WebCore::Font::drawComplexText):
3556
3557 2009-02-27  Jian Li  <jianli@chromium.org>
3558
3559         Reviewed by Alexey Proskuryakov.
3560
3561         WorkerContextProxy::create in WorkerMessagingProxy.cpp should only be provided for non-Chromium platform.
3562         https://bugs.webkit.org/show_bug.cgi?id=24113
3563
3564         * workers/WorkerMessagingProxy.cpp:
3565
3566 2009-02-27  Yael Aharon  <yael.aharon@nokia.com>
3567
3568         Added a refresh button to storage views.
3569
3570         https://bugs.webkit.org/show_bug.cgi?id=24040
3571
3572         Reviewed by Timothy Hatcher.
3573
3574         * inspector/front-end/DOMStorageItemsView.js:
3575         (WebInspector.DOMStorageItemsView):
3576         (WebInspector.DOMStorageItemsView.prototype.get statusBarItems):
3577         (WebInspector.DOMStorageItemsView.prototype.update):
3578         (WebInspector.DOMStorageItemsView.prototype._refreshButtonClicked):
3579         * inspector/front-end/DatabaseTableView.js:
3580         (WebInspector.DatabaseTableView):
3581         (WebInspector.DatabaseTableView.prototype.get statusBarItems):
3582         (WebInspector.DatabaseTableView.prototype._refreshButtonClicked):
3583         * inspector/front-end/DatabasesPanel.js:
3584         (WebInspector.DatabasesPanel):
3585         (WebInspector.DatabasesPanel.prototype.get statusBarItems):
3586         (WebInspector.DatabasesPanel.prototype.reset):
3587         (WebInspector.DatabasesPanel.prototype.showDatabase):
3588         (WebInspector.DatabasesPanel.prototype.showDOMStorage):
3589         (WebInspector.DatabasesPanel.prototype._updateSidebarWidth):
3590         * inspector/front-end/inspector.css:
3591
3592 2009-02-27  Yael Aharon  <yael.aharon@nokia.com>
3593
3594         Added support for editing/deleting localStorage and sessionStorage items
3595         directly from Web Inspector.
3596
3597         https://bugs.webkit.org/show_bug.cgi?id=23866.
3598
3599         Reviewed by Timothy Hatcher.
3600
3601         * WebCore.vcproj/WebCore.vcproj:
3602         * inspector/front-end/DOMStorageDataGrid.js: Added.
3603         (WebInspector.DOMStorageDataGrid):
3604         (WebInspector.DOMStorageDataGrid.prototype._ondblclick):
3605         (WebInspector.DOMStorageDataGrid.prototype._startEditing):
3606         (WebInspector.DOMStorageDataGrid.prototype._editingCommitted):
3607         (WebInspector.DOMStorageDataGrid.prototype._editingCancelled):
3608         (WebInspector.DOMStorageDataGrid.prototype.deleteSelectedRow):
3609         * inspector/front-end/DOMStorageItemsView.js:
3610         (WebInspector.DOMStorageItemsView):
3611         (WebInspector.DOMStorageItemsView.prototype.get statusBarItems):
3612         (WebInspector.DOMStorageItemsView.prototype.hide):
3613         (WebInspector.DOMStorageItemsView.prototype.update):
3614         (WebInspector.DOMStorageItemsView.prototype._deleteButtonClicked):