2009-06-30 Adam Langley <agl@google.com>
[WebKit-https.git] / WebCore / ChangeLog
1 2009-06-30  Adam Langley  <agl@google.com>
2
3         Reviewed by Eric Seidel.
4
5         Chromium Linux: use different fonts for each script run.
6
7         https://bugs.webkit.org/show_bug.cgi?id=26853
8
9         Previously, when rendering complex text, we picked a single font which
10         could render all the glyphs needed for the run. However, this meant
11         that sometimes lines were rendered with, for example, [LATIN, THAI,
12         LATIN] and we could end up with a different font for the Latin parts
13         than for lines without Thai in them.
14
15         With this patch, we pick a font for each script run.
16
17         This change is covered by existing layout tests.
18
19         * platform/graphics/chromium/FontLinux.cpp:
20         (WebCore::Font::drawGlyphs):
21         (WebCore::TextRunWalker::TextRunWalker):
22         (WebCore::TextRunWalker::~TextRunWalker):
23         (WebCore::TextRunWalker::nextScriptRun):
24         (WebCore::TextRunWalker::fontPlatformDataForScriptRun):
25         (WebCore::TextRunWalker::setupFontForScriptRun):
26         (WebCore::TextRunWalker::allocHarfbuzzFont):
27         (WebCore::setupForTextPainting):
28         (WebCore::Font::drawComplexText):
29         (WebCore::Font::floatWidthForComplexText):
30         (WebCore::Font::offsetForPositionForComplexText):
31         (WebCore::Font::selectionRectForComplexText):
32         * platform/graphics/chromium/FontPlatformDataLinux.cpp:
33         (WebCore::FontPlatformData::setupPaint):
34
35 2009-06-30  Simon Fraser  <simon.fraser@apple.com>
36
37         Reviewed by Dave Hyatt, Dan Bernstein.
38         
39         <rdar://problem/6191676> Redraw issues scrolling overflow:scroll div with compositing
40
41         There are two parts to this fix. First, if a compositing layer has overflow clipping
42         or a mask, then the compositing layer does not need to be sized to encompass all
43         non-composited children.
44         
45         Second, when scrolling, we have to back up to the compositing ancestor and have
46         it reposition descendant compositing layers, because overflow doesn't follow
47         the z-order tree.
48         
49         Test: compositing/overflow/overflow-scroll.html
50
51         * page/FrameView.cpp:
52         (WebCore::FrameView::layout):
53         Pass the UpdateCompositingLayers flag when updating layers after layout, so that
54         we can reposition compositing layers if we're not about to do a layer rebuild.
55         
56         * rendering/RenderLayer.cpp:
57         (WebCore::RenderLayer::updateLayerPositions):
58         Only update compositing layers if the flag is set.
59         
60         (WebCore::RenderLayer::scrollToOffset):
61         Do compositing layer updates from the compositing ancestor in one fell swoop.
62
63         * rendering/RenderLayer.h:
64         Replace the unused FullUpdate flag with one that allows us to specify whether
65         compositing layers should be updated.
66         
67         * rendering/RenderLayerBacking.cpp:
68         (WebCore::RenderLayerBacking::updateAfterLayout):
69         * rendering/RenderLayerBacking.h:
70         New param that we can pass to updateCompositingDescendantGeometry to control
71         whether the update goes deep.
72
73         * rendering/RenderLayerCompositor.cpp:
74         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
75         We can return earlier if this is not a self-painting layer.
76         If the layer has overflow clip or a mask, then the composited bounds are just the
77         local bounds, excluding descendants.
78         
79         (WebCore::RenderLayerCompositor::updateCompositingDescendantGeometry):
80         * rendering/RenderLayerCompositor.h:
81         Renamed from updateCompositingChildrenGeometry, and added a flag that allows
82         us to do a deep update.
83
84 2009-06-30  Alexey Proskuryakov  <ap@webkit.org>
85
86         Reviewed by Dan Bernstein.
87
88         https://bugs.webkit.org/show_bug.cgi?id=26764
89         Uncaught NOT_FOUND_ERR: DOMException 8 loading empty text file
90
91         Test: fast/parser/empty-text-resource.html
92
93         * loader/TextDocument.cpp: (WebCore::TextTokenizer::finish): Create document tree if it
94         hasn't been created yet.
95
96 2009-06-30  Brian Weinstein  <bweinstein@apple.com>
97
98         Reviewed by Adam Roben.
99
100         Renamed scrollbarUnderPoint to scrollbarAtPoint.
101
102         * page/EventHandler.cpp:
103         (WebCore::EventHandler::hitTestResultAtPoint):
104         (WebCore::EventHandler::handleMousePressEvent):
105         (WebCore::EventHandler::handleMouseMoveEvent):
106         * platform/ScrollView.cpp:
107         (WebCore::ScrollView::scrollbarAtPoint):
108         * platform/ScrollView.h:
109         * platform/chromium/PopupMenuChromium.cpp:
110         (WebCore::PopupListBox::handleMouseDownEvent):
111         (WebCore::PopupListBox::handleMouseMoveEvent):
112
113 2009-06-30  Oliver Hunt  <oliver@apple.com>
114
115         Reviewed by Geoff Garen.
116
117         <rdar://problem/6960286> CrashTracer: [REGRESSION] 1120 crashes in Safari at com.apple.WebCore WebCore::JSLazyEventListener::parseCode const + 62
118
119         <select> elements and other elements the produce popups can keep their popups
120         live across a page load.  If this occurs and the <select> element has an
121         onchange handler it is possible to get into a state where we try to execute
122         JS on a page that no longer has an execution context. 
123
124         * bindings/js/JSLazyEventListener.cpp:
125         (WebCore::JSLazyEventListener::parseCode):
126           Be paranoid and add a null check, but assert as well because we shouldn't
127           actually get to this point.
128         * rendering/RenderMenuList.cpp:
129         (WebCore::RenderMenuList::valueChanged):
130
131 2009-06-30  Drew Wilson  <atwilson@google.com>
132
133         Reviewed by David Levin.
134
135         <https://bugs.webkit.org/show_bug.cgi?id=25435>
136
137         Added support for sending MessagePorts to/from Workers via postMessage().
138
139         * bindings/js/JSWorkerContextCustom.cpp:
140         (WebCore::JSWorkerContext::messageChannel):
141         Exposes MessageChannel constructor WorkerContext.
142         * bindings/js/JSWorkerCustom.cpp:
143         * bindings/v8/custom/V8MessageChannelConstructor.cpp:
144         (WebCore::CALLBACK_FUNC_DECL):
145         Now correctly handles being instantiated from within a Worker.
146        * platform/CrossThreadCopier.h:
147         (WebCore::GenericWorkerTaskTraits<PassOwnPtr>):
148         Added support for passing PassOwnPtr as argument to GenericWorkerTask
149        * workers/GenericWorkerTask.h:
150         (WebCore::):
151         * workers/Worker.cpp:
152         (WebCore::Worker::postMessage):
153         Now handles disentangling/entangling MessagePorts sent to/from via postMessage.
154         (WebCore::Worker::dispatchMessage):
155         * workers/Worker.h:
156         * workers/Worker.idl:
157         Added an optional MessagePort argument to postMessage()
158         * workers/WorkerContext.cpp:
159         (WebCore::WorkerContext::hasPendingActivity):
160         Workers now report pending activity whenever there are remotely entangled ports.
161         (WebCore::WorkerContext::postMessage):
162         Now handles disentangling/entangling MessagePorts sent to/from via postMessage.
163         (WebCore::WorkerContext::dispatchMessage):
164         * workers/WorkerContext.h:
165         * workers/WorkerContext.idl:
166         Added an optional MessagePort argument to postMessage()
167         * workers/WorkerContextProxy.h:
168         * workers/WorkerMessagingProxy.cpp:
169         Updated messaging infrastructure to transport an optional MessagePort/MessagePortChannel.
170         (WebCore::MessageWorkerContextTask::create):
171         (WebCore::MessageWorkerContextTask::MessageWorkerContextTask):
172         (WebCore::MessageWorkerContextTask::performTask):
173         (WebCore::MessageWorkerTask::create):
174         (WebCore::MessageWorkerTask::MessageWorkerTask):
175         (WebCore::MessageWorkerTask::performTask):
176         (WebCore::WorkerMessagingProxy::postMessageToWorkerObject):
177         (WebCore::WorkerMessagingProxy::postMessageToWorkerContext):
178         * workers/WorkerMessagingProxy.h:
179         Added additional postMessage() API that accepts a MessagePort
180         * workers/WorkerObjectProxy.h:
181         Added additional postMessage() API that accepts a MessagePort
182
183 2009-06-30  Adam Langley  <agl@google.com>
184
185         Reviewed by Eric Seidel.
186
187         Chromium: Add complex text support on Linux.
188
189         https://bugs.webkit.org/show_bug.cgi?id=25068
190
191         This patch adds complex text support on Linux using Harfbuzz. It's not
192         the fastest code possible: some caching of font tables will certainly
193         be required. However, it's probably the simplest code that works.
194
195         This will require checking in new baselines in the Chromium tree for
196         those layout tests which now pass.
197
198         * platform/graphics/chromium/FontLinux.cpp:
199         (WebCore::Font::drawGlyphs):
200         (WebCore::truncateFixedPointToInteger):
201         (WebCore::TextRunWalker::TextRunWalker):
202         (WebCore::TextRunWalker::~TextRunWalker):
203         (WebCore::TextRunWalker::reset):
204         (WebCore::TextRunWalker::setXOffsetToZero):
205         (WebCore::TextRunWalker::rtl):
206         (WebCore::TextRunWalker::setBackwardsIteration):
207         (WebCore::TextRunWalker::nextScriptRun):
208         (WebCore::TextRunWalker::glyphs):
209         (WebCore::TextRunWalker::length):
210         (WebCore::TextRunWalker::xPositions):
211         (WebCore::TextRunWalker::advances):
212         (WebCore::TextRunWalker::width):
213         (WebCore::TextRunWalker::logClusters):
214         (WebCore::TextRunWalker::numCodePoints):
215         (WebCore::TextRunWalker::widthOfFullRun):
216         (WebCore::TextRunWalker::allocHarfbuzzFont):
217         (WebCore::TextRunWalker::deleteGlyphArrays):
218         (WebCore::TextRunWalker::createGlyphArrays):
219         (WebCore::TextRunWalker::expandGlyphArrays):
220         (WebCore::TextRunWalker::shapeGlyphs):
221         (WebCore::TextRunWalker::setGlyphXPositions):
222         (WebCore::setupForTextPainting):
223         (WebCore::fontPlatformDataForTextRun):
224         (WebCore::Font::drawComplexText):
225         (WebCore::Font::floatWidthForComplexText):
226         (WebCore::glyphIndexForXPositionInScriptRun):
227         (WebCore::Font::offsetForPositionForComplexText):
228         (WebCore::Font::selectionRectForComplexText):
229         * platform/graphics/chromium/HarfbuzzSkia.cpp: Added.
230         (WebCore::SkiaScalarToHarfbuzzFixed):
231         (WebCore::stringToGlyphs):
232         (WebCore::glyphsToAdvances):
233         (WebCore::canRender):
234         (WebCore::getOutlinePoint):
235         (WebCore::getGlyphMetrics):
236         (WebCore::getFontMetric):
237         (WebCore::harfbuzzSkiaGetTable):
238
239 2009-06-30  Eric Carlson  <eric.carlson@apple.com>
240
241         Reviewed by Simon Fraser.
242
243         <rdar://problem/7019799> Slow loading MediaDocument can fall back to plug-in unnecessarily
244
245         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
246         (WebCore::MediaPlayerPrivate::updateStates):
247             Always fall back to a plug-in if m_hasUnsupportedTracks is set.
248         (WebCore::MediaPlayerPrivate::disableUnsupportedTracks):
249             Set m_hasUnsupportedTracks if we disable a track.
250
251 2009-06-30  Nate Chapin  <japhet@chromium.org>
252
253         Reviewed by Dimitri Glazkov.
254
255         Fix inverted if/else that's causing a layout test in src.chromium.org to fail.
256
257         https://bugs.webkit.org/show_bug.cgi?id=26820
258
259         * bindings/v8/V8Proxy.cpp:
260         (WebCore::GCPrologueVisitor::visitDOMWrapper): if (port2), not if (!port2).
261
262 2009-06-30  Dan Bernstein  <mitz@apple.com>
263
264         Reviewed by Dave Hyatt.
265
266         - fix <rdar://problem/6946611> REGRESSION (r30673): Shade10:" D_Snap
267           to Grid" window is clipping
268
269         Added an app-specific quirk to revert the behavior of <link> elements
270         to the way it was before r30673, namely that if the rel attribute
271         is not "stylesheet" but the type attribute contains "text/css", the
272         link behaves as a stylesheet link.
273
274         * WebCore.base.exp: Exported setTreatsAnyTextCSSLinkAsStylesheet().
275         * html/HTMLLinkElement.cpp:
276         (WebCore::HTMLLinkElement::process): Check
277             Settings::treatsAnyTextCSSLinkAsStylesheet() and if true, allow a
278             style sheet link if the type contains "text/css".
279         * page/Settings.cpp:
280         (WebCore::Settings::Settings):
281             Initialize m_treatsAnyTextCSSLinkAsStylesheet.
282         (WebCore::Settings::setTreatsAnyTextCSSLinkAsStylesheet): Added.
283         * page/Settings.h:
284         (WebCore::Settings::treatsAnyTextCSSLinkAsStylesheet): Added.
285
286 2009-06-30  Adrien Nader  <camaradetux@gmail.com>
287
288         Reviewed by Xan Lopez.
289
290         Fix typo in GNUMakefile.am: it reads WebCOre instead of WebCore.
291
292         * GNUmakefile.am:
293
294 2009-06-30  Jan Michael Alonzo  <jmalonzo@webkit.org>
295
296         Reviewed by Xan Lopez.
297
298         [Gtk] Turn on ENABLE_DATAGRID so we can run the layout tests.
299
300         * GNUmakefile.am:
301
302 2009-06-30  Raju Kunnath  <raju.kunnath@nokia.com>
303
304         Reviewed by Simon Hausmann.
305
306         <https://bugs.webkit.org/show_bug.cgi?id=26752>
307
308         [Qt] Windows release build issue with Qt4.5 due to -GL flag on msvc2005 and msvc2008. 
309
310         * WebCore.pro: Removed -GL compiler option for win32-msvc2005|win32-msvc2008.
311
312 2009-06-30  Xan Lopez  <xlopez@igalia.com>
313
314         Reviewed by Jan Alonzo.
315
316         Initialize member variables in the right order. Fixes compiler
317         warning.
318
319         * platform/image-decoders/bmp/BMPImageReader.cpp:
320         (WebCore::BMPImageReader::BMPImageReader):
321
322 2009-06-29  Xan Lopez  <xlopez@igalia.com>
323
324         Reviewed by David Levin.
325
326         https://bugs.webkit.org/show_bug.cgi?id=26831
327         Fix compiler warning in WorkerLoaderProxy.h
328
329         Forward declaration of a class within a class is not allowed,
330         since the compiler can't know if the declaration is legal at that
331         point. This gives the following compiler warning:
332
333         ../../WebCore/workers/WorkerLoaderProxy.h:40: warning: declaration
334         "class WebCore::ScriptExecutionContext::Task" does not declare
335         anything
336
337         Include the full ScriptExecutionHeader header instead.
338
339         * workers/WorkerLoaderProxy.h:
340
341 2009-06-29  Xan Lopez  <xlopez@igalia.com>
342
343         Reviewed by Jan Alonzo.
344
345         Remove unused function.
346
347         * plugins/gtk/PluginPackageGtk.cpp:
348
349 2009-06-29  Simon Fraser  <simon.fraser@apple.com>
350
351         Reviewed by Dan Bernstein.
352
353         Change RenderLayer::updateLayerPositions() to use a bitmask instead of two
354         boolean arguments. FullUpdate is unused at present, but will be used soon.
355
356         * page/FrameView.cpp:
357         (WebCore::FrameView::layout):
358         * rendering/RenderLayer.cpp:
359         (WebCore::RenderLayer::updateLayerPositions):
360         (WebCore::RenderLayer::scrollToOffset):
361         * rendering/RenderLayer.h:
362         (WebCore::RenderLayer::):
363
364 2009-06-29  Nate Chapin  <japhet@chromium.org>
365
366         Reviewed by Dimitri Glazkov.
367
368         Fix one more bad merge in V8Proxy.
369
370         https://bugs.webkit.org/show_bug.cgi?id=26819
371
372         * bindings/v8/V8Proxy.cpp:
373         (WebCore::V8Proxy::setDOMException): setDOMExceptionHelper() instead of convertToV8Object().
374
375 2009-06-29  Sam Weinig  <sam@webkit.org>
376
377         Reviewed by Mark Rowe.
378
379         Remove more unused scons support.
380
381         * SConstruct: Removed.
382
383 2009-06-29  Sam Weinig  <sam@webkit.org>
384
385         Reviewed by Dave Hyatt.
386
387         Fix some incorrect create functions.
388
389         * html/DataGridColumn.h:
390         (WebCore::DataGridColumn::create):
391         * html/DataGridColumnList.h:
392         (WebCore::DataGridColumnList::create):
393
394 2009-06-29  Sam Weinig  <sam@webkit.org>
395
396         Reviewed by Dave Hyatt.
397
398         Remove initialize method from DataGridDataSource and add
399         DOMDataGridDataSource.
400
401         * GNUmakefile.am:
402         * WebCore.pro:
403         * WebCore.vcproj/WebCore.vcproj:
404         * WebCore.xcodeproj/project.pbxproj:
405         * WebCoreSources.bkl:
406         * bindings/js/JSDataGridDataSource.cpp:
407         * bindings/js/JSDataGridDataSource.h:
408         * bindings/js/JSHTMLDataGridElementCustom.cpp:
409         (WebCore::JSHTMLDataGridElement::setDataSource):
410         * html/DOMDataGridDataSource.cpp: Added.
411         (WebCore::DOMDataGridDataSource::DOMDataGridDataSource):
412         (WebCore::DOMDataGridDataSource::~DOMDataGridDataSource):
413         * html/DOMDataGridDataSource.h: Added.
414         (WebCore::DOMDataGridDataSource::create):
415         (WebCore::DOMDataGridDataSource::isDOMDataGridDataSource):
416         (WebCore::asDOMDataGridDataSource):
417         * html/DataGridDataSource.h:
418         (WebCore::DataGridDataSource::isDOMDataGridDataSource):
419         (WebCore::DataGridDataSource::isJSDataGridDataSource):
420         * html/HTMLDataGridElement.cpp:
421         (WebCore::HTMLDataGridElement::HTMLDataGridElement):
422         (WebCore::HTMLDataGridElement::setDataSource):
423         (WebCore::HTMLDataGridElement::dataSource):
424         * html/HTMLDataGridElement.h:
425
426 2009-06-29  Nate Chapin  <japhet@chromium.org>
427
428         Reviewed by Dimitri Glazkov.
429
430         Fix a couple of bad merge items from my previous V8Proxy patch.
431
432         https://bugs.webkit.org/show_bug.cgi?id=26813
433
434         * bindings/v8/V8Collection.h:
435         (WebCore::nodeCollectionNamedPropertyGetter):  Fix a bad function name that slipped through.
436         * bindings/v8/V8Proxy.cpp:
437         (WebCore::V8Proxy::setDOMException):  Fix a bad merge that caused a couple of lines of extraneous, breaking code to get in.
438
439 2009-06-29  Chris Marrin  <cmarrin@apple.com>
440
441         Reviewed by Simon Fraser  <simon.fraser@apple.com>.
442
443         https://bugs.webkit.org/show_bug.cgi?id=26706
444
445         Fixed crash due to dereference of m_toStyle
446
447         * page/animation/ImplicitAnimation.cpp:
448         (WebCore::ImplicitAnimation::isTargetPropertyEqual):
449
450 2009-06-29  Eric Carlson  <eric.carlson@apple.com>
451
452         Reviewed by Simon Fraser.
453
454         <rdar://problem/7014813> Ask media engine if a movie is streamed or downloaded.
455
456         * WebCore.base.exp: 
457             Export _wkQTMovieGetType
458
459         * platform/graphics/MediaPlayer.cpp:
460         (WebCore::MediaPlayer::hasSingleSecurityOrigin):
461             Move to keep with other non-callback functions.
462         (WebCore::MediaPlayer::movieLoadType):
463             New, returns the movie type.
464         * platform/graphics/MediaPlayer.h:
465             Declare MovieLoadType enum and movieLoadType method.
466
467         * platform/graphics/MediaPlayerPrivate.h:
468         (WebCore::MediaPlayerPrivateInterface::movieLoadType):
469             Default implementation of movieLoadType
470
471         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
472         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
473         (WebCore::MediaPlayerPrivate::createQTMovie):
474             Don't base m_isStreaming on protocol, there are other types of streaming movies.
475         (WebCore::MediaPlayerPrivate::maxTimeBuffered):
476             Don't assume all streams are unbuffered.
477         (WebCore::MediaPlayerPrivate::updateStates):
478             Update m_isStreaming once we have metadata.
479         (WebCore::MediaPlayerPrivate::disableUnsupportedTracks):
480             Tracks that are disabled to begin with shouldn't be included in m_enabledTrackCount.
481         (WebCore::MediaPlayerPrivate::movieLoadType):
482             New, return movie type.
483
484         * platform/mac/WebCoreSystemInterface.h:
485         * platform/mac/WebCoreSystemInterface.mm:
486             Add wkQTMovieGetType.
487
488 2009-06-29  Alice Liu  <alice.liu@apple.com>
489
490         Fixed <rdar://problem/6930280> Reproducible crash at USA Today photo gallery
491
492         Reviewed by Anders Carlsson.
493
494         No test added because the crash requires a flash plugin
495
496         * plugins/win/PluginMessageThrottlerWin.cpp:
497         Rely on the hWnd of the plugin to tell us whether the PluginView has 
498         been deleted during execution of its wndProc.
499         (WebCore::PluginMessageThrottlerWin::messageThrottleTimerFired):
500
501 2009-06-29  Dmitry Titov  <dimich@chromium.org>
502
503         Reviewed by David Levin.
504
505         https://bugs.webkit.org/show_bug.cgi?id=26811
506          [Chromium] Remove a flag and functions used to enable workers in runtime.
507
508         * bindings/v8/WorkerContextExecutionProxy.cpp:
509         * bindings/v8/WorkerContextExecutionProxy.h:
510
511 2009-06-29  Simon Fraser  <simon.fraser@apple.com>
512
513         Reviewed by Dave Hyatt.
514         
515         <rdar://problem/6976712> Text antialiasing problems when rendering into compositing layers.
516         
517         Improve the appearance of text in compositing layers by making use of
518         CA's layer geometry flipping, rather that doing it ourselves with a flip
519         transform. This allows CG to use font autohinting in the layer text.
520
521         * platform/graphics/GraphicsLayer.h:
522         (WebCore::GraphicsLayer::setGeometryOrientation):
523         (WebCore::GraphicsLayer::geometryOrientation):
524         New methods to set whether this layer uses flipped geometry.
525         
526         * platform/graphics/mac/GraphicsLayerCA.h:
527         * platform/graphics/mac/GraphicsLayerCA.mm:
528         (WebCore::GraphicsLayerCA::setGeometryOrientation):
529         (WebCore::GraphicsLayerCA::geometryOrientation):
530         Subclass in order to call into CA
531         
532         (WebCore::GraphicsLayerCA::setContentsLayer):
533         Now that CA is doing the geometry flipping, we no longer need to flip the content
534         layers for image and video manually
535         
536         * rendering/RenderLayerCompositor.cpp:
537         (WebCore::RenderLayerCompositor::ensureRootPlatformLayer):
538         Turn on flipping on the root layer.
539
540 2009-06-29  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
541
542         Reviewed by Adam Treat.
543
544         Fixes: https://bugs.webkit.org/show_bug.cgi?id=26246
545
546         Implement most WML specific <select> element features.
547         Add 'iname' / 'ivalue' support and support variable references.
548
549         Add two tests covering most select/variable related functionality.
550         Needs more tests when adding full 'iname' / 'ivalue' support (used in conjuction with onpick).
551
552         Tests: http/tests/wml/post-data-to-server.html
553                wml/select-element-variables.html
554
555         * dom/SelectElement.cpp:
556         (WebCore::SelectElement::optionCount): Refactored from HTMLSelectElement::length() for use within HTML & WML.
557         * dom/SelectElement.h:
558         * html/HTMLSelectElement.cpp:
559         (WebCore::HTMLSelectElement::length): Use new SelectElement::optionCount() function. (no functional changes for HTML).
560         * wml/WMLCardElement.cpp:
561         (WebCore::WMLCardElement::handleIntrinsicEventIfNeeded): Activated commented code taking care of WMLSelectElement initialization.
562         * wml/WMLSelectElement.cpp: Add a bunch of new code handling WML specific feature processing.
563         (WebCore::WMLSelectElement::title):
564         (WebCore::WMLSelectElement::formControlName):
565         (WebCore::WMLSelectElement::defaultEventHandler):
566         (WebCore::WMLSelectElement::selectInitialOptions):
567         (WebCore::WMLSelectElement::calculateDefaultOptionIndices):
568         (WebCore::WMLSelectElement::selectDefaultOptions):
569         (WebCore::WMLSelectElement::initializeVariables):
570         (WebCore::WMLSelectElement::updateVariables):
571         (WebCore::WMLSelectElement::parseIndexValueString):
572         (WebCore::WMLSelectElement::valueStringToOptionIndices):
573         (WebCore::WMLSelectElement::optionIndicesToValueString):
574         (WebCore::WMLSelectElement::optionIndicesToString):
575         (WebCore::WMLSelectElement::name):
576         (WebCore::WMLSelectElement::value):
577         (WebCore::WMLSelectElement::iname):
578         (WebCore::WMLSelectElement::ivalue):
579         * wml/WMLSelectElement.h:
580
581 2009-06-29  David Hyatt  <hyatt@apple.com>
582
583         Reviewed by Adam Roben.
584
585         Put <datagrid> behind an ifdef.
586
587         * Configurations/FeatureDefines.xcconfig:
588         * bindings/js/JSDataGridColumnListCustom.cpp:
589         * bindings/js/JSDataGridDataSource.cpp:
590         * bindings/js/JSDataGridDataSource.h:
591         * bindings/js/JSHTMLDataGridElementCustom.cpp:
592         * html/DataGridColumn.cpp:
593         * html/DataGridColumn.h:
594         * html/DataGridColumn.idl:
595         * html/DataGridColumnList.cpp:
596         * html/DataGridColumnList.h:
597         * html/DataGridColumnList.idl:
598         * html/DataGridDataSource.h:
599         * html/HTMLDataGridCellElement.cpp:
600         * html/HTMLDataGridCellElement.h:
601         * html/HTMLDataGridCellElement.idl:
602         * html/HTMLDataGridColElement.cpp:
603         * html/HTMLDataGridColElement.h:
604         * html/HTMLDataGridColElement.idl:
605         * html/HTMLDataGridElement.cpp:
606         * html/HTMLDataGridElement.h:
607         * html/HTMLDataGridElement.idl:
608         * html/HTMLDataGridRowElement.cpp:
609         * html/HTMLDataGridRowElement.h:
610         * html/HTMLDataGridRowElement.idl:
611         * html/HTMLTagNames.in:
612         * page/DOMWindow.idl:
613         * rendering/RenderDataGrid.cpp:
614         * rendering/RenderDataGrid.h:
615
616 2009-06-29  Simon Hausmann  <simon.hausmann@nokia.com>
617
618         Reviewed by Ariya Hidayat and Adam Roben.
619
620         Fix compilation with MINGW. Ported MSVC inline assembly to
621         GNU inline assembly. Also fixed casting errors where gcc
622         refused to cast a pointer-to-function to a pointer-to-object,
623         without an intermediate cast to a non-pointer type.
624
625         * plugins/win/PluginViewWin.cpp:
626         (WebCore::PluginView::hookedBeginPaint):
627         (WebCore::PluginView::hookedEndPaint):
628         (WebCore::hook):
629         (WebCore::setUpOffscreenPaintingHooks):
630
631 2009-06-26  John Sullivan  <sullivan@apple.com>
632
633         Added Speech submenu to context menu on Mac when there's a non-editable selection
634         (it was already present when there's an editable selection). 
635         Also added support for disabling "Stop Speaking" when there is no speaking to stop.
636
637         Reviewed by Tim Hatcher.
638
639         * loader/EmptyClients.h:
640         (WebCore::EmptyContextMenuClient::isSpeaking):
641         implemented this new virtual function to return false
642         
643         * page/ContextMenuClient.h:
644         declared this new pure virtual function
645         
646         * platform/ContextMenu.cpp:
647         (WebCore::ContextMenu::populate):
648         insert Speech item (after a separator) on Mac when there's selected non-editable text
649         (WebCore::ContextMenu::checkOrEnableIfNeeded):
650         enable Stop Speaking item only if the context menu client returns true for isSpeaking()
651
652 2009-06-28  Dan Bernstein  <mitz@apple.com>
653
654         Reviewed by Simon Fraser.
655
656         - fix https://bugs.webkit.org/show_bug.cgi?id=26783
657           <rdar://problem/7014543> REGRESSION (r45296): Subfolders not displayed
658           in MobileMe iDisk Web App
659
660         Test: added a case to fast/dom/Element/scrollWidth.html
661
662         Ensure that scroll{Width, Height} is greater or equal to
663         client{Width, Height}.
664
665         * rendering/RenderBox.cpp:
666         (WebCore::RenderBox::scrollWidth):
667         (WebCore::RenderBox::scrollHeight):
668
669 2009-06-27  Simon Fraser  <simon.fraser@apple.com>
670
671         Reviewed by Eric Seidel.
672
673         https://bugs.webkit.org/show_bug.cgi?id=26780
674         
675         Do not make compositing layers for non-self-painting RenderLayers,
676         since these exist only to push a clip onto the clipping stack. If such
677         a layer gets compositied for some other reason, it should not paint.
678         
679         Also ensure that we update composited layer positions correctly
680         inside overflow:scroll layers. We can't assume that the contents
681         are child layers, so we have to go up to the compositing ancestor,
682         and tell it to update all its child layer positions as we do 
683         after layout.
684
685         Tests: compositing/layers-inside-overflow-scroll.html
686                compositing/self-painting-layers.html
687
688         * rendering/RenderLayer.cpp:
689         (WebCore::RenderLayer::scrollToOffset):
690         * rendering/RenderLayerBacking.cpp:
691         (WebCore::RenderLayerBacking::paintIntoLayer):
692         * rendering/RenderLayerCompositor.cpp:
693         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
694         (WebCore::RenderLayerCompositor::needsToBeComposited):
695
696 2009-06-28  Luke Kenneth Casson Leighton  <lkcl@lkcl.net>
697
698         Reviewed by Eric Seidel.
699
700         PurgeableBuffer #defines leave out functions on gtk MacOSX 10.4 build
701         https://bugs.webkit.org/show_bug.cgi?id=23057
702
703         Define these functions for Gtk as well.
704
705         * platform/PurgeableBuffer.h:
706
707 2009-06-28  Nate Chapin  <japhet@chromium.org>
708
709         Reviewed by Dimitri Glazkov.
710
711         Update CodeGeneratorV8.pm to match the new api for V8Proxy.
712
713         https://bugs.webkit.org/show_bug.cgi?id=26765
714
715         * bindings/scripts/CodeGeneratorV8.pm: Match the current version of V8Proxy.
716
717 2009-06-28  Nicolas Sylvain  <nsylvain@chromium.org>
718
719         Reviewed by Dimitri Glazkov.
720
721         If loading a font fails because of the sandbox, we ask the browser process to 
722         try to load it by calling ensureFontLoaded. If it still fails after 
723         ensureFontLoaded, we hit a ASSERT_NOT_REACHED. 
724
725         This case happens once in a while during browser shutdown. The browser will 
726         queue a message to the renderer to shutdown, and will then stop answering sync 
727         messages from the renderer. If the renderer is still loading a page during this 
728         time, it might try to call the browser process to ask to load a font. The 
729         browser process will ignore the request, and the font will fail to load, even 
730         after the second try. 
731
732         This is unfortunate, but there is no real risk here, since the renderer will be 
733         going away as soon as it processes another message. 
734
735         This can't be layout tested as it depends on the sandbox. 
736
737         https://bugs.webkit.org/show_bug.cgi?id=26743 
738
739         * platform/graphics/chromium/FontChromiumWin.cpp:
740         * platform/graphics/chromium/FontPlatformDataChromiumWin.cpp:
741         * platform/graphics/chromium/GlyphPageTreeNodeChromiumWin.cpp:
742         * platform/graphics/chromium/SimpleFontDataChromiumWin.cpp:
743
744 2009-06-28  John Abd-El-Malek  <jam@chromium.org>
745
746         Reviewed by Eric Seidel.
747
748         https://bugs.webkit.org/show_bug.cgi?id=15457
749
750         Test: plugins/netscape-plugin-map-data-to-src.html
751
752         Fix problems with Real or WMP plugins not displaying because "data" was set
753         on the OBJECT tag instead of "src".  This is based on what Firefox does, see
754         http://mxr.mozilla.org/mozilla-central/source/layout/generic/nsObjectFrame.cpp#3045
755
756         * rendering/RenderPartObject.cpp:
757         (WebCore::mapDataParamToSrc):
758         (WebCore::RenderPartObject::updateWidget):
759
760 2009-06-27  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
761
762         Reviewed by Jan Alonzo.
763
764         [Qt] Build fix after r45290
765         https://bugs.webkit.org/show_bug.cgi?id=26769
766
767         * WebCore.pro:
768
769 2009-06-27  Emilio Pozuelo Monfort  <pochu27@gmail.com>
770
771         Reviewed by Jan Alonzo.
772
773         [GTK] Don't use deprecated GTK+ symbols.
774         https://bugs.webkit.org/show_bug.cgi?id=26583
775
776         * plugins/gtk/gtk2xtbin.c:
777         (gtk_xtbin_class_init):
778         (gtk_xtbin_new):
779         (gtk_xtbin_destroy):
780
781 2009-06-27  Simon Fraser  <simon.fraser@apple.com>
782
783         Reviewed by Dan Bernstein.
784
785         https://bugs.webkit.org/show_bug.cgi?id=26780
786         
787         Fix up previous change. When computeCompositingRequirements() determines
788         that the current layer is composited, it needs to inform its parent
789         by setting compositingState.m_subtreeIsCompositing() to true. That didn't
790         always happen after the previous patch. Clarified the logic here.
791         
792         * rendering/RenderLayerCompositor.cpp:
793         (WebCore::CompositingState::CompositingState):
794         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
795
796 2009-06-27  Simon Fraser  <simon.fraser@apple.com>
797
798         Reviewed by Dan Bernstein.
799
800         https://bugs.webkit.org/show_bug.cgi?id=26780
801         
802         First part: fix the RenderLayer::hasCompositingDescendant() flag to be set
803         correctly.
804
805         * rendering/RenderLayerCompositor.cpp:
806         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
807         Do not unconditionally set compositingState.m_subtreeIsCompositing, because
808         that can clobber the value from an earlier sibling. Add some more comments.
809         
810         Remove a final use of Vector iterators.
811         
812         (WebCore::RenderLayerCompositor::recursiveRepaintLayerRect):
813         Move the normalFlowList() processing outside the test for isStackingContext().
814
815 2009-06-27  Dan Bernstein  <mitz@apple.com>
816
817         Reviewed by Simon Fraser and Antti Koivisto.
818
819         - make paintFillLayerExtended() non-virtual and remove its clipY and
820           clipH parameters
821
822         These parameters were computed and passed along to
823         paintFillLayerExtended in order to vertically constrain the rect fill to
824         the damage rect, because Qt cannot paint tall rectangles (see
825         <http://websvn.kde.org/?view=rev&revision=42721>). Since the damage rect
826         is passed along in the PaintInfo, the extra parameters are redundant,
827         and the intersection can just take place in paintFillLayerExtended().
828
829         * rendering/InlineFlowBox.cpp:
830         (WebCore::InlineFlowBox::paintFillLayers):
831         (WebCore::InlineFlowBox::paintFillLayer):
832         (WebCore::InlineFlowBox::paintBoxDecorations):
833         (WebCore::InlineFlowBox::paintMask):
834         * rendering/InlineFlowBox.h:
835         * rendering/RenderBox.cpp:
836         (WebCore::RenderBox::paintRootBoxDecorations):
837         (WebCore::RenderBox::paintBoxDecorations):
838         (WebCore::RenderBox::paintMask):
839         (WebCore::RenderBox::paintMaskImages):
840         (WebCore::RenderBox::paintFillLayers):
841         (WebCore::RenderBox::paintFillLayer):
842         * rendering/RenderBox.h:
843         * rendering/RenderBoxModelObject.cpp:
844         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
845         * rendering/RenderBoxModelObject.h:
846         * rendering/RenderFieldset.cpp:
847         (WebCore::RenderFieldset::paintBoxDecorations):
848         (WebCore::RenderFieldset::paintMask):
849         * rendering/RenderTable.cpp:
850         (WebCore::RenderTable::paintBoxDecorations):
851         (WebCore::RenderTable::paintMask):
852         * rendering/RenderTableCell.cpp:
853         (WebCore::RenderTableCell::paintBackgroundsBehindCell):
854         (WebCore::RenderTableCell::paintMask):
855
856 2009-06-27  Ryosuke Niwa  <rniwa@google.com>
857
858         Reviewed by Eric Seidel.
859
860         https://bugs.webkit.org/show_bug.cgi?id=26762
861
862         Clean up for IndentOutdentCommand::indentRegion, and solved most of problems related to the bug 21712.
863         https://bugs.webkit.org/show_bug.cgi?id=21712
864
865         Added few utility functions to htmlediting.h/cpp
866
867         isVisibilyAdjacent checks whether the first position is visibly next to the second position.
868         i.e. there is no visible node between the first and second positions
869
870         canMergeLists checks whether two lists can be merged.
871         It checks the type of list, the editing boundary, and adjacency of the lists.
872
873         Tests: editing/execCommand/indent-nested-lists-1.html
874                editing/execCommand/indent-nested-lists-2.html
875                editing/execCommand/indent-nested-lists-3.html
876                editing/execCommand/indent-nested-lists-4.html
877                editing/execCommand/indent-nested-lists-5.html
878                editing/execCommand/indent-nested-lists-6.html
879                editing/execCommand/indent-nested-lists-7.html
880                editing/execCommand/outdent-nested-lists-1.html
881                editing/execCommand/outdent-nested-lists-2.html
882                editing/execCommand/outdent-nested-lists-3.html
883                editing/execCommand/outdent-nested-lists-4.html
884
885         * editing/IndentOutdentCommand.cpp:
886         (WebCore::IndentOutdentCommand::prepareBlockquoteLevelForInsertion):
887         (WebCore::IndentOutdentCommand::tryIndentingAsListItem):
888         (WebCore::IndentOutdentCommand::indentIntoBlockquote):
889         (WebCore::IndentOutdentCommand::indentRegion):
890         * editing/IndentOutdentCommand.h:
891         * editing/htmlediting.cpp:
892         (WebCore::enclosingListChild):
893         (WebCore::canMergeLists):
894         (WebCore::isVisibilyAdjacent):
895         * editing/htmlediting.h:
896
897 2009-06-27  Pavel Feldman  <pfeldman@chromium.org>
898
899         Reviewed by Timothy Hatcher.
900
901         WebInspector: Fix completion when iterating options using Tab.
902
903         https://bugs.webkit.org/show_bug.cgi?id=26722
904
905         * inspector/front-end/TextPrompt.js:
906         (WebInspector.TextPrompt.prototype._completionsReady):
907
908 2009-06-27  Gustavo Noronha Silva  <gns@gnome.org>
909
910         Reviewed by Holger Freyther.
911
912         https://bugs.webkit.org/show_bug.cgi?id=25889
913         [GTK] scrollbar policy for main frame is not implementable
914
915         Override visibleContentRect to handle GTK+'s case, in which
916         scrollbars or equivalent decoration are painted by the parent
917         widget.
918
919         * platform/ScrollView.cpp:
920         * platform/gtk/ScrollViewGtk.cpp:
921         (WebCore::ScrollView::visibleContentRect):
922
923 2009-06-27  Daniel Bates  <dbates@intudata.com>
924
925         Reviewed by Adam Barth.
926
927         https://bugs.webkit.org/show_bug.cgi?id=26708
928         
929         Fix addresses false negatives with respect to scheme relative paths, iFrame JavaScript URLs,
930         and UTF-7 encoded payloads.   
931
932         Tests: http/tests/security/xssAuditor/http-equiv-utf-7-encoded.html
933                http/tests/security/xssAuditor/iframe-javascript-url.html
934                http/tests/security/xssAuditor/script-tag-utf-7-encoded.html
935                http/tests/security/xssAuditor/script-tag-with-source-relative-scheme.html
936
937         * html/HTMLTokenizer.cpp:
938         (WebCore::HTMLTokenizer::scriptHandler): Moved XSSAuditor check to HTMLTokenizer::parseTag.
939         (WebCore::HTMLTokenizer::parseTag):
940         * loader/FrameLoader.cpp:
941         (WebCore::FrameLoader::loadSubframe): Modified to inform XSSAuditor of parent frame so
942         as to compare against iFrame javascript URL.
943         * page/XSSAuditor.cpp: Removed method XSSAuditor::isControlCharacter. Instead, exposed method
944         isControlCharacter in ResourceResponseBase.cpp.
945         (WebCore::XSSAuditor::XSSAuditor):
946         (WebCore::XSSAuditor::decodeURL): Modified to decode string using specified encoder.
947         (WebCore::XSSAuditor::findInRequest): Generalized to arbitrary frame so as to prevent execution
948         of iFrame javascript URL.
949         * page/XSSAuditor.h: Added field m_parentFrame.
950         * platform/network/ResourceResponseBase.cpp:
951         (WebCore::isControlCharacter):
952         * platform/network/ResourceResponseBase.h:
953
954 2009-06-27  Oliver Hunt  <oliver@apple.com>
955
956         Reviewed by Maciej Stachowiak.
957
958         Bug 26771: Canvas is incorrectly tainted when drawing from a video element that uses <source> elements
959
960         The drawImage(<video>) logic naively assumes that it just needs
961         to check the src attribute of the video element when in fact it
962         needs to look at the url that is being played instead.  Failure
963         to do this means that video provided through source elements 
964         taints the canvas.
965
966         Test: media/video-canvas-source.html
967
968         * html/CanvasRenderingContext2D.cpp:
969         (WebCore::CanvasRenderingContext2D::checkOrigin):
970         (WebCore::CanvasRenderingContext2D::drawImage):
971         * html/CanvasRenderingContext2D.h:
972
973 2009-06-26  Brian Weinstein  <bweinstein@apple.com>
974
975         Reviewed by Simon Fraser.
976
977         https://bugs.webkit.org/show_bug.cgi?id=26695
978         
979         Added the ability to do scrollbar hit testing in EventHandler, changed the
980         signature of a PlatformWheelEvent constructor, and changed scrollbarUnderMouse
981         to scrollbarUnderPoint, and updated all calls to that function.        
982
983         * page/EventHandler.cpp:
984         (WebCore::EventHandler::hitTestResultAtPoint):
985         (WebCore::EventHandler::handleMousePressEvent):
986         (WebCore::EventHandler::handleMouseMoveEvent):
987         * page/EventHandler.h:
988         (WebCore::):
989         * platform/PlatformWheelEvent.h:
990         * platform/ScrollView.cpp:
991         (WebCore::ScrollView::scrollbarUnderPoint):
992         * platform/ScrollView.h:
993         * platform/chromium/PopupMenuChromium.cpp:
994         (WebCore::PopupListBox::handleMouseDownEvent):
995         (WebCore::PopupListBox::handleMouseMoveEvent):
996         * platform/win/WheelEventWin.cpp:
997         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
998
999
1000 2009-06-26  Simon Fraser  <simon.fraser@apple.com>
1001
1002         Reviewed by Dan Bernstein.
1003
1004         <rdar://problem/7011924> Opacity transitions should not trigger hardware compositing mode
1005         
1006         Don't go into compositing mode just for opacity transitions, but they will be
1007         hardware acclerated if we're already compositing.
1008
1009         * rendering/RenderLayerCompositor.cpp:
1010         (WebCore::RenderLayerCompositor::requiresCompositingLayer):
1011         (WebCore::RenderLayerCompositor::requiresCompositingForTransform):
1012         (WebCore::RenderLayerCompositor::requiresCompositingForAnimation):
1013         * rendering/RenderLayerCompositor.h:
1014
1015 2009-06-26  Simon Fraser  <simon.fraser@apple.com>
1016
1017         Rubber-stamped by Dave Levin
1018
1019         Rename ioCompState to compositingState to better match WebCore coding style.
1020         
1021         * rendering/RenderLayerCompositor.cpp:
1022         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
1023         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
1024
1025 2009-06-26  Dan Bernstein  <mitz@apple.com>
1026
1027         Reviewed by Mark Rowe.
1028
1029         - revert unintentional project changes from r45277
1030
1031         * WebCore.xcodeproj/project.pbxproj:
1032
1033 2009-06-26  Mark Rowe  <mrowe@apple.com>
1034
1035         Fix the Windows build.
1036
1037         * WebCore.vcproj/WebCore.vcproj: Remove ColorSafari.cpp as
1038         the file was deleted from SVN.
1039
1040 2009-06-26  Simon Fraser  <simon.fraser@apple.com>
1041
1042         Reviewed by Dan Bernstein.
1043
1044         https://bugs.webkit.org/show_bug.cgi?id=26766
1045
1046         Change to use array indexing rather than Vector enumerators; the former
1047         are preferred style.
1048
1049         * rendering/RenderLayerBacking.cpp:
1050         (WebCore::RenderLayerBacking::hasNonCompositingContent):
1051         * rendering/RenderLayerCompositor.cpp:
1052         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
1053         (WebCore::RenderLayerCompositor::computeCompositingRequirements):
1054         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
1055         (WebCore::RenderLayerCompositor::updateCompositingChildrenGeometry):
1056         (WebCore::RenderLayerCompositor::recursiveRepaintLayerRect):
1057         (WebCore::RenderLayerCompositor::layerHas3DContent):
1058
1059 2009-06-26  Dan Bernstein  <mitz@apple.com>
1060
1061         Reviewed by Oliver Hunt.
1062
1063         - fix <rdar://problem/6961476> REGRESSION (r42043): scrollWidth reported
1064           as 1 px
1065
1066         Test: fast/dom/Element/scrollWidth.html
1067
1068         Changed scrollWidth and scrollHeight to use the same logic for
1069         visible overflow boxes that is used for clipped overflow boxes. In
1070         particular, borders are not included and
1071         {leftmost,rightmost,lowest}Position() are used. This logic matches IE8.
1072
1073         * rendering/RenderBox.cpp:
1074         (WebCore::RenderBox::scrollWidth):
1075         (WebCore::RenderBox::scrollHeight):
1076
1077 2009-06-26  Chris Fleizach  <cfleizach@apple.com>
1078
1079         Reviewed by Oliver Hunt.
1080
1081         Bug 26725: aria-hidden, aria-disabled, aria-readonly need to be implemented
1082         https://bugs.webkit.org/show_bug.cgi?id=26725
1083
1084         Tests: accessibility/aria-disabled.html
1085                accessibility/aria-hidden.html
1086                accessibility/aria-readonly.html
1087
1088         * accessibility/AccessibilityRenderObject.cpp:
1089         (WebCore::AccessibilityRenderObject::ariaIsHidden):
1090         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
1091         (WebCore::AccessibilityRenderObject::isEnabled):
1092         (WebCore::AccessibilityRenderObject::canSetValueAttribute):
1093         * accessibility/AccessibilityRenderObject.h:
1094         * html/HTMLAttributeNames.in:
1095
1096 2009-06-26  Brett Wilson  <brettw@chromium.org>
1097
1098         Reviewed by David Levin.
1099
1100         https://bugs.webkit.org/show_bug.cgi?id=26759
1101
1102         GIFImageDecoder is broken.
1103
1104         Make the GIFImageDecoder.repetitionCount function const to match the
1105         base class. The mismatched definitions were causing the function to not
1106         get called.
1107
1108         * platform/image-decoders/gif/GIFImageDecoder.cpp:
1109         (WebCore::GIFImageDecoder::repetitionCount):
1110         * platform/image-decoders/gif/GIFImageDecoder.h:
1111
1112 2009-06-26  Chris Marrin  <cmarrin@apple.com>
1113
1114         Reviewed by Simon Fraser  <simon.fraser@apple.com>.
1115
1116         Additional fix for https://bugs.webkit.org/show_bug.cgi?id=26651
1117
1118         The flag should always default to true to avoid it getting set
1119         to false in a build with accelerated compositing turned off
1120         and then disabling accelerated compositing when subsequently
1121         running a build with it turned on.
1122
1123         * page/Settings.cpp:
1124         (WebCore::Settings::Settings):
1125
1126 2009-06-26  Brady Eidson  <beidson@apple.com>
1127
1128         Reviewed by Sam Weinig.
1129
1130         Followup for the fix for <rdar://problem/6961578> REGRESSION (r43511): Opening .fdf files from Acrobat Professional fails
1131
1132         Now that other MIME type correction stuff is in our swizzled method, Tiger needs it too!
1133
1134         * platform/network/mac/ResourceHandleMac.mm:
1135         (-[WebCoreResourceHandleAsDelegate connection:didReceiveResponse:]):
1136         * platform/network/mac/WebCoreURLResponse.h:
1137
1138 2009-06-26  Jeremy Orlow  <jorlow@chromium.org>
1139
1140         Reviewed by Darin Fisher.
1141
1142         https://bugs.webkit.org/show_bug.cgi?id=26732
1143
1144         For the final step of https://bugs.webkit.org/show_bug.cgi?id=25376,
1145         combine LocalStorage and SessionStorage into StorageNamespace. The
1146         synching code (for LocalStorage) has already been removed, so these
1147         classes are now very similar.  All they do is essentially contain a
1148         logical grouping of origins that are attached to specific contexts
1149         (be it PageGroups for LocalStorage and Page for SessionStorage).
1150
1151         * GNUmakefile.am:
1152         * WebCore.vcproj/WebCore.vcproj:
1153         * WebCore.xcodeproj/project.pbxproj:
1154         * WebCoreSources.bkl:
1155         * page/Chrome.cpp:
1156         (WebCore::Chrome::createWindow):
1157         * page/DOMWindow.cpp:
1158         (WebCore::DOMWindow::localStorage):
1159         * page/DOMWindow.h:
1160         * page/Page.cpp:
1161         (WebCore::Page::sessionStorage):
1162         (WebCore::Page::setSessionStorage):
1163         * page/Page.h:
1164         * page/PageGroup.cpp:
1165         (WebCore::PageGroup::localStorage):
1166         * page/PageGroup.h:
1167         * storage/LocalStorage.cpp: Removed.
1168         * storage/LocalStorage.h: Removed.
1169         * storage/LocalStorageTask.cpp:
1170         * storage/LocalStorageThread.cpp:
1171         * storage/SessionStorage.cpp: Removed.
1172         * storage/SessionStorage.h: Removed.
1173         * storage/StorageArea.cpp:
1174         (WebCore::StorageArea::create):
1175         (WebCore::StorageArea::StorageArea):
1176         (WebCore::StorageArea::copy):
1177         (WebCore::StorageArea::length):
1178         (WebCore::StorageArea::key):
1179         (WebCore::StorageArea::getItem):
1180         (WebCore::StorageArea::setItem):
1181         (WebCore::StorageArea::removeItem):
1182         (WebCore::StorageArea::clear):
1183         (WebCore::StorageArea::contains):
1184         (WebCore::StorageArea::importItem):
1185         (WebCore::StorageArea::close):
1186         (WebCore::StorageArea::dispatchStorageEvent):
1187         * storage/StorageArea.h:
1188         (WebCore::):
1189         * storage/StorageAreaSync.cpp:
1190         (WebCore::StorageAreaSync::scheduleFinalSync):
1191         * storage/StorageNamespace.cpp: Copied from WebCore/storage/LocalStorage.cpp.
1192         (WebCore::localStorageNamespaceMap):
1193         (WebCore::StorageNamespace::localStorageNamespace):
1194         (WebCore::StorageNamespace::sessionStorageNamespace):
1195         (WebCore::StorageNamespace::StorageNamespace):
1196         (WebCore::StorageNamespace::~StorageNamespace):
1197         (WebCore::StorageNamespace::copy):
1198         (WebCore::StorageNamespace::storageArea):
1199         (WebCore::StorageNamespace::close):
1200         * storage/StorageNamespace.h: Copied from WebCore/storage/LocalStorage.h.
1201
1202 2009-06-26  Nate Chapin  <japhet@chromium.org>
1203
1204         Reviewed by David Levin.
1205
1206         Upstream V8Proxy.  This involved updating a lot of function and variable names to match WebKit style, hence the large size.
1207
1208         https://bugs.webkit.org/show_bug.cgi?id=26623
1209
1210         * bindings/v8/ScheduledAction.cpp:
1211         (WebCore::ScheduledAction::ScheduledAction):
1212         (WebCore::ScheduledAction::~ScheduledAction):
1213         (WebCore::ScheduledAction::execute):
1214         * bindings/v8/ScriptCallStack.cpp:
1215         (WebCore::ScriptCallStack::ScriptCallStack):
1216         * bindings/v8/ScriptController.cpp:
1217         (WebCore::ScriptController::isSafeScript):
1218         (WebCore::ScriptController::gcProtectJSWrapper):
1219         (WebCore::ScriptController::gcUnprotectJSWrapper):
1220         (WebCore::ScriptController::processingUserGesture):
1221         (WebCore::ScriptController::evaluate):
1222         (WebCore::ScriptController::setEventHandlerLineNumber):
1223         (WebCore::ScriptController::bindToWindowObject):
1224         (WebCore::ScriptController::collectGarbage):
1225         (WebCore::ScriptController::haveInterpreter):
1226         (WebCore::createScriptObject):
1227         (WebCore::ScriptController::createScriptObjectForPluginElement):
1228         * bindings/v8/ScriptInstance.cpp:
1229         (WebCore::V8ScriptInstance::clear):
1230         (WebCore::V8ScriptInstance::set):
1231         * bindings/v8/ScriptObject.cpp:
1232         (WebCore::ScriptGlobalObject::set):
1233         * bindings/v8/ScriptObjectQuarantine.cpp:
1234         (WebCore::getQuarantinedScriptObject):
1235         * bindings/v8/ScriptScope.cpp:
1236         (WebCore::ScriptScope::ScriptScope):
1237         * bindings/v8/ScriptValue.h:
1238         (WebCore::ScriptValue::ScriptValue):
1239         (WebCore::ScriptValue::operator=):
1240         (WebCore::ScriptValue::clear):
1241         * bindings/v8/V8AbstractEventListener.cpp:
1242         (WebCore::V8AbstractEventListener::invokeEventHandler):
1243         (WebCore::V8AbstractEventListener::handleEvent):
1244         (WebCore::V8AbstractEventListener::disposeListenerObject):
1245         (WebCore::V8AbstractEventListener::getReceiverObject):
1246         * bindings/v8/V8Collection.cpp:
1247         (WebCore::toOptionsCollectionSetter):
1248         * bindings/v8/V8Collection.h:
1249         (WebCore::getV8Object):
1250         (WebCore::getNamedPropertyOfCollection):
1251         (WebCore::nodeCollectionNamedPropertyGetter):
1252         (WebCore::getIndexedPropertyOfCollection):
1253         (WebCore::nodeCollectionIndexedPropertyGetter):
1254         (WebCore::nodeCollectionIndexedPropertyEnumerator):
1255         (WebCore::collectionIndexedPropertyEnumerator):
1256         (WebCore::collectionStringOrNullIndexedPropertyGetter):
1257         * bindings/v8/V8DOMMap.cpp:
1258         (WebCore::weakDOMObjectCallback):
1259         (WebCore::DOMData::removeObjectsFromWrapperMap):
1260         * bindings/v8/V8Helpers.cpp:
1261         (WebCore::wrapNPObject):
1262         (WebCore::toV8Context):
1263         * bindings/v8/V8LazyEventListener.cpp:
1264         (WebCore::V8LazyEventListener::~V8LazyEventListener):
1265         (WebCore::V8LazyEventListener::getListenerFunction):
1266         (WebCore::V8LazyEventListener::callListenerFunction):
1267         (WebCore::V8LazyEventListener::getWrappedListenerFunction):
1268         * bindings/v8/V8NodeFilterCondition.cpp:
1269         (WebCore::V8NodeFilterCondition::V8NodeFilterCondition):
1270         (WebCore::V8NodeFilterCondition::~V8NodeFilterCondition):
1271         (WebCore::V8NodeFilterCondition::acceptNode):
1272         * bindings/v8/V8ObjectEventListener.cpp:
1273         (WebCore::weakObjectEventListenerCallback):
1274         (WebCore::V8ObjectEventListener::~V8ObjectEventListener):
1275         * bindings/v8/V8Proxy.cpp: Added.
1276         * bindings/v8/V8Proxy.h:
1277         (WebCore::):
1278         (WebCore::GlobalHandleInfo::GlobalHandleInfo):
1279         (WebCore::V8Proxy::):
1280         (WebCore::V8Proxy::V8Proxy):
1281         (WebCore::V8Proxy::frame):
1282         (WebCore::V8Proxy::inlineCode):
1283         (WebCore::V8Proxy::setInlineCode):
1284         (WebCore::V8Proxy::timerCallback):
1285         (WebCore::V8Proxy::setTimerCallback):
1286         (WebCore::V8Proxy::setEventHandlerLineNumber):
1287         (WebCore::V8Proxy::finishedWithEvent):
1288         (WebCore::V8Proxy::wrapCPointer):
1289         (WebCore::V8Proxy::extractCPointer):
1290         (WebCore::V8Proxy::convertDOMWrapperToNative):
1291         (WebCore::V8Proxy::convertDOMWrapperToNode):
1292         (WebCore::V8Proxy::convertToV8Object):
1293         (WebCore::V8Proxy::convertToNativeObject):
1294         (WebCore::V8Proxy::convertToNativeEvent):
1295         (WebCore::V8Proxy::context):
1296         (WebCore::V8Proxy::extractCPointerImpl):
1297         (WebCore::V8Proxy::utilityContext):
1298         (WebCore::V8Proxy::constructDOMObject):
1299         (WebCore::throwError):
1300         (WebCore::toV8):
1301         * bindings/v8/V8Utilities.h:
1302         * bindings/v8/WorkerContextExecutionProxy.cpp:
1303         (WebCore::WorkerContextExecutionProxy::retrieve):
1304         (WebCore::WorkerContextExecutionProxy::initContextIfNeeded):
1305         (WebCore::WorkerContextExecutionProxy::GetConstructor):
1306         (WebCore::WorkerContextExecutionProxy::ToV8Object):
1307         (WebCore::WorkerContextExecutionProxy::EventToV8Object):
1308         (WebCore::WorkerContextExecutionProxy::toV8):
1309         (WebCore::WorkerContextExecutionProxy::forgetV8EventObject):
1310         (WebCore::WorkerContextExecutionProxy::evaluate):
1311         (WebCore::WorkerContextExecutionProxy::runScript):
1312         * bindings/v8/custom/V8AttrCustom.cpp:
1313         (WebCore::ACCESSOR_SETTER):
1314         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp:
1315         (WebCore::NAMED_PROPERTY_GETTER):
1316         (WebCore::NAMED_PROPERTY_SETTER):
1317         * bindings/v8/custom/V8CanvasPixelArrayCustom.cpp:
1318         (WebCore::INDEXED_PROPERTY_GETTER):
1319         (WebCore::INDEXED_PROPERTY_SETTER):
1320         * bindings/v8/custom/V8CanvasRenderingContext2DCustom.cpp:
1321         (WebCore::toV8):
1322         (WebCore::toCanvasStyle):
1323         (WebCore::ACCESSOR_GETTER):
1324         (WebCore::ACCESSOR_SETTER):
1325         (WebCore::CALLBACK_FUNC_DECL):
1326         * bindings/v8/custom/V8ClientRectListCustom.cpp:
1327         (WebCore::INDEXED_PROPERTY_GETTER):
1328         * bindings/v8/custom/V8ClipboardCustom.cpp:
1329         (WebCore::ACCESSOR_GETTER):
1330         (WebCore::CALLBACK_FUNC_DECL):
1331         * bindings/v8/custom/V8CustomBinding.cpp:
1332         (WebCore::allowSettingFrameSrcToJavascriptUrl):
1333         (WebCore::ACCESSOR_GETTER):
1334         (WebCore::INDEXED_ACCESS_CHECK):
1335         (WebCore::NAMED_ACCESS_CHECK):
1336         (WebCore::V8Custom::GetTargetFrame):
1337         * bindings/v8/custom/V8CustomEventListener.cpp:
1338         (WebCore::V8EventListener::V8EventListener):
1339         (WebCore::V8EventListener::~V8EventListener):
1340         (WebCore::V8EventListener::callListenerFunction):
1341         * bindings/v8/custom/V8CustomSQLStatementCallback.cpp:
1342         (WebCore::V8CustomSQLStatementCallback::handleEvent):
1343         * bindings/v8/custom/V8CustomSQLStatementErrorCallback.cpp:
1344         (WebCore::V8CustomSQLStatementErrorCallback::handleEvent):
1345         * bindings/v8/custom/V8CustomSQLTransactionCallback.cpp:
1346         (WebCore::V8CustomSQLTransactionCallback::handleEvent):
1347         * bindings/v8/custom/V8CustomSQLTransactionErrorCallback.cpp:
1348         (WebCore::V8CustomSQLTransactionErrorCallback::handleEvent):
1349         * bindings/v8/custom/V8CustomVoidCallback.cpp:
1350         (WebCore::V8CustomVoidCallback::handleEvent):
1351         (WebCore::invokeCallback):
1352         * bindings/v8/custom/V8CustomXPathNSResolver.cpp:
1353         (WebCore::V8CustomXPathNSResolver::lookupNamespaceURI):
1354         * bindings/v8/custom/V8DOMParserConstructor.cpp:
1355         (WebCore::CALLBACK_FUNC_DECL):
1356         * bindings/v8/custom/V8DOMWindowCustom.cpp:
1357         (WebCore::V8Custom::WindowSetTimeoutImpl):
1358         (WebCore::convertBase64):
1359         (WebCore::ACCESSOR_SETTER):
1360         (WebCore::CALLBACK_FUNC_DECL):
1361         (WebCore::ACCESSOR_GETTER):
1362         (WebCore::createWindow):
1363         (WebCore::INDEXED_PROPERTY_GETTER):
1364         (WebCore::NAMED_PROPERTY_GETTER):
1365         (WebCore::V8Custom::ClearTimeoutImpl):
1366         (WebCore::NAMED_ACCESS_CHECK):
1367         (WebCore::INDEXED_ACCESS_CHECK):
1368         * bindings/v8/custom/V8DatabaseCustom.cpp:
1369         (WebCore::CALLBACK_FUNC_DECL):
1370         * bindings/v8/custom/V8DocumentCustom.cpp:
1371         (WebCore::CALLBACK_FUNC_DECL):
1372         * bindings/v8/custom/V8DocumentLocationCustom.cpp:
1373         (WebCore::ACCESSOR_GETTER):
1374         (WebCore::ACCESSOR_SETTER):
1375         * bindings/v8/custom/V8ElementCustom.cpp:
1376         (WebCore::CALLBACK_FUNC_DECL):
1377         (WebCore::ACCESSOR_SETTER):
1378         (WebCore::ACCESSOR_GETTER):
1379         * bindings/v8/custom/V8EventCustom.cpp:
1380         (WebCore::ACCESSOR_SETTER):
1381         (WebCore::ACCESSOR_GETTER):
1382         * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
1383         (WebCore::CALLBACK_FUNC_DECL):
1384         * bindings/v8/custom/V8HTMLCollectionCustom.cpp:
1385         (WebCore::getNamedItems):
1386         (WebCore::getItem):
1387         (WebCore::NAMED_PROPERTY_GETTER):
1388         (WebCore::CALLBACK_FUNC_DECL):
1389         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
1390         (WebCore::NAMED_PROPERTY_GETTER):
1391         (WebCore::CALLBACK_FUNC_DECL):
1392         (WebCore::ACCESSOR_GETTER):
1393         * bindings/v8/custom/V8HTMLFormElementCustom.cpp:
1394         (WebCore::INDEXED_PROPERTY_GETTER):
1395         (WebCore::NAMED_PROPERTY_GETTER):
1396         (WebCore::CALLBACK_FUNC_DECL):
1397         * bindings/v8/custom/V8HTMLFrameElementCustom.cpp:
1398         (WebCore::ACCESSOR_SETTER):
1399         * bindings/v8/custom/V8HTMLFrameSetElementCustom.cpp:
1400         (WebCore::NAMED_PROPERTY_GETTER):
1401         * bindings/v8/custom/V8HTMLIFrameElementCustom.cpp:
1402         (WebCore::ACCESSOR_SETTER):
1403         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
1404         (WebCore::CALLBACK_FUNC_DECL):
1405         * bindings/v8/custom/V8HTMLInputElementCustom.cpp:
1406         (WebCore::ACCESSOR_GETTER):
1407         (WebCore::ACCESSOR_SETTER):
1408         (WebCore::CALLBACK_FUNC_DECL):
1409         * bindings/v8/custom/V8HTMLOptionElementConstructor.cpp:
1410         (WebCore::CALLBACK_FUNC_DECL):
1411         * bindings/v8/custom/V8HTMLOptionsCollectionCustom.cpp:
1412         (WebCore::CALLBACK_FUNC_DECL):
1413         (WebCore::ACCESSOR_GETTER):
1414         (WebCore::ACCESSOR_SETTER):
1415         (WebCore::INDEXED_PROPERTY_GETTER):
1416         (WebCore::INDEXED_PROPERTY_SETTER):
1417         * bindings/v8/custom/V8HTMLPlugInElementCustom.cpp:
1418         (WebCore::NAMED_PROPERTY_GETTER):
1419         (WebCore::NAMED_PROPERTY_SETTER):
1420         (WebCore::INDEXED_PROPERTY_GETTER):
1421         (WebCore::INDEXED_PROPERTY_SETTER):
1422         * bindings/v8/custom/V8HTMLSelectElementCollectionCustom.cpp:
1423         (WebCore::NAMED_PROPERTY_GETTER):
1424         (WebCore::INDEXED_PROPERTY_SETTER):
1425         * bindings/v8/custom/V8HTMLSelectElementCustom.cpp:
1426         (WebCore::CALLBACK_FUNC_DECL):
1427         (WebCore::removeElement):
1428         * bindings/v8/custom/V8InspectorControllerCustom.cpp:
1429         (WebCore::CALLBACK_FUNC_DECL):
1430         * bindings/v8/custom/V8LocationCustom.cpp:
1431         (WebCore::ACCESSOR_SETTER):
1432         (WebCore::ACCESSOR_GETTER):
1433         (WebCore::CALLBACK_FUNC_DECL):
1434         (WebCore::INDEXED_ACCESS_CHECK):
1435         (WebCore::NAMED_ACCESS_CHECK):
1436         * bindings/v8/custom/V8MessageChannelConstructor.cpp:
1437         (WebCore::CALLBACK_FUNC_DECL):
1438         * bindings/v8/custom/V8MessagePortCustom.cpp:
1439         (WebCore::ACCESSOR_GETTER):
1440         (WebCore::ACCESSOR_SETTER):
1441         (WebCore::CALLBACK_FUNC_DECL):
1442         * bindings/v8/custom/V8NamedNodeMapCustom.cpp:
1443         (WebCore::INDEXED_PROPERTY_GETTER):
1444         (WebCore::NAMED_PROPERTY_GETTER):
1445         * bindings/v8/custom/V8NavigatorCustom.cpp:
1446         (WebCore::ACCESSOR_GETTER):
1447         * bindings/v8/custom/V8NodeCustom.cpp:
1448         (WebCore::CALLBACK_FUNC_DECL):
1449         * bindings/v8/custom/V8NodeIteratorCustom.cpp:
1450         (WebCore::toV8):
1451         (WebCore::CALLBACK_FUNC_DECL):
1452         * bindings/v8/custom/V8NodeListCustom.cpp:
1453         (WebCore::NAMED_PROPERTY_GETTER):
1454         * bindings/v8/custom/V8SQLResultSetRowListCustom.cpp:
1455         (WebCore::CALLBACK_FUNC_DECL):
1456         * bindings/v8/custom/V8SQLTransactionCustom.cpp:
1457         (WebCore::CALLBACK_FUNC_DECL):
1458         * bindings/v8/custom/V8SVGElementInstanceCustom.cpp:
1459         (WebCore::CALLBACK_FUNC_DECL):
1460         * bindings/v8/custom/V8SVGLengthCustom.cpp:
1461         (WebCore::ACCESSOR_GETTER):
1462         (WebCore::CALLBACK_FUNC_DECL):
1463         * bindings/v8/custom/V8SVGMatrixCustom.cpp:
1464         (WebCore::CALLBACK_FUNC_DECL):
1465         * bindings/v8/custom/V8StyleSheetListCustom.cpp:
1466         (WebCore::NAMED_PROPERTY_GETTER):
1467         * bindings/v8/custom/V8TreeWalkerCustom.cpp:
1468         (WebCore::toV8):
1469         (WebCore::CALLBACK_FUNC_DECL):
1470         * bindings/v8/custom/V8WebKitCSSMatrixConstructor.cpp:
1471         (WebCore::CALLBACK_FUNC_DECL):
1472         * bindings/v8/custom/V8WebKitPointConstructor.cpp:
1473         (WebCore::CALLBACK_FUNC_DECL):
1474         * bindings/v8/custom/V8WorkerContextCustom.cpp:
1475         (WebCore::ACCESSOR_GETTER):
1476         (WebCore::ACCESSOR_SETTER):
1477         (WebCore::SetTimeoutOrInterval):
1478         (WebCore::CALLBACK_FUNC_DECL):
1479         * bindings/v8/custom/V8WorkerCustom.cpp:
1480         (WebCore::CALLBACK_FUNC_DECL):
1481         (WebCore::getEventListener):
1482         (WebCore::ACCESSOR_GETTER):
1483         (WebCore::ACCESSOR_SETTER):
1484         * bindings/v8/custom/V8XMLHttpRequestConstructor.cpp:
1485         (WebCore::CALLBACK_FUNC_DECL):
1486         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
1487         (WebCore::getEventListener):
1488         (WebCore::ACCESSOR_GETTER):
1489         (WebCore::ACCESSOR_SETTER):
1490         (WebCore::CALLBACK_FUNC_DECL):
1491         * bindings/v8/custom/V8XMLHttpRequestUploadCustom.cpp:
1492         (WebCore::ACCESSOR_GETTER):
1493         (WebCore::ACCESSOR_SETTER):
1494         (WebCore::CALLBACK_FUNC_DECL):
1495         * bindings/v8/custom/V8XMLSerializerConstructor.cpp:
1496         (WebCore::CALLBACK_FUNC_DECL):
1497         * bindings/v8/custom/V8XPathEvaluatorConstructor.cpp:
1498         (WebCore::CALLBACK_FUNC_DECL):
1499         * bindings/v8/custom/V8XSLTProcessorCustom.cpp:
1500         (WebCore::CALLBACK_FUNC_DECL):
1501
1502 2009-06-26  Kevin McCullough  <kmccullough@apple.com>
1503
1504         Reviewed by Tim Hatcher.
1505
1506         <rdar://problem/7011047> Profiler shows the record button 'on' even
1507         though it's finished
1508
1509         I consolidated the creation of the user initiated profile name into
1510         its own function and then called it from console::profile instead of
1511         calling startUserInitiatedProfiling().  This way we don't call
1512         toggleRecordButton() which turns on the record button.
1513
1514         * inspector/InspectorController.cpp:
1515         (WebCore::InspectorController::didCommitLoad):
1516         (WebCore::InspectorController::getCurrentUserInitiatedProfileName):
1517         (WebCore::InspectorController::startUserInitiatedProfiling):
1518         (WebCore::InspectorController::stopUserInitiatedProfiling):
1519         * inspector/InspectorController.h:
1520         * page/Console.cpp:
1521         (WebCore::Console::profile):
1522         (WebCore::Console::profileEnd):
1523
1524 2009-06-26  Jeremy Moskovich  <jeremy@chromium.org>
1525
1526         Reviewed by Eric Seidel.
1527
1528         https://bugs.webkit.org/show_bug.cgi?id=26691
1529
1530         Cleanup: Move focusRingColor to RenderTheme.
1531
1532         Most of this CL involves deleting files and removing dead code.
1533
1534         focusRingColor() is now defined in RenderTheme rather than in
1535         misc. places on each port.  The default color is specified as
1536         black in renderTheme and ports can override it in their own
1537         custom renderThemes.
1538
1539         Behavior should be identical except for the following cases,
1540         this lists platform and what the focus ring color used to be
1541         before this cl and the file where it used to be defined:
1542
1543         Android - red
1544         WebCore/platform/android/TemporaryLinkStubs.cpp
1545
1546         Cairo - aqua focus ring color - 0xFF7DADD9
1547         WebCore/platform/graphics/cairo/GraphicsContextCairo.cpp
1548
1549         wx - red
1550         WebCore/platform/wx/TemporaryLinkStubs.cpp
1551
1552         QT - black
1553         WebCore/platform/graphics/qt/GraphicsContextQt.cpp
1554
1555         Manual test: manual-tests/focusringcolor-change-on-theme-change.html
1556
1557         * css/CSSStyleSelector.cpp:
1558         (WebCore::CSSStyleSelector::getColorFromPrimitiveValue):
1559         * manual-tests/focusringcolor-change-on-theme-change.html: Added.
1560         * platform/android/TemporaryLinkStubs.cpp:
1561         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1562         * platform/graphics/chromium/ColorChromium.cpp: Removed.
1563         * platform/graphics/chromium/ColorChromiumMac.mm: Removed.
1564         * platform/graphics/mac/ColorMac.h:
1565         * platform/graphics/mac/ColorMac.mm:
1566         (WebCore::oldAquaFocusRingColor):
1567         (WebCore::setUsesTestModeFocusRingColor):
1568         (WebCore::usesTestModeFocusRingColor):
1569         * platform/graphics/qt/GraphicsContextQt.cpp:
1570         * platform/graphics/skia/GraphicsContextSkia.cpp:
1571         (WebCore::GraphicsContext::drawFocusRing):
1572         * platform/graphics/win/ColorSafari.cpp: Removed.
1573         * platform/wx/TemporaryLinkStubs.cpp:
1574         * rendering/RenderTheme.cpp:
1575         (WebCore::RenderTheme::focusRingColor):
1576         * rendering/RenderTheme.h:
1577         * rendering/RenderThemeChromiumMac.h:
1578         * rendering/RenderThemeChromiumMac.mm:
1579         (WebCore::RenderThemeChromiumMac::focusRingColor):
1580         (WebCore::RenderThemeChromiumMac::systemColor):
1581         * rendering/RenderThemeChromiumSkia.cpp:
1582         (WebCore::RenderThemeChromiumSkia::focusRingColor):
1583         * rendering/RenderThemeChromiumSkia.h:
1584         * rendering/RenderThemeMac.h:
1585         * rendering/RenderThemeMac.mm:
1586         (WebCore::RenderThemeMac::focusRingColor):
1587         (WebCore::RenderThemeMac::systemColor):
1588         * rendering/RenderThemeSafari.cpp:
1589         (WebCore::makeRGBAFromCGColor):
1590         (WebCore::RenderThemeSafari::focusRingColor):
1591         * rendering/RenderThemeSafari.h:
1592
1593 2009-06-26  Dmitry Titov  <dimich@chromium.org>
1594
1595         Reviewed by David Levin.
1596
1597         https://bugs.webkit.org/show_bug.cgi?id=26761
1598         [Chromium] Enable Dedicated Workers in Chromium.
1599
1600         * bindings/v8/custom/V8WorkerCustom.cpp:
1601         (WebCore::CALLBACK_FUNC_DECL):
1602         Remove the check that prevented workers from being created w/o a command-line switch.
1603         The flag itself and methods will be removed in a subsequent patch, after
1604         corresponding change in Chromium.
1605
1606 2009-06-26  Jessie Berlin  <jberlin@apple.com>
1607
1608         Reviewed by Mark Rowe.
1609         
1610         Fix: https://bugs.webkit.org/show_bug.cgi?id=26723
1611         Where the m_mouseDown event was never being set on windows, so the
1612         client X and Y coordinates were always being reported as zero in a
1613         dragstart handler.
1614
1615         Test: editing/selection/drag-start-event-client-x-y.html
1616
1617         * page/EventHandler.cpp:
1618         (WebCore::EventHandler::handleMousePressEvent):
1619         Set the m_mouseDown event when the mouse press is handled.
1620         * page/mac/EventHandlerMac.mm:
1621         (WebCore::EventHandler::mouseDown):
1622         Removed now redundant setting of m_mouseDown.
1623
1624 2009-06-26  Brady Eidson  <beidson@apple.com>
1625
1626         Tiger build fix
1627
1628         * WebCore.xcodeproj/project.pbxproj:
1629         * platform/network/mac/WebCoreURLResponse.mm:
1630         (swizzleMIMETypeMethodIfNecessary):
1631
1632 2009-06-26  Alexey Proskuryakov  <ap@webkit.org>
1633
1634         Reviewed by Sam Weinig.
1635
1636         https://bugs.webkit.org/show_bug.cgi?id=26681
1637         Problem updating applicationCache when server returns 304
1638         
1639         Improve the fix, make the test pass on Tiger.
1640
1641         * loader/appcache/ApplicationCacheGroup.cpp:
1642         (WebCore::ApplicationCacheGroup::didReceiveResponse): Fix another code path to remove the
1643         current item from list.
1644
1645         * platform/network/mac/ResourceHandleMac.mm: (WebCore::ResourceHandle::start): On Tiger,
1646         conditional requests that cannot be cached by network layer cause errors with default cache
1647         policy.
1648
1649 2009-06-26  Brady Eidson  <beidson@apple.com>
1650
1651         Reviewed by Sam Weinig
1652
1653         <rdar://problem/6961578> REGRESSION (r43511): Opening .fdf files from Acrobat Professional fails
1654
1655         When we disabled content sniffing for file urls we lost knowledge of many file extensions that we
1656         didn't intend to lose.  Turns out the CoreTypes UTI database doesn't know about every extension Gatekeeper
1657         knew about.
1658
1659         By comparing CoreTypes' database to Gatekeepers, this patch adds a hardcoded list of file extension to MIME
1660         type mappings that are missing in CoreType's database.
1661
1662         Test: platform/mac/fast/loader/file-url-mimetypes.html
1663
1664         * platform/network/mac/ResourceHandleMac.mm:
1665         (-[WebCoreResourceHandleAsDelegate connection:didReceiveResponse:]): Move the MIME Type swizzling code to
1666           WebCoreURLResponse.
1667
1668         * platform/network/mac/ResourceResponseMac.mm:
1669         (WebCore::ResourceResponse::platformLazyInit): _webcore_MIMEType -> MIMEType, as we now have only one place
1670           where we do all MIMEType correction.
1671
1672         * platform/network/mac/WebCoreURLResponse.h: Remove _webcore_MIMEType, as it is now folded into the swizzled
1673           implementation of MIMEType.
1674         * platform/network/mac/WebCoreURLResponse.mm:
1675         (createBinaryExtensionsSet):
1676         (createExtensionToMIMETypeMap):
1677         (swizzleMIMETypeMethodIfNecessary):
1678         (webNSURLResponseMIMEType): If it's a file URL and there's no MIME type, see if the extension exists in the 
1679           extension -> MIME type map before turning to the default MIME type.  Also roll in what was previously
1680           implemented in _webcore_MIMEType.
1681
1682         * svg/graphics/SVGImage.cpp:
1683         (WebCore::SVGImage::~SVGImage): Tweak this ASSERT - SVGImages might get destroyed without ever having a client.
1684
1685 2009-06-25  Pierre d'Herbemont  <pdherbemont@apple.com>
1686
1687         Reviewed by Simon Fraser.
1688
1689         Show the fullscreen button only if the backend has support for it.
1690
1691         https://bugs.webkit.org/show_bug.cgi?id=26661
1692
1693         No test since this is not reachable via the DOM.
1694
1695         * html/HTMLMediaElement.h:
1696         (WebCore::HTMLMediaElement::supportsFullscreen): new
1697         * html/HTMLVideoElement.h:
1698         (WebCore::HTMLVideoElement::supportsFullscreen): new
1699         * platform/graphics/MediaPlayer.cpp:
1700         (WebCore::NullMediaPlayerPrivate::supportsFullscreen): new
1701         (WebCore::MediaPlayer::supportsFullscreen): new
1702         * platform/graphics/MediaPlayer.h: new
1703         * platform/graphics/MediaPlayerPrivate.h: new
1704         (WebCore::MediaPlayerPrivateInterface::supportsFullscreen): new
1705         * rendering/MediaControlElements.cpp:
1706         (WebCore::MediaControlFullscreenButtonElement::rendererIsNeeded): new
1707         * rendering/MediaControlElements.h:
1708
1709 2009-06-25  Pierre d'Herbemont  <pdherbemont@apple.com>
1710
1711         Reviewed by Simon Fraser.
1712
1713         <rdar://problem/7007776> Controller doesn't automatically update counters when file
1714         is playing ( http://www.jazzguitar.be/mp3/Michael%20Lewis%20-%20SSSJ.mp3 )
1715
1716         Update the time display when the movie time changes.
1717
1718         * rendering/RenderMedia.cpp:
1719         (WebCore::RenderMedia::updateControls):
1720
1721 2009-06-25  Pierre d'Herbemont  <pdherbemont@apple.com>
1722
1723         Reviewed by Simon Fraser.
1724
1725         https://bugs.webkit.org/show_bug.cgi?id=26659
1726
1727         Support hidding a control bar element from the Media element controller.
1728
1729         Update layout tests since the fullscreen button no longer has a renderer.
1730
1731         * rendering/MediaControlElements.cpp:
1732         (WebCore::MediaTextDisplayElement::update): call updateStyle() so everything
1733         is updated properly.
1734         (WebCore::MediaControlInputElement::MediaControlInputElement):
1735         (WebCore::MediaControlInputElement::update): call updateStyle()
1736         (WebCore::MediaControlInputElement::updateStyle): create the renderer properly
1737         or not depending on what rendererIsNeeded() return.
1738         * rendering/MediaControlElements.h:
1739
1740 2009-06-26  Kevin McCullough  <kmccullough@apple.com>
1741
1742         Reviewed by Oliver Hunt.
1743
1744         <rdar://problem/6968137> Profiler title numbers increment even after a
1745         reload.
1746
1747         - Now the numbers are reset when the profiles are.
1748
1749         * inspector/InspectorController.cpp:
1750         (WebCore::InspectorController::didCommitLoad):
1751
1752 2009-06-26  Adele Peterson  <adele@apple.com>
1753
1754         Reviewed by Darin Adler.
1755
1756         Fix for <rdar://problem/7000796>
1757         REGRESSION(34681): Breaking up quoted text makes new, unquoted text blue after certain steps; repros with some messages
1758
1759         Test: editing/inserting/break-blockquote-after-delete.html
1760
1761         Keep track of whether the typing style should be preserved after the TypingCommand is applied.  When adding onto an open
1762         typing command, keep that flag up to date.
1763
1764         In this case, an InsertParagraphSeparatorInQuotedContent command, which should not preserve typing style, 
1765         was following an open Delete command, which does preserve the typing style.  So we were applying the original
1766         typing style (from before the delete, so blue text) to the cursor in the unquoted area after breaking up the blockquote.
1767
1768         * editing/TypingCommand.cpp:
1769         (WebCore::TypingCommand::TypingCommand):
1770         (WebCore::TypingCommand::typingAddedToOpenCommand):
1771         (WebCore::TypingCommand::insertTextRunWithoutNewlines):
1772         (WebCore::TypingCommand::insertLineBreak):
1773         (WebCore::TypingCommand::insertParagraphSeparator):
1774         (WebCore::TypingCommand::insertParagraphSeparatorInQuotedContent):
1775         (WebCore::TypingCommand::deleteKeyPressed):
1776         (WebCore::TypingCommand::forwardDeleteKeyPressed):
1777         (WebCore::TypingCommand::deleteSelection):
1778         (WebCore::TypingCommand::updatePreservesTypingStyle):
1779         * editing/TypingCommand.h: (WebCore::TypingCommand::preservesTypingStyle):
1780
1781 2009-06-26  Jedrzej Nowacki  <jedrzej.nowacki@nokia.com>
1782
1783         Reviewed by Simon Hausmann.
1784
1785         Add support for saving and loading of QWebHistory to and from a QByteArray.
1786
1787         This includes streaming operators for QWebHistory. for convenience.
1788
1789         New autotests that test QWebHistory and QWebHistoryItem serialization.
1790
1791         * WebCore.pro:
1792         * history/HistoryItem.h:
1793         (WebCore::HistoryItem::dailyVisitCounts):
1794         (WebCore::HistoryItem::weeklyVisitCounts):
1795         * history/qt/HistoryItemQt.cpp: Added.
1796         (WebCore::HistoryItem::restoreState):
1797         (WebCore::HistoryItem::saveState):
1798
1799 2009-06-26  Jedrzej Nowacki  <jedrzej.nowacki@nokia.com>
1800
1801         Reviewed by Simon Hausmann.
1802
1803         Add support for QDataStream operators to String and IntPoint.
1804
1805         * platform/graphics/IntPoint.h:
1806         (WebCore::operator<<):
1807         (WebCore::operator>>):
1808         * platform/text/PlatformString.h:
1809         * platform/text/qt/StringQt.cpp:
1810         (WebCore::operator<<):
1811         (WebCore::operator>>):
1812
1813 2009-06-26  Ben Murdoch  <benm@google.com>
1814
1815         Reviewed by Darin Fisher.
1816
1817         Add #if ENABLE(DOM_STORAGE) to the V8 custom bindings for local/session storage.
1818         https://bugs.webkit.org/show_bug.cgi?id=26757
1819
1820         * bindings/v8/custom/V8StorageCustom.cpp
1821
1822 2009-06-26  Yongjun Zhang  <yongjun.zhang@nokia.com>
1823
1824         Reviewed by Eric Seidel.
1825
1826         Test: platform/qt/fast/events/event-sender-keydown-frame.html
1827
1828         Bug 20303: [Qt] Key events are not working in frames.
1829
1830         Merge scrolling handling code in qt and win port, move it to
1831         EventHandler.
1832
1833         * page/EventHandler.cpp:
1834         (WebCore::EventHandler::scrollRecursively):
1835         * page/EventHandler.h:
1836
1837 2009-06-26  Rob Buis  <rwlbuis@gmail.com>
1838
1839         Reviewed by Eric Seidel.
1840
1841         https://bugs.webkit.org/show_bug.cgi?id=26682
1842         Bug 26682: It should be possible to add image to SVG DOM programmatically (using JavaScript)
1843
1844         Make sure the xlink:href animated property setting syncs the corresponding attribute with the right namespace.
1845
1846         Test: svg/custom/createImageElement.svg
1847
1848         * svg/SVGAnimatedProperty.h:
1849         (WebCore::synchronizeProperty):
1850
1851 2009-06-26  Takeshi Yoshino  <tyoshino@google.com>
1852
1853         Reviewed by Timothy Hatcher.
1854
1855         Bug 26156: In view-source mode, always render the contents using HTMLViewSourceDocument
1856         https://bugs.webkit.org/show_bug.cgi?id=26156
1857
1858         When in view-source mode, render the contents using HTMLViewSourceDocument
1859         regardless it's applicable for any plugin or not.
1860
1861         Chromium tells WebCore to render the contents of specified URL when
1862         view-source: prefix is added to the URL. But currently, DOMImplementation
1863         ignores inViewSourceMode() when the MIME type is indicating that the contents
1864         are neither texts nor HTML family documents.
1865
1866         For example, we can check the contents of asf file without launching media
1867         player. Rendering contents for view-source:-specified input is not what user
1868         expects.
1869
1870         http://code.google.com/p/chromium/issues/detail?id=10545
1871
1872         I want to fix this issue by this patch. IMHO, regardless of this Chromium
1873         specific issue, I think we should force use of HTMLViewSourceDocument when
1874         inViewSourceMode() is specified.
1875
1876         Test: fast/frames/viewsource-on-image-file.html
1877
1878         * dom/DOMImplementation.cpp:
1879         (WebCore::DOMImplementation::createDocument):
1880         * html/HTMLViewSourceDocument.cpp:
1881         (WebCore::HTMLViewSourceDocument::createTokenizer):
1882         * html/HTMLViewSourceDocument.h:
1883
1884 2009-06-26  Xan Lopez  <xlopez@igalia.com>
1885
1886         Reviewed by Jan Alonzo.
1887
1888         https://bugs.webkit.org/show_bug.cgi?id=25529
1889         [Gtk] Expected states not exposed to assistive technologies
1890
1891         Add support for VISIBLE, EDITABLE and SENSITIVE states.
1892
1893         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
1894         (setAtkStateSetFromCoreObject):
1895
1896 2009-06-26  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
1897
1898         Reviewed by Darin Adler.
1899
1900         "Pointer to incomplete class type is not allowed" error with RVCT
1901         https://bugs.webkit.org/show_bug.cgi?id=26721
1902
1903         Based on Norbert Leser's work.
1904
1905         * dom/Document.cpp:
1906         (WebCore::Document::setFocusedNode):
1907         * dom/Node.cpp:
1908         (WebCore::Node::dispatchMouseEvent):
1909         * dom/Node.h: Remove the default value for PassRefPtr<Event> args,
1910         to eliminate dependency on the Event class definition
1911
1912 2009-06-26  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
1913
1914         Reviewed by Maciej Stachowiak.
1915
1916         [Qt] Build fix after r45183
1917         https://bugs.webkit.org/show_bug.cgi?id=26748
1918
1919         * WebCore.pro:
1920
1921 2009-06-25  Alexey Proskuryakov  <ap@webkit.org>
1922
1923         Reviewed by Darin Adler.
1924
1925         https://bugs.webkit.org/show_bug.cgi?id=26681
1926         <rdar://problem/7003461> Problem updating applicationCache when server returns 304
1927
1928         Test: http/tests/appcache/update-cache.html
1929
1930         * loader/appcache/ApplicationCacheGroup.cpp: (WebCore::ApplicationCacheGroup::didReceiveResponse):
1931         We're already done with the resource, don't try to load it again.
1932
1933 2009-06-25  Simon Fraser  <simon.fraser@apple.com>
1934
1935         Reviewed by Oliver Hunt.
1936         
1937         <rdar://problem/6990481>
1938         
1939         Handle perspective computation on non-layer objects.
1940
1941         Test: transforms/3d/general/perspective-non-layer.html
1942
1943         * rendering/RenderObject.cpp:
1944         (WebCore::RenderObject::getTransformFromContainer):
1945
1946 2009-06-25  Pierre d'Herbemont  <pdherbemont@apple.com>
1947
1948         Reviewed by Eric Seidel.
1949
1950         https://bugs.webkit.org/show_bug.cgi?id=26653
1951
1952         Use flex box in the mediaControls.css style, to nicely scale if a button gets
1953         dynamically added or removed.
1954
1955         Media tests results are affected by this changes.
1956
1957         * css/mediaControls.css:
1958         * css/mediaControlsQT.css:
1959
1960 2009-06-25  Albert J. Wong  <ajwong@chromium.org>
1961
1962         Reviewed by Darin Fisher.
1963
1964         https://bugs.webkit.org/show_bug.cgi?id=26724
1965
1966         Move relavent part of setDefaultFontSize from RenderThemeChromiumWin
1967         up into RenderThemeChromiumSkia.
1968
1969         * rendering/RenderThemeChromiumSkia.cpp:
1970         (WebCore::RenderThemeChromiumSkia::setDefaultFontSize):
1971         * rendering/RenderThemeChromiumSkia.h:
1972         * rendering/RenderThemeChromiumWin.cpp:
1973         (WebCore::RenderThemeChromiumWin::setDefaultFontSize):
1974         * rendering/RenderThemeChromiumWin.h:
1975
1976 2009-06-25  Matt Perry  <mpcomplete@chromium.org>
1977
1978         Reviewed by Darin Fisher.
1979
1980         https://bugs.webkit.org/show_bug.cgi?id=26733
1981
1982         Add V8-only methods to FrameLoaderClient that V8 can use to send
1983         out notifications when it creates/destroys a script context.
1984
1985         * loader/EmptyClients.h:
1986         (WebCore::EmptyFrameLoaderClient::didCreateScriptContext):
1987         (WebCore::EmptyFrameLoaderClient::didDestroyScriptContext):
1988         * loader/FrameLoaderClient.h:
1989         (WebCore::FrameLoaderClient::didCreateScriptContext):
1990         (WebCore::FrameLoaderClient::didDestroyScriptContext):
1991
1992 2009-06-25  Dimitri Glazkov  <dglazkov@chromium.org>
1993
1994         Reviewed by David Levin.
1995
1996         Correct a few typos that snuck in when I was reformatting CodeGeneratorV8.pm
1997         to match WebKit style.
1998
1999         * bindings/scripts/CodeGeneratorV8.pm: Corrected lots of typos.
2000
2001 2009-06-25  Adam Langley  <agl@google.com>
2002
2003         TBRed: fix for Chromium tree.
2004
2005         Add missing include for r45199.
2006
2007         https://bugs.webkit.org/show_bug.cgi?id=26736
2008
2009         r45199 added a reference to throwError without including V8Proxy.h
2010
2011         * bindings/v8/WorkerScriptController.cpp:
2012
2013 2009-06-25  Adam Langley  <agl@google.com>
2014
2015         TBRed: fix for Chromium tree.
2016
2017         https://bugs.webkit.org/show_bug.cgi?id=26735
2018
2019         Fix V8IsolatedWorld to point to the correct include file.
2020
2021         The deprecated v8_index.h was removed from the Chromium tree in r19291
2022         and upstreamed into WebKit with r45193. However V8IsolatedWorld
2023         slipped in between the cracks and broke the build.
2024
2025         * bindings/v8/V8IsolatedWorld.h: update with new header location.
2026
2027 2009-06-25  Chris Marrin  <cmarrin@apple.com>
2028
2029         Reviewed by Simon Fraser  <simon.fraser@apple.com>.
2030
2031         https://bugs.webkit.org/show_bug.cgi?id=26651
2032         
2033         Preference is named "WebKitAcceleratedCompositingEnabled"
2034         and is a boolean value. When false, prevents compositing layers from
2035         being created, which prevents hardware animation from running.
2036         Also forces video to do software rendering. Added a cache for
2037         the flag in RenderLayerCompositing and made it all work
2038         on-the-fly when the flag is changed while a page is loaded.
2039
2040         * WebCore.base.exp:
2041         * page/FrameView.cpp:
2042         (WebCore::FrameView::updateCompositingLayers):
2043         * page/Settings.cpp:
2044         (WebCore::setNeedsReapplyStylesInAllFrames):
2045         (WebCore::Settings::Settings):
2046         (WebCore::Settings::setAcceleratedCompositingEnabled):
2047         * page/Settings.h:
2048         (WebCore::Settings::acceleratedCompositingEnabled):
2049         * rendering/RenderLayer.cpp:
2050         (WebCore::RenderLayer::hasAcceleratedCompositing):
2051         (WebCore::RenderLayer::updateTransform):
2052         (WebCore::RenderLayer::currentTransform):
2053         * rendering/RenderLayer.h:
2054         * rendering/RenderLayerBacking.cpp:
2055         (WebCore::RenderLayerBacking::updateLayerTransform):
2056         * rendering/RenderLayerCompositor.cpp:
2057         (WebCore::RenderLayerCompositor::RenderLayerCompositor):
2058         (WebCore::RenderLayerCompositor::enableCompositingMode):
2059         (WebCore::RenderLayerCompositor::cacheAcceleratedCompositingEnabledFlag):
2060         (WebCore::RenderLayerCompositor::updateCompositingLayers):
2061         (WebCore::RenderLayerCompositor::canAccelerateVideoRendering):
2062         (WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
2063         (WebCore::RenderLayerCompositor::needsToBeComposited):
2064         (WebCore::RenderLayerCompositor::destroyRootPlatformLayer):
2065         * rendering/RenderLayerCompositor.h:
2066         (WebCore::RenderLayerCompositor::hasAcceleratedCompositing):
2067         * rendering/RenderObject.h:
2068         (WebCore::makeMatrixRenderable):
2069
2070 2009-06-25  Jian Li  <jianli@chromium.org>
2071
2072         Reviewed by Dimitri Glazkov.
2073
2074         Bug 26701: Implement the missing code for "FIXME: Need to return an
2075         exception" in WorkerScriptController::evaluate for v8 bindings.
2076         https://bugs.webkit.org/show_bug.cgi?id=26701
2077
2078         * bindings/v8/WorkerScriptController.cpp:
2079         (WebCore::WorkerScriptController::evaluate):
2080
2081 2009-06-25  Nate Chapin  <japhet@chromium.org>
2082
2083         Reviewed by Dimitri Glazkov.
2084
2085         Upstream V8Index.
2086
2087         https://bugs.webkit.org/show_bug.cgi?id=26495
2088
2089         * bindings/v8/V8Index.cpp: Added.
2090         (WebCore::V8ClassIndex::GetFactory): Moved from src.chromium.org.
2091         (WebCore::V8ClassIndex::GetCache): Moved from src.chromium.org.
2092         * bindings/v8/V8Index.h:
2093         (WebCore::V8ClassIndex::): Moved from src.chromium.org.
2094         (WebCore::V8ClassIndex::ToInt): Moved from src.chromium.org.
2095         (WebCore::V8ClassIndex::FromInt): Moved from src.chromium.org.
2096
2097 2009-06-25  Adam Langley  <agl@google.com>
2098
2099         Reviewed by Darin Fisher.
2100
2101         https://bugs.webkit.org/show_bug.cgi?id=26529
2102
2103         This is hopefully the last step before our renderers can run
2104         cleanly in a chroot.
2105
2106         WebKit needs to be able to ask for the correct font to use in
2107         the case that the current font doesn't include glyphs for
2108         certain code points. Currently we make a fontconfig call in our
2109         WebKit port to handle this.
2110
2111         This patch changes this so that the call is sent our via
2112         ChromiumBridge.
2113
2114         http://codereview.chromium.org/132007
2115
2116         This should not affect any layout tests.
2117
2118         * platform/chromium/ChromiumBridge.h:
2119         * platform/graphics/chromium/FontCacheLinux.cpp:
2120         (WebCore::FontCache::getFontDataForCharacters):
2121
2122 2009-06-25  Albert J. Wong  <ajwong@chromium.org>
2123
2124         Reviewed by David Levin.
2125
2126         https://bugs.webkit.org/show_bug.cgi?id=26566
2127         Upstream these files from the chromium v8 code.  No tests were
2128         affected because this is essentially a code move.
2129
2130         * bindings/v8/NPV8Object.cpp: Added.
2131         (allocV8NPObject):
2132         (freeV8NPObject):
2133         (listFromVariantArgs):
2134         (npIdentifierToV8Identifier):
2135         (npCreateV8ScriptObject):
2136         (NPN_Invoke):
2137         (NPN_InvokeDefault):
2138         (NPN_Evaluate):
2139         (NPN_EvaluateHelper):
2140         (NPN_GetProperty):
2141         (NPN_SetProperty):
2142         (NPN_RemoveProperty):
2143         (NPN_HasProperty):
2144         (NPN_HasMethod):
2145         (NPN_SetException):
2146         (NPN_Enumerate):
2147         (NPN_Construct):
2148         * bindings/v8/NPV8Object.h: Added.
2149         (PrivateIdentifier::):
2150         * bindings/v8/V8NPUtils.cpp: Added.
2151         (convertV8ObjectToNPVariant):
2152         (convertNPVariantToV8Object):
2153         (getStringIdentifier):
2154         * bindings/v8/V8NPUtils.h: Added.
2155
2156 2009-06-25  Shinichiro Hamaji  <hamaji@chromium.org>
2157
2158         Reviewed by Dimitri Glazkov.
2159
2160         https://bugs.webkit.org/show_bug.cgi?id=26436
2161
2162         Windows Chromium bug fix: save context of destination canvas in
2163         TransparencyWin::compositeTextComposite() before the function
2164         modifies the context.
2165
2166         Test: fast/canvas/translate-text.html
2167
2168         * platform/graphics/chromium/TransparencyWin.cpp:
2169         (WebCore::TransparencyWin::compositeTextComposite):
2170
2171 2009-06-25  Patrick Mueller  <Patrick_Mueller@us.ibm.com>
2172
2173         Reviewed by Timothy Hatcher.
2174
2175         Show the filename and first line for "(program)" in the Profiler/Debugger
2176         https://bugs.webkit.org/show_bug.cgi?id=25475
2177
2178         Add support to associate a sourceURL with an eval()'d string
2179         via a @sourceURL comment.  Currently the sourceURL is only available
2180         in the script debugger, not in the console or profiler, but it's
2181         most needed in the script debugger.
2182
2183         * English.lproj/localizedStrings.js: added new "(program): %s" string
2184         * inspector/front-end/Script.js:
2185         (WebInspector.Script): if no sourceURL is available for the Script,
2186         search for a comment of the form //@ sourceURL=(url) to use
2187         as the sourceURL instead.
2188         * manual-tests/inspector/named-evals.html: Added.
2189
2190 2009-06-25  John Gregg  <johnnyg@google.com>
2191
2192         Reviewed by Sam Weinig.
2193
2194         Bug 23721: Changing dropdown's selectedIndex within onchange handler fires another onchange
2195         https://bugs.webkit.org/show_bug.cgi?id=23721
2196
2197         onchange events fire when a SELECT element has
2198         focus and the selectedIndex is updated by script in some way--either
2199         during another onchange, onkeypress, onfocus, or timer--and then
2200         focus is lost. 
2201
2202         Fixed by making a separate method for user-driven selectedIndex 
2203         changes, leaving scripts to use one which doesn't cause onchange to
2204         be queued.
2205         
2206         Test: fast/forms/select-script-onchange.html
2207
2208         * dom/SelectElement.cpp: check if the pending change is user driven
2209         before calling onchange
2210         (WebCore::SelectElement::menuListOnChange):
2211         (WebCore::SelectElement::setSelectedIndex):
2212         * dom/SelectElement.h: store whether the pending change is user driven
2213         (WebCore::SelectElementData::userDrivenChange):
2214         (WebCore::SelectElementData::setUserDrivenChange):
2215         * html/HTMLSelectElement.cpp: split into two methods -- script version
2216         [non-user-driven] corresponds to IDL defined property name
2217         (WebCore::HTMLSelectElement::setSelectedIndex):
2218         (WebCore::HTMLSelectElement::setSelectedIndexByUser):
2219         * html/HTMLSelectElement.h: 
2220         * rendering/RenderMenuList.cpp: use ByUser method when coming through
2221         the renderer
2222         (WebCore::RenderMenuList::valueChanged):
2223
2224 2009-06-25  Jeremy Orlow  <jorlow@chromium.org>
2225
2226         Reviewed by Darin Fisher.
2227
2228         https://bugs.webkit.org/show_bug.cgi?id=26698
2229
2230         Combined LocalStorageArea and SessionStorageArea into StorageArea since
2231         (after my other refactorings) there are no longer substantial
2232         differences between the two.
2233
2234         * GNUmakefile.am:
2235         * WebCore.vcproj/WebCore.vcproj:
2236         * WebCore.xcodeproj/project.pbxproj:
2237         * WebCoreSources.bkl:
2238         * storage/LocalStorage.cpp:
2239         (WebCore::LocalStorage::storageArea):
2240         * storage/LocalStorage.h:
2241         * storage/LocalStorageArea.cpp: Removed.
2242         * storage/LocalStorageArea.h: Removed.
2243         * storage/SessionStorage.cpp:
2244         (WebCore::SessionStorage::copy):
2245         (WebCore::SessionStorage::storageArea):
2246         * storage/SessionStorage.h:
2247         * storage/SessionStorageArea.cpp: Removed.
2248         * storage/SessionStorageArea.h: Removed.
2249         * storage/StorageArea.cpp:
2250         (WebCore::StorageArea::createLocalStorage):
2251         (WebCore::StorageArea::StorageArea):
2252         (WebCore::StorageArea::createSessionStorage):
2253         (WebCore::StorageArea::copy):
2254         (WebCore::StorageArea::setItem):
2255         (WebCore::StorageArea::removeItem):
2256         (WebCore::StorageArea::clear):
2257         (WebCore::StorageArea::scheduleFinalSync):
2258         (WebCore::StorageArea::blockUntilImportComplete):
2259         (WebCore::StorageArea::dispatchStorageEvent):
2260         * storage/StorageArea.h:
2261         * storage/StorageAreaSync.cpp:
2262         (WebCore::StorageAreaSync::StorageAreaSync):
2263         (WebCore::StorageAreaSync::scheduleFinalSync):
2264         (WebCore::StorageAreaSync::syncTimerFired):
2265         (WebCore::StorageAreaSync::performImport):
2266         * storage/StorageAreaSync.h:
2267         * storage/StorageSyncManager.h:
2268
2269 2009-06-25  Dan Bernstein  <mitz@apple.com>
2270
2271         Reviewed by Darin Adler.
2272
2273         - fix https://bugs.webkit.org/show_bug.cgi?id=26671
2274           <rdar://problem/7001880> Safari 4.0 crashes in
2275           WebCore::DOMTimer::fired()
2276
2277         Test: fast/dom/style-sheet-candidate-remove-unrendered-document.html
2278
2279         When a "style sheet candidate" element is removed from a document,
2280         call Document::removeStyleSheetCandidateNode() regardless of whether
2281         the document is rendered. Otherwise, the document's style sheet
2282         candidate set can end up containing stale references.
2283
2284         * dom/ProcessingInstruction.cpp:
2285         (WebCore::ProcessingInstruction::removedFromDocument):
2286         * html/HTMLLinkElement.cpp:
2287         (WebCore::HTMLLinkElement::removedFromDocument):
2288         * html/HTMLStyleElement.cpp:
2289         (WebCore::HTMLStyleElement::removedFromDocument):
2290
2291 2009-06-25  Dimitri Glazkov  <dglazkov@chromium.org>
2292
2293         Reviewed by Darin Fisher.
2294
2295         Update CodeGeneratorV8.pm to sync up with the changes downstream.
2296
2297         * bindings/scripts/CodeGeneratorV8.pm: Added HTMLFrameSetElement check,
2298           FileList as a ref-counted type, and DataGridColumn as typeCanFailConversion.
2299
2300 2009-06-25  Dimitri Glazkov  <dglazkov@chromium.org>
2301
2302         Unreviewed, build fix.
2303
2304         Add FileList.h include to fix Chromium build.
2305
2306         * platform/chromium/ClipboardChromium.cpp: Added FileList.h include.
2307
2308 2009-06-25  Joseph Pecoraro  <joepeck02@gmail.com>
2309
2310         Reviewed by Jan Alonzo.
2311
2312         Bug 26489: Web Inspector: Typo in DatabaseQuery Error Message
2313         https://bugs.webkit.org/show_bug.cgi?id=26489
2314
2315         Fixed a Typo in a Web Inspector error message.
2316
2317         * English.lproj/localizedStrings.js:
2318         * inspector/front-end/DatabaseQueryView.js:
2319         (WebInspector.DatabaseQueryView.prototype._queryError):
2320
2321 2009-06-25  Simon Hausmann  <simon.hausmann@nokia.com>
2322
2323         Fix the Qt build, add missing StorageAreaSync files to the build.
2324
2325         * WebCore.pro:
2326
2327 2009-06-25  Simon Hausmann  <simon.hausmann@nokia.com>
2328
2329         Reviewed by and done with Tor Arne Vestbø.
2330
2331         Fix shortcut keyboard handling with plugins on the Qt/Mac build.
2332
2333         When we receive shortcut events like Ctrl+V then the text in the QKeyEvent is
2334         empty. If we're asked to disambiguate the event into a Char keyboard event,
2335         we try to detect this situation and still set the text, to ensure that the
2336         general event handling sends a key press event after this disambiguation.
2337
2338         * platform/qt/PlatformKeyboardEventQt.cpp:
2339         (WebCore::PlatformKeyboardEvent::disambiguateKeyDownEvent):
2340
2341 2009-06-25  Eric Seidel  <eric@webkit.org>
2342
2343         Build fix only, no review.
2344
2345         Add FileList.h and NotImplemented.h includes in an attempt to fix bots.
2346
2347         * platform/gtk/ClipboardGtk.cpp:
2348         * platform/qt/ClipboardQt.cpp:
2349         * platform/win/ClipboardWin.cpp:
2350         * platform/wx/ClipboardWx.cpp:
2351
2352 2009-05-21  Eric Seidel  <eric@webkit.org>
2353
2354         Reviewed by Maciej Stachowiak.
2355
2356         Expose files in the clipboard in ondrop events
2357         https://bugs.webkit.org/show_bug.cgi?id=25916
2358
2359         Make it possible for applications like gmail to implement
2360         drag and drop of attachments onto email messages.
2361
2362         This patch exposes an event.dataTransfer.files accessor
2363         on the drop event.  No information is exposed during dragover.
2364         This follows the HTML 5 drag and drop security model:
2365         http://www.w3.org/TR/html5/editing.html#security-risks-in-the-drag-and-drop-model
2366         The test http/tests/security/clipboard/clipboard-file-access.html
2367         verifies this behavior.
2368
2369         Internet Explorer shows historical documentation of supporting
2370         getData('File') as a way of exposing files on the pasteboard.  The current version of their docs:
2371         http://msdn.microsoft.com/en-us/library/ms537658(VS.85).aspx
2372         has removed this reference (as far as I can tell IE never implemented it)
2373         I have a printed copy of that URL from 2008 on my desk describing getData('File') in IE.
2374         IE does not follow the HTML5 clipboard security model and always allows access to the full clipboard, even on dragover.
2375
2376         I choose not to use IE's getData('File') and instead added .files
2377         so that the accessor could have a type, matching WebKit's existing
2378         .files accessor on HTMLInputElement.
2379
2380         Mozilla has equivalent file access:
2381         event.dataTransfer.mozGetDataAt("application/x-moz-file", 0);
2382         which also does not return a typed value.
2383         https://developer.mozilla.org/En/DragDrop/Recommended_Drag_Types#Dragging_Files
2384
2385         This is only implemented for Mac WebKit.  All other platforms (including Apple's Win WebKit)
2386         have incomplete Clipboard implementations and will require experts from those platforms
2387         to add this functionality.  Right now they all have Clipboard*::files() methods which call notImplemented();
2388
2389         Test: http/tests/security/clipboard/clipboard-file-access.html
2390
2391         * dom/Clipboard.h:
2392         * dom/Clipboard.idl:
2393         * platform/chromium/ClipboardChromium.cpp:
2394         (WebCore::ClipboardChromium::files):
2395         * platform/chromium/ClipboardChromium.h:
2396         * platform/gtk/ClipboardGtk.cpp:
2397         (WebCore::ClipboardGtk::files):
2398         * platform/gtk/ClipboardGtk.h:
2399         * platform/mac/ClipboardMac.h:
2400         * platform/mac/ClipboardMac.mm:
2401         (WebCore::absoluteURLsFromPasteboardFilenames):
2402         (WebCore::absoluteURLsFromPasteboard):
2403         (WebCore::ClipboardMac::files):
2404         * platform/qt/ClipboardQt.cpp:
2405         (WebCore::ClipboardQt::files):
2406         * platform/qt/ClipboardQt.h:
2407         * platform/win/ClipboardWin.cpp:
2408         (WebCore::ClipboardWin::files):
2409         * platform/win/ClipboardWin.h:
2410         * platform/wx/ClipboardWx.cpp:
2411         (WebCore::ClipboardWx::files):
2412         * platform/wx/ClipboardWx.h:
2413
2414 2009-06-25  Eric Seidel  <eric@webkit.org>
2415
2416         No review, only completing revert of r45144.
2417
2418         Add back files deleted by r45144.
2419
2420         * storage/LocalStorageArea.cpp: Added.
2421         (WebCore::LocalStorageArea::create):
2422         (WebCore::LocalStorageArea::LocalStorageArea):
2423         (WebCore::LocalStorageArea::scheduleFinalSync):
2424         (WebCore::LocalStorageArea::itemChanged):
2425         (WebCore::LocalStorageArea::itemRemoved):
2426         (WebCore::LocalStorageArea::areaCleared):
2427         (WebCore::LocalStorageArea::blockUntilImportComplete):
2428         (WebCore::LocalStorageArea::dispatchStorageEvent):
2429         * storage/LocalStorageArea.h: Added.
2430         * storage/SessionStorageArea.cpp: Added.
2431         (WebCore::SessionStorageArea::copy):
2432         (WebCore::SessionStorageArea::SessionStorageArea):
2433         (WebCore::SessionStorageArea::itemChanged):
2434         (WebCore::SessionStorageArea::itemRemoved):
2435         (WebCore::SessionStorageArea::areaCleared):
2436         (WebCore::SessionStorageArea::blockUntilImportComplete):
2437         (WebCore::SessionStorageArea::dispatchStorageEvent):
2438         * storage/SessionStorageArea.h: Added.
2439         (WebCore::SessionStorageArea::create):
2440
2441 2009-06-25  Eric Seidel  <eric@webkit.org>
2442
2443         No review, reverting r45144 only.
2444
2445         Roll out r45144 after 18 test failures appeared on the bots.
2446         https://bugs.webkit.org/show_bug.cgi?id=26698
2447
2448         * GNUmakefile.am:
2449         * WebCore.vcproj/WebCore.vcproj:
2450         * WebCore.xcodeproj/project.pbxproj:
2451         * WebCoreSources.bkl:
2452         * storage/LocalStorage.cpp:
2453         (WebCore::LocalStorage::storageArea):
2454         * storage/LocalStorage.h:
2455         * storage/SessionStorage.cpp:
2456         (WebCore::SessionStorage::copy):
2457         (WebCore::SessionStorage::storageArea):
2458         * storage/SessionStorage.h:
2459         * storage/StorageArea.cpp:
2460         (WebCore::StorageArea::StorageArea):
2461         (WebCore::StorageArea::~StorageArea):
2462         (WebCore::StorageArea::setItem):
2463         (WebCore::StorageArea::removeItem):
2464         (WebCore::StorageArea::clear):
2465         * storage/StorageArea.h:
2466         * storage/StorageAreaSync.cpp:
2467         (WebCore::StorageAreaSync::StorageAreaSync):
2468         (WebCore::StorageAreaSync::scheduleFinalSync):
2469         (WebCore::StorageAreaSync::syncTimerFired):
2470         (WebCore::StorageAreaSync::performImport):
2471         * storage/StorageAreaSync.h:
2472         * storage/StorageSyncManager.h:
2473
2474 2009-06-24  Jeremy Orlow  <jorlow@chromium.org>
2475
2476         Reviewed by Darin Fisher.
2477
2478         https://bugs.webkit.org/show_bug.cgi?id=26698
2479
2480         Combined LocalStorageArea and SessionStorageArea into StorageArea since
2481         (after my other refactorings) there are no longer substantial
2482         differences between the two.
2483
2484         * GNUmakefile.am:
2485         * WebCore.vcproj/WebCore.vcproj:
2486         * WebCore.xcodeproj/project.pbxproj:
2487         * WebCoreSources.bkl:
2488         * storage/LocalStorage.cpp:
2489         (WebCore::LocalStorage::storageArea):
2490         * storage/LocalStorage.h:
2491         * storage/LocalStorageArea.cpp: Removed.
2492         * storage/LocalStorageArea.h: Removed.
2493         * storage/SessionStorage.cpp:
2494         (WebCore::SessionStorage::copy):
2495         (WebCore::SessionStorage::storageArea):
2496         * storage/SessionStorage.h:
2497         * storage/SessionStorageArea.cpp: Removed.
2498         * storage/SessionStorageArea.h: Removed.
2499         * storage/StorageArea.cpp:
2500         (WebCore::StorageArea::createLocalStorage):
2501         (WebCore::StorageArea::StorageArea):
2502         (WebCore::StorageArea::createSessionStorage):
2503         (WebCore::StorageArea::copy):
2504         (WebCore::StorageArea::setItem):
2505         (WebCore::StorageArea::removeItem):
2506         (WebCore::StorageArea::clear):
2507         (WebCore::StorageArea::scheduleFinalSync):
2508         (WebCore::StorageArea::blockUntilImportComplete):
2509         (WebCore::StorageArea::dispatchStorageEvent):
2510         * storage/StorageArea.h:
2511         * storage/StorageAreaSync.cpp:
2512         (WebCore::StorageAreaSync::StorageAreaSync):
2513         (WebCore::StorageAreaSync::scheduleFinalSync):
2514         (WebCore::StorageAreaSync::syncTimerFired):
2515         (WebCore::StorageAreaSync::performImport):
2516         * storage/StorageAreaSync.h:
2517         * storage/StorageSyncManager.h:
2518
2519 2009-06-24  Dan Bernstein  <mitz@apple.com>
2520
2521         Reviewed by Simon Fraser.
2522
2523         - fix <rdar://problem/7001817> REGRESSION (r41902): Base position track
2524           at UCSC Genome Browser doesn't work because image map prevents img
2525           from hit-testing
2526
2527         Test: fast/replaced/image-map-2.html
2528
2529         * rendering/RenderImage.cpp:
2530         (WebCore::RenderImage::nodeAtPoint): Do not reset 'inside' to false if
2531         the image map failed the hit test.
2532
2533 2009-06-22  Adam Barth  <abarth@webkit.org>
2534
2535         Reviewed by Dimitri Glazkov.
2536
2537         https://bugs.webkit.org/show_bug.cgi?id=26366
2538
2539         Refactor V8DOMMap to support isolated worlds.
2540
2541         * bindings/v8/ScriptController.cpp:
2542         (WebCore::ScriptController::evaluateInNewWorld):
2543         * bindings/v8/ScriptController.h:
2544         * bindings/v8/V8DOMMap.cpp:
2545         (WebCore::DOMDataStore::InternalDOMWrapperMap::InternalDOMWrapperMap):
2546         (WebCore::DOMDataStore::allStores):
2547         (WebCore::DOMDataStore::allStoresMutex):
2548         (WebCore::DOMDataStore::domData):
2549         (WebCore::ScopedDOMDataStore::ScopedDOMDataStore):
2550         (WebCore::ScopedDOMDataStore::~ScopedDOMDataStore):
2551         (WebCore::StaticDOMDataStore::StaticDOMDataStore):
2552         (WebCore::):
2553         (WebCore::MainThreadDOMData::MainThreadDOMData):
2554         (WebCore::MainThreadDOMData::getStore):
2555         (WebCore::ChildThreadDOMData::ChildThreadDOMData):
2556         (WebCore::ChildThreadDOMData::getStore):
2557         (WebCore::DOMDataStore::DOMDataStore):
2558         (WebCore::DOMDataStore::~DOMDataStore):
2559         (WebCore::DOMDataStoreHandle::DOMDataStoreHandle):
2560         (WebCore::DOMDataStoreHandle::~DOMDataStoreHandle):
2561         (WebCore::::forget):
2562         (WebCore::getDOMNodeMap):
2563         (WebCore::getDOMObjectMap):
2564         (WebCore::getActiveDOMObjectMap):
2565         (WebCore::getDOMSVGElementInstanceMap):
2566         (WebCore::getDOMSVGObjectWithContextMap):
2567         (WebCore::DOMData::getCurrent):
2568         (WebCore::DOMData::handleWeakObject):
2569         (WebCore::DOMData::ensureDeref):
2570         (WebCore::weakDOMObjectCallback):
2571         (WebCore::weakActiveDOMObjectCallback):
2572         (WebCore::weakNodeCallback):
2573         (WebCore::weakSVGElementInstanceCallback):
2574         (WebCore::weakSVGObjectWithContextCallback):
2575         (WebCore::DOMData::derefObject):
2576         (WebCore::DOMData::derefDelayedObjects):
2577         (WebCore::DOMData::derefDelayedObjectsInCurrentThread):
2578         (WebCore::DOMData::removeObjectsFromWrapperMap):
2579         (WebCore::removeAllDOMObjectsInCurrentThreadHelper):
2580         (WebCore::visitDOMNodesInCurrentThread):
2581         (WebCore::visitDOMObjectsInCurrentThread):
2582         (WebCore::visitActiveDOMObjectsInCurrentThread):
2583         (WebCore::visitDOMSVGElementInstancesInCurrentThread):
2584         (WebCore::visitSVGObjectsInCurrentThread):
2585         * bindings/v8/V8DOMMap.h:
2586         (WebCore::DOMDataStoreHandle::getStore):
2587         * bindings/v8/V8IsolatedWorld.cpp: Added.
2588         (WebCore::getIsolatedWorldKey):
2589         (WebCore::contextWeakReferenceCallback):
2590         (WebCore::V8IsolatedWorld::evaluate):
2591         (WebCore::V8IsolatedWorld::V8IsolatedWorld):
2592         (WebCore::V8IsolatedWorld::~V8IsolatedWorld):
2593         (WebCore::V8IsolatedWorld::getEntered):
2594         * bindings/v8/V8IsolatedWorld.h: Added.
2595         (WebCore::V8IsolatedWorld::getDOMDataStore):
2596
2597 2009-06-24  Mikhail Naganov  <mnaganov@chromium.org>
2598
2599         Reviewed by Timothy Hatcher.
2600
2601         Bug 26604: Search doesn't work in Web Inspector Profiler
2602         https://bugs.webkit.org/show_bug.cgi?id=26604
2603
2604         Seems like search was damaged in revision 42808.
2605
2606         * inspector/front-end/ProfileView.js:
2607         (WebInspector.ProfileView.prototype.refresh):
2608         Here and in other functions: nodes we're searching in are profile data grid
2609         nodes, so there is no more need for '_dataGridNode' references.
2610         (WebInspector.ProfileView.prototype.searchCanceled):
2611         (WebInspector.ProfileView.prototype.performSearch.matchesQuery):
2612         Fixed accidental semicolon that caused 'matchesQuery' always return true.
2613         (WebInspector.ProfileView.prototype.performSearch):
2614         To perform search correctly in the case of bottom up tree, we need to populate
2615         the tree, because there's no 1-to-1 correspondence between profile nodes and
2616         data grid nodes in this case.
2617         (WebInspector.ProfileView.prototype._jumpToSearchResult):
2618
2619 2009-06-24  Simon Fraser  <simon.fraser@apple.com>
2620
2621         Reviewed by Darin Adler.
2622         
2623         <rdar://problem/6450239&6574516>
2624     
2625         Fix flashing issues caused by compositing layers rendering content before
2626         a deferred layout has happened. Because the -viewWillDraw machinery doesn't
2627         work for composited layers, we need to use scheduleViewUpdate() to queue
2628         up a layout via the run loop observer in WebKit, whenever we know we
2629         are going to be painting soon.
2630
2631         * rendering/RenderLayerBacking.cpp:
2632         (WebCore::RenderLayerBacking::setContentsNeedDisplay):
2633         (WebCore::RenderLayerBacking::setContentsNeedDisplayInRect):
2634
2635 2009-06-24  David Levin  <levin@chromium.org>
2636
2637         Fix all builds.
2638
2639         * ForwardingHeaders/wtf/FastAllocBase.h: Added.
2640
2641 2009-06-24  Jeremy Orlow  <jorlow@chromium.org>
2642
2643         Reviewed by Darin Fisher.
2644
2645         https://bugs.webkit.org/show_bug.cgi?id=26658
2646
2647         Split the syncing portions of LocalStorageArea into StorageAreaSync.
2648         This name will make more sense in the next patch (in this set) when
2649         LocalStorageArea and SessionStorageArea are merged to become simply
2650         StorageArea.  (Thus the synching portion of StorageArea is in
2651         StorageAreaSync.)
2652
2653         This looks like a big patch, but really all it's doing is splitting
2654         code and patching split-related things up.
2655
2656         * GNUmakefile.am:
2657         * WebCore.vcproj/WebCore.vcproj:
2658         * WebCore.xcodeproj/project.pbxproj:
2659         * WebCoreSources.bkl:
2660         * storage/LocalStorageArea.cpp:
2661         (WebCore::LocalStorageArea::create):
2662         (WebCore::LocalStorageArea::LocalStorageArea):
2663         (WebCore::LocalStorageArea::scheduleFinalSync):
2664         (WebCore::LocalStorageArea::itemChanged):
2665         (WebCore::LocalStorageArea::itemRemoved):
2666         (WebCore::LocalStorageArea::areaCleared):
2667         (WebCore::LocalStorageArea::blockUntilImportComplete):
2668         * storage/LocalStorageArea.h:
2669         * storage/LocalStorageTask.cpp:
2670         (WebCore::LocalStorageTask::LocalStorageTask):
2671         * storage/LocalStorageTask.h:
2672         (WebCore::LocalStorageTask::createImport):
2673         (WebCore::LocalStorageTask::createSync):
2674         * storage/LocalStorageThread.cpp:
2675         (WebCore::LocalStorageThread::scheduleImport):
2676         (WebCore::LocalStorageThread::scheduleSync):
2677         * storage/LocalStorageThread.h:
2678         * storage/SessionStorageArea.cpp:
2679         (WebCore::SessionStorageArea::blockUntilImportComplete):
2680         * storage/SessionStorageArea.h:
2681         * storage/StorageArea.h:
2682         * storage/StorageAreaSync.cpp: Copied from WebCore/storage/LocalStorageArea.cpp.
2683         * storage/StorageAreaSync.h: Copied from WebCore/storage/LocalStorageArea.h.
2684         * storage/StorageSyncManager.cpp:
2685         (WebCore::StorageSyncManager::scheduleImport):
2686         (WebCore::StorageSyncManager::scheduleSync):
2687         * storage/StorageSyncManager.h:
2688
2689 2009-06-24  Adam Treat  <adam.treat@torchmobile.com>
2690
2691         Fix Qt build.
2692
2693         * WebCore.pro:
2694
2695 2009-06-24  David Levin  <levin@chromium.org>
2696
2697         Reviewed by David Hyatt.
2698
2699         Bug 26696: Member functions in DataGridColumnList should return pointers instead of PassRefPtr.
2700         https://bugs.webkit.org/show_bug.cgi?id=26696
2701
2702         * html/DataGridColumnList.cpp:
2703         (WebCore::DataGridColumnList::itemWithName):
2704         (WebCore::DataGridColumnList::add):
2705         * html/DataGridColumnList.h:
2706         (WebCore::DataGridColumnList::item):
2707         (WebCore::DataGridColumnList::primaryColumn):
2708         (WebCore::DataGridColumnList::sortColumn):
2709
2710 2009-06-24  Sam Weinig  <sam@webkit.org>
2711
2712         Reviewed by Dave "Messy" Hyatt.
2713
2714         Little bit of style cleanup.
2715
2716         * html/DataGridColumn.cpp:
2717         * html/DataGridColumn.h:
2718         * html/DataGridColumn.idl:
2719         * html/DataGridColumnList.cpp:
2720         * html/DataGridColumnList.h:
2721         * html/DataGridColumnList.idl:
2722         * html/HTMLDataGridCellElement.cpp:
2723         * html/HTMLDataGridCellElement.h:
2724         * html/HTMLDataGridCellElement.idl:
2725         * html/HTMLDataGridColElement.cpp:
2726         * html/HTMLDataGridColElement.h:
2727         * html/HTMLDataGridColElement.idl:
2728         * html/HTMLDataGridElement.h:
2729         * html/HTMLDataGridElement.idl:
2730         * html/HTMLDataGridRowElement.cpp:
2731         * html/HTMLDataGridRowElement.h:
2732         * html/HTMLDataGridRowElement.idl:
2733
2734 2009-06-24  Chris Fleizach  <cfleizach@apple.com>
2735
2736         Reviewed by Oliver Hunt.
2737
2738         Bug 26668: AX: need a way to retrieve the language for an element
2739         
2740         Provides a way to retrieve the language associated with a specific accessibility element.
2741
2742         Test: accessibility/language-attribute.html
2743
2744         * accessibility/AccessibilityObject.cpp:
2745         (WebCore::AccessibilityObject::language):
2746         * accessibility/AccessibilityObject.h:
2747         * accessibility/AccessibilityRenderObject.cpp:
2748         (WebCore::AccessibilityRenderObject::language):
2749         * accessibility/AccessibilityRenderObject.h:
2750         * accessibility/mac/AccessibilityObjectWrapper.mm:
2751         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
2752
2753 2009-06-24  Brady Eidson  <beidson@apple.com>
2754
2755         Reviewed by Dan Bernstein.
2756         
2757         <rdar://problem/6893811> Instead of downloading files linked from Google Earth, file contents displayed in browser window as text.
2758
2759         * platform/network/mac/WebCoreURLResponse.mm:
2760         (createBinaryExtensionsSet): Add '.kmz' to the list of known-to-be-binary extensions.
2761
2762 2009-06-24  Nicolas Weber  <thakis@chromium.org>
2763
2764         Reviewed by Eric Seidel.
2765
2766         https://bugs.webkit.org/show_bug.cgi?id=26685
2767         Accomodate for backwards-incompatible skia api changes.
2768
2769         * platform/graphics/skia/GraphicsContextSkia.cpp:
2770         (WebCore::GraphicsContext::clearRect):
2771         (WebCore::GraphicsContext::setCompositeOperation):
2772         * platform/graphics/skia/ImageBufferSkia.cpp:
2773         (WebCore::ImageBuffer::ImageBuffer):
2774         * platform/graphics/skia/ImageSkia.cpp:
2775         (WebCore::paintSkBitmap):
2776         (WebCore::Image::drawPattern):
2777         * platform/graphics/skia/PlatformContextSkia.cpp:
2778         (PlatformContextSkia::State::State):
2779         (PlatformContextSkia::setupPaintCommon):
2780         (PlatformContextSkia::setXfermodeMode):
2781         (PlatformContextSkia::applyClipFromImage):
2782         * platform/graphics/skia/PlatformContextSkia.h:
2783         * platform/graphics/skia/SkiaUtils.cpp:
2784         (WebCore::):
2785         (WebCore::WebCoreCompositeToSkiaComposite):
2786         * platform/graphics/skia/SkiaUtils.h:
2787
2788 2009-06-24  Jan Michael Alonzo  <jmalonzo@webkit.org>
2789
2790         Gtk build fix. Add files that were added in r45093 and r45096
2791
2792         * GNUmakefile.am:
2793
2794 2009-06-24  Brady Eidson  <beidson@apple.com>
2795
2796         Fix 64-bit SnowLeopard build.
2797
2798         * html/DataGridColumnList.cpp:
2799         (WebCore::DataGridColumnList::remove):
2800         (WebCore::DataGridColumnList::move):
2801
2802 2009-06-24  Rob Buis  <rwlbuis@gmail.com>
2803
2804         Reviewed by Eric Seidel.
2805
2806         https://bugs.webkit.org/show_bug.cgi?id=26392
2807         Bug 26392: In html, modification of xlink:href of an newly inserted svg image does not work.
2808         https://bugs.webkit.org/show_bug.cgi?id=26328
2809         Bug 26328: changing href attribute of svg images does not work when changing display attribute as well
2810
2811         React to href updates even when there is no renderer, i.e. display=none.
2812
2813         Tests: svg/custom/js-update-image-and-display.svg
2814                svg/custom/js-update-image-and-display2.svg
2815                svg/custom/js-update-image-and-display3.svg
2816
2817         * svg/SVGImageElement.cpp:
2818         (WebCore::SVGImageElement::svgAttributeChanged):
2819
2820 2009-06-24  David Hyatt  <hyatt@apple.com>
2821
2822         Reviewed by Sam Weinig.
2823
2824         https://bugs.webkit.org/show_bug.cgi?id=26687
2825
2826         Add basic back-end column support to datagrid.
2827
2828         Added fast/dom/HTMLDataGridElement/ column tests.
2829
2830         * DerivedSources.cpp:
2831         * DerivedSources.make:
2832         * WebCore.pro:
2833         * WebCore.vcproj/WebCore.vcproj:
2834         * WebCore.xcodeproj/project.pbxproj:
2835         * WebCoreSources.bkl:
2836         * html/DataGridColumn.cpp: Added.
2837         (WebCore::DataGridColumn::setPrimary):
2838         * html/DataGridColumn.h: Added.
2839         (WebCore::DataGridColumn::create):
2840         (WebCore::DataGridColumn::id):
2841         (WebCore::DataGridColumn::setId):
2842         (WebCore::DataGridColumn::label):
2843         (WebCore::DataGridColumn::setLabel):
2844         (WebCore::DataGridColumn::type):
2845         (WebCore::DataGridColumn::setType):
2846         (WebCore::DataGridColumn::sortable):
2847         (WebCore::DataGridColumn::setSortable):
2848         (WebCore::DataGridColumn::sortDirection):
2849         (WebCore::DataGridColumn::setSortDirection):
2850         (WebCore::DataGridColumn::primary):
2851         (WebCore::DataGridColumn::detachFromColumnList):
2852         (WebCore::DataGridColumn::DataGridColumn):
2853         * html/DataGridColumn.idl: Added.
2854         * html/DataGridColumnList.cpp: Added.
2855         (WebCore::DataGridColumnList::~DataGridColumnList):
2856         (WebCore::DataGridColumnList::itemWithName):
2857         (WebCore::DataGridColumnList::add):
2858         (WebCore::DataGridColumnList::remove):
2859         (WebCore::DataGridColumnList::move):
2860         (WebCore::DataGridColumnList::clear):
2861         (WebCore::DataGridColumnList::primaryColumnChanged):
2862         * html/DataGridColumnList.h: Added.
2863         (WebCore::DataGridColumnList::create):
2864         (WebCore::DataGridColumnList::length):
2865         (WebCore::DataGridColumnList::item):
2866         (WebCore::DataGridColumnList::primaryColumn):
2867         (WebCore::DataGridColumnList::sortColumn):
2868         * html/DataGridColumnList.idl: Added.
2869         * html/HTMLDataGridColElement.cpp:
2870         (WebCore::HTMLDataGridColElement::sortable):
2871         (WebCore::HTMLDataGridColElement::setSortable):
2872         (WebCore::HTMLDataGridColElement::sortDirection):
2873         (WebCore::HTMLDataGridColElement::setSortDirection):
2874         * html/HTMLDataGridColElement.h:
2875         * html/HTMLDataGridColElement.idl:
2876         * html/HTMLDataGridElement.cpp:
2877         (WebCore::HTMLDataGridElement::HTMLDataGridElement):
2878         * html/HTMLDataGridElement.h:
2879         (WebCore::HTMLDataGridElement::columns):
2880         * html/HTMLDataGridElement.idl:
2881         * rendering/RenderDataGrid.cpp:
2882         (WebCore::RenderDataGrid::paintObject):
2883         (WebCore::RenderDataGrid::paintColumnHeaders):
2884         (WebCore::RenderDataGrid::rebuildColumns):
2885         * rendering/RenderDataGrid.h:
2886         (WebCore::RenderDataGrid::gridElement):
2887
2888 2009-06-24  Jessie Berlin  <jberlin@apple.com>
2889
2890         Reviewed by Adam Roben.
2891
2892         Partially fixes: https://bugs.webkit.org/show_bug.cgi?id=24735
2893         (<rdar://problem/5015942>)
2894         Where on windows it was not possible to set an element as the drag
2895         image using setDragImage on the dataTransfer object.
2896         
2897         Does not "fix" the case of dragging a link where the default link image
2898         is still used, even when the -webkit-user-drag is set to "element". This
2899         is the same behavior as is found on OS X.
2900         
2901         Added a manual test because it is not possible to check that what is
2902         contained in the image snapshot is indeed the requested element.
2903
2904         * dom/Clipboard.h:
2905         (WebCore::Clipboard::dragImageElement):
2906         Made getting the raw pointer from the RefPtr a const operation.
2907         * manual-tests/drag-with-div-or-image-as-data-image.html: Added.
2908         * platform/win/ClipboardWin.cpp:
2909         (WebCore::ClipboardWin::createDragImage):
2910         Get an image of the rendered element and its subtree.
2911
2912 2009-06-24  Darin Fisher  <darin@chromium.org>
2913
2914         Reviewed by David Levin.
2915
2916         https://bugs.webkit.org/show_bug.cgi?id=26683
2917         Fix Chromium build bustage: Add custom binding for HTMLDataGridElement.dataSource
2918
2919         This change just adds a stub implementation for now to help fix the build.
2920
2921         * bindings/v8/custom/V8CustomBinding.h:
2922         * bindings/v8/custom/V8HTMLDataGridElementCustom.cpp: Added.
2923
2924 2009-06-24  David Kilzer  <ddkilzer@apple.com>
2925
2926         Build fixes for ENABLE(PLUGIN_PROXY_FOR_VIDEO)
2927
2928         Reviewed by Adam Roben.
2929
2930         * html/HTMLMediaElement.cpp:
2931         (WebCore::HTMLMediaElement::deliverNotification): Removed
2932         ExceptionCode parameter from togglePlayState().
2933         (WebCore::HTMLMediaElement::initialURL): Don't convert a KURL
2934         object to a String when assigning to a KURL variable.
2935
2936 2009-06-24  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2937
2938         Reviewed by Adam Treat.
2939
2940         Save memory by not storing attribute values in member variables, if not absolutely needed.
2941         Also fixes bugs where we're substituting variables too early (noticeable with the upcoming <select> element).
2942
2943         * wml/WMLDoElement.cpp:
2944         (WebCore::WMLDoElement::parseMappedAttribute):
2945         (WebCore::WMLDoElement::label):
2946         * wml/WMLDoElement.h:
2947         * wml/WMLFieldSetElement.cpp:
2948         (WebCore::WMLFieldSetElement::insertedIntoDocument):
2949         * wml/WMLFieldSetElement.h:
2950         * wml/WMLOptGroupElement.cpp:
2951         (WebCore::WMLOptGroupElement::title):
2952         (WebCore::WMLOptGroupElement::parseMappedAttribute):
2953         (WebCore::WMLOptGroupElement::groupLabelText):
2954         * wml/WMLOptGroupElement.h:
2955         * wml/WMLPostfieldElement.cpp:
2956         (WebCore::WMLPostfieldElement::name):
2957         (WebCore::WMLPostfieldElement::value):
2958         (WebCore::WMLPostfieldElement::encodeData):
2959         * wml/WMLPostfieldElement.h:
2960         * wml/WMLSetvarElement.cpp:
2961         (WebCore::WMLSetvarElement::parseMappedAttribute):
2962         (WebCore::WMLSetvarElement::name):
2963         (WebCore::WMLSetvarElement::value):
2964         * wml/WMLSetvarElement.h:
2965         * wml/WMLTimerElement.cpp:
2966         (WebCore::WMLTimerElement::parseMappedAttribute):
2967         (WebCore::WMLTimerElement::insertedIntoDocument):
2968         (WebCore::WMLTimerElement::timerFired):
2969         (WebCore::WMLTimerElement::start):
2970         (WebCore::WMLTimerElement::value):
2971         * wml/WMLTimerElement.h:
2972
2973 2009-06-24  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2974
2975         Reviewed by Adam Roben.
2976
2977         Forgot to initialize m_task member variable. Results in crashes sometimes.
2978
2979         * wml/WMLAnchorElement.cpp:
2980         (WebCore::WMLAnchorElement::WMLAnchorElement):
2981
2982 2009-06-24  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2983
2984         Not reviewed. Forgot to include within last patch.
2985
2986         * manual-tests/wml/card-title-attr.wml: Added.
2987
2988 2009-06-24  Wajahat Siddiqui <wajahatmeister@gmail.com>
2989  
2990         Reviewed by Nikolas Zimmermann.
2991
2992         Fixes: https://bugs.webkit.org/show_bug.cgi?id=26474
2993         Adding WML <card> title attribute handling.
2994
2995         * wml/WMLElement.h: marking parseValueSubstitutingVariableReferences and parseValueForbiddingVariableReferences as const
2996         * wml/WMLElement.cpp:
2997         * wml/WMLCardElement.h: 
2998         (WebCore::WMLCardElement::title):
2999         * wml/WMLCardElement.cpp:
3000         * wml/manual-test/card-title-attr.wml: Manual test  
3001  
3002 2009-06-24  Simon Hausmann  <simon.hausmann@nokia.com>
3003
3004         Reviewed by Tor Arne Vestbø.
3005
3006         Fix the build without ENABLE_VIDEO.
3007
3008         * html/CanvasRenderingContext2D.cpp: Add #if ENABLE guards.
3009         * html/CanvasRenderingContext2D.h: Ditto.
3010
3011 2009-06-24  Siddhartha Chattopadhyay  <sidchat@google.com>
3012
3013         Reviewed by Eric Seidel.
3014
3015         Fix for https://bugs.webkit.org/show_bug.cgi?id=26200 which I introduced earlier. I had
3016         the smartReplace set TRUE initially, which was wrong since the purpose of this call is
3017         to just replace the selection, and place the caret at the end of the selection it replaced.
3018
3019         * editing/Editor.cpp:
3020         (WebCore::Editor::markMisspellingsAfterTypingToPosition):
3021         * manual-tests/textarea-caret-position-after-auto-spell-correct.html: Added.
3022
3023 2009-06-24  Kevin Watters  <kevinwatters@gmail.com>
3024
3025         Reviewed by Kevin Ollivier.
3026
3027         Don't use an unsigned int for intervalInMS because we sometimes initialize
3028         it with a negative value.
3029
3030         * platform/wx/SharedTimerWx.cpp:
3031         (WebCore::setSharedTimerFireTime):
3032
3033 2009-06-24  Eric Seidel  <eric@webkit.org>
3034
3035         No review, build fix only.
3036
3037         The previous checkin had an improper merge.  This fixes the build.
3038
3039         * page/DragController.cpp:
3040         (WebCore::DragController::tryDocumentDrag):
3041
3042 2009-06-05  Eric Seidel  <eric@webkit.org>
3043
3044         Reviewed by Oliver Hunt.
3045
3046         https://bugs.webkit.org/show_bug.cgi?id=25922
3047         JS setting dropEffect = "none" causes tryDHTMLDrag
3048         to return DragOperationNone.  Which is also the value
3049         tryDHTMLDrag previously used to indicate JS did not
3050         want to handle the drag.
3051
3052         Make it possible for the DragController::try* methods
3053         to return a bool to indicate if javascript accepted
3054         or rejected the drag event, separate from the DragOperation.
3055
3056         Tests:
3057         - fast/events/drag-to-navigate.html
3058         - fast/events/prevent-drag-to-navigate.html
3059
3060         * page/DragController.cpp:
3061         (WebCore::DragController::dragEnteredOrUpdated):
3062         (WebCore::DragController::tryDocumentDrag):
3063         (WebCore::defaultOperationForDrag):
3064         (WebCore::DragController::tryDHTMLDrag):
3065         * page/DragController.h:
3066
3067 2009-06-23  Oliver Hunt  <oliver@apple.com> and Eric Carlson  <eric.carlson@apple.com>
3068
3069         Reviewed by Sam Weinig and Dave Hyatt.
3070
3071         <rdar://problem/6164797> Add Canvas API to allow drawing of <video> frames
3072         <https://bugs.webkit.org/show_bug.cgi?id=25920>
3073
3074         Add support for drawing the contents of the video element to the canvas
3075         in accordance with the current HTML5 draft.
3076
3077         Test: media/video-canvas.html
3078
3079         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
3080         (WebCore::JSCanvasRenderingContext2D::drawImage):
3081           Standard custom bindings stuff we need to do for all canvas methods.
3082         * html/CanvasRenderingContext2D.cpp:
3083         (WebCore::size): Helper function for finding the size of a video element
3084         (WebCore::CanvasRenderingContext2D::checkOrigin): moved up in the file.
3085         (WebCore::CanvasRenderingContext2D::drawImage): The various overloads of HTML5's drawImage(<video>)
3086         * html/CanvasRenderingContext2D.h:
3087         * html/HTMLMediaElement.h:
3088         (WebCore::HTMLMediaElement::hasSingleSecurityOrigin):
3089           hasSingleSecurityOrigin is needed for security, currently all implementations are trivial
3090           as we force QT to maintain a single origin.
3091         * html/HTMLVideoElement.cpp:
3092         (WebCore::HTMLVideoElement::paint): 
3093             Paint routine on video so we don't have to look at MediaPlayer directly
3094         * html/HTMLVideoElement.h:
3095         * platform/graphics/MediaPlayer.cpp:
3096         (WebCore::NullMediaPlayerPrivate::hasSingleSecurityOrigin):
3097         (WebCore::MediaPlayer::hasSingleSecurityOrigin):
3098             Default implementations of hasSingleSecurityOrigin
3099         * platform/graphics/MediaPlayer.h:
3100         * platform/graphics/MediaPlayerPrivate.h:
3101         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
3102         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
3103         (WebCore::MediaPlayerPrivate::setUpVideoRendering):
3104             A video may need a player now even if it is not visible.
3105         (WebCore::MediaPlayerPrivate::hasSingleSecurityOrigin):
3106             Always return true due to restrictions we've placed on QT.
3107         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.cpp:
3108         (WebCore::MediaPlayerPrivate::paint):
3109             Jump through some hoops to allow windows QT to draw to an intermediate buffer.
3110             In the long term we'd like to cache the HDC, but this will do for now.
3111         (WebCore::MediaPlayerPrivate::hasSingleSecurityOrigin):
3112         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.h:
3113             As for Mac we force QT to only allow same origin loads.
3114
3115 2009-06-23  Adam Langley  <agl@google.com>
3116
3117         Reviewed by Eric Seidel.
3118
3119         Chromium: Fix crash with inherited font-size in <option>
3120
3121         https://bugs.webkit.org/show_bug.cgi?id=26656
3122         http://code.google.com/p/chromium/issues/detail?id=14853
3123
3124         In r42597 (https://bugs.webkit.org/show_bug.cgi?id=25244), I changed
3125         the <select> handing for Chromium to fix a rendering bug. However,
3126         although the font-size is correctly ignored, getRowHeight wasn't
3127         updated and so was calculating the height of the rows in an
3128         inconsistent manner. This can lead to a crash.
3129
3130         * manual-tests/optgroup-empty-and-nested.html: adding test case for crash
3131         * platform/chromium/PopupMenuChromium.cpp:
3132         (WebCore::PopupListBox::getRowHeight):
3133
3134 2009-06-23  Brady Eidson  <beidson@apple.com>
3135
3136         Patch by Antti Koivisto.
3137         Reviewed by Brady Eidson.
3138
3139         <rdar://problem/6988010> Failed resources not reloaded when built against Tiger SDK
3140
3141         A latent bug that cache revalidation uncovered.  When a CachedResource failed to load,
3142         it should always be revalidated upon reload.
3143
3144         * loader/CachedResource.cpp:
3145         (WebCore::CachedResource::canUseCacheValidator):
3146         (WebCore::CachedResource::mustRevalidate):
3147
3148 2009-06-23  Dan Bernstein  <mitz@apple.com>
3149
3150         Reviewed by Darin Adler.
3151
3152         - fix <rdar://problem/6634228> Crash in [NSScroller mouseDown:] beneath
3153           EventHandler::passMouseDownEventToWidget()
3154
3155         * page/mac/EventHandlerMac.mm:
3156         (WebCore::EventHandler::passMouseDownEventToWidget): Surround the
3157         -mouseDown: call with calls to Widget::beforeMouseDown() and
3158         Widget::afterMouseDown(), which prevent the widget's view hierarchy from
3159         being removed from its parent view while the scroller is tracking the
3160         mouse.
3161
3162 2009-06-23  Sam Weinig  <sam@webkit.org>
3163
3164         Reviewed by Dave Hyatt.
3165
3166         Fix for https://bugs.webkit.org/show_bug.cgi?id=26516
3167         Add initial implementation of DataGridDataSource
3168
3169         - Initial implementation only supports the initialize callback function.
3170
3171         Test: fast/dom/HTMLDataGridElement/DataGridDataSource-basic.html
3172
3173         * WebCore.xcodeproj/project.pbxproj:
3174         * GNUmakefile.am:
3175         * WebCore.pro:
3176         * WebCore.vcproj/WebCore.vcproj:
3177         * WebCore.xcodeproj/project.pbxproj:
3178         * WebCoreSources.bkl:
3179         * bindings/js/JSDataGridDataSource.cpp: Added.
3180         (WebCore::JSDataGridDataSource::JSDataGridDataSource):
3181         (WebCore::JSDataGridDataSource::~JSDataGridDataSource):
3182         (WebCore::JSDataGridDataSource::initialize):
3183         * bindings/js/JSDataGridDataSource.h: Added.
3184         (WebCore::JSDataGridDataSource::create):
3185         (WebCore::JSDataGridDataSource::isJSDataGridDataSource):
3186         (WebCore::JSDataGridDataSource::jsDataSource):
3187         (WebCore::asJSDataGridDataSource):
3188         * bindings/js/JSHTMLDataGridElementCustom.cpp: Added.
3189         (WebCore::JSHTMLDataGridElement::listener):
3190         (WebCore::JSHTMLDataGridElement::setListener):
3191         * html/DataGridDataSource.h: Added.
3192         (WebCore::DataGridDataSource::~DataGridDataSource):
3193         (WebCore::DataGridDataSource::isJSDataGridDataSource):
3194         * html/HTMLDataGridElement.cpp:
3195         (WebCore::HTMLDataGridElement::HTMLDataGridElement):
3196         (WebCore::HTMLDataGridElement::setDataSource):
3197         (WebCore::HTMLDataGridElement::initializationTimerFired):
3198         * html/HTMLDataGridElement.h:
3199         (WebCore::HTMLDataGridElement::dataSource):
3200         * html/HTMLDataGridElement.idl:
3201
3202 2009-06-23  Ryosuke Niwa  <rniwa@google.com>
3203
3204         Reviewed by Justin Garcia.
3205
3206         Undo the changeset 21212 to fix the regression bug 14062.
3207         The changeset 21212 attempted to fix rdar://problem/5002441.
3208         The changeset 21212 modified InsertTextCommand::input so as to convert
3209         all spaces in text to non-breaking spaces for rdar://problem/5002441.
3210         However, the bug was originally caused by rebalanceWhitespaceAt
3211         and this workaround introduced a regression bug 14062.
3212         Because rebalanceWhitespaceAt appears to behave correctly now,
3213         the workaround introduced in 21212 is no longer needed.
3214
3215         Test: editing/inserting/space-after-removeformat.html
3216
3217         * editing/InsertTextCommand.cpp:
3218         (WebCore::InsertTextCommand::input):
3219
3220 2009-06-23  Beth Dakin  <bdakin@apple.com>
3221
3222         Reviewed by Dave Hyatt.
3223
3224         Fix for https://bugs.webkit.org/show_bug.cgi?id=26523 <col> 
3225         elements width can't be changed with javascript
3226
3227         This patch both fixes setting the width attribute directly in 
3228         JavaScript, and setting the width on the style attribute. 
3229
3230         * html/HTMLTableColElement.cpp:
3231         (WebCore::HTMLTableColElement::parseMappedAttribute): If we have a 
3232         new width, call setNeedsLayoutAndPrefWidthsRecalc()
3233
3234         Call calcPrefWidths() on the table cols.
3235         * rendering/AutoTableLayout.cpp:
3236         (WebCore::AutoTableLayout::recalcColumn):
3237         * rendering/FixedTableLayout.cpp:
3238         (WebCore::FixedTableLayout::calcWidthArray):
3239         
3240         Call layoutIfNeeded on the table cols.
3241         * rendering/RenderTable.cpp:
3242         (WebCore::RenderTable::layout):
3243
3244         * rendering/RenderTableCol.cpp:
3245         (WebCore::RenderTableCol::clippedOverflowRectForRepaint): Use new 
3246         table() convenience function.
3247         (WebCore::RenderTableCol::calcPrefWidths): Just call 
3248         setPrefWidthsDirty(false) on ourself and our children.
3249         (WebCore::RenderTableCol::table):
3250         * rendering/RenderTableCol.h:
3251
3252 2009-06-23  Ojan Vafai  <ojan@chromium.org>
3253
3254         Reviewed by Dan Bernstein.
3255
3256         Add logic to CSSStyleDeclaration::diff to deal with font-sizes that are 
3257         keyword values. When diff is called on a CSSStyleDeclaration, we check
3258         the keywordSize to see if font-size matches a keyword value.
3259         
3260         This ensures that when we diff a CSSMutableStyleDeclaration returned from
3261         copyInheritableProperties on a CSSComputedStyleDeclaration that we 
3262         correctly identify matching font-sizes.
3263         
3264         https://bugs.webkit.org/show_bug.cgi?id=26279
3265
3266         Test: editing/inserting/font-size-clears-from-typing-style.html
3267
3268         * css/CSSComputedStyleDeclaration.cpp:
3269         (WebCore::CSSComputedStyleDeclaration::cssPropertyMatches):
3270         * css/CSSComputedStyleDeclaration.h:
3271         * css/CSSStyleDeclaration.cpp:
3272         (WebCore::CSSStyleDeclaration::cssPropertyMatches):
3273         (WebCore::CSSStyleDeclaration::diff):
3274         * css/CSSStyleDeclaration.h:
3275
3276 2009-06-23  Kevin McCullough  <kmccullough@apple.com>
3277
3278         Reviewed by Darin Adler.
3279
3280         <rdar://problem/6994790> CrashTracer: [USER] 8 crashes in Mail trying to
3281         add a blank line to pasted Facebook content (under
3282         CompositeEditCommand::positionAvoidingSpecialElementBoundary)
3283
3284         - Just added null checks and I will create a new bug to prevent the
3285         bad behavior.
3286
3287         * editing/CompositeEditCommand.cpp:
3288         (WebCore::CompositeEditCommand::positionAvoidingSpecialElementBoundary):
3289
3290 2009-06-23  Simon Fraser  <simon.fraser@apple.com>
3291
3292         Build fix.
3293
3294         Wrap shouldDoSoftwarePaint() in #if USE(ACCELERATED_COMPOSITING) to avoid warning when 
3295         ACCELERATED_COMPOSITING is not defined.
3296
3297         * rendering/RenderLayer.cpp:
3298
3299 2009-06-23  Simon Fraser  <simon.fraser@apple.com>
3300
3301         Reviewed by Dave Hyatt.
3302         
3303         https://bugs.webkit.org/show_bug.cgi?id=24863
3304         
3305         Fix reflection painting on elements with compositing layers.
3306
3307         Test: compositing/reflections/reflection-on-composited.html
3308
3309         * rendering/RenderLayer.h:
3310         Add a new PaintLayerPaintingReflection flag which is set while painting inside
3311         reflections.
3312         (WebCore::RenderLayer::setPaintingInsideReflection):
3313         Add a setter so that RenderLayerBacking can call it.
3314
3315         * rendering/RenderLayer.cpp:
3316         (WebCore::shouldDoSoftwarePaint):
3317         Utility to clarify the logic of when a composited layer should do a software paint.
3318         
3319         (WebCore::RenderLayer::paintLayer):
3320         Use shouldDoSoftwarePaint() to determine when to software-paint a reflected layer.
3321         Remove transform-related tests from the reflection-painting if test because they appear
3322         to be unnecessary.
3323
3324         * rendering/RenderLayerBacking.cpp:
3325         (WebCore::RenderLayerBacking::paintIntoLayer):
3326         Add the code to paint reflections to the composited layer painting method.
3327         
3328         * rendering/RenderReplica.cpp:
3329         (WebCore::RenderReplica::paint):
3330         Set the PaintLayerPaintingReflection flag.
3331
3332 2009-06-23  Antti Koivisto  <antti@apple.com>
3333
3334         Reviewed by Darin Adler.
3335         
3336         https://bugs.webkit.org/show_bug.cgi?id=26643
3337         Memory cache should respect Cache-Control: no-store
3338         
3339         Make resources with Cache-Control: no-store uncacheable in the memory cache.
3340         They get evicted immediately when all clients are gone and are always
3341         reloaded from the server.
3342
3343         Conforms to RFC2616 14.9.2 and seems also match Firefox behavior.
3344
3345         * loader/CachedResource.cpp:
3346         (WebCore::CachedResource::removeClient):
3347         (WebCore::CachedResource::canUseCacheValidator):
3348         (WebCore::CachedResource::mustRevalidate):
3349         * platform/network/ResourceResponseBase.cpp:
3350         (WebCore::ResourceResponseBase::ResourceResponseBase):
3351         (WebCore::ResourceResponseBase::parseCacheControlDirectives):
3352         (WebCore::ResourceResponseBase::cacheControlContainsNoStore):
3353         * platform/network/ResourceResponseBase.h:
3354
3355 2009-06-23  Brady Eidson  <beidson@apple.com>
3356
3357         Windows build fix.
3358
3359         * platform/graphics/win/QTMovieWin.cpp:
3360         (QTMovieWin::play):
3361         (QTMovieWin::pause):
3362         (QTMovieWin::setRate):
3363         (QTMovieWin::setCurrentTime):
3364
3365 2009-06-23  Kevin McCullough  <kmccullough@apple.com>
3366
3367         Reviewed by Adele Peterson.
3368
3369         <rdar://problem/6902203> REGRESSION: 'Return' insertion point incorrect
3370         after manually quoting blank line then hitting return
3371
3372         If the insertion point is both the begining and ending visible position
3373         then we need to insert at the end instead of the begining, which is what
3374         would normally happen if the insertion point was as the begining.
3375
3376         * editing/BreakBlockquoteCommand.cpp:
3377         (WebCore::BreakBlockquoteCommand::doApply):
3378
3379 2009-06-23  Brady Eidson  <beidson@apple.com>
3380
3381         Reviewed by Sam Weinig, and looked over by Eric Carlson.
3382
3383         <rdar://problem/6980466> Media elements should provide option for changing pitch correction
3384
3385         Introduce a new boolean property to HTMLMediaElement called webkitPreservesPitch for script to control this.
3386
3387         * html/HTMLMediaElement.cpp:
3388         (WebCore::HTMLMediaElement::HTMLMediaElement): Currently the platforms that have a flexible pitch preservation 
3389           property (Quicktime on Mac and Win) have had it on by default, so continue that default for now.
3390         (WebCore::HTMLMediaElement::loadResource):
3391         (WebCore::HTMLMediaElement::webkitPreservesPitch):
3392         (WebCore::HTMLMediaElement::setWebkitPreservesPitch):
3393         * html/HTMLMediaElement.h:
3394         * html/HTMLMediaElement.idl:
3395
3396         * platform/graphics/MediaPlayer.cpp:
3397         (WebCore::NullMediaPlayerPrivate::setPreservesPitch):
3398         (WebCore::MediaPlayer::MediaPlayer):
3399         (WebCore::MediaPlayer::preservesPitch):
3400         (WebCore::MediaPlayer::setPreservesPitch):
3401         * platform/graphics/MediaPlayer.h:
3402         * platform/graphics/MediaPlayerPrivate.h:
3403         (WebCore::MediaPlayerPrivateInterface::setPreservesPitch):
3404
3405         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
3406         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
3407         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
3408         (WebCore::MediaPlayerPrivate::createQTMovie): Rework to allow recreation of the movie with almost the
3409           exact same attributes as before, with pitch preservation being the difference.
3410         (WebCore::MediaPlayerPrivate::setPreservesPitch): Recreate the QTMovie if the flag actually changes.
3411         (WebCore::MediaPlayerPrivate::updateStates): Restore current time and rate if this is a recreated movie.
3412         (WebCore::MediaPlayerPrivate::timeChanged): Clear the time-to-be-restored, as this callback means it
3413           has been effectively overwritten.
3414
3415         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.cpp:
3416         (WebCore::MediaPlayerPrivate::load):
3417         (WebCore::MediaPlayerPrivate::setPreservesPitch):
3418         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.h:
3419         * platform/graphics/win/QTMovieWin.cpp:
3420         (QTMovieWinPrivate::QTMovieWinPrivate):
3421         (QTMovieWinPrivate::~QTMovieWinPrivate):
3422         (QTMovieWinPrivate::task): Restore current time and rate if this is a re-created movie.
3423         (QTMovieWin::play): Clear the time-to-be-restored, as this effectively overwrites it.
3424         (QTMovieWin::pause): Ditto.
3425         (QTMovieWin::setRate): Ditto.
3426         (QTMovieWin::setCurrentTime): Ditto.
3427         (QTMovieWin::setPreservesPitch): Recreate the Movie if the flag actually changes.
3428         (QTMovieWin::load): Rework to allow recreation of the Movie with similar state as the movie before it, 
3429           but changing the pitch preservation flag.
3430         * platform/graphics/win/QTMovieWin.h:
3431
3432 2009-06-23  Eric Carlson  <eric.carlson@apple.com>
3433
3434         Reviewed by Simon Fraser.
3435
3436         <rdar://problem/6998286> Crash after leaving page with <video>
3437         
3438         Don't try to post events after going into the page cache.
3439
3440         * html/HTMLMediaElement.cpp:
3441         (WebCore::HTMLMediaElement::documentWillBecomeInactive): Cancel pending events and stop
3442         event timers so we won't try to post events after going into the cache.
3443
3444 2009-06-23  Jeremy Orlow  <jorlow@chromium.org>
3445
3446         Reviewed by Brady Eidson.
3447
3448         Simplify the interaction between LocalStorageArea/SessionStorageArea
3449         and StorageArea by creating a "blockUntilImportComplete()" function
3450         rather than bouncing back and forth between the child and parent
3451         classes in a somewhat unintuitive manner.
3452
3453         This patch also paves the way for LocalStorageArea and
3454         SessionStorageArea being merged into one.  It's part of several in a
3455         set which are separating syncing (to disk) code from the rest of the
3456         implementation so that local storage and session storage's code can be
3457         unified.
3458
3459         https://bugs.webkit.org/show_bug.cgi?id=25376
3460
3461         * storage/LocalStorageArea.cpp:
3462         (WebCore::LocalStorageArea::blockUntilImportComplete):
3463         * storage/LocalStorageArea.h:
3464         * storage/StorageArea.cpp:
3465         (WebCore::StorageArea::length):
3466         (WebCore::StorageArea::key):
3467         (WebCore::StorageArea::getItem):
3468         (WebCore::StorageArea::setItem):
3469         (WebCore::StorageArea::removeItem):
3470         (WebCore::StorageArea::clear):
3471         (WebCore::StorageArea::contains):
3472         * storage/StorageArea.h:
3473         (WebCore::StorageArea::blockUntilImportComplete):
3474
3475 2009-06-23  Simon Fraser  <simon.fraser@apple.com>
3476
3477         Reviewed by Dave Hyatt
3478
3479         First part of https://bugs.webkit.org/show_bug.cgi?id=26652
3480         
3481         * rendering/RenderLayer.cpp:
3482         (WebCore::RenderLayer::paint):
3483         (WebCore::RenderLayer::paintLayer):
3484         * rendering/RenderLayer.h:
3485         (WebCore::RenderLayer::):
3486         * rendering/RenderReplica.cpp:
3487         (WebCore::RenderReplica::paint):
3488         Replace the 3 boolean params to RenderLayer::paintLayer() with a bit mask for readability.
3489         
3490         * rendering/RenderLayerBacking.cpp:
3491         (WebCore::RenderLayerBacking::paintIntoLayer):
3492         (WebCore::RenderLayerBacking::paintContents):
3493         * rendering/RenderLayerBacking.h:
3494         Remove the unused 'haveTransparency' param to paintIntoLayer().
3495
3496 2009-06-23  Simon Fraser  <simon.fraser@apple.com>
3497
3498         Reviewed by Darin Adler.
3499
3500         <rdar://problem/6997929> Assertion at WebCore::RenderLayer::updateClipRects with hardware acceleration
3501
3502         The updatingControlTints() painting pass goes through compositing layer boundaries,
3503         so we need to ensure we don't cache clip rects computed with the wrong root by
3504         setting temporaryClipRects to true.
3505         
3506         * rendering/RenderLayer.cpp:
3507         (WebCore::RenderLayer::paintLayer):
3508         
3509         * rendering/RenderLayerBacking.cpp:
3510         (WebCore::RenderLayerBacking::contentOffsetInCompostingLayer):
3511         Remove a printf that I left in by mistake.
3512
3513 2009-06-23  Anders Carlsson  <andersca@apple.com>
3514
3515         Reviewed by Darin Adler.
3516
3517         WebCore side of <rdar://problem/6946094>.
3518         
3519         * platform/win/ClipboardWin.cpp:
3520         (WebCore::ClipboardWin::setExternalDataObject):
3521         * platform/win/ClipboardWin.h:
3522
3523 2009-06-23  Darin Fisher  <darin@chromium.org>
3524
3525         Reviewed by Darin Adler.
3526
3527         https://bugs.webkit.org/show_bug.cgi?id=26650
3528
3529         Add setFormContentType and setFormData since it is awkward for Chromium
3530         to use setFormInfoFromRequest to set the underlying members.  Also, add
3531         a clearChildren method that Chromium needs.  These methods are used as
3532         part of the Chromium code that serializes a HistoryItem for storing in
3533         the browser's session history.
3534
3535         * history/HistoryItem.cpp:
3536         * history/HistoryItem.h:
3537
3538 2009-06-23  Eric Carlson  <eric.carlson@apple.com>
3539
3540         Reviewed by Darin Adler.
3541
3542         <rdar://problem/6978938> Need HTML 5 event attributes for media elements
3543
3544         Test: media/event-attributes.html
3545
3546         * html/HTMLAttributeNames.in: Add media event attribute names.
3547         * html/HTMLMediaElement.cpp:
3548         (WebCore::HTMLMediaElement::parseMappedAttribute): Handle media event attributes.
3549
3550 2009-06-23  Thiago Macieira  <thiago.macieira@nokia.com>
3551
3552         Reviewed by Simon Hausmann.
3553
3554         Fix Qt build with Phonon.
3555
3556         The #include <phonon> header no longer exists. And the <Phonon> or
3557         <Phonon/Phonon> headers have never existed (neither for us nor for the
3558         Phonon sources). You have to select each and every header that you do
3559         want now.
3560
3561         * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
3562
3563 2009-06-23  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
3564
3565         Reviewed by Simon Hausmann.
3566
3567         Remove duplicated code in Qt & GTK logging initialization
3568
3569         We now share the getChannelFromName() function in Logging.cpp
3570
3571         * platform/gtk/LoggingGtk.cpp:
3572         * platform/qt/LoggingQt.cpp:
3573
3574 2009-06-23  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
3575
3576         Reviewed by Simon Hausmann.
3577
3578         Rename the plugin logging channel to plural form 'Plugins'
3579
3580         This matches both the other logging channel names, as well as the
3581         WebKit logging channel used by Safari/Mac for plugins.
3582
3583         * platform/Logging.cpp:
3584         * platform/Logging.h:
3585         * platform/gtk/LoggingGtk.cpp:
3586         * platform/mac/LoggingMac.mm:
3587         * platform/qt/LoggingQt.cpp:
3588         * platform/win/LoggingWin.cpp:
3589         * plugins/PluginDebug.h:
3590         * plugins/gtk/PluginPackageGtk.cpp:
3591         * plugins/mac/PluginPackageMac.cpp:
3592         * plugins/mac/PluginViewMac.cpp:
3593         * plugins/qt/PluginPackageQt.cpp:
3594
3595 2009-06-23  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
3596
3597         Reviewed by Simon Hausmann.
3598
3599         Fix NPAPI mouse translation issues on Mac
3600
3601         The WindowRef we pass to the plugin refers to the the top level window,
3602         so the x and y positions have to be relative to this position, but we
3603         have to manually compensate for title bar decorations and other parents