2009-03-04 Simon Fraser <simon.fraser@apple.com>
[WebKit-https.git] / WebCore / ChangeLog
1 2009-03-04  Simon Fraser  <simon.fraser@apple.com>
2
3         Reviewed by Dave Hyatt
4         
5         https://bugs.webkit.org/show_bug.cgi?id=24361
6         
7         Reinstate code that sets result.innerNode when hitTest() returns true,
8         but never filled in the innerNode. Fixes hit testing of generated content.
9
10         Test: fast/css-generated-content/hit-test-generated-content.html
11
12         * rendering/RenderLayer.cpp:
13         (WebCore::RenderLayer::hitTestContents):
14
15 2009-03-04  Adam Barth  <abath@webkit.org>
16
17         Reviewed by Alexey Proskuryakov.
18
19         https://bugs.webkit.org/show_bug.cgi?id=24356
20
21         Fix WebKit style for allowUniversalAccessFromFileURLs.
22
23         * WebCore.base.exp:
24         * dom/Document.cpp:
25         (WebCore::Document::initSecurityContext):
26         * page/Settings.cpp:
27         (WebCore::Settings::Settings):
28         (WebCore::Settings::setAllowUniversalAccessFromFileURLs):
29         * page/Settings.h:
30         (WebCore::Settings::allowUniversalAccessFromFileURLs):
31
32 2009-03-04  Brady Eidson  <beidson@apple.com>
33
34         Reviewed by Darin Adler
35
36         <rdar://problem/6619630> Quick Look of vCards stuck on image of first card opened.
37
38         I narrowed this down to http://trac.webkit.org/changeset/39304 which, among other things,
39         consolidated some of the various decision making pieces of the Cache into the new method
40         FrameLoader::cachePolicy().
41
42         Before 39304, when deciding whether to use an existing CachedResource, we checked if the FrameLoader 
43         is reloading.  If it is, we'd evict any existing resource then recreate it.  Quick looks uses the
44         same URL for this image every time and expects it to be reloaded with each new card.
45
46         The FrameLoader::isReloading() check did one thing - Ask the DocumentLoader if it's cache policy
47         is "ReloadIgnoringCacheData".  This check was lost in the consolidation to the new method.  
48
49         * loader/FrameLoader.cpp:
50         (WebCore::FrameLoader::cachePolicy): Restore the DocumentLoader's cachePolicy check as a possible
51           condition for returning CachePolicyReload.
52
53 2009-03-04  Timothy Hatcher  <timothy@apple.com>
54
55         * English.lproj/localizedStrings.js: Update strings to include "DATABASES",
56         "LOCAL STORAGE" and "SESSION STORAGE".
57
58 2009-03-04  Timothy Hatcher  <timothy@apple.com>
59
60         Fix a regression where the Web Inspector console would not animate
61         in or out correctly.
62
63         Reviewed by Anders Carlsson.
64
65         * inspector/front-end/inspector.css: Move a z-index to a child element
66         to get the correct stacking order during the animation.
67
68 2009-03-03  David Hyatt  <hyatt@apple.com>
69
70         https://bugs.webkit.org/show_bug.cgi?id=24201, pathologically bad block layout.
71
72         Make sure to factor clear deltas into y position estimates.  Also avoid doing the comparison of
73         the final position against the y position estimate until after the clear has happened.  This gets rid
74         of some duplicated cut/pasted code and also ensures a layout delta only has to be put in once.
75
76         Reviewed by Dan Bernstein
77
78         Added fast/block/float/nested-clearance.html
79
80         * rendering/RenderBlock.cpp:
81         (WebCore::RenderBlock::collapseMargins):
82         (WebCore::RenderBlock::clearFloatsIfNeeded):
83         (WebCore::RenderBlock::estimateVerticalPosition):
84         (WebCore::RenderBlock::layoutBlockChildren):
85         (WebCore::RenderBlock::getClearDelta):
86         * rendering/RenderBlock.h:
87
88 2009-03-02  Kim Grönholm  <kim.gronholm@nomovok.com>
89
90         Reviewed by Simon Hausmann.
91
92         Improvement to 3d transformations rendering in QtWebKit. QTransform is used
93         instead of QMatrix. This allows perspective transformations since QTransform is
94         a true 3x3 matrix.
95
96         * platform/graphics/qt/GraphicsContextQt.cpp: Use QTransform instead of QMatrix everywhere.
97         (WebCore::GraphicsContext::getCTM):
98         (WebCore::GraphicsContext::restorePlatformState):
99         (WebCore::GraphicsContext::fillPath):
100         (WebCore::GraphicsContext::strokePath):
101         (WebCore::GraphicsContext::fillRect):
102         (WebCore::GraphicsContext::translate):
103         (WebCore::GraphicsContext::rotate):
104         (WebCore::GraphicsContext::scale):
105         (WebCore::GraphicsContext::concatCTM):
106         * platform/graphics/qt/ImageQt.cpp:
107         (WebCore::Image::drawPattern):
108         * platform/graphics/qt/PathQt.cpp:
109         (WebCore::Path::translate):
110         (WebCore::Path::transform):
111         * platform/graphics/qt/PatternQt.cpp:
112         (WebCore::Pattern::createPlatformPattern):
113         * platform/graphics/qt/TransformationMatrixQt.cpp:
114         (WebCore::TransformationMatrix::operator QTransform): Replace the conversion operator
115         to QMatrix with one to QTransform.
116         * platform/graphics/transforms/TransformationMatrix.h:
117         * platform/graphics/qt/FontQt.cpp:
118
119 2009-02-24  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
120
121         Reviewed by Simon Hausmann.
122
123         https://bugs.webkit.org/show_bug.cgi?id=24151
124         Fix Qt/S60 build break
125
126         * platform/FileSystem.h: Create a default case for non-win and non-mac Qt builds
127         * platform/qt/FileSystemQt.cpp: Ditto
128         (WebCore::unloadModule):
129
130 2009-03-03  Mike Belshe  <mike@belshe.com>
131
132         Reviewed by Alexey Proskuryakov.
133
134         https://bugs.webkit.org/show_bug.cgi?id=21939
135         Uninitialized ExceptionCode in DOMWindow::postMessage
136
137         * dom/MessagePort.cpp:
138         (WebCore::MessagePort::postMessage):
139
140 2009-03-03  David Kilzer  <ddkilzer@apple.com>
141
142         <rdar://problem/6581203> WebCore and WebKit should install the same set of headers during installhdrs phase as build phase
143
144         Reviewed by Mark Rowe.
145
146         The fix is to add INSTALLHDRS_COPY_PHASE = YES and
147         INSTALLHDRS_SCRIPT_PHASE = YES to WebCore.xcconfig, then to make
148         sure various build phase scripts work with the installhdrs build
149         phase.
150
151         * Configurations/Base.xcconfig: Defined REAL_PLATFORM_NAME
152         based on PLATFORM_NAME to work around the missing definition on
153         Tiger.
154         * Configurations/WebCore.xcconfig: Added
155         JAVASCRIPTCORE_PRIVATE_HEADERS_DIR variable to simplify logic in
156         the "Generate Derived Sources" script.  Added
157         INSTALLHDRS_COPY_PHASE = YES and INSTALLHDRS_SCRIPT_PHASE = YES.
158
159         * WebCore.xcodeproj/project.pbxproj:
160         - Added shell code to prevent running "Check For Global
161           Initializers", "Check For Exit Time Destructors" and "Check
162           For Weak VTables" scripts during the installhdrs build phase.
163         - Made "Generate Derived Sources" work for the installhdrs build
164           phase.  Also simplified setting of CREATE_HASH_TABLE by using
165           JAVASCRIPTCORE_PRIVATE_HEADERS_DIR.
166
167 2009-03-02  Adam Langley  <agl@google.com>
168
169         Reviewed by Darin Fisher.
170
171         Chromium Linux: Switch to using Skia to render widgets.
172
173         In order to sandbox the Chromium renderer on Linux we need to remove
174         the X connection. GTK cannot render without an X connection so, for
175         now, we render widgets ourselves.
176
177         Previously didn't use anti-alias fonts in order to match Windows font
178         rendering exactly. This was helpful when bootstrapping our layout
179         tests. Now, however, we are ready to enable it.
180
181         https://bugs.webkit.org/show_bug.cgi?id=24244
182
183         * platform/chromium/ScrollbarThemeChromium.cpp:
184         (WebCore::ScrollbarThemeChromium::buttonSize):
185         * platform/chromium/ScrollbarThemeChromiumLinux.cpp:
186         (WebCore::ScrollbarThemeChromium::scrollbarThickness):
187         (WebCore::ScrollbarThemeChromium::paintTrackPiece):
188         (WebCore::ScrollbarThemeChromium::paintButton):
189         (WebCore::ScrollbarThemeChromium::paintThumb):
190         * platform/graphics/chromium/FontPlatformDataLinux.cpp:
191         (WebCore::FontPlatformData::setupPaint):
192         * platform/graphics/skia/PlatformContextSkia.cpp:
193         (PlatformContextSkia::PlatformContextSkia):
194         (PlatformContextSkia::~PlatformContextSkia):
195         * platform/graphics/skia/PlatformContextSkia.h:
196         * rendering/RenderThemeChromiumGtk.cpp: Removed.
197         * rendering/RenderThemeChromiumGtk.h: Removed.
198         * rendering/RenderThemeChromiumLinux.cpp: Added.
199         * rendering/RenderThemeChromiumLinux.h: Added.
200
201 2009-03-03  Dimitri Glazkov  <dglazkov@chromium.org>
202
203         Reviewed by Darin Fisher.
204
205         https://bugs.webkit.org/show_bug.cgi?id=24261
206         Fix return types.
207
208         Test: LayoutTests/dom/svg/level3/xpath/XPathEvaluator_evaluate_TYPE_ERR.svg
209
210         * bindings/v8/V8Binding.h:
211         (WebCore::toInt32): change return type to int
212         (WebCore::toFloat): change return type to float.
213
214 2009-03-03  Anders Carlsson  <andersca@apple.com>
215
216         Reviewed by John Sullivan.
217
218         https://bugs.webkit.org/show_bug.cgi?id=22884
219         <rdar://problem/6449783>
220         modified layout test crashes Safari
221
222         Null check NPStream before dereferencing it.
223         
224         * plugins/PluginView.cpp:
225         (WebCore::PluginView::destroyStream):
226
227 2009-03-03  Eric Carlson  <eric.carlson@apple.com>
228
229         Reviewed by Simon Fraser.
230
231         Fix for <rdar://problem/6641045>
232         Don't call QTKit to get movie properties until movie metadata has been loaded.
233
234         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
235         (WebCore::MediaPlayerPrivate::metaDataAvailable): defined
236         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
237         (WebCore::MediaPlayerPrivate::createQTTime): return default if !metaDataAvailable.
238         (WebCore::MediaPlayerPrivate::play): Ditto.
239         (WebCore::MediaPlayerPrivate::pause): Ditto.
240         (WebCore::MediaPlayerPrivate::duration): Ditto.
241         (WebCore::MediaPlayerPrivate::currentTime): Ditto.
242         (WebCore::MediaPlayerPrivate::seek): Ditto.
243         (WebCore::MediaPlayerPrivate::seekTimerFired): Ditto.
244         (WebCore::MediaPlayerPrivate::paused): Ditto.
245         (WebCore::MediaPlayerPrivate::seeking): Ditto.
246         (WebCore::MediaPlayerPrivate::naturalSize): Ditto.
247         (WebCore::MediaPlayerPrivate::hasVideo): Ditto.
248         (WebCore::MediaPlayerPrivate::setVolume): Ditto.
249         (WebCore::MediaPlayerPrivate::setRate): Ditto.
250         (WebCore::MediaPlayerPrivate::dataRate): Ditto.
251         (WebCore::MediaPlayerPrivate::maxTimeLoaded): Ditto.
252         (WebCore::MediaPlayerPrivate::totalBytes): Ditto.
253
254 2009-03-03  Kevin McCullough  <kmccullough@apple.com>
255
256         - Spelling fix.
257
258         * page/Console.cpp:
259         (WebCore::Console::profile):
260
261 2009-03-03  Dimitri Glazkov  <dglazkov@chromium.org>
262
263         Reviewed by Darin Fisher.
264
265         https://bugs.webkit.org/show_bug.cgi?id=23657
266         Remove Database API callback IDLs from the project. 
267         They were removed in r40633.
268
269         * WebCore.xcodeproj/project.pbxproj: Removed IDL files from the project.
270
271 2009-03-03  Kevin McCullough  <kmccullough@apple.com>
272
273         Reviewed by Oliver Hunt.
274
275         <rdar://problem/6639110> console.profile() doesn't work without a title
276
277         * page/Console.cpp:
278         (WebCore::Console::profile): If there is no title assume this is a user
279         initiated profile and give it the next incremented title name.
280
281 2009-03-03  Timothy Hatcher  <timothy@apple.com>
282
283         Fix a regression that broke dirxml and caused an ASSERT in debug builds. Also simplified
284         the console code and refactored things to have fewer code paths and duplication.
285
286         rdar://problem/6367127
287         https://bugs.webkit.org/show_bug.cgi?id=24329
288
289         Reviewed by Kevin McCullough.
290
291         Test: manual-tests/inspector/console-dir.html
292
293         * bindings/js/JSInspectedObjectWrapper.cpp:
294         (WebCore::JSInspectedObjectWrapper::wrap): Use the lexicalGlobalObject instead of dynamicGlobalObject
295         to fix an ASSERT about using a wrapper from the wrong ExecState.
296         * bindings/js/JSQuarantinedObjectWrapper.cpp:
297         (WebCore::JSQuarantinedObjectWrapper::JSQuarantinedObjectWrapper): Ditto.
298         (WebCore::JSQuarantinedObjectWrapper::allowsUnwrappedAccessFrom): Ditto.
299         * inspector/front-end/Console.js:
300         (WebInspector.Console.prototype._format): Remove the inline argument and add forceObjectFormat.
301         When forceObjectFormat is true, the only formatter used is _formatobject.
302         (WebInspector.Console.prototype._formatvalue): Remove the inline argument.
303         (WebInspector.Console.prototype._formatstring): Ditto.
304         (WebInspector.Console.prototype._formatregexp): Ditto.
305         (WebInspector.Console.prototype._formatarray): Ditto.
306         (WebInspector.Console.prototype._formatnode): Remove the inline argument and make a DOM tree instead of an anchor.
307         (WebInspector.Console.prototype._formatobject): Remove the inline argument and always make a property graph.
308         (WebInspector.Console.prototype._formaterror): Remove the inline argument.
309         (WebInspector.ConsoleMessage): Remove the case for MessageLevel.Node and
310         simplify the case for MessageLevel.Object to use the normal _format code path with the %O formatter.
311         (WebInspector.ConsoleMessage.prototype._format.formatForConsole): Don't pass an additional true argument for inline.
312         (WebInspector.ConsoleMessage.prototype._format.formatAsObjectForConsole): Added. Pass a true argument for forceObjectFormat.
313         (WebInspector.ConsoleMessage.prototype._format): Added support for the %O formatter. Use formatForConsole for all arguments.
314         (WebInspector.ConsoleMessage.prototype.toString): Add the other message levels.
315         * inspector/front-end/inspector.css: Tweak styles to look and work correctly.
316         * inspector/front-end/utilities.js:
317         (Object.type): Return "node" for Node objects.
318         (Object.describe): Handle the "node" type.
319         * page/Console.cpp:
320         (WebCore::printMessageSourceAndLevelPrefix): Fix an assert by adding the other message level types.
321         (WebCore::Console::dirxml): Use the standard log fuction since it prints a DOM tree for nodes by default.
322         * page/Console.h:
323         (WebCore::enum MessageLevel): Removed NodeMessageLevel. Added a FIXME.
324
325 2009-03-03  Scott Violet  <sky@google.com>
326
327         Reviewed by Eric Seidel.
328
329         https://bugs.webkit.org/show_bug.cgi?id=24325
330         Crash on replacing document contents during drop.
331
332         Makes sure a node is in the document during a move before using it.
333
334         Test: fast/events/crash-on-mutate-during-drop.html
335
336         * editing/MoveSelectionCommand.cpp:
337         (WebCore::MoveSelectionCommand::doApply):
338
339 2009-03-03  Jungshik Shin <jshin@chromium.org>
340
341         Reviewed by Eric Seidel.
342
343         https://bugs.webkit.org/show_bug.cgi?id=23028
344         Enable dynamic web font support to Chromium on Windows.
345         Files that were omitted by mistake in the latest patch
346         that was landed.
347
348         * loader/CachedFont.cpp:
349         (WebCore::CachedFont::~CachedFont):
350         (WebCore::CachedFont::ensureCustomFontData):
351         (WebCore::CachedFont::platformDataFromCustomData):
352         (WebCore::CachedFont::allClientsRemoved):
353         * platform/graphics/chromium/FontCustomPlatformData.cpp:
354         (WebCore::EOTStream::EOTStream):
355         (WebCore::createFontCustomPlatformData):
356         * platform/graphics/win/FontCustomPlatformData.cpp:
357         (WebCore::EOTStream::EOTStream):
358         (WebCore::createFontCustomPlatformData):
359
360 2009-03-03  Gustavo Noronha Silva  <gns@gnome.org>
361
362         Reviewed by Alexey Proskuryakov.
363
364         https://bugs.webkit.org/show_bug.cgi?id=16826
365         [Gtk] Implement WebKitDownload
366
367         Make the Soup backend able to handle requests without a frame,
368         since we may have such things now that we support downloads.
369
370         * platform/network/ResourceHandleInternal.h:
371         * platform/network/soup/ResourceHandleSoup.cpp:
372         (WebCore::ResourceHandle::start):
373
374 2009-03-03  Dimitri Glazkov  <dglazkov@chromium.org>
375
376         Reviewed by Eric Seidel.
377
378         https://bugs.webkit.org/show_bug.cgi?id=24331
379         Add custom V8 bindings for Element, Attr, HTMLFrame, and HTMLIFrame.
380
381         * bindings/v8/custom/V8AttrCustom.cpp: Added.
382         * bindings/v8/custom/V8CustomBinding.cpp: Added.
383         * bindings/v8/custom/V8CustomBinding.h: Added attribute-checking helpers.
384         * bindings/v8/custom/V8ElementCustom.cpp: Added.
385         * bindings/v8/custom/V8HTMLFrameElementCustom.cpp: Added.
386         * bindings/v8/custom/V8HTMLIFrameElementCustom.cpp: Added.
387
388 2009-03-03  Brady Eidson  <beidson@apple.com>
389
390         Reviewed by Darin Adler
391
392         <rdar://problem/6616664> - Quick looks of various file types is broken
393
394         In http://trac.webkit.org/changeset/40553 there was an attempt to prevent NSURLRequest churn
395         for non-HTTP loads when the underlying ResourceRequest changed.  Unfortunately it was a little
396         overzealous as the mainDocumentURL is relevant for all loads, not only HTTP/HTTPS loads.
397
398         Partially reverted behavior to always set the mainDocumentURL in situations when we would've
399         before that patch.
400
401         * loader/FrameLoader.cpp:
402         (WebCore::FrameLoader::addExtraFieldsToRequest):
403
404         * platform/network/ResourceRequestBase.cpp:
405         (WebCore::ResourceRequestBase::setMainDocumentURL):
406
407 2009-03-03  Chris Marrin  <cmarrin@apple.com>
408
409         Reviewed by Simon Fraser.
410
411         https://bugs.webkit.org/show_bug.cgi?id=24256
412
413         Added a WebCoreForceSoftwareAnimation flag.
414
415         * platform/graphics/mac/GraphicsLayerCA.mm:
416         (WebCore::forceSoftwareAnimation):
417         (WebCore::GraphicsLayerCA::setOpacity):
418         (WebCore::GraphicsLayerCA::animateTransform):
419         (WebCore::GraphicsLayerCA::animateFloat):
420
421 2009-03-02  Chris Marrin  <cmarrin@apple.com>
422
423         Reviewed by Sam Weinig.
424
425         https://bugs.webkit.org/show_bug.cgi?id=24257
426
427         Added prototype properties for several classes with constructors that
428         were missing them, including the one mentioned in the bug.
429
430         Test: fast/dom/Window/custom-constructors.html
431
432         * bindings/js/JSAudioConstructor.cpp:
433         (WebCore::JSAudioConstructor::JSAudioConstructor):
434         * bindings/js/JSDOMWindowBase.cpp:
435         (jsDOMWindowBaseWebKitCSSMatrix):
436         * bindings/js/JSImageConstructor.cpp:
437         (WebCore::JSImageConstructor::JSImageConstructor):
438         * bindings/js/JSOptionConstructor.cpp:
439         (WebCore::JSOptionConstructor::JSOptionConstructor):
440         * bindings/js/JSWebKitCSSMatrixConstructor.cpp:
441         (WebCore::JSWebKitCSSMatrixConstructor::JSWebKitCSSMatrixConstructor):
442         * bindings/js/JSWebKitCSSMatrixConstructor.h:
443         * bindings/js/JSWebKitPointConstructor.cpp:
444         (WebCore::JSWebKitPointConstructor::JSWebKitPointConstructor):
445         * bindings/js/JSWorkerConstructor.cpp:
446         (WebCore::JSWorkerConstructor::JSWorkerConstructor):
447
448 2009-03-03  Dimitri Glazkov  <dglazkov@chromium.org>
449
450         Reviewed by Darin Fisher.
451
452         https://bugs.webkit.org/show_bug.cgi?id=24321
453         Add V8 bindings headers.
454
455         * bindings/v8/V8Binding.h: Added.
456         * bindings/v8/V8Proxy.h: Added.
457         * bindings/v8/custom/V8CustomBinding.h: Added.
458         * bindings/v8/custom/V8CustomEventListener.h: Added.
459
460 2009-03-03  Jungshik Shin <jshin@chromium.org>
461
462         Reviewed by Eric Seidel.
463
464         https://bugs.webkit.org/show_bug.cgi?id=23803
465         Fix an 'off-by-1' error in ChromiumWin's font fallback.
466
467         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
468         (WebCore::FontCache::getFontDataForCharacters):
469
470 2009-03-03  Jungshik Shin  <jshin@chromium.org>
471
472         Reviewed by Eric Seidel.
473
474         http://bugs.webkit.org/show_bug.cgi?id=23028
475         Enable dynamic web font support to Chromium on Windows: Part 1
476         - Move OpenTypeUtilities.{cpp,h} to platform/graphics/opentype
477           from platform/graphics/win because both Windows port and Chromium Windows
478           port will use them.
479         - Adjust WebCore.vcproj accordingly.
480
481         * WebCore.vcproj/WebCore.vcproj:
482         * platform/graphics/opentype: Added.
483         * platform/graphics/opentype/OpenTypeUtilities.cpp: Copied from WebCore/platform/graphics/win/OpenTypeUtilities.cpp.
484         * platform/graphics/opentype/OpenTypeUtilities.h: Copied from WebCore/platform/graphics/win/OpenTypeUtilities.h.
485         * platform/graphics/win/OpenTypeUtilities.cpp: Removed.
486         * platform/graphics/win/OpenTypeUtilities.h: Removed.
487
488 2009-03-03  Simon Fraser  <simon.fraser@apple.com>
489
490         Reviewed by Dave Hyatt
491
492         https://bugs.webkit.org/show_bug.cgi?id=24312
493         
494         Take 3D transforms into account when hit testing:
495         
496         1. Maintain a bit on each RenderLayer that is set when the layer
497            has 3d descendants, so that we know when to fall into the slow
498            hit testing path.
499            
500         2. Make a ref-counted HitTestingTransformState, which is used to store
501            an accumulated transform, and the hit test point, and hitTestRect
502            in the plane of the ancestor non-3d ('flattening') layer.
503            
504            It's ref-counted so we can heap allocate it (to avoid stack bloat),
505            and avoid copying when hitTestLayer calls itself after applying the transform.
506            
507         3. Add logic to hitTestLayer to depth-test just direct descendants, if any have
508            3D transforms, or to do deep depth-testing when traversing a preserves-3d
509            hierarchy. When hit, layers compute a z-offset from the ancestor flattening
510            layer, which allows for correct depth testing.
511            
512            The existing early-return codepath is unaffected when there are no 3d transforms
513            and no preserve-3d.
514
515         * rendering/RenderLayer.cpp:
516         (WebCore::RenderLayer::RenderLayer):
517         (WebCore::RenderLayer::updateTransform):
518         (WebCore::RenderLayer::dirty3DTransformedDescendantStatus):
519         (WebCore::RenderLayer::update3DTransformedDescendantStatus):
520         (WebCore::RenderLayer::hitTest):
521         (WebCore::computeZOffset):
522         (WebCore::RenderLayer::createLocalTransformState):
523         (WebCore::RenderLayer::hitTestLayer):
524         (WebCore::RenderLayer::hitTestContents):
525         * rendering/RenderLayer.h:
526         (WebCore::RenderLayer::preserves3D):
527         (WebCore::RenderLayer::has3DTransform):
528         (WebCore::RenderLayer::setHas3DTransformedDescendant):
529         (WebCore::RenderLayer::has3DTransformedDescendant):
530         * rendering/RenderLayerBacking.cpp:
531         * rendering/TransformState.cpp:
532         (WebCore::TransformState::flatten):
533         (WebCore::TransformState::mappedPoint):
534         (WebCore::HitTestingTransformState::move):
535         (WebCore::HitTestingTransformState::applyTransform):
536         (WebCore::HitTestingTransformState::flatten):
537         (WebCore::HitTestingTransformState::mappedPoint):
538         (WebCore::HitTestingTransformState::mappedQuad):
539         * rendering/TransformState.h:
540         (WebCore::TransformState::TransformState):
541         (WebCore::HitTestingTransformState::create):
542         (WebCore::HitTestingTransformState::move):
543         (WebCore::HitTestingTransformState::HitTestingTransformState):
544
545 2009-03-03  Brett Wilson  <brettw@chromium.org>
546
547         Fix uninitialized memory reads in the Chromium Windows transparency
548         code that were identified by Purify,
549
550         Reviewed by Darin Fisher.
551
552         * platform/graphics/chromium/TransparencyWin.cpp:
553         (WebCore::TransparencyWin::OwnedBuffers::OwnedBuffers):
554         (WebCore::TransparencyWin::initializeNewContext):
555
556 2009-03-03  Simon Fraser  <simon.fraser@apple.com>
557
558         Reviewed by Dave Hyatt
559
560         https://bugs.webkit.org/show_bug.cgi?id=24312
561         
562         Factor the code that compute a transform relative to the container
563         into RenderObject::transformFromContainer().
564         
565         * rendering/RenderBox.cpp:
566         (WebCore::RenderBox::mapLocalToAbsolutePoint):
567         (WebCore::RenderBox::mapAbsoluteToLocalPoint):
568         * rendering/RenderObject.cpp:
569         (WebCore::RenderObject::transformFromContainer):
570         * rendering/RenderObject.h:
571
572 2009-03-03  Simon Fraser  <simon.fraser@apple.com>
573
574         Reviewed by Dave Hyatt
575
576         https://bugs.webkit.org/show_bug.cgi?id=24317
577         
578         Always return |true| from RenderTextControlMultiLine::nodeAtPoint() if
579         the superclass found a node, otherwise we set the innerNode of the
580         HitTestResult, but don't actually report that we found a hit.
581
582         * rendering/RenderTextControlMultiLine.cpp:
583         (WebCore::RenderTextControlMultiLine::nodeAtPoint):
584
585 2009-03-03  Onne Gorter  <onne.gorter@avinity.net>
586
587         Reviewed by Anders Carlsson.
588
589         https://bugs.webkit.org/show_bug.cgi?id=23707
590         resizing plugins does not work, because the plugin never gets informed
591
592         Make gtk plugins resize correctly, by sending them the setwindow event
593         correctly. Also ensure that all plugin eventing is done with correct
594         locking/calling. Mostly copied from mac implementation.
595
596         manual test: manual-tests/gtk/plugin-resize-scroll.html
597
598         * plugins/PluginView.h:
599         * plugins/gtk/PluginViewGtk.cpp:
600         (WebCore::PluginView::dispatchNPEvent):
601         ensure locking/calling for NPEvents
602         (WebCore::PluginView::updatePluginWidget):
603         if something changed, let setNPWindowIfNeeded handle it
604         (WebCore::PluginView::paint):
605         (WebCore::PluginView::handleKeyboardEvent):
606         (WebCore::PluginView::handleMouseEvent):
607         ensure calling conventions
608         (WebCore::PluginView::setNPWindowRect):
609         just pass control to setNPWindowIfNeeded
610         (WebCore::PluginView::setNPWindowIfNeeded):
611         event the plugin correctly of new window
612         (WebCore::PluginView::init):
613         init through the new setup
614
615 2009-03-03  Mike Belshe  <mike@belshe.com>
616
617         Reviewed by Darin Fisher.
618
619         https://bugs.webkit.org/show_bug.cgi?id=24311
620         Make IDL returning DOMObject use [V8Custom]
621
622         * dom/Document.idl:
623         * html/HTMLCanvasElement.idl:
624
625 2009-03-02  Simon Fraser  <simon.fraser@apple.com>
626
627         Reviewed by Adele Peterson
628
629         https://bugs.webkit.org/show_bug.cgi?id=24313
630         
631         If RenderTextControlSingleLine::nodeAtPoint() pokes a node into the
632         HitTestResult, then it had better well return |true|. And m_innerBlock
633         could never have been set as the hit node by the superclass, because
634         the superclass knows nothing about m_innerBlock.
635         
636         Test: fast/forms/input-hit-test-border.html
637
638         * rendering/RenderTextControlSingleLine.cpp:
639         (WebCore::RenderTextControlSingleLine::nodeAtPoint):
640
641 2009-03-02  Sam Weinig  <sam@webkit.org>
642
643         Reviewed by Mark Rowe.
644
645         Enable Geolocation (except on Tiger and Leopard).
646
647         * Configurations/WebCore.xcconfig:
648
649 2009-03-02  Ojan Vafai  <ojan@chromium.org>
650
651         Reviewed by Adele Peterson.
652
653         Fix https://bugs.webkit.org/show_bug.cgi?id=24307
654         Null out m_highlightedNode on hideHighlight().
655         Ran WebCore/manual-tests/inspector/highlight-nodes.html.
656
657         * inspector/InspectorController.cpp:
658         (WebCore::InspectorController::hideHighlight):
659
660 2009-03-02  Sam Weinig  <sam@webkit.org>
661
662         Reviewed by Geoffrey Garen.
663
664         Fix for <rdar://problem/6507404> Add Geolocation support.
665
666         This is not yet turned on for any Mac platform.
667
668         * WebCore.xcodeproj/project.pbxproj:
669         * page/Chrome.cpp:
670         (WebCore::Chrome::shouldAllowGeolocationForFrame):
671         * page/Chrome.h:
672         * page/ChromeClient.h:
673         (WebCore::ChromeClient::shouldAllowGeolocationForFrame):
674         * page/Geolocation.cpp:
675         (WebCore::Geolocation::Geolocation):
676         (WebCore::Geolocation::disconnectFrame): Remove call to setUsingGeolocation as the document
677         will not be alive at this point.
678         (WebCore::Geolocation::getCurrentPosition): Check if the embedding app allows geolocation and
679         return a PERMISSION_DENIED if not.
680         (WebCore::Geolocation::watchPosition): Ditto.
681         (WebCore::Geolocation::shouldAllowGeolocation): Perform request to embedding layer of whether
682         to allow geolocation and cache the result. 
683         * page/Geolocation.h:
684         (WebCore::Geolocation::):
685         * platform/GeolocationService.cpp:
686         * platform/GeolocationService.h:
687         (WebCore::GeolocationService::~GeolocationService):
688         (WebCore::GeolocationService::stopUpdating):
689         * platform/mac/GeolocationServiceMac.h: Added.
690         (WebCore::GeolocationServiceMac::lastPosition):
691         (WebCore::GeolocationServiceMac::lastError):
692         * platform/mac/GeolocationServiceMac.mm: Added.
693         (WebCore::GeolocationService::create):
694         (WebCore::GeolocationServiceMac::GeolocationServiceMac):
695         (WebCore::GeolocationServiceMac::~GeolocationServiceMac):
696         (WebCore::GeolocationServiceMac::startUpdating):
697         (WebCore::GeolocationServiceMac::stopUpdating):
698         (WebCore::GeolocationServiceMac::suspend):
699         (WebCore::GeolocationServiceMac::resume):
700         (WebCore::GeolocationServiceMac::positionChanged):
701         (WebCore::GeolocationServiceMac::errorOccurred):
702         (-[WebCoreCoreLocationObserver initWithCallback:]):
703         (-[WebCoreCoreLocationObserver locationManager:didUpdateToLocation:fromLocation:]):
704         (-[WebCoreCoreLocationObserver locationManager:didFailWithError:]):
705
706 2009-03-02  Kevin Ollivier  <kevino@theolliviers.com>
707
708         Build fixes for wxWidgets Mac trunk build.
709
710         * platform/wx/wxcode/mac/carbon/fontprops.cpp:
711         (wxFontProperties::wxFontProperties):
712         (GetTextExtent):
713         * webcore-wx.bkl:
714
715 2009-03-02  Kevin Ollivier  <kevino@theolliviers.com>
716
717         wxGTK missing header build fix.
718
719         * platform/wx/wxcode/gtk/fontprops.cpp:
720
721 2009-03-02  Dan Bernstein  <mitz@apple.com>
722
723         Reviewed by Adam Roben.
724
725         - fix https://bugs.webkit.org/show_bug.cgi?id=21811
726           REGRESSION: Windows Build Not Selecting Proper Font
727
728         * platform/graphics/win/FontCacheWin.cpp:
729         (WebCore::createGDIFont): Added back code to verify that the created
730         HFONT has the requested face name.
731
732 2009-03-02  Timothy Hatcher  <timothy@apple.com>
733
734         Fixes a regression caused by splitting the input and output of console commands.
735
736         https://bugs.webkit.org/show_bug.cgi?id=24293
737
738         Reviewed by Kevin McCullough.
739
740         * inspector/front-end/Console.js:
741         (WebInspector.Console.prototype.addMessage): Don't treat ConsoleCommandResult as a
742         normal ConsoleMessage when appending. This prevents resetting repeatCounts incorrectly.
743
744 2009-03-02  Timothy Hatcher  <timothy@apple.com>
745
746         Make exception messages and logged Error objects display consistently.
747
748         https://bugs.webkit.org/show_bug.cgi?id=18983
749
750         Reviewed by Adam Roben.
751
752         * English.lproj/localizedStrings.js: Remove a string for line numbers.
753         * inspector/front-end/Console.js:
754         (WebInspector.Console.prototype._enterKeyPressed): Pass the exception
755         boolean to the ConsoleCommandResult constructor and don't pass level.
756         (WebInspector.Console.prototype._formatnode): Fix a className typo.
757         (WebInspector.Console.prototype._formaterror): Add an error-message
758         classed span around the message to show in red and remove the
759         console-message-url class from the link so it doesn't float right.
760         Instead enclose the link in parentheses and use displayNameForURL
761         to shorten the URL in the link.
762         (WebInspector.ConsoleMessage.prototype.toMessageElement): Simplify
763         how line numbers are shown since link underlining a string with
764         parentheses looks bad.
765         (WebInspector.ConsoleCommandResult): Take an exception boolean flag
766         instead of a level and get line and URL based on that flag.
767         * inspector/front-end/inspector.css: Tweaks to the styles.
768
769 2009-03-02  Ojan Vafai  <ojan@chromium.org>
770
771         Reviewed by Adele Peterson.
772
773         Bug 24048: extra windows button padding doesn't apply when there's no appearance
774         <https://bugs.webkit.org/show_bug.cgi?id=24048>
775
776         Replace adjustButtonInnerStyle with buttonInternalPaddingLeft/Right/Top/Bottom.
777
778         No tests added as existing tests already cover this behavior.
779
780         * rendering/RenderButton.cpp:
781         (WebCore::RenderButton::setupInnerStyle):
782         * rendering/RenderTheme.cpp:
783         * rendering/RenderTheme.h:
784         (WebCore::RenderTheme::buttonInternalPaddingLeft):
785         (WebCore::RenderTheme::buttonInternalPaddingRight):
786         (WebCore::RenderTheme::buttonInternalPaddingTop):
787         * rendering/RenderThemeChromiumGtk.cpp:
788         (WebCore::RenderThemeWin::buttonInternalPaddingLeft):
789         (WebCore::RenderThemeWin::buttonInternalPaddingRight):
790         (WebCore::RenderThemeWin::buttonInternalPaddingTop):
791         (WebCore::RenderThemeWin::buttonInternalPaddingBottom):
792         * rendering/RenderThemeChromiumGtk.h:
793         * rendering/RenderThemeChromiumWin.cpp:
794         (WebCore::RenderThemeChromiumWin::buttonInternalPaddingLeft):
795         (WebCore::RenderThemeChromiumWin::buttonInternalPaddingRight):
796         (WebCore::RenderThemeChromiumWin::buttonInternalPaddingTop):
797         (WebCore::RenderThemeChromiumWin::buttonInternalPaddingBottom):
798         * rendering/RenderThemeChromiumWin.h:
799         * rendering/RenderThemeWin.cpp:
800         (WebCore::RenderThemeWin::buttonInternalPaddingLeft):
801         (WebCore::RenderThemeWin::buttonInternalPaddingRight):
802         (WebCore::RenderThemeWin::buttonInternalPaddingTop):
803         (WebCore::RenderThemeWin::buttonInternalPaddingBottom):
804         * rendering/RenderThemeWin.h:
805
806 2009-03-02  Adam Treat  <adam.treat@torchmobile.com>
807
808         Build fix for Qt port.  Remove unnecessary assert.
809
810         * platform/graphics/qt/ImageBufferQt.cpp:
811         (WebCore::ImageBuffer::putImageData):
812
813 2009-03-02  Adam Treat  <adam.treat@torchmobile.com>
814
815         Reviewed by Adam Roben and previously by Eric Seidel and Simon Fraser.
816
817         https://bugs.webkit.org/show_bug.cgi?id=24227
818         Ensure that the checkForSolidColor() optimization is correctly triggered
819         for all cases of drawPattern.  Currently, the optimization was not triggered
820         when the check had not been previously performed via a request for the
821         image's NativeImagePtr.
822
823         Implement the Qt version of the checkForSolidColor() method.  Combined with
824         the bug fix this reduces the time it takes to draw a repeating background
825         of a 1x1 image from ~50msecs to ~0msecs on my machine.
826
827         * platform/graphics/BitmapImage.cpp:
828         (WebCore::BitmapImage::BitmapImage):
829         * platform/graphics/BitmapImage.h:
830         (WebCore::BitmapImage::mayFillWithSolidColor):
831         * platform/graphics/Image.h:
832         (WebCore::Image::mayFillWithSolidColor):
833         * platform/graphics/cairo/ImageCairo.cpp:
834         (WebCore::BitmapImage::BitmapImage):
835         (WebCore::BitmapImage::checkForSolidColor):
836         * platform/graphics/cg/ImageCG.cpp:
837         (WebCore::BitmapImage::BitmapImage):
838         (WebCore::BitmapImage::checkForSolidColor):
839         * platform/graphics/qt/ImageQt.cpp:
840         (WebCore::BitmapImage::checkForSolidColor):
841         * platform/graphics/skia/ImageSkia.cpp:
842         (WebCore::BitmapImage::checkForSolidColor):
843         * platform/graphics/wx/ImageWx.cpp:
844         (WebCore::BitmapImage::checkForSolidColor):
845
846 2009-03-02  Gustavo Noronha Silva  <gns@gnome.org>
847
848         Unreviewed build fix; adding missing files to EXTRA_DIST, so that
849         they show up in the tarball.
850
851         * GNUmakefile.am:
852
853 2009-03-02  Dirk Schulze  <krit@webkit.org>
854
855         Reviewed by Holger Freyther.
856
857         Added putImageData to Qt. Discussed with Ariya Hidayat.
858
859         [Qt] lacks putImageData support in Canvas
860         https://bugs.webkit.org/show_bug.cgi?id=22186
861
862         * platform/graphics/qt/ImageBufferQt.cpp:
863         (WebCore::ImageBuffer::putImageData):
864
865 2009-03-02  Timothy Hatcher  <timothy@apple.com>
866
867         Show exception messages again when evaluating bad expressions in the
868         Web Inspector's console.
869
870         https://bugs.webkit.org/show_bug.cgi?id=19890
871
872         Reviewed by Oliver Hunt.
873
874         * bindings/js/JSQuarantinedObjectWrapper.cpp:
875         (WebCore::JSQuarantinedObjectWrapper::transferExceptionToExecState):
876         Fix the order in which the exception is set and cleared now that the
877         exception is stored in the shared GlobalData, not per ExecState.
878
879 2009-02-28  Timothy Hatcher  <timothy@apple.com>
880
881         Make input in the Web Inspector console print before any output
882         that might be added by the called function.
883
884         https://bugs.webkit.org/show_bug.cgi?id=19931
885
886         Reviewed by Oliver Hunt.
887
888         * inspector/front-end/Console.js:
889         (WebInspector.Console.prototype._enterKeyPressed): Add the command
890         message before evaluating the result. Associate the originating
891         command to the result, so if they are adjacent there is no divider.
892         (WebInspector.ConsoleCommand): No longer take a result.
893         (WebInspector.ConsoleCommand.prototype.toMessageElement): Result
894         code removed since it isn't used now.
895         (WebInspector.ConsoleCommandResult): Subclass ConsoleMessage.
896         (WebInspector.ConsoleCommandResult.prototype.toMessageElement):
897         Call the ConsoleMessage toMessageElement and add a style class.
898         * inspector/front-end/inspector.css: Add a new style class for
899         adjacent results to hide the divider. Also tweak the position of
900         the disclosure triangle for objects to not use the left margin.
901
902 2009-03-01  Chris Fleizach  <cfleizach@apple.com>
903
904         Reviewed by Oliver Hunt.
905
906         Bug 24282: AX Palindrome error when asking for a specific index of the AXChildren array
907         <https://bugs.webkit.org/show_bug.cgi?id=24282>
908
909         When fetching an array of elements with a range, attachment views need to be returned
910         instead of the actual attachment.
911
912         * page/mac/AccessibilityObjectWrapper.mm:
913         (-[AccessibilityObjectWrapper accessibilityIndexOfChild:]):
914         (-[AccessibilityObjectWrapper accessibilityArrayAttributeValues:index:maxCount:]):
915
916 2009-03-01  Ojan Vafai  <ojan@chromium.org>
917
918         Reviewed by Eric Seidel.
919
920         Bug 24251: Cleanup: replace positionForCoordinates with positionForPoint
921         <https://bugs.webkit.org/show_bug.cgi?id=24251>
922         
923         Make RenderObject::positionForCoordinate non-virtual and
924         RenderObject::positionForPoint virtual in preparation for
925         removing positionFor* from RenderObject/RenderText.
926
927         * page/Frame.cpp:
928         (WebCore::Frame::visiblePositionForPoint):
929         * rendering/RenderBR.cpp:
930         (WebCore::RenderBR::positionForPoint):
931         * rendering/RenderBR.h:
932         * rendering/RenderBlock.cpp:
933         (WebCore::RenderBlock::positionForPoint):
934         * rendering/RenderBlock.h:
935         * rendering/RenderBox.cpp:
936         (WebCore::RenderBox::positionForPoint):
937         * rendering/RenderBox.h:
938         * rendering/RenderInline.cpp:
939         (WebCore::RenderInline::positionForPoint):
940         * rendering/RenderInline.h:
941         * rendering/RenderObject.cpp:
942         (WebCore::RenderObject::positionForCoordinates):
943         (WebCore::RenderObject::positionForPoint):
944         * rendering/RenderObject.h:
945         * rendering/RenderReplaced.cpp:
946         (WebCore::RenderReplaced::positionForPoint):
947         * rendering/RenderReplaced.h:
948         * rendering/RenderSVGInlineText.cpp:
949         (WebCore::RenderSVGInlineText::positionForPoint):
950         * rendering/RenderSVGInlineText.h:
951         * rendering/RenderText.cpp:
952         (WebCore::RenderText::positionForPoint):
953         * rendering/RenderText.h:
954
955 2009-03-01  Larry Ewing  <lewing@novell.com>
956
957         Reviewed by Alexey Proskuryakov.
958
959         https://bugs.webkit.org/show_bug.cgi?id=24080
960         NPN_GetValue casting to the wrong type and writing outside bounds
961
962         Make sure to cast the value to the correct type so that only
963         memory owned by the value is written to.
964
965         * plugins/gtk/PluginViewGtk.cpp (PluginView::getValueStatic): 
966         * plugins/qt/PluginViewQt.cpp (PluginView::getValueStatic):
967         * plugins/mac/PluginViewMac.cpp (PluginView::getValueStatic): 
968         (PluginView::getValue):
969
970 2009-03-01  Jeremy Moskovich  <jeremy@chromium.org>
971
972         Reviewed by Simon Fraser.
973
974         https://bugs.webkit.org/show_bug.cgi?id=24197 and
975         https://bugs.webkit.org/show_bug.cgi?id=23512
976
977         The Windows version of cgColor() is conditionally compiled using
978         !PLATFORM(MAC) change this to PLATFORM(WIN_OS) so that Chrome
979         can use the OS X version instead of the Windows version.
980
981         Also rename cgColor() -> createCGColor()
982
983         No observable change in behavior, so no test.
984
985         * platform/graphics/Color.h:
986         * platform/graphics/cg/ColorCG.cpp:
987         (WebCore::createCGColor):
988         * platform/graphics/cg/GraphicsContextCG.cpp:
989         (WebCore::GraphicsContext::setPlatformShadow):
990         * platform/graphics/mac/ColorMac.mm:
991         (WebCore::createCGColor):
992         * platform/graphics/mac/GraphicsContextMac.mm:
993         (WebCore::GraphicsContext::drawFocusRing):
994         * platform/graphics/mac/GraphicsLayerCA.mm:
995         (WebCore::setLayerBorderColor):
996         (WebCore::setLayerBackgroundColor):
997         (WebCore::GraphicsLayerCA::setBackgroundColor):
998         * platform/graphics/win/GraphicsContextCGWin.cpp:
999         (WebCore::GraphicsContext::drawFocusRing):
1000         * svg/graphics/filters/cg/SVGFEHelpersCg.mm:
1001         (WebCore::ciColor):
1002
1003 2009-03-01  David Levin  <levin@chromium.org>
1004
1005         Reviewed by Alexey Proskuryakov.
1006
1007         Bug 24271: XMLHttpRequest needs js bindings for Workers.
1008         <https://bugs.webkit.org/show_bug.cgi?id=24271>
1009
1010         Tests: http/tests/xmlhttprequest/workers/methods-async.html
1011                http/tests/xmlhttprequest/workers/methods.html
1012
1013         * bindings/js/JSWorkerContextBase.cpp:
1014         (WebCore::JSWorkerContextBase::getOwnPropertySlot):
1015         (jsWorkerContextBaseXMLHttpRequest):
1016         (setJSWorkerContextBaseXMLHttpRequest):
1017         Expose XMLHttpRequest to Workers.
1018
1019         * bindings/js/JSWorkerContextBase.h:
1020
1021         * bindings/js/JSXMLHttpRequestConstructor.cpp:
1022         (WebCore::JSXMLHttpRequestConstructor::JSXMLHttpRequestConstructor):
1023         (WebCore::constructXMLHttpRequest):
1024         (WebCore::JSXMLHttpRequestConstructor::mark):
1025         Removed the dependencies on Document.
1026
1027         * bindings/js/JSXMLHttpRequestConstructor.h:
1028         (WebCore::JSXMLHttpRequestConstructor::scriptExecutionContext):
1029         * dom/EventException.idl:
1030         * dom/EventListener.idl:
1031         Chnage to have the NoStaticTables attribute since they are used from XHR.
1032
1033         * loader/WorkerThreadableLoader.cpp:
1034         (WebCore::workerContextDidFinishLoading):
1035         (WebCore::WorkerThreadableLoader::MainThreadBridge::didFinishLoading):
1036         Fixed identifier to be unsigned long.
1037
1038         * loader/WorkerThreadableLoader.h:
1039         * workers/WorkerThread.cpp:
1040         (WebCore::WorkerThread::workerThread):
1041         Stop active objects when the thread is getting shutdown so that xhr gets properly shutdown.
1042
1043         * xml/XMLHttpRequestUpload.cpp:
1044
1045         * xml/XMLHttpRequest.idl:
1046         * xml/XMLHttpRequestException.idl:
1047         * xml/XMLHttpRequestProgressEvent.idl:
1048         * xml/XMLHttpRequestUpload.idl:
1049         Chnage to have the NoStaticTables attribute since they are used from XHR.
1050
1051 2009-03-01  Horia Olaru  <olaru@adobe.com>
1052
1053         Adding manual debugger test cases for bug.
1054
1055         https://bugs.webkit.org/show_bug.cgi?id=21073
1056
1057         Reviewed by Kevin McCullough.
1058
1059         * manual-tests/inspector/debugger-step-on-do-while-statements.html: Added.
1060         * manual-tests/inspector/debugger-step-on-for-in-statements.html: Added.
1061         * manual-tests/inspector/debugger-step-on-for-statements.html: Added.
1062         * manual-tests/inspector/debugger-step-on-while-statements.html: Added.
1063         * manual-tests/inspector/resources/loop-statements.js: Added.
1064
1065 2009-03-01  Dan Bernstein  <mitz@apple.com>
1066
1067         Reviewed by Darin Adler.
1068
1069         - fix <rdar://problem/6634768> Reproducible crash in RenderLayer::updateScrollCornerStyle() using full-page zoom at MobileMe Contacts
1070
1071         Test: fast/events/scroll-during-zoom-change.html
1072
1073         * dom/Document.cpp:
1074         (WebCore::Document::recalcStyle): Pause scheduled events during style
1075         reclaculation. Changes to the zoom property result in scroll events
1076         being generated during style recalc, and those events need to be
1077         deferred until the render tree is consistent.
1078         * page/FrameView.cpp:
1079         (WebCore::FrameView::layout): Changed to account for a case in which the
1080         post-layout tasks trigger a nested layout, which reactivates the
1081         post-layout task timer.
1082
1083 2009-03-01  Ross Boucher  <rboucher@gmail.com>
1084
1085         Alphabetically sort scripts in the Script's panel file popup menu.
1086
1087         https://bugs.webkit.org/show_bug.cgi?id=23395
1088
1089         Reviewed by Timothy Hatcher.
1090
1091         * inspector/front-end/ScriptsPanel.js:
1092         (WebInspector.ScriptsPanel.prototype._addScriptToFilesMenu):
1093         * inspector/front-end/utilities.js:
1094         (insertionIndexForObjectInListSortedByFunction):
1095         (indexOfObjectInListSortedByFunction):
1096
1097 2009-03-01  Yael Aharon  <yael.aharon@nokia.com>
1098
1099         Pass securityOrigin->host() instead of securityOrigin->domain() to WebInspector
1100         when creating databases, localStorage or sessionStorage. Changing document.domain
1101         should have no affect on databases, localStorage and sessionStorage in Web Inspector.
1102
1103         https://bugs.webkit.org/show_bug.cgi?id=23844
1104
1105         Reviewed by Timothy Hatcher.
1106
1107         * inspector/InspectorController.cpp:
1108         (WebCore::InspectorController::addDOMStorageScriptResource):
1109         (WebCore::InspectorController::didUseDOMStorage):
1110         * storage/Database.cpp:
1111         (WebCore::Database::openDatabase):
1112
1113 2009-03-01  Gustavo Noronha Silva  <gns@gnome.org>
1114
1115         Reviewed by Holger Freyther.
1116
1117         Avoid leaking errors when reporting GIO errors.
1118
1119         * platform/network/soup/ResourceHandleSoup.cpp:
1120         (WebCore::readCallback):
1121         (WebCore::openCallback):
1122         (WebCore::queryInfoCallback):
1123
1124 2009-03-01  Gustavo Noronha Silva  <gns@gnome.org>
1125
1126         Reviewed by Holger Freyther.
1127
1128         Fixes crash when the GIO backend is given the URI for a directory.
1129
1130         * platform/network/soup/ResourceHandleSoup.cpp:
1131         (WebCore::networkErrorForFile):
1132
1133 2009-02-28  Dimitri Glazkov  <dglazkov@chromium.org>
1134
1135         Reviewed by Darin Fisher.
1136
1137         https://bugs.webkit.org/show_bug.cgi?id=24261
1138         Fix V8 custom binding scrubbing error.
1139
1140         Test: fast/dom/TreeWalker/TreeWalker-currentNode.html
1141         Test: traversal/exception-forwarding.html
1142         TesT: traversal/stay-within-root.html
1143
1144         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp:
1145         * bindings/v8/custom/V8NodeIteratorCustom.cpp:
1146         (WebCore::toV8): Replace v8::Undefined() return value with v8::Null().
1147         * bindings/v8/custom/V8TreeWalkerCustom.cpp:
1148         (WebCore::toV8): Ditto.
1149
1150 2009-02-28  Dimitri Glazkov  <dglazkov@chromium.org>
1151
1152         Reviewed by Darin Fisher.
1153
1154         https://bugs.webkit.org/show_bug.cgi?id=24261
1155         Fix V8 custom binding scrubbing error.
1156
1157         Test: fast/dom/CSSStyleDeclaration/css-properties-case-sensitive.html
1158
1159         * WebCore.xcodeproj/project.pbxproj:
1160         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp:
1161         (WebCore::cssPropertyName):  Remove dubious checks, left over from
1162             incomplete conversion of parameter from pointer to pass-by-ref.
1163         (WebCore::NAMED_PROPERTY_GETTER): Initialize parameter.
1164         (WebCore::NAMED_PROPERTY_SETTER): Ditto.
1165
1166 2009-02-28  Xan Lopez  <xan@gnome.org>
1167
1168         Reviewed by Holger Freyther.
1169
1170         https://bugs.webkit.org/show_bug.cgi?id=24263
1171         [GTK] ref ResourceHandle until we are finished with it
1172
1173         Add a ref to the ResourceHandle in startHttp so we can keep it
1174         alive untill all callbacks have been executed, and unref it when
1175         soup tells us it's done with the SoupMessage (in
1176         finishedCallback). Fixes a number of crashes when calling
1177         didReceiveData whould crash because of the handle dying.
1178
1179         * platform/network/soup/ResourceHandleSoup.cpp:
1180         (WebCore::finishedCallback):
1181         (WebCore::ResourceHandle::startHttp):
1182
1183 2009-02-28  Adam Bergkvist <adam.bergkvist@ericsson.com>
1184
1185         Reviewed by Alexey Proskuryakov.
1186
1187         https://bugs.webkit.org/show_bug.cgi?id=24226
1188         [SOUP] HTTP status text is never set
1189
1190         Set HTTP status text to SoupMessage reason_phrase.
1191
1192         * platform/network/soup/ResourceHandleSoup.cpp:
1193         (WebCore::fillResponseFromMessage):
1194
1195 2009-02-28  Dan Bernstein  <mitz@apple.com>
1196
1197         - fix malformed project file
1198
1199         * WebCore.xcodeproj/project.pbxproj:
1200
1201 2009-02-28  Dan Bernstein  <mitz@apple.com>
1202
1203         Reviewed by Oliver Hunt.
1204
1205         - fix https://bugs.webkit.org/show_bug.cgi?id=23848
1206           <rdar://problem/6573250> REGRESSION: Crash when mouse cursor moves over a link on www.opportuno.de
1207
1208         Test: fast/layers/inline-dirty-z-order-lists.html
1209
1210         * rendering/RenderBox.cpp:
1211         (WebCore::RenderBox::styleWillChange): Moved the code that dirties a
1212         layer's and its stacking context's z-order lists when the layer's
1213         z-index or visibility change from here...
1214         * rendering/RenderBoxModelObject.cpp:
1215         (WebCore::RenderBoxModelObject::styleWillChange): ...to here, so that
1216         it will apply to RenderInline too.
1217
1218 2009-02-27  Alexey Proskuryakov  <ap@webkit.org>
1219
1220         Reviewed by David Hyatt.
1221
1222         Don't include TextResourceDecoder.h in Document.h
1223
1224         This undoes inlining of Document::displayStringModifiedByEncoding() to avoid world rebuilds
1225         when TextResourceDecoder.h is modified. Performance impact is expected to be negligible.
1226
1227         * dom/Document.cpp:
1228         (WebCore::Document::displayStringModifiedByEncoding):
1229         (WebCore::Document::displayBufferModifiedByEncoding):
1230         * dom/Document.h:
1231         * WebCore.base.exp:
1232
1233 2009-02-27  Matt Pennig  <pennig@apple.com>
1234
1235         Reviewed by David Hyatt.
1236
1237         Resolves: https://bugs.webkit.org/show_bug.cgi?id=24107
1238         "Fixed elements have 0 as an offsetLeft property"
1239         
1240         Code also brings offsetLeft/Top in full conformance with the spec.
1241         Added two tests, one for fixed-position elements, and one for <html>.
1242         
1243         Tests: fast/dom/Element/fixed-position-offset-parent.html
1244                fast/dom/Element/offsetLeft-offsetTop-html.html
1245
1246         * rendering/RenderBoxModelObject.cpp:
1247         (WebCore::RenderBoxModelObject::offsetLeft):
1248         (WebCore::RenderBoxModelObject::offsetTop):
1249
1250 2009-02-27  Dean Jackson  <dino@apple.com>
1251
1252         Reviewed by Simon Fraser.
1253
1254         renderer()->hasTransform() returns true for elements
1255         with perspective, but no transform, so test for transform
1256         when hit testing. This fixes ASSERT from
1257         https://bugs.webkit.org/show_bug.cgi?id=24252
1258
1259         Test: transforms/no_transform_hit_testing.html
1260
1261         * rendering/RenderLayer.cpp:
1262         (WebCore::RenderLayer::hitTestLayer):
1263
1264 2009-02-27  Dimitri Glazkov  <dglazkov@chromium.org>
1265
1266         Reviewed by Darin Fisher.
1267
1268         Fix scrubbing error -- a reversed condition.
1269
1270         * bindings/v8/ScriptValue.h:
1271         (WebCore::ScriptValue::clear): Change early exit for empty value, not the opposite.
1272
1273 2009-02-27  Jian Li  <jianli@chromium.org>
1274
1275         Reviewed by Alexey Proskuryakov.
1276
1277         Add confirmMessageFromWorkerObject to WorkerObjectProxy.
1278         https://bugs.webkit.org/show_bug.cgi?id=24152
1279
1280         * workers/WorkerMessagingProxy.cpp:
1281         (WebCore::MessageWorkerContextTask::performTask):
1282         (WebCore::WorkerMessagingProxy::confirmMessageFromWorkerObject):
1283         * workers/WorkerMessagingProxy.h:
1284         * workers/WorkerObjectProxy.h:
1285
1286 2009-02-27  Anders Carlsson  <andersca@apple.com>
1287
1288         Reviewed by David Hyatt.
1289
1290         Revert r41295, the fix for https://bugs.webkit.org/show_bug.cgi?id=24227 
1291         because it leads to assertion failures in the Mac port.
1292         
1293         * platform/graphics/BitmapImage.cpp:
1294         (WebCore::BitmapImage::BitmapImage):
1295         * platform/graphics/BitmapImage.h:
1296         (WebCore::BitmapImage::mayFillWithSolidColor):
1297         * platform/graphics/Image.h:
1298         (WebCore::Image::mayFillWithSolidColor):
1299         * platform/graphics/cairo/ImageCairo.cpp:
1300         (WebCore::BitmapImage::BitmapImage):
1301         * platform/graphics/cg/ImageCG.cpp:
1302         (WebCore::BitmapImage::BitmapImage):
1303         (WebCore::BitmapImage::checkForSolidColor):
1304         * platform/graphics/qt/ImageQt.cpp:
1305         (WebCore::BitmapImage::checkForSolidColor):
1306         * platform/graphics/skia/ImageSkia.cpp:
1307         (WebCore::BitmapImage::checkForSolidColor):
1308         * platform/graphics/wx/ImageWx.cpp:
1309         (WebCore::BitmapImage::checkForSolidColor):
1310
1311 2009-02-27  Adam Barth  <abarth@webkit.org>
1312
1313         Reviewed by Eric Seidel.
1314
1315         https://bugs.webkit.org/show_bug.cgi?id=20249
1316
1317         Add a preference to allow universal access from local URLs to mitigate
1318         some attacks.  Some clients still want to allow this access, so we
1319         expose this as a preference.
1320
1321         * WebCore.base.exp:
1322         * dom/Document.cpp:
1323         (WebCore::Document::initSecurityContext):
1324         * page/SecurityOrigin.cpp:
1325         (WebCore::SecurityOrigin::SecurityOrigin):
1326         * page/Settings.cpp:
1327         (WebCore::Settings::Settings):
1328         (WebCore::Settings::setAllowUniversalAccessFromFileUrls):
1329         * page/Settings.h:
1330         (WebCore::Settings::allowUniversalAccessFromFileUrls):
1331
1332 2009-02-27  Adam Treat  <adam.treat@torchmobile.com>
1333
1334         Reviewed by Eric Seidel.
1335
1336         https://bugs.webkit.org/show_bug.cgi?id=24229
1337         If an image has no alpha channel there is no reason to use SourceOver.
1338
1339         * platform/graphics/qt/ImageQt.cpp:
1340         (WebCore::Image::drawPattern):
1341         (WebCore::BitmapImage::draw):
1342
1343 2009-02-27  Adam Treat  <adam.treat@torchmobile.com>
1344
1345         Reviewed by Eric Seidel and Simon Fraser.
1346
1347         https://bugs.webkit.org/show_bug.cgi?id=24227
1348         Ensure that the checkForSolidColor() optimization is correctly triggered
1349         for all cases of drawPattern.  Currently, the optimization was not triggered
1350         when the check had not been previously performed via a request for the
1351         image's NativeImagePtr.
1352
1353         Implement the Qt version of the checkForSolidColor() method.  Combined with
1354         the bug fix this reduces the time it takes to draw a repeating background
1355         of a 1x1 image from ~50msecs to ~0msecs on my machine.
1356
1357         * platform/graphics/BitmapImage.cpp:
1358         (WebCore::BitmapImage::BitmapImage):
1359         * platform/graphics/BitmapImage.h:
1360         (WebCore::BitmapImage::mayFillWithSolidColor):
1361         * platform/graphics/Image.h:
1362         (WebCore::Image::mayFillWithSolidColor):
1363         * platform/graphics/cairo/ImageCairo.cpp:
1364         (WebCore::BitmapImage::BitmapImage):
1365         * platform/graphics/cg/ImageCG.cpp:
1366         (WebCore::BitmapImage::BitmapImage):
1367         (WebCore::BitmapImage::checkForSolidColor):
1368         * platform/graphics/qt/ImageQt.cpp:
1369         (WebCore::BitmapImage::checkForSolidColor):
1370         * platform/graphics/skia/ImageSkia.cpp:
1371         (WebCore::BitmapImage::checkForSolidColor):
1372         * platform/graphics/wx/ImageWx.cpp:
1373         (WebCore::BitmapImage::checkForSolidColor):
1374
1375 2009-02-27  Dirk Schulze  <krit@webkit.org>
1376
1377         Reviewed by Zack Rusin.
1378
1379         Added support for gradients and pattern on Fonts for Qt.
1380
1381         [Qt] gradients and patterns for FontQt
1382         https://bugs.webkit.org/show_bug.cgi?id=24243
1383
1384         * platform/graphics/qt/FontQt.cpp:
1385         (WebCore::Font::drawComplexText):
1386
1387 2009-02-27  Jian Li  <jianli@chromium.org>
1388
1389         Reviewed by Alexey Proskuryakov.
1390
1391         WorkerContextProxy::create in WorkerMessagingProxy.cpp should only be provided for non-Chromium platform.
1392         https://bugs.webkit.org/show_bug.cgi?id=24113
1393
1394         * workers/WorkerMessagingProxy.cpp:
1395
1396 2009-02-27  Yael Aharon  <yael.aharon@nokia.com>
1397
1398         Added a refresh button to storage views.
1399
1400         https://bugs.webkit.org/show_bug.cgi?id=24040
1401
1402         Reviewed by Timothy Hatcher.
1403
1404         * inspector/front-end/DOMStorageItemsView.js:
1405         (WebInspector.DOMStorageItemsView):
1406         (WebInspector.DOMStorageItemsView.prototype.get statusBarItems):
1407         (WebInspector.DOMStorageItemsView.prototype.update):
1408         (WebInspector.DOMStorageItemsView.prototype._refreshButtonClicked):
1409         * inspector/front-end/DatabaseTableView.js:
1410         (WebInspector.DatabaseTableView):
1411         (WebInspector.DatabaseTableView.prototype.get statusBarItems):
1412         (WebInspector.DatabaseTableView.prototype._refreshButtonClicked):
1413         * inspector/front-end/DatabasesPanel.js:
1414         (WebInspector.DatabasesPanel):
1415         (WebInspector.DatabasesPanel.prototype.get statusBarItems):
1416         (WebInspector.DatabasesPanel.prototype.reset):
1417         (WebInspector.DatabasesPanel.prototype.showDatabase):
1418         (WebInspector.DatabasesPanel.prototype.showDOMStorage):
1419         (WebInspector.DatabasesPanel.prototype._updateSidebarWidth):
1420         * inspector/front-end/inspector.css:
1421
1422 2009-02-27  Yael Aharon  <yael.aharon@nokia.com>
1423
1424         Added support for editing/deleting localStorage and sessionStorage items
1425         directly from Web Inspector.
1426
1427         https://bugs.webkit.org/show_bug.cgi?id=23866.
1428
1429         Reviewed by Timothy Hatcher.
1430
1431         * WebCore.vcproj/WebCore.vcproj:
1432         * inspector/front-end/DOMStorageDataGrid.js: Added.
1433         (WebInspector.DOMStorageDataGrid):
1434         (WebInspector.DOMStorageDataGrid.prototype._ondblclick):
1435         (WebInspector.DOMStorageDataGrid.prototype._startEditing):
1436         (WebInspector.DOMStorageDataGrid.prototype._editingCommitted):
1437         (WebInspector.DOMStorageDataGrid.prototype._editingCancelled):
1438         (WebInspector.DOMStorageDataGrid.prototype.deleteSelectedRow):
1439         * inspector/front-end/DOMStorageItemsView.js:
1440         (WebInspector.DOMStorageItemsView):
1441         (WebInspector.DOMStorageItemsView.prototype.get statusBarItems):
1442         (WebInspector.DOMStorageItemsView.prototype.hide):
1443         (WebInspector.DOMStorageItemsView.prototype.update):
1444         (WebInspector.DOMStorageItemsView.prototype._deleteButtonClicked):
1445         * inspector/front-end/DatabasesPanel.js:
1446         (WebInspector.DatabasesPanel):
1447         (WebInspector.DatabasesPanel.prototype.get statusBarItems):
1448         (WebInspector.DatabasesPanel.prototype.reset):
1449         (WebInspector.DatabasesPanel.prototype.showDOMStorage):
1450         (WebInspector.DatabasesPanel.prototype.dataGridForDOMStorage):
1451         (WebInspector.DatabasesPanel.prototype._updateSidebarWidth):
1452         * inspector/front-end/WebKit.qrc:
1453         * inspector/front-end/inspector.css:
1454         * inspector/front-end/inspector.html:
1455
1456 2009-02-26  Brett Wilson  <brettw@chromium.org>
1457
1458         Fix Windows transparency for the Chromium port. Implement a helper
1459         class for handling transparency on Windows. It allows semitransparent
1460         ClearType and semitransparent form controls by making new layers in the
1461         background.
1462
1463         It also replaces the "ThemeHelper" which allows better
1464         scaling and transforms on Windows form controls. In addition to the
1465         functionality that the ThemeHelper did, but additionally handles the
1466         antialiasing properly so that the form controls aren't composited on a
1467         white square.
1468
1469         https://bugs.webkit.org/show_bug.cgi?id=24101
1470
1471         Reviewed by Eric Seidel.
1472
1473         * platform/graphics/chromium/FontChromiumWin.cpp:
1474         (WebCore::):
1475         (WebCore::TransparencyAwareFontPainter::TransparencyAwareFontPainter::TransparencyAwareFontPainter):
1476         (WebCore::TransparencyAwareFontPainter::TransparencyAwareFontPainter::initializeForGDI):
1477         (WebCore::TransparencyAwareFontPainter::TransparencyAwareFontPainter::~TransparencyAwareFontPainter):
1478         (WebCore::TransparencyAwareFontPainter::TransparencyAwareFontPainter::drawGlyphs):
1479         (WebCore::Font::drawGlyphs):
1480         * platform/graphics/chromium/ThemeHelperChromiumWin.cpp:
1481         * platform/graphics/chromium/ThemeHelperChromiumWin.h:
1482         * platform/graphics/chromium/TransparencyWin.cpp: Added.
1483         (WebCore::):
1484         (WebCore::TransparencyWin::OwnedBuffers::OwnedBuffers):
1485         (WebCore::TransparencyWin::OwnedBuffers::destBitmap):
1486         (WebCore::TransparencyWin::OwnedBuffers::referenceBitmap):
1487         (WebCore::TransparencyWin::OwnedBuffers::canHandleSize):
1488         (WebCore::TransparencyWin::TransparencyWin):
1489         (WebCore::TransparencyWin::~TransparencyWin):
1490         (WebCore::TransparencyWin::init):
1491         (WebCore::TransparencyWin::computeLayerSize):
1492         (WebCore::TransparencyWin::setupLayer):
1493         (WebCore::TransparencyWin::setupLayerForNoLayer):
1494         (WebCore::TransparencyWin::setupLayerForOpaqueCompositeLayer):
1495         (WebCore::TransparencyWin::setupLayerForTextComposite):
1496         (WebCore::TransparencyWin::setupLayerForWhiteLayer):
1497         (WebCore::TransparencyWin::setupTransform):
1498         (WebCore::TransparencyWin::setupTransformForKeepTransform):
1499         (WebCore::TransparencyWin::setupTransformForUntransform):
1500         (WebCore::TransparencyWin::setupTransformForScaleTransform):
1501         (WebCore::TransparencyWin::setTextCompositeColor):
1502         (WebCore::TransparencyWin::initializeNewContext):
1503         (WebCore::TransparencyWin::compositeOpaqueComposite):
1504         (WebCore::TransparencyWin::compositeTextComposite):
1505         (WebCore::TransparencyWin::makeLayerOpaque):
1506         * platform/graphics/chromium/TransparencyWin.h: Added.
1507         (WebCore::TransparencyWin::):
1508         (WebCore::TransparencyWin::context):
1509         (WebCore::TransparencyWin::platformContext):
1510         (WebCore::TransparencyWin::drawRect):
1511         * platform/graphics/skia/GraphicsContextSkia.cpp:
1512         (WebCore::GraphicsContext::endTransparencyLayer):
1513         * platform/graphics/skia/ImageSkia.cpp:
1514         (WebCore::paintSkBitmap):
1515         * rendering/RenderThemeChromiumWin.cpp:
1516         (WebCore::):
1517         (WebCore::RenderThemeChromiumWin::paintButton):
1518         (WebCore::RenderThemeChromiumWin::paintMenuList):
1519         (WebCore::RenderThemeChromiumWin::paintTextFieldInternal):
1520
1521 2009-02-27  Dimitri Glazkov  <dglazkov@chromium.org>
1522
1523         Reviewed by Eric Seidel.
1524
1525         https://bugs.webkit.org/show_bug.cgi?id=24211
1526         Add ScheduledAction for V8.
1527
1528         * bindings/v8/ScheduledAction.cpp: Added.
1529         (WebCore::ScheduledAction::ScheduledAction):
1530         (WebCore::ScheduledAction::~ScheduledAction):
1531         (WebCore::ScheduledAction::execute):
1532         * bindings/v8/ScheduledAction.h: Added.
1533         (WebCore::ScheduledAction::ScheduledAction):
1534
1535 2009-02-27  Zack Rusin  <zack@kde.org>
1536
1537         Reviewed by Nikolas Zimmermann.
1538
1539         Qt: be more reasonable about scrolled lines
1540
1541         cMouseWheelPixelsPerLineStep is currently a constant set to 13.3. it doesn't
1542         match our metrics meaning that Qt scrolls by ~2 lines by default which is quite
1543         irritating. so lets scroll vertically by the Qt set number of lines * Qt default
1544         single step scroll
1545
1546         * platform/qt/WheelEventQt.cpp:
1547
1548 2009-02-27  Xan Lopez  <xan@gnome.org>
1549
1550         Rubber-stamped by Alexey Proskuryakov.
1551
1552         https://bugs.webkit.org/show_bug.cgi?id=24222
1553         [GTK] Remove checks for old glib versions
1554
1555         libsoup, which is a hard dependency, needs at least glib 2.15.3,
1556         so remove all glib checks for versions older than that.
1557
1558         * platform/gtk/ContextMenuGtk.cpp:
1559         (WebCore::ContextMenu::ContextMenu):
1560         * platform/gtk/ContextMenuItemGtk.cpp:
1561         (WebCore::ContextMenuItem::setSubMenu):
1562         * platform/gtk/PopupMenuGtk.cpp:
1563         (WebCore::PopupMenu::show):
1564         * platform/gtk/WidgetGtk.cpp:
1565         (WebCore::Widget::retainPlatformWidget):
1566         * platform/network/soup/ResourceHandleSoup.cpp:
1567
1568 2009-02-26  Dirk Schulze  <krit@webkit.org>
1569
1570         Reviewed by Oliver Hunt.
1571
1572         Added support for Gradients and Patterns on filled or stroked Fonts
1573         in Cairo. I also added support for globalAlpha on FontCairo.
1574
1575         [CAIRO] SVG/Canvas fonts miss gradients/pattern support
1576         https://bugs.webkit.org/show_bug.cgi?id=18617
1577
1578         * html/CanvasRenderingContext2D.cpp:
1579         (WebCore::CanvasRenderingContext2D::drawTextInternal):
1580         * platform/graphics/cairo/FontCairo.cpp:
1581         (WebCore::Font::drawGlyphs):
1582
1583 2009-02-26  Stephen White  <senorblanco@chromium.org>
1584
1585         Reviewed by Eric Seidel.
1586
1587         https://bugs.webkit.org/show_bug.cgi?id=23957
1588
1589         Fix for SVG gradient and pattern text for Chromium/skia. 
1590         Added accessors for the fill and stroke gradients to
1591         GraphicsContext.  Changed the paintSkiaText function to take a
1592         GraphicsContext, so we can check for gradients/patterns. 
1593         Changed the skiaDrawText function to set the SkPaint shader
1594         correctly, and to scale up the gradient shader matrix to
1595         encompass the entire text string.  Also offset each glyph
1596         separately, rather than transforming the canvas, so that the
1597         gradient/pattern stays fixed relative to the text origin.
1598
1599         * platform/graphics/GraphicsContext.cpp:
1600         (WebCore::GraphicsContext::getFillGradient):
1601         (WebCore::GraphicsContext::getStrokeGradient):
1602         (WebCore::GraphicsContext::getFillPattern):
1603         (WebCore::GraphicsContext::getStrokePattern):
1604         * platform/graphics/GraphicsContext.h:
1605         * platform/graphics/chromium/FontChromiumWin.cpp:
1606         (WebCore::Font::drawGlyphs):
1607         * platform/graphics/chromium/UniscribeHelper.cpp:
1608         (WebCore::UniscribeHelper::draw):
1609         * platform/graphics/skia/SkiaFontWin.cpp:
1610         (WebCore::windowsCanHandleTextDrawing):
1611         (WebCore::skiaDrawText):
1612         (WebCore::paintSkiaText):
1613         * platform/graphics/skia/SkiaFontWin.h:
1614
1615 2009-02-26  Dimitri Glazkov  <dglazkov@chromium.org>
1616
1617         Reviewed by Eric Seidel.
1618
1619         https://bugs.webkit.org/show_bug.cgi?id=24208
1620         Add custom V8 bindings for Navigator, Clipboard, Document, and Node.
1621
1622         * bindings/v8/custom/V8ClipboardCustom.cpp: Added.
1623         (WebCore::ACCESSOR_GETTER):
1624         (WebCore::CALLBACK_FUNC_DECL):
1625         * bindings/v8/custom/V8DocumentCustom.cpp: Added.
1626         (WebCore::CALLBACK_FUNC_DECL):
1627         * bindings/v8/custom/V8NavigatorCustom.cpp: Added.
1628         (WebCore::ACCESSOR_GETTER):
1629         * bindings/v8/custom/V8NodeCustom.cpp: Added.
1630         (WebCore::CALLBACK_FUNC_DECL):
1631
1632 2009-02-26  Gustavo Noronha Silva  <gns@gnome.org>
1633
1634         Unreviewed build fix for building with GNOME Keyring enabled.
1635
1636         * platform/network/soup/webkit-soup-auth-dialog.c:
1637         (show_auth_dialog):
1638
1639 2009-02-26  Xan Lopez  <xan@gnome.org>
1640
1641         Reviewed by Holger Freyther.
1642
1643         https://bugs.webkit.org/show_bug.cgi?id=16947
1644         [GTK] Missing HTTP Auth challenge
1645
1646         Add HTTP authentication dialog with optional GNOME Keyring
1647         storage.
1648
1649         * GNUmakefile.am:
1650         * platform/network/ResourceHandleInternal.h:
1651         (WebCore::ResourceHandleInternal::ResourceHandleInternal):
1652         * platform/network/soup/ResourceHandleSoup.cpp:
1653         (WebCore::currentToplevelCallback):
1654         (WebCore::ResourceHandle::startHttp):
1655         (WebCore::ResourceHandle::start):
1656         * platform/network/soup/webkit-soup-auth-dialog.c: Added.
1657         (webkit_soup_auth_dialog_class_init):
1658         (webkit_soup_auth_dialog_init):
1659         (webkit_soup_auth_dialog_session_feature_init):
1660         (free_authData):
1661         (set_password_callback):
1662         (response_callback):
1663         (show_auth_dialog):
1664         (find_password_callback):
1665         (session_authenticate):
1666         (attach):
1667         * platform/network/soup/webkit-soup-auth-dialog.h: Added.
1668
1669 2009-02-25  Ojan Vafai  <ojan@chromium.org> and Eric Seidel <eric@webkit.org>
1670
1671         Reviewed by Dave Hyatt.
1672
1673         After Ojan's positionForCoordinates fix http://trac.webkit.org/changeset/41191
1674         svg/custom/pointer-events-image.svg and svg/custom/pointer-events-text.svg
1675         started failing because Ojan's new code was now *correctly* calling through to
1676         SVG asking for the closest text offset in the last line box, instead of
1677         just returning the offset at the end of the last line box when clicking below a box.
1678
1679         But!  The SVG code was wrong, in that it returned the character offset of the last
1680         character when you asked for a character offset after the end of the box, instead
1681         it should return the offset *after* the last character.  This patch fixes
1682         that behavior by reordering the last two clauses in svgCharacterHitsPosition.
1683
1684         The SVG positionForCoordinates function is still wrong, and I've added some FIXMEs
1685         to document what's wrong.  I've also cleaned up the code a bit so it's clearer
1686         what it is doing (which also makes more obvious what's wrong with it).
1687
1688         * rendering/RenderSVGInlineText.cpp:
1689         (WebCore::RenderSVGInlineText::positionForCoordinates):
1690         * rendering/SVGInlineTextBox.cpp:
1691         (WebCore::SVGInlineTextBoxClosestCharacterToPositionWalker::SVGInlineTextBoxClosestCharacterToPositionWalker):
1692         (WebCore::SVGInlineTextBoxClosestCharacterToPositionWalker::chunkPortionCallback):
1693         (WebCore::SVGInlineTextBoxClosestCharacterToPositionWalker::offsetOfHitCharacter):
1694         (WebCore::SVGInlineTextBox::closestCharacterToPosition):
1695         (WebCore::SVGInlineTextBox::svgCharacterHitsPosition):
1696
1697 2009-02-26  Darin Fisher  <darin@chromium.org>
1698
1699         Reviewed by Eric Seidel.
1700
1701         Minor cleanup of ChromiumBridge:
1702         Removing unused matchesMIMEType method and s/Javascript/JavaScript/
1703
1704         * platform/chromium/ChromiumBridge.h:
1705         * platform/chromium/MimeTypeRegistryChromium.cpp:
1706         (WebCore::MIMETypeRegistry::isSupportedImageMIMEType):
1707         (WebCore::MIMETypeRegistry::isSupportedJavaScriptMIMEType):
1708         (WebCore::MIMETypeRegistry::isSupportedNonImageMIMEType):
1709
1710 2009-02-26  David Hyatt  <hyatt@apple.com>
1711
1712         Reviewed by Sam Weinig
1713
1714         Fix text-bottom vertical alignment.  It was incorrectly aligning the bottom of the descent instead of including
1715         the line-height below the descent.
1716
1717         Added fast/inline/vertical-align-text-bottom.html
1718
1719         * rendering/RenderBoxModelObject.cpp:
1720         (WebCore::RenderBoxModelObject::verticalPosition):
1721
1722 2009-02-26  Dirk Schulze  <krit@webkit.org>
1723
1724         Reviewed by Eric Seidel.
1725
1726         Make SVG Masking platform independet with the use of ImageBuffer::getImageData(),
1727         ImageBuffer::putImageData() and GraphicsContext::clipToImageBuffer(). Every platform has
1728         just to implement this three methods to support SVG Masking now.
1729  
1730         Make SVG Masking platform aware
1731         https://bugs.webkit.org/show_bug.cgi?id=19243
1732
1733         * GNUmakefile.am:
1734         * WebCore.pro:
1735         * WebCore.vcproj/WebCore.vcproj:
1736         * WebCore.xcodeproj/project.pbxproj:
1737         * svg/graphics/SVGResourceMasker.cpp:
1738         (WebCore::SVGResourceMasker::applyMask):
1739         * svg/graphics/cairo/SVGResourceMaskerCairo.cpp: Removed.
1740         * svg/graphics/cg/SVGResourceMaskerCg.cpp: Removed.
1741         * svg/graphics/cg/SVGResourceMaskerCg.mm: Removed.
1742         * svg/graphics/qt/SVGResourceMaskerQt.cpp: Removed.
1743         * svg/graphics/skia/SVGResourceMaskerSkia.cpp: Removed.
1744
1745 2009-02-26  Yong Li  <yong.li@torchmobile.com>
1746
1747         Reviewed by Darin Adler, Antti Koivisto and Alexey Proskuryakov.
1748
1749         Test: http/tests/misc/slow-preload-cancel.html
1750
1751         https://bugs.webkit.org/show_bug.cgi?id=24133
1752         Clear all pending preloads in the DocLoader object when we decide to
1753         cancel its all requests.
1754
1755         * loader/DocLoader.cpp:
1756         (WebCore::DocLoader::clearPendingPreloads):
1757         * loader/DocLoader.h:
1758         * loader/loader.cpp:
1759         (WebCore::Loader::cancelRequests):
1760
1761 2009-02-26  Dimitri Glazkov  <dglazkov@chromium.org>
1762
1763         Reviewed by Eric Seidel.
1764
1765         https://bugs.webkit.org/show_bug.cgi?id=24182
1766         Add NodeFilter, NodeIterator, and TreeWalker custom V8 bindings.
1767
1768         * bindings/v8/custom/V8NodeFilterCustom.cpp: Added.
1769         (WebCore::CALLBACK_FUNC_DECL):
1770         * bindings/v8/custom/V8NodeIteratorCustom.cpp: Added.
1771         (WebCore::toV8):
1772         (WebCore::CALLBACK_FUNC_DECL):
1773         * bindings/v8/custom/V8TreeWalkerCustom.cpp: Added.
1774         (WebCore::toV8):
1775         (WebCore::CALLBACK_FUNC_DECL):
1776
1777 2009-02-26  Alexey Proskuryakov  <ap@webkit.org>
1778
1779         Reviewed by Darin Adler.
1780
1781         https://bugs.webkit.org/show_bug.cgi?id=23500
1782         KURL::parse() incorrectly compares its result to original string
1783
1784         * platform/KURL.cpp: (WebCore::KURL::parse): Take string length into account.
1785
1786 2009-02-26  Ojan Vafai  <ojan@chromium.org>
1787
1788         Reviewed by Kevin McCullough.
1789
1790         Manual test for inspector node highlighting.
1791
1792         * manual-tests/inspector/highlight-nodes.html: Added.
1793
1794 2009-02-16  Anantanarayanan Iyengar  <ananta@chromium.org>
1795
1796         Reviewed by Darin Fisher.
1797
1798         https://bugs.webkit.org/show_bug.cgi?id=23973
1799         ScrollView::scrollContents can be invoked during view shutdown.  In
1800         this scenario the FrameView::hostWindow method can return NULL, which
1801         indicates that the frame/page is being destroyed. This causes a crash
1802         when we try to dereference a NULL hostWindow pointer.  Fix is to add a
1803         NULL check for this.  
1804
1805         * platform/ScrollView.cpp:
1806         (WebCore::ScrollView::scrollContents):
1807
1808 2009-02-26  Rahul Kuchhal  <kuchhal@chromium.org>
1809
1810         Reviewed by Dave Hyatt.
1811
1812         https://bugs.webkit.org/show_bug.cgi?id=24003
1813         Fix a crash caused by unsafe type conversion.
1814
1815         Test: fast/block/positioning/absolute-in-inline-rtl-4.html
1816
1817         * rendering/RenderBox.cpp:
1818         (WebCore::RenderBox::calcAbsoluteHorizontalValues):
1819
1820 2009-02-26  Ojan Vafai  <ojan@chromium.org>
1821
1822         Reviewed by Adam Roben.
1823
1824         https://bugs.webkit.org/show_bug.cgi?id=24202
1825         Have drawNodeHighlight clip instead of clearing. This makes it work for
1826         both Safari and Chromium since Chromium draws the inspector highlighting
1827         in the same buffer as the page.
1828
1829         * inspector/InspectorController.cpp:
1830         (WebCore::quadToPath):
1831         (WebCore::drawOutlinedQuad):
1832         (WebCore::drawOutlinedQuadWithClip):
1833         (WebCore::drawHighlightForBox):
1834
1835 2009-02-26  David Hyatt  <hyatt@apple.com>
1836
1837         Reviewed by Dan Bernstein & Darin Adler
1838
1839         Make sure the border/padding are properly omitted at the start of an inline that is a continuation.
1840         
1841         Added fast/inline/inline-continuation-borders.html
1842
1843         * rendering/InlineFlowBox.cpp:
1844         (WebCore::InlineFlowBox::determineSpacingForFlowBoxes):
1845
1846 2009-02-26  Simon Fraser  <simon.fraser@apple.com>
1847
1848         Build fix, no review.
1849         
1850         Try to fix the wx build after r41218.
1851
1852         * WebCoreSources.bkl:
1853
1854 2009-02-26  Alexey Proskuryakov  <ap@webkit.org>
1855
1856         Reviewed by Darin Adler.
1857
1858         https://bugs.webkit.org/show_bug.cgi?id=19527
1859         ASSERTION FAILED: containerA && containerB
1860
1861         Test: fast/dom/Range/bug-19527.html
1862
1863         * dom/Range.cpp:
1864         (WebCore::Range::isPointInRange):
1865         (WebCore::Range::comparePoint):
1866         Bring the behavior in line with current Firefox, making it impossible for these methods
1867         to pass a null container to compareBoundaryPoints().
1868
1869 2009-02-26  Jonathon Jongsma  <jonathon@quotidian.org>
1870
1871         Reviewed by Holger Freyther.
1872
1873         https://bugs.webkit.org/show_bug.cgi?id=20358
1874
1875         * platform/graphics/gtk/SimpleFontDataGtk.cpp:
1876         (WebCore::SimpleFontData::smallCapsFontData): the small-caps font data
1877         should set the computed size rather than the specified size, otherwise
1878         the caps just get rendered normal size.
1879
1880 2009-02-26  Benjamin Meyer  <benjamin.meyer@torchmobile.com>
1881
1882         Reviewed by George Staikos.
1883
1884         https://bugs.webkit.org/show_bug.cgi?id=24062
1885         QNetworkCookieJar expects the url and not the policy url.  Sending the
1886         policy url will cause QNetworkCookieJar to behave incorrectly.  One
1887         example would be a cookie that does not have a path or domain.
1888         QNetworkCookieJar will use the url it is given to fill in default values.
1889         This allows setting cookies on the url of the main frame from an iFrame
1890         when the cookie should be set on the url of the iFrame.
1891
1892         Originally noticed on http://writer.zoho.com/jsp/home.jsp?serviceurl=/index.do
1893
1894         * platform/qt/CookieJarQt.cpp:
1895         (WebCore::setCookies):
1896
1897 2009-02-26  Charles Wei  <charles.wei@torchmobile.com.cn>
1898
1899         Reviewed by George Staikos.
1900
1901         make WebKit/Qt compile with SVG disabled
1902
1903         * WebCore.pro:
1904         * platform/graphics/qt/FontPlatformDataQt.cpp:
1905
1906 2009-02-25  Gustavo Noronha Silva  <gns@gnome.org>
1907
1908         Unreviewed build fix. Add WebCore/workers to the list of paths
1909         searched by the bindings generator perl script.
1910
1911         * GNUmakefile.am:
1912
1913 2009-02-25  Sam Weinig  <sam@webkit.org>
1914
1915         Reviewed by Geoffrey Garen.
1916
1917         Add canvas to the list of RenderObjects that can mark a page as
1918         visually not empty.
1919
1920         * rendering/RenderHTMLCanvas.cpp:
1921         (WebCore::RenderHTMLCanvas::RenderHTMLCanvas):
1922
1923 2009-02-25  Eric Carlson  <eric.carlson@apple.com>
1924
1925         Reviewed by Dave Hyatt.
1926
1927         * rendering/RenderBox.cpp:
1928         (WebCore::RenderBox::nodeAtPoint): Remove assertion fired when child has layer
1929         as RenderMedia with controls always has a layer.
1930
1931 2009-02-25  Dan Bernstein  <mitz@apple.com>
1932
1933         Reviewed by Simon Fraser.
1934
1935         - fix https://bugs.webkit.org/show_bug.cgi?id=24130
1936           <rdar://problem/6618196> Paint very slow when horizontally resizing
1937
1938         Test: fast/gradients/background-clipped.html
1939
1940         * rendering/RenderBoxModelObject.cpp:
1941         (WebCore::RenderBoxModelObject::paintFillLayerExtended): Intersect the
1942         destination rectangle passed to drawTiledImage() with the dirty
1943         rectangle. This makes it more likely for the destination rect to be
1944         contained in a single tile rect, which results in a faster code path
1945         being taken down the road (just drawing a single tile instead of
1946         tiling).
1947
1948 2009-02-25  Ojan Vafai  <ojan@chromium.org>
1949
1950         Reviewed by Eric Seidel.
1951
1952         Fix test regressions from positionForCoordinates patch.
1953         https://bugs.webkit.org/show_bug.cgi?id=24148
1954
1955         * rendering/RenderBlock.cpp:
1956         (WebCore::positionForPointWithInlineChildren):
1957         Remove ASSERT that placeholder text codepath is hitting.
1958
1959 2009-02-25  Chris Fleizach  <cfleizach@apple.com>
1960
1961         Reviewed by Beth Dakin.
1962
1963         Bug 24143: Crash occurs at WebCore::AccessibilityTable::isTableExposableThroughAccessibility() when applying a link in GMail
1964         https://bugs.webkit.org/show_bug.cgi?id=24143
1965
1966         When an AX object is marked dirty, do not create AX elements while going up the parent chain.
1967         Do not allow AXRenderObjects to remove their own IDs from the cache, all the cache to do that work
1968         Make sure the AXObjectWrapper's have an object before calling them
1969         In AXObjectCache, change get -> getOrCreate. Use get() to only retrieve an element if it exists
1970
1971         Test: platform/mac-snowleopard/accessibility/table-updating.html
1972
1973         * WebCore.base.exp:
1974         * page/AXObjectCache.cpp:
1975         (WebCore::AXObjectCache::~AXObjectCache):
1976         (WebCore::AXObjectCache::get):
1977         (WebCore::AXObjectCache::getOrCreate):
1978         (WebCore::AXObjectCache::removeAXID):
1979         (WebCore::AXObjectCache::handleActiveDescendantChanged):
1980         (WebCore::AXObjectCache::handleAriaRoleChanged):
1981         * page/AXObjectCache.h:
1982         * page/AccessibilityImageMapLink.cpp:
1983         (WebCore::AccessibilityImageMapLink::parentObject):
1984         * page/AccessibilityListBox.cpp:
1985         (WebCore::AccessibilityListBox::listBoxOptionAccessibilityObject):
1986         (WebCore::AccessibilityListBox::doAccessibilityHitTest):
1987         * page/AccessibilityListBoxOption.cpp:
1988         (WebCore::AccessibilityListBoxOption::elementRect):
1989         (WebCore::AccessibilityListBoxOption::parentObject):
1990         * page/AccessibilityObject.cpp:
1991         (WebCore::AccessibilityObject::detach):
1992         (WebCore::AccessibilityObject::parentObjectIfExists):
1993         (WebCore::replacedNodeNeedsCharacter):
1994         (WebCore::AccessibilityObject::accessibilityObjectForPosition):
1995         * page/AccessibilityObject.h:
1996         * page/AccessibilityRenderObject.cpp:
1997         (WebCore::AccessibilityRenderObject::firstChild):
1998         (WebCore::AccessibilityRenderObject::lastChild):
1999         (WebCore::AccessibilityRenderObject::previousSibling):
2000         (WebCore::AccessibilityRenderObject::nextSibling):
2001         (WebCore::AccessibilityRenderObject::parentObjectIfExists):
2002         (WebCore::AccessibilityRenderObject::parentObject):
2003         (WebCore::AccessibilityRenderObject::isAttachment):
2004         (WebCore::AccessibilityRenderObject::headingLevel):
2005         (WebCore::AccessibilityRenderObject::anchorElement):
2006         (WebCore::AccessibilityRenderObject::menuForMenuButton):
2007         (WebCore::AccessibilityRenderObject::menuButtonForMenu):
2008         (WebCore::AccessibilityRenderObject::checkboxOrRadioRect):
2009         (WebCore::AccessibilityRenderObject::internalLinkElement):
2010         (WebCore::AccessibilityRenderObject::addRadioButtonGroupMembers):
2011         (WebCore::AccessibilityRenderObject::titleUIElement):
2012         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
2013         (WebCore::AccessibilityRenderObject::accessibilityParentForImageMap):
2014         (WebCore::AccessibilityRenderObject::getDocumentLinks):
2015         (WebCore::AccessibilityRenderObject::doAccessibilityHitTest):
2016         (WebCore::AccessibilityRenderObject::focusedUIElement):
2017         (WebCore::AccessibilityRenderObject::activeDescendant):
2018         (WebCore::AccessibilityRenderObject::observableObject):
2019         (WebCore::AccessibilityRenderObject::childrenChanged):
2020         (WebCore::AccessibilityRenderObject::addChildren):
2021         * page/AccessibilityRenderObject.h:
2022         (WebCore::AccessibilityRenderObject::setRenderObject):
2023         * page/AccessibilityTable.cpp:
2024         (WebCore::AccessibilityTable::addChildren):
2025         (WebCore::AccessibilityTable::headerContainer):
2026         (WebCore::AccessibilityTable::cellForColumnAndRow):
2027         * page/AccessibilityTableCell.cpp:
2028         (WebCore::AccessibilityTableCell::isTableCell):
2029         (WebCore::AccessibilityTableCell::titleUIElement):
2030         * page/AccessibilityTableColumn.cpp:
2031         (WebCore::AccessibilityTableColumn::headerObjectForSection):
2032         * page/AccessibilityTableRow.cpp:
2033         (WebCore::AccessibilityTableRow::isTableRow):
2034         * page/gtk/AccessibilityObjectWrapperAtk.cpp:
2035         * page/mac/AXObjectCacheMac.mm:
2036         (WebCore::AXObjectCache::postNotification):
2037         (WebCore::AXObjectCache::postNotificationToElement):
2038         * page/mac/AccessibilityObjectWrapper.mm:
2039         (textMarkerForVisiblePosition):
2040         (AXLinkElementForNode):
2041         (nsStringForReplacedNode):
2042         (-[AccessibilityObjectWrapper doAXAttributedStringForTextMarkerRange:]):
2043         (-[AccessibilityObjectWrapper accessibilityActionNames]):
2044         (-[AccessibilityObjectWrapper accessibilityAttributeNames]):
2045         (-[AccessibilityObjectWrapper accessibilityFocusedUIElement]):
2046         (-[AccessibilityObjectWrapper accessibilityHitTest:]):
2047         (-[AccessibilityObjectWrapper accessibilityIsAttributeSettable:]):
2048         (-[AccessibilityObjectWrapper accessibilityIsIgnored]):
2049         (-[AccessibilityObjectWrapper accessibilityParameterizedAttributeNames]):
2050         (-[AccessibilityObjectWrapper accessibilityPerformPressAction]):
2051         (-[AccessibilityObjectWrapper accessibilityPerformAction:]):
2052         (-[AccessibilityObjectWrapper accessibilitySetValue:forAttribute:]):
2053         (-[AccessibilityObjectWrapper _accessibilityParentForSubview:]):
2054         (-[AccessibilityObjectWrapper accessibilityIndexOfChild:]):
2055         (-[AccessibilityObjectWrapper accessibilityArrayAttributeCount:]):
2056         (-[AccessibilityObjectWrapper accessibilityArrayAttributeValues:index:maxCount:]):
2057
2058 2009-02-25  Beth Dakin  <bdakin@apple.com>
2059
2060         Reviewed by Geoff Garen.
2061
2062         Re-working of <rdar://problem/6487249> repro crash in 
2063         WebCore::CSSParser::parseFillImage copying entire contents of this 
2064         page
2065         -and corresponding: https://bugs.webkit.org/show_bug.cgi?id=24172
2066
2067         Fixes a bunch of layout test failures I caused!
2068
2069         * css/CSSParser.cpp:
2070         (WebCore::CSSParser::parseValue):
2071         (WebCore::CSSParser::parseContent):
2072         (WebCore::CSSParser::parseFillImage):
2073         (WebCore::CSSParser::parseFontFaceSrc):
2074         (WebCore::CSSParser::parseBorderImage):
2075
2076 2009-02-25  Dimitri Glazkov  <dglazkov@chromium.org>
2077
2078         Reviewed by Eric Seidel.
2079
2080         https://bugs.webkit.org/show_bug.cgi?id=24174
2081         Add more V8 custom bindings.
2082
2083         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp: Added.
2084         (WebCore::hasCSSPropertyNamePrefix):
2085         (WebCore::cssPropertyName):
2086         (WebCore::NAMED_PROPERTY_GETTER):
2087         (WebCore::NAMED_PROPERTY_SETTER):
2088         * bindings/v8/custom/V8DOMStringListCustom.cpp: Added.
2089         (WebCore::INDEXED_PROPERTY_GETTER):
2090         (WebCore::CALLBACK_FUNC_DECL):
2091         * bindings/v8/custom/V8EventCustom.cpp: Added.
2092         (WebCore::ACCESSOR_SETTER):
2093         (WebCore::ACCESSOR_GETTER):
2094         * bindings/v8/custom/V8HTMLDocumentCustom.cpp: Added.
2095         (WebCore::NAMED_PROPERTY_DELETER):
2096         (WebCore::NAMED_PROPERTY_SETTER):
2097         (WebCore::NAMED_PROPERTY_GETTER):
2098         * bindings/v8/custom/V8HTMLFrameSetElementCustom.cpp: Added.
2099         (WebCore::NAMED_PROPERTY_GETTER):
2100         * bindings/v8/custom/V8NamedNodeMapCustom.cpp: Added.
2101         (WebCore::INDEXED_PROPERTY_GETTER):
2102         (WebCore::NAMED_PROPERTY_GETTER):
2103         * bindings/v8/custom/V8NodeListCustom.cpp: Added.
2104         (WebCore::NAMED_PROPERTY_GETTER):
2105         * bindings/v8/custom/V8StyleSheetListCustom.cpp: Added.
2106         (WebCore::NAMED_PROPERTY_GETTER):
2107
2108 2009-02-25  Scott Violet  <sky@google.com>
2109
2110         Reviewed by Dave Hyatt.
2111
2112         https://bugs.webkit.org/show_bug.cgi?id=24171
2113         Provides a RenderTheme method for getting the scroll bar size and
2114         changes RenderListBox to use it. RenderTheme returns a size of regular,
2115         and Mac's override to return small. Changes ScrollbarThemeChromium to
2116         use the scrollbarsize of the scrollbar when getting the size
2117         instead of passing in no-args.
2118
2119         * platform/chromium/ScrollbarThemeChromium.cpp:
2120         (WebCore::ScrollbarThemeChromium::trackRect):
2121         (WebCore::ScrollbarThemeChromium::buttonSize):
2122         * rendering/RenderListBox.cpp:
2123         (WebCore::RenderListBox::createScrollbar):
2124         * rendering/RenderTheme.h:
2125         (WebCore::RenderTheme::scrollbarControlSizeForPart):
2126         * rendering/RenderThemeChromiumMac.h:
2127         (WebCore::RenderThemeChromiumMac::scrollbarControlSizeForPart):
2128         * rendering/RenderThemeMac.h:
2129         (WebCore::RenderThemeMac::scrollbarControlSizeForPart):
2130
2131 2009-02-25  Beth Dakin  <bdakin@apple.com>
2132
2133         Reviewed by Darin Adler.
2134
2135         Fix for <rdar://problem/6487249> repro crash in 
2136         WebCore::CSSParser::parseFillImage copying entire contents of this 
2137         page
2138         -and corresponding: https://bugs.webkit.org/show_bug.cgi?id=24172
2139
2140         * css/CSSParser.cpp:
2141         (WebCore::CSSParser::parseValue): Null-check m_styleSheet
2142
2143 2009-02-25  Adam Treat  <adam.treat@torchmobile.com>
2144
2145         Fix the Qt build.
2146
2147         * WebCore.pro:
2148
2149 2009-02-25  Jan Michael Alonzo  <jmalonzo@webkit.org>
2150
2151         Gtk build fix. Not reviewed.
2152
2153         Add files to the build per r41218.
2154         Rename WebkitPoint.h to WebKitPoint.h in DOMWindow.cpp
2155
2156         * GNUmakefile.am:
2157         * page/DOMWindow.cpp:
2158
2159 2009-02-25  Zan Dobersek  <zandobersek@gmail.com>
2160
2161         Reviewed by Alexey Proskuryakov.
2162
2163         https://bugs.webkit.org/show_bug.cgi?id=24043
2164         When faced with URLs with unsupported protocol on Gtk port,
2165         report the error through an idle function and return true, so
2166         a proper resource handle is created.
2167
2168         * platform/network/soup/ResourceHandleSoup.cpp:
2169         (WebCore::reportUnknownProtocolError):
2170         (WebCore::ResourceHandle::start):
2171
2172 2009-02-25  Steve Falkenburg  <sfalken@apple.com>
2173
2174         Windows build fix.
2175         Use struct to forward declare ResourceRequest.
2176
2177         * history/HistoryItem.h:
2178         * inspector/InspectorController.h:
2179         * loader/DocumentThreadableLoader.h:
2180         * loader/FrameLoaderClient.h:
2181         * loader/MainResourceLoader.h:
2182         * loader/SubresourceLoader.h:
2183         * loader/SubresourceLoaderClient.h:
2184         * loader/ThreadableLoader.h:
2185         * loader/WorkerThreadableLoader.h:
2186         * platform/CrossThreadCopier.h:
2187         * platform/network/ResourceHandle.h:
2188         * platform/network/ResourceHandleClient.h:
2189         * platform/network/ResourceRequestBase.h:
2190         * platform/network/cf/ResourceRequestCFNet.h:
2191         * xml/XMLHttpRequest.h:
2192
2193 2009-02-25  Steve Falkenburg  <sfalken@apple.com>
2194
2195         Partial Windows build fix.
2196         
2197         * DerivedSources.cpp:
2198         * WebCore.vcproj/WebCore.vcproj:
2199
2200 2009-02-25  Dirk Schulze  <krit@webkit.org>
2201
2202         Reviewed by Oliver Hunt.
2203
2204         Ported arcTo to Qt. Qt has no native support for arcTo. This changes
2205         calculate the behavior of arcTo and draws it with lineTo and arc.
2206
2207         [QT] implement Canvas arcTo
2208         https://bugs.webkit.org/show_bug.cgi?id=23873
2209
2210         * platform/graphics/qt/PathQt.cpp:
2211         (WebCore::Path::addArcTo):
2212
2213 2009-02-25  Simon Fraser  <simon.fraser@apple.com>
2214
2215         Reviewed by Dan Bernstein
2216
2217         Remove idl files from Resources, and sort.
2218         
2219         * WebCore.xcodeproj/project.pbxproj:
2220
2221 2009-02-25  Chris Marrin  <cmarrin@apple.com>
2222
2223         Reviewed by Simon Fraser.
2224
2225         https://bugs.webkit.org/show_bug.cgi?id=23943
2226
2227         Added webkitConvertPointFromNodeToPage and webkitConvertPointFromPageToNode on
2228         the window object. Also added WebKitPoint object, which is passed in and out
2229         of these functions.
2230
2231         Test: fast/dom/Window/webkitConvertPoint.html
2232
2233         * DerivedSources.make:
2234         * WebCore.pro:
2235         * WebCore.vcproj/WebCore.vcproj:
2236         * WebCore.xcodeproj/project.pbxproj:
2237         * WebCoreSources.bkl:
2238         * bindings/js/JSDOMWindowBase.cpp:
2239         (jsDOMWindowBaseWebKitPoint):
2240         (setJSDOMWindowBaseWebKitPoint):
2241         * bindings/js/JSWebKitPointConstructor.cpp: Added.
2242         (WebCore::):
2243         (WebCore::JSWebKitPointConstructor::JSWebKitPointConstructor):
2244         (WebCore::constructWebKitPoint):
2245         (WebCore::JSWebKitPointConstructor::getConstructData):
2246         * bindings/js/JSWebKitPointConstructor.h: Added.
2247         (WebCore::JSWebKitPointConstructor::classInfo):
2248         * dom/Node.cpp:
2249         (WebCore::Node::convertToPage):
2250         (WebCore::Node::convertFromPage):
2251         * dom/Node.h:
2252         * page/DOMWindow.cpp:
2253         (WebCore::DOMWindow::webkitConvertPointFromNodeToPage):
2254         (WebCore::DOMWindow::webkitConvertPointFromPageToNode):
2255         * page/DOMWindow.h:
2256         * page/DOMWindow.idl:
2257         * page/WebKitPoint.h: Added.
2258         (WebCore::WebKitPoint::create):
2259         (WebCore::WebKitPoint::x):
2260         (WebCore::WebKitPoint::y):
2261         (WebCore::WebKitPoint::setX):
2262         (WebCore::WebKitPoint::setY):
2263         (WebCore::WebKitPoint::WebKitPoint):
2264         * page/WebKitPoint.idl: Added.
2265
2266 2009-02-25  Jian Li  <jianli@chromium.org>
2267
2268         Reviewed by Alexey Proskuryakov.
2269
2270         Remove "#if ENABLE(WORKERS)" wrap from CrossThreadCopier files.
2271         https://bugs.webkit.org/show_bug.cgi?id=24145
2272
2273         * platform/CrossThreadCopier.cpp:
2274         * platform/CrossThreadCopier.h:
2275
2276 2009-02-25  David Levin  <levin@chromium.org>
2277
2278         Reviewed by Alexey Proskuryakov.
2279
2280         Bug 23688: ThreadableLoader needs a sync implementation for Workers.
2281         <https://bugs.webkit.org/show_bug.cgi?id=23688>
2282
2283         No observable change in behavior, so no test.
2284
2285         * loader/ThreadableLoader.cpp:
2286         (WebCore::ThreadableLoader::loadResourceSynchronously):
2287         * loader/ThreadableLoaderClientWrapper.h:
2288         (WebCore::ThreadableLoaderClientWrapper::clearClient):
2289         (WebCore::ThreadableLoaderClientWrapper::done):
2290         (WebCore::ThreadableLoaderClientWrapper::didFinishLoading):
2291         (WebCore::ThreadableLoaderClientWrapper::didFail):
2292         (WebCore::ThreadableLoaderClientWrapper::didFailRedirectCheck):
2293         (WebCore::ThreadableLoaderClientWrapper::ThreadableLoaderClientWrapper):
2294         Expose whether the loader is done (based on what callbacks were done).
2295
2296         * loader/WorkerThreadableLoader.cpp:
2297         (WebCore::WorkerThreadableLoader::WorkerThreadableLoader):
2298         (WebCore::WorkerThreadableLoader::loadResourceSynchronously):
2299         Each loader is given its own mode so that only its callbacks get through the run loop.
2300
2301         The xhr spec says that the readystatechange events are synchronous, so in the case of a
2302         nested sync xhr no readystatechange events should be fired for the outer xhr.
2303
2304         (WebCore::WorkerThreadableLoader::MainThreadBridge::MainThreadBridge):
2305
2306         * loader/WorkerThreadableLoader.h:
2307         (WebCore::WorkerThreadableLoader::create):
2308         (WebCore::WorkerThreadableLoader::done):
2309
2310         * workers/WorkerRunLoop.cpp:
2311         (WebCore::WorkerRunLoop::WorkerRunLoop):
2312         * workers/WorkerRunLoop.h:
2313         (WebCore::WorkerRunLoop::createUniqueId):
2314         Simple method to create a uniqueId on demand with respect to the run loop.
2315
2316         * workers/WorkerThread.h:
2317
2318 2009-02-25  David Levin  <levin@chromium.org>
2319
2320         Reviewed by Alexey Proskuryakov.
2321
2322         Bug 24089: ThreadableLoader::loadResourceSynchronously should do callbacks like the async code.
2323         <https://bugs.webkit.org/show_bug.cgi?id=24089>
2324
2325         Make threadable loader callbacks to happen during the sync load call.
2326
2327         Changes the behavior of sync xhr for insecure redirects in two ways:
2328         + Sends an error event instead of an abort event (which is the same as async xhr's behavior).
2329         + Throws a network exception which is what other browsers do and what the spec
2330         says to do (http://www.w3.org/TR/XMLHttpRequest/).
2331
2332         * loader/DocumentThreadableLoader.cpp:
2333         (WebCore::DocumentThreadableLoader::loadResourceSynchronously):
2334         * loader/DocumentThreadableLoader.h:
2335         * loader/ThreadableLoader.cpp:
2336         (WebCore::ThreadableLoader::loadResourceSynchronously):
2337         * loader/ThreadableLoader.h:
2338         * xml/XMLHttpRequest.cpp:
2339         (WebCore::XMLHttpRequest::XMLHttpRequest):
2340         (WebCore::XMLHttpRequest::loadRequestSynchronously):
2341         (WebCore::XMLHttpRequest::loadRequestAsynchronously):
2342         (WebCore::XMLHttpRequest::didFail):
2343         (WebCore::XMLHttpRequest::didFailRedirectCheck):
2344         * xml/XMLHttpRequest.h:
2345
2346 2009-02-24  Chris Marrin  <cmarrin@apple.com>
2347
2348         Reviewed by David Hyatt.
2349
2350         https://bugs.webkit.org/show_bug.cgi?id=23368
2351
2352         Added logic to correctly hit test accelerated layers.
2353
2354         Tests: animations/animation-hit-test-transform.html
2355                animations/animation-hit-test.html
2356                transitions/transition-hit-test-transform.html
2357                transitions/transition-hit-test.html
2358
2359         * page/animation/KeyframeAnimation.cpp:
2360         (WebCore::KeyframeAnimation::animate):
2361         * rendering/RenderLayer.cpp:
2362         (WebCore::RenderLayer::hitTestLayer):
2363         (WebCore::RenderLayer::updateClipRects):
2364         * rendering/RenderLayerBacking.cpp:
2365         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
2366
2367 2009-02-25  Alexey Proskuryakov  <ap@webkit.org>
2368
2369         Reviewed by Darin Adler.
2370
2371         https://bugs.webkit.org/show_bug.cgi?id=24067
2372         REGRESSION: Crash in WebCore::Document::initSecurityContext
2373
2374         The crash started to happen when we removed a check for frame->document() being null.
2375         However, the original document shouldn't be null here, because it is needed to alias
2376         security origins. So, this patch fixes the crash by correcting security origin behavior.
2377
2378         Test: http/tests/security/aboutBlank/window-open-self-about-blank.html
2379         This tests for not crashing, and for inheriting the domain from the document being replaced.
2380         Preserving the aliasing cannot be tested for automatically, because we'd need a non-trivial
2381         domain to remove a prefix from.
2382
2383         * loader/FrameLoader.cpp: (WebCore::FrameLoader::begin): Create a new document before
2384         clearing the frame, so that Document::initSecurityContext() could access the old one.
2385
2386 2009-02-25  Jay Campan  <jcampan@google.com>
2387
2388         Reviewed by Darin Fisher.
2389
2390         https://bugs.webkit.org/show_bug.cgi?id=24066
2391
2392         Items in drop-downs were not painted correctly.  Makes sure the
2393         PopupListBox invalidates in the coordinates of the window as this is
2394         FramelessScrollView::invalidateRect paints to.
2395
2396         * platform/chromium/PopupMenuChromium.cpp:
2397         (WebCore::PopupListBox::invalidateRow):
2398
2399 2009-02-24  Simon Fraser  <simon.fraser@apple.com>
2400
2401         Reviewed by Anders Carlsson
2402
2403         https://bugs.webkit.org/show_bug.cgi?id=15081
2404         
2405         Make display:none work for applet, emebed and object elements
2406         by calling rendererIsNeeded() on superclasses.
2407
2408         Tests: fast/replaced/applet-display-none.html
2409                fast/replaced/embed-display-none.html
2410                fast/replaced/object-display-none.html
2411
2412         * html/HTMLAppletElement.cpp:
2413         (WebCore::HTMLAppletElement::rendererIsNeeded):
2414         * html/HTMLElement.cpp:
2415         (WebCore::HTMLElement::rendererIsNeeded):
2416         * html/HTMLEmbedElement.cpp:
2417         (WebCore::HTMLEmbedElement::rendererIsNeeded):
2418         * html/HTMLObjectElement.cpp:
2419         (WebCore::HTMLObjectElement::rendererIsNeeded):
2420
2421 2009-02-24  Simon Fraser  <simon.fraser@apple.com>
2422
2423         Reviewed by Dave Hyatt
2424
2425         https://bugs.webkit.org/show_bug.cgi?id=24137
2426         
2427         Fix localToAbsolute() and absoluteToLocal() to map points through 3d transforms,
2428         taking perspective and transform-style: preserve-3d into account.
2429         
2430         In order to support transform-style: preserve-3d, which keeps elements in a
2431         3d space, we have to carry along an accumulated matrix in TransformState.
2432         We also need to apply the perspective from the parent, if any, with the
2433         appropriate origin.
2434
2435         * GNUmakefile.am:
2436         * WebCore.base.exp:
2437         * WebCore.pro:
2438         * WebCore.scons:
2439         * WebCore.vcproj/WebCore.vcproj:
2440         * WebCore.xcodeproj/project.pbxproj:
2441         * WebCoreSources.bkl:
2442         * css/CSSComputedStyleDeclaration.cpp:
2443         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
2444         * platform/graphics/transforms/TransformationMatrix.cpp:
2445         (WebCore::TransformationMatrix::translate):
2446         (WebCore::TransformationMatrix::translate3d):
2447         (WebCore::TransformationMatrix::translateRight3d):
2448         * platform/graphics/transforms/TransformationMatrix.h:
2449         * rendering/RenderBox.cpp:
2450         (WebCore::RenderBox::mapLocalToAbsolutePoint):
2451         (WebCore::RenderBox::mapAbsoluteToLocalPoint):
2452         * rendering/RenderBox.h:
2453         * rendering/RenderLayer.cpp:
2454         (WebCore::RenderLayer::updateTransform):
2455         (WebCore::RenderLayer::perspectiveTransform):
2456         (WebCore::RenderLayer::perspectiveOrigin):
2457         * rendering/RenderLayer.h:
2458         * rendering/RenderLayerBacking.cpp:
2459         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
2460         * rendering/RenderLayerCompositor.cpp:
2461         (WebCore::requiresCompositingLayerForTransform):
2462         (WebCore::RenderLayerCompositor::layerHas3DContent):
2463         * rendering/RenderObject.cpp:
2464         (WebCore::RenderObject::localToAbsolute):
2465         (WebCore::RenderObject::absoluteToLocal):
2466         (WebCore::RenderObject::mapLocalToAbsolutePoint):
2467         (WebCore::RenderObject::mapAbsoluteToLocalPoint):
2468         * rendering/RenderObject.h:
2469         * rendering/RenderTableCell.cpp:
2470         (WebCore::RenderTableCell::mapLocalToAbsolutePoint):
2471         (WebCore::RenderTableCell::mapAbsoluteToLocalPoint):
2472         * rendering/RenderTableCell.h:
2473         * rendering/RenderView.cpp:
2474         (WebCore::RenderView::mapLocalToAbsolutePoint):
2475         (WebCore::RenderView::mapAbsoluteToLocalPoint):
2476         * rendering/RenderView.h:
2477         * rendering/TransformState.cpp: Added.
2478         (WebCore::TransformState::move):
2479         (WebCore::TransformState::applyTransform):
2480         (WebCore::TransformState::flatten):
2481         * rendering/TransformState.h: Added.
2482         (WebCore::TransformState::):
2483         (WebCore::TransformState::TransformState):
2484         (WebCore::TransformState::move):
2485         * rendering/style/RenderStyle.h:
2486         (WebCore::InheritedFlags::hasPerspective):
2487
2488 2009-02-24  Sam Weinig  <sam@webkit.org>
2489
2490         Reviewed by David Hyatt.
2491
2492         Fix for https://bugs.webkit.org/show_bug.cgi?id=23990
2493         Regression (r40837): JavaScript image popup doesn't work
2494
2495         Make the getClientRects and getBoundingClientRect methods return rects
2496         relative to the viewport.
2497
2498         Test: fast/dom/getBoundingClientRect-getClientRects-relative-to-viewport.html
2499
2500         * dom/Element.cpp:
2501         (WebCore::Element::getClientRects):
2502         (WebCore::Element::getBoundingClientRect):
2503
2504 2009-02-24  Ojan Vafai  <ojan@chromium.org>
2505
2506         Reviewed by Eric Seidel.
2507
2508         SVG pages don't have a body or an html element! 
2509         Don't return early if there is no body.
2510
2511         * editing/VisiblePosition.cpp:
2512         (WebCore::VisiblePosition::canonicalPosition):
2513
2514 2009-02-23  David Hyatt  <hyatt@apple.com>
2515
2516         Reviewed by Eric Seidel
2517
2518         https://bugs.webkit.org/show_bug.cgi?id=23740, painting order wrong for normal flow elements with overflow: hidden
2519         
2520         This patch reworks the painting of overflow.  There is now the concept of a "self-painting layer."  All
2521         layers are considered to be self-painting except for overflow layers that are normal flow (and that don't have
2522         reflections or masks).
2523         
2524         If an overflow layer is not self-painting, then it ends up painted by its parent just like any other normal flow object.
2525         The only difference is that the clip has to be pushed and popped when painting the object's children.
2526         
2527         The lightweight clipping scheme used for controls has been extended to cover overflow now in this simplified case.  With
2528         the code consolidated into reusable push/pop functions, all of the renderers that use overflow have been patched to
2529         use the new functions.
2530         
2531         Hit testing has also been patched to check the overflow clip rect first before recurring into children.
2532         
2533         Scrollbar paint has been moved into RenderBlock for now, since none of the table objects support scrollbars
2534         yet, and scrollbar hit testing was already there anyway.  Now the two code paths are more symmetrical.
2535         
2536         Masks are now treated like normal flow layers (just like reflections).
2537
2538         A couple of test cases have been added to fast/overflow to test the stacking order. 
2539
2540         * rendering/InlineFlowBox.cpp:
2541         (WebCore::InlineFlowBox::nodeAtPoint):
2542         (WebCore::InlineFlowBox::paint):
2543         * rendering/RenderBlock.cpp:
2544         (WebCore::RenderBlock::repaintOverhangingFloats):
2545         (WebCore::RenderBlock::paint):
2546         (WebCore::RenderBlock::paintChildren):
2547         (WebCore::RenderBlock::paintObject):
2548         (WebCore::RenderBlock::paintFloats):
2549         (WebCore::RenderBlock::insertFloatingObject):
2550         (WebCore::RenderBlock::floatRect):
2551         (WebCore::RenderBlock::lowestPosition):
2552         (WebCore::RenderBlock::rightmostPosition):
2553         (WebCore::RenderBlock::leftmostPosition):
2554         (WebCore::RenderBlock::addOverhangingFloats):
2555         (WebCore::RenderBlock::nodeAtPoint):
2556         (WebCore::RenderBlock::hitTestContents):
2557         * rendering/RenderBox.cpp:
2558         (WebCore::RenderBox::nodeAtPoint):
2559         (WebCore::RenderBox::pushContentsClip):
2560         (WebCore::RenderBox::popContentsClip):
2561         * rendering/RenderBox.h:
2562         (WebCore::RenderBox::paintObject):
2563         * rendering/RenderBoxModelObject.cpp:
2564         (WebCore::RenderBoxModelObject::hasSelfPaintingLayer):
2565         * rendering/RenderBoxModelObject.h:
2566         * rendering/RenderLayer.cpp:
2567         (WebCore::RenderLayer::paintLayer):
2568         (WebCore::RenderLayer::hitTestLayer):
2569         (WebCore::RenderLayer::shouldBeNormalFlowOnly):
2570         (WebCore::RenderLayer::isSelfPaintingLayer):
2571         * rendering/RenderLayer.h:
2572         * rendering/RenderTable.cpp:
2573         (WebCore::RenderTable::paint):
2574         (WebCore::RenderTable::paintObject):
2575         (WebCore::RenderTable::nodeAtPoint):
2576         * rendering/RenderTable.h:
2577         * rendering/RenderTableCell.cpp:
2578         (WebCore::RenderTableCell::paint):
2579         * rendering/RenderTableRow.cpp:
2580         (WebCore::RenderTableRow::nodeAtPoint):
2581         (WebCore::RenderTableRow::paint):
2582         * rendering/RenderTableRow.h:
2583         * rendering/RenderTableSection.cpp:
2584         (WebCore::RenderTableSection::paint):
2585         (WebCore::RenderTableSection::paintObject):
2586         (WebCore::RenderTableSection::nodeAtPoint):
2587         * rendering/RenderTableSection.h:
2588         * rendering/RenderTreeAsText.cpp:
2589         (WebCore::write):
2590         (WebCore::writeLayers):
2591
2592 2009-02-24  David Levin  <levin@chromium.org>
2593
2594         Reviewed by NOBODY (build fix).
2595
2596         Attempted build fix for wx-mac.
2597
2598         * WebCoreSources.bkl:
2599
2600 2009-02-24  David Levin  <levin@chromium.org>
2601
2602         Reviewed by NOBODY (build fix).
2603
2604         Attempted build fixes for qt-linux and wx-mac.
2605
2606         * WebCore.pro:
2607         * webcore-base.bkl:
2608
2609 2009-02-24  Ojan Vafai  <ojan@dhcp-172-31-134-214.sfo.corp.google.com>
2610
2611         Reviewed by Sam Weinig.
2612
2613         Fix null pointer error. If the node is the Document, then ownerDocument() 
2614         returns null, document() does not.
2615
2616         * editing/VisiblePosition.cpp:
2617         (WebCore::VisiblePosition::canonicalPosition):
2618
2619 2009-02-24  Jian Li  <jianli@chromium.org>
2620
2621         Reviewed by NOBODY (attempted build fixes).
2622
2623         Fix build break for Windows and Linux.
2624
2625         * GNUmakefile.am:
2626         * WebCore.vcproj/WebCore.vcproj:
2627
2628 2009-02-24  Dimitri Glazkov  <dglazkov@chromium.org>
2629
2630         Reviewed by Eric Seidel.
2631
2632         https://bugs.webkit.org/show_bug.cgi?id=24131
2633         Fix-up COM/RefCounted dichotomy in Chromium port.
2634
2635         * page/chromium/AccessibilityObjectWrapper.h:
2636         (WebCore::AccessibilityObjectWrapper::AccessibilityObjectWrapper): Added
2637         explicit setting of recount.
2638
2639 2009-02-24  Dimitri Glazkov  <dglazkov@chromium.org>
2640
2641         Reviewed by Eric Seidel.
2642
2643         https://bugs.webkit.org/show_bug.cgi?id=24141
2644         Add clarity to V8 interceptor helper function.
2645
2646         * bindings/v8/custom/V8HTMLPlugInElementCustom.cpp:
2647         (WebCore::NAMED_PROPERTY_GETTER): Renamed to notHandledByInterceptor.
2648         (WebCore::NAMED_PROPERTY_SETTER): Ditto.
2649         (WebCore::INDEXED_PROPERTY_GETTER): Ditto.
2650         (WebCore::INDEXED_PROPERTY_SETTER): Ditto.
2651
2652 2009-02-24  Simon Fraser  <simon.fraser@apple.com>
2653
2654         Reviewed by Eric Seidel
2655
2656         Minor numeric cleanup: convert float literals to doubles.
2657         
2658         * platform/graphics/transforms/RotateTransformOperation.cpp:
2659         (WebCore::RotateTransformOperation::blend):
2660
2661 2009-02-24  Mark Mentovai  <mark@chromium.org>
2662
2663         Reviewed by Eric Seidel.
2664
2665         https://bugs.webkit.org/show_bug.cgi?id=24139
2666         Add missing include.
2667
2668         * bindings/v8/ScriptInstance.h:
2669
2670 2009-02-24  Jian Li  <jianli@chromium.org>
2671
2672         Reviewed by Alexey Proskuryakov.
2673
2674         Move worker related files from dom directory to worker directory under WebCore.
2675         https://bugs.webkit.org/show_bug.cgi?id=24123
2676
2677         * DerivedSources.make:
2678         * GNUmakefile.am:
2679         * WebCore.pro:
2680         * WebCore.scons:
2681         * WebCore.vcproj/MigrateIDLAndScripts:
2682         * WebCore.vcproj/WebCore.vcproj:
2683         * WebCore.xcodeproj/project.pbxproj:
2684         * platform/CrossThreadCopier.cpp: Renamed from WebCore/dom/CrossThreadCopier.cpp.
2685         * platform/CrossThreadCopier.h: Renamed from WebCore/dom/CrossThreadCopier.h.
2686         * workers/GenericWorkerTask.h: Renamed from WebCore/dom/GenericWorkerTask.h.
2687         * workers/Worker.cpp: Renamed from WebCore/dom/Worker.cpp.
2688         * workers/Worker.h: Renamed from WebCore/dom/Worker.h.
2689         * workers/Worker.idl: Renamed from WebCore/dom/Worker.idl.
2690         * workers/WorkerContext.cpp: Renamed from WebCore/dom/WorkerContext.cpp.
2691         * workers/WorkerContext.h: Renamed from WebCore/dom/WorkerContext.h.
2692         * workers/WorkerContext.idl: Renamed from WebCore/dom/WorkerContext.idl.
2693         * workers/WorkerContextProxy.h: Renamed from WebCore/dom/WorkerContextProxy.h.
2694         * workers/WorkerLocation.cpp: Renamed from WebCore/dom/WorkerLocation.cpp.
2695         * workers/WorkerLocation.h: Renamed from WebCore/dom/WorkerLocation.h.
2696         * workers/WorkerLocation.idl: Renamed from WebCore/dom/WorkerLocation.idl.
2697         * workers/WorkerMessagingProxy.cpp: Renamed from WebCore/dom/WorkerMessagingProxy.cpp.
2698         * workers/WorkerMessagingProxy.h: Renamed from WebCore/dom/WorkerMessagingProxy.h.
2699         * workers/WorkerObjectProxy.h: Renamed from WebCore/dom/WorkerObjectProxy.h.
2700         * workers/WorkerRunLoop.cpp: Renamed from WebCore/dom/WorkerRunLoop.cpp.
2701         * workers/WorkerRunLoop.h: Renamed from WebCore/dom/WorkerRunLoop.h.
2702         * workers/WorkerThread.cpp: Renamed from WebCore/dom/WorkerThread.cpp.
2703         * workers/WorkerThread.h: Renamed from WebCore/dom/WorkerThread.h.
2704
2705 2009-02-05  Ojan Vafai  <ojan@chromium.org> and Eric Seidel <eric@webkit.org>
2706
2707         Reviewed by Dave Hyatt.
2708
2709         Make cursor positions match IE6/IE7/FF3 when clicking in margins/padding
2710         around divs inside editable regions.
2711         https://bugs.webkit.org/show_bug.cgi?id=23605
2712
2713         Fix clicks outside editable regions from focusing the editable region.
2714         https://bugs.webkit.org/show_bug.cgi?id=23607
2715
2716         Removed editing/selection/contenteditable-click-outside.html as it's
2717         not as useful as our new tests.
2718
2719         Clean up RenderBlock::positionForCoordinates to remove dead code,
2720         duplicate code, and generally make it more readable.
2721
2722         Tests: editing/selection/click-in-margins-inside-editable-div.html
2723                editing/selection/click-in-padding-with-multiple-line-boxes.html
2724                editing/selection/click-outside-editable-div.html
2725
2726         * editing/VisiblePosition.cpp:
2727         (WebCore::VisiblePosition::canonicalPosition):
2728         * rendering/RenderBlock.cpp:
2729         (WebCore::positionForPointRespectingEditingBoundaries):
2730         (WebCore::positionForPointWithInlineChildren):
2731         (WebCore::RenderBlock::positionForCoordinates):
2732         (WebCore::RenderBlock::updateFirstLetter):
2733
2734 2009-02-24  Sam Weinig  <sam@webkit.org>
2735
2736         Reviewed by Geoffrey Garen.
2737
2738         Related to <rdar://problem/6590295>
2739         Allow disabling javascript: urls.
2740
2741         * WebCore.base.exp:
2742         * html/HTMLAnchorElement.cpp:
2743         (WebCore::HTMLAnchorElement::parseMappedAttribute):
2744         * loader/FrameLoader.cpp:
2745         (WebCore::FrameLoader::executeIfJavaScriptURL):
2746         * page/Page.cpp:
2747         (WebCore::Page::Page):
2748         (WebCore::Page::setJavaScriptURLsAreAllowed):
2749         (WebCore::Page::javaScriptURLsAreAllowed):
2750         * page/Page.h:
2751
2752 2009-02-24  Simon Fraser  <simon.fraser@apple.com>
2753
2754         Fix build when ACCELERATED_COMPOSITING is turned on
2755         (overflowList() -> normalFlowList()).
2756     
2757         * rendering/RenderLayerBacking.cpp:
2758         (WebCore::RenderLayerBacking::hasNonCompositingContent):
2759         (WebCore::RenderLayerBacking::paintIntoLayer):
2760         * rendering/RenderLayerCompositor.cpp:
2761         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
2762         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
2763         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
2764         (WebCore::RenderLayerCompositor::recursiveRepaintLayerRect):
2765         (WebCore::RenderLayerCompositor::layerHas3DContent):
2766
2767 2009-02-24  Simon Fraser  <simon.fraser@apple.com>
2768
2769         Reviewed by Darin Adler
2770         
2771         https://bugs.webkit.org/show_bug.cgi?id=24135
2772         
2773         Round the FloatPoint returned by absoluteToLocal(), rather than
2774         truncating it.
2775
2776         * dom/MouseRelatedEvent.cpp:
2777         (WebCore::MouseRelatedEvent::receivedTarget):
2778
2779 2009-02-24  Beth Dakin  <bdakin@apple.com>
2780
2781         Reviewed by Sam Weinig.
2782
2783         Fix for https://bugs.webkit.org/show_bug.cgi?id=24004 REGRESSION: 
2784         Ordered list item marker misaligned when line height is not 1.2 
2785         -and corresponding <rdar://problem/6602506>
2786
2787         This is a regression from http://trac.webkit.org/changeset/40880 
2788         where createInlineBox was taken off of RenderObject and moved to 
2789         RenderBox. The problem was that the RenderBox version still needs 
2790         to be virtual because there is still an existing implementation in 
2791         RenderListMarker. 
2792
2793         * rendering/RenderBox.h:
2794         * rendering/RenderListMarker.cpp:
2795         (WebCore::RenderListMarker::createInlineBox):
2796         * rendering/RenderListMarker.h:
2797
2798 2009-02-24  Dimitri Glazkov  <dglazkov@chromium.org>
2799
2800         Reviewed by Eric Seidel.
2801
2802         https://bugs.webkit.org/show_bug.cgi?id=24128
2803         Upstream more V8 custom bindings: constructors, XSLTProcessor.
2804
2805         * bindings/v8/custom/V8DOMParserConstructor.cpp: Added.
2806         (WebCore::CALLBACK_FUNC_DECL):
2807         * bindings/v8/custom/V8MessageChannelConstructor.cpp: Added.
2808         (WebCore::CALLBACK_FUNC_DECL):
2809         * bindings/v8/custom/V8WebKitCSSMatrixConstructor.cpp: Added.
2810         (WebCore::CALLBACK_FUNC_DECL):
2811         * bindings/v8/custom/V8XMLSerializerConstructor.cpp: Added.
2812         (WebCore::CALLBACK_FUNC_DECL):
2813         * bindings/v8/custom/V8XPathEvaluatorConstructor.cpp: Added.
2814         (WebCore::CALLBACK_FUNC_DECL):
2815         * bindings/v8/custom/V8XSLTProcessorCustom.cpp: Added.
2816         (WebCore::CALLBACK_FUNC_DECL):
2817
2818 2009-02-24  David Levin  <levin@chromium.org>
2819
2820         Reviewed by Alexey Proskuryakov.
2821
2822         Bug 24090: WorkerThreadableLoader needs to be able to post tasks for a mode.
2823         <https://bugs.webkit.org/show_bug.cgi?id=24090>
2824
2825         No observable change in behavior, so no test.
2826
2827         * dom/WorkerMessagingProxy.cpp:
2828         (WebCore::WorkerMessagingProxy::postMessageToWorkerContext):
2829         (WebCore::WorkerMessagingProxy::postTaskToWorkerContext):
2830         Fixed the bug that m_unconfirmedMessageCount was getting incremented for non-message tasks.
2831
2832         (WebCore::WorkerMessagingProxy::postTaskForModeToWorkerContext):
2833
2834         * dom/WorkerMessagingProxy.h:
2835         * loader/ThreadableLoader.cpp:
2836         (WebCore::ThreadableLoader::create):
2837         * loader/WorkerThreadableLoader.cpp:
2838         (WebCore::WorkerThreadableLoader::WorkerThreadableLoader):
2839         (WebCore::WorkerThreadableLoader::MainThreadBridge::MainThreadBridge):
2840         (WebCore::WorkerThreadableLoader::MainThreadBridge::didSendData):
2841         (WebCore::WorkerThreadableLoader::MainThreadBridge::didReceiveResponse):
2842         (WebCore::WorkerThreadableLoader::MainThreadBridge::didReceiveData):
2843         (WebCore::WorkerThreadableLoader::MainThreadBridge::didFinishLoading):
2844         (WebCore::WorkerThreadableLoader::MainThreadBridge::didFail):
2845         (WebCore::WorkerThreadableLoader::MainThreadBridge::didFailRedirectCheck):
2846         (WebCore::WorkerThreadableLoader::MainThreadBridge::didReceiveAuthenticationCancellation):
2847         Changed these methods to post task using a mode.
2848
2849         * loader/WorkerThreadableLoader.h:
2850         (WebCore::WorkerThreadableLoader::create):
2851
2852 2009-02-24  Alexey Proskuryakov  <ap@webkit.org>
2853
2854         Reviewed by Darin Adler.
2855
2856         https://bugs.webkit.org/show_bug.cgi?id=24091
2857         <rdar://problem/6468660> Start of redirect chain ends up as master entry in Application Cache
2858
2859         Test: http/tests/appcache/access-via-redirect.php
2860
2861         * loader/appcache/ApplicationCacheGroup.cpp:
2862         (WebCore::ApplicationCacheGroup::finishedLoadingMainResource): Use the URL we ended up with,
2863         not the original one.
2864
2865 2009-02-24  Jian Li  <jianli@chromium.org>
2866
2867         Reviewed by Alexey Proskuryakov.
2868
2869         Change to include WorkerObjectProxy.h instead of WorkerMessagingProxy.h in WorkerContext.cpp and WorkerScriptController.cpp.
2870         https://bugs.webkit.org/show_bug.cgi?id=24112
2871
2872         * bindings/js/WorkerScriptController.cpp:
2873         * dom/WorkerContext.cpp:
2874
2875 2009-02-23  Antti Koivisto  <antti@apple.com>
2876
2877         Reviewed by Oliver Hunt.
2878
2879         <rdar://problem/6613796> Extended text codecs registered on webview creation
2880
2881         Comparing a text encoding with string "GBK" ended up constructing
2882         TextEncoding("GBK") which in turn initialized all extended
2883         text codecs.
2884
2885         * platform/text/TextCodecICU.cpp:
2886         (WebCore::TextCodecICU::decode):
2887
2888 2009-02-23  Sam Weinig  <sam@webkit.org>
2889
2890         Fix Qt build.
2891
2892         * bridge/qt/qt_runtime.cpp:
2893         (JSC::Bindings::valueRealType):
2894
2895 2009-02-23  Julien Chaffraix  <jchaffraix@webkit.org>
2896
2897         Reviewed by Darin Adler.
2898
2899         Bug 23956: Safari crashes when cloneNode fails (cloning a XML element with an invalid nodeName)
2900
2901         The crash occurred because Document::cloneNode would call Document::createElementNS. Unfortunately
2902         element created with createElement could have a wrong nodeName (createElement sets the string as the
2903         localName without checking for a prefix).
2904
2905         The fix is to call Document::createElement(const QualifiedName&, bool) that will not do any checks on the QualifiedName
2906         and will always succeed.
2907         Also rolled-out the HTMLElement specialisation of clonedNode as it was equivalent to what is done now (added an ASSERT
2908         to ensure that).
2909
2910         Test: fast/dom/cloneNode.html
2911
2912         * dom/Element.cpp:
2913         (WebCore::Element::cloneNode): Call createElement(const QualifiedName&, bool) instead of createElementNS as it will
2914         always return an element.
2915
2916         * html/HTMLElement.cpp:
2917         * html/HTMLElement.h: Removed HTMLElement::clonedNode as it is equivalent to what is now done.
2918
2919 2009-02-23  Dimitri Glazkov  <dglazkov@chromium.org>
2920
2921         Reviewed by Eric Seidel.
2922
2923         https://bugs.webkit.org/show_bug.cgi?id=24109
2924         Upstream V8 Script abstractions, all except ScriptController.
2925
2926         * bindings/v8/ScriptCachedFrameData.h: Added.
2927         (WebCore::ScriptCachedFrameData::ScriptCachedFrameData):
2928         (WebCore::ScriptCachedFrameData::~ScriptCachedFrameData):
2929         (WebCore::ScriptCachedFrameData::restore):
2930         (WebCore::ScriptCachedFrameData::clear):
2931         (WebCore::ScriptCachedFrameData::domWindow):
2932         * bindings/v8/ScriptCallFrame.cpp: Added.
2933         (WebCore::ScriptCallFrame::ScriptCallFrame):
2934         (WebCore::ScriptCallFrame::~ScriptCallFrame):
2935         (WebCore::ScriptCallFrame::argumentAt):
2936         * bindings/v8/ScriptCallFrame.h: Added.
2937         (WebCore::ScriptCallFrame::functionName):
2938         (WebCore::ScriptCallFrame::sourceURL):
2939         (WebCore::ScriptCallFrame::lineNumber):
2940         (WebCore::ScriptCallFrame::argumentCount):
2941         * bindings/v8/ScriptCallStack.cpp: Added.
2942         (WebCore::ScriptCallStack::ScriptCallStack):
2943         (WebCore::ScriptCallStack::~ScriptCallStack):
2944         (WebCore::ScriptCallStack::at):
2945         * bindings/v8/ScriptCallStack.h: Added.
2946         (WebCore::ScriptCallStack::size):
2947         * bindings/v8/ScriptInstance.cpp: Added.
2948         (WebCore::V8ScriptInstance::V8ScriptInstance):
2949         (WebCore::V8ScriptInstance::~V8ScriptInstance):
2950         (WebCore::V8ScriptInstance::instance):
2951         (WebCore::V8ScriptInstance::clear):
2952         (WebCore::V8ScriptInstance::set):
2953         * bindings/v8/ScriptInstance.h: Added.
2954         (WebCore::V8ScriptInstance::create):
2955         * bindings/v8/ScriptSourceCode.h: Added.
2956         (WebCore::ScriptSourceCode::ScriptSourceCode):
2957         (WebCore::ScriptSourceCode::isEmpty):
2958         (WebCore::ScriptSourceCode::source):
2959         (WebCore::ScriptSourceCode::url):
2960         (WebCore::ScriptSourceCode::startLine):
2961         * bindings/v8/ScriptState.h: Added.
2962         (WebCore::ScriptState::hadException):
2963         (WebCore::ScriptState::setException):
2964         (WebCore::ScriptState::exception):
2965         * bindings/v8/ScriptString.h: Added.
2966         (WebCore::ScriptString::ScriptString):
2967         (WebCore::ScriptString::operator String):
2968         (WebCore::ScriptString::isNull):
2969         (WebCore::ScriptString::size):
2970         (WebCore::ScriptString::operator=):
2971         (WebCore::ScriptString::operator+=):
2972         * bindings/v8/ScriptValue.cpp: Added.
2973         (WebCore::ScriptValue::getString):
2974         * bindings/v8/ScriptValue.h: Added.
2975         (WebCore::ScriptValue::ScriptValue):
2976         (WebCore::ScriptValue::operator=):
2977         (WebCore::ScriptValue::operator==):
2978         (WebCore::ScriptValue::operator!=):
2979         (WebCore::ScriptValue::isNull):
2980         (WebCore::ScriptValue::isUndefined):
2981         (WebCore::ScriptValue::clear):
2982         (WebCore::ScriptValue::~ScriptValue):
2983         (WebCore::ScriptValue::v8Value):
2984
2985 2009-02-23  Adam Treat  <adam.treat@torchmobile.com>
2986
2987         Reviewed by Timothy Hatcher.
2988
2989         https://bugs.webkit.org/show_bug.cgi?id=24106
2990         The Qt port is crashing on exit because the tear down procedure involves
2991         the WebCore::InspectorController trying to access the JS execution context
2992         for a page that is being deleted.  This patch amends the inspector so
2993         that it does not try and access the execution context of the WebCore::Page
2994         in the midst of deletion.
2995
2996         * inspector/InspectorController.cpp:
2997         (WebCore::InspectorController::inspectedPageDestroyed):
2998         (WebCore::InspectorController::stopUserInitiatedProfiling):
2999
3000 2009-02-23  David Levin  <levin@chromium.org>
3001
3002         Reviewed by Alexey Proskuryakov.
3003
3004         Bug 24088: ThreadableLoaderClient::didFailWillSendRequestCheck isn't wired up completely for workers and could use a better name.
3005         <https://bugs.webkit.org/show_bug.cgi?id=24088>
3006
3007         No observable change in behavior, so no test.
3008
3009         * loader/DocumentThreadableLoader.cpp:
3010         (WebCore::DocumentThreadableLoader::create):
3011         * loader/ThreadableLoaderClient.h:
3012         (WebCore::ThreadableLoaderClient::didFailRedirectCheck):
3013         * loader/ThreadableLoaderClientWrapper.h:
3014         (WebCore::ThreadableLoaderClientWrapper::didFailRedirectCheck):
3015         * loader/WorkerThreadableLoader.cpp:
3016         (WebCore::workerContextDidFailRedirectCheck):
3017         (WebCore::WorkerThreadableLoader::MainThreadBridge::didFailRedirectCheck):
3018         * loader/WorkerThreadableLoader.h:
3019         * xml/XMLHttpRequest.cpp:
3020         (WebCore::XMLHttpRequest::didFinishLoading):
3021         * xml/XMLHttpRequest.h:
3022
3023 2009-02-23  David Levin  <levin@chromium.org>
3024
3025         Reviewed by Alexey Proskuryakov.
3026
3027         Bug 24047: Need to simplify nested if's in WorkerRunLoop::runInMode
3028         <https://bugs.webkit.org/show_bug.cgi?id=24047>
3029
3030         Made a nested if inside of WorkerRunLoop::runInMode a lot simpler by
3031         using only MessageQueue::waitForMessageFilteredWithTimeout instead
3032         of three different MessageQueue methods.
3033
3034         No observable change in behavior, so no test.
3035
3036         * dom/WorkerRunLoop.cpp:
3037         (WebCore::ModePredicate::operator()):
3038         Minor clean-up to able to pass a const ref point for ModePredicate into runInMode.
3039         (WebCore::WorkerRunLoop::runInMode):
3040         * dom/WorkerRunLoop.h:
3041
3042 2009-02-23  David Hyatt  <hyatt@apple.com>
3043
3044         In preparation for making layers for multicol objects (so that they can properly split child layers
3045         into multiple columns), rename all of the "overflowOnly" and "overflowList" members and functions
3046         of RenderLayer to use the term "normal flow" instead.
3047
3048         Reviewed by Cameron Zwarich
3049
3050         * rendering/RenderLayer.cpp:
3051         (WebCore::RenderLayer::RenderLayer):
3052         (WebCore::RenderLayer::~RenderLayer):
3053         (WebCore::RenderLayer::setHasVisibleContent):
3054         (WebCore::RenderLayer::enclosingCompositingLayer):
3055         (WebCore::RenderLayer::addChild):
3056         (WebCore::RenderLayer::removeChild):
3057         (WebCore::RenderLayer::paintLayer):
3058         (WebCore::RenderLayer::hitTestLayer):
3059         (WebCore::RenderLayer::dirtyNormalFlowList):
3060         (WebCore::RenderLayer::updateNormalFlowList):
3061         (WebCore::RenderLayer::collectLayers):
3062         (WebCore::RenderLayer::updateLayerListsIfNeeded):
3063         (WebCore::RenderLayer::shouldBeNormalFlowOnly):
3064         (WebCore::RenderLayer::styleChanged):
3065         * rendering/RenderLayer.h:
3066         (WebCore::RenderLayer::isNormalFlowOnly):
3067         (WebCore::RenderLayer::normalFlowList):
3068         * rendering/RenderTreeAsText.cpp:
3069         (WebCore::writeLayers):
3070
3071 2009-02-23  David Hyatt  <hyatt@apple.com>
3072
3073         Fix the stacking order for column rules in multi-column layout.  Column rules should paint as part of the background of an element, just
3074         after all other components of the background have been painted.  This allows negative z-index children to still paint on top of the
3075         column rules (rather than ending up above the background of the box but behind the column rules).
3076
3077         Reviewed by Eric Seidel
3078
3079         Added fast/multicol/column-rules-stacking.html
3080
3081         * rendering/RenderBlock.cpp:
3082         (WebCore::RenderBlock::paintColumnRules):
3083         (WebCore::RenderBlock::paintColumnContents):
3084         (WebCore::RenderBlock::paintObject):
3085         * rendering/RenderBlock.h:
3086
3087 2009-02-23  Adam Treat  <adam.treat@torchmobile.com>
3088
3089         Reviewed by David Hyatt.
3090
3091         No testcases have been added or modified since this patch should not result in
3092         a behavior change for ports that have layout tests enabled.
3093
3094         Currently, the implementation of GraphicsContext::drawLineForText amongst
3095         the various ports differ in that some of them are honoring the context's
3096         strokeStyle when drawing a text-decoration and some of them are not.
3097         For instance, Apple's Mac port *does not* honor the context's strokeStyle(),
3098         but the Cairo implementation does and has an explicit workaround that
3099         sets the strokeStyle() temporarily.
3100
3101         This patch fixes so that all ports are consistent by explicitly making sure
3102         to set the GraphicsContext strokeStyle to SolidStroke whenever
3103         painting the text-decoration of an InlineFlowBox or InlineTextBox as these
3104         should always use a solid stroke.
3105
3106         This patch addresses these bugs:
3107         https://bugs.webkit.org/show_bug.cgi?id=19364
3108         https://bugs.webkit.org/show_bug.cgi?id=15659
3109
3110         * rendering/InlineFlowBox.cpp:
3111         (WebCore::InlineFlowBox::paintTextDecorations):
3112         * rendering/InlineTextBox.cpp:
3113         (WebCore::InlineTextBox::paintDecoration):
3114
3115 2009-02-23  Scott Violet  <sky@google.com>
3116
3117         Reviewed by Eric Seidel.
3118
3119         https://bugs.webkit.org/show_bug.cgi?id=24098
3120         Bugs in ClipboardChromium
3121
3122         Fixes the following bugs in ClipboardChromium:
3123         * It's possible for the extension to be empty, resulting in a bad file
3124           name, for example, 'foo.' or just '.'.
3125         * We weren't restricting the size of the file to MAX_PATH.
3126         * We weren't removing characters that are invalid for file system names.
3127
3128         * platform/chromium/ClipboardChromium.cpp:
3129         (WebCore::writeImageToDataObject):
3130         * platform/chromium/ClipboardChromium.h:
3131         * platform/chromium/ClipboardChromiumLinux.cpp: Added.
3132         (WebCore::ClipboardChromium::validateFileName):
3133         * platform/chromium/ClipboardChromiumMac.cpp: Added.
3134         (WebCore::ClipboardChromium::validateFileName):
3135         * platform/chromium/ClipboardChromiumWin.cpp: Added.
3136         (WebCore::isInvalidFileCharacter):
3137         (WebCore::ClipboardChromium::validateFileName):
3138
3139 2009-02-23  Thiago Macieira  <thiago.macieira@nokia.com>
3140
3141         Reviewed by Simon Hausmann.
3142
3143         Fix the Copyright notices in a few files
3144
3145         * platform/qt/RenderThemeQt.h:
3146
3147 2009-02-23  Xan Lopez  <xan@gnome.org>
3148
3149         Reviewed by Alexey Proskuryakov.
3150
3151         https://bugs.webkit.org/show_bug.cgi?id=22624
3152         [SOUP][GTK] Need API to get SoupSession from WebKit.
3153
3154         Allow to retrieve the Soup session and modify the code to take
3155         into account users changing features on it.
3156
3157         * platform/network/ResourceHandle.h:
3158         * platform/network/soup/CookieJarSoup.cpp:
3159         (WebCore::defaultCookieJar):
3160         (WebCore::setDefaultCookieJar):
3161         * platform/network/soup/CookieJarSoup.h:
3162         * platform/network/soup/ResourceHandleSoup.cpp:
3163         (WebCore::createSoupSession):
3164         (WebCore::ensureSessionIsInitialized):
3165         (WebCore::ResourceHandle::startHttp):
3166         (WebCore::ResourceHandle::cancel):
3167         (WebCore::ResourceHandle::defaultSession):
3168
3169 2009-02-23  Xan Lopez  <xan@gnome.org>
3170
3171         Reviewed by Alexey Proskuryakov.
3172
3173         https://bugs.webkit.org/show_bug.cgi?id=22624
3174         [SOUP][GTK] Need API to get SoupSession from WebKit.
3175
3176         Remove CURL support.
3177
3178         * GNUmakefile.am:
3179
3180 2009-02-23  Alexey Proskuryakov  <ap@webkit.org>
3181
3182         Reviewed by Mark Rowe.
3183
3184         Test: fast/dom/empty-hash-and-search.html
3185
3186         https://bugs.webkit.org/show_bug.cgi?id=21147
3187         hash property returns incorrect value for links w/o hash
3188
3189         Make hash() and search() behavior for empty and missing parts match IE and Firefox.
3190
3191         * platform/KURL.cpp:
3192         (WebCore::KURL::query): Changed to return query without '?', as it is already done for ref().
3193         (WebCore::KURL::prettyURL): Append the query with the question mark.
3194
3195         * page/Location.cpp:
3196         (WebCore::Location::search): Return an empty string if query is empty or missing.
3197         (WebCore::Location::hash): Return an empty string for empty hashes, not only missing ones.
3198
3199         * dom/WorkerLocation.cpp:
3200         (WebCore::WorkerLocation::search):
3201         (WebCore::WorkerLocation::hash):
3202         Match document.location fixes above.
3203
3204         * html/HTMLAnchorElement.cpp:
3205         (WebCore::HTMLAnchorElement::hash):
3206         (WebCore::HTMLAnchorElement::search):
3207         Return an empty string for empty and missing parts.
3208
3209 2009-02-23  Alexey Proskuryakov  <ap@webkit.org>
3210
3211         Reviewed by Darin Adler.
3212
3213         https://bugs.webkit.org/show_bug.cgi?id=20184
3214         SELECT with no name generates invalid query string
3215
3216         Test: fast/forms/select-no-name.html
3217
3218         * html/HTMLSelectElement.cpp:
3219         (WebCore::HTMLSelectElement::appendFormData): Added a check for empty name.
3220
3221 2009-02-23  Alexey Proskuryakov  <ap@webkit.org>
3222
3223         Apply review comments for the previous check-in (forgot to save the file, oops).
3224
3225         * dom/ContainerNode.cpp: (WebCore::ContainerNode::removeChildren):
3226
3227 2009-02-23  Alexey Proskuryakov  <ap@webkit.org>
3228
3229         Reviewed by Darin Adler.
3230
3231         https://bugs.webkit.org/show_bug.cgi?id=15707
3232         Crash when manipulating document from within an iframe onload function
3233
3234         Test: fast/dom/onload-open.html
3235
3236         * dom/ContainerNode.cpp: (WebCore::ContainerNode::removeChildren): Protect the container and
3237         the current node, because anything can happen when dispatching events.
3238
3239 2009-02-23  Alexey Proskuryakov  <ap@webkit.org>
3240
3241         Reviewed by Darin Adler.
3242
3243         https://bugs.webkit.org/show_bug.cgi?id=18970
3244         Numerically named input fields cause document.forms loop problems
3245
3246         Test: fast/forms/numeric-input-name.html
3247
3248         * bindings/scripts/CodeGeneratorJS.pm: Try index getter before name getter, even if the
3249         latter overrides properties.
3250
3251 2009-02-23  Alexey Proskuryakov  <ap@webkit.org>
3252
3253         Reviewed by Sam Weinig.
3254
3255         https://bugs.webkit.org/show_bug.cgi?id=24059
3256         Tokenizer::write() return value is never used
3257
3258         * dom/Tokenizer.h:
3259         * dom/XMLTokenizer.cpp:
3260         (WebCore::XMLTokenizer::write):
3261         * dom/XMLTokenizer.h:
3262         * html/HTMLTokenizer.cpp:
3263         (WebCore::HTMLTokenizer::write):
3264         * html/HTMLTokenizer.h:
3265         * loader/FTPDirectoryDocument.cpp:
3266         (WebCore::FTPDirectoryTokenizer::write):
3267         * loader/ImageDocument.cpp:
3268         (WebCore::ImageTokenizer::write):
3269         * loader/MediaDocument.cpp:
3270         (WebCore::MediaTokenizer::write):
3271         * loader/PluginDocument.cpp:
3272         (WebCore::PluginTokenizer::write):
3273         * loader/TextDocument.cpp:
3274         (WebCore::TextTokenizer::write):
3275         Made write() return void, not bool.
3276
3277 2009-02-20  Geoffrey Garen  <ggaren@apple.com>
3278
3279         Reviewed by Sam Weinig.
3280
3281         Updated for JavaScriptCore changes to timeout checking.
3282
3283         * bindings/js/JSCustomPositionCallback.cpp:
3284         (WebCore::JSCustomPositionCallback::handleEvent):
3285         * bindings/js/JSCustomPositionErrorCallback.cpp:
3286         (WebCore::JSCustomPositionErrorCallback::handleEvent):
3287         * bindings/js/JSCustomSQLStatementCallback.cpp:
3288         (WebCore::JSCustomSQLStatementCallback::handleEvent):
3289         * bindings/js/JSCustomSQLStatementErrorCallback.cpp:
3290         (WebCore::JSCustomSQLStatementErrorCallback::handleEvent):
3291         * bindings/js/JSCustomSQLTransactionCallback.cpp:
3292         (WebCore::JSCustomSQLTransactionCallback::handleEvent):
3293         * bindings/js/JSCustomSQLTransactionErrorCallback.cpp:
3294         (WebCore::JSCustomSQLTransactionErrorCallback::handleEvent):
3295         * bindings/js/JSCustomVoidCallback.cpp:
3296         (WebCore::JSCustomVoidCallback::handleEvent):
3297         * bindings/js/JSCustomXPathNSResolver.cpp:
3298         (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
3299         * bindings/js/JSDOMWindowBase.cpp:
3300         (WebCore::JSDOMWindowBase::JSDOMWindowBase):
3301         (WebCore::JSDOMWindowBase::commonJSGlobalData):
3302         * bindings/js/JSEventListener.cpp:
3303         (WebCore::JSAbstractEventListener::handleEvent):
3304         * bindings/js/ScheduledAction.cpp:
3305         (WebCore::ScheduledAction::executeFunctionInContext):
3306         * bindings/js/ScriptController.cpp:
3307         (WebCore::ScriptController::evaluate):
3308         * bindings/js/WorkerScriptController.cpp:
3309         (WebCore::WorkerScriptController::evaluate):
3310         (WebCore::WorkerScriptController::forbidExecution):
3311         * bindings/objc/WebScriptObject.mm:
3312         (-[WebScriptObject callWebScriptMethod:withArguments:]):
3313         (-[WebScriptObject evaluateWebScript:]):
3314         * bridge/NP_jsobject.cpp:
3315         (_NPN_InvokeDefault):
3316         (_NPN_Invoke):
3317         (_NPN_Evaluate):
3318         (_NPN_Construct):
3319         * bridge/jni/jni_jsobject.mm:
3320         (JavaJSObject::call):
3321         (JavaJSObject::eval):
3322
3323 2009-02-21  Hironori Bono  <hbono@chromium.org>
3324
3325         Reviewed by Alexey Proskuryakov.
3326
3327         https://bugs.webkit.org/show_bug.cgi?id=23786
3328         [Chromium] line-break characters in a complex text are treated as zero-width spaces
3329
3330         This change prevents the UniscribeHelper class from treating the line-break characters
3331         as whitespaces.
3332
3333         Tests: fast/text/international/bidi-linebreak-001.html
3334                fast/text/international/bidi-linebreak-002.html
3335                fast/text/international/bidi-linebreak-003.html
3336
3337         * platform/graphics/chromium/UniscribeHelper.cpp:
3338         (WebCore::UniscribeHelper::adjustSpaceAdvances):
3339         Make the UniscribeHelper::adjustSpaceAdvances() function treat all characters in
3340         the treatAsSpace() function (e.g. U+0020, U+000A, U+000D, U+00A0) as whitespaces,
3341         so does when Chromium renders a simple text.
3342
3343 2009-02-20  Julien Chaffraix  <jchaffraix@webkit.org>
3344
3345         Reviewed by Alexey Proskuryakov.
3346
3347         Bug 23940: Use Document::createElement(const QualifiedName&, bool) when creating a known element inside WebCore
3348
3349         Document::createElement(const QualifiedName&, bool) does not check for the prefix as opposed the the one taking an AtomicString
3350         or Document::createElementNS. This is perfectly fine internally because we know the type of element created and the check is
3351         unneeded.
3352
3353         It also removes the use of an ExceptionCode argument which was here only to check that the prefix check was fine. Finally it
3354         enables us to use some generated QualifiedName.
3355
3356         * bindings/js/JSOptionConstructor.cpp:
3357         (WebCore::constructHTMLOptionElement):
3358         * dom/Document.cpp:
3359         (WebCore::Document::setTitle):
3360         * dom/XMLTokenizer.cpp:
3361         (WebCore::createXHTMLParserErrorHeader):
3362         (WebCore::XMLTokenizer::insertErrorMessageBlock):
3363         * editing/CompositeEditCommand.cpp:
3364         (WebCore::createBlockPlaceholderElement):
3365         * editing/htmlediting.cpp:
3366         (WebCore::createTabSpanElement):
3367         * html/HTMLSelectElement.cpp:
3368         (WebCore::HTMLSelectElement::setLength):
3369         * loader/FTPDirectoryDocument.cpp:
3370         (WebCore::FTPDirectoryTokenizer::appendEntry):
3371         (WebCore::FTPDirectoryTokenizer::createTDForFilename):
3372         (WebCore::FTPDirectoryTokenizer::loadDocumentTemplate):
3373         (WebCore::FTPDirectoryTokenizer::createBasicDocument):
3374         * loader/ImageDocument.cpp:
3375         (WebCore::ImageDocument::createDocumentStructure):
3376         * loader/MediaDocument.cpp:
3377         (WebCore::MediaTokenizer::createDocumentStructure):
3378         * loader/PluginDocument.cpp:
3379         (WebCore::PluginTokenizer::createDocumentStructure):
3380         * loader/TextDocument.cpp:
3381         (WebCore::TextTokenizer::write):
3382         * page/Frame.cpp:
3383         (WebCore::Frame::selectionComputedStyle):
3384         (WebCore::Frame::styleForSelectionStart):
3385         Document::createElement(const AtomicString&, ...) to Document::createElement(const QualifiedName&, ...) switch.
3386
3387         * xml/XPathFunctions.cpp:
3388         (WebCore::XPath::FunLang::evaluate): Re-use langAttr instead of creating a new attribute.
3389         * page/DragController.cpp:
3390         (WebCore::documentFragmentFromDragData): Use the HTMLAnchorElement directly to get rid of the static cast.
3391
3392 2009-02-19  Dimitri Glazkov  <dglazkov@chromium.org>
3393
3394         Reviewed by Eric Seidel.
3395
3396         https://bugs.webkit.org/show_bug.cgi?id=24060
3397         Fix up to accommodate for CanvasPixelArray return.
3398
3399         * platform/graphics/skia/ImageBufferSkia.cpp:
3400         (WebCore::ImageBuffer::getImageData): Added an extra data() to call.
3401         (WebCore::ImageBuffer::putImageData): Ditto.
3402
3403 2009-02-20  Eric Carlson  <eric.carlson@apple.com>
3404
3405         Simon Fraser
3406
3407         https://bugs.webkit.org/show_bug.cgi?id=24042
3408         Bug 24042: MediaPlayer should cache plug-in proxy
3409
3410         The changes in https://bugs.webkit.org/show_bug.cgi?id=23917 assume that
3411         MediaPlayer will always have created the private media player object before
3412         the plug-in is instantiated and calls back with the proxy object. This is not
3413         true on all platforms because of threading latency, so MediaPlayer should
3414         cache the plug-in proxy so it can pass it to the media engine at a later time.
3415
3416         * platform/graphics/MediaPlayer.cpp:
3417         (WebCore::NullMediaPlayerPrivate::setPoster): Null media engine implementation of proxy methods.
3418         (WebCore::NullMediaPlayerPrivate::deliverNotification): Ditto.
3419         (WebCore::NullMediaPlayerPrivate::setMediaPlayerProxy): Ditto.
3420         (WebCore::MediaPlayer::MediaPlayer): Initialize m_playerProxy.
3421         (WebCore::MediaPlayer::load): Pass m_playerProxy to newly created engine.
3422         (WebCore::MediaPlayer::setMediaPlayerProxy): Cache m_playerProxy.
3423         * platform/graphics/MediaPlayer.h: Declare m_playerProxy.
3424
3425 2009-02-20  Eric Carlson  <eric.carlson@apple.com>
3426
3427         Simon Fraser.
3428
3429         https://bugs.webkit.org/show_bug.cgi?id=24063
3430         Make it possible for a port to require a user gesture to play/pause an <audio> or <video> element
3431
3432         * html/HTMLMediaElement.cpp:
3433         (WebCore::HTMLMediaElement::HTMLMediaElement):  Rename m_loadRestrictions to m_Restrictions.
3434         Initialize m_internalCall.
3435         (WebCore::HTMLMediaElement::loadTimerFired): Increment m_internalCall around call to load().
3436         (WebCore::HTMLMediaElement::load): Call loadInternal if restrictions check out.
3437         (WebCore::HTMLMediaElement::loadInternal): New, guts of old load()
3438         (WebCore::HTMLMediaElement::setNetworkState): Fix bug introduced in r40943
3439         (WebCore::HTMLMediaElement::play): Call playInternal if restrictions check out.
3440         (WebCore::HTMLMediaElement::playInternal): New, guts of old play()
3441         (WebCore::HTMLMediaElement::pause): Call pauseInternal if restrictions check out.
3442         (WebCore::HTMLMediaElement::pauseInternal): New, guts of old pause()
3443         (WebCore::HTMLMediaElement::togglePlayState): Call playInternal/pauseInternal
3444         (WebCore::HTMLMediaElement::deliverNotification): Remove unnecessary white space.
3445         * html/HTMLMediaElement.h: Rename m_loadRestrictions to m_Restrictions, add m_internalCall,
3446         add RequireUserGestureRateChangeRestriction.
3447
3448 2009-02-20  Darin Fisher  <darin@chromium.org>
3449
3450         Fix build bustage in FileSystemWin.cpp.
3451
3452         Need to return CString() instead of 0 since there are now two CString
3453         constructors that take a pointer type.
3454
3455         * platform/win/FileSystemWin.cpp:
3456         (WebCore::openTemporaryFile):
3457
3458 2009-02-20  Dimitri Glazkov  <dglazkov@chromium.org>
3459
3460         Reviewed by Sam Weinig.
3461
3462         https://bugs.webkit.org/show_bug.cgi?id=23999
3463         Change license headers to accurately reflect code history.
3464
3465         * platform/ContentType.cpp:
3466         * platform/ContentType.h:
3467
3468 2009-02-18  Dimitri Glazkov  <dglazkov@chromium.org>
3469
3470         Reviewed by Antti Koivisto.
3471
3472         https://bugs.webkit.org/show_bug.cgi?id=23999
3473         Split off MIME type parsing into its own class.
3474
3475         * GNUmakefile.am: Added ContentType sources.
3476         * WebCore.pro: Ditto.
3477         * WebCore.scons: Ditto.
3478         * WebCore.vcproj/WebCore.vcproj: Ditto.
3479         * WebCore.xcodeproj/project.pbxproj: Ditto.
3480         * WebCoreSources.bkl: Ditto.
3481         * html/HTMLMediaElement.cpp: Changed to use ContentType.
3482         (WebCore::HTMLMediaElement::selectMediaURL):
3483         * platform/ContentType.cpp: Added.
3484         (WebCore::ContentType::ContentType):
3485         (WebCore::ContentType::parameter):
3486         (WebCore::ContentType::type):
3487         * platform/ContentType.h: Added.
3488         (WebCore::ContentType::raw):
3489         * platform/MIMETypeRegistry.cpp:
3490         * platform/MIMETypeRegistry.h:
3491         * platform/graphics/MediaPlayer.cpp:
3492         (WebCore::MediaPlayer::load):
3493         * rendering/style/ContentData.h: Renamed ContentType to StyleContentType.
3494         * rendering/style/RenderStyleConstants.h: Ditto.
3495         (WebCore::):
3496
3497 2009-02-20  Holger Hans Peter Freyther  <zecke@selfish.org>
3498
3499         Unreviewed build fix.
3500
3501         Use CString() instead of 0.
3502
3503         * platform/gtk/FileSystemGtk.cpp:
3504         (WebCore::openTemporaryFile):
3505         * platform/qt/FileSystemQt.cpp:
3506         (WebCore::openTemporaryFile):
3507
3508 2009-02-20  Gustavo Noronha Silva  <gns@gnome.org>
3509
3510         Reviewed by Holger Freyther.
3511
3512         When dealing with local files, use a path instead of an URI. GFile
3513         has problems decoding URIs with percent signs on them.
3514
3515         * platform/network/soup/ResourceHandleSoup.cpp:
3516         (WebCore::ResourceHandle::startGio):
3517
3518 2009-02-20  Gustavo Noronha Silva  <gns@gnome.org>
3519
3520         Reviewed by Holger Freyther.
3521
3522         Protect the ResourceHandle instance from being destroyed by
3523         didReceiveData inside the GIO readCallback call, so that
3524         cancelling caused by scripts is handled correctly.
3525
3526         * platform/network/soup/ResourceHandleSoup.cpp:
3527         (WebCore::readCallback):
3528
3529 2009-02-20  David Kilzer  <ddkilzer@apple.com>
3530
3531         Make IconDatabaseNone.cpp compile with -Wunused and pass check-for-exit-time-destructors
3532
3533         Reviewed by Sam Weinig.
3534
3535         * loader/icon/IconDatabaseNone.cpp:
3536         (WebCore::IconDatabase::defaultDatabaseFilename): Use DEFINE_STATIC_LOCAL().
3537         (WebCore::IconDatabase::open): Commented out unused parameter.
3538         (WebCore::IconDatabase::setPrivateBrowsingEnabled): Ditto.
3539         (WebCore::IconDatabase::iconForPageURL): Ditto.
3540         (WebCore::IconDatabase::iconURLForPageURL): Ditto.
3541         (WebCore::IconDatabase::defaultIcon): Ditto.
3542         (WebCore::IconDatabase::retainIconForPageURL): Ditto.
3543         (WebCore::IconDatabase::releaseIconForPageURL): Ditto.
3544         (WebCore::IconDatabase::setIconDataForIconURL): Ditto.
3545         (WebCore::IconDatabase::setIconURLForPageURL): Ditto.
3546         (WebCore::IconDatabase::setEnabled): Ditto.
3547         (WebCore::IconDatabase::pageURLMappingCount): Added stub.
3548         (WebCore::IconDatabase::retainedPageURLCount): Ditto.
3549         (WebCore::IconDatabase::iconRecordCount): Ditto.
3550         (WebCore::IconDatabase::iconRecordCountWithData): Ditto.
3551
3552 2009-02-20  David Kilzer  <ddkilzer@apple.com>
3553
3554         Add comment to generated code when shadowing a built-in object
3555
3556         Reviewed by Sam Weinig.
3557
3558         * bindings/scripts/CodeGeneratorJS.pm: Added comment to
3559         generated code output.
3560
3561 2009-02-20  Avi Drissman  <avi@chromium.org>
3562
3563         Reviewed by Eric Seidel.
3564
3565         https://bugs.webkit.org/show_bug.cgi?id=24036
3566         Keyboard events need disambiguation on the Linux platform too.
3567
3568         * platform/chromium/PlatformKeyboardEventChromium.cpp:
3569         (WebCore::PlatformKeyboardEvent::disambiguateKeyDownEvent):
3570
3571 2009-02-19  Darin Fisher  <darin@chromium.org>
3572
3573         Reviewed by Eric Seidel.
3574
3575         https://bugs.webkit.org/show_bug.cgi?id=24046
3576
3577         Several improvements to CString:
3578         1- Make it possible to initialize a CString from a CStringBuffer
3579         2- Make it possible to get a CStringBuffer from a CString
3580         3- Change CStringBuffer::data() to return a const pointer to ward off mutation
3581         4- Remove unused releaseBuffer() methods.
3582         5- Make CStringBuffer::create() private to force consumers to get a CStringBuffer from a CString.
3583
3584         * platform/text/CString.cpp:
3585         (WebCore::CString::init):
3586         (WebCore::CString::mutableData):
3587         (WebCore::CString::newUninitialized):
3588         (WebCore::CString::copyBufferIfNeeded):
3589         * platform/text/CString.h:
3590         (WebCore::CStringBuffer::data):
3591         (WebCore::CStringBuffer::length):
3592         (WebCore::CStringBuffer::create):
3593         (WebCore::CStringBuffer::mutableData):
3594         (WebCore::CString::CString):
3595         (WebCore::CString::buffer):
3596
3597 2009-02-19  Dmitry Titov  <dimich@chromium.org>
3598
3599         Reviewed by Alexey Proskuryakov.
3600
3601         https://bugs.webkit.org/show_bug.cgi?id=24017
3602         Remove some usage of Document in Worker.
3603
3604         * dom/WorkerContext.h:
3605         (WebCore::WorkerContext::userAgent):
3606         * dom/Document.cpp:
3607         (WebCore::Document::userAgent):
3608         * dom/Document.h:
3609         * dom/ScriptExecutionContext.h:
3610         Added virtual ScriptExecutionContext::userAgent(const KURL&).