7f70868627029d18c3731ee31f22f88d69e23d7c
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2012-08-21  Sukolsak Sakshuwong  <sukolsak@google.com>
2
3         Remove UndoManager's undoscope content attribute
4         https://bugs.webkit.org/show_bug.cgi?id=94637
5
6         Reviewed by Ryosuke Niwa.
7
8         No new tests. Covered by existing tests.
9
10         * bindings/v8/DOMTransaction.cpp:
11         (WebCore::DOMTransaction::callFunction):
12         * dom/Document.cpp:
13         (WebCore::Document::undoManager):
14         * dom/Element.cpp:
15         (WebCore::Element::~Element):
16         (WebCore):
17         * dom/Element.h:
18         (Element):
19         * dom/Element.idl:
20         * dom/ElementRareData.h:
21         (ElementRareData):
22         * editing/UndoManager.cpp:
23         (WebCore::UndoManager::create):
24         (WebCore::UndoManager::UndoManager):
25         (WebCore::UndoManager::disconnect):
26         (WebCore::UndoManager::transact):
27         (WebCore::UndoManager::undo):
28         (WebCore::UndoManager::redo):
29         (WebCore::UndoManager::clearUndo):
30         (WebCore::UndoManager::clearRedo):
31         (WebCore):
32         * editing/UndoManager.h:
33         (WebCore):
34         (UndoManager):
35         (WebCore::UndoManager::document):
36         (WebCore::UndoManager::ownerNode):
37         * html/HTMLAttributeNames.in:
38         * html/HTMLElement.cpp:
39         (WebCore::HTMLElement::parseAttribute):
40         (WebCore::HTMLElement::setContentEditable):
41
42 2012-08-21  Joanmarie Diggs  <jdiggs@igalia.com>
43
44         [Gtk] No accessible caret-moved events found in certain content
45         https://bugs.webkit.org/show_bug.cgi?id=72811
46
47         Reviewed by Chris Fleizach.
48
49         Part of the bug is due to objects which should claim to implement AtkText
50         failed to do so as a result of containing a mixture of inline and block
51         spans.
52
53         An updated unit test was provided.
54
55         * accessibility/gtk/WebKitAccessibleWrapperAtk.cpp:
56         (roleIsTextType): New method to check if a role is one expected to have
57         implemented the AtkText interface. Currently that is defined as:
58          - ParagraphRole
59          - HeadingRole
60          - DivRole
61          - CellRole
62         (getInterfaceMaskFromObject): If a role is one of the text type roles,
63         automatically add WAI_TEXT to the accessible object's interface mask.
64
65 2012-08-21  Tony Chang  <tony@chromium.org>
66
67         Force XML comments to maintain whitespace
68         https://bugs.webkit.org/show_bug.cgi?id=94620
69
70         Reviewed by Pavel Feldman.
71
72         Fix a typo in XMLViewer.css for white-space formatting. This seems
73         like the desired behavior so you can see, e.g., code formatted in an
74         XML comment.
75
76         Covered by existing xmlviewer tests in http/tests/xmlviewer/dumpAsText
77
78         * xml/XMLViewer.css:
79         (.comment): Fix typo.
80         * xml/XMLViewer.js:
81         (createComment): Add style to comment nodes.
82
83 2012-08-21  Sheriff Bot  <webkit.review.bot@gmail.com>
84
85         Unreviewed, rolling out r126202.
86         http://trac.webkit.org/changeset/126202
87         https://bugs.webkit.org/show_bug.cgi?id=94657
88
89         Causes assertion failures on Chromium Linux dbg compositing
90         layout tests (Requested by dominicc on #webkit).
91
92         * platform/graphics/chromium/FrameBufferSkPictureCanvasLayerTextureUpdater.cpp:
93         (WebCore::FrameBufferSkPictureCanvasLayerTextureUpdater::updateTextureRect):
94         * platform/graphics/chromium/LayerRendererChromium.cpp:
95         (WebCore::applyFilters):
96         (WebCore::LayerRendererChromium::drawRenderPassQuad):
97         (WebCore::LayerRendererChromium::drawTileQuad):
98         (WebCore::LayerRendererChromium::drawYUVVideoQuad):
99         (WebCore::LayerRendererChromium::drawTextureQuad):
100         (WebCore::LayerRendererChromium::getFramebufferTexture):
101         (WebCore::LayerRendererChromium::bindFramebufferToTexture):
102         * platform/graphics/chromium/LayerRendererChromium.h:
103         (LayerRendererChromium):
104         * platform/graphics/chromium/cc/CCResourceProvider.cpp:
105         (WebCore::CCResourceProvider::createResource):
106         (WebCore::CCResourceProvider::createResourceFromExternalTexture):
107         (WebCore::CCResourceProvider::deleteResource):
108         (WebCore::CCResourceProvider::upload):
109         (WebCore::CCResourceProvider::lockForWrite):
110         (WebCore::CCResourceProvider::unlockForWrite):
111         (WebCore::CCResourceProvider::flush):
112         (WebCore::CCResourceProvider::shallowFlushIfSupported):
113         (WebCore::CCResourceProvider::lockForRead):
114         (WebCore::CCResourceProvider::unlockForRead):
115         (WebCore::CCResourceProvider::CCResourceProvider):
116         * platform/graphics/chromium/cc/CCResourceProvider.h:
117         (WebCore):
118         (CCResourceProvider):
119         (WebCore::CCResourceProvider::Resource::Resource):
120         (Resource):
121         (CCScopedLockResourceForRead):
122         (WebCore::CCScopedLockResourceForRead::CCScopedLockResourceForRead):
123         (WebCore::CCScopedLockResourceForRead::~CCScopedLockResourceForRead):
124         (WebCore::CCScopedLockResourceForRead::textureId):
125         (CCScopedLockResourceForWrite):
126         (WebCore::CCScopedLockResourceForWrite::CCScopedLockResourceForWrite):
127         (WebCore::CCScopedLockResourceForWrite::~CCScopedLockResourceForWrite):
128         (WebCore::CCScopedLockResourceForWrite::textureId):
129
130 2012-08-21  David Grogan  <dgrogan@chromium.org>
131
132         IndexedDB: Fire error at request when abort is called in upgradeneeded
133         https://bugs.webkit.org/show_bug.cgi?id=94402
134
135         Reviewed by Tony Chang.
136
137         Tests - updated intversion-abort-in-initial-upgradeneeded-expected.txt
138
139         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
140         (WebCore::IDBDatabaseBackendImpl::transactionFinishedAndAbortFired):
141         (WebCore::IDBDatabaseBackendImpl::transactionFinishedAndCompleteFired):
142         (WebCore):
143         (WebCore::IDBDatabaseBackendImpl::runIntVersionChangeTransaction):
144         Now that second-half open calls don't get abandoned on the queue, we
145         can ASSERT that there's at most one of them at any time.
146
147         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
148         (IDBDatabaseBackendImpl):
149         * Modules/indexeddb/IDBRequest.cpp:
150         (WebCore::IDBRequest::dispatchEvent):
151         Move setting m_didFireUpgradeNeededEvent before dispatching the event.
152         If abort is called in the event handler an error event will be
153         enqueued and ASSERT_WITH_MESSAGE(m_readyState == PENDING ||
154         m_didFireUpgradeNeededEvent, ...) needs to pass.
155
156         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
157         (WebCore::IDBTransactionBackendImpl::abort):
158         (WebCore::IDBTransactionBackendImpl::commit):
159
160 2012-08-21  Sheriff Bot  <webkit.review.bot@gmail.com>
161
162         Unreviewed, rolling out r126233.
163         http://trac.webkit.org/changeset/126233
164         https://bugs.webkit.org/show_bug.cgi?id=94656
165
166         Broke Chromium Mac build (Requested by dominicc on #webkit).
167
168         * CMakeLists.txt:
169         * GNUmakefile.list.am:
170         * Target.pri:
171         * WebCore.gypi:
172         * WebCore.vcproj/WebCore.vcproj:
173         * WebCore.xcodeproj/project.pbxproj:
174         * css/mediaControls.css:
175         (video::-webkit-media-text-track-display):
176         * html/shadow/MediaControlElements.cpp:
177         (RenderTextTrackContainerElement):
178         (WebCore::MediaControlTextTrackContainerElement::updateDisplay):
179         * html/track/TextTrack.cpp:
180         * html/track/TextTrack.h:
181         (TextTrack):
182         * html/track/TextTrackCue.cpp:
183         (WebCore::TextTrackCue::TextTrackCue):
184         (WebCore::TextTrackCue::calculateComputedLinePosition):
185         (WebCore::TextTrackCue::calculateDisplayParameters):
186         (WebCore::TextTrackCue::getDisplayTree):
187         (WebCore::TextTrackCue::getPositionCoordinates):
188         * html/track/TextTrackCue.h:
189         (WebCore):
190         (TextTrackCue):
191         * rendering/RenderTextTrackCue.cpp: Removed.
192         * rendering/RenderTextTrackCue.h: Removed.
193
194 2012-08-20  Kentaro Hara  <haraken@chromium.org>
195
196         [V8] Remove getToStringName() and getToStringTemplate() from V8Binding
197         https://bugs.webkit.org/show_bug.cgi?id=94573
198
199         Reviewed by Adam Barth.
200
201         - Remove V8Binding::getToStringName() and V8Binding::getToStringTemplate().
202
203         - Replace getToStringName() with String::NewSymbol("toString").
204
205         - Fix V8PerIsolateData::getToStringTemplate() so that it caches a persistent
206         handle of a created FunctionTemplate. Before this patch, a FunctionTemplate
207         had been created for each toString().
208
209         No tests. No change in behavior.
210
211         * bindings/v8/V8Binding.cpp:
212         (WebCore::constructorToString):
213         * bindings/v8/V8Binding.h:
214         (WebCore):
215         * bindings/scripts/CodeGeneratorV8.pm:
216         (GenerateImplementation):
217         * bindings/scripts/test/V8/V8Float64Array.cpp:
218         (WebCore::ConfigureV8Float64ArrayTemplate):
219         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
220         (WebCore::ConfigureV8TestActiveDOMObjectTemplate):
221         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
222         (WebCore::ConfigureV8TestCustomNamedGetterTemplate):
223         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
224         (WebCore::ConfigureV8TestEventConstructorTemplate):
225         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
226         (WebCore::ConfigureV8TestEventTargetTemplate):
227         * bindings/scripts/test/V8/V8TestException.cpp:
228         (WebCore::ConfigureV8TestExceptionTemplate):
229         * bindings/scripts/test/V8/V8TestInterface.cpp:
230         (WebCore::ConfigureV8TestInterfaceTemplate):
231         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
232         (WebCore::ConfigureV8TestMediaQueryListListenerTemplate):
233         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
234         (WebCore::ConfigureV8TestNamedConstructorTemplate):
235         * bindings/scripts/test/V8/V8TestNode.cpp:
236         (WebCore::ConfigureV8TestNodeTemplate):
237         * bindings/scripts/test/V8/V8TestObj.cpp:
238         (WebCore::ConfigureV8TestObjTemplate):
239         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
240         (WebCore::ConfigureV8TestSerializedScriptValueInterfaceTemplate):
241         * bindings/v8/V8PerIsolateData.h:
242         (V8PerIsolateData):
243
244 2012-08-21  Arvid Nilsson  <anilsson@rim.com>
245
246         [BlackBerry] WebGL Aquarium fails to render
247         https://bugs.webkit.org/show_bug.cgi?id=94634
248
249         The aquarium leaves with a glColorMask(false, false, false, true) which
250         caused us to fail to blit the color components of the aquarium to the
251         EGLImage.
252
253         Fixed by setting an appropriate color mask for a blit operation.
254
255         Reviewed by Yong Li.
256
257         No new tests, tested manually.
258
259         * platform/graphics/blackberry/EGLImageLayerWebKitThread.cpp:
260         (WebCore::EGLImageLayerWebKitThread::blitToFrontBuffer):
261
262 2012-08-21  Victor Carbune  <victor@rosedu.org>
263
264         Display a TextTrackCue when snap-to-lines flag is set
265         https://bugs.webkit.org/show_bug.cgi?id=79751
266
267         Reviewed by Tony Chang.
268
269         This patch implements rendering functionality for a given text track,
270         following closer the exact WebVTT specification. There are two new classes
271         which have been added in order to succesfully cover rendering when of a text
272         track cue.
273
274         RenderTextTrackCue handles the specific rendering algorithm required,
275         by checking for overlaps with other boxes that are in the same
276         container (these can be any other boxes, not necessarily other cues,
277         the video controls, for example).
278
279         TextTrackCueBox extends HTMLDivElement and is an intermediate layer
280         between the renderer class and the actual cue object. Its purpose is
281         to instantiate the particular renderer and cover all the default CSS
282         styling that needs to be applied to the cue.
283
284         The layout is done in two steps:
285           - Step 1: Layout the TextTrackCue with default CSS properties set (this is
286         the TextTrackCueBox decorated with the respective CSS elements)
287           - Step 2: RenderTextTrackCue adjusts the box position depending on the
288         parameters of the TextTrackCue object and the overlaps that may occur with
289         previously positioned cues.
290
291         Tests: media/track/track-cue-rendering-horizontal.html
292                media/track/track-cue-rendering-vertical.html
293
294         * CMakeLists.txt: Updated to include RenderTextTrackCue.
295         * GNUmakefile.list.am: Updated to include RenderTextTrackCue.
296         * Target.pri: Updated to include RenderTextTrackCue.
297         * WebCore.gypi: Updated to include RenderTextTrackCue.
298         * WebCore.vcproj/WebCore.vcproj: Updated to include RenderTextTrackCue.
299         * WebCore.xcodeproj/project.pbxproj: Updated to include RenderTextTrackCue.
300         * css/mediaControls.css: Removed unreliable CSS.
301         (video::-webkit-media-text-track-display): Removed properties.
302         * html/shadow/MediaControlElements.cpp: Updated to not use the new class.
303         (RenderTextTrackContainerElement):
304         (WebCore::MediaControlTextTrackContainerElement::updateDisplay): Simplified
305         the function by moving the check if track is rendered in TextTrack and used
306         the TextTrackCueBox for cues.
307         * html/track/TextTrack.cpp: Added a new method.
308         (WebCore::TextTrack::isRendered): Method that returns whether the track should
309         be rendered or not.
310         (WebCore):
311         * html/track/TextTrack.h: Added the isRendered method.
312         (TextTrack):
313         * html/track/TextTrackCue.cpp: Added several helper methods and
314         the TextTrackCueBox.
315         (WebCore):
316         (WebCore::TextTrackCueBox::TextTrackCueBox): The TextTrackCueBox extends
317         the HTMLDivElement and represents a bridge class between RenderTextTrackCue
318         and TextTrackCue. This is required as the layout is done in two steps, as
319         explained on top of the ChangeLog entry.
320         (WebCore::TextTrackCueBox::getCue): Returns the associated TextTrackCue object.
321         (WebCore::TextTrackCueBox::applyCSSProperties): Applies a part of the default CSS
322         properties, as defined by section 3.5.1 of the WebVTT specification.
323         (WebCore::TextTrackCueBox::shadowPseudoId): Moved the shadow pseudo id.
324         (WebCore::TextTrackCueBox::createRenderer): Creates the particular renderer.
325         (WebCore::TextTrackCue::TextTrackCue): Corrected the internal writing mode map.
326         (WebCore::TextTrackCue::calculateComputedLinePosition): Updated the compute line
327         position algorithm. This requires, however, a method to consider only rendered
328         tracks (and therefore will be addressed completely in subsequent changeset).
329         (WebCore::TextTrackCue::calculateDisplayParameters): Updated and corrected the
330         computed display parameters to match the current specification.
331         (WebCore::TextTrackCue::getDisplayTree): Update to use the TextTrackCueBox class
332         and moved CSS application to the respective class.
333         (WebCore::TextTrackCue::getPositionCoordinates): Added comment to specify in which
334         situation this method is used and change visibility to private.
335         (WebCore::TextTrackCue::getCSSWritingMode): Returns the CSS writing mode corresponding
336         to the cue writing mode.
337         (WebCore::TextTrackCue::getCSSSize): Returns the cue width / height (depending on the
338         writing direction.
339         (WebCore::TextTrackCue::getCSSPosition): Returns the default display position, that is
340         used in the first layout step.
341         * html/track/TextTrackCue.h:
342         (WebCore):
343         (TextTrackCueBox):
344         (WebCore::TextTrackCueBox::create): Initialization method.
345         (TextTrackCue):
346         (WebCore::TextTrackCue::getWritingDirection): Helper method to return the internal
347         values used to represent the writing direction.
348         * rendering/RenderTextTrackCue.cpp: Added.
349         (WebCore):
350         (WebCore::RenderTextTrackCue::RenderTextTrackCue):
351         (WebCore::RenderTextTrackCue::layout): The rendering steps, as mentioned in
352         the WebVTT rendering rules. Currently, this treats only the snap-to-lines set
353         case. It is implemented following closely the spec, and might be subject to
354         change as discussions on various bugs evolve.
355         (WebCore::RenderTextTrackCue::initializeLayoutParameters): Steps 1 - 7.
356         (WebCore::RenderTextTrackCue::placeBoxInDefaultPosition): Steps 8 - 10.
357         (WebCore::RenderTextTrackCue::isOutside): Inline method to check if the cue is outside.
358         (WebCore::RenderTextTrackCue::isOverlapping): Inline method to check if the cue overlaps other boxes.
359         (WebCore::RenderTextTrackCue::shouldSwitchDirection): Step 12.
360         (WebCore::RenderTextTrackCue::moveBoxesByStep): Step 13.
361         (WebCore::RenderTextTrackCue::switchDirection): Steps 15 - 18.
362         (WebCore::RenderTextTrackCue::repositionCueSnapToLinesSet): Cue repositioning
363         for text track cue when the snap to lines flag is set.
364         (WebCore::RenderTextTrackCue::repositionCueSnapToLinesNotSet): Cue repositioning
365         for text track cue when the snap to lines flag is not set. Not implemented yet.
366         * rendering/RenderTextTrackCue.h: Added.
367         (WebCore):
368         (RenderTextTrackCue): Rendering class, handling the display of cues.
369
370 2012-08-21  Lianghui Chen  <liachen@rim.com>
371
372         [BlackBerry] Add RSS content handling support
373         https://bugs.webkit.org/show_bug.cgi?id=93496
374
375         Reviewed by Rob Buis.
376
377         Add code to filter RSS content, and properly convert them to HTML
378         content so they can display nicely, instead of as plain text.
379
380         Following modules are included:
381
382         RSSFilterStream: the code for detecting RSS content, and controlling
383         the handling of these content.
384
385         RSSParserBase: the base class for the following 3 RSS parser.
386         RSS10Parser: the code for decoding RSS 1.0 content.
387         RSS20Parser: the code for decoding RSS 2.0 content.
388         RSSAtomParser: the code for decoding Atom format RSS content.
389         RSSGenerator: the code for generating HTML content based on RSS feed.
390
391         No new tests as it's not changing how HTML content is handled.
392
393         * PlatformBlackBerry.cmake:
394         * platform/network/blackberry/NetworkJob.cpp:
395         (WebCore::NetworkJob::initialize):
396         * platform/network/blackberry/rss/RSS10Parser.cpp: Added.
397         (WebCore):
398         (WebCore::RSS10Parser::RSS10Parser):
399         (WebCore::RSS10Parser::parseBuffer):
400         (WebCore::RSS10Parser::parseXmlDoc):
401         (WebCore::RSS10Parser::parseItemBaseAttribute):
402         (WebCore::RSS10Parser::parseItem):
403         (WebCore::RSS10Parser::parseFeed):
404         * platform/network/blackberry/rss/RSS10Parser.h: Added.
405         (WebCore):
406         (RSS10Parser):
407         * platform/network/blackberry/rss/RSS20Parser.cpp: Added.
408         (WebCore):
409         (WebCore::RSS20Parser::RSS20Parser):
410         (WebCore::RSS20Parser::parseBuffer):
411         (WebCore::RSS20Parser::parseXmlDoc):
412         (WebCore::RSS20Parser::parseItemBaseAttribute):
413         (WebCore::RSS20Parser::parseItem):
414         (WebCore::RSS20Parser::parseFeed):
415         (WebCore::RSS20Parser::parseEnclosure):
416         * platform/network/blackberry/rss/RSS20Parser.h: Added.
417         (WebCore):
418         (RSS20Parser):
419         * platform/network/blackberry/rss/RSSAtomParser.cpp: Added.
420         (WebCore):
421         (WebCore::isRelativePath):
422         (WebCore::RSSAtomLink::relType):
423         (WebCore::RSSAtomParser::RSSAtomParser):
424         (WebCore::RSSAtomParser::parseBuffer):
425         (WebCore::RSSAtomParser::parseXmlDoc):
426         (WebCore::RSSAtomParser::parseItemBaseAttribute):
427         (WebCore::RSSAtomParser::parseItem):
428         (WebCore::RSSAtomParser::parseFeed):
429         (WebCore::RSSAtomParser::parseLink):
430         (WebCore::RSSAtomParser::enclosureFromLink):
431         (WebCore::RSSAtomParser::parseContent):
432         (WebCore::RSSAtomParser::parseAuthor):
433         (WebCore::RSSAtomParser::parseCategory):
434         * platform/network/blackberry/rss/RSSAtomParser.h: Added.
435         (WebCore):
436         (RSSAtomLink):
437         (WebCore::RSSAtomLink::RSSAtomLink):
438         (RSSAtomParser):
439         * platform/network/blackberry/rss/RSSFilterStream.cpp: Added.
440         (WebCore):
441         (WebCore::isASCIISpaceLowerByte):
442         (WebCore::stripWhiteSpace):
443         (WebCore::equalIgnoringCase):
444         (WebCore::isAtomMIMEType):
445         (WebCore::isRSSMIMEType):
446         (WebCore::isPotentialRSSMIMEType):
447         (WebCore::isRSSContent):
448         (WebCore::RSSTypeFromContentType):
449         (WebCore::RSSTypeFromContent):
450         (WebCore::createParser):
451         (WebCore::findXMLEncodingPosition):
452         (WebCore::findXMLLanguagePosition):
453         (WebCore::defaultEncodingForLanguage):
454         (WebCore::isTranscodingNeeded):
455         (WebCore::transcode):
456         (WebCore::transcodeContent):
457         (WebCore::RSSFilterStream::RSSFilterStream):
458         (WebCore::RSSFilterStream::notifyStatusReceived):
459         (WebCore::RSSFilterStream::notifyHeadersReceived):
460         (WebCore::RSSFilterStream::notifyDataReceived):
461         (WebCore::RSSFilterStream::notifyClose):
462         (WebCore::RSSFilterStream::convertContentToHtml):
463         (WebCore::RSSFilterStream::handleRSSContent):
464         (WebCore::RSSFilterStream::charset):
465         (WebCore::RSSFilterStream::encoding):
466         (WebCore::RSSFilterStream::saveHeaders):
467         (WebCore::RSSFilterStream::removeHeader):
468         (WebCore::RSSFilterStream::updateHeader):
469         (WebCore::RSSFilterStream::updateRSSHeaders):
470         (WebCore::RSSFilterStream::sendSavedHeaders):
471         (WebCore::RSSFilterStream::appendData):
472         * platform/network/blackberry/rss/RSSFilterStream.h: Added.
473         (WebCore):
474         (RSSFilterStream):
475         * platform/network/blackberry/rss/RSSGenerator.cpp: Added.
476         (WebCore):
477         (WebCore::RSSGenerator::RSSGenerator):
478         (WebCore::RSSGenerator::~RSSGenerator):
479         (WebCore::RSSGenerator::generateHtml):
480         * platform/network/blackberry/rss/RSSGenerator.h: Added.
481         (WebCore):
482         (RSSGenerator):
483         * platform/network/blackberry/rss/RSSParserBase.cpp: Added.
484         (WebCore):
485         (WebCore::RSSEnclosure::RSSEnclosure):
486         (WebCore::RSSEnclosure::typeInEnum):
487         (WebCore::RSSEnclosure::suggestedName):
488         (WebCore::RSSFeed::RSSFeed):
489         (WebCore::RSSFeed::~RSSFeed):
490         (WebCore::RSSFeed::clear):
491         (WebCore::RSSItem::RSSItem):
492         (WebCore::RSSItem::~RSSItem):
493         (WebCore::RSSItem::clear):
494         (WebCore::RSSParserBase::RSSParserBase):
495         (WebCore::RSSParserBase::~RSSParserBase):
496         (WebCore::textFromXMLAttr):
497         (WebCore::textFromXMLNode):
498         * platform/network/blackberry/rss/RSSParserBase.h: Added.
499         (WebCore):
500         (RSSEnclosure):
501         (RSSItemBase):
502         (RSSParserBase):
503
504 2012-08-21  Andrew Lo  <anlo@rim.com>
505
506         [BlackBerry] requestAnimationFrame: Unscheduled display link frames need to be sent to main thread
507         https://bugs.webkit.org/show_bug.cgi?id=94600
508
509         Reviewed by Rob Buis.
510
511         http://trac.webkit.org/changeset/116792 implements destroying
512         DisplayRefreshMonitor after the number of unscheduled frames exceeds 10.
513
514         Part of that change involves dispatching to the main thread whether
515         the frame was scheduled or not.
516
517         Make the corresponding change for the BlackBerry port that was made for
518         DisplayRefreshMonitorMac.cpp.
519
520         Tests covered by http://trac.webkit.org/changeset/116792
521
522         * platform/graphics/blackberry/DisplayRefreshMonitorBlackBerry.cpp:
523         (WebCore::DisplayRefreshMonitor::displayLinkFired):
524
525 2012-08-21  Brian Salomon  <bsalomon@google.com>
526
527         [Chromium/Skia] Filters should flush the SkCanvas
528         https://bugs.webkit.org/show_bug.cgi?id=94602
529
530         Reviewed by Stephen White.
531
532         Adds a SkCanvas::flush call to FilterBufferState::swap() to ensure the textures are updated before they are consumed by the compositor.
533
534         Covered by existing css3/filters layout tests.
535
536         * platform/graphics/chromium/cc/CCRenderSurfaceFilters.cpp:
537
538 2012-08-21  Lianghui Chen  <liachen@rim.com>
539
540         [BlackBerry] Use new method to create socket handle
541         https://bugs.webkit.org/show_bug.cgi?id=89991
542
543         Reviewed by Rob Buis.
544
545         Update the way to create SocketStream as the platform API has changed.
546
547         No new tests as no change of behaviour, just API change adaptation.
548
549         * platform/network/blackberry/SocketStreamHandleBlackBerry.cpp:
550         (WebCore::SocketStreamHandle::SocketStreamHandle):
551
552 2012-08-21  Kentaro Hara  <haraken@chromium.org>
553
554         [V8] Move compileScript() from V8Proxy to ScriptSourceCode
555         https://bugs.webkit.org/show_bug.cgi?id=94561
556
557         Reviewed by Adam Barth.
558
559         To kill V8Proxy, this patch moves compileScript() from V8Proxy
560         to ScriptSourceCode. This patch also removes fromWebCoreString().
561
562         No tests. No change in behavior.
563
564         * UseV8.cmake:
565         * WebCore.gypi:
566         * bindings/v8/ScriptController.h:
567         (ScriptController):
568         * bindings/v8/ScriptSourceCode.cpp: Added.
569         (WebCore):
570         (WebCore::ScriptSourceCode::compileScript):
571         * bindings/v8/ScriptSourceCode.h:
572         (ScriptSourceCode):
573         * bindings/v8/V8Binding.h:
574         * bindings/v8/V8LazyEventListener.cpp:
575         (WebCore::V8LazyEventListener::prepareListenerObject):
576         * bindings/v8/V8Proxy.cpp:
577         (WebCore::V8Proxy::evaluate):
578         * bindings/v8/V8Proxy.h:
579         (V8Proxy):
580         * bindings/v8/WorkerContextExecutionProxy.cpp:
581         (WebCore::WorkerContextExecutionProxy::evaluate):
582         (WebCore::WorkerContextExecutionProxy::runScript):
583         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
584         (WebCore::V8InjectedScriptHost::getEventListenersCallback):
585         * bindings/v8/custom/V8MessageEventCustom.cpp:
586         (WebCore::V8MessageEvent::dataAccessorGetter):
587         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
588         (WebCore::toV8Object):
589         (WebCore::V8WebGLRenderingContext::getSupportedExtensionsCallback):
590
591 2012-08-21  Kentaro Hara  <haraken@chromium.org>
592
593         [V8] Move toV8Context() from V8Proxy to V8Binding
594         https://bugs.webkit.org/show_bug.cgi?id=94597
595
596         Reviewed by Adam Barth.
597
598         To kill V8Proxy, we can move toV8Context() from V8Proxy to V8Binding.
599
600         No tests. No change in behavior.
601
602         * bindings/v8/V8Binding.cpp:
603         (WebCore::toV8Context):
604         (WebCore):
605         * bindings/v8/V8Binding.h:
606         (WebCore):
607         * bindings/v8/V8Proxy.cpp:
608         * bindings/v8/V8Proxy.h:
609
610 2012-08-21  Gabriel Peal  <gpeal@google.com>
611
612         Web Inspector: Embeddable Web Inspector
613         https://bugs.webkit.org/show_bug.cgi?id=91528
614
615         Reviewed by Pavel Feldman.
616
617         Adds functionality to the inspector such that it is better suited to run embedded in another webpage. It adds the ability to prepopulate the timeline panel with an existing recording among other controls.
618
619         * English.lproj/localizedStrings.js:
620         * inspector/front-end/InspectorFrontendAPI.js:
621         (InspectorFrontendAPI.dispatchQueryParameters):
622         (InspectorFrontendAPI.loadTimelineFromURL):
623         * inspector/front-end/InspectorFrontendHostStub.js:
624         (.WebInspector.InspectorFrontendHostStub.prototype.hiddenPanels):
625         (.WebInspector.InspectorFrontendHostStub.prototype.loadResourceSynchronously):
626         * inspector/front-end/InspectorView.js:
627         * inspector/front-end/TimelineModel.js:
628         (WebInspector.TimelineModel.prototype.loadFromURL.onDataReceived):
629         (WebInspector.TimelineModel.prototype.loadFromURL.parseAndImportData):
630         (WebInspector.TimelineModel.prototype.loadFromURL.onLoad):
631         (WebInspector.TimelineModel.prototype.loadFromURL):
632         * inspector/front-end/TimelinePanel.js:
633         (WebInspector.TimelinePanel.prototype.loadFromURL):
634         * inspector/front-end/inspector.js:
635         (WebInspector._createPanels):
636         (WebInspector.loaded):
637         * inspector/front-end/utilities.js:
638
639 2012-08-21  Robin Cao  <robin.cao@torchmobile.com.cn>
640
641         [BlackBerry] Add support for getUserMedia
642         https://bugs.webkit.org/show_bug.cgi?id=94591
643
644         Reviewed by George Staikos.
645
646         Implement getUserMedia feature using the platform API.
647
648         Tests in fast/mediastream cover this.
649
650         PR #153571
651
652         Reviewed internally by George Staikos.
653
654         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
655         (WebCore::toWebMediaStreamSource):
656         (WebCore):
657         (WebCore::toWebMediaStreamDescriptor):
658         (WebCore::MediaPlayerPrivate::lookupMediaStream):
659         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.h:
660         (MediaPlayerPrivate):
661
662 2012-08-21  Pavel Feldman  <pfeldman@chromium.org>
663
664         Web Inspector: remove DOMNodeRemoved listener from the DefaultTextEditor
665         https://bugs.webkit.org/show_bug.cgi?id=94592
666
667         Reviewed by Yury Semikhatsky.
668
669         It seems to be not necessary.
670
671         * inspector/front-end/DefaultTextEditor.js:
672         (WebInspector.TextEditorMainPanel):
673         (WebInspector.TextEditorMainPanel.prototype._handleDOMUpdates):
674         (WebInspector.TextEditorMainChunk):
675         (WebInspector.TextEditorMainChunk.prototype.set expanded):
676
677 2012-08-21  Thiago Marcos P. Santos  <thiago.santos@intel.com>
678
679         CodeGeneratorInspector.py: Generate guards for type validators
680         https://bugs.webkit.org/show_bug.cgi?id=94511
681
682         Reviewed by Yury Semikhatsky.
683
684         Fix regression when building debug and one of the generated types is
685         disabled by a compile flag. We should generate guards for these type
686         validators the same way as we are doing on the include headers.
687
688         * inspector/CodeGeneratorInspector.py:
689         (TypeBindings.create_type_declaration_.EnumBinding.get_code_generator.CodeGenerator.generate_type_builder):
690
691 2012-08-21  Florin Malita  <fmalita@chromium.org>
692
693         ASSERT triggered in SVGTRefTargetEventListener::handleEvent()
694         https://bugs.webkit.org/show_bug.cgi?id=94487
695
696         Reviewed by Nikolas Zimmermann.
697
698         The current way of tracking tref target elements by id can leave stale event listeners
699         under certain circumstances. This patch switches to storing a target RefPtr instead
700         to avoid an id lookup which may not return the original/attached element.
701
702         Test: svg/custom/tref-stale-listener-crash.html
703
704         * svg/SVGTRefElement.cpp:
705         (SVGTRefTargetEventListener):
706         (WebCore::SVGTRefTargetEventListener::isAttached): use m_target instead of an explicit bool.
707         (WebCore::SVGTRefTargetEventListener::SVGTRefTargetEventListener):
708         (WebCore::SVGTRefTargetEventListener::attach): save a target RefPtr instead of an id.
709         (WebCore::SVGTRefTargetEventListener::detach): detach the target element directly without
710         going through a lookup.
711         (WebCore::SVGTRefTargetEventListener::handleEvent):
712         (WebCore::SVGTRefElement::updateReferencedText): use an explicit target pointer instead of
713         the id-based lookup.
714         (WebCore::SVGTRefElement::buildPendingResource):
715         * svg/SVGTRefElement.h:
716         (SVGTRefElement):
717
718 2012-08-21  Alexandre Elias  <aelias@google.com>
719
720         [chromium] Add software bitmap resources to CCResourceProvider
721         https://bugs.webkit.org/show_bug.cgi?id=93677
722
723         Reviewed by Adrienne Walker.
724
725         This adds the ability to CCResourceProvider to use software bitmaps.
726         They are allocated as plain-old-memory, and exposed as Skia objects.
727
728         We want the ResourceProvider to be able to handle different resource
729         types at the same time.  In practice, a default resource type is
730         desired for most uses within a single compositor instance, which is
731         specified by the default resource type.  Default resource types are
732         expected to be mostly 1-to-1 with CCRenderer types.
733
734         New tests added by parametrizing existing CCResourceProvider tests.
735
736         * platform/graphics/chromium/FrameBufferSkPictureCanvasLayerTextureUpdater.cpp:
737         (WebCore::FrameBufferSkPictureCanvasLayerTextureUpdater::updateTextureRect):
738         * platform/graphics/chromium/LayerRendererChromium.cpp:
739         (WebCore::applyFilters):
740         (WebCore::LayerRendererChromium::drawRenderPassQuad):
741         (WebCore::LayerRendererChromium::drawTileQuad):
742         (WebCore::LayerRendererChromium::drawYUVVideoQuad):
743         (WebCore::LayerRendererChromium::drawTextureQuad):
744         (WebCore::LayerRendererChromium::getFramebufferTexture):
745         (WebCore::LayerRendererChromium::bindFramebufferToTexture):
746         * platform/graphics/chromium/LayerRendererChromium.h:
747         (DrawingFrame):
748         * platform/graphics/chromium/cc/CCResourceProvider.cpp:
749         (WebCore::CCResourceProvider::createResource):
750         (WebCore):
751         (WebCore::CCResourceProvider::createGLTexture):
752         (WebCore::CCResourceProvider::createBitmap):
753         (WebCore::CCResourceProvider::createResourceFromExternalTexture):
754         (WebCore::CCResourceProvider::deleteResource):
755         (WebCore::CCResourceProvider::upload):
756         (WebCore::CCResourceProvider::flush):
757         (WebCore::CCResourceProvider::shallowFlushIfSupported):
758         (WebCore::CCResourceProvider::lockForRead):
759         (WebCore::CCResourceProvider::unlockForRead):
760         (WebCore::CCResourceProvider::lockForWrite):
761         (WebCore::CCResourceProvider::unlockForWrite):
762         (WebCore::CCResourceProvider::ScopedReadLockGL::ScopedReadLockGL):
763         (WebCore::CCResourceProvider::ScopedReadLockGL::~ScopedReadLockGL):
764         (WebCore::CCResourceProvider::ScopedWriteLockGL::ScopedWriteLockGL):
765         (WebCore::CCResourceProvider::ScopedWriteLockGL::~ScopedWriteLockGL):
766         (WebCore::CCResourceProvider::populateSkBitmapWithResource):
767         (WebCore::CCResourceProvider::ScopedReadLockSoftware::ScopedReadLockSoftware):
768         (WebCore::CCResourceProvider::ScopedReadLockSoftware::~ScopedReadLockSoftware):
769         (WebCore::CCResourceProvider::ScopedWriteLockSoftware::ScopedWriteLockSoftware):
770         (WebCore::CCResourceProvider::ScopedWriteLockSoftware::~ScopedWriteLockSoftware):
771         (WebCore::CCResourceProvider::CCResourceProvider):
772         * platform/graphics/chromium/cc/CCResourceProvider.h:
773         (WebCore):
774         (WebCore::CCResourceProvider::setCreationPolicy):
775         (WebCore::CCResourceProvider::creationPolicy):
776         (CCResourceProvider):
777         (ScopedReadLockGL):
778         (WebCore::CCResourceProvider::ScopedReadLockGL::textureId):
779         (ScopedWriteLockGL):
780         (WebCore::CCResourceProvider::ScopedWriteLockGL::textureId):
781         (ScopedReadLockSoftware):
782         (WebCore::CCResourceProvider::ScopedReadLockSoftware::skBitmap):
783         (ScopedWriteLockSoftware):
784         (WebCore::CCResourceProvider::ScopedWriteLockSoftware::skCanvas):
785         (Resource):
786
787 2012-08-21  Tab Atkins  <tabatkins@google.com>
788
789         Track -webkit property usage.
790         https://bugs.webkit.org/show_bug.cgi?id=93420
791
792         Reviewed by Ojan Vafai.
793
794         First draft of an attempt to track all usage of -webkit prefixed properties across the web.
795         This attempt is dumb, but should provide useful data as a first-pass.
796         I plan to optimize this for better data collection in the future.
797
798         No tests added, as this is untestable currently.
799         It should have zero effect besides histogramming.
800
801         * css/CSSParser.cpp:
802         (WebCore::cssPropertyID):
803
804 2012-08-21  Alec Flett  <alecflett@chromium.org>
805
806         IndexedDB: remove old update/openCursor glue
807         https://bugs.webkit.org/show_bug.cgi?id=94378
808
809         Reviewed by Tony Chang.
810
811         Remove old openCursor and update methods after landing
812         https://bugs.webkit.org/show_bug.cgi?id=91125 and removing
813         Chromium-side glue.
814
815         No new tests: this code is dead.
816
817         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
818         * Modules/indexeddb/IDBObjectStoreBackendImpl.h:
819         (IDBObjectStoreBackendImpl):
820         * Modules/indexeddb/IDBObjectStoreBackendInterface.h:
821         * inspector/InspectorIndexedDBAgent.cpp:
822         (WebCore):
823
824 2012-08-21  James Robinson  <jamesr@chromium.org>
825
826         [chromium] Should be able to destroy a CCLayerTreeHost without manually setting the root layer
827         https://bugs.webkit.org/show_bug.cgi?id=94631
828
829         Reviewed by Adrienne Walker.
830
831         In the depths of time when dinosaurs roamed the earth, LayerChromium and CCLayerTreeHost were both reference
832         counted and there was a cycle between the root LayerChromium and CCLayerTreeHost. This required all users of
833         CCLayerTreeHost to manually break the cycle by calling setRootLayer(0) before dropping their reference to the
834         host. Nowadays, CCLayerTreeHost has a single owner and LayerChromiums only have a weak pointer to their host
835         so we should just do this cleanup ourselves instead of imposing it on callers.
836
837         Unit test added to LayerChromiumTest.cpp
838
839         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
840         (WebCore::CCLayerTreeHost::~CCLayerTreeHost):
841
842 2012-08-21  Ulan Degenbaev  <ulan@chromium.org>
843
844         Call AdjustAmountOfExternalAllocatedMemory when V8ArrayBuffer constructed and destructed
845         https://bugs.webkit.org/show_bug.cgi?id=92993
846
847         Reviewed by Kenneth Russell.
848
849         Call AdjustAmountOfExternalAllocatedMemory when V8ArrayBuffer
850         is constructed and destructed so that V8's garbage collection
851         heuristics can account for the memory held by these objects.
852
853         * WebCore.gypi:
854         * bindings/v8/SerializedScriptValue.cpp:
855         * bindings/v8/custom/V8ArrayBufferCustom.cpp:
856         (WebCore::V8ArrayBufferDeallocationObserver::instance):
857         (WebCore):
858         (WebCore::V8ArrayBuffer::constructorCallback):
859         * bindings/v8/custom/V8ArrayBufferCustom.h: Added.
860         (WebCore):
861         * bindings/v8/custom/V8ArrayBufferViewCustom.cpp:
862         * bindings/v8/custom/V8ArrayBufferViewCustom.h:
863         (WebCore::constructWebGLArray):
864         * dom/MessageEvent.cpp:
865         (WebCore::MessageEvent::MessageEvent):
866         (WebCore::MessageEvent::initMessageEvent):
867
868 2012-08-21  Taiju Tsuiki  <tzik@chromium.org>
869
870         Web Inspector: Completion events of InspectorFileSystemAgent should be fired asynchronously.
871         https://bugs.webkit.org/show_bug.cgi?id=93933
872
873         Reviewed by Yury Semikhatsky.
874
875         InspectorFileSystemAgent fires completion event too early in error case. It should wait
876         until JS code is ready.
877
878         Test: http/tests/inspector/filesystem/request-directory-content.html
879               http/tests/inspector/filesystem/request-file-content.html
880               http/tests/inspector/filesystem/request-metadata.html
881
882         * inspector/InspectorFileSystemAgent.cpp:
883         (WebCore): Add ReportErrorTask class
884
885 2012-08-21  Mike West  <mkwst@chromium.org>
886
887         Blocking a resource via Content Security Policy should trigger an Error event.
888         https://bugs.webkit.org/show_bug.cgi?id=89440
889
890         Reviewed by Jochen Eisinger.
891
892         If a CSP directive is violated, CachedResourceLoader will trigger a
893         console error, and return a null image. In that case, we now dispatch
894         an error on the relevant element.
895
896         Adjusted http/tests/security/contentSecurityPolicy/image-blocked.html
897         and http/tests/security/contentSecurityPolicy/register-bypassing-scheme.html
898         to test the new behavior.
899
900         This has the side-effect of also generating errors for images blocked by
901         Chromium's content settings. Adjusted
902         platform/chromium/permissionclient/image-permissions.html to agree with
903         the new behavior.
904
905         * loader/ImageLoader.cpp:
906         (WebCore::ImageLoader::updateFromElement):
907
908 2012-08-21  Taiju Tsuiki  <tzik@chromium.org>
909
910         Web Inspector: Split out crumb list part of styles from elementsPanel.css
911         https://bugs.webkit.org/show_bug.cgi?id=94301
912
913         Reviewed by Pavel Feldman.
914
915         As a preparation to use BreadcrumbList on FileSystem, introduce breadcrumbList.css and
916         move crumb-related style entries into it from elementsPanel.css.
917
918         No new tests. This change does not make functional change.
919
920         * WebCore.gypi:
921         * WebCore.vcproj/WebCore.vcproj:
922         * inspector/front-end/ElementsPanel.js:
923         * inspector/front-end/WebKit.qrc:
924         * inspector/front-end/breadcrumbList.css: Added.
925         (.crumbs):
926         (.crumbs .crumb):
927         (.crumbs .crumb.collapsed > *):
928         (.crumbs .crumb.collapsed::before):
929         (.crumbs .crumb.compact .extra):
930         (.crumbs .crumb.dimmed):
931         (.crumbs .crumb.start):
932         (.crumbs .crumb.end):
933         (.crumbs .crumb.selected):
934         (.crumbs .crumb.selected:hover):
935         (.crumbs .crumb.selected.end, .crumbs .crumb.selected.end:hover):
936         (.crumbs .crumb:hover):
937         (.crumbs .crumb.dimmed:hover):
938         (.crumbs .crumb.end:hover):
939         * inspector/front-end/elementsPanel.css:
940
941 2012-08-21  Sudarsana Nagineni  <sudarsana.nagineni@linux.intel.com>
942
943         canvas/philip/tests/2d.fillStyle.parse.invalid.rgba-6.html fails
944         https://bugs.webkit.org/show_bug.cgi?id=50797
945
946         Reviewed by Andreas Kling.
947
948         Add a check in fast-path parseAlphaValue() to return early
949         if the CSS <alphavalue> ended with an invalid digit.
950
951         Test: canvas/philip/tests/2d.fillStyle.parse.invalid.rgba-6.html
952
953         * css/CSSParser.cpp:
954         (WebCore::parseAlphaValue):
955
956 2012-08-21  Benjamin Poulain  <bpoulain@apple.com>
957
958         Store CString data in the CStringBuffer to avoid the double indirection
959         https://bugs.webkit.org/show_bug.cgi?id=94562
960
961         Reviewed by Darin Adler.
962
963         * bindings/cpp/WebDOMCString.cpp:
964         (WebDOMCString::length): With the patch, CStringBuffer hold the real string length instead of the
965         size of the buffer including the terminating zero. WebDOMCString is updated accordingly.
966
967 2012-08-21  Benjamin Poulain  <bpoulain@apple.com>
968
969         Create CSS color output string on 8 bits
970         https://bugs.webkit.org/show_bug.cgi?id=94625
971
972         Reviewed by Andreas Kling.
973
974         * css/CSSPrimitiveValue.cpp:
975         (WebCore::CSSPrimitiveValue::customCssText):
976         Previously, the output string for a CSS color was computed on 16 bits.
977         This was mainly forced by the use of String::number().
978
979         Since the double to string conversion is done on 8bits anyway, I changed
980         the code to use dtoa's numberToFixedPrecisionString directly instead of
981         String::number().
982         All the other parts were already on 8bits.
983
984 2012-08-21  Martin Robinson  <mrobinson@igalia.com>
985
986         [GTK] Using a native window for the WebView breaks GtkOverlay
987         https://bugs.webkit.org/show_bug.cgi?id=90085
988
989         Reviewed by Alejandro G. Castro.
990
991         No new tests. This will be covered by pixel test for accelerated
992         compositing when they are activated.
993
994         * GNUmakefile.am: Add XComposite libraries to the linker list.
995         * GNUmakefile.list.am: Add RedirectedXCompositeWindow files to the source list.
996         Make a new section for GLX specific files.
997         * platform/graphics/glx/GLContextGLX.cpp:
998         (WebCore::GLContextGLX::sharedDisplay): Expose sharedDisplay as a static method
999         so that it can be called by other X11 specific code.
1000         * platform/graphics/glx/GLContextGLX.h: Ditto.
1001         * platform/gtk/RedirectedXCompositeWindow.cpp: Added. An implementation of a GL surface
1002         that renders to an X-window which redirects to a pixmap.
1003         * platform/gtk/RedirectedXCompositeWindow.h: Added.
1004
1005 2012-08-21  David Hyatt  <hyatt@apple.com>
1006
1007         [New Multicolumn] Make column rules paint properly.
1008         https://bugs.webkit.org/show_bug.cgi?id=94616
1009
1010         Reviewed by Simon Fraser.
1011
1012         Make the new multi-column code paint column rules and also prepare it for painting
1013         the actual column contents.
1014
1015         * rendering/RenderMultiColumnBlock.cpp:
1016         (WebCore::RenderMultiColumnBlock::ensureColumnSets):
1017         Remove the addRegionToThread call, since this is now done automatically in RenderRegion::insertedIntoTree.
1018         
1019         * rendering/RenderMultiColumnBlock.h:
1020         (WebCore::RenderMultiColumnBlock::flowThread):
1021         Make public so that RenderMultiColumnSet can access it.
1022         
1023         (RenderMultiColumnBlock):
1024         * rendering/RenderMultiColumnSet.cpp:
1025         (WebCore::RenderMultiColumnSet::columnGap):
1026         Add a column gap fetch method. It's identical to the one on RenderBlock (which will eventually go away
1027         when we kill the old multi-column code).
1028         
1029         (WebCore::RenderMultiColumnSet::columnRectAt):
1030         Also identical to the RenderBlock version of this method. Gets the rect for the nth column.
1031         
1032         (WebCore::RenderMultiColumnSet::paintReplaced):
1033         Subclass paintReplaced in order to do column rules and contents painting.
1034         
1035         (WebCore::RenderMultiColumnSet::paintColumnRules):
1036         (WebCore::RenderMultiColumnSet::paintColumnContents):
1037         Similar to the methods on RenderBlock. The former paints the rules and the latter paints the contents of
1038         the flow thread into the columns.
1039         
1040         * rendering/RenderMultiColumnSet.h:
1041         (RenderMultiColumnSet):
1042         Add the declarations of all the new methods.
1043         
1044         * rendering/RenderRegion.cpp:
1045         (WebCore::RenderRegion::installFlowThread):
1046         Added a new virtual function for installing flow threads when they didn't exist at construction time.
1047         This only applies to actual CSS Regions, so the subclass of the method in RenderRegionSet just does
1048         nothing.
1049         
1050         (WebCore::RenderRegion::attachRegion):
1051         Get the named flow thread code out of attachRegion, since it broke multi-column. Moved it into a
1052         virtual function, installFlowThread, that is only used by actual CSS regions. Eventually we may
1053         want a RenderRegion subclass that represents a region for a named flow thread only, but for now
1054         let the code sit in installFlowThread in the base class.
1055         
1056         * rendering/RenderRegion.h:
1057         (RenderRegion):
1058         Add installFlowThread declaration.
1059         
1060         * rendering/RenderRegionSet.cpp:
1061         (WebCore::RenderRegionSet::installFlowThread):
1062         installFlowThread for region sets just does nothing, since we don't use named flow threads.
1063         
1064         * rendering/RenderRegionSet.h:
1065         (RenderRegionSet):
1066         Add the override of installFlowThread.
1067
1068 2012-08-21  Patrick Gansterer  <paroga@webkit.org>
1069
1070         [WIN] Build fix for !ENABLE(DRAG_SUPPORT).
1071
1072         * page/win/EventHandlerWin.cpp:
1073         (WebCore):
1074         (WebCore::EventHandler::passMouseMoveEventToSubframe):
1075
1076 2012-08-21  James Robinson  <jamesr@chromium.org>
1077
1078         Unreviewed, rolling out r126170.
1079         http://trac.webkit.org/changeset/126170
1080         https://bugs.webkit.org/show_bug.cgi?id=94614
1081
1082         I spoke too soon
1083
1084         * page/scrolling/chromium/ScrollingCoordinatorChromium.cpp:
1085         (WebCore::ScrollingCoordinatorPrivate::ScrollingCoordinatorPrivate):
1086         (WebCore::ScrollingCoordinatorPrivate::setScrollLayer):
1087         (WebCore::ScrollingCoordinatorPrivate::setHorizontalScrollbarLayer):
1088         (WebCore::ScrollingCoordinatorPrivate::setVerticalScrollbarLayer):
1089         (WebCore::ScrollingCoordinatorPrivate::hasScrollLayer):
1090         (WebCore::ScrollingCoordinatorPrivate::scrollLayer):
1091         (ScrollingCoordinatorPrivate):
1092         (WebCore::createScrollbarLayer):
1093         (WebCore::ScrollingCoordinator::frameViewHorizontalScrollbarLayerDidChange):
1094         (WebCore::ScrollingCoordinator::frameViewVerticalScrollbarLayerDidChange):
1095         (WebCore::ScrollingCoordinator::setScrollLayer):
1096         (WebCore::ScrollingCoordinator::setNonFastScrollableRegion):
1097         (WebCore::ScrollingCoordinator::setWheelEventHandlerCount):
1098         (WebCore::ScrollingCoordinator::setShouldUpdateScrollLayerPositionOnMainThread):
1099         (WebCore::ScrollingCoordinator::setLayerIsContainerForFixedPositionLayers):
1100         (WebCore::ScrollingCoordinator::setLayerIsFixedToContainerLayer):
1101         * platform/graphics/chromium/Canvas2DLayerBridge.cpp:
1102         (WebCore::Canvas2DLayerBridge::Canvas2DLayerBridge):
1103         (WebCore::Canvas2DLayerBridge::~Canvas2DLayerBridge):
1104         (WebCore::Canvas2DLayerBridge::prepareForDraw):
1105         (WebCore::Canvas2DLayerBridge::layer):
1106         (WebCore::Canvas2DLayerBridge::contextAcquired):
1107         * platform/graphics/chromium/Canvas2DLayerBridge.h:
1108         (Canvas2DLayerBridge):
1109         * platform/graphics/chromium/DrawingBufferChromium.cpp:
1110         (WebCore::DrawingBufferPrivate::DrawingBufferPrivate):
1111         (WebCore::DrawingBufferPrivate::~DrawingBufferPrivate):
1112         (WebCore::DrawingBufferPrivate::layer):
1113         (DrawingBufferPrivate):
1114         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
1115         (WebCore::GraphicsLayerChromium::GraphicsLayerChromium):
1116         (WebCore::GraphicsLayerChromium::~GraphicsLayerChromium):
1117         (WebCore::GraphicsLayerChromium::willBeDestroyed):
1118         (WebCore):
1119         (WebCore::GraphicsLayerChromium::updateNames):
1120         (WebCore::GraphicsLayerChromium::removeFromParent):
1121         (WebCore::GraphicsLayerChromium::setSize):
1122         (WebCore::GraphicsLayerChromium::clearBackgroundColor):
1123         (WebCore::GraphicsLayerChromium::setContentsOpaque):
1124         (WebCore::GraphicsLayerChromium::setFilters):
1125         (WebCore::GraphicsLayerChromium::setBackgroundFilters):
1126         (WebCore::GraphicsLayerChromium::setMaskLayer):
1127         (WebCore::GraphicsLayerChromium::setBackfaceVisibility):
1128         (WebCore::GraphicsLayerChromium::setOpacity):
1129         (WebCore::GraphicsLayerChromium::setReplicatedByLayer):
1130         (WebCore::GraphicsLayerChromium::setContentsNeedsDisplay):
1131         (WebCore::GraphicsLayerChromium::setNeedsDisplay):
1132         (WebCore::GraphicsLayerChromium::setNeedsDisplayInRect):
1133         (WebCore::GraphicsLayerChromium::setContentsToImage):
1134         (WebCore::GraphicsLayerChromium::setContentsToCanvas):
1135         (WebCore::GraphicsLayerChromium::addAnimation):
1136         (WebCore::GraphicsLayerChromium::pauseAnimation):
1137         (WebCore::GraphicsLayerChromium::removeAnimation):
1138         (WebCore::GraphicsLayerChromium::suspendAnimations):
1139         (WebCore::GraphicsLayerChromium::resumeAnimations):
1140         (WebCore::GraphicsLayerChromium::addLinkHighlight):
1141         (WebCore::GraphicsLayerChromium::didFinishLinkHighlight):
1142         (WebCore::GraphicsLayerChromium::setContentsToMedia):
1143         (WebCore::GraphicsLayerChromium::primaryLayer):
1144         (WebCore::GraphicsLayerChromium::platformLayer):
1145         (WebCore::GraphicsLayerChromium::setDebugBackgroundColor):
1146         (WebCore::GraphicsLayerChromium::setDebugBorder):
1147         (WebCore::GraphicsLayerChromium::updateChildList):
1148         (WebCore::GraphicsLayerChromium::updateLayerPosition):
1149         (WebCore::GraphicsLayerChromium::updateLayerSize):
1150         (WebCore::GraphicsLayerChromium::updateAnchorPoint):
1151         (WebCore::GraphicsLayerChromium::updateTransform):
1152         (WebCore::GraphicsLayerChromium::updateChildrenTransform):
1153         (WebCore::GraphicsLayerChromium::updateMasksToBounds):
1154         (WebCore::GraphicsLayerChromium::updateLayerPreserves3D):
1155         (WebCore::GraphicsLayerChromium::updateLayerIsDrawable):
1156         (WebCore::GraphicsLayerChromium::updateLayerBackgroundColor):
1157         (WebCore::GraphicsLayerChromium::updateContentsRect):
1158         (WebCore::GraphicsLayerChromium::updateContentsScale):
1159         (WebCore::GraphicsLayerChromium::setupContentsLayer):
1160         * platform/graphics/chromium/GraphicsLayerChromium.h:
1161         (WebCore::GraphicsLayerChromium::hasContentsLayer):
1162         (GraphicsLayerChromium):
1163         (WebCore::GraphicsLayerChromium::contentsLayer):
1164         * platform/graphics/chromium/LayerChromium.cpp:
1165         (WebCore::LayerChromium::rootLayer):
1166         * platform/graphics/chromium/LayerChromium.h:
1167
1168 2012-08-21  Adam Barth  <abarth@webkit.org>
1169
1170         Update run-bindings-tests results after http://trac.webkit.org/changeset/126165
1171
1172         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
1173         (WebCore::jsTestActiveDOMObjectExcitingAttr):
1174         (WebCore::jsTestActiveDOMObjectConstructor):
1175         (WebCore::jsTestActiveDOMObjectPrototypeFunctionExcitingFunction):
1176
1177 2012-08-21  Vincent Scheib  <scheib@chromium.org>
1178
1179         Add parsing logic for allow-pointer-lock to iframe sandbox attribute.
1180         https://bugs.webkit.org/show_bug.cgi?id=94513
1181
1182         Reviewed by Adam Barth.
1183
1184         Pointer lock was previously blocked from all sandboxed iframes.
1185         Parsing the sandbox="allow-pointer-lock" attribute allows pages
1186         to control the feature and enable it in sandboxed iframes.
1187
1188         Tests: http/tests/pointer-lock/iframe-sandboxed-allow-pointer-lock.html
1189                http/tests/pointer-lock/iframe-sandboxed-nested-allow-pointer-lock.html
1190                http/tests/pointer-lock/iframe-sandboxed-nested-disallow-then-allow-pointer-lock.html
1191
1192         * dom/SecurityContext.cpp:
1193         (WebCore::SecurityContext::parseSandboxPolicy):
1194
1195 2012-08-21  James Robinson  <jamesr@chromium.org>
1196
1197         Unreviewed, rolling out r126169.
1198         http://trac.webkit.org/changeset/126169
1199         https://bugs.webkit.org/show_bug.cgi?id=94614
1200
1201         Crashes already fixed downstream
1202
1203         * page/scrolling/chromium/ScrollingCoordinatorChromium.cpp:
1204         (WebCore::ScrollingCoordinatorPrivate::ScrollingCoordinatorPrivate):
1205         (ScrollingCoordinatorPrivate):
1206         (WebCore::ScrollingCoordinatorPrivate::setScrollLayer):
1207         (WebCore::ScrollingCoordinatorPrivate::setHorizontalScrollbarLayer):
1208         (WebCore::ScrollingCoordinatorPrivate::setVerticalScrollbarLayer):
1209         (WebCore::ScrollingCoordinatorPrivate::scrollLayer):
1210         (WebCore::scrollableLayerForGraphicsLayer):
1211         (WebCore):
1212         (WebCore::createScrollbarLayer):
1213         (WebCore::ScrollingCoordinator::frameViewHorizontalScrollbarLayerDidChange):
1214         (WebCore::ScrollingCoordinator::frameViewVerticalScrollbarLayerDidChange):
1215         (WebCore::ScrollingCoordinator::setScrollLayer):
1216         (WebCore::ScrollingCoordinator::setNonFastScrollableRegion):
1217         (WebCore::ScrollingCoordinator::setWheelEventHandlerCount):
1218         (WebCore::ScrollingCoordinator::setShouldUpdateScrollLayerPositionOnMainThread):
1219         (WebCore::ScrollingCoordinator::setLayerIsContainerForFixedPositionLayers):
1220         (WebCore::ScrollingCoordinator::setLayerIsFixedToContainerLayer):
1221         * platform/graphics/chromium/Canvas2DLayerBridge.cpp:
1222         (WebCore::Canvas2DLayerBridge::Canvas2DLayerBridge):
1223         (WebCore::Canvas2DLayerBridge::~Canvas2DLayerBridge):
1224         (WebCore::Canvas2DLayerBridge::prepareForDraw):
1225         (WebCore::Canvas2DLayerBridge::layer):
1226         (WebCore::Canvas2DLayerBridge::contextAcquired):
1227         * platform/graphics/chromium/Canvas2DLayerBridge.h:
1228         (Canvas2DLayerBridge):
1229         * platform/graphics/chromium/DrawingBufferChromium.cpp:
1230         (WebCore::DrawingBufferPrivate::DrawingBufferPrivate):
1231         (WebCore::DrawingBufferPrivate::~DrawingBufferPrivate):
1232         (WebCore::DrawingBufferPrivate::layer):
1233         (DrawingBufferPrivate):
1234         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
1235         (WebCore::GraphicsLayerChromium::GraphicsLayerChromium):
1236         (WebCore::GraphicsLayerChromium::~GraphicsLayerChromium):
1237         (WebCore::GraphicsLayerChromium::updateNames):
1238         (WebCore::GraphicsLayerChromium::removeFromParent):
1239         (WebCore::GraphicsLayerChromium::setSize):
1240         (WebCore::GraphicsLayerChromium::clearBackgroundColor):
1241         (WebCore::GraphicsLayerChromium::setContentsOpaque):
1242         (WebCore::GraphicsLayerChromium::setFilters):
1243         (WebCore::GraphicsLayerChromium::setBackgroundFilters):
1244         (WebCore::GraphicsLayerChromium::setMaskLayer):
1245         (WebCore::GraphicsLayerChromium::setBackfaceVisibility):
1246         (WebCore::GraphicsLayerChromium::setOpacity):
1247         (WebCore::GraphicsLayerChromium::setReplicatedByLayer):
1248         (WebCore::GraphicsLayerChromium::setContentsNeedsDisplay):
1249         (WebCore::GraphicsLayerChromium::setNeedsDisplay):
1250         (WebCore::GraphicsLayerChromium::setNeedsDisplayInRect):
1251         (WebCore::GraphicsLayerChromium::setContentsToImage):
1252         (WebCore::GraphicsLayerChromium::setContentsToCanvas):
1253         (WebCore):
1254         (WebCore::GraphicsLayerChromium::setContentsToMedia):
1255         (WebCore::GraphicsLayerChromium::setContentsTo):
1256         (WebCore::GraphicsLayerChromium::addAnimation):
1257         (WebCore::GraphicsLayerChromium::pauseAnimation):
1258         (WebCore::GraphicsLayerChromium::removeAnimation):
1259         (WebCore::GraphicsLayerChromium::suspendAnimations):
1260         (WebCore::GraphicsLayerChromium::resumeAnimations):
1261         (WebCore::GraphicsLayerChromium::addLinkHighlight):
1262         (WebCore::GraphicsLayerChromium::didFinishLinkHighlight):
1263         (WebCore::GraphicsLayerChromium::platformLayer):
1264         (WebCore::GraphicsLayerChromium::setDebugBackgroundColor):
1265         (WebCore::GraphicsLayerChromium::setDebugBorder):
1266         (WebCore::GraphicsLayerChromium::updateChildList):
1267         (WebCore::GraphicsLayerChromium::updateLayerPosition):
1268         (WebCore::GraphicsLayerChromium::updateLayerSize):
1269         (WebCore::GraphicsLayerChromium::updateAnchorPoint):
1270         (WebCore::GraphicsLayerChromium::updateTransform):
1271         (WebCore::GraphicsLayerChromium::updateChildrenTransform):
1272         (WebCore::GraphicsLayerChromium::updateMasksToBounds):
1273         (WebCore::GraphicsLayerChromium::updateLayerPreserves3D):
1274         (WebCore::GraphicsLayerChromium::updateLayerIsDrawable):
1275         (WebCore::GraphicsLayerChromium::updateLayerBackgroundColor):
1276         (WebCore::GraphicsLayerChromium::updateContentsRect):
1277         (WebCore::GraphicsLayerChromium::updateContentsScale):
1278         (WebCore::GraphicsLayerChromium::setupContentsLayer):
1279         * platform/graphics/chromium/GraphicsLayerChromium.h:
1280         (WebCore::GraphicsLayerChromium::hasContentsLayer):
1281         (WebCore::GraphicsLayerChromium::contentLayer):
1282         (GraphicsLayerChromium):
1283         (WebCore::GraphicsLayerChromium::contentsLayer):
1284         * platform/graphics/chromium/LayerChromium.cpp:
1285         (WebCore::LayerChromium::rootLayer):
1286         * platform/graphics/chromium/LayerChromium.h:
1287
1288 2012-08-21  Sheriff Bot  <webkit.review.bot@gmail.com>
1289
1290         Unreviewed, rolling out r126076, r126099, and r126106.
1291         http://trac.webkit.org/changeset/126076
1292         http://trac.webkit.org/changeset/126099
1293         http://trac.webkit.org/changeset/126106
1294         https://bugs.webkit.org/show_bug.cgi?id=94614
1295
1296         Caused crashes during compositor shutdown in Aura builds of
1297         Chromium (Requested by kbr_google on #webkit).
1298
1299         * page/scrolling/chromium/ScrollingCoordinatorChromium.cpp:
1300         (WebCore::ScrollingCoordinatorPrivate::ScrollingCoordinatorPrivate):
1301         (WebCore::ScrollingCoordinatorPrivate::setScrollLayer):
1302         (WebCore::ScrollingCoordinatorPrivate::setHorizontalScrollbarLayer):
1303         (WebCore::ScrollingCoordinatorPrivate::setVerticalScrollbarLayer):
1304         (WebCore::ScrollingCoordinatorPrivate::hasScrollLayer):
1305         (WebCore::ScrollingCoordinatorPrivate::scrollLayer):
1306         (ScrollingCoordinatorPrivate):
1307         (WebCore::createScrollbarLayer):
1308         (WebCore::ScrollingCoordinator::frameViewHorizontalScrollbarLayerDidChange):
1309         (WebCore::ScrollingCoordinator::frameViewVerticalScrollbarLayerDidChange):
1310         (WebCore::ScrollingCoordinator::setScrollLayer):
1311         (WebCore::ScrollingCoordinator::setNonFastScrollableRegion):
1312         (WebCore::ScrollingCoordinator::setWheelEventHandlerCount):
1313         (WebCore::ScrollingCoordinator::setShouldUpdateScrollLayerPositionOnMainThread):
1314         (WebCore::ScrollingCoordinator::setLayerIsContainerForFixedPositionLayers):
1315         (WebCore::ScrollingCoordinator::setLayerIsFixedToContainerLayer):
1316         * platform/graphics/chromium/Canvas2DLayerBridge.cpp:
1317         (WebCore::Canvas2DLayerBridge::Canvas2DLayerBridge):
1318         (WebCore::Canvas2DLayerBridge::~Canvas2DLayerBridge):
1319         (WebCore::Canvas2DLayerBridge::prepareForDraw):
1320         (WebCore::Canvas2DLayerBridge::layer):
1321         (WebCore::Canvas2DLayerBridge::contextAcquired):
1322         * platform/graphics/chromium/Canvas2DLayerBridge.h:
1323         (Canvas2DLayerBridge):
1324         * platform/graphics/chromium/DrawingBufferChromium.cpp:
1325         (WebCore::DrawingBufferPrivate::DrawingBufferPrivate):
1326         (WebCore::DrawingBufferPrivate::~DrawingBufferPrivate):
1327         (WebCore::DrawingBufferPrivate::layer):
1328         (DrawingBufferPrivate):
1329         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
1330         (WebCore::GraphicsLayerChromium::GraphicsLayerChromium):
1331         (WebCore::GraphicsLayerChromium::~GraphicsLayerChromium):
1332         (WebCore::GraphicsLayerChromium::willBeDestroyed):
1333         (WebCore):
1334         (WebCore::GraphicsLayerChromium::updateNames):
1335         (WebCore::GraphicsLayerChromium::removeFromParent):
1336         (WebCore::GraphicsLayerChromium::setSize):
1337         (WebCore::GraphicsLayerChromium::clearBackgroundColor):
1338         (WebCore::GraphicsLayerChromium::setContentsOpaque):
1339         (WebCore::GraphicsLayerChromium::setFilters):
1340         (WebCore::GraphicsLayerChromium::setBackgroundFilters):
1341         (WebCore::GraphicsLayerChromium::setMaskLayer):
1342         (WebCore::GraphicsLayerChromium::setBackfaceVisibility):
1343         (WebCore::GraphicsLayerChromium::setOpacity):
1344         (WebCore::GraphicsLayerChromium::setReplicatedByLayer):
1345         (WebCore::GraphicsLayerChromium::setContentsNeedsDisplay):
1346         (WebCore::GraphicsLayerChromium::setNeedsDisplay):
1347         (WebCore::GraphicsLayerChromium::setNeedsDisplayInRect):
1348         (WebCore::GraphicsLayerChromium::setContentsToImage):
1349         (WebCore::GraphicsLayerChromium::setContentsToCanvas):
1350         (WebCore::GraphicsLayerChromium::addAnimation):
1351         (WebCore::GraphicsLayerChromium::pauseAnimation):
1352         (WebCore::GraphicsLayerChromium::removeAnimation):
1353         (WebCore::GraphicsLayerChromium::suspendAnimations):
1354         (WebCore::GraphicsLayerChromium::resumeAnimations):
1355         (WebCore::GraphicsLayerChromium::addLinkHighlight):
1356         (WebCore::GraphicsLayerChromium::didFinishLinkHighlight):
1357         (WebCore::GraphicsLayerChromium::setContentsToMedia):
1358         (WebCore::GraphicsLayerChromium::primaryLayer):
1359         (WebCore::GraphicsLayerChromium::platformLayer):
1360         (WebCore::GraphicsLayerChromium::setDebugBackgroundColor):
1361         (WebCore::GraphicsLayerChromium::setDebugBorder):
1362         (WebCore::GraphicsLayerChromium::updateChildList):
1363         (WebCore::GraphicsLayerChromium::updateLayerPosition):
1364         (WebCore::GraphicsLayerChromium::updateLayerSize):
1365         (WebCore::GraphicsLayerChromium::updateAnchorPoint):
1366         (WebCore::GraphicsLayerChromium::updateTransform):
1367         (WebCore::GraphicsLayerChromium::updateChildrenTransform):
1368         (WebCore::GraphicsLayerChromium::updateMasksToBounds):
1369         (WebCore::GraphicsLayerChromium::updateLayerPreserves3D):
1370         (WebCore::GraphicsLayerChromium::updateLayerIsDrawable):
1371         (WebCore::GraphicsLayerChromium::updateLayerBackgroundColor):
1372         (WebCore::GraphicsLayerChromium::updateContentsRect):
1373         (WebCore::GraphicsLayerChromium::updateContentsScale):
1374         (WebCore::GraphicsLayerChromium::setupContentsLayer):
1375         * platform/graphics/chromium/GraphicsLayerChromium.h:
1376         (WebCore::GraphicsLayerChromium::hasContentsLayer):
1377         (GraphicsLayerChromium):
1378         (WebCore::GraphicsLayerChromium::contentsLayer):
1379         * platform/graphics/chromium/LayerChromium.cpp:
1380         (WebCore::LayerChromium::rootLayer):
1381         * platform/graphics/chromium/LayerChromium.h:
1382
1383 2012-08-21  Pavel Feldman  <pfeldman@chromium.org>
1384
1385         Web Inspector: do not use window's eval in InjectedScript
1386         https://bugs.webkit.org/show_bug.cgi?id=94610
1387
1388         Reviewed by Yury Semikhatsky.
1389
1390         Otherwise, inspector does not work when eval is overriden.
1391
1392         Test: inspector/console/console-eval-fake.html
1393
1394         * bindings/js/JSInjectedScriptHostCustom.cpp:
1395         (WebCore::JSInjectedScriptHost::evaluate):
1396         (WebCore):
1397         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
1398         (WebCore::V8InjectedScriptHost::evaluateCallback):
1399         (WebCore):
1400         * inspector/InjectedScriptHost.idl:
1401         * inspector/InjectedScriptSource.js:
1402         (.):
1403
1404 2012-08-21  Adam Barth  <abarth@webkit.org>
1405
1406         Implement JSDOMWindow*::allowsAccessFrom* in terms of BindingSecurity
1407         https://bugs.webkit.org/show_bug.cgi?id=93407
1408
1409         Reviewed by Eric Seidel.
1410
1411         This patch removes allowsAccessFrom and implements the security checks
1412         in terms of shouldAllowAccessToDOMWindow directly.
1413
1414         * bindings/generic/BindingSecurity.cpp:
1415         (WebCore::BindingSecurity::shouldAllowAccessToDOMWindow):
1416         (WebCore):
1417         * bindings/generic/BindingSecurity.h:
1418         (BindingSecurity):
1419         * bindings/js/JSDOMBinding.cpp:
1420         (WebCore::shouldAllowAccessToFrame):
1421         (WebCore):
1422         (WebCore::shouldAllowAccessToDOMWindow):
1423         * bindings/js/JSDOMBinding.h:
1424         (WebCore):
1425         * bindings/js/JSDOMWindowBase.cpp:
1426         (WebCore::shouldAllowAccessFrom):
1427         (WebCore):
1428         * bindings/js/JSDOMWindowBase.h:
1429         (JSDOMWindowBase):
1430         * bindings/js/JSDOMWindowCustom.cpp:
1431         (WebCore::namedItemGetter):
1432         (WebCore::JSDOMWindow::getOwnPropertySlot):
1433         (WebCore::JSDOMWindow::getOwnPropertyDescriptor):
1434         (WebCore::JSDOMWindow::put):
1435         (WebCore::JSDOMWindow::deleteProperty):
1436         (WebCore::JSDOMWindow::getPropertyNames):
1437         (WebCore::JSDOMWindow::getOwnPropertyNames):
1438         (WebCore::JSDOMWindow::defineOwnProperty):
1439         (WebCore::JSDOMWindow::setLocation):
1440         * bindings/js/JSDOMWindowCustom.h:
1441         * bindings/js/JSInjectedScriptManager.cpp:
1442         (WebCore::InjectedScriptManager::canAccessInspectedWindow):
1443         * bindings/objc/WebScriptObject.mm:
1444         (-[WebScriptObject _isSafeScript]):
1445         * bindings/scripts/CodeGeneratorJS.pm:
1446         (GenerateGetOwnPropertyDescriptorBody):
1447         (GenerateImplementation):
1448
1449 2012-08-21  Dan Bernstein  <mitz@apple.com>
1450
1451         <rdar://problem/12104508> TextIterator takes O(n^2) to iterate over n empty blocks
1452         https://bugs.webkit.org/show_bug.cgi?id=94429
1453
1454         Reviewed by Sam Weinig.
1455
1456         No new tests, because behavior is unchanged.
1457
1458         * editing/TextIterator.cpp:
1459         (WebCore::TextIterator::shouldRepresentNodeOffsetZero): Enhanced the check for nodes that
1460         cannot contain VisiblePosition to also check for zero-height blocks.
1461
1462 2012-08-21  'Pavel Feldman'  <pfeldman@chromium.org>
1463
1464         Web Inspector: break on exceptions decoration was lost, restoring.
1465
1466         Not reviewed - a follow up to 126012.
1467
1468         * inspector/front-end/ScriptsPanel.js:
1469         (WebInspector.ScriptsPanel.prototype._pauseOnExceptionStateChanged.get switch):
1470         (WebInspector.ScriptsPanel.prototype._pauseOnExceptionStateChanged):
1471
1472 2012-08-21  Sheriff Bot  <webkit.review.bot@gmail.com>
1473
1474         Unreviewed, rolling out r126146.
1475         http://trac.webkit.org/changeset/126146
1476         https://bugs.webkit.org/show_bug.cgi?id=94606
1477
1478         It made all tests assert (Requested by Ossy on #webkit).
1479
1480         * bridge/qt/qt_runtime.cpp:
1481         (JSC::Bindings::prototypeForSignalsAndSlots):
1482         (JSC::Bindings::QtRuntimeMethod::call):
1483         (JSC::Bindings::QtRuntimeMethod::jsObjectRef):
1484         (JSC::Bindings::QtRuntimeMethod::connectOrDisconnect):
1485         * bridge/qt/qt_runtime.h:
1486         (QtRuntimeMethod):
1487
1488 2012-08-21  Sheriff Bot  <webkit.review.bot@gmail.com>
1489
1490         Unreviewed, rolling out r126150.
1491         http://trac.webkit.org/changeset/126150
1492         https://bugs.webkit.org/show_bug.cgi?id=94605
1493
1494         Breaks 73 layout tests on chromium.webkit builder (Requested
1495         by pfeldman on #webkit).
1496
1497         * UseV8.cmake:
1498         * WebCore.gypi:
1499         * bindings/v8/V8Binding.cpp:
1500         (StringTraits):
1501         (WebCore):
1502         (WebCore::v8StringToWebCoreString):
1503         (WebCore::int32ToWebCoreStringFast):
1504         (WebCore::int32ToWebCoreString):
1505         * bindings/v8/V8Binding.h:
1506         (WebCore):
1507         (V8ParameterBase):
1508         (WebCore::V8ParameterBase::operator String):
1509         (WebCore::V8ParameterBase::operator AtomicString):
1510         (WebCore::V8ParameterBase::V8ParameterBase):
1511         (WebCore::V8ParameterBase::prepareBase):
1512         (WebCore::V8ParameterBase::object):
1513         (WebCore::V8ParameterBase::setString):
1514         (WebCore::V8ParameterBase::toString):
1515         (WebCore::::prepare):
1516         * bindings/v8/V8StringResource.cpp: Removed.
1517         * bindings/v8/V8StringResource.h: Removed.
1518
1519 2012-08-21  Philippe Normand  <pnormand@igalia.com>
1520
1521         Early returns in MediaPlayer setters
1522         https://bugs.webkit.org/show_bug.cgi?id=87304
1523
1524         Calls to the MediaPlayerPrivate implementation can be avoided if
1525         the value to set and the current value are equal.
1526
1527         Reviewed by Eric Carlson.
1528
1529         * platform/graphics/MediaPlayer.cpp:
1530         (WebCore::MediaPlayer::loadWithNextMediaEngine): Once a new
1531         MediaPlayerPrivate has been created propagate the playback rate
1532         value to it, as it is done for some other attributes like preload
1533         or preservePitch.
1534         (WebCore::MediaPlayer::setVolume): Perform action only if current
1535         and new values differ.
1536         (WebCore::MediaPlayer::setMuted): Ditto.
1537         (WebCore::MediaPlayer::setPreservesPitch): Ditto.
1538         (WebCore::MediaPlayer::setSize): Ditto.
1539         (WebCore::MediaPlayer::setVisible): Ditto.
1540         (WebCore::MediaPlayer::setPreload): Ditto.
1541
1542 2012-08-21  Ilya Tikhonovsky  <loislo@chromium.org>
1543
1544         Web Inspector: NMI: OwnPtr<T> was counted as RefPtr<T>
1545         https://bugs.webkit.org/show_bug.cgi?id=94599
1546
1547         Reviewed by Yury Semikhatsky.
1548
1549         * dom/MemoryInstrumentation.h:
1550         (WebCore::MemoryObjectInfo::MemoryObjectInfo):
1551         (WebCore::MemoryInstrumentation::addInstrumentedObjectImpl):
1552         (WebCore::MemoryInstrumentation::addObjectImpl):
1553
1554 2012-08-21  Ilya Tikhonovsky  <loislo@chromium.org>
1555
1556         Web Inspector: NMI: rename addMember for strings and KURL to addInstrumentedMember.
1557         https://bugs.webkit.org/show_bug.cgi?id=94580
1558
1559         Reviewed by Yury Semikhatsky.
1560
1561         Drive by fix: immutable ElementAttrybuteData uses the same trick with placement new as in StylePropertySet.
1562
1563         * css/CSSCanvasValue.cpp:
1564         (WebCore::CSSCanvasValue::reportDescendantMemoryUsage):
1565         * css/CSSCharsetRule.cpp:
1566         (WebCore::CSSCharsetRule::reportDescendantMemoryUsage):
1567         * css/CSSFontFaceSrcValue.cpp:
1568         (WebCore::CSSFontFaceSrcValue::reportDescendantMemoryUsage):
1569         * css/CSSFunctionValue.cpp:
1570         (WebCore::CSSFunctionValue::reportDescendantMemoryUsage):
1571         * css/CSSImageSetValue.cpp:
1572         (WebCore::CSSImageSetValue::ImageWithScale::reportMemoryUsage):
1573         * css/CSSImageValue.cpp:
1574         (WebCore::CSSImageValue::reportDescendantMemoryUsage):
1575         * css/CSSPrimitiveValue.cpp:
1576         (WebCore::CSSPrimitiveValue::reportDescendantMemoryUsage):
1577         * css/CSSStyleSheet.cpp:
1578         (WebCore::CSSStyleSheet::reportMemoryUsage):
1579         * css/CSSValue.cpp:
1580         (WebCore::TextCloneCSSValue::reportDescendantMemoryUsage):
1581         * css/CSSVariableValue.h:
1582         (WebCore::CSSVariableValue::reportDescendantMemoryUsage):
1583         * css/FontFeatureValue.cpp:
1584         (WebCore::FontFeatureValue::reportDescendantMemoryUsage):
1585         * css/MediaQuery.cpp:
1586         (WebCore::MediaQuery::reportMemoryUsage):
1587         * css/MediaQueryExp.cpp:
1588         (WebCore::MediaQueryExp::reportMemoryUsage):
1589         * css/StyleRuleImport.cpp:
1590         (WebCore::StyleRuleImport::reportDescendantMemoryUsage):
1591         * css/StyleSheetContents.cpp:
1592         (WebCore::StyleSheetContents::reportMemoryUsage):
1593         * css/WebKitCSSKeyframeRule.cpp:
1594         (WebCore::StyleKeyframe::reportMemoryUsage):
1595         * css/WebKitCSSKeyframesRule.cpp:
1596         (WebCore::StyleRuleKeyframes::reportDescendantMemoryUsage):
1597         * css/WebKitCSSSVGDocumentValue.cpp:
1598         (WebCore::WebKitCSSSVGDocumentValue::reportDescendantMemoryUsage):
1599         * css/WebKitCSSShaderValue.cpp:
1600         (WebCore::WebKitCSSShaderValue::reportDescendantMemoryUsage):
1601         * dom/Attribute.h:
1602         (WebCore::Attribute::reportMemoryUsage):
1603         * dom/CharacterData.cpp:
1604         (WebCore::CharacterData::reportMemoryUsage):
1605         * dom/Document.cpp:
1606         (WebCore::Document::reportMemoryUsage):
1607         * dom/ElementAttributeData.cpp:
1608         (WebCore::immutableElementAttributeDataSize):
1609         (WebCore):
1610         (WebCore::ElementAttributeData::createImmutable):
1611         (WebCore::ElementAttributeData::reportMemoryUsage):
1612         * dom/Event.cpp:
1613         (WebCore::Event::reportMemoryUsage):
1614         * dom/MemoryInstrumentation.cpp:
1615         (WebCore::MemoryInstrumentation::addInstrumentedObjectImpl):
1616         * dom/MemoryInstrumentation.h:
1617         (MemoryInstrumentation):
1618         * dom/QualifiedName.h:
1619         (WebCore::QualifiedName::QualifiedNameImpl::reportMemoryUsage):
1620         * loader/DocumentLoader.cpp:
1621         (WebCore::DocumentLoader::reportMemoryUsage):
1622         * loader/FrameLoader.cpp:
1623         (WebCore::FrameLoader::reportMemoryUsage):
1624         * loader/SubstituteData.cpp:
1625         (WebCore::SubstituteData::reportMemoryUsage):
1626         * loader/cache/CachedCSSStyleSheet.cpp:
1627         (WebCore::CachedCSSStyleSheet::reportMemoryUsage):
1628         * loader/cache/CachedResource.cpp:
1629         (WebCore::CachedResource::reportMemoryUsage):
1630         * loader/cache/CachedResourceLoader.cpp:
1631         (WebCore::CachedResourceLoader::reportMemoryUsage):
1632         * loader/cache/CachedScript.cpp:
1633         (WebCore::CachedScript::reportMemoryUsage):
1634         * loader/cache/CachedShader.cpp:
1635         (WebCore::CachedShader::reportMemoryUsage):
1636         * loader/cache/CachedXSLStyleSheet.cpp:
1637         (WebCore::CachedXSLStyleSheet::reportMemoryUsage):
1638         * loader/cache/MemoryCache.cpp:
1639         (WebCore::MemoryCache::reportMemoryUsage):
1640         * platform/network/ResourceRequestBase.cpp:
1641         (WebCore::ResourceRequestBase::reportMemoryUsage):
1642         * platform/network/ResourceResponseBase.cpp:
1643         (WebCore::ResourceResponseBase::reportMemoryUsage):
1644         * rendering/style/StyleRareInheritedData.cpp:
1645         (WebCore::StyleRareInheritedData::reportMemoryUsage):
1646         * rendering/style/StyleRareNonInheritedData.cpp:
1647         (WebCore::StyleRareNonInheritedData::reportMemoryUsage):
1648         * svg/SVGPaint.cpp:
1649         (WebCore::SVGPaint::reportDescendantMemoryUsage):
1650
1651 2012-08-20  Kentaro Hara  <haraken@chromium.org>
1652
1653         [V8] Move String related code in V8Binding to a separate file
1654         https://bugs.webkit.org/show_bug.cgi?id=94571
1655
1656         Reviewed by Adam Barth.
1657
1658         This patch moves V8Parameter, V8ParameterBase and String related code
1659         in V8Binding to a separate file.
1660
1661         No tests. No change in behavior.
1662
1663         * UseV8.cmake:
1664         * WebCore.gypi:
1665         * bindings/v8/V8Binding.cpp:
1666         * bindings/v8/V8Binding.h:
1667         * bindings/v8/V8StringResource.cpp: Added.
1668         * bindings/v8/V8StringResource.h: Added.
1669         (WebCore):
1670
1671 2012-08-17  Simon Hausmann  <simon.hausmann@nokia.com>
1672
1673         [Qt] REGRESSION(r125428): fast/profiler/nested-start-and-stop-profiler.html fails
1674         https://bugs.webkit.org/show_bug.cgi?id=93897
1675
1676         Reviewed by Kenneth Rohde Christiansen.
1677
1678         Before r125428 run-time methods (wrapped signals, slots or invokable functions) were subclasses of
1679         JSInternalFunction and therefore real function objects in the JavaScript sense. r125428 changed them
1680         to be just callable objects, but they did not have Function.prototype as prototype anymore for example
1681         nor was their name correct (resulting in a layout test failure).
1682
1683         This patch changes run-time methods back to being real function objects that have a correct name and
1684         have Function.prototype in their prototype change
1685
1686         The objects returned by JSObjectMakeFunctionWithCallbackInjected are light-weight internal function objects
1687         that do not support JSObject{Set/Get}Private. Therefore we inject our own prototype right before the
1688         Function.prototype prototype, which uses private data to store a pointer to our C++ QtRuntimeMethod object.
1689         This complicates the retrieval of the pointer to that instance slightly, which is why this patch introduces
1690         the toRuntimeMethod convenience function that looks up our prototype first and does a check for type-safety.
1691
1692         At the same time the patch removes the length properties from the run-time method itself as well as connect/disconnect.
1693         The length property on a function signifies the number of arguments, but in all three cases that number is
1694         actually variable, because of overloading. That is why we choose not to expose it in the first place.
1695
1696         * bridge/qt/qt_runtime.cpp:
1697         (JSC::Bindings::prototypeForSignalsAndSlots):
1698         (JSC::Bindings::QtRuntimeMethod::call):
1699         (JSC::Bindings::QtRuntimeMethod::jsObjectRef):
1700         (JSC::Bindings::QtRuntimeMethod::toRuntimeMethod):
1701         (Bindings):
1702         (JSC::Bindings::QtRuntimeMethod::connectOrDisconnect):
1703         * bridge/qt/qt_runtime.h:
1704         (QtRuntimeMethod): Remove unused member variables.
1705
1706 2012-08-21  Simon Hausmann  <simon.hausmann@nokia.com>
1707
1708         Unreviewed build fix for newer Qt 5 versions: QVariant::WidgetStar has been removed,
1709         but fortunately QMetaType has a much more powerful function available for us to use.
1710
1711         Thanks to Jedrzej Nowacki for the hint :)
1712
1713         * bridge/qt/qt_runtime.cpp:
1714         (JSC::Bindings::convertQVariantToValue):
1715
1716 2012-08-21  Kentaro Hara  <haraken@chromium.org>
1717
1718         [V8] Remove String::New() from V8 binding (Part 1)
1719         https://bugs.webkit.org/show_bug.cgi?id=94574
1720
1721         Reviewed by Adam Barth.
1722
1723         Currently, V8 binding mixes String::New(), String::NewSymbol() and v8String().
1724         String::New() should be replaced with String::NewSymbol() or v8String(),
1725         depending on use cases:
1726
1727         - If it is a symbol (e.g. attribute name, constant string, etc),
1728         String::NewSymbol() should be used. Cache of created symbols is managed by V8.
1729
1730         - If it is not a symbol, v8String() should be used. Cache of created strings
1731         is managed by V8 binding (i.e. StringCache class).
1732
1733         This patch replaces String::New() for symbols with String::NewSymbol().
1734
1735         No tests. No change in behavior.
1736
1737         * bindings/scripts/CodeGeneratorV8.pm:
1738         (GenerateNamedConstructorCallback):
1739         (GenerateNonStandardFunction):
1740         (GenerateImplementation):
1741         * bindings/scripts/test/V8/V8Float64Array.cpp:
1742         (WebCore::ConfigureV8Float64ArrayTemplate):
1743         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
1744         (WebCore::ConfigureV8TestActiveDOMObjectTemplate):
1745         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
1746         (WebCore::ConfigureV8TestEventTargetTemplate):
1747         * bindings/scripts/test/V8/V8TestInterface.cpp:
1748         (WebCore::ConfigureV8TestInterfaceTemplate):
1749         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
1750         (WebCore::V8TestNamedConstructorConstructor::GetTemplate):
1751         * bindings/scripts/test/V8/V8TestObj.cpp:
1752         (WebCore::ConfigureV8TestObjTemplate):
1753         (WebCore::V8TestObj::installPerContextProperties):
1754         * bindings/v8/V8DOMConfiguration.cpp:
1755         (WebCore::V8DOMConfiguration::batchConfigureConstants):
1756         (WebCore::V8DOMConfiguration::batchConfigureCallbacks):
1757         (WebCore::V8DOMConfiguration::configureTemplate):
1758         * bindings/v8/V8DOMConfiguration.h:
1759         (WebCore::V8DOMConfiguration::configureAttribute):
1760
1761 2012-08-21  Sheriff Bot  <webkit.review.bot@gmail.com>
1762
1763         Unreviewed, rolling out r126028.
1764         http://trac.webkit.org/changeset/126028
1765         https://bugs.webkit.org/show_bug.cgi?id=94576
1766
1767         it broke compilation on apple webkit win. (Requested by loislo
1768         on #webkit).
1769
1770         * inspector/CodeGeneratorInspector.py:
1771         * inspector/InjectedScriptWebGLModule.cpp:
1772         (WebCore::InjectedScriptWebGLModule::captureFrame):
1773         * inspector/InjectedScriptWebGLModule.h:
1774         (InjectedScriptWebGLModule):
1775         * inspector/Inspector.json:
1776         * inspector/InspectorController.cpp:
1777         (WebCore::InspectorController::InspectorController):
1778         * inspector/InspectorWebGLAgent.cpp:
1779         (WebCore::InspectorWebGLAgent::InspectorWebGLAgent):
1780         * inspector/InspectorWebGLAgent.h:
1781         (WebCore):
1782         (WebCore::InspectorWebGLAgent::create):
1783         (InspectorWebGLAgent):
1784
1785 2012-08-20  Ilya Tikhonovsky  <loislo@chromium.org>
1786
1787         Web Inspector: NMI: wrong size was reported for immutable StylePropertySet
1788         https://bugs.webkit.org/show_bug.cgi?id=94489
1789
1790         Reviewed by Yury Semikhatsky.
1791
1792         Immutable StylePropertySet is created via placement new.
1793         The rest of the allocated buffer is used as an array of CSSProperty.
1794         This means that we don't need to report m_properties member but have to report actual size of the buffer
1795         used for both, the object and CSSProperty array.
1796
1797         * css/StylePropertySet.cpp:
1798         (WebCore::immutableStylePropertySetSize):
1799         (WebCore):
1800         (WebCore::StylePropertySet::createImmutable):
1801         (WebCore::StylePropertySet::reportMemoryUsage):
1802         * dom/MemoryInstrumentation.h:
1803         (WebCore::MemoryObjectInfo::reportObjectInfo):
1804         (WebCore::MemoryClassInfo::MemoryClassInfo):
1805
1806 2012-08-20  Kentaro Hara  <haraken@chromium.org>
1807
1808         [V8] Move handleOutOfMemory() from V8Proxy to V8Binding
1809         https://bugs.webkit.org/show_bug.cgi?id=94563
1810
1811         Reviewed by Adam Barth.
1812
1813         To kill V8Proxy, this patch moves handleOutOfMemory() from V8Proxy to V8Binding.
1814
1815         No tests. No change in behavior.
1816
1817         * bindings/v8/V8AbstractEventListener.cpp:
1818         (WebCore::V8AbstractEventListener::invokeEventHandler):
1819         * bindings/v8/V8Binding.cpp:
1820         (WebCore::handleOutOfMemory):
1821         (WebCore):
1822         * bindings/v8/V8Binding.h:
1823         (WebCore):
1824         * bindings/v8/V8Proxy.cpp:
1825         * bindings/v8/V8Proxy.h:
1826         (V8Proxy):
1827         * bindings/v8/WorkerContextExecutionProxy.cpp:
1828         (WebCore::WorkerContextExecutionProxy::runScript):
1829
1830 2012-08-20  MORITA Hajime  <morrita@google.com>
1831
1832         InsertionShouldCallDidNotifyDescendantInsertions should be merged to InsertionShouldCallDidNotifySubtreeInsertions
1833         https://bugs.webkit.org/show_bug.cgi?id=94570
1834
1835         Reviewed by Ryosuke Niwa.
1836
1837         Node::didNotifySubtreeInsertions() and Node::didNotifyDescendantInsertions() are used for similar purpose and
1838         we could unify them to the safer one, which is didNotifySubtreeInsertions().
1839
1840         This change replaces the last didNotifyDescendantInsertions() implementation in HTMLBodyElement with didNotifySubtreeInsertions()
1841         then eliminates related code which is no longer used.
1842
1843         No new tests. Covered by existing tests.
1844
1845         * dom/ContainerNodeAlgorithms.h:
1846         (WebCore::ChildNodeInsertionNotifier::notifyNodeInsertedIntoDocument):
1847         (WebCore::ChildNodeInsertionNotifier::notifyNodeInsertedIntoTree):
1848         * dom/Node.h: Removed didNotifyDescendantInsertions() stub and InsertionShouldCallDidNotifyDescendantInsertions enum value.
1849         * html/HTMLBodyElement.cpp:
1850         (WebCore::HTMLBodyElement::insertedInto):
1851         (WebCore::HTMLBodyElement::didNotifySubtreeInsertions): morphed from didNotifyDescendantInsertions()
1852         * html/HTMLBodyElement.h:
1853         (HTMLBodyElement):
1854         * html/HTMLFormElement.cpp:
1855         (WebCore::HTMLFormElement::insertedInto): Remove useless InsertionShouldCallDidNotifyDescendantInsertions return statement.
1856
1857 2012-08-20  Rob Buis  <rbuis@rim.com>
1858
1859         Reduce GradientAttributes object size
1860         https://bugs.webkit.org/show_bug.cgi?id=86151
1861
1862         Reviewed by Eric Seidel.
1863
1864         This reduces GradientAttributes in memory size by 8 bytes on my 64-bit system. It also
1865         reduces the size of RenderSVGResourceLinearGradient and RenderSVGResourceRadialGradient.
1866
1867         * svg/GradientAttributes.h:
1868         (WebCore::GradientAttributes::spreadMethod):
1869         (WebCore::GradientAttributes::gradientUnits):
1870         (GradientAttributes):
1871         (WebCore):
1872         (SameSizeAsGradientAttributes):
1873
1874 2012-08-20  Keishi Hattori  <keishi@webkit.org>
1875
1876         Clicking input type=range with padding or border sets wrong value
1877         https://bugs.webkit.org/show_bug.cgi?id=94473
1878
1879         Reviewed by Kent Tamura.
1880
1881         We should take the padding and border width into account when calculating the value from the mouse location.
1882
1883         Test: fast/forms/range/range-hit-test-with-padding.html
1884
1885         * html/shadow/SliderThumbElement.cpp:
1886         (WebCore::sliderTrackElementOf):
1887         (WebCore):
1888         (WebCore::SliderThumbElement::setPositionFromPoint):
1889         * html/shadow/SliderThumbElement.h:
1890         (WebCore):
1891
1892 2012-08-20  MORITA Hajime  <morrita@google.com>
1893
1894         load event shouldn't fired during node insertion traversals.
1895         https://bugs.webkit.org/show_bug.cgi?id=94447
1896
1897         Reviewed by Ryosuke Niwa.
1898
1899         HTMLFrameElementBase::didNotifyDescendantInsertions() with empty @src
1900         can trigger a load event during ChildNodeInsertionNotifier
1901         traversal, whose handler can make DOM tree state inconsistent.
1902
1903         This change introduces a post traversal hook,
1904         didNotifySubtreeInsertions(), for the insertion traversal and
1905         replaces the problematic didNotifyDescendantInsertions() with it.
1906
1907         Since didNotifySubtreeInsertions() is invoked after the traversal,
1908         it is safe for event handlers to mutate the tree.
1909
1910         Test: fast/frames/iframe-onload-and-domnodeinserted.html
1911
1912         * dom/ContainerNodeAlgorithms.h:
1913         (ChildNodeInsertionNotifier): Added a post subtree notification.
1914         (WebCore::ChildNodeInsertionNotifier::notifyNodeInsertedIntoDocument):
1915         (WebCore::ChildNodeInsertionNotifier::notify):
1916         * dom/Node.h:
1917         (WebCore::Node::didNotifySubtreeInsertions): Newly added.
1918         * html/HTMLFrameElementBase.cpp:
1919         (WebCore::HTMLFrameElementBase::insertedInto): Now returns InsertionShouldCallDidNotifySubtreeInsertions
1920         (WebCore::HTMLFrameElementBase::didNotifySubtreeInsertions): Replaced didNotifyDescendantInsertions()
1921         * html/HTMLFrameElementBase.h:
1922         (HTMLFrameElementBase):
1923
1924 2012-08-20  Shinya Kawanaka  <shinyak@chromium.org> 
1925
1926         Regression(r126127): Build break on multiple platforms
1927         https://bugs.webkit.org/show_bug.cgi?id=94568
1928
1929         Reviewed by Hajime Morita.
1930
1931         Notation::cloneNode should also have ExceptionCode. We add it in this patch.
1932
1933         No new tests, no change in behavior.
1934
1935         * dom/Notation.cpp:
1936         (WebCore::Notation::cloneNode):
1937         * dom/Notation.h:
1938         (Notation):
1939
1940 2012-08-20  Shinya Kawanaka  <shinyak@chromium.org>
1941
1942         ShadowRoot.cloneNode() must always throw a DATA_CLONE_ERR exception.
1943         https://bugs.webkit.org/show_bug.cgi?id=91704
1944
1945         Reviewed by Dimitri Glazkov.
1946
1947         According to the spec, ShadowRoot.cloneNode() should throw a DATA_CLONE_ERR exception. The existing implementation
1948         returned null object instead.
1949
1950         We change the cloneNode() interface so that we can throw an exception from cloneNode().
1951
1952         Test: fast/dom/shadow/shadowroot-clonenode.html
1953
1954         * dom/Attr.cpp:
1955         (WebCore::Attr::cloneNode):
1956         * dom/Attr.h:
1957         * dom/CDATASection.cpp:
1958         (WebCore::CDATASection::cloneNode):
1959         * dom/CDATASection.h:
1960         (CDATASection):
1961         * dom/Comment.cpp:
1962         (WebCore::Comment::cloneNode):
1963         * dom/Comment.h:
1964         (Comment):
1965         * dom/Document.cpp:
1966         (WebCore::Document::cloneNode):
1967         * dom/Document.h:
1968         (Document):
1969         * dom/DocumentFragment.cpp:
1970         (WebCore::DocumentFragment::cloneNode):
1971         * dom/DocumentFragment.h:
1972         (DocumentFragment):
1973         * dom/DocumentType.cpp:
1974         (WebCore::DocumentType::cloneNode):
1975         * dom/DocumentType.h:
1976         (DocumentType):
1977         * dom/Element.cpp:
1978         (WebCore::Element::cloneNode):
1979         * dom/Element.h:
1980         (Element):
1981         * dom/EntityReference.cpp:
1982         (WebCore::EntityReference::cloneNode):
1983         * dom/EntityReference.h:
1984         (EntityReference):
1985         * dom/Node.h:
1986         (Node):
1987         (WebCore::Node::cloneNode):
1988         * dom/Node.idl:
1989         * dom/ProcessingInstruction.cpp:
1990         (WebCore::ProcessingInstruction::cloneNode):
1991         * dom/ProcessingInstruction.h:
1992         (ProcessingInstruction):
1993         * dom/ShadowRoot.cpp:
1994         (WebCore::ShadowRoot::cloneNode):
1995         * dom/ShadowRoot.h:
1996         (ShadowRoot):
1997         * dom/Text.cpp:
1998         (WebCore::Text::cloneNode):
1999         * dom/Text.h:
2000         (Text):
2001
2002 2012-08-20  Kent Tamura  <tkent@chromium.org>
2003
2004         [Chromium-win] Use native digits in parsing/formatting dates in the textfield part of input[type=date]
2005         https://bugs.webkit.org/show_bug.cgi?id=94281
2006
2007         Reviewed by Hajime Morita.
2008
2009         Tests: Add some cases to Source/WebKit/chromium/tests/LocaleWinTest.cpp
2010
2011         * platform/text/LocaleWin.cpp:
2012         (WebCore::LocaleWin::isLocalizedDigit): A helper for parseNumber(). This
2013         return true if the specified character is one of native digits.
2014         (WebCore::LocaleWin::parseNumber):
2015         Try to parse ASCII digits, then try to parse native digtis. This
2016         becomes a member of LocaleWin because it uses
2017         convertFromLocalizedNumber().
2018         (WebCore::LocaleWin::appendNumber): Apply convertToLocalizedNumber().
2019         (WebCore::LocaleWin::appendTwoDigitsNumber): ditto.
2020         (WebCore::LocaleWin::appendFourDigitsNumber): ditto.
2021         * platform/text/LocaleWin.h:
2022         (LocaleWin):
2023         - Make some static functions member functions of LocaleWin.
2024         - Add isLocalizedDigit().
2025
2026 2012-08-20  Kentaro Hara  <haraken@chromium.org>
2027
2028         Rename collectGarbageIfNecessary() to hintForCollectGarbage()
2029         https://bugs.webkit.org/show_bug.cgi?id=94455
2030
2031         Reviewed by Adam Barth.
2032
2033         This is a follow-up patch for r126098.
2034
2035         collectGarbage() always collects garbage. collectGarbageIfNecessary() just sends
2036         an idle notification to V8, which is just a hint for V8 to trigger GC.
2037         To clarify the difference, this patch renames collectGarbageIfNecessary()
2038         to hintForCollectGarbage().
2039
2040         No tests. No change in behavior.
2041
2042         * bindings/v8/ScriptController.cpp:
2043         (WebCore::ScriptController::clearForClose):
2044         (WebCore::ScriptController::clearForNavigation):
2045         * bindings/v8/V8GCController.cpp:
2046         (WebCore::V8GCController::hintForCollectGarbage):
2047         * bindings/v8/V8GCController.h:
2048         (V8GCController):
2049
2050 2012-08-20  Alexandre Elias  <aelias@google.com>
2051
2052         [chromium] Texture layer should not generate zero textureId quads
2053         https://bugs.webkit.org/show_bug.cgi?id=94550
2054
2055         Reviewed by Adrienne Walker.
2056
2057         After a context loss, CCTextureLayerImpl would clear its textureId
2058         but continued to produce external resources and quads with the zero
2059         textureid.  Add early returns so that CCTextureLayerImpl becomes
2060         inert after a context loss.
2061
2062         Added assertion in read lock so that dontUseOldResourcesAfterLostContext
2063         test catches the problem.
2064
2065         * platform/graphics/chromium/cc/CCResourceProvider.h:
2066         (WebCore::CCScopedLockResourceForRead::CCScopedLockResourceForRead):
2067         * platform/graphics/chromium/cc/CCTextureLayerImpl.cpp:
2068         (WebCore::CCTextureLayerImpl::willDraw):
2069         (WebCore::CCTextureLayerImpl::appendQuads):
2070         (WebCore::CCTextureLayerImpl::didDraw):
2071         (WebCore::CCTextureLayerImpl::didLoseContext):
2072
2073 2012-08-20  Kent Tamura  <tkent@chromium.org>
2074
2075         [Chromium] Make the popup positioning code testable
2076         https://bugs.webkit.org/show_bug.cgi?id=94086
2077
2078         Reviewed by Hajime Morita.
2079
2080         Introduce PopupContent interface in order to make a mock.
2081
2082         * platform/chromium/PopupContainer.cpp:
2083         (WebCore::PopupContainer::layoutAndCalculateWidgetRectInternal):
2084          - Make it a member of PopupContainer to avoid namespace pollution.
2085          - Use PopupContent interface.
2086          - Make the code clearer.
2087         * platform/chromium/PopupContainer.h:
2088         (PopupContainer): Expose layoutAndCalculateWidgetRectInternal.
2089
2090         * platform/chromium/PopupListBox.cpp:
2091         (WebCore::PopupListBox::popupContentHeight): Added.
2092         * platform/chromium/PopupListBox.h:
2093         (PopupContent): Added.
2094         (PopupListBox): Inherit PopupContent.
2095         (WebCore::PopupListBox::~PopupListBox):
2096         Make this virtual because this class has some virtual functions.
2097
2098 2012-08-20  Tom Sepez  <tsepez@chromium.org>
2099
2100         XSSAuditor too tolerant of injected data: URLs from other "hostless" schemes.
2101         https://bugs.webkit.org/show_bug.cgi?id=94547
2102
2103         Reviewed by Adam Barth.
2104
2105         Check that there is a host before making same-host tests.
2106
2107         Test: fast/frames/xss-auditor-handles-file-urls.html
2108
2109         * html/parser/XSSAuditor.cpp:
2110         (WebCore::XSSAuditor::eraseAttributeIfInjected):
2111         (WebCore::XSSAuditor::isLikelySafeResource):
2112         * html/parser/XSSAuditor.h:
2113
2114 2012-08-20  Elliott Sprehn  <esprehn@chromium.org>
2115
2116         Removed dead code from a very old iteration of CSS counters.
2117         https://bugs.webkit.org/show_bug.cgi?id=94539
2118
2119         Reviewed by Eric Seidel.
2120
2121         Remove two unused shorts that were on StyleRareNonInheritedData that are no longer used.
2122
2123         No tests, this just removes dead code.
2124
2125         * rendering/style/RenderStyle.cpp:
2126         (WebCore::RenderStyle::diff):
2127         * rendering/style/RenderStyle.h:
2128         * rendering/style/StyleRareNonInheritedData.cpp:
2129         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
2130         (WebCore::StyleRareNonInheritedData::operator==):
2131         * rendering/style/StyleRareNonInheritedData.h:
2132         (StyleRareNonInheritedData):
2133
2134 2012-08-20  Luke Macpherson   <macpherson@chromium.org>
2135
2136         Fix inspector with variables enabled and enable inspector variables tests by default.
2137         https://bugs.webkit.org/show_bug.cgi?id=94296
2138
2139         Reviewed by Hajime Morita.
2140
2141         Change from using getPropertyName static function to CSSProperty::cssName(), which can resolve variables if needed.
2142
2143         Covered by inspector/styles/variables.
2144
2145         * css/PropertySetCSSStyleDeclaration.cpp:
2146         (WebCore::PropertySetCSSStyleDeclaration::item):
2147
2148 2012-08-20  Sudarsana Nagineni  <sudarsana.nagineni@linux.intel.com>
2149
2150         Cancel the outstanding vibration pattern if the pattern is 0 or an empty list
2151         https://bugs.webkit.org/show_bug.cgi?id=94085
2152
2153         Reviewed by Kentaro Hara.
2154
2155         vibrate() method to stop the device from vibrating is getting called before the
2156         vibration is in effect. Hence, it is failing to cancel the pre-existing instance
2157         of processing vibration patterns. 
2158
2159         This patch cancel the pre-existing instance of the processing vibration patterns
2160         always when the vibrate() method called with pattern 0 or an empty list.
2161
2162         No new tests since there is no return value in the Vibration API to test this
2163         particular case. Existing test fast/dom/navigator-vibration.html covers testing of
2164         the Vibration API.
2165
2166         * Modules/vibration/Vibration.cpp:
2167         (WebCore::Vibration::vibrate):
2168
2169 2012-08-20  Adam Klein  <adamk@chromium.org>
2170
2171         Allow MutationEvents to be enabled/disabled per context
2172         https://bugs.webkit.org/show_bug.cgi?id=94016
2173
2174         Reviewed by Ojan Vafai.
2175
2176         Chromium wants to be able to turn MutationEvents off for some
2177         Documents (e.g., for Apps V2). This patch makes the firing (and the
2178         constructor on DOMWindow) of MutationEvents a per-context feature, with
2179         the default being enabled.
2180
2181         No functional change (since the feature defaults to enabled).
2182         It's not clear to me that there's a way to test this in DRT without
2183         adding a special hook for this one feature. It will be tested in
2184         Chromium once it's implemented in Chromium.
2185
2186         * dom/ContextFeatures.cpp:
2187         (WebCore::ContextFeatures::mutationEventsEnabled): Add new method,
2188         with the default being enabled.
2189         * dom/ContextFeatures.h:
2190         * dom/Document.cpp:
2191         (WebCore::Document::addMutationEventListenerTypeIfEnabled): Add new
2192         method that checks the ContextFeature flag before adding the passed-in
2193         listener type.
2194         (WebCore::Document::addListenerTypeIfNeeded): Call the new method
2195         instead of addListenerType for MutationEvent types.
2196         * dom/Document.h:
2197         (WebCore::Document::addListenerType): Make private to avoid anyone
2198         outside Document from enabling MutationEvent listeners. All callers
2199         must go through addListenerTypeIfNeeded.
2200
2201 2012-08-20  Levi Weintraub  <leviw@chromium.org>
2202
2203         [Sub-pixel Layout] Block selection gap repainting can leave one pixel gaps
2204         https://bugs.webkit.org/show_bug.cgi?id=94526
2205
2206         Reviewed by Eric Seidel.
2207
2208         Reverting RenderLayer's m_blockSelectionGapsBounds to be an IntRect and applying enclosingIntRect to the
2209         gapRects added to the bounds. Previously, we'd end multiple block gaps and pixel snap the result, which
2210         can yield results one pixel off in width and height.
2211
2212         Covered by existing tests. This undoes some of the rebaselining from when sub-pixel was enabled for Chromium.
2213
2214         * rendering/RenderLayer.cpp:
2215         * rendering/RenderLayer.h:
2216
2217 2012-08-20  Kentaro Hara  <haraken@chromium.org>
2218
2219         [V8] Move instrumentedCallFunction() from V8Proxy to ScriptController
2220         https://bugs.webkit.org/show_bug.cgi?id=94456
2221
2222         Reviewed by Adam Barth.
2223
2224         To kill V8Proxy, this patch moves instrumentedCallFunction() from V8Proxy
2225         to ScriptController. Also this patch renames instrumentedCallFunction()
2226         to callFunctionWithInstrumentation(), for consistency with callFunction().
2227
2228         No tests. No change in behavior.
2229
2230         * bindings/v8/ScriptController.cpp:
2231         (WebCore::ScriptController::callFunction):
2232         (WebCore):
2233         (WebCore::handleMaxRecursionDepthExceeded):
2234         (WebCore::resourceInfo):
2235         (WebCore::resourceString):
2236         (WebCore::ScriptController::callFunctionWithInstrumentation):
2237         * bindings/v8/ScriptController.h:
2238         (ScriptController):
2239         * bindings/v8/ScriptFunctionCall.cpp:
2240         (WebCore::ScriptCallback::call):
2241         * bindings/v8/V8Callback.cpp:
2242         (WebCore::invokeCallback):
2243         * bindings/v8/V8NodeFilterCondition.cpp:
2244         (WebCore::V8NodeFilterCondition::acceptNode):
2245         * bindings/v8/V8Proxy.cpp:
2246         (WebCore):
2247         * bindings/v8/V8Proxy.h:
2248         (V8Proxy):
2249         * bindings/v8/V8WindowErrorHandler.cpp:
2250         (WebCore::V8WindowErrorHandler::callListenerFunction):
2251         * bindings/v8/custom/V8CustomXPathNSResolver.cpp:
2252         (WebCore::V8CustomXPathNSResolver::lookupNamespaceURI):
2253
2254 2012-08-20  Elliott Sprehn  <esprehn@chromium.org>
2255
2256         Never notify of insertedIntoTree during document destruction.
2257         https://bugs.webkit.org/show_bug.cgi?id=94535
2258
2259         Reviewed by Eric Seidel.
2260
2261         Never notify of insertedIntoTree during document destruction. Previously since we
2262         avoid notifying of willBeRemovedFromTree it's possible we could have gotten several
2263         insertedIntoTree notifications without ever being told we were removed.
2264
2265         No tests needed since this just closes holes related to future code.
2266
2267         * rendering/RenderObjectChildList.cpp:
2268         (WebCore::RenderObjectChildList::appendChildNode): Never call insertedIntoTree during document destruction.
2269         (WebCore::RenderObjectChildList::insertChildNode): Same.
2270         * rendering/RenderRegion.cpp:
2271         (WebCore::RenderRegion::attachRegion): Removed unneeded document destruction check.
2272
2273 2012-08-20  James Robinson  <jamesr@chromium.org>
2274
2275         [chromium] Initialize GraphicsLayerChromium::m_contentsLayerId when setting contents layer
2276         https://bugs.webkit.org/show_bug.cgi?id=94552
2277
2278         Reviewed by Kenneth Russell.
2279
2280         Set it or it don't work good.
2281
2282         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
2283         (WebCore::GraphicsLayerChromium::setupContentsLayer):
2284
2285 2012-08-20  Rik Cabanier  <cabanier@adobe.com>
2286
2287         parse CSS attribute -webkit-blend-mode
2288         https://bugs.webkit.org/show_bug.cgi?id=94024
2289  
2290         Reviewed by Dirk Schulze.
2291
2292         Added parsing and general CSS handling of -webkit-blend-mode per http://www.w3.org/TR/2012/WD-compositing-20120816/
2293
2294         Tests: css3/compositing/blend-mode-property-parsing-invalid.html
2295                css3/compositing/blend-mode-property-parsing.html
2296                css3/compositing/blend-mode-property.html
2297
2298         * css/CSSComputedStyleDeclaration.cpp:
2299         (WebCore):
2300         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
2301         * css/CSSParser.cpp:
2302         (WebCore::isValidKeywordPropertyAndValue):
2303         (WebCore::isKeywordPropertyID):
2304         (WebCore::CSSParser::parseValue):
2305         * css/CSSProperty.cpp:
2306         (WebCore::CSSProperty::isInheritedProperty):
2307         * css/CSSPropertyNames.in:
2308         * css/CSSValueKeywords.in:
2309         * css/StyleBuilder.cpp:
2310         (WebCore::StyleBuilder::StyleBuilder):
2311         * rendering/RenderLayer.h:
2312         (RenderLayer):
2313         * rendering/RenderLayerBacking.cpp:
2314         (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer):
2315         (WebCore):
2316         (WebCore::RenderLayerBacking::updateLayerBlendMode):
2317         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
2318         (WebCore::RenderLayerBacking::setBlendMode):
2319         * rendering/RenderLayerBacking.h:
2320         (RenderLayerBacking):
2321         * rendering/style/RenderStyle.cpp:
2322         (WebCore::RenderStyle::diff):
2323         * rendering/style/RenderStyle.h:
2324         * rendering/style/StyleRareNonInheritedData.cpp:
2325         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
2326         (WebCore::StyleRareNonInheritedData::operator==):
2327         * rendering/style/StyleRareNonInheritedData.h:
2328         (StyleRareNonInheritedData):
2329
2330 2012-08-20  Kentaro Hara  <haraken@chromium.org>
2331
2332         [V8] Move retrieve{Window,Frame,PerContextData}() from V8Proxy to V8Binding
2333         https://bugs.webkit.org/show_bug.cgi?id=94460
2334
2335         Reviewed by Adam Barth.
2336
2337         To kill V8Proxy, we move retrieve{Window,Frame,PerContextData}()
2338         from V8Proxy to V8Binding. Also, this patch renames these methods as follows:
2339
2340         - retrieveWindow() -> toDOMWindow()
2341         - retrieveFrame() -> toFrameIfNotDetached()
2342         - retrievePerContextData() -> perContextDataForCurrentWorld()
2343
2344         No tests. No change in behavior.
2345
2346         * bindings/v8/BindingState.cpp:
2347         (WebCore::activeDOMWindow):
2348         (WebCore::firstDOMWindow):
2349         (WebCore::activeFrame):
2350         (WebCore::firstFrame):
2351         (WebCore::currentFrame):
2352         (WebCore::currentDocument):
2353         * bindings/v8/PageScriptDebugServer.cpp:
2354         (WebCore::retrieveFrameWithGlobalObjectCheck):
2355         (WebCore::PageScriptDebugServer::getDebugListenerForContext):
2356         (WebCore::PageScriptDebugServer::runMessageLoopOnPause):
2357         * bindings/v8/V8Binding.cpp:
2358         (WebCore::retrieveWindow):
2359         (WebCore):
2360         (WebCore::retrieveFrame):
2361         (WebCore::retrievePerContextData):
2362         * bindings/v8/V8Binding.h:
2363         (WebCore):
2364         * bindings/v8/V8DOMWrapper.cpp:
2365         (WebCore::V8DOMWrapper::constructorForType):
2366         * bindings/v8/V8NPUtils.cpp:
2367         (WebCore::convertV8ObjectToNPVariant):
2368         * bindings/v8/V8Proxy.cpp:
2369         (WebCore::V8Proxy::handleOutOfMemory):
2370         (WebCore::V8Proxy::context):
2371         (WebCore::V8Proxy::matchesCurrentContext):
2372         * bindings/v8/V8Proxy.h:
2373         (V8Proxy):
2374
2375 2012-08-20  Abhishek Arya  <inferno@chromium.org>
2376
2377         Yank an unneccessary if added in r125810.
2378         https://bugs.webkit.org/show_bug.cgi?id=85804
2379
2380         Reviewed by Levi Weintraub.
2381
2382         * rendering/RenderBlockLineLayout.cpp:
2383         (WebCore::RenderBlock::layoutInlineChildren):
2384
2385 2012-08-20  James Robinson  <jamesr@chromium.org>
2386
2387         [chromium] REGRESSION(126076) Should not touch old GraphicsLayerChromium::m_contentsLayer when setting up a new contents layer
2388         https://bugs.webkit.org/show_bug.cgi?id=94544
2389
2390         Reviewed by Adrienne Walker.
2391
2392         GraphicsLayerChromium only keeps a weak pointer to its m_contentsLayer. When replacing it with a new contents
2393         layer, it may be unsafe to touch the old value. It's also completely unnecessary.
2394
2395         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
2396         (WebCore::GraphicsLayerChromium::GraphicsLayerChromium):
2397         (WebCore::GraphicsLayerChromium::setContentsToImage):
2398         (WebCore::GraphicsLayerChromium::setContentsTo):
2399         (WebCore::GraphicsLayerChromium::setupContentsLayer):
2400         * platform/graphics/chromium/GraphicsLayerChromium.h:
2401
2402 2012-08-20  Kentaro Hara  <haraken@chromium.org>
2403
2404         [V8] Move collectGarbage() from ScriptController to V8GCController
2405         https://bugs.webkit.org/show_bug.cgi?id=94455
2406
2407         Reviewed by Adam Barth.
2408
2409         - This patch moves collectGarbage() from ScriptController to V8GCController.
2410         - This patch makes collectGarbage() a static method.
2411         - This patch removes ScriptController::lowMemoryNotification()
2412         since it is not used at all.
2413
2414         No tests. No change in behavior.
2415
2416         * bindings/v8/ScriptController.cpp:
2417         * bindings/v8/ScriptController.h:
2418         * bindings/v8/V8GCController.cpp:
2419         (WebCore::V8GCController::collectGarbage):
2420         (WebCore):
2421         * bindings/v8/V8GCController.h:
2422         (V8GCController):
2423
2424 2012-08-20  Kentaro Hara  <haraken@chromium.org>
2425
2426         [V8] Remove V8Proxy from V8IsolatedContext
2427         https://bugs.webkit.org/show_bug.cgi?id=94450
2428
2429         Reviewed by Adam Barth.
2430
2431         This patch removes dependency on V8Proxy from V8IsolatedContext.
2432
2433         No tests. No change in behavior.
2434
2435         * bindings/v8/ScriptController.cpp:
2436         (WebCore::ScriptController::evaluateInIsolatedWorld):
2437         * bindings/v8/V8IsolatedContext.cpp:
2438         (WebCore::V8IsolatedContext::V8IsolatedContext):
2439         * bindings/v8/V8IsolatedContext.h:
2440         (WebCore):
2441         (V8IsolatedContext):
2442
2443 2012-08-20  Philip Rogers  <pdr@google.com>
2444
2445         Canvas drawImage() should draw SVG at the correct scale.
2446         https://bugs.webkit.org/show_bug.cgi?id=94377
2447
2448         Previously, drawing SVG in canvas would render at the incorrect scale
2449         because imageSizeForRenderer did not take into account the page scale.
2450         After this patch, we now incorporate the page scale in
2451         CachedImage::imageSizeForRenderer().
2452
2453         Reviewed by Tim Horton.
2454
2455         Test: svg/as-image/svg-as-image-canvas.html
2456
2457         * loader/cache/CachedImage.cpp:
2458         (WebCore::CachedImage::imageSizeForRenderer):
2459
2460 2012-08-20  Simon Fraser  <simon.fraser@apple.com>
2461
2462         Assertion going back to results.html page from an image diff result
2463         https://bugs.webkit.org/show_bug.cgi?id=94143
2464
2465         Reviewed by Adam Barth.
2466
2467         Avoid redundantly setting the DOMWindow on a JSDOMWindow shell in
2468         ScriptCachedFrameData::restore(), as we may have already done this
2469         in ScriptController::clearWindowShell(). This avoids an assertion
2470         on some platforms when going Back to the test results page from
2471         a diff image.
2472
2473         * bindings/js/ScriptCachedFrameData.cpp:
2474         (WebCore::ScriptCachedFrameData::restore):
2475
2476 2012-08-20  Dean Jackson  <dino@apple.com>
2477
2478         [WebGL] OES_vertex_array_object is not correctly un/binding or deleting
2479         https://bugs.webkit.org/show_bug.cgi?id=94029
2480
2481         Reviewed by Ken Russell.
2482
2483         When the currently bound vertex array is deleted, the specification says that
2484         the default object should be bound in its place. Also, binding a null object
2485         as a vertex array was not actually clearing the bound object at the GL layer.
2486         And lastly, it should not be possible to bind a deleted vertex array.
2487
2488         The test case for this is the public Khronos WebGL conformance suite, in particular:
2489         conformance/extensions/oes-vertex-array-object.html
2490
2491         * html/canvas/OESVertexArrayObject.cpp:
2492         (WebCore::OESVertexArrayObject::deleteVertexArrayOES): Check if the deleted array is
2493         currently bound, and if so, unbind it.
2494         (WebCore::OESVertexArrayObject::bindVertexArrayOES): Make sure never to bind an
2495         array that has been marked as deleted.
2496         * platform/graphics/opengl/Extensions3DOpenGL.cpp:
2497         (WebCore::Extensions3DOpenGL::bindVertexArrayOES): Remove the null check on bind. We
2498         do need to call glBindVertexArrayAPPLE with a null value in order to clear it.
2499
2500 2012-08-20  Kentaro Hara  <haraken@chromium.org>
2501
2502         [V8] Move clearForClose() and clearForNavigation() from V8Proxy to ScriptController
2503         https://bugs.webkit.org/show_bug.cgi?id=94459
2504
2505         Reviewed by Adam Barth.
2506
2507         To kill V8Proxy, we can move clearForClose() and
2508         clearForNavigation() from V8Proxy to ScriptController.
2509
2510         No tests. No change in behavior.
2511
2512         * bindings/v8/ScriptController.cpp:
2513         (WebCore::ScriptController::~ScriptController):
2514         (WebCore::ScriptController::resetIsolatedWorlds):
2515         (WebCore):
2516         (WebCore::ScriptController::clearForClose):
2517         (WebCore::ScriptController::clearForNavigation):
2518         (WebCore::ScriptController::clearWindowShell):
2519         * bindings/v8/ScriptController.h:
2520         (ScriptController):
2521         * bindings/v8/V8Proxy.cpp:
2522         (WebCore::V8Proxy::~V8Proxy):
2523         (WebCore::V8Proxy::handleOutOfMemory):
2524         * bindings/v8/V8Proxy.h:
2525         (V8Proxy):
2526
2527 2012-08-20  Dirk Schulze  <krit@webkit.org>
2528
2529         CSS Masking and CSS Filters applied in wrong order
2530         https://bugs.webkit.org/show_bug.cgi?id=94354
2531
2532         Reviewed by Dean Jackson.
2533
2534         According to the Filter Effects spec, the order should be first filters, then masking and clipping.
2535         Changed the order on applying the different effects in RenderLayer.
2536
2537         Test: css3/filters/filter-mask-clip-order.html
2538
2539         * rendering/RenderLayer.cpp:
2540         (WebCore::RenderLayer::paintLayerContents): First filter, then mask and clip the content.
2541
2542 2012-08-20  Kentaro Hara  <haraken@chromium.org>
2543
2544         [V8] Move mainWorldContext() from V8Proxy to ScriptController
2545         https://bugs.webkit.org/show_bug.cgi?id=94453
2546
2547         Reviewed by Adam Barth.
2548
2549         This patch moves mainWorldContext() from V8Proxy to ScriptController.
2550         In addition, this patch removes dependency on V8Proxy from WorldContextHandle.
2551
2552         No tests. No change in behavior.
2553
2554         * bindings/v8/DOMTransaction.cpp:
2555         (WebCore::DOMTransaction::callFunction):
2556         * bindings/v8/NPV8Object.cpp:
2557         (WebCore::toV8Context):
2558         * bindings/v8/ScriptController.cpp:
2559         (WebCore::ScriptController::evaluate):
2560         (WebCore::ScriptController::mainWorldContext):
2561         (WebCore):
2562         (WebCore::ScriptController::bindToWindowObject):
2563         (WebCore::createScriptObject):
2564         (WebCore::ScriptController::createScriptObjectForPluginElement):
2565         * bindings/v8/ScriptController.h:
2566         (ScriptController):
2567         * bindings/v8/ScriptState.cpp:
2568         (WebCore::mainWorldScriptState):
2569         * bindings/v8/V8LazyEventListener.cpp:
2570         (WebCore::V8LazyEventListener::prepareListenerObject):
2571         * bindings/v8/V8Proxy.cpp:
2572         (WebCore::V8Proxy::context):
2573         (WebCore::toV8Context):
2574         * bindings/v8/V8Proxy.h:
2575         (V8Proxy):
2576         * bindings/v8/WorldContextHandle.cpp:
2577         (WebCore::WorldContextHandle::adjustedContext):
2578         * bindings/v8/WorldContextHandle.h:
2579         (WebCore):
2580         (WorldContextHandle):
2581
2582 2012-08-20  Adam Klein  <adamk@chromium.org>
2583
2584         Remove redundant TOUCH_LISTENER event type
2585         https://bugs.webkit.org/show_bug.cgi?id=94524
2586
2587         Reviewed by Ryosuke Niwa.
2588
2589         Code that needs to determine whether there are touch listeners
2590         can instead call Document::touchEventHandlerCount(), added in r107832.
2591         TOUCH_LISTENER didn't fit very well into the hasListenerType() model
2592         anyway, as there's not a 1:1 correspondance between the enum value and
2593         an event.
2594
2595         * dom/Document.cpp:
2596         (WebCore::Document::addListenerTypeIfNeeded): Remove two bits of code:
2597         the bookkeeping for TOUCH_LISTENER, and the notification into
2598         ChromeClient (which is handled by calls to didAddTouchEventHandler in
2599         all the places that call addListenerTypeIfNeeded).
2600         (WebCore::Document::didRemoveTouchEventHandler): Remove bookkeeping for TOUCH_LISTENER.
2601         * dom/Document.h:
2602         * history/CachedFrame.cpp:
2603         (WebCore::CachedFrameBase::restore): Call touchEventHandlerCount instead of hasListenerType.
2604         * html/HTMLInputElement.cpp:
2605         (WebCore::HTMLInputElement::updateType): ditto
2606         * page/EventHandler.cpp:
2607         (WebCore::EventHandler::handleTouchEvent): ditto
2608         * page/Frame.cpp:
2609         (WebCore::Frame::setDocument): ditto
2610         * testing/Internals.cpp: Remove hasTouchEventListener method since its
2611         data source no longer exists.
2612         * testing/Internals.h: ditto
2613         (Internals):
2614         * testing/Internals.idl: ditto
2615
2616 2012-08-16  James Robinson  <jamesr@chromium.org>
2617
2618         [chromium] Change WebLayer from a concrete type to a pure virtual interface
2619         https://bugs.webkit.org/show_bug.cgi?id=94174
2620
2621         Reviewed by Adrienne Walker.
2622
2623         This updates WebCore code for the WebLayer interface changes. Classes that have ownership of specific layer
2624         types (such as DrawingBufferChromium, Canvas2DLayerBridge and ScrollingCoordinatorChromium) hold ownership
2625         of a specific type and a pointer to the WebLayer to GraphicsLayerChromium to be included in the final layer
2626         tree. GraphicsLayerChromium holds a WebContentLayer and (optionally) a WebImageLayer and WebLayer (for
2627         m_transformLayer) and assembles the final layer tree.
2628
2629         * page/scrolling/chromium/ScrollingCoordinatorChromium.cpp:
2630         (WebCore::ScrollingCoordinatorPrivate::ScrollingCoordinatorPrivate):
2631         (ScrollingCoordinatorPrivate):
2632         (WebCore::ScrollingCoordinatorPrivate::setScrollLayer):
2633         (WebCore::ScrollingCoordinatorPrivate::setHorizontalScrollbarLayer):
2634         (WebCore::ScrollingCoordinatorPrivate::setVerticalScrollbarLayer):
2635         (WebCore::ScrollingCoordinatorPrivate::scrollLayer):
2636         (WebCore::scrollableLayerForGraphicsLayer):
2637         (WebCore):
2638         (WebCore::createScrollbarLayer):
2639         (WebCore::ScrollingCoordinator::setScrollLayer):
2640         (WebCore::ScrollingCoordinator::setNonFastScrollableRegion):
2641         (WebCore::ScrollingCoordinator::setWheelEventHandlerCount):
2642         (WebCore::ScrollingCoordinator::setShouldUpdateScrollLayerPositionOnMainThread):
2643         (WebCore::ScrollingCoordinator::setLayerIsContainerForFixedPositionLayers):
2644         (WebCore::ScrollingCoordinator::setLayerIsFixedToContainerLayer):
2645         * platform/graphics/chromium/Canvas2DLayerBridge.cpp:
2646         (WebCore::AcceleratedDeviceContext::AcceleratedDeviceContext):
2647         (WebCore::AcceleratedDeviceContext::clearLayer):
2648         (AcceleratedDeviceContext):
2649         (WebCore::AcceleratedDeviceContext::prepareForDraw):
2650         (WebCore::Canvas2DLayerBridge::Canvas2DLayerBridge):
2651         (WebCore::Canvas2DLayerBridge::~Canvas2DLayerBridge):
2652         (WebCore::Canvas2DLayerBridge::skCanvas):
2653         (WebCore::Canvas2DLayerBridge::layer):
2654         (WebCore::Canvas2DLayerBridge::contextAcquired):
2655         * platform/graphics/chromium/Canvas2DLayerBridge.h:
2656         (WebCore):
2657         (Canvas2DLayerBridge):
2658         * platform/graphics/chromium/DrawingBufferChromium.cpp:
2659         (WebCore::DrawingBufferPrivate::DrawingBufferPrivate):
2660         (WebCore::DrawingBufferPrivate::~DrawingBufferPrivate):
2661         (WebCore::DrawingBufferPrivate::layer):
2662         (DrawingBufferPrivate):
2663         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
2664         (WebCore::GraphicsLayerChromium::GraphicsLayerChromium):
2665         (WebCore::GraphicsLayerChromium::~GraphicsLayerChromium):
2666         (WebCore::GraphicsLayerChromium::updateNames):
2667         (WebCore::GraphicsLayerChromium::removeFromParent):
2668         (WebCore::GraphicsLayerChromium::setSize):
2669         (WebCore::GraphicsLayerChromium::clearBackgroundColor):
2670         (WebCore::GraphicsLayerChromium::setContentsOpaque):
2671         (WebCore::GraphicsLayerChromium::setFilters):
2672         (WebCore::GraphicsLayerChromium::setBackgroundFilters):
2673         (WebCore::GraphicsLayerChromium::setMaskLayer):
2674         (WebCore::GraphicsLayerChromium::setBackfaceVisibility):
2675         (WebCore::GraphicsLayerChromium::setOpacity):
2676         (WebCore::GraphicsLayerChromium::setReplicatedByLayer):
2677         (WebCore::GraphicsLayerChromium::setContentsNeedsDisplay):
2678         (WebCore::GraphicsLayerChromium::setNeedsDisplay):
2679         (WebCore::GraphicsLayerChromium::setNeedsDisplayInRect):
2680         (WebCore::GraphicsLayerChromium::setContentsToImage):
2681         (WebCore::GraphicsLayerChromium::setContentsToCanvas):
2682         (WebCore):
2683         (WebCore::GraphicsLayerChromium::setContentsToMedia):
2684         (WebCore::GraphicsLayerChromium::setContentsTo):
2685         (WebCore::GraphicsLayerChromium::addAnimation):
2686         (WebCore::GraphicsLayerChromium::pauseAnimation):
2687         (WebCore::GraphicsLayerChromium::removeAnimation):
2688         (WebCore::GraphicsLayerChromium::suspendAnimations):
2689         (WebCore::GraphicsLayerChromium::resumeAnimations):
2690         (WebCore::GraphicsLayerChromium::addLinkHighlight):
2691         (WebCore::GraphicsLayerChromium::didFinishLinkHighlight):
2692         (WebCore::GraphicsLayerChromium::platformLayer):
2693         (WebCore::GraphicsLayerChromium::setDebugBackgroundColor):
2694         (WebCore::GraphicsLayerChromium::setDebugBorder):
2695         (WebCore::GraphicsLayerChromium::updateChildList):
2696         (WebCore::GraphicsLayerChromium::updateLayerPosition):
2697         (WebCore::GraphicsLayerChromium::updateLayerSize):
2698         (WebCore::GraphicsLayerChromium::updateAnchorPoint):
2699         (WebCore::GraphicsLayerChromium::updateTransform):
2700         (WebCore::GraphicsLayerChromium::updateChildrenTransform):
2701         (WebCore::GraphicsLayerChromium::updateMasksToBounds):
2702         (WebCore::GraphicsLayerChromium::updateLayerPreserves3D):
2703         (WebCore::GraphicsLayerChromium::updateLayerIsDrawable):
2704         (WebCore::GraphicsLayerChromium::updateLayerBackgroundColor):
2705         (WebCore::GraphicsLayerChromium::updateContentsRect):
2706         (WebCore::GraphicsLayerChromium::updateContentsScale):
2707         (WebCore::GraphicsLayerChromium::setupContentsLayer):
2708         * platform/graphics/chromium/GraphicsLayerChromium.h:
2709         (WebCore::GraphicsLayerChromium::hasContentsLayer):
2710         (WebCore::GraphicsLayerChromium::contentLayer):
2711         (GraphicsLayerChromium):
2712         (WebCore::GraphicsLayerChromium::contentsLayer):
2713         * platform/graphics/chromium/LayerChromium.cpp:
2714         (WebCore::LayerChromium::rootLayer):
2715         * platform/graphics/chromium/LayerChromium.h:
2716
2717 2012-08-20  Leandro Gracia Gil  <leandrogracia@chromium.org>
2718
2719         Move transformFriendlyBoundingBox out of Range
2720         https://bugs.webkit.org/show_bug.cgi?id=94366
2721
2722         Reviewed by Simon Fraser and Ryosuke Niwa.
2723
2724         Bug 93111 introduced a new method in Range called transformFriendlyBoundingBox.
2725         However, this method should not have been added there in order to reduce the
2726         dependencies between Range and the rendering code. This patch moves it to a
2727         static method in RenderObject.
2728
2729         Tests: existing tests, no new feature added by this patch.
2730
2731         * dom/Range.cpp:
2732         * dom/Range.h:
2733         * rendering/RenderObject.cpp:
2734         (WebCore::RenderObject::absoluteBoundingBoxRectForRange):
2735         (WebCore):
2736         * rendering/RenderObject.h:
2737         (RenderObject):
2738
2739 2012-08-20  Ryosuke Niwa  <rniwa@webkit.org>
2740
2741         Replace isolate || bidi-override by isolate-override
2742         https://bugs.webkit.org/show_bug.cgi?id=89746
2743
2744         Reviewed by Levi Weintraub.
2745
2746         The combination of bidi-isolate and isolate was replaced by a single isolate-override in
2747         http://lists.w3.org/Archives/Public/www-style/2012May/0541.html. The spec. has been updated accordingly:
2748         http://dev.w3.org/csswg/css3-writing-modes/#unicode-bidi
2749
2750         To follow the specification change, added -webkit-isolate-override and removed the support for
2751         isolate || bidi-override, simplifying the CSS parser and serializer.
2752
2753         Test: fast/text/bidi-override-isolate.html
2754
2755         * css/CSSComputedStyleDeclaration.cpp:
2756         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): Removed. We can just new a CSSPrimitiveValue
2757         constructor now.
2758         * css/CSSParser.cpp:
2759         (WebCore::CSSParser::parseValue):
2760         * css/CSSPrimitiveValueMappings.h:
2761         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Added now that unicode-bidi always creates a signle
2762         primitive value instead of a primitive value of css value list.
2763         (WebCore::CSSPrimitiveValue::operator EUnicodeBidi):
2764         * css/CSSValueKeywords.in: Added -webkit-isolate-override
2765         * css/StyleBuilder.cpp:
2766         (WebCore): Removed ApplyPropertyUnicodeBidi since we can use ApplyPropertyDefault now.
2767         (WebCore::StyleBuilder::StyleBuilder): Use ApplyPropertyDefault.
2768         * platform/text/UnicodeBidi.h: Renamed OverrideIsolate to IsolateOverride to match the spec.
2769         (WebCore::isIsolated):
2770         (WebCore::isOverride):
2771         * rendering/RenderBlockLineLayout.cpp:
2772         (WebCore::constructBidiRuns):
2773
2774 2012-08-20  Tony Chang  <tony@chromium.org>
2775
2776         RenderGrid children should always be RenderBoxes
2777         https://bugs.webkit.org/show_bug.cgi?id=94305
2778
2779         Reviewed by Abhishek Arya.
2780
2781         During RenderGrid::layout, we assume all the children are RenderBoxes.
2782         When removing children, if the last child is an anonymous block, we don't
2783         want to remove the anonymous block for grids. Ensure this doesn't happen
2784         by adding canCollapseAnonymousBlockChild to RenderBlock (flexboxen and
2785         grid can override this method).
2786
2787         Test: fast/css-grid-layout/should-not-collapse-anonymous-blocks.html
2788
2789         * rendering/RenderBlock.cpp:
2790         (WebCore::RenderBlock::removeChild): Check canCollapseAnonymousBlockChild().
2791         * rendering/RenderBlock.h:
2792         (WebCore::RenderBlock::canCollapseAnonymousBlockChild):
2793         (RenderBlock):
2794         * rendering/RenderDeprecatedFlexibleBox.h: canCollapseAnonymousBlockChild returns false.
2795         * rendering/RenderFlexibleBox.h: canCollapseAnonymousBlockChild returns false.
2796         * rendering/RenderGrid.h: canCollapseAnonymousBlockChild returns false.
2797
2798 2012-08-20  Kenneth Russell  <kbr@google.com>
2799
2800         Unreviewed, rolling out r126026.
2801         http://trac.webkit.org/changeset/126026
2802         https://bugs.webkit.org/show_bug.cgi?id=94449
2803
2804         Caused assertion failure in layout test touchadjustment/context-menu.html
2805
2806         * page/TouchAdjustment.cpp:
2807         (TouchAdjustment):
2808         (WebCore::TouchAdjustment::providesContextMenuItems):
2809         (WebCore::TouchAdjustment::appendSubtargetsForNodeToList):
2810         (WebCore::TouchAdjustment::compileSubtargetList):
2811         (WebCore::findBestClickableCandidate):
2812         (WebCore::findBestContextMenuCandidate):
2813
2814 2012-08-20  Andrew Lo  <anlo@rim.com>
2815
2816         [BlackBerry] Enabling DEBUG_LAYER_ANIMATION results in build break & warnings
2817         https://bugs.webkit.org/show_bug.cgi?id=94514
2818
2819         Reviewed by Rob Buis.
2820
2821         Add wtf::CString definition to fix build break when enabling DEBUG_LAYER_ANIMATION
2822         debug prints. Fix build warnings from prints.
2823
2824         No new tests, non-functional change.
2825
2826         * platform/graphics/blackberry/GraphicsLayerBlackBerry.cpp:
2827         (WebCore::GraphicsLayerBlackBerry::addAnimation):
2828         (WebCore::GraphicsLayerBlackBerry::pauseAnimation):
2829
2830 2012-08-20  Christophe Dumez  <christophe.dumez@intel.com>
2831
2832         [JSC] SerializedScriptValue::create() should throw a DataCloneError if input is an unsupported object
2833         https://bugs.webkit.org/show_bug.cgi?id=94493
2834
2835         Reviewed by Oliver Hunt.
2836
2837         Update JSC implementation for SerializedScriptValue::create() so that
2838         a DataCloneError is thrown when the input value is an unsupported
2839         object. The previous implementation was not throwing any error.
2840
2841         This change is according to the structured clone specification at:
2842         http://www.w3.org/TR/html5/common-dom-interfaces.html#structured-clone
2843
2844         This also matches the corresponding V8 implementation.
2845
2846         Test: fast/events/message-port-multi.html.
2847
2848         * bindings/js/SerializedScriptValue.cpp:
2849         (WebCore::CloneSerializer::dumpIfTerminal):
2850         (WebCore::CloneSerializer::serialize):
2851         (WebCore::SerializedScriptValue::maybeThrowExceptionIfSerializationFailed):
2852         * bindings/js/SerializedScriptValue.h:
2853
2854 2012-08-20  Sheriff Bot  <webkit.review.bot@gmail.com>
2855
2856         Unreviewed, rolling out r125884.
2857         http://trac.webkit.org/changeset/125884
2858         https://bugs.webkit.org/show_bug.cgi?id=94523
2859
2860         Appears to be causing a top crash in the Canary channel
2861         (Requested by abarth on #webkit).
2862
2863         * UseV8.cmake:
2864         * WebCore.gypi:
2865         * bindings/v8/DOMWrapperWorld.cpp:
2866         (WebCore::DOMWrapperWorld::DOMWrapperWorld):
2867         (WebCore::mainThreadNormalWorld):
2868         * bindings/v8/DOMWrapperWorld.h:
2869         (WebCore):
2870         (WebCore::DOMWrapperWorld::create):
2871         (WebCore::DOMWrapperWorld::~DOMWrapperWorld):
2872         (DOMWrapperWorld):
2873         * bindings/v8/IsolatedWorld.cpp: Copied from Source/WebCore/bindings/v8/DOMWrapperWorld.cpp.
2874         (WebCore):
2875         (WebCore::IsolatedWorld::IsolatedWorld):
2876         (WebCore::IsolatedWorld::~IsolatedWorld):
2877         * bindings/v8/IsolatedWorld.h: Copied from Source/WebCore/bindings/v8/DOMWrapperWorld.h.
2878         (WebCore):
2879         (IsolatedWorld):
2880         (WebCore::IsolatedWorld::create):
2881         (WebCore::IsolatedWorld::count):
2882         (WebCore::IsolatedWorld::id):
2883         (WebCore::IsolatedWorld::domDataStore):
2884         * bindings/v8/V8DOMWrapper.h:
2885         (WebCore::V8DOMWrapper::getCachedWrapper):
2886         * bindings/v8/V8IsolatedContext.cpp:
2887         (WebCore::V8IsolatedContext::V8IsolatedContext):
2888         (WebCore::V8IsolatedContext::destroy):
2889         * bindings/v8/V8IsolatedContext.h:
2890         (WebCore::V8IsolatedContext::getEntered):
2891         (WebCore::V8IsolatedContext::world):
2892         (V8IsolatedContext):
2893         * bindings/v8/V8PerIsolateData.h:
2894         (WebCore::V8PerIsolateData::registerDOMDataStore):
2895         (WebCore::V8PerIsolateData::unregisterDOMDataStore):
2896
2897 2012-08-20  Chris Rogers  <crogers@google.com>
2898
2899         Remove improper ASSERT in AudioParamTimeline::valuesForTimeRangeImpl()
2900         https://bugs.webkit.org/show_bug.cgi?id=94504
2901
2902         Reviewed by Kenneth Russell.
2903
2904         AudioParamTimeline::valuesForTimeRangeImpl() is able to handle the case where there are no timeline events.
2905         So don't ASSERT for that case.
2906
2907         * Modules/webaudio/AudioParamTimeline.cpp:
2908         (WebCore::AudioParamTimeline::valuesForTimeRangeImpl):
2909
2910 2012-08-20  Ken Buchanan  <kenrb@chromium.org>
2911         Line boxes not being dirtied correctly during inline removal
2912         https://bugs.webkit.org/show_bug.cgi?id=93156
2913
2914         Reviewed by David Hyatt.
2915
2916         When two inline objects were being removed from different lineboxes
2917         in an ancestral RenderBlock, the way the RenderBlock was being marked
2918         prevented the second linebox from being marked dirty. This causes
2919         it to not get layout in the subsequent layout pass.
2920
2921         This patch causes only the descendants corresponding to actual changed
2922         lineboxes to have their ancestorLineBoxDirty bit set, rather than
2923         the RenderBlock that contains the lineboxes themselves.
2924
2925         * rendering/RenderLineBoxList.cpp:
2926         (WebCore::RenderLineBoxList::dirtyLinesFromChangedChild):
2927
2928 2012-08-20  John Mellor  <johnme@chromium.org>
2929
2930         Text Autosizing: Only take into account block width <= document layout width.
2931         https://bugs.webkit.org/show_bug.cgi?id=93862
2932
2933         Reviewed by Kenneth Rohde Christiansen.
2934
2935         Instead of calculating the textAutosizingMultiplier purely based on the
2936         width of each block, we now work out the maximum width of the block
2937         that could be displayed onscreen at any one time, and use that value.
2938         This avoids excessive text size multiplication (there's no point making
2939         text bigger than this, since you wouldn't be able to zoom out far
2940         enough to read it!).
2941
2942         To determine the maximum onscreen block width, we take the minimum of
2943         the block width and the layoutWidth of the narrowest non-flattened
2944         ancestor frame. Flattened frames are ignored since they don't impose a
2945         hard limit on the maximum width that can be displayed, instead they can
2946         stretch to fit their contents. Note that on mobile the layoutWidth of
2947         the main frame is the fixed layout width aka viewport width.
2948
2949         In practice this caps the maximum multiplier to a value that depends
2950         on the metrics of the device. For example on a Nexus S (480 x 800px
2951         and 1.5x devicePixelRatio) with a 980px default fixed layout width,
2952         this limits the multiplier to: 980 / (480/1.5) = 3.0625
2953
2954         Most pages won't have blocks that actually hit this cap, or they will
2955         only slightly exceed it (so their multiplier will only be slightly
2956         reduced). For example it's not uncommon for desktop pages to be
2957         slightly wider than 980px, but they would have to additionally have
2958         text that spans the full width of the page for this to affect them, and
2959         even then it would merely slightly decrease their multiplier).
2960
2961         This will have more dramatic effects on the rare desktop pages which
2962         give a width=device-width (or similar) mobile viewport tag (on ports
2963         which support viewports). A follow-up patch will hopefully address this
2964         by wrapping the text in such excessively wide blocks to the layoutWidth.
2965
2966         Tests: fast/text-autosizing/narrow-iframe-flattened.html
2967                fast/text-autosizing/narrow-iframe.html
2968                fast/text-autosizing/wide-block.html
2969                fast/text-autosizing/wide-iframe.html
2970
2971         * page/FrameView.cpp:
2972         (WebCore::FrameView::isInChildFrameWithFrameFlattening):
2973
2974             Made public and const, so can be used from TextAutosizer.
2975
2976         * rendering/TextAutosizer.cpp:
2977         (WebCore::TextAutosizer::processSubtree):
2978
2979             Computes the minimum layout width of the parent frames, as described
2980             above.
2981
2982         (WebCore::TextAutosizer::processBlock):
2983
2984             Limits used block width to this min layout width.
2985
2986 2012-08-20  Hans Wennborg  <hans@chromium.org>
2987
2988         Respect runtime flags for Device Orientation and Device Motion
2989         https://bugs.webkit.org/show_bug.cgi?id=94479
2990
2991         Reviewed by Adam Barth.
2992
2993         There are flags that allows disabling of device orientation and device
2994         motion at runtime. These flags determine the availability of the
2995         corresponding event constructors in DOMWindow.
2996
2997         However, the flags should also control the ability to add event
2998         listeners for these events, otherwise the feature can be used even if
2999         it is disabled.
3000
3001         * page/DOMWindow.cpp:
3002         (WebCore::DOMWindow::addEventListener):
3003
3004 2012-08-20  Philip Rogers  <pdr@google.com>
3005
3006         Remove incorrect getBBox() code
3007         https://bugs.webkit.org/show_bug.cgi?id=94419
3008
3009         Reviewed by Dirk Schulze.
3010
3011         SVGPathElement defines a getBBox() function that is wrong and
3012         should use objectBoundingBox(). This patch cleans this up.
3013
3014         No new tests as this is just a cleanup of old code.
3015
3016         * svg/SVGPathElement.cpp:
3017         (WebCore):
3018         * svg/SVGPathElement.h:
3019         (SVGPathElement):
3020
3021 2012-08-20  David Reveman  <reveman@chromium.org>
3022
3023         [Chromium] Schedule texture uploads based on hard-coded timer and vsync.
3024         https://bugs.webkit.org/show_bug.cgi?id=84281
3025
3026         Reviewed by James Robinson.
3027
3028         Improve interaction between vsync and texture uploads by performing
3029         uploads in smaller batches and use a hard-coded timer to emulate
3030         upload completion. This greatly reduces the chance of the compositor
3031         missing a vsync due to being busy with texture uploads.
3032
3033         The CCScheduler client is now given a time limit when told to update
3034         more resources. This time limit is passed to an instance of the
3035         CCTextureUpdateController class, which is responsible for performing
3036         texture updates until the limit is reached.
3037
3038         Unit tests: CCSchedulerTest.RequestCommit
3039                     CCTextureUpdateControllerTest.UpdateMoreTextures
3040                     CCTextureUpdateControllerTest.HasMoreUpdates
3041
3042         * platform/graphics/chromium/cc/CCFrameRateController.cpp:
3043         (WebCore::CCFrameRateController::nextTickTime):
3044         (WebCore):
3045         * platform/graphics/chromium/cc/CCFrameRateController.h:
3046         (CCFrameRateController):
3047         * platform/graphics/chromium/cc/CCScheduler.cpp:
3048         (WebCore::CCScheduler::processScheduledActions):
3049         * platform/graphics/chromium/cc/CCScheduler.h:
3050         (CCSchedulerClient):
3051         * platform/graphics/chromium/cc/CCTextureUpdateController.cpp:
3052         (WebCore::CCTextureUpdateController::maxPartialTextureUpdates):
3053         (WebCore::CCTextureUpdateController::CCTextureUpdateController):
3054         (WebCore::CCTextureUpdateController::updateMoreTextures):
3055         (WebCore):
3056         (WebCore::CCTextureUpdateController::onTimerFired):
3057         (WebCore::CCTextureUpdateController::monotonicTimeNow):
3058         (WebCore::CCTextureUpdateController::updateMoreTexturesTime):
3059         (WebCore::CCTextureUpdateController::updateMoreTexturesSize):
3060         (WebCore::CCTextureUpdateController::updateMoreTexturesIfEnoughTimeRemaining):
3061         (WebCore::CCTextureUpdateController::updateMoreTexturesNow):
3062         * platform/graphics/chromium/cc/CCTextureUpdateController.h:
3063         (WebCore::CCTextureUpdateController::create):
3064         (CCTextureUpdateController):
3065         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
3066         (WebCore::CCThreadProxy::beginFrameCompleteOnImplThread):
3067         (WebCore::CCThreadProxy::scheduledActionUpdateMoreResources):
3068         * platform/graphics/chromium/cc/CCThreadProxy.h:
3069
3070 2012-08-20  Bruno de Oliveira Abinader  <bruno.abinader@basyskom.com>
3071
3072         [css3-text] Add parsing support for -webkit-text-decoration-style
3073         https://bugs.webkit.org/show_bug.cgi?id=94093
3074
3075         Reviewed by Julien Chaffraix.
3076
3077         This patch implements the "text-decoration-style" property parsing as specified
3078         in CSS3 working draft, with "-webkit-" prefix. The specification can be found
3079         here: http://dev.w3.org/csswg/css3-text/#text-decoration-style
3080
3081         Additionally, Mozilla implementation details can be found here:
3082         https://developer.mozilla.org/en-US/docs/CSS/text-decoration-style
3083
3084         This is an individual task for bug 90958. Rendering support will be handled on a
3085         different bug.
3086
3087         Test: fast/css3-text-decoration/getComputedStyle/getComputedStyle-text-decoration-style.html
3088
3089         * css/CSSComputedStyleDeclaration.cpp:
3090         (WebCore::renderTextDecorationStyleFlagsToCSSValue):
3091         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3092         * css/CSSParser.cpp:
3093         (WebCore::CSSParser::parseValue):
3094         * css/CSSPrimitiveValueMappings.h:
3095         (WebCore::CSSPrimitiveValue::operator TextDecorationStyle):
3096         * css/CSSProperty.cpp:
3097         (WebCore::CSSProperty::isInheritedProperty):
3098         * css/CSSPropertyNames.in:
3099         * css/CSSValueKeywords.in:
3100         * css/StyleBuilder.cpp:
3101         (WebCore::StyleBuilder::StyleBuilder):
3102         * css/StyleResolver.cpp:
3103         (WebCore::StyleResolver::collectMatchingRulesForList):
3104         * rendering/style/RenderStyle.cpp:
3105         (WebCore::RenderStyle::diff):
3106         * rendering/style/RenderStyle.h:
3107         * rendering/style/RenderStyleConstants.h: Added non-bitwise TextDecorationStyle enum.
3108         * rendering/style/StyleRareNonInheritedData.cpp:
3109         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData): Added m_textDecorationStyle to default and copy constructors.
3110         (WebCore::StyleRareNonInheritedData::operator==): Include m_textDecorationStyle in comparison.
3111         * rendering/style/StyleRareNonInheritedData.h:
3112         (StyleRareNonInheritedData):
3113         Added m_textDecorationStyle here as it won't be used regularly.
3114
3115 2012-08-20  Jakob Petsovits  <jpetsovits@rim.com>
3116
3117         [BlackBerry] Persist cookies not from atexit() but the new onThreadFinished()
3118         https://bugs.webkit.org/show_bug.cgi?id=94482
3119         RIM PR 184923
3120
3121         Reviewed by Yong Li.
3122
3123         BlackBerry::Platform recently made changes that ensure
3124         that MessageClient threads are being shut down correctly.
3125         A new onThreadFinished() virtual was introduced for
3126         custom clean-up functionality and can replace the
3127         atexit() handler that we previously used to flush cookies
3128         to the cookie database backingstore.
3129
3130         No new functionality, no new tests.
3131
3132         * platform/blackberry/CookieDatabaseBackingStore/CookieDatabaseBackingStore.cpp:
3133         (WebCore):
3134         (WebCore::CookieDatabaseBackingStore::onThreadFinished):
3135         (WebCore::CookieDatabaseBackingStore::sendChangesToDatabaseSynchronously):
3136         * platform/blackberry/CookieDatabaseBackingStore/CookieDatabaseBackingStore.h:
3137         (CookieDatabaseBackingStore):
3138         * platform/blackberry/CookieManager.cpp:
3139         (WebCore):
3140         (WebCore::cookieManager):
3141         * platform/blackberry/CookieManager.h:
3142
3143 2012-08-20  Alexandre Elias  <aelias@google.com>
3144
3145         [chromium] Move non-GL-specific code out of LayerRendererChromium
3146         https://bugs.webkit.org/show_bug.cgi?id=93927
3147
3148         Reviewed by Adrienne Walker.
3149
3150         This patch moves most of the generic logic dealing with matrices and
3151         render passes into a new class "CCDirectRenderer" that sits between
3152         CCRenderer and LayerRendererChromium, and also publicly exposes a
3153         few other things like the UnthrottledTextureUploader.
3154
3155         The plan is for the future software compositing implementation to also
3156         derive from CCDirectRenderer, whereas the ubercompositor delegating
3157         renderer will still derive from CCRenderer.
3158
3159         No new tests (no-op refactoring).
3160
3161         * WebCore.gypi:
3162         * platform/graphics/chromium/GeometryBinding.cpp:
3163         (WebCore::GeometryBinding::GeometryBinding):
3164         * platform/graphics/chromium/GeometryBinding.h:
3165         (GeometryBinding):
3166         * platform/graphics/chromium/LayerRendererChromium.cpp:
3167         (WebCore::LayerRendererChromium::LayerRendererChromium):
3168         (WebCore::LayerRendererChromium::beginDrawingFrame):
3169         (WebCore::LayerRendererChromium::drawQuad):
3170         (WebCore::LayerRendererChromium::drawRenderPassQuad):
3171         (WebCore::LayerRendererChromium::drawTileQuad):
3172         (WebCore::LayerRendererChromium::finishDrawingFrame):
3173         (WebCore::LayerRendererChromium::drawQuadGeometry):
3174         (WebCore::LayerRendererChromium::bindFramebufferToOutputSurface):
3175         (WebCore):
3176         (WebCore::LayerRendererChromium::bindFramebufferToTexture):
3177         (WebCore::LayerRendererChromium::enableScissorTestRect):
3178         (WebCore::LayerRendererChromium::disableScissorTest):
3179         (WebCore::LayerRendererChromium::setDrawViewportSize):
3180         (WebCore::LayerRendererChromium::makeContextCurrent):
3181         (WebCore::LayerRendererChromium::initializeSharedObjects):
3182         * platform/graphics/chromium/LayerRendererChromium.h:
3183         (LayerRendererChromium):
3184         * platform/graphics/chromium/TextureCopier.h:
3185         (TextureCopier):
3186         * platform/graphics/chromium/TextureUploader.h:
3187         (UnthrottledTextureUploader):
3188         (WebCore::UnthrottledTextureUploader::create):
3189         (WebCore::UnthrottledTextureUploader::~UnthrottledTextureUploader):
3190         (WebCore::UnthrottledTextureUploader::UnthrottledTextureUploader):
3191         (WebCore):
3192         * platform/graphics/chromium/cc/CCDirectRenderer.cpp: Added.
3193         (projectionMatrix):
3194         (canvasMatrix):
3195         (WebCore):
3196         (WebCore::CCDirectRenderer::DrawingFrame::initializeMatrices):
3197         (WebCore::CCDirectRenderer::DrawingFrame::initializeScissors):
3198         (WebCore::CCDirectRenderer::decideRenderPassAllocationsForFrame):
3199         (WebCore::CCDirectRenderer::drawFrame):
3200         (WebCore::CCDirectRenderer::drawRenderPass):
3201         (WebCore::CCDirectRenderer::useRenderPass):
3202         (WebCore::CCDirectRenderer::haveCachedResourcesForRenderPassId):
3203         (WebCore::CCDirectRenderer::renderPassTextureSize):
3204         (WebCore::CCDirectRenderer::renderPassTextureFormat):
3205         * platform/graphics/chromium/cc/CCDirectRenderer.h: Added.
3206         (WebCore):
3207         (CCDirectRenderer):
3208         (WebCore::CCDirectRenderer::~CCDirectRenderer):
3209         (WebCore::CCDirectRenderer::resourceProvider):
3210         (WebCore::CCDirectRenderer::CCDirectRenderer):
3211         (DrawingFrame):
3212         (WebCore::CCDirectRenderer::DrawingFrame::DrawingFrame):
3213         (CachedTexture):
3214         (WebCore::CCDirectRenderer::CachedTexture::create):
3215         (WebCore::CCDirectRenderer::CachedTexture::~CachedTexture):
3216         (WebCore::CCDirectRenderer::CachedTexture::isComplete):
3217         (WebCore::CCDirectRenderer::CachedTexture::setIsComplete):
3218         (WebCore::CCDirectRenderer::CachedTexture::CachedTexture):
3219         (WebCore::CCDirectRenderer::quadVertexRect):
3220         (WebCore::CCDirectRenderer::quadRectTransform):
3221
3222 2012-08-20  Julien Chaffraix  <jchaffraix@webkit.org>
3223
3224         Introduce a will-be-removed-from-tree notification in RenderObject
3225         https://bugs.webkit.org/show_bug.cgi?id=94271
3226
3227         Reviewed by Abhishek Arya.
3228
3229         Following bug 93874, we have an insertion notification. This change adds the
3230         matching removal notification (willBeRemovedFromTree).
3231
3232         Refactoring covered by existing tests.
3233
3234         * rendering/RenderObjectChildList.cpp:
3235         (WebCore::RenderObjectChildList::removeChildNode):
3236         Removed the code from here and moved it below.
3237
3238         * rendering/RenderObject.cpp:
3239         (WebCore::RenderObject::willBeRemovedFromTree):
3240         * rendering/RenderObject.h:
3241         This is the base function that should be called by every instance.
3242
3243         * rendering/RenderListItem.cpp:
3244         (WebCore::RenderListItem::willBeRemovedFromTree):
3245         * rendering/RenderListItem.h:
3246         * rendering/RenderQuote.cpp:
3247         (WebCore::RenderQuote::willBeRemovedFromTree):
3248         * rendering/RenderQuote.h:
3249         * rendering/RenderRegion.cpp:
3250         (WebCore::RenderRegion::willBeRemovedFromTree):
3251         * rendering/RenderRegion.h:
3252         Overriden functions.
3253
3254 2012-08-20  Mike West  <mkwst@chromium.org>
3255
3256         CSP 1.1: The 'plugin-types' warning should include details about explicit type declaration when relevant.
3257         https://bugs.webkit.org/show_bug.cgi?id=94432
3258
3259         Reviewed by Adam Barth.
3260
3261         Given a 'plugin-types' Content Security Policy directive, an 'object' or
3262         'embed' tag is blocked if it doesn't include an explicit declaration of
3263         the plugin's expected media type. This restriction should be made clear
3264         in the console warning that's generated.
3265
3266         Existing tests have been adjusted to agree with the new error string.
3267
3268         * page/ContentSecurityPolicy.cpp:
3269         (WebCore::CSPDirectiveList::checkMediaTypeAndReportViolation):
3270             If a media type fail to match the policy's restrictions, and the
3271             declared type attribute is empty, then add another line to the
3272             console warning, espousing the virtues of explicit declaration.
3273
3274 2012-08-20  Dana Jansens  <danakj@chromium.org>
3275
3276         [chromium] Update HUD resources as a final step to drawing a frame
3277         https://bugs.webkit.org/show_bug.cgi?id=93743
3278
3279         Reviewed by Adrienne Walker.
3280
3281         The HUD should be painted as a last step, after the whole frame has been
3282         generated. This introduces a new "updateHudTexture" method on the HUD layer
3283         and has the HUD layer save itself on CCLayerTreeHostImpl so that it can
3284         call back to this method.
3285
3286         This allows the CCLayerTreeHostImpl to cause the HUD layer to update its
3287         texture as a final step before drawing the frame, allowing the HUD texture
3288         to contain all possible information about the current frame.
3289
3290         * platform/graphics/chromium/cc/CCHeadsUpDisplayLayerImpl.cpp:
3291         (WebCore::CCHeadsUpDisplayLayerImpl::willDraw):
3292         (WebCore):
3293         (WebCore::CCHeadsUpDisplayLayerImpl::appendQuads):
3294         (WebCore::CCHeadsUpDisplayLayerImpl::updateHudTexture):
3295         * platform/graphics/chromium/cc/CCHeadsUpDisplayLayerImpl.h:
3296         (CCHeadsUpDisplayLayerImpl):
3297         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
3298         (WebCore::CCLayerTreeHost::finishCommitOnImplThread):
3299         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
3300         (WebCore::CCLayerTreeHostImpl::CCLayerTreeHostImpl):
3301         (WebCore::CCLayerTreeHostImpl::drawLayers):
3302         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
3303         (WebCore):
3304         (WebCore::CCLayerTreeHostImpl::setHudLayer):
3305         (WebCore::CCLayerTreeHostImpl::hudLayer):
3306         (CCLayerTreeHostImpl):
3307
3308 2012-08-20  Ian Vollick  <vollick@chromium.org>
3309
3310         [chromium] Add tracing for active composited animations
3311         https://bugs.webkit.org/show_bug.cgi?id=84210
3312
3313         Reviewed by James Robinson.
3314
3315         This patch issues the trace events from the animations. Animations will
3316         report when they start and finish on the main and impl threads (via
3317         TRACE_EVENT_ASYNC*), and also issues instant trace events whenever they
3318         change state.
3319
3320         No new tests, only changes tracing behavior.
3321
3322         * platform/graphics/chromium/cc/CCActiveAnimation.cpp:
3323         (WebCore::CCActiveAnimation::CCActiveAnimation):
3324         (WebCore::CCActiveAnimation::~CCActiveAnimation):
3325         (WebCore::CCActiveAnimation::setRunState):
3326         (WebCore::CCActiveAnimation::clone):
3327         (WebCore):
3328         (WebCore::CCActiveAnimation::cloneAndInitialize):
3329         * platform/graphics/chromium/cc/CCActiveAnimation.h:
3330         (WebCore::CCActiveAnimation::isControllingInstance):
3331         (CCActiveAnimation):
3332         * platform/graphics/chromium/cc/CCLayerAnimationController.cpp:
3333         (WebCore::CCLayerAnimationController::pushNewAnimationsToImplThread):
3334         (WebCore::CCLayerAnimationController::replaceImplThreadAnimations):
3335         (WebCore::CCLayerAnimationController::tickAnimations):
3336
3337 2012-08-20  Bill Budge  <bbudge@chromium.org>
3338
3339         webkitfullscreenchange not fired properly in iframe.
3340         https://bugs.webkit.org/show_bug.cgi?id=93525
3341
3342         Reviewed by Adam Barth.
3343
3344         webkitCancelFullScreen exits fullscreen by invoking webkitExitFullScreen on topDocument.
3345         However, if webkitDidExitFullScreenForElement is invoked on a descendant document, no events
3346         get dispatched. This change starts the event dispatch delay timer on the document where
3347         webkitCancelFullScreen was called, so that the events get dispatched. In addition, when events
3348         are dispatched, the check whether a node has been removed is changed to also check that the
3349         node isn't in another document, as can happen with frames. Finally, webkitExitFullscreen
3350         is fixed to remove unnecessary code and conform to the spec.
3351
3352         No new tests (the existing fullscreen/exit-full-screen-iframe.html test now passes).
3353
3354         * dom/Document.cpp:
3355         (WebCore::Document::webkitExitFullscreen):
3356         (WebCore::Document::webkitDidExitFullScreenForElement):
3357         (WebCore::Document::fullScreenChangeDelayTimerFired):
3358
3359 2012-08-20  Yuzhu Shen  <yzshen@chromium.com>
3360
3361         [chromium] pepper plugins sometimes are shifted by 1 pixel
3362         https://bugs.webkit.org/show_bug.cgi?id=94257
3363
3364         Reviewed by Levi Weintraub.
3365
3366         Change RenderWidget::updateWidgetGeometry() to use LayoutRect instead of IntRect to avoid unwanted truncation
3367         (when converting from FloatRect to IntRect).
3368
3369         This makes sure that the optimized rendering code path of Pepper plugin
3370         (PluginInstance::GetBitmapForOptimizedPluginPaint) has consistent coordinates with the normal WebKit rendering
3371         code path.
3372
3373         No new tests because we don't have Pepper plugin tests in WebKit.
3374
3375         * rendering/RenderWidget.cpp:
3376         (WebCore::RenderWidget::updateWidgetGeometry):
3377
3378 2012-08-20  Christophe Dumez  <christophe.dumez@intel.com>
3379
3380         postMessage() in MessagePort.idl does not match spec
3381         https://bugs.webkit.org/show_bug.cgi?id=94477
3382
3383         Reviewed by Kentaro Hara.
3384
3385         Update definition of postMessage() in MessagePort.idl
3386         to match the specification at:
3387         http://www.w3.org/TR/html5/comms.html#messageport
3388
3389         The first argument should be of type 'any', not
3390         'DOMString'.
3391
3392         No new tests, no behavior change.
3393
3394         * dom/MessagePort.idl:
3395
3396 2012-08-20  Sheriff Bot  <webkit.review.bot@gmail.com>
3397
3398         Unreviewed, rolling out r125989.
3399         http://trac.webkit.org/changeset/125989
3400         https://bugs.webkit.org/show_bug.cgi?id=94485
3401
3402         "Two of the new tests always failed on Mac bots" (Requested by
3403         bradee-oh on #webkit).
3404
3405         * css/CSSComputedStyleDeclaration.cpp:
3406         (WebCore):
3407         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3408         * css/CSSParser.cpp:
3409         (WebCore::isValidKeywordPropertyAndValue):
3410         (WebCore::isKeywordPropertyID):
3411         (WebCore::CSSParser::parseValue):
3412         * css/CSSProperty.cpp:
3413         (WebCore::CSSProperty::isInheritedProperty):
3414         * css/CSSPropertyNames.in:
3415         * css/CSSValueKeywords.in:
3416         * css/StyleBuilder.cpp:
3417         (WebCore::StyleBuilder::StyleBuilder):
3418         * rendering/RenderLayer.h:
3419         (RenderLayer):
3420         * rendering/RenderLayerBacking.cpp:
3421         (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer):
3422         (WebCore):
3423         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
3424         * rendering/RenderLayerBacking.h:
3425         (RenderLayerBacking):
3426         * rendering/style/RenderStyle.cpp:
3427         (WebCore::RenderStyle::diff):
3428         * rendering/style/RenderStyle.h:
3429         * rendering/style/StyleRareNonInheritedData.cpp:
3430         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
3431         (WebCore::StyleRareNonInheritedData::operator==):
3432         * rendering/style/StyleRareNonInheritedData.h:
3433         (StyleRareNonInheritedData):
3434
3435 2012-08-20  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
3436
3437         [Qt] Custom tap-highlight-color renders fully opaque
3438         https://bugs.webkit.org/show_bug.cgi?id=94468
3439
3440         Reviewed by Kenneth Rohde Christiansen.
3441
3442         Adjust the default tap-highlight-color to figure in that is will be
3443         drawn semi-transparent.
3444
3445         * rendering/RenderTheme.h:
3446         (RenderTheme):
3447
3448 2012-08-20  Andrey Adaikin  <aandrey@chromium.org>
3449
3450         Web Inspector: [WebGL] Add minimum transport protocol from backend to frontend
3451         https://bugs.webkit.org/show_bug.cgi?id=88973
3452
3453         Reviewed by Pavel Feldman.
3454
3455         Added the following protocol methods to communicate with the WebGL injected
3456         module: captureFrame, getTraceLog, dropTraceLog, replayTraceLog.
3457
3458         * inspector/CodeGeneratorInspector.py:
3459         * inspector/InjectedScriptWebGLModule.cpp:
3460         (WebCore::InjectedScriptWebGLModule::captureFrame):
3461         (WebCore):
3462         (WebCore::InjectedScriptWebGLModule::dropTraceLog):
3463         (WebCore::InjectedScriptWebGLModule::getTraceLog):
3464         (WebCore::InjectedScriptWebGLModule::replayTraceLog):
3465         * inspector/InjectedScriptWebGLModule.h:
3466         (InjectedScriptWebGLModule):
3467         * inspector/Inspector.json:
3468         * inspector/InspectorController.cpp:
3469         (WebCore::InspectorController::InspectorController):
3470         * inspector/InspectorWebGLAgent.cpp:
3471         (WebCore::InspectorWebGLAgent::InspectorWebGLAgent):
3472         (WebCore::InspectorWebGLAgent::dropTraceLog):
3473         (WebCore):
3474         (WebCore::InspectorWebGLAgent::captureFrame):
3475         (WebCore::InspectorWebGLAgent::getTraceLog):
3476         (WebCore::InspectorWebGLAgent::replayTraceLog):
3477         * inspector/InspectorWebGLAgent.h:
3478         (WebCore):
3479         (WebCore::InspectorWebGLAgent::create):
3480         (InspectorWebGLAgent):
3481
3482 2012-08-20  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
3483
3484         [TouchAdjustment] Adjust to word or selection
3485         https://bugs.webkit.org/show_bug.cgi?id=94449
3486
3487         Reviewed by Antonio Gomes.
3488
3489         Makes each separate word a separate subtarget when context menu triggers
3490         selections, and only the selected part of a partial selected node a 
3491         target when selections are not overridden.
3492
3493         Test: touchadjustment/context-menu-text-subtargets.html
3494
3495         * page/TouchAdjustment.cpp:
3496         (TouchAdjustment):
3497         (WebCore::TouchAdjustment::providesContextMenuItems):
3498         (WebCore::TouchAdjustment::appendQuadsToSubtargetList):
3499         (WebCore::TouchAdjustment::appendBasicSubtargetsForNode):
3500         (WebCore::TouchAdjustment::appendContextSubtargetsForNode):
3501         (WebCore::TouchAdjustment::compileSubtargetList):
3502         (WebCore::findBestClickableCandidate):
3503         (WebCore::findBestContextMenuCandidate):
3504
3505 2012-08-20  Xan Lopez  <xlopez@igalia.com>
3506
3507         [GTK] Provide backwards compatible method for WebKitDOMWebKitNamedFlow::overflow
3508         https://bugs.webkit.org/show_bug.cgi?id=94464
3509
3510         Reviewed by Carlos Garcia Campos.
3511
3512         Provide a compatibility method to access the new 'overset'
3513         property through the old 'overflow' name in
3514         WebKitDOMWebKitNamedFlow. Note that trying to access it through
3515         g_object_get directly will give a runtime warning, since the
3516         property does not actually exist anymore; this is done purely to
3517         maintain API compatibility.
3518
3519         * bindings/gobject/WebKitDOMCustom.cpp:
3520         (webkit_dom_webkit_named_flow_get_overflow): add method.
3521         * bindings/gobject/WebKitDOMCustom.h:
3522
3523 2012-08-20  Sami Kyostila  <skyostil@chromium.org>
3524
3525         [chromium] Convert screen space scroll gestures to layer space
3526         https://bugs.webkit.org/show_bug.cgi?id=92499
3527
3528         Reviewed by James Robinson.
3529
3530         Scroll gestures should be converted from screen space to local layer space to
3531         correctly apply the scroll delta to page scaled and/or transformed layers.
3532         Visually this means that the scrolled content will always follow the user's
3533         finger for any "well-formed" layer transform.
3534
3535         Wheel scroll deltas will still be directly interpreted as local layer scroll
3536         coordinates.
3537
3538         We also adjust the logic for propagating ("bubbling") scroll events to parent
3539         layers. Previously a parent layer was allowed to scroll in the screen-space
3540         axis orthogonal to the direction the starting layer scrolled toward. For
3541         example if a vertically scrolling layer is scrolled diagonally down and right,
3542         the layer moves down and its parent to the right.
3543
3544         This patch generalizes this behavior to non-axis aligned transformed layers so
3545         that the scrolling direction of any parent is constrained to be perpendicular
3546         direction of movement of the starting layer. This makes the scrolling behavior
3547         of transformed layers physically plausible. For instance, assume a 45 degree
3548         rotated, vertically scrollable layer. Dragging your finger vertically
3549         (relative to the layer) scrolls the layer up and down, while horizontal
3550         movement results in the parent of the layer moving in a corresponding way.
3551
3552         Since generally users want to scroll a single layer in one direction, this
3553         patch also introduces a rule that if the resulting movement of a layer is
3554         within 45 degrees of the original scroll input, the bubbling process is
3555         stopped. This makes it possible to reliably scroll a single layer without
3556         affecting any of its parents.
3557
3558         Added new unit tests:
3559             CCLayerTreeHostImplTest.scrollAxisAlignedRotatedLayer
3560             CCLayerTreeHostImplTest.scrollNonAxisAlignedRotatedLayer
3561             CCLayerTreeHostImplTest.scrollScaledLayer
3562             CCMathUtilTest.smallestAngleBetweenVectors
3563             CCMathUtilTest.vectorProjection
3564
3565         * platform/graphics/chromium/cc/CCInputHandler.h:
3566         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
3567         (WebCore::CCLayerTreeHostImpl::CCLayerTreeHostImpl):
3568         (WebCore::CCLayerTreeHostImpl::scrollBegin):
3569         (WebCore::scrollLayerWithScreenSpaceDelta):
3570         (WebCore):
3571         (WebCore::scrollLayerWithLocalDelta):
3572         (WebCore::CCLayerTreeHostImpl::scrollBy):
3573         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
3574         (CCLayerTreeHostImpl):
3575         * platform/graphics/chromium/cc/CCMathUtil.cpp:
3576         (WebCore::CCMathUtil::smallestAngleBetweenVectors):
3577         (WebCore):
3578         (WebCore::CCMathUtil::projectVector):
3579         * platform/graphics/chromium/cc/CCMathUtil.h:
3580         (CCMathUtil):
3581
3582 2012-08-20  Carlos Garcia Campos  <cgarcia@igalia.com>
3583
3584         [GTK] Add API to set preferred languages to WebKit2 GTK+
3585         https://bugs.webkit.org/show_bug.cgi?id=90878
3586
3587         Unreviewed. Fix mac build.
3588
3589         * WebCore.exp.in: Export WebCore::languageDidChange().
3590
3591 2012-08-20  Pavel Feldman  <pfeldman@chromium.org>
3592
3593         Web Inspector: improve standalone test harness to allow attaching to inspector before test.
3594         https://bugs.webkit.org/show_bug.cgi?id=94426
3595
3596         Reviewed by Vsevolod Vlasov.
3597
3598         - User can not "Debug", attach inspector to the front-end and "Continue" test execution.
3599         - You can also assign filter from the query parameter.
3600
3601         * inspector/front-end/test-runner.html:
3602
3603 2012-08-20  Pavel Feldman  <pfeldman@chromium.org>
3604
3605         Web Inspector: load scripts panel lazily
3606         https://bugs.webkit.org/show_bug.cgi?id=94416
3607
3608         Reviewed by Vsevolod Vlasov.
3609
3610         - removes access to WebInspector.panels.scripts and loads it lazily.
3611         - extracts classes to their own files when classes residing in one file belong to different modules
3612         - removes StylesPanel.js in favor of the actual classes it contains 
3613
3614         * WebCore.gypi:
3615         * WebCore.vcproj/WebCore.vcproj:
3616         * WebCore.xcodeproj/project.pbxproj:
3617         * inspector/compile-front-end.py:
3618         * inspector/front-end/AdvancedSearchController.js:
3619         (WebInspector.AdvancedSearchController.prototype.handleShortcut):
3620         * inspector/front-end/BreakpointsSidebarPane.js:
3621         * inspector/front-end/FilteredItemSelectionDialog.js:
3622         * inspector/front-end/InspectorFrontendAPI.js:
3623         (InspectorFrontendAPI._pendingCommands.isDebuggingEnabled):
3624         (InspectorFrontendAPI.setDebuggingEnabled):
3625         * inspector/front-end/NativeBreakpointsSidebarPane.js: Added.
3626         (WebInspector.NativeBreakpointsSidebarPane):
3627         (WebInspector.NativeBreakpointsSidebarPane.prototype._addListElement):
3628         (WebInspector.NativeBreakpointsSidebarPane.prototype._removeListElement):
3629         (WebInspector.NativeBreakpointsSidebarPane.prototype._reset):
3630         * inspector/front-end/ObjectPropertiesSection.js:
3631         (WebInspector.ObjectPropertyTreeElement.prototype._functionContextMenuEventFired):
3632         * inspector/front-end/ScriptSnippetModel.js:
3633         * inspector/front-end/ScriptsPanel.js:
3634         (WebInspector.ScriptsPanel.prototype.showGoToSourceDialog):
3635         * inspector/front-end/SnippetJavaScriptSourceFrame.js: Added.
3636         (WebInspector.SnippetJavaScriptSourceFrame):
3637         (WebInspector.SnippetJavaScriptSourceFrame.prototype.statusBarItems):
3638         (WebInspector.SnippetJavaScriptSourceFrame.prototype._runButtonClicked):
3639         * inspector/front-end/StyleSheetOutlineDialog.js: Added.
3640         (WebInspector.StyleSheetOutlineDialog):
3641         (WebInspector.StyleSheetOutlineDialog.show):
3642         (WebInspector.StyleSheetOutlineDialog.prototype.itemTitleAt):
3643         (WebInspector.StyleSheetOutlineDialog.prototype.itemSubtitleAt):
3644         (WebInspector.StyleSheetOutlineDialog.prototype.itemKeyAt):
3645         (WebInspector.StyleSheetOutlineDialog.prototype.itemsCount):
3646         (WebInspector.StyleSheetOutlineDialog.prototype.requestItems):
3647         (WebInspector.StyleSheetOutlineDialog.prototype.requestItems.didGetStyleSheet):
3648         (WebInspector.StyleSheetOutlineDialog.prototype.selectItem):
3649         (WebInspector.StyleSheetOutlineDialog.prototype.rewriteQuery):
3650         * inspector/front-end/StyleSource.js: Renamed from Source/WebCore/inspector/front-end/StylesPanel.js.
3651         (WebInspector.StylesUISourceCodeProvider):
3652         (WebInspector.StylesUISourceCodeProvider.prototype.uiSourceCodes):
3653         (WebInspector.StylesUISourceCodeProvider.prototype.rawLocationToUILocation):
3654         (WebInspector.StylesUISourceCodeProvider.prototype.uiLocationToRawLocation):
3655         (WebInspector.StylesUISourceCodeProvider.prototype._populate):
3656         (WebInspector.StylesUISourceCodeProvider.prototype._resourceAdded):
3657         (WebInspector.StylesUISourceCodeProvider.prototype.reset):
3658         (WebInspector.StyleSource):
3659         (WebInspector.StyleSource.prototype.isEditable):
3660         (WebInspector.StyleSource.prototype.workingCopyCommitted):
3661         (WebInspector.StyleSource.prototype.workingCopyChanged):
3662         (WebInspector.StyleSource.prototype._callOrSetTimeout):
3663         (WebInspector.StyleSource.prototype._commitIncrementalEdit):
3664         (WebInspector.StyleSource.prototype._clearIncrementalUpdateTimer):
3665         (WebInspector.InspectorStyleSource):
3666         * inspector/front-end/WebKit.qrc:
3667         * inspector/front-end/inspector.html:
3668         * inspector/front-end/inspector.js:
3669         (WebInspector._panelDescriptors):
3670         (WebInspector._registerShortcuts):
3671         (WebInspector.documentKeyDown):
3672         (WebInspector._showAnchorLocation):
3673
3674 2012-08-20  Dominik Röttsches  <dominik.rottsches@intel.com>
3675
3676         [EFL] Get rid of pango backend support once harfbuzz-ng is working
3677         https://bugs.webkit.org/show_bug.cgi?id=92102
3678
3679         Reviewed by Kenneth Rohde Christiansen.
3680
3681         Removing support for Pango complex font rendering now that we HarfBuzz.
3682
3683         No new tests, no change in behavior.
3684
3685         * PlatformEfl.cmake: Removing Pango specific includes and libraries.
3686
3687 2012-08-20  Pavel Feldman  <pfeldman@chromium.org>
3688
3689         Web Inspector: prepare scripts panel to be lazily loaded
3690         https://bugs.webkit.org/show_bug.cgi?id=94423
3691
3692         Reviewed by Vsevolod Vlasov.
3693
3694         - makes scripts panel read workspace data upon creation
3695         - moves pause on script state management into the debugger model
3696         - updates frontend API to use debugger model, not scripts panel
3697
3698         * inspector/front-end/DebuggerModel.js:
3699         (WebInspector.DebuggerModel.prototype.debuggerEnabled):
3700         (WebInspector.DebuggerModel.prototype.disableDebugger):
3701         (WebInspector.DebuggerModel.prototype._debuggerWasEnabled):
3702         (WebInspector.DebuggerModel.prototype._pauseOnExceptionStateChanged):
3703         (WebInspector.DebuggerModel.prototype.get _debuggerWasDisabled):
3704         * inspector/front-end/InspectorFrontendAPI.js:
3705         (InspectorFrontendAPI._pendingCommands.isDebuggingEnabled):
3706         (InspectorFrontendAPI.setDebuggingEnabled):
3707         * inspector/front-end/ScriptsPanel.js:
3708         (WebInspector.ScriptsPanel):
3709         (WebInspector.ScriptsPanel.prototype._debuggerWasEnabled):
3710         (WebInspector.ScriptsPanel.prototype._debuggerWasDisabled):
3711         (WebInspector.ScriptsPanel.prototype._reset):
3712         (WebInspector.ScriptsPanel.prototype.canShowAnchorLocation):
3713         (WebInspector.ScriptsPanel.prototype._updateDebuggerButtons):
3714         (WebInspector.ScriptsPanel.prototype._enableDebugging):
3715         (WebInspector.ScriptsPanel.prototype._togglePauseOnExceptions):
3716         (WebInspector.ScriptsPanel.prototype.showGoToSourceDialog):
3717         * inspector/front-end/inspector.js:
3718         (WebInspector.documentKeyDown):
3719
3720 2012-08-20  Robin Cao  <robin.cao@torchmobile.com.cn>
3721
3722         [BlackBerry] Adapt to changes in the platform media player API
3723         https://bugs.webkit.org/show_bug.cgi?id=94329
3724         PR #194237
3725
3726         Reviewed by Antonio Gomes.
3727
3728         The interface to platform's media player has changed from MMRPlayer
3729         to PlatformPlayer. This patch adapts to this change.
3730
3731         And we also decided to postpone the creation of PlatformPlayer until
3732         the loading started. This is needed because we may create different
3733         types of player for different media sources.
3734
3735         This is a refactor, no new tests.
3736
3737         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
3738         (WebCore::MediaPlayerPrivate::getSupportedTypes):
3739         (WebCore::MediaPlayerPrivate::supportsType):
3740         (WebCore::MediaPlayerPrivate::notifyAppActivatedEvent):
3741         (WebCore::MediaPlayerPrivate::setCertificatePath):
3742         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
3743         (WebCore::MediaPlayerPrivate::load):
3744         (WebCore::MediaPlayerPrivate::cancelLoad):
3745         (WebCore::MediaPlayerPrivate::prepareToPlay):
3746         (WebCore::MediaPlayerPrivate::play):
3747         (WebCore::MediaPlayerPrivate::pause):
3748         (WebCore::MediaPlayerPrivate::naturalSize):
3749         (WebCore::MediaPlayerPrivate::hasVideo):
3750         (WebCore::MediaPlayerPrivate::hasAudio):
3751         (WebCore::MediaPlayerPrivate::duration):
3752         (WebCore::MediaPlayerPrivate::currentTime):
3753         (WebCore::MediaPlayerPrivate::seek):
3754         (WebCore::MediaPlayerPrivate::setRate):
3755         (WebCore::MediaPlayerPrivate::paused):
3756         (WebCore::MediaPlayerPrivate::setVolume):
3757         (WebCore::MediaPlayerPrivate::maxTimeSeekable):
3758         (WebCore::MediaPlayerPrivate::buffered):
3759         (WebCore::MediaPlayerPrivate::paint):
3760         (WebCore::MediaPlayerPrivate::hasAvailableVideoFrame):
3761         (WebCore::MediaPlayerPrivate::movieLoadType):
3762         (WebCore::MediaPlayerPrivate::setAllowPPSVolumeUpdates):
3763         (WebCore::MediaPlayerPrivate::updateStates):
3764         (WebCore):
3765         (WebCore::MediaPlayerPrivate::onStateChanged):
3766         (WebCore::MediaPlayerPrivate::onMediaStatusChanged):
3767         (WebCore::MediaPlayerPrivate::onError):
3768         (WebCore::MediaPlayerPrivate::waitMetadataTimerFired):
3769         (WebCore::MediaPlayerPrivate::showErrorDialog):
3770         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.h:
3771         (MediaPlayerPrivate):
3772
3773 2012-08-19  Kentaro Hara  <haraken@chromium.org>
3774
3775         [V8] Move contextDebugId() and setContextDebugId() from V8Proxy to ScriptController
3776         https://bugs.webkit.org/show_bug.cgi?id=94446
3777
3778         Reviewed by Adam Barth.
3779
3780         To kill V8Proxy, we can move contextDebugId() and setContextDebugId()
3781         from V8Proxy to ScriptController.
3782
3783         No tests. No change in behavior.
3784
3785         * bindings/v8/ScriptController.cpp:
3786         (WebCore::ScriptController::setContextDebugId):
3787         (WebCore):
3788         (WebCore::ScriptController::contextDebugId):
3789         * bindings/v8/ScriptController.h:
3790         (ScriptController):
3791         * bindings/v8/V8IsolatedContext.cpp:
3792         (WebCore::V8IsolatedContext::V8IsolatedContext):
3793         * bindings/v8/V8Proxy.cpp:
3794         * bindings/v8/V8Proxy.h:
3795         (V8Proxy):
3796
3797 2012-08-20  Kentaro Hara  <haraken@chromium.org>
3798
3799         [V8] Move V8Proxy::newInstance() to V8ObjectConstructor
3800         https://bugs.webkit.org/show_bug.cgi?id=94443
3801
3802         Reviewed by Adam Barth.
3803
3804         To kill V8Proxy, this patch moves V8Proxy::newInstance() to
3805         V8ObjectConstructor::newInstanceInFrame().
3806         In addition, this patch does the following things:
3807
3808         - For consistency with V8ObjectConstructor::newInstanceInFrame(),
3809         this patch inserts an if(v8::V8::IsDead()) check to just after
3810         Function::NewInstance(). The check is done by V8Binding::assertIfV8IsDead().
3811
3812         - To avoid #include circular dependency, this patch de-inline
3813         V8ObjectConstructor::newInstance()s. I didn't observe any perf regression.
3814         I don't think these methods are worth being inlined, because
3815         these methods call Function::NewInstance(), which is not inlined
3816         and calls a bunch of heavy mehtods in V8.
3817
3818         No tests. No change in behavior.
3819
3820         * bindings/v8/NPV8Object.cpp:
3821         (_NPN_Construct):
3822         * bindings/v8/V8Binding.cpp:
3823         (WebCore::assertIfV8IsDead):
3824         (WebCore):
3825         * bindings/v8/V8Binding.h:
3826         (WebCore):
3827         * bindings/v8/V8ObjectConstructor.cpp:
3828         (WebCore::V8ObjectConstructor::newInstance):
3829         (WebCore):
3830         (WebCore::V8ObjectConstructor::newInstanceInFrame):
3831         * bindings/v8/V8ObjectConstructor.h:
3832         (WebCore):
3833         (V8ObjectConstructor):
3834         * bindings/v8/V8Proxy.cpp:
3835         (WebCore::V8Proxy::runScript):
3836         (WebCore::V8Proxy::instrumentedCallFunction):
3837
3838 2012-08-20  Kentaro Hara  <haraken@chromium.org>
3839
3840         [V8] Move V8Proxy::m_extensions to ScriptController
3841         https://bugs.webkit.org/show_bug.cgi?id=94444
3842
3843         Reviewed by Adam Barth.
3844
3845         To kill V8Proxy, this patch moves V8Proxy::m_extensions to ScriptController.
3846         This patch also renames extensions() to registeredExtensions() for clarification.
3847
3848         No tests. No change in behavior.
3849
3850         * bindings/v8/ScriptController.cpp:
3851         (WebCore::ScriptController::registeredExtensions):
3852         (WebCore):
3853         (WebCore::ScriptController::registerExtensionIfNeeded):
3854         * bindings/v8/ScriptController.h:
3855         (WebCore):
3856         (ScriptController):
3857         * bindings/v8/V8DOMWindowShell.cpp:
3858         (WebCore::V8DOMWindowShell::createNewContext):
3859         * bindings/v8/V8Proxy.cpp:
3860         * bindings/v8/V8Proxy.h:
3861         (WebCore):
3862         (V8Proxy):
3863
3864 2012-08-20  Pavel Feldman  <pfeldman@chromium.org>
3865
3866         Web Inspector: toolbar causes 8 reflows upon opening
3867         https://bugs.webkit.org/show_bug.cgi?id=94422
3868
3869         Reviewed by Yury Semikhatsky.
3870
3871         Toolbar's overflow code causes inspector to do 8 reflows upon opening.
3872         Fixing it via introducing batch toolbar update.
3873
3874         * inspector/front-end/Toolbar.js:
3875         (WebInspector.Toolbar):
3876         (WebInspector.Toolbar.prototype.setCoalescingUpdate):
3877         (WebInspector.Toolbar.prototype._updateDropdownButtonAndHideDropdown):
3878         * inspector/front-end/inspector.css:
3879         (body.compact .toolbar-icon):
3880         (body.compact .toolbar-icon.custom-toolbar-icon):
3881         (body.compact .toolbar-item:active .toolbar-icon):
3882         (body.compact .toolbar-label):
3883         (body.compact .toolbar-item.resources .toolbar-icon):
3884         (body.compact .toolbar-item.network .toolbar-icon):
3885         (body.compact .toolbar-item.scripts .toolbar-icon):
3886         (body.compact .toolbar-item.timeline .toolbar-icon):
3887         (body.compact .toolbar-item.profiles .toolbar-icon):
3888         (body.compact .toolbar-item.audits .toolbar-icon):
3889         (body.compact .toolbar-item.console .toolbar-icon):
3890         * inspector/front-end/inspector.js:
3891         (WebInspector.get _setCompactMode):
3892         (WebInspector.windowResize):
3893
3894 2012-08-19  Kentaro Hara  <haraken@chromium.org>
3895
3896         [V8] Replace proxy()->windowShell() in ScriptController with windowShell()
3897         https://bugs.webkit.org/show_bug.cgi?id=94445
3898
3899         Reviewed by Adam Barth.
3900
3901         Now ScriptController owns windowShell. So ScriptController doesn't
3902         need to get windowShell through V8Proxy.
3903
3904         No tests. No change in behavior.
3905
3906         * bindings/v8/ScriptController.cpp:
3907         (WebCore::ScriptController::updateSecurityOrigin):
3908         (WebCore::ScriptController::haveInterpreter):
3909         (WebCore::ScriptController::enableEval):
3910         (WebCore::ScriptController::disableEval):
3911         (WebCore::ScriptController::updateDocument):
3912         (WebCore::ScriptController::namedItemAdded):
3913         (WebCore::ScriptController::namedItemRemoved):
3914
3915 2012-08-19  Kentaro Hara  <haraken@chromium.org>
3916
3917         [V8] Move V8Proxy::callFunction() to ScriptController
3918         https://bugs.webkit.org/show_bug.cgi?id=94437
3919
3920         Reviewed by Adam Barth.
3921
3922         To kill V8Proxy, this patch moves callFunction() from V8Proxy to ScriptController.
3923
3924         No tests. No change in behavior.
3925
3926         * bindings/v8/DOMTransaction.cpp:
3927         (WebCore::DOMTransaction::callFunction):
3928         * bindings/v8/NPV8Object.cpp:
3929         (_NPN_Invoke):
3930         (_NPN_InvokeDefault):
3931         * bindings/v8/ScheduledAction.cpp:
3932         (WebCore::ScheduledAction::execute):
3933         * bindings/v8/ScheduledAction.h:
3934         (WebCore):
3935         (ScheduledAction):
3936         * bindings/v8/ScriptController.cpp:
3937         (WebCore::ScriptController::callFunction):
3938         (WebCore):
3939         (WebCore::ScriptController::callFunctionEvenIfScriptDisabled):
3940         * bindings/v8/ScriptController.h:
3941         (ScriptController):
3942         * bindings/v8/V8EventListener.cpp:
3943         (WebCore::V8EventListener::callListenerFunction):
3944         * bindings/v8/V8LazyEventListener.cpp:
3945         (WebCore::V8LazyEventListener::callListenerFunction):
3946         * bindings/v8/V8Proxy.cpp:
3947         * bindings/v8/V8Proxy.h:
3948         (V8Proxy):
3949         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
3950         (WebCore::V8HTMLDocument::openCallback):
3951
3952 2012-08-19  Yoshifumi Inoue  <yosin@chromium.org>
3953
3954         [Forms] Set SpinButtonElement free from HTMLInputElement
3955         https://bugs.webkit.org/show_bug.cgi?id=93941
3956
3957         Reviewed by Kent Tamura.
3958
3959         This patch removes dependency to HTMLInputElement from SpinButtonElement.
3960
3961         Functionalities used to be calling HTMLInputElement functions are
3962         replaced to calling functions SpinButtonOwner class.
3963
3964         * html/TextFieldInputType.cpp:
3965         (WebCore::TextFieldInputType::focusAndSelectSpinButtonOwner): Moved functionality from SpinButtonElement::defaultEventHandler.
3966         (WebCore::TextFieldInputType::shouldSpinButtonRespondToMouseEvents): Moved code from SpinButtonElement::willRespondToMouseClickEvents
3967         (WebCore::TextFieldInputType::shouldSpinButtonRespondToWheelEvents): Moved code from SpinButtonElement::forwardEvent
3968         * html/TextFieldInputType.h:
3969         (TextFieldInputType):
3970         * html/TimeInputType.cpp:
3971         (WebCore::TimeInputType::DateTimeEditControlOwnerImpl::focusAndSelectEditControlOwner): Moved functionality from SpinButtonElement::defaultEventHandler.
3972         (WebCore::TimeInputType::DateTimeEditControlOwnerImpl::isEditControlOwnerFocused): Added for DateTimeEditElement::shouldSpinButtonRespondToWheelEvents.
3973         * html/TimeInputType.h:
3974         * html/shadow/DateTimeEditElement.cpp:
3975         (WebCore::DateTimeEditElement::focusAndSelectSpinButtonOwner): Added for SpinButtonElementOwner class change.
3976         (WebCore::DateTimeEditElement::shouldSpinButtonRespondToMouseEvents): ditto
3977         (WebCore::DateTimeEditElement::shouldSpinButtonRespondToWheelEvents): ditto
3978         * html/shadow/DateTimeEditElement.h:
3979         (EditControlOwner): Added new virtual function declarations for SpinButtonElementOwner class change.
3980         (DateTimeEditElement): Added new function declarations for SpinButtonElementOwner.
3981         * html/shadow/SpinButtonElement.cpp:
3982         (WebCore::SpinButtonElement::defaultEventHandler): Changed to use SpinButtonElementOwner instead of HTMLInputElement.
3983         (WebCore::SpinButtonElement::forwardEvent): ditto
3984         (WebCore::SpinButtonElement::willRespondToMouseMoveEvents): ditto
3985         (WebCore::SpinButtonElement::willRespondToMouseClickEvents): ditto
3986         (WebCore::SpinButtonElement::step): ditto
3987         (WebCore::SpinButtonElement::shouldRespondToMouseEvents): Added helper function for calling SpinButtonOwner instance.
3988         * html/shadow/SpinButtonElement.h:
3989         (SpinButtonOwner): Added new virtual function declarations.
3990         (SpinButtonElement):
3991
3992 2012-08-19  Yoshifumi Inoue  <yosin@chromium.org>
3993
3994         [Tests] time-multiple-fields-appearance-basic.html and time-multiple-fields-appearance-pseudo-elements.html are failed on Chromium Mac
3995         https://bugs.webkit.org/show_bug.cgi?id=94439
3996
3997         Reviewed by Kent Tamura.
3998
3999         This patch disabled CSS selector for Firefox compatibility applied to
4000         multiple fields time input UI, because it is supposed to apply text
4001         field rather than multiple fields.
4002
4003         This patch allows us to have same appearance among Chromium-Linux,
4004         Mac and Win.
4005
4006         No new tests. Following existing tests cover this change:
4007           fast/forms/time-multiple-fields/time-multiple-fields-appearance-basic.html
4008           fast/forms/time-multiple-fields/time-multiple-fields-appearance-disabled-readonly.html
4009           fast/forms/time-multiple-fields/time-multiple-fields-appearance-pseudo-classes.html
4010           fast/forms/time-multiple-fields/time-multiple-fields-appearance-pseudo-elements.html
4011           fast/forms/time-multiple-fields/time-multiple-fields-appearance-style.html
4012
4013         * css/themeWin.css: Exclude input[type="time"] selector if ENABLE_INPUT_TYPE_TIME_MULTIPLE_FIELDS
4014         enabled.
4015
4016 2012-08-19  Kentaro Hara  <haraken@chromium.org>
4017
4018         [V8] Rename SafeAllocation to V8ObjectConstructor
4019         https://bugs.webkit.org/show_bug.cgi?id=94436
4020
4021         Reviewed by Adam Barth.
4022
4023         For clarification.
4024
4025         No tests. No change in behavior.
4026
4027         * UseV8.cmake:
4028         * WebCore.gypi:
4029         * bindings/v8/ScriptFunctionCall.cpp:
4030         (WebCore::ScriptFunctionCall::construct):
4031         * bindings/v8/V8Binding.cpp:
4032         (WebCore::createRawTemplate):
4033         * bindings/v8/V8Binding.h:
4034         * bindings/v8/V8DOMWindowShell.cpp:
4035         (WebCore::V8DOMWindowShell::installDOMWindow):
4036         * bindings/v8/V8DOMWrapper.cpp:
4037         (WebCore::V8DOMWrapper::instantiateV8Object):
4038         * bindings/v8/V8NPObject.cpp:
4039         (WebCore::createV8ObjectForNPObject):
4040         * bindings/v8/V8ObjectConstructor.cpp: Renamed from Source/WebCore/bindings/v8/SafeAllocation.cpp.
4041         (WebCore):
4042         (WebCore::V8ObjectConstructor::isValidConstructorMode):
4043         * bindings/v8/V8ObjectConstructor.h: Renamed from Source/WebCore/bindings/v8/SafeAllocation.h.
4044         (WebCore):
4045         (ConstructorMode):
4046         (WebCore::ConstructorMode::ConstructorMode):
4047         (WebCore::ConstructorMode::~ConstructorMode):
4048         (WebCore::ConstructorMode::current):
4049         (V8ObjectConstructor):
4050         (WebCore::V8ObjectConstructor::newInstance):
4051         * bindings/v8/V8PerContextData.cpp:
4052         (WebCore::V8PerContextData::createWrapperFromCacheSlowCase):
4053         * bindings/v8/WorkerContextExecutionProxy.