Rubber Stamped by Adam Roben.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-05-27  Stephanie Lewis  <slewis@apple.com>
2
3         Rubber Stamped by Adam Roben.
4
5         Update Order Files.  Use -order_file flag since it can order more of the binary.
6
7         * Configurations/Base.xcconfig:
8         * WebCore.order:
9
10 2011-05-27  Sheriff Bot  <webkit.review.bot@gmail.com>
11
12         Unreviewed, rolling out r87464.
13         http://trac.webkit.org/changeset/87464
14         https://bugs.webkit.org/show_bug.cgi?id=61643
15
16         client-close/server-close tests are flaky on Chromium Mac and
17         Windows (Requested by aklein on #webkit).
18
19         * platform/network/SocketStreamHandleBase.cpp:
20         (WebCore::SocketStreamHandleBase::send):
21         (WebCore::SocketStreamHandleBase::close):
22         (WebCore::SocketStreamHandleBase::sendPendingData):
23         * platform/network/SocketStreamHandleBase.h:
24         * websockets/ThreadableWebSocketChannelClientWrapper.cpp:
25         (WebCore::ThreadableWebSocketChannelClientWrapper::didClose):
26         (WebCore::ThreadableWebSocketChannelClientWrapper::didCloseCallback):
27         * websockets/ThreadableWebSocketChannelClientWrapper.h:
28         * websockets/WebSocket.cpp:
29         (WebCore::WebSocket::send):
30         (WebCore::WebSocket::close):
31         (WebCore::WebSocket::bufferedAmount):
32         (WebCore::WebSocket::didConnect):
33         (WebCore::WebSocket::didReceiveMessage):
34         (WebCore::WebSocket::didReceiveMessageError):
35         (WebCore::WebSocket::didClose):
36         * websockets/WebSocket.h:
37         * websockets/WebSocketChannel.cpp:
38         (WebCore::WebSocketChannel::WebSocketChannel):
39         (WebCore::WebSocketChannel::close):
40         (WebCore::WebSocketChannel::disconnect):
41         (WebCore::WebSocketChannel::didClose):
42         (WebCore::WebSocketChannel::didReceiveData):
43         (WebCore::WebSocketChannel::didFail):
44         (WebCore::WebSocketChannel::processBuffer):
45         * websockets/WebSocketChannel.h:
46         * websockets/WebSocketChannelClient.h:
47         (WebCore::WebSocketChannelClient::didClose):
48         * websockets/WorkerThreadableWebSocketChannel.cpp:
49         (WebCore::WorkerThreadableWebSocketChannel::Peer::close):
50         (WebCore::workerContextDidClose):
51         (WebCore::WorkerThreadableWebSocketChannel::Peer::didClose):
52         * websockets/WorkerThreadableWebSocketChannel.h:
53
54 2011-05-27  Rob Buis  <rbuis@rim.com>
55
56         Reviewed by Nikolas Zimmermann.
57
58         https://bugs.webkit.org/show_bug.cgi?id=19995
59         hixie.ch : anchor Link fails with fragment identifiers inside SVG fragments.
60
61         Only allow links to animation elements within the document.
62
63         Test: svg/hixie/links/003.xml
64
65         * svg/SVGAElement.cpp:
66         (WebCore::SVGAElement::defaultEventHandler):
67
68 2011-05-27  Andreas Kling  <kling@webkit.org>
69
70         Reviewed by Benjamin Poulain.
71
72         Update RGBA color serialization to match HTML5.
73         https://bugs.webkit.org/show_bug.cgi?id=61449
74
75         HTML5 now specifies that fully transparent colors should have their alpha value
76         serialized to "0" rather than "0.0" (followed by any number of extra zeroes.)
77
78         The number of decimals for alpha values between 0 and 1 is not specified,
79         so match Gecko and Presto by returning the lowest number of decimals needed
80         to represent the number. (No more trailing zeroes.)
81
82         * platform/graphics/Color.cpp:
83         (WebCore::Color::serialized):
84
85 2011-05-27  Hans Wennborg  <hans@chromium.org>
86
87         Reviewed by Tony Gentilcore.
88
89         IndexedDB: Support mutating cursors on top of LevelDB
90         https://bugs.webkit.org/show_bug.cgi?id=61615
91
92         We need to support the case where a new node is added to the tree in a
93         transaction after the TreeIterator has covered the whole tree.
94
95         Since this is done lazily, i.e. we set a flag that the tree might have
96         changed, and act upon it later, some members need to be mutable,
97         because we might need to re-seek the tree iterator in a const function.
98
99         Test: storage/indexeddb/mutating-cursor.html
100               storage/indexeddb/mozilla/cursor-mutation-objectstore-only.html (existing)
101
102         * platform/leveldb/LevelDBTransaction.cpp:
103         (WebCore::LevelDBTransaction::set):
104         (WebCore::LevelDBTransaction::TreeIterator::reset):
105         (WebCore::LevelDBTransaction::TreeIterator::~TreeIterator):
106         (WebCore::LevelDBTransaction::TreeIterator::TreeIterator):
107         (WebCore::LevelDBTransaction::TransactionIterator::TransactionIterator):
108         (WebCore::LevelDBTransaction::TransactionIterator::~TransactionIterator):
109         (WebCore::LevelDBTransaction::TransactionIterator::next):
110         (WebCore::LevelDBTransaction::TransactionIterator::prev):
111         (WebCore::LevelDBTransaction::TransactionIterator::key):
112         (WebCore::LevelDBTransaction::TransactionIterator::value):
113         (WebCore::LevelDBTransaction::TransactionIterator::treeChanged):
114         (WebCore::LevelDBTransaction::TransactionIterator::refreshTreeIterator):
115         (WebCore::LevelDBTransaction::registerIterator):
116         (WebCore::LevelDBTransaction::unregisterIterator):
117         (WebCore::LevelDBTransaction::notifyIteratorsOfTreeChange):
118         * platform/leveldb/LevelDBTransaction.h:
119         * storage/IDBFactoryBackendImpl.cpp:
120         (WebCore::IDBFactoryBackendImpl::open):
121         * storage/IDBLevelDBBackingStore.cpp:
122         (WebCore::IDBLevelDBBackingStore::open):
123
124 2011-05-27  Sujin Park  <sujjin.park@gmail.com>
125
126         Unreviewed, buildfix if --no-javascript-debugger.
127
128         Regression(R84125): Broke GTK build
129         https://bugs.webkit.org/show_bug.cgi?id=60698
130
131         No new tests since this doesn't change any behavior.
132
133         * inspector/WorkerInspectorController.h:
134
135 2011-05-26  Yael Aharon  <yael.aharon@nokia.com>
136
137         Reviewed by Tony Chang.
138
139         webkit should implement the dropzone attribute
140         https://bugs.webkit.org/show_bug.cgi?id=58210
141
142         Add support for dropzone attribute.
143         http://www.whatwg.org/specs/web-apps/current-work/multipage/dnd.html#the-dropzone-attribute
144         If a drag event was not canceled by JavaScript, look for an element with a dropzone attribute.
145         If there is such an element, and it matches the drag data store, set the action defined by that
146         element and continue processing the drag and drop operation.
147
148         Tests: fast/events/dropzone-001.html
149                fast/events/dropzone-002.html
150                fast/events/dropzone-003.html
151                fast/events/dropzone-004.html
152
153         * dom/Clipboard.cpp:
154         (WebCore::Clipboard::hasFileOfType):
155         (WebCore::Clipboard::hasStringOfType):
156         (WebCore::convertDropZoneOperationToDragOperation):
157         (WebCore::convertDragOperationToDropZoneOperation):
158         (WebCore::Clipboard::processDropZoneKeyword):
159         * dom/Clipboard.h:
160         * html/HTMLAttributeNames.in:
161         * html/HTMLElement.idl:
162         * page/EventHandler.cpp:
163         (WebCore::EventHandler::findDropZone):
164         (WebCore::EventHandler::updateDragAndDrop):
165         * page/EventHandler.h:
166
167 2011-05-27  Patrick Gansterer  <paroga@webkit.org>
168
169         Unreviewed WinCE build fix for r87467.
170
171         * page/wince/FrameWinCE.cpp:
172
173 2011-05-26  Hans Wennborg  <hans@chromium.org>
174
175         Reviewed by Tony Gentilcore.
176
177         IndexedDB: Support NO_DUPLICATE cursors on LevelDB back-end
178         https://bugs.webkit.org/show_bug.cgi?id=61517
179
180         Support cursors where the direction is set to NEXT_NO_DUPLICATE,
181         or PREV_NO_DUPLICATE, as specified here:
182         http://www.w3.org/TR/IndexedDB/#widl-IDBCursor-NEXT_NO_DUPLICATE
183
184         This is tested by storage/indexeddb/mozilla/indexes.html
185
186         * storage/IDBLevelDBBackingStore.cpp:
187         (WebCore::IDBLevelDBBackingStore::openObjectStoreCursor):
188         (WebCore::IDBLevelDBBackingStore::openIndexKeyCursor):
189         (WebCore::IDBLevelDBBackingStore::openIndexCursor):
190
191 2011-05-26  Hans Wennborg  <hans@chromium.org>
192
193         Reviewed by Tony Gentilcore.
194
195         LevelDB: turn on paranoid checks and verify checksums, log errors
196         https://bugs.webkit.org/show_bug.cgi?id=61516
197
198         This allows for detection of corrupted databases.
199         Even if we can't recover from a corrupted database, discovering the
200         problem is a step in the right direction.
201
202         No new functionality, no new tests.
203
204         * platform/leveldb/LevelDBDatabase.cpp:
205         (WebCore::LevelDBDatabase::open):
206         (WebCore::LevelDBDatabase::put):
207         (WebCore::LevelDBDatabase::remove):
208         (WebCore::LevelDBDatabase::get):
209         (WebCore::LevelDBDatabase::write):
210         (WebCore::IteratorImpl::checkStatus):
211         (WebCore::IteratorImpl::seekToLast):
212         (WebCore::IteratorImpl::seek):
213         (WebCore::IteratorImpl::next):
214         (WebCore::IteratorImpl::prev):
215         (WebCore::LevelDBDatabase::createIterator):
216
217 2011-05-27  James Robinson  <jamesr@chromium.org>
218
219         Reviewed by Adam Barth.
220
221         CachedResourceLoader stores data: urls in validated URL set
222         https://bugs.webkit.org/show_bug.cgi?id=61604
223
224         CachedResourceLoader maintains a set of URLs that have been validated to avoid validating the same resource
225         multiple times for loads within the same document.  This doesn't make sense for data: URLs and just wastes
226         memory.
227
228         * loader/cache/CachedResourceLoader.cpp:
229         (WebCore::CachedResourceLoader::revalidateResource):
230         (WebCore::CachedResourceLoader::loadResource):
231
232 2011-05-23  MORITA Hajime  <morrita@google.com>
233
234         Reviewed by Tony Chang.
235
236         [Refactoring] DocumentMarker should be carried around as a pointer, not value.
237         https://bugs.webkit.org/show_bug.cgi?id=61262
238
239         - Changed return value of markersInRange() from Vector<DocumentMarker> to Vector<DocumentMarker*>.
240         - Introduced markersFor() that returns Vector<DocumentMarker*>
241         - Removed DocumentMarkerController::setRenderedRectForMarker() which now can be replaced by
242           RenderedDocumentMarker::setRenderedRect().
243         - This change didn't remove markersForNode() beucase there is patches on review which depends
244           markersForNode(). I'll remove its call after these patches are landed.
245         
246         No new tests. No behavior change.
247
248         * WebCore.exp.in:
249         * dom/DocumentMarkerController.cpp:
250         (WebCore::DocumentMarkerController::addTextMatchMarker):
251         (WebCore::DocumentMarkerController::markersFor):
252         (WebCore::DocumentMarkerController::markersInRange):
253         (WebCore::DocumentMarkerController::hasMarkers):
254         * dom/DocumentMarkerController.h:
255         * dom/RenderedDocumentMarker.h:
256         (WebCore::toRenderedDocumentMarker):
257         * editing/CompositeEditCommand.cpp:
258         (WebCore::CompositeEditCommand::replaceTextInNodePreservingMarkers):
259         * editing/DeleteSelectionCommand.cpp:
260         (WebCore::DeleteSelectionCommand::originalStringForAutocorrectionAtBeginningOfSelection):
261         * editing/Editor.cpp:
262         (WebCore::Editor::selectionStartHasMarkerFor):
263         * editing/SpellingCorrectionController.cpp:
264         (WebCore::markersHaveIdenticalDescription):
265         (WebCore::SpellingCorrectionController::respondToChangedSelection):
266         (WebCore::SpellingCorrectionController::recordSpellcheckerResponseForModifiedCorrection):
267         (WebCore::SpellingCorrectionController::processMarkersOnTextToBeReplacedByResult):
268         * editing/SpellingCorrectionController.h:
269         (WebCore::SpellingCorrectionController::shouldStartTimerFor):
270         * rendering/InlineTextBox.cpp:
271         (WebCore::InlineTextBox::paintSpellingOrGrammarMarker):
272         (WebCore::InlineTextBox::paintTextMatchMarker):
273         (WebCore::InlineTextBox::computeRectForReplacementMarker):
274         (WebCore::InlineTextBox::paintDocumentMarkers):
275         * rendering/InlineTextBox.h:
276         * rendering/svg/SVGInlineFlowBox.cpp:
277         (WebCore::SVGInlineFlowBox::computeTextMatchMarkerRectForRenderer):
278
279 2011-05-26  MORITA Hajime  <morrita@google.com>
280
281         Reviewed by Kent Tamura.
282
283         WebCore::HTMLSummaryElement::isMainSummary ReadAV@NULL
284         https://bugs.webkit.org/show_bug.cgi?id=61511
285
286         Removed Unnecessary wrong cast to Elmement, which can be non-Element.
287
288         Test: fast/html/details-summary-document-child.html
289
290         * html/HTMLSummaryElement.cpp:
291         (WebCore::HTMLSummaryElement::detailsElement):
292
293 2011-05-26  Adam Barth  <abarth@webkit.org>
294
295         Reviewed by Ryosuke Niwa.
296
297         FrameLoader cannot be null
298         https://bugs.webkit.org/show_bug.cgi?id=61609
299
300         This code has a bunch of cargo-cult null checking.
301
302         * html/HTMLMediaElement.cpp:
303         (WebCore::HTMLMediaElement::createRenderer):
304         (WebCore::HTMLMediaElement::attach):
305         (WebCore::HTMLMediaElement::loadResource):
306         (WebCore::HTMLMediaElement::getPluginProxyParams):
307         (WebCore::HTMLMediaElement::createMediaPlayerProxy):
308         (WebCore::HTMLMediaElement::updateWidget):
309
310 2011-05-26  Shane Stephens  <shanestephens@google.com>
311
312         Reviewed by James Robinson.
313
314         REGRESSION (r81992): layout triggered by position update fails to apply when transform is updated at same time
315         https://bugs.webkit.org/show_bug.cgi?id=60689
316
317         When a transform is modified in a style, we were upgrading our understanding
318         of the difference from PositionedMovementOnly to SimplifiedLayout.  However,
319         if the position of the style is independently changed at the same time, both
320         PositionedMovement and SimplifiedLayout passes are required.
321
322         Test: transforms/2d/set-transform-and-top.html
323
324         * rendering/RenderObject.cpp:
325         Added checks for SimplifiedLayoutAndPositionedMovement - when encountered,
326         set both PositionedMovement and SimplifiedLayout update flasgs. 
327         * rendering/style/RenderStyleConstants.h:
328         Added a new StyleDifference enum value (SimplifiedLayoutAndPositionedMovement) for 
329         cases when both PositionedMovement and SimplifiedLayout are required.
330
331 2011-05-26  Luke Macpherson   <macpherson@chromium.org>
332
333         Reviewed by Eric Seidel.
334
335         Implement webkit margin collapse CSS properties in CSSStyleApplyProperty
336         https://bugs.webkit.org/show_bug.cgi?id=61589
337
338         No new tests as no new functionality added.
339
340         * css/CSSStyleApplyProperty.cpp:
341         (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):
342         Add handlers for:
343           CSSPropertyWebkitMarginBeforeCollapse
344           CSSPropertyWebkitMarginAfterCollapse
345           CSSPropertyWebkitMarginTopCollapse
346           CSSPropertyWebkitMarginBottomCollapse
347           CSSPropertyWebkitMarginCollapse
348         * css/CSSStyleSelector.cpp:
349         (WebCore::CSSStyleSelector::applyProperty):
350         Remove cases that are no longer required.
351
352 2011-05-26  Adam Barth  <abarth@webkit.org>
353
354         Reviewed by Eric Seidel.
355
356         Support cross-origin property for images
357         https://bugs.webkit.org/show_bug.cgi?id=61015
358
359         This patch add support for the crossorigin attribute of images and
360         teaches 2D canvas to respect that flag and not taint a canvas if the
361         image drawn on the canvas is allowed by CORS.
362
363         While I was editing this code, I couldn't resist a couple touch-up
364         changes.
365
366         Tests: http/tests/security/canvas-remote-read-remote-image-allowed-with-credentials.html
367                http/tests/security/canvas-remote-read-remote-image-allowed.html
368                http/tests/security/canvas-remote-read-remote-image-blocked-no-crossorigin.html
369
370         * html/HTMLAttributeNames.in:
371         * html/HTMLCanvasElement.cpp:
372         (WebCore::HTMLCanvasElement::securityOrigin):
373         * html/HTMLCanvasElement.h:
374         * html/HTMLImageElement.idl:
375         * html/canvas/CanvasRenderingContext.cpp:
376         (WebCore::CanvasRenderingContext::checkOrigin):
377         * html/canvas/CanvasRenderingContext2D.cpp:
378         (WebCore::CanvasRenderingContext2D::createPattern):
379         * loader/ImageLoader.cpp:
380         (WebCore::ImageLoader::updateFromElement):
381         * loader/cache/CachedResource.cpp:
382         (WebCore::CachedResource::passesAccessControlCheck):
383         * loader/cache/CachedResource.h:
384
385 2011-05-26  Mihai Parparita  <mihaip@chromium.org>
386
387         Reviewed by Adam Barth.
388
389         Fix worldID and destinationDomain argument names
390         https://bugs.webkit.org/show_bug.cgi?id=61571
391
392         As part of working on r87423, I noticed a couple of inconsistencies in
393         argument names:
394         - We would use worldId in .h files but worldID in .cpp files.
395           Standardize on the latter
396         - SecurityOrigin::addOriginAccessWhitelistEntry would take a
397           destinationDomains argument, even though the actual parameter was for
398           a single domain (renamed to be singular).
399
400         * bindings/v8/ScriptController.h:
401         * bindings/v8/V8Proxy.h:
402         * page/SecurityOrigin.cpp:
403         (WebCore::SecurityOrigin::addOriginAccessWhitelistEntry):
404         (WebCore::SecurityOrigin::removeOriginAccessWhitelistEntry):
405         * page/SecurityOrigin.h:
406
407 2011-05-26  Emil A Eklund  <eae@chromium.org>
408
409         Reviewed by Eric Seidel.
410
411         Replace RenderLayer::x/y/width/height with location/size
412         https://bugs.webkit.org/show_bug.cgi?id=61414
413
414         Covered by existing tests.
415
416         * dom/MouseRelatedEvent.cpp:
417         (WebCore::MouseRelatedEvent::computeRelativePosition):
418         * rendering/RenderBox.cpp:
419         (WebCore::RenderBox::computeRectForRepaint):
420         * rendering/RenderBox.h:
421         (WebCore::RenderBox::maxLayoutOverflow):
422         * rendering/RenderInline.cpp:
423         (WebCore::RenderInline::clippedOverflowRectForRepaint):
424         (WebCore::RenderInline::computeRectForRepaint):
425         * rendering/RenderLayer.cpp:
426         (WebCore::RenderLayer::updateLayerPosition):
427         (WebCore::RenderLayer::convertToLayerCoords):
428         (WebCore::RenderLayer::offsetFromResizeCorner):
429         (WebCore::RenderLayer::calculateRects):
430         * rendering/RenderLayer.h:
431         (WebCore::RenderLayer::location):
432         (WebCore::RenderLayer::setSize):
433         * rendering/RenderObject.cpp:
434         (WebCore::RenderObject::computeRectForRepaint):
435         * rendering/RenderTreeAsText.cpp:
436         (WebCore::write):
437         (WebCore::writeLayers):
438         (WebCore::externalRepresentation):
439         * rendering/RenderView.cpp:
440         (WebCore::RenderView::absoluteRects):
441         (WebCore::RenderView::absoluteQuads):
442
443 2011-05-26  Annie Sullivan  <sullivan@chromium.org>
444
445         Reviewed by Ryosuke Niwa.
446
447         Delete table in contentEditable/designMode produces odd contents
448         https://bugs.webkit.org/show_bug.cgi?id=57148
449
450         Removes border-collapse, -webkit-border-horizontal-spacing, and
451         -webkit-border-vertical-spacing from the list of properties which
452         should be preserved during edit operations. Also renames this
453         list to editingInheritableProperties to be more clear about what
454         the list is for.
455
456         Test: editing/deleting/delete-last-char-in-table.html
457
458         * editing/EditingStyle.cpp: Removes border vertical/horizontal
459         spacing from editingStyleProperties.
460         * editing/EditingStyle.h: Renames OnlyInheritableProperties to
461         OnlyEditingInheritableProperties.
462         * editing/markup.cpp: Renames InheritablePropertiesAndBackgroundColorInEffect.
463
464 2011-05-26  Yuta Kitamura  <yutak@chromium.org>
465
466         Reviewed by Kent Tamura.
467
468         WebSocket closing handshake
469         https://bugs.webkit.org/show_bug.cgi?id=35721
470
471         Implement WebSocket closing handshake based on Ian Hickson's
472         WebSocket protocol draft 76.
473
474         Tests: http/tests/websocket/tests/client-close.html
475                http/tests/websocket/tests/server-close.html
476
477         * platform/network/SocketStreamHandleBase.cpp:
478         (WebCore::SocketStreamHandleBase::send):
479         Do not send a message if we are in Closing state.
480         (WebCore::SocketStreamHandleBase::close):
481         Do not disconnect if we have pending data which have not been sent yet.
482         In this case, the actual disconnection will happen in sendPendingData().
483         (WebCore::SocketStreamHandleBase::disconnect):
484         Renamed from close(). Disconnect the connection immediately.
485         (WebCore::SocketStreamHandleBase::sendPendingData):
486         * platform/network/SocketStreamHandleBase.h:
487         * websockets/ThreadableWebSocketChannelClientWrapper.cpp:
488         Add didStartClosingHandshake(). Add a function argument (ClosingHandshakeCompletionStatus)
489         to didClose().
490         (WebCore::ThreadableWebSocketChannelClientWrapper::didStartClosingHandshake):
491         (WebCore::ThreadableWebSocketChannelClientWrapper::didClose):
492         (WebCore::ThreadableWebSocketChannelClientWrapper::didStartClosingHandshakeCallback):
493         (WebCore::ThreadableWebSocketChannelClientWrapper::didCloseCallback):
494         * websockets/ThreadableWebSocketChannelClientWrapper.h:
495         * websockets/WebSocket.cpp:
496         (WebCore::WebSocket::send):
497         (WebCore::WebSocket::close):
498         Fail if close() is attempted before the connection is established.
499         Otherwise, set the state to CLOSING and start the closing handshake.
500         (WebCore::WebSocket::bufferedAmount):
501         If the state is CLOSING, we need to consider buffered data in m_channel and sent after close().
502         (WebCore::WebSocket::didConnect):
503         (WebCore::WebSocket::didReceiveMessage):
504         We need to invoke message event in CLOSING state as well as OPEN state.
505         (WebCore::WebSocket::didReceiveMessageError):
506         (WebCore::WebSocket::didStartClosingHandshake):
507         (WebCore::WebSocket::didClose):
508         * websockets/WebSocket.h:
509         * websockets/WebSocketChannel.cpp:
510         (WebCore::WebSocketChannel::WebSocketChannel):
511         (WebCore::WebSocketChannel::close):
512         Start the closing handshake.
513         (WebCore::WebSocketChannel::disconnect):
514         Disconnect the socket stream, instead of close.
515         (WebCore::WebSocketChannel::didClose):
516         (WebCore::WebSocketChannel::didReceiveData): Ditto.
517         (WebCore::WebSocketChannel::didFail): Ditto.
518         (WebCore::WebSocketChannel::processBuffer):
519         Ditto.
520         Handle 0xFF 0x00 byte sequence, and discard received data once the closing handshake has started.
521         (WebCore::WebSocketChannel::startClosingHandshake):
522         Send 0xFF 0x00 byte sequence.
523         (WebCore::WebSocketChannel::closingTimerFired):
524         Disconnect the socket stream if the closing handshake has timed out.
525         * websockets/WebSocketChannel.h:
526         m_closing is true if "the WebSocket closing handshake has started" (as stated in the protocol
527         specification).
528         * websockets/WebSocketChannelClient.h:
529         (WebCore::WebSocketChannelClient::didStartClosingHandshake): Added.
530         (WebCore::WebSocketChannelClient::didClose): Add closingHandshakeCompletion parameter.
531         * websockets/WorkerThreadableWebSocketChannel.cpp:
532         Add closingHandshakeCompletion parameter to didClose(), and add didStartClosingHandshake().
533         (WebCore::WorkerThreadableWebSocketChannel::Peer::close):
534         (WebCore::workerContextDidStartClosingHandshake):
535         (WebCore::WorkerThreadableWebSocketChannel::Peer::didStartClosingHandshake):
536         (WebCore::workerContextDidClose):
537         (WebCore::WorkerThreadableWebSocketChannel::Peer::didClose):
538         * websockets/WorkerThreadableWebSocketChannel.h:
539
540 2011-05-26  David Levin  <levin@chromium.org>
541
542         Reviewed by Dmitry Titov.
543
544         WebKit's font notification has problems when the WebKit main thread != UI thread.
545         https://bugs.webkit.org/show_bug.cgi?id=61391
546
547         This doesn't happen in DumpRenderTree, so it needs a unit test which is taking me
548         some time to write correctly. In the meantime, this issues happens to be causing
549         some crashes in Chrome so here's the fix alone for the time being.
550
551         * platform/graphics/mac/FontCacheMac.mm:
552         (WebCore::invalidateFontCache): Ensure that FontCache::invalidate is only called on WebKit's main thread.
553         (WebCore::fontCacheRegisteredFontsChangedNotificationCallback): Call common function for font cache invalidation.
554          Note that the call to fontCache() is fine since the singleton is initialized well before calling this function. Theoretically,
555          there could be a problem due to a lack of a memory barrier but that is highly unlikely and this is debug only code.
556         (WebCore::fontCacheATSNotificationCallback): Ditto.
557
558 2011-05-26  Stephanie Lewis  <slewis@apple.com>
559
560         Reviewed by Geoff Garen.
561
562         https://bugs.webkit.org/show_bug.cgi?id=61345
563         part of <rdar://problem/8675177>
564         Roll back in now that the Crashes are fixed.  ResourceResponseBase and ResourceResponse had two different definitions
565         for m_isNull.  ResourceResponse treats m_isNull as meaning there isn't any platform ResourceResponse. 
566         ResourceResponseBase treats m_isNull as meaning no fields have been initialized.  Consolidate calls into ResourceResponseBase meaning. 
567
568         Don't initialize ResourceResponse.m_suggestedFilename until we want to use it.  Initializing it requires reading in and parsing a plist.  
569         Add new initialization state CommonAndUncommonFields to ResourceResponse.  This will be for all the header fields.
570         Move suggestedFilename initialization to AllFields so it is never initialized unless we ask for it. 
571         Add "Content-Type" to common headers since it is looked for by every CSS sheet load.
572
573         No new functionality so no new tests.
574
575         * platform/network/ResourceResponseBase.cpp:
576         (WebCore::ResourceResponseBase::adopt):
577         (WebCore::ResourceResponseBase::suggestedFilename):
578         (WebCore::ResourceResponseBase::setSuggestedFilename):
579         (WebCore::ResourceResponseBase::httpStatusText):
580         (WebCore::ResourceResponseBase::setHTTPStatusText):
581         (WebCore::ResourceResponseBase::httpHeaderField):
582         (WebCore::ResourceResponseBase::setHTTPHeaderField):
583         (WebCore::ResourceResponseBase::httpHeaderFields):
584         (WebCore::ResourceResponseBase::isAttachment):
585         (WebCore::ResourceResponseBase::setLastModifiedDate):
586         (WebCore::ResourceResponseBase::lastModifiedDate):
587         (WebCore::ResourceResponseBase::wasCached):
588         (WebCore::ResourceResponseBase::connectionReused):
589         (WebCore::ResourceResponseBase::setConnectionReused):
590         (WebCore::ResourceResponseBase::connectionID):
591         (WebCore::ResourceResponseBase::setConnectionID):
592         (WebCore::ResourceResponseBase::resourceLoadTiming):
593         (WebCore::ResourceResponseBase::setResourceLoadTiming):
594         (WebCore::ResourceResponseBase::resourceLoadInfo):
595         (WebCore::ResourceResponseBase::setResourceLoadInfo):
596         * platform/network/ResourceResponseBase.h:
597         * platform/network/cf/ResourceResponse.h:
598         (WebCore::ResourceResponse::ResourceResponse):
599         * platform/network/cf/ResourceResponseCFNet.cpp:
600         (WebCore::ResourceResponse::platformLazyInit):
601         * platform/network/mac/ResourceResponseMac.mm:
602
603 2011-05-26  James Kozianski  <koz@chromium.org>
604
605         Reviewed by Eric Seidel.
606
607         Implement a whitelist for registerProtocolHandler
608         https://bugs.webkit.org/show_bug.cgi?id=60322
609
610         * page/Navigator.cpp:
611         (WebCore::initProtocolHandlerWhitelist):
612         (WebCore::isProtocolWhitelisted):
613         (WebCore::verifyProtocolHandlerScheme):
614
615 2011-05-26  Annie Sullivan  <sullivan@chromium.org>
616
617         Reviewed by Ryosuke Niwa.
618
619         [debug feature] CSSStyleDeclaration should have a way to print cssText
620         https://bugs.webkit.org/show_bug.cgi?id=61570
621
622         Adds a method to print the cssText to stderr for debugging.
623
624         * css/CSSStyleDeclaration.cpp:
625         (WebCore::CSSStyleDeclaration::showStyle): New method to print cssText to stderr
626         * css/CSSStyleDeclaration.h: New method declaration
627
628 2011-05-26  Syed Idris Shah  <syed.idris-shah@nokia.com>
629
630         Reviewed by Andreas Kling.
631
632         [Qt] fast/canvas/webgl/gl-uniform-arrays.html failing for Qt on Linux
633         https://bugs.webkit.org/show_bug.cgi?id=60377 
634
635         LayoutTests/fast/canvas/webgl/gl-uniform-arrays.html
636
637         For an array of active uniform, we should be careful while truncating the name of the uniform. 
638         Currently we are truncating the last three characters of an array with out checking for [0]. 
639         As a result we are truncating the the actual name of the active uniforms i.e. color to co. 
640
641         * html/canvas/WebGLRenderingContext.cpp:
642         (WebCore::WebGLRenderingContext::getUniform): Strip "[0]" from the name if it's an array and is part of the name.
643
644 2011-05-26  Sheriff Bot  <webkit.review.bot@gmail.com>
645
646         Unreviewed, rolling out r87444.
647         http://trac.webkit.org/changeset/87444
648         https://bugs.webkit.org/show_bug.cgi?id=61582
649
650         Layout test regressions in Chromium/WebKit: fast/css/first-
651         letter-text-fragment-crash.html, fast/css/first-letter-
652         visibility.html (Requested by aklein on #webkit).
653
654         * page/Chrome.cpp:
655         * page/Chrome.h:
656         * page/ChromeClient.h:
657         * page/FrameView.cpp:
658         (WebCore::FrameView::setContentsSize):
659         * page/FrameView.h:
660
661 2011-05-26  David Levin  <levin@chromium.org>
662
663         Reviewed by Darin Fisher.
664
665         Need a callback for when the preferred rendered size changed.
666         https://bugs.webkit.org/show_bug.cgi?id=61309
667
668         No new tests needed since no new functionality is exposed.
669
670         * page/Chrome.cpp:
671         (WebCore::Chrome::contentsPreferredSizeChanged): Plumbed through the call.
672         * page/Chrome.h: Added the new method.
673         * page/ChromeClient.h: Ditto.
674         * page/FrameView.cpp:
675         (WebCore::FrameView::setContentsSize): Added calculations for the preferred size
676         and the call to contentsPreferredSizeChanged.
677
678 2011-05-25  Levi Weintraub  <leviw@chromium.org>
679
680         Reviewed by Eric Seidel.
681
682         Switch controlClipRect to use IntPoint
683         https://bugs.webkit.org/show_bug.cgi?id=60806
684
685         Switching controlClipRect to take an IntPoint representing the
686         offset to be added instead of a pair of ints.
687
688         No new tests as this is just refactoring.
689
690         * WebCore.xcodeproj/project.pbxproj:
691         * rendering/RenderBlock.cpp:
692         (WebCore::RenderBlock::nodeAtPoint):
693         * rendering/RenderBox.cpp:
694         (WebCore::RenderBox::pushContentsClip):
695         * rendering/RenderBox.h:
696         (WebCore::RenderBox::controlClipRect):
697         * rendering/RenderButton.cpp:
698         (WebCore::RenderButton::controlClipRect):
699         * rendering/RenderButton.h:
700         * rendering/RenderListBox.cpp:
701         (WebCore::RenderListBox::paintItemBackground):
702         (WebCore::RenderListBox::controlClipRect):
703         * rendering/RenderListBox.h:
704         * rendering/RenderMenuList.cpp:
705         (WebCore::RenderMenuList::controlClipRect):
706         * rendering/RenderMenuList.h:
707         * rendering/RenderTextControlSingleLine.cpp:
708         (WebCore::RenderTextControlSingleLine::controlClipRect):
709         * rendering/RenderTextControlSingleLine.h:
710
711 2011-05-25  Levi Weintraub  <leviw@chromium.org>
712
713         Reviewed by Eric Seidel.
714
715         Switch controlClipRect to use IntPoint
716         https://bugs.webkit.org/show_bug.cgi?id=60806
717
718         Switching controlClipRect to take an IntPoint representing the
719         offset to be added instead of a pair of ints.
720
721         No new tests as this is just refactoring.
722
723         * WebCore.xcodeproj/project.pbxproj:
724         * rendering/RenderBlock.cpp:
725         (WebCore::RenderBlock::nodeAtPoint):
726         * rendering/RenderBox.cpp:
727         (WebCore::RenderBox::pushContentsClip):
728         * rendering/RenderBox.h:
729         (WebCore::RenderBox::controlClipRect):
730         * rendering/RenderButton.cpp:
731         (WebCore::RenderButton::controlClipRect):
732         * rendering/RenderButton.h:
733         * rendering/RenderListBox.cpp:
734         (WebCore::RenderListBox::paintItemBackground):
735         (WebCore::RenderListBox::controlClipRect):
736         * rendering/RenderListBox.h:
737         * rendering/RenderMenuList.cpp:
738         (WebCore::RenderMenuList::controlClipRect):
739         * rendering/RenderMenuList.h:
740         * rendering/RenderTextControlSingleLine.cpp:
741         (WebCore::RenderTextControlSingleLine::controlClipRect):
742         * rendering/RenderTextControlSingleLine.h:
743
744 2011-05-26  Jeff Miller  <jeffm@apple.com>
745
746         Reviewed by Steve Falkenburg.
747
748         Fullscreen content is sometimes obscured by taskbar (which even covers up the "exit fullscreen" button)
749         https://bugs.webkit.org/show_bug.cgi?id=61569
750         <rdar://problem/9454315>
751
752         Normally, when the background fullscreen window is animated in, the Windows taskbar will be hidden, but this doesn't always work for some reason.
753         Workaround this issue by setting the real fullscreen window to be a topmost window.
754
755         * platform/graphics/win/FullScreenController.cpp:
756         (FullScreenController::Private::fullscreenClientWndProc): Exit fullscreen when m_fullScreenWindow is deactivated.
757         (FullScreenController::enterFullScreenRepaintCompleted): Make m_fullScreenWindow a topmost window before animating it in to ensure the taskbar is hidden.
758
759 2011-05-26  James Robinson  <jamesr@chromium.org>
760
761         Reviewed by Darin Fisher.
762
763         [skia] Add area check to ImageBufferData::getImageData
764         https://bugs.webkit.org/show_bug.cgi?id=61375
765
766         No change in behavior, just a sanity check.
767
768         * platform/graphics/skia/ImageBufferSkia.cpp:
769         (WebCore::getImageData):
770
771 2011-05-26  Levi Weintraub  <leviw@chromium.org>
772
773         Reviewed by Eric Seidel.
774
775         Switch positionOverflowControls to IntSize
776         https://bugs.webkit.org/show_bug.cgi?id=61493
777
778         Switching positionOverflowControls to take a layerOffset IntSize
779         as opposed to a pair of ints.
780
781         No new tests since this is just refactoring.
782
783         * rendering/RenderLayer.cpp:
784         (WebCore::RenderLayer::updateLayerPositions):
785         (WebCore::RenderLayer::positionOverflowControls):
786         (WebCore::RenderLayer::paintOverflowControls):
787         * rendering/RenderLayer.h:
788
789 2011-05-26  Sheriff Bot  <webkit.review.bot@gmail.com>
790
791         Unreviewed, rolling out r87368.
792         http://trac.webkit.org/changeset/87368
793         https://bugs.webkit.org/show_bug.cgi?id=61564
794
795         Wrong approach, will do the wrong thing if the element needs
796         simplified normal flow layout but is not positioned (Requested
797         by jamesr on #webkit).
798
799         * rendering/RenderObject.h:
800         (WebCore::RenderObject::needsPositionedMovementLayout):
801
802 2011-05-02  Robert Hogan  <robert@webkit.org>
803
804         Reviewed by Adam Roben.
805
806         [Qt] Allow popup windows from plugins when initiated by a user gesture
807
808         https://bugs.webkit.org/show_bug.cgi?id=41292
809
810         If the event is from a user gesture and the plugin doesn't support
811         NPN_PushPopupsEnabledState() and NPN_PopPopupsEnabledState(), allow popups.
812
813         * plugins/qt/PluginViewQt.cpp:
814         (WebCore::PluginView::dispatchNPEvent):
815
816 2011-05-26  Leandro Gracia Gil  <leandrogracia@chromium.org>
817
818         Reviewed by Dmitry Titov.
819
820         [V8] Add missing compile guards for WebWorkers in WebCore.
821         https://bugs.webkit.org/show_bug.cgi?id=61535
822
823         No new tests - refactoring only.
824
825         * bindings/v8/V8AbstractEventListener.cpp:
826         (WebCore::V8AbstractEventListener::invokeEventHandler):
827         * bindings/v8/V8DOMWrapper.cpp:
828         (WebCore::V8DOMWrapper::instantiateV8Object):
829
830 2011-05-26  Mihai Parparita  <mihaip@chromium.org>
831
832         Reviewed by Adam Barth.
833
834         Support cross-origin XMLHttpRequest in isolated worlds
835         https://bugs.webkit.org/show_bug.cgi?id=59843
836
837         Allows isolated worlds to be associated with a different SecurityOrigin
838         (exposed as a setIsolatedWorldSecurityOrigin function in
839         ScriptController).
840
841         The XMLHttpRequest constructor can then check that it's being
842         instantiated in an isolated world and use its security origin.
843         XMLHttpRequest, ThreadableLoader and DocumentThreadableLoader had to be
844         changed to use the copied SecurityOrigin instead of always grabbing the
845         Document's.
846
847         Test: http/tests/security/isolatedWorld/cross-origin-xhr.html
848
849         * bindings/v8/ScriptController.cpp:
850         (WebCore::ScriptController::setIsolatedWorldSecurityOrigin):
851         * bindings/v8/ScriptController.h:
852         * bindings/v8/V8IsolatedContext.cpp:
853         (WebCore::V8IsolatedContext::setSecurityOrigin):
854         * bindings/v8/V8IsolatedContext.h:
855         (WebCore::V8IsolatedContext::securityOrigin):
856         * bindings/v8/V8Proxy.cpp:
857         (WebCore::V8Proxy::evaluateInIsolatedWorld):
858         (WebCore::V8Proxy::setIsolatedWorldSecurityOrigin):
859         (WebCore::V8Proxy::resetIsolatedWorlds):
860         * bindings/v8/V8Proxy.h:
861         * bindings/v8/custom/V8XMLHttpRequestConstructor.cpp:
862         (WebCore::V8XMLHttpRequest::constructorCallback):
863         * loader/DocumentThreadableLoader.cpp:
864         (WebCore::DocumentThreadableLoader::DocumentThreadableLoader):
865         (WebCore::DocumentThreadableLoader::makeCrossOriginAccessRequestWithPreflight):
866         (WebCore::DocumentThreadableLoader::didReceiveResponse):
867         (WebCore::DocumentThreadableLoader::preflightSuccess):
868         (WebCore::DocumentThreadableLoader::isAllowedRedirect):
869         (WebCore::DocumentThreadableLoader::securityOrigin):
870         * loader/DocumentThreadableLoader.h:
871         * loader/ThreadableLoader.h:
872         * xml/XMLHttpRequest.cpp:
873         (WebCore::XMLHttpRequest::create):
874         (WebCore::XMLHttpRequest::XMLHttpRequest):
875         (WebCore::XMLHttpRequest::securityOrigin):
876         (WebCore::XMLHttpRequest::responseXML):
877         (WebCore::XMLHttpRequest::createRequest):
878         (WebCore::XMLHttpRequest::setRequestHeader):
879         (WebCore::XMLHttpRequest::getAllResponseHeaders):
880         (WebCore::XMLHttpRequest::getResponseHeader):
881         * xml/XMLHttpRequest.h:
882
883 2011-05-26  Michael Nordman  <michaeln@google.com>
884
885         Reviewed by Darin Fisher.
886
887         [Chromium] Use SecurityOrigin produced databaseIdentifier strings, instead of
888         SecurityOrigin RefPtrs, as the top level key into the DatabaseTracker's
889         collection of open databases. Otherwise we can fail to lookup databases when
890         trying to forceably close them via  WebDatabase::closeDatabaseImmediately.
891         https://bugs.webkit.org/show_bug.cgi?id=61417
892
893         New new functionality, no tests.
894
895         * storage/DatabaseTracker.h:
896         * storage/chromium/DatabaseTrackerChromium.cpp:
897         (WebCore::DatabaseTracker::addOpenDatabase):
898         (WebCore::DatabaseTracker::removeOpenDatabase):
899         (WebCore::DatabaseTracker::getOpenDatabases):
900         (WebCore::DatabaseTracker::interruptAllDatabasesForContext):
901
902 2011-05-25  Jer Noble  <jer.noble@apple.com>
903
904         Reviewed by Maciej Stachowiak.
905
906         Safari Web Content crashes while entering/exiting the full screen mode of the video content
907         https://bugs.webkit.org/show_bug.cgi?id=61498
908
909         No new tests, as DRT does not currently animate the full screen transition.
910
911         To guard against m_fullScreenRenderer being called after it has been deleted, add
912         code in RenderFullScreen which notifies the document when its full-screen renderer
913         will be destroyed.
914
915         Also, add some sanity checks when accessing the full-screen renderer's layer backing.
916
917         * dom/Document.cpp:
918         (WebCore::Document::webkitWillEnterFullScreenForElement): Guard against a missing
919             full-screen renderer layer.
920         (WebCore::Document::webkitWillExitFullScreenForElement): Ditto.
921         (WebCore::Document::setFullScreenRenderer): Added ASSERT.
922         (WebCore::Document::fullScreenRendererDestroyed): Added.
923         (WebCore::Document::setAnimatingFullScreen): Guard against the full-screen
924             element having been removed from the document.
925         * dom/Document.h:
926         * rendering/RenderFullScreen.cpp:
927         (RenderFullScreen::destroy): Added.  Tell the Document that it's full-screen
928             renderer is about to be destroyed.
929         * rendering/RenderFullScreen.h:
930
931 2011-05-26  Andreas Kling  <kling@webkit.org>
932
933         Reviewed by Geoffrey Garen.
934
935         Overload resolution in generated JSC bindings could be more efficient.
936         https://bugs.webkit.org/show_bug.cgi?id=61544
937
938         Only fetch the arguments once, and not until they are needed (less work
939         in the case of an early return.)
940
941         * bindings/scripts/CodeGeneratorJS.pm:
942         * bindings/scripts/test/JS/JSTestObj.cpp: Rebaselined.
943         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod):
944
945 2011-05-26  Adrienne Walker  <enne@google.com>
946
947         Reviewed by James Robinson.
948
949         [chromium] Be robust to empty viewports in the compositor
950         https://bugs.webkit.org/show_bug.cgi?id=61545
951
952         It's possible for a frame to be requested to be drawn before it is
953         non-empty.  The compositor should be robust to that possibility.  The
954         changes in LayerTilerChromium are the only required changes to handle
955         this, but having an early out in LayerRendererChromium seemed like a
956         good sanity check.
957
958         * platform/graphics/chromium/LayerRendererChromium.cpp:
959         (WebCore::LayerRendererChromium::updateAndDrawLayers):
960         (WebCore::LayerRendererChromium::drawLayers):
961         * platform/graphics/chromium/LayerTilerChromium.cpp:
962         (WebCore::LayerTilerChromium::prepareToUpdate):
963         (WebCore::LayerTilerChromium::updateRect):
964         (WebCore::LayerTilerChromium::draw):
965
966 2011-05-26  Emil A Eklund  <eae@chromium.org>
967
968         Reviewed by Eric Seidel.
969
970         Change RenderObject to use FloatPoint::scale and FloatQuad::scale
971         https://bugs.webkit.org/show_bug.cgi?id=61497
972
973         Covered by existing test.
974
975         * platform/graphics/FloatQuad.h:
976         (WebCore::FloatQuad::scale):
977         * rendering/RenderObject.h:
978         (WebCore::adjustFloatQuadForAbsoluteZoom):
979         (WebCore::adjustFloatRectForAbsoluteZoom):
980         (WebCore::adjustFloatQuadForPageScale):
981         (WebCore::adjustFloatRectForPageScale):
982
983 2011-05-26  Alexis Menard  <alexis.menard@openbossa.org>
984
985         Unreviewed build fix for Qt and QuickTime backend.
986
987         r87328 added a new system interface, we need to add it too.
988
989         * platform/qt/WebCoreSystemInterface.h:
990         * platform/qt/WebCoreSystemInterface.mm:
991
992 2011-05-26  Andrey Kosyakov  <caseq@chromium.org>
993
994         Unreviewed follow-up to r87395, added checks to avoid accessing undefined member for certain timeline events.
995
996         * inspector/front-end/TimelinePanel.js:
997         (WebInspector.TimelinePanel.prototype._innerAddRecordToTimeline):
998         (WebInspector.TimelinePanel.FormattedRecord):
999
1000 2011-05-25  Ryosuke Niwa  <rniwa@webkit.org>
1001
1002         Reviewed by Enrica Casucci.
1003
1004         WebKit duplicates styles from css rules on copy and paste
1005         https://bugs.webkit.org/show_bug.cgi?id=61466
1006
1007         Fixed the bug by removing duplicate properties from inline style declarations in ReplaceSelectionCommand.
1008         Also moved the code to obtain style from rules from markup.cpp to EditingStyle.cpp to share code.
1009
1010         Test: editing/pasteboard/style-from-rules.html
1011
1012         * editing/EditingStyle.cpp:
1013         (WebCore::EditingStyle::EditingStyle): Added a null check.
1014         (WebCore::EditingStyle::extractFontSizeDelta): Ditto.
1015         (WebCore::styleFromMatchedRulesForElement): Moved from markup.cpp.
1016         (WebCore::EditingStyle::mergeStyleFromRules): Extracted from StyledMarkupAccumulator::appendElement.
1017         (WebCore::EditingStyle::mergeStyleFromRulesForSerialization): Ditto.
1018         (WebCore::EditingStyle::removeStyleFromRules): Added.
1019         * editing/EditingStyle.h:
1020         * editing/ReplaceSelectionCommand.cpp:
1021         (WebCore::ReplaceSelectionCommand::removeRedundantStylesAndKeepStyleSpanInline): Renamed from
1022         negateStyleRulesThatAffectAppearance; Calls removeStyleFromRules.
1023         * editing/markup.cpp:
1024         (WebCore::StyledMarkupAccumulator::appendElement): Calls mergeStyleFromRulesForSerialization.
1025         (WebCore::styleFromMatchedRulesAndInlineDecl): Calls mergeStyleFromRules; changed the return type
1026         from CSSMutableStyleDeclaration to EditingStyle.
1027         (WebCore::isElementPresentational): Calls styleFromMatchedRulesAndInlineDecl.
1028         (WebCore::shouldIncludeWrapperForFullySelectedRoot): Ditto.
1029         (WebCore::highestAncestorToWrapMarkup): Calls shouldIncludeWrapperForFullySelectedRoot.
1030         (WebCore::createMarkup): Calls styleFromMatchedRulesAndInlineDecl.
1031
1032 2011-05-26  Michael Schneider  <michschn@google.com>
1033
1034         Reviewed by Pavel Feldman.
1035
1036         WebInspector: Added API to access the timeline data in a inspector extension.
1037         https://bugs.webkit.org/show_bug.cgi?id=61098
1038
1039         * WebCore.gypi:
1040         * WebCore.vcproj/WebCore.vcproj:
1041         * inspector/front-end/ExtensionAPI.js:
1042         (WebInspector.injectedExtensionAPI.InspectorExtensionAPI):
1043         (WebInspector.injectedExtensionAPI):
1044         * inspector/front-end/ExtensionServer.js:
1045         (WebInspector.ExtensionServer):
1046         (WebInspector.ExtensionServer.prototype._addRecordToTimeline):
1047         (WebInspector.ExtensionServer.prototype._onSubscribe):
1048         (WebInspector.ExtensionServer.prototype._onUnsubscribe):
1049         (WebInspector.ExtensionServer.prototype._registerHandler):
1050         (WebInspector.ExtensionServer.prototype._registerSubscriptionHandler):
1051         * inspector/front-end/TimelineManager.js: Added.
1052         (WebInspector.TimelineManager):
1053         (WebInspector.TimelineManager.prototype.start):
1054         (WebInspector.TimelineManager.prototype.stop):
1055         (WebInspector.TimelineDispatcher):
1056         (WebInspector.TimelineDispatcher.prototype.started):
1057         (WebInspector.TimelineDispatcher.prototype.stopped):
1058         (WebInspector.TimelineDispatcher.prototype.eventRecorded):
1059         * inspector/front-end/TimelinePanel.js:
1060         (WebInspector.TimelinePanel):
1061         (WebInspector.TimelinePanel.prototype._toggleTimelineButtonClicked):
1062         (WebInspector.TimelinePanel.prototype._onTimelineEventRecorded):
1063         * inspector/front-end/WebKit.qrc:
1064         * inspector/front-end/inspector.html:
1065
1066 2011-05-26  Andrey Kosyakov  <caseq@chromium.org>
1067
1068         Reviewed by Yury Semikhatsky.
1069
1070         Web Inspector: TimelinePanel should not modify input timeline data when processing timeline event
1071         https://bugs.webkit.org/show_bug.cgi?id=61529
1072
1073         Do not modify input timeline data when processing timeline event.
1074
1075         * inspector/front-end/TimelinePanel.js:
1076         (WebInspector.TimelinePanel.prototype._addRecordToTimeline):
1077         (WebInspector.TimelinePanel.prototype._innerAddRecordToTimeline):
1078         (WebInspector.TimelinePanel.FormattedRecord):
1079         (WebInspector.TimelinePanel.FormattedRecord.prototype._generatePopupContent):
1080         (WebInspector.TimelinePanel.FormattedRecord.prototype._refreshDetails):
1081         (WebInspector.TimelinePanel.FormattedRecord.prototype._getRecordDetails):
1082
1083 2011-05-26  Rob Buis  <rbuis@rim.com>
1084
1085         Reviewed by Dirk Schulze.
1086
1087         Dynamically created <animate> elements do not animate upon document insertion as they should
1088         https://bugs.webkit.org/show_bug.cgi?id=20028
1089
1090         Tests: svg/animations/animate-insert-begin.html
1091                svg/animations/animate-insert-no-begin.html
1092
1093         Move animation initializing and rescheduling to insertedIntoDocument. This way animate elements
1094         dynamicaly inserted into the document using js start as well.
1095
1096         * svg/animation/SVGSMILElement.cpp:
1097         (WebCore::SVGSMILElement::insertedIntoDocument):
1098         * svg/animation/SVGSMILElement.h:
1099
1100 2011-05-26  Andreas Kling  <kling@webkit.org>
1101
1102         Reviewed by Benjamin Poulain.
1103
1104         JSC DOM bindings: ExecState::argumentCount() is size_t, not int.
1105         https://bugs.webkit.org/show_bug.cgi?id=61530
1106
1107         * bindings/scripts/CodeGeneratorJS.pm:
1108         * bindings/scripts/test/JS/JSTestObj.cpp:
1109         (WebCore::jsTestObjPrototypeFunctionOptionsObject):
1110         (WebCore::jsTestObjPrototypeFunctionWithDynamicFrameAndOptionalArg):
1111         (WebCore::jsTestObjPrototypeFunctionWithDynamicFrameAndUserGestureASAD):
1112         (WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArg):
1113         (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndOptionalArg):
1114         (WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndTwoOptionalArgs):
1115         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod2):
1116         (WebCore::jsTestObjPrototypeFunctionClassMethodWithOptional):
1117
1118 2011-05-26  Simon Fraser  <simon.fraser@apple.com>
1119
1120         Reviewed by Adam Roben.
1121
1122         Some repeating linear gradients look wrong
1123         https://bugs.webkit.org/show_bug.cgi?id=61371
1124
1125         Test: fast/gradients/css3-repeating-linear-gradients2.html
1126         
1127         Fix incorrect stop duplication code when filling forwards a repeating
1128         gradient. The "if (srcStopOrdinal < originalNumStops - 1)" test was wrong
1129         because srcStopOrdinal had been adjusted for stops added by start-filling,
1130         but originalNumStops had not. Fix by considering srcStopOrdinal as an index
1131         into the original stops, so comparing it with originalNumStops remains valid.
1132
1133         * css/CSSGradientValue.cpp:
1134         (WebCore::CSSGradientValue::addStops):
1135
1136 2011-05-26  Vsevolod Vlasov  <vsevik@chromium.org>
1137
1138         Reviewed by Yury Semikhatsky.
1139
1140         Web Inspector: In network panel, show transfer size in a first line of resource row.
1141         https://bugs.webkit.org/show_bug.cgi?id=61354
1142
1143         * English.lproj/localizedStrings.js:
1144         * inspector/front-end/NetworkPanel.js:
1145         (WebInspector.NetworkPanel.prototype._createTable):
1146         (WebInspector.NetworkDataGridNode.prototype._refreshSizeCell):
1147
1148 2011-05-25  Simon Fraser  <simon.fraser@apple.com>
1149
1150         Reviewed by Dan Bernstein.
1151
1152         Always antialias borders, outlines and rules when scaling
1153         https://bugs.webkit.org/show_bug.cgi?id=61502
1154         
1155         r84273 changed the behavior of drawLineForBoxSide() to never antialias by default.
1156         This actually disabled antialiasing in some circumstances where it used to be enabled,
1157         for example collapsed table border drawing.
1158         
1159         Fix by allowing antialiasing for collapsed table borders, column rules and span
1160         outlines when the context is scaled.
1161
1162         Test: fast/borders/border-antialiasing.html
1163
1164         * rendering/RenderBlock.cpp:
1165         (WebCore::RenderBlock::paintColumnRules):
1166         * rendering/RenderInline.cpp:
1167         (WebCore::RenderInline::paintOutline):
1168         (WebCore::RenderInline::paintOutlineForLine):
1169         * rendering/RenderTableCell.cpp:
1170         (WebCore::RenderTableCell::paintCollapsedBorder):
1171
1172 2011-05-26  Vsevolod Vlasov  <vsevik@chromium.org>
1173
1174         Reviewed by Yury Semikhatsky.
1175
1176         Web Inspector: Use different SourceFrame instances for ResourcesPanel and NetworkPanel
1177         https://bugs.webkit.org/show_bug.cgi?id=59193
1178
1179         * inspector/front-end/NetworkItemView.js:
1180         (WebInspector.NetworkItemView):
1181         (WebInspector.NetworkItemView._contentViewForResource):
1182         * inspector/front-end/NetworkPanel.js:
1183         (WebInspector.NetworkPanel.prototype._refreshResource):
1184         * inspector/front-end/Resource.js:
1185         (WebInspector.Resource.prototype.get messages):
1186         (WebInspector.Resource.prototype.addMessage):
1187         (WebInspector.Resource.prototype.set errors):
1188         (WebInspector.Resource.prototype.set warnings):
1189         (WebInspector.Resource.prototype.clearErrorsAndWarnings):
1190         * inspector/front-end/ResourceTreeModel.js:
1191         (WebInspector.ResourceTreeModel.prototype._consoleMessageAdded):
1192         * inspector/front-end/ResourceView.js:
1193         (WebInspector.ResourceView.hasTextContent):
1194         (WebInspector.ResourceView.nonSourceViewForResource):
1195         (WebInspector.ResourceSourceFrame):
1196         (WebInspector.ResourceSourceFrame.mimeTypeForResource):
1197         (WebInspector.ResourceSourceFrame.prototype.requestContent):
1198         (WebInspector.ResourceSourceFrame.prototype.suggestedFileName):
1199         (WebInspector.EditableResourceSourceFrame):
1200         (WebInspector.EditableResourceSourceFrame.prototype.doubleClick):
1201         (WebInspector.EditableResourceSourceFrame.prototype.editContent):
1202         (WebInspector.EditableResourceSourceFrame.prototype.cancelEditing):
1203         (WebInspector.EditableResourceSourceFrame.prototype.afterTextChanged):
1204         (WebInspector.EditableResourceSourceFrame.prototype._clearIncrementalUpdateTimer):
1205         (WebInspector.ResourceRevisionSourceFrame):
1206         (WebInspector.ResourceRevisionSourceFrame.prototype.requestContent):
1207         * inspector/front-end/ResourcesPanel.js:
1208         (WebInspector.ResourcesPanel.prototype.showResource):
1209         (WebInspector.ResourcesPanel.prototype._showResourceView):
1210         (WebInspector.ResourcesPanel.prototype._resourceViewForResource):
1211         (WebInspector.ResourcesPanel.prototype._showRevisionView):
1212         (WebInspector.ResourcesPanel.prototype._sourceViewForRevision):
1213         (WebInspector.ResourcesPanel.prototype.searchCanceled):
1214         (WebInspector.ResourcesPanel.prototype._findTreeElementForRevision):
1215         (WebInspector.ResourcesPanel.prototype._findTreeElementForRevision.getParent):
1216         (WebInspector.FrameResourceTreeElement):
1217         (WebInspector.FrameResourceTreeElement.prototype.onattach):
1218         (WebInspector.FrameResourceTreeElement.prototype._updateErrorsAndWarningsBubbles):
1219         (WebInspector.FrameResourceTreeElement.prototype._errorsWarningsCleared):
1220         (WebInspector.FrameResourceTreeElement.prototype._errorsWarningsMessageAdded):
1221         (WebInspector.FrameResourceTreeElement.prototype._appendRevision):
1222         (WebInspector.FrameResourceTreeElement.prototype.sourceView):
1223         (WebInspector.FrameResourceTreeElement.prototype._createSourceView):
1224         (WebInspector.FrameResourceTreeElement.prototype._recreateSourceView):
1225         (WebInspector.ResourceRevisionTreeElement):
1226         (WebInspector.ResourceRevisionTreeElement.prototype._handleContextMenuEvent):
1227         (WebInspector.ResourceRevisionTreeElement.prototype.sourceView):
1228
1229 2011-05-26  Andreas Kling  <kling@webkit.org>
1230
1231         Reviewed by Darin Adler.
1232
1233         JSC DOM bindings: Use isUndefinedOrNull() instead of (isNull() || isUndefined()).
1234         https://bugs.webkit.org/show_bug.cgi?id=61472
1235
1236         * bindings/scripts/CodeGeneratorJS.pm:
1237         * bindings/scripts/test/JS/JSTestObj.cpp: Rebaselined.
1238         (WebCore::jsTestObjPrototypeFunctionMethodWithCallbackAndOptionalArg):
1239         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod):
1240
1241 2011-05-26  Keishi Hattori  <keishi@webkit.org>
1242
1243         Reviewed by Kent Tamura.
1244
1245         Add <input type=color> appearance.
1246         https://bugs.webkit.org/show_bug.cgi?id=61275
1247
1248         Test: fast/forms/color/input-appearance-color.html
1249
1250         * css/html.css:
1251         (input[type="color"]): Adds square-button appearance.
1252         (input[type="color"]::-webkit-color-swatch-wrapper):
1253         (input[type="color"]::-webkit-color-swatch):
1254         (input[type="color"][list]): Adds menulist appearance.
1255         (input[type="color"][list]::-webkit-color-swatch-wrapper):
1256         (input[type="color"][list]::-webkit-color-swatch):
1257         * html/ColorInputType.cpp:
1258         (WebCore::ColorInputType::createShadowSubtree): Creates -webkit-color-swatch inside -webkit-color-swatch-wrapper.
1259         (WebCore::ColorInputType::updateColorSwatch): Updates background color of shadowColorSwatch.
1260         (WebCore::ColorInputType::valueChanged): Calls updateColorSwatch.
1261         (WebCore::ColorInputType::shadowColorSwatch): Gets shadowColorSwatch element.
1262         * html/ColorInputType.h:
1263         (WebCore::ColorInputType::ColorInputType): Changed to inherit InputType.
1264
1265 2011-05-26  Kent Tamura  <tkent@chromium.org>
1266
1267         Reviewed by Dimitri Glazkov.
1268
1269         Fix a bug that <input type="number"> dispatches two blurs when tabbing
1270         from an invalid number
1271         https://bugs.webkit.org/show_bug.cgi?id=59071
1272
1273         NumberInputType::handleBlurEvent() dispatched an extra focus event
1274         and an extra blur event because
1275         SelectionController::textWillBeReplaced() called by
1276         RenderTextControlSingleLine::updateFromElement() focuses a node
1277         with the selection.
1278
1279         In order to avoid this problem,
1280          - Introduce Node::willBlur()
1281            It is called before any state changes by a blur event.
1282          - Call RenderTextControlSingleLine::updateFromElement() in willBlur()
1283            It avoids extra focus/blur events because Document::m_focusedNode is
1284            still the number input during willBlur().
1285
1286         Test: fast/forms/input-number-blur-twice.html
1287
1288         * dom/Document.cpp:
1289         (WebCore::Document::setFocusedNode): Calls Node::beforeBlueEvent().
1290         * dom/Node.cpp:
1291         (WebCore::Node::willBlur):
1292           Default empty implementation of willBlur().
1293         * dom/Node.h: Declare willBlur().
1294         * html/HTMLInputElement.cpp:
1295         (WebCore::HTMLInputElement::willBlur):
1296           Added.  It just calls InputType::willBlur().
1297         (WebCore::HTMLInputElement::handleBlurEvent):
1298           Removed InputType::handleBlurEvent() call.
1299         * html/HTMLInputElement.h: Declare willBlur().
1300         * html/InputType.cpp:
1301         (WebCore::InputType::willBlur): Default empty implementation.
1302         (WebCore::InputType::handleBlurEvent): Removed.
1303         * html/InputType.h: Declare willBlur(), remove handleBlurEvent().
1304         * html/NumberInputType.cpp:
1305         (WebCore::NumberInputType::willBlur):
1306           Move the code in handleBlurEvent() here.
1307         * html/NumberInputType.h: Declare willBlur().
1308
1309 2011-05-25  Hans Wennborg  <hans@chromium.org>
1310
1311         Reviewed by Steve Block.
1312
1313         IndexedDB: Support LevelDB transactions.
1314         https://bugs.webkit.org/show_bug.cgi?id=61270
1315
1316         Introduce LevelDBTransaction, which implements in-memory transaction
1317         support on top of LevelDB, and hook this up for IndexedDB to use.
1318
1319         This is all covered by existing tests.
1320
1321         * CMakeLists.txt:
1322         * GNUmakefile.list.am:
1323         * WebCore.gypi:
1324         * WebCore.pro:
1325         * WebCore.xcodeproj/project.pbxproj:
1326         * platform/leveldb/LevelDBDatabase.cpp:
1327         (WebCore::LevelDBDatabase::open):
1328         (WebCore::LevelDBDatabase::put):
1329         (WebCore::LevelDBDatabase::remove):
1330         (WebCore::LevelDBDatabase::write):
1331         (WebCore::IteratorImpl::IteratorImpl):
1332         (WebCore::IteratorImpl::isValid):
1333         (WebCore::IteratorImpl::seekToLast):
1334         (WebCore::IteratorImpl::seek):
1335         (WebCore::IteratorImpl::next):
1336         (WebCore::IteratorImpl::prev):
1337         (WebCore::IteratorImpl::key):
1338         (WebCore::IteratorImpl::value):
1339         (WebCore::LevelDBDatabase::createIterator):
1340         (WebCore::LevelDBDatabase::comparator):
1341         * platform/leveldb/LevelDBDatabase.h:
1342         * platform/leveldb/LevelDBIterator.h:
1343         (WebCore::LevelDBIterator::~LevelDBIterator):
1344         * platform/leveldb/LevelDBTransaction.cpp: Added.
1345         (WebCore::LevelDBTransaction::create):
1346         (WebCore::LevelDBTransaction::LevelDBTransaction):
1347         (WebCore::LevelDBTransaction::clearTree):
1348         (WebCore::LevelDBTransaction::~LevelDBTransaction):
1349         (WebCore::makeVector):
1350         (WebCore::LevelDBTransaction::set):
1351         (WebCore::LevelDBTransaction::put):
1352         (WebCore::LevelDBTransaction::remove):
1353         (WebCore::LevelDBTransaction::get):
1354         (WebCore::LevelDBTransaction::commit):
1355         (WebCore::LevelDBTransaction::rollback):
1356         (WebCore::LevelDBTransaction::createIterator):
1357         (WebCore::LevelDBTransaction::TreeIterator::create):
1358         (WebCore::LevelDBTransaction::TreeIterator::isValid):
1359         (WebCore::LevelDBTransaction::TreeIterator::seekToLast):
1360         (WebCore::LevelDBTransaction::TreeIterator::seek):
1361         (WebCore::LevelDBTransaction::TreeIterator::next):
1362         (WebCore::LevelDBTransaction::TreeIterator::prev):
1363         (WebCore::LevelDBTransaction::TreeIterator::key):
1364         (WebCore::LevelDBTransaction::TreeIterator::value):
1365         (WebCore::LevelDBTransaction::TreeIterator::isDeleted):
1366         (WebCore::LevelDBTransaction::TreeIterator::reset):
1367         (WebCore::LevelDBTransaction::TreeIterator::~TreeIterator):
1368         (WebCore::LevelDBTransaction::TreeIterator::TreeIterator):
1369         (WebCore::LevelDBTransaction::TransactionIterator::create):
1370         (WebCore::LevelDBTransaction::TransactionIterator::TransactionIterator):
1371         (WebCore::LevelDBTransaction::TransactionIterator::isValid):
1372         (WebCore::LevelDBTransaction::TransactionIterator::seekToLast):
1373         (WebCore::LevelDBTransaction::TransactionIterator::seek):
1374         (WebCore::LevelDBTransaction::TransactionIterator::next):
1375         (WebCore::LevelDBTransaction::TransactionIterator::prev):
1376         (WebCore::LevelDBTransaction::TransactionIterator::key):
1377         (WebCore::LevelDBTransaction::TransactionIterator::value):
1378         (WebCore::LevelDBTransaction::TransactionIterator::handleConflictsAndDeletes):
1379         (WebCore::LevelDBTransaction::TransactionIterator::setCurrentIteratorToSmallestKey):
1380         (WebCore::LevelDBTransaction::TransactionIterator::setCurrentIteratorToLargestKey):
1381         (WebCore::LevelDBTransaction::registerIterator):
1382         (WebCore::LevelDBTransaction::unregisterIterator):
1383         (WebCore::LevelDBTransaction::resetIterators):
1384         * platform/leveldb/LevelDBTransaction.h: Added.
1385         (WebCore::LevelDBTransaction::AVLTreeAbstractor::get_less):
1386         (WebCore::LevelDBTransaction::AVLTreeAbstractor::set_less):
1387         (WebCore::LevelDBTransaction::AVLTreeAbstractor::get_greater):
1388         (WebCore::LevelDBTransaction::AVLTreeAbstractor::set_greater):
1389         (WebCore::LevelDBTransaction::AVLTreeAbstractor::get_balance_factor):
1390         (WebCore::LevelDBTransaction::AVLTreeAbstractor::set_balance_factor):
1391         (WebCore::LevelDBTransaction::AVLTreeAbstractor::compare_key_key):
1392         (WebCore::LevelDBTransaction::AVLTreeAbstractor::compare_key_node):
1393         (WebCore::LevelDBTransaction::AVLTreeAbstractor::compare_node_node):
1394         (WebCore::LevelDBTransaction::AVLTreeAbstractor::null):
1395         (WebCore::LevelDBTransaction::TransactionIterator::~TransactionIterator):
1396         * platform/leveldb/LevelDBWriteBatch.cpp:
1397         (WebCore::LevelDBWriteBatch::create):
1398         (WebCore::LevelDBWriteBatch::LevelDBWriteBatch):
1399         (WebCore::LevelDBWriteBatch::~LevelDBWriteBatch):
1400         (WebCore::makeSlice):
1401         (WebCore::LevelDBWriteBatch::put):
1402         (WebCore::LevelDBWriteBatch::remove):
1403         (WebCore::LevelDBWriteBatch::clear):
1404         * storage/IDBLevelDBBackingStore.cpp:
1405         (WebCore::getInt):
1406         (WebCore::putInt):
1407         (WebCore::getString):
1408         (WebCore::putString):
1409         (WebCore::getNewObjectStoreId):
1410         (WebCore::IDBLevelDBBackingStore::createObjectStore):
1411         (WebCore::deleteRange):
1412         (WebCore::IDBLevelDBBackingStore::deleteObjectStore):
1413         (WebCore::IDBLevelDBBackingStore::getObjectStoreRecord):
1414         (WebCore::getNewVersionNumber):
1415         (WebCore::IDBLevelDBBackingStore::putObjectStoreRecord):
1416         (WebCore::IDBLevelDBBackingStore::clearObjectStore):
1417         (WebCore::IDBLevelDBBackingStore::deleteObjectStoreRecord):
1418         (WebCore::IDBLevelDBBackingStore::nextAutoIncrementNumber):
1419         (WebCore::IDBLevelDBBackingStore::keyExistsInObjectStore):
1420         (WebCore::IDBLevelDBBackingStore::forEachObjectStoreRecord):
1421         (WebCore::getNewIndexId):
1422         (WebCore::IDBLevelDBBackingStore::createIndex):
1423         (WebCore::IDBLevelDBBackingStore::putIndexDataForRecord):
1424         (WebCore::findGreatestKeyLessThan):
1425         (WebCore::versionExists):
1426         (WebCore::IDBLevelDBBackingStore::getPrimaryKeyViaIndex):
1427         (WebCore::IDBLevelDBBackingStore::keyExistsInIndex):
1428         (WebCore::findLastIndexKeyEqualTo):
1429         (WebCore::IDBLevelDBBackingStore::openObjectStoreCursor):
1430         (WebCore::IDBLevelDBBackingStore::openIndexKeyCursor):
1431         (WebCore::IDBLevelDBBackingStore::openIndexCursor):
1432         (WebCore::IDBLevelDBBackingStore::createTransaction):
1433         (WebCore::IDBLevelDBBackingStore::Transaction::create):
1434         (WebCore::IDBLevelDBBackingStore::Transaction::Transaction):
1435         (WebCore::IDBLevelDBBackingStore::Transaction::begin):
1436         (WebCore::IDBLevelDBBackingStore::Transaction::commit):
1437         (WebCore::IDBLevelDBBackingStore::Transaction::rollback):
1438         * storage/IDBLevelDBBackingStore.h:
1439         * storage/IDBTransactionBackendImpl.cpp:
1440         (WebCore::IDBTransactionBackendImpl::abort):
1441
1442 2011-05-26  Shane Stephens  <shanestephens@google.com>
1443
1444         Reviewed by James Robinson.
1445
1446         REGRESSION (r81992): layout triggered by position update fails to apply when transform is updated at same time
1447         https://bugs.webkit.org/show_bug.cgi?id=60689
1448
1449         Test: transforms/2d/set-transform-and-top.html
1450
1451         * rendering/RenderBlock.cpp:
1452         (WebCore::RenderBlock::simplifiedLayout):
1453
1454 2011-05-26  Igor Oliveira  <igor.oliveira@openbossa.org>
1455
1456         Reviewed by Andreas Kling.
1457
1458         drag-not-loaded-image.html test crashes when WebKit is built with debug option
1459         https://bugs.webkit.org/show_bug.cgi?id=61480
1460
1461         Checks if image has content before starting to drag.
1462
1463         * page/DragController.cpp:
1464         (WebCore::DragController::startDrag):
1465
1466 2011-05-26  Alok Priyadarshi  <alokp@chromium.org>
1467
1468         Reviewed by James Robinson.
1469
1470         [chromium] Cannot create stencil render-buffer for accelerated drawing on desktop GL
1471         https://bugs.webkit.org/show_bug.cgi?id=61444
1472
1473         Used DEPTH24_STENCIL8 format for stencil buffer instead of STENCIL_INDEX8.
1474         Packed depth-stencil buffer is the most common format supported by graphics cards.
1475         It is not very robust to rely on just one format being supported,
1476         so long term the task of creating FBO should be delegated to SKIA,
1477         which has necessary code to iterate through all possible formats.
1478
1479         * platform/graphics/chromium/LayerTextureUpdaterCanvas.cpp:
1480         (WebCore::LayerTextureUpdaterSkPicture::deleteFrameBuffer):
1481         (WebCore::LayerTextureUpdaterSkPicture::createFrameBuffer):
1482
1483 2011-05-25  Jer Noble  <jer.noble@apple.com>
1484
1485         Reviewed by Dan Bernstein.
1486
1487         30 second rewind button dysfunctional viewing trailers fullscreen.
1488         https://bugs.webkit.org/show_bug.cgi?id=61505
1489
1490         Add support for painting MediaReturnToRealtimeButton, as well as hide and show
1491         the correct default video control buttons when entering full-screen mode.
1492
1493         * css/fullscreenQuickTime.css:
1494         (video:-webkit-full-screen::-webkit-media-controls-return-to-realtime-button):
1495         * html/shadow/MediaControlRootElement.cpp:
1496         (WebCore::MediaControlRootElement::enteredFullscreen): Show the "Back 30s" and
1497             "Return to Realtime" buttons for Live Streams in full-screen mode.
1498         (WebCore::MediaControlRootElement::exitedFullscreen): Reset the styles of 
1499             all the buttons affected by enteredFullscreen().
1500         * rendering/RenderMediaControls.cpp:
1501         (WebCore::RenderMediaControls::paintMediaControlsPart): Add support for 
1502             MediaReturnToRealtimeButton.
1503
1504 2011-05-25  Luke Macpherson   <macpherson@chromium.org>
1505
1506         Reviewed by Dimitri Glazkov.
1507
1508         Implement various CSS font properties in CSSStyleApplyProperty.
1509         https://bugs.webkit.org/show_bug.cgi?id=60603
1510
1511         No new tests - refactoring only.
1512
1513         * css/CSSStyleApplyProperty.cpp:
1514         (WebCore::ApplyPropertyFont):
1515         Added templated class to handle font properties
1516         (WebCore::ApplyPropertyFontWeight):
1517         Added class to handle font weight calculation
1518         (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):
1519         Instantiate ApplyPropertyFont/ApplyPropertyFontWeight for appropriate properties.
1520         * css/CSSStyleSelector.cpp:
1521         (WebCore::CSSStyleSelector::applyProperty):
1522         Remove properties that are now implemented in CSSStyleApplyProperty
1523         * css/CSSStyleSelector.h:
1524         (WebCore::CSSStyleSelector::fontDescription):
1525         Added getter for m_style->fontDescription()
1526         (WebCore::CSSStyleSelector::parentFontDescription):
1527         Added getter for m_parentStyle->fontDescription()
1528         (WebCore::CSSStyleSelector::setFontDescription):
1529         Added setter for m_style->setFontDescription() that automatically sets m_fontDirty
1530
1531 2011-05-25  James Simonsen  <simonjam@chromium.org>
1532
1533         Reviewed by Adam Barth.
1534
1535         Add site-specific hack for zipcar.com with old versions of requirejs.
1536         https://bugs.webkit.org/show_bug.cgi?id=61321
1537
1538         Old versions of requirejs (< 0.15.0) try to load scripts in parallel but execute them in
1539         order. This used to work in webkit by setting a bogus script type (script/cache), then
1540         changing the type to a valid one when they wanted to execute it. This hack translates the
1541         behavior into the new API (by disabling forceAsync).
1542
1543         * html/HTMLScriptElement.cpp:
1544         (WebCore::needsOldRequirejsQuirk): Added.
1545         (WebCore::HTMLScriptElement::insertedIntoDocument):
1546         If hack is needed, set a proper script type so script loads.
1547         If script isn't async, disable forceAsync so script executes in order.
1548
1549 2011-05-25  Andreas Kling  <kling@webkit.org>
1550
1551         Reviewed by David Levin.
1552
1553         Rebaseline run-bindings-tests.
1554         https://bugs.webkit.org/show_bug.cgi?id=61469
1555
1556         * bindings/scripts/test/JS/:
1557         * bindings/scripts/test/V8/:
1558
1559 2011-05-25  Levi Weintraub  <leviw@chromium.org>
1560
1561         Reviewed by Eric Seidel.
1562
1563         Switch itemBoundingBoxRect to use IntPoint
1564         https://bugs.webkit.org/show_bug.cgi?id=60789
1565
1566         Changing itemBoundingBoxRect to use an IntPoint representing the offset
1567         to be added tot he box rect instead of a pair of ints.
1568
1569         No new tests since this is just refactoring.
1570
1571         * accessibility/AccessibilityListBox.cpp:
1572         (WebCore::AccessibilityListBox::elementAccessibilityHitTest):
1573         * accessibility/AccessibilityListBoxOption.cpp:
1574         (WebCore::AccessibilityListBoxOption::elementRect):
1575         * rendering/RenderListBox.cpp:
1576         (WebCore::RenderListBox::itemBoundingBoxRect):
1577         (WebCore::RenderListBox::addFocusRingRects):
1578         (WebCore::RenderListBox::paintItemForeground):
1579         (WebCore::RenderListBox::paintItemBackground):
1580         (WebCore::RenderListBox::nodeAtPoint):
1581         * rendering/RenderListBox.h:
1582
1583 2011-05-24  MORITA Hajime  <morrita@google.com>
1584
1585         Reviewed by Dimitri Glazkov.
1586
1587         RenderText with empty text is not created inside ShadowContentElement 
1588         https://bugs.webkit.org/show_bug.cgi?id=61111        
1589
1590         - Changed Text::rendererIsNeeded() to be shadow-aware.
1591         - previousRenderer(), nextRenderer() and parentRenderer() on NodeRenderingContext is now
1592           safe even if it's used with an attached node, which was originally used only during attach().
1593           We need this change because these APIs are called inside CharacterData::updateRenderer() callstack.
1594         
1595         Tests: fast/html/details-replace-summary-child.html
1596                fast/html/details-replace-text.html
1597
1598         * dom/NodeRenderingContext.cpp:
1599         (WebCore::NodeRenderingContext::NodeRenderingContext):
1600         (WebCore::NodeRenderingContext::nextRenderer):
1601         (WebCore::NodeRenderingContext::previousRenderer):
1602         (WebCore::NodeRenderingContext::parentRenderer):
1603         (WebCore::NodeRenderingContext::shouldCreateRenderer):
1604         * dom/NodeRenderingContext.h:
1605         (WebCore::NodeRenderingContext::parentNodeForRenderingAndStyle):
1606         * dom/Text.cpp:
1607         (WebCore::Text::rendererIsNeeded):
1608
1609 2011-05-25  Sailesh Agrawal  <sail@chromium.org>
1610
1611         Reviewed by Tony Chang.
1612
1613         Rename ScrollbarOverlayUtilitiesMac to ScrollbarOverlayUtilitiesChromiumMac
1614         https://bugs.webkit.org/show_bug.cgi?id=61401
1615
1616         ScrollbarOverlayUtilitiesMac.mm was being excluded from the WebCore project. Fix was to make sure the file name ended with ChromiumMac.
1617
1618         * WebCore.gypi:
1619         * platform/chromium/ScrollbarOverlayUtilitiesChromiumMac.h: Copied from Source/WebCore/platform/chromium/ScrollbarOverlayUtilitiesMac.h.
1620         * platform/chromium/ScrollbarOverlayUtilitiesChromiumMac.mm: Copied from Source/WebCore/platform/chromium/ScrollbarOverlayUtilitiesMac.mm.
1621         * platform/chromium/ScrollbarOverlayUtilitiesMac.h: Removed.
1622         * platform/chromium/ScrollbarOverlayUtilitiesMac.mm: Removed.
1623
1624 2011-05-25  James Robinson  <jamesr@chromium.org>
1625
1626         Reviewed by Geoffrey Garen
1627
1628         CachedResource overhead size calculation ignores the actual size of the URL
1629         https://bugs.webkit.org/show_bug.cgi?id=61481
1630
1631         CachedResource::overheadSize is used to determine the size of an entry in the memory cache to know when to evict
1632         it.  When the resource is a large data: URL, for example representing image or audio data, the URL size itself
1633         can be significant.
1634
1635         This patch uses an estimate of actual number of bytes used by the URL that is valid for ASCII urls and close for
1636         other types of strings instead of a fixed number.
1637
1638         * loader/cache/CachedResource.cpp:
1639         (WebCore::CachedResource::overheadSize):
1640
1641 2011-05-25  Oliver Hunt  <oliver@apple.com>
1642
1643         Reviewed by Geoffrey Garen.
1644
1645         Make RegExp GC allocated
1646         https://bugs.webkit.org/show_bug.cgi?id=61490
1647
1648         RegExp is GC'd so we don't need the RefPtr shenanigans anymore.
1649
1650         * bindings/js/SerializedScriptValue.cpp:
1651         (WebCore::CloneDeserializer::readTerminal):
1652
1653 2011-05-25  Martin Robinson  <mrobinson@igalia.com>
1654
1655         Reviewed by Dirk Schulze.
1656
1657         [Cairo] Move the global alpha property from GraphicsContext to PlatformContextCairo
1658         https://bugs.webkit.org/show_bug.cgi?id=60185
1659
1660         Remove Cairo #ifdefs from GraphicsContext.h by pushing the global alpha
1661         state into PlatformContextCairo. Since Cairo is the only platform that needs
1662         to store this, this is the proper place for it. Change the image mask stack into
1663         a more generic state stack that can keep track of the multiple bits of platform
1664         specific state and properly handle save/restore pairs.
1665
1666         No new tests. This is just a code refactor.
1667
1668         * platform/graphics/GraphicsContext.h: Remove Cairo #ifdefs.
1669         (WebCore::GraphicsContextState::GraphicsContextState): Ditto.
1670         * platform/graphics/cairo/ContextShadowCairo.cpp: Access global alpha from PlatformContextCairo now.
1671         (WebCore::ContextShadow::drawRectShadow):
1672         * platform/graphics/cairo/FontCairo.cpp: Ditto.
1673         (WebCore::Font::drawGlyphs):
1674         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1675         (WebCore::setPlatformFill): Ditto.
1676         (WebCore::setPlatformStroke): Ditto.
1677         (WebCore::GraphicsContext::setAlpha): Ditto.
1678         * platform/graphics/cairo/PlatformContextCairo.cpp: Moved ImageMaskInformation class from the
1679         header file, since it can be private now. Abstract the image mask state and the global alpha
1680         in a generic State class.
1681         (WebCore::ImageMaskInformation::update): 
1682         (WebCore::ImageMaskInformation::isValid):
1683         (WebCore::ImageMaskInformation::maskSurface):
1684         (WebCore::ImageMaskInformation::maskRect):
1685         (WebCore::PlatformContextCairo::State::State): Added.
1686         (WebCore::PlatformContextCairo::PlatformContextCairo): Intialize the state
1687         class when this class is constructed.
1688         (WebCore::PlatformContextCairo::restore): Now pop the last state off the state stack.
1689         (WebCore::PlatformContextCairo::~PlatformContextCairo): Added this so that we can forward
1690         declare the State class in the header.
1691         (WebCore::PlatformContextCairo::save): Push a new state onto the stack.
1692         (WebCore::PlatformContextCairo::pushImageMask): Operate on the state stack now.
1693         (WebCore::PlatformContextCairo::globalAlpha): Added.
1694         (WebCore::PlatformContextCairo::setGlobalAlpha): Added.
1695         (WebCore::PlatformContextCairo::drawSurfaceToContext: Call globalAlpha().
1696         * platform/graphics/cairo/PlatformContextCairo.h: Changed the image mask stack
1697         into a more generic state stack, much like PlatformContextChromium.
1698
1699 2011-05-25  Mark Rowe  <mrowe@apple.com>
1700
1701         Reviewed by Sam Weinig.
1702
1703         <rdar://problem/9504058> Need some way to query user gesture state from injected bundle
1704
1705         * WebCore.exp.in: Add an export that WebKit2 needs.
1706
1707 2011-05-25  Jer Noble  <jer.noble@apple.com>
1708
1709         Ureviewed; Build fix for Leopard and Snow Leopard.
1710
1711         Move _wkQTMovieResolvedURL outside of a #if check for Leopard and SL.
1712
1713         * WebCore.exp.in:
1714
1715 2011-05-25  Michael Saboff  <msaboff@apple.com>
1716
1717         Reviewed by Sam Weinig.
1718
1719         Cleanup of commented items from https://bugs.webkit.org/show_bug.cgi?id=61222
1720         https://bugs.webkit.org/show_bug.cgi?id=61478
1721
1722         Cleanup of further comments after patch was landed.  Changes include
1723         using /2 instead of >>1, adding a blank line after class include,
1724         making method names start with lower case and adding clarifying
1725         comments.
1726
1727         No new tests as the changes are stylistic and not functional.
1728
1729         * loader/cache/MemoryCache.cpp:
1730         (WebCore::MemoryCache::pruneLiveResourcesToPercentage):
1731         (WebCore::MemoryCache::pruneDeadResourcesToPercentage):
1732         * loader/cache/MemoryCache.h:
1733         (WebCore::MemoryCache::pruneToPercentage):
1734         * platform/mac/MemoryPressureHandlerMac.mm:
1735         (WebCore::MemoryPressureHandler::respondToMemoryPressure):
1736
1737 2011-05-25  Stephanie Lewis  <slewis@apple.com>
1738
1739         Reviewed by Brady Eidson.
1740
1741         https://bugs.webkit.org/show_bug.cgi?id=61407
1742         part of <rdar://problem/8675177>
1743         Move Quicklook quirk down into WebCore so it can be caculated when the user
1744         starts a reload.  Restructure the conditions so it only called when absolutely 
1745         necessary.
1746   
1747         No change in functionality so no new tests.
1748
1749         * loader/FrameLoader.cpp:
1750         (WebCore::FrameLoader::subresourceCachePolicy):
1751         * page/Settings.cpp:
1752         (WebCore::Settings::Settings):
1753         * page/Settings.h:
1754         * platform/network/cf/ResourceRequest.h:
1755         * platform/network/mac/ResourceRequestMac.mm:
1756         (WebCore::initQuickLookResourceCachingQuirks):
1757         (WebCore::ResourceRequest::useQuickLookResourceCachingQuirks):
1758
1759 2011-05-24  Jer Noble  <jer.noble@apple.com>
1760
1761         Reviewed by Darin Adler.
1762
1763         Video fails to play on Vimeo
1764         https://bugs.webkit.org/show_bug.cgi?id=61403
1765
1766         No new tests; Covered by media/video-canvas-source.html.
1767
1768         Vimeo redirects their assets from player.vimeo.com to av.vimeo.com, which is rejected
1769         by AVFoundation and QTKit due to our setting a ForbidCrossSiteReference option when
1770         creating an AVAsset or QTMovie. Instead, we should just reject local->remote and
1771         remote->local and make our answer to hasSingleSecurityOrigin dynamic.
1772
1773         When checking whether a given request has a single security origin, use a 
1774         SecurityOrigin to check the host, port, and scheme.
1775
1776         * WebCore.exp.in:
1777         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
1778         (WebCore::MediaPlayerPrivateAVFoundation::assetURL): Added.
1779         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.h:
1780         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.mm:
1781         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Exchange ForbidCrossSiteReference
1782             for ForbidRemoteReferenceToLocal and ForbidLocalReferenceToRemote
1783         (WebCore::MediaPlayerPrivateAVFoundationObjC::hasSingleSecurityOrigin): Check to see that the
1784             requested and resolved URLs have the same host and port.
1785         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
1786         (WebCore::MediaPlayerPrivateQTKit::commonMovieAttributes): Exchange NoCrossSiteAttribute for 
1787             NoRemoteToLocalSiteAttribute and NoLocalToRemoteSiteAttribute.
1788         (WebCore::MediaPlayerPrivateQTKit::hasSingleSecurityOrigin):     Check to see that the
1789                 requested and resolved URLs have the same host and port.
1790         * platform/mac/WebCoreSystemInterface.h: Added wkAVAssetResolvedURL.
1791         * platform/mac/WebCoreSystemInterface.mm: Ditto.
1792
1793 2011-05-25  Andrew Scherkus  <scherkus@chromium.org>
1794
1795         Reviewed by Eric Carlson.
1796
1797         Fix media element regression where ended event stopped firing after changing the src attribute.
1798
1799         https://bugs.webkit.org/show_bug.cgi?id=61336
1800
1801         Test: media/media-ended.html
1802
1803         * html/HTMLMediaElement.cpp:
1804         (WebCore::HTMLMediaElement::prepareForLoad):
1805
1806 2011-05-25  Jer Noble  <jer.noble@apple.com>
1807
1808         Reviewed by Darin Adler.
1809
1810         REGRESSION: Fullscreen button on embedded Vimeo videos does nothing
1811         https://bugs.webkit.org/show_bug.cgi?id=61461
1812
1813         Tests: fullscreen/full-screen-iframe-legacy.html
1814
1815         Allow calls from the legacy full-screen API to bypass the iframe
1816         "webkitallowfullscreen" requirement by adding a parameter to 
1817         Document::webkitRequestFullScreenForElement specifying the strictness
1818         of that check.  Specify this new parameter everywhere that function is 
1819         called, including in the default controls' full-screen button handler.
1820
1821         * dom/Document.cpp:
1822         (WebCore::Document::webkitRequestFullScreenForElement):
1823         * dom/Document.h:
1824         * dom/Element.cpp:
1825         (WebCore::Element::requestFullScreen): Renamed from webkitRequestFullScreen.
1826         * html/HTMLMediaElement.cpp:
1827         (WebCore::HTMLMediaElement::enterFullscreen):
1828         * html/shadow/MediaControlElements.cpp:
1829         (WebCore::MediaControlFullscreenButtonElement::defaultEventHandler):
1830
1831 2011-05-25  Kulanthaivel Palanichamy  <kulanthaivel@codeaurora.org>
1832
1833         Reviewed by David Hyatt.
1834
1835         Selector matching doesn't update when DOM changes ("[data-a=x] #x")
1836         https://bugs.webkit.org/show_bug.cgi?id=60752
1837
1838         Currently CSSStyleSelector maintains a HashSet of attributes (m_selectorAttrs)
1839         which are used in CSS attribute selectors to determine the need for style
1840         recalculation whenever element attributes are manipulated in DOM.
1841         In certain conditions (element with no style, element is styled and attribute
1842         is not a mapped attribute, attribute is of type 'type' or read-only)
1843         even when attribute selector matches for an element, the attribute is not
1844         added to m_selectorAttrs. This results in missing style recalculations
1845         when a DOM element attribute is changed and is not found in m_selectorAttrs.
1846
1847         Removing the above said conditions in
1848         CSSStyleSelector::SelectorChecker::checkOneSelector() for registering
1849         attributes in m_selectorAttrs will solve this issue. But this particular
1850         function is called numerous times which triggers adding duplicate attributes
1851         again and again.
1852
1853         This patch follows the approach taken for collecting ids in selectors, where
1854         all the attributes in selectors are added to a HashSet at the time of adding
1855         style rules to CSSStyleSelector from StyleSheets and when
1856         CSSStyleSelector::hasSelectorForAttribute() is called, the attribute is
1857         simply looked up in this pre-populated hash set.
1858
1859         Test: fast/css/attribute-selector-dynamic-no-elementstyle.html
1860
1861         * css/CSSStyleSelector.cpp:
1862         (WebCore::CSSStyleSelector::SelectorChecker::checkSelector):
1863         (WebCore::CSSStyleSelector::checkSelector):
1864         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector):
1865         (WebCore::collectFeaturesFromSelector):
1866         (WebCore::CSSStyleSelector::applyProperty):
1867         (WebCore::CSSStyleSelector::hasSelectorForAttribute):
1868         * css/CSSStyleSelector.h:
1869
1870 2011-05-25  Ryosuke Niwa  <rniwa@webkit.org>
1871
1872         Reviewed by James Robinson.
1873
1874         CSSStyleSelector should provide a way to obtain rules from non-author stylesheets
1875         https://bugs.webkit.org/show_bug.cgi?id=61454
1876
1877         Replaced bool and enum arguments of styleRulesForElement and pseudoStyleRulesForElement
1878         by one enum, and provided a way to obtain rules from UA/user stylesheets.
1879
1880         * css/CSSRule.h: Removed CSSRuleFilter.
1881         * css/CSSStyleSelector.cpp:
1882         (WebCore::CSSStyleSelector::styleRulesForElement): See above.
1883         (WebCore::CSSStyleSelector::pseudoStyleRulesForElement): Ditto.
1884         * css/CSSStyleSelector.h: Moved CSSRuleFilter here.
1885         * editing/markup.cpp:
1886         (WebCore::styleFromMatchedRulesForElement): Calls styleRulesForElement.
1887         * inspector/InspectorCSSAgent.cpp:
1888         (WebCore::InspectorCSSAgent::getStylesForNode): Ditto.
1889         * page/DOMWindow.cpp:
1890         (WebCore::DOMWindow::getMatchedCSSRules): Ditto.
1891
1892 2011-05-25  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
1893
1894         Reviewed by Andreas Kling.
1895
1896         [Qt] JSC bridge: implement __qt_sender__ without using Scope Chain
1897         https://bugs.webkit.org/show_bug.cgi?id=61343
1898
1899         Create a stack to keep track of the sender objects. This is simpler than
1900         the similar mechanism in QObject (C++ API), that keeps a stack per-object.
1901
1902         Since we do not support multiple threads, one static stack will be enough for
1903         handling the behavior.
1904
1905         This behavior is covered by the tst_QWebFrame::connectAndDisconnect() auto test.
1906
1907         * bridge/qt/qt_instance.cpp:
1908         (JSC::Bindings::QtInstance::qtSenderStack):
1909         We have one static stack of QObject*. The top of the stack contains the
1910         last object that emitted signal that called a JavaScript function.
1911
1912         * bridge/qt/qt_instance.h:
1913         (JSC::Bindings::QtInstance::QtSenderStack::top):
1914         (JSC::Bindings::QtInstance::QtSenderStack::push):
1915         (JSC::Bindings::QtInstance::QtSenderStack::pop):
1916         Minimal functionality to manipulate the sender stack.
1917
1918         * bridge/qt/qt_runtime.cpp:
1919         (JSC::Bindings::QtConnectionObject::execute):
1920         Remove the previous code that modified the scope chain. Push the sender object
1921         to the stack before calling the JavaScript function (the "slot" in Qt-speak) and
1922         pop it afterwards.
1923
1924 2011-05-25  Sheriff Bot  <webkit.review.bot@gmail.com>
1925
1926         Unreviewed, rolling out r87257.
1927         http://trac.webkit.org/changeset/87257
1928         https://bugs.webkit.org/show_bug.cgi?id=61457
1929
1930         This broke layout tests, see bug 61431. (Requested by
1931         hwennborg on #webkit).
1932
1933         * storage/IDBBackingStore.h:
1934         * storage/IDBFactoryBackendImpl.cpp:
1935         (WebCore::IDBFactoryBackendImpl::IDBFactoryBackendImpl):
1936         (WebCore::IDBFactoryBackendImpl::open):
1937         * storage/IDBFactoryBackendImpl.h:
1938         * storage/IDBFactoryBackendInterface.h:
1939         * storage/IDBLevelDBBackingStore.cpp:
1940         * storage/IDBLevelDBBackingStore.h:
1941         * storage/IDBSQLiteBackingStore.cpp:
1942         * storage/IDBSQLiteBackingStore.h:
1943
1944 2011-05-25  Alexis Menard  <alexis.menard@openbossa.org>
1945
1946         Reviewed by Eric Carlson.
1947
1948         [Qt] Enable usage of QuickTime mediaplayer for the Qt port on Mac.
1949         https://bugs.webkit.org/show_bug.cgi?id=61279
1950
1951         Enable the QuickTime backend for the Qt port on Mac. The patch adds the bits in WebCore
1952         to enable the QTKit backend of the Mac port. It can be enabled by passing DEFINES+=USE_QTKIT=1
1953         when calling build-webkit.
1954
1955         * WebCore.pri:
1956         * WebCore.pro:
1957         * features.pri:
1958         * platform/KURL.h:
1959         * platform/SharedBuffer.h:
1960         * platform/cf/KURLCFNet.cpp:
1961         * platform/cf/SharedBufferCF.cpp:
1962         * platform/graphics/FloatSize.h:
1963         * platform/graphics/IntRect.h:
1964         * platform/graphics/IntSize.h:
1965         * platform/graphics/MediaPlayer.cpp:
1966         * platform/graphics/cg/FloatSizeCG.cpp:
1967         * platform/graphics/cg/IntRectCG.cpp:
1968         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
1969         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
1970         (WebCore::MediaPlayerPrivateQTKit::createQTMovieView):
1971         (WebCore::MediaPlayerPrivateQTKit::createQTVideoRenderer):
1972         (WebCore::MediaPlayerPrivateQTKit::createQTMovieLayer):
1973         (WebCore::MediaPlayerPrivateQTKit::preferredRenderingMode):
1974         (WebCore::MediaPlayerPrivateQTKit::paint):
1975         (-[WebCoreMovieObserver layerHostChanged:]):
1976         * platform/mac/KURLMac.mm:
1977         * platform/mac/SharedBufferMac.mm:
1978         (+[WebCoreSharedBufferData initialize]):
1979         * platform/mac/WebCoreObjCExtras.mm:
1980         * platform/qt/WebCoreSystemInterface.h: Added.
1981         * platform/qt/WebCoreSystemInterface.mm: Added.
1982
1983 2011-05-25  Rob Buis  <rbuis@rim.com>
1984
1985         Reviewed by Eric Seidel.
1986         New test rubber-stamped by Dirk Schulze.
1987
1988         WebKit does not handle missing filter elements correctly
1989         https://bugs.webkit.org/show_bug.cgi?id=12569
1990
1991         Do not render elements that reference non-existant filters.
1992
1993         Test: svg/W3C-SVG-1.1-SE/filters-felem-01-b.svg
1994
1995         * rendering/svg/SVGRenderSupport.cpp:
1996         (WebCore::SVGRenderSupport::prepareToRenderSVGContent):
1997
1998 2011-05-25  Nate Chapin  <japhet@chromium.org>
1999
2000         Reviewed by Adam Barth.
2001
2002         Put view-source documents in a unique origin and always allow them to run scripts. This ensures tools like
2003         XMLViewer work even when scripts are disabled, while still providing the protections expected when scripts are disabled.
2004         https://bugs.webkit.org/show_bug.cgi?id=59113
2005
2006         * bindings/ScriptControllerBase.cpp:
2007         (WebCore::ScriptController::canExecuteScripts): Check whether the document is viewing source, and allow scripts in that case.
2008         * css/CSSStyleSelector.cpp:
2009         (WebCore::CSSStyleSelector::matchUARules):
2010         * dom/Document.cpp:
2011         (WebCore::Document::Document):
2012         (WebCore::Document::setIsViewSource): Renamed from setUsesViewSourceStyles(), set's a unique security origin if we are viewing source.
2013         * dom/Document.h:
2014         (WebCore::Document::isViewSource): Renamed from usesViewSourceStyles().
2015         * html/HTMLViewSourceDocument.cpp:
2016         (WebCore::HTMLViewSourceDocument::HTMLViewSourceDocument):
2017         * loader/FrameLoader.cpp:
2018         (WebCore::FrameLoader::receivedFirstData):
2019         * xml/XMLTreeViewer.cpp:
2020         (WebCore::XMLTreeViewer::transformDocumentToTreeView):
2021
2022 2011-05-25  Julien Chaffraix  <jchaffraix@codeaurora.org>
2023
2024         Reviewed by James Robinson.
2025
2026         http://philip.html5.org/tests/canvas/suite/tests/2d.composite.uncovered.fill.source-in.html fails
2027         https://bugs.webkit.org/show_bug.cgi?id=39027
2028
2029         And:
2030
2031         - Fix LayoutTests/canvas/philip/tests/2d.composite.uncovered.fill.source-out.html
2032           https://bugs.webkit.org/show_bug.cgi?id=48295
2033
2034         - Fix LayoutTests/canvas/philip/tests/2d.composite.uncovered.pattern.source-in.html
2035           https://bugs.webkit.org/show_bug.cgi?id=48304
2036
2037         - Fix LayoutTests/canvas/philip/tests/2d.composite.uncovered.pattern.source-out.html
2038         https://bugs.webkit.org/show_bug.cgi?id=48305
2039
2040         Those 4 tests have the same root cause for failing. Instead of splitting them in 2 fixes, I squashed
2041         them together as the fix is common.
2042
2043         Based on an older work by Ariya Hidayat.
2044
2045         * html/canvas/CanvasRenderingContext2D.cpp:
2046         (WebCore::CanvasRenderingContext2D::fill):
2047         (WebCore::CanvasRenderingContext2D::fillRect): Added call displayTransparencyEverywhere for those 2
2048         cases if we have to.
2049
2050         (WebCore::CanvasRenderingContext2D::shouldDisplayTransparencyEverywhere): This method returns true if
2051         the spec says to display transparency everywhere. We only do so for source-in and source-out for now.
2052         (WebCore::CanvasRenderingContext2D::displayTransparencyEverywhere): This method implements the spec
2053         (which matches other browsers' behavior) and "display transparency elsewhere".
2054
2055         * html/canvas/CanvasRenderingContext2D.h: Added the two previous methods.
2056
2057 2011-05-25  Levi Weintraub  <leviw@chromium.org>
2058
2059         Reviewed by Eric Seidel.
2060
2061         Add IntPoint versions of IntRect::move and IntPoint::move
2062         https://bugs.webkit.org/show_bug.cgi?id=61390
2063
2064         Adding move methods to IntRect and IntPoint that take an IntPoint
2065         that's acting as an offset. Since we also apply negative offsets,
2066         also adding a single parameter operator- for IntPoint.
2067
2068         No new tests since this is refactoring.
2069
2070         * page/FrameView.cpp:
2071         (WebCore::FrameView::invalidateScrollbarRect):
2072         (WebCore::FrameView::convertFromRenderer):
2073         (WebCore::FrameView::convertToRenderer):
2074         * platform/ScrollView.cpp:
2075         (WebCore::ScrollView::wheelEvent):
2076         * platform/ScrollView.h:
2077         (WebCore::ScrollView::convertChildToSelf):
2078         (WebCore::ScrollView::convertSelfToChild):
2079         * platform/ScrollbarThemeComposite.cpp:
2080         (WebCore::ScrollbarThemeComposite::invalidatePart):
2081         * platform/graphics/IntPoint.h:
2082         (WebCore::IntPoint::move):
2083         (WebCore::operator-):
2084         * platform/graphics/IntRect.h:
2085         (WebCore::IntRect::move):
2086         * platform/graphics/filters/FilterEffect.cpp:
2087         (WebCore::FilterEffect::requestedRegionOfInputImageData):
2088         * platform/graphics/gpu/Texture.cpp:
2089         (WebCore::Texture::updateSubRect):
2090         * platform/mac/WidgetMac.mm:
2091         (WebCore::Widget::paint):
2092         * rendering/RenderBlock.cpp:
2093         (WebCore::RenderBlock::logicalRectToPhysicalRect):
2094         (WebCore::RenderBlock::selectionGaps):
2095         * rendering/RenderBox.cpp:
2096         (WebCore::RenderBox::offsetFromContainer):
2097         (WebCore::RenderBox::computeRectForRepaint):
2098         (WebCore::RenderBox::localCaretRect):
2099         * rendering/RenderDetailsMarker.cpp:
2100         (WebCore::RenderDetailsMarker::paint):
2101         * rendering/RenderInline.cpp:
2102         (WebCore::RenderInline::culledInlineVisualOverflowBoundingBox):
2103         * rendering/RenderInputSpeech.cpp:
2104         (WebCore::RenderInputSpeech::paintInputFieldSpeechButton):
2105         * rendering/RenderLayerBacking.cpp:
2106         (WebCore::paintScrollbar):
2107         (WebCore::RenderLayerBacking::paintContents):
2108         * rendering/RenderLayerCompositor.cpp:
2109         (WebCore::paintScrollbar):
2110         (WebCore::RenderLayerCompositor::paintContents):
2111         * rendering/RenderListItem.cpp:
2112         (WebCore::RenderListItem::positionListMarker):
2113         * rendering/RenderListMarker.cpp:
2114         (WebCore::RenderListMarker::paint):
2115         * rendering/RenderTableCell.cpp:
2116         (WebCore::RenderTableCell::computeRectForRepaint):
2117         * rendering/RenderTextControlSingleLine.cpp:
2118         (WebCore::RenderTextControlSingleLine::nodeAtPoint):
2119         * rendering/RenderView.cpp:
2120         (WebCore::RenderView::repaintViewRectangle):
2121
2122 2011-05-25  Levi Weintraub  <leviw@chromium.org>
2123
2124         Reviewed by Eric Seidel.
2125
2126         Switch addFocusRingRects to use IntPoint
2127         https://bugs.webkit.org/show_bug.cgi?id=60783
2128
2129         Switching addFocusRingRects to use an IntPoint representing the offset being
2130         applied instead of a pair of ints.
2131
2132         No new tests as this is only refactoring.
2133
2134         * platform/graphics/FloatSize.h:
2135         (WebCore::flooredIntPoint):
2136         * rendering/RenderBlock.cpp:
2137         (WebCore::RenderBlock::addFocusRingRects):
2138         * rendering/RenderBlock.h:
2139         * rendering/RenderBox.cpp:
2140         (WebCore::RenderBox::addFocusRingRects):
2141         * rendering/RenderBox.h:
2142         * rendering/RenderInline.cpp:
2143         (WebCore::RenderInline::addFocusRingRects):
2144         * rendering/RenderInline.h:
2145         * rendering/RenderListBox.cpp:
2146         (WebCore::RenderListBox::addFocusRingRects):
2147         * rendering/RenderListBox.h:
2148         * rendering/RenderObject.cpp:
2149         (WebCore::RenderObject::paintFocusRing):
2150         (WebCore::RenderObject::absoluteFocusRingQuads):
2151         * rendering/RenderObject.h:
2152         (WebCore::RenderObject::addFocusRingRects):
2153         * rendering/RenderTextControl.cpp:
2154         (WebCore::RenderTextControl::addFocusRingRects):
2155         * rendering/RenderTextControl.h:
2156         * rendering/RenderTextControlSingleLine.cpp:
2157         (WebCore::RenderTextControlSingleLine::addFocusRingRects):
2158         * rendering/RenderTextControlSingleLine.h:
2159         * rendering/svg/RenderSVGContainer.cpp:
2160         (WebCore::RenderSVGContainer::addFocusRingRects):
2161         * rendering/svg/RenderSVGContainer.h:
2162         * rendering/svg/RenderSVGImage.cpp:
2163         (WebCore::RenderSVGImage::addFocusRingRects):
2164         * rendering/svg/RenderSVGImage.h:
2165         * rendering/svg/RenderSVGPath.cpp:
2166         (WebCore::RenderSVGPath::addFocusRingRects):
2167         * rendering/svg/RenderSVGPath.h:
2168
2169 2011-05-25  Sheriff Bot  <webkit.review.bot@gmail.com>
2170
2171         Unreviewed, rolling out r87229.
2172         http://trac.webkit.org/changeset/87229
2173         https://bugs.webkit.org/show_bug.cgi?id=61445
2174
2175         Lots of tests crashing in
2176         CFNetwork!URLResponse::createFilenameFromResponseHeaders on
2177         Windows XP (Requested by aroben on #webkit).
2178
2179         * platform/network/ResourceResponseBase.cpp:
2180         (WebCore::ResourceResponseBase::adopt):
2181         (WebCore::ResourceResponseBase::suggestedFilename):
2182         (WebCore::ResourceResponseBase::setSuggestedFilename):
2183         (WebCore::ResourceResponseBase::httpStatusText):
2184         (WebCore::ResourceResponseBase::setHTTPStatusText):
2185         (WebCore::ResourceResponseBase::httpHeaderField):
2186         (WebCore::ResourceResponseBase::setHTTPHeaderField):
2187         (WebCore::ResourceResponseBase::httpHeaderFields):
2188         (WebCore::ResourceResponseBase::isAttachment):
2189         (WebCore::ResourceResponseBase::setLastModifiedDate):
2190         (WebCore::ResourceResponseBase::lastModifiedDate):
2191         (WebCore::ResourceResponseBase::wasCached):
2192         (WebCore::ResourceResponseBase::connectionReused):
2193         (WebCore::ResourceResponseBase::setConnectionReused):
2194         (WebCore::ResourceResponseBase::connectionID):
2195         (WebCore::ResourceResponseBase::setConnectionID):
2196         (WebCore::ResourceResponseBase::resourceLoadTiming):
2197         (WebCore::ResourceResponseBase::setResourceLoadTiming):
2198         (WebCore::ResourceResponseBase::resourceLoadInfo):
2199         (WebCore::ResourceResponseBase::setResourceLoadInfo):
2200         * platform/network/ResourceResponseBase.h:
2201         * platform/network/cf/ResourceResponse.h:
2202         (WebCore::ResourceResponse::ResourceResponse):
2203         * platform/network/cf/ResourceResponseCFNet.cpp:
2204         (WebCore::ResourceResponse::platformLazyInit):
2205         * platform/network/mac/ResourceResponseMac.mm:
2206         (WebCore::ResourceResponse::platformLazyInit):
2207
2208 2011-05-25  Igor Oliveira  <igor.oliveira@openbossa.org>
2209
2210         Reviewed by Antonio Gomes.
2211
2212         [Qt] QtWebKit crashes when dragging not loaded images
2213         https://bugs.webkit.org/show_bug.cgi?id=61314
2214
2215         Checks if nativeImageForCurrentFrame is a valid pointer.
2216
2217         Test: http/tests/misc/drag-not-loaded-image.html
2218
2219         * platform/qt/DragImageQt.cpp:
2220         (WebCore::createDragImageFromImage):
2221
2222 2011-05-25  Ryuan Choi  <ryuan.choi@samsung.com>
2223
2224         Reviewed by Xan Lopez.
2225
2226         [GTK] combobox and scrollbar are rendered small size at gtk+2.22.0
2227         https://bugs.webkit.org/show_bug.cgi?id=61436
2228
2229         Fix arguments of gdk_drawable_get_size.
2230
2231         No new tests, no behavior change.
2232
2233         * platform/gtk/GtkVersioning.c:
2234         (getGdkDrawableSize):
2235
2236 2011-05-23  Alexander Pavlov  <apavlov@chromium.org>
2237
2238         Reviewed by Yury Semikhatsky.
2239
2240         Web Inspector: extreme lagging when searching for "img[src*="
2241         https://bugs.webkit.org/show_bug.cgi?id=61282
2242
2243         No new tests, as this is a refactoring: ElementsTreeElement DOM is manipulated directly
2244         when built and search-highlighted, rather than through innerHTML.
2245
2246         * inspector/front-end/DOMSyntaxHighlighter.js:
2247         (WebInspector.DOMSyntaxHighlighter):
2248         (WebInspector.DOMSyntaxHighlighter.prototype.createSpan):
2249         * inspector/front-end/ElementsPanel.js:
2250         (WebInspector.ElementsPanel.prototype._hideSearchHighlights):
2251         * inspector/front-end/ElementsTreeOutline.js:
2252         (WebInspector.ElementsTreeElement.prototype.highlightSearchResults):
2253         (WebInspector.ElementsTreeElement.prototype.hideSearchHighlights):
2254         (WebInspector.ElementsTreeElement.prototype._updateSearchHighlight.updateEntryShow):
2255         (WebInspector.ElementsTreeElement.prototype._updateSearchHighlight.updateEntryHide):
2256         (WebInspector.ElementsTreeElement.prototype._updateSearchHighlight):
2257         (WebInspector.ElementsTreeElement.prototype._addNewAttribute):
2258         (WebInspector.ElementsTreeElement.prototype.updateTitle):
2259         (WebInspector.ElementsTreeElement.prototype._buildAttributeDOM):
2260         ():
2261         * inspector/front-end/utilities.js:
2262         ():
2263
2264 2011-05-25  Leandro Gracia Gil  <leandrogracia@chromium.org>
2265
2266         Reviewed by Tony Gentilcore.
2267
2268         Introduce HTML5 track list objects.
2269         https://bugs.webkit.org/show_bug.cgi?id=60184
2270
2271         Introduce the TrackList, MultipleTrackList and ExclusiveTrackList objects
2272         for their use in the MediaStream API and the HTML Media Element.
2273         Current spec: http://www.whatwg.org/specs/web-apps/current-work/multipage/the-iframe-element.html#tracklist
2274
2275         The Media Stream API will test this feature in the bug 56587.
2276         More tests related to the HTML Media Element may be added later.
2277
2278         * CMakeLists.txt:
2279         * CodeGenerators.pri:
2280         * DerivedSources.cpp:
2281         * DerivedSources.make:
2282         * GNUmakefile.list.am:
2283         * WebCore.gypi:
2284         * WebCore.pro:
2285         * WebCore.vcproj/WebCore.vcproj:
2286         * WebCore.xcodeproj/project.pbxproj:
2287         * bindings/js/JSEventTarget.cpp:
2288         (WebCore::toJS):
2289         * bindings/v8/V8DOMWrapper.cpp:
2290         (WebCore::V8DOMWrapper::convertEventTargetToV8Object):
2291         * dom/DOMAllInOne.cpp:
2292         * dom/EventTarget.cpp:
2293         (WebCore::EventTarget::toTrackList):
2294         (WebCore::EventTarget::toMultipleTrackList):
2295         (WebCore::EventTarget::toExclusiveTrackList):
2296         * dom/EventTarget.h:
2297         * dom/ExclusiveTrackList.cpp: Added.
2298         (WebCore::ExclusiveTrackList::create):
2299         (WebCore::ExclusiveTrackList::ExclusiveTrackList):
2300         (WebCore::ExclusiveTrackList::~ExclusiveTrackList):
2301         (WebCore::ExclusiveTrackList::clear):
2302         (WebCore::ExclusiveTrackList::select):
2303         (WebCore::ExclusiveTrackList::toExclusiveTrackList):
2304         * dom/ExclusiveTrackList.h: Added.
2305         (WebCore::ExclusiveTrackList::selectedIndex):
2306         * dom/ExclusiveTrackList.idl: Added.
2307         * dom/MultipleTrackList.cpp: Added.
2308         (WebCore::MultipleTrackList::create):
2309         (WebCore::MultipleTrackList::MultipleTrackList):
2310         (WebCore::MultipleTrackList::~MultipleTrackList):
2311         (WebCore::MultipleTrackList::clear):
2312         (WebCore::MultipleTrackList::isEnabled):
2313         (WebCore::MultipleTrackList::enable):
2314         (WebCore::MultipleTrackList::disable):
2315         (WebCore::MultipleTrackList::toMultipleTrackList):
2316         * dom/MultipleTrackList.h: Added.
2317         * dom/MultipleTrackList.idl: Added.
2318         * dom/TrackList.cpp: Added.
2319         (WebCore::Track::create):
2320         (WebCore::Track::Track):
2321         (WebCore::TrackList::create):
2322         (WebCore::TrackList::TrackList):
2323         (WebCore::TrackList::~TrackList):
2324         (WebCore::TrackList::length):
2325         (WebCore::TrackList::checkIndex):
2326         (WebCore::TrackList::getID):
2327         (WebCore::TrackList::getKind):
2328         (WebCore::TrackList::getLabel):
2329         (WebCore::TrackList::getLanguage):
2330         (WebCore::TrackList::clear):
2331         (WebCore::TrackList::postChangeEvent):
2332         (WebCore::TrackList::dispatchChangeEvent):
2333         (WebCore::TrackList::toTrackList):
2334         (WebCore::TrackList::scriptExecutionContext):
2335         (WebCore::TrackList::eventTargetData):
2336         (WebCore::TrackList::ensureEventTargetData):
2337         * dom/TrackList.h: Added.
2338         (WebCore::Track::id):
2339         (WebCore::Track::kind):
2340         (WebCore::Track::label):
2341         (WebCore::Track::language):
2342         (WebCore::TrackList::DispatchTask::create):
2343         (WebCore::TrackList::DispatchTask::performTask):
2344         (WebCore::TrackList::DispatchTask::DispatchTask):
2345         (WebCore::TrackList::refEventTarget):
2346         (WebCore::TrackList::derefEventTarget):
2347         * dom/TrackList.idl: Added.
2348
2349 2011-05-25  Keishi Hattori  <keishi@webkit.org>
2350
2351         Reviewed by Kent Tamura.
2352
2353         Move ElementWithPseudoId to separate file
2354         https://bugs.webkit.org/show_bug.cgi?id=61430
2355
2356         No new tests because no behavior changes.
2357
2358         * CMakeLists.txt: Added ElementWithPseudoId.cpp
2359         * GNUmakefile.list.am: Added ElementWithPseudoId.{h,cpp}
2360         * WebCore.gypi: Added ElementWithPseudoId.{h,cpp}
2361         * WebCore.pro: Added ElementWithPseudoId.{h,cpp}
2362         * WebCore.vcproj/WebCore.vcproj: Added ElementWithPseudoId.{h,cpp}
2363         * WebCore.xcodeproj/project.pbxproj: Added ElementWithPseudoId.{h,cpp}
2364         * html/ValidationMessage.cpp: Removed ElementWithPseudoId definition.
2365         * html/shadow/ElementWithPseudoId.cpp: Added.
2366         (WebCore::ElementWithPseudoId::shadowPseudoId):
2367         * html/shadow/ElementWithPseudoId.h: Added.
2368         (WebCore::ElementWithPseudoId::create):
2369         (WebCore::ElementWithPseudoId::ElementWithPseudoId):
2370
2371 2011-05-25  Alexis Menard  <alexis.menard@openbossa.org>
2372
2373         Reviewed by Antonio Gomes.
2374
2375         [Qt] When QWebView has a different style set on it then the scrollbars are not rendered correctly
2376         https://bugs.webkit.org/show_bug.cgi?id=34635
2377
2378         Make sure the scrollbar is properly rendered on Mac with another style than the Mac style. The code had
2379         two paths, one for Mac and one for any other styles. The problem is that on Mac you can still run the
2380         application with -style plastique for example, therefore the code used for other styles should also be
2381         used whenever the current style is not the Mac style.
2382
2383         * platform/qt/ScrollbarThemeQt.cpp:
2384         (WebCore::ScrollbarThemeQt::paint):
2385
2386 2011-05-25  Yuta Kitamura  <yutak@chromium.org>
2387
2388         Reviewed by Kent Tamura.
2389
2390         WebSocket: Use fail() when WebSocketChannel has failed
2391         https://bugs.webkit.org/show_bug.cgi?id=61353
2392
2393         An existing error message has been modified, but it is impossible
2394         to test this message in LayoutTests because it is only shown when
2395         memory allocation has failed, which is hard to reproduce reliably.
2396
2397         One new message has been added. It is covered by an existing test
2398         http/tests/websocket/tests/frame-length-overflow.html.
2399
2400         There is no other change in behavior. No new tests are added.
2401
2402         * websockets/WebSocketChannel.cpp:
2403         (WebCore::WebSocketChannel::fail):
2404         Do not close if we know the socket stream is already closed. This does not
2405         change the behavior, because SocketStreamBase does nothing if it is already
2406         closed.
2407         (WebCore::WebSocketChannel::didOpen):
2408         (WebCore::WebSocketChannel::didReceiveData):
2409         We need to set m_shouldDiscardReceivedData to true before calling fail(),
2410         so I moved the error message from appendToBuffer() to here.
2411         The error message was rephrased in order to improve readability.
2412         (WebCore::WebSocketChannel::appendToBuffer):
2413         Unnested the code.
2414         (WebCore::WebSocketChannel::processBuffer):
2415
2416 2011-05-16  Alexander Pavlov  <apavlov@chromium.org>
2417
2418         Reviewed by David Levin.
2419
2420         CSSParser: m_implicitShorthand should probably be RAII
2421         https://bugs.webkit.org/show_bug.cgi?id=51586
2422
2423         It was impossible to entirely eliminate the m_implicitShorthand manual changes
2424         due to the parseFill*() method stateful call chains.
2425
2426         No new tests, as this is a refactoring.
2427
2428         * css/CSSParser.cpp:
2429         (ImplicitScope::ImplicitScope):
2430         (ImplicitScope::~ImplicitScope):
2431         (WebCore::CSSParser::parseShorthand):
2432         (WebCore::CSSParser::parse4Values):
2433         (WebCore::CSSParser::parseBorderRadius):
2434
2435 2011-05-24  Pavel Podivilov  <podivilov@chromium.org>
2436
2437         Reviewed by Yury Semikhatsky.
2438
2439         Web Inspector: inspected page crashes when call stack is empty after live edit.
2440         https://bugs.webkit.org/show_bug.cgi?id=61364
2441
2442         * bindings/v8/ScriptDebugServer.cpp:
2443         (WebCore::ScriptDebugServer::currentCallFrame):
2444
2445 2011-05-23  Yury Semikhatsky  <yurys@chromium.org>
2446
2447         Reviewed by Adam Barth.
2448
2449         Chromium DevTools: Tab crashes with "Aw, snap!" on entering "(new Image())." in console
2450         https://bugs.webkit.org/show_bug.cgi?id=61194
2451
2452         Test: inspector/console/console-eval-syntax-error.html
2453
2454         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
2455         (WebCore::V8InjectedScriptHost::evaluateCallback): return immediately in case of syntax error
2456
2457 2011-05-25  Yuzo Fujishima  <yuzo@google.com>
2458
2459         Reviewed by Kent Tamura.
2460
2461         Fix for Bug 61352 - Refactor RenderView::{enable,disable}LayoutState call sites to use RIIA
2462         https://bugs.webkit.org/show_bug.cgi?id=61352
2463
2464         No new tests because no behavior changes.
2465
2466         * html/shadow/MediaControlElements.cpp:
2467         (WebCore::RenderMediaVolumeSliderContainer::layout):
2468         * page/FrameView.cpp:
2469         (WebCore::FrameView::layout):
2470         * rendering/RenderBlock.cpp:
2471         (WebCore::RenderBlock::repaintOverhangingFloats):
2472         (WebCore::RenderBlock::updateFirstLetter):
2473         * rendering/RenderLayer.cpp:
2474         (WebCore::RenderLayer::updateLayerPositions):
2475         (WebCore::RenderLayer::updateScrollInfoAfterLayout):
2476         * rendering/RenderListBox.cpp:
2477         (WebCore::RenderListBox::layout):
2478         * rendering/RenderListItem.cpp:
2479         (WebCore::RenderListItem::updateMarkerLocation):
2480         * rendering/RenderMedia.cpp:
2481         (WebCore::RenderMedia::layout):
2482         * rendering/RenderView.h:
2483         (WebCore::RenderView::disableLayoutState):
2484         (WebCore::RenderView::enableLayoutState):
2485         (WebCore::LayoutStateDisabler::LayoutStateDisabler):
2486         (WebCore::LayoutStateDisabler::~LayoutStateDisabler):
2487         * rendering/svg/RenderSVGRoot.cpp:
2488         (WebCore::RenderSVGRoot::layout):
2489
2490 2011-05-24  Csaba Osztrogon√°c  <ossy@webkit.org>
2491
2492         [Qt] Unreviewed typo fix after r87228.
2493
2494         * WebCore.pro:
2495
2496 2011-05-24  Keishi Hattori  <keishi@webkit.org>
2497
2498         Reviewed by Kent Tamura.
2499
2500         Disable textfield implementation of <input type=color>. Add INPUT_COLOR feature flag. Add input color sanitizer.
2501         https://bugs.webkit.org/show_bug.cgi?id=61273
2502
2503         Test: fast/forms/color/input-value-sanitization-color.html
2504
2505         * Configurations/FeatureDefines.xcconfig: Added COLOR_INPUT feature flag.
2506         * GNUmakefile.am: Added COLOR_INPUT feature flag.
2507         * features.pri: Added COLOR_INPUT feature flag.
2508         * html/ColorInputType.cpp: Wrapped with COLOR_INPUT feature flag.
2509         (WebCore::ColorInputType::isColorControl): Added.
2510         (WebCore::ColorInputType::fallbackValue): Added. Fallback value defined in spec.
2511         (WebCore::ColorInputType::sanitizeValue): Added. Sanitize value string as defined in spec.
2512         * html/ColorInputType.h: Wrapped with COLOR_INPUT feature flag.
2513         (WebCore::ColorInputType::ColorInputType): Changed to inherit BaseButtonInputType.
2514         * html/InputType.cpp:
2515         (WebCore::InputType::isColorControl): Added.
2516         * html/InputType.h:
2517
2518 2011-05-24  Steve Lacey  <sjl@chromium.org>
2519
2520         Reviewed by Eric Carlson.
2521
2522         Move chromium media controls timeline back to flexible rather than absolute
2523         layout.
2524
2525         https://bugs.webkit.org/show_bug.cgi?id=61379
2526
2527         * css/mediaControlsChromium.css:
2528         (audio::-webkit-media-controls-current-time-display, video::-webkit-media-controls-current-time-display):
2529         (audio::-webkit-media-controls-timeline, video::-webkit-media-controls-timeline):
2530
2531 2011-05-24  Fumitoshi Ukai  <ukai@chromium.org>
2532
2533         Unreviewed. Fix clang error.
2534
2535         error: initialization of pointer of type 'WebCore::MHTMLArchive *' to
2536         NULL from a constant boolean expression [-Werror,-Wbool-conversio
2537
2538         * loader/archive/mhtml/MHTMLArchive.cpp:
2539         (WebCore::MHTMLArchive::create):
2540
2541 2011-05-24  Adam Barth  <abarth@webkit.org>
2542
2543         Reviewed by Eric Seidel.
2544
2545         Add FIXME comments about removing FrameLoader::isProcessingUserGesture
2546         https://bugs.webkit.org/show_bug.cgi?id=61395
2547
2548         All the callers of the API are wrong.  They should call the more modern
2549         static member function of ScriptController instead.  I'll remove the
2550         FrameLoader function in a future patch.
2551
2552         * html/HTMLMediaElement.cpp:
2553         (WebCore::HTMLMediaElement::processingUserGesture):
2554         * rendering/RenderFileUploadControl.cpp:
2555         (WebCore::RenderFileUploadControl::click):
2556
2557 2011-05-24  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2558
2559         Unreviewed. Fix style error.
2560
2561         * platform/efl/WidgetEfl.cpp:
2562         (WebCore::WidgetPrivate::WidgetPrivate):
2563
2564 2011-05-24  Greg Simon  <gregsimon@chromium.org>
2565
2566         Reviewed by Dimitri Glazkov.
2567
2568         Control Indexeddb backends from LayoutTestController
2569         https://bugs.webkit.org/show_bug.cgi?id=61000
2570
2571         Test: storage/indexeddb/migrate-basics.html
2572
2573         * storage/IDBBackingStore.h:
2574         * storage/IDBFactoryBackendImpl.cpp:
2575         (WebCore::IDBFactoryBackendImpl::IDBFactoryBackendImpl):
2576         (WebCore::IDBFactoryBackendImpl::open):
2577         (WebCore::IDBFactoryBackendImpl::setEnableMigration):
2578         (WebCore::IDBFactoryBackendImpl::migrate):
2579         * storage/IDBFactoryBackendImpl.h:
2580         * storage/IDBFactoryBackendInterface.h:
2581         * storage/IDBLevelDBBackingStore.cpp:
2582         (WebCore::IDBLevelDBBackingStore::backingStoreExists):
2583         * storage/IDBLevelDBBackingStore.h:
2584         (WebCore::IDBLevelDBBackingStore::backingStoreType):
2585         * storage/IDBSQLiteBackingStore.cpp:
2586         (WebCore::IDBSQLiteBackingStore::backingStoreExists):
2587         * storage/IDBSQLiteBackingStore.h:
2588         (WebCore::IDBSQLiteBackingStore::backingStoreType):
2589
2590 2011-05-24  Leo Yang  <leo.yang@torchmobile.com.cn>
2591
2592         Reviewed by Ryosuke Niwa.
2593
2594         [SVG] Assertion failure by dragging text between input fields inside <foreignObject>s
2595         https://bugs.webkit.org/show_bug.cgi?id=60692
2596
2597         Add NULL check of 'holder' in WebCore::ReplacementFragment::ReplacementFragment()
2598         before call VisibleSelection::selectionFromContentsOfNode() to prevent crashing.
2599
2600         Test: editing/pasteboard/drag-drop-input-in-svg.svg
2601
2602         * editing/ReplaceSelectionCommand.cpp:
2603         (WebCore::ReplacementFragment::ReplacementFragment):
2604
2605 2011-05-24  Andy Estes  <aestes@apple.com>
2606
2607         Reviewed by Geoffrey Garen.
2608
2609         REGRESSION (r70748): WebKit cannot play QuickTime movies on Mac OS X Wiki Server pages
2610         https://bugs.webkit.org/show_bug.cgi?id=61229
2611
2612         This site-specific hack maintains compatibility with Mac OS X Wiki Server,
2613         which embeds QuickTime movies using an object tag containing QuickTime's
2614         ActiveX classid. Treat this classid as valid only if OS X Server's unique
2615         'generator' meta tag is present. Only apply this quirk if there is no
2616         fallback content, which ensures the quirk will disable itself if Wiki
2617         Server is updated to generate an alternate embed tag as fallback content.
2618
2619         * html/HTMLObjectElement.cpp:
2620         (WebCore::HTMLObjectElement::shouldAllowQuickTimeClassIdQuirk): Return
2621         true if site-specific quirks are enabled, the object element has no
2622         fallback content, the classid attribute matches QuickTime's classid and
2623         the document has a 'generator' meta tag matching Mac OS X Web Services
2624         Server's unique generator string.
2625         (WebCore::HTMLObjectElement::hasValidClassId): Call
2626         shouldAllowQuickTimeClassIdQuirk()
2627         * html/HTMLObjectElement.h:
2628
2629 2011-05-24  Nate Chapin  <japhet@chromium.org>
2630
2631         Reviewed by Adam Barth.
2632
2633         Change CachedResources to take a ResourceRequest instead of
2634         a url in their constructors and provide a very minimal set of
2635         cases for avoiding reusing a CachedResource. The ResourceRequest
2636         part of this change requires pushing responsibility
2637         for calling Document::completeURL() to the caller, instead of
2638         CachedResourceLoader, since ResourceRequest ASSERTs if it
2639         is constructed with an invalid url.
2640
2641         https://bugs.webkit.org/show_bug.cgi?id=61318
2642
2643         Refactor, no new tests.
2644
2645         * css/CSSFontSelector.cpp:
2646         (WebCore::CSSFontSelector::addFontFaceRule):
2647         * css/CSSImageValue.cpp:
2648         (WebCore::CSSImageValue::cachedImage):
2649         * css/CSSImportRule.cpp:
2650         (WebCore::CSSImportRule::insertedIntoParent):
2651         * dom/ProcessingInstruction.cpp:
2652         (WebCore::ProcessingInstruction::checkStyleSheet):
2653         * dom/ScriptElement.cpp:
2654         (WebCore::ScriptElement::requestScript):
2655         * html/HTMLLinkElement.cpp:
2656         (WebCore::HTMLLinkElement::process):
2657         * loader/ImageLoader.cpp:
2658         (WebCore::ImageLoader::updateFromElement):
2659         * loader/cache/CachedCSSStyleSheet.cpp:
2660         (WebCore::CachedCSSStyleSheet::CachedCSSStyleSheet):
2661         (WebCore::CachedCSSStyleSheet::didAddClient):
2662         (WebCore::CachedCSSStyleSheet::checkNotify):
2663         * loader/cache/CachedCSSStyleSheet.h:
2664         * loader/cache/CachedFont.cpp:
2665         (WebCore::CachedFont::CachedFont):
2666         * loader/cache/CachedFont.h:
2667         * loader/cache/CachedImage.cpp:
2668         (WebCore::CachedImage::CachedImage):
2669         (WebCore::CachedImage::checkShouldPaintBrokenImage):
2670         * loader/cache/CachedImage.h:
2671         * loader/cache/CachedResource.cpp:
2672         (WebCore::CachedResource::CachedResource):
2673         (WebCore::reuseRequest):
2674         (WebCore::CachedResource::allowReuseOfRequest):
2675         (WebCore::CachedResource::removeClient):
2676         (WebCore::CachedResource::canUseCacheValidator):
2677         * loader/cache/CachedResource.h:
2678         (WebCore::CachedResource::resourceRequest):
2679         (WebCore::CachedResource::url):
2680         * loader/cache/CachedResourceLoader.cpp:
2681         * loader/cache/CachedResourceLoader.h:
2682         * loader/cache/CachedResourceRequest.cpp:
2683         (WebCore::CachedResourceRequest::load):
2684         * loader/cache/CachedScript.cpp:
2685         (WebCore::CachedScript::CachedScript):
2686         * loader/cache/CachedScript.h:
2687         * loader/cache/CachedXSLStyleSheet.cpp:
2688         (WebCore::CachedXSLStyleSheet::CachedXSLStyleSheet):
2689         (WebCore::CachedXSLStyleSheet::didAddClient):
2690         (WebCore::CachedXSLStyleSheet::checkNotify):
2691         * loader/cache/CachedXSLStyleSheet.h:
2692         * svg/SVGFEImageElement.cpp:
2693         (WebCore::SVGFEImageElement::requestImageResource):
2694         * svg/SVGFontFaceUriElement.cpp:
2695         (WebCore::SVGFontFaceUriElement::loadFont):
2696         * xml/XSLImportRule.cpp:
2697         (WebCore::XSLImportRule::loadSheet):
2698
2699 2011-05-24  Kent Tamura  <tkent@chromium.org>
2700
2701         Reviewed by Dimitri Glazkov.
2702
2703         Use Element::shadowPseudoId() for text field decoration elements
2704         https://bugs.webkit.org/show_bug.cgi?id=61351
2705
2706         No new tests. Covered by existing tests.
2707
2708         * css/CSSSelector.cpp: Remove support for the following static pseudo selectors:
2709           - -webkit-inner-spin-button
2710           - -webkit-input-speech-button
2711           - -webkit-outer-spin-button
2712           - -webkit-search-cancel-button
2713           - -webkit-search-decoration
2714           - -webkit-search-results-button
2715           - -webkit-search-results-decoration
2716         (WebCore::CSSSelector::pseudoId):
2717         (WebCore::nameToPseudoTypeMap):
2718         (WebCore::CSSSelector::extractPseudoType):
2719         * css/CSSSelector.h: ditto.
2720         * css/CSSStyleSelector.cpp:
2721         (WebCore::CSSStyleSelector::matchRules):
2722           Store shadowPseudoId() result in a local variable because
2723           SearchFieldResultsButtonElement::shadowPseudoId() is a little expensive.
2724         * html/shadow/TextControlInnerElements.cpp:
2725          Override Element::shadowPseudoId() instead of Element::styleForRenderer().
2726         (WebCore::SearchFieldResultsButtonElement::shadowPseudoId):
2727         (WebCore::SearchFieldCancelButtonElement::shadowPseudoId):
2728         (WebCore::SpinButtonElement::shadowPseudoId):
2729         (WebCore::InputFieldSpeechButtonElement::shadowPseudoId):
2730         * html/shadow/TextControlInnerElements.h: Update declarations.
2731         * rendering/RenderTextControlSingleLine.cpp: Remove createFooStyle() functions.
2732         * rendering/RenderTextControlSingleLine.h: ditto.
2733         * rendering/style/RenderStyleConstants.h: Remove unused pseudo IDs.
2734
2735 2011-05-24  Dimitri Glazkov  <dglazkov@chromium.org>
2736
2737         Sorted WebCore.xcodeproj again.
2738
2739         * WebCore.xcodeproj/project.pbxproj: Ran sort-XCode-project-file.
2740
2741 2011-05-24  Stephanie Lewis  <slewis@apple.com>
2742
2743         Reviewed by Geoff Garen.
2744
2745         https://bugs.webkit.org/show_bug.cgi?id=61345
2746         part of <rdar://problem/8675177>
2747         Don't initialize ResourceResponse.m_suggestedFilename until we want to use it.  Initializing it requires reading in and parsing a plist.  
2748         Add new initialization state CommonAndUncommonFields to ResourceResponse.  This will be for all the header fields.
2749         Move suggestedFilename initialization to AllFields so it is never initialized unless we ask for it. 
2750         Add "Content-Type" to common headers since it is looked for by every CSS sheet load.
2751
2752         No new tests because functionality has not changed.
2753
2754         * platform/network/ResourceResponseBase.cpp:
2755         (WebCore::ResourceResponseBase::adopt):
2756         (WebCore::ResourceResponseBase::suggestedFilename):
2757         (WebCore::ResourceResponseBase::setSuggestedFilename):
2758         (WebCore::ResourceResponseBase::httpStatusText):
2759         (WebCore::ResourceResponseBase::setHTTPStatusText):
2760         (WebCore::ResourceResponseBase::httpHeaderField):
2761         (WebCore::ResourceResponseBase::setHTTPHeaderField):
2762         (WebCore::ResourceResponseBase::httpHeaderFields):
2763         (WebCore::ResourceResponseBase::isAttachment):
2764         (WebCore::ResourceResponseBase::setLastModifiedDate):
2765         (WebCore::ResourceResponseBase::lastModifiedDate):
2766         (WebCore::ResourceResponseBase::wasCached):
2767         (WebCore::ResourceResponseBase::connectionReused):
2768         (WebCore::ResourceResponseBase::setConnectionReused):
2769         (WebCore::ResourceResponseBase::connectionID):
2770         (WebCore::ResourceResponseBase::setConnectionID):
2771         (WebCore::ResourceResponseBase::resourceLoadTiming):
2772         (WebCore::ResourceResponseBase::setResourceLoadTiming):
2773         (WebCore::ResourceResponseBase::resourceLoadInfo):
2774         (WebCore::ResourceResponseBase::setResourceLoadInfo):
2775         * platform/network/ResourceResponseBase.h:
2776         * platform/network/cf/ResourceResponse.h:
2777         (WebCore::ResourceResponse::ResourceResponse):
2778         * platform/network/cf/ResourceResponseCFNet.cpp:
2779         (WebCore::ResourceResponse::platformLazyInit):
2780         * platform/network/mac/ResourceResponseMac.mm:
2781         (WebCore::ResourceResponse::platformLazyInit):
2782
2783 2011-05-24  Michael Saboff  <msaboff@apple.com>
2784
2785         Reviewed by Geoffrey Garen.
2786
2787         Improve handling in WebCore of low memory situations
2788         https://bugs.webkit.org/show_bug.cgi?id=61222
2789
2790         Added new class, MemoryPressureHandler, to platform to respond to low
2791         system memory events. Added Mac specific implementation that reduces the
2792         page cache, NSURL cache, WebCore cache by half their current usage
2793         and then garbage collects.  This can allow Safari to continue operating
2794         in a low memory situation with minimal paging.
2795         Split up prune operations in MemoryCache to allow for pruning to a
2796         specific actual size to support this change.
2797
2798         No tests added as the functionality of WebKit wasn't changed.
2799
2800         * GNUmakefile.list.am:
2801         * WebCore.exp.in:
2802         * WebCore.gypi:
2803         * WebCore.pro:
2804         * WebCore.vcproj/WebCore.vcproj:
2805         * WebCore.xcodeproj/project.pbxproj:
2806         * loader/cache/MemoryCache.cpp:
2807         (WebCore::MemoryCache::pruneLiveResources):
2808         (WebCore::MemoryCache::forcePruneLiveResources):
2809         (WebCore::MemoryCache::pruneLiveResourcesToTarget):
2810         (WebCore::MemoryCache::pruneDeadResources):
2811         (WebCore::MemoryCache::forcePruneDeadResources):
2812         (WebCore::MemoryCache::pruneDeadResourcesToTarget):
2813         * loader/cache/MemoryCache.h:
2814         (WebCore::MemoryCache::forcePrune):
2815         * platform/MemoryPressureHandler.cpp: Added.
2816         (WebCore::memoryPressureHandler):
2817         (WebCore::MemoryPressureHandler::MemoryPressureHandler):
2818         (WebCore::MemoryPressureHandler::install):
2819         (WebCore::MemoryPressureHandler::respondToMemoryPressure):
2820         * platform/MemoryPressureHandler.h: Added.
2821         * platform/mac/MemoryPressureHandler.mm: Added.
2822         (WebCore::MemoryPressureHandler::install):
2823         (WebCore::MemoryPressureHandler::respondToMemoryPressure):
2824
2825 2011-05-24  Kent Tamura  <tkent@chromium.org>
2826
2827         Reviewed by Dimitri Glazkov.
2828
2829         Node::shadowAncestorNode() and shadowTreeRootNode() should be const.
2830         https://bugs.webkit.org/show_bug.cgi?id=61398
2831
2832         shadowAncestorNode() and shadowTreeRootNode() should be const
2833         though they can return 'this' pointer.
2834
2835         No new tests. This doesn't change any visible behavior.
2836
2837         * dom/Node.cpp:
2838         (WebCore::Node::shadowAncestorNode): Make this const.
2839         (WebCore::Node::shadowTreeRootNode): ditto.
2840         * dom/Node.h: Update declarations.
2841         * html/shadow/TextControlInnerElements.h:
2842         (WebCore::SpinButtonElement::isEnabledFormControl): Need no const_cast<>.
2843         (WebCore::SpinButtonElement::isReadOnlyFormControl): ditto.
2844
2845 2011-05-24  James Simonsen  <simonjam@chromium.org>
2846
2847         Reviewed by Eric Seidel.
2848
2849         ASSERT_NOT_REACHED reached with broken ideograph and system fallback
2850         https://bugs.webkit.org/show_bug.cgi?id=53528
2851
2852         Test: fast/text/justify-ideograph-vertical.html (on chromium linux)
2853
2854         * platform/graphics/FontFastPath.cpp:
2855         (WebCore::Font::glyphDataForCharacter): Identify and handle broken ideographs as any other variant.
2856         * platform/graphics/SimpleFontData.h:
2857         (WebCore::SimpleFontData::variantFontData): Added BrokenIdeographVariant.
2858
2859 2011-05-24  Syed Idris Shah  <syed.idris-shah@nokia.com>
2860
2861         Reviewed by Andreas Kling.
2862
2863         [Qt] fast/canvas/webgl/gl-uniform-arrays.html failing for Qt on Linux
2864         https://bugs.webkit.org/show_bug.cgi?id=60377 
2865
2866         LayoutTests/fast/canvas/webgl/gl-uniform-arrays.html
2867
2868         We do not need assert for the useProgram as program can be null.
2869
2870         * platform/graphics/qt/GraphicsContext3DQt.cpp:
2871         (WebCore::GraphicsContext3D::useProgram): Program can be null. Removing assert.
2872
2873 2011-05-24  Ryosuke Niwa  <rniwa@webkit.org>
2874
2875         Reviewed by Darin Adler.
2876
2877         Undo gets broken in contenteditable area when a text field's value is set by script
2878         https://bugs.webkit.org/show_bug.cgi?id=61340
2879
2880         The bug was caused by RenderTextControl::setInnerTextValue's clearing undo stack by
2881         calling clearUndoRedoOperations whenever script sets new value to input or textarea.
2882
2883         Fixed the bug by removing the offending call to clearUndoRedoOperations. While this call
2884         was added by r15565 to fix a crash, SimpleEditCommands have since become much more robust
2885         and the test added by r15565 (fast/forms/text-field-setvalue-crash.html) still passes.
2886
2887         Test: editing/undo/undo-after-setting-value.html
2888
2889         * rendering/RenderTextControl.cpp:
2890         (WebCore::RenderTextControl::setInnerTextValue):
2891
2892 2011-05-24  Dan Bernstein  <mitz@apple.com>
2893
2894         Reviewed by Dave Hyatt.
2895
2896         Move code to discover if a CTFont has vertical glyphs out of SimpleFontData::platformInit()
2897         https://bugs.webkit.org/show_bug.cgi?id=61392
2898
2899         * platform/graphics/mac/SimpleFontDataMac.mm:
2900         (WebCore::fontHasVerticalGlyphs): Moved code here...
2901         (WebCore::SimpleFontData::platformInit): ...from here.
2902
2903 2011-05-24  Kenneth Russell  <kbr@google.com>
2904
2905         Reviewed by James Robinson.
2906
2907         Implement Float64Array
2908         https://bugs.webkit.org/show_bug.cgi?id=39144
2909
2910         Implemented Float64Array based on the existing Float32Array sources.
2911         Built and tested in Chromium on Linux and Mac OS X and Safari on Mac OS X.
2912
2913         * CMakeLists.txt:
2914         * CodeGenerators.pri:
2915         * DerivedSources.cpp:
2916         * DerivedSources.make:
2917         * GNUmakefile.list.am:
2918         * UseJSC.cmake:
2919         * WebCore.gypi:
2920         * WebCore.pro:
2921         * WebCore.vcproj/WebCore.vcproj:
2922         * WebCore.xcodeproj/project.pbxproj:
2923         * bindings/js/JSBindingsAllInOne.cpp:
2924         * bindings/js/JSDOMWindowCustom.cpp:
2925         (WebCore::JSDOMWindow::float64Array):
2926         * bindings/js/JSFloat64ArrayCustom.cpp: Added.
2927         (WebCore::JSFloat64Array::indexSetter):
2928         (WebCore::toJS):
2929         (WebCore::JSFloat64Array::set):
2930         (WebCore::JSFloat64ArrayConstructor::constructJSFloat64Array):
2931         * bindings/v8/custom/V8Float64ArrayCustom.cpp: Added.
2932         (WebCore::V8Float64Array::constructorCallback):
2933         (WebCore::V8Float64Array::setCallback):
2934         (WebCore::toV8):
2935         * html/canvas/ArrayBufferView.h:
2936         (WebCore::ArrayBufferView::isDoubleArray):
2937         * html/canvas/Float64Array.cpp: Added.
2938         (WebCore::Float64Array::create):
2939         (WebCore::Float64Array::Float64Array):
2940         (WebCore::Float64Array::subarray):
2941         * html/canvas/Float64Array.h: Added.
2942         (WebCore::Float64Array::set):
2943         (WebCore::Float64Array::item):
2944         (WebCore::Float64Array::isDoubleArray):
2945         * html/canvas/Float64Array.idl: Added.
2946         * page/DOMWindow.idl:
2947         * workers/WorkerContext.idl:
2948
2949 2011-05-24  Simon Fraser  <simon.fraser@apple.com>
2950
2951         Reviewed by Chris Marrin.
2952
2953         Add ability to set compositing layer bounds origin
2954         https://bugs.webkit.org/show_bug.cgi?id=61381
2955
2956         On Core Animation layers, the origin of the bounds
2957         rectangle affects where layer content is rendered, as well
2958         as the offset of sublayers. Currently we always set the
2959         bounds offset to a zero point, but may need to make use
2960         of the bounds offset in future, so expose it via GraphicsLayer.
2961
2962         * platform/graphics/GraphicsLayer.h:
2963         (WebCore::GraphicsLayer::boundsOrigin):
2964         (WebCore::GraphicsLayer::setBoundsOrigin):
2965         * platform/graphics/ca/GraphicsLayerCA.cpp:
2966         (WebCore::GraphicsLayerCA::setSize):
2967         (WebCore::GraphicsLayerCA::setBoundsOrigin):
2968         (WebCore::GraphicsLayerCA::setAllowTiledLayer):
2969         (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
2970         (WebCore::GraphicsLayerCA::updateBounds):
2971         (WebCore::GraphicsLayerCA::ensureStructuralLayer):
2972         (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
2973         * platform/graphics/ca/GraphicsLayerCA.h:
2974
2975 2011-05-24  Leandro Pereira  <leandro@profusion.mobi>
2976
2977         [EFL] Build fix.
2978
2979         * CMakeLists.txt: Also build platform/network/ContentTypeParser.cpp,
2980         added by r86289.
2981
2982 2011-05-24  Leandro Pereira  <leandro@profusion.mobi>
2983
2984         [EFL] Build fix.
2985
2986         * bridge/runtime_root.cpp: Include <heap/Weak.h> instead of
2987         <JavaScriptCore/Weak.h>.
2988
2989 2011-05-24  Jay Civelli  <jcivelli@chromium.org>
2990
2991         Reviewed by Adam Barth.
2992
2993         Adding MHTML reading support. That required some basic MIME header parsing.
2994         Modified DocumentLoader to keep a reference to the currently Archive loaded,
2995         so we can have different policies for loading subresources depending on the
2996         archive type.
2997         https://bugs.webkit.org/show_bug.cgi?id=7168
2998
2999         * CMakeLists.txt:
3000         * Configurations/FeatureDefines.xcconfig:
3001         * GNUmakefile.am:
3002         * GNUmakefile.list.am:
3003         * WebCore.gyp/WebCore.gyp:
3004         * WebCore.gypi:
3005         * WebCore.pro:
3006         * WebCore.vcproj/WebCore.vcproj:
3007         * WebCore.xcodeproj/project.pbxproj:
3008         * features.pri:
3009         * loader/DocumentLoader.cpp:
3010         (WebCore::DocumentLoader::commitLoad):
3011         (WebCore::DocumentLoader::setupForReplaceByMIMEType):
3012         (WebCore::DocumentLoader::popArchiveForSubframe):
3013         (WebCore::DocumentLoader::scheduleArchiveLoad):
3014         * loader/DocumentLoader.h:
3015         * loader/FrameLoader.cpp:
3016         (WebCore::FrameLoader::loadURLIntoChildFrame):
3017         (WebCore::FrameLoader::loadArchive):
3018         (WebCore::FrameLoader::stopAllLoaders):
3019         (WebCore::FrameLoader::finishedLoadingDocument):
3020         * loader/FrameLoader.h:
3021         (WebCore::FrameLoader::archive):
3022         * loader/MainResourceLoader.cpp:
3023         (WebCore::MainResourceLoader::continueAfterContentPolicy):
3024         * loader/ResourceLoader.cpp:
3025         (WebCore::ResourceLoader::start):
3026         * loader/archive/Archive.cpp: Added.
3027         * loader/archive/Archive.h:
3028         (WebCore::Archive::mainResource):
3029         * loader/archive/ArchiveFactory.cpp:
3030         (WebCore::archiveFactoryCreate):
3031         (WebCore::archiveMIMETypes):
3032         (WebCore::ArchiveFactory::create):
3033         (WebCore::ArchiveFactory::registerKnownArchiveMIMETypes):
3034         * loader/archive/ArchiveFactory.h:
3035         * loader/archive/ArchiveResourceCollection.cpp:
3036         (WebCore::ArchiveResourceCollection::addAllResources):
3037         (WebCore::ArchiveResourceCollection::popSubframeArchive):
3038         * loader/archive/ArchiveResourceCollection.h:
3039         * loader/archive/cf/LegacyWebArchive.cpp:
3040         (WebCore::LegacyWebArchive::create):
3041         (WebCore::LegacyWebArchive::type):
3042         * loader/archive/cf/LegacyWebArchive.h:
3043         * loader/archive/mhtml/MHTMLArchive.cpp: Added.
3044         * loader/archive/mhtml/MHTMLArchive.h: Added.
3045         * loader/archive/mhtml/MHTMLParser.cpp: Added.
3046         * loader/archive/mhtml/MHTMLParser.h: Added.
3047         * platform/MIMETypeRegistry.cpp:
3048         (WebCore::initializeSupportedNonImageMimeTypes):
3049         * platform/mac/PasteboardMac.mm:
3050         (WebCore::Pasteboard::documentFragment):
3051         * platform/network/MIMEHeader.cpp: Added.
3052         * platform/network/MIMEHeader.h: Added.
3053
3054 2011-05-24  Geoffrey Garen  <ggaren@apple.com>
3055
3056         Try to fix some builds: #include Weak.h for Weak<T>.
3057
3058         * bridge/runtime_root.h:
3059
3060 2011-05-24  Sam Weinig  <sam@webkit.org>
3061
3062         Reviewed by Beth Dakin.
3063
3064         Can't scroll scaled page that has overflow:hidden on its root
3065         <rdar://problem/9029189>
3066         https://bugs.webkit.org/show_bug.cgi?id=61339
3067
3068         Test: fast/events/scroll-in-scaled-page-with-overflow-hidden.html
3069
3070         * page/FrameView.cpp:
3071         (WebCore::FrameView::applyOverflowToViewport):
3072         Scrollbars should be enabled for the viewport when scaled, even if overflow:hidden
3073         is specified.
3074
3075 2011-05-24  Adam Roben  <aroben@apple.com>
3076
3077         Leopard build fix
3078
3079         * bridge/runtime_root.cpp: Added a missing #include.
3080
3081 2011-05-24  Jian Li  <jianli@chromium.org>
3082
3083         Reviewed by Kenneth Russell.
3084
3085         Make start parameter of Blob.slice optional.
3086         https://bugs.webkit.org/show_bug.cgi?id=59628
3087
3088         The start parameter should be optional per the latest FILE API
3089         spec: http://dev.w3.org/2006/webapi/FileAPI/#dfn-Blob.
3090
3091         * fileapi/Blob.h:
3092         * fileapi/Blob.idl: Make start parameter optional.
3093
3094 2011-05-24  Adam Roben  <aroben@apple.com>
3095
3096         Invalidate RuntimeObjects when they are finalized
3097
3098         This will cause the underlying NPObject to be released at finalization time, rather than at
3099         destruction time (which is unpredictable and could occur after the plugin has been
3100         unloaded).
3101
3102         Test: plugins/npobject-js-wrapper-destroyed-after-plugin-unload.html
3103
3104         Fixes <http://webkit.org/b/61317> <rdar://problem/9489829> Crash in _NPN_DeallocateObject
3105         when reloading yahoo.com webarchive in WebKit1
3106
3107         Reviewed by Oliver Hunt.
3108
3109         * bridge/runtime_object.cpp:
3110         (JSC::Bindings::RuntimeObject::~RuntimeObject): Assert that we've already been invalidated.
3111
3112         * bridge/runtime_root.cpp:
3113         (JSC::Bindings::RootObject::invalidate):
3114         (JSC::Bindings::RootObject::addRuntimeObject):
3115         Updated for m_runtimeObjects type change.
3116
3117         (JSC::Bindings::RootObject::finalize): Added. Invalidates the RuntimeObject and removes it
3118         from the map.
3119
3120         * bridge/runtime_root.h: Now inherits from WeakHandleOwner.
3121         Changed m_runtimeObjects from a WeakGCMap to a HashMap of JSC::Weak objects so that we will
3122         be notified when the RuntimeObjects are finalized.
3123
3124 2011-05-24  Mike Reed  <reed@google.com>
3125
3126         Reviewed by Kenneth Russell.
3127
3128         skia: fix stroking of zero-height rectangles
3129         https://bugs.webkit.org/show_bug.cgi?id=61284
3130
3131         Tests: canvas/philip/tests/2d.line.miter.lineedge.html
3132                canvas/philip/tests/2d.strokeRect.zero.4.html
3133
3134         * platform/graphics/skia/GraphicsContextSkia.cpp:
3135         (WebCore::GraphicsContext::strokeRect):
3136
3137 2011-05-24  Zan Dobersek  <zandobersek@gmail.com> and Philippe Normand  <pnormand@igalia.com>
3138
3139         Reviewed by Kenneth Russell.
3140
3141         Enable FloatArray usage outside WebGL guards
3142         https://bugs.webkit.org/show_bug.cgi?id=61356
3143
3144         * webaudio/AudioBuffer.cpp:
3145         * webaudio/AudioBuffer.idl:
3146         * webaudio/RealtimeAnalyser.cpp:
3147         * webaudio/RealtimeAnalyser.h:
3148         * webaudio/RealtimeAnalyserNode.h:
3149         * webaudio/RealtimeAnalyserNode.idl:
3150
3151 2011-05-24  Adam Klein  <adamk@chromium.org>
3152
3153         Unreviewed, rolling out r87145.
3154         http://trac.webkit.org/changeset/87145
3155         https://bugs.webkit.org/show_bug.cgi?id=61194
3156
3157         Regression in LayoutTests/inspector/debugger/scripts-panel.html on Chromium Win & Linux.
3158
3159         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
3160         (WebCore::V8InjectedScriptHost::evaluateCallback):
3161
3162 2011-05-24  Matthew Delaney  <mdelaney@apple.com>
3163
3164         Reviewed by Simon Fraser.
3165
3166         Clamp coordinates to integers for canvas create/getImageData routines
3167         https://bugs.webkit.org/show_bug.cgi?id=61135
3168
3169         Test: fast/canvas/canvas-getImageData-largeNonintegralDimensions.html
3170
3171         * html/HTMLCanvasElement.cpp:
3172         (WebCore::HTMLCanvasElement::convertLogicalToDevice): clamp to ints
3173         * html/canvas/CanvasRenderingContext2D.cpp:
3174         (WebCore::CanvasRenderingContext2D::createImageData):
3175         (WebCore::CanvasRenderingContext2D::getImageData):
3176         * platform/graphics/cg/ImageBufferDataCG.cpp:
3177         (WebCore::ImageBufferData::getData):
3178
3179 2011-05-24  Robin Dunn  <robin@alldunn.com>
3180
3181         Reviewed by Kevin Ollivier.
3182
3183         [wx] Make sure x and y adjustments are applied to all operations, and fix the calculations
3184         for the height and width checks to take into account x and y offsets.
3185         
3186         https://bugs.webkit.org/show_bug.cgi?id=61367
3187
3188         * platform/graphics/wx/ImageWx.cpp:
3189         (WebCore::Image::drawPattern):
3190
3191 2011-05-24  Tony Chang  <tony@chromium.org>
3192
3193         Reviewed by James Robinson.
3194
3195         fix render overflow computation for input type=range
3196         https://bugs.webkit.org/show_bug.cgi?id=61132
3197
3198         Test: fast/forms/slider-hit-testing.html
3199
3200         We need to clear m_overflow otherwise we use the first
3201         size of the slider for hit testing (i.e., changes to the size
3202         cause problems).  This only shows up if the thumb isn't contained
3203         in the bounds of the slider.  Making the range have a smaller height
3204         than the thumb shows the bug.
3205
3206         * rendering/RenderSlider.cpp:
3207         (WebCore::RenderSlider::layout): Clear the overflow during layout
3208             so we re-compute the overflow based on the current size of the
3209             slider.
3210
3211 2011-05-24  Alok Priyadarshi  <alokp@chromium.org>
3212
3213         Reviewed by James Robinson.
3214
3215         Enable skia gpu rendering for content layers
3216         https://bugs.webkit.org/show_bug.cgi?id=56749
3217
3218         This patch adds gpu accelerated rendering for content and root layers.
3219         Layer textures are updated in two stages:
3220         1. Paint: The non-accelerated path paints the layer contents into a bitmap.
3221                   The accelerated path paints into an SkPicture, which is essentially a display list.
3222         2. Upload: The non-accelerated path uploads the pixels obtained in the first stage to a texture.
3223                    The accelerated path renders the picture directly into the texture.
3224
3225         The accelerated path can be enabled by --enable-accelerated-drawing command-line flag in chromium.
3226         Note that this patch does not accelerate the CG path on mac. We have two options here - use skia or accelrate CG path.
3227         Any bugs should be caught by layout tests.
3228
3229         * platform/graphics/chromium/ContentLayerChromium.cpp:
3230         (WebCore::ContentLayerChromium::createTextureUpdater):
3231         * platform/graphics/chromium/LayerRendererChromium.cpp:
3232         (WebCore::LayerRendererChromium::create):
3233         (WebCore::LayerRendererChromium::LayerRendererChromium):
3234         (WebCore::LayerRendererChromium::skiaContext):
3235         (WebCore::LayerRendererChromium::updateAndDrawLayers):
3236         (WebCore::LayerRendererChromium::createRootLayerTextureUpdater):
3237         * platform/graphics/chromium/LayerRendererChromium.h:
3238         (WebCore::LayerRendererChromium::acceleratedDrawing):
3239         * platform/graphics/chromium/LayerTextureUpdaterCanvas.cpp:
3240         (WebCore::LayerTextureUpdaterSkPicture::LayerTextureUpdaterSkPicture):
3241         (WebCore::LayerTextureUpdaterSkPicture::~LayerTextureUpdaterSkPicture):
3242         (WebCore::LayerTextureUpdaterSkPicture::prepareToUpdate):
3243         (WebCore::LayerTextureUpdaterSkPicture::updateTextureRect):
3244         (WebCore::LayerTextureUpdaterSkPicture::deleteFrameBuffer):
3245         (WebCore::LayerTextureUpdaterSkPicture::createFrameBuffer):
3246         (WebCore::LayerTextureUpdaterSkPicture::clearFrameBuffer):
3247         * platform/graphics/chromium/LayerTextureUpdaterCanvas.h:
3248         (WebCore::LayerTextureUpdaterSkPicture::orientation):
3249         * platform/graphics/chromium/LayerTilerChromium.cpp:
3250         (WebCore::LayerTilerChromium::updateRect):
3251         (WebCore::LayerTilerChromium::draw):
3252
3253 2011-05-24  Pavel Podivilov  <podivilov@chromium.org>
3254
3255         Reviewed by Yury Semikhatsky.
3256
3257         Web Inspector: display keyboard shortcuts in scripts panel sidebar buttons tooltip text.
3258         https://bugs.webkit.org/show_bug.cgi?id=61358
3259
3260         * English.lproj/localizedStrings.js:
3261         * inspector/front-end/CallStackSidebarPane.js:
3262         (WebInspector.CallStackSidebarPane.prototype._selectedPlacardByIndex):
3263         (WebInspector.CallStackSidebarPane.prototype.registerShortcuts):
3264         * inspector/front-end/Panel.js:
3265         (WebInspector.Panel.prototype.registerShortcut):
3266         * inspector/front-end/ScriptsPanel.js:
3267         (WebInspector.ScriptsPanel):
3268         (WebInspector.ScriptsPanel.prototype._createSidebarButtons):
3269         (WebInspector.ScriptsPanel.prototype._createSidebarButtonAndRegisterShortcuts):
3270
3271 2011-05-24  Philippe Normand  <pnormand@igalia.com>
3272
3273         Reviewed by Andres Kling.
3274
3275         JSAudioContextCustom doesn't encode errors
3276         https://bugs.webkit.org/show_bug.cgi?id=61357
3277
3278         Fix AudioContext return values
3279
3280         * bindings/js/JSAudioContextCustom.cpp:
3281         (WebCore::JSAudioContextConstructor::constructJSAudioContext):
3282
3283 2011-05-24  Rob Buis  <rbuis@rim.com>
3284
3285         Rubber-stamped by Dirk Schulze.
3286
3287         Remove requiresLayer inlines, already provided by RenderSVGModelObject.
3288
3289         * rendering/svg/RenderSVGHiddenContainer.h:
3290         (WebCore::RenderSVGHiddenContainer::isSVGHiddenContainer):
3291         * rendering/svg/RenderSVGImage.h:
3292
3293 2011-05-24  Nikolas Zimmermann  <nzimmermann@rim.com>
3294
3295         Not reviewed, build fix.
3296
3297         Remove platform layering violation: TextRun stores RenderObjects for SVG Fonts support
3298         https://bugs.webkit.org/show_bug.cgi?id=60254
3299
3300         Forgot to rename the destructor.
3301
3302         * platform/graphics/SimpleFontData.h:
3303         (WebCore::SimpleFontData::AdditionalFontData::~AdditionalFontData):
3304
3305 2011-05-24  Nikolas Zimmermann  <nzimmermann@rim.com>
3306
3307         Not reviewed, build fix.
3308
3309         Remove platform layering violation: TextRun stores RenderObjects for SVG Fonts support
3310         https://bugs.webkit.org/show_bug.cgi?id=60254
3311
3312         Rename SimpleFontData::FontData subclass to AdditionalFontData, to avoid clashes with the WebCore::FontData class, which breaks the win build.
3313
3314         * platform/graphics/SimpleFontData.cpp:
3315         (WebCore::SimpleFontData::SimpleFontData):
3316         * platform/graphics/SimpleFontData.h:
3317         (WebCore::SimpleFontData::fontData):
3318         * svg/SVGFontData.h:
3319
3320 2011-05-24  Nikolas Zimmermann  <nzimmermann@rim.com>
3321
3322         Reviewed by Antti Koivisto.
3323
3324         Remove platform layering violation: TextRun stores RenderObjects for SVG Fonts support
3325         https://bugs.webkit.org/show_bug.cgi?id=60254
3326
3327         First part:
3328         Remove a long-standing layering violation in TextRun: it stores RenderObject/RenderSVGResource pointers for SVG Fonts support.
3329         Replace the two Render* pointers with a single RefPtr<AbstractRenderingContext>. AbstractRenderingContext is a helper class,
3330         that can be derived from in order to associate additional data with a TextRun. This effectively reduces the memory consumption of TextRun.
3331
3332         Introduce rendering/TextRunRenderingContext.h, which inherits from TextRun::AbstractRenderingContext and holds additional data.
3333         If the primary font in use is a SVG Font then allocate a TextRunRenderingContext object and store it in the RefPtr<AbstractRenderingContext>
3334         in TextRun. If the primary font is not a SVG Font, don't even allocate the TextRunRenderingContext structure, as we won't need the context data.
3335         SVG Fonts glyph matching only works within a context, so we need access to the RenderObject that's drawing the text.
3336
3337         This is the main preparation patch for the SVG Fonts rewrite, that will allow us to share the simple text code path for SVG Fonts as well,
3338         making all CSS text properties work for HTML text using SVG Fonts, and allows proper integration within the GlyphPage concept. Soon
3339         we can intermix WOFF/SVG & native fonts, within segment font declarations.
3340
3341         Second part:
3342         Remove a long-standing layering violation in SimpleFontData: it stores SVGFontData objects, that are living in svg/.
3343         Use the same concept as above, introduce SimpleFontData::AbstractFontData, and let SVGFontData inherit from AbstractFontData and extent it.
3344         If SVG Fonts are used, CSSFontFaceSource will create a SVGFontData object and pass it as PassOwnPtr<AbstractFontData> to SimpleFontData.
3345
3346         All layering violations are gone now, SVG Fonts are cleanly integrated now.
3347         Doesn't affect any tests yet, refactoring only.
3348
3349         * CMakeLists.txt:
3350         * GNUmakefile.list.am:
3351         * WebCore.gypi:
3352         * WebCore.pro:
3353         * WebCore.vcproj/WebCore.vcproj:
3354         * WebCore.xcodeproj/project.pbxproj:
3355         * css/CSSFontFaceSource.cpp:
3356         (WebCore::CSSFontFaceSource::getFontData):
3357         * platform/graphics/Font.cpp:
3358         (WebCore::Font::drawText):
3359         (WebCore::Font::width):
3360         (WebCore::Font::selectionRectForText):
3361         (WebCore::Font::offsetForPosition):
3362         * platform/graphics/Font.h:
3363         * platform/graphics/SimpleFontData.cpp:
3364         (WebCore::SimpleFontData::SimpleFontData):
3365         (WebCore::SimpleFontData::~SimpleFontData):
3366         * platform/graphics/SimpleFontData.h:
3367         (WebCore::SimpleFontData::FontData::~FontData):
3368         (WebCore::SimpleFontData::fontMetrics):
3369         (WebCore::SimpleFontData::setMaxCharWidth):
3370         (WebCore::SimpleFontData::setAvgCharWidth):
3371         (WebCore::SimpleFontData::setSpaceWidth):
3372         (WebCore::SimpleFontData::setSpaceGlyph):
3373         (WebCore::SimpleFontData::setZeroWidthSpaceGlyph):
3374         (WebCore::SimpleFontData::fontData):
3375         (WebCore::SimpleFontData::isSVGFont):
3376         (WebCore::SimpleFontData::setMissingGlyphData):
3377         * platform/graphics/TextRun.h:
3378         (WebCore::TextRun::TextRun):
3379         (WebCore::TextRun::setAllowTabs):
3380         (WebCore::TextRun::setXPos):
3381         (WebCore::TextRun::RenderingContext::~RenderingContext):
3382         (WebCore::TextRun::renderingContext):
3383         (WebCore::TextRun::setRenderingContext):
3384         * rendering/EllipsisBox.cpp:
3385         (WebCore::EllipsisBox::paint):
3386         (WebCore::EllipsisBox::selectionRect):
3387         (WebCore::EllipsisBox::paintSelection):
3388         * rendering/InlineTextBox.cpp:
3389         (WebCore::InlineTextBox::selectionRect):
3390         (WebCore::InlineTextBox::paint):
3391         (WebCore::InlineTextBox::paintSelection):
3392         (WebCore::InlineTextBox::paintCompositionBackground):
3393         (WebCore::InlineTextBox::paintSpellingOrGrammarMarker):
3394         (WebCore::InlineTextBox::paintTextMatchMarker):
3395         (WebCore::InlineTextBox::computeRectForReplacementMarker):
3396         (WebCore::InlineTextBox::offsetForPosition):
3397         (WebCore::InlineTextBox::positionForOffset):
3398         (WebCore::InlineTextBox::constructTextRun):
3399         * rendering/InlineTextBox.h:
3400         * rendering/RenderBlock.cpp:
3401         (WebCore::stripTrailingSpace):
3402         (WebCore::RenderBlock::constructTextRun):
3403         * rendering/RenderBlock.h:
3404         * rendering/RenderBlockLineLayout.cpp:
3405         (WebCore::setLogicalWidthForTextRun):
3406         (WebCore::textWidth):
3407         (WebCore::tryHyphenating):
3408         (WebCore::RenderBlock::LineBreaker::nextLineBreak):
3409         (WebCore::RenderBlock::checkLinesForTextOverflow):
3410         * rendering/RenderCombineText.cpp:
3411         (WebCore::RenderCombineText::combineText):
3412         * rendering/RenderFileUploadControl.cpp:
3413         (WebCore::RenderFileUploadControl::paintObject):
3414         (WebCore::RenderFileUploadControl::computePreferredLogicalWidths):
3415         * rendering/RenderFlexibleBox.cpp:
3416         (WebCore::RenderFlexibleBox::applyLineClamp):
3417         * rendering/RenderImage.cpp:
3418         (WebCore::RenderImage::setImageSizeForAltText):
3419         (WebCore::RenderImage::paintReplaced):
3420         * rendering/RenderListBox.cpp:
3421         (WebCore::RenderListBox::updateFromElement):
3422         * rendering/RenderListMarker.cpp:
3423         (WebCore::RenderListMarker::paint):
3424         (WebCore::RenderListMarker::computePreferredLogicalWidths):
3425         (WebCore::RenderListMarker::getRelativeMarkerRect):
3426         * rendering/RenderText.cpp:
3427         (WebCore::RenderText::widthFromCache):
3428         (WebCore::RenderText::trimmedPrefWidths):
3429         (WebCore::RenderText::computePreferredLogicalWidths):
3430         (WebCore::RenderText::width):
3431         * rendering/RenderTextControl.cpp:
3432         (WebCore::RenderTextControl::getAvgCharWidth):
3433         * rendering/svg/RenderSVGAllInOne.cpp:
3434         * rendering/svg/SVGInlineTextBox.cpp:
3435         (WebCore::SVGInlineTextBox::offsetForPositionInFragment):
3436         (WebCore::SVGInlineTextBox::prepareGraphicsContextForTextPainting):
3437         (WebCore::SVGInlineTextBox::restoreGraphicsContextAfterTextPainting):
3438         (WebCore::SVGInlineTextBox::constructTextRun):
3439         (WebCore::SVGInlineTextBox::paintText):
3440         * rendering/svg/SVGTextLayoutEngineSpacing.cpp:
3441         (WebCore::SVGTextLayoutEngineSpacing::calculateSVGKerning):
3442         * rendering/svg/SVGTextMetrics.cpp:
3443         (WebCore::constructTextRun):
3444         (WebCore::SVGTextMetrics::measureCharacterRange):
3445         * rendering/svg/SVGTextRunRenderingContext.cpp: Copied from svg/SVGFont.cpp.
3446         (WebCore::svgFontAndFontFaceElementForFontData):
3447         (WebCore::firstParentRendererForNonTextNode):
3448         (WebCore::referencingRenderObjectFromRun):
3449         (WebCore::activePaintingResourceFromRun):
3450         (WebCore::SVGTextRunWalker::walk):
3451         (WebCore::floatWidthMissingGlyphCallback):
3452         (WebCore::floatWidthOfSubStringUsingSVGFont):
3453         (WebCore::SVGTextRunRenderingContext::floatWidthUsingSVGFont):
3454         (WebCore::SVGTextRunRenderingContext::drawTextUsingSVGFont):
3455         (WebCore::SVGTextRunRenderingContext::selectionRectForTextUsingSVGFont):
3456         (WebCore::SVGTextRunRenderingContext::offsetForPositionForTextUsingSVGFont):
3457         * rendering/svg/SVGTextRunRenderingContext.h: Added.
3458         (WebCore::SVGTextRunRenderingContext::create):
3459         (WebCore::SVGTextRunRenderingContext::context):
3460         (WebCore::SVGTextRunRenderingContext::activePaintingResource):
3461         (WebCore::SVGTextRunRenderingContext::setActivePaintingResource):
3462         (WebCore::SVGTextRunRenderingContext::SVGTextRunRenderingContext):
3463         (WebCore::textRunNeedsRenderingContext):
3464         * svg/SVGAllInOne.cpp:
3465         * svg/SVGFont.cpp: Removed.
3466         * svg/SVGFontData.cpp: