'class WrapperTypeInfo' should be 'struct WrapperTypeInfo'
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-08-08  Kentaro Hara  <haraken@chromium.org>
2
3         'class WrapperTypeInfo' should be 'struct WrapperTypeInfo'
4
5         Unreviewed. Build fix for r125015.
6
7         * bindings/v8/V8BindingPerIsolateData.h:
8         (WebCore):
9
10 2012-08-08  Matt Arsenault  <arsenm2@gmail.com>
11
12         Crash when inspecting an element with border-image
13         https://bugs.webkit.org/show_bug.cgi?id=93380
14
15         Reviewed by Tim Horton.
16
17         The second value in the CSSPair should be the same as the first if
18         we are in a shorthand and the next value is not a
19         border-image-repeat keyword.
20
21         Test: fast/css/parse-border-image-repeat-null-crash.html
22
23         * css/CSSParser.cpp:
24         (WebCore::CSSParser::parseBorderImageRepeat):
25
26 2012-08-08  Kentaro Hara  <haraken@chromium.org>
27
28         [V8] Factor out V8BindingPerIsolateData from V8Binding to a separate file
29         https://bugs.webkit.org/show_bug.cgi?id=93333
30
31         Reviewed by Adam Barth.
32
33         This patch moves V8BindingPerIsolateData to V8BindingPerIsolateData.{h,cpp}.
34
35         To avoid circular #include dependency, I used OwnPtrs for m_stringCache,
36         m_integerCache, m_hiddenPropertyName and m_gcEventData.
37
38         No tests. No change in behavior.
39
40         * UseV8.cmake:
41         * WebCore.gypi:
42         * bindings/v8/ScriptGCEvent.cpp:
43         (WebCore::isolateGCEventData):
44         (WebCore::ScriptGCEvent::addEventListener):
45         (WebCore::ScriptGCEvent::removeEventListener):
46         (WebCore::ScriptGCEvent::gcPrologueCallback):
47         (WebCore::ScriptGCEvent::gcEpilogueCallback):
48         * bindings/v8/V8Binding.cpp:
49         * bindings/v8/V8Binding.h:
50         (GCEventData):
51         (WebCore):
52         * bindings/v8/V8BindingPerIsolateData.cpp: Added.
53         (WebCore):
54         (WebCore::V8BindingPerIsolateData::V8BindingPerIsolateData):
55         (WebCore::V8BindingPerIsolateData::~V8BindingPerIsolateData):
56         (WebCore::V8BindingPerIsolateData::create):
57         (WebCore::V8BindingPerIsolateData::ensureInitialized):
58         (WebCore::V8BindingPerIsolateData::dispose):
59         (WebCore::V8BindingPerIsolateData::reportMemoryUsage):
60         * bindings/v8/V8BindingPerIsolateData.h: Added.
61         (WebCore):
62         (V8BindingPerIsolateData):
63         (WebCore::V8BindingPerIsolateData::current):
64         (WebCore::V8BindingPerIsolateData::rawTemplateMap):
65         (WebCore::V8BindingPerIsolateData::templateMap):
66         (WebCore::V8BindingPerIsolateData::toStringName):
67         (WebCore::V8BindingPerIsolateData::toStringTemplate):
68         (WebCore::V8BindingPerIsolateData::lazyEventListenerToStringTemplate):
69         (WebCore::V8BindingPerIsolateData::stringCache):
70         (WebCore::V8BindingPerIsolateData::integerCache):
71         (WebCore::V8BindingPerIsolateData::allStores):
72         (WebCore::V8BindingPerIsolateData::hiddenPropertyName):
73         (WebCore::V8BindingPerIsolateData::auxiliaryContext):
74         (WebCore::V8BindingPerIsolateData::registerDOMDataStore):
75         (WebCore::V8BindingPerIsolateData::unregisterDOMDataStore):
76         (WebCore::V8BindingPerIsolateData::domDataStore):
77         (WebCore::V8BindingPerIsolateData::setDOMDataStore):
78         (WebCore::V8BindingPerIsolateData::recursionLevel):
79         (WebCore::V8BindingPerIsolateData::incrementRecursionLevel):
80         (WebCore::V8BindingPerIsolateData::decrementRecursionLevel):
81         (WebCore::V8BindingPerIsolateData::globalHandleMap):
82         (WebCore::V8BindingPerIsolateData::internalScriptRecursionLevel):
83         (WebCore::V8BindingPerIsolateData::incrementInternalScriptRecursionLevel):
84         (WebCore::V8BindingPerIsolateData::decrementInternalScriptRecursionLevel):
85         (WebCore::V8BindingPerIsolateData::gcEventData):
86         (WebCore::V8BindingPerIsolateData::setShouldCollectGarbageSoon):
87         (WebCore::V8BindingPerIsolateData::clearShouldCollectGarbageSoon):
88         (WebCore::V8BindingPerIsolateData::shouldCollectGarbageSoon):
89
90 2012-08-08  Pavel Feldman  <pfeldman@chromium.org>
91
92         Web Inspector: show whitespace nodes if they are the only tag's children.
93         https://bugs.webkit.org/show_bug.cgi?id=93441
94
95         Reviewed by Vsevolod Vlasov.
96
97         Pass whitespace node info into the front-end when it is the only element's child.
98
99         * inspector/InspectorDOMAgent.cpp:
100         (WebCore::InspectorDOMAgent::buildArrayForContainerChildren):
101
102 2012-08-08  Kentaro Hara  <haraken@chromium.org>
103
104         [V8] Pass Isolate to ArrayValue and Dictionary
105         https://bugs.webkit.org/show_bug.cgi?id=93315
106
107         Reviewed by Adam Barth.
108
109         This patch passes Isolate to ArrayValue and Dictionary.
110
111         Rationale 1: We want to replace V8Proxy::throwError(ExceptionCode)
112         with setDOMException(ExceptionCode, Isolate*). For the replacement,
113         we need to pass Isolate to V8Utilities::extractTransferables().
114         To pass Isolate to V8Utilities::extractTransferables(), ( ...omitted... ),
115         we need to pass Isolate to ArrayValue and Dictionary.
116
117         Rationale 2: JSC already passes ExecState to ArrayValue and Dictionary.
118
119         Tests: storage/indexeddb/*
120                fast/files/*
121
122         * bindings/scripts/CodeGeneratorV8.pm:
123         (GenerateEventConstructorCallback):
124         (JSValueToNative):
125         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
126         (WebCore::V8TestEventConstructor::constructorCallback):
127         * bindings/scripts/test/V8/V8TestObj.cpp:
128         (WebCore::TestObjV8Internal::optionsObjectCallback):
129         * bindings/v8/ArrayValue.cpp:
130         (WebCore::ArrayValue::operator=):
131         (WebCore::ArrayValue::get):
132         * bindings/v8/ArrayValue.h:
133         (WebCore::ArrayValue::ArrayValue):
134         (ArrayValue):
135         * bindings/v8/Dictionary.cpp:
136         (WebCore::Dictionary::Dictionary):
137         (WebCore::Dictionary::operator=):
138         (WebCore::Dictionary::get):
139         * bindings/v8/Dictionary.h:
140         (Dictionary):
141         * bindings/v8/custom/V8BlobCustom.cpp:
142         (WebCore::V8Blob::constructorCallback):
143         * bindings/v8/custom/V8IntentConstructor.cpp:
144         (WebCore::V8Intent::constructorCallback):
145
146 2012-08-08  Yury Semikhatsky  <yurys@chromium.org>
147
148         Web Inspector: cached images memory instrumentation regression after r124744
149         https://bugs.webkit.org/show_bug.cgi?id=93366
150
151         Reviewed by Vsevolod Vlasov.
152
153         CachedImage memory usage data no includes size of both encoded and
154         decoded data.
155
156         Test: inspector/profiler/memory-instrumentation-cached-images.html
157
158         * loader/cache/CachedImage.cpp:
159         (WebCore::CachedImage::reportMemoryUsage):
160
161 2012-08-08  Kentaro Hara  <haraken@chromium.org>
162
163         Optimize Element::hasAttribute() by replacing String with AtomicString
164         https://bugs.webkit.org/show_bug.cgi?id=90273
165
166         Reviewed by Adam Barth.
167
168         Based on the observation described in this ChangeLog
169         (http://trac.webkit.org/changeset/121439), this patch optimizes the
170         performance of Element::hasAttribute() by replacing String with AtomicString.
171
172         Performance test: https://bugs.webkit.org/attachment.cgi?id=150144
173
174         hasAttribute (Chromium/Linux):
175         329.60ms => 259.00ms
176
177         hasAttributeNS (Chromium/Linux):
178         549.60ms => 435.80ms
179
180         * dom/Element.cpp:
181         (WebCore::Element::hasAttribute):
182         (WebCore::Element::hasAttributeNS):
183         * dom/Element.h:
184         (Element):
185
186 2012-08-08  Kentaro Hara  <haraken@chromium.org>
187
188         Optimize Element::removeAttribute() by replacing String with AtomicString
189         https://bugs.webkit.org/show_bug.cgi?id=90265
190
191         Reviewed by Adam Barth.
192
193         Based on the observation described in this ChangeLog
194         (http://trac.webkit.org/changeset/121439), this patch optimizes
195         Element::removeAttribute() by replacing String with AtomicString.
196
197         Performance test: https://bugs.webkit.org/attachment.cgi?id=150140
198
199         removeAttribute (Chromium/Linux):
200         334.20ms => 240.60ms
201
202         removeAttributeNS (Chromium/Linux):
203         552.80ms => 421.60ms
204
205         * dom/Element.cpp:
206         (WebCore::Element::removeAttribute):
207         (WebCore::Element::removeAttributeNS):
208         * dom/Element.h:
209         (Element):
210
211 2012-08-08  Shinya Kawanaka  <shinyak@chromium.org>
212
213         Remove Element::ensureShadowRoot
214         https://bugs.webkit.org/show_bug.cgi?id=77608
215
216         Reviewed by Ryosuke Niwa.
217
218         Since Element::ensureShadowRoot is not used anymore, we can remove this safely.
219
220         No new tests, no change in behavior.
221
222         * WebCore.order:
223         * dom/Element.cpp:
224         * dom/Element.h:
225         (Element):
226
227 2012-08-08  Kentaro Hara  <haraken@chromium.org>
228
229         Remove an unused member variable.
230
231         Unreviewed, build fix for r124990.
232
233         * dom/ContainerNode.h:
234         (WebCore::ChildNodesLazySnapshot::ChildNodesLazySnapshot):
235         (ChildNodesLazySnapshot):
236
237 2012-08-07  Vsevolod Vlasov  <vsevik@chromium.org>
238
239         Web Inspector: TabbedPane should use floating point width values for measuring.
240         https://bugs.webkit.org/show_bug.cgi?id=93349
241
242         Reviewed by Pavel Feldman.
243
244         TabbedPane now uses getBoundingClientRect().width instead of offsetWidth for more precise calculation.
245
246         * inspector/front-end/TabbedPane.js:
247         (WebInspector.TabbedPane.prototype._totalWidth):
248         (WebInspector.TabbedPane.prototype._updateTabsDropDown):
249         (WebInspector.TabbedPane.prototype._measureDropDownButton):
250         (WebInspector.TabbedPane.prototype._updateWidths):
251         (WebInspector.TabbedPaneTab.prototype._measure):
252
253 2012-08-08  Douglas Stockwell  <dstockwell@chromium.org>
254
255         'highlight' should not be parsed for a composite operation
256         https://bugs.webkit.org/show_bug.cgi?id=92615
257
258         Reviewed by Ryosuke Niwa.
259
260         r88144 removed support for highlight as a composite operation but did
261         not update the parser.
262
263         Test: fast/backgrounds/composite-highlight-is-invalid.html
264
265         * css/CSSParser.cpp:
266         (WebCore::CSSParser::parseFillProperty):
267
268 2012-08-08  Takashi Sakamoto  <tasak@google.com>
269
270         showNodePath should show the age of ShadowRoot
271         https://bugs.webkit.org/show_bug.cgi?id=93347
272
273         Reviewed by Ryosuke Niwa.
274
275         No new tests, because this patch is for fixing a bug of a method for
276         debugging. If NDEBUG is defined, the method is not compiled.
277
278         * dom/Node.cpp:
279         (WebCore::Node::showNodePathForThis):
280         Fixed the bug to obtain the oldest shadow root from a shadow root.
281         oldestShadowRootFor only works for an element node, not for a shadow root.
282
283 2012-08-07  Kent Tamura  <tkent@chromium.org>
284
285         Remove fractionDigits argument of WebCore::convertToLocalizedNumber()
286         https://bugs.webkit.org/show_bug.cgi?id=93435
287
288         Reviewed by Kentaro Hara.
289
290         Remove the fractionDigits argument of convertToLocalizedNumber because
291         we don't use it any more. Also, we can remove
292         parseToDoubleForNumberTypeWithDecimalPlaces() functions, which are used
293         to obtain the fractionDigits argument.
294
295         No new tests because of no behavior changes.
296
297         * platform/text/LocalizedNumber.h:
298         (WebCore): Remove the fractionDigits argument of convertToLocalizedNumber.
299         * platform/text/LocalizedNumberICU.cpp:
300         (WebCore::convertToLocalizedNumber): ditto.
301         * platform/text/LocalizedNumberNone.cpp:
302         (WebCore::convertToLocalizedNumber): ditto.
303         * platform/text/mac/LocalizedNumberMac.mm:
304         (WebCore::convertToLocalizedNumber): ditto.
305         * platform/text/win/LocalizedNumberWin.cpp:
306         (WebCore::convertToLocalizedNumber): ditto.
307
308         * html/NumberInputType.cpp:
309         (WebCore::NumberInputType::localizeValue):
310         Remove the code to make the decimalPlace value.
311         * html/parser/HTMLParserIdioms.cpp:
312         Remove parseToDoubleForNumberTypeWithDecimalPlaces.
313         * html/parser/HTMLParserIdioms.h: ditto.
314
315 2012-08-08  Mario Sanchez Prada  <msanchez@igalia.com>
316
317         REGRESSION(r65062): out of bound access in TextIterator (5 editing tests) on GTK
318         https://bugs.webkit.org/show_bug.cgi?id=63611
319
320         Reviewed by Ryosuke Niwa.
321
322         Ensure document's layout is up-to-date before using TextIterator
323         to properly calculate the offset for a text change when emitting
324         accessibility related signals in GTK.
325
326         * accessibility/gtk/AXObjectCacheAtk.cpp:
327         (WebCore::AXObjectCache::nodeTextChangePlatformNotification): Call
328         to document->updateLayout() before using TextIterator.
329
330 2012-08-07  Hayato Ito  <hayato@chromium.org>
331
332         Unreviewed build fix after http://trac.webkit.org/changeset/124975
333
334         Remove assertion introduced in r124975.
335
336         * dom/EventDispatcher.cpp:
337         (WebCore::EventDispatcher::EventDispatcher):
338         (WebCore::EventDispatcher::dispatchEvent):
339         * dom/EventDispatcher.h:
340         (EventDispatcher):
341
342 2012-08-07  Sheriff Bot  <webkit.review.bot@gmail.com>
343
344         Unreviewed, rolling out r124969.
345         http://trac.webkit.org/changeset/124969
346         https://bugs.webkit.org/show_bug.cgi?id=93436
347
348         Causes assertion failure in RenderQueue (Requested by toyoshim
349         on #webkit).
350
351         * rendering/RenderObjectChildList.cpp:
352         (WebCore::RenderObjectChildList::removeChildNode):
353         (WebCore::RenderObjectChildList::appendChildNode):
354         (WebCore::RenderObjectChildList::insertChildNode):
355         * rendering/RenderQuote.cpp:
356         (WebCore::adjustDepth):
357         (WebCore::RenderQuote::RenderQuote):
358         (WebCore::RenderQuote::~RenderQuote):
359         (WebCore::RenderQuote::willBeDestroyed):
360         (WebCore::RenderQuote::renderName):
361         (WebCore):
362         (WebCore::RenderQuote::placeQuote):
363         (WebCore::RenderQuote::originalText):
364         (WebCore::RenderQuote::computePreferredLogicalWidths):
365         (WebCore::RenderQuote::rendererSubtreeAttached):
366         (WebCore::RenderQuote::rendererRemovedFromTree):
367         (WebCore::RenderQuote::styleDidChange):
368         * rendering/RenderQuote.h:
369         (RenderQuote):
370         (WebCore::RenderQuote::isQuote):
371         * rendering/RenderView.cpp:
372         (WebCore::RenderView::RenderView):
373         * rendering/RenderView.h:
374         (WebCore):
375         (RenderView):
376         (WebCore::RenderView::addRenderQuote):
377         (WebCore::RenderView::removeRenderQuote):
378         (WebCore::RenderView::hasRenderQuotes):
379         * rendering/style/RenderStyle.cpp:
380         (WebCore::RenderStyle::diff):
381
382 2012-08-07  Kentaro Hara  <haraken@chromium.org>
383
384         Optimize ChildNode{Insertion,Removal}Notifier::notify() by lazily taking a snapshot of child nodes
385         https://bugs.webkit.org/show_bug.cgi?id=92965
386
387         Reviewed by Adam Barth.
388
389         This patch improves performance of Dromaeo/dom-modify by 8.2% in both Chromium and Safari.
390
391         [Mac/Safari]     4590.33 runs/s  =>  4965.79 runs/s  (+8.18%)
392         [Chromium/Linux] 3970.63 runs/s  =>  4299.65 runs/s  (+8.29%)
393
394         notifyDescendantRemovedFromDocument() cannot iterate child nodes in this way:
395
396         void notifyDescendantRemovedFromDocument(Node* node) {
397             for (Node* child = node->firstChild(); child; child = child->nextSibling()) {
398                 ...;
399                 notifyNodeRemovedFromDocument(child);
400             }
401         }
402
403         This is because notifyNodeRemovedFromDocument(child) might dispatch events
404         and the events might change child trees. To avoid security issues, the current
405         code takes a snapshot of child nodes before starting the iteration.
406
407         void notifyDescendantRemovedFromDocument(Node* node) {
408             NodeVector children;
409             getChildNodes(node, children); // Take a snapshot.
410             for (int i = 0; i < children.size(); i++) {
411                 ...;
412                 notifyNodeRemovedFromDocument(children[i]);
413             }
414         }
415
416         Based on the observation that in almost all cases events won't be dispatched
417         from inside notifyNodeRemovedFromDocument(), this patch implements
418         a "lazy" snapshot. The snapshot is taken at the point where
419         EventDispatcher::dispatchEvent() is invoked. The snapshot is not taken unless
420         any event is dispatched.
421
422         No tests. Confirm that all existing tests pass.
423         Actually, at present there is (should be) no case where an event is
424         dispatched from inside notifyNodeRemovedFromDocument(). Even DOMNodeInserted
425         and DOMNodeRemoved events are not dispatched. Originally the snapshot was
426         implemented "just in case" to protect the code from future attacks.
427         I manually confirmed that the lazy snapshot works correctly by inserting
428         takeChildNodesSnapshot() to notifyDescendantRemovedFromDocument()
429         in a random manner.
430
431         * dom/ContainerNode.cpp:
432         (WebCore):
433         * dom/ContainerNode.h:
434         (ChildNodesLazySnapshot):
435         (WebCore::ChildNodesLazySnapshot::ChildNodesLazySnapshot):
436         (WebCore::ChildNodesLazySnapshot::~ChildNodesLazySnapshot):
437         (WebCore::ChildNodesLazySnapshot::nextNode):
438         (WebCore::ChildNodesLazySnapshot::takeSnapshot):
439         (WebCore::ChildNodesLazySnapshot::nextSnapshot):
440         (WebCore::ChildNodesLazySnapshot::hasSnapshot):
441         (WebCore::ChildNodesLazySnapshot::takeChildNodesLazySnapshot):
442         (WebCore):
443         * dom/ContainerNodeAlgorithms.cpp:
444         (WebCore::ChildNodeInsertionNotifier::notifyDescendantInsertedIntoDocument):
445         (WebCore::ChildNodeRemovalNotifier::notifyDescendantRemovedFromDocument):
446         * dom/EventDispatcher.cpp:
447         (WebCore::EventDispatcher::dispatchEvent):
448
449 2012-08-07  Ojan Vafai  <ojan@chromium.org>
450
451         percentage margins + flex incorrectly overflows the flexbox
452         https://bugs.webkit.org/show_bug.cgi?id=93411
453
454         Reviewed by Tony Chang.
455
456         Percent margins should always be computed with respect to the containing
457         block's width, not it's height. We were getting this wrong in column flows.
458
459         Test: css3/flexbox/percent-margins.html
460
461         * rendering/RenderFlexibleBox.cpp:
462         (WebCore::RenderFlexibleBox::computeMarginValue):
463         (WebCore):
464         (WebCore::RenderFlexibleBox::computeMainAxisPreferredSizes):
465         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren):
466         * rendering/RenderFlexibleBox.h:
467
468 2012-08-07  Kentaro Hara  <haraken@chromium.org>
469
470         [V8] Replace throwError(ExceptionCode, Isolate*) with setDOMException(ExceptionCode, Isolate*) in v8/* and v8/custom/*
471         https://bugs.webkit.org/show_bug.cgi?id=93226
472
473         Reviewed by Eric Seidel.
474
475         Now throwError(ExceptionCode, Isolate*) is equivalent to
476         setDOMException(ExceptionCode, Isolate*). We can replace the former with
477         the latter. After this replacement, the rule becomes simple and sane:
478         "Use throwError() for throwing JavaScript errors, use setDOMException()
479         for throwing DOM exceptions".
480
481         No tests. No change in behavior.
482
483         * bindings/v8/SerializedScriptValue.cpp:
484         (WebCore::SerializedScriptValue::transferArrayBuffers):
485         (WebCore::SerializedScriptValue::SerializedScriptValue):
486         * bindings/v8/custom/V8AudioContextCustom.cpp:
487         (WebCore::V8AudioContext::constructorCallback):
488         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp:
489         (WebCore::V8CSSStyleDeclaration::namedPropertySetter):
490         * bindings/v8/custom/V8DOMStringMapCustom.cpp:
491         (WebCore::V8DOMStringMap::namedPropertySetter):
492         * bindings/v8/custom/V8DOMWindowCustom.cpp:
493         (WebCore::handlePostMessageCallback):
494         * bindings/v8/custom/V8DedicatedWorkerContextCustom.cpp:
495         (WebCore::handlePostMessageCallback):
496         * bindings/v8/custom/V8DirectoryEntryCustom.cpp:
497         (WebCore::V8DirectoryEntry::getDirectoryCallback):
498         (WebCore::V8DirectoryEntry::getFileCallback):
499         * bindings/v8/custom/V8DocumentCustom.cpp:
500         (WebCore::V8Document::evaluateCallback):
501         * bindings/v8/custom/V8HistoryCustom.cpp:
502         (WebCore::V8History::pushStateCallback):
503         (WebCore::V8History::replaceStateCallback):
504         * bindings/v8/custom/V8IntentConstructor.cpp:
505         (WebCore::V8Intent::constructorCallback):
506         * bindings/v8/custom/V8MessagePortCustom.cpp:
507         (WebCore::handlePostMessageCallback):
508         * bindings/v8/custom/V8MutationObserverCustom.cpp:
509         (WebCore::V8MutationObserver::constructorCallback):
510         * bindings/v8/custom/V8NotificationCenterCustom.cpp:
511         (WebCore::V8NotificationCenter::createHTMLNotificationCallback):
512         (WebCore::V8NotificationCenter::createNotificationCallback):
513         (WebCore::V8NotificationCenter::requestPermissionCallback):
514         * bindings/v8/custom/V8SQLTransactionCustom.cpp:
515         (WebCore::V8SQLTransaction::executeSqlCallback):
516         * bindings/v8/custom/V8SQLTransactionSyncCustom.cpp:
517         (WebCore::V8SQLTransactionSync::executeSqlCallback):
518         * bindings/v8/custom/V8StorageCustom.cpp:
519         (WebCore::storageSetter):
520         * bindings/v8/custom/V8WebSocketCustom.cpp:
521         (WebCore::V8WebSocket::constructorCallback):
522         (WebCore::V8WebSocket::sendCallback):
523         * bindings/v8/custom/V8WorkerContextCustom.cpp:
524         (WebCore::V8WorkerContext::importScriptsCallback):
525         * bindings/v8/custom/V8WorkerCustom.cpp:
526         (WebCore::handlePostMessageCallback):
527         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
528         (WebCore::V8XMLHttpRequest::responseTextAccessorGetter):
529         (WebCore::V8XMLHttpRequest::openCallback):
530         (WebCore::V8XMLHttpRequest::sendCallback):
531
532 2012-08-07  Kentaro Hara  <haraken@chromium.org>
533
534         [V8] Replace v8::Handle<v8::Value>() in custom bindings with v8Undefined()
535         https://bugs.webkit.org/show_bug.cgi?id=93215
536
537         Reviewed by Eric Seidel.
538
539         We should use v8Undefined() everywhere in V8 bindings.
540
541         No tests. No change in behavior.
542
543         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp:
544         (WebCore::V8CSSStyleDeclaration::namedPropertyGetter):
545         (WebCore::V8CSSStyleDeclaration::namedPropertySetter):
546         * bindings/v8/custom/V8ConsoleCustom.cpp:
547         (WebCore::V8Console::traceCallback):
548         (WebCore::V8Console::assertCallback):
549         (WebCore::V8Console::profileCallback):
550         (WebCore::V8Console::profileEndCallback):
551         * bindings/v8/custom/V8DOMStringMapCustom.cpp:
552         (WebCore::V8DOMStringMap::namedPropertyGetter):
553         * bindings/v8/custom/V8DOMWindowCustom.cpp:
554         (WebCore::V8DOMWindow::indexedPropertyGetter):
555         (WebCore::V8DOMWindow::namedPropertyGetter):
556         * bindings/v8/custom/V8DataViewCustom.cpp:
557         (WebCore::V8DataView::setInt8Callback):
558         (WebCore::V8DataView::setUint8Callback):
559         * bindings/v8/custom/V8DeviceMotionEventCustom.cpp:
560         (WebCore::V8DeviceMotionEvent::initDeviceMotionEventCallback):
561         * bindings/v8/custom/V8DeviceOrientationEventCustom.cpp:
562         (WebCore::V8DeviceOrientationEvent::initDeviceOrientationEventCallback):
563         * bindings/v8/custom/V8DirectoryEntryCustom.cpp:
564         (WebCore::V8DirectoryEntry::getDirectoryCallback):
565         (WebCore::V8DirectoryEntry::getFileCallback):
566         * bindings/v8/custom/V8HTMLAllCollectionCustom.cpp:
567         (WebCore::getNamedItems):
568         (WebCore::V8HTMLAllCollection::namedPropertyGetter):
569         * bindings/v8/custom/V8HTMLCollectionCustom.cpp:
570         (WebCore::getNamedItems):
571         (WebCore::V8HTMLCollection::namedPropertyGetter):
572         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
573         (WebCore::V8HTMLDocument::GetNamedProperty):
574         * bindings/v8/custom/V8HTMLFormElementCustom.cpp:
575         (WebCore::V8HTMLFormElement::indexedPropertyGetter):
576         (WebCore::V8HTMLFormElement::namedPropertyGetter):
577         * bindings/v8/custom/V8HTMLFrameSetElementCustom.cpp:
578         (WebCore::V8HTMLFrameSetElement::namedPropertyGetter):
579         * bindings/v8/custom/V8HTMLOptionsCollectionCustom.cpp:
580         (WebCore::V8HTMLOptionsCollection::indexedPropertyGetter):
581         * bindings/v8/custom/V8HTMLPlugInElementCustom.cpp:
582         (WebCore::npObjectNamedGetter):
583         (WebCore::npObjectNamedSetter):
584         (WebCore::npObjectIndexedGetter):
585         (WebCore::npObjectIndexedSetter):
586         * bindings/v8/custom/V8HTMLSelectElementCustom.cpp:
587         (WebCore::V8HTMLSelectElement::indexedPropertyGetter):
588         * bindings/v8/custom/V8LocationCustom.cpp:
589         (WebCore::V8Location::reloadAccessorGetter):
590         (WebCore::V8Location::replaceAccessorGetter):
591         (WebCore::V8Location::assignAccessorGetter):
592         * bindings/v8/custom/V8NamedNodeMapCustom.cpp:
593         (WebCore::V8NamedNodeMap::indexedPropertyGetter):
594         (WebCore::V8NamedNodeMap::namedPropertyGetter):
595         * bindings/v8/custom/V8NodeListCustom.cpp:
596         (WebCore::V8NodeList::namedPropertyGetter):
597         * bindings/v8/custom/V8SVGLengthCustom.cpp:
598         (WebCore::V8SVGLength::convertToSpecifiedUnitsCallback):
599         * bindings/v8/custom/V8StorageCustom.cpp:
600         (WebCore::storageGetter):
601         (WebCore::V8Storage::namedPropertyGetter):
602         (WebCore::storageSetter):
603         * bindings/v8/custom/V8StyleSheetListCustom.cpp:
604         (WebCore::V8StyleSheetList::namedPropertyGetter):
605
606 2012-08-07  Kentaro Hara  <haraken@chromium.org>
607
608         [V8] Replace v8::Handle<v8::Value>() in bindings/v8/* with v8Undefined()
609         https://bugs.webkit.org/show_bug.cgi?id=93211
610
611         Reviewed by Eric Seidel.
612
613         We should use v8Undefined() everywhere in V8 bindings.
614         Replacing v8::Local<v8::Value>() etc with v8Undefined() can cause build
615         errors due to type conversion mismatch. I'll do the replacement in follow-up
616         patches.
617
618         No tests. No change in behavior.
619
620         * bindings/v8/IDBBindingUtilities.cpp:
621         (WebCore):
622         * bindings/v8/ScriptDebugServer.cpp:
623         (WebCore::ScriptDebugServer::pauseOnExceptionsState):
624         (WebCore::ScriptDebugServer::handleV8DebugEvent):
625         * bindings/v8/SerializedScriptValue.cpp:
626         * bindings/v8/V8Binding.cpp:
627         (WebCore::batchConfigureCallbacks):
628         * bindings/v8/V8Collection.h:
629         (WebCore::getV8Object):
630         (WebCore::collectionNamedPropertyGetter):
631         * bindings/v8/V8DOMWrapper.cpp:
632         (WebCore::V8DOMWrapper::convertEventTargetToV8Object):
633         * bindings/v8/V8NPObject.cpp:
634         (WebCore::npObjectGetProperty):
635         (WebCore::npObjectSetProperty):
636         * bindings/v8/V8Proxy.cpp:
637         (WebCore::V8Proxy::setDOMException):
638         (WebCore::V8Proxy::throwError):
639         * bindings/v8/WorkerScriptDebugServer.cpp:
640         (WebCore::WorkerScriptDebugServer::addListener):
641
642 2012-08-07  Joe Mason  <jmason@rim.com>
643
644         Fix regression in credential storage when using Negotiate auth
645         https://bugs.webkit.org/show_bug.cgi?id=93386
646
647         Reviewed by George Staikos.
648
649         r124205 regressed credential storage and lookup.  It added code to update the scheme used in
650         credential storage if the scheme chosen by the network stack is different from that requested by
651         webkit (currently this is only used when webkit requests Negotiate auth, but the Negotiate
652         infrastructure isn't set up correctly, so the network stack falls back to another auth type, usually
653         NTLM).  But the credentials are saved when a "success" status is received, and the scheme in the
654         credentials is not updated until notifyAuthReceived is called to report the actual auth scheme used.
655         The result is that the credentials are stored with the wrong auth scheme and can never be retreived.
656
657         Fixed by delaying the credential save until notifyAuthReceived.
658
659         RIM PR 166514
660         Internally reviewed by George Staikos
661
662         * platform/network/blackberry/NetworkJob.cpp:
663         (WebCore::NetworkJob::handleNotifyStatusReceived): Stop storing credentials here.
664         (WebCore::NetworkJob::notifyAuthReceived): Store credentials here instead.
665
666 2012-08-07  Kent Tamura  <tkent@chromium.org>
667
668         [Mac] Do not reformat numbers in <input type=number>
669         https://bugs.webkit.org/show_bug.cgi?id=93236
670
671         Reviewed by Hajime Morita.
672
673         We had bugs such as stripping leading zeros, dropping lower digits of
674         large numbers because we parse a user-input string to a double value,
675         and generate a string from the double value.
676
677         In order to avoid such reformatting, we use
678         platform/text/NumberLocalizer, which maps ASCII digits to the
679         corresponding localized digits.
680
681         Test: fast/forms/number/number-lossless-localization.html
682
683         * WebCore.xcodeproj/project.pbxproj:
684         Add the following files:
685          - platform/text/NumberLocalizer.cpp
686          - platform/text/NumberLocalizer.h
687          - platform/mac/LocaleMac.h
688          - platform/mac/LocaleMac.mm
689         * platform/text/mac/LocaleMac.h:
690         (LocaleMac): Inherit NumberLocalizer, and declare
691         initializeNumberLocalizerData() for it.
692         Add m_didInitializeNumberData flag.
693         * platform/text/mac/LocaleMac.mm:
694         (WebCore::LocaleMac::LocaleMac): Initialize m_didInitializeNumberData
695         (WebCore::LocaleMac::initializeNumberLocalizerData):
696         Added. Prepare data for number localization, and call
697         NumberLocalizer::setNumberLocalizerData().
698         A tricky part is to format 9876543210 for m_locale. It seems OSX doesn't
699         have API to get localized digits.
700         * platform/text/mac/LocalizedNumberMac.mm:
701         Remove many lines, and calls the corresponding functions of LocaleMac.
702         (WebCore::convertToLocalizedNumber):
703         (WebCore::convertFromLocalizedNumber):
704         (WebCore::localizedDecimalSeparator):
705
706 2012-08-07  Kentaro Hara  <haraken@chromium.org>
707
708         [V8] Move V8BindingMacros.h from bindings/v8/custom/ to bindings/v8/
709         https://bugs.webkit.org/show_bug.cgi?id=93254
710
711         Reviewed by Eric Seidel.
712
713         V8BindingMacros.h should exist in bindings/v8/.
714         This patch also moves related enums from V8Binding.h to V8BindingMacros.h.
715
716         No tests. No change in behavior.
717
718         * WebCore.gypi:
719         * bindings/v8/V8BindingMacros.h: Renamed from Source/WebCore/bindings/v8/custom/V8BindingMacros.h.
720         (WebCore):
721
722 2012-08-07  Kentaro Hara  <haraken@chromium.org>
723
724         [V8] StringCache::m_lastStringImpl and StringCache::m_lastV8String should be in sync
725         https://bugs.webkit.org/show_bug.cgi?id=93065
726
727         Reviewed by Eric Seidel.
728
729         StringCache::m_lastStringImpl caches a StringImpl that was accessed most
730         recently. StringCache::m_lastV8String caches Persistent<String> corresponding
731         to the StringImpl. Hence m_lastStringImpl and m_lastV8String should be in sync.
732
733         However, StringCache::remove() breaks the sync. StringCache::remove() clears
734         m_lastStringImpl but does not clear m_lastV8String. As far as I analyze the code,
735         this won't cause any problem, but we should fix it just in case.
736
737         No tests. No change in behavior.
738
739         * bindings/v8/V8Binding.cpp:
740         (WebCore::StringCache::remove):
741
742 2012-08-07  Hayato Ito  <hayato@chromium.org>
743
744         Don't re-use the same EventDispatcher instance to dispatch events.
745         https://bugs.webkit.org/show_bug.cgi?id=93322
746
747         Reviewed by Dimitri Glazkov.
748
749         It is potentially dangerous to call
750         EventDispatcher::dispatchEvent(PassRefPtr<Event>) twice for the
751         same EventDispatcher instance.  Some member functions in
752         EventDispatcher assume that dispatchEvent(PassRefPtr<Event>) is
753         never called more than once in its life cycle.
754
755         For example, EventDispatcher::ensureEventAncestor never
756         recalculates ancestors of node even when
757         dispatchEvent(PassRefPtr<Event)) is called again with a different
758         event parameter.
759
760         A 'dblclick' event violates this rule. A 'dblclick' dispatching
761         reuses the same dispatcher instance.  So stop re-using the same
762         dispatcher and add ASSERT to make sure dispatchEvent() is never
763         called more than once.
764
765         No new tests, no change in functionality.
766
767         * dom/EventDispatcher.cpp:
768         (WebCore::EventDispatcher::EventDispatcher):
769         (WebCore::EventDispatcher::dispatchEvent):
770         * dom/EventDispatcher.h:
771         (EventDispatcher):
772         * dom/MouseEvent.cpp:
773         (WebCore::MouseEventDispatchMediator::dispatchEvent):
774
775 2012-08-07  Joshua Bell  <jsbell@chromium.org>
776
777         Layout Test storage/indexeddb/intversion-omit-parameter.html is flaky
778         https://bugs.webkit.org/show_bug.cgi?id=92952
779
780         Reviewed by Tony Chang.
781
782         Account for events being propagated from the back-end to front-end after
783         front-end context is stopped (i.e. document is being destroyed). The IDBRequest
784         lifecycle was tightened up in http://trac.webkit.org/changeset/123275 with more
785         asserts but the stopped state wasn't accounted for.
786
787         Test: [chromium] webkit_unit_tests --gtest_filter='IDBRequestTest.EventsAfterStopping'
788
789         * Modules/indexeddb/IDBRequest.cpp:
790         (WebCore::IDBRequest::abort):
791         (WebCore::IDBRequest::onError):
792         (WebCore::IDBRequest::onSuccess):
793         (WebCore::IDBRequest::onSuccessWithContinuation):
794
795 2012-08-07  Kentaro Hara  <haraken@chromium.org>
796
797         Optimize Element::getAttributeNode() by replacing String with AtomicString
798         https://bugs.webkit.org/show_bug.cgi?id=90274
799
800         Reviewed by Adam Barth.
801
802         Based on the observation described in this ChangeLog
803         (http://trac.webkit.org/changeset/121439), this patch optimizes
804         the performance of Element::getAttributeNode() by replacing String
805         with AtomicString.
806
807         Performance test: https://bugs.webkit.org/attachment.cgi?id=150147
808
809         getAttributeNode (Chromium/Linux):
810         375.20ms => 310.80ms
811
812         getAttributeNodeNS (Chromium/Linux):
813         684.40ms => 539.00ms
814
815         * dom/Element.cpp:
816         (WebCore::Element::getAttributeNode):
817         (WebCore::Element::getAttributeNodeNS):
818         * dom/Element.h:
819         (Element):
820
821 2012-08-07  Michelangelo De Simone  <michelangelo@webkit.org>
822
823         CSSParser::parseTransform() refactor to accept valueList as argument
824         https://bugs.webkit.org/show_bug.cgi?id=93295
825
826         Reviewed by Darin Adler.
827
828         CSS::parseTranform() is now accepting the related CSSParserValueList as
829         argument. This change will be used by the code to parse the 3d-transforms
830         within the custom() function, see bug #71443.
831
832         * css/CSSParser.cpp:
833         (WebCore::CSSParser::parseValue):
834         (WebCore::CSSParser::parseTransform):
835         * css/CSSParser.h:
836
837 2012-08-07  Elliott Sprehn  <esprehn@gmail.com>
838
839         Reimplement RenderQuote placement algorithm
840         https://bugs.webkit.org/show_bug.cgi?id=93056
841
842         Reviewed by Eric Seidel.
843
844         Greatly simplify the code that maintains the linked list of RenderQuotes. Now RenderQuote
845         is placed into the linked list in computePreferredLogicalWidths on first access and is
846         detached when destroyed (or explicitly removed).
847
848         The new algorithm doesn't require walking up the tree of renderers when there are no
849         RenderQuotes in the tree yet, and also removes the need to walk over every subtree
850         when inserting in rendererSubtreeAttached.
851
852         No new tests because this patch doesn't change any behavior.
853
854         * rendering/RenderObjectChildList.cpp:
855         (WebCore::RenderObjectChildList::removeChildNode): Call detachQuote when removing from a child list.
856         (WebCore::RenderObjectChildList::appendChildNode):
857         (WebCore::RenderObjectChildList::insertChildNode):
858         * rendering/RenderQuote.cpp:
859         (WebCore::RenderQuote::RenderQuote):
860         (WebCore::RenderQuote::~RenderQuote):
861         (WebCore::RenderQuote::willBeDestroyed): Call detachQuote to ensure all destroyed quotes are detached.
862         (WebCore::RenderQuote::originalText):
863         (WebCore::RenderQuote::computePreferredLogicalWidths): Attach quote before computing the width.
864         (WebCore):
865         (WebCore::RenderQuote::attachQuote): Puts the RenderQuote in the linked list of quotes and computes the depth.
866         (WebCore::RenderQuote::detachQuote): Removes the quote from the linked list.
867         (WebCore::RenderQuote::updateDepth):
868         * rendering/RenderQuote.h:
869         (RenderQuote):
870         * rendering/style/RenderStyle.cpp:
871         (WebCore::RenderStyle::diff): Return StyleDifferenceLayout if quotes change and remove check in styleDidChange in RenderQuote.
872         * rendering/RenderView.cpp:
873         (WebCore::RenderView::RenderView):
874         * rendering/RenderView.h:
875         (WebCore):
876         (WebCore::RenderView::setRenderQuoteHead):
877         (WebCore::RenderView::renderQuoteHead): Stores the first quote in the document.
878         (RenderView):
879
880 2012-08-07  Kentaro Hara  <haraken@chromium.org>
881
882         [V8] Remove a bunch of Persistent::New()s on setJSWrapperForXXXObject()
883         https://bugs.webkit.org/show_bug.cgi?id=93342
884
885         Reviewed by Adam Barth.
886
887         There are a lot of custom bindings like this:
888
889             V8DOMWrapper::setJSWrapperForDOMObject(impl.release(), v8::Persistent<v8::Object>::New(args.Holder()));
890
891         Manually written Persistent::New() is error-prone. We can remove the
892         Persistent::New() by allocating the Persistent handle inside
893         setJSWrapperForDOMObject().
894
895         A new setJSWrapperForDOMObject() receives a wrapper object, allocates
896         the Persistent handle of the wrapper object, and return the Persistent handle.
897
898         No tests. No change in behavior.
899
900         * bindings/scripts/CodeGeneratorV8.pm:
901         (GenerateConstructorCallback):
902         (GenerateEventConstructorCallback):
903         (GenerateNamedConstructorCallback):
904         (GenerateToV8Converters):
905         * bindings/scripts/test/V8/V8Float64Array.cpp:
906         (WebCore::V8Float64Array::wrapSlow):
907         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
908         (WebCore::V8TestActiveDOMObject::wrapSlow):
909         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
910         (WebCore::V8TestCustomNamedGetter::wrapSlow):
911         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
912         (WebCore::V8TestEventConstructor::constructorCallback):
913         (WebCore::V8TestEventConstructor::wrapSlow):
914         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
915         (WebCore::V8TestEventTarget::wrapSlow):
916         * bindings/scripts/test/V8/V8TestException.cpp:
917         (WebCore::V8TestException::wrapSlow):
918         * bindings/scripts/test/V8/V8TestInterface.cpp:
919         (WebCore::V8TestInterface::constructorCallback):
920         (WebCore::V8TestInterface::wrapSlow):
921         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
922         (WebCore::V8TestMediaQueryListListener::wrapSlow):
923         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
924         (WebCore::V8TestNamedConstructorConstructorCallback):
925         (WebCore::V8TestNamedConstructor::wrapSlow):
926         * bindings/scripts/test/V8/V8TestNode.cpp:
927         (WebCore::V8TestNode::constructorCallback):
928         (WebCore::V8TestNode::wrapSlow):
929         * bindings/scripts/test/V8/V8TestObj.cpp:
930         (WebCore::V8TestObj::constructorCallback):
931         (WebCore::V8TestObj::wrapSlow):
932         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
933         (WebCore::V8TestSerializedScriptValueInterface::constructorCallback):
934         (WebCore::V8TestSerializedScriptValueInterface::wrapSlow):
935         * bindings/v8/V8DOMWindowShell.cpp:
936         (WebCore::V8DOMWindowShell::installDOMWindow):
937         * bindings/v8/V8DOMWrapper.cpp:
938         (WebCore::V8DOMWrapper::setJSWrapperForDOMNode):
939         (WebCore::V8DOMWrapper::setJSWrapperForActiveDOMNode):
940         * bindings/v8/V8DOMWrapper.h:
941         (V8DOMWrapper):
942         (WebCore::V8DOMWrapper::setJSWrapperForDOMObject):
943         (WebCore::V8DOMWrapper::setJSWrapperForActiveDOMObject):
944         * bindings/v8/WorkerContextExecutionProxy.cpp:
945         (WebCore::WorkerContextExecutionProxy::initContextIfNeeded):
946         * bindings/v8/custom/V8ArrayBufferCustom.cpp:
947         (WebCore::V8ArrayBuffer::constructorCallback):
948         * bindings/v8/custom/V8ArrayBufferViewCustom.h:
949         (WebCore::wrapArrayBufferView):
950         (WebCore::constructWebGLArray):
951         * bindings/v8/custom/V8DOMFormDataCustom.cpp:
952         (WebCore::V8DOMFormData::constructorCallback):
953         * bindings/v8/custom/V8DataViewCustom.cpp:
954         (WebCore::V8DataView::constructorCallback):
955         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
956         (WebCore::v8HTMLImageElementConstructorCallback):
957         * bindings/v8/custom/V8IntentConstructor.cpp:
958         (WebCore::V8Intent::constructorCallback):
959         * bindings/v8/custom/V8MessageChannelConstructor.cpp:
960         (WebCore::V8MessageChannel::constructorCallback):
961         * bindings/v8/custom/V8MutationObserverCustom.cpp:
962         (WebCore::V8MutationObserver::constructorCallback):
963         * bindings/v8/custom/V8WebKitPointConstructor.cpp:
964         (WebCore::V8WebKitPoint::constructorCallback):
965         * bindings/v8/custom/V8WebSocketCustom.cpp:
966         (WebCore::V8WebSocket::constructorCallback):
967         * bindings/v8/custom/V8XMLHttpRequestConstructor.cpp:
968         (WebCore::V8XMLHttpRequest::constructorCallback):
969
970 2012-08-07  Erik Arvidsson  <arv@chromium.org>
971
972         Evolution, empathy no longer build with webkint 1.9.6:  webkit_dom_html_element_set_class_name is gone
973         https://bugs.webkit.org/show_bug.cgi?id=93384
974
975         Reviewed by Adam Barth.
976
977         The GObject bindings do not do inheritance so when className was moved from HTMLElement to Element,
978         webkit_dom_html_element_set_class_name was no longer defined. This patch re-adds the binding for the
979         GObject bindings to HTMLElement.
980
981         No new tests.
982
983         * html/HTMLElement.idl:
984
985 2012-08-07  Dirk Pranke  <dpranke@chromium.org>
986
987         fix chromium win build after r124945
988         https://bugs.webkit.org/show_bug.cgi?id=93421
989
990         Unreviewed, build fix.
991
992         Two Efl files were removed in r124945 but we forgot to remove
993         them from WebCore.gypi.
994
995         * WebCore.gypi:
996
997 2012-08-07  Dean Jackson  <dino@apple.com>
998
999         Unreviewed build fix for Mac port after http://trac.webkit.org/changeset/124954
1000
1001         * html/HTMLPlugInElement.cpp:
1002         (WebCore::HTMLPlugInElement::isKeyboardFocusable):
1003
1004 2012-08-07  Kentaro Hara  <haraken@chromium.org>
1005
1006         [V8] Move setIsolatedWorldSecurityOrigin() from V8Proxy to ScriptController
1007         https://bugs.webkit.org/show_bug.cgi?id=93334
1008
1009         Reviewed by Adam Barth.
1010
1011         The goal is to move factor out V8Proxy methods to ScriptController.
1012         As a starting point, this patch moves setIsolatedWorldSecurityOrigin().
1013
1014         isolatedWorlds() and isolatedWorldSecurityOrigins() are temporary methods.
1015         They will be soon removed after moving all related methods
1016         and m_isolatedWorlds and m_isolatedWorldSecurityOrigins.
1017
1018         No tests. No change in behavior.
1019
1020         * bindings/v8/ScriptController.cpp:
1021         (WebCore::ScriptController::setIsolatedWorldSecurityOrigin):
1022         * bindings/v8/V8Proxy.cpp:
1023         * bindings/v8/V8Proxy.h:
1024         (WebCore):
1025         (V8Proxy):
1026         (WebCore::V8Proxy::isolatedWorlds):
1027         (WebCore::V8Proxy::isolatedWorldSecurityOrigins):
1028
1029 2012-08-07  Yoshifumi Inoue  <yosin@chromium.org>
1030
1031         translateZ(0) shifts file name in file input
1032         https://bugs.webkit.org/show_bug.cgi?id=69248
1033
1034         Reviewed by Simon Fraser.
1035
1036         This patch changes to use relative y-coordinate rather than absolute
1037         y-coordinate for baseline of text of input type "file" what we've already
1038         done for file icon y-coordinate.
1039
1040         Test: file-appearance-transform-no-effects.html
1041
1042         * rendering/RenderFileUploadControl.cpp:
1043         (WebCore::RenderFileUploadControl::paintObject): Changed to use paintOffset
1044         instead of absoluteBoundingBoxRectIgnoringTransforms().
1045
1046 2012-08-07  Kentaro Hara  <haraken@chromium.org>
1047
1048         [V8] Replace throwError(ExceptionCode, Isolate*) with
1049         setDOMException(ExceptionCode, Isolate*) in CodeGeneratorV8.pm
1050         https://bugs.webkit.org/show_bug.cgi?id=93223
1051
1052         Reviewed by Adam Barth.
1053
1054         Now throwError(ExceptionCode, Isolate*) is equivalent to
1055         setDOMException(ExceptionCode, Isolate*). We can replace the former
1056         with the latter. After this replacement, the rule becomes simple
1057         and sane: "Use throwError() for throwing JavaScript errors, use
1058         setDOMException() for throwing DOM exceptions".
1059
1060         Test: bindings/scripts/test/TestObj.idl
1061
1062         * bindings/scripts/CodeGeneratorV8.pm:
1063         (GenerateParametersCheck):
1064         (GenerateConstructorCallback):
1065         (GenerateNamedConstructorCallback):
1066         * bindings/scripts/test/V8/V8TestInterface.cpp:
1067         (WebCore::V8TestInterface::constructorCallback):
1068         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
1069         (WebCore::V8TestNamedConstructorConstructorCallback):
1070         * bindings/scripts/test/V8/V8TestObj.cpp:
1071         (WebCore::TestObjV8Internal::methodWithCallbackArgCallback):
1072         (WebCore::TestObjV8Internal::methodWithNonCallbackArgAndCallbackArgCallback):
1073         (WebCore::TestObjV8Internal::methodWithCallbackAndOptionalArgCallback):
1074         (WebCore::TestObjV8Internal::overloadedMethod5Callback):
1075         (WebCore::V8TestObj::constructorCallback):
1076
1077 2012-08-07  Fady Samuel  <fsamuel@chromium.org>
1078
1079         Allow plugins to decide whether they are keyboard focusable
1080         https://bugs.webkit.org/show_bug.cgi?id=88958
1081
1082         Reviewed by Anders Carlsson.
1083
1084         * dom/Node.h:
1085         (WebCore::Node::isPluginElement):
1086         * html/HTMLEmbedElement.cpp:
1087         (WebCore::HTMLEmbedElement::renderWidgetForJSBindings):
1088         * html/HTMLEmbedElement.h:
1089         (HTMLEmbedElement):
1090         * html/HTMLObjectElement.cpp:
1091         (WebCore::HTMLObjectElement::renderWidgetForJSBindings):
1092         * html/HTMLObjectElement.h:
1093         (HTMLObjectElement):
1094         * html/HTMLPlugInElement.cpp:
1095         (WebCore::HTMLPlugInElement::pluginWidget):
1096         (WebCore::HTMLPlugInElement::isKeyboardFocusable):
1097         (WebCore):
1098         (WebCore::HTMLPlugInElement::isPluginElement):
1099         * html/HTMLPlugInElement.h:
1100         (HTMLPlugInElement):
1101         * page/FocusController.cpp:
1102         (WebCore::FocusController::advanceFocusInDocumentOrder):
1103         * plugins/PluginViewBase.h:
1104         (WebCore::PluginViewBase::supportsKeyboardFocus):
1105
1106 2012-08-07  Anna Cavender  <annacc@chromium.org>
1107
1108         Create a MediaSource object.
1109         https://bugs.webkit.org/show_bug.cgi?id=91773
1110
1111         Reviewed by Eric Carlson.
1112
1113         MediaSource object is needed in order to implement the new
1114         object-oriented MediaSource API:
1115         http://dvcs.w3.org/hg/html-media/raw-file/tip/media-source/media-source.html
1116
1117         No new tests - will be able to test after landing:
1118         https://bugs.webkit.org/show_bug.cgi?id=91775
1119
1120         Adding new files to build files:
1121         * CMakeLists.txt:
1122         * DerivedSources.cpp:
1123         * DerivedSources.make:
1124         * DerivedSources.pri:
1125         * GNUmakefile.list.am:
1126         * Target.pri:
1127         * WebCore.gypi:
1128         * WebCore.vcproj/WebCore.vcproj:
1129         * WebCore.xcodeproj/project.pbxproj:
1130
1131         New MediaSource object:
1132         * Modules/mediasource/MediaSource.cpp: Added.
1133         * Modules/mediasource/MediaSource.h: Added.
1134         * Modules/mediasource/MediaSource.idl: Added.
1135
1136         Create a registry for the blob storage and lookup:
1137         * Modules/mediasource/MediaSourceRegistry.cpp: Added.
1138         * Modules/mediasource/MediaSourceRegistry.h: Added.
1139
1140         Connect SourceBuffer to MediaSource:
1141         * Modules/mediasource/SourceBuffer.cpp:
1142         (WebCore::SourceBuffer::SourceBuffer):
1143         (WebCore::SourceBuffer::buffered): Forward call to MediaSource.
1144         (WebCore::SourceBuffer::append): Ditto.
1145         (WebCore::SourceBuffer::abort): Ditto.
1146         * Modules/mediasource/SourceBuffer.h:
1147         (WebCore::SourceBuffer::create): Add a MediaSource to the constructor.
1148         (WebCore::SourceBuffer::clear): Clear the MediaSource.
1149         (SourceBuffer):
1150         * Modules/mediasource/SourceBufferList.cpp: include SourceBuffer.h
1151         * Modules/mediasource/SourceBufferList.h:
1152
1153         Make MediaSource an EventTarget:
1154         * dom/EventTarget.h:
1155         (WebCore):
1156         * dom/EventTargetFactory.in:
1157
1158         Enable creation of MediaSource object URL from JavaScript:
1159         * html/DOMURL.cpp:
1160         (WebCore):
1161         (WebCore::DOMURL::createObjectURL):
1162         (WebCore::DOMURL::revokeObjectURL):
1163         * html/DOMURL.h:
1164         (WebCore):
1165         (DOMURL):
1166         * html/DOMURL.idl:
1167         * html/PublicURLManager.h: create a new sourceURLs list for storing
1168             reigstered MediaSource URLS.
1169         (WebCore::PublicURLManager::contextDestroyed): make sure everything is
1170             removed from the sourceURLs list upon destruction.
1171         (PublicURLManager):
1172         (WebCore::PublicURLManager::sourceURLs): getter for the sourceURLs list.
1173
1174         New MediaSource constructor:
1175         * page/DOMWindow.idl:
1176
1177 2012-08-07  Kentaro Hara  <haraken@chromium.org>
1178
1179         [V8] Implement V8Proxy::registerExtensionIfNeeded() and remove redundant methods
1180         https://bugs.webkit.org/show_bug.cgi?id=93209
1181
1182         Reviewed by Adam Barth.
1183
1184         By implementing V8Proxy::registerExtensionIfNeeded(), we can remove
1185         registeredExtensionWithV8() and registerExtension().
1186
1187         No tests. No change in behavior.
1188
1189         * bindings/v8/V8DOMWindowShell.cpp:
1190         (WebCore::V8DOMWindowShell::createNewContext):
1191         * bindings/v8/V8Proxy.cpp:
1192         (WebCore::V8Proxy::registerExtensionIfNeeded):
1193         * bindings/v8/V8Proxy.h:
1194         (V8Proxy):
1195
1196 2012-08-07  Ryuan Choi  <ryuan.choi@samsung.com>
1197
1198         [EFL] Remove PlatformTouchEventEfl and PlatformTouchPointEfl
1199         https://bugs.webkit.org/show_bug.cgi?id=93270
1200
1201         Reviewed by Eric Seidel.
1202
1203         PlatformTouchEventEfl and PlatformTouchPointEfl initialize PlatformTouchEvent
1204         directly from Ewk_TouchEvent which is WebKit1/Efl API and they can not be
1205         shared with WebKit2/Efl.
1206
1207         In order to remove this WebKit dependency from WebCore, this patch removes Efl
1208         specific codes from PlatformTouchXXX and adds the classes which convert
1209         Ewk_Touch_XXX to PlatformTouchXXX.
1210
1211         No new tests. Just a refactoring.
1212
1213         * PlatformEfl.cmake: Removed PlatformTouchEventEfl.cpp and PlatformTouchPointEfl.cpp
1214         * platform/PlatformTouchEvent.h: Removed Efl specific codes.
1215         (PlatformTouchEvent):
1216         * platform/PlatformTouchPoint.h: Ditto.
1217         (PlatformTouchPoint):
1218         * platform/efl/PlatformTouchEventEfl.cpp: Removed.
1219         * platform/efl/PlatformTouchPointEfl.cpp: Removed.
1220
1221 2012-08-07  James Robinson  <jamesr@chromium.org>
1222
1223         [chromium] Avoid dependending on implicit WebString -> String conversion in compositor
1224         https://bugs.webkit.org/show_bug.cgi?id=93408
1225
1226         Reviewed by Adrienne Walker.
1227
1228         * platform/graphics/chromium/LayerRendererChromium.cpp:
1229         (WebCore::LayerRendererChromium::initialize):
1230         * platform/graphics/chromium/cc/CCResourceProvider.cpp:
1231         (WebCore::CCResourceProvider::initialize):
1232
1233 2012-08-07  Kentaro Hara  <haraken@chromium.org>
1234
1235         [V8] Factor out V8Binding methods that configures DOM attributes and methods
1236         https://bugs.webkit.org/show_bug.cgi?id=93239
1237
1238         Reviewed by Adam Barth.
1239
1240         V8Binding is messy. This patch factors out V8Binding methods that configures
1241         DOM attributes and methods into another file. This patch just moves the methods
1242         from V8Binding.{h,cpp} to V8ConfigureDOMAttributesAndMethods.{h,cpp}.
1243
1244         No tests. No change in behavior.
1245
1246         * UseV8.cmake:
1247         * WebCore.gypi:
1248         * bindings/v8/V8Binding.cpp:
1249         * bindings/v8/V8Binding.h:
1250         (WebCore):
1251         * bindings/v8/V8ConfigureDOMAttributesAndMethods.cpp: Added.
1252         (WebCore):
1253         (WebCore::batchConfigureAttributes):
1254         (WebCore::batchConfigureConstants):
1255         (WebCore::batchConfigureCallbacks):
1256         (WebCore::configureTemplate):
1257         * bindings/v8/V8ConfigureDOMAttributesAndMethods.h: Added.
1258         (WebCore):
1259         (BatchedAttribute):
1260         (WebCore::configureAttribute):
1261         (BatchedConstant):
1262         (BatchedCallback):
1263
1264 2012-08-07  Kentaro Hara  <haraken@chromium.org>
1265
1266         [V8] Replace all V8 undefined values in the rest of custom bindings with v8Undefined()
1267         https://bugs.webkit.org/show_bug.cgi?id=93220
1268
1269         Reviewed by Eric Seidel.
1270
1271         We should use v8Undefined() everywhere in V8 bindings.
1272         This patch replaces all V8 undefined values in the rest of custom bindings
1273         with v8Undefined().
1274
1275         No tests. No change in behavior.
1276
1277         * bindings/v8/custom/V8DOMStringMapCustom.cpp:
1278         (WebCore::V8DOMStringMap::namedPropertyQuery): Simple refactoring not related to
1279         this patch. Since other bindings are using 0 instead of v8::None, we should use 0 here too.
1280         * bindings/v8/custom/V8DOMWindowCustom.cpp:
1281         (WebCore::toV8):
1282         * bindings/v8/custom/V8ScriptProfileCustom.cpp:
1283         (WebCore::toV8):
1284         * bindings/v8/custom/V8ScriptProfileNodeCustom.cpp:
1285         (WebCore::toV8):
1286
1287 2012-08-07  Kentaro Hara  <haraken@chromium.org>
1288
1289         [V8] Remove #include V8BindingMacros.h
1290         https://bugs.webkit.org/show_bug.cgi?id=93312
1291
1292         Reviewed by Eric Seidel.
1293
1294         We are factoring out V8Binding methods to separate files.
1295         After the refactoring, V8Binding.h will include binding related
1296         header files (e.g. V8BindingMacros.h, V8BindingHelper.h, etc), so that
1297         custom V8 binding files just need to include V8Binding.h only.
1298
1299         We can remove '#include V8BindingMacros.h' from V8 binding files.
1300
1301         No tests. No change in behavior.
1302
1303         * bindings/scripts/CodeGeneratorV8.pm:
1304         (GenerateNormalAttrSetter):
1305         (GenerateParametersCheck):
1306         (GenerateEventConstructorCallback):
1307         (ConvertToV8Parameter):
1308         * bindings/scripts/test/V8/V8Float64Array.cpp:
1309         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
1310         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
1311         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
1312         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
1313         * bindings/scripts/test/V8/V8TestInterface.cpp:
1314         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
1315         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
1316         * bindings/scripts/test/V8/V8TestObj.cpp:
1317         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
1318         * bindings/v8/ScriptController.cpp:
1319         * bindings/v8/custom/V8BlobCustom.cpp:
1320         * bindings/v8/custom/V8ConsoleCustom.cpp:
1321         * bindings/v8/custom/V8DOMWindowCustom.cpp:
1322         * bindings/v8/custom/V8DataViewCustom.cpp:
1323         * bindings/v8/custom/V8DeviceMotionEventCustom.cpp:
1324         * bindings/v8/custom/V8DeviceOrientationEventCustom.cpp:
1325         * bindings/v8/custom/V8DirectoryEntryCustom.cpp:
1326         * bindings/v8/custom/V8DirectoryEntrySyncCustom.cpp:
1327         * bindings/v8/custom/V8IntentConstructor.cpp:
1328         * bindings/v8/custom/V8MutationObserverCustom.cpp:
1329         * bindings/v8/custom/V8PerformanceCustom.cpp:
1330         * bindings/v8/custom/V8SQLTransactionCustom.cpp:
1331         * bindings/v8/custom/V8SQLTransactionSyncCustom.cpp:
1332         * bindings/v8/custom/V8SVGLengthCustom.cpp:
1333         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
1334         * bindings/v8/custom/V8WebKitAnimationCustom.cpp:
1335         * bindings/v8/custom/V8WorkerContextCustom.cpp:
1336
1337 2012-08-07  Kentaro Hara  <haraken@chromium.org>
1338
1339         [V8] Remove #include Frame.h from V8Binding.h
1340         https://bugs.webkit.org/show_bug.cgi?id=93326
1341
1342         Reviewed by Adam Barth.
1343
1344         We want to remove unnecessary #include in V8Binding.h
1345         to avoid circular include dependency.
1346
1347         No tests. No change in behavior.
1348
1349         * bindings/scripts/CodeGeneratorV8.pm:
1350         (GenerateDomainSafeFunctionGetter):
1351         (GenerateNormalAttrGetter):
1352         (GenerateReplaceableAttrSetter):
1353         (GenerateFunctionCallback):
1354         (GenerateNamedConstructorCallback):
1355         (GenerateToV8Converters):
1356         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
1357         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
1358         * bindings/scripts/test/V8/V8TestNode.cpp:
1359         * bindings/v8/ScheduledAction.cpp:
1360         * bindings/v8/V8Binding.h:
1361         * bindings/v8/V8DOMWrapper.cpp:
1362         * bindings/v8/custom/V8DocumentCustom.cpp:
1363         * bindings/v8/custom/V8SVGDocumentCustom.cpp:
1364         * testing/v8/WebCoreTestSupport.cpp:
1365
1366 2012-08-07  Kentaro Hara  <haraken@chromium.org>
1367
1368         [V8] Factor out V8Binding classes that manage V8 value's cache
1369         https://bugs.webkit.org/show_bug.cgi?id=93343
1370
1371         Reviewed by Adam Barth.
1372
1373         We are factoring out V8Binding methods to separate files.
1374         This patch moves V8Binding classes that manage V8 value's cache
1375         to V8ValueCache.{h,cpp}.
1376
1377         No tests. No change in behavior.
1378
1379         * UseV8.cmake:
1380         * WebCore.gypi:
1381         * bindings/v8/V8Binding.cpp:
1382         * bindings/v8/V8Binding.h:
1383         (WebCore):
1384         * bindings/v8/V8ValueCache.cpp: Added.
1385         (WebCore):
1386         (WebCore::makeExternalString):
1387         (WebCore::cachedStringCallback):
1388         (WebCore::StringCache::remove):
1389         (WebCore::StringCache::v8ExternalStringSlow):
1390         (WebCore::IntegerCache::createSmallIntegers):
1391         (WebCore::IntegerCache::~IntegerCache):
1392         * bindings/v8/V8ValueCache.h: Added.
1393         (WebCore):
1394         (StringCache):
1395         (WebCore::StringCache::StringCache):
1396         (WebCore::StringCache::v8ExternalString):
1397         (WebCore::StringCache::clearOnGC):
1398         (WebCoreStringResource):
1399         (WebCore::WebCoreStringResource::WebCoreStringResource):
1400         (WebCore::WebCoreStringResource::~WebCoreStringResource):
1401         (WebCore::WebCoreStringResource::data):
1402         (WebCore::WebCoreStringResource::length):
1403         (WebCore::WebCoreStringResource::webcoreString):
1404         (WebCore::WebCoreStringResource::atomicString):
1405         (WebCore::WebCoreStringResource::visitStrings): This method is used by inspector
1406         and thus is not performance-critical. To avoid circular #include dependency,
1407         I moved the implementation to cpp.
1408         (WebCore::WebCoreStringResource::toStringResource):
1409         (IntegerCache):
1410         (WebCore::IntegerCache::IntegerCache):
1411         (WebCore::IntegerCache::v8Integer):
1412         (WebCore::IntegerCache::v8UnsignedInteger):
1413
1414 2012-08-07  James Robinson  <jamesr@chromium.org>
1415
1416         [chromium] Switch PlatformLayer typedef to Platform API type for PLATFORM(CHROMIUM)
1417         https://bugs.webkit.org/show_bug.cgi?id=93335
1418
1419         Reviewed by Adrienne Walker.
1420
1421         This converts the PlatformLayer typedef to WebKit::WebLayer (part of the chromium Platform API) for the
1422         Chromium port. This involves some odd const_cast<>s in places since cross-platform interfaces assume that
1423         PlatformLayer is a potentially heavy implementation class, but WebLayer is a thin smart pointer type.
1424
1425         * page/scrolling/chromium/ScrollingCoordinatorChromium.cpp:
1426         (WebCore::createScrollbarLayer):
1427         (WebCore::ScrollingCoordinator::setScrollLayer):
1428         (WebCore::ScrollingCoordinator::setNonFastScrollableRegion):
1429         (WebCore::ScrollingCoordinator::setLayerIsContainerForFixedPositionLayers):
1430         (WebCore::ScrollingCoordinator::setLayerIsFixedToContainerLayer):
1431         * platform/graphics/PlatformLayer.h:
1432         (WebKit):
1433         (WebCore):
1434         * platform/graphics/chromium/Canvas2DLayerBridge.cpp:
1435         (WebCore::Canvas2DLayerBridge::layer):
1436         * platform/graphics/chromium/Canvas2DLayerBridge.h:
1437         (Canvas2DLayerBridge):
1438         * platform/graphics/chromium/DrawingBufferChromium.cpp:
1439         (WebCore::DrawingBufferPrivate::layer):
1440         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
1441         (WebCore::GraphicsLayerChromium::removeFromParent):
1442         (WebCore::GraphicsLayerChromium::setDrawsContent):
1443         (WebCore::GraphicsLayerChromium::setContentsVisible):
1444         (WebCore::GraphicsLayerChromium::setMaskLayer):
1445         (WebCore::GraphicsLayerChromium::setContentsToCanvas):
1446         (WebCore::GraphicsLayerChromium::setContentsToMedia):
1447         (WebCore::GraphicsLayerChromium::primaryLayer):
1448         (WebCore::GraphicsLayerChromium::platformLayer):
1449         (WebCore::GraphicsLayerChromium::updateChildList):
1450         * platform/graphics/chromium/GraphicsLayerChromium.h:
1451         (GraphicsLayerChromium):
1452
1453 2012-08-07  James Robinson  <jamesr@chromium.org>
1454
1455         [chromium] Use WebCompositor interface in Platform API instead of CCProxy to query threaded compositor status
1456         https://bugs.webkit.org/show_bug.cgi?id=93398
1457
1458         Reviewed by Adam Barth.
1459
1460         Converts non-compositor code that cares about threaded compositing status over to query WebCompositor instead of
1461         CCProxy.
1462
1463         * page/scrolling/chromium/ScrollingCoordinatorChromium.cpp:
1464         * platform/chromium/support/WebCompositorImpl.cpp:
1465         (WebKit):
1466         (WebKit::WebCompositor::threadingEnabled):
1467         (WebKit::WebCompositor::onCompositorThread):
1468         (WebKit::WebCompositorImpl::threadingEnabled):
1469         * platform/chromium/support/WebCompositorImpl.h:
1470         (WebCompositorImpl):
1471         * platform/graphics/chromium/Canvas2DLayerBridge.cpp:
1472         (WebCore::Canvas2DLayerBridge::Canvas2DLayerBridge):
1473         * platform/graphics/chromium/DrawingBufferChromium.cpp:
1474         (WebCore::DrawingBuffer::DrawingBuffer):
1475
1476 2012-08-07  Anders Carlsson  <andersca@apple.com>
1477
1478         Knob slot animation is flipped
1479         https://bugs.webkit.org/show_bug.cgi?id=93396
1480
1481         Reviewed by Beth Dakin.
1482
1483         When painting the scrollbar knob slot, use rectForPart: since it correctly takes the expansion transition state into account.
1484
1485         * platform/mac/ScrollbarThemeMac.mm:
1486         (WebCore::scrollbarPainterPaint):
1487
1488 2012-08-07  Adrienne Walker  <enne@google.com>
1489
1490         50% fixed position coverage slow scroll heuristic is incorrect when invalidations aren't clipped
1491         https://bugs.webkit.org/show_bug.cgi?id=92011
1492
1493         Reviewed by Simon Fraser.
1494
1495         The heuristic in scrollContentsFastPath to slow scroll by invalidating
1496         the entire frame if fixed position elements cover 50% of the frame
1497         takes away the ability of ports to make their own decisions about how
1498         to best handle invalidations. Therefore, remove this heuristic.
1499
1500         * page/FrameView.cpp:
1501         (WebCore::FrameView::scrollContentsFastPath):
1502
1503 2012-08-07  Konrad Piascik  <kpiascik@rim.com>
1504
1505         [BlackBerry] Change how devicePixelRatio is set.
1506         https://bugs.webkit.org/show_bug.cgi?id=93385
1507
1508         Reviewed by Antonio Gomes.
1509
1510         Update the theme to adjust to a constant devicePixelRatio.
1511
1512         Not testable.
1513
1514         * platform/blackberry/RenderThemeBlackBerry.cpp:
1515         (WebCore::determineFullScreenMultiplier):
1516
1517 2012-08-07  James Robinson  <jamesr@chromium.org>
1518
1519         [chromium] Move WebCompositor interface into Platform API
1520         https://bugs.webkit.org/show_bug.cgi?id=93391
1521
1522         Reviewed by Adam Barth.
1523
1524         Moves the support files for WebCompositor into WebCore/platform/support/. CCThreadImpl is a helper class used
1525         only by WebCompositorImpl.
1526
1527         Refactor/renaming only, so no new tests.
1528
1529         * WebCore.gypi:
1530         * platform/chromium/support/CCThreadImpl.cpp: Renamed from Source/WebKit/chromium/src/CCThreadImpl.cpp.
1531         (WebKit):
1532         (GetThreadIDTask):
1533         (WebKit::GetThreadIDTask::GetThreadIDTask):
1534         (WebKit::GetThreadIDTask::~GetThreadIDTask):
1535         (WebKit::GetThreadIDTask::run):
1536         (CCThreadTaskAdapter):
1537         (WebKit::CCThreadTaskAdapter::CCThreadTaskAdapter):
1538         (WebKit::CCThreadTaskAdapter::~CCThreadTaskAdapter):
1539         (WebKit::CCThreadTaskAdapter::run):
1540         (WebKit::CCThreadImpl::create):
1541         (WebKit::CCThreadImpl::~CCThreadImpl):
1542         (WebKit::CCThreadImpl::postTask):
1543         (WebKit::CCThreadImpl::postDelayedTask):
1544         (WebKit::CCThreadImpl::threadID):
1545         (WebKit::CCThreadImpl::CCThreadImpl):
1546         * platform/chromium/support/CCThreadImpl.h: Renamed from Source/WebKit/chromium/src/CCThreadImpl.h.
1547         (WebKit):
1548         (CCThreadImpl):
1549         * platform/chromium/support/WebCompositorImpl.cpp: Renamed from Source/WebKit/chromium/src/WebCompositorImpl.cpp.
1550         (WebKit):
1551         (WebKit::WebCompositor::initialize):
1552         (WebKit::WebCompositor::shutdown):
1553         (WebKit::WebCompositor::setPerTilePaintingEnabled):
1554         (WebKit::WebCompositor::setPartialSwapEnabled):
1555         (WebKit::WebCompositor::setAcceleratedAnimationEnabled):
1556         (WebKit::WebCompositorImpl::initialize):
1557         (WebKit::WebCompositorImpl::initialized):
1558         (WebKit::WebCompositorImpl::shutdown):
1559         * platform/chromium/support/WebCompositorImpl.h: Renamed from Source/WebKit/chromium/src/WebCompositorImpl.h.
1560         (WebCore):
1561         (WebKit):
1562         (WebCompositorImpl):
1563
1564 2012-08-07  Abhishek Arya  <inferno@chromium.org>
1565
1566         Crash in ContainerNode::cloneChildNodes.
1567         https://bugs.webkit.org/show_bug.cgi?id=93378
1568
1569         Reviewed by Levi Weintraub.
1570
1571         Re-enabling the editing delete button controller in cloneChildNode was causing style changes,
1572         thereby causing load events to fire. The load event can blow our nodes from underneath. This causes
1573         crashes when we are nested inside cloneChildNodes. The patch just skips the delete button controller's
1574         container element from being cloned and removes the hacky enable/disable logic. 
1575
1576         Test: fast/dom/clone-node-load-event-crash.html
1577
1578         * dom/ContainerNode.cpp:
1579         (WebCore::ContainerNode::cloneChildNodes):
1580
1581 2012-08-07  No'am Rosenthal  <noam.rosenthal@nokia.com>
1582
1583         GraphicsLayerAnimation shouldn't use HashMap<String>
1584         https://bugs.webkit.org/show_bug.cgi?id=93284
1585
1586         Reviewed by Kenneth Rohde Christiansen.
1587
1588         Use a vector containing all the animations instead of a map of String to Vector.
1589         The HashMap contains very few elements, which makes it inefficient relatively to a vector.
1590         This has been shown to be a bottleneck in valgrind.
1591
1592         Covered by existing animation tests.
1593
1594         * platform/graphics/GraphicsLayerAnimation.cpp:
1595         (WebCore::GraphicsLayerAnimation::GraphicsLayerAnimation):
1596         (WebCore::GraphicsLayerAnimations::hasActiveAnimationsOfType):
1597         (WebCore::GraphicsLayerAnimations::hasRunningAnimations):
1598         (WebCore::GraphicsLayerAnimations::add):
1599         (WebCore::GraphicsLayerAnimations::pause):
1600         (WebCore::GraphicsLayerAnimations::remove):
1601         (WebCore::GraphicsLayerAnimations::apply):
1602         * platform/graphics/GraphicsLayerAnimation.h:
1603         (GraphicsLayerAnimation):
1604         (WebCore::GraphicsLayerAnimation::name):
1605         (GraphicsLayerAnimations):
1606         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
1607         (WebCore::GraphicsLayerTextureMapper::addAnimation):
1608
1609 2012-08-07  Marcelo Lira  <marcelo.lira@openbossa.org>
1610
1611         [Qt] Add support for the Gamepad API
1612         https://bugs.webkit.org/show_bug.cgi?id=90637
1613
1614         Reviewed by Alexis Menard.
1615
1616         Adds support for Gamepad API on the Qt port.
1617
1618         The implementation of this class relies on the Linux
1619         kernel joystick API.
1620
1621         Gamepad devices are recognized through the GamepadsQt
1622         class, which uses the udev library to watch for connection,
1623         disconnection and other gamepad related events.
1624
1625         Tests for this feature already exist.
1626
1627         * DerivedSources.pri:
1628         * Target.pri:
1629         * WebCore.pri:
1630         * platform/qt/GamepadsQt.cpp: Added.
1631         (WebCore):
1632         (GamepadDeviceLinuxQt):
1633         (WebCore::GamepadDeviceLinuxQt::create):
1634         (WebCore::GamepadDeviceLinuxQt::GamepadDeviceLinuxQt):
1635         (WebCore::GamepadDeviceLinuxQt::~GamepadDeviceLinuxQt):
1636         (WebCore::GamepadDeviceLinuxQt::readCallback):
1637         (GamepadsQt):
1638         (WebCore::GamepadsQt::GamepadsQt):
1639         (WebCore::GamepadsQt::~GamepadsQt):
1640         (WebCore::GamepadsQt::isGamepadDevice):
1641         (WebCore::GamepadsQt::onGamePadChange):
1642         (WebCore::GamepadsQt::registerDevice):
1643         (WebCore::GamepadsQt::unregisterDevice):
1644         (WebCore::GamepadsQt::updateGamepadList):
1645         (WebCore::sampleGamepads):
1646
1647 2012-08-07  Mike Reed  <reed@google.com>
1648
1649         reimplement fastMod w/o (soon to be) private skia macros
1650         https://bugs.webkit.org/show_bug.cgi?id=93370
1651
1652         Reviewed by Adrienne Walker.
1653
1654         fastMod() reimplemented (same functionality) to stop using soon-to-be private macros in
1655         SkMath.h. The new version is functionally identical.
1656
1657         No new tests -- existing layouttests exercise GraphicsContext::strokeArc(), the only caller
1658
1659         * platform/graphics/skia/GraphicsContextSkia.cpp:
1660
1661 2012-08-07  Brian Anderson  <brianderson@chromium.org>
1662
1663         Add CCDelayBasedTimeSource::setTimebaseAndInterval
1664         https://bugs.webkit.org/show_bug.cgi?id=92825
1665
1666         Reviewed by James Robinson.
1667
1668         Allows CCDelayBaseTimeSource to have it's timebase and interval updated
1669         on the fly.  Accounts for double ticking due to jitter or resetting the
1670         timer multiple times quickly.
1671
1672         CCDelayBasedTimeSourceTest updated with two tests for proper handling
1673         of jittery timebase/interval source and immediate handling of
1674         significant timebase/interval changes.
1675
1676         * platform/graphics/chromium/cc/CCDelayBasedTimeSource.cpp:
1677         (WebCore::CCDelayBasedTimeSource::CCDelayBasedTimeSource):
1678         (WebCore::CCDelayBasedTimeSource::nextTickTime):
1679         (WebCore):
1680         (WebCore::CCDelayBasedTimeSource::onTimerFired):
1681         (WebCore::CCDelayBasedTimeSource::setTimebaseAndInterval):
1682         (WebCore::CCDelayBasedTimeSource::postNextTickTask):
1683         * platform/graphics/chromium/cc/CCDelayBasedTimeSource.h:
1684
1685 2012-07-23  Alexandru Chiculita  <achicu@adobe.com>
1686
1687         [CSS Shaders] Reuse precompiled shaders across elements
1688         https://bugs.webkit.org/show_bug.cgi?id=88427
1689
1690         Reviewed by Dean Jackson.
1691
1692         Added CustomFilterProgramInfo as a link between the CustomFilterProgram and the CustomFilterCompiledProgram.
1693         CustomFilterGlobalContext now acts as a cache for the compiled shaders. Note that only the shaders displayed on the page
1694         are cached, making it useful in animations or when more elements share the same shader filter.
1695
1696         For CSS Shaders we need two files, vertex and fragment shaders, so that's why we have a CustomFilterProgram. 
1697         CustomFilterProgram is the platform object, so StyleCustomFilterProgram implements it and is referenced from the RenderStyle.
1698
1699         StyleCustomFilterProgram is also the one that actually keeps references to the CachedShaders and has all the loading logic.
1700         The only problem is that there might be multiple StyleCustomFilterProgram with the same set of CachedShaders.
1701         That's why in this patch I've added CustomFilterProgramInfo as a simple class to be used as a key in a hash map.
1702
1703         For now CustomFilterProgramInfo should act similar to a pair<String, String>. There's only one exception: one of the strings
1704         is allowed to be null. A null string is the placeholder for the default shader.
1705
1706         Note that alpha compositing and blending will be added to the CustomFilterProgramInfo after the mix() 
1707         function parsing will land in https://bugs.webkit.org/show_bug.cgi?id=90101 .
1708
1709         Test: css3/filters/custom/custom-filter-shader-reuse.html
1710
1711         * CMakeLists.txt:
1712         * GNUmakefile.list.am:
1713         * WebCore.gypi:
1714         * WebCore.vcproj/WebCore.vcproj:
1715         * WebCore.xcodeproj/project.pbxproj:
1716         * platform/graphics/filters/CustomFilterCompiledProgram.cpp:
1717         (WebCore::CustomFilterCompiledProgram::CustomFilterCompiledProgram):
1718         (WebCore::CustomFilterCompiledProgram::getDefaultShaderString): Returns the default shader based on the type.
1719         (WebCore):
1720         (WebCore::CustomFilterCompiledProgram::compileShader): Added check for isNull and used the default shader in that case.
1721         (WebCore::CustomFilterCompiledProgram::~CustomFilterCompiledProgram): Added call to CustomFilterGlobalContext::removeCompiledProgram.
1722         * platform/graphics/filters/CustomFilterCompiledProgram.h:
1723         (WebCore::CustomFilterCompiledProgram::detachFromGlobalContext): Called from ~CustomFilterGlobalContext, so that it doesn't call into a deleted object later when ~CustomFilterCompiledProgram is called. It should only happen when CustomFilterGlobalContext dies before the 
1724         CustomFilterCompiledPrograms that it caches.
1725         (WebCore):
1726         * platform/graphics/filters/CustomFilterGlobalContext.cpp:
1727         (WebCore::CustomFilterGlobalContext::~CustomFilterGlobalContext):
1728         (WebCore::CustomFilterGlobalContext::getCompiledProgram): Gets or creates a compiled shader for a specific CustomFilterProgramInfo.
1729         (WebCore):
1730         (WebCore::CustomFilterGlobalContext::removeCompiledProgram): Called by ~CustomFilterCompiledProgram.
1731         * platform/graphics/filters/CustomFilterGlobalContext.h:
1732         (WebCore):
1733         (CustomFilterGlobalContext):
1734         * platform/graphics/filters/CustomFilterProgram.cpp:
1735         (WebCore::CustomFilterProgram::programInfo):
1736         * platform/graphics/filters/CustomFilterProgram.h:
1737         (WebCore):
1738         * platform/graphics/filters/CustomFilterProgramInfo.cpp: Added.
1739         (WebCore):
1740         (WebCore::hashPossiblyNullString): We need to allow null strings in the hash, so this is a helper to check for isNull 
1741         before asking for the hash.
1742         (WebCore::CustomFilterProgramInfo::CustomFilterProgramInfo):
1743         (WebCore::CustomFilterProgramInfo::isEmptyValue):
1744         (WebCore::CustomFilterProgramInfo::isHashTableDeletedValue):
1745         (WebCore::CustomFilterProgramInfo::hash):
1746         (WebCore::CustomFilterProgramInfo::operator==):
1747         * platform/graphics/filters/CustomFilterProgramInfo.h: Added.
1748         (WebCore):
1749         (CustomFilterProgramInfo):
1750         (WebCore::CustomFilterProgramInfo::vertexShaderString):
1751         (WebCore::CustomFilterProgramInfo::fragmentShaderString):
1752         (WebCore::CustomFilterProgramInfoHash::hash):
1753         (WebCore::CustomFilterProgramInfoHash::equal):
1754         (CustomFilterProgramInfoHash): Structures needed to make this a key in the hash map.
1755         (CustomFilterProgramInfoHashTraits):
1756         (WebCore::CustomFilterProgramInfoHashTraits::isEmptyValue): I've used the deleted strings value to mark a deleted
1757         CustomFilterProgramInfo object. Those are not safe to compare to deleted, so there's a need to set safeToCompareToEmptyOrDeleted to false, meaning that there's a need to manually check for empty values.
1758         (WTF):
1759         * platform/graphics/filters/FECustomFilter.cpp:
1760         (WebCore::FECustomFilter::initializeContext): Moved to using the cached shader instead.
1761
1762 2012-08-07  Florin Malita  <fmalita@chromium.org>
1763
1764         [Chromium] Unreviewed build fix after r124879.
1765
1766         * WebCore.gypi: Remove deleted file references.
1767
1768 2012-08-07  George Staikos  <staikos@webkit.org>
1769
1770         [BlackBerry] We should fail the HTTP auth silently for non-main loads
1771         in the non-viewer process.
1772         https://bugs.webkit.org/show_bug.cgi?id=93230
1773
1774         Reviewed by Rob Buis.
1775
1776         No way to test this in WebKit.
1777
1778         * platform/network/blackberry/NetworkJob.cpp: Add early return.
1779         (WebCore::NetworkJob::sendRequestWithCredentials):
1780
1781 2012-08-07  Alexander Pavlov  <apavlov@chromium.org>
1782
1783         Web Inspector: Typing backslash in Console traverses the panel history when using German keyboard layout
1784         https://bugs.webkit.org/show_bug.cgi?id=93357
1785
1786         Reviewed by Vsevolod Vlasov.
1787
1788         For some reason, in the German keyboard layout keyIdentifier for '\' is the same as that for '['
1789         in the ordinary English-US layout.
1790         Remove a too-safe-side check and never switch panels on key combinations that result in "keypress" events.
1791
1792         * inspector/front-end/InspectorView.js:
1793         (WebInspector.InspectorView):
1794         (WebInspector.InspectorView.prototype._keyPress):
1795
1796 2012-08-07  Robin Cao  <robin.cao@torchmobile.com.cn>
1797
1798         [BlackBerry] GL scissor test is accidentally turned off
1799         https://bugs.webkit.org/show_bug.cgi?id=93360
1800         PR #161020
1801
1802         Reviewed by Antonio Gomes.
1803
1804         The GL scissor test is accidentally turned off inside drawTextures().
1805         This is wrong and should be removed.
1806
1807         * platform/graphics/blackberry/LayerCompositingThread.cpp:
1808         (WebCore::LayerCompositingThread::drawTextures):
1809
1810 2012-08-07  Abhishek Arya  <inferno@chromium.org>
1811
1812         Crash in InlineFlowBox::deleteLine.
1813         https://bugs.webkit.org/show_bug.cgi?id=88795
1814
1815         Reviewed by Tony Chang.
1816
1817         When we move the fullscreen object from its parent to RenderFullScreen, we forgot to clear the
1818         line box tree underneath the object's containing block and mark it for layout. Before the patch,
1819         the containing block never got laid out and maintained references to removed line boxes (since the
1820         object moved under RenderFullScreen did get laid out and its lineboxes replaced with new ones).
1821
1822         Test: fullscreen/full-screen-line-boxes-crash.html
1823
1824         * rendering/RenderFullScreen.cpp:
1825         (RenderFullScreen::wrapRenderer):
1826
1827 2012-08-07  Vsevolod Vlasov  <vsevik@chromium.org>
1828
1829         Web Inspector: Do not disable network tracking while profiling cpu.
1830         https://bugs.webkit.org/show_bug.cgi?id=93359
1831
1832         Reviewed by Yury Semikhatsky.
1833
1834         Removed network tracking enabling/disabling machinery.
1835
1836         * inspector/front-end/CPUProfileView.js:
1837         (WebInspector.CPUProfileType.prototype.buttonClicked):
1838         * inspector/front-end/NetworkManager.js:
1839         (WebInspector.NetworkManager.get this):
1840         (WebInspector.NetworkManager.get NetworkAgent):
1841         (WebInspector.NetworkManager):
1842         * inspector/front-end/ResourceTreeModel.js:
1843         (WebInspector.ResourceTreeModel):
1844
1845 2012-08-07  Alexei Filippov  <alexeif@chromium.org>
1846
1847         Web Inspector: make the MemoryClassInfo class a not-template
1848         https://bugs.webkit.org/show_bug.cgi?id=93265
1849
1850         Reviewed by Yury Semikhatsky.
1851
1852         * bindings/js/ScriptWrappable.h:
1853         (WebCore::ScriptWrappable::reportMemoryUsage):
1854         * bindings/v8/DOMDataStore.cpp:
1855         (WebCore::DOMDataStore::reportMemoryUsage):
1856         * bindings/v8/IntrusiveDOMWrapperMap.h:
1857         (WebCore::ChunkedTable::reportMemoryUsage):
1858         * bindings/v8/ScriptWrappable.h:
1859         (WebCore::ScriptWrappable::reportMemoryUsage):
1860         * bindings/v8/V8Binding.cpp:
1861         (WebCore::V8BindingPerIsolateData::reportMemoryUsage):
1862         (WebCore::StringCache::reportMemoryUsage):
1863         * bindings/v8/V8DOMMap.h:
1864         * css/CSSAspectRatioValue.cpp:
1865         (WebCore::CSSAspectRatioValue::reportDescendantMemoryUsage):
1866         * css/CSSBorderImageSliceValue.cpp:
1867         (WebCore::CSSBorderImageSliceValue::reportDescendantMemoryUsage):
1868         * css/CSSCalculationValue.cpp:
1869         (WebCore::CSSCalcValue::reportDescendantMemoryUsage):
1870         * css/CSSCanvasValue.cpp:
1871         (WebCore::CSSCanvasValue::reportDescendantMemoryUsage):
1872         * css/CSSCharsetRule.cpp:
1873         (WebCore::CSSCharsetRule::reportDescendantMemoryUsage):
1874         * css/CSSComputedStyleDeclaration.cpp:
1875         (WebCore::CSSComputedStyleDeclaration::reportMemoryUsage):
1876         * css/CSSCrossfadeValue.cpp:
1877         (WebCore::CSSCrossfadeValue::reportDescendantMemoryUsage):
1878         * css/CSSCursorImageValue.cpp:
1879         (WebCore::CSSCursorImageValue::reportDescendantMemoryUsage):
1880         * css/CSSFontFaceRule.cpp:
1881         (WebCore::CSSFontFaceRule::reportDescendantMemoryUsage):
1882         * css/CSSFontFaceSrcValue.cpp:
1883         (WebCore::CSSFontFaceSrcValue::reportDescendantMemoryUsage):
1884         * css/CSSFunctionValue.cpp:
1885         (WebCore::CSSFunctionValue::reportDescendantMemoryUsage):
1886         * css/CSSGradientValue.cpp:
1887         (WebCore::CSSGradientColorStop::reportMemoryUsage):
1888         (WebCore::CSSGradientValue::reportBaseClassMemoryUsage):
1889         (WebCore::CSSLinearGradientValue::reportDescendantMemoryUsage):
1890         (WebCore::CSSRadialGradientValue::reportDescendantMemoryUsage):
1891         * css/CSSImageGeneratorValue.cpp:
1892         (WebCore::CSSImageGeneratorValue::reportBaseClassMemoryUsage):
1893         * css/CSSImageSetValue.cpp:
1894         (WebCore::CSSImageSetValue::reportDescendantMemoryUsage):
1895         (WebCore::CSSImageSetValue::ImageWithScale::reportMemoryUsage):
1896         * css/CSSImageValue.cpp:
1897         (WebCore::CSSImageValue::reportDescendantMemoryUsage):
1898         * css/CSSImportRule.cpp:
1899         (WebCore::CSSImportRule::reportDescendantMemoryUsage):
1900         * css/CSSInheritedValue.cpp:
1901         (WebCore::CSSInheritedValue::reportDescendantMemoryUsage):
1902         * css/CSSInitialValue.cpp:
1903         (WebCore::CSSInitialValue::reportDescendantMemoryUsage):
1904         * css/CSSLineBoxContainValue.cpp:
1905         (WebCore::CSSLineBoxContainValue::reportDescendantMemoryUsage):
1906         * css/CSSMediaRule.cpp:
1907         (WebCore::CSSMediaRule::reportDescendantMemoryUsage):
1908         * css/CSSPageRule.cpp:
1909         (WebCore::CSSPageRule::reportDescendantMemoryUsage):
1910         * css/CSSPrimitiveValue.cpp:
1911         (WebCore::CSSPrimitiveValue::reportDescendantMemoryUsage):
1912         * css/CSSProperty.cpp:
1913         (WebCore::CSSProperty::reportMemoryUsage):
1914         * css/CSSReflectValue.cpp:
1915         (WebCore::CSSReflectValue::reportDescendantMemoryUsage):
1916         * css/CSSRule.cpp:
1917         (WebCore::CSSRule::reportBaseClassMemoryUsage):
1918         * css/CSSRuleList.cpp:
1919         (WebCore::StaticCSSRuleList::reportMemoryUsage):
1920         * css/CSSRuleList.h:
1921         * css/CSSSelectorList.cpp:
1922         (WebCore::CSSSelectorList::reportMemoryUsage):
1923         * css/CSSStyleRule.cpp:
1924         (WebCore::CSSStyleRule::reportDescendantMemoryUsage):
1925         * css/CSSStyleSheet.cpp:
1926         (WebCore::CSSStyleSheet::reportMemoryUsage):
1927         * css/CSSTimingFunctionValue.cpp:
1928         (WebCore::CSSLinearTimingFunctionValue::reportDescendantMemoryUsage):
1929         (WebCore::CSSCubicBezierTimingFunctionValue::reportDescendantMemoryUsage):
1930         (WebCore::CSSStepsTimingFunctionValue::reportDescendantMemoryUsage):
1931         * css/CSSUnicodeRangeValue.cpp:
1932         (WebCore::CSSUnicodeRangeValue::reportDescendantMemoryUsage):
1933         * css/CSSUnknownRule.h:
1934         (WebCore::CSSUnknownRule::reportDescendantMemoryUsage):
1935         * css/CSSValue.cpp:
1936         (WebCore::TextCloneCSSValue::reportDescendantMemoryUsage):
1937         * css/CSSValueList.cpp:
1938         (WebCore::CSSValueList::reportDescendantMemoryUsage):
1939         * css/CSSVariableValue.h:
1940         (WebCore::CSSVariableValue::reportDescendantMemoryUsage):
1941         * css/FontFeatureValue.cpp:
1942         (WebCore::FontFeatureValue::reportDescendantMemoryUsage):
1943         * css/FontValue.cpp:
1944         (WebCore::FontValue::reportDescendantMemoryUsage):
1945         * css/MediaList.cpp:
1946         (WebCore::MediaQuerySet::reportMemoryUsage):
1947         (WebCore::MediaList::reportMemoryUsage):
1948         * css/MediaQuery.cpp:
1949         (WebCore::MediaQuery::reportMemoryUsage):
1950         * css/MediaQueryExp.cpp:
1951         (WebCore::MediaQueryExp::reportMemoryUsage):
1952         * css/PropertySetCSSStyleDeclaration.cpp:
1953         (WebCore::PropertySetCSSStyleDeclaration::reportMemoryUsage):
1954         (WebCore::StyleRuleCSSStyleDeclaration::reportMemoryUsage):
1955         (WebCore::InlineCSSStyleDeclaration::reportMemoryUsage):
1956         * css/ShadowValue.cpp:
1957         (WebCore::ShadowValue::reportDescendantMemoryUsage):
1958         * css/StylePropertySet.cpp:
1959         (WebCore::StylePropertySet::reportMemoryUsage):
1960         * css/StyleResolver.cpp:
1961         (WebCore::StyleResolver::Features::reportMemoryUsage):
1962         (WebCore::StyleResolver::collectMatchingRulesForList):
1963         * css/StyleRule.cpp:
1964         (WebCore::StyleRuleBase::reportMemoryUsage):
1965         (WebCore::StyleRule::reportDescendantMemoryUsage):
1966         (WebCore::StyleRulePage::reportDescendantMemoryUsage):
1967         (WebCore::StyleRuleFontFace::reportDescendantMemoryUsage):
1968         (WebCore::StyleRuleBlock::reportDescendantMemoryUsage):
1969         (WebCore::StyleRuleMedia::reportDescendantMemoryUsage):
1970         (WebCore::StyleRuleRegion::reportDescendantMemoryUsage):
1971         * css/StyleRuleImport.cpp:
1972         (WebCore::StyleRuleImport::reportDescendantMemoryUsage):
1973         * css/StyleSheetContents.cpp:
1974         (WebCore::StyleSheetContents::reportMemoryUsage):
1975         * css/WebKitCSSFilterValue.cpp:
1976         (WebCore::WebKitCSSFilterValue::reportDescendantMemoryUsage):
1977         * css/WebKitCSSKeyframeRule.cpp:
1978         (WebCore::StyleKeyframe::reportMemoryUsage):
1979         (WebCore::WebKitCSSKeyframeRule::reportDescendantMemoryUsage):
1980         * css/WebKitCSSKeyframesRule.cpp:
1981         (WebCore::StyleRuleKeyframes::reportDescendantMemoryUsage):
1982         (WebCore::WebKitCSSKeyframesRule::reportDescendantMemoryUsage):
1983         * css/WebKitCSSMixFunctionValue.cpp:
1984         (WebCore::WebKitCSSMixFunctionValue::reportDescendantMemoryUsage):
1985         * css/WebKitCSSRegionRule.cpp:
1986         (WebCore::WebKitCSSRegionRule::reportDescendantMemoryUsage):
1987         * css/WebKitCSSSVGDocumentValue.cpp:
1988         (WebCore::WebKitCSSSVGDocumentValue::reportDescendantMemoryUsage):
1989         * css/WebKitCSSShaderValue.cpp:
1990         (WebCore::WebKitCSSShaderValue::reportDescendantMemoryUsage):
1991         * css/WebKitCSSTransformValue.cpp:
1992         (WebCore::WebKitCSSTransformValue::reportDescendantMemoryUsage):
1993         * dom/CharacterData.cpp:
1994         (WebCore::CharacterData::reportMemoryUsage):
1995         * dom/ContainerNode.h:
1996         (WebCore::ContainerNode::reportMemoryUsage):
1997         * dom/Document.cpp:
1998         (WebCore::Document::reportMemoryUsage):
1999         * dom/Element.h:
2000         (WebCore::Element::reportMemoryUsage):
2001         * dom/ElementAttributeData.cpp:
2002         (WebCore::ElementAttributeData::reportMemoryUsage):
2003         * dom/MemoryInstrumentation.h:
2004         (MemoryInstrumentation):
2005         (MemoryObjectInfo):
2006         (WebCore::MemoryObjectInfo::reportObjectInfo):
2007         (MemoryClassInfo):
2008         (WebCore::MemoryClassInfo::MemoryClassInfo):
2009         * dom/Node.cpp:
2010         (WebCore::Node::reportMemoryUsage):
2011         * dom/QualifiedName.h:
2012         (WebCore::QualifiedName::QualifiedNameImpl::reportMemoryUsage):
2013         (WebCore::QualifiedName::reportMemoryUsage):
2014         * loader/DocumentLoader.cpp:
2015         (WebCore::DocumentLoader::reportMemoryUsage):
2016         * loader/FrameLoader.cpp:
2017         (WebCore::FrameLoader::reportMemoryUsage):
2018         * loader/ResourceLoader.cpp:
2019         (WebCore::ResourceLoader::reportMemoryUsage):
2020         * loader/cache/CachedCSSStyleSheet.cpp:
2021         (WebCore::CachedCSSStyleSheet::reportMemoryUsage):
2022         * loader/cache/CachedFont.cpp:
2023         (WebCore::CachedFont::reportMemoryUsage):
2024         * loader/cache/CachedImage.cpp:
2025         (WebCore::CachedImage::reportMemoryUsage):
2026         * loader/cache/CachedRawResource.cpp:
2027         (WebCore::CachedRawResource::reportMemoryUsage):
2028         * loader/cache/CachedResource.cpp:
2029         (WebCore::CachedResource::reportMemoryUsage):
2030         * loader/cache/CachedResourceHandle.cpp:
2031         (WebCore::CachedResourceHandleBase::reportMemoryUsage):
2032         * loader/cache/CachedResourceLoader.cpp:
2033         (WebCore::CachedResourceLoader::reportMemoryUsage):
2034         * loader/cache/CachedSVGDocument.cpp:
2035         (WebCore::CachedSVGDocument::reportMemoryUsage):
2036         * loader/cache/CachedScript.cpp:
2037         (WebCore::CachedScript::reportMemoryUsage):
2038         * loader/cache/CachedShader.cpp:
2039         (WebCore::CachedShader::reportMemoryUsage):
2040         * loader/cache/CachedXSLStyleSheet.cpp:
2041         (WebCore::CachedXSLStyleSheet::reportMemoryUsage):
2042         * loader/cache/MemoryCache.cpp:
2043         (WebCore::MemoryCache::reportMemoryUsage):
2044         * page/Frame.cpp:
2045         (WebCore::Frame::reportMemoryUsage):
2046         * platform/SharedBuffer.cpp:
2047         (WebCore::SharedBuffer::reportMemoryUsage):
2048         * platform/TreeShared.h:
2049         (WebCore::TreeShared::reportMemoryUsage):
2050         * rendering/style/RenderStyle.cpp:
2051         (WebCore::RenderStyle::reportMemoryUsage):
2052         * rendering/style/StyleRareInheritedData.cpp:
2053         (WebCore::StyleRareInheritedData::reportMemoryUsage):
2054         * rendering/style/StyleRareNonInheritedData.cpp:
2055         (WebCore::StyleRareNonInheritedData::reportMemoryUsage):
2056         * svg/SVGColor.cpp:
2057         (WebCore::SVGColor::reportDescendantMemoryUsage):
2058         * svg/SVGPaint.cpp:
2059         (WebCore::SVGPaint::reportDescendantMemoryUsage):
2060
2061 2012-08-02  Simon Hausmann  <simon.hausmann@nokia.com>
2062
2063         [Qt] Remove Qt 4 specific code paths
2064         https://bugs.webkit.org/show_bug.cgi?id=88161
2065
2066         Reviewed by Kenneth Rohde Christiansen.
2067
2068         * Target.pri:
2069         * WebCore.pri:
2070         * bridge/qt/qt_class.cpp:
2071         (JSC::Bindings::QtClass::fallbackObject):
2072         * bridge/qt/qt_instance.cpp:
2073         (JSC::Bindings::QtInstance::getPropertyNames):
2074         (JSC::Bindings::QtInstance::stringValue):
2075         (JSC::Bindings::QtField::setValueToInstance):
2076         * bridge/qt/qt_runtime.h:
2077         (QtConnectionObject):
2078         * bridge/qt/qt_runtime_qt4.cpp: Removed.
2079         * editing/qt/SmartReplaceQt.cpp: Removed.
2080         * page/qt/EventHandlerQt.cpp:
2081         (WebCore::EventHandler::tabsToAllFormControls):
2082         * platform/graphics/GraphicsContext3D.h:
2083         * platform/graphics/OpenGLShims.cpp:
2084         (WebCore::getProcAddress):
2085         * platform/graphics/OpenGLShims.h:
2086         * platform/graphics/gstreamer/PlatformVideoWindowPrivate.h:
2087         * platform/graphics/gstreamer/PlatformVideoWindowQt.cpp:
2088         (FullScreenVideoWindow::FullScreenVideoWindow):
2089         (FullScreenVideoWindow::keyPressEvent):
2090         (FullScreenVideoWindow::event):
2091         (FullScreenVideoWindow::showFullScreen):
2092         (PlatformVideoWindow::PlatformVideoWindow):
2093         * platform/graphics/qt/GraphicsContext3DQt.cpp:
2094         (WebCore::GraphicsContext3DPrivate::blitMultisampleFramebufferAndRestoreContext):
2095         (WebCore::GraphicsContext3DPrivate::makeCurrentIfNeeded):
2096         * platform/graphics/qt/GraphicsContextQt.cpp:
2097         (WebCore::GraphicsContext::releaseWindowsContext):
2098         * platform/graphics/qt/ImageQt.cpp:
2099         (WebCore::BitmapImage::create):
2100         * platform/graphics/qt/SimpleFontDataQt.cpp:
2101         (WebCore::SimpleFontData::platformInit):
2102         * platform/graphics/texmap/TextureMapper.h:
2103         * platform/graphics/texmap/TextureMapperGL.cpp:
2104         (WebCore::TextureMapperGLData::SharedGLData::getCurrentGLContext):
2105         * platform/qt/DeviceMotionProviderQt.h:
2106         * platform/qt/DeviceOrientationProviderQt.h:
2107         * platform/qt/KURLQt.cpp:
2108         (WebCore::KURL::operator QUrl):
2109         * platform/qt/PlatformScreenQt.cpp:
2110         (WebCore::screenDepth):
2111         (WebCore::screenDepthPerComponent):
2112         (WebCore::screenIsMonochrome):
2113         (WebCore::screenRect):
2114         (WebCore::screenAvailableRect):
2115         * platform/qt/QWebPageClient.h:
2116         (QWebPageClient):
2117         * platform/qt/RenderThemeQt.cpp:
2118         * platform/text/qt/TextBreakIteratorQt.cpp: Removed.
2119         * plugins/qt/PluginContainerQt.cpp: Removed.
2120         * plugins/qt/PluginContainerQt.h: Removed.
2121         * plugins/qt/PluginPackageQt.cpp:
2122         (WebCore::PluginPackage::isPluginBlacklisted):
2123         * plugins/qt/PluginViewQt.cpp:
2124         (WebCore::PluginView::setFocus):
2125         (WebCore::PluginView::paintUsingXPixmap):
2126         (WebCore::setSharedXEventFields):
2127         (WebCore::PluginView::setNPWindowIfNeeded):
2128         (WebCore::PluginView::setParentVisible):
2129         (WebCore::PluginView::platformGetValue):
2130         (WebCore::PluginView::invalidateRect):
2131         (WebCore::getVisualAndColormap):
2132         (WebCore::PluginView::platformStart):
2133         * plugins/win/PluginViewWin.cpp:
2134         (windowHandleForPageClient):
2135
2136 2012-08-06  Andrey Kosyakov  <caseq@chromium.org>
2137
2138         Web Inspector: implement reusable progress bar
2139         https://bugs.webkit.org/show_bug.cgi?id=93267
2140
2141         - Generic progress bar implementation to be used
2142             by various long-running operations in inspector.
2143
2144         Test: inspector/progress-bar.html
2145
2146         Reviewed by Pavel Feldman.
2147
2148         * WebCore.gypi: Added ProgressBar.js
2149         * WebCore.vcproj/WebCore.vcproj: ditto.
2150         * inspector/compile-front-end.py: ditto.
2151         * inspector/front-end/AdvancedSearchController.js: renamed style for stop button.
2152         (WebInspector.SearchView):
2153         * inspector/front-end/ProgressBar.js: Added.
2154         (WebInspector.Progress): Interface for both ProgressIndicator and SubProgress.
2155         (WebInspector.Progress.prototype.setTotalWork):
2156         (WebInspector.Progress.prototype.setTitle):
2157         (WebInspector.Progress.prototype.setWorked):
2158         (WebInspector.Progress.prototype.done):
2159         (WebInspector.Progress.prototype.isCanceled):
2160         (WebInspector.ProgressIndicator): A UI control that implements Progress.
2161         (WebInspector.ProgressIndicator.prototype.show):
2162         (WebInspector.ProgressIndicator.prototype.hide):
2163         (WebInspector.ProgressIndicator.prototype.done):
2164         (WebInspector.ProgressIndicator.prototype._cancel):
2165         (WebInspector.ProgressIndicator.prototype.isCanceled):
2166         (WebInspector.ProgressIndicator.prototype.setTitle):
2167         (WebInspector.ProgressIndicator.prototype.setTotalWork):
2168         (WebInspector.ProgressIndicator.prototype.setWorked):
2169         (WebInspector.CompositeProgress): A progress bar that is composed of several SubProgress bars and uses a Progress to display total progress of all tasks.
2170         (WebInspector.CompositeProgress.prototype._childDone):
2171         (WebInspector.CompositeProgress.prototype.createSubProgress):
2172         (WebInspector.CompositeProgress.prototype._update):
2173         (WebInspector.SubProgress): A child of CompositeProgress, implements Progress interface.
2174         (WebInspector.SubProgress.prototype.isCanceled):
2175         (WebInspector.SubProgress.prototype.setTitle):
2176         (WebInspector.SubProgress.prototype.done):
2177         (WebInspector.SubProgress.prototype.setTotalWork):
2178         (WebInspector.SubProgress.prototype.setWorked):
2179         * inspector/front-end/WebKit.qrc: Added ProgressBar.js
2180         * inspector/front-end/inspector.css:
2181         (.progress-bar-stop-button-item):
2182         (.progress-bar-stop-button .glyph):
2183         (.progress-bar-container):
2184         (.progress-bar-container span):
2185         (.progress-bar-container progress):
2186         (.progress-bar-container button.status-bar-item):
2187         * inspector/front-end/inspector.html:
2188
2189 2012-08-07  Peter Rybin  <peter.rybin@gmail.com>
2190
2191         Web Inspector: display function scope in UI
2192         https://bugs.webkit.org/show_bug.cgi?id=90631
2193
2194         Reviewed by Yury Semikhatsky.
2195
2196         Two new tree element types added: function scope group node and scope node.
2197         Scope node is only used to represent closure and catch scopes. Scopes that
2198         have a real object beneath are represented as a property node.
2199         A method that reads properties from RemoteObject and populate tree element
2200         is factored out from RemoteObjectTreeElement for reuse.
2201
2202         * inspector/front-end/ObjectPropertiesSection.js:
2203         (WebInspector.ObjectPropertyTreeElement.prototype.onpopulate):
2204         (WebInspector.ObjectPropertyTreeElement.Populate.callback):
2205         (WebInspector.ObjectPropertyTreeElement.Populate):
2206         (WebInspector.FunctionScopeMainTreeElement):
2207         (WebInspector.FunctionScopeMainTreeElement.prototype.onpopulate.didGetDetails):
2208         (WebInspector.FunctionScopeMainTreeElement.prototype.onpopulate):
2209         (WebInspector.FunctionScopeMainTreeElement.prototype.onattach):
2210         (WebInspector.FunctionScopeMainTreeElement.prototype.update):
2211         (WebInspector.ScopeTreeElement):
2212         (WebInspector.ScopeTreeElement.prototype.onpopulate):
2213         (WebInspector.ScopeTreeElement.prototype.onattach):
2214         (WebInspector.ScopeTreeElement.prototype.update):
2215         * inspector/front-end/RemoteObject.js:
2216         (WebInspector.RemoteObjectProperty.fromScopeValue):
2217
2218
2219 2012-08-07  Vineet Chaudhary  <rgf748@motorola.com>
2220
2221         [V8] Remove custom toV8() calls for TypedArray.
2222         https://bugs.webkit.org/show_bug.cgi?id=93248
2223
2224         Reviewed by Kentaro Hara.
2225
2226         With the support of [TypedArray] we can remove the custom calls toV8().
2227         TypedArray spec : http://www.khronos.org/registry/typedarray/specs/latest/#7
2228
2229         Tests: TestTypedArray.idl
2230         Tests under below folders should pass as this does not cause any behavioral changes.
2231                fast/canvas/webgl
2232                compositing/webgl
2233
2234         * bindings/js/JSInt8ArrayCustom.cpp:
2235         * bindings/js/JSUint8ArrayCustom.cpp:
2236         * bindings/js/JSUint8ClampedArrayCustom.cpp:
2237         * bindings/scripts/CodeGeneratorV8.pm:
2238         (GenerateImplementation): Modified Generator code to generate bindings for toV8().
2239         (IsWrapperType):
2240         (GetTypeNameOfExternalTypedArray): Method to get view type of TypedArray.
2241         * bindings/scripts/test/V8/V8Float64Array.cpp: Tests results.
2242         (WebCore::toV8):
2243         * bindings/v8/custom/V8Float32ArrayCustom.cpp: Removed custom call toV8().
2244         * bindings/v8/custom/V8Float64ArrayCustom.cpp: Ditto.
2245         * bindings/v8/custom/V8Int16ArrayCustom.cpp: Ditto.
2246         * bindings/v8/custom/V8Int32ArrayCustom.cpp: Ditto.
2247         * bindings/v8/custom/V8Int8ArrayCustom.cpp: Ditto.
2248         * bindings/v8/custom/V8Uint16ArrayCustom.cpp: Ditto.
2249         * bindings/v8/custom/V8Uint32ArrayCustom.cpp: Ditto.
2250         * bindings/v8/custom/V8Uint8ArrayCustom.cpp: Ditto.
2251         * bindings/v8/custom/V8Uint8ClampedArrayCustom.cpp: Ditto.
2252         * html/canvas/Int8Array.idl: Using TypedArray.
2253         * html/canvas/Uint8Array.idl: Ditto.
2254         * html/canvas/Uint8ClampedArray.idl: Ditto.
2255
2256 2012-08-07  Pavel Feldman  <pfeldman@chromium.org>
2257
2258         Web Inspector: [regression r121673] restore link between the command and the result.
2259         https://bugs.webkit.org/show_bug.cgi?id=93280
2260
2261         Reviewed by Vsevolod Vlasov.
2262
2263         Passing lost parameter along.
2264
2265         Test: inspector/console/console-originating-command.html
2266
2267         * inspector/front-end/ConsoleView.js:
2268         (WebInspector.ConsoleView.prototype.runScript.runCallback):
2269         (WebInspector.ConsoleView.prototype.runScript):
2270         (WebInspector.ConsoleView.prototype._printResult):
2271
2272 2012-08-07  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
2273
2274         CUSTOM_SCHEME_HANDLER flag should depend on REGISTER_PROTOCOL_HANDLER
2275         https://bugs.webkit.org/show_bug.cgi?id=93081
2276
2277         Reviewed by Adam Barth.
2278
2279         CUSTOM_SCHEME_HANDLER #if guards are enclosed in the REGISTER_PROTOCOL_HANDLER guards.
2280         The whole NavigatorRegisterProtocolHandler interface is conditional on REGISTER_PROTOCOL_HANDLER
2281         CUSTOM_SCHEME_HANDLER-specific methods only are conditional on CUSTOM_SCHEME_HANDLER.
2282
2283         No new tests. No new functionality is added.
2284
2285         * Modules/protocolhandler/NavigatorRegisterProtocolHandler.cpp:
2286         (WebCore::NavigatorRegisterProtocolHandler::registerProtocolHandler):
2287         * Modules/protocolhandler/NavigatorRegisterProtocolHandler.h:
2288         (NavigatorRegisterProtocolHandler):
2289         * Modules/protocolhandler/NavigatorRegisterProtocolHandler.idl:
2290         * Modules/protocolhandler/RegisterProtocolHandlerClient.h:
2291
2292 2012-08-07  Xingnan Wang  <xingnan.wang@intel.com>
2293
2294         IndexedDB: Size the Vector in encodeInt/encodeVarInt/encodeString
2295         https://bugs.webkit.org/show_bug.cgi?id=91813
2296
2297         Reviewed by Kentaro Hara.
2298
2299         To avoid memory re-allocation in Vector, init the capability or size of Vector in encodeInt(), encodeVarInt(),
2300         encodeBool(), encodeIDBKey() etc.
2301
2302         No new tests - Low level functions covered by existing layout tests and also covered by Chromium
2303         webkit_unit_tests IDBLevelIDBCodingTest.* which validates the sizes of buffers returned by encodeVarInt.
2304
2305         * Modules/indexeddb/IDBLevelDBCoding.cpp:
2306         (WebCore::IDBLevelDBCoding::encodeInt):
2307         (WebCore::IDBLevelDBCoding::encodeVarInt):
2308         (WebCore::IDBLevelDBCoding::encodeString):
2309
2310 2012-08-06  Arko Saha  <arko@motorola.com>
2311
2312         Microdata: itemType[index] must be undefined for out-of-range index.
2313         https://bugs.webkit.org/show_bug.cgi?id=92988
2314
2315         Reviewed by Kentaro Hara.
2316
2317         Made changes in IndexedGetter property so that it returns undefined
2318         for out-of-range index.
2319         Spec: http://www.w3.org/TR/WebIDL/#idl-indexed-properties
2320         Firefox and Opera's behavior is consistent with the spec. Both returns
2321         undefined for out-of-range index.
2322
2323         Also renamed the function name collectionStringOrNullIndexedPropertyGetter and
2324         setCollectionStringOrNullIndexedGetter to collectionStringOrUndefinedIndexedPropertyGetter
2325         and setCollectionStringOrUndefinedIndexedGetter respectively.
2326
2327         Test: fast/dom/MicroData/domsettabletokenlist-attributes-out-of-range-index.html
2328
2329         * bindings/scripts/CodeGeneratorJS.pm:
2330         (GenerateImplementation):
2331         * bindings/scripts/CodeGeneratorV8.pm:
2332         (GenerateImplementationIndexer):
2333         * bindings/v8/V8Collection.h:
2334         (WebCore::collectionStringOrUndefinedIndexedPropertyGetter):
2335         (WebCore::setCollectionStringOrUndefinedIndexedGetter):
2336
2337 2012-08-06  David Grogan  <dgrogan@chromium.org>
2338
2339         IndexedDB: Make leveldb store integer versions and migrate old schemas
2340         https://bugs.webkit.org/show_bug.cgi?id=92883
2341
2342         Reviewed by Tony Chang.
2343
2344         Our first schema change. If an existing DB doesn't have integer
2345         versions, this will add one to all object stores in the origin.
2346
2347         No new tests - chrome test for the migration forthcoming. Will involve
2348         starting with a leveldb directory from an old build of chrome, opening
2349         it up with the migration code in place, and checking the new database.
2350         http://codereview.chromium.org/10826159/
2351
2352         * Modules/indexeddb/IDBLevelDBBackingStore.cpp:
2353         (WebCore::putVarInt):
2354         (WebCore):
2355         (WebCore::setUpMetadata):
2356         Uses the ASSERT-but-still-handle-corruption pattern recently discussed
2357         in https://bugs.webkit.org/show_bug.cgi?id=92725#c13.
2358
2359         (WebCore::IDBLevelDBBackingStore::open):
2360         (WebCore::IDBLevelDBBackingStore::getIDBDatabaseMetaData):
2361         Because we can't store negative numbers, store 0 instead of -1.
2362
2363         (WebCore::IDBLevelDBBackingStore::createIDBDatabaseMetaData):
2364         (WebCore::IDBLevelDBBackingStore::updateIDBDatabaseIntVersion):
2365         * Modules/indexeddb/IDBLevelDBCoding.h:
2366         * Modules/indexeddb/IDBMetadata.h:
2367
2368 2012-08-06  Sheriff Bot  <webkit.review.bot@gmail.com>
2369
2370         Unreviewed, rolling out r124780.
2371         http://trac.webkit.org/changeset/124780
2372         https://bugs.webkit.org/show_bug.cgi?id=93340
2373
2374         We don't want an incomplete feature set for the chromium
2375         branch cut. (Requested by annacc on #webkit).
2376
2377         * CMakeLists.txt:
2378         * DerivedSources.cpp:
2379         * DerivedSources.make:
2380         * DerivedSources.pri:
2381         * GNUmakefile.list.am:
2382         * Modules/mediasource/MediaSource.cpp: Removed.
2383         * Modules/mediasource/MediaSource.h: Removed.
2384         * Modules/mediasource/MediaSource.idl: Removed.
2385         * Modules/mediasource/MediaSourceRegistry.cpp: Removed.
2386         * Modules/mediasource/MediaSourceRegistry.h: Removed.
2387         * Modules/mediasource/SourceBuffer.cpp:
2388         (WebCore::SourceBuffer::SourceBuffer):
2389         (WebCore::SourceBuffer::buffered):
2390         (WebCore::SourceBuffer::append):
2391         (WebCore::SourceBuffer::abort):
2392         * Modules/mediasource/SourceBuffer.h:
2393         (WebCore::SourceBuffer::create):
2394         (WebCore::SourceBuffer::clear):
2395         (SourceBuffer):
2396         * Modules/mediasource/SourceBufferList.cpp:
2397         * Modules/mediasource/SourceBufferList.h:
2398         * Target.pri:
2399         * WebCore.gypi:
2400         * WebCore.vcproj/WebCore.vcproj:
2401         * WebCore.xcodeproj/project.pbxproj:
2402         * dom/EventTarget.h:
2403         (WebCore):
2404         * dom/EventTargetFactory.in:
2405         * html/DOMURL.cpp:
2406         * html/DOMURL.h:
2407         (WebCore):
2408         (DOMURL):
2409         * html/DOMURL.idl:
2410         * page/DOMWindow.idl:
2411
2412 2012-08-06  Sheriff Bot  <webkit.review.bot@gmail.com>
2413
2414         Unreviewed, rolling out r124798.
2415         http://trac.webkit.org/changeset/124798
2416         https://bugs.webkit.org/show_bug.cgi?id=93337
2417
2418         We don't want an incomplete feature set for the chromium
2419         branch cut. (Requested by annacc on #webkit).
2420
2421         * html/DOMURL.cpp:
2422         (WebCore::DOMURL::createObjectURL):
2423         * html/PublicURLManager.h:
2424         (WebCore::PublicURLManager::contextDestroyed):
2425         (PublicURLManager):
2426
2427 2012-08-06  Sheriff Bot  <webkit.review.bot@gmail.com>
2428
2429         Unreviewed, rolling out r124848.
2430         http://trac.webkit.org/changeset/124848
2431         https://bugs.webkit.org/show_bug.cgi?id=93336
2432
2433         Caused 3 tests to crash on chromium Linux32/Mac10.6/Linux
2434         (Requested by toyoshim on #webkit).
2435
2436         * html/HTMLMediaElement.cpp:
2437         (WebCore):
2438         (WebCore::HTMLMediaElement::HTMLMediaElement):
2439         (WebCore::HTMLMediaElement::parseAttribute):
2440         (WebCore::HTMLMediaElement::prepareForLoad):
2441         (WebCore::HTMLMediaElement::loadResource):
2442         (WebCore::HTMLMediaElement::noneSupported):
2443         (WebCore::HTMLMediaElement::mediaEngineError):
2444         (WebCore::HTMLMediaElement::mediaPlayerSourceOpened):
2445         (WebCore::HTMLMediaElement::isValidSourceId):
2446         (WebCore::HTMLMediaElement::seek):
2447         (WebCore::HTMLMediaElement::webkitSourceAddId):
2448         (WebCore::HTMLMediaElement::webkitSourceRemoveId):
2449         (WebCore::HTMLMediaElement::webkitSourceBuffered):
2450         (WebCore::HTMLMediaElement::webkitSourceAppend):
2451         (WebCore::HTMLMediaElement::webkitSourceAbort):
2452         (WebCore::HTMLMediaElement::webkitSourceEndOfStream):
2453         (WebCore::HTMLMediaElement::webkitSourceState):
2454         (WebCore::HTMLMediaElement::setSourceState):
2455         (WebCore::HTMLMediaElement::userCancelledLoad):
2456         (WebCore::HTMLMediaElement::createMediaPlayer):
2457         * html/HTMLMediaElement.h:
2458         (HTMLMediaElement):
2459         * html/HTMLMediaElement.idl:
2460
2461 2012-08-06  Anna Cavender  <annacc@chromium.org>
2462
2463         Update HTMLMediaElement to the new OO MediaSource API.
2464         https://bugs.webkit.org/show_bug.cgi?id=91775
2465
2466         Reviewed by Eric Carlson.
2467
2468         This patch rips out the old-style MediaSource API and allows a
2469         MediaSource object to be attached to HTMLMediaElement.
2470         http://dvcs.w3.org/hg/html-media/raw-file/tip/media-source/media-source.html
2471
2472         Test: http/tests/media/media-source/video-media-source-add-and-remove-buffers.html
2473
2474         Tests: updates to http/tests/media/media-source/*
2475
2476         * html/HTMLMediaElement.cpp:
2477         (WebCore):
2478         (WebCore::HTMLMediaElement::HTMLMediaElement): Remove old style API resources.
2479         (WebCore::HTMLMediaElement::parseAttribute): Remove old style event attributes.
2480         (WebCore::HTMLMediaElement::prepareForLoad): Set source state to "closed".
2481         (WebCore::HTMLMediaElement::loadResource): Get MediaSource object from blob registry
2482             look up and, if found, set it's MediaPlayer pointer to the current MediaPlayer.
2483         (WebCore::HTMLMediaElement::noneSupported): Set source state to "closed".
2484         (WebCore::HTMLMediaElement::mediaEngineError): Set source state to "closed".
2485         (WebCore::HTMLMediaElement::mediaPlayerSourceOpened): Set source state to "open".
2486         (WebCore::HTMLMediaElement::mediaPlayerSourceURL): Change to new blob URL.
2487         (WebCore::HTMLMediaElement::seek): Check if source state is "closed".
2488         (WebCore::HTMLMediaElement::setSourceState): Helper function so that we don't have to
2489             keep checking for m_mediaSource.
2490         (WebCore::HTMLMediaElement::userCancelledLoad): Set source state to "closed".
2491         (WebCore::HTMLMediaElement::createMediaPlayer): If the current MediaPlayer is re-
2492             created, notify the MediaSource and reset its MediaPlayer.
2493
2494         * html/HTMLMediaElement.h: Remove old style API code and add a MediaSource object.
2495         (HTMLMediaElement):
2496         * html/HTMLMediaElement.idl: Remove old style API.
2497
2498 2012-08-06  Adam Barth  <abarth@webkit.org>
2499
2500         BindingSecurity::shouldAllowAccessToFrame shouldn't use a raw boolean parameter
2501         https://bugs.webkit.org/show_bug.cgi?id=93323
2502
2503         Reviewed by Eric Seidel.
2504
2505         As requested by Eric. This patch also renames the function to match its
2506         counterpart in the JavaScriptCore bindings.
2507
2508         * bindings/generic/BindingSecurity.cpp:
2509         (WebCore::canAccessDocument):
2510         (WebCore::BindingSecurity::shouldAllowAccessToFrame):
2511         (WebCore::BindingSecurity::shouldAllowAccessToNode):
2512         (WebCore::BindingSecurity::allowSettingFrameSrcToJavascriptUrl):
2513         * bindings/generic/BindingSecurity.h:
2514         (BindingSecurity):
2515         * bindings/scripts/CodeGeneratorV8.pm:
2516         (GenerateDomainSafeFunctionGetter):
2517         (GenerateReplaceableAttrSetter):
2518         (GenerateFunctionCallback):
2519         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
2520         (WebCore::TestActiveDOMObjectV8Internal::excitingFunctionCallback):
2521         (WebCore::TestActiveDOMObjectV8Internal::postMessageAttrGetter):
2522         * bindings/v8/ScriptController.cpp:
2523         (WebCore::ScriptController::canAccessFromCurrentOrigin):
2524         * bindings/v8/custom/V8DOMWindowCustom.cpp:
2525         (WebCore::WindowSetTimeoutImpl):
2526         (WebCore::V8DOMWindow::eventAccessorGetter):
2527         (WebCore::V8DOMWindow::eventAccessorSetter):
2528         (WebCore::V8DOMWindow::openerAccessorSetter):
2529         (WebCore::V8DOMWindow::addEventListenerCallback):
2530         (WebCore::V8DOMWindow::removeEventListenerCallback):
2531         (WebCore::V8DOMWindow::showModalDialogCallback):
2532         (WebCore::V8DOMWindow::openCallback):
2533         (WebCore::V8DOMWindow::namedSecurityCheck):
2534         (WebCore::V8DOMWindow::indexedSecurityCheck):
2535         * bindings/v8/custom/V8HistoryCustom.cpp:
2536         (WebCore::V8History::indexedSecurityCheck):
2537         (WebCore::V8History::namedSecurityCheck):
2538         * bindings/v8/custom/V8InjectedScriptManager.cpp:
2539         (WebCore::InjectedScriptManager::canAccessInspectedWindow):
2540         * bindings/v8/custom/V8LocationCustom.cpp:
2541         (WebCore::V8Location::reloadAccessorGetter):
2542         (WebCore::V8Location::replaceAccessorGetter):
2543         (WebCore::V8Location::assignAccessorGetter):
2544         (WebCore::V8Location::toStringCallback):
2545         (WebCore::V8Location::indexedSecurityCheck):
2546         (WebCore::V8Location::namedSecurityCheck):
2547
2548 2012-08-06  Yuta Kitamura  <yutak@chromium.org>
2549
2550         WebSocket.send() should accept ArrayBufferView
2551         https://bugs.webkit.org/show_bug.cgi?id=90877
2552
2553         Reviewed by Kent Tamura.
2554
2555         Accept ArrayBufferView as an argument of WebSocket.send() to comply with recent change
2556         in specification: <http://html5.org/tools/web-apps-tracker?from=7084&to=7085>.
2557
2558         Once WebSocket.send(ArrayBuffer) was removed from the specification, but added back
2559         in <http://html5.org/tools/web-apps-tracker?from=7202&to=7203>. Thus the functionality
2560         of send(ArrayBuffer) is kept as-is.
2561
2562         Tests: http/tests/websocket/tests/hybi/send-arraybufferview.html
2563                http/tests/websocket/tests/hybi/workers/send-arraybufferview.html
2564
2565         * Modules/websockets/ThreadableWebSocketChannel.h:
2566         Change the signature of send() to receive offset and length so the clients can send
2567         subrange of an ArrayBuffer.
2568         * Modules/websockets/WebSocket.cpp:
2569         (WebCore::WebSocket::send):
2570         WebSocket.send(ArrayBufferView) is added, which puts the sub region of the given
2571         ArrayBuffer into the outgoing frame queue.
2572         * Modules/websockets/WebSocket.h:
2573         * Modules/websockets/WebSocket.idl:
2574         * Modules/websockets/WebSocketChannel.cpp:
2575         (WebCore::WebSocketChannel::send):
2576         * Modules/websockets/WebSocketChannel.h:
2577         (WebSocketChannel):
2578         * Modules/websockets/WorkerThreadableWebSocketChannel.cpp:
2579         (WebCore::WorkerThreadableWebSocketChannel::send):
2580         (WebCore::WorkerThreadableWebSocketChannel::Peer::send):
2581         (WebCore::WorkerThreadableWebSocketChannel::Bridge::send):
2582         Send only necessary part of data to the main thread.
2583         * Modules/websockets/WorkerThreadableWebSocketChannel.h:
2584         (WorkerThreadableWebSocketChannel):
2585         (Bridge):
2586         * bindings/js/JSWebSocketCustom.cpp:
2587         (WebCore::JSWebSocket::send): Accept ArrayBufferView in send().
2588         * bindings/v8/custom/V8WebSocketCustom.cpp:
2589         (WebCore::V8WebSocket::sendCallback): Ditto.
2590
2591 2012-08-06  James Robinson  <jamesr@chromium.org>
2592
2593         [chromium] Add gyp variable to control which compositor target is depended on
2594         https://bugs.webkit.org/show_bug.cgi?id=93165
2595
2596         Reviewed by Adam Barth.
2597
2598         This adds a use_libcc_for_compositor gyp variable to control whether webcore_platform links in the compositor
2599         code from the webcore_chromium_compositor target or from cc from the chromium repo.
2600
2601         * WebCore.gyp/WebCore.gyp:
2602         * WebCore.gypi:
2603
2604 2012-08-06  Shinya Kawanaka  <shinyak@chromium.org>
2605
2606         Crash in GenericEventQueue::timerFired since the owner of GenericEventQueue is deleted during dispatching events.
2607         https://bugs.webkit.org/show_bug.cgi?id=92946
2608
2609         Reviewed by Eric Carlson.
2610
2611         In GenericEventQueue::timerFired(), the owner of GenericEventQueue might be deleted.
2612         We have to protect the owner of GenericEventQueue during dispatching events.
2613
2614         Test: media/event-queue-crash.html
2615
2616         * dom/GenericEventQueue.cpp:
2617         (WebCore::GenericEventQueue::timerFired): Added a protection.
2618
2619 2012-08-06  Joshua Bell  <jsbell@chromium.org>
2620
2621         IndexedDB: Remove IDBRequest::finishCursor() and plumbing
2622         https://bugs.webkit.org/show_bug.cgi?id=93274
2623
2624         Reviewed by Tony Chang.
2625
2626         Delete an unused flag and code for setting it, rendered obsolete in r123275.
2627
2628         No new tests - no functional changes.
2629
2630         * Modules/indexeddb/IDBCursor.cpp:
2631         (WebCore::IDBCursor::close):
2632         * Modules/indexeddb/IDBRequest.cpp:
2633         (WebCore::IDBRequest::IDBRequest):
2634         * Modules/indexeddb/IDBRequest.h:
2635         (IDBRequest):
2636
2637 2012-08-06  James Robinson  <jamesr@chromium.org>
2638
2639         [chromium] Remove lingering unwrap<>() calls in GraphicsLayerChromium.cpp
2640         https://bugs.webkit.org/show_bug.cgi?id=93319
2641
2642         Reviewed by Adrienne Walker.
2643
2644         Gets rid of all (but one) of the remaining unwrap<LayerChromium>() calls in GraphicsLayer chromium to avoid
2645         punching through the WebLayer API.  Covered by many layout tests, mostly in compositing/
2646
2647         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
2648         (WebCore::GraphicsLayerChromium::willBeDestroyed):
2649         (WebCore::GraphicsLayerChromium::setName):
2650         (WebCore::GraphicsLayerChromium::updateNames):
2651         (WebCore::GraphicsLayerChromium::setMaskLayer):
2652         (WebCore::GraphicsLayerChromium::setReplicatedByLayer):
2653         (WebCore::GraphicsLayerChromium::setContentsToImage):
2654         (WebCore::GraphicsLayerChromium::setContentsToCanvas):
2655         (WebCore::GraphicsLayerChromium::setContentsToMedia):
2656         (WebCore::GraphicsLayerChromium::updateChildList):
2657         (WebCore::GraphicsLayerChromium::setupContentsLayer):
2658         * platform/graphics/chromium/GraphicsLayerChromium.h:
2659         (GraphicsLayerChromium):
2660
2661 2012-08-06  Adrienne Walker  <enne@google.com>
2662
2663         [chromium] Convert WebScrollbarThemeGeometry from a concrete class to an interface
2664         https://bugs.webkit.org/show_bug.cgi?id=93308
2665
2666         Reviewed by James Robinson.
2667
2668         Convert WebScrollbarThemeGeometry to be an interface. Create a new
2669         WebScrollbarThemeGeometryNative implementation to wrap a native theme
2670         pointer.
2671
2672         Update ScrollbarLayerChromium/CCScrollbarLayerImpl to use a pointer to
2673         this interface rather than a concrete member variable. Because both
2674         layer types need to access the theme during painting or compositing
2675         and either layer could go away at any time, the theme is cloned during
2676         commit rather than dealing with refcounting across threads or having
2677         one layer type be the sole owner.
2678
2679         * WebCore.gypi:
2680         * page/scrolling/chromium/ScrollingCoordinatorChromium.cpp:
2681         (WebCore::createScrollbarLayer):
2682         * platform/chromium/support/WebScrollbarThemeGeometryNative.cpp: Renamed from Source/WebKit/chromium/src/WebScrollbarThemeGeometry.cpp.
2683         (WebKit):
2684         (WebKit::WebScrollbarThemeGeometryNative::create):
2685         (WebKit::WebScrollbarThemeGeometryNative::WebScrollbarThemeGeometryNative):
2686         (WebKit::WebScrollbarThemeGeometryNative::clone):
2687         (WebKit::WebScrollbarThemeGeometryNative::thumbPosition):
2688         (WebKit::WebScrollbarThemeGeometryNative::thumbLength):
2689         (WebKit::WebScrollbarThemeGeometryNative::trackPosition):
2690         (WebKit::WebScrollbarThemeGeometryNative::trackLength):
2691         (WebKit::WebScrollbarThemeGeometryNative::hasButtons):
2692         (WebKit::WebScrollbarThemeGeometryNative::hasThumb):
2693         (WebKit::WebScrollbarThemeGeometryNative::trackRect):
2694         (WebKit::WebScrollbarThemeGeometryNative::thumbRect):
2695         (WebKit::WebScrollbarThemeGeometryNative::minimumThumbLength):
2696         (WebKit::WebScrollbarThemeGeometryNative::scrollbarThickness):
2697         (WebKit::WebScrollbarThemeGeometryNative::backButtonStartRect):
2698         (WebKit::WebScrollbarThemeGeometryNative::backButtonEndRect):
2699         (WebKit::WebScrollbarThemeGeometryNative::forwardButtonStartRect):
2700         (WebKit::WebScrollbarThemeGeometryNative::forwardButtonEndRect):
2701         (WebKit::WebScrollbarThemeGeometryNative::constrainTrackRectToTrackPieces):
2702         (WebKit::WebScrollbarThemeGeometryNative::splitTrack):
2703         * platform/chromium/support/WebScrollbarThemeGeometryNative.h: Added.
2704         (WebKit):
2705         (WebScrollbarThemeGeometryNative):
2706         * platform/graphics/chromium/ScrollbarLayerChromium.cpp:
2707         (WebCore::ScrollbarLayerChromium::create):
2708         (WebCore::ScrollbarLayerChromium::ScrollbarLayerChromium):
2709         (WebCore::ScrollbarLayerChromium::pushPropertiesTo):
2710         (WebCore::ScrollbarBackgroundPainter::create):
2711         (WebCore::ScrollbarBackgroundPainter::ScrollbarBackgroundPainter):
2712         (ScrollbarBackgroundPainter):
2713         (WebCore::ScrollbarThumbPainter::create):
2714         (WebCore::ScrollbarThumbPainter::ScrollbarThumbPainter):
2715         (ScrollbarThumbPainter):
2716         (WebCore::ScrollbarLayerChromium::createTextureUpdaterIfNeeded):
2717         (WebCore::ScrollbarLayerChromium::setTexturePriorities):
2718         (WebCore::ScrollbarLayerChromium::update):
2719         * platform/graphics/chromium/ScrollbarLayerChromium.h:
2720         (ScrollbarLayerChromium):
2721         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
2722         (WebCore::CCScrollbarLayerImpl::setScrollbarGeometry):
2723         (WebCore::CCScrollbarLayerImpl::setScrollbarData):
2724         (WebCore::CCScrollbarLayerImpl::appendQuads):
2725         * platform/graphics/chromium/cc/CCScrollbarLayerImpl.h:
2726         (WebCore::CCScrollbarLayerImpl::scrollbarGeometry):
2727         (CCScrollbarLayerImpl):
2728
2729 2012-08-06  Adam Barth  <abarth@webkit.org>
2730
2731         JSC should use BindingState to determine the activeDOMWindow
2732         https://bugs.webkit.org/show_bug.cgi?id=93307
2733
2734         Reviewed by Eric Seidel.
2735
2736         This patch moves activeDOMWindow from JSDOMBindings.cpp to
2737         BindingState.cpp. This is a first step towards sharing the core
2738         security logic in the bindings between JavaScriptCore and V8. Once the
2739         logic is shared, we will be able to refactor the logic to avoid the
2740         need for DOMWindow::m_securityOrigin.
2741
2742         This patch doesn't actually share any code (yet). It just sets the
2743         stage by creating BindingState as a typedef of ExecState and adding the
2744         appropriate files to the build systems.
2745
2746         This patch also renames activeWindow and firstWindow in the V8 bindings
2747         to activeDOMWindow and firstDOMWindow to match the names in the
2748         JavaScriptCore bindings.
2749
2750         * GNUmakefile.list.am:
2751         * Target.pri:
2752         * UseJSC.cmake:
2753         * WebCore.gypi:
2754         * WebCore.vcproj/WebCore.vcproj:
2755         * WebCore.xcodeproj/project.pbxproj:
2756         * bindings/generic/BindingSecurity.cpp:
2757         (WebCore::canAccessDocument):
2758         * bindings/js/JSBindingsAllInOne.cpp:
2759         * bindings/js/JSDOMBinding.cpp:
2760         (WebCore):
2761         * bindings/js/JSDOMBinding.h:
2762         (WebCore):
2763         * bindings/v8/BindingState.cpp:
2764         (WebCore::activeDOMWindow):
2765         (WebCore::firstDOMWindow):
2766         * bindings/v8/BindingState.h:
2767         (WebCore):
2768         * bindings/v8/custom/V8DOMWindowCustom.cpp:
2769         (WebCore::V8DOMWindow::locationAccessorSetter):
2770         (WebCore::handlePostMessageCallback):
2771         (WebCore::V8DOMWindow::showModalDialogCallback):
2772         (WebCore::V8DOMWindow::openCallback):
2773         * bindings/v8/custom/V8DocumentLocationCustom.cpp:
2774         (WebCore::V8Document::locationAccessorSetter):
2775         * bindings/v8/custom/V8LocationCustom.cpp:
2776         (WebCore::V8Location::hashAccessorSetter):
2777         (WebCore::V8Location::hostAccessorSetter):
2778         (WebCore::V8Location::hostnameAccessorSetter):
2779         (WebCore::V8Location::hrefAccessorSetter):
2780         (WebCore::V8Location::pathnameAccessorSetter):
2781         (WebCore::V8Location::portAccessorSetter):
2782         (WebCore::V8Location::protocolAccessorSetter):
2783         (WebCore::V8Location::searchAccessorSetter):
2784         (WebCore::V8Location::reloadCallback):
2785         (WebCore::V8Location::replaceCallback):
2786         (WebCore::V8Location::assignCallback):
2787
2788 2012-08-05  Kent Tamura  <tkent@chromium.org>
2789
2790         [Chromium-Mac] Use the default locale only if the browser locale matches to it
2791         https://bugs.webkit.org/show_bug.cgi?id=93227
2792
2793         Reviewed by Hajime Morita.
2794
2795         For a calendar picker, we have used month names and day-of-week names
2796         obtained from the OS default locale. However, the year-month format and
2797         [Today] [Clear] labels are decided with the browser locale. It made
2798         calendar pickers with mixed languages.
2799
2800         To make calendar pickers with a single language, we use the OS default
2801         locale only if the browser locale matches to it.
2802
2803         No new tests. Behavior for locale setting is not testable in WebKit.
2804
2805         * platform/text/mac/LocaleMac.mm:
2806         (WebCore::languageFromLocale):
2807         A helper for determineLocale. This returns the language part of the
2808         specified locale identifier.
2809         (WebCore::determineLocale):
2810         If the browser language matches to the language of the current NSLocale,
2811         returns the current NSLocale. Otherwise, returns a NSLocale with the
2812         browser language.
2813         Note that [NSLolca localeIdentifier] returns a string in
2814         <language>_<country> format though defaultLanguage() in Chromium returns
2815         a string in <language>-<country> format.
2816         (WebCore::LocaleMac::currentLocale):
2817         Use determineLocale.
2818
2819 2012-08-06  Luke Macpherson   <macpherson@chromium.org>
2820
2821         Handle variables in CSSParser::parseValidPrimitive(), preventing null return value.
2822         https://bugs.webkit.org/show_bug.cgi?id=93235
2823
2824         Reviewed by Tony Chang.
2825
2826         By returning null here (and failing to handle the variable) the current code would cause null pointer dereferences in StyleResolver at several points.
2827         Instead we create a primitive value for the variable reference and return it.
2828
2829         Test: fast/css/variables/invalid-font-reference.html
2830
2831         * css/CSSParser.cpp:
2832         (WebCore::CSSParser::parseValidPrimitive):
2833
2834 2012-08-06  David Reveman  <reveman@chromium.org>
2835
2836         [Chromium] Rename CCTextureUpdater to CCTextureUpdateQueue.
2837         https://bugs.webkit.org/show_bug.cgi?id=93293
2838
2839         Reviewed by Adrienne Walker.
2840
2841         No new tests.
2842
2843         * WebCore.gypi:
2844         * platform/graphics/chromium/ContentLayerChromium.cpp:
2845         (WebCore::ContentLayerChromium::update):
2846         * platform/graphics/chromium/ContentLayerChromium.h:
2847         (ContentLayerChromium):
2848         * platform/graphics/chromium/HeadsUpDisplayLayerChromium.cpp:
2849         (WebCore::HeadsUpDisplayLayerChromium::update):
2850         * platform/graphics/chromium/HeadsUpDisplayLayerChromium.h:
2851         (HeadsUpDisplayLayerChromium):
2852         * platform/graphics/chromium/ImageLayerChromium.cpp:
2853         (WebCore::ImageLayerChromium::update):
2854         * platform/graphics/chromium/ImageLayerChromium.h:
2855         (ImageLayerChromium):
2856         * platform/graphics/chromium/LayerChromium.h:
2857         (WebCore):
2858         (WebCore::LayerChromium::update):
2859         * platform/graphics/chromium/ScrollbarLayerChromium.cpp:
2860         (WebCore::ScrollbarLayerChromium::updatePart):
2861         (WebCore::ScrollbarLayerChromium::update):
2862         * platform/graphics/chromium/ScrollbarLayerChromium.h:
2863         (WebCore):
2864         (ScrollbarLayerChromium):
2865         * platform/graphics/chromium/TextureLayerChromium.cpp:
2866         (WebCore::TextureLayerChromium::update):
2867         * platform/graphics/chromium/TextureLayerChromium.h:
2868         (TextureLayerChromiumClient):
2869         (TextureLayerChromium):
2870         * platform/graphics/chromium/TiledLayerChromium.cpp:
2871         (WebCore::TiledLayerChromium::updateTiles):
2872         (WebCore::TiledLayerChromium::updateContentRect):
2873         * platform/graphics/chromium/TiledLayerChromium.h:
2874         (TiledLayerChromium):
2875         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
2876         (WebCore::CCLayerTreeHost::updateLayers):
2877         (WebCore::CCLayerTreeHost::paintMasksForRenderSurface):
2878         (WebCore::CCLayerTreeHost::paintLayerContents):
2879         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
2880         (WebCore):
2881         (CCLayerTreeHost):
2882         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
2883         (WebCore::CCSingleThreadProxy::doCommit):
2884         (WebCore::CCSingleThreadProxy::commitAndComposite):
2885         * platform/graphics/chromium/cc/CCSingleThreadProxy.h:
2886         * platform/graphics/chromium/cc/CCTextureUpdateController.cpp:
2887         (WebCore::CCTextureUpdateController::updateTextures):
2888         (WebCore::CCTextureUpdateController::CCTextureUpdateController):
2889         (WebCore::CCTextureUpdateController::hasMoreUpdates):
2890         (WebCore::CCTextureUpdateController::updateMoreTextures):
2891         * platform/graphics/chromium/cc/CCTextureUpdateController.h:
2892         (WebCore::CCTextureUpdateController::create):
2893         (CCTextureUpdateController):
2894         * platform/graphics/chromium/cc/CCTextureUpdateQueue.cpp: Renamed from Source/WebCore/platform/graphics/chromium/cc/CCTextureUpdater.cpp.
2895         (WebCore):
2896         (WebCore::CCTextureUpdateQueue::CCTextureUpdateQueue):
2897         (WebCore::CCTextureUpdateQueue::~CCTextureUpdateQueue):
2898         (WebCore::CCTextureUpdateQueue::appendFullUpload):
2899         (WebCore::CCTextureUpdateQueue::appendPartialUpload):
2900         (WebCore::CCTextureUpdateQueue::appendCopy):
2901         (WebCore::CCTextureUpdateQueue::takeFirstFullUpload):
2902         (WebCore::CCTextureUpdateQueue::takeFirstPartialUpload):
2903         (WebCore::CCTextureUpdateQueue::takeFirstCopy):
2904         (WebCore::CCTextureUpdateQueue::hasMoreUpdates):
2905         * platform/graphics/chromium/cc/CCTextureUpdateQueue.h: Renamed from Source/WebCore/platform/graphics/chromium/cc/CCTextureUpdater.h.
2906         (WebCore):
2907         (CCTextureUpdateQueue):
2908         (WebCore::CCTextureUpdateQueue::fullUploadSize):
2909         (WebCore::CCTextureUpdateQueue::partialUploadSize):
2910         (WebCore::CCTextureUpdateQueue::copySize):
2911         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
2912         (WebCore::CCThreadProxy::beginFrame):
2913         (WebCore::CCThreadProxy::beginFrameCompleteOnImplThread):
2914         * platform/graphics/chromium/cc/CCThreadProxy.h:
2915         (WebCore):
2916         (CCThreadProxy):
2917
2918 2012-08-06  Anders Carlsson  <andersca@apple.com>
2919
2920         Clear out the TileCache backpointer for all tile layers when the tile cache is destroyed
2921         https://bugs.webkit.org/show_bug.cgi?id=93317
2922         <rdar://problem/11566543>
2923
2924         Reviewed by Dean Jackson.
2925
2926         It seems that in some rare cases, the tile cache layer can be destroyed in the same transaction as tile layers
2927         are being asked to paint. Make sure to null out the TileCache back pointer for all layers in the TileCache destructor.
2928
2929         * platform/graphics/ca/mac/TileCache.mm:
2930         (WebCore::TileCache::~TileCache):
2931
2932 2012-08-06  Sheriff Bot  <webkit.review.bot@gmail.com>
2933
2934         Unreviewed, rolling out r124816.
2935         http://trac.webkit.org/changeset/124816
2936         https://bugs.webkit.org/show_bug.cgi?id=93311
2937
2938         made some tests crash (Requested by noamr on #webkit).
2939
2940         * platform/graphics/GraphicsLayerAnimation.cpp:
2941         (WebCore::GraphicsLayerAnimation::GraphicsLayerAnimation):
2942         (WebCore::GraphicsLayerAnimations::hasActiveAnimationsOfType):
2943         (WebCore::GraphicsLayerAnimations::hasRunningAnimations):
2944         (WebCore::GraphicsLayerAnimations::add):
2945         (WebCore::GraphicsLayerAnimations::pause):
2946         (WebCore::GraphicsLayerAnimations::apply):
2947         * platform/graphics/GraphicsLayerAnimation.h:
2948         (GraphicsLayerAnimation):
2949         (GraphicsLayerAnimations):
2950         (WebCore::GraphicsLayerAnimations::remove):
2951         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
2952         (WebCore::GraphicsLayerTextureMapper::addAnimation):
2953
2954 2012-08-06  Max Vujovic  <mvujovic@adobe.com>
2955
2956         [CSS Shaders] Parse mix function
2957         https://bugs.webkit.org/show_bug.cgi?id=90101
2958
2959         Reviewed by Dirk Schulze.
2960
2961         Parse the mix function syntax for CSS Shaders as defined in the Filter Effects spec:
2962         https://dvcs.w3.org/hg/FXTF/raw-file/tip/filters/index.html#FilterFunction
2963
2964         The fragment shader argument of the custom filter function can now be a mix function with
2965         the following syntax:
2966         mix(<uri> [ <blend-mode> || <alpha-compositing> ]?)
2967
2968         For example:
2969         -webkit-filter: custom(url(shader.vert) mix(url(shader.frag multiply source-over))
2970
2971         The Filter Effects spec references the Compositing and Blending spec, which defines the
2972         supported blend modes and alpha compositing modes.
2973
2974         Blend modes:
2975         https://dvcs.w3.org/hg/FXTF/rawfile/tip/compositing/index.html#blend-mode
2976
2977         This patch adds all of the blend modes in the spec.
2978
2979         Alpha compositing modes:
2980         https://dvcs.w3.org/hg/FXTF/rawfile/tip/compositing/index.html#alpha-compositing
2981
2982         This patch does not add any new CSS values for alpha compositing. Currently, we parse the
2983         values that are the same between the spec and the -webkit-background-composite property,
2984         including:
2985             clear
2986             copy
2987             source-over
2988             source-in
2989             source-out
2990             source-atop
2991             destination-over
2992             destination-in
2993             destination-out
2994             destination-atop
2995             xor
2996
2997         In the future, we may need to add the following CSS values for alpha compositing:
2998             lighter
2999             destination
3000
3001         This is currently under discussion on the www-style mailing list:
3002         http://lists.w3.org/Archives/Public/www-style/2012Aug/0123.html
3003
3004         No new test files. Add test cases in:
3005             css3/filters/script-tests/custom-filter-property-computed-style.js:
3006             css3/filters/script-tests/custom-filter-property-parsing-invalid.js:
3007             css3/filters/script-tests/custom-filter-property-parsing.js:
3008
3009         * GNUmakefile.list.am:
3010         * Target.pri:
3011         * WebCore.gypi:
3012         * WebCore.vcproj/WebCore.vcproj:
3013         * WebCore.xcodeproj/project.pbxproj:
3014         * css/CSSComputedStyleDeclaration.cpp:
3015         (WebCore::CSSComputedStyleDeclaration::valueForFilter):
3016         * css/CSSParser.cpp:
3017         (WebCore::CSSParser::isBlendMode):
3018         (WebCore):
3019         (WebCore::CSSParser::isCompositeOperator):
3020         (WebCore::CSSParser::parseMixFunction):
3021         (WebCore::CSSParser::parseCustomFilter):
3022         * css/CSSParser.h:
3023         (WebCore):
3024         * css/CSSParserValues.h:
3025         (WebCore::CSSParserValueList::currentIndex):
3026         * css/CSSPrimitiveValueMappings.h:
3027         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
3028         (WebCore):
3029         (WebCore::CSSPrimitiveValue::operator BlendMode):
3030         * css/CSSValue.cpp:
3031         (WebCore::CSSValue::reportMemoryUsage):
3032         (WebCore::CSSValue::cssText):
3033         (WebCore::CSSValue::destroy):
3034         (WebCore::CSSValue::cloneForCSSOM):
3035         * css/CSSValue.h:
3036         (WebCore::CSSValue::isWebKitCSSMixFunctionValue):
3037         (CSSValue):
3038         * css/CSSValueKeywords.in:
3039         * css/StyleResolver.cpp:
3040         (WebCore::StyleResolver::collectMatchingRulesForList):
3041         * css/WebKitCSSMixFunctionValue.cpp: Added.
3042         (WebCore):
3043         (WebCore::WebKitCSSMixFunctionValue::WebKitCSSMixFunctionValue):
3044         (WebCore::WebKitCSSMixFunctionValue::customCssText):
3045         (WebCore::WebKitCSSMixFunctionValue::cloneForCSSOM):
3046         (WebCore::WebKitCSSMixFunctionValue::reportDescendantMemoryUsage):
3047         * css/WebKitCSSMixFunctionValue.h: Added.
3048         (WebCore):
3049         (WebKitCSSMixFunctionValue):
3050         (WebCore::WebKitCSSMixFunctionValue::create):
3051         * platform/graphics/GraphicsTypes.h:
3052         * platform/graphics/filters/CustomFilterProgram.cpp:
3053         (WebCore::CustomFilterProgram::CustomFilterProgram):
3054         * platform/graphics/filters/CustomFilterProgram.h:
3055         (WebCore::CustomFilterProgramMixSettings::CustomFilterProgramMixSettings):
3056         (CustomFilterProgramMixSettings):
3057         (WebCore):
3058         * rendering/style/StyleCustomFilterProgram.h:
3059         (WebCore::StyleCustomFilterProgram::create):
3060         (WebCore::StyleCustomFilterProgram::StyleCustomFilterProgram):
3061
3062 2012-08-06  No'am Rosenthal  <noam.rosenthal@nokia.com>
3063
3064         GraphicsLayerAnimation shouldn't use HashMap<String>
3065         https://bugs.webkit.org/show_bug.cgi?id=93284
3066
3067         Reviewed by Kenneth Rohde Christiansen.
3068
3069         Use a vector containing all the animations instead of a map of String to Vector.
3070         The HashMap contains very few elements, which makes it inefficient relatively to a vector.
3071         This has been shown to be a bottleneck in valgrind.
3072
3073         Covered by existing animation tests.
3074
3075         * platform/graphics/GraphicsLayerAnimation.cpp:
3076         (WebCore::GraphicsLayerAnimation::GraphicsLayerAnimation):
3077         (WebCore::GraphicsLayerAnimations::hasActiveAnimationsOfType):
3078         (WebCore::GraphicsLayerAnimations::hasRunningAnimations):
3079         (WebCore::GraphicsLayerAnimations::add):
3080         (WebCore::GraphicsLayerAnimations::pause):
3081         (WebCore::GraphicsLayerAnimations::remove):
3082         (WebCore::GraphicsLayerAnimations::apply):
3083         * platform/graphics/GraphicsLayerAnimation.h:
3084         (GraphicsLayerAnimation):
3085         (WebCore::GraphicsLayerAnimation::name):
3086         (GraphicsLayerAnimations):
3087         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
3088         (WebCore::GraphicsLayerTextureMapper::addAnimation):
3089
3090 2012-08-06  Beth Dakin  <bdakin@apple.com>
3091
3092         https://bugs.webkit.org/show_bug.cgi?id=93199
3093         REGRESSION (r124489): Crash in FrameView::scrollContentsFastPath when 
3094         scrolling Facebook and Google image search
3095         -and corresponding-
3096         <rdar://problem/12035066>
3097
3098         Reviewed by Anders Carlsson.
3099
3100         As the comment in setShouldUpdateScrollLayerPositionOnMainThread() 
3101         indicates, the goal of adding a call to 
3102         updateMainFrameScrollPositionAndScrollLayerPosition() within that 
3103         function was just to make sure the layer position was up-to-date 
3104         since that is what is not kept up to date when scrolling is happening 
3105         on the scrolling thread. So I'm fixing this crash by having that code 
3106         ONLY update the layer position instead of also updating the scroll 
3107         position, since it was updating the scroll position that led to this 
3108         crash.
3109
3110         New function updateMainFrameScrollLayerPosition() will update JUST 
3111         the layer position.
3112         * page/scrolling/ScrollingCoordinator.h:
3113         (ScrollingCoordinator):        
3114         * page/scrolling/ScrollingCoordinator.cpp:
3115         (WebCore::ScrollingCoordinator::updateMainFrameScrollLayerPosition):
3116
3117         Update just the layer position here instead of the layer position and 
3118         the scroll position.
3119         (WebCore)::
3120 (WebCore::ScrollingCoordinator::setShouldUpdateScrollLayerPositionOnMainThread):
3121
3122 2012-08-06  Anna Cavender  <annacc@chromium.org>
3123
3124         MediaSource should use it's own list of source URLs
3125         https://bugs.webkit.org/show_bug.cgi?id=93285
3126
3127         Reviewed by Eric Carlson.
3128
3129         r124780 added MediaSource objects to PublicURLManager's streamURLs list,
3130         piggy-backing on MEDIA_STREAM.  This patch creates a sourceURLs list so
3131         that MediaSource can stand on its own.
3132
3133         Test: builds on Andriod even when MEDIA_STREAM is disabled.
3134
3135         * html/DOMURL.cpp:
3136         (WebCore::DOMURL::createObjectURL):
3137         * html/PublicURLManager.h:
3138         (WebCore::PublicURLManager::contextDestroyed):
3139         (PublicURLManager):
3140         (WebCore::PublicURLManager::sourceURLs):
3141
3142 2012-08-06  Nico Weber  <thakis@chromium.org>
3143
3144         [chromium/mac] Unbreak debug builds with the 10.7 SDK
3145         https://bugs.webkit.org/show_bug.cgi?id=93202
3146
3147         Reviewed by James Robinson.
3148
3149         FMGetATSFontRefFromFont() is not available with the 10.7 SDK
3150         when targetting 10.6. Don't delete this code completely yet,
3151         it's still used with the 10.6 SDK when targetting 10.6 (which
3152         chromium's build bots use).
3153
3154         * platform/graphics/mac/SimpleFontDataMac.mm:
3155         (WebCore):
3156
3157 2012-07-31  Ojan Vafai  <ojan@chromium.org>
3158
3159         need tests to ensure flexboxes play nicely with box-sizing
3160         https://bugs.webkit.org/show_bug.cgi?id=70771
3161
3162         Reviewed by Tony Chang.
3163
3164         Anytime we grab the width/height off of the RenderStyle, we need to adjust
3165         it for box-sizing. Fortunately, we only do this two places in RenderFlexibleBox.
3166         Also, delete crossAxisLength since it's unused.
3167
3168         Test: css3/flexbox/box-sizing.html
3169
3170         * rendering/RenderFlexibleBox.cpp:
3171         (WebCore::RenderFlexibleBox::preferredMainAxisContentExtentForChild):
3172         * rendering/RenderFlexibleBox.h:
3173
3174 2012-08-06  John J. Barton  <johnjbarton@chromium.org>
3175
3176         Web Inspector: WebInspector.linkifyStringAsFragment gives wrong typeof lineNumber
3177         https://bugs.webkit.org/show_bug.cgi?id=93019
3178
3179         Reviewed by Pavel Feldman.
3180
3181         Add test for WebInspector.linkifyStringAsFragment()
3182
3183         * inspector/front-end/ResourceUtils.js:
3184         (WebInspector.linkifyStringAsFragmentWithCustomLinkifier):
3185
3186 2012-08-06  David Reveman  <reveman@chromium.org>
3187
3188         [Chromium] Refactor CCTextureUpdater into CCTextureUpdater and CCTextureUpdateController.
3189         https://bugs.webkit.org/show_bug.cgi?id=92596
3190
3191         Reviewed by Adrienne Walker.
3192
3193         The CCTextureUpdater interface is used by the main thread to queue
3194         texture updates. The CCTextureUpdateController constructor takes a
3195         CCTextureUpdater and contains the logic required to perform texture
3196         uploads and texture copies. This class is only used by the impl thread.
3197
3198         No new tests.
3199
3200         * WebCore.gypi:
3201         * platform/graphics/chromium/LayerRendererChromium.cpp:
3202         * platform/graphics/chromium/ScrollbarLayerChromium.cpp:
3203         (WebCore::ScrollbarLayerChromium::updatePart):
3204         * platform/graphics/chromium/TextureCopier.cpp:
3205         (WebCore::AcceleratedTextureCopier::copyTexture):
3206         * platform/graphics/chromium/TextureCopier.h:
3207         (Parameters):
3208         (TextureCopier):
3209         (AcceleratedTextureCopier):
3210         * platform/graphics/chromium/TextureUploader.h:
3211         (Parameters):
3212         (TextureUploader):
3213         * platform/graphics/chromium/ThrottledTextureUploader.cpp:
3214         (WebCore::ThrottledTextureUploader::uploadTexture):
3215         * platform/graphics/chromium/ThrottledTextureUploader.h:
3216         (ThrottledTextureUploader):
3217         * platform/graphics/chromium/TiledLayerChromium.cpp:
3218         (WebCore::TiledLayerChromium::updateTiles):
3219         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp:
3220         (WebCore::CCSingleThreadProxy::doCommit):
3221         * platform/graphics/chromium/cc/CCTextureUpdateController.cpp: Added.
3222         (WebCore):
3223         (WebCore::CCTextureUpdateController::maxPartialTextureUpdates):
3224         (WebCore::CCTextureUpdateController::updateTextures):
3225         (WebCore::CCTextureUpdateController::CCTextureUpdateController):
3226         (WebCore::CCTextureUpdateController::~CCTextureUpdateController):
3227         (WebCore::CCTextureUpdateController::hasMoreUpdates):
3228         (WebCore::CCTextureUpdateController::updateMoreTextures):
3229         (WebCore::CCTextureUpdateController::updateMoreTexturesSize):
3230         * platform/graphics/chromium/cc/CCTextureUpdateController.h: Copied from Source/WebCore/platform/graphics/chromium/cc/CCTextureUpdater.h.
3231         (WebCore):
3232         (CCTextureUpdateController):
3233         (WebCore::CCTextureUpdateController::create):
3234         * platform/graphics/chromium/cc/CCTextureUpdater.cpp:
3235         (WebCore::CCTextureUpdater::appendFullUpload):
3236         (WebCore::CCTextureUpdater::appendPartialUpload):
3237         (WebCore::CCTextureUpdater::appendCopy):
3238         (WebCore::CCTextureUpdater::takeFirstFullUpload):
3239         (WebCore::CCTextureUpdater::takeFirstPartialUpload):
3240         (WebCore::CCTextureUpdater::takeFirstCopy):
3241         (WebCore::CCTextureUpdater::hasMoreUpdates):
3242         * platform/graphics/chromium/cc/CCTextureUpdater.h:
3243         (CCTextureUpdater):
3244         (WebCore::CCTextureUpdater::fullUploadSize):
3245         (WebCore::CCTextureUpdater::partialUploadSize):
3246         (WebCore::CCTextureUpdater::copySize):
3247         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
3248         (WebCore::CCThreadProxy::scheduledActionBeginFrame):
3249         (WebCore::CCThreadProxy::beginFrame):
3250         (WebCore::CCThreadProxy::beginFrameCompleteOnImplThread):
3251         (WebCore::CCThreadProxy::hasMoreResourceUpdates):
3252         (WebCore::CCThreadProxy::scheduledActionUpdateMoreResources):
3253         (WebCore::CCThreadProxy::scheduledActionCommit):
3254         (WebCore::CCThreadProxy::maxPartialTextureUpdates):
3255         * platform/graphics/chromium/cc/CCThreadProxy.h:
3256         (WebCore):
3257         (WebCore::CCThreadProxy::BeginFrameAndCommitState::BeginFrameAndCommitState):
3258         (BeginFrameAndCommitState):
3259         (CCThreadProxy):
3260
3261 2012-08-06  Douglas Stockwell  <dstockwell@chromium.org>
3262
3263         Crash in WebCore::RenderListItem::updateMarkerLocation
3264         https://bugs.webkit.org/show_bug.cgi?id=90476
3265
3266         Reviewed by Abhishek Arya.
3267
3268         In some cases an anonymous block is destroyed when its last child is
3269         removed. RenderListItem did not expect this and has it's own logic for
3270         cleaning up such blocks when the list marker is removed. Detect this
3271         case in RenderBlock::removeChild to defer to the logic in RenderListItem::updateListMarker.
3272
3273         Test: fast/lists/list-marker-remove-crash.html
3274
3275         * rendering/RenderBlock.cpp:
3276         (WebCore::RenderBlock::removeChild):
3277
3278 2012-08-06  Shawn Singh  <shawnsingh@chromium.org>
3279
3280         [chromium] Non-preserves-3d requires explicit flattening of screen-space transform.
3281         https://bugs.webkit.org/show_bug.cgi?id=85808
3282
3283         Reviewed by Adrienne Walker.
3284
3285         When computing the screen-space transforms, z values were not
3286         being flattened when they should be. This caused incorrect
3287         clipping due to occlusion tracking that relied on the screen-space
3288         transform. The fix is to flatten the screen-space transform just
3289         like the "sublayerMatrix" is flattened, when the layer does not
3290         preserve-3d.
3291
3292         In addition to making the simple fix, it was convenient to make a
3293         helper function for the flattening code.
3294
3295         Additional unit test added to exercise that flattening code:
3296           CCLayerTreeHostCommonTest.verifyTransformsForFlatteningLayer
3297
3298         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
3299         (WebCore::calculateDrawTransformsInternal):
3300         * platform/graphics/chromium/cc/CCMathUtil.cpp:
3301         (WebCore::CCMathUtil::flattenTransformTo2d):
3302         (WebCore):
3303         * platform/graphics/chromium/cc/CCMathUtil.h:
3304         (CCMathUtil):
3305
3306 2012-08-06  Anna Cavender  <annacc@chromium.org>
3307
3308         Create a MediaSource object.
3309         https://bugs.webkit.org/show_bug.cgi?id=91773
3310
3311         Reviewed by Eric Carlson.
3312
3313         MediaSource object is needed in order to implement the new
3314         object-oriented MediaSource API:
3315         http://dvcs.w3.org/hg/html-media/raw-file/tip/media-source/media-source.html
3316
3317         No new tests - will be able to test after landing:
3318         https://bugs.webkit.org/show_bug.cgi?id=91775
3319  
3320         Adding new files to build files:
3321         * CMakeLists.txt:
3322         * DerivedSources.cpp:
3323         * DerivedSources.make:
3324         * DerivedSources.pri:
3325         * GNUmakefile.list.am:
3326         * Target.pri:
3327         * WebCore.gypi:
3328         * WebCore.vcproj/WebCore.vcproj:
3329         * WebCore.xcodeproj/project.pbxproj:
3330
3331         New MediaSource object:
3332         * Modules/mediasource/MediaSource.cpp: Added.
3333         * Modules/mediasource/MediaSource.h: Added.
3334         * Modules/mediasource/MediaSource.idl: Added.
3335
3336         Create a registry for the blob storage and lookup:
3337         * Modules/mediasource/MediaSourceRegistry.cpp: Added.
3338         * Modules/mediasource/MediaSourceRegistry.h: Added.
3339
3340         Connect SourceBuffer to MediaSource:
3341         * Modules/mediasource/SourceBuffer.cpp:
3342         (WebCore::SourceBuffer::SourceBuffer):
3343         (WebCore::SourceBuffer::buffered): Forward call to MediaSource.
3344         (WebCore::SourceBuffer::append): Ditto.
3345         (WebCore::SourceBuffer::abort): Ditto.
3346         * Modules/mediasource/SourceBuffer.h:
3347         (WebCore::SourceBuffer::create): Add a MediaSource to the constructor.
3348         (WebCore::SourceBuffer::clear): Clear the MediaSource.
3349         (SourceBuffer):
3350         * Modules/mediasource/SourceBufferList.cpp: include SourceBuffer.h
3351         * Modules/mediasource/SourceBufferList.h:
3352  
3353         Make MediaSource an EventTarget:
3354         * dom/EventTarget.h:
3355         (WebCore):
3356         * dom/EventTargetFactory.in:
3357
3358         Enable creation of MediaSource object URL from JavaScript:
3359         * html/DOMURL.cpp:
3360         (WebCore):
3361         (WebCore::DOMURL::createObjectURL):
3362         * html/DOMURL.h:
3363         (WebCore):
3364         (DOMURL):
3365         * html/DOMURL.idl:
3366
3367         New MediaSource constructor:
3368         * page/DOMWindow.idl:
3369
3370 2012-08-06  Andreas Kling  <kling@webkit.org>
3371
3372         Simplify CSSOM style declaration's grabbing at internals.
3373         <http://webkit.org/b/93261>
3374
3375         Reviewed by Antti Koivisto.
3376
3377         It was already the case that StylePropertySets exposed in CSSOM were guaranteed mutable,
3378         so remove the mechanism to convert immutable backing objects to mutable ones.
3379
3380         Made ensureCSSStyleDeclaration() non-const to prevent callers that may have an
3381         immutable StylePropertySet from wrapping a CSSOM object around it.
3382
3383         * css/PropertySetCSSStyleDeclaration.h:
3384         (PropertySetCSSStyleDeclaration):
3385         * css/PropertySetCSSStyleDeclaration.cpp:
3386         (WebCore::PropertySetCSSStyleDeclaration::length):
3387         (WebCore::PropertySetCSSStyleDeclaration::item):
3388         (WebCore::PropertySetCSSStyleDeclaration::cssText):
3389         (WebCore::PropertySetCSSStyleDeclaration::setCssText):
3390         (WebCore::PropertySetCSSStyleDeclaration::getPropertyCSSValue):
3391         (WebCore::PropertySetCSSStyleDeclaration::getPropertyValue):
3392         (WebCore::PropertySetCSSStyleDeclaration::getPropertyPriority):
3393         (WebCore::PropertySetCSSStyleDeclaration::getPropertyShorthand):
3394         (WebCore::PropertySetCSSStyleDeclaration::isPropertyImplicit):
3395         (WebCore::PropertySetCSSStyleDeclaration::setProperty):
3396         (WebCore::PropertySetCSSStyleDeclaration::removeProperty):
3397         (WebCore::PropertySetCSSStyleDeclaration::getPropertyCSSValueInternal):
3398         (WebCore::PropertySetCSSStyleDeclaration::getPropertyValueInternal):
3399         (WebCore::PropertySetCSSStyleDeclaration::setPropertyInternal):
3400         (WebCore::PropertySetCSSStyleDeclaration::copy):
3401         (WebCore::PropertySetCSSStyleDeclaration::makeMutable):
3402         (WebCore::PropertySetCSSStyleDeclaration::cssPropertyMatches):
3403
3404             Remove indirection and access StylePropertySet member directly.
3405
3406         * css/StylePropertySet.h:
3407         * css/StylePropertySet.cpp:
3408         (WebCore::StylePropertySet::ensureCSSStyleDeclaration):
3409         (WebCore::StylePropertySet::ensureInlineCSSStyleDeclaration):
3410
3411             Made these two non-const. CSSOM wrappers should only ever be constructed around
3412             mutable StylePropertySets.
3413             Also added ASSERT(isMutable()).
3414
3415         * inspector/InspectorCSSAgent.cpp:
3416         (WebCore::InspectorCSSAgent::buildObjectForAttributesStyle):
3417
3418             Cast away the constness of StyledElement::attributeStyle(). It's not pretty,
3419             but these objects are guaranteed mutable, and there's an assertion to protect
3420             us in ensureCSSStyleDeclaration() if something changes in the future.
3421
3422 2012-08-06  Andrei Poenaru  <poenaru@adobe.com>
3423
3424         Web Inspector: Protocol: Add "namedFlowCreated" and "namedFlowRemoved" events
3425         https://bugs.webkit.org/show_bug.cgi?id=92739
3426
3427         Reviewed by Pavel Feldman.
3428
3429         Implemented "namedFlowCreated" and "namedFlowRemoved" events.
3430
3431         Modified test: inspector/styles/protocol-css-regions-commands.html.
3432
3433         * dom/WebKitNamedFlowCollection.cpp:
3434         (WebCore::WebKitNamedFlowCollection::ensureFlowWithName):
3435         (WebCore::WebKitNamedFlowCollection::discardNamedFlow):
3436         * inspector/Inspector.json:
3437         * inspector/InspectorCSSAgent.cpp:
3438         (WebCore::InspectorCSSAgent::reset):
3439         (WebCore::InspectorCSSAgent::didCreateNamedFlow):
3440         (WebCore):
3441         (WebCore::InspectorCSSAgent::didRemoveNamedFlow):
3442         (WebCore::InspectorCSSAgent::getNamedFlowCollection):
3443         * inspector/InspectorCSSAgent.h:
3444         (InspectorCSSAgent):
3445         * inspector/InspectorInstrumentation.cpp:
3446         (WebCore):
3447         (WebCore::InspectorInstrumentation::didCreateNamedFlowImpl):
3448         (WebCore::InspectorInstrumentation::didRemoveNamedFlowImpl):
3449         * inspector/InspectorInstrumentation.h:
3450         (InspectorInstrumentation):
3451         (WebCore::InspectorInstrumentation::didCreateNamedFlow):
3452         (WebCore):
3453         (WebCore::InspectorInstrumentation::didRemoveNamedFlow):
3454         * inspector/front-end/CSSStyleModel.js:
3455         (WebInspector.CSSStyleModel.prototype._namedFlowCreated.callback):
3456         (WebInspector.CSSStyleModel.prototype._namedFlowCreated):
3457         (WebInspector.CSSStyleModel.prototype._namedFlowRemoved.callback):
3458         (WebInspector.CSSStyleModel.prototype._namedFlowRemoved):
3459         (WebInspector.CSSDispatcher.prototype.styleSheetChanged):
3460         (WebInspector.CSSDispatcher.prototype.namedFlowCreated):
3461         (WebInspector.CSSDispatcher.prototype.namedFlowRemoved):
3462
3463 2012-08-06  Abhishek Arya  <inferno@chromium.org>
3464
3465         Crash in FrameLoader::stopAllLoaders.
3466         https://bugs.webkit.org/show_bug.cgi?id=90805
3467
3468         Reviewed by Nate Chapin.
3469
3470         Calling m_provisionalDocumentLoader->stopLoading() can blow away the