2009-12-07 Kent Tamura <tkent@chromium.org>
[WebKit-https.git] / WebCore / ChangeLog
1 2009-12-07  Kent Tamura  <tkent@chromium.org>
2
3         Reviewed by Darin Adler.
4
5         Fix a bug that KURL rejects a host name which has an IPv4 address
6         inside an IPv6 form like [::127.0.0.1].
7         https://bugs.webkit.org/show_bug.cgi?id=29913
8
9         * platform/KURL.cpp:
10         (WebCore::characterClassTable): Add IPv6Char to '.'.
11
12 2009-12-07  Brady Eidson  <beidson@apple.com>
13
14         Reviewed by Sam Weinig.
15
16         <rdar://problem/7443417> - Closing a window opened with "New windows open with: Same Page" results in crash in ::~HistoryItem
17
18         The HistoryItem copy constructor has one very specific use case - to support the feature of a WebView copying another WebView's
19         BackForwardList.  That constructor wasn't initializing its m_document pointer, leading to this crash in the destructor.
20
21         * history/HistoryItem.cpp:
22         (WebCore::HistoryItem::~HistoryItem): Change the setDocument(0) to an ASSERT that the document is already 0. A HistoryItem cannot
23           outlive its Document and Documents will always clear the back-pointer in their ::detach() method.
24         (WebCore::HistoryItem::HistoryItem): Missed the m_document initializer in the copy constructor. Also remove an invalid assertion
25           about the original items m_cachedPage object (which is irrelevant to the copy).
26
27 2009-12-07  Dmitry Titov  <dimich@chromium.org>
28
29         Reviewed by Darin Adler.
30
31         Remove partial SharedScript implementation.
32         https://bugs.webkit.org/show_bug.cgi?id=32237
33         The patch was obtained by running "git revert" command and then un-reverting WebCore/ChangeLog.
34
35         * DerivedSources.make:
36         * SharedScript/SharedScriptContext.cpp: Removed.
37         * SharedScript/SharedScriptContext.h: Removed.
38         * SharedScript/SharedScriptContext.idl: Removed.
39         * SharedScript/SharedScriptController.h: Removed.
40         * SharedScript/WebKitSharedScript.cpp: Removed.
41         * SharedScript/WebKitSharedScript.h: Removed.
42         * SharedScript/WebKitSharedScript.idl: Removed.
43         * SharedScript/WebKitSharedScriptRepository.cpp: Removed.
44         * SharedScript/WebKitSharedScriptRepository.h: Removed.
45         * WebCore.vcproj/WebCore.vcproj:
46         * WebCore.xcodeproj/project.pbxproj:
47         * dom/Document.cpp:
48         (WebCore::Document::detach):
49         * dom/EventTarget.cpp:
50         * dom/EventTarget.h:
51         * dom/ScriptExecutionContext.h:
52
53 2009-12-07  Alexey Proskuryakov  <ap@apple.com>
54
55         Reviewed by Nikolas Zimmermann.
56
57         https://bugs.webkit.org/show_bug.cgi?id=32226
58         Random crashes in WebSocket tests on Leopard Debug builbot
59
60         * platform/network/SocketStreamHandleBase.cpp: (WebCore::SocketStreamHandleBase::close):
61         Make sure the object still exists when setting m_state.
62
63 2009-12-07  Shiki Okasaka  <shiki@google.com>
64
65         Reviewed by Dirk Schulze.
66
67         Avoid zero division during SVGPaintServerPattern::setup()
68         https://bugs.webkit.org/show_bug.cgi?id=29912
69
70         Fix zero division bugs in SVGPaintServerPattern::setup() that occurred
71         if the tile of a pattern was bigger than the pattern and the pattern
72         size was < 0.5, and if the attribute overflow was set to visible.
73
74         Test: svg/custom/small-pattern.html
75
76         * svg/graphics/SVGPaintServerPattern.cpp:
77         (WebCore::SVGPaintServerPattern::setup):
78
79 2009-12-07  Kenneth Russell  <kbr@google.com>
80
81         Reviewed by Dimitri Glazkov.
82
83         [v8] WebCore::WebGLArrayBufferInternal::byteLengthAttrGetter NULL pointer
84         https://bugs.webkit.org/show_bug.cgi?id=31889
85
86         Fixed bug in handling of zero-argument constructor call.
87
88         Test: fast/canvas/webgl/bug-31889.html
89
90         * bindings/v8/custom/V8WebGLArrayBufferCustom.cpp:
91         (WebCore::CALLBACK_FUNC_DECL):
92
93 2009-12-07  Gyuyoung Kim  <gyuyoung@gmail.com>
94
95         Reviewed by Eric Seidel.
96
97         https://bugs.webkit.org/show_bug.cgi?id=32024
98         [GTK] WebKit does not compile without JAVASCRIPT_DEBUGGER
99
100         Fix build errors when javascript-debugger is disabled on GTK
101
102         * GNUmakefile.am:
103
104 2009-12-07  Dan Bernstein  <mitz@apple.com>
105
106         Reviewed by Darin Adler.
107
108         Fixed <rdar://problem/7437820> Weird selection artifacts
109
110         Tests: fast/repaint/block-selection-gap-stale-cache-2.html
111                fast/repaint/block-selection-gap-stale-cache.html
112
113         Instead of caching the block selection gaps’ bounds in the RenderView at setSelection()
114         time, cache them in each RenderLayer at paint time. This prevents the cache from getting
115         stale due to layout changes and overflow scrolling.
116
117         * rendering/RenderBlock.cpp:
118         (WebCore::RenderBlock::selectionGapRectsForRepaint): Account for overflow scroll.
119         (WebCore::RenderBlock::paintSelection): Update the enclosing layer’s selection gaps bounds.
120         * rendering/RenderLayer.cpp:
121         (WebCore::RenderLayer::addBlockSelectionGapsBounds): Added. Updates the selection gaps
122         bounds to include the given rect.
123         (WebCore::RenderLayer::clearBlockSelectionGapsBounds): Added. Recursively clears the cached
124         selection gaps bounds.
125         (WebCore::RenderLayer::repaintBlockSelectionGaps): Added. Recursively invalidates the
126         selection gaps bounds.
127         * rendering/RenderLayer.h:
128         * rendering/RenderView.cpp:
129         (WebCore::RenderView::setSelection): Clear the layer-level selection gaps bounds instead
130         of the view-level cache.
131         (WebCore::RenderView::clearSelection): Changed to call repaintBlockSelectionGaps().
132         * rendering/RenderView.h:
133
134 2009-12-07  Philippe Normand  <pnormand@igalia.com>
135
136         Reviewed by Gustavo Noronha.
137
138         Fixed whitelist comment and removed useless (tags, sdp) mimetypes
139         from it. Also, GStreamer doesn't handle directly SMIL.
140
141         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
142         (WebCore::mimeTypeCache):
143
144 2009-12-07  Joanmarie Diggs  <joanmarie.diggs@gmail.com>
145
146         Reviewed by Xan Lopez.
147
148         https://bugs.webkit.org/show_bug.cgi?id=25415
149         [GTK][ATK] Please implement support for get_text_at_offset
150
151         Eliminate the segfaults which occur when accessing the text interface now
152         implemented by text controls.
153
154         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
155         (getPangoLayoutForAtk):
156
157 2009-12-07  Gustavo Noronha Silva  <gns@gnome.org>
158
159         Reviewed by Xan Lopez.
160
161         Turn the MediaPlayer supported types blacklist into a whitelist
162
163         [GTK] REGRESSION: webkit thinks it can render PDFs
164         https://bugs.webkit.org/show_bug.cgi?id=32183
165
166         Covered by API test.
167
168         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
169         (WebCore::mimeTypeCache):
170
171 2009-12-07  Joanmarie Diggs  <joanmarie.diggs@gmail.com>
172
173         Reviewed by Xan Lopez.
174
175         https://bugs.webkit.org/show_bug.cgi?id=25524
176         [Gtk] Expose the title attribute to assistive technologies
177
178         Expose 'alt' attribute from images as accessible name.
179         Expose the 'title' core HTML attribute as accessible description.
180         This is a modified version of the original fix submitted by Mario Sanchez Prada,
181         adjusted so that it doesn't impact other platforms.
182
183         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
184         (webkit_accessible_get_name):
185         (webkit_accessible_get_description):
186
187 2009-12-07  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
188
189         Reviewed by Simon Hausmann.
190
191         [Qt] Fix support for generic font families
192
193         By not propagating the resolved font family in FontCacheQt and
194         only concidering the font description we ended up passing the
195         generic font families to Qt directly. Since most systems don't
196         have a mapping for these font families we ended up using the
197         default font in most cases.
198
199         * platform/graphics/qt/FontCacheQt.cpp:
200         * platform/graphics/qt/FontPlatformData.h:
201         * platform/graphics/qt/FontPlatformDataQt.cpp:
202
203 2009-12-06  Oliver Hunt  <oliver@apple.com>
204
205         Reviewed by Maciej Stachowiak.
206
207         Object.getOwnPropertyDescriptor() allows cross-frame access
208         https://bugs.webkit.org/show_bug.cgi?id=32119
209
210         Make all implementations of getOwnPropertyDescriptor that have
211         cross domain restrictions simply fail immediately on cross domain
212         access, rather than trying to mimic the behaviour of normal
213         property access.
214
215         Test: http/tests/security/cross-frame-access-getOwnPropertyDescriptor.html
216
217         * bindings/js/JSDOMWindowCustom.cpp:
218         (WebCore::JSDOMWindow::getOwnPropertyDescriptor):
219         * bindings/js/JSHistoryCustom.cpp:
220         (WebCore::JSHistory::getOwnPropertyDescriptorDelegate):
221         * bindings/js/JSLocationCustom.cpp:
222         (WebCore::JSLocation::getOwnPropertyDescriptorDelegate):
223         * bindings/scripts/CodeGeneratorJS.pm:
224
225 2009-12-07  Steve Block  <steveblock@google.com>
226
227         Reviewed by Adam Barth.
228
229         Moves JSC-specific functions from jni_utility and moves them to new jsc/jni_utility_private files.
230         https://bugs.webkit.org/show_bug.cgi?id=32157
231
232         Build fix only, no new tests.
233
234         * WebCore.xcodeproj/project.pbxproj: Modified. Add jni_utility_private.[cpp|h].
235         * bridge/jni/jni_instance.cpp: Modified. Include jni_utility_private.h for JSC.
236         * bridge/jni/jni_jsobject.mm: Modified. Include jni_utility_private.h for JSC.
237         * bridge/jni/jni_objc.mm: Modified. Include jni_utility_private.h for JSC.
238         * bridge/jni/jni_runtime.cpp: Modified. Include jni_utility_private.h for JSC.
239         * bridge/jni/jni_utility.cpp: Modified. Removed convertValueToJValue and convertArrayInstanceToJavaArray.
240         * bridge/jni/jni_utility.h: Modified. Removed convertValueToJValue and dispatchJNICall.
241         * bridge/jni/jsc: Added.
242         * bridge/jni/jsc/jni_utility_private.cpp: Added.
243         (JSC::Bindings::convertArrayInstanceToJavaArray):
244         (JSC::Bindings::convertValueToJValue):
245         * bridge/jni/jsc/jni_utility_private.h: Added. Header for convertValueToJValue and dispatchJNICall.
246         * platform/android/TemporaryLinkStubs.cpp: Modified. Include jni_utility_private.h for JSC.
247
248 2009-12-06  Oliver Hunt  <oliver@apple.com>
249
250         Reviewed by Maciej Stachowiak.
251
252         texImage2D pixel junk for transparency
253         https://bugs.webkit.org/show_bug.cgi?id=32188
254
255         Use kCGBlendModeCopy when drawing an image to the intermediate context
256         used to create a GL texture.
257
258         No test as we don't currently have any mechanism to retrieve pixel data
259         from the webgl context.
260
261         * platform/graphics/mac/GraphicsContext3DMac.cpp:
262         (WebCore::imageToTexture):
263
264 2009-12-03  Philippe Normand  <pnormand@igalia.com>
265
266         Reviewed by Gustavo Noronha.
267
268         Advertize audio/ogg correctly and refactored mime-type cache
269         building.
270
271         [GTK] Recognize oga as audio/ogg
272         https://bugs.webkit.org/show_bug.cgi?id=31990
273
274         Test: media/media-can-play-ogg.html
275
276         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
277         (WebCore::mimeTypeCache):
278
279 2009-12-05  Alexey Proskuryakov  <ap@apple.com>
280
281         Reviewed by Eric Seidel.
282
283         https://bugs.webkit.org/show_bug.cgi?id=32175
284         REGRESSION: websocket/tests/url-parsing.html is crashing on Leopard Bot
285
286         * platform/network/cf/SocketStreamHandleCFNet.cpp:
287         (WebCore::SocketStreamHandle::readStreamCallback): Call platformClose() to unschedule both
288         streams, guaranteeing that there will be no callbacks after SocketStreamHandle is destroyed.
289         (WebCore::SocketStreamHandle::writeStreamCallback): Edited a comment a bit.
290
291 2009-12-05  Adam Langley  <agl@google.com>
292
293         Reviewed by Adam Barth.
294
295         Check that a CSS format() argument is of a valid type.
296
297         https://bugs.webkit.org/show_bug.cgi?id=31815
298         http://code.google.com/p/chromium/issues/detail?id=28582
299
300         Test: fast/css/url-format-non-string.html
301
302         * css/CSSParser.cpp:
303         (WebCore::CSSParser::parseFontFaceSrc):
304
305 2009-12-04  Adam Langley  <agl@google.com>
306
307         Reviewed by Eric Seidel.
308
309         Chromium: make rounded borders heavier.
310
311         Skia draws its rounded corners differently from the other ports.
312         Whereas they have anti-aliased clipping regions, Skia only has 1-bit
313         regions. (Which is technically more correct, but somewhat unhelpful
314         for us.) Instead, with Skia we use a layer and collect all the
315         clipping paths in effect. When the state is popped, we paint
316         transparency outside the clipping paths and merge the layer down.
317
318         This appears to cause rounded borders to look a little thin, which is
319         addressed in this patch.
320
321         This is well covered by existing tests but will require new baselines
322         in the Chromium tree.
323
324         https://bugs.webkit.org/show_bug.cgi?id=31778
325
326         * platform/graphics/skia/GraphicsContextSkia.cpp:
327         (WebCore::GraphicsContext::addInnerRoundedRectClip):
328
329 2009-12-04  Simon Fraser  <simon.fraser@apple.com>
330
331         Reviewed by Dan Bernstein.
332
333         <rdar://problem/7441571> Hardware-backed layers are skipped when printing
334         
335         When printing, set the PaintBehaviorFlattenCompositingLayers flag so that compositing layers
336         paint. This also causes 3D transforms to be flattened to 2D.
337
338         Test: printing/compositing-layer-printing.html
339
340         * page/FrameView.cpp:
341         (WebCore::FrameView::paintContents):
342
343 2009-12-04  Oliver Hunt  <oliver@apple.com>
344
345         Reviewed by Beth Dakin.
346
347         Fix up some issues in my SVGListTraits change from yesterday.
348
349         * svg/SVGListTraits.h:
350         (WebCore::):
351
352 2009-12-04  Albert J. Wong  <ajwong@chromium.org>
353
354         Not reviewed: chromium build fix.
355
356         Fix Chromium build break caused by moving of isDefaultPortForProtocol() and
357         portAllowed() into KURL.h/KURL.cpp.  Cloning code.
358
359         * platform/KURLGoogle.cpp:
360         (WebCore::isDefaultPortForProtocol):
361         (WebCore::portAllowed):
362
363 2009-12-04  Pavel Feldman  <pfeldman@chromium.org>
364
365         Reviewed by Timothy Hatcher.
366
367         Web Inspector: Remove suppress highlight when restoring selected node.
368
369         https://bugs.webkit.org/show_bug.cgi?id=32152
370
371         * inspector/front-end/ElementsPanel.js:
372         (WebInspector.ElementsPanel.prototype.setDocument.selectNode):
373         (WebInspector.ElementsPanel.prototype.setDocument.selectLastSelectedNode):
374         (WebInspector.ElementsPanel.prototype.setDocument):
375
376 2009-12-04  Dirk Schulze  <krit@webkit.org>
377
378         Reviewed by Nikolas Zimmermann.
379
380         Gradient SVG animation demonstrates tearing at animation extremes
381         https://bugs.webkit.org/show_bug.cgi?id=11929
382
383         The focalPoint of a radial gradient is temporarly substracted by
384         the centralPoint, if the focalPoint is not in the radius of the
385         gradient. This is needed to calculate a new postion of the focalPoint
386         according to the specification. But the new focalPoint needs to be
387         moved by the centralPoint after this calculation, which is not the case
388         at the moment. This patch fixes this issue. It was also introduced a
389         deviation of maximal 0.2% for Cairo to get around the fixed point numbers
390         in Cairo.
391
392         W3C-SVG-1.1/pservers-grad-13-b needed an update. The missing adjustment
393         of the new focalPoint caused wrong results for the last three tests.
394
395         Test: svg/custom/radial-gradient-with-outstanding-focalPoint.svg
396
397         * svg/SVGRadialGradientElement.cpp:
398         (WebCore::SVGRadialGradientElement::buildGradient):
399
400 2009-12-04  Anton Muhin  <antonm@chromium.org>
401
402         Reviewed by Dmitry Titov.
403
404         Do not use WebCore::String::String(const UChar*, int length) to convert
405         short v8 strings.
406
407         Plus added string traits.
408         https://bugs.webkit.org/show_bug.cgi?id=31415
409
410         * bindings/v8/V8Binding.cpp:
411         (WebCore::):
412         (WebCore::v8StringToWebCoreString):
413
414 2009-12-04  Chris Fleizach  <cfleizach@apple.com>
415
416         Reviewed by Darin Adler.
417
418         REGRESSION: AX: buttons now extremely repetitive
419         https://bugs.webkit.org/show_bug.cgi?id=32164
420
421         Test: platform/mac/accessibility/button-shouldnot-have-axvalue.html
422
423         * accessibility/AccessibilityObject.h:
424         (WebCore::AccessibilityObject::isButton):
425         * accessibility/mac/AccessibilityObjectWrapper.mm:
426         (-[AccessibilityObjectWrapper accessibilityAttributeNames]):
427
428 2009-12-04  Zoltan Herczeg  <zherczeg@inf.u-szeged.hu>
429
430         Reviewed by Darin Adler.
431
432         Check whether the right side of a string append is non-empty
433         https://bugs.webkit.org/show_bug.cgi?id=32151
434
435         Especially beneficial for CachedScript::script() method
436         which usually appends an empty string returned by flush()
437         to its m_script member. m_script is often hundreds of kbytes
438         which is duplated without reason.
439
440         * platform/text/String.cpp:
441         (WebCore::String::append):
442
443 2009-12-04  Enrica Casucci  <enrica@apple.com>
444
445         Reviewed by John Sullivan.
446
447         Mail.app crashes when indenting table pasted from Numbers.app.
448         <rdar://problem/7209507>
449         https://bugs.webkit.org/show_bug.cgi?id=32166
450
451         Test: LayoutTests/editing/execCommand/indent-partial-table.html
452         
453         * editing/IndentOutdentCommand.cpp:
454         (WebCore::IndentOutdentCommand::indentRegion): Added test to verify that the end of the paragraph
455         after the selection has not been moved.
456
457 2009-12-04  Alexey Proskuryakov  <ap@apple.com>
458
459         Reviewed by Darin Adler.
460
461         https://bugs.webkit.org/show_bug.cgi?id=32085
462         WebSocket should block the same ports that are blocked for resource loading
463
464         Test: websocket/tests/url-parsing.html
465
466         * page/SecurityOrigin.cpp:
467         (WebCore::SecurityOrigin::SecurityOrigin):
468         (WebCore::SecurityOrigin::localURLSchemes):
469         * page/SecurityOrigin.h:
470         Move isDefaultPortForProtocol() to KURL, because that's a better place for it (SecurityOrigin
471         is not even in WebCore/platform directory).
472
473         * html/HTMLAnchorElement.cpp:
474         (WebCore::HTMLAnchorElement::host):
475         (WebCore::HTMLAnchorElement::setHost):
476         (WebCore::HTMLAnchorElement::setPort):
477         Updated for the new location of isDefaultPortForProtocol().
478
479         * platform/KURL.cpp:
480         (WebCore::KURL::protocolIs): In an assertion, compare to "javascript" case-insensitively,
481         since the function doesn't require lower case input.
482         (WebCore::isDefaultPortForProtocol): Moved from SecurityOrigin.
483         (WebCore::portAllowed): Moved from ResourceHandle.
484         * platform/KURL.h:
485
486         * platform/network/ResourceHandle.cpp: (WebCore::ResourceHandle::create): Updated for the
487         new location of portAllowed().
488
489         * websockets/WebSocket.cpp: (WebCore::WebSocket::connect): Per the spec, raise a SECURITY_ERR
490         if trying to connect to a blocked port.
491
492 2009-12-04  Benjamin Poulain  <benjamin.poulain@nokia.com>
493
494         Reviewed by Kenneth Rohde Christiansen.
495
496         [Qt] WebKit crashes when loading certain SVG images
497         https://bugs.webkit.org/show_bug.cgi?id=29443
498
499         Remove FontFallbackListQt and rely on the common FontFallbackList
500         to handle the fonts. FontCache and FontPlatformData have been
501         updated to work with the common FontFallbackList.
502
503         In the previous implementation, FontPlatformDataCacheKey
504         was a clone of FontPlatformData with the hashing
505         capabilities added in order to use it as a key in the cache's
506         hashmap. FontPlatformData has been modified to handle the hashing
507         function directly so the data are not copied twice in memory.
508
509         FontFallbackList::fontDataAt() from FontFallbackListQt was a copy of
510         code from FontCache::getFontData() and FontFallbackList::fontDataAt().
511         The behavior is similar except currFamily->family().length() was
512         not tested and the fallback fonts selector were not used.
513
514         Existing tests cover the change.
515
516         * WebCore.pro:
517         * platform/graphics/qt/FontCacheQt.cpp:
518         (WebCore::FontCache::platformInit):
519         (WebCore::FontCache::getFontDataForCharacters):
520         (WebCore::FontCache::getSimilarFontPlatformData):
521         (WebCore::FontCache::getLastResortFallbackFont):
522         (WebCore::FontCache::getTraitsInFamily):
523         (WebCore::FontCache::createFontPlatformData):
524         * platform/graphics/qt/FontCustomPlatformData.cpp:
525         (WebCore::FontCustomPlatformData::fontPlatformData):
526         * platform/graphics/qt/FontFallbackListQt.cpp:
527         Removed. We now use the implementation from FontFallbackList.cpp
528         * platform/graphics/qt/FontPlatformData.h:
529         Add hashing capabilities to be able to use the data with the FontCache.
530         This was previously done in FontCacheQt.cpp
531         (WebCore::FontPlatformDataPrivate::FontPlatformDataPrivate):
532         (WebCore::FontPlatformData::FontPlatformData):
533         (WebCore::FontPlatformData::isHashTableDeletedValue):
534         (WebCore::FontPlatformData::font):
535         (WebCore::FontPlatformData::size):
536         (WebCore::FontPlatformData::family):
537         (WebCore::FontPlatformData::bold):
538         (WebCore::FontPlatformData::italic):
539         (WebCore::FontPlatformData::smallCaps):
540         (WebCore::FontPlatformData::pixelSize):
541         * platform/graphics/qt/FontPlatformDataQt.cpp:
542         (WebCore::FontPlatformData::FontPlatformData):
543         (WebCore::FontPlatformData::~FontPlatformData):
544         (WebCore::FontPlatformData::operator=):
545         (WebCore::FontPlatformData::operator==):
546         (WebCore::FontPlatformData::hash):
547
548 2009-12-04  Adam Treat  <atreat@rim.com>
549
550         Reviewed by Dan Bernstein.
551
552         Fix wrong assert that was only working through sheer luck.
553         https://bugs.webkit.org/show_bug.cgi?id=32162
554
555         * platform/text/BidiContext.cpp:
556         (WebCore::BidiContext::create):
557
558 2009-12-04  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
559
560         Reviewed by Simon Hausmann.
561
562         [Qt] Allow removing 'qrc' as a local security origin scheme
563
564         * page/SecurityOrigin.cpp:
565
566 2009-12-04  Zoltan Horvath  <zoltan@webkit.org>
567
568         Reviewed by Eric Seidel.
569
570         Allow custom memory allocation control for WebCore's CollectionCache
571         https://bugs.webkit.org/show_bug.cgi?id=32109
572
573         Inherits the following class from FastAllocBase because it is
574         instantiated by 'new':
575
576         struct name            - instantiated at: WebCore/'location'
577
578         struct CollectionCache - dom/Document.cpp:4029
579
580         * html/CollectionCache.h:
581
582 2009-12-04  Steve Block  <steveblock@google.com>
583
584         Reviewed by Darin Adler.
585
586         Fixes a crashing bug in Geolocation when a watch is cleared from some callbacks. 
587         https://bugs.webkit.org/show_bug.cgi?id=32111
588
589         In Geolocation::GeoNotifier::timerFired, a JS callback may be invoked if a
590         fatal error was registered on this GeoNotifier or if this request has timed
591         out. If the request is a watch, and is cleared by a call to clearWatch in the
592         callback, the GeoNotifier object will be destroyed. We must therefore cache the
593         m_geolocation member to allow us to call Geolocation::fatalErrorOccurred or
594         Geolocation::requestTimedOut.
595
596         Tests: fast/dom/Geolocation/permission-denied-already-clear-watch.html
597                fast/dom/Geolocation/timeout-clear-watch.html
598
599         * page/Geolocation.cpp: Modified.
600         (WebCore::Geolocation::GeoNotifier::timerFired): Modified. Cache the m_geolocation member before invoking the JS callback.
601
602 2009-12-04  Zoltan Horvath  <zoltan@webkit.org>
603
604         Reviewed by Eric Seidel.
605
606         Allow custom memory allocation control for 2 classes of the platform directory in WebCore
607         https://bugs.webkit.org/show_bug.cgi?id=
608
609         Inherits the following class from Noncopyable because it is instantiated
610         by 'new' and no need to be copyable:
611
612         class/struct name         - instantiated at: WebCore/'location'
613
614         class SharedTimer         - (its child class) workers/WorkerRunLoop.cpp:91
615
616         Inherits the following class from FastAllocBase because it is
617         instantiated by 'new':
618
619         class TransformOperations - rendering/style/RenderStyle.h:1175
620
621         Noncopyable.h's include added to SharedTimer.h.
622
623         * platform/SharedTimer.h:
624         * platform/graphics/transforms/TransformOperations.h:
625
626 2009-12-04  Xan Lopez  <xlopez@igalia.com>
627
628         Reviewed by Gustavo Noronha.
629
630         [GTK]Enable DNS prefetching
631         https://bugs.webkit.org/show_bug.cgi?id=23846
632
633         Enable DNS prefetching.
634
635         Based on a patch by José Millán.
636
637         * platform/network/soup/DNSSoup.cpp:
638         (WebCore::prefetchDNS):
639
640 2009-12-04  Zoltan Horvath  <zoltan@webkit.org>
641
642         Reviewed by Eric Seidel.
643
644         Allow custom memory allocation control for the svg directory in WebCore
645         https://bugs.webkit.org/show_bug.cgi?id=
646
647         Inherits the following classes from Noncopyable because these are instantiated
648         by 'new' and no need to be copyable:
649
650         class/struct name           - instantiated at: WebCore/'location'
651
652         struct ResourceSet          - svg/graphics/SVGResource.cpp:148
653         class SVGFontData           - css/CSSFontFaceSource.cpp:156
654         class SVGDocumentExtensions - dom/Document.cpp:3962
655         class SVGViewSpec           - svg/SVGSVGElement.cpp:191
656
657         * svg/SVGDocumentExtensions.h:
658         * svg/SVGFontData.h:
659         * svg/SVGViewSpec.h:
660         * svg/graphics/SVGResource.cpp:
661
662 2009-12-03  Chris Fleizach  <cfleizach@apple.com>
663
664         Reviewed by Beth Dakin.
665
666         WAI-ARIA: aria-activedescendant doesn't work as intended
667         https://bugs.webkit.org/show_bug.cgi?id=32100
668
669         Fixes a number of issues regarding the "tree" role and aria-activedescendant.
670         1. The indexes were being reported incorrectly by treeitems.
671         2. aria-activedescendant changes were not being sent to the containing item.
672         3. The tree's selected rows need to consult aria-activedescendant.
673         4. Since a tree changes what it returns as its children (it returns its rows)
674            the mac-specific array indexing methods need to correctly handle the tree case.
675
676         Tests: platform/mac/accessibility/aria-tree-activedescendant.html
677                platform/mac/accessibility/aria-tree-index-of-items.html
678
679         * accessibility/AXObjectCache.h:
680         (WebCore::AXObjectCache::):
681         * accessibility/AccessibilityRenderObject.cpp:
682         (WebCore::AccessibilityRenderObject::shouldFocusActiveDescendant):
683         (WebCore::AccessibilityRenderObject::activeDescendant):
684         (WebCore::AccessibilityRenderObject::handleActiveDescendantChanged):
685         (WebCore::AccessibilityRenderObject::ariaTreeSelectedRows):
686         * accessibility/mac/AXObjectCacheMac.mm:
687         (WebCore::AXObjectCache::postPlatformNotification):
688         * accessibility/mac/AccessibilityObjectWrapper.mm:
689         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
690         (-[AccessibilityObjectWrapper accessibilityIndexOfChild:]):
691         (-[AccessibilityObjectWrapper accessibilityArrayAttributeValues:index:maxCount:]):
692         * accessibility/win/AXObjectCacheWin.cpp:
693         (WebCore::AXObjectCache::postPlatformNotification):
694
695 2009-12-03  Zoltan Horvath  <zoltan@webkit.org>
696
697         Reviewed by Eric Seidel.
698
699         Allow custom memory allocation control for the xml directory in WebCore
700         https://bugs.webkit.org/show_bug.cgi?id=
701
702         Inherits the following class from Noncopyable because it is instantiated 
703         by 'new' and no need to be copyable:
704
705         class/struct name               - instantiated at: WebCore/'location'
706
707         struct XMLHttpRequestStaticData - xml/XMLHttpRequest.cpp:134
708
709         Inherits the following classes from FastAllocBase because these are instantiated by 'new':
710
711         class NodeTest                  - xml/XPathGrammar.y:258
712         class NodeSet                   - xml/XPathValue.cpp:52
713         struct EvaluationContext        - xml/XPathExpressionNode.cpp:40
714
715         * xml/XMLHttpRequest.cpp:
716         * xml/XPathExpressionNode.h:
717         * xml/XPathNodeSet.h:
718         * xml/XPathStep.h:
719
720 2009-12-03  Drew Wilson  <atwilson@chromium.org>
721
722         Reviewed by Adam Barth.
723
724         New History changes do not compile for Chromium/V8
725         https://bugs.webkit.org/show_bug.cgi?id=32148
726
727         Existing tests suffice (just trying to get code to compile).
728
729         * WebCore.gypi:
730         Added V8HistoryCustom.cpp and other missing files.
731         * bindings/v8/custom/V8CustomBinding.h:
732         Added custom handlers for History.pushState()/replaceState().
733         * bindings/v8/custom/V8HistoryCustom.cpp: Added.
734         Added custom handlers for History.pushState()/replaceState().
735         * history/BackForwardListChromium.cpp:
736         (WebCore::BackForwardList::pushStateItem):
737         Stubbed out this routine for now - will implement in the future.
738
739 2009-12-03  Adam Barth  <abarth@webkit.org>
740
741         Reviewed by Eric Seidel.
742
743         OwnPtr<XBLBindingManager> Document::m_bindingManager;
744         https://bugs.webkit.org/show_bug.cgi?id=32147
745
746         The document actually owns the bindingManager.  That's what the code
747         should say.
748
749         * dom/Document.cpp:
750         (WebCore::Document::~Document):
751         * dom/Document.h:
752         (WebCore::Document::bindingManager):
753
754 2009-12-03  Adam Barth  <abarth@webkit.org>
755
756         Reviewed by Eric Seidel.
757
758         OwnPtr<Tokenizer> Document::m_tokenizer;
759         https://bugs.webkit.org/show_bug.cgi?id=32145
760
761         The document actually owns the tokenizer.  That's what the code should say.
762
763         * dom/Document.cpp:
764         (WebCore::Document::removedLastRef):
765         (WebCore::Document::~Document):
766         (WebCore::Document::cancelParsing):
767         (WebCore::Document::implicitOpen):
768         (WebCore::Document::implicitClose):
769         * dom/Document.h:
770         (WebCore::Document::tokenizer):
771
772 2009-12-03  Adam Barth  <abarth@webkit.org>
773
774         Reviewed by Eric Seidel.
775
776         OwnPtr<RenderArena> Document::m_renderArena;
777         https://bugs.webkit.org/show_bug.cgi?id=32146
778
779         The document owns the renderArena.  That's what the code should say.
780
781         * dom/Document.cpp:
782         (WebCore::Document::Document): Also, removed a redundant initialization
783         of the tokenizer that I missed in my previous patch.
784         (WebCore::Document::~Document):
785         (WebCore::Document::attach):
786         (WebCore::Document::detach):
787         * dom/Document.h:
788         (WebCore::Document::renderArena):
789
790 2009-12-03  Drew Wilson  <atwilson@chromium.org>
791
792         Rolling back r51633 because it causes a chromium perf regression.
793
794         * platform/graphics/SimpleFontData.h:
795         * platform/graphics/mac/ComplexTextControllerCoreText.cpp:
796
797 2009-12-03  Adam Barth  <abarth@webkit.org>
798
799         Reviewed by Eric Seidel.
800
801         The code should say that Document owns DocLoader
802         https://bugs.webkit.org/show_bug.cgi?id=32143
803
804         It's the truth.
805
806         * dom/Document.cpp:
807         (WebCore::Document::~Document):
808         * dom/Document.h:
809         (WebCore::Document::docLoader):
810
811 2009-12-03  Chris Fleizach  <cfleizach@apple.com>
812
813         Reviewed by Eric Seidel.
814
815         AX: VO just says "term" on many web sites
816         https://bugs.webkit.org/show_bug.cgi?id=32139
817
818         Test: platform/mac/accessibility/definition-list-term.html
819
820         * accessibility/AccessibilityRenderObject.cpp:
821         (WebCore::AccessibilityRenderObject::accessibilityDescription):
822         * accessibility/mac/AccessibilityObjectWrapper.mm:
823         (-[AccessibilityObjectWrapper subrole]):
824         (-[AccessibilityObjectWrapper roleDescription]):
825
826 2009-12-03  Chris Fleizach  <cfleizach@apple.com>
827
828         Reviewed by Beth Dakin.
829
830         Implement WAI-ARIA scrollbar role and related property aria-orientation
831         https://bugs.webkit.org/show_bug.cgi?id=32126
832
833         Test: accessibility/aria-scrollbar-role.html
834
835         * accessibility/AccessibilityObject.cpp:
836         (WebCore::createARIARoleMap):
837         * accessibility/AccessibilityObject.h:
838         (WebCore::AccessibilityObject::isScrollbar):
839         * accessibility/AccessibilityRenderObject.cpp:
840         (WebCore::AccessibilityRenderObject::valueForRange):
841         (WebCore::AccessibilityRenderObject::orientation):
842         (WebCore::AccessibilityRenderObject::canHaveChildren):
843         * accessibility/AccessibilityRenderObject.h:
844         * accessibility/mac/AccessibilityObjectWrapper.mm:
845         (-[AccessibilityObjectWrapper additionalAccessibilityAttributeNames]):
846         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
847         * html/HTMLAttributeNames.in:
848
849 2009-12-03  Dan Bernstein  <mitz@apple.com>
850
851         Reviewed by Darin Adler.
852
853         Fixed <rdar://problem/7401617> Selection painting issue in hardware-
854         accelerated layers
855         which is another part of https://bugs.webkit.org/show_bug.cgi?id=23628
856         Fix selection painting to do container-relative repaints
857
858         Test: fast/repaint/block-selection-gap-in-composited-layer.html
859
860         * rendering/RenderBlock.cpp:
861         (WebCore::RenderBlock::selectionGapRectsForRepaint): Compute and paint
862         gap rects in the coordinate space of the repaint container.
863         * rendering/RenderLayerCompositor.cpp:
864         (WebCore::RenderLayerCompositor::recursiveRepaintLayerRect): Added a
865         FIXME.
866         * rendering/RenderView.cpp:
867         (WebCore::RenderView::setSelection): Map block selection gap rects from
868         the repaint container’s coordinate space to the view’s coordinate space
869         before adding them to the cached selection bounds.
870         (WebCore::RenderView::clearSelection): Changed to use
871         repaintRectangleInViewAndCompositedLayers() so that the selection rect
872         is invalidated in composited layers as well.
873
874 2009-12-03  Jonathan Dixon  <joth@chromium.org>
875
876         Reviewed by Dimitri Glazkov.
877
878         Bug 32066 - Add enable geolocation flag to WebCore::Settings for Chromium
879         https://bugs.webkit.org/show_bug.cgi?id=32066
880
881         Adds geolocationEnabled in Settings for runtime control of geolocaiton features. This defaults to ON
882         as it is intended as a development and testing aid, not a user control. To completely remove geolocation
883         from a given port, the compile time ENABLE_GEOLOCATION should still be used.
884         Adding placeholder GeolocationServiceChromium implementation, as this is required to allows
885         ENABLE_GEOLOCATION to be defined (in turn required for testing), even though this patch does not
886         make that the default just yet.
887
888         * WebCore.gypi:
889         * page/Settings.cpp:
890         (WebCore::Settings::Settings): Add new m_geolocationEnabled flag default value
891         (WebCore::Settings::setGeolocationEnabled): Setter for  m_geolocationEnabled flag
892         * page/Settings.h:
893         (WebCore::Settings::geolocationEnabled):  Add m_geolocationEnabled flag
894         * platform/chromium/GeolocationServiceChromium.cpp: Added.
895         (WebCore::GeolocationServiceChromium::GeolocationServiceChromium): Place holder GeolocationServiceChromium)
896         (WebCore::createGeolocationService): factory function, only required when ENABLED(GEOLOCATION) is true
897
898 2009-12-03  Enrica Casucci  <enrica@apple.com>
899
900         Reviewed by John Sullivan.
901
902         SpinTracer: 349 spins in Mail at WebCore::Editor::advanceToNextMisspelling(bool)
903         <rdar://problem/7198592>
904         https://bugs.webkit.org/show_bug.cgi?id=32129
905
906         Fixed the way the next paragraph is calculated.
907         I've added a repro case in Safari and attached it to the Bugzilla bug.
908
909         * editing/Editor.cpp:
910         (WebCore::findFirstMisspellingOrBadGrammarInRange): Changed the way we move to the
911         next paragraph in the loop.
912
913 2009-12-03  Oliver Hunt  <oliver@apple.com>
914
915         Build fix
916
917         * svg/SVGListTraits.h:
918         (WebCore::):
919
920 2009-12-03  Oliver Hunt  <oliver@apple.com>
921
922         Build fix
923
924         * svg/SVGListTraits.h:
925         (WebCore::):
926
927 2009-12-03  Brady Eidson  <beidson@apple.com>
928
929         No wonder editing WebCore.exp repeatedly while I worked on this patch never seemed to stick.
930
931         Long live our auto-generated overlords that I didn't know about...  
932
933         * WebCore.base.exp:
934
935 2009-12-03  Oliver Hunt  <oliver@apple.com>
936
937         Reviewed by Dan Bernstein.
938
939         REGRESSION (r51627): 3 SVG tests are failing
940         https://bugs.webkit.org/show_bug.cgi?id=32117
941
942         Null checking Items in the SVGList is insufficient as items may
943         be floats, etc so add SVGListTraits::isNull and add appropriate
944         specializations.
945
946         Test: svg/dom/svglist-exception-on-out-bounds-error.html
947
948         * svg/SVGList.h:
949         (WebCore::SVGListTypeOperations::isNull):
950         (WebCore::SVGList::initialize):
951         (WebCore::SVGList::insertItemBefore):
952         (WebCore::SVGList::replaceItem):
953         (WebCore::SVGList::appendItem):
954         * svg/SVGListTraits.h:
955         (WebCore::):
956
957 2009-12-03  Brady Eidson  <beidson@apple.com>
958
959         No review - release build fix.
960
961         * history/HistoryItem.cpp:
962         (WebCore::HistoryItem::documentDetached):
963
964 2009-12-03  Brady Eidson  <beidson@apple.com>
965
966         No review - release build fix.
967
968         * loader/HistoryController.cpp:
969         (WebCore::HistoryController::pushState):
970
971 2009-12-03  Enrica Casucci  <enrica@apple.com>
972
973         Reviewed by Adele Peterson.
974
975         Multiple Undos removes the last posted comment and/or the ones before it.
976         <rdar://problem/6557066>
977         https://bugs.webkit.org/show_bug.cgi?id=32079
978         
979         The fix consists in preventing Undos and Redos to be applied to elements that
980         are no longer editable. We do not attempt to remove the commands from the queue.
981         It is a relatively simple fix that comes with a little extra overhead for the apply
982         and unapply methods where we are now performing the editability check.
983
984         Test: editing/undo/undo-indent-noneditable.html
985
986         * editing/AppendNodeCommand.cpp:
987         (WebCore::AppendNodeCommand::doApply):
988         (WebCore::AppendNodeCommand::doUnapply):
989         * editing/DeleteFromTextNodeCommand.cpp:
990         (WebCore::DeleteFromTextNodeCommand::doApply):
991         (WebCore::DeleteFromTextNodeCommand::doUnapply):
992         * editing/InsertIntoTextNodeCommand.cpp:
993         (WebCore::InsertIntoTextNodeCommand::doApply):
994         (WebCore::InsertIntoTextNodeCommand::doUnapply):
995         * editing/InsertNodeBeforeCommand.cpp:
996         (WebCore::InsertNodeBeforeCommand::doApply):
997         (WebCore::InsertNodeBeforeCommand::doUnapply):
998         * editing/JoinTextNodesCommand.cpp:
999         (WebCore::JoinTextNodesCommand::doApply):
1000         (WebCore::JoinTextNodesCommand::doUnapply):
1001         * editing/MergeIdenticalElementsCommand.cpp:
1002         (WebCore::MergeIdenticalElementsCommand::doApply):
1003         (WebCore::MergeIdenticalElementsCommand::doUnapply):
1004         * editing/RemoveNodeCommand.cpp:
1005         (WebCore::RemoveNodeCommand::doApply):
1006         (WebCore::RemoveNodeCommand::doUnapply):
1007         * editing/SplitElementCommand.cpp:
1008         (WebCore::SplitElementCommand::executeApply):
1009         (WebCore::SplitElementCommand::doUnapply):
1010         * editing/SplitTextNodeCommand.cpp:
1011         (WebCore::SplitTextNodeCommand::doApply):
1012         (WebCore::SplitTextNodeCommand::doUnapply):
1013         * editing/WrapContentsInDummySpanCommand.cpp:
1014         (WebCore::WrapContentsInDummySpanCommand::doUnapply):
1015         (WebCore::WrapContentsInDummySpanCommand::doReapply):
1016
1017 2009-12-03  Brady Eidson  <beidson@apple.com>
1018
1019         Reviewed by Sam Weinig.
1020
1021         <rdar://problem/7214236> and http://webkit.org/b/32052 - Implement HTML5 state object history API
1022
1023         Tests: fast/loader/stateobjects/document-destroyed-navigate-back.html
1024                fast/loader/stateobjects/document-destroyed-navigate-back-with-fragment-scroll.html
1025                fast/loader/stateobjects/popstate-after-load-complete-addeventlistener.html
1026                fast/loader/stateobjects/popstate-after-load-complete-body-attribute.html
1027                fast/loader/stateobjects/popstate-after-load-complete-window-attribute.html
1028                fast/loader/stateobjects/pushstate-object-types.html
1029                fast/loader/stateobjects/pushstate-then-replacestate.html
1030                fast/loader/stateobjects/pushstate-with-fragment-urls-and-hashchange.html
1031                fast/loader/stateobjects/replacestate-then-pushstate.html
1032                http/tests/loading/state-object-security-exception.html
1033
1034         Derived sources and project file changes:
1035         * DerivedSources.cpp:
1036         * DerivedSources.make:
1037         * GNUmakefile.am
1038         * WebCore.pro
1039         * WebCore.vcproj/WebCore.vcproj:
1040         * WebCore.xcodeproj/project.pbxproj:
1041
1042         Add the new PopStateEvent:
1043         * dom/PopStateEvent.cpp: Added.
1044         (WebCore::PopStateEvent::PopStateEvent):
1045         (WebCore::PopStateEvent::initPopStateEvent):
1046         * dom/PopStateEvent.h: Added.
1047         (WebCore::PopStateEvent::create):
1048         (WebCore::PopStateEvent::isPopStateEvent):
1049         (WebCore::PopStateEvent::state):
1050         * dom/PopStateEvent.idl: Added.
1051         * bindings/js/JSPopStateEventCustom.cpp: Added.
1052         (WebCore::JSPopStateEvent::initPopStateEvent):
1053         (WebCore::JSPopStateEvent::state):
1054         * bindings/js/JSEventCustom.cpp:
1055         (WebCore::toJS):
1056         * dom/Event.cpp:
1057         (WebCore::Event::isPopStateEvent):
1058         * dom/Event.h:
1059         * dom/EventNames.h:
1060
1061         Add the "onpopstate" attribute:
1062         * html/HTMLAttributeNames.in:
1063         * html/HTMLBodyElement.cpp:
1064         (WebCore::HTMLBodyElement::parseMappedAttribute):
1065         * html/HTMLBodyElement.idl:
1066         * html/HTMLFrameSetElement.cpp:
1067         (WebCore::HTMLFrameSetElement::parseMappedAttribute):
1068         * html/HTMLFrameSetElement.h:
1069         * html/HTMLFrameSetElement.idl:
1070         * page/DOMWindow.h:
1071         * page/DOMWindow.idl:
1072
1073         Add pushState and replaceState management to the loader and history machinery:
1074         * bindings/js/JSHistoryCustom.cpp:
1075         (WebCore::JSHistory::pushState):
1076         (WebCore::JSHistory::replaceState):
1077         * loader/HistoryController.cpp:
1078         (WebCore::HistoryController::updateForSameDocumentNavigation): Augmented from "scrollToAnchor()", combining
1079           both the same-document fragment scroll case with the new same-document state object activation case.
1080         (WebCore::HistoryController::pushState):
1081         (WebCore::HistoryController::replaceState):
1082         * loader/HistoryController.h:
1083         * history/BackForwardList.cpp:
1084         (WebCore::BackForwardList::addItem): Use insertItemAfterCurrent.
1085         (WebCore::BackForwardList::insertItemAfterCurrent): Optionally insert the item without clearing the forward
1086           list, as pushStateItem might've selectively cleared only certain items, with the bulk of the forward list
1087           meant to remain.
1088         (WebCore::BackForwardList::pushStateItem): Clear the forward list *only* for the state item's document, then 
1089           insert the new item.
1090         (WebCore::BackForwardList::removeItem):
1091         * history/BackForwardList.h:
1092         * page/History.cpp:
1093         (WebCore::History::urlForState):
1094         (WebCore::History::stateObjectAdded):
1095         * page/History.h:
1096         * page/History.idl:
1097
1098         Let HistoryItems and Documents associate with each other, as well as letting HistoryItems contain state objects:
1099         * history/HistoryItem.cpp:
1100         (WebCore::HistoryItem::HistoryItem):
1101         (WebCore::HistoryItem::~HistoryItem):
1102         (WebCore::HistoryItem::setStateObject):
1103         (WebCore::HistoryItem::setDocument):
1104         (WebCore::HistoryItem::documentDetached):
1105         * history/HistoryItem.h:
1106         (WebCore::HistoryItem::stateObject):
1107         (WebCore::HistoryItem::document):
1108         * dom/Document.cpp:
1109         (WebCore::Document::detach): Notify all back/forward history items owned by this Document that it
1110           is going away.
1111         (WebCore::Document::registerHistoryItem): Manage the list of back/forward history items this document owns.
1112         (WebCore::Document::unregisterHistoryItem): Ditto.
1113         * dom/Document.h:
1114
1115         Add the ability for Documents, DocumentLoaders, and FrameLoaderClients to be notified when a Documents
1116         URL changes as the result of pushState(), replaceState(), or a popstate navigation:
1117         * dom/Document.cpp:
1118         (WebCore::Document::implicitClose): If there's a pending state object, dispatch the popstate event.
1119         (WebCore::Document::updateURLForPushOrReplaceState):
1120         (WebCore::Document::statePopped): If loading is complete, dispatch the popstate event. Otherwise, set 
1121           the pending state object.
1122         * loader/DocumentLoader.cpp:
1123         (WebCore::DocumentLoader::replaceRequestURLForSameDocumentNavigation):
1124         * loader/DocumentLoader.h:
1125         * loader/FrameLoaderClient.h:
1126         * loader/EmptyClients.h:
1127         (WebCore::EmptyFrameLoaderClient::dispatchDidChangeStateObjectForPageForFrame):
1128
1129         Change handling of "loading a HistoryItem" to distinguish between new-Document navigations and same-Document
1130         navigations, combining the old concept of anchor scrolls with the new concept of state object navigations:
1131         * loader/FrameLoader.cpp:
1132         (WebCore::FrameLoader::loadInSameDocument):
1133         (WebCore::FrameLoader::continueFragmentScrollAfterNavigationPolicy):
1134         (WebCore::FrameLoader::navigateWithinDocument):
1135         (WebCore::FrameLoader::navigateToDifferentDocument):
1136         (WebCore::FrameLoader::loadItem):
1137         * loader/FrameLoader.h:
1138         * page/Page.cpp:
1139         (WebCore::Page::goToItem): Changed to allow state object activations to pass through without the load stopping.
1140
1141 2009-12-03  Pavel Feldman  <pfeldman@chromium.org>
1142
1143         Not reviewed: chromium build fix.
1144         r51621 changed JS bindings only, broke v8's.
1145
1146         * bindings/v8/ScriptFunctionCall.cpp:
1147         (WebCore::ScriptFunctionCall::appendArgument):
1148         * bindings/v8/ScriptFunctionCall.h:
1149
1150 2009-12-03  Dimitri Glazkov  <dglazkov@chromium.org>
1151
1152         Reviewed by Adam Barth.
1153
1154         [V8] Attributes and NamedNodeMaps aren't tracked correctly and may be prematurely garbage-collected.
1155         https://bugs.webkit.org/show_bug.cgi?id=32094
1156
1157         Covered by existing test: LayoutTests/fast/dom/Attr/access-after-element-destruction.html
1158
1159         * bindings/v8/DOMObjectsInclude.h:
1160         * bindings/v8/V8DOMWrapper.cpp:
1161         (WebCore::V8DOMWrapper::getTemplate):
1162         (WebCore::V8DOMWrapper::convertToV8Object):
1163         (WebCore::V8DOMWrapper::convertNamedNodeMapToV8Object):
1164         * bindings/v8/V8DOMWrapper.h:
1165         * bindings/v8/V8GCController.cpp:
1166         (WebCore::ObjectGrouperVisitor::visitDOMWrapper):
1167         * bindings/v8/custom/V8CustomBinding.h:
1168
1169 2009-12-03  Pavel Feldman  <pfeldman@chromium.org>
1170
1171         Reviewed by Timothy Hatcher.
1172
1173         Chromium: Add support for settings containing ":"
1174
1175         https://bugs.webkit.org/show_bug.cgi?id=32118
1176
1177         * inspector/front-end/WatchExpressionsSidebarPane.js:
1178         (WebInspector.WatchExpressionsSection):
1179
1180 2009-12-03  Rafael Antognolli  <antognolli@profusion.mobi>, Kenneth Christiansen <kenneth@webkit.org>
1181
1182         Reviewed by Simon Fraser.
1183
1184         repaint events from outside the viewport aren't received
1185         https://bugs.webkit.org/show_bug.cgi?id=32081
1186
1187         When using a tiled backing store for painting, you need to receive
1188         event from outside the viewport. Setting the viewport to the size
1189         of the contents is not an option if you want to make use of WebCore's
1190         infrastructure for drawing scrollbars etc.
1191
1192         A new property, paintsEntireContents, has been introduced for the
1193         above use-case. It is settable, as tiling will be optional for Qt,
1194         and for the not yet upstreamed EFL port, there will be two different
1195         views, where only one of them are tiled.
1196
1197         No change in behavior, so no new tests added.
1198
1199         * page/FrameView.cpp:
1200         (WebCore::FrameView::repaintContentRectangle):
1201         * platform/ScrollView.cpp:
1202         (WebCore::ScrollView::ScrollView):
1203         (WebCore::ScrollView::setPaintsEntireContents):
1204         (WebCore::ScrollView::wheelEvent):
1205         * platform/ScrollView.h:
1206         (WebCore::ScrollView::paintsEntireContents):
1207
1208 2009-11-23  Jeremy Moskovich  <jeremy@chromium.org>
1209
1210         Reviewed by Eric Seidel.
1211
1212         Switch Chrome/Mac to use Core Text APIs rather than ATSUI APIs.
1213         https://bugs.webkit.org/show_bug.cgi?id=31802
1214
1215         No test since this is already covered by existing pixel tests.
1216
1217         * platform/graphics/SimpleFontData.h: Change #ifdef to define getNSFont() on Chrome/Mac .
1218         * platform/graphics/mac/ComplexTextControllerCoreText.cpp: Provide forward declarations
1219         of Core Text functions that are public on 10.6 but SPI on 10.5.
1220
1221 2009-12-03  Pavel Feldman  <pfeldman@dhcp-172-28-174-220.spb.corp.google.com>
1222
1223         Reviewed by Timothy Hatcher.
1224
1225         Web Inspector: Simplify the settings support in inspector controller.
1226
1227         https://bugs.webkit.org/show_bug.cgi?id=32076
1228
1229         Test: inspector/settings-set-get.html
1230
1231         * WebCore.Inspector.exp:
1232         * bindings/js/JSInspectorFrontendHostCustom.cpp:
1233         * bindings/v8/custom/V8InspectorFrontendHostCustom.cpp:
1234         * inspector/InspectorClient.h:
1235         * inspector/InspectorController.cpp:
1236         (WebCore::InspectorController::~InspectorController):
1237         (WebCore::InspectorController::setting):
1238         (WebCore::InspectorController::setSetting):
1239         (WebCore::InspectorController::setWindowVisible):
1240         (WebCore::InspectorController::attachWindow):
1241         (WebCore::InspectorController::setAttachedWindowHeight):
1242         (WebCore::InspectorController::storeLastActivePanel):
1243         (WebCore::InspectorController::scriptObjectReady):
1244         (WebCore::InspectorController::showWindow):
1245         (WebCore::InspectorController::enableResourceTracking):
1246         (WebCore::InspectorController::disableResourceTracking):
1247         (WebCore::InspectorController::ensureResourceTrackingSettingsLoaded):
1248         (WebCore::InspectorController::enableProfiler):
1249         (WebCore::InspectorController::disableProfiler):
1250         (WebCore::InspectorController::enableDebuggerFromFrontend):
1251         (WebCore::InspectorController::disableDebugger):
1252         * inspector/InspectorController.h:
1253         * inspector/InspectorFrontendHost.cpp:
1254         (WebCore::InspectorFrontendHost::setting):
1255         (WebCore::InspectorFrontendHost::setSetting):
1256         * inspector/InspectorFrontendHost.h:
1257         * inspector/InspectorFrontendHost.idl:
1258         * loader/EmptyClients.h:
1259         (WebCore::EmptyInspectorClient::populateSetting):
1260         (WebCore::EmptyInspectorClient::storeSetting):
1261
1262 2009-12-03  Ben Murdoch  <benm@google.com>
1263
1264         Reviewed by Brady Eidson.
1265
1266         [Android] notifyHistoryItemChanged() should pass a pointer to the HistoryItem that changed.
1267         https://bugs.webkit.org/show_bug.cgi?id=31915
1268
1269         No change in functionality so no new tests required.
1270
1271         * history/HistoryItem.cpp:
1272         (WebCore::defaultNotifyHistoryItemChanged): Update this function to pass the HistoryItem that is being changed.
1273         (WebCore::HistoryItem::setAlternateTitle): Update call to notifyHistoryItemChanged to include the new parameter.
1274         (WebCore::HistoryItem::setURLString): ditto.
1275         (WebCore::HistoryItem::setOriginalURLString): ditto.
1276         (WebCore::HistoryItem::setReferrer): ditto.
1277         (WebCore::HistoryItem::setTitle): ditto.
1278         (WebCore::HistoryItem::setTarget): ditto.
1279         (WebCore::HistoryItem::setDocumentState): On Android, add a call to notifyHistoryItemChanged. See bug for a discussion of why this is needed.
1280         (WebCore::HistoryItem::clearDocumentState): ditto.
1281         (WebCore::HistoryItem::setIsTargetItem): ditto.
1282         (WebCore::HistoryItem::addChildItem): ditto.
1283         (WebCore::HistoryItem::setFormInfoFromRequest): ditto.
1284         * history/HistoryItem.h: Update signature of notifyHistoryItemChanged.
1285
1286 2009-12-03  Ben Murdoch  <benm@google.com>
1287
1288         Reviewed by Brady Eidson.
1289
1290         [Android] The FrameLoaderClient is unaware of BackForwardList changes.
1291         https://bugs.webkit.org/show_bug.cgi?id=31914
1292
1293         This change adds three new methods on the FrameLoaderClient interface to receive notifications when the BackForwardList changes.
1294
1295         No new tests required. Functionality on all platforms upstream remains the same. Android is the first platform to make use of these callbacks.
1296
1297         * history/BackForwardList.cpp:
1298         (WebCore::BackForwardList::addItem): Execute the callback.
1299         (WebCore::BackForwardList::goBack): ditto.
1300         (WebCore::BackForwardList::goForward): ditto.
1301         (WebCore::BackForwardList::goToItem): ditto.
1302         (WebCore::BackForwardList::setCapacity): dito.
1303         * loader/EmptyClients.h:
1304         (WebCore::EmptyFrameLoaderClient::dispatchDidAddBackForwardItem): Add an empty implementation for the callback that does nothing.
1305         (WebCore::EmptyFrameLoaderClient::dispatchDidRemoveBackForwardItem): ditto.
1306         (WebCore::EmptyFrameLoaderClient::dispatchDidChangeBackForwardIndex): ditto.
1307         * loader/FrameLoaderClient.h:
1308
1309 2009-12-03  Ben Murdoch  <benm@google.com>
1310
1311         Reviewed by Brady Eidson.
1312
1313         [Android] Upstream WebCore/history/android: Require some platform specific state attached to HistoryItem.
1314         https://bugs.webkit.org/show_bug.cgi?id=31913
1315
1316         Android stores information such as the zoom scale factor and bridge back to the Java counterpart with HistoryItem.
1317
1318         No new tests required as this is Android specific code.
1319
1320         * history/HistoryItem.h: Add Android specific member data to HistoryItem.
1321         * history/android: Added.
1322         * history/android/AndroidWebHistoryBridge.h: Added.
1323         * history/android/HistoryItemAndroid.cpp: Added, provides implementation for Android specific member functions in HistoryItem.
1324         (WebCore::HistoryItem::bridge): Added.
1325         (WebCore::HistoryItem::setBridge): Added.
1326
1327 2009-12-03  Oliver Hunt  <oliver@apple.com>
1328
1329         Reviewed by Maciej Stachowiak.
1330
1331         NULL ptr in SVGPathSegList::getPathSegAtLength()
1332         https://bugs.webkit.org/show_bug.cgi?id=30313
1333
1334         Add exception checks to SVGPathSegList's implementation to catch (and propagate) exceptions.
1335         Add null checks to SVGList's content manipulation functions to prevent
1336         null values from entering the list in the first place.
1337
1338         Test: svg/dom/svgpath-out-of-bounds-getPathSeg.html
1339
1340         * svg/SVGList.h:
1341         (WebCore::SVGList::initialize):
1342         (WebCore::SVGList::insertItemBefore):
1343         (WebCore::SVGList::replaceItem):
1344         (WebCore::SVGList::appendItem):
1345         * svg/SVGPathElement.cpp:
1346         (WebCore::SVGPathElement::getPathSegAtLength):
1347         * svg/SVGPathElement.h:
1348         * svg/SVGPathElement.idl:
1349         * svg/SVGPathSegList.cpp:
1350         (WebCore::SVGPathSegList::getPathSegAtLength):
1351         (WebCore::SVGPathSegList::toPathData):
1352         (WebCore::SVGPathSegList::createAnimated):
1353         * svg/SVGPathSegList.h:
1354
1355 2009-12-02  Yusuke Sato  <yusukes@chromium.org>
1356
1357         Reviewed by Eric Seidel.
1358
1359         Sanitize web fonts using the OTS library 
1360         https://bugs.webkit.org/show_bug.cgi?id=31106
1361
1362         Add support for OpenType sanitizer (OTS). It parses OpenType files (from @font-face)
1363         and attempts to validate and sanitize them. We hope this reduces the attack surface
1364         of the system font libraries.
1365
1366         * WebCore.gyp/WebCore.gyp: Added dependency to (chromium_src_dir)/third_party/ots/ library.
1367         * WebCore.gypi: Added new files below.
1368         * WebCore.xcodeproj/project.pbxproj: Ditto.
1369         * platform/graphics/chromium/FontCustomPlatformData.cpp: Validate and transcode a web font.
1370         (WebCore::createFontCustomPlatformData):
1371         * platform/graphics/mac/FontCustomPlatformData.cpp: Ditto.
1372         (WebCore::createFontCustomPlatformData):
1373         * platform/graphics/opentype/OpenTypeSanitizer.cpp: Added.
1374         (WebCore::OpenTypeSanitizer::sanitize):
1375         * platform/graphics/opentype/OpenTypeSanitizer.h: Added.
1376         (WebCore::OpenTypeSanitizer::OpenTypeSanitizer):
1377
1378 2009-12-02  Oliver Hunt  <oliver@apple.com>
1379
1380         Reviewed by Sam Weinig.
1381
1382         Web Inspector frontend heap allocates ScriptFunctionCall which is unsafe
1383         https://bugs.webkit.org/show_bug.cgi?id=32098
1384
1385         Fix is simply to make the ScriptFunctionCall stack allocated as nature intended.
1386         Doing this required adding an appendArgument(char*) to ScriptFunctionCall so
1387         that an explicit String cast would not be necessary.
1388
1389         To prevent something like this happening again in future i've added private
1390         operator new implementations to ScriptFunctionCall making this type of mistake
1391         produce errors when compiling.
1392
1393         Test case: Inspector tests now pass with GC on every alloc enabled.
1394
1395         * bindings/js/ScriptFunctionCall.cpp:
1396         (WebCore::ScriptFunctionCall::appendArgument):
1397         * bindings/js/ScriptFunctionCall.h:
1398         (WebCore::ScriptFunctionCall::operator new):
1399         (WebCore::ScriptFunctionCall::operator new[]):
1400         * inspector/InspectorFrontend.cpp:
1401         (WebCore::InspectorFrontend::addConsoleMessage):
1402         (WebCore::InspectorFrontend::updateConsoleMessageRepeatCount):
1403         (WebCore::InspectorFrontend::addResource):
1404         (WebCore::InspectorFrontend::updateResource):
1405         (WebCore::InspectorFrontend::removeResource):
1406         (WebCore::InspectorFrontend::updateFocusedNode):
1407         (WebCore::InspectorFrontend::setAttachedWindow):
1408         (WebCore::InspectorFrontend::addRecordToTimeline):
1409         (WebCore::InspectorFrontend::parsedScriptSource):
1410         (WebCore::InspectorFrontend::failedToParseScriptSource):
1411         (WebCore::InspectorFrontend::addProfileHeader):
1412         (WebCore::InspectorFrontend::setRecordingProfile):
1413         (WebCore::InspectorFrontend::didGetProfileHeaders):
1414         (WebCore::InspectorFrontend::didGetProfile):
1415         (WebCore::InspectorFrontend::pausedScript):
1416         (WebCore::InspectorFrontend::setDocument):
1417         (WebCore::InspectorFrontend::setDetachedRoot):
1418         (WebCore::InspectorFrontend::setChildNodes):
1419         (WebCore::InspectorFrontend::childNodeCountUpdated):
1420         (WebCore::InspectorFrontend::childNodeInserted):
1421         (WebCore::InspectorFrontend::childNodeRemoved):
1422         (WebCore::InspectorFrontend::attributesUpdated):
1423         (WebCore::InspectorFrontend::didRemoveNode):
1424         (WebCore::InspectorFrontend::didGetChildNodes):
1425         (WebCore::InspectorFrontend::didApplyDomChange):
1426         (WebCore::InspectorFrontend::didGetEventListenersForNode):
1427         (WebCore::InspectorFrontend::didGetCookies):
1428         (WebCore::InspectorFrontend::didDispatchOnInjectedScript):
1429         (WebCore::InspectorFrontend::addDatabase):
1430         (WebCore::InspectorFrontend::selectDatabase):
1431         (WebCore::InspectorFrontend::didGetDatabaseTableNames):
1432         (WebCore::InspectorFrontend::addDOMStorage):
1433         (WebCore::InspectorFrontend::selectDOMStorage):
1434         (WebCore::InspectorFrontend::didGetDOMStorageEntries):
1435         (WebCore::InspectorFrontend::didSetDOMStorageItem):
1436         (WebCore::InspectorFrontend::didRemoveDOMStorageItem):
1437         (WebCore::InspectorFrontend::updateDOMStorage):
1438         (WebCore::InspectorFrontend::addNodesToSearchResult):
1439         (WebCore::InspectorFrontend::evaluateForTestInFrontend):
1440         * inspector/InspectorFrontend.h:
1441
1442 2009-12-02  Dave Hyatt  <hyatt@apple.com>
1443
1444         Reviewed by Darin Adler.
1445
1446         https://bugs.webkit.org/show_bug.cgi?id=32072, clean up invalid @-rule error handling so that we
1447         pass more CSS test suite stuff.  Make the grammar stop enforcing the ordering of @namespace vs.
1448         @variables vs. @import.  Just let the parser handle that instead.  This simplifies the grammar and
1449         makes error handling deal with more cases correctly.
1450
1451         Added fast/css/namespaces/namespaces-invalid-at-rules.xml
1452
1453         * css/CSSGrammar.y:
1454         * css/CSSParser.cpp:
1455         (WebCore::CSSParser::CSSParser):
1456         (WebCore::CSSParser::parseRule):
1457         (WebCore::CSSParser::createCharsetRule):
1458         (WebCore::CSSParser::createImportRule):
1459         (WebCore::CSSParser::createMediaRule):
1460         (WebCore::CSSParser::createKeyframesRule):
1461         (WebCore::CSSParser::createStyleRule):
1462         (WebCore::CSSParser::createFontFaceRule):
1463         (WebCore::CSSParser::addNamespace):
1464         (WebCore::CSSParser::createVariablesRule):
1465         * css/CSSParser.h:
1466
1467 2009-12-02  Yusuke Sato  <yusukes@chromium.org>
1468
1469         Reviewed by Dan Bernstein.
1470
1471         Safari/Chromium for Windows fails to load CJK WebFonts
1472         https://bugs.webkit.org/show_bug.cgi?id=31804
1473         
1474         * platform/graphics/opentype/OpenTypeUtilities.cpp:
1475         (WebCore::renameAndActivateFont): Load a remote font even if the font has 2 or more faces.
1476
1477 2009-12-02  Avi Drissman  <avi@chromium.org>
1478
1479         Reviewed by Darin Fisher.
1480
1481         Chromium: Need tickmarks in scrollbar
1482         https://bugs.webkit.org/show_bug.cgi?id=32069
1483
1484         * WebCore.gyp/WebCore.gyp:
1485         * WebCore.gypi:
1486         * platform/chromium/ScrollbarThemeChromiumMac.h: Added.
1487         * platform/chromium/ScrollbarThemeChromiumMac.mm: Added.
1488
1489 2009-11-13  Timothy Hatcher  <timothy@apple.com>
1490
1491         Expose a function to set the value of an input element on behalf of the user.
1492         This function will dispatch the change event so the page is notified when autofill
1493         happens. Also dispatch a change event when a select element is changed by autofill.
1494
1495         <rdar://problem/6760590> Would like a way to detect a login form AutoFill from JavaScript
1496
1497         Reviewed by Darin Adler.
1498
1499         * WebCore.xcodeproj/project.pbxproj: Added the DOMHTMLInputElementPrivate.h header.
1500         * bindings/objc/DOMHTML.mm:
1501         (-[DOMHTMLSelectElement _activateItemAtIndex:]): Call setSelectedIndexByUser instead so
1502         a change event is fired. This method is called by Safari autofill.
1503         * dom/Document.cpp:
1504         (WebCore::Document::setFocusedNode): Use dispatchFormControlChangeEvent instead
1505         of dispatching the change event directly to be consistent.
1506         * html/HTMLFormControlElement.cpp:
1507         (WebCore::HTMLInputElement::setValueForUser): Added. Calls setValue with the sendChangeEvent
1508         (WebCore::HTMLInputElement::setValue): Added the optional sendChangeEvent argument. Mimics setChecked.
1509         * html/HTMLInputElement.h:
1510         * html/HTMLInputElement.idl: Added setValueForUser for non-JS languages.
1511         * html/InputElement.h: Added setValueForUser.
1512
1513 2009-12-02  Pavel Feldman  <pfeldman@dhcp-172-28-174-220.spb.corp.google.com>
1514
1515         Reviewed by Timothy Hatcher.
1516
1517         Web Inspector: DOM tree selection disappears upon page refresh.
1518
1519         https://bugs.webkit.org/show_bug.cgi?id=31142
1520
1521         Test: inspector/elements-panel-selection-on-refresh.html
1522
1523         * inspector/InjectedScriptHost.cpp:
1524         (WebCore::InjectedScriptHost::pushNodeByPathToFrontend):
1525         * inspector/InjectedScriptHost.h:
1526         * inspector/InjectedScriptHost.idl:
1527         * inspector/InspectorBackend.h:
1528         * inspector/InspectorController.cpp:
1529         (WebCore::InspectorController::close):
1530         (WebCore::InspectorController::releaseDOMAgent):
1531         (WebCore::InspectorController::resetScriptObjects):
1532         * inspector/InspectorDOMAgent.cpp:
1533         (WebCore::InspectorDOMAgent::~InspectorDOMAgent):
1534         (WebCore::InspectorDOMAgent::reset):
1535         (WebCore::InspectorDOMAgent::setDocument):
1536         (WebCore::InspectorDOMAgent::pushDocumentToFrontend):
1537         (WebCore::InspectorDOMAgent::nodeForPath):
1538         (WebCore::InspectorDOMAgent::pushNodePathToFrontend):
1539         * inspector/InspectorDOMAgent.h:
1540         * inspector/front-end/DOMAgent.js:
1541         (WebInspector.DOMNode.prototype._renumber):
1542         (WebInspector.DOMAgent.prototype._setDocument):
1543         * inspector/front-end/ElementsPanel.js:
1544         (WebInspector.ElementsPanel.prototype.reset):
1545         (WebInspector.ElementsPanel.prototype.setDocument.selectDefaultNode):
1546         (WebInspector.ElementsPanel.prototype.setDocument.selectLastSelectedNode):
1547         (WebInspector.ElementsPanel.prototype.setDocument):
1548         * inspector/front-end/InjectedScript.js:
1549         (InjectedScript.pushNodeByPathToFrontend):
1550         * inspector/front-end/InjectedScriptAccess.js:
1551
1552 2009-12-01  Dave Hyatt  <hyatt@apple.com>
1553
1554         Reviewed by Dan Bernstein.
1555
1556         https://bugs.webkit.org/show_bug.cgi?id=32045, make sure escape sequences work with
1557         all the @-rules we support.  When escape sequences are present, the lexical scanner
1558         just returns a generic token name: ATKEYWORD.  We have to process the escape sequences
1559         and then recheck against the rules we support with the final processed name.  If we
1560         find a match, we mutate the token value to the appropriate rule name token, e.g.,
1561         NAMESPACE_SYM.
1562
1563         Added fast/css/namespaces/namespaces-escapes.xml
1564
1565         * css/CSSParser.cpp:
1566         (WebCore::CSSParser::lex):
1567         (WebCore::CSSParser::recheckAtKeyword):
1568         (WebCore::CSSParser::text):
1569         * css/CSSParser.h:
1570
1571 2009-12-02  Anton Muhin  <antonm@chromium.org>
1572
1573         Reviewed by Adam Barth.:w
1574
1575         Allow to skip thread checks when accessing DOMDataStore for processes
1576         which run V8 in single thread mode.
1577         https://bugs.webkit.org/show_bug.cgi?id=31877
1578
1579         Should be covered by buildbots.
1580
1581         * bindings/v8/V8DOMMap.cpp:
1582         (WebCore::getDOMDataStore):
1583         (WebCore::enableFasterDOMStoreAccess):
1584         (WebCore::getDOMNodeMap):
1585         (WebCore::getDOMObjectMap):
1586         (WebCore::getActiveDOMObjectMap):
1587         (WebCore::getDOMSVGElementInstanceMap):
1588         (WebCore::getDOMSVGObjectWithContextMap):
1589         * bindings/v8/V8DOMMap.h:
1590
1591 2009-12-02  Yury Semikhatsky  <yurys@chromium.org>
1592
1593         Reviewed by Pavel Feldman.
1594
1595         Code clean up: remove ScriptObjectQuarantine.* as a whole.
1596
1597         https://bugs.webkit.org/show_bug.cgi?id=32060
1598
1599         * GNUmakefile.am:
1600         * WebCore.gypi:
1601         * WebCore.pro:
1602         * WebCore.vcproj/WebCore.vcproj:
1603         * WebCore.xcodeproj/project.pbxproj:
1604         * WebCoreSources.bkl:
1605         * bindings/js/JSBindingsAllInOne.cpp:
1606         * bindings/js/ScriptObjectQuarantine.cpp: Removed.
1607         * bindings/js/ScriptObjectQuarantine.h: Removed.
1608         * bindings/js/ScriptValue.cpp:
1609         (WebCore::ScriptValue::quarantineValue):
1610         * bindings/js/ScriptValue.h:
1611         * bindings/v8/ScriptObjectQuarantine.cpp: Removed.
1612         * bindings/v8/ScriptObjectQuarantine.h: Removed.
1613         * bindings/v8/ScriptValue.h:
1614         (WebCore::ScriptValue::quarantineValue):
1615         * inspector/ConsoleMessage.cpp:
1616         (WebCore::ConsoleMessage::ConsoleMessage):
1617         * inspector/InspectorController.cpp:
1618         * inspector/InspectorDatabaseResource.cpp:
1619         (WebCore::InspectorDatabaseResource::bind):
1620         * inspector/InspectorFrontend.cpp:
1621
1622 2009-12-02  Fumitoshi Ukai  <ukai@chromium.org>
1623
1624         Reviewed by Alexey Proskuryakov.
1625
1626         WebSocket handshake check query component of URL
1627         https://bugs.webkit.org/show_bug.cgi?id=31617
1628
1629         Tests: websocket/tests/url-with-credential.html
1630                websocket/tests/url-with-empty-query.html
1631                websocket/tests/url-with-fragment.html
1632                websocket/tests/url-with-query-for-no-query.html
1633                websocket/tests/url-with-query.html
1634
1635         * platform/KURLGoogle.cpp:
1636         (WebCore::KURL::query): returns a null if query is not specified and returns an empty if query is specified but empty.
1637         * websockets/WebSocketHandshake.cpp:
1638         (WebCore::resourceName): added. add query component to path if specified.
1639         (WebCore::WebSocketHandshake::clientLocation):
1640         (WebCore::WebSocketHandshake::clientHandshakeMessage):
1641
1642 2009-12-01  David Levin  <levin@chromium.org>
1643
1644         Reviewed by Eric Seidel.
1645
1646         Incorrect code in WebGLRenderingContext.cpp
1647         https://bugs.webkit.org/show_bug.cgi?id=32046
1648
1649         Fix incorrect code that happened to work. != has higher precendence than &.
1650         The simplest fix is to remove the "!= 0" which violates WebKit style
1651         guidelines anyway.
1652
1653         Also added periods to few comments in the same function.
1654
1655         * html/canvas/WebGLRenderingContext.cpp:
1656         (WebCore::WebGLRenderingContext::validateIndexArray):
1657
1658 2009-12-01  Kent Tamura  <tkent@chromium.org>
1659
1660         Reviewed by Darin Adler.
1661
1662         Change [Reflect] to [ConvertNullToNullString, Reflect] for min, max,
1663         pattern and step attributes of HTMLInputElement.
1664         https://bugs.webkit.org/show_bug.cgi?id=31708
1665
1666         * html/HTMLInputElement.idl:
1667
1668 2009-12-01  Chris Fleizach  <cfleizach@apple.com>
1669
1670         Reviewed by Darin Adler.
1671
1672         WAI-ARIA: implement support for ARIA drag and drop
1673         https://bugs.webkit.org/show_bug.cgi?id=32007
1674
1675         Test: platform/mac/accessibility/aria-drag-drop.html
1676
1677         * accessibility/AccessibilityObject.h:
1678         (WebCore::AccessibilityObject::supportsARIADropping):
1679         (WebCore::AccessibilityObject::supportsARIADragging):
1680         (WebCore::AccessibilityObject::isARIAGrabbed):
1681         (WebCore::AccessibilityObject::setARIAGrabbed):
1682         (WebCore::AccessibilityObject::determineARIADropEffects):
1683         * accessibility/AccessibilityRenderObject.cpp:
1684         (WebCore::AccessibilityRenderObject::supportsARIADropping):
1685         (WebCore::AccessibilityRenderObject::supportsARIADragging):
1686         (WebCore::AccessibilityRenderObject::isARIAGrabbed):
1687         (WebCore::AccessibilityRenderObject::setARIAGrabbed):
1688         (WebCore::AccessibilityRenderObject::determineARIADropEffects):
1689         * accessibility/AccessibilityRenderObject.h:
1690         * accessibility/mac/AccessibilityObjectWrapper.mm:
1691         (-[AccessibilityObjectWrapper additionalAccessibilityAttributeNames]):
1692         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
1693         (-[AccessibilityObjectWrapper accessibilityIsAttributeSettable:]):
1694         (-[AccessibilityObjectWrapper accessibilitySetValue:forAttribute:]):
1695         * html/HTMLAttributeNames.in:
1696
1697 2009-12-01  Adam Barth  <abarth@webkit.org>
1698
1699         https://bugs.webkit.org/show_bug.cgi?id=21288
1700
1701         Unreviewed port of @sandbox to V8.
1702
1703         * bindings/v8/ScriptController.cpp:
1704         (WebCore::ScriptController::isEnabled):
1705         * bindings/v8/custom/V8DOMWindowCustom.cpp:
1706         (WebCore::createWindow):
1707
1708 2009-12-01  Patrik Persson  <patrik.j.persson@ericsson.com>
1709
1710         Reviewed by Darin Adler.
1711
1712         Implement HTML5 sandbox attribute for iframes.
1713         http://www.w3.org/TR/html5/text-level-semantics.html#attr-iframe-sandbox
1714         https://bugs.webkit.org/show_bug.cgi?id=21288
1715
1716         Tests: fast/frames/sandboxed-iframe-attribute-parsing.html
1717                fast/frames/sandboxed-iframe-forms.html
1718                fast/frames/sandboxed-iframe-navigation-allowed.html
1719                fast/frames/sandboxed-iframe-navigation-parent.html
1720                fast/frames/sandboxed-iframe-navigation-targetlink.html
1721                fast/frames/sandboxed-iframe-navigation-windowopen.html
1722                fast/frames/sandboxed-iframe-plugins.html
1723                fast/frames/sandboxed-iframe-scripting.html
1724                fast/frames/sandboxed-iframe-storage.html
1725                http/tests/security/sandboxed-iframe-document-cookie.html
1726                http/tests/security/sandboxed-iframe-modify-self.html
1727                http/tests/security/xss-DENIED-sandboxed-iframe.html
1728                http/tests/xmlhttprequest/access-control-sandboxed-iframe-allow.html
1729                http/tests/xmlhttprequest/access-control-sandboxed-iframe-denied-without-wildcard.html
1730                http/tests/xmlhttprequest/access-control-sandboxed-iframe-denied.html
1731
1732         * bindings/js/JSDOMWindowCustom.cpp: sandboxing navigation
1733         (WebCore::createWindow):
1734         * bindings/js/ScriptController.cpp: sandboxing scripts
1735         (WebCore::ScriptController::isEnabled):
1736         * dom/Document.cpp:
1737         (WebCore::Document::processHttpEquiv):
1738         (WebCore::Document::cookie): raise exception when accessed from sandbox
1739         (WebCore::Document::setCookie): raise exception when accessed from sandbox
1740         (WebCore::Document::initSecurityContext): updae sandbox status
1741         (WebCore::Document::updateSandboxFlags):
1742         * dom/Document.h:
1743         * dom/Document.idl:
1744         * html/HTMLAppletElement.cpp: sandboxing applets
1745         (WebCore::HTMLAppletElement::createRenderer):
1746         (WebCore::HTMLAppletElement::renderWidgetForJSBindings):
1747         (WebCore::HTMLAppletElement::canEmbedJava):
1748         * html/HTMLAppletElement.h:
1749         * html/HTMLAttributeNames.in:
1750         * html/HTMLFrameOwnerElement.cpp: management of sandbox flags as stated in attribute
1751         (WebCore::HTMLFrameOwnerElement::HTMLFrameOwnerElement):
1752         (WebCore::HTMLFrameOwnerElement::setSandboxFlags):
1753         * html/HTMLFrameOwnerElement.h:
1754         (WebCore::HTMLFrameOwnerElement::sandboxFlags):
1755         * html/HTMLIFrameElement.cpp: sandbox attribute parsing
1756         (WebCore::parseSandboxAttribute):
1757         (WebCore::HTMLIFrameElement::parseMappedAttribute):
1758         * html/HTMLIFrameElement.idl:
1759         * inspector/InspectorController.cpp:
1760         (WebCore::InspectorController::getCookies):
1761         * loader/CrossOriginAccessControl.cpp:
1762         (WebCore::passesAccessControlCheck):
1763         * loader/FrameLoader.cpp:
1764         (WebCore::FrameLoader::FrameLoader):
1765         (WebCore::FrameLoader::init):
1766         (WebCore::FrameLoader::submitForm): sandboxing forms
1767         (WebCore::FrameLoader::requestObject): sandboxing plugins
1768         (WebCore::FrameLoader::shouldAllowNavigation): sandboxing navigation
1769         (WebCore::FrameLoader::updateSandboxFlags): propagation of sandbox flags
1770         * loader/FrameLoader.h:
1771         (WebCore::FrameLoader::ownerElementSandboxFlagsChanged):
1772         (WebCore::FrameLoader::isSandboxed):
1773         (WebCore::FrameLoader::sandboxFlags):
1774         * loader/FrameLoaderTypes.h:
1775         (WebCore::):
1776         * page/DOMWindow.cpp: disable storage and databases in sandboxed frames
1777         (WebCore::DOMWindow::sessionStorage):
1778         (WebCore::DOMWindow::localStorage):
1779         (WebCore::DOMWindow::openDatabase):
1780         * page/SecurityOrigin.cpp: added sandboxing status
1781         (WebCore::SecurityOrigin::SecurityOrigin):
1782         (WebCore::SecurityOrigin::canAccess):
1783         (WebCore::SecurityOrigin::canRequest):
1784         (WebCore::SecurityOrigin::toString):
1785         * page/SecurityOrigin.h:
1786         (WebCore::SecurityOrigin::setSandboxFlags):
1787         (WebCore::SecurityOrigin::isSandboxed):
1788         (WebCore::SecurityOrigin::canAccessDatabase):
1789         (WebCore::SecurityOrigin::canAccessStorage):
1790         * websockets/WebSocketChannel.cpp:
1791         (WebCore::WebSocketChannel::didReceiveData):
1792
1793 2009-12-01  Chris Fleizach  <cfleizach@apple.com>
1794
1795         Reviewed by David Kilzer.
1796
1797         ARIA: support a way to create a static text object
1798         https://bugs.webkit.org/show_bug.cgi?id=32030
1799
1800         Test: accessibility/aria-text-role.html
1801
1802         * accessibility/AccessibilityObject.cpp:
1803         (WebCore::createARIARoleMap):
1804         * accessibility/AccessibilityRenderObject.cpp:
1805         (WebCore::AccessibilityRenderObject::stringValue):
1806         (WebCore::AccessibilityRenderObject::isDescendantOfBarrenParent):
1807         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
1808         (WebCore::AccessibilityRenderObject::text):
1809         * accessibility/AccessibilityRenderObject.h:
1810
1811 2009-12-01  Oliver Hunt  <oliver@apple.com>
1812
1813         Reviewed by Maciej Stachowiak.
1814
1815         Inspector crashes when collecting on every allocation
1816         https://bugs.webkit.org/show_bug.cgi?id=32044
1817
1818         The crash is caused by the prototype wrapper object getting collected
1819         when allocating the object that is going to use it as a prototype.
1820         Because the only reference to the prototype wrapper is through the
1821         new object's Structure it does not get marked automatically.
1822
1823         * bindings/js/JSInspectedObjectWrapper.cpp:
1824         (WebCore::JSInspectedObjectWrapper::wrap):
1825         * bindings/js/JSInspectorCallbackWrapper.cpp:
1826         (WebCore::JSInspectorCallbackWrapper::wrap):
1827
1828 2009-12-01  Nikolas Zimmermann  <nzimmermann@rim.com>
1829
1830         Reviewed by Simon Fraser.
1831
1832         Add SVG animation test framework with 'snapshot' functionality
1833         https://bugs.webkit.org/show_bug.cgi?id=31897
1834
1835         Add 'sampleSVGAnimationForElementAtTime' method to the LayoutTestController,
1836         for the use within the new SVG animation test framework (LayoutTests/svg/animations/)
1837
1838         layoutTestController.sampleAnimationAtTime(<svg animation id>, <absolute time>, <svg element id>);
1839         to sample a svg animateMotion/animateColor/animate/set element at certain times.
1840
1841         After the desired SVG animation starts and calling the method above, it's immediately forwarded to
1842         the desired sampling time. After JS returns from the 'sampleSVGAnimationForElementAtTime' method
1843         a callback is fired used to sample the animation value at the target time. It's modelled similar
1844         to the CSS animation/transition testing framework, inspired by
1845         LayoutTests/animations/animation-test-helpers.js.
1846
1847         Though it has been extended to integrate within the fast/js/js-test-* framework, that's used for
1848         the SVG dynamic-updates tests, to simplify test creation, by utilizing script-tests/* only.
1849
1850         Adding a simple testcase testing the DRT methods, it will soon be extended to test animVal/baseVal
1851         interaction, while animating.
1852
1853         Test: svg/animations/animVal-basics.html
1854
1855         * WebCore.base.exp:
1856         * WebCore.xcodeproj/project.pbxproj:
1857         * svg/SVGDocumentExtensions.cpp:
1858         (WebCore::SVGDocumentExtensions::sampleAnimationAtTime):
1859         * svg/SVGDocumentExtensions.h:
1860         * svg/animation/SMILTimeContainer.cpp:
1861         (WebCore::SMILTimeContainer::SMILTimeContainer):
1862         (WebCore::SMILTimeContainer::sampleAnimationAtTime):
1863         (WebCore::SMILTimeContainer::updateAnimations):
1864         * svg/animation/SMILTimeContainer.h:
1865
1866 2009-12-01  Jens Alfke  <snej@chromium.org>
1867
1868         Reviewed by Darin Adler.
1869
1870         Add convenience methods to Element and QualifiedName that take
1871         char* instead of AtomicString, in preparation for removing the
1872         implicit conversion between the two types (30187).
1873         https://bugs.webkit.org/show_bug.cgi?id=31749
1874
1875         * dom/Element.cpp:
1876         (WebCore::Element::setCStringAttribute):  Equivalent to setAttribute.
1877         * dom/Element.h:
1878         * dom/QualifiedName.cpp:
1879         (WebCore::QualifiedName::init):  Shared impl of both constructors
1880         (WebCore::QualifiedName::QualifiedName):  New c'tor taking char*.
1881         * dom/QualifiedName.h:
1882         * platform/network/HTTPHeaderMap.cpp:
1883         (WebCore::CaseFoldingCStringTranslator):  Enables lookup by C string
1884         (WebCore::HTTPHeaderMap::get):  New variant that takes C string
1885         (WebCore::HTTPHeaderMap::contains):  New variant that takes C string
1886         (WebCore::HTTPHeaderMap::add):  New variant that takes C string
1887         * platform/network/HTTPHeaderMap.h:
1888         (WebCore::HTTPHeaderMap::get):
1889         (WebCore::HTTPHeaderMap::add):
1890         * platform/network/ResourceRequestBase.cpp:
1891         (WebCore::ResourceRequestBase::httpHeaderField):  New variant that takes C string
1892         * platform/network/ResourceRequestBase.h:
1893         (WebCore::ResourceRequestBase::setHTTPHeaderField):  Use symbolic names for headers
1894         * platform/network/ResourceResponseBase.cpp:
1895         (WebCore::ResourceResponseBase::httpHeaderField):  New variant that takes C string
1896         * platform/network/ResourceResponseBase.h:
1897
1898 2009-12-01  Alexey Proskuryakov  <ap@apple.com>
1899
1900         More Windows build fix.
1901
1902         * platform/network/cf/CredentialStorageCFNet.cpp:
1903         (WebCore::CredentialStorage::getFromPersistentStorage):
1904
1905 2009-12-01  Alexey Proskuryakov  <ap@apple.com>
1906
1907         Windows build fix.
1908
1909         * platform/network/cf/CredentialStorageCFNet.cpp: Include RetainPtr.h.
1910
1911 2009-12-01  Alexey Proskuryakov  <ap@apple.com>
1912
1913         Reviewed by Darin Adler.
1914
1915         https://bugs.webkit.org/show_bug.cgi?id=32036
1916         Implement CredentialStorage::getFromPersistentStorage for CFNetwork
1917
1918         * platform/network/cf/CredentialStorageCFNet.cpp:
1919         (WebCore::CredentialStorage::getFromPersistentStorage):
1920
1921 2009-12-01  Daniel Bates  <dbates@webkit.org>
1922
1923         Reviewed by Pavel Feldman.
1924
1925         https://bugs.webkit.org/show_bug.cgi?id=32001
1926
1927         Added missing localized strings (that I left out of the patch for bug #21554):
1928         %d × %d pixels
1929         %d × %d pixels (Natural: %d × %d pixels)
1930
1931         Also, changed formatting of these stings to conform with existing ones (added
1932         a space on both sides of the multiply sign).
1933
1934         * English.lproj/localizedStrings.js: Added stings.
1935         * inspector/front-end/ElementsTreeOutline.js:
1936         (WebInspector.ElementsTreeElement.prototype.createTooltipForImageNode):
1937
1938 2009-12-01  Dave Hyatt  <hyatt@apple.com>
1939
1940         Reviewed by Simon Fraser.
1941
1942         Fix for bug 32032, empty namespaces should be allowed in @namespace directives in CSS.
1943
1944         Added fast/css/namespaces/namespaces-empty.xml
1945
1946         * css/CSSStyleSheet.cpp:
1947         (WebCore::CSSStyleSheet::addNamespace):
1948         (WebCore::CSSStyleSheet::determineNamespace):
1949
1950 2009-12-01  Joseph Pecoraro  <joepeck@webkit.org>
1951
1952         Reviewed by Timothy Hatcher.
1953
1954         Web Inspector: Escape key in the Search Field should be more User Friendly
1955         https://bugs.webkit.org/show_bug.cgi?id=32005
1956
1957         * inspector/front-end/inspector.js:
1958         (WebInspector.loaded): add mousedown listener on the search field
1959         (WebInspector.searchFieldManualFocus): user clicked to focus on the search field
1960         (WebInspector.searchKeyDown): handle escape
1961
1962 2009-12-01  Dave Hyatt  <hyatt@apple.com>
1963
1964         Reviewed by David Kilzer.
1965
1966         @namespace directives need to use "maybe_space" in the "maybe_ns_prefix" portion of the grammar to match
1967         the spec.  Not doing so prevent comments from being used immmediately after the namespace prefix.
1968
1969         Added fast/css/namespaces-comments.xml
1970
1971         * css/CSSGrammar.y:
1972
1973 2009-12-01  Yael Aharon  <yael.aharon@nokia.com>
1974
1975         Reviewed by Timothy Hatcher.
1976
1977         Reloading WebInspector from context menu is closing it instead of reloading.
1978         https://bugs.webkit.org/show_bug.cgi?id=32004
1979
1980         When reloading WebInspector, don't delete its m_page.
1981
1982         * inspector/InspectorController.cpp:
1983         (WebCore::InspectorController::close):
1984
1985 2009-12-01  Steve Block  <steveblock@google.com>
1986
1987         Reviewed by Dimitri Glazkov.
1988
1989         Adds V8 bindings for Geolocation.
1990         https://bugs.webkit.org/show_bug.cgi?id=30206
1991
1992         Also adds Geolocation files to Chrome build files.
1993
1994         * WebCore.gyp/WebCore.gyp: Modified. Corrects list of Geolocation IDL files.
1995         * WebCore.gypi: Modified. Adds Geolocation files.
1996         * bindings/v8/DOMObjectsInclude.h: Modified. Adds Geolocation includes.
1997         * bindings/v8/DerivedSourcesAllInOne.cpp: Modified. Adds Geolocation files.
1998         * bindings/v8/V8Index.cpp: Modified. Includes Geolocation generated headers.
1999         * bindings/v8/V8Index.h: Modified. Adds Geolocation types to DOM_OBJECT_TYPES.
2000         * bindings/v8/custom/V8CoordinatesCustom.cpp: Added. Handles optional properties.
2001         * bindings/v8/custom/V8CustomBinding.h: Modified. Declares callbacks and getters.
2002         * bindings/v8/custom/V8CustomPositionCallback.cpp: Added.
2003         (WebCore::V8CustomPositionCallback::V8CustomPositionCallback): Added. Constructor.
2004         (WebCore::V8CustomPositionCallback::~V8CustomPositionCallback): Added. Destructor.
2005         (WebCore::V8CustomPositionCallback::handleEvent): Added. Invokes callback.
2006         * bindings/v8/custom/V8CustomPositionCallback.h: Added.
2007         (WebCore::V8CustomPositionCallback::create): Added. Factory method.
2008         * bindings/v8/custom/V8CustomPositionErrorCallback.cpp: Added.
2009         (WebCore::V8CustomPositionErrorCallback::V8CustomPositionErrorCallback): Added. Constructor.
2010         (WebCore::V8CustomPositionErrorCallback::~V8CustomPositionErrorCallback): Added. Destructor.
2011         (WebCore::V8CustomPositionErrorCallback::handleEvent): Added. Invokes callback.
2012         * bindings/v8/custom/V8CustomPositionErrorCallback.h: Added.
2013         (WebCore::V8CustomPositionErrorCallback::create): Added. Factory method.
2014         * bindings/v8/custom/V8GeolocationCustom.cpp: Added.
2015         (WebCore::throwTypeMismatchException): Added. Throws a type mismatch error.
2016         (WebCore::createPositionCallback): Added. Handles type checking for successCallback argument.
2017         (WebCore::createPositionErrorCallback): Added. Handles type checking for errorCallback argument.
2018         (WebCore::createPositionOptions): Added. Handles type checking for positionOptions argument.
2019
2020 2009-12-01  Yury Semikhatsky  <yurys@chromium.org>
2021
2022         Reviewed by Adam Barth.
2023
2024         Provide a way to get ScriptState for the inspected page.
2025
2026         https://bugs.webkit.org/show_bug.cgi?id=32020
2027
2028         * bindings/v8/ScriptController.cpp:
2029         (WebCore::ScriptController::mainWorldScriptState):
2030         * bindings/v8/ScriptController.h:
2031         * bindings/v8/ScriptState.cpp:
2032         (WebCore::scriptStateFromPage):
2033
2034 2009-12-01  Chris Marrin  <cmarrin@apple.com>
2035
2036         Reviewed by Adam Roben.
2037
2038         Changed mallocs to fastMallocs and frees to fastFrees in GraphicsContext3D. Also added error returns
2039         https://bugs.webkit.org/show_bug.cgi?id=30778
2040
2041         * platform/graphics/mac/GraphicsContext3DMac.cpp:
2042         (WebCore::GraphicsContext3D::getProgramInfoLog):
2043         (WebCore::GraphicsContext3D::getShaderInfoLog):
2044         (WebCore::GraphicsContext3D::getShaderSource):
2045         (WebCore::imageToTexture):
2046
2047 2009-12-01  Mads Ager  <ager@chromium.org>
2048
2049         Reviewed by Eric Seidel.
2050
2051         [V8] Don't crash in DOMWindow event getter in OOM situations
2052         https://bugs.webkit.org/show_bug.cgi?id=32017
2053
2054         Add missing null handle checks in DOMWindow event property
2055         accessors.  V8Proxy::context(frame) can return a null handle in
2056         OOM situations either if failing to initialize a context or if an
2057         OOM is handled gracefully and javascript is disabled.
2058
2059         No new tests because we don't have a good way to test
2060         out-of-memory bugs.
2061
2062         * bindings/v8/custom/V8DOMWindowCustom.cpp:
2063         (WebCore::ACCESSOR_GETTER):
2064         (WebCore::ACCESSOR_SETTER):
2065
2066 2009-12-01  Chris Marrin  <cmarrin@apple.com>
2067
2068         Reviewed by Oliver Hunt.
2069
2070         Updated HTMLCanvasElement to accept "experimental-webgl" as the context name.
2071         https://bugs.webkit.org/show_bug.cgi?id=31672
2072
2073         * html/HTMLCanvasElement.cpp:
2074         (WebCore::HTMLCanvasElement::getContext):
2075
2076 2009-12-01  Pavel Feldman  <pfeldman@dhcp-172-28-174-220.spb.corp.google.com>
2077
2078         Not reviewed: chromium build fix, added missing import.
2079
2080         * inspector/InspectorFrontendHost.cpp:
2081
2082 2009-12-01  Pavel Feldman  <pfeldman@chromium.org>
2083
2084         Not reviewed: fix windows build via unexcluding generated files from
2085         project.
2086
2087         * WebCore.vcproj/WebCore.vcproj:
2088
2089 2009-12-01  Mark Rowe  <mrowe@apple.com>
2090
2091         Stop copying IDL files in to the WebCore framework wrapper.
2092
2093         * WebCore.xcodeproj/project.pbxproj:
2094
2095 2009-12-01  Mark Rowe  <mrowe@apple.com>
2096
2097         Fix the Tiger build by making the Xcode project compatible with Xcode 2.4.
2098
2099         This was probably broken by hand-editing the project file as Xcode itself
2100         knows how to keep project files to a backwards-compatible subset of its format.
2101
2102         * WebCore.xcodeproj/project.pbxproj:
2103
2104 2009-12-01  Pavel Feldman  <pfeldman@chromium.org>
2105
2106         Not reviewed: windows build fix (bad vcproj in r51528).
2107
2108         * WebCore.vcproj/WebCore.vcproj:
2109
2110 2009-11-27  Pavel Feldman  <pfeldman@dhcp-172-28-174-220.spb.corp.google.com>
2111
2112         Reviewed by Timothy Hatcher.
2113
2114         Web Inspector: Split InspectorBackend into three parts: backend,
2115         injected script host and frontend host.
2116         
2117         https://bugs.webkit.org/show_bug.cgi?id=31888
2118
2119         * DerivedSources.make:
2120         * GNUmakefile.am:
2121         * WebCore.gypi:
2122         * WebCore.pro:
2123         * WebCore.vcproj/WebCore.vcproj:
2124         * WebCore.xcodeproj/project.pbxproj:
2125         * WebCoreSources.bkl:
2126         * bindings/js/JSBindingsAllInOne.cpp:
2127         * bindings/js/JSInspectorBackendCustom.cpp: Removed.
2128         * bindings/js/JSInspectorFrontendHostCustom.cpp: Added.
2129         (WebCore::JSInspectorFrontendHost::search):
2130         (WebCore::JSInspectorFrontendHost::setting):
2131         (WebCore::JSInspectorFrontendHost::setSetting):
2132         * bindings/js/ScriptObject.cpp:
2133         (WebCore::ScriptGlobalObject::set):
2134         * bindings/js/ScriptObject.h:
2135         * bindings/v8/DOMObjectsInclude.h:
2136         * bindings/v8/DerivedSourcesAllInOne.cpp:
2137         * bindings/v8/ScriptObject.cpp:
2138         (WebCore::ScriptGlobalObject::set):
2139         * bindings/v8/ScriptObject.h:
2140         * bindings/v8/V8Index.cpp:
2141         * bindings/v8/V8Index.h:
2142         * bindings/v8/custom/V8CustomBinding.h:
2143         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp: Added.
2144         (WebCore::CALLBACK_FUNC_DECL):
2145         * bindings/v8/custom/V8InspectorBackendCustom.cpp: Removed.
2146         * bindings/v8/custom/V8InspectorFrontendHostCustom.cpp: Added.
2147         (WebCore::CALLBACK_FUNC_DECL):
2148         * inspector/InjectedScriptHost.cpp: Added.
2149         (WebCore::InjectedScriptHost::InjectedScriptHost):
2150         (WebCore::InjectedScriptHost::~InjectedScriptHost):
2151         (WebCore::InjectedScriptHost::copyText):
2152         (WebCore::InjectedScriptHost::nodeForId):
2153         (WebCore::InjectedScriptHost::wrapObject):
2154         (WebCore::InjectedScriptHost::unwrapObject):
2155         (WebCore::InjectedScriptHost::pushNodePathToFrontend):
2156         (WebCore::InjectedScriptHost::addNodesToSearchResult):
2157         (WebCore::InjectedScriptHost::currentCallFrame):
2158         (WebCore::InjectedScriptHost::databaseForId):
2159         (WebCore::InjectedScriptHost::selectDatabase):
2160         (WebCore::InjectedScriptHost::selectDOMStorage):
2161         (WebCore::InjectedScriptHost::reportDidDispatchOnInjectedScript):
2162         (WebCore::InjectedScriptHost::inspectorDOMAgent):
2163         (WebCore::InjectedScriptHost::inspectorFrontend):
2164         * inspector/InjectedScriptHost.h: Added.
2165         (WebCore::InjectedScriptHost::create):
2166         (WebCore::InjectedScriptHost::inspectorController):
2167         (WebCore::InjectedScriptHost::disconnectController):
2168         * inspector/InjectedScriptHost.idl: Added.
2169         * inspector/InspectorBackend.cpp:
2170         (WebCore::InspectorBackend::InspectorBackend):
2171         (WebCore::InspectorBackend::storeLastActivePanel):
2172         (WebCore::InspectorBackend::toggleNodeSearch):
2173         (WebCore::InspectorBackend::resourceTrackingEnabled):
2174         (WebCore::InspectorBackend::debuggerEnabled):
2175         (WebCore::InspectorBackend::enableDebugger):
2176         (WebCore::InspectorBackend::disableDebugger):
2177         (WebCore::InspectorBackend::addBreakpoint):
2178         (WebCore::InspectorBackend::updateBreakpoint):
2179         (WebCore::InspectorBackend::removeBreakpoint):
2180         (WebCore::InspectorBackend::pauseInDebugger):
2181         (WebCore::InspectorBackend::resumeDebugger):
2182         (WebCore::InspectorBackend::stepOverStatementInDebugger):
2183         (WebCore::InspectorBackend::stepIntoStatementInDebugger):
2184         (WebCore::InspectorBackend::stepOutOfFunctionInDebugger):
2185         (WebCore::InspectorBackend::pauseOnExceptions):
2186         (WebCore::InspectorBackend::setPauseOnExceptions):
2187         (WebCore::InspectorBackend::profilerEnabled):
2188         (WebCore::InspectorBackend::enableProfiler):
2189         (WebCore::InspectorBackend::disableProfiler):
2190         (WebCore::InspectorBackend::startProfiling):
2191         (WebCore::InspectorBackend::stopProfiling):
2192         (WebCore::InspectorBackend::getProfileHeaders):
2193         (WebCore::InspectorBackend::getProfile):
2194         (WebCore::InspectorBackend::currentCallFrame):
2195         (WebCore::InspectorBackend::highlightDOMNode):
2196         (WebCore::InspectorBackend::hideDOMNodeHighlight):
2197         (WebCore::InspectorBackend::getCookies):
2198         (WebCore::InspectorBackend::deleteCookie):
2199         (WebCore::InspectorBackend::didEvaluateForTestInFrontend):
2200         (WebCore::InspectorBackend::nodeForId):
2201         * inspector/InspectorBackend.h:
2202         (WebCore::InspectorBackend::create):
2203         * inspector/InspectorBackend.idl:
2204         * inspector/InspectorController.cpp:
2205         (WebCore::InspectorController::InspectorController):
2206         (WebCore::InspectorController::~InspectorController):
2207         (WebCore::InspectorController::inspectedPageDestroyed):
2208         (WebCore::InspectorController::windowScriptObjectAvailable):
2209         * inspector/InspectorController.h:
2210         (WebCore::InspectorController::inspectorFrontendHost):
2211         (WebCore::InspectorController::injectedScriptHost):
2212         * inspector/InspectorFrontendHost.cpp: Added.
2213         (WebCore::InspectorFrontendHost::InspectorFrontendHost):
2214         (WebCore::InspectorFrontendHost::~InspectorFrontendHost):
2215         (WebCore::InspectorFrontendHost::loaded):
2216         (WebCore::InspectorFrontendHost::attach):
2217         (WebCore::InspectorFrontendHost::detach):
2218         (WebCore::InspectorFrontendHost::closeWindow):
2219         (WebCore::InspectorFrontendHost::windowUnloading):
2220         (WebCore::InspectorFrontendHost::setAttachedWindowHeight):
2221         (WebCore::InspectorFrontendHost::moveWindowBy):
2222         (WebCore::InspectorFrontendHost::localizedStringsURL):
2223         (WebCore::InspectorFrontendHost::hiddenPanels):
2224         (WebCore::InspectorFrontendHost::platform):
2225         (WebCore::InspectorFrontendHost::port):
2226         (WebCore::InspectorFrontendHost::addResourceSourceToFrame):
2227         (WebCore::InspectorFrontendHost::addSourceToFrame):
2228         * inspector/InspectorFrontendHost.h: Added.
2229         (WebCore::InspectorFrontendHost::create):
2230         (WebCore::InspectorFrontendHost::inspectorController):
2231         (WebCore::InspectorFrontendHost::disconnectController):
2232         * inspector/InspectorFrontendHost.idl: Added.
2233         * inspector/front-end/Breakpoint.js:
2234         (WebInspector.Breakpoint.prototype.set condition):
2235         * inspector/front-end/BreakpointsSidebarPane.js:
2236         (WebInspector.BreakpointsSidebarPane.prototype.addBreakpoint):
2237         (WebInspector.BreakpointsSidebarPane.prototype.removeBreakpoint):
2238         (WebInspector.BreakpointsSidebarPane.prototype._breakpointEnableChanged):
2239         * inspector/front-end/ConsoleView.js:
2240         (WebInspector.ConsoleView.prototype.clearMessages):
2241         * inspector/front-end/CookieItemsView.js:
2242         (WebInspector.CookieItemsView.prototype._deleteCookieCallback):
2243         * inspector/front-end/DOMAgent.js:
2244         (WebInspector.DOMAgent.prototype.getChildNodesAsync):
2245         (WebInspector.DOMAgent.prototype.setAttributeAsync):
2246         (WebInspector.DOMAgent.prototype.removeAttributeAsync):
2247         (WebInspector.DOMAgent.prototype.setTextNodeValueAsync):
2248         (WebInspector.Cookies.getCookiesAsync):
2249         (WebInspector.EventListeners.getEventListenersForNodeAsync):
2250         * inspector/front-end/DOMStorage.js:
2251         (WebInspector.DOMStorage.prototype.getEntries):
2252         (WebInspector.DOMStorage.prototype.setItem):
2253         (WebInspector.DOMStorage.prototype.removeItem):
2254         * inspector/front-end/Database.js:
2255         (WebInspector.Database.prototype.getTableNames):
2256         * inspector/front-end/ElementsPanel.js:
2257         (WebInspector.ElementsPanel.this.treeOutline.focusedNodeChanged):
2258         (WebInspector.ElementsPanel.prototype.hide):
2259         (WebInspector.ElementsPanel.prototype.reset):
2260         (WebInspector.ElementsPanel.prototype.handleCopyEvent):
2261         (WebInspector.ElementsPanel.prototype._nodeSearchButtonClicked):
2262         * inspector/front-end/ElementsTreeOutline.js:
2263         (WebInspector.ElementsTreeOutline.prototype.set focusedDOMNode.restoreHighlightToHoveredNode):
2264         (WebInspector.ElementsTreeOutline.prototype.set focusedDOMNode):
2265         ():
2266         * inspector/front-end/EventListenersSidebarPane.js:
2267         (WebInspector.EventListenersSidebarPane.prototype):
2268         * inspector/front-end/InjectedScript.js:
2269         (InjectedScript._evaluateAndWrap):
2270         (InjectedScript.performSearch.addNodesToResults):
2271         (InjectedScript.getCallFrames):
2272         (InjectedScript._callFrameForId):
2273         (InjectedScript._clearConsoleMessages):
2274         (InjectedScript._inspectObject):
2275         (InjectedScript._copy):
2276         (InjectedScript._ensureCommandLineAPIInstalled):
2277         (InjectedScript._window):
2278         (InjectedScript._nodeForId):
2279         (InjectedScript._objectForId):
2280         (InjectedScript.pushNodeToFrontend):
2281         (InjectedScript.executeSql):
2282         (InjectedScript.executeSql.errorCallback):
2283         (InjectedScript.executeSql.queryTransaction):
2284         * inspector/front-end/InjectedScriptAccess.js:
2285         (InjectedScriptAccess._installHandler.InjectedScriptAccess.methodName):
2286         (InjectedScriptAccess._installHandler):
2287         * inspector/front-end/InspectorBackendStub.js: Added.
2288         (.WebInspector.InspectorBackendStub):
2289         (.WebInspector.InspectorBackendStub.prototype.wrapCallback):
2290         (.WebInspector.InspectorBackendStub.prototype.platform):
2291         (.WebInspector.InspectorBackendStub.prototype.port):
2292         (.WebInspector.InspectorBackendStub.prototype.closeWindow):
2293         (.WebInspector.InspectorBackendStub.prototype.attach):
2294         (.WebInspector.InspectorBackendStub.prototype.detach):
2295         (.WebInspector.InspectorBackendStub.prototype.storeLastActivePanel):
2296         (.WebInspector.InspectorBackendStub.prototype.clearMessages):
2297         (.WebInspector.InspectorBackendStub.prototype.searchingForNode):
2298         (.WebInspector.InspectorBackendStub.prototype.search):
2299         (.WebInspector.InspectorBackendStub.prototype.toggleNodeSearch):
2300         (.WebInspector.InspectorBackendStub.prototype.setAttachedWindowHeight):
2301         (.WebInspector.InspectorBackendStub.prototype.moveByUnrestricted):
2302         (.WebInspector.InspectorBackendStub.prototype.addResourceSourceToFrame):
2303         (.WebInspector.InspectorBackendStub.prototype.addSourceToFrame):
2304         (.WebInspector.InspectorBackendStub.prototype.getResourceDocumentNode):
2305         (.WebInspector.InspectorBackendStub.prototype.highlightDOMNode):
2306         (.WebInspector.InspectorBackendStub.prototype.hideDOMNodeHighlight):
2307         (.WebInspector.InspectorBackendStub.prototype.inspectedWindow):
2308         (.WebInspector.InspectorBackendStub.prototype.loaded):
2309         (.WebInspector.InspectorBackendStub.prototype.localizedStringsURL):
2310         (.WebInspector.InspectorBackendStub.prototype.windowUnloading):
2311         (.WebInspector.InspectorBackendStub.prototype.hiddenPanels):
2312         (.WebInspector.InspectorBackendStub.prototype.debuggerEnabled):
2313         (.WebInspector.InspectorBackendStub.prototype.enableResourceTracking):
2314         (.WebInspector.InspectorBackendStub.prototype.disableResourceTracking):
2315         (.WebInspector.InspectorBackendStub.prototype.resourceTrackingEnabled):
2316         (.WebInspector.InspectorBackendStub.prototype.enableDebugger):
2317         (.WebInspector.InspectorBackendStub.prototype.disableDebugger):
2318         (.WebInspector.InspectorBackendStub.prototype.addBreakpoint):
2319         (.WebInspector.InspectorBackendStub.prototype.removeBreakpoint):
2320         (.WebInspector.InspectorBackendStub.prototype.updateBreakpoint):
2321         (.WebInspector.InspectorBackendStub.prototype.pauseInDebugger):
2322         (.WebInspector.InspectorBackendStub.prototype.pauseOnExceptions):
2323         (.WebInspector.InspectorBackendStub.prototype.setPauseOnExceptions):
2324         (.WebInspector.InspectorBackendStub.prototype.resumeDebugger):
2325         (.WebInspector.InspectorBackendStub.prototype.profilerEnabled):
2326         (.WebInspector.InspectorBackendStub.prototype.enableProfiler):
2327         (.WebInspector.InspectorBackendStub.prototype.disableProfiler):
2328         (.WebInspector.InspectorBackendStub.prototype.startProfiling):
2329         (.WebInspector.InspectorBackendStub.prototype.stopProfiling):
2330         (.WebInspector.InspectorBackendStub.prototype.getProfileHeaders):
2331         (.WebInspector.InspectorBackendStub.prototype.getProfile):
2332         (.WebInspector.InspectorBackendStub.prototype.takeHeapSnapshot):
2333         (.WebInspector.InspectorBackendStub.prototype.databaseTableNames):
2334         (.WebInspector.InspectorBackendStub.prototype.stepIntoStatementInDebugger):
2335         (.WebInspector.InspectorBackendStub.prototype.stepOutOfFunctionInDebugger):
2336         (.WebInspector.InspectorBackendStub.prototype.stepOverStatementInDebugger):
2337         (.WebInspector.InspectorBackendStub.prototype.setSetting):
2338         (.WebInspector.InspectorBackendStub.prototype.dispatchOnInjectedScript):
2339         (.WebInspector.InspectorBackendStub.prototype.releaseWrapperObjectGroup):
2340         (.WebInspector.InspectorBackendStub.prototype.setting):
2341         * inspector/front-end/InspectorControllerStub.js:
2342         * inspector/front-end/InspectorFrontendHostStub.js: Added.
2343         (.WebInspector.InspectorFrontendHostStub):
2344         (.WebInspector.InspectorFrontendHostStub.prototype.platform):
2345         (.WebInspector.InspectorFrontendHostStub.prototype.port):
2346         (.WebInspector.InspectorFrontendHostStub.prototype.closeWindow):
2347         (.WebInspector.InspectorFrontendHostStub.prototype.attach):
2348         (.WebInspector.InspectorFrontendHostStub.prototype.detach):
2349         (.WebInspector.InspectorFrontendHostStub.prototype.search):
2350         (.WebInspector.InspectorFrontendHostStub.prototype.setAttachedWindowHeight):
2351         (.WebInspector.InspectorFrontendHostStub.prototype.moveWindowBy):
2352         (.WebInspector.InspectorFrontendHostStub.prototype.addResourceSourceToFrame):
2353         (.WebInspector.InspectorFrontendHostStub.prototype.addSourceToFrame):
2354         (.WebInspector.InspectorFrontendHostStub.prototype.loaded):
2355         (.WebInspector.InspectorFrontendHostStub.prototype.localizedStringsURL):
2356         (.WebInspector.InspectorFrontendHostStub.prototype.hiddenPanels):
2357         (.WebInspector.InspectorFrontendHostStub.prototype.setSetting):
2358         (.WebInspector.InspectorFrontendHostStub.prototype.setting):
2359         * inspector/front-end/ProfileView.js:
2360         (WebInspector.CPUProfileView):
2361         (WebInspector.CPUProfileType.prototype.buttonClicked):
2362         * inspector/front-end/ProfilesPanel.js:
2363         (WebInspector.ProfilesPanel.prototype._updateInterface):
2364         (WebInspector.ProfilesPanel.prototype._enableProfiling):
2365         (WebInspector.ProfilesPanel.prototype._toggleProfiling):
2366         * inspector/front-end/ResourcesPanel.js:
2367         (WebInspector.ResourcesPanel.prototype.reset):
2368         (WebInspector.ResourcesPanel.prototype._toggleLargerResources):
2369         (WebInspector.ResourcesPanel.prototype._enableResourceTracking):
2370         (WebInspector.ResourcesPanel.prototype._toggleResourceTracking):
2371         * inspector/front-end/ScriptView.js:
2372         (WebInspector.ScriptView.prototype.setupSourceFrameIfNeeded):
2373         * inspector/front-end/ScriptsPanel.js:
2374         (WebInspector.ScriptsPanel.prototype.show):
2375         (WebInspector.ScriptsPanel.prototype.addScript):
2376         (WebInspector.ScriptsPanel.prototype.attachDebuggerWhenShown):
2377         (WebInspector.ScriptsPanel.prototype.reset):
2378         (WebInspector.ScriptsPanel.prototype.canShowResource):
2379         (WebInspector.ScriptsPanel.prototype._showScriptOrResource):
2380         (WebInspector.ScriptsPanel.prototype._addScriptToFilesMenu):
2381         (WebInspector.ScriptsPanel.prototype._updatePauseOnExceptionsButton):
2382         (WebInspector.ScriptsPanel.prototype._updateDebuggerButtons):
2383         (WebInspector.ScriptsPanel.prototype._enableDebugging):
2384         (WebInspector.ScriptsPanel.prototype._toggleDebugging):
2385         (WebInspector.ScriptsPanel.prototype._togglePauseOnExceptions):
2386         (WebInspector.ScriptsPanel.prototype._togglePause):
2387         (WebInspector.ScriptsPanel.prototype._stepOverClicked):
2388         (WebInspector.ScriptsPanel.prototype._stepIntoClicked):
2389         (WebInspector.ScriptsPanel.prototype._stepOutClicked):
2390         * inspector/front-end/SourceView.js:
2391         (WebInspector.SourceView.prototype.setupSourceFrameIfNeeded):
2392         (WebInspector.SourceView.prototype.performSearch.findSearchMatches):
2393         (WebInspector.SourceView.prototype.performSearch):
2394         * inspector/front-end/StylesSidebarPane.js:
2395         (WebInspector.StylesSidebarPane.prototype._changeColorFormat):
2396         * inspector/front-end/TestController.js:
2397         (WebInspector.TestController.prototype.notifyDone):
2398         * inspector/front-end/TimelinePanel.js:
2399         (WebInspector.TimelinePanel.prototype._toggleTimelineButtonClicked):
2400         * inspector/front-end/WatchExpressionsSidebarPane.js:
2401         (WebInspector.WatchExpressionsSection.prototype.update):
2402         (WebInspector.WatchExpressionsSection.prototype.loadSavedExpressions):
2403         (WebInspector.WatchExpressionsSection.prototype.saveExpressions):
2404         * inspector/front-end/WebKit.qrc:
2405         * inspector/front-end/inspector.html:
2406         * inspector/front-end/inspector.js:
2407         (WebInspector.pendingDispatches.0.get platform):
2408         (WebInspector.get port):
2409         (WebInspector.set currentPanel):
2410         (WebInspector._createPanels):
2411         (WebInspector._loadPreferences):
2412         (WebInspector.set attached):
2413         (WebInspector._updateHoverHighlight):
2414         (WebInspector.loaded):
2415         (windowLoaded):
2416         (WebInspector.windowUnload):
2417         (WebInspector.close):
2418         (WebInspector.toolbarDrag):
2419         (WebInspector.UIString):
2420
2421 2009-11-30  Shinichiro Hamaji  <hamaji@chromium.org>
2422
2423         Reviewed by Dan Bernstein.
2424
2425         css2.1/t1205-c566-list-stl-00-e-ag.html is failing
2426         https://bugs.webkit.org/show_bug.cgi?id=23264
2427         css2.1/t1205-c565-list-pos-00-b.html is failing
2428         https://bugs.webkit.org/show_bug.cgi?id=23263
2429
2430         Ignore whitespaces after list markers.
2431         Rendering of this was already done for the case where inside=false.
2432         This fixes the rendering of inside=true case and calcInlinePrefWidths.
2433
2434         Test: fast/lists/calc-width-with-space.html
2435
2436         * rendering/RenderBlock.cpp:
2437         (WebCore::RenderBlock::calcInlinePrefWidths):
2438         * rendering/RenderBlockLineLayout.cpp:
2439         (WebCore::RenderBlock::findNextLineBreak):
2440
2441 2009-11-30  Fumitoshi Ukai  <ukai@chromium.org>
2442
2443         Unreviewed Chromium build fix introduced by r51212
2444
2445         Fix scriptStateFromNode and ScriptStateFromPage to take DOMWrapperWorld
2446         as the first argument.
2447         Move mainThreadNormalWorld() to ScriptState.{h,cpp}.
2448         Add debuggerWorld() and pluginWorld() in ScriptState.h.
2449
2450         * bindings/v8/ScriptController.cpp:
2451         * bindings/v8/ScriptController.h:
2452         * bindings/v8/ScriptState.cpp:
2453         (WebCore::scriptStateFromNode):
2454         (WebCore::scriptStateFromPage):
2455         (WebCore::mainThreadNormalWorld):
2456         * bindings/v8/ScriptState.h:
2457         (WebCore::debuggerWorld):
2458         (WebCore::pluginWorld):
2459
2460 2009-11-30  Enrica Casucci  <enrica@apple.com>
2461
2462         Reviewed by Darin Adler.
2463
2464         Can focus but not type into content editable block that contains only non-editable content.
2465         <rdar://problem/5982901>
2466         https://bugs.webkit.org/show_bug.cgi?id=31750
2467         
2468         The goal is to change the way we choose a visible position
2469         after hit detection, by preferring a visually equivalent editable
2470         position if available. By doing this, it is possible to add content
2471         to an editable block that initially contains only non editable elements.
2472
2473         Test: editing/selection/mixed-editability-10.html
2474
2475         * WebCore.base.exp: Changed to match the new signature of downstream
2476         and upstream in the Position class.
2477         * dom/Position.cpp:
2478         (WebCore::Position::atEditingBoundary): Added.
2479         (WebCore::Position::upstream): Modified to allow to cross the boundary
2480         between editable and non editable content if required.
2481         (WebCore::Position::downstream): Modified to allow to cross the boundary
2482         between editable and non editable content if required.
2483         (WebCore::Position::isCandidate): Modified to qualify as candidates positions
2484         that are at the editability boundary.
2485         (WebCore::Position::getInlineBoxAndOffset): Modified to retrieve the inline box
2486         to be used in calculating the caret rectangle.
2487         * dom/Position.h:
2488         (WebCore::Position::):
2489         * dom/PositionIterator.cpp:
2490         (WebCore::PositionIterator::atEditingBoundary): Added.
2491         (WebCore::PositionIterator::isCandidate): Modified to qualify as candidates positions
2492         that are at the editability boundary.
2493         * dom/PositionIterator.h:
2494         * editing/htmlediting.cpp:
2495         (WebCore::firstEditablePositionAfterPositionInRoot): Modified to accept not only
2496         descendants of the editable container, but the container itself.
2497         (WebCore::lastEditablePositionBeforePositionInRoot): Modified to accept not only
2498         descendants of the editable container, but the container itself.
2499         * rendering/RenderObject.cpp:
2500         (WebCore::RenderObject::createVisiblePosition): Added logic to prefer an editable position,
2501         if available.
2502         * rendering/RenderText.cpp:
2503         (WebCore::RenderText::isAllCollapsibleWhitespace): Added.
2504         * rendering/RenderText.h:
2505
2506 2009-11-30  Kevin Ollivier  <kevino@theolliviers.com>
2507
2508         wx build fix, add header needed for wx build.
2509
2510         * css/CSSFontFaceSrcValue.cpp:
2511
2512 2009-11-30  Mark Rowe  <mrowe@apple.com>
2513
2514         Reviewed by David Kilzer.
2515
2516         <rdar://problem/7424387> WebCore binary missing symbols when built for x86_64 from a machine that cannot run x86_64 binaries
2517
2518         The check for whether WTF_USE_PLUGIN_HOST_PROCESS is defined occurs under the native architecture of the build machine.
2519         If that is 32-bit then WTF_USE_PLUGIN_HOST_PROCESS will not be defined.  We work around this by forcing the check to
2520         be performed against the x86_64 architecture.
2521
2522         * DerivedSources.make:
2523
2524 2009-11-30  Beth Dakin  <bdakin@apple.com>
2525
2526         Reviewed by Oliver Hunt.
2527
2528         Fix for https://bugs.webkit.org/show_bug.cgi?id=32000 Crash in 
2529         Safari caused by extreme column-gap and column-width values 
2530         -and corresponding-
2531         <rdar://problem/7425433>
2532
2533         Prevent desiredColumnCount from being less than 1 since it is used 
2534         as a divisor.
2535         * rendering/RenderBlock.cpp:
2536         (WebCore::RenderBlock::calcColumnWidth):
2537
2538 2009-11-30  Alexey Proskuryakov  <ap@apple.com>
2539
2540         Reviewed by Oliver Hunt.
2541
2542         https://bugs.webkit.org/show_bug.cgi?id=31659
2543         Connection must be closed in case of Web Socket handshake error
2544
2545         The network connection was closed, but the close event wasn't dispatched.
2546
2547         Tested by websocket/tests/handshake-error.html, which is un-skipped now.
2548
2549         * platform/network/cf/SocketStreamHandleCFNet.cpp: (WebCore::SocketStreamHandle::platformClose):
2550         Call client didHandle() method. This looks strange in CFNetwork implementation, because
2551         it's the client that asked to close the stream, so it shouldn't need the callback. It makes
2552         more sense in cross-process implementation, because closing is async there.
2553
2554 2009-11-30  Gavin Barraclough  <barraclough@apple.com>
2555
2556         Reviewed by Geoff Garen.
2557
2558         Bug 31859 - Make world selection for JSC IsolatedWorlds automagical.
2559
2560         WebCore presently has to explicitly specify the world before entering into JSC,
2561         which is a little fragile (particularly since property access via a
2562         getter/setter might invoke execution). Instead derive the current world from
2563         the lexical global object.
2564
2565         Remove the last uses of mainThreadCurrentWorld(), so the world is always obtained via
2566         currentWorld().  Switch this to obtain the world from the ExecsState's lexical global
2567         object instead.  Remove the call/construct/evaluate 'InWorld' methods, since these
2568         are no longer necessary.
2569
2570         * WebCore.base.exp:
2571         * bindings/js/JSCallbackData.cpp:
2572         (WebCore::JSCallbackData::invokeCallback):
2573         * bindings/js/JSCallbackData.h:
2574         (WebCore::JSCallbackData::JSCallbackData):
2575         * bindings/js/JSCustomXPathNSResolver.cpp:
2576         (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
2577         * bindings/js/JSDOMBinding.cpp:
2578         (WebCore::currentWorld):
2579         (WebCore::mainThreadNormalWorld):
2580         * bindings/js/JSDOMBinding.h:
2581         (WebCore::WebCoreJSClientData::WebCoreJSClientData):
2582         * bindings/js/JSDOMWindowBase.cpp:
2583         (WebCore::JSDOMWindowBase::updateDocument):
2584         * bindings/js/JSDOMWindowBase.h:
2585         * bindings/js/JSEventListener.cpp:
2586         (WebCore::JSEventListener::handleEvent):
2587         (WebCore::JSEventListener::reportError):
2588         * bindings/js/JSHTMLDocumentCustom.cpp:
2589         (WebCore::JSHTMLDocument::open):
2590         * bindings/js/JSNodeFilterCondition.cpp:
2591         (WebCore::JSNodeFilterCondition::acceptNode):
2592         * bindings/js/JSQuarantinedObjectWrapper.cpp:
2593         (WebCore::JSQuarantinedObjectWrapper::construct):
2594         (WebCore::JSQuarantinedObjectWrapper::call):
2595         * bindings/js/ScheduledAction.cpp:
2596         (WebCore::ScheduledAction::executeFunctionInContext):
2597         * bindings/js/ScriptController.cpp:
2598         (WebCore::ScriptController::evaluateInWorld):
2599         (WebCore::ScriptController::initScript):
2600         (WebCore::ScriptController::updateDocument):
2601         * bindings/js/ScriptFunctionCall.cpp:
2602         (WebCore::ScriptFunctionCall::call):
2603         (WebCore::ScriptFunctionCall::construct):
2604         * bindings/js/ScriptObjectQuarantine.cpp:
2605         (WebCore::getQuarantinedScriptObject):
2606         * bindings/js/ScriptState.cpp:
2607         (WebCore::scriptStateFromNode):
2608         (WebCore::scriptStateFromPage):
2609         * bindings/js/ScriptState.h:
2610         * bindings/js/WorkerScriptController.cpp:
2611         (WebCore::WorkerScriptController::evaluate):
2612         * bindings/objc/WebScriptObject.mm:
2613         (-[WebScriptObject callWebScriptMethod:withArguments:]):
2614         (-[WebScriptObject evaluateWebScript:]):
2615         * bridge/NP_jsobject.cpp:
2616         (_NPN_InvokeDefault):
2617         (_NPN_Invoke):
2618         (_NPN_Evaluate):
2619         (_NPN_Construct):
2620         * bridge/jni/jni_jsobject.mm:
2621         (JavaJSObject::call):
2622         (JavaJSObject::eval):
2623         * dom/NodeFilter.h:
2624         (WebCore::NodeFilter::acceptNode):
2625         * dom/NodeIterator.h:
2626         (WebCore::NodeIterator::nextNode):
2627         (WebCore::NodeIterator::previousNode):
2628         * dom/TreeWalker.h:
2629         (WebCore::TreeWalker::parentNode):
2630         (WebCore::TreeWalker::firstChild):
2631         (WebCore::TreeWalker::lastChild):
2632         (WebCore::TreeWalker::previousSibling):
2633         (WebCore::TreeWalker::nextSibling):
2634         (WebCore::TreeWalker::previousNode):
2635         (WebCore::TreeWalker::nextNode):
2636         * inspector/InspectorController.cpp:
2637         (WebCore::InspectorController::windowScriptObjectAvailable):
2638         (WebCore::InspectorController::didEvaluateForTestInFrontend):
2639         * inspector/JavaScriptCallFrame.cpp:
2640         (WebCore::JavaScriptCallFrame::evaluate):
2641
2642 2009-11-30  Eric Carlson  <eric.carlson@apple.com>
2643
2644         Reviewed by Simon Fraser.
2645
2646         All HTML5 media element events should be regular events
2647         https://bugs.webkit.org/show_bug.cgi?id=30513
2648
2649         * html/HTMLMediaElement.cpp:
2650         (WebCore::HTMLMediaElement::selectMediaResource):
2651         (WebCore::HTMLMediaElement::noneSupported):
2652         (WebCore::HTMLMediaElement::mediaEngineError):
2653         (WebCore::HTMLMediaElement::setNetworkState):
2654         (WebCore::HTMLMediaElement::userCancelledLoad):
2655             Call scheduleEvent instead of scheduleProgressEvent.
2656         (WebCore::HTMLMediaElement::progressEventTimerFired):
2657             Call scheduleEvent instead of scheduleProgressEvent. Call renderer->updateFromElement
2658             after scheduling a 'progress' event so the controller will update download
2659             progress indicator.
2660         * html/HTMLMediaElement.h:
2661             Remove scheduleProgressEvent prototype.
2662
2663 2009-11-30  Joseph Pecoraro  <joepeck@webkit.org>
2664
2665         Reviewed by Pavel Feldman.
2666
2667         Web Inspector: Wrong console output for Regexp escape sequence
2668         https://bugs.webkit.org/show_bug.cgi?id=31538
2669
2670         Updated inspector/console-format.html
2671
2672         * inspector/front-end/ConsoleView.js:
2673         (WebInspector.ConsoleView.createDividerElement): style issues.
2674         (WebInspector.ConsoleView.createFilterElement): style issues.
2675         (WebInspector.ConsoleView): added _customFormatters table.
2676         (WebInspector.ConsoleView.prototype.updateMessageRepeatCount): style isses.
2677         (WebInspector.ConsoleView.prototype._incrementErrorWarningCount): style issues.
2678         (WebInspector.ConsoleView.prototype._format): simplified delegation to formatter logic.
2679         (WebInspector.ConsoleView.prototype._formatobject):
2680         (WebInspector.ConsoleView.prototype._formatnode):
2681         (WebInspector.ConsoleView.prototype._printArray):
2682         (WebInspector.ConsoleMessage.prototype._format): commented and broke down the algorithm into parts.
2683         (WebInspector.ConsoleMessage.prototype._formatWithSubstitutionString.append): handle substitution string formatting.
2684         (WebInspector.ConsoleMessage.prototype._formatIndividualValue): handling individual value formatting.
2685         (WebInspector.ConsoleCommandResult):
2686         * inspector/front-end/InjectedScript.js: simplified regex formatting.
2687         * inspector/front-end/inspector.js:
2688         (WebInspector.linkifyStringAsFragment): converted new RegExp to literal for performance benefits.
2689         * inspector/front-end/utilities.js: 
2690         (Element.prototype.hasStyleClass): update inaccurate comment.
2691         (String.prototype.trimURL): converted new RegExp to literal for performance benefits.
2692
2693 2009-11-30  Erik Arvidsson  <arv@chromium.org>
2694
2695         Reviewed by Adam Barth.
2696
2697         Clean up V8 bindings for CSSStyleDeclaration and CSSVariableDeclaration
2698         https://bugs.webkit.org/show_bug.cgi?id=31895
2699
2700         No new tests. This is already covered by:
2701                 fast/dom/CSSStyleDeclaration/css-computed-style-item.html
2702                 fast/dom/CSSStyleDeclaration/css-style-item.html
2703
2704         * bindings/v8/V8Collection.h:
2705         (WebCore::collectionStringIndexedPropertyGetter):
2706         (WebCore::setCollectionStringIndexedGetter):
2707         * bindings/v8/V8DOMWrapper.cpp:
2708         (WebCore::V8DOMWrapper::getTemplate):
2709
2710 2009-11-30  Steve Block  <steveblock@google.com>
2711
2712         Reviewed by Eric Seidel.
2713
2714         Adds include of wtf/StdLibExtras.h for DEFINE_STATIC_LOCAL in V8 ScriptController.
2715         https://bugs.webkit.org/show_bug.cgi?id=31932
2716
2717         Build fix only, no new tests.
2718
2719         * bindings/v8/ScriptController.cpp: Modified. Adds include of wtf/StdLibExtras.h.
2720
2721 2009-11-30  Steve Block  <steveblock@google.com>
2722
2723         Reviewed by Eric Seidel.
2724
2725         Adds PassOwnPtr include to ScriptExecutionContext.h.
2726         https://bugs.webkit.org/show_bug.cgi?id=31929
2727
2728         Build fix only, no new tests.
2729
2730         * dom/ScriptExecutionContext.h: Modified. Adds PassOwnPtr include.
2731
2732 2009-11-30  Dirk Schulze  <krit@webkit.org>
2733
2734         Reviewed by Nikolas Zimmermann.
2735
2736         REGRESSION (r49757): masking-mask-01-b.svg rendered incorrectly
2737         [https://bugs.webkit.org/show_bug.cgi?id=31980]
2738
2739         It turns out, that we did not handle maskUnits="userSpaceOnUse"
2740         correctly. We just need to move the context of the maskImage
2741         if maskContentUnits="objectBoundingBox". The context gets scaled
2742         on this unit combination, so we have to substract the position of
2743         the targetRect. On userSpaceOnUse the position just depends on the
2744         position of the mask element.
2745         I added a test with some senseless and reasonable values for size
2746         and postion of the mask and it's contents. I also used every
2747         combination of maskUnits and maskContentUnits to be sure, that it
2748         is fixed this time.
2749
2750         Test: svg/custom/mask-with-all-units.svg
2751
2752         * svg/SVGMaskElement.cpp:
2753         (WebCore::SVGMaskElement::drawMaskerContent):
2754
2755 2009-11-30  Steve Block  <steveblock@google.com>
2756
2757         Reviewed by Eric Seidel.
2758
2759         Adds ENABLE(INSPECTOR) guards around DOMWindow::inspectorTimelineAgent.
2760         https://bugs.webkit.org/show_bug.cgi?id=31928
2761
2762         Build fix only, no new tests.
2763
2764         * page/DOMWindow.cpp: Modified. Adds ENABLE(INSPECTOR) guards around DOMWindow::inspectorTimelineAgent.
2765
2766 2009-11-30  Steve Block  <steveblock@google.com>
2767
2768         Reviewed by Eric Seidel.
2769
2770         Adds SHARED_WORKERS guards to V8 WorkerContextExecutionProxy.
2771         https://bugs.webkit.org/show_bug.cgi?id=31926
2772
2773         Build fix only, no new tests.
2774
2775         * bindings/v8/WorkerContextExecutionProxy.cpp:
2776         (WebCore::WorkerContextExecutionProxy::initContextIfNeeded):
2777         (WebCore::WorkerContextExecutionProxy::convertToV8Object):
2778         (WebCore::WorkerContextExecutionProxy::convertEventTargetToV8Object):
2779
2780 2009-11-30  Benjamin Poulain  <benjamin.poulain@nokia.com>
2781
2782         Reviewed by Kenneth Rohde Christiansen.
2783
2784         Chrome::contentsSizeChanged() is called when the content size has not changed
2785         https://bugs.webkit.org/show_bug.cgi?id=31978
2786
2787         Do not trigger contentsSizeChaned() is the new size is the same as the old one.
2788
2789         * page/FrameView.cpp:
2790         (WebCore::FrameView::setContentsSize):
2791
2792 2009-11-30  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
2793
2794         Reviewed by Kenneth Rohde Christiansen.
2795
2796         [Qt] Fix some compiler warnings seen on QtWebKit/Mac
2797         https://bugs.webkit.org/show_bug.cgi?id=31962
2798
2799         No new tests as there is no functional change.
2800
2801         * platform/network/ResourceHandle.h: Make destructor virtual as 
2802         after r50772 ResourceHandle has virtual functions.
2803
2804         * plugins/mac/PluginPackageMac.cpp: 
2805         (WebCore::PluginPackage::fetchInfo): Fix typo WTF is a namespace
2806         not a label
2807
2808         * plugins/mac/PluginViewMac.cpp:
2809         (WebCore::PluginView::setNPWindowIfNeeded): Add l to the format
2810         specifier
2811
2812 2009-11-30  Xan Lopez  <xlopez@igalia.com>
2813
2814         Reviewed by Gustavo Noronha.
2815
2816         Add new headers to sources list.
2817
2818         * GNUmakefile.am:
2819
2820 2009-11-30  Girish Ramakrishnan  <girish@forwardbias.in>
2821
2822         Reviewed by Holger Freyther.
2823
2824         [Qt] Mac Plugins : Get context menu to work in QGraphicsView
2825         
2826         Flash expects the value in record.where to be the global position for
2827         displaying the context menu.
2828         
2829         https://bugs.webkit.org/show_bug.cgi?id=31979
2830
2831         * plugins/mac/PluginViewMac.cpp:
2832         (WebCore::PluginView::handleMouseEvent):
2833
2834 2009-11-30  Steve Block  <steveblock@google.com>
2835
2836         Reviewed by Eric Seidel.
2837
2838         Adds PLATFORM(CHROMIUM) guards around memory usage code in V8GCController.
2839         https://bugs.webkit.org/show_bug.cgi?id=31925
2840
2841         This code uses ChromiumBridge and Chromium-specific constant values not
2842         appropriate for other platforms such as Android.
2843
2844         Build fix only, no new tests.
2845
2846         * bindings/v8/V8GCController.cpp: Modified. Adds PLATFORM(CHROMIUM) around Chromium-specific code.
2847
2848 2009-11-29  Brent Fulgham  <bfulgham@webkit.org>
2849
2850         Build fix.
2851
2852         Correct draw signature used in ImageCairoWin.cpp.
2853
2854         * platform/graphics/win/ImageCairoWin.cpp:
2855         (WebCore::BitmapImage::getHBITMAPOfSize):
2856         (WebCore::BitmapImage::drawFrameMatchingSourceSize):
2857
2858 2009-11-28  Oliver Hunt  <oliver@apple.com>
2859
2860         Reviewed by Sam Weinig.
2861
2862         postMessage should serialize File objects
2863         https://bugs.webkit.org/show_bug.cgi?id=31955
2864
2865         Update SerializedScriptValue to include support for
2866         File objects in the serialized object graph.
2867
2868         * bindings/js/SerializedScriptValue.cpp:
2869         (WebCore::SerializedScriptValueData::SerializedScriptValueData):
2870         (WebCore::SerializingTreeWalker::convertIfTerminal):
2871         (WebCore::DeserializingTreeWalker::convertIfTerminal):
2872         * bindings/js/SerializedScriptValue.h:
2873         (WebCore::SerializedScriptValueData::):
2874         (WebCore::SerializedScriptValueData::asString):
2875
2876 2009-11-29  Simon Fraser  <simon.fraser@apple.com>
2877
2878         Reviewed by Dan Bernstein.
2879
2880         Optimize the hierarchy rebuilding of compositing layers
2881         https://bugs.webkit.org/show_bug.cgi?id=31879
2882         
2883         When updating the compositing layer hierarchy, instead of removing all
2884         child layers and then re-adding them one by one, build a vector of child
2885         layers, and set them in one go.
2886         
2887         * platform/graphics/GraphicsLayer.h:
2888         * platform/graphics/GraphicsLayer.cpp:
2889         (WebCore::GraphicsLayer::setChildren): New method that takes a Vector of child
2890         GraphicsLayers.
2891         
2892         * platform/graphics/mac/GraphicsLayerCA.h: Override setChildren().
2893         * platform/graphics/win/GraphicsLayerCACF.h: Ditto.
2894         * platform/graphics/mac/GraphicsLayerCA.mm: 
2895         (WebCore::GraphicsLayerCA::setChildren): Implement setChildren() to 
2896         set the bit that notes that sublayers changed.
2897         * platform/graphics/win/GraphicsLayerCACF.cpp:
2898         (WebCore::GraphicsLayerCACF::setChildren): Implement setChildren() to 
2899         udpate sublayers, with a note that this is not efficient.
2900         
2901         * rendering/RenderLayerCompositor.h:
2902         * rendering/RenderLayerCompositor.cpp:
2903         (WebCore::RenderLayerCompositor::updateCompositingLayers):
2904         When updating compositing layers, use the faster updateLayerTreeGeometry() if
2905         we know that no layer hierarchy changes are needed, and, at the root, use
2906         the vector returned from rebuildCompositingLayerTree() to attach the root
2907         layer.
2908         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree): Changed to
2909         collect child layers into Vectors of GraphicsLayers, which can be set as
2910         layer children in one go.
2911         (WebCore::RenderLayerCompositor::updateLayerTreeGeometry): Split out from
2912         rebuildCompositingLayerTree() for simplicity, and called when we just need to
2913         update layer geometry, without doing any reparenting.
2914
2915 2009-11-29  Daniel Bates  <dbates@webkit.org>
2916
2917         Reviewed by Adam Barth.
2918
2919         https://bugs.webkit.org/show_bug.cgi?id=31971
2920
2921         Updated comment to reflect latest XSSAuditor bindings.
2922
2923         No functionality was changed. So, no new tests.
2924
2925         * page/XSSAuditor.h:
2926
2927 2009-11-29  Daniel Bates  <dbates@webkit.org>
2928
2929         Reviewed by Eric Seidel.
2930
2931         https://bugs.webkit.org/show_bug.cgi?id=31969
2932
2933         Removes unnecessary #include files.
2934
2935         No functionality was changed. So, no new tests.
2936
2937         * css/CSSComputedStyleDeclaration.cpp: Removed include CachedImage.h, and
2938         Pair.h
2939         * css/CSSCursorImageValue.cpp: Removed include RenderStyle.h
2940         * css/CSSFontFaceSrcValue.cpp: Removed include Node.h
2941         * css/CSSFontSelector.cpp: Removed include NodeList.h
2942         * css/CSSGradientValue.cpp: Removed include GraphicsContext.h, ImageBuffer.h
2943         * css/CSSImageValue.cpp: Removed include RenderStyle.h
2944         * css/CSSImportRule.cpp: Removed include MediaList.h
2945         * css/CSSMutableStyleDeclaration.cpp: Removed include CSSProperty.h
2946         * css/CSSRule.cpp: Removed include CSSStyleSheet.h
2947         * css/CSSStyleSelector.cpp: Removed include CSSFontFace.h,
2948         CSSFontFaceSource.h, and CSSProperty.h
2949         * page/EventSource.h: Removed include EventListener.h
2950
2951 2009-11-29  Daniel Bates  <dbates@webkit.org>
2952
2953         Reviewed by Eric Seidel.
2954
2955         https://bugs.webkit.org/show_bug.cgi?id=31965
2956
2957         Removed #include KeyframeList.h from CSSStyleSelector.h. Instead,
2958         forward declared it.
2959
2960         As a side effect, we need to #include KeyframeList.h in
2961         RenderLayerBacking.cpp.
2962
2963         No functionality was changed. So, no new tests.
2964
2965         * css/CSSStyleSelector.cpp:
2966         * css/CSSStyleSelector.h: Removed #include KeyframeList.h
2967         * rendering/RenderLayerBacking.cpp: Added #include KeyframeList.h
2968
2969 2009-11-29  Shu Chang  <Chang.Shu@nokia.com>
2970
2971         Reviewed by Eric Seidel.
2972
2973         Continue to search for matching node in the case where multiple nodes
2974         have the same id.
2975         https://bugs.webkit.org/show_bug.cgi?id=31428
2976
2977         Test: fast/dom/Element/id-in-node-list-index01.html
2978
2979         * dom/DynamicNodeList.cpp:
2980         (WebCore::DynamicNodeList::itemWithName):
2981
2982 2009-11-29  Daniel Bates  <dbates@webkit.org>
2983
2984         Reviewed by Eric Seidel.
2985
2986         https://bugs.webkit.org/show_bug.cgi?id=31966
2987
2988         Removed #include RenderStyle.h from file KeyframeAnimation.h. Instead,
2989         forward declared it.
2990
2991         No functionality was changed. So, no new tests.
2992
2993         * page/animation/KeyframeAnimation.cpp:
2994         * page/animation/KeyframeAnimation.h:
2995
2996 2009-11-29  Daniel Bates  <dbates@webkit.org>
2997
2998         Unreviewed, fix change log entry date.
2999
3000         For some reason, bugzilla-tool did not update the date in the change
3001         log entry for my last commit (r51468). So, this commit fixes the date
3002         of that entry.
3003
3004 2009-11-29  Daniel Bates  <dbates@webkit.org>
3005
3006         Reviewed by Dan Bernstein.
3007
3008         https://bugs.webkit.org/show_bug.cgi?id=31964
3009
3010         Removed #include StringImpl, StyleImage. Instead, forward declared them.
3011         Also, we can substitute #include <wtf/PassRefPtr.h> for #include PlatformString.h,
3012         since it seems we only really used it to include PassRefPtr.h.
3013
3014         No functionality was changed. So, no new tests.
3015
3016         * rendering/style/ContentData.h:
3017
3018 2009-11-29  Zoltan Horvath  <zoltan@webkit.org>
3019
3020         Reviewed by Eric Seidel.
3021
3022         Allow custom memory allocation control for classes of the rendering and storage directory in WebCore
3023         https://bugs.webkit.org/show_bug.cgi?id=31906
3024
3025         Inherits the following classes from Noncopyable because these are instantiated
3026         by 'new' and no need to be copyable:
3027
3028         class/struct name               - instantiated at: WebCore/'location'
3029
3030         class SQLTransactionClient      - storage/DatabaseThread.cpp:45
3031         class SQLTransactionCoordinator - storage/DatabaseThread.cpp:46
3032         class OriginUsageRecord         - storage/OriginQuotaManager.cpp:66
3033         class DatabaseTracker           - storage/DatabaseTracker.cpp:62
3034         class ScrollbarTheme            - (its child class) rendering/RenderScrollbarTheme.cpp:35
3035         class RenderSelectionInfoBase   - (its child class) rendering/RenderView.cpp:310
3036         class RenderOverflow            - rendering/RenderBox.cpp:2846
3037
3038         Inherits the following classes from FastAllocBase because these are instantiated by 'new':
3039
3040         struct FillLayer                - css/CSSStyleSelector.cpp:197
3041         struct ShadowData               - rendering/style/ShadowData.cpp:35
3042         class CounterContent            - css/CSSStyleSelector.cpp:4111
3043
3044         * platform/ScrollbarTheme.h:
3045         * rendering/RenderOverflow.h:
3046         * rendering/RenderSelectionInfo.h:
3047         * rendering/style/CounterContent.h:
3048         * rendering/style/FillLayer.h:
3049         * rendering/style/ShadowData.h:
3050         * storage/DatabaseTracker.h:
3051         * storage/OriginUsageRecord.h:
3052         * storage/SQLTransactionClient.h:
3053         * storage/SQLTransactionCoordinator.h:
3054
3055 2009-11-28  Adam Barth  <abarth@webkit.org>
3056
3057         Reviewed by Dimitri Glazkov.
3058
3059         [Chromium] Sify compose button alerts error
3060         https://bugs.webkit.org/show_bug.cgi?id=31394
3061
3062         Test: http/tests/security/calling-versus-current.html
3063
3064         We're supposed to use the calling context for security checks.  In JSC
3065         land, this is the lexicalGlobalObject.
3066
3067         * bindings/v8/V8Proxy.cpp:
3068         (WebCore::V8Proxy::canAccessPrivate):
3069
3070 2009-11-27  Shinichiro Hamaji  <hamaji@chromium.org>
3071
3072         Unreviewed Chromium build fix introduced by r51428.
3073
3074         [Chromium] Ignore line-height CSS property for PushButton
3075         https://bugs.webkit.org/show_bug.cgi?id=31712
3076
3077         * rendering/RenderThemeChromiumSkia.cpp:
3078         (WebCore::RenderThemeChromiumSkia::adjustButtonStyle):
3079
3080 2009-11-27  Shinichiro Hamaji  <hamaji@chromium.org>
3081
3082         Unreviewed Chromium test fix by reverting r51413.
3083
3084         [v8] Do not check the thread when accessing DOMDataStore
3085         https://bugs.webkit.org/show_bug.cgi?id=31877
3086
3087         * bindings/v8/V8DOMMap.cpp:
3088         (WebCore::getDOMNodeMap):
3089         (WebCore::getDOMObjectMap):
3090         (WebCore::getActiveDOMObjectMap):
3091         (WebCore::getDOMSVGElementInstanceMap):
3092         (WebCore::getDOMSVGObjectWithContextMap):
3093
3094 2009-11-27  Daniel Bates  <dbates@webkit.org>
3095
3096         Unreviewed, comment fix.
3097
3098         Corrected misspelling of the word "implemented".
3099
3100         * inspector/front-end/InjectedScriptAccess.js:
3101
3102 2009-11-27  Daniel Bates  <dbates@webkit.org>
3103
3104         Reviewed by Adam Barth.
3105
3106         https://bugs.webkit.org/show_bug.cgi?id=31940
3107
3108         Makes the error messages more descriptive when we refuse to load an object/embed or
3109         refuse to load from the document base URL.
3110
3111         * page/XSSAuditor.cpp:
3112         (WebCore::XSSAuditor::canLoadObject): Changed console message to be more descriptive.
3113         (WebCore::XSSAuditor::canSetBaseElementURL): Ditto.
3114
3115 2009-11-27  Yury Semikhatsky  <yurys@chromium.org>
3116
3117         Reviewed by Pavel Feldman.
3118
3119         This is a WebCore part of the fix that allows to view plugin
3120         resources loaded by plugins.
3121
3122         https://bugs.webkit.org/show_bug.cgi?id=31832
3123
3124         * inspector/InspectorController.cpp:
3125         (WebCore::InspectorController::willSendRequest):
3126         (WebCore::InspectorController::didReceiveResponse):
3127         (WebCore::InspectorController::didReceiveContentLength):
3128         (WebCore::InspectorController::didFinishLoading):
3129         (WebCore::InspectorController::didFailLoading):
3130         * inspector/InspectorController.h:
3131         * inspector/InspectorResource.cpp:
3132         (WebCore::InspectorResource::addLength):
3133         * loader/ResourceLoadNotifier.cpp:
3134         (WebCore::ResourceLoadNotifier::didFailToLoad):
3135         (WebCore::ResourceLoadNotifier::dispatchWillSendRequest):
3136         (WebCore::ResourceLoadNotifier::dispatchDidReceiveResponse):
3137         (WebCore::ResourceLoadNotifier::dispatchDidReceiveContentLength):
3138         (WebCore::ResourceLoadNotifier::dispatchDidFinishLoading):
3139
3140 2009-11-27  Yury Semikhatsky  <yurys@chromium.org>
3141
3142         Reviewed by Pavel Feldman.
3143
3144         Instead of generating negative identifiers for cached resources in
3145         InspectorController and extending identifier type from 'unsigned long' to 'long
3146         long' reuse progress tracker from the inspected page to generate those
3147         identifiers. It guarantees that InspectorResources have unique ids since
3148         all of them are generated by that progress tracker.
3149
3150         Added a couple new overloaded methods to Script* objects that accept
3151         long and unsigned long arguments. These types of argumens have already
3152         been passed as long long.
3153
3154         https://bugs.webkit.org/show_bug.cgi?id=31921
3155
3156         * bindings/js/ScriptFunctionCall.cpp:
3157         (WebCore::ScriptFunctionCall::appendArgument):
3158         * bindings/js/ScriptFunctionCall.h:
3159         * bindings/js/ScriptObject.cpp:
3160         (WebCore::ScriptObject::set):
3161         * bindings/js/ScriptObject.h:
3162         * bindings/v8/ScriptFunctionCall.cpp:
3163         (WebCore::ScriptFunctionCall::appendArgument):
3164         * bindings/v8/ScriptFunctionCall.h:
3165         * bindings/v8/ScriptObject.cpp:
3166         (WebCore::ScriptObject::set):
3167         * bindings/v8/ScriptObject.h:
3168         * inspector/InspectorBackend.cpp:
3169         (WebCore::InspectorBackend::dispatchOnInjectedScript):
3170         * inspector/InspectorController.cpp:
3171         (WebCore::InspectorController::InspectorController):
3172         (WebCore::InspectorController::getTrackedResource):
3173         (WebCore::InspectorController::didLoadResourceFromMemoryCache): Use inspected page's ProgressTracker to generate unique identifiers for cached resources in InspectorController.
3174         * inspector/InspectorController.h:
3175         * inspector/InspectorDOMAgent.cpp:
3176         (WebCore::InspectorDOMAgent::buildObjectForNode):
3177         (WebCore::InspectorDOMAgent::buildObjectForEventListener):
3178         * inspector/InspectorFrontend.cpp:
3179         (WebCore::InspectorFrontend::addResource):
3180         (WebCore::InspectorFrontend::updateResource):
3181         (WebCore::InspectorFrontend::removeResource):
3182         (WebCore::InspectorFrontend::updateFocusedNode):
3183         * inspector/InspectorFrontend.h:
3184         * inspector/InspectorResource.cpp:
3185         (WebCore::InspectorResource::InspectorResource):
3186         (WebCore::InspectorResource::createCached):
3187         * inspector/InspectorResource.h: Change InspectorResource identifier type from 'long long' to 'unsigned long'.
3188         (WebCore::InspectorResource::create):
3189         (WebCore::InspectorResource::identifier):
3190         * inspector/TimelineRecordFactory.cpp:
3191         (WebCore::TimelineRecordFactory::createResourceSendRequestRecord):
3192         (WebCore::TimelineRecordFactory::createResourceReceiveResponseRecord):
3193         (WebCore::TimelineRecordFactory::createResourceFinishRecord):
3194
3195 2009-11-26  Shinichiro Hamaji  <hamaji@chromium.org>
3196
3197         Reviewed by Dan Bernstein.
3198
3199         Assertion failure in RenderBlock::positionForPointWithInlineChildren when running fast/inline/relative-positioned-overflow.html
3200         https://bugs.webkit.org/show_bug.cgi?id=29966
3201
3202         When an empty inline element is clicked, the root inline box has
3203         no leaf children. Use the renderer of a normal child instead.
3204
3205         This change resolves Windows port's assertion failure in a layout test.
3206         Also, this fixes the behavior when a user drags the mouse from an
3207         empty inline element to above texts.
3208
3209         Test: editing/selection/last-empty-inline.html
3210
3211         * rendering/RenderBlock.cpp:
3212         (WebCore::RenderBlock::positionForPointWithInlineChildren):
3213
3214 2009-11-26  Kent Tamura  <tkent@chromium.org>
3215
3216         Reviewed by Eric Seidel.
3217
3218         [Chromium] Ignore line-height CSS property specified to push buttons on
3219         Windows and Linux.
3220         https://bugs.webkit.org/show_bug.cgi?id=31712
3221
3222         LayoutTests/fast/forms/control-restrict-line-height.html checks that the
3223         following controls should ignore line-height CSS property.
3224          - <select>
3225          - <input type=button>
3226          - <input type=search>
3227         This change addresses the <input type=button> issue with Chromium/Windows
3228         and Chromium/Linux.
3229         
3230         * rendering/RenderThemeChromiumSkia.cpp: Implement adjustButtonStyle() to ignore line-height.
3231         * rendering/RenderThemeChromiumSkia.h: Declare adjustButtonStyle().
3232
3233 2009-11-26  Kinuko Yasuda  <kinuko@chromium.com>
3234
3235         Reviewed by Eric Seidel.
3236
3237         Remove the special charset meta tag in the clipboard so that
3238         copy-and-paste with interchange breaklines/spaces works correctly
3239         within WebKit.
3240
3241         No new tests.  Layout tests that involve copy-and-paste with
3242         interchange breaklines (like editing/pasteboard/paste-line-endings-00?)
3243         should pass on Mac/Chromium with this fix.
3244
3245         * platform/chromium/ClipboardChromium.cpp:
3246         * platform/chromium/PasteboardChromium.cpp:
3247         (WebCore::Pasteboard::documentFragment):
3248
3249 2009-11-26  İsmail Dönmez  <ismail@namtrac.org>
3250
3251         Reviewed by Eric Seidel.
3252
3253         Compile with QT_NO_WHEELEVENT defined.
3254
3255         * platform/qt/WheelEventQt.cpp:
3256         (WebCore::PlatformWheelEvent::applyDelta):
3257
3258 2009-11-26  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
3259
3260         Reviewed by Oliver Hunt.
3261
3262         Move GOwnPtr* from wtf to wtf/gtk
3263         https://bugs.webkit.org/show_bug.cgi?id=31793
3264
3265         No new tests as there is no functional change.
3266
3267         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp: Change the
3268           path for GOwnPtr.h.
3269         * platform/text/TextEncoding.cpp: Ditto.
3270         * platform/text/gtk/TextCodecGtk.cpp: Ditto.
3271
3272 2009-11-26  Yury Semikhatsky  <yurys@chromium.org>
3273
3274         Not reviewed. Build fix: revert r51421.
3275
3276         * inspector/InspectorController.cpp:
3277         (WebCore::InspectorController::willSendRequest):
3278         (WebCore::InspectorController::didReceiveResponse):
3279         (WebCore::InspectorController::didReceiveContentLength):
3280         (WebCore::InspectorController::didFinishLoading):
3281         (WebCore::InspectorController::didFailLoading):
3282         * inspector/InspectorController.h:
3283         * inspector/InspectorResource.cpp:
3284         (WebCore::InspectorResource::addLength):
3285         * loader/ResourceLoadNotifier.cpp:
3286         (WebCore::ResourceLoadNotifier::didFailToLoad):
3287         (WebCore::ResourceLoadNotifier::dispatchWillSendRequest):
3288         (WebCore::ResourceLoadNotifier::dispatchDidReceiveResponse):
3289         (WebCore::ResourceLoadNotifier::dispatchDidReceiveContentLength):
3290         (WebCore::ResourceLoadNotifier::dispatchDidFinishLoading):
3291
3292 2009-11-26  Yury Semikhatsky  <yurys@chromium.org>
3293
3294         Reviewed by Pavel Feldman.
3295
3296         This is a WebCore part of the fix that allows to view plugin
3297         resources loaded by plugins.
3298
3299         https://bugs.webkit.org/show_bug.cgi?id=31832
3300
3301         * inspector/InspectorController.cpp:
3302         (WebCore::InspectorController::willSendRequest):
3303         (WebCore::InspectorController::didReceiveResponse):
3304         (WebCore::InspectorController::didReceiveContentLength):
3305         (WebCore::InspectorController::didFinishLoading):
3306         (WebCore::InspectorController::didFailLoading):
3307         * inspector/InspectorController.h: Remove unused DocumentLoader parameters from inspector methods.
3308         * inspector/InspectorResource.cpp:
3309         (WebCore::InspectorResource::addLength): Update loading end time when new data are received.
3310         * loader/ResourceLoadNotifier.cpp:
3311         (WebCore::ResourceLoadNotifier::didFailToLoad): Notify InspectorController about the failure.
3312         (WebCore::ResourceLoadNotifier::dispatchWillSendRequest):
3313         (WebCore::ResourceLoadNotifier::dispatchDidReceiveResponse):
3314         (WebCore::ResourceLoadNotifier::dispatchDidReceiveContentLength):
3315         (WebCore::ResourceLoadNotifier::dispatchDidFinishLoading):
3316
3317 2009-11-26  Daniel Bates  <dbates@webkit.org>
3318
3319         Reviewed by Pavel Feldman.
3320
3321         https://bugs.webkit.org/show_bug.cgi?id=21554
3322
3323         Implements support for hovering over <img> src to display the height and width of that image
3324         in a tooltip. Displays both the displayable and natural dimensions of the image.
3325
3326         Test: inspector/elements-img-tooltip.html
3327
3328         * inspector/front-end/ElementsTreeOutline.js:
3329         (WebInspector.ElementsTreeElement.prototype.createTooltipForImageNode): Added.
3330         (WebInspector.ElementsTreeElement.prototype._updateTitle.callback):
3331         (WebInspector.ElementsTreeElement.prototype._updateTitle):
3332         (WebInspector.ElementsTreeElement.prototype._nodeTitleInfo):
3333         * inspector/front-end/ObjectProxy.js:
3334         (WebInspector.ObjectProxy.getPropertiesAsync): Added.
3335         * inspector/front-end/inspector.js:
3336         (WebInspector.linkifyURLAsNode): Added tooltipText argument.
3337         (WebInspector.linkifyURL): Ditto.
3338
3339 2009-11-26  Kevin Ollivier  <kevino@theolliviers.com>
3340
3341         wx build fix after drawPattern API change.
3342
3343         * platform/graphics/wx/ImageWx.cpp:
3344         (WebCore::Image::drawPattern):
3345
3346 2009-11-26  Anton Muhin  <antonm@chromium.org>
3347
3348         Reviewed by Adam Barth.
3349
3350         Use an internal field instead of hidden property to speedup lookup
3351         of entered isolated world.
3352
3353         Plus some inlinings.
3354         https://bugs.webkit.org/show_bug.cgi?id=31884
3355
3356         Covered by layout tests + manual running of some benchmarks as
3357         content scripts.
3358
3359         * bindings/v8/V8DOMWrapper.cpp:
3360         * bindings/v8/V8DOMWrapper.h:
3361         (WebCore::V8DOMWrapper::setDOMWrapper):
3362         * bindings/v8/V8HiddenPropertyName.h:
3363         * bindings/v8/V8IsolatedWorld.cpp:
3364         (WebCore::V8IsolatedWorld::V8IsolatedWorld):
3365         * bindings/v8/V8IsolatedWorld.h:
3366         (WebCore::V8IsolatedWorld::getEntered):
3367         (WebCore::V8IsolatedWorld::getGlobalObject):
3368         * bindings/v8/custom/V8CustomBinding.h:
3369
3370 2009-11-26  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
3371
3372         Reviewed by Kenneth Rohde Christiansen.
3373
3374         [Qt] Corrects build break on Windows.
3375
3376         Rename platform/text/qt/TextBoundaries.cpp to TextBoundariesQt.cpp since
3377         platform/text/TextBoundaries.cpp was compiled instead when compiling with nmake.
3378
3379         * WebCore.pro:
3380         * platform/text/qt/TextBoundariesQt.cpp: Renamed from WebCore/platform/text/qt/TextBoundaries.cpp.
3381         (WebCore::findNextWordFromIndex):
3382         (WebCore::findWordBoundary):
3383
3384 2009-11-26  Anton Muhin  <antonm@chromium.org>
3385
3386         Reviewed by Adam Barth.
3387
3388         Do not check if the thread is main or not when accessing DOMDataStore as currently in Chromium WebKit is used in main thread only.
3389         https://bugs.webkit.org/show_bug.cgi?id=31877
3390
3391         Covered by layout tests and buildbots.
3392
3393         * bindings/v8/V8DOMMap.cpp:
3394         (WebCore::getDOMNodeMap):
3395         (WebCore::getDOMObjectMap):
3396         (WebCore::getActiveDOMObjectMap):
3397         (WebCore::getDOMSVGElementInstanceMap):
3398         (WebCore::getDOMSVGObjectWithContextMap):
3399
3400 2009-11-26  Girish Ramakrishnan  <girish@forwardbias.in>
3401
3402         Reviewed by Holger Freyther.
3403
3404         [Qt] Mac Plugins : Pass mouse position relative to the fake window
3405         
3406         When using off-screen rendering, we need to pass mouse events relative
3407         to the fake window instead of the global position.
3408         
3409         https://bugs.webkit.org/show_bug.cgi?id=31794
3410
3411         * plugins/mac/PluginViewMac.cpp:
3412         (WebCore::PluginView::platformStart):
3413         (WebCore::PluginView::handleMouseEvent):
3414
3415 2009-11-24  Holger Hans Peter Freyther  <zecke@selfish.org>
3416
3417         Reviewed by Eric Seidel.
3418
3419         [Qt] Use QNetworkReply::rawHeaderPairs
3420         https://bugs.webkit.org/show_bug.cgi?id=31826
3421
3422         The QNetworkReply is internally storing the HTTP headers
3423         as a list of pairs. Currently we have to ask the QNetworkReply
3424         to put all header names into a QStringList. Afterwards we will
3425         iterate over this QStringList and ask the QNetworkReply to
3426         give us the value for this header name. The current Qt implementation
3427         is doing a linear to find the header value.
3428
3429         Use a new API to directly access the list of pairs and push
3430         this into WebCore. This avoids doing some allocations and doing
3431         linear searches from within a loop.
3432
3433         * platform/network/qt/QNetworkReplyHandler.cpp:
3434         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
3435
3436 2009-11-21  Holger Hans Peter Freyther  <zecke@selfish.org>
3437
3438         Reviewed by Kenneth Rohde Christiansen.
3439
3440         [Qt] Add Qt specific information of RenderPart
3441         https://bugs.webkit.org/show_bug.cgi?id=31203
3442
3443         The WebCore::Widget of the RenderPart (RenderWidget) might be
3444         backed with a platform widget. Print both the WebCore::Widget
3445         and platform widget state. In the above bug we had a problem
3446         that the WebCore::Widget was invisible but the QWidget was
3447         visible.
3448
3449         * rendering/RenderTreeAsText.cpp:
3450         (WebCore::operator<<): Add special case for RenderPart
3451
3452 2009-11-17  Holger Hans Peter Freyther  <zecke@selfish.org>
3453
3454         Reviewed by Kenneth Rohde Christiansen.
3455
3456         [Qt] Call Widget::setSelfVisible from hide/show
3457         https://bugs.webkit.org/show_bug.cgi?id=31203
3458
3459         Call Widget::setSelfVisible from Widget::show and
3460         Widget::hide and use isParentVisible to decide
3461         if the widget should be shown. This way client
3462         code can rely on isVisible.
3463
3464         Change PluginViewQt::show, PluginViewQt::hide to
3465         call the base class as it is doing the right thing
3466         now. Add an assert verify that platfomWidget and
3467         platformPluginWidget are the same.
3468
3469         * manual-tests/qt/qtplugin.html: Modify manual test
3470         * platform/qt/WidgetQt.cpp:
3471         (WebCore::Widget::show):
3472         (WebCore::Widget::hide):
3473         * plugins/qt/PluginViewQt.cpp:
3474         (WebCore::PluginView::show):
3475         (WebCore::PluginView::hide):
3476
3477 2009-11-24  Holger Hans Peter Freyther  <zecke@selfish.org>
3478
3479         Reviewed by Alexey Proskuryakov.
3480
3481         Fix compilation of REQUEST_DEBUG debug code
3482         https://bugs.webkit.org/show_bug.cgi?id=31850
3483
3484         In r47907 the single parameter KURL constructor to parse
3485         from a WebCore::String was replaced with a two parameter
3486         constructor. I think in this debug case parsing the urls
3487         again is no problem and I have changed the code to use the
3488         two parameter version.
3489
3490         * loader/loader.cpp:
3491         (WebCore::Loader::Host::didFinishLoading):
3492
3493 2009-11-26  Søren Gjesse  <sgjesse@chromium.org>
3494
3495         Reviewed by Pavel Feldman.
3496
3497         [V8] Avoid using JavaScript objects as context data
3498         https://bugs.webkit.org/show_bug.cgi?id=31873
3499
3500         Change the context "data" from a JavaScript object holding the two properties type and value to
3501         a string holding type and value separated by a comma.
3502
3503         * bindings/v8/V8Proxy.cpp:
3504         (WebCore::V8Proxy::setInjectedScriptContextDebugId):
3505         (WebCore::V8Proxy::setContextDebugId):
3506         (WebCore::V8Proxy::contextDebugId):
3507
3508 2009-11-25  Dimitri Glazkov  <dglazkov@chromium.org>
3509
3510         Reviewed by David Levin.
3511
3512         [Chromium] Implement canSetValueAttribute in the API, the clean-up part.
3513         https://bugs.webkit.org/show_bug.cgi?id=31894
3514
3515         * accessibility/chromium/AccessibilityObjectWrapper.h: Added RefCounted decl.
3516         (WebCore::AccessibilityObjectWrapper::AccessibilityObjectWrapper): Removed mis-refcountingness.
3517
3518 2009-11-25  Kenneth Russell  <kbr@google.com>
3519
3520         Reviewed by Oliver Hunt.
3521
3522         Off-by-one error in index validation for drawElements and drawArrays
3523         https://bugs.webkit.org/show_bug.cgi?id=31891
3524
3525         Fixed computation of number of elements for bound array objects.
3526
3527         Test: fast/canvas/webgl/index-validation.html
3528
3529         * html/canvas/WebGLRenderingContext.cpp:
3530         (WebCore::WebGLRenderingContext::vertexAttribPointer):
3531
3532 2009-11-25  Dmitry Titov  <dimich@chromium.org>
3533
3534         Reviewed by David Levin.
3535
3536         Update SharedScript to use eventNames() instead of EventNames()
3537         https://bugs.webkit.org/show_bug.cgi?id=31890
3538
3539         * SharedScript/WebKitSharedScript.cpp:
3540         (WebCore::LoadEventTask::performTask):
3541
3542 2009-11-25  Eric Carlson  <eric.carlson@apple.com>
3543
3544         Reviewed by Simon Fraser.
3545
3546         <rdar://problem/7409331> Windows: Support closed caption in <video> element
3547
3548         Enable closed captions in QuickTime/Windows media engine.
3549
3550         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.cpp:
3551         (WebCore::MediaPlayerPrivate::hasClosedCaptions):
3552         (WebCore::MediaPlayerPrivate::setClosedCaptionsVisible):
3553             New, all through to m_qtMovie.
3554
3555         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.h:
3556             Make all but the destructor private since MediaPlayer call through the media
3557             engine interface.
3558
3559         * platform/graphics/win/QTMovieWin.cpp:
3560         (QTMovieWin::disableUnsupportedTracks):
3561             Use handy new constants for QuickTime track types.
3562         (QTMovieWin::hasClosedCaptions):
3563         (QTMovieWin::setClosedCaptionsVisible):
3564             New, closed caption support.
3565         * platform/graphics/win/QTMovieWin.h:
3566
3567         * rendering/RenderMediaControls.cpp:
3568         (WebCore::RenderMediaControls::paintMediaControlsPart):
3569             Deal with closed caption buttons.
3570
3571         * rendering/RenderThemeWin.cpp:
3572         (WebCore::RenderThemeWin::shouldRenderMediaControlPart):
3573             New, don't ask the media engine if it has closed captions unless the Safari theme will
3574             be able to render the button.
3575         (WebCore::RenderThemeWin::paintMediaToggleClosedCaptionsButton):
3576             New.
3577  &nb