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