Self camera should be lauched during a call.
[framework/web/webkit-efl.git] / Source / WebCore / ChangeLog
1 2012-09-24  Tony Chang  <tony@chromium.org>
2
3         flex-grow should be 1 when omitted from flex shorthand
4         https://bugs.webkit.org/show_bug.cgi?id=97480
5
6         Reviewed by Ojan Vafai.
7
8         We were using 0, based on an outdated version of the spec.
9
10         Tests: css3/flexbox/flex-property-parsing.html
11                css3/flexbox/flex-algorithm.html: New test case.
12
13         * css/CSSParser.cpp:
14         (WebCore::CSSParser::parseFlex):
15
16 2013-02-13  Morten Stenshorne  <mstensho@opera.com>
17
18         WebKit ignores column-rules wider than column-gap
19         https://bugs.webkit.org/show_bug.cgi?id=15553
20
21         Paint column rules even if they are wider than the gap.
22         Rules wider than the gap should just overlap with column contents.
23
24         Reviewed by Eric Seidel.
25
26         Test: fast/multicol/rule-thicker-than-gap.html
27
28         * rendering/RenderBlock.cpp:
29         (WebCore::RenderBlock::paintColumnRules):
30
31 2013-03-18  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
32
33         [EFL] Cancel mark on search field is not displayed
34         https://bugs.webkit.org/show_bug.cgi?id=94880
35
36         Reviewed by Kenneth Rohde Christiansen.
37
38         adjustSearchFieldCancelButtonStyle() doesn't set style width and height for search cancel button.
39         So, the button isn't showing up in search input field. Besides the button size should be scaled based
40         on the font size as chromium, qt, and blackberry ports.
41
42         Tests: fast/forms/search-cancel-button-style-sharing.html
43                fast/forms/search-rtl.html
44         * platform/efl/RenderThemeEfl.cpp:
45         (WebCore):
46         (WebCore::RenderThemeEfl::adjustSearchFieldCancelButtonStyle):
47
48 2012-08-30  Kangil Han  <kangil.han@samsung.com>
49
50         Fix compile warning when enable tiled backing store
51         https://bugs.webkit.org/show_bug.cgi?id=95422
52
53         Reviewed by Kentaro Hara.
54
55         Fixed compile warning messages when enabled tiled backing store.
56         In case of TiledBackingStore, it was first thought about static_cast<unsigned>.
57         However, if minus value is assigned to the comparison, it would be critical.
58         So, it was modified as using int value in tiled coordinate calculation.
59
60         * page/Frame.cpp:
61         (WebCore::Frame::tiledBackingStorePaintEnd): comparison between signed and unsigned integer expressions [-Wsign-compare]
62         * platform/graphics/TiledBackingStore.cpp:
63         (WebCore::TiledBackingStore::invalidate): comparison between signed and unsigned integer expressions [-Wsign-compare]
64         (WebCore::TiledBackingStore::paint): comparison between signed and unsigned integer expressions [-Wsign-compare]
65         (WebCore::TiledBackingStore::coverageRatio): comparison between signed and unsigned integer expressions [-Wsign-compare]
66         (WebCore::TiledBackingStore::createTiles): comparison between signed and unsigned integer expressions [-Wsign-compare]
67         * platform/graphics/cairo/GLContext.cpp:
68         (WebCore::GLContext::createOffscreenContext): no return statement in function returning non-void [-Wreturn-type]
69
70 2012-09-28  Alberto Garcia  <agarcia@igalia.com>
71
72         TextureMapperGL: fix -Wsign-compare compilation warning.
73         https://bugs.webkit.org/show_bug.cgi?id=97928
74
75         Reviewed by Martin Robinson.
76
77         Use size_t rather than int to iterate over FilterOperations.
78
79         * platform/graphics/texmap/TextureMapperGL.cpp:
80         (WebCore::BitmapTextureGL::applyFilters):
81
82 2013-03-11  Kent Tamura  <tkent@chromium.org>
83
84         Inappropriate validation message for required number/date input elements
85         https://bugs.webkit.org/show_bug.cgi?id=111982
86
87         Reviewed by Kentaro Hara.
88
89         For validation message, badInput messages should take precedence
90         over valueMissing messages because users already filled out the
91         field with a bad value.
92
93         Tests: Update fast/forms/validationMessage.html
94
95         * html/InputType.cpp:
96         (WebCore::InputType::validationMessage):
97         Check badInput first.
98
99 2013-03-11  Kent Tamura  <tkent@chromium.org>
100
101         Refactoring: Move the content of HTMLInputElement::subtreeHasChanged to TextFieldInputType
102         https://bugs.webkit.org/show_bug.cgi?id=103195
103
104         Reviewed by Kentaro Hara.
105
106         HTMLInputElement::subtreeHasChanged is called only if the input is
107         a text field. The code should be moved to TextFieldInputType.
108
109         No new tests. This should not change any behavior.
110
111         * html/HTMLInputElement.cpp:
112         - Remove unnecessary NumberInputType.h inclusion.
113         - Remove convertFromVisibleValue. It was used only by subtreeHasChanged.
114         (WebCore::HTMLInputElement::subtreeHasChanged):
115         Move the code to TextFieldInputType::subtreeHasChanged except
116         calculateAndAdjustDirectionality, which is a protected member of
117         HTMLElement.
118         * html/HTMLInputElement.h:
119         (HTMLInputElement): Remove convertFromVisibleValue.
120
121         * html/InputType.cpp:
122         Move convertFromVisibleValue to TextFieldInputType.
123         (WebCore::InputType::subtreeHasChanged):
124         Add ASSERT_NOT_REACHED.
125         * html/InputType.h:
126         (InputType): Remove convertFromVisibleValue.
127
128         * html/TextFieldInputType.cpp:
129         (WebCore::TextFieldInputType::convertFromVisibleValue):
130         Moved from InputType.
131         (WebCore::TextFieldInputType::subtreeHasChanged):
132         Moved from HTMLInputElement. A latter part is moved to
133         didSetValueByUserEdit to be hooked by SearchInputType.
134         (WebCore::TextFieldInputType::didSetValueByUserEdit):
135         Moved from HTMLInputElement::subtreeHasChanged, and clean up the code.
136         * html/TextFieldInputType.h:
137         (TextFieldInputType):
138         - Move convertFromVisibleValue from InputType.
139         - Add didSetValueByUserEdit and subtreeHasChanged.
140
141         * html/SearchInputType.cpp:
142         (WebCore::SearchInputType::didSetValueByUserEdit):
143         Renamed from subtreeHasChanged, and calls TextFieldInputType::didSetValueByUserEdit.
144         * html/SearchInputType.h:
145         (SearchInputType): Rename subtreeHasChanged to didSetValueByUserEdit.
146
147 2012-11-22  Kentaro Hara  <haraken@chromium.org>
148
149         [V8] Move WorkerExecutionContextProxy::initializeIfNeeded() to V8Initializer
150         https://bugs.webkit.org/show_bug.cgi?id=103061
151
152         Reviewed by Adam Barth.
153
154         This is an incremental step to remove WorkerExecutionContextProxy.
155         This patch moves WorkerExecutionContextProxy::initializeIfNeeded() to V8Initializer.
156         This patch also renames methods so that the names become consistent
157         between the main thread and workers.
158
159         No tests. No change in behavior.
160
161         * bindings/v8/V8Initializer.cpp:
162         (WebCore::reportFatalErrorInMainThread):
163         (WebCore::messageHandlerInMainThread):
164         (WebCore::failedAccessCheckCallbackInMainThread):
165         (WebCore::V8Initializer::initializeMainThreadIfNeeded):
166         (WebCore::reportFatalErrorInWorker):
167         (WebCore):
168         (WebCore::messageHandlerInWorker):
169         (WebCore::V8Initializer::initializeWorkerIfNeeded):
170         * bindings/v8/V8Initializer.h:
171         (V8Initializer):
172         * bindings/v8/WorkerContextExecutionProxy.cpp:
173         (WebCore::WorkerContextExecutionProxy::WorkerContextExecutionProxy):
174         * bindings/v8/WorkerContextExecutionProxy.h:
175         (WorkerContextExecutionProxy):
176
177 2012-11-25  Christophe Dumez  <christophe.dumez@intel.com>
178
179         [EFL] Refactor RenderThemeEfl::ThemePartCacheEntry::reuse()
180         https://bugs.webkit.org/show_bug.cgi?id=103189
181
182         Reviewed by Kenneth Rohde Christiansen.
183
184         Check if the entry size and type changed in
185         RenderThemeEfl::ThemePartCacheEntry::reuse() to avoid
186         useless processing if one of them did not change.
187
188         Remove useless call to cairo_surface_finish() since
189         we are using a smart pointer for the surface.
190
191         Resize the edge object *after* loading its content
192         from the theme file as it seems more logical this
193         way.
194
195         No new tests, no behavior change for layout tests.
196
197         * platform/efl/RenderThemeEfl.cpp:
198         (WebCore::RenderThemeEfl::ThemePartCacheEntry::reuse):
199         * platform/efl/RenderThemeEfl.h:
200         (ThemePartCacheEntry):
201
202 2012-11-25  Ryosuke Niwa  <rniwa@webkit.org>
203
204         Rename DynamicNodeList to LiveNodeList
205         https://bugs.webkit.org/show_bug.cgi?id=103197
206
207         Reviewed by Ojan Vafai.
208
209         Rename DynamicNodeList to LiveNodeList to match the terminology used in DOM4 working draft:
210         http://www.w3.org/TR/2012/WD-dom-20120405/#concept-collection-live
211         "A collection (either NodeList or HTMLCollection) can be either live or static".
212
213         Also rename DynamicNodeListCacheBase to LiveNodeListBase, and merge DynamicSubtreeNodeList
214         into LiveNodeList (old DynamicNodeList) now that the only difference between those two classes
215         is the former calling registerNodeListCache and unregisterNodeListCache on Document.
216
217         This patch completes the series of simplification of NodeList/HTMLCollection classes.
218
219         * CMakeLists.txt:
220         * GNUmakefile.list.am:
221         * Target.pri:
222         * WebCore.gypi:
223         * WebCore.xcodeproj/project.pbxproj:
224         * bindings/js/JSHTMLOptionsCollectionCustom.cpp:
225         (WebCore::getNamedItems):
226         * bindings/js/JSNodeListCustom.cpp:
227         (WebCore::JSNodeListOwner::isReachableFromOpaqueRoots):
228         * bindings/v8/custom/V8NodeListCustom.cpp:
229         (WebCore::V8NodeList::opaqueRootForGC):
230         * dom/ChildNodeList.cpp:
231         (WebCore::ChildNodeList::ChildNodeList):
232         (WebCore::ChildNodeList::nodeMatches):
233         * dom/ChildNodeList.h:
234         * dom/ClassNodeList.cpp:
235         (WebCore::ClassNodeList::ClassNodeList):
236         * dom/ClassNodeList.h:
237         * dom/DOMAllInOne.cpp:
238         * dom/Document.cpp:
239         (WebCore::Document::registerNodeListCache):
240         (WebCore::Document::unregisterNodeListCache):
241         (WebCore):
242         * dom/Document.h:
243         (WebCore):
244         (Document):
245         * dom/DynamicNodeList.cpp: Removed.
246         * dom/DynamicNodeList.h: Removed.
247         * dom/LiveNodeList.cpp: Copied from Source/WebCore/dom/DynamicNodeList.cpp.
248         (WebCore::LiveNodeListBase::rootNode):
249         (WebCore::LiveNodeListBase::invalidateCache):
250         (WebCore::LiveNodeListBase::invalidateIdNameCacheMaps):
251         (WebCore::LiveNodeListBase::reportMemoryUsage):
252         (WebCore::LiveNodeList::namedItem):
253         * dom/LiveNodeList.h: Copied from Source/WebCore/dom/DynamicNodeList.h.
254         (WebCore::LiveNodeListBase::LiveNodeListBase):
255         (WebCore::LiveNodeListBase::shouldInvalidateTypeOnAttributeChange):
256         (WebCore::LiveNodeList::LiveNodeList):
257         (WebCore::LiveNodeList::~LiveNodeList):
258         (LiveNodeList):
259         * dom/MicroDataItemList.cpp:
260         (WebCore::MicroDataItemList::MicroDataItemList):
261         * dom/MicroDataItemList.h:
262         * dom/NameNodeList.cpp:
263         (WebCore::NameNodeList::NameNodeList):
264         * dom/NameNodeList.h:
265         * dom/Node.cpp:
266         (WebCore::shouldInvalidateNodeListCachesForAttr):
267         (WebCore::Document::invalidateNodeListCaches):
268         * dom/Node.h:
269         (WebCore):
270         * dom/NodeList.h:
271         (WebCore::NodeList::isLiveNodeList):
272         * dom/NodeRareData.h:
273         (NodeListsNodeData):
274         (WebCore::NodeListsNodeData::removeCacheWithAtomicName):
275         (WebCore::NodeListsNodeData::removeCacheWithName):
276         (WebCore::NodeListsNodeData::removeCacheWithQualifiedName):
277         (WebCore::NodeListsNodeData::adoptTreeScope):
278         * dom/PropertyNodeList.cpp:
279         (WebCore::PropertyNodeList::PropertyNodeList):
280         * dom/PropertyNodeList.h:
281         * dom/TagNodeList.cpp:
282         (WebCore::TagNodeList::TagNodeList):
283         * dom/TagNodeList.h:
284         * html/HTMLCollection.cpp:
285         (WebCore::HTMLCollection::HTMLCollection):
286         (WebCore::LiveNodeListBase::iterateForNextNode):
287         (WebCore::LiveNodeListBase::itemBeforeOrAfter):
288         (WebCore::LiveNodeListBase::itemBefore):
289         (WebCore::LiveNodeListBase::itemAfter):
290         (WebCore::LiveNodeListBase::isLastItemCloserThanLastOrCachedItem):
291         (WebCore::LiveNodeListBase::isFirstItemCloserThanCachedItem):
292         (WebCore::LiveNodeListBase::setItemCache):
293         (WebCore::LiveNodeListBase::length):
294         (WebCore::LiveNodeListBase::item):
295         (WebCore::LiveNodeListBase::itemBeforeOrAfterCachedItem):
296         * html/HTMLCollection.h:
297         * html/LabelsNodeList.cpp:
298         (WebCore::LabelsNodeList::LabelsNodeList):
299         * html/LabelsNodeList.h:
300         * html/RadioNodeList.cpp:
301         (WebCore::RadioNodeList::RadioNodeList):
302         * html/RadioNodeList.h:
303
304 2012-10-08  Robert Hogan  <robert@webkit.org>
305
306         Changing position:relative to position:static results in mis-positioned div
307         https://bugs.webkit.org/show_bug.cgi?id=26397
308
309         Reviewed by Ojan Vafai.
310
311         When a block changes position from relative to static it is no longer the containing block for any
312         positioned objects it may have. If any of those positioned objects actually have a position specified
313         they are going to need a layout as their new containing block will likely have a different location they
314         need to offset from. Positioned objects without a specified position always get a layout anyway 
315         in layoutPositionedObjects() so no need to worry about them in this situation. 
316
317         Test: fast/block/abspos-child-container-changes-from-relative-to-static-expected.html
318
319         * rendering/RenderBlock.cpp:
320         (WebCore::RenderBlock::styleWillChange):
321         (WebCore::RenderBlock::layoutPositionedObjects):
322         (WebCore::RenderBlock::removePositionedObjects):
323         * rendering/RenderBlock.h:
324         (RenderBlock):
325
326 2012-11-25  Kent Tamura  <tkent@chromium.org>
327
328         Correct input[type=number] value sanitization for user-input
329         https://bugs.webkit.org/show_bug.cgi?id=103018
330
331         Reviewed by Kentaro Hara.
332
333         If a number field has non-number string, HTMLInputElement::value is not
334         updated and returns the past valid value. It doesn't match to the value
335         sanitization algorithm defined by the HTML standard [1], and Opera's
336         behavior. We should sanitize non-number strings to "".
337
338         [1] http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#number-state-(type=number)
339         > The value sanitization algorithm is as follows: If the value of the
340         > element is not a valid floating-point number, then set it to the empty
341         > string instead.
342
343         No new tests. Update existing tests;
344         fast/forms/number/number-commit-valid-only.html and
345         fast/forms/number/number-unacceptable-style.html
346
347         * html/HTMLInputElement.cpp:
348         (WebCore::HTMLInputElement::subtreeHasChanged):
349         Remove isAcceptableValue check.
350
351         * html/HTMLInputElement.h:
352         (HTMLInputElement): isAcceptableValue is no longer needed.
353         * html/InputType.cpp: Remove isAcceptableValue.
354         * html/InputType.h: Ditto.
355         * html/NumberInputType.cpp: Ditto.
356         (WebCore::NumberInputType::hasUnacceptableValue):
357         Fold the isAcceptableValue content into this.
358         * html/NumberInputType.h:
359         (NumberInputType): Remove isAcceptableValue.
360
361 2012-12-11  Viatcheslav Ostapenko  <sl.ostapenko@samsung.com>
362
363         Remove conversion to/from float and float division from ImageFrame::setRGBA
364         https://bugs.webkit.org/show_bug.cgi?id=103693
365
366         Reviewed by Brent Fulgham.
367
368         Replace floating point operations used for alpha premultiply with fixed point arithmetic
369         which is basically integer operations. Allows to shave extra couple percent from decoding
370         images with transparency.
371
372         Covered by existing tests.
373
374         * platform/image-decoders/ImageDecoder.h:
375         (ImageFrame):
376         (WebCore::ImageFrame::fixPointUnsignedMultiply):
377         (WebCore::ImageFrame::setRGBA):
378
379 2012-11-30  Jer Noble  <jer.noble@apple.com>
380
381         Unreviewed Windows build fix.
382
383         Add a default: entry to an case statement to fix a build error when compiled in VS2005.
384
385         * html/MediaController.cpp:
386         (MediaController::playbackState):
387
388 2012-11-28  Byungwoo Lee  <bw80.lee@samsung.com>
389
390         [EFL] Use mutex locker in wakeUp() to ensure thread-safety.
391         https://bugs.webkit.org/show_bug.cgi?id=101132
392
393         Reviewed by Gyuyoung Kim.
394
395         Add mutex locker for the ecore pipe to ensure thread-safety of
396         RunLoop::wakeUp().
397
398         RunLoop::wakeUp() can be called by multiple thread. It uses
399         ecore_pipe_write() function but the function is not thread-safe.
400
401         * platform/RunLoop.h:
402         (RunLoop):
403         * platform/efl/RunLoopEfl.cpp:
404         (WebCore::RunLoop::wakeUp):
405
406 2012-11-09  Huang Dongsung  <luxtella@company100.net>
407
408         Coordinated Graphics: Remove a backing store of GraphicsLayer when the layer is far from the viewport.
409         https://bugs.webkit.org/show_bug.cgi?id=101656
410
411         Reviewed by Kenneth Rohde Christiansen.
412
413         TiledBackingStore computes cover and keep rects to create, keep or remove tiles
414         smartly, but currently TiledBackingStore expects a contents rect is big enough
415         to cover the visibleRect. However, when CoordinatedGraphicsLayer uses TBS, it
416         is usually wrong expectation.
417
418         We must compute cover and keep rects using the visibleRect, instead of
419         the rect intersecting the visibleRect with m_rect, because TBS can be
420         used as a backing store of GraphicsLayer and the visible rect usually
421         does not intersect with m_rect.
422         In the below case, the intersecting rect is an empty.
423
424          +---------------+
425          |               |
426          |   m_rect      |
427          |       +-------|-----------------------+
428          |       | HERE  |  cover or keep        |
429          +---------------+      rect             |
430                  |         +---------+           |
431                  |         | visible |           |
432                  |         |  rect   |           |
433                  |         +---------+           |
434                  |                               |
435                  |                               |
436                  +-------------------------------+
437
438         We must create or keep the tiles in the HERE region. Currently in the
439         case, we do not create or keep tiles on the HERE region. Moreover, in
440         the case, we early return, which means we don't remove any tiles. It
441         causes to waste heap and video memory.
442
443         This patch changes TiledBackingStore to manage tiles smartly for
444         Coordinated Graphics.
445
446         Changing cache policy is not testable in layout tests.
447
448         * platform/graphics/TiledBackingStore.cpp:
449         (WebCore::TiledBackingStore::visibleRect):
450         (WebCore::TiledBackingStore::visibleAreaIsCovered):
451         (WebCore::TiledBackingStore::createTiles):
452         (WebCore::TiledBackingStore::adjustForContentsRect):
453         (WebCore::TiledBackingStore::removeAllNonVisibleTiles):
454         * platform/graphics/TiledBackingStore.h:
455         (TiledBackingStore):
456
457 2012-10-10  Christophe Dumez  <christophe.dumez@intel.com>
458
459         SQLResultSet.rowsAffected not cleared
460         https://bugs.webkit.org/show_bug.cgi?id=46070
461
462         Reviewed by Kenneth Rohde Christiansen.
463
464         SQLResultSet.rowsAffected is supposed to return the number
465         of rows that were changed by the statement. For "SELECT"
466         statements, it should return 0.
467
468         However, our implementation currently relies on sqlite3_changes()
469         to compute this value. sqlite3_changes() returns the number of
470         direct row changes in the most recent INSERT, UPDATE, or DELETE
471         statement within the same trigger context. Unfortunately, the
472         most recent INSERT, UPDATE, or DELETE statement may not be the
473         last statement. As a consequence, if you INSERT 1 row, then
474         do a SELECT, SQLResultSet.rowsAffected will be 1 for both the
475         INSERT and the SELECT statements.
476
477         The proposed solution is to use sqlite3_total_changes() instead
478         of sqlite3_changes(). sqlite3_total_changes() returns the number
479         of row changes caused by INSERT, UPDATE or DELETE statements since
480         the database connection was opened. We now store the value
481         returned by sqlite3_total_changes() before each statement in
482         order to return the count difference in
483         SQLiteDatabase::lastChanges().
484
485         Test: storage/websql/execute-sql-rowsAffected.html
486
487         * platform/sql/SQLiteDatabase.cpp:
488         (WebCore::SQLiteDatabase::SQLiteDatabase):
489         (WebCore::SQLiteDatabase::updateLastChangesCount):
490         (WebCore):
491         (WebCore::SQLiteDatabase::lastChanges):
492         * platform/sql/SQLiteDatabase.h:
493         (SQLiteDatabase):
494         * platform/sql/SQLiteStatement.cpp:
495         (WebCore::SQLiteStatement::step):
496
497 2012-11-20  Keishi Hattori  <keishi@webkit.org>
498
499         Week picker width is too small
500         https://bugs.webkit.org/show_bug.cgi?id=102766
501
502         Reviewed by Kent Tamura.
503
504         The width of week picker was too small because we were forgetting about
505         the week number column when calculating the desired width.
506
507         No new tests. Covered by week-picker-appearance*.html.
508
509         * Resources/pagepopups/calendarPicker.css:
510         (.week-mode .week-column): Needs to be table-cell.
511         * Resources/pagepopups/calendarPicker.js:
512         (CalendarPicker.prototype.fixWindowSize):
513
514 2012-11-20  Xabier Rodriguez Calvar  <calvaris@igalia.com>
515
516         [GTK] no volume slider in HTML5 media element controls
517         https://bugs.webkit.org/show_bug.cgi?id=97192
518
519         Reviewed by Philippe Normand.
520
521         r115829 was causing this regression so it was partially
522         reverted. The revert causes some small regressions, in the tests
523         but it is better to have the volume slider shown.
524
525         * css/mediaControlsGtk.css:
526         (audio::-webkit-media-controls-panel)
527         (video::-webkit-media-controls-panel): Partially reverted
528         r115829.
529
530 2012-11-19  Antti Koivisto  <antti@apple.com>
531
532         Collect user style sheets in DocumentStyleSheetCollection
533         https://bugs.webkit.org/show_bug.cgi?id=102683
534
535         Reviewed by Andreas Kling.
536
537         Move the user stylesheet collection logic from StyleResolver to DocumentStyleSheetCollection.
538         
539         * css/StyleResolver.cpp:
540         (WebCore::StyleResolver::StyleResolver):
541         (WebCore::StyleResolver::collectRulesFromUserStyleSheets):
542         (WebCore::collectCSSOMWrappers):
543         * css/StyleResolver.h:
544         (StyleResolver):
545         * dom/DocumentStyleSheetCollection.cpp:
546         (WebCore::DocumentStyleSheetCollection::~DocumentStyleSheetCollection):
547         (WebCore::DocumentStyleSheetCollection::pageUserStyleSheet):
548         (WebCore::DocumentStyleSheetCollection::clearPageUserStyleSheet):
549         (WebCore::DocumentStyleSheetCollection::updatePageUserStyleSheet):
550         (WebCore::DocumentStyleSheetCollection::analyzeStyleSheetChange):
551         (WebCore::collectActiveStyleSheetsFromSeamlessParents):
552         (WebCore::DocumentStyleSheetCollection::updateStyleResolver):
553         
554             Factor the StyleResolver updating code to function.
555
556         (WebCore):
557         (WebCore::DocumentStyleSheetCollection::updateActiveStyleSheets):
558         
559             Collect the user style sheets. Some renaming and other minor refactoring.
560
561         (WebCore::DocumentStyleSheetCollection::reportMemoryUsage):
562         * dom/DocumentStyleSheetCollection.h:
563         (WebCore::DocumentStyleSheetCollection::activeUserStyleSheets):
564         
565             Add activeUserStyleSheets vector that contains all user stylesheets from different sources,
566             similar to activeAuthorStyleSheets.
567
568         (DocumentStyleSheetCollection):
569         (WebCore::DocumentStyleSheetCollection::documentUserStyleSheets):
570
571 2012-11-20  Elliott Sprehn  <esprehn@chromium.org>
572
573         Remove unneeded optimization in Element::isInTopLayer
574         https://bugs.webkit.org/show_bug.cgi?id=102772
575
576         Reviewed by Andreas Kling.
577
578         There's no reason to worry about calling elementRareData() multiple
579         times in this non performance sensitive code path as it's only used
580         in HTMLDialogElement's showModal and close methods.
581
582         No new tests, just simplification.
583
584         * dom/Element.cpp:
585         (WebCore::Element::setIsInTopLayer):
586
587 2012-11-20  Elliott Sprehn  <esprehn@chromium.org>
588
589         Simplify Element::isSpellCheckingEnabled
590         https://bugs.webkit.org/show_bug.cgi?id=102779
591
592         Reviewed by Andreas Kling.
593
594         isSpellCheckingEnabled contains logic that duplicates parentOrHostElement
595         and can be simplified by just calling that.
596
597         No new tests, just simplification.
598
599         * dom/Element.cpp:
600         (WebCore::Element::isSpellCheckingEnabled):
601
602 2012-11-20  Kihong Kwon  <kihong.kwon@samsung.com>
603
604         Apply DeviceController as parent class of DeviceMotionController.
605         https://bugs.webkit.org/show_bug.cgi?id=102578
606
607         Reviewed by Hajime Morita.
608
609         DeviceController needs to be applied as parent class of DeviceMotionController
610         because DeviceController which is extracted as parent class of
611         DeviceMotionController and DeviceOrientationController is already added.
612         Therefore duplicated implementation can be removed.
613
614         Covered by existing tests.
615
616         * dom/DeviceMotionClient.h:
617         * dom/DeviceMotionController.cpp:
618         (WebCore::DeviceMotionController::DeviceMotionController):
619         (WebCore::DeviceMotionController::didChangeDeviceMotion):
620         (WebCore::DeviceMotionController::deviceMotionClient):
621         (WebCore::DeviceMotionController::hasLastData):
622         (WebCore::DeviceMotionController::getLastEvent):
623         (WebCore::DeviceMotionController::from):
624         (WebCore):
625         * dom/DeviceMotionController.h:
626         (WebCore):
627         (WebCore::DeviceMotionController::~DeviceMotionController):
628         (DeviceMotionController):
629         * dom/Document.cpp:
630         Remove all implementations which are related DeviceOrientationEvnet and DeviceMotionEvent.
631         Because DeviceController checks suspend and stop status of active dom object before dispatchEvent.
632         (WebCore::Document::suspendActiveDOMObjects):
633         (WebCore::Document::resumeActiveDOMObjects):
634         * loader/EmptyClients.h:
635         * page/DOMWindow.cpp:
636         (WebCore::DOMWindow::addEventListener):
637         (WebCore::DOMWindow::removeEventListener):
638         (WebCore::DOMWindow::removeAllEventListeners):
639
640 2012-11-20  Kentaro Hara  <haraken@chromium.org>
641
642         [V8] Remove V8ParameterBase
643         https://bugs.webkit.org/show_bug.cgi?id=102774
644
645         Reviewed by Adam Barth.
646
647         V8ParameterBase is a redundant indirection.
648         We can flatten methods of V8ParameterBase to V8Parameter.
649
650         No tests. No change in behavior.
651
652         * bindings/v8/V8StringResource.h:
653         (WebCore::V8Parameter::V8Parameter):
654         (V8Parameter):
655         (WebCore::V8Parameter::toString):
656         (WebCore::::prepare):
657
658 2012-11-20  Kunihiko Sakamoto  <ksakamoto@chromium.org>
659
660         Use localized date-time format in datetime input
661         https://bugs.webkit.org/show_bug.cgi?id=102769
662
663         Reviewed by Kent Tamura.
664
665         Move the implementation of Locale::dateTimeFormatWithSeconds and Locale::dateTimeFormatWithoutSeconds
666         to its subclasses and use platform-specific methods to get date-time pattern.
667         Because Windows does not provide an API to get date-time pattern. We use fixed "{date} {time}"
668         pattern for Windows.
669
670         Test: fast/forms/datetime/datetime-appearance-l10n.html
671
672         * platform/text/LocaleICU.cpp:
673         (WebCore::LocaleICU::initializeDateTimeFormat): Retrieve datetime formats too.
674         (WebCore::LocaleICU::dateTimeFormatWithSeconds): Added.
675         (WebCore):
676         (WebCore::LocaleICU::dateTimeFormatWithoutSeconds): Added.
677         * platform/text/LocaleICU.h:
678         (LocaleICU): Add m_dateTimeFormatWithSeconds and m_dateTimeFormatWithoutSeconds.
679         * platform/text/LocaleNone.cpp:
680         (LocaleNone):
681         (WebCore::LocaleNone::dateTimeFormatWithSeconds): Added. Always returns "dd/MM/yyyyy HH:mm:ss".
682         (WebCore):
683         (WebCore::LocaleNone::dateTimeFormatWithoutSeconds): Added. Always returns "dd/MM/yyyyy HH:mm".
684         * platform/text/PlatformLocale.cpp:
685         (WebCore): Remove dateTimeFormatWithSeconds() and dateTimeFormatWithoutSeconds() as these are now pure virtual.
686         * platform/text/PlatformLocale.h:
687         (Locale): Make dateTimeFormatWithSeconds() and dateTimeFormatWithoutSeconds() pure virtual.
688         * platform/text/mac/LocaleMac.h:
689         (LocaleMac): Add m_dateTimeFormatWithSeconds and m_dateTimeFormatWithoutSeconds.
690         * platform/text/mac/LocaleMac.mm:
691         (WebCore::LocaleMac::dateTimeFormatterWithSeconds): Added.
692         (WebCore):
693         (WebCore::LocaleMac::dateTimeFormatterWithoutSeconds): Added.
694         (WebCore::LocaleMac::dateTimeFormatWithSeconds): Added.
695         (WebCore::LocaleMac::dateTimeFormatWithoutSeconds): Added.
696         * platform/text/win/LocaleWin.cpp:
697         (WebCore::LocaleWin::dateTimeFormatWithSeconds): Copied from original Locale::dateTimeFormatWithSeconds().
698         (WebCore):
699         (WebCore::LocaleWin::dateTimeFormatWithoutSeconds): Copied from original Locale::dateTimeFormatWithoutSeconds().
700         * platform/text/win/LocaleWin.h:
701         (LocaleWin): Add m_dateTimeFormatWithSeconds and m_dateTimeFormatWithoutSeconds.
702
703 2012-11-20  Sheriff Bot  <webkit.review.bot@gmail.com>
704
705         Unreviewed, rolling out r135257.
706         http://trac.webkit.org/changeset/135257
707         https://bugs.webkit.org/show_bug.cgi?id=102777
708
709         Broke Chromium Debug compilation (Requested by yurys on
710         #webkit).
711
712         * bindings/v8/DOMDataStore.h:
713         (WebCore::DOMDataStore::getNode):
714
715 2012-11-20  Vsevolod Vlasov  <vsevik@chromium.org>
716
717         Web Inspector: Revert r133149: breaks revision reverting
718         https://bugs.webkit.org/show_bug.cgi?id=102672
719
720         Reviewed by Yury Semikhatsky.
721
722         * inspector/front-end/JavaScriptSourceFrame.js:
723         (WebInspector.JavaScriptSourceFrame):
724         (WebInspector.JavaScriptSourceFrame.prototype._onFormattedChanged):
725         (WebInspector.JavaScriptSourceFrame.prototype._onWorkingCopyCommitted):
726         (WebInspector.JavaScriptSourceFrame.prototype._innerSetContent):
727
728 2012-11-19  Csaba Osztrogonác  <ossy@webkit.org>
729
730         [Qt][Win] Unreviewed speculative buildfix after r135217.
731
732         * platform/win/WindowsExtras.h:
733
734 2012-11-19  Yury Semikhatsky  <yurys@chromium.org>
735
736         Unreviewed. Fix Chromium Win compilation after r135255.
737         https://bugs.webkit.org/show_bug.cgi?id=97803
738
739         * WebCore.gypi: removed reference to platform/wince/DragDataWince.cpp which
740         was deleted in the aforementioned change.
741
742 2012-11-19  Kentaro Hara  <haraken@chromium.org>
743
744         [V8] Merge getCachedWrapper(Node*) into DOMDataStore
745         https://bugs.webkit.org/show_bug.cgi?id=102158
746
747          Reviewed by Adam Barth.
748
749         A follow-up patch for r135230. This patch adds a correct ASSERTION.
750
751         No tests. No change in behavior.
752
753         * bindings/v8/DOMDataStore.h:
754         (WebCore::DOMDataStore::getNode):
755
756 2012-11-19  Kentaro Hara  <haraken@chromium.org>
757
758         [JSC] Replace $implClassName with $interfaceName in CodeGeneratorJS.pm
759         https://bugs.webkit.org/show_bug.cgi?id=102757
760
761         Reviewed by Adam Barth.
762
763         In CodeGeneratorJS.pm $implClassName and $interfaceName are
764         equivalent. We're using them interchangeably. We should replace
765         $implClassName with $interfaceName.
766
767         No tests. No change in behavior.
768
769         * bindings/scripts/CodeGeneratorJS.pm:
770         (AddClassForwardIfNeeded):
771         (GenerateGetOwnPropertySlotBody):
772         (GenerateGetOwnPropertyDescriptorBody):
773         (GenerateHeader):
774         (GenerateOverloadedFunction):
775         (GenerateImplementation):
776         (GenerateParametersCheck):
777         (GenerateImplementationFunctionCall):
778         (NativeToJSValue):
779
780 2012-11-19  Patrick Gansterer  <paroga@webkit.org>
781
782         Port DragDataWin.cpp to WinCE
783         https://bugs.webkit.org/show_bug.cgi?id=97803
784
785         Reviewed by Brent Fulgham.
786
787         Add two simple #if OS(WINCE) to DragDataWin.cpp, so it can be used by the WinCE port too.
788
789         * PlatformWinCE.cmake:
790         * platform/win/DragDataWin.cpp:
791         (WebCore::DragData::containsFiles):
792         (WebCore::DragData::numberOfFiles):
793         (WebCore::DragData::asFilenames):
794         * platform/wince/DragDataWinCE.cpp: Removed.
795
796 2012-11-19  Pan Deng  <pan.deng@intel.com>
797
798         [Web Inspector] This patch makes script line number search-able in Timeline panel.
799         https://bugs.webkit.org/show_bug.cgi?id=101910.
800
801         Reviewed by Pavel Feldman.
802
803         Script line number is visible in Timeline panel, however, not search-able. This patch makes it search-able.
804
805         No new tests. 
806
807         * inspector/front-end/TimelinePanel.js:
808         (WebInspector.TimelineRecordListRow.prototype.update):
809         (WebInspector.TimelineRecordListRow.testContentMatching):
810         * inspector/front-end/TimelinePresentationModel.js:
811         (WebInspector.TimelinePresentationModel.Record.prototype._generatePopupContentWithImagePreview):
812         (WebInspector.TimelinePresentationModel.Record.prototype._refreshDetails):
813         (WebInspector.TimelinePresentationModel.Record.prototype.detailsNode):
814         (WebInspector.TimelinePresentationModel.Record.prototype._createSpanWithText):
815         (WebInspector.TimelinePresentationModel.Record.prototype._getRecordDetails):
816
817 2012-11-19  Elliott Sprehn  <esprehn@chromium.org>
818
819         Remove unneeded null check in NodeRendererFactory::createRendererIfNeeded
820         https://bugs.webkit.org/show_bug.cgi?id=102765
821
822         Reviewed by Ojan Vafai.
823
824         If parentRenderer() was null then we return early from
825         createRendererIfNeeded() because shouldCreateRenderer() will return false
826         so there's no reason to check for it again.
827
828         Additionally if either parentRenderer() or style() is null then
829         implementations of rendererIsNeeded() will crash, so add asserts to
830         make this assumption more clear.
831
832         No new tests, just simplification.
833
834         * dom/NodeRenderingContext.cpp:
835         (WebCore::NodeRendererFactory::createRendererIfNeeded):
836
837 2012-11-19  Shinya Kawanaka  <shinyak@chromium.org>
838
839         [Refactoring] Remove WebCore::isInsertionPoint(Node*)
840         https://bugs.webkit.org/show_bug.cgi?id=102756
841
842         Reviewed by Hajime Morita.
843
844         Now that WebCore::isInsertionPoint(Node* node) does nothing special. We can remove this.
845
846         No new tests, simple refactoring.
847
848         * dom/ComposedShadowTreeWalker.cpp:
849         (WebCore::ComposedShadowTreeWalker::traverseNodeEscapingFallbackContents):
850         * dom/ContainerNode.cpp:
851         (WebCore::childAttachedAllowedWhenAttachingChildren):
852         * html/shadow/ContentDistributor.cpp:
853         (WebCore::ContentDistributor::invalidate):
854         * html/shadow/InsertionPoint.cpp:
855         (WebCore::InsertionPoint::isActive):
856         * html/shadow/InsertionPoint.h:
857         (WebCore::toInsertionPoint):
858         (WebCore::isActiveInsertionPoint):
859         (WebCore::isLowerEncapsulationBoundary):
860         (WebCore::parentNodeForDistribution):
861         * testing/Internals.cpp:
862         (WebCore::Internals::isValidContentSelect):
863
864 2012-11-19  Shinya Kawanaka  <shinyak@chromium.org>
865
866         [Refactoring] Remove shadowPseudoId() and use setPseudo() in <progress> ElementShadow.
867         https://bugs.webkit.org/show_bug.cgi?id=101703
868
869         Reviewed by Hajime Morita.
870
871         We're migrating shadowPseudoId() to pseudo(). We remove shadowPseudoId() from HTMLKeygenElement and use
872         setPseudo()/pseudo() instead.
873
874         No new tests, simple refactoring.
875
876         * html/shadow/ProgressShadowElement.cpp:
877         (WebCore::ProgressInnerElement::ProgressInnerElement):
878         * html/shadow/ProgressShadowElement.h:
879         (ProgressInnerElement):
880         (WebCore::ProgressBarElement::ProgressBarElement):
881         (ProgressBarElement):
882         (WebCore::ProgressValueElement::ProgressValueElement):
883
884 2012-11-19  Yury Semikhatsky  <yurys@chromium.org>
885
886         Unreviewed. Fix Chromium Debug compilation after r135230.
887         https://bugs.webkit.org/show_bug.cgi?id=102158
888
889         Removed ASSERT that used instance field in a static method.
890
891         * bindings/v8/DOMDataStore.h:
892         (WebCore::DOMDataStore::getWrapperFromObject):
893
894 2012-11-19  Chris Guan  <chris.guan@torchmobile.com.cn>
895
896         [Blackberry] When a frame is being detached, cancel all its network jobs.
897         https://bugs.webkit.org/show_bug.cgi?id=102758
898
899         Reviewed by George Staikos.
900
901         I use FrameDestructionObserver to refactor Networkjob code.
902         NetworkJob is inheriting from FrameDestructionObserver to be
903         aware of frame's destroyed. When a frame is being detached,
904         the willDetachPage() can be called in which we can cancel 
905         the job. This patch reverted the fix for RIM PR134207 as well.
906
907         Manually test is on 
908         "http://www.reuters.com/article/2012/01/27/us-greece-idUSTRE80P0DE20120127"
909         which triggers a ping loader.
910
911         No behavior changed, no new layout tests.
912
913         * platform/network/blackberry/NetworkJob.cpp:
914         (WebCore::NetworkJob::NetworkJob):
915         (WebCore::NetworkJob::initialize):
916         (WebCore::NetworkJob::handleNotifyHeaderReceived):
917         (WebCore::NetworkJob::startNewJobWithRequest):
918         (WebCore::NetworkJob::frameDestroyed):
919         (WebCore):
920         (WebCore::NetworkJob::willDetachPage):
921         * platform/network/blackberry/NetworkJob.h:
922         (NetworkJob):
923         * platform/network/blackberry/NetworkManager.cpp:
924         (WebCore::NetworkManager::startJob):
925         * platform/network/blackberry/NetworkManager.h:
926         (NetworkManager):
927         * platform/network/blackberry/ResourceHandleBlackBerry.cpp:
928         (WebCore::ResourceHandle::start):
929         (WebCore::ResourceHandle::loadResourceSynchronously):
930
931 2012-11-19  Matt Falkenhagen  <falken@chromium.org>
932
933         Implement the new stacking layer needed by the Fullscreen API and the new <dialog> element
934         https://bugs.webkit.org/show_bug.cgi?id=84796
935
936         Reviewed by Julien Chaffraix.
937
938         This adds the top layer element stack to Document. The Fullscreen
939         specification mandates that we track the ordering of the DOM nodes in
940         the top layer, not the renderers. That makes it hard to implement on
941         the rendering side only.
942
943         Elements in the top layer get a layer. Layers in the top layer are
944         added to the root layer's child list after normal layers and in the
945         order of the top layer stack. This way, the top layer appears above
946         all other stacking contexts and in the desired order.
947
948         In addition, top layer renderers are added as children of RenderView
949         in top layer order. This is to satisfy requirements such as the
950         containing block of an element in the top layer is the initial
951         containing block. It also allows RenderLayer to know the proper
952         stacking order of the layers without going directly from the top layer
953         elements to their layers.
954
955         So far, only modal dialog elements can be added to the top layer.
956         The plan is to make the Fullscreen API also use the top layer.
957
958         Tests: fast/dom/HTMLDialogElement/top-layer-containing-block.html
959                fast/dom/HTMLDialogElement/top-layer-display-none.html
960                fast/dom/HTMLDialogElement/top-layer-nesting.html
961                fast/dom/HTMLDialogElement/top-layer-stacking-dynamic.html
962                fast/dom/HTMLDialogElement/top-layer-stacking.html
963
964         * WebCore.exp.in:
965         * css/StyleResolver.cpp:
966         (WebCore::StyleResolver::adjustRenderStyle): Elements in the top layer have a stacking context.
967         * dom/Document.cpp:
968         (WebCore):
969         (WebCore::Document::addToTopLayer):
970         (WebCore::Document::removeFromTopLayer):
971         * dom/Document.h:
972         (Document):
973         (WebCore::Document::topLayerElements): Add the top layer element stack to Document.
974         * dom/Element.cpp:
975         (WebCore::Element::removedFrom):
976         (WebCore):
977         (WebCore::Element::isInTopLayer):
978         (WebCore::Element::setIsInTopLayer):
979         * dom/Element.h:
980         * dom/ElementRareData.h:
981         (ElementRareData):
982         * dom/Node.cpp:
983         (WebCore::Node::detach): Add an exception to the assert since top layer elements and their descendants are moved from their
984         regular position in the render tree.
985         * dom/NodeRareData.h:
986         (WebCore::NodeRareData::NodeRareData):
987         (NodeRareData):
988         (WebCore::NodeRareData::isInTopLayer):
989         (WebCore::NodeRareData::setIsInTopLayer):
990         * dom/NodeRenderingContext.cpp:
991         (WebCore):
992         (WebCore::adjustInsertionPointForTopLayerElement):
993         (WebCore::NodeRendererFactory::createRendererIfNeeded): Add renderers for top layer elements as children of RenderView, and
994         in top layer stacking order.
995         * html/HTMLDialogElement.cpp:
996         (WebCore::HTMLDialogElement::close):
997         (WebCore::HTMLDialogElement::showModal):
998         * rendering/RenderLayer.cpp:
999         (WebCore):
1000         (WebCore::RenderLayer::isInTopLayer):
1001         (WebCore::RenderLayer::isInTopLayerSubtree):
1002         (WebCore::RenderLayer::rebuildZOrderLists): Add the top layer stack after normal layer collection.
1003         (WebCore::RenderLayer::collectLayers): Avoid adding layers for top layer elements during normal layer collection.
1004         * rendering/RenderLayer.h:
1005         (RenderLayer):
1006
1007 2012-11-19  Kentaro Hara  <haraken@chromium.org>
1008
1009         In CodeGeneratorObj.pm we should rename $dataNode to $interface.
1010         https://bugs.webkit.org/show_bug.cgi?id=102749
1011
1012         Reviewed by Adam Barth.
1013
1014         $dataNode is misnamed. It should be renamed to $interface.
1015
1016         No tests. No change in behavior.
1017
1018         * bindings/scripts/CodeGeneratorObjC.pm:
1019         (GenerateInterface):
1020         (GetParentImplClassName):
1021         (GetParentAndProtocols):
1022         (GenerateHeader):
1023         (GenerateImplementation):
1024
1025 2012-11-19  Kentaro Hara  <haraken@chromium.org>
1026
1027         In CodeGeneratorV8.pm, we should rename $dataNode to $interface
1028         https://bugs.webkit.org/show_bug.cgi?id=102747
1029
1030         Reviewed by Adam Barth.
1031
1032         $dataNode is misnamed. It should be $interface.
1033
1034         No tests. No change in behavior.
1035
1036         * bindings/scripts/CodeGeneratorV8.pm:
1037         (GenerateInterface):
1038         (NeedsCustomOpaqueRootForGC):
1039         (GetGenerateIsReachable):
1040         (GetCustomIsReachable):
1041         (GenerateOpaqueRootForGC):
1042         (GenerateHeader):
1043         (GetInternalFields):
1044         (GenerateHeaderCustomInternalFieldIndices):
1045         (GenerateHeaderNamedAndIndexedPropertyAccessors):
1046         (GenerateHeaderCustomCall):
1047         (IsConstructable):
1048         (GenerateConstructorGetter):
1049         (GenerateNormalAttrGetter):
1050         (GenerateReplaceableAttrSetter):
1051         (GenerateNormalAttrSetter):
1052         (GenerateOverloadedFunctionCallback):
1053         (GenerateFunctionCallback):
1054         (GenerateArgumentsCountCheck):
1055         (GenerateOverloadedConstructorCallback):
1056         (GenerateSingleConstructorCallback):
1057         (GenerateConstructorCallback):
1058         (GenerateEventConstructorCallback):
1059         (GenerateTypedArrayConstructorCallback):
1060         (GenerateNamedConstructorCallback):
1061         (GenerateBatchedAttributeData):
1062         (IsStandardFunction):
1063         (GenerateNonStandardFunction):
1064         (GenerateImplementationIndexer):
1065         (GenerateImplementationNamedPropertyGetter):
1066         (GenerateImplementationCustomCall):
1067         (GenerateImplementationMasqueradesAsUndefined):
1068         (GenerateImplementation):
1069         (GenerateHeaderContentHeader):
1070         (GenerateImplementationContentHeader):
1071         (GenerateCallbackHeader):
1072         (GenerateCallbackImplementation):
1073         (BaseInterfaceName):
1074         (GenerateToV8Converters):
1075         (GetNativeTypeForConversions):
1076         (GetTypeNameOfExternalTypedArray):
1077         (WriteData):
1078
1079 2012-11-19  Keishi Hattori  <keishi@webkit.org>
1080
1081         Move in animation should be disabled until the calendar picker is loaded.
1082         https://bugs.webkit.org/show_bug.cgi?id=102661
1083
1084         Reviewed by Kent Tamura.
1085
1086         On weeks where the first day is in the previous month (e.x. 2013-W01)
1087         the move in animation happens when you open the calendar picker. This
1088         patch disables the move in animation until the calendar picker is fully
1089         loaded.
1090
1091         No new tests.
1092
1093         * Resources/pagepopups/calendarPicker.js:
1094         (CalendarPicker):
1095         (CalendarPicker.prototype._handleWindowResize):
1096         (DaysTable.prototype._startMoveInAnimation):
1097
1098 2012-11-19  Elliott Sprehn  <esprehn@chromium.org>
1099
1100         Clean up loop in NodeRenderingContext::nextRenderer and previousRenderer
1101         https://bugs.webkit.org/show_bug.cgi?id=102743
1102
1103         Reviewed by Hajime Morita.
1104
1105         Clean up while (true) loops in NodeRenderingContext reducing the
1106         amount of code and the need for ASSERT_NOT_REACHED.
1107
1108         No new tests, just simplifcation.
1109
1110         * dom/NodeRenderingContext.cpp:
1111         (WebCore::NodeRenderingContext::nextRenderer):
1112         (WebCore::NodeRenderingContext::previousRenderer):
1113
1114 2012-11-19  Shinya Kawanaka  <shinyak@chromium.org>
1115
1116         [Shadow] attribute pseudo should return empty string instead of null when nothing is specified.
1117         https://bugs.webkit.org/show_bug.cgi?id=102753
1118
1119         Reviewed by Hajime Morita.
1120
1121         The ShadowDOM spec is changed so that attribute 'pseudo' returns empty string instead of null when
1122         no value is set.
1123
1124         Test: fast/dom/shadow/pseudo-attribute.html
1125
1126         * dom/Element.idl:
1127
1128 2012-11-19  Kentaro Hara  <haraken@chromium.org>
1129
1130         In CodeGeneratorGObject.pm we should rename $dataNode to $interface
1131         https://bugs.webkit.org/show_bug.cgi?id=102751
1132
1133         Reviewed by Adam Barth.
1134
1135         $dataNode is misnamed. It should be $interface.
1136
1137         No tests. No change in behavior.
1138
1139         * bindings/scripts/CodeGeneratorGObject.pm:
1140         (GetParentClassName):
1141         (GetParentGObjType):
1142         (GenerateProperties):
1143         (GenerateFunctions):
1144         (GenerateCFile):
1145         (GenerateEventTargetIface):
1146         (Generate):
1147         (WriteData):
1148         (GenerateInterface):
1149
1150 2012-11-19  Kentaro Hara  <haraken@chromium.org>
1151
1152         In CodeGenerator.pm we should rename $dataNode to $interface
1153         https://bugs.webkit.org/show_bug.cgi?id=102754
1154
1155         Reviewed by Adam Barth.
1156
1157         $dataNode is misnamed. It should be $interface.
1158
1159         No tests. No change in behavior.
1160
1161         * bindings/scripts/CodeGenerator.pm:
1162         (ForAllParents):
1163         (AddMethodsConstantsAndAttributesFromParentInterfaces):
1164         (FindSuperMethod):
1165         (IsConstructorTemplate):
1166         (LinkOverloadedFunctions):
1167         (GenerateCompileTimeCheckForEnumsIfNeeded):
1168         (GetVisibleInterfaceName):
1169         (IsSubType):
1170
1171 2012-11-19  Kentaro Hara  <haraken@chromium.org>
1172
1173         In CodeGeneratorCPP.pm we should rename $dataNode to $interface
1174         https://bugs.webkit.org/show_bug.cgi?id=102752
1175
1176         Reviewed by Adam Barth.
1177
1178         $dataNode is misnamed. It should be $interface.
1179
1180         No tests. No change in behavior.
1181
1182         * bindings/scripts/CodeGeneratorCPP.pm:
1183         (GenerateInterface):
1184         (GetParentImplClassName):
1185         (GetParent):
1186         (GenerateHeader):
1187         (GenerateImplementation):
1188
1189 2012-11-19  Kentaro Hara  <haraken@chromium.org>
1190
1191         In CodeGeneratorJS.pm we should rename $dataNode to $interface
1192         https://bugs.webkit.org/show_bug.cgi?id=102748
1193
1194         Reviewed by Adam Barth.
1195
1196         $dataNode is misnamed. It should be $interface.
1197
1198         No tests. No change in behavior.
1199
1200         * bindings/scripts/CodeGeneratorJS.pm:
1201         (GenerateInterface):
1202         (GetParentClassName):
1203         (GetGenerateIsReachable):
1204         (GetCustomIsReachable):
1205         (GenerateGetOwnPropertySlotBody):
1206         (GenerateGetOwnPropertyDescriptorBody):
1207         (GenerateHeaderContentHeader):
1208         (GenerateImplementationContentHeader):
1209         (ShouldGenerateToJSDeclaration):
1210         (ShouldGenerateToJSImplementation):
1211         (GenerateHeader):
1212         (GenerateAttributesHashTable):
1213         (GenerateOverloadedFunction):
1214         (GenerateImplementation):
1215         (GenerateArgumentsCountCheck):
1216         (GenerateParametersCheck):
1217         (GenerateCallbackHeader):
1218         (GenerateCallbackImplementation):
1219         (WriteData):
1220         (GenerateConstructorDeclaration):
1221         (GenerateConstructorDefinition):
1222         (IsConstructable):
1223
1224 2012-11-19  Adam Barth  <abarth@webkit.org>
1225
1226         [V8] Merge getCachedWrapper(Node*) into DOMDataStore
1227         https://bugs.webkit.org/show_bug.cgi?id=102158
1228
1229         Reviewed by Eric Seidel.
1230
1231         This patch is an incremental step towards fully merging the Node code
1232         path with the general code path. After this patch, at least Nodes flow
1233         through the same class.
1234
1235         * Modules/indexeddb/IDBTransactionCoordinator.h:
1236         * bindings/scripts/CodeGeneratorV8.pm:
1237         (GenerateHeader):
1238         (GenerateToV8Converters):
1239         * bindings/v8/DOMDataStore.h:
1240         (WebCore::DOMDataStore::getNode):
1241         (DOMDataStore):
1242         (WebCore::DOMDataStore::getWrapperFromObject):
1243         * bindings/v8/DOMWrapperWorld.cpp:
1244         (WebCore::DOMWrapperWorld::DOMWrapperWorld):
1245         (WebCore):
1246         * bindings/v8/DOMWrapperWorld.h:
1247         (WebCore):
1248         (DOMWrapperWorld):
1249         * bindings/v8/V8DOMWrapper.h:
1250         (V8DOMWrapper):
1251
1252 2012-11-19  Kentaro Hara  <haraken@chromium.org>
1253
1254         In the IDL parser, we should rename $dataNode to $interface
1255         https://bugs.webkit.org/show_bug.cgi?id=102746
1256
1257         Reviewed by Adam Barth.
1258
1259         $dataNode is misnamed. It should be $interface.
1260
1261         No tests. No change in behavior.
1262
1263         * bindings/scripts/IDLParser.pm:
1264         (parseInterface):
1265         (parseException):
1266         (parseAttributeOrOperationRest):
1267         (parseOperationOrIterator):
1268         (parseSpecialOperation):
1269         (parseInterfaceOld):
1270         (parseExceptionOld):
1271         (parseAttributeOrOperationOrIteratorOld):
1272         (parseAttributeOrOperationRestOld):
1273         (applyMemberList):
1274         (applyExtendedAttributeList):
1275         * bindings/scripts/generate-bindings.pl:
1276         * bindings/scripts/preprocess-idls.pl:
1277         (checkIDLAttributes):
1278
1279 2012-11-19  Adam Klein  <adamk@chromium.org>
1280
1281         MutationObserver wrapper should not be collected while still observing
1282         https://bugs.webkit.org/show_bug.cgi?id=102328
1283
1284         Reviewed by Adam Barth.
1285
1286         Use the new opaqueRootForGC helper in V8GCController to put each
1287         MutationObserver wrapper in the same object group as the nodes it's
1288         observing.
1289
1290         Only includes V8 impl for now, JSC impl coming soon.
1291
1292         Tests: fast/mutation/observer-wrapper-dropoff-transient.html
1293                fast/mutation/observer-wrapper-dropoff.html
1294
1295         * bindings/v8/V8GCController.cpp: Add custom code for MutationObserver
1296         with a FIXME to move this out once we update the opaque roots API.
1297         * dom/MutationObserver.cpp:
1298         (WebCore::MutationObserver::getObservedNodes): Plumbing to expose the observed nodes
1299         to the GC controller.
1300         (WebCore):
1301         * dom/MutationObserver.h:
1302         * dom/MutationObserverRegistration.cpp:
1303         (WebCore::MutationObserverRegistration::addRegistrationNodesToSet): More plumbing.
1304         (WebCore):
1305         * dom/MutationObserverRegistration.h:
1306         (MutationObserverRegistration):
1307
1308 2012-11-19  Tony Chang  <tony@chromium.org>
1309
1310         Move more non-settings out of InternalSettings
1311         https://bugs.webkit.org/show_bug.cgi?id=102711
1312
1313         Reviewed by Adam Barth.
1314
1315         Remove userPreferredLanguages, setUserPreferredLanguages and allowRoundingHacks
1316         from internal.settings since they are already exposed by window.internals (in
1317         fact, no one calls the internal.settings version).
1318
1319         Move setUsesOverlayScrollbars from internals.settings to internals because it is
1320         a global (static) setting and not tied to the lifetime of the Settings object.
1321
1322         No new tests, there should be no behavior change since this is a refactor.
1323
1324         * testing/InternalSettings.cpp:
1325         (WebCore::InternalSettings::reset): Remove custom reset code.
1326         (WebCore::InternalSettings::setUsesOverlayScrollbars): Add exception code handling to make it more consistent with other settings setters.
1327         * testing/InternalSettings.h:
1328         * testing/InternalSettings.idl: Remove unnecessary methods.
1329         * testing/Internals.cpp:
1330         (WebCore::Internals::resetToConsistentState): Reset userPreferredLanguages, allowRoundingHacks and overlay scrollbars.
1331         (WebCore::Internals::userPreferredLanguages): Don't go through InternalSettings.
1332         (WebCore::Internals::setUserPreferredLanguages): Don't go through InternalSettings.
1333         (WebCore::Internals::setUsesOverlayScrollbars): Moved from InternalsSettings.
1334         (WebCore::Internals::allowRoundingHacks): Don't go through InternalSettings.
1335
1336 2012-11-19  David Grogan  <dgrogan@chromium.org>
1337
1338         IndexedDB: Complex series of opens/deleteDatabase fails an ASSERT
1339         https://bugs.webkit.org/show_bug.cgi?id=101810
1340
1341         Reviewed by Tony Chang.
1342
1343         Tests - storage/indexeddb/deletedatabase-delayed-by-versionchange.html
1344
1345         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
1346         (WebCore::IDBDatabaseBackendImpl::processPendingCalls):
1347         The condition tested by this assert is a valid state.
1348
1349 2012-11-19  Peter Wang  <peter.wang@torchmobile.com.cn>
1350
1351         Web Inspector: [JSC] worker debugger shouldn't stop for "willExecuteProgram" instruction
1352         https://bugs.webkit.org/show_bug.cgi?id=102637
1353
1354         Reviewed by Timothy Hatcher.
1355
1356         Override the interface "willExecuteProgram" to let WorkerScriptDebugServer to avoid to stop for it.
1357
1358         No new DRT test case. Sorry, so far it seems impossible to write a case to controle the popupped
1359         worker inspector window.
1360
1361         * bindings/js/ScriptDebugServer.cpp:
1362         (WebCore::ScriptDebugServer::createCallFrame):
1363         (WebCore::ScriptDebugServer::callEvent):
1364         (WebCore::ScriptDebugServer::willExecuteProgram):
1365         * bindings/js/ScriptDebugServer.h:
1366         (ScriptDebugServer):
1367         * bindings/js/WorkerScriptDebugServer.cpp:
1368         (WebCore::WorkerScriptDebugServer::willExecuteProgram):
1369         (WebCore):
1370         * bindings/js/WorkerScriptDebugServer.h:
1371         (WorkerScriptDebugServer):
1372
1373 2012-11-19  Pratik Solanki  <psolanki@apple.com>
1374
1375         For single element arrays use the pointer into the CFDataRef instead of copying data
1376         https://bugs.webkit.org/show_bug.cgi?id=102306
1377
1378         Reviewed by Brent Fulgham.
1379
1380         Address review comments for slightly nicer code.
1381
1382         * platform/SharedBuffer.cpp:
1383         (WebCore::SharedBuffer::data):
1384         * platform/cf/SharedBufferCF.cpp:
1385         (WebCore::SharedBuffer::singleDataArrayBuffer):
1386
1387 2012-11-19  Chris Rogers  <crogers@google.com>
1388
1389         Remove empirical bass-boost for HRTF spatialization
1390         https://bugs.webkit.org/show_bug.cgi?id=102745
1391
1392         Reviewed by Kenneth Russell.
1393
1394         Some empirically-based post-processing is being removed so that we'll
1395         now process with the exact HRTF impulse response measurements.
1396         Listening tests have determined that this post-processing is not necessary.
1397
1398         * platform/audio/HRTFElevation.cpp:
1399         (WebCore::HRTFElevation::calculateKernelsForAzimuthElevation):
1400         * platform/audio/HRTFKernel.cpp:
1401         (WebCore::HRTFKernel::HRTFKernel):
1402         * platform/audio/HRTFKernel.h:
1403         (WebCore::HRTFKernel::create):
1404         (HRTFKernel):
1405
1406 2012-11-19  Adam Barth  <abarth@webkit.org>
1407
1408         DISALLOW_COPY_AND_ASSIGN is not a WebKit macro
1409         https://bugs.webkit.org/show_bug.cgi?id=102755
1410
1411         Reviewed by Sam Weinig.
1412
1413         WTF_MAKE_NONCOPYABLE is the idiom we use in WebKit.  I don't understand
1414         how this compiles.
1415
1416         * Modules/indexeddb/IDBBackingStore.h:
1417         (RecordIdentifier):
1418
1419 2012-11-19  Chris Rogers  <crogers@google.com>
1420
1421         Implement .detune attribute for BiquadFilterNode
1422         https://bugs.webkit.org/show_bug.cgi?id=102737
1423
1424         Reviewed by Kenneth Russell.
1425
1426         Similar to OscillatorNode, BiquadFilterNode must have a .detune attribute
1427
1428         Tests changed: webaudio/biquad-lowpass.html
1429
1430         * Modules/webaudio/BiquadDSPKernel.cpp:
1431         (WebCore::BiquadDSPKernel::updateCoefficientsIfNecessary):
1432         * Modules/webaudio/BiquadFilterNode.h:
1433         (WebCore::BiquadFilterNode::detune):
1434         * Modules/webaudio/BiquadFilterNode.idl:
1435         * Modules/webaudio/BiquadProcessor.cpp:
1436         (WebCore::BiquadProcessor::BiquadProcessor):
1437         (WebCore::BiquadProcessor::checkForDirtyCoefficients):
1438         * Modules/webaudio/BiquadProcessor.h:
1439         (WebCore::BiquadProcessor::parameter4):
1440         (BiquadProcessor):
1441
1442 2012-11-19  Patrick Gansterer  <paroga@webkit.org>
1443
1444         [WIN] Add WebCore::getRegistryValue()
1445         https://bugs.webkit.org/show_bug.cgi?id=97828
1446
1447         Reviewed by Brent Fulgham.
1448
1449         The new function adds an abstraction to SHGetValue(), which isn't available on WinCE.
1450         Changing the existing files allows us to share more code between WinCE and WinNT in a next step.
1451
1452         * platform/win/MIMETypeRegistryWin.cpp:
1453         (WebCore::mimeTypeForExtension):
1454         (WebCore):
1455         (WebCore::MIMETypeRegistry::getPreferredExtensionForMIMEType):
1456         * platform/win/WindowsExtras.h:
1457         (WebCore::getRegistryValue):
1458         (WebCore):
1459         * plugins/win/PluginDatabaseWin.cpp:
1460         (WebCore::addPluginPathsFromRegistry):
1461         (WebCore::addWindowsMediaPlayerPluginDirectory):
1462         (WebCore::addQuickTimePluginDirectory):
1463         (WebCore::addAdobeAcrobatPluginDirectory):
1464         (WebCore::addJavaPluginDirectory):
1465
1466 2012-11-19  Alpha Lam  <hclam@chromium.org>
1467
1468         Not reviewed. Build fix for Chromium.
1469
1470         Added SkTypes.h includes for Windows.
1471
1472         * platform/graphics/chromium/ImageDecodingStore.h:
1473         * platform/graphics/chromium/ImageFrameGenerator.h:
1474         * platform/graphics/chromium/LazyDecodingPixelRef.h:
1475
1476 2012-11-19  Adam Barth  <abarth@webkit.org>
1477
1478         [V8] Simplify V8DOMWindowShell::getEntered
1479         https://bugs.webkit.org/show_bug.cgi?id=102156
1480
1481         Reviewed by Eric Seidel.
1482
1483         This patch is an incremental step towards merging
1484         V8DOMWrapper::getCachedWrapper(Node*) with the general case for looking
1485         up DOM wrappers. In order to merge with the general case, we need to
1486         get down to calling v8::Context::GetCurrent once, which means we need
1487         to factor the call to v8::Context::GetEntered out of V8DOMWindowShell.
1488
1489         As a side-benefit to this change, we can remove some redundant checks
1490         for isolatedWorldsExist and v8::Context::InContext from callers of
1491         V8DOMWindowShell::getEntered, including in getCachedWrapper.
1492
1493         * bindings/v8/DOMDataStore.cpp:
1494         (WebCore::DOMDataStore::current):
1495         * bindings/v8/ScriptController.cpp:
1496         (WebCore::ScriptController::shouldBypassMainWorldContentSecurityPolicy):
1497         (WebCore::ScriptController::currentWorldContext):
1498         * bindings/v8/V8DOMWindowShell.h:
1499         (WebCore::V8DOMWindowShell::isolated):
1500         (WebCore::V8DOMWindowShell::perContextData):
1501         (WebCore::V8DOMWindowShell::world):
1502         (V8DOMWindowShell):
1503         * bindings/v8/V8DOMWrapper.h:
1504         (WebCore::V8DOMWrapper::getCachedWrapper):
1505         * bindings/v8/WorldContextHandle.cpp:
1506         (WebCore::WorldContextHandle::WorldContextHandle):
1507         * bindings/v8/custom/V8DocumentCustom.cpp:
1508         (WebCore::V8Document::dispatchWrapCustom):
1509         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
1510         (WebCore::V8HTMLDocument::dispatchWrapCustom):
1511         * bindings/v8/custom/V8SVGDocumentCustom.cpp:
1512         (WebCore::V8SVGDocument::dispatchWrapCustom):
1513         * bindings/v8/custom/V8XMLHttpRequestConstructor.cpp:
1514         (WebCore::V8XMLHttpRequest::constructorCallback):
1515
1516 2012-11-19  Kentaro Hara  <haraken@chromium.org>
1517
1518         Rename idlDocument::classes to idlDocument::interfaces in the IDL parser
1519         https://bugs.webkit.org/show_bug.cgi?id=102671
1520
1521         Reviewed by Adam Barth.
1522
1523         Most part of code generators use 'interface'. The spec uses 'interface'.
1524         Thus, the IDL parser should use 'interface' instead of 'class'.
1525
1526         No tests. No change in behavior.
1527
1528         * bindings/scripts/CodeGenerator.pm:
1529         (ProcessDocument):
1530         (AddMethodsConstantsAndAttributesFromParentInterfaces):
1531         (ParseInterface):
1532         * bindings/scripts/CodeGeneratorCPP.pm:
1533         (GenerateImplementation):
1534         * bindings/scripts/CodeGeneratorJS.pm:
1535         (GenerateHeader):
1536         * bindings/scripts/CodeGeneratorObjC.pm:
1537         (GenerateImplementation):
1538         * bindings/scripts/CodeGeneratorV8.pm:
1539         (GenerateHeader):
1540         (GenerateFunctionCallback):
1541         * bindings/scripts/IDLParser.pm:
1542         (Parse):
1543         (parseModule):
1544         * bindings/scripts/generate-bindings.pl:
1545
1546 2012-11-19  Eric Carlson  <eric.carlson@apple.com>
1547
1548         HTMLMediaElement::configureTextTracks should configure all text tracks
1549         https://bugs.webkit.org/show_bug.cgi?id=102561
1550
1551         Reviewed by Philippe Normand.
1552
1553         No new tests, track-mode-not-changed-by-new-track.html was updated to test the changes.
1554
1555         * html/HTMLMediaElement.cpp:
1556         (WebCore::HTMLMediaElement::textTrackModeChanged): HTMLTrackElement -> TextTrack.
1557         (WebCore::HTMLMediaElement::willRemoveTrack): Ditto.
1558         (WebCore::HTMLMediaElement::configureTextTrackGroup): Ditto.
1559         (WebCore::HTMLMediaElement::configureTextTracks): Ditto.
1560         (WebCore::HTMLMediaElement::markCaptionAndSubtitleTracksAsUnconfigured): Ditto.
1561         * html/HTMLMediaElement.h:
1562
1563         * html/HTMLTrackElement.cpp:
1564         (WebCore::HTMLTrackElement::HTMLTrackElement): Move hasBeenConfigured down to TextTrack.
1565         (WebCore::HTMLTrackElement::parseAttribute): isDefault is stored on TextTrack.
1566         (WebCore::HTMLTrackElement::ensureTrack): LoadableTextTrack constructor doesn't take 
1567             "default" argument.
1568         * html/HTMLTrackElement.h:
1569
1570         * html/track/LoadableTextTrack.cpp:
1571         (WebCore::LoadableTextTrack::LoadableTextTrack): Initialize m_isDefault to false.
1572         * html/track/LoadableTextTrack.h: 
1573         (WebCore::TextTrack::isDefault): Override base class implementation, because a track element
1574             can be flagged as default.
1575         (WebCore::TextTrack::setIsDefault): Ditto.
1576
1577         * html/track/TextTrack.cpp:
1578         (WebCore::TextTrack::TextTrack): Initialize m_hasBeenConfigured.
1579         * html/track/TextTrack.h:
1580         (WebCore::TextTrack::hasBeenConfigured): New, moved from HTMLTrackElement so other code doesn't
1581             need know what type of track it is calling.
1582         (WebCore::TextTrack::setHasBeenConfigured): Ditto.
1583         (WebCore::TextTrack::isDefault): Base, do nothing, implementation because only LoadableTextTrack
1584             can be "default".
1585         (WebCore::TextTrack::setIsDefault): Ditto.
1586
1587 2012-11-19  Huang Dongsung  <luxtella@company100.net>
1588
1589         Coordinated Graphics: refactor syncCanvas to handle the lifecycle clearly.
1590         https://bugs.webkit.org/show_bug.cgi?id=102664
1591
1592         Reviewed by Noam Rosenthal.
1593
1594         As refactoring Coordinated Graphics in WebKit2, code related to
1595         TextureMapper is changed.
1596
1597         No new tests. Refactoring only.
1598
1599         * platform/graphics/qt/GraphicsContext3DQt.cpp:
1600         (GraphicsContext3DPrivate):
1601         (WebCore::GraphicsContext3DPrivate::platformLayerSize):
1602             We need to know the size of a texture mapper platform layer.
1603         (WebCore):
1604         * platform/graphics/texmap/TextureMapperBackingStore.cpp:
1605           Because CoordinatedGraphicsLayer handles the canvas GraphicsSurface
1606           lifecycle, TextureMapperSurfaceBackingStore does not need to know
1607           GraphicsSurfaceToken.
1608         (WebCore::TextureMapperSurfaceBackingStore::setGraphicsSurface):
1609         (WebCore::TextureMapperSurfaceBackingStore::swapBuffersIfNeeded):
1610         (WebCore::TextureMapperSurfaceBackingStore::paintToTextureMapper):
1611         * platform/graphics/texmap/TextureMapperBackingStore.h:
1612         (TextureMapperSurfaceBackingStore):
1613         * platform/graphics/texmap/TextureMapperPlatformLayer.h:
1614         (WebCore::TextureMapperPlatformLayer::platformLayerSize):
1615
1616 2012-11-19  Alpha Lam  <hclam@chromium.org>
1617
1618         [chromium] Lazy image decoding without cache
1619         https://bugs.webkit.org/show_bug.cgi?id=102021
1620
1621         Reviewed by Stephen White.
1622
1623         Goal of this change is to make image decoding in ImageFrameGenerator
1624         completely lazy without caching. Image decoding logic is then removed
1625         from ImageDecodingStore.
1626
1627         These methods are removed.
1628         - ImageDecodingStore::lockPixels
1629         - ImageDecodingStore::unlockPixels
1630
1631         Instead image decoding and scaling is done in
1632         ImageFrameGenerator::decodeAndScale().
1633
1634         Unit tests are updated:
1635         DeferredImageDecoderTest::drawIntoSkPicture
1636         DeferredImageDecoderTest::drawScaledIntoSkPicture
1637
1638         Also covered by layout tests:
1639         platform/chromium/virtual/deferred
1640
1641         * platform/graphics/chromium/DeferredImageDecoder.cpp:
1642         (WebCore::DeferredImageDecoder::createLazyDecodingBitmap):
1643         * platform/graphics/chromium/ImageDecodingStore.h:
1644         (ImageDecodingStore):
1645         * platform/graphics/chromium/ImageFrameGenerator.cpp:
1646         (WebCore::ImageFrameGenerator::ImageFrameGenerator):
1647         (WebCore::ImageFrameGenerator::~ImageFrameGenerator):
1648         (WebCore::ImageFrameGenerator::setData):
1649         (WebCore::ImageFrameGenerator::decodeAndScale):
1650         * platform/graphics/chromium/ImageFrameGenerator.h:
1651         (WebCore::ImageFrameGenerator::create):
1652         (ImageFrameGenerator):
1653         * platform/graphics/chromium/LazyDecodingPixelRef.cpp:
1654         (WebCore::LazyDecodingPixelRef::onLockPixels):
1655         (WebCore::LazyDecodingPixelRef::onUnlockPixels):
1656         * platform/graphics/chromium/LazyDecodingPixelRef.h:
1657         (LazyDecodingPixelRef):
1658
1659 2012-11-19  Abhishek Arya  <inferno@chromium.org>
1660
1661         Crash in ApplyStyleCommand::cleanupUnstyledAppleStyleSpans.
1662         https://bugs.webkit.org/show_bug.cgi?id=100150
1663
1664         Reviewed by Ryosuke Niwa.
1665
1666         RefPtr startDummySpanAncestor and endDummySpanAncestor since
1667         they can go away inside fixRangeAndApplyInlineStyle call.
1668
1669         Test: editing/style/apply-style-crash.html
1670
1671         * editing/ApplyStyleCommand.cpp:
1672         (WebCore::ApplyStyleCommand::applyInlineStyle):
1673
1674 2012-11-19  Sheriff Bot  <webkit.review.bot@gmail.com>
1675
1676         Unreviewed, rolling out r135172.
1677         http://trac.webkit.org/changeset/135172
1678         https://bugs.webkit.org/show_bug.cgi?id=102710
1679
1680         Broke some WebKit2 api tests :( (Requested by japhet on
1681         #webkit).
1682
1683         * loader/DocumentLoader.cpp:
1684         (WebCore::DocumentLoader::DocumentLoader):
1685         (WebCore::DocumentLoader::~DocumentLoader):
1686         (WebCore::DocumentLoader::finishedLoading):
1687         (WebCore::DocumentLoader::clearMainResourceLoader):
1688         (WebCore::DocumentLoader::isLoadingInAPISense):
1689         (WebCore::DocumentLoader::documentURL):
1690         (WebCore::DocumentLoader::isLoadingMainResource):
1691         (WebCore::DocumentLoader::startLoadingMainResource):
1692         * loader/DocumentLoader.h:
1693         (DocumentLoader):
1694         * loader/FrameLoader.cpp:
1695         (WebCore::FrameLoader::FrameLoader):
1696         (WebCore::FrameLoader::init):
1697         * loader/FrameLoaderStateMachine.cpp:
1698         (WebCore::FrameLoaderStateMachine::FrameLoaderStateMachine):
1699         * loader/FrameLoaderStateMachine.h:
1700         * loader/MainResourceLoader.cpp:
1701         (WebCore::shouldLoadAsEmptyDocument):
1702         (WebCore):
1703         (WebCore::MainResourceLoader::continueAfterContentPolicy):
1704         (WebCore::MainResourceLoader::didReceiveResponse):
1705         (WebCore::MainResourceLoader::didFinishLoading):
1706         (WebCore::MainResourceLoader::handleEmptyLoad):
1707         (WebCore::MainResourceLoader::loadNow):
1708         (WebCore::MainResourceLoader::load):
1709         * loader/MainResourceLoader.h:
1710         (MainResourceLoader):
1711
1712 2012-11-19  Tony Chang  <tony@chromium.org>
1713
1714         Remove 'is' prefix from WebSettings::isWebSecurityEnabled and WebSettings::isSpatialNavigationEnabled
1715         https://bugs.webkit.org/show_bug.cgi?id=102548
1716
1717         Reviewed by Adam Barth.
1718
1719         This allows us to use Settings.in to generate the code for this.
1720
1721         I didn't rename any of the WebKit API methods with similar names because that would
1722         probably break consumers.  It turns out that the getter is only called from
1723         Source/WebKit/efl (most of the time, WebPreferences just sets values on Settings).
1724
1725         No new tests, just a refactor.
1726
1727         * WebCore.exp.in: Remove symbols that are now inlined.
1728         * WebCore.order: Remove symbols that are now inlined.
1729         * dom/Document.cpp:
1730         (WebCore::Document::initSecurityContext): Rename.
1731         * page/Settings.cpp:
1732         (WebCore::Settings::Settings): Remove code since it will be generated.
1733         * page/Settings.h:
1734         (Settings): Remove code since it will be generated.
1735         * page/Settings.in: Add entries to be generated.
1736         * page/SpatialNavigation.cpp:
1737         (WebCore::isSpatialNavigationEnabled): Fix caller.
1738
1739 2012-11-19  Yael Aharon  <yael.aharon@intel.com>
1740
1741         [EFL][TexMap] Complie error when considering warnings as errors
1742         https://bugs.webkit.org/show_bug.cgi?id=102705
1743
1744         Reviewed by Kenneth Rohde Christiansen.
1745
1746         Change GaussianKernelHalfWidth to unsigned.
1747
1748         No new tests.
1749
1750         * platform/graphics/texmap/TextureMapperGL.cpp:
1751         (WebCore):
1752
1753 2012-11-19  Sheriff Bot  <webkit.review.bot@gmail.com>
1754
1755         Unreviewed, rolling out r134830.
1756         http://trac.webkit.org/changeset/134830
1757         https://bugs.webkit.org/show_bug.cgi?id=102701
1758
1759         ActiveDOMObject is not applicable to MutationObservers due to
1760         being tied to a Document (Requested by aklein on #webkit).
1761
1762         * bindings/js/JSMutationObserverCustom.cpp:
1763         (WebCore::JSMutationObserverConstructor::constructJSMutationObserver):
1764         * bindings/v8/custom/V8MutationObserverCustom.cpp:
1765         (WebCore::V8MutationObserver::constructorCallback):
1766         * dom/MutationObserver.cpp:
1767         (WebCore::MutationObserver::create):
1768         (WebCore::MutationObserver::MutationObserver):
1769         (WebCore::MutationObserver::observationStarted):
1770         (WebCore::MutationObserver::observationEnded):
1771         * dom/MutationObserver.h:
1772         (WebCore):
1773         * dom/MutationObserver.idl:
1774
1775 2012-11-19  Brady Eidson  <beidson@apple.com>
1776
1777         NetworkProcess Authentication.
1778         https://bugs.webkit.org/show_bug.cgi?id=102592
1779
1780         Reviewed by Alexey Proskuryakov.
1781
1782         Change an ASSERT that assumes there should be a resource handle which is not true with the NetworkProcess.
1783
1784         Also export some more stuff.
1785
1786         No new tests (Platform support, no effect in tested configs).
1787
1788         * WebCore.exp.in:
1789
1790         * loader/ResourceLoader.cpp:
1791         (WebCore::ResourceLoader::didReceiveAuthenticationChallenge): Only ASSERT that the handle has a challenge if
1792           there is a handle.
1793
1794 2012-11-19  Alec Flett  <alecflett@chromium.org>
1795
1796         IndexedDB: simplify RecordIdentifier
1797         https://bugs.webkit.org/show_bug.cgi?id=102018
1798
1799         Reviewed by Tony Chang.
1800
1801         Make IDBBackingStore's RecordIdentifier be a simple
1802         class, existing only as an inline or stack-based instance.
1803         This makes much of the copy semantics more explicit, and
1804         removes refcounting from an object that only ever had a refcount
1805         of 1 or 2.
1806
1807         No new tests, just a refactor.
1808
1809         * Modules/indexeddb/IDBBackingStore.cpp:
1810         (WebCore::IDBBackingStore::putRecord):
1811         (WebCore::IDBBackingStore::deleteRecord):
1812         (WebCore::IDBBackingStore::maybeUpdateKeyGeneratorCurrentNumber):
1813         (WebCore::IDBBackingStore::keyExistsInObjectStore):
1814         (WebCore::IDBBackingStore::putIndexDataForRecord):
1815         (WebCore::IDBBackingStore::deleteIndexDataForRecord):
1816         (WebCore::ObjectStoreKeyCursorImpl::loadCurrentRow):
1817         (ObjectStoreCursorImpl):
1818         (WebCore::ObjectStoreCursorImpl::loadCurrentRow):
1819         (WebCore::IndexKeyCursorImpl::recordIdentifier):
1820         (WebCore::IndexCursorImpl::recordIdentifier):
1821         * Modules/indexeddb/IDBBackingStore.h:
1822         (WebCore::IDBBackingStore::RecordIdentifier::RecordIdentifier):
1823         (WebCore::IDBBackingStore::RecordIdentifier::isValid):
1824         (WebCore::IDBBackingStore::RecordIdentifier::reset):
1825         (RecordIdentifier):
1826         (IDBBackingStore):
1827         (WebCore::IDBBackingStore::Cursor::recordIdentifier):
1828         (WebCore::IDBBackingStore::Cursor::Cursor):
1829         (Cursor):
1830         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
1831         (WebCore):
1832         (WebCore::IDBObjectStoreBackendImpl::setIndexKeys):
1833         (WebCore::IDBObjectStoreBackendImpl::putInternal):
1834         (WebCore::IDBObjectStoreBackendImpl::deleteInternal):
1835
1836 2012-11-19  Alexander Shalamov  <alexander.shalamov@intel.com>
1837
1838         Improve ContentTypeParser, so that it could be used to validate mime type according to RFC
1839         https://bugs.webkit.org/show_bug.cgi?id=100927
1840
1841         Reviewed by Alexey Proskuryakov.
1842
1843         This patch adds ParsedContentType class that represents contents of parsed
1844         content type string. isValidContentType function could be used to check if
1845         format of the content type string is acorrding to RFC 2616 section 4.2.
1846
1847         * CMakeLists.txt:
1848         * GNUmakefile.list.am:
1849         * Target.pri:
1850         * WebCore.gypi:
1851         * WebCore.xcodeproj/project.pbxproj:
1852         * platform/network/MIMEHeader.cpp:
1853         (WebCore::MIMEHeader::parseHeader):
1854         * platform/network/ParsedContentType.cpp: Renamed from Source/WebCore/platform/network/ContentTypeParser.cpp.
1855         (WebCore):
1856         (EmptyParsedContentType):
1857         (WebCore::EmptyParsedContentType::setContentType):
1858         (WebCore::EmptyParsedContentType::setContentTypeParameter):
1859         (WebCore::skipSpaces):
1860         (WebCore::isTokenCharacter):
1861         (WebCore::parseToken):
1862         (WebCore::parseQuotedString):
1863         (WebCore::substringForRange):
1864         (WebCore::parseContentType):
1865         (WebCore::isValidContentType):
1866         (WebCore::ParsedContentType::ParsedContentType):
1867         (WebCore::ParsedContentType::charset):
1868         (WebCore::ParsedContentType::parameterValueForName):
1869         (WebCore::ParsedContentType::parameterCount):
1870         (WebCore::ParsedContentType::setContentType):
1871         (WebCore::ParsedContentType::setContentTypeParameter):
1872         * platform/network/ParsedContentType.h: Renamed from Source/WebCore/platform/network/ContentTypeParser.h.
1873         (WebCore):
1874         (ParsedContentType):
1875         (WebCore::ParsedContentType::mimeType):
1876
1877 2012-11-19  Erik Arvidsson  <arv@chromium.org>
1878
1879         Update DOMException name: InvalidNodeTypeError
1880         https://bugs.webkit.org/show_bug.cgi?id=102519
1881
1882         Reviewed by Kentaro Hara.
1883
1884         Patch 24 of 25 to update DOMException name to match the spec and Firefox.
1885
1886         No code uses DOMException InvalidNodeTypeError. We do use INVALID_NODE_TYPE_ERR for RangeException. See bug 102515.
1887
1888         * dom/DOMCoreException.cpp:
1889
1890 2012-11-19  Shinya Kawanaka  <shinyak@chromium.org>
1891
1892         Changing id, className, or attribute should invalidate distribution
1893         https://bugs.webkit.org/show_bug.cgi?id=100738
1894
1895         Reviewed by Dimitri Glazkov.
1896
1897         When id, className, or attribute is changed, we might have to invalidate distribution.
1898         However, we don't want to do useless invalidation. So we consult with the RuleFeatureSet of ElementShadow
1899         to invalidate distribution only if necessary.
1900
1901         For the code that className is changed, we can share a lot of code between invalidating distribution and
1902         invalidating style. So we made checkNeedsStyleInvalidationForClassChange a template method, and share it.
1903
1904         Since attributeChanged() is a hot method, we don't want to make it slow. So we made one function to determine
1905         whether we have to invalidate distribution, and make it called only if necessary. Also, we've optimized
1906         shadowOfParentForDistribution() by making isInsertionPoint() de-virtualed. We consuded NodeFlags (IsInsertionPointFlag)
1907         for this purpose.
1908
1909         We've measured how this patch makes changing attribute slow. I've measured each code 3 times.
1910         DOM/ModifyAttribute.html is a micro benchmark which changes attribute a lot of times. The result of this benchmark
1911         will be the most affected by this patch. However, it's only 2% performance regression.
1912
1913         DOM/ModifyAttribute.html
1914         Before this patch:
1915                 median  stdev    min    max    [ms]
1916           1st    494.0   3.36  490.0  502.0
1917           2nd    503.5   3.44  497.0  512.0
1918           3rd    494.0   3.48  488.0  499.0
1919
1920         After this patch:
1921                 median  stdev  min      max    [ms]
1922           1st    504.0   2.00  501.0  509.0
1923           2nd    505.5   3.08  500.0  513.0
1924           3rd    507.0   2.32  502.0  510.0
1925
1926         Tests: fast/dom/shadow/distribution-attribute-modified.html
1927                fast/dom/shadow/distribution-className-modified.html
1928                fast/dom/shadow/distribution-id-modified.html
1929                fast/dom/shadow/reprojection-attribute-modified.html
1930                fast/dom/shadow/reprojection-className-modified.html
1931                fast/dom/shadow/reprojection-id-modified.html
1932
1933         * dom/Element.cpp:
1934         (WebCore::Element::attributeChanged):
1935         (WebCore::HasSelectorForClassStyleFunctor::HasSelectorForClassStyleFunctor):
1936         (HasSelectorForClassStyleFunctor):
1937         (WebCore::HasSelectorForClassStyleFunctor::operator()): Returns true if StyleResolver::hasSelectorForClass returns true.
1938         (WebCore):
1939         (WebCore::HasSelectorForClassDistributionFunctor::HasSelectorForClassDistributionFunctor):
1940         (HasSelectorForClassDistributionFunctor):
1941         (WebCore::HasSelectorForClassDistributionFunctor::operator()): Returns true if ElementShadow::hasSelectForClass returns true.
1942         (WebCore::checkFunctorForClassChange):
1943         (WebCore::checkNeedsStyleInvalidationForClassChange):
1944         (WebCore::checkNeedsDistributionInvalidationForClassChange): Extracted the implementation to checkFunctorForClassChange.
1945         (WebCore::Element::shouldInvalidateDistributionWhenAttributeChanged):
1946         * dom/Element.h:
1947         (Element):
1948         * dom/Node.h:
1949         (WebCore::Node::isInsertionPoint):
1950         * html/HTMLElement.h:
1951         (HTMLElement):
1952         * html/shadow/InsertionPoint.cpp:
1953         (WebCore::InsertionPoint::InsertionPoint):
1954         * html/shadow/InsertionPoint.h:
1955         (InsertionPoint):
1956         (WebCore::isInsertionPoint):
1957         (WebCore::shadowOfParentForDistribution):
1958         (WebCore::resolveReprojection):
1959
1960 2012-11-19  Nate Chapin  <japhet@chromium.org>
1961
1962         Move empty loading to DocumentLoader, simplify FrameLoader::init()
1963         https://bugs.webkit.org/show_bug.cgi?id=101512
1964
1965         Reviewed by Adam Barth.
1966
1967         No new tests, though several outputs changed because we no longer send resource
1968             load callbacks for empty loads.
1969
1970         * loader/DocumentLoader.cpp:
1971         (WebCore::DocumentLoader::DocumentLoader):
1972         (WebCore::DocumentLoader::~DocumentLoader):
1973         (WebCore::DocumentLoader::finishedLoading):
1974         (WebCore::DocumentLoader::clearMainResourceLoader):
1975         (WebCore::DocumentLoader::isLoadingInAPISense):
1976         (WebCore::DocumentLoader::isLoadingMainResource):
1977         (WebCore::DocumentLoader::maybeLoadEmpty):
1978         (WebCore):
1979         (WebCore::DocumentLoader::startLoadingMainResource): Handle empty main resource
1980              loads directly here.
1981         * loader/DocumentLoader.h:
1982         (DocumentLoader):
1983         * loader/FrameLoader.cpp:
1984         (WebCore::FrameLoader::FrameLoader): Initialize some variables whose values
1985             were previously being reset in init(). Given that the FrameLoader is in
1986             an inconsistent state before init() is called anyway, there doesn't seem
1987             to be a disadvantage to just initializing them to their post-init() values.
1988         (WebCore::FrameLoader::init): Just call startLoadingMainResource(), instead of
1989             doing a bunch of direct calls to functions FrameLoader shouldn't know about.
1990         * loader/FrameLoaderStateMachine.cpp:
1991         (WebCore::FrameLoaderStateMachine::FrameLoaderStateMachine):
1992         * loader/FrameLoaderStateMachine.h:
1993         * loader/MainResourceLoader.cpp: Throughout, remove the concept of an empty load.
1994         (WebCore::MainResourceLoader::loadNow): This only returned true when an empty
1995             load got deferred, which won't happen now. Return void and always treat
1996             as returning false.
1997         * loader/MainResourceLoader.h:
1998         (MainResourceLoader):
1999
2000 2012-11-19  Erik Arvidsson  <arv@chromium.org>
2001
2002         Update DOMException name: TimeoutError
2003         https://bugs.webkit.org/show_bug.cgi?id=102513
2004
2005         Reviewed by Kentaro Hara.
2006
2007         Patch 23 of 25 to update DOMException name to match the spec and Firefox.
2008
2009         No code uses DOMException TimeoutError. We do use TIMEOUT_ERR for XMLHttpRequestException. See bug 102506.
2010
2011         * dom/DOMCoreException.cpp:
2012
2013 2012-11-19  Erik Arvidsson  <arv@chromium.org>
2014
2015         Update DOMException name: DataCloneError
2016         https://bugs.webkit.org/show_bug.cgi?id=102521
2017
2018         Reviewed by Kentaro Hara.
2019
2020         Patch 25 of 25 to update DOMException name to match the spec and Firefox.
2021
2022         Updated existing tests.
2023
2024         * dom/DOMCoreException.cpp:
2025
2026 2012-11-19  Tom Hudson  <tomhudson@chromium.org>
2027
2028         Improve performance of RenderBoxModelObject::paintTranslucentBorderSides()
2029         https://bugs.webkit.org/show_bug.cgi?id=98660
2030
2031         Reviewed by Simon Fraser.
2032
2033         Accumulate edges[i].shouldRender() in a flag field and pass that to paintBorderSides()
2034         and paintTranslucentBorderSides() so that we don't do unnecessary work.
2035
2036         If we can avoid setting up and tearing down an unnecessary transparent layer we save
2037         30ms on some mobile platforms.
2038
2039         * rendering/RenderBoxModelObject.h:
2040         * rendering/RenderBoxModelObject.cpp:
2041         (WebCore::RenderBoxModelObject::paintBorder):
2042         (WebCore::RenderBoxModelObject::paintTranslucentBorderSides):
2043
2044 2012-11-19  Hans Muller  <hmuller@adobe.com>
2045
2046         [CSS Exclusions] remove null exclusion shape check from ExclusionShape::createExclusionShape
2047         https://bugs.webkit.org/show_bug.cgi?id=100765
2048
2049         Reviewed by Dirk Schulze.
2050
2051         ExclusionShape::createExclusionShape now ASSERTs that its basicShape argument
2052         isn't null, since the caller is expected to ensure as much.  No new tests were
2053         needed since this is a near-trivial cleanup.
2054
2055         * rendering/ExclusionShape.cpp:
2056         (WebCore::ExclusionShape::createExclusionShape): This method no longer defends against a null basicShape argument by returning null.
2057
2058 2012-11-19  Sami Kyostila  <skyostil@chromium.org>
2059
2060         Use device scale factor instead of physical screen DPI for screen DPI
2061         https://bugs.webkit.org/show_bug.cgi?id=101769
2062
2063         Reviewed by Adam Barth.
2064
2065         Media queries call WebCore::Screen::{horizontal,vertical}DPI() to determine
2066         the dots per CSS inch[1] value for the "screen" media type. On Chromium these
2067         functions currently return the physical screen DPI, which is wrong. To fix
2068         this, we remove both of these functions entirely and make media queries use
2069         the device scale factor multiplied by 96 on all ports.
2070
2071         [1] http://www.w3.org/TR/css3-mediaqueries/#resolution0
2072
2073         * page/Screen.cpp:
2074         (WebCore::Screen::horizontalDPI):
2075         (WebCore::Screen::verticalDPI):
2076         * platform/PlatformScreen.h:
2077         (WebCore):
2078         * platform/blackberry/PlatformScreenBlackBerry.cpp:
2079         * platform/chromium/PlatformScreenChromium.cpp:
2080         * platform/efl/PlatformScreenEfl.cpp:
2081         * platform/gtk/PlatformScreenGtk.cpp:
2082         * platform/mac/PlatformScreenMac.mm:
2083         * platform/qt/PlatformScreenQt.cpp:
2084         * platform/win/PlatformScreenWin.cpp:
2085         * platform/wx/ScreenWx.cpp:
2086
2087 2012-11-19  Julien Chaffraix  <jchaffraix@webkit.org>
2088
2089         Computed grid items' positions shouldn't be using Length
2090         https://bugs.webkit.org/show_bug.cgi?id=102537
2091
2092         Reviewed by Tony Chang.
2093
2094         This change refactors how we store the grid items' position to use
2095         a new type GridPosition. Length was a temporary type as it supported
2096         'auto' | <integer> but it was starting to get more and more confusing
2097         as we were implementing the layout routines.
2098
2099         No change in behavior.
2100
2101         * GNUmakefile.list.am:
2102         * WebCore.gypi:
2103         * WebCore.vcproj/WebCore.vcproj:
2104         * WebCore.xcodeproj/project.pbxproj:
2105         Added the new file to the build systems.
2106
2107         * rendering/style/RenderStyle.h:
2108         Updated after the type change. Also made some getters
2109         return a const reference instead of forcing a copy.
2110
2111         * rendering/style/StyleGridItemData.h:
2112         (StyleGridItemData):
2113         Ditto, also removed a comment about adding a new type.
2114
2115         * css/CSSComputedStyleDeclaration.cpp:
2116         (WebCore::valueForGridPosition):
2117         * css/StyleResolver.cpp:
2118         (WebCore::createGridPosition):
2119         (WebCore::StyleResolver::applyProperty):
2120         * rendering/RenderGrid.cpp:
2121         (WebCore::RenderGrid::resolveGridPosition):
2122         Updated these sites after switching to GridPosition.
2123
2124         * rendering/RenderGrid.h:
2125         Changed resolveGridPosition signature: it now takes a GridPosition.
2126
2127         * rendering/style/GridPosition.h: Added.
2128         (WebCore::GridPosition::GridPosition):
2129         Default constructor, creates an 'auto' position.
2130
2131         (WebCore::GridPosition::isPositive):
2132         (WebCore::GridPosition::type):
2133         (WebCore::GridPosition::isAuto):
2134         (WebCore::GridPosition::setIntegerPosition):
2135         (WebCore::GridPosition::integerPosition):
2136         Helper functions.
2137
2138         (WebCore::GridPosition::operator==):
2139         Required comparison operator for StyleGridItemData.
2140
2141 2012-11-19  Thiago Marcos P. Santos  <thiago.santos@intel.com>
2142
2143         Apply the resolved viewport rules
2144         https://bugs.webkit.org/show_bug.cgi?id=95964
2145
2146         Reviewed by Kenneth Rohde Christiansen.
2147
2148         This patch implements the CSS Device Adaptation specification. The
2149         WebKit implementation relies on the already implemented Viewport Meta
2150         infrastructure to notify the browser of viewport changes.
2151
2152         The implementation was tests with success on the Qt and EFL ports, but
2153         basically every port supporting Viewport Meta should be fine.
2154
2155         The usage of @-webkit-viewport inside media queries (more tests coming
2156         to map all the corner cases) is currently limited when the media query
2157         depends on the viewport dimensions itself. Defining the width and height
2158         based on screen size will fail on ports reporting the screen
2159         size as the size of the browser window instead of the device screen.
2160
2161         Tests: css3/device-adapt/opera/cascading-001.xhtml
2162                css3/device-adapt/opera/cascading-002.xhtml
2163                css3/device-adapt/opera/cascading-003.xhtml
2164                css3/device-adapt/opera/cascading-004.xhtml
2165                css3/device-adapt/opera/constrain-001.xhtml
2166                css3/device-adapt/opera/constrain-002.xhtml
2167                css3/device-adapt/opera/constrain-003.xhtml
2168                css3/device-adapt/opera/constrain-004.xhtml
2169                css3/device-adapt/opera/constrain-005.xhtml
2170                css3/device-adapt/opera/constrain-006.xhtml
2171                css3/device-adapt/opera/constrain-007.xhtml
2172                css3/device-adapt/opera/constrain-008.xhtml
2173                css3/device-adapt/opera/constrain-009.xhtml
2174                css3/device-adapt/opera/constrain-010.xhtml
2175                css3/device-adapt/opera/constrain-011.xhtml
2176                css3/device-adapt/opera/constrain-012.xhtml
2177                css3/device-adapt/opera/constrain-013.xhtml
2178                css3/device-adapt/opera/constrain-014.xhtml
2179                css3/device-adapt/opera/constrain-015.xhtml
2180                css3/device-adapt/opera/constrain-016.xhtml
2181                css3/device-adapt/opera/constrain-017.xhtml
2182                css3/device-adapt/opera/constrain-020.xhtml
2183                css3/device-adapt/opera/syntax-001.xhtml
2184                css3/device-adapt/opera/syntax-002.xhtml
2185                css3/device-adapt/opera/syntax-003.xhtml
2186
2187         * CMakeLists.txt:
2188         * GNUmakefile.list.am:
2189         * Target.pri:
2190         * WebCore.gypi:
2191         * WebCore.vcproj/WebCore.vcproj:
2192         * WebCore.xcodeproj/project.pbxproj:
2193         * css/CSSAllInOne.cpp:
2194         * css/RuleSet.cpp:
2195         (WebCore::RuleSet::addRulesFromSheet):
2196         * css/StyleResolver.cpp:
2197         (WebCore::StyleResolver::StyleResolver):
2198         (WebCore::StyleResolver::appendAuthorStyleSheets):
2199         (WebCore::StyleResolver::~StyleResolver):
2200         * css/StyleResolver.h:
2201         (StyleResolver):
2202         (WebCore::StyleResolver::viewportStyleResolver):
2203         * css/ViewportStyleResolver.cpp: Added.
2204         (WebCore):
2205         (WebCore::ViewportStyleResolver::ViewportStyleResolver):
2206         (WebCore::ViewportStyleResolver::addViewportRule):
2207         (WebCore::ViewportStyleResolver::clearDocument):
2208         (WebCore::ViewportStyleResolver::resolve):
2209         (WebCore::ViewportStyleResolver::getViewportArgumentValue):
2210         * css/ViewportStyleResolver.h: Added.
2211         (WebCore):
2212         (ViewportStyleResolver):
2213         (WebCore::ViewportStyleResolver::create):
2214         * dom/Document.h:
2215         (WebCore::Document::setViewportArguments):
2216         * dom/ViewportArguments.cpp:
2217         (WebCore::compareIgnoringAuto):
2218         (WebCore):
2219         (WebCore::ViewportArguments::resolve):
2220         * dom/ViewportArguments.h:
2221         (ViewportAttributes):
2222         (WebCore::ViewportArguments::ViewportArguments):
2223         (ViewportArguments):
2224         (WebCore::ViewportArguments::operator==):
2225
2226 2012-11-19  Erik Arvidsson  <arv@chromium.org>
2227
2228         Update DOMException name: SecurityError
2229         https://bugs.webkit.org/show_bug.cgi?id=102437
2230
2231         Reviewed by Kentaro Hara.
2232
2233         Patch 18 of 25 to update DOMException name to match the spec and Firefox.
2234
2235         Updated existing tests.
2236
2237         * dom/DOMCoreException.cpp:
2238
2239 2012-11-19  Erik Arvidsson  <arv@chromium.org>
2240
2241         Update DOMException name: URLMismatchError
2242         https://bugs.webkit.org/show_bug.cgi?id=102511
2243
2244         Reviewed by Kentaro Hara.
2245
2246         Patch 21 of 25 to update DOMException name to match the spec and Firefox.
2247
2248         Updated existing tests.
2249
2250         * dom/DOMCoreException.cpp:
2251         (WebCore):
2252
2253 2012-11-19  Kihong Kwon  <kihong.kwon@samsung.com>
2254
2255         Add PROXIMITY_EVENTS feature
2256         https://bugs.webkit.org/show_bug.cgi?id=102658
2257
2258         Reviewed by Kentaro Hara.
2259
2260         Add PROXIMITY_EVENTS feature to xcode project for WebCorei and GNU make.
2261
2262         No new tests. Just add a new feature.
2263
2264         * Configurations/FeatureDefines.xcconfig:
2265         * GNUmakefile.features.am:
2266
2267 2012-11-19  Alexei Filippov  <alph@chromium.org>
2268
2269         Web Inspector: Dim a component's subitems' color in NMI snapshot
2270         https://bugs.webkit.org/show_bug.cgi?id=102224
2271
2272         Reviewed by Yury Semikhatsky.
2273
2274         * inspector/front-end/NativeMemorySnapshotView.js:
2275         (WebInspector.NativeSnapshotNode.prototype._createSizeCell):
2276         * inspector/front-end/nativeMemoryProfiler.css:
2277         (.native-snapshot-view .data-grid .dimmed div.size-bar):
2278
2279 2012-11-19  Erik Arvidsson  <arv@chromium.org>
2280
2281         Update DOMException name: NetworkError
2282         https://bugs.webkit.org/show_bug.cgi?id=102503
2283
2284         Reviewed by Kentaro Hara.
2285
2286         Patch 19 of 25 to update DOMException name to match the spec and Firefox.
2287
2288         No code uses DOMException NetworkError. We do use NETWORK_ERR for XMLHttpRequestException. See bug 102506.
2289
2290         * dom/DOMCoreException.cpp:
2291
2292 2012-11-19  Ilya Tikhonovsky  <loislo@chromium.org>
2293
2294         webaudio: clean-up. Replace AudioContext::m_document member with ContextDestructionObserver::scriptExecutionContext().
2295         https://bugs.webkit.org/show_bug.cgi?id=102649
2296
2297         Reviewed by Adam Barth.
2298
2299         AudioContext uses m_document only as a pointer to ScriptExecutionContext.
2300         It could be safely replaced with ContextDestructionObserver::m_scriptExecutionContext.
2301         The lifetime of m_scriptExecutionContext is slightly different but it could be adjusted by m_isStopScheduled flag.
2302
2303         No new tests as there is no new functionality.
2304
2305         * Modules/webaudio/AudioBufferSourceNode.cpp:
2306         (WebCore::AudioBufferSourceNode::looping):
2307         (WebCore::AudioBufferSourceNode::setLooping):
2308         * Modules/webaudio/AudioContext.cpp:
2309         (WebCore::AudioContext::AudioContext):
2310         (WebCore::AudioContext::stop):
2311         (WebCore::AudioContext::scriptExecutionContext):
2312         (WebCore::AudioContext::fireCompletionEvent):
2313         (WebCore::AudioContext::reportMemoryUsage):
2314         * Modules/webaudio/AudioContext.h:
2315         (AudioContext):
2316         * Modules/webaudio/ScriptProcessorNode.cpp:
2317         (WebCore::ScriptProcessorNode::fireProcessEvent):
2318         (WebCore::ScriptProcessorNode::scriptExecutionContext):
2319
2320 2012-11-19  Ilya Tikhonovsky  <loislo@chromium.org>
2321
2322         webaudio: leak: AudioContext objects are leaking. They retain 36mb of shared data.
2323         https://bugs.webkit.org/show_bug.cgi?id=102356
2324
2325         Reviewed by Adam Barth.
2326
2327         A clean-up code was moved from uninitialize to clear method.
2328         AudioContext marks itself as hasPendingActivity in method constructCommon and unmarks itself in method clear.
2329         m_isStopScheduled filters out second ActiveDOMObject::stop call.
2330         markForDeletion appends AudioNode pointer to m_nodesToDelete array if there is no active audio thread.
2331         adoptRef was added in createOfflineContext method.
2332         A guard was added into deleteMarkedNodes.
2333
2334         Test: inspector-protocol/nmi-webaudio-leak-test.html
2335
2336         * Modules/webaudio/AudioContext.cpp:
2337         (WebCore::AudioContext::createOfflineContext):
2338         (WebCore::AudioContext::AudioContext):
2339         (WebCore::AudioContext::constructCommon):
2340         (WebCore::AudioContext::~AudioContext):
2341         (WebCore::AudioContext::clear):
2342         (WebCore::AudioContext::uninitialize):
2343         (WebCore::AudioContext::stopDispatch):
2344         (WebCore::AudioContext::stop):
2345         (WebCore::AudioContext::markForDeletion):
2346         (WebCore::AudioContext::scheduleNodeDeletion):
2347         (WebCore::AudioContext::deleteMarkedNodes):
2348         * Modules/webaudio/AudioContext.h:
2349         (AudioContext):
2350         * bindings/v8/custom/V8AudioContextCustom.cpp:
2351         (WebCore::V8AudioContext::constructorCallback):
2352         * inspector/InspectorMemoryAgent.cpp:
2353         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
2354         * platform/PlatformMemoryInstrumentation.cpp:
2355         (WebCore::PlatformMemoryInstrumentation::reportMemoryUsage):
2356         (WebCore):
2357         * platform/PlatformMemoryInstrumentation.h:
2358         (PlatformMemoryInstrumentation):
2359         (WebCore):
2360
2361 2012-11-19  Erik Arvidsson  <arv@chromium.org>
2362
2363         Update DOMException name: QuotaExceededError
2364         https://bugs.webkit.org/show_bug.cgi?id=102512
2365
2366         Reviewed by Kentaro Hara.
2367
2368         Patch 22 of 25 to update DOMException name to match the spec and Firefox.
2369
2370         Updated existing tests.
2371
2372         * dom/DOMCoreException.cpp:
2373
2374 2012-11-19  Erik Arvidsson  <arv@chromium.org>
2375
2376         Update DOMException name: AbortError
2377         https://bugs.webkit.org/show_bug.cgi?id=102508
2378
2379         Reviewed by Kentaro Hara.
2380
2381         Patch 20 of 25 to update DOMException name to match the spec and Firefox.
2382
2383         No code uses DOMException AbortError. We do use ABORT_ERR for XMLHttpRequestException. See bug 102506.
2384
2385         * dom/DOMCoreException.cpp:
2386
2387 2012-11-19  Kentaro Hara  <haraken@chromium.org>
2388
2389         Unreviewed, rolling out r135111.
2390         http://trac.webkit.org/changeset/135111
2391         https://bugs.webkit.org/show_bug.cgi?id=102356
2392
2393         The patch caused crashes in several layout tests
2394
2395         * Modules/webaudio/AudioContext.cpp:
2396         (WebCore::AudioContext::createOfflineContext):
2397         (WebCore::AudioContext::AudioContext):
2398         (WebCore::AudioContext::constructCommon):
2399         (WebCore::AudioContext::~AudioContext):
2400         (WebCore::AudioContext::uninitialize):
2401         (WebCore::AudioContext::uninitializeDispatch):
2402         (WebCore::AudioContext::stop):
2403         (WebCore::AudioContext::markForDeletion):
2404         (WebCore::AudioContext::scheduleNodeDeletion):
2405         (WebCore::AudioContext::deleteMarkedNodes):
2406         * Modules/webaudio/AudioContext.h:
2407         (AudioContext):
2408         * bindings/v8/custom/V8AudioContextCustom.cpp:
2409         (WebCore::V8AudioContext::constructorCallback):
2410         * inspector/InspectorMemoryAgent.cpp:
2411         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
2412         * platform/PlatformMemoryInstrumentation.cpp:
2413         (WebCore):
2414         * platform/PlatformMemoryInstrumentation.h:
2415
2416 2012-11-19  Kentaro Hara  <haraken@chromium.org>
2417
2418         Unreviewed, rolling out r135116.
2419         http://trac.webkit.org/changeset/135116
2420         https://bugs.webkit.org/show_bug.cgi?id=102649
2421
2422         Revert this patch to revert r135111, which caused crashes in
2423         several layout tests
2424
2425         * Modules/webaudio/AudioBufferSourceNode.cpp:
2426         (WebCore::AudioBufferSourceNode::looping):
2427         (WebCore::AudioBufferSourceNode::setLooping):
2428         * Modules/webaudio/AudioContext.cpp:
2429         (WebCore::AudioContext::AudioContext):
2430         (WebCore::AudioContext::stop):
2431         (WebCore::AudioContext::document):
2432         (WebCore):
2433         (WebCore::AudioContext::hasDocument):
2434         (WebCore::AudioContext::scriptExecutionContext):
2435         (WebCore::AudioContext::fireCompletionEvent):
2436         (WebCore::AudioContext::reportMemoryUsage):
2437         * Modules/webaudio/AudioContext.h:
2438         (AudioContext):
2439         * Modules/webaudio/ScriptProcessorNode.cpp:
2440         (WebCore::ScriptProcessorNode::fireProcessEvent):
2441         (WebCore::ScriptProcessorNode::scriptExecutionContext):
2442
2443 2012-11-19  Eugene Klyuchnikov  <eustas.bug@gmail.com>
2444
2445         Web Inspector: Refine JsDoc in DebuggerScriptMapping.js
2446         https://bugs.webkit.org/show_bug.cgi?id=102673
2447
2448         Reviewed by Vsevolod Vlasov.
2449
2450         DebuggerScriptMapping calls public method "addScript" not defined
2451         in SourceMapping interface.
2452
2453         To make things clear I've added ScriptSourceMapping interface that
2454         extends SourceMapping interface by adding "addScript" method.
2455
2456         * inspector/front-end/SourceMapping.js: Added "ScriptSourceMapping".
2457         * inspector/front-end/CompilerScriptMapping.js:
2458         Updated "@implements" to ScriptSourceMapping.
2459         * inspector/front-end/ResourceScriptMapping.js: Ditto.
2460         * inspector/front-end/ScriptSnippetModel.js: Ditto.
2461         * inspector/front-end/DebuggerScriptMapping.js: Updated signatures.
2462         Removed useless code.
2463
2464 2012-11-19  Tim Horton  <timothy_horton@apple.com>
2465
2466         Unreviewed, untested build fix.
2467
2468         * bindings/scripts/IDLParser.pm:
2469         (parseModule):
2470
2471 2012-11-19  Dongwoo Joshua Im  <dw.im@samsung.com>
2472
2473         [CSS3] Move CSSPropertyWebkitTextAlignLast into isValidKeywordPropertyAndValue function
2474         https://bugs.webkit.org/show_bug.cgi?id=102303
2475
2476         Reviewed by Alexis Menard.
2477
2478         Move the part which check whether CSSPropertyWebkitTextAlignLast has available value
2479         into the isValidKeywordPropertyAndValue function, like the same kind of properties.
2480         This will help speed wise in JS.
2481
2482         No new functionality, no new tests.
2483
2484         * css/CSSParser.cpp:
2485         (WebCore::isValidKeywordPropertyAndValue):
2486         (WebCore::isKeywordPropertyID):
2487         (WebCore::CSSParser::parseValue):
2488
2489 2012-11-19  Keishi Hattori  <keishi@webkit.org>
2490
2491         REGRESSION (r133565): Calendar picker isn't animating when changing month by pressing 't'
2492         https://bugs.webkit.org/show_bug.cgi?id=102660
2493
2494         Reviewed by Kent Tamura.
2495
2496         The calendar picker used to animate when you press 't'.
2497
2498         No new tests.
2499
2500         * Resources/pagepopups/calendarPicker.js:
2501         (DaysTable.prototype.selectRange):
2502
2503 2012-11-19  Kent Tamura  <tkent@chromium.org>
2504
2505         input.value="" should clear date/time input elements with partial values
2506         https://bugs.webkit.org/show_bug.cgi?id=102645
2507
2508         Reviewed by Kentaro Hara.
2509
2510         Tests: fast/forms/date-multiple-fields/date-multiple-fields-value-set-empty.html
2511                fast/forms/datetime-multiple-fields/datetime-multiple-fields-value-set-empty.html
2512                fast/forms/datetimelocal-multiple-fields/datetimelocal-multiple-fields-value-set-empty.html
2513                fast/forms/month-multiple-fields/month-multiple-fields-value-set-empty.html
2514                fast/forms/time-multiple-fields/time-multiple-fields-value-set-empty.html
2515                fast/forms/week-multiple-fields/week-multiple-fields-value-set-empty.html
2516
2517         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
2518         (WebCore::BaseMultipleFieldsDateAndTimeInputType::setValue):
2519         If the new value is an empty string and sub-fields has values, we should
2520         update the UI value to the empty state.
2521         * html/DateTimeFieldsState.h:
2522         (WebCore::DateTimeFieldsState::hasAnyValue):
2523         Added. It returns true if one or more sub-fields are not empty.
2524
2525 2012-11-19  Andrey Adaikin  <aandrey@chromium.org>
2526
2527         Web Inspector: [Canvas] if many canvases are being instrumented show the screenshot of the first one
2528         https://bugs.webkit.org/show_bug.cgi?id=102522
2529
2530         Reviewed by Yury Semikhatsky.
2531
2532         When many canvases are being instrumented we'll want to show replay screenshots for each canvas.
2533         Meanwhile, show the screenshot of the first one (instead of the last one), as it's likely to be the "main" canvas.
2534         Drive-by: add more typification for the JS compiler.
2535         Drive-by: create a new canvas for WebGL replay every time (similar to 2D replay) to avoid problems with resetting the context state.
2536
2537         * inspector/InjectedScriptCanvasModuleSource.js:
2538         (.):
2539
2540 2012-11-19  Kentaro Hara  <haraken@chromium.org>
2541
2542         Remove IDLStructure.pm
2543         https://bugs.webkit.org/show_bug.cgi?id=102642
2544
2545         Reviewed by Adam Barth.
2546
2547         Previously IDLStructure.pm was full of regular expressions to
2548         parse IDL files. Now a new IDL parser is implemented, IDLStructure.pm
2549         just contains several data structures for the IDL parser. We can
2550         move them to IDLParser.pm and thus remove IDLStructure.pm.
2551
2552         No tests. No change in generated code.
2553
2554         * CMakeLists.txt:
2555         * DerivedSources.make:
2556         * DerivedSources.pri:
2557         * GNUmakefile.am:
2558         * WebCore.gyp/WebCore.gyp:
2559         * WebCore.vcproj/MigrateScripts:
2560         * WebCore.vcproj/WebCore.vcproj:
2561         * WebCore.xcodeproj/project.pbxproj:
2562         * bindings/scripts/IDLParser.pm:
2563         (Parse):
2564         (parseInterface):
2565         (parseException):
2566         (parseConst):
2567         (parseAttributeRest):
2568         (parseOperationRest):
2569         (parseOptionalOrRequiredArgument):
2570         (parseExceptionField):
2571         (parseInterfaceOld):
2572         (parseExceptionOld):
2573         (parseAttributeRestOld):
2574         (applyExtendedAttributeList):
2575         * bindings/scripts/IDLStructure.pm: Removed.
2576
2577 2012-11-19  Alexei Filippov  <alph@chromium.org>
2578
2579         Web Inspector: refine time and bytes output formatting
2580         https://bugs.webkit.org/show_bug.cgi?id=102265
2581
2582         Reviewed by Yury Semikhatsky.
2583
2584         Add a space between number and unit, otherwise it's hard to read things like 88B.
2585         Reduce a number of decimal digits in KB and MB formats. 1023.45KB seems to be too detailed.
2586
2587         * English.lproj/localizedStrings.js:
2588         * inspector/front-end/CookiesTable.js:
2589         (WebInspector.CookiesTable.prototype._createGridNode):
2590         * inspector/front-end/UIUtils.js:
2591         (Number.secondsToString):
2592         (Number.bytesToString):
2593
2594 2012-11-19  Eugene Klyuchnikov  <eustas.bug@gmail.com>
2595
2596         Web Inspector: Timeline: DomContentLoaded event labeled incorrectly
2597         https://bugs.webkit.org/show_bug.cgi?id=102383
2598
2599         Reviewed by Yury Semikhatsky.
2600
2601         Fixed string presentation of event.
2602
2603         * inspector/front-end/TimelinePresentationModel.js: Fixed string.
2604
2605 2012-11-19  Kentaro Hara  <haraken@chromium.org>
2606
2607         Remove IDLStructure.pm
2608         https://bugs.webkit.org/show_bug.cgi?id=102642
2609
2610         Reviewed by Adam Barth.
2611
2612         Previously IDLStructure.pm was full of regular expressions to
2613         parse IDL files. Now a new IDL parser is implemented, IDLStructure.pm
2614         just contains several data structures for the IDL parser. We can
2615         move them to IDLParser.pm and thus remove IDLStructure.pm.
2616
2617         No tests. No change in generated code.
2618
2619         * CMakeLists.txt:
2620         * DerivedSources.make:
2621         * DerivedSources.pri:
2622         * GNUmakefile.am:
2623         * WebCore.gyp/WebCore.gyp:
2624         * WebCore.vcproj/MigrateScripts:
2625         * WebCore.vcproj/WebCore.vcproj:
2626         * WebCore.xcodeproj/project.pbxproj:
2627         * bindings/scripts/IDLParser.pm:
2628         (Parse):
2629         (parseInterface):
2630         (parseException):
2631         (parseConst):
2632         (parseAttributeRest):
2633         (parseOperationRest):
2634         (parseOptionalOrRequiredArgument):
2635         (parseExceptionField):
2636         (parseInterfaceOld):
2637         (parseExceptionOld):
2638         (parseAttributeRestOld):
2639         (applyExtendedAttributeList):
2640         * bindings/scripts/IDLStructure.pm: Removed.
2641
2642 2012-11-19  Alexei Filippov  <alph@chromium.org>
2643
2644         Web Inspector: refine time and bytes output formatting
2645         https://bugs.webkit.org/show_bug.cgi?id=102265
2646
2647         Reviewed by Yury Semikhatsky.
2648
2649         Add a space between number and unit, otherwise it's hard to read things like 88B.
2650         Reduce a number of decimal digits in KB and MB formats. 1023.45KB seems to be too detailed.
2651
2652         * English.lproj/localizedStrings.js:
2653         * inspector/front-end/CookiesTable.js:
2654         (WebInspector.CookiesTable.prototype._createGridNode):
2655         * inspector/front-end/UIUtils.js:
2656         (Number.secondsToString):
2657         (Number.bytesToString):
2658
2659 2012-11-19  Eugene Klyuchnikov  <eustas.bug@gmail.com>
2660
2661         Web Inspector: Timeline: DomContentLoaded event labeled incorrectly
2662         https://bugs.webkit.org/show_bug.cgi?id=102383
2663
2664         Reviewed by Yury Semikhatsky.
2665
2666         Fixed string presentation of event.
2667
2668         * inspector/front-end/TimelinePresentationModel.js: Fixed string.
2669
2670 2012-11-19  Kentaro Hara  <haraken@chromium.org>
2671
2672         Unreviewed, rolling out r135114.
2673         http://trac.webkit.org/changeset/135114
2674         https://bugs.webkit.org/show_bug.cgi?id=102642
2675
2676         it broke Qt build
2677
2678         * CMakeLists.txt:
2679         * DerivedSources.make:
2680         * DerivedSources.pri:
2681         * GNUmakefile.am:
2682         * WebCore.gyp/WebCore.gyp:
2683         * WebCore.vcproj/MigrateScripts:
2684         * WebCore.vcproj/WebCore.vcproj:
2685         * WebCore.xcodeproj/project.pbxproj:
2686         * bindings/scripts/IDLParser.pm:
2687         (Parse):
2688         (parseInterface):
2689         (parseException):
2690         (parseConst):
2691         (parseAttributeRest):
2692         (parseOperationRest):
2693         (parseOptionalOrRequiredArgument):
2694         (parseExceptionField):
2695         (parseInterfaceOld):
2696         (parseExceptionOld):
2697         (parseAttributeRestOld):
2698         (applyExtendedAttributeList):
2699         * bindings/scripts/IDLStructure.pm: Added.
2700
2701 2012-11-19  Vsevolod Vlasov  <vsevik@chromium.org>
2702
2703         Unreviewed inspector closure compilation fix.
2704
2705         * inspector/front-end/ObjectPropertiesSection.js:
2706         * inspector/front-end/externs.js:
2707
2708 2012-11-18  Ilya Tikhonovsky  <loislo@chromium.org>
2709
2710         webaudio: clean-up. Replace AudioContext::m_document member with ContextDestructionObserver::scriptExecutionContext().
2711         https://bugs.webkit.org/show_bug.cgi?id=102649
2712
2713         Reviewed by Adam Barth.
2714
2715         AudioContext uses m_document only as a pointer to ScriptExecutionContext.
2716         It could be safely replaced with ContextDestructionObserver::m_scriptExecutionContext.
2717         The lifetime of m_scriptExecutionContext is slightly different but it could be adjusted by m_isStopScheduled flag.
2718
2719         No new tests as there is no new functionality.
2720
2721         * Modules/webaudio/AudioBufferSourceNode.cpp:
2722         (WebCore::AudioBufferSourceNode::looping):
2723         (WebCore::AudioBufferSourceNode::setLooping):
2724         * Modules/webaudio/AudioContext.cpp:
2725         (WebCore::AudioContext::AudioContext):
2726         (WebCore::AudioContext::stop):
2727         (WebCore::AudioContext::fireCompletionEvent):
2728         (WebCore::AudioContext::reportMemoryUsage):
2729         * Modules/webaudio/AudioContext.h:
2730         (WebCore::AudioContext::scriptExecutionContext):
2731         (AudioContext):
2732         * Modules/webaudio/ScriptProcessorNode.cpp:
2733         (WebCore::ScriptProcessorNode::fireProcessEvent):
2734         (WebCore::ScriptProcessorNode::scriptExecutionContext):
2735
2736 2012-11-18  Kentaro Hara  <haraken@chromium.org>
2737
2738         [V8] Remove unused variables from CodeGeneratorV8.pm
2739         https://bugs.webkit.org/show_bug.cgi?id=102648
2740
2741         Reviewed by Adam Barth.
2742
2743         No tests. No change in generated code.
2744
2745         * bindings/scripts/CodeGeneratorV8.pm:
2746         (GenerateInterface):
2747         (GenerateHeader):
2748         (GetInternalFields):
2749         (GenerateNormalAttrGetter):
2750         (GenerateSingleBatchedAttribute):
2751         (GenerateImplementationCustomCall):
2752         (GenerateFunctionCallString):
2753         (CreateCustomSignature):
2754         (GetContextEnableFunction):
2755
2756 2012-11-18  Kentaro Hara  <haraken@chromium.org>
2757
2758         Remove IDLStructure.pm
2759         https://bugs.webkit.org/show_bug.cgi?id=102642
2760
2761         Reviewed by Adam Barth.
2762
2763         Previously IDLStructure.pm was full of regular expressions to
2764         parse IDL files. Now a new IDL parser is implemented, IDLStructure.pm
2765         just contains several data structures for the IDL parser. We can
2766         move them to IDLParser.pm and thus remove IDLStructure.pm.
2767
2768         No tests. No change in generated code.
2769
2770         * CMakeLists.txt:
2771         * DerivedSources.make:
2772         * DerivedSources.pri:
2773         * GNUmakefile.am:
2774         * WebCore.gyp/WebCore.gyp:
2775         * WebCore.vcproj/MigrateScripts:
2776         * WebCore.vcproj/WebCore.vcproj:
2777         * WebCore.xcodeproj/project.pbxproj:
2778         * bindings/scripts/IDLParser.pm:
2779         (Parse):
2780         (parseInterface):
2781         (parseException):
2782         (parseConst):
2783         (parseAttributeRest):
2784         (parseOperationRest):
2785         (parseOptionalOrRequiredArgument):
2786         (parseExceptionField):
2787         (parseInterfaceOld):
2788         (parseExceptionOld):
2789         (parseAttributeRestOld):
2790         (applyExtendedAttributeList):
2791         * bindings/scripts/IDLStructure.pm: Removed.
2792
2793 2012-11-18  Kentaro Hara  <haraken@chromium.org>
2794
2795         [V8] Make more use of $v8Interface in CodeGeneratorV8.pm
2796         https://bugs.webkit.org/show_bug.cgi?id=102639
2797
2798         Reviewed by Adam Barth.
2799
2800         We can replace hard-coded "V8${interfaceName}" with $v8Interface.
2801
2802         No tests. No change in generated code.
2803
2804         * bindings/scripts/CodeGeneratorV8.pm:
2805         (GenerateNormalAttrGetter):
2806         (GenerateNormalAttrSetter):
2807         (GenerateFunctionCallback):
2808         (GenerateNamedConstructorCallback):
2809         (GenerateImplementationIndexer):
2810         (GenerateImplementationNamedPropertyGetter):
2811         (GenerateImplementation):
2812
2813 2012-11-16  Ilya Tikhonovsky  <loislo@chromium.org>
2814
2815         webaudio: leak: AudioContext objects are leaking. They retain 36mb of shared data.
2816         https://bugs.webkit.org/show_bug.cgi?id=102356
2817
2818         Reviewed by Adam Barth.
2819
2820         A clean-up code was moved from uninitialize to clear method.
2821         AudioContext marks itself as hasPendingActivity in method constructCommon and unmarks itself in method clear.
2822         m_isStopScheduled filters out second ActiveDOMObject::stop call.
2823         markForDeletion appends AudioNode pointer to m_nodesToDelete array if there is no active audio thread.
2824         adoptRef was added in createOfflineContext method.
2825
2826         Test: inspector-protocol/nmi-webaudio-leak-test.html
2827
2828         * Modules/webaudio/AudioContext.cpp:
2829         (WebCore::AudioContext::createOfflineContext):
2830         (WebCore::AudioContext::AudioContext):
2831         (WebCore::AudioContext::constructCommon):
2832         (WebCore::AudioContext::~AudioContext):
2833         (WebCore::AudioContext::clear):
2834         (WebCore::AudioContext::uninitialize):
2835         (WebCore::AudioContext::stopDispatch):
2836         (WebCore::AudioContext::stop):
2837         (WebCore::AudioContext::markForDeletion):
2838         (WebCore::AudioContext::scheduleNodeDeletion):
2839         (WebCore::AudioContext::deleteMarkedNodes):
2840         * Modules/webaudio/AudioContext.h:
2841         (AudioContext):
2842         * bindings/v8/custom/V8AudioContextCustom.cpp:
2843         (WebCore::V8AudioContext::constructorCallback):
2844         * inspector/InspectorMemoryAgent.cpp:
2845         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
2846         * platform/PlatformMemoryInstrumentation.cpp:
2847         (WebCore::PlatformMemoryInstrumentation::reportMemoryUsage):
2848         (WebCore):
2849         * platform/PlatformMemoryInstrumentation.h:
2850         (PlatformMemoryInstrumentation):
2851         (WebCore):
2852
2853 2012-11-18  Kunihiko Sakamoto  <ksakamoto@chromium.org>
2854
2855         min/max/step support for calendar picker on datetime/datetime-local
2856         https://bugs.webkit.org/show_bug.cgi?id=102628
2857
2858         Reviewed by Kent Tamura.
2859
2860         Gray out dates with no allowed values on calendar picker for datetime/datetime-local
2861         when values are limited by min/max/step attributes.
2862
2863         Test: platform/chromium/fast/forms/calendar-picker/calendar-picker-datetime-with-step.html
2864
2865         * Resources/pagepopups/calendarPicker.js:
2866         (CalendarPicker.prototype._stepMismatch):
2867         Returns true iff there are any allowed values in the given day.
2868
2869 2012-11-18  Laszlo Gombos  <l.gombos@samsung.com>
2870
2871         Remove non-existent directories from the make system
2872         https://bugs.webkit.org/show_bug.cgi?id=102632
2873
2874         Reviewed by Adam Barth.
2875
2876         Remove (non-existent) symbian references from the exclude list in gyp project files.
2877
2878         No new tests as there is no new functionality.
2879
2880         * WebCore.gyp/WebCore.gyp:
2881
2882 2012-11-18  Patrick Gansterer  <paroga@webkit.org>
2883
2884         [WIN] Add a IMLangFontLinkType typedef
2885         https://bugs.webkit.org/show_bug.cgi?id=102584
2886
2887         Reviewed by Brent Fulgham.
2888
2889         Add a central typedef for IMLangFontLink(2) to get rid of a bunch of ifdefs.
2890
2891         * platform/graphics/FontCache.h:
2892         (WebCore):
2893         * platform/graphics/win/FontCacheWin.cpp:
2894         (WebCore::FontCache::getFontLinkInterface):
2895         (WebCore::getCJKCodePageMasks):
2896         (WebCore::createMLangFont):
2897         (WebCore::FontCache::getFontDataForCharacters):
2898         * platform/graphics/win/SimpleFontDataWin.cpp:
2899         (WebCore::SimpleFontData::containsCharacters):
2900         * platform/graphics/wince/FontCacheWinCE.cpp:
2901         (WebCore):
2902         (WebCore::FontCache::getFontLinkInterface):
2903         (WebCore::getCJKCodePageMasks):
2904         (WebCore::FontCache::getFontDataForCharacters):
2905         * platform/graphics/wince/FontPlatformData.cpp:
2906         (WebCore::FontFamilyCodePageInfo::codePages):
2907         (WebCore::FixedSizeFontData::create):
2908         * platform/graphics/wince/GlyphPageTreeNodeWinCE.cpp:
2909         (WebCore::GlyphPage::fill):
2910
2911 2012-11-18  Mike West  <mkwst@chromium.org>
2912
2913         Web Inspector: Remove unused ConsoleMessage constructor.
2914         https://bugs.webkit.org/show_bug.cgi?id=102590
2915
2916         Reviewed by Brent Fulgham.
2917
2918         We currently have a ConsoleMessage constructor that's unused. Let's
2919         kill it.
2920
2921         * inspector/ConsoleMessage.cpp:
2922         * inspector/ConsoleMessage.h:
2923         (ConsoleMessage):
2924             Removing an unused constructor variant.
2925
2926 2012-11-18  Andreas Kling  <akling@apple.com>
2927
2928         StyledElement: Make handling the "style" attribute a litte faster.
2929         <http://webkit.org/b/102623>
2930
2931         Reviewed by Ojan Vafai.
2932
2933         We know that "style" is never a presentation attribute, so avoid the virtual call to isPresentationAttribute()
2934         by hoisting the parseAttribute() logic up into attributeChanged().
2935         Did the same thing with Element::parseAttribute() for consistency.
2936
2937         Knocks ~0.6% of samples off of the DOM/CreateNodes performance test.
2938
2939         * dom/Element.cpp:
2940         (WebCore::Element::attributeChanged):
2941         * dom/Element.h:
2942         (WebCore::Element::parseAttribute):
2943         * dom/StyledElement.cpp:
2944         (WebCore::StyledElement::attributeChanged):
2945         * dom/StyledElement.h:
2946         (StyledElement):
2947
2948 2012-11-18  Laszlo Gombos  <l.gombos@samsung.com>
2949
2950         [CMake] Consolidate common input files
2951         https://bugs.webkit.org/show_bug.cgi?id=101632
2952
2953         Reviewed by Rob Buis.
2954
2955         Consolidate and sort the list of files, move common source files
2956         into CMakeLists.txt from the port specific files.
2957
2958         No new tests as there is no new functionality.
2959
2960         * CMakeLists.txt:
2961         * PlatformBlackBerry.cmake:
2962         * PlatformEfl.cmake:
2963         * PlatformWinCE.cmake:
2964
2965 2012-11-18  Andreas Kling  <akling@apple.com>
2966
2967         Tighten small SharedBuffers by reserving the exact amount of space needed.
2968         <http://webkit.org/b/102625>
2969
2970         Reviewed by Anders Carlsson.
2971
2972         When adding the first chunk to a small (<4096 bytes) SharedBuffer, reserve the exact
2973         amount of space needed instead of leaving it to Vector<char>::append().
2974
2975         1.86MB progression on Membuster3.
2976
2977         * platform/SharedBuffer.cpp:
2978         (WebCore::SharedBuffer::append):
2979
2980 2012-11-18  Ryosuke Niwa  <rniwa@webkit.org>
2981
2982         Make namedItem return a node list only in HTMLFormControlsCollection and HTMLOptionsCollection
2983         https://bugs.webkit.org/show_bug.cgi?id=101311
2984
2985         Reviewed by Darin Adler.
2986
2987         Introduce two new interfaces HTMLFormControlsCollection and HTMLOptionsCollection to be used by form.elements
2988         and select.options. These two interfaces have the named getter and namedItem that returns a live NodeList when
2989         there are multiple matches. Introducing these two interfaces allow us to make "regular" HTMLCollection's named
2990         getter and namedItem return exactly one node or null as specified in HTML5:
2991         http://www.whatwg.org/specs/web-apps/current-work/multipage/common-dom-interfaces.html#collections-0
2992
2993         Unfortunately, HTMLOptionsCollection still has a bug that its named getter and namedItem returns
2994         a static NodeList instead of a live NodeList (DynamicNodeList) at the moment.
2995
2996         Also got rid of Document::objects since it's not exposed in IDL or called anywhere.
2997
2998         Test: fast/dom/html-collections-namedItem.html
2999
3000         * CMakeLists.txt:
3001         * DerivedSources.cpp:
3002         * DerivedSources.make:
3003         * DerivedSources.pri:
3004         * GNUmakefile.list.am:
3005         * Target.pri:
3006         * UseJSC.cmake:
3007         * UseV8.cmake:
3008         * WebCore.gypi:
3009         * WebCore.vcproj/WebCore.vcproj:
3010         * WebCore.xcodeproj/project.pbxproj:
3011         * bindings/js/JSBindingsAllInOne.cpp:
3012         * bindings/js/JSHTMLAllCollectionCustom.cpp:
3013         (WebCore::getNamedItems):
3014         * bindings/js/JSHTMLCollectionCustom.cpp:
3015         (WebCore::JSHTMLCollection::nameGetter): Now returns exactly one node or null.
3016         (WebCore::toJS):
3017         * bindings/js/JSHTMLFormControlsCollectionCustom.cpp: Added.
3018         (WebCore::getNamedItems): Returns RadioNodeList when there are multiple matches.
3019         (WebCore::JSHTMLFormControlsCollection::canGetItemsForName):
3020         (WebCore::JSHTMLFormControlsCollection::nameGetter):
3021         (WebCore::JSHTMLFormControlsCollection::namedItem):
3022         * bindings/js/JSHTMLOptionsCollectionCustom.cpp:
3023         (WebCore::getNamedItems): Returns a static NodeList when there are multiple matches.
3024         This is a bug. It should be a live NodeList instead.
3025         (WebCore::JSHTMLOptionsCollection::canGetItemsForName):
3026         (WebCore::JSHTMLOptionsCollection::nameGetter):
3027         (WebCore::JSHTMLOptionsCollection::namedItem):
3028         * bindings/js/CodeGeneratorJS.pm: Include JSNode.js for all HTML*Collection interfaces for simplicity.
3029         * bindings/js/CodeGeneratorV8.pm: HTMLOptionsCollection now inherits from HTMLCollection. See
3030         http://www.whatwg.org/specs/web-apps/current-work/multipage/common-dom-interfaces.html#htmloptionscollection
3031         * bindings/v8/custom/V8HTMLAllCollectionCustom.cpp: Pass in isolate when we can.
3032         (WebCore::getNamedItems): Added a comment about how we should be returning
3033         a HTMLCollection when there are multiple matches.
3034         (WebCore::getItem):
3035         (WebCore::V8HTMLAllCollection::namedPropertyGetter):
3036         (WebCore::V8HTMLAllCollection::namedItemCallback):
3037         * bindings/v8/custom/V8HTMLCollectionCustom.cpp: Now returns exactly one node or null.
3038         (WebCore::V8HTMLCollection::namedPropertyGetter):
3039         (WebCore::toV8):
3040         * bindings/v8/custom/V8HTMLFormControlsCollectionCustom.cpp: Added.
3041         (WebCore::getNamedItems): Returns RadioNodeList when there are multiple matches.
3042         (WebCore::V8HTMLFormControlsCollection::namedPropertyGetter):
3043         (WebCore::V8HTMLFormControlsCollection::namedItemCallback):
3044         * bindings/v8/custom/V8HTMLOptionsCollectionCustom.cpp:
3045         (WebCore::getNamedItems): Returns a static NodeList when there are multiple matches.
3046         This is a bug. It should be a live NodeList instead.
3047         (WebCore::V8HTMLOptionsCollection::namedPropertyGetter):
3048         (WebCore::V8HTMLOptionsCollection::namedItemCallback):
3049         * dom/Document.cpp: Removed Document::objects since it was not used anywhere.
3050         * dom/Document.h:
3051         (Document):
3052         * dom/Element.cpp:
3053         (WebCore::ElementRareData::ensureCachedHTMLCollection): form.elements should instantiate
3054         a HTMLFormControlsCollection instead of a HTMLCollection.
3055         * html/CollectionType.h:
3056         * html/HTMLCollection.idl: Removed [Custom] since namedItem is a regular function call now.
3057         * html/HTMLFieldSetElement.cpp:
3058         * html/HTMLFieldSetElement.h:
3059         * html/HTMLFormCollection.cpp: Removed.
3060         * html/HTMLFormCollection.h: Removed.
3061         * html/HTMLFormControlsCollection.cpp: Copied from Source/WebCore/html/HTMLFormCollection.cpp.
3062         (WebCore::HTMLFormControlsCollection::HTMLFormControlsCollection):
3063         (WebCore::HTMLFormControlsCollection::create):
3064         (WebCore::HTMLFormControlsCollection::~HTMLFormControlsCollection):
3065         (WebCore::HTMLFormControlsCollection::formControlElements):
3066         (WebCore::HTMLFormControlsCollection::formImageElements):
3067         (WebCore::HTMLFormControlsCollection::virtualItemAfter):
3068         (WebCore::HTMLFormControlsCollection::namedItem):
3069         (WebCore::HTMLFormControlsCollection::updateNameCache):
3070         * html/HTMLFormControlsCollection.h: Copied from Source/WebCore/html/HTMLFormCollection.h.
3071         (HTMLFormControlsCollection):
3072         * html/HTMLFormControlsCollection.idl: Added.
3073         * html/HTMLFormElement.cpp:
3074         * html/HTMLFormElement.h:
3075         * html/HTMLOptionsCollection.idl:
3076
3077 2012-11-18  Kentaro Hara  <haraken@chromium.org>
3078
3079         [V8] Rename $className to $v8InterfaceName
3080         https://bugs.webkit.org/show_bug.cgi?id=102487
3081
3082         Reviewed by Adam Barth.
3083
3084         In CodeGeneratorV8.pm, $className is always "V8$interfaceName".
3085         We should rename $className to $v8InterfaceName. Also we can
3086         remove GetCallbackClassName().
3087
3088         No tests. No change in behavior.
3089
3090         * bindings/scripts/CodeGeneratorV8.pm:
3091         (GenerateHeader):
3092         (GetHeaderClassInclude):
3093         (GenerateDomainSafeFunctionGetter):
3094         (GenerateDomainSafeFunctionSetter):
3095         (GenerateParametersCheck):
3096         (GenerateImplementation):
3097         (GenerateHeaderContentHeader):
3098         (GenerateImplementationContentHeader):
3099         (GenerateCallbackHeader):
3100         (GenerateCallbackImplementation):
3101         (GenerateToV8Converters):
3102         (GetPassRefPtrType):
3103
3104 2012-11-18  Kentaro Hara  <haraken@chromium.org>
3105
3106         [V8] Remove GetTypeFromSignature() from CodeGeneratorV8.pm
3107         https://bugs.webkit.org/show_bug.cgi?id=102499
3108
3109         Reviewed by Adam Barth.
3110
3111         No tests. No change in behavior.
3112
3113         * bindings/scripts/CodeGeneratorV8.pm:
3114         (GenerateNormalAttrGetter):
3115         (GenerateNormalAttrSetter):
3116         (GenerateParametersCheckExpression):
3117         (GenerateParametersCheck):
3118         (GenerateFunctionCallString):
3119         (GetNativeTypeFromSignature):
3120         (TranslateParameter):
3121         (TypeCanFailConversion):
3122         (JSValueToNative):
3123         (NativeToJSValue):
3124
3125 2012-11-18  Kentaro Hara  <haraken@chromium.org>
3126
3127         Remove GenerateModule() from all code generators
3128         https://bugs.webkit.org/show_bug.cgi?id=102490
3129
3130         Reviewed by Adam Barth.
3131
3132         WebKit IDL files no longer support modules. The Web IDL spec
3133         no longer supports modules. We can remove it from code generators.
3134
3135         No tests. No change in behavior.
3136
3137         * bindings/scripts/CodeGenerator.pm:
3138         (ProcessDocument):
3139         * bindings/scripts/CodeGeneratorCPP.pm:
3140         * bindings/scripts/CodeGeneratorGObject.pm:
3141         * bindings/scripts/CodeGeneratorJS.pm:
3142         * bindings/scripts/CodeGeneratorObjC.pm:
3143         * bindings/scripts/CodeGeneratorV8.pm:
3144
3145 2012-11-18  Kentaro Hara  <haraken@chromium.org>
3146
3147         [V8] Get rid of unused functions and inline redundant functions in CodeGeneratorV8.pm
3148         https://bugs.webkit.org/show_bug.cgi?id=102497
3149
3150         Reviewed by Adam Barth.
3151
3152         No tests. No change in behavior.
3153
3154         * bindings/scripts/CodeGeneratorV8.pm:
3155         (GenerateDomainSafeFunctionGetter):
3156         (GenerateNormalAttrGetter):
3157         (GenerateFunctionCallString):
3158
3159 2012-11-18  Sheriff Bot  <webkit.review.bot@gmail.com>
3160
3161         Unreviewed, rolling out r135074.
3162         http://trac.webkit.org/changeset/135074
3163         https://bugs.webkit.org/show_bug.cgi?id=102619
3164
3165         Made most layout tests crash. (Requested by rakuco on
3166         #webkit).
3167
3168         * PlatformEfl.cmake:
3169         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
3170         (WebCore::GraphicsContext3D::create):
3171         (WebCore::GraphicsContext3D::GraphicsContext3D):
3172         (WebCore::GraphicsContext3D::~GraphicsContext3D):
3173         (WebCore::GraphicsContext3D::makeContextCurrent):
3174         (WebCore::GraphicsContext3D::setContextLostCallback):
3175         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
3176         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
3177         (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
3178         (WebCore::GraphicsContext3DPrivate::createSurface):
3179         (WebCore::GraphicsContext3DPrivate::setCurrentGLContext):
3180         (WebCore::GraphicsContext3DPrivate::platformGraphicsContext3D):
3181         (WebCore::GraphicsContext3DPrivate::makeContextCurrent):
3182         (WebCore::GraphicsContext3DPrivate::createGraphicsSurfaces):
3183         (WebCore::GraphicsContext3DPrivate::copyToGraphicsSurface):
3184         (WebCore::GraphicsContext3DPrivate::graphicsSurfaceToken):
3185         * platform/graphics/efl/GraphicsContext3DPrivate.h:
3186         (GraphicsContext3DPrivate):
3187         * platform/graphics/opengl/GLDefs.h: Removed.
3188         * platform/graphics/opengl/GLPlatformContext.cpp: Removed.
3189         * platform/graphics/opengl/GLPlatformContext.h: Removed.
3190         * platform/graphics/opengl/GLPlatformSurface.cpp: Removed.
3191         * platform/graphics/opengl/GLPlatformSurface.h: Removed.
3192         * platform/graphics/surfaces/glx/GLXContext.cpp: Removed.
3193         * platform/graphics/surfaces/glx/GLXContext.h: Removed.
3194         * platform/graphics/surfaces/glx/GLXSurface.cpp: Removed.
3195         * platform/graphics/surfaces/glx/GLXSurface.h: Removed.
3196
3197 2012-11-18  Antti Koivisto  <antti@apple.com>
3198
3199         REGRESSION(r129644): User StyleSheet not applying
3200         https://bugs.webkit.org/show_bug.cgi?id=102110
3201
3202         Reviewed by Andreas Kling.
3203
3204         Injected stylesheets added as UserStyleAuthorLevel fail to apply. r129644 implicitly assumed that
3205         such things don't exists but on Chromium addUserStyleSheet() confusingly uses them.
3206         
3207         The patch adds injected author stylesheets to DocumentStyleSheetCollection::activeStyleSheets().
3208         It also generally cleans up the code around injected and user stylesheets.
3209
3210         Tests: userscripts/user-script-and-stylesheet.html
3211                userscripts/user-stylesheet-invalidate.html
3212
3213         * css/StyleResolver.cpp:
3214         (WebCore::StyleResolver::StyleResolver):
3215         (WebCore::StyleResolver::collectRulesFromUserStyleSheets):
3216         (WebCore::collectCSSOMWrappers):
3217         * css/StyleResolver.h:
3218         (StyleResolver):
3219         * dom/Document.cpp:
3220         (WebCore::Document::setCompatibilityMode):
3221         * dom/DocumentStyleSheetCollection.cpp:
3222         (WebCore::DocumentStyleSheetCollection::DocumentStyleSheetCollection):
3223         (WebCore::DocumentStyleSheetCollection::~DocumentStyleSheetCollection):
3224         (WebCore::DocumentStyleSheetCollection::injectedUserStyleSheets):
3225         (WebCore):
3226         (WebCore::DocumentStyleSheetCollection::injectedAuthorStyleSheets):
3227         (WebCore::DocumentStyleSheetCollection::updateInjectedStyleSheetCache):
3228         (WebCore::DocumentStyleSheetCollection::invalidateInjectedStyleSheetCache):
3229         (WebCore::DocumentStyleSheetCollection::addUserSheet):
3230         (WebCore::DocumentStyleSheetCollection::updateActiveStyleSheets):
3231         (WebCore::DocumentStyleSheetCollection::reportMemoryUsage):
3232         * dom/DocumentStyleSheetCollection.h:
3233         (WebCore::DocumentStyleSheetCollection::documentUserStyleSheets):
3234         (DocumentStyleSheetCollection):
3235         * page/PageGroup.cpp:
3236         (WebCore::PageGroup::addUserStyleSheetToWorld):
3237         (WebCore::PageGroup::removeUserStyleSheetFromWorld):
3238         (WebCore::PageGroup::removeUserStyleSheetsFromWorld):
3239         (WebCore::PageGroup::removeAllUserContent):
3240         (WebCore::PageGroup::invalidatedInjectedStyleSheetCacheInAllFrames):
3241         * page/PageGroup.h:
3242         (PageGroup):
3243
3244 2012-11-18  Adam Barth  <abarth@webkit.org>
3245
3246         Unreviewed.
3247
3248         Update run-bindings-tests baselines after
3249         http://trac.webkit.org/changeset/135063
3250
3251         * bindings/scripts/test/JS/JSTestActiveDOMObject.h:
3252         (JSTestActiveDOMObjectOwner):
3253         * bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
3254         (JSTestCustomNamedGetterOwner):
3255         * bindings/scripts/test/JS/JSTestEventConstructor.h:
3256         (JSTestEventConstructorOwner):
3257         * bindings/scripts/test/JS/JSTestEventTarget.h:
3258         (JSTestEventTargetOwner):
3259         * bindings/scripts/test/JS/JSTestException.h:
3260         (JSTestExceptionOwner):
3261         * bindings/scripts/test/JS/JSTestInterface.h:
3262         (JSTestInterfaceOwner):
3263         * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
3264         (JSTestMediaQueryListListenerOwner):
3265         * bindings/scripts/test/JS/JSTestNamedConstructor.h:
3266         (JSTestNamedConstructorOwner):
3267         * bindings/scripts/test/JS/JSTestObj.h:
3268         (JSTestObjOwner):
3269         * bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
3270         (JSTestOverloadedConstructorsOwner):
3271         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
3272         (JSTestSerializedScriptValueInterfaceOwner):
3273
3274 2012-11-18  Simon Fraser  <simon.fraser@apple.com>
3275
3276         Make convertToLayerCoords iterative, rather than recursive
3277         https://bugs.webkit.org/show_bug.cgi?id=102618
3278
3279         Reviewed by Antti Koivisto.
3280
3281         RenderLayer::convertToLayerCoords() is a hot function on profiles.
3282         Change it to be iterative, rather than recursive, so that the
3283         bulk of the function can be inlined.
3284         
3285         Was tested with assertions against the old code during development.
3286
3287         * rendering/RenderLayer.cpp:
3288         (WebCore::accumulateOffsetTowardsAncestor):
3289         (WebCore::RenderLayer::convertToLayerCoords):
3290
3291 2012-11-18  Andreas Kling  <akling@apple.com>
3292
3293         Inline the StyledElement constructor.
3294         <http://webkit.org/b/102615>
3295
3296         Reviewed by Antti Koivisto.
3297
3298         StyledElement sits between Element and HTMLElement in the inheritance chain, and both of those are inline. 
3299         Knocks ~0.4% of samples off of the DOM/CreateNodes performance test.
3300
3301         * dom/StyledElement.cpp:
3302         * dom/StyledElement.h:
3303         (WebCore::StyledElement::StyledElement):
3304
3305 2012-11-18  Andreas Kling  <akling@apple.com>
3306
3307         HTMLMediaElement: Skip unnecessary attribute lookup in parsing of "src" attribute.
3308         <http://webkit.org/b/102614>
3309
3310         Reviewed by Anders Carlsson.
3311
3312         When parsing the "src" attribute, we don't need to look it up with fastHasAttribute()
3313         to know if it's present. If it's not present, 'value' argument will be null.
3314
3315         * html/HTMLMediaElement.cpp:
3316         (WebCore::HTMLMediaElement::parseAttribute):
3317
3318 2012-11-18  Kondapally Kalyan  <kalyan.kondapally@intel.com>
3319
3320         [EFL] Refactor GraphicsContext3DEFL.
3321         https://bugs.webkit.org/show_bug.cgi?id=101291.
3322
3323         Reviewed by Kenneth Rohde Christiansen.
3324
3325         GraphicsContext3DEfl creates GraphicsContext3DPrivate, which acts as its platform Layer.
3326         GraphicsContext3DPrivate needs to handle the following cases:
3327         1) To provide an off-screen buffer for accelerated composition.
3328         2) Render to a current context.
3329         3) To render directly to host window. (currently not supported.)
3330
3331         Before this patch Evas was used to provide us an off-screen context and buffer. GLX was used in
3332         the other supported case. Evas acts as a glue layer to provide us with appropriate
3333         GL bindings (OpenGL functions), GL context and drawable (surface/offscreenbuffer).
3334         However, primitive rendering is handled by TextureMapper and OpenGLShims is used to load the needed GL functions.
3335
3336         It would be for our advantage to be able to take in to use any optimisations/extensions
3337         provided by underlying drivers, specific to a platform (e.g. GLX_MESA_copy_sub_buffer etc.).
3338         This patch introduces an abstraction layer to make it easy to add support for any GL backend (GLX, EGL etc.)
3339         and do any platform specific optimizations as needed without complicating GraphicsContext3DPrivate class.
3340         Two new classes are added with this implementation, GLPlatformContext and GLPlatformSurface.
3341         GraphicsContext3DPrivate would create and own a GLPlatformContext and GLPlatformSurface.
3342
3343         GLPlatformContext encapsulates an OpenGL context hiding any platform specific management.
3344         It uses GL extension ARB_robustness (when available) to detect driver resets.
3345         It defines a simple interface for things that need to be handled by the context. Support
3346         for multi-threaded usage and shared context-group would be added later.
3347
3348         GLPlatformSurface encapsulates an OpenGL drawable hiding any platform specific management.
3349         It defines a simple interface for things that need to be handled by the surface.
3350         It creates an off-screen rendering area. Any GLPlatformContext (compatible with the surface)
3351         can be used to render into this off-screen area.
3352
3353         This patch also adds GLX implementation. To keep the patch to minimum EGL support would be added in another changeset.
3354
3355         * PlatformEfl.cmake:
3356         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
3357         (WebCore::GraphicsContext3D::create):
3358         (WebCore::GraphicsContext3D::GraphicsContext3D):
3359         (WebCore::GraphicsContext3D::~GraphicsContext3D):
3360         (WebCore::GraphicsContext3D::makeContextCurrent):
3361         (WebCore::GraphicsContext3D::setContextLostCallback):
3362         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
3363         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
3364         (GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
3365         (GraphicsContext3DPrivate::releaseResources):
3366         (GraphicsContext3DPrivate::setContextLostCallback):
3367         (GraphicsContext3DPrivate::platformGraphicsContext3D):
3368         (GraphicsContext3DPrivate::makeContextCurrent):
3369         (GraphicsContext3DPrivate::createGraphicsSurfaces):
3370         (GraphicsContext3DPrivate::copyToGraphicsSurface):
3371         (GraphicsContext3DPrivate::graphicsSurfaceToken):
3372         * platform/graphics/efl/GraphicsContext3DPrivate.h:
3373         (GraphicsContext3DPrivate):
3374         * platform/graphics/opengl/GLDefs.h: Added.
3375         (WebCore):
3376         * platform/graphics/opengl/GLPlatformContext.cpp: Added.
3377         (WebCore):
3378         (WebCore::GLPlatformContext::createContext):
3379         (WebCore::GLPlatformContext::createOffScreenContext):
3380         (WebCore::GLPlatformContext::createCurrentContextWrapper):
3381         (WebCore::GLPlatformContext::GLPlatformContext):
3382         (WebCore::GLPlatformContext::~GLPlatformContext):
3383         (WebCore::GLPlatformContext::makeCurrent):
3384         (WebCore::GLPlatformContext::isValid):
3385         (WebCore::GLPlatformContext::releaseCurrent):
3386         (WebCore::GLPlatformContext::handle):
3387         (WebCore::GLPlatformContext::isCurrentContext):
3388         (WebCore::GLPlatformContext::initialize):
3389         (WebCore::GLPlatformContext::getCurrent):
3390         (WebCore::GLPlatformContext::platformMakeCurrent):
3391         (WebCore::GLPlatformContext::platformReleaseCurrent):
3392         (WebCore::GLPlatformContext::destroy):
3393         * platform/graphics/opengl/GLPlatformContext.h: Added.
3394         (WebCore):
3395         (GLPlatformContext):
3396         * platform/graphics/opengl/GLPlatformSurface.cpp: Added.
3397         (WebCore):
3398         (WebCore::GLPlatformSurface::createOffscreenSurface):
3399         (WebCore::GLPlatformSurface::createTransportSurface):
3400         (WebCore::GLPlatformSurface::GLPlatformSurface):
3401         (WebCore::GLPlatformSurface::~GLPlatformSurface):
3402         (WebCore::GLPlatformSurface::handle):
3403         (WebCore::GLPlatformSurface::geometry):
3404         (WebCore::GLPlatformSurface::sharedDisplay):
3405         (WebCore::GLPlatformSurface::configuration):
3406         (WebCore::GLPlatformSurface::swapBuffers):
3407         (WebCore::GLPlatformSurface::copyTexture):
3408         (WebCore::GLPlatformSurface::updateContents):
3409         (WebCore::GLPlatformSurface::setGeometry):
3410         (WebCore::GLPlatformSurface::destroy):
3411         * platform/graphics/opengl/GLPlatformSurface.h: Added.
3412         (WebCore):
3413         (GLPlatformSurface):
3414             GLXOffScreenContext creates an off-screen context. This is used when
3415             renderstyle is RenderOffscreen.
3416             It uses GL extension GLX_ARB_create_context (when available)
3417             to create a context else falls back to use glXCreateNewContext.
3418         * platform/graphics/surfaces/glx/GLXContext.cpp: Added.
3419         (WebCore):
3420         (WebCore::initializeARBExtensions):
3421         (WebCore::GLXOffScreenContext::GLXOffScreenContext):
3422         (WebCore::GLXOffScreenContext::initialize):
3423         (WebCore::GLXOffScreenContext::~GLXOffScreenContext):
3424         (WebCore::GLXOffScreenContext::isCurrentContext):
3425         (WebCore::GLXOffScreenContext::platformMakeCurrent):
3426         (WebCore::GLXOffScreenContext::platformReleaseCurrent):
3427         (WebCore::GLXOffScreenContext::freeResources):
3428         (WebCore::GLXOffScreenContext::destroy):
3429             GLXCurrentContextWrapper acts as a wrapper for current context.
3430             This is used when renderstyle is RenderToCurrentGLContext.
3431         * platform/graphics/surfaces/glx/GLXContext.h: Added.
3432         (WebCore):
3433         (GLXCurrentContextWrapper):
3434         (WebCore::GLXCurrentContextWrapper::GLXCurrentContextWrapper):
3435         (WebCore::GLXCurrentContextWrapper::~GLXCurrentContextWrapper):
3436         (GLXOffScreenContext):
3437         * platform/graphics/surfaces/glx/GLXSurface.cpp: Added.
3438         (WebCore):
3439         (WebCore::GLXSurface::GLXSurface):
3440         (WebCore::GLXSurface::~GLXSurface):
3441         (WebCore::GLXSurface::visualInfo):
3442         (WebCore::GLXSurface::xWindow):
3443         (WebCore::GLXSurface::pBufferConfiguration):
3444         (WebCore::GLXSurface::transportSurfaceConfiguration):
3445         (WebCore::GLXSurface::isXRenderExtensionSupported):
3446             GLXTransportSurface creates Window and uses it as an off-screen surface.
3447             Any GLContext that was created with respect to configuration can be used
3448             to render into this.
3449             This is used when contents of the buffer are to be provided to UI Process
3450             for display.
3451         (WebCore::GLXTransportSurface::GLXTransportSurface):
3452         (WebCore::GLXTransportSurface::~GLXTransportSurface):
3453         (WebCore::GLXTransportSurface::configuration):
3454         (WebCore::GLXTransportSurface::swapBuffers):
3455         (WebCore::GLXTransportSurface::setGeometry):
3456         (WebCore::GLXTransportSurface::initialize):
3457         (WebCore::GLXTransportSurface::destroy):
3458         (WebCore::GLXTransportSurface::freeResources):
3459            GLXPBuffer, Creates a GL surface (PBuffer) used for offscreen rendering.
3460            Any GLContext that was created with respect to configuration can be used
3461            to render into this.
3462         (WebCore::GLXPBuffer::GLXPBuffer):
3463         (WebCore::GLXPBuffer::~GLXPBuffer):
3464         (WebCore::GLXPBuffer::initialize):
3465         (WebCore::GLXPBuffer::configuration):
3466         (WebCore::GLXPBuffer::destroy):
3467         (WebCore::GLXPBuffer::freeResources):
3468         * platform/graphics/surfaces/glx/GLXSurface.h: Added.
3469         (WebCore):
3470             Creates X resources which are shared between surface and context.
3471         (SharedX11Resources):
3472         (WebCore::SharedX11Resources::create):
3473         (WebCore::SharedX11Resources::deref):
3474         (WebCore::SharedX11Resources::getXWindow):
3475         (WebCore::SharedX11Resources::display):
3476         (WebCore::SharedX11Resources::visualInfo):
3477         (WebCore::SharedX11Resources::createConfig):
3478         (WebCore::SharedX11Resources::pBufferContextConfig):
3479         (WebCore::SharedX11Resources::surfaceContextConfig):
3480         (WebCore::SharedX11Resources::isXRenderExtensionSupported):
3481         (WebCore::SharedX11Resources::SharedX11Resources):
3482         (WebCore::SharedX11Resources::~SharedX11Resources):
3483         (GLXSurface):
3484         (GLXTransportSurface):
3485         (GLXPBuffer):
3486
3487 2012-11-18  Andreas Kling  <akling@apple.com>
3488
3489         Element::parseAttribute() should take name & value as separate arguments.
3490         <http://webkit.org/b/102608>
3491
3492         Reviewed by Antti Koivisto.
3493
3494         Update the signature of parseAttribute() to take a QualifiedName/AtomicString combo instead
3495         of an Attribute. This lets us pass avoid refcount churn in Element::attributeChanged() since
3496         creating a temporary Attribute is no longer necessary.
3497
3498         This was surprisingly hot (~1%) on the DOM/CreateNodes performance test.
3499
3500         * bindings/js/ScriptEventListener.cpp:
3501         (WebCore::createAttributeEventListener):
3502         * bindings/js/ScriptEventListener.h:
3503         (WebCore):
3504         * bindings/v8/ScriptEventListener.cpp:
3505         (WebCore::createAttributeEventListener):
3506         * bindings/v8/ScriptEventListener.h:
3507         (WebCore):
3508         * dom/Element.cpp:
3509         (WebCore::Element::attributeChanged):
3510         (WebCore::Element::parseAttribute):
3511         * dom/Element.h:
3512         (Element):
3513         * dom/StyledElement.cpp:
3514         (WebCore::StyledElement::parseAttribute):
3515         * dom/StyledElement.h:
3516         (StyledElement):
3517         * html/HTMLAnchorElement.cpp:
3518         (WebCore::HTMLAnchorElement::parseAttribute):
3519         * html/HTMLAnchorElement.h:
3520         (HTMLAnchorElement):
3521         * html/HTMLAppletElement.cpp:
3522         (WebCore::HTMLAppletElement::parseAttribute):
3523         * html/HTMLAppletElement.h:
3524         (HTMLAppletElement):
3525         * html/HTMLAreaElement.cpp:
3526         (WebCore::HTMLAreaElement::parseAttribute):
3527         * html/HTMLAreaElement.h:
3528         (HTMLAreaElement):
3529         * html/HTMLBaseElement.cpp:
3530         (WebCore::HTMLBaseElement::parseAttribute):
3531         * html/HTMLBaseElement.h:
3532         (HTMLBaseElement):
3533         * html/HTMLBodyElement.cpp:
3534         (WebCore::HTMLBodyElement::parseAttribute):
3535         * html/HTMLBodyElement.h:
3536         (HTMLBodyElement):
3537         * html/HTMLButtonElement.cpp:
3538         (WebCore::HTMLButtonElement::parseAttribute):
3539         * html/HTMLButtonElement.h:
3540         * html/HTMLCanvasElement.cpp:
3541         (WebCore::HTMLCanvasElement::parseAttribute):
3542         * html/HTMLCanvasElement.h:
3543         (HTMLCanvasElement):
3544         * html/HTMLDetailsElement.cpp:
3545         (WebCore::HTMLDetailsElement::parseAttribute):
3546         * html/HTMLDetailsElement.h:
3547         (HTMLDetailsElement):
3548         * html/HTMLElement.cpp:
3549         (WebCore::HTMLElement::parseAttribute):
3550         (WebCore::HTMLElement::dirAttributeChanged):
3551         * html/HTMLElement.h:
3552         (HTMLElement):
3553         * html/HTMLEmbedElement.cpp:
3554         (WebCore::HTMLEmbedElement::parseAttribute):
3555         * html/HTMLEmbedElement.h:
3556         (HTMLEmbedElement):
3557         * html/HTMLFormControlElement.cpp:
3558         (WebCore::HTMLFormControlElement::parseAttribute):
3559         * html/HTMLFormControlElement.h:
3560         (HTMLFormControlElement):
3561         * html/HTMLFormElement.cpp:
3562         (WebCore::HTMLFormElement::parseAttribute):
3563         * html/HTMLFormElement.h:
3564         (HTMLFormElement):
3565         * html/HTMLFrameElement.cpp:
3566         (WebCore::HTMLFrameElement::parseAttribute):
3567         * html/HTMLFrameElement.h:
3568         (HTMLFrameElement):
3569         * html/HTMLFrameElementBase.cpp:
3570         (WebCore::HTMLFrameElementBase::parseAttribute):
3571         * html/HTMLFrameElementBase.h:
3572         (HTMLFrameElementBase):
3573         * html/HTMLFrameSetElement.cpp:
3574         (WebCore::HTMLFrameSetElement::parseAttribute):
3575         * html/HTMLFrameSetElement.h:
3576         (HTMLFrameSetElement):
3577         * html/HTMLIFrameElement.cpp:
3578         (WebCore::HTMLIFrameElement::parseAttribute):
3579         * html/HTMLIFrameElement.h:
3580         (HTMLIFrameElement):
3581         * html/HTMLImageElement.cpp:
3582         (WebCore::HTMLImageElement::parseAttribute):
3583         * html/HTMLImageElement.h:
3584         (HTMLImageElement):
3585         * html/HTMLInputElement.cpp:
3586         (WebCore::HTMLInputElement::parseAttribute):
3587         (WebCore::HTMLInputElement::parseMaxLengthAttribute):
3588         * html/HTMLInputElement.h:
3589         (HTMLInputElement):
3590         * html/HTMLKeygenElement.cpp:
3591         (WebCore::HTMLKeygenElement::parseAttribute):
3592         * html/HTMLKeygenElement.h:
3593         (HTMLKeygenElement):
3594         * html/HTMLLIElement.cpp:
3595         (WebCore::HTMLLIElement::parseAttribute):
3596         * html/HTMLLIElement.h:
3597         (HTMLLIElement):
3598         * html/HTMLLinkElement.cpp:
3599         (WebCore::HTMLLinkElement::parseAttribute):
3600         * html/HTMLLinkElement.h:
3601         (HTMLLinkElement):
3602         * html/HTMLMapElement.cpp:
3603         (WebCore::HTMLMapElement::parseAttribute):
3604         * html/HTMLMapElement.h:
3605         (HTMLMapElement):
3606         * html/HTMLMediaElement.cpp:
3607         (WebCore::HTMLMediaElement::parseAttribute):
3608         * html/HTMLMediaElement.h:
3609         * html/HTMLMetaElement.cpp:
3610         (WebCore::HTMLMetaElement::parseAttribute):
3611         * html/HTMLMetaElement.h:
3612         (HTMLMetaElement):
3613         * html/HTMLMeterElement.cpp:
3614         (WebCore::HTMLMeterElement::parseAttribute):
3615         * html/HTMLMeterElement.h:
3616         (HTMLMeterElement):
3617         * html/HTMLOListElement.cpp:
3618         (WebCore::HTMLOListElement::parseAttribute):
3619         * html/HTMLOListElement.h:
3620         (HTMLOListElement):
3621         * html/HTMLObjectElement.cpp:
3622         (WebCore::HTMLObjectElement::parseAttribute):
3623         * html/HTMLObjectElement.h:
3624         (HTMLObjectElement):
3625         * html/HTMLOptGroupElement.cpp:
3626         (WebCore::HTMLOptGroupElement::parseAttribute):
3627         * html/HTMLOptGroupElement.h:
3628         * html/HTMLOptionElement.cpp:
3629         (WebCore::HTMLOptionElement::parseAttribute):
3630         * html/HTMLOptionElement.h:
3631         (HTMLOptionElement):
3632         * html/HTMLOutputElement.cpp:
3633         (WebCore::HTMLOutputElement::parseAttribute):
3634         * html/HTMLOutputElement.h:
3635         (HTMLOutputElement):
3636         * html/HTMLProgressElement.cpp:
3637         (WebCore::HTMLProgressElement::parseAttribute):
3638         * html/HTMLProgressElement.h:
3639         * html/HTMLScriptElement.cpp:
3640         (WebCore::HTMLScriptElement::parseAttribute):
3641         * html/HTMLScriptElement.h:
3642         (HTMLScriptElement):
3643         * html/HTMLSelectElement.cpp:
3644         (WebCore::HTMLSelectElement::parseAttribute):
3645         (WebCore::HTMLSelectElement::parseMultipleAttribute):
3646         * html/HTMLSelectElement.h:
3647         * html/HTMLStyleElement.cpp:
3648         (WebCore::HTMLStyleElement::parseAttribute):
3649         * html/HTMLStyleElement.h:
3650         (HTMLStyleElement):
3651         * html/HTMLTableCellElement.cpp:
3652         (WebCore::HTMLTableCellElement::parseAttribute):
3653         * html/HTMLTableCellElement.h:
3654         (HTMLTableCellElement):
3655         * html/HTMLTableColElement.cpp:
3656         (WebCore::HTMLTableColElement::parseAttribute):
3657         * html/HTMLTableColElement.h:
3658         (HTMLTableColElement):
3659         * html/HTMLTableElement.cpp:
3660         (WebCore::HTMLTableElement::parseAttribute):
3661         * html/HTMLTableElement.h:
3662         (HTMLTableElement):
3663         * html/HTMLTextAreaElement.cpp:
3664         (WebCore::HTMLTextAreaElement::parseAttribute):
3665         * html/HTMLTextAreaElement.h:
3666         (HTMLTextAreaElement):
3667         * html/HTMLTextFormControlElement.cpp:
3668         (WebCore::HTMLTextFormControlElement::parseAttribute):
3669         * html/HTMLTextFormControlElement.h:
3670         (HTMLTextFormControlElement):
3671         * html/HTMLTrackElement.cpp:
3672         (WebCore::HTMLTrackElement::parseAttribute):
3673         * html/HTMLTrackElement.h:
3674         (HTMLTrackElement):
3675         * html/HTMLVideoElement.cpp:
3676         (WebCore::HTMLVideoElement::parseAttribute):
3677         * html/HTMLVideoElement.h:
3678         (HTMLVideoElement):
3679         * html/shadow/HTMLContentElement.cpp:
3680         (WebCore::HTMLContentElement::parseAttribute):
3681         * html/shadow/HTMLContentElement.h:
3682         (HTMLContentElement):
3683         * mathml/MathMLElement.cpp:
3684         (WebCore::MathMLElement::parseAttribute):
3685         * mathml/MathMLElement.h:
3686         (MathMLElement):
3687         * svg/SVGAElement.cpp:
3688         (WebCore::SVGAElement::parseAttribute):
3689         * svg/SVGAElement.h:
3690         (SVGAElement):
3691         * svg/SVGAnimateMotionElement.cpp:
3692         (WebCore::SVGAnimateMotionElement::parseAttribute):
3693         * svg/SVGAnimateMotionElement.h:
3694         (SVGAnimateMotionElement):
3695         * svg/SVGAnimateTransformElement.cpp:
3696         (WebCore::SVGAnimateTransformElement::parseAttribute):
3697         * svg/SVGAnimateTransformElement.h:
3698         (SVGAnimateTransformElement):
3699         * svg/SVGAnimationElement.cpp:
3700         (WebCore::SVGAnimationElement::parseAttribute):
3701         * svg/SVGAnimationElement.h:
3702         (SVGAnimationElement):
3703         * svg/SVGCircleElement.cpp:
3704         (WebCore::SVGCircleElement::parseAttribute):
3705         * svg/SVGCircleElement.h:
3706         (SVGCircleElement):
3707         * svg/SVGClipPathElement.cpp:
3708         (WebCore::SVGClipPathElement::parseAttribute):
3709         * svg/SVGClipPathElement.h:
3710         (SVGClipPathElement):
3711         * svg/SVGComponentTransferFunctionElement.cpp:
3712         (WebCore::SVGComponentTransferFunctionElement::parseAttribute):
3713         * svg/SVGComponentTransferFunctionElement.h:
3714         (SVGComponentTransferFunctionElement):
3715         * svg/SVGCursorElement.cpp:
3716         (WebCore::SVGCursorElement::parseAttribute):
3717         * svg/SVGCursorElement.h:
3718         (SVGCursorElement):
3719         * svg/SVGElement.cpp:
3720         (WebCore::SVGElement::reportAttributeParsingError):
3721         (WebCore::SVGElement::parseAttribute):
3722         * svg/SVGElement.h:
3723         (SVGElement):
3724         * svg/SVGEllipseElement.cpp:
3725         (WebCore::SVGEllipseElement::parseAttribute):
3726         * svg/SVGEllipseElement.h:
3727         (SVGEllipseElement):
3728         * svg/SVGExternalResourcesRequired.cpp:
3729         (WebCore::SVGExternalResourcesRequired::parseAttribute):
3730         * svg/SVGExternalResourcesRequired.h:
3731         (SVGExternalResourcesRequired):
3732         * svg/SVGFEBlendElement.cpp:
3733         (WebCore::SVGFEBlendElement::parseAttribute):
3734         * svg/SVGFEBlendElement.h:
3735         (SVGFEBlendElement):
3736         * svg/SVGFEColorMatrixElement.cpp:
3737         (WebCore::SVGFEColorMatrixElement::parseAttribute):
3738         * svg/SVGFEColorMatrixElement.h:
3739         (SVGFEColorMatrixElement):
3740         * svg/SVGFEComponentTransferElement.cpp:
3741         (WebCore::SVGFEComponentTransferElement::parseAttribute):
3742         * svg/SVGFEComponentTransferElement.h:
3743         (SVGFEComponentTransferElement):
3744         * svg/SVGFECompositeElement.cpp:
3745         (WebCore::SVGFECompositeElement::parseAttribute):
3746         * svg/SVGFECompositeElement.h:
3747         (SVGFECompositeElement):
3748         * svg/SVGFEConvolveMatrixElement.cpp:
3749         (WebCore::SVGFEConvolveMatrixElement::parseAttribute):
3750         * svg/SVGFEConvolveMatrixElement.h:
3751         (SVGFEConvolveMatrixElement):
3752         * svg/SVGFEDiffuseLightingElement.cpp:
3753         (WebCore::SVGFEDiffuseLightingElement::parseAttribute):
3754         * svg/SVGFEDiffuseLightingElement.h:
3755         (SVGFEDiffuseLightingElement):
3756         * svg/SVGFEDisplacementMapElement.cpp:
3757         (WebCore::SVGFEDisplacementMapElement::parseAttribute):
3758         * svg/SVGFEDisplacementMapElement.h:
3759         (SVGFEDisplacementMapElement):
3760         * svg/SVGFEDropShadowElement.cpp:
3761         (WebCore::SVGFEDropShadowElement::parseAttribute):
3762         * svg/SVGFEDropShadowElement.h:
3763         (SVGFEDropShadowElement):
3764         * svg/SVGFEGaussianBlurElement.cpp:
3765         (WebCore::SVGFEGaussianBlurElement::parseAttribute):
3766         * svg/SVGFEGaussianBlurElement.h:
3767         (SVGFEGaussianBlurElement):
3768         * svg/SVGFEImageElement.cpp:
3769         (WebCore::SVGFEImageElement::parseAttribute):
3770         * svg/SVGFEImageElement.h:
3771         (SVGFEImageElement):
3772         * svg/SVGFELightElement.cpp:
3773         (WebCore::SVGFELightElement::parseAttribute):
3774         * svg/SVGFELightElement.h:
3775         (SVGFELightElement):
3776         * svg/SVGFEMergeNodeElement.cpp:
3777         (WebCore::SVGFEMergeNodeElement::parseAttribute):
3778         * svg/SVGFEMergeNodeElement.h:
3779         (SVGFEMergeNodeElement):
3780         * svg/SVGFEMorphologyElement.cpp:
3781         (WebCore::SVGFEMorphologyElement::parseAttribute):
3782         * svg/SVGFEMorphologyElement.h:
3783         (SVGFEMorphologyElement):
3784         * svg/SVGFEOffsetElement.cpp:
3785         (WebCore::SVGFEOffsetElement::parseAttribute):
3786         * svg/SVGFEOffsetElement.h:
3787         (SVGFEOffsetElement):
3788         * svg/SVGFESpecularLightingElement.cpp:
3789         (WebCore::SVGFESpecularLightingElement::parseAttribute):
3790         * svg/SVGFESpecularLightingElement.h:
3791         (SVGFESpecularLightingElement):
3792         * svg/SVGFETileElement.cpp:
3793         (WebCore::SVGFETileElement::parseAttribute):
3794         * svg/SVGFETileElement.h:
3795         (SVGFETileElement):
3796         * svg/SVGFETurbulenceElement.cpp:
3797         (WebCore::SVGFETurbulenceElement::parseAttribute):
3798         * svg/SVGFETurbulenceElement.h:
3799         (SVGFETurbulenceElement):
3800         * svg/SVGFilterElement.cpp:
3801         (WebCore::SVGFilterElement::parseAttribute):
3802         * svg/SVGFilterElement.h:
3803         (SVGFilterElement):
3804         * svg/SVGFilterPrimitiveStandardAttributes.cpp:
3805         (WebCore::SVGFilterPrimitiveStandardAttributes::parseAttribute):
3806         * svg/SVGFilterPrimitiveStandardAttributes.h:
3807         (SVGFilterPrimitiveStandardAttributes):
3808         * svg/SVGFitToViewBox.h:
3809         (WebCore::SVGFitToViewBox::parseAttribute):
3810         * svg/SVGFontFaceElement.cpp:
3811         (WebCore::SVGFontFaceElement::parseAttribute):
3812         * svg/SVGFontFaceElement.h:
3813         (SVGFontFaceElement):
3814         * svg/SVGFontFaceUriElement.cpp:
3815         (WebCore::SVGFontFaceUriElement::parseAttribute):
3816         * svg/SVGFontFaceUriElement.h:
3817         (SVGFontFaceUriElement):
3818         * svg/SVGForeignObjectElement.cpp:
3819         (WebCore::SVGForeignObjectElement::parseAttribute):
3820         * svg/SVGForeignObjectElement.h:
3821         (SVGForeignObjectElement):
3822         * svg/SVGGElement.cpp:
3823         (WebCore::SVGGElement::parseAttribute):
3824         * svg/SVGGElement.h:
3825         (SVGGElement):
3826         * svg/SVGGlyphElement.cpp:
3827         (WebCore::SVGGlyphElement::parseAttribute):
3828         * svg/SVGGlyphElement.h:
3829         (SVGGlyphElement):
3830         * svg/SVGGlyphRefElement.cpp:
3831         (WebCore::SVGGlyphRefElement::parseAttribute):
3832         * svg/SVGGlyphRefElement.h:
3833         * svg/SVGGradientElement.cpp:
3834         (WebCore::SVGGradientElement::parseAttribute):
3835         * svg/SVGGradientElement.h:
3836         * svg/SVGImageElement.cpp:
3837         (WebCore::SVGImageElement::parseAttribute):
3838         * svg/SVGImageElement.h:
3839         (SVGImageElement):
3840         * svg/SVGLangSpace.cpp:
3841         (WebCore::SVGLangSpace::parseAttribute):
3842         * svg/SVGLangSpace.h:
3843         (SVGLangSpace):
3844         * svg/SVGLineElement.cpp:
3845         (WebCore::SVGLineElement::parseAttribute):
3846         * svg/SVGLineElement.h:
3847         (SVGLineElement):
3848         * svg/SVGLinearGradientElement.cpp:
3849         (WebCore::SVGLinearGradientElement::parseAttribute):
3850         * svg/SVGLinearGradientElement.h:
3851         (SVGLinearGradientElement):
3852         * svg/SVGMPathElement.cpp:
3853         (WebCore::SVGMPathElement::parseAttribute):
3854         * svg/SVGMPathElement.h:
3855         (SVGMPathElement):
3856         * svg/SVGMarkerElement.cpp:
3857         (WebCore::SVGMarkerElement::parseAttribute):
3858         * svg/SVGMarkerElement.h:
3859         (SVGMarkerElement):
3860         * svg/SVGMaskElement.cpp:
3861         (WebCore::SVGMaskElement::parseAttribute):
3862         * svg/SVGMaskElement.h:
3863         (SVGMaskElement):
3864         * svg/SVGPathElement.cpp:
3865         (WebCore::SVGPathElement::parseAttribute):
3866         * svg/SVGPathElement.h:
3867         (SVGPathElement):
3868         * svg/SVGPatternElement.cpp:
3869         (WebCore::SVGPatternElement::parseAttribute):
3870         * svg/SVGPatternElement.h:
3871         (SVGPatternElement):
3872         * svg/SVGPolyElement.cpp:
3873         (WebCore::SVGPolyElement::parseAttribute):
3874         * svg/SVGPolyElement.h:
3875         (SVGPolyElement):
3876         * svg/SVGRadialGradientElement.cpp:
3877         (WebCore::SVGRadialGradientElement::parseAttribute):
3878         * svg/SVGRadialGradientElement.h:
3879         (SVGRadialGradientElement):
3880         * svg/SVGRectElement.cpp:
3881         (WebCore::SVGRectElement::parseAttribute):
3882         * svg/SVGRectElement.h:
3883         (SVGRectElement):
3884         * svg/SVGSVGElement.cpp:
3885         (WebCore::SVGSVGElement::parseAttribute):
3886         * svg/SVGSVGElement.h:
3887         (SVGSVGElement):
3888         * svg/SVGScriptElement.cpp:
3889         (WebCore::SVGScriptElement::parseAttribute):
3890         * svg/SVGScriptElement.h:
3891         (SVGScriptElement):
3892         * svg/SVGStopElement.cpp:
3893         (WebCore::SVGStopElement::parseAttribute):
3894         * svg/SVGStopElement.h:
3895         (SVGStopElement):
3896         * svg/SVGStyleElement.cpp:
3897         (WebCore::SVGStyleElement::parseAttribute):
3898         * svg/SVGStyleElement.h:
3899         (SVGStyleElement):
3900         * svg/SVGStyledElement.cpp:
3901         (WebCore::SVGStyledElement::parseAttribute):
3902         * svg/SVGStyledElement.h:
3903         (SVGStyledElement):
3904         * svg/SVGStyledTransformableElement.cpp:
3905         (WebCore::SVGStyledTransformableElement::parseAttribute):
3906         * svg/SVGStyledTransformableElement.h:
3907         (SVGStyledTransformableElement):
3908         * svg/SVGSymbolElement.cpp:
3909         (WebCore::SVGSymbolElement::parseAttribute):
3910         * svg/SVGSymbolElement.h:
3911         (SVGSymbolElement):
3912         * svg/SVGTRefElement.cpp:
3913         (WebCore::SVGTRefElement::parseAttribute):
3914         * svg/SVGTRefElement.h:
3915         (SVGTRefElement):
3916         * svg/SVGTests.cpp:
3917         (WebCore::SVGTests::parseAttribute):
3918         * svg/SVGTests.h:
3919         (SVGTests):
3920         * svg/SVGTextContentElement.cpp:
3921         (WebCore::SVGTextContentElement::parseAttribute):
3922         * svg/SVGTextContentElement.h:
3923         (SVGTextContentElement):
3924         * svg/SVGTextElement.cpp:
3925         (WebCore::SVGTextElement::parseAttribute):
3926         * svg/SVGTextElement.h:
3927         (SVGTextElement):
3928         * svg/SVGTextPathElement.cpp:
3929         (WebCore::SVGTextPathElement::parseAttribute):
3930         * svg/SVGTextPathElement.h:
3931         * svg/SVGTextPositioningElement.cpp:
3932         (WebCore::SVGTextPositioningElement::parseAttribute):
3933         * svg/SVGTextPositioningElement.h:
3934         (SVGTextPositioningElement):
3935         * svg/SVGURIReference.cpp:
3936         (WebCore::SVGURIReference::parseAttribute):
3937         * svg/SVGURIReference.h:
3938         (SVGURIReference):
3939         * svg/SVGUseElement.cpp:
3940         (WebCore::SVGUseElement::parseAttribute):
3941         * svg/SVGUseElement.h:
3942         (SVGUseElement):
3943         * svg/SVGViewElement.cpp:
3944         (WebCore::SVGViewElement::parseAttribute):
3945         * svg/SVGViewElement.h:
3946         (SVGViewElement):
3947         * svg/SVGZoomAndPan.h:
3948         (WebCore::SVGZoomAndPan::parseAttribute):
3949         * svg/animation/SVGSMILElement.cpp:
3950         (WebCore::SVGSMILElement::parseAttribute):
3951         * svg/animation/SVGSMILElement.h:
3952         (SVGSMILElement):
3953
3954 2012-11-18  Andreas Kling  <akling@apple.com>
3955
3956         StyleResolver: No need to compare "cellpadding" attributes when evaluating style sharing candidates.
3957         <http://webkit.org/b/102596>
3958
3959         Reviewed by Antti Koivisto.
3960
3961         Differences in the cellpadding attribute is caught by comparing additionalPresentationAttributeStyle()
3962         later on in canShareStyleWithElement() and we shouldn't waste time on comparing them.
3963
3964         * css/StyleResolver.cpp:
3965         (WebCore::haveIdenticalStyleAffectingAttributes):
3966
3967 2012-11-17  Jon Lee  <jonlee@apple.com>
3968
3969         Simulated mouse events should return an accurate offset
3970         https://bugs.webkit.org/show_bug.cgi?id=102606
3971         <rdar://problem/12725627>
3972
3973         Reviewed by Brady Eidson.
3974
3975         A check to see if the event is simulated prior to calculating the offset has existed for a
3976         long time (since at least r14916). Back then the check was needed because the offset was
3977         incrementally adjusted when the target was assigned (through
3978         MouseRelatedEvent::receivedTarget()).
3979
3980         Since r82225, we started calculating the offset only when needed, and calculating the offset
3981         from scratch rather than incrementally adjusting it. Since we recalculate from scratch,
3982         the isSimulated check is irrelevant, and we should remove it.
3983
3984         Tests are not possible because all uses of simulated mouse events provide no underlying
3985         event, so the offset is never recalculated.
3986
3987         * dom/MouseRelatedEvent.cpp:
3988         (WebCore::MouseRelatedEvent::computeRelativePosition): Remove the m_isSimulated check.
3989
3990 2012-11-17  Simon Fraser  <simon.fraser@apple.com>
3991
3992         Don't say there are dirty overlay scrollbars when they are clipped out
3993         https://bugs.webkit.org/show_bug.cgi?id=102609
3994
3995         Reviewed by Brady Eidson.
3996
3997         Painting overlay scrollbars involves a second painting pass over the entire
3998         RenderLayer subtree for a compositing layer, which can be very expensive.
3999         
4000         Avoid this when possible by detecting when overflow controls are not in
4001         the damage rect.
4002
4003         * rendering/RenderLayer.cpp:
4004         (WebCore::RenderLayer::rectForHorizontalScrollbar): Compute a local rect
4005         for the horizontal scrollbar.
4006         (WebCore::RenderLayer::rectForVerticalScrollbar): Compute a local rect
4007         for the vertical scrollbar.
4008         (WebCore::RenderLayer::positionOverflowControls): Use rectForHorizontalScrollbar()
4009         and rectForVerticalScrollbar().
4010         (WebCore::RenderLayer::overflowControlsIntersectRect): Return true if any
4011         of the present overflow controls intersect the given local rect.
4012         (WebCore::RenderLayer::paintOverflowControls): Bail if the damage rect
4013         doesn't intersect any of the overflow controls.
4014         * rendering/RenderLayer.h:
4015         (RenderLayer):
4016
4017 2012-11-17  Adam Barth  <abarth@webkit.org>
4018
4019         REGRESSION (r133633): ASSERTION FAILED: m_wrapper || !m_jsFunction
4020         https://bugs.webkit.org/show_bug.cgi?id=101428
4021
4022         Reviewed by Geoffrey Garen.
4023
4024         JSNodeOwner has some smarts that wrappers of subclasses of Node need to
4025         call during garbage collection. This patch teaches subclasses of Node
4026         to have their JSMumbleOwner objects inherit from JSNodeOwner.
4027
4028         The immediate benefit of this patch is that we correctly avoid
4029         collecting wrappers for HTMLAudioElements when they are reachable from
4030         the DOM.
4031
4032         * bindings/scripts/CodeGeneratorJS.pm:
4033         (GenerateHeader):
4034         (GenerateImplementation):
4035
4036 2012-11-17  Elliott Sprehn  <esprehn@chromium.org>
4037
4038         Expose JSObject::removeDirect and PrivateName to WebCore
4039         https://bugs.webkit.org/show_bug.cgi?id=102546
4040
4041         Reviewed by Geoffrey Garen.
4042
4043         Add forwarding header for PrivateName, so JSDependentRetained works.
4044
4045         No new tests, just adding headers.
4046
4047         * ForwardingHeaders/runtime/PrivateName.h: Added.
4048
4049 2012-11-17  Simon Fraser  <simon.fraser@apple.com>
4050
4051         Reduce the crazy number of parameters to RenderLayer clip-rect functions
4052         https://bugs.webkit.org/show_bug.cgi?id=102604
4053
4054         Reviewed by Dan Bernstein.
4055
4056         Many of the RenderLayer member functions related to clip rect computation
4057         took a long list of similar parameters. Gather these into a struct, ClipRectsContext,
4058         that we pass to these functions
4059         
4060         No functional changes.
4061
4062         * rendering/RenderLayer.cpp:
4063         (WebCore::RenderLayer::paintLayer):
4064         (WebCore::RenderLayer::paintLayerContents):
4065         (WebCore::RenderLayer::hitTestLayer):
4066         (WebCore::RenderLayer::updateClipRects):
4067         (WebCore::RenderLayer::calculateClipRects):
4068         (WebCore::RenderLayer::parentClipRects):
4069         (WebCore::RenderLayer::backgroundClipRect):
4070         (WebCore::RenderLayer::calculateRects):
4071         (WebCore::RenderLayer::childrenClipRect):
4072         (WebCore::RenderLayer::selfClipRect):
4073         (WebCore::RenderLayer::localClipRect):
4074         * rendering/RenderLayer.h:
4075         (WebCore::RenderLayer::ClipRectsContext::ClipRectsContext):
4076         (ClipRectsContext):
4077         (RenderLayer):
4078         (WebCore::RenderLayer::clipRects):
4079         * rendering/RenderLayerBacking.cpp:
4080         (WebCore::RenderLayerBacking::updateCompositedBounds):
4081         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
4082         * rendering/RenderLayerCompositor.cpp:
4083         (WebCore::RenderLayerCompositor::addToOverlapMap):
4084         (WebCore::RenderLayerCompositor::clippedByAncestor):
4085         * rendering/RenderTreeAsText.cpp:
4086         (WebCore::writeLayers):
4087
4088 2012-11-17  Simon Fraser  <simon.fraser@apple.com>
4089
4090         Simplify bounds computation for the RenderView's layer
4091         https://bugs.webkit.org/show_bug.cgi?id=102597
4092
4093         Reviewed by Anders Carlsson.
4094
4095         Computing the bounds of the main layer (that of the RenderView) used to do
4096         a full RenderLayer walk, taking the union of the bounds of all the sublayers,
4097         which is very expensive on large pages.
4098         
4099         For the RenderView we can avoid that entirely and just use the RenderView's
4100         document rect. Since page scaling happens as a transform on this layer,
4101         we want the unscaled document rect.
4102
4103         * rendering/RenderLayer.cpp:
4104         (WebCore::RenderLayer::calculateLayerBounds):
4105
4106 2012-11-17  Eric Seidel  <eric@webkit.org>
4107
4108         Add ScriptWrappable to more WebCore classes which are commonly JS-wrapped
4109         https://bugs.webkit.org/show_bug.cgi?id=102601
4110
4111         Reviewed by Adam Barth.
4112
4113         From my investigations all of these classes exist only to be exposed
4114         to the web (via JavaScript) and are not used internally by WebCore.
4115         I beleive all of them always have wrappers.
4116         These were found using this code:
4117         https://bugs.webkit.org/show_bug.cgi?id=102539#c2
4118
4119         Geolocation -- navigator.geolocation
4120         WebKitCSSMatrix -- represent matrixes in JS through various APIs
4121         DOMStringMap, NamedNodeMap, NodeIterator, TreeWalker -- exclusively for the DOM API
4122         Blob, FileList - used by the File, Clipboard and XHR, also exclusively as API
4123         ValidityState -- formControl.validity
4124         CanvasRenderingContext -- canvas.getContext()
4125         DOMApplicationCache -- window.appcache
4126         Screen -- window.screen
4127         DOMMimeTypeArray -- navigator.mimetypes
4128         DOMPlugin -- navigator.plugins[0]
4129         DOMPluginArray -- navigator.plugins
4130
4131         * Modules/geolocation/Geolocation.h:
4132         * css/WebKitCSSMatrix.h:
4133         * dom/DOMStringMap.h:
4134         * dom/NamedNodeMap.h:
4135         * dom/NodeIterator.h:
4136         * dom/TreeWalker.h:
4137         * fileapi/Blob.h:
4138         * fileapi/FileList.h: (had to un-indent to make check-webkit-style happy)
4139         (FileList):
4140         (WebCore::FileList::create):
4141         (WebCore::FileList::length):
4142         (WebCore::FileList::isEmpty):
4143         (WebCore::FileList::clear):
4144         (WebCore::FileList::append):
4145         * html/ValidityState.h:
4146         * html/canvas/CanvasRenderingContext.h:
4147         * loader/appcache/DOMApplicationCache.h:
4148         * page/Screen.h:
4149         * platform/graphics/wince/MediaPlayerProxy.cpp:
4150         (WebCore::WebMediaPlayerProxy::initEngine): This code was wrong, fixed to use internal APIs.
4151         * plugins/DOMMimeTypeArray.h:
4152         * plugins/DOMPlugin.h:
4153         * plugins/DOMPluginArray.h:
4154
4155 2012-11-17  Alexandru Chiculita  <achicu@adobe.com>
4156
4157         [Texmap][CSS Shaders] Reuse the precompiled shader for custom filters in TextureMapperGL
4158         https://bugs.webkit.org/show_bug.cgi?id=101801
4159
4160         Reviewed by Noam Rosenthal.
4161
4162         Added a HashMap in TextureMapperGL to store the precompiled versions of the shaders.
4163         Also added a new API on TextureMapper that receives a notification when the shader
4164         is no longer needed.
4165
4166         No new tests, the code is tested by existing tests.
4167
4168         * platform/graphics/filters/CustomFilterOperation.h:
4169         (WebCore::CustomFilterOperation::setProgram):
4170         (CustomFilterOperation): Made the constructor protected, so that we can overwrite the class in WK2.
4171         * platform/graphics/filters/CustomFilterValidatedProgram.cpp:
4172         (WebCore::CustomFilterValidatedProgram::validatedProgramInfo):
4173         (WebCore):
4174         * platform/graphics/filters/CustomFilterValidatedProgram.h:
4175         (CustomFilterValidatedProgram):
4176         * platform/graphics/texmap/TextureMapper.h:
4177         (WebCore):
4178         (TextureMapper):
4179         (WebCore::TextureMapper::removeCachedCustomFilterProgram):
4180         Function to be called by the platform code, when the shader is no longer
4181         needed. This implementation is empty and overridden in TextureMapperGL.
4182         * platform/graphics/texmap/TextureMapperGL.cpp:
4183         (WebCore::TextureMapperGL::removeCachedCustomFilterProgram):
4184         Removes the compiled shader from the cache. This is called from WK2 when the compiled shader
4185         is no longer needed.
4186         (WebCore):
4187         (WebCore::TextureMapperGL::drawUsingCustomFilter): The first time it uses a new
4188         shader it will cache the compiled version until removeCachedCustomFilterProgram is called.
4189         * platform/graphics/texmap/TextureMapperGL.h:
4190         (WebCore):
4191         (TextureMapperGL):
4192
4193 2012-11-17  Brady Eidson  <beidson@apple.com>
4194
4195         Add an integer identifier field to AuthenticationChallengeBase.
4196         https://bugs.webkit.org/show_bug.cgi?id=102593
4197
4198         Reviewed by Darin Adler.
4199
4200         This is to support linking two different challenges that might not compare as equal but that 
4201         represent the same logical authentication challenge.
4202
4203         One example is in an IPC environment where the platform challenge can only exist in one process.
4204
4205         No new tests (Platform support, no effect in tested configs).
4206
4207         * WebCore.exp.in:
4208
4209         * platform/network/AuthenticationChallengeBase.cpp:
4210         (WebCore::AuthenticationChallengeBase::AuthenticationChallengeBase):
4211         * platform/network/AuthenticationChallengeBase.h:
4212         (WebCore::AuthenticationChallengeBase::identifier):
4213
4214         * platform/network/cf/AuthenticationChallenge.h:
4215         * platform/network/mac/AuthenticationMac.mm:
4216         (WebCore::generateUniqueIdentifier):
4217         (WebCore::AuthenticationChallenge::AuthenticationChallenge): Generate a new unique identifier whenever
4218           constructing a challenge from an NSURLAuthenticationChallenge.
4219
4220         * platform/network/cf/AuthenticationCF.cpp:
4221         (WebCore::generateUniqueIdentifier):
4222         (WebCore::AuthenticationChallenge::AuthenticationChallenge): Generate a new unique identifier whenever
4223           constructing a challenge from a CFURLAuthChallengeRef.
4224
4225         Implement the new constructor form for ports relevant to WebKit2:
4226         * platform/network/qt/AuthenticationChallenge.h:
4227         (WebCore::AuthenticationChallenge::AuthenticationChallenge):
4228         * platform/network/soup/AuthenticationChallenge.h:
4229         (WebCore::AuthenticationChallenge::AuthenticationChallenge):
4230         * platform/network/win/AuthenticationChallenge.h:
4231         (WebCore::AuthenticationChallenge::AuthenticationChallenge):
4232
4233 2012-11-17  Simon Fraser  <simon.fraser@apple.com>
4234
4235         Dump the tile cache extent in layout tests
4236         https://bugs.webkit.org/show_bug.cgi?id=102600
4237
4238         Reviewed by Anders Carlsson.
4239
4240         When dumping tiled layer stats in layout tests, also dump the extent
4241         of the tile grid. This will allow us to detect issues related
4242         to zooming, which is not possible with the existing tile coverage rect,
4243         which is dumped in layer (not tile) coordinates.
4244
4245         * platform/graphics/TiledBacking.h: Added tileGridExtent().
4246         * platform/graphics/ca/GraphicsLayerCA.cpp:
4247         (WebCore::GraphicsLayerCA::dumpAdditionalProperties): Dump the tile grid extent.
4248         * platform/graphics/ca/mac/TileCache.h: tileCoverageRect() should be OVERRIDE.
4249         * platform/graphics/ca/mac/TileCache.mm:
4250         (WebCore::TileCache::getTileIndexRangeForRect):
4251         (WebCore::TileCache::tileGridExtent): Return a rect with the size of
4252         the grid as top,left width,height.
4253
4254 2012-11-17  Andreas Kling  <akling@apple.com>
4255
4256         Avoid full style recalc when 'style' attribute changes.
4257         <http://webkit.org/b/78718>
4258
4259         Reviewed by Anders Carlsson.
4260
4261         Use setNeedsStyleRecalc(InlineStyleChange) when the 'style' attribute changes
4262         to reduce the amount of work done in recalcStyle().
4263
4264         * dom/StyledElement.cpp:
4265         (WebCore::StyledElement::styleAttributeChanged):
4266
4267 2012-11-17  Li Yin  <li.yin@intel.com>
4268
4269         Remove coneGain and distanceGain attributes from PannerNode.idl
4270         https://bugs.webkit.org/show_bug.cgi?id=102343
4271
4272         Reviewed by Chris Rogers.
4273
4274         Removing .coneGain and .distanceGain as publicly accessible values,
4275         since normally they only need to be calculated internally.
4276
4277         No changes to tests, since these attributes were not tested and are being removed.
4278
4279         * Modules/webaudio/PannerNode.idl:
4280
4281 2012-11-17  Balazs Kelemen  <kbalazs@webkit.org>
4282
4283         [Coordinated Graphics] Resumed animations leave an obsolate GraphicsLayerAnimation behind
4284         https://bugs.webkit.org/show_bug.cgi?id=102530
4285
4286         Reviewed by Noam Rosenthal.
4287
4288         GraphicsLayer::addAnimation is called no only when a new animation is created
4289         but also when resuming a paused animation. If this is a resumed animation we
4290         should remove the obsolate GraphicsLayerAnimation object.
4291
4292         Tested by animations tests.
4293
4294         * platform/graphics/GraphicsLayerAnimation.cpp:
4295         (WebCore::GraphicsLayerAnimations::add):
4296
4297 2012-11-17  Martin Robinson  <mrobinson@igalia.com>
4298
4299         [Soup] CredentialStorage should only be used for HTTP-family requests
4300         https://bugs.webkit.org/show_bug.cgi?id=102582
4301
4302         Reviewed by Gustavo Noronha Silva.
4303
4304         Do not use CredentialStorage when handling non-HTTP family requests. CredentialStorage
4305         only expects to handle requests in the HTTP family.
4306
4307         No new tests. This is covered by existing tests.
4308
4309         * platform/network/ResourceHandle.h:
4310         (ResourceHandle): Add a shouldUseCredentialStorage helper to ResourceHandle. This
4311         helper returns false when firstRequest() is a non-HTTP family request.
4312         * platform/network/soup/ResourceHandleSoup.cpp:
4313         (WebCore::applyAuthenticationToRequest): Use the new helper.
4314         (WebCore::createSoupRequestAndMessageForHandle): Ditto.
4315         (WebCore::ResourceHandle::start): Ditto.
4316         (WebCore::ResourceHandle::shouldUseCredentialStorage): Ditto.
4317         (WebCore::ResourceHandle::didReceiveAuthenticationChallenge): Ditto.
4318         (WebCore::ResourceHandle::receivedCredential): Ditto.
4319
4320 2012-11-16  Patrick Gansterer  <paroga@webkit.org>
4321
4322         Build fix for !USE(ACCELERATED_COMPOSITING) after r135029.
4323
4324         * rendering/RenderLayer.cpp:
4325         (WebCore::RenderLayer::paintOverflowControls):
4326
4327 2012-11-16  Benjamin Poulain  <bpoulain@apple.com>
4328
4329         Improve the performance of rect transform
4330         https://bugs.webkit.org/show_bug.cgi?id=101828
4331
4332         Reviewed by Simon Fraser.
4333
4334         Mapping a rect and a quad by a transform is a common operation because
4335         we use it to recompute the repaint rect, overflow rect, etc.
4336
4337         The way it was done, is by transforming through mapRect()->mapQuad()->4 times mapPoint().
4338         Each of those functions tests isIdentityOrTranslation() which has to read the whole matrix
4339         and perform many comparison.
4340         Because of that, the simple mapping of a rect was loading and checking the matrix 5 times
4341         too many.
4342
4343         This patch just cut the intermediary calls.
4344
4345         On ARM, putting the operation together also has the advantage of loading the matrix
4346         only once in registers and reusing it for every point.
4347
4348         * platform/graphics/transforms/TransformationMatrix.cpp:
4349         (WebCore::TransformationMatrix::mapPoint):
4350         (WebCore::TransformationMatrix::mapRect):
4351         * platform/graphics/transforms/TransformationMatrix.h:
4352         (WebCore):
4353         (WebCore::TransformationMatrix::mapPointImpl): New convenience function to perform the
4354         point project without doing isIdentityOrTranslation().
4355
4356 2012-11-16  Simon Fraser  <simon.fraser@apple.com>
4357
4358         Avoid calling the virtual isBlockFlow() in RenderBox::computeRectForRepaint()
4359         https://bugs.webkit.org/show_bug.cgi?id=102581
4360
4361         Reviewed by Dan Bernstein.
4362
4363         isBlockFlow() is a virtual function call, and shows up in profiles of
4364         Facebook pages as called from RenderBox::computeRectForRepaint().
4365         
4366         It's faster to do the hasColumns() bit-check first. Also replace
4367         a call to layer() with the hasLayer() bit-check.        
4368
4369         * rendering/RenderBox.cpp:
4370         (WebCore::RenderBox::computeRectForRepaint):
4371
4372 2012-11-16  Sheriff Bot  <webkit.review.bot@gmail.com>
4373
4374         Unreviewed, rolling out r134817.
4375         http://trac.webkit.org/changeset/134817
4376         https://bugs.webkit.org/show_bug.cgi?id=102576
4377
4378         Broke iframes and causing tons of crashes on ClusterFuzz
4379         (Requested by inferno-sec on #webkit).
4380
4381         * dom/ContainerNode.cpp:
4382         (WebCore::willRemoveChildren):
4383         * dom/ContainerNodeAlgorithms.cpp:
4384         (WebCore::ChildFrameDisconnector::collectDescendant):
4385         * dom/ContainerNodeAlgorithms.h:
4386         (WebCore::ChildFrameDisconnector::ChildFrameDisconnector):
4387         (WebCore::ChildFrameDisconnector::~ChildFrameDisconnector):
4388         (ChildFrameDisconnector):
4389         (WebCore::ChildFrameDisconnector::collectDescendant):
4390         (WebCore::ChildFrameDisconnector::disconnect):
4391         * dom/Node.cpp:
4392         * dom/Node.h:
4393         (Node):
4394         * dom/NodeRareData.h:
4395         (WebCore::NodeRareData::NodeRareData):
4396         (NodeRareData):
4397         * html/HTMLFrameOwnerElement.cpp:
4398         (WebCore::HTMLFrameOwnerElement::setContentFrame):
4399         (WebCore::HTMLFrameOwnerElement::disconnectContentFrame):
4400
4401 2012-11-16  Simon Fraser  <simon.fraser@apple.com>
4402
4403         Fix overlay scrollbar painting in compositing layers
4404         https://bugs.webkit.org/show_bug.cgi?id=102442
4405
4406         Reviewed by Beth Dakin.
4407
4408         There were two issues with overlay scrollbar painting in
4409         compositing layers.
4410         
4411         First, we'd only ever call setContainsDirtyOverlayScrollbars()
4412         on the RenderView's layer, even when encountering an overlay scrollbar
4413         in some descendant compositing layer. This meant that we'd never
4414         run the paintOverlayScrollbars() code for those child compositing
4415         layers, so sometimes scrollbars were missing there.
4416         
4417         Even after fixing that, we would fail to render scrollbars that
4418         were not in the composited RenderLayer itself. This happened because
4419         we called into RenderLayer::paintOverlayScrollbars(), which called
4420         paintLayer() with flags that only said to paint the overlay scrollbars
4421         but not any descendants, so this paint path would not walk child
4422         RenderLayers.
4423         
4424         Also remove the containsScrollableAreaWithOverlayScrollbars() flag on
4425         ScrollView which is no longer used.
4426
4427         * platform/ScrollView.cpp:
4428         (WebCore::ScrollView::ScrollView): Remove containsScrollableAreaWithOverlayScrollbars().
4429         (WebCore::ScrollView::paint): Remove setting of m_containsScrollableAreaWithOverlayScrollbars.
4430         * platform/ScrollView.h:
4431         * rendering/RenderLayer.cpp:
4432         (WebCore::RenderLayer::paintOverflowControls): Call setContainsDirtyOverlayScrollbars()
4433         on the compositing ancestor or the root.
4434         Remove call to setContainsScrollableAreaWithOverlayScrollbars().
4435         (WebCore::RenderLayer::paintOverlayScrollbars): When painting overlay
4436         scrollbars, no need to say we have transparency, and no need to use 
4437         temporary clip rects.
4438         (WebCore::RenderLayer::paintLayer): The PaintLayerPaintingOverlayScrollbars
4439         check here was only needed because the compositing entrypoint to painting
4440         overlay scrollbars went via paintLayer(), which isn't normally used as
4441         a composited painting entry point. Now that we no longer call that, we
4442         don't need this special check.
4443         * rendering/RenderLayerBacking.cpp:
4444         (WebCore::RenderLayerBacking::paintIntoLayer): Jump into overlay scrollbar
4445         painting via paintLayerContents(), not paintOverlayScrollbars(), since
4446         the latter does not traverse sublayers.
4447
4448 2012-11-16  Joshua Bell  <jsbell@chromium.org>
4449
4450         IndexedDB: Assert hit when getting non-existent object store in version change transaction
4451         https://bugs.webkit.org/show_bug.cgi?id=102547
4452
4453         Reviewed by Tony Chang.
4454
4455         Code did not account for the not-found case in "versionchange" transactions, where all
4456         object stores are implicitly in scope.
4457
4458         Test: storage/indexeddb/object-lookups-in-versionchange.html
4459
4460         * Modules/indexeddb/IDBTransaction.cpp:
4461         (WebCore::IDBTransaction::objectStore):
4462
4463 2012-11-12  Simon Fraser  <simon.fraser@apple.com>
4464
4465         Eliminate ancestor tree walk computing outlineBoundsForRepaint() when updating layer positions
4466         https://bugs.webkit.org/show_bug.cgi?id=101874
4467
4468         Reviewed by Dave Hyatt.
4469
4470         RenderLayer::updateLayerPositions() and updateLayerPositionsAfterScroll() spend a
4471         lot of time in computeRepaintRects(), which does two ancestor tree walks, once
4472         for clippedOverflowRectForRepaint(), and one for outlineBoundsForRepaint().
4473
4474         Eliminate the ancestor tree walk in outlineBoundsForRepaint() by maintaining
4475         a RenderGeometryMap as we traverse the layer tree, and then using it to map
4476         the outline bounds to the repaint container. Replace the hokey cached offsetFromRoot
4477         now that the RenderGeometryMap can do a better job.
4478         
4479         The clipped overflow rect cannot be mapped simply, so cannot yet make use of
4480         the geometry map.
4481         
4482         Modify the RenderGeometryMap to support mapping to some repaintContainer ancestor.
4483         Add a RenderObject walk that is necessary to detect flipped writing mode blocks.
4484         
4485         Pass the RenderGeometryMap as an optional parameter to outlineBoundsForRepaint.
4486         
4487         * page/FrameView.cpp:
4488         (WebCore::FrameView::layout): Make a RenderGeometryMap and pass it down
4489         to updateLayerPositions(). For partial layouts, we have to push layers
4490         between the root and the enclosing layer of the layout subtree.
4491         The geometry map used for repainting does not use SnapOffsetForTransforms,
4492         so initialize it explicitly with just the UseTransforms flag.
4493         (WebCore::FrameView::repaintFixedElementsAfterScrolling): Make a RenderGeometryMap
4494         to pass along to updateLayerPositionsAfterScroll().
4495         * rendering/RenderBox.cpp:
4496         (WebCore::RenderBox::outlineBoundsForRepaint): Replace the optional cachedOffsetToRepaintContainer
4497         parameter with an optional RenderGeometryMap, and it use to map the compute rect to
4498         repaintContainer coordinates.
4499         * rendering/RenderBox.h:
4500         * rendering/RenderGeometryMap.cpp:
4501         (WebCore::RenderGeometryMap::RenderGeometryMap): This now has to store the mapping
4502         flags to use, so that its behavior can match that of mapLocalToContainer(). The
4503         pertinent flag is the confusingly named SnapOffsetForTransforms.
4504         (WebCore::RenderGeometryMap::absolutePoint): Call the new mapToContainer() with
4505         a null container.
4506         (WebCore::RenderGeometryMap::absoluteRect): Ditto.
4507         (WebCore::RenderGeometryMap::mapToContainer): Map to the supplied container,
4508         asserting that we found it. Add point- and rect-based mapping methods
4509         akin to the old absoluteRect/absolutePoint.
4510         (WebCore::canMapViaLayer): We need to test for isRenderFlowThread() here too.
4511         (WebCore::RenderGeometryMap::pushMappingsToAncestor): When mapping via
4512         layers, ensure that the RenderView is pushed as the first step.
4513         * rendering/RenderGeometryMap.h:
4514         (RenderGeometryMap):
4515         * rendering/RenderLayer.cpp:
4516         (WebCore::RenderLayer::updateLayerPositionsAfterLayout): New wrapper for updateLayerPositions()
4517         that makes the geometry map.
4518         (WebCore::RenderLayer::updateLayerPositionsAfterScroll): New wrapper for updateLayerPositionsAfterScroll
4519         that makes the geometry map.
4520         (WebCore::RenderLayer::updateLayerPositions): Now takes an optional RenderGeometryMap.
4521         Remove the old offsetFromRoot code. Push and pop layers to/from the geometry map. Use
4522         the geometry map to get the offsetFromRoot as needed by overflow controls. Pass
4523         it to computeRepaintRects().
4524         (WebCore::RenderLayer::computeRepaintRects): Pass the geometry map to outlineBoundsForRepaint().
4525         (WebCore::RenderLayer::updateLayerPositionsAfterScroll): Push and pop to/from the
4526         geometry map, and pass it to computeRepaintRects().
4527         (WebCore::RenderLayer::removeOnlyThisLayer): Remove the offsetFromRootBeforeMove
4528         computation; this could use a geometry map in future if it is shown to be a bottleneck.
4529         * rendering/RenderLayer.h:
4530         (WebCore::RenderLayer::canUseConvertToLayerCoords): It was thought that the isComposited()
4531         was there because the older cached offsetFromRoot logic was sensitive to compositing,
4532         but convertToLayerCoords() is not affected by compositing so this check is not needed,
4533         and actually harmful.
4534         * rendering/RenderLayerCompositor.cpp:
4535         (WebCore::RenderLayerCompositor::OverlapMap::OverlapMap): The geometry map
4536         used for overlap testing should not use SnapOffsetForTransforms, so initialize
4537         it explicitly with just the UseTransforms flag.
4538         * rendering/RenderObject.h:
4539         (WebCore::RenderObject::outlineBoundsForRepaint):
4540         * rendering/svg/RenderSVGModelObject.cpp:
4541         (WebCore::RenderSVGModelObject::outlineBoundsForRepaint):
4542         * rendering/svg/RenderSVGModelObject.h:
4543         (RenderSVGModelObject):
4544
4545 2012-11-16  Alec Flett  <alecflett@chromium.org>
4546
4547         Add tests for explicit serialization values
4548         https://bugs.webkit.org/show_bug.cgi?id=96818
4549
4550         Reviewed by Adam Barth.
4551
4552         Expose direct access to the serialization/deserialization mechanisms
4553         of SerializedScriptValue to DumpRenderTree.
4554
4555         * testing/Internals.cpp:
4556         (WebCore::Internals::serializeObject):
4557         (WebCore):
4558         (WebCore::Internals::deserializeBuffer):
4559         * testing/Internals.h:
4560         (WebCore):
4561         * testing/Internals.idl:
4562
4563 2012-11-16  Andreas Kling  <akling@apple.com>
4564
4565         Exploit shared attribute data to avoid parsing identical "style" attributes.
4566         <http://webkit.org/b/101163>
4567
4568         Reviewed by Antti Koivisto.
4569
4570         Track the "inline style dirty" state on ElementAttributeData instead of in a Node flag.
4571         This allows us to avoid duplicate work for ElementAttributeData that are shared between multiple elements,
4572         since the state is no longer per-Element.
4573
4574         * css/StyleResolver.cpp:
4575         (WebCore::isCacheableInMatchedPropertiesCache):
4576
4577             Disable the matched properties cache for styles with non-standard writing-mode.
4578             This is necessary because some CSS properties have different meaning depending on context -
4579             properties handled by CSSProperty::resolveDirectionAwareProperty().
4580
4581             Now that multiple elements may have identical inlineStyle() pointers, this is necessary to
4582             avoid mapping StylePropertySets with direction-aware properties to RenderStyles with differing
4583             writing-modes in the matched properties cache.
4584
4585         * dom/Node.h:
4586         * dom/ElementAttributeData.cpp:
4587         (WebCore::ElementAttributeData::ElementAttributeData):
4588         * dom/ElementAttributeData.h:
4589         (WebCore::ElementAttributeData::ElementAttributeData):
4590         (ElementAttributeData):
4591         * dom/Element.h:
4592         (WebCore::Element::updateInvalidAttributes):
4593         * dom/Element.cpp:
4594         (WebCore::Element::getAttribute):
4595         (WebCore::Element::removeAttribute):
4596         * dom/StyledElement.h:
4597         (WebCore::StyledElement::invalidateStyleAttribute):
4598         * dom/StyledElement.cpp:
4599         (WebCore::StyledElement::updateStyleAttribute):
4600
4601             Move "style attribute dirty" flag to ElementAttributeData.
4602
4603         (WebCore::Element::cloneAttributesFromElement):
4604
4605             Remove ugly optimization to avoid reparsing inline style when cloning elements. This now happens
4606             automagically since cloning nodes just refs the original attribute data.
4607
4608         * dom/StyledElement.cpp:
4609         (WebCore::StyledElement::updateStyleAttribute):
4610         (WebCore::StyledElement::setInlineStyleFromString):
4611         (WebCore::StyledElement::styleAttributeChanged):
4612         (WebCore::StyledElement::inlineStyleChanged):
4613
4614             Avoid reparsing the inline style if the element's attribute data is immutable and already has
4615             a parsed inlineStyle(). Split the set-inline-style-from-string code out of styleAttributeChanged()
4616             to make the code more understandable.
4617
4618 2012-11-16  Simon Fraser  <simon.fraser@apple.com>
4619
4620         Don't update layer positions on scrolling if we're in the middle of layout
4621         https://bugs.webkit.org/show_bug.cgi?id=102556
4622
4623         Reviewed by Dan Bernstein.
4624
4625         RenderLayer::scrollTo() can be called in the middle of layout. When
4626         that happens we should not waste time updating layer positions,
4627         compositing layers, or widget positions, because we'll do those at the
4628         end of layout anyway.
4629         
4630         This prevents us from having inconsistent RenderLayer state, which
4631         hinders future optimizations in this area.
4632
4633         * rendering/RenderLayer.cpp:
4634         (WebCore::RenderLayer::scrollTo):
4635
4636 2012-11-16  Tony Chang  <tony@chromium.org>
4637
4638         Remove ENABLE_CSS_HIERARCHIES since it's no longer in use
4639         https://bugs.webkit.org/show_bug.cgi?id=102554
4640
4641         Reviewed by Andreas Kling.
4642
4643         As mentioned in https://bugs.webkit.org/show_bug.cgi?id=79939#c41 ,
4644         we're going to revist this feature once additional vendor support is
4645         achieved.
4646
4647         No new tests, just removing an unused define.
4648
4649         * Configurations/FeatureDefines.xcconfig:
4650         * GNUmakefile.features.am:
4651
4652 2012-11-16  Mark Pilgrim  <pilgrim@chromium.org>
4653
4654         [Chromium] Remove cookie-related functions from PlatformSupport
4655         https://bugs.webkit.org/show_bug.cgi?id=99340
4656
4657         Reviewed by Adam Barth.
4658
4659         Move cookie-related functions out of PlatformSupport and implement
4660         new PlatformCookieJar interface via NetworkContext.
4661
4662         * WebCore.gyp/WebCore.gyp:
4663         * WebCore.gypi:
4664         * loader/CookieJar.cpp:
4665         * loader/chromium/CookieJarChromium.cpp: Removed.
4666         * platform/chromium/PlatformSupport.h:
4667         (WebCore):
4668         (PlatformSupport):
4669         * platform/network/NetworkingContext.h:
4670         (WebKit):
4671         (NetworkingContext):
4672         * platform/network/chromium/CookieJarChromium.cpp: Copied from Source/WebCore/loader/chromium/CookieJarChromium.cpp.
4673         (WebCore::setCookiesFromDOM):
4674         (WebCore::cookiesForDOM):
4675         (WebCore::cookieRequestHeaderFieldValue):
4676         (WebCore::cookiesEnabled):
4677         (WebCore::getRawCookies):
4678         (WebCore::deleteCookie):
4679         (WebCore::getHostnamesWithCookies):
4680         (WebCore::deleteCookiesForHostname):
4681         (WebCore::deleteAllCookies):
4682
4683 2012-11-16  Pablo Flouret  <pablof@motorola.com>
4684
4685         [JSC] Don't sanitize window.onerror information on crossorigin-enabled scripts
4686         https://bugs.webkit.org/show_bug.cgi?id=70574
4687
4688         Reviewed by Geoffrey Garen.
4689
4690         For scripts that use CORS (via the crossorigin attribute in this case),
4691         don't sanitize the information passed to the window's onerror handler (i.e.
4692         message, url, and line number). Useful for scripts hosted on CDNs.
4693
4694         Tests: http/tests/security/script-crossorigin-onerror-information.html
4695                http/tests/security/script-no-crossorigin-onerror-should-be-sanitized.html
4696
4697         * WebCore.exp.in:
4698         * WebCore.order:
4699
4700         * bindings/js/JSDOMBinding.cpp:
4701         (WebCore::reportException):
4702         * bindings/js/JSDOMBinding.h:
4703         (WebCore):
4704         * bindings/js/ScriptController.cpp:
4705         (WebCore::ScriptController::evaluateInWorld):
4706         * bindings/js/ScriptSourceCode.h:
4707         (WebCore::ScriptSourceCode::ScriptSourceCode):
4708         (WebCore::ScriptSourceCode::cachedScript):
4709         (ScriptSourceCode):
4710         * bindings/js/WorkerScriptController.cpp:
4711         (WebCore::WorkerScriptController::evaluate):
4712             Keep a reference to the cached script in the ScriptSourceCode, so
4713             that it can be passed around and be available when reporting the
4714             exception.
4715
4716         * dom/ScriptExecutionContext.cpp:
4717         (WebCore::ScriptExecutionContext::sanitizeScriptError):
4718         (WebCore::ScriptExecutionContext::reportException):
4719         (WebCore::ScriptExecutionContext::dispatchErrorEvent):
4720         * dom/ScriptExecutionContext.h:
4721         (WebCore):
4722         (ScriptExecutionContext):
4723             Check if the script passes the access control checks, and if so,
4724             don't sanitize the error information.
4725
4726         * html/parser/HTMLPreloadScanner.cpp:
4727         (WebCore::PreloadTask::processAttributes):
4728         (WebCore::PreloadTask::preload):
4729         (PreloadTask):
4730         (WebCore::PreloadTask::crossOriginModeAllowsCookies):
4731             When preloading script elements, check for the crossorigin attribute
4732             and adjust the request's allowCookies value accordingly. Otherwise
4733             when the script is loaded from the cache later on, the cross origin mode
4734             (anonymous/use-credentials) will be effectively ignored.
4735
4736 2012-11-16  Jon Lee  <jonlee@apple.com>
4737
4738         Change visual look of placeholder
4739         https://bugs.webkit.org/show_bug.cgi?id=102149
4740         <rdar://problem/12695566>
4741
4742         Reviewed by Darin Adler.
4743
4744         Move the button to the lower-right corner. Move the theming into
4745         RenderSnapshottedPlugin for now. Eventually we will want to migrate to using the
4746         shadow DOM instead, and the metrics of the button are needed for click passthrough.
4747
4748         * Resources/startButton.png: Added.
4749         * Resources/startButton@2x.png: Added.
4750         * Resources/startButtonPressed.png: Added.
4751         * Resources/startButtonPressed@2x.png: Added.
4752         * WebCore.xcodeproj/project.pbxproj: Add button images.
4753
4754         Maintain variables to track whether the mouse is over the button, and the rect
4755         for the button. If the user clicks in the rect, we render a pressed button.
4756         * rendering/RenderSnapshottedPlugIn.cpp:
4757         (WebCore): Add named constant for bottom and right padding of the button.
4758         (WebCore::RenderSnapshottedPlugIn::RenderSnapshottedPlugIn):
4759         (WebCore::RenderSnapshottedPlugIn::paintReplaced):
4760         (WebCore::startButtonImage): Returns button image.
4761         (WebCore::startButtonPressedImage): Returns pressed button image.
4762         (WebCore::RenderSnapshottedPlugIn::paintButton): Draw the button image in the
4763         lower right hand corner, but only if we are active or hovered.
4764         (WebCore::RenderSnapshottedPlugIn::repaintButton): Stubbed to call repaint().
4765         (WebCore::RenderSnapshottedPlugIn::handleEvent): Repaint the button if we are
4766         hovering over the plugin rect. With a mouse down event, calculate whether the
4767         mouse position is within the button rect.
4768         (WebCore::RenderSnapshottedPlugIn::layout): Cache the rect representing the button
4769         contents.
4770         * rendering/RenderSnapshottedPlugIn.h:
4771
4772         Remove theming function for now.
4773         * rendering/RenderTheme.h:
4774         (RenderTheme):
4775         * rendering/RenderThemeMacShared.h:
4776         * rendering/RenderThemeMacShared.mm:
4777
4778 2012-11-16  Eric Seidel  <eric@webkit.org>
4779
4780         Deploy ScriptWrappable to more always-wrapped objects
4781         https://bugs.webkit.org/show_bug.cgi?id=102539
4782
4783         Reviewed by Adam Barth.
4784
4785         Add the ScriptWrappable baseclass to:
4786         CSSStyleDeclaration (anttik tells me these should only be used from JS, even though some old Editing code used to use them)
4787         ClientRect (element.getBoundingClientRects)
4788         Event (Not all events end up wrapped, but any which live past dispatch do)
4789         NodeList (this covers Static and Dynamic node list types, like document.all)
4790         HTMLCollection (separate from NodeList, for things like table.rows)
4791         Storage (for window.storage, always wrapped)
4792         XMLHttpRequest (always wrapped, created from JS)
4793
4794         This should be a small memory savings as the inline pointer is only 4-8 bytes
4795         instead of the hashmap entry which would be 8-16.  This may also show up
4796         on benchmarks which repeatedly access these objects (like window.storage).
4797
4798         These were found by adding a couple lines of logging-code to
4799         WebCore::createWrapper when we were in the main world, but took the
4800         HashMap (instead of inline) storage path. I used sort and uniq -c
4801         to find the most-frequently wrapped objects (while surfing
4802         a few common sites) and came up with this list.  There are still a few
4803         more complicated objects (like CSSStyleDeclaration) which may benifit
4804         from inline-wrapper-access and will be covered in a later patch.
4805
4806         * css/CSSStyleDeclaration.h:
4807         * dom/ClientRect.h:
4808         * dom/Event.h:
4809         * dom/NodeList.h:
4810         * html/HTMLCollection.h:
4811         * storage/Storage.h:
4812         * xml/XMLHttpRequest.h:
4813
4814 2012-11-16  Jon Lee  <jonlee@apple.com>
4815
4816         Simulated events instances do not all have the same underlying event
4817         https://bugs.webkit.org/show_bug.cgi?id=102468
4818         <rdar://problem/12716331>
4819
4820         Reviewed by Alexey Proskuryakov.
4821
4822         The PassRefPtr with the underlying event is included as an argument for the mouse
4823         down, up, and click events. But the PassRefPtr loses its underlying pointer after
4824         the first simulated mouse down event because it gets assigned to that event's
4825         private m_underlyingEvent variable. We therefore send NULL to the other events.
4826
4827         The fix is for this and related functions to pass the raw pointer.
4828
4829         A layout test is not possible to put together because the call sites that use simulated
4830         events with an underlying event do not send mouse events, and those that send mouse
4831         events have a NULL underlying event.
4832
4833         * dom/EventDispatcher.cpp:
4834         (WebCore::EventDispatcher::dispatchSimulatedClick): Require passing in the raw pointer.
4835         * dom/EventDispatcher.h:
4836         * dom/Node.cpp:
4837         (WebCore::Node::dispatchSimulatedClick): Ditto.
4838         * dom/Node.h:
4839
4840 2012-11-16  Patrick Gansterer  <paroga@webkit.org>
4841
4842         Build fix for WinCE after r134936.
4843
4844         * platform/network/win/CookieJarWin.cpp:
4845         (WebCore::cookieRequestHeaderFieldValue):
4846
4847 2012-11-16  Dimitri Glazkov  <dglazkov@chromium.org>
4848
4849         Unreviewed, rolling out r134986.
4850         http://trac.webkit.org/changeset/134986
4851         https://bugs.webkit.org/show_bug.cgi?id=102110
4852
4853         Triggered ASSERT in fast/frames/seamless/seamless-inherited-
4854         origin.html.
4855
4856         * css/StyleResolver.cpp:
4857         (WebCore::StyleResolver::StyleResolver):
4858         (WebCore::StyleResolver::addAuthorRulesAndCollectUserRulesFromSheets):
4859         (WebCore::collectCSSOMWrappers):
4860         * css/StyleResolver.h:
4861         (StyleResolver):
4862         * dom/Document.cpp:
4863         (WebCore::Document::setCompatibilityMode):
4864         * dom/DocumentStyleSheetCollection.cpp:
4865         (WebCore::DocumentStyleSheetCollection::DocumentStyleSheetCollection):
4866         (WebCore::DocumentStyleSheetCollection::~DocumentStyleSheetCollection):
4867         (WebCore::DocumentStyleSheetCollection::pageGroupUserSheets):
4868         (WebCore):
4869         (WebCore::DocumentStyleSheetCollection::clearPageGroupUserSheets):
4870         (WebCore::DocumentStyleSheetCollection::updatePageGroupUserSheets):
4871         (WebCore::DocumentStyleSheetCollection::addUserSheet):
4872         (WebCore::DocumentStyleSheetCollection::updateActiveStyleSheets):
4873         (WebCore::DocumentStyleSheetCollection::reportMemoryUsage):
4874         * dom/DocumentStyleSheetCollection.h:
4875         (DocumentStyleSheetCollection):
4876         (WebCore::DocumentStyleSheetCollection::documentUserSheets):
4877         * page/PageGroup.cpp:
4878         (WebCore::PageGroup::addUserStyleSheetToWorld):
4879         (WebCore::PageGroup::removeUserStyleSheetFromWorld):
4880         (WebCore::PageGroup::removeUserStyleSheetsFromWorld):
4881         (WebCore::PageGroup::removeAllUserContent):
4882         (WebCore::PageGroup::resetUserStyleCacheInAllFrames):
4883         * page/PageGroup.h:
4884         (PageGroup):
4885
4886 2012-11-16  Michael Pruett  <michael@68k.org>
4887
4888         IndexedDB: Propagate DOMRequestState to IndexedDB binding utility functions
4889         https://bugs.webkit.org/show_bug.cgi?id=102430
4890
4891         Reviewed by Adam Barth.
4892
4893         DOMRequestState is currently propagated to some but not all of
4894         the IndexedDB binding utility functions. In order to implement
4895         these functions for JSC, this state must be propagated to all
4896         of the utility functions.
4897
4898         Tests: storage/indexeddb/*
4899
4900         * Modules/indexeddb/IDBCursor.cpp:
4901         (WebCore::IDBCursor::update):
4902         (WebCore::IDBCursor::setValueReady):
4903         * Modules/indexeddb/IDBObjectStore.cpp:
4904         (WebCore::generateIndexKeysForValue):
4905         (WebCore::IDBObjectStore::put):
4906         (WebCore):
4907         * Modules/indexeddb/IDBRequest.cpp:
4908         (WebCore::IDBRequest::onSuccess):
4909         (WebCore::IDBRequest::dispatchEvent):
4910         * Modules/indexeddb/IDBRequest.h:
4911         (WebCore::IDBRequest::requestState):
4912         (IDBRequest):
4913         * bindings/v8/IDBBindingUtilities.cpp:
4914         (WebCore::createIDBKeyFromScriptValueAndKeyPath):
4915         (WebCore::serializeIDBValue):
4916         (WebCore::injectIDBKeyIntoScriptValue):
4917         * bindings/v8/IDBBindingUtilities.h:
4918         (WebCore):
4919
4920 2012-11-16  Byungwoo Lee  <bw80.lee@samsung.com>
4921
4922         Rebaselined run-bindings-tests.
4923         https://bugs.webkit.org/show_bug.cgi?id=102523
4924
4925         Reviewed by Dimitri Glazkov.
4926
4927         Expected results need to be updated after r134931
4928
4929         * bindings/scripts/test/JS/JSTestObj.cpp:
4930         (WebCore::jsTestObjWithScriptArgumentsAndCallStackAttribute):
4931         (WebCore::setJSTestObjWithScriptArgumentsAndCallStackAttribute):
4932         (WebCore::jsTestObjPrototypeFunctionWithScriptArgumentsAndCallStack):
4933         * bindings/scripts/test/V8/V8TestObj.cpp:
4934         (WebCore::TestObjV8Internal::withScriptArgumentsAndCallStackAttributeAttrGetter):
4935         (WebCore::TestObjV8Internal::withScriptArgumentsAndCallStackAttributeAttrSetter):
4936         (WebCore::TestObjV8Internal::withScriptArgumentsAndCallStackCallback):
4937
4938 2012-11-16  Pratik Solanki  <psolanki@apple.com>
4939
4940         For single element arrays use the pointer into the CFDataRef instead of copying data
4941         https://bugs.webkit.org/show_bug.cgi?id=102306
4942         <rdar://problem/12267471>
4943
4944         Reviewed by Alexey Proskuryakov.
4945
4946         We generally copy the data received from CFNetwork into our own buffers. But if the
4947         CFArrayRef has exactly one CFDataRef inside it, then we can just hold on to the CFDataRef
4948         and access its memory directly and avoid making a copy.
4949
4950         This also moves the creation of PurgeableBuffer from CachedResource to SharedBuffer.
4951         SharedBuffer::createPurgeableBuffer() will avoid creating PurgeableBuffer when the
4952         SharedBuffer is backed by a NSData/CFDataRef and when we want to optimize and directly use
4953         the memory in the data array.
4954
4955         No new tests because no change in functionality.
4956
4957         * loader/ResourceBuffer.cpp:
4958         (WebCore::ResourceBuffer::createPurgeableBuffer): Added.
4959         * loader/ResourceBuffer.h:
4960         * loader/cache/CachedResource.cpp:
4961         (WebCore::CachedResource::makePurgeable):
4962         * platform/SharedBuffer.cpp:
4963         (WebCore::SharedBuffer::createPurgeableBuffer): Added.
4964         (WebCore::SharedBuffer::data):
4965         * platform/SharedBuffer.h:
4966         * platform/cf/SharedBufferCF.cpp:
4967         (WebCore::SharedBuffer::platformData): Use reinterpret_cast instead of C-style cast.
4968         (WebCore::SharedBuffer::maybeTransferPlatformData): Use reinterpret_cast instead of C-style cast.
4969         (WebCore::SharedBuffer::singleDataArrayBuffer): Added.
4970
4971 2012-11-16  Antti Koivisto  <antti@apple.com>
4972
4973         REGRESSION(r129644): User StyleSheet not applying
4974         https://bugs.webkit.org/show_bug.cgi?id=102110
4975
4976         Reviewed by Andreas Kling.
4977
4978         Injected stylesheets added as UserStyleAuthorLevel fail to apply. r129644 implicitly assumed that
4979         such things don't exists but on Chromium addUserStyleSheet() confusingly uses them.
4980         
4981         The patch adds injected author stylesheets to DocumentStyleSheetCollection::activeStyleSheets().
4982         It also generally cleans up the code around injected and user stylesheets.
4983
4984         Tests: userscripts/user-script-and-stylesheet.html
4985                userscripts/user-stylesheet-invalidate.html
4986
4987         * css/StyleResolver.cpp:
4988         (WebCore::StyleResolver::StyleResolver):
4989         (WebCore::StyleResolver::collectRulesFromUserStyleSheets):
4990         (WebCore::collectCSSOMWrappers):
4991         * css/StyleResolver.h:
4992         (StyleResolver):
4993         * dom/Document.cpp:
4994         (WebCore::Document::setCompatibilityMode):
4995         * dom/DocumentStyleSheetCollection.cpp:
4996         (WebCore::DocumentStyleSheetCollection::DocumentStyleSheetCollection):
4997         (WebCore::DocumentStyleSheetCollection::~DocumentStyleSheetCollection):
4998         (WebCore::DocumentStyleSheetCollection::injectedUserStyleSheets):
4999         (WebCore):
5000         (WebCore::DocumentStyleSheetCollection::injectedAuthorStyleSheets):
5001         (WebCore::DocumentStyleSheetCollection::updateInjectedStyleSheetCache):
5002         (WebCore::DocumentStyleSheetCollection::invalidateInjectedStyleSheetCache):
5003         (WebCore::DocumentStyleSheetCollection::addUserSheet):
5004         (WebCore::DocumentStyleSheetCollection::updateActiveStyleSheets):
5005         (WebCore::DocumentStyleSheetCollection::reportMemoryUsage):
5006         * dom/DocumentStyleSheetCollection.h:
5007         (WebCore::DocumentStyleSheetCollection::documentUserStyleSheets):
5008         (DocumentStyleSheetCollection):
5009         * page/PageGroup.cpp:
5010         (WebCore::PageGroup::addUserStyleSheetToWorld):
5011         (WebCore::PageGroup::removeUserStyleSheetFromWorld):
5012         (WebCore::PageGroup::removeUserStyleSheetsFromWorld):
5013         (WebCore::PageGroup::removeAllUserContent):
5014         (WebCore::PageGroup::invalidatedInjectedStyleSheetCacheInAllFrames):
5015         * page/PageGroup.h:
5016         (PageGroup):
5017
5018 2012-11-16  Andreas Kling  <akling@apple.com>
5019
5020         StyleResolver: Only input elements need equal "readonly" attribute for style sharing.
5021         <http://webkit.org/b/102536>
5022
5023         Reviewed by Antti Koivisto.
5024
5025         Move the comparison of the "readonly" attribute into canShareStyleWithControl() since it's only
5026         relevant for sharing style between <input> elements.
5027
5028         Also skip attribute comparisons for form control elements that share the same ElementAttributeData.
5029
5030         * css/StyleResolver.cpp:
5031         (WebCore::StyleResolver::canShareStyleWithControl):
5032         (WebCore::haveIdenticalStyleAffectingAttributes):
5033
5034 2012-11-16  Sheriff Bot  <webkit.review.bot@gmail.com>
5035
5036         Unreviewed, rolling out r134867.
5037         http://trac.webkit.org/changeset/134867
5038         https://bugs.webkit.org/show_bug.cgi?id=102544
5039
5040         Broke security fuzzier test (heap-buffer-overflow) (Requested
5041         by bfulgham on #webkit).
5042
5043         * platform/audio/Biquad.cpp:
5044         (WebCore::Biquad::process):
5045
5046 2012-11-16  Tommy Widenflycht  <tommyw@google.com>
5047
5048         MediaStream API: Update RTCPeerConnection states to match the latest editors draft
5049         https://bugs.webkit.org/show_bug.cgi?id=102382
5050
5051         Reviewed by Adam Barth.
5052
5053         Updating readyState & iceState, and adding iceGatheringState.
5054         Also safeguarding the event timer callback.
5055
5056         Patch covered by existing tests.
5057
5058         * Modules/mediastream/RTCPeerConnection.cpp:
5059         (WebCore::RTCPeerConnection::RTCPeerConnection):
5060         (WebCore::RTCPeerConnection::createOffer):
5061         (WebCore::RTCPeerConnection::createAnswer):
5062         (WebCore::RTCPeerConnection::setLocalDescription):
5063         (WebCore::RTCPeerConnection::localDescription):
5064         (WebCore::RTCPeerConnection::setRemoteDescription):
5065         (WebCore::RTCPeerConnection::remoteDescription):
5066         (WebCore::RTCPeerConnection::updateIce):
5067         (WebCore::RTCPeerConnection::addIceCandidate):
5068         (WebCore::RTCPeerConnection::readyState):
5069         (WebCore::RTCPeerConnection::iceGatheringState):
5070         (WebCore):
5071         (WebCore::RTCPeerConnection::iceState):
5072         (WebCore::RTCPeerConnection::addStream):
5073         (WebCore::RTCPeerConnection::close):
5074         (WebCore::RTCPeerConnection::didChangeIceGatheringState):
5075         (WebCore::RTCPeerConnection::stop):
5076         (WebCore::RTCPeerConnection::changeReadyState):
5077         (WebCore::RTCPeerConnection::scheduledEventTimerFired):
5078         * Modules/mediastream/RTCPeerConnection.h:
5079         (RTCPeerConnection):
5080         * Modules/mediastream/RTCPeerConnection.idl:
5081         * dom/EventNames.h:
5082         (WebCore):
5083         * platform/mediastream/RTCPeerConnectionHandlerClient.h:
5084         (RTCPeerConnectionHandlerClient):
5085         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp:
5086         (WebCore::RTCPeerConnectionHandlerChromium::didChangeICEGatheringState):
5087         (WebCore):
5088         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h:
5089         (RTCPeerConnectionHandlerChromium):
5090
5091 2012-11-16  Dimitri Glazkov  <dglazkov@chromium.org>
5092
5093         Unreviewed, rolling out r134973.
5094         http://trac.webkit.org/changeset/134973
5095         https://bugs.webkit.org/show_bug.cgi?id=99340
5096
5097         Broke compile on at least Mac and Linux.
5098
5099         * WebCore.gyp/WebCore.gyp:
5100         * WebCore.gypi:
5101         * loader/CookieJar.cpp:
5102         * loader/chromium/CookieJarChromium.cpp: Renamed from Source/WebKit/chromium/src/FrameNetworkingContextImpl.cpp.
5103         (WebCore):
5104         (WebCore::setCookies):
5105         (WebCore::cookies):
5106         (WebCore::cookieRequestHeaderFieldValue):
5107         (WebCore::cookiesEnabled):
5108         (WebCore::getRawCookies):
5109         (WebCore::deleteCookie):
5110         (WebCore::getHostnamesWithCookies):
5111         (WebCore::deleteCookiesForHostname):
5112         (WebCore::deleteAllCookies):
5113         * platform/chromium/PlatformSupport.h:
5114         (WebCore):
5115         (PlatformSupport):
5116         * platform/network/NetworkingContext.h:
5117         * platform/network/chromium/CookieJarChromium.cpp: Removed.
5118
5119 2012-11-16  Martin Robinson  <mrobinson@igalia.com>
5120
5121         [GTK] [WebKit2] Move GtkAuthenticationDialog to the UIProcess
5122         https://bugs.webkit.org/show_bug.cgi?id=101843
5123
5124         Reviewed by Gustavo Noronha Silva.
5125
5126         Make GtkAuthenticationDialog more general, so that it can be subclassed in 
5127         WebKit2. We cannot use the WebCore authentication-related classes directly there.
5128
5129         No new tests. This patch does not change behavior.
5130
5131         * platform/gtk/GtkAuthenticationDialog.cpp:
5132         (WebCore::GtkAuthenticationDialog::GtkAuthenticationDialog): Remove an unused include and reorder
5133         some field initializers.
5134         (WebCore::GtkAuthenticationDialog::authenticate): Now handle both the okay and cancel case here. This
5135         makes it simpler to subclass.
5136         (WebCore::GtkAuthenticationDialog::authenticationDialogResponseCallback): Handle fetching the username
5137         and password here, so that it can be shared with subclasses.
5138         * platform/gtk/GtkAuthenticationDialog.h: Make some methods virtual and protected so they can be
5139         subclasses.
5140
5141 2012-11-16  Mark Pilgrim  <pilgrim@chromium.org>
5142
5143         [Chromium] Remove cookie-related functions from PlatformSupport
5144         https://bugs.webkit.org/show_bug.cgi?id=99340
5145
5146         Reviewed by Adam Barth.
5147
5148         Move cookie-related functions out of PlatformSupport and implement
5149         new PlatformCookieJar interface via NetworkContext.
5150
5151         * WebCore.gyp/WebCore.gyp:
5152         * WebCore.gypi:
5153         * loader/CookieJar.cpp:
5154         * loader/chromium/CookieJarChromium.cpp: Removed.
5155         * platform/chromium/PlatformSupport.h:
5156         (WebCore):
5157         (PlatformSupport):
5158         * platform/network/NetworkingContext.h:
5159         (WebKit):
5160         (NetworkingContext):
5161         * platform/network/chromium/CookieJarChromium.cpp: Copied from Source/WebCore/loader/chromium/CookieJarChromium.cpp.
5162         (WebCore::setCookiesFromDOM):
5163         (WebCore::cookiesForDOM):
5164         (WebCore::cookieRequestHeaderFieldValue):
5165         (WebCore::cookiesEnabled):
5166         (WebCore::getRawCookies):
5167         (WebCore::deleteCookie):
5168         (WebCore::getHostnamesWithCookies):
5169         (WebCore::deleteCookiesForHostname):
5170         (WebCore::deleteAllCookies):
5171
5172 2012-11-16  Byungwoo Lee  <bw80.lee@samsung.com>
5173
5174         Fix assertion bug of build fix r134961
5175         https://bugs.webkit.org/show_bug.cgi?id=102533
5176
5177         Reviewed by Martin Robinson.
5178
5179         Assertion condition should be '!d->m_currentWebChallenge.isNull()'
5180
5181         * platform/network/soup/ResourceHandleSoup.cpp:
5182         (WebCore::ResourceHandle::continueDidReceiveAuthenticationChallenge):
5183
5184 2012-11-16  Tommy Widenflycht  <tommyw@google.com>
5185
5186         [chromium] MediaStream API: Add missing WebRTCPeerConnectionHandlerClient::didAddRemoteDataChannel
5187         https://bugs.webkit.org/show_bug.cgi?id=102386
5188
5189         Reviewed by Adam Barth.
5190
5191         Existing tests expanded to cover patch.
5192
5193         * platform/mediastream/RTCDataChannelDescriptor.cpp:
5194         (WebCore::RTCDataChannelDescriptor::RTCDataChannelDescriptor):
5195         (WebCore::RTCDataChannelDescriptor::readyStateChanged):
5196         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp:
5197         (WebCore::RTCPeerConnectionHandlerChromium::didAddRemoteDataChannel):
5198         (WebCore):
5199         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h:
5200         (WebKit):
5201         (RTCPeerConnectionHandlerChromium):
5202
5203 2012-11-16  Scott Violet  <sky@chromium.org>
5204
5205         [chromium] Copy linux theme related files to default
5206         https://bugs.webkit.org/show_bug.cgi?id=102403
5207
5208         Reviewed by Tony Chang
5209
5210         Transitional patch that copies linux WebThemeEngine to default directory.
5211
5212         No new tests, refactoring only.
5213
5214         * WebCore.gyp/WebCore.gyp: Update compile rules when use_default_render_theme is set.
5215         * WebCore.gypi: Adds new files.
5216         * platform/chromium/PlatformSupport.h:
5217         * platform/chromium/PlatformThemeChromiumDefault.cpp: Copied from Source/WebCore/platform/chromium/PlatformThemeChromiumLinux.cpp.
5218         * platform/chromium/PlatformThemeChromiumDefault.h: Copied from Source/WebCore/platform/chromium/PlatformThemeChromiumLinux.h.
5219         * platform/chromium/ScrollbarThemeChromiumDefault.cpp: Copied from Source/WebCore/platform/chromium/ScrollbarThemeChromiumLinux.cpp.
5220         * platform/chromium/ScrollbarThemeChromiumDefault.h: Copied from Source/WebCore/platform/chromium/ScrollbarThemeChromiumLinux.h.
5221         * rendering/RenderThemeChromiumDefault.cpp: Copied from Source/WebCore/rendering/RenderThemeChromiumLinux.cpp.
5222         * rendering/RenderThemeChromiumDefault.h: Copied from Source/WebCore/rendering/RenderThemeChromiumLinux.h.
5223
5224 2012-11-16  Alec Flett  <alecflett@chromium.org>
5225
5226         IndexedDB: add missing 'explicit' and fix backing store release
5227         https://bugs.webkit.org/show_bug.cgi?id=102450
5228
5229         Reviewed by Tony Chang.
5230
5231         A inconsequential regression was introduced in http://trac.webkit.org/changeset/134129
5232         which resulted in objects sticking around a bit longer than
5233         expected. This makes sure the LevelDBTransaction is released
5234         at the moment of commit/rollback rather than when IDBTransactionBackendImpl
5235         is destroyed.
5236
5237         No new tests, this is just internal state that will affect
5238         some future refactoring.
5239
5240         * Modules/indexeddb/IDBBackingStore.h:
5241         (Cursor):
5242         (Transaction):
5243         (WebCore::IDBBackingStore::Transaction::reset):
5244         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
5245         (WebCore::IDBTransactionBackendImpl::abort):
5246         (WebCore::IDBTransactionBackendImpl::commit):
5247
5248 2012-11-16  Dimitri Glazkov  <dglazkov@chromium.org>
5249
5250         [Chromium] One last tweak to WebCore.gypi to make Win build not sad.
5251
5252         * WebCore.gypi: Removed one last mention of accessibility/gtk file.
5253
5254 2012-11-16  Robert Flack  <flackr@chromium.org>
5255
5256         Handle gesture events on scrollbars.
5257         https://bugs.webkit.org/show_bug.cgi?id=101516
5258
5259         Reviewed by Antonio Gomes.
5260
5261         Adds a gesture event handler to scrollbars and sends gestures beginning
5262         over a scrollbar to this handler to allow touch scrolling scrollbars.
5263
5264         Test: fast/events/touch/gesture/gesture-scrollbar.html
5265
5266         * page/EventHandler.cpp:
5267         (WebCore::EventHandler::clear):
5268         (WebCore::EventHandler::handleGestureEvent):
5269         (WebCore::EventHandler::isScrollbarHandlingGestures):
5270         (WebCore):
5271         * page/EventHandler.h:
5272         (EventHandler):
5273         * platform/Scrollbar.cpp:
5274         (WebCore::Scrollbar::Scrollbar):
5275         (WebCore):
5276         (WebCore::Scrollbar::gestureEvent):
5277         (WebCore::Scrollbar::mouseMoved):
5278         (WebCore::Scrollbar::mouseUp):
5279         (WebCore::Scrollbar::mouseDown):
5280         * platform/Scrollbar.h:
5281         (WebCore):
5282         (Scrollbar):
5283         * platform/ScrollbarTheme.h:
5284         (WebCore::ScrollbarTheme::hitTest):
5285         * platform/ScrollbarThemeComposite.cpp:
5286         (WebCore::ScrollbarThemeComposite::hitTest):
5287         * platform/ScrollbarThemeComposite.h:
5288         (ScrollbarThemeComposite):
5289         * platform/qt/ScrollbarThemeQStyle.cpp:
5290         (WebCore::ScrollbarThemeQStyle::hitTest):
5291         * platform/qt/ScrollbarThemeQStyle.h:
5292         (ScrollbarThemeQStyle):
5293
5294 2012-11-16  Xianzhu Wang  <wangxianzhu@chromium.org>
5295
5296         [Chromium-Android] Stack overflow in MediaControlsChromiumAndroid.cpp
5297         https://bugs.webkit.org/show_bug.cgi?id=102444
5298
5299         Reviewed by Adam Barth.
5300
5301         No new tests. Have been covered by many existing layout tests.
5302
5303         * html/shadow/MediaControlsChromiumAndroid.cpp:
5304         (WebCore::MediaControls::create): Calls createControls instead of itself.
5305
5306 2012-11-16  Andreas Kling  <akling@apple.com>
5307
5308         StyleResolver: Optimize sharing candidate evaluation for elements with shared attribute data.
5309         <http://webkit.org/b/102507>
5310
5311         Reviewed by Antti Koivisto.
5312
5313         When evaluating two elements as potential style sharing candidate, we have a whole bunch of code
5314         comparing the various attributes that would prevent sharing.
5315
5316         If the two elements both share the same ElementAttributeData, we can skip all those checks
5317         since they are guaranteed to have equal attributes.
5318
5319         Cuts the time spent in canShareStyleWithElement() by 25% on the HTML5 spec at <http://whatwg.org/c>.
5320
5321         * css/StyleResolver.cpp:
5322         (WebCore::haveIdenticalStyleAffectingAttributes):
5323         (WebCore::StyleResolver::canShareStyleWithElement):
5324
5325 2012-11-16  Byungwoo Lee  <bw80.lee@samsung.com>
5326
5327         [EFL][GTK] Build fix after r134955
5328         https://bugs.webkit.org/show_bug.cgi?id=102527
5329
5330         Reviewed by Martin Robinson.
5331
5332         Fix the EFL,GTK debug bulid fails after r134955.
5333
5334         * platform/network/soup/ResourceHandleSoup.cpp:
5335         (WebCore::ResourceHandle::continueDidReceiveAuthenticationChallenge):
5336
5337 2012-11-15  Alexey Proskuryakov  <ap@apple.com>
5338
5339         Private Browsing is a per-page setting that sets a global value
5340         https://bugs.webkit.org/show_bug.cgi?id=67870
5341
5342         Reviewed by Sam Weinig.
5343
5344         Make ResourceHandle{Mac,CFNet} use context to access storage session.
5345
5346         * WebCore.exp.in: We track less session state in WebCore now, so we need fewer
5347         exports.
5348
5349         * loader/FrameNetworkingContext.h: Added an OVERRIDE.
5350
5351         * page/Settings.cpp: (WebCore::Settings::setPrivateBrowsingEnabled): WebCore
5352         no longer keeps track of a globally enabled private CFNetwork storage session.
5353
5354         * platform/CookiesStrategy.h: Added defaultCookieStorage(). Some cookie jar methods
5355         don't have a NetworkingContext pointer, and have to use whatever a client expects
5356         them to do. Perhaps we should move those methods away from WebCore eventually.
5357
5358         * platform/network/NetworkingContext.h: Added storageSession().
5359
5360         * platform/network/ResourceHandle.h: Removed sttaic methods for dealing with global
5361         sessions.
5362
5363         * platform/network/ResourceHandleInternal.h: Added m_storageSession. We need to
5364         remember it post-creation to do things in willSendRequest. Alternatively, we could
5365         keep a reference to NetworkingContext itself.
5366
5367         * platform/network/cf/CookieJarCFNet.cpp:
5368         (WebCore::setCookiesFromDOM): currentCFHTTPCookieStorage now needs a context,
5369         there is no globally current one any more. Also, we don't really expect cookie
5370         stirage to be 0 when not using NSURLConnection.
5371         (WebCore::cookiesForDOM): Ditto.
5372         (WebCore::cookieRequestHeaderFieldValue): Ditto.
5373         (WebCore::cookiesEnabled): Ditto.
5374         (WebCore::getRawCookies): Ditto.
5375         (WebCore::deleteCookie): Ditto.
5376         (WebCore::getHostnamesWithCookies): Ditto.
5377         (WebCore::deleteCookiesForHostname): Ditto.
5378         (WebCore::deleteAllCookies): Ditto.
5379         * platform/network/cf/CookieStorageCFNet.cpp:
5380         (WebCore::currentCFHTTPCookieStorage): Use a context.
5381         (WebCore::defaultCFHTTPCookieStorage): Except for Windows-only override session,
5382         this is implemented in a strategy.
5383         (WebCore::overridenCookieStorage): Exposed the override for WebKit use on Windows.
5384
5385         * platform/network/cf/CookieStorageCFNet.h: Ditto.
5386
5387         * platform/network/cf/ResourceHandleCFNet.cpp:
5388         (WebCore::willSendRequest): Use storage session from the context, not global one.
5389         (WebCore::makeFinalRequest): Merged this into the only remaining caller. This
5390         function didn't really make any sense on its own.
5391         (WebCore::shouldRelaxThirdPartyCookiePolicy): Factored out of createCFURLConnection
5392         to match Mac.
5393         (WebCore::ResourceHandle::createCFURLConnection): While merging makeFinalRequest()
5394         in, removed some seemingly nonsensical code that was getting and immediately re-applying
5395         cookie storage accept policy.
5396         (WebCore::ResourceHandle::start): Store context->storageSession() for use in willSendRequest.
5397         (WebCore::ResourceHandle::willSendRequest): Apply the stored session, not global one.
5398         (WebCore::ResourceHandle::storageSession): An accessor for static methods that cannot
5399         access "d".
5400         (WebCore::ResourceHandle::loadResourceSynchronously): Store context->storageSession() for use in willSendRequest.
5401         (WebCore::ResourceHandle::willLoadFromCache): Don't call makeFinalRequest here.
5402         It didn't match Mac, and nothing in makeFinalRequest should have affected the result.
5403
5404         * platform/network/cf/ResourceRequestCFNet.cpp: (WebCore::ResourceRequest::doUpdatePlatformRequest):
5405         This function used to apply current storage session to every request for no apparent
5406         reason.
5407
5408         * platform/network/mac/CookieJarMac.mm:
5409         (WebCore::cookiesForDOM): Changed to pass context to currentCFHTTPCookieStorage.
5410         (WebCore::cookieRequestHeaderFieldValue): Ditto.
5411         (WebCore::setCookiesFromDOM): Ditto.
5412         (WebCore::cookiesEnabled): Ditto.
5413         (WebCore::getRawCookies): Ditto.
5414         (WebCore::deleteCookie): Ditto.
5415         (WebCore::getHostnamesWithCookies): Ditto.
5416         (WebCore::deleteCookiesForHostname): Ditto.
5417         (WebCore::deleteAllCookies): Ditto.
5418         * platform/network/mac/ResourceHandleMac.mm:
5419         (WebCore::shouldRelaxThirdPartyCookiePolicy): There was no need to special case
5420         null currentCFHTTPCookieStorage, WKSI handles that internally. Added a context
5421         argument, so that the function can access current session.
5422         (WebCore::ResourceHandle::createNSURLConnection): Updated for other code changes.
5423         (WebCore::ResourceHandle::start): Store context->storageSession() for use in willSendRequest.
5424         (WebCore::ResourceHandle::willLoadFromCache): Style fix.
5425         (WebCore::ResourceHandle::loadResourceSynchronously): Store context->storageSession()
5426         for use in willSendRequest. 
5427         (WebCore::ResourceHandle::willSendRequest): Use stored session, not global one.
5428
5429 2012-11-16  Dimitri Glazkov  <dglazkov@chromium.org>
5430
5431         [Chromium] Land a proper fix for r134939.
5432
5433         * WebCore.gyp/WebCore.gyp: Added exclusion for "atk".
5434         * WebCore.gypi: Put the accessibility/atk directory back into WebCore.gypi.
5435
5436 2012-11-16  Dimitri Glazkov  <dglazkov@chromium.org>
5437
5438         [Chromium] Just yank the whole accessibility/atk dir out of WebCore.gypi.
5439
5440 2012-11-16  Dimitri Glazkov  <dglazkov@chromium.org>
5441
5442         [Chromium] Updated WebCore.gypi after r134939.
5443
5444         * WebCore.gypi: Renamed acessibility/gtk to accessibility/atk.
5445
5446 2012-11-16  Martin Robinson  <mrobinson@igalia.com>
5447
5448         [GTK] Move CredentialBackingStore usage from GtkAuthenticationDialog to ResourceHandleSoup
5449         https://bugs.webkit.org/show_bug.cgi?id=101840
5450
5451         Reviewed by Gustavo Noronha Silva.
5452
5453         Make ResourceHandleSoup aware of per-session CredentialStorage and persistent CredentialStorage.
5454         Persistent credential storage interaction is moved from GtkAuthenticationDialog, so that it can
5455         be used whether or not GtkAuthenticationDialog is used or not. We try to properly handle redirects
5456         in the manner that the CFNet backend does.
5457
5458         No new tests. There are tests for this behavior, but they cannot be activated until we finish
5459         plumbing this through to the API layer. Once that patch lands, the tests will be turned on.
5460
5461         * platform/gtk/GtkAuthenticationDialog.cpp: No longer store credentials into the persistent
5462         storage manually, instead rely on ResourceHandleSoup. Also, we no longer get proposed credentials
5463         from the persistent storage here as well. They are pre-loaded by the ResourceHanndle.
5464         * platform/gtk/GtkAuthenticationDialog.h: Remove callbacks and members associated with saving
5465         credentials to the persistent credential store.
5466         * platform/network/ResourceHandle.h:
5467         (ResourceHandle): Add a method which is used to continue asynchronously after looking for
5468         proposed credentials in the persistent credential store.
5469         * platform/network/ResourceHandleInternal.h: Add a member which tracks persistent credentials to be added once we know
5470         an authentication succeeded.
5471         * platform/network/gtk/CredentialBackingStore.cpp:
5472         (CredentialForChallengeAsyncReadyCallbackData): Added this data structure used for asynchronous access
5473         of stored credentials.
5474         (WebCore::credentialForChallengeAsyncReadyCallback): Ditto for this callback.
5475         (WebCore::CredentialBackingStore::credentialForChallenge): Make this method asynchronous.
5476         * platform/network/gtk/CredentialBackingStore.h:
5477         (CredentialBackingStore): Update method signatures for for making credentialForChallenge asynchronous.
5478         * platform/network/soup/AuthenticationChallenge.h:
5479         (WebCore::AuthenticationChallenge::setProposedCredential): Added a setter so that ResourceHandleSoup
5480         can set proposed credentials from the persistent credential store.
5481         * platform/network/soup/ResourceHandleSoup.cpp:
5482         (WebCore::gotHeadersCallback): For GTK+ save any pending credential in the persistent credential storage
5483         if the authentication succeeded.
5484         (WebCore::applyAuthenticationToRequest): Added this method which generically embeds stored credentials
5485         in the request URI. This is the method that Soup uses to override any soup-stored session credential.
5486         (WebCore::restartedCallback): Strip credentials for requests that span a security origin. Handle
5487         authenticating requests from the session store.
5488         (WebCore::createSoupRequestAndMessageForHandle): Make the local request reference mutable.
5489         (WebCore::ResourceHandle::start): Remove some code which is now part of applyAuthenticationToRequest.
5490         Call applyAuthenticationToRequest and clear the user and password members like the CFNet backend does.
5491         (WebCore::getCredentialFromPersistentStoreCallback): Added this callback for getting persistently stored credentials.
5492         (WebCore::ResourceHandle::continueDidReceiveAuthenticationChallenge): Split out didReceiveAuthenticationChallenge
5493         into this asynchronous bit.
5494         (WebCore::ResourceHandle::didReceiveAuthenticationChallenge): For GTK+ continue handling this situation after
5495         first looking in the persistent credential store.
5496         (WebCore::ResourceHandle::receivedCredential): Store session credentials in the session storage, which is
5497         at the moment a redundant version of the Soup session storage and also prepare any persistent credentials
5498         for storage later (see gotHeadersCallback).
5499
5500 2012-11-16  Erik Arvidsson  <arv@chromium.org>
5501
5502         Update DOMException name: TypeMismatchError
5503         https://bugs.webkit.org/show_bug.cgi?id=102418
5504
5505         Reviewed by Kentaro Hara.
5506
5507         Patch 17 of 25 to update DOMException name to match the spec and Firefox.
5508
5509         Updated existing tests.
5510
5511         * dom/DOMCoreException.cpp:
5512         (WebCore):
5513         * dom/ExceptionCode.h:
5514
5515 2012-11-16  Balazs Kelemen  <kbalazs@webkit.org>
5516
5517         Coordinated Graphics: support the "freeze animations" API
5518         https://bugs.webkit.org/show_bug.cgi?id=100703
5519
5520         Reviewed by Noam Rosenthal.
5521
5522         Typo fix after previous patch.
5523
5524         No new tests, it's just a typo that only takes effect in the browser.
5525
5526         * platform/graphics/GraphicsLayerAnimation.cpp:
5527         (WebCore::GraphicsLayerAnimation::GraphicsLayerAnimation):
5528         Initialize members.
5529
5530 2012-11-16  Dan Carney  <dcarney@google.com>
5531
5532         add 7 bit strings capabilities to the v8 binding layer
5533         https://bugs.webkit.org/show_bug.cgi?id=91850
5534
5535         Reviewed by Adam Barth.
5536
5537         This change enables the v8 binding layer to make use of webkit's
5538         8 bit string capabilities. Using 8 bit strings leads to certain
5539         benchmark performance improvemnts as can be seen in
5540         https://bug-91850-attachments.webkit.org/attachment.cgi?id=163334.
5541
5542         No new tests.  Test coverage already extensive.
5543
5544         * bindings/v8/V8PerIsolateData.cpp:
5545         (WebCore::V8PerIsolateData::visitExternalStrings):
5546         * bindings/v8/V8StringResource.cpp:
5547         (StringTraits):
5548         (WebCore::false):
5549         (WebCore):
5550         (WebCore::true):
5551         (WebCore::v8StringToWebCoreString):
5552         * bindings/v8/V8ValueCache.cpp:
5553         (WebCore::makeExternalString):
5554         (WebCore::WebCoreStringResourceBase::toWebCoreStringResourceBase):
5555         (WebCore):
5556         (WebCore::WebCoreStringResourceBase::visitStrings):
5557         * bindings/v8/V8ValueCache.h:
5558         (WebCoreStringResourceBase):
5559         (WebCore::WebCoreStringResourceBase::WebCoreStringResourceBase):
5560         (WebCore::WebCoreStringResourceBase::~WebCoreStringResourceBase):
5561         (WebCore::WebCoreStringResourceBase::atomicString):
5562         (WebCore::WebCoreStringResourceBase::memoryConsumption):
5563         (WebCoreStringResource16):
5564         (WebCore::WebCoreStringResource16::WebCoreStringResource16):
5565         (WebCore):
5566         (WebCoreStringResource8):
5567         (WebCore::WebCoreStringResource8::WebCoreStringResource8):
5568
5569 2012-11-16  Erik Arvidsson  <arv@chromium.org>
5570
5571         Update DOMException name: InvalidAccessError
5572         https://bugs.webkit.org/show_bug.cgi?id=102400
5573
5574         Reviewed by Kentaro Hara.
5575
5576         Patch 15 of 25 to update DOMException name to match the spec and Firefox.
5577
5578         Updated existing tests.
5579
5580         * dom/DOMCoreException.cpp:
5581
5582 2012-11-16  Alexandru Chiculita  <achicu@adobe.com>
5583
5584         [Texmap][CSS Shaders] Make the CustomFilterValidatedProgram maintain the platform compiled program
5585         https://bugs.webkit.org/show_bug.cgi?id=102414
5586
5587         Reviewed by Noam Rosenthal.
5588
5589         Added WebCore classes needed for the WebKit2 implementation of Texture Mapper to keep a reference to the 
5590         platform compiled custom filter. It is just used to maintain the life-time of the objects. WebKit2 injects a
5591         client in TextureMapperPlatformCompiledProgram and receives a callback when the custom filter program is not
5592         used to render any layer on the page. 
5593
5594         Note that CustomFilterValidatedProgram are reused across multiple elements of the same page. Also, the instances
5595         are reused across frames, so animations should reuse the same pre-validated program. In this case, the mechanism is
5596         extended and reused in the platform compositor.
5597         
5598         No new tests, existing tests for CSS Custom Filters already cover this path.
5599
5600         * CMakeLists.txt:
5601         * GNUmakefile.am:
5602         * GNUmakefile.list.am:
5603         * Target.pri:
5604         * WebCore.pri:
5605         * platform/graphics/filters/CustomFilterValidatedProgram.cpp:
5606         (WebCore):
5607         * platform/graphics/filters/CustomFilterValidatedProgram.h:
5608         (WebCore):
5609         (CustomFilterValidatedProgram):
5610         * platform/graphics/filters/texmap/CustomFilterValidatedProgramTextureMapper.cpp: Added.
5611         (WebCore):
5612         (WebCore::CustomFilterValidatedProgram::platformCompiledProgram): Platform implementation for creating and deleting the reference.
5613         (WebCore::CustomFilterValidatedProgram::platformInit):
5614         (WebCore::CustomFilterValidatedProgram::platformDestroy):
5615         * platform/graphics/filters/texmap/TextureMapperPlatformCompiledProgram.h: Added.
5616         (WebCore):
5617         (TextureMapperPlatformCompiledProgramClient):
5618         (WebCore::TextureMapperPlatformCompiledProgramClient::ref):
5619         (WebCore::TextureMapperPlatformCompiledProgramClient::deref):
5620         (TextureMapperPlatformCompiledProgram):
5621         Stores a link to a TextureMapperPlatformCompiledProgramClient. It's main purpose is to call unref on the client when
5622         the shader is not needed anymore. WebKit2 can use that to delete the corresponding shader from the compositor side.
5623         (WebCore::TextureMapperPlatformCompiledProgram::create):
5624         (WebCore::TextureMapperPlatformCompiledProgram::setClient): Used by WebKit2 to inject the platform client.
5625         (WebCore::TextureMapperPlatformCompiledProgram::client):
5626         (WebCore::TextureMapperPlatformCompiledProgram::TextureMapperPlatformCompiledProgram):
5627
5628 2012-11-16  Andreas Kling  <akling@apple.com>
5629
5630         Short-circuit Element::hasEquivalentAttributes() if elements share attribute data.
5631         <http://webkit.org/b/102498>
5632
5633         Reviewed by Antti Koivisto.
5634
5635         Add a fast path to hasEquivalentAttributes() that checks if both elements are using
5636         the same ElementAttributeData.
5637
5638         * dom/Element.cpp:
5639         (WebCore::Element::hasEquivalentAttributes):
5640
5641 2012-11-16  Zeno Albisser  <zeno@webkit.org>
5642
5643         [Qt] Adding a null pointer check for currentContext to GraphicsContext3DQt.
5644         https://bugs.webkit.org/show_bug.cgi?id=102360
5645
5646         QOpenGLContext::currentContext() will return null, in case there is
5647         no current context. Therefore currentContext must be null-checked
5648         before it can be reused.
5649         Making a context current on a null-surface on the other hand is
5650         perfectly possible.
5651
5652         Reviewed by Kenneth Rohde Christiansen.
5653
5654         * platform/graphics/qt/GraphicsContext3DQt.cpp:
5655         (WebCore::GraphicsContext3DPrivate::blitMultisampleFramebufferAndRestoreContext):
5656
5657 2012-11-16  Eugene Klyuchnikov  <eustas.bug@gmail.com>
5658
5659         Web Inspector: Workaround to show shortcuts for panels that hasn't been loaded.
5660         https://bugs.webkit.org/show_bug.cgi?id=102488
5661
5662         Reviewed by Vsevolod Vlasov.
5663
5664         Panels are lazily loaded / instantiated.
5665         Panel constructors register keyboard shortcuts.
5666
5667         When user open shortcuts screen all panel should be loaded.
5668         Otherwise some shortcuts will be missing.
5669
5670         * inspector/front-end/ShortcutsScreen.js: Added callback invokation.
5671         * inspector/front-end/inspector.js:
5672         Provided callback that loads all panels.
5673
5674 2012-11-16  Kentaro Hara  <haraken@chromium.org>
5675
5676         [V8] Remove IsSubType() from CodeGeneratorV8.pm
5677         https://bugs.webkit.org/show_bug.cgi?id=102348
5678
5679         Reviewed by Adam Barth.
5680
5681         CodeGenerator.pm has IsStrictSubType(). CodeGeneratorV8.pm should use it.
5682
5683         No tests. No change in behavior.
5684
5685         * bindings/scripts/CodeGenerator.pm:
5686         (IsSubType):
5687         * bindings/scripts/CodeGeneratorJS.pm:
5688         (GenerateImplementation):
5689         * bindings/scripts/CodeGeneratorV8.pm:
5690         (GenerateHeader):
5691         (GetInternalFields):
5692         (GenerateNormalAttrGetter):
5693         (GenerateNormalAttrSetter):
5694         (GenerateFunctionCallback):
5695         (GenerateImplementationIndexer):
5696         (GenerateToV8Converters):
5697
5698 2012-11-16  Mario Sanchez Prada  <mario@webkit.org>
5699
5700         [EFL] Share WebKit-Gtk's Accessibility implementation with others WebKit ports.
5701         https://bugs.webkit.org/show_bug.cgi?id=99578
5702
5703         Reviewed by Martin Robinson.
5704
5705         Renamed WebCore/accessibility/gtk to WebCore/accessibility/atk.
5706
5707         * GNUmakefile.am:
5708         * GNUmakefile.list.am:
5709         * accessibility/atk/AXObjectCacheAtk.cpp: Renamed from
5710         Source/WebCore/accessibility/gtk/AXObjectCacheAtk.cpp.
5711         * accessibility/atk/AccessibilityObjectAtk.cpp: Renamed from
5712         Source/WebCore/accessibility/gtk/AccessibilityObjectAtk.cpp.
5713         * accessibility/atk/WebKitAccessibleHyperlink.cpp: Renamed from
5714         Source/WebCore/accessibility/gtk/WebKitAccessibleHyperlink.cpp.
5715         * accessibility/atk/WebKitAccessibleHyperlink.h: Renamed from
5716         Source/WebCore/accessibility/gtk/WebKitAccessibleHyperlink.h.
5717         * accessibility/atk/WebKitAccessibleInterfaceAction.cpp: Renamed
5718         from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceAction.cpp.
5719         * accessibility/atk/WebKitAccessibleInterfaceAction.h: Renamed
5720         from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceAction.h.
5721         * accessibility/atk/WebKitAccessibleInterfaceComponent.cpp:
5722         Renamed from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceComponent.cpp.
5723         * accessibility/atk/WebKitAccessibleInterfaceComponent.h: Renamed
5724         from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceComponent.h.
5725         * accessibility/atk/WebKitAccessibleInterfaceDocument.cpp: Renamed
5726         from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceDocument.cpp.
5727         * accessibility/atk/WebKitAccessibleInterfaceDocument.h: Renamed
5728         from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceDocument.h.
5729         * accessibility/atk/WebKitAccessibleInterfaceEditableText.cpp:
5730         Renamed from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceEditableText.cpp.
5731         * accessibility/atk/WebKitAccessibleInterfaceEditableText.h:
5732         Renamed from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceEditableText.h.
5733         * accessibility/atk/WebKitAccessibleInterfaceHyperlinkImpl.cpp:
5734         Renamed from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceHyperlinkImpl.cpp.
5735         * accessibility/atk/WebKitAccessibleInterfaceHyperlinkImpl.h:
5736         Renamed from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceHyperlinkImpl.h.
5737         * accessibility/atk/WebKitAccessibleInterfaceHypertext.cpp:
5738         Renamed from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceHypertext.cpp.
5739         * accessibility/atk/WebKitAccessibleInterfaceHypertext.h: Renamed
5740         from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceHypertext.h.
5741         * accessibility/atk/WebKitAccessibleInterfaceImage.cpp: Renamed
5742         from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceImage.cpp.
5743         * accessibility/atk/WebKitAccessibleInterfaceImage.h: Renamed from
5744         Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceImage.h.
5745         * accessibility/atk/WebKitAccessibleInterfaceSelection.cpp:
5746         Renamed from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceSelection.cpp.
5747         * accessibility/atk/WebKitAccessibleInterfaceSelection.h: Renamed
5748         from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceSelection.h.
5749         * accessibility/atk/WebKitAccessibleInterfaceTable.cpp: Renamed
5750         from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceTable.cpp.
5751         * accessibility/atk/WebKitAccessibleInterfaceTable.h: Renamed from
5752         Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceTable.h.
5753         * accessibility/atk/WebKitAccessibleInterfaceText.cpp: Renamed
5754         from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceText.cpp.
5755         * accessibility/atk/WebKitAccessibleInterfaceText.h: Renamed from
5756         Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceText.h.
5757         * accessibility/atk/WebKitAccessibleInterfaceValue.cpp: Renamed
5758         from Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceValue.cpp.
5759         * accessibility/atk/WebKitAccessibleInterfaceValue.h: Renamed from
5760         Source/WebCore/accessibility/gtk/WebKitAccessibleInterfaceValue.h.
5761         * accessibility/atk/WebKitAccessibleUtil.cpp: Renamed from
5762         Source/WebCore/accessibility/gtk/WebKitAccessibleUtil.cpp.
5763         * accessibility/atk/WebKitAccessibleUtil.h: Renamed from
5764         Source/WebCore/accessibility/gtk/WebKitAccessibleUtil.h.
5765         * accessibility/atk/WebKitAccessibleWrapperAtk.cpp: Renamed from
5766         Source/WebCore/accessibility/gtk/WebKitAccessibleWrapperAtk.cpp.
5767         * accessibility/atk/WebKitAccessibleWrapperAtk.h: Renamed from
5768         Source/WebCore/accessibility/gtk/WebKitAccessibleWrapperAtk.h.
5769
5770 2012-11-16  Shinya Kawanaka  <shinyak@chromium.org>
5771
5772         Changing pseudoClass (:indeterminate) should cause distribution
5773         https://bugs.webkit.org/show_bug.cgi?id=101903
5774
5775         Reviewed by Dimitri Glazkov.
5776
5777         <progress> and <input type="checkbox"> have 'indeterminate' state. When their state is changed, we have to
5778         invalidate distribution if necessary. To check it, we collect a feature that :invalidate is used in select attributes.
5779
5780         For <input>, we also have to see 'type' is changed. According to the spec, :indeterminate should match only
5781         progress element or <input type="checkbox">. So changing 'type' might also change :indeterminate state.
5782
5783         Tests: fast/dom/shadow/pseudoclass-update-indeterminate-input.html
5784                fast/dom/shadow/pseudoclass-update-indeterminate-progress.html
5785
5786         * html/HTMLInputElement.cpp:
5787         (WebCore::HTMLInputElement::updateType):
5788         (WebCore::HTMLInputElement::setIndeterminate):
5789         * html/HTMLProgressElement.cpp:
5790         (WebCore::HTMLProgressElement::didElementStateChange):
5791
5792 2012-11-16  Alexis Menard  <alexis@webkit.org>
5793
5794         Factorize the creation of primitive values with a pair into a function.
5795         https://bugs.webkit.org/show_bug.cgi?id=102485
5796
5797         Reviewed by Antti Koivisto.
5798
5799         The pattern is already existing in various call sites inside CSSParser
5800         and more will be added in the future (see bug 102104).
5801
5802         No new tests : It's a refactoring only, the tests should cover it.
5803
5804         * css/CSSParser.cpp:
5805         (WebCore):
5806         (WebCore::createPrimitiveValuePair):
5807         (WebCore::CSSParser::parseValue):
5808         (WebCore::CSSParser::parseFillSize):
5809         (WebCore::CSSParser::parseBorderImageRepeat):
5810         (WebCore::CSSParser::parseBorderRadius):
5811         (WebCore::CSSParser::parseCounter):
5812
5813 2012-11-16  Mark Pilgrim  <pilgrim@chromium.org>
5814
5815         Expand PlatformCookieJar interface to allow for other ports
5816         https://bugs.webkit.org/show_bug.cgi?id=102456
5817
5818         Reviewed by Adam Barth.
5819
5820         Add firstParty and cookieURL arguments to several functions to
5821         prepare for integrating Chromium port into new PlatformCookieJar
5822         interface.
5823
5824         * loader/CookieJar.cpp:
5825         (WebCore::cookiesEnabled):
5826         (WebCore::cookieRequestHeaderFieldValue):
5827         (WebCore::getRawCookies):
5828         * platform/network/PlatformCookieJar.h:
5829         (WebCore):
5830         * platform/network/cf/CookieJarCFNet.cpp:
5831         (WebCore::cookieRequestHeaderFieldValue):
5832         (WebCore::cookiesEnabled):
5833         (WebCore::getRawCookies):
5834         * platform/network/curl/CookieJarCurl.cpp:
5835         (WebCore::cookieRequestHeaderFieldValue):
5836         (WebCore::cookiesEnabled):
5837         (WebCore::getRawCookies):
5838         * platform/network/mac/CookieJarMac.mm:
5839         (WebCore::cookieRequestHeaderFieldValue):
5840         (WebCore::cookiesEnabled):
5841         (WebCore::getRawCookies):
5842         * platform/network/qt/CookieJarQt.cpp:
5843         (WebCore::cookieRequestHeaderFieldValue):
5844         (WebCore::cookiesEnabled):
5845         (WebCore::getRawCookies):
5846         * platform/network/soup/CookieJarSoup.cpp:
5847         (WebCore::cookieRequestHeaderFieldValue):
5848         (WebCore::cookiesEnabled):
5849         (WebCore::getRawCookies):
5850         * platform/network/win/CookieJarWin.cpp:
5851         (WebCore::cookieRequestHeaderFieldValue):
5852         (WebCore::cookiesEnabled):
5853         (WebCore::getRawCookies):
5854
5855 2012-11-16  Julien Chaffraix  <jchaffraix@webkit.org>
5856
5857         RenderGrid should have a function to resolve grid position
5858         https://bugs.webkit.org/show_bug.cgi?id=102441
5859
5860         Reviewed by Ojan Vafai.
5861
5862         The code was doing this conversion implicitly inside RenderGrid::findChildLogicalPosition.
5863         Also note that we also provided a fallback by returning LayoutPoint() (ie the (0, 0) position
5864         on the grid) if we couldn't handle the value. The explicit conversion is needed in order to
5865         support render areas and add a proper grid model to RenderGrid.
5866
5867         No expected change in behavior.
5868
5869         * rendering/RenderGrid.h:
5870         * rendering/RenderGrid.cpp:
5871         (WebCore::RenderGrid::resolveGridPosition):
5872         Added this new function to handle the conversion. We re-use Length but should never see
5873         a lot of the <length> values so I added some ASSERTs to enforce and catch that.
5874
5875         (WebCore::RenderGrid::findChildLogicalPosition):
5876         Simplified the function now that it just use resolveGridPosition.
5877
5878 2012-11-16  Ulan Degenbaev  <ulan@chromium.org>
5879
5880         [V8] Increment the amount of externally allocated memory for the receiving V8 isolate when transferring ArrayBuffer
5881         https://bugs.webkit.org/show_bug.cgi?id=94463
5882
5883         Reviewed by Kentaro Hara.
5884
5885         Call AdjustAmountOfExternalAllocatedMemory when V8ArrayBuffer is deserialized and transferred.
5886
5887         Test: ManualTests/typed-array-memory.html
5888
5889         * bindings/v8/SerializedScriptValue.cpp:
5890
5891 2012-11-16  Sheriff Bot  <webkit.review.bot@gmail.com>
5892
5893         Unreviewed, rolling out r134694.
5894         http://trac.webkit.org/changeset/134694
5895         https://bugs.webkit.org/show_bug.cgi?id=102481
5896
5897         it made API test crash on EFL port (Requested by gyuyoung on
5898         #webkit).
5899
5900         * platform/efl/RenderThemeEfl.cpp:
5901         (WebCore::fillColorsFromEdjeClass):
5902         (WebCore::RenderThemeEfl::setColorFromThemeClass):
5903         (WebCore::RenderThemeEfl::loadTheme):
5904         (WebCore::RenderThemeEfl::RenderThemeEfl):
5905         * platform/efl/RenderThemeEfl.h:
5906         (RenderThemeEfl):
5907
5908 2012-11-16  Mike West  <mkwst@chromium.org>
5909
5910         Web Inspector: Move call stack generation out of bindings.
5911         https://bugs.webkit.org/show_bug.cgi?id=101331
5912
5913         Reviewed by Yury Semikhatsky.
5914
5915         Currently, we generate stack traces for console messages at each call
5916         site. Bug 100650 has the end goal of moving all stack trace generation
5917         inside of the Inspector in order to ensure that we never send a console
5918         message without a stack trace if it's possible to generate one. This
5919         also ensures that we never generate unused call stacks.
5920
5921         This patch is the first step in that direction, moving stack trace
5922         generation out of the Console bindings, and into either Console or
5923         InspectorConsoleAgent.
5924
5925         No visible change in behavior should result; this refactoring should
5926         continue to pass all existing inspector tests.
5927
5928         * bindings/js/JSConsoleCustom.cpp:
5929         (WebCore::JSConsole::profile):
5930         (WebCore::JSConsole::profileEnd):
5931             Adjust custom JSC Console bindings to drop call stack generation.
5932         * bindings/scripts/CodeGeneratorJS.pm:
5933         (GenerateCallWith):
5934         * bindings/scripts/CodeGeneratorV8.pm:
5935         (GenerateCallWith):
5936             Drop call stack generation from JSC and V8 bindings.
5937         * bindings/scripts/CodeGeneratorGObject.pm:
5938             Skip timeEnd explicitly in these bindings; it used to include
5939             ScriptArguments, which autoskipped it. Now it doesn't, so it needs
5940             to be called out on its own.
5941         * bindings/v8/ScriptCallStackFactory.cpp:
5942         (WebCore::createScriptCallStackForConsole):
5943         (WebCore::createScriptCallStack):
5944         (WebCore):
5945         * bindings/v8/ScriptCallStackFactory.h:
5946         (WebCore):
5947             Add 'createScriptCallStack(ScriptState*, size_t)' to V8's
5948             ScriptCallStackFactory in order to match JCS' implementation.
5949             It simply delegates to 'createScriptCallStackForConsole', which
5950             now also accepts a 'maxStackSize' parameter.
5951         * bindings/v8/custom/V8ConsoleCustom.cpp:
5952         (WebCore::V8Console::traceCallback):
5953         (WebCore::V8Console::assertCallback):
5954         (WebCore::V8Console::profileCallback):
5955         (WebCore::V8Console::profileEndCallback):
5956             Adjust custom V8 bindings to drop call stack generation.
5957         * inspector/InspectorConsoleAgent.cpp:
5958         (WebCore::InspectorConsoleAgent::addMessageToConsole):
5959             With the eventual goal of getting rid of the call stack parameter
5960             entirely, this patch drops it from one version of
5961             'addMessageToConsole' (replacing it with ScriptState*), and creates
5962             a new version that only accepts a call stack. We should be able to
5963             migrate most (all?) external call sites over to the arguments
5964             version in future patches.
5965         (WebCore):
5966         (WebCore::InspectorConsoleAgent::count):
5967             Count takes 'ScriptState*' instead of a call stack, and generates
5968             the stack as needed.
5969         * inspector/InspectorConsoleAgent.h:
5970         (InspectorConsoleAgent):
5971         * inspector/InspectorConsoleInstrumentation.h:
5972         (WebCore::InspectorInstrumentation::addMessageToConsole):
5973         (WebCore):
5974         (WebCore::InspectorInstrumentation::consoleCount):
5975         * inspector/InspectorInstrumentation.cpp:
5976         (WebCore):
5977         (WebCore::InspectorInstrumentation::addMessageToConsoleImpl):
5978         (WebCore::InspectorInstrumentation::consoleCountImpl):
5979         * inspector/InspectorInstrumentation.h:
5980         (InspectorInstrumentation):
5981             Changes the InspectorInstrumentation pipeline to match the
5982             InspectorConsoleAgent changes.
5983         * page/Console.cpp:
5984         (WebCore::Console::addMessage):
5985             We now (always) generate one frame of a stack trace in order to
5986             populate line numbers and caller URLs. If we need to print the whole
5987             trace here, we generate a full stack.
5988         (WebCore::Console::debug):
5989         (WebCore::Console::error):
5990         (WebCore::Console::info):
5991         (WebCore::Console::log):
5992         (WebCore::Console::warn):
5993         (WebCore::Console::dir):
5994         (WebCore::Console::dirxml):
5995         (WebCore::Console::clear):
5996         (WebCore::Console::trace):
5997         (WebCore::Console::assertCondition):
5998         (WebCore::Console::count):
5999         (WebCore::Console::markTimeline):
6000         (WebCore::Console::timeEnd):
6001         (WebCore::Console::timeStamp):
6002         (WebCore::Console::group):
6003         (WebCore::Console::groupCollapsed):
6004         (WebCore::Console::profile):
6005         (WebCore::Console::profileEnd):
6006             s/ScriptCallStack/ScriptState*/g. Also, printing the stack trace
6007             has been moved out of 'trace' and into 'addMessage'.
6008         * page/Console.h:
6009         (Console):
6010         * page/Console.idl:
6011             Drop the call stack, add the script state.
6012         * workers/WorkerContext.cpp:
6013         (WebCore::WorkerContext::addMessageToWorkerConsole):
6014             Use the new, explicitly call stacked addMessageToConsole. We'll kill
6015             this in a future patch.
6016
6017 2012-11-16  Marja Hölttä  <marja@chromium.org>
6018
6019         Add initiator to CachedResourceRequest.
6020         https://bugs.webkit.org/show_bug.cgi?id=101935
6021
6022         Reviewed by Adam Barth.
6023
6024         Motivation: Chromium needs to know which elements request a
6025         resource (such as an image or a script) (bug 92761). In addition,
6026         for exposing resource timing information (bug 84883) we need to
6027         store the initiator, and this is the first step towards it.
6028
6029         No new tests: No visible change in behavior.
6030
6031         * CMakeLists.txt:
6032         * GNUmakefile.list.am:
6033         * Target.pri:
6034         * WebCore.gypi:
6035         * WebCore.vcproj/WebCore.vcproj:
6036         * WebCore.xcodeproj/project.pbxproj:
6037         * css/CSSCursorImageValue.cpp:
6038         (WebCore::CSSCursorImageValue::cachedImage):
6039         * css/CSSFontFaceSrcValue.cpp:
6040         (WebCore::CSSFontFaceSrcValue::cachedFont):
6041         * css/CSSImageSetValue.cpp:
6042         (WebCore::CSSImageSetValue::cachedImageSet):
6043         * css/CSSImageValue.cpp:
6044         (WebCore::CSSImageValue::cachedImage):
6045         * css/CSSImageValue.h:
6046         (WebCore):
6047         (CSSImageValue):
6048         * css/StyleResolver.cpp:
6049         (WebCore::StyleResolver::loadPendingImage):
6050         * css/StyleRuleImport.cpp:
6051         (WebCore::StyleRuleImport::requestStyleSheet):
6052         * css/WebKitCSSSVGDocumentValue.cpp:
6053         (WebCore::WebKitCSSSVGDocumentValue::load):
6054         * css/WebKitCSSShaderValue.cpp:
6055         (WebCore::WebKitCSSShaderValue::cachedShader):
6056         * dom/ScriptElement.cpp:
6057         (WebCore::ScriptElement::requestScript):
6058         * html/HTMLLinkElement.cpp:
6059         (WebCore::HTMLLinkElement::process):
6060         * html/parser/CSSPreloadScanner.cpp:
6061         (WebCore::CSSPreloadScanner::emitRule):
6062         * html/parser/CSSPreloadScanner.h:
6063         (CSSPreloadScanner):
6064         * html/parser/HTMLPreloadScanner.cpp:
6065         (WebCore::PreloadTask::preload):
6066         * loader/ImageLoader.cpp:
6067         (WebCore::ImageLoader::updateFromElement):
6068         * loader/cache/CachedResourceLoader.cpp:
6069         (WebCore::CachedResourceLoader::requestImage):
6070         (WebCore::CachedResourceLoader::requestResource):
6071         (WebCore::CachedResourceLoader::determineRevalidationPolicy):
6072         (WebCore):
6073         (WebCore::CachedResourceLoader::preload):
6074         * loader/cache/CachedResourceLoader.h:
6075         (WebCore):
6076         (CachedResourceLoader):
6077         * loader/cache/CachedResourceRequest.cpp:
6078         (WebCore::CachedResourceRequest::CachedResourceRequest):
6079         (WebCore):
6080         (WebCore::CachedResourceRequest::~CachedResourceRequest):
6081         (WebCore::CachedResourceRequest::setInitiator):
6082         (WebCore::CachedResourceRequest::initiatorName):
6083         (WebCore::CachedResourceRequest::initiatorDocument):
6084         (WebCore::CachedResourceRequest::initiatorElement):
6085         * loader/cache/CachedResourceRequest.h:
6086         (WebCore):
6087         (WebCore::CachedResourceRequest::setOptions):
6088         (WebCore::CachedResourceRequest::defer):
6089         (WebCore::CachedResourceRequest::setDefer):
6090         (CachedResourceRequest):
6091         * loader/cache/CachedResourceRequestInitiators.cpp: Copied from Source/WebCore/loader/cache/CachedResourceRequest.cpp.
6092         (WebCore):
6093         (WebCore::CachedResourceRequestInitiators::CachedResourceRequestInitiators):
6094         * loader/cache/CachedResourceRequestInitiators.h: Copied from Source/WebCore/loader/cache/CachedResourceRequest.cpp.
6095         (WebCore):
6096         (CachedResourceRequestInitiators):
6097         (WebCore::cachedResourceRequestInitiators):
6098         * loader/icon/IconLoader.cpp:
6099         (WebCore::IconLoader::startLoading):
6100         * platform/ThreadGlobalData.cpp:
6101         (WebCore::ThreadGlobalData::ThreadGlobalData):
6102         * platform/ThreadGlobalData.h:
6103         (WebCore):
6104         (WebCore::ThreadGlobalData::cachedResourceRequestInitiators):
6105         (ThreadGlobalData):
6106         * svg/SVGFEImageElement.cpp:
6107         (WebCore::SVGFEImageElement::requestImageResource):
6108         * svg/SVGFontFaceUriElement.cpp:
6109         (WebCore::SVGFontFaceUriElement::loadFont):
6110         * svg/SVGUseElement.cpp:
6111         (WebCore::SVGUseElement::svgAttributeChanged):
6112
6113 2012-11-16  Yury Semikhatsky  <yurys@chromium.org>
6114
6115         Web Inspector: don't show an Error when evaluating a watch expression results in an exception
6116         https://bugs.webkit.org/show_bug.cgi?id=102470
6117
6118         Reviewed by Vsevolod Vlasov.
6119
6120         Dim watch expression and show "<not available>" as its value in cases when it evaluates
6121         into an exception.
6122
6123         * English.lproj/localizedStrings.js:
6124         * inspector/front-end/WatchExpressionsSidebarPane.js:
6125         (WebInspector.WatchExpressionTreeElement.prototype.update):
6126         * inspector/front-end/inspector.css:
6127
6128 2012-11-16  Vsevolod Vlasov  <vsevik@chromium.org>
6129
6130         Web Inspector: Rollout 134404 134548 134552 Temporarily rolling out to ease merging.
6131         https://bugs.webkit.org/show_bug.cgi?id=102476
6132
6133         Unreviewed rolling out.
6134
6135         * English.lproj/localizedStrings.js:
6136         * WebCore.gypi:
6137         * WebCore.vcproj/WebCore.vcproj:
6138         * inspector/compile-front-end.py:
6139         * inspector/front-end/AdvancedSearchController.js:
6140         * inspector/front-end/CallStackSidebarPane.js:
6141         (WebInspector.CallStackSidebarPane.prototype.registerShortcuts):
6142         * inspector/front-end/ConsoleView.js:
6143         (WebInspector.ConsoleView.prototype._registerShortcuts):
6144         * inspector/front-end/ElementsPanel.js:
6145         (WebInspector.ElementsPanel):
6146         (WebInspector.ElementsPanel.prototype._registerShortcuts):
6147         * inspector/front-end/ElementsPanelDescriptor.js:
6148         * inspector/front-end/GoToLineDialog.js:
6149         (WebInspector.GoToLineDialog.install):
6150         * inspector/front-end/KeyboardShortcut.js:
6151         (WebInspector.KeyboardShortcut._keyName):
6152         * inspector/front-end/Panel.js:
6153         (WebInspector.Panel.prototype.registerShortcut):
6154         (WebInspector.Panel.prototype.unregisterShortcut):
6155         (WebInspector.PanelDescriptor.prototype.panel):
6156         * inspector/front-end/ScriptsPanel.js:
6157         (WebInspector.ScriptsPanel):
6158         (WebInspector.ScriptsPanel.prototype._createDebugToolbar):
6159         (WebInspector.ScriptsPanel.prototype._createButtonAndRegisterShortcuts):
6160         * inspector/front-end/ScriptsPanelDescriptor.js:
6161         * inspector/front-end/ShortcutsScreen.js:
6162         (WebInspector.ShortcutsScreen):
6163         (WebInspector.ShortcutsSection):
6164         (WebInspector.ShortcutsSection.prototype._renderKey):
6165         * inspector/front-end/StylesSidebarPane.js:
6166         (WebInspector.StylesSidebarPane.prototype.registerShortcuts):
6167         * inspector/front-end/TimelinePanel.js:
6168         (WebInspector.TimelinePanel.prototype._registerShortcuts):
6169         * inspector/front-end/TimelinePanelDescriptor.js: Removed.
6170         * inspector/front-end/WebKit.qrc:
6171         * inspector/front-end/inspector.html:
6172         * inspector/front-end/inspector.js:
6173         (WebInspector._panelDescriptors):
6174         (WebInspector._registerShortcuts):
6175
6176 2012-11-16  Eugene Klyuchnikov  <eustas.bug@gmail.com>
6177
6178         Web Inspector: Memory Timeline Crash
6179         https://bugs.webkit.org/show_bug.cgi?id=102390
6180
6181         Reviewed by Vsevolod Vlasov.
6182
6183         Crash seems to be caused by IPC overflow.
6184         Messages "ParsedScriptSource" are routed to
6185         ResourceScriptMapping.prototype.addScript that process them in time
6186         linear to number of already registered non-anonymous non-inline scripts.
6187
6188         Fixed this with replacing repreated filtering with "on-line" bucketing.
6189
6190         * inspector/front-end/ResourceScriptMapping.js:
6191         (WebInspector.ResourceScriptMapping):
6192         Removed duplicating initialization code.
6193         (WebInspector.ResourceScriptMapping.prototype.addScript):
6194         Added script bucketing by sourceURL/isInline parameters.
6195         (WebInspector.ResourceScriptMapping.prototype._scriptsForSourceURL):
6196         Avoid filterfig.
6197         (WebInspector.ResourceScriptMapping.prototype._createUISourceCode):
6198         Added outgoing muatable array safeguard.
6199         (WebInspector.ResourceScriptMapping.prototype._reset):
6200         Added type information and added two new maps.
6201
6202 2012-11-16  Helder Correia  <helder.correia@nokia.com>
6203
6204         [CoordGfx] Follow coding style on explicit constructors
6205         https://bugs.webkit.org/show_bug.cgi?id=102451
6206
6207         Reviewed by Noam Rosenthal.
6208
6209         Use the explicit keyword on single argument constructors.
6210
6211         No new tests needed.
6212
6213         * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
6214         (GraphicsLayerTextureMapper):
6215         * platform/graphics/texmap/TextureMapper.h:
6216         (TextureMapper):
6217         * platform/graphics/texmap/TextureMapperBackingStore.h:
6218         (WebCore::TextureMapperTile::TextureMapperTile):
6219         * platform/graphics/texmap/TextureMapperGL.cpp:
6220         (WebCore::TextureMapperGLData::SharedGLData::SharedGLData):
6221         (WebCore::TextureMapperGLData::TextureMapperGLData):
6222         * platform/graphics/texmap/TextureMapperGL.h:
6223         (BitmapTextureGL):
6224         * platform/graphics/texmap/TextureMapperShaderManager.h:
6225         (TextureMapperShaderManager):
6226
6227 2012-11-16  Kihong Kwon  <kihong.kwon@samsung.com>
6228
6229         Add DeviceController base-class to remove duplication of DeviceXXXControler
6230         https://bugs.webkit.org/show_bug.cgi?id=96894
6231
6232         Reviewed by Hajime Morita.
6233
6234         Add DeviceController which is extracted from DeviceOrientationController to remove duplication.
6235         And soon-to-be-added DeviceMotionController and ProximityController.
6236
6237         Covered by existing tests.
6238
6239         * CMakeLists.txt:
6240         * GNUmakefile.list.am:
6241         * Target.pri:
6242         * WebCore.gypi:
6243         * WebCore.vcproj/WebCore.vcproj:
6244         * WebCore.xcodeproj/project.pbxproj:
6245         * dom/DeviceOrientationClient.h:
6246         * dom/DeviceOrientationController.cpp:
6247         Remove member functions to move to DeviceController.
6248         - addListener(), removeListener(), removeAllListeners(), isActive()
6249         (WebCore::DeviceOrientationController::DeviceOrientationController):
6250         (WebCore::DeviceOrientationController::didChangeDeviceOrientation):
6251         (WebCore::DeviceOrientationController::client):
6252         (WebCore::DeviceOrientationController::hasLastData):
6253         (WebCore::DeviceOrientationController::getLastEvent):
6254         (WebCore::DeviceOrientationController::from):
6255         (WebCore):
6256         * dom/DeviceOrientationController.h:
6257         (WebCore):
6258         (WebCore::DeviceOrientationController::~DeviceOrientationController):
6259         (DeviceOrientationController):
6260         * dom/Document.cpp:
6261         Remove suspendEventsForAllListeners() and resumeEventsForAllListeners() function calls.
6262         These calls can be made by checking activeDOMObjectsAreSuspended() and activeDOMObjectsAreStopped() before dispatchEvent.
6263         (WebCore::Document::suspendActiveDOMObjects):
6264         (WebCore::Document::resumeActiveDOMObjects):
6265         * loader/EmptyClients.h:
6266         (EmptyDeviceClient):
6267         (WebCore::EmptyDeviceClient::startUpdating):
6268         (WebCore::EmptyDeviceClient::stopUpdating):
6269         (WebCore):
6270         * page/DOMWindow.cpp:
6271         (WebCore::DOMWindow::addEventListener):
6272         (WebCore::DOMWindow::removeEventListener):
6273         (WebCore::DOMWindow::removeAllEventListeners):
6274         * page/DeviceClient.h: Added.
6275         (WebCore):
6276         (DeviceClient):
6277         (WebCore::DeviceClient::~DeviceClient):
6278         * page/DeviceController.cpp: Added.
6279         DeviceController has extracted functions from DeviceOrientationController and DeviceMotionController.
6280         - addDeviceEventListener(), removeDeviceEventlistener(), removeAllDeviceEventListeners(), dispatchDeviceEvent()
6281         All kind of device event controller which has DeviceClient can be inherited from DeviceController.
6282         (WebCore):
6283         (WebCore::DeviceController::DeviceController):
6284         (WebCore::DeviceController::addDeviceEventListener):
6285         (WebCore::DeviceController::removeDeviceEventListener):
6286         (WebCore::DeviceController::removeAllDeviceEventListeners):
6287         (WebCore::DeviceController::dispatchDeviceEvent):
6288         (WebCore::DeviceController::fireDeviceEvent):
6289         * page/DeviceController.h: Added.
6290         (WebCore):
6291         (DeviceController):
6292         (WebCore::DeviceController::~DeviceController):
6293         (WebCore::DeviceController::isActive):
6294         (WebCore::DeviceController::client):
6295         (WebCore::DeviceController::hasLastData):
6296         (WebCore::DeviceController::getLastEvent):
6297
6298 2012-11-16  Alexander Pavlov  <apavlov@chromium.org>
6299
6300         Web Inspector: [Overrides] Device metrics get reset on navigation, yet remain in the Overrides view
6301         https://bugs.webkit.org/show_bug.cgi?id=102467
6302
6303         Reviewed by Pavel Feldman.
6304
6305         Restore the device metrics overrides from the inspector cookie in InspectorPageAgent::restore().
6306         Drive-by: move the script execution and FPS counter display state restoration from enable() into restore(),
6307         so that they will get restored only upon page navigation, not upon any agent enablement.
6308
6309         * inspector/InspectorPageAgent.cpp:
6310         (WebCore::InspectorPageAgent::restore): Restore device metrics overrides, script execution and FPS counter display state.
6311         (WebCore::InspectorPageAgent::enable): Don't restore script execution and FPS counter display state on any enablement.
6312
6313 2012-11-16  Sheriff Bot  <webkit.review.bot@gmail.com>
6314
6315         Unreviewed, rolling out r134908.
6316         http://trac.webkit.org/changeset/134908
6317         https://bugs.webkit.org/show_bug.cgi?id=102473
6318
6319         Broke the Apple Windows Debug build. (Requested by dydx on
6320         #webkit).
6321
6322         * WebCore.exp.in:
6323         * dom/ViewportArguments.cpp:
6324         (WebCore::computeViewportAttributes):
6325         * dom/ViewportArguments.h:
6326         (WebCore):
6327
6328 2012-11-16  Peter Rybin  <prybin@chromium.org>
6329
6330         Web Inspector: show internal properties in inspector frontend
6331         https://bugs.webkit.org/show_bug.cgi?id=100021
6332
6333         Reviewed by Yury Semikhatsky.
6334
6335         New field 'internalProperties' is parsed and passed via all callbacks to Object Properties section.
6336
6337         Test: inspector/debugger/properties-special.html
6338
6339         * inspector/front-end/ObjectPropertiesSection.js:
6340         (WebInspector.ObjectPropertiesSection.prototype.update.callback):
6341         (WebInspector.ObjectPropertiesSection.prototype.update):
6342         (.callback):
6343         (WebInspector.ObjectPropertyTreeElement.populate):
6344         (.processProperties):
6345         (WebInspector.ArrayGroupingTreeElement._populateAsFragment):
6346         (WebInspector.ArrayGroupingTreeElement._populateNonIndexProperties):
6347         * inspector/front-end/RemoteObject.js:
6348         (WebInspector.RemoteObject.prototype.set else):
6349
6350 2012-11-06  Alexander Pavlov  <apavlov@chromium.org>
6351
6352         Web Inspector: metrics, geolocation, orientation overrides do not belong to the settings panel
6353         https://bugs.webkit.org/show_bug.cgi?id=93691
6354
6355         Reviewed by Vsevolod Vlasov.
6356
6357         - The Overrides tab contents have been moved from the Settings dialog into a brand new Overrides drawer view,
6358         both receiving a new, more light-weight design.
6359         - The Cog button now brings up a popup menu with the "Overrides" and "Settings" items.
6360
6361         * WebCore.gypi:
6362         * WebCore.vcproj/WebCore.vcproj:
6363         * inspector/compile-front-end.py:
6364         * inspector/front-end/ContextMenu.js:
6365         (WebInspector.ContextMenu.prototype.showSoftMenu): Display the ContextMenu as a soft menu.
6366         * inspector/front-end/OverridesView.js: Copied from Source/WebCore/inspector/front-end/SettingsScreen.js.
6367         (WebInspector.OverridesView.appendBlockTo):
6368         (WebInspector.OverridesView):
6369         (WebInspector.OverridesView.showInDrawer):
6370         (WebInspector.OverridesView.prototype.get listener):
6371         (WebInspector.OverridesView.prototype._createUserAgentSelectRowElement.get const):
6372         (WebInspector.OverridesView.prototype._createUserAgentSelectRowElement.textDoubleClicked):
6373         (WebInspector.OverridesView.prototype._createUserAgentSelectRowElement.textChanged):
6374         (WebInspector.OverridesView.prototype._createUserAgentSelectRowElement.set checkboxClicked):
6375         (WebInspector.OverridesView.prototype._createUserAgentSelectRowElement):
6376         (WebInspector.OverridesView.prototype._createInput):
6377         (WebInspector.OverridesView.prototype._onMetricsCheckboxClicked):
6378         (WebInspector.OverridesView.prototype._applyDeviceMetricsUserInput):
6379         (WebInspector.OverridesView.prototype.):
6380         (WebInspector.OverridesView.prototype.set if):
6381         (WebInspector.OverridesView.prototype._createDeviceMetricsElement.swapDimensionsClicked):
6382         (WebInspector.OverridesView.prototype._createDeviceMetricsElement):
6383         (WebInspector.OverridesView.prototype._onGeolocationOverrideCheckboxClicked):
6384         (WebInspector.OverridesView.prototype._applyGeolocationUserInput):
6385         (WebInspector.OverridesView.prototype._setGeolocationPosition):
6386         (WebInspector.OverridesView.prototype._createGeolocationOverrideElement):
6387         (WebInspector.OverridesView.prototype._onDeviceOrientationOverrideCheckboxClicked):
6388         (WebInspector.OverridesView.prototype._applyDeviceOrientationUserInput):
6389         (WebInspector.OverridesView.prototype._setDeviceOrientation):
6390         (WebInspector.OverridesView.prototype._createDeviceOrientationOverrideElement):
6391         * inspector/front-end/ScriptsPanel.js:
6392         (WebInspector.ScriptsPanel): Fix the "DOM Breakpoints" pane move upon the panel creation.
6393         * inspector/front-end/SettingsScreen.js:
6394         (WebInspector.SettingsTab):
6395         (WebInspector.SettingsTab.prototype._appendSection):
6396         (WebInspector.GenericSettingsTab):
6397         (WebInspector.ExperimentsSettingsTab):
6398         (WebInspector.SettingsController): Implement the popup menu upon the button click.
6399         (WebInspector.SettingsController.prototype.showOverrides):
6400         (WebInspector.SettingsController.prototype.showSettings):
6401         (WebInspector.SettingsController.prototype.appendApplicableItems):
6402         (WebInspector.SettingsController.prototype._buttonPressed):
6403         (WebInspector.SettingsController.prototype._onHideSettingsScreen):
6404         (WebInspector.SettingsController.prototype.showSettingsScreen):
6405         * inspector/front-end/ShortcutsScreen.js: Add "Shortcuts" header.
6406         (WebInspector.ShortcutsScreen.prototype.createShortcutsTabView):
6407         * inspector/front-end/SoftContextMenu.js: Enable in all cases, implement the alignToCurrentTarget mode in show().
6408         (WebInspector.SoftContextMenu.prototype.show):
6409         * inspector/front-end/TabbedPane.js: Implement vertical tab layout (skipping the tab width computations).
6410         (WebInspector.TabbedPane.prototype.set verticalTabLayout):
6411         (WebInspector.TabbedPane.prototype._updateWidths):
6412         (WebInspector.TabbedPaneTab.prototype.setWidth):
6413         (WebInspector.TabbedPaneTab.prototype._createTabElement):
6414         * inspector/front-end/WebKit.qrc:
6415         * inspector/front-end/helpScreen.css: Update styles for the new Settings and Overrides look-and-feel.
6416         * inspector/front-end/inspector.css: Drive-by fix small artifacts in the soft menu and drawer view statusbar item label.
6417         (.soft-context-menu-item):
6418         (.drawer-header):
6419         * inspector/front-end/inspector.html:
6420
6421 2012-11-16  Sheriff Bot  <webkit.review.bot@gmail.com>
6422
6423         Unreviewed, rolling out r134865.
6424         http://trac.webkit.org/changeset/134865
6425         https://bugs.webkit.org/show_bug.cgi?id=102466
6426
6427         Broke the Apple Windows Debug build. (Requested by dydx on
6428         #webkit).
6429
6430         * WebCore.exp.in:
6431         * bindings/js/SerializedScriptValue.h:
6432         * testing/Internals.cpp:
6433         * testing/Internals.h:
6434         (WebCore):
6435         * testing/Internals.idl:
6436
6437 2012-11-16  Takashi Sakamoto  <tasak@google.com>
6438
6439         ASSERT_NOT_REACHED() when building a CSSOM wrapper for StyleRuleHost
6440         https://bugs.webkit.org/show_bug.cgi?id=102116
6441
6442         Reviewed by Alexander Pavlov.
6443
6444         Provide a CSSUnknownRule instance as a CSSOM wrapper for StyleRuleHost
6445         rules. Since there is no CSSOM wrapper for @host @-rules and
6446         ASSERT_NOT_REACHED is used when a CSSOM wrapper is requested,
6447         this crash occurs.
6448
6449         Tests: fast/css/at-host-cssom-crash.html
6450                inspector/styles/styles-include-host-rules-crash.html
6451
6452         * css/StyleRule.cpp:
6453         (WebCore::StyleRuleBase::createCSSOMWrapper):
6454         Return a CSSUnknownRule instance for StyleRuleHost rules instead of
6455         calling ASSERT_NOT_REACHED().
6456
6457 2012-11-16  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
6458
6459         Avoid copying of ViewportArguments in computeViewportAttributes function
6460         https://bugs.webkit.org/show_bug.cgi?id=102354
6461
6462         Reviewed by Kenneth Rohde Christiansen.
6463
6464         Since r134749 we do not need copying of ViewportArguments parameter in
6465         computeViewportAttributes() as it is not modified any more.
6466
6467         Tested by existing tests fast/viewport.
6468
6469         * WebCore.exp.in: Updated exported symbols for MAC.
6470         * dom/ViewportArguments.cpp:
6471         (WebCore::computeViewportAttributes):
6472         * dom/ViewportArguments.h:
6473         (WebCore):
6474
6475 2012-11-15  Yury Semikhatsky  <yurys@chromium.org>
6476
6477         Memory instrumentation: add code for reporting stack traces of unknown instrumented objects
6478         https://bugs.webkit.org/show_bug.cgi?id=102384
6479
6480         Reviewed by Pavel Feldman.
6481
6482         * inspector/InspectorMemoryAgent.cpp:
6483         (WebCore::MemoryInstrumentationClientImpl::checkCountedObject): return false
6484         if the check fails.
6485         * inspector/MemoryInstrumentationImpl.h:
6486         (MemoryInstrumentationClientImpl):
6487
6488 2012-11-15  Jer Noble  <jer.noble@apple.com>
6489
6490         Crash at WebCore::PluginData::pluginFileForMimeType const + 38
6491         https://bugs.webkit.org/show_bug.cgi?id=102454
6492
6493         Reviewed by Dan Bernstein.
6494
6495         NULL-check the return value of Page::pluginData().
6496
6497         * loader/SubframeLoader.cpp:
6498         (WebCore::logPluginRequest):
6499
6500 2012-11-15  Kenichi Ishibashi  <bashi@chromium.org>
6501
6502         [Chromium] Unreviewed build fix attempt on win
6503
6504         Include OpenTypeVerticalData.h
6505
6506         * platform/graphics/chromium/FontPlatformDataChromiumWin.h:
6507         (WebCore):
6508
6509 2012-11-15  Kentaro Hara  <haraken@chromium.org>
6510
6511         Unreviewed, rolling out r134881.
6512         http://trac.webkit.org/changeset/134881
6513         https://bugs.webkit.org/show_bug.cgi?id=102348
6514
6515         http/tests/appcache tests on JSC platforms are broken
6516
6517         * bindings/scripts/CodeGenerator.pm:
6518         (IsStrictSubtype):
6519         * bindings/scripts/CodeGeneratorJS.pm:
6520         (GenerateImplementation):
6521         * bindings/scripts/CodeGeneratorV8.pm:
6522         (GenerateHeader):
6523         (GetInternalFields):
6524         (IsSubType):
6525         (IsNodeSubType):
6526         (GenerateNormalAttrGetter):
6527         (GenerateNormalAttrSetter):
6528         (GenerateFunctionCallback):
6529         (GenerateImplementationIndexer):
6530         (GenerateToV8Converters):
6531
6532 2012-11-15  Viatcheslav Ostapenko  <v.ostapenko@samsung.com>
6533
6534         [TexMap][Cairo][Qt] Refactor BitmapTextureGL::updateContents().
6535         https://bugs.webkit.org/show_bug.cgi?id=102420
6536
6537         Reviewed by Gyuyoung Kim.
6538
6539         Moved out texture upload without swizzle to the separate method and changed
6540         drawRepaintCounter to use no-swizzle method. This also fixes blue background
6541         of repaint counters in Qt Minibrowser.
6542         Added condition for sub-image buffer creation to not create it if full image is
6543         uploaded. This should give noticeable improvement for platforms that do not
6544         support sub-image upload to texture.
6545
6546         Covered by existing tests.
6547
6548         * platform/graphics/texmap/TextureMapperGL.cpp:
6549         (WebCore::TextureMapperGL::drawRepaintCounter):
6550         (WebCore::BitmapTextureGL::updateContentsNoSwizzle):
6551         (WebCore):
6552         (WebCore::BitmapTextureGL::updateContents):
6553         * platform/graphics/texmap/TextureMapperGL.h:
6554         (BitmapTextureGL):
6555
6556 2012-11-15  Kent Tamura  <tkent@chromium.org>
6557
6558         A Spin button should release mouse event capturing when a modal dialog opens
6559         https://bugs.webkit.org/show_bug.cgi?id=98007
6560
6561         Reviewed by Hajime Morita.
6562
6563         Description of bug:
6564         If the mouse left button is pressed on a spin button in
6565         input[type=number] and a 'change' event handler opens a modal dialog
6566         such as alert(), a repeating timer doesn't stop and mouse event
6567         capturing isn't released even though the mouse pointer isn't on the spin
6568         button.
6569         A user will see repeating alert dialogs for a document like <input
6570         type=number value=1 onchange="if (this.value==1) {alert(...);
6571         this.value=1;}"> by clicking the up button.
6572
6573         How to solve:
6574         We should notify modal dialog or popup open to a spin button.
6575         This patch introduce PopupOpeningObserver. Chrome notifies it when
6576         any dialogs / popups is opening. SpinButtonElement implements
6577         PopupOpeningObserver and registers/unregisters itself to/from
6578         Chrome.
6579
6580         No new tests. This is a behavior change, but it's very hard to make an
6581         automated test for timer-related behavior.
6582
6583         * page/PopupOpeningObserver.h: Added.
6584         * GNUmakefile.list.am: Add PopupOpeningObserver.h
6585         * Target.pri: Ditto.
6586         * WebCore.gypi: Ditto.
6587         * WebCore.vcproj/WebCore.vcproj: Ditto.
6588         * WebCore.xcodeproj/project.pbxproj: Ditto.
6589
6590         * page/Chrome.cpp:
6591         (WebCore::Chrome::runJavaScriptAlert): Calls notifyPopupOpeningObservers.
6592         (WebCore::Chrome::runJavaScriptConfirm): Ditto.
6593         (WebCore::Chrome::runJavaScriptPrompt): Ditto.
6594         (WebCore::Chrome::createColorChooser): Ditto.
6595         (WebCore::Chrome::openDateTimeChooser):
6596         Added. Calls notifyPopupOpeningObservers before calling
6597         ChromeClient::openDateTimeChooser.
6598         (WebCore::Chrome::runOpenPanel): Calls notifyPopupOpeningObservers.
6599         (WebCore::Chrome::createPopupMenu): Ditto.
6600         (WebCore::Chrome::createSearchPopupMenu): Ditto.
6601         (WebCore::Chrome::registerPopupOpeningObserver): Added.
6602         (WebCore::Chrome::unregisterPopupOpeningObserver): Added.
6603         (WebCore::Chrome::notifyPopupOpeningObservers): Added.
6604         * page/Chrome.h: Added new members and required class/struct declarations.
6605
6606         * html/BaseChooserOnlyDateAndTimeInputType.cpp:
6607         (WebCore::BaseChooserOnlyDateAndTimeInputType::handleDOMActivateEvent):
6608         Use Chrome::openDateTimeChooser instead of ChromeClient::openDateTimeChooser.
6609         * html/shadow/PickerIndicatorElement.cpp:
6610         (WebCore::PickerIndicatorElement::openPopup): Ditto.
6611
6612         * html/shadow/SpinButtonElement.h:
6613         (SpinButtonElement): Declare willOpenPopup.
6614         * html/shadow/SpinButtonElement.cpp:
6615         (WebCore::SpinButtonElement::defaultEventHandler):
6616         Change the order of timer start and changing the value so that we
6617         can cancel the timer correctly.
6618         Calls Chrome::registerPopupOpeningObserver on starting mouse capturing.
6619         (WebCore::SpinButtonElement::willOpenPopup):
6620         Release mouse event capturing before opening a modal dialog.
6621         (WebCore::SpinButtonElement::releaseCapture):
6622         Calls Chrome::unregisterPopupOpeningObserver.
6623
6624
6625 2012-11-15  Shinya Kawanaka  <shinyak@chromium.org>
6626
6627         Chaging pseudoClass (:enabled) should cause distribution
6628         https://bugs.webkit.org/show_bug.cgi?id=101900
6629
6630         Reviewed by Dimitri Glazkov.
6631
6632         When element's 'enabled' state is changed, we have to invalidate distribution.
6633
6634         According to the spec, :enabled matches anchor/area/link element having href attribute,
6635         and several form control elements which is not disabled. However, currently :enalbed does not match
6636         anchor/area/link yet. See https://bugs.webkit.org/show_bug.cgi?id=102349
6637
6638         Tests: fast/dom/shadow/pseudoclass-update-enabled-anchor.html
6639                fast/dom/shadow/pseudoclass-update-enabled-area.html
6640                fast/dom/shadow/pseudoclass-update-enabled-button.html
6641                fast/dom/shadow/pseudoclass-update-enabled-fieldset.html
6642                fast/dom/shadow/pseudoclass-update-enabled-input.html
6643                fast/dom/shadow/pseudoclass-update-enabled-optgroup.html
6644                fast/dom/shadow/pseudoclass-update-enabled-option.html
6645                fast/dom/shadow/pseudoclass-update-enabled-select.html
6646                fast/dom/shadow/pseudoclass-update-enabled-textarea.html
6647
6648         * html/HTMLAnchorElement.cpp:
6649         (WebCore::HTMLAnchorElement::parseAttribute):
6650         * html/HTMLFormControlElement.cpp:
6651         (WebCore::HTMLFormControlElement::disabledAttributeChanged):
6652         * html/HTMLOptGroupElement.cpp:
6653         (WebCore::HTMLOptGroupElement::parseAttribute):
6654         * html/HTMLOptionElement.cpp:
6655         (WebCore::HTMLOptionElement::parseAttribute):
6656
6657 2012-11-15  Erik Arvidsson  <arv@chromium.org>
6658
6659         Update DOMException name: ValidationError
6660         https://bugs.webkit.org/show_bug.cgi?id=102416
6661
6662         Reviewed by Kentaro Hara.
6663
6664         Patch 16 of 25 to update DOMException name to match the spec and Firefox.
6665
6666         VALIDATION_ERR is historical and not used in any spec or our code.
6667
6668         * dom/DOMCoreException.cpp:
6669         * dom/ExceptionCode.h:
6670
6671 2012-11-15  Kentaro Hara  <haraken@chromium.org>
6672
6673         [V8] Remove IsSubType() from CodeGeneratorV8.pm
6674         https://bugs.webkit.org/show_bug.cgi?id=102348
6675
6676         Reviewed by Adam Barth.
6677
6678         CodeGenerator.pm has IsStrictSubType(). CodeGeneratorV8.pm should use it.
6679
6680         No tests. No change in behavior.
6681
6682         * bindings/scripts/CodeGenerator.pm:
6683         (IsSubType):
6684         * bindings/scripts/CodeGeneratorJS.pm:
6685         (GenerateImplementation):
6686         * bindings/scripts/CodeGeneratorV8.pm:
6687         (GenerateHeader):
6688         (GetInternalFields):
6689         (GenerateNormalAttrGetter):
6690         (GenerateNormalAttrSetter):
6691         (GenerateFunctionCallback):
6692         (GenerateImplementationIndexer):
6693         (GenerateToV8Converters):
6694
6695 2012-11-15  Erik Arvidsson  <arv@chromium.org>
6696
6697         Update DOMException name: NamespaceError
6698         https://bugs.webkit.org/show_bug.cgi?id=102395
6699
6700         Reviewed by Kentaro Hara.
6701
6702         Patch 14 of 25 to update DOMException name to match the spec and Firefox.
6703
6704         Updated existing tests.
6705
6706         * dom/DOMCoreException.cpp:
6707
6708 2012-11-15  Tien-Ren Chen  <trchen@chromium.org>
6709
6710         Add Settings to disable custom scrollbars on main frame
6711         https://bugs.webkit.org/show_bug.cgi?id=102323
6712
6713         Reviewed by Adam Barth.
6714
6715         Custom scrollbars on main frame don't really work well on touch devices.
6716         Add a setting to inhibit their creation.
6717
6718         No new tests. No change in default layout behavior.
6719
6720         * page/FrameView.cpp:
6721         (WebCore::FrameView::createScrollbar):
6722         * page/Settings.in:
6723
6724 2012-11-15  Rick Byers  <rbyers@chromium.org>
6725
6726         custom CSS cursors ignore hotspot values embedded in CUR files
6727         https://bugs.webkit.org/show_bug.cgi?id=100059
6728
6729         Reviewed by Kenneth Russell.
6730
6731         Add reading the hotspot values to the ICOImageDecoder (for CUR files only),
6732         and plumb it through so that the existing calls to ImageSource::getHotSpot
6733         actually return the hot spot value when there is one.
6734
6735         Tests: fast/events/mouse-cursor.html, fast/events/mouse-cursor-multiframecur.html
6736
6737         * platform/graphics/ImageSource.cpp:
6738         (WebCore::ImageSource::getHotSpot):
6739         * platform/graphics/chromium/DeferredImageDecoder.cpp:
6740         (WebCore::DeferredImageDecoder::hotSpot):
6741         (WebCore::DeferredImageDecoder::hotSpotAtIndex):
6742         * platform/graphics/chromium/DeferredImageDecoder.h:
6743         (DeferredImageDecoder):
6744         * platform/image-decoders/ImageDecoder.h:
6745         (WebCore::ImageDecoder::hotSpot):
6746         (WebCore::ImageDecoder::hotSpotAtIndex):
6747         (ImageDecoder):
6748         * platform/image-decoders/ico/ICOImageDecoder.cpp:
6749         (WebCore::ICOImageDecoder::hotSpot):
6750         (WebCore::ICOImageDecoder::hotSpotAtIndex):
6751         (WebCore::ICOImageDecoder::processDirectory):
6752         (WebCore::ICOImageDecoder::readDirectoryEntry):
6753         * platform/image-decoders/ico/ICOImageDecoder.h:
6754         (ICOImageDecoder):
6755         (IconDirectoryEntry):
6756
6757 2012-11-15  Kenichi Ishibashi  <bashi@chromium.org>
6758
6759         Make OpenTypeVerticalData be ref-counted
6760         https://bugs.webkit.org/show_bug.cgi?id=101971
6761
6762         Reviewed by Tony Chang.
6763
6764         FontCache::purgeInactiveFontData() uses mark & sweep algorithm to remove unused
6765         OpenTypeVerticalData objects. It marks only OpenTypeVerticalData which can be reached
6766         via SimpleFontData in gFontDataCache. However, OpenTypeVerticalData can be referred by
6767         SimpleFontData which resides in CSSFontFaceSource::m_fontDataTable so the algorithm can
6768         delete active OpenTypeVerticalData. To avoid deleting active OpenTypeVerticalData, make
6769         it be ref-counted.
6770
6771         No new tests. No changes in behavior. Checked manually that the use-after-free was fixed.
6772
6773         * platform/graphics/FontCache.cpp:
6774         (WebCore): Use RefPtr instead of OwnPtr for FontVerticalDataCache.
6775         (WebCore::FontCache::getVerticalData): Return PassRefPtr<OpenTypeVerticalData>.
6776         (WebCore::FontCache::purgeInactiveFontData): Follow the change of OwnPtr -> RefPtr.
6777         * platform/graphics/FontCache.h:
6778         * platform/graphics/SimpleFontData.cpp:
6779         (WebCore::SimpleFontData::SimpleFontData):
6780         * platform/graphics/SimpleFontData.h:
6781         Use RefPtr instead of raw const pointer for OpenTypeVerticalData.
6782         (WebCore::SimpleFontData::verticalData):
6783         * platform/graphics/chromium/FontPlatformDataChromiumWin.cpp:
6784         (WebCore::FontPlatformData::verticalData): Return PassRefPtr<OpenTypeVerticalData>.
6785         * platform/graphics/chromium/FontPlatformDataChromiumWin.h:
6786         (FontPlatformData):
6787         * platform/graphics/harfbuzz/FontPlatformDataHarfBuzz.cpp:
6788         (WebCore::FontPlatformData::verticalData): Ditto.
6789         * platform/graphics/harfbuzz/FontPlatformDataHarfBuzz.h:
6790         (WebCore):
6791         (FontPlatformData):
6792         * platform/graphics/opentype/OpenTypeVerticalData.h:
6793         (WebCore::OpenTypeVerticalData::create): Added.
6794         (OpenTypeVerticalData):
6795
6796 2012-11-15  Xingnan Wang  <xingnan.wang@intel.com>
6797
6798         Optimize the multiply-add in Biquad.cpp::process
6799         https://bugs.webkit.org/show_bug.cgi?id=75528
6800
6801         Reviewed by Brent Fulgham.
6802
6803         Pipeline the multiply-add with SSE2 intrinsics.
6804         Get ~45% performance improvement for the function.
6805
6806         * platform/audio/Biquad.cpp:
6807         (WebCore::Biquad::process):
6808
6809 2012-11-15  Alec Flett  <alecflett@chromium.org>
6810
6811         Add tests for explicit serialization values
6812         https://bugs.webkit.org/show_bug.cgi?id=96818
6813
6814         Reviewed by Adam Barth.
6815
6816         Expose direct access to the serialization/deserialization mechanisms
6817         of SerializedScriptValue to DumpRenderTree.
6818
6819         * testing/Internals.cpp:
6820         (WebCore::Internals::serializeObject):
6821         (WebCore):
6822         (WebCore::Internals::deserializeBuffer):
6823         * testing/Internals.h:
6824         (WebCore):
6825         * testing/Internals.idl:
6826
6827 2012-11-15  Gustavo Noronha Silva  <gns@gnome.org>
6828
6829         [GTK] Split WebCore/platform into a separate library
6830         https://bugs.webkit.org/show_bug.cgi?id=94435
6831
6832         Reviewed by Martin Robinson.
6833
6834         More people have been reporting problems when linking WebCore because
6835         the command line limit is being exceeded. Splitting WebCore a bit more
6836         is in order.
6837
6838         * GNUmakefile.am: add new libWebCorePlatform convenience library.
6839         * GNUmakefile.list.am: move list of platform/* files to its own variable.
6840
6841 2012-11-15  Luke Macpherson   <macpherson@chromium.org>
6842
6843         Remove unused macro HANDLE_INHERIT_AND_INITIAL_WITH_VALUE in StyleResolver.cpp
6844         https://bugs.webkit.org/show_bug.cgi?id=102036
6845
6846         Reviewed by Darin Adler.
6847
6848         Remove HANDLE_INHERIT_AND_INITIAL_WITH_VALUE macro, as it is not used anywhere.
6849
6850         No tests added because code is unused, and compile is enough to verify that conculsively.
6851
6852         * css/StyleResolver.cpp:
6853
6854 2012-11-15  Erik Arvidsson  <arv@chromium.org>
6855
6856         Update DOMException name: SyntaxError
6857         https://bugs.webkit.org/show_bug.cgi?id=102279
6858
6859         Reviewed by Kentaro Hara.
6860
6861         Patch 12 of 25 to update DOMException name to match the spec and Firefox.
6862
6863         Updated existing tests.
6864
6865         * dom/DOMCoreException.cpp:
6866
6867 2012-11-15  Takashi Sakamoto  <tasak@google.com>
6868
6869         [Win] key event's location does not work on Windows platform.
6870         https://bugs.webkit.org/show_bug.cgi?id=89742
6871
6872         Reviewed by Brent Fulgham.
6873
6874         As WM_KEYDOWN, WM_KEYUP, WM_SYSKEYDOWN, and WM_SYSKEYUP doesn't
6875         directly provide a virtual keycode which distinguish between left-hand
6876         and right-hand keys. To obtain a virtual keycode, we have to look at
6877         lparam, i.e. scancode and extended key bit. So if the given virtual
6878         keycode is control, shift, or menu, use MapVirtualKey with scancode and
6879         extended key bit and recreate a virtual keycode which distinguishes
6880         between left-hand and right-hand.
6881
6882         No new tests, because left-hand keys, right-hand keys layout tests
6883         have been already added.
6884
6885         * platform/win/KeyEventWin.cpp:
6886         (WebCore::windowsKeycodeWithLocation):
6887         Use wparam and lparam to recreate a virtual keycode which distinguishes
6888         between left-hand and right-hand if the given wparam (=virtual keycode)
6889         is control, shift, or menu.
6890         (WebCore):
6891         (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
6892         Use the newly added function to obtain windows virtual keycode.
6893
6894 2012-11-15  Joe Mason  <jmason@rim.com>
6895
6896         [BlackBerry] Don't assert when notifyAuthReceived is called with a different auth type
6897         https://bugs.webkit.org/show_bug.cgi?id=102436
6898
6899         Reviewed by Rob Buis.
6900
6901         The server type could change if we contact a site taking HTTP auth, through an HTTP proxy
6902         taking auth of its own. First we get a 407 from the proxy, and then when get past the
6903         proxy, we get a 401 from the end site - so notifyAuthReceived gets called again with auth
6904         type Proxy instead of HTTP.
6905
6906         The correct thing to do when that happens is skip the "update the auth type in the
6907         credentials" step, since these are actually new credentials and not just credentials being
6908         reused for a different auth type on the same server.
6909
6910         PR 241637
6911
6912         * platform/network/blackberry/NetworkJob.cpp:
6913         (WebCore::NetworkJob::notifyAuthReceived):
6914
6915 2012-11-15  Stephen Chenney  <schenney@chromium.org>
6916
6917         mpath elements do not clear resource lists before destruction
6918         https://bugs.webkit.org/show_bug.cgi?id=101505
6919
6920         Reviewed by Abhishek Arya.
6921
6922         The destructor for SVGMPathElement should clear its resources before
6923         deletion, so as not to leave hanging pointers in resource lists.
6924
6925         Test: svg/animations/mpath-remove-from-dependents-on-delete-crash.html
6926
6927         * svg/SVGMPathElement.cpp:
6928         (WebCore::SVGMPathElement::~SVGMPathElement): Add destructor that calls clearResourceReferences.
6929         (WebCore):
6930         * svg/SVGMPathElement.h:
6931         (SVGMPathElement): Add destructor.
6932
6933 2012-11-15  Kentaro Hara  <haraken@chromium.org>
6934
6935         Remove CodeGenerator::StripModule
6936         https://bugs.webkit.org/show_bug.cgi?id=102338
6937
6938         Reviewed by Adam Barth.
6939
6940         Now WebKit IDL files have no modules. (The Web IDL spec has no modules.)
6941         We can remove CodeGenerator::StripModule.
6942         This might break some internal builds if the internal builds are still
6943         using modules. Ping haraken@ you observe it.
6944
6945         No tests. No change in behavior.
6946
6947         * bindings/scripts/CodeGenerator.pm:
6948         (ForAllParents):
6949         (AttributeNameForGetterAndSetter):
6950         (IsStrictSubtype):
6951         * bindings/scripts/CodeGeneratorCPP.pm:
6952         (GetClassName):
6953         (GetImplClassName):
6954         (GetParentImplClassName):
6955         (GetParent):
6956         (ConversionNeeded):
6957         (GetCPPTypeGetter):
6958         (AddForwardDeclarationsForType):
6959         (AddIncludesForType):
6960         (GenerateImplementation):
6961         * bindings/scripts/CodeGeneratorGObject.pm:
6962         (GetParentClassName):
6963         (GetParentGObjType):
6964         (GetClassName):
6965         * bindings/scripts/CodeGeneratorJS.pm:
6966         (GetParentClassName):
6967         (AddIncludesForTypeInImpl):
6968         (AddIncludesForTypeInHeader):
6969         (GenerateParametersCheckExpression):
6970         (GenerateImplementation):
6971         (GenerateParametersCheck):
6972         (GetNativeTypeFromSignature):
6973         (JSValueToNative):
6974         (NativeToJSValue):
6975         * bindings/scripts/CodeGeneratorObjC.pm:
6976         (GetClassName):
6977         (GetImplClassName):
6978         (GetParentImplClassName):
6979         (GetParentAndProtocols):
6980         (GetPropertyAttributes):
6981         (ConversionNeeded):
6982         (GetObjCTypeGetter):
6983         (AddForwardDeclarationsForType):
6984         (AddIncludesForType):
6985         (GenerateImplementation):
6986         * bindings/scripts/CodeGeneratorV8.pm:
6987         (AddIncludesForType):
6988         (GenerateHeader):
6989         (IsSubType):
6990         (GenerateSingleBatchedAttribute):
6991         (GenerateImplementation):
6992         (BaseInterfaceName):
6993         (GetTypeFromSignature):
6994         (IsWrapperType):
6995
6996 2012-11-15  Luke Macpherson   <macpherson@chromium.org>
6997
6998         Make assumptions about m_parentStyle consistent within StyleResolver::applyProperty()
6999         https://bugs.webkit.org/show_bug.cgi?id=101696
7000
7001         Reviewed by Tony Chang.
7002
7003         Most of the code in StyleResolver::applyProperty assumes that isInherit implies that m_parentStyle is available.
7004         This patch ASSERTs that this assumption is correct, and removes the few existing checks to maintain consistency.
7005
7006         No new tests / covered by all existing CSS tests.
7007
7008         * css/StyleResolver.cpp:
7009         (WebCore::StyleResolver::applyProperty):
7010
7011 2012-11-15  Kentaro Hara  <haraken@chromium.org>
7012
7013         [V8] Remove redundant $interfaceName from function parameters
7014         https://bugs.webkit.org/show_bug.cgi?id=102334
7015
7016         Reviewed by Adam Barth.
7017
7018         'sub func { my $dataNode = shift; my $interfaceName = shift; }'
7019         is redundant. We can get $interfaceName by $dataNode->name.
7020
7021         No tests. No change in behavior.
7022
7023         * bindings/scripts/CodeGeneratorV8.pm:
7024         (GenerateOpaqueRootForGC):
7025         (GenerateHeader):
7026         (GenerateConstructorGetter):
7027         (GenerateNormalAttrGetter):
7028         (GenerateReplaceableAttrSetter):
7029         (GenerateNormalAttrSetter):
7030         (GenerateOverloadedFunctionCallback):
7031         (GenerateFunctionCallback):
7032         (GenerateOverloadedConstructorCallback):
7033         (GenerateSingleConstructorCallback):
7034         (GenerateConstructorCallback):
7035         (GenerateEventConstructorCallback):
7036         (GenerateTypedArrayConstructorCallback):
7037         (GenerateNamedConstructorCallback):
7038         (GenerateBatchedAttributeData):
7039         (GenerateImplementation):
7040         (GenerateToV8Converters):
7041         (GetNativeTypeForConversions):
7042
7043 2012-11-15  Simon Fraser  <simon.fraser@apple.com>
7044
7045         Ensure that scrollbar layers show debug borders
7046         https://bugs.webkit.org/show_bug.cgi?id=102429
7047
7048         Reviewed by Anders Carlsson.
7049
7050         After r133517, scrollbar layers no longer showed debug borders, which
7051         was very confusing. Fix this by explicitly calling setShowDebugBorder()
7052         on the scrollbar-related layers owned by RenderLayerCompositor
7053         and RenderLayerBacking.
7054         
7055         * rendering/RenderLayerBacking.cpp:
7056         (WebCore::RenderLayerBacking::updateDebugIndicators):
7057         * rendering/RenderLayerCompositor.cpp:
7058         (WebCore::RenderLayerCompositor::cacheAcceleratedCompositingFlags):
7059         (WebCore::RenderLayerCompositor::updateOverflowControlsLayers):
7060
7061 2012-11-15  Andreas Kling  <akling@apple.com>
7062
7063         ASSERTION FAILED: fastAttributeLookupAllowed(name) for 7 layout tests
7064         <http://webkit.org/b/102423>
7065
7066         Reviewed by Anders Carlsson.
7067
7068         Use Element::getAttributeItem() to find out if the element has a given attribute
7069         instead of fastHasAttribute() since that causes assertions for the "style" attribute.
7070
7071         * html/parser/HTMLConstructionSite.cpp:
7072         (WebCore::HTMLConstructionSite::mergeAttributesFromTokenIntoElement):
7073
7074 2012-11-15  Erik Arvidsson  <arv@chromium.org>
7075
7076         Update DOMException name: DOMStringSizeError
7077         https://bugs.webkit.org/show_bug.cgi?id=102089
7078
7079         Reviewed by Ojan Vafai.
7080
7081         Patch 2 of 25 to update DOMException name to match the spec and Firefox.
7082
7083         DOMSTRING_SIZE_ERR is historical and not used in any spec or in our code.
7084
7085         * dom/DOMCoreException.cpp:
7086         * dom/ExceptionCode.h:
7087
7088 2012-11-15  Joshua Bell  <jsbell@chromium.org>
7089
7090         IndexedDB: Indexing tests are flaky-crashing
7091         https://bugs.webkit.org/show_bug.cgi?id=102283
7092
7093         Reviewed by Tony Chang.
7094
7095         Processing the final task can cause IDBTransactionBackendImpl references to be released
7096         by all holders. Prior to looping over the tasks (or, in an even earlier implementation,
7097         swapping queues) control would fall off the end of the function. The loop termination
7098         check introduced in http://wkrev.com/134529 requires that |this| be kept alive until
7099         the method completes.
7100
7101         Test: storage/indexeddb/transaction-crash-in-tasks.html
7102
7103         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
7104         (WebCore::IDBTransactionBackendImpl::abort): Rename self => protect.
7105         (WebCore::IDBTransactionBackendImpl::commit): Rename self => protect.
7106         (WebCore::IDBTransactionBackendImpl::taskTimerFired): New self-ref.
7107
7108 2012-11-15  Elliott Sprehn  <esprehn@chromium.org>
7109
7110         MutationObserver wrapper should not be collected while still observing
7111         https://bugs.webkit.org/show_bug.cgi?id=102328
7112
7113         Reviewed by Adam Barth.
7114
7115         Make MutationObserver an ActiveDOMObject so that the wrapper is not
7116         collected while it is still observing the DOM. This is needed because
7117         the wrapper is passed into the callback and expandos on the wrapper
7118         should be preserved.
7119
7120         Test: fast/mutation/observer-wrapper-dropoff.html
7121
7122         * bindings/js/JSMutationObserverCustom.cpp:
7123         (WebCore::JSMutationObserverConstructor::constructJSMutationObserver):
7124         * bindings/v8/custom/V8MutationObserverCustom.cpp:
7125         (WebCore::V8MutationObserver::constructorCallback):
7126         * dom/MutationObserver.cpp:
7127         (WebCore::MutationObserver::create):
7128         (WebCore::MutationObserver::MutationObserver):
7129         (WebCore::MutationObserver::observationStarted):
7130         (WebCore::MutationObserver::observationEnded):
7131         * dom/MutationObserver.h:
7132         (WebCore):
7133         * dom/MutationObserver.idl:
7134
7135 2012-11-15  Tony Chang  <tony@chromium.org>
7136
7137         Generate Settings from a .in file
7138         https://bugs.webkit.org/show_bug.cgi?id=100393
7139
7140         Reviewed by Adam Barth.
7141
7142         Generate most settings from an .in file to reduce human mistakes and
7143         to make it easier to add/remove new settings.
7144
7145         I only moved settings that are easy to move at this point.  There are many more that
7146         have some minor naming inconsistencies that we can also move to Settings.in, but I'll
7147         do that in a follow up patch.
7148
7149         This doesn't generate SettingInternals.* yet-- we can do that in a follow up patch.
7150
7151         No new tests, this is a refactor.
7152
7153         * CMakeLists.txt:
7154         * DerivedSources.make: Run make_settings.pl.
7155         * DerivedSources.pri: Run make_settings.pl.
7156         * GNUmakefile.am: Run make_settings.pl.
7157         * GNUmakefile.list.am:
7158         * WebCore.exp.in: Remove functions that are now inline in the header.
7159         * WebCore.gyp/WebCore.gyp: Run action_makenames.py, which will run make_settings.pl.
7160         * WebCore.gyp/scripts/action_makenames.py:
7161         (main): Allow make_settings.pl.
7162         * WebCore.order: Remove functions that are now inline in the header.
7163         * html/ValidationMessage.cpp:
7164         (WebCore::ValidationMessage::setMessageDOMAndStartTimer): Fix a typo in "magnification".
7165         * page/Settings.cpp:
7166         (WebCore::Settings::Settings): Replace generated settings with SETTINGS_INITIALIZER_LIST.
7167         * page/Settings.h:
7168         (Settings): Replace generated settings with SETTINGS_GETTERS_AND_SETTERS and SETTINGS_MEMBER_VARIABLES.
7169         * page/Settings.in: Added.
7170         * page/make_settings.pl: Added.
7171         (defaultItemFactory):
7172         (generateCode):
7173         (generateHeader): Use a similar model as make_names.pl.
7174         (printConditionalMacros):
7175         (printGettersAndSetters):
7176         (printMemberVariables):
7177         (printGetterAndSetter):
7178         (printInitializerList):
7179         (printInitializer):
7180
7181 2012-11-15  Alpha Lam  <hclam@chromium.org>
7182
7183         [chromium] Refactoring to move logic of creating lazy decoded SkBitmap into DeferredImageDecoder
7184         https://bugs.webkit.org/show_bug.cgi?id=102019
7185
7186         Reviewed by Stephen White.
7187
7188         Goal of this change is to keep ImageDecodingStore clean and only do
7189         image caching. Logic of creating lazily decoded SkBitmaps is moved into
7190         DeferredImageDecoder.
7191
7192         In particular these two methods are moved:
7193         - ImageDecodingStore::createLazyDecodedSkBitmap
7194         - ImageDecodingStore::resizeLazyDecodedSkBitmap
7195
7196         No new tests. There is no new code (really). It is just moved from
7197         ImageDecodingStore to DeferredImageDecoder.
7198
7199         No change in behavior. Code is tested with:
7200         Unit tests: webkit_unit_tests
7201         Layout test: platform/chromium/virtual/deferred
7202
7203         * platform/graphics/chromium/DeferredImageDecoder.cpp:
7204         (WebCore::DeferredImageDecoder::isLazyDecoded):
7205         (WebCore):
7206         (WebCore::DeferredImageDecoder::resizeLazyDecodedSkBitmap):
7207         (WebCore::DeferredImageDecoder::frameBufferAtIndex):
7208         (WebCore::DeferredImageDecoder::setData):
7209         (WebCore::DeferredImageDecoder::createLazyDecodedSkBitmap):
7210         * platform/graphics/chromium/DeferredImageDecoder.h:
7211         (WebCore):
7212         (DeferredImageDecoder):
7213         * platform/graphics/chromium/ImageDecodingStore.cpp:
7214         * platform/graphics/chromium/ImageDecodingStore.h:
7215         (ImageDecodingStore):
7216         * platform/graphics/chromium/ImageFrameGenerator.cpp:
7217         (WebCore::ImageFrameGenerator::ImageFrameGenerator):
7218         * platform/graphics/chromium/ImageFrameGenerator.h:
7219         (WebCore::ImageFrameGenerator::create):
7220         (ImageFrameGenerator):
7221         * platform/graphics/skia/NativeImageSkia.cpp:
7222         (WebCore::NativeImageSkia::resizedBitmap):
7223
7224 2012-11-15  Roger Fong  <roger_fong@apple.com>
7225
7226         Unreviewed. Build fix for Windows after r134767.
7227
7228         Update vsprops and vcproj files to reflect changes to file locations in r134767.
7229
7230         * WebCore.vcproj/WebCore.vcproj:
7231         * WebCore.vcproj/WebCoreCommon.vsprops:
7232
7233 2012-11-15  Elliott Sprehn  <esprehn@chromium.org>
7234
7235         Track subframe count to avoid traversing the tree when there's no subframes
7236         https://bugs.webkit.org/show_bug.cgi?id=101821
7237
7238         Reviewed by Ojan Vafai.
7239
7240         Bug 101619 showed a 9-14% improvement from not walking the children during
7241         removeChild looking for frames when there's known to be no frames. The fix
7242         in that bug only avoids this walk when the whole document has no frames, this
7243         patch extends it to skip traversing subtrees that have no iframes by hooking
7244         the frame assignment to walk up the tree and keep track of the count of frames
7245         in the subtree on contentFrame assignment and then decrement it on disconnect.
7246
7247         No new tests, this is just a perf refactor.
7248
7249         * dom/ContainerNode.cpp:
7250         (WebCore::willRemoveChildren):
7251         * dom/ContainerNodeAlgorithms.cpp:
7252         (WebCore::ChildFrameDisconnector::collectFrameOwners):
7253         * dom/ContainerNodeAlgorithms.h:
7254         (WebCore::ChildFrameDisconnector::ChildFrameDisconnector):
7255         (ChildFrameDisconnector):
7256         (WebCore::ChildFrameDisconnector::collectFrameOwners):
7257           Renamed from collectDescendant() to better reflect what it really does.
7258         (WebCore::ChildFrameDisconnector::disconnectCollectedFrameOwners):
7259           Renamed from disconnect() to better reflect what it really does.
7260         (WebCore::ChildFrameDisconnector::disconnect):
7261           New method that does the collection of frame owners on either the root
7262           or only it's descendants.
7263         * dom/Node.cpp:
7264         (WebCore::Node::connectedSubframeCount):
7265         (WebCore::Node::incrementConnectedSubframeCount):
7266         (WebCore::Node::decrementConnectedSubframeCount):
7267         * dom/Node.h:
7268         * dom/NodeRareData.h:
7269         (WebCore::NodeRareData::NodeRareData):
7270         (WebCore::NodeRareData::connectedSubframeCount):
7271         (WebCore::NodeRareData::incrementConnectedSubframeCount):
7272         (WebCore::NodeRareData::decrementConnectedSubframeCount):
7273         * html/HTMLFrameOwnerElement.cpp:
7274         (WebCore::HTMLFrameOwnerElement::setContentFrame):
7275         (WebCore::HTMLFrameOwnerElement::disconnectContentFrame):
7276
7277 2012-11-15  Alpha Lam  <hclam@chromium.org>
7278
7279         [chromium] WebGL texImage2D fails with deferred image decoding
7280         https://bugs.webkit.org/show_bug.cgi?id=102310
7281
7282         Reviewed by Kenneth Russell.
7283
7284         Skia's implementation of GraphicsContext3D::getImageData() uses ImageSource
7285         to decode an image. When deferred image decoding is enabled this class
7286         generates an ImageFrame marked as incomplete, which WebGL rejects. This results
7287         in failing of texImage2D.
7288
7289         This change uses ImageDecoder directly instead of ImageSource. This skips
7290         the code path of deferred image decoding. This behavior is correct because
7291         GraphicsContext3D wants to decode the image differently with alpha not
7292         premultiplied and color profile applied optionally.
7293
7294         Added a test to prove this change fixed the bug.
7295
7296         Test: fast/images/webgl-teximage2d.html
7297
7298         * platform/graphics/skia/GraphicsContext3DSkia.cpp:
7299         (WebCore::GraphicsContext3D::getImageData):
7300
7301 2012-11-15  Jer Noble  <jer.noble@apple.com>
7302
7303         Further unreviewed build fix. Add explicit static_casts to avoid implicit precision warnings.
7304
7305         * platform/graphics/avfoundation/objc/WebCoreAVFResourceLoader.mm:
7306         (WebCore::WebCoreAVFResourceLoader::fulfillRequestWithResource):
7307
7308 2012-11-15  Jer Noble  <jer.noble@apple.com>
7309
7310         Unreviewed build fix. Avoid implicit precision and unused parameter warnings.
7311
7312         * platform/graphics/avfoundation/objc/WebCoreAVFResourceLoader.mm:
7313         (WebCore::WebCoreAVFResourceLoader::responseReceived):
7314         (WebCore::WebCoreAVFResourceLoader::fulfillRequestWithResource):
7315
7316 2012-11-15  Adam Barth  <abarth@webkit.org>
7317
7318         [V8] We shouldn't call deprecated V8 APIs
7319         https://bugs.webkit.org/show_bug.cgi?id=102407
7320
7321         Reviewed by Eric Seidel.
7322
7323         This patch was written by Sven Panne on the V8 team. He would prefer
7324         that we not call deprecated V8 APIs. This patch updates these call
7325         sites to more modern idioms.
7326
7327         * bindings/scripts/CodeGeneratorV8.pm:
7328         (GenerateConstructorGetter):
7329         (GenerateImplementation):
7330         * bindings/scripts/test/V8/V8TestObj.cpp:
7331         (WebCore::TestObjV8Internal::TestObjConstructorGetter):
7332         * bindings/v8/PageScriptDebugServer.cpp:
7333         (WebCore::PageScriptDebugServer::addListener):
7334         * bindings/v8/ScriptController.cpp:
7335         (WebCore::ScriptController::setContextDebugId):
7336         (WebCore::ScriptController::contextDebugId):
7337         * bindings/v8/ScriptProfiler.cpp:
7338         (WebCore::ScriptProfiler::objectByHeapObjectId):
7339             - This code doesn't seem to do anything anymore.
7340         * bindings/v8/V8DOMConfiguration.h:
7341         (WebCore::V8DOMConfiguration::configureAttribute):
7342         * bindings/v8/V8DOMWindowShell.cpp:
7343         (WebCore::setInjectedScriptContextDebugId):
7344         * bindings/v8/V8DOMWrapper.cpp:
7345         (WebCore::V8DOMWrapper::maybeDOMWrapper):
7346         (WebCore::V8DOMWrapper::isWrapperOfType):
7347         * bindings/v8/V8EventListenerList.h:
7348         (WebCore::V8EventListenerList::doFindWrapper):
7349         (WebCore::V8EventListenerList::findOrCreateWrapper):
7350         * bindings/v8/WorkerContextExecutionProxy.cpp:
7351         (WebCore::WorkerContextExecutionProxy::initializeIfNeeded):
7352         * bindings/v8/WrapperTypeInfo.h:
7353         (WebCore::WrapperTypeInfo::unwrap):
7354
7355 2012-11-15  Sheriff Bot  <webkit.review.bot@gmail.com>
7356
7357         Unreviewed, rolling out r134800 and r134805.
7358         http://trac.webkit.org/changeset/134800
7359         http://trac.webkit.org/changeset/134805
7360         https://bugs.webkit.org/show_bug.cgi?id=102417
7361
7362         This patch broke chromium port (Requested by jianli on
7363         #webkit).
7364
7365         * Modules/mediastream/RTCPeerConnection.cpp:
7366         (WebCore::RTCPeerConnection::RTCPeerConnection):
7367         (WebCore::RTCPeerConnection::createOffer):
7368         (WebCore::RTCPeerConnection::createAnswer):
7369         (WebCore::RTCPeerConnection::setLocalDescription):
7370         (WebCore::RTCPeerConnection::localDescription):
7371         (WebCore::RTCPeerConnection::setRemoteDescription):
7372         (WebCore::RTCPeerConnection::remoteDescription):
7373         (WebCore::RTCPeerConnection::updateIce):
7374         (WebCore::RTCPeerConnection::addIceCandidate):
7375         (WebCore::RTCPeerConnection::readyState):
7376         (WebCore::RTCPeerConnection::iceState):
7377         (WebCore::RTCPeerConnection::addStream):
7378         (WebCore::RTCPeerConnection::close):
7379         (WebCore::RTCPeerConnection::stop):
7380         (WebCore::RTCPeerConnection::changeReadyState):
7381         (WebCore::RTCPeerConnection::scheduledEventTimerFired):
7382         * Modules/mediastream/RTCPeerConnection.h:
7383         (RTCPeerConnection):
7384         * Modules/mediastream/RTCPeerConnection.idl:
7385         * dom/EventNames.h:
7386         (WebCore):
7387         * platform/mediastream/RTCDataChannelDescriptor.cpp:
7388         (WebCore::RTCDataChannelDescriptor::RTCDataChannelDescriptor):
7389         (WebCore::RTCDataChannelDescriptor::readyStateChanged):
7390         * platform/mediastream/RTCPeerConnectionHandlerClient.h:
7391         (RTCPeerConnectionHandlerClient):
7392         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp:
7393         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h:
7394         (RTCPeerConnectionHandlerChromium):
7395
7396 2012-11-15  Elliott Sprehn  <esprehn@chromium.org>
7397
7398         Remove Node::aboutToUnload and be more explicit about what it was for
7399         https://bugs.webkit.org/show_bug.cgi?id=102357
7400
7401         Reviewed by Ryosuke Niwa.
7402
7403         Node::aboutToUnload was confusingly named because it was only called on
7404         the focused node, and it really only existed to support notifying the
7405         embedder that inputs should stop being editable on unload. Instead add
7406         a new method to HTMLInputElement that ends editing and call that
7407         explicitly in the FrameLoader so it's clear what this is about.
7408
7409         No new tests, this is just a refactoring.
7410
7411         * dom/Node.h:
7412         * html/HTMLInputElement.cpp:
7413         (WebCore::HTMLInputElement::endEditing):
7414             New method that handles finishing editing.
7415         * html/HTMLInputElement.h:
7416         (HTMLInputElement):
7417         * html/TextFieldInputType.cpp:
7418         (WebCore::TextFieldInputType::handleBlurEvent):
7419             Use the new method to reduce code duplication.
7420         * loader/FrameLoader.cpp:
7421         (WebCore::FrameLoader::stopLoading):
7422             Be explicit about what this check was for.
7423
7424 2012-11-15  Tommy Widenflycht  <tommyw@google.com>
7425
7426         [chromium] MediaStream API: Add missing WebRTCPeerConnectionHandlerClient::didAddRemoteDataChannel
7427         https://bugs.webkit.org/show_bug.cgi?id=102386
7428
7429         Reviewed by Adam Barth.
7430
7431         Existing tests expanded to cover patch.
7432
7433         * platform/mediastream/RTCDataChannelDescriptor.cpp:
7434         (WebCore::RTCDataChannelDescriptor::RTCDataChannelDescriptor):
7435         (WebCore::RTCDataChannelDescriptor::readyStateChanged):
7436         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp:
7437         (WebCore::RTCPeerConnectionHandlerChromium::didAddRemoteDataChannel):
7438         (WebCore):
7439         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h:
7440         (WebKit):
7441         (RTCPeerConnectionHandlerChromium):
7442
7443 2012-11-15  Rick Byers  <rbyers@chromium.org>
7444
7445         No tests for changing mouse cursors
7446         https://bugs.webkit.org/show_bug.cgi?id=100550
7447
7448         Reviewed by Brent Fulgham.
7449
7450         Add infrastructure to keep track of the last set mouse cursor,
7451         and then to query it from DumpRenderTree.  Also adds ASSERTs to help ensure
7452         we can reliably detect when an uninitialized Cursor object is used (such as
7453         the one that can be returned from OptionalCursor in the NoCursorChange scenario).
7454
7455         Test: fast/events/mouse-cursor.html
7456
7457         * WebCore.exp.in: Add Cursor copy ctor export
7458         * page/EventHandler.cpp:
7459         (WebCore::OptionalCursor::cursor):
7460         (WebCore::EventHandler::handleMouseMoveEvent): Keep track of last set mouse cursor
7461         * page/EventHandler.h:
7462         (WebCore::EventHandler::currentMouseCursor): New getter for last set mouse cursor
7463         * platform/Cursor.h:
7464         (WebCore::Cursor::Cursor): Mark uninitialized cursor types as invalid.
7465         (WebCore::Cursor::type): Assert cursor type is valid.
7466         * testing/Internals.cpp:
7467         (WebCore::cursorTypeToString): Helper to convert cursor type to enum
7468         (WebCore):
7469         (WebCore::Internals::getCurrentCursorInfo): New function to return a string describing the last set mouse cursor
7470         * testing/Internals.h: Declare getCurrentCursorInfo
7471         * testing/Internals.idl: Declare getCurrentCursorInfo
7472
7473 2012-11-13  Jer Noble  <jer.noble@apple.com>
7474
7475         Support loading of blob URLs in AVFoundation.
7476         https://bugs.webkit.org/show_bug.cgi?id=102182
7477
7478         Reviewed by Eric Carlson.
7479
7480         Add support for BLOB (and other non-natively supported schemed) URLs through the AVAssetResourceLoader API.
7481
7482         Test: media/video-src-blob.html
7483
7484         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
7485         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
7486         (WebCore::MediaPlayerPrivateAVFoundationObjC::shouldWaitForLoadingOfResource): Only go down the encrypted
7487             media path if the key scheme is skp://.
7488         (WebCore::MediaPlayerPrivateAVFoundationObjC::didCancelLoadingRequest): Added.  Cancel resource loading if
7489             the media engine requests it.
7490         (WebCore::MediaPlayerPrivateAVFoundationObjC::addKey): Use the new, non-deprecated API.
7491         
7492         Use the dispatch_main_queue() as the AVAssetResourceLoadDelegate queue now that <rdar://problem/12362461> is fixed.
7493         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
7494         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL):
7495         (-[WebCoreAVFLoaderDelegate resourceLoader:shouldWaitForLoadingOfRequestedResource:]):
7496         (-[WebCoreAVFLoaderDelegate resourceLoader:didCancelLoadingRequest:]):
7497
7498         Add a new helper class to manage loading the CachedRawResource and feed the incoming
7499         data to the AVAssetResourceLoader.
7500         * platform/graphics/avfoundation/objc/WebCoreAVFResourceLoader.h: Added.
7501         * platform/graphics/avfoundation/objc/WebCoreAVFResourceLoader.mm: Added.
7502         (WebCore::WebCoreAVFResourceLoader::create): Simple factory.
7503         (WebCore::WebCoreAVFResourceLoader::WebCoreAVFResourceLoader): Simple constructor.
7504         (WebCore::WebCoreAVFResourceLoader::~WebCoreAVFResourceLoader): Simple destructor.
7505         (WebCore::WebCoreAVFResourceLoader::startLoading): Tell the cachedResourceLoader to schedule loading.
7506         (WebCore::WebCoreAVFResourceLoader::stopLoading): Remove this as a client of the resource.
7507         (WebCore::WebCoreAVFResourceLoader::responseReceived): Fill in the contentInformation field of the 
7508             AVAssetResourceLoadingRequest.
7509         (WebCore::WebCoreAVFResourceLoader::dataReceived): Call fulfillRequestWithResource.
7510         (WebCore::WebCoreAVFResourceLoader::notifyFinished): Tell the AVAssetResourceLoadingRequest that loading
7511             has completed.
7512         (WebCore::WebCoreAVFResourceLoader::fulfillRequestWithResource): Fill in (if possible) the dataRequest
7513             field of the AVAssetResourceLoadingRequest.
7514
7515         Add a MediaPlayerClient method allowing MediaPlayerPrivate subclasses to access the HTMLMediaElement's
7516         document's cachedResourceLoader.
7517         * html/HTMLMediaElement.cpp:
7518         (WebCore::HTMLMediaElement::mediaPlayerCachedResourceLoader):
7519         * html/HTMLMediaElement.h:
7520         * platform/graphics/MediaPlayer.cpp:
7521         (WebCore::MediaPlayer::cachedResourceLoader):
7522         * platform/graphics/MediaPlayer.h:
7523         (WebCore::MediaPlayerClient::mediaPlayerCachedResourceLoader):
7524
7525         Add a convenience method to convert from MIME type -> UTI.
7526         * platform/network/mac/UTIUtilities.h:
7527         * platform/network/mac/UTIUtilities.mm:
7528         (WebCore::UTIFromMIMEType):
7529
7530         Add new files to project.
7531         * WebCore.xcodeproj/project.pbxproj:
7532
7533 2012-11-15  Kenneth Rohde Christiansen  <kenneth@webkit.org>
7534
7535         Remove initiallyFitToViewport attribute
7536         https://bugs.webkit.org/show_bug.cgi?id=102392
7537
7538         Reviewed by Noam Rosenthal.
7539
7540         Remove the initiallyFitToViewport which shouldn't have been
7541         added in the first place. We now reset userScalable to auto (-1)
7542         in case it was not explicitly set by the web author.
7543
7544         Same behavior, covered by existing tests.
7545
7546         * dom/ViewportArguments.cpp:
7547         (WebCore::ViewportArguments::resolve):
7548         * dom/ViewportArguments.h:
7549         (ViewportAttributes):
7550
7551 2012-11-15  Tommy Widenflycht  <tommyw@google.com>
7552
7553         MediaStream API: Update RTCPeerConnection states to match the latest editors draft
7554         https://bugs.webkit.org/show_bug.cgi?id=102382
7555
7556         Reviewed by Adam Barth.
7557
7558         Updating readyState & iceState, and adding iceGatheringState.
7559         Also safeguarding the event timer callback.
7560
7561         Patch covered by existing tests.
7562
7563         * Modules/mediastream/RTCPeerConnection.cpp:
7564         (WebCore::RTCPeerConnection::RTCPeerConnection):
7565         (WebCore::RTCPeerConnection::createOffer):
7566         (WebCore::RTCPeerConnection::createAnswer):
7567         (WebCore::RTCPeerConnection::setLocalDescription):
7568         (WebCore::RTCPeerConnection::localDescription):
7569         (WebCore::RTCPeerConnection::setRemoteDescription):
7570         (WebCore::RTCPeerConnection::remoteDescription):
7571         (WebCore::RTCPeerConnection::updateIce):
7572         (WebCore::RTCPeerConnection::addIceCandidate):
7573         (WebCore::RTCPeerConnection::readyState):
7574         (WebCore::RTCPeerConnection::iceGatheringState):
7575         (WebCore):
7576         (WebCore::RTCPeerConnection::iceState):
7577         (WebCore::RTCPeerConnection::addStream):
7578         (WebCore::RTCPeerConnection::close):
7579         (WebCore::RTCPeerConnection::didChangeIceGatheringState):
7580         (WebCore::RTCPeerConnection::stop):
7581         (WebCore::RTCPeerConnection::changeReadyState):
7582         (WebCore::RTCPeerConnection::scheduledEventTimerFired):
7583         * Modules/mediastream/RTCPeerConnection.h:
7584         (RTCPeerConnection):
7585         * Modules/mediastream/RTCPeerConnection.idl:
7586         * dom/EventNames.h:
7587         (WebCore):
7588         * platform/mediastream/RTCPeerConnectionHandlerClient.h:
7589         (RTCPeerConnectionHandlerClient):
7590         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp:
7591         (WebCore::RTCPeerConnectionHandlerChromium::didChangeICEGatheringState):
7592         (WebCore):
7593         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h:
7594         (RTCPeerConnectionHandlerChromium):
7595
7596 2012-11-15  Sheriff Bot  <webkit.review.bot@gmail.com>
7597
7598         Unreviewed, rolling out r134649 and r134665.
7599         http://trac.webkit.org/changeset/134649
7600         http://trac.webkit.org/changeset/134665
7601         https://bugs.webkit.org/show_bug.cgi?id=102413
7602
7603         Broke a ton of downstream chromium tests (Requested by japhet
7604         on #webkit).
7605
7606         * loader/DocumentLoader.cpp:
7607         (WebCore::DocumentLoader::DocumentLoader):
7608         (WebCore::DocumentLoader::~DocumentLoader):
7609         (WebCore::DocumentLoader::finishedLoading):
7610         (WebCore::DocumentLoader::clearMainResourceLoader):
7611         (WebCore::DocumentLoader::isLoadingInAPISense):
7612         (WebCore::DocumentLoader::documentURL):
7613         (WebCore::DocumentLoader::isLoadingMainResource):
7614         (WebCore::DocumentLoader::startLoadingMainResource):
7615         * loader/DocumentLoader.h:
7616         (DocumentLoader):
7617         * loader/FrameLoader.cpp:
7618         (WebCore::FrameLoader::FrameLoader):
7619         (WebCore::FrameLoader::init):
7620         * loader/FrameLoaderStateMachine.cpp:
7621         (WebCore::FrameLoaderStateMachine::FrameLoaderStateMachine):
7622         * loader/FrameLoaderStateMachine.h:
7623         * loader/MainResourceLoader.cpp:
7624         (WebCore::shouldLoadAsEmptyDocument):
7625         (WebCore):
7626         (WebCore::MainResourceLoader::continueAfterContentPolicy):
7627         (WebCore::MainResourceLoader::didReceiveResponse):
7628         (WebCore::MainResourceLoader::didFinishLoading):
7629         (WebCore::MainResourceLoader::handleEmptyLoad):
7630         (WebCore::MainResourceLoader::loadNow):
7631         (WebCore::MainResourceLoader::load):
7632         * loader/MainResourceLoader.h:
7633         (MainResourceLoader):
7634
7635 2012-11-15  Kentaro Hara  <haraken@chromium.org>
7636
7637         Correct syntax of old-style IDL files
7638         https://bugs.webkit.org/show_bug.cgi?id=102335
7639
7640         Reviewed by Adam Barth.
7641
7642         Recently tasak@ corrected an IDL syntax of almost all IDL files.
7643         We should correct the rest of them.
7644
7645         No tests. No change in behavior.
7646
7647         * html/canvas/OESElementIndexUint.idl:
7648         * page/PerformanceMark.idl:
7649         * page/PerformanceMeasure.idl:
7650
7651 2012-11-15  Elliott Sprehn  <esprehn@chromium.org>
7652
7653         Remove isHTMLInputElement since it's unused and toInputElement exists 
7654         https://bugs.webkit.org/show_bug.cgi?id=102358
7655
7656         Reviewed by Ojan Vafai.
7657
7658         Remove isHTMLInputElement as no one uses it. Everyone just uses
7659         Node::toInputElement and checks for a 0 return value instead.
7660
7661         toInputElement is also more reliable as there's no requirement that
7662         subclasses of HTMLInputElement have the tag name of inputTag so using
7663         this method in a check could potentially miss future subclasses with
7664         different tag names, though none exist right now.
7665
7666         No new tests, this just deletes dead code.
7667
7668         * html/HTMLInputElement.h:
7669
7670 2012-11-15  Erik Arvidsson  <arv@chromium.org>
7671
7672         Update DOMException name: NotSupportedError
7673         https://bugs.webkit.org/show_bug.cgi?id=102139
7674
7675         Reviewed by Ojan Vafai.
7676
7677         Patch 9 of 25 to update DOMException name to match the spec and Firefox.
7678
7679         Updated existing tests.
7680
7681         * dom/DOMCoreException.cpp:
7682
7683 2012-11-15  Elliott Sprehn  <esprehn@chromium.org>
7684
7685         Remove isHTMLInputElement since it's unused and toInputElement exists 
7686         https://bugs.webkit.org/show_bug.cgi?id=102358
7687
7688         Reviewed by Ojan Vafai.
7689
7690         Remove isHTMLInputElement as no one uses it. Everyone just uses
7691         Node::toInputElement and checks for a 0 return value instead.
7692
7693         toInputElement is also more reliable as there's no requirement that
7694         subclasses of HTMLInputElement have the tag name of inputTag so using
7695         this method in a check could potentially miss future subclasses with
7696         different tag names, though none exist right now.
7697
7698         No new tests, this just deletes dead code.
7699
7700         * html/HTMLInputElement.h:
7701
7702 2012-11-15  Erik Arvidsson  <arv@chromium.org>
7703
7704         Update DOMException name: NoModificationAllowedError
7705         https://bugs.webkit.org/show_bug.cgi?id=102134
7706
7707         Reviewed by Ojan Vafai.
7708
7709         Patch 7 of 25 to update DOMException name to match the spec and Firefox.
7710
7711         Updated existing tests.
7712
7713         * dom/DOMCoreException.cpp:
7714
7715 2012-11-15  Miguel Garcia  <miguelg@chromium.org>
7716
7717         Remove unnecesary dependencies INPUT_TYPE_COLOR
7718         https://bugs.webkit.org/show_bug.cgi?id=102379
7719
7720         Reviewed by Darin Adler.
7721
7722         Platforms should be able to enable INPUT_TYPE_COLOR without enabling
7723         CALENDAR_PICKER and DATALIST_ELEMENT. Before this patch however there would be
7724         compile errors in such configuration.
7725
7726         No new tests since this is not adding any extra functionality.
7727
7728         * WebCore.gyp/WebCore.gyp:
7729         * html/ColorInputType.cpp:
7730         (WebCore::ColorInputType::shouldShowSuggestions):
7731         * make-file-arrays.py:
7732         (main):
7733
7734 2012-11-15  Eric Carlson  <eric.carlson@apple.com>
7735
7736         Update computed line position algorithm
7737         https://bugs.webkit.org/show_bug.cgi?id=93779
7738
7739         Reviewed by Philippe Normand.
7740
7741         Compute the position of a text track relative to rendered tracks. This is needed to position
7742         cues correctly when there is more than one text track.
7743
7744         Test: media/track/track-cue-container-rendering-position.html
7745
7746         * html/track/TextTrack.cpp:
7747         (WebCore::TextTrack::invalidateTrackIndex): Invalidate both cached track indices.
7748         (WebCore::TextTrack::trackIndexRelativeToRenderedTracks): Return the index of the track relative
7749             to other rendered tracks.
7750         * html/track/TextTrack.h:
7751
7752         * html/track/TextTrackCue.cpp:
7753         (WebCore::TextTrackCue::calculateComputedLinePosition): Use trackIndexRelativeToRenderedTracks()
7754             instead of trackIndex() so cues are positioned correctly.
7755
7756         * html/track/TextTrackList.cpp:
7757         (TextTrackList::getTrackIndex): Change return type from unsigned to int.
7758         (TextTrackList::getTrackIndexRelativeToRenderedTracks): New.
7759         * html/track/TextTrackList.h:
7760
7761 2012-11-15  Dominik Röttsches  <dominik.rottsches@intel.com>
7762
7763         [EFL] Bump Harfbuzz to allow fixing bug 101009 on EFL
7764         https://bugs.webkit.org/show_bug.cgi?id=101323
7765
7766         Reviewed by Martin Robinson.
7767
7768         Removing ifdef since we bumped Harfbuzz dependency. This is the
7769         real fix replacing the previous workaround of having a Chromium
7770         specific ifdef here, since Chromium uses a newer HarfBuzz version
7771         already.
7772
7773         No new tests, covered by css3/flexbox/inline-flex-crash.html
7774         which will not crash anymore even with the ifdef removed.
7775
7776         * platform/graphics/harfbuzz/ng/HarfBuzzShaper.cpp:
7777         (WebCore::HarfBuzzShaper::shapeHarfBuzzRuns):
7778
7779 2012-11-15  Andreas Kling  <kling@webkit.org>
7780
7781         REGRESSION(r134408): Heap-use-after-free in WebCore::HTMLConstructionSite::mergeAttributesFromTokenIntoElement().
7782         <http://webkit.org/b/102304>
7783
7784         Reviewed by Anders Carlsson.
7785
7786         Test: fast/dom/cloneNode-below-body-attribute-merging.html
7787
7788         * html/parser/HTMLConstructionSite.cpp:
7789         (WebCore::HTMLConstructionSite::mergeAttributesFromTokenIntoElement):
7790
7791             Use Element::fastHasAttribute() to determine if a given attribute is already present on the element
7792             we're merging attributes into.
7793
7794         * dom/ElementAttributeData.h:
7795         (ElementAttributeData):
7796
7797             Remove a now-unnecessary friend declaration.
7798
7799 2012-11-15  Elliott Sprehn  <esprehn@chromium.org>
7800
7801         Prevent creation of detached frames in ShadowRoot
7802         https://bugs.webkit.org/show_bug.cgi?id=102333
7803
7804         Reviewed by Dimitri Glazkov.
7805
7806         Similar to Bug 94717 you can create a loaded iframe in a detached
7807         subtree using ShadowRoot. To fix this we just need to make
7808         SubframeLoadingDisabler traverse through shadow boundaries.
7809
7810         Test: fast/frames/detached-shadow-frame.html
7811
7812         * html/HTMLFrameOwnerElement.h:
7813         (WebCore::SubframeLoadingDisabler::canLoadFrame):
7814
7815 2012-11-15  Shinya Kawanaka  <shinyak@chromium.org>
7816
7817         Changing pseudoClass (:visited) should cause distribution.
7818         https://bugs.webkit.org/show_bug.cgi?id=101700
7819
7820         Reviewed by Dimitri Glazkov.
7821
7822         When href attribute of an anchor or area element is changed, we have to invalidate distribution.
7823
7824         Since we would like to check a few pseudoClasses at once, we make the argument of
7825         SelectRuleFeatureSet::hasSelectorFor int.
7826
7827         Tests: fast/dom/shadow/pseudoclass-update-visited-anchor.html
7828                fast/dom/shadow/pseudoclass-update-visited-area.html
7829
7830         * dom/ElementShadow.cpp:
7831         (WebCore::invalidateParentDistributionIfNecessary):
7832         * dom/ElementShadow.h:
7833         (WebCore):
7834         * html/HTMLAnchorElement.cpp:
7835         (WebCore::HTMLAnchorElement::parseAttribute):
7836         * html/shadow/SelectRuleFeatureSet.h:
7837         (WebCore::SelectRuleFeatureSet::hasSelectorFor):
7838
7839 2012-11-15  Balazs Kelemen  <kbalazs@webkit.org>
7840
7841         Coordinated Graphics: support the "freeze animations" API
7842         https://bugs.webkit.org/show_bug.cgi?id=100703
7843
7844         Reviewed by Noam Rosenthal.
7845
7846         Make animations resumable in Coordinated Graphics.
7847         Pausing was already implemented.
7848
7849         Tested with animations and transitions tests. No tests to be
7850         unskipped because these tests has been working without this API
7851         as well (although this is the preferred way).
7852
7853         * platform/graphics/GraphicsLayerAnimation.cpp:
7854         (WebCore::GraphicsLayerAnimation::apply):
7855         (WebCore::GraphicsLayerAnimation::computeTotalRunningTime):
7856         Do not consider the time while we was suspended as part of
7857         the total running time.
7858         (WebCore):
7859         (WebCore::GraphicsLayerAnimation::resume):
7860         (WebCore::GraphicsLayerAnimations::suspend):
7861         (WebCore::GraphicsLayerAnimations::resume):
7862         * platform/graphics/GraphicsLayerAnimation.h:
7863         (GraphicsLayerAnimation):
7864         (GraphicsLayerAnimations):
7865
7866 2012-11-15  Gabor Rapcsanyi  <rgabor@webkit.org>
7867
7868         Relocate the ARM NEON SVG filter optimizations
7869         https://bugs.webkit.org/show_bug.cgi?id=102214
7870
7871         Reviewed by Zoltan Herczeg.
7872
7873         Relocate the ARM filter optimizations into platform/graphics/cpu/arm
7874         to keep them together with the others.
7875         From now all graphics optimization for ARM NEON should go here.
7876
7877         * CMakeLists.txt:
7878         * GNUmakefile.am:
7879         * GNUmakefile.list.am:
7880         * Target.pri:
7881         * WebCore.gyp/WebCore.gyp:
7882         * WebCore.gypi:
7883         * WebCore.pri:
7884         * WebCore.xcodeproj/project.pbxproj:
7885         * platform/graphics/cpu/arm/filters/FEBlendNEON.h: Renamed from Source/WebCore/platform/graphics/filters/arm/FEBlendNEON.h.
7886         (WebCore):
7887         (FEBlendUtilitiesNEON):
7888         (WebCore::FEBlendUtilitiesNEON::div255):
7889         (WebCore::FEBlendUtilitiesNEON::normal):
7890         (WebCore::FEBlendUtilitiesNEON::multiply):
7891         (WebCore::FEBlendUtilitiesNEON::screen):
7892         (WebCore::FEBlendUtilitiesNEON::darken):
7893         (WebCore::FEBlendUtilitiesNEON::lighten):
7894         (WebCore::FEBlend::platformApplyNEON):
7895         * platform/graphics/cpu/arm/filters/FECompositeArithmeticNEON.h: Renamed from Source/WebCore/platform/graphics/filters/arm/FECompositeArithmeticNEON.h.
7896         (WebCore):
7897         (WebCore::FEComposite::computeArithmeticPixelsNeon):
7898         (WebCore::FEComposite::platformArithmeticNeon):
7899         * platform/graphics/cpu/arm/filters/FEGaussianBlurNEON.h: Renamed from Source/WebCore/platform/graphics/filters/arm/FEGaussianBlurNEON.h.
7900         (WebCore):
7901         (WebCore::boxBlurNEON):
7902         * platform/graphics/cpu/arm/filters/FELightingNEON.cpp: Renamed from Source/WebCore/platform/graphics/filters/arm/FELightingNEON.cpp.
7903         (WebCore):
7904         (WebCore::feLightingConstantsForNeon):
7905         (WebCore::FELighting::platformApplyNeonWorker):
7906         (WebCore::FELighting::getPowerCoefficients):
7907         * platform/graphics/cpu/arm/filters/FELightingNEON.h: Renamed from Source/WebCore/platform/graphics/filters/arm/FELightingNEON.h.
7908         (WebCore):
7909         (FELightingFloatArgumentsForNeon):
7910         (FELightingPaintingDataForNeon):
7911         (WebCore::FELighting::platformApplyNeon):
7912         * platform/graphics/cpu/arm/filters/NEONHelpers.h: Renamed from Source/WebCore/platform/graphics/filters/arm/NEONHelpers.h.
7913         (WebCore):
7914         (WebCore::loadRGBA8AsFloat):
7915         (WebCore::storeFloatAsRGBA8):
7916
7917 2012-11-15  Mike West  <mkwst@chromium.org>
7918
7919         We should trigger a console warning when we encounter invalid sandbox flags.
7920         https://bugs.webkit.org/show_bug.cgi?id=101956
7921
7922         Reviewed by Adam Barth.
7923
7924         A developer who writes '<iframe sandbox="allowScripts">' probably has
7925         something in mind other than what the browser interprets. In these
7926         situations, we should log a console warning that notes 'allowScripts'
7927         is an invalid sandbox flag ('allow-scripts' is probably what she
7928         meant).
7929
7930         This patch does the simplest thing possible: it throws a warning that
7931         lists the invalid flags encountered for sandbox attributes on iframes,
7932         and for sandbox Content Security Policy directives.
7933
7934         Tests: http/tests/security/contentSecurityPolicy/sandbox-invalid-header.html
7935                http/tests/security/sandboxed-iframe-invalid.html
7936
7937         * dom/SecurityContext.cpp:
7938         (WebCore::SecurityContext::parseSandboxPolicy):
7939         * dom/SecurityContext.h:
7940         (SecurityContext):
7941             Accept a new out parameter, invalidTokensErrorMessage. If invalid
7942             tokens are encountered, build an error message string, and pass it
7943             back to the caller through this parameter.
7944         * html/HTMLIFrameElement.cpp:
7945         (WebCore::HTMLIFrameElement::parseAttribute):
7946         * page/ContentSecurityPolicy.cpp:
7947         (WebCore::CSPDirectiveList::applySandboxPolicy):
7948             When applying a sandbox policy, pass a string into
7949             SecurityContext::parseSandboxPolicy to grab any errors that might
7950             be encountered, and log a warning in that event.
7951         (WebCore::ContentSecurityPolicy::reportInvalidSandboxFlags):
7952         (WebCore):
7953         * page/ContentSecurityPolicy.h:
7954             Adding a new method to report invalid sandbox flags.
7955
7956 2012-11-15  Kenneth Rohde Christiansen  <kenneth@webkit.org>
7957
7958         Rename member vars in ViewportArgument to match css-device-adapt
7959         https://bugs.webkit.org/show_bug.cgi?id=102355
7960
7961         Reviewed by Gyuyoung Kim.
7962
7963         No behavior change, thus no new tests.
7964
7965         * dom/ViewportArguments.cpp:
7966         (WebCore::ViewportArguments::resolve):
7967         (WebCore::setViewportFeature):
7968         * dom/ViewportArguments.h:
7969         (WebCore::ViewportArguments::ViewportArguments):
7970         (ViewportArguments):
7971         (WebCore::ViewportArguments::operator==):
7972
7973 2012-11-15  Andrey Adaikin  <aandrey@chromium.org>
7974
7975         Web Inspector: [WebGL] cloneNode for images with revoked Blob URIs fails
7976         https://bugs.webkit.org/show_bug.cgi?id=102366
7977
7978         Reviewed by Vsevolod Vlasov.
7979
7980         * inspector/InjectedScriptCanvasModuleSource.js:
7981         (.):
7982
7983 2012-11-15  Mark Rowe  <mrowe@apple.com>
7984
7985         Build fix.
7986
7987         Disable deprecation warnings in a few places that need it.
7988
7989         * platform/graphics/ca/mac/TileCache.mm:
7990         (WebCore::TileCache::drawRepaintCounter):
7991         * platform/graphics/mac/FontMac.mm:
7992         (WebCore::showGlyphsWithAdvances):
7993         * platform/graphics/mac/WebLayer.mm:
7994         (drawLayerContents):
7995
7996 2012-11-15  Kent Tamura  <tkent@chromium.org>
7997
7998         Support stand-alone month names in calendar picker
7999         https://bugs.webkit.org/show_bug.cgi?id=102196
8000
8001         Reviewed by Kentaro Hara.
8002
8003         We have showed non stand-alone month names in any locales. However
8004         we should show stand-alone month names in some locales such as
8005         Russian.
8006
8007         This patch introduce PagePopupController::formatMonth. It is
8008         exposed to page-popups, and format year-month pairs in the same
8009         way as input[type=month].
8010
8011         No new tests. Affects platform/chromium/fast/forms/calendar-picker/calendar-picker-appearance-ru.html.
8012
8013         * Resources/pagepopups/calendarPicker.js:
8014         (Month.prototype.toLocaleString):
8015         Calls pagePopupController.formatMonth except Japanese locale.
8016         (handleArgumentsTimeout):
8017         Remove unnecessary default monthLabels.
8018         * page/PagePopupController.cpp:
8019         (WebCore::PagePopupController::formatMonth): Added.
8020         * page/PagePopupController.h:
8021         (PagePopupController): Declare formatMonth.
8022         * page/PagePopupController.idl: Add formatMonth.
8023
8024 2012-11-15  Eugene Klyuchnikov  <eustas.bug@gmail.com>
8025
8026         Web Inspector: Fix new JS compiler warnings.
8027         https://bugs.webkit.org/show_bug.cgi?id=102341
8028
8029         Reviewed by Yury Semikhatsky.
8030
8031         New version of compiler finds new inconsistencies.
8032
8033         * inspector/front-end/DOMAgent.js: Replaced 2 simiar cases with loop.
8034         * inspector/front-end/DOMBreakpointsSidebarPane.js:
8035         Declared instance property on WebInspector.
8036         * inspector/front-end/Script.js: Normalized parameter notation.
8037
8038 2012-11-15  Kenneth Rohde Christiansen  <kenneth@webkit.org>
8039
8040         Unreviewed build fix.
8041
8042         * dom/ViewportArguments.cpp:
8043         (WebCore::convertToUserSpace): Add static
8044
8045 2012-11-14  Kenneth Rohde Christiansen  <kenneth@webkit.org>
8046
8047         Refactor ViewportArguments to only use CSS units
8048         https://bugs.webkit.org/show_bug.cgi?id=102287
8049
8050         Reviewed by Noam Rosenthal.
8051
8052         Refactor the ViewportArgument code to use a member method for
8053         resolving the viewport. This new method only uses arguments in
8054         CSS units.
8055
8056         This is preparation for adding the CSS Device Adaptation support.
8057
8058         Tested by existing tests fast/viewport.
8059
8060         * dom/ViewportArguments.cpp:
8061         (WebCore::clampLengthValue):
8062         (WebCore::clampScaleValue): New utility functions.
8063         (WebCore::ViewportArguments::resolve):
8064         (WebCore::convertToUserSpace): Added until everyone provides arguments
8065         only in CSS units and not device ones.
8066         (WebCore::computeViewportAttributes):
8067         (WebCore::computeMinimumScaleFactorForContentContained):
8068         (WebCore):
8069         (WebCore::restrictMinimumScaleFactorToViewportSize):
8070         * dom/ViewportArguments.h:
8071         (ViewportArguments):
8072
8073 2012-11-14  Shinya Kawanaka  <shinyak@chromium.org> 
8074
8075         Changing pseudoClass (:disabled) should cause distribution.
8076         https://bugs.webkit.org/show_bug.cgi?id=101901
8077
8078         Reviewed by Hajime Morita.
8079
8080         We have to invalidate distribution when pseudo-class (:disabled) is changed.
8081
8082         According to the HTML5 spec, :disabled will match button, input, select, textarea, optgroup,
8083         option, command, li, and fieldset. However, command is not implemented yet, we skip li and command. li might
8084         have 'disabled' state, but we need a command element to make it 'disabled' state.
8085
8086         Tests: fast/dom/shadow/pseudoclass-update-disabled-button.html
8087                fast/dom/shadow/pseudoclass-update-disabled-fieldset.html
8088                fast/dom/shadow/pseudoclass-update-disabled-input.html
8089                fast/dom/shadow/pseudoclass-update-disabled-optgroup.html
8090                fast/dom/shadow/pseudoclass-update-disabled-option.html
8091                fast/dom/shadow/pseudoclass-update-disabled-select.html
8092                fast/dom/shadow/pseudoclass-update-disabled-textarea.html
8093
8094         * html/HTMLFormControlElement.cpp:
8095         (WebCore::HTMLFormControlElement::disabledAttributeChanged):
8096         * html/HTMLOptGroupElement.cpp:
8097         (WebCore::HTMLOptGroupElement::parseAttribute):
8098         * html/HTMLOptionElement.cpp:
8099         (WebCore::HTMLOptionElement::parseAttribute):
8100
8101 2012-11-14  Sheriff Bot  <webkit.review.bot@gmail.com>
8102
8103         Unreviewed, rolling out r134691, r134703, r134715, r134716,
8104         and r134733.
8105         http://trac.webkit.org/changeset/134691
8106         http://trac.webkit.org/changeset/134703
8107         http://trac.webkit.org/changeset/134715
8108         http://trac.webkit.org/changeset/134716
8109         http://trac.webkit.org/changeset/134733
8110         https://bugs.webkit.org/show_bug.cgi?id=102342
8111
8112         "Broke the Apple Windows Debug and GTK builds." (Requested by
8113         dydx on #webkit).
8114
8115         * WebCore.exp.in:
8116         * bindings/js/SerializedScriptValue.h:
8117         * testing/Internals.cpp:
8118         * testing/Internals.h:
8119         (WebCore):
8120         * testing/Internals.idl:
8121
8122 2012-11-14  Pavel Feldman  <pfeldman@chromium.org>
8123
8124         Not reviewed: fixing inspector tests under Qt.
8125
8126         * inspector/front-end/TestController.js:
8127         * inspector/front-end/utilities.js:
8128         (.):
8129
8130 2012-11-14  Kentaro Hara  <haraken@chromium.org>
8131
8132         Unreviewed. Rebaselined run-bindings-tests.
8133
8134         * bindings/scripts/test/V8/V8TestNode.h:
8135         (WebCore::toV8Fast):
8136
8137 2012-11-14  Simon Fraser  <simon.fraser@apple.com>
8138
8139         Don't use temporary clip rects when hit testing
8140         https://bugs.webkit.org/show_bug.cgi?id=102329
8141
8142         Reviewed by Beth Dakin.
8143
8144         We now cache clip rects separately for painting, hit testing etc. Hit testing
8145         clip rects are always shrunk to exclude scrollbars (so that hit testing on
8146         the scrollbars works), so we no longer every need to use temporary clip rects
8147         during hit testing.
8148
8149         Added an assertion that the scrollbar relevancy when we computed the clip rects
8150         is the same as that when using them.
8151         
8152         * rendering/RenderLayer.cpp:
8153         (WebCore::RenderLayer::hitTestLayer):
8154         (WebCore::RenderLayer::updateClipRects):
8155         * rendering/RenderLayer.h:
8156         (WebCore::ClipRectsCache::ClipRectsCache):
8157         (ClipRectsCache):
8158
8159 2012-11-14  Dirk Schulze  <krit@webkit.org>
8160
8161         Support animation of basic shape 'polygon'
8162         https://bugs.webkit.org/show_bug.cgi?id=102080
8163
8164         Reviewed by Daniel Bates.
8165
8166         The basic shapes 'circle', 'rectangle' and 'ellipse' are animatable with the committed
8167         patch http://trac.webkit.org/changeset/134352.
8168         This is a follow-up patch to make 'polygon' animatable as well, as long as the number
8169         of vertices between start and end polygon is the same.
8170
8171         Added polygon animation test to existing test:
8172             fast/exclusions/shape-inside/shape-inside-animation.html
8173             css3/masking/clip-path-animation.html
8174
8175         * page/animation/CSSPropertyAnimation.cpp: Forgot to add copyright with last commits.
8176         * rendering/style/BasicShapes.cpp:
8177         (WebCore::BasicShape::canBlend): Polygons are allowed now.
8178         (WebCore::BasicShapePolygon::blend): Interpolate polygon shapes.
8179
8180 2012-11-14  Kentaro Hara  <haraken@chromium.org>
8181
8182         Unreviewed. Fix code generator warnings.
8183
8184         * bindings/scripts/CodeGeneratorV8.pm:
8185         (GenerateFunctionCallback):
8186         (GenerateImplementation):
8187
8188 2012-11-14  Shinya Kawanaka  <shinyak@chromium.org>
8189
8190         Changing pseudoClass (:checked) should cause distribution.
8191         https://bugs.webkit.org/show_bug.cgi?id=101902
8192
8193         Reviewed by Dimitri Glazkov.
8194
8195         When the 'checked' state is changed, we have to invalidate distribution.
8196
8197         According to the HTML5 spec, :checked should match a checked input[type="checkbox"],
8198         a checked input[type="radio"], a selected option, and commands. However, we don't have a command element yet.
8199
8200         Tests: fast/dom/shadow/pseudoclass-update-checked-input.html
8201                fast/dom/shadow/pseudoclass-update-checked-option.html
8202
8203         * html/HTMLInputElement.cpp:
8204         (WebCore::HTMLInputElement::setChecked):
8205         * html/HTMLOptionElement.cpp:
8206         (WebCore::HTMLOptionElement::setSelectedState):
8207
8208 2012-11-14  Kentaro Hara  <haraken@chromium.org>
8209
8210         [V8] Kill $implClassName from CodeGeneratorV8.pm
8211         https://bugs.webkit.org/show_bug.cgi?id=102312
8212
8213         Reviewed by Adam Barth.
8214
8215         $implClassName and $interfaceName are the same.
8216         Sometimes we are passing both $implClassName and $interfaceName to
8217         subroutines. We can kill $implClassName.
8218
8219         No tests. No change in behavior.
8220
8221         * bindings/scripts/CodeGeneratorV8.pm:
8222         (GenerateOpaqueRootForGC):
8223         (GenerateHeader):
8224         (GenerateDomainSafeFunctionGetter):
8225         (GenerateDomainSafeFunctionSetter):
8226         (GenerateConstructorGetter):
8227         (GenerateNormalAttrGetter):
8228         (GenerateReplaceableAttrSetter):
8229         (GenerateNormalAttrSetter):
8230         (GenerateEventListenerCallback):
8231         (GenerateOverloadedFunctionCallback):
8232         (GenerateFunctionCallback):
8233         (GenerateParametersCheck):
8234         (GenerateOverloadedConstructorCallback):
8235         (GenerateSingleConstructorCallback):
8236         (GenerateConstructorCallback):
8237         (GenerateEventConstructorCallback):
8238         (GenerateTypedArrayConstructorCallback):
8239         (GenerateNamedConstructorCallback):
8240         (GenerateImplementation):
8241         (GenerateFunctionCallString):
8242
8243 2012-11-14  Adam Barth  <abarth@webkit.org>
8244
8245         [V8] We can shave one instruction off toV8Fast
8246         https://bugs.webkit.org/show_bug.cgi?id=102297
8247
8248         Reviewed by Kentaro Hara.
8249
8250         There's no reason to store info.Holder in a local variable. Calling
8251         Holder() is essentially free because it's inlined to an offset read.
8252
8253         I doubt this patch moves the performance needle in any measurable way,
8254         but it makes the code slightly prettier.
8255
8256         * bindings/scripts/CodeGeneratorV8.pm:
8257         (GenerateHeader):
8258         * bindings/scripts/test/V8/V8TestNode.h:
8259         (WebCore::toV8Fast):
8260
8261 2012-11-14  Kentaro Hara  <haraken@chromium.org>
8262
8263         [V8] Get rid of a redundant branch in JSValueToNative()
8264         https://bugs.webkit.org/show_bug.cgi?id=102311
8265
8266         Reviewed by Adam Barth.
8267
8268         No tests. No change in behavior.
8269
8270         * bindings/scripts/CodeGeneratorV8.pm:
8271         (JSValueToNative):
8272         (NativeToJSValue):
8273
8274 2012-11-14  Shinya Kawanaka  <shinyak@chromium.org>
8275
8276         Changing pseudoClass (:link) should cause distribution
8277         https://bugs.webkit.org/show_bug.cgi?id=101698
8278
8279         Reviewed by Hajime Morita.
8280
8281         CSSSelector :link matches anchor element with href attribute. When href attribute of an anchor element is changed,
8282         we have to invalidate distribution.
8283
8284         According to the HTML spec, :link matches a link element having href attribute, currently we have not implemented it yet.
8285
8286         Tests: fast/dom/shadow/pseudoclass-update-link-anchor.html
8287                fast/dom/shadow/pseudoclass-update-link-area.html
8288
8289         * html/HTMLAnchorElement.cpp:
8290         (WebCore::HTMLAnchorElement::parseAttribute):
8291
8292 2012-11-14  Kentaro Hara  <haraken@chromium.org>
8293
8294         Remove unused functions from CodeGenerator.pm
8295         https://bugs.webkit.org/show_bug.cgi?id=102316
8296
8297         Reviewed by Adam Barth.
8298
8299         No tests. No change in behavior.
8300
8301         * bindings/scripts/CodeGenerator.pm:
8302         (GenerateCompileTimeCheckForEnumsIfNeeded):
8303
8304 2012-11-14  Tiancheng Jiang  <tijiang@rim.com>
8305
8306         [BlackBerry] Update BB10 form theme.
8307         https://bugs.webkit.org/show_bug.cgi?id=100760
8308
8309         Reviewed by Rob Buis.
8310
8311         RIM PR 225755
8312         Internally Reviewed by Eli Fidler.
8313         Update checkbox, radio and menulist button style. Adjust border width
8314         and line height.
8315
8316         * platform/blackberry/RenderThemeBlackBerry.cpp:
8317         (WebCore::RenderThemeBlackBerry::adjustMenuListButtonStyle):
8318         * platform/blackberry/RenderThemeBlackBerry.h:
8319         (RenderThemeBlackBerry):
8320
8321 2012-11-14  Erik Arvidsson  <arv@chromium.org>
8322
8323         Update DOMException name: InvalidModificationError
8324         https://bugs.webkit.org/show_bug.cgi?id=102281
8325
8326         Reviewed by Kentaro Hara.
8327
8328         Patch 13 of 25 to update DOMException name to match the spec and Firefox.
8329
8330         DOMExcecption INVALID_MODIFICATION_ERR is not used in our code.
8331
8332         * dom/DOMCoreException.cpp:
8333
8334 2012-11-14  Adam Barth  <abarth@webkit.org>
8335
8336         document variable in Document::axObjectCache is actually the topDocument
8337         https://bugs.webkit.org/show_bug.cgi?id=101966
8338
8339         Reviewed by Chris Fleizach.
8340
8341         Name change requested by Darin Adler.
8342
8343         * dom/Document.cpp:
8344         (WebCore::Document::axObjectCache):
8345
8346 2012-11-14  Joseph Pecoraro  <pecoraro@apple.com>
8347
8348         [CF]: XMLHttpRequest "timeout" events firing as "error" events
8349         https://bugs.webkit.org/show_bug.cgi?id=102271
8350
8351         Reviewed by David Kilzer.
8352
8353         Initialize the tiemout flag if the error results from a timeout
8354         in the USE(CFNETWORK) cases.
8355
8356         No new tests. This is covered by http/tests/xmlhttprequest/timeout
8357         tests on ports that USE(CFNETWORK).
8358
8359         * platform/network/cf/ResourceErrorCF.cpp:
8360         (WebCore::ResourceError::ResourceError):
8361         * platform/network/mac/ResourceErrorMac.mm:
8362         (WebCore::ResourceError::ResourceError):
8363
8364 2012-11-14  Nico Weber  <thakis@chromium.org>
8365
8366         [chromium/mac] Fix drawing of buttons, checkboxes, radio boxes, and steppers when the page is scaled
8367         https://bugs.webkit.org/show_bug.cgi?id=102282
8368
8369         Reviewed by James Robinson.
8370
8371         Chromium uses skia, and skia state is synced with CG context state at
8372         LocalCurrentGraphicsContext construction time. So delay that
8373         construction after context transforms have happened.
8374         (This regressed in http://trac.webkit.org/changeset/125830)
8375
8376         Covered by the new pixel test fast/forms/zoomed-controls.html. I
8377         couldn't find an existing test for this.
8378
8379         * platform/mac/ThemeMac.mm:
8380         (WebCore::paintCheckbox):
8381         (WebCore::paintRadio):
8382         (WebCore::paintButton):
8383
8384 2012-11-14  Mark Lam  <mark.lam@apple.com>
8385
8386         Change JSEventListener::m_jsFunction to be a weak ref.
8387         https://bugs.webkit.org/show_bug.cgi?id=101989.
8388
8389         Reviewed by Geoffrey Garen.
8390
8391         No new tests.
8392
8393         * ForwardingHeaders/heap/SlotVisitor.h: Added.
8394         * bindings/js/JSDOMBinding.h: Added #include <heap/SlotVisitor.h>
8395         * bindings/js/JSEventListener.cpp:
8396         (WebCore::JSEventListener::JSEventListener):
8397         (WebCore::JSEventListener::visitJSFunction):
8398         (WebCore::JSEventListener::operator==):
8399          - Removed the m_wrapper checks in operator==() because they are not
8400            needed. There is no longer any threat of m_jsFunction pointing to
8401            recycled memory. The use of weak refs will ensure that m_jsFunction
8402            is either still holding on to its old memory exclusively, or is 0'ed
8403            out when the GC collects it.
8404         * bindings/js/JSEventListener.h:
8405         (JSEventListener):
8406         (WebCore::JSEventListener::jsFunction):
8407
8408 2012-11-14  Dan Carney  <dcarney@google.com>
8409
8410         [V8] Rename dispatchWrap
8411         https://bugs.webkit.org/show_bug.cgi?id=102240
8412
8413         Reviewed by Adam Barth.
8414
8415         Mostly a rename:
8416         dispatchWrap->wrap
8417         wrapSlow->createWrapper
8418         dispatchWrapCustom->wrap
8419
8420         No new tests. No change in functionality.
8421
8422         * bindings/scripts/CodeGeneratorV8.pm:
8423         (GenerateHeader):
8424         (GenerateNormalAttrGetter):
8425         (GenerateImplementation):
8426         (GenerateToV8Converters):
8427         * bindings/scripts/IDLAttributes.txt:
8428         * bindings/scripts/test/V8/V8Float64Array.cpp:
8429         (WebCore::wrap):
8430         (WebCore::V8Float64Array::createWrapper):
8431         * bindings/scripts/test/V8/V8Float64Array.h:
8432         (V8Float64Array):
8433         (WebCore):
8434         (WebCore::toV8Object):
8435         (WebCore::toV8):
8436         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
8437         (WebCore::V8TestActiveDOMObject::createWrapper):
8438         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
8439         (V8TestActiveDOMObject):
8440         (WebCore::wrap):
8441         (WebCore::toV8Object):
8442         (WebCore::toV8):
8443         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
8444         (WebCore::V8TestCustomNamedGetter::createWrapper):
8445         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
8446         (V8TestCustomNamedGetter):
8447         (WebCore::wrap):
8448         (WebCore::toV8Object):
8449         (WebCore::toV8):
8450         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
8451         (WebCore::V8TestEventConstructor::createWrapper):
8452         * bindings/scripts/test/V8/V8TestEventConstructor.h:
8453         (V8TestEventConstructor):
8454         (WebCore::wrap):
8455         (WebCore::toV8Object):
8456         (WebCore::toV8):
8457         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
8458         (WebCore::V8TestEventTarget::createWrapper):
8459         * bindings/scripts/test/V8/V8TestEventTarget.h:
8460         (V8TestEventTarget):
8461         (WebCore::wrap):
8462         (WebCore::toV8Object):
8463         (WebCore::toV8):
8464         * bindings/scripts/test/V8/V8TestException.cpp:
8465         (WebCore::V8TestException::createWrapper):
8466         * bindings/scripts/test/V8/V8TestException.h:
8467         (V8TestException):
8468         (WebCore::wrap):
8469         (WebCore::toV8Object):
8470         (WebCore::toV8):
8471         * bindings/scripts/test/V8/V8TestInterface.cpp:
8472         (WebCore::V8TestInterface::createWrapper):
8473         * bindings/scripts/test/V8/V8TestInterface.h:
8474         (V8TestInterface):
8475         (WebCore::wrap):
8476         (WebCore::toV8Object):
8477         (WebCore::toV8):
8478         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
8479         (WebCore::V8TestMediaQueryListListener::createWrapper):
8480         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
8481         (V8TestMediaQueryListListener):
8482         (WebCore::wrap):
8483         (WebCore::toV8Object):
8484         (WebCore::toV8):
8485         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
8486         (WebCore::V8TestNamedConstructor::createWrapper):
8487         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
8488         (V8TestNamedConstructor):
8489         (WebCore::wrap):
8490         (WebCore::toV8Object):
8491         (WebCore::toV8):
8492         * bindings/scripts/test/V8/V8TestNode.cpp:
8493         (WebCore::V8TestNode::createWrapper):
8494         * bindings/scripts/test/V8/V8TestNode.h:
8495         (V8TestNode):
8496         (WebCore::wrap):
8497         (WebCore::toV8Object):
8498         (WebCore::toV8):
8499         (WebCore::toV8Fast):
8500         * bindings/scripts/test/V8/V8TestObj.cpp:
8501         (WebCore::V8TestObj::createWrapper):
8502         * bindings/scripts/test/V8/V8TestObj.h:
8503         (V8TestObj):
8504         (WebCore::wrap):
8505         (WebCore::toV8Object):
8506         (WebCore::toV8):
8507         * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
8508         (WebCore::V8TestOverloadedConstructors::createWrapper):
8509         * bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
8510         (V8TestOverloadedConstructors):
8511         (WebCore::wrap):
8512         (WebCore::toV8Object):
8513         (WebCore::toV8):
8514         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
8515         (WebCore::V8TestSerializedScriptValueInterface::createWrapper):
8516         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
8517         (V8TestSerializedScriptValueInterface):
8518         (WebCore::wrap):
8519         (WebCore::toV8Object):
8520         (WebCore::toV8):
8521         * bindings/v8/custom/V8BlobCustom.cpp:
8522         (WebCore::wrap):
8523         * bindings/v8/custom/V8CSSRuleCustom.cpp:
8524         (WebCore::wrap):
8525         * bindings/v8/custom/V8CSSValueCustom.cpp:
8526         (WebCore::wrap):
8527         * bindings/v8/custom/V8CanvasRenderingContextCustom.cpp:
8528         (WebCore::wrap):
8529         * bindings/v8/custom/V8DataViewCustom.cpp:
8530         (WebCore::wrap):
8531         * bindings/v8/custom/V8DocumentCustom.cpp:
8532         (WebCore::wrap):
8533         * bindings/v8/custom/V8ElementCustom.cpp:
8534         (WebCore):
8535         (WebCore::wrap):
8536         * bindings/v8/custom/V8EntryCustom.cpp:
8537         (WebCore::wrap):
8538         * bindings/v8/custom/V8EntrySyncCustom.cpp:
8539         (WebCore::wrap):
8540         * bindings/v8/custom/V8EventCustom.cpp:
8541         (WebCore):
8542         (WebCore::wrap):
8543         * bindings/v8/custom/V8HTMLCollectionCustom.cpp:
8544         (WebCore::wrap):
8545         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
8546         (WebCore::wrap):
8547         * bindings/v8/custom/V8HTMLElementCustom.cpp:
8548         (WebCore::wrap):
8549         * bindings/v8/custom/V8ImageDataCustom.cpp:
8550         (WebCore::wrap):
8551         * bindings/v8/custom/V8NodeCustom.cpp:
8552         (WebCore::wrap):
8553         * bindings/v8/custom/V8PerformanceEntryCustom.cpp:
8554         (WebCore::wrap):
8555         * bindings/v8/custom/V8SVGDocumentCustom.cpp:
8556         (WebCore::wrap):
8557         * bindings/v8/custom/V8SVGElementCustom.cpp:
8558         (WebCore::wrap):
8559         * bindings/v8/custom/V8SVGPathSegCustom.cpp:
8560         (WebCore::wrap):
8561         * bindings/v8/custom/V8StyleSheetCustom.cpp:
8562         (WebCore::wrap):
8563         * dom/make_names.pl:
8564         (printWrapperFunctions):
8565         (printWrapperFactoryCppFile):
8566
8567 2012-11-14  Ryuan Choi  <ryuan.choi@gmail.com>
8568
8569         [EFL] Refactor theme to choose whether to support foreground color of selection
8570         https://bugs.webkit.org/show_bug.cgi?id=102037
8571
8572         Reviewed by Gyuyoung Kim.
8573
8574         RenderThemeEfl can change foreground color of selection using theme file.
8575         But it can not disable supports of foreground color to keep the text color
8576         which is selected.
8577
8578         This patch refactors color classes of theme file from active/inactive classes
8579         to foreground/background classes so that RenderThemeEfl checks whether
8580         theme file supports foreground color class.
8581
8582         * platform/efl/RenderThemeEfl.cpp:
8583         (WebCore::fillColorsFromEdjeClass):
8584         (WebCore::RenderThemeEfl::setColorFromThemeClass):
8585         (WebCore::RenderThemeEfl::loadTheme):
8586         (WebCore::RenderThemeEfl::RenderThemeEfl):
8587         (WebCore::RenderThemeEfl::supportsSelectionForegroundColors):
8588         (WebCore):
8589         * platform/efl/RenderThemeEfl.h:
8590         (RenderThemeEfl):
8591
8592 2012-11-14  Tony Chang  <tony@chromium.org>
8593
8594         Convert m_selectorVector back to a stack allocated m_reusableSelectorVector
8595         https://bugs.webkit.org/show_bug.cgi?id=102295
8596
8597         Reviewed by Andreas Kling.
8598
8599         Revert r125252 because we're not going to go forward with implementing CSS hierarchies at this time.
8600
8601         No new tests because there should be no change in behavior.
8602
8603         * css/CSSGrammar.y.in:
8604         * css/CSSParser.cpp:
8605         (WebCore::CSSParser::CSSParser):
8606         (WebCore::CSSParser::parseValue):
8607         (WebCore::CSSParser::parseColor):
8608         (WebCore::CSSParser::parseDeclaration):
8609         (WebCore):
8610         (WebCore::filterProperties):
8611         (WebCore::CSSParser::createStylePropertySet):
8612         (WebCore::CSSParser::addProperty):
8613         (WebCore::CSSParser::rollbackLastProperties):
8614         (WebCore::CSSParser::clearProperties):
8615         (WebCore::CSSParser::parse4Values):
8616         (WebCore::CSSParser::parseFlowThread):
8617         (WebCore::CSSParser::addTextDecorationProperty):
8618         (WebCore::CSSParser::createFloatingSelectorVector):
8619         (WebCore::CSSParser::sinkFloatingSelectorVector):
8620         (WebCore::CSSParser::createStyleRule):
8621         (WebCore::CSSParser::createFontFaceRule):
8622         (WebCore::CSSParser::createPageRule):
8623         (WebCore::CSSParser::setReusableRegionSelectorVector):
8624         (WebCore::CSSParser::startDeclarationsForMarginBox):
8625         (WebCore::CSSParser::endDeclarationsForMarginBox):
8626         (WebCore::CSSParser::deleteFontFaceOnlyValues):
8627         * css/CSSParser.h:
8628         (WebCore::CSSParser::hasProperties):
8629         (WebCore::CSSParser::reusableSelectorVector):
8630         (CSSParser):
8631         (WebCore::CSSParser::reusableRegionSelectorVector):
8632         * css/CSSParserValues.cpp:
8633         (WebCore::CSSParserSelector::adoptSelectorVector):
8634         * css/CSSParserValues.h:
8635         (CSSParserSelector):
8636         * css/CSSSelectorList.cpp:
8637         (WebCore::CSSSelectorList::adoptSelectorVector):
8638         * css/CSSSelectorList.h:
8639         (CSSSelectorList):
8640         * css/SVGCSSParser.cpp:
8641         (WebCore::CSSParser::parseSVGValue):
8642         * css/StyleRule.cpp:
8643         (WebCore::StyleRuleRegion::StyleRuleRegion):
8644         * css/StyleRule.h:
8645         (WebCore::StyleRule::parserAdoptSelectorVector):
8646         (WebCore::StyleRulePage::parserAdoptSelectorVector):
8647         (WebCore::StyleRuleRegion::create):
8648         (StyleRuleRegion):
8649
8650 2012-11-14  Alec Flett  <alecflett@chromium.org>
8651
8652         Add tests for explicit serialization values
8653         https://bugs.webkit.org/show_bug.cgi?id=96818
8654
8655         Reviewed by Adam Barth.
8656
8657         Expose direct access to the serialization/deserialization mechanisms
8658         of SerializedScriptValue to DumpRenderTree.
8659
8660         * testing/Internals.cpp:
8661         (WebCore::Internals::serializeObject):
8662         (WebCore):
8663         (WebCore::Internals::deserializeBuffer):
8664         * testing/Internals.h:
8665         (WebCore):
8666         * testing/Internals.idl:
8667
8668 2012-11-14  Michael Pruett  <michael@68k.org>
8669
8670         IndexedDB: Add clear() method to JSC ScriptValue
8671         https://bugs.webkit.org/show_bug.cgi?id=102288
8672
8673         Reviewed by Kentaro Hara.
8674
8675         IndexedDB uses the ScriptValue::clear() method, which existed
8676         previously only in the V8 implementation of ScriptValue. This
8677         change is necessary to implement IndexedDB for JSC.
8678
8679         Tests: storage/indexeddb/*
8680
8681         * bindings/js/ScriptValue.h:
8682         (WebCore::ScriptValue::clear):
8683         (ScriptValue):
8684
8685 2012-11-14  Joshua Bell  <jsbell@chromium.org>
8686
8687         IndexedDB: Indexing tests are flaky-crashing
8688         https://bugs.webkit.org/show_bug.cgi?id=102283
8689
8690         Reviewed by Tony Chang.
8691
8692         Don't commit the transaction if there are outstanding pre-emptive events
8693         from indexing operations.
8694
8695         Speculative fix for the flakiness.
8696
8697         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
8698         (WebCore::IDBTransactionBackendImpl::taskEventTimerFired):
8699
8700 2012-11-14  Tony Chang  <tony@chromium.org>
8701
8702         Crash in flexbox when removing absolutely positioned children
8703         https://bugs.webkit.org/show_bug.cgi?id=100465
8704
8705         Reviewed by Ojan Vafai.
8706
8707         We use m_numberOfChildrenOnFirstLine when computing baseline alignment.
8708         This value gets set during flexbox layout. When we remove an absolutely
8709         positioned child, we don't relayout and this value would get stale.
8710
8711         Change m_numberOfChildrenOnFirstLine to m_numberOfInFlowChildrenOnFirstLine
8712         so the value doesn't get stale when we remove absolutely positioned children.
8713         Also change the loop in firstLineBoxBaseline to bail if we run off the end of
8714         the iterator.
8715
8716         Test: css3/flexbox/crash-removing-out-of-flow-child.html
8717
8718         * rendering/RenderFlexibleBox.cpp:
8719         (WebCore::RenderFlexibleBox::RenderFlexibleBox):
8720         (WebCore::RenderFlexibleBox::firstLineBoxBaseline):
8721         (WebCore::RenderFlexibleBox::layoutBlock):
8722         (WebCore::RenderFlexibleBox::repositionLogicalHeightDependentFlexItems):
8723         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren):
8724         * rendering/RenderFlexibleBox.h:
8725
8726 2012-11-14  Joshua Bell  <jsbell@chromium.org>
8727
8728         IndexedDB: Remove magic numbers in record comparator, handle missing case
8729         https://bugs.webkit.org/show_bug.cgi?id=102255
8730
8731         Reviewed by Tony Chang.
8732
8733         For some ranges of metadata entries, a simple type byte comparison is sufficient
8734         for the backing store comparator. In two places those ranges used magic numbers,
8735         one of which was incorrect - which could lead to failed reads/writes.
8736
8737         Test: webkit_unit_tests --gtest_filter='IDBLevelDBCodingTest.ComparisonTest'
8738
8739         * Modules/indexeddb/IDBLevelDBCoding.cpp:
8740         (IDBLevelDBCoding):
8741         (WebCore::IDBLevelDBCoding::compare):
8742         * Modules/indexeddb/IDBLevelDBCoding.h:
8743
8744 2012-11-14  Dirk Schulze  <krit@webkit.org>
8745
8746         Cleanup BasicShape blending check
8747         https://bugs.webkit.org/show_bug.cgi?id=102289
8748
8749         Reviewed by Daniel Bates.
8750
8751         CSSPropertyAnimation had the same code for varifying that two BasicShape objects can be blended 
8752         twice. Refactor the code and add a canBlend method in BasicShape that combines both checks. This
8753         is a preparation for follow-up patches.
8754
8755         Pure refactoring without behavior change, no new tests.
8756
8757         * page/animation/CSSPropertyAnimation.cpp:
8758         (WebCore::blendFunc): Call new canBlend method for blending verification.
8759         * rendering/style/BasicShapes.cpp:
8760         (WebCore::BasicShape::canBlend): Check if two BasicShape objects can be blended.
8761         (WebCore):
8762         * rendering/style/BasicShapes.h:
8763
8764 2012-11-14  Dirk Schulze  <krit@webkit.org>
8765
8766         [CSS Exclusions] Basic shapes on 'shape-inside' should be animatable
8767         https://bugs.webkit.org/show_bug.cgi?id=102123
8768
8769         Reviewed by Antti Koivisto.
8770
8771         The '-webkit-shape-inside' propery takes a BasicShape as input like
8772         '-webkit-clip-path'. Follow up on http://trac.webkit.org/changeset/134352 and
8773         make '-webkit-shape-inside' animatable as well.
8774
8775         Test: fast/exclusions/shape-inside/shape-inside-animation.html
8776
8777         * page/animation/CSSPropertyAnimation.cpp:
8778         (WebCore::blendFunc): Blend fuction for exclusion shapes. The property takes another
8779             input then '-webkit-clip-path'.
8780         (WebCore):
8781         (PropertyWrapperBasicShape): Add wrapper for BasicShape object. Can be reused by
8782             '-webkit-shape-ourside' as well.
8783         (WebCore::PropertyWrapperBasicShape::PropertyWrapperBasicShape):
8784         (WebCore::CSSPropertyAnimation::ensurePropertyMap):
8785
8786 2012-11-14  Helder Correia  <helder.correia@nokia.com>
8787
8788         [TexMap][Cairo] Accelerated compositing debug visuals
8789         https://bugs.webkit.org/show_bug.cgi?id=101883
8790
8791         Reviewed by Kenneth Rohde Christiansen.
8792
8793         No new tests, just introducing a debug feature.
8794
8795         Add a Cairo implementation to complement the patch from bug 90116
8796         (http://trac.webkit.org/changeset/122275).
8797
8798         For this feature to be enabled, the environment variable
8799         WEBKIT_SHOW_COMPOSITING_DEBUG_VISUALS must be set to 1. Once enabled,
8800         both repaint counters and tile borders will be painted.
8801
8802         A Cairo-specific drawRepaintCounter() implementation was added to
8803         TextureMapperGL. A cairo_surface_t is used as scratch buffer to paint
8804         the counters. It is then uploaded to a BitmapTexture acquired
8805         from the pool and finally draw by TextureMapper. The actual compositing
8806         happens inside LayerBackingStore::paintToTextureMapper(). Each
8807         LayerBackingStoreTile has a repaint counter which gets incremented in
8808         LayerBackingStore::updateTile().
8809
8810         * platform/graphics/texmap/TextureMapperGL.cpp:
8811         (WebCore::TextureMapperGL::drawRepaintCounter):
8812
8813 2012-11-14  Michael Pruett  <michael@68k.org>
8814
8815         IndexedDB: Add JSNoStaticTables to IndexedDB interfaces
8816         https://bugs.webkit.org/show_bug.cgi?id=102268
8817
8818         Reviewed by Geoffrey Garen.
8819
8820         Add JSNoStaticTables attribute to IndexedDB interface
8821         definitions. This attribute must be specified in interfaces
8822         which can be accessed from workers.
8823
8824         Tests: storage/indexeddb/*
8825
8826         * Modules/indexeddb/IDBAny.idl:
8827         * Modules/indexeddb/IDBCursor.idl:
8828         * Modules/indexeddb/IDBCursorWithValue.idl:
8829         * Modules/indexeddb/IDBDatabase.idl:
8830         * Modules/indexeddb/IDBDatabaseException.idl:
8831         * Modules/indexeddb/IDBFactory.idl:
8832         * Modules/indexeddb/IDBIndex.idl:
8833         * Modules/indexeddb/IDBKey.idl:
8834         * Modules/indexeddb/IDBKeyRange.idl:
8835         * Modules/indexeddb/IDBObjectStore.idl:
8836         * Modules/indexeddb/IDBOpenDBRequest.idl:
8837         * Modules/indexeddb/IDBRequest.idl:
8838         * Modules/indexeddb/IDBTransaction.idl:
8839         * Modules/indexeddb/IDBUpgradeNeededEvent.idl:
8840         * Modules/indexeddb/IDBVersionChangeEvent.idl:
8841         * Modules/indexeddb/IDBVersionChangeRequest.idl:
8842         * dom/DOMStringList.idl:
8843
8844 2012-11-14  Michael Pruett  <michael@68k.org>
8845
8846         IndexedDB: Replace int64 with int64_t
8847         https://bugs.webkit.org/show_bug.cgi?id=102270
8848
8849         Reviewed by Tony Chang.
8850
8851         Cleaning up coding inconsistencies, no change in behavior.
8852
8853         Tests: storage/indexeddb/*
8854
8855         * Modules/indexeddb/IDBDatabase.cpp:
8856         (WebCore::IDBDatabase::deleteObjectStore):
8857         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
8858         (WebCore::IDBObjectStoreBackendImpl::putInternal):
8859
8860 2012-11-14  Viatcheslav Ostapenko  <v.ostapenko@samsung.com>
8861
8862         [EFL][WK2] White flicker when scrolling big pages with dark background on slower hardware.
8863         https://bugs.webkit.org/show_bug.cgi?id=102000
8864
8865         Reviewed by Noam Rosenthal.
8866
8867         Add helper functions to clear viewport before painting. Those functions
8868         used by EFL Webkit2 port to set view background to match page background
8869         in order to reduce visibility of flicker during scrolling/scaling/repainting
8870         where page tiles are not ready.
8871
8872         * platform/graphics/texmap/TextureMapper.h:
8873         * platform/graphics/texmap/TextureMapperGL.cpp:
8874         (WebCore::TextureMapperGL::drawSolidColor):
8875         (WebCore):
8876         * platform/graphics/texmap/TextureMapperGL.h:
8877         * platform/graphics/texmap/TextureMapperImageBuffer.cpp:
8878         (WebCore::TextureMapperImageBuffer::drawSolidColor):
8879         (WebCore):
8880         * platform/graphics/texmap/TextureMapperImageBuffer.h:
8881
8882 2012-11-14  Mark Lam  <mark.lam@apple.com>
8883
8884         Fixed regressions due to adding JSEventListener::m_wrapper null checks.
8885         https://bugs.webkit.org/show_bug.cgi?id=102183.
8886
8887         Reviewed by Geoffrey Garen.
8888
8889         Fixed JSEventListener::operator==() to work within the contract that
8890         when m_wrapper is 0, m_jsFunction is also expected to be 0. Also fixed
8891         some typos in comments.
8892
8893         No new tests.
8894
8895         * bindings/js/JSEventListener.cpp:
8896         (WebCore::JSEventListener::visitJSFunction):
8897         (WebCore::JSEventListener::operator==):
8898         * bindings/js/JSEventListener.h:
8899         (WebCore::JSEventListener::jsFunction):
8900
8901 2012-11-14  Nate Chapin  <japhet@chromium.org>
8902
8903         Fix chromium asserts from r134649.
8904
8905         Rubber-stamped by Adam Barth.
8906
8907         MainResourceLoader was calling releaseResources() twice when cancelled
8908         within MainResourceLoader::load(), so check reachedTerminalState() before
8909         calling releaseResources() there.
8910
8911         * loader/MainResourceLoader.cpp:
8912         (WebCore::MainResourceLoader::load):
8913
8914 2012-11-14  Andreas Kling  <kling@webkit.org>
8915
8916         Only resolve presentation attribute style once per shared ElementAttributeData.
8917         <http://webkit.org/b/100990>
8918
8919         Reviewed by Antti Koivisto.
8920
8921         Track the "presentation attribute style dirty" state on ElementAttributeData instead of in a Node flag.
8922         This allows us to avoid duplicate work for ElementAttributeData that are shared between multiple elements,
8923         since the state is no longer per-Element.
8924
8925         I've left the presentation attribute cache in there for now, since it still covers the case where
8926         two elements have the same presentation attributes but different non-presentation attributes.
8927         It's likely that we're not gaining much from it anymore, but that's a topic for another patch.
8928
8929         (WebCore::StyledElement::rebuildPresentationAttributeStyle):
8930         * dom/StyledElement.h:
8931         (WebCore::StyledElement::presentationAttributeStyle):
8932         (WebCore::ElementAttributeData::ElementAttributeData):
8933         * dom/ElementAttributeData.h:
8934         (WebCore::ElementAttributeData::ElementAttributeData):
8935         (ElementAttributeData):
8936         * dom/Node.h:
8937
8938             Move presentation attribute style dirty flag from Node to ElementAttributeData.
8939
8940         * dom/ElementAttributeData.cpp:
8941         (SameSizeAsElementAttributeData):
8942
8943             Add a compile-time object size assertion for ElementAttributeData.
8944
8945         * dom/StyledElement.cpp:
8946         (WebCore::StyledElement::attributeChanged):
8947
8948             Don't mark the presentation attribute style dirty if the element is using an immutable (implies
8949             shared) ElementAttributeData and another element has already generated the StylePropertySet.
8950             The element itself is still marked for style recalc like before, this just avoids the process
8951             of converting the attributes to CSS properties.
8952
8953 2012-11-14  Scott Violet  <sky@chromium.org>
8954
8955         [Chromium] Refactor theme font lookup into a factory
8956         https://bugs.webkit.org/show_bug.cgi?id=101949
8957
8958         Reviewed by Tony Chang.
8959
8960         This will ultimately allow us to use what is currently in RenderThemeChromiumLinux on windows.
8961
8962         No new tests. Refactoring only.
8963
8964         * WebCore.gyp/WebCore.gyp:
8965         * WebCore.gypi:
8966         * rendering/RenderThemeChromiumFontProvider.cpp: Added.
8967         (WebCore):
8968         (WebCore::RenderThemeChromiumFontProvider::defaultGUIFont): Moved into RenderThemeFontProvider.
8969         * rendering/RenderThemeChromiumFontProvider.h: Added.
8970         (WTF):
8971         (WebCore):
8972         (RenderThemeChromiumFontProvider): This is the font related methods.
8973         * rendering/RenderThemeChromiumFontProviderLinux.cpp: Added.
8974         (WebCore):
8975         (WebCore::RenderThemeChromiumFontProvider::setDefaultFontSize): What was in RenderThemeChromiumSkia::setDefaultFontSize.
8976         (WebCore::RenderThemeChromiumFontProvider::systemFont): What was in RenderThemeChromiumSkia::systemFont.
8977         * rendering/RenderThemeChromiumFontProviderWin.cpp: Added.
8978         (WebCore):
8979         (WebCore::pointsToPixels): Moved from RenderThemeChromiumWin.
8980         (WebCore::getNonClientMetrics): Moved from RenderThemeChromiumWin.
8981         (WebCore::systemFontSize): Moved from RenderThemeChromiumWin.
8982         (WebCore::RenderThemeChromiumFontProvider::systemFont): Moved from RenderThemeChromiumWin.
8983         (WebCore::RenderThemeChromiumFontProvider::setDefaultFontSize): Moved from RenderThemeChromiumWin.
8984         * rendering/RenderThemeChromiumSkia.cpp:
8985         (WebCore::RenderThemeChromiumSkia::RenderThemeChromiumSkia): Moved into RenderThemeFontProvider.
8986         (WebCore::RenderThemeChromiumSkia::systemFont): Calls to RenderThemeChromiumFontProvider.
8987         (WebCore::RenderThemeChromiumSkia::setDefaultFontSize): Calls to RenderThemeChromiumFontProvider.
8988         * rendering/RenderThemeChromiumSkia.h:
8989         (RenderThemeChromiumSkia): Moves defaultFontSize into RenderThemeChromiumFontProvider.
8990         * rendering/RenderThemeChromiumWin.cpp: Moves font code into RenderThemeFontProviderWin.
8991         (WebCore):
8992         * rendering/RenderThemeChromiumWin.h: Removed overriden methods now handled by RenderThemeChromiumSkia.
8993         (RenderThemeChromiumWin):
8994
8995 2012-11-14  Erik Arvidsson  <arv@chromium.org>
8996
8997         Update DOMException name: InUseAttributeError
8998         https://bugs.webkit.org/show_bug.cgi?id=102141
8999
9000         Reviewed by Ojan Vafai.
9001
9002         Patch 10 of 25 to update DOMException name to match the spec and Firefox.
9003
9004         The name for this is not in the spec but the case was selected to match
9005         Firefox. http://mxr.mozilla.org/mozilla-central/source/dom/base/domerr.msg#18
9006
9007         INUSE_ATTRIBUTE_ERR is historical and not used in any spec or any of our tests.
9008
9009         * dom/DOMCoreException.cpp:
9010         * dom/ExceptionCode.h:
9011
9012 2012-11-14  Lynn Neir  <lynn.neir@skype.net>
9013
9014         [WinCairo] Incorrect line-height for styled menulist (select tag)
9015         in windows theme.
9016         https://bugs.webkit.org/show_bug.cgi?id=79435
9017
9018         Reviewed by Brent Fulgham
9019
9020         Applied same fix as in RenderThemeSafari::adjustMenuListButtonStyle
9021         to Windows theme to fix issue.
9022
9023         Tests: fast/forms/menulist-restrict-line-height.html
9024                fast/forms/control-restrict-line-height.html
9025                fast/forms/basic-selects.html
9026
9027         * rendering/RenderThemeWin.cpp:
9028         (WebCore::RenderThemeWin::adjustMenuListButtonStyle): Set line
9029         height to the correct initial height.
9030
9031 2012-11-14  Erik Arvidsson  <arv@chromium.org>
9032
9033         Update DOMException name: WrongDocumentError
9034         https://bugs.webkit.org/show_bug.cgi?id=102096
9035
9036         Reviewed by Ojan Vafai.
9037
9038         Patch 4 of 25 to update DOMException name to match the spec and Firefox.
9039
9040         Updated existing tests.
9041
9042         * dom/DOMCoreException.cpp:
9043
9044 2012-11-14  Nate Chapin  <japhet@chromium.org>
9045
9046         Move empty loading to DocumentLoader, simplify FrameLoader::init()
9047         https://bugs.webkit.org/show_bug.cgi?id=101512
9048
9049         Reviewed by Adam Barth.
9050
9051         No new tests, though several outputs changed because we no longer send resource
9052             load callbacks for empty loads.
9053
9054         * loader/DocumentLoader.cpp:
9055         (WebCore::DocumentLoader::startLoadingMainResource): Handle empty main resource
9056             loads directly here.
9057         * loader/DocumentLoader.h:
9058         * loader/FrameLoader.cpp:
9059         (WebCore::FrameLoader::FrameLoader): Initialize some variables whose values
9060             were previously being reset in init(). Given that the FrameLoader is in
9061             an inconsistent state before init() is called anyway, there doesn't seem
9062             to be a disadvantage to just initializing them to their post-init() values.
9063         (WebCore::FrameLoader::init): Just call startLoadingMainResource(), instead of
9064             doing a bunch of direct calls to functions FrameLoader shouldn't know about.
9065         * loader/FrameLoaderStateMachine.cpp:
9066         * loader/FrameLoaderStateMachine.h:
9067         * loader/MainResourceLoader.cpp: Throughout, remove the concept of an empty load.
9068         (WebCore::MainResourceLoader::loadNow): This only returned true when an empty
9069             load got deferred, which won't happen now. Return void and always treat
9070             as returning false.
9071         * loader/MainResourceLoader.h:
9072
9073 2012-11-14  Erik Arvidsson  <arv@chromium.org>
9074
9075         Update DOMException name: InvalidStateError
9076         https://bugs.webkit.org/show_bug.cgi?id=102241
9077
9078         Reviewed by Ojan Vafai.
9079
9080         Patch 11 of 25 to update DOMException name to match the spec and Firefox.
9081
9082         Updated existing tests.
9083
9084         * dom/DOMCoreException.cpp:
9085
9086 2012-11-14  Joshua Bell  <jsbell@chromium.org>
9087
9088         Rename NATIVE_TYPE_ERR to TypeError
9089         https://bugs.webkit.org/show_bug.cgi?id=102114
9090
9091         Reviewed by Kentaro Hara.
9092
9093         Defines names (mostly) matching WebIDL exception types for use by dom (etc) code.
9094         V8 binding code had colliding enum members, which required prefixing.
9095
9096         No new tests - just internal renames.
9097
9098         * Modules/indexeddb/IDBCursor.cpp: s/NATIVE_TYPE_ERR/TypeError/g
9099         (WebCore::IDBCursor::advance):
9100         (WebCore::IDBCursor::stringToDirection):
9101         (WebCore::IDBCursor::directionToString):
9102         * Modules/indexeddb/IDBDatabase.cpp: Ditto.
9103         (WebCore::IDBDatabase::setVersion):
9104         * Modules/indexeddb/IDBFactory.cpp: Ditto.
9105         (WebCore::IDBFactory::open):
9106         (WebCore::IDBFactory::openInternal):
9107         (WebCore::IDBFactory::deleteDatabase):
9108         * Modules/indexeddb/IDBObjectStore.cpp: Ditto.
9109         (WebCore::IDBObjectStore::createIndex):
9110         * Modules/indexeddb/IDBTransaction.cpp: Ditto.
9111         (WebCore::IDBTransaction::stringToMode):
9112         (WebCore::IDBTransaction::modeToString):
9113         * bindings/js/JSDOMBinding.cpp: Ditto.
9114         (WebCore::setDOMException):
9115         * bindings/v8/DateExtension.cpp: Prefix ErrorType enum/members w/ V8/v8.
9116         (WebCore::DateExtension::OnSleepDetected):
9117         * bindings/v8/NPV8Object.cpp: Ditto.
9118         (_NPN_SetException):
9119         * bindings/v8/V8Binding.cpp: Ditto.
9120         (WebCore::throwError):
9121         (WebCore::handleMaxRecursionDepthExceeded):
9122         * bindings/v8/V8Binding.h: Ditto.
9123         (WebCore):
9124         * bindings/v8/V8NPObject.cpp: Ditto.
9125         (WebCore::npObjectInvokeImpl):
9126         (WebCore::npObjectGetProperty):
9127         (WebCore::npObjectSetProperty):
9128         (WebCore::npObjectPropertyEnumerator):
9129         * bindings/v8/V8ThrowException.cpp: Rename ALL the errors!
9130         (WebCore::V8ThrowException::setDOMException):
9131         (WebCore::V8ThrowException::throwError):
9132         (WebCore::V8ThrowException::throwTypeError):
9133         (WebCore::V8ThrowException::throwNotEnoughArgumentsError):
9134         * bindings/v8/V8ThrowException.h:
9135         (V8ThrowException):
9136         * bindings/v8/WorkerContextExecutionProxy.cpp: Prefixing (continued)
9137         (WebCore::WorkerContextExecutionProxy::evaluate):
9138         * bindings/v8/custom/V8ArrayBufferCustom.cpp: Ditto.
9139         (WebCore::V8ArrayBuffer::constructorCallback):
9140         * bindings/v8/custom/V8ArrayBufferViewCustom.h: Ditto.
9141         (WebCore::constructWebGLArrayWithArrayBufferArgument):
9142         (WebCore::constructWebGLArray):
9143         (WebCore::setWebGLArrayHelper):
9144         * bindings/v8/custom/V8AudioContextCustom.cpp: Ditto.
9145         (WebCore::V8AudioContext::constructorCallback):
9146         * bindings/v8/custom/V8BlobCustom.cpp: Ditto.
9147         (WebCore::V8Blob::constructorCallback):
9148         * bindings/v8/custom/V8ClipboardCustom.cpp: Ditto.
9149         (WebCore::V8Clipboard::clearDataCallback):
9150         (WebCore::V8Clipboard::setDragImageCallback):
9151         * bindings/v8/custom/V8DOMFormDataCustom.cpp: Ditto.
9152         (WebCore::V8DOMFormData::appendCallback):
9153         * bindings/v8/custom/V8SQLResultSetRowListCustom.cpp: Ditto.
9154         (WebCore::V8SQLResultSetRowList::itemCallback):
9155         * dom/ExceptionCode.h: Add WebIDL exception types.
9156
9157 2012-11-14  Tiancheng Jiang  <tijiang@rim.com>
9158
9159         [BlackBerry] Style BB10 time input field font.
9160         https://bugs.webkit.org/show_bug.cgi?id=102260.
9161
9162         Reviewed by Rob Buis.
9163
9164         RIM PR 243355
9165         Adjust time input field font using BB10 system default font.
9166
9167         * css/themeBlackBerry.css:
9168         (input[type="date"], input[type="datetime"], input[type="datetime-local"], input[type="time"], input[type="month"]):
9169
9170 2012-11-14  Li Yin  <li.yin@intel.com>
9171
9172         createDelay should raise exception when the maxDelayTime parameter is incorrect.
9173         https://bugs.webkit.org/show_bug.cgi?id=102173
9174
9175         Reviewed by Chris Rogers.
9176
9177         Spec: https://dvcs.w3.org/hg/audio/raw-file/tip/webaudio/specification.html
9178         The specified value must be greater than zero and less than three minutes or a
9179         NOT_SUPPORTED_ERR exception will be thrown.
9180
9181         Tests: webaudio/delaynode-maxdelaylimit.html
9182
9183         * Modules/webaudio/AudioContext.cpp:
9184         (WebCore::AudioContext::createDelay):
9185         * Modules/webaudio/AudioContext.h:
9186         (AudioContext):
9187         * Modules/webaudio/AudioContext.idl: Add raising exception for createDelay.
9188         * Modules/webaudio/DelayNode.cpp:
9189         (WebCore):
9190         (WebCore::DelayNode::DelayNode):
9191         * Modules/webaudio/DelayNode.h:
9192         (WebCore::DelayNode::create):
9193         (DelayNode):
9194
9195 2012-11-14  Simon Fraser  <simon.fraser@apple.com>
9196
9197         Don't pass a paintingRoot when painting from RenderLayerBacking
9198         https://bugs.webkit.org/show_bug.cgi?id=102256
9199
9200         Reviewed by David Hyatt.
9201
9202         The 'paintingRoot' parameter to the RenderLayer paint functions
9203         is used when painting just a subtree (e.g. when painting dragged
9204         selections). There is no need to pass it when a RenderLayerBacking
9205         paints its contents or overlay scrollbars.
9206         
9207         Passing it requires an expensive isDescendant() check, so passing
9208         null is more efficient.
9209         
9210         * rendering/RenderLayer.h:
9211         (WebCore::RenderLayer::LayerPaintingInfo::LayerPaintingInfo):
9212         * rendering/RenderLayerBacking.cpp:
9213         (WebCore::RenderLayerBacking::paintIntoLayer):
9214         (WebCore::RenderLayerBacking::paintContents):
9215         * rendering/RenderLayerBacking.h:
9216         (RenderLayerBacking):
9217
9218 2012-11-14  Alec Flett  <alecflett@chromium.org>
9219
9220         Add DOMRequestState to maintain world/ScriptExecutionContext state
9221         https://bugs.webkit.org/show_bug.cgi?id=102102
9222
9223         Reviewed by Adam Barth.
9224
9225         Introduce DOMRequestState, and convert IndexedDB over.
9226
9227         No new tests, this is an abstraction layer for existing code.
9228
9229         * Modules/indexeddb/IDBRequest.cpp:
9230         (WebCore::IDBRequest::IDBRequest):
9231         (WebCore::IDBRequest::onSuccess):
9232         (WebCore::IDBRequest::dispatchEvent):
9233         * Modules/indexeddb/IDBRequest.h:
9234         (IDBRequest):
9235         * WebCore.gypi:
9236         * bindings/v8/DOMRequestState.h: Added.
9237         (WebCore):
9238         (DOMRequestState):
9239         (WebCore::DOMRequestState::DOMRequestState):
9240         (Scope):
9241         (WebCore::DOMRequestState::Scope::Scope):
9242         (WebCore::DOMRequestState::scope):
9243
9244 2012-11-14  Justin Novosad  <junov@google.com>
9245
9246         Boxes with rounded corners and thin borders are too slow to draw
9247         https://bugs.webkit.org/show_bug.cgi?id=101974
9248
9249         Reviewed by Simon Fraser.
9250
9251         With the current implementation RenderBox::
9252         determineBackgroundBleedAvoidance() uses the slow path
9253         BackgroundBleedUseTransparencyLayer for some very common use cases,
9254         notably for drawing rectangles with rounded corners that have thin
9255         borders. This is because the BackgroundBleedShrinkBackground
9256         strategy requires a border at least two pixels wide on all sides. This
9257         patch introduce drawing strategy BackgroundBleedBackgroundOverBorder.
9258         This approach consists in drawing the border first, with an inset inner
9259         edge (for anti-aliased compositing to work well).  This approach only
9260         works with opaque solid edges and opaque single-layer backgrounds.
9261         By using this approach rather than BackgroundBleedUseTransparencyLayer,
9262         we save two clipPath, one save and one saveLayer on the
9263         GraphicsContext. This patch gets good coverage from existing layout
9264         tests. One additional test was added to exercise mitring, thick edges
9265         and anti-aliasing edge cases under the new painting algorithm.
9266
9267         Test: fast/borders/border-radius-wide-border-05.html
9268
9269         * rendering/RenderBox.cpp:
9270         (WebCore::RenderBox::determineBackgroundBleedAvoidance):
9271         Added selection criteria for BackgroundOverBorder
9272         (WebCore::RenderBox::paintBoxDecorations):
9273         Added a preliminary paintBorder pass for BackgroundOverBorder
9274         (WebCore::RenderBox::paintBackground):
9275         Insetting the background to to innerBorder when bleedAvoidance is
9276         BackgroundOverBorder.  This why BackgroundOverBorder only works for
9277         Opaque solid edges.
9278         (WebCore):
9279         (WebCore::RenderBox::backgroundIsSingleOpaqueLayer):
9280         Utility method use by determineBackgroundBleedAvoidance to test the
9281         background's eligibility for BackgroundOverBorder bleed avoidance
9282         strategy.  The reason the background must be a single layer is to avoid
9283         color bleeding from layer compositing along anti-aliased edges
9284         * rendering/RenderBox.h:
9285         (RenderBox):
9286         * rendering/RenderBoxModelObject.cpp:
9287         (WebCore::RenderBoxModelObject::getBackgroundRoundedRect):
9288         (WebCore::RenderBoxModelObject::borderInnerRectAdjustedForBleedAvoidance):
9289         Added support for BackgroundOverBorder by applying a one pixel inset.
9290         (WebCore::RenderBoxModelObject::backgroundRoundedRectAdjustedForBleedAvoidance):
9291         Set the background rect to the inner border for BackgroundOverBorder
9292         (WebCore):
9293         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
9294         Added support for BackgroundOverBorder by using 
9295         backgroundRoundedRectAdjustedForBleedAvoidance
9296         (WebCore::RenderBoxModelObject::paintBorderSides):
9297         Added support for BackgroundOverBorder by applying per-side inset
9298         adjustments.
9299         (WebCore::RenderBoxModelObject::paintTranslucentBorderSides):
9300         (WebCore::RenderBoxModelObject::paintBorder):
9301         Added support for BackgroundOverBorder by using an adjusted inner
9302         border, but not if sides are painted individually.
9303         * rendering/RenderBoxModelObject.h:
9304         (RenderBoxModelObject):
9305
9306 2012-11-14  Hideki Yoshida  <yoshida-hxa@necst.nec.co.jp>
9307
9308         [WinCairo] Fix cairo_t* memory leak in GraphicsContext::platformInit
9309         https://bugs.webkit.org/show_bug.cgi?id=76219
9310
9311         Reviewed by Brent Fulgham.
9312
9313         This patch is to fix a memory leak problem which occurs
9314         in every rendering process on Wincairo port.
9315         By applying this patch, the memory allocated in cairo 
9316         library will be released by calling cairo_destroy.
9317
9318         * platform/graphics/win/GraphicsContextCairoWin.cpp:
9319         (WebCore::GraphicsContext::platformInit):
9320
9321 2012-11-14  Sami Kyostila  <skyostil@chromium.org>
9322
9323         Optimize painting of composited scrolling layers
9324         https://bugs.webkit.org/show_bug.cgi?id=96087
9325
9326         Reviewed by Simon Fraser.
9327
9328         Don't completely repaint accelerated scrolling layers when the scroll offset
9329         changes.
9330
9331         Test: compositing/overflow/scrolling-without-painting.html
9332
9333         * platform/graphics/GraphicsLayer.cpp:
9334         (WebCore::GraphicsLayer::setOffsetFromRenderer):
9335         * platform/graphics/GraphicsLayer.h:
9336         (GraphicsLayer):
9337         * rendering/RenderLayerBacking.cpp:
9338         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
9339
9340 2012-11-14  Pavel Feldman  <pfeldman@chromium.org>
9341
9342         Web Inspector: keep track of mutation observers and disconnect them upon upload
9343         https://bugs.webkit.org/show_bug.cgi?id=102239
9344
9345         Reviewed by Vsevolod Vlasov.
9346
9347         Otherwise we hit memory leaks.
9348
9349         * inspector/front-end/DefaultTextEditor.js:
9350         (WebInspector.DefaultTextEditor.prototype.wasShown):
9351         (WebInspector.DefaultTextEditor.prototype.willHide):
9352         (WebInspector.TextEditorMainPanel.prototype._wasShown):
9353         (WebInspector.TextEditorMainPanel.prototype._willHide):
9354         (WebInspector.TextEditorMainPanel.prototype._attachMutationObserver):
9355         (WebInspector.TextEditorMainPanel.prototype._detachMutationObserver):
9356         * inspector/front-end/utilities.js:
9357
9358 2012-11-14  Sergio Villar Senin  <svillar@igalia.com>
9359
9360         [Qt] Use a node image if there is no drag image set for Drag&Drop
9361         https://bugs.webkit.org/show_bug.cgi?id=102124
9362
9363         Reviewed by Simon Hausmann.
9364
9365         Use the nodeImage provided by the frame if there is no dragImage in
9366         the clipboard for the current drag&drop operation.
9367
9368         * platform/qt/ClipboardQt.cpp:
9369         (WebCore::ClipboardQt::createDragImage):
9370
9371 2012-11-14  Max Vujovic  <mvujovic@adobe.com>
9372
9373         Call to enclosingFilterLayer() in RenderObject::containerForRepaint() is expensive
9374         https://bugs.webkit.org/show_bug.cgi?id=101846
9375
9376         Reviewed by Simon Fraser.
9377
9378         If software-rendered CSS Filters have not been used in the document, avoid doing the second
9379         tree walk in RenderObject::containerForRepaint, which determines the RenderObject's
9380         enclosing filter layer.
9381
9382         No new tests. We now avoid a filters related code path for a performance improvement when
9383         we're not using filters.
9384
9385         * page/FrameView.cpp:
9386         (WebCore::FrameView::FrameView):
9387         * page/FrameView.h:
9388         (FrameView):
9389         (WebCore::FrameView::setHasSoftwareFilters):
9390         (WebCore::FrameView::hasSoftwareFilters):
9391         * rendering/RenderLayer.cpp:
9392         (WebCore::RenderLayer::updateOrRemoveFilterEffectRenderer):
9393         * rendering/RenderObject.cpp:
9394         (WebCore::RenderObject::containerForRepaint):
9395
9396 2012-11-14  Erik Arvidsson  <arv@chromium.org>
9397
9398         Update DOMException name: NotFoundError
9399         https://bugs.webkit.org/show_bug.cgi?id=102137
9400
9401         Reviewed by Ojan Vafai.
9402
9403         Patch 8 of 25 to update DOMException name to match the spec and Firefox.
9404
9405         Updated existing tests.
9406
9407         * dom/DOMCoreException.cpp:
9408
9409 2012-11-14  Otto Derek Cheung  <otcheung@rim.com>
9410
9411         [BlackBerry] Updating BB Cookie database to use WAL
9412         https://bugs.webkit.org/show_bug.cgi?id=102237
9413
9414         Reviewed by Rob Buis.
9415
9416         The cookie database is accessed by one process only and should be updated to
9417         use the WAL journal mode for better I/O performance.
9418
9419         PR 236553
9420
9421         cookieCollection.db-wal is created after the conversion to WAL.
9422         Tested cookie persistence by logging on to random sites and restarting the browser and
9423         check if it automatically logs in.
9424         Also tested using Opera's cookie persistence test.
9425
9426         * platform/blackberry/CookieDatabaseBackingStore/CookieDatabaseBackingStore.cpp:
9427         (WebCore::CookieDatabaseBackingStore::invokeOpen):
9428
9429 2012-11-14  Erik Arvidsson  <arv@chromium.org>
9430
9431         Update DOMException name: IndexSizeError
9432         https://bugs.webkit.org/show_bug.cgi?id=102087
9433
9434         Reviewed by Ojan Vafai.
9435
9436         This is the first in a series of updates to DOMException name to match
9437         the spec and Firefox.
9438
9439         Patch 1 of 25
9440
9441         Updated existing tests.
9442
9443         * dom/DOMCoreException.cpp:
9444         (WebCore):
9445
9446 2012-11-14  Gabor Rapcsanyi  <rgabor@webkit.org>
9447
9448         Fix [-Wmissing-braces] warnings in graphics/cpu/arm/GraphicsContext3DNEON.h
9449         https://bugs.webkit.org/show_bug.cgi?id=102205
9450
9451         Reviewed by Csaba Osztrogonác.
9452
9453         Fixing some warnings in GraphicsContext3DNEON.h which have been caused by missing braces.
9454
9455         * platform/graphics/cpu/arm/GraphicsContext3DNEON.h:
9456         (WebCore::ARM::unpackOneRowOfRGBA4444ToRGBA8NEON):
9457         (WebCore::ARM::unpackOneRowOfRGBA5551ToRGBA8NEON):
9458         (WebCore::ARM::unpackOneRowOfRGB565ToRGBA8NEON):
9459
9460 2012-11-14  Erik Arvidsson  <arv@chromium.org>
9461
9462         Update DOMException name: NoDataAllowedError
9463         https://bugs.webkit.org/show_bug.cgi?id=102132
9464
9465         Reviewed by Darin Adler.
9466
9467         Patch 6 of 25 to update DOMException name to match the spec and Firefox.
9468
9469         NO_DATA_ALLOWED_ERR is historical and not used in any spec or in our code.
9470
9471         * dom/DOMCoreException.cpp:
9472         (WebCore):
9473         * dom/ExceptionCode.h:
9474
9475 2012-11-14  Pavel Feldman  <pfeldman@chromium.org>
9476
9477         Web Inspector: "Reveal in Element Panel" doesn't work if Elements panel hasn't been opened
9478         https://bugs.webkit.org/show_bug.cgi?id=102219
9479
9480         Reviewed by Alexander Pavlov.
9481
9482         Force elements module load upon context menu invocation.
9483
9484         * inspector/front-end/ElementsTreeOutline.js:
9485         (WebInspector.ElementsTreeOutline.prototype._contextMenuEventFired.focusElement):
9486         (WebInspector.ElementsTreeOutline.prototype._contextMenuEventFired):
9487
9488 2012-11-14  Sheriff Bot  <webkit.review.bot@gmail.com>
9489
9490         Unreviewed, rolling out r134523.
9491         http://trac.webkit.org/changeset/134523
9492         https://bugs.webkit.org/show_bug.cgi?id=102218
9493
9494         brake chrome windows build, as it references a non existing
9495         header js/DOMRequestState.h (Requested by jochen__ on
9496         #webkit).
9497
9498         * Modules/indexeddb/IDBCursor.cpp:
9499         (WebCore::IDBCursor::setValueReady):
9500         * Modules/indexeddb/IDBCursor.h:
9501         (IDBCursor):
9502         * Modules/indexeddb/IDBRequest.cpp:
9503         (WebCore::IDBRequest::IDBRequest):
9504         (WebCore::IDBRequest::onSuccess):
9505         (WebCore::IDBRequest::stop):
9506         (WebCore::IDBRequest::dispatchEvent):
9507         * Modules/indexeddb/IDBRequest.h:
9508         (IDBRequest):
9509         * WebCore.gypi:
9510         * bindings/v8/DOMRequestState.h: Removed.
9511         * bindings/v8/IDBBindingUtilities.cpp:
9512         (WebCore::deserializeIDBValue):
9513         (WebCore::idbKeyToScriptValue):
9514         * bindings/v8/IDBBindingUtilities.h:
9515         (WebCore):
9516
9517 2012-11-14  Anton Obzhirov  <a.obzhirov@samsung.com>
9518
9519         Add platform implementation of remote web inspector server for GTK port.
9520         https://bugs.webkit.org/show_bug.cgi?id=88094 
9521
9522         Reviewed by Gustavo Noronha Silva.
9523
9524         Extra SocketStreamHandle constructor is added to accept existing GSocketConnection.
9525         Needed to pass remote inspector server socket connection. The change is tested with 
9526         inspector server API tests.
9527
9528         * platform/network/soup/SocketStreamHandle.h:
9529         (WebCore::SocketStreamHandle::create):
9530         (SocketStreamHandle):
9531         * platform/network/soup/SocketStreamHandleSoup.cpp:
9532         (WebCore::SocketStreamHandle::SocketStreamHandle):
9533         (WebCore):
9534         (WebCore::SocketStreamHandle::connected):
9535         (WebCore::SocketStreamHandle::platformSend):
9536         (WebCore::SocketStreamHandle::platformClose):
9537
9538 2012-11-14  Pavel Feldman  <pfeldman@chromium.org>
9539
9540         Web Inspector: context menu on ObjectPropertyTreeElement's values is masked by the section.
9541         https://bugs.webkit.org/show_bug.cgi?id=102212
9542
9543         Reviewed by Vsevolod Vlasov.
9544
9545         * inspector/front-end/ObjectPropertiesSection.js:
9546         (WebInspector.ObjectPropertiesSection.prototype.enableContextMenu):
9547
9548 2012-11-09  Ilya Tikhonovsky  <loislo@chromium.org>
9549
9550         Web Inspector: NMI add instrumentation for WebAudo related stuff.
9551         They use about 16Mb for shared data on pages with webaudio.
9552         As example Angry Birds app.
9553         https://bugs.webkit.org/show_bug.cgi?id=101729
9554
9555         Reviewed by Yury Semikhatsky.
9556
9557         Plain vanilla instrumentation for audio and webaudio classes.
9558         AudioContext is a kind of ActiveDOMObject. I found that these objects
9559         are accessible through ScriptExecutuionContext and ScriptExecutionContext
9560         is an ancestor of Document. Document class was instrumented earler.
9561         I instrumented ActiveDOMObject, ScriptExecutionContext and other ancestors
9562         and now AudioContext and other ActiveDOMObjects are reacheable from Document.
9563
9564         Test: inspector-protocol/nmi-webaudio.html
9565
9566         * Modules/webaudio/AudioContext.cpp:
9567         (WebCore::AudioContext::reportMemoryUsage):
9568         (WebCore):
9569         * Modules/webaudio/AudioContext.h:
9570         (AudioContext):
9571         * Modules/webaudio/AudioNode.cpp:
9572         (WebCore::AudioNode::reportMemoryUsage):
9573         (WebCore):
9574         * Modules/webaudio/AudioNode.h:
9575         (AudioNode):
9576         * dom/ActiveDOMObject.cpp:
9577         (WebCore::ActiveDOMObject::reportMemoryUsage):
9578         (WebCore):
9579         * dom/ActiveDOMObject.h:
9580         (ActiveDOMObject):
9581         * dom/Document.cpp:
9582         (WebCore::Document::reportMemoryUsage):
9583         * dom/ScriptExecutionContext.cpp:
9584         (WebCore::ScriptExecutionContext::reportMemoryUsage):
9585         (WebCore):
9586         * dom/ScriptExecutionContext.h:
9587         (ScriptExecutionContext):
9588         * dom/SecurityContext.cpp:
9589         (WebCore::SecurityContext::reportMemoryUsage):
9590         (WebCore):
9591         * dom/SecurityContext.h:
9592         (SecurityContext):
9593         * dom/WebCoreMemoryInstrumentation.cpp:
9594         (WebCore):
9595         * dom/WebCoreMemoryInstrumentation.h:
9596         (WebCoreMemoryTypes):
9597         * platform/audio/AudioArray.h:
9598         (AudioArray):
9599         (WebCore::AudioArray::reportMemoryUsage):
9600         * platform/audio/FFTFrame.cpp:
9601         (WebCore::FFTFrame::reportMemoryUsage):
9602         (WebCore):
9603         * platform/audio/FFTFrame.h:
9604         (FFTFrame):
9605         * platform/audio/HRTFDatabase.cpp:
9606         (WebCore::HRTFDatabase::reportMemoryUsage):
9607         (WebCore):
9608         * platform/audio/HRTFDatabase.h:
9609         (HRTFDatabase):
9610         * platform/audio/HRTFDatabaseLoader.cpp:
9611         (WebCore::HRTFDatabaseLoader::reportMemoryUsage):
9612         (WebCore):
9613         * platform/audio/HRTFDatabaseLoader.h:
9614         (HRTFDatabaseLoader):
9615         * platform/audio/HRTFElevation.cpp:
9616         (WebCore::HRTFElevation::reportMemoryUsage):
9617         (WebCore):
9618         * platform/audio/HRTFElevation.h:
9619         (HRTFElevation):
9620         * platform/audio/HRTFKernel.cpp:
9621         (WebCore::HRTFKernel::reportMemoryUsage):
9622         (WebCore):
9623         * platform/audio/HRTFKernel.h:
9624         (HRTFKernel):
9625
9626 2012-11-14  Eugene Klyuchnikov  <eustas.bug@gmail.com>
9627
9628         Web Inspector: Settings screen: close button overlays view title on mac.
9629         https://bugs.webkit.org/show_bug.cgi?id=102198
9630
9631         Reviewed by Pavel Feldman.
9632
9633         Added margin-left for mac. Adjusted title height and vertical positioning.
9634
9635         * inspector/front-end/helpScreen.css:
9636         (.help-window-caption): Adjusted title height.
9637         (.help-window-title): Adjusted title vertical positioning. 
9638         (body.platform-mac .help-window-main .help-window-title): Fixed margin.
9639
9640 2012-11-13  Pavel Feldman  <pfeldman@chromium.org>
9641
9642         Web Inspector: use last selection as complementary signal when applying DOM changes to the text model.
9643         https://bugs.webkit.org/show_bug.cgi?id=101905
9644
9645         Reviewed by Vsevolod Vlasov.
9646
9647         Currently we use heuristics for detecting damaged model range upon DOM mutation.
9648         This change adds signals from the last selection and keyboard events in order to
9649         further improve the heuristics quality.
9650
9651         * inspector/front-end/DefaultTextEditor.js:
9652         (WebInspector.DefaultTextEditor):
9653         (WebInspector.DefaultTextEditor.EditInfo):
9654         (WebInspector.DefaultTextEditor.prototype._handleTextInput):
9655         (WebInspector.DefaultTextEditor.prototype._handleKeyDown):
9656         (WebInspector.DefaultTextEditor.prototype.lastSelection):
9657         (WebInspector.DefaultTextEditor.prototype.wasShown):
9658         (WebInspector.TextEditorMainPanel.prototype._applyDomUpdates):
9659         (WebInspector.TextEditorMainPanel.prototype._guessEditRangeBasedOnSelection):
9660         (WebInspector.TextEditorMainPanel.prototype._guessEditRangeBasedOnDiff):
9661         (WebInspector.TextEditorMainPanel.prototype._closingBlockOffset):
9662         (WebInspector.TextEditorMainPanel.prototype._handleSelectionChange):
9663         * inspector/front-end/TextEditorModel.js:
9664         (WebInspector.TextRange.prototype.compareTo):
9665         (WebInspector.TextRange.prototype.shift):
9666         (WebInspector.TextEditorModel.endsWithBracketRegex.):
9667
9668 2012-11-14  Dan Carney  <dcarney@google.com>
9669
9670         [V8] use toV8Fast in all relevant Node getters
9671         https://bugs.webkit.org/show_bug.cgi?id=100851
9672
9673         Reviewed by Kentaro Hara.
9674
9675         The toV8Fast function for Node objects is now called in all getters
9676         instead of toV8.
9677
9678         No new tests. Test coverage extensive.
9679
9680         * bindings/scripts/CodeGeneratorV8.pm:
9681         (GenerateHeader):
9682         (GenerateNormalAttrGetter):
9683         (IsDOMNodeType):
9684         * bindings/scripts/test/V8/V8TestNode.h:
9685         (WebCore::toV8Fast):
9686
9687 2012-11-14  Kenneth Rohde Christiansen  <kenneth@webkit.org>
9688
9689         Clean up use of adjustWindowRect
9690         https://bugs.webkit.org/show_bug.cgi?id=102072
9691
9692         Reviewed by Gyuyoung Kim.
9693
9694         Tested by fast/dom/Window/open-window-min-size.html
9695
9696         * loader/FrameLoader.cpp:
9697         (WebCore::createWindow):
9698
9699             Validate the window size here so that it is not just done for
9700             .open, but also for .showModalDialog. This is compatible with
9701             other browsers such as IE and Firefox (though IE > 6, enforces
9702             a minimum width of 250 instead of 100 as Firefox and us.)
9703
9704         * page/DOMWindow.cpp:
9705         (WebCore):
9706         (WebCore::DOMWindow::adjustWindowRect):
9707
9708             Make it a static method which only takes page. It was never
9709             called from anywhere without a valid page, so the page check
9710             has been turned into an assert, and two of the arguments have
9711             been removed as they can be accessed via the page.
9712
9713         (WebCore::DOMWindow::moveBy):
9714         (WebCore::DOMWindow::moveTo):
9715         (WebCore::DOMWindow::resizeBy):
9716         (WebCore::DOMWindow::resizeTo):
9717
9718             Update use of adjustWindowRect.
9719
9720         (WebCore::DOMWindow::open):
9721
9722             Avoid modifying the WindowFeatures as the WebCore::createWindow
9723             validates and adjusts the arguments.
9724
9725         * page/DOMWindow.h:
9726         (DOMWindow):
9727
9728 2012-11-14  Takashi Sakamoto  <tasak@google.com>
9729
9730         Crash when replacing parts of text inputs with content: url(...)
9731         https://bugs.webkit.org/show_bug.cgi?id=101133
9732
9733         Reviewed by Kent Tamura.
9734
9735         Disable directly setting content of elements in an input element's
9736         shadow dom tree, because the setting breaks input element's behavior.
9737
9738         Tests: fast/forms/number/number-content-url-crash.html
9739                fast/forms/search/search-content-url-crash.html
9740
9741         * css/html.css:
9742         (input::-webkit-textfield-decoration-container):
9743         Use important to disable overriding an input element's content
9744         property.
9745         * html/TextFieldInputType.cpp:
9746         (WebCore::TextFieldInputType::attach):
9747         Added ASSERTION. No content should be applied to
9748         input::-webkit-textfield-decoration-container.
9749
9750 2012-11-14  Kentaro Hara  <haraken@chromium.org>
9751
9752         Unreviewed. Rebaselined run-bindings-tests results.
9753
9754         * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
9755         (WebCore::V8TestOverloadedConstructors::constructor1Callback):
9756         (WebCore::V8TestOverloadedConstructors::constructor2Callback):
9757         (WebCore::V8TestOverloadedConstructors::constructor3Callback):
9758         (WebCore::V8TestOverloadedConstructors::constructor4Callback):
9759         (WebCore::V8TestOverloadedConstructors::wrapSlow):
9760
9761 2012-11-14  Anton Muhin  <antonm@chromium.org>
9762
9763         Provide return types for custom WebGLRenderingContext methods
9764         https://bugs.webkit.org/show_bug.cgi?id=100777
9765
9766         Reviewed by Kenneth Russell.
9767
9768         No new tests as doesn't change generated code.
9769
9770         * html/canvas/WebGLRenderingContext.idl:
9771
9772 2012-11-14  Kent Tamura  <tkent@chromium.org>
9773
9774         Support for localization tests of calendar picker
9775         https://bugs.webkit.org/show_bug.cgi?id=102181
9776
9777         Reviewed by Kentaro Hara.
9778
9779         Introduce DateTimeChooserParameters::locale to inform locale to
9780         DateTimeChooser implementations. However we pass defaultLanguage
9781         unless tests calls internals.settings.
9782         setLangAttributeAwareFormControlUIEnabled(true) explicitly.
9783
9784         Test: platform/chromium/fast/forms/calendar-picker/calendar-picker-appearance-ru.html
9785
9786         * html/HTMLInputElement.cpp:
9787         (WebCore::HTMLInputElement::setupDateTimeChooserParameters):
9788         Set DateTimeChooserParameters::locale up.
9789         * platform/DateTimeChooser.h:
9790         (DateTimeChooserParameters): Add 'locale' member.
9791
9792 2012-11-14  Pavel Feldman  <pfeldman@chromium.org>
9793
9794         Web Inspector: highlight is not updating as one edits CSS properties
9795         https://bugs.webkit.org/show_bug.cgi?id=102191
9796
9797         Reviewed by Alexander Pavlov.
9798
9799         We should update highlight upon layout / style recalculation.
9800
9801         * inspector/InspectorInstrumentation.cpp:
9802         (WebCore):
9803         (WebCore::InspectorInstrumentation::didRecalculateStyleImpl):
9804         * inspector/InspectorPageAgent.cpp:
9805         (WebCore::InspectorPageAgent::InspectorPageAgent):
9806         (WebCore::InspectorPageAgent::enable):
9807         (WebCore::InspectorPageAgent::disable):
9808         (WebCore::InspectorPageAgent::domContentEventFired):
9809         (WebCore::InspectorPageAgent::didPaint):
9810         (WebCore::InspectorPageAgent::didLayout):
9811         (WebCore::InspectorPageAgent::didScroll):
9812         (WebCore):
9813         (WebCore::InspectorPageAgent::didRecalculateStyle):
9814         * inspector/InspectorPageAgent.h:
9815
9816 2012-11-14  Sheriff Bot  <webkit.review.bot@gmail.com>
9817
9818         Unreviewed, rolling out r134566.
9819         http://trac.webkit.org/changeset/134566
9820         https://bugs.webkit.org/show_bug.cgi?id=102197
9821
9822         "it broke Chromium Android Release build" (Requested by
9823         haraken on #webkit).
9824
9825         * html/HTMLInputElement.cpp:
9826         (WebCore::HTMLInputElement::setupDateTimeChooserParameters):
9827         * platform/DateTimeChooser.h:
9828         (DateTimeChooserParameters):
9829
9830 2012-11-08  Vsevolod Vlasov  <vsevik@chromium.org>
9831
9832         Web Inspector: No content available for requests made from flash
9833         https://bugs.webkit.org/show_bug.cgi?id=101560
9834
9835         Reviewed by Pavel Feldman.
9836
9837         Network request data is now saved to inspector cache in following cases:
9838          - Error status code;
9839          - No cached resource available;
9840          - Cached resource has ShouldNotBufferData option set.
9841         Drive-by: refactored didReceiveResponse logic to be clearer.
9842
9843         * inspector/InspectorResourceAgent.cpp:
9844         (WebCore::InspectorResourceAgent::didReceiveResponse):
9845         (WebCore::InspectorResourceAgent::didReceiveData):
9846         * loader/cache/CachedResource.h:
9847         (WebCore::CachedResource::shouldBufferData):
9848
9849 2012-11-14  Shinya Kawanaka  <shinyak@chromium.org>
9850
9851         Changing pseudoClass (:target) should cause distribution
9852         https://bugs.webkit.org/show_bug.cgi?id=101699
9853
9854         Reviewed by Hajime Morita.
9855
9856         When cssTarget element is changed, we might have to invalidate distribution. We check its necessity
9857         by consulting with SelectRuleFeatureSet.
9858
9859         We also implement invalidateParentDistributionIfNecessary for all collected features in this patch.
9860
9861         Test: fast/dom/shadow/pseudoclass-update-target.html
9862
9863         * dom/Document.cpp:
9864         (WebCore::Document::setCSSTarget):
9865         * dom/ElementShadow.cpp:
9866         (WebCore::invalidateParentDistributionIfNecessary):
9867         (WebCore):
9868         * dom/ElementShadow.h:
9869         (WebCore):
9870         * html/shadow/SelectRuleFeatureSet.h:
9871         (WebCore::SelectRuleFeatureSet::hasSelectorFor):
9872         (SelectRuleFeatureSet):
9873
9874 2012-11-14  Kentaro Hara  <haraken@chromium.org>
9875
9876         [V8] DOM wrapper objects should be collected in minor GC cycles
9877         https://bugs.webkit.org/show_bug.cgi?id=98725
9878
9879         Reviewed by Adam Barth.
9880
9881         Previously minor GC cycles cannot collect DOM Nodes. All DOM Nodes
9882         have to survive two minor GC cycles, be promoted to the old space
9883         and wait for a heavy major GC cycle.
9884
9885         This patch enables V8 to collect DOM Nodes in minor GC cycles.
9886         For real world applications, I confirmed that minor GC cycles
9887         reclaims a substantial amount of memory (24 MB for Facebook,
9888         235 MB for Google Calendar) with acceptable overhead (~10 ms
9889         per minor GC cycle). No performance regression in Dromaeo
9890         DOM tests.
9891
9892         A design document: https://docs.google.com/a/google.com/document/d/16DeHrzkm3cO9XCPT1aK3Y5qgUxXB3RFmueqQWYmN2rI/edit
9893         Performance results: https://docs.google.com/a/google.com/document/d/1h0-EsHu7T0sSMuZm5eE0r1e8sCAzY3weLvsDUpOSngE/edit
9894         A slide: https://docs.google.com/a/google.com/presentation/d/1uifwVYGNYTZDoGLyCb7sXa7g49mWNMW2gaWvMN5NLk8/edit#slide=id.p
9895
9896         * bindings/v8/IntrusiveDOMWrapperMap.h:
9897         (WebCore::IntrusiveDOMWrapperMap::set):
9898         * bindings/v8/V8DOMWindowShell.cpp:
9899         (WebCore::initializeV8IfNeeded):
9900         * bindings/v8/V8GCController.cpp:
9901         (WebCore):
9902         (WebCore::gcTree):
9903         (WebCore::V8GCController::newWrapperBorn):
9904         (WebCore::V8GCController::gcPrologue):
9905         (WebCore::V8GCController::minorGCPrologue):
9906         (WebCore::V8GCController::majorGCPrologue):
9907         (WebCore::V8GCController::gcEpilogue):
9908         (WebCore::V8GCController::minorGCEpilogue):
9909         (WebCore::V8GCController::majorGCEpilogue):
9910         * bindings/v8/V8GCController.h:
9911         (WebCore):
9912         (V8GCController):
9913         * bindings/v8/WorkerContextExecutionProxy.cpp:
9914         (WebCore::WorkerContextExecutionProxy::initIsolate):
9915         * dom/Element.cpp:
9916         (WebCore::Element::focus):
9917         * dom/Node.h:
9918         (WebCore::Node::inEden):
9919         (WebCore::Node::setEden):
9920         (Node):
9921
9922 2012-11-14  Kentaro Hara  <haraken@chromium.org>
9923
9924         [V8] Replace setDOMWrapper() + setJSWrapperForDOMObject() with createDOMWrapper()
9925         https://bugs.webkit.org/show_bug.cgi?id=101917
9926
9927         Reviewed by Adam Barth.
9928
9929         setJSWrapperForDOMObject() is always coupled with setDOMWrapper().
9930         We can replace setDOMWrapper() + setJSWrapperForDOMObject() with
9931         createDOMWrapper(). (c.f. CREATE_DOM_WRAPPER() in JSC)
9932
9933         No tests. No change in behavior.
9934
9935         * bindings/scripts/CodeGeneratorV8.pm:
9936         (GenerateConstructorCallback):
9937         (GenerateEventConstructorCallback):
9938         (GenerateNamedConstructorCallback):
9939         (GenerateToV8Converters):
9940         * bindings/v8/V8DOMWindowShell.cpp:
9941         (WebCore::V8DOMWindowShell::installDOMWindow):
9942         * bindings/v8/V8DOMWrapper.cpp:
9943         (WebCore::V8DOMWrapper::instantiateV8Object):
9944         * bindings/v8/V8DOMWrapper.h:
9945         (V8DOMWrapper):
9946         (WebCore::V8DOMWrapper::createDOMWrapper):
9947         * bindings/v8/WorkerContextExecutionProxy.cpp:
9948         (WebCore::WorkerContextExecutionProxy::initializeIfNeeded):
9949         * bindings/v8/custom/V8ArrayBufferCustom.cpp:
9950         (WebCore::V8ArrayBuffer::constructorCallback):
9951         * bindings/v8/custom/V8ArrayBufferViewCustom.h:
9952         (WebCore::wrapArrayBufferView):
9953         (WebCore::constructWebGLArray):
9954         * bindings/v8/custom/V8DOMFormDataCustom.cpp:
9955         (WebCore::V8DOMFormData::constructorCallback):
9956         * bindings/v8/custom/V8DataViewCustom.cpp:
9957         (WebCore::V8DataView::constructorCallback):
9958         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
9959         (WebCore::v8HTMLImageElementConstructorCallback):
9960         * bindings/v8/custom/V8IntentConstructor.cpp:
9961         (WebCore::V8Intent::constructorCallback):
9962         * bindings/v8/custom/V8MessageChannelConstructor.cpp:
9963         (WebCore::V8MessageChannel::constructorCallback):
9964         * bindings/v8/custom/V8MutationObserverCustom.cpp:
9965         (WebCore::V8MutationObserver::constructorCallback):
9966         * bindings/v8/custom/V8WebKitPointConstructor.cpp:
9967         (WebCore::V8WebKitPoint::constructorCallback):
9968         * bindings/v8/custom/V8WebSocketCustom.cpp:
9969         (WebCore::V8WebSocket::constructorCallback):
9970         * bindings/v8/custom/V8XMLHttpRequestConstructor.cpp:
9971         (WebCore::V8XMLHttpRequest::constructorCallback):
9972
9973 2012-11-14  Kent Tamura  <tkent@chromium.org>
9974
9975         Support for localization tests of calendar picker
9976         https://bugs.webkit.org/show_bug.cgi?id=102181
9977
9978         Reviewed by Kentaro Hara.
9979
9980         Introduce DateTimeChooserParameters::locale to inform locale to
9981         DateTimeChooser implementations. However we pass defaultLanguage
9982         unless tests calls internals.settings.
9983         setLangAttributeAwareFormControlUIEnabled(true) explicitly.
9984
9985         Test: platform/chromium/fast/forms/calendar-picker/calendar-picker-appearance-ru.html
9986
9987         * html/HTMLInputElement.cpp:
9988         (WebCore::HTMLInputElement::setupDateTimeChooserParameters):
9989         Set DateTimeChooserParameters::locale up.
9990         * platform/DateTimeChooser.h:
9991         (DateTimeChooserParameters): Add 'locale' member.
9992
9993 2012-11-14  Alexei Filippov  <alph@chromium.org>
9994
9995         Web Inspector: Show total memory in the NMI snapshot header
9996         https://bugs.webkit.org/show_bug.cgi?id=101922
9997
9998         Reviewed by Pavel Feldman.
9999
10000         * inspector/front-end/NativeMemorySnapshotView.js:
10001         (WebInspector.NativeMemoryProfileType.prototype.buttonClicked.didReceiveMemorySnapshot):
10002         (WebInspector.NativeMemoryProfileType.prototype.buttonClicked):
10003
10004 2012-11-14  Jan Keromnes  <janx@linux.com>
10005
10006         Web Inspector: CodeMirrorTextEditor fails to scroll breakpoint into view after the first time
10007         https://bugs.webkit.org/show_bug.cgi?id=102142
10008
10009         Reviewed by Pavel Feldman.
10010
10011         Calling revealLine in highlightLine like in DefaultTextEditor does the trick.
10012
10013         * inspector/front-end/CodeMirrorTextEditor.js:
10014         (WebInspector.CodeMirrorTextEditor.prototype.highlightLine):
10015
10016 2012-11-13  Kent Tamura  <tkent@chromium.org>
10017
10018         Use menulist-button instead of menulist for date/time input types
10019         https://bugs.webkit.org/show_bug.cgi?id=101886
10020
10021         Reviewed by Hajime Morita.
10022
10023         Both of Chromium-Android and iOS use -webkit-appearance:menulist-button,
10024         not menulist. We had better apply common one by default.
10025
10026         No new tests. Covered by fast/forms/*/*-appearance-*.html.
10027
10028         * css/html.css:
10029         (input[type="date"]): Switch menulist-button from menulist.
10030         (input[type="datetime"]): Ditto.
10031         (input[type="datetime-local"]): Ditto.
10032         (input[type="month"]): Ditto.
10033         (input[type="time"]): Ditto.
10034         (input[type="week"]): Ditto.
10035         (input::-webkit-date-and-time-value):
10036         Add top, right, bottom margins. The right margin is important when
10037         dir=rtl is specified.
10038         whitespace:pre is needed to align baseline in a case of empty values.
10039         * css/themeChromiumAndroid.css:
10040         Remove redundant style declaration.
10041         * css/themeWin.css:
10042         Remove padding adjustment for date/time input types. It is for
10043         textfields.
10044
10045 2012-11-13  Vincent Scheib  <scheib@chromium.org>
10046
10047         Remove RuntimeEnabledFeatures::isPointerLockEnabled.
10048         https://bugs.webkit.org/show_bug.cgi?id=102107
10049
10050         Reviewed by Adam Barth.
10051
10052         The runtime flag is always true now that the feature is enabled by default in Chromium.
10053
10054         * bindings/generic/RuntimeEnabledFeatures.cpp:
10055         (WebCore):
10056         * bindings/generic/RuntimeEnabledFeatures.h:
10057         (RuntimeEnabledFeatures):
10058         * dom/Document.idl:
10059         * dom/Element.idl:
10060         * dom/MouseEvent.idl:
10061
10062 2012-11-13  Eugene Klyuchnikov  <eustas.bug@gmail.com>
10063
10064         Web Inspector: JsDoc-annotate KeyboardShortcuts
10065         https://bugs.webkit.org/show_bug.cgi?id=101301
10066
10067         Reviewed by Pavel Feldman.
10068
10069         JsDoc-annotate KeyboardShortcuts to improve readability.
10070
10071         * inspector/front-end/AdvancedSearchController.js: Fix parameter type.
10072         * inspector/front-end/KeyboardShortcut.js: Add annotations.
10073         * inspector/front-end/Panel.js: Make event parameter typed.
10074         * inspector/front-end/inspector.js: Ditto.
10075
10076 2012-11-13  Eugene Klyuchnikov  <eustas.bug@gmail.com>
10077
10078         Web Inspector: Extract common interface for StatusBarButton and StatusBarCombo
10079         https://bugs.webkit.org/show_bug.cgi?id=101907
10080
10081         Reviewed by Pavel Feldman.
10082
10083         Status bar control element should have common interface for
10084         easier management.
10085         In this patch getter/setter for StatusBarButton "disabled" are replaced
10086         with regular functions "enabled"/"setEnabled"; added "setEnabled"
10087         to StatusBarCombo; added new base class StatusBarItem with
10088         method "setEnabled" and member "element".
10089
10090         * inspector/front-end/CPUProfileView.js: Adopted refactoring.
10091         * inspector/front-end/DockController.js: Ditto.
10092         * inspector/front-end/ScriptsPanel.js: Ditto.
10093         * inspector/front-end/TimelinePanel.js: Ditto.
10094         * inspector/front-end/inspector.js: Ditto.
10095         * inspector/front-end/StatusBarButton.js:
10096         (WebInspector.StatusBarItem): Added.
10097         (WebInspector.StatusBarButton): Replaced getter/setter with
10098         regular functions.
10099         (WebInspector.StatusBarComboBox.prototype.setEnabled): Added.
10100
10101 2012-11-13  Eugene Klyuchnikov  <eustas.bug@gmail.com>
10102
10103         Web Inspector: Console: update tab/shift-tab shortcut description.
10104         https://bugs.webkit.org/show_bug.cgi?id=102175
10105
10106         Reviewed by Pavel Feldman.
10107
10108         For "Tab / Shift-Tab" it said "Next/previous suggestion".
10109         Actually, shift-tab to do nothing, and tab auto-completes common prefix.
10110
10111         * English.lproj/localizedStrings.js: Replaced string.
10112         * inspector/front-end/ConsoleView.js: Updated shortcut registration.
10113
10114 2012-11-13  Dana Jansens  <danakj@chromium.org>
10115
10116         [chromium] Pass showDebugBorders directly to WebLayerTreeSettings, don't use the GraphicsLayer border width setting.
10117         https://bugs.webkit.org/show_bug.cgi?id=102130
10118
10119         Reviewed by James Robinson.
10120
10121         The current method of setting debug borders on GraphicsLayers requires
10122         every GraphicsLayerClient to set the value on the layer(s) it
10123         represents. This skips the NonCompositedContentHost as well as any
10124         other clients other than RenderLayerBacking - including layers from the
10125         inspector.
10126
10127         Instead, pass the debug border setting directly to the
10128         WebLayerTreeSettings where the compositor can use the flag to enable
10129         borders on all layers globally.
10130
10131         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
10132         (WebCore::GraphicsLayerChromium::GraphicsLayerChromium):
10133         (WebCore::GraphicsLayerChromium::updateMasksToBounds):
10134         (WebCore::GraphicsLayerChromium::updateLayerIsDrawable):
10135         (WebCore::GraphicsLayerChromium::setupContentsLayer):
10136         * platform/graphics/chromium/GraphicsLayerChromium.h:
10137         (GraphicsLayerChromium):
10138
10139 2012-11-13  Kunihiko Sakamoto  <ksakamoto@chromium.org>
10140
10141         Enable calendar picker for input types datetime/datetime-local
10142         https://bugs.webkit.org/show_bug.cgi?id=101889
10143
10144         Reviewed by Kent Tamura.
10145
10146         This adds calendar picker to <input type=datetime> and <input type=datetime-local>.
10147         When a user choose a date from calendar picker, year/month/day fields of the input
10148         element are updated and hour/minute/second fields are unchanged.
10149
10150         Tests: platform/chromium/fast/forms/calendar-picker/calendar-picker-datetime-local.html
10151                platform/chromium/fast/forms/calendar-picker/calendar-picker-datetime.html
10152
10153         * Resources/pagepopups/calendarPicker.js: Day.parse accepts datetime string (just drops time part).
10154         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
10155         (WebCore::BaseMultipleFieldsDateAndTimeInputType::pickerIndicatorChooseValue):
10156         If the given value is not valid for the element, try to parse it as a date string.
10157         * html/DateTimeInputType.cpp:
10158         (WebCore::DateTimeInputType::formatDateTimeFieldsState): DateTimeFieldsState::month() returns 1-12, not 0-11.
10159         * html/DateTimeLocalInputType.cpp:
10160         (WebCore::DateTimeLocalInputType::formatDateTimeFieldsState): Ditto.
10161         * html/shadow/DateTimeEditElement.cpp:
10162         (WebCore::DateTimeEditElement::setOnlyYearMonthDay): Added.
10163         (WebCore):
10164         * html/shadow/DateTimeEditElement.h:
10165         (DateTimeEditElement):
10166         * rendering/RenderThemeChromiumCommon.cpp:
10167         (WebCore::RenderThemeChromiumCommon::supportsCalendarPicker): Return true for datetime and datetimelocal too.
10168
10169 2012-11-13  Sheriff Bot  <webkit.review.bot@gmail.com>
10170
10171         Unreviewed, rolling out r134524.
10172         http://trac.webkit.org/changeset/134524
10173         https://bugs.webkit.org/show_bug.cgi?id=102177
10174
10175         "Chromiium build broken" (Requested by haraken on #webkit).
10176
10177         * WebCore.gyp/WebCore.gyp:
10178         * WebCore.gypi:
10179         * rendering/RenderThemeChromiumFontProvider.cpp: Removed.
10180         * rendering/RenderThemeChromiumFontProvider.h: Removed.
10181         * rendering/RenderThemeChromiumFontProviderLinux.cpp: Removed.
10182         * rendering/RenderThemeChromiumFontProviderWin.cpp: Removed.
10183         * rendering/RenderThemeChromiumSkia.cpp:
10184         (WebCore::RenderThemeChromiumSkia::defaultGUIFont):
10185         (WebCore::RenderThemeChromiumSkia::systemFont):
10186         (WebCore::RenderThemeChromiumSkia::setDefaultFontSize):
10187         * rendering/RenderThemeChromiumSkia.h:
10188         (RenderThemeChromiumSkia):
10189         * rendering/RenderThemeChromiumWin.cpp:
10190         (WebCore):
10191         (WebCore::getNonClientMetrics):
10192         (WebCore::systemFontSize):
10193         (WebCore::pointsToPixels):
10194         (WebCore::RenderThemeChromiumWin::systemFont):
10195         (WebCore::RenderThemeChromiumWin::setDefaultFontSize):
10196         * rendering/RenderThemeChromiumWin.h:
10197         (RenderThemeChromiumWin):
10198
10199 2012-11-13  KyungTae Kim  <ktf.kim@samsung.com>
10200
10201         Fix compile warning [-Wsign-compare]
10202         https://bugs.webkit.org/show_bug.cgi?id=101458
10203
10204         Reviewed by Alexey Proskuryakov.
10205
10206         Currently, lossy check has been done by comparing file size(posix signed integral value) with conversioned(standard c++ unsigned integral value).
10207         However, it leads -Wsign-compare compile warning.
10208         Therefore, this patch assigns the file size to the biggest possible unsigned variable, then does the lossy check.
10209
10210         * platform/posix/SharedBufferPOSIX.cpp:
10211         (WebCore::SharedBuffer::createWithContentsOfFile):
10212
10213 2012-11-13  Keishi Hattori  <keishi@webkit.org>
10214
10215         Enable datalist UI for input types week and month
10216         https://bugs.webkit.org/show_bug.cgi?id=102041
10217
10218         Reviewed by Kent Tamura.
10219
10220         Enabling datalist UI for input types week and month.
10221
10222         No new tests. Tests will be added later in Bug 102039 and Bug 102040.
10223
10224         * rendering/RenderThemeChromiumCommon.cpp:
10225         (WebCore::RenderThemeChromiumCommon::supportsDataListUI): Add month and week to the list.
10226
10227 2012-11-13  Eberhard Graether  <egraether@google.com>
10228
10229         checkbox to toggle FPS counter in the inspector's settings
10230         https://bugs.webkit.org/show_bug.cgi?id=99660
10231
10232         Reviewed by Pavel Feldman.
10233
10234         Added a checkbox to the inspector's settings to toggle a FPS counter. The checkbox appears when InspectorClient::canShowFPSCounter() returns true.
10235
10236         No new tests.
10237
10238         * English.lproj/localizedStrings.js:
10239         * inspector/Inspector.json:
10240         * inspector/InspectorClient.h:
10241         (WebCore::InspectorClient::canShowFPSCounter):
10242         (WebCore::InspectorClient::setShowFPSCounter):
10243         (InspectorClient):
10244         * inspector/InspectorPageAgent.cpp:
10245         (PageAgentState):
10246         (WebCore::InspectorPageAgent::enable):
10247         (WebCore::InspectorPageAgent::disable):
10248         (WebCore::InspectorPageAgent::canShowFPSCounter):
10249         (WebCore):
10250         (WebCore::InspectorPageAgent::setShowFPSCounter):
10251         * inspector/InspectorPageAgent.h:
10252         * inspector/front-end/Settings.js:
10253         * inspector/front-end/SettingsScreen.js:
10254         (WebInspector.GenericSettingsTab):
10255         (WebInspector.GenericSettingsTab.prototype.get _showFPSCounterChanged):
10256         * inspector/front-end/inspector.js:
10257         (WebInspector.doLoadedDone):
10258
10259 2012-11-13  Shinya Kawanaka  <shinyak@chromium.org>
10260
10261         Collect necessary features for SelectRuleFeatureSet
10262         https://bugs.webkit.org/show_bug.cgi?id=102160
10263
10264         Reviewed by Dimitri Glazkov.
10265
10266         When pseudo class is changed, we might have to invalidate distribution. To determine whether we should invalidate
10267         distribution, we would like to collect RuleFeature from select attributes.
10268
10269         According to ShadowDOM spec, we have to collect the following pseudo classes: checked, enabled, disabled,
10270         indeterminate, link, target, and visited. We collect them in this patch.
10271
10272         Test: fast/dom/shadow/shadow-select-attribute-featureset.html
10273
10274         * html/shadow/SelectRuleFeatureSet.cpp:
10275         (WebCore::SelectRuleFeatureSet::SelectRuleFeatureSet): Uses int as bitset so that we can use bit operator.
10276         (WebCore::SelectRuleFeatureSet::add):
10277         (WebCore::SelectRuleFeatureSet::clear):
10278         (WebCore::SelectRuleFeatureSet::collectFeaturesFromSelector): Collects necessary features from CSSSelector.
10279         * html/shadow/SelectRuleFeatureSet.h:
10280         (WebCore::SelectRuleFeatureSet::hasSelectorForChecked):
10281         (WebCore::SelectRuleFeatureSet::hasSelectorForEnabled):
10282         (WebCore::SelectRuleFeatureSet::hasSelectorForDisabled):
10283         (WebCore::SelectRuleFeatureSet::hasSelectorForIndeterminate):
10284         (WebCore::SelectRuleFeatureSet::hasSelectorForLink):
10285         (WebCore::SelectRuleFeatureSet::hasSelectorForTarget):
10286         (WebCore::SelectRuleFeatureSet::hasSelectorForVisited):
10287         (SelectRuleFeatureSet):
10288         (WebCore::SelectRuleFeatureSet::setSelectRuleFeature):
10289         (WebCore::SelectRuleFeatureSet::hasSelectorFor):
10290         * testing/Internals.cpp:
10291         (WebCore::Internals::hasSelectorForPseudoClassInShadow):
10292         (WebCore):
10293         * testing/Internals.h:
10294         (Internals):
10295         * testing/Internals.idl:
10296
10297 2012-11-13  Andreas Kling  <kling@webkit.org>
10298
10299         Move inline style logic from ElementAttributeData to StyledElement.
10300         <http://webkit.org/b/102120>
10301
10302         Reviewed by Antti Koivisto.
10303
10304         Move all the logic dealing with element inline style from ElementAttributeData to StyledElement.
10305         No difference in behavior, just making ElementAttributeData dumber.
10306
10307         * css/StylePropertySet.cpp:
10308         * css/StylePropertySet.h:
10309         (WebCore::StylePropertySet::hasCSSOMWrapper):
10310         (WebCore::StylePropertySet::cssStyleDeclaration):
10311
10312             Added as complements to ensureCSSStyleDeclaration() for the case where we don't want
10313             to instantiate a CSSOM wrapper unnecessarily.
10314
10315         * dom/StyledElement.h:
10316         (WebCore::StyledElement::inlineStyle):
10317         * dom/ElementAttributeData.cpp:
10318         (WebCore::ImmutableElementAttributeData::ImmutableElementAttributeData):
10319         (WebCore::MutableElementAttributeData::MutableElementAttributeData):
10320         (WebCore::ElementAttributeData::reportMemoryUsage):
10321         * dom/ElementAttributeData.h:
10322         (WebCore::ElementAttributeData::inlineStyle):
10323         (ElementAttributeData):
10324
10325             Renamed m_inlineStyleDecl to m_inlineStyle. Finally.
10326
10327         * dom/StyledElement.cpp:
10328         (WebCore::StyledElement::~StyledElement):
10329
10330             Detach the CSSOM wrapper from the inline style if there is one.
10331
10332         (WebCore::StyledElement::ensureMutableInlineStyle):
10333         (WebCore::StyledElement::style):
10334
10335             Renamed ensureInlineStyle() to ensureMutableInlineStyle() since that's what it
10336             actually does. Update call sites accordingly.
10337
10338         (WebCore::StyledElement::inlineStyleCSSOMWrapper):
10339
10340             Added helper to get the CSSOM wrapper for the element's inline style if there is one.
10341
10342         (WebCore::StyledElement::styleAttributeChanged):
10343
10344             Do the work to parse/update/replace the inline style attribute here instead of
10345             in an ElementAttributeData method.
10346
10347         (WebCore::StyledElement::setInlineStyleProperty):
10348         (WebCore::StyledElement::removeInlineStyleProperty):
10349         (WebCore::StyledElement::removeAllInlineStyleProperties):
10350         * editing/ApplyStyleCommand.cpp:
10351         (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
10352         (WebCore::ApplyStyleCommand::removeEmbeddingUpToEnclosingBlock):
10353         (WebCore::ApplyStyleCommand::applyInlineStyleToNodeRange):
10354         * editing/ReplaceSelectionCommand.cpp:
10355         (WebCore::ReplaceSelectionCommand::handleStyleSpans):
10356         * html/canvas/CanvasStyle.cpp:
10357         (WebCore::currentColor):
10358
10359             s/ensureInlineStyle/ensureMutableInlineStyle/
10360
10361 2012-11-13  Li Yin  <li.yin@intel.com>
10362
10363         fast/forms/file/input-file-write-files.html should cover correct setting value
10364         https://bugs.webkit.org/show_bug.cgi?id=100085
10365
10366         Reviewed by Kentaro Hara.
10367
10368         Fix the GObject and Objective C bindings comparibility issue. Preserving existing
10369         behavior for those may be important in idl.
10370
10371         No new tests, because fast/forms/file/input-file-value.html has covered it.
10372
10373         * html/HTMLInputElement.idl:
10374
10375 2012-11-13  KyungTae Kim  <ktf.kim@samsung.com>
10376
10377         [EFL] Fix build warning in NetworkStateNotifierEfl.cpp
10378         https://bugs.webkit.org/show_bug.cgi?id=102061
10379
10380         Reviewed by Gyuyoung Kim.
10381
10382         The second argument for NLMSG_OK needs to be unsigned to avoid the -Wsign-compare warning.
10383
10384         * platform/network/efl/NetworkStateNotifierEfl.cpp:
10385         (WebCore::readSocketCallback):
10386
10387 2012-11-13  Sami Kyostila  <skyostil@chromium.org>
10388
10389         Don't mark scrolling contents as dirty if RenderLayerBacking is going away
10390         https://bugs.webkit.org/show_bug.cgi?id=101947
10391
10392         Reviewed by Simon Fraser.
10393
10394         When a scrolling contents graphics layer is created or destroyed, the
10395         associated graphics layer is marked as needing display because some of
10396         the painted content may have migrated between the primary graphics layer
10397         and the scrolling layer.
10398
10399         This causes a problem when the RenderLayerBacking is being destroyed,
10400         because setNeedsDisplay() needs to check from the compositor whether to
10401         track repaints or not. If the RenderLayerBacking is being destroyed, the
10402         value returned by compositor() is garbage and this causes a crash.
10403
10404         This patch fixes the problem by making RenderLayer::compositor() return a null
10405         pointer when the renderer no longer has a view.
10406
10407         Covered by existing layout tests in compositing/overflow/.
10408
10409         * rendering/RenderLayer.cpp:
10410         (WebCore::RenderLayer::compositor):
10411
10412 2012-11-13  Erik Arvidsson  <arv@chromium.org>
10413
10414         Update DOMException name: InvalidCharacterError
10415         https://bugs.webkit.org/show_bug.cgi?id=102128
10416
10417         Reviewed by Darin Adler.
10418
10419         Patch 5 of 25 to update DOMException name to match the spec and Firefox.
10420
10421         Updated existing tests.
10422
10423         * dom/DOMCoreException.cpp:
10424
10425 2012-11-13  Joshua Bell  <jsbell@chromium.org>
10426
10427         IndexedDB: Run multiple tasks per transaction tick
10428         https://bugs.webkit.org/show_bug.cgi?id=97738
10429
10430         Reviewed by Tony Chang.
10431
10432         Process multiple tasks from the pending queue(s) when the timer fires. The
10433         task may initiate new tasks that change which queue is active (e.g. indexing
10434         operations) so the loop must re-check each tick which queue to use.
10435
10436         In DumpRenderTree, time to make 20k puts/20k gets dropped from 3.2s to 2.0s (-37%);
10437         in Chromium's content_shell, the time dropped from 8.1s to 4.6s (-42%).
10438
10439         No new tests - just perf improvements, covered by (nearly) all existing IDB tests.
10440
10441         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
10442         (WebCore::IDBTransactionBackendImpl::abort): Use takeFirst() to clean up code.
10443         (WebCore::IDBTransactionBackendImpl::taskTimerFired): Process as many tasks as are available.
10444
10445 2012-11-13  Elliott Sprehn  <esprehn@chromium.org>
10446
10447         Disable frame loading instead of throwing exceptions on subtree modifications in ChildFrameDisconnector
10448         https://bugs.webkit.org/show_bug.cgi?id=102012
10449
10450         Reviewed by Ojan Vafai.
10451
10452         Previously if you modified the subtree that was being removed from a
10453         removeChild from inside an unload handler on an <iframe> inside the
10454         subtree you'd get an exception which is wrong. Instead we just need to
10455         disable all frame loading there.
10456
10457         This works because either the subtree will be removed and the frame never
10458         loading doesn't matter, or some section of the subtree that contains the
10459         frame will be moved to another part of the document which will cause the
10460         frame to load when it's inserted there.
10461
10462         I also added a check for <object> elements. It doesn't seem this is actually
10463         reachable in the existing code, but I'm not entirely sure since the frame
10464         loading and object/plugin handling is very confusing.
10465
10466         A better fix could be to repeatedly walk the subtree until all frames
10467         were disconnected or some iteration limit was hit and then force all leftover
10468         subframes to disconnect without firing unload handlers but this is such an
10469         edge case I don't think the complexity is necessary.
10470
10471         Test: fast/frames/modifications-in-subtree-unload.html
10472
10473         * dom/ContainerNodeAlgorithms.h:
10474         (WebCore::ChildFrameDisconnector::ChildFrameDisconnector):
10475         (WebCore::ChildFrameDisconnector::~ChildFrameDisconnector):
10476         (ChildFrameDisconnector):
10477         (WebCore::ChildFrameDisconnector::disconnect):
10478         * dom/Node.cpp:
10479         (WebCore::checkAcceptChild): Removed exception.
10480         * html/HTMLFrameElementBase.cpp:
10481         (WebCore::HTMLFrameElementBase::didNotifySubtreeInsertions): Check canLoadFrame().
10482         * html/HTMLFrameOwnerElement.h:
10483         (SubframeLoadingDisabler):
10484         (WebCore::SubframeLoadingDisabler::SubframeLoadingDisabler):
10485         (WebCore::SubframeLoadingDisabler::~SubframeLoadingDisabler):
10486         (WebCore::SubframeLoadingDisabler::canLoadFrame):
10487           Returns true if frames can be loaded in the subtree.
10488         (WebCore::SubframeLoadingDisabler::disabledSubtreeRoots):
10489         * html/HTMLObjectElement.cpp:
10490         (WebCore::HTMLObjectElement::updateWidget):
10491           Check canLoadFrame(). I think this case is impossible, but it's better
10492           to be safe than sorry later.
10493
10494 2012-11-13  Joshua Bell  <jsbell@chromium.org>
10495
10496         [V8] Add missing ENABLE(SVG) test in header
10497         https://bugs.webkit.org/show_bug.cgi?id=102143
10498
10499         Reviewed by Kentaro Hara.
10500
10501         Need to wrap the #include of a header that's only conditionally generated.
10502
10503         Fixes build error if compiling e.g. w/ GYP_DEFINES="enable_svg=0"
10504
10505         * bindings/v8/custom/V8ElementCustom.cpp:
10506
10507 2012-11-13  Jon Lee  <jonlee@apple.com>
10508
10509         Automatically run small plugins
10510         https://bugs.webkit.org/show_bug.cgi?id=102148
10511         <rdar://problem/12695560>
10512
10513         Reviewed by Darin Adler.
10514
10515         * rendering/RenderEmbeddedObject.h: Promote layout() to protected.
10516         * rendering/RenderSnapshottedPlugIn.cpp: Add constants for threshold size for plugins that will auto-start.
10517         (WebCore::RenderSnapshottedPlugIn::layout): After layout, obtain the width and height of the element.
10518         If either dimension is 0, or the overall size of the plugin is smaller that the threshold size, move the
10519         display state to Playing. Assuming we will always layout before first paint, changing the state here
10520         should be safe.
10521         * rendering/RenderSnapshottedPlugIn.h:
10522
10523 2012-11-13  Kenneth Russell  <kbr@google.com>
10524
10525         Notify embedder of lost contexts and allow overriding of WebGL support
10526         https://bugs.webkit.org/show_bug.cgi?id=101826
10527
10528         Reviewed by Adam Barth.
10529
10530         Add hooks notifying the embedder when OpenGL contexts are lost and
10531         allowing overriding of WebGL support on a per-frame basis.
10532
10533         No tests yet; don't know how to test this solely within WebKit.
10534         Currently developing tests in the Chromium port exercising the
10535         notifications end-to-end. Once those are in place, I'm prepared to
10536         investigate adding tests for all ports.
10537
10538         * html/canvas/WebGLRenderingContext.cpp:
10539         (WebCore):
10540         (WebCore::WebGLRenderingContext::create):
10541           Check whether embedder vetoes creation of new WebGL contexts.
10542         (WebCore::WebGLRenderingContext::loseContextImpl):
10543           Notify embedder that context was lost.
10544         (WebCore::WebGLRenderingContext::maybeRestoreContext):
10545           Check whether embedder vetoes restoration of existing WebGL contexts.
10546         * loader/FrameLoaderClient.h:
10547         (FrameLoaderClient):
10548         (WebCore::FrameLoaderClient::allowWebGL):
10549         (WebCore::FrameLoaderClient::didLoseWebGLContext):
10550           Hooks notifying embedder of lost contexts and asking permission to run WebGL.
10551
10552 2012-11-13  Scott Violet  <sky@chromium.org>
10553
10554         [Chromium] Refactor theme font lookup into a factory
10555         https://bugs.webkit.org/show_bug.cgi?id=101949
10556
10557         Reviewed by Tony Chang.
10558
10559         This will ultimately allow us to use what is currently in RenderThemeChromiumLinux on windows.
10560
10561         No new tests. Refactoring only.
10562
10563         * WebCore.gyp/WebCore.gyp:
10564         * WebCore.gypi:
10565         * rendering/RenderThemeChromiumFontProvider.cpp: Added.
10566         (WebCore):
10567         (WebCore::RenderThemeChromiumFontProvider::defaultGUIFont): Moved into RenderThemeFontProvider.
10568         * rendering/RenderThemeChromiumFontProvider.h: Added.
10569         (WTF):
10570         (WebCore):
10571         (RenderThemeChromiumFontProvider): This is the font related methods.
10572         * rendering/RenderThemeChromiumFontProviderLinux.cpp: Added.
10573         (WebCore):
10574         (WebCore::RenderThemeChromiumFontProvider::setDefaultFontSize): What was in RenderThemeChromiumSkia::setDefaultFontSize.
10575         (WebCore::RenderThemeChromiumFontProvider::systemFont): What was in RenderThemeChromiumSkia::systemFont.
10576         * rendering/RenderThemeChromiumFontProviderWin.cpp: Added.
10577         (WebCore):
10578         (WebCore::pointsToPixels): Moved from RenderThemeChromiumWin.
10579         (WebCore::getNonClientMetrics): Moved from RenderThemeChromiumWin.
10580         (WebCore::systemFontSize): Moved from RenderThemeChromiumWin.
10581         (WebCore::RenderThemeChromiumFontProvider::systemFont): Moved from RenderThemeChromiumWin.
10582         (WebCore::RenderThemeChromiumFontProvider::setDefaultFontSize): Moved from RenderThemeChromiumWin.
10583         * rendering/RenderThemeChromiumSkia.cpp:
10584         (WebCore::RenderThemeChromiumSkia::RenderThemeChromiumSkia): Moved into RenderThemeFontProvider.
10585         (WebCore::RenderThemeChromiumSkia::systemFont): Calls to RenderThemeChromiumFontProvider.
10586         (WebCore::RenderThemeChromiumSkia::setDefaultFontSize): Calls to RenderThemeChromiumFontProvider.
10587         * rendering/RenderThemeChromiumSkia.h:
10588         (RenderThemeChromiumSkia): Moves defaultFontSize into RenderThemeChromiumFontProvider.
10589         * rendering/RenderThemeChromiumWin.cpp: Moves font code into RenderThemeFontProviderWin.
10590         (WebCore):
10591         * rendering/RenderThemeChromiumWin.h: Removed overriden methods now handled by RenderThemeChromiumSkia.
10592         (RenderThemeChromiumWin):
10593
10594 2012-11-13  Alec Flett  <alecflett@chromium.org>
10595
10596         Add DOMRequestState to maintain world/ScriptExecutionContext state
10597         https://bugs.webkit.org/show_bug.cgi?id=102102
10598
10599         Reviewed by Adam Barth.
10600
10601         Introduce DOMRequestState, and convert IndexedDB over.
10602
10603         No new tests, this is an abstraction layer for existing code.
10604
10605         * Modules/indexeddb/IDBRequest.cpp:
10606         (WebCore::IDBRequest::IDBRequest):
10607         (WebCore::IDBRequest::onSuccess):
10608         (WebCore::IDBRequest::dispatchEvent):
10609         * Modules/indexeddb/IDBRequest.h:
10610         (IDBRequest):
10611         * WebCore.gypi:
10612         * bindings/v8/DOMRequestState.h: Added.
10613         (WebCore):
10614         (DOMRequestState):
10615         (WebCore::DOMRequestState::DOMRequestState):
10616         (Scope):
10617         (WebCore::DOMRequestState::Scope::Scope):
10618         (WebCore::DOMRequestState::scope):
10619
10620 2012-11-13  Robert Sesek  <rsesek@chromium.org>
10621
10622         Sever Chromium's dependence on WebKitSystemInterface media control drawing functions in RenderThemeMac
10623         https://bugs.webkit.org/show_bug.cgi?id=101634
10624
10625         Reviewed by Adam Barth.
10626
10627         This splits out the common methods between RenderThemeMac and RenderThemeChromiumMac
10628         into RenderThemeMacShared.
10629
10630         No new tests, just refactoring.
10631
10632         * WebCore.gyp/WebCore.gyp: Remove RenderThemeMac.mm from platform/ sources list, since it's part of rendering/
10633         * WebCore.gypi: Add RenderThemeMacShared.{h,mm}
10634         * WebCore.xcodeproj/project.pbxproj: Add RenderThemeMacShared.{h,mm}
10635         * rendering/RenderThemeChromiumMac.h:
10636         * rendering/RenderThemeChromiumMac.mm:
10637         (WebCore::RenderThemeChromiumMac::popupInternalPaddingLeft):
10638         (WebCore::RenderThemeChromiumMac::popupInternalPaddingRight):
10639         (WebCore::RenderThemeChromiumMac::extraDefaultStyleSheet):
10640         * rendering/RenderThemeMac.h:
10641         (RenderThemeMac):
10642         * rendering/RenderThemeMac.mm:
10643         (WebCore):
10644         (WebCore::RenderTheme::themeForPage):
10645         (WebCore::RenderThemeMac::create):
10646         (WebCore::RenderThemeMac::RenderThemeMac):
10647         (WebCore::RenderThemeMac::~RenderThemeMac):
10648         (WebCore::RenderThemeMac::documentViewFor):
10649         (WebCore::mediaControllerTheme):
10650         (WebCore::RenderThemeMac::paintMediaSliderTrack):
10651         (WebCore::RenderThemeMac::paintMediaRewindButton):
10652         (WebCore::RenderThemeMac::paintMediaReturnToRealtimeButton):
10653         (WebCore::RenderThemeMac::paintMediaFullScreenVolumeSliderTrack):
10654         (WebCore::RenderThemeMac::paintMediaFullScreenVolumeSliderThumb):
10655         (WebCore::RenderThemeMac::extraMediaControlsStyleSheet):
10656         (WebCore::RenderThemeMac::extraFullScreenStyleSheet):
10657         * rendering/RenderThemeMacShared.h: Copied from Source/WebCore/rendering/RenderThemeMac.h.
10658         (WebCore):
10659         (RenderThemeMacShared):
10660         (WebCore::RenderThemeMacShared::supportsControlTints):
10661         (WebCore::RenderThemeMacShared::scrollbarControlSizeForPart):
10662         (WebCore::RenderThemeMacShared::supportsSelectionForegroundColors):
10663         (WebCore::RenderThemeMacShared::supportsClosedCaptioning):
10664         (WebCore::RenderThemeMacShared::updateActiveState):
10665         * rendering/RenderThemeMacShared.mm: Copied from Source/WebCore/rendering/RenderThemeMac.mm.
10666         (-[WebCoreRenderThemeNotificationObserver initWithTheme:WebCore::]):
10667         (-[WebCoreRenderThemeNotificationObserver systemColorsDidChange:]):
10668         (-[WebCoreTextFieldCell _coreUIDrawOptionsWithFrame:inView:includeFocus:]):
10669         (WebCore):
10670         (WebCore::RenderThemeMacShared::RenderThemeMacShared):
10671         (WebCore::RenderThemeMacShared::~RenderThemeMacShared):
10672         (WebCore::RenderThemeMacShared::platformActiveSelectionBackgroundColor):
10673         (WebCore::RenderThemeMacShared::platformInactiveSelectionBackgroundColor):
10674         (WebCore::RenderThemeMacShared::platformActiveListBoxSelectionBackgroundColor):
10675         (WebCore::RenderThemeMacShared::platformActiveListBoxSelectionForegroundColor):
10676         (WebCore::RenderThemeMacShared::platformInactiveListBoxSelectionForegroundColor):
10677         (WebCore::RenderThemeMacShared::platformFocusRingColor):
10678         (WebCore::RenderThemeMacShared::platformInactiveListBoxSelectionBackgroundColor):
10679         (WebCore::toFontWeight):
10680         (WebCore::RenderThemeMacShared::systemFont):
10681         (WebCore::convertNSColorToColor):
10682         (WebCore::menuBackgroundColor):
10683         (WebCore::RenderThemeMacShared::platformColorsDidChange):
10684         (WebCore::RenderThemeMacShared::systemColor):
10685         (WebCore::RenderThemeMacShared::usesTestModeFocusRingColor):
10686         (WebCore::RenderThemeMacShared::isControlStyled):
10687         (WebCore::RenderThemeMacShared::adjustRepaintRect):
10688         (WebCore::RenderThemeMacShared::inflateRect):
10689         (WebCore::RenderThemeMacShared::convertToPaintingRect):
10690         (WebCore::RenderThemeMacShared::updateCheckedState):
10691         (WebCore::RenderThemeMacShared::updateEnabledState):
10692         (WebCore::RenderThemeMacShared::updateFocusedState):
10693         (WebCore::RenderThemeMacShared::updatePressedState):
10694         (WebCore::RenderThemeMacShared::controlSupportsTints):
10695         (WebCore::RenderThemeMacShared::controlSizeForFont):
10696         (WebCore::RenderThemeMacShared::setControlSize):
10697         (WebCore::RenderThemeMacShared::sizeForFont):
10698         (WebCore::RenderThemeMacShared::sizeForSystemFont):
10699         (WebCore::RenderThemeMacShared::setSizeFromFont):
10700         (WebCore::RenderThemeMacShared::setFontFromControlSize):
10701         (WebCore::RenderThemeMacShared::controlSizeForSystemFont):
10702         (WebCore::RenderThemeMacShared::paintTextField):
10703         (WebCore::RenderThemeMacShared::adjustTextFieldStyle):
10704         (WebCore::RenderThemeMacShared::paintCapsLockIndicator):
10705         (WebCore::RenderThemeMacShared::paintTextArea):
10706         (WebCore::RenderThemeMacShared::adjustTextAreaStyle):
10707         (WebCore::RenderThemeMacShared::popupButtonMargins):
10708         (WebCore::RenderThemeMacShared::popupButtonSizes):
10709         (WebCore::RenderThemeMacShared::popupButtonPadding):
10710         (WebCore::RenderThemeMacShared::paintMenuList):
10711         (WebCore::RenderThemeMacShared::meterSizeForBounds):
10712         (WebCore::RenderThemeMacShared::paintMeter):
10713         (WebCore::RenderThemeMacShared::supportsMeter):
10714         (WebCore::RenderThemeMacShared::levelIndicatorStyleFor):
10715         (WebCore::RenderThemeMacShared::levelIndicatorFor):
10716         (WebCore::RenderThemeMacShared::progressBarSizes):
10717         (WebCore::RenderThemeMacShared::progressBarMargins):
10718         (WebCore::RenderThemeMacShared::minimumProgressBarHeight):
10719         (WebCore::RenderThemeMacShared::animationRepeatIntervalForProgressBar):
10720         (WebCore::RenderThemeMacShared::animationDurationForProgressBar):
10721         (WebCore::RenderThemeMacShared::adjustProgressBarStyle):
10722         (WebCore::RenderThemeMacShared::paintProgressBar):
10723         (WebCore::TopGradientInterpolate):
10724         (WebCore::BottomGradientInterpolate):
10725         (WebCore::MainGradientInterpolate):
10726         (WebCore::TrackGradientInterpolate):
10727         (WebCore::RenderThemeMacShared::paintMenuListButtonGradients):
10728         (WebCore::RenderThemeMacShared::paintMenuListButton):
10729         (WebCore::menuListButtonSizes):
10730         (WebCore::RenderThemeMacShared::adjustMenuListStyle):
10731         (WebCore::RenderThemeMacShared::popupInternalPaddingLeft):
10732         (WebCore::RenderThemeMacShared::popupInternalPaddingRight):
10733         (WebCore::RenderThemeMacShared::popupInternalPaddingTop):
10734         (WebCore::RenderThemeMacShared::popupInternalPaddingBottom):
10735         (WebCore::RenderThemeMacShared::adjustMenuListButtonStyle):
10736         (WebCore::RenderThemeMacShared::setPopupButtonCellState):
10737         (WebCore::RenderThemeMacShared::menuListSizes):
10738         (WebCore::RenderThemeMacShared::minimumMenuListSize):
10739         (WebCore::RenderThemeMacShared::adjustSliderTrackStyle):
10740         (WebCore::RenderThemeMacShared::paintSliderTrack):
10741         (WebCore::RenderThemeMacShared::adjustSliderThumbStyle):
10742         (WebCore::RenderThemeMacShared::paintSliderThumb):
10743         (WebCore::RenderThemeMacShared::paintSearchField):
10744         (WebCore::RenderThemeMacShared::setSearchCellState):
10745         (WebCore::RenderThemeMacShared::searchFieldSizes):
10746         (WebCore::RenderThemeMacShared::setSearchFieldSize):
10747         (WebCore::RenderThemeMacShared::adjustSearchFieldStyle):
10748         (WebCore::RenderThemeMacShared::paintSearchFieldCancelButton):
10749         (WebCore::RenderThemeMacShared::cancelButtonSizes):
10750         (WebCore::RenderThemeMacShared::adjustSearchFieldCancelButtonStyle):
10751         (WebCore::RenderThemeMacShared::resultsButtonSizes):
10752         (WebCore::RenderThemeMacShared::adjustSearchFieldDecorationStyle):
10753         (WebCore::RenderThemeMacShared::paintSearchFieldDecoration):
10754         (WebCore::RenderThemeMacShared::adjustSearchFieldResultsDecorationStyle):
10755         (WebCore::RenderThemeMacShared::paintSearchFieldResultsDecoration):
10756         (WebCore::RenderThemeMacShared::adjustSearchFieldResultsButtonStyle):
10757         (WebCore::RenderThemeMacShared::paintSearchFieldResultsButton):
10758         (WebCore::RenderThemeMacShared::sliderTickSize):
10759         (WebCore::RenderThemeMacShared::sliderTickOffsetFromTrackCenter):
10760         (WebCore::RenderThemeMacShared::adjustSliderThumbSize):
10761         (WebCore::RenderThemeMacShared::shouldShowPlaceholderWhenFocused):
10762         (WebCore::RenderThemeMacShared::popupButton):
10763         (WebCore::RenderThemeMacShared::search):
10764         (WebCore::RenderThemeMacShared::searchMenuTemplate):
10765         (WebCore::RenderThemeMacShared::sliderThumbHorizontal):
10766         (WebCore::RenderThemeMacShared::sliderThumbVertical):
10767         (WebCore::RenderThemeMacShared::textField):
10768         (WebCore::RenderThemeMacShared::fileListNameForWidth):
10769         (WebCore::RenderThemeMacShared::paintPlugInSnapshotOverlay):
10770
10771 2012-11-13  Tab Atkins  <jackalmage@gmail.com>
10772
10773         CSS @charset parsing is too loose, doesn't match other browsers
10774         https://bugs.webkit.org/show_bug.cgi?id=101527
10775
10776         Reviewed by Alexey Proskuryakov.
10777
10778         Per <https://www.w3.org/Bugs/Public/show_bug.cgi?id=19882#attach_1244>,
10779         IE and FF have changed to be strict about @charset parsing,
10780         as the CSS 2.1 spec requires.
10781         Since @charset use is very uncommon anyway,
10782         we should match the new behavior and the spec for platform consistency.
10783
10784         Test: fast/encoding/css-charset-evil/css-charset-evil.html
10785
10786         * loader/TextResourceDecoder.cpp:
10787         (WebCore::bytesEqual):
10788         (WebCore::TextResourceDecoder::checkForCSSCharset):
10789
10790 2012-11-13  Kenichi Ishibashi  <bashi@chromium.org>
10791
10792         [WebSocket] send() and close() should not throw an exception for an unpaired surrogate but use the replacement character
10793         https://bugs.webkit.org/show_bug.cgi?id=101569
10794
10795         Reviewed by Alexey Proskuryakov.
10796
10797         Replace unpaired surrogates with replacing character (U+FFFD) when
10798         encoding text messages and close reasons. This change is aimed at
10799         following the changes on the WebSocket API specification.
10800
10801         Test: http/tests/websocket/tests/hybi/close-reason-too-long.html
10802
10803         * Modules/websockets/WebSocket.cpp:
10804         (WebCore::WebSocket::close):
10805         Use String::StrictConversionReplacingUnpairedSurrogatesWithFFFD mode to encode
10806         text message. Remove invalid utf-8 check.
10807         * Modules/websockets/WebSocketChannel.cpp:
10808         (WebCore::WebSocketChannel::send):
10809         Use String::StrictConversionReplacingUnpairedSurrogatesWithFFFD mode to encode
10810         close reason. Remove invalid utf-8 check.
10811
10812 2012-11-13  Christophe Dumez  <christophe.dumez@intel.com>
10813
10814         Make HTMLLegendElement.form behave according to specification
10815         https://bugs.webkit.org/show_bug.cgi?id=101044
10816
10817         Reviewed by Kent Tamura.
10818
10819         According to the HTML5 specification (http://dev.w3.org/html5/spec/single-page.html#dom-legend-form),
10820         The form IDL attribute's behavior depends on whether the legend element is in a fieldset element or
10821         not. If the legend has a fieldset element as its parent, then the form IDL attribute must return the
10822         same value as the form IDL attribute on that fieldset element. Otherwise, it must return null.
10823
10824         This patch makes WebKit behaves according to specification (and Firefox). Previously, legend.form was
10825         not returning null if the element was not inside a fieldset. Also, legend.form did not necessarily
10826         return the same value as the parent fieldset's form attribute.
10827
10828         Test: fast/forms/legend/legend-form.html
10829
10830         * html/HTMLLegendElement.cpp:
10831         (WebCore):
10832         (WebCore::HTMLLegendElement::virtualForm):
10833         * html/HTMLLegendElement.h:
10834         (HTMLLegendElement):
10835
10836 2012-11-13  Mark Lam  <mark.lam@apple.com>
10837
10838         Make an assertion in JSEventListener::jsFunction() more useful.
10839         https://bugs.webkit.org/show_bug.cgi?id=101985.
10840
10841         Reviewed by Geoffrey Garen.
10842
10843         The assertion was weakened in r134495. This strengthens it again.
10844
10845         No new tests.
10846
10847         * bindings/js/JSEventListener.h:
10848         (WebCore::JSEventListener::jsFunction):
10849
10850 2012-11-13  Dean Jackson  <dino@apple.com>
10851
10852         Support list of tracks in caption media controls
10853         https://bugs.webkit.org/show_bug.cgi?id=101669
10854
10855         Reviewed by Eric Carlson.
10856
10857         Attempt four of commit. The first two times caused build failures on Chromium. The third time
10858         crashed the Windows test bot. It's also been rebased since r134488.
10859
10860         Add some new elements to the media control shadow DOM that display the list of available
10861         tracks on an audio/video element. The UI is hidden by default everywhere but on Mac,
10862         where it is given a very basic design. At the moment only the list of available tracks
10863         are displayed; The followup bug will make the UI active: https://bugs.webkit.org/show_bug.cgi?id=101670
10864
10865         No new tests - this doesn't expose any testable surface.
10866
10867         * css/mediaControls.css: Added default rules that hide the new elements.
10868         * css/mediaControlsQuickTime.css: Specific rules that give a basic rendering of the new track list.
10869         * html/shadow/MediaControlElements.cpp:
10870         (WebCore::MediaControlElement::isShowing): Tests for the visibility of a control.
10871         (WebCore::MediaControlClosedCaptionsContainerElement::MediaControlClosedCaptionsContainerElement):
10872         (WebCore::MediaControlClosedCaptionsContainerElement::create):
10873         (WebCore::MediaControlClosedCaptionsContainerElement::shadowPseudoId):
10874         (WebCore::MediaControlToggleClosedCaptionsButtonElement::MediaControlToggleClosedCaptionsButtonElement):
10875         (WebCore::MediaControlToggleClosedCaptionsButtonElement::create): Now takes a reference to the media controls as a parameter.
10876         (WebCore::MediaControlToggleClosedCaptionsButtonElement::updateDisplayType):
10877         (WebCore::MediaControlToggleClosedCaptionsButtonElement::defaultEventHandler):
10878         (WebCore::MediaControlToggleClosedCaptionsButtonElement::shadowPseudoId):
10879         (WebCore::MediaControlClosedCaptionsTrackListElement::MediaControlClosedCaptionsTrackListElement): New element for holding a list of tracks to display.
10880         * html/shadow/MediaControlElements.h:
10881         (MediaControlElement):
10882         (MediaControlToggleClosedCaptionsButtonElement):
10883         (MediaControlClosedCaptionsContainerElement):
10884         (MediaControlClosedCaptionsTrackListElement): Examines the media element to build a shadow DOM that lists all the tracks available.
10885         * html/shadow/MediaControlsApple.cpp:
10886         (WebCore::MediaControlsApple::MediaControlsApple):
10887         (WebCore::MediaControlsApple::create): New track container and list elements created.
10888         (WebCore::MediaControlsApple::setMediaController): Hook up the new elements to the controller..
10889         (WebCore::MediaControlsApple::hide):
10890         (WebCore::MediaControlsApple::makeTransparent):
10891         (WebCore::MediaControlsApple::reset):
10892         (WebCore::MediaControlsApple::reportedError):
10893         (WebCore::MediaControlsApple::toggleClosedCaptionTrackList): Shows or hides the popup with the list of tracks.
10894         (WebCore):
10895         * html/shadow/MediaControlsApple.h:
10896         (MediaControlsApple):
10897         * html/shadow/MediaControlsChromium.cpp:
10898         (WebCore::MediaControlsChromium::initializeControls): Pass in the controls as a parameter.
10899         * html/shadow/MediaControls.h:
10900         (MediaControls):
10901         * platform/Language.cpp:
10902         (WebCore::displayNameForLanguageLocale): New function to return a human-readable name for a locale, given the identifier input.
10903         * platform/Language.h:
10904         (WebCore):
10905         * rendering/RenderMediaControls.cpp:
10906         (WebCore::RenderMediaControls::paintMediaControlsPart): New enum values into switch.
10907         * rendering/RenderMediaControlsChromium.cpp:
10908         (WebCore::RenderMediaControlsChromium::paintMediaControlsPart): New enum values into switch.
10909
10910 2012-11-13  Dimitri Glazkov  <dglazkov@chromium.org>
10911
10912         Unreviewed, rolling out r134377.
10913         http://trac.webkit.org/changeset/134377
10914         https://bugs.webkit.org/show_bug.cgi?id=101133
10915
10916         Caused a mysterious Android Clang build failure, needs
10917         investigation before landing again.
10918
10919         * css/html.css:
10920         (input::-webkit-textfield-decoration-container):
10921         * html/TextFieldInputType.cpp:
10922         (WebCore::TextFieldInputType::attach):
10923
10924 2012-11-13  Sheriff Bot  <webkit.review.bot@gmail.com>
10925
10926         Unreviewed, rolling out r134482.
10927         http://trac.webkit.org/changeset/134482
10928         https://bugs.webkit.org/show_bug.cgi?id=102140
10929
10930         The patch causes fast/regions/moved-content-node-crash.html to
10931         crash in Debug mode due to ASSERTION. (Requested by abucur on
10932         #webkit).
10933
10934         * rendering/InlineFlowBox.cpp:
10935         (SameSizeAsInlineFlowBox):
10936         * rendering/InlineFlowBox.h:
10937         (WebCore::InlineFlowBox::InlineFlowBox):
10938         (InlineFlowBox):
10939         * rendering/RenderBlock.cpp:
10940         (WebCore::RenderBlock::lineWidthForPaginatedLineChanged):
10941         * rendering/RenderBlockLineLayout.cpp:
10942         (WebCore::RenderBlock::layoutRunsAndFloatsInRange):
10943         (WebCore::RenderBlock::linkToEndLineIfNeeded):
10944         (WebCore::RenderBlock::determineStartPosition):
10945         * rendering/RootInlineBox.cpp:
10946         (WebCore::RootInlineBox::RootInlineBox):
10947         * rendering/RootInlineBox.h:
10948         (WebCore):
10949         (WebCore::RootInlineBox::paginationStrut):
10950         (WebCore::RootInlineBox::setPaginationStrut):
10951         (WebCore::RootInlineBox::isFirstAfterPageBreak):
10952         (WebCore::RootInlineBox::setIsFirstAfterPageBreak):
10953         (WebCore::RootInlineBox::paginatedLineWidth):
10954         (WebCore::RootInlineBox::setPaginatedLineWidth):
10955         (RootInlineBox):
10956
10957 2012-11-13  Xianzhu Wang  <wangxianzhu@chromium.org>
10958
10959         Missing NodeRenderStyle.h include in WebCore/html/TextFieldInputType.cpp
10960         https://bugs.webkit.org/show_bug.cgi?id=102108
10961
10962         Reviewed by Adam Barth.
10963
10964         No new tests. Fix clang build break.
10965
10966         * html/TextFieldInputType.cpp: Added #include "NodeRenderStyle.h"
10967
10968 2012-11-13  Chris Fleizach  <cfleizach@apple.com>
10969
10970         AX: MathML types need to be semantically identified in AX tree
10971         https://bugs.webkit.org/show_bug.cgi?id=101263
10972
10973         Reviewed by Beth Dakin.
10974
10975         Semantically identify various MathML elements within the AX tree. This will allow
10976         screen readers to identify math types so that equations can be output more accurately.
10977
10978         Test: platform/mac/accessibility/mathml-elements.html
10979
10980         * accessibility/AccessibilityObject.h:
10981         (AccessibilityObject):
10982         (WebCore::AccessibilityObject::isMathElement):
10983         (WebCore::AccessibilityObject::isMathFraction):
10984         (WebCore::AccessibilityObject::isMathFenced):
10985         (WebCore::AccessibilityObject::isMathSubscriptSuperscript):
10986         (WebCore::AccessibilityObject::isMathRow):
10987         (WebCore::AccessibilityObject::isMathUnderOver):
10988         (WebCore::AccessibilityObject::isMathRoot):
10989         (WebCore::AccessibilityObject::isMathSquareRoot):
10990         (WebCore::AccessibilityObject::isMathText):
10991         (WebCore::AccessibilityObject::isMathNumber):
10992         (WebCore::AccessibilityObject::isMathOperator):
10993         (WebCore::AccessibilityObject::isMathFenceOperator):
10994         (WebCore::AccessibilityObject::isMathSeparatorOperator):
10995         (WebCore::AccessibilityObject::isMathIdentifier):
10996         (WebCore::AccessibilityObject::isMathTable):
10997         (WebCore::AccessibilityObject::isMathTableRow):
10998         (WebCore::AccessibilityObject::isMathTableCell):
10999         (WebCore::AccessibilityObject::mathRadicandObject):
11000         (WebCore::AccessibilityObject::mathRootIndexObject):
11001         (WebCore::AccessibilityObject::mathUnderObject):
11002         (WebCore::AccessibilityObject::mathOverObject):
11003         (WebCore::AccessibilityObject::mathNumeratorObject):
11004         (WebCore::AccessibilityObject::mathDenominatorObject):
11005         (WebCore::AccessibilityObject::mathBaseObject):
11006         (WebCore::AccessibilityObject::mathSubscriptObject):
11007         (WebCore::AccessibilityObject::mathSuperscriptObject):
11008         (WebCore::AccessibilityObject::mathFencedOpenString):
11009         (WebCore::AccessibilityObject::mathFencedCloseString):
11010         * accessibility/AccessibilityRenderObject.cpp:
11011         (WebCore::startOfContinuations):
11012             Handle a case where a MathML render element is created with the node of their parent (which could lead to an assert).
11013         (WebCore::AccessibilityRenderObject::textUnderElement):
11014             Handle the cases for RenderMathMLOperators which use the node of their parent, which confuses the normal textUnderElement() routine.
11015         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
11016             Handle ignored cases for math elements
11017         (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
11018         (WebCore::AccessibilityRenderObject::isMathElement):
11019         (WebCore::AccessibilityRenderObject::isMathFraction):
11020         (WebCore::AccessibilityRenderObject::isMathFenced):
11021         (WebCore::AccessibilityRenderObject::isMathSubscriptSuperscript):
11022         (WebCore::AccessibilityRenderObject::isMathRow):
11023         (WebCore::AccessibilityRenderObject::isMathUnderOver):
11024         (WebCore::AccessibilityRenderObject::isMathSquareRoot):
11025         (WebCore::AccessibilityRenderObject::isMathRoot):
11026         (WebCore::AccessibilityRenderObject::isMathOperator):
11027         (WebCore::AccessibilityRenderObject::isMathFenceOperator):
11028         (WebCore::AccessibilityRenderObject::isMathSeparatorOperator):
11029         (WebCore::AccessibilityRenderObject::isMathText):
11030         (WebCore::AccessibilityRenderObject::isMathNumber):
11031         (WebCore::AccessibilityRenderObject::isMathIdentifier):
11032         (WebCore::AccessibilityRenderObject::isMathTable):
11033         (WebCore::AccessibilityRenderObject::isMathTableRow):
11034         (WebCore::AccessibilityRenderObject::isMathTableCell):
11035         (WebCore::AccessibilityRenderObject::isIgnoredElementWithinMathTree):
11036             Make sure anonymouse blocks are ignored within math tree; make sure non-element type objects are ignored (like <mstyle>).
11037         (WebCore::AccessibilityRenderObject::mathRadicandObject):
11038         (WebCore::AccessibilityRenderObject::mathRootIndexObject):
11039         (WebCore::AccessibilityRenderObject::mathNumeratorObject):
11040         (WebCore::AccessibilityRenderObject::mathDenominatorObject):
11041         (WebCore::AccessibilityRenderObject::mathUnderObject):
11042         (WebCore::AccessibilityRenderObject::mathOverObject):
11043         (WebCore::AccessibilityRenderObject::mathBaseObject):
11044         (WebCore::AccessibilityRenderObject::mathSubscriptObject):
11045         (WebCore::AccessibilityRenderObject::mathSuperscriptObject):
11046         (WebCore::AccessibilityRenderObject::mathFencedOpenString):
11047         (WebCore::AccessibilityRenderObject::mathFencedCloseString):
11048         * accessibility/AccessibilityRenderObject.h:
11049         (AccessibilityRenderObject):
11050         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
11051         (-[WebAccessibilityObjectWrapper additionalAccessibilityAttributeNames]):
11052         (createAccessibilityRoleMap):
11053         (-[WebAccessibilityObjectWrapper subrole]):
11054         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
11055         * rendering/mathml/RenderMathMLBlock.cpp:
11056         (WebCore::RenderMathMLBlock::RenderMathMLBlock):
11057         * rendering/mathml/RenderMathMLBlock.h:
11058         (WebCore::RenderMathMLBlock::isRenderMathMLFenced):
11059         (WebCore::RenderMathMLBlock::isRenderMathMLFraction):
11060         (WebCore::RenderMathMLBlock::isRenderMathMLRoot):
11061         (WebCore::RenderMathMLBlock::isRenderMathMLSquareRoot):
11062         (WebCore::RenderMathMLBlock::isRenderMathMLSubSup):
11063         (WebCore::RenderMathMLBlock::isRenderMathMLUnderOver):
11064         (WebCore::RenderMathMLBlock::setIgnoreInAccessibilityTree):
11065         (WebCore::RenderMathMLBlock::ignoreInAccessibilityTree):
11066             Add ability to identify anonymous render blocks as items that AX should ignore.
11067         (RenderMathMLBlock):
11068         * rendering/mathml/RenderMathMLFenced.cpp:
11069         (WebCore::RenderMathMLFenced::createMathMLOperator):
11070             Identify which kind of math operator is being created on the fly (Fence or Separator)
11071         (WebCore::RenderMathMLFenced::makeFences):
11072         (WebCore::RenderMathMLFenced::addChild):
11073         * rendering/mathml/RenderMathMLFenced.h:
11074         (WebCore::RenderMathMLFenced::isRenderMathMLFenced):
11075         (RenderMathMLFenced):
11076         * rendering/mathml/RenderMathMLFraction.h:
11077         (WebCore::RenderMathMLFraction::isRenderMathMLFraction):
11078         * rendering/mathml/RenderMathMLOperator.cpp:
11079         (WebCore::RenderMathMLOperator::RenderMathMLOperator):
11080         (WebCore::RenderMathMLOperator::updateFromElement):
11081         (WebCore::RenderMathMLOperator::createGlyph):
11082              Mark anonymous render blocks as AX ignored.
11083         * rendering/mathml/RenderMathMLOperator.h:
11084         (WebCore::RenderMathMLOperator::setOperatorType):
11085         (WebCore::RenderMathMLOperator::operatorType):
11086         (RenderMathMLOperator):
11087         * rendering/mathml/RenderMathMLRoot.h:
11088         (WebCore::RenderMathMLRoot::isRenderMathMLRoot):
11089         * rendering/mathml/RenderMathMLSquareRoot.h:
11090         (WebCore::RenderMathMLSquareRoot::isRenderMathMLSquareRoot):
11091         * rendering/mathml/RenderMathMLSubSup.h:
11092         (WebCore::RenderMathMLSubSup::isRenderMathMLSubSup):
11093         * rendering/mathml/RenderMathMLUnderOver.h:
11094         (WebCore::RenderMathMLUnderOver::isRenderMathMLUnderOver):
11095         
11096 2012-11-13  Mark Lam  <mark.lam@apple.com>
11097
11098         JSEventListener should not access m_jsFunction when its wrapper is gone.
11099         https://bugs.webkit.org/show_bug.cgi?id=101985.
11100
11101         Reviewed by Geoffrey Garen.
11102
11103         Added a few null checks for m_wrapper before we do anything with m_jsFunction.
11104
11105         No new tests.
11106
11107         * bindings/js/JSEventListener.cpp:
11108         (WebCore::JSEventListener::initializeJSFunction):
11109         - Removed a now invalid assertion. m_wrapper is expected to have a
11110           valid non-zero value when jsFunction is valid. However, in the case
11111           of JSLazyEventListener (which extends JSEventListener), m_wrapper is
11112           initially 0 when m_jsFunction has not been realized yet. When
11113           JSLazyEventListener::initializeJSFunction() realizes m_jsFunction,
11114           it will set m_wrapper to an appropriate wrapper object.
11115
11116           For this reason, JSEventListener::jsFunction() cannot do the null
11117           check on m_wrapper until after the call to initializeJSFunction.
11118
11119           This, in turns, means that in the case of the non-lazy
11120           JSEventListener, initializeJSFunction() will also be called, and
11121           if the GC has collected the m_wrapper but the JSEventListener has
11122           not been removed yet, it is possible to see a null m_wrapper while
11123           m_jsFunction contains a non-zero stale value.
11124
11125           Hence, this assertion of (m_wrapper || !m_jsFunction) in
11126           JSEventListener::initializeJSFunction() is not always true and
11127           should be removed.
11128
11129         (WebCore::JSEventListener::visitJSFunction):
11130         (WebCore::JSEventListener::operator==):
11131         * bindings/js/JSEventListener.h:
11132         (WebCore::JSEventListener::jsFunction):
11133
11134 2012-11-13  Adam Barth  <abarth@webkit.org>
11135
11136         [V8] instantiateV8Object should encapulate the tricky creationContext logic
11137         https://bugs.webkit.org/show_bug.cgi?id=102117
11138
11139         Reviewed by Eric Seidel.
11140
11141         The logic around creationContext is tricky. Rather than putting the
11142         logic in the code generator, we can centralize the logic in
11143         instantiateV8Object.
11144
11145         This patch shouldn't have any behavior change.
11146
11147         * bindings/scripts/CodeGeneratorV8.pm:
11148         (GenerateToV8Converters):
11149         * bindings/v8/V8DOMWrapper.cpp:
11150         (V8WrapperInstantiationScope):
11151         (WebCore::V8WrapperInstantiationScope::V8WrapperInstantiationScope):
11152         (WebCore::V8WrapperInstantiationScope::~V8WrapperInstantiationScope):
11153         (WebCore::V8WrapperInstantiationScope::context):
11154         (WebCore):
11155         (WebCore::V8DOMWrapper::instantiateV8Object):
11156         * bindings/v8/V8DOMWrapper.h:
11157         (V8DOMWrapper):
11158
11159 2012-11-13  Silvia Pfeiffer  <silviapf@chromium.org>
11160
11161         Clean up the inheritance tree under the MediaControls Class.
11162         https://bugs.webkit.org/show_bug.cgi?id=88871
11163
11164         Reviewed by Eric Carlson.
11165
11166         This patch removes code duplication between the Chromium and Safari
11167         media controls shadow DOMs.
11168         This is achieved by pulling common functions that are identical (or
11169         almost identical) between the different platforms into the base class.
11170         The derived classes are renamed based on their platform:
11171         - MediaControlRootElement                to MediaControlsApple.
11172         - MediaControlRootElementChromium        to MediaControlsChromium.
11173         - MediaControlRootElementChromiumAndroid to MediaControlsChromiumAndroid.
11174         MediaControls is now no longer an abstract base class, but its "create"
11175         function is only implemented in the port-specific header file, so it's
11176         on purpose incomplete in the MediaControls.cpp file.
11177
11178         No new tests because this is refactoring work only.
11179
11180         * CMakeLists.txt:
11181           Rename MediaControlRootElement.cpp to MediaControlsApple.cpp .
11182         * GNUmakefile.list.am:
11183           Rename MediaControlRootElement.[cpp,h] to MediaControlsApple.[cpp,h] .
11184         * Target.pri:
11185           Rename MediaControlRootElement.cpp to MediaControlsApple.cpp .
11186         * WebCore.gypi:
11187           Rename MediaControlRootElement[Chromium[Android]].[cpp,h] to MediaControls[Apple,Chromium[Android]].[cpp,h] .
11188         * WebCore.order:
11189           Rename MediaControlRootElement symbols to MediaControlsApple symbols.
11190         * WebCore.vcproj/WebCore.vcproj:
11191           Rename MediaControlRootElement.[cpp,h] to MediaControlsApple.[cpp,h] .
11192         * WebCore.xcodeproj/project.pbxproj:
11193           Rename MediaControlRootElement.[cpp,h] to MediaControlsApple.[cpp,h] .
11194         * html/shadow/MediaControlElements.cpp:
11195         (WebCore::MediaControlTimelineElement::defaultEventHandler):
11196           Remove dependency on MediaControlRootElement.h (base class MediaControls.h is still there).
11197           Rename updateTimeDisplay() to updateCurrentTimeDisplay().
11198         * html/shadow/MediaControls.cpp:
11199         (WebCore::MediaControls::MediaControls):
11200           Added initialization for media elements that all platform controls share.
11201         (WebCore):
11202           Removed include files that are already included in header file.
11203         (WebCore::MediaControls::setMediaController):
11204           Added controller assignment for media elements that all platform controls share.
11205         (WebCore::MediaControls::reset):
11206           Added resets for media elements that all platform controls share.
11207         (WebCore::MediaControls::reportedError):
11208           Added error handling for media elements that all platform controls share.
11209         (WebCore::MediaControls::loadedMetadata):
11210           Added default action for loadedMetadata event.
11211         (WebCore::MediaControls::show):
11212         (WebCore::MediaControls::hide):
11213         (WebCore::MediaControls::makeOpaque):
11214         (WebCore::MediaControls::makeTransparent):
11215         (WebCore::MediaControls::shouldHideControls):
11216         (WebCore::MediaControls::bufferingProgressed):
11217         (WebCore::MediaControls::playbackStarted):
11218         (WebCore::MediaControls::playbackProgressed):
11219         (WebCore::MediaControls::playbackStopped):
11220         (WebCore::MediaControls::updateCurrentTimeDisplay):
11221         (WebCore::MediaControls::showVolumeSlider):
11222         (WebCore::MediaControls::changedMute):
11223         (WebCore::MediaControls::changedVolume):
11224         (WebCore::MediaControls::changedClosedCaptionsVisibility):
11225         (WebCore::MediaControls::enteredFullscreen):
11226         (WebCore::MediaControls::exitedFullscreen):
11227         (WebCore::MediaControls::defaultEventHandler):
11228         (WebCore::MediaControls::hideFullscreenControlsTimerFired):
11229         (WebCore::MediaControls::startHideFullscreenControlsTimer):
11230         (WebCore::MediaControls::stopHideFullscreenControlsTimer):
11231         (WebCore::MediaControls::shadowPseudoId):
11232         (WebCore::MediaControls::containsRelatedTarget):
11233         (WebCore::MediaControls::createTextTrackDisplay):
11234         (WebCore::MediaControls::showTextTrackDisplay):
11235         (WebCore::MediaControls::hideTextTrackDisplay):
11236         (WebCore::MediaControls::updateTextTrackDisplay):
11237           Added default actions for all these media controls member functions.
11238         * html/shadow/MediaControls.h:
11239         (WebCore):
11240           Added include files and forward class declarations that all media controls share.
11241         (MediaControls):
11242           Make all pure virtual functions that have default implementations just virtual.
11243         (WebCore::MediaControls::updateStatusDisplay):
11244           Add an empty virtual updateStatusDisplay function which is used by media elements.
11245         * html/shadow/MediaControlsApple.cpp: Renamed from Source/WebCore/html/shadow/MediaControlRootElement.cpp.
11246           Reduced Apple-specific media control functions by relying on default implementations in the base class.
11247         * html/shadow/MediaControlsApple.h: Renamed from Source/WebCore/html/shadow/MediaControlRootElement.h.
11248           Reduced Apple-specific media control elements by relying on some elements in the base class.
11249         * html/shadow/MediaControlsChromium.cpp: Renamed from Source/WebCore/html/shadow/MediaControlRootElementChromium.cpp.
11250           Reduced Chromium-specific media control functions by relying on default implementations in the base class.
11251         * html/shadow/MediaControlsChromium.h: Renamed from Source/WebCore/html/shadow/MediaControlRootElementChromium.h.
11252           Reduced Chromium-specific media control functions by relying on default implementations in the base class.
11253         * html/shadow/MediaControlsChromiumAndroid.cpp: Renamed from Source/WebCore/html/shadow/MediaControlRootElementChromiumAndroid.cpp.
11254           Renamed class name and base class name.
11255         * html/shadow/MediaControlsChromiumAndroid.h: Renamed from Source/WebCore/html/shadow/MediaControlRootElementChromiumAndroid.h.
11256           Renamed class name and base class name.
11257         * rendering/RenderTheme.h:
11258         (WebCore::RenderTheme::timeWithoutMouseMovementBeforeHidingControls):
11259           Moved timeWithoutMouseMovementBeforeHidingControls variable from all classes to a theme-specific function.
11260
11261 2012-11-13  Benjamin Poulain  <benjamin@webkit.org>
11262
11263         CSSParser::setStyleSheet() should be inline
11264         https://bugs.webkit.org/show_bug.cgi?id=101829
11265
11266         Reviewed by Andreas Kling.
11267
11268         * css/CSSParser.cpp:
11269         * css/CSSParser.h:
11270         (WebCore::CSSParser::setStyleSheet):
11271         CSSParser::setStyleSheet() just assign a pointer, it does not even
11272         change a ref-count. The function should probably be in the header.
11273
11274 2012-11-13  Andrei Bucur  <abucur@adobe.com>
11275
11276         [CSS Regions] Add Region info for RootLineBoxes and pack the pagination data
11277         https://bugs.webkit.org/show_bug.cgi?id=101332
11278
11279         Reviewed by David Hyatt.
11280
11281         Currently the pagination information for lines is spread between the RootInlineBox and InlineFlowBox classes, consuming memory even though
11282         the boxes were not the result of an pagination layout. To overcome this, a new struct (LineFragmentationData) is created that wraps all the data,
11283         including a new member, the containing Region for the line.
11284         The containing Region is used to detect if a line changed the Region where it resides. This will be helpful especially when implementing region
11285         styling for layout properties (e.g. the font-size property https://bugs.webkit.org/show_bug.cgi?id=95559 ).
11286         A line can change the region when it is shifted inside the containing block or if the entire block moves. This means it's better to delegate
11287         the task of updating the containing Region to the block.
11288
11289         Tests: No new tests because there is no functional change.
11290
11291         * rendering/InlineFlowBox.cpp:
11292         (SameSizeAsInlineFlowBox):
11293         * rendering/InlineFlowBox.h:
11294         (WebCore::InlineFlowBox::InlineFlowBox):
11295         (InlineFlowBox):
11296         * rendering/RenderBlock.cpp:
11297         (WebCore::RenderBlock::lineWidthForPaginatedLineChanged):
11298         * rendering/RenderBlockLineLayout.cpp:
11299         (WebCore::RenderBlock::layoutRunsAndFloatsInRange):
11300         (WebCore::RenderBlock::linkToEndLineIfNeeded):
11301         (WebCore::RenderBlock::determineStartPosition):
11302         * rendering/RootInlineBox.cpp:
11303         (WebCore::RootInlineBox::RootInlineBox):
11304         (WebCore::RootInlineBox::setContainingRegion):
11305         (WebCore):
11306         * rendering/RootInlineBox.h:
11307         (WebCore):
11308         (WebCore::RootInlineBox::paginationStrut):
11309         (WebCore::RootInlineBox::setPaginationStrut):
11310         (WebCore::RootInlineBox::isFirstAfterPageBreak):
11311         (WebCore::RootInlineBox::setIsFirstAfterPageBreak):
11312         (WebCore::RootInlineBox::paginatedLineWidth):
11313         (WebCore::RootInlineBox::setPaginatedLineWidth):
11314         (RootInlineBox):
11315         (WebCore::RootInlineBox::containingRegion):
11316         (WebCore::RootInlineBox::ensureLineFragmentationData):
11317         (LineFragmentationData):
11318         (WebCore::RootInlineBox::LineFragmentationData::LineFragmentationData):
11319
11320 2012-11-13  Milian Wolff  <milian.wolff@kdab.com>
11321
11322         [Qt] QNX build fails due to signature change in gl2.h header (glShaderSource)
11323         https://bugs.webkit.org/show_bug.cgi?id=98038
11324
11325         Reviewed by Simon Hausmann.
11326
11327         Cast the function to the expected type, just like it is done on non-Qt/OpenGL2 ES platforms.
11328
11329         * platform/graphics/OpenGLShims.cpp:
11330         (WebCore):
11331
11332 2012-11-13  Chris Fleizach  <cfleizach@apple.com>
11333
11334         WebKit exposes ARIA rowheader role as AXUnknown when not contained in table/grid
11335         https://bugs.webkit.org/show_bug.cgi?id=101616
11336
11337         Reviewed by Beth Dakin.
11338
11339         If the rowheader role is exposed because the element is not within a table, the mac platform
11340         should map that to a generic group.
11341
11342         Test: platform/mac/accessibility/rowheader-outside-table-role.html
11343
11344         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
11345         (createAccessibilityRoleMap):
11346
11347 2012-11-13  Stephen White  <senorblanco@chromium.org>
11348
11349         [Chromium] Fix SkImageFilter DAG path to pass all css3/filters tests
11350         https://bugs.webkit.org/show_bug.cgi?id=101952
11351
11352         Reviewed by James Robinson.
11353
11354         With these changes, all of the css3/filters tests pass when the
11355         if-test in GraphicsLayerChromium::setFilters() is forced true (for
11356         now, it remains true only if there's a reference filter in the chain).
11357
11358         Covered by the css3/filters tests (when the switch is thrown in
11359         GraphicsLayerChromium::setFilters()).
11360
11361         * WebCore.gypi:
11362         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
11363         Drop to software rendering if there's a custom filter in the chain.
11364         This is the same as the WebFilterOperations path is doing.
11365         * platform/graphics/filters/skia/DropShadowImageFilter.cpp: Added.
11366         * platform/graphics/filters/skia/DropShadowImageFilter.h: Added.
11367         New implementation of drop-shadow filter; equivalent to
11368         the path in cc/render_surface_filters.cc.
11369         * platform/graphics/filters/skia/SkiaImageFilterBuilder.cpp:
11370         Fix the sepia and grayscale filters (value was inverted).
11371
11372 2012-11-13  Sheriff Bot  <webkit.review.bot@gmail.com>
11373
11374         Unreviewed, rolling out r134442.
11375         http://trac.webkit.org/changeset/134442
11376         https://bugs.webkit.org/show_bug.cgi?id=102111
11377
11378         Does not compile on apple-mac (Requested by abarth on
11379         #webkit).
11380
11381         * CMakeLists.txt:
11382         * GNUmakefile.list.am:
11383         * Target.pri:
11384         * WebCore.gypi:
11385         * WebCore.vcproj/WebCore.vcproj:
11386         * WebCore.xcodeproj/project.pbxproj:
11387         * css/CSSCursorImageValue.cpp:
11388         (WebCore::CSSCursorImageValue::cachedImage):
11389         * css/CSSFontFaceSrcValue.cpp:
11390         (WebCore::CSSFontFaceSrcValue::cachedFont):
11391         * css/CSSImageSetValue.cpp:
11392         (WebCore::CSSImageSetValue::cachedImageSet):
11393         * css/CSSImageValue.cpp:
11394         (WebCore::CSSImageValue::cachedImage):
11395         * css/CSSImageValue.h:
11396         (WebCore):
11397         (CSSImageValue):
11398         * css/StyleResolver.cpp:
11399         (WebCore::StyleResolver::loadPendingImage):
11400         * css/StyleRuleImport.cpp:
11401         (WebCore::StyleRuleImport::requestStyleSheet):
11402         * css/WebKitCSSSVGDocumentValue.cpp:
11403         (WebCore::WebKitCSSSVGDocumentValue::load):
11404         * css/WebKitCSSShaderValue.cpp:
11405         (WebCore::WebKitCSSShaderValue::cachedShader):
11406         * dom/ScriptElement.cpp:
11407         (WebCore::ScriptElement::requestScript):
11408         * html/HTMLLinkElement.cpp:
11409         (WebCore::HTMLLinkElement::process):
11410         * html/parser/CSSPreloadScanner.cpp:
11411         (WebCore::CSSPreloadScanner::emitRule):
11412         * html/parser/CSSPreloadScanner.h:
11413         (CSSPreloadScanner):
11414         * html/parser/HTMLPreloadScanner.cpp:
11415         (WebCore::PreloadTask::preload):
11416         * loader/ImageLoader.cpp:
11417         (WebCore::ImageLoader::updateFromElement):
11418         * loader/cache/CachedResourceLoader.cpp:
11419         (WebCore::CachedResourceLoader::requestImage):
11420         (WebCore::CachedResourceLoader::requestResource):
11421         (WebCore::CachedResourceLoader::determineRevalidationPolicy):
11422         (WebCore):
11423         (WebCore::CachedResourceLoader::preload):
11424         * loader/cache/CachedResourceLoader.h:
11425         (WebCore):
11426         (CachedResourceLoader):
11427         * loader/cache/CachedResourceRequest.cpp:
11428         (WebCore::CachedResourceRequest::CachedResourceRequest):
11429         * loader/cache/CachedResourceRequest.h:
11430         (CachedResourceRequest):
11431         (WebCore::CachedResourceRequest::defer):
11432         (WebCore::CachedResourceRequest::setDefer):
11433         * loader/cache/CachedResourceRequestInitiators.cpp: Removed.
11434         * loader/cache/CachedResourceRequestInitiators.h: Removed.
11435         * loader/icon/IconLoader.cpp:
11436         (WebCore::IconLoader::startLoading):
11437         * platform/ThreadGlobalData.cpp:
11438         (WebCore::ThreadGlobalData::ThreadGlobalData):
11439         * platform/ThreadGlobalData.h:
11440         (ThreadGlobalData):
11441         * svg/SVGFEImageElement.cpp:
11442         (WebCore::SVGFEImageElement::requestImageResource):
11443         * svg/SVGFontFaceUriElement.cpp:
11444         (WebCore::SVGFontFaceUriElement::loadFont):
11445         * svg/SVGUseElement.cpp:
11446         (WebCore::SVGUseElement::svgAttributeChanged):
11447
11448 2012-11-13  Chris Fleizach  <cfleizach@apple.com>
11449
11450         AX: file upload input text value is not exposed through accessibility
11451         https://bugs.webkit.org/show_bug.cgi?id=100583
11452
11453         Reviewed by Beth Dakin.
11454
11455         This is a hard problem to solve on the Mac because there are three pieces of information
11456              1) The type of button 2) The text on the button 3) The text for the value.
11457         I think the best compromise is to label this as a file upload button type in the role description, 
11458         and then expose the file path text as the AXTitle. 
11459         This will give the more relevant information and should be clear what is happening.
11460
11461         Test: platform/mac/accessibility/file-upload-button-subrole.html
11462
11463         * English.lproj/Localizable.strings:
11464         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
11465         (-[WebAccessibilityObjectWrapper subrole]):
11466         (-[WebAccessibilityObjectWrapper roleDescription]):
11467         (-[WebAccessibilityObjectWrapper accessibilityTitle]):
11468         * platform/LocalizedStrings.cpp:
11469         (WebCore::AXFileUploadButtonText):
11470         * platform/LocalizedStrings.h:
11471
11472 2012-11-13  Sheriff Bot  <webkit.review.bot@gmail.com>
11473
11474         Unreviewed, rolling out r133944.
11475         http://trac.webkit.org/changeset/133944
11476         https://bugs.webkit.org/show_bug.cgi?id=102118
11477
11478         Only JS bindings support NATIVE_TYPE_ERR (Requested by arv on
11479         #webkit).
11480
11481         * bindings/scripts/CodeGeneratorV8.pm:
11482         (GenerateFunctionCallback):
11483         (GenerateParametersCheck):
11484         (GenerateSingleConstructorCallback):
11485         (GenerateNamedConstructorCallback):
11486         (TypeCanFailConversion):
11487         * dom/Element.cpp:
11488         (WebCore::Element::setAttributeNode):
11489         (WebCore::Element::removeAttributeNode):
11490         * dom/Element.idl:
11491
11492 2012-11-13  Adam Barth  <abarth@webkit.org>
11493
11494         Unreviewed.
11495
11496         Update run-bindings-tests results.
11497
11498         * bindings/scripts/test/V8/V8Float64Array.cpp:
11499         (WebCore::V8Float64Array::dispatchWrapCustom):
11500         (WebCore::V8Float64Array::wrapSlow):
11501         * bindings/scripts/test/V8/V8Float64Array.h:
11502         (WebCore::V8Float64Array::toNative):
11503         (V8Float64Array):
11504         (WebCore):
11505         (WebCore::dispatchWrap):
11506         (WebCore::toV8Object):
11507         (WebCore::toV8):
11508         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
11509         (WebCore::V8TestActiveDOMObject::wrapSlow):
11510         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
11511         (WebCore::V8TestActiveDOMObject::toNative):
11512         (V8TestActiveDOMObject):
11513         (WebCore):
11514         (WebCore::dispatchWrap):
11515         (WebCore::toV8Object):
11516         (WebCore::toV8):
11517         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
11518         (WebCore::V8TestCustomNamedGetter::wrapSlow):
11519         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
11520         (WebCore::V8TestCustomNamedGetter::toNative):
11521         (V8TestCustomNamedGetter):
11522         (WebCore):
11523         (WebCore::dispatchWrap):
11524         (WebCore::toV8Object):
11525         (WebCore::toV8):
11526         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
11527         (WebCore::V8TestEventConstructor::wrapSlow):
11528         * bindings/scripts/test/V8/V8TestEventConstructor.h:
11529         (WebCore::V8TestEventConstructor::toNative):
11530         (V8TestEventConstructor):
11531         (WebCore):
11532         (WebCore::dispatchWrap):
11533         (WebCore::toV8Object):
11534         (WebCore::toV8):
11535         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
11536         (WebCore::V8TestEventTarget::wrapSlow):
11537         * bindings/scripts/test/V8/V8TestEventTarget.h:
11538         (WebCore::V8TestEventTarget::toNative):
11539         (V8TestEventTarget):
11540         (WebCore):
11541         (WebCore::dispatchWrap):
11542         (WebCore::toV8Object):
11543         (WebCore::toV8):
11544         * bindings/scripts/test/V8/V8TestException.cpp:
11545         (WebCore::V8TestException::wrapSlow):
11546         * bindings/scripts/test/V8/V8TestException.h:
11547         (WebCore::V8TestException::toNative):
11548         (V8TestException):
11549         (WebCore):
11550         (WebCore::dispatchWrap):
11551         (WebCore::toV8Object):
11552         (WebCore::toV8):
11553         * bindings/scripts/test/V8/V8TestInterface.cpp:
11554         (WebCore::V8TestInterface::wrapSlow):
11555         * bindings/scripts/test/V8/V8TestInterface.h:
11556         (WebCore::V8TestInterface::toNative):
11557         (V8TestInterface):
11558         (WebCore):
11559         (WebCore::dispatchWrap):
11560         (WebCore::toV8Object):
11561         (WebCore::toV8):
11562         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
11563         (WebCore::V8TestMediaQueryListListener::wrapSlow):
11564         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
11565         (WebCore::V8TestMediaQueryListListener::toNative):
11566         (V8TestMediaQueryListListener):
11567         (WebCore):
11568         (WebCore::dispatchWrap):
11569         (WebCore::toV8Object):
11570         (WebCore::toV8):
11571         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
11572         (WebCore::V8TestNamedConstructor::wrapSlow):
11573         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
11574         (WebCore::V8TestNamedConstructor::toNative):
11575         (V8TestNamedConstructor):
11576         (WebCore):
11577         (WebCore::dispatchWrap):
11578         (WebCore::toV8Object):
11579         (WebCore::toV8):
11580         * bindings/scripts/test/V8/V8TestNode.cpp:
11581         (WebCore::V8TestNode::wrapSlow):
11582         * bindings/scripts/test/V8/V8TestNode.h:
11583         (WebCore::V8TestNode::toNative):
11584         (V8TestNode):
11585         (WebCore):
11586         (WebCore::dispatchWrap):
11587         (WebCore::toV8Object):
11588         (WebCore::toV8):
11589         (WebCore::toV8Fast):
11590         * bindings/scripts/test/V8/V8TestObj.cpp:
11591         (WebCore::V8TestObj::wrapSlow):
11592         * bindings/scripts/test/V8/V8TestObj.h:
11593         (WebCore::V8TestObj::toNative):
11594         (V8TestObj):
11595         (WebCore):
11596         (WebCore::dispatchWrap):
11597         (WebCore::toV8Object):
11598         (WebCore::toV8):
11599         * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
11600         (WebCore::V8TestOverloadedConstructors::wrapSlow):
11601         * bindings/scripts/test/V8/V8TestOverloadedConstructors.h:
11602         (WebCore::V8TestOverloadedConstructors::toNative):
11603         (V8TestOverloadedConstructors):
11604         (WebCore):
11605         (WebCore::dispatchWrap):
11606         (WebCore::toV8Object):
11607         (WebCore::toV8):
11608         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
11609         (WebCore::V8TestSerializedScriptValueInterface::wrapSlow):
11610         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
11611         (WebCore::V8TestSerializedScriptValueInterface::toNative):
11612         (V8TestSerializedScriptValueInterface):
11613         (WebCore):
11614         (WebCore::dispatchWrap):
11615         (WebCore::toV8Object):
11616         (WebCore::toV8):
11617
11618 2012-11-13  Adam Barth  <abarth@webkit.org>
11619
11620         Unreviewed.
11621
11622         Speculative build fix for Qt.
11623
11624         * dom/make_names.pl:
11625         (printWrapperFactoryCppFile):
11626
11627 2012-11-13  Sami Kyostila  <skyostil@chromium.org>
11628
11629         Allow painting outside overflow clip in accelerated scrolling layers
11630         https://bugs.webkit.org/show_bug.cgi?id=100524
11631
11632         Reviewed by Simon Fraser.
11633
11634         In preparation for avoiding repaints when scrolling child layers, make it
11635         possible to paint outside the overflow clip.
11636
11637         Test: compositing/overflow/updating-scrolling-content.html
11638
11639         * rendering/LayoutState.h:
11640         (LayoutState):
11641         * rendering/RenderBlock.cpp:
11642         (WebCore::RenderBlock::paint):
11643         * rendering/RenderBox.cpp:
11644         (WebCore::RenderBox::applyCachedClipAndScrollOffsetForRepaint):
11645         * rendering/RenderLayer.cpp:
11646         (WebCore::RenderLayer::repaintBlockSelectionGaps):
11647
11648 2012-11-13  Patrick Gansterer  <paroga@webkit.org>
11649
11650         Port SimpleFontDataWin.cpp to WinCE
11651         https://bugs.webkit.org/show_bug.cgi?id=97889
11652
11653         Reviewed by Brent Fulgham.
11654
11655         Add #if !OS(WINCE) around some parts of the code, so it can be used by the WinCE port too in a next step.
11656         Also cleaned up the include headers.
11657
11658         * platform/graphics/win/SimpleFontDataWin.cpp:
11659         (WebCore::SimpleFontData::initGDIFont):
11660         (WebCore::SimpleFontData::platformDestroy):
11661         (WebCore::SimpleFontData::boundsForGDIGlyph):
11662         (WebCore):
11663         (WebCore::SimpleFontData::widthForGDIGlyph):
11664
11665 2012-11-13  Pavel Feldman  <pfeldman@chromium.org>
11666
11667         Web Inspector: [Chromium] move spectrum.css into the standalone css files group.
11668
11669         Not reviewed: moved css file in gypi.
11670
11671         * WebCore.gypi:
11672
11673 2012-11-13  Dimitri Glazkov  <dglazkov@chromium.org>
11674
11675         Unreviewed, rolling out r134434.
11676         http://trac.webkit.org/changeset/134434
11677         https://bugs.webkit.org/show_bug.cgi?id=102072
11678
11679         The test that was added asserts in loader.
11680
11681         * loader/FrameLoader.cpp:
11682         (WebCore::createWindow):
11683         * page/DOMWindow.cpp:
11684         (WebCore):
11685         (WebCore::DOMWindow::adjustWindowRect):
11686         (WebCore::DOMWindow::moveBy):
11687         (WebCore::DOMWindow::moveTo):
11688         (WebCore::DOMWindow::resizeBy):
11689         (WebCore::DOMWindow::resizeTo):
11690         (WebCore::DOMWindow::open):
11691         (WebCore::DOMWindow::showModalDialog):
11692         * page/DOMWindow.h:
11693         (DOMWindow):
11694
11695 2012-11-13  Dan Carney  <dcarney@google.com>
11696
11697         [V8] More efficient wrapper dispatch
11698         https://bugs.webkit.org/show_bug.cgi?id=102082
11699
11700         Reviewed by Adam Barth.
11701
11702         Dispatching a call to V8Whatever::wrap involved a chain
11703         of calls, each of which checked its wrapper cache.
11704         This refactor gives calls only 2 choices of functions to call:
11705         toV8 and toV8Object instead of wrap. wrap has been renamed to
11706         dispatchWrap and no longer contains cache checks.
11707         Additionally, classes which require a custom toV8 function
11708         have had all wrapping and caching calls removed, as they could
11709         not have been accessed.
11710
11711         No new tests. Sufficiently covered.
11712
11713         * Modules/indexeddb/IDBAny.idl:
11714         * Modules/indexeddb/IDBKey.idl:
11715         * WebCore.gypi:
11716         * bindings/scripts/CodeGeneratorV8.pm:
11717         (GenerateHeader):
11718         (GenerateNormalAttrGetter):
11719         (GenerateImplementation):
11720         (GenerateToV8Converters):
11721         * bindings/scripts/IDLAttributes.txt:
11722         * bindings/v8/SerializedScriptValue.cpp:
11723         * bindings/v8/custom/V8BlobCustom.cpp:
11724         (WebCore::V8Blob::dispatchWrapCustom):
11725         * bindings/v8/custom/V8CSSRuleCustom.cpp:
11726         (WebCore::V8CSSRule::dispatchWrapCustom):
11727         * bindings/v8/custom/V8CSSValueCustom.cpp:
11728         (WebCore::V8CSSValue::dispatchWrapCustom):
11729         * bindings/v8/custom/V8CanvasRenderingContextCustom.cpp:
11730         (WebCore::V8CanvasRenderingContext::dispatchWrapCustom):
11731         * bindings/v8/custom/V8DataViewCustom.cpp:
11732         (WebCore):
11733         (WebCore::V8DataView::dispatchWrapCustom):
11734         * bindings/v8/custom/V8DocumentCustom.cpp:
11735         (WebCore::V8Document::dispatchWrapCustom):
11736         * bindings/v8/custom/V8ElementCustom.cpp: Copied from Source/WebCore/bindings/v8/custom/V8PerformanceEntryCustom.cpp.
11737         (WebCore):
11738         (WebCore::V8Element::dispatchWrapCustom):
11739         * bindings/v8/custom/V8EntryCustom.cpp:
11740         (WebCore::V8Entry::dispatchWrapCustom):
11741         * bindings/v8/custom/V8EntrySyncCustom.cpp:
11742         (WebCore::V8EntrySync::dispatchWrapCustom):
11743         * bindings/v8/custom/V8EventCustom.cpp:
11744         (WebCore):
11745         (WebCore::V8Event::dispatchWrapCustom):
11746         * bindings/v8/custom/V8HTMLCollectionCustom.cpp:
11747         (WebCore::V8HTMLCollection::dispatchWrapCustom):
11748         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
11749         (WebCore::V8HTMLDocument::dispatchWrapCustom):
11750         * bindings/v8/custom/V8HTMLElementCustom.cpp:
11751         (WebCore::V8HTMLElement::dispatchWrapCustom):
11752         * bindings/v8/custom/V8ImageDataCustom.cpp:
11753         (WebCore::V8ImageData::dispatchWrapCustom):
11754         * bindings/v8/custom/V8NodeCustom.cpp:
11755         (WebCore::V8Node::dispatchWrapCustom):
11756         * bindings/v8/custom/V8PerformanceEntryCustom.cpp:
11757         (WebCore::V8PerformanceEntry::dispatchWrapCustom):
11758         * bindings/v8/custom/V8SVGDocumentCustom.cpp:
11759         (WebCore::V8SVGDocument::dispatchWrapCustom):
11760         * bindings/v8/custom/V8SVGElementCustom.cpp:
11761         (WebCore::V8SVGElement::dispatchWrapCustom):
11762         * bindings/v8/custom/V8SVGPathSegCustom.cpp:
11763         (WebCore::V8SVGPathSeg::dispatchWrapCustom):
11764         * bindings/v8/custom/V8StyleSheetCustom.cpp:
11765         (WebCore::V8StyleSheet::dispatchWrapCustom):
11766         * dom/Element.idl:
11767         * dom/make_names.pl:
11768         (printWrapperFunctions):
11769         (printWrapperFactoryCppFile):
11770         (printWrapperFactoryHeaderFile):
11771         * html/MicroDataItemValue.idl:
11772         * inspector/ScriptProfile.idl:
11773         * inspector/ScriptProfileNode.idl:
11774         * page/DOMWindow.idl:
11775         * workers/WorkerContext.idl:
11776
11777 2012-11-13  Dimitri Glazkov  <dglazkov@chromium.org>
11778
11779         Unreviewed, rolling out r134367.
11780         http://trac.webkit.org/changeset/134367
11781         https://bugs.webkit.org/show_bug.cgi?id=100738
11782
11783         Speculative rollout, could have cause Dromaeo setAttribute
11784         perf regression.
11785
11786         * dom/Element.cpp:
11787         (WebCore::Element::attributeChanged):
11788         (WebCore::checkNeedsStyleInvalidationForClassChange):
11789         (WebCore::Element::classAttributeChanged):
11790
11791 2012-11-13  Marja Hölttä  <marja@chromium.org>
11792
11793         Add initiator to CachedResourceRequest.
11794         https://bugs.webkit.org/show_bug.cgi?id=101935
11795
11796         Reviewed by Adam Barth.
11797
11798         Motivation: Chromium needs to know which elements request a
11799         resource (such as an image or a script) (bug 92761). In addition,
11800         for exposing resource timing information (bug 84883) we need to
11801         store the initiator, and this is the first step towards it.
11802
11803         No new tests: No visible change in behavior.
11804
11805         * CMakeLists.txt:
11806         * GNUmakefile.list.am:
11807         * Target.pri:
11808         * WebCore.gypi:
11809         * WebCore.vcproj/WebCore.vcproj:
11810         * WebCore.xcodeproj/project.pbxproj:
11811         * css/CSSCrossfadeValue.cpp:
11812         (WebCore::cachedImageForCSSValue):
11813         * css/CSSCursorImageValue.cpp:
11814         (WebCore::CSSCursorImageValue::cachedImage):
11815         * css/CSSFontFaceSrcValue.cpp:
11816         (WebCore::CSSFontFaceSrcValue::cachedFont):
11817         * css/CSSImageSetValue.cpp:
11818         (WebCore::CSSImageSetValue::cachedImageSet):
11819         * css/CSSImageValue.cpp:
11820         (WebCore::CSSImageValue::cachedImage):
11821         * css/CSSImageValue.h:
11822         (WebCore):
11823         (CSSImageValue):
11824         * css/StyleResolver.cpp:
11825         (WebCore::StyleResolver::loadPendingImage):
11826         * css/StyleRuleImport.cpp:
11827         (WebCore::StyleRuleImport::requestStyleSheet):
11828         * css/WebKitCSSSVGDocumentValue.cpp:
11829         (WebCore::WebKitCSSSVGDocumentValue::load):
11830         * css/WebKitCSSShaderValue.cpp:
11831         (WebCore::WebKitCSSShaderValue::cachedShader):
11832         * dom/ScriptElement.cpp:
11833         (WebCore::ScriptElement::requestScript):
11834         * html/HTMLLinkElement.cpp:
11835         (WebCore::HTMLLinkElement::process):
11836         * html/parser/CSSPreloadScanner.cpp:
11837         (WebCore::CSSPreloadScanner::emitRule):
11838         * html/parser/CSSPreloadScanner.h:
11839         (CSSPreloadScanner):
11840         * html/parser/HTMLPreloadScanner.cpp:
11841         (WebCore::PreloadTask::preload):
11842         * loader/ImageLoader.cpp:
11843         (WebCore::ImageLoader::updateFromElement):
11844         * loader/cache/CachedResourceLoader.cpp:
11845         (WebCore::CachedResourceLoader::requestImage):
11846         (WebCore::CachedResourceLoader::requestResource):
11847         (WebCore::CachedResourceLoader::determineRevalidationPolicy):
11848         (WebCore):
11849         (WebCore::CachedResourceLoader::preload):
11850         * loader/cache/CachedResourceLoader.h:
11851         (WebCore):
11852         (CachedResourceLoader):
11853         * loader/cache/CachedResourceRequest.cpp:
11854         (WebCore::CachedResourceRequest::CachedResourceRequest):
11855         (WebCore):
11856         (WebCore::CachedResourceRequest::~CachedResourceRequest):
11857         (WebCore::CachedResourceRequest::setInitiator):
11858         (WebCore::CachedResourceRequest::initiatorName):
11859         (WebCore::CachedResourceRequest::initiatorDocument):
11860         (WebCore::CachedResourceRequest::initiatorElement):
11861         * loader/cache/CachedResourceRequest.h:
11862         (WebCore):
11863         (WebCore::CachedResourceRequest::setOptions):
11864         (WebCore::CachedResourceRequest::defer):
11865         (WebCore::CachedResourceRequest::setDefer):
11866         (CachedResourceRequest):
11867         * loader/cache/CachedResourceRequestInitiators.cpp: Copied from Source/WebCore/loader/cache/CachedResourceRequest.cpp.
11868         (WebCore):
11869         (WebCore::CachedResourceRequestInitiators::CachedResourceRequestInitiators):
11870         * loader/cache/CachedResourceRequestInitiators.h: Copied from Source/WebCore/loader/cache/CachedResourceRequest.cpp.
11871         (WebCore):
11872         (CachedResourceRequestInitiators):
11873         (WebCore::cachedResourceRequestInitiators):
11874         * loader/icon/IconLoader.cpp:
11875         (WebCore::IconLoader::startLoading):
11876         * platform/ThreadGlobalData.cpp:
11877         (WebCore::ThreadGlobalData::ThreadGlobalData):
11878         * platform/ThreadGlobalData.h:
11879         (WebCore):
11880         (WebCore::ThreadGlobalData::cachedResourceRequestInitiators):
11881         (ThreadGlobalData):
11882         * svg/SVGFEImageElement.cpp:
11883         (WebCore::SVGFEImageElement::requestImageResource):
11884         * svg/SVGFontFaceUriElement.cpp:
11885         (WebCore::SVGFontFaceUriElement::loadFont):
11886         * svg/SVGUseElement.cpp:
11887         (WebCore::SVGUseElement::svgAttributeChanged):
11888
11889 2012-11-13  Sheriff Bot  <webkit.review.bot@gmail.com>
11890
11891         Unreviewed, rolling out r134345.
11892         http://trac.webkit.org/changeset/134345
11893         https://bugs.webkit.org/show_bug.cgi?id=102106
11894
11895         Incomplete support for NATIVE_TYPE_ERR in objc and other
11896         bindings (Requested by jsbell on #webkit).
11897
11898         * Modules/mediastream/MediaConstraintsImpl.cpp:
11899         (WebCore::MediaConstraintsImpl::create):
11900         * Modules/mediastream/MediaStreamTrackList.cpp:
11901         (WebCore::MediaStreamTrackList::add):
11902         (WebCore::MediaStreamTrackList::remove):
11903         * Modules/mediastream/RTCDataChannel.cpp:
11904         (WebCore::RTCDataChannel::setBinaryType):
11905         * Modules/mediastream/RTCIceCandidate.cpp:
11906         (WebCore::RTCIceCandidate::create):
11907         * Modules/mediastream/RTCPeerConnection.cpp:
11908         (WebCore::RTCPeerConnection::parseConfiguration):
11909         (WebCore::RTCPeerConnection::createOffer):
11910         (WebCore::RTCPeerConnection::createAnswer):
11911         (WebCore::RTCPeerConnection::setLocalDescription):
11912         (WebCore::RTCPeerConnection::setRemoteDescription):
11913         (WebCore::RTCPeerConnection::addIceCandidate):
11914         (WebCore::RTCPeerConnection::addStream):
11915         (WebCore::RTCPeerConnection::removeStream):
11916         * Modules/mediastream/RTCSessionDescription.cpp:
11917         (WebCore::RTCSessionDescription::create):
11918         (WebCore::RTCSessionDescription::setType):
11919         * bindings/js/CallbackFunction.cpp:
11920         (WebCore::checkFunctionOnlyCallback):
11921         * bindings/js/JSCustomXPathNSResolver.cpp:
11922         (WebCore::JSCustomXPathNSResolver::create):
11923         * bindings/js/JSHTMLOptionsCollectionCustom.cpp:
11924         (WebCore::JSHTMLOptionsCollection::add):
11925         * bindings/js/JSHTMLSelectElementCustom.cpp:
11926         (WebCore::selectIndexSetter):
11927         * bindings/js/JSMutationObserverCustom.cpp:
11928         (WebCore::JSMutationObserverConstructor::constructJSMutationObserver):
11929         * bindings/js/JSSQLResultSetRowListCustom.cpp:
11930         (WebCore::JSSQLResultSetRowList::item):
11931         * bindings/js/JSSQLTransactionCustom.cpp:
11932         (WebCore::JSSQLTransaction::executeSql):
11933         * bindings/js/JSSQLTransactionSyncCustom.cpp:
11934         (WebCore::JSSQLTransactionSync::executeSql):
11935         * bindings/scripts/CodeGeneratorJS.pm:
11936         (GenerateParametersCheck):
11937         * bindings/scripts/CodeGeneratorObjC.pm:
11938         (GenerateImplementation):
11939         * bindings/scripts/CodeGeneratorV8.pm:
11940         (GenerateFunctionCallString):
11941         * bindings/v8/V8Callback.h:
11942         (WebCore::createFunctionOnlyCallback):
11943         * bindings/v8/V8Collection.cpp:
11944         (WebCore::toOptionsCollectionSetter):
11945         * bindings/v8/custom/V8DocumentCustom.cpp:
11946         (WebCore::V8Document::evaluateCallback):
11947         * bindings/v8/custom/V8HTMLOptionsCollectionCustom.cpp:
11948         (WebCore::V8HTMLOptionsCollection::addCallback):
11949         * bindings/v8/custom/V8MutationObserverCustom.cpp:
11950         (WebCore::V8MutationObserver::constructorCallback):
11951         * bindings/v8/custom/V8SQLTransactionCustom.cpp:
11952         (WebCore::V8SQLTransaction::executeSqlCallback):
11953         * bindings/v8/custom/V8SQLTransactionSyncCustom.cpp:
11954         (WebCore::V8SQLTransactionSync::executeSqlCallback):
11955         * dom/DOMCoreException.idl:
11956         * html/HTMLElement.cpp:
11957         (WebCore::HTMLElement::insertAdjacentElement):
11958         * html/HTMLMediaElement.cpp:
11959         (WebCore::HTMLMediaElement::webkitAddKey):
11960         * html/HTMLOptionsCollection.cpp:
11961         (WebCore::HTMLOptionsCollection::add):
11962         * html/canvas/CanvasRenderingContext2D.cpp:
11963         (WebCore::CanvasRenderingContext2D::drawImage):
11964         (WebCore::CanvasRenderingContext2D::createPattern):
11965         (WebCore::CanvasRenderingContext2D::putImageData):
11966         (WebCore::CanvasRenderingContext2D::webkitPutImageDataHD):
11967         * page/Crypto.cpp:
11968         (WebCore::Crypto::getRandomValues):
11969         * page/DOMSelection.cpp:
11970         (WebCore::DOMSelection::extend):
11971         * svg/properties/SVGTransformListPropertyTearOff.h:
11972         (WebCore::SVGTransformListPropertyTearOff::createSVGTransformFromMatrix):
11973
11974 2012-11-13  Erik Arvidsson  <arv@chromium.org>
11975
11976         Update DOMException name: HierarchyRequestError
11977         https://bugs.webkit.org/show_bug.cgi?id=102092
11978
11979         Reviewed by Ojan Vafai.
11980
11981         Patch 3 of 25 to update DOMException name to match the spec and Firefox.
11982
11983         Updated existing tests.
11984
11985         * dom/DOMCoreException.cpp:
11986
11987 2012-11-13  Kenneth Rohde Christiansen  <kenneth@webkit.org>
11988
11989         Clean up use of adjustWindowRect
11990         https://bugs.webkit.org/show_bug.cgi?id=102072
11991
11992         Reviewed by Alexis Menard.
11993
11994         Tested by fast/dom/Window/open-window-min-size.html
11995
11996         * loader/FrameLoader.cpp:
11997         (WebCore::createWindow):
11998
11999             Validate the window size here so that it is not just done for
12000             .open, but also for .showModalDialog. This is compatible with
12001             other browsers such as IE and Firefox (though IE > 6, enforces
12002             a minimum width of 250 instead of 100 as Firefox and us.)
12003
12004         * page/DOMWindow.cpp:
12005         (WebCore):
12006         (WebCore::DOMWindow::adjustWindowRect):
12007
12008             Make it a static method which only takes page. It was never
12009             called from anywhere without a valid page, so the page check
12010             has been turned into an assert, and two of the arguments have
12011             been removed as they can be accessed via the page.
12012
12013         (WebCore::DOMWindow::moveBy):
12014         (WebCore::DOMWindow::moveTo):
12015         (WebCore::DOMWindow::resizeBy):
12016         (WebCore::DOMWindow::resizeTo):
12017
12018             Update use of adjustWindowRect.
12019
12020         (WebCore::DOMWindow::open):
12021
12022             Avoid modifying the WindowFeatures as the WebCore::createWindow
12023             validates and adjusts the arguments.
12024
12025         * page/DOMWindow.h:
12026         (DOMWindow):
12027
12028 2012-11-13  Bem Jones-Bey  <bjonesbe@adobe.com>
12029
12030         [CSS Exclusions] Update wrap-margin/padding to shape-margin/padding
12031         https://bugs.webkit.org/show_bug.cgi?id=97736
12032
12033         Reviewed by Andreas Kling.
12034
12035         Rename properties to match updated spec.
12036
12037         Tests: fast/exclusions/shape-margin-parsing.html
12038                fast/exclusions/shape-padding-parsing.html
12039
12040         * css/CSSComputedStyleDeclaration.cpp:
12041         (WebCore):
12042         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
12043         * css/CSSParser.cpp:
12044         (WebCore::isSimpleLengthPropertyID):
12045         (WebCore::CSSParser::parseValue):
12046         * css/CSSProperty.cpp:
12047         (WebCore::CSSProperty::isInheritedProperty):
12048         * css/CSSPropertyNames.in:
12049         * css/StyleBuilder.cpp:
12050         (WebCore::StyleBuilder::StyleBuilder):
12051         * css/StylePropertySet.cpp:
12052         (WebCore::StylePropertySet::asText):
12053         * css/StylePropertyShorthand.cpp:
12054         (WebCore::webkitWrapShorthand):
12055         * css/StyleResolver.cpp:
12056         (WebCore::StyleResolver::applyProperty):
12057         * rendering/style/RenderStyle.cpp:
12058         (WebCore::RenderStyle::diff):
12059         * rendering/style/RenderStyle.h:
12060         * rendering/style/StyleRareNonInheritedData.cpp:
12061         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
12062         (WebCore::StyleRareNonInheritedData::operator==):
12063         * rendering/style/StyleRareNonInheritedData.h:
12064         (StyleRareNonInheritedData):
12065
12066 2012-11-13  Dimitri Glazkov  <dglazkov@chromium.org>
12067
12068         Unreviewed, rolling out r134418.
12069         http://trac.webkit.org/changeset/134418
12070         https://bugs.webkit.org/show_bug.cgi?id=101903
12071
12072         The newly added test is crashing on cr-win.
12073
12074         * dom/ElementShadow.cpp:
12075         * dom/ElementShadow.h:
12076         * html/HTMLInputElement.cpp:
12077         (WebCore::HTMLInputElement::updateType):
12078         (WebCore::HTMLInputElement::setIndeterminate):
12079         * html/HTMLProgressElement.cpp:
12080         (WebCore::HTMLProgressElement::didElementStateChange):
12081         * html/shadow/SelectRuleFeatureSet.cpp:
12082         (WebCore::SelectRuleFeatureSet::add):
12083         (WebCore::SelectRuleFeatureSet::clear):
12084         (WebCore::SelectRuleFeatureSet::collectFeaturesFromSelector):
12085         * html/shadow/SelectRuleFeatureSet.h:
12086         (SelectRuleFeatureSet):
12087
12088 2012-11-13  Dimitri Glazkov  <dglazkov@chromium.org>
12089
12090         Unreviewed, rolling out r134391.
12091         http://trac.webkit.org/changeset/134391
12092         https://bugs.webkit.org/show_bug.cgi?id=99660
12093
12094         Speculative rollout, trying to fix browser_tests failure.
12095
12096         * English.lproj/localizedStrings.js:
12097         * inspector/Inspector.json:
12098         * inspector/InspectorClient.h:
12099         * inspector/InspectorPageAgent.cpp:
12100         (PageAgentState):
12101         (WebCore::InspectorPageAgent::enable):
12102         (WebCore::InspectorPageAgent::disable):
12103         * inspector/InspectorPageAgent.h:
12104         * inspector/front-end/Settings.js:
12105         * inspector/front-end/SettingsScreen.js:
12106         (WebInspector.GenericSettingsTab):
12107         * inspector/front-end/inspector.js:
12108         (WebInspector.doLoadedDone):
12109
12110 2012-11-13  Sheriff Bot  <webkit.review.bot@gmail.com>
12111
12112         Unreviewed, rolling out r134205.
12113         http://trac.webkit.org/changeset/134205
12114         https://bugs.webkit.org/show_bug.cgi?id=102093
12115
12116         Broke webkit-flow-inlines-dynamic.html on several ports
12117         (Requested by mihnea on #webkit).
12118
12119         * css/StyleResolver.cpp:
12120         (WebCore::StyleResolver::isValidRegionStyleProperty):
12121         * rendering/InlineBox.cpp:
12122         * rendering/InlineBox.h:
12123         (WebCore):
12124         (InlineBox):
12125         * rendering/InlineFlowBox.cpp:
12126         (WebCore::InlineFlowBox::addToLine):
12127         (WebCore::InlineFlowBox::addTextBoxVisualOverflow):
12128         * rendering/RenderRegion.cpp:
12129         (WebCore::RenderRegion::setRegionObjectsRegionStyle):
12130         (WebCore::RenderRegion::restoreRegionObjectsOriginalStyle):
12131         (WebCore::RenderRegion::computeStyleInRegion):
12132         (WebCore::RenderRegion::computeChildrenStyleInRegion):
12133         (WebCore::RenderRegion::setObjectStyleInRegion):
12134         (WebCore::RenderRegion::clearObjectStyleInRegion):
12135         * rendering/RenderRegion.h:
12136         (RenderRegion):
12137         (ObjectRegionStyleInfo):
12138
12139 2012-11-13  Andreas Kling  <kling@webkit.org>
12140
12141         Remove the non-const overload of ElementAttributeData::inlineStyle().
12142
12143         Rubber-stamped by Anders Koivisto.
12144
12145         No call sites actually needed a mutable StylePropertySet* from inlineStyle() anyway.
12146
12147         * dom/ElementAttributeData.h:
12148
12149 2012-11-13  Keishi Hattori  <keishi@webkit.org>
12150
12151         [Chromium] Enable input type month/week
12152         https://bugs.webkit.org/show_bug.cgi?id=102042
12153
12154         Reviewed by Kent Tamura.
12155
12156         Enable input type month/week for Chromium.
12157
12158         No new tests. Tests will be added later in Bug 102045 and Bug 102046.
12159
12160         * bindings/generic/RuntimeEnabledFeatures.cpp:
12161         (WebCore):
12162
12163 2012-11-13  Shinya Kawanaka  <shinyak@chromium.org>
12164
12165         [Refactoring] Remove shadowPseudoId() and use setPseudo() in <meter> ElementShadow.
12166         https://bugs.webkit.org/show_bug.cgi?id=101906
12167
12168         Reviewed by Dimitri Glazkov.
12169
12170         We're migrating shadowPseudoId() to pseudo(). We remove shadowPseudoId() from HTMLKeygenElement and use
12171         setPseudo()/pseudo() instead.
12172
12173         No new tests, covered by existing tests.
12174
12175         * html/HTMLMeterElement.cpp:
12176         (WebCore::HTMLMeterElement::didElementStateChange): Since shadowPseudoId() was returning pseudo id without setting
12177         it anywhere, we have to set it into pseudo attribute here.
12178         (WebCore::HTMLMeterElement::createShadowSubtree): ditto.
12179         * html/shadow/MeterShadowElement.cpp:
12180         (WebCore::MeterInnerElement::MeterInnerElement):
12181         (WebCore::MeterValueElement::valuePseudoId):
12182         * html/shadow/MeterShadowElement.h:
12183         (MeterInnerElement):
12184         (WebCore::MeterBarElement::MeterBarElement):
12185         (MeterBarElement):
12186         (WebCore::MeterValueElement::MeterValueElement):
12187         (WebCore::MeterValueElement::updatePseudo):
12188         (MeterValueElement):
12189
12190 2012-11-13  Shinya Kawanaka  <shinyak@chromium.org>
12191
12192         Changing pseudoClass (:indeterminate) should cause distribution
12193         https://bugs.webkit.org/show_bug.cgi?id=101903
12194
12195         Reviewed by Dimitri Glazkov.
12196
12197         <progress> and <input type="checkbox"> have 'indeterminate' state. When their state is changed, we have to
12198         invalidate distribution if necessary. To check it, we collect a feature that :invalidate is used in select attributes.
12199
12200         For <input>, we also have to see 'type' is changed. According to the spec, :indeterminate should match only
12201         progress element or <input type="checkbox">. So changing 'type' might also change :indeterminate state.
12202
12203         Tests: fast/dom/shadow/pseudoclass-update-indeterminate-input.html
12204                fast/dom/shadow/pseudoclass-update-indeterminate-progress.html
12205
12206         * dom/ElementShadow.cpp:
12207         (WebCore::invalidateParentDistributionIfNecessary): Since we will add a lot of pseudoClass check later, we would like to
12208         have this kind of helper method. We will add various pseudoClass check (see Bug 101697), we reuse CSSSelector::PseudoType
12209         here.
12210         (WebCore):
12211         * dom/ElementShadow.h:
12212         (WebCore):
12213         * html/HTMLInputElement.cpp:
12214         (WebCore::HTMLInputElement::updateType): Invalidate parent distribution anyway, since it changes various internal states.
12215         (WebCore::HTMLInputElement::setIndeterminate): Invalidate parent distribution if necessary.
12216         * html/HTMLProgressElement.cpp:
12217         (WebCore::HTMLProgressElement::didElementStateChange):
12218         * html/shadow/SelectRuleFeatureSet.cpp:
12219         (WebCore::SelectRuleFeatureSet::SelectRuleFeatureSet): Adds m_usesIndeterminate feature.
12220         (WebCore::SelectRuleFeatureSet::add):
12221         (WebCore::SelectRuleFeatureSet::clear):
12222         (WebCore::SelectRuleFeatureSet::collectFeaturesFromSelector):
12223         * html/shadow/SelectRuleFeatureSet.h:
12224         (WebCore::SelectRuleFeatureSet::hasSelectorForIndeterminate):
12225         (SelectRuleFeatureSet):
12226
12227 2012-11-13  Andreas Kling  <kling@webkit.org>
12228
12229         Exploit ElementAttributeData sharing in Node.cloneNode.
12230         <http://webkit.org/b/101374>
12231
12232         Reviewed by Anders Carlsson.
12233
12234         Instead of blindly creating a new ElementAttributeData for Node.cloneNode, let's be clever!
12235         If the source data is immutable, simply ref it from the new node at virtually no cost.
12236
12237         If the source data is mutable, convert it to immutable data so it can be shared between both nodes.
12238         Since the typical use-case for Node.cloneNode is to create-once/clone-many, this saves both time
12239         and memory in the long run.
12240
12241         ~8% speed-up on PerformanceTests/DOM/CloneNodes on my MBP.
12242
12243         * dom/Element.cpp:
12244         (WebCore::Element::cloneAttributesFromElement):
12245
12246             Move attribute data cloning logic from ElementAttributeData to Element.
12247
12248         * dom/ElementAttributeData.cpp:
12249         (WebCore::ImmutableElementAttributeData::~ImmutableElementAttributeData):
12250         (WebCore::ImmutableElementAttributeData::ImmutableElementAttributeData):
12251         (WebCore::ElementAttributeData::ElementAttributeData):
12252         (WebCore::MutableElementAttributeData::MutableElementAttributeData):
12253         (WebCore::ElementAttributeData::makeMutableCopy):
12254         (WebCore::ElementAttributeData::makeImmutableCopy):
12255         * dom/ElementAttributeData.h:
12256         (ElementAttributeData):
12257         (ImmutableElementAttributeData):
12258         (MutableElementAttributeData):
12259
12260             Add facilities for converting a mutable ElementAttributeData to an immutable one.
12261             Share some code in the common base class constructor.
12262
12263 2012-11-13  Kentaro Hara  <haraken@chromium.org>
12264
12265         Unreviewed. Build fix of V8 bindings.
12266
12267         * bindings/v8/V8DOMWrapper.cpp:
12268         (WebCore::V8DOMWrapper::maybeDOMWrapper):
12269
12270 2012-11-13  Andrey Adaikin  <aandrey@chromium.org>
12271
12272         Web Inspector: [Canvas] UI: make the Grid save scrolling position, show wait spinner icon
12273         https://bugs.webkit.org/show_bug.cgi?id=102071
12274
12275         Reviewed by Pavel Feldman.
12276
12277         * inspector/front-end/CanvasProfileView.js:
12278         (WebInspector.CanvasProfileView):
12279         (WebInspector.CanvasProfileView.prototype.dispose):
12280         (WebInspector.CanvasProfileView.prototype.elementsToRestoreScrollPositionsFor):
12281         (WebInspector.CanvasProfileView.prototype._enableWaitIcon):
12282         (WebInspector.CanvasProfileView.prototype._replayTraceLog.didReplayTraceLog):
12283         (WebInspector.CanvasProfileView.prototype._replayTraceLog):
12284         (WebInspector.CanvasProfileView.prototype._didReceiveTraceLog):
12285         (WebInspector.CanvasProfileView.prototype._createCallNode):
12286         * inspector/front-end/canvasProfiler.css:
12287         (#canvas-replay-image.wait):
12288
12289 2012-11-13  Eugene Klyuchnikov  <eustas.bug@gmail.com>
12290
12291         Web Inspector: Settings screen: some panel shortcuts are missing
12292         https://bugs.webkit.org/show_bug.cgi?id=101026
12293
12294         Reviewed by Pavel Feldman.
12295
12296         Panels, that have not been loaded by the time shortcuts view was
12297         initialized, had no chance to register shortcuts.
12298
12299         Solution: move shortcut registration (for shortcuts screen) to panel
12300         descriptors.
12301
12302         More changes: add JsDoc annotations to ShortcutScreen and change "key"
12303         parameter type for raw string to key descriptor object.
12304
12305         * WebCore.gypi: Added TimelinePanelDescriptor.js file.
12306         * WebCore.vcproj/WebCore.vcproj: Ditto.
12307         * inspector/compile-front-end.py: Ditto.
12308         * inspector/front-end/WebKit.qrc: Ditto.
12309         * inspector/front-end/inspector.html: Ditto.
12310         * inspector/front-end/AdvancedSearchController.js: Add JsDoc annotation.
12311         * inspector/front-end/GoToLineDialog.js: Ditto.
12312         * inspector/front-end/CallStackSidebarPane.js: Removed shortcut-screen
12313         shortcuts registration.
12314         * inspector/front-end/ElementsPanel.js: Ditto.
12315         * inspector/front-end/ScriptsPanel.js: Ditto.
12316         * inspector/front-end/StylesSidebarPane.js: Ditto.
12317         * inspector/front-end/TimelinePanel.js: Ditto.
12318         * inspector/front-end/ConsoleView.js: Changes order of lines to increase
12319         readability.
12320         * inspector/front-end/ElementsPanelDescriptor.js: Add shortcut-screen
12321         shortcuts registration and key descriptor constants.
12322         * inspector/front-end/ScriptsPanelDescriptor.js: Ditto.
12323         * inspector/front-end/TimelinePanelDescriptor.js: Ditto.
12324         * inspector/front-end/Panel.js: Removed unused "uregisterShortcut"; made
12325         "registerShortcuts" method accept array of key descriptors.
12326         (WebInspector.PanelDescriptor.prototype.registerShortcuts): Added.
12327         * inspector/front-end/ShortcutsScreen.js: Added JsDoc; changed parameter
12328         type from string to key descriptor.
12329         * inspector/front-end/inspector.js: Register shortcuts using
12330         panel descriptors.
12331         (WebInspector._panelDescriptors): Removed duplicate line.
12332
12333 2012-11-13  Gabor Rapcsanyi  <rgabor@webkit.org>
12334
12335         Optimize RGB565 and RGBA5551 packing/unpacking functions with NEON intrinsics
12336         https://bugs.webkit.org/show_bug.cgi?id=102060
12337
12338         Reviewed by Zoltan Herczeg.
12339
12340         Adding more NEONized packing functions to GraphicsContext3DNEON.h.
12341         These functions are three times faster with this intrinsics optimizations.
12342
12343         * platform/graphics/GraphicsContext3D.cpp:
12344         (WebCore):
12345         * platform/graphics/cpu/arm/GraphicsContext3DNEON.h:
12346         (WebCore::ARM::unpackOneRowOfRGBA5551ToRGBA8NEON):
12347         (ARM):
12348         (WebCore::ARM::packOneRowOfRGBA8ToUnsignedShort5551NEON):
12349         (WebCore::ARM::unpackOneRowOfRGB565ToRGBA8NEON):
12350         (WebCore::ARM::packOneRowOfRGBA8ToUnsignedShort565NEON):
12351
12352 2012-11-13  Csaba Osztrogonác  <ossy@webkit.org>
12353
12354         [Qt] Enable Mutation observer
12355         https://bugs.webkit.org/show_bug.cgi?id=102066
12356
12357         Reviewed by Pavel Feldman.
12358
12359         * DerivedSources.pri: Add missing IDL files.
12360
12361 2012-11-13  Kentaro Hara  <haraken@chromium.org>
12362
12363         [V8] Make isValidDOMObject() static
12364         https://bugs.webkit.org/show_bug.cgi?id=101914
12365
12366         Reviewed by Adam Barth.
12367
12368         isValidDOMObject() is used by DOMWrapper.cpp only.
12369
12370         No tests. No change in behavior.
12371
12372         * bindings/v8/V8DOMWrapper.cpp:
12373         (WebCore::isValidDOMObject):
12374         (WebCore):
12375         (WebCore::V8DOMWrapper::maybeDOMWrapper):
12376         * bindings/v8/V8DOMWrapper.h:
12377         (V8DOMWrapper):
12378
12379 2012-11-13  Mihnea Ovidenie  <mihnea@adobe.com>
12380
12381         [CSSRegions] Incorrect computed height for content with region-break-before
12382         https://bugs.webkit.org/show_bug.cgi?id=101862
12383
12384         Reviewed by Julien Chaffraix.
12385
12386         When processing the region breaks for auto-height regions, we skipped the case
12387         when the region-break-before occurred in the first region in the chain which was
12388         an auto-height region. Because of that, the region computed height was not 0
12389         as it was supposed to be, but rather LayoutUnit::max() / 2.
12390
12391         Test: fast/regions/autoheight-breakbefore-wrongheight.html
12392
12393         * rendering/RenderFlowThread.cpp:
12394         (WebCore::RenderFlowThread::addForcedRegionBreak):
12395         Make sure we process also the case when the region-break occurs at offset 0 in the flow thread
12396         and the first region in chain is an auto-height region.
12397         * rendering/RenderRegion.cpp:
12398         (WebCore::RenderRegion::updateLogicalHeight):
12399         Add an assert to make sure that the computed height for auto-height regions is always less than LayoutUnit::max() / 2.
12400
12401 2012-11-13  Yury Semikhatsky  <yurys@chromium.org>
12402
12403         Memory instrumentation: remove reportMemoryUsage method from ImageObserver
12404         https://bugs.webkit.org/show_bug.cgi?id=102058
12405
12406         Reviewed by Pavel Feldman.
12407
12408         * bindings/v8/V8PerIsolateData.cpp:
12409         (WebCore::V8PerIsolateData::reportMemoryUsage): drive-by fix, no need to report
12410         each element of the vector as generic vector instrumentation will take care of it.
12411         * platform/graphics/Image.cpp: the client is reported as weak pointer to make sure
12412         we don't count its by the pointer to the base class which may differ from the actual
12413         object address.
12414         (WebCore::Image::reportMemoryUsage):
12415         * platform/graphics/ImageObserver.h: removed reportMemoryUsage method from the interface.
12416         (ImageObserver):
12417
12418 2012-11-13  Eberhard Graether  <egraether@google.com>
12419
12420         checkbox to toggle FPS counter in the inspector's settings
12421         https://bugs.webkit.org/show_bug.cgi?id=99660
12422
12423         Reviewed by Pavel Feldman.
12424
12425         Added a checkbox to the inspector's settings to toggle a FPS counter. The checkbox appears when InspectorClient::canShowFPSCounter() returns true.
12426
12427         No new tests.
12428
12429         * English.lproj/localizedStrings.js:
12430         * inspector/Inspector.json:
12431         * inspector/InspectorClient.h:
12432         (WebCore::InspectorClient::canShowFPSCounter):
12433         (WebCore::InspectorClient::setShowFPSCounter):
12434         (InspectorClient):
12435         * inspector/InspectorPageAgent.cpp:
12436         (PageAgentState):
12437         (WebCore::InspectorPageAgent::enable):
12438         (WebCore::InspectorPageAgent::disable):
12439         (WebCore::InspectorPageAgent::canShowFPSCounter):
12440         (WebCore):
12441         (WebCore::InspectorPageAgent::setShowFPSCounter):
12442         * inspector/InspectorPageAgent.h:
12443         * inspector/front-end/Settings.js:
12444         * inspector/front-end/SettingsScreen.js:
12445         (WebInspector.GenericSettingsTab):
12446         (WebInspector.GenericSettingsTab.prototype.get _showFPSCounterChanged):
12447         * inspector/front-end/inspector.js:
12448         (WebInspector.doLoadedDone):
12449
12450 2012-11-12  Kent Tamura  <tkent@chromium.org>
12451
12452         Unable to set valid time value to input[type=time] with user interaction in some cases
12453         https://bugs.webkit.org/show_bug.cgi?id=102048
12454
12455         Reviewed by Kentaro Hara.
12456
12457         The implementations of shouldMillisecondFieldReadOnly,
12458         shouldMinuteFieldReadOnly, and shouldSecondFieldReadOnly were
12459         incorrect. We need to check if a part of the minimum value matches to
12460         the corresponding part of the current value.
12461
12462         Also, we had better check hour field editability.
12463
12464         Test: fast/forms/time-multiple-fields/time-multiple-fields-readonly-subfield.html
12465
12466         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
12467         (WebCore::BaseMultipleFieldsDateAndTimeInputType::shouldHaveSecondField):
12468         Fix a problem that hh:mm:00.sss didn't create a seconds field.
12469         * html/shadow/DateTimeEditElement.cpp:
12470         (DateTimeEditBuilder): Add shouldHourFieldReadOnly declaration.
12471         (WebCore::DateTimeEditBuilder::visitField):
12472         Add shouldHourFieldReadOnly check to Hour11/Hour12/Hour23/Hour24/Period fields.
12473         (WebCore::DateTimeEditBuilder::shouldHourFieldReadOnly):
12474         Added. An hour field should be read-only if the step value is a multiple
12475         of a day and the hour part of the minimum value matches to the hour part
12476         of the value.
12477         (WebCore::DateTimeEditBuilder::shouldMillisecondFieldReadOnly):
12478         A millisecond field should be read-only if the step value is a multiple
12479         of one second and the millisecond part of the minimum value matches to
12480         the millisecond part of the value.
12481         (WebCore::DateTimeEditBuilder::shouldMinuteFieldReadOnly):
12482         A minute field should be read-only if the step value is a multiple of
12483         one hour and the minute part of the minimum value matches to the minute
12484         part of the value.
12485         (WebCore::DateTimeEditBuilder::shouldSecondFieldReadOnly):
12486         A second field should be read-only if the step value is a multiple of
12487         one minute and the second part of the minimum value matches to the second
12488         part of the value.
12489         * platform/Decimal.cpp:
12490         (WebCore::Decimal::remainder):
12491         Fix a bug in case that the fractional part of quotient is >= 0.5. Also
12492         make this matches to C99, C++11, ECMAScript behavior.
12493
12494 2012-11-13  Yury Semikhatsky  <yurys@chromium.org>
12495
12496         Memory instrumentation: MemoryBlock name should not include full path to the block
12497         https://bugs.webkit.org/show_bug.cgi?id=102055
12498
12499         Reviewed by Pavel Feldman.
12500
12501         * inspector/InspectorMemoryAgent.cpp: pass only last path component as MemoryBlock name
12502         intead of fully qualified name.
12503
12504 2012-11-13  Pavel Feldman  <pfeldman@chromium.org>
12505
12506         Web Inspector: get rid of enter/exitTextChangeMode in the editor
12507         https://bugs.webkit.org/show_bug.cgi?id=101845
12508
12509         Reviewed by Vsevolod Vlasov.
12510
12511         They seem to do nothing.
12512
12513         * inspector/front-end/DefaultTextEditor.js:
12514         (WebInspector.DefaultTextEditor.prototype._textChanged):
12515         (WebInspector.DefaultTextEditor.prototype.editRange):
12516         (WebInspector.TextEditorMainPanel):
12517         (WebInspector.TextEditorMainPanel.prototype.handleUndoRedo):
12518         (WebInspector.TextEditorMainPanel.prototype.handleEnterKey.get var):
12519         (WebInspector.TextEditorMainPanel.prototype.handleEnterKey):
12520         (WebInspector.TextEditorMainPanel.prototype._applyDomUpdates):
12521         * inspector/front-end/TextEditorModel.js:
12522         (WebInspector.TextEditorModel.endsWithBracketRegex.):
12523
12524 2012-11-13  Tommy Widenflycht  <tommyw@google.com>
12525
12526         Remove the custom WebSocket::send for both V8 and JSC
12527         https://bugs.webkit.org/show_bug.cgi?id=101936
12528
12529         Reviewed by Kentaro Hara.
12530
12531         This patch removes the custom WebSocket::send since it isn't needed anymore.
12532
12533         Patch covered by existing tests.
12534
12535         * Modules/websockets/WebSocket.idl:
12536         * UseV8.cmake:
12537         * WebCore.gypi:
12538         * bindings/js/JSWebSocketCustom.cpp:
12539         * bindings/v8/custom/V8WebSocketCustom.cpp: Removed.
12540
12541 2012-11-13  Pavel Feldman  <pfeldman@chromium.org>
12542
12543         Web Inspector: move indentation logic into TextEditorModel
12544         https://bugs.webkit.org/show_bug.cgi?id=101842
12545
12546         Reviewed by Vsevolod Vlasov.
12547
12548         I'd like to move as much headless logic into the TextEditorModel as possible.
12549         Drive by: removed some dead code, converted getter into function and moved undo
12550         mark state into the model as well.
12551
12552         * inspector/front-end/DefaultTextEditor.js:
12553         (WebInspector.DefaultTextEditor.prototype.editRange):
12554         (WebInspector.DefaultTextEditor.prototype._syncDecorationsForLine):
12555         (WebInspector.TextEditorChunkedPanel.prototype._splitChunkOnALine):
12556         (WebInspector.TextEditorMainPanel.prototype.handleEnterKey.get var):
12557         (WebInspector.TextEditorMainPanel.prototype.handleEnterKey):
12558         (WebInspector.TextEditorMainPanel.prototype._applyDomUpdates):
12559         (WebInspector.TextEditorMainPanel.prototype._updateChunksForRanges):
12560         (WebInspector.TextEditorMainChunk):
12561         (WebInspector.TextEditorMainChunk.prototype.isDecorated):
12562         (WebInspector.TextEditorMainChunk.prototype.set expanded):
12563         * inspector/front-end/TextEditorModel.js:
12564         (WebInspector.TextEditorModel.endsWithBracketRegex.):
12565
12566 2012-11-13  Hayato Ito  <hayato@chromium.org>
12567
12568         Unreviewed attempt to fix the chromium mac-build after r134348.
12569
12570         * platform/graphics/mac/FontMac.mm:
12571         (WebCore::Font::drawGlyphs):
12572         * platform/mac/WebCoreSystemInterface.h:
12573         * platform/mac/WebCoreSystemInterface.mm:
12574
12575 2012-11-13  Pavel Feldman  <pfeldman@chromium.org>
12576
12577         Web Inspector: migrate text editor to mutation observers
12578         https://bugs.webkit.org/show_bug.cgi?id=101841
12579
12580         Reviewed by Vsevolod Vlasov.
12581
12582         Otherwise, we miss notifications on the removed lines.
12583
12584         * inspector/front-end/DefaultTextEditor.js:
12585         (WebInspector.DefaultTextEditor.prototype.wasShown):
12586         (WebInspector.DefaultTextEditor.prototype.willHide):
12587         (WebInspector.TextEditorChunkedPanel.prototype._repaintAll):
12588         (WebInspector.TextEditorMainPanel):
12589         (WebInspector.TextEditorMainPanel.prototype._wasShown):
12590         (WebInspector.TextEditorMainPanel.prototype._willHide):
12591         (WebInspector.TextEditorMainPanel.prototype.markAndRevealRange):
12592         (WebInspector.TextEditorMainPanel.prototype.beginDomUpdates):
12593         (WebInspector.TextEditorMainPanel.prototype.endDomUpdates):
12594         (WebInspector.TextEditorMainPanel.prototype._paintScheduledLines):
12595         (WebInspector.TextEditorMainPanel.prototype._paintLineChunks):
12596         (WebInspector.TextEditorMainPanel.prototype._paintLine):
12597         (WebInspector.TextEditorMainPanel.prototype._insertSpanBefore):
12598         (WebInspector.TextEditorMainPanel.prototype._handleMutations.else.get if):
12599         (WebInspector.TextEditorMainPanel.prototype._handleMutations):
12600         (WebInspector.TextEditorMainPanel.prototype._collectDirtyLines):
12601         (WebInspector.TextEditorMainPanel.prototype._applyDomUpdates):
12602         * inspector/front-end/externs.js:
12603         (WebKitMutation):
12604         (WebKitMutationObserver.prototype.observe):
12605         (WebKitMutationObserver.prototype.disconnect):
12606         * inspector/front-end/textEditor.css:
12607         (.debug-fadeout):
12608         (@-webkit-keyframes debug-fadeout):
12609         (to):
12610
12611 2012-11-13  Gabor Rapcsanyi  <rgabor@webkit.org>
12612
12613         Optimize RGBA4444ToRGBA8 packing/unpacking functions with NEON intrinsics in GraphicsContext3D
12614         https://bugs.webkit.org/show_bug.cgi?id=101473
12615
12616         Reviewed by Zoltan Herczeg.
12617
12618         With NEON intrinsics the packing/unpacking functions can be optimized well.
12619         This particular function is about 3 times faster with ARM NEON. On top level tests
12620         the speed up was 1.18x.
12621
12622         * CMakeLists.txt:
12623         * GNUmakefile.am:
12624         * GNUmakefile.list.am:
12625         * Target.pri:
12626         * WebCore.gyp/WebCore.gyp:
12627         * WebCore.gypi:
12628         * WebCore.pri:
12629         * WebCore.xcodeproj/project.pbxproj:
12630         * platform/graphics/GraphicsContext3D.cpp:
12631         (WebCore):
12632         * platform/graphics/cpu/arm/GraphicsContext3DNEON.h: Added.
12633         (WebCore):
12634         (ARM):
12635         (WebCore::ARM::unpackOneRowOfRGBA4444ToRGBA8NEON):
12636         (WebCore::ARM::packOneRowOfRGBA8ToUnsignedShort4444NEON):
12637
12638 2012-11-13  Takashi Sakamoto  <tasak@google.com>
12639
12640         Crash when replacing parts of text inputs with content: url(...)
12641         https://bugs.webkit.org/show_bug.cgi?id=101133
12642
12643         Reviewed by Kent Tamura.
12644
12645         Disable directly setting content of elements in an input element's
12646         shadow dom tree, because the setting breaks input element's behavior.
12647
12648         Tests: fast/forms/number/number-content-url-crash.html
12649                fast/forms/search/search-content-url-crash.html
12650
12651         * css/html.css:
12652         (input::-webkit-textfield-decoration-container):
12653         Use important to disable overriding an input element's content
12654         property.
12655         * html/TextFieldInputType.cpp:
12656         (WebCore::TextFieldInputType::attach):
12657         Added ASSERTION. No content should be applied to
12658         input::-webkit-textfield-decoration-container.
12659
12660 2012-11-12  Huang Dongsung  <luxtella@company100.net>
12661
12662         [Qt] REGRESSION(134142): overscaled tiles in pixel test results and MiniBrowser
12663         https://bugs.webkit.org/show_bug.cgi?id=101918
12664
12665         Reviewed by Noam Rosenthal.
12666
12667         Remove TiledBackingStore::rect(), because it is not used anymore.
12668
12669         * platform/graphics/TiledBackingStore.h:
12670         (TiledBackingStore):
12671
12672 2012-11-12  Adam Barth  <abarth@webkit.org>
12673
12674         [V8] We should be able to recover the V8DOMWindowShell more quickly
12675         https://bugs.webkit.org/show_bug.cgi?id=102020
12676
12677         Reviewed by Kentaro Hara.
12678
12679         For isolated worlds, we used to store the V8DOMWindowShell as an
12680         internal field of the inner DOM window. This patch moves the pointer to
12681         an internal field of the v8::Context, which saves us the work of
12682         looking up the inner DOM window.
12683
12684         Unfortunately, we cannot store the V8DOMWindowShell in V8PerContextData
12685         because the V8DOMWindowShell outlives the V8PerContextData. (We destroy
12686         the V8PerContextData when we detach the V8DOMWindowShell from the
12687         frame.)
12688
12689         * bindings/scripts/CodeGeneratorV8.pm:
12690         (GetInternalFields):
12691         * bindings/v8/V8DOMWindowShell.cpp:
12692         (WebCore::V8DOMWindowShell::initializeIfNeeded):
12693         * bindings/v8/V8DOMWindowShell.h:
12694         (WebCore::V8DOMWindowShell::getEntered):
12695         * bindings/v8/V8PerContextData.h:
12696
12697 2012-11-12  Kentaro Hara  <haraken@chromium.org>
12698
12699         [V8] Add ASSERT() to guarantee that we don't store NULL pointers to V8 internal fields
12700         https://bugs.webkit.org/show_bug.cgi?id=101054
12701
12702         Reviewed by Adam Barth.
12703
12704         I'm investigating a Chromium crash bug:
12705         http://code.google.com/p/chromium/issues/detail?id=155942
12706
12707         I've not yet identified the root cause (because I can't reproduce
12708         the crash), but it looks like we are storing NULL pointers to
12709         V8 internal fields. Just in case, we can add an ASSERT() to
12710         guarantee that NULL pointers are never stored. (Also I'm hoping
12711         that this ASSERT() will give me more debug information.)
12712
12713         No tests. No change in behavior.
12714
12715         * bindings/v8/V8DOMWrapper.h:
12716         (WebCore::V8DOMWrapper::setDOMWrapper):
12717
12718 2012-11-12  Shinya Kawanaka  <shinyak@chromium.org>
12719
12720         Changing id, className, or attribute should invalidate distribution
12721         https://bugs.webkit.org/show_bug.cgi?id=100738
12722
12723         Reviewed by Dimitri Glazkov.
12724
12725         When id, className, or attribute is changed, we might have to invalidate distribution.
12726         However, we don't want to do useless invalidation. So we consult with the RuleFeatureSet of ElementShadow,
12727         and invalidate distribution only if necessary.
12728
12729         When className is changed, we can share a lot of code between invalidating distribution and invalidating style.
12730         So we made checkNeedsStyleInvalidationForClassChange a template method, and share it.
12731
12732         Also we've measured how this patch makes changing attribute slow. By converting checkNeedsStyleInvalidationForClassChange
12733         to template, actually this improves the performance of changing attribute code. I've measured each code 3 times.
12734
12735         DOM/ModifyAttribute.html
12736         Before this patch:
12737                 median  stdev  min      max    [ms]
12738           1st   115.62   0.67  114.75   117.00
12739           2nd   115.08   1.13  113.25   117.58
12740           3rd   114.75   1.16  113.42   117.83
12741
12742         After this patch:
12743                 median  stdev  min      max    [ms]
12744           1st   102.55   0.95  101.25   104.50
12745           2nd   103.10   0.86  102.20   100.95
12746           3rd   103.30   1.05  102.10   106.65
12747
12748         Tests: fast/dom/shadow/distribution-attribute-modified.html
12749                fast/dom/shadow/distribution-className-modified.html
12750                fast/dom/shadow/distribution-id-modified.html
12751                fast/dom/shadow/reprojection-attribute-modified.html
12752                fast/dom/shadow/reprojection-className-modified.html
12753                fast/dom/shadow/reprojection-id-modified.html
12754
12755         * dom/Element.cpp:
12756         (WebCore::Element::attributeChanged):
12757         (WebCore::HasSelectorForClassStyleFunctor::HasSelectorForClassStyleFunctor):
12758         (HasSelectorForClassStyleFunctor):
12759         (WebCore::HasSelectorForClassStyleFunctor::operator()): Returns true if StyleResolver::hasSelectorForClass returns true.
12760         (WebCore):
12761         (WebCore::HasSelectorForClassDistributionFunctor::HasSelectorForClassDistributionFunctor):
12762         (HasSelectorForClassDistributionFunctor):
12763         (WebCore::HasSelectorForClassDistributionFunctor::operator()): Returns true if ElementShadow::hasSelectorForClass returns true.
12764         (WebCore::checkFunctorForClassChange):
12765         (WebCore::checkNeedsStyleInvalidationForClassChange): Extacted the implementation to checkFunctorForClassChange.
12766         (WebCore::checkNeedsDistributionInvalidationForClassChange):
12767         (WebCore::Element::classAttributeChanged):
12768
12769 2012-11-12  Joe Mason  <jmason@rim.com>
12770
12771         [BlackBerry] NetworkJob should not check if data is received with HEAD
12772         https://bugs.webkit.org/show_bug.cgi?id=102034
12773
12774         Reviewed by George Staikos.
12775
12776         Internal PR: 241391
12777
12778         Make HEAD requests call didFinish instead of didFail on a 404 response, even though they
12779         have no data.
12780
12781         Tests: ManualTests/blackberry/head-xhr-nonexistant-file.html
12782
12783         * platform/network/blackberry/NetworkJob.cpp:
12784         (WebCore::NetworkJob::NetworkJob):
12785         (WebCore::NetworkJob::initialize):
12786         (WebCore::NetworkJob::shouldNotifyClientFailed):
12787         * platform/network/blackberry/NetworkJob.h:
12788         (NetworkJob):
12789
12790 2012-11-12  Adam Barth  <abarth@webkit.org>
12791
12792         [V8] V8DOMWrapper::instantiateV8Object shouldn't use deprecatedDocument
12793         https://bugs.webkit.org/show_bug.cgi?id=102015
12794
12795         Reviewed by Kentaro Hara.
12796
12797         Previously, Nodes had a special path through
12798         V8DOMWrapper::instantiateV8Object using deprecatedDocument so that we
12799         could find the V8PerContextData quickly. Now that we can get the
12800         V8PerContextData from the v8::Context quickly, we can move Nodes to the
12801         general case. The net consequence is that creation of all DOM objects
12802         should be as fast as Nodes are.
12803
12804         * bindings/scripts/CodeGeneratorV8.pm:
12805         (GenerateToV8Converters):
12806         * bindings/scripts/test/V8/V8Float64Array.cpp:
12807         (WebCore::V8Float64Array::wrapSlow):
12808         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
12809         (WebCore::V8TestActiveDOMObject::wrapSlow):
12810         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
12811         (WebCore::V8TestCustomNamedGetter::wrapSlow):
12812         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
12813         (WebCore::V8TestEventConstructor::wrapSlow):
12814         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
12815         (WebCore::V8TestEventTarget::wrapSlow):
12816         * bindings/scripts/test/V8/V8TestException.cpp:
12817         (WebCore::V8TestException::wrapSlow):
12818         * bindings/scripts/test/V8/V8TestInterface.cpp:
12819         (WebCore::V8TestInterface::wrapSlow):
12820         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
12821         (WebCore::V8TestMediaQueryListListener::wrapSlow):
12822         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
12823         (WebCore::V8TestNamedConstructor::wrapSlow):
12824         * bindings/scripts/test/V8/V8TestNode.cpp:
12825         (WebCore::V8TestNode::wrapSlow):
12826         * bindings/scripts/test/V8/V8TestObj.cpp:
12827         (WebCore::V8TestObj::wrapSlow):
12828         * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp:
12829         (WebCore::V8TestOverloadedConstructors::wrapSlow):
12830         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
12831         (WebCore::V8TestSerializedScriptValueInterface::wrapSlow):
12832         * bindings/v8/V8Binding.cpp:
12833         * bindings/v8/V8Binding.h:
12834         (WebCore):
12835         * bindings/v8/V8DOMWrapper.cpp:
12836         (WebCore::V8DOMWrapper::instantiateV8Object):
12837         * bindings/v8/V8DOMWrapper.h:
12838         (V8DOMWrapper):
12839
12840 2012-11-12  KyungTae Kim  <ktf.kim@samsung.com>
12841
12842         Some CSS properties are not handled on StyleResolver::applyProperty
12843         https://bugs.webkit.org/show_bug.cgi?id=102027
12844
12845         Reviewed by Gyuyoung Kim.
12846
12847         The CSSPropertyMaxZoom, CSSPropertyMinZoom, CSSPropertyOrientation and CSSPropertyUserZoom
12848         need to be handled on StyleResolver::applyProperty.
12849
12850         * css/StyleResolver.cpp:
12851         (WebCore::StyleResolver::applyProperty):
12852
12853 2012-11-12  Simon Fraser  <simon.fraser@apple.com>
12854
12855         Avoid calling calculateLayerBounds() and convertToLayerCoords() more than once per layer paint
12856         https://bugs.webkit.org/show_bug.cgi?id=102031
12857
12858         Reviewed by Beth Dakin.
12859
12860         RenderLayer::paintLayerContents() and callees could end up calling convertToLayerCoords()
12861         and calculateLayerBounds() multiple times for painting a single layer.
12862         
12863         Keep track of whether we've computed the root-relative bounds and do it on demand.
12864         Compute the offset relative to rootLayer once, and pass it around as an optional parameter
12865         to functions that need it.
12866
12867         * rendering/RenderLayer.cpp:
12868         (WebCore::RenderLayer::paintLayerContents):
12869         (WebCore::RenderLayer::hitTestLayer):
12870         (WebCore::RenderLayer::calculateRects):
12871         (WebCore::RenderLayer::intersectsDamageRect):
12872         (WebCore::RenderLayer::boundingBox):
12873         (WebCore::RenderLayer::calculateLayerBounds):
12874         * rendering/RenderLayer.h:
12875         * rendering/RenderLayerCompositor.cpp:
12876         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
12877
12878 2012-11-12  Simon Fraser  <simon.fraser@apple.com>
12879
12880         Change calculateLayerBounds() from a static function to a member function
12881         https://bugs.webkit.org/show_bug.cgi?id=102022
12882
12883         Reviewed by Beth Dakin.
12884
12885         calculateLayerBounds() has grown into a substantial function after
12886         starting live as a little utility function, so make it a member function
12887         of RenderLayer, and adjust callers accordingly.
12888
12889         * rendering/RenderLayer.cpp:
12890         (WebCore::RenderLayer::setFilterBackendNeedsRepaintingInRect):
12891         (WebCore::RenderLayer::paintLayerContents):
12892         (WebCore::RenderLayer::calculateLayerBounds):
12893         * rendering/RenderLayer.h:
12894         * rendering/RenderLayerCompositor.cpp:
12895         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
12896
12897 2012-11-12  Alexei Filippov  <alph@chromium.org>
12898
12899         Web Inspector: Add an option to switch display of "Other" memory on/off in NMI
12900         https://bugs.webkit.org/show_bug.cgi?id=101601
12901
12902         Reviewed by Yury Semikhatsky.
12903
12904         * English.lproj/localizedStrings.js:
12905         * inspector/front-end/NativeMemorySnapshotView.js:
12906         * inspector/front-end/Settings.js:
12907         * inspector/front-end/SettingsScreen.js:
12908         (WebInspector.GenericSettingsTab):
12909
12910 2012-11-10  Dirk Schulze  <krit@webkit.org>
12911
12912         BasicShapes 'circle', 'rectangle', 'ellipse' should be animatable with themselves
12913         https://bugs.webkit.org/show_bug.cgi?id=101854
12914
12915         Reviewed by Andreas Kling.
12916
12917         The basic shapes BasicShapeCircle, BasicShapeEllipse and BasicShapeRectangle should
12918         blend with themselves. This patch introduces simple interpolation of BasicShapes for
12919         the -webkit-clip-path property.
12920
12921         Test: css3/masking/clip-path-animation.html
12922
12923         * page/animation/CSSPropertyAnimation.cpp:
12924         (WebCore::blendFunc): Added a new function that blends between two BasicShape objects.
12925             It skips blending on <clipPath> references, polygons and if the shapes are not of
12926             the same type.
12927         (WebCore):
12928         (PropertyWrapperClipPath): Added new wrapper for ClipPathShapes.
12929         (WebCore::PropertyWrapperClipPath::PropertyWrapperClipPath): Ditto.
12930         (WebCore::CSSPropertyAnimation::ensurePropertyMap): Add -webkit-clip-path to animatable
12931             properties.
12932         * rendering/style/BasicShapes.cpp:
12933             The blending is done by each shape itself. This is similar to FilterOperations or
12934             TransformOperations.
12935         (WebCore::BasicShapeRectangle::blend):
12936         (WebCore):
12937         (WebCore::BasicShapeCircle::blend):
12938         (WebCore::BasicShapeEllipse::blend):
12939         (WebCore::BasicShapePolygon::blend):
12940         * rendering/style/BasicShapes.h:
12941             Added new blending functions to header.
12942         (BasicShape):
12943         (BasicShapeRectangle):
12944         (BasicShapeCircle):
12945         (BasicShapeEllipse):
12946         (BasicShapePolygon):
12947
12948 2012-11-12  Adam Barth  <abarth@webkit.org>
12949
12950         [V8] We should be able to get V8PerContextData from a v8::Context more quickly
12951         https://bugs.webkit.org/show_bug.cgi?id=102008
12952
12953         Reviewed by Ojan Vafai.
12954
12955         This patch uses the new v8::Context::GetAlignedPointerFromEmbedderData
12956         API to get the V8PerContextData associated with a v8::Context much more
12957         quickly. We no longer need to use a hidden property on the inner global
12958         object. This patch will enable future optimizations.
12959
12960         * bindings/v8/V8HiddenPropertyName.h:
12961         (WebCore):
12962         * bindings/v8/V8PerContextData.cpp:
12963         (WebCore::V8PerContextData::dispose):
12964         (WebCore::V8PerContextData::init):
12965         * bindings/v8/V8PerContextData.h:
12966         (WebCore::V8PerContextData::from):
12967
12968 2012-11-12  Elliott Sprehn  <esprehn@chromium.org>
12969
12970         Make Frames and HTMLFrameOwnerElement less friendly
12971         https://bugs.webkit.org/show_bug.cgi?id=102003
12972
12973         Reviewed by Ojan Vafai.
12974
12975         Frame used to assign HTMLFrameOwnerElement's m_contentFrame directly
12976         this patch makes it go through a method to allow future hooks when frames
12977         are associated with owners.
12978
12979         No new tests, this is just a refactor.
12980
12981         * html/HTMLFrameOwnerElement.cpp:
12982         (WebCore::HTMLFrameOwnerElement::setContentFrame):
12983         * html/HTMLFrameOwnerElement.h:
12984         (HTMLFrameOwnerElement):
12985         (WebCore::HTMLFrameOwnerElement::clearContentFrame):
12986         * page/Frame.cpp:
12987         (WebCore::Frame::Frame): Use new methods.
12988
12989 2012-11-12  Beth Dakin  <bdakin@apple.com>
12990
12991         Zoomed-in scrolling is very slow when deviceScaleFactor > 1
12992         https://bugs.webkit.org/show_bug.cgi?id=101787
12993
12994         Reviewed by Simon Fraser.
12995
12996         This patch adds a new member to the GraphicsContextState that tracks 
12997         whether or not fonts should be subpixel-quantized. We want to default 
12998         to sibpixel-quantizing, but we'll turn it off if we're scrolling 
12999         content that cannot be scrolled on the scrolling thread.
13000
13001         State has a new bool shouldSubpixelQuantizeFonts. It defaults to true 
13002         since normally we do want to quantize.
13003         * platform/graphics/GraphicsContext.cpp:
13004         (WebCore::GraphicsContext::setShouldSubpixelQuantizeFonts):
13005         (WebCore::GraphicsContext::shouldSubpixelQuantizeFonts):
13006         * platform/graphics/GraphicsContext.h:
13007         (WebCore::GraphicsContextState::GraphicsContextState):
13008         (GraphicsContextState):
13009         (GraphicsContext):
13010
13011         wkSetCGFontRenderingMode now takes a BOOL parameter which indicates 
13012         whether or not it should try to subpixel-quantize the fonts.
13013         * platform/graphics/mac/FontMac.mm:
13014         (WebCore::Font::drawGlyphs):
13015         * platform/mac/WebCoreSystemInterface.h:
13016         * platform/mac/WebCoreSystemInterface.mm:
13017
13018         Disable subpixel-quantization for overflow areas, subframes, and 
13019         content that is scrolling on the main thread.
13020         * rendering/RenderLayer.cpp:
13021         (WebCore::RenderLayer::paintLayerContents):
13022
13023 2012-11-12  Timothy Hatcher  <timothy@apple.com>
13024
13025         Expose InspectorFrontendClientLocal::setAttachedWindow as public.
13026
13027         This allows external actions to update the docked state in the frontend.
13028
13029         https://bugs.webkit.org/show_bug.cgi?id=102023
13030
13031         Reviewed by Anders Carlsson.
13032
13033         * inspector/InspectorFrontendClientLocal.h:
13034         Moved InspectorFrontendClientLocal::setAttachedWindow to public section.
13035
13036 2012-11-12  Erik Arvidsson  <arv@chromium.org>
13037
13038         Replace DOMException TYPE_MISMATCH_ERR with TypeError
13039         https://bugs.webkit.org/show_bug.cgi?id=101604
13040
13041         Reviewed by Adam Barth.
13042
13043         DOMException.TYPE_MISMATCH_ERR is deprecated in favor of using TypeError.
13044
13045         We have historically used TYPE_MISMATCH_ERR as a blanket DOMException code when
13046         the spec mandates TypeError being thrown.
13047
13048         Updated existing tests.
13049
13050         * Modules/mediastream/MediaConstraintsImpl.cpp:
13051         * Modules/mediastream/MediaStreamTrackList.cpp:
13052         * Modules/mediastream/PeerConnection00.cpp:
13053         * Modules/mediastream/RTCDataChannel.cpp:
13054         * Modules/mediastream/RTCIceCandidate.cpp:
13055         * Modules/mediastream/RTCPeerConnection.cpp:
13056         * Modules/mediastream/RTCSessionDescription.cpp:
13057         * Modules/mediastream/SessionDescription.cpp:
13058         * bindings/js/CallbackFunction.cpp:
13059         * bindings/js/JSCustomXPathNSResolver.cpp:
13060         * bindings/js/JSHTMLOptionsCollectionCustom.cpp:
13061         * bindings/js/JSHTMLSelectElementCustom.cpp:
13062         * bindings/js/JSMutationObserverCustom.cpp:
13063         * bindings/js/JSSQLResultSetRowListCustom.cpp:
13064         * bindings/js/JSSQLTransactionCustom.cpp:
13065         * bindings/js/JSSQLTransactionSyncCustom.cpp:
13066         * bindings/scripts/CodeGeneratorJS.pm:
13067         * bindings/scripts/CodeGeneratorObjC.pm:
13068         * bindings/scripts/CodeGeneratorV8.pm:
13069         * bindings/v8/V8Callback.h:
13070         * bindings/v8/V8Collection.cpp:
13071         * bindings/v8/custom/V8DocumentCustom.cpp:
13072         * bindings/v8/custom/V8HTMLOptionsCollectionCustom.cpp:
13073         * bindings/v8/custom/V8MutationObserverCustom.cpp:
13074         * bindings/v8/custom/V8SQLTransactionCustom.cpp:
13075         * bindings/v8/custom/V8SQLTransactionSyncCustom.cpp:
13076         * dom/DOMCoreException.idl:
13077         * html/HTMLElement.cpp:
13078         * html/HTMLMediaElement.cpp:
13079         * html/HTMLOptionsCollection.cpp:
13080         * html/canvas/CanvasRenderingContext2D.cpp:
13081         * page/Crypto.cpp:
13082         * page/DOMSelection.cpp:
13083         * svg/properties/SVGTransformListPropertyTearOff.h:
13084
13085 2012-11-12  Joshua Bell  <jsbell@chromium.org>
13086
13087         IndexedDB: Use sequence<> instead of DOMString[] in IDL
13088         https://bugs.webkit.org/show_bug.cgi?id=100539
13089
13090         Reviewed by Adam Barth.
13091
13092         In the binding layer, DOMString[] is implemented as an alias for DOMStringList.
13093         WebIDL usage is tending towards sequence<DOMString> anyway for inputs, so switch
13094         to that. Note webkit.org/b/100537 which requires sequence<String> instead.
13095
13096         Covered by storage/indexeddb/transaction-basics.html and objectstore-basics.html
13097
13098         * Modules/indexeddb/IDBDatabase.cpp:
13099         (WebCore::IDBDatabase::transaction): DOMStringList -> Vector<String>
13100         * Modules/indexeddb/IDBDatabase.h:
13101         (WebCore::IDBDatabase::transaction):
13102         (IDBDatabase):
13103         * Modules/indexeddb/IDBDatabase.idl: DOMString[] -> sequence<String>
13104         * Modules/indexeddb/IDBObjectStore.cpp: Move trivial impls to header.
13105         * Modules/indexeddb/IDBObjectStore.h:
13106         (WebCore::IDBObjectStore::createIndex):
13107         * Modules/indexeddb/IDBObjectStore.idl: DOMString[] -> sequence<String>
13108
13109 2012-11-12  Anders Carlsson  <andersca@apple.com>
13110
13111         Remove Leopard only gradient code
13112         https://bugs.webkit.org/show_bug.cgi?id=102033
13113
13114         Reviewed by Dan Bernstein.
13115
13116         USE_CG_SHADING was only ever true on Leopard, so we can remove it now.
13117
13118         * platform/graphics/Gradient.h:
13119         * platform/graphics/cg/GradientCG.cpp:
13120         (WebCore::Gradient::platformDestroy):
13121         (WebCore::Gradient::platformGradient):
13122         (WebCore::Gradient::paint):
13123
13124 2012-11-12  Tiancheng Jiang  <tijiang@rim.com>
13125
13126         [BlackBerry] Update BB10 form theme.
13127         https://bugs.webkit.org/show_bug.cgi?id=100760
13128
13129         Reviewed by Rob Buis.
13130
13131         RIM PR 237003
13132         Internally Reviewed by Eli Fidler.
13133         Since we nolonger use small font for form controls, adjust paddingDivisor
13134         ratio to decrease the padding value.
13135
13136         * platform/blackberry/RenderThemeBlackBerry.cpp:
13137         (WebCore):
13138
13139 2012-11-12  Simon Fraser  <simon.fraser@apple.com>
13140
13141         Fix filter dirty rect regression from r134311
13142         https://bugs.webkit.org/show_bug.cgi?id=102002
13143
13144         Reviewed by Beth Dakin.
13145
13146         When rendering with filters, the code can inflate the root-relative
13147         paintDirtyRect in RenderLayer::paintLayerContents(), and my cleanup
13148         broke this behavior.
13149     
13150         Fix by making a local copy of LayerPaintingInfo, updating its paintDirtyRect,
13151         and using it for the rest of the function.
13152
13153         * rendering/RenderLayer.cpp:
13154         (WebCore::RenderLayer::paintLayerContents):
13155
13156 2012-11-12  Kentaro Hara  <haraken@chromium.org>
13157
13158         [V8] V8Event::valueAccessorGetter() in custom binding is not used
13159         https://bugs.webkit.org/show_bug.cgi?id=101893
13160
13161         Reviewed by Adam Barth.
13162
13163         No tests. No change in behavior.
13164
13165         * bindings/v8/custom/V8EventCustom.cpp:
13166
13167 2012-11-12  Roger Fong  <roger_fong@apple.com>
13168
13169         Web Inspector: Fix docking behaviour on Windows.
13170         https://bugs.webkit.org/show_bug.cgi?id=101978
13171
13172         Reviewed by Brian Weinstein.
13173
13174         There are a number of problems with docking behaviour on Windows.
13175         For starters, it does not ever constrain the inspector's size properly while docked.
13176         It also does not properly set the whether or not the inspector can be docked/undocked.
13177         This patch fixes both issues.
13178
13179         * inspector/InspectorFrontendClientLocal.cpp:
13180         (WebCore::InspectorFrontendClientLocal::frontendLoaded):
13181         Switch order of calling bringToFront and setDockingUnavailable.
13182
13183 2012-11-12  Adam Barth  <abarth@webkit.org>
13184
13185         [V8] Update callers to use the aligned pointer API rather than the deprecated unaligned pointer API
13186         https://bugs.webkit.org/show_bug.cgi?id=101519
13187
13188         Reviewed by Ojan Vafai.
13189
13190         There should be no change in behavior.  The new API is slightly faster
13191         than the old API (and apparently works correctly internally in V8).
13192
13193         * bindings/scripts/CodeGeneratorV8.pm:
13194         (GenerateHeader):
13195         * bindings/scripts/test/V8/V8Float64Array.h:
13196         (WebCore::V8Float64Array::toNative):
13197         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
13198         (WebCore::V8TestActiveDOMObject::toNative):
13199         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
13200         (WebCore::V8TestCustomNamedGetter::toNative):
13201         * bindings/scripts/test/V8/V8TestEventConstructor.h:
13202         (WebCore::V8TestEventConstructor::toNative):
13203         * bindings/scripts/test/V8/V8TestEventTarget.h:
13204         (WebCore::V8TestEventTarget::toNative):
13205         * bindings/scripts/test/V8/V8TestException.h:
13206         (WebCore::V8TestException::toNative):
13207         * bindings/scripts/test/V8/V8TestInterface.h:
13208         (WebCore::V8TestInterface::toNative):
13209         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
13210         (WebCore::V8TestMediaQueryListListener::toNative):
13211         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
13212         (WebCore::V8TestNamedConstructor::toNative):
13213         * bindings/scripts/test/V8/V8TestNode.h:
13214         (WebCore::V8TestNode::toNative):
13215         * bindings/scripts/test/V8/V8TestObj.h:
13216         (WebCore::V8TestObj::toNative):
13217         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
13218         (WebCore::V8TestSerializedScriptValueInterface::toNative):
13219         * bindings/v8/NPV8Object.cpp:
13220         (WebCore::v8ObjectToNPObject):
13221         (WebCore::npCreateV8ScriptObject):
13222         * bindings/v8/V8Collection.h:
13223         (WebCore::toNativeCollection):
13224         * bindings/v8/V8DOMWindowShell.cpp:
13225         (WebCore::setIsolatedWorldField):
13226         (WebCore::V8DOMWindowShell::enteredIsolatedWorldContext):
13227         * bindings/v8/V8DOMWrapper.cpp:
13228         (WebCore::V8DOMWrapper::isWrapperOfType):
13229         * bindings/v8/V8DOMWrapper.h:
13230         (WebCore::V8DOMWrapper::setDOMWrapper):
13231         (WebCore::V8DOMWrapper::clearDOMWrapper):
13232         * bindings/v8/WrapperTypeInfo.h:
13233         (WebCore::toNative):
13234         (WebCore::toWrapperTypeInfo):
13235
13236 2012-11-12  Andreas Kling  <kling@webkit.org>
13237
13238         Rename AttributeStyle => PresentationAttributeStyle across WebCore.
13239         <http://webkit.org/b/101975>
13240
13241         Rubber-stamped by Antti Koivisto.
13242
13243         The completely separate concepts of "attribute style" and "style attribute" were a bit too
13244         easy to confuse in variable and method names. Reconfigure our terminology to call it
13245         "presentation attribute style" instead of "attribute style".
13246
13247         * css/StyleResolver.cpp:
13248         (WebCore::StyleResolver::sweepMatchedPropertiesCache):
13249         (WebCore::StyleResolver::matchAllRules):
13250         (WebCore::StyleResolver::canShareStyleWithElement):
13251         * dom/Attr.cpp:
13252         (WebCore::Attr::style):
13253         * dom/ElementAttributeData.cpp:
13254         (WebCore::MutableElementAttributeData::MutableElementAttributeData):
13255         (WebCore::ElementAttributeData::reportMemoryUsage):
13256         * dom/ElementAttributeData.h:
13257         (WebCore::ElementAttributeData::presentationAttributeStyle):
13258         (WebCore::ElementAttributeData::setPresentationAttributeStyle):
13259         (ElementAttributeData):
13260         * dom/Node.h:
13261         (WebCore::Node::attributeStyleDirty):
13262         (WebCore::Node::setPresentationAttributeStyleDirty):
13263         (WebCore::Node::clearPresentationAttributeStyleDirty):
13264         * dom/StyledElement.cpp:
13265         (WebCore::StyledElement::attributeChanged):
13266         (WebCore::StyledElement::rebuildPresentationAttributeStyle):
13267         (WebCore::StyledElement::addPropertyToPresentationAttributeStyle):
13268         * dom/StyledElement.h:
13269         (WebCore::StyledElement::additionalPresentationAttributeStyle):
13270         (StyledElement):
13271         (WebCore::StyledElement::collectStyleForPresentationAttribute):
13272         (WebCore::StyledElement::presentationAttributeStyle):
13273         * html/HTMLBRElement.cpp:
13274         (WebCore::HTMLBRElement::collectStyleForPresentationAttribute):
13275         * html/HTMLBRElement.h:
13276         (HTMLBRElement):
13277         * html/HTMLBodyElement.cpp:
13278         (WebCore::HTMLBodyElement::collectStyleForPresentationAttribute):
13279         * html/HTMLBodyElement.h:
13280         (HTMLBodyElement):
13281         * html/HTMLDivElement.cpp:
13282         (WebCore::HTMLDivElement::collectStyleForPresentationAttribute):
13283         * html/HTMLDivElement.h:
13284         (HTMLDivElement):
13285         * html/HTMLElement.cpp:
13286         (WebCore::HTMLElement::applyBorderAttributeToStyle):
13287         (WebCore::HTMLElement::mapLanguageAttributeToLocale):
13288         (WebCore::HTMLElement::collectStyleForPresentationAttribute):
13289         (WebCore::HTMLElement::applyAlignmentAttributeToStyle):
13290         (WebCore::HTMLElement::addHTMLLengthToStyle):
13291         * html/HTMLElement.h:
13292         (HTMLElement):
13293         * html/HTMLEmbedElement.cpp:
13294         (WebCore::HTMLEmbedElement::collectStyleForPresentationAttribute):
13295         * html/HTMLEmbedElement.h:
13296         (HTMLEmbedElement):
13297         * html/HTMLFontElement.cpp:
13298         (WebCore::HTMLFontElement::collectStyleForPresentationAttribute):
13299         * html/HTMLFontElement.h:
13300         (HTMLFontElement):
13301         * html/HTMLFrameSetElement.cpp:
13302         (WebCore::HTMLFrameSetElement::collectStyleForPresentationAttribute):
13303         * html/HTMLFrameSetElement.h:
13304         (HTMLFrameSetElement):
13305         * html/HTMLHRElement.cpp:
13306         (WebCore::HTMLHRElement::collectStyleForPresentationAttribute):
13307         * html/HTMLHRElement.h:
13308         (HTMLHRElement):
13309         * html/HTMLIFrameElement.cpp:
13310         (WebCore::HTMLIFrameElement::collectStyleForPresentationAttribute):
13311         * html/HTMLIFrameElement.h:
13312         (HTMLIFrameElement):
13313         * html/HTMLImageElement.cpp:
13314         (WebCore::HTMLImageElement::collectStyleForPresentationAttribute):
13315         * html/HTMLImageElement.h:
13316         (HTMLImageElement):
13317         * html/HTMLInputElement.cpp:
13318         (WebCore::HTMLInputElement::collectStyleForPresentationAttribute):
13319         * html/HTMLInputElement.h:
13320         (HTMLInputElement):
13321         * html/HTMLLIElement.cpp:
13322         (WebCore::HTMLLIElement::collectStyleForPresentationAttribute):
13323         * html/HTMLLIElement.h:
13324         (HTMLLIElement):
13325         * html/HTMLMarqueeElement.cpp:
13326         (WebCore::HTMLMarqueeElement::collectStyleForPresentationAttribute):
13327         * html/HTMLMarqueeElement.h:
13328         (HTMLMarqueeElement):
13329         * html/HTMLOListElement.cpp:
13330         (WebCore::HTMLOListElement::collectStyleForPresentationAttribute):
13331         * html/HTMLOListElement.h:
13332         (HTMLOListElement):
13333         * html/HTMLObjectElement.cpp:
13334         (WebCore::HTMLObjectElement::collectStyleForPresentationAttribute):
13335         * html/HTMLObjectElement.h:
13336         (HTMLObjectElement):
13337         * html/HTMLParagraphElement.cpp:
13338         (WebCore::HTMLParagraphElement::collectStyleForPresentationAttribute):
13339         * html/HTMLParagraphElement.h:
13340         (HTMLParagraphElement):
13341         * html/HTMLPlugInElement.cpp:
13342         (WebCore::HTMLPlugInElement::collectStyleForPresentationAttribute):
13343         * html/HTMLPlugInElement.h:
13344         (HTMLPlugInElement):
13345         * html/HTMLPreElement.cpp:
13346         (WebCore::HTMLPreElement::collectStyleForPresentationAttribute):
13347         * html/HTMLPreElement.h:
13348         (HTMLPreElement):
13349         * html/HTMLTableCaptionElement.cpp:
13350         (WebCore::HTMLTableCaptionElement::collectStyleForPresentationAttribute):
13351         * html/HTMLTableCaptionElement.h:
13352         (HTMLTableCaptionElement):
13353         * html/HTMLTableCellElement.cpp:
13354         (WebCore::HTMLTableCellElement::collectStyleForPresentationAttribute):
13355         (WebCore::HTMLTableCellElement::additionalPresentationAttributeStyle):
13356         * html/HTMLTableCellElement.h:
13357         (HTMLTableCellElement):
13358         * html/HTMLTableColElement.cpp:
13359         (WebCore::HTMLTableColElement::collectStyleForPresentationAttribute):
13360         (WebCore::HTMLTableColElement::additionalPresentationAttributeStyle):
13361         * html/HTMLTableColElement.h:
13362         (HTMLTableColElement):
13363         * html/HTMLTableElement.cpp:
13364         (WebCore::HTMLTableElement::collectStyleForPresentationAttribute):
13365         (WebCore::HTMLTableElement::additionalPresentationAttributeStyle):
13366         * html/HTMLTableElement.h:
13367         (HTMLTableElement):
13368         * html/HTMLTablePartElement.cpp:
13369         (WebCore::HTMLTablePartElement::collectStyleForPresentationAttribute):
13370         * html/HTMLTablePartElement.h:
13371         (HTMLTablePartElement):
13372         * html/HTMLTableSectionElement.cpp:
13373         (WebCore::HTMLTableSectionElement::additionalPresentationAttributeStyle):
13374         * html/HTMLTableSectionElement.h:
13375         (HTMLTableSectionElement):
13376         * html/HTMLTextAreaElement.cpp:
13377         (WebCore::HTMLTextAreaElement::collectStyleForPresentationAttribute):
13378         * html/HTMLTextAreaElement.h:
13379         (HTMLTextAreaElement):
13380         * html/HTMLUListElement.cpp:
13381         (WebCore::HTMLUListElement::collectStyleForPresentationAttribute):
13382         * html/HTMLUListElement.h:
13383         (HTMLUListElement):
13384         * html/HTMLVideoElement.cpp:
13385         (WebCore::HTMLVideoElement::collectStyleForPresentationAttribute):
13386         * html/HTMLVideoElement.h:
13387         (HTMLVideoElement):
13388         * inspector/InspectorCSSAgent.cpp:
13389         (WebCore::InspectorCSSAgent::buildObjectForAttributesStyle):
13390         * mathml/MathMLElement.cpp:
13391         (WebCore::MathMLElement::collectStyleForPresentationAttribute):
13392         * mathml/MathMLElement.h:
13393         (MathMLElement):
13394         * svg/SVGImageElement.cpp:
13395         (WebCore::SVGImageElement::collectStyleForPresentationAttribute):
13396         * svg/SVGImageElement.h:
13397         (SVGImageElement):
13398         * svg/SVGStyledElement.cpp:
13399         (WebCore::SVGStyledElement::collectStyleForPresentationAttribute):
13400         * svg/SVGStyledElement.h:
13401         (SVGStyledElement):
13402         * svg/SVGTextContentElement.cpp:
13403         (WebCore::SVGTextContentElement::collectStyleForPresentationAttribute):
13404         * svg/SVGTextContentElement.h:
13405         (SVGTextContentElement):
13406
13407 2012-11-12  Adam Barth  <abarth@webkit.org>
13408
13409         [V8] Many things crash when switching to V8's new aligned pointer API
13410         https://bugs.webkit.org/show_bug.cgi?id=101994
13411
13412         Reviewed by Eric Seidel.
13413
13414         When using the aligned pointer API, we need to make sure to initialize
13415         every internal field that we later read because the new API has better
13416         error checks than the old API. This patch explicitly initializes the
13417         enteredIsolatedWorldIndex internal field to zero for main worlds,
13418         fixing the LayoutTest crashes from our previous attempt to move the
13419         aligned pointer API.
13420
13421         * bindings/v8/V8DOMWindowShell.cpp:
13422         (WebCore::V8DOMWindowShell::initializeIfNeeded):
13423
13424 2012-11-12  Simon Fraser  <simon.fraser@apple.com>
13425
13426         Reduce the crazy number of parameters to RenderLayer painting member functions
13427         https://bugs.webkit.org/show_bug.cgi?id=101895
13428
13429         Reviewed by Beth Dakin.
13430
13431         The various RenderLayer::paintLayer* functions took a lot of arguments, most
13432         of which were passed down directly to descendants.
13433         
13434         Gather these arguments into a LayerPaintingInfo struct.
13435
13436         * rendering/RenderLayer.cpp:
13437         (WebCore::RenderLayer::paint): Create a LayerPaintingInfo struct to pass
13438         to descendant paint calls.
13439         (WebCore::RenderLayer::paintOverlayScrollbars): Ditto.
13440         (WebCore::RenderLayer::paintLayer): When painting transformed layers, we
13441         make a new LayerPaintingInfo because the root layer is shifted.
13442         (WebCore::RenderLayer::paintLayerContentsAndReflection):
13443         (WebCore::RenderLayer::paintLayerContents):
13444         (WebCore::RenderLayer::paintList):
13445         (WebCore::RenderLayer::paintPaginatedChildLayer):
13446         (WebCore::RenderLayer::paintChildLayerIntoColumns): Create a new LayerPaintingInfo
13447         struct for column painting.
13448         * rendering/RenderLayer.h:
13449         (WebCore::RenderLayer::LayerPaintingInfo::LayerPaintingInfo):
13450         (LayerPaintingInfo):
13451         * rendering/RenderLayerBacking.cpp:
13452         (WebCore::RenderLayerBacking::paintIntoLayer): Build a LayerPaintingInfo
13453         to enter layer painting.
13454         * rendering/RenderReplica.cpp:
13455         (WebCore::RenderReplica::paint): Ditto.
13456
13457 2012-11-12  Brady Eidson  <beidson@apple.com>
13458
13459         NetworkProcess: Use an accurate shouldContentSniff value when creating ResourceHandles
13460         https://bugs.webkit.org/show_bug.cgi?id=101872
13461
13462         Reviewed by Alexey Proskuryakov.
13463
13464         Expose shouldSniffContent to pass it along to the NetworkProcess.
13465
13466         * loader/ResourceLoader.h:
13467         (WebCore::ResourceLoader::shouldSniffContent):
13468
13469 2012-11-12  Christophe Dumez  <christophe.dumez@intel.com>
13470
13471         Fix memory leak in createSurfaceForBackingStore()
13472         https://bugs.webkit.org/show_bug.cgi?id=101941
13473
13474         Reviewed by Kenneth Rohde Christiansen.
13475
13476         Fix memory leak in createSurfaceForBackingStore(),
13477         the RefPtr<cairo_surface_t> should be released
13478         when returned since we pass ownership to the
13479         caller.
13480
13481         No new tests, no behavior change for layout tests.
13482
13483         * platform/graphics/efl/CairoUtilitiesEfl.cpp:
13484         (WebCore::createSurfaceForBackingStore):
13485
13486 2012-11-12  Joe Mason  <jmason@rim.com>
13487
13488         [BlackBerry] Update to new proxyInfo API
13489         https://bugs.webkit.org/show_bug.cgi?id=101945
13490
13491         Reviewed by George Staikos.
13492
13493         Internal PR: 234680
13494         Reviewed internally by: Leo Yang
13495
13496         The proxyAddress, proxyUsername and proxyPassword methods in BlackBerry::Platform::Settings
13497         have been replaced with a single, more efficient proxyInfo method.
13498
13499         No new tests because this is an API update with no behaviour change.
13500
13501         * platform/network/blackberry/NetworkJob.cpp:
13502         (WebCore::NetworkJob::sendRequestWithCredentials):
13503         (WebCore::NetworkJob::storeCredentials):
13504
13505 2012-11-12  Sheriff Bot  <webkit.review.bot@gmail.com>
13506
13507         Unreviewed, rolling out r126157.
13508         http://trac.webkit.org/changeset/126157
13509         https://bugs.webkit.org/show_bug.cgi?id=101954
13510
13511         This patch caused (untestable) regression of the volume
13512         property on Mac, Win, and Blackberry ports. (Requested by
13513         jernoble on #webkit).
13514
13515         * platform/graphics/MediaPlayer.cpp:
13516         (WebCore::MediaPlayer::loadWithNextMediaEngine):
13517         (WebCore::MediaPlayer::setVolume):
13518         (WebCore::MediaPlayer::setMuted):
13519         (WebCore::MediaPlayer::setPreservesPitch):
13520         (WebCore::MediaPlayer::setSize):
13521         (WebCore::MediaPlayer::setVisible):
13522         (WebCore::MediaPlayer::setPreload):
13523
13524 2012-11-12  Arpita Bahuguna  <arpitabahuguna@gmail.com>
13525
13526         Specified width CSS tables should not include border and padding as part of that width.
13527         https://bugs.webkit.org/show_bug.cgi?id=77028
13528
13529         Reviewed by Julien Chaffraix.
13530
13531         CSS table width should not include border and padding even though HTML
13532         tables size as though their width includes border/padding.
13533
13534         This is applicable for all CSS tables with specified widths.
13535
13536         The change would also make our rendering of CSS tables with specified
13537         width similar to that of Opera, IE and FF.
13538
13539         Test: fast/table/css-table-width-with-border-padding.html
13540
13541         * rendering/RenderTable.cpp:
13542         (WebCore::RenderTable::convertStyleLogicalWidthToComputedWidth):
13543         Added check for all (positive) specified widths for CSS tables to
13544         consider border and padding outside of the specified width.
13545
13546 2012-11-12  Allan Sandfeld Jensen  <allan.jensen@digia.com>
13547
13548         Move resolving blob references to FormData.
13549         https://bugs.webkit.org/show_bug.cgi?id=101754
13550
13551         Reviewed by Simon Hausmann.
13552
13553         Resolving Blob-references to a set of just File and Data is done similar by several platforms.
13554         This patch adds a generic implementation in FormData and uses that from CFNetwork, Qt and
13555         BlackBerry network implementation.
13556
13557         * platform/network/FormData.cpp:
13558         (WebCore::appendBlobResolved):
13559         (WebCore::FormData::resolveBlobReferences):
13560         * platform/network/FormData.h:
13561         * platform/network/blackberry/ResourceRequestBlackBerry.cpp:
13562         (WebCore::ResourceRequest::initializePlatformRequest):
13563         * platform/network/cf/FormDataStreamCFNet.cpp:
13564         (WebCore::setHTTPBody):
13565         * platform/network/qt/QNetworkReplyHandler.cpp:
13566         (WebCore::FormDataIODevice::prepareFormElements):
13567
13568 2012-11-12  Zeno Albisser  <zeno@webkit.org>
13569
13570         GraphicsSurfaceGLX does not handle transparency correctly.
13571         https://bugs.webkit.org/show_bug.cgi?id=101943
13572
13573         GraphicsSurfacGLX must consistently use RGBA texture format.
13574         glXCreateWindow must be called after creating the XWindow
13575         that serves as a temporary offscreen texture storage, in order
13576         to allow for transparency.
13577         When creating the offscreen XWindow we must make sure,
13578         that we use a framebuffer configuration that supports
13579         an alpha mask.
13580
13581         Reviewed by Noam Rosenthal.
13582
13583         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
13584         (WebCore):
13585         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
13586         (WebCore::GraphicsSurfacePrivate::~GraphicsSurfacePrivate):
13587         (WebCore::GraphicsSurfacePrivate::createSurface):
13588         (GraphicsSurfacePrivate):
13589         (WebCore::GraphicsSurface::platformPaintToTextureMapper):
13590
13591 2012-11-12  Sheriff Bot  <webkit.review.bot@gmail.com>
13592
13593         Unreviewed, rolling out r134225.
13594         http://trac.webkit.org/changeset/134225
13595         https://bugs.webkit.org/show_bug.cgi?id=101948
13596
13597         Appears to have broken the EFL and GTK builds (Requested by
13598         abarth on #webkit).
13599
13600         * bindings/js/JSHTMLElementCustom.cpp:
13601         (WebCore):
13602         (WebCore::JSHTMLElement::itemValue):
13603         (WebCore::JSHTMLElement::setItemValue):
13604         * bindings/v8/custom/V8HTMLElementCustom.cpp:
13605         (WebCore):
13606         (WebCore::V8HTMLElement::itemValueAccessorGetter):
13607         (WebCore::V8HTMLElement::itemValueAccessorSetter):
13608         * html/HTMLElement.idl:
13609
13610 2012-11-12  Allan Sandfeld Jensen  <allan.jensen@digia.com>
13611
13612         hitTestResultAtPoint does two hit-tests if called on non main frame
13613         https://bugs.webkit.org/show_bug.cgi?id=101915
13614
13615         Reviewed by Antonio Gomes.
13616
13617         Always redirect hitTestResultAtPoint to the main-frame. This used to being
13618         done on every result that hit anything, which caused running the expensive 
13619         hit-tests multiple times in almost all cases.
13620
13621         * page/EventHandler.cpp:
13622         (WebCore::EventHandler::hitTestResultAtPoint):
13623
13624 2012-11-12  Kentaro Hara  <haraken@chromium.org>
13625
13626         [V8][JSC] ScriptProfileNode::callUID needs not to be [Custom]
13627         https://bugs.webkit.org/show_bug.cgi?id=101892
13628
13629         Reviewed by Adam Barth.
13630
13631         We can remove [Custom] from callUID in ScriptProfileNode.idl.
13632
13633         No tests. No change in behavior.
13634
13635         * GNUmakefile.list.am:
13636         * Target.pri:
13637         * UseJSC.cmake:
13638         * WebCore.gypi:
13639         * WebCore.vcproj/WebCore.vcproj:
13640         * WebCore.xcodeproj/project.pbxproj:
13641         * bindings/js/JSBindingsAllInOne.cpp:
13642         * bindings/js/JSScriptProfileNodeCustom.cpp: Removed.
13643         * bindings/v8/custom/V8ScriptProfileNodeCustom.cpp:
13644         * inspector/ScriptProfileNode.idl:
13645
13646 2012-11-12  Kentaro Hara  <haraken@chromium.org>
13647
13648         [V8] Performance::memory getter needs not to be [Custom]
13649         https://bugs.webkit.org/show_bug.cgi?id=101890
13650
13651         Reviewed by Adam Barth.
13652
13653         No tests. No change in behavior.
13654
13655         * UseV8.cmake:
13656         * WebCore.gypi:
13657         * bindings/v8/custom/V8PerformanceCustom.cpp: Removed.
13658         * page/Performance.idl:
13659
13660 2012-11-12  Kentaro Hara  <haraken@chromium.org>
13661
13662         [V8][JSC] HTMLOptionsCollection::length needs not to be [Custom]
13663         https://bugs.webkit.org/show_bug.cgi?id=101888
13664
13665         Reviewed by Adam Barth.
13666
13667         We can remove [Custom] from getter. It is possible to remove [Custom]
13668         from setter, but it changes the current behavior.
13669         (I think the current implementation of the setter is wrong.
13670         I'll fix it in another patch.)
13671
13672         No tests. No change in behavior.
13673
13674         * bindings/js/JSHTMLOptionsCollectionCustom.cpp:
13675         * bindings/v8/custom/V8HTMLOptionsCollectionCustom.cpp:
13676         * html/HTMLOptionsCollection.idl:
13677
13678 2012-11-12  Yael Aharon  <yael.aharon@intel.com>
13679
13680         [EFL][WK2][AC] Black screen when applications use software backend.
13681         https://bugs.webkit.org/show_bug.cgi?id=101659
13682
13683         Reviewed by Kenneth Rohde Christiansen.
13684
13685         Add a utility method to create a cairo_surface_t from a given Evas_Object_Image.
13686
13687         No new tests. Will be covered when running existing tests without enabling openGL.
13688
13689         * platform/graphics/efl/CairoUtilitiesEfl.cpp:
13690         (WebCore::createSurfaceForImage):
13691         (WebCore):
13692         * platform/graphics/efl/CairoUtilitiesEfl.h:
13693         (WebCore):
13694
13695 2012-11-12  Carlos Garcia Campos  <cgarcia@igalia.com>
13696
13697         Unreviewed. Fix make distcheck.
13698
13699         * GNUmakefile.am: Remove editing from IDL_PATH since it doesn't
13700         contain idl files anymore.
13701         * GNUmakefile.list.am: Add missing header files.
13702
13703 2012-11-12  Tommy Widenflycht  <tommyw@google.com>
13704
13705         MediaStream API: Make sure that MediaConstraints only has optional and mandatory at the top level
13706         https://bugs.webkit.org/show_bug.cgi?id=101733
13707
13708         Reviewed by Jochen Eisinger.
13709
13710         This patch adds better verification to MediaConstraintsImpl.
13711
13712         Existing tests expanded to cover this change.
13713
13714         * Modules/mediastream/MediaConstraintsImpl.cpp:
13715         (WebCore::MediaConstraintsImpl::initialize):
13716
13717 2012-11-12  Sheriff Bot  <webkit.review.bot@gmail.com>
13718
13719         Unreviewed, rolling out r134223.
13720         http://trac.webkit.org/changeset/134223
13721         https://bugs.webkit.org/show_bug.cgi?id=101939
13722
13723         Breaks inspector tests (Requested by pfeldman on #webkit).
13724
13725         * inspector/front-end/DefaultTextEditor.js:
13726         (WebInspector.TextEditorChunkedPanel.prototype._repaintAll):
13727         (WebInspector.TextEditorMainPanel):
13728         (WebInspector.TextEditorMainPanel.prototype.markAndRevealRange):
13729         (WebInspector.TextEditorMainPanel.prototype.beginDomUpdates):
13730         (WebInspector.TextEditorMainPanel.prototype.endDomUpdates):
13731         (WebInspector.TextEditorMainPanel.prototype._paintScheduledLines):
13732         (WebInspector.TextEditorMainPanel.prototype._paintLineChunks):
13733         (WebInspector.TextEditorMainPanel.prototype._paintLine):
13734         (WebInspector.TextEditorMainPanel.prototype._insertSpanBefore):
13735         (WebInspector.TextEditorMainPanel.prototype._handleDOMUpdates):
13736         (WebInspector.TextEditorMainPanel.prototype._applyDomUpdates):
13737         * inspector/front-end/externs.js:
13738         * inspector/front-end/textEditor.css:
13739
13740 2012-11-12  Allan Sandfeld Jensen  <allan.jensen@digia.com>
13741
13742         [Qt] Support ResourceRequest's setTimeoutInterval
13743         https://bugs.webkit.org/show_bug.cgi?id=101731
13744
13745         Reviewed by Simon Hausmann.
13746
13747         Establish a timeout and return the correct error when it is triggered.
13748
13749         Tested by existing http/tests/xmlhttprequest/timeout tests.
13750
13751         * platform/network/ResourceRequestBase.cpp:
13752         * platform/network/qt/QNetworkReplyHandler.cpp:
13753         (WebCore::QNetworkReplyHandler::release):
13754         (WebCore::QNetworkReplyHandler::finish):
13755         (WebCore::QNetworkReplyHandler::timeout):
13756         (WebCore::QNetworkReplyHandler::timerEvent):
13757         (WebCore::QNetworkReplyHandler::start):
13758         * platform/network/qt/QNetworkReplyHandler.h:
13759         (QNetworkReplyHandler):
13760
13761 2012-11-12  Sheriff Bot  <webkit.review.bot@gmail.com>
13762
13763         Unreviewed, rolling out r134224.
13764         http://trac.webkit.org/changeset/134224
13765         https://bugs.webkit.org/show_bug.cgi?id=101937
13766
13767         asserting on bawts (Requested by kling on #webkit).
13768
13769         * rendering/style/RenderStyle.cpp:
13770         (WebCore::RenderStyle::diff):
13771         (WebCore::RenderStyle::setColor):
13772         (WebCore::RenderStyle::setVisitedLinkColor):
13773         * rendering/style/RenderStyle.h:
13774         * rendering/style/StyleBackgroundData.cpp:
13775         (WebCore::StyleBackgroundData::StyleBackgroundData):
13776         * rendering/style/StyleBackgroundData.h:
13777         (WebCore::StyleBackgroundData::color):
13778         (StyleBackgroundData):
13779         * rendering/style/StyleInheritedData.cpp:
13780         (WebCore::StyleInheritedData::StyleInheritedData):
13781         * rendering/style/StyleInheritedData.h:
13782         (StyleInheritedData):
13783         * rendering/style/StyleMultiColData.cpp:
13784         (WebCore::StyleMultiColData::StyleMultiColData):
13785         * rendering/style/StyleMultiColData.h:
13786         (StyleMultiColData):
13787         * rendering/style/StyleRareInheritedData.cpp:
13788         (SameSizeAsStyleRareInheritedData):
13789         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
13790         (WebCore::StyleRareInheritedData::operator==):
13791         * rendering/style/StyleRareInheritedData.h:
13792         (WebCore):
13793         (StyleRareInheritedData):
13794         * rendering/style/StyleRareNonInheritedData.cpp:
13795         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
13796         (WebCore::StyleRareNonInheritedData::operator==):
13797         * rendering/style/StyleRareNonInheritedData.h:
13798         (StyleRareNonInheritedData):
13799
13800 2012-11-12  Tiancheng Jiang  <tijiang@rim.com>
13801
13802         [BlackBerry] Update BB10 form theme.
13803         https://bugs.webkit.org/show_bug.cgi?id=100760
13804
13805         Reviewed by Rob Buis.
13806
13807         RIM PR 236993
13808         Internally Reviewed by Jeff Rogers.
13809         Use slide and paint method on slider range and media controls.
13810
13811         * platform/blackberry/RenderThemeBlackBerry.cpp:
13812         (WebCore):
13813         (WebCore::drawThreeSliceHorizontal):
13814         (WebCore::drawThreeSliceVertical):
13815         (WebCore::RenderThemeBlackBerry::paintSliderTrackRect):
13816         (WebCore::RenderThemeBlackBerry::paintMediaSliderTrack):
13817         (WebCore::RenderThemeBlackBerry::paintMediaSliderThumb):
13818         (WebCore::RenderThemeBlackBerry::paintMediaVolumeSliderTrack):
13819         * platform/blackberry/RenderThemeBlackBerry.h:
13820         (RenderThemeBlackBerry):
13821
13822 2012-11-12  Kent Tamura  <tkent@chromium.org>
13823
13824         Refactoring: set read-only values on layout in DateTimeEditElement
13825         https://bugs.webkit.org/show_bug.cgi?id=101916
13826
13827         Reviewed by Kentaro Hara.
13828
13829         We have always updated read-only values when we set an empty value or
13830         DateTimeFieldsState. It has wasted CPU time because such read-only
13831         values are never updated after layout() essentially. So, we set
13832         read-only values in DateTimeEditBuilder used by layout(), and remove
13833         dateForReadOnlyField arguments of setEmptyValue and
13834         setValueAsDateTimeFieldsState.
13835
13836         No new tests. This should not make behavior changes.
13837
13838         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
13839         (WebCore::BaseMultipleFieldsDateAndTimeInputType::restoreFormControlState):
13840         We removed dateForReadOnlyField argument because read-only values are
13841         already set in DateTimeFieldElement::layout().
13842         * html/shadow/DateTimeEditElement.cpp:
13843         (WebCore::DateTimeEditBuilder::visitField):
13844         Set a value to a read-only minute/second/millisecond field while
13845         building UI elements.
13846         Also, changed variable types for millisecond and second fields to
13847         RefPtr<DateTimeNumericFieldElement> because we'd like to call
13848         setValueAsDate, which is private in DateTimeMillisecondFieldElement and
13849         DateTimeSecondFieldElement
13850         (WebCore::DateTimeEditElement::setValueAsDateTimeFieldsState):
13851         We removed dateForReadOnlyField argument because read-only values are
13852         already set in DateTimeFieldElement::layout().
13853         (WebCore::DateTimeEditElement::setEmptyValue): Ditto.
13854         * html/shadow/DateTimeEditElement.h:
13855         (DateTimeEditElement):
13856         Removed dateForReadOnlyField argument for setValueAsDateTimeFieldsState.
13857
13858         * html/shadow/DateTimeFieldElement.cpp:
13859         (WebCore::DateTimeFieldElement::defaultKeyboardEventHandler):
13860         We removed dateForReadOnlyField argument because read-only values are
13861         already set in DateTimeFieldElement::layout().
13862         * html/shadow/DateTimeFieldElement.h:
13863         (DateTimeFieldElement): Ditto.
13864
13865         * html/shadow/DateTimeFieldElements.cpp: Ditto.
13866         * html/shadow/DateTimeFieldElements.h: Ditto.
13867         * html/shadow/DateTimeNumericFieldElement.cpp:
13868         (WebCore::DateTimeNumericFieldElement::setEmptyValue):
13869         It should do nothing if it is read-only because a read-only value was
13870         already set just after construction.
13871         * html/shadow/DateTimeNumericFieldElement.h:
13872         (DateTimeNumericFieldElement):
13873         Removed dateForReadOnlyField argument of setEmptyValue.
13874         * html/shadow/DateTimeSymbolicFieldElement.cpp:
13875         (WebCore::DateTimeSymbolicFieldElement::setEmptyValue): Ditto.
13876         * html/shadow/DateTimeSymbolicFieldElement.h:
13877         (DateTimeSymbolicFieldElement): Ditto.
13878
13879 2012-11-12  Tiancheng Jiang  <tijiang@rim.com>
13880
13881         [BlackBerry] Update BB10 form theme.
13882         https://bugs.webkit.org/show_bug.cgi?id=100760
13883
13884         Reviewed by Rob Buis.
13885
13886         RIM PR 236993
13887         Internally Reviewed by Jeff Rogers.
13888         Enable GL slider.
13889
13890         * platform/blackberry/RenderThemeBlackBerry.cpp:
13891         (WebCore::drawThreeSlice):
13892         (WebCore):
13893         (WebCore::RenderThemeBlackBerry::paintSliderTrackRect):
13894         (WebCore::RenderThemeBlackBerry::paintSliderThumb):
13895
13896 2012-11-12  Kentaro Hara  <haraken@chromium.org>
13897
13898         [V8][JSC] HTMLElement::itemValue() needs not to be custom
13899         https://bugs.webkit.org/show_bug.cgi?id=101882
13900
13901         Reviewed by Adam Barth.
13902
13903         We can remove a [Custom] IDL attribute.
13904
13905         No tests. No change in behavior.
13906
13907         * bindings/js/JSHTMLElementCustom.cpp:
13908         * bindings/v8/custom/V8HTMLElementCustom.cpp:
13909         * html/HTMLElement.idl:
13910
13911 2012-11-12  Andreas Kling  <kling@webkit.org>
13912
13913         RenderStyle: Pack Color members tighter in substructures.
13914         <http://webkit.org/b/101860>
13915
13916         Reviewed by Antti Koivisto.
13917
13918         For RenderStyle substructures (StyleInheritedData, et al.), unfold all WebCore::Color
13919         members into RGBA32/bool variables OR just an RGBA32 if the color can never be invalid.
13920
13921         Memory saved per instance:
13922
13923             - StyleMultiColData:          4 bytes
13924             - StyleBackgroundData:        8 bytes
13925             - StyleInheritedData:         8 bytes
13926             - StyleRareInheritedData:    24 bytes
13927             - StyleRareNonInheritedData: 24 bytes
13928
13929         323kB progression on Membuster3.
13930
13931         * rendering/style/RenderStyle.cpp:
13932         (WebCore::RenderStyle::diff):
13933         (WebCore::RenderStyle::setColor):
13934         (WebCore::RenderStyle::setVisitedLinkColor):
13935         (WebCore::RenderStyle::setVisitedLinkColumnRuleColor):
13936         (WebCore::RenderStyle::setBackgroundColor):
13937         * rendering/style/RenderStyle.h:
13938         * rendering/style/StyleBackgroundData.cpp:
13939         (WebCore::StyleBackgroundData::StyleBackgroundData):
13940         * rendering/style/StyleBackgroundData.h:
13941         (WebCore::StyleBackgroundData::color):
13942         (StyleBackgroundData):
13943         * rendering/style/StyleInheritedData.cpp:
13944         (WebCore::StyleInheritedData::StyleInheritedData):
13945         * rendering/style/StyleInheritedData.h:
13946         (StyleInheritedData):
13947         * rendering/style/StyleMultiColData.cpp:
13948         (WebCore::StyleMultiColData::StyleMultiColData):
13949         (WebCore::StyleMultiColData::setVisitedLinkColumnRuleColor):
13950         * rendering/style/StyleMultiColData.h:
13951         (StyleMultiColData):
13952         (WebCore::StyleMultiColData::visitedLinkColumnRuleColor):
13953         * rendering/style/StyleRareInheritedData.cpp:
13954         (SameSizeAsStyleRareInheritedData):
13955         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
13956         (WebCore::StyleRareInheritedData::operator==):
13957         (WebCore::StyleRareInheritedData::setTextStrokeColor):
13958         (WebCore::StyleRareInheritedData::setTextFillColor):
13959         (WebCore::StyleRareInheritedData::setTextEmphasisColor):
13960         (WebCore::StyleRareInheritedData::setVisitedLinkTextStrokeColor):
13961         (WebCore::StyleRareInheritedData::setVisitedLinkTextFillColor):
13962         (WebCore::StyleRareInheritedData::setVisitedLinkTextEmphasisColor):
13963         * rendering/style/StyleRareInheritedData.h:
13964         (StyleRareInheritedData):
13965         (WebCore::StyleRareInheritedData::textStrokeColor):
13966         (WebCore::StyleRareInheritedData::textFillColor):
13967         (WebCore::StyleRareInheritedData::textEmphasisColor):
13968         (WebCore::StyleRareInheritedData::visitedLinkTextStrokeColor):
13969         (WebCore::StyleRareInheritedData::visitedLinkTextFillColor):
13970         (WebCore::StyleRareInheritedData::visitedLinkTextEmphasisColor):
13971         * rendering/style/StyleRareNonInheritedData.cpp:
13972         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
13973         (WebCore::StyleRareNonInheritedData::operator==):
13974         (WebCore::StyleRareNonInheritedData::setVisitedLinkBorderLeftColor):
13975         (WebCore::StyleRareNonInheritedData::setVisitedLinkBorderRightColor):
13976         (WebCore::StyleRareNonInheritedData::setVisitedLinkBorderTopColor):
13977         (WebCore::StyleRareNonInheritedData::setVisitedLinkBorderBottomColor):
13978         (WebCore::StyleRareNonInheritedData::setVisitedLinkOutlineColor):
13979         (WebCore::StyleRareNonInheritedData::setVisitedLinkBackgroundColor):
13980         * rendering/style/StyleRareNonInheritedData.h:
13981         (WebCore::StyleRareNonInheritedData::visitedLinkBackgroundColor):
13982         (WebCore::StyleRareNonInheritedData::visitedLinkOutlineColor):
13983         (WebCore::StyleRareNonInheritedData::visitedLinkBorderLeftColor):
13984         (WebCore::StyleRareNonInheritedData::visitedLinkBorderRightColor):
13985         (WebCore::StyleRareNonInheritedData::visitedLinkBorderTopColor):
13986         (WebCore::StyleRareNonInheritedData::visitedLinkBorderBottomColor):
13987         (StyleRareNonInheritedData):
13988
13989 2012-11-12  Pavel Feldman  <pfeldman@chromium.org>
13990
13991         Web Inspector: migrate text editor to mutation observers
13992         https://bugs.webkit.org/show_bug.cgi?id=101841
13993
13994         Reviewed by Vsevolod Vlasov.
13995
13996         Otherwise, we miss notifications on the removed lines.
13997
13998         * inspector/front-end/DefaultTextEditor.js:
13999         (WebInspector.TextEditorMainPanel):
14000         (WebInspector.TextEditorMainPanel.prototype.beginDomUpdates):
14001         (WebInspector.TextEditorMainPanel.prototype.endDomUpdates):
14002         (WebInspector.TextEditorMainPanel.prototype._handleMutations):
14003         (WebInspector.TextEditorMainPanel.prototype._handleMutation):
14004         * inspector/front-end/externs.js:
14005         (WebKitMutation):
14006         (WebKitMutationObserver.prototype.observe):
14007         (WebKitMutationObserver.prototype.disconnect):
14008
14009 2012-11-12  Allan Sandfeld Jensen  <sandfeld@kde.org>
14010
14011         [Qt] Flash-plugin starts with wrong width
14012         https://bugs.webkit.org/show_bug.cgi?id=101836
14013
14014         Reviewed by Simon Hausmann.
14015
14016         Defer the setWindow call, so that the one time it is called it will have its final size.
14017
14018         * plugins/PluginPackage.cpp:
14019         (WebCore::PluginPackage::determineQuirks):
14020
14021 2012-11-12  Tommy Widenflycht  <tommyw@google.com>
14022
14023         Remove the V8 custom code for WebSockets constructor
14024         https://bugs.webkit.org/show_bug.cgi?id=100801
14025
14026         Reviewed by Kentaro Hara.
14027
14028         This patch does the following:
14029
14030         1) Modifies the V8 code generator to support overloaded constructors,
14031            the JS generator is fixed to work as before. Proper support for JS will come later.
14032
14033         2) Modifies WebSocket.h/.cpp for the new constructors.
14034
14035         Tested by running WebSockets layout tests.
14036
14037         * Modules/websockets/WebSocket.cpp:
14038         (WebCore::WebSocket::create):
14039         (WebCore):
14040         * Modules/websockets/WebSocket.h:
14041         (WebSocket):
14042         * Modules/websockets/WebSocket.idl:
14043         * bindings/scripts/CodeGeneratorJS.pm:
14044         (GenerateConstructorDefinition):
14045         * bindings/scripts/CodeGeneratorV8.pm:
14046         (GenerateHeader):
14047         (GenerateOverloadedConstructorCallback):
14048         (GenerateSingleConstructorCallback):
14049         (GenerateConstructorCallback):
14050         (GenerateImplementation):
14051         * bindings/scripts/IDLParser.pm:
14052         (copyAttributes):
14053         (parseExtendedAttributeList):
14054         (parseExtendedAttributes):
14055         (applyExtendedAttributeList):
14056         * bindings/scripts/IDLStructure.pm:
14057         * bindings/scripts/test/CPP/WebDOMTestOverloadedConstructors.cpp: Added.
14058         (WebDOMTestOverloadedConstructors::WebDOMTestOverloadedConstructorsPrivate::WebDOMTestOverloadedConstructorsPrivate):
14059         (WebDOMTestOverloadedConstructors::WebDOMTestOverloadedConstructorsPrivate):
14060         (WebDOMTestOverloadedConstructors::WebDOMTestOverloadedConstructors):
14061         (WebDOMTestOverloadedConstructors::operator=):
14062         (WebDOMTestOverloadedConstructors::impl):
14063         (WebDOMTestOverloadedConstructors::~WebDOMTestOverloadedConstructors):
14064         (toWebCore):
14065         (toWebKit):
14066         * bindings/scripts/test/CPP/WebDOMTestOverloadedConstructors.h: Added.
14067         (WebCore):
14068         (WebDOMTestOverloadedConstructors):
14069         * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructors.cpp: Added.
14070         (WebKit):
14071         (WebKit::kit):
14072         (WebKit::core):
14073         (WebKit::wrapTestOverloadedConstructors):
14074         (webkit_dom_test_overloaded_constructors_finalize):
14075         (webkit_dom_test_overloaded_constructors_set_property):
14076         (webkit_dom_test_overloaded_constructors_get_property):
14077         (webkit_dom_test_overloaded_constructors_constructed):
14078         (webkit_dom_test_overloaded_constructors_class_init):
14079         (webkit_dom_test_overloaded_constructors_init):
14080         * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructors.h: Added.
14081         (_WebKitDOMTestOverloadedConstructors):
14082         (_WebKitDOMTestOverloadedConstructorsClass):
14083         * bindings/scripts/test/GObject/WebKitDOMTestOverloadedConstructorsPrivate.h: Added.
14084         (WebKit):
14085         * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp: Added.
14086         (WebCore):
14087         (WebCore::JSTestOverloadedConstructorsConstructor::JSTestOverloadedConstructorsConstructor):
14088         (WebCore::JSTestOverloadedConstructorsConstructor::finishCreation):
14089         (WebCore::JSTestOverloadedConstructorsConstructor::getOwnPropertySlot):
14090         (WebCore::JSTestOverloadedConstructorsConstructor::getOwnPropertyDescriptor):
14091         (WebCore::JSTestOverloadedConstructorsConstructor::constructJSTestOverloadedConstructors):
14092         (WebCore::JSTestOverloadedConstructorsConstructor::getConstructData):
14093         (WebCore::JSTestOverloadedConstructorsPrototype::self):
14094         (WebCore::JSTestOverloadedConstructors::JSTestOverloadedConstructors):
14095         (WebCore::JSTestOverloadedConstructors::finishCreation):
14096         (WebCore::JSTestOverloadedConstructors::createPrototype):
14097         (WebCore::JSTestOverloadedConstructors::destroy):
14098         (WebCore::JSTestOverloadedConstructors::~JSTestOverloadedConstructors):
14099         (WebCore::JSTestOverloadedConstructors::getOwnPropertySlot):
14100         (WebCore::JSTestOverloadedConstructors::getOwnPropertyDescriptor):
14101         (WebCore::jsTestOverloadedConstructorsConstructor):
14102         (WebCore::JSTestOverloadedConstructors::getConstructor):
14103         (WebCore::isObservable):
14104         (WebCore::JSTestOverloadedConstructorsOwner::isReachableFromOpaqueRoots):
14105         (WebCore::JSTestOverloadedConstructorsOwner::finalize):
14106         (WebCore::toJS):
14107         (WebCore::toTestOverloadedConstructors):
14108         * bindings/scripts/test/JS/JSTestOverloadedConstructors.h: Added.
14109         (WebCore):
14110         (JSTestOverloadedConstructors):
14111         (WebCore::JSTestOverloadedConstructors::create):
14112         (WebCore::JSTestOverloadedConstructors::createStructure):
14113         (WebCore::JSTestOverloadedConstructors::impl):
14114         (WebCore::JSTestOverloadedConstructors::releaseImpl):
14115         (WebCore::JSTestOverloadedConstructors::releaseImplIfNotNull):
14116         (JSTestOverloadedConstructorsOwner):
14117         (WebCore::wrapperOwner):
14118         (WebCore::wrapperContext):
14119         (JSTestOverloadedConstructorsPrototype):
14120         (WebCore::JSTestOverloadedConstructorsPrototype::create):
14121         (WebCore::JSTestOverloadedConstructorsPrototype::createStructure):
14122         (WebCore::JSTestOverloadedConstructorsPrototype::JSTestOverloadedConstructorsPrototype):
14123         (JSTestOverloadedConstructorsConstructor):
14124         (WebCore::JSTestOverloadedConstructorsConstructor::create):
14125         (WebCore::JSTestOverloadedConstructorsConstructor::createStructure):
14126         * bindings/scripts/test/ObjC/DOMTestOverloadedConstructors.h: Added.
14127         * bindings/scripts/test/ObjC/DOMTestOverloadedConstructors.mm: Added.
14128         (-[DOMTestOverloadedConstructors dealloc]):
14129         (-[DOMTestOverloadedConstructors finalize]):
14130         (core):
14131         (kit):
14132         * bindings/scripts/test/ObjC/DOMTestOverloadedConstructorsInternal.h: Added.
14133         (WebCore):
14134         * bindings/scripts/test/TestOverloadedConstructors.idl: Copied from Source/WebCore/bindings/scripts/test/TestSerializedScriptValueInterface.idl.
14135         * bindings/scripts/test/TestSerializedScriptValueInterface.idl:
14136         * bindings/scripts/test/V8/V8TestOverloadedConstructors.cpp: Added.
14137         (WebCore):
14138         (TestOverloadedConstructorsV8Internal):
14139         (WebCore::TestOverloadedConstructorsV8Internal::V8_USE):
14140         (WebCore::V8TestOverloadedConstructors::constructor1Callback):
14141         (WebCore::V8TestOverloadedConstructors::constructor2Callback):
14142         (WebCore::V8TestOverloadedConstructors::constructor3Callback):
14143         (WebCore::V8TestOverloadedConstructors::constructor4Callback):
14144         (WebCore::V8TestOverloadedConstructors::constructorCallback):
14145         (WebCore::ConfigureV8TestOverloadedConstructorsTemplate):
14146         (WebCore::V8TestOverloadedConstructors::GetRawTemplate):
14147         (WebCore::V8TestOverloadedConstructors::GetTemplate):
14148         (WebCore::V8TestOverloadedConstructors::HasInstance):
14149         (WebCore::V8TestOverloadedConstructors::wrapSlow):
14150         (WebCore::V8TestOverloadedConstructors::derefObject):
14151         * bindings/scripts/test/V8/V8TestOverloadedConstructors.h: Added.
14152         (WebCore):
14153         (V8TestOverloadedConstructors):
14154         (WebCore::V8TestOverloadedConstructors::toNative):
14155         (WebCore::V8TestOverloadedConstructors::installPerContextProperties):
14156         (WebCore::V8TestOverloadedConstructors::installPerContextPrototypeProperties):
14157         (WebCore::V8TestOverloadedConstructors::wrap):
14158         (WebCore::toV8):
14159         * bindings/v8/custom/V8WebSocketCustom.cpp:
14160
14161 2012-11-12  Shinya Kawanaka  <shinyak@chromium.org>
14162
14163         [Refactoring] Create SelectRuleFeatureSet for collecting RuleFeatureSet for select attribute
14164         https://bugs.webkit.org/show_bug.cgi?id=101891
14165
14166         Reviewed by Hajime Morita.
14167
14168         We would like to have another class for RuleFeatureSet to collect 'select' attribute features,
14169         since it will have more features than the original RuleFeatureSet has.
14170
14171         Also, some methods of ElementShadow are removed and we provide a method to get SelectRuleFeatureSet itself.
14172
14173         No new tests, no change in behavior.
14174
14175         * CMakeLists.txt:
14176         * GNUmakefile.list.am:
14177         * Target.pri:
14178         * WebCore.gypi:
14179         * WebCore.vcproj/WebCore.vcproj:
14180         * WebCore.xcodeproj/project.pbxproj:
14181         * dom/ElementShadow.h:
14182         (ElementShadow):
14183         (WebCore::ElementShadow::selectRuleFeatureSet):
14184         (WebCore):
14185         * html/shadow/SelectRuleFeatureSet.cpp: Added.
14186         (WebCore):
14187         (WebCore::SelectRuleFeatureSet::SelectRuleFeatureSet):
14188         (WebCore::SelectRuleFeatureSet::add):
14189         (WebCore::SelectRuleFeatureSet::clear):
14190         (WebCore::SelectRuleFeatureSet::collectFeaturesFromSelector):
14191         * html/shadow/SelectRuleFeatureSet.h: Added.
14192         (WebCore):
14193         (SelectRuleFeatureSet):
14194         (WebCore::SelectRuleFeatureSet::hasSelectorForId):
14195         (WebCore::SelectRuleFeatureSet::hasSelectorForClass):
14196         (WebCore::SelectRuleFeatureSet::hasSelectorForAttribute):
14197         * testing/Internals.cpp:
14198         (WebCore::Internals::hasSelectorForIdInShadow):
14199         (WebCore::Internals::hasSelectorForClassInShadow):
14200         (WebCore::Internals::hasSelectorForAttributeInShadow):
14201
14202 2012-11-13  Keishi Hattori  <keishi@webkit.org>
14203
14204         Build fix for Chromium Android (caused by r134216)
14205
14206         Unreviewed.
14207
14208         No new tests.
14209
14210         * platform/text/PlatformLocale.cpp:
14211         (WebCore::Locale::formatDateTime):
14212
14213 2012-11-12  Keishi Hattori  <keishi@webkit.org>
14214
14215         Add support for week/month to Locale::formatDateTime()
14216         https://bugs.webkit.org/show_bug.cgi?id=101878
14217
14218         Reviewed by Kent Tamura.
14219
14220         Adding support for week/month to Locale::formatDateTime() in preparation for datalist support for <input type=week/month>.
14221
14222         Added Chromium tests LocaleMacTest.formatWeek and LocaleMacTest.formatMonth.
14223
14224         * platform/text/PlatformLocale.cpp:
14225         (WebCore::DateTimeStringBuilder::visitField):
14226         (WebCore::Locale::formatDateTime): Support week and month types.
14227
14228 2012-11-12  Allan Sandfeld Jensen  <allan.jensen@digia.com>
14229
14230         [Qt] Can not load MHTML documents
14231         https://bugs.webkit.org/show_bug.cgi?id=101765
14232
14233         Reviewed by Simon Hausmann.
14234
14235         Recognize common MHTML extensions so that we can recognize MHTML tests on the file-system.
14236
14237         Tested by existing mhtml/ tests.
14238
14239         * platform/qt/MIMETypeRegistryQt.cpp:
14240         (WebCore):
14241
14242 2012-11-12  Andreas Kling  <akling@apple.com>
14243
14244         Tighten vector in ResourceRequestBase::setResponseContentDispositionEncodingFallbackArray().
14245         <http://webkit.org/b/101850>
14246
14247         Reviewed by Antti Koivisto.
14248
14249         Reserve the exact amount of space needed for m_responseContentDispositionEncodingFallbackArray.
14250         222kB progression on Membuster3.
14251
14252         * platform/network/ResourceRequestBase.cpp:
14253         (WebCore::ResourceRequestBase::setResponseContentDispositionEncodingFallbackArray):
14254
14255 2012-11-12  Tommy Widenflycht  <tommyw@google.com>
14256
14257         MediaStream API: Schedule the RTCDataChannel events to be triggered at idle state
14258         https://bugs.webkit.org/show_bug.cgi?id=101751
14259
14260         Reviewed by Adam Barth.
14261
14262         This patch queues the events until the JS interpreter is in an idle state.
14263
14264         Existing tests cover this patch.
14265
14266         * Modules/mediastream/RTCDataChannel.cpp:
14267         (WebCore::RTCDataChannel::RTCDataChannel):
14268         (WebCore::RTCDataChannel::readyStateChanged):
14269         (WebCore::RTCDataChannel::dataArrived):
14270         (WebCore::RTCDataChannel::error):
14271         (WebCore::RTCDataChannel::scheduleDispatchEvent):
14272         (WebCore):
14273         (WebCore::RTCDataChannel::scheduledEventTimerFired):
14274         * Modules/mediastream/RTCDataChannel.h:
14275         (RTCDataChannel):
14276         * platform/chromium/support/WebRTCDataChannel.cpp:
14277         (WebKit::WebRTCDataChannel::setBufferedAmount):
14278         (WebKit::WebRTCDataChannel::readyStateChanged):
14279         (WebKit::WebRTCDataChannel::dataArrived):
14280         (WebKit::WebRTCDataChannel::error):
14281
14282 2012-11-12  Kunihiko Sakamoto  <ksakamoto@chromium.org>
14283
14284         Remove HTMLInputElement dependency from PickerIndicatorElement
14285         https://bugs.webkit.org/show_bug.cgi?id=101913
14286
14287         Reviewed by Kent Tamura.
14288
14289         Introduced PickerIndicatorOwner interface that replaces the role of hostInput() in
14290         PickerIndicatorElement. It makes easier to add interactions between picker indicator
14291         and its owner without having to add functions to HTMLInputElement.
14292
14293         No new tests. This is just a refactor.
14294
14295         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
14296         (WebCore::BaseMultipleFieldsDateAndTimeInputType::isPickerIndicatorOwnerDisabledOrReadOnly): Added.
14297         (WebCore):
14298         (WebCore::BaseMultipleFieldsDateAndTimeInputType::pickerIndicatorChooseValue): Added.
14299         (WebCore::BaseMultipleFieldsDateAndTimeInputType::setupDateTimeChooserParameters): Added.
14300         (WebCore::BaseMultipleFieldsDateAndTimeInputType::~BaseMultipleFieldsDateAndTimeInputType):
14301         (WebCore::BaseMultipleFieldsDateAndTimeInputType::createShadowSubtree):
14302         (WebCore::BaseMultipleFieldsDateAndTimeInputType::destroyShadowSubtree):
14303         * html/BaseMultipleFieldsDateAndTimeInputType.h:
14304         (WebCore):
14305         (BaseMultipleFieldsDateAndTimeInputType): Implements PickerIndicatorOwner.
14306         * html/shadow/PickerIndicatorElement.cpp: Replaced all the use of hostInput() by using PickerIndicatorOwner.
14307         (WebCore::PickerIndicatorElement::PickerIndicatorElement):
14308         (WebCore::PickerIndicatorElement::create):
14309         (WebCore::PickerIndicatorElement::defaultEventHandler):
14310         (WebCore::PickerIndicatorElement::willRespondToMouseClickEvents):
14311         (WebCore::PickerIndicatorElement::didChooseValue):
14312         (WebCore::PickerIndicatorElement::openPopup):
14313         * html/shadow/PickerIndicatorElement.h:
14314         (PickerIndicatorElement): Added a PickerIndicatorOwner member.
14315         (PickerIndicatorOwner): An interface class for communicating picker indicator and its owner.
14316         (WebCore::PickerIndicatorElement::PickerIndicatorOwner::~PickerIndicatorOwner):
14317         (WebCore::PickerIndicatorElement::removePickerIndicatorOwner):
14318
14319 2012-11-12  Mihnea Ovidenie  <mihnea@adobe.com>
14320
14321         [CSSRegions]Add support for text-shadow in region styling
14322         https://bugs.webkit.org/show_bug.cgi?id=94472
14323
14324         Reviewed by David Hyatt.
14325
14326         Original patch by Andrei Onea.
14327         Add support for text-shadow in region styling (@-webkit-region rule).
14328         In addition to the previously supported region styling properties (background-color and color),
14329         text-shadow requires the computation of an element style in region at layout time.
14330
14331         This patch adds a new method on RenderRegion - ensureRegionStyleForObject - that
14332         can be used to retrieve the object style in region (if already cached) or to compute it
14333         on the spot. When computing the object style in region, we need to compute the style in region
14334         also for the object ancestor, up to the content nodes.
14335
14336         This patch also refactors the way styles in region are computed and stored, because
14337         we can compute the style in region not only at paint time, but also at layout time.
14338
14339         Test: fast/regions/region-style-text-shadow.html
14340
14341         * css/StyleResolver.cpp:
14342         (WebCore::StyleResolver::isValidRegionStyleProperty):
14343         Allow text-shadow to be used in region styling.
14344         * rendering/InlineBox.cpp:
14345         (WebCore::InlineBox::styleInRegion):
14346         Retrieve the region style for an InlineBox's renderer, given its RenderRegion.
14347         Compute the style in region if not computed yet.
14348         (WebCore::InlineBox::regionDuringLayout):
14349         Retrieve the region in which an InlineBox is being flowed.
14350         * rendering/InlineBox.h:
14351         * rendering/InlineFlowBox.cpp: Take region styling into account.
14352         (WebCore::InlineFlowBox::addToLine):
14353         (WebCore::InlineFlowBox::addTextBoxVisualOverflow):
14354         * rendering/RenderRegion.cpp:
14355         (WebCore::RenderRegion::setRegionObjectsRegionStyle):
14356         (WebCore::canCacheObjectStyleInRegion):
14357         Test if we can cache the computed style in region.
14358         (WebCore::RenderRegion::restoreRegionObjectsOriginalStyle):
14359         (WebCore::RenderRegion::computeStyleInRegion):
14360         (WebCore::RenderRegion::setChildrenStyleInRegion):
14361         (WebCore::setObjectHasBoxDecorationsFlag):
14362         (WebCore::RenderRegion::setObjectStyleInRegion):
14363         (WebCore::RenderRegion::clearObjectStyleInRegion):
14364         (WebCore::RenderRegion::ensureRegionStyleForObject):
14365         * rendering/RenderRegion.h:
14366
14367 2012-11-12  Sheriff Bot  <webkit.review.bot@gmail.com>
14368
14369         Unreviewed, rolling out r134154.
14370         http://trac.webkit.org/changeset/134154
14371         https://bugs.webkit.org/show_bug.cgi?id=101919
14372
14373         Causes plenty of crashes on GTK and Apple Win builders
14374         (Requested by zdobersek on #webkit).
14375
14376         * css/mediaControls.css:
14377         * css/mediaControlsQuickTime.css:
14378         (audio::-webkit-media-controls-toggle-closed-captions-button, video::-webkit-media-controls-toggle-closed-captions-button):
14379         (audio::-webkit-media-controls-volume-slider-mute-button, video::-webkit-media-controls-volume-slider-mute-button):
14380         * html/shadow/MediaControlElements.cpp:
14381         (WebCore::MediaControlToggleClosedCaptionsButtonElement::MediaControlToggleClosedCaptionsButtonElement):
14382         (WebCore::MediaControlToggleClosedCaptionsButtonElement::create):
14383         (WebCore::MediaControlToggleClosedCaptionsButtonElement::defaultEventHandler):
14384         (WebCore::MediaControlToggleClosedCaptionsButtonElement::updateDisplayType):
14385         (WebCore::MediaControlToggleClosedCaptionsButtonElement::shadowPseudoId):
14386         * html/shadow/MediaControlElements.h:
14387         (MediaControlElement):
14388         (MediaControlToggleClosedCaptionsButtonElement):
14389         * html/shadow/MediaControlRootElement.cpp:
14390         (WebCore::MediaControlRootElement::MediaControlRootElement):
14391         (WebCore::MediaControlRootElement::create):
14392         (WebCore::MediaControlRootElement::setMediaController):
14393         (WebCore::MediaControlRootElement::hide):
14394         (WebCore::MediaControlRootElement::makeTransparent):
14395         (WebCore::MediaControlRootElement::reset):
14396         (WebCore::MediaControlRootElement::reportedError):
14397         * html/shadow/MediaControlRootElement.h:
14398         (WebCore):
14399         (MediaControlRootElement):
14400         * html/shadow/MediaControlRootElementChromium.cpp:
14401         (WebCore::MediaControlRootElementChromium::initializeControls):
14402         * html/shadow/MediaControls.h:
14403         (MediaControls):
14404         * platform/Language.cpp:
14405         (WebCore):
14406         * platform/Language.h:
14407         (WebCore):
14408         * rendering/RenderMediaControls.cpp:
14409         (WebCore::RenderMediaControls::paintMediaControlsPart):
14410         * rendering/RenderMediaControlsChromium.cpp:
14411         (WebCore::RenderMediaControlsChromium::paintMediaControlsPart):
14412
14413 2012-11-12  Mike West  <mkwst@chromium.org>
14414
14415         'for (x in y)' requires 'var' declaration in ConsoleMessage.js
14416         https://bugs.webkit.org/show_bug.cgi?id=101908
14417
14418         Reviewed by Pavel Feldman.
14419
14420         r134166 should have included a 'var' declaration in its 'for (x in y)'
14421         loop. This patch adds the missing 'var' in order to prevent leakage into
14422         the global context.
14423
14424         * inspector/front-end/ConsoleMessage.js:
14425         (WebInspector.ConsoleMessageImpl.prototype.append):
14426         (WebInspector.ConsoleMessageImpl.prototype._formatWithSubstitutionString):
14427
14428 2012-11-12  Zeno Albisser  <zeno@webkit.org>
14429
14430         [Qt] MiniBrowser should not strongly depend on QtTestSupport.
14431         https://bugs.webkit.org/show_bug.cgi?id=101775
14432
14433         Introducing HAVE(QTTESTSUPPORT) to allow building
14434         MiniBrowser without QtTestSupport.
14435         This is necessary when using a production build.
14436
14437         Reviewed by Tor Arne Vestbø.
14438
14439         * Target.pri:
14440         * platform/qt/QtTestSupport.h:
14441
14442 2012-11-12  Pavel Feldman  <pfeldman@chromium.org>
14443
14444         Web Inspector: wasShown is called twice when show() is called from within wasShown
14445         https://bugs.webkit.org/show_bug.cgi?id=101858
14446
14447         Reviewed by Vsevolod Vlasov.
14448
14449         When we attach views lazily from within wasShown, the views were getting wasShown notification twice.
14450         We now mute one of them.
14451
14452         * inspector/front-end/View.js:
14453         (WebInspector.View):
14454         (WebInspector.View.prototype._inNotification):
14455         (WebInspector.View.prototype._parentIsShowing):
14456         (WebInspector.View.prototype._callOnVisibleChildren):
14457         (WebInspector.View.prototype._processWasShown):
14458         (WebInspector.View.prototype._processWillHide):
14459         (WebInspector.View.prototype._processOnResize):
14460         (WebInspector.View.prototype._notify):
14461         (WebInspector.View.prototype.show):
14462
14463 2012-11-12  Ryosuke Niwa  <rniwa@webkit.org>
14464
14465         Build fix after r134191. Turns out that FrameView::performPostLayoutTasks calls FrameSelection::updateAppearance
14466         in the middle of a layout. So we can't have assertions in recomputeCaretRect and updateAppearance.
14467
14468         Furthermore, we can't update layout in updateAppearance. So do that in its call sites.
14469
14470         * editing/FrameSelection.cpp:
14471         (WebCore::FrameSelection::setSelection):
14472         (WebCore::FrameSelection::recomputeCaretRect):
14473         (WebCore::FrameSelection::updateAppearance):
14474         (WebCore::FrameSelection::setCaretVisibility):
14475
14476 2012-11-12  Shinya Kawanaka  <shinyak@chromium.org>
14477
14478         Don't update style when attaching in HTMLMeterElement
14479         https://bugs.webkit.org/show_bug.cgi?id=101714
14480
14481         Reviewed by Hajime Morita.
14482
14483         HTMLMeterElement was updating style when it's being attached. However, updating style when attaching
14484         can cause style-update prevention. The similar thing has already happened in Bug 100507.
14485
14486         Since we have already set the default value in creating ShadowDOM subtree, we don't need to update style actually.
14487
14488         Test: fast/dom/HTMLMeterElement/meter-bar-set-value.html
14489
14490         * html/HTMLMeterElement.cpp:
14491         * html/HTMLMeterElement.h:
14492         (HTMLMeterElement): Removed attach(). We don't need it.
14493
14494 2012-11-09  Ryosuke Niwa  <rniwa@webkit.org>
14495
14496         Multiple Layout Tests (e.g. fast/repaint/japanese-rl-selection-clear.html) is failing after r133840.
14497         https://bugs.webkit.org/show_bug.cgi?id=101547
14498
14499         Reviewed by Simon Fraser.
14500
14501         I overlooked the fact when the selection is null, we still have to invalidate the caret rect that
14502         previously existed. Revert the optimization added in r133840 to skip caret invalidation when new
14503         selection is null, and add a special method to be called by FrameLoader prior to destruction instead.
14504         This will let us avoid doing an extra layout upon destruction and not regress repaint tests.
14505
14506         Covered by existing tests.
14507
14508         * editing/FrameSelection.cpp:
14509         (WebCore::FrameSelection::setSelection): Added DoNotUpdateAppearance option.
14510         (WebCore::FrameSelection::prepareForDestruction): Added.
14511         (WebCore::FrameSelection::updateAppearance): Reverted the flawed optimization added in r133840.
14512         Also, don't update style before updating selection unless text caret is disabled since we always
14513         update the layout (including style) when text caret is enabled.
14514         * editing/FrameSelection.h:
14515         (FrameSelection):
14516         * loader/FrameLoader.cpp:
14517         (WebCore::FrameLoader::clear): Call prepareForDestruction instead of clear to avoid a layout.
14518
14519 2012-11-11  Dongwoo Joshua Im  <dw.im@samsung.com>
14520
14521         [CSS3] Parsing the property, text-align-last.
14522         https://bugs.webkit.org/show_bug.cgi?id=99439
14523
14524         Reviewed by Julien Chaffraix.
14525
14526         This patch implements the parsing side of the "text-align-last" property specified
14527         in CSS3 working draft, with "-webkit-" prefix, under ENABLE_CSS3_TEXT flag.
14528         Specification link : http://www.w3.org/TR/css3-text/#text-align-last
14529
14530         Tests: fast/css3-text/css3-text-align-last/getComputedStyle/getComputedStyle-text-align-last-inherited.html
14531                fast/css3-text/css3-text-align-last/getComputedStyle/getComputedStyle-text-align-last.html
14532
14533         * css/CSSComputedStyleDeclaration.cpp:
14534         (WebCore):
14535         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): Get the value of the text-align-last property.
14536         * css/CSSParser.cpp:
14537         (WebCore::CSSParser::parseValue): Parse the value, and check whether it is a proper value which text-align-last can have.
14538         * css/CSSPrimitiveValueMappings.h:
14539         (WebCore):
14540         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
14541         (WebCore::CSSPrimitiveValue::operator ETextAlignLast):
14542         * css/CSSProperty.cpp:
14543         (WebCore::CSSProperty::isInheritedProperty):
14544         * css/CSSPropertyNames.in: Add '-webkit-text-align-last' property.
14545         * css/StyleBuilder.cpp:
14546         (WebCore::StyleBuilder::StyleBuilder):
14547         * css/StylePropertySet.cpp:
14548         (WebCore):
14549         * css/StyleResolver.cpp:
14550         (WebCore::StyleResolver::applyProperty):
14551         * rendering/style/RenderStyle.h:
14552         * rendering/style/RenderStyleConstants.h:
14553         * rendering/style/StyleRareInheritedData.cpp:
14554         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
14555         (WebCore::StyleRareInheritedData::operator==):
14556         * rendering/style/StyleRareInheritedData.h:
14557         (StyleRareInheritedData): Add m_textAlignLast.
14558
14559 2012-11-11  Shinya Kawanaka  <shinyak@chromium.org>
14560
14561         [Refactoring] Remove shadowPseudoId() and use setPseudo() in HTMLKeygenElement
14562         https://bugs.webkit.org/show_bug.cgi?id=101881
14563
14564         Reviewed by Kent Tamura.
14565
14566         We're migrating shadowPseudoId() to pseudo(). We remove shadowPseudoId() from HTMLKeygenElement and use
14567         setPseudo()/pseudo() instead.
14568
14569         No new tests, simple refacotring.
14570
14571         * html/HTMLKeygenElement.cpp:
14572         (WebCore::KeygenSelectElement::KeygenSelectElement):
14573         (KeygenSelectElement):
14574
14575 2012-11-11  Adam Barth  <abarth@webkit.org>
14576
14577         Many DOMWindowProperties would benefit from being ScriptWrappable
14578         https://bugs.webkit.org/show_bug.cgi?id=101887
14579
14580         Reviewed by Kentaro Hara.
14581
14582         These object are only ever created at the behest of script, which means
14583         making them ScriptWrappable is a win.
14584
14585         * page/BarInfo.h:
14586         * page/Console.h:
14587         * page/Crypto.h:
14588         * page/History.h:
14589         * page/Location.h:
14590         * page/Navigator.h:
14591         * page/Performance.h:
14592
14593 2012-11-11  Kentaro Hara  <haraken@chromium.org>
14594
14595         [V8] HTMLDocument::all() needs not to be custom
14596         https://bugs.webkit.org/show_bug.cgi?id=101875
14597
14598         Reviewed by Adam Barth.
14599
14600         We can easily remove the custom getter from V8 because the
14601         custom setter sets .all by ForceSet(). On the other hand,
14602         it is non-trivial to remove the custom getter from JSC
14603         because the custom setter sets .all by putDirect()
14604         and the custom getter wants to get it by getDirect().
14605
14606         No tests. No change in behavior.
14607
14608         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
14609         * html/HTMLDocument.idl:
14610
14611 2012-11-11  Kentaro Hara  <haraken@chromium.org>
14612
14613         [V8] V8Console::memoryAttrGetter() needs not to be custom
14614         https://bugs.webkit.org/show_bug.cgi?id=101873
14615
14616         Reviewed by Adam Barth.
14617
14618         No tests. No change in behavior.
14619
14620         * bindings/v8/custom/V8ConsoleCustom.cpp:
14621         (WebCore):
14622         * page/Console.idl:
14623
14624 2012-11-11  Shinya Kawanaka  <shinyak@chromium.org>
14625
14626         [Shadow] ElementShadow should have RuleFeatureSet for select attribute selectors.
14627         https://bugs.webkit.org/show_bug.cgi?id=101180
14628
14629         Reviewed by Dimitri Glazkov.
14630
14631         This is a preparation patch for Bug 100451.
14632
14633         We preserve RuleFeatureSet collected from select attributes in ShadowDOM.
14634         When an element attribute is changed, we might have to invalidate content distribution,
14635         however it's high cost operation. So we would like to check RuleFeatureSet used in
14636         select attributes to determine we really need to invalidate distribution.
14637
14638         Like StyleResolver, ElementShadow has several rule features. When nested ShadowDOM is used,
14639         first we collect features in nested ShadowDOM, and merge it to the parent ShadowDOM.
14640         For the performance reason, we have a flag to check whether we need to collect features again.
14641
14642         Test: fast/dom/shadow/shadow-select-attribute-featureset.html
14643
14644         * WebCore.exp.in:
14645         * dom/ElementShadow.cpp:
14646         (WebCore::ElementShadow::ElementShadow):
14647         (WebCore::ElementShadow::setShouldCollectSelectFeatureSet): Enable a flag to collect feature set of descendant
14648         nodes (and their ShadowDOM).
14649         (WebCore):
14650         (WebCore::ElementShadow::ensureSelectFeatureSetCollected):
14651         (WebCore::ElementShadow::collectSelectFeatureSetFrom): Collect RuleFeatureSet from all descendant Nodes and their
14652         ShadowDOM. We need to collect id, class, and attribute names.
14653         * dom/ElementShadow.h:
14654         (WebCore::ElementShadow::shouldCollectSelectFeatureSet):
14655         (ElementShadow):
14656         (WebCore::ElementShadow::hasSelectorForId):
14657         (WebCore):
14658         (WebCore::ElementShadow::hasSelectorForClass):
14659         (WebCore::ElementShadow::hasSelectorForAttribute):
14660         * html/shadow/HTMLContentElement.cpp:
14661         (WebCore::HTMLContentElement::parseAttribute): When select attribute is changed, enable a flag to recollect features.
14662         (WebCore::HTMLContentElement::insertedInto): We have to recollect features when HTMLContentElement is moved.
14663         (WebCore::HTMLContentElement::removedFrom): ditto.
14664         * html/shadow/HTMLContentElement.h:
14665         (WebCore::toHTMLContentElement):
14666         (WebCore):
14667         * testing/Internals.cpp:
14668         (WebCore::Internals::hasSelectorForIdInShadow):
14669         (WebCore):
14670         (WebCore::Internals::hasSelectorForClassInShadow):
14671         (WebCore::Internals::hasSelectorForAttributeInShadow):
14672         * testing/Internals.h:
14673         (Internals):
14674         * testing/Internals.idl:
14675
14676 2012-11-11  Sheriff Bot  <webkit.review.bot@gmail.com>
14677
14678         Unreviewed, rolling out r134144.
14679         http://trac.webkit.org/changeset/134144
14680         https://bugs.webkit.org/show_bug.cgi?id=101876
14681
14682         seems to break win 7 chromium browser test (Requested by
14683         hayato on #webkit).
14684
14685         * WebCore.exp.in:
14686         * page/EventHandler.cpp:
14687         (WebCore):
14688         (WebCore::EventHandler::handleMouseMoveEvent):
14689         * page/EventHandler.h:
14690         (EventHandler):
14691         * testing/Internals.cpp:
14692         * testing/Internals.h:
14693         * testing/Internals.idl:
14694
14695 2012-11-11  Kent Tamura  <tkent@chromium.org>
14696
14697         Internals: MockPagePopup should not update DOM structure during detach()
14698         https://bugs.webkit.org/show_bug.cgi?id=101710
14699
14700         Reviewed by Hajime Morita.
14701
14702         PickerIndicatorElement::detach calls
14703         MockPagePopupDriver::closePagePopup, MockPagePopup::~MockPagePopup,
14704         which remove the mock iframe from the tree. But updating the tree during
14705         detach() is dangerous.
14706
14707         MockPagePopupDriver::closePagePopup calls MockpagePopup::closeLater, it
14708         requests to call 'close' asynchronously, and 'close' removes the mock
14709         iframe. We need to change MockPagePopup so that it is ref-couted and has
14710         a timer.
14711
14712         No new tests. This is a change for the test harness.
14713
14714         * testing/MockPagePopupDriver.cpp:
14715         (MockPagePopup): Make this ref-counted, add closeLater, add close, and
14716         add m_closeTimer.
14717         (WebCore::MockPagePopup::MockPagePopup): Initialize the timer.
14718         (WebCore::MockPagePopup::create): PassOwnPtr -> PassRefPtr
14719         (WebCore::MockPagePopup::closeLater):
14720         - Add one reference to avoid destruction by m_mockPagePopup.clear() in
14721           closePagePopup.
14722         - Notify didClosePopup here because the client expects didClosePopup is
14723           called synchronously.
14724         - Invoke the timer to call 'close'
14725         (WebCore::MockPagePopup::close):
14726         Just remove one reference. This means calling the desructor.
14727         (WebCore::MockPagePopup::~MockPagePopup):
14728         Move didClosePopup call to caloseLater.
14729         (WebCore::MockPagePopupDriver::closePagePopup):
14730         Request to close PagePopup.
14731         Clear PagePopupClient in m_pagePopupController because this object is
14732         necessary until MockPagePopup is closed, but it should not have a
14733         reference to the PagePopupClient.
14734         * testing/MockPagePopupDriver.h:
14735         (MockPagePopupDriver): Make MockPagePopup ref-counted.
14736
14737 2012-11-11  Adam Barth  <abarth@webkit.org>
14738
14739         axObjectCache code is more complicated than necessary
14740         https://bugs.webkit.org/show_bug.cgi?id=101820
14741
14742         Reviewed by Darin Adler.
14743
14744         This code should use OwnPtr rather than manually calling new/delete.
14745         Also, instead of using a "double check" pattern, we can just access the
14746         private fields on the top document directly.
14747
14748         * dom/Document.cpp:
14749         (WebCore::Document::Document):
14750         (WebCore::Document::clearAXObjectCache):
14751         (WebCore::Document::axObjectCacheExists):
14752         (WebCore):
14753         (WebCore::Document::axObjectCache):
14754         * dom/Document.h:
14755         (Document):
14756
14757 2012-11-10  Simon Fraser  <simon.fraser@apple.com>
14758
14759         Save one call to containerForRepaint() when updating layer positions
14760         https://bugs.webkit.org/show_bug.cgi?id=101856
14761
14762         Reviewed by Dan Bernstein.
14763
14764          RenderLayer::updateLayerPositions() has already computed the repaint container,
14765          but calls computeRepaintRects() which computes it again. Computing the repaint
14766          container involves a walk back up the layer tree, so calling it during a tree
14767          traversal is costly.
14768          
14769          Fix by passing the repaint container down into computeRepaintRects().
14770
14771         * rendering/RenderLayer.cpp:
14772         (WebCore::RenderLayer::updateLayerPositions):
14773         (WebCore::RenderLayer::computeRepaintRects):
14774         (WebCore::RenderLayer::computeRepaintRectsIncludingDescendants):
14775         (WebCore::RenderLayer::updateLayerPositionsAfterScroll):
14776         (WebCore::RenderLayer::setHasVisibleContent):
14777         * rendering/RenderLayer.h:
14778         (RenderLayer):
14779
14780 2012-11-11  Kenichi Ishibashi  <bashi@chromium.org>
14781
14782         WTFString::utf8() should have a mode of conversion to use replacement character
14783         https://bugs.webkit.org/show_bug.cgi?id=101678
14784
14785         Reviewed by Alexey Proskuryakov.
14786
14787         Follow the change on String::utf8()
14788
14789         No new tests. No changes in behavior.
14790
14791         * Modules/websockets/WebSocket.cpp:
14792         (WebCore::WebSocket::close): Pass String::StrictConversion instead of true to String::utf8().
14793         * Modules/websockets/WebSocketChannel.cpp:
14794         (WebCore::WebSocketChannel::send): Ditto.
14795         * html/MediaFragmentURIParser.cpp:
14796         (WebCore::MediaFragmentURIParser::parseFragments): Ditto.
14797         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
14798         (WebCore::MediaPlayerPrivate::notifyChallengeResult): Ditto.
14799         * platform/network/blackberry/rss/RSSFilterStream.cpp:
14800         (WebCore::RSSFilterStream::convertContentToHtml): Ditto.
14801         * platform/network/blackberry/rss/RSSGenerator.cpp:
14802         (WebCore::RSSGenerator::generateHtml): Ditto.
14803
14804 2012-11-10  Simon Fraser  <simon.fraser@apple.com>
14805
14806         Coalesce main thread scroll position updates
14807         https://bugs.webkit.org/show_bug.cgi?id=101855
14808
14809         Reviewed by Anders Carlsson.
14810
14811         When using threaded scrolling, the dispatched updateMainFrameScrollPosition() calls 
14812         from ScrollingTree would pile up on the main thread, and we'd handle several per
14813         runloop cycle when scrolling fast. This causes extra work especially on pages
14814         with position:fixed elements which must update RenderLayers on scrolling.
14815         
14816         Fix by using a zero-delay timer in ScrollingCoordinator to coalesce these
14817         scrolling updates to one per runloop.
14818
14819         * page/scrolling/ScrollingCoordinator.cpp:
14820         (WebCore::ScrollingCoordinator::ScrollingCoordinator): Initialized data members
14821         for the scheduled scroll position update.
14822         (WebCore::ScrollingCoordinator::scheduleUpdateMainFrameScrollPosition): If 
14823         the timer is active and the parameters match, just update the target scroll
14824         position and return. If the params don't match, dispatch the scheduled update,
14825         and then the new one. Otherwise, prime the timer.
14826         (WebCore::ScrollingCoordinator::updateMainFrameScrollPositionTimerFired): Call
14827         the existing updateMainFrameScrollPosition() with the saved values.
14828         * page/scrolling/ScrollingCoordinator.h:
14829         * page/scrolling/ScrollingTree.cpp:
14830         (WebCore::ScrollingTree::updateMainFrameScrollPosition): Call scheduleUpdateMainFrameScrollPosition()
14831         rather than updateMainFrameScrollPosition().
14832         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
14833         (WebCore::ScrollingCoordinatorMac::syncChildPositions): Fixed a bug that caused fixed
14834         position elements to jiggle with the patch; we should be calling syncPosition() (which just
14835         sets the position data, without touching CA layers).
14836
14837 2012-11-10  Simon Fraser  <simon.fraser@apple.com>
14838
14839         Remove ScrollingCoordinatorMac::updateMainFrameScrollPositionAndScrollLayerPosition()
14840         https://bugs.webkit.org/show_bug.cgi?id=101514
14841
14842         Reviewed by Tim Horton.
14843
14844         ScrollingCoordinatorMac::updateMainFrameScrollPositionAndScrollLayerPosition() is very similar to
14845         ScrollingCoordinator::updateMainFrameScrollPosition(). In order to eliminate updateMainFrameScrollPositionAndScrollLayerPosition(),
14846         we just need to plumb through a flag that says that updateMainFrameScrollPosition() should
14847         set the layer position (rather than just doing a 'sync').
14848
14849         * page/scrolling/ScrollingCoordinator.cpp:
14850         (WebCore::ScrollingCoordinator::updateMainFrameScrollPosition):
14851         * page/scrolling/ScrollingCoordinator.h:
14852         * page/scrolling/ScrollingTree.cpp:
14853         (WebCore::ScrollingTree::updateMainFrameScrollPosition):
14854         * page/scrolling/ScrollingTree.h:
14855         * page/scrolling/mac/ScrollingCoordinatorMac.h:
14856         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
14857         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
14858         (WebCore::ScrollingTreeScrollingNodeMac::setScrollPositionWithoutContentEdgeConstraints):
14859
14860 2012-11-10  Sheriff Bot  <webkit.review.bot@gmail.com>
14861
14862         Unreviewed, rolling out r134069.
14863         http://trac.webkit.org/changeset/134069
14864         https://bugs.webkit.org/show_bug.cgi?id=101852
14865
14866         "It is a wrong way to fix the problem. See discussions in bug
14867         96614" (Requested by 1JTAAPQFJ on #webkit).
14868
14869         * bindings/js/JSDictionary.cpp:
14870         (WebCore::JSDictionary::getWithUndefinedOrNullCheck):
14871
14872 2012-11-10  Mike West  <mkwst@chromium.org>
14873
14874         Web Inspector: Multiple '%c' formatting options should all have effect.
14875         https://bugs.webkit.org/show_bug.cgi?id=101495
14876
14877         Reviewed by Pavel Feldman.
14878
14879         This patch supports multiple '%c' formatting blocks in console messages.
14880         'console.log("%cblue! %cgreen!", "color: blue;", "color: green;")' will
14881         do exactly what you expect: "blue!" will be blue, and "green!" will be
14882         green.
14883
14884         The implementation moves the styles off the message's parent 'span', and
14885         onto new 'span' elements that wrap the various textual bits of the
14886         message.
14887
14888         * inspector/front-end/ConsoleMessage.js:
14889         (WebInspector.ConsoleMessageImpl.prototype.):
14890         (WebInspector.ConsoleMessageImpl.prototype.append):
14891         (WebInspector.ConsoleMessageImpl.prototype._formatWithSubstitutionString):
14892
14893 2012-11-10  Mike West  <mkwst@chromium.org>
14894
14895         Including <CoreText/CoreText.h> breaks the chromium/mac build.
14896         https://bugs.webkit.org/show_bug.cgi?id=101851
14897
14898         Reviewed by Dan Bernstein.
14899
14900         r134146 introduced inclusion of 'CoreText/CoreText.h' in
14901         SimpleFontDataCoreText.cpp, which broke the chromium/mac build. Grepping
14902         around, it looks like this needs to be modified to include
14903         'ApplicationServices/ApplicationServices.h'.
14904
14905         * platform/graphics/mac/SimpleFontDataCoreText.cpp:
14906             Drop 'CoreText.h' in favor of 'ApplicationServices.h'.
14907         * platform/graphics/mac/ComplexTextControllerCoreText.mm:
14908             Drop the platform-specific '#if' logic; just include 'ApplicationServices.h'.
14909
14910 2012-11-10  Andreas Kling  <kling@webkit.org>
14911
14912         Don't detach from shared ElementAttributeData when overwriting attribute with identical value.
14913         <http://webkit.org/b/101849>
14914
14915         Reviewed by Anders Carlsson.
14916
14917         Defer the mutableAttributeData() call in Element::setAttributeInternal() until the last
14918         possible moment, to avoid unnecessarily detaching and cloning from attribute data.
14919
14920         120 kB progression on Membuster3.
14921
14922         * dom/Element.cpp:
14923         (WebCore::Element::setAttributeInternal):
14924         (WebCore::Element::addAttributeInternal):
14925
14926 2012-11-10  Simon Fraser  <simon.fraser@apple.com>
14927
14928         Some minor optimizations in RenderLayer
14929         https://bugs.webkit.org/show_bug.cgi?id=101847
14930
14931         Reviewed by Anders Carlsson.
14932
14933         Some minor performance improvements in RenderLayer code.
14934
14935         * rendering/RenderLayer.cpp:
14936         (WebCore::RenderLayer::updateLayerPosition): isRenderInline() is a virtual call,
14937         so prefix it with an isInline() check which tests a bit on RenderObject.
14938         (WebCore::RenderLayer::localBoundingBox): Ditto.
14939         (WebCore::RenderLayer::calculateLayerBounds): Pull layer->renderer()
14940         into a local variable.
14941
14942 2012-11-10  Anders Carlsson  <andersca@apple.com>
14943
14944         Document::m_fullScreenElementStack should be a Vector
14945         https://bugs.webkit.org/show_bug.cgi?id=101844
14946
14947         Reviewed by Andreas Kling.
14948
14949         m_fullScreenElementStack is currently a Deque where elements are being prepended
14950         and removed from the beginning in LIFO order, so it can be replaced with a Vector.
14951
14952         * dom/Document.cpp:
14953         (WebCore::Document::requestFullScreenForElement):
14954         (WebCore::Document::webkitCancelFullScreen):
14955         (WebCore::Document::popFullscreenElementStack):
14956         (WebCore::Document::pushFullscreenElementStack):
14957         * dom/Document.h:
14958         (WebCore::Document::webkitFullscreenElement):
14959         (Document):
14960
14961 2012-11-10  Adam Barth  <abarth@webkit.org>
14962
14963         [V8] Clean up header includes and ifdefs in V8GCController
14964         https://bugs.webkit.org/show_bug.cgi?id=101691
14965
14966         Reviewed by Kentaro Hara.
14967
14968         This file doesn't need to include all these headers anymore.
14969
14970         * bindings/v8/V8GCController.cpp:
14971         (WebCore::workingSetEstimateMBMutex):
14972         (WebCore::V8GCController::majorGCEpilogue):
14973         (WebCore::V8GCController::checkMemoryUsage):
14974
14975 2012-11-10  Joseph Pecoraro  <pecoraro@apple.com>
14976
14977         [Mac] Guard WebCore PageVisibility Symbol Export
14978         https://bugs.webkit.org/show_bug.cgi?id=101817
14979
14980         Reviewed by Andreas Kling.
14981
14982         Guard the export with the same ENABLE guards around its definition
14983         and implementation.
14984
14985         * WebCore.exp.in:
14986
14987 2012-11-10  Bruno de Oliveira Abinader  <bruno.abinader@basyskom.com>
14988
14989         [css] text-decoration:none no longer valid
14990         https://bugs.webkit.org/show_bug.cgi?id=101529
14991
14992         Reviewed by Ojan Vafai.
14993
14994         This patch fixes an issue where the 'none' value was parsed as explicitly
14995         'initial' value. However true in a sense that the initial value for the
14996         'text-decoration' property is 'none', the value itself could not be parsed as
14997         'initial'.
14998
14999         The getComputedStyle layout tests for 'text-decoration' and
15000         '-webkit-text-decoration-line' CSS properties are updated with the correct
15001         results.
15002
15003         * css/CSSParser.cpp:
15004         (WebCore::CSSParser::parseTextDecoration): When parsed, 'none' value
15005         gets its own identifier value instead of explicit initial.
15006
15007 2012-11-09  Dean Jackson  <dino@apple.com>
15008
15009         Support list of tracks in caption media controls
15010         https://bugs.webkit.org/show_bug.cgi?id=101669
15011
15012         Reviewed by Eric Carlson.
15013
15014         Attempt three of commit. The first two times caused build failures on Chromium.
15015
15016         Add some new elements to the media control shadow DOM that display the list of available
15017         tracks on an audio/video element. The UI is hidden by default everywhere but on Mac,
15018         where it is given a very basic design. At the moment only the list of available tracks
15019         are displayed; The followup bug will make the UI active: https://bugs.webkit.org/show_bug.cgi?id=101670
15020
15021         No new tests - this doesn't expose any testable surface.
15022
15023         * css/mediaControls.css: Added default rules that hide the new elements.
15024         * css/mediaControlsQuickTime.css: Specific rules that give a basic rendering of the new track list.
15025         * html/shadow/MediaControlElements.cpp:
15026         (WebCore::MediaControlElement::isShowing): Tests for the visibility of a control.
15027         (WebCore::MediaControlClosedCaptionsContainerElement::MediaControlClosedCaptionsContainerElement):
15028         (WebCore::MediaControlClosedCaptionsContainerElement::create):
15029         (WebCore::MediaControlClosedCaptionsContainerElement::shadowPseudoId):
15030         (WebCore::MediaControlToggleClosedCaptionsButtonElement::MediaControlToggleClosedCaptionsButtonElement):
15031         (WebCore::MediaControlToggleClosedCaptionsButtonElement::create): Now takes a reference to the media controls as a parameter.
15032         (WebCore::MediaControlToggleClosedCaptionsButtonElement::updateDisplayType):
15033         (WebCore::MediaControlToggleClosedCaptionsButtonElement::defaultEventHandler):
15034         (WebCore::MediaControlToggleClosedCaptionsButtonElement::shadowPseudoId):
15035         (WebCore::MediaControlClosedCaptionsTrackListElement::MediaControlClosedCaptionsTrackListElement): New element for holding a list of tracks to display.
15036         * html/shadow/MediaControlElements.h:
15037         (MediaControlElement):
15038         (MediaControlToggleClosedCaptionsButtonElement):
15039         (MediaControlClosedCaptionsContainerElement):
15040         (MediaControlClosedCaptionsTrackListElement): Examines the media element to build a shadow DOM that lists all the tracks available.
15041         * html/shadow/MediaControlRootElement.cpp:
15042         (WebCore::MediaControlRootElement::MediaControlRootElement):
15043         (WebCore::MediaControlRootElement::create): New track container and list elements created.
15044         (WebCore::MediaControlRootElement::setMediaController): Hook up the new elements to the controller..
15045         (WebCore::MediaControlRootElement::hide):
15046         (WebCore::MediaControlRootElement::makeTransparent):
15047         (WebCore::MediaControlRootElement::reset):
15048         (WebCore::MediaControlRootElement::reportedError):
15049         (WebCore::MediaControlRootElement::toggleClosedCaptionTrackList): Shows or hides the popup with the list of tracks.
15050         (WebCore):
15051         * html/shadow/MediaControlRootElement.h:
15052         (WebCore):
15053         (MediaControlRootElement):
15054         * html/shadow/MediaControlRootElementChromium.cpp:
15055         (WebCore::MediaControlRootElementChromium::initializeControls): Pass in the controls as a parameter.
15056         * html/shadow/MediaControls.h:
15057         (MediaControls):
15058         * platform/Language.cpp:
15059         (WebCore::displayNameForLanguageLocale): New function to return a human-readable name for a locale, given the identifier input.
15060         * platform/Language.h:
15061         (WebCore):
15062         * rendering/RenderMediaControls.cpp:
15063         (WebCore::RenderMediaControls::paintMediaControlsPart): New enum values into switch.
15064         * rendering/RenderMediaControlsChromium.cpp:
15065         (WebCore::RenderMediaControlsChromium::paintMediaControlsPart): New enum values into switch.
15066
15067 2012-11-09  Sheriff Bot  <webkit.review.bot@gmail.com>
15068
15069         Unreviewed, rolling out r134152.
15070         http://trac.webkit.org/changeset/134152
15071         https://bugs.webkit.org/show_bug.cgi?id=101831
15072
15073         broke chromium again (Requested by dino_ on #webkit).
15074
15075         * css/mediaControls.css:
15076         * css/mediaControlsQuickTime.css:
15077         (audio::-webkit-media-controls-toggle-closed-captions-button, video::-webkit-media-controls-toggle-closed-captions-button):
15078         (audio::-webkit-media-controls-volume-slider-mute-button, video::-webkit-media-controls-volume-slider-mute-button):
15079         * html/shadow/MediaControlElements.cpp:
15080         (WebCore::MediaControlToggleClosedCaptionsButtonElement::MediaControlToggleClosedCaptionsButtonElement):
15081         (WebCore::MediaControlToggleClosedCaptionsButtonElement::create):
15082         (WebCore::MediaControlToggleClosedCaptionsButtonElement::defaultEventHandler):
15083         (WebCore::MediaControlToggleClosedCaptionsButtonElement::updateDisplayType):
15084         (WebCore::MediaControlToggleClosedCaptionsButtonElement::shadowPseudoId):
15085         * html/shadow/MediaControlElements.h:
15086         (MediaControlElement):
15087         (MediaControlToggleClosedCaptionsButtonElement):
15088         * html/shadow/MediaControlRootElement.cpp:
15089         (WebCore::MediaControlRootElement::MediaControlRootElement):
15090         (WebCore::MediaControlRootElement::create):
15091         (WebCore::MediaControlRootElement::setMediaController):
15092         (WebCore::MediaControlRootElement::hide):
15093         (WebCore::MediaControlRootElement::makeTransparent):
15094         (WebCore::MediaControlRootElement::reset):
15095         (WebCore::MediaControlRootElement::reportedError):
15096         * html/shadow/MediaControlRootElement.h:
15097         (WebCore):
15098         (MediaControlRootElement):
15099         * html/shadow/MediaControlRootElementChromium.cpp:
15100         (WebCore::MediaControlRootElementChromium::initializeControls):
15101         * html/shadow/MediaControls.h:
15102         (MediaControls):
15103         * platform/Language.cpp:
15104         (WebCore):
15105         * platform/Language.h:
15106         (WebCore):
15107         * rendering/RenderMediaControls.cpp:
15108         (WebCore::RenderMediaControls::paintMediaControlsPart):
15109         * rendering/RenderMediaControlsChromium.cpp:
15110         (WebCore::RenderMediaControlsChromium::paintMediaControlsPart):
15111
15112 2012-11-09  Dean Jackson  <dino@apple.com>
15113
15114         Support list of tracks in caption media controls
15115         https://bugs.webkit.org/show_bug.cgi?id=101669
15116
15117         Reviewed by Eric Carlson.
15118
15119         Attempt two of commit. The first time caused a build failure on Chromium.
15120
15121         Add some new elements to the media control shadow DOM that display the list of available
15122         tracks on an audio/video element. The UI is hidden by default everywhere but on Mac,
15123         where it is given a very basic design. At the moment only the list of available tracks
15124         are displayed; The followup bug will make the UI active: https://bugs.webkit.org/show_bug.cgi?id=101670
15125
15126         No new tests - this doesn't expose any testable surface.
15127
15128         * css/mediaControls.css: Added default rules that hide the new elements.
15129         * css/mediaControlsQuickTime.css: Specific rules that give a basic rendering of the new track list.
15130         * html/shadow/MediaControlElements.cpp:
15131         (WebCore::MediaControlElement::isShowing): Tests for the visibility of a control.
15132         (WebCore::MediaControlClosedCaptionsContainerElement::MediaControlClosedCaptionsContainerElement):
15133         (WebCore::MediaControlClosedCaptionsContainerElement::create):
15134         (WebCore::MediaControlClosedCaptionsContainerElement::shadowPseudoId):
15135         (WebCore::MediaControlToggleClosedCaptionsButtonElement::MediaControlToggleClosedCaptionsButtonElement):
15136         (WebCore::MediaControlToggleClosedCaptionsButtonElement::create): Now takes a reference to the media controls as a parameter.
15137         (WebCore::MediaControlToggleClosedCaptionsButtonElement::updateDisplayType):
15138         (WebCore::MediaControlToggleClosedCaptionsButtonElement::defaultEventHandler):
15139         (WebCore::MediaControlToggleClosedCaptionsButtonElement::shadowPseudoId):
15140         (WebCore::MediaControlClosedCaptionsTrackListElement::MediaControlClosedCaptionsTrackListElement): New element for holding a list of tracks to display.
15141         * html/shadow/MediaControlElements.h:
15142         (MediaControlElement):
15143         (MediaControlToggleClosedCaptionsButtonElement):
15144         (MediaControlClosedCaptionsContainerElement):
15145         (MediaControlClosedCaptionsTrackListElement): Examines the media element to build a shadow DOM that lists all the tracks available.
15146         * html/shadow/MediaControlRootElement.cpp:
15147         (WebCore::MediaControlRootElement::MediaControlRootElement):
15148         (WebCore::MediaControlRootElement::create): New track container and list elements created.
15149         (WebCore::MediaControlRootElement::setMediaController): Hook up the new elements to the controller..
15150         (WebCore::MediaControlRootElement::hide):
15151         (WebCore::MediaControlRootElement::makeTransparent):
15152         (WebCore::MediaControlRootElement::reset):
15153         (WebCore::MediaControlRootElement::reportedError):
15154         (WebCore::MediaControlRootElement::toggleClosedCaptionTrackList): Shows or hides the popup with the list of tracks.
15155         (WebCore):
15156         * html/shadow/MediaControlRootElement.h:
15157         (WebCore):
15158         (MediaControlRootElement):
15159         * html/shadow/MediaControlRootElementChromium.cpp:
15160         (WebCore::MediaControlRootElementChromium::initializeControls): Pass in the controls as a parameter.
15161         * html/shadow/MediaControls.h:
15162         (MediaControls):
15163         * platform/Language.cpp:
15164         (WebCore::displayNameForLanguageLocale): New function to return a human-readable name for a locale, given the identifier input.
15165         * platform/Language.h:
15166         (WebCore):
15167         * rendering/RenderMediaControls.cpp:
15168         (WebCore::RenderMediaControls::paintMediaControlsPart): New enum values into switch.
15169         * rendering/RenderMediaControlsChromium.cpp:
15170         (WebCore::RenderMediaControlsChromium::paintMediaControlsPart): New enum values into switch.
15171
15172 2012-11-09  Ojan Vafai  <ojan@chromium.org>
15173
15174         Should only fire a single set of mouse events and update hover state once when scrolling is done
15175         https://bugs.webkit.org/show_bug.cgi?id=99940
15176
15177         Reviewed by Levi Weintraub.
15178
15179         -Use a DeferrableOneShotTimer instead of a Timer. By resetting when the
15180         timer is fired, we ensure the actual goal of not firing fake mouse events
15181         until the scroll is completed. This is the core part of this change.
15182         -Change our mouse event throttling to keep a running average of how long
15183         mouse events take and adjust throttling appropriately.
15184         Test: fast/scrolling/fake-mouse-event-throttling.html
15185         -Maintain a minimum throttle of 100ms.
15186
15187         * page/EventHandler.cpp:
15188         (WebCore):
15189         (WebCore::RunningAverageDurationTracker::RunningAverageDurationTracker):
15190         (WebCore::RunningAverageDurationTracker::~RunningAverageDurationTracker):
15191         Keep track of a running average instead of max. This lets us adjust throttling
15192         dynamically without punishing a page for having a single mouse event handler
15193         that takes disproportionately long.
15194         (RunningAverageDurationTracker):
15195         (WebCore::EventHandler::EventHandler):
15196         (WebCore::EventHandler::clear):
15197         (WebCore::EventHandler::mouseMoved):
15198         (WebCore::EventHandler::handleMouseMoveEvent):
15199         (WebCore::EventHandler::dispatchFakeMouseMoveEventSoon):
15200         (WebCore::EventHandler::fakeMouseMoveEventTimerFired):
15201         * page/EventHandler.h:
15202         (EventHandler):
15203         * platform/Timer.h:
15204         (WebCore::DeferrableOneShotTimer::setDelay):
15205         (WebCore::DeferrableOneShotTimer::delay):
15206         Add a way of adjusting the timer delay.
15207
15208 2012-11-09  Rick Byers  <rbyers@chromium.org>
15209
15210         Move chromium to USE(LAZY_NATIVE_CURSOR)
15211         https://bugs.webkit.org/show_bug.cgi?id=101501
15212
15213         Reviewed by Adam Barth.
15214
15215         This simplifies cursor handling in chromium and unifies it with other
15216         ports for easier code sharing and testing by moving to the
15217         USE_LAZY_CURSOR model and eliminating PlatformCursor entirely.
15218
15219         PlatformCursor adds no value in chromium since the sandboxing model
15220         requires the cursor information be marshalled to the browser process
15221         before being turned into a real OS cursor.
15222
15223         Test: fast/events/mouse-cursor.html
15224
15225         * WebCore.gypi:
15226         * platform/Cursor.h:
15227         (WebCore):
15228         * platform/chromium/CursorChromium.cpp:
15229         (WebCore::Cursor::Cursor):
15230         (WebCore::Cursor::operator=):
15231         (WebCore::Cursor::~Cursor):
15232         (WebCore::Cursor::ensurePlatformCursor):
15233         * platform/chromium/PlatformCursor.h: Removed.
15234
15235 2012-11-09  Noam Rosenthal  <noam.rosenthal@nokia.com>
15236
15237         Allow ports to decide whether an image should be directly composited
15238         https://bugs.webkit.org/show_bug.cgi?id=101827
15239
15240         Reviewed by Simon Fraser.
15241
15242         Tested by compositing/tiling/huge-layer-img.html.
15243
15244         * platform/graphics/GraphicsLayer.h:
15245         (WebCore::GraphicsLayer::shouldDirectlyCompositeImage):
15246             Allow the GraphicsLayer implementation to decide if the image can be composited.
15247
15248         * rendering/RenderLayerBacking.cpp:
15249         (WebCore::RenderLayerBacking::isDirectlyCompositedImage):
15250             Take onto account the new shouldDirectlyCompositeImage check.
15251
15252 2012-11-09  Dan Bernstein  <mitz@apple.com>
15253
15254         SimpleFontData::getCFStringAttributes sets some attributes to their default values, but shouldn’t
15255         https://bugs.webkit.org/show_bug.cgi?id=101799
15256
15257         Reviewed by Alexey Proskuryakov.
15258
15259         In some configurations, setting kCTLigatureAttributeName to its default value of 1 yields
15260         different behavior from not setting it at all. We can get the correct behavior and greatly
15261         simplify the code by not setting attributes to their default values.
15262
15263         * platform/graphics/mac/SimpleFontDataCoreText.cpp:
15264         Removed redundant #import directives and changed the remaining ones to #include.
15265         (WebCore::SimpleFontData::getCFStringAttributes): Changed to use a mutable dictionary and
15266         only add attributes that have non-default values.
15267
15268 2012-11-09  Rick Byers  <rbyers@chromium.org>
15269
15270         No tests for changing mouse cursors
15271         https://bugs.webkit.org/show_bug.cgi?id=100550
15272
15273         Reviewed by Adam Barth.
15274
15275         Add infrastructure to keep track of the last set mouse cursor,
15276         and then to query it from DumpRenderTree.
15277
15278         Test: fast/events/mouse-cursor.html
15279
15280         * WebCore.exp.in: Add Cursor copy ctor export
15281         * page/EventHandler.cpp:
15282         (WebCore::EventHandler::handleMouseMoveEvent): Keep track of last set mouse cursor
15283         * page/EventHandler.h:
15284         (WebCore::EventHandler::currentMouseCursor): New getter for last set mouse cursor
15285         * testing/Internals.cpp:
15286         (WebCore::cursorTypeToString): Helper to convert cursor type to enum
15287         (WebCore):
15288         (WebCore::Internals::getCurrentCursorInfo): New function to return a string describing the last set mouse cursor
15289         * testing/Internals.h: Declare getCurrentCursorInfo
15290         * testing/Internals.idl: Declare getCurrentCursorInfo
15291
15292 2012-11-09  Huang Dongsung  <luxtella@company100.net>
15293
15294         Coordinated Graphics: Amend CoordinatedBackingStore::paintToTextureMapper to fit its own semantic.
15295         https://bugs.webkit.org/show_bug.cgi?id=101701
15296
15297         Reviewed by Noam Rosenthal.
15298
15299         Add TiledBackingStore::rect() because CoordinatedTile needs to know
15300         m_rect of TiledBackingStore.
15301
15302         * platform/graphics/TiledBackingStore.h:
15303         (WebCore::TiledBackingStore::rect):
15304
15305 2012-11-09  Sheriff Bot  <webkit.review.bot@gmail.com>
15306
15307         Unreviewed, rolling out r134139.
15308         http://trac.webkit.org/changeset/134139
15309         https://bugs.webkit.org/show_bug.cgi?id=101823
15310
15311         breaks chromium (android) build (Requested by thorton on
15312         #webkit).
15313
15314         * css/mediaControls.css:
15315         * css/mediaControlsQuickTime.css:
15316         (audio::-webkit-media-controls-toggle-closed-captions-button, video::-webkit-media-controls-toggle-closed-captions-button):
15317         (audio::-webkit-media-controls-volume-slider-mute-button, video::-webkit-media-controls-volume-slider-mute-button):
15318         * html/shadow/MediaControlElements.cpp:
15319         (WebCore::MediaControlToggleClosedCaptionsButtonElement::MediaControlToggleClosedCaptionsButtonElement):
15320         (WebCore::MediaControlToggleClosedCaptionsButtonElement::create):
15321         (WebCore::MediaControlToggleClosedCaptionsButtonElement::defaultEventHandler):
15322         (WebCore::MediaControlToggleClosedCaptionsButtonElement::updateDisplayType):
15323         (WebCore::MediaControlToggleClosedCaptionsButtonElement::shadowPseudoId):
15324         * html/shadow/MediaControlElements.h:
15325         (MediaControlElement):
15326         (MediaControlToggleClosedCaptionsButtonElement):
15327         * html/shadow/MediaControlRootElement.cpp:
15328         (WebCore::MediaControlRootElement::MediaControlRootElement):
15329         (WebCore::MediaControlRootElement::create):
15330         (WebCore::MediaControlRootElement::setMediaController):
15331         (WebCore::MediaControlRootElement::hide):
15332         (WebCore::MediaControlRootElement::makeTransparent):
15333         (WebCore::MediaControlRootElement::reset):
15334         (WebCore::MediaControlRootElement::reportedError):
15335         * html/shadow/MediaControlRootElement.h:
15336         (WebCore):
15337         (MediaControlRootElement):
15338         * html/shadow/MediaControlRootElementChromium.cpp:
15339         (WebCore::MediaControlRootElementChromium::initializeControls):
15340         * html/shadow/MediaControls.h:
15341         (MediaControls):
15342         * platform/Language.cpp:
15343         (WebCore):
15344         * platform/Language.h:
15345         (WebCore):
15346
15347 2012-11-09  Huang Dongsung  <luxtella@company100.net>
15348
15349         [TexMap] Initialize m_compositedNativeImagePtr in GraphicsLayerTextureMapper.
15350         https://bugs.webkit.org/show_bug.cgi?id=101675
15351
15352         Reviewed by Noam Rosenthal.
15353
15354         Fix a potential bug in GraphicsLayerTextureMapper. If the member's uninitialized
15355         value equals image->nativeImageForCurrentFrame() by change, we can encounter
15356         undefined behavior.
15357
15358         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
15359         (WebCore::GraphicsLayerTextureMapper::GraphicsLayerTextureMapper):
15360         (WebCore::GraphicsLayerTextureMapper::setContentsToImage):
15361
15362 2012-11-09  Dean Jackson  <dino@apple.com>
15363
15364         Support list of tracks in caption media controls
15365         https://bugs.webkit.org/show_bug.cgi?id=101669
15366
15367         Reviewed by Eric Carlson.
15368
15369         Add some new elements to the media control shadow DOM that display the list of available
15370         tracks on an audio/video element. The UI is hidden by default everywhere but on Mac,
15371         where it is given a very basic design. At the moment only the list of available tracks
15372         are displayed; The followup bug will make the UI active: https://bugs.webkit.org/show_bug.cgi?id=101670
15373
15374         No new tests - this doesn't expose any testable surface.
15375
15376         * css/mediaControls.css: Added default rules that hide the new elements.
15377         * css/mediaControlsQuickTime.css: Specific rules that give a basic rendering of the new track list.
15378         * html/shadow/MediaControlElements.cpp:
15379         (WebCore::MediaControlElement::isShowing): Tests for the visibility of a control.
15380         (WebCore::MediaControlClosedCaptionsContainerElement::MediaControlClosedCaptionsContainerElement):
15381         (WebCore::MediaControlClosedCaptionsContainerElement::create):
15382         (WebCore::MediaControlClosedCaptionsContainerElement::shadowPseudoId):
15383         (WebCore::MediaControlToggleClosedCaptionsButtonElement::MediaControlToggleClosedCaptionsButtonElement):
15384         (WebCore::MediaControlToggleClosedCaptionsButtonElement::create): Now takes a reference to the media controls as a parameter.
15385         (WebCore::MediaControlToggleClosedCaptionsButtonElement::updateDisplayType):
15386         (WebCore::MediaControlToggleClosedCaptionsButtonElement::defaultEventHandler):
15387         (WebCore::MediaControlToggleClosedCaptionsButtonElement::shadowPseudoId):
15388         (WebCore::MediaControlClosedCaptionsTrackListElement::MediaControlClosedCaptionsTrackListElement): New element for holding a list of tracks to display.
15389         * html/shadow/MediaControlElements.h:
15390         (MediaControlElement):
15391         (MediaControlToggleClosedCaptionsButtonElement):
15392         (MediaControlClosedCaptionsContainerElement):
15393         (MediaControlClosedCaptionsTrackListElement): Examines the media element to build a shadow DOM that lists all the tracks available.
15394         * html/shadow/MediaControlRootElement.cpp:
15395         (WebCore::MediaControlRootElement::MediaControlRootElement):
15396         (WebCore::MediaControlRootElement::create): New track container and list elements created.
15397         (WebCore::MediaControlRootElement::setMediaController): Hook up the new elements to the controller..
15398         (WebCore::MediaControlRootElement::hide):
15399         (WebCore::MediaControlRootElement::makeTransparent):
15400         (WebCore::MediaControlRootElement::reset):
15401         (WebCore::MediaControlRootElement::reportedError):
15402         (WebCore::MediaControlRootElement::toggleClosedCaptionTrackList): Shows or hides the popup with the list of tracks.
15403         (WebCore):
15404         * html/shadow/MediaControlRootElement.h:
15405         (WebCore):
15406         (MediaControlRootElement):
15407         * html/shadow/MediaControlRootElementChromium.cpp:
15408         (WebCore::MediaControlRootElementChromium::initializeControls): Pass in the controls as a parameter.
15409         * html/shadow/MediaControls.h:
15410         (MediaControls):
15411         * platform/Language.cpp:
15412         (WebCore::displayNameForLanguageLocale): New function to return a human-readable name for a locale, given the identifier input.
15413         * platform/Language.h:
15414         (WebCore):
15415
15416 2012-11-09  Noel Gordon  <noel.gordon@gmail.com>
15417
15418         [chromium] Should pass fast/images/paletted-png-with-color-profile.html
15419         https://bugs.webkit.org/show_bug.cgi?id=101551
15420
15421         Reviewed by Adam Barth.
15422
15423         Support decoding color PALETTE images that have an ICC color profile.
15424
15425         Covered by fast/images/png-suite/test.html and many other fast/image tests.
15426
15427         * platform/image-decoders/png/PNGImageDecoder.cpp:
15428         (WebCore::PNGImageDecoder::headerAvailable): Move the color profile code after the
15429         transparency (tRNS) reader. Allow color PNG images: RGB, RGBA, PALLETE to be color
15430         corrected. Use the transparency count from the tRNS reader to detect the expansion
15431         of RGB and PALLETE image pixels to RGBA.
15432
15433 2012-11-09  Tien-Ren Chen  <trchen@chromium.org>
15434
15435         Correct hit-test point scaling for document.elementFromPoint
15436         https://bugs.webkit.org/show_bug.cgi?id=101798
15437
15438         Reviewed by Adam Barth.
15439
15440         The hit-test point come from user JavaScript is in the document coordinate.
15441         Convert to the frame coordinate with correct scale factor for hit test.
15442
15443         Test: fast/dom/elementFromPoint-scaled-scrolled.html
15444
15445         * dom/Document.cpp:
15446         (WebCore::nodeFromPoint):
15447
15448 2012-11-09  Alec Flett  <alecflett@chromium.org>
15449
15450         IndexedDB: Combine IDBBackingStore and IDBLevelDBBackingStore
15451         https://bugs.webkit.org/show_bug.cgi?id=101415
15452
15453         Reviewed by Tony Chang.
15454
15455         Combine abstract interface IDBBackingStore with its only
15456         implementation, IDBLevelDBBackingStore, to reduce code
15457         complexity. The legacy structure existed to support a SQLLite
15458         IDBBackingStore, but it is no longer worth the complexity to
15459         support this abstraction.
15460
15461         Changes include:
15462         1) Merging IDBLevelDBBackingStore into IDBBackingStore.
15463
15464         2) Merge together IDBBackingStore's inner classes: Cursor,
15465         Transaction, and ObjectStoreRecordIdentfier with their respective
15466         subclasses in IDBLevelDBBackingStore.
15467
15468         3) Simplifying the inner Transaction class to not be refcounted or
15469         virtualized, to allow it to be a simple concrete member of its
15470         owner, IDBTransactionBackendImpl.
15471
15472         No new tests as this is purely a refactor.
15473
15474         * Modules/indexeddb/IDBBackingStore.cpp:
15475         (WebCore::recordInternalError):
15476         (WebCore::setUpMetadata):
15477         (WebCore::IDBBackingStore::IDBBackingStore):
15478         (WebCore):
15479         (WebCore::IDBBackingStore::~IDBBackingStore):
15480         (WebCore::IDBBackingStore::open):
15481         (WebCore::IDBBackingStore::getDatabaseNames):
15482         (WebCore::IDBBackingStore::getIDBDatabaseMetaData):
15483         (WebCore::IDBBackingStore::createIDBDatabaseMetaData):
15484         (WebCore::IDBBackingStore::updateIDBDatabaseIntVersion):
15485         (WebCore::IDBBackingStore::updateIDBDatabaseMetaData):
15486         (WebCore::deleteRange):
15487         (WebCore::IDBBackingStore::deleteDatabase):
15488         (WebCore::IDBBackingStore::getObjectStores):
15489         (WebCore::setMaxObjectStoreId):
15490         (WebCore::IDBBackingStore::createObjectStore):
15491         (WebCore::IDBBackingStore::deleteObjectStore):
15492         (WebCore::IDBBackingStore::getRecord):
15493         (WebCore::IDBBackingStore::putRecord):
15494         (WebCore::IDBBackingStore::clearObjectStore):
15495         (WebCore::IDBBackingStore::deleteRecord):
15496         (WebCore::IDBBackingStore::getKeyGeneratorCurrentNumber):
15497         (WebCore::IDBBackingStore::maybeUpdateKeyGeneratorCurrentNumber):
15498         (WebCore::IDBBackingStore::keyExistsInObjectStore):
15499         (WebCore::IDBBackingStore::getIndexes):
15500         (WebCore::setMaxIndexId):
15501         (WebCore::IDBBackingStore::createIndex):
15502         (WebCore::IDBBackingStore::deleteIndex):
15503         (WebCore::IDBBackingStore::putIndexDataForRecord):
15504         (WebCore::IDBBackingStore::deleteIndexDataForRecord):
15505         (WebCore::IDBBackingStore::findKeyInIndex):
15506         (WebCore::IDBBackingStore::getPrimaryKeyViaIndex):
15507         (WebCore::IDBBackingStore::keyExistsInIndex):
15508         (WebCore::IDBBackingStore::Cursor::Cursor):
15509         (WebCore::IDBBackingStore::Cursor::firstSeek):
15510         (WebCore::IDBBackingStore::Cursor::advance):
15511         (WebCore::IDBBackingStore::Cursor::continueFunction):
15512         (WebCore::IDBBackingStore::Cursor::haveEnteredRange):
15513         (WebCore::IDBBackingStore::Cursor::isPastBounds):
15514         (WebCore::ObjectStoreKeyCursorImpl::create):
15515         (ObjectStoreKeyCursorImpl):
15516         (WebCore::ObjectStoreKeyCursorImpl::value):
15517         (WebCore::ObjectStoreKeyCursorImpl::ObjectStoreKeyCursorImpl):
15518         (WebCore::ObjectStoreKeyCursorImpl::loadCurrentRow):
15519         (WebCore::ObjectStoreCursorImpl::create):
15520         (ObjectStoreCursorImpl):
15521         (WebCore::ObjectStoreCursorImpl::value):
15522         (WebCore::ObjectStoreCursorImpl::ObjectStoreCursorImpl):
15523         (WebCore::ObjectStoreCursorImpl::loadCurrentRow):
15524         (WebCore::IndexKeyCursorImpl::create):
15525         (IndexKeyCursorImpl):
15526         (WebCore::IndexKeyCursorImpl::value):
15527         (WebCore::IndexKeyCursorImpl::primaryKey):
15528         (WebCore::IndexKeyCursorImpl::recordIdentifier):
15529         (WebCore::IndexKeyCursorImpl::IndexKeyCursorImpl):
15530         (WebCore::IndexKeyCursorImpl::loadCurrentRow):
15531         (WebCore::IndexCursorImpl::create):
15532         (IndexCursorImpl):
15533         (WebCore::IndexCursorImpl::value):
15534         (WebCore::IndexCursorImpl::primaryKey):
15535         (WebCore::IndexCursorImpl::recordIdentifier):
15536         (WebCore::IndexCursorImpl::IndexCursorImpl):
15537         (WebCore::IndexCursorImpl::loadCurrentRow):
15538         (WebCore::objectStoreCursorOptions):
15539         (WebCore::indexCursorOptions):
15540         (WebCore::IDBBackingStore::openObjectStoreCursor):
15541         (WebCore::IDBBackingStore::openObjectStoreKeyCursor):
15542         (WebCore::IDBBackingStore::openIndexKeyCursor):
15543         (WebCore::IDBBackingStore::openIndexCursor):
15544         (WebCore::IDBBackingStore::Transaction::Transaction):
15545         (WebCore::IDBBackingStore::Transaction::begin):
15546         (WebCore::IDBBackingStore::Transaction::commit):
15547         (WebCore::IDBBackingStore::Transaction::rollback):
15548         * Modules/indexeddb/IDBBackingStore.h:
15549         (WebCore):
15550         (IDBBackingStore):
15551         (RecordIdentifier):
15552         (WebCore::IDBBackingStore::RecordIdentifier::create):
15553         (WebCore::IDBBackingStore::RecordIdentifier::~RecordIdentifier):
15554         (WebCore::IDBBackingStore::RecordIdentifier::isValid):
15555         (WebCore::IDBBackingStore::RecordIdentifier::primaryKey):
15556         (WebCore::IDBBackingStore::RecordIdentifier::setPrimaryKey):
15557         (WebCore::IDBBackingStore::RecordIdentifier::version):
15558         (WebCore::IDBBackingStore::RecordIdentifier::setVersion):
15559         (WebCore::IDBBackingStore::RecordIdentifier::RecordIdentifier):
15560         (Transaction):
15561         (WebCore::IDBBackingStore::Transaction::levelDBTransactionFrom):
15562         (CursorOptions):
15563         (Cursor):
15564         (WebCore::IDBBackingStore::Cursor::Cursor):
15565         (WebCore::IDBBackingStore::Cursor::key):
15566         (WebCore::IDBBackingStore::Cursor::primaryKey):
15567         (WebCore::IDBBackingStore::Cursor::~Cursor):
15568         * Modules/indexeddb/IDBFactoryBackendImpl.cpp:
15569         (WebCore::IDBFactoryBackendImpl::openBackingStore):
15570         * Modules/indexeddb/IDBIndexBackendImpl.cpp:
15571         (WebCore::IDBIndexBackendImpl::countInternal):
15572         * Modules/indexeddb/IDBLevelDBBackingStore.h: Removed.
15573         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
15574         (WebCore::IDBObjectStoreBackendImpl::setIndexKeys):
15575         (WebCore::IDBObjectStoreBackendImpl::putInternal):
15576         (WebCore::IDBObjectStoreBackendImpl::deleteInternal):
15577         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
15578         (WebCore::IDBTransactionBackendImpl::IDBTransactionBackendImpl):
15579         (WebCore::IDBTransactionBackendImpl::abort):
15580         (WebCore::IDBTransactionBackendImpl::commit):
15581         (WebCore::IDBTransactionBackendImpl::taskTimerFired):
15582         * Modules/indexeddb/IDBTransactionBackendImpl.h:
15583         (WebCore::IDBTransactionBackendImpl::backingStoreTransaction):
15584         * WebCore.xcodeproj/project.pbxproj:
15585
15586 2012-11-09  Tien-Ren Chen  <trchen@chromium.org>
15587
15588         Correct scroll adjustment for touchEvent.clientX/clientY
15589         https://bugs.webkit.org/show_bug.cgi?id=101800
15590
15591         Reviewed by Adam Barth.
15592
15593         FrameView::scrollX/scrollY returns scroll offset in (scaled) frame coordinate.
15594         Convert to document coordinate before passing to JavaScript.
15595
15596         Test: fast/events/touch/touch-scaled-scrolled.html
15597
15598         * dom/Touch.cpp:
15599         (WebCore::contentsX):
15600         (WebCore::contentsY):
15601
15602 2012-11-09  Alexandru Chiculita  <achicu@adobe.com>
15603
15604         [Texmap][CSS Shaders] Enable CSS Shaders in TextureMapperGL
15605         https://bugs.webkit.org/show_bug.cgi?id=98990
15606
15607         Reviewed by Noam Rosenthal.
15608
15609         Added code that draws the Custom Filter in the TextureMapperGL. Also added 
15610         required code to make a depth buffer for a BitmapTextureGL.
15611
15612         Note that the code is not optimized yet, so it will always recompile the shader.
15613
15614         Test: css3/filters/custom/composited/custom-filter-blend-modes.html
15615
15616         * platform/graphics/texmap/TextureMapperGL.cpp:
15617         (WebCore::BitmapTextureGL::BitmapTextureGL):
15618         (WebCore::getPassesRequiredForFilter):
15619         (WebCore):
15620         (WebCore::TextureMapperGL::drawUsingCustomFilter):
15621         (WebCore::BitmapTextureGL::applyFilters):
15622         (WebCore::BitmapTextureGL::initializeDepthBuffer):
15623         (WebCore::BitmapTextureGL::~BitmapTextureGL):
15624         * platform/graphics/texmap/TextureMapperGL.h:
15625         (BitmapTextureGL):
15626
15627 2012-11-09  Sadrul Habib Chowdhury  <sadrul@chromium.org>
15628
15629         CustomEvent: Allow taking in a serialized value during initialization.
15630         https://bugs.webkit.org/show_bug.cgi?id=101348
15631
15632         Reviewed by Adam Barth.
15633
15634         If a CustomEvent is initialized using a serialized value, then for each access
15635         to |detail|, the value is deserialized first. This way, each world gets a different
15636         deserialization.
15637
15638         * UseV8.cmake:
15639         * WebCore.gypi:
15640         * bindings/v8/V8HiddenPropertyName.h:
15641         (WebCore):
15642         * bindings/v8/custom/V8CustomEventCustom.cpp: Copied from Source/WebCore/bindings/v8/V8HiddenPropertyName.h.
15643         (WebCore):
15644         (WebCore::V8CustomEvent::detailAccessorGetter):
15645         * dom/CustomEvent.cpp:
15646         (WebCore::CustomEvent::initCustomEvent):
15647         (WebCore):
15648         * dom/CustomEvent.h:
15649         (CustomEvent):
15650         (WebCore::CustomEvent::serializedScriptValue):
15651         * dom/CustomEvent.idl:
15652
15653 2012-11-09  Brady Eidson  <beidson@apple.com>
15654
15655         Implement WebResourceBuffer::isEmpty()
15656         https://bugs.webkit.org/show_bug.cgi?id=101805
15657
15658         Reviewed by Alexey Proskuryakov.
15659
15660         This is required to make the existing subresource loading in NetworkProcess work correctly,
15661         as there's an isEmpty() check in the WebProcess that decides whether or not to actually deliver 
15662         the data to the ResourceLoader.
15663
15664         No new tests (No change in behavior in any configuration we test.)
15665
15666         * loader/ResourceBuffer.h: Make isEmpty() virtual.
15667
15668 2012-11-09  Michael Saboff  <msaboff@apple.com>
15669
15670         HTML Attributes names and values should be created as 8 bit string where possible
15671         https://bugs.webkit.org/show_bug.cgi?id=101781
15672
15673         Reviewed by Filip Pizlo.
15674
15675         Given that almost all attribute names and values are lower case ASCII, we should try to
15676         create 8 bit strings to process them.  Creating an AtomicString already tries to make
15677         an 8 bit string, so that didn't need to change.
15678
15679         No new tests, functionality covered by existing tests.
15680
15681         * html/HTMLViewSourceDocument.cpp:
15682         (WebCore::HTMLViewSourceDocument::processTagToken):
15683         * html/parser/HTMLMetaCharsetParser.cpp:
15684         (WebCore::HTMLMetaCharsetParser::processMeta):
15685         * html/parser/HTMLPreloadScanner.cpp:
15686         (WebCore::PreloadTask::processAttributes):
15687
15688 2012-11-09  Dana Jansens  <danakj@chromium.org>
15689
15690         [chromium] Define WEBKIT_IMPLEMENTATION everywhere inside WebCore
15691         https://bugs.webkit.org/show_bug.cgi?id=101795
15692
15693         Reviewed by James Robinson.
15694
15695         * WebCore.gyp/WebCore.gyp:
15696
15697 2012-11-09  Sheriff Bot  <webkit.review.bot@gmail.com>
15698
15699         Unreviewed, rolling out r134101.
15700         http://trac.webkit.org/changeset/134101
15701         https://bugs.webkit.org/show_bug.cgi?id=101790
15702
15703         IDBDatabaseBackendTest.BackingStoreRetention failing
15704         (Requested by jsbell|gardener on #webkit).
15705
15706         * GNUmakefile.list.am:
15707         * Modules/indexeddb/IDBBackingStore.cpp:
15708         (WebCore::IDBLevelDBBackingStore::IDBLevelDBBackingStore):
15709         (WebCore::IDBLevelDBBackingStore::~IDBLevelDBBackingStore):
15710         (WebCore::IDBLevelDBBackingStore::open):
15711         (WebCore::IDBLevelDBBackingStore::getDatabaseNames):
15712         (WebCore::IDBLevelDBBackingStore::getIDBDatabaseMetaData):
15713         (WebCore::IDBLevelDBBackingStore::createIDBDatabaseMetaData):
15714         (WebCore::IDBLevelDBBackingStore::updateIDBDatabaseIntVersion):
15715         (WebCore::IDBLevelDBBackingStore::updateIDBDatabaseMetaData):
15716         (WebCore::IDBLevelDBBackingStore::deleteDatabase):
15717         (WebCore::IDBLevelDBBackingStore::getObjectStores):
15718         (WebCore::IDBLevelDBBackingStore::createObjectStore):
15719         (WebCore::IDBLevelDBBackingStore::deleteObjectStore):
15720         (WebCore::IDBLevelDBBackingStore::getRecord):
15721         (WebCore):
15722         (WebCore::IDBLevelDBBackingStore::putRecord):
15723         (WebCore::IDBLevelDBBackingStore::clearObjectStore):
15724         (WebCore::IDBLevelDBBackingStore::createInvalidRecordIdentifier):
15725         (WebCore::IDBLevelDBBackingStore::deleteRecord):
15726         (WebCore::IDBLevelDBBackingStore::getKeyGeneratorCurrentNumber):
15727         (WebCore::IDBLevelDBBackingStore::maybeUpdateKeyGeneratorCurrentNumber):
15728         (WebCore::IDBLevelDBBackingStore::keyExistsInObjectStore):
15729         (WebCore::IDBLevelDBBackingStore::getIndexes):
15730         (WebCore::IDBLevelDBBackingStore::createIndex):
15731         (WebCore::IDBLevelDBBackingStore::deleteIndex):
15732         (WebCore::IDBLevelDBBackingStore::putIndexDataForRecord):
15733         (WebCore::IDBLevelDBBackingStore::deleteIndexDataForRecord):
15734         (WebCore::IDBLevelDBBackingStore::findKeyInIndex):
15735         (WebCore::IDBLevelDBBackingStore::getPrimaryKeyViaIndex):
15736         (WebCore::IDBLevelDBBackingStore::keyExistsInIndex):
15737         (WebCore::IDBLevelDBBackingStore::openObjectStoreCursor):
15738         (WebCore::IDBLevelDBBackingStore::openObjectStoreKeyCursor):
15739         (WebCore::IDBLevelDBBackingStore::openIndexKeyCursor):
15740         (WebCore::IDBLevelDBBackingStore::openIndexCursor):
15741         (WebCore::IDBLevelDBBackingStore::createTransaction):
15742         (WebCore::IDBLevelDBBackingStore::Transaction::create):
15743         (WebCore::IDBLevelDBBackingStore::Transaction::Transaction):
15744         (WebCore::IDBLevelDBBackingStore::Transaction::begin):
15745         (WebCore::IDBLevelDBBackingStore::Transaction::commit):
15746         (WebCore::IDBLevelDBBackingStore::Transaction::rollback):
15747         (WebCore::IDBLevelDBBackingStore::backingStoreExists):
15748         * Modules/indexeddb/IDBBackingStore.h:
15749         (WebCore):
15750         (WebCore::IDBBackingStore::~IDBBackingStore):
15751         (IDBBackingStore):
15752         (RecordIdentifier):
15753         (WebCore::IDBBackingStore::Cursor::~Cursor):
15754         (WebCore::IDBBackingStore::Transaction::~Transaction):
15755         (Transaction):
15756         * Modules/indexeddb/IDBFactoryBackendImpl.cpp:
15757         (WebCore::IDBFactoryBackendImpl::openBackingStore):
15758         * Modules/indexeddb/IDBLevelDBBackingStore.h: Copied from Source/WebCore/Modules/indexeddb/IDBBackingStore.h.
15759         (WebCore):
15760         (IDBLevelDBBackingStore):
15761         (Transaction):
15762         (WebCore::IDBLevelDBBackingStore::Transaction::levelDBTransactionFrom):
15763         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
15764         (WebCore::IDBObjectStoreBackendImpl::setIndexKeys):
15765         (WebCore::IDBObjectStoreBackendImpl::putInternal):
15766         (WebCore::IDBObjectStoreBackendImpl::deleteInternal):
15767         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
15768         (WebCore::IDBTransactionBackendImpl::IDBTransactionBackendImpl):
15769         (WebCore::IDBTransactionBackendImpl::abort):
15770         (WebCore::IDBTransactionBackendImpl::commit):
15771         (WebCore::IDBTransactionBackendImpl::taskTimerFired):
15772         * Modules/indexeddb/IDBTransactionBackendImpl.h:
15773         (WebCore::IDBTransactionBackendImpl::backingStoreTransaction):
15774         * WebCore.xcodeproj/project.pbxproj:
15775
15776 2012-11-09  Erik Arvidsson  <arv@chromium.org>
15777
15778         REGRESSION (r125239): classList contains() doesn't work after element was moved from strict mode document to quirks mode document
15779         https://bugs.webkit.org/show_bug.cgi?id=101627
15780
15781         Reviewed by Alexey Proskuryakov.
15782
15783         We used to only create m_classNamesForQuirksMode in the constructor or when the class attribute
15784         was changed. If an element is moved from a standards document to a quirks mode document the
15785         m_classNamesForQuirksMode would not be up to date which lead to wrong results.
15786
15787         Now we alway check if m_classNamesForQuirksMode is up to date (in quirks mode only).
15788
15789         Test: fast/dom/Element/class-list-move-between-document-with-different-quirks-mode.html
15790
15791         * html/ClassList.cpp:
15792         (WebCore::ClassList::classNames): Create the m_classNamesForQuirksMode lazily as needed so that
15793                                           it is up to date.
15794         * html/ClassList.h:
15795
15796 2012-11-09  Alec Flett  <alecflett@chromium.org>
15797
15798         IndexedDB: Combine IDBBackingStore and IDBLevelDBBackingStore
15799         https://bugs.webkit.org/show_bug.cgi?id=101415
15800
15801         Reviewed by Tony Chang.
15802
15803         Combine abstract interface IDBBackingStore with its only
15804         implementation, IDBLevelDBBackingStore, to reduce code
15805         complexity. The legacy structure existed to support a SQLLite
15806         IDBBackingStore, but it is no longer worth the complexity to
15807         support this abstraction.
15808
15809         Changes include:
15810         1) Merging IDBLevelDBBackingStore into IDBBackingStore.
15811
15812         2) Merge together IDBBackingStore's inner classes: Cursor,
15813         Transaction, and ObjectStoreRecordIdentfier with their respective
15814         subclasses in IDBLevelDBBackingStore.
15815
15816         3) Simplifying the inner Transaction class to not be refcounted or
15817         virtualized, to allow it to be a simple concrete member of its
15818         owner, IDBTransactionBackendImpl.
15819
15820         No new tests as this is purely a refactor.
15821
15822         * Modules/indexeddb/IDBBackingStore.cpp:
15823         (WebCore::recordInternalError):
15824         (WebCore::setUpMetadata):
15825         (WebCore::IDBBackingStore::IDBBackingStore):
15826         (WebCore):
15827         (WebCore::IDBBackingStore::~IDBBackingStore):
15828         (WebCore::IDBBackingStore::open):
15829         (WebCore::IDBBackingStore::getDatabaseNames):
15830         (WebCore::IDBBackingStore::getIDBDatabaseMetaData):
15831         (WebCore::IDBBackingStore::createIDBDatabaseMetaData):
15832         (WebCore::IDBBackingStore::updateIDBDatabaseIntVersion):
15833         (WebCore::IDBBackingStore::updateIDBDatabaseMetaData):
15834         (WebCore::deleteRange):
15835         (WebCore::IDBBackingStore::deleteDatabase):
15836         (WebCore::IDBBackingStore::getObjectStores):
15837         (WebCore::setMaxObjectStoreId):
15838         (WebCore::IDBBackingStore::createObjectStore):
15839         (WebCore::IDBBackingStore::deleteObjectStore):
15840         (WebCore::IDBBackingStore::getRecord):
15841         (WebCore::IDBBackingStore::putRecord):
15842         (WebCore::IDBBackingStore::clearObjectStore):
15843         (WebCore::IDBBackingStore::deleteRecord):
15844         (WebCore::IDBBackingStore::getKeyGeneratorCurrentNumber):
15845         (WebCore::IDBBackingStore::maybeUpdateKeyGeneratorCurrentNumber):
15846         (WebCore::IDBBackingStore::keyExistsInObjectStore):
15847         (WebCore::IDBBackingStore::getIndexes):
15848         (WebCore::setMaxIndexId):
15849         (WebCore::IDBBackingStore::createIndex):
15850         (WebCore::IDBBackingStore::deleteIndex):
15851         (WebCore::IDBBackingStore::putIndexDataForRecord):
15852         (WebCore::IDBBackingStore::deleteIndexDataForRecord):
15853         (WebCore::IDBBackingStore::findKeyInIndex):
15854         (WebCore::IDBBackingStore::getPrimaryKeyViaIndex):
15855         (WebCore::IDBBackingStore::keyExistsInIndex):
15856         (WebCore::IDBBackingStore::Cursor::Cursor):
15857         (WebCore::IDBBackingStore::Cursor::firstSeek):
15858         (WebCore::IDBBackingStore::Cursor::advance):
15859         (WebCore::IDBBackingStore::Cursor::continueFunction):
15860         (WebCore::IDBBackingStore::Cursor::haveEnteredRange):
15861         (WebCore::IDBBackingStore::Cursor::isPastBounds):
15862         (WebCore::ObjectStoreKeyCursorImpl::create):
15863         (ObjectStoreKeyCursorImpl):
15864         (WebCore::ObjectStoreKeyCursorImpl::value):
15865         (WebCore::ObjectStoreKeyCursorImpl::ObjectStoreKeyCursorImpl):
15866         (WebCore::ObjectStoreKeyCursorImpl::loadCurrentRow):
15867         (WebCore::ObjectStoreCursorImpl::create):
15868         (ObjectStoreCursorImpl):
15869         (WebCore::ObjectStoreCursorImpl::value):
15870         (WebCore::ObjectStoreCursorImpl::ObjectStoreCursorImpl):
15871         (WebCore::ObjectStoreCursorImpl::loadCurrentRow):
15872         (WebCore::IndexKeyCursorImpl::create):
15873         (IndexKeyCursorImpl):
15874         (WebCore::IndexKeyCursorImpl::value):
15875         (WebCore::IndexKeyCursorImpl::primaryKey):
15876         (WebCore::IndexKeyCursorImpl::recordIdentifier):
15877         (WebCore::IndexKeyCursorImpl::IndexKeyCursorImpl):
15878         (WebCore::IndexKeyCursorImpl::loadCurrentRow):
15879         (WebCore::IndexCursorImpl::create):
15880         (IndexCursorImpl):
15881         (WebCore::IndexCursorImpl::value):
15882         (WebCore::IndexCursorImpl::primaryKey):
15883         (WebCore::IndexCursorImpl::recordIdentifier):
15884         (WebCore::IndexCursorImpl::IndexCursorImpl):
15885         (WebCore::IndexCursorImpl::loadCurrentRow):
15886         (WebCore::objectStoreCursorOptions):
15887         (WebCore::indexCursorOptions):
15888         (WebCore::IDBBackingStore::openObjectStoreCursor):
15889         (WebCore::IDBBackingStore::openObjectStoreKeyCursor):
15890         (WebCore::IDBBackingStore::openIndexKeyCursor):
15891         (WebCore::IDBBackingStore::openIndexCursor):
15892         (WebCore::IDBBackingStore::Transaction::Transaction):
15893         (WebCore::IDBBackingStore::Transaction::begin):
15894         (WebCore::IDBBackingStore::Transaction::commit):
15895         (WebCore::IDBBackingStore::Transaction::rollback):
15896         * Modules/indexeddb/IDBBackingStore.h:
15897         (WebCore):
15898         (IDBBackingStore):
15899         (RecordIdentifier):
15900         (WebCore::IDBBackingStore::RecordIdentifier::create):
15901         (WebCore::IDBBackingStore::RecordIdentifier::~RecordIdentifier):
15902         (WebCore::IDBBackingStore::RecordIdentifier::isValid):
15903         (WebCore::IDBBackingStore::RecordIdentifier::primaryKey):
15904         (WebCore::IDBBackingStore::RecordIdentifier::setPrimaryKey):
15905         (WebCore::IDBBackingStore::RecordIdentifier::version):
15906         (WebCore::IDBBackingStore::RecordIdentifier::setVersion):
15907         (WebCore::IDBBackingStore::RecordIdentifier::RecordIdentifier):
15908         (Transaction):
15909         (WebCore::IDBBackingStore::Transaction::levelDBTransactionFrom):
15910         (CursorOptions):
15911         (Cursor):
15912         (WebCore::IDBBackingStore::Cursor::Cursor):
15913         (WebCore::IDBBackingStore::Cursor::key):
15914         (WebCore::IDBBackingStore::Cursor::primaryKey):
15915         (WebCore::IDBBackingStore::Cursor::~Cursor):
15916         * Modules/indexeddb/IDBFactoryBackendImpl.cpp:
15917         (WebCore::IDBFactoryBackendImpl::openBackingStore):
15918         * Modules/indexeddb/IDBIndexBackendImpl.cpp:
15919         (WebCore::IDBIndexBackendImpl::countInternal):
15920         * Modules/indexeddb/IDBLevelDBBackingStore.h: Removed.
15921         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
15922         (WebCore::IDBObjectStoreBackendImpl::setIndexKeys):
15923         (WebCore::IDBObjectStoreBackendImpl::putInternal):
15924         (WebCore::IDBObjectStoreBackendImpl::deleteInternal):
15925         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
15926         (WebCore::IDBTransactionBackendImpl::IDBTransactionBackendImpl):
15927         (WebCore::IDBTransactionBackendImpl::abort):
15928         (WebCore::IDBTransactionBackendImpl::commit):
15929         (WebCore::IDBTransactionBackendImpl::taskTimerFired):
15930         * Modules/indexeddb/IDBTransactionBackendImpl.h:
15931         (WebCore::IDBTransactionBackendImpl::backingStoreTransaction):
15932         * WebCore.xcodeproj/project.pbxproj:
15933
15934 2012-10-28  Timothy Hatcher  <timothy@apple.com>
15935
15936         Make -webkit-canvas in CSS use the full backing store instead
15937         of always 1x when rendering.
15938
15939         https://bugs.webkit.org/show_bug.cgi?id=100611
15940
15941         Reviewed by Dean Jackson.
15942
15943         Test: fast/canvas/canvas-as-image-hidpi.html
15944
15945         * html/HTMLCanvasElement.cpp:
15946         (WebCore::HTMLCanvasElement::makePresentationCopy): Pass Unscaled to copyImage.
15947         (WebCore::HTMLCanvasElement::copiedImage): Ditto.
15948         * platform/graphics/ImageBuffer.h:
15949         * platform/graphics/cg/ImageBufferCG.cpp:
15950         (WebCore::ImageBuffer::copyImage): Added Scale parameter and use copyNativeImage for Unscaled.
15951         * platform/graphics/cairo/ImageBufferCairo.cpp:
15952         (WebCore::ImageBuffer::copyImage): Added unnamed ScaleBehavior parameter.
15953         * platform/graphics/qt/ImageBufferQt.cpp:
15954         (WebCore::ImageBuffer::copyImage): Ditto.
15955         * platform/graphics/skia/ImageBufferSkia.cpp:
15956         (WebCore::ImageBuffer::copyImage): Ditto.
15957         * platform/graphics/wince/ImageBufferWinCE.cpp:
15958         (WebCore::ImageBuffer::copyImage): Ditto.
15959         * platform/graphics/wx/ImageBufferWx.cpp:
15960         (WebCore::ImageBuffer::copyImage): Ditto.
15961
15962 2012-10-28  Timothy Hatcher  <timothy@apple.com>
15963
15964         Reset the canvas backing store pixel ratio when the buffer resizes.
15965
15966         The backing store was not being recreated using the current page pixel ratio
15967         when a resize occurred.
15968
15969         https://bugs.webkit.org/show_bug.cgi?id=100608
15970
15971         Reviewed by Darin Adler.
15972
15973         Test: fast/canvas/canvas-resize-reset-pixelRatio.html
15974
15975         * html/HTMLCanvasElement.cpp:
15976         (WebCore::HTMLCanvasElement::HTMLCanvasElement): Use targetDeviceScaleFactor.
15977         (WebCore::HTMLCanvasElement::reset): Do a clear only if the pixel ratios also
15978         match. Store the new pixel ratio in m_deviceScaleFactor.
15979         (WebCore::HTMLCanvasElement::targetDeviceScaleFactor): Added.
15980         * html/HTMLCanvasElement.h:
15981         (WebCore::HTMLCanvasElement::setSize): Return early only if the sizes and
15982         pixel ratios match.
15983
15984 2012-11-08  Ryosuke Niwa  <rniwa@webkit.org>
15985
15986         RemoveFormat command doesn't remove background color
15987         https://bugs.webkit.org/show_bug.cgi?id=101682
15988
15989         Reviewed by Tony Chang.
15990
15991         Fixed the bug by removing all non-transparent background-color properties.
15992
15993         Test: editing/execCommand/remove-format-background-color.html
15994
15995         * editing/RemoveFormatCommand.cpp:
15996         (WebCore::RemoveFormatCommand::doApply):
15997
15998 2012-11-09  Alec Flett  <alecflett@chromium.org>
15999
16000         IndexedDB: switch frontend to use int64_t-based references
16001         https://bugs.webkit.org/show_bug.cgi?id=100426
16002
16003         Reviewed by Tony Chang.
16004
16005         Remove String-based objectStore/index references, obsoleted by
16006         https://bugs.webkit.org/show_bug.cgi?id=100425.
16007
16008         No new tests as this is the second half of a refactor.
16009
16010         * Modules/indexeddb/IDBCallbacks.h:
16011         * Modules/indexeddb/IDBDatabase.cpp:
16012         (WebCore::IDBDatabase::deleteObjectStore):
16013         (WebCore::IDBDatabase::transaction):
16014         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
16015         (WebCore::IDBDatabaseBackendImpl::setVersion):
16016         (WebCore::IDBDatabaseBackendImpl::transaction):
16017         (WebCore::IDBDatabaseBackendImpl::runIntVersionChangeTransaction):
16018         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
16019         (IDBDatabaseBackendImpl):
16020         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
16021         (IDBDatabaseBackendInterface):
16022         * Modules/indexeddb/IDBMetadata.h:
16023         (WebCore::IDBObjectStoreMetadata::findIndex):
16024         (IDBObjectStoreMetadata):
16025         (WebCore::IDBObjectStoreMetadata::containsIndex):
16026         * Modules/indexeddb/IDBObjectStore.cpp:
16027         (WebCore::IDBObjectStore::put):
16028         (WebCore):
16029         (WebCore::IDBObjectStore::index):
16030         (WebCore::IDBObjectStore::deleteIndex):
16031         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
16032         (WebCore::IDBObjectStoreBackendImpl::put):
16033         (WebCore):
16034         * Modules/indexeddb/IDBObjectStoreBackendImpl.h:
16035         (IDBObjectStoreBackendImpl):
16036         * Modules/indexeddb/IDBObjectStoreBackendInterface.h:
16037         * inspector/Inspector-1.0.json:
16038         * inspector/Inspector.json:
16039         * inspector/InspectorIndexedDBAgent.cpp:
16040         (WebCore):
16041         (WebCore::InspectorIndexedDBAgent::requestData):
16042         * inspector/InspectorIndexedDBAgent.h:
16043         (InspectorIndexedDBAgent):
16044
16045 2012-11-09  Mario Sanchez Prada  <mario@webkit.org>
16046
16047         [GTK] Isolate the GTK/Gail/Pango specific code in accessibility/gtk
16048         https://bugs.webkit.org/show_bug.cgi?id=101727
16049
16050         Reviewed by Chris Fleizach.
16051
16052         Added conditional compilation checks for GTK+ specific
16053         accessibility code, to pave the way for sharing this
16054         implementation with other ports (e.g WebKitEFL).
16055
16056         * accessibility/gtk/WebKitAccessibleInterfaceText.cpp:
16057         (webkitAccessibleTextGetTextAfterOffset): Added conditional
16058         compilation checks, only implementing it in GTK so far.
16059         (webkitAccessibleTextGetTextAtOffset): Ditto.
16060         (webkitAccessibleTextGetTextBeforeOffset): Ditto.
16061         * accessibility/gtk/WebKitAccessibleWrapperAtk.cpp:
16062         (atkParentOfRootObject): Added conditional compilation checks,
16063         only implementing in GTK the part of getting the accessible object
16064         for the root object.
16065         (webkitAccessibleGetParent): Updated comments.
16066         (webkitAccessibleGetNChildren): Ditto.
16067         (webkitAccessibleRefChild): Ditto.
16068         (webkitAccessibleGetIndexInParent): Ditto.
16069         (webkitAccessibleGetAttributes): Only set the 'toolkit' attribute
16070         for GTK. Other ports might be interested in this too.
16071         (setAtkStateSetFromCoreObject): Updated comments.
16072
16073 2012-11-09  Tommy Widenflycht  <tommyw@google.com>
16074
16075         MediaStream API: Don't trigger any object deletion during RTCPeerConnection::stop
16076         https://bugs.webkit.org/show_bug.cgi?id=101586
16077
16078         Reviewed by Adam Barth.
16079
16080         Stop calling stop on the RTCPeerConnectionHandler, and don't delete it, when
16081         ActiveDOMObject::stop is called on RTCPeerConnection. Due to the async nature of the new
16082         API some WebCore objects might be cleaned away which is not allowed at this stage.
16083
16084         This behaviour is not possible to test unfortunately in webkit.
16085
16086         * Modules/mediastream/RTCPeerConnection.cpp:
16087         (WebCore::RTCPeerConnection::stop):
16088
16089 2012-11-09  Joshua Bell  <jsbell@chromium.org>
16090
16091         [Chromium] Unreviewed gardening. Fix chromium-win builds following r134082
16092
16093         * WebCore.gypi:
16094
16095 2012-11-09  Dan Carney  <dcarney@google.com>
16096
16097         [V8] Remove ScriptController::windowShell()
16098         https://bugs.webkit.org/show_bug.cgi?id=100235
16099
16100         Reviewed by Adam Barth.
16101
16102         Refactored windowShell(DOMWrapperWorld*) and
16103         existingWindowShell(DOMWrapperWorld*) to be like JSC.
16104
16105         No new tests. No change in functionality.
16106
16107         * bindings/scripts/CodeGeneratorV8.pm:
16108         (GenerateToV8Converters):
16109         * bindings/v8/DOMWrapperWorld.cpp:
16110         (WebCore::isolatedWorldMap):
16111         (WebCore::DOMWrapperWorld::getAllWorlds):
16112         (WebCore):
16113         * bindings/v8/DOMWrapperWorld.h:
16114         (DOMWrapperWorld):
16115         * bindings/v8/PageScriptDebugServer.cpp:
16116         (WebCore::PageScriptDebugServer::addListener):
16117         * bindings/v8/ScriptController.cpp:
16118         (WebCore::ScriptController::~ScriptController):
16119         (WebCore::ScriptController::clearForOutOfMemory):
16120         (WebCore):
16121         (WebCore::ScriptController::clearForClose):
16122         (WebCore::ScriptController::updateSecurityOrigin):
16123         (WebCore::ScriptController::initializeMainWorld): Returns true if the main world was initialized.
16124         (WebCore::existingWindowShellWorkaroundWorld):
16125         (WebCore::ScriptController::existingWindowShell):
16126         (WebCore::ScriptController::windowShell):
16127         (WebCore::ScriptController::evaluateInIsolatedWorld):
16128         (WebCore::ScriptController::currentWorldContext):
16129         (WebCore::ScriptController::mainWorldContext):
16130         (WebCore::ScriptController::haveInterpreter):
16131         (WebCore::ScriptController::enableEval):
16132         (WebCore::ScriptController::disableEval):
16133         (WebCore::ScriptController::clearWindowShell):
16134         (WebCore::ScriptController::setContextDebugId):
16135         (WebCore::ScriptController::updateDocument):
16136         (WebCore::ScriptController::namedItemAdded):
16137         (WebCore::ScriptController::namedItemRemoved):
16138         * bindings/v8/ScriptController.h:
16139         (ScriptController):
16140         (WebCore::ScriptController::getAllWorlds):
16141         * bindings/v8/V8Binding.cpp:
16142         (WebCore::perContextDataForCurrentWorld):
16143         (WebCore::handleOutOfMemory):
16144         * bindings/v8/V8DOMWindowShell.cpp:
16145         (WebCore::V8DOMWindowShell::initializeIfNeeded):
16146         (WebCore::V8DOMWindowShell::updateDocument):
16147         (WebCore::V8DOMWindowShell::namedItemAdded):
16148         (WebCore::V8DOMWindowShell::namedItemRemoved):
16149         * bindings/v8/V8DOMWindowShell.h:
16150         (WebCore::V8DOMWindowShell::isContextInitialized):
16151         (WebCore::V8DOMWindowShell::isGlobalInitialized):
16152         * bindings/v8/custom/V8DocumentCustom.cpp:
16153         (WebCore::toV8):
16154         * bindings/v8/custom/V8HTMLDocumentCustom.cpp:
16155         (WebCore::toV8):
16156         * bindings/v8/custom/V8SVGDocumentCustom.cpp:
16157         (WebCore::toV8):
16158
16159 2012-11-09  Adam Barth  <abarth@webkit.org>
16160
16161         [V8] Remove a level of indirection in DOMDataStore
16162         https://bugs.webkit.org/show_bug.cgi?id=101690
16163
16164         Reviewed by Kentaro Hara.
16165
16166         There is no longer any reason for the DOMDataStore to hold the wrapper
16167         map via a pointer. It can just hold the wrapper map directly, saving a
16168         level of indirection. I doubt this has any measurable performance gain.
16169
16170         * bindings/v8/DOMDataStore.cpp:
16171         (WebCore::DOMDataStore::DOMDataStore):
16172         (WebCore::DOMDataStore::~DOMDataStore):
16173         (WebCore::DOMDataStore::reportMemoryUsage):
16174         * bindings/v8/DOMDataStore.h:
16175         (WebCore::DOMDataStore::get):
16176         (WebCore::DOMDataStore::set):
16177         (DOMDataStore):
16178
16179 2012-11-09  Mihnea Ovidenie  <mihnea@adobe.com>
16180
16181         [CSSRegions] Region styling properties are not filtered correctly
16182         https://bugs.webkit.org/show_bug.cgi?id=101768
16183
16184         Reviewed by Andreas Kling.
16185
16186         Region styling allows only a handful of css properties. There is a mechanism in place,
16187         in StyleResolver::isValidRegionStyleProperty that filters the supported region style properties.
16188         In order to be effective, this mechanism relies on RuleData::m_isInRegionRule being set correctly.
16189         This patch makes sure that the flag RuleData::m_isInRegionRule is set properly in RuleData constructor.
16190
16191         Test: fast/regions/region-style-not-supported-properties.html
16192
16193         * css/RuleSet.cpp:
16194         (WebCore::RuleData::RuleData):
16195
16196 2012-11-09  Tommy Widenflycht  <tommyw@google.com>
16197
16198         MediaStream API: Deleting all files relating to the deprecated PeerConnection00
16199         https://bugs.webkit.org/show_bug.cgi?id=101730
16200
16201         Reviewed by Adam Barth.
16202
16203         Since RTCPeerConenction has superseeded PeerConnection00 this patch removes all
16204         files relating to the old API.
16205
16206         No testing needed, the remaining tests makes sure that nothing else breaks.
16207
16208         * CMakeLists.txt:
16209         * GNUmakefile.list.am:
16210         * Modules/mediastream/DOMWindowMediaStream.idl:
16211         * Modules/mediastream/IceCallback.h: Removed.
16212         * Modules/mediastream/IceCallback.idl: Removed.
16213         * Modules/mediastream/IceCandidate.cpp: Removed.
16214         * Modules/mediastream/IceCandidate.h: Removed.
16215         * Modules/mediastream/IceCandidate.idl: Removed.
16216         * Modules/mediastream/PeerConnection00.cpp: Removed.
16217         * Modules/mediastream/PeerConnection00.h: Removed.
16218         * Modules/mediastream/PeerConnection00.idl: Removed.
16219         * Modules/mediastream/SessionDescription.cpp: Removed.
16220         * Modules/mediastream/SessionDescription.h: Removed.
16221         * Modules/mediastream/SessionDescription.idl: Removed.
16222         * WebCore.gypi:
16223         * bindings/generic/RuntimeEnabledFeatures.cpp:
16224         (WebCore):
16225         * bindings/generic/RuntimeEnabledFeatures.h:
16226         (RuntimeEnabledFeatures):
16227         * dom/EventTargetFactory.in:
16228         * platform/chromium/support/WebICECandidateDescriptor.cpp: Removed.
16229         * platform/chromium/support/WebICEOptions.cpp: Removed.
16230         * platform/chromium/support/WebMediaHints.cpp: Removed.
16231         * platform/mediastream/IceCandidateDescriptor.cpp: Removed.
16232         * platform/mediastream/IceCandidateDescriptor.h: Removed.
16233         * platform/mediastream/IceOptions.cpp: Removed.
16234         * platform/mediastream/IceOptions.h: Removed.
16235         * platform/mediastream/MediaHints.cpp: Removed.
16236         * platform/mediastream/MediaHints.h: Removed.
16237         * platform/mediastream/MediaStreamCenter.h:
16238         (WebCore):
16239         (MediaStreamCenter):
16240         * platform/mediastream/PeerConnection00Handler.cpp: Removed.
16241         * platform/mediastream/PeerConnection00Handler.h: Removed.
16242         * platform/mediastream/PeerConnection00HandlerClient.h: Removed.
16243         * platform/mediastream/SessionDescriptionDescriptor.cpp: Removed.
16244         * platform/mediastream/SessionDescriptionDescriptor.h: Removed.
16245         * platform/mediastream/blackberry/MediaStreamCenterBlackBerry.cpp:
16246         * platform/mediastream/blackberry/MediaStreamCenterBlackBerry.h:
16247         (WebCore):
16248         (MediaStreamCenterBlackBerry):
16249         * platform/mediastream/chromium/MediaStreamCenterChromium.cpp:
16250         * platform/mediastream/chromium/MediaStreamCenterChromium.h:
16251         (WebCore):
16252         (MediaStreamCenterChromium):
16253         * platform/mediastream/chromium/PeerConnection00Handler.cpp: Removed.
16254         * platform/mediastream/chromium/PeerConnection00HandlerInternal.cpp: Removed.
16255         * platform/mediastream/chromium/PeerConnection00HandlerInternal.h: Removed.
16256         * platform/mediastream/gstreamer/MediaStreamCenterGStreamer.cpp:
16257         * platform/mediastream/gstreamer/MediaStreamCenterGStreamer.h:
16258         (WebCore):
16259         (MediaStreamCenterGStreamer):
16260
16261 2012-11-09  Jer Noble  <jer.noble@apple.com>
16262
16263         Plugin diagnostic logging should send plugin file basename instead of MIME type.
16264         https://bugs.webkit.org/show_bug.cgi?id=101679
16265
16266         Reviewed by Eric Carlson.
16267
16268         Log the basename of the plugin file rather than the mime type so as to more
16269         accurately log which plugin was used to handle the request.
16270
16271         * loader/SubframeLoader.cpp:
16272         (WebCore::logPluginRequest): Log the plugin 'file' field, if present.
16273         * plugins/PluginData.cpp:
16274         (WebCore::PluginData::pluginInfoForMimeType): Factored out from pluginNameForMimeType.
16275         (WebCore::PluginData::pluginNameForMimeType): Use pluginInfoForMimeType to retrieve name field.
16276         (WebCore::PluginData::pluginFileForMimeType): Use pluginInfoForMimeType to retrieve file field.
16277         * plugins/PluginData.h:
16278
16279 2012-11-09  Alexey Proskuryakov  <ap@apple.com>
16280
16281         CookieJar uses Document class, which is a layering violation
16282         https://bugs.webkit.org/show_bug.cgi?id=101621
16283
16284         Reviewed by Brady Eidson.
16285
16286         Split CookieJar in two parts, one that takes a Document, and another that is a pure
16287         platform one, using NetworkingContext to access the correct platform storage.
16288
16289         * GNUmakefile.list.am:
16290         * PlatformBlackBerry.cmake:
16291         * Target.pri:
16292         * WebCore.gypi:
16293         * WebCore.gyp/WebCore.gyp:
16294         * WebCore.vcproj/WebCore.vcproj:
16295         * WebCore.xcodeproj/project.pbxproj:
16296         Updated.
16297
16298         * loader/CookieJar.cpp: Added.
16299         (WebCore::networkingContext):
16300         (WebCore::cookies):
16301         (WebCore::setCookies):
16302         (WebCore::cookiesEnabled):
16303         (WebCore::cookieRequestHeaderFieldValue):
16304         (WebCore::getRawCookies):
16305         (WebCore::deleteCookie):
16306         (WebCore::getHostnamesWithCookies):
16307         (WebCore::deleteCookiesForHostname):
16308         (WebCore::deleteAllCookies):
16309         * loader/CookieJar.h: Copied from Source/WebCore/platform/CookieJar.h.
16310         This is an adaptor for pure platform implementations. Clients continue to use the
16311         old interface unchanged.
16312
16313         * platform/blackberry/CookieJarBlackBerry.cpp: Removed.
16314         * loader/blackberry/CookieJarBlackBerry.cpp: Copied from Source/WebCore/platform/blackberry/CookieJarBlackBerry.cpp.
16315         * platform/network/chromium/CookieJarChromium.cpp: Removed.
16316         * loader/chromium/CookieJarChromium.cpp: Copied from Source/WebCore/platform/network/chromium/CookieJarChromium.cpp.
16317         These platforms do not have a pure platform implementation yet, so they just keep
16318         to use original implementations. Since the code is not in platform/ any more, the
16319         violation is resolved for Chromium and Blackberry, too.
16320
16321         * platform/CookieJar.h: Removed.
16322         * platform/network/PlatformCookieJar.h: Copied from Source/WebCore/platform/CookieJar.h.
16323         The platform interface is now more uniform - all functions take a NetworkingContext
16324         instead of hardcoding which cookie storage to use in some cases.
16325         Renamed functions that are only useful for document.cookie implementation to look
16326         less generic.
16327
16328         * platform/mac/CookieJar.mm: Removed.
16329         * platform/network/mac/CookieJarMac.mm: Copied from Source/WebCore/platform/mac/CookieJar.mm.
16330         (WebCore::cookiesForDOM): This now takes a context instead of Document, and also
16331         takes a firstParty URL (unused on Mac, but used on some other platforms).
16332         (WebCore::cookieRequestHeaderFieldValue): Get cookie storage from context (and
16333         use shared one if context is null).
16334         (WebCore::setCookiesFromDOM): Ditto.
16335         (WebCore::cookiesEnabled): Ditto.
16336         (WebCore::getRawCookies): Ditto.
16337         (WebCore::deleteCookie): Ditto.
16338         (WebCore::getHostnamesWithCookies): Ditto. This used to only support default storage,
16339         but its cleaner to have a uniform interface.
16340         (WebCore::deleteCookiesForHostname): Ditto.
16341         (WebCore::deleteAllCookies): Ditto.
16342
16343         * platform/network/cf/CookieJarCFNet.cpp:
16344         Same changes as on Mac.
16345
16346         * platform/network/curl/CookieJarCurl.cpp:
16347         Updated for new interface. Implementation is largely a dummy one.
16348
16349         * platform/qt/CookieJarQt.h: Removed.
16350         * platform/network/qt/CookieJarQt.h: Copied from Source/WebCore/platform/qt/CookieJarQt.h.
16351         Moved to a common location, most cookie files were in network/ already.
16352
16353         * platform/qt/CookieJarQt.cpp: Removed.
16354         * platform/network/qt/CookieJarQt.cpp: Copied from Source/WebCore/platform/qt/CookieJarQt.cpp.
16355         (WebCore::setCookiesFromDOM): Use context's or shared cooke jar as appropriate.
16356         (WebCore::cookiesForDOM): Ditto.
16357         (WebCore::cookieRequestHeaderFieldValue): Ditto.
16358         (WebCore::cookiesEnabled): Ditto.
16359         (WebCore::getRawCookies): Ditto.
16360         (WebCore::deleteCookie): Ditto.
16361         (WebCore::getHostnamesWithCookies): Back-end implementation can only handle shared
16362         jar here, assert that argument does not request another one.
16363         (WebCore::deleteCookiesForHostname): Ditto.
16364         (WebCore::deleteAllCookies): Ditto.
16365
16366         * platform/network/soup/CookieJarSoup.cpp:
16367         (WebCore::cookieJarForContext):
16368         (WebCore::setCookiesFromDOM):
16369         (WebCore::cookiesForContext):
16370         (WebCore::cookiesForDOM):
16371         (WebCore::cookieRequestHeaderFieldValue):
16372         (WebCore::cookiesEnabled):
16373         (WebCore::getRawCookies):
16374         (WebCore::deleteCookie):
16375         (WebCore::getHostnamesWithCookies):
16376         (WebCore::deleteCookiesForHostname):
16377         (WebCore::deleteAllCookies):
16378         Updated for new function signatures, and use the same cross-platform logic for
16379         choosing a cookie jar.
16380
16381         * platform/network/soup/CookieJarSoup.h: Don't include unnecessary CooieJar.h.
16382         
16383         * platform/network/win/CookieJarWin.cpp:
16384         (WebCore::setCookiesFromDOM):
16385         (WebCore::cookiesForDOM):
16386         (WebCore::cookieRequestHeaderFieldValue):
16387         (WebCore::cookiesEnabled):
16388         (WebCore::getRawCookies):
16389         (WebCore::deleteCookie):
16390         (WebCore::getHostnamesWithCookies):
16391         (WebCore::deleteCookiesForHostname):
16392         (WebCore::deleteAllCookies):
16393         Updated for new function signatures.
16394
16395 2012-11-09  Bruno de Oliveira Abinader  <bruno.abinader@basyskom.com>
16396
16397         [css] Text decoration's "blink" not valid when CSS3_TEXT is enabled
16398         https://bugs.webkit.org/show_bug.cgi?id=101750
16399
16400         Reviewed by Ojan Vafai.
16401
16402         This patch fixes an issue regarding "blink" value, which is valid for CSS 2.1
16403         "text-decoration" property, but recently have its parser function modified by
16404         the addition of CSS3 "-webkit-text-decoration-line" property.
16405
16406         The 'fast/css/getComputedStyle/getComputedStyle-text-decoration.html'
16407         layout test is updated with all possible value combinations.
16408
16409         * css/CSSParser.cpp:
16410         (WebCore::CSSParser::parseTextDecoration): Added 'blink' value to list
16411         if accepted.
16412
16413 2012-11-09  Xan Lopez  <xlopez@igalia.com>
16414
16415         [GTK] Do not use 'ls' to list IDL files in EXTRA_DIST
16416         https://bugs.webkit.org/show_bug.cgi?id=101581
16417
16418         Reviewed by Martin Robinson.
16419
16420         Use normal GNU Make wildcards instead of 'ls' to list files in
16421         EXTRA_DIST, it's safer and more straightforward.
16422
16423         * GNUmakefile.am: ditto.
16424
16425 2012-11-09  Charles Wei  <charles.wei@torchmobile.com.cn>
16426
16427         Need to clear exception in JSDictionary that might have been caused by previous operation.
16428         https://bugs.webkit.org/show_bug.cgi?id=96614
16429
16430         Reviewed by George Staikos.
16431
16432         IndexedDB IDBDatabase::createObjectStore supports both String type of KeyPath and
16433         String Array type of KeyPath. It will first try to get the keyPath as a String Array,
16434         if fails, it will try to get KeyPath as a String, from the Dictionary. The first get
16435         will leave the internal ExecState of Dictionary in exception state. We need to clear
16436         the exception state before the 2nd query, otherwise the second query will also fail.
16437
16438         No new tests. The existing test case LayoutTests/storage/indexeddb/tutorial.html should
16439         now work with this patch.
16440         * bindings/js/JSDictionary.cpp:
16441         (WebCore::JSDictionary::getWithUndefinedOrNullCheck):
16442
16443 2012-11-09  Keishi Hattori  <keishi@webkit.org>
16444
16445         Month/week picker should submit month/week string
16446         https://bugs.webkit.org/show_bug.cgi?id=101744
16447
16448         Reviewed by Kent Tamura.
16449
16450         Month/week picker should submit month/week string and not yyyy-mm-dd.
16451
16452         No new tests. Test will be added in Bug 101555 and Bug 101556.
16453
16454         * Resources/pagepopups/calendarPicker.js:
16455         (DaysTable.prototype._handleDayClick):
16456
16457 2012-11-07  Pavel Feldman  <pfeldman@chromium.org>
16458
16459         Web Inspector: wrong output for empty object {}
16460         https://bugs.webkit.org/show_bug.cgi?id=101356
16461
16462         Reviewed by Vsevolod Vlasov.
16463
16464         Changed preview formatting to iterate over enumerable properties only + visit the prototypes.
16465
16466         * inspector/InjectedScriptSource.js:
16467         (.):
16468         * inspector/front-end/ConsoleMessage.js:
16469         (WebInspector.ConsoleMessageImpl.prototype._appendObjectPreview):
16470
16471 2012-11-09  Keishi Hattori  <keishi@webkit.org>
16472
16473         Fix annotations in page popup files
16474         https://bugs.webkit.org/show_bug.cgi?id=101736
16475
16476         Reviewed by Kent Tamura.
16477
16478         Add @constructor where needed. Replacing /* with /** for annotations.
16479
16480         No new tests. No behavior change.
16481
16482         * Resources/pagepopups/calendarPicker.js:
16483         * Resources/pagepopups/pickerCommon.js:
16484         * Resources/pagepopups/suggestionPicker.js:
16485
16486 2012-11-09  Huang Dongsung  <luxtella@company100.net>
16487
16488         Coordinated Graphics: Remove a backing store of GraphicsLayer when the layer is far from the viewport.
16489         https://bugs.webkit.org/show_bug.cgi?id=101656
16490
16491         Reviewed by Kenneth Rohde Christiansen.
16492
16493         TiledBackingStore computes cover and keep rects to create, keep or remove tiles
16494         smartly, but currently TiledBackingStore expects a contents rect is big enough
16495         to cover the visibleRect. However, when CoordinatedGraphicsLayer uses TBS, it
16496         is usually wrong expectation.
16497
16498         We must compute cover and keep rects using the visibleRect, instead of
16499         the rect intersecting the visibleRect with m_rect, because TBS can be
16500         used as a backing store of GraphicsLayer and the visible rect usually
16501         does not intersect with m_rect.
16502         In the below case, the intersecting rect is an empty.
16503
16504          +---------------+
16505          |               |
16506          |   m_rect      |
16507          |       +-------|-----------------------+
16508          |       | HERE  |  cover or keep        |
16509          +---------------+      rect             |
16510                  |         +---------+           |
16511                  |         | visible |           |
16512                  |         |  rect   |           |
16513                  |         +---------+           |
16514                  |                               |
16515                  |                               |
16516                  +-------------------------------+
16517
16518         We must create or keep the tiles in the HERE region. Currently in the
16519         case, we do not create or keep tiles on the HERE region. Moreover, in
16520         the case, we early return, which means we don't remove any tiles. It
16521         causes to waste heap and video memory.
16522
16523         This patch changes TiledBackingStore to manage tiles smartly for
16524         Coordinated Graphics.
16525
16526         Changing cache policy is not testable in layout tests.
16527
16528         * platform/graphics/TiledBackingStore.cpp:
16529         (WebCore::TiledBackingStore::visibleRect):
16530         (WebCore::TiledBackingStore::visibleAreaIsCovered):
16531         (WebCore::TiledBackingStore::createTiles):
16532         (WebCore::TiledBackingStore::adjustForContentsRect):
16533         (WebCore::TiledBackingStore::removeAllNonVisibleTiles):
16534         * platform/graphics/TiledBackingStore.h:
16535         (TiledBackingStore):
16536
16537 2012-11-09  Keishi Hattori  <keishi@webkit.org>
16538
16539         Fix undefined variable in Week constructor for calendar picker
16540         https://bugs.webkit.org/show_bug.cgi?id=101734
16541
16542         Reviewed by Kent Tamura.
16543
16544         Closer compiler found an undefined variable in the Week constructor.
16545
16546         No new tests. This code isn't used.
16547
16548         * Resources/pagepopups/calendarPicker.js:
16549         (Week): Used wrong variable name.
16550
16551 2012-11-09  Pavel Feldman  <pfeldman@chromium.org>
16552
16553         Web Inspector: render canvas log as a grid.
16554         https://bugs.webkit.org/show_bug.cgi?id=101732
16555
16556         Reviewed by Vsevolod Vlasov.
16557
16558         * English.lproj/localizedStrings.js:
16559         * inspector/front-end/CanvasProfileView.js:
16560         (WebInspector.CanvasProfileView):
16561         (WebInspector.CanvasProfileView.prototype._onSelectTraceLog):
16562         (WebInspector.CanvasProfileView.prototype._replayTraceLog.didReplayTraceLog):
16563         (WebInspector.CanvasProfileView.prototype._replayTraceLog):
16564         (WebInspector.CanvasProfileHeader.prototype.traceLogId):
16565         (WebInspector.CanvasLogGrid):
16566         (WebInspector.CanvasLogGrid.prototype._didReceiveTraceLog):
16567         (WebInspector.CanvasLogGrid.prototype._createCallNode):
16568         * inspector/front-end/DataGrid.js:
16569         (WebInspector.DataGridNode.prototype.createCell):
16570         * inspector/front-end/canvasProfiler.css:
16571         (#canvas-replay-image-container):
16572
16573 2012-11-09  Allan Sandfeld Jensen  <allan.jensen@digia.com>
16574
16575         Regression(r107593) Crash in ContextMenuController::addInspectElementItem()
16576         https://bugs.webkit.org/show_bug.cgi?id=101595
16577
16578         Reviewed by Simon Hausmann.
16579
16580         If the contextMenu is a null pointer treat it as empty, appendItem will later
16581         create it if necessary.
16582
16583         * page/ContextMenuController.cpp:
16584         (WebCore::ContextMenuController::addInspectElementItem):
16585
16586 2012-11-09  Christophe Dumez  <christophe.dumez@intel.com>
16587
16588         [EFL][WK2] Add support for custom cursors
16589         https://bugs.webkit.org/show_bug.cgi?id=101723
16590
16591         Reviewed by Kenneth Rohde Christiansen.
16592
16593         Add getEvasObject() virtual method to Image class and
16594         provide implementation for BitmapImage.
16595
16596         No new tests, no behavior change.
16597
16598         * platform/efl/CursorEfl.cpp:
16599         (WebCore::cursorString):
16600         * platform/graphics/BitmapImage.h:
16601         (BitmapImage):
16602         * platform/graphics/Image.h:
16603         (Image):
16604         (WebCore::Image::getEvasObject):
16605         * platform/graphics/efl/ImageEfl.cpp:
16606         (WebCore::BitmapImage::getEvasObject):
16607         (WebCore):
16608
16609 2012-11-09  Adam Barth  <abarth@webkit.org>
16610
16611         IndexedDB should use mostly ScriptWrappable DOM objects
16612         https://bugs.webkit.org/show_bug.cgi?id=101694
16613
16614         Reviewed by Kentaro Hara.
16615
16616         These object always have JavaScript wrappers, so we should store the
16617         wrappers inline to use less memory and be faster.
16618
16619         * Modules/indexeddb/IDBAny.h:
16620         * Modules/indexeddb/IDBCursor.h:
16621         * Modules/indexeddb/IDBDatabase.h:
16622         * Modules/indexeddb/IDBFactory.h:
16623         * Modules/indexeddb/IDBIndex.h:
16624         * Modules/indexeddb/IDBKey.h:
16625         * Modules/indexeddb/IDBKeyRange.h:
16626         * Modules/indexeddb/IDBObjectStore.h:
16627         * Modules/indexeddb/IDBRequest.h:
16628         * Modules/indexeddb/IDBTransaction.h:
16629
16630 2012-11-09  Vsevolod Vlasov  <vsevik@chromium.org>
16631
16632         Web Inspector: Add meaningful error message when request content was evicted from inspector cache.
16633         https://bugs.webkit.org/show_bug.cgi?id=101578
16634
16635         Reviewed by Yury Semikhatsky.
16636
16637         Added specific error message when request content was evicted from inspector cache.
16638         Replaced purge with evict in fields/methods names.
16639
16640         * inspector/InspectorResourceAgent.cpp:
16641         (WebCore::InspectorResourceAgent::getResponseBody):
16642         * inspector/NetworkResourcesData.cpp:
16643         (WebCore::NetworkResourcesData::ResourceData::ResourceData):
16644         (WebCore::NetworkResourcesData::ResourceData::evictContent):
16645         (WebCore::NetworkResourcesData::setResourceContent):
16646         (WebCore::NetworkResourcesData::maybeAddResourceData):
16647         (WebCore::NetworkResourcesData::maybeDecodeDataToContent):
16648         (WebCore::NetworkResourcesData::ensureNoDataForRequestId):
16649         (WebCore::NetworkResourcesData::ensureFreeSpace):
16650         * inspector/NetworkResourcesData.h:
16651         (WebCore::NetworkResourcesData::ResourceData::isContentEvicted):
16652         (ResourceData):
16653
16654 2012-11-09  Kent Tamura  <tkent@chromium.org>
16655
16656         Don't use RenderTextControlSingleLine for date/time input types without the multiple-fields UI
16657         https://bugs.webkit.org/show_bug.cgi?id=101722
16658
16659         Reviewed by Hajime Morita.
16660
16661         Because the date/time input types are not textfields, we should not use
16662         RenderTextControlSingleLine, and don't need to create shadow trees for
16663         RenderTextControlSingleLine.
16664
16665         No new tests. Covered by fast/forms/*/*-appearance-*.html.
16666
16667         * css/html.css:
16668         (input[type="date"]):
16669         It has menulist appeanrace by default, and should be a flexible box to
16670         center the inner text. 10em width is almost same as the default width of
16671         text fields.
16672         (input[type="datetime"]): Ditto.
16673         (input[type="datetime-local"]): Ditto.
16674         (input[type="month"]): Ditto.
16675         (input[type="time"]): Ditto.
16676         (input[type="week"]): Ditto.
16677         (input::-webkit-date-and-time-value):
16678         Added. A style for the inner text block.
16679         * html/BaseChooserOnlyDateAndTimeInputType.cpp:
16680         (WebCore::BaseChooserOnlyDateAndTimeInputType::createRenderer):
16681         Don't create RenderTextControlSingleLine.
16682         (WebCore::BaseChooserOnlyDateAndTimeInputType::updateInnerTextValue):
16683         Skip TextFieldInputType::updateInnerTextValue.
16684         (WebCore::BaseChooserOnlyDateAndTimeInputType::forwardEvent):
16685         Skip TextFieldInputType::forwardEvent.
16686         (WebCore::BaseChooserOnlyDateAndTimeInputType::createShadowSubtree):
16687         Just add one element to the shadow root.
16688         (WebCore::BaseChooserOnlyDateAndTimeInputType::updateAppearance):
16689         Sets a localized value to the inner text block.
16690         (WebCore::BaseChooserOnlyDateAndTimeInputType::setValue):
16691         Calls updateAppearance if the value is updated.
16692         * html/BaseChooserOnlyDateAndTimeInputType.h:
16693         (BaseChooserOnlyDateAndTimeInputType): Declare updateAppearance,
16694         createRenderer, updateInnerTextValue, forwardEvent, createShadowSubtree,
16695         and setValue.
16696         * html/BaseDateAndTimeInputType.h:
16697         (WebCore): Add a FIXME comment.
16698         (BaseDateAndTimeInputType):
16699         Make visibleValue protected. It is used by BaseChooserOnlyDateAndTimeInputType.
16700         * html/TextFieldInputType.h:
16701         (TextFieldInputType):
16702         Make setValue protected. It is used by BaseChooserOnlyDateAndTimeInputType.
16703
16704 2012-11-09  Vsevolod Vlasov  <vsevik@chromium.org>
16705
16706         Web Inspector: Clarify meaning of different urls in protocol.
16707         https://bugs.webkit.org/show_bug.cgi?id=101582
16708
16709         Reviewed by Yury Semikhatsky.
16710
16711         * inspector/Inspector.json:
16712
16713 2012-11-09  Keishi Hattori  <keishi@webkit.org>
16714
16715         Month picker should select the current month when navigating while keeping selection position.
16716         https://bugs.webkit.org/show_bug.cgi?id=101724
16717
16718         Reviewed by Kent Tamura.
16719
16720         Month picker needs to behave differently because selection won't be in the same position when changing current month.
16721
16722         No new tests. Test will be added in Bug 101556.
16723
16724         * Resources/pagepopups/calendarPicker.js:
16725         (DaysTable.prototype.navigateToMonth): Date/Week picker should keep selection position for first selected date node.
16726         (DaysTable.prototype._startMoveInAnimation): Moving shared code to separate function.
16727         (MonthPickerDaysTable.prototype.navigateToMonth): Month picker should just select the month.
16728
16729 2012-11-09  Alexei Filippov  <alph@chromium.org>
16730
16731         Web Inspector: Fix heap snapshots counted several times by NMI
16732         https://bugs.webkit.org/show_bug.cgi?id=101085
16733
16734         The fix moves snapshots size counting to V8PerIsolateData class. As long
16735         as it has one instance per isolate its reportMemoryUsage should be
16736         called once per isolate.
16737
16738         Reviewed by Yury Semikhatsky.
16739
16740         * bindings/v8/V8PerIsolateData.cpp:
16741         (WebCore::V8PerIsolateData::reportMemoryUsage):
16742         * inspector/InspectorProfilerAgent.cpp:
16743         (WebCore::InspectorProfilerAgent::reportMemoryUsage):
16744
16745 2012-11-08  Pavel Feldman  <pfeldman@chromium.org>
16746
16747         Web Inspector: split SplitView into SplitView and SidebarView
16748         https://bugs.webkit.org/show_bug.cgi?id=101612
16749
16750         Reviewed by Vsevolod Vlasov.
16751
16752         Currently, SplitView is rather a sidebar view. I'm extracting the reusable split component from it.
16753
16754         * WebCore.gypi:
16755         * WebCore.vcproj/WebCore.vcproj:
16756         * inspector/compile-front-end.py:
16757         * inspector/front-end/AuditsPanel.js:
16758         (WebInspector.AuditsPanel):
16759         * inspector/front-end/CSSNamedFlowCollectionsView.js:
16760         (WebInspector.CSSNamedFlowCollectionsView):
16761         (WebInspector.CSSNamedFlowCollectionsView.prototype.wasShown):
16762         * inspector/front-end/ElementsPanel.js:
16763         * inspector/front-end/FileSystemView.js:
16764         (WebInspector.FileSystemView):
16765         * inspector/front-end/MemoryStatistics.js:
16766         (WebInspector.CounterUI):
16767         (WebInspector.MemoryStatistics.prototype.setTopPosition):
16768         (WebInspector.MemoryStatistics.prototype.setSidebarWidth):
16769         (WebInspector.MemoryStatistics.prototype.visible):
16770         (WebInspector.MemoryStatistics.prototype.show):
16771         (WebInspector.MemoryStatistics.prototype.hide):
16772         * inspector/front-end/NavigatorOverlayController.js:
16773         (WebInspector.NavigatorOverlayController.prototype.set _pinNavigator):
16774         (WebInspector.NavigatorOverlayController.prototype.set showNavigatorOverlay):
16775         (WebInspector.NavigatorOverlayController.prototype.hideNavigatorOverlay):
16776         (WebInspector.NavigatorOverlayController.prototype._innerHideNavigatorOverlay):
16777         * inspector/front-end/NetworkPanel.js:
16778         * inspector/front-end/Panel.js:
16779         (WebInspector.Panel.prototype.createSidebarView):
16780         (WebInspector.Panel.prototype.createSidebarViewWithTree):
16781         * inspector/front-end/ProfilesPanel.js:
16782         (WebInspector.ProfilesPanel):
16783         * inspector/front-end/ResourcesPanel.js:
16784         * inspector/front-end/ScriptsPanel.js:
16785         (WebInspector.ScriptsPanel):
16786         * inspector/front-end/SidebarView.js: Added.
16787         (WebInspector.SidebarView):
16788         (WebInspector.SidebarView.prototype._hasLeftSidebar):
16789         (WebInspector.SidebarView.prototype.get mainElement):
16790         (WebInspector.SidebarView.prototype.get sidebarElement):
16791         (WebInspector.SidebarView.prototype._innerSetSidebarPosition):
16792         (WebInspector.SidebarView.prototype.setMinimalSidebarWidth):
16793         (WebInspector.SidebarView.prototype.setMinimalMainWidthPercent):
16794         (WebInspector.SidebarView.prototype.setSidebarWidth):
16795         (WebInspector.SidebarView.prototype.sidebarWidth):
16796         (WebInspector.SidebarView.prototype.onResize):
16797         (WebInspector.SidebarView.prototype.applyConstraints):
16798         (WebInspector.SidebarView.prototype.hideMainElement):
16799         (WebInspector.SidebarView.prototype.showMainElement):
16800         (WebInspector.SidebarView.prototype.hideSidebarElement):
16801         (WebInspector.SidebarView.prototype.showSidebarElement):
16802         (WebInspector.SidebarView.prototype.elementsToRestoreScrollPositionsFor):
16803         * inspector/front-end/SplitView.js:
16804         (WebInspector.SplitView):
16805         (WebInspector.SplitView.prototype.firstElement):
16806         (WebInspector.SplitView.prototype.secondElement):
16807         (WebInspector.SplitView.prototype.setChangeFirstOnResize):
16808         (WebInspector.SplitView.prototype.resizerElement):
16809         (WebInspector.SplitView.prototype.showOnlyFirst):
16810         (WebInspector.SplitView.prototype.showOnlySecond):
16811         (WebInspector.SplitView.prototype._showOnly):
16812         (WebInspector.SplitView.prototype._removeAllLayoutProperties):
16813         (WebInspector.SplitView.prototype.showBoth):
16814         (WebInspector.SplitView.prototype.setResizable):
16815         (WebInspector.SplitView.prototype.setSplitOffset):
16816         (WebInspector.SplitView.prototype.splitOffset):
16817         (WebInspector.SplitView.prototype._innerSetSplitOffset):
16818         (WebInspector.SplitView.prototype._startResizerDragging):
16819         * inspector/front-end/TimelinePanel.js:
16820         * inspector/front-end/WebKit.qrc:
16821         * inspector/front-end/inspector.html:
16822         * inspector/front-end/splitView.css:
16823
16824 2012-11-09  Andrey Lushnikov  <lushnikov@google.com>
16825
16826         Web Inspector: Ctrl+A in the network panel should select resource content, not the entire panel
16827         https://bugs.webkit.org/show_bug.cgi?id=101591
16828
16829         Reviewed by Vsevolod Vlasov.
16830
16831         Intercept Ctrl+A event in DefaultTextEditor to select resource content
16832
16833         * inspector/front-end/DefaultTextEditor.js:
16834         (WebInspector.DefaultTextEditor.prototype._registerShortcuts): Added Ctrl+A
16835         (WebInspector.DefaultTextEditor.prototype._handleKeyDown): Intercept Ctrl+A even for readonly fields
16836         (WebInspector.TextEditorMainPanel.prototype.handleSelectAll):
16837         * inspector/front-end/KeyboardShortcut.js: Added SelectAll constant for Ctrl+A combination
16838
16839 2012-11-09  Dan Carney  <dcarney@google.com>
16840
16841         [V8] Main world should have one DOMDataStore
16842         https://bugs.webkit.org/show_bug.cgi?id=101470
16843
16844         Reviewed by Kentaro Hara.
16845
16846         The main world DOMWrapperWorld held onto a DOMDataStore that should
16847         never be used, as there is a static one optimized for speed in
16848         DOMDataStore.
16849
16850         No new tests. No change in functionality.
16851
16852         * bindings/v8/DOMDataStore.cpp:
16853         (WebCore::DOMDataStore::current):
16854         * bindings/v8/DOMWrapperWorld.h:
16855         (WebCore::DOMWrapperWorld::isolatedWorldDomDataStore):
16856         (WebCore::DOMWrapperWorld::DOMWrapperWorld):
16857         * bindings/v8/V8DOMWrapper.h:
16858         (WebCore::V8DOMWrapper::getCachedWrapper):
16859
16860 2012-11-09  Alexei Filippov  <alph@chromium.org>
16861
16862         Web Inspector: Navigating around NMI snapshot grid with keys breaks the grid
16863         https://bugs.webkit.org/show_bug.cgi?id=101611
16864
16865         Reviewed by Yury Semikhatsky.
16866
16867         Keys navigation cause populate message sent to the node. The node should
16868         not react on populate messages but the first one.
16869
16870         * inspector/front-end/NativeMemorySnapshotView.js:
16871
16872 2012-11-08  Eugene Klyuchnikov  <eustas.bug@gmail.com>
16873
16874         Web Inspector: Timeline: "Send Request" events are shown out of order.
16875         https://bugs.webkit.org/show_bug.cgi?id=101544
16876
16877         Reviewed by Yury Semikhatsky.
16878
16879         Solution: replace obsolete out-of-order record pushing with frontend
16880         record reparenting.
16881
16882         * inspector/InspectorTimelineAgent.cpp:
16883         (WebCore::InspectorTimelineAgent::willSendResourceRequest): Replaced
16884         direct record pushing with standard appendRecord invokation.
16885         * inspector/front-end/TimelinePresentationModel.js:
16886         (WebInspector.TimelinePresentationModel.prototype._findParentRecord):
16887         Made "Send Request" records top-level if gluing is on.
16888
16889 2012-11-08  Sheriff Bot  <webkit.review.bot@gmail.com>
16890
16891         Unreviewed, rolling out r134010.
16892         http://trac.webkit.org/changeset/134010
16893         https://bugs.webkit.org/show_bug.cgi?id=101716
16894
16895         Broke the chromium windows build. (Requested by noel_ on
16896         #webkit).
16897
16898         * Modules/indexeddb/IDBAny.cpp:
16899         * Modules/indexeddb/IDBCallbacks.h:
16900         * Modules/indexeddb/IDBDatabase.cpp:
16901         (WebCore::IDBDatabase::createObjectStore):
16902         (WebCore::IDBDatabase::deleteObjectStore):
16903         (WebCore::IDBDatabase::transaction):
16904         * Modules/indexeddb/IDBDatabase.h:
16905         (IDBDatabase):
16906         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
16907         (WebCore::IDBDatabaseBackendImpl::getObjectStoreId):
16908         (WebCore):
16909         (WebCore::IDBDatabaseBackendImpl::setVersion):
16910         (WebCore::IDBDatabaseBackendImpl::transaction):
16911         (WebCore::IDBDatabaseBackendImpl::runIntVersionChangeTransaction):
16912         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
16913         (WebCore::IDBDatabaseBackendImpl::deleteObjectStore):
16914         (IDBDatabaseBackendImpl):
16915         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
16916         (WebCore):
16917         (IDBDatabaseBackendInterface):
16918         * Modules/indexeddb/IDBMetadata.h:
16919         (WebCore::IDBObjectStoreMetadata::containsIndex):
16920         (WebCore::IDBDatabaseMetadata::findObjectStore):
16921         (IDBDatabaseMetadata):
16922         (WebCore::IDBDatabaseMetadata::containsObjectStore):
16923         * Modules/indexeddb/IDBObjectStore.cpp:
16924         (WebCore::IDBObjectStore::put):
16925         (WebCore):
16926         (WebCore::IDBObjectStore::createIndex):
16927         (WebCore::IDBObjectStore::index):
16928         (WebCore::IDBObjectStore::deleteIndex):
16929         * Modules/indexeddb/IDBObjectStore.h:
16930         (WebCore::IDBObjectStore::openCursor):
16931         (IDBObjectStore):
16932         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
16933         (WebCore::IDBObjectStoreBackendImpl::put):
16934         (WebCore::IDBObjectStoreBackendImpl::putWithIndexKeys):
16935         (WebCore):
16936         (WebCore::IDBObjectStoreBackendImpl::setIndexKeys):
16937         (WebCore::IDBObjectStoreBackendImpl::setIndexesReady):
16938         (WebCore::IDBObjectStoreBackendImpl::index):
16939         (WebCore::IDBObjectStoreBackendImpl::getIndexId):
16940         (WebCore::IDBObjectStoreBackendImpl::getIndexIds):
16941         (WebCore::IDBObjectStoreBackendImpl::deleteIndex):
16942         * Modules/indexeddb/IDBObjectStoreBackendImpl.h:
16943         (IDBObjectStoreBackendImpl):
16944         * Modules/indexeddb/IDBObjectStoreBackendInterface.h:
16945         (WebCore):
16946         * Modules/indexeddb/IDBTransaction.cpp:
16947         (WebCore::IDBTransaction::objectStore):
16948         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
16949         (WebCore::IDBTransactionBackendImpl::objectStore):
16950         (WebCore):
16951         * Modules/indexeddb/IDBTransactionBackendImpl.h:
16952         (IDBTransactionBackendImpl):
16953         * Modules/indexeddb/IDBTransactionBackendInterface.h:
16954
16955 2012-11-08  Grzegorz Czajkowski  <g.czajkowski@samsung.com>
16956
16957         [EFL] Add a method to the TextCheckerEnchant class to check whether any dictionary is loaded
16958         https://bugs.webkit.org/show_bug.cgi?id=101570
16959
16960         Reviewed by Gustavo Noronha Silva.
16961
16962         Expose a new method to check whether a vector of loaded languages is empty.
16963         WK2-EFL needs it to set the default language (if the client didn't set any) when
16964         spelling setting is being enabled. This change makes it more convenient to check
16965         whether the dictionaries vector is empty.
16966
16967         No new tests, no behavior change.
16968
16969         * platform/text/enchant/TextCheckerEnchant.cpp:
16970         (TextCheckerEnchant::checkSpellingOfString):
16971         (TextCheckerEnchant::getGuessesForWord):
16972         (TextCheckerEnchant::loadedSpellCheckingLanguages):
16973         A newly exposed method is used internally too.
16974
16975         * platform/text/enchant/TextCheckerEnchant.h:
16976         (WebCore::TextCheckerEnchant::hasDictionary):
16977         Add an inline hasDictionary() method.
16978
16979 2012-11-08  Shinya Kawanaka  <shinyak@chromium.org>
16980
16981         [Refactoring] Remove shadowPseudoId() and use pseudo() instead in TextTrackCue
16982         https://bugs.webkit.org/show_bug.cgi?id=101702
16983
16984         Reviewed by Hajime Morita.
16985
16986         We're migrating shadowPseudoId() to pseudo(). We remove shadowPseudoId() from TextTrackCue and use
16987         setPseudo()/pseudo() instead.
16988
16989         No new tests, simple refactoring.
16990
16991         * html/track/TextTrackCue.cpp:
16992         (WebCore::TextTrackCueBox::TextTrackCueBox):
16993         * html/track/TextTrackCue.h:
16994         (TextTrackCueBox):
16995
16996 2012-11-08  Arpita Bahuguna  <arpitabahuguna@gmail.com>
16997
16998         table not aligned in center column and seems shrunk because of float:right (table-layout: fixed and width: 100%)
16999         https://bugs.webkit.org/show_bug.cgi?id=18153
17000
17001         Reviewed by Beth Dakin.
17002
17003         Preferred logical width is computed incorrectly for fixed layout tables
17004         with 100% percent width, in standards mode.
17005
17006         According to our fixed table layout algorithm (CSS2 specification - 17.5.2.1)
17007         the ultimate width of the table is the greater of the value of the
17008         'width' property for the table elements and the sum of the column
17009         widths.
17010
17011         For our specific scenario we have a fixed layout table with 100% width
17012         consisting of columns with fixed widths, the sum of which is less than
17013         the specified width of the table (i.e. 100% of the containing block).
17014         Even then the applied width is the cummulative of the width of the
17015         columns.
17016
17017         This happens because of the quirks mode check added in
17018         FixedTableLayout::computePreferredLogicalWidths(), which prohibits the
17019         setting of maxWidth to our fixed layout table with percent width, and
17020         which perhaps is not required anymore.
17021
17022         Test: fast/table/fixed-table-layout/table-with-percent-width.html
17023
17024         * rendering/FixedTableLayout.cpp:
17025         (WebCore::FixedTableLayout::computePreferredLogicalWidths):
17026         Removed the quirks mode check.
17027
17028 2012-11-08  Sheriff Bot  <webkit.review.bot@gmail.com>
17029
17030         Unreviewed, rolling out r134004.
17031         http://trac.webkit.org/changeset/134004
17032         https://bugs.webkit.org/show_bug.cgi?id=101713
17033
17034         multiple crashes (Requested by hayato on #webkit).
17035
17036         * rendering/RenderThemeMac.mm:
17037         (WebCore::RenderThemeMac::adjustMediaSliderThumbSize):
17038         (WebCore::RenderThemeMac::paintMediaFullscreenButton):
17039         (WebCore::RenderThemeMac::paintMediaMuteButton):
17040         (WebCore::RenderThemeMac::paintMediaPlayButton):
17041         (WebCore::RenderThemeMac::paintMediaSeekBackButton):
17042         (WebCore::RenderThemeMac::paintMediaSeekForwardButton):
17043         (WebCore::RenderThemeMac::paintMediaSliderTrack):
17044         (WebCore::RenderThemeMac::paintMediaSliderThumb):
17045         (WebCore::RenderThemeMac::paintMediaRewindButton):
17046         (WebCore::RenderThemeMac::paintMediaReturnToRealtimeButton):
17047         (WebCore::RenderThemeMac::paintMediaToggleClosedCaptionsButton):
17048         (WebCore::RenderThemeMac::paintMediaControlsBackground):
17049         (WebCore::RenderThemeMac::paintMediaCurrentTime):
17050         (WebCore::RenderThemeMac::paintMediaTimeRemaining):
17051         (WebCore::RenderThemeMac::paintMediaVolumeSliderContainer):
17052         (WebCore::RenderThemeMac::paintMediaVolumeSliderTrack):
17053         (WebCore::RenderThemeMac::paintMediaVolumeSliderThumb):
17054         (WebCore::RenderThemeMac::paintMediaFullScreenVolumeSliderTrack):
17055         (WebCore::RenderThemeMac::paintMediaFullScreenVolumeSliderThumb):
17056
17057 2012-11-08  Jan Keromnes  <janx@linux.com>
17058
17059         Web Inspector: stop using cursorCoords in CodeMirrorTextEditor
17060         https://bugs.webkit.org/show_bug.cgi?id=101607
17061
17062         Reviewed by Vsevolod Vlasov.
17063
17064         API changes completing migration to v3.
17065
17066         * inspector/front-end/CodeMirrorTextEditor.js:
17067         (WebInspector.CodeMirrorTextEditor):
17068         (WebInspector.CodeMirrorTextEditor.prototype.revealLine):
17069         (WebInspector.CodeMirrorTextEditor.prototype.selection):
17070
17071 2012-11-08  Alexei Filippov  <alph@chromium.org>
17072
17073         Web Inspector: make "Other" bar color darker in NMI snapshot.
17074         https://bugs.webkit.org/show_bug.cgi?id=101602
17075
17076         Reviewed by Vsevolod Vlasov.
17077
17078         * inspector/front-end/NativeMemorySnapshotView.js:
17079         (WebInspector.MemoryBlockViewProperties._initialize):
17080
17081 2012-11-08  Alec Flett  <alecflett@chromium.org>
17082
17083         IndexedDB: switch frontend to use int64_t-based references
17084         https://bugs.webkit.org/show_bug.cgi?id=100426
17085
17086         Reviewed by Tony Chang.
17087
17088         Remove String-based objectStore/index references, obsoleted by
17089         https://bugs.webkit.org/show_bug.cgi?id=100425.
17090
17091         No new tests as this is the second half of a refactor.
17092
17093         * Modules/indexeddb/IDBCallbacks.h:
17094         * Modules/indexeddb/IDBDatabase.cpp:
17095         (WebCore::IDBDatabase::deleteObjectStore):
17096         (WebCore::IDBDatabase::transaction):
17097         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
17098         (WebCore::IDBDatabaseBackendImpl::setVersion):
17099         (WebCore::IDBDatabaseBackendImpl::transaction):
17100         (WebCore::IDBDatabaseBackendImpl::runIntVersionChangeTransaction):
17101         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
17102         (IDBDatabaseBackendImpl):
17103         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
17104         (IDBDatabaseBackendInterface):
17105         * Modules/indexeddb/IDBMetadata.h:
17106         (WebCore::IDBObjectStoreMetadata::findIndex):
17107         (IDBObjectStoreMetadata):
17108         (WebCore::IDBObjectStoreMetadata::containsIndex):
17109         * Modules/indexeddb/IDBObjectStore.cpp:
17110         (WebCore::IDBObjectStore::put):
17111         (WebCore):
17112         (WebCore::IDBObjectStore::index):
17113         (WebCore::IDBObjectStore::deleteIndex):
17114         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
17115         (WebCore::IDBObjectStoreBackendImpl::put):
17116         (WebCore):
17117         * Modules/indexeddb/IDBObjectStoreBackendImpl.h:
17118         (IDBObjectStoreBackendImpl):
17119         * Modules/indexeddb/IDBObjectStoreBackendInterface.h:
17120         * inspector/Inspector-1.0.json:
17121         * inspector/Inspector.json:
17122         * inspector/InspectorIndexedDBAgent.cpp:
17123         (WebCore):
17124         (WebCore::InspectorIndexedDBAgent::requestData):
17125         * inspector/InspectorIndexedDBAgent.h:
17126         (InspectorIndexedDBAgent):
17127
17128 2012-11-08  Shinya Kawanaka  <shinyak@chromium.org>
17129
17130         [Refactoring] Expose collectFeaturesFromSelector from RuleSet.cpp
17131         https://bugs.webkit.org/show_bug.cgi?id=101692
17132
17133         Reviewed by Dimitri Glazkov.
17134
17135         We expose collectFeaturesFromSelector in RuleSet.cpp to use it for collecting ShadowDOM select attribute features.
17136
17137         No new tests, simple refactoring.
17138
17139         * css/RuleFeature.cpp:
17140         (WebCore::RuleFeatureSet::collectFeaturesFromSelector): Moved from RuleSet.cpp.
17141         (WebCore):
17142         * css/RuleFeature.h:
17143         (WebCore):
17144         (RuleFeatureSet):
17145         * css/RuleSet.cpp:
17146         (WebCore::collectFeaturesFromRuleData):
17147
17148 2012-11-08  Robert Sesek  <rsesek@chromium.org>
17149
17150         Guard calls to WebKitSystemInterface media control drawing functions in RenderThemeMac with PLATFORM(MAC)
17151         https://bugs.webkit.org/show_bug.cgi?id=101634
17152
17153         Reviewed by Adam Barth.
17154
17155         No new tests, just disabling unused code in Chromium port.
17156
17157         * rendering/RenderThemeMac.mm:
17158         (WebCore::RenderThemeMac::adjustMediaSliderThumbSize):
17159         (WebCore::RenderThemeMac::paintMediaFullscreenButton):
17160         (WebCore::RenderThemeMac::paintMediaMuteButton):
17161         (WebCore::RenderThemeMac::paintMediaPlayButton):
17162         (WebCore::RenderThemeMac::paintMediaSeekBackButton):
17163         (WebCore::RenderThemeMac::paintMediaSeekForwardButton):
17164         (WebCore::RenderThemeMac::paintMediaSliderTrack):
17165         (WebCore::RenderThemeMac::paintMediaSliderThumb):
17166         (WebCore::RenderThemeMac::paintMediaRewindButton):
17167         (WebCore::RenderThemeMac::paintMediaReturnToRealtimeButton):
17168         (WebCore::RenderThemeMac::paintMediaToggleClosedCaptionsButton):
17169         (WebCore::RenderThemeMac::paintMediaControlsBackground):
17170         (WebCore::RenderThemeMac::paintMediaCurrentTime):
17171         (WebCore::RenderThemeMac::paintMediaTimeRemaining):
17172         (WebCore::RenderThemeMac::paintMediaVolumeSliderContainer):
17173         (WebCore::RenderThemeMac::paintMediaVolumeSliderTrack):
17174         (WebCore::RenderThemeMac::paintMediaVolumeSliderThumb):
17175         (WebCore::RenderThemeMac::paintMediaFullScreenVolumeSliderTrack):
17176         (WebCore::RenderThemeMac::paintMediaFullScreenVolumeSliderThumb):
17177
17178 2012-11-08  Keishi Hattori  <keishi@webkit.org>
17179
17180         Enable calendar picker for input types week/month
17181         https://bugs.webkit.org/show_bug.cgi?id=101553
17182
17183         Reviewed by Kent Tamura.
17184
17185         Enabling calendar picker for <input type=week/month>
17186
17187         No new tests. Tests will be added later in Bug 101556 and Bug 101555.
17188
17189         * rendering/RenderThemeChromiumCommon.cpp:
17190         (WebCore::RenderThemeChromiumCommon::supportsCalendarPicker):
17191
17192 2012-11-08  Robin Cao  <robin.cao@torchmobile.com.cn>
17193
17194         [BlackBerry] Change the default return value of MediaPlayerPrivate::hasSingleSecurityOrigin
17195         https://bugs.webkit.org/show_bug.cgi?id=101681
17196
17197         Reviewed by George Staikos.
17198
17199         Since the platform player in BlackBerry disallows resources that come from different origins,
17200         so it's safe to directly returns true here.
17201
17202         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
17203         (WebCore::MediaPlayerPrivate::hasSingleSecurityOrigin):
17204
17205 2012-11-08  Mark Lam  <mark.lam@apple.com>
17206
17207         Renamed ...InlineMethods.h files to ...Inlines.h.
17208         https://bugs.webkit.org/show_bug.cgi?id=101145.
17209
17210         Reviewed by Geoffrey Garen.
17211
17212         This is only a refactoring effort to rename the files. There are no
17213         functionality changes.
17214
17215         No new tests.
17216
17217         * GNUmakefile.list.am:
17218         * Target.pri:
17219         * WebCore.gypi:
17220         * WebCore.vcproj/WebCore.vcproj:
17221         * WebCore.xcodeproj/project.pbxproj:
17222         * html/parser/HTMLEntityParser.cpp:
17223         * html/parser/HTMLTokenizer.cpp:
17224         * html/track/WebVTTTokenizer.cpp:
17225         * xml/parser/CharacterReferenceParserInlineMethods.h: Removed.
17226         * xml/parser/CharacterReferenceParserInlines.h: Copied from Source/WebCore/xml/parser/CharacterReferenceParserInlineMethods.h.
17227         * xml/parser/MarkupTokenizerInlineMethods.h: Removed.
17228         * xml/parser/MarkupTokenizerInlines.h: Copied from Source/WebCore/xml/parser/MarkupTokenizerInlineMethods.h.
17229         * xml/parser/XMLCharacterReferenceParser.cpp:
17230         * xml/parser/XMLTokenizer.cpp:
17231
17232 2012-11-08  Sheriff Bot  <webkit.review.bot@gmail.com>
17233
17234         Unreviewed, rolling out r133984.
17235         http://trac.webkit.org/changeset/133984
17236         https://bugs.webkit.org/show_bug.cgi?id=101684
17237
17238         windows build error. (Requested by hayato on #webkit).
17239
17240         * Modules/indexeddb/IDBCallbacks.h:
17241         * Modules/indexeddb/IDBDatabase.cpp:
17242         (WebCore::IDBDatabase::createObjectStore):
17243         (WebCore::IDBDatabase::deleteObjectStore):
17244         (WebCore::IDBDatabase::transaction):
17245         * Modules/indexeddb/IDBDatabase.h:
17246         (IDBDatabase):
17247         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
17248         (WebCore::IDBDatabaseBackendImpl::getObjectStoreId):
17249         (WebCore):
17250         (WebCore::IDBDatabaseBackendImpl::setVersion):
17251         (WebCore::IDBDatabaseBackendImpl::transaction):
17252         (WebCore::IDBDatabaseBackendImpl::runIntVersionChangeTransaction):
17253         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
17254         (WebCore::IDBDatabaseBackendImpl::deleteObjectStore):
17255         (IDBDatabaseBackendImpl):
17256         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
17257         (IDBDatabaseBackendInterface):
17258         * Modules/indexeddb/IDBMetadata.h:
17259         (WebCore::IDBObjectStoreMetadata::containsIndex):
17260         (WebCore::IDBDatabaseMetadata::findObjectStore):
17261         (IDBDatabaseMetadata):
17262         (WebCore::IDBDatabaseMetadata::containsObjectStore):
17263         * Modules/indexeddb/IDBObjectStore.cpp:
17264         (WebCore::IDBObjectStore::put):
17265         (WebCore):
17266         (WebCore::IDBObjectStore::createIndex):
17267         (WebCore::IDBObjectStore::index):
17268         (WebCore::IDBObjectStore::deleteIndex):
17269         * Modules/indexeddb/IDBObjectStore.h:
17270         (WebCore::IDBObjectStore::openCursor):
17271         (IDBObjectStore):
17272         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
17273         (WebCore::IDBObjectStoreBackendImpl::put):
17274         (WebCore::IDBObjectStoreBackendImpl::putWithIndexKeys):
17275         (WebCore):
17276         (WebCore::IDBObjectStoreBackendImpl::setIndexKeys):
17277         (WebCore::IDBObjectStoreBackendImpl::setIndexesReady):
17278         (WebCore::IDBObjectStoreBackendImpl::index):
17279         (WebCore::IDBObjectStoreBackendImpl::getIndexId):
17280         (WebCore::IDBObjectStoreBackendImpl::getIndexIds):
17281         (WebCore::IDBObjectStoreBackendImpl::deleteIndex):
17282         * Modules/indexeddb/IDBObjectStoreBackendImpl.h:
17283         (IDBObjectStoreBackendImpl):
17284         * Modules/indexeddb/IDBObjectStoreBackendInterface.h:
17285         * Modules/indexeddb/IDBTransaction.cpp:
17286         (WebCore::IDBTransaction::objectStore):
17287         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
17288         (WebCore::IDBTransactionBackendImpl::objectStore):
17289         (WebCore):
17290         * Modules/indexeddb/IDBTransactionBackendImpl.h:
17291         (IDBTransactionBackendImpl):
17292         * Modules/indexeddb/IDBTransactionBackendInterface.h:
17293
17294 2012-11-08  Shinya Kawanaka  <shinyak@chromium.org>
17295
17296         HTMLContentElement should preserve parsed CSSSelectorList
17297         https://bugs.webkit.org/show_bug.cgi?id=101543
17298
17299         Reviewed by Dimitri Glazkov.
17300
17301         We would like to preserve CSSSelectorList for select attribute of HTMLContentElement.
17302
17303         Before, we parsed and validated select attribute every time distribution happens. If we preserve the parsed
17304         CSSSelectorList, we can reduce distribution time.
17305
17306         This is also a prepration patch for Bug 101180. It also needs the parsed CSSSelectorList. We don't want to
17307         parse and validate it again.
17308
17309         No new tests, covered by exising tests.
17310
17311         * html/shadow/ContentSelectorQuery.cpp:
17312         (WebCore::ContentSelectorQuery::ContentSelectorQuery): We don't parse select attribute here anymore.
17313         if it's already parsed.
17314         (WebCore::ContentSelectorQuery::matches):
17315         * html/shadow/ContentSelectorQuery.h:
17316         (ContentSelectorQuery):
17317         * html/shadow/HTMLContentElement.cpp:
17318         (WebCore::HTMLContentElement::HTMLContentElement):
17319         (WebCore::HTMLContentElement::isSelectValid):
17320         (WebCore::HTMLContentElement::ensureSelectParsed): If we don't have parsed the current select attribute,
17321         we parse and validate it.
17322         (WebCore::HTMLContentElement::parseAttribute): When select attribute is changed, we have to have a flag enabled
17323         to parse select attrite again.
17324         (WebCore::validateSubSelector): Moved from ContentSelectorQuery.
17325         (WebCore):
17326         (WebCore::validateSelector): Moved from ContentSelectorQuery.
17327         (WebCore::HTMLContentElement::validateSelect):
17328         * html/shadow/HTMLContentElement.h:
17329         (HTMLContentElement):
17330         (WebCore::HTMLContentElement::setSelect):
17331         (WebCore):
17332         (WebCore::HTMLContentElement::selectorList):
17333         * html/shadow/HTMLShadowElement.cpp:
17334         (WebCore::HTMLShadowElement::emptySelectorList):
17335         (WebCore):
17336         * html/shadow/HTMLShadowElement.h:
17337         (HTMLShadowElement):
17338         (WebCore::HTMLShadowElement::selectorList):
17339         * html/shadow/InsertionPoint.h:
17340         (InsertionPoint):
17341
17342 2012-11-08  Alec Flett  <alecflett@chromium.org>
17343
17344         IndexedDB: switch frontend to use int64_t-based references
17345         https://bugs.webkit.org/show_bug.cgi?id=100426
17346
17347         Reviewed by Tony Chang.
17348
17349         Remove String-based objectStore/index references, obsoleted by
17350         https://bugs.webkit.org/show_bug.cgi?id=100425.
17351
17352         No new tests as this is the second half of a refactor.
17353
17354         * Modules/indexeddb/IDBCallbacks.h:
17355         * Modules/indexeddb/IDBDatabase.cpp:
17356         (WebCore::IDBDatabase::deleteObjectStore):
17357         (WebCore::IDBDatabase::transaction):
17358         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
17359         (WebCore::IDBDatabaseBackendImpl::setVersion):
17360         (WebCore::IDBDatabaseBackendImpl::transaction):
17361         (WebCore::IDBDatabaseBackendImpl::runIntVersionChangeTransaction):
17362         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
17363         (IDBDatabaseBackendImpl):
17364         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
17365         (IDBDatabaseBackendInterface):
17366         * Modules/indexeddb/IDBMetadata.h:
17367         (WebCore::IDBObjectStoreMetadata::findIndex):
17368         (IDBObjectStoreMetadata):
17369         (WebCore::IDBObjectStoreMetadata::containsIndex):
17370         * Modules/indexeddb/IDBObjectStore.cpp:
17371         (WebCore::IDBObjectStore::put):
17372         (WebCore):
17373         (WebCore::IDBObjectStore::index):
17374         (WebCore::IDBObjectStore::deleteIndex):
17375         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
17376         (WebCore::IDBObjectStoreBackendImpl::put):
17377         (WebCore):
17378         * Modules/indexeddb/IDBObjectStoreBackendImpl.h:
17379         (IDBObjectStoreBackendImpl):
17380         * Modules/indexeddb/IDBObjectStoreBackendInterface.h:
17381         * inspector/Inspector-1.0.json:
17382         * inspector/Inspector.json:
17383         * inspector/InspectorIndexedDBAgent.cpp:
17384         (WebCore):
17385         (WebCore::InspectorIndexedDBAgent::requestData):
17386         * inspector/InspectorIndexedDBAgent.h:
17387         (InspectorIndexedDBAgent):
17388
17389 2012-11-08  Kenichi Ishibashi  <bashi@chromium.org>
17390
17391         [Chromium] Arabic digits should appear left-to-right
17392         https://bugs.webkit.org/show_bug.cgi?id=101440
17393
17394         Reviewed by Tony Chang.
17395
17396         Call hb_buffer_set_direction() to set direction when drawing glyphs or
17397         direction should be overridden. Leave direction setting to HarfBuzz when
17398         WebKit is calculating widths because the direction is LTR by default while
17399         calculating widths.  Set script before shaping so that HarfBuzz can estimate
17400         appropriate direction.
17401
17402         Test: fast/text/international/arabic-digits.html
17403
17404         * platform/graphics/harfbuzz/ng/HarfBuzzShaper.cpp:
17405         (WebCore::HarfBuzzShaper::HarfBuzzRun::HarfBuzzRun):
17406         Add m_script. This holds the script of the run.
17407         (WebCore::HarfBuzzShaper::shape):
17408         Tell shapeHarfBuzzRuns() to set direction when drawing glyphs or
17409         direction should be overridden.
17410         (WebCore::HarfBuzzShaper::collectHarfBuzzRuns):
17411         Set script of HarfBuzzRuns.
17412         (WebCore::HarfBuzzShaper::shapeHarfBuzzRuns):
17413         Add an argument that indicates it should set direction.
17414         * platform/graphics/harfbuzz/ng/HarfBuzzShaper.h:
17415         (WebCore::HarfBuzzShaper::HarfBuzzRun::create):
17416         (WebCore::HarfBuzzShaper::HarfBuzzRun::rtl):
17417         (WebCore::HarfBuzzShaper::HarfBuzzRun::script):
17418         (HarfBuzzRun):
17419         (HarfBuzzShaper):
17420
17421 2012-11-08  Huang Dongsung  <luxtella@company100.net>
17422
17423         [TexMap] Remove contentsLayer() in GraphicsLayerTextureMapper.
17424         https://bugs.webkit.org/show_bug.cgi?id=101658
17425
17426         Reviewed by Noam Rosenthal.
17427
17428         GraphicsLayerTextureMapper::contentsLayer() is duplicated to
17429         GraphicsLayer::platformLayer(), so we remove it.
17430
17431         No new tests, this is just a refactor.
17432
17433         * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
17434         (WebCore::GraphicsLayerTextureMapper::platformLayer):
17435         * platform/graphics/texmap/TextureMapperLayer.cpp:
17436         (WebCore::TextureMapperLayer::flushCompositingStateSelf):
17437
17438 2012-11-08  Benjamin Poulain  <benjamin@webkit.org>
17439
17440         Improve the use of AtomicString with literals
17441         https://bugs.webkit.org/show_bug.cgi?id=101298
17442
17443         Reviewed by Darin Adler.
17444
17445         Fix a bunch of cases of AtomicString with literals:
17446         -Do not create temporary AtomicString to perform a comparison, that is very wasteful.
17447         -Use the ConstructFromLiteral constructor whenever it makes sense.
17448         -Make "x-frame-options" static instead of creating it for each response.
17449         -Use ASCIILiteral() instead of AtomicString() in EventHandler, the function takes a String,
17450          not an AtomicString.
17451
17452         * Modules/battery/BatteryController.cpp:
17453         (WebCore::BatteryController::supplementName):
17454         * Modules/battery/NavigatorBattery.cpp:
17455         (WebCore::NavigatorBattery::from):
17456         * Modules/filesystem/chromium/DraggedIsolatedFileSystem.cpp:
17457         (WebCore::DraggedIsolatedFileSystem::supplementName):
17458         * Modules/gamepad/NavigatorGamepad.cpp:
17459         (WebCore::NavigatorGamepad::from):
17460         * Modules/geolocation/GeolocationController.cpp:
17461         (WebCore::GeolocationController::supplementName):
17462         * Modules/geolocation/NavigatorGeolocation.cpp:
17463         (WebCore::NavigatorGeolocation::from):
17464         * Modules/indexeddb/DOMWindowIndexedDatabase.cpp:
17465         (WebCore::DOMWindowIndexedDatabase::from):
17466         * Modules/indexeddb/IDBCursor.cpp:
17467         (WebCore::IDBCursor::directionNext):
17468         (WebCore::IDBCursor::directionNextUnique):
17469         (WebCore::IDBCursor::directionPrev):
17470         (WebCore::IDBCursor::directionPrevUnique):
17471         * Modules/indexeddb/IDBRequest.cpp:
17472         (WebCore::IDBRequest::readyState):
17473         * Modules/indexeddb/IDBTransaction.cpp:
17474         (WebCore::IDBTransaction::modeReadOnly):
17475         (WebCore::IDBTransaction::modeReadWrite):
17476         (WebCore::IDBTransaction::modeVersionChange):
17477         (WebCore::IDBTransaction::modeReadOnlyLegacy):
17478         (WebCore::IDBTransaction::modeReadWriteLegacy):
17479         * Modules/indexeddb/PageGroupIndexedDatabase.cpp:
17480         (WebCore::PageGroupIndexedDatabase::from):
17481         * Modules/intents/DOMWindowIntents.cpp:
17482         (WebCore::DOMWindowIntents::from):
17483         * Modules/mediastream/UserMediaController.cpp:
17484         (WebCore::UserMediaController::supplementName):
17485         * Modules/navigatorcontentutils/NavigatorContentUtils.cpp:
17486         (WebCore::NavigatorContentUtils::supplementName):
17487         * Modules/networkinfo/NavigatorNetworkInfoConnection.cpp:
17488         (WebCore::NavigatorNetworkInfoConnection::from):
17489         * Modules/networkinfo/NetworkInfoController.cpp:
17490         (WebCore::NetworkInfoController::supplementName):
17491         * Modules/notifications/DOMWindowNotifications.cpp:
17492         (WebCore::DOMWindowNotifications::from):
17493         * Modules/notifications/NotificationController.cpp:
17494         (WebCore::NotificationController::supplementName):
17495         * Modules/quota/DOMWindowQuota.cpp:
17496         (WebCore::DOMWindowQuota::from):
17497         * Modules/speech/SpeechRecognitionController.cpp:
17498         (WebCore::SpeechRecognitionController::supplementName):
17499         * Modules/vibration/Vibration.cpp:
17500         (WebCore::Vibration::supplementName):
17501         * accessibility/AccessibilityObject.cpp:
17502         (WebCore::AccessibilityObject::invalidStatus):
17503         * accessibility/AccessibilityRenderObject.cpp:
17504         (WebCore::AccessibilityRenderObject::ariaLiveRegionStatus):
17505         (WebCore::AccessibilityRenderObject::ariaLiveRegionRelevant):
17506         * bindings/v8/custom/V8DOMWindowCustom.cpp:
17507         (WebCore::V8DOMWindow::namedSecurityCheck):
17508         * bindings/v8/custom/V8NodeListCustom.cpp:
17509         (WebCore::V8NodeList::namedPropertyGetter):
17510         * dom/ContextFeatures.cpp:
17511         (WebCore::ContextFeatures::supplementName):
17512         * dom/DeviceMotionController.cpp:
17513         (WebCore::DeviceMotionController::supplementName):
17514         * dom/DeviceOrientationController.cpp:
17515         (WebCore::DeviceOrientationController::supplementName):
17516         * dom/Element.cpp:
17517         (WebCore::Element::webkitRegionOverset):
17518         * dom/MutationRecord.cpp:
17519         * html/FileInputType.cpp:
17520         (WebCore::UploadButtonElement::shadowPseudoId):
17521         * html/FormController.cpp:
17522         (WebCore::SavedFormState::getReferencedFilePaths):
17523         (WebCore::FormKeyGenerator::formKey):
17524         * html/HTMLButtonElement.cpp:
17525         (WebCore::HTMLButtonElement::formControlType):
17526         * html/HTMLDetailsElement.cpp:
17527         (WebCore::summaryQuerySelector):
17528         * html/HTMLFieldSetElement.cpp:
17529         (WebCore::HTMLFieldSetElement::formControlType):
17530         * html/HTMLKeygenElement.cpp:
17531         (WebCore::KeygenSelectElement::shadowPseudoId):
17532         (WebCore::HTMLKeygenElement::formControlType):
17533         * html/HTMLOptGroupElement.cpp:
17534         (WebCore::HTMLOptGroupElement::formControlType):
17535         * html/HTMLOutputElement.cpp:
17536         (WebCore::HTMLOutputElement::formControlType):
17537         * html/HTMLSelectElement.cpp:
17538         (WebCore::HTMLSelectElement::formControlType):
17539         * html/HTMLTextAreaElement.cpp:
17540         (WebCore::HTMLTextAreaElement::formControlType):
17541         * html/HTMLTextFormControlElement.cpp:
17542         (WebCore::directionString):
17543         * html/shadow/DateTimeEditElement.cpp:
17544         (WebCore::DateTimeEditElement::DateTimeEditElement):
17545         * html/shadow/DateTimeFieldElements.cpp:
17546         (WebCore::DateTimeAMPMFieldElement::create):
17547         (WebCore::DateTimeDayFieldElement::create):
17548         (WebCore::DateTimeHourFieldElement::create):
17549         (WebCore::DateTimeMillisecondFieldElement::create):
17550         (WebCore::DateTimeMinuteFieldElement::create):
17551         (WebCore::DateTimeMonthFieldElement::create):
17552         (WebCore::DateTimeSecondFieldElement::create):
17553         (WebCore::DateTimeSymbolicMonthFieldElement::create):
17554         (WebCore::DateTimeWeekFieldElement::create):
17555         (WebCore::DateTimeYearFieldElement::create):
17556         * html/shadow/DetailsMarkerControl.cpp:
17557         (WebCore::DetailsMarkerControl::shadowPseudoId):
17558         * html/shadow/ImageInnerElement.cpp:
17559         (WebCore::ImageInnerElement::shadowPseudoId):
17560         * html/shadow/MediaControlElements.cpp:
17561         (WebCore::MediaControlPanelElement::shadowPseudoId):
17562         (WebCore::MediaControlTimelineContainerElement::shadowPseudoId):
17563         (WebCore::MediaControlVolumeSliderContainerElement::shadowPseudoId):
17564         (WebCore::MediaControlStatusDisplayElement::shadowPseudoId):
17565         (WebCore::MediaControlPanelMuteButtonElement::shadowPseudoId):
17566         (WebCore::MediaControlVolumeSliderMuteButtonElement::shadowPseudoId):
17567         (WebCore::MediaControlPlayButtonElement::shadowPseudoId):
17568         (WebCore::MediaControlOverlayPlayButtonElement::shadowPseudoId):
17569         (WebCore::MediaControlSeekForwardButtonElement::shadowPseudoId):
17570         (WebCore::MediaControlSeekBackButtonElement::shadowPseudoId):
17571         (WebCore::MediaControlRewindButtonElement::shadowPseudoId):
17572         (WebCore::MediaControlReturnToRealtimeButtonElement::shadowPseudoId):
17573         (WebCore::MediaControlToggleClosedCaptionsButtonElement::shadowPseudoId):
17574         (WebCore::MediaControlTimelineElement::shadowPseudoId):
17575         (WebCore::MediaControlVolumeSliderElement::shadowPseudoId):
17576         (WebCore::MediaControlFullscreenVolumeSliderElement::shadowPseudoId):
17577         (WebCore::MediaControlFullscreenButtonElement::shadowPseudoId):
17578         (WebCore::MediaControlFullscreenVolumeMinButtonElement::shadowPseudoId):
17579         (WebCore::MediaControlFullscreenVolumeMaxButtonElement::shadowPseudoId):
17580         (WebCore::MediaControlTimeRemainingDisplayElement::shadowPseudoId):
17581         (WebCore::MediaControlCurrentTimeDisplayElement::shadowPseudoId):
17582         (WebCore::MediaControlTextTrackContainerElement::shadowPseudoId):
17583         * html/shadow/MediaControlRootElement.cpp:
17584         (WebCore::MediaControlRootElement::shadowPseudoId):
17585         * html/shadow/MediaControlRootElementChromium.cpp:
17586         (WebCore::MediaControlPanelEnclosureElement::shadowPseudoId):
17587         (WebCore::MediaControlRootElementChromium::shadowPseudoId):
17588         * html/shadow/MediaControlRootElementChromiumAndroid.cpp:
17589         (WebCore::MediaControlOverlayEnclosureElement::shadowPseudoId):
17590         * html/shadow/MeterShadowElement.cpp:
17591         (WebCore::MeterInnerElement::shadowPseudoId):
17592         (WebCore::MeterBarElement::shadowPseudoId):
17593         (WebCore::MeterValueElement::shadowPseudoId):
17594         * html/shadow/ProgressShadowElement.cpp:
17595         (WebCore::ProgressInnerElement::shadowPseudoId):
17596         (WebCore::ProgressBarElement::shadowPseudoId):
17597         (WebCore::ProgressValueElement::shadowPseudoId):
17598         * html/shadow/SliderThumbElement.cpp:
17599         (WebCore::sliderThumbShadowPseudoId):
17600         (WebCore::mediaSliderThumbShadowPseudoId):
17601         (WebCore::SliderContainerElement::shadowPseudoId):
17602         * html/shadow/SpinButtonElement.cpp:
17603         (WebCore::SpinButtonElement::shadowPseudoId):
17604         * html/shadow/TextControlInnerElements.cpp:
17605         (WebCore::SearchFieldResultsButtonElement::shadowPseudoId):
17606         (WebCore::SearchFieldCancelButtonElement::shadowPseudoId):
17607         (WebCore::InputFieldSpeechButtonElement::shadowPseudoId):
17608         * html/track/TextTrackCue.cpp:
17609         (WebCore::TextTrackCueBox::textTrackCueBoxShadowPseudoId):
17610         * loader/CrossOriginAccessControl.cpp:
17611         (WebCore::passesAccessControlCheck):
17612         * loader/MainResourceLoader.cpp:
17613         (WebCore::MainResourceLoader::didReceiveResponse):
17614         * loader/PrerendererClient.cpp:
17615         (WebCore::PrerendererClient::supplementName):
17616         * loader/cache/CachedResource.cpp:
17617         (WebCore::CachedResource::updateResponseAfterRevalidation):
17618         * page/DOMWindowPagePopup.cpp:
17619         (WebCore::DOMWindowPagePopup::supplementName):
17620         * page/EventHandler.cpp:
17621         (WebCore::EventHandler::handlePasteGlobalSelection):
17622         (WebCore::focusDirectionForKey):
17623         * page/SpeechInput.cpp:
17624         (WebCore::SpeechInput::supplementName):
17625         * page/animation/CompositeAnimation.cpp:
17626         (WebCore::CompositeAnimation::updateKeyframeAnimations):
17627         * platform/graphics/FontCache.cpp:
17628         (WebCore::alternateFamilyName):
17629         * platform/graphics/MediaPlayer.cpp:
17630         (WebCore::applicationOctetStream):
17631         (WebCore::textPlain):
17632         (WebCore::codecs):
17633         * platform/graphics/chromium/FontCacheAndroid.cpp:
17634         (WebCore::FontCache::getLastResortFallbackFont):
17635         * platform/graphics/filters/SourceAlpha.cpp:
17636         (WebCore::SourceAlpha::effectName):
17637         * platform/graphics/filters/SourceGraphic.cpp:
17638         (WebCore::SourceGraphic::effectName):
17639         * platform/graphics/mac/FontCacheMac.mm:
17640         (WebCore::FontCache::getSimilarFontPlatformData):
17641         (WebCore::FontCache::getLastResortFallbackFont):
17642         * platform/graphics/skia/FontCacheSkia.cpp:
17643         (WebCore::FontCache::getLastResortFallbackFont):
17644         * platform/graphics/win/FontCacheWin.cpp:
17645         (WebCore::FontCache::getLastResortFallbackFont):
17646         * platform/graphics/wx/FontCacheWx.cpp:
17647         (WebCore::FontCache::getSimilarFontPlatformData):
17648         * platform/network/ResourceResponseBase.cpp:
17649         (WebCore::ResourceResponseBase::setHTTPHeaderField):
17650         (WebCore::ResourceResponseBase::parseCacheControlDirectives):
17651         (WebCore::ResourceResponseBase::hasCacheValidatorFields):
17652         (WebCore::ResourceResponseBase::date):
17653         (WebCore::ResourceResponseBase::age):
17654         (WebCore::ResourceResponseBase::expires):
17655         (WebCore::ResourceResponseBase::lastModified):
17656         (WebCore::ResourceResponseBase::isAttachment):
17657         * rendering/RenderTextControlMultiLine.cpp:
17658         (WebCore::RenderTextControlMultiLine::getAvgCharWidth):
17659         * rendering/RenderTextControlSingleLine.cpp:
17660         (WebCore::RenderTextControlSingleLine::getAvgCharWidth):
17661         (WebCore::RenderTextControlSingleLine::preferredContentWidth):
17662         * svg/SVGAnimateColorElement.cpp:
17663         (WebCore::attributeValueIsCurrentColor):
17664         * svg/SVGAnimateMotionElement.cpp:
17665         (WebCore::SVGAnimateMotionElement::rotateMode):
17666         * svg/SVGAnimationElement.cpp:
17667         (WebCore::SVGAnimationElement::setCalcMode):
17668         (WebCore::SVGAnimationElement::setAttributeType):
17669         (WebCore::SVGAnimationElement::isAdditive):
17670         (WebCore::SVGAnimationElement::isAccumulated):
17671         (WebCore::inheritsFromProperty):
17672         * svg/SVGFEConvolveMatrixElement.cpp:
17673         (WebCore::SVGFEConvolveMatrixElement::kernelUnitLengthXIdentifier):
17674         (WebCore::SVGFEConvolveMatrixElement::kernelUnitLengthYIdentifier):
17675         (WebCore::SVGFEConvolveMatrixElement::orderXIdentifier):
17676         (WebCore::SVGFEConvolveMatrixElement::orderYIdentifier):
17677         * svg/SVGFEDiffuseLightingElement.cpp:
17678         (WebCore::SVGFEDiffuseLightingElement::kernelUnitLengthXIdentifier):
17679         (WebCore::SVGFEDiffuseLightingElement::kernelUnitLengthYIdentifier):
17680         * svg/SVGFEDropShadowElement.cpp:
17681         (WebCore::SVGFEDropShadowElement::stdDeviationXIdentifier):
17682         (WebCore::SVGFEDropShadowElement::stdDeviationYIdentifier):
17683         * svg/SVGFEGaussianBlurElement.cpp:
17684         (WebCore::SVGFEGaussianBlurElement::stdDeviationXIdentifier):
17685         (WebCore::SVGFEGaussianBlurElement::stdDeviationYIdentifier):
17686         * svg/SVGFEMorphologyElement.cpp:
17687         (WebCore::SVGFEMorphologyElement::radiusXIdentifier):
17688         (WebCore::SVGFEMorphologyElement::radiusYIdentifier):
17689         * svg/SVGFESpecularLightingElement.cpp:
17690         (WebCore::SVGFESpecularLightingElement::kernelUnitLengthXIdentifier):
17691         (WebCore::SVGFESpecularLightingElement::kernelUnitLengthYIdentifier):
17692         * svg/SVGFETurbulenceElement.cpp:
17693         (WebCore::SVGFETurbulenceElement::baseFrequencyXIdentifier):
17694         (WebCore::SVGFETurbulenceElement::baseFrequencyYIdentifier):
17695         * svg/SVGFilterElement.cpp:
17696         (WebCore::SVGFilterElement::filterResXIdentifier):
17697         (WebCore::SVGFilterElement::filterResYIdentifier):
17698         * svg/SVGLangSpace.cpp:
17699         (WebCore::SVGLangSpace::xmlspace):
17700         (WebCore::SVGLangSpace::addSupportedAttributes):
17701         * svg/SVGMarkerElement.cpp:
17702         (WebCore::SVGMarkerElement::orientTypeIdentifier):
17703         (WebCore::SVGMarkerElement::orientAngleIdentifier):
17704         (WebCore::SVGMarkerElement::synchronizeOrientType):
17705         * svg/SVGSVGElement.cpp:
17706         (WebCore::SVGSVGElement::contentScriptType):
17707         (WebCore::SVGSVGElement::contentStyleType):
17708         * svg/SVGStyleElement.cpp:
17709         (WebCore::SVGStyleElement::type):
17710         (WebCore::SVGStyleElement::media):
17711         * svg/SVGTextContentElement.cpp:
17712         (WebCore::SVGTextContentElement::collectStyleForAttribute):
17713         * svg/SVGViewSpec.cpp:
17714         (WebCore::SVGViewSpec::viewBoxIdentifier):
17715         (WebCore::SVGViewSpec::preserveAspectRatioIdentifier):
17716         (WebCore::SVGViewSpec::transformIdentifier):
17717         * svg/animation/SVGSMILElement.cpp:
17718         (WebCore::SVGSMILElement::parseClockValue):
17719         (WebCore::SVGSMILElement::restart):
17720         (WebCore::SVGSMILElement::fill):
17721         (WebCore::SVGSMILElement::repeatCount):
17722         * testing/InternalSettings.cpp:
17723         (WebCore::InternalSettings::from):
17724         * xml/parser/XMLTreeBuilder.cpp:
17725         (WebCore::XMLTreeBuilder::processDOCTYPE):
17726         (WebCore::XMLTreeBuilder::processXMLEntity):
17727
17728 2012-11-08  Beth Dakin  <bdakin@apple.com>
17729
17730         https://bugs.webkit.org/show_bug.cgi?id=101644
17731         Fixed header on Facebook news feed becomes detached from top of 
17732         viewport after rubber band scrolling
17733         -and corresponding-
17734         <rdar://problem/12651944>
17735
17736         Reviewed by Simon Fraser.
17737
17738         There is code to handle this for non-threaded scrolling on FrameView. 
17739         This patch moves most of that code into a convenience function on 
17740         ScrollingCoordinator.
17741
17742         Have FrameView::scrollOffsetForFixedPosition() call 
17743         WebCore::scrollOffsetForFixedPosition() with all the right 
17744         parameters.
17745         * page/FrameView.cpp:
17746         (WebCore::FrameView::scrollOffsetForFixedPosition):
17747
17748         Here's where all the math happens.
17749         * page/scrolling/ScrollingCoordinator.cpp:
17750         (WebCore::fixedPositionScrollOffset):
17751         (WebCore::scrollOffsetForFixedPosition):
17752
17753         The viewportRect in these three places needs to have the 
17754         adjusted-for-fixed offset.
17755         (WebCore::ScrollingCoordinator::updateMainFrameScrollPosition):
17756         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
17757         (WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):
17758         * rendering/RenderLayerCompositor.cpp:
17759         (WebCore::RenderLayerCompositor::computeFixedViewportConstraints):
17760
17761 2012-11-08  Alpha Lam  <hclam@chromium.org>
17762
17763         [chromium] Deferred image decoding fails with image orientation
17764         https://bugs.webkit.org/show_bug.cgi?id=101648
17765
17766         Reviewed by Stephen White.
17767
17768         When an image is deferred save the orientation state. Once this state
17769         is cached it can be used to reply future queries since this state is
17770         static.
17771
17772         No new tests but platform/chromium/virtual/deferred/fast/images/image-orientation.html is passing now.
17773
17774         * platform/graphics/chromium/DeferredImageDecoder.cpp:
17775         (WebCore::DeferredImageDecoder::DeferredImageDecoder):
17776         (WebCore::DeferredImageDecoder::frameBufferAtIndex):
17777         (WebCore::DeferredImageDecoder::orientation):
17778         * platform/graphics/chromium/DeferredImageDecoder.h:
17779         (DeferredImageDecoder):
17780
17781 2012-11-08  Andreas Kling  <kling@webkit.org>
17782
17783         DocumentLoader: Shrink-to-fit the ResourceResponse vector after loading completes.
17784         <http://webkit.org/b/101657>
17785
17786         Reviewed by Anders Carlsson.
17787
17788         Shrink DocumentLoader::m_responses to exact size when we stop adding responses to it,
17789         as we know it won't grow after that.
17790
17791         520kB progression on Membuster3.
17792
17793         * loader/DocumentLoader.cpp:
17794         (WebCore::DocumentLoader::stopRecordingResponses):
17795
17796 2012-11-08  Hans Muller  <hmuller@adobe.com>
17797
17798         [CSS Exclusions] Polygon with horizontal bottom edges returns incorrect segments
17799         https://bugs.webkit.org/show_bug.cgi?id=100874
17800
17801         Reviewed by Dirk Schulze.
17802
17803         Revised the way that computeXIntersections() handles intersections with horizotal polygon edges.
17804         Deciding if a vertex intersection corresponds to a polygon "edge crossing", i.e. a change from inside
17805         to outside or outside to inside, now depends on which side of the horizontal line the function's
17806         y parameter corresponds to. If the y corresponds to the top of the line, then isaMinY the parameter
17807         is true, and an intersection with a horizontal edge is only considered to be an edge crossing if
17808         if the inside of the polygon is just below the horizontal edge.  When isMinY is false then the inside
17809         of the polygon must be just above the horizontal edge.
17810
17811         Tests: fast/exclusions/shape-inside/shape-inside-rectilinear-polygon-003.html
17812                fast/exclusions/shape-inside/shape-inside-rectilinear-polygon-004.html
17813
17814         * rendering/ExclusionPolygon.cpp:
17815         (WebCore::getVertexIntersectionVertices): Corrected two cases where the next/previous vertex was determined incorrectly.
17816         (WebCore::ExclusionPolygon::computeXIntersections): Added a bool isMinY parameter which specifies if the y parameter corresponds to the top or bottom a horizontal line.
17817         (WebCore::ExclusionPolygon::getExcludedIntervals): Added the new computeXIntersections() parameter.
17818         (WebCore::ExclusionPolygon::getIncludedIntervals): Ditto.
17819         * rendering/ExclusionPolygon.h:
17820         (WebCore::ExclusionPolygonEdge::previousEdge): Corrected the previousEdge() function.
17821
17822 2012-11-08  Otto Derek Cheung  <otcheung@rim.com>
17823
17824         [BlackBerry] Disable cookies on file://
17825         https://bugs.webkit.org/show_bug.cgi?id=101646
17826
17827         Reviewed by Rob Buis.
17828
17829         Disabling cookies on file and local in the browser app.
17830
17831         PR 239779
17832
17833         Tested by trying to set and retrieve cookies on WI while browsing
17834         files on the file scheme.
17835
17836         * platform/blackberry/CookieManager.cpp:
17837         (WebCore):
17838         (WebCore::shouldIgnoreScheme):
17839         (WebCore::CookieManager::getRawCookies):
17840         (WebCore::CookieManager::checkAndTreatCookie):
17841
17842 2012-11-08  Joshua Bell  <jsbell@chromium.org>
17843
17844         Expose snapshots in platform/leveldb wrapper API
17845         https://bugs.webkit.org/show_bug.cgi?id=100786
17846
17847         Reviewed by Tony Chang.
17848
17849         Expose leveldb "snapshots" in the LevelDB API. A snapshot lets you observe the database
17850         as it was when the snapshot was taken. This can be used to implement parallel transactions,
17851         e.g. where a read transaction won't see updates made by a later write transaction.
17852
17853         Tests: webkit_unit_tests --gtest_filter='LevelDBDatabaseTest.Transaction*'
17854
17855         * platform/leveldb/LevelDBDatabase.cpp:
17856         (WebCore::LevelDBSnapshot::LevelDBSnapshot): New (but for now internal-only) wrapper type.
17857         (WebCore):
17858         (WebCore::LevelDBSnapshot::~LevelDBSnapshot): Release the leveldb::Snapshot.
17859         (WebCore::LevelDBDatabase::get): Optional snapshot argument, for use by transactions.
17860         (WebCore::LevelDBDatabase::createIterator): Ditto.
17861         * platform/leveldb/LevelDBDatabase.h:
17862         (leveldb):
17863         (WebCore):
17864         (LevelDBSnapshot):
17865         (LevelDBDatabase):
17866         * platform/leveldb/LevelDBTransaction.cpp:
17867         (WebCore::LevelDBTransaction::LevelDBTransaction): Initialize a snapshot.
17868         (WebCore::LevelDBTransaction::get):
17869         (WebCore::LevelDBTransaction::TransactionIterator::TransactionIterator):
17870         * platform/leveldb/LevelDBTransaction.h:
17871         (LevelDBTransaction):
17872
17873 2012-11-08  Brady Eidson  <beidson@apple.com>
17874
17875         Have NetworkProcess do the actual loading of subresources.
17876         https://bugs.webkit.org/show_bug.cgi?id=101640
17877
17878         Reviewed by Alexey Proskuryakov.
17879
17880         No new tests (No change in behavior in any configuration we test.)
17881
17882         * WebCore.exp.in:
17883         * loader/ResourceBuffer.h: Virtualize a few methods for ports to override.
17884
17885 2012-11-08  Huang Dongsung  <luxtella@company100.net>
17886
17887         Coordinated Graphics: Remove an invisible TiledBackingStore of CoordinatedGraphicsLayer.
17888         https://bugs.webkit.org/show_bug.cgi?id=101424
17889
17890         Reviewed by Noam Rosenthal.
17891
17892         This patch adds ASSERT to TextureMapperLayer while fixing this bug in
17893         WebKit2.
17894
17895         * platform/graphics/texmap/TextureMapperLayer.cpp:
17896         (WebCore::TextureMapperLayer::paintSelf):
17897
17898 2012-11-08  Sheriff Bot  <webkit.review.bot@gmail.com>
17899
17900         Unreviewed, rolling out r133945.
17901         http://trac.webkit.org/changeset/133945
17902         https://bugs.webkit.org/show_bug.cgi?id=101645
17903
17904         Numerous layout and unit test failures (Requested by
17905         jsbell|gardener on #webkit).
17906
17907         * bindings/scripts/CodeGeneratorV8.pm:
17908         (GenerateHeader):
17909         * bindings/scripts/test/V8/V8Float64Array.h:
17910         (WebCore::V8Float64Array::toNative):
17911         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
17912         (WebCore::V8TestActiveDOMObject::toNative):
17913         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
17914         (WebCore::V8TestCustomNamedGetter::toNative):
17915         * bindings/scripts/test/V8/V8TestEventConstructor.h:
17916         (WebCore::V8TestEventConstructor::toNative):
17917         * bindings/scripts/test/V8/V8TestEventTarget.h:
17918         (WebCore::V8TestEventTarget::toNative):
17919         * bindings/scripts/test/V8/V8TestException.h:
17920         (WebCore::V8TestException::toNative):
17921         * bindings/scripts/test/V8/V8TestInterface.h:
17922         (WebCore::V8TestInterface::toNative):
17923         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
17924         (WebCore::V8TestMediaQueryListListener::toNative):
17925         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
17926         (WebCore::V8TestNamedConstructor::toNative):
17927         * bindings/scripts/test/V8/V8TestNode.h:
17928         (WebCore::V8TestNode::toNative):
17929         * bindings/scripts/test/V8/V8TestObj.h:
17930         (WebCore::V8TestObj::toNative):
17931         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
17932         (WebCore::V8TestSerializedScriptValueInterface::toNative):
17933         * bindings/v8/NPV8Object.cpp:
17934         (WebCore::v8ObjectToNPObject):
17935         (WebCore::npCreateV8ScriptObject):
17936         * bindings/v8/V8Collection.h:
17937         (WebCore::toNativeCollection):
17938         * bindings/v8/V8DOMWindowShell.cpp:
17939         (WebCore::setIsolatedWorldField):
17940         (WebCore::V8DOMWindowShell::enteredIsolatedWorldContext):
17941         * bindings/v8/V8DOMWrapper.cpp:
17942         (WebCore::V8DOMWrapper::isWrapperOfType):
17943         * bindings/v8/V8DOMWrapper.h:
17944         (WebCore::V8DOMWrapper::setDOMWrapper):
17945         (WebCore::V8DOMWrapper::clearDOMWrapper):
17946         * bindings/v8/WrapperTypeInfo.h:
17947         (WebCore::toNative):
17948         (WebCore::toWrapperTypeInfo):
17949
17950 2012-11-01  Filip Pizlo  <fpizlo@apple.com>
17951
17952         JSC should infer when indexed storage contains only integers or doubles
17953         https://bugs.webkit.org/show_bug.cgi?id=98606
17954
17955         Reviewed by Oliver Hunt.
17956
17957         Just refactoring WebCore to pass 0 for the ArrayAllocationProfile*.
17958
17959         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
17960         (WebCore::JSCanvasRenderingContext2D::webkitLineDash):
17961         * bindings/js/JSClipboardCustom.cpp:
17962         (WebCore::JSClipboard::types):
17963         * bindings/js/JSDOMBinding.cpp:
17964         (WebCore::jsArray):
17965         * bindings/js/JSDOMBinding.h:
17966         (WebCore::jsArray):
17967         * bindings/js/JSInjectedScriptHostCustom.cpp:
17968         (WebCore::getJSListenerFunctions):
17969         * bindings/js/JSJavaScriptCallFrameCustom.cpp:
17970         (WebCore::JSJavaScriptCallFrame::scopeChain):
17971         * bindings/js/JSMessageEventCustom.cpp:
17972         (WebCore::JSMessageEvent::ports):
17973         * bindings/js/JSMutationCallbackCustom.cpp:
17974         (WebCore::JSMutationCallback::handleEvent):
17975         * bindings/js/JSWebGLRenderingContextCustom.cpp:
17976         (WebCore::toJS):
17977         (WebCore::JSWebGLRenderingContext::getAttachedShaders):
17978         (WebCore::JSWebGLRenderingContext::getSupportedExtensions):
17979         * bindings/js/SerializedScriptValue.cpp:
17980         (WebCore::CloneDeserializer::deserialize):
17981
17982 2012-11-08  Tiancheng Jiang  <tijiang@rim.com>
17983
17984         [BlackBerry] Update BB10 date input form.
17985         https://bugs.webkit.org/show_bug.cgi?id=101075
17986
17987         Reviewed by Rob Buis.
17988
17989         RIM PR 234531
17990         Internally Reviewed by Mike Fenton.
17991         Change date input appearance to button and hide caret when click on them.
17992
17993         * css/themeBlackBerry.css:
17994         (input[type="date"], input[type="datetime"], input[type="datetime-local"], input[type="time"], input[type="month"]):
17995
17996 2012-11-08  Adam Barth  <abarth@webkit.org>
17997
17998         [V8] Update callers to use the aligned pointer API rather than the deprecated unaligned pointer API
17999         https://bugs.webkit.org/show_bug.cgi?id=101519
18000
18001         Reviewed by Ojan Vafai.
18002
18003         There should be no change in behavior.  The new API is slightly faster
18004         than the old API (and apparently works correctly internally in V8).
18005
18006         * bindings/scripts/CodeGeneratorV8.pm:
18007         (GenerateHeader):
18008         * bindings/scripts/test/V8/V8Float64Array.h:
18009         (WebCore::V8Float64Array::toNative):
18010         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
18011         (WebCore::V8TestActiveDOMObject::toNative):
18012         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
18013         (WebCore::V8TestCustomNamedGetter::toNative):
18014         * bindings/scripts/test/V8/V8TestEventConstructor.h:
18015         (WebCore::V8TestEventConstructor::toNative):
18016         * bindings/scripts/test/V8/V8TestEventTarget.h:
18017         (WebCore::V8TestEventTarget::toNative):
18018         * bindings/scripts/test/V8/V8TestException.h:
18019         (WebCore::V8TestException::toNative):
18020         * bindings/scripts/test/V8/V8TestInterface.h:
18021         (WebCore::V8TestInterface::toNative):
18022         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
18023         (WebCore::V8TestMediaQueryListListener::toNative):
18024         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
18025         (WebCore::V8TestNamedConstructor::toNative):
18026         * bindings/scripts/test/V8/V8TestNode.h:
18027         (WebCore::V8TestNode::toNative):
18028         * bindings/scripts/test/V8/V8TestObj.h:
18029         (WebCore::V8TestObj::toNative):
18030         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
18031         (WebCore::V8TestSerializedScriptValueInterface::toNative):
18032         * bindings/v8/NPV8Object.cpp:
18033         (WebCore::v8ObjectToNPObject):
18034         (WebCore::npCreateV8ScriptObject):
18035         * bindings/v8/V8Collection.h:
18036         (WebCore::toNativeCollection):
18037         * bindings/v8/V8DOMWindowShell.cpp:
18038         (WebCore::setIsolatedWorldField):
18039         (WebCore::V8DOMWindowShell::enteredIsolatedWorldContext):
18040         * bindings/v8/V8DOMWrapper.cpp:
18041         (WebCore::V8DOMWrapper::isWrapperOfType):
18042         * bindings/v8/V8DOMWrapper.h:
18043         (WebCore::V8DOMWrapper::setDOMWrapper):
18044         (WebCore::V8DOMWrapper::clearDOMWrapper):
18045         * bindings/v8/WrapperTypeInfo.h:
18046         (WebCore::toNative):
18047         (WebCore::toWrapperTypeInfo):
18048
18049 2012-11-08  Erik Arvidsson  <arv@chromium.org>
18050
18051         setAttributeNode and friends should not have optional argument
18052         https://bugs.webkit.org/show_bug.cgi?id=101631
18053
18054         Reviewed by Ojan Vafai.
18055
18056         http://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-887236154
18057
18058         Fix getAttributeNode, getAttributeNodeNS and removeAttributeNode to make the Attr
18059         argument mandatory.
18060
18061         These used to throw DOMExceptions when an invalid type was passed instead of
18062         TypeError which is also a spec violation.
18063
18064         Updated existing tests.
18065
18066         * bindings/scripts/CodeGeneratorV8.pm:
18067         * dom/Element.cpp:
18068         * dom/Element.idl:
18069
18070 2012-11-08  Joshua Bell  <jsbell@chromium.org>
18071
18072         IndexedDB: Remove unused error handling clauses when writing to transaction
18073         https://bugs.webkit.org/show_bug.cgi?id=100700
18074
18075         Reviewed by Tony Chang.
18076
18077         Transactions are written into in-memory data structures. This can only fail if allocation
18078         fails, so "success" results are always returned. Change the return types to void, and delete
18079         all of the unreachable error handling code.
18080
18081         No new tests - just refactoring/dead code removal.
18082
18083         * Modules/indexeddb/IDBLevelDBBackingStore.cpp:
18084         (WebCore::putBool): Only write to transactions.
18085         (WebCore):
18086         (WebCore::putInt): Ditto.
18087         (WebCore::putVarInt): Ditto.
18088         (WebCore::putString): Ditto.
18089         (WebCore::putIDBKeyPath): Ditto.
18090         (WebCore::IDBLevelDBBackingStore::updateIDBDatabaseIntVersion):
18091         (WebCore::IDBLevelDBBackingStore::updateIDBDatabaseMetaData):
18092         (WebCore::deleteRange): Writes only to transaction, so can't fail.
18093         (WebCore::setMaxObjectStoreId):
18094         (WebCore::IDBLevelDBBackingStore::createObjectStore):
18095         (WebCore::getNewVersionNumber):
18096         (WebCore::IDBLevelDBBackingStore::putObjectStoreRecord):
18097         (WebCore::IDBLevelDBBackingStore::maybeUpdateKeyGeneratorCurrentNumber):
18098         (WebCore::setMaxIndexId):
18099         (WebCore::IDBLevelDBBackingStore::createIndex):
18100         (WebCore::IDBLevelDBBackingStore::putIndexDataForRecord):
18101         * platform/leveldb/LevelDBTransaction.cpp:
18102         (WebCore::LevelDBTransaction::set): Return type is void.
18103         (WebCore::LevelDBTransaction::put): Ditto.
18104         (WebCore::LevelDBTransaction::remove): Ditto.
18105         * platform/leveldb/LevelDBTransaction.h:
18106         (LevelDBTransaction):
18107
18108 2012-11-08  Ryosuke Niwa  <rniwa@webkit.org>
18109
18110         On Chromium, click-after-nested-block.html, focus_editable_html.html, and autoscroll.html
18111         hit assertion added in r133840
18112         https://bugs.webkit.org/show_bug.cgi?id=101576
18113
18114         Reviewed by Abhishek Arya.
18115
18116         Update layout before invalidating caret rect as needed.
18117         Existing tests cover this.
18118
18119         * editing/FrameSelection.cpp:
18120         (WebCore::FrameSelection::setCaretVisibility): Merged clearCaretRectIfNeeded.
18121         * editing/FrameSelection.h:
18122
18123 2012-11-08  Elliott Sprehn  <esprehn@chromium.org>
18124
18125         Skip frame owner disconnect when there's no frames
18126         https://bugs.webkit.org/show_bug.cgi?id=101619
18127
18128         Reviewed by Ojan Vafai.
18129
18130         Even when there's no subframes in the document we traverse down every
18131         subtree on Node removal looking for frames to disconnect. This patch
18132         checks document()->frame()->tree()->firstChild() to skip this traversal
18133         if there's no subframes.
18134
18135         No new tests, this just short circuits code for speed.
18136
18137         * dom/ContainerNodeAlgorithms.h:
18138         (WebCore::ChildFrameDisconnector::ChildFrameDisconnector):
18139
18140 2012-11-08  Erik Arvidsson  <arv@chromium.org>
18141
18142         Wrong error type is thrown for type errors in callbacks
18143         https://bugs.webkit.org/show_bug.cgi?id=101502
18144
18145         Reviewed by Adam Barth.
18146
18147         We should be throwing a TypeError and not a DOMException with code TYPE_MISMATCH_ERR.
18148
18149         http://www.w3.org/TR/WebIDL/#es-callback-function
18150
18151         Updated existing tests.
18152
18153         * bindings/scripts/CodeGeneratorJS.pm:
18154         * bindings/scripts/CodeGeneratorV8.pm:
18155         * bindings/scripts/test/JS/JSTestObj.cpp:
18156         * bindings/scripts/test/V8/V8TestObj.cpp:
18157
18158 2012-11-08  Andreas Kling  <kling@webkit.org>
18159
18160         4.68MB below RenderStyle::filter() on Membuster3.
18161         <http://webkit.org/b/101624>
18162         <rdar://problem/12663822>
18163
18164         Reviewed by Darin Adler.
18165
18166         Rename the non-const RenderStyle::filter() to mutableFilter() since using it causes us to detach
18167         from the rare non-inherited data (copy-on-write.)
18168         Most call sites were calling filter() on a RenderStyle* which was causing the bloat.
18169
18170         4.68MB progression on Membuster3.
18171
18172         * css/StyleResolver.cpp:
18173         (WebCore::StyleResolver::loadPendingSVGDocuments):
18174         (WebCore::StyleResolver::loadPendingShaders):
18175         * rendering/style/RenderStyle.h:
18176
18177 2012-11-08  Alexey Proskuryakov  <ap@apple.com>
18178
18179         Create loader/blackberry directory, because svn-apply cannot apply a patch that
18180         creates a directory and moves a file into it.
18181
18182         * loader/blackberry: Added.
18183
18184 2012-11-08  Geoffrey Garen  <ggaren@apple.com>
18185
18186         Mac build fix: Mark WidthCache.h 'private' so WebKit can use it.
18187
18188         Not reviewed.
18189
18190         * WebCore.xcodeproj/project.pbxproj:
18191
18192 2012-11-05  Geoffrey Garen  <ggaren@apple.com>
18193
18194         Optimized kerning and ligatures using caching
18195         https://bugs.webkit.org/show_bug.cgi?id=101269
18196
18197         Reviewed by Dan Bernstein.
18198
18199         Consider three kinds of text layout, and the value of caching for each:
18200
18201             (1) 1 layout of 100% unique words: small negative value.
18202
18203             (2) 1 layout of English prose: medium positive value.
18204
18205             (3) Many layouts of anything: extra-extra-large positive value.
18206
18207         Since we can't distinguish betwen these workflows a priori, we use statistical
18208         sampling. To minimize cost in (1) and maximize benefit in (2) and (3), we treat
18209         each cache access as a statistical sample, and use the cache in proportion to
18210         the observed probability of duplicate text measurement.
18211
18212         Benchmark results:
18213             plt3: 1% faster
18214             chapter-reflow-once-random: No change [*]
18215             chapter-reflow-once: 23% faster
18216             chapter-reflow-twice: 52% faster
18217             chapter-reflow-thrice: 68% faster
18218             chapter-reflow: 263% faster
18219             line-layout: 270% faster
18220
18221             [*] This is a stress test designed to make everything go wrong for
18222             caching. It does not represent real world content.
18223
18224         * GNUmakefile.list.am:
18225         * Target.pri:
18226         * WebCore.vcproj/WebCore.vcproj:
18227         * WebCore.xcodeproj/project.pbxproj:
18228         * platform/graphics/WidthCache.h: Added.
18229
18230         (WidthCache): Added a class that caches common word widths. This cache
18231         could cache more things or more cases in future -- but for now it seems
18232         to cover the common cases.
18233
18234         (SmallStringKey): Early profiling showed that allocating an AtomicString
18235         or String measurably added to the cost of the cache, so I added a custom
18236         string key that can be stored directly inside the table by value --
18237         empirically answering an age-old question with which Apple WebKit engineers
18238         seem to be obsessed.
18239
18240         (WebCore::WidthCache::SmallStringKey::capacity):
18241         (WebCore::WidthCache::SmallStringKey::SmallStringKey):
18242         (WebCore::WidthCache::SmallStringKey::characters):
18243         (WebCore::WidthCache::SmallStringKey::length):
18244         (WebCore::WidthCache::SmallStringKey::hash):
18245         (WebCore::WidthCache::SmallStringKey::isHashTableDeletedValue):
18246         (WebCore::WidthCache::SmallStringKey::isHashTableEmptyValue):
18247         (WebCore::WidthCache::SmallStringKeyHash::hash):
18248         (WebCore::WidthCache::SmallStringKeyHash::equal):
18249         (SmallStringKeyHash):
18250         (SmallStringKeyHashTraits):
18251         (WebCore::WidthCache::SmallStringKeyHashTraits::isEmptyValue): Ditto.
18252
18253         (WebCore::WidthCache::WidthCache):
18254         (WebCore::WidthCache::add): Separate out the "don't use the cache" case
18255         so the compiler can inline it separate, hopefully further reducing cases
18256         of (1).
18257
18258         (WebCore::WidthCache::addSlowCase): There's a little subtlety to the
18259         sampling policy here. Lots of different approaches are possible, and I
18260         just picked a simple one that seemed to work based on benchmarking. I'll
18261         point out some interesting sublteties I'm aware of here:
18262
18263             (*) Since we start at the min sampling rate, a font used for 20 words
18264             or fewer never allocates a cache. Anecdotally, some fonts seem to
18265             be used this way.
18266
18267             (*) When the sampling rate is x / y, sampling all x words in a row
18268             seems smart because some words may occur more commonly in relation to
18269             each other (such as 'each' and 'other'), and repeat workloads will
18270             lay out the same words in order. Intuitively, these are both reasons
18271             this policy may ramp up more effectively under load.
18272
18273             (*) I opted for linear back-off instead of, say, exponential back-off
18274             because we're not trying to back off to infinity -- just to our min
18275             sampling rate. Since we don't expect the cache to hit for every word,
18276             my guess is that exponential back-off would be too aggressive.
18277
18278             (*) Our "eviction" policy has an IQ of 1. I expect this is sufficient
18279             because it would be surprising to see a million unique words all used
18280             in the same document. (I would not like to play a Letterpress game
18281             against such a document.)
18282
18283         (WebCore::WidthCache::clear): Needed because a font can change, in which
18284         case we need to ditch its cache.
18285
18286         (WebCore::operator==): Needed for hashing.
18287
18288 2012-11-08  Andrey Kosyakov  <caseq@chromium.org>
18289
18290         Web Inspector: show statistics over selected frame range in Timeline's Frame mode
18291         https://bugs.webkit.org/show_bug.cgi?id=101593
18292
18293         Reviewed by Pavel Feldman.
18294
18295         - change status bar records counter wording to "N of M frames|records shown" depending on mode;
18296         - append average frame length and & stddev in frame mode;
18297         - expand the above to a popover that includes frame count, range duration and min/avg/max/stddev on frame length;
18298         - show frame bars & dividers iff selection range includes < 30 frames (drive-by)
18299
18300         * English.lproj/localizedStrings.js:
18301         * inspector/front-end/TimelineFrameController.js:
18302         (WebInspector.FrameStatistics):
18303         * inspector/front-end/TimelineModel.js:
18304         (WebInspector.TimelineModel.aggregateTimeByCategory):
18305         * inspector/front-end/TimelinePanel.js:
18306         (WebInspector.TimelinePanel.prototype.get statusBarItems):
18307         (WebInspector.TimelinePanel.prototype._createStatusBarItems.getAnchor):
18308         (WebInspector.TimelinePanel.prototype._createStatusBarItems):
18309         (WebInspector.TimelinePanel.prototype._updateRecordsCounter):
18310         (WebInspector.TimelinePanel.prototype._updateFrameStatistics):
18311         (WebInspector.TimelinePanel.prototype._showFrameStatistics):
18312         (WebInspector.TimelinePanel.prototype._updateFrameBars):
18313         (WebInspector.TimelinePanel.prototype._overviewModeChanged.set if):
18314         (WebInspector.TimelinePanel.prototype._overviewModeChanged):
18315         (WebInspector.TimelinePanel.prototype._refresh):
18316         * inspector/front-end/TimelinePresentationModel.js:
18317         (WebInspector.TimelinePresentationModel.prototype.):
18318         (WebInspector.TimelinePresentationModel.prototype.compareEndTime):
18319         (WebInspector.TimelinePresentationModel.prototype.filteredFrames):
18320         (WebInspector.TimelinePresentationModel.generatePopupContentForFrameStatistics):
18321         * inspector/front-end/timelinePanel.css:
18322         (.timeline-records-stats, .storage-application-cache-status, .storage-application-cache-connectivity):
18323         (.timeline-records-stats):
18324         (.timeline-frames-stats):
18325
18326 2012-11-08  Jakob Petsovits  <jpetsovits@rim.com>
18327
18328         [BlackBerry] Rework the API to use document coordinates
18329         https://bugs.webkit.org/show_bug.cgi?id=101608
18330         RIM PR 173292
18331
18332         Reviewed by Adam Treat.
18333
18334         Provide a better API for WebPage to relay.
18335         See Source/WebKit/blackberry/ChangeLog for details.
18336
18337         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
18338         (WebCore::MediaPlayerPrivate::getWindowScreenRect):
18339         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.h:
18340         (Platform):
18341         (BlackBerry):
18342         (MediaPlayerPrivate):
18343
18344 2012-11-08  Sheriff Bot  <webkit.review.bot@gmail.com>
18345
18346         Unreviewed, rolling out r133892.
18347         http://trac.webkit.org/changeset/133892
18348         https://bugs.webkit.org/show_bug.cgi?id=101617
18349
18350         Compile failures on mac, android, linux (Requested by
18351         jsbell|gardener on #webkit).
18352
18353         * bindings/v8/DOMDataStore.cpp:
18354         (WebCore::DOMDataStore::current):
18355         * bindings/v8/DOMWrapperWorld.h:
18356         (WebCore::DOMWrapperWorld::domDataStore):
18357         (WebCore::DOMWrapperWorld::DOMWrapperWorld):
18358         * bindings/v8/V8DOMWrapper.h:
18359         (WebCore::V8DOMWrapper::getCachedWrapper):
18360
18361 2012-11-08  Andrey Adaikin  <aandrey@chromium.org>
18362
18363         Web Inspector: [Canvas] UI iterations: image on the top, auto replay
18364         https://bugs.webkit.org/show_bug.cgi?id=101584
18365
18366         Reviewed by Pavel Feldman.
18367
18368         * inspector/front-end/CanvasProfileView.js:
18369         (WebInspector.CanvasProfileView):
18370         (WebInspector.CanvasProfileView.prototype._showTraceLog):
18371         (WebInspector.CanvasProfileView.prototype._onTraceLogItemClick):
18372         (WebInspector.CanvasProfileView.prototype._replayTraceLog.didReplayTraceLog):
18373         (WebInspector.CanvasProfileView.prototype._replayTraceLog):
18374         * inspector/front-end/canvasProfiler.css:
18375         (.canvas-trace-log):
18376         (#canvas-replay-image-container):
18377         (#canvas-replay-image):
18378
18379 2012-11-08  Wei Fanzhe  <whyer1@gmail.com>
18380
18381         While absolute positioning is put before the first flexitem, flexitems will move to a new line.
18382         https://bugs.webkit.org/show_bug.cgi?id=101294
18383
18384         Reviewed by Ojan Vafai.
18385
18386         This issue has to do with RenderFlexibleBox::computeNextFlexLine. When determing line breaks, the algorithm sees if 1) the total width exceeds lineBreakLength and 2) whether orderedChildren is non-empty.  But then, if the total width exceeds lineBreakLength and there's only absolutely positioned elemments in orderedChildren then the conditions are met and the algorithm mistakenly breaks the line. The solution is to see if orderedChildren collects at least a flex item. If it does, break the line.  
18387
18388         * rendering/RenderFlexibleBox.cpp:
18389         (WebCore::RenderFlexibleBox::computeNextFlexLine):
18390
18391 2012-11-08  Dimitri Glazkov  <dglazkov@chromium.org>
18392
18393         Unreviewed, rolling out r133429.
18394         http://trac.webkit.org/changeset/133429
18395         https://bugs.webkit.org/show_bug.cgi?id=101173
18396
18397         Speculative roll out, investigating perf regression.
18398
18399         * dom/ContextFeatures.cpp:
18400         * dom/ContextFeatures.h:
18401         * dom/Position.cpp:
18402         (WebCore::Position::Position):
18403         (WebCore::Position::findParent):
18404         * dom/TreeScope.cpp:
18405         (WebCore::TreeScope::getSelection):
18406         * html/HTMLTagNames.in:
18407         * html/shadow/HTMLContentElement.cpp:
18408         (WebCore::HTMLContentElement::contentTagName):
18409         * page/DOMWindow.idl:
18410
18411 2012-11-07  Emil A Eklund  <eae@chromium.org>
18412
18413         Fix enclosingLayoutRect calls in InlineFlowBox.h
18414         https://bugs.webkit.org/show_bug.cgi?id=101497
18415
18416         Reviewed by Levi Weintraub.
18417
18418         InlineFlowBox.h used to include LayoutTypesInlineMethods.h which
18419         overrid enclosingLayoutRect to call closingIntRect. When we
18420         removed the LayoutTypes abstraction we switched these to
18421         enclosingIntRect to preserve the behavior.
18422         This patch changes these back to enclosingLayoutRect which is
18423         the desired behavior.
18424
18425         Covered by existing tests.
18426
18427         * rendering/InlineFlowBox.h:
18428         (WebCore::InlineFlowBox::layoutOverflowRect):
18429         (WebCore::InlineFlowBox::visualOverflowRect):
18430
18431 2012-11-08  Philip Rogers  <pdr@google.com>
18432
18433         Remove unnecessary save/restore in SVGTextRunRenderingContext
18434         https://bugs.webkit.org/show_bug.cgi?id=101546
18435
18436         Reviewed by Andreas Kling.
18437
18438         This patch removes an unnecessary context save/restore SVGTextRunRenderingContext by
18439         refactoring the code to save off the stroke thickness.
18440
18441         No new tests as this is heavily covered by existing tests.
18442
18443         * rendering/svg/SVGTextRunRenderingContext.cpp:
18444         (WebCore::SVGTextRunRenderingContext::drawSVGGlyphs):
18445
18446 2012-11-08  Carlos Garcia Campos  <cgarcia@igalia.com>
18447
18448         [GTK] Clean up includes in GObject DOM bindings code
18449         https://bugs.webkit.org/show_bug.cgi?id=101077
18450
18451         Reviewed by Kentaro Hara.
18452
18453         Remove some headers included multiple times for the same file and
18454         fix consistency in the includes style.
18455
18456         * bindings/gobject/DOMObjectCache.cpp:
18457         * bindings/gobject/GObjectEventListener.cpp:
18458         * bindings/gobject/GObjectEventListener.h:
18459         * bindings/gobject/WebKitDOMBinding.cpp:
18460         * bindings/gobject/WebKitDOMBinding.h:
18461         * bindings/gobject/WebKitDOMEventTarget.cpp:
18462         * bindings/gobject/WebKitDOMEventTarget.h:
18463         * bindings/gobject/WebKitDOMEventTargetPrivate.h:
18464         (WebKit):
18465         * bindings/gobject/WebKitDOMObject.cpp:
18466         * bindings/gobject/WebKitDOMObject.h:
18467         * bindings/gobject/WebKitHTMLElementWrapperFactory.cpp:
18468         * bindings/gobject/WebKitHTMLElementWrapperFactory.h:
18469         * bindings/scripts/CodeGeneratorGObject.pm:
18470         (GenerateHeader):
18471         (GenerateFunction):
18472         (Generate):
18473         (WriteData):
18474         * bindings/scripts/test/GObject/WebKitDOMFloat64Array.cpp:
18475         * bindings/scripts/test/GObject/WebKitDOMFloat64Array.h:
18476         * bindings/scripts/test/GObject/WebKitDOMFloat64ArrayPrivate.h:
18477         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.cpp:
18478         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObject.h:
18479         * bindings/scripts/test/GObject/WebKitDOMTestActiveDOMObjectPrivate.h:
18480         * bindings/scripts/test/GObject/WebKitDOMTestCallback.cpp:
18481         * bindings/scripts/test/GObject/WebKitDOMTestCallback.h:
18482         * bindings/scripts/test/GObject/WebKitDOMTestCallbackPrivate.h:
18483         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.cpp:
18484         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetter.h:
18485         * bindings/scripts/test/GObject/WebKitDOMTestCustomNamedGetterPrivate.h:
18486         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.cpp:
18487         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructor.h:
18488         * bindings/scripts/test/GObject/WebKitDOMTestEventConstructorPrivate.h:
18489         * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.cpp:
18490         * bindings/scripts/test/GObject/WebKitDOMTestEventTarget.h:
18491         * bindings/scripts/test/GObject/WebKitDOMTestEventTargetPrivate.h:
18492         * bindings/scripts/test/GObject/WebKitDOMTestException.cpp:
18493         * bindings/scripts/test/GObject/WebKitDOMTestException.h:
18494         * bindings/scripts/test/GObject/WebKitDOMTestExceptionPrivate.h:
18495         * bindings/scripts/test/GObject/WebKitDOMTestInterface.cpp:
18496         * bindings/scripts/test/GObject/WebKitDOMTestInterface.h:
18497         * bindings/scripts/test/GObject/WebKitDOMTestInterfacePrivate.h:
18498         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.cpp:
18499         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListener.h:
18500         * bindings/scripts/test/GObject/WebKitDOMTestMediaQueryListListenerPrivate.h:
18501         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.cpp:
18502         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructor.h:
18503         * bindings/scripts/test/GObject/WebKitDOMTestNamedConstructorPrivate.h:
18504         * bindings/scripts/test/GObject/WebKitDOMTestNode.cpp:
18505         * bindings/scripts/test/GObject/WebKitDOMTestNode.h:
18506         * bindings/scripts/test/GObject/WebKitDOMTestNodePrivate.h:
18507         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
18508         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
18509         * bindings/scripts/test/GObject/WebKitDOMTestObjPrivate.h:
18510         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.cpp:
18511         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.h:
18512         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterfacePrivate.h:
18513
18514 2012-11-08  Dan Carney  <dcarney@google.com>
18515
18516         [V8] Main world should have one DOMDataStore
18517         https://bugs.webkit.org/show_bug.cgi?id=101470
18518
18519         Reviewed by Kentaro Hara.
18520
18521         The main world DOMWrapperWorld held onto a DOMDataStore that should
18522         never be used, as there is a static one optimized for speed in
18523         DOMDataStore.
18524
18525         No new tests. No change in functionality.
18526
18527         * bindings/v8/DOMDataStore.cpp:
18528         (WebCore::DOMDataStore::current):
18529         * bindings/v8/DOMWrapperWorld.h:
18530         (WebCore::DOMWrapperWorld::isolatedWorldDomDataStore):
18531         (WebCore::DOMWrapperWorld::DOMWrapperWorld):
18532         * bindings/v8/V8DOMWrapper.h:
18533         (WebCore::V8DOMWrapper::getCachedWrapper):
18534
18535 2012-11-08  Laszlo Gombos  <l.gombos@samsung.com>
18536
18537         [EFL] Remove non-variable options from the build system
18538         https://bugs.webkit.org/show_bug.cgi?id=101506
18539
18540         Reviewed by Kenneth Rohde Christiansen.
18541
18542         Remove WTF_USE_ICU_UNICODE, WTF_USE_CAIRO and WTF_USE_FREETYPE cmake variables
18543         as these are always set to const 1 and not really configurable.
18544
18545         Remove duplicate platform/graphics/cairo include path from
18546         PlatformEfl.cmake.
18547
18548         No new tests as there is no new functionality.
18549
18550         * PlatformEfl.cmake:
18551
18552 2012-11-08  KyungTae Kim  <ktf.kim@samsung.com>
18553
18554         Unused parameters on GraphicsLayerUpdater.cpp
18555         https://bugs.webkit.org/show_bug.cgi?id=101577
18556
18557         Reviewed by Kentaro Hara.
18558
18559         The parameter 'displayID' is not used when !USE(REQUEST_ANIMATION_FRAME_DISPLAY_MONITOR)
18560         Use UNUSED_PARAM macro for removing -Wunused-parameter warnings
18561
18562         * platform/graphics/GraphicsLayerUpdater.cpp:
18563         (WebCore::GraphicsLayerUpdater::GraphicsLayerUpdater):
18564         (WebCore::GraphicsLayerUpdater::screenDidChange):
18565
18566 2012-11-08  Alexander Pavlov  <apavlov@chromium.org>
18567
18568         Web Inspector: Add option to disable rulers (Elements panel)
18569         https://bugs.webkit.org/show_bug.cgi?id=101554
18570
18571         Reviewed by Pavel Feldman.
18572
18573         A new setting, showMetricsRulers, has been introduced (off by default, so users need to opt in to see the rulers).
18574         The setting value is passed into InspectorDOMAgent, down to the InspectorOverlayPage, which affects the drawGrid() and
18575         drawRulers() calls. As a side effect, the issue when the rulers were painted for elements having no renderers has been fixed.
18576
18577         No new tests, a UI change.
18578
18579         * English.lproj/localizedStrings.js: Add "Show rulers" string.
18580         * inspector/InspectorDOMAgent.cpp:
18581         (WebCore::InspectorDOMAgent::highlightConfigFromInspectorObject): Copy over the showRulers value.
18582         * inspector/InspectorOverlay.cpp:
18583         (WebCore::buildObjectForHighlight): Copy over the showRulers value.
18584         * inspector/InspectorOverlay.h:
18585         (HighlightConfig): Add |bool showRulers|.
18586         (WebCore::Highlight::Highlight): Initialize fields.
18587         (Highlight): Add |bool showRulers|.
18588         (WebCore::Highlight::setDataFromConfig):
18589         * inspector/InspectorOverlayPage.html:
18590         * inspector/front-end/DOMAgent.js: Make use of WebInspector.settings.showMetricsRulers when building the highlight DTO.
18591         * inspector/front-end/Settings.js: Add showMetricsRulers.
18592         * inspector/front-end/SettingsScreen.js:
18593         (WebInspector.GenericSettingsTab): Add "Show rulers" checkbox in the Elements panel section.
18594
18595 2012-11-08  Alexander Shalamov  <alexander.shalamov@intel.com>
18596
18597         Warn in the inspector console when using dpi and dpcm units outside of media="print"
18598         https://bugs.webkit.org/show_bug.cgi?id=100865
18599
18600         Reviewed by Kenneth Rohde Christiansen.
18601
18602         Added function that prints warning to inspector console whenever dpi or dpcm CSS units
18603         are used for screen media.
18604
18605         Test: fast/media/mq-resolution-dpi-dpcm-warning.html
18606
18607         * css/CSSStyleSheet.cpp:
18608         (WebCore::CSSStyleSheet::setMediaQueries):
18609         * css/MediaList.cpp:
18610         (WebCore):
18611         (WebCore::addResolutionWarningMessageToConsole):
18612         (WebCore::reportMediaQueryWarningIfNeeded):
18613         * css/MediaList.h:
18614         (WebCore):
18615         * css/MediaQueryMatcher.cpp:
18616         (WebCore::MediaQueryMatcher::matchMedia):
18617         * css/StyleSheetContents.cpp:
18618         (WebCore::StyleSheetContents::parserAppendRule):
18619
18620 2012-11-08  Eugene Klyuchnikov  <eustas.bug@gmail.com>
18621
18622         Web Inspector: Console: "time" and "timeEnd" should have same number of required arguments
18623         https://bugs.webkit.org/show_bug.cgi?id=101451
18624
18625         Reviewed by Yury Semikhatsky.
18626
18627         Solution: make console.time "title" parameter mandatory.
18628
18629         * page/Console.idl: Changed parameter specification.
18630
18631 2012-11-08  Vsevolod Vlasov  <vsevik@chromium.org>
18632
18633         Unreviewed fixed inspector frontend compilation
18634
18635         * inspector/front-end/DataGrid.js:
18636
18637 2012-11-08  Zeno Albisser  <zeno@webkit.org>
18638
18639         GraphicsSurfaceGLX needs to query the drawable for YInversion.
18640         https://bugs.webkit.org/show_bug.cgi?id=101472
18641
18642         After r133049 the WebGL content is now displayed upside down
18643         for the Qt port. We cannot just apply a generic rule, that
18644         the content needs to be flipped upside down.
18645         Instead we have to query GLX to tell us, if the drawable's
18646         framebuffer is y-inverted.
18647
18648         Reviewed by Kenneth Rohde Christiansen.
18649
18650         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
18651         (WebCore::GraphicsSurfacePrivate::textureIsYInverted):
18652         (GraphicsSurfacePrivate):
18653         (WebCore::GraphicsSurface::platformPaintToTextureMapper):
18654
18655 2012-11-08  Mike West  <mkwst@chromium.org>
18656
18657         Warn when parsing an invalid X-Frame-Options header.
18658         https://bugs.webkit.org/show_bug.cgi?id=101447
18659
18660         Reviewed by Adam Barth.
18661
18662         An 'X-Frame-Options' header that contains an invalid option (that is,
18663         neither 'DENY' nor 'SAMEORIGIN') is ignored. This patch adds a console
18664         warning to notify developers that they've made a mistake.
18665
18666         Test: http/tests/security/XFrameOptions/x-frame-options-invalid.html
18667
18668         * dom/Document.cpp:
18669         (WebCore::Document::processHttpEquiv):
18670             Move the request identifier generation out of the failure block in
18671             order to pass it into 'shouldInterruptLoadForXFrameOptions'. This
18672             ensures that the console message is properly tied to a request.
18673         * loader/FrameLoader.cpp:
18674         (WebCore::FrameLoader::shouldInterruptLoadForXFrameOptions):
18675         * loader/FrameLoader.h:
18676         (FrameLoader):
18677             'shouldInterruptLoadForXFrameOptions' now accepts a request
18678             identifier as a parameter, and generates a console message if the
18679             load is blocked.
18680         * loader/MainResourceLoader.cpp:
18681         (WebCore::MainResourceLoader::didReceiveResponse):
18682             Pass the request identifier into 'shouldInterruptLoadForXFrameOptions'.
18683
18684 2012-11-08  Eugene Klyuchnikov  <eustas.bug@gmail.com>
18685
18686         Web Inspector: Timeline: Improve time/timeEnd appearance.
18687         https://bugs.webkit.org/show_bug.cgi?id=100936
18688
18689         Reviewed by Yury Semikhatsky.
18690
18691         Changes:
18692         - time/timeEnd records should be top level records only in "glue" mode
18693         - time/timeEnd records should display "message" in record list / popover
18694         - glued records add aggregated statistics to root record
18695         - glued records do not reduce their origin self time
18696
18697         Test: inspector/timeline/timeline-time.html
18698
18699         * English.lproj/localizedStrings.js: Added "Message" string.
18700         * inspector/front-end/TimelinePresentationModel.js:
18701         (WebInspector.TimelinePresentationModel.Record): Added "origin" field.
18702
18703 2012-11-08  Yury Semikhatsky  <yurys@chromium.org>
18704
18705         Web Inspector: move front-end methods called from native part to InspectorFrontendAPI
18706         https://bugs.webkit.org/show_bug.cgi?id=101463
18707
18708         Reviewed by Vsevolod Vlasov.
18709
18710         Moved Web Inspector methods called from native code to InspectorFrontendAPI.
18711
18712         * inspector/InspectorClient.cpp:
18713         (WebCore::InspectorClient::doDispatchMessageOnFrontendPage):
18714         * inspector/InspectorFrontendHost.cpp:
18715         (WebCore::FrontendMenuProvider::create):
18716         (WebCore::FrontendMenuProvider::disconnect):
18717         (WebCore::FrontendMenuProvider::FrontendMenuProvider):
18718         (WebCore::FrontendMenuProvider::contextMenuItemSelected):
18719         (WebCore::FrontendMenuProvider::contextMenuCleared):
18720         (FrontendMenuProvider):
18721         (WebCore::InspectorFrontendHost::showContextMenu):
18722         * inspector/front-end/InspectorFrontendAPI.js:
18723         (InspectorFrontendAPI.loadCompleted):
18724         (InspectorFrontendAPI.contextMenuItemSelected):
18725         (InspectorFrontendAPI.contextMenuCleared):
18726         (InspectorFrontendAPI.dispatchMessageAsync):
18727         (InspectorFrontendAPI.dispatchMessage):
18728         * inspector/front-end/inspector.js:
18729
18730 2012-11-08  Kunihiko Sakamoto  <ksakamoto@chromium.org>
18731
18732         User can change a disabled select (drop down box)
18733         https://bugs.webkit.org/show_bug.cgi?id=100932
18734
18735         Reviewed by Kent Tamura.
18736
18737         <select> should not handle events if it's disabled.
18738
18739         Test: fast/forms/select/select-disabled.html
18740
18741         * html/HTMLSelectElement.cpp:
18742         (WebCore::HTMLSelectElement::defaultEventHandler):
18743
18744 2012-11-08  Alec Flett  <alecflett@chromium.org>
18745
18746         IndexedDB: Rename methods and remove dead code from IDBBackingStore
18747         https://bugs.webkit.org/show_bug.cgi?id=101488
18748
18749         Reviewed by Ojan Vafai.
18750
18751         In preparation for merging IDBBackingStore and IDBLevelDBBackingStore:
18752
18753         1) rename ObjectStoreRecordIdentifier to RecordIdentifier
18754         2) remove IDBBackingStore::forEachRecord and friends
18755         3) remove IDBBackingStore::Cursor::close, since it was an empty method.
18756
18757         No new tests as this is purely code cleanup.
18758
18759         * Modules/indexeddb/IDBBackingStore.cpp:
18760         (WebCore::IDBLevelDBBackingStore::getRecord):
18761         (WebCore):
18762         (WebCore::IDBLevelDBBackingStore::putRecord):
18763         (WebCore::IDBLevelDBBackingStore::createInvalidRecordIdentifier):
18764         (WebCore::IDBLevelDBBackingStore::deleteRecord):
18765         (WebCore::IDBLevelDBBackingStore::keyExistsInObjectStore):
18766         (WebCore::IDBLevelDBBackingStore::putIndexDataForRecord):
18767         (WebCore::IDBLevelDBBackingStore::deleteIndexDataForRecord):
18768         * Modules/indexeddb/IDBBackingStore.h:
18769         (WebCore::IDBBackingStore::RecordIdentifier::~RecordIdentifier):
18770         (IDBBackingStore):
18771         * Modules/indexeddb/IDBCursorBackendImpl.cpp:
18772         (WebCore::IDBCursorBackendImpl::close):
18773         * Modules/indexeddb/IDBIndexBackendImpl.cpp:
18774         (WebCore::IDBIndexBackendImpl::countInternal):
18775         (WebCore::IDBIndexBackendImpl::getInternal):
18776         (WebCore::IDBIndexBackendImpl::getKeyInternal):
18777         * Modules/indexeddb/IDBLevelDBBackingStore.h:
18778         (IDBLevelDBBackingStore):
18779         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
18780         (WebCore::IDBObjectStoreBackendImpl::getInternal):
18781         (WebCore):
18782         (WebCore::IDBObjectStoreBackendImpl::setIndexKeys):
18783         (WebCore::IDBObjectStoreBackendImpl::putInternal):
18784         (WebCore::IDBObjectStoreBackendImpl::deleteInternal):
18785         (WebCore::IDBObjectStoreBackendImpl::countInternal):
18786
18787 2012-11-07  Vsevolod Vlasov  <vsevik@chromium.org>
18788
18789         Web Inspector: console error after inspecting IndexedDB
18790         https://bugs.webkit.org/show_bug.cgi?id=101481
18791
18792         Reviewed by Pavel Feldman.
18793
18794         Added objectId nullity check to RemoteOBject::release.
18795         Drive-by added release for entry key and primaryKey.
18796
18797         * inspector/front-end/IndexedDBViews.js:
18798         (WebInspector.IDBDataView.prototype.clear):
18799         * inspector/front-end/RemoteObject.js:
18800         (WebInspector.RemoteObject.prototype.release):
18801
18802 2012-11-07  Vsevolod Vlasov  <vsevik@chromium.org>
18803
18804         Web Inspector: Migrate inspector IndexedDB support to frontend API.
18805         https://bugs.webkit.org/show_bug.cgi?id=101457
18806
18807         Reviewed by Pavel Feldman.
18808
18809         Migrated IndexedDB support to web facing IndexedDB API.
18810
18811         * inspector/Inspector.json:
18812         * inspector/InspectorIndexedDBAgent.cpp:
18813         (WebCore):
18814         (WebCore::assertIDBFactory):
18815         (WebCore::InspectorIndexedDBAgent::requestDatabaseNamesForFrame):
18816         (WebCore::InspectorIndexedDBAgent::requestDatabase):
18817         (WebCore::InspectorIndexedDBAgent::requestData):
18818         * inspector/front-end/IndexedDBModel.js:
18819         (WebInspector.IndexedDBModel.prototype.innerCallback):
18820         (WebInspector.IndexedDBModel.prototype._requestData):
18821         * inspector/front-end/IndexedDBViews.js:
18822         (WebInspector.IDBDataView.prototype._updateData.callback):
18823         (WebInspector.IDBDataView.prototype._updateData):
18824         (WebInspector.IDBDataGridNode):
18825         (WebInspector.IDBDataGridNode.prototype.createCell):
18826
18827 2012-08-20  Taiju Tsuiki  <tzik@chromium.org>
18828
18829         Web Inspector: Drop dimmed crumb handling
18830         https://bugs.webkit.org/show_bug.cgi?id=94457
18831
18832         Reviewed by Vsevolod Vlasov.
18833
18834         No new tests. Existing inspector test should work.
18835
18836         * inspector/front-end/ElementsPanel.js:
18837         (WebInspector.ElementsPanel.prototype.updateBreadcrumb):
18838         (WebInspector.ElementsPanel.prototype.updateBreadcrumbSizes):
18839         * inspector/front-end/breadcrumbList.css:
18840
18841 2012-11-07  Vsevolod Vlasov  <vsevik@chromium.org>
18842
18843         Web Inspector: Infinite loop in DataGrid::autoSizeColumn
18844         https://bugs.webkit.org/show_bug.cgi?id=101363
18845
18846         Reviewed by Pavel Feldman.
18847
18848         Test: inspector/datagrid-autosize.html
18849
18850         * inspector/front-end/DataGrid.js:
18851         (WebInspector.DataGrid.prototype._autoSizeWidths):
18852         (WebInspector.DataGrid.prototype.autoSizeColumns):
18853
18854 2012-11-07  Keishi Hattori  <keishi@webkit.org>
18855
18856         Implement week picking to calendar picker
18857         https://bugs.webkit.org/show_bug.cgi?id=101449
18858
18859         Reviewed by Kent Tamura.
18860
18861         This adds week picker mode to CalendarPicker.
18862
18863         No new tests. Tests will be added later when this feature is enabled in DRT.
18864
18865         * Resources/pagepopups/calendarPicker.css:
18866         (.month-mode .day):
18867         (.week-mode .available.day-selected.monday): Rounded corners around week selection.
18868         (.week-mode .available.day-selected.sunday): Ditto.
18869         (.week-mode .unavailable.day-selected):
18870         (.week-mode .unavailable.day-selected.monday):
18871         (.week-mode .unavailable.day-selected.sunday):
18872         (.week-mode .week-column.unavailable.day-selected):
18873         (.week-column): Hide week column unless in week mode.
18874         (.week-mode .week-column):
18875         * Resources/pagepopups/calendarPicker.js:
18876         (parseDateString): Support week string.
18877         (Week):
18878         (Week.parse): Parses "yyyy-Www" string.
18879         (Week.createFromDate): Creates Week containing datetime.
18880         (Week.createFromToday): Creates Week containing today.
18881         (Week.weekOneStartDateForYear): Returns the start date for the first week of year.
18882         (Week.numberOfWeeksInYear): Returns the number of weeks in year.
18883         (Week._numberOfWeeksSinceDate): Returns number of weeks since a date.
18884         (Week.prototype.equals): Returns true if the Weeks are the same.
18885         (Week.prototype.previous): Returns the previous Week.
18886         (Week.prototype.next): Returns the next Week.
18887         (Week.prototype.startDate): Returns start datetime of Week.
18888         (Week.prototype.endDate): Returns end datetime of Week.
18889         (Week.prototype.valueOf): Returns the milliseconds since epoch.
18890         (Week.prototype.toString): Returns ISO week string.
18891         (CalendarPicker): Add week picker mode.
18892         (CalendarPicker.prototype.showMonth): Use NavigationBehaviour instead of bools.
18893         (YearMonthController.prototype.attachTo): Fix bug.
18894         (YearMonthController.prototype.moveRelatively): Use new showMonth.
18895         (DaysTable.prototype.attachTo): Add week number column.
18896         (DaysTable.prototype._renderMonth): Render week numbers.
18897         (DaysTable.prototype.navigateToMonth): Render week numbers.
18898         (DaysTable.prototype.selectRange):
18899         (DaysTable.prototype._selectRangeAtPosition): Week number nodes have an positionX of -1.
18900         (DaysTable.prototype._maybeSetPreviousMonth):
18901         (DaysTable.prototype._maybeSetNextMonth):
18902         (MonthPickerDaysTable.prototype.selectRange):
18903         (MonthPickerDaysTable.prototype.selectRangeAndShowEntireRange):
18904         (MonthPickerDaysTable.prototype._handleKey):
18905         (WeekPickerDaysTable): Added.
18906         (WeekPickerDaysTable.prototype._markRangeAsSelected): Marks week as selected.
18907         (WeekPickerDaysTable.prototype.selectRange): Selects week.
18908         (WeekPickerDaysTable.prototype.selectRangeAndShowEntireRange): Selects week and navigate to show entire selection.
18909         (WeekPickerDaysTable.prototype._rangeForNode): Returns Week for node.
18910         (WeekPickerDaysTable.prototype._handleKey):
18911
18912 2012-11-07  Sheriff Bot  <webkit.review.bot@gmail.com>
18913
18914         Unreviewed, rolling out r133841.
18915         http://trac.webkit.org/changeset/133841
18916         https://bugs.webkit.org/show_bug.cgi?id=101542
18917
18918         Reverted patches were innocent (Requested by shinyak on
18919         #webkit).
18920
18921         * WebCore.exp.in:
18922         * dom/Element.cpp:
18923         (WebCore::Element::shadowPseudoId):
18924         * dom/Element.h:
18925         (Element):
18926         * dom/ElementRareData.cpp:
18927         (WebCore::ElementRareData::reportMemoryUsage):
18928         * dom/ElementRareData.h:
18929         (ElementRareData):
18930         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
18931         (WebCore::BaseMultipleFieldsDateAndTimeInputType::createShadowSubtree):
18932         * html/ColorInputType.cpp:
18933         (WebCore::ColorInputType::createShadowSubtree):
18934         * html/HTMLTextAreaElement.cpp:
18935         (WebCore::HTMLTextAreaElement::updatePlaceholderText):
18936         * html/RangeInputType.cpp:
18937         (WebCore::RangeInputType::createShadowSubtree):
18938         * html/TextFieldInputType.cpp:
18939         (WebCore::TextFieldInputType::createShadowSubtree):
18940         (WebCore::TextFieldInputType::updatePlaceholderText):
18941         * html/ValidationMessage.cpp:
18942         (WebCore::ValidationMessage::buildBubbleTree):
18943         * html/shadow/DateTimeEditElement.cpp:
18944         (WebCore::DateTimeEditBuilder::visitLiteral):
18945         (WebCore::DateTimeEditElement::DateTimeEditElement):
18946         * html/shadow/DateTimeFieldElement.cpp:
18947         (WebCore::DateTimeFieldElement::initialize):
18948         * html/shadow/DateTimeFieldElement.h:
18949         (DateTimeFieldElement):
18950         * html/shadow/PickerIndicatorElement.cpp:
18951         (WebCore::PickerIndicatorElement::PickerIndicatorElement):
18952         * html/track/TextTrackCue.cpp:
18953         (WebCore::TextTrackCueBox::TextTrackCueBox):
18954         (WebCore::TextTrackCue::updateDisplayTree):
18955         * testing/Internals.cpp:
18956         (WebCore::Internals::setShadowPseudoId):
18957
18958 2012-11-07  Simon Fraser  <simon.fraser@apple.com>
18959
18960         Fix EFL build, which has accelerated compositing disabled, by making
18961         repaintViewRectangle() const.
18962
18963         * rendering/RenderView.cpp:
18964         (WebCore::RenderView::repaintViewRectangle):
18965         * rendering/RenderView.h:
18966         (RenderView):
18967
18968 2012-11-07  Simon Fraser  <simon.fraser@apple.com>
18969
18970         constify ALL the repaint containers
18971         https://bugs.webkit.org/show_bug.cgi?id=101541
18972
18973         Reviewed by Beth Dakin.
18974
18975         Make all the RenderLayerModelObject* repaintContainer arguments const, since
18976         these member functions should have no need to mutate this object.
18977
18978         * WebCore.exp.in:
18979         * rendering/RenderBR.h:
18980         * rendering/RenderBlock.cpp:
18981         (WebCore::RenderBlock::selectionGapRectsForRepaint):
18982         (WebCore::RenderBlock::rectWithOutlineForRepaint):
18983         * rendering/RenderBlock.h:
18984         * rendering/RenderBox.cpp:
18985         (WebCore::RenderBox::outlineBoundsForRepaint):
18986         (WebCore::RenderBox::mapLocalToContainer):
18987         (WebCore::RenderBox::clippedOverflowRectForRepaint):
18988         (WebCore::RenderBox::computeRectForRepaint):
18989         * rendering/RenderBox.h:
18990         * rendering/RenderFlowThread.cpp:
18991         (WebCore::RenderFlowThread::repaintRectangleInRegions): Need to use a const_iterator.
18992         * rendering/RenderFlowThread.h:
18993         * rendering/RenderInline.cpp:
18994         (WebCore::RenderInline::clippedOverflowRectForRepaint):
18995         (WebCore::RenderInline::rectWithOutlineForRepaint):
18996         (WebCore::RenderInline::computeRectForRepaint):
18997         (WebCore::RenderInline::mapLocalToContainer):
18998         * rendering/RenderInline.h:
18999         * rendering/RenderListMarker.cpp:
19000         (WebCore::RenderListMarker::selectionRectForRepaint):
19001         * rendering/RenderListMarker.h:
19002         * rendering/RenderObject.cpp:
19003         (WebCore::RenderObject::repaintUsingContainer):
19004         (WebCore::RenderObject::repaintAfterLayoutIfNeeded):
19005         (WebCore::RenderObject::rectWithOutlineForRepaint):
19006         (WebCore::RenderObject::clippedOverflowRectForRepaint):
19007         (WebCore::RenderObject::computeRectForRepaint):
19008         (WebCore::RenderObject::computeFloatRectForRepaint):
19009         (WebCore::RenderObject::mapLocalToContainer):
19010         (WebCore::RenderObject::localToContainerQuad):
19011         (WebCore::RenderObject::localToContainerPoint):
19012         * rendering/RenderObject.h:
19013         (WebCore::RenderObject::selectionRectForRepaint):
19014         (WebCore::RenderObject::outlineBoundsForRepaint):
19015         * rendering/RenderReplaced.cpp:
19016         (WebCore::RenderReplaced::selectionRectForRepaint):
19017         (WebCore::RenderReplaced::clippedOverflowRectForRepaint):
19018         * rendering/RenderReplaced.h:
19019         * rendering/RenderTableCell.cpp:
19020         (WebCore::RenderTableCell::clippedOverflowRectForRepaint):
19021         (WebCore::RenderTableCell::computeRectForRepaint):
19022         * rendering/RenderTableCell.h:
19023         * rendering/RenderTableCol.cpp:
19024         (WebCore::RenderTableCol::clippedOverflowRectForRepaint):
19025         * rendering/RenderTableCol.h:
19026         * rendering/RenderTableRow.cpp:
19027         (WebCore::RenderTableRow::clippedOverflowRectForRepaint):
19028         * rendering/RenderTableRow.h:
19029         * rendering/RenderText.cpp:
19030         (WebCore::RenderText::clippedOverflowRectForRepaint):
19031         (WebCore::RenderText::selectionRectForRepaint):
19032         * rendering/RenderText.h:
19033         * rendering/RenderView.cpp:
19034         (WebCore::RenderView::mapLocalToContainer):
19035         (WebCore::RenderView::computeRectForRepaint):
19036         * rendering/RenderView.h:
19037         * rendering/svg/RenderSVGForeignObject.cpp:
19038         (WebCore::RenderSVGForeignObject::clippedOverflowRectForRepaint):
19039         (WebCore::RenderSVGForeignObject::computeFloatRectForRepaint):
19040         (WebCore::RenderSVGForeignObject::mapLocalToContainer):
19041         * rendering/svg/RenderSVGForeignObject.h:
19042         * rendering/svg/RenderSVGGradientStop.h:
19043         * rendering/svg/RenderSVGHiddenContainer.h:
19044         * rendering/svg/RenderSVGInline.cpp:
19045         (WebCore::RenderSVGInline::clippedOverflowRectForRepaint):
19046         (WebCore::RenderSVGInline::computeFloatRectForRepaint):
19047         (WebCore::RenderSVGInline::mapLocalToContainer):
19048         * rendering/svg/RenderSVGInline.h:
19049         * rendering/svg/RenderSVGModelObject.cpp:
19050         (WebCore::RenderSVGModelObject::clippedOverflowRectForRepaint):
19051         (WebCore::RenderSVGModelObject::computeFloatRectForRepaint):
19052         (WebCore::RenderSVGModelObject::mapLocalToContainer):
19053         (WebCore::RenderSVGModelObject::outlineBoundsForRepaint):
19054         * rendering/svg/RenderSVGModelObject.h:
19055         * rendering/svg/RenderSVGRoot.cpp:
19056         (WebCore::RenderSVGRoot::clippedOverflowRectForRepaint):
19057         (WebCore::RenderSVGRoot::computeFloatRectForRepaint):
19058         (WebCore::RenderSVGRoot::mapLocalToContainer):
19059         * rendering/svg/RenderSVGRoot.h:
19060         * rendering/svg/RenderSVGText.cpp:
19061         (WebCore::RenderSVGText::clippedOverflowRectForRepaint):
19062         (WebCore::RenderSVGText::computeRectForRepaint):
19063         (WebCore::RenderSVGText::computeFloatRectForRepaint):
19064         (WebCore::RenderSVGText::mapLocalToContainer):
19065         * rendering/svg/RenderSVGText.h:
19066         * rendering/svg/SVGRenderSupport.cpp:
19067         (WebCore::SVGRenderSupport::clippedOverflowRectForRepaint):
19068         (WebCore::SVGRenderSupport::computeFloatRectForRepaint):
19069         (WebCore::SVGRenderSupport::mapLocalToContainer):
19070         * rendering/svg/SVGRenderSupport.h:
19071         (SVGRenderSupport):
19072
19073 2012-11-07  Kent Tamura  <tkent@chromium.org>
19074
19075         [Chromium-win] Refactor date/time format conversion code in LocaleWin
19076         https://bugs.webkit.org/show_bug.cgi?id=101329
19077
19078         Reviewed by Kentaro Hara.
19079
19080         convertWindowsDateFormatToLDML and convertWindowsTimeFormatToLDML did
19081         similar jobs with different code. We can merge them into one function.
19082
19083         As for the date format conversion, we have tokenized a format string and
19084         stored token objects into a vector. We skip token object generation and
19085         generate a LDML-compliant pattern string during parsing.
19086
19087         No new tests. This should make no behavior changes and
19088         WebKit/chromium/tests/LocaleWinTest.cpp has test cases.
19089
19090         * platform/text/win/LocaleWin.cpp:
19091         (WebCore): Remove DateFormatToken, isFooSymbol, ensureShortDateTokens,
19092         convertWindowsDateFormatToLDML, mapCharacterToDateTimeFieldType, and
19093         convertWindowsTimeFormatToLDML.
19094         (WebCore::commitLiteralToken): Store the result to the specified StringBuilder.
19095         (WebCore::convertWindowsDateTimeFormat):
19096         Renamed from parseDateFormat, and supports time format symbols.
19097         (WebCore::LocaleWin::dateFormat): Use convertWindowsDateTimeFormat.
19098         (WebCore::LocaleWin::monthFormat): Ditto.
19099         (WebCore::LocaleWin::timeFormat): Ditto.
19100         (WebCore::LocaleWin::shortTimeFormat): Ditto.
19101         * platform/text/win/LocaleWin.h:
19102         (LocaleWin): Remove ensureShortDateTokens and m_shortDateTokens.
19103
19104 2012-11-07  Shinya Kawanaka  <shinyak@chromium.org>
19105
19106         Unreviewed, rolling out r133428 and r133749
19107         https://bugs.webkit.org/show_bug.cgi?id=101533
19108
19109         These patches might cause memory regression.
19110
19111         * WebCore.exp.in:
19112         * dom/Element.cpp:
19113         (WebCore::Element::shadowPseudoId):
19114         (WebCore):
19115         (WebCore::Element::setShadowPseudoId):
19116         * dom/Element.h:
19117         (Element):
19118         * dom/ElementRareData.cpp:
19119         (WebCore::ElementRareData::reportMemoryUsage):
19120         * dom/ElementRareData.h:
19121         (ElementRareData):
19122         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
19123         (WebCore::BaseMultipleFieldsDateAndTimeInputType::createShadowSubtree):
19124         * html/ColorInputType.cpp:
19125         (WebCore::ColorInputType::createShadowSubtree):
19126         * html/HTMLTextAreaElement.cpp:
19127         (WebCore::HTMLTextAreaElement::updatePlaceholderText):
19128         * html/RangeInputType.cpp:
19129         (WebCore::RangeInputType::createShadowSubtree):
19130         * html/TextFieldInputType.cpp:
19131         (WebCore::TextFieldInputType::createShadowSubtree):
19132         (WebCore::TextFieldInputType::updatePlaceholderText):
19133         * html/ValidationMessage.cpp:
19134         (WebCore::ValidationMessage::buildBubbleTree):
19135         * html/shadow/DateTimeEditElement.cpp:
19136         (WebCore::DateTimeEditBuilder::visitLiteral):
19137         (WebCore::DateTimeEditElement::DateTimeEditElement):
19138         * html/shadow/DateTimeFieldElement.cpp:
19139         (WebCore::DateTimeFieldElement::initialize):
19140         * html/shadow/DateTimeFieldElement.h:
19141         (DateTimeFieldElement):
19142         * html/shadow/PickerIndicatorElement.cpp:
19143         (WebCore::PickerIndicatorElement::PickerIndicatorElement):
19144         * html/track/TextTrackCue.cpp:
19145         (WebCore::TextTrackCueBox::TextTrackCueBox):
19146         (WebCore::TextTrackCue::updateDisplayTree):
19147         * testing/Internals.cpp:
19148         (WebCore::Internals::setShadowPseudoId):
19149
19150 2012-11-07  Ryosuke Niwa  <rniwa@webkit.org>
19151
19152         Crash in WebCore::RenderLayer::normalFlowList
19153         https://bugs.webkit.org/show_bug.cgi?id=101528
19154
19155         Reviewed by Simon Fraser.
19156
19157         Make sure the layout is up to date before re-computing the caret rect.
19158         Avoid doing the layout when the selection is cleared since we can always stop
19159         the blink timer in that case.
19160
19161         Unfortunately, we haven't found any reproduction of this crash yet.
19162
19163         * editing/FrameSelection.cpp:
19164         (WebCore::isNonOrphanedCaret):
19165         (WebCore::FrameSelection::localCaretRect):
19166         (WebCore::FrameSelection::updateAppearance):
19167
19168 2012-11-07  Adam Barth  <abarth@webkit.org>
19169
19170         [V8] IntrusiveDOMWrapperMap should be usable for more than just Nodes
19171         https://bugs.webkit.org/show_bug.cgi?id=101110
19172
19173         Reviewed by Kentaro Hara.
19174
19175         Hopefully the memory issues with this patch have been resolved by
19176         fixing bug 101525. This patch re-lands this patch again, hopefully for
19177         the last time.
19178
19179         * bindings/v8/DOMDataStore.cpp:
19180         (WebCore::DOMDataStore::weakCallback):
19181         * bindings/v8/DOMDataStore.h:
19182         (WebCore::DOMDataStore::wrapperIsStoredInObject):
19183         (WebCore::DOMDataStore::getWrapperFromObject):
19184         (WebCore::DOMDataStore::setWrapperInObject):
19185
19186 2012-11-07  KyungTae Kim  <ktf.kim@samsung.com>
19187
19188         Seam occurred between pieces of ShadowBlur on floating point zoom
19189         https://bugs.webkit.org/show_bug.cgi?id=101435
19190
19191         Reviewed by Simon Fraser.
19192
19193         When paint Shadow that doesn't have blurred edge on floating point zoom,
19194         pixel seam (pixel cracks) occurred between pieces of the ShadowBlur because of unaligned clip rect.
19195         So, enlarge the clipping area 1 pixel so that the fill does not bleed (due to antialiasing)
19196         even if the unaligned clip rect occurred.
19197
19198
19199         * platform/graphics/ShadowBlur.cpp:
19200         (WebCore::ShadowBlur::calculateLayerBoundingRect):
19201
19202 2012-11-07  Tim Horton  <timothy_horton@apple.com>
19203
19204         Repaint issues with -webkit-svg-shadow used on a container
19205         https://bugs.webkit.org/show_bug.cgi?id=65643
19206         <rdar://problem/7600532>
19207
19208         Reviewed by Simon Fraser.
19209
19210         SVG renderer repaint rects are currently expanded only by the shadow of
19211         the renderer itself; however, the area they need to repaint can be larger
19212         than that, if their parents also have shadows. We need to take into account
19213         parent's shadows (respecting transforms, as well).
19214
19215         clippedOverflowRectForRepaint already recurses upwards through the render tree,
19216         and ends up with a rect in layout coordinates, so we manually apply the shadow
19217         at each step (repaintRectInLocalCoordinatesExcludingSVGShadow was added to allow
19218         us to get the raw repaint rect without the shadow baked-in).
19219
19220         repaintRectInLocalCoordinates now includes shadows from all parents.
19221
19222         Also, RenderSVGRoot was clipping repaint rects to the viewport before applying
19223         shadows, so offscreen elements with on-screen shadows (applied by the root) would not paint the shadows.
19224         We can just swap the order of these things to correct this.
19225
19226         Tests: svg/css/parent-shadow-offscreen.svg, svg/css/root-shadow-offscreen.svg, svg/repaint/repaint-webkit-svg-shadow.svg
19227
19228         * rendering/RenderObject.cpp:
19229         (WebCore::RenderObject::addChild): Mark the child being added as having an SVG shadow if it is being added as a child of an element that does.
19230         (WebCore::RenderObject::styleDidChange): Mark the child being added as having an SVG shadow if its new style has a shadow.
19231         * rendering/svg/RenderSVGImage.cpp:
19232         (WebCore::RenderSVGImage::layout): Cache the repaint rect before intersecting it with the shadow.
19233         * rendering/svg/RenderSVGImage.h:
19234         (WebCore::RenderSVGImage::repaintRectInLocalCoordinatesExcludingSVGShadow): Return the cached repaint rect for the renderer without the shadow included.
19235         * rendering/svg/RenderSVGModelObject.cpp:
19236         (WebCore::RenderSVGModelObject::RenderSVGModelObject): Renderers do not have a shadow by default.
19237         * rendering/svg/RenderSVGModelObject.h:
19238         (WebCore::RenderSVGModelObject::repaintRectInLocalCoordinatesExcludingSVGShadow): Return the cached repaint rect for the renderer without the shadow included.
19239         (WebCore::RenderSVGModelObject::hasSVGShadow): Return whether or not the renderer has a shadow.
19240         (WebCore::RenderSVGModelObject::setHasSVGShadow): Set whether or not the renderer has a shadow.
19241         * rendering/svg/RenderSVGRoot.cpp:
19242         (WebCore::RenderSVGRoot::RenderSVGRoot):
19243         (WebCore::RenderSVGRoot::computeFloatRectForRepaint): Apply the shadow before clipping to the viewport, so we draw shadows for elements outside the viewport.
19244         (WebCore::RenderSVGRoot::updateCachedBoundaries): Cache the repaint rect before intersecting it with the shadow.
19245         * rendering/svg/RenderSVGRoot.h:
19246         (WebCore::RenderSVGRoot::hasSVGShadow): Return whether or not the renderer has a shadow.
19247         (WebCore::RenderSVGRoot::setHasSVGShadow): Set whether or not the renderer has a shadow.
19248         (WebCore::RenderSVGRoot::repaintRectInLocalCoordinatesExcludingSVGShadow): Return the cached repaint rect for the renderer without the shadow included.
19249         * rendering/svg/RenderSVGShape.cpp:
19250         (WebCore::RenderSVGShape::updateRepaintBoundingBox): Cache the repaint rect before intersecting it with the shadow.
19251         * rendering/svg/RenderSVGShape.h:
19252         (WebCore::RenderSVGShape::repaintRectInLocalCoordinatesExcludingSVGShadow): Return the cached repaint rect for the renderer without the shadow included.
19253         * rendering/svg/SVGRenderSupport.cpp:
19254         (WebCore::SVGRenderSupport::repaintRectForRendererInLocalCoordinatesExcludingSVGShadow): Return the cached repaint rect for the renderer without the shadow included.
19255         (WebCore::SVGRenderSupport::clippedOverflowRectForRepaint): Apply shadows as we walk through our parents, instead of only applying the renderer's own shadow.
19256         (WebCore::SVGRenderSupport::rendererHasSVGShadow): Return whether or not the renderer has a shadow.
19257         (WebCore::SVGRenderSupport::setRendererHasSVGShadow): Set whether or not the renderer has a shadow.
19258         (WebCore::SVGRenderSupport::intersectRepaintRectWithShadows): Walk through the element's parents, adding shadows to the repaint rect as we go, eventually
19259         transforming the repaint rect back into local coordinates.
19260         (WebCore::SVGRenderSupport::intersectRepaintRectWithResources): Don't add shadows by default, just other resources, so that we can cache repaint rects with and without shadows.
19261         * rendering/svg/SVGRenderSupport.h:
19262
19263 2012-11-07  Anders Carlsson  <andersca@apple.com>
19264
19265         Add RemoteGraphicsLayer class
19266         https://bugs.webkit.org/show_bug.cgi?id=101535
19267
19268         Reviewed by Simon Fraser.
19269
19270         * WebCore.exp.in:
19271         Export GraphicsLayer symbols required by WebKit2.
19272
19273         * WebCore.xcodeproj/project.pbxproj:
19274         Make GraphicsLayerFactory.h a private header.
19275
19276 2012-11-07  Adam Barth  <abarth@webkit.org>
19277
19278         [V8] Don't leak <img> elements in content scripts
19279         https://bugs.webkit.org/show_bug.cgi?id=101525
19280
19281         Reviewed by Ojan Vafai.
19282
19283         I found the leak that was causing a problem for bug 101110. We weren't
19284         filling in the derefObjectFunction for HTMLImageElements (and
19285         potentially some other types of elements). That manifests today as a
19286         memory leak in content scripts (which use the derefObjectFunction for
19287         nodes) and caused a memory leak after bug 101110 because we started
19288         using the derefObjectFunction in the main world as well.
19289
19290         This patch adds ASSERTs so that we won't make this mistake in the future.
19291
19292         * bindings/scripts/CodeGeneratorV8.pm:
19293         (GenerateNamedConstructorCallback):
19294         * bindings/v8/DOMDataStore.cpp:
19295         (WebCore::DOMDataStore::weakCallback):
19296         * bindings/v8/DOMWrapperMap.h:
19297         (WebCore::DOMWrapperMap::defaultWeakCallback):
19298         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
19299         (WebCore):
19300
19301 2012-11-07  Alec Flett  <alecflett@chromium.org>
19302
19303         IndexedDB: Prepare for IDBBackingStore merge by renaming IDBLevelDBBackingStore.cpp
19304         https://bugs.webkit.org/show_bug.cgi?id=101486
19305
19306         Reviewed by Ojan Vafai.
19307
19308         Rename IDBLevelDBBackingStore.cpp to IDBBackingStore.cpp in
19309         preparation for merging these classes. This will make the merge
19310         diffs sane. See https://bugs.webkit.org/show_bug.cgi?id=101415
19311         for the final goal.
19312
19313         No new tests, this is is just a rename and minor style fix.
19314
19315         * CMakeLists.txt:
19316         * GNUmakefile.list.am:
19317         * Modules/indexeddb/IDBBackingStore.cpp: Renamed from Source/WebCore/Modules/indexeddb/IDBLevelDBBackingStore.cpp.
19318         * WebCore.gypi:
19319         * WebCore.xcodeproj/project.pbxproj:
19320
19321 2012-11-07  Adam Barth  <abarth@webkit.org>
19322
19323         [V8] Prepare DOMDataStore to be able to store ScriptWrappable wrappers inline
19324         https://bugs.webkit.org/show_bug.cgi?id=101523
19325
19326         Unreviewed. Technically this patch hasn't been reviewed, but it is part
19327         of a patch that was reviewed by Kentaro Hara.
19328
19329         Sadly, my patch for bug 101110 triggered the regression again. This
19330         patch is a smaller incremental step towards the patch in bug 101110. It
19331         doesn't make that much sense on its own, but it will help me isolate
19332         the source of the regression.
19333
19334         * bindings/v8/DOMDataStore.h:
19335         (WebCore::DOMDataStore::get):
19336         (DOMDataStore):
19337         (WebCore::DOMDataStore::set):
19338         (WebCore::DOMDataStore::wrapperIsStoredInObject):
19339         (WebCore::DOMDataStore::getWrapperFromObject):
19340         (WebCore::DOMDataStore::setWrapperInObject):
19341
19342 2012-11-05  Ryosuke Niwa  <rniwa@webkit.org>
19343
19344         SimplifyMarkupCommand takes a disproportionally long time to run when there are many nodes to remove
19345         https://bugs.webkit.org/show_bug.cgi?id=101144
19346
19347         Reviewed by Enrica Casucci.
19348
19349         The bug was caused by attach() happening between each node removal. Since the command was trying
19350         to remove millions of node in some cases, attach()ing render objects for each node being reinserted
19351         imposed a huge runtime cost.
19352
19353         Fixed the bug by using lazy attach when removing nodes and avoiding calls to isContentEditable.
19354         Also remove all ancestors at once when they are direct child/parent of each other so that we don't
19355         remove an ancestor and then insert its child back only to remove it again in the next iteration.
19356
19357         No new tests since it doesn't change the asymptotic performance, and adding a new performance test for
19358         this specific case is not the worth the increase in the bot cycle time. I'll note that the email
19359         attached in the original radar bug (<rdar://problem/12179712>) took 100 seconds to open now only takes
19360         7 seconds to open on my MacPro.
19361
19362         * editing/AppendNodeCommand.cpp:
19363         (WebCore::AppendNodeCommand::doApply): Takes a flag indicating whether we should assume nodes are editable
19364         without calling isContentEditable or not.
19365         * editing/ApplyStyleCommand.cpp:
19366         (WebCore::ApplyStyleCommand::applyInlineStyleToPushDown): Update the style as later code requires render
19367         object.
19368         * editing/CompositeEditCommand.cpp:
19369         (WebCore::CompositeEditCommand::insertNodeBefore): Passes a flag to the command.
19370         (WebCore::CompositeEditCommand::removeNode): Ditto.
19371         (WebCore::CompositeEditCommand::removeNodePreservingChildren): Ditto.
19372         * editing/CompositeEditCommand.h:
19373         (CompositeEditCommand):
19374         * editing/DeleteSelectionCommand.cpp:
19375         (WebCore::DeleteSelectionCommand::removeNode): Takes a flag indicating whether we should assume nodes are
19376         editable without calling isContentEditable or not.
19377         * editing/DeleteSelectionCommand.h:
19378         (DeleteSelectionCommand):
19379         * editing/EditCommand.h:
19380         * editing/InsertIntoTextNodeCommand.cpp:
19381         (WebCore::InsertIntoTextNodeCommand::doApply): Update the layout when password echo is enabled since
19382         we need to have render objects for echoing.
19383         * editing/InsertNodeBeforeCommand.cpp:
19384         (WebCore::InsertNodeBeforeCommand::InsertNodeBeforeCommand): Ditto.
19385         (WebCore::InsertNodeBeforeCommand::doApply): Ditto; also always use lazy attach.
19386         (WebCore::InsertNodeBeforeCommand::doUnapply):
19387         * editing/InsertNodeBeforeCommand.h:
19388         (WebCore::InsertNodeBeforeCommand::create):
19389         (InsertNodeBeforeCommand):
19390         * editing/RemoveNodeCommand.cpp:
19391         (WebCore::RemoveNodeCommand::RemoveNodeCommand): Ditto about the flag.
19392         (WebCore::RemoveNodeCommand::doApply):
19393         * editing/RemoveNodeCommand.h:
19394         (WebCore::RemoveNodeCommand::create):
19395         (RemoveNodeCommand):
19396         * editing/RemoveNodePreservingChildrenCommand.cpp:
19397         (WebCore::RemoveNodePreservingChildrenCommand::RemoveNodePreservingChildrenCommand): Ditto.
19398         (WebCore::RemoveNodePreservingChildrenCommand::doApply):
19399         * editing/RemoveNodePreservingChildrenCommand.h:
19400         (WebCore::RemoveNodePreservingChildrenCommand::create):
19401         (RemoveNodePreservingChildrenCommand):
19402         * editing/SimplifyMarkupCommand.cpp:
19403         (WebCore::SimplifyMarkupCommand::doApply):
19404         (WebCore::SimplifyMarkupCommand::pruneSubsequentAncestorsToRemove): Added to optimize removals of multiple
19405         ancestors.
19406         * editing/SimplifyMarkupCommand.h:
19407         (SimplifyMarkupCommand):
19408
19409 2012-11-07  Sheriff Bot  <webkit.review.bot@gmail.com>
19410
19411         Unreviewed, rolling out r133810.
19412         http://trac.webkit.org/changeset/133810
19413         https://bugs.webkit.org/show_bug.cgi?id=101520
19414
19415         This patch made ws_single_peak_r regress by 15% (Requested by
19416         abarth on #webkit).
19417
19418         * bindings/v8/DOMDataStore.cpp:
19419         (WebCore::DOMDataStore::weakCallback):
19420         * bindings/v8/DOMDataStore.h:
19421         (WebCore::DOMDataStore::get):
19422         (WebCore::DOMDataStore::set):
19423         (DOMDataStore):
19424
19425 2012-11-07  Elliott Sprehn  <esprehn@chromium.org>
19426
19427         Clean up confused use of Document::renderer and renderView
19428         https://bugs.webkit.org/show_bug.cgi?id=101484
19429
19430         Reviewed by Ojan Vafai.
19431
19432         Document::renderer and Document::renderView are the same thing, but it seems
19433         people don't always realize it and check if document()->renderer() is a RenderView.
19434
19435         This patch cleans up usage of document()->renderer() and document()->renderView() and
19436         simplifies the code that was written without realizing they were the same thing.
19437
19438         No new tests, this is just a refactor.
19439
19440         * accessibility/AccessibilityRenderObject.cpp:
19441         (WebCore::AccessibilityRenderObject::visiblePositionForPoint): Lots of simplification.
19442         * dom/Element.cpp:
19443         (WebCore::Element::screenRect):
19444         (WebCore::Element::unregisterNamedFlowContentNode): Remove unneeded conditional.
19445         * editing/FrameSelection.cpp: Remove verbose casts.
19446         (WebCore::clearRenderViewSelection):
19447         (WebCore::FrameSelection::recomputeCaretRect):
19448         (WebCore::CaretBase::invalidateCaretRect):
19449         (WebCore::FrameSelection::focusedOrActiveStateChanged):
19450         * page/Frame.cpp:
19451         (WebCore::Frame::contentRenderer): Vastly simplified.
19452         * page/PrintContext.cpp: Remove verbose casts.
19453         (WebCore::PrintContext::computePageRects):
19454         (WebCore::PrintContext::computePageRectsWithPageSizeInternal):
19455         * page/wince/FrameWinCE.cpp:
19456         (WebCore::computePageRectsForFrame): Remove unreachable code.
19457         * rendering/RenderObject.cpp:
19458         (WebCore::RenderObject::maximalOutlineSize): Remove verbose cast.
19459
19460 2012-11-07  Adam Barth  <abarth@webkit.org>
19461
19462         [V8] IntrusiveDOMWrapperMap should be usable for more than just Nodes
19463         https://bugs.webkit.org/show_bug.cgi?id=101110
19464
19465         Reviewed by Kentaro Hara.
19466
19467         This patch generalizes our support for storing wrappers in DOM objects
19468         to be usable for more than just nodes. After this patch, any object
19469         with a ScriptWrappable base class will have its wrapper stored inline
19470         in the object in the main world.
19471
19472         * bindings/v8/DOMDataStore.cpp:
19473         (WebCore::DOMDataStore::weakCallback):
19474         * bindings/v8/DOMDataStore.h:
19475         (WebCore::DOMDataStore::get):
19476         (WebCore::DOMDataStore::set):
19477
19478 2012-11-07  Tiancheng Jiang  <tijiang@rim.com>
19479
19480         [BlackBerry] Update BB10 form theme.
19481         https://bugs.webkit.org/show_bug.cgi?id=100760
19482
19483         Reviewed by Rob Buis.
19484
19485         RIM PR 236997
19486         Internally Reviewed by Jakob Petsovits.
19487
19488         Set font family to fix DRT test fast/forms/input-type-text-min-width.html
19489
19490         * platform/blackberry/RenderThemeBlackBerry.cpp:
19491         (WebCore::RenderThemeBlackBerry::defaultGUIFont):
19492         (WebCore):
19493         (WebCore::RenderThemeBlackBerry::systemFont):
19494
19495 2012-11-07  Beth Dakin  <bdakin@apple.com>
19496
19497         https://bugs.webkit.org/show_bug.cgi?id=101303
19498         Fixed position elements that are out of view still end up forcing 
19499         non-threaded scrolling
19500         -and corresponding-
19501         <rdar://problem/12642222>
19502
19503         Reviewed by Simon Fraser.
19504
19505         Re-name hasNonLayerFixedObjects() to 
19506         hasVisibleSlowRepaintFixedObjects() and make it virtual. 
19507         * page/scrolling/ScrollingCoordinator.cpp:
19508         (WebCore::ScrollingCoordinator::hasVisibleSlowRepaintFixedObjects):
19509         (WebCore::ScrollingCoordinator::mainThreadScrollingReasons):
19510         * page/scrolling/ScrollingCoordinator.h:
19511         (ScrollingCoordinator):
19512
19513         Override hasVisibleSlowRepaintFixedObjects() to always return false. 
19514         We don't want to bother with the extra computation in the 
19515         ScrollingCoordinator implementation, though other ports might still 
19516         want it.
19517         * page/scrolling/mac/ScrollingCoordinatorMac.h:
19518         (WebCore::ScrollingCoordinatorMac::hasVisibleSlowRepaintFixedObjects):
19519         (ScrollingCoordinatorMac):
19520
19521         Make this function const so that we can call it from 
19522         requiresCompositingForPosition().
19523         * rendering/RenderLayerCompositor.cpp:
19524         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
19525
19526         Actually be thorough here and check if the fixed object has any 
19527         descendants that are visible in the view. If it does, then we do 
19528         want to composite the fixed object.
19529         (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
19530         * rendering/RenderLayerCompositor.h:
19531
19532 2012-11-07  Roger Fong  <roger_fong@apple.com>
19533
19534         Unreviewed. Style fix following r133262.
19535
19536         * html/HTMLMediaElement.cpp:
19537         (WebCore::HTMLMediaElement::clearMediaPlayer):
19538         * html/HTMLMediaElement.h:
19539         (HTMLMediaElement):
19540
19541 2012-11-07  Adam Barth  <abarth@webkit.org>
19542
19543         [V8] DOMWrapperMap doesn't need to use virtual functions
19544         https://bugs.webkit.org/show_bug.cgi?id=101494
19545
19546         Reviewed by Kentaro Hara.
19547
19548         DOMWrapperMap has only one subclass. There's no reason to use virtual functions.
19549
19550         * bindings/v8/DOMDataStore.cpp:
19551         (WebCore::DOMDataStore::DOMDataStore):
19552         * bindings/v8/DOMWrapperMap.h:
19553         (WebCore::DOMWrapperMap::DOMWrapperMap):
19554         (WebCore::DOMWrapperMap::get):
19555         (WebCore::DOMWrapperMap::set):
19556         (WebCore::DOMWrapperMap::clear):
19557         (WebCore::DOMWrapperMap::reportMemoryUsage):
19558         (WebCore::DOMWrapperMap::remove):
19559         (WebCore::DOMWrapperMap::defaultWeakCallback):
19560         * bindings/v8/V8NPObject.cpp:
19561         (WebCore::staticNPObjectMap):
19562
19563 2012-11-07  Alexandru Chiculita  <achicu@adobe.com>
19564
19565         [CSS Shaders] Remove the dependency on CustomFilterValidatedProgram from CustomFilterRenderer
19566         https://bugs.webkit.org/show_bug.cgi?id=101071
19567
19568         Reviewed by Dean Jackson.
19569
19570         I've removed the need to get a CustomFilterValidatedProgram from FilterEffectRenderer. It was only
19571         used to delay the compilation of the shader until it was really needed. Instead, the FilterEffectRenderer
19572         will directly get the compiled shader in the constructor. The callers that still want to avoid 
19573         compiling the shader until it is really needed can use the setCompiledProgram to inject the shader
19574         at a later time, before painting.
19575
19576         No new tests, the change is covered by the css3/filters/custom/ tests.
19577
19578         * platform/graphics/filters/CustomFilterConstants.h:
19579         * platform/graphics/filters/CustomFilterProgramInfo.h:
19580         * platform/graphics/filters/CustomFilterRenderer.cpp:
19581         (WebCore::CustomFilterRenderer::create):
19582         (WebCore::CustomFilterRenderer::CustomFilterRenderer):
19583         (WebCore::CustomFilterRenderer::premultipliedAlpha):
19584         (WebCore::CustomFilterRenderer::setCompiledProgram):
19585         (WebCore):
19586         (WebCore::CustomFilterRenderer::prepareForDrawing):
19587         (WebCore::CustomFilterRenderer::bindProgramAndBuffers):
19588         * platform/graphics/filters/CustomFilterRenderer.h:
19589         (WebCore):
19590         (CustomFilterRenderer):
19591         (WebCore::CustomFilterRenderer::compiledProgram):
19592         * platform/graphics/filters/FECustomFilter.cpp:
19593         (WebCore::FECustomFilter::FECustomFilter):
19594         (WebCore::FECustomFilter::prepareForDrawing):
19595         * platform/graphics/filters/FECustomFilter.h:
19596         (FECustomFilter):
19597
19598 2012-11-07  Adam Barth  <abarth@webkit.org>
19599
19600         [V8] IntrusiveDOMWrapperMap is no longer needed and can be deleted
19601         https://bugs.webkit.org/show_bug.cgi?id=101493
19602
19603         Reviewed by Kentaro Hara.
19604
19605         This patch is another incremental step towards landing the patch in bug
19606         101110. In this patch, we delete IntrusiveDOMWrapperMap, which is no
19607         longer needed.
19608
19609         * WebCore.gypi:
19610         * bindings/v8/DOMDataStore.cpp:
19611         (WebCore::DOMDataStore::DOMDataStore):
19612         (WebCore::DOMDataStore::~DOMDataStore):
19613         (WebCore::DOMDataStore::reportMemoryUsage):
19614         (WebCore::DOMDataStore::weakCallback):
19615         (WebCore):
19616         * bindings/v8/DOMDataStore.h:
19617         (WebCore::DOMDataStore::get):
19618         (WebCore::DOMDataStore::set):
19619         (DOMDataStore):
19620         * bindings/v8/IntrusiveDOMWrapperMap.h: Removed.
19621         * bindings/v8/V8GCController.cpp:
19622
19623 2012-11-07  Sudarsana Nagineni  <sudarsana.nagineni@intel.com>
19624
19625         [AC] glXChooseFBConfig() and glXGetVisualFromFBConfig() return values are leaking in GraphicsSurface
19626         https://bugs.webkit.org/show_bug.cgi?id=101475
19627
19628         Reviewed by Kenneth Rohde Christiansen.
19629
19630         Free the memory returned by glXChooseFBConfig and glXGetVisualFromFBConfig
19631         using XFree to avoid memory leaks.
19632
19633         No tests. No change in behavior.
19634
19635         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
19636         (WebCore::GraphicsSurfacePrivate::~GraphicsSurfacePrivate):
19637         (WebCore::GraphicsSurfacePrivate::createSurface):
19638
19639 2012-11-07  Fady Samuel  <fsamuel@chromium.org>
19640
19641         Autoresize should work even if turned on while the page is loading.
19642         https://bugs.webkit.org/show_bug.cgi?id=101380
19643
19644         Reviewed by David Levin.
19645
19646         Autoresize does not work in cases where it is turned on while loading.
19647         This patch addresses this by allowing autoSize to complete if it's turned on
19648         while loading and doing a final pass after loading.
19649
19650         * loader/FrameLoader.cpp:
19651         (WebCore::FrameLoader::checkCompleted):
19652         Adjust to call renamed function.
19653         * page/FrameView.cpp:
19654         (WebCore::FrameView::handleLoadCompleted):
19655         Rename function to encompass its expanded responsibilities (which include doing the final auto size after the load is completed).
19656         (WebCore::FrameView::autoSizeIfEnabled):
19657         Allow the size to shrink if autosize is adjusted while the page is loading.
19658         * page/FrameView.h:
19659         (FrameView):
19660         Renamed 'checkFlushDeferredRepaintsAfterLoadComplete' to 'handleLoadComplete'
19661
19662 2012-11-07  Philip Rogers  <pdr@google.com>
19663
19664         Skip SVG repaint tracking when parent container transforms
19665         https://bugs.webkit.org/show_bug.cgi?id=101177
19666
19667         Reviewed by Eric Seidel.
19668
19669         This patch skips child repaint rect checks when a parent container is transformed, leading
19670         to a 75% increase on the RoboHornet SVG benchmark:
19671             http://www.robohornet.org/#et=svg  (average of 2 runs)
19672             Before patch: 161.6ms
19673             After patch: 38.5ms
19674
19675         SVG transforms are relative to the local container which makes calculating an absolute
19676         repaint rect expensive because it requires multiplying the local repaint rect by each
19677         parent container's local transform. See SVGRenderSupport::computeFloatRectForRepaint
19678         as an example of this calculation.
19679
19680         This patch takes advantage of SVG's container rules: when a parent container's transform
19681         changes, all children must be repainted (there is no absolute positioning in SVG).
19682         SVGRenderSupport::checkForSVGRepaintDuringLayout has been added which checks for whether
19683         the parent transform changed before doing child repaint checks. A similar optimization is
19684         used in HTML (see RenderObject::checkForRepaintDuringLayout) where no repaint checking
19685         is done when the view is fully repainted.
19686
19687         This code is tested in existing tests.
19688
19689         * rendering/svg/RenderSVGContainer.cpp:
19690         (WebCore::RenderSVGContainer::layout):
19691         * rendering/svg/RenderSVGForeignObject.cpp:
19692         (WebCore::RenderSVGForeignObject::layout):
19693         * rendering/svg/RenderSVGImage.cpp:
19694         (WebCore::RenderSVGImage::layout):
19695         * rendering/svg/RenderSVGShape.cpp:
19696         (WebCore::RenderSVGShape::layout):
19697         * rendering/svg/RenderSVGText.cpp:
19698         (WebCore::RenderSVGText::layout):
19699         * rendering/svg/SVGRenderSupport.cpp:
19700         (WebCore::SVGRenderSupport::checkForSVGRepaintDuringLayout):
19701         (WebCore):
19702         * rendering/svg/SVGRenderSupport.h:
19703         (SVGRenderSupport):
19704
19705 2012-11-07  Chris Fleizach  <cfleizach@apple.com>
19706
19707         AX: Textfields don't get focus when navigated to from 'show all tabs' button
19708         https://bugs.webkit.org/show_bug.cgi?id=101369
19709
19710         Reviewed by Darin Adler.
19711
19712         When focus leaves a webpage, the webpage does not normally clear its focused node. When focus
19713         returns (through tab, or mouse click), then focus will be cleared and restored.
19714
19715         However, when focus is returned through accessibility means, focus is not cleared first, which
19716         means subsequent focus actions do nothing.
19717
19718         This fix will check if the focused node is the same as the node being focused, and if so, clear the focus first.
19719
19720         Making a layout test for this is not possible because it requires setting focus to something in the chrome, and then
19721         moving focus back to the webpage.
19722       
19723         * accessibility/AccessibilityRenderObject.cpp:
19724         (WebCore::AccessibilityRenderObject::setFocused):
19725
19726 2012-11-07  Adam Barth  <abarth@webkit.org>
19727
19728         [V8] We should hide the DOMWrapperMaps inside DOMDataStore
19729         https://bugs.webkit.org/show_bug.cgi?id=101430
19730
19731         Reviewed by Kentaro Hara.
19732
19733         This is yet another incremental step towards landing the patch in bug
19734         101110. In this patch, we hide the existence of DOMWrapperMaps inside
19735         DOMDataStore. In the process, we can remove V8DOMMap.cpp.
19736
19737         * UseV8.cmake:
19738         * WebCore.gypi:
19739         * bindings/v8/DOMDataStore.h:
19740         (WebCore::DOMDataStore::set):
19741         * bindings/v8/DOMWrapperWorld.h:
19742         * bindings/v8/ScriptProfiler.cpp:
19743         * bindings/v8/SerializedScriptValue.cpp:
19744         (WebCore::neuterBinding):
19745         * bindings/v8/V8DOMMap.cpp: Removed.
19746         * bindings/v8/V8DOMMap.h: Removed.
19747         * bindings/v8/V8DOMWindowShell.cpp:
19748         * bindings/v8/V8DOMWrapper.h:
19749         (WebCore::V8DOMWrapper::getCachedWrapper):
19750         (WebCore::V8DOMWrapper::setWrapperClass):
19751         (WebCore::V8DOMWrapper::setJSWrapperForDOMObject):
19752         * bindings/v8/V8NPObject.cpp:
19753         * bindings/v8/WorkerContextExecutionProxy.cpp:
19754         * bindings/v8/WorkerScriptController.cpp:
19755
19756 2012-11-07  Varun Jain  <varunjain@chromium.org>
19757
19758         Add new gesture type, LongTap, which is basically the completion of a GestureLongPress
19759         https://bugs.webkit.org/show_bug.cgi?id=101385
19760
19761         Reviewed by Adam Barth.
19762
19763         Test: Only creating the new enum. No functionality change, hence no tests required.
19764
19765         * platform/PlatformEvent.h:
19766
19767 2012-11-05  Emil A Eklund  <eae@chromium.org>
19768
19769         Remove LayoutTypes abstraction
19770         https://bugs.webkit.org/show_bug.cgi?id=93050
19771
19772         Reviewed by Levi Weintraub.
19773
19774         Remove LayoutTypes abstraction and rename FractionalLayout* to
19775         Layout* now that all platforms use the FractionalLayout version
19776         (albeit with different fractions).
19777
19778         No new tests, no change in functionality.
19779
19780         * CMakeLists.txt:
19781         * GNUmakefile.list.am:
19782         * Target.pri:
19783         * WebCore.exp.in:
19784         * WebCore.gypi:
19785         * WebCore.vcproj/WebCore.vcproj:
19786         * WebCore.xcodeproj/project.pbxproj:
19787         * accessibility/AccessibilityNodeObject.cpp:
19788         * accessibility/AccessibilityNodeObject.h:
19789         * accessibility/AccessibilityObject.h:
19790         * accessibility/AccessibilityRenderObject.h:
19791         * css/LengthFunctions.cpp:
19792         * css/LengthFunctions.h:
19793         * dom/Document.h:
19794         * dom/DocumentMarkerController.h:
19795         * dom/ElementRareData.h:
19796         * dom/MouseRelatedEvent.h:
19797         * dom/Node.h:
19798         * dom/Touch.h:
19799         * editing/FrameSelection.cpp:
19800         * editing/FrameSelection.h:
19801         * editing/RenderedPosition.h:
19802         * html/HTMLAreaElement.h:
19803         * inspector/InspectorOverlay.h:
19804         * inspector/InspectorTimelineAgent.h:
19805         * inspector/TimelineRecordFactory.cpp:
19806         * inspector/TimelineRecordFactory.h:
19807         * loader/cache/CachedImage.h:
19808         * page/FocusController.h:
19809         * page/FrameView.h:
19810         * page/Page.h:
19811         * page/SpatialNavigation.cpp:
19812         * page/SpatialNavigation.h:
19813         * platform/FractionalLayoutUnit.h: Removed.
19814         * platform/LayoutUnit.h: Copied from Source/WebCore/platform/FractionalLayoutUnit.h.
19815         * platform/Length.h:
19816         * platform/PopupMenuClient.h:
19817         * platform/animation/AnimationUtilities.h:
19818         * platform/graphics/FloatPoint.cpp:
19819         * platform/graphics/FloatPoint.h:
19820         * platform/graphics/FloatRect.cpp:
19821         * platform/graphics/FloatRect.h:
19822         * platform/graphics/FloatSize.cpp:
19823         * platform/graphics/FloatSize.h:
19824         * platform/graphics/FractionalLayoutBoxExtent.cpp: Removed.
19825         * platform/graphics/FractionalLayoutBoxExtent.h: Removed.
19826         * platform/graphics/FractionalLayoutPoint.h: Removed.
19827         * platform/graphics/FractionalLayoutRect.cpp: Removed.
19828         * platform/graphics/FractionalLayoutRect.h: Removed.
19829         * platform/graphics/FractionalLayoutSize.h: Removed.
19830         * platform/graphics/GraphicsLayer.cpp:
19831         * platform/graphics/GraphicsLayerAnimation.cpp:
19832         * platform/graphics/IntRect.cpp:
19833         * platform/graphics/IntRect.h:
19834         * platform/graphics/LayoutBoxExtent.cpp: Copied from Source/WebCore/platform/graphics/FractionalLayoutBoxExtent.cpp.
19835         * platform/graphics/LayoutBoxExtent.h: Copied from Source/WebCore/platform/graphics/FractionalLayoutBoxExtent.h.
19836         * platform/graphics/LayoutPoint.h: Copied from Source/WebCore/platform/graphics/FractionalLayoutPoint.h.
19837         * platform/graphics/LayoutRect.cpp: Copied from Source/WebCore/platform/graphics/FractionalLayoutRect.cpp.
19838         * platform/graphics/LayoutRect.h: Copied from Source/WebCore/platform/graphics/FractionalLayoutRect.h.
19839         * platform/graphics/LayoutSize.h: Copied from Source/WebCore/platform/graphics/FractionalLayoutSize.h.
19840         * platform/graphics/MediaPlayer.h:
19841         * platform/graphics/filters/CustomFilterOperation.h:
19842         * platform/graphics/filters/CustomFilterParameterList.h:
19843         * platform/graphics/filters/FilterOperation.h:
19844         * platform/graphics/filters/FilterOperations.h:
19845         * platform/graphics/filters/ValidatedCustomFilterOperation.cpp:
19846         * platform/graphics/filters/ValidatedCustomFilterOperation.h:
19847         * platform/graphics/qt/FractionalLayoutPointQt.cpp: Removed.
19848         * platform/graphics/qt/FractionalLayoutRectQt.cpp: Removed.
19849         * platform/graphics/qt/FractionalLayoutSizeQt.cpp: Removed.
19850         * platform/graphics/qt/LayoutPointQt.cpp: Copied from Source/WebCore/platform/graphics/qt/FractionalLayoutPointQt.cpp.
19851         * platform/graphics/qt/LayoutRectQt.cpp: Added.
19852         * platform/graphics/qt/LayoutSizeQt.cpp: Copied from Source/WebCore/platform/graphics/qt/FractionalLayoutSizeQt.cpp.
19853         * platform/graphics/transforms/TransformOperations.h:
19854         * platform/graphics/transforms/TransformState.h:
19855         * platform/graphics/transforms/TransformationMatrix.cpp:
19856         * platform/graphics/transforms/TransformationMatrix.h:
19857         * rendering/AutoTableLayout.h:
19858         * rendering/ColumnInfo.h:
19859         * rendering/ExclusionShapeInsideInfo.h:
19860         * rendering/FilterEffectRenderer.h:
19861         * rendering/FixedTableLayout.h:
19862         * rendering/GapRects.h:
19863         * rendering/HitTestResult.h:
19864         * rendering/HitTestingTransformState.cpp:
19865         * rendering/HitTestingTransformState.h:
19866         * rendering/InlineFlowBox.cpp:
19867         * rendering/LayoutRepainter.cpp:
19868         * rendering/LayoutRepainter.h:
19869         * rendering/LayoutState.h:
19870         * rendering/LayoutTypes.h:
19871         * rendering/LayoutTypesInlineMethods.h:
19872         * rendering/PaintInfo.h:
19873         * rendering/RenderBlock.cpp:
19874         * rendering/RenderBlock.h:
19875         * rendering/RenderBlockLineLayout.cpp:
19876         * rendering/RenderBox.cpp:
19877         * rendering/RenderBox.h:
19878         * rendering/RenderBoxModelObject.cpp:
19879         * rendering/RenderBoxModelObject.h:
19880         * rendering/RenderDeprecatedFlexibleBox.cpp:
19881         * rendering/RenderFieldset.cpp:
19882         * rendering/RenderFlexibleBox.cpp:
19883         * rendering/RenderFlowThread.cpp:
19884         * rendering/RenderGeometryMap.h:
19885         * rendering/RenderImageResource.h:
19886         * rendering/RenderInline.cpp:
19887         * rendering/RenderLayer.cpp:
19888         * rendering/RenderLayerFilterInfo.h:
19889         * rendering/RenderLineBoxList.cpp:
19890         * rendering/RenderListMarker.cpp:
19891         * rendering/RenderMarquee.cpp:
19892         * rendering/RenderMenuList.h:
19893         * rendering/RenderMultiColumnBlock.cpp:
19894         * rendering/RenderMultiColumnSet.cpp:
19895         * rendering/RenderNamedFlowThread.cpp:
19896         * rendering/RenderObject.cpp:
19897         * rendering/RenderObject.h:
19898         * rendering/RenderOverflow.h:
19899         * rendering/RenderRegion.cpp:
19900         * rendering/RenderReplaced.cpp:
19901         * rendering/RenderTable.cpp:
19902         * rendering/RenderTable.h:
19903         * rendering/RenderText.cpp:
19904         * rendering/RenderThemeChromiumCommon.cpp:
19905         * rendering/RenderThemeChromiumCommon.h:
19906         * rendering/RenderTreeAsText.cpp:
19907         * rendering/RenderTreeAsText.h:
19908         * rendering/RenderView.h:
19909         * rendering/style/NinePieceImage.h:
19910         * rendering/style/RenderStyle.h:
19911         * rendering/style/ShadowData.cpp:
19912         * rendering/style/ShadowData.h:
19913         * rendering/style/StyleCachedImageSet.h:
19914         * rendering/style/StyleImage.h:
19915         * rendering/svg/SVGRenderSupport.h:
19916
19917 2012-11-07  Alexandru Chiculita  <achicu@adobe.com>
19918
19919         CoordinatedGraphicsArgumentCoders should use ValidatedCustomFitlerOperation instead
19920         https://bugs.webkit.org/show_bug.cgi?id=100905
19921
19922         Reviewed by Noam Rosenthal.
19923
19924         Added getters for the validated shaders, so that platform code could extract them.
19925
19926         No new tests, just added two getters.
19927
19928         * platform/graphics/filters/CustomFilterValidatedProgram.h:
19929         (WebCore::CustomFilterValidatedProgram::validatedVertexShader):
19930         (WebCore::CustomFilterValidatedProgram::validatedFragmentShader):
19931         (CustomFilterValidatedProgram):
19932
19933 2012-11-07  Joshua Bell  <jsbell@chromium.org>
19934
19935         IndexedDB: Assertion failure with open() within upgradeneeded
19936         https://bugs.webkit.org/show_bug.cgi?id=96947
19937
19938         Reviewed by Dimitri Glazkov.
19939
19940         Postpone creation of the "pending second half open" until the version change
19941         transaction has started.
19942
19943         Test: storage/indexeddb/unblocked-version-changes.html
19944
19945         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
19946         (WebCore::IDBDatabaseBackendImpl::setIntVersionInternal):
19947         (WebCore::IDBDatabaseBackendImpl::runIntVersionChangeTransaction):
19948         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
19949         (IDBDatabaseBackendImpl):
19950         * Modules/indexeddb/IDBDatabaseCallbacks.h:
19951
19952 2012-11-07  Alexandru Chiculita  <achicu@adobe.com>
19953
19954         [CSS Shaders] Add CustomFilterMeshBoxType to ValidatedCustomFilterOperation
19955         https://bugs.webkit.org/show_bug.cgi?id=100890
19956
19957         Reviewed by Dean Jackson.
19958
19959         Added the CustomFilterMeshBoxType parameter to the ValidatedCustomFilterOperation.
19960
19961         No new tests, this parameter is not used in the implementation yet.
19962
19963         * platform/graphics/filters/ValidatedCustomFilterOperation.cpp:
19964         (WebCore::ValidatedCustomFilterOperation::ValidatedCustomFilterOperation):
19965         * platform/graphics/filters/ValidatedCustomFilterOperation.h:
19966         (WebCore::ValidatedCustomFilterOperation::create):
19967         (WebCore::ValidatedCustomFilterOperation::meshBoxType):
19968         (WebCore::ValidatedCustomFilterOperation::operator==):
19969         (ValidatedCustomFilterOperation):
19970         * rendering/FilterEffectRenderer.cpp:
19971         (WebCore::createCustomFilterEffect):
19972         * rendering/RenderLayer.cpp:
19973         (WebCore::RenderLayer::computeFilterOperations):
19974
19975 2012-11-07  Sergio Villar Senin  <svillar@igalia.com>
19976
19977         [Qt] Implement deleteCookie() for persistent storage
19978         https://bugs.webkit.org/show_bug.cgi?id=101272
19979
19980         Reviewed by Jocelyn Turcotte.
19981
19982         Individual cookies were never persistently cleared as the
19983         deleteCookie() virtual method was not implemented for persistent
19984         storage. That's why cookies were only deleted for the current
19985         session.
19986
19987         * platform/qt/CookieJarQt.cpp:
19988         (WebCore::SharedCookieJarQt::deleteCookie):
19989         (WebCore): added deleteCookie() implementation for persistent
19990         storage.
19991         * platform/qt/CookieJarQt.h:
19992         (SharedCookieJarQt):
19993
19994 2012-11-07  Shinya Kawanaka  <shinyak@chromium.org>
19995
19996         [Shadow] Style should update when 'pseudo' attribute is dynamically updated
19997         https://bugs.webkit.org/show_bug.cgi?id=100918
19998
19999         Reviewed by Dimitri Glazkov.
20000
20001         When 'pseudo' attribute is changed and its element is in ShadowTree, we enable the styleShouldRecalc flag.
20002
20003         It would be fast if we have a set of pseudo attribute style value in RuleFeatureSet,
20004         but it might consume a lot of memory.
20005
20006         Test: fast/dom/shadow/pseudo-attribute-dynamic.html
20007
20008         * dom/Element.cpp:
20009         (WebCore::Element::attributeChanged):
20010
20011 2012-11-07  Ulan Degenbaev  <ulan@chromium.org>
20012
20013         [V8] WebKit sends unnecessary low memory notification when running memory benchmarks
20014         https://bugs.webkit.org/show_bug.cgi?id=101474
20015
20016         Reviewed by Kentaro Hara.
20017
20018         Do not send low memory notification to V8 when most of memory usage
20019         comes from V8 heap and not DOM objects. In this case V8 can schedule GC
20020         itself more optimally.
20021
20022         * bindings/v8/V8GCController.cpp:
20023         (WebCore::V8GCController::checkMemoryUsage):
20024
20025 2012-11-07  Allan Sandfeld Jensen  <allan.jensen@digia.com>
20026
20027         [Qt] Open link in this window action
20028         https://bugs.webkit.org/show_bug.cgi?id=101226
20029
20030         Reviewed by Simon Hausmann.
20031
20032         Adds the action to the WebCore context-menu controller.
20033
20034         * page/ContextMenuController.cpp:
20035         (WebCore::ContextMenuController::contextMenuItemSelected):
20036         (WebCore::ContextMenuController::checkOrEnableIfNeeded):
20037         * platform/ContextMenuItem.h:
20038         * platform/LocalizedStrings.h:
20039         * platform/qt/LocalizedStringsQt.cpp:
20040         (WebCore::contextMenuItemTagOpenLinkInThisWindow):
20041
20042 2012-11-07  Andrey Adaikin  <aandrey@chromium.org>
20043
20044         Web Inspector: [Canvas] closure compiler fixes
20045         https://bugs.webkit.org/show_bug.cgi?id=101459
20046
20047         Reviewed by Pavel Feldman.
20048
20049         * inspector/InjectedScriptCanvasModuleSource.js:
20050         (.):
20051
20052 2012-11-07  Sheriff Bot  <webkit.review.bot@gmail.com>
20053
20054         Unreviewed, rolling out r133712.
20055         http://trac.webkit.org/changeset/133712
20056         https://bugs.webkit.org/show_bug.cgi?id=101461
20057
20058         Broke fast/forms/time* tests on chromium-win. (Requested by
20059         mkwst on #webkit).
20060
20061         * platform/text/win/LocaleWin.cpp:
20062         (WebCore::DateFormatToken::DateFormatToken):
20063         (DateFormatToken):
20064         (WebCore):
20065         (WebCore::isEraSymbol):
20066         (WebCore::isYearSymbol):
20067         (WebCore::isMonthSymbol):
20068         (WebCore::isDaySymbol):
20069         (WebCore::commitLiteralToken):
20070         (WebCore::parseDateFormat):
20071         (WebCore::LocaleWin::ensureShortDateTokens):
20072         (WebCore::convertWindowsDateFormatToLDML):
20073         (WebCore::mapCharacterToDateTimeFieldType):
20074         (WebCore::convertWindowsTimeFormatToLDML):
20075         (WebCore::LocaleWin::dateFormat):
20076         (WebCore::LocaleWin::monthFormat):
20077         (WebCore::LocaleWin::timeFormat):
20078         (WebCore::LocaleWin::shortTimeFormat):
20079         * platform/text/win/LocaleWin.h:
20080         (LocaleWin):
20081
20082 2012-11-07  Vsevolod Vlasov  <vsevik@chromium.org>
20083
20084         Web Inspector: [Regression] Editing formatted source should not be allowed.
20085         https://bugs.webkit.org/show_bug.cgi?id=101355
20086
20087         Reviewed by Pavel Feldman.
20088
20089         * inspector/front-end/JavaScriptSourceFrame.js:
20090         (WebInspector.JavaScriptSourceFrame.prototype._onFormattedChanged):
20091         * inspector/front-end/UISourceCodeFrame.js:
20092         (WebInspector.UISourceCodeFrame.prototype._onFormattedChanged):
20093
20094 2012-11-07  Shinya Kawanaka  <shinyak@chromium.org>
20095
20096         [Shadow] Use setPseudo() instead of setShadowPseudoId().
20097         https://bugs.webkit.org/show_bug.cgi?id=101306
20098
20099         Reviewed by Kent Tamura.
20100
20101         We would like to remove setShadowPseudoId() and use setPseudo() instead, since ShadowDOM spec now has
20102         'pseudo' attribute.
20103
20104         We change all setShadowPseudoId() invocation to setPseudo() invocation. Also, when AtomicString is not
20105         constructed with AtomicStringFromLiteral, we use it.
20106
20107         No new tests, refactoring.
20108
20109         * WebCore.exp.in:
20110         * dom/Element.cpp:
20111         * dom/Element.h:
20112         (Element):
20113         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
20114         (WebCore::BaseMultipleFieldsDateAndTimeInputType::createShadowSubtree):
20115         * html/ColorInputType.cpp:
20116         (WebCore::ColorInputType::createShadowSubtree):
20117         * html/HTMLTextAreaElement.cpp:
20118         (WebCore::HTMLTextAreaElement::updatePlaceholderText):
20119         * html/RangeInputType.cpp:
20120         (WebCore::RangeInputType::createShadowSubtree):
20121         * html/TextFieldInputType.cpp:
20122         (WebCore::TextFieldInputType::createShadowSubtree):
20123         (WebCore::TextFieldInputType::updatePlaceholderText):
20124         * html/ValidationMessage.cpp:
20125         (WebCore::ValidationMessage::buildBubbleTree):
20126         * html/shadow/DateTimeEditElement.cpp:
20127         (WebCore::DateTimeEditBuilder::visitLiteral):
20128         (WebCore::DateTimeEditElement::DateTimeEditElement):
20129         * html/shadow/DateTimeFieldElement.cpp:
20130         (WebCore::DateTimeFieldElement::initialize):
20131         * html/shadow/DateTimeFieldElement.h:
20132         (DateTimeFieldElement):
20133         * html/shadow/PickerIndicatorElement.cpp:
20134         (WebCore::PickerIndicatorElement::PickerIndicatorElement):
20135         * html/track/TextTrackCue.cpp:
20136         (WebCore::TextTrackCueBox::TextTrackCueBox):
20137         (WebCore::TextTrackCue::updateDisplayTree):
20138         * testing/Internals.cpp:
20139         (WebCore::Internals::setShadowPseudoId):
20140
20141 2012-11-07  Andrey Adaikin  <aandrey@chromium.org>
20142
20143         Web Inspector: [Canvas] Save CanvasGradient objects state for a replay
20144         https://bugs.webkit.org/show_bug.cgi?id=101432
20145
20146         Reviewed by Pavel Feldman.
20147
20148         Save CanvasGradient resource state for a subsequent replay. The gradient's state is modified by the gradient.addColorStop() call.
20149
20150         Test: inspector/profiler/canvas2d/canvas2d-gradient-capturing.html
20151
20152         * inspector/InjectedScriptCanvasModuleSource.js:
20153         (.):
20154
20155 2012-11-07  Vsevolod Vlasov  <vsevik@chromium.org>
20156
20157         Web Inspector: [Regression] Snippets evaluations should not appear in Sources tab of navigator.
20158         https://bugs.webkit.org/show_bug.cgi?id=101354
20159
20160         Reviewed by Pavel Feldman.
20161
20162         * inspector/front-end/DebuggerScriptMapping.js:
20163         * inspector/front-end/NetworkUISourceCodeProvider.js:
20164         (WebInspector.NetworkUISourceCodeProvider.prototype._parsedScriptSource):
20165         * inspector/front-end/Script.js:
20166         (WebInspector.Script.prototype.isSnippet):
20167         * inspector/front-end/ScriptSnippetModel.js:
20168         (WebInspector.ScriptSnippetModel.prototype._snippetIdForSourceURL):
20169
20170 2012-11-07  Dan Carney  <dcarney@google.com>
20171
20172         [V8] Cleanup V8DOMWrapper::getCachedWrapper
20173         https://bugs.webkit.org/show_bug.cgi?id=100853
20174
20175         Reviewed by Adam Barth.
20176
20177         Slight cleanup. Removed redundant branch.
20178
20179         No new tests. No change in functionality.
20180
20181         * bindings/v8/V8DOMWrapper.h:
20182         (WebCore::V8DOMWrapper::getCachedWrapper):
20183
20184 2012-11-07  Simon Hausmann  <simon.hausmann@digia.com>
20185
20186         [Qt] Unreviewed trivial build fix adapting to QtMultimedia API changes
20187
20188         The QtMultimedia namespace is now called QMultimedia and
20189         QtMultimedia::MetaData is now QMediaMetaData.
20190
20191         * platform/graphics/qt/MediaPlayerPrivateQt.cpp:
20192         (WebCore::MediaPlayerPrivateQt::supportsType):
20193         (WebCore::MediaPlayerPrivateQt::totalBytes):
20194
20195 2012-11-07  Christophe Dumez  <christophe.dumez@intel.com>
20196
20197         Add replaceWithLiteral() method to WTF::String
20198         https://bugs.webkit.org/show_bug.cgi?id=101257
20199
20200         Reviewed by Benjamin Poulain.
20201
20202         Substitute String::replace() calls by String::replaceWithLiteral() where
20203         adequate, for efficiency.
20204
20205         No new tests, no behavior change.
20206
20207         * dom/Node.cpp:
20208         (WebCore::Node::showNode):
20209         * editing/EditingStyle.cpp:
20210         (WebCore::StyleChange::extractTextStyles):
20211         * editing/MarkupAccumulator.cpp:
20212         (WebCore::MarkupAccumulator::appendQuotedURLAttributeValue):
20213         * html/HTMLAnchorElement.cpp:
20214         (WebCore::HTMLAnchorElement::setSearch):
20215         * loader/FormSubmission.cpp:
20216         (WebCore::appendMailtoPostFormDataToURL):
20217         * platform/network/soup/ProxyResolverSoup.cpp:
20218         (soupProxyResolverWkSetProperty):
20219         * plugins/PluginView.cpp:
20220         (WebCore::makeURL):
20221         * rendering/InlineTextBox.cpp:
20222         (WebCore::InlineTextBox::showBox):
20223         * xml/XSLTProcessor.cpp:
20224         (WebCore::transformTextStringToXHTMLDocumentString):
20225
20226 2012-11-07  Kenneth Rohde Christiansen  <kenneth@webkit.org>
20227
20228         Remove support for "desktop-width" in the viewport meta tag
20229         https://bugs.webkit.org/show_bug.cgi?id=101217
20230
20231         Reviewed by Gyuyoung Kim.
20232
20233         This has been removed from the CSS Device Adaptation spec, and
20234         should be safe to remove as it is not documented anywhere (neither
20235         in blog posts).
20236
20237         The viewport meta should only support the legacy features.
20238
20239         * dom/ViewportArguments.cpp:
20240         (WebCore::computeViewportAttributes):
20241         (WebCore::findSizeValue):
20242         (WebCore::findScaleValue):
20243         (WebCore::findUserScalableValue):
20244         * dom/ViewportArguments.h:
20245
20246 2012-11-07  Dominik Röttsches  <dominik.rottsches@intel.com>
20247
20248         [EFL] Fix execution of exif-orientation-image-document.html on EFL Wk2 bot
20249         https://bugs.webkit.org/show_bug.cgi?id=101343
20250
20251         Reviewed by Kenneth Rohde Christiansen.
20252
20253         Add Cairo to the list of backends that support shouldRespectImageOrientation.
20254
20255         No new tests, fixes exif-orientation-image-document.html.
20256
20257         * rendering/RenderObject.cpp:
20258         (WebCore::RenderObject::shouldRespectImageOrientation):
20259
20260 2012-11-06  Yury Semikhatsky  <yurys@chromium.org>
20261
20262         Console not displaying all properties of an Object once native Constructor overwritten
20263         https://bugs.webkit.org/show_bug.cgi?id=101320
20264
20265         Reviewed by Pavel Feldman.
20266
20267         Use Object instance from {}.constructor when formatting inspector messages in the
20268         injected script. Otherwise inspected page may overwrite Object value and break inspector.
20269
20270         Test: inspector/console/console-Object-overwritten.html
20271
20272         * inspector/InjectedScriptSource.js:
20273
20274 2012-11-06  Keishi Hattori  <keishi@webkit.org>
20275
20276         Implement month picking to calendar picker
20277         https://bugs.webkit.org/show_bug.cgi?id=101333
20278
20279         Reviewed by Kent Tamura.
20280
20281         This adds month picker mode to CalendarPicker.
20282
20283         No new tests. Tests will be added later when this feature is enabled in DRT.
20284
20285         * Resources/pagepopups/calendarPicker.css:
20286         (.month-mode .day): Remove rounded corners when in month mode.
20287         * Resources/pagepopups/calendarPicker.js:
20288         (Month.createFromToday): Creates month containing today.
20289         (CalendarPicker): Set this.selectionConstructor to Day or Month depending on the mode. Create DayTables or MonthPickerDaysTable depending on the mode.
20290         (CalendarPicker.prototype.handleToday):
20291         (CalendarPicker.prototype._layoutButtons):
20292         (DaysTable.prototype._renderMonth): Set element.dataset.monthValue for all date nodes.
20293         (DaysTable.prototype._markRangeAsSelected): Marks all day nodes in range as selected.
20294         (DaysTable.prototype.selectRange): Selects a day.
20295         (DaysTable.prototype.selectRangeAndShowEntireRange): Same as selectRange.
20296         (DaysTable.prototype._selectRangeContainingNode):
20297         (DaysTable.prototype._rangeForNode): Returns Day for node.
20298         (DaysTable.prototype.startDate): Start datetime of visible date range. This value is inclusive.
20299         (DaysTable.prototype.endDate): End datetime of visible date range. This value is exclusive.
20300         (DaysTable.prototype._handleKey):
20301         (MonthPickerDaysTable):
20302         (MonthPickerDaysTable.prototype._markRangeAsSelected): Marks all day nodes in range as selected.
20303         (MonthPickerDaysTable.prototype.selectRange): Selects month. If month is not visible, navigates to that month.
20304         (MonthPickerDaysTable.prototype.selectRangeAndShowEntireRange): Selects month. Navigates to the month.
20305         (MonthPickerDaysTable.prototype._rangeForNode): Returns Month for node.
20306         (MonthPickerDaysTable.prototype._handleKey): Arrow keys simply move the selection forwards or backwards.
20307
20308 2012-11-06  Dan Beam  <dbeam@chromium.org>
20309
20310         Enable REQUEST_AUTOCOMPLETE for chromium port
20311         https://bugs.webkit.org/show_bug.cgi?id=101376
20312
20313         Reviewed by Adam Barth.
20314
20315         Added a runtime enabled feature to control whether HTMLFormElement#requestAutocomplete is visible from JavaScript.
20316
20317         * bindings/generic/RuntimeEnabledFeatures.cpp:
20318         (WebCore):
20319         * bindings/generic/RuntimeEnabledFeatures.h:
20320         (RuntimeEnabledFeatures):
20321
20322         Added a binding from RuntimeEnabledFeatures that triggers [V8EnabledAtRuntime=requestAutocomplete].
20323
20324         (WebCore::RuntimeEnabledFeatures::requestAutocompleteEnabled):
20325
20326         Added a getter to WebCore to ask whether the runtime flag requestAutocomplete is on.
20327
20328         (WebCore::RuntimeEnabledFeatures::setRequestAutocompleteEnabled):
20329
20330         Added a setter to WebCore to affect the runtime flag requestAutocomplete.
20331
20332         * html/HTMLFormElement.idl:
20333
20334         Wrapped commonly grouped features in an #if defined(ENABLED_REQUEST_AUTOCOMPLETE) block and added [V8EnableAtRuntime]
20335         so these features can be changed with a command line switch in the chromium port.
20336
20337 2012-11-06  Adam Barth  <abarth@webkit.org>
20338
20339         [V8] Unify setJSWrapperForDOMObject and setJSWrapperForDOMNode
20340         https://bugs.webkit.org/show_bug.cgi?id=101422
20341
20342         Reviewed by Kentaro Hara.
20343
20344         This patch is another incremental step towards the patch in Bug 10110.
20345         In this step, we unify setJSWrapperForDOMObject and
20346         setJSWrapperForDOMNode.
20347
20348         * bindings/scripts/CodeGeneratorV8.pm:
20349         (GenerateHeader):
20350         (GenerateNormalAttrGetter):
20351         (GenerateConstructorCallback):
20352         (GenerateNamedConstructorCallback):
20353         (GenerateToV8Converters):
20354         * bindings/scripts/test/V8/V8Float64Array.h:
20355         (WebCore::V8Float64Array::wrap):
20356         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
20357         (WebCore::V8TestActiveDOMObject::wrap):
20358         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
20359         (WebCore::V8TestCustomNamedGetter::wrap):
20360         * bindings/scripts/test/V8/V8TestEventConstructor.h:
20361         (WebCore::V8TestEventConstructor::wrap):
20362         * bindings/scripts/test/V8/V8TestEventTarget.h:
20363         (WebCore::V8TestEventTarget::wrap):
20364         * bindings/scripts/test/V8/V8TestException.h:
20365         (WebCore::V8TestException::wrap):
20366         * bindings/scripts/test/V8/V8TestInterface.h:
20367         (WebCore::V8TestInterface::wrap):
20368         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
20369         (WebCore::V8TestMediaQueryListListener::wrap):
20370         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
20371         (WebCore::V8TestNamedConstructor::wrap):
20372         * bindings/scripts/test/V8/V8TestNode.cpp:
20373         (WebCore::V8TestNode::constructorCallback):
20374         (WebCore::V8TestNode::wrapSlow):
20375         * bindings/scripts/test/V8/V8TestObj.cpp:
20376         (WebCore::TestObjV8Internal::readOnlyTestObjAttrAttrGetter):
20377         * bindings/scripts/test/V8/V8TestObj.h:
20378         (WebCore::V8TestObj::wrap):
20379         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
20380         (WebCore::V8TestSerializedScriptValueInterface::wrap):
20381         * bindings/v8/DOMDataStore.cpp:
20382         (WebCore::DOMDataStore::current):
20383         * bindings/v8/DOMDataStore.h:
20384         (WebCore::DOMDataStore::get):
20385         (DOMDataStore):
20386         * bindings/v8/V8DOMWrapper.cpp:
20387         * bindings/v8/V8DOMWrapper.h:
20388         (V8DOMWrapper):
20389         (WebCore::V8DOMWrapper::setJSWrapperPrivate):
20390         (WebCore::V8DOMWrapper::setJSWrapperForDOMObject):
20391         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
20392         (WebCore::v8HTMLImageElementConstructorCallback):
20393
20394 2012-11-06  Ken Buchanan  <kenrb@chromium.org>
20395
20396         Crash due to column span under button element
20397         https://bugs.webkit.org/show_bug.cgi?id=101402
20398
20399         Reviewed by Abhishek Arya.
20400
20401         When there is a column-spanning child of a RenderButton
20402         splitBlocks() must split the RenderButton as well as its
20403         only permitted direct child, the anonymous block referenced
20404         by m_inner. A crash was occurring because splitBlocks()
20405         calls addChildIgnoringAnonymousColumnBlocks() to add the
20406         cloned m_inner to the cloned RenderButton, which meant the
20407         m_inner for the cloned RenderButton was not being set even
20408         though a child was being added. This violates state
20409         assumptions in the RenderButton code.
20410
20411         This patch prevents any descendants of RenderButton from
20412         spanning columns. Also, it adds a precautionary check in
20413         RenderButton::removeChild() to mitigate problems if similar
20414         state problems are found in future.
20415
20416         * rendering/RenderBlock.cpp:
20417         (WebCore::RenderBlock::containingColumnsBlock):
20418         * rendering/RenderButton.cpp:
20419         (WebCore::RenderButton::removeChild):
20420
20421 2012-11-06  Shinya Kawanaka  <shinyak@chromium.org>
20422
20423         [Shadow] Pseudo custom-elements should start with 'x-'.
20424         https://bugs.webkit.org/show_bug.cgi?id=100919
20425
20426         Reviewed by Dimitri Glazkov.
20427
20428         Pseuco custom-elements should start with 'x-'. 'Pseudo' starting with '-webkit-' should work
20429         only in UserAgent ShadowDOM. If it's used in Author ShadowDOM, it should not work.
20430
20431         Test: fast/dom/shadow/pseudo-attribute-rendering.html
20432
20433         * css/SelectorChecker.cpp:
20434         (WebCore::SelectorChecker::checkSelector): Added ShadowRoot type check.
20435
20436 2012-11-06  Chris Evans  <cevans@google.com>
20437
20438         Re-order variables in BidiRun and LayoutState
20439         https://bugs.webkit.org/show_bug.cgi?id=100173
20440
20441         Reviewed by Eric Seidel.
20442
20443         The variable re-ordering and use of bitfields for bools has two benefits:
20444         1) Size reduction. sizeof(BidiRun) goes down from 48 to 40 bytes on 64-bit. This is achieved by removing a bool member variable from BidiRun and packing it together with other bools in the BidiCharacterRun base class.
20445         2) Security improvement. We have a lot of use-after-free in the RenderObject hierarchy, and the RenderArena class protects us from a lot of trouble by ensuring that objects of arbitrary type cannot be overlayed on top of freed RenderObjects. This change additionally makes sure that non-virtual RenderArena allocated objects do not have member variables which fully overlap the freed vtable pointer. This leaves re-used vtable pointers always pointing to either a valid vtable or an invalid address due to the freelist high-bit poisoning.
20446
20447         This change is exclusively about size savings; it is performance neutral as you would expect, including on Parser/html5-full-render.html
20448
20449         * platform/text/BidiResolver.h:
20450         (WebCore::BidiCharacterRun::BidiCharacterRun): impact from re-ordering members.
20451         (BidiCharacterRun): provide an efficiently packed bit of storage for BidiRun subclass to use, and re-order members to place bools adjacent.
20452         * rendering/BidiRun.h:
20453         (WebCore::BidiRun::BidiRun): use base class' efficiently packed bit storage for m_hasHyphen.
20454         (BidiRun): m_hasHyphen is now stored in the base class.
20455         * rendering/LayoutState.cpp:
20456         (WebCore::LayoutState::LayoutState):
20457         * rendering/LayoutState.h:
20458         (WebCore::LayoutState::LayoutState): impact from re-ordering members.
20459         (LayoutState): re-order members to place bools adjacently.
20460
20461 2012-11-06  Kent Tamura  <tkent@chromium.org>
20462
20463         [Chromium-win] Refactor date/time format conversion code in LocaleWin
20464         https://bugs.webkit.org/show_bug.cgi?id=101329
20465
20466         Reviewed by Kentaro Hara.
20467
20468         convertWindowsDateFormatToLDML and convertWindowsTimeFormatToLDML did
20469         similar jobs with different code. We can merge them into one function.
20470
20471         As for the date format conversion, we have tokenized a format string and
20472         stored token objects into a vector. We skip token object generation and
20473         generate a LDML-compliant pattern string during parsing.
20474
20475         No new tests. This should make no behavior changes and
20476         WebKit/chromium/tests/LocaleWinTest.cpp has test cases.
20477
20478         * platform/text/win/LocaleWin.cpp:
20479         (WebCore): Remove DateFormatToken, isFooSymbol, ensureShortDateTokens,
20480         convertWindowsDateFormatToLDML, mapCharacterToDateTimeFieldType, and
20481         convertWindowsTimeFormatToLDML.
20482         (WebCore::commitLiteralToken): Store the result to the specified StringBuilder.
20483         (WebCore::convertWindowsDateTimeFormat):
20484         Renamed from parseDateFormat, and supports time format symbols.
20485         (WebCore::LocaleWin::dateFormat): Use convertWindowsDateTimeFormat.
20486         (WebCore::LocaleWin::monthFormat): Ditto.
20487         (WebCore::LocaleWin::timeFormat): Ditto.
20488         (WebCore::LocaleWin::shortTimeFormat): Ditto.
20489         * platform/text/win/LocaleWin.h:
20490         (LocaleWin): Remove ensureShortDateTokens and m_shortDateTokens.
20491
20492 2012-11-06  Elliott Sprehn  <esprehn@chromium.org>
20493
20494         Make Document::renderer faster by using the cached ptr for RenderView
20495         https://bugs.webkit.org/show_bug.cgi?id=101409
20496
20497         Reviewed by Eric Seidel.
20498
20499         In Bug 101277 I made Document::renderView() just return m_renderView instead
20500         of casting the result of renderer(). While this made renderView() cheaper it
20501         makes more sense to just make renderer() faster for Document pointers and
20502         go back to the out of line method in RenderView.h because lots of places in
20503         the code do document()->renderer().
20504
20505         No new tests, this is just a refactor.
20506
20507         * dom/Document.h:
20508         (WebCore::Document::renderer):
20509         * rendering/RenderView.h:
20510         (WebCore::Document::renderView):
20511
20512 2012-11-06  Adam Barth  <abarth@webkit.org>
20513
20514         [V8] neuterBinding should remember the type of its argument
20515         https://bugs.webkit.org/show_bug.cgi?id=101413
20516
20517         Reviewed by Kentaro Hara.
20518
20519         This is a small part of the patch in
20520         https://bugs.webkit.org/show_bug.cgi?id=101110 that we can land
20521         separately to try to tease out what is causing the memory regression.
20522
20523         * bindings/v8/SerializedScriptValue.cpp:
20524         (WebCore):
20525         (WebCore::neuterBinding):
20526
20527 2012-11-06  Alexey Proskuryakov  <ap@apple.com>
20528
20529         Clean up which storage cookie jar functions use
20530         https://bugs.webkit.org/show_bug.cgi?id=101395
20531
20532         Reviewed by Brady Eidson.
20533
20534         * WebCore.exp.in:
20535         * platform/mac/WebCoreSystemInterface.h:
20536         * platform/mac/WebCoreSystemInterface.mm:
20537         Updated for two new WKSI functions.
20538
20539         * platform/CookieJar.h: Added explanatory comments.
20540
20541         * platform/mac/CookieJar.mm:
20542         (WebCore::cookies): Removed fallback on NSHTTPCookieStorage, the WKSI function
20543         already implements it.
20544         (WebCore::cookieRequestHeaderFieldValue): Ditto.
20545         (WebCore::setCookies): Ditto.
20546         (WebCore::cookiesEnabled): Ditto.
20547         (WebCore::getRawCookies): Ditto.
20548         (WebCore::deleteCookie): Ditto.
20549         (WebCore::getHostnamesWithCookies): This function used to look at NSHTTPCookieStorage
20550         exclusively. While it makes sense to bypass private storage session, default storage
20551         session (currently only used for testing on Mac) is never OK to bypass. Changed to
20552         use a WKSI function that supports both.
20553         (WebCore::deleteCookiesForHostname): Ditto.
20554         (WebCore::deleteAllCookies): Ditto.
20555
20556         * platform/network/cf/CookieJarCFNet.cpp:
20557         (WebCore::getHostnamesWithCookies):
20558         (WebCore::deleteCookiesForHostname):
20559         (WebCore::deleteAllCookies):
20560         Updated to match Foundation, so now these functions bypass private session.
20561
20562         * platform/network/cf/CookieStorageCFNet.cpp:
20563         (WebCore::currentCFHTTPCookieStorage): Updated a comment.
20564         (WebCore::defaultCFHTTPCookieStorage):  Added a function that returns cookie storage
20565         for non-private session (or null if that would be an NSHTTPCookieStorage).        
20566         (WebCore::startObservingCookieChanges): We do not want to observe private cookies
20567         here, and we certainly don't want a mismatch between start/stop due to private
20568         browsing mode changes.
20569         (WebCore::stopObservingCookieChanges): Ditto.
20570
20571         * platform/network/cf/CookieStorageCFNet.h: Added defaultCFHTTPCookieStorage().
20572
20573 2012-11-06  Huang Dongsung  <luxtella@company100.net>
20574
20575         Build fix. r133601 broke the Windows build.
20576         https://bugs.webkit.org/show_bug.cgi?id=101404
20577
20578         Reviewed by Noam Rosenthal.
20579
20580         Only static const integral data members can be initialized within a class in the
20581         Windows, so we initialize static const double date members out of the class.
20582
20583         * platform/graphics/texmap/TextureMapper.cpp:
20584         (BitmapTexturePool):
20585         (WebCore):
20586
20587 2012-11-06  Simon Fraser  <simon.fraser@apple.com>
20588
20589         -webkit-background-clip:text produces artifacts when applied to the body and the browser is resized
20590         https://bugs.webkit.org/show_bug.cgi?id=89287
20591
20592         Reviewed by Beth Dakin.
20593
20594         If the body had -webkit-background-clip: text, we'd fail to paint
20595         anything behind it, so would see garbage pixels.
20596         
20597         Fix by having RenderView::paintBoxDecorations() check for a background-clip of "text"
20598         on the renderer that paints the root background.
20599         
20600         Added some new pixel tests for combinations of html and body transform
20601         and backgrounds; earlier versions of the patch broke some of these tests.
20602
20603         Tests: fast/backgrounds/background-clip-text-on-body.html
20604                fast/backgrounds/transformed-body-background.html
20605                fast/backgrounds/transformed-body-html-background.html
20606                fast/backgrounds/transformed-html-body-background.html
20607
20608         * rendering/RenderView.cpp:
20609         (WebCore::rendererObscuresBackground): Broke up the single condition
20610         into early 'false' returns when possible. We need to also check whether
20611         the renderer that actually paints the background (which might be the body)
20612         will fill it; background-clip: text does not.
20613         (WebCore::RenderView::paintBoxDecorations): Rather than checking firstChild(),
20614         actually check the root renderer, so that we can reliably get to the renderer
20615         that mains the root background.
20616
20617 2012-11-06  Stephen White  <senorblanco@chromium.org>
20618
20619         Implement save and restore for a bunch of InternalSettings state
20620         https://bugs.webkit.org/show_bug.cgi?id=101394
20621
20622         Reviewed by Dirk Pranke.
20623
20624         In http://trac.webkit.org/changeset/133399, I resolved a bunch of 
20625         flaky tests by saving and restoring the InternalSettings state
20626         EnableCompositingForFixedPosition.  On a hunch, I git grepped for all
20627         internal settings state which is being set by layout tests but not
20628         saved and restored.  It turns out there about 15 calls.
20629
20630         This patch takes care of five of them, mostly compositing-related.
20631         The others I was either not sure about, or were already at least
20632         being reset to known values by the testing harness.
20633
20634         Hopefully this will alleviate some further test flakiness.
20635
20636         * testing/InternalSettings.cpp:
20637         * testing/InternalSettings.h:
20638
20639 2012-11-06  KyungTae Kim  <ktf.kim@samsung.com>
20640
20641         Fix build warning in RenderLayer.cpp caused by r133628
20642         https://bugs.webkit.org/show_bug.cgi?id=101401
20643
20644         Reviewed by Simon Fraser.
20645
20646         The static function WebCore::frameViewFromLayer is only used when USE(ACCELERATED_COMPOSITING),
20647         so define it only that case for removing -Wunused-function warning
20648
20649         * rendering/RenderLayer.cpp:
20650         (WebCore):
20651
20652 2012-11-06  Hans Muller  <hmuller@adobe.com>
20653
20654         [CSS Exclusions] Store ExclusionPolygonEdge vertices in clockwise order
20655         https://bugs.webkit.org/show_bug.cgi?id=100763
20656
20657         Reviewed by Darin Adler.
20658
20659         The ExclusionPolygon's internal logic, notably getVertexIntersectionVertices(),
20660         assumes that ExclusionPolygonEdge vertices are stored in clockwise order.
20661         If this is not true, then we construct the polygon's edges in reverse.
20662
20663         To determine if the vertices are in clockwise order, we compare the slope
20664         of the line between the top,left vertex and its previous vertex, with the
20665         the slope of the line of vertices before and after the top,left vertex.
20666         If the slope of the latter is greater, then top,left vertex is located
20667         to its left, and the vertices are clockwise.
20668
20669         Test: fast/exclusions/shape-inside/shape-inside-counterclockwise-polygon.html
20670
20671         * rendering/ExclusionPolygon.cpp:
20672         (WebCore::determinant): Used to decide if the min vertex is on the left side of the line that passes through its adjacent vertices.
20673         (WebCore::ExclusionPolygon::ExclusionPolygon): If the polygon's vertices are specified in counterclockwise order, construct the edges in reverse.
20674         (WebCore::appendIntervalX): Made this an inline since it was only defined as a function for the sake of clarity.
20675
20676 2012-11-06  Tiancheng Jiang  <tijiang@rim.com>
20677
20678         [BlackBerry] Update BB10 form theme.
20679         https://bugs.webkit.org/show_bug.cgi?id=100760
20680
20681         Reviewed by Rob Buis.
20682
20683         RIM PR 238123
20684         Internal Reviewed by Chris Hutten-Czapski
20685         BB10 selection theme use slice image function to draw selection button,
20686         any border-radius setting other than 0 will make the button corner
20687         clipped. Always set button border-radius: 0 for BB10 theme.
20688
20689         * css/themeBlackBerry.css:
20690         (select[size][multiple]):
20691         (select[size="1"]):
20692
20693 2012-11-06  Elliott Sprehn  <esprehn@chromium.org>
20694
20695         Remove branch from inside RenderObject::view now that renderer() is more expensive
20696         https://bugs.webkit.org/show_bug.cgi?id=101277
20697
20698         Reviewed by Eric Seidel.
20699
20700         It was observed in Bug 100057 that calling renderer() repeatedly now that it has a branch
20701         can be a performance regression. Now that we no longer keep a separate pointer for rare data
20702         in Document, we can use that space for a pointer to the RenderView making RenderObject::view()
20703         faster and removing the branch.
20704
20705         This is a 1% improvement on Parser/html5-full-render.html
20706
20707         This also cleans up the code because it turns out we don't need to have RenderObject::view() in
20708         RenderView.h because we can just call Document::renderView() and not do toRenderView. This makes
20709         it easier to find this method as it exists in the right header file now.
20710
20711         No new tests, this is just a refactor.
20712
20713         * WebCore.exp.in: Remove export of Document::renderView since it's inline now.
20714         * dom/Document.cpp:
20715         (WebCore::Document::Document):
20716         (WebCore::Document::setRenderer):
20717         (WebCore):
20718         * dom/Document.h:
20719         (WebCore::Document::renderView):
20720         (Document):
20721         * rendering/RenderObject.h:
20722         (WebCore::RenderObject::view):
20723         * rendering/RenderView.h:
20724         (WebCore):
20725
20726 2012-11-06  Sheriff Bot  <webkit.review.bot@gmail.com>
20727
20728         Unreviewed, rolling out r133526.
20729         http://trac.webkit.org/changeset/133526
20730         https://bugs.webkit.org/show_bug.cgi?id=101388
20731
20732         May have caused 15% memory regression in Chromium (Requested
20733         by jsbell|gardener on #webkit).
20734
20735         * UseV8.cmake:
20736         * WebCore.gypi:
20737         * bindings/scripts/CodeGeneratorV8.pm:
20738         (GenerateHeader):
20739         (GenerateNormalAttrGetter):
20740         (GenerateConstructorCallback):
20741         (GenerateNamedConstructorCallback):
20742         (GenerateToV8Converters):
20743         (GetDomMapFunction):
20744         (GetDomMapName):
20745         * bindings/scripts/test/V8/V8Float64Array.h:
20746         (WebCore::V8Float64Array::wrap):
20747         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
20748         (WebCore::V8TestActiveDOMObject::wrap):
20749         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
20750         (WebCore::V8TestCustomNamedGetter::wrap):
20751         * bindings/scripts/test/V8/V8TestEventConstructor.h:
20752         (WebCore::V8TestEventConstructor::wrap):
20753         * bindings/scripts/test/V8/V8TestEventTarget.h:
20754         (WebCore::V8TestEventTarget::wrap):
20755         * bindings/scripts/test/V8/V8TestException.h:
20756         (WebCore::V8TestException::wrap):
20757         * bindings/scripts/test/V8/V8TestInterface.h:
20758         (WebCore::V8TestInterface::wrap):
20759         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
20760         (WebCore::V8TestMediaQueryListListener::wrap):
20761         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
20762         (WebCore::V8TestNamedConstructor::wrap):
20763         * bindings/scripts/test/V8/V8TestNode.cpp:
20764         (WebCore::V8TestNode::constructorCallback):
20765         (WebCore::V8TestNode::wrapSlow):
20766         * bindings/scripts/test/V8/V8TestObj.cpp:
20767         (WebCore::TestObjV8Internal::readOnlyTestObjAttrAttrGetter):
20768         * bindings/scripts/test/V8/V8TestObj.h:
20769         (WebCore::V8TestObj::wrap):
20770         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
20771         (WebCore::V8TestSerializedScriptValueInterface::wrap):
20772         * bindings/v8/DOMDataStore.cpp:
20773         (WebCore::DOMDataStore::DOMDataStore):
20774         (WebCore::DOMDataStore::~DOMDataStore):
20775         (WebCore::DOMDataStore::current):
20776         (WebCore::DOMDataStore::reportMemoryUsage):
20777         * bindings/v8/DOMDataStore.h:
20778         (WebCore::DOMDataStore::domNodeMap):
20779         (WebCore::DOMDataStore::domObjectMap):
20780         (DOMDataStore):
20781         * bindings/v8/DOMWrapperMap.h:
20782         (WebCore):
20783         (DOMWrapperMap):
20784         (WebCore::DOMWrapperMap::~DOMWrapperMap):
20785         (WebCore::DOMWrapperHashMap::remove):
20786         * bindings/v8/DOMWrapperWorld.h:
20787         * bindings/v8/IntrusiveDOMWrapperMap.h: Copied from Source/WebKit/chromium/src/WebScriptController.cpp.
20788         (WebCore):
20789         (IntrusiveDOMWrapperMap):
20790         (WebCore::IntrusiveDOMWrapperMap::weakCallback):
20791         * bindings/v8/ScriptProfiler.cpp:
20792         * bindings/v8/SerializedScriptValue.cpp:
20793         (WebCore::neuterBinding):
20794         * bindings/v8/V8DOMMap.cpp: Copied from Source/WebKit/chromium/src/WebScriptController.cpp.
20795         (WebCore):
20796         (WebCore::getDOMNodeMap):
20797         (WebCore::getDOMObjectMap):
20798         * bindings/v8/V8DOMMap.h: Copied from Source/WebKit/chromium/src/WebScriptController.cpp.
20799         (WebCore):
20800         * bindings/v8/V8DOMWindowShell.cpp:
20801         * bindings/v8/V8DOMWrapper.cpp:
20802         (WebCore::V8DOMWrapper::setJSWrapperForDOMNode):
20803         (WebCore):
20804         * bindings/v8/V8DOMWrapper.h:
20805         (V8DOMWrapper):
20806         (WebCore::V8DOMWrapper::getCachedWrapper):
20807         (WebCore::V8DOMWrapper::setJSWrapperForDOMObject):
20808         * bindings/v8/V8GCController.cpp:
20809         * bindings/v8/V8NPObject.cpp:
20810         * bindings/v8/WorkerContextExecutionProxy.cpp:
20811         * bindings/v8/WorkerScriptController.cpp:
20812         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
20813         (WebCore::v8HTMLImageElementConstructorCallback):
20814
20815 2012-11-06  Alexey Proskuryakov  <ap@apple.com>
20816
20817         Some cookie code cleanup
20818         https://bugs.webkit.org/show_bug.cgi?id=101375
20819
20820         Reviewed by Dan Bernstein.
20821
20822         * platform/CookieJar.h: Fixed style. Grouped functions by which storage they operate
20823         on in Mac port, but didn't add explanatory comments yet, because this is different
20824         in some ports.
20825
20826         * platform/mac/CookieJar.mm:
20827         (WebCore): Removed special code for isHTTPOnly, it's present in Foundation in all
20828         supported OS X versions.
20829         (WebCore::filterCookies): Use -isHTTPOnly directly.
20830         (WebCore::cookies): Get rid of a variable for URL, implicit conversion works just as well.
20831         (WebCore::cookieRequestHeaderFieldValue): Ditto.
20832         (WebCore::setCookies): Assert that no more than one cookie was created from one
20833         Set-Cookie header, document.cookie can only be used to set one cookie at a time.
20834         (WebCore::getRawCookies): Removed useless local variables.
20835
20836         * platform/network/CookieStorage.h: Removed an unneeded include, clarified a comment.
20837
20838         * platform/network/HTTPHeaderMap.h: Added a FIXME.
20839
20840 2012-11-06  John Griggs  <jgriggs@rim.com>
20841
20842         Implement MediaPlayerPrivate::didLoadingProgress for BlackBerry platform
20843         https://bugs.webkit.org/show_bug.cgi?id=100378
20844
20845         Reviewed by Eric Carlson.
20846
20847         Implement this method for BlackBerry platform.
20848
20849         New test: LayoutTests/media/progress-events-generated-correctly.html
20850
20851         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
20852         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
20853         (WebCore::MediaPlayerPrivate::didLoadingProgress):
20854         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.h:
20855         (MediaPlayerPrivate):
20856
20857 2012-11-06  Adam Barth  <abarth@webkit.org>
20858
20859         DOMImplementation should use ScriptWrappable
20860         https://bugs.webkit.org/show_bug.cgi?id=101279
20861
20862         Reviewed by Eric Seidel.
20863
20864         This patch makes DOMImplementation ScriptWrappable. Both the V8 and JSC
20865         bindings automatically detect the presence of this base class and use
20866         it to optimize getting and setting JavaScript wrappers.
20867
20868         This patch is a 23% progression on Bindings/document-implementation for
20869         the V8 bindings and a 69% progression for the JSC bindings.
20870
20871         * dom/DOMImplementation.h:
20872
20873 2012-11-06  Benjamin Poulain  <benjamin@webkit.org>
20874
20875         Speed up TransformationMatrix::multiply() on modern ARM
20876         https://bugs.webkit.org/show_bug.cgi?id=101084
20877
20878         Reviewed by Gavin Barraclough.
20879
20880         The main improvements are:
20881         -Store the full source matrix in the registers d16 to d31. This way we avoid going
20882          back and forth to memory to use the operands.
20883          Since the full matrix is in register, we can also directly modify the memory of m_matrix,
20884          we no longer need the temporary matrix memcopied at the end.
20885         -Use of LoadMultiple and StoreMultiple to load-store the matrix parameters.
20886         -Use Multiply-Accumulate instead of VMUL followed by VADD. This half the number of instruction.
20887         -On regular ARMv7, using a loop to reuse the same code for each row also improve the performance.
20888
20889         Depending on the hardware, the new code takes 20% to 42% less time than the basic implementation.
20890
20891         * platform/graphics/transforms/TransformationMatrix.cpp:
20892         (WebCore::TransformationMatrix::multiply):
20893         * platform/graphics/transforms/TransformationMatrix.h:
20894         (TransformationMatrix):
20895
20896 2012-11-06  Sheriff Bot  <webkit.review.bot@gmail.com>
20897
20898         Unreviewed, rolling out r133529 and r133562.
20899         http://trac.webkit.org/changeset/133529
20900         http://trac.webkit.org/changeset/133562
20901         https://bugs.webkit.org/show_bug.cgi?id=101371
20902
20903         Caused 15% memory regression on Chromium page cyclers
20904         (Requested by jsbell|gardener on #webkit).
20905
20906         * platform/text/LineBreakIteratorPoolICU.h:
20907         (WebCore::LineBreakIteratorPool::take):
20908         (WebCore::LineBreakIteratorPool::put):
20909         (LineBreakIteratorPool):
20910         * platform/text/TextBreakIterator.cpp:
20911         (WebCore::acquireLineBreakIterator):
20912         * platform/text/TextBreakIterator.h:
20913         (WebCore):
20914         (WebCore::LazyLineBreakIterator::LazyLineBreakIterator):
20915         (WebCore::LazyLineBreakIterator::get):
20916         (WebCore::LazyLineBreakIterator::reset):
20917         (LazyLineBreakIterator):
20918         * platform/text/TextBreakIteratorICU.cpp:
20919         (WebCore::acquireLineBreakIterator):
20920         (WebCore::releaseLineBreakIterator):
20921         * platform/text/gtk/TextBreakIteratorGtk.cpp:
20922         (WebCore::setUpIterator):
20923         (WebCore::acquireLineBreakIterator):
20924         * platform/text/wince/TextBreakIteratorWinCE.cpp:
20925         (WebCore::acquireLineBreakIterator):
20926         * rendering/RenderBlockLineLayout.cpp:
20927         (WebCore::RenderBlock::LineBreaker::nextLineBreak):
20928         * rendering/RenderText.cpp:
20929         (WebCore::RenderText::computePreferredLogicalWidths):
20930         * rendering/RenderText.h:
20931         (WebCore):
20932         * rendering/break_lines.cpp:
20933         (WebCore):
20934         (WebCore::isBreakableSpace):
20935         (WebCore::needsLineBreakIterator):
20936         (WebCore::nextBreakablePosition):
20937         (WebCore::nextBreakablePositionIgnoringNBSP):
20938         * rendering/break_lines.h:
20939         (WebCore):
20940         (WebCore::isBreakable):
20941
20942 2012-11-06  Peter Beverloo  <peter@chromium.org>
20943
20944         [Chromium] Enable the JavaScript i18n API for Android
20945         https://bugs.webkit.org/show_bug.cgi?id=101357
20946
20947         Reviewed by Adam Barth.
20948
20949         Remove the conditional dependency on the v8-i18n API. The library is now
20950         always available in a Chromium for Android checkout.
20951
20952         * WebCore.gyp/WebCore.gyp:
20953
20954 2012-11-06  Adam Barth  <abarth@webkit.org>
20955
20956         ScriptWrappable should work for more than just Node
20957         https://bugs.webkit.org/show_bug.cgi?id=101319
20958
20959         Reviewed by Eric Seidel.
20960
20961         This patch generalizes the inline cached wrapper code path to work with
20962         all subclasses of ScriptWrappable, not just Node.
20963
20964         * bindings/js/JSDOMBinding.h:
20965         (WebCore::setInlineCachedWrapper):
20966         (WebCore::getInlineCachedWrapper):
20967         (WebCore):
20968         (WebCore::clearInlineCachedWrapper):
20969         (WebCore::cacheWrapper):
20970         * bindings/js/JSNodeCustom.h:
20971
20972 2012-11-06  Tiancheng Jiang  <tijiang@rim.com>
20973
20974         [BlackBerry] Update BB10 form theme.
20975         https://bugs.webkit.org/show_bug.cgi?id=100760
20976
20977         Reviewed by Rob Buis.
20978
20979         Revert webkit/ce306dcc698199a6f7ce679daf0a30c25d3a3d43 slider theme
20980         change which break media control and vertical slider.
20981
20982         RIM PR 236993
20983         Internal Reviewed by Jeff Rogers.
20984
20985         * platform/blackberry/RenderThemeBlackBerry.cpp:
20986         (WebCore::RenderThemeBlackBerry::paintSliderTrackRect):
20987         (WebCore::RenderThemeBlackBerry::paintSliderThumb):
20988
20989 2012-11-06  Michael Saboff  <msaboff@apple.com>
20990
20991         canonicalizedTitle() shouldn't convert 8 bit title strings to 16 bit
20992         https://bugs.webkit.org/show_bug.cgi?id=101105
20993
20994         Reviewed by Darin Adler.
20995
20996         Turned canonicalizedTitle() into a templated function based on character type.
20997         Changed call in updateTitle() to check the bitness of the title string to call
20998         the right template flavor of canonicalizedTitle().
20999         Made supporting changes by adding displayBufferModifiedByEncoding(LChar*, ...)
21000         and made TextEncoding::displayBuffer() a templated function as well.
21001
21002         No new tests needed, as functionality is unchanged.
21003
21004         * dom/Document.cpp:
21005         (WebCore::canonicalizedTitle):
21006         (WebCore::Document::updateTitle):
21007         (WebCore::Document::displayBufferModifiedByEncodingInternal):
21008         * dom/Document.h:
21009         (WebCore::Document::displayBufferModifiedByEncoding):
21010         * platform/text/TextEncoding.h:
21011         (TextEncoding):
21012         (WebCore::TextEncoding::displayBuffer):
21013
21014 2012-11-05  Simon Fraser  <simon.fraser@apple.com>
21015
21016         Fix RenderGeometryMap assertion when layers are scrolled during layout
21017         https://bugs.webkit.org/show_bug.cgi?id=101292
21018
21019         Reviewed by Beth Dakin.
21020
21021         When we set RenderLayer scroll positions as part of layout, we don't want
21022         to update compositing layers right away. Updating compositing layers
21023         requires that the entire layer tree has been updated from renderers,
21024         so that the geometry of all RenderLayers can be trusted. When this state
21025         was violated, RenderGeometryMap asserts.
21026         
21027         Fix by bailing from updateCompositingLayersAfterScroll() if FrameView
21028         tells us that we're doing layout. A full update of the compositing layers
21029         will happen later anyway.
21030
21031         Test: compositing/geometry/geometry-map-scroll-during-layout-assertion.html
21032
21033         * rendering/RenderLayer.cpp:
21034         (WebCore::frameViewFromLayer):
21035         (WebCore::RenderLayer::updateCompositingLayersAfterScroll):
21036
21037 2012-11-06  Michael Saboff  <msaboff@apple.com>
21038
21039         quoteCSSString() always creates a 16 bit string
21040         https://bugs.webkit.org/show_bug.cgi?id=101004
21041
21042         Reviewed by Darin Adler.
21043
21044         Added a new templated helper based on character type from the logic of quoteCSSString() to process
21045         the argument string based on its native bitness.
21046
21047         Functionality covered by existing tests.
21048
21049         * css/CSSParser.cpp:
21050         (WebCore::quoteCSSStringInternal):
21051         (WebCore::quoteCSSString):
21052
21053 2012-11-06  Andras Becsi  <andras.becsi@digia.com>
21054
21055         [Qt][WK2] Fit-to-width broken on pages with viewport meta tag
21056         https://bugs.webkit.org/show_bug.cgi?id=99715
21057
21058         Reviewed by Jocelyn Turcotte.
21059
21060         Add a bool that indicates if the content had an explicit
21061         initial-scale in the viewport meta tag.
21062
21063         * dom/ViewportArguments.cpp:
21064         (WebCore::computeViewportAttributes):
21065         * dom/ViewportArguments.h:
21066         (ViewportAttributes):
21067
21068 2012-11-06  Mike West  <mkwst@chromium.org>
21069
21070         CSP 1.1: Tweak the script interface to match the spec.
21071         https://bugs.webkit.org/show_bug.cgi?id=101321
21072
21073         Reviewed by Adam Barth.
21074
21075        This patch brings WebKit in line with the changes made to the spec in
21076        https://dvcs.w3.org/hg/content-security-policy/rev/5a29424a37d4.
21077        Specifically, the following:
21078
21079        - Renamed 'document.SecurityPolicy' to 'document.securityPolicy'
21080        - Converted the following to read-only boolean attributes:
21081          - 'allowsEval'
21082          - 'allowsInlineScript'
21083          - 'allowsInlineStyle'
21084          - 'isActive'
21085
21086         These changes only have effect for ports with CSP_NEXT enabled.
21087
21088         Tests: http/tests/security/contentSecurityPolicy/1.1/securitypolicy-allowinlinescript.html
21089                http/tests/security/contentSecurityPolicy/1.1/securitypolicy-allowinlinestyle.html
21090
21091         * dom/Document.idl:
21092         * page/DOMSecurityPolicy.idl:
21093             Tweaking the IDL files to match the new definition of the
21094             functionlity in the spec.
21095
21096 2012-11-06  Andrey Lushnikov  <lushnikov@google.com>
21097
21098         Added console.clear() method
21099
21100         Web Inspector: add console.clear()
21101         https://bugs.webkit.org/show_bug.cgi?id=101021
21102
21103         Reviewed by Vsevolod Vlasov.
21104
21105         Adds native implementation of console.clear
21106
21107         Test: inspector/console/console-clear-function.html
21108
21109         * English.lproj/localizedStrings.js: Adds 'Console was cleared' string
21110         * inspector/ConsoleMessage.cpp:
21111         (WebCore::messageTypeValue): Adds ClearMessageType
21112         * inspector/Inspector.json:
21113         * inspector/InspectorConsoleAgent.cpp:
21114         (WebCore::InspectorConsoleAgent::addMessageToConsole):
21115         * inspector/front-end/ConsoleMessage.js:
21116         (WebInspector.ConsoleMessageImpl.prototype._formatMessage): Display strategy for "clear" message
21117         * inspector/front-end/ConsoleModel.js:
21118         * inspector/front-end/inspector.css:
21119         (.console-info): Adds style for the 'console was cleared' message
21120         * page/Console.cpp: backend binging for console.clear()
21121         (WebCore::Console::clear):
21122         (WebCore):
21123         * page/Console.h:
21124         (Console):
21125         * page/Console.idl: Adds 'clear' message to protocol
21126         * page/ConsoleTypes.h:
21127
21128 2012-11-06  Aaron Colwell  <acolwell@chromium.org>
21129
21130         Heap-buffer-overflow in WebCore::TextTrackCueList::add
21131         https://bugs.webkit.org/show_bug.cgi?id=101018
21132
21133         Reviewed by Eric Carlson.
21134
21135         Added an extra check to avoid using a negative array index when a cue
21136         is added to the beginning of the list.
21137
21138         Test case added to LayoutTests/media/track/track-add-remove-cue.html.
21139
21140         * html/track/TextTrackCueList.cpp:
21141         (WebCore::TextTrackCueList::add):
21142
21143 2012-11-06  Aaron Colwell  <acolwell@chromium.org>
21144
21145         Regression(r132681): Heap-use-after-free in WebCore::RenderTextTrackCue::layout
21146         https://bugs.webkit.org/show_bug.cgi?id=100981
21147
21148         Reviewed by Eric Carlson.
21149
21150         Fixing a TextTrackCue use after free bug. textTrackRemoveCues() needs to be called when
21151         an HTMLTrackElement is removed from an HTMLMediaElement so that references to
21152         TextTrackCues are removed from m_cueTree.
21153
21154         Test: media/track/track-remove-by-setting-innerHTML.html
21155
21156         * html/HTMLMediaElement.cpp:
21157         (WebCore::HTMLMediaElement::willRemoveTrack):
21158
21159 2012-10-23  Stephen White  <senorblanco@chromium.org>
21160
21161         [skia] Implement reference (url) filters on composited layers.
21162         https://bugs.webkit.org/show_bug.cgi?id=100142
21163
21164         Reviewed by James Robinson.
21165
21166         Covered by css3/filters/effect-reference-hw.html
21167
21168         * WebCore.gyp/WebCore.gyp:
21169         * WebCore.gypi:
21170         Add new files.
21171         * WebCore.xcodeproj/project.pbxproj:
21172         Mark FilterEffect.h as "private".
21173         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
21174         (WebCore::GraphicsLayerChromium::setFilters):
21175         Use the new SkImageFilter builder and setLayer() infrastructure, but
21176         only if there's a reference filter in the chain.
21177         * platform/graphics/filters/FEBlend.h:
21178         * platform/graphics/filters/FEColorMatrix.h:
21179         * platform/graphics/filters/FEGaussianBlur.h:
21180         * platform/graphics/filters/FELighting.h:
21181         * platform/graphics/filters/FEMorphology.h:
21182         * platform/graphics/filters/FilterEffect.h:
21183         (WebCore::FilterEffect::createImageFilter):
21184         Add createImageFilter() factory function for building SkImageFilters.
21185         * platform/graphics/filters/FilterOperation.h:
21186         (WebCore::FilterOperation::ReferenceFilterOperation::filterEffect):
21187         (WebCore::FilterOperation::ReferenceFilterOperation::setFilterEffect):
21188         Add a FilterEffect member to ReferenceFilterOperation, and accessors
21189         for it.
21190         * platform/graphics/filters/skia/FEBlendSkia.cpp:
21191         (WebCore::FEBlend::createImageFilter):
21192         Implement SkImageFilter building for FEBlend filter.
21193         * platform/graphics/filters/skia/FEColorMatrixSkia.cpp:
21194         (WebCore::createColorFilter):
21195         (WebCore::FEColorMatrix::platformApplySkia):
21196         Refactor creation of SkColorFilter from an FEColorMatrix filter.
21197         (WebCore::FEColorMatrix::createImageFilter):
21198         Implement SkImageFilter building for FEColorMatrix filter.
21199         * platform/graphics/filters/skia/FEGaussianBlurSkia.cpp:
21200         (WebCore::FEGaussianBlur::createImageFilter):
21201         Implement SkImageFilter building for FEGaussianBlur filter.
21202         * platform/graphics/filters/skia/FELightingSkia.cpp:
21203         (WebCore::FELighting::createImageFilter):
21204         Implement SkImageFilter building for FELighting filters.
21205         * platform/graphics/filters/skia/FEMorphologySkia.cpp:
21206         (WebCore::FEMorphology::createImageFilter):
21207         Implement SkImageFilter building for FEMorphology filter.
21208         * platform/graphics/filters/skia/SkiaImageFilterBuilder.cpp: Added.
21209         (WebCore::SkiaImageFilterBuilder::SkiaImageFilterBuilder):
21210         (WebCore::SkiaImageFilterBuilder::build):
21211         * platform/graphics/filters/skia/SkiaImageFilterBuilder.h:
21212         Implement new helper class for building an SkImageFilter DAG from
21213         a FilterEffect DAG.  Can also build from FilterOperations list.
21214         * rendering/FilterEffectRenderer.cpp:
21215         (WebCore::FilterEffectRenderer::build):
21216         When building FilterEffects from a reference filter, also store the
21217         generated DAG on the ReferenceFilterOperation itself.
21218         * rendering/RenderLayer.cpp:
21219         (WebCore::RenderLayer::updateOrRemoveFilterEffect):
21220         Even when in composited mode, if there's a reference filter in the 
21221         chain, build the FilterEffect DAG from it.
21222
21223 2012-11-06  Max Feil  <mfeil@rim.com>
21224
21225         [BlackBerry] Automatically go fullscreen on video play
21226         https://bugs.webkit.org/show_bug.cgi?id=101100
21227
21228         Reviewed by Eric Carlson.
21229
21230         There is a requirement to have HTML5 video automatically enter
21231         fullscreen when a video starts playing (PR131774). This change
21232         implements this feature, with restrictions. The main restriction
21233         is adherence to WebKit's philosophy of only entering fullscreen
21234         due to a user gesture. This is important in order to avoid
21235         pop-up advertisements and other unwanted fullscreen content.
21236         One consequence of this is that video elements with the autoplay
21237         attribute will not automatically enter fullscreen.
21238
21239         Other caveats:
21240         - This feature applies only to "small screen" devices where
21241         automatically going fullscreen makes more sense.
21242         - Fullscreen will only be entered automatically when the
21243         video is played from the beginning (current time is zero).
21244         It is assumed that if the user is resuming play from a paused
21245         state and is not in fullscreen mode, then they exited fullscreen
21246         mode intentionally.
21247
21248         Test: platform/blackberry/media/video-automatic-fullscreen.html
21249
21250         * html/HTMLMediaElement.cpp:
21251         (WebCore::HTMLMediaElement::mediaPlayerEnterFullscreen):
21252         (WebCore):
21253         (WebCore::HTMLMediaElement::mediaPlayerIsFullscreen):
21254         (WebCore::HTMLMediaElement::mediaPlayerIsFullscreenPermitted):
21255         * html/HTMLMediaElement.h:
21256         (HTMLMediaElement):
21257         * platform/graphics/MediaPlayer.h:
21258         (WebCore::MediaPlayerClient::mediaPlayerEnterFullscreen):
21259         (WebCore::MediaPlayerClient::mediaPlayerIsFullscreen):
21260         (WebCore::MediaPlayerClient::mediaPlayerIsFullscreenPermitted):
21261         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
21262         (WebCore::MediaPlayerPrivate::play):
21263         (WebCore::MediaPlayerPrivate::waitMetadataTimerFired):
21264         (WebCore::MediaPlayerPrivate::conditionallyGoFullscreenAfterPlay):
21265         (WebCore):
21266         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.h:
21267         (MediaPlayerPrivate):
21268
21269 2012-11-06  Grzegorz Czajkowski  <g.czajkowski@samsung.com>
21270
21271         [WK2][EFL][GTK] early return of checkSpellingOfString treats correct words as misspelled
21272         https://bugs.webkit.org/show_bug.cgi?id=101215
21273
21274         Reviewed by Gustavo Noronha Silva.
21275
21276         Save the misspelled location and length of the string to the default values (-1, 0)
21277         at the beginning of the checkSpellingOfString method.
21278         It assumes that the words are spelled correctly and early return of method doesn't
21279         cause assertions in findFirstMisspelling (WebCore/editing/TextCheckingHelper.cpp).
21280
21281         * platform/text/enchant/TextCheckerEnchant.cpp:
21282         (TextCheckerEnchant::checkSpellingOfString):
21283
21284 2012-11-06  Huang Dongsung  <luxtella@company100.net>
21285
21286         [TexMap] Remove unused textures in the texture pool.
21287         https://bugs.webkit.org/show_bug.cgi?id=100706
21288
21289         Reviewed by Noam Rosenthal.
21290
21291         Currently, we do not remove textures in the texture pool of
21292         TextureMapper. The texture pool is destroyed when TextureMapper is
21293         destroyed. It means the texture pool consumes texture memory until its
21294         destruction. This patch removes textures if the textures have been not
21295         used in 3 seconds as LayerTreeCoordinator manages UpdateAtlases.
21296
21297         Changing cache policy is not testable in layout tests.
21298
21299         * platform/graphics/texmap/TextureMapper.cpp:
21300         (WebCore::BitmapTexturePoolEntry::BitmapTexturePoolEntry):
21301         (WebCore::BitmapTexturePoolEntry::markUsed):
21302         (WebCore::BitmapTexturePoolEntry::compareTimeLastUsed):
21303         (BitmapTexturePoolEntry):
21304         (WebCore):
21305         (BitmapTexturePool):
21306         (WebCore::BitmapTexturePool::BitmapTexturePool):
21307         (WebCore::BitmapTexturePool::scheduleReleaseUnusedTextures):
21308         (WebCore::BitmapTexturePool::releaseUnusedTexturesTimerFired):
21309         (WebCore::BitmapTexturePool::acquireTexture):
21310         (WebCore::TextureMapper::acquireTextureFromPool):
21311         (WebCore::TextureMapper::TextureMapper):
21312         (WebCore::TextureMapper::~TextureMapper):
21313         * platform/graphics/texmap/TextureMapper.h:
21314         (WebCore):
21315         (TextureMapper):
21316
21317 2012-11-02  Ilya Tikhonovsky  <loislo@chromium.org>
21318
21319         Web Inspector: NMI instrument CachedMetadata. It uses ~300k on plus.google.com
21320         https://bugs.webkit.org/show_bug.cgi?id=101067
21321
21322         Reviewed by Yury Semikhatsky.
21323
21324         Plain vanilla instrumentation for CachedMetadata class.
21325
21326         * CMakeLists.txt:
21327         * GNUmakefile.list.am:
21328         * Target.pri:
21329         * WebCore.gypi:
21330         * WebCore.vcproj/WebCore.vcproj:
21331         * WebCore.xcodeproj/project.pbxproj:
21332         * loader/CachedMetadata.cpp: Added.
21333         (WebCore):
21334         (WebCore::CachedMetadata::reportMemoryUsage):
21335         * loader/CachedMetadata.h:
21336         (CachedMetadata):
21337
21338 2012-11-06  Alexei Filippov  <alph@chromium.org>
21339
21340         Web Inspector: report physical memory really committed for JS heap in NMI
21341         https://bugs.webkit.org/show_bug.cgi?id=101335
21342
21343         Some OSes (e.g. Linux) perform lazy commits of requested memory.
21344         Because of that the committed memory may not retain any physical
21345         memory until the very first access to the committed chunk.
21346         That led to JS heap reported more physical memory than was currently
21347         in use.
21348
21349         Reviewed by Vsevolod Vlasov.
21350
21351         * bindings/v8/ScriptGCEvent.cpp:
21352         (WebCore::ScriptGCEvent::getHeapSize):
21353
21354 2012-11-06  Vsevolod Vlasov  <vsevik@chromium.org>
21355
21356         Web Inspector: Breakpoint is not removed when it was set in non-formatted mode and then removed while in formatted mode.
21357         https://bugs.webkit.org/show_bug.cgi?id=100595
21358
21359         Reviewed by Yury Semikhatsky.
21360
21361         Breakpoints in storage are now updated/removed by file name saved from primary location when they were created,
21362         not by the name returned by UISourceCode (as this one could change when UISourceCode is formatted).
21363         SourceFileId is now used across BreakpointManager to specify file name.
21364         And breakpointStorageId is now used to specify (fileName, lineNumber) pair.
21365
21366         * inspector/front-end/BreakpointManager.js:
21367         (WebInspector.BreakpointManager.sourceFileId):
21368         (WebInspector.BreakpointManager.prototype._restoreBreakpoints):
21369         (WebInspector.BreakpointManager.prototype._uiSourceCodeRemoved): Removed redundant check.
21370         (WebInspector.BreakpointManager.prototype.breakpointLocationsForUISourceCode):
21371         (WebInspector.BreakpointManager.Breakpoint):
21372         (WebInspector.BreakpointManager.Breakpoint.prototype._breakpointStorageId):
21373         (WebInspector.BreakpointManager.Storage.prototype._restoreBreakpoints):
21374         (set WebInspector.BreakpointManager.Storage.Item):
21375
21376 2012-11-06  Keishi Hattori  <keishi@webkit.org>
21377
21378         The "Rect" class in WebCore/Resources/pagepopups/pickerCommon.js should be renamed
21379         https://bugs.webkit.org/show_bug.cgi?id=101304
21380
21381         Reviewed by Kent Tamura.
21382
21383         The name Rect conflicts with CSS Rect.
21384
21385         No new tests. Just renaming.
21386
21387         * Resources/pagepopups/pickerCommon.js:
21388         (Rectangle): Renamed from Rect.
21389         (Rectangle.prototype.toString):
21390         (Rectangle.intersection):
21391         (adjustWindowRect):
21392         (hideWindow):
21393
21394 2012-11-06  Kentaro Hara  <haraken@chromium.org>
21395
21396         Replace setDOMWrapper(wrapper, 0) with resetDOMWrapper(wrapper)
21397         https://bugs.webkit.org/show_bug.cgi?id=101190
21398
21399         Reviewed by Adam Barth.
21400
21401         To guarantee that we never stores NULL pointers to V8 internal
21402         fields, we want to insert ASSERT()s to setDOMWrapper().
21403         This patch replaces setDOMWrapper() that intentionally
21404         passes NULL pointers with clearDOMWrapper().
21405
21406         No tests. No change in behavior.
21407
21408         * bindings/v8/V8DOMWrapper.h:
21409         (V8DOMWrapper):
21410         (WebCore::V8DOMWrapper::clearDOMWrapper):
21411         * bindings/v8/V8NPObject.cpp:
21412         (WebCore::forgetV8ObjectForNPObject):
21413
21414 2012-11-06  Vsevolod Vlasov  <vsevik@chromium.org>
21415
21416         Web Inspector: Displayed name/path of urls in network tab of dev tools is inconsistent
21417         https://bugs.webkit.org/show_bug.cgi?id=101064
21418
21419         Reviewed by Yury Semikhatsky.
21420
21421         Extracted some generic methods from ParsedURL displayName getters (about:blank and data url handlers).
21422         Implemented consistent name() and path() method on NetworkRequest based on ParsedURL.
21423         NetworkPanel now uses name() and path() methods on NetworkRequest to show requests and search for them.
21424
21425         Test: http/tests/inspector/network/request-name-path.html
21426
21427         * inspector/front-end/NetworkPanel.js:
21428         (WebInspector.NetworkLogView.prototype._matchRequest):
21429         (WebInspector.NetworkLogView.prototype._highlightMatchedRequests):
21430         (WebInspector.NetworkLogView.prototype.performFilter):
21431         (WebInspector.NetworkDataGridNode.prototype._refreshNameCell):
21432         (WebInspector.NetworkDataGridNode.NameComparator):
21433         * inspector/front-end/NetworkRequest.js:
21434         (WebInspector.NetworkRequest.prototype.set url):
21435         (WebInspector.NetworkRequest.prototype.name):
21436         (WebInspector.NetworkRequest.prototype.path):
21437         (WebInspector.NetworkRequest.prototype._parseNameAndPathFromURL):
21438         * inspector/front-end/ParsedURL.js:
21439         (WebInspector.ParsedURL):
21440         (WebInspector.ParsedURL.prototype.get displayName):
21441         (WebInspector.ParsedURL.prototype.dataURLDisplayName):
21442         (WebInspector.ParsedURL.prototype.isAboutBlank):
21443         (WebInspector.ParsedURL.prototype.isDataURL):
21444
21445 2012-11-05  Pavel Feldman  <pfeldman@chromium.org>
21446
21447         Web Inspector: make Spectrum and Popover WebInspector.Views in order to enable reuse
21448         https://bugs.webkit.org/show_bug.cgi?id=101200
21449
21450         Reviewed by Yury Semikhatsky.
21451
21452         - Split Spectrum and SpectrumPopoverHelper (first is a component, second is controller)
21453         - Made Popover a root view in order to enable lazy style loading for potential subviews (such as Spectrum)
21454         - Extracted spectrum's css into a separate file
21455
21456         * WebCore.gypi:
21457         * WebCore.vcproj/WebCore.vcproj:
21458         * inspector/front-end/DOMExtension.js:
21459         (Element.prototype.positionAt):
21460         (Size):
21461         (Element.prototype.measurePreferredSize):
21462         * inspector/front-end/HeapSnapshotView.js:
21463         (WebInspector.HeapSnapshotView.prototype.willHide):
21464         (WebInspector.HeapSnapshotView.prototype._helpClicked):
21465         * inspector/front-end/Popover.js:
21466         (WebInspector.Popover):
21467         (WebInspector.Popover.prototype.show):
21468         (WebInspector.Popover.prototype.showView):
21469         (WebInspector.Popover.prototype._innerShow):
21470         (WebInspector.Popover.prototype.hide):
21471         (WebInspector.Popover.prototype.dispose):
21472         (WebInspector.Popover.prototype._positionElement):
21473         * inspector/front-end/Spectrum.js:
21474         (WebInspector.Spectrum.alphaDrag):
21475         (WebInspector.Spectrum):
21476         (WebInspector.Spectrum.prototype.wasShown):
21477         (WebInspector.SpectrumPopupHelper):
21478         (WebInspector.SpectrumPopupHelper.prototype.spectrum):
21479         (WebInspector.SpectrumPopupHelper.prototype.toggle):
21480         (WebInspector.SpectrumPopupHelper.prototype.show):
21481         (WebInspector.SpectrumPopupHelper.prototype.reposition):
21482         (WebInspector.SpectrumPopupHelper.prototype.hide):
21483         (WebInspector.ColorSwatch):
21484         (WebInspector.ColorSwatch.prototype.setColorString):
21485         * inspector/front-end/StylesSidebarPane.js:
21486         (WebInspector.StylesSidebarPane):
21487         (WebInspector.StylesSidebarPane.prototype.update):
21488         (WebInspector.StylesSidebarPane.prototype.willHide):
21489         (WebInspector.StylePropertyTreeElement.prototype.updateTitle.):
21490         * inspector/front-end/View.js:
21491         (WebInspector.View.prototype.measurePreferredSize):
21492         * inspector/front-end/WebKit.qrc:
21493         * inspector/front-end/elementsPanel.css:
21494         (.image-preview-container img):
21495         * inspector/front-end/inspector.css:
21496         (.swatch):
21497         (.swatch-inner):
21498         (.swatch-inner:hover):
21499         * inspector/front-end/spectrum.css: Added.
21500         (.spectrum-container):
21501         (.spectrum-top):
21502         (.spectrum-color):
21503         (.spectrum-display-value):
21504         (.spectrum-hue):
21505         (.spectrum-fill):
21506         (.spectrum-range-container):
21507         (.spectrum-range-container *):
21508         (.spectrum-range-container label):
21509         (.spectrum-range-container input):
21510         (.spectrum-dragger, .spectrum-slider):
21511         (.spectrum-sat):
21512         (.spectrum-val):
21513         (.spectrum-dragger):
21514         (.spectrum-slider):
21515         (.spectrum-container .swatch):
21516
21517 2012-11-06  Takashi Sakamoto  <tasak@google.com>
21518
21519         removeAttribute('style') not working in certain circumstances
21520         https://bugs.webkit.org/show_bug.cgi?id=99295
21521
21522         Reviewed by Ryosuke Niwa.
21523
21524         After web developers did style.XXXX=YYYY for some element, the inline
21525         style should be always removable by using "removeAttribute('style')".
21526         Currently it depends on whether web developers invokes
21527         getAttribute('style'), setAttribute('style), and so on. E.g. once they
21528         invoke getAttribute('style'), removeAttribute('style') works. This is
21529         very confusing behavior.
21530         Looking at Firefox browser, removeAttribute('style') always removes
21531         all inline styles.
21532
21533         Test: fast/css/remove-attribute-style.html
21534
21535         * css/StylePropertySet.cpp:
21536         (WebCore::StylePropertySet::clear):
21537         Added a new method to remove all style properties.
21538         (WebCore):
21539         * css/StylePropertySet.h:
21540         (StylePropertySet):
21541         * dom/Element.cpp:
21542         (WebCore::Element::removeAttribute):
21543         If 'style' is given but the element has no style attribute, the old
21544         code did nothing. However, if the element is styled element and has any
21545         inline styles, the inline styles should be removed. So invoke
21546         StyledElement::removeAllInlineStyleProperties and if any inline styles
21547         are removed, invoke style recalc, too.
21548         * dom/StyledElement.cpp:
21549         (WebCore::StyledElement::removeAllInlineStyleProperties):
21550         Added a new method to remove all inline style propeties. If any inline
21551         style is removed, invoke inlineStyleChanged() to force style recalc.
21552         (WebCore):
21553         * dom/StyledElement.h:
21554         (StyledElement):
21555
21556 2012-11-06  Alexei Filippov  <alph@chromium.org>
21557
21558         Web Inspector: dim size bar for expanded item in native memory snapshot grid
21559         https://bugs.webkit.org/show_bug.cgi?id=101062
21560
21561         Reviewed by Yury Semikhatsky.
21562
21563         * inspector/front-end/nativeMemoryProfiler.css:
21564         (.native-snapshot-view .data-grid .expanded div.size-bar):
21565
21566 2012-11-06  Shinya Kawanaka  <shinyak@chromium.org>
21567
21568         [Shadow] Using isUnknownPseudoElement() for shadow pseudo id seems confusing
21569         https://bugs.webkit.org/show_bug.cgi?id=100826
21570
21571         Reviewed by Hajime Morita.
21572
21573         We used isUnknownPseudoElement() for these 3 meanings: 1) the element is a custom pseudo-element (starting with 'x-'),
21574         2) the element is a webkit custom pseudo-element (starting with '-webkit-'), and 3) the element has an unknown type.
21575         We would like to distinguish them when parsing CSSSelector types. Also, we disable using (3) type for using
21576         shadowPseudoId.
21577
21578         In this patch, we allow using WebKitCustomPseudoElement in AuthorShadowRoot, and CustomPseudoElement in
21579         UAShadowRoot. However, we will disable them later.
21580
21581         Test: fast/dom/shadow/shadow-pseudo-id.html
21582
21583         * css/CSSGrammar.y.in: Now we can discard UNKNOWN type. It should not match anything.
21584         * css/CSSParser.cpp:
21585         (WebCore::CSSParser::updateSpecifiersWithElementName):
21586         (WebCore::CSSParser::updateSpecifiers):
21587         * css/CSSParserValues.h:
21588         (WebCore::CSSParserSelector::isCustomPseudoElement):
21589         (CSSParserSelector):
21590         * css/CSSSelector.cpp:
21591         (WebCore::CSSSelector::pseudoId):
21592         (WebCore::CSSSelector::parsePseudoType):
21593         (WebCore::CSSSelector::isCustomPseudoType): Returns true if the type is PseudoUserAgentCustomElement or PseudoWebKitCustomElement.
21594         (WebCore::CSSSelector::extractPseudoType):
21595         * css/CSSSelector.h:
21596         (CSSSelector):
21597         (WebCore::CSSSelector::isCustomPseudoElement):
21598         (WebCore):
21599         * css/CSSSelectorList.cpp:
21600         (WebCore::SelectorHasInvalidSelectorFunctor::operator()): We will reject all selectors which were judged as
21601         UNKNOWN before. i.e. It contians all three types for now.
21602         (WebCore::CSSSelectorList::hasInvalidSelector): Renamed.
21603         * css/CSSSelectorList.h:
21604         (CSSSelectorList):
21605         * css/RuleSet.cpp:
21606         (WebCore::RuleSet::addRule):
21607         * css/SelectorChecker.cpp:
21608         (WebCore::SelectorChecker::checkSelector):
21609         * dom/Element.cpp:
21610         (WebCore::Element::setShadowPseudoId):
21611         * dom/SelectorQuery.cpp:
21612         (WebCore::SelectorQueryCache::add):
21613
21614 2012-11-06  Shinya Kawanaka  <shinyak@chromium.org>
21615
21616         [Shadow] ShadowRoot should know the existence of elements having ElementShadow.
21617         https://bugs.webkit.org/show_bug.cgi?id=100922
21618
21619         Reviewed by Hajime Morita.
21620
21621         We count the elements having ElementShadow in ShadowRoot. This is a prepation patch for to solve Bug 100451.
21622         We have a count-up and count-down login in ShadowRoot::insertedInto and ShadowRoot::removedFrom.
21623
21624         For performance reason, we have a flag that an element should be unregistered in ShadowRoot.
21625
21626         Test: fast/dom/shadow/has-elementshadow.html
21627
21628         * dom/ShadowRoot.cpp:
21629         (WebCore::ShadowRoot::ShadowRoot):
21630         (WebCore::ShadowRoot::insertedInto): Count up the number of elements having ElementShadow. ElementShadow
21631         is created only when the oldest ShadowRoot is created, we only count up only when this ShadowRoot is oldest.
21632         (WebCore):
21633         (WebCore::ShadowRoot::removedFrom): Count down if we used this ShadowRoot for count up.
21634         * dom/ShadowRoot.h:
21635         (ShadowRoot):
21636         (WebCore::ShadowRoot::registerElementShadow):
21637         (WebCore::ShadowRoot::unregisterElementShadow):
21638         (WebCore::ShadowRoot::hasElementShadow):
21639         (WebCore::ShadowRoot::countElementShadow):
21640         * testing/Internals.cpp:
21641         (WebCore::Internals::countElementShadow):
21642         (WebCore):
21643         * testing/Internals.h:
21644         (Internals):
21645         * testing/Internals.idl:
21646
21647 2012-11-06  Pavel Feldman  <pfeldman@chromium.org>
21648
21649         Web Inspector: show "debugging session terminated" message when remote debuggign connection is closed unexpectedly.
21650         https://bugs.webkit.org/show_bug.cgi?id=101030
21651
21652         Reviewed by Vsevolod Vlasov.
21653
21654         * inspector/front-end/inspector.js:
21655         (WebInspector.loaded.WebInspector.socket.onclose):
21656         (WebInspector.loaded):
21657         (WebInspector.detached):
21658
21659 2012-11-06  Alexander Pavlov  <apavlov@chromium.org>
21660
21661         Web Inspector: [Overrides] Add Chrome for Android and Firefox for Android user agent strings
21662         https://bugs.webkit.org/show_bug.cgi?id=100666
21663
21664         Reviewed by Pavel Feldman.
21665
21666         * inspector/front-end/SettingsScreen.js:
21667         (WebInspector.UserAgentSettingsTab.prototype._createUserAgentSelectRowElement.get const):
21668
21669 2012-11-02  Yury Semikhatsky  <yurys@chromium.org>
21670
21671         Web Inspector: JavaScript web workers debugging crashes
21672         https://bugs.webkit.org/show_bug.cgi?id=101065
21673
21674         Reviewed by Alexander Pavlov.
21675
21676         Clear m_pageInspector when page inspector instance is deleted.
21677         Disable worker inspection when front-end disconnects.
21678
21679         Test: inspector-protocol/debugger-terminate-dedicated-worker-while-paused.html
21680
21681         * inspector/InspectorWorkerAgent.cpp:
21682         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::~WorkerFrontendChannel): notify
21683         WorkerMessagingProxy so that it can clear pointer to the channel.
21684
21685 2012-11-06  Nikita Vasilyev  <me@elv1s.ru>
21686
21687         Web Inspector: Console: wrap long URLs
21688         https://bugs.webkit.org/show_bug.cgi?id=100970
21689
21690         Reviewed by Yury Semikhatsky.
21691
21692         * inspector/front-end/inspector.css:
21693         (.console-message-url):
21694
21695 2012-11-05  Keishi Hattori  <keishi@webkit.org>
21696
21697         Introduce Day class to calendar picker
21698         https://bugs.webkit.org/show_bug.cgi?id=101194
21699
21700         Reviewed by Kent Tamura.
21701
21702         Introducing Day class so day, week, and month can all be abstracted. To
21703         solve some of the complexity around which months to show, I made
21704         CalendarPicker in charge of it. This also made YearMonthController and
21705         DaysTable independent of each other.
21706
21707         No new tests. Covered by existing calendar-picker-*.html tests.
21708
21709         * Resources/pagepopups/calendarPicker.js:
21710         (createUTCDate): Allow negative month or date.
21711         (parseDateString): Will return Day or Month depending on string format.
21712         (Day): Represents a day.
21713         (Day.parse): Parse yyyy-mm-dd.
21714         (Day.createFromDate): Creates a Day that contains a datetime.
21715         (Day.createFromToday): Creates Day for today. A method with the same name will be added to Week and Month in the future.
21716         (Day.prototype.equals): Returns true if they are the same.
21717         (Day.prototype.previous): Returns the previous day.
21718         (Day.prototype.next): Returns the next day.
21719         (Day.prototype.startDate): Returns the datetime that is the start of this day.
21720         (Day.prototype.endDate): Returns the datetime that is the start of this day.
21721         (Day.prototype.valueOf): Returns the milliseconds since epoch.
21722         (Day.prototype.toString): Returns an ISO date string.
21723         (Month): Fix bug in calculating month from value.
21724         (Month.prototype.endDate): Use Day.Maximum.
21725         (CalendarPicker): Added _currentMonth. yearMonthController and daysTable can be private members now.
21726         (CalendarPicker.prototype._layout):
21727         (CalendarPicker.prototype.handleToday): Use Day.createFromToday.
21728         (CalendarPicker.prototype.shouldShowMonth): Returns true if the month should be shown.
21729         (CalendarPicker.prototype.showMonth): Shows the given month. If the month is out of the range of months that should be shown, we clamp the month and show that.
21730         (CalendarPicker.prototype.currentMonth): Returns the current month that is shown.
21731         (YearMonthController): Removed _currentMonth.
21732         (YearMonthController.prototype.attachTo):
21733         (YearMonthController.prototype.setMonth):
21734         (YearMonthController.prototype._handleYearMonthChange): Use CalendarPicker.showMonth
21735         (YearMonthController.prototype.moveRelatively):
21736         (DaysTable):
21737         (CalendarPicker.prototype._stepMismatch): Made private.
21738         (CalendarPicker.prototype._outOfRange): Made private.
21739         (CalendarPicker.prototype.isValidDate): Take Day or Month instead of milliseconds since epoch.
21740         (DaysTable.prototype._renderMonth):
21741         (DaysTable.prototype.navigateToMonth): Shows a given month. Can use animation and leave the selection position as is.
21742         (DaysTable.prototype.selectRange): Select a range.
21743         (DaysTable.prototype._maybeSetPreviousMonth):
21744         (DaysTable.prototype._maybeSetNextMonth):
21745         (DaysTable.prototype._handleKey):
21746         (CalendarPicker.prototype._handleBodyKeyDown):
21747
21748 2012-11-05  Kenichi Ishibashi  <bashi@chromium.org>
21749
21750         Unreviewed, Adding #if PLATFORM(CHROMIUM) for the fix of
21751         https://bugs.webkit.org/show_bug.cgi?id=101009
21752
21753         This fix requires the most recent version of harfbuzz-ng.
21754         EFL port uses version 0.9.2, which doesn't have the fix.
21755
21756         * platform/graphics/harfbuzz/ng/HarfBuzzShaper.cpp:
21757         (WebCore::HarfBuzzShaper::shapeHarfBuzzRuns):
21758
21759 2012-11-05  Glenn Adams  <glenn@skynav.com>
21760
21761         Ensure acquireLineBreakIterator signature consistency on non-ICU ports.
21762         https://bugs.webkit.org/show_bug.cgi?id=101281
21763
21764         Reviewed by Ryosuke Niwa.
21765
21766         Fix (newly) inconsistent signature for acquireLineBreakIterator for non-ICU ports
21767         caused by http://trac.webkit.org/changeset/133529.
21768
21769         See new tests added from https://bugs.webkit.org/show_bug.cgi?id=89235.
21770
21771         * platform/text/TextBreakIterator.cpp:
21772         (WebCore::acquireLineBreakIterator):
21773         * platform/text/gtk/TextBreakIteratorGtk.cpp:
21774         (WebCore::setUpIterator):
21775         (WebCore::acquireLineBreakIterator):
21776         * platform/text/wince/TextBreakIteratorWinCE.cpp:
21777         (WebCore::acquireLineBreakIterator):
21778
21779 2012-11-05  Hayato Ito  <hayato@chromium.org>
21780
21781         Use switch/case statements instead of if/elseif in CSSSelector.cpp
21782         https://bugs.webkit.org/show_bug.cgi?id=100470
21783
21784         Reviewed by Ryosuke Niwa.
21785
21786         Minor clean up. We can get compiler warnings if we use switch/case statements here.
21787
21788         No changes to functionality, so no new tests.
21789
21790         * css/CSSSelector.cpp:
21791         (WebCore::CSSSelector::selectorText):
21792
21793 2012-11-05  Kenichi Ishibashi  <bashi@chromium.org>
21794
21795         [Chromium] Unicode combining diacritical aren't always combined on Linux
21796         https://bugs.webkit.org/show_bug.cgi?id=101009
21797
21798         Reviewed by Kent Tamura.
21799
21800         Add a space character to harfbuzzBuffer as pre-context. This will prevent
21801         harfbuzz from inserting dotted-circle.
21802
21803         Test: fast/text/international/combining-marks-position.html
21804
21805         * platform/graphics/harfbuzz/ng/HarfBuzzShaper.cpp:
21806         (WebCore::HarfBuzzShaper::shapeHarfBuzzRuns):
21807
21808 2012-11-05  Shinya Kawanaka  <shinyak@chromium.org>
21809
21810         LayoutTest fast/dom/shadow/shadowroot-type.html is failing on Windows
21811         https://bugs.webkit.org/show_bug.cgi?id=101201
21812
21813         Reviewed by Hajime Morita.
21814
21815         When we use a bit field for enum, Windows compiler seems returning some wrong value.
21816         We would like to avoid using a bit field for enum value.
21817
21818         * dom/ShadowRoot.cpp:
21819         (WebCore::ShadowRoot::create):
21820         * dom/ShadowRoot.h:
21821         (WebCore::ShadowRoot::type):
21822         (WebCore::ShadowRoot::setType):
21823         (ShadowRoot):
21824
21825 2012-11-05  Benjamin Poulain  <benjamin@webkit.org>
21826
21827         TransformOperationInfo's constructor is really slow
21828         https://bugs.webkit.org/show_bug.cgi?id=101143
21829
21830         Reviewed by Sam Weinig.
21831
21832         TransformOperationInfo() was slow for a few reasons:
21833         -The function used a lot of branches. The basic assumption is that the input
21834          is incorrect, thus every character is an opportunity to fail.
21835         -Every branch had to be tested in order. If the name was matching the last if()
21836          all the previous names had to be tested.
21837         -Since equalIgnoringCase() was used in every branch, it was forcing the case folding
21838          every time.
21839         -When the string is 16bits, the case folding was using ICU, which was incredibly inefficient.
21840
21841         This can be fixed by either
21842         1) Compute the lowercase name, then match it to a HashMap.
21843         2) Write a tree to quickly reduce the number of branch needed.
21844
21845         The first solution is not viable because 16bits strings case folding
21846         remains an important bottleneck.
21847
21848         Instead, the code now splits the names on simple characteristics to
21849         match any name in a limited number of branches.
21850
21851         The assumption is the input is correct, so & is used instead of && to
21852         avoid branches in favor of conditional instructions.
21853
21854         * css/CSSParser.cpp:
21855         (WebCore::TransformOperationInfo::TransformOperationInfo):
21856
21857 2012-11-05  Simon Fraser  <simon.fraser@apple.com>
21858
21859         RenderGeometryMap asserts when loading http://en.softonic.com/mac
21860         https://bugs.webkit.org/show_bug.cgi?id=101284
21861         <rdar://problem/11540560>
21862
21863         Reviewed by Tim Horton.
21864
21865         When FrameView::layout() calls document->updateStyleIfNeeded(), we
21866         can be in a state where FrameView::needsLayout() is false. However,
21867         this is a bad time to update compositing layers, because we're about
21868         to do layout, which will require us to update them again soon anyway,
21869         and some RenderLayers may not have been sized or positioned yet.
21870         
21871         Fix by adding a m_doingPreLayoutStyleUpdate member to FrameView,
21872         and toggling it around this call to updateStyleIfNeeded().
21873         Read this state in updateCompositingLayersAfterStyleChange(), which is
21874         now called unconditionally by recalcStyle(), but returns early
21875         if this flag is set, or layout is pending.
21876
21877         * dom/Document.cpp:
21878         (WebCore::Document::recalcStyle):
21879         * page/FrameView.cpp:
21880         (WebCore::FrameView::reset):
21881         (WebCore::FrameView::updateCompositingLayersAfterStyleChange):
21882         (WebCore::FrameView::layout):
21883         * page/FrameView.h:
21884         (FrameView):
21885
21886 2012-11-05  Beth Dakin  <bdakin@apple.com>
21887
21888         https://bugs.webkit.org/show_bug.cgi?id=101275
21889         Clean up ScrollingConstraints.h
21890
21891         Reviewed by Simon Fraser.
21892
21893         This class cleans up ScrollingConstraints.h by removing the constructors since the 
21894         compiler will generate those constructors for us anyway. The patch also makes the 
21895         two override functions private.
21896         * page/scrolling/ScrollingConstraints.h:
21897         (ViewportConstraints):
21898         (FixedPositionViewportConstraints):
21899         (StickyPositionViewportConstraints):
21900
21901 2012-11-05  Simon Fraser  <simon.fraser@apple.com>
21902
21903         Make Document::updateStyleIfNeeded() non-virtual
21904         https://bugs.webkit.org/show_bug.cgi?id=101273
21905
21906         Reviewed by Eric Seidel.
21907
21908         Document::updateStyleIfNeeded() has been virtual like forever, but
21909         no-one ever overrides it, so make it non-virtual.
21910
21911         * dom/Document.h:
21912         (Document):
21913
21914 2012-11-05  Philip Rogers  <pdr@google.com>
21915
21916         Unblock SVG external references
21917         https://bugs.webkit.org/show_bug.cgi?id=100635
21918
21919         Reviewed by Adam Barth.
21920
21921         This patch reverts r132849 and r132869 because the potential XSS issue
21922         turned out to not be an issue after all.
21923
21924         Covered by existing tests, many of which are re-whitelisted with this patch.
21925
21926         * loader/cache/CachedResourceLoader.cpp:
21927         (WebCore::CachedResourceLoader::canRequest):
21928
21929 2012-11-05  Beth Dakin  <bdakin@apple.com>
21930
21931         https://bugs.webkit.org/show_bug.cgi?id=101001
21932         Pages with position:fixed elements should still be able to scroll on 
21933         the scrolling thread
21934         -and corresponding-
21935         <rdar://problem/10857315>
21936
21937         Reviewed by Simon Fraser.
21938
21939         This patch adds two new classes. ScrollingStateFixedNode is a class 
21940         to represent fixed nodes in the state tree, and 
21941         ScrollingTreeFixedNode represents fixed node in the scrolling tree 
21942         over on the scrolling thread.
21943         * WebCore.xcodeproj/project.pbxproj:
21944
21945         When we are (non-programatically) scrolling fixed objects on the 
21946         scrolling thread, we do not want to do any work here. 
21947         * page/FrameView.cpp:
21948         (WebCore::FrameView::updateFixedElementsAfterScrolling):
21949
21950         Whenever we sync the position of the main frame's layer, we have to 
21951         do the same for scrolling tree children.
21952         * page/scrolling/ScrollingCoordinator.cpp:
21953         (WebCore::ScrollingCoordinator::updateMainFrameScrollPosition):
21954
21955         New ScrollingNodeType -- FixedNode, yay! And two new functions 
21956         specific to dealing with FixedNodes.
21957         * page/scrolling/ScrollingCoordinator.h:
21958         (WebCore::ScrollingCoordinator::updateViewportConstrainedNode):
21959         (WebCore::ScrollingCoordinator::syncChildPositions):
21960
21961         This is the new class that represents fixed nodes in the state tree. 
21962         All of the changed properties are stored within 
21963         FixedPositionViewportConstraints.
21964         * page/scrolling/ScrollingStateFixedNode.cpp: Added.
21965         (WebCore):
21966         (WebCore::ScrollingStateFixedNode::create):
21967         (WebCore::ScrollingStateFixedNode::ScrollingStateFixedNode):
21968         (WebCore::ScrollingStateFixedNode::~ScrollingStateFixedNode):
21969         (WebCore::ScrollingStateFixedNode::updateConstraints):
21970         (WebCore::ScrollingStateFixedNode::dumpProperties):
21971         * page/scrolling/ScrollingStateFixedNode.h: Added.
21972         (WebCore):
21973         (ScrollingStateFixedNode):
21974         (WebCore::ScrollingStateFixedNode::viewportConstraints):
21975         (WebCore::toScrollingStateFixedNode):
21976
21977         Make sure to create the right type of clone for each node.
21978         * page/scrolling/ScrollingStateNode.cpp:
21979         (WebCore::ScrollingStateNode::cloneAndReset):
21980
21981         Now that m_children may be anything other than null, I found this 
21982         bug. We encounter it when the parameter to removeChild is this and we 
21983         want to remove all of our children. In that case, this is obviously 
21984         not found in its own child array.
21985         (WebCore::ScrollingStateNode::removeChild):
21986
21987         ScrollingStateNode now caches the GraphicsLayer in addition to the 
21988         PlatformLayer. This will allow us to sync the GraphicsLayer position 
21989         at the appropriate times.
21990         * page/scrolling/ScrollingStateNode.h:
21991         (WebCore::ScrollingStateNode::isScrollingStateFixedNode):
21992         (WebCore::ScrollingStateNode::graphicsLayer):
21993         (ScrollingStateNode):
21994
21995         Handle fixed nodes.
21996         * page/scrolling/ScrollingTree.cpp:
21997         (WebCore::ScrollingTree::updateTreeFromStateNode):
21998
21999         New function parentScrollPositionDidChange() is called on children 
22000         when the parent has scrolled.
22001         * page/scrolling/ScrollingTreeNode.h:
22002         (ScrollingTreeNode):
22003         * page/scrolling/ScrollingTreeScrollingNode.h:
22004         (ScrollingTreeScrollingNode):
22005
22006         Return true for supportsFixedPositionLayers(). 
22007         * page/scrolling/mac/ScrollingCoordinatorMac.h:
22008         (ScrollingCoordinatorMac):
22009
22010         Handle fixed nodes.
22011         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
22012         (WebCore::ScrollingCoordinatorMac::attachToStateTree):
22013
22014         Now that m_children can be non-null I caught this pre-existing bug 
22015         where we would come times remove a node without updating the HashMap. 
22016         This patch fixes that by consolidating the removal into one function.
22017         (WebCore::ScrollingCoordinatorMac::removeNode):
22018         (WebCore::ScrollingCoordinatorMac::detachFromStateTree):
22019         (WebCore::ScrollingCoordinatorMac::clearStateTree):
22020
22021         Update the GraphicsLayers to reflect the new position that the 
22022         Scrolling thread has moved the underlying CALayer to already.
22023         (WebCore::ScrollingCoordinatorMac::syncChildPositions):
22024
22025         Pass new constraints over to the appropriate state node.
22026         (WebCore::ScrollingCoordinatorMac::updateViewportConstrainedNode):
22027
22028         Cache the GraphicsLayer in addition to the PlatformLayer.
22029         * page/scrolling/mac/ScrollingStateNodeMac.mm:
22030         (WebCore::ScrollingStateNode::setScrollLayer):
22031
22032         Here is the new class that represents fixed nodes over on the 
22033         scrolling thread. 
22034         * page/scrolling/mac/ScrollingTreeFixedNode.h: Added.
22035         (WebCore):
22036         (ScrollingTreeFixedNode):
22037         * page/scrolling/mac/ScrollingTreeFixedNode.mm: Added.
22038         (WebCore):
22039         (WebCore::ScrollingTreeFixedNode::create):
22040         (WebCore::ScrollingTreeFixedNode::ScrollingTreeFixedNode):
22041         (WebCore::ScrollingTreeFixedNode::~ScrollingTreeFixedNode):
22042         (WebCore::ScrollingTreeFixedNode::update):
22043
22044         This is where the magic happens. re-position the fixed object when 
22045         its parent has scrolled so that it appears to have not moved at all.
22046         (WebCore::ScrollingTreeFixedNode::parentScrollPositionDidChange):
22047
22048         Whenever we change the position of a scrolling layer, tell our 
22049         children.
22050         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
22051         (WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):
22052
22053         Handle fixed nodes.
22054         * rendering/RenderLayerBacking.cpp:
22055         (WebCore::RenderLayerBacking::attachToScrollingCoordinator):
22056
22057         detachFromScrollingCoordinator() needs to be public so that it can be 
22058         called from RenderLayerCompositor for fixed nodes.
22059         * rendering/RenderLayerBacking.h:
22060         (RenderLayerBacking):
22061
22062         RenderLayerCompositor takes control of attaching and detaching fixed 
22063         nodes to/from the ScrollingCoordinator. 
22064         * rendering/RenderLayerCompositor.cpp:
22065         (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
22066         (WebCore::RenderLayerCompositor::didFlushChangesForLayer):
22067         (WebCore::RenderLayerCompositor::updateBacking):
22068         (WebCore::RenderLayerCompositor::layerWillBeRemoved):
22069         (WebCore::RenderLayerCompositor::didMoveOnscreen):
22070         (WebCore::RenderLayerCompositor::willMoveOffscreen):
22071         (WebCore::RenderLayerCompositor::clearBackingForLayerIncludingDescendants):
22072         (WebCore::isRootmostFixedOrStickyLayer):
22073         (WebCore):
22074         (WebCore::RenderLayerCompositor::updateViewportConstraintStatus):
22075         (WebCore::RenderLayerCompositor::addViewportConstrainedLayer):
22076         (WebCore::RenderLayerCompositor::removeViewportConstrainedLayer):
22077         (WebCore::RenderLayerCompositor::computeViewportConstraints):
22078         (WebCore::nearestScrollingCoordinatorAncestor):
22079         (WebCore::RenderLayerCompositor::registerOrUpdateViewportConstrainedLayer):
22080         (WebCore::RenderLayerCompositor::unregisterViewportConstrainedLayer):
22081         (WebCore::RenderLayerCompositor::registerAllViewportConstrainedLayers):
22082         (WebCore::RenderLayerCompositor::unregisterAllViewportConstrainedLayers):
22083         * rendering/RenderLayerCompositor.h:
22084         (WebCore):
22085         (RenderLayerCompositor):
22086
22087 2012-11-05  Geoffrey Garen  <ggaren@apple.com>
22088
22089         Cleaned up the Font class in preparation for optimizing kerning and ligatures
22090         https://bugs.webkit.org/show_bug.cgi?id=101258
22091
22092         Reviewed by Dan Bernstein.
22093
22094         * platform/graphics/Font.h:
22095         (WebCore::Font::typesettingFeatures):
22096         (WebCore::Font::computeTypesettingFeatures): Compute and cache our
22097         typesetting features instead of recomputing each time a client asks
22098         for them. This makes the class interface easier to use because
22099         "typesettingFeatures()" can appear in more than one expression without
22100         undue performance cost. This may also be a small speedup to code that
22101         calls typesettingFeatures() often for other reasons.
22102
22103         * platform/graphics/Font.cpp:
22104         (WebCore::Font::Font):
22105         (WebCore::Font::operator=):
22106         (WebCore::Font::update): Ditto.
22107
22108         (WebCore::Font::width): Unforked the width() function so all width-related
22109         interfaces can benefit from optimization without duplicate code.
22110
22111 2012-11-05  Peng Huang  <penghuang@google.com>
22112
22113         Webkit does not handle some media keys correctly On Linux gtk platform.
22114         https://bugs.webkit.org/show_bug.cgi?id=101221
22115
22116         Reviewed by Alexey Proskuryakov.
22117
22118         Add media keyboard support on Linux gtk platform.
22119
22120         * platform/chromium/KeyCodeConversionGtk.cpp:
22121         (WebCore::windowsKeyCodeForKeyEvent):
22122
22123 2012-11-05  Glenn Adams  <glenn@skynav.com>
22124
22125         Add support to -webkit-line-break property for CSS3 Text line-break property values and semantics.
22126         https://bugs.webkit.org/show_bug.cgi?id=89235
22127
22128         Reviewed by Eric Seidel.
22129
22130         See also wiki documentation at:
22131         [1] http://trac.webkit.org/wiki/LineBreaking
22132         [2] http://trac.webkit.org/wiki/LineBreakingCSS3Mapping
22133
22134         Web exposed changes include:
22135         (1) The default (initial) value for -webkit-line-break becomes 'auto', instead of 'normal';
22136         (2) The values 'auto', 'loose', 'normal', and 'strict' are added to -webkit-line-break;
22137         (3) See [2] above for details regarding interpretation.
22138
22139         Tests: css3/line-break/line-break-auto-centered.html
22140                css3/line-break/line-break-auto-half-kana.html
22141                css3/line-break/line-break-auto-hyphens.html
22142                css3/line-break/line-break-auto-inseparables.html
22143                css3/line-break/line-break-auto-iteration-marks.html
22144                css3/line-break/line-break-auto-postfixes.html
22145                css3/line-break/line-break-auto-prefixes.html
22146                css3/line-break/line-break-auto-sound-marks.html
22147                css3/line-break/line-break-loose-centered.html
22148                css3/line-break/line-break-loose-half-kana.html
22149                css3/line-break/line-break-loose-hyphens.html
22150                css3/line-break/line-break-loose-inseparables.html
22151                css3/line-break/line-break-loose-iteration-marks.html
22152                css3/line-break/line-break-loose-postfixes.html
22153                css3/line-break/line-break-loose-prefixes.html
22154                css3/line-break/line-break-loose-sound-marks.html
22155                css3/line-break/line-break-normal-centered.html
22156                css3/line-break/line-break-normal-half-kana.html
22157                css3/line-break/line-break-normal-hyphens.html
22158                css3/line-break/line-break-normal-inseparables.html
22159                css3/line-break/line-break-normal-iteration-marks.html
22160                css3/line-break/line-break-normal-postfixes.html
22161                css3/line-break/line-break-normal-prefixes.html
22162                css3/line-break/line-break-normal-sound-marks.html
22163                css3/line-break/line-break-strict-centered.html
22164                css3/line-break/line-break-strict-half-kana.html
22165                css3/line-break/line-break-strict-hyphens.html
22166                css3/line-break/line-break-strict-inseparables.html
22167                css3/line-break/line-break-strict-iteration-marks.html
22168                css3/line-break/line-break-strict-postfixes.html
22169                css3/line-break/line-break-strict-prefixes.html
22170                css3/line-break/line-break-strict-sound-marks.html
22171
22172         * platform/text/LineBreakIteratorPoolICU.h:
22173         (WebCore::LineBreakIteratorPool::makeLocaleWithBreakKeyword):
22174         Add static function to construct ICU locale argument (also used as pool key) with additional
22175         break keyword.
22176         (WebCore::LineBreakIteratorPool::take):
22177         (WebCore::LineBreakIteratorPool::put):
22178         (LineBreakIteratorPool):
22179         Remove direct dependency from ICU library (and types), moving that dependency into
22180         new {open,close}LineBreakIterator() functions (defined in TextBreakIteratorICU.cpp).
22181         Update to take line break mode into account.
22182         Create (and cache) different break iterators depending on line break mode (in addition to locale),
22183         which entails expanding pool entry key format to optionally append "@break=" +
22184         "loose"|"normal"|"strict" keyword to locale string.
22185
22186         * platform/text/TextBreakIterator.h:
22187         (WebCore::LazyLineBreakIterator::LazyLineBreakIterator):
22188         (WebCore::LazyLineBreakIterator::isLooseCJKMode):
22189         (WebCore::LazyLineBreakIterator::get):
22190         (WebCore::LazyLineBreakIterator::reset):
22191         (LazyLineBreakIterator):
22192         Define LineBreakIteratorMode enumeration for use in TextBreakIterator et al.
22193         Add state member to indicate line break mode.
22194
22195         * platform/text/TextBreakIteratorICU.cpp:
22196         (WebCore::acquireLineBreakIterator):
22197         Use new line break mode when making iterator from pool.
22198         Handle change of return type of LineBreakIteratorPool::take() to non-ICU type,
22199         i.e., TextBreakIterator* instead of ICU's UBreakIterator*.
22200         (WebCore::releaseLineBreakIterator):
22201         Handle change of parameter type of LineBreakIteratorPool::put() to non-ICU type,
22202         i.e., TextBreakIterator* instead of ICU's UBreakIterator*.
22203         (WebCore::isCJKLocale):
22204         New functions for determining if CJK rules apply.
22205         (WebCore::openLineBreakIterator):
22206         New function for abstracting opening of ICU style line break iterator. This is now
22207         used in LineBreakIteratorPoolICU.h rather than having direct ICU API dependency there.
22208         This function also takes into account the line break mode.
22209         (WebCore::closeLineBreakIterator):
22210         (WebCore::mapLineIteratorModeToRules):
22211         New function for abstracting closing of ICU style line break iterator. This is now
22212         used in LineBreakIteratorPoolICU.h rather than having direct ICU API dependency there.
22213
22214         * rendering/RenderBlockLineLayout.cpp:
22215         (WebCore::RenderBlock::LineBreaker::nextLineBreak):
22216         Pass line break iterator mode flag when reseting LazyLineBreakIterator.
22217         Add looseMode local variable to prevent need for computing under isBreakable().
22218
22219         * rendering/RenderText.cpp:
22220         (WebCore::mapLineBreakToIteratorMode):
22221         Add implementation for mapLineBreakToIteratorMode(), used by both RenderText::computePreferredLogicalWidths
22222         and RenderBlock::LineBreaker::nextLineBreak.
22223         (WebCore::RenderText::computePreferredLogicalWidths):
22224         Ensure (lazy line) breakIterator is initialized for line break mode.
22225         Ensure isBreakable() is passed loose mode flag to match behavior in RenderBlock::LineBreaker::nextLineBreak.
22226
22227         * rendering/RenderText.h:
22228         (WebCore):
22229         Add declaration for mapLineBreakToIteratorMode(), used by both RenderText::computePreferredLogicalWidths
22230         and RenderBlock::LineBreaker::nextLineBreak.
22231
22232         * rendering/break_lines.cpp:
22233         (WebCore):
22234         Introduce two (local) enums NBSPBehavior and LooseBehavior for expanding template on nextBreakablePosition
22235         to include loose mode parameter.
22236         (WebCore::isBreakableSpace):
22237         Add externally specified loose mode parameter to prevent need to invoke line break iterator
22238         accessor method on each invocation. Use new loose mode flavors off NBP functions.
22239         (WebCore::needsLineBreakIterator):
22240         Introduce loose mode behavior template parameter to optimize loose mode behavior code path in order
22241         to prevent regression to non loose mode path.
22242         (WebCore::nextBreakablePosition):
22243         (WebCore::nextBreakablePositionIgnoringNBSP):
22244         Use new template parameter enums described above.
22245         (WebCore::nextBreakablePositionIgnoringNBSPLoose):
22246         (WebCore::nextBreakablePositionLoose):
22247         Introduce two additional 'loose' mode flavors of NBP template expansions.
22248
22249         * rendering/break_lines.h:
22250         (WebCore):
22251         (WebCore::isBreakable):
22252         Add externally specified loose mode parameter to prevent need to invoke line break iterator
22253         accessor method on each invocation.
22254
22255 2012-11-05  Adam Barth  <abarth@webkit.org>
22256
22257         webkitRegionLayoutUpdate is incorrectly named
22258         https://bugs.webkit.org/show_bug.cgi?id=100335
22259
22260         Reviewed by Ojan Vafai.
22261
22262         DOM event names are supposed to be lower case.
22263
22264         * dom/EventNames.h:
22265         (WebCore):
22266         * dom/WebKitNamedFlow.cpp:
22267         (WebCore::WebKitNamedFlow::dispatchRegionLayoutUpdateEvent):
22268
22269 2012-11-05  Adam Barth  <abarth@webkit.org>
22270
22271         [V8] IntrusiveDOMWrapperMap should be usable for more than just Nodes
22272         https://bugs.webkit.org/show_bug.cgi?id=101110
22273
22274         Reviewed by Kentaro Hara.
22275
22276         This patch generalizes our support for storing wrappers in DOM objects
22277         to be usable for more than just nodes. After this patch, any object
22278         with a ScriptWrappable base class will have its wrapper stored inline
22279         in the object in the main world.
22280
22281         To achieve this goal, this patch hides the details of how we map from
22282         objects to wrappers inside DOMDataStore and then removes the
22283         IntrusiveDOMWrapperMap class entirely. This approach lets us remove the
22284         DOMWrapperMap base class and make all of these functions non-virtual.
22285
22286         * UseV8.cmake:
22287         * WebCore.gypi:
22288             - Remove deleted files.
22289         * bindings/scripts/CodeGeneratorV8.pm:
22290         (GenerateHeader):
22291         (GenerateNormalAttrGetter):
22292         (GenerateConstructorCallback):
22293         (GenerateNamedConstructorCallback):
22294         (GenerateToV8Converters):
22295             - Rather than grabbing at the DOMWrapperMap directly, we now ask
22296               the DOMDataStore to do this work for us.
22297         * bindings/scripts/test/V8/V8Float64Array.h:
22298         (WebCore::V8Float64Array::wrap):
22299         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
22300         (WebCore::V8TestActiveDOMObject::wrap):
22301         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
22302         (WebCore::V8TestCustomNamedGetter::wrap):
22303         * bindings/scripts/test/V8/V8TestEventConstructor.h:
22304         (WebCore::V8TestEventConstructor::wrap):
22305         * bindings/scripts/test/V8/V8TestEventTarget.h:
22306         (WebCore::V8TestEventTarget::wrap):
22307         * bindings/scripts/test/V8/V8TestException.h:
22308         (WebCore::V8TestException::wrap):
22309         * bindings/scripts/test/V8/V8TestInterface.h:
22310         (WebCore::V8TestInterface::wrap):
22311         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
22312         (WebCore::V8TestMediaQueryListListener::wrap):
22313         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
22314         (WebCore::V8TestNamedConstructor::wrap):
22315         * bindings/scripts/test/V8/V8TestNode.cpp:
22316         (WebCore::V8TestNode::constructorCallback):
22317         (WebCore::V8TestNode::wrapSlow):
22318         * bindings/scripts/test/V8/V8TestObj.cpp:
22319         (WebCore::TestObjV8Internal::readOnlyTestObjAttrAttrGetter):
22320         * bindings/scripts/test/V8/V8TestObj.h:
22321         (WebCore::V8TestObj::wrap):
22322         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
22323         (WebCore::V8TestSerializedScriptValueInterface::wrap):
22324         * bindings/v8/DOMDataStore.cpp:
22325             - Updated run-bindings-test results.
22326         (WebCore::DOMDataStore::DOMDataStore):
22327         (WebCore::DOMDataStore::~DOMDataStore):
22328             - Simplify constructor and destructor now that there is only one
22329               hash map.
22330         (WebCore::DOMDataStore::current):
22331             - Now that V8DOMMap.cpp doesn't handle the null isolate case, we
22332               need to handle it here.
22333         (WebCore::DOMDataStore::reportMemoryUsage):
22334             - Simplfied now that there is only one wrapper map.
22335         (WebCore::DOMDataStore::weakCallback):
22336             - Moved from IntrusiveDOMWrapperMap.h
22337         * bindings/v8/DOMDataStore.h:
22338         (WebCore::DOMDataStore::get):
22339         (WebCore::DOMDataStore::set):
22340             - These functions now handle the intrusive case with a branch
22341               rather than with a virtual function call. In many cases, the
22342               branch can be optimized away by the compiler when the overloaded
22343               inline functions are inlined.
22344         (WebCore::DOMDataStore::wrapperIsStoredInObject):
22345             - Overloaded functions to determine whether to store the wrapper
22346               inside the object or in the hashmap.
22347         (WebCore::DOMDataStore::getWrapperFromObject):
22348         (WebCore::DOMDataStore::storeWrapperInObject):
22349             - Overloaded functions to get/set the wrapper from inside the
22350               object itself.
22351         * bindings/v8/DOMWrapperMap.h:
22352         (WebCore::DOMWrapperHashMap::get):
22353         (WebCore::DOMWrapperHashMap::set):
22354         (WebCore::DOMWrapperHashMap::clear):
22355         (WebCore::DOMWrapperHashMap::reportMemoryUsage):
22356         (WebCore::DOMWrapperHashMap::remove):
22357             - These functions are no longer virtual.
22358         * bindings/v8/DOMWrapperWorld.h:
22359         * bindings/v8/IntrusiveDOMWrapperMap.h: Removed.
22360         * bindings/v8/ScriptProfiler.cpp:
22361         * bindings/v8/SerializedScriptValue.cpp:
22362         (WebCore::neuterBinding):
22363             - We need to keep the type information slightly longer so that we
22364               look in the right wrapper map.
22365         * bindings/v8/V8DOMMap.cpp: Removed.
22366         * bindings/v8/V8DOMMap.h: Removed.
22367         * bindings/v8/V8DOMWindowShell.cpp:
22368         * bindings/v8/V8DOMWrapper.cpp:
22369         * bindings/v8/V8DOMWrapper.h:
22370         (WebCore::V8DOMWrapper::getCachedWrapper):
22371             - Defer this work to the store.
22372         (WebCore::V8DOMWrapper::setWrapperClass):
22373             - An overloaded function to set the right wrapper class.
22374         (WebCore::V8DOMWrapper::setJSWrapperForDOMObject):
22375             - This function is now general enough to handle ever kind of object.
22376         * bindings/v8/V8GCController.cpp:
22377         * bindings/v8/V8NPObject.cpp:
22378         * bindings/v8/WorkerContextExecutionProxy.cpp:
22379         * bindings/v8/WorkerScriptController.cpp:
22380         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
22381         (WebCore::v8HTMLImageElementConstructorCallback):
22382             - Call the more general function (instead of the now-deleted specialized function).
22383
22384 2012-11-05  Alexey Proskuryakov  <ap@apple.com>
22385
22386         Get rid of setCookieStoragePrivateBrowsingEnabled.
22387         https://bugs.webkit.org/show_bug.cgi?id=101247
22388
22389         Reviewed by Brady Eidson.
22390
22391         We were only doing anything here on Mac, and only because we couldn't know if
22392         sessions were in use. But sessions are always in use, and those obsolete changing
22393         cookie storage explicitly.
22394
22395         * platform/network/win/CookieStorageWin.cpp: Removed.
22396         * PlatformWinCE.cmake:
22397         * WebCore.gypi:
22398         No more CookieStorageWin.cpp with an empty implementation.
22399     
22400         * WebCore.exp.in:
22401         * platform/mac/WebCoreSystemInterface.h:
22402         * platform/mac/WebCoreSystemInterface.mm:
22403         We no longer need this WKSI function.
22404
22405         * page/Settings.cpp: (WebCore::Settings::setPrivateBrowsingEnabled):
22406         Removed the only call to setCookieStoragePrivateBrowsingEnabled().
22407
22408         * platform/network/CookieStorage.h:
22409         * platform/network/cf/CookieStorageCFNet.cpp:
22410         * platform/network/curl/CookieJarCurl.cpp:
22411         * platform/network/soup/CookieStorageSoup.cpp:
22412         * platform/qt/TemporaryLinkStubsQt.cpp:
22413         Removed empty setCookieStoragePrivateBrowsingEnabled implementations.
22414
22415         * platform/network/mac/CookieStorageMac.mm: This function used to have a FIXME
22416         that we should observe private storage while in private browsing mode. I don't think
22417         that it was correct - Safari doesn't display content of private storage, and thus
22418         doesn't need to know about changes.
22419         The removal of this function has an effect on WebKit1 clients that enable private
22420         browsing. We used to globally change cookie storage, even for loads not initiated
22421         by WebKit. Now we match API description: "If private browsing is enabled, WebKit
22422         will not store information about sites the user visits."
22423
22424 2012-11-05  Florin Malita  <fmalita@chromium.org>
22425
22426         Crash when mixing layers, foreignObjects and SVG hidden containers
22427         https://bugs.webkit.org/show_bug.cgi?id=87297
22428
22429         Reviewed by Dirk Schulze.
22430
22431         Foreign objects may introduce content which requires layers, but layer creation is
22432         suppressed within RenderSVGHiddenContainer subtrees and this yields an inconsistent render
22433         tree state. This patch prevents foreignObject renderer instantiation under
22434         RenderSVGHiddenContainers.
22435
22436         Test: svg/foreignObject/foreign-object-defs-crash.svg
22437
22438         * svg/SVGForeignObjectElement.cpp:
22439         (WebCore::SVGForeignObjectElement::rendererIsNeeded):
22440         (WebCore):
22441         * svg/SVGForeignObjectElement.h:
22442         (SVGForeignObjectElement):
22443
22444 2012-11-05  Simon Fraser  <simon.fraser@apple.com>
22445
22446         Remove the unused m_fixedPositionedElements from RenderView
22447         https://bugs.webkit.org/show_bug.cgi?id=101251
22448
22449         Reviewed by Anders Carlsson.
22450
22451         m_fixedPositionedElements was completely unused. Remove it
22452         and the related typedef.
22453
22454         * rendering/RenderView.h:
22455         (RenderView):
22456
22457 2012-11-05  Simon Fraser  <simon.fraser@apple.com>
22458
22459         Fix layer borders to cleaning appear and disappear on switching
22460         https://bugs.webkit.org/show_bug.cgi?id=101136
22461
22462         Reviewed by Sam Weinig.
22463
22464         GraphicsLayers decided whether to show layer borders based
22465         on a callback through the GraphicsLayerClient. This made it
22466         hard to manage state, resulting in a failure to cleanly
22467         hide layers when toggled off via the preference.
22468         
22469         Changed the layer border and repaint counter visibility to be bits
22470         stored on GraphicsLayer just like other properties, with getters
22471         and setters. RenderLayerBacking now updates these debug
22472         indicators when we update other compositing layer properties.
22473         
22474         In GraphicsLayerCA, avoid calling updateDebugIndicators() explicitly
22475         in several places by setting the change flag DebugIndicatorsChanged
22476         for properties whose values affect the appearance of the debug border.
22477
22478         Removed the GraphicsLayerClient methods showDebugBorders() and
22479         showRepaintCounter() which are no longer required.
22480
22481         * platform/graphics/GraphicsLayer.cpp:
22482         (WebCore::GraphicsLayer::GraphicsLayer):
22483         (WebCore::GraphicsLayer::updateDebugIndicators):
22484         * platform/graphics/GraphicsLayer.h:
22485         (WebCore::GraphicsLayer::setShowDebugBorder):
22486         (WebCore::GraphicsLayer::isShowingDebugBorder):
22487         (WebCore::GraphicsLayer::setShowRepaintCounter):
22488         (WebCore::GraphicsLayer::isShowingRepaintCounter):
22489         (WebCore::GraphicsLayer::repaintCount):
22490         (WebCore::GraphicsLayer::incrementRepaintCount):
22491         * platform/graphics/GraphicsLayerClient.h:
22492         * platform/graphics/ca/GraphicsLayerCA.cpp:
22493         (WebCore::GraphicsLayerCA::GraphicsLayerCA):
22494         (WebCore::GraphicsLayerCA::setMasksToBounds):
22495         (WebCore::GraphicsLayerCA::setDrawsContent):
22496         (WebCore::GraphicsLayerCA::platformCALayerShowRepaintCounter):
22497         (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
22498         (WebCore::GraphicsLayerCA::updateMasksToBounds):
22499         (WebCore::GraphicsLayerCA::updateLayerDrawsContent):
22500         (WebCore::GraphicsLayerCA::updateDebugBorder):
22501         (WebCore::GraphicsLayerCA::setShowDebugBorder):
22502         (WebCore::GraphicsLayerCA::setShowRepaintCounter):
22503         (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
22504         (WebCore::GraphicsLayerCA::setupContentsLayer):
22505         (WebCore::GraphicsLayerCA::cloneLayer):
22506         * platform/graphics/ca/GraphicsLayerCA.h:
22507         (GraphicsLayerCA):
22508         (WebCore::GraphicsLayerCA::platformCALayerShowDebugBorders):
22509         * rendering/RenderLayerBacking.cpp:
22510         (WebCore::RenderLayerBacking::updateDebugIndicators):
22511         * rendering/RenderLayerBacking.h:
22512         (RenderLayerBacking):
22513         * rendering/RenderLayerCompositor.cpp:
22514         (WebCore::RenderLayerCompositor::updateBacking):
22515         * rendering/RenderLayerCompositor.h:
22516         (RenderLayerCompositor):
22517
22518 2012-11-05  Genevieve Mak  <gmak@rim.com>
22519
22520         [BLACKBERRY] Update touch code to reflect touch refactor
22521         https://bugs.webkit.org/show_bug.cgi?id=101227
22522
22523         Reviewed by Rob Buis.
22524
22525         PR #2706785
22526         Reviewed Internally by: Mike Lattanzio
22527
22528         * platform/blackberry/PlatformTouchEventBlackBerry.cpp:
22529         (WebCore::touchEventType):
22530         (WebCore::PlatformTouchEvent::PlatformTouchEvent):
22531
22532 2012-11-05  Alok Priyadarshi  <alokp@chromium.org>
22533
22534         [chromium] Pass canPaintLCDText to WebContentLayerClient::paintContents
22535         https://bugs.webkit.org/show_bug.cgi?id=99083
22536
22537         Reviewed by Stephen White.
22538
22539         Use LCD text setting passed to WebContentLayerClient::paintContents instead of turning it off for all composited layers.
22540
22541         No new tests needed. This patch does not change anything functionally.
22542
22543         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
22544         (WebCore::GraphicsLayerChromium::setContentsOpaque):
22545         (WebCore::GraphicsLayerChromium::paint):
22546         * platform/graphics/chromium/OpaqueRectTrackingContentLayerDelegate.cpp:
22547         (WebCore::OpaqueRectTrackingContentLayerDelegate::paintContents):
22548         * platform/graphics/chromium/OpaqueRectTrackingContentLayerDelegate.h:
22549         (OpaqueRectTrackingContentLayerDelegate):
22550
22551 2012-11-05  Stephen White  <senorblanco@chromium.org>
22552
22553         [chromium] Build fix after http://trac.webkit.org/changeset/133488.
22554         Removed a deleted file.  Unreviewed.
22555
22556         * WebCore.gypi:
22557
22558 2012-11-05  Kentaro Hara  <haraken@chromium.org>
22559
22560         [V8] toV8(impl) should return null if impl is 0
22561         https://bugs.webkit.org/show_bug.cgi?id=101206
22562
22563         Reviewed by Adam Barth.
22564
22565         toV8(impl) should return null if impl is 0. However,
22566         V8HTMLCollection::toV8() does not have the null check.
22567         All other toV8()s return null.
22568
22569         No tests. I think there will be no call path that hits the change.
22570
22571         * bindings/v8/custom/V8HTMLCollectionCustom.cpp:
22572         (WebCore::toV8):
22573
22574 2012-11-05  David Barton  <dbarton@mathscribe.com>
22575
22576         Implement SimpleFontData::platformBoundsForGlyph on skia
22577         https://bugs.webkit.org/show_bug.cgi?id=101115
22578
22579         Reviewed by Eric Seidel.
22580
22581         The implementation is similar to SimpleFontData::platformWidthForGlyph on skia.
22582
22583         Tested by: fast/block/lineboxcontain/*glyphs*, mathml/presentation/*
22584
22585         * platform/graphics/skia/SimpleFontDataSkia.cpp:
22586         (WebCore::SimpleFontData::platformBoundsForGlyph): Implemented.
22587
22588 2012-11-05  Andreas Kling  <kling@webkit.org>
22589
22590         Decouple Attr logic from ElementAttributeData.
22591         <http://webkit.org/b/101126>
22592
22593         Reviewed by Antti Koivisto.
22594
22595         Move all logic dealing with Attr DOM nodes from ElementAttributeData to Element.
22596         This makes more sense since an Attr is tied to a single Element, but an ElementAttributeData
22597         can be shared by any number of Elements at a given time.
22598
22599         Also updated naming convention from just "Attr" to "Attr node" in the code I was touching.
22600         "Attr" is way too generic, and has been historically confused with WebCore::Attribute a lot.
22601
22602         * dom/Element.h:
22603         * dom/ElementAttributeData.h:
22604         * dom/Element.cpp:
22605         (WebCore::attrNodeListMap):
22606         (WebCore::attrNodeListForElement):
22607         (WebCore::ensureAttrNodeListForElement):
22608         (WebCore::removeAttrNodeListForElement):
22609         (WebCore::findAttrNodeInList):
22610         (WebCore::Element::~Element):
22611         (WebCore::Element::detachAttribute):
22612         (WebCore::Element::setAttributeNode):
22613         (WebCore::Element::removeAttributeInternal):
22614         (WebCore::Element::getAttributeNode):
22615         (WebCore::Element::getAttributeNodeNS):
22616         (WebCore::Element::normalizeAttributes):
22617         (WebCore::Element::attrIfExists):
22618         (WebCore::Element::ensureAttr):
22619         (WebCore::Element::detachAttrNodeFromElementWithValue):
22620         (WebCore::Element::detachAllAttrNodesFromElement):
22621         (WebCore::Element::cloneAttributesFromElement):
22622
22623             Move everything Attr-related into Element.cpp while simplifying some loops and remove
22624             conditions that are no longer needed as they used to depend on having an attributeData().
22625
22626         * dom/Node.h:
22627         (WebCore::Node::hasSyntheticAttrChildNodes):
22628         (WebCore::Node::setHasSyntheticAttrChildNodes):
22629
22630             Renamed the hasAttrList() node flag to hasSyntheticAttrChildNodes().
22631
22632         * dom/Attr.cpp:
22633         (WebCore::Attr::detachFromElementWithValue):
22634
22635             Remove awkward indirection and let the call site deal with removing the Attr node from
22636             the Element's list of Attr nodes.
22637
22638         * dom/ElementAttributeData.cpp:
22639         (WebCore::ElementAttributeData::clearAttributes):
22640
22641             Remove now-unused Element* argument.
22642
22643 2012-11-05  Hans Muller  <hmuller@adobe.com>
22644
22645         [CSS Exclusions] Polygon edges should span colinear vertices
22646         https://bugs.webkit.org/show_bug.cgi?id=99343
22647
22648         Reviewed by Dirk Schulze.
22649
22650         ExclusionPolygonEdges now span coincident and collinear vertices. Currently
22651         pairs of vertices are only considered coincident if their coordinates are exactly
22652         equal. Similarly, a vertex is only considered collinear with an edge if the area
22653         of the triangle defined by the three vertices is exactly zero.  In the future it
22654         may be useful to relax the comparison with zero.
22655
22656         Tests: fast/exclusions/shape-inside/shape-inside-coincident-vertices.html
22657                fast/exclusions/shape-inside/shape-inside-collinear-vertices.html
22658
22659         * rendering/ExclusionPolygon.cpp:
22660         (WebCore::determinant): Used to measure collinearity.
22661         (WebCore):
22662         (WebCore::areCollinearPoints): True if three FloatPoint arguments are collinear per the test outlined above.
22663         (WebCore::areCoincidentPoints): True if the two FloatPoint arguments are equal.
22664         (WebCore::nextVertexIndex): The next vertex index in clockwise or counterclockwise order.
22665         (WebCore::ExclusionPolygon::findNextEdgeVertexIndex): Return the index of the next non-coincident, non-collinear vertex.
22666         (WebCore::ExclusionPolygon::ExclusionPolygon): Skip coincident and collinear vertices when building the list of edges.
22667         * rendering/ExclusionPolygon.h: Added private findNextEdgeVertexIndex() declaration.
22668
22669 2012-11-05  Christophe Dumez  <christophe.dumez@intel.com>
22670
22671         [EFL] Use POSIX implementation of SharedBuffer::createWithContentsOfFile()
22672         https://bugs.webkit.org/show_bug.cgi?id=101228
22673
22674         Reviewed by Kenneth Rohde Christiansen.
22675
22676         Get rid of EFL-specific implementation of SharedBuffer::createWithContentsOfFile()
22677         and reuse the POSIX one since it is pretty much the same.
22678
22679         No new tests, no behavior change.
22680
22681         * PlatformEfl.cmake:
22682         * platform/efl/SharedBufferEfl.cpp: Removed.
22683
22684 2012-11-05  Kentaro Hara  <haraken@chromium.org>
22685
22686         Add a comment about a return value of IDBKey::toV8()
22687         https://bugs.webkit.org/show_bug.cgi?id=101212
22688
22689         Reviewed by Adam Barth.
22690
22691         Although all other toV8(impl) return null when impl is 0,
22692         IDBKey::toV8(impl) is expected to return undefined when impl is 0.
22693         This patch adds a comment about it.
22694
22695         No tests.
22696
22697         * bindings/js/JSIDBKeyCustom.cpp:
22698         (WebCore::toJS):
22699         * bindings/v8/custom/V8IDBKeyCustom.cpp:
22700         (WebCore::toV8):
22701
22702 2012-11-05  Dominik Röttsches  <dominik.rottsches@intel.com>
22703
22704         [Cairo] Make Cairo honor image orientation
22705         https://bugs.webkit.org/show_bug.cgi?id=101207
22706
22707         Reviewed by Kenneth Rohde Christiansen.
22708
22709         Implement transformed image drawing in BitmapImageCairo, similar
22710         as it was done for Skia in bug 100179, r132384.
22711         The image drawing code needs to transform the graphics context
22712         depending on exif orientation in order for this to work.
22713
22714         No new tests, covered by fast/images/exif-* which are passing now.
22715
22716         * platform/graphics/BitmapImage.h: Enable draw function which respects image orientation for Cairo.
22717         * platform/graphics/cairo/BitmapImageCairo.cpp:
22718         (WebCore::BitmapImage::draw): Apply ImageOrientation's transformFromDefault() transformation to context.
22719         (WebCore):
22720
22721 2012-11-05  Kentaro Hara  <haraken@chromium.org>
22722
22723         [V8] Dispose() and Clear() should be always coupled for safety
22724         https://bugs.webkit.org/show_bug.cgi?id=101191
22725
22726         Reviewed by Adam Barth.
22727
22728         Clear() is not mandatory. However, to avoid misusing already
22729         disposed wrappers, Clear() should be always called just
22730         after Dispose().
22731
22732         No tests. No change in behavior.
22733
22734         * bindings/v8/DOMWrapperMap.h:
22735         (WebCore::DOMWrapperHashMap::defaultWeakCallback):
22736         * bindings/v8/IntrusiveDOMWrapperMap.h:
22737         (WebCore::IntrusiveDOMWrapperMap::weakCallback):
22738         * bindings/v8/NPV8Object.cpp:
22739         (WebCore::freeV8NPObject):
22740         * bindings/v8/ScheduledAction.cpp:
22741         (WebCore::ScheduledAction::~ScheduledAction):
22742         * bindings/v8/V8NPObject.cpp:
22743         (WebCore::V8NPTemplateMap::dispose):
22744         (WebCore::weakNPObjectCallback):
22745         (WebCore::forgetV8ObjectForNPObject):
22746         * bindings/v8/V8PerContextData.cpp:
22747         (WebCore::V8PerContextData::dispose):
22748         * bindings/v8/V8ValueCache.cpp:
22749         (WebCore::cachedStringCallback):
22750         (WebCore::IntegerCache::~IntegerCache):
22751         * bindings/v8/custom/V8InjectedScriptManager.cpp:
22752         (WebCore::WeakReferenceCallback):
22753
22754 2012-11-05  Hans Muller  <hmuller@adobe.com>
22755
22756         [CSS Exclusions] Layout of the first shape-inside line can be incorrect
22757         https://bugs.webkit.org/show_bug.cgi?id=100996
22758
22759         Reviewed by Dirk Schulze.
22760
22761         Made the conversion from floating point top/bottom logical shape bounds coordinates
22762         LayoutUnits explicit and corrected the case where the top value was truncated.  A
22763         float logicalTop value is converted to LayoutUnit with fromFloatCeil() to ensure
22764         that the LayoutUnit value is within the shape.
22765         
22766         Test: fast/exclusions/shape-inside/shape-inside-shape-logical-top.html
22767
22768         * rendering/ExclusionShapeInsideInfo.h:
22769         (WebCore::ExclusionShapeInsideInfo::shapeLogicalTop): Redefined this method in terms of shapeLogicalBoundsY,Max().
22770         (WebCore::ExclusionShapeInsideInfo::shapeLogicalBottom):  Ditto.
22771         (WebCore::ExclusionShapeInsideInfo::lineOverlapsShapeBounds):  Ditto.
22772         (ExclusionShapeInsideInfo):
22773         (WebCore::ExclusionShapeInsideInfo::shapeLogicalBoundsY): Explicit conversion from floating point shape coordinates to LayoutUnits.
22774         (WebCore::ExclusionShapeInsideInfo::shapeLogicalBoundsMaxY): Ditto.
22775
22776 2012-11-05  Antti Koivisto  <antti@apple.com>
22777
22778         Protect against resource deletion during iteration in MemoryCache::pruneDeadResourcesToSize
22779         https://bugs.webkit.org/show_bug.cgi?id=101211
22780
22781         Reviewed by Andreas Kling.
22782         
22783         Some crashes have been seen under MemoryCache::pruneDeadResourcesToSize. A possible cause is that
22784         destroyDecodedData() call ends up evicting the resource pointed by 'previous' pointer during iteration
22785         and deleting the object. This looks in principle possible via stylesheets and SVG images.
22786         
22787         Speculative fix, no repro, no obvious way to construct a test.
22788
22789         * loader/cache/MemoryCache.cpp:
22790         (WebCore::MemoryCache::pruneDeadResourcesToSize):
22791         
22792             Use CachedResourceHandle to protect the 'previous' pointer during iteration. Check if the
22793             resource has been kicked out from the cache during destroyDecodedData() and stop iterating
22794             if has (as it may die when CachedResourceHandle releases it).
22795             The 'current' pointer is not protected as the resource it points to is allowed to die.
22796             
22797 2012-11-05  Andrey Adaikin  <aandrey@chromium.org>
22798
22799         Web Inspector: Fix jscompiler cast syntax
22800         https://bugs.webkit.org/show_bug.cgi?id=101066
22801
22802         Reviewed by Pavel Feldman.
22803
22804         Casts should be in the form of "/** @type {TypeName} */ (expr)" instead of "/** @type {TypeName} */ expr".
22805
22806         * inspector/InjectedScriptCanvasModuleSource.js:
22807         (.):
22808         * inspector/InjectedScriptSource.js:
22809         (.):
22810         * inspector/front-end/ApplicationCacheModel.js:
22811         (WebInspector.ApplicationCacheModel.prototype._frameNavigated):
22812         (WebInspector.ApplicationCacheModel.prototype._frameDetached):
22813         * inspector/front-end/AuditLauncherView.js:
22814         (WebInspector.AuditLauncherView.prototype._onRequestStarted):
22815         (WebInspector.AuditLauncherView.prototype._onRequestFinished):
22816         * inspector/front-end/BreakpointManager.js:
22817         (WebInspector.BreakpointManager.prototype._uiSourceCodeAdded):
22818         (WebInspector.BreakpointManager.prototype._uiSourceCodeFormatted):
22819         (WebInspector.BreakpointManager.prototype._uiSourceCodeRemoved):
22820         (WebInspector.BreakpointManager.prototype._breakpointResolved):
22821         (WebInspector.BreakpointManager.Breakpoint.prototype._locationUpdated):
22822         (WebInspector.BreakpointManager.Storage):
22823         * inspector/front-end/BreakpointsSidebarPane.js:
22824         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointAdded):
22825         * inspector/front-end/CSSNamedFlowCollectionsView.js:
22826         (WebInspector.CSSNamedFlowCollectionsView.prototype._documentUpdated):
22827         (WebInspector.CSSNamedFlowCollectionsView.prototype._namedFlowCreated):
22828         (WebInspector.CSSNamedFlowCollectionsView.prototype._regionLayoutUpdated):
22829         (WebInspector.CSSNamedFlowCollectionsView.prototype._selectedNodeChanged):
22830         * inspector/front-end/CSSSelectorProfileView.js:
22831         (WebInspector.CSSProfileHeader.prototype.createView):
22832         * inspector/front-end/CSSStyleModel.js:
22833         (WebInspector.CSSStyleModel.LiveLocation.prototype.uiLocation):
22834         (WebInspector.CSSStyleDeclaration.parseComputedStylePayload):
22835         * inspector/front-end/CompilerScriptMapping.js:
22836         (WebInspector.CompilerScriptMapping.prototype.rawLocationToUILocation):
22837         (WebInspector.CompilerScriptMapping.prototype.loadSourceMapForScript):
22838         * inspector/front-end/ConsoleView.js:
22839         (WebInspector.ConsoleView.prototype._frameAdded):
22840         (WebInspector.ConsoleView.prototype._frameRemoved):
22841         * inspector/front-end/DOMAgent.js:
22842         (WebInspector.DOMDocument):
22843         * inspector/front-end/DebuggerModel.js:
22844         (WebInspector.DebuggerModel.prototype.didSetBreakpoint):
22845         (WebInspector.DebuggerModel.prototype.setBreakpointByURL):
22846         (WebInspector.DebuggerModel.prototype.):
22847         (WebInspector.DebuggerModel.prototype.setBreakpointBySourceId):
22848         (WebInspector.DebuggerModel.CallFrame.prototype.get location):
22849         * inspector/front-end/DebuggerScriptMapping.js:
22850         (WebInspector.DebuggerScriptMapping.prototype._parsedScriptSource):
22851         * inspector/front-end/DirectoryContentView.js:
22852         (WebInspector.DirectoryContentView.prototype._sort):
22853         * inspector/front-end/ElementsPanel.js:
22854         (WebInspector.ElementsPanel.prototype._updateBreadcrumbIfNeeded):
22855         * inspector/front-end/ElementsPanelDescriptor.js:
22856         (WebInspector.ElementsPanelDescriptor.prototype.appendApplicableItems):
22857         * inspector/front-end/ElementsTreeOutline.js:
22858         (.get node):
22859         * inspector/front-end/ExtensionServer.js:
22860         (WebInspector.ExtensionServer.prototype._onAddRequestHeaders):
22861         (WebInspector.ExtensionServer.prototype._handleOpenURL):
22862         (WebInspector.ExtensionServer.prototype._onGetResourceContent):
22863         (WebInspector.ExtensionServer.prototype._onSetResourceContent):
22864         (WebInspector.ExtensionServer.prototype._notifyResourceAdded):
22865         (WebInspector.ExtensionServer.prototype._notifyUISourceCodeContentCommitted):
22866         (WebInspector.ExtensionServer.prototype._notifyRequestFinished):
22867         * inspector/front-end/FileContentView.js:
22868         (WebInspector.FileContentView.prototype._metadataReceived):
22869         (WebInspector.FileContentView.FileContentProvider.prototype.requestContent):
22870         * inspector/front-end/FileSystemModel.js:
22871         (WebInspector.FileSystemModel.prototype._frameAdded):
22872         (WebInspector.FileSystemModel.prototype._frameNavigated):
22873         (WebInspector.FileSystemModel.prototype._frameDetached):
22874         * inspector/front-end/FileSystemView.js:
22875         (WebInspector.FileSystemView.EntryTreeElement.prototype.onselect):
22876         (WebInspector.FileSystemView.EntryTreeElement.prototype.refresh):
22877         * inspector/front-end/HandlerRegistry.js:
22878         (WebInspector.HandlerRegistry.prototype._appendHrefItems):
22879         * inspector/front-end/HeapSnapshotLoader.js:
22880         (WebInspector.HeapSnapshotLoader.prototype.write):
22881         * inspector/front-end/HeapSnapshotView.js:
22882         (WebInspector.HeapSnapshotView.prototype._changeBase):
22883         (WebInspector.HeapProfileHeader.prototype.load):
22884         (WebInspector.HeapProfileHeader.prototype._snapshotReceived):
22885         * inspector/front-end/IndexedDBModel.js:
22886         (WebInspector.IndexedDBModel.prototype._frameNavigated):
22887         (WebInspector.IndexedDBModel.prototype._frameDetached):
22888         * inspector/front-end/IndexedDBViews.js:
22889         (WebInspector.IDBDataView.prototype._keyColumnHeaderFragment):
22890         * inspector/front-end/JavaScriptSourceFrame.js:
22891         (WebInspector.JavaScriptSourceFrame.prototype._onFormattedChanged):
22892         (WebInspector.JavaScriptSourceFrame.prototype._breakpointAdded):
22893         (WebInspector.JavaScriptSourceFrame.prototype._breakpointRemoved):
22894         (WebInspector.JavaScriptSourceFrame.prototype._consoleMessageAdded):
22895         (WebInspector.JavaScriptSourceFrame.prototype._consoleMessageRemoved):
22896         (WebInspector.JavaScriptSourceFrame.prototype._handleGutterClick):
22897         (WebInspector.JavaScriptSourceFrame.prototype._continueToLine):
22898         * inspector/front-end/MemoryStatistics.js:
22899         (WebInspector.MemoryStatistics.prototype.show):
22900         * inspector/front-end/NavigatorView.js:
22901         (WebInspector.NavigatorView.prototype._uiSourceCodeTitleChanged):
22902         (WebInspector.NavigatorView.prototype._uiSourceCodeWorkingCopyChanged):
22903         (WebInspector.NavigatorView.prototype._uiSourceCodeWorkingCopyCommitted):
22904         (WebInspector.NavigatorView.prototype._uiSourceCodeFormattedChanged):
22905         * inspector/front-end/NetworkLog.js:
22906         (WebInspector.NetworkLog.prototype._onRequestStarted):
22907         * inspector/front-end/NetworkManager.js:
22908         (WebInspector.NetworkManager.prototype._cacheDisabledSettingChanged):
22909         * inspector/front-end/NetworkPanel.js:
22910         (WebInspector.NetworkLogView.prototype._onRequestUpdated):
22911         (WebInspector.NetworkLogView.prototype._mainFrameNavigated):
22912         (WebInspector.NetworkPanel.prototype.reveal):
22913         (WebInspector.NetworkPanel.prototype.appendApplicableItems):
22914         * inspector/front-end/NetworkUISourceCodeProvider.js:
22915         (WebInspector.NetworkUISourceCodeProvider.prototype._parsedScriptSource):
22916         (WebInspector.NetworkUISourceCodeProvider.prototype._resourceAdded):
22917         * inspector/front-end/ObjectPopoverHelper.js:
22918         (WebInspector.ObjectPopoverHelper.prototype.):
22919         (WebInspector.ObjectPopoverHelper.prototype._showObjectPopover):
22920         * inspector/front-end/PresentationConsoleMessageHelper.js:
22921         (WebInspector.PresentationConsoleMessageHelper.prototype._consoleMessageAdded):
22922         (WebInspector.PresentationConsoleMessageHelper.prototype._parsedScriptSource):
22923         * inspector/front-end/ProfilesPanel.js:
22924         * inspector/front-end/ResourceScriptMapping.js:
22925         (WebInspector.ResourceScriptMapping.prototype.rawLocationToUILocation):
22926         (WebInspector.ResourceScriptMapping.prototype._uiSourceCodeAddedToWorkspace):
22927         (WebInspector.ResourceScriptFile.prototype._workingCopyCommitted):
22928         (WebInspector.ResourceScriptFile.prototype._workingCopyChanged):
22929         * inspector/front-end/ResourceTreeModel.js:
22930         (WebInspector.ResourceTreeModel.prototype._onRequestFinished):
22931         (WebInspector.ResourceTreeModel.prototype._consoleMessageAdded):
22932         * inspector/front-end/ResourcesPanel.js:
22933         (WebInspector.ResourcesPanel.prototype._databaseAdded):
22934         (WebInspector.ResourcesPanel.prototype._domStorageAdded):
22935         (WebInspector.IndexedDBTreeElement.prototype._indexedDBAdded):
22936         (WebInspector.IndexedDBTreeElement.prototype._indexedDBRemoved):
22937         (WebInspector.IndexedDBTreeElement.prototype._indexedDBLoaded):
22938         (WebInspector.FileSystemListTreeElement.prototype._fileSystemAdded):
22939         (WebInspector.FileSystemListTreeElement.prototype._fileSystemRemoved):
22940         (WebInspector.FileSystemListTreeElement.prototype._fileSystemTreeElementByName):
22941         (WebInspector.SearchResultsTreeElementsTraverser.prototype._traverseNext):
22942         (WebInspector.SearchResultsTreeElementsTraverser.prototype._traversePrevious):
22943         * inspector/front-end/RevisionHistoryView.js:
22944         (WebInspector.RevisionHistoryView.prototype._uiSourceCodeRemoved):
22945         * inspector/front-end/SASSSourceMapping.js:
22946         (rawLocationToUILocation):
22947         * inspector/front-end/ScopeChainSidebarPane.js:
22948         (WebInspector.ScopeChainSidebarPane.prototype.update):
22949         * inspector/front-end/Script.js:
22950         (WebInspector.Script.Location.prototype.uiLocation):
22951         * inspector/front-end/ScriptFormatter.js:
22952         (WebInspector.ScriptFormatter.prototype.get _worker):
22953         * inspector/front-end/ScriptsPanel.js:
22954         (WebInspector.ScriptsPanel.prototype._uiSourceCodeAdded):
22955         (WebInspector.ScriptsPanel.prototype._uiSourceCodeRemoved):
22956         (WebInspector.ScriptsPanel.prototype._editorClosed):
22957         (WebInspector.ScriptsPanel.prototype._editorSelected):
22958         (WebInspector.ScriptsPanel.prototype._scriptSelected):
22959         (WebInspector.ScriptsPanel.prototype.canSearchAndReplace):
22960         (WebInspector.ScriptsPanel.prototype.replaceSelectionWith):
22961         (WebInspector.ScriptsPanel.prototype.replaceAllWith):
22962         (WebInspector.ScriptsPanel.prototype._toggleBreakpoint):
22963         (WebInspector.ScriptsPanel.prototype.set _fileRenamed):
22964         (WebInspector.ScriptsPanel.prototype._appendUISourceCodeItems):
22965         * inspector/front-end/ScriptsPanelDescriptor.js:
22966         (WebInspector.ScriptsPanelDescriptor.prototype.appendApplicableItems):
22967         * inspector/front-end/StylesSourceMapping.js:
22968         (WebInspector.StylesSourceMapping.prototype.rawLocationToUILocation):
22969         (WebInspector.StylesSourceMapping.prototype._uiSourceCodeAddedToWorkspace):
22970         * inspector/front-end/TabbedEditorContainer.js:
22971         (WebInspector.TabbedEditorContainer.prototype._scrollChanged):
22972         (WebInspector.TabbedEditorContainer.prototype._selectionChanged):
22973         (WebInspector.TabbedEditorContainer.prototype._tabClosed):
22974         (WebInspector.TabbedEditorContainer.prototype._tabSelected):
22975         (WebInspector.TabbedEditorContainer.prototype._uiSourceCodeTitleChanged):
22976         (WebInspector.TabbedEditorContainer.prototype._uiSourceCodeWorkingCopyChanged):
22977         (WebInspector.TabbedEditorContainer.prototype._uiSourceCodeWorkingCopyCommitted):
22978         (WebInspector.TabbedEditorContainer.prototype._uiSourceCodeFormattedChanged):
22979         * inspector/front-end/TimelineModel.js:
22980         (WebInspector.TimelineModelLoader.prototype.write):
22981         * inspector/front-end/UISourceCodeFrame.js:
22982         (WebInspector.UISourceCodeFrame.prototype._onFormattedChanged):
22983         * inspector/front-end/Workspace.js:
22984         (WebInspector.WorkspaceController.prototype._frameAdded):
22985         (WebInspector.Project.prototype._fileAdded):
22986         (WebInspector.Project.prototype._fileRemoved):
22987
22988 2012-11-05  Pavel Feldman  <pfeldman@chromium.org>
22989
22990         Web Inspector: render message bubbles in CodeMirror experiment.
22991         https://bugs.webkit.org/show_bug.cgi?id=101164
22992
22993         Reviewed by Vsevolod Vlasov.
22994
22995         It sounds like addLineWidget just makes it happen.
22996
22997         * inspector/front-end/CodeMirrorTextEditor.js:
22998         (WebInspector.CodeMirrorTextEditor):
22999         (WebInspector.CodeMirrorTextEditor.prototype.addDecoration):
23000         (WebInspector.CodeMirrorTextEditor.prototype.get if):
23001         (WebInspector.CodeMirrorTextEditor.prototype.removeDecoration):
23002         (WebInspector.CodeMirrorTextEditor.prototype._change):
23003         * inspector/front-end/DefaultTextEditor.js:
23004         (.preventDefaultOnMouseUp):
23005         * inspector/front-end/PresentationConsoleMessageHelper.js:
23006         (WebInspector.PresentationConsoleMessageHelper):
23007         * inspector/front-end/cm/cmdevtools.css:
23008         (.CodeMirror .webkit-html-message-bubble):
23009         (.CodeMirror .webkit-html-message-bubble img):
23010         (.CodeMirror .webkit-html-warning-message):
23011         (.CodeMirror .webkit-html-error-message):
23012
23013 2012-11-05  Thiago Marcos P. Santos  <thiago.santos@intel.com>
23014
23015         Validate CSS Device Adaptation properties and resolve shorthands
23016         https://bugs.webkit.org/show_bug.cgi?id=95962
23017
23018         Reviewed by Alexis Menard.
23019
23020         Add the missing keywords and properties for the viewport at-rule.
23021         Note that we have to mark that we are inside a viewport scope because
23022         some properties are not validated as they would be inside a style
23023         rule. As an example, the semantics of CSSPropertyWidth are completely
23024         different: on a viewport rule, it stands for a shorthand for the
23025         minimum and maximum width.
23026
23027         Test: css3/device-adapt/viewport-properties-validation.html
23028
23029         * css/CSSComputedStyleDeclaration.cpp:
23030         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
23031         * css/CSSParser.cpp:
23032         (WebCore::CSSParser::parseValue):
23033         (WebCore):
23034         (WebCore::CSSParser::parseViewportProperty):
23035         (WebCore::CSSParser::parseViewportShorthand):
23036         * css/CSSParser.h:
23037         * css/CSSProperty.cpp:
23038         (WebCore::CSSProperty::isInheritedProperty):
23039         * css/CSSPropertyNames.in:
23040         * css/CSSValueKeywords.in:
23041
23042 2012-11-05  Sheriff Bot  <webkit.review.bot@gmail.com>
23043
23044         Unreviewed, rolling out r133286, r133385, and r133394.
23045         http://trac.webkit.org/changeset/133286
23046         http://trac.webkit.org/changeset/133385
23047         http://trac.webkit.org/changeset/133394
23048         https://bugs.webkit.org/show_bug.cgi?id=101198
23049
23050         Broke image placement on some web sites. (Requested by kling
23051         on #webkit).
23052
23053         * css/StyleResolver.cpp:
23054         (WebCore::StyleResolver::sweepMatchedPropertiesCache):
23055         (WebCore::StyleResolver::matchAllRules):
23056         (WebCore::StyleResolver::canShareStyleWithElement):
23057         * dom/Attr.cpp:
23058         (WebCore::Attr::detachFromElementWithValue):
23059         * dom/Element.cpp:
23060         (WebCore::Element::~Element):
23061         (WebCore::Element::detachAttribute):
23062         (WebCore::Element::getAttribute):
23063         (WebCore::Element::setAttributeNode):
23064         (WebCore::Element::removeAttributeInternal):
23065         (WebCore::Element::getAttributeNode):
23066         (WebCore::Element::getAttributeNodeNS):
23067         (WebCore::Element::normalizeAttributes):
23068         (WebCore::Element::attrIfExists):
23069         (WebCore::Element::ensureAttr):
23070         (WebCore::Element::cloneAttributesFromElement):
23071         * dom/Element.h:
23072         (Element):
23073         (WebCore::Element::updateInvalidAttributes):
23074         * dom/ElementAttributeData.cpp:
23075         (WebCore::MutableElementAttributeData::MutableElementAttributeData):
23076         (WebCore):
23077         (WebCore::attrListMap):
23078         (WebCore::attrListForElement):
23079         (WebCore::ensureAttrListForElement):
23080         (WebCore::removeAttrListForElement):
23081         (WebCore::findAttrInList):
23082         (WebCore::ElementAttributeData::attrIfExists):
23083         (WebCore::ElementAttributeData::ensureAttr):
23084         (WebCore::ElementAttributeData::setAttr):
23085         (WebCore::ElementAttributeData::removeAttr):
23086         (WebCore::ElementAttributeData::detachAttrObjectsFromElement):
23087         (WebCore::ElementAttributeData::reportMemoryUsage):
23088         (WebCore::ElementAttributeData::cloneDataFrom):
23089         (WebCore::ElementAttributeData::clearAttributes):
23090         (WebCore::ElementAttributeData::getAttributeNode):
23091         * dom/ElementAttributeData.h:
23092         (WebCore):
23093         (WebCore::ElementAttributeData::attributeStyle):
23094         (WebCore::ElementAttributeData::setAttributeStyle):
23095         (ElementAttributeData):
23096         (WebCore::ElementAttributeData::ElementAttributeData):
23097         * dom/Node.h:
23098         (WebCore):
23099         (WebCore::Node::hasAttrList):
23100         (WebCore::Node::attributeStyleDirty):
23101         (WebCore::Node::setAttributeStyleDirty):
23102         (WebCore::Node::clearAttributeStyleDirty):
23103         (Node):
23104         (WebCore::Node::setHasAttrList):
23105         (WebCore::Node::clearHasAttrList):
23106         (WebCore::Node::isStyleAttributeValid):
23107         (WebCore::Node::setIsStyleAttributeValid):
23108         (WebCore::Node::clearIsStyleAttributeValid):
23109         * dom/StyledElement.cpp:
23110         (WebCore::StyledElement::updateStyleAttribute):
23111         (WebCore::StyledElement::attributeChanged):
23112         (WebCore::StyledElement::styleAttributeChanged):
23113         (WebCore::StyledElement::inlineStyleChanged):
23114         (WebCore::StyledElement::updateAttributeStyle):
23115         * dom/StyledElement.h:
23116         (StyledElement):
23117         (WebCore::StyledElement::invalidateStyleAttribute):
23118         (WebCore::StyledElement::attributeStyle):
23119         * inspector/InspectorCSSAgent.cpp:
23120         (WebCore::InspectorCSSAgent::buildObjectForAttributesStyle):
23121
23122 2012-11-05  Simon Hausmann  <simon.hausmann@digia.com>
23123
23124         Unreviewed trivial Qt build fix.
23125
23126         Surround imports from QtGui by QT_{BEGIN,END}_NAMESPACE to fix namespaced
23127         builds.
23128
23129         * platform/graphics/qt/GraphicsContextQt.cpp:
23130         * platform/graphics/qt/ImageQt.cpp:
23131
23132 2012-11-05  Shinya Kawanaka  <shinyak@chromium.org>
23133
23134         [Shadow] ShadowRoot type is not set correctly.
23135         https://bugs.webkit.org/show_bug.cgi?id=101188
23136
23137         Reviewed by Hajime Morita.
23138
23139         ShadowRoot type is not set correctly in Release build. We have had to remove #ifndef block.
23140
23141         Test: fast/dom/shadow/shadowroot-type.html
23142
23143         * dom/ShadowRoot.cpp:
23144         (WebCore::ShadowRoot::create):
23145         * testing/Internals.cpp:
23146         (WebCore::Internals::shadowRootType):
23147         (WebCore):
23148         * testing/Internals.h:
23149         (Internals):
23150         * testing/Internals.idl:
23151
23152 2012-11-05  Kent Tamura  <tkent@chromium.org>
23153
23154         BaseChooserOnlyDateAndTimeInputType should implement DateTimeChooserClient
23155         https://bugs.webkit.org/show_bug.cgi?id=101038
23156
23157         Reviewed by Hajime Morita.
23158
23159         Add DateTimeChooserClient behavior to BaseChooserOnlyDateAndTimeInputType.
23160         It means that date/time input elements without
23161         ENABLE_INPUT_MULTIPLE_FIELDS_UI can open date/time choosers by
23162         DOMActivate event.
23163
23164         This patch doesn't change behavior yet because Chromimum-Android port
23165         intercepts user events and doesn't deliver them to date/time input
23166         elements. <http://crbug.com/159381>
23167
23168         * html/BaseChooserOnlyDateAndTimeInputType.cpp:
23169         Add DateTimeChooserClient behavior. The code is similar to
23170         PickerIndicatorElement.
23171         (WebCore::BaseChooserOnlyDateAndTimeInputType::~BaseChooserOnlyDateAndTimeInputType):
23172         Closes DateTimeChooser.
23173         (WebCore::BaseChooserOnlyDateAndTimeInputType::handleDOMActivateEvent):
23174         Open DateTimeChooser if
23175          - The element is not disabled,
23176          - The element is not read-only,
23177          - The element has a renderer,
23178          - This event is created by a user gesture, and
23179          - The element has no DateTimeChooser.
23180         (WebCore::BaseChooserOnlyDateAndTimeInputType::detach):
23181         Closes DateTimeChooser.
23182         (WebCore::BaseChooserOnlyDateAndTimeInputType::didChooseValue):
23183         Set a string value coming from a chooser to the input element.
23184         (WebCore::BaseChooserOnlyDateAndTimeInputType::didEndChooser):
23185         Clear m_dateTimeChooser when the chooser was closed.
23186         (WebCore::BaseChooserOnlyDateAndTimeInputType::closeDateTimeChooser):
23187         Requests to close the chooser.
23188         * html/BaseChooserOnlyDateAndTimeInputType.h:
23189         (BaseChooserOnlyDateAndTimeInputType):
23190          - Implement DateTimeChooserClient
23191          - Add closeDateTimeChooser helper function.
23192          - Add detach override.
23193          - Add m_dateTimeChooser.
23194         * html/HTMLInputElement.cpp:
23195         (WebCore::HTMLInputElement::setupDateTimeChooserParameters):
23196         Added. The code is moved from PickerIndicatorElement.cpp in order to
23197         share it with BaseChooserOnlyDateAndTimeInputType.
23198         * html/HTMLInputElement.h:
23199         (HTMLInputElement): Declare setupDateTimeChooserParameters.
23200         * html/shadow/PickerIndicatorElement.cpp:
23201         (WebCore::PickerIndicatorElement::openPopup):
23202         Move some code to HTMLInputElement::setupDateTimeChooserParameters.
23203
23204 2012-11-04  Julien Chaffraix  <jchaffraix@webkit.org>
23205
23206         Fix the collapsing border code to handle mixed directionality at the row level
23207         https://bugs.webkit.org/show_bug.cgi?id=101060
23208
23209         Reviewed by Ojan Vafai.
23210
23211         After bug 87900, we support mixed directionality at the row-group level. For coherency
23212         - as the underlying code didn't support it - we were artificially ignoring 'direction'
23213         below the row-group. This change relaxes the restriction and patches the collapsing
23214         borders code to query the right style and border.
23215
23216         Tests: fast/table/border-collapsing/table-ltr-rows-mixed-direction.html
23217                fast/table/border-collapsing/table-rtl-row-mixed-direction.html
23218
23219         * rendering/RenderTable.cpp:
23220         (WebCore::RenderTable::tableStartBorderAdjoiningCell):
23221         (WebCore::RenderTable::tableEndBorderAdjoiningCell):
23222         Changed to query the row's direction.
23223
23224         * rendering/RenderTableCell.cpp:
23225         (WebCore::RenderTableCell::hasStartBorderAdjoiningTable):
23226         (WebCore::RenderTableCell::hasEndBorderAdjoiningTable):
23227         Added 2 helper functions. They determine if a specific cell's border
23228         adjoins the table. This code is required as the last cell's end border
23229         can be resolved against the start border.
23230
23231         (WebCore::RenderTableCell::computeCollapsedStartBorder):
23232         (WebCore::RenderTableCell::computeCollapsedEndBorder):
23233         Updated these functions now that being the start / end column doesn't mean
23234         that we have to resolve against the row / row-group / table's border.
23235
23236         * rendering/RenderTableCell.h:
23237         (WebCore::RenderTableCell::styleForCellFlow):
23238         Updated to return the row's style.
23239
23240         * rendering/RenderTableRow.cpp:
23241         (WebCore::RenderTableRow::borderAdjoiningStartCell):
23242         (WebCore::RenderTableRow::borderAdjoiningEndCell):
23243         * rendering/RenderTableSection.cpp:
23244         (WebCore::RenderTableSection::borderAdjoiningStartCell):
23245         (WebCore::RenderTableSection::borderAdjoiningEndCell):
23246         Updated these functions to work with mixed directionality.
23247
23248         * rendering/RenderTableSection.cpp:
23249         (WebCore::RenderTableSection::setLogicalPositionForCell):
23250         Changed this function to use the section's direction. This is wrong and should be changed
23251         once we properly fix the collapsing border code.
23252
23253         (WebCore::RenderTableSection::logicalRectForWritingModeAndDirection):
23254         Added a FIXME.
23255
23256         * rendering/style/CollapsedBorderValue.h:
23257         (WebCore::CollapsedBorderValue::width):
23258         This is a bug in our implementation: we used to return a non-zero width for inexistant borders (per CSS 2.1,
23259         'border-style: off | hidden' should have a 0 width). This is covered by our existing tests (among others by
23260         fast/table/border-collapsing/last-cell-left-border-hidden-table-ltr-section-rtl.html).
23261
23262 2012-11-04  Andrey Adaikin  <aandrey@chromium.org>
23263
23264         Web Inspector: [Canvas] do not blow up the capturing log
23265         https://bugs.webkit.org/show_bug.cgi?id=100752
23266
23267         Reviewed by Pavel Feldman.
23268
23269         Clear obsolete calls in the canvas 2D capturing log in runtime.
23270         Now we store in the log only minimum number of calls that are necessary to replay a
23271         canvas 2D context. To achieve that we find in runtime those calls in the log that no
23272         longer contribute to the final context state and remove them.
23273         These are the rules according which we find and remove such calls:
23274         - all PATH methods between a clip() call and beginPath() call can be removed
23275         - all MATRIX methods before a restore() or setTransform() call but after any PATH or corresponding save() method
23276         - all consecutive save() + restore() calls
23277
23278         Tests: inspector/profiler/canvas2d/canvas2d-api-changes.html
23279                inspector/profiler/canvas2d/canvas2d-profiler-capturing-basics.html
23280
23281         * inspector/InjectedScriptCanvasModuleSource.js:
23282         (.):
23283
23284 2012-11-04  Shinya Kawanaka  <shinyak@chromium.org>
23285
23286         [Shadow] ShadowRoot should have a method to return ShadowRootType.
23287         https://bugs.webkit.org/show_bug.cgi?id=101178
23288
23289         Reviewed by Hajime Morita.
23290
23291         When we style PseudoCustomElement, we have to know ShadowRootType.
23292         We would like to expose a method to get ShadowRootType also in Release mode.
23293
23294         This is a preparation patch for Bug 101170.
23295
23296         * dom/ShadowRoot.h:
23297         (ShadowRoot):
23298
23299 2012-11-04  Keishi Hattori  <keishi@webkit.org>
23300
23301         Introduce Month class to calendar picker
23302         https://bugs.webkit.org/show_bug.cgi?id=101024
23303
23304         Reviewed by Kent Tamura.
23305
23306         Month class needs to be introduced to implement a month picker. This
23307         patch just introduces the Month class into the calendar picker without
23308         changing the current behavior.
23309
23310         No new tests. Covered by existing calendar-picker-*.html tests.
23311
23312         * Resources/pagepopups/calendarPicker.js:
23313         (Month.prototype.toLocaleString): Returns a localized month string.
23314         (Month): Takes a Month object, number representing the month, or year and month numbers.
23315         (Month.parse): Returns a new Month from an ISO month string.
23316         (Month.createFromDate): Returns a new Month containing the given datetime.
23317         (Month.prototype.equals): Returns true if the given month is the same.
23318         (Month.prototype.previous): Returns the previous month.
23319         (Month.prototype.next): Returns the next month.
23320         (Month.prototype.startDate): Returns a datetime that is the start of this month. The value is inclusive.
23321         (Month.prototype.endDate): Returns a datetime that is the end of this month. The value is exclusive.
23322         (Month.prototype.valueOf): Returns a number representing the month.
23323         (Month.prototype.toString): Returns an ISO month string.
23324         (YearMonthController): Use Month object.
23325         (YearMonthController.prototype.attachTo): Year 275760 ends in September so use the year before to measure the label width.
23326         (YearMonthController.prototype.setMonth): Take a month object.
23327         (YearMonthController.prototype._redraw): Use ISO month string for element.dataset.value.
23328         (YearMonthController.prototype._handleYearMonthChange):
23329         (YearMonthController.prototype.moveRelatively):
23330         (DaysTable): Use Month object.
23331         (DaysTable.prototype._renderMonth): Take a month object. Testing for isNaN is moved up to fix a bug when showing September, 275760.
23332         (DaysTable.prototype._navigateToMonth): Take a month object.
23333         (DaysTable.prototype._navigateToMonthWithAnimation): Take a month object.
23334         (DaysTable.prototype.navigateToMonthAndKeepSelectionPosition): Take a month object.
23335         (DaysTable.prototype.selectDate):
23336         (DaysTable.prototype._maybeSetPreviousMonth): Use Month object to calculate the previous month.
23337         (DaysTable.prototype._maybeSetNextMonth): Use Month object to calculate the next month.
23338
23339 2012-11-04  Halton Huo  <halton.huo@intel.com>
23340
23341         [EFL] Use _LIBRARIES instead of _LIBRARY
23342         https://bugs.webkit.org/show_bug.cgi?id=101042
23343
23344         Reviewed by Gyuyoung Kim.
23345
23346         In CMake Find files, _LIBRARY is intended for internal use, should
23347         use _LIBRARIES instead.
23348
23349         * PlatformEfl.cmake: s/_LIBRARY}/_LIBRARIES}
23350
23351 2012-11-04  MORITA Hajime  <morrita@google.com>
23352
23353         Shadow DOM should be able to be disabled per context.
23354         https://bugs.webkit.org/show_bug.cgi?id=101173
23355
23356         Reviewed by Dimitri Glazkov.
23357
23358         This change pulls back relevant bits from r131549. Note that if
23359         the the port enables runtime Shadow DOM flag, this can cause slow
23360         down on some Chromium page cycler test cases (which r131549
23361         attempted to fix).
23362
23363         This change is temporal and the flags should be switched back from
23364         ContextFeatures to RuntimeEnabledFeatures once it gains sufficent
23365         stability.
23366
23367         * dom/ContextFeatures.cpp:
23368         (WebCore::ContextFeatures::shadowDOMEnabled):
23369         (WebCore):
23370         * dom/ContextFeatures.h:
23371         * dom/Position.cpp:
23372         (WebCore::Position::Position):
23373         (WebCore::Position::findParent):
23374         * dom/TreeScope.cpp:
23375         (WebCore::TreeScope::getSelection):
23376         * html/HTMLTagNames.in:
23377         * html/shadow/HTMLContentElement.cpp:
23378         (WebCore::HTMLContentElement::contentTagName):
23379         * page/DOMWindow.idl:
23380
23381 2012-11-04  Shinya Kawanaka  <shinyak@chromium.org>
23382
23383         [Shadow] Implement custom pseudo-elements styling
23384         https://bugs.webkit.org/show_bug.cgi?id=100812
23385
23386         Reviewed by Hajime Morita.
23387
23388         Instead of using ElementRareData::m_shadowPseudoId, we use 'pseudo' attribute.
23389
23390         Later we would like to remove Element::shadowPseudoId and Element::setShadowPseudoId
23391         and use pseudo()/setPseudo() instead (Bug 101171).
23392
23393         Test: fast/dom/shadow/styling-pseudo-attribute.html
23394
23395         * dom/Element.cpp:
23396         (WebCore::Element::shadowPseudoId):
23397         (WebCore::Element::setShadowPseudoId):
23398         * dom/ElementRareData.cpp:
23399         (WebCore::ElementRareData::reportMemoryUsage):
23400         * dom/ElementRareData.h:
23401         (ElementRareData):
23402
23403 2012-11-04  Kent Tamura  <tkent@chromium.org>
23404
23405         BaseChooserOnlyDateAndTimeInputType should have BaseClickableWithKeyInputType behavior
23406         https://bugs.webkit.org/show_bug.cgi?id=101039
23407
23408         Reviewed by Hajime Morita.
23409
23410         Add BaseClickableWithKeyInputType behavior to
23411         BaseChooserOnlyDateAndTimeInputType. It means date/time input types
23412         without ENABLE_INPUT_MULTIPLE_FIELDS_UI receive DOMActivate events by
23413         pressing space or enter key. They're going to open a date/time chooser
23414         by DOMActive event.
23415
23416         Because BaseChooserOnlyDateAndTimeInputType inherits from
23417         BaseDateAndTimeInputType, it can't inherit
23418         BaseClickableWithKeyInputType. So, this patch adds static helper
23419         functions to BaseClickableWithKeyInputType, and
23420         BaseChooserOnlyDateAndTimeInputType uses them.
23421
23422         This patch doesn't change behavior yet because Chromimum-Android port
23423         intercepts user events and doesn't deliver them to date/time input
23424         elements.
23425
23426         * html/BaseChooserOnlyDateAndTimeInputType.cpp:
23427         (WebCore::BaseChooserOnlyDateAndTimeInputType::handleDOMActivateEvent):
23428         Add an empty implementation with a FIXME comment.
23429         (WebCore::BaseChooserOnlyDateAndTimeInputType::handleKeydownEvent):
23430         Add BaseClickableWithKeyInputType behavior by a helper function.
23431         (WebCore::BaseChooserOnlyDateAndTimeInputType::handleKeypressEvent): Ditto.
23432         (WebCore::BaseChooserOnlyDateAndTimeInputType::handleKeyupEvent): Ditto.
23433         (WebCore::BaseChooserOnlyDateAndTimeInputType::accessKeyAction): Ditto.
23434         * html/BaseChooserOnlyDateAndTimeInputType.h:
23435         (BaseChooserOnlyDateAndTimeInputType): Add function declarations.
23436         * html/BaseClickableWithKeyInputType.cpp:
23437         Add static helper functions, and existing member functions use them.
23438         * html/BaseClickableWithKeyInputType.h:
23439         (BaseClickableWithKeyInputType): Add declarations of the helper functions.
23440         * html/InputType.h:
23441         (InputType): Make dispatchSimulatedClickIfActive public because it is
23442         called from a helper function.
23443
23444 2012-11-04  Sheriff Bot  <webkit.review.bot@gmail.com>
23445
23446         Unreviewed, rolling out r133416.
23447         http://trac.webkit.org/changeset/133416
23448         https://bugs.webkit.org/show_bug.cgi?id=101169
23449
23450         Broke world selection by right click (Requested by rniwa on
23451         #webkit).
23452
23453         * page/EventHandler.cpp:
23454         (WebCore::EventHandler::handleGestureForTextSelectionOrContextMenu):
23455         (WebCore::EventHandler::sendContextMenuEvent):
23456
23457 2012-11-04  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
23458
23459         Missing ASCIILiteral in a place of accessibility
23460         https://bugs.webkit.org/show_bug.cgi?id=101160
23461
23462         Reviewed by Darin Adler.
23463
23464         ASCIILiteral usage is being missed in a spot of accessibliity.
23465
23466         * accessibility/AccessibilityMediaControls.cpp:
23467         (WebCore::AccessibilityMediaTimeDisplay::accessibilityDescription):
23468
23469 2012-11-03  Balazs Kelemen  <kbalazs@webkit.org>
23470
23471         [Qt][WK2] setPlatformStrategies always asserts after r132744
23472         https://bugs.webkit.org/show_bug.cgi?id=100838
23473
23474         Reviewed by Simon Hausmann.
23475
23476         Reland with build fixes.
23477
23478         The problem here is that we use QWebSettings::clearMemoryCaches, a WebKit1 API
23479         from the injected bundle, which calls initializeWebCoreQt and it sets the platform
23480         strategies to the one for WebKit1. We should stop using WebKit1 API's from WebKit2
23481         code. In order to keep the behavior, this patch adds exported helpers to WebCore
23482         that can be used from DumpRenderTree and WebKitTestRunner. This is the same idea
23483         as WebCoreTestSupport but these helpers are specific to Qt. Technically we could
23484         add it to the WebKit1 API for the time being, but my goal was to move in the direction
23485         of removing the WebKit1 dependency from WebKitTestRunner. We only build the file
23486         in non production mode.
23487
23488         Basically covered by all tests.
23489
23490         * Target.pri:
23491         * WebCore.pri: We need to link against fontconfig (only in non-production mode) since
23492         initializeTestFonts uses it.
23493         * platform/qt/QtTestSupport.cpp: Added. I choose GPL license because code from qwebsettings.cpp
23494         is also under that.
23495         (WebKit):
23496         (WebKit::QtTestSupport::clearMemoryCaches): This is basically a copy of QWebSettings::clearMemoryCaches
23497         without calling initializeWebCoreQt.
23498         (WebKit::QtTestSupport::initializeTestFonts): I moved this code here as well now that we have to expose
23499         symbols from WebCore anyway. The advantage is that now we don't have to build it twice and we don't need
23500         additional files to forward it from the directory of DumpRenderTree for WebKitTestRunner.
23501         I added a call to FontCace::invalidate in the case when the font set has been changed so that it will do
23502         the job even if we would stop clearing all caches between tests. Also moved the call to
23503         QFontDatabase::removeAllApplicationFonts from callers to here.
23504         * platform/qt/QtTestSupport.h:
23505         (WebKit):
23506         (QtTestSupport):
23507
23508 2012-11-04  Florin Malita  <fmalita@chromium.org>
23509
23510         Color-profile property triggers assert
23511         https://bugs.webkit.org/show_bug.cgi?id=101080
23512
23513         Reviewed by Dirk Schulze.
23514
23515         CSSPropertyColorProfile is not handled in StyleResolver::applySVGProperty(), triggering the
23516         unimplemented property assert. Adding a stub entry to avoid that.
23517
23518         Test: svg/css/color-profile-crash.html
23519
23520         * css/SVGCSSStyleSelector.cpp:
23521         (WebCore::StyleResolver::applySVGProperty):
23522
23523 2012-11-04  Kaustubh Atrawalkar  <kaustubh@motorola.com>
23524
23525         Unable to copy text on disabled input fields on long press gesture
23526         https://bugs.webkit.org/show_bug.cgi?id=99698
23527
23528         Reviewed by Ryosuke Niwa.
23529
23530         Text from disabled input/text should be allowed to select. Replaced isContentEditable()
23531         with canStartSelection()
23532
23533         Test: fast/events/touch/gesture/disabled-input-text-selection.html
23534
23535         * page/EventHandler.cpp:
23536         (WebCore::EventHandler::handleGestureLongPress):
23537
23538 2012-11-03  Sheriff Bot  <webkit.review.bot@gmail.com>
23539
23540         Unreviewed, rolling out r133403, r133404, and r133409.
23541         http://trac.webkit.org/changeset/133403
23542         http://trac.webkit.org/changeset/133404
23543         http://trac.webkit.org/changeset/133409
23544         https://bugs.webkit.org/show_bug.cgi?id=101158
23545
23546         "Broke tests" (Requested by kbalazs on #webkit).
23547
23548         * Target.pri:
23549         * WebCore.pri:
23550         * platform/qt/QtTestSupport.h: Removed.
23551
23552 2012-11-03  Alexey Proskuryakov  <ap@apple.com>
23553
23554         Get rid of USE(CFURLSTORAGESESSIONS)
23555         https://bugs.webkit.org/show_bug.cgi?id=101131
23556
23557         Reviewed by Sam Weinig.
23558
23559         This is always enabled on CFNetwork based platforms.
23560
23561         * WebCore.exp.in:
23562         * page/Settings.cpp:
23563         (WebCore::Settings::setPrivateBrowsingEnabled):
23564         * platform/mac/CookieJar.mm:
23565         (WebCore::cookies):
23566         (WebCore::cookieRequestHeaderFieldValue):
23567         (WebCore::setCookies):
23568         (WebCore::cookiesEnabled):
23569         (WebCore::getRawCookies):
23570         (WebCore::deleteCookie):
23571         * platform/network/ResourceHandle.h:
23572         (ResourceHandle):
23573         * platform/network/cf/CookieStorageCFNet.cpp:
23574         (WebCore):
23575         (WebCore::currentCFHTTPCookieStorage):
23576         * platform/network/cf/CookieStorageCFNet.h:
23577         * platform/network/cf/ResourceHandleCFNet.cpp:
23578         (WebCore::willSendRequest):
23579         (WebCore::makeFinalRequest):
23580         (WebCore::ResourceHandle::willSendRequest):
23581         (WebCore):
23582         * platform/network/cf/ResourceRequest.h:
23583         (ResourceRequest):
23584         * platform/network/cf/ResourceRequestCFNet.cpp:
23585         (WebCore::ResourceRequest::doUpdatePlatformRequest):
23586         (WebCore):
23587         * platform/network/mac/CookieStorageMac.mm:
23588         (WebCore::setCookieStoragePrivateBrowsingEnabled):
23589         * platform/network/mac/ResourceHandleMac.mm:
23590         (WebCore::shouldRelaxThirdPartyCookiePolicy):
23591         (WebCore::ResourceHandle::createNSURLConnection):
23592         (WebCore::ResourceHandle::willSendRequest):
23593         (WebCore):
23594         * platform/network/mac/ResourceRequestMac.mm:
23595         (WebCore):
23596         (WebCore::ResourceRequest::setStorageSession):
23597
23598 2012-11-03  Balazs Kelemen  <kbalazs@webkit.org>
23599
23600         [Qt][WK2] setPlatformStrategies always asserts after r132744
23601         https://bugs.webkit.org/show_bug.cgi?id=100838
23602
23603         Reviewed by Simon Hausmann.
23604
23605         Reland with build fix.
23606
23607         The problem here is that we use QWebSettings::clearMemoryCaches, a WebKit1 API
23608         from the injected bundle, which calls initializeWebCoreQt and it sets the platform
23609         strategies to the one for WebKit1. We should stop using WebKit1 API's from WebKit2
23610         code. In order to keep the behavior, this patch adds exported helpers to WebCore
23611         that can be used from DumpRenderTree and WebKitTestRunner. This is the same idea
23612         as WebCoreTestSupport but these helpers are specific to Qt. Technically we could
23613         add it to the WebKit1 API for the time being, but my goal was to move in the direction
23614         of removing the WebKit1 dependency from WebKitTestRunner. We only build the file
23615         in non production mode.
23616
23617         Basically covered by all tests.
23618
23619         * Target.pri:
23620         * WebCore.pri: We need to link against fontconfig (only in non-production mode) since
23621         initializeTestFonts uses it.
23622         * platform/qt/QtTestSupport.cpp: Added. I choose GPL license because code from qwebsettings.cpp
23623         is also under that.
23624         (WebKit):
23625         (WebKit::QtTestSupport::clearMemoryCaches): This is basically a copy of QWebSettings::clearMemoryCaches
23626         without calling initializeWebCoreQt.
23627         (WebKit::QtTestSupport::initializeTestFonts): I moved this code here as well now that we have to expose
23628         symbols from WebCore anyway. The advantage is that now we don't have to build it twice and we don't need
23629         additional files to forward it from the directory of DumpRenderTree for WebKitTestRunner.
23630         I added a call to FontCace::invalidate in the case when the font set has been changed so that it will do
23631         the job even if we would stop clearing all caches between tests. Also moved the call to
23632         QFontDatabase::removeAllApplicationFonts from callers to here.
23633         * platform/qt/QtTestSupport.h:
23634         (WebKit):
23635         (QtTestSupport):
23636
23637 2012-11-03  Sheriff Bot  <webkit.review.bot@gmail.com>
23638
23639         Unreviewed, rolling out r133397.
23640         http://trac.webkit.org/changeset/133397
23641         https://bugs.webkit.org/show_bug.cgi?id=101155
23642
23643         "Broke Qt. No way to force the damn bots to do a clean build.
23644         I'm giving up." (Requested by kbalazs on #webkit).
23645
23646         * Target.pri:
23647         * WebCore.pri:
23648         * platform/qt/QtTestSupport.h: Removed.
23649
23650 2012-11-03  Stephen White  <senorblanco@chromium.org>
23651
23652         Speculative fix to eliminate flakiness in
23653         css3/filters/blur-filter-page-scroll-self.html
23654         https://bugs.webkit.org/show_bug.cgi?id=91620.
23655         Suspicion is that a prior test is setting
23656         window.internals.settings.setEnableCompositingForFixedPosition(true),
23657         causing this test to be intermittely run on the GPU, giving different
23658         pixel results depending on test order.
23659
23660         Reviewed by Jochen Eisinger.
23661
23662         Covered by css3/filters/blur-filter-page-scroll-self.html
23663
23664         * testing/InternalSettings.cpp:
23665         (WebCore::InternalSettings::Backup::Backup):
23666         (WebCore::InternalSettings::Backup::restoreTo):
23667         * testing/InternalSettings.h:
23668         (Backup):
23669
23670 2012-11-03  Mark Rowe  <mrowe@apple.com>
23671
23672         REGRESSION (r132858): Crash below -[DOMElement setClassName:] when called with a nil string
23673
23674         Reviewed by Anders Carlsson.
23675
23676         The changes in r132858 introduced an overload of AtomicString::add for CFStrings. However, the overload
23677         that was introduced is not null safe.
23678
23679         * platform/text/cf/AtomicStringCF.cpp:
23680         (WTF::AtomicString::add): Handle a null string by returning a null StringImpl.
23681
23682 2012-11-03  Balazs Kelemen  <kbalazs@webkit.org>
23683
23684         [Qt][WK2] setPlatformStrategies always asserts after r132744
23685         https://bugs.webkit.org/show_bug.cgi?id=100838
23686
23687         Reviewed by Simon Hausmann.
23688
23689         The problem here is that we use QWebSettings::clearMemoryCaches, a WebKit1 API
23690         from the injected bundle, which calls initializeWebCoreQt and it sets the platform
23691         strategies to the one for WebKit1. We should stop using WebKit1 API's from WebKit2
23692         code. In order to keep the behavior, this patch adds exported helpers to WebCore
23693         that can be used from DumpRenderTree and WebKitTestRunner. This is the same idea
23694         as WebCoreTestSupport but these helpers are specific to Qt. Technically we could
23695         add it to the WebKit1 API for the time being, but my goal was to move in the direction
23696         of removing the WebKit1 dependency from WebKitTestRunner. We only build the file
23697         in non production mode.
23698
23699         Basically covered by all tests.
23700
23701         * Target.pri:
23702         * WebCore.pri: We need to link against fontconfig (only in non-production mode) since
23703         initializeTestFonts uses it.
23704         * platform/qt/QtTestSupport.cpp: Added. I choose GPL license because code from qwebsettings.cpp
23705         is also under that.
23706         (WebKit):
23707         (WebKit::QtTestSupport::clearMemoryCaches): This is basically a copy of QWebSettings::clearMemoryCaches
23708         without calling initializeWebCoreQt.
23709         (WebKit::QtTestSupport::initializeTestFonts): I moved this code here as well now that we have to expose
23710         symbols from WebCore anyway. The advantage is that now we don't have to build it twice and we don't need
23711         additional files to forward it from the directory of DumpRenderTree for WebKitTestRunner.
23712         I added a call to FontCace::invalidate in the case when the font set has been changed so that it will do
23713         the job even if we would stop clearing all caches between tests. Also moved the call to
23714         QFontDatabase::removeAllApplicationFonts from callers to here.
23715         * platform/qt/QtTestSupport.h:
23716         (WebKit):
23717         (QtTestSupport):
23718
23719 2012-11-03  Dan Beam  <dbeam@chromium.org>
23720
23721         Implement HTMLFormElement#requestAutocomplete and associated events
23722         https://bugs.webkit.org/show_bug.cgi?id=100557
23723
23724         Reviewed by Adam Barth.
23725
23726         Implements an initial version of the proposal for interactive autocomplete outlined in this email:
23727         http://lists.whatwg.org/htdig.cgi/whatwg-whatwg.org/2012-October/037711.html
23728
23729         The goal of this patch is to allow web authors to call formElement.requestAutocomplete(); after subscribing for
23730         autocomplete/autocompleteerror events on formElement. If the form's [autocomplete] attribute is "off" an
23731         error will be dispatched. Otherwise, a request will be issued to the FrameLoaderClient.  At the moment, the
23732         implementation in Chrome (https://codereview.chromium.org/11270018/) will simply dispatch an error until the
23733         UI on Chrome's side is built. Both autocomplete and autocompleteerror events will be dispatched asynchronously
23734         after a small delay to behave consistently in all situations and implementations.
23735
23736         Currently this is behind the feature flag REQUEST_AUTOCOMPLETE, which is disabled.
23737
23738         Test: fast/forms/form-request-autocomplete.html
23739
23740         * dom/EventNames.h:
23741         (WebCore):
23742
23743         Added autocomplete and autocompleteerror events. The autocomplete event is dispatched after a user adds more
23744         information to a form using the future UI. This is not currently dispatched in any implementation (including Chrome)
23745         but will be in the future. The autocompleteerror event is dispatched when the form has [autocomplete="off"] on the
23746         node being asked for an interactive autocomplete. The user agent may also dispatch this event if it doesn't implement
23747         this API but has turned on the feature flag, can't currently show an autocomplete UI (e.g. running headlessly or in
23748         an HTML notification, security concerns, or any other reason it desires).
23749
23750         * html/HTMLAttributeNames.in:
23751
23752         Added onautocomplete and onautocompleteerror attributes so they can be parsed when creating form elements and used
23753         as event listeners. For example:
23754
23755           <form onautocomplete="/* when autocomplete succeeds */" autocompleteerror="/* when autocomplete fails */">
23756
23757         * html/HTMLFormElement.cpp:
23758         (WebCore::HTMLFormElement::HTMLFormElement):
23759         (WebCore):
23760
23761         Added m_requestAutocompleteTimer (a timer that's used to dispatch events asynchronously) to the initializer list that
23762         triggers requestAutocompleteTimerFired when it times out.
23763
23764         (WebCore::HTMLFormElement::requestAutocomplete):
23765
23766         Called when HTMLFormElement#requestAutocomplete is called from JS (also see HTMLFormElement.idl) and decides whether
23767         to dispatch an error and exit early (in the case where autocomplete="off") or pass the request on to the
23768         FrameLoaderClient.
23769
23770         (WebCore::HTMLFormElement::finishRequestAutocomplete):
23771
23772         Called when the request for an interactive autocomplete is finished with either a success or error result. This
23773         causes an event to queue and fired after a 0 second delay. Events are owned by HTMLFormElement and reference the
23774         target element (this) until fired.
23775
23776         (WebCore::HTMLFormElement::requestAutocompleteTimerFired):
23777
23778         Called when the event timer runs out to pump the queue of current events. Events are released on dispatch.
23779
23780         (WebCore::HTMLFormElement::parseAttribute):
23781
23782         Encountering onautocomplete or onautocompleteerror attributes while parsing HTMLFormElements now adds event listeners
23783         for autocomplete an autocompleteerror events (respectively) to dispatch the value of the attribute as a script.
23784
23785         * html/HTMLFormElement.h:
23786         (HTMLFormElement):
23787
23788         Added various methods and data members as required by the implementation.
23789
23790         * html/HTMLFormElement.idl:
23791
23792         Added the method requestAutocomplete and associated DOM event handler attributes (onautocomplete/onautocompleteerror)
23793         to HTMLFormElement's public DOM API (unprefixed, as per Ian Hickson's advice). All are require the Conditional
23794         REQUEST_AUTOCOMPLETE to be enabled to be activated.
23795
23796         * loader/EmptyClients.cpp:
23797         (WebCore):
23798         (WebCore::EmptyFrameLoaderClient::didRequestAutocomplete):
23799
23800         Added noop implementation for FrameLoader::didRequestAutocomplete.
23801
23802         * loader/EmptyClients.h:
23803         (EmptyFrameLoaderClient):
23804
23805         Added FrameLoader::didRequestAutocomplete to EmptyFrameLoaderClient interface.
23806
23807         * loader/FrameLoaderClient.h:
23808         (FrameLoaderClient):
23809
23810         Added noop implementation to FrameLoaderClient interface (which is implemented chromium's FrameLoaderLoaderImpl.cpp).
23811
23812 2012-11-03  Pavel Feldman  <pfeldman@chromium.org>
23813
23814         Web Inspector: %d, %i, and %f log formatters have same result
23815         https://bugs.webkit.org/show_bug.cgi?id=101148
23816
23817         Reviewed by Alexander Pavlov.
23818
23819         Added separate formatters for %f, %i, %d and %s.
23820
23821         Test: inspector/console/console-message-format.html
23822
23823         * inspector/front-end/ConsoleMessage.js:
23824         (WebInspector.ConsoleMessageImpl.prototype.stringFormatter):
23825         (WebInspector.ConsoleMessageImpl.prototype.floatFormatter):
23826         (WebInspector.ConsoleMessageImpl.prototype.integerFormatter):
23827
23828 2012-11-03  Andreas Kling  <kling@webkit.org>
23829
23830         Decouple Attr logic from ElementAttributeData.
23831         <http://webkit.org/b/101126>
23832
23833         Reviewed by Antti Koivisto.
23834
23835         Move all logic dealing with Attr DOM nodes from ElementAttributeData to Element.
23836         This makes more sense since an Attr is tied to a single Element, but an ElementAttributeData
23837         can be shared by any number of Elements at a given time.
23838
23839         Also updated naming convention from just "Attr" to "Attr node" in the code I was touching.
23840         "Attr" is way too generic, and has been historically confused with WebCore::Attribute a lot.
23841
23842         * dom/Element.h:
23843         * dom/ElementAttributeData.h:
23844         * dom/Element.cpp:
23845         (WebCore::attrNodeListMap):
23846         (WebCore::attrNodeListForElement):
23847         (WebCore::ensureAttrNodeListForElement):
23848         (WebCore::removeAttrNodeListForElement):
23849         (WebCore::findAttrNodeInList):
23850         (WebCore::Element::~Element):
23851         (WebCore::Element::detachAttribute):
23852         (WebCore::Element::setAttributeNode):
23853         (WebCore::Element::removeAttributeInternal):
23854         (WebCore::Element::getAttributeNode):
23855         (WebCore::Element::getAttributeNodeNS):
23856         (WebCore::Element::normalizeAttributes):
23857         (WebCore::Element::attrIfExists):
23858         (WebCore::Element::ensureAttr):
23859         (WebCore::Element::detachAttrNodeFromElementWithValue):
23860         (WebCore::Element::detachAllAttrNodesFromElement):
23861         (WebCore::Element::cloneAttributesFromElement):
23862
23863             Move everything Attr-related into Element.cpp while simplifying some loops and remove
23864             conditions that are no longer needed as they used to depend on having an attributeData().
23865
23866         * dom/Node.h:
23867         (WebCore::Node::hasSyntheticAttrChildNodes):
23868         (WebCore::Node::setHasSyntheticAttrChildNodes):
23869
23870             Renamed the hasAttrList() node flag to hasSyntheticAttrChildNodes().
23871
23872         * dom/Attr.cpp:
23873         (WebCore::Attr::detachFromElementWithValue):
23874
23875             Remove awkward indirection and let the call site deal with removing the Attr node from
23876             the Element's list of Attr nodes.
23877
23878         * dom/ElementAttributeData.cpp:
23879         (WebCore::ElementAttributeData::clearAttributes):
23880
23881             Remove now-unused Element* argument.
23882
23883 2012-11-03  Pavel Feldman  <pfeldman@chromium.org>
23884
23885         REGRESSION (r132014-r132047): Webkit Inspector Window docking broken
23886         https://bugs.webkit.org/show_bug.cgi?id=101125
23887
23888         Reviewed by Vsevolod Vlasov.
23889
23890         Added "bottom" as default docked state.
23891
23892         * inspector/front-end/DockController.js:
23893         (WebInspector.DockController):
23894
23895 2012-11-02  Shinya Kawanaka  <shinyak@chromium.org>
23896
23897         [Shadow] ShadowRoot should be able to know the existence of <content>
23898         https://bugs.webkit.org/show_bug.cgi?id=100921
23899
23900         Reviewed by Dimitri Glazkov.
23901
23902         When <content> is inserted into or removed from a shadow subtree, ShadowRoot counts the number of <content>.
23903         It provides O(1) method to check the existence of <content>.
23904
23905         This is necessary when we implement a fast checking path for distribution invalidation when an element attribute
23906         is changed. Larger context is explained in Bug 100451.
23907
23908         Test: fast/dom/shadow/has-content-elements.html
23909
23910         * dom/ShadowRoot.cpp:
23911         (WebCore::ShadowRoot::ShadowRoot):
23912         (WebCore::ShadowRoot::hasInsertionPoint): Since we track both <content> and <shadow>, we don't need to traverse
23913         all the descendants of ShadowRoot anymore.
23914         * dom/ShadowRoot.h:
23915         (WebCore::ShadowRoot::registerContentElement):
23916         (WebCore::ShadowRoot::unregisterContentElement):
23917         (WebCore::ShadowRoot::hasContentElement):
23918         (ShadowRoot):
23919         * html/shadow/HTMLContentElement.cpp:
23920         (WebCore::HTMLContentElement::HTMLContentElement):
23921         (WebCore::HTMLContentElement::insertedInto): When <content> is inserted into ShadowDOM subtree,
23922         we notify it to the ShadowRoot. Note that only active <content> element is counted.
23923         (WebCore):
23924         (WebCore::HTMLContentElement::removedFrom):
23925         * html/shadow/HTMLContentElement.h:
23926         (HTMLContentElement):
23927         * testing/Internals.cpp:
23928         (WebCore::Internals::hasContentElement):
23929         (WebCore):
23930         * testing/Internals.h:
23931         (Internals):
23932         * testing/Internals.idl:
23933
23934 2012-11-02  KyungTae Kim  <ktf.kim@samsung.com>
23935
23936         sCurrentPaintTimeStamp is not initialized when FrameView::paintContents returns in the middle
23937         https://bugs.webkit.org/show_bug.cgi?id=99990
23938
23939         Reviewed by Darin Adler.
23940
23941         Move initialization code for sCurrentPaintTimeStamp to the below of early returns,
23942         because it was not reset after early return.
23943
23944         * page/FrameView.cpp:
23945         (WebCore::FrameView::paintContents):
23946
23947 2012-11-02  KyungTae Kim  <ktf.kim@samsung.com>
23948
23949         Fix build warning in PluginView.cpp on release build
23950         https://bugs.webkit.org/show_bug.cgi?id=101049
23951
23952         Reviewed by Kentaro Hara.
23953
23954         The protocol, host, port parameters are not used when LOG_DISABLED
23955         Use UNUSED_PARAM macro for removing -Wunused-parameter warning
23956
23957         * plugins/PluginView.cpp:
23958         (WebCore::PluginView::getAuthenticationInfo):
23959
23960 2012-10-25  Martin Robinson  <mrobinson@igalia.com>
23961
23962         [GTK] Move soup authentication from GtkAuthenticationDialog to WebCore
23963         https://bugs.webkit.org/show_bug.cgi?id=99914
23964
23965         Reviewed by Carlos Garcia Campos.
23966
23967         Move the actual soup authentication code from the GtkAuthenticationDialog to ResourceHandleSoup.
23968         This allows a more generic implementation of authentication, for example, one where a WebKit2
23969         client can completely handle authentication.
23970
23971         No new tests. This does not change behavior.
23972
23973         * platform/gtk/GtkAuthenticationDialog.cpp: Remove references to the SoupPasswordManager, which
23974         is going away in the next release of Gnome. Instead we always assume that the authentication backend has
23975         support for remembering passwords and pass that information along with the answer to the authentication
23976         request.
23977
23978         The rest of the changes to this class can be summarized as:
23979         1. Getting the information from the AuthenticationChallenge instead of directly from the libsoup
23980            objects.
23981         2. Using the AuthenticationClient to accomplish the authentication instead of talking to libsoup
23982            directly.
23983         * platform/gtk/GtkAuthenticationDialog.h:
23984         (GtkAuthenticationDialog): Remove members which are no longer used.
23985         * platform/network/ResourceHandle.h:
23986         (ResourceHandle): ResourceHandleSoup now implements the entire AuthenticationClient interface.
23987         * platform/network/soup/ResourceHandleSoup.cpp:
23988         (WebCore::WebCoreSynchronousLoader::didReceiveAuthenticationChallenge): Don't handle authentication
23989         for synchronous handles.
23990         (WebCore::ResourceHandle::didReceiveAuthenticationChallenge): Now set the current challenge on
23991         the internal data structure.
23992         (WebCore::ResourceHandle::receivedRequestToContinueWithoutCredential): Added.
23993         (WebCore::ResourceHandle::receivedCredential): Added.
23994         (WebCore::ResourceHandle::receivedCancellation): Added.
23995         (WebCore::authenicateCallback): Pass the handle as the authentication client.
23996
23997 2012-11-02  Benjamin Poulain  <bpoulain@apple.com>
23998
23999         Improve CSSParser::setupParser() since the prefix/suffix are literals
24000         https://bugs.webkit.org/show_bug.cgi?id=101107
24001
24002         Reviewed by Andreas Kling.
24003
24004         * css/CSSParser.cpp:
24005         (WebCore::CSSParser::setupParser):
24006         * css/CSSParser.h:
24007         (CSSParser):
24008         (WebCore::CSSParser::setupParser):
24009         CSSParser::setupParser() is only used with literals prefix and suffix. We do not have
24010         to compute the length at runtime, we can direclty encode it in the binary.
24011
24012 2012-11-02  Sheriff Bot  <webkit.review.bot@gmail.com>
24013
24014         Unreviewed, rolling out r133375.
24015         http://trac.webkit.org/changeset/133375
24016         https://bugs.webkit.org/show_bug.cgi?id=101138
24017
24018         Caused 3 tests to fail on Mac (Requested by aboxhall-laptop on
24019         #webkit).
24020
24021         * platform/text/LineBreakIteratorPoolICU.h:
24022         (WebCore::LineBreakIteratorPool::take):
24023         (WebCore::LineBreakIteratorPool::put):
24024         (LineBreakIteratorPool):
24025         * platform/text/TextBreakIterator.h:
24026         (WebCore):
24027         (WebCore::LazyLineBreakIterator::LazyLineBreakIterator):
24028         (WebCore::LazyLineBreakIterator::get):
24029         (WebCore::LazyLineBreakIterator::reset):
24030         (LazyLineBreakIterator):
24031         * platform/text/TextBreakIteratorICU.cpp:
24032         (WebCore::acquireLineBreakIterator):
24033         (WebCore::releaseLineBreakIterator):
24034         * rendering/RenderBlockLineLayout.cpp:
24035         (WebCore::RenderBlock::LineBreaker::nextLineBreak):
24036         * rendering/RenderText.cpp:
24037         (WebCore::RenderText::computePreferredLogicalWidths):
24038         * rendering/RenderText.h:
24039         (WebCore):
24040         * rendering/break_lines.cpp:
24041         (WebCore):
24042         (WebCore::isBreakableSpace):
24043         (WebCore::needsLineBreakIterator):
24044         (WebCore::nextBreakablePosition):
24045         (WebCore::nextBreakablePositionIgnoringNBSP):
24046         * rendering/break_lines.h:
24047         (WebCore):
24048         (WebCore::isBreakable):
24049
24050 2012-11-02  Andreas Kling  <kling@webkit.org>
24051
24052         Cut overgrown ElementAttributeData bitfield.
24053         <http://webkit.org/b/101129>
24054
24055         Reviewed by Anders Carlsson.
24056
24057         Make sure the ElementAttributeData bitfield fits into 32 bits. Added a compile-time assertion
24058         to guard against future bloatage.
24059
24060         * dom/ElementAttributeData.cpp:
24061         (SameSizeAsElementAttributeData):
24062         * dom/ElementAttributeData.h:
24063         (ElementAttributeData):
24064
24065 2012-11-02  Michael Saboff  <msaboff@apple.com>
24066
24067         Crash calling is8Bit() in visitedLinkHash()
24068         https://bugs.webkit.org/show_bug.cgi?id=101119
24069
24070         Reviewed by Filip Pizlo.
24071
24072         Added an isEmpty() check to AttributeURL and KURL.
24073
24074         * platform/LinkHash.cpp:
24075         (WebCore::visitedLinkHash):
24076
24077 2012-11-02  Glenn Adams  <glenn@skynav.com>
24078
24079         Add support to -webkit-line-break property for CSS3 Text line-break property values and semantics.
24080         https://bugs.webkit.org/show_bug.cgi?id=89235
24081
24082         Reviewed by Eric Seidel.
24083
24084         See also wiki documentation at:
24085         [1] http://trac.webkit.org/wiki/LineBreaking
24086         [2] http://trac.webkit.org/wiki/LineBreakingCSS3Mapping
24087
24088         Web exposed changes include:
24089         (1) The default (initial) value for -webkit-line-break becomes 'auto', instead of 'normal';
24090         (2) The values 'auto', 'loose', 'normal', and 'strict' are added to -webkit-line-break;
24091         (3) See [2] above for details regarding interpretation.
24092
24093         Tests: css3/line-break/line-break-auto-centered.html
24094                css3/line-break/line-break-auto-half-kana.html
24095                css3/line-break/line-break-auto-hyphens.html
24096                css3/line-break/line-break-auto-inseparables.html
24097                css3/line-break/line-break-auto-iteration-marks.html
24098                css3/line-break/line-break-auto-postfixes.html
24099                css3/line-break/line-break-auto-prefixes.html
24100                css3/line-break/line-break-auto-sound-marks.html
24101                css3/line-break/line-break-loose-centered.html
24102                css3/line-break/line-break-loose-half-kana.html
24103                css3/line-break/line-break-loose-hyphens.html
24104                css3/line-break/line-break-loose-inseparables.html
24105                css3/line-break/line-break-loose-iteration-marks.html
24106                css3/line-break/line-break-loose-postfixes.html
24107                css3/line-break/line-break-loose-prefixes.html
24108                css3/line-break/line-break-loose-sound-marks.html
24109                css3/line-break/line-break-normal-centered.html
24110                css3/line-break/line-break-normal-half-kana.html
24111                css3/line-break/line-break-normal-hyphens.html
24112                css3/line-break/line-break-normal-inseparables.html
24113                css3/line-break/line-break-normal-iteration-marks.html
24114                css3/line-break/line-break-normal-postfixes.html
24115                css3/line-break/line-break-normal-prefixes.html
24116                css3/line-break/line-break-normal-sound-marks.html
24117                css3/line-break/line-break-strict-centered.html
24118                css3/line-break/line-break-strict-half-kana.html
24119                css3/line-break/line-break-strict-hyphens.html
24120                css3/line-break/line-break-strict-inseparables.html
24121                css3/line-break/line-break-strict-iteration-marks.html
24122                css3/line-break/line-break-strict-postfixes.html
24123                css3/line-break/line-break-strict-prefixes.html
24124                css3/line-break/line-break-strict-sound-marks.html
24125
24126         * platform/text/LineBreakIteratorPoolICU.h:
24127         (WebCore::LineBreakIteratorPool::makeLocaleWithBreakKeyword):
24128         Add static function to construct ICU locale argument (also used as pool key) with additional
24129         break keyword.
24130         (WebCore::LineBreakIteratorPool::take):
24131         (WebCore::LineBreakIteratorPool::put):
24132         (LineBreakIteratorPool):
24133         Remove direct dependency from ICU library (and types), moving that dependency into
24134         new {open,close}LineBreakIterator() functions (defined in TextBreakIteratorICU.cpp).
24135         Update to take line break mode into account.
24136         Create (and cache) different break iterators depending on line break mode (in addition to locale),
24137         which entails expanding pool entry key format to optionally append "@break=" +
24138         "loose"|"normal"|"strict" keyword to locale string.
24139
24140         * platform/text/TextBreakIterator.h:
24141         (WebCore::LazyLineBreakIterator::LazyLineBreakIterator):
24142         (WebCore::LazyLineBreakIterator::isLooseCJKMode):
24143         (WebCore::LazyLineBreakIterator::get):
24144         (WebCore::LazyLineBreakIterator::reset):
24145         (LazyLineBreakIterator):
24146         Define LineBreakIteratorMode enumeration for use in TextBreakIterator et al.
24147         Add state member to indicate line break mode.
24148
24149         * platform/text/TextBreakIteratorICU.cpp:
24150         (WebCore::acquireLineBreakIterator):
24151         Use new line break mode when making iterator from pool.
24152         Handle change of return type of LineBreakIteratorPool::take() to non-ICU type,
24153         i.e., TextBreakIterator* instead of ICU's UBreakIterator*.
24154         (WebCore::releaseLineBreakIterator):
24155         Handle change of parameter type of LineBreakIteratorPool::put() to non-ICU type,
24156         i.e., TextBreakIterator* instead of ICU's UBreakIterator*.
24157         (WebCore::isCJKLocale):
24158         New functions for determining if CJK rules apply.
24159         (WebCore::openLineBreakIterator):
24160         New function for abstracting opening of ICU style line break iterator. This is now
24161         used in LineBreakIteratorPoolICU.h rather than having direct ICU API dependency there.
24162         This function also takes into account the line break mode.
24163         (WebCore::closeLineBreakIterator):
24164         (WebCore::mapLineIteratorModeToRules):
24165         New function for abstracting closing of ICU style line break iterator. This is now
24166         used in LineBreakIteratorPoolICU.h rather than having direct ICU API dependency there.
24167
24168         * rendering/RenderBlockLineLayout.cpp:
24169         (WebCore::RenderBlock::LineBreaker::nextLineBreak):
24170         Pass line break iterator mode flag when reseting LazyLineBreakIterator.
24171         Add looseMode local variable to prevent need for computing under isBreakable().
24172
24173         * rendering/RenderText.cpp:
24174         (WebCore::mapLineBreakToIteratorMode):
24175         Add implementation for mapLineBreakToIteratorMode(), used by both RenderText::computePreferredLogicalWidths
24176         and RenderBlock::LineBreaker::nextLineBreak.
24177         (WebCore::RenderText::computePreferredLogicalWidths):
24178         Ensure (lazy line) breakIterator is initialized for line break mode.
24179         Ensure isBreakable() is passed loose mode flag to match behavior in RenderBlock::LineBreaker::nextLineBreak.
24180
24181         * rendering/RenderText.h:
24182         (WebCore):
24183         Add declaration for mapLineBreakToIteratorMode(), used by both RenderText::computePreferredLogicalWidths
24184         and RenderBlock::LineBreaker::nextLineBreak.
24185
24186         * rendering/break_lines.cpp:
24187         (WebCore):
24188         Introduce two (local) enums NBSPBehavior and LooseBehavior for expanding template on nextBreakablePosition
24189         to include loose mode parameter.
24190         (WebCore::isBreakableSpace):
24191         Add externally specified loose mode parameter to prevent need to invoke line break iterator
24192         accessor method on each invocation. Use new loose mode flavors off NBP functions.
24193         (WebCore::needsLineBreakIterator):
24194         Introduce loose mode behavior template parameter to optimize loose mode behavior code path in order
24195         to prevent regression to non loose mode path.
24196         (WebCore::nextBreakablePosition):
24197         (WebCore::nextBreakablePositionIgnoringNBSP):
24198         Use new template parameter enums described above.
24199         (WebCore::nextBreakablePositionIgnoringNBSPLoose):
24200         (WebCore::nextBreakablePositionLoose):
24201         Introduce two additional 'loose' mode flavors of NBP template expansions.
24202
24203         * rendering/break_lines.h:
24204         (WebCore):
24205         (WebCore::isBreakable):
24206         Add externally specified loose mode parameter to prevent need to invoke line break iterator
24207         accessor method on each invocation.
24208
24209 2012-11-02  Elliott Sprehn  <esprehn@chromium.org>
24210
24211         Replace NodeRareData hash map with a union on m_renderer
24212         https://bugs.webkit.org/show_bug.cgi?id=100057
24213
24214         Reviewed by Eric Seidel.
24215
24216         Use a union on Node::m_renderer between NodeRareData* and RenderObject*. This removes
24217         the overhead of accessing rare data and the memory from the map.
24218
24219         This is an 8% improvement on Bindings/get-elements-by-tag-name.html which tested
24220         document.getElementsByTagName and was previously optimized in Bug 90059 for a 5% 
24221         improvement. As this is better than even the special casing for document that was
24222         done in that bug, general node list access should see an even greater win.
24223
24224         This reduces the memory usage on nytimes.com by 250k per Bug 101052 by
24225         removing the rare data map overhead.
24226
24227         This is also a 15% improvement on Parser/textarea-parsing.html
24228
24229         By removing the performance overhead of rareData() this patch addresses the performance
24230         issues raised in Bugs 73853, 87034 and 89635.
24231
24232         I ran Parser/html5-full-render.html and there was no performance regression after
24233         tuning Text::recalcTextStyle and the refactor that was done in r132684.
24234
24235         No new tests, this is just a refactor.
24236
24237         * dom/Document.cpp:
24238         (WebCore::Document::Document):
24239         * dom/Document.h:
24240         (WebCore::Node::Node):
24241         * dom/Element.cpp:
24242         (WebCore::Element::elementRareData):
24243         * dom/Node.cpp:
24244         (WebCore::Node::rareData):
24245         (WebCore::Node::ensureRareData):
24246         (WebCore::Node::clearRareData):
24247         (WebCore::Node::renderBox):
24248         (WebCore::Node::renderBoxModelObject):
24249         (WebCore::Node::reportMemoryUsage):
24250         * dom/Node.h:
24251         (NodeRareDataBase):
24252           Base class for NodeRareData that knows about the renderer so we can
24253           inline the accesses in Node.h
24254         (WebCore::NodeRareDataBase::renderer):
24255         (WebCore::NodeRareDataBase::setRenderer):
24256         (WebCore::NodeRareDataBase::~NodeRareDataBase):
24257         (WebCore::NodeRareDataBase::NodeRareDataBase):
24258         (WebCore):
24259         (WebCore::Node::renderer):
24260         (WebCore::Node::setRenderer):
24261         (Node):
24262         * dom/NodeRareData.h:
24263         * dom/NodeRenderStyle.h:
24264         (WebCore::Node::renderStyle):
24265         * dom/Text.cpp:
24266         (WebCore::Text::recalcTextStyle):
24267           This method appears very hot in html5-full-render.html and accessing the
24268           renderer 4 times caused a 2% performance regression with this patch. I
24269           reduced it to 1 access and there's no longer any performance regression.
24270         * dom/WebCoreMemoryInstrumentation.cpp:
24271           Removed tracking of the rare data map memory usage as there is no longer
24272           a map to track.
24273         * dom/WebCoreMemoryInstrumentation.h:
24274         * inspector/InspectorMemoryAgent.cpp:
24275         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
24276
24277 2012-11-02  Alexey Proskuryakov  <ap@apple.com>
24278
24279         [Mac] ResourceHandle changes for network process
24280         https://bugs.webkit.org/show_bug.cgi?id=101111
24281
24282         Reviewed by Jessie Berlin.
24283
24284         With NSOperationQueue, we'll be getting NetworkProcess delegate method calls
24285         on secondary threads, and so we won't block other requests while consulting with WebProcess.
24286
24287         * platform/network/NetworkingContext.h:
24288         (WebCore::NetworkingContext::scheduledRunLoopPairs):
24289         (WebCore::NetworkingContext::scheduledOperationQueue):
24290         Add an ability to schedule on an NSOperationQueue. Now that scheduling on run loop
24291         is not a must, give scheduledRunLoopPairs() a default implementation.
24292
24293         * platform/network/mac/ResourceHandleMac.mm: Removed isInitializingConnection
24294         static. It was only used to catch a long obsolete bug with debug logging, and
24295         cannot work with multiple threads.
24296         (WebCore::ResourceHandle::start): Scedule on a operation queue if applicable.
24297         (-[WebCoreResourceHandleAsDelegate connection:willCacheResponse:]): Removed a
24298         check that used isInitializingConnection.
24299
24300 2012-11-02  Chris Rogers  <crogers@google.com>
24301
24302         Automating gain AudioParam with linearRampToValueAtTime introduces buzzing distortion
24303         https://bugs.webkit.org/show_bug.cgi?id=100885
24304
24305         Reviewed by Kenneth Russell.
24306
24307         AudioParamTimeline needs to use double-precision for time-values to avoid drift and precision issues.
24308
24309         Covered by existing tests.
24310
24311         * Modules/webaudio/AudioParam.cpp:
24312         (WebCore::AudioParam::calculateTimelineValues):
24313         * Modules/webaudio/AudioParamTimeline.cpp:
24314         (WebCore::AudioParamTimeline::valueForContextTime):
24315         (WebCore::AudioParamTimeline::valuesForTimeRange):
24316         (WebCore::AudioParamTimeline::valuesForTimeRangeImpl):
24317         * Modules/webaudio/AudioParamTimeline.h:
24318         (AudioParamTimeline):
24319
24320 2012-11-02  Stephen Chenney  <schenney@chromium.org>
24321
24322         Reduce redundant code in SimpleFontData[platform]
24323         https://bugs.webkit.org/show_bug.cgi?id=97245
24324
24325         Reviewed by Eric Seidel.
24326
24327         Move duplicated code out of platform specific files and into the common file.
24328         This represents all of the methods in SimpleFontData that do not have genuine
24329         platform specific code.
24330
24331         No new tests because there is no change at all in the functionality.
24332
24333         * platform/graphics/SimpleFontData.cpp:
24334         (WebCore):
24335         (WebCore::SimpleFontData::smallCapsFontData): Implementation from platform files.
24336         (WebCore::SimpleFontData::emphasisMarkFontData): Implementation from platform files.
24337         * platform/graphics/chromium/SimpleFontDataChromiumWin.cpp:
24338         (WebCore): Removed common code.
24339         * platform/graphics/freetype/SimpleFontDataFreeType.cpp:
24340         (WebCore): Removed common code.
24341         * platform/graphics/mac/SimpleFontDataMac.mm:
24342         (WebCore): Removed common code.
24343         * platform/graphics/pango/SimpleFontDataPango.cpp:
24344         (WebCore): Removed common code.
24345         * platform/graphics/qt/SimpleFontDataQt.cpp:
24346         (WebCore): Removed common code.
24347         * platform/graphics/skia/SimpleFontDataSkia.cpp:
24348         (WebCore): Removed common code.
24349         * platform/graphics/win/SimpleFontDataWin.cpp:
24350         (WebCore): Removed common code.
24351         * platform/graphics/wince/SimpleFontDataWinCE.cpp:
24352         (WebCore): Removed common code.
24353         * platform/graphics/wx/SimpleFontDataWx.cpp:
24354         (WebCore): Removed common code.
24355
24356 2012-11-02  Adam Barth  <abarth@webkit.org>
24357
24358         memory-instrumentation-cached-images.html is crashing
24359         https://bugs.webkit.org/show_bug.cgi?id=101103
24360
24361         Unreviewed.
24362
24363         Restore code deleted in http://trac.webkit.org/changeset/133331.
24364
24365         * bindings/v8/IntrusiveDOMWrapperMap.h:
24366
24367 2012-11-02  Simon Fraser  <simon.fraser@apple.com>
24368
24369         Enable SUBPIXEL_LAYOUT on Mac
24370         https://bugs.webkit.org/show_bug.cgi?id=101076
24371
24372         Reviewed by Dave Hyatt.
24373
24374         Define ENABLE_SUBPIXEL_LAYOUT and include it in FEATURE_DEFINES.
24375
24376         * Configurations/FeatureDefines.xcconfig:
24377
24378 2012-11-02  Lianghui Chen  <liachen@rim.com>
24379
24380         [BlackBerry] ResourceHandle::cancel() in ResourceHandleBlackBerry should setClient to null.
24381         https://bugs.webkit.org/show_bug.cgi?id=101082
24382
24383         Internal PR: 235410.
24384         Patch suggested by George Staikos, prepared by Lyon Chen.
24385         Reviewed by Yong Li.
24386
24387         ResourceHandle::cancel() should call setClient(0) to close the window
24388         during which it has been cancelled but its client is still there and can
24389         be called.
24390
24391         No new tests as it's a code improvement without obvious bug.
24392
24393         * platform/network/blackberry/ResourceHandleBlackBerry.cpp:
24394         (WebCore::ResourceHandle::cancel):
24395
24396 2012-11-02  Anders Carlsson  <andersca@apple.com>
24397
24398         Add a PluginInactive plug-in unavailability reason
24399         https://bugs.webkit.org/show_bug.cgi?id=101089
24400
24401         Reviewed by Sam Weinig.
24402
24403         This is to be used by Mac WebKit and WebKit2 shortly.
24404
24405         * English.lproj/Localizable.strings:
24406         * platform/LocalizedStrings.cpp:
24407         (WebCore::inactivePluginText):
24408         (WebCore):
24409         * platform/LocalizedStrings.h:
24410         (WebCore):
24411         * platform/blackberry/LocalizedStringsBlackBerry.cpp:
24412         (WebCore::inactivePluginText):
24413         (WebCore):
24414         * platform/efl/LocalizedStringsEfl.cpp:
24415         (WebCore::inactivePluginText):
24416         (WebCore):
24417         * platform/gtk/LocalizedStringsGtk.cpp:
24418         (WebCore::inactivePluginText):
24419         (WebCore):
24420         * platform/qt/LocalizedStringsQt.cpp:
24421         (WebCore::inactivePluginText):
24422         (WebCore):
24423         * rendering/RenderEmbeddedObject.cpp:
24424         (WebCore::unavailablePluginReplacementText):
24425         * rendering/RenderEmbeddedObject.h:
24426
24427 2012-11-02  Rob Buis  <rbuis@rim.com>
24428
24429         [CMAKE] Remove QNX specific section
24430         https://bugs.webkit.org/show_bug.cgi?id=101063
24431
24432         Reviewed by Daniel Bates.
24433
24434         We do not need the QNX section anymore, so also remove the FEATURE_DEFINES_CSS variable as it
24435         equals FEATURE_DEFINES_WITH_SPACE_SEPARATOR.
24436
24437         * CMakeLists.txt:
24438
24439 2012-11-02  Michael Saboff  <msaboff@apple.com>
24440
24441         visitedHashLink() converts 8 bit URLs and attributes to 16 bits.
24442         https://bugs.webkit.org/show_bug.cgi?id=101014
24443
24444         Reviewed by Geoffrey Garen.
24445
24446         Converted most of the static methods to templated based on character type.  Changed visitedHashLink to 
24447         check bitness of both the base URL and attribute.  If both are 8 bit, then we process using the LChar
24448         version of the templated methods.  Otherwise we use the 16 bit flavor.
24449
24450         Changes covered by existing tests.
24451
24452         * platform/LinkHash.cpp:
24453         (WebCore::findSlashDotDotSlash):
24454         (WebCore::findSlashSlash):
24455         (WebCore::findSlashDotSlash):
24456         (WebCore::containsColonSlashSlash):
24457         (WebCore::squeezeOutNullCharacters):
24458         (WebCore::cleanSlashDotDotSlashes):
24459         (WebCore::mergeDoubleSlashes):
24460         (WebCore::cleanSlashDotSlashes):
24461         (WebCore::cleanPath):
24462         (WebCore::matchLetter):
24463         (WebCore::needsTrailingSlash):
24464         (WebCore::visitedURLInline):
24465         (WebCore::visitedURL):
24466         (WebCore::visitedLinkHash):
24467
24468 2012-11-02  Ian Vollick  <vollick@chromium.org>
24469
24470         Support invalidation tracking for composited layers
24471         https://bugs.webkit.org/show_bug.cgi?id=97801
24472
24473         Reviewed by Simon Fraser.
24474
24475         GraphicsLayers now store invalidated rects and can include them in
24476         the layer tree dump.
24477
24478         Test: compositing/repaint/invalidations-on-composited-layers.html
24479
24480         * WebCore.exp.in:
24481           Exports FrameView::resetTrackedRepaints()
24482         * page/FrameView.cpp:
24483         (WebCore::FrameView::setTracksRepaints):
24484           Notifies each compositor that we are starting/stopping repaints.
24485         (WebCore::FrameView::resetTrackedRepaints):
24486           Moved implementation to the cpp file.
24487         * platform/graphics/GraphicsLayer.cpp:
24488         (WebCore::GraphicsLayer::~GraphicsLayer):
24489           Clears the repaint rects associated with this layer.
24490         (WebCore::GraphicsLayer::resetTrackedRepaints):
24491           Clears the repaint rects associated with this layer.
24492           Note that the repaint rects are stored in a statically allocated
24493           HashMap to avoid using space on the graphics layers.
24494         (WebCore::GraphicsLayer::addRepaintRect):
24495           Adds a repaint rect to list associated with this layer in the
24496           hash map mentioned above.
24497         (WebCore::GraphicsLayer::dumpProperties):
24498           This has been modified to include the repaint rects in the dump
24499           if they've been requested.
24500         * platform/graphics/GraphicsLayerClient.h:
24501         (WebCore::GraphicsLayerClient::isTrackingRepaints):
24502           This is how graphics layers check if repaint tracking is happening.
24503           Returns false by default.
24504         * platform/graphics/blackberry/GraphicsLayerBlackBerry.cpp:
24505         (WebCore::GraphicsLayerBlackBerry::setContentsNeedsDisplay):
24506         (WebCore::GraphicsLayerBlackBerry::setNeedsDisplay):
24507         (WebCore::GraphicsLayerBlackBerry::setNeedsDisplayInRect):
24508           These now call GraphicsLayer::addRepaintRect as necessary.
24509         * platform/graphics/ca/GraphicsLayerCA.cpp:
24510         (WebCore::GraphicsLayerCA::setNeedsDisplayInRect):
24511           Now calls GraphicsLayer::addRepaintRect as necessary.
24512         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
24513         (WebCore::GraphicsLayerChromium::setContentsNeedsDisplay):
24514         (WebCore::GraphicsLayerChromium::setNeedsDisplay):
24515         (WebCore::GraphicsLayerChromium::setNeedsDisplayInRect):
24516           These now call GraphicsLayer::addRepaintRect as necessary.
24517         * platform/graphics/clutter/GraphicsLayerClutter.cpp:
24518         (WebCore::GraphicsLayerClutter::setNeedsDisplay):
24519         (WebCore::GraphicsLayerClutter::setNeedsDisplayInRect):
24520           These now call GraphicsLayer::addRepaintRect as necessary.
24521         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
24522         (WebCore::GraphicsLayerTextureMapper::setNeedsDisplay):
24523         (WebCore::GraphicsLayerTextureMapper::setContentsNeedsDisplay):
24524         (WebCore::GraphicsLayerTextureMapper::setNeedsDisplayInRect):
24525           These now call GraphicsLayer::addRepaintRect as necessary.
24526         * rendering/RenderLayerBacking.cpp:
24527         (WebCore::RenderLayerBacking::isTrackingRepaints):
24528           Required since this is a GraphicsLayerClient.
24529         * rendering/RenderLayerCompositor.cpp:
24530         (WebCore::RenderLayerCompositor::layerTreeAsText):
24531           Now accepts a flag to include the repaint rects in the layer tree
24532           dump.
24533         (WebCore::resetTrackedRepaintRectsRecursive):
24534           Clears the repaint rects on all graphics layers.
24535         (WebCore::RenderLayerCompositor::resetTrackedRepaintRects):
24536           Clears the repaint rects on all graphics layers.
24537         (WebCore::RenderLayerCompositor::isTrackingRepaints):
24538           Required since this is a GraphicsLayerClient.
24539         * testing/Internals.cpp:
24540         (WebCore::Internals::layerTreeAsText):
24541         * testing/Internals.h:
24542         * testing/Internals.idl:
24543           The internals changes plumb the new flag for including the repaint
24544           rects in the layer tree dump.
24545
24546 2012-11-02  Adam Barth  <abarth@webkit.org>
24547
24548         [V8] Generalize NodeWrapperMap to be able to handle other sorts of keys
24549         https://bugs.webkit.org/show_bug.cgi?id=100973
24550
24551         Reviewed by Stephen White.
24552
24553         This is the first step towards using intrusive DOM wrapper maps more
24554         widely in WebCore (see
24555         http://lists.webkit.org/pipermail/webkit-dev/2012-November/022686.html
24556         for more context).
24557
24558         * bindings/v8/DOMDataStore.cpp:
24559         (WebCore::DOMDataStore::DOMDataStore):
24560         * bindings/v8/IntrusiveDOMWrapperMap.h:
24561         (WebCore):
24562         (WebCore::IntrusiveDOMWrapperMap::weakCallback):
24563
24564 2012-11-02  Adam Barth  <abarth@webkit.org>
24565
24566         ASSERT in RenderLayer::hitTestContents can fire
24567         https://bugs.webkit.org/show_bug.cgi?id=99656
24568
24569         Reviewed by Eric Seidel.
24570
24571         The issue is that updateHitTestResult and addNodeToRectBasedTestResult
24572         are using two different nodes. Since they aren't consistent, we violate
24573         assertions about only setting the inner node if we're doing a
24574         rect-based hit test. This patch makes the two consistent.
24575
24576         Test: fast/dom/nodesFromRect/nodesFromRect-continuation-crash.html
24577
24578         * rendering/RenderBlock.cpp:
24579         (WebCore::RenderBlock::nodeForHitTest):
24580         (WebCore):
24581         (WebCore::RenderBlock::nodeAtPoint):
24582         (WebCore::RenderBlock::updateHitTestResult):
24583         * rendering/RenderBlock.h:
24584         (RenderBlock):
24585
24586 2012-11-02  Mike West  <mkwst@chromium.org>
24587
24588         Prefer 'Content-Security-Policy' to 'X-WebKit-CSP'.
24589         https://bugs.webkit.org/show_bug.cgi?id=101043
24590
24591         Reviewed by Adam Barth.
24592
24593         The canonical 'Content-Security-Policy' header landed in 133095, but we
24594         missed a few tests while updating to the new hotness. We also should
24595         start using the canonical header for the inspector.
24596
24597         This patch should have no visible change; tests should continue to pass
24598         with the new header, just as they did with the old header.
24599
24600         * inspector/front-end/inspector.html:
24601
24602 2012-11-02  Adam Barth  <abarth@webkit.org>
24603
24604         ENABLE(UNDO_MANAGER) is disabled everywhere and is not under active development
24605         https://bugs.webkit.org/show_bug.cgi?id=100711
24606
24607         Reviewed by Eric Seidel.
24608
24609         No one is actively working on ENABLE(UNDO_MANAGER). There are some
24610         tricky lifetime issues in the UndoManager API that are complicating
24611         ongoing work to improve the interaction between WebCore and the garbage
24612         collector. Rather than leave this code in a broken state, we should
24613         remove it for the time being. We can always restore it from the svn
24614         history when there is an active owner for this code.
24615
24616         * CMakeLists.txt:
24617         * Configurations/FeatureDefines.xcconfig:
24618         * DerivedSources.cpp:
24619         * DerivedSources.make:
24620         * DerivedSources.pri:
24621         * GNUmakefile.features.am:
24622         * GNUmakefile.list.am:
24623         * Target.pri:
24624         * UseJSC.cmake:
24625         * UseV8.cmake:
24626         * WebCore.gypi:
24627         * WebCore.vcproj/WebCore.vcproj:
24628         * WebCore.xcodeproj/project.pbxproj:
24629         * bindings/js/DOMTransaction.cpp: Removed.
24630         * bindings/js/DOMTransaction.h: Removed.
24631         * bindings/js/JSBindingsAllInOne.cpp:
24632         * bindings/js/JSUndoManagerCustom.cpp: Removed.
24633         * bindings/v8/DOMTransaction.cpp: Removed.
24634         * bindings/v8/DOMTransaction.h: Removed.
24635         * bindings/v8/V8HiddenPropertyName.h:
24636         (WebCore):
24637         * bindings/v8/custom/V8DOMTransactionCustom.cpp: Removed.
24638         * bindings/v8/custom/V8UndoManagerCustom.cpp: Removed.
24639         * css/PropertySetCSSStyleDeclaration.cpp:
24640         (WebCore::PropertySetCSSStyleDeclaration::setCssText):
24641         (WebCore::PropertySetCSSStyleDeclaration::setProperty):
24642         (WebCore::PropertySetCSSStyleDeclaration::removeProperty):
24643         (WebCore::PropertySetCSSStyleDeclaration::setPropertyInternal):
24644         * dom/CharacterData.cpp:
24645         (WebCore::CharacterData::setDataAndUpdate):
24646         * dom/ContainerNode.cpp:
24647         (WebCore::willRemoveChild):
24648         (WebCore::willRemoveChildren):
24649         (WebCore::updateTreeAfterInsertion):
24650         * dom/Document.cpp:
24651         (WebCore::Document::Document):
24652         * dom/Document.h:
24653         (WebCore):
24654         (Document):
24655         * dom/Document.idl:
24656         * dom/Element.cpp:
24657         (WebCore::Element::willModifyAttribute):
24658         * editing/CompositeEditCommand.h:
24659         * editing/DOMTransaction.idl: Removed.
24660         * editing/DOMTransactionStep.cpp: Removed.
24661         * editing/DOMTransactionStep.h: Removed.
24662         * editing/Editor.cpp:
24663         (WebCore::Editor::appliedEditing):
24664         (WebCore::Editor::unappliedEditing):
24665         (WebCore::Editor::reappliedEditing):
24666         (WebCore::Editor::canUndo):
24667         (WebCore::Editor::undo):
24668         (WebCore::Editor::canRedo):
24669         (WebCore::Editor::redo):
24670         * editing/UndoManager.cpp: Removed.
24671         * editing/UndoManager.h: Removed.
24672         * editing/UndoManager.idl: Removed.
24673         * editing/UndoStep.h:
24674         (UndoStep):
24675
24676 2012-11-02  Mike West  <mkwst@chromium.org>
24677
24678         Measure the usage of the various CSP headers.
24679         https://bugs.webkit.org/show_bug.cgi?id=100974
24680
24681         Reviewed by Adam Barth.
24682
24683         Currently, we're collecting metrics regarding usage of the
24684         'X-WebKit-CSP' and 'X-WebKit-CSP-Report-Only' HTTP headers. We've
24685         recently added support for the canonical 'Content-Security-Policy'
24686         and 'Content-Security-Policy-Report-Only' headers. This patch adds
24687         those headers explicitly into the metrics, giving insight into uptake
24688         of the unprefixed header, and into usage of pure reporting vs.
24689         enforcement.
24690
24691         No visible functionality should change; all Content Security Policy
24692         tests should continue to pass.
24693
24694         * page/ContentSecurityPolicy.cpp:
24695         (WebCore::ContentSecurityPolicy::didReceiveHeader):
24696             Convert the CSP header type into a FeatureObserver::Feature, and
24697             observe it.
24698         * page/FeatureObserver.h:
24699             Add three new values to the enum to cover the new header types.
24700
24701 2012-11-02  Ojan Vafai  <ojan@chromium.org>
24702
24703         Fix silly mistake from http://trac.webkit.org/changeset/133315.
24704         Forgot to remove the "!".
24705
24706         * css/StyleResolver.cpp:
24707         (WebCore::StyleResolver::canShareStyleWithElement):
24708
24709 2012-11-02  Tom Sepez  <tsepez@chromium.org>
24710
24711         Support X-XSS-Protection: report=URL header syntax in XSSAuditor.
24712         https://bugs.webkit.org/show_bug.cgi?id=100892
24713
24714         Reviewed by Adam Barth.
24715
24716         This patch adds a security feature which allows a violation report to be sent back
24717         to a site when the XSSAuditor detects a reflected XSS against it.  It uses the same
24718         reporting mechanism as for CSP violation reports.
24719
24720         Tests: http/tests/security/xssAuditor/malformed-xss-protection-header-5.html
24721                http/tests/security/xssAuditor/malformed-xss-protection-header-6.html
24722                http/tests/security/xssAuditor/malformed-xss-protection-header-7.html
24723                http/tests/security/xssAuditor/malformed-xss-protection-header-8.html
24724                http/tests/security/xssAuditor/malformed-xss-protection-header-9.html
24725                http/tests/security/xssAuditor/report-script-tag.html
24726                http/tests/security/xssAuditor/xss-protection-parsing-03.html
24727                http/tests/security/xssAuditor/xss-protection-parsing-04.html
24728
24729         * html/parser/XSSAuditor.cpp:
24730         (WebCore::XSSAuditor::XSSAuditor):
24731         (WebCore::XSSAuditor::init):
24732         (WebCore::XSSAuditor::filterToken):
24733         Invoke Ping loader's violation reporting, if requested, when a reflected
24734         XSS is detected.
24735         
24736         * html/parser/XSSAuditor.h:
24737         XSSAuditor class need to store the report URL as well as the undigested versions
24738         of the request URL and request body for reporting.
24739
24740         * loader/MixedContentChecker.cpp:
24741         (WebCore):
24742         * loader/MixedContentChecker.h:
24743         (MixedContentChecker):
24744         Make isMixedContent() method public.
24745
24746         * loader/PingLoader.cpp:
24747         (WebCore::PingLoader::sendViolationReport):
24748         * loader/PingLoader.h:
24749         (PingLoader):
24750         * page/ContentSecurityPolicy.cpp:
24751         (WebCore::ContentSecurityPolicy::reportViolation):
24752         Renamed reportContentSecurityPolicyViolation() method to sendViolationReport(),
24753         since this is now used to send more than just CSP violations.
24754         
24755         * platform/network/HTTPParsers.cpp:
24756         (WebCore):
24757         (WebCore::skipEquals):
24758         (WebCore::skipValue):
24759         (WebCore::parseXSSProtectionHeader):
24760         * platform/network/HTTPParsers.h:
24761         Parse and return report= directive in X-XSS-Protection header.
24762         
24763 2012-11-02  Sheriff Bot  <webkit.review.bot@gmail.com>
24764
24765         Unreviewed, rolling out r133313.
24766         http://trac.webkit.org/changeset/133313
24767         https://bugs.webkit.org/show_bug.cgi?id=101078
24768
24769         "A lot of tests hit the ASSERTs introduced by this patch"
24770         (Requested by haraken on #webkit).
24771
24772         * bindings/v8/V8DOMWrapper.h:
24773         (WebCore::V8DOMWrapper::setDOMWrapper):
24774
24775 2012-11-02  Ojan Vafai  <ojan@chromium.org>
24776
24777         Unreviewed, rolling out r132913.
24778         http://trac.webkit.org/changeset/132913
24779         https://bugs.webkit.org/show_bug.cgi?id=91850
24780
24781         Caused performance regressions.
24782         See https://bugs.webkit.org/show_bug.cgi?id=100872 for details.
24783
24784         * bindings/v8/V8PerIsolateData.cpp:
24785         (WebCore::V8PerIsolateData::visitExternalStrings):
24786         * bindings/v8/V8StringResource.cpp:
24787         (StringTraits):
24788         (WebCore::v8StringToWebCoreString):
24789         * bindings/v8/V8ValueCache.cpp:
24790         (WebCore::makeExternalString):
24791         (WebCore::WebCoreStringResource::visitStrings):
24792         * bindings/v8/V8ValueCache.h:
24793         (WebCore::WebCoreStringResource::WebCoreStringResource):
24794         (WebCore::WebCoreStringResource::~WebCoreStringResource):
24795         (WebCore::WebCoreStringResource::data):
24796         (WebCoreStringResource):
24797         (WebCore::WebCoreStringResource::length):
24798         (WebCore::WebCoreStringResource::atomicString):
24799         (WebCore::WebCoreStringResource::toStringResource):
24800
24801 2012-11-02  Martin Robinson  <mrobinson@igalia.com>
24802
24803         [GTK] Remove dependency on SoupPasswordManager
24804         https://bugs.webkit.org/show_bug.cgi?id=100775
24805
24806         Reviewed by Carlos Garcia Campos.
24807
24808         Remember passwords using libsecret instead of SoupPasswordManager. We accomplish this using
24809         a new class, CredentialBackingStore. CredentialBackingStore will soon be the thing that backs
24810         CredentialStoreGtk. The name is based on the name of a similar class from the BlackBerry port.
24811
24812         No new tests. This does not change behavior.
24813
24814         * GNUmakefile.am: Add libsecret flags to the build and the new directory to the include list.
24815         * GNUmakefile.list.am: Add new files to the source list.
24816         * platform/gtk/GRefPtrGtk.cpp: Add support for SecretValue to GRefPtrGtk.
24817         * platform/gtk/GtkAuthenticationDialog.cpp: Replace interaction with SoupPasswordManger with
24818         interaction with the CredentialBackingStore. Remove all conditional SoupPasswordManager guards.
24819         * platform/gtk/GtkAuthenticationDialog.h: Ditto.
24820         * platform/network/gtk/CredentialBackingStore.cpp: Added.
24821         * platform/network/gtk/CredentialBackingStore.h: Added.
24822
24823 2012-11-02  Jinwoo Song  <jinwoo7.song@samsung.com>
24824
24825         Fix build warning [-Wswitch]
24826         https://bugs.webkit.org/show_bug.cgi?id=101029
24827
24828         Reviewed by Alexey Proskuryakov.
24829
24830         Fix build warning message: enumeration value ‘Viewport’ not handled in switch [-Wswitch]
24831         in Source/WebCore/css/StyleSheetContents.cpp.
24832         Add case statement for 'Viewport' with the CSS_DEVICE_ADAPTATION macro.
24833
24834         * css/StyleSheetContents.cpp:
24835         (WebCore::childRulesHaveFailedOrCanceledSubresources):
24836
24837 2012-11-02  Ojan Vafai  <ojan@chromium.org>
24838
24839         Move m_element checks out of canShareStyle into locateSharedStyle
24840         https://bugs.webkit.org/show_bug.cgi?id=101070
24841
24842         Reviewed by Darin Adler.
24843
24844         Can shareStyleWithElement is called for each sibling as we look for a
24845         shareElement. locateSharedStyle is called once for the element we're
24846         trying to find a style for. Checks that only depend on the latter
24847         element should, thus be in locateSharedStyle.
24848
24849         No new tests. There should be no change in behavior, except possibly
24850         a performance improvement in some cases.
24851
24852         * css/StyleResolver.cpp:
24853         (WebCore::StyleResolver::canShareStyleWithElement):
24854         (WebCore::StyleResolver::locateSharedStyle):
24855
24856 2012-11-02  Kentaro Hara  <haraken@chromium.org>
24857
24858         [V8] Add ASSERT() to guarantee that we don't store NULL pointers to V8 internal fields
24859         https://bugs.webkit.org/show_bug.cgi?id=101054
24860
24861         Reviewed by Adam Barth.
24862
24863         I'm investigating a Chromium crash bug:
24864         http://code.google.com/p/chromium/issues/detail?id=155942
24865
24866         I've not yet identified the root cause (because I can't reproduce
24867         the crash), but it looks like we are storing NULL pointers to
24868         V8 internal fields. Just in case, we can add an ASSERT() to
24869         guarantee that NULL pointers are never stored. (Also I'm hoping
24870         that this ASSERT() will give me more debug information.)
24871
24872         No tests. No change in behavior.
24873
24874         * bindings/v8/V8DOMWrapper.h:
24875         (WebCore::V8DOMWrapper::setDOMWrapper):
24876
24877 2012-11-02  Kevin Ellis  <kevers@chromium.org>
24878
24879         Imrpove scoring in touch adjustment to address bias towards smaller targets.
24880         https://bugs.webkit.org/show_bug.cgi?id=101046
24881
24882         Reviewed by Antonio Gomes.
24883
24884         Update the touch overlap score for touch adjustmetn to normalize
24885         with respect to the maximum possible overlap rather than the size
24886         of the target element.  This change enables good overlap scores for
24887         small and large targets alike.  Prior to the patch it was not possible
24888         to get a good overlap score for a sufficiently larget target.
24889
24890         Covered by existing tests, which have been updated to reflect the
24891         intended behavior.
24892
24893         * page/TouchAdjustment.cpp:
24894         (WebCore::TouchAdjustment::hybridDistanceFunction):
24895
24896 2012-11-02  Mike West  <mkwst@chromium.org>
24897
24898         Web Inspector: Repeated errors are rendered incorrectly: link is not floating to the right.
24899         https://bugs.webkit.org/show_bug.cgi?id=101032
24900
24901         Reviewed by Yury Semikhatsky.
24902
24903         https://bugs.webkit.org/show_bug.cgi?id=100525 incorrectly added
24904         '-webkit-flex: 1' only to the list generated for errors in the console.
24905         It should have been added to normal warning text as well. This patch
24906         fixes the problem.
24907
24908         * inspector/front-end/inspector.css:
24909         (.repeated-message .outline-disclosure, .repeated-message > .console-message-text):
24910
24911 2012-11-02  Eugene Klyuchnikov  <eustas.bug@gmail.com>
24912
24913         Web Inspector: Timeline: show popup for CPU bars.
24914         https://bugs.webkit.org/show_bug.cgi?id=100951
24915
24916         Reviewed by Pavel Feldman.
24917
24918         Each CPU bar can represent a combination of several shorter messages.
24919         We should show information about combined messages - start time,
24920         total duration, CPU time, message count.
24921
24922         * English.lproj/localizedStrings.js: Added "Message Count" string.
24923         * inspector/front-end/TimelinePanel.js:
24924         (WebInspector.TimelinePanel.prototype._refreshMainThreadBars):
24925         Supply elements with underlying info.
24926         * inspector/front-end/TimelinePresentationModel.js:
24927         (WebInspector.TimelinePresentationModel.prototype.generateMainThreadBarPopupContent):
24928         Added.
24929
24930 2012-11-02  Alexei Filippov  <alph@chromium.org>
24931
24932         Web Inspector: Network panel grid UI is misaligned after r132888
24933         https://bugs.webkit.org/show_bug.cgi?id=101050
24934
24935         Rollback the change to basic data grid css and move it to the native memory
24936         snapshot datagrid css.
24937
24938         Reviewed by Alexander Pavlov.
24939
24940         * inspector/front-end/dataGrid.css:
24941         (.data-grid td):
24942         * inspector/front-end/nativeMemoryProfiler.css:
24943         (.native-snapshot-view .data-grid td):
24944
24945 2012-11-02  Sheriff Bot  <webkit.review.bot@gmail.com>
24946
24947         Unreviewed, rolling out r133303.
24948         http://trac.webkit.org/changeset/133303
24949         https://bugs.webkit.org/show_bug.cgi?id=101068
24950
24951         "Broke qt wk2 build (seems like bots fails to rerun qmake if
24952         needed)" (Requested by kbalazs on #webkit).
24953
24954         * Target.pri:
24955         * WebCore.pri:
24956         * platform/PlatformStrategies.cpp:
24957         (WebCore):
24958         * platform/qt/QtTestSupport.h: Removed.
24959
24960 2012-11-02  Balazs Kelemen  <kbalazs@webkit.org>
24961
24962         [Qt][WK2] setPlatformStrategies always asserts after r132744
24963         https://bugs.webkit.org/show_bug.cgi?id=100838
24964
24965         Reviewed by Simon Hausmann.
24966
24967         The problem here is that we use QWebSettings::clearMemoryCaches, a WebKit1 API
24968         from the injected bundle, which calls initializeWebCoreQt and it sets the platform
24969         strategies to the one for WebKit1. We should stop using WebKit1 API's from WebKit2
24970         code. In order to keep the behavior, this patch adds exported helpers to WebCore
24971         that can be used from DumpRenderTree and WebKitTestRunner. This is the same idea
24972         as WebCoreTestSupport but these helpers are specific to Qt. Technically we could
24973         add it to the WebKit1 API for the time being, but my goal was to move in the direction
24974         of removing the WebKit1 dependency from WebKitTestRunner. We only build the file
24975         in non production mode.
24976
24977         Basically covered by all tests.
24978
24979         * Target.pri:
24980         * WebCore.pri: We need to link against fontconfig (only in non-production mode) since
24981         initializeTestFonts uses it.
24982         * platform/PlatformStrategies.cpp:
24983         (WebCore): Zero initialize the global static variable as it is expected by the functions
24984         below. It is a side fix. It seems like it has not been shown on debug WebKit2 bots because
24985         common runtime environments tend to zero initialize statics by default - but I don't think
24986         we should rely on that.
24987         * platform/qt/QtTestSupport.cpp: Added. I choose GPL license because code from qwebsettings.cpp
24988         is also under that.
24989         (WebKit):
24990         (WebKit::QtTestSupport::clearMemoryCaches): This is basically a copy of QWebSettings::clearMemoryCaches
24991         without calling initializeWebCoreQt.
24992         (WebKit::QtTestSupport::initializeTestFonts): I moved this code here as well now that we have to expose
24993         symbols from WebCore anyway. The advantage is that now we don't have to build it twice and we don't need
24994         additional files to forward it from the directory of DumpRenderTree for WebKitTestRunner.
24995         I added a call to FontCace::invalidate in the case when the font set has been changed so that it will do
24996         the job even if we would stop clearing all caches between tests. Also moved the call to
24997         QFontDatabase::removeAllApplicationFonts from callers to here.
24998         * platform/qt/QtTestSupport.h:
24999         (WebKit):
25000         (QtTestSupport):
25001
25002 2012-11-02  Kent Tamura  <tkent@chromium.org>
25003
25004         Optimize DateTimeFormat::quoteAndAppendLiteral output
25005         https://bugs.webkit.org/show_bug.cgi?id=101040
25006
25007         Reviewed by Kentaro Hara.
25008
25009         In LDML date format pattern, only ASCII alphabet and quote have special
25010         roles. So we don't need to quote the input string if it doesn't contain
25011         them.
25012
25013         No new tests. Updated WebKit/chromium/tests/LocaleWinTest.cpp
25014
25015         * platform/text/DateTimeFormat.cpp:
25016         (WebCore::isASCIIAlphabetOrQuote): A helper to check special characters.
25017         (WebCore::DateTimeFormat::quoteAndAppendLiteral):
25018         Append the input string as is if it has no special character.
25019
25020 2012-11-02  Ilya Tikhonovsky  <loislo@chromium.org>
25021
25022         Web Inspector: NMI instrument NodeRareData::Map. It uses ~250k on nytimes.com
25023         https://bugs.webkit.org/show_bug.cgi?id=101052
25024
25025         Reviewed by Yury Semikhatsky.
25026
25027         I noticed that in many cases cache structures are plain static HashMap, HashSet etc.
25028         MemoryAgent can visit it but instrumentation for these containers report no objectType.
25029         It means that addRootObject method needs to accept objectType property as an argument.
25030         Otherwise I would have had to create a proxy class with proper objectType.
25031
25032         * dom/WebCoreMemoryInstrumentation.cpp:
25033         (WebCore::WebCoreMemoryInstrumentation::reportMemoryUsage):
25034         (WebCore):
25035         * dom/WebCoreMemoryInstrumentation.h:
25036         (WebCoreMemoryInstrumentation):
25037         (WebCore):
25038         * inspector/InspectorMemoryAgent.cpp:
25039         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
25040
25041 2012-11-02  Michael Brüning  <michael.bruning@digia.com>
25042
25043         [Qt][WK2] ASSERT hit for every mouse click
25044         https://bugs.webkit.org/show_bug.cgi?id=100607
25045
25046         Reviewed by Jocelyn Turcotte.
25047
25048         Changed the logic of absolutePathForRenderer to use the first highlight box as the mid box 
25049         by uniting the two in case the mid box is empty. This allows the first box to be merged with
25050         the last box should they intersect, and thereby prevents an ASSERT in addHighlightRect that is
25051         triggered by two intersecting boxes being passed to addHighlightRect as separate ones.
25052
25053         Also, this patch removes some superfluous checks for LayoutRect::isEmpty, which is being checked
25054         in LayoutRect::intersects already.
25055
25056         No new tests, but added manual test: ManualTests/tap-gesture-on-em-link-tap-highlight-assert.html
25057
25058         * page/GestureTapHighlighter.cpp:
25059
25060 2012-11-02  Arpita Bahuguna  <arpitabahuguna@gmail.com>
25061
25062         Regression r130057: Improper preferred width calculation when an inline replaced object, wrapped in an inline flow, follows some text.
25063         https://bugs.webkit.org/show_bug.cgi?id=99442
25064
25065         Reviewed by Levi Weintraub.
25066
25067         Extra width is displayed after an inline replaced object that follows some
25068         text (not ending in a whitespace) within an inline-block. This is due to
25069         the end width (endMin) of the text object being carried forward (via inlineMin)
25070         and added onto the next line containing the inline replaced object.
25071
25072         This was caused as a regression to, or rather became apparent post the fix
25073         http://trac.webkit.org/changeset/130057 which fixed the block's preferred
25074         width when a renderInline with width contained an inline replaced object.
25075
25076         Test: fast/block/block-with-inline-replaced-child-following-text.html
25077
25078         * rendering/RenderBlock.cpp:
25079         (WebCore::RenderBlock::computeInlinePreferredLogicalWidths):
25080         Introduced another flag (shouldBreakLineAfterText) which is set when
25081         our current Text line (object) does not end in a whitespace, thereby
25082         implying that there could be more text following, for which the end width
25083         needs to be carried forward onto the next line.
25084
25085         In case the following object instead turns out to be an Inline Replaced
25086         object, we should terminate our previous line and reset this extra width.
25087         This is now being handled by checking for the shouldBreakLineAfterText
25088         flag while processing Inline Replaced objects.
25089
25090         Once set, shouldBreakLineAfterText shall be reset only if we get another
25091         Text object that ends in a whitespace, signifying the termination of
25092         that text line. For all other cases, we persist with this flag through
25093         the block's inline contents.
25094
25095 2012-11-02  Eugene Klyuchnikov  <eustas.bug@gmail.com>
25096
25097         Web Inspector: Console: remove obsolete ctrl-shift-m shortcut
25098         https://bugs.webkit.org/show_bug.cgi?id=101036
25099
25100         Reviewed by Pavel Feldman.
25101
25102         Ctrl-shift-m on console dumps MemoryAgent.getDOMNodeCount
25103         This functionality seems to be obsolete.
25104
25105         * inspector/front-end/ConsoleView.js: Removed shortcut and function.
25106
25107 2012-11-02  Stephen Chenney  <schenney@chromium.org>
25108
25109         SVG classes cause layering violations in platform Font code
25110         https://bugs.webkit.org/show_bug.cgi?id=98513
25111
25112         Reviewed by Eric Seidel.
25113
25114         Add a contained class to save and restore GlpyhPage state in FontFallbackList.
25115         This allows us to remove the layering violation, and several methods, that
25116         previously existed to support SVGTextRunRenderingContext.
25117
25118         No new tests because no change at all in functionality.
25119
25120         * platform/graphics/FontFallbackList.h:
25121         (FontFallbackList):
25122         (GlyphPagesStateSaver): New state save and restore class
25123         (WebCore::FontFallbackList::GlyphPagesStateSaver::GlyphPagesStateSaver): Save GlyphPage state
25124         (WebCore::FontFallbackList::GlyphPagesStateSaver::~GlyphPagesStateSaver): Restore GlyphPage state
25125         * rendering/svg/SVGTextRunRenderingContext.cpp:
25126         (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter): Shift to usage of the new class.
25127
25128 2012-11-02  Vsevolod Vlasov  <vsevik@chromium.org>
25129
25130         Web Inspector: Fix compilation errors
25131         https://bugs.webkit.org/show_bug.cgi?id=101027
25132
25133         Reviewed by Yury Semikhatsky.
25134
25135         * inspector/InjectedScriptSource.js:
25136         (.):
25137         * inspector/front-end/NativeMemorySnapshotView.js:
25138         (WebInspector.NativeSnapshotNode.prototype._createSizeCell):
25139
25140 2012-11-02  Andreas Kling  <kling@webkit.org>
25141
25142         Only resolve attribute-derived style once per shared ElementAttributeData.
25143         <http://webkit.org/b/100990>
25144
25145         Reviewed by Antti Koivisto.
25146
25147         Track the serialization of the "style" attribute, and the dirtiness of the presentation attribute style
25148         on ElementAttributeData instead of in Node flags.
25149
25150         This allows us to avoid duplicate work for ElementAttributeData that are shared between multiple elements,
25151         since the state is no longer per-Element.
25152
25153         I've left the presentation attribute cache in there for now, since it covers two additional cases:
25154
25155             - Elements with the same attributes in different order.
25156             - Elements with the same presentation attributes, but with differing non-presentation attributes.
25157
25158         It's likely that we're not gaining much from it anymore, but that's a topic for another patch.
25159
25160         * dom/Node.h:
25161         * dom/ElementAttributeData.h:
25162         (WebCore::ElementAttributeData::presentationAttributeStyle):
25163         (WebCore::ElementAttributeData::setPresentationAttributeStyle):
25164         (WebCore::ElementAttributeData::styleAttributeIsDirty):
25165         (WebCore::ElementAttributeData::setStyleAttributeIsDirty):
25166         (WebCore::ElementAttributeData::presentationAttributeStyleIsDirty):
25167         (WebCore::ElementAttributeData::setPresentationAttributeStyleIsDirty):
25168         (ElementAttributeData):
25169         (WebCore::ElementAttributeData::ElementAttributeData):
25170         * dom/Element.cpp:
25171         (WebCore::Element::getAttribute):
25172         * dom/Element.h:
25173         (WebCore::Element::styleAttributeIsDirty):
25174         (WebCore::Element::updateInvalidAttributes):
25175         * dom/StyledElement.cpp:
25176         (WebCore::StyledElement::updateStyleAttribute):
25177         (WebCore::StyledElement::attributeChanged):
25178         (WebCore::StyledElement::styleAttributeChanged):
25179         (WebCore::StyledElement::inlineStyleChanged):
25180         * dom/StyledElement.h:
25181         (WebCore::StyledElement::invalidateStyleAttribute):
25182
25183             Move the "attribute style dirty" and "style attribute valid" node flags to ElementAttributeData
25184             and change them to both use dirty semantics.
25185
25186         * dom/ElementAttributeData.cpp:
25187         (WebCore::ElementAttributeData::cloneDataFrom):
25188
25189             Share the presentation attribute style between cloned elements initially.
25190
25191         * dom/StyledElement.h:
25192         (WebCore::StyledElement::presentationAttributeStyle):
25193         * css/StyleResolver.cpp:
25194         (WebCore::StyleResolver::sweepMatchedPropertiesCache):
25195         (WebCore::StyleResolver::matchAllRules):
25196         (WebCore::StyleResolver::canShareStyleWithElement):
25197         * dom/ElementAttributeData.cpp:
25198         (WebCore::MutableElementAttributeData::MutableElementAttributeData):
25199         (WebCore::ElementAttributeData::reportMemoryUsage):
25200         * inspector/InspectorCSSAgent.cpp:
25201         (WebCore::InspectorCSSAgent::buildObjectForAttributesStyle):
25202
25203             Renamed StyledElement::attributeStyle() to presentationAttributeStyle(). The old name was too
25204             easily confused with "style attribute".
25205
25206         * dom/StyledElement.cpp:
25207         (WebCore::StyledElement::rebuildPresentationAttributeStyle):
25208
25209             Renamed from updateAttributeStyle().
25210
25211 2012-11-01  Kent Tamura  <tkent@chromium.org>
25212
25213         Introduce ENABLE_DATE_AND_TIME_INPUT_TYPES, and clarify usage of other related flags
25214         https://bugs.webkit.org/show_bug.cgi?id=101007
25215
25216         Reviewed by Kentaro Hara.
25217
25218         ChromeClient::openDateTimeChooser and Locale::formatDateTime are
25219         necessary if one of date/time input types is enabled and even if
25220         ENABLE_INPUT_MULTIPLE_FIELDS_UI is disabled. So they should be wrapped
25221         with ENABLE(DATE_AND_TIME_INPUT_TYPES).
25222
25223         The following clases are used only for ChromeClient::openDateTimeChooser.
25224         They should be wrapped with the same flag.
25225           - class DateTimeChooser
25226           - class DateTiemChooserClient
25227
25228         The following classes/functions are used for
25229         Locale::formatDateTime. They should be wrapped with the same flag.
25230           - Locale::dateFormat
25231           - Locale::monthFormat
25232           - Locale::timeFormat
25233           - Locale::shortTimeFormat
25234           - Locale::monthLabels
25235           - Locale::shortMonthLabels
25236           - Locale::standAloneMonthLabels
25237           - Locale::shortStandAloneMonthLabels
25238           - class DateTimeFormat
25239
25240         Also, we change the meaning of ENABLE_CALENDAR_PICKER. It meant
25241          1) <input> supports calendar picker UI, and
25242          2) WebCore/Resources/pagepopups/ is used for the calendar UI implementation.
25243         Now ENABLE_CALENDAR_PICKER means only 2.
25244
25245         No new tests because of no behavior changes.
25246
25247         * html/BaseDateAndTimeInputType.h: This is necessary only if date/time
25248         input types are enabled because this is a common super class of
25249         date/time InputType classes.
25250         * html/BaseDateAndTimeInputType.cpp: Ditto.
25251         * html/BaseChooserOnlyDateAndTimeInputType.cpp: Ditto.
25252         * html/BaseChooserOnlyDateAndTimeInputType.h: Ditto.
25253
25254         * page/ChromeClient.h: Change the flag for openDateTimeChooser, and add a comment.
25255         * loader/EmptyClients.cpp: Follow the openDateTimeChooser flag change.
25256         * loader/EmptyClients.h: Ditto.
25257         * platform/DateTimeChooser.h:
25258         This is needed only if ChromeClient::openDateTimeChooser is available.
25259         * platform/DateTimeChooserClient.h: Ditto.
25260
25261         * platform/LocalizedStrings.h:
25262         weekFormatInLDML is necessary if ENABLE(INPUT_TYPE_WEEK) regardless of
25263         ENABLE(INPUT_MULTIPLE_FIELDS_UI).
25264
25265         * platform/text/PlatformLocale.h:
25266         Change the condition for Locale::formatDateTime and the code used by
25267         Locale::formatDateTime.
25268         * platform/text/PlatformLocale.cpp:
25269         (WebCore::Locale::formatDateTime):
25270         This is necessary even if !ENABLE(INPUT_MULTIPLE_FIELDS_UI), to produce
25271         localized representations of date/time values.
25272         * platform/text/LocaleICU.cpp:
25273         Change the condition for the code used by Locale::formatDateTime.
25274         * platform/text/LocaleICU.h: Ditto.
25275         * platform/text/LocaleNone.cpp: Ditto.
25276         * platform/text/mac/LocaleMac.h: Ditto.
25277         * platform/text/mac/LocaleMac.mm: Ditto.
25278         * platform/text/win/LocaleWin.cpp: Ditto.
25279         * platform/text/win/LocaleWin.h: Ditto.
25280         * platform/text/DateTimeFormat.cpp: Ditto.
25281         * platform/text/DateTimeFormat.h: Ditto.
25282
25283         * html/BaseMultipleFieldsDateAndTimeInputType.h:
25284         Remove some #if-#endif for a picker indicator element because
25285         ENABLE_CALENDAR_PICKER meaning is changed.
25286         * html/BaseMultipleFieldsDateAndTimeInputType.cpp: Ditto.
25287
25288         * html/shadow/PickerIndicatorElement.cpp: CALENDAR_PICKER ->
25289         INPUT_MULTIPLE_FIELDS_UI because ENABLE_CALENDAR_PICKER meaning is changed.
25290         * html/shadow/PickerIndicatorElement.h: Ditto.
25291         * rendering/RenderDetailsMarker.cpp: Ditto.
25292         * rendering/RenderDetailsMarker.h: Ditto.
25293         * rendering/RenderTheme.h: Ditto.
25294         * rendering/RenderThemeChromiumCommon.cpp: Ditto.
25295         * rendering/RenderThemeChromiumCommon.h: Ditto.
25296         * rendering/RenderThemeChromiumMac.h: Ditto.
25297         * rendering/RenderThemeChromiumSkia.h: Ditto.
25298
25299 2012-11-02  Zeno Albisser  <zeno@webkit.org>
25300
25301         [Qt] Revert QCocoaNativeInterface workaround from r131720.
25302         https://bugs.webkit.org/show_bug.cgi?id=100842
25303
25304         Reviewed by Simon Hausmann.
25305
25306         After updating Qt5 on the buildbots, the workaround
25307         introduced in r131720 is not needed anymore.
25308
25309         * platform/graphics/surfaces/mac/GraphicsSurfaceMac.cpp:
25310         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
25311
25312 2012-11-02  Kent Tamura  <tkent@chromium.org>
25313
25314         Add a common base class for date/time input types without inline editing behavior
25315         https://bugs.webkit.org/show_bug.cgi?id=101031
25316
25317         Reviewed by Hajime Morita.
25318
25319         Add BaseChooserOnlyDateAndTimeInputType class, which will support
25320         DateTimeChooserClient, and date/time input types inherit it if
25321         !ENABLE(INPUT_MULTIPLE_FIELDS_UI).
25322
25323         No new tests. This doesn't change any behavior.
25324
25325         * CMakeLists.txt: Add BaseChooserOnlyDateAndTimeInputType.{cpp,h}.
25326         * GNUmakefile.list.am: Ditto.
25327         * Target.pri: Ditto.
25328         * WebCore.gypi: Ditto.
25329         * WebCore.xcodeproj/project.pbxproj: Ditto.
25330         * html/BaseChooserOnlyDateAndTimeInputType.cpp: Added.
25331         * html/BaseChooserOnlyDateAndTimeInputType.h: Added.
25332
25333         * html/DateInputType.h: Inherit BaseChooserOnlyDateAndTimeInputType if
25334         !ENABLE(INPUT_MULTIPLE_FIELDS_UI).
25335         * html/DateTimeInputType.h: Ditto.
25336         * html/DateTimeLocalInputType.h: Ditto.
25337         * html/MonthInputType.h: Ditto.
25338         * html/TimeInputType.h: Ditto.
25339         * html/WeekInputType.h: Ditto.
25340
25341 2012-11-02  Peter Wang  <peter.wang@torchmobile.com.cn>
25342
25343         Web Inspector: [JSC] implement WorkerScriptDebugServer
25344         https://bugs.webkit.org/show_bug.cgi?id=99801
25345
25346         Reviewed by Yury Semikhatsky.
25347
25348         To implement Worker Inspector for JSC.
25349         The virtual function "runEventLoopWhilePaused" is defined, since there are different ways to block
25350         the JS running in worker-context and normal page-context.
25351         The function "isContentScript" now is virtual because the original invoked functions are useless
25352         and cause problem in worker-context.
25353         In function "WebCore::WorkerScriptController::attachDebugger", we invoke "initScriptIfNeeded" to
25354         ensure the JSGloblalObject exist in the case of attaching Debugger before executing the worker
25355         JS code (Pause on start).
25356
25357         No new test case.
25358
25359         * bindings/js/PageScriptDebugServer.cpp:
25360         (WebCore::PageScriptDebugServer::runEventLoopWhilePaused):
25361         (WebCore):
25362         * bindings/js/PageScriptDebugServer.h:
25363         (PageScriptDebugServer):
25364         * bindings/js/ScriptDebugServer.cpp:
25365         (WebCore::ScriptDebugServer::isContentScript):
25366         (WebCore::ScriptDebugServer::pauseIfNeeded):
25367         * bindings/js/ScriptDebugServer.h:
25368         (JSC):
25369         (ScriptDebugServer):
25370         * bindings/js/WorkerScriptController.cpp:
25371         (WebCore::WorkerScriptController::attachDebugger):
25372         (WebCore):
25373         (WebCore::WorkerScriptController::detachDebugger):
25374         * bindings/js/WorkerScriptController.h:
25375         (WorkerScriptController):
25376         * bindings/js/WorkerScriptDebugServer.cpp:
25377         (WebCore::WorkerScriptDebugServer::WorkerScriptDebugServer):
25378         (WebCore):
25379         (WebCore::WorkerScriptDebugServer::addListener):
25380         (WebCore::WorkerScriptDebugServer::recompileAllJSFunctions):
25381         (WebCore::WorkerScriptDebugServer::removeListener):
25382         (WebCore::WorkerScriptDebugServer::runEventLoopWhilePaused):
25383         * bindings/js/WorkerScriptDebugServer.h:
25384         (WorkerScriptDebugServer):
25385         (WebCore::WorkerScriptDebugServer::getListenersForGlobalObject):
25386         (WebCore::WorkerScriptDebugServer::isContentScript):
25387
25388 2012-11-02  KyungTae Kim  <ktf.kim@samsung.com>
25389
25390         Compilation warning in Node.cpp when USERSELECT_ALL is disabled
25391         https://bugs.webkit.org/show_bug.cgi?id=101025
25392
25393         Reviewed by Ryosuke Niwa.
25394
25395         The parameter 'treatment' is not used when USERSELECT_ALL is disabled. 
25396
25397         * dom/Node.cpp:
25398         (WebCore::Node::rendererIsEditable):
25399
25400 2012-11-01  Vsevolod Vlasov  <vsevik@chromium.org>
25401
25402         Web Inspector: Middle click closes an editor and pastes selection into current editor on Linux
25403         https://bugs.webkit.org/show_bug.cgi?id=100743
25404
25405         Reviewed by Alexander Pavlov.
25406
25407         Editor now consumes all middle mouse button mouse ups except for the ones in the main panel.
25408         TabbedPane now consumes all middle mouse button mouse ups as well.
25409         Navigator view does not pass focus anymore if element was selected with middle mouse button.
25410
25411         * inspector/front-end/DefaultTextEditor.js:
25412         (.preventDefaultOnMouseUp):
25413         (.consumeMouseUp):
25414         * inspector/front-end/NavigatorView.js:
25415         (WebInspector.NavigatorSourceTreeElement.prototype.ondblclick):
25416         * inspector/front-end/TabbedPane.js:
25417         (WebInspector.TabbedPane):
25418         (WebInspector.TabbedPane.prototype.onMouseUp):
25419         (WebInspector.TabbedPane.prototype.onMouseClick):
25420
25421 2012-11-01  Ilya Tikhonovsky  <loislo@chromium.org>
25422
25423         Web Inspector: NMI instrument ShadowRoot. It gives us ~400k on plus.google.com
25424         https://bugs.webkit.org/show_bug.cgi?id=100866
25425
25426         Reviewed by Yury Semikhatsky.
25427
25428         Plain vanilla memory instrumentation code for HTMLInputElement which has a ElementShadow.
25429
25430         * CMakeLists.txt:
25431         * GNUmakefile.list.am:
25432         * Target.pri:
25433         * WebCore.gypi:
25434         * WebCore.vcproj/WebCore.vcproj:
25435         * dom/DocumentOrderedMap.cpp:
25436         (WebCore::DocumentOrderedMap::reportMemoryUsage):
25437         (WebCore):
25438         * dom/DocumentOrderedMap.h:
25439         (DocumentOrderedMap):
25440         * dom/Element.cpp:
25441         (WebCore::Element::reportMemoryUsage):
25442         (WebCore):
25443         * dom/Element.h:
25444         * dom/ElementRareData.cpp: Added.
25445         (WebCore):
25446         (WebCore::ElementRareData::reportMemoryUsage):
25447         * dom/ElementRareData.h:
25448         (ElementRareData):
25449         * dom/ElementShadow.cpp:
25450         (WebCore::ElementShadow::reportMemoryUsage):
25451         (WebCore):
25452         * dom/ElementShadow.h:
25453         (ElementShadow):
25454         * dom/Node.cpp:
25455         (WebCore::Node::reportMemoryUsage):
25456         * dom/NodeRareData.cpp: Added.
25457         (WebCore):
25458         (WebCore::NodeListsNodeData::reportMemoryUsage):
25459         (WebCore::NodeRareData::reportMemoryUsage):
25460         * dom/NodeRareData.h:
25461         (NodeListsNodeData):
25462         (NodeRareData):
25463         * dom/ShadowRoot.cpp:
25464         (WebCore):
25465         (WebCore::ShadowRoot::reportMemoryUsage):
25466         * dom/ShadowRoot.h:
25467         (ShadowRoot):
25468         * dom/TreeScope.cpp:
25469         (WebCore::TreeScope::reportMemoryUsage):
25470         (WebCore):
25471         * dom/TreeScope.h:
25472         (TreeScope):
25473         * html/HTMLFormControlElement.cpp:
25474         (WebCore::HTMLFormControlElement::reportMemoryUsage):
25475         (WebCore):
25476         * html/HTMLFormControlElement.h:
25477         (HTMLFormControlElement):
25478         * html/HTMLInputElement.cpp:
25479         (WebCore::HTMLInputElement::reportMemoryUsage):
25480         (WebCore):
25481         * html/HTMLInputElement.h:
25482         (HTMLInputElement):
25483         * html/HTMLTextFormControlElement.cpp:
25484         (WebCore::HTMLTextFormControlElement::reportMemoryUsage):
25485         (WebCore):
25486         * html/HTMLTextFormControlElement.h:
25487         (HTMLTextFormControlElement):
25488
25489 2012-11-02  Vsevolod Vlasov  <vsevik@chromium.org>
25490
25491         Web Inspector: Cookie info in Network Resources Cookies tab shows "Invalid Date"
25492         https://bugs.webkit.org/show_bug.cgi?id=97471
25493
25494         Reviewed by Pavel Feldman.
25495
25496         This patch is partly based on patch by Otto Derek Cheung <otcheung@rim.com>.
25497         Refactored CookieParser so that all cookies in front-end were WebInspector.Cookie object.
25498         Cookie table can now show Max-Age as well as Expires attribute of a cookie.
25499         Fixed expiresDate calculation.
25500         Removed getters from CookieParser for better compilation.
25501
25502         * English.lproj/localizedStrings.js:
25503         * inspector/front-end/AuditRules.js:
25504         (WebInspector.AuditRules.CookieRuleBase.prototype.mapResourceCookies):
25505         (WebInspector.AuditRules.CookieSizeRule.prototype._average):
25506         (WebInspector.AuditRules.CookieSizeRule.prototype._max):
25507         (WebInspector.AuditRules.StaticCookielessRule.prototype._collectorCallback):
25508         * inspector/front-end/CookieItemsView.js:
25509         (WebInspector.CookieItemsView.prototype._filterCookiesForDomain):
25510         * inspector/front-end/CookieParser.js:
25511         (WebInspector.CookieParser.prototype.cookies):
25512         (WebInspector.CookieParser.prototype._flushCookie):
25513         (WebInspector.CookieParser.prototype._addCookie):
25514         (WebInspector.Cookie.prototype.httpOnly):
25515         (WebInspector.Cookie.prototype.secure):
25516         (WebInspector.Cookie.prototype.session):
25517         (WebInspector.Cookie.prototype.path):
25518         (WebInspector.Cookie.prototype.domain):
25519         (WebInspector.Cookie.prototype.expires):
25520         (WebInspector.Cookie.prototype.maxAge):
25521         (WebInspector.Cookie.prototype.size):
25522         (WebInspector.Cookie.prototype.setSize):
25523         (WebInspector.Cookie.prototype.expiresDate):
25524         (WebInspector.Cookie.prototype.attributes):
25525         (WebInspector.Cookies.getCookiesAsync):
25526         (WebInspector.Cookies.buildCookiesFromString):
25527         (WebInspector.Cookies.buildCookieProtocolObject):
25528         (WebInspector.Cookies.cookieMatchesResourceURL):
25529         (WebInspector.Cookies.cookieDomainMatchesResourceDomain):
25530         * inspector/front-end/CookiesTable.js:
25531         (WebInspector.CookiesTable):
25532         (WebInspector.CookiesTable.prototype._totalSize):
25533         (WebInspector.CookiesTable.prototype._sortCookies.expiresCompare):
25534         (WebInspector.CookiesTable.prototype._sortCookies):
25535         (WebInspector.CookiesTable.prototype._createGridNode):
25536         * inspector/front-end/HAREntry.js:
25537         (WebInspector.HAREntry.prototype._buildCookie):
25538
25539 2012-11-01  Yury Semikhatsky  <yurys@chromium.org>
25540
25541         Memory instrumentation: do not call checkCountedObject with wrong pointers
25542         https://bugs.webkit.org/show_bug.cgi?id=100958
25543
25544         Reviewed by Alexander Pavlov.
25545
25546         Removed redundant call to checkCountedObject.
25547
25548         * inspector/MemoryInstrumentationImpl.cpp:
25549         (WebCore::MemoryInstrumentationClientImpl::countObjectSize):
25550
25551 2012-11-02  Peter Wang  <peter.wang@torchmobile.com.cn>
25552
25553         Web Inspector: a small defect in "WorkersSidebarPanel.js"
25554         https://bugs.webkit.org/show_bug.cgi?id=101022
25555
25556         Reviewed by Yury Semikhatsky.
25557
25558         In "autoattachToWorkersClicked", the "event.target.checked" doesn't alwyas valid, since the
25559         "event.target" might be a label.
25560
25561         The problem just causes an error report, doesn't effect function, so no new test case.
25562
25563         * inspector/front-end/WorkersSidebarPane.js:
25564         (WebInspector.WorkersSidebarPane.prototype._autoattachToWorkersClicked):
25565
25566 2012-11-01  Shinya Kawanaka  <shinyak@chromium.org>
25567
25568         [Shadow] Element should have getter and setter of attribute 'pseudo'
25569         https://bugs.webkit.org/show_bug.cgi?id=100831
25570
25571         Reviewed by Hajime Morita.
25572
25573         We expose 'pseudo' attribute in Element. When nothing is assigned to 'pseudo', it should return null.
25574
25575         Test: fast/dom/shadow/pseudo-attribute.html
25576
25577         * dom/Element.cpp:
25578         (WebCore::Element::pseudo):
25579         (WebCore):
25580         (WebCore::Element::setPseudo):
25581         * dom/Element.h:
25582         (Element):
25583         * dom/Element.idl:
25584         * html/HTMLAttributeNames.in:
25585
25586 2012-11-01  Roger Fong  <roger_fong@apple.com>
25587
25588         Build fix. http://trac.webkit.org/changeset/133252 broke the Windows build.
25589         https://bugs.webkit.org/show_bug.cgi?id=101008
25590
25591         Reviewed by fischman@chromium.org.
25592
25593         * html/HTMLMediaElement.cpp:
25594         (WebCore::HTMLMediaElement::clearMediaPlayer):
25595         * html/HTMLMediaElement.h:
25596         (HTMLMediaElement):
25597
25598 2012-11-01  Stephen White  <senorblanco@chromium.org>
25599
25600         Unreviewed, rolling out r133244.
25601         http://trac.webkit.org/changeset/133244
25602         https://bugs.webkit.org/show_bug.cgi?id=100973
25603
25604         Broke Chromium Mac (clang) builds.
25605
25606         * bindings/v8/DOMDataStore.cpp:
25607         (WebCore::DOMDataStore::DOMDataStore):
25608         * bindings/v8/IntrusiveDOMWrapperMap.h:
25609         (WebCore::DOMNodeWrapperMap::weakCallback):
25610
25611 2012-11-01  Ami Fischman  <fischman@chromium.org>
25612
25613         HTMLMediaPlayer should free m_player when src is set/changed
25614         https://bugs.webkit.org/show_bug.cgi?id=99647
25615
25616         Reviewed by Eric Carlson.
25617
25618         New ManualTest added; manual since leaking media players doesn't have layoutTestController-visible effects.
25619
25620         * html/HTMLMediaElement.cpp:
25621         (WebCore::HTMLMediaElement::parseAttribute): clearMediaPlayer() when src is set/changed
25622         (WebCore::HTMLMediaElement::userCancelledLoad): use new clearMediaPlayer() helper
25623         (WebCore::HTMLMediaElement::clearMediaPlayer): clear m_player and associated timers/flags
25624         (WebCore):
25625         (WebCore::HTMLMediaElement::createMediaPlayer): whitespace-only change
25626         * html/HTMLMediaElement.h: new method: createMediaPlayer().
25627         (HTMLMediaElement):
25628
25629 2012-11-01  Tom Sepez  <tsepez@chromium.org>
25630
25631         XSS blocker false positive when page contains <iframe src="">
25632         https://bugs.webkit.org/show_bug.cgi?id=93416
25633
25634         Reviewed by Adam Barth.
25635
25636         Treat src="" and src="about:blank" as safe resources even if they appear
25637         in the query parameters.
25638
25639         Tests: http/tests/security/xssAuditor/iframe-injection-allowed-2.html
25640                http/tests/security/xssAuditor/iframe-injection-allowed-3.html
25641                http/tests/security/xssAuditor/iframe-injection-allowed.html
25642
25643         * html/parser/XSSAuditor.cpp:
25644         (WebCore::XSSAuditor::isLikelySafeResource):
25645
25646 2012-11-01  Tien-Ren Chen  <trchen@chromium.org>
25647
25648         Fix assertion failure in RenderGeometryMap::absoluteRect when frame scale != 1.0
25649         https://bugs.webkit.org/show_bug.cgi?id=100912
25650
25651         Reviewed by Simon Fraser.
25652
25653         Frame scale will add transformation to RenderView, so fixed position doesn't
25654         get propagated up to the viewport by RenderGeometryMap. This is handled
25655         correctly in RenderView::mapLocalToContainer, causing the assertion to fail.
25656         This patch corrects RenderGeometryMap::mapToAbsolute to handle the RenderView
25657         transformation case.
25658
25659         A layout test is added to catch this issue. The test will crash debug build
25660         without this patch.
25661
25662         Test: compositing/geometry/fixed-position-composited-page-scale-scroll.html
25663
25664         * rendering/RenderGeometryMap.cpp:
25665         (WebCore::RenderGeometryMap::mapToAbsolute):
25666
25667 2012-11-01  Adam Barth  <abarth@webkit.org>
25668
25669         [V8] Generalize NodeWrapperMap to be able to handle other sorts of keys
25670         https://bugs.webkit.org/show_bug.cgi?id=100973
25671
25672         Reviewed by Kentaro Hara.
25673
25674         This is the first step towards using intrusive DOM wrapper maps more
25675         widely in WebCore (see
25676         http://lists.webkit.org/pipermail/webkit-dev/2012-November/022686.html
25677         for more context).
25678
25679         * bindings/v8/DOMDataStore.cpp:
25680         (WebCore::DOMDataStore::DOMDataStore):
25681         * bindings/v8/IntrusiveDOMWrapperMap.h:
25682         (WebCore):
25683         (WebCore::IntrusiveDOMWrapperMap::weakCallback):
25684
25685 2012-11-01  Alexandru Chiculita  <achicu@adobe.com>
25686
25687         [CSS Shaders] CustomFilterOperation should be converted to ValidatedCustomFilterOperation before using it
25688         https://bugs.webkit.org/show_bug.cgi?id=100533
25689
25690         Reviewed by Dean Jackson.
25691
25692         Added the code that converts a CustomFilterOperation to a ValidatedCustomFilterOperation.
25693         Both the software path and the composited one will use this operation instead. There will be
25694         no need to check the shader in platform code anymore.
25695
25696         No new tests, already covered by existing custom filter tests.
25697
25698         * platform/graphics/filters/ValidatedCustomFilterOperation.cpp:
25699         (WebCore::ValidatedCustomFilterOperation::ValidatedCustomFilterOperation):
25700         * platform/graphics/filters/ValidatedCustomFilterOperation.h:
25701         (WebCore):
25702         (WebCore::ValidatedCustomFilterOperation::create):
25703         (ValidatedCustomFilterOperation):
25704         (WebCore::ValidatedCustomFilterOperation::validatedProgram):
25705         (WebCore::ValidatedCustomFilterOperation::parameters):
25706         (WebCore::ValidatedCustomFilterOperation::meshRows):
25707         (WebCore::ValidatedCustomFilterOperation::meshColumns):
25708         (WebCore::ValidatedCustomFilterOperation::meshType):
25709         (WebCore::ValidatedCustomFilterOperation::operator==):
25710         * rendering/FilterEffectRenderer.cpp:
25711         (WebCore::createCustomFilterEffect):
25712         (WebCore::FilterEffectRenderer::build):
25713         * rendering/RenderLayer.cpp:
25714         (WebCore::RenderLayer::ensureBacking):
25715         (WebCore::RenderLayer::clearBacking):
25716         (WebCore::RenderLayer::styleChanged): updateOrRemoveFilterClients needs to be called before the composited
25717         layer is updated. Otherwise the composited layer will never see a loaded filter in the first call.
25718         (WebCore):
25719         (WebCore::RenderLayer::isCSSCustomFilterEnabled):
25720         (WebCore::RenderLayer::computeFilterOperations):
25721         (WebCore::RenderLayer::updateOrRemoveFilterClients): Split updateOrRemoveFilterEffect into 2 functions.
25722         This one is supposed to add the clients needed to load network resources.
25723         (WebCore::RenderLayer::updateOrRemoveFilterEffectRenderer): Figures out if a software fallback is needed 
25724         and creates a FilterEffectRenderer.
25725         * rendering/RenderLayer.h:
25726         (RenderLayer):
25727
25728 2012-11-01  Max Vujovic  <mvujovic@adobe.com>
25729
25730         [CSS Shaders] Get rid of internal tex coord attribute
25731         https://bugs.webkit.org/show_bug.cgi?id=94358
25732
25733         Reviewed by Dean Jackson.
25734
25735         Remove the internal css_a_texCoord attribute that WebKit added to shaders in order to
25736         sample the element texture by texture coordinate.
25737
25738         Now, the WebKit-added sampling code can leverage a_texCoord if the author defined it, or
25739         WebKit can add its own a_texCoord definition to the author's shader.
25740
25741         Note that vertex attributes are read-only in GLSL. Also, note that we already reject the
25742         shader if the author did not define a_texCoord with the correct type. Essentially, if
25743         a_texCoord exists in the author's validated shader, we are guaranteed that it's the correct
25744         type and that its value is unmodified.
25745
25746         Test: css3/filters/custom/custom-filter-a-tex-coord-optional.html
25747
25748         * platform/graphics/filters/CustomFilterCompiledProgram.cpp:
25749         (WebCore::CustomFilterCompiledProgram::CustomFilterCompiledProgram):
25750             Remove the references to m_internalTexCoordAttribLocation.
25751         (WebCore::CustomFilterCompiledProgram::initializeParameterLocations): Ditto.
25752         * platform/graphics/filters/CustomFilterCompiledProgram.h: Ditto.
25753         * platform/graphics/filters/CustomFilterRenderer.cpp:
25754         (WebCore::CustomFilterRenderer::bindProgramAndBuffers): Ditto.
25755         (WebCore::CustomFilterRenderer::unbindVertexAttributes): Ditto.
25756         * platform/graphics/filters/CustomFilterValidatedProgram.cpp:
25757         (WebCore::CustomFilterValidatedProgram::CustomFilterValidatedProgram):
25758             Pass the set of symbols found in the author's shaders to the rewriteMixVertexShader
25759             method.
25760         (WebCore::CustomFilterValidatedProgram::rewriteMixVertexShader):
25761             If the author didn't define a_texCoord, add it to the end of the author's vertex 
25762             shader, but before the shader's new main function. As before, the new main function
25763             will pass the texture coordinate to the fragment shader via the css_v_texCoord varying.
25764         * platform/graphics/filters/CustomFilterValidatedProgram.h:
25765         (WebCore):
25766             Add a forward declaration for ANGLEShaderSymbol.
25767         (CustomFilterValidatedProgram):
25768             Update the method prototype for rewriteMixVertexShader.
25769
25770 2012-11-01  Chris Rogers  <crogers@google.com>
25771
25772         Ensure that AudioNode deletion is synchronized with a stable state of the rendering graph
25773         https://bugs.webkit.org/show_bug.cgi?id=100994
25774
25775         Reviewed by Kenneth Russell.
25776
25777         In some rare cases it has been observed that nodes are getting deleted in the main thread
25778         during an audio rendering quantum where the dirty inputs and outputs have not yet been cleaned
25779         via calls to handleDirtyAudioSummingJunctions() and handleDirtyAudioNodeOutputs().
25780         This was possible because nodes marked for deletion with markForDeletion() could be picked
25781         up in a subsequent call to deleteMarkedNodes() before the render quantum has finished and
25782         handlePostRenderTasks() has had a chance to reconcile these marked nodes and clean the dirty state.
25783         The solution is to manage the marked nodes in a separate vector which only gets copied to another
25784         vector truly eligible for deletion which is synchronized in handlePostRenderTasks().
25785
25786         * Modules/webaudio/AudioContext.cpp:
25787         (WebCore::AudioContext::markForDeletion):
25788         (WebCore::AudioContext::scheduleNodeDeletion):
25789         (WebCore::AudioContext::deleteMarkedNodes):
25790         * Modules/webaudio/AudioContext.h:
25791         (AudioContext):
25792
25793 2012-11-01  Ryosuke Niwa  <rniwa@webkit.org>
25794
25795         Build fix after r133224 as suggested by Enrica.
25796         Confirmed the test failures go away on Chromium Mac locally.
25797
25798         * page/EventHandler.cpp:
25799         (WebCore::EventHandler::updateSelectionForMouseDrag):
25800
25801 2012-11-01  Alexey Proskuryakov  <ap@apple.com>
25802
25803         Rename HAVE(NETWORK_CFDATA_ARRAY_CALLBACK) to USE(NETWORK_CFDATA_ARRAY_CALLBACK)
25804
25805         Rubber-stamped by Joe Pecoraro.
25806
25807         All CFNetwork based platforms have this now, but not all use it at the moment.
25808
25809         * loader/ResourceLoader.h:
25810         * loader/SubresourceLoader.h:
25811         * loader/cf/SubresourceLoaderCF.cpp:
25812         * loader/mac/ResourceLoaderMac.mm:
25813         * platform/SharedBuffer.cpp:
25814         (WebCore::SharedBuffer::clear):
25815         (WebCore::SharedBuffer::buffer):
25816         (WebCore::SharedBuffer::getSomeData):
25817         * platform/SharedBuffer.h:
25818         * platform/cf/SharedBufferCF.cpp:
25819         * platform/network/ResourceHandle.h:
25820         * platform/network/ResourceHandleClient.h:
25821         (ResourceHandleClient):
25822         * platform/network/cf/ResourceHandleCFNet.cpp:
25823         (WebCore::willCacheResponse):
25824         (WebCore::ResourceHandle::createCFURLConnection):
25825         * platform/network/mac/ResourceHandleMac.mm:
25826
25827 2012-11-01  Alexey Proskuryakov  <ap@apple.com>
25828
25829         Fix HAVE(NETWORK_CFDATA_ARRAY_CALLBACK) build
25830         https://bugs.webkit.org/show_bug.cgi?id=100979
25831
25832         Reviewed by Joseph Pecoraro.
25833
25834         * loader/ResourceBuffer.cpp: (WebCore::ResourceBuffer::append):
25835         * loader/ResourceBuffer.h:
25836         Added a version of append() that takes CFDataRef, passing it directly to SharedBuffer.
25837
25838         * loader/mac/ResourceLoaderMac.mm: (WebCore::ResourceLoader::didReceiveDataArray):
25839         InspectorInstrumentation now takes a length. Unfortunately, we don't have encodedLength
25840         here, meaning that the results will likely be incorrect.
25841
25842         * platform/network/cf/ResourceHandleCFNet.cpp:
25843         (WebCore::willCacheResponse): Removed a version that needlessly used deprecated API.
25844         (WebCore::ResourceHandle::createCFURLConnection): This code assumed that
25845         HAVE(NETWORK_CFDATA_ARRAY_CALLBACK) and USE(PROTECTION_SPACE_AUTH_CALLBACK) always
25846         come together. Changed to check for these separately.
25847
25848 2012-11-01  Rob Buis  <rbuis@rim.com>
25849
25850         [BlackBerry] Add more form validation strings
25851         https://bugs.webkit.org/show_bug.cgi?id=100978
25852
25853         Reviewed by Yong Li.
25854
25855         PR 210072
25856
25857         Implement these two methods properly.
25858
25859         * platform/blackberry/LocalizedStringsBlackBerry.cpp:
25860         (WebCore::validationMessageRangeUnderflowText):
25861         (WebCore::validationMessageRangeOverflowText):
25862
25863 2012-11-01  Alexandru Chiculita  <achicu@adobe.com>
25864
25865         [CSS Shaders] Move MeshBoxType out of CustomFilterOperation
25866         https://bugs.webkit.org/show_bug.cgi?id=100782
25867
25868         Reviewed by Dean Jackson.
25869
25870         Moved CustomFilter::MeshBoxType enum to the CustomFilterConstants.h file and renamed it to CustomFilterMeshBoxType. 
25871         This way we can reuse it without including the CustomFilterOperation file.
25872
25873         No new tests, just refactoring code.
25874
25875         * css/CSSPrimitiveValueMappings.h:
25876         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
25877         (WebCore::CSSPrimitiveValue::operator CustomFilterMeshBoxType):
25878         * css/StyleResolver.cpp:
25879         (WebCore::StyleResolver::createCustomFilterOperation):
25880         * platform/graphics/filters/CustomFilterArrayParameter.h: Adding AnimationUtilities.h for WebCore::blend, looks like
25881         CustomFilterOperation already included AnimationsUtilities.h indirectly.
25882         * platform/graphics/filters/CustomFilterConstants.h: Added CustomFilterMeshBoxType.
25883         * platform/graphics/filters/CustomFilterNumberParameter.h:
25884         * platform/graphics/filters/CustomFilterOperation.cpp:
25885         (WebCore::CustomFilterOperation::CustomFilterOperation):
25886         * platform/graphics/filters/CustomFilterOperation.h:
25887         (WebCore::CustomFilterOperation::create):
25888         (WebCore::CustomFilterOperation::meshBoxType):
25889         (CustomFilterOperation):
25890         * platform/graphics/filters/CustomFilterRenderer.cpp:
25891         (WebCore::CustomFilterRenderer::create):
25892         (WebCore::CustomFilterRenderer::CustomFilterRenderer):
25893         * platform/graphics/filters/CustomFilterRenderer.h: Also removed the need to include CustomFilterOperation.h. Some other
25894         headers were needed to replace the files that were automatically incldued because of that file.
25895         (WebCore):
25896         (CustomFilterRenderer):
25897         * platform/graphics/filters/FECustomFilter.cpp:
25898         (WebCore::FECustomFilter::FECustomFilter):
25899         (WebCore::FECustomFilter::create):
25900         * platform/graphics/filters/FECustomFilter.h:
25901         (FECustomFilter):
25902
25903 2012-11-01  Enrica Casucci  <enrica@apple.com>
25904
25905         Part2 of: Extend -webkit-user-select with new value "all"
25906         <rdar://problem/10161404>
25907         https://bugs.webkit.org/show_bug.cgi?id=91912
25908
25909         Reviewed by Ryosuke Niwa.
25910
25911         The new value "all" for -webkit-user-select property gives content none-or-all selection option.
25912         The patch was originally prepared by Alice Cheng but the approach has been changed.
25913         The idea is to treat these elements like non editable, meaning that we should skip over them entirely
25914         when moving the cursor and a deletion should delete the element and all its descentants at once.
25915         The key change is in Node::rendererIsEditable where we now return false if the element style is
25916         userSelect: all. The other change is in the way we create the selection on mouse click and dragging
25917         over the element. In both cases we force the selection to extend over the entire element with
25918         the user-select: all attribute.
25919         This is currently enabled only for the Mac port.
25920
25921         Test: editing/selection/user-select-all-selection.html
25922
25923         * dom/Node.cpp: Added a parameter to isContentEditable to behave differently
25924         when called from JavaScript. Internally isContentEditable returns false on
25925         nodes with user-select: all style.
25926         (WebCore::Node::isContentEditable):
25927         (WebCore::Node::isContentRichlyEditable):
25928         (WebCore::Node::rendererIsEditable):
25929         (WebCore::Node::shouldUseInputMethod):
25930         (WebCore::Node::willRespondToMouseClickEvents):
25931         * dom/Node.h:
25932         (WebCore::Node::rendererIsEditable):
25933         (WebCore::Node::rendererIsRichlyEditable):
25934         * dom/Position.cpp:
25935         (WebCore::Position::nodeIsUserSelectAll): Added.
25936         (WebCore::Position::rootUserSelectAllForNode): Added.
25937         * dom/Position.h: Added static functions described above.
25938         * editing/ApplyStyleCommand.cpp:
25939         (WebCore::ApplyStyleCommand::removeInlineStyleFromElement): Added parameter to
25940         isContentEditable() call.
25941         (WebCore::ApplyStyleCommand::surroundNodeRangeWithElement): Added parameter to
25942         isContentEditable() call.
25943         * editing/DeleteFromTextNodeCommand.cpp:
25944         (WebCore::DeleteFromTextNodeCommand::doApply): Added parameter to
25945         isContentEditable() call.
25946         * editing/FrameSelection.cpp:
25947         (WebCore::adjustForwardPositionForUserSelectAll): New helper function.
25948         (WebCore::adjustBackwardPositionForUserSelectAll): New helper function.
25949         (WebCore::FrameSelection::modifyExtendingRight):
25950         (WebCore::FrameSelection::modifyExtendingForward):
25951         (WebCore::FrameSelection::modifyExtendingLeft):
25952         (WebCore::FrameSelection::modifyExtendingBackward):
25953         (WebCore::FrameSelection::modify):
25954         (WebCore::CaretBase::invalidateCaretRect): Added parameter to
25955         isContentEditable() call.
25956         * editing/InsertNodeBeforeCommand.cpp:
25957         (WebCore::InsertNodeBeforeCommand::doApply): Ditto.
25958         (WebCore::InsertNodeBeforeCommand::doUnapply): Ditto.
25959         * editing/RemoveNodeCommand.cpp:
25960         (WebCore::RemoveNodeCommand::doApply): Ditto.
25961         * editing/visible_units.cpp:
25962         (WebCore::startOfParagraph): We should not consider a paragraph break and element
25963         with user-select: all style, like we do at the border of editability.
25964         (WebCore::endOfParagraph): Ditto.
25965         * page/EventHandler.cpp:
25966         (WebCore::EventHandler::updateSelectionForMouseDownDispatchingSelectStart): Create a selection
25967         around the element whose style is user-select: all.
25968         (WebCore::EventHandler::updateSelectionForMouseDrag): Ditto.
25969         * rendering/RootInlineBox.cpp:
25970         (WebCore::RootInlineBox::selectionState): Fixed a bug uncovered during this work.
25971         If the selection starts in one of the leaf boxes and after we encounter one with SelectionNone,
25972         we should return the selection state as SelectionBoth, assuming we went past the end selection.
25973         This avoids doing an incorrect gap filling for the selection highlighting.
25974
25975 2012-11-01  Alec Flett  <alecflett@chromium.org>
25976
25977         IndexedDB: Fix Windows build by re-adding a #include
25978         https://bugs.webkit.org/show_bug.cgi?id=100986
25979
25980         Reviewed by Stephen White.
25981
25982         Fix #include that broke windows.
25983
25984         * Modules/indexeddb/IDBCallbacks.h:
25985
25986 2012-11-01  David Barton  <dbarton@mathscribe.com>
25987
25988         REGRESSION (r128837): mathml/presentation/subsup.xhtml became flaky
25989         https://bugs.webkit.org/show_bug.cgi?id=97390
25990
25991         Reviewed by Ojan Vafai.
25992
25993         In a RenderMathMLSubSup, we need to set the base's wrapper's style so that baseHeight
25994         in layout() will be the base's true height, without any flexbox stretching.
25995
25996         Tested by existing tests.
25997
25998         * rendering/mathml/RenderMathMLSubSup.cpp:
25999         (WebCore::RenderMathMLSubSup::fixAnonymousStyles):
26000         (WebCore::RenderMathMLSubSup::addChild):
26001         (WebCore::RenderMathMLSubSup::styleDidChange):
26002         * rendering/mathml/RenderMathMLSubSup.h:
26003         (RenderMathMLSubSup):
26004
26005 2012-11-01  Antti Koivisto  <antti@apple.com>
26006
26007         REGRESSION (r132941): attribute modification 10% performance regression
26008         https://bugs.webkit.org/show_bug.cgi?id=100873
26009
26010         Reviewed by Ojan Vafai.
26011
26012         Don't do the class change finding by mutating SpaceSplitString. It is slow. Instead use a bit vector
26013         to mark the unchanged classes
26014
26015         * css/StyleResolver.cpp:
26016         (WebCore):
26017         * css/StyleResolver.h:
26018         (WebCore::StyleResolver::hasSelectorForAttribute):
26019         (WebCore):
26020         (WebCore::StyleResolver::hasSelectorForClass):
26021         (WebCore::StyleResolver::hasSelectorForId):
26022         
26023             Inlined these and moved value validity testing to clients.
26024
26025         * dom/Element.cpp:
26026         (WebCore::checkNeedsStyleInvalidationForIdChange):
26027         (WebCore):
26028         (WebCore::Element::attributeChanged):
26029     
26030             Clean up id testing too.
26031
26032         (WebCore::checkNeedsStyleInvalidationForClassChange):
26033         
26034             Use bit vector for marking seen values. Avoids allocations and reffing.
26035
26036         (WebCore::Element::classAttributeChanged):
26037         
26038             Don't test if style is already invalid.
26039
26040 2012-11-01  Ryosuke Niwa  <rniwa@webkit.org>
26041
26042         [Mac] Crash in Range::editingStartPosition
26043         https://bugs.webkit.org/show_bug.cgi?id=100972
26044
26045         Reviewed by Enrica Casucci.
26046
26047         Add a missing null pointer check. toNormalizedRange() can return null here, in which case the call to
26048         pastLastNode() will crash.
26049
26050         No new tests since determining the exact condition under which we go through the said code path and
26051         toNormalRange returns null is hard.
26052
26053         * editing/mac/EditorMac.mm:
26054         (WebCore::Editor::fontForSelection):
26055
26056 2012-11-01  Beth Dakin  <bdakin@apple.com>
26057
26058         https://bugs.webkit.org/show_bug.cgi?id=100917
26059         There should be a way to dump the scrolling tree from the layout tests
26060
26061         Reviewed by Simon Fraser.
26062
26063         New Internals call to dump the scrolling state tree as text. Calls through to the 
26064         ScrollingCoordinator.
26065         * testing/Internals.cpp:
26066         (WebCore::Internals::scrollingStateTreeAsText):
26067         (WebCore):
26068         * testing/Internals.h:
26069         * testing/Internals.idl:
26070         * WebCore.exp.in:
26071         * page/Page.cpp:
26072         (WebCore::Page::scrollingStateTreeAsText):
26073         (WebCore):
26074         * page/Page.h:
26075         (Page):
26076
26077         ScrollingCoordinator tells the rootStateNode to dump the tree as text.
26078         * page/scrolling/mac/ScrollingCoordinatorMac.h:
26079         (ScrollingCoordinatorMac):
26080         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
26081         (WebCore::ScrollingCoordinatorMac::scrollingStateTreeAsText):
26082         (WebCore):
26083         * page/scrolling/ScrollingCoordinator.cpp:
26084         (WebCore::ScrollingCoordinator::scrollingStateTreeAsText):
26085         (WebCore):
26086         * page/scrolling/ScrollingCoordinator.h:
26087         (ScrollingCoordinator):
26088
26089         dumpNode() dumps generic stuff for each node, and dumpProperties will dump the 
26090         properties that are specific to different types of nodes.
26091         * page/scrolling/ScrollingStateNode.cpp:
26092         (WebCore::ScrollingStateNode::writeIndent):
26093         (WebCore):
26094         (WebCore::ScrollingStateNode::dumpNode):
26095         (WebCore::ScrollingStateNode::scrollingStateTreeAsText):
26096         * page/scrolling/ScrollingStateNode.h:
26097         (WebCore):
26098         (ScrollingStateNode):
26099         * page/scrolling/ScrollingStateScrollingNode.cpp:
26100         (WebCore::ScrollingStateScrollingNode::dumpProperties):
26101         (WebCore):
26102         * page/scrolling/ScrollingStateScrollingNode.h:
26103         (ScrollingStateScrollingNode):
26104
26105 2012-11-01  Kenneth Russell  <kbr@google.com>
26106
26107         Add RGB to supported destination formats of ImageBuffer::copyToPlatformTexture
26108         https://bugs.webkit.org/show_bug.cgi?id=100971
26109
26110         Reviewed by Stephen White.
26111
26112         The ImageBuffer::copyToPlatformTexture restriction added in
26113         r132965 was too restrictive. Allow RGB textures to prevent
26114         performance regressions.
26115
26116         * html/canvas/WebGLRenderingContext.cpp:
26117         (WebCore):
26118         (WebCore::WebGLRenderingContext::texImage2D):
26119         * platform/graphics/ImageBuffer.h:
26120         (ImageBuffer):
26121
26122 2012-11-01  Michael Matovsky  <mmatovsky@rim.com>
26123
26124         [BlackBerry] Web page view state should be preserved for pages loaded from page cache
26125         https://bugs.webkit.org/show_bug.cgi?id=100694
26126         Internal PR: 220488
26127
26128         Internally reviewed by Lianghui Chen, Joe Mason
26129         Reviewed by Rob Buis.
26130
26131         The web page view specific metadata should be preserved for web pages loaded from page cache (by using back/forward).
26132         This requires web page view state to be saved in and restored from the corresponding page cache history item.
26133
26134         No new tests for platform specific internal change.
26135
26136         * history/blackberry/HistoryItemViewState.h:
26137         (HistoryItemViewState):
26138
26139 2012-11-01  Alec Flett  <alecflett@chromium.org>
26140
26141         IndexedDB: add methods to support id-based backend APIs
26142         https://bugs.webkit.org/show_bug.cgi?id=100425
26143
26144         Reviewed by Tony Chang.
26145
26146         First half of refactor involves adding a number of methods that
26147         are int64_t-based rather than String-based. As a part of this, the
26148         IDB*Metadata structs and the backend objectStore/index maps all
26149         use int64_t as keys, rather than String.
26150
26151         In addition, there were a number of cleanups that came out of the
26152         refactor:
26153
26154         - The list of object stores active in a transaction is now
26155           maintained by the frontend IDBTransaction rather than the backend
26156           IDBTransactionBackendImpl. This also had a simplifying rippling
26157           effect through other call signatures.
26158
26159         - I was able to remove an apparently old FIXME from
26160           IDBTransactionBackendImpl::objectStore and replace it with an ASSERT.
26161
26162         - IDBObjectStoreBackendImpl's IndexWriter class got a little
26163           simpler since the id is now easily available in the
26164           IDBIndexMetadata.
26165
26166         - A number of methods got simpler in their int64_t versions,
26167           specifically dropping a number of ExceptionCodes.
26168
26169         There is also some glue code
26170         (getIndexId/getIndexIds/getObjectStoreId) that will go away with
26171         the 2nd half of this: https://bugs.webkit.org/show_bug.cgi?id=100425
26172
26173         No new tests, no new functionality as this is just a refactor.
26174
26175         * Modules/indexeddb/IDBDatabase.cpp:
26176         (WebCore::IDBDatabase::objectStoreNames):
26177         (WebCore::IDBDatabase::createObjectStore):
26178         (WebCore::IDBDatabase::deleteObjectStore):
26179         (WebCore::IDBDatabase::transaction):
26180         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
26181         (WebCore::IDBDatabaseBackendImpl::metadata):
26182         (WebCore::IDBDatabaseBackendImpl::createObjectStore):
26183         (WebCore::IDBDatabaseBackendImpl::objectStore):
26184         (WebCore::IDBDatabaseBackendImpl::getObjectStoreId):
26185         (WebCore):
26186         (WebCore::IDBDatabaseBackendImpl::deleteObjectStore):
26187         (WebCore::IDBDatabaseBackendImpl::transaction):
26188         (WebCore::IDBDatabaseBackendImpl::loadObjectStores):
26189         (WebCore::IDBDatabaseBackendImpl::removeObjectStoreFromMap):
26190         (WebCore::IDBDatabaseBackendImpl::addObjectStoreToMap):
26191         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
26192         (WebCore::IDBDatabaseBackendImpl::deleteObjectStore):
26193         (IDBDatabaseBackendImpl):
26194         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
26195         (IDBDatabaseBackendInterface):
26196         * Modules/indexeddb/IDBIndex.h:
26197         (WebCore::IDBIndex::id):
26198         (WebCore::IDBIndex::openKeyCursor):
26199         * Modules/indexeddb/IDBIndexBackendInterface.h:
26200         * Modules/indexeddb/IDBMetadata.h:
26201         (WebCore::IDBIndexMetadata::IDBIndexMetadata):
26202         (IDBIndexMetadata):
26203         (IDBObjectStoreMetadata):
26204         (WebCore::IDBObjectStoreMetadata::containsIndex):
26205         (IDBDatabaseMetadata):
26206         (WebCore::IDBDatabaseMetadata::IDBDatabaseMetadata):
26207         (WebCore::IDBDatabaseMetadata::containsObjectStore):
26208         * Modules/indexeddb/IDBObjectStore.cpp:
26209         (WebCore::IDBObjectStore::indexNames):
26210         (WebCore::IDBObjectStore::put):
26211         (WebCore::IDBObjectStore::createIndex):
26212         (WebCore::IDBObjectStore::index):
26213         (WebCore::IDBObjectStore::deleteIndex):
26214         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
26215         (WebCore::IDBObjectStoreBackendImpl::put):
26216         (WebCore::IDBObjectStoreBackendImpl::putWithIndexKeys):
26217         (WebCore):
26218         (WebCore::makeIndexWriters):
26219         (WebCore::IDBObjectStoreBackendImpl::setIndexKeys):
26220         (WebCore::IDBObjectStoreBackendImpl::setIndexesReady):
26221         (WebCore::IDBObjectStoreBackendImpl::setIndexesReadyInternal):
26222         (WebCore::IDBObjectStoreBackendImpl::putInternal):
26223         (WebCore::IDBObjectStoreBackendImpl::deleteInternal):
26224         (WebCore::IDBObjectStoreBackendImpl::createIndex):
26225         (WebCore::IDBObjectStoreBackendImpl::index):
26226         (WebCore::IDBObjectStoreBackendImpl::getIndexId):
26227         (WebCore::IDBObjectStoreBackendImpl::getIndexIds):
26228         (WebCore::IDBObjectStoreBackendImpl::deleteIndex):
26229         (WebCore::IDBObjectStoreBackendImpl::loadIndexes):
26230         (WebCore::IDBObjectStoreBackendImpl::removeIndexFromMap):
26231         (WebCore::IDBObjectStoreBackendImpl::addIndexToMap):
26232         * Modules/indexeddb/IDBObjectStoreBackendImpl.h:
26233         (IDBObjectStoreBackendImpl):
26234         * Modules/indexeddb/IDBObjectStoreBackendInterface.h:
26235         * Modules/indexeddb/IDBOpenDBRequest.cpp:
26236         (WebCore::IDBOpenDBRequest::onUpgradeNeeded):
26237         * Modules/indexeddb/IDBRequest.cpp:
26238         (WebCore::IDBRequest::onSuccess):
26239         (WebCore::IDBRequest::uncaughtExceptionInEventHandler):
26240         * Modules/indexeddb/IDBTransaction.cpp:
26241         (WebCore::IDBTransaction::create):
26242         (WebCore::IDBTransaction::IDBTransaction):
26243         (WebCore::IDBTransaction::objectStore):
26244         * Modules/indexeddb/IDBTransaction.h:
26245         (IDBTransaction):
26246         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
26247         (WebCore::IDBTransactionBackendImpl::create):
26248         (WebCore::IDBTransactionBackendImpl::IDBTransactionBackendImpl):
26249         (WebCore::IDBTransactionBackendImpl::objectStore):
26250         (WebCore):
26251         (WebCore::IDBTransactionBackendImpl::scheduleTask):
26252         * Modules/indexeddb/IDBTransactionBackendImpl.h:
26253         (IDBTransactionBackendImpl):
26254         * Modules/indexeddb/IDBTransactionBackendInterface.h:
26255
26256 2012-11-01  Adam Barth  <abarth@webkit.org>
26257
26258         [V8] The DOMWrapperVisitor abstraction is no longer needed
26259         https://bugs.webkit.org/show_bug.cgi?id=100965
26260
26261         Reviewed by Kentaro Hara.
26262
26263         This patch removes the DOMWrapperVisitor interface because it is no
26264         longer needed. As a consequence, DOMWrapperMaps no longer need to
26265         support enumeration, and we can move more DOM objects to use the faster
26266         intrusive wrappers.
26267
26268         There was one remaining user of DOMWrapperVisitor in the
26269         ScriptProfiler, which I've moved over to enumerating objects directly
26270         from V8, similar to a function above it in the same file.
26271
26272         * bindings/v8/DOMWrapperMap.h:
26273         (WebCore):
26274         (DOMWrapperMap):
26275         * bindings/v8/IntrusiveDOMWrapperMap.h:
26276         * bindings/v8/ScriptProfiler.cpp:
26277         (WebCore::ScriptProfiler::visitNodeWrappers):
26278         (WebCore::ScriptProfiler::visitExternalArrays):
26279
26280 2012-11-01  Mike West  <mkwst@chromium.org>
26281
26282         CSP 1.0: Warn when old-style directives encountered.
26283         https://bugs.webkit.org/show_bug.cgi?id=100883
26284
26285         Reviewed by Adam Barth.
26286
26287         In Mozilla's pre-W3C-spec implementation, a few directives are
26288         implemented that were either renamed, reworked, or removed from CSP 1.0.
26289         This patch adds special warning messages for three of those directives
26290         to set developer expectations correctly.
26291
26292         Test: http/tests/security/contentSecurityPolicy/source-list-parsing-deprecated.html
26293
26294         * page/ContentSecurityPolicy.cpp:
26295         (WebCore::CSPDirectiveList::parseDirective):
26296         (WebCore::CSPDirectiveList::addDirective):
26297         (WebCore::ContentSecurityPolicy::reportUnsupportedDirective):
26298         * page/ContentSecurityPolicy.h:
26299             Rename 'reportUnrecognizedDirectives' to
26300             'reportUnsupportedDirectives', and teach it to give more descriptive
26301             error messages when encountering 'allow', 'options', and
26302             'policy-uri'.
26303
26304 2012-11-01  Pavel Feldman  <pfeldman@chromium.org>
26305
26306         Web Inspector: Update CodeMirror to v3
26307         https://bugs.webkit.org/show_bug.cgi?id=99319
26308
26309         Reviewed by Vsevolod Vlasov.
26310
26311         Updated to ToT v3.
26312
26313         * inspector/front-end/CodeMirrorTextEditor.js:
26314         (WebInspector.CodeMirrorTextEditor):
26315         (WebInspector.CodeMirrorTextEditor.prototype._gutterClick):
26316         (WebInspector.CodeMirrorTextEditor.prototype.addBreakpoint):
26317         (WebInspector.CodeMirrorTextEditor.prototype.removeBreakpoint):
26318         (WebInspector.CodeMirrorTextEditor.prototype.setExecutionLine):
26319         (WebInspector.CodeMirrorTextEditor.prototype.clearExecutionLine):
26320         (WebInspector.CodeMirrorTextEditor.prototype.highlightLine):
26321         (WebInspector.CodeMirrorTextEditor.prototype.clearLineHighlight):
26322         (WebInspector.CodeMirrorTextEditor.prototype._change):
26323         * inspector/front-end/cm/cmdevtools.css:
26324         (.CodeMirror):
26325         (.CodeMirror-linenumber):
26326         (.cm-breakpoint):
26327         * inspector/front-end/cm/codemirror.css:
26328         (.CodeMirror):
26329         (.CodeMirror-scroll):
26330         (.CodeMirror-lines):
26331         (.CodeMirror pre):
26332         (.CodeMirror-scrollbar-filler):
26333         (.CodeMirror-gutters):
26334         (.CodeMirror-linenumbers):
26335         (.CodeMirror-linenumber):
26336         (.CodeMirror pre.CodeMirror-cursor):
26337         (.CodeMirror pre.CodeMirror-secondarycursor):
26338         (.cm-keymap-fat-cursor pre.CodeMirror-cursor):
26339         (.cm-keymap-fat-cursor pre.CodeMirror-cursor:not(#nonsense_id)):
26340         (.CodeMirror pre.CodeMirror-cursor.CodeMirror-overwrite):
26341         (.cm-s-default .cm-keyword):
26342         (.cm-s-default .cm-atom):
26343         (.cm-s-default .cm-number):
26344         (.cm-s-default .cm-def):
26345         (.cm-s-default .cm-variable):
26346         (.cm-s-default .cm-variable-2):
26347         (.cm-s-default .cm-variable-3):
26348         (.cm-s-default .cm-property):
26349         (.cm-s-default .cm-operator):
26350         (.cm-s-default .cm-comment):
26351         (.cm-s-default .cm-string):
26352         (.cm-s-default .cm-string-2):
26353         (.cm-s-default .cm-meta):
26354         (.cm-s-default .cm-error):
26355         (.cm-s-default .cm-qualifier):
26356         (.cm-s-default .cm-builtin):
26357         (.cm-s-default .cm-bracket):
26358         (.cm-s-default .cm-tag):
26359         (.cm-s-default .cm-attribute):
26360         (.cm-s-default .cm-header):
26361         (.cm-s-default .cm-quote):
26362         (.cm-s-default .cm-hr):
26363         (.cm-s-default .cm-link):
26364         (.cm-header, .cm-strong):
26365         (.cm-em):
26366         (.cm-emstrong):
26367         (.cm-link):
26368         (.cm-invalidchar):
26369         (div.CodeMirror span.CodeMirror-matchingbracket):
26370         (div.CodeMirror span.CodeMirror-nonmatchingbracket):
26371         (.CodeMirror-sizer):
26372         (.CodeMirror-vscrollbar, .CodeMirror-hscrollbar, .CodeMirror-scrollbar-filler):
26373         (.CodeMirror-vscrollbar):
26374         (.CodeMirror-hscrollbar):
26375         (.CodeMirror-gutter):
26376         (.CodeMirror-gutter-elt):
26377         (.CodeMirror-linebackground):
26378         (.CodeMirror-linewidget):
26379         (.CodeMirror-measure):
26380         (.CodeMirror-measure pre):
26381         (.CodeMirror-selected):
26382         (.CodeMirror-focused .CodeMirror-selected):
26383         (.CodeMirror span):
26384         * inspector/front-end/cm/codemirror.js:
26385         (window.CodeMirror.):
26386         (window.CodeMirror):
26387         * inspector/front-end/utilities.js:
26388
26389 2012-11-01  Tiancheng Jiang  <tijiang@rim.com>
26390
26391         [BlackBerry] Update BB10 form theme.
26392         https://bugs.webkit.org/show_bug.cgi?id=100760
26393
26394         Reviewed by Rob Buis.
26395
26396         RIM PR 235194.
26397
26398         Check img pointer is null, if so, do early return.
26399
26400         * platform/blackberry/RenderThemeBlackBerry.cpp:
26401         (WebCore::drawControl):
26402         (WebCore::drawThreeSlice):
26403         (WebCore::drawNineSlice):
26404
26405 2012-11-01  Adam Barth  <abarth@webkit.org>
26406
26407         [V8] The V8DOMMap visitors are no longer needed
26408         https://bugs.webkit.org/show_bug.cgi?id=100963
26409
26410         Reviewed by Kentaro Hara.
26411
26412         This patch inlines visitAllDOMNodes into its one caller (and removes
26413         one layer of visitor adaptor abstraction).
26414
26415         * bindings/v8/ScriptProfiler.cpp:
26416         (WebCore::ScriptProfiler::visitNodeWrappers):
26417         * bindings/v8/V8DOMMap.cpp:
26418         * bindings/v8/V8DOMMap.h:
26419         (WebCore):
26420
26421 2012-11-01  Tiancheng Jiang  <tijiang@rim.com>
26422
26423         [BlackBerry] Update BB10 form theme.
26424         https://bugs.webkit.org/show_bug.cgi?id=100760
26425
26426         Reviewed by Rob Buis.
26427
26428         RIM PR 235194.
26429
26430         Check img pointer is null, if so, do early return.
26431
26432         * platform/blackberry/RenderThemeBlackBerry.cpp:
26433         (WebCore::drawControl):
26434         (WebCore::drawThreeSlice):
26435         (WebCore::drawNineSlice):
26436
26437 2012-11-01  Adam Barth  <abarth@webkit.org>
26438
26439         Unreviewed. Build fix.
26440
26441         * bindings/v8/V8GCController.cpp:
26442
26443 2012-11-01  Christophe Dumez  <christophe.dumez@intel.com>
26444
26445         [EFL][WK2] Add Ewk_Auth_Request API
26446         https://bugs.webkit.org/show_bug.cgi?id=100858
26447
26448         Reviewed by Kenneth Rohde Christiansen.
26449
26450         Provide an AuthenticationClient for EFL port in WebCore so
26451         that we can handle authentication similarly to other ports
26452         of WebKit.
26453
26454         No new tests, no behavior change for layout tests.
26455
26456         * PlatformEfl.cmake: Add AuthenticationChallengeSoup.cpp to CMake.
26457         * loader/ResourceLoader.cpp:
26458         (WebCore::ResourceLoader::didReceiveAuthenticationChallenge):
26459         * platform/network/ResourceHandle.h:
26460         (ResourceHandle): Have ResourceHandle subclass AuthenticationClient like
26461         most of the other ports.
26462         * platform/network/soup/AuthenticationChallengeSoup.cpp: Fix initialization
26463         of previousFailureCount member. It should be 1 if we are retrying
26464         authentication and 0 otherwise, not the opposite.
26465         (WebCore::AuthenticationChallenge::AuthenticationChallenge):
26466         * platform/network/soup/ResourceHandleSoup.cpp: Provide implementation for EFL
26467         port of AuthenticationClient methods.
26468         (WebCore::WebCoreSynchronousLoader::didReceiveAuthenticationChallenge):
26469         (WebCoreSynchronousLoader):
26470         (WebCore):
26471         (WebCore::ResourceHandle::didReceiveAuthenticationChallenge):
26472         (WebCore::ResourceHandle::receivedRequestToContinueWithoutCredential):
26473         (WebCore::ResourceHandle::receivedCredential):
26474         (WebCore::ResourceHandle::receivedCancellation):
26475         (WebCore::authenticateCallback):
26476         (WebCore::ResourceHandle::defaultSession):
26477
26478 2012-10-24  Jocelyn Turcotte  <jocelyn.turcotte@digia.com>
26479
26480         WebIconDatabase: Properly clean up on destruction
26481         https://bugs.webkit.org/show_bug.cgi?id=100237
26482
26483         Reviewed by Brady Eidson.
26484
26485         It's now possible that the IconDatabase gets destroyed since WebKit2
26486         isn't using it as a singleton.
26487
26488         Check that the database was properly closed rather than asserting that
26489         it won't get deleted.
26490
26491         * loader/icon/IconDatabase.cpp:
26492         (WebCore::IconDatabase::~IconDatabase):
26493
26494 2012-11-01  Alexei Filippov  <alph@chromium.org>
26495
26496         Web Inspector: make component subitems use parent color in native memory snapshots.
26497         https://bugs.webkit.org/show_bug.cgi?id=100876
26498
26499         A component subitems use the color of the component itself if the color
26500         is not explicitly specified for the subitem.
26501
26502         Reviewed by Yury Semikhatsky.
26503
26504         * inspector/front-end/NativeMemorySnapshotView.js:
26505         (WebInspector.NativeSnapshotNode.prototype._createSizeCell):
26506         (WebInspector.MemoryBlockViewProperties._initialize):
26507         (WebInspector.MemoryBlockViewProperties._forMemoryBlock):
26508
26509 2012-11-01  Emil A Eklund  <eae@chromium.org>
26510
26511         [subpixel] Change intrinsicSize to LayoutUnit
26512         https://bugs.webkit.org/show_bug.cgi?id=99104
26513
26514         Reviewed by Levi Weintraub.
26515
26516         Change RenderReplaced and intrinsicSize to LayoutUnit to avoid
26517         rounding problems when zooming/scaling. Also change imageSize to
26518         LayoutUnit as it can return a scaled size.
26519
26520         Test: fast/sub-pixel/tiled-canvas-elements.html
26521
26522         * html/ImageDocument.cpp:
26523         (WebCore::ImageDocumentParser::finish):
26524         * loader/cache/CachedImage.cpp:
26525         (WebCore::CachedImage::imageSizeForRenderer):
26526         * loader/cache/CachedImage.h:
26527         (CachedImage):
26528         * platform/graphics/FractionalLayoutSize.h:
26529         (FractionalLayoutSize):
26530         (WebCore::FractionalLayoutSize::scale):
26531         (WebCore::FractionalLayoutSize::clampToMinimumSize):
26532         * rendering/RenderBox.h:
26533         (WebCore::RenderBox::intrinsicSize):
26534         * rendering/RenderHTMLCanvas.cpp:
26535         (WebCore::RenderHTMLCanvas::canvasSizeChanged):
26536         * rendering/RenderImage.cpp:
26537         (WebCore::RenderImage::imageChanged):
26538         (WebCore::RenderImage::updateIntrinsicSizeIfNeeded):
26539         (WebCore::RenderImage::paintReplaced):
26540         (WebCore::RenderImage::minimumReplacedHeight):
26541         * rendering/RenderImage.h:
26542         (RenderImage):
26543         * rendering/RenderImageResource.h:
26544         (WebCore::RenderImageResource::imageSize):
26545         * rendering/RenderImageResourceStyleImage.h:
26546         * rendering/RenderReplaced.cpp:
26547         (WebCore::RenderReplaced::RenderReplaced):
26548         (WebCore::RenderReplaced::computeAspectRatioInformationForRenderBox):
26549         (WebCore::RenderReplaced::computeReplacedLogicalWidth):
26550         (WebCore::RenderReplaced::computeReplacedLogicalHeight):
26551         * rendering/RenderReplaced.h:
26552         (RenderReplaced):
26553         (WebCore::RenderReplaced::minimumReplacedHeight):
26554         (WebCore::RenderReplaced::setIntrinsicSize):
26555         * rendering/RenderVideo.cpp:
26556         (WebCore::RenderVideo::updateIntrinsicSize):
26557         (WebCore::RenderVideo::calculateIntrinsicSize):
26558         (WebCore::RenderVideo::videoBox):
26559         (WebCore::RenderVideo::minimumReplacedHeight):
26560         * rendering/RenderVideo.h:
26561         (RenderVideo):
26562         * rendering/style/StyleCachedImage.cpp:
26563         (WebCore::StyleCachedImage::imageSize):
26564         * rendering/style/StyleCachedImage.h:
26565         (StyleCachedImage):
26566         * rendering/style/StyleCachedImageSet.cpp:
26567         (WebCore::StyleCachedImageSet::imageSize):
26568         * rendering/style/StyleCachedImageSet.h:
26569         (StyleCachedImageSet):
26570         * rendering/style/StyleGeneratedImage.cpp:
26571         (WebCore::StyleGeneratedImage::imageSize):
26572         (WebCore::StyleGeneratedImage::computeIntrinsicDimensions):
26573         * rendering/style/StyleGeneratedImage.h:
26574         (StyleGeneratedImage):
26575         * rendering/style/StyleImage.h:
26576         (StyleImage):
26577         * rendering/style/StylePendingImage.h:
26578
26579 2012-11-01  Adam Barth  <abarth@webkit.org>
26580
26581         [V8] Unify the V8GCController visitors
26582         https://bugs.webkit.org/show_bug.cgi?id=100897
26583
26584         Reviewed by Eric Seidel.
26585
26586         After this patch, we use a single visitor for all DOM wrappers,
26587         regardless of type. We also visit all the wrappers in one pass by
26588         calling v8::V8::VisitHandlesWithClassIds directly rather than via
26589         visitAllDOMNodes.
26590
26591         This patch also introduces a wrapper class ID for non-Node DOM objects.
26592         Previously, only DOM nodes had a class ID.
26593
26594         * bindings/v8/IntrusiveDOMWrapperMap.h:
26595         * bindings/v8/ScriptProfiler.cpp:
26596         (WebCore::retainedDOMInfo):
26597         (WebCore::ScriptProfiler::initialize):
26598         * bindings/v8/V8DOMMap.cpp:
26599         (WebCore::visitAllDOMNodes):
26600         * bindings/v8/V8DOMWrapper.cpp:
26601         (WebCore::V8DOMWrapper::setJSWrapperForDOMNode):
26602         * bindings/v8/V8DOMWrapper.h:
26603         (WebCore::V8DOMWrapper::setJSWrapperForDOMObject):
26604         * bindings/v8/V8GCController.cpp:
26605         (WebCore::GCHandleVisitor::notifyFinished):
26606         (GCHandleVisitor):
26607         (WebCore::V8GCController::majorGCPrologue):
26608         * bindings/v8/WrapperTypeInfo.h:
26609         (WebCore):
26610
26611 2012-11-01  Stephen White  <senorblanco@chromium.org>
26612
26613         Unreviewed, rolling out r133143.
26614         http://trac.webkit.org/changeset/133143
26615         https://bugs.webkit.org/show_bug.cgi?id=96894
26616
26617         Causing content_browsertests failures
26618
26619         * CMakeLists.txt:
26620         * GNUmakefile.list.am:
26621         * Target.pri:
26622         * WebCore.gypi:
26623         * WebCore.vcproj/WebCore.vcproj:
26624         * WebCore.xcodeproj/project.pbxproj:
26625         * dom/DeviceOrientationClient.h:
26626         (DeviceOrientationClient):
26627         * dom/DeviceOrientationController.cpp:
26628         (WebCore::DeviceOrientationController::DeviceOrientationController):
26629         (WebCore):
26630         (WebCore::DeviceOrientationController::~DeviceOrientationController):
26631         (WebCore::DeviceOrientationController::timerFired):
26632         (WebCore::DeviceOrientationController::addListener):
26633         (WebCore::DeviceOrientationController::removeListener):
26634         (WebCore::DeviceOrientationController::removeAllListeners):
26635         (WebCore::DeviceOrientationController::suspendEventsForAllListeners):
26636         (WebCore::DeviceOrientationController::resumeEventsForAllListeners):
26637         (WebCore::DeviceOrientationController::didChangeDeviceOrientation):
26638         (WebCore::DeviceOrientationController::supplementName):
26639         * dom/DeviceOrientationController.h:
26640         (WebCore):
26641         (DeviceOrientationController):
26642         (WebCore::DeviceOrientationController::isActive):
26643         (WebCore::DeviceOrientationController::client):
26644         (WebCore::DeviceOrientationController::from):
26645         * dom/Document.cpp:
26646         (WebCore::Document::suspendActiveDOMObjects):
26647         (WebCore::Document::resumeActiveDOMObjects):
26648         * loader/EmptyClients.h:
26649         (WebCore::EmptyDeviceOrientationClient::startUpdating):
26650         (WebCore::EmptyDeviceOrientationClient::stopUpdating):
26651         * page/DOMWindow.cpp:
26652         (WebCore::DOMWindow::addEventListener):
26653         (WebCore::DOMWindow::removeEventListener):
26654         (WebCore::DOMWindow::removeAllEventListeners):
26655         * page/DeviceClient.h: Removed.
26656         * page/DeviceController.cpp: Removed.
26657         * page/DeviceController.h: Removed.
26658
26659 2012-11-01  Kondapally Kalyan  <kalyan.kondapally@intel.com>
26660
26661         [EFL][AC]Free GL resources allocated by GraphicsContext3DEfl.
26662         https://bugs.webkit.org/show_bug.cgi?id=100923.
26663
26664         Reviewed by Kenneth Rohde Christiansen.
26665
26666         GraphicsContext3DEfl creates FBO's, textures and render buffer's, but doesn't free them.
26667         This patch makes sure that GraphicsContext3dEfl frees all the GL resources allocated by it.
26668
26669         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
26670         (WebCore::GraphicsContext3D::~GraphicsContext3D):
26671
26672 2012-11-01  Andreas Kling  <kling@webkit.org>
26673
26674         Fix StylePropertySet/ElementAttributeData custom allocation in debug builds.
26675         <http://webkit.org/b/100753>
26676
26677         Unreviewed debug bot crash fix after r133138.
26678
26679         There's additional padding after StylePropertySet and ElementAttributeData
26680         in 64-bit debug builds since there are additional members in RefCountedBase.
26681         Use 'sizeof(ImmutableFoo) - sizeof(void*)' as the base size of ImmutableFoo.
26682
26683         * css/StylePropertySet.cpp:
26684         (WebCore::sizeForImmutableStylePropertySetWithPropertyCount):
26685         * dom/ElementAttributeData.cpp:
26686         (WebCore::sizeForImmutableElementAttributeDataWithAttributeCount):
26687         (WebCore::ElementAttributeData::createImmutable):
26688         (WebCore::ElementAttributeData::reportMemoryUsage):
26689
26690 2012-11-01  Stephen Chenney  <schenney@chromium.org>
26691
26692         FEImage::m_document is never cleared. Why not?
26693         https://bugs.webkit.org/show_bug.cgi?id=99243
26694
26695         Reviewed by Dirk Schulze.
26696
26697         Adding a comment to explain why the failure to clear m_document is not a problem.
26698
26699         No new tests because no code change at all.
26700
26701         * svg/graphics/filters/SVGFEImage.h:
26702         (FEImage): Add a comment on the lifetime of m_document.
26703
26704 2012-11-01  Eugene Klyuchnikov  <eustas.bug@gmail.com>
26705
26706         Web Inspector: Timeline: make "addRecord" unambiguous
26707         https://bugs.webkit.org/show_bug.cgi?id=100761
26708
26709         Reviewed by Pavel Feldman.
26710
26711         TimelinePresentationModel.addRecord accepts two parameters:
26712         record and parentRecord. parentRecord is always root record.
26713         Make this explicit by removing parentRecord parameter.
26714
26715         * inspector/front-end/TimelinePanel.js: Removed parameter.
26716         * inspector/front-end/TimelinePresentationModel.js:
26717         (WebInspector.TimelinePresentationModel.prototype.addRecord):
26718         Used root recoed instead of parent record.
26719
26720 2012-11-01  Charles Wei  <charles.wei@torchmobile.com.cn>
26721
26722         [BlackBerry] Browser prematurely sends wrong credentials
26723         https://bugs.webkit.org/show_bug.cgi?id=100585
26724
26725         Reviewed by George Staikos.
26726
26727         Don't send credentials to the server before been challenged.
26728
26729         * platform/network/blackberry/NetworkManager.cpp:
26730         (WebCore::NetworkManager::startJob):
26731
26732 2012-11-01  Stephen Chenney  <schenney@chromium.org>
26733
26734         SVG as an image may recreate the renderer on zoom
26735         https://bugs.webkit.org/show_bug.cgi?id=99508
26736
26737         Reviewed by Abhishek Arya.
26738
26739         The SVGImage code, when SVG is used in <img> tags, caches the renderer
26740         at the start of the painting method and re-uses the pointer at the end
26741         of the method. However, when the page is zoomed the renderer may be
26742         detached mid-method, thus leaving a stray pointer. The fix is to
26743         re-fetch the pointer after the zooms.
26744
26745         Test: svg/as-image/img-zoom-svg-stylesheet.html
26746
26747         * svg/graphics/SVGImage.cpp:
26748         (WebCore::SVGImage::drawSVGToImageBuffer): Re-fetch the renderer after
26749         the zoom operations.
26750
26751 2012-11-01  Pavel Feldman  <pfeldman@chromium.org>
26752
26753         Web Inspector: introduce Inspector.detached message containing termination cause.
26754         https://bugs.webkit.org/show_bug.cgi?id=100948
26755
26756         Reviewed by Yury Semikhatsky.
26757
26758         Now protocol clients have more information to process connection termination.
26759
26760         * English.lproj/localizedStrings.js:
26761         * inspector/Inspector.json:
26762         * inspector/front-end/InspectorFrontendHostStub.js:
26763         (WebInspector.RemoteDebuggingTerminatedScreen):
26764         * inspector/front-end/inspector.js:
26765         (WebInspector.loaded.WebInspector.socket.onopen):
26766         (WebInspector.loaded):
26767         (WebInspector.detached):
26768
26769 2012-11-01  Vsevolod Vlasov  <vsevik@chromium.org>
26770
26771         Web Inspector: Restoring breakpoints for formatted UISourceCode should be triggered by BreakpointManager, not ScriptsPanel.
26772         https://bugs.webkit.org/show_bug.cgi?id=100593
26773
26774         Reviewed by Pavel Feldman.
26775
26776         BreakpointManager now listen for FormattedChanged event and restores formatted breakpoints on it.
26777         Removed now redundant callback from UISourceCode.setFormatted().
26778
26779         * inspector/front-end/BreakpointManager.js:
26780         (WebInspector.BreakpointManager.prototype._restoreBreakpoints):
26781         (WebInspector.BreakpointManager.prototype._uiSourceCodeAdded):
26782         (WebInspector.BreakpointManager.prototype._uiSourceCodeFormatted):
26783         (WebInspector.BreakpointManager.prototype._uiSourceCodeRemoved):
26784         * inspector/front-end/ScriptsPanel.js:
26785         (WebInspector.ScriptsPanel.prototype._addUISourceCode):
26786         (WebInspector.ScriptsPanel.prototype._revealExecutionLine):
26787         (WebInspector.ScriptsPanel.prototype._toggleFormatSource):
26788         * inspector/front-end/UISourceCode.js:
26789         (WebInspector.UISourceCode.prototype._fireContentAvailable):
26790         (WebInspector.UISourceCode.prototype.setFormatted.formattedChanged):
26791         (WebInspector.UISourceCode.prototype.setFormatted.didGetContent):
26792         (WebInspector.UISourceCode.prototype.setFormatted):
26793
26794 2012-10-30  Yury Semikhatsky  <yurys@chromium.org>
26795
26796         Web Inspector: Output code evaluated in the console the same as console.log
26797         https://bugs.webkit.org/show_bug.cgi?id=100695
26798
26799         Reviewed by Pavel Feldman.
26800
26801         Added an option to return object preview from evaluation commands in the protocol.
26802         The option is used to generate preview for console eval results.
26803
26804         * inspector/InjectedScript.cpp:
26805         (WebCore::InjectedScript::evaluate):
26806         (WebCore::InjectedScript::callFunctionOn):
26807         (WebCore::InjectedScript::evaluateOnCallFrame):
26808         * inspector/InjectedScript.h:
26809         (InjectedScript):
26810         * inspector/InjectedScriptSource.js:
26811         (.):
26812         * inspector/Inspector.json:
26813         * inspector/InspectorDebuggerAgent.cpp:
26814         (WebCore::InspectorDebuggerAgent::evaluateOnCallFrame):
26815         * inspector/InspectorDebuggerAgent.h:
26816         (InspectorDebuggerAgent):
26817         * inspector/InspectorRuntimeAgent.cpp:
26818         (WebCore::InspectorRuntimeAgent::evaluate):
26819         (WebCore::InspectorRuntimeAgent::callFunctionOn):
26820         * inspector/InspectorRuntimeAgent.h:
26821         (InspectorRuntimeAgent):
26822         * inspector/front-end/ConsoleMessage.js:
26823         (WebInspector.ConsoleMessageImpl.prototype.useArrayPreviewInFormatter):
26824         (WebInspector.ConsoleMessageImpl.prototype._formatParameterAsArray):
26825         * inspector/front-end/ConsoleView.js:
26826         (WebInspector.ConsoleCommandResult.prototype.useArrayPreviewInFormatter):
26827         * inspector/front-end/DebuggerModel.js:
26828         (WebInspector.DebuggerModel.prototype.evaluateOnSelectedCallFrame):
26829         (WebInspector.DebuggerModel.CallFrame.prototype.evaluate):
26830         * inspector/front-end/ExtensionServer.js:
26831         (WebInspector.ExtensionServer.prototype.evaluate):
26832         * inspector/front-end/JavaScriptSourceFrame.js:
26833         (WebInspector.JavaScriptSourceFrame.prototype._resolveObjectForPopover):
26834         * inspector/front-end/RemoteObject.js:
26835         (WebInspector.RemoteObject.prototype.):
26836         (WebInspector.RemoteObject.prototype.callFunction):
26837         (WebInspector.RemoteObject.prototype.callFunctionJSON):
26838         * inspector/front-end/RuntimeModel.js:
26839         (WebInspector.RuntimeModel.prototype.evaluate):
26840         (WebInspector.RuntimeModel.prototype.evaluated):
26841         * inspector/front-end/WatchExpressionsSidebarPane.js:
26842         (WebInspector.WatchExpressionsSection.prototype.update):
26843
26844 2012-11-01  Vsevolod Vlasov  <vsevik@chromium.org>
26845
26846         Web Inspector: Remove obsolete code from JavaScriptSourceFrame
26847         https://bugs.webkit.org/show_bug.cgi?id=100594
26848
26849         Reviewed by Yury Semikhatsky.
26850
26851         Removed obsolete WorkingCopyCommitted listener.
26852         Removed redundant code that removes breakpoints from _innerSetContent.
26853
26854         * inspector/front-end/JavaScriptSourceFrame.js:
26855         (WebInspector.JavaScriptSourceFrame):
26856         (WebInspector.JavaScriptSourceFrame.prototype._innerSetContent):
26857
26858 2012-11-01  Andreas Kling  <kling@webkit.org>
26859
26860         Update average StylePropertySet size estimation.
26861         <http://webkit.org/b/100940>
26862
26863         Reviewed by Antti Koivisto.
26864
26865         Use sizeForImmutableStylePropertySetWithPropertyCount(2) as the average StylePropertySet
26866         size to keep it in sync with the changed object memory layout.
26867
26868         * css/StylePropertySet.cpp:
26869         (WebCore::sizeForImmutableStylePropertySetWithPropertyCount):
26870         (WebCore::StylePropertySet::createImmutable):
26871         (WebCore::StylePropertySet::averageSizeInBytes):
26872         (WebCore::StylePropertySet::reportMemoryUsage):
26873
26874
26875 2012-11-01  Kondapally Kalyan  <kalyan.kondapally@intel.com>
26876
26877         [EFL][Qt][AC] Remove an unnecessary connection to X-Server.
26878         https://bugs.webkit.org/show_bug.cgi?id=100628.
26879
26880         Reviewed by Kenneth Rohde Christiansen.
26881
26882         With Changset: https://bugs.webkit.org/show_bug.cgi?id=100523
26883         GraphicsSurfacePrivate should always use the Display returned by offscreenwindow.
26884         However, in GraphicsSurfacePrivate constructor we call XOpenDisplay before asking
26885         display from offscreenwindow.
26886         This patch removes unnecessary call to XOpenDisplay made in GraphicsSurfacePrivate.
26887
26888         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
26889         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
26890
26891 2012-11-01  Mihnea Ovidenie  <mihnea@adobe.com>
26892
26893         [CSSRegions]Former auto-height regions should not ignore their defined height
26894         https://bugs.webkit.org/show_bug.cgi?id=100749
26895
26896         Reviewed by Julien Chaffraix.
26897
26898         When a region with height auto has its height defined, we should also clear the override logical content height.
26899         Otherwise, the region will use the wrong height when laying out content from the associated render flow thread.
26900
26901         Test: fast/regions/autoheight-definedheight-changenotdetected.html
26902
26903         * rendering/RenderRegion.cpp:
26904         (WebCore::RenderRegion::updateRegionHasAutoLogicalHeightFlag):
26905
26906 2012-11-01  Yury Semikhatsky  <yurys@chromium.org>
26907
26908         Memory instrumentation: do not report memory occupied by RenderObjects referenced from CSSImageGeneratorValue
26909         https://bugs.webkit.org/show_bug.cgi?id=100934
26910
26911         Reviewed by Alexander Pavlov.
26912
26913         * css/CSSImageGeneratorValue.cpp:
26914         (WTF): Skip rederences to RenderObjects from CSSImageGeneratorValue when collecting
26915         memory usage data.
26916
26917 2012-11-01  Kihong Kwon  <kihong.kwon@samsung.com>
26918
26919         Add DeviceController base-class to remove duplication of DeviceXXXControler
26920         https://bugs.webkit.org/show_bug.cgi?id=96894
26921
26922         Reviewed by Hajime Morita.
26923
26924         Add DeviceController which is extracted from DeviceOrientationController to remove duplication.
26925         And soon-to-be-added DeviceMotionController and ProximityController.
26926
26927         Covered by existing tests.
26928
26929         * CMakeLists.txt:
26930         * GNUmakefile.list.am:
26931         * Target.pri:
26932         * WebCore.gypi:
26933         * WebCore.vcproj/WebCore.vcproj:
26934         * WebCore.xcodeproj/project.pbxproj:
26935         * dom/DeviceOrientationClient.h:
26936         * dom/DeviceOrientationController.cpp:
26937         Remove member functions to move to DeviceController.
26938         - addListener(), removeListener(), removeAllListeners(), isActive()
26939         (WebCore::DeviceOrientationController::DeviceOrientationController):
26940         (WebCore::DeviceOrientationController::didChangeDeviceOrientation):
26941         (WebCore::DeviceOrientationController::client):
26942         (WebCore::DeviceOrientationController::hasLastData):
26943         (WebCore::DeviceOrientationController::getLastEvent):
26944         (WebCore::DeviceOrientationController::from):
26945         (WebCore):
26946         * dom/DeviceOrientationController.h:
26947         (WebCore):
26948         (WebCore::DeviceOrientationController::~DeviceOrientationController):
26949         (DeviceOrientationController):
26950         * dom/Document.cpp:
26951         Remove suspendEventsForAllListeners() and resumeEventsForAllListeners() function calls.
26952         These calls can be made by checking activeDOMObjectsAreSuspended() and activeDOMObjectsAreStopped() before dispatchEvent.
26953         (WebCore::Document::suspendActiveDOMObjects):
26954         (WebCore::Document::resumeActiveDOMObjects):
26955         * loader/EmptyClients.h:
26956         (EmptyDeviceClient):
26957         (WebCore::EmptyDeviceClient::startUpdating):
26958         (WebCore::EmptyDeviceClient::stopUpdating):
26959         (WebCore):
26960         * page/DOMWindow.cpp:
26961         (WebCore::DOMWindow::addEventListener):
26962         (WebCore::DOMWindow::removeEventListener):
26963         (WebCore::DOMWindow::removeAllEventListeners):
26964         * page/DeviceClient.h: Added.
26965         (WebCore):
26966         (DeviceClient):
26967         (WebCore::DeviceClient::~DeviceClient):
26968         * page/DeviceController.cpp: Added.
26969         DeviceController has extracted functions from DeviceOrientationController and DeviceMotionController.
26970         - addDeviceEventListener(), removeDeviceEventlistener(), removeAllDeviceEventListeners(), dispatchDeviceEvent()
26971         All kind of device event controller which has DeviceClient can be inherited from DeviceController.
26972         (WebCore):
26973         (WebCore::DeviceController::DeviceController):
26974         (WebCore::DeviceController::addDeviceEventListener):
26975         (WebCore::DeviceController::removeDeviceEventListener):
26976         (WebCore::DeviceController::removeAllDeviceEventListeners):
26977         (WebCore::DeviceController::dispatchDeviceEvent):
26978         (WebCore::DeviceController::fireDeviceEvent):
26979         * page/DeviceController.h: Added.
26980         (WebCore):
26981         (DeviceController):
26982         (WebCore::DeviceController::~DeviceController):
26983         (WebCore::DeviceController::isActive):
26984         (WebCore::DeviceController::client):
26985         (WebCore::DeviceController::hasLastData):
26986         (WebCore::DeviceController::getLastEvent):
26987
26988 2012-11-01  Yury Semikhatsky  <yurys@chromium.org>
26989
26990         Memory instrumentation: report memory occupied by ResourceRequest instead of its base ResourceRequestBase
26991         https://bugs.webkit.org/show_bug.cgi?id=100497
26992
26993         Reviewed by Alexander Pavlov.
26994
26995         Added memory reporting method to chromium implementation of ResourceRequest.
26996
26997         * platform/network/ResourceRequestBase.cpp:
26998         (WebCore::ResourceRequestBase::reportMemoryUsageBase): Renamed reportMemoryUsage
26999         on ResourceRequestBase to reportMemoryUsageBase and made it protected. I'd
27000         rather make ResourceRequestBase::reportMemoryUsage virtual and override it
27001         in the descendant but ResourceRequestBase doesn't have any virtual methods
27002         and shouldn't be used directly(ResourceRequest should be used instead).
27003         * platform/network/ResourceRequestBase.h:
27004         (ResourceRequestBase):
27005         * platform/network/chromium/ResourceRequest.cpp:
27006         (WebCore::ResourceRequest::reportMemoryUsage):
27007         (WebCore):
27008         * platform/network/chromium/ResourceRequest.h:
27009         (ResourceRequest):
27010
27011 2012-11-01  Andreas Kling  <kling@webkit.org>
27012
27013         Pack immutable StylePropertySets harder on 64-bit.
27014         <http://webkit.org/b/100753>
27015         <rdar://problem/12599155>
27016
27017         Reviewed by Antti Koivisto.
27018
27019         Move away from using CSSProperty as internal storage for immutable StylePropertySets.
27020         Instead use two arrays, one for property metadata (ID, shorthand ID, !important, ...)
27021         and one for the CSSValue pointers. This saves 4 bytes per property on 64-bit.
27022
27023         Old object layout:
27024
27025             Ref count                   (4 bytes)
27026             Metadata                    (4 bytes)
27027             CSSProperty [N]             (16 bytes each)
27028
27029         New object layout:
27030
27031             Ref count                   (4 bytes)
27032             Metadata                    (4 bytes)
27033             CSSValue* [N]               (8 bytes each)
27034             StylePropertyMetadata [N]   (4 bytes each)
27035
27036         901kB progress on Membuster3 (22% overall reduction in StylePropertySet memory.)
27037
27038         The CSSProperty class sticks around for now, it's still used in mutable StylePropertySets
27039         and by the StylePropertySet constructors.
27040
27041         * css/CSSProperty.cpp:
27042         * css/CSSProperty.h:
27043         (CSSProperty):
27044         (WebCore::CSSProperty::CSSProperty):
27045         (WebCore::CSSProperty::id):
27046         (WebCore::CSSProperty::shorthandID):
27047         (WebCore::CSSProperty::isImportant):
27048         (WebCore::CSSProperty::metadata):
27049
27050             Break the bitfield from CSSProperty out into a StylePropertyMetadata class (actually a union.)
27051
27052         * css/StylePropertySet.cpp:
27053         (WebCore::immutableStylePropertySetSize):
27054
27055             Updated size calculation for immutable StylePropertySets, 1/4 smaller!
27056
27057         (WebCore::ImmutableStylePropertySet::ImmutableStylePropertySet):
27058         (WebCore::ImmutableStylePropertySet::~ImmutableStylePropertySet):
27059         (WebCore::MutableStylePropertySet::MutableStylePropertySet):
27060         (WebCore::StylePropertySet::mergeAndOverrideOnConflict):
27061         (WebCore::StylePropertySet::reportMemoryUsage):
27062         (WebCore::StylePropertySet::PropertyReference::cssName):
27063         (WebCore::StylePropertySet::PropertyReference::cssText):
27064         * css/StylePropertySet.h:
27065         (WebCore::StylePropertySet::PropertyReference::id):
27066         (WebCore::StylePropertySet::PropertyReference::shorthandID):
27067         (WebCore::StylePropertySet::PropertyReference::isImportant):
27068         (WebCore::StylePropertySet::PropertyReference::isInherited):
27069         (WebCore::StylePropertySet::PropertyReference::isImplicit):
27070         (PropertyReference):
27071         (WebCore::StylePropertySet::PropertyReference::value):
27072         (WebCore::StylePropertySet::PropertyReference::toCSSProperty):
27073         (WebCore::StylePropertySet::PropertyReference::propertyMetadata):
27074         (WebCore::StylePropertySet::PropertyReference::propertyValue):
27075         (StylePropertySet):
27076         (ImmutableStylePropertySet):
27077         (WebCore::StylePropertySet::immutableValueArray):
27078         (WebCore::StylePropertySet::immutableMetadataArray):
27079
27080             Refactored internal storage for StylePropertySet.
27081
27082 2012-11-01  Kent Tamura  <tkent@chromium.org>
27083
27084         Remove unused Locale::parseDateTime
27085         https://bugs.webkit.org/show_bug.cgi?id=100910
27086
27087         Reviewed by Kentaro Hara.
27088
27089         For date/time input types, InputType::convertFromVisibleValue is never
27090         called. convertFromVisibleValue is called when an inner editable node is
27091         updated. However input elements don't have such editable nodes if
27092         ENABLE_INPUT_MULTIPLE_FIELDS_UI is enabled, and a user can't edit the
27093         inner editable node otherwise because we open date/time pickers when a
27094         user try to change the field value.
27095
27096         We had used convertFromVisibleValue for input[type=date] with an old UI.
27097
27098         No new tests because of no behavior changes.
27099
27100         * html/BaseDateAndTimeInputType.cpp:
27101         (WebCore::BaseDateAndTimeInputType::convertFromVisibleValue):
27102         Remove Locale::parseDateTiem and put ASSERT_NOT_REACHED.
27103
27104         * platform/text/PlatformLocale.h: Remove parseDateTime.
27105
27106         * platform/text/LocaleICU.h: Remove parseDateTime and a bogus comment.
27107         * platform/text/LocaleICU.cpp: Remove parseDateTime.
27108
27109         * platform/text/LocaleNone.cpp: Remove parseDateTime.
27110
27111         * platform/text/mac/LocaleMac.h: Remove parseDateTime.
27112         * platform/text/mac/LocaleMac.mm: Ditto.
27113         * platform/text/win/LocaleWin.h:
27114         - Remove parseDateTime, its helpers, and m_baseYear.
27115         - Remove appendNumber, appendTwoDigitsNumber, appendFourDigitsNumber,
27116           and formatDate. They don't exist.
27117         * platform/text/win/LocaleWin.cpp:
27118         Remove the above functions.
27119         (WebCore::LocaleWin::LocaleWin): Remove m_baseYear iniitalization.
27120
27121 2012-10-31  Nate Chapin  <japhet@chromium.org>
27122
27123         Remove some CachedResource::Status's in favor of looking at CachedResource::m_error
27124         https://bugs.webkit.org/show_bug.cgi?id=100901
27125
27126         Reviewed by Adam Barth.
27127
27128         No new tests, refactor only.
27129
27130         * inspector/InspectorPageAgent.cpp:
27131         (WebCore::InspectorPageAgent::buildObjectForFrameTree):
27132         * loader/DocumentThreadableLoader.cpp:
27133         (WebCore::DocumentThreadableLoader::notifyFinished):
27134         * loader/FrameLoader.cpp:
27135         (WebCore::FrameLoader::loadInSameDocument):
27136         * loader/SubresourceLoader.cpp:
27137         (WebCore::SubresourceLoader::didFail):
27138         (WebCore::SubresourceLoader::willCancel):
27139         * loader/cache/CachedResource.cpp:
27140         (WebCore::CachedResource::stopLoading):
27141         * loader/cache/CachedResource.h:
27142         (WebCore::CachedResource::wasCanceled):
27143         (WebCore::CachedResource::errorOccurred):
27144         (WebCore::CachedResource::loadFailedOrCanceled):
27145
27146 2012-10-31  Stephen White  <senorblanco@chromium.org>
27147
27148         Unreviewed, rolling out r133122.
27149         http://trac.webkit.org/changeset/133122
27150         https://bugs.webkit.org/show_bug.cgi?id=99083
27151
27152         Broke Chromium Win, Android, ChromeOS builds
27153
27154         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
27155         (WebCore::GraphicsLayerChromium::setContentsOpaque):
27156         (WebCore::GraphicsLayerChromium::paint):
27157         * platform/graphics/chromium/OpaqueRectTrackingContentLayerDelegate.cpp:
27158         (WebCore::OpaqueRectTrackingContentLayerDelegate::paintContents):
27159         * platform/graphics/chromium/OpaqueRectTrackingContentLayerDelegate.h:
27160         (OpaqueRectTrackingContentLayerDelegate):
27161
27162 2012-10-31  Takashi Sakamoto  <tasak@google.com>
27163
27164         [Refactoring] Move initial style setting for ProgressValueElement from attach method to createShadowSubtree method in HTMLProgressElement.
27165         https://bugs.webkit.org/show_bug.cgi?id=83664
27166
27167         Reviewed by Hajime Morita.
27168
27169         The original code updates inline style during attach(). However,
27170         the attach would be invoked from Element::recalcStyle()'s reattach().
27171         If updating inline styles during the reattach(), style related flags,
27172         i.e. childNeedsStyleRecalc, and needsStyleRecalc are cleared after the
27173         reattach(). So the inline styles are not updated in next
27174         setNeedsStyleRecalc, because ProgressValueElement has already had
27175         InlineStyleChange (existingChanegType == InlineStyleChange) and
27176         markAncestorsWithChildNeedsStyleRecalc is not invoked.
27177
27178         Test: fast/dom/HTMLProgressElement/progress-bar-set-value.html
27179
27180         * html/HTMLProgressElement.cpp:
27181         (WebCore::HTMLProgressElement::attach):
27182         Copied updateFromElement from didElementStateChange. If removing the
27183         update, indeterminate-progress-001.html and progress-element.html
27184         under fast/dom/HTMLProgressElement will fail. We still need attach()
27185         and updateFromElement. To remove the attach(), need more refactoring,
27186         i.e. investigating where attach() is invoked from and modifying all
27187         related codes.
27188         (WebCore::HTMLProgressElement::createShadowSubtree):
27189         Initialize m_value by indeterminate-position. The value is default
27190         value of progress element.
27191
27192 2012-10-31  Hayato Ito  <hayato@chromium.org>
27193
27194         Make resolveReprojection() defined in ComposedShadowTreeWalker.cpp callable from outside.
27195         https://bugs.webkit.org/show_bug.cgi?id=100832
27196
27197         Reviewed by Dimitri Glazkov.
27198
27199         InsertionPoint.h now defines resolveReprojection() so that it can be called from outside.
27200
27201         No new tests as no new functionality.
27202
27203         * dom/ComposedShadowTreeWalker.cpp:
27204         * html/shadow/InsertionPoint.h:
27205         (WebCore::shadowOfParentForDistribution):
27206         (WebCore):
27207         (WebCore::resolveReprojection):
27208
27209 2012-10-31  Alok Priyadarshi  <alokp@chromium.org>
27210
27211         [chromium] Pass canPaintLCDText to WebContentLayerClient::paintContents
27212         https://bugs.webkit.org/show_bug.cgi?id=99083
27213
27214         Reviewed by James Robinson.
27215
27216         Use LCD text setting passed to WebContentLayerClient::paintContents instead of turning it off for all composited layers.
27217
27218         No new tests needed. This patch does not change anything functionally.
27219
27220         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
27221         (WebCore::GraphicsLayerChromium::setContentsOpaque):
27222         (WebCore::GraphicsLayerChromium::paint):
27223         * platform/graphics/chromium/OpaqueRectTrackingContentLayerDelegate.cpp:
27224         (WebCore::OpaqueRectTrackingContentLayerDelegate::paintContents):
27225         * platform/graphics/chromium/OpaqueRectTrackingContentLayerDelegate.h:
27226         (OpaqueRectTrackingContentLayerDelegate):
27227
27228 2012-10-31  Chris Evans  <cevans@google.com>
27229
27230         RenderArena has a memory leak and poor efficiency
27231         https://bugs.webkit.org/show_bug.cgi?id=100893
27232
27233         Reviewed by Eric Seidel.
27234
27235         1) Avoid memory leak that persists for the Document lifetime by
27236         increasing recycled size buckets up to 1024. It was previously 400,
27237         and sizeof(RenderNamedFlowThread) / sizeof(RenderSVGText) both blew this
27238         quota. An assert was added to prevent this happening again.
27239
27240         2) Fix the size of the recyled size bucket array on 64-bit. We only
27241         need 8 byte granularity on 64-bit, but we had 4.
27242
27243         3) Try and pass power-of-two sizes to the underlying malloc() call, so
27244         that we're space efficient. We now take Arena metadata into account.
27245
27246         4) Double the default RenderArena size allocation to 8192 bytes. Even
27247         for a render of a trivial text file, 4096 bytes is not enough to prevent
27248         extra calls into the underlying malloc() for more arena pool.
27249
27250         * rendering/RenderArena.cpp:
27251         (WebCore::RenderArena::RenderArena): Adjust arena size so that we pass on the page-sized multiple to the underlying malloc() implementation.
27252         (WebCore::RenderArena::allocate):
27253         (WebCore::RenderArena::free): Assert that the allocation size is handled by our recycling buckets.
27254         * rendering/RenderArena.h:
27255         (WebCore): Maintain free buckets up to 1024 bytes to avoid memory leak.
27256         (RenderArena): Double the default allocation size and handle 64-bit systems more efficiently.
27257
27258 2012-10-31  Adam Barth  <abarth@webkit.org>
27259
27260         [V8] Garbage collection should use opaque roots rather than implicit references
27261         https://bugs.webkit.org/show_bug.cgi?id=100707
27262
27263         Reviewed by Kentaro Hara.
27264
27265         This patch replaces visitDOMWrapper with opaqueRootForGC. The
27266         former used to inform V8 of implicit relationships between wrapper
27267         objects on a per-wrapper basis. That meant that we needed to know which
27268         DOMDataStore a given wrapper was in during garbage collection.
27269
27270         After this patch, we now use object groups rather than implicit
27271         references to inform V8 of these relationships. That has two benefits:
27272
27273         1) We no longer need to know which DOMDataStore a wrapper belongs
27274            because we don't need to find the exact source wrapper for the
27275            implicit connection.
27276
27277         2) We can now handle more complicated implicit relationships, for
27278            example when some of the intervening objects haven't had their
27279            JavaScript wrappers created yet.
27280
27281         This patch also unlocks to paths of future development:
27282         A) Fixing the remaining failures in fast/dom/gc-9.html
27283         B) Enumerating DOM wrappers entirely from V8 rather than from the
27284            DOMWrapperMaps (so that we can move more object towards using
27285            IntrusiveDOMWrapperMaps, which aren't enumerable from WebCore).
27286
27287         * bindings/scripts/CodeGeneratorV8.pm:
27288         (NeedsCustomOpaqueRootForGC):
27289         (GenerateOpaqueRootForGC):
27290         (GenerateHeader):
27291         (GenerateImplementation):
27292         * bindings/v8/V8GCController.cpp:
27293         (ImplicitConnection):
27294         (WebCore::ImplicitConnection::ImplicitConnection):
27295         (WebCore::ImplicitConnection::root):
27296         (WebCore::ImplicitConnection::wrapper):
27297         (WebCore):
27298         (WebCore::operator<):
27299         (WrapperGrouper):
27300         (WebCore::WrapperGrouper::WrapperGrouper):
27301         (WebCore::WrapperGrouper::addToGroup):
27302         (WebCore::WrapperGrouper::keepAlive):
27303         (WebCore::WrapperGrouper::apply):
27304         (WebCore::ObjectVisitor::ObjectVisitor):
27305         (WebCore::ObjectVisitor::visitDOMWrapper):
27306         (ObjectVisitor):
27307         (WebCore::V8GCController::opaqueRootForGC):
27308         (WebCore::NodeVisitor::NodeVisitor):
27309         (WebCore::NodeVisitor::visitNodeWrapper):
27310         (NodeVisitor):
27311         (WebCore::V8GCController::majorGCPrologue):
27312         * bindings/v8/V8GCController.h:
27313         (WebCore):
27314         (V8GCController):
27315         * bindings/v8/WrapperTypeInfo.h:
27316         (WebCore):
27317         (WebCore::WrapperTypeInfo::opaqueRootForGC):
27318         (WrapperTypeInfo):
27319         * bindings/v8/custom/V8NodeListCustom.cpp:
27320         (WebCore::V8NodeList::opaqueRootForGC):
27321         * bindings/v8/custom/V8SpeechRecognitionResultCustom.cpp:
27322         (WebCore::V8SpeechRecognitionResult::opaqueRootForGC):
27323
27324 2012-10-31  Stephen White  <senorblanco@chromium.org>
27325
27326         Unreviewed, rolling out r133107.
27327         http://trac.webkit.org/changeset/133107
27328         https://bugs.webkit.org/show_bug.cgi?id=100425
27329
27330         Broke compile on Chromium Win.
27331
27332         * Modules/indexeddb/IDBCallbacks.h:
27333         (IDBCallbacks):
27334         * Modules/indexeddb/IDBDatabase.cpp:
27335         (WebCore::IDBDatabase::objectStoreNames):
27336         (WebCore::IDBDatabase::createObjectStore):
27337         (WebCore::IDBDatabase::deleteObjectStore):
27338         (WebCore::IDBDatabase::transaction):
27339         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
27340         (WebCore::IDBDatabaseBackendImpl::metadata):
27341         (WebCore::IDBDatabaseBackendImpl::createObjectStore):
27342         (WebCore::IDBDatabaseBackendImpl::objectStore):
27343         (WebCore::IDBDatabaseBackendImpl::deleteObjectStore):
27344         (WebCore::IDBDatabaseBackendImpl::transaction):
27345         (WebCore::IDBDatabaseBackendImpl::loadObjectStores):
27346         (WebCore::IDBDatabaseBackendImpl::removeObjectStoreFromMap):
27347         (WebCore::IDBDatabaseBackendImpl::addObjectStoreToMap):
27348         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
27349         (IDBDatabaseBackendImpl):
27350         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
27351         (IDBDatabaseBackendInterface):
27352         * Modules/indexeddb/IDBFactory.cpp:
27353         * Modules/indexeddb/IDBFactory.h:
27354         * Modules/indexeddb/IDBIndex.h:
27355         (WebCore::IDBIndex::openKeyCursor):
27356         * Modules/indexeddb/IDBIndexBackendInterface.h:
27357         * Modules/indexeddb/IDBKeyPath.cpp:
27358         * Modules/indexeddb/IDBMetadata.h:
27359         (WebCore):
27360         (IDBDatabaseMetadata):
27361         (WebCore::IDBDatabaseMetadata::IDBDatabaseMetadata):
27362         (IDBObjectStoreMetadata):
27363         (WebCore::IDBIndexMetadata::IDBIndexMetadata):
27364         (IDBIndexMetadata):
27365         * Modules/indexeddb/IDBObjectStore.cpp:
27366         (WebCore::IDBObjectStore::indexNames):
27367         (WebCore::IDBObjectStore::put):
27368         (WebCore::IDBObjectStore::createIndex):
27369         (WebCore::IDBObjectStore::index):
27370         (WebCore::IDBObjectStore::deleteIndex):
27371         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
27372         (WebCore::IDBObjectStoreBackendImpl::putWithIndexKeys):
27373         (WebCore):
27374         (WebCore::makeIndexWriters):
27375         (WebCore::IDBObjectStoreBackendImpl::setIndexKeys):
27376         (WebCore::IDBObjectStoreBackendImpl::setIndexesReady):
27377         (WebCore::IDBObjectStoreBackendImpl::setIndexesReadyInternal):
27378         (WebCore::IDBObjectStoreBackendImpl::putInternal):
27379         (WebCore::IDBObjectStoreBackendImpl::deleteInternal):
27380         (WebCore::IDBObjectStoreBackendImpl::createIndex):
27381         (WebCore::IDBObjectStoreBackendImpl::index):
27382         (WebCore::IDBObjectStoreBackendImpl::deleteIndex):
27383         (WebCore::IDBObjectStoreBackendImpl::loadIndexes):
27384         (WebCore::IDBObjectStoreBackendImpl::removeIndexFromMap):
27385         (WebCore::IDBObjectStoreBackendImpl::addIndexToMap):
27386         * Modules/indexeddb/IDBObjectStoreBackendImpl.h:
27387         (IDBObjectStoreBackendImpl):
27388         * Modules/indexeddb/IDBObjectStoreBackendInterface.h:
27389         * Modules/indexeddb/IDBOpenDBRequest.cpp:
27390         (WebCore::IDBOpenDBRequest::onUpgradeNeeded):
27391         * Modules/indexeddb/IDBRequest.cpp:
27392         (WebCore::IDBRequest::onSuccess):
27393         (WebCore::IDBRequest::uncaughtExceptionInEventHandler):
27394         * Modules/indexeddb/IDBTransaction.cpp:
27395         (WebCore::IDBTransaction::create):
27396         (WebCore::IDBTransaction::IDBTransaction):
27397         (WebCore::IDBTransaction::objectStore):
27398         * Modules/indexeddb/IDBTransaction.h:
27399         (IDBTransaction):
27400         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
27401         (WebCore::IDBTransactionBackendImpl::create):
27402         (WebCore::IDBTransactionBackendImpl::IDBTransactionBackendImpl):
27403         (WebCore::IDBTransactionBackendImpl::objectStore):
27404         (WebCore::IDBTransactionBackendImpl::scheduleTask):
27405         * Modules/indexeddb/IDBTransactionBackendImpl.h:
27406         (IDBTransactionBackendImpl):
27407         * Modules/indexeddb/IDBTransactionBackendInterface.h:
27408         * Modules/indexeddb/IDBTransactionCoordinator.h:
27409
27410 2012-10-31  Alec Flett  <alecflett@chromium.org>
27411
27412         IndexedDB: add methods to support id-based backend APIs
27413         https://bugs.webkit.org/show_bug.cgi?id=100425
27414
27415         Reviewed by Tony Chang.
27416
27417         First half of refactor involves adding a number of methods that
27418         are int64_t-based rather than String-based. As a part of this, the
27419         IDB*Metadata structs and the backend objectStore/index maps all
27420         use int64_t as keys, rather than String.
27421
27422         In addition, there were a number of cleanups that came out of the
27423         refactor:
27424
27425         - The list of object stores active in a transaction is now
27426           maintained by the frontend IDBTransaction rather than the backend
27427           IDBTransactionBackendImpl. This also had a simplifying rippling
27428           effect through other call signatures.
27429
27430         - I was able to remove an apparently old FIXME from
27431           IDBTransactionBackendImpl::objectStore and replace it with an ASSERT.
27432
27433         - IDBObjectStoreBackendImpl's IndexWriter class got a little
27434           simpler since the id is now easily available in the
27435           IDBIndexMetadata.
27436
27437         - A number of methods got simpler in their int64_t versions,
27438           specifically dropping a number of ExceptionCodes.
27439
27440         There is also some glue code
27441         (getIndexId/getIndexIds/getObjectStoreId) that will go away with
27442         the 2nd half of this: https://bugs.webkit.org/show_bug.cgi?id=100425
27443
27444         No new tests, no new functionality as this is just a refactor.
27445
27446         * Modules/indexeddb/IDBDatabase.cpp:
27447         (WebCore::IDBDatabase::objectStoreNames):
27448         (WebCore::IDBDatabase::createObjectStore):
27449         (WebCore::IDBDatabase::deleteObjectStore):
27450         (WebCore::IDBDatabase::transaction):
27451         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
27452         (WebCore::IDBDatabaseBackendImpl::metadata):
27453         (WebCore::IDBDatabaseBackendImpl::createObjectStore):
27454         (WebCore::IDBDatabaseBackendImpl::objectStore):
27455         (WebCore::IDBDatabaseBackendImpl::getObjectStoreId):
27456         (WebCore):
27457         (WebCore::IDBDatabaseBackendImpl::deleteObjectStore):
27458         (WebCore::IDBDatabaseBackendImpl::transaction):
27459         (WebCore::IDBDatabaseBackendImpl::loadObjectStores):
27460         (WebCore::IDBDatabaseBackendImpl::removeObjectStoreFromMap):
27461         (WebCore::IDBDatabaseBackendImpl::addObjectStoreToMap):
27462         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
27463         (WebCore::IDBDatabaseBackendImpl::deleteObjectStore):
27464         (IDBDatabaseBackendImpl):
27465         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
27466         (IDBDatabaseBackendInterface):
27467         * Modules/indexeddb/IDBIndex.h:
27468         (WebCore::IDBIndex::id):
27469         (WebCore::IDBIndex::openKeyCursor):
27470         * Modules/indexeddb/IDBIndexBackendInterface.h:
27471         * Modules/indexeddb/IDBMetadata.h:
27472         (WebCore::IDBIndexMetadata::IDBIndexMetadata):
27473         (IDBIndexMetadata):
27474         (IDBObjectStoreMetadata):
27475         (WebCore::IDBObjectStoreMetadata::containsIndex):
27476         (IDBDatabaseMetadata):
27477         (WebCore::IDBDatabaseMetadata::IDBDatabaseMetadata):
27478         (WebCore::IDBDatabaseMetadata::containsObjectStore):
27479         * Modules/indexeddb/IDBObjectStore.cpp:
27480         (WebCore::IDBObjectStore::indexNames):
27481         (WebCore::IDBObjectStore::put):
27482         (WebCore::IDBObjectStore::createIndex):
27483         (WebCore::IDBObjectStore::index):
27484         (WebCore::IDBObjectStore::deleteIndex):
27485         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
27486         (WebCore::IDBObjectStoreBackendImpl::put):
27487         (WebCore::IDBObjectStoreBackendImpl::putWithIndexKeys):
27488         (WebCore):
27489         (WebCore::makeIndexWriters):
27490         (WebCore::IDBObjectStoreBackendImpl::setIndexKeys):
27491         (WebCore::IDBObjectStoreBackendImpl::setIndexesReady):
27492         (WebCore::IDBObjectStoreBackendImpl::setIndexesReadyInternal):
27493         (WebCore::IDBObjectStoreBackendImpl::putInternal):
27494         (WebCore::IDBObjectStoreBackendImpl::deleteInternal):
27495         (WebCore::IDBObjectStoreBackendImpl::createIndex):
27496         (WebCore::IDBObjectStoreBackendImpl::index):
27497         (WebCore::IDBObjectStoreBackendImpl::getIndexId):
27498         (WebCore::IDBObjectStoreBackendImpl::getIndexIds):
27499         (WebCore::IDBObjectStoreBackendImpl::deleteIndex):
27500         (WebCore::IDBObjectStoreBackendImpl::loadIndexes):
27501         (WebCore::IDBObjectStoreBackendImpl::removeIndexFromMap):
27502         (WebCore::IDBObjectStoreBackendImpl::addIndexToMap):
27503         * Modules/indexeddb/IDBObjectStoreBackendImpl.h:
27504         (IDBObjectStoreBackendImpl):
27505         * Modules/indexeddb/IDBObjectStoreBackendInterface.h:
27506         * Modules/indexeddb/IDBOpenDBRequest.cpp:
27507         (WebCore::IDBOpenDBRequest::onUpgradeNeeded):
27508         * Modules/indexeddb/IDBRequest.cpp:
27509         (WebCore::IDBRequest::onSuccess):
27510         (WebCore::IDBRequest::uncaughtExceptionInEventHandler):
27511         * Modules/indexeddb/IDBTransaction.cpp:
27512         (WebCore::IDBTransaction::create):
27513         (WebCore::IDBTransaction::IDBTransaction):
27514         (WebCore::IDBTransaction::objectStore):
27515         * Modules/indexeddb/IDBTransaction.h:
27516         (IDBTransaction):
27517         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
27518         (WebCore::IDBTransactionBackendImpl::create):
27519         (WebCore::IDBTransactionBackendImpl::IDBTransactionBackendImpl):
27520         (WebCore::IDBTransactionBackendImpl::objectStore):
27521         (WebCore):
27522         (WebCore::IDBTransactionBackendImpl::scheduleTask):
27523         * Modules/indexeddb/IDBTransactionBackendImpl.h:
27524         (IDBTransactionBackendImpl):
27525         * Modules/indexeddb/IDBTransactionBackendInterface.h:
27526
27527 2012-10-30  Mark Lam  <mark.lam@apple.com>
27528
27529         A JSC printf (support for %J+s and %b).
27530         https://bugs.webkit.org/show_bug.cgi?id=100566.
27531
27532         Reviewed by Michael Saboff.
27533
27534         Added forwarding header for VMInspector.h.
27535
27536         No new tests needed for this.
27537
27538         * ForwardingHeaders/interpreter/VMInspector.h: Added.
27539
27540 2012-10-31  Chris Rogers  <crogers@google.com>
27541
27542         Implement optional arguments in AudioBufferSourceNode start() method
27543         https://bugs.webkit.org/show_bug.cgi?id=100894
27544
27545         Reviewed by Kenneth Russell.
27546
27547         The start() method should be able to take 1, 2, or 3 arguments, optionally supporting
27548         offset and duration.  Currently, only 1 and 3 arguments are supported.
27549
27550         Test: webaudio/audiobuffersource-start.html
27551
27552         * Modules/webaudio/AudioBufferSourceNode.cpp:
27553         (WebCore::AudioBufferSourceNode::renderFromBuffer):
27554         (WebCore::AudioBufferSourceNode::startGrain):
27555         (WebCore):
27556         * Modules/webaudio/AudioBufferSourceNode.h:
27557         (AudioBufferSourceNode):
27558         * Modules/webaudio/AudioBufferSourceNode.idl:
27559
27560 2012-10-31  Mike West  <mkwst@chromium.org>
27561
27562         Implement the canonical "Content-Security-Policy" header.
27563         https://bugs.webkit.org/show_bug.cgi?id=96765
27564
27565         Reviewed by Adam Barth.
27566
27567         The CSP 1.0 specification defines the "Content-Security-Policy" header
27568         as the canonical mechanism of defining a resource's security policy. Up
27569         through this patch, we've implemented the functionality behind a prefix
27570         in order to ensure compatibility with the standard once it's released as
27571         a recommendation. Both the specification and WebKit's implementation are
27572         far enough along in that process that it makes sense to support the
27573         unprefixed header for sites that wish to opt-in to CSP 1.0.
27574
27575         As discussed on public-webappsec[1], we'll keep the experimental 1.1
27576         features behind the prefixed header ('X-WebKit-CSP') until that standard
27577         is far enough along to justify moving them out to the canonical header.
27578
27579         This patch defines the 'Content-Security-Policy' header for all ports,
27580         just as the 'X-WebKit-CSP' header is currently supported on all ports.
27581         Ports that have not opted-in to the CSP_NEXT flag will see exactly the
27582         same behavior with both headers. Ports that have opted-in will see much
27583         of CSP 1.1's current definition on the prefixed header, and CSP 1.0 on
27584         the canonical header.
27585
27586         The functionality in this change is covered by the changes made to
27587         existing tests. No expectations changed, only the headers that are sent.
27588
27589         * dom/Document.cpp:
27590         (WebCore::Document::processHttpEquiv):
27591             Add canonical header support to 'meta' element definitions.
27592         * loader/FrameLoader.cpp:
27593         (WebCore::FrameLoader::didBeginDocument):
27594             Add canonical header support to FrameLoader.
27595         * page/ContentSecurityPolicy.cpp:
27596         (WebCore::CSPDirectiveList::headerType):
27597             The ContentSecurityPolicy::HeaderType enum now has four values:
27598             prefixed/report-only, unprefixed/report-only, prefixed/enforce, and
27599             unprefixed/enforce. Instead of creating logic to output the proper
27600             type based on internal flags, CSPDirectiveList now saves the value
27601             provided at creation time, and returns it via this method.
27602         (CSPDirectiveList):
27603         (WebCore::CSPDirectiveList::CSPDirectiveList):
27604             The constructor now accepts a type, which is stored on the object.
27605             It also stores a new internal variable, 'm_experimental', which
27606             defines whether or not experimental features ought to be available.
27607             These features are still locked behind the CSP_NEXT flag, but that
27608             might not be the case forever.
27609         (WebCore::CSPDirectiveList::create):
27610             The static constructor wrapper now passes the type into the real
27611             constructor, which also now handles setting its internal variables.
27612         (WebCore::CSPDirectiveList::parse):
27613             'parse()' is given the header, so it makes sense to store it here as
27614             well, rather than in the create wrapper.
27615         (WebCore::CSPDirectiveList::addDirective):
27616             1.1 directives remain locked behind CSP_NEXT, but now also require
27617             that 'm_experimental' is set, signaling usage of the prefixed header
27618             and an implicit opt-in to 1.1.
27619         * page/ContentSecurityPolicy.h:
27620             Added two new types to the HeaderTypes enum: PrefixedReportOnly, and
27621             PrefixedEnforcePolicy. These map to 'X-WebKitCSP-Report-Only' and
27622             'X-WebKit-CSP', respectively.
27623
27624 2012-10-31  Roger Fong  <roger_fong@apple.com>
27625
27626         Change PopupMenu positioning on Windows such that behaviour on multiple monitors matches Windows standards.
27627         https://bugs.webkit.org/show_bug.cgi?id=100317
27628
27629         Reviewed by Sam Weinig.
27630
27631         The existing code determines which screen the popup menu "belongs" to by determining which screen the owning application's hwnd belongs to,
27632         where ownership is determined by how much of the hwnd is on which screen.
27633         To match what most Windows applications do, the owning screen should be whichever screen the drop down button belongs to.
27634         To determine which screen an element belongs to in Windows we need to pass in an hwnd for that element.
27635         However, since the drop down button is something that WebKit renders there is no hwnd.
27636
27637         To remedy this issue, we can temporarily move the popup menu's hwnd to match the position and size of the button,
27638         determine the correct screen, and then eventually move it back to the correct final position after the rest of 
27639         the calculations have been completed. This is all done in the same function call so no rendering of the popup menu occurs
27640         between the temporary and final positionings.
27641
27642         There's not really a good way of testing popup menus except manually, they're separate hwnds created outside of the WebView.
27643
27644         * platform/win/PopupMenuWin.cpp:
27645         (WebCore::monitorFromHwnd):
27646         (WebCore):
27647         (WebCore::PopupMenuWin::show):
27648         (WebCore::PopupMenuWin::calculatePositionAndSize):
27649
27650 2012-10-31  Thiago Marcos P. Santos  <thiago.santos@intel.com>
27651
27652         Added viewport at-rule to the CSS parser and tokenizer
27653         https://bugs.webkit.org/show_bug.cgi?id=95961
27654
27655         Reviewed by Kenneth Rohde Christiansen.
27656
27657         Add tokens and grammar rules to parse @-webkit-viewport blocks. Also add
27658         the newly parsed rule to the rule list.
27659
27660         This parser now implements the following part of the CSS Device Adaptation
27661         specification: http://www.w3.org/TR/css-device-adapt/#syntax
27662
27663         Test: css3/device-adapt/viewport-at-rule-parsing.html
27664
27665         * CMakeLists.txt:
27666         * GNUmakefile.list.am:
27667         * Target.pri:
27668         * WebCore.gypi:
27669         * WebCore.vcproj/WebCore.vcproj:
27670         * WebCore.xcodeproj/project.pbxproj:
27671         * css/CSSGrammar.y.in:
27672         * css/CSSParser.cpp:
27673         (WebCore::CSSParser::CSSParser):
27674         (WebCore::CSSParser::detectAtToken):
27675         (WebCore):
27676         (WebCore::CSSParser::createViewportRule):
27677         * css/CSSParser.h:
27678         (CSSParser):
27679         (WebCore::CSSParser::markViewportRuleBodyStart):
27680         (WebCore::CSSParser::markViewportRuleBodyEnd):
27681         (WebCore::CSSParser::inViewport):
27682
27683             These methods are needed by the next patch validating the properties.
27684             Some viewport properties are common to other rules but have different
27685             semantics, and accepts different keywords. The validation needs to be
27686             done in a different code path.
27687
27688         * css/CSSPropertySourceData.h:
27689         * css/CSSRule.cpp:
27690         (WebCore):
27691         (WebCore::CSSRule::cssText):
27692         (WebCore::CSSRule::destroy):
27693         (WebCore::CSSRule::reattach):
27694         (WebCore::CSSRule::reportMemoryUsage):
27695         * css/CSSRule.h:
27696         (CSSRule):
27697         (WebCore::CSSRule::isViewportRule):
27698         * css/StyleRule.cpp:
27699         (WebCore::StyleRuleBase::reportMemoryUsage):
27700         (WebCore::StyleRuleBase::destroy):
27701         (WebCore::StyleRuleBase::copy):
27702         (WebCore::StyleRuleBase::createCSSOMWrapper):
27703         (WebCore):
27704         (WebCore::StyleRuleViewport::StyleRuleViewport):
27705         (WebCore::StyleRuleViewport::~StyleRuleViewport):
27706         (WebCore::StyleRuleViewport::mutableProperties):
27707         (WebCore::StyleRuleViewport::setProperties):
27708         (WebCore::StyleRuleViewport::reportDescendantMemoryUsage):
27709         * css/StyleRule.h:
27710         (StyleRuleBase):
27711         (WebCore::StyleRuleBase::isViewportRule):
27712         (WebCore):
27713         (StyleRuleViewport):
27714         (WebCore::StyleRuleViewport::create):
27715         (WebCore::StyleRuleViewport::properties):
27716         (WebCore::StyleRuleViewport::copy):
27717         * css/WebKitCSSViewportRule.cpp: Added.
27718         (WebCore):
27719         (WebCore::WebKitCSSViewportRule::WebKitCSSViewportRule):
27720         (WebCore::WebKitCSSViewportRule::~WebKitCSSViewportRule):
27721         (WebCore::WebKitCSSViewportRule::style):
27722         (WebCore::WebKitCSSViewportRule::cssText):
27723         (WebCore::WebKitCSSViewportRule::reattach):
27724         (WebCore::WebKitCSSViewportRule::reportDescendantMemoryUsage):
27725         * css/WebKitCSSViewportRule.h: Added.
27726         (WebCore):
27727
27728 2012-10-31  Max Vujovic  <mvujovic@adobe.com>
27729
27730         [CSS Shaders] Validate types of built-in uniforms
27731         https://bugs.webkit.org/show_bug.cgi?id=98974
27732
27733         Reviewed by Dean Jackson.
27734
27735         Reject shaders which define built-in uniforms with the wrong type. For example, we reject a
27736         shader with the GLSL code "uniform float u_textureSize;" because u_textureSize should be a
27737         vec2, not a float.
27738
27739         Relevant Spec Section:
27740         https://dvcs.w3.org/hg/FXTF/raw-file/tip/filters/index.html#shader-uniform-variables
27741
27742         Test: css3/filters/custom/invalid-custom-filter-uniform-types.html
27743
27744         * platform/graphics/filters/CustomFilterValidatedProgram.cpp:
27745         (WebCore):
27746         (WebCore::builtInUniformNameToTypeMap):
27747         (WebCore::validateSymbols):
27748
27749 2012-10-31  Sheriff Bot  <webkit.review.bot@gmail.com>
27750
27751         Unreviewed, rolling out r133044.
27752         http://trac.webkit.org/changeset/133044
27753         https://bugs.webkit.org/show_bug.cgi?id=100888
27754
27755         Hits an ASSERT in the isolatedWorlds tests (Requested by
27756         abarth on #webkit).
27757
27758         * bindings/scripts/CodeGeneratorV8.pm:
27759         (NeedsToVisitDOMWrapper):
27760         (GenerateVisitDOMWrapper):
27761         (GenerateHeader):
27762         (GenerateImplementation):
27763         * bindings/v8/V8GCController.cpp:
27764         (WebCore::ObjectVisitor::ObjectVisitor):
27765         (WebCore::ObjectVisitor::visitDOMWrapper):
27766         (ObjectVisitor):
27767         (WebCore::rootForGC):
27768         (ImplicitConnection):
27769         (WebCore::ImplicitConnection::ImplicitConnection):
27770         (WebCore::ImplicitConnection::root):
27771         (WebCore::ImplicitConnection::wrapper):
27772         (WebCore):
27773         (WebCore::operator<):
27774         (WebCore::NodeVisitor::NodeVisitor):
27775         (WebCore::NodeVisitor::visitNodeWrapper):
27776         (NodeVisitor):
27777         (WebCore::NodeVisitor::applyGrouping):
27778         (WebCore::V8GCController::majorGCPrologue):
27779         * bindings/v8/V8GCController.h:
27780         (V8GCController):
27781         * bindings/v8/WrapperTypeInfo.h:
27782         (WebCore):
27783         (WebCore::WrapperTypeInfo::visitDOMWrapper):
27784         (WrapperTypeInfo):
27785         * bindings/v8/custom/V8NodeListCustom.cpp:
27786         (WebCore::V8NodeList::visitDOMWrapper):
27787         * bindings/v8/custom/V8SpeechRecognitionResultCustom.cpp:
27788         (WebCore::V8SpeechRecognitionResult::visitDOMWrapper):
27789
27790 2012-10-31  Philip Rogers  <pdr@google.com>
27791
27792         Cache animationMode() in SVG animations.
27793         https://bugs.webkit.org/show_bug.cgi?id=99694
27794
27795         Reviewed by Eric Seidel.
27796
27797         This patch caches animationMode() which accounted for 25% of the CPU time of a simple
27798         animation benchmark! This is the 3rd patch for WK99694.
27799
27800         Background: SVGAnimationElement contains most of the shared animation logic for <animate>,
27801         <set>, <animateColor>, <animateTransform>, and <animateMotion>. <animateMotion> is the only
27802         animation element that can depend on other elements in the page. For example:
27803         <path id="mypath" d="M0 0 L 100 100Z"/> <!-- note, can be animated! -->
27804         <rect x="0" y="0" width="100" height="100" fill="green">
27805             <animateMotion dur="6s" repeatCount="indefinite">
27806                 <mpath xlink:href="#mypath"/>
27807             </animateMotion>
27808         </rect>
27809         See: http://www.w3.org/TR/SVG/single-page.html#animate-AnimateMotionElement
27810
27811         animationMode depends on several properties of an animation element: the set tag, whether
27812         the animation has a path, and the "values", "to", and "by" attributes. animationMode() was
27813         a hot function for two reasons:
27814         1) hasAttribute(SVGNames::valuesAttr) is expensive because we are unable to use
27815            fastHasAttribute. This is cacheable by simply calculating the animationMode when the
27816            "values" attribute changes.
27817         2) In the <animateMotion> case, determining if a path is empty or changed is expensive.
27818            AnimateMotion can have a path attribute, or it can have <mpath> children that reference
27819            a (possibly non-existent) <path> element elsewhere in the page. Before this patch we did
27820            this path lookup on every animation loop in case something changed. After this patch we
27821            only update AnimateMotion's path when it changes.
27822
27823         A previous patch, http://trac.webkit.org/changeset/132847, laid the groundwork for tracking
27824         <path> changes in <mpath>. This patch adds <mpath> to our resource tracking infrastructure
27825         to track when target <path>s change, instead of looking this up every time.
27826
27827         This refactoring is covered by existing tests.
27828         svg/animations/mozilla/animateMotion-mpath-targetChange-1.svg fails after this patch
27829         because our element dependency tracking has a bug with duplicate ids; see WK99893.
27830
27831         * svg/SVGAnimateMotionElement.cpp:
27832         (WebCore::SVGAnimateMotionElement::parseAttribute):
27833         (WebCore::SVGAnimateMotionElement::updateAnimationPath):
27834
27835             animationPath() has been changed to updateAnimationPath() and should only be called
27836             when the animation path (path attribute, or mpath's referenced path) has changed.
27837
27838         (WebCore::SVGAnimateMotionElement::buildTransformForProgress):
27839         (WebCore::SVGAnimateMotionElement::updateAnimationMode):
27840
27841             If an animationPath exists, we use PathAnimation, otherwise we fall back to the normal
27842             updateAnimationMode() codepath.
27843
27844         (WebCore):
27845         * svg/SVGAnimateMotionElement.h:
27846         (SVGAnimateMotionElement):
27847         * svg/SVGAnimationElement.cpp:
27848         (WebCore::SVGAnimationElement::SVGAnimationElement):
27849         (WebCore::SVGAnimationElement::isSupportedAttribute):
27850         (WebCore::SVGAnimationElement::parseAttribute):
27851
27852             The from, by, and to attributes have been added so that we can track when they change
27853             and update the animation mode. Similarly for when the values attribute changes.
27854
27855         (WebCore::SVGAnimationElement::updateAnimationMode):
27856         * svg/SVGAnimationElement.h:
27857         (WebCore::SVGAnimationElement::animationMode):
27858         (SVGAnimationElement):
27859         (WebCore::SVGAnimationElement::setAnimationMode):
27860         (WebCore::SVGAnimationElement::calculateDistance):
27861         * svg/SVGMPathElement.cpp:
27862         (WebCore::SVGMPathElement::buildPendingResource):
27863
27864             It would be nice to move all the duplicated buildPendingResource() logic into a central
27865             place (SVGURIReference?) but for now it is copied. This function is nearly identical to
27866             SVGFEImageElement::buildPendingResource.
27867
27868         (WebCore):
27869         (WebCore::SVGMPathElement::clearResourceReferences):
27870         (WebCore::SVGMPathElement::insertedInto):
27871         (WebCore::SVGMPathElement::removedFrom):
27872         (WebCore::SVGMPathElement::svgAttributeChanged):
27873         (WebCore::SVGMPathElement::targetPathChanged):
27874         (WebCore::SVGMPathElement::notifyParentOfPathChange):
27875         * svg/SVGMPathElement.h:
27876         (SVGMPathElement):
27877         * svg/SVGPathElement.cpp:
27878
27879             When a <path>'s path changes, we need to notify any dependent <mpath> elements. This is
27880             typically handled with RenderSVGResource::markForLayoutAndParentResourceInvalidation
27881             but for the special-case of <mpath> we only need to track when the path's "d" attribute
27882             changes so invalidateMPathDependencies() has been added.
27883
27884         (WebCore::SVGPathElement::svgAttributeChanged):
27885         (WebCore::SVGPathElement::invalidateMPathDependencies):
27886         (WebCore):
27887         (WebCore::SVGPathElement::insertedInto):
27888         (WebCore::SVGPathElement::removedFrom):
27889         * svg/SVGPathElement.h:
27890         (SVGPathElement):
27891         * svg/SVGSetElement.cpp:
27892         (WebCore::SVGSetElement::SVGSetElement):
27893         (WebCore::SVGSetElement::updateAnimationMode):
27894         (WebCore):
27895         * svg/SVGSetElement.h:
27896         (SVGSetElement):
27897         * svg/animation/SVGSMILElement.cpp:
27898         (WebCore::SVGSMILElement::isSupportedAttribute):
27899
27900 2012-10-31  Beth Dakin  <bdakin@apple.com>
27901
27902         https://bugs.webkit.org/show_bug.cgi?id=100879
27903         ScrollingStateNode::cloneAndResetNode() should not be virtual
27904
27905         Reviewed by Simon Fraser.
27906
27907         cloneAndResetNode() is currently pure virtual and implemented only 
27908         in ScrollingStateScrollingNode. However, all of the work that it 
27909         does at this time is stuff that a generic ScrollingStateNode could 
27910         do. We should move this implementation to the base class so that it 
27911         does not need to be duplicated for future node types.
27912
27913         This patch also re-names cloneAndResetNode() to cloneAndReset()
27914         and correspondingly re-names cloneAndResetChildNodes() to 
27915         cloneAndResetChildren(). 
27916
27917         Finally the patch also changes the copy constructors of both of these 
27918         classes to take a const reference instead of a pointer.
27919
27920         * page/scrolling/ScrollingStateNode.cpp:
27921         (WebCore::ScrollingStateNode::ScrollingStateNode):
27922         (WebCore::ScrollingStateNode::cloneAndReset):
27923         (WebCore):
27924         (WebCore::ScrollingStateNode::cloneAndResetChildren):
27925         * page/scrolling/ScrollingStateNode.h:
27926         (ScrollingStateNode):
27927         * page/scrolling/ScrollingStateScrollingNode.cpp:
27928         (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
27929         (WebCore):
27930         * page/scrolling/ScrollingStateScrollingNode.h:
27931         (ScrollingStateScrollingNode):
27932         * page/scrolling/ScrollingStateTree.cpp:
27933         (WebCore::ScrollingStateTree::commit):
27934
27935 2012-10-31  Tom Sepez  <tsepez@chromium.org>
27936         
27937         Malformed X-XSS-Protection headers not reported.
27938         https://bugs.webkit.org/show_bug.cgi?id=100538
27939
27940         Reviewed by Adam Barth.
27941
27942         Re-writes X-XSS-Protection header parser to be more particular, and to
27943         return better information on error.
27944
27945         Tests: http/tests/security/xssAuditor/malformed-xss-protection-header-1.html
27946                http/tests/security/xssAuditor/malformed-xss-protection-header-2.html
27947                http/tests/security/xssAuditor/malformed-xss-protection-header-4.html
27948                http/tests/security/xssAuditor/xss-protection-parsing-02.html
27949
27950         * html/parser/XSSAuditor.cpp:
27951         (WebCore::XSSAuditor::init):
27952         Detect error return code and log console message with details
27953         * platform/network/HTTPParsers.cpp:
27954         (WebCore):
27955         (WebCore::skipWhiteSpace):
27956         Use safe less-than comparsion in case called with pos already out of range.
27957         (WebCore::skipToken):
27958         Fix comparison to properly reject substrings at end of input.  Prevent advancing
27959         returned position when match fails, so that this may someday be used to match
27960         optional tokens.
27961         (WebCore::parseXSSProtectionHeader):
27962         Return detailled error status. Avoid needless string copy.
27963         * platform/network/HTTPParsers.h:
27964         Add new error returns for x-xss-protection header parser.
27965         
27966 2012-10-31  Simon Fraser  <simon.fraser@apple.com>
27967
27968         REGRESSION (tile cache layers): bits of tiled layers are missing with certain 3D transforms
27969         https://bugs.webkit.org/show_bug.cgi?id=100808
27970         <rdar://problem/12562541>
27971
27972         Reviewed by Dean Jackson.
27973
27974         When projecting rects down into transformed layers, the projection can fail with severe
27975         3D rotations if the computed w component in TransformationMatrix::projectPoint() is negative.
27976         In this case we already clamp, but the fact that we clamped doesn't make it out to
27977         GraphicsLayerCA::computeVisibleRect() which resulted in incorrect visible rects being
27978         computed.
27979         
27980         Fix by propagating the fact that clamping occurred out of the TransformState functions
27981         which can clamp. In computeVisibleRect(), simply consider the entire layer bounds
27982         to be visible if clamping occurred.
27983
27984         Tests: compositing/tiling/rotated-tiled-clamped.html
27985                compositing/tiling/rotated-tiled-preserve3d-clamped.html
27986
27987         * platform/graphics/ca/GraphicsLayerCA.cpp:
27988         (WebCore::GraphicsLayerCA::computeVisibleRect): If either the applyTransform()
27989         or the state.mappedQuad() clamped, use our bounds as the visible rect.
27990         * platform/graphics/transforms/TransformState.cpp:
27991         (WebCore::TransformState::applyTransform): Pass out clamping state.
27992         (WebCore::TransformState::flatten): Ditto.
27993         (WebCore::TransformState::mappedPoint): Ditto.
27994         (WebCore::TransformState::mappedQuad): Ditto.
27995         (WebCore::TransformState::flattenWithTransform): Ditto. No need to initialize
27996         wasClamped, since this function is internal.
27997         * platform/graphics/transforms/TransformState.h:
27998         (TransformState):
27999         * platform/graphics/transforms/TransformationMatrix.cpp:
28000         (WebCore::TransformationMatrix::projectQuad): If any point projection clamped,
28001         set the flag to say we clamped.
28002         * platform/graphics/transforms/TransformationMatrix.h:
28003         (TransformationMatrix):
28004
28005 2012-10-31  Tiancheng Jiang  <tijiang@rim.com>
28006
28007         Change bubble message style to BB10 UX spec.
28008         https://bugs.webkit.org/show_bug.cgi?id=100862
28009
28010         Reviewed by Rob Buis.
28011
28012         RIM PR 198108
28013         Internal Reviewed by Otto Cheung.
28014         No new tests.
28015
28016         * css/themeBlackBerry.css:
28017         (::-webkit-validation-bubble-message): Added.
28018         (::-webkit-validation-bubble-arrow): Added.
28019         (::-webkit-validation-bubble-heading): Added.
28020
28021 2012-10-31  Mike West  <mkwst@chromium.org>
28022
28023         Prefer document->addConsoleMessage to document->domWindow->console->addMessage.
28024         https://bugs.webkit.org/show_bug.cgi?id=100850
28025
28026         Reviewed by Adam Barth.
28027
28028         For historical reasons, a few places in WebCore talk to Console directly
28029         via 'document()->domWindow()->console()->addMessage(...)'. This is more
28030         safely wrapped by calling 'addConsoleMessage' on the Document itself.
28031
28032         No visible functionality should change; we'll simply avoid potential
28033         null dereferences in the future.
28034
28035         * html/HTMLFormElement.cpp:
28036         (WebCore::HTMLFormElement::validateInteractively):
28037         * html/canvas/WebGLRenderingContext.cpp:
28038         (WebCore):
28039         (WebCore::WebGLRenderingContext::printWarningToConsole):
28040         * loader/FrameLoader.cpp:
28041         (WebCore::FrameLoader::reportLocalLoadFailed):
28042         * loader/MixedContentChecker.cpp:
28043         (WebCore::MixedContentChecker::logWarning):
28044         * loader/appcache/ApplicationCacheGroup.cpp:
28045         (WebCore::ApplicationCacheGroup::abort):
28046         (WebCore::ApplicationCacheGroup::didReceiveResponse):
28047         (WebCore::ApplicationCacheGroup::didFinishLoading):
28048         (WebCore::ApplicationCacheGroup::didFail):
28049         (WebCore::ApplicationCacheGroup::didReceiveManifestResponse):
28050         (WebCore::ApplicationCacheGroup::didFinishLoadingManifest):
28051         (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete):
28052         * loader/cache/CachedResourceLoader.cpp:
28053         (WebCore::CachedResourceLoader::printAccessDeniedMessage):
28054
28055 2012-10-31  Pavel Feldman  <pfeldman@chromium.org>
28056
28057         Web Inspector: frame chooser does not work on subsequent inspector open.
28058         https://bugs.webkit.org/show_bug.cgi?id=100771
28059
28060         Reviewed by Yury Semikhatsky.
28061
28062         - Make WorkerRuntimeAgent and PageRuntimeAgent register themselves in the instrumenting agents independently
28063         - Move pause / run worker handling from InspectorRuntimeAgent into WorkerRuntimeAgent
28064         - Remove remains of the front-end reused signal from InspectorAgent
28065         - Send execution contexts post clear window object instead of post commit load.
28066
28067         * inspector/InspectorAgent.cpp:
28068         (WebCore::InspectorAgent::InspectorAgent):
28069         (WebCore::InspectorAgent::clearFrontend):
28070         (WebCore::InspectorAgent::didCommitLoad):
28071         * inspector/InspectorAgent.h:
28072         (InspectorAgent):
28073         * inspector/InspectorInstrumentation.cpp:
28074         (WebCore):
28075         (WebCore::InspectorInstrumentation::didClearWindowObjectInWorldImpl):
28076         (WebCore::InspectorInstrumentation::willEvaluateWorkerScript):
28077         * inspector/InspectorInstrumentation.h:
28078         (InspectorInstrumentation):
28079         * inspector/InspectorPageAgent.cpp:
28080         (WebCore::InspectorPageAgent::restore):
28081         * inspector/InspectorRuntimeAgent.cpp:
28082         (WebCore::InspectorRuntimeAgent::InspectorRuntimeAgent):
28083         (WebCore::InspectorRuntimeAgent::~InspectorRuntimeAgent):
28084         (WebCore::InspectorRuntimeAgent::run):
28085         (WebCore::InspectorRuntimeAgent::setScriptDebugServer):
28086         * inspector/InspectorRuntimeAgent.h:
28087         (InspectorRuntimeAgent):
28088         * inspector/InstrumentingAgents.h:
28089         (WebCore):
28090         (WebCore::InstrumentingAgents::InstrumentingAgents):
28091         (WebCore::InstrumentingAgents::workerRuntimeAgent):
28092         (WebCore::InstrumentingAgents::setWorkerRuntimeAgent):
28093         (InstrumentingAgents):
28094         * inspector/PageRuntimeAgent.cpp:
28095         (WebCore::PageRuntimeAgent::PageRuntimeAgent):
28096         (WebCore::PageRuntimeAgent::~PageRuntimeAgent):
28097         (WebCore::PageRuntimeAgent::setFrontend):
28098         (WebCore::PageRuntimeAgent::clearFrontend):
28099         (WebCore::PageRuntimeAgent::enable):
28100         (WebCore::PageRuntimeAgent::didCreateMainWorldContext):
28101         * inspector/PageRuntimeAgent.h:
28102         (PageRuntimeAgent):
28103         * inspector/WorkerRuntimeAgent.cpp:
28104         (WebCore::WorkerRuntimeAgent::WorkerRuntimeAgent):
28105         (WebCore::WorkerRuntimeAgent::~WorkerRuntimeAgent):
28106         (WebCore::WorkerRuntimeAgent::run):
28107         (WebCore):
28108         (WebCore::WorkerRuntimeAgent::pauseWorkerContext):
28109         * inspector/WorkerRuntimeAgent.h:
28110         (WorkerRuntimeAgent):
28111
28112 2012-10-31  Kondapally Kalyan  <kalyan.kondapally@intel.com>
28113
28114         [Qt][EFL][AC][WK2]TextureMapperLayer backing store contents are drawn upside down on screen.
28115         https://bugs.webkit.org/show_bug.cgi?id=100845.
28116
28117         Reviewed by Noam Rosenthal.
28118
28119         WebGL displays the Canvas with (0,0) being the bottom left corner.
28120         In GraphicsSurface::platformPaintToTextureMapper we don't set ShouldFlipTexture
28121         flag before painting to TextureMapper.
28122         It results in backing store contents being drawn upside down on screen.
28123         This patch enables ShouldFlipTexture flag when TextureMapperLayer renders 
28124         it's backing store contents into a TextureMapper.
28125
28126         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
28127         (WebCore::GraphicsSurface::platformPaintToTextureMapper):
28128
28129 2012-10-31  Noam Rosenthal  <noam.rosenthal@nokia.com>
28130
28131         [Texmap] Enable filter animations in GraphicsLayerAnimation
28132         https://bugs.webkit.org/show_bug.cgi?id=100318
28133
28134         Reviewed by Kenneth Rohde Christiansen.
28135
28136         Use the same method of animating filters in WebCore to animate filters for TextureMapper.
28137         Added the appropriate methods to GraphicsLayerAnimation and TextureMapperLayer.
28138
28139         Tested by LayoutTests/css3/filters/filter-animation-hw.html and other tests.
28140
28141         * platform/graphics/GraphicsLayerAnimation.cpp:
28142         (WebCore):
28143         (WebCore::blendFunc):
28144         (WebCore::applyFilterAnimation):
28145         (WebCore::GraphicsLayerAnimation::applyInternal):
28146         * platform/graphics/GraphicsLayerAnimation.h:
28147         (Client):
28148         * platform/graphics/texmap/TextureMapperLayer.cpp:
28149         (WebCore::TextureMapperLayer::intermediateSurfaceRect):
28150         (WebCore::TextureMapperLayer::shouldPaintToIntermediateSurface):
28151         (WebCore::TextureMapperLayer::paintRecursive):
28152         (WebCore::TextureMapperLayer::syncAnimations):
28153         * platform/graphics/texmap/TextureMapperLayer.h:
28154         (TextureMapperLayer):
28155         (WebCore::TextureMapperLayer::setFilters):
28156         (WebCore::TextureMapperLayer::setAnimatedFilters):
28157
28158 2012-10-31  Adam Barth  <abarth@webkit.org>
28159
28160         [V8] Garbage collection should use opaque roots rather than implicit references
28161         https://bugs.webkit.org/show_bug.cgi?id=100707
28162
28163         Reviewed by Kentaro Hara.
28164
28165         This patch replaces visitDOMWrapper with opaqueRootForGC. The
28166         former used to inform V8 of implicit relationships between wrapper
28167         objects on a per-wrapper basis. That meant that we needed to know which
28168         DOMDataStore a given wrapper was in during garbage collection.
28169
28170         After this patch, we now use object groups rather than implicit
28171         references to inform V8 of these relationships. That has two benefits:
28172
28173         1) We no longer need to know which DOMDataStore a wrapper belongs
28174            because we don't need to find the exact source wrapper for the
28175            implicit connection.
28176
28177         2) We can now handle more complicated implicit relationships, for
28178            example when some of the intervening objects haven't had their
28179            JavaScript wrappers created yet.
28180
28181         This patch also unlocks to paths of future development:
28182         A) Fixing the remaining failures in fast/dom/gc-9.html
28183         B) Enumerating DOM wrappers entirely from V8 rather than from the
28184            DOMWrapperMaps (so that we can move more object towards using
28185            IntrusiveDOMWrapperMaps, which aren't enumerable from WebCore).
28186
28187         * bindings/scripts/CodeGeneratorV8.pm:
28188         (NeedsCustomOpaqueRootForGC):
28189         (GenerateOpaqueRootForGC):
28190         (GenerateHeader):
28191         (GenerateImplementation):
28192         * bindings/v8/V8GCController.cpp:
28193         (ImplicitConnection):
28194         (WebCore::ImplicitConnection::ImplicitConnection):
28195         (WebCore::ImplicitConnection::root):
28196         (WebCore::ImplicitConnection::wrapper):
28197         (WebCore):
28198         (WebCore::operator<):
28199         (WrapperGrouper):
28200         (WebCore::WrapperGrouper::WrapperGrouper):
28201         (WebCore::WrapperGrouper::addToGroup):
28202         (WebCore::WrapperGrouper::keepAlive):
28203         (WebCore::WrapperGrouper::apply):
28204         (WebCore::ObjectVisitor::ObjectVisitor):
28205         (WebCore::ObjectVisitor::visitDOMWrapper):
28206         (ObjectVisitor):
28207         (WebCore::V8GCController::opaqueRootForGC):
28208         (WebCore::NodeVisitor::NodeVisitor):
28209         (WebCore::NodeVisitor::visitNodeWrapper):
28210         (NodeVisitor):
28211         (WebCore::V8GCController::majorGCPrologue):
28212         * bindings/v8/V8GCController.h:
28213         (WebCore):
28214         (V8GCController):
28215         * bindings/v8/WrapperTypeInfo.h:
28216         (WebCore):
28217         (WebCore::WrapperTypeInfo::opaqueRootForGC):
28218         (WrapperTypeInfo):
28219         * bindings/v8/custom/V8NodeListCustom.cpp:
28220         (WebCore::V8NodeList::opaqueRootForGC):
28221         * bindings/v8/custom/V8SpeechRecognitionResultCustom.cpp:
28222         (WebCore::V8SpeechRecognitionResult::opaqueRootForGC):
28223
28224 2012-10-31  Alexei Filippov  <alph@chromium.org>
28225
28226         Web Inspector: Add total node to native memory snapshot tree
28227         https://bugs.webkit.org/show_bug.cgi?id=100843
28228
28229         Reviewed by Yury Semikhatsky.
28230
28231         * inspector/front-end/NativeMemorySnapshotView.js:
28232         (WebInspector.NativeSnapshotDataGrid):
28233         (WebInspector.NativeSnapshotNode):
28234         (WebInspector.MemoryBlockViewProperties._initialize):
28235
28236 2012-10-31  Arpita Bahuguna  <arpitabahuguna@gmail.com>
28237
28238         Table with percentage column widths doesn't scale to fill the entire width of a table containing it
28239         https://bugs.webkit.org/show_bug.cgi?id=11645
28240
28241         Reviewed by Julien Chaffraix.
28242
28243         When the inner (or nested) table has auto width and column(s) with
28244         percent width, we should scale our column(s) to the width of the
28245         containing table (unless it has auto width).
28246
28247         Test: fast/table/scale-nested-percent-width-cols.html
28248
28249         * rendering/AutoTableLayout.cpp:
28250         (WebCore::shouldScaleColumns):
28251         If the containing table width was of percent type, we were disallowing
28252         our inner or nested table's column from scaling to the size of the parent
28253         table. We should prohibit the scaling of the nested table columns only
28254         if the parent table has auto width.
28255
28256 2012-10-31  Ian Vollick  <vollick@chromium.org>
28257
28258         Add support for text-based repaint testing
28259         https://bugs.webkit.org/show_bug.cgi?id=100584
28260
28261         Reviewed by Simon Fraser.
28262
28263         Allows tracked repaint rects to be dumped as text.
28264
28265         The following layout tests have been converted:
28266           fast/repaint/layer-full-repaint.html
28267           fast/repaint/overflow-flipped-writing-mode-table.html
28268
28269         * WebCore.exp.in:
28270           Exports for:
28271             FrameView::setTracksRepaints(bool)
28272             Frame::trackedRepaintRectsAsText() const
28273         * page/Frame.cpp:
28274         (WebCore::Frame::trackedRepaintRectsAsText):
28275           Returns a string containing information on all tracked repaint rects.
28276         * page/FrameView.cpp:
28277         (WebCore::FrameView::setTracksRepaints):
28278           Rather than calling m_trackedRepaintRects.clear() directly, I've
28279           called resetTrackedRepaints(). This will allow us to do more
28280           sophisticated resetting when we start tracking repaint rects for
28281           composited layers.
28282         (WebCore::FrameView::trackedRepaintRectsAsText):
28283           Provides the string returned by Frame::trackedRepaintRectsAsText.
28284         * testing/Internals.cpp:
28285         (WebCore::Internals::repaintRectsAsText):
28286           Returns Frame::trackedRepaintRectsAsText.
28287         (WebCore):
28288         (WebCore::Internals::startTrackingRepaints):
28289           Calls FrameView::setTracksRepaints(true)
28290         (WebCore::Internals::stopTrackingRepaints):
28291           Calls FrameView::setTracksRepaints(false)
28292         * testing/Internals.h:
28293         * testing/Internals.idl:
28294           Declarations for:
28295             repaintRectsAsText
28296             startTrackingRepaints
28297             stopTrackingRepaints
28298
28299 2012-10-31  Yury Semikhatsky  <yurys@chromium.org>
28300
28301         Web Inspector: page crash when pausing in dedicated worker
28302         https://bugs.webkit.org/show_bug.cgi?id=100837
28303
28304         Reviewed by Pavel Feldman.
28305
28306         Pass debugger agent to InjectedScriptHost::init in case of workers.
28307
28308         Test: inspector-protocol/debugger-pause-dedicated-worker.html
28309
28310         * inspector/WorkerInspectorController.cpp:
28311         (WebCore::WorkerInspectorController::WorkerInspectorController):
28312
28313 2012-10-31  Zoltan Nyul  <zoltan.nyul@intel.com>
28314
28315         perspective-origin should ignore values with more then two lengths and use the default values
28316         https://bugs.webkit.org/show_bug.cgi?id=100835
28317
28318         Reviewed by Kenneth Rohde Christiansen.
28319
28320         Perspective-origin should ignore values with more then two lengths
28321         (http://www.w3.org/TR/css3-transforms/#perspective-origin) and use
28322         the default values instead of parsing it as an unlimited-length list,
28323         of which all but the first two values are ignored. This makes perspective-origin 
28324         behave similar to transform-origin which uses default value in this case,
28325         as well as firefox does the same.
28326
28327         Test: transforms/2d/computed-style-origin.html
28328
28329         * css/CSSParser.cpp:
28330         (WebCore::CSSParser::parsePerspectiveOrigin):
28331
28332 2012-10-31  Sheriff Bot  <webkit.review.bot@gmail.com>
28333
28334         Unreviewed, rolling out r133016.
28335         http://trac.webkit.org/changeset/133016
28336         https://bugs.webkit.org/show_bug.cgi?id=100856
28337
28338         broke compile-webkit on several bots (Requested by podivilov
28339         on #webkit).
28340
28341         * CMakeLists.txt:
28342         * GNUmakefile.list.am:
28343         * Target.pri:
28344         * WebCore.gypi:
28345         * WebCore.vcproj/WebCore.vcproj:
28346         * WebCore.xcodeproj/project.pbxproj:
28347         * dom/DeviceOrientationClient.h:
28348         (DeviceOrientationClient):
28349         * dom/DeviceOrientationController.cpp:
28350         (WebCore::DeviceOrientationController::DeviceOrientationController):
28351         (WebCore):
28352         (WebCore::DeviceOrientationController::~DeviceOrientationController):
28353         (WebCore::DeviceOrientationController::timerFired):
28354         (WebCore::DeviceOrientationController::addListener):
28355         (WebCore::DeviceOrientationController::removeListener):
28356         (WebCore::DeviceOrientationController::removeAllListeners):
28357         (WebCore::DeviceOrientationController::suspendEventsForAllListeners):
28358         (WebCore::DeviceOrientationController::resumeEventsForAllListeners):
28359         (WebCore::DeviceOrientationController::didChangeDeviceOrientation):
28360         (WebCore::DeviceOrientationController::supplementName):
28361         * dom/DeviceOrientationController.h:
28362         (WebCore):
28363         (DeviceOrientationController):
28364         (WebCore::DeviceOrientationController::isActive):
28365         (WebCore::DeviceOrientationController::client):
28366         (WebCore::DeviceOrientationController::from):
28367         * dom/Document.cpp:
28368         (WebCore::Document::suspendActiveDOMObjects):
28369         (WebCore::Document::resumeActiveDOMObjects):
28370         * loader/EmptyClients.h:
28371         (WebCore::EmptyDeviceOrientationClient::startUpdating):
28372         (WebCore::EmptyDeviceOrientationClient::stopUpdating):
28373         * page/DOMWindow.cpp:
28374         (WebCore::DOMWindow::addEventListener):
28375         (WebCore::DOMWindow::removeEventListener):
28376         (WebCore::DOMWindow::removeAllEventListeners):
28377         * page/DeviceClient.h: Removed.
28378         * page/DeviceController.cpp: Removed.
28379         * page/DeviceController.h: Removed.
28380
28381 2012-10-31  Antti Koivisto  <antti@apple.com>
28382
28383         Remove stray calls to mutableAttributeData()
28384         https://bugs.webkit.org/show_bug.cgi?id=100849
28385
28386         Reviewed by Andreas Kling.
28387
28388         Changing the cached class attribute value does not require mutable attribute data.
28389
28390         * dom/Element.cpp:
28391         (WebCore::Element::classAttributeChanged):
28392         * dom/ElementAttributeData.h:
28393         (WebCore::ElementAttributeData::clearClass):
28394         
28395             Make const like setClass().
28396
28397 2012-10-31  Mike West  <mkwst@chromium.org>
28398
28399         X-Frame-Options console message should be associated with a request.
28400         https://bugs.webkit.org/show_bug.cgi?id=100735
28401
28402         Reviewed by Pavel Feldman.
28403
28404         In 99941, we added the possibility to tie console messages to requests,
28405         which enables automatic generation of stack traces, line numbers, etc.
28406         making the error simpler to diagnose for web developers. This patch
28407         uses the piping laid in that patch to improve the console message
28408         generated when a document is blocked by X-Frame-Options.
28409
28410         No new tests; the functionality is covered by changes to existing tests.
28411
28412         * dom/Document.cpp:
28413         (WebCore::Document::processHttpEquiv):
28414             Grab the request identifier from the currently active DocumentLoader
28415             and pass it into the console message.
28416         * loader/MainResourceLoader.cpp:
28417         (WebCore::MainResourceLoader::didReceiveResponse):
28418             Grab the request identifier from the MainResourceLoader, and pass it
28419             into the console message.
28420
28421 2012-10-31  Sheriff Bot  <webkit.review.bot@gmail.com>
28422
28423         Unreviewed, rolling out r133015.
28424         http://trac.webkit.org/changeset/133015
28425         https://bugs.webkit.org/show_bug.cgi?id=100847
28426
28427         broke Apple Win Debug compilation (Requested by podivilov on
28428         #webkit).
28429
28430         * inspector/InspectorAgent.cpp:
28431         (WebCore::InspectorAgent::InspectorAgent):
28432         (WebCore::InspectorAgent::clearFrontend):
28433         (WebCore::InspectorAgent::didCommitLoad):
28434         * inspector/InspectorAgent.h:
28435         (WebCore::InspectorAgent::didCommitLoadFired):
28436         (InspectorAgent):
28437         * inspector/InspectorInstrumentation.cpp:
28438         (WebCore):
28439         (WebCore::InspectorInstrumentation::didClearWindowObjectInWorldImpl):
28440         (WebCore::InspectorInstrumentation::willEvaluateWorkerScript):
28441         (WebCore::InspectorInstrumentation::runtimeAgentEnabled):
28442         * inspector/InspectorInstrumentation.h:
28443         (InspectorInstrumentation):
28444         * inspector/InspectorPageAgent.cpp:
28445         (WebCore::InspectorPageAgent::restore):
28446         * inspector/InspectorRuntimeAgent.cpp:
28447         (WebCore::InspectorRuntimeAgent::InspectorRuntimeAgent):
28448         (WebCore::InspectorRuntimeAgent::~InspectorRuntimeAgent):
28449         (WebCore::InspectorRuntimeAgent::run):
28450         (WebCore):
28451         (WebCore::InspectorRuntimeAgent::pauseWorkerContext):
28452         * inspector/InspectorRuntimeAgent.h:
28453         (InspectorRuntimeAgent):
28454         * inspector/InstrumentingAgents.h:
28455         (WebCore):
28456         (WebCore::InstrumentingAgents::InstrumentingAgents):
28457         (WebCore::InstrumentingAgents::inspectorRuntimeAgent):
28458         (WebCore::InstrumentingAgents::setInspectorRuntimeAgent):
28459         (InstrumentingAgents):
28460         * inspector/PageRuntimeAgent.cpp:
28461         (WebCore::PageRuntimeAgent::PageRuntimeAgent):
28462         (WebCore::PageRuntimeAgent::~PageRuntimeAgent):
28463         (WebCore::PageRuntimeAgent::setFrontend):
28464         (WebCore::PageRuntimeAgent::clearFrontend):
28465         (WebCore::PageRuntimeAgent::enable):
28466         (WebCore::PageRuntimeAgent::didClearWindowObject):
28467         * inspector/PageRuntimeAgent.h:
28468         (PageRuntimeAgent):
28469         * inspector/WorkerRuntimeAgent.cpp:
28470         (WebCore::WorkerRuntimeAgent::WorkerRuntimeAgent):
28471         (WebCore::WorkerRuntimeAgent::~WorkerRuntimeAgent):
28472         * inspector/WorkerRuntimeAgent.h:
28473         (WorkerRuntimeAgent):
28474
28475 2012-10-31  Kihong Kwon  <kihong.kwon@samsung.com>
28476
28477         Add DeviceController base-class to remove duplication of DeviceXXXControler
28478         https://bugs.webkit.org/show_bug.cgi?id=96894
28479
28480         Reviewed by Hajime Morita.
28481
28482         Add DeviceController which is extracted from DeviceOrientationController to remove duplication.
28483         And soon-to-be-added DeviceMotionController and ProximityController.
28484
28485         Covered by existing tests.
28486
28487         * CMakeLists.txt:
28488         * GNUmakefile.list.am:
28489         * Target.pri:
28490         * WebCore.gypi:
28491         * WebCore.vcproj/WebCore.vcproj:
28492         * WebCore.xcodeproj/project.pbxproj:
28493         * dom/DeviceOrientationClient.h:
28494         * dom/DeviceOrientationController.cpp:
28495         Remove member functions to move to DeviceController.
28496         - addListener(), removeListener(), removeAllListeners(), isActive()
28497         (WebCore::DeviceOrientationController::DeviceOrientationController):
28498         (WebCore::DeviceOrientationController::didChangeDeviceOrientation):
28499         (WebCore::DeviceOrientationController::client):
28500         (WebCore::DeviceOrientationController::hasLastData):
28501         (WebCore::DeviceOrientationController::getLastEvent):
28502         (WebCore::DeviceOrientationController::from):
28503         (WebCore):
28504         * dom/DeviceOrientationController.h:
28505         (WebCore):
28506         (WebCore::DeviceOrientationController::~DeviceOrientationController):
28507         (DeviceOrientationController):
28508         * dom/Document.cpp:
28509         Remove suspendEventsForAllListeners() and resumeEventsForAllListeners() function calls.
28510         These calls can be made by checking activeDOMObjectsAreSuspended() and activeDOMObjectsAreStopped() before dispatchEvent.
28511         (WebCore::Document::suspendActiveDOMObjects):
28512         (WebCore::Document::resumeActiveDOMObjects):
28513         * loader/EmptyClients.h:
28514         (EmptyDeviceClient):
28515         (WebCore::EmptyDeviceClient::startUpdating):
28516         (WebCore::EmptyDeviceClient::stopUpdating):
28517         (WebCore):
28518         * page/DOMWindow.cpp:
28519         (WebCore::DOMWindow::addEventListener):
28520         (WebCore::DOMWindow::removeEventListener):
28521         (WebCore::DOMWindow::removeAllEventListeners):
28522         * page/DeviceClient.h: Added.
28523         (WebCore):
28524         (DeviceClient):
28525         (WebCore::DeviceClient::~DeviceClient):
28526         * page/DeviceController.cpp: Added.
28527         DeviceController has extracted functions from DeviceOrientationController and DeviceMotionController.
28528         - addDeviceEventListener(), removeDeviceEventlistener(), removeAllDeviceEventListeners(), dispatchDeviceEvent()
28529         All kind of device event controller which has DeviceClient can be inherited from DeviceController.
28530         (WebCore):
28531         (WebCore::DeviceController::DeviceController):
28532         (WebCore::DeviceController::addDeviceEventListener):
28533         (WebCore::DeviceController::removeDeviceEventListener):
28534         (WebCore::DeviceController::removeAllDeviceEventListeners):
28535         (WebCore::DeviceController::dispatchDeviceEvent):
28536         (WebCore::DeviceController::fireDeviceEvent):
28537         * page/DeviceController.h: Added.
28538         (WebCore):
28539         (DeviceController):
28540         (WebCore::DeviceController::~DeviceController):
28541         (WebCore::DeviceController::isActive):
28542         (WebCore::DeviceController::client):
28543         (WebCore::DeviceController::hasLastData):
28544         (WebCore::DeviceController::getLastEvent):
28545
28546 2012-10-31  Pavel Feldman  <pfeldman@chromium.org>
28547
28548         Web Inspector: frame chooser does not work on subsequent inspector open.
28549         https://bugs.webkit.org/show_bug.cgi?id=100771
28550
28551         Reviewed by Yury Semikhatsky.
28552
28553         - Make WorkerRuntimeAgent and PageRuntimeAgent register themselves in the instrumenting agents independently
28554         - Move pause / run worker handling from InspectorRuntimeAgent into WorkerRuntimeAgent
28555         - Remove remains of the front-end reused signal from InspectorAgent
28556         - Send execution contexts post clear window object instead of post commit load.
28557
28558         * inspector/InspectorAgent.cpp:
28559         (WebCore::InspectorAgent::InspectorAgent):
28560         (WebCore::InspectorAgent::clearFrontend):
28561         (WebCore::InspectorAgent::didCommitLoad):
28562         * inspector/InspectorAgent.h:
28563         (InspectorAgent):
28564         * inspector/InspectorInstrumentation.cpp:
28565         (WebCore):
28566         (WebCore::InspectorInstrumentation::didClearWindowObjectInWorldImpl):
28567         (WebCore::InspectorInstrumentation::willEvaluateWorkerScript):
28568         * inspector/InspectorInstrumentation.h:
28569         (InspectorInstrumentation):
28570         * inspector/InspectorPageAgent.cpp:
28571         (WebCore::InspectorPageAgent::restore):
28572         * inspector/InspectorRuntimeAgent.cpp:
28573         (WebCore::InspectorRuntimeAgent::InspectorRuntimeAgent):
28574         (WebCore::InspectorRuntimeAgent::~InspectorRuntimeAgent):
28575         (WebCore::InspectorRuntimeAgent::run):
28576         (WebCore::InspectorRuntimeAgent::setScriptDebugServer):
28577         * inspector/InspectorRuntimeAgent.h:
28578         (InspectorRuntimeAgent):
28579         * inspector/InstrumentingAgents.h:
28580         (WebCore):
28581         (WebCore::InstrumentingAgents::InstrumentingAgents):
28582         (WebCore::InstrumentingAgents::workerRuntimeAgent):
28583         (WebCore::InstrumentingAgents::setWorkerRuntimeAgent):
28584         (InstrumentingAgents):
28585         * inspector/PageRuntimeAgent.cpp:
28586         (WebCore::PageRuntimeAgent::PageRuntimeAgent):
28587         (WebCore::PageRuntimeAgent::~PageRuntimeAgent):
28588         (WebCore::PageRuntimeAgent::setFrontend):
28589         (WebCore::PageRuntimeAgent::clearFrontend):
28590         (WebCore::PageRuntimeAgent::enable):
28591         (WebCore::PageRuntimeAgent::didCreateMainWorldContext):
28592         * inspector/PageRuntimeAgent.h:
28593         (PageRuntimeAgent):
28594         * inspector/WorkerRuntimeAgent.cpp:
28595         (WebCore::WorkerRuntimeAgent::WorkerRuntimeAgent):
28596         (WebCore::WorkerRuntimeAgent::~WorkerRuntimeAgent):
28597         (WebCore::WorkerRuntimeAgent::run):
28598         (WebCore):
28599         (WebCore::WorkerRuntimeAgent::pauseWorkerContext):
28600         * inspector/WorkerRuntimeAgent.h:
28601         (WorkerRuntimeAgent):
28602
28603 2012-10-31  Keishi Hattori  <keishi@webkit.org>
28604
28605         Calendar picker can flicker when opened from the suggestion picker
28606         https://bugs.webkit.org/show_bug.cgi?id=100816
28607
28608         Reviewed by Kent Tamura.
28609
28610         Calendar picker was opening before the hiding completed.
28611
28612         No new tests. Added test to date-suggestion-picker-key-operations.html.
28613
28614         * Resources/pagepopups/pickerCommon.js: Added didHide event.
28615         * Resources/pagepopups/suggestionPicker.js:
28616         (SuggestionPicker.prototype.selectEntry): Use didHide event so we don't open the calendar picker prematurely.
28617         (SuggestionPicker._handleWindowDidHide): When the window finished hiding, open the calendar picker.
28618
28619 2012-10-31  Allan Sandfeld Jensen  <allan.jensen@digia.com>
28620
28621         Reset binding test result after r132973
28622         https://bugs.webkit.org/show_bug.cgi?id=99178
28623
28624         Unreviewed gardening.
28625
28626         * bindings/scripts/test/JS/JSFloat64Array.cpp:
28627         (WebCore::getJSFloat64ArrayConstructorTable):
28628         (WebCore::JSFloat64ArrayConstructor::getOwnPropertySlot):
28629         (WebCore::JSFloat64ArrayConstructor::getOwnPropertyDescriptor):
28630
28631 2012-10-31  Mike West  <mkwst@chromium.org>
28632
28633         Script run from an isolated world should bypass a page's CSP.
28634         https://bugs.webkit.org/show_bug.cgi?id=97398
28635
28636         Reviewed by Adam Barth.
28637
28638         A page's Content Security Policy currently applies to all resources
28639         loaded, regardless of their source. That generally makes sense, but
28640         proves problematic when considering script run from an isolated
28641         world (Chrome extensions, for instance). These scripts should be allowed
28642         to inject resources into a page's DOM without eiher being restricted by
28643         the page's active CSP, or generating violation reports that spam the
28644         page owner.
28645
28646         Ideally, the isolated world could define its own Content Security Policy
28647         which should be applied to resources it loads. For the moment, this
28648         patch accepts a String that we can parse later on, but only uses it in
28649         a binary way. If a non-empty policy String is provided, we bypass the
28650         main world's CSP checks. If an empty String is provided, the main
28651         world's CSP checks remain active.
28652
28653         Test: http/tests/security/isolatedWorld/bypass-main-world-csp.html
28654
28655         (WebCore::isolatedWorldContentSecurityPolicies):
28656         (WebCore::DOMWrapperWorld::isolatedWorldHasContentSecurityPolicy):
28657         (WebCore::DOMWrapperWorld::setIsolatedWorldContentSecurityPolicy):
28658         (WebCore::DOMWrapperWorld::clearIsolatedWorldContentSecurityPolicy):
28659         * bindings/v8/DOMWrapperWorld.h:
28660         (DOMWrapperWorld):
28661             Mechanisms for setting and clearing Content Security Policies from
28662             isolated worlds; implemented in the same HashMappy way as
28663             SecurityOrigin.
28664         * bindings/v8/ScriptController.cpp:
28665         (WebCore::ScriptController::shouldBypassMainWorldContentSecurityPolicy):
28666         (WebCore):
28667         * bindings/v8/ScriptController.h:
28668         (ScriptController):
28669             Adding a method to ScriptController to query the state of the
28670             current world's Content Security Policy. We'll drop this once we can
28671             apply a policy more directly, but for the moment it's necessary for
28672             the next bit.
28673         * loader/cache/CachedResourceLoader.cpp:
28674         (WebCore::CachedResourceLoader::canRequest):
28675             Check the new ScriptController method, and only perform CSP checks
28676             when loading resources if we're executing code from the main world,
28677             or an isolated world with no Content Security Policy set.
28678
28679 2012-10-31  Tim Horton  <timothy_horton@apple.com>
28680
28681         Unreviewed, attempt to fix the release build by not exporting symbols that aren't defined there.
28682
28683         * WebCore.exp.in:
28684
28685 2012-10-31  Yury Semikhatsky  <yurys@chromium.org>
28686
28687         Memory instrumentation: do not report memory occupied by objects referenced using client interfaces
28688         https://bugs.webkit.org/show_bug.cgi?id=100824
28689
28690         Reviewed by Alexander Pavlov.
28691
28692         In many classes we have pointer to a client object. These references should be
28693         reported as weak pointers and the client's memory usage should be reported when
28694         the client is reached from its instrumented owner where we know exact type of
28695         the client. Otherwise we would need to add reportMemoryUsage to all client
28696         interfaces which places additional burden on the client implementers and blurs
28697         the instrumentation boundaries.
28698
28699         * inspector/InspectorController.cpp:
28700         (WebCore::InspectorController::reportMemoryUsage):
28701         * inspector/InspectorDebuggerAgent.cpp:
28702         (WebCore::InspectorDebuggerAgent::reportMemoryUsage):
28703         * inspector/InspectorMemoryAgent.cpp:
28704         (WebCore::InspectorMemoryAgent::reportMemoryUsage):
28705         * inspector/InspectorOverlay.cpp:
28706         (WebCore::InspectorOverlay::reportMemoryUsage):
28707         * inspector/InspectorResourceAgent.cpp:
28708         (WebCore::InspectorResourceAgent::reportMemoryUsage):
28709         * page/Page.cpp:
28710         (WebCore::Page::reportMemoryUsage):
28711
28712 2012-10-31  Tim Horton  <timothy_horton@apple.com>
28713
28714         Unreviewed, attempt to fix the build by exporting NoExceptionAssertionChecker symbols.
28715
28716         * WebCore.exp.in:
28717
28718 2012-10-31  Eric Seidel  <eric@webkit.org>
28719
28720         Add non-virtual firstChild/lastChild overrides to RenderBlock and RenderTableCol for a > 30% speedup on table from bug 100304
28721         https://bugs.webkit.org/show_bug.cgi?id=100306
28722
28723         Reviewed by Abhishek Arya.
28724
28725         Presumably this is a speedup for other rendering tests as well.  We use firstChild() all over
28726         the rendering code w/o considering that it makes a virtual function call.
28727         Originally I just fixed the one callsite which was showing up on the sample to
28728         use children()->firstChild() directly.  However after further thought, this
28729         broader solution seemed the better way to go.  The first patch was a 15% win for
28730         this large table, this broader solution was a 30%!? win.
28731
28732         The elephant in the room for this table is that we're walking the whole table
28733         for many nextColumn calls.  But that I will solve in a later bug.
28734
28735         * rendering/RenderBlock.h:
28736         (WebCore::RenderBlock::firstChild):
28737         (WebCore::RenderBlock::lastChild):
28738         (RenderBlock):
28739         * rendering/RenderObject.h:
28740         (RenderObject):
28741         * rendering/RenderTableCol.h:
28742         (WebCore::RenderTableCol::firstChild):
28743         (WebCore::RenderTableCol::lastChild):
28744         (RenderTableCol):
28745
28746 2012-10-31  Philippe Normand  <pnormand@igalia.com>
28747
28748         Spatialized panning renders incorrectly with USE_CONCATENATED_IMPULSE_RESPONSES
28749         https://bugs.webkit.org/show_bug.cgi?id=98294
28750
28751         Reviewed by Chris Rogers.
28752
28753         Regenerated the concatenated impulse responses file with
28754         elevations in increasing order per azimuth. In the previous
28755         version of this file the elevations for 315, 330 and 345 were
28756         concatenated at the wrong indexes.
28757
28758         * platform/audio/resources/Composite.wav:
28759
28760 2012-10-31  Tim Horton  <timothy_horton@apple.com>
28761
28762         Full-page PDFPlugin should support inline form editing
28763         https://bugs.webkit.org/show_bug.cgi?id=100155
28764
28765         Reviewed by Dan Bernstein.
28766
28767         Add form controls corresponding to Text and Choice PDF annotations,
28768         allowing for single- and multi-line text input, and <option>-like input.
28769
28770         Currently, forms are only implemented for full-page PDF documents.
28771
28772         * WebCore.exp.in: Expose a variety of additional WebCore functionality to WebKit2.
28773         * WebCore.xcodeproj/project.pbxproj: Expose some more WebCore headers as private headers for use in WebKit2.
28774
28775 2012-10-30  Eric Seidel  <eric@webkit.org>
28776
28777         RoboHornetPro spends ~25% of total test time in WebCore::Region::Shape methods
28778         https://bugs.webkit.org/show_bug.cgi?id=98800
28779
28780         Reviewed by Sam Weinig.
28781
28782         This patch brings our total RoboHornetPro time from 8.2 seconds to 5.3 seconds!
28783
28784         OverlapMap previously used Regions to track Layer bounds rects. 
28785         Unfortunately unioning a list of Regions is O(N^2)
28786         where N is the number of Shapes (in this case rects).
28787         This is because Shapes are immutable, so to union two shapes, we copy
28788         both Shapes' segment/span vectors into a single new Shape.
28789         Thus if we union a set of M Regions, each with 1 Shape, we'll end up copying
28790         the segments of the first Shape N times before we have the final Region/Shape
28791         and the second shape N-1 times. The sum of 1 to N is (N*(N-1))/2 aka order N^2.
28792         Fixing the N^2 algorithm covered by https://bugs.webkit.org/show_bug.cgi?id=100814.
28793
28794         For now we just avoid this O(N^2) by moving away from Region, since OverlapMap
28795         doesn't need it. We just collect a vector of the layer rects and hit-test that directly.
28796         Hit-testing the rect list is O(N), just like hit-testing the same information in a Region would be.
28797
28798         Even better for us is that the OverlapMap is never even used in RoboHornetPro.
28799         We just collect these rects to end up doing nothing with them. :)
28800
28801         * rendering/RenderLayerCompositor.cpp:
28802         (WebCore::RenderLayerCompositor::OverlapMap::add):
28803         (WebCore::RenderLayerCompositor::OverlapMap::overlapsLayers):
28804         (WebCore::RenderLayerCompositor::OverlapMap::pushCompositingContainer):
28805         (WebCore::RenderLayerCompositor::OverlapMap::popCompositingContainer):
28806         (RenderLayerCompositor::OverlapMap):
28807
28808 2012-10-30  Beth Dakin  <bdakin@apple.com>
28809
28810         https://bugs.webkit.org/show_bug.cgi?id=100813
28811         ScrollingCoordinatorMac::stateNodeForID() should return a 
28812         ScrollingStateNode* instead of a ScrollingStateScrollingNode*
28813
28814         Reviewed by Sam Weinig.
28815
28816         ScrollingCoordinatorMac::stateNodeForID() should return a 
28817         ScrollingStateNode* instead of a ScrollingStateScrollingNode* so that 
28818         it can be used for other types of nodes once we add them.
28819         * page/scrolling/mac/ScrollingCoordinatorMac.h:
28820         (ScrollingCoordinatorMac):
28821         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
28822         (WebCore::ScrollingCoordinatorMac::frameViewLayoutUpdated):
28823         (WebCore::ScrollingCoordinatorMac::recomputeWheelEventHandlerCountForFrameView):
28824         (WebCore::ScrollingCoordinatorMac::requestScrollPositionUpdate):
28825         (WebCore::ScrollingCoordinatorMac::stateNodeForID):
28826
28827 2012-10-30  Keishi Hattori  <keishi@webkit.org>
28828
28829         F4 inside <input type=time> should not open calendar picker
28830         https://bugs.webkit.org/show_bug.cgi?id=100730
28831
28832         Reviewed by Kent Tamura.
28833
28834         We lacked the check to see if the picker indicator is visible.
28835
28836         Test: fast/forms/time-multiple-fields/time-multiple-fields-open-picker-key-bindings.html
28837
28838         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
28839         (WebCore::BaseMultipleFieldsDateAndTimeInputType::handleKeydownEvent): Check if picker indicator is visible.
28840
28841 2012-10-30  Kent Tamura  <tkent@chromium.org>
28842
28843         Delaying 'change' and 'input' event dispatching during HTMLInputElement::setValue
28844         https://bugs.webkit.org/show_bug.cgi?id=100772
28845
28846         Reviewed by Abhishek Arya.
28847
28848         'change' and 'input' events are asynchronous and not
28849         cancelable. We can use ScopedEvent.
28850
28851         Test: fast/forms/range/range-type-change-onchange.html
28852
28853         * dom/Node.cpp:
28854         (WebCore::Node::dispatchChangeEvent): Use dispatchScopedEvent.
28855         (WebCore::Node::dispatchInputEvent): Ditto.
28856         * html/HTMLInputElement.cpp:
28857         (WebCore::HTMLInputElement::setValue):
28858         Make a scope to delay event dispatching.
28859         * html/RangeInputType.cpp:
28860         (WebCore::RangeInputType::handleKeydownEvent): Ditto.
28861
28862 2012-10-30  Simon Fraser  <simon.fraser@apple.com>
28863
28864         Fix issues with filters and reflections
28865         https://bugs.webkit.org/show_bug.cgi?id=100308
28866
28867         Reviewed by Dirk Schulze.
28868
28869         Composited filters were being applied to the wrong CALayer. The code used
28870         primaryLayer(), which may be a CATransformLayer (which filters cannot apply
28871         to; doing so causes console spew), or a CALayer that is used for reflection
28872         flattening, which again is the wrong layer.
28873
28874         Test: css3/filters/composited-reflected.html
28875
28876         * platform/graphics/ca/GraphicsLayerCA.cpp:
28877         (WebCore::GraphicsLayerCA::updateContentsVisibility): Replace .get()-> with ->
28878         (WebCore::GraphicsLayerCA::updateContentsOpaque): Ditto.
28879         (WebCore::GraphicsLayerCA::updateFilters): Apply filters to m_layer, not primaryLayer(),
28880         and use m_layerClones, not primaryLayerClones().
28881         (WebCore::GraphicsLayerCA::cloneLayer): When cloning a layer for reflections, copy filters
28882         from the source layer.
28883         * platform/graphics/ca/PlatformCALayer.h:
28884         (PlatformCALayer): Add a member function to copy filters from a supplied layer.
28885         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
28886         (PlatformCALayer::setFilters): Remove blank line.
28887         (PlatformCALayer::copyFiltersFrom): Copy CAFIlters from the given layer.
28888         * platform/graphics/ca/win/PlatformCALayerWin.cpp:
28889         (PlatformCALayer::copyFiltersFrom): Stub; no filters on Windows.
28890
28891 2012-10-30  Beth Dakin  <bdakin@apple.com>
28892
28893         https://bugs.webkit.org/show_bug.cgi?id=100809
28894         ScrollingCoordinator::attachToStateTree() should take an enum 
28895         indicating what type of node to create
28896
28897         Reviewed by Simon Fraser.
28898
28899         New enum ScrollingNodeType will soon have other values, such as 
28900         FixedNode.
28901         * page/scrolling/ScrollingCoordinator.h:
28902         (WebCore::ScrollingCoordinator::attachToStateTree):
28903         * page/scrolling/mac/ScrollingCoordinatorMac.h:
28904         (ScrollingCoordinatorMac):
28905
28906         This patch generalizes this function so that it can be used to create 
28907         different types of nodes and so that it is actually ready to create 
28908         child nodes. 
28909         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
28910         (WebCore::ScrollingCoordinatorMac::attachToStateTree):
28911
28912         The rootStateNode is always a ScrollingNode.
28913         (WebCore::ScrollingCoordinatorMac::ensureRootStateNodeForFrameView):
28914
28915         For the time being, always create a ScrollingNode.
28916         * rendering/RenderLayerBacking.cpp:
28917         (WebCore::RenderLayerBacking::attachToScrollingCoordinator):
28918
28919 2012-10-30  Gregg Tavares  <gman@google.com>
28920
28921         Set the initial scissor box for WebGL
28922         https://bugs.webkit.org/show_bug.cgi?id=100804
28923
28924         Reviewed by Kenneth Russell.
28925
28926         The initial scissor box needs to be set for WebGL
28927
28928         No new tests as no new functionality.
28929
28930         * html/canvas/WebGLRenderingContext.cpp:
28931         (WebCore):
28932         (WebCore::WebGLRenderingContext::initializeNewContext):
28933
28934 2012-10-30  Charles Wei  <charles.wei@torchmobile.com.cn>
28935
28936         [BlackBerry] PurgeCredential should also purge the persisted credential store
28937         https://bugs.webkit.org/show_bug.cgi?id=100744
28938
28939         Reviewed by George Staikos.
28940
28941         When challenged by the server, we will check the credential in-memory and from the persistent storage.
28942         So the invalid credentials should also be purged from the persistent credential storage; Otherwise,
28943         it will be sent to the server next time been challenged, instead of prompting the user.
28944
28945         * platform/network/blackberry/NetworkJob.cpp:
28946         (WebCore::NetworkJob::purgeCredentials):
28947
28948 2012-10-30  Allan Sandfeld Jensen  <allan.jensen@digia.com>
28949
28950         DOM URL is flaky when workers are used
28951         https://bugs.webkit.org/show_bug.cgi?id=99178
28952
28953         Reviewed by Geoffrey Garen.
28954
28955         Extend JSNoStaticTables to also avoid direct access of static tables in constructor objects.
28956
28957         Test: fast/workers/worker-domurl.html
28958
28959         * bindings/scripts/CodeGeneratorJS.pm:
28960         (constructorHashTableAccessor):
28961         (GenerateConstructorDefinition):
28962
28963 2012-10-30  Jae Hyun Park  <jae.park@company100.net>
28964
28965         Coordinated Graphics: Remove unused methods
28966         https://bugs.webkit.org/show_bug.cgi?id=100799
28967
28968         Reviewed by Noam Rosenthal.
28969
28970         Currently, there are several unused methods regarding Coordinated
28971         Graphics. This patch removes those unused methods.
28972
28973         No new tests (No change in behavior).
28974
28975         * platform/graphics/texmap/TextureMapperGL.cpp:
28976
28977 2012-10-30  Hans Muller  <hmuller@adobe.com>
28978
28979         [CSS Exclusions] Multiple segment polygon layout does not get all segments
28980         https://bugs.webkit.org/show_bug.cgi?id=100039
28981
28982         Reviewed by Dirk Schulze.
28983
28984         Corrected the algorithm for computing included polygon intervals for rectilinear polygons,
28985         and polygons with horizontal edges in general.
28986
28987         Tests: fast/exclusions/shape-inside/shape-inside-rectilinear-polygon-001.html
28988                fast/exclusions/shape-inside/shape-inside-rectilinear-polygon-002.html
28989
28990         * rendering/ExclusionPolygon.cpp: Removed some internal dead code related to the no-longer-used sortedEdgesMinY Vector.
28991         (WebCore::ExclusionPolygon::ExclusionPolygon): Initialize new ExclusionPolygonEdge edgeIndex field.
28992         (WebCore::getVertexIntersectionVertices): Return the previous, next, and target vertex indices for a vertex intersection.
28993         (WebCore::ExclusionPolygon::computeXIntersections): Refactored the core of this method to improve handling of horizontal edges.
28994         (WebCore::ExclusionPolygon::computeEdgeIntersections): Ignore zero-width edges.
28995         * rendering/ExclusionPolygon.h: Removed the rightVertexY() method, since it's no longer used.
28996         (WebCore::ExclusionPolygon::edgeAt): New method.
28997         (WebCore::ExclusionPolygon::numberOfEdges): New method.
28998         (ExclusionPolygon): Added support for retrieving edges.
28999         (WebCore::ExclusionPolygonEdge::vertex1): Use vertex1Index.
29000         (WebCore::ExclusionPolygonEdge::vertex2): Use vertex2Index.
29001         (ExclusionPolygonEdge): Renamed index1, index2 fields to vertex1Index, vertex2Index.
29002         (WebCore::ExclusionPolygonEdge::previousEdge): New method.
29003         (WebCore::ExclusionPolygonEdge::nextEdge): New method.
29004
29005 2012-10-30  Chris Evans  <cevans@google.com>
29006
29007         Improve performance of MaskPtr.
29008         https://bugs.webkit.org/show_bug.cgi?id=100790
29009
29010         Reviewed by Eric Seidel.
29011
29012         Calculate the mask once, and store it as a fast-access member variable.
29013         Also avoid unneccessary integer width expansion in index calculation.
29014         Parser/tiny-innerHTML.html has a high stddev.
29015         Best result I've seen pre-patch is 5.70 runs/s.
29016         Best result I've seen post-patch is 5.72 runs/s, but this is not statistically significant.
29017         MaskPtr is still showing as ~2% in the profile, so we're not sure we trust the profile symbolization at this time.
29018         MaskPtr is now reduced to a single inline instruction (was: 4) so this seems like a strict improvement worth landing.
29019
29020         * rendering/RenderArena.cpp:
29021         (MaskPtr): Use a passed-in mask for the mask operation.
29022         (WebCore::RenderArena::RenderArena): Calculate the mask and store it.
29023         (WebCore::RenderArena::allocate):
29024         (WebCore::RenderArena::free): Use stored mask and avoid unneccessary casts.
29025         * rendering/RenderArena.h:
29026         (RenderArena): Store the freelist mask as a member variable.
29027
29028 2012-10-30  Kenichi Ishibashi  <bashi@chromium.org>
29029
29030         local(Helvetica) in src descriptor prevent fallback
29031         https://bugs.webkit.org/show_bug.cgi?id=100446
29032
29033         Reviewed by Dan Bernstein.
29034
29035         FontCache::getCachedFontData() has a mechanism that aliases a few pairs
29036         of font family names, so that if the family name specified in the font-family
29037         property is not available on the system, but the its alias is available,
29038         it will be used instead. This is appropriate for the font-family property,
29039         but not for font family names specified in the local() function of the src
29040         descriptor in a @font-face rule.
29041
29042         This patch disables the mechanism while checking src descriptor of @font-face.
29043
29044         No new tests. It's difficult to test the change because 'Helvetica' can
29045         be mapped any other font. For example, chromium DRT uses FontConfig to
29046         map Helvetica to Times New Roman. Other ports may map Helvetica to other
29047         fonts. We can't define the expected result.
29048
29049         * css/CSSFontFaceSource.cpp:
29050         (WebCore::CSSFontFaceSource::getFontData):
29051         Call fontCache()->getCachedFontData() with checkingAlternateName = true.
29052         This disables aliasing font family names in FontCache.
29053
29054 2012-10-30  Beth Dakin  <bdakin@apple.com>
29055
29056         https://bugs.webkit.org/show_bug.cgi?id=100796
29057         Should add FixedPositionViewportConstraints to ScrollingConstraints.h
29058
29059         Reviewed by Simon Fraser.
29060
29061         ScrollingConstraints.h currently contains an abstract class called 
29062         ViewportConstraints that is intended to encapsulate data and logic 
29063         required to reposition elements whose layout depends on the viewport 
29064         rect (positions fixed and sticky), when scrolling and zooming. 
29065         However, at this time there is only a subclass for sticky. We should 
29066         add a sub-class for fixed. This is required to get pages with fixed 
29067         position elements scrolling on the scrolling thread.
29068
29069         * page/scrolling/ScrollingConstraints.cpp:
29070         (WebCore::FixedPositionViewportConstraints::layerPositionForViewportRect):
29071         (WebCore):
29072         * page/scrolling/ScrollingConstraints.h:
29073         (WebCore::ViewportConstraints::ViewportConstraints):
29074         (ViewportConstraints):
29075         (WebCore::ViewportConstraints::setAnchorEdges):
29076         (FixedPositionViewportConstraints):
29077         (WebCore::FixedPositionViewportConstraints::FixedPositionViewportConstraints):
29078         (WebCore::FixedPositionViewportConstraints::viewportRectAtLastLayout):
29079         (WebCore::FixedPositionViewportConstraints::setViewportRectAtLastLayout):
29080         (WebCore::FixedPositionViewportConstraints::layerPositionAtLastLayout):
29081         (WebCore::FixedPositionViewportConstraints::setLayerPositionAtLastLayout):
29082         (WebCore):
29083
29084 2012-10-30  Tiancheng Jiang  <tijiang@rim.com>
29085
29086         [BlackBerry] update form theme for BB10.
29087         https://bugs.webkit.org/show_bug.cgi?id=100760
29088
29089         Reviewed by Rob Buis.
29090
29091         RIM PR:222126
29092         Introduce slide function to paint new theme for the form controls.
29093
29094         No new tests.
29095
29096         * css/themeBlackBerry.css:
29097         (select):
29098         * platform/blackberry/RenderThemeBlackBerry.cpp:
29099         (WebCore):
29100         (WebCore::drawControl): Added.
29101         (WebCore::drawThreeSlice): Added.
29102         (WebCore::drawNineSlice): Added.
29103         (WebCore::loadImage): Added.
29104         (WebCore::RenderThemeBlackBerry::systemFont): Modified.
29105         (WebCore::RenderThemeBlackBerry::paintTextFieldOrTextAreaOrSearchField): Modified.
29106         (WebCore::RenderThemeBlackBerry::paintCheckbox): Modified.
29107         (WebCore::RenderThemeBlackBerry::paintRadio): Modified.
29108         (WebCore::RenderThemeBlackBerry::paintButton): Modified.
29109         (WebCore::RenderThemeBlackBerry::paintMenuList): Modified.
29110         (WebCore::RenderThemeBlackBerry::paintMenuListButton): Modified.
29111         (WebCore::RenderThemeBlackBerry::paintSliderTrackRect): Modified.
29112         (WebCore::RenderThemeBlackBerry::paintSliderThumb): Modified.
29113         * platform/blackberry/RenderThemeBlackBerry.h:
29114         (RenderThemeBlackBerry):
29115
29116 2012-10-30  Rick Byers  <rbyers@chromium.org>
29117
29118         cssText for cursor property doesn't include hotspot
29119         https://bugs.webkit.org/show_bug.cgi?id=99530
29120
29121         Reviewed by Darin Adler.
29122
29123         Implement customCssText in CSSCursorImageValue to include the hotspot when present.
29124         Also explicitly track whether or not a hotspot was supplied in the parser,
29125         while still using the existing convention of (-1,-1) to denote no hotspot
29126         in the rest of the system.
29127
29128         Test: fast/css/cursor-parsing.html
29129
29130         * css/CSSCursorImageValue.cpp:
29131         (WebCore::CSSCursorImageValue::customCssText):
29132         * css/CSSCursorImageValue.h:
29133         (CSSCursorImageValue):
29134
29135 2012-10-30  Kenneth Russell  <kbr@google.com>
29136
29137         Temporarily restrict use of ImageBufferSkia::copyToPlatformTexture until bugs resolved
29138         https://bugs.webkit.org/show_bug.cgi?id=100714
29139
29140         Reviewed by Stephen White.
29141
29142         For the moment, only use ImageBuffer::copyToPlatformTexture when
29143         copying to RGBA/UNSIGNED_BYTE textures, and document restriction
29144         in header. Restriction will be lifted once the implementations
29145         (currently only Chromium has one) have been fixed; see bug 100715.
29146
29147         No new tests; manually ran WebGL conformance test
29148         tex-image-and-sub-image-2d-with-canvas-rgba5551.html on NVIDIA
29149         hardware on Mac OS.
29150
29151         * html/canvas/WebGLRenderingContext.cpp:
29152         (WebCore):
29153         (WebCore::WebGLRenderingContext::texImage2D):
29154         * platform/graphics/ImageBuffer.h:
29155         (ImageBuffer):
29156
29157 2012-10-30  Nico Weber  <thakis@chromium.org>
29158
29159         Fix potential overflow in jpeg exif reader. Found by aedla@google.com.
29160         https://bugs.webkit.org/show_bug.cgi?id=100320
29161
29162         Reviewed by Eric Seidel.
29163
29164         Adding more than 1 element past an array is undefined, so don't do it.
29165
29166         No test, since in practice ifd will just overflow and `end - ifd` will
29167         become much larget than 2 and the `if (end - ifd < 2)` a few lines
29168         down will catch that case.
29169
29170         * platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
29171         (WebCore::readImageOrientation):
29172
29173 2012-10-26  Alexandru Chiculita  <achicu@adobe.com>
29174
29175         [CSS Shaders] Add the ValidatedCustomFilterOperation class
29176         https://bugs.webkit.org/show_bug.cgi?id=100558
29177
29178         Reviewed by Dean Jackson.
29179
29180         Added the ValidatedCustomFilterOperation class. The file is now almost empty,
29181         but more is going to come in the following patches.
29182
29183         Added the a filter operation type VALIDATED_CUSTOM and updated the compositors to ignore
29184         such operations for now.
29185         
29186         No new tests, there is no new functionality yet.
29187
29188         * CMakeLists.txt:
29189         * GNUmakefile.list.am:
29190         * Target.pri:
29191         * WebCore.gypi:
29192         * WebCore.vcproj/WebCore.vcproj:
29193         * WebCore.xcodeproj/project.pbxproj:
29194         * css/CSSComputedStyleDeclaration.cpp:
29195         (WebCore::CSSComputedStyleDeclaration::valueForFilter):
29196         * css/StyleResolver.cpp:
29197         (WebCore::StyleResolver::createFilterOperations):
29198         * platform/graphics/blackberry/LayerWebKitThread.cpp:
29199         (WebCore::LayerWebKitThread::filtersCanBeComposited):
29200         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
29201         (PlatformCALayer::filtersCanBeComposited):
29202         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
29203         (WebCore::copyWebCoreFilterOperationsToWebFilterOperations):
29204         * platform/graphics/filters/FilterOperation.h:
29205         * platform/graphics/filters/FilterOperations.cpp:
29206         (WebCore::FilterOperations::hasCustomFilter):
29207         (WebCore::FilterOperations::getOutsets):
29208         * platform/graphics/filters/ValidatedCustomFilterOperation.cpp: Added.
29209         (WebCore):
29210         (WebCore::ValidatedCustomFilterOperation::ValidatedCustomFilterOperation):
29211         (WebCore::ValidatedCustomFilterOperation::~ValidatedCustomFilterOperation):
29212         (WebCore::ValidatedCustomFilterOperation::blend):
29213         * platform/graphics/filters/ValidatedCustomFilterOperation.h: Added.
29214         (WebCore):
29215         (ValidatedCustomFilterOperation):
29216         (WebCore::ValidatedCustomFilterOperation::create):
29217         (WebCore::ValidatedCustomFilterOperation::affectsOpacity):
29218         (WebCore::ValidatedCustomFilterOperation::movesPixels):
29219         (WebCore::ValidatedCustomFilterOperation::blendingNeedsRendererSize):
29220         (WebCore::ValidatedCustomFilterOperation::operator==):
29221
29222 2012-10-30  Joseph Pecoraro  <pecoraro@apple.com>
29223
29224         [Mac] Sync up FeatureDefine Configuration Files
29225         https://bugs.webkit.org/show_bug.cgi?id=100171
29226
29227         Reviewed by David Kilzer.
29228
29229         Follow up to better coordinate with iOS feature defines. Make:
29230
29231           - ENABLE_FILTERS always on
29232           - ENABLE_INPUT_* iphonesimulator values point to the iphoneos values
29233
29234         * Configurations/FeatureDefines.xcconfig:
29235
29236 2012-10-30  Joseph Pecoraro  <pecoraro@apple.com>
29237
29238         [Mac] Sync up FeatureDefine Configuration Files
29239         https://bugs.webkit.org/show_bug.cgi?id=100171
29240
29241         Reviewed by David Kilzer.
29242
29243         Ensure an identical FeatureDefine files across all projects. Changes:
29244
29245           - ENABLE_CSS_BOX_DECORATION_BREAK should be in all
29246           - ENABLE_PDFKIT_PLUGIN should be in all
29247           - ENABLE_RESOLUTION_MEDIA_QUERY should be in all
29248           - ENABLE_ENCRYPTED_MEDIA should be in all
29249           - ENABLE_HIDDEN_PAGE_DOM_TIMER_THROTTLING with corrected value
29250           - Some alphabetical ordering cleanup
29251
29252         * Configurations/FeatureDefines.xcconfig:
29253
29254 2012-10-30  Andreas Kling  <kling@webkit.org>
29255
29256         StylePropertySet: Convert more logic to use PropertyReference.
29257         <http://webkit.org/b/100779>
29258
29259         Reviewed by Antti Koivisto.
29260
29261         Rewrite more of the StylePropertySet logic to use PropertyReference instead of CSSProperty.
29262         This is cleanup before changing the internal storage layout of immutable StylePropertySet.
29263
29264         * css/CSSComputedStyleDeclaration.cpp:
29265         (WebCore::CSSComputedStyleDeclaration::cssPropertyMatches):
29266         * css/CSSComputedStyleDeclaration.h:
29267         * css/CSSStyleDeclaration.h:
29268         * css/PropertySetCSSStyleDeclaration.cpp:
29269         (WebCore::PropertySetCSSStyleDeclaration::cssPropertyMatches):
29270         * css/PropertySetCSSStyleDeclaration.h:
29271         * css/StylePropertySet.cpp:
29272         (WebCore::StylePropertySet::appendFontLonghandValueIfExplicit):
29273         (WebCore::StylePropertySet::fontValue):
29274         (WebCore::StylePropertySet::get4Values):
29275         (WebCore::StylePropertySet::getPropertyCSSValue):
29276         (WebCore::StylePropertySet::removeProperty):
29277         (WebCore::StylePropertySet::propertyIsImportant):
29278         (WebCore::StylePropertySet::getPropertyShorthand):
29279         (WebCore::StylePropertySet::isPropertyImplicit):
29280         (WebCore::StylePropertySet::setProperty):
29281         (WebCore::StylePropertySet::mergeAndOverrideOnConflict):
29282         (WebCore::StylePropertySet::findPropertyIndex):
29283         (WebCore::StylePropertySet::findMutableCSSPropertyWithID):
29284         (WebCore::StylePropertySet::propertyMatches):
29285         (WebCore::StylePropertySet::removeEquivalentProperties):
29286         * css/StylePropertySet.h:
29287         (WebCore::StylePropertySet::PropertyReference::shorthandID):
29288         (WebCore::StylePropertySet::PropertyReference::isImplicit):
29289
29290 2012-10-30  Eric Seidel  <eric@webkit.org>
29291
29292         Teach RenderTable how to use Vector::insert and Vector::append instead of its own custom memmove code
29293         https://bugs.webkit.org/show_bug.cgi?id=100428
29294
29295         Reviewed by Julien Chaffraix.
29296
29297         RenderTable is now like all other clients of Vector instead of being
29298         needlessly different. :)
29299
29300         insert, append and grow all use the same expandCapacity logic under the covers
29301         and Vector::insert uses TypeOperations::moveOverlapping which should use memmove
29302         by default for unknown types.
29303
29304         * rendering/RenderTable.cpp:
29305         (WebCore::RenderTable::splitColumn):
29306         (WebCore::RenderTable::appendColumn):
29307         * rendering/RenderTable.h:
29308         (WebCore::RenderTable::ColumnStruct::ColumnStruct):
29309
29310 2012-10-30  Vincent Scheib  <scheib@chromium.org>
29311
29312         Unreviewed, rolling out r132927.
29313         http://trac.webkit.org/changeset/132927
29314         https://bugs.webkit.org/show_bug.cgi?id=100558
29315
29316         Compile error on Chromium builders
29317
29318         * CMakeLists.txt:
29319         * GNUmakefile.list.am:
29320         * Target.pri:
29321         * WebCore.gypi:
29322         * WebCore.vcproj/WebCore.vcproj:
29323         * WebCore.xcodeproj/project.pbxproj:
29324         * css/CSSComputedStyleDeclaration.cpp:
29325         (WebCore::CSSComputedStyleDeclaration::valueForFilter):
29326         * css/StyleResolver.cpp:
29327         (WebCore::StyleResolver::createFilterOperations):
29328         * platform/graphics/blackberry/LayerWebKitThread.cpp:
29329         (WebCore::LayerWebKitThread::filtersCanBeComposited):
29330         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
29331         (PlatformCALayer::filtersCanBeComposited):
29332         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
29333         (WebCore::copyWebCoreFilterOperationsToWebFilterOperations):
29334         * platform/graphics/filters/FilterOperation.h:
29335         * platform/graphics/filters/FilterOperations.cpp:
29336         (WebCore::FilterOperations::hasCustomFilter):
29337         (WebCore::FilterOperations::getOutsets):
29338         * platform/graphics/filters/ValidatedCustomFilterOperation.cpp: Removed.
29339         * platform/graphics/filters/ValidatedCustomFilterOperation.h: Removed.
29340
29341 2012-10-30  W. James MacLean  <wjmaclean@chromium.org>
29342
29343         [chromium] Restrict link highlights to targets that display a hand-cursor
29344         https://bugs.webkit.org/show_bug.cgi?id=99862
29345
29346         Reviewed by James Robinson.
29347
29348         To avoid applying highlights to inappropriate targets, such as large divs with
29349         click handlers installed, test candidate targets and only highlight them if they
29350         would normally display a hand cursor on mouse over. This is a heuristic, but has
29351         been tested and found effective in practice.
29352
29353         This CL refactors EventHandler::selectCursor() to make the logic for determining
29354         if CURSOR_AUTO should resolve to CURSOR_POINTER available outside EventHandler.
29355
29356         Relies on existing cursor tests.
29357
29358         * page/EventHandler.cpp:
29359         (WebCore::EventHandler::useHandCursor):
29360         (WebCore):
29361         (WebCore::EventHandler::selectCursor):
29362         * page/EventHandler.h:
29363         (EventHandler):
29364
29365 2012-10-30  Rob Buis  <rbuis@rim.com>
29366
29367         [BlackBerry] Remove CookieDatabaseBackingStore::upgradeTableIfNeeded
29368         https://bugs.webkit.org/show_bug.cgi?id=100783
29369
29370         Reviewed by Yong Li.
29371
29372         PR 220513.
29373
29374         Remove CookieDatabaseBackingStore::upgradeTableIfNeeded, it was needed for backwards
29375         compatibility, but not needed anymore.
29376
29377         * platform/blackberry/CookieDatabaseBackingStore/CookieDatabaseBackingStore.cpp:
29378         (WebCore::CookieDatabaseBackingStore::invokeOpen):
29379         * platform/blackberry/CookieDatabaseBackingStore/CookieDatabaseBackingStore.h:
29380
29381 2012-10-30  Glenn Adams  <glenn@skynav.com>
29382
29383         [CSS] Expand -webkit-line-break value space
29384         https://bugs.webkit.org/show_bug.cgi?id=100739
29385
29386         Reviewed by Eric Seidel.
29387
29388         (1) expand -webkit-line-break to include new values defined by CSS3 Text [1], i.e., 'auto', 'strict', 'loose';
29389         (2) change default (initial) value for -webkit-line-break to 'auto' to match CSS3 Text;
29390         (3) rename enum EKHTMLLineBreak to LineBreak, renaming enum values appropriately;
29391
29392         New tests to be added when functionality of new values is added. No rendering behavior change at this time.
29393         Only externally visible change is default (initial) value returning 'auto' rather than 'normal', for which 3 existing
29394         tests that were sensitive to this value have been updated. Note that until the functionality for the new values is
29395         added, any actual use of the new values will be treated as the same as the pre-existing 'normal' value, i.e., the
29396         default semantics.
29397
29398         * css/CSSComputedStyleDeclaration.cpp:
29399         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
29400         Update from kthmlLineBreak() to lineBreak().
29401
29402         * css/CSSParser.cpp:
29403         (WebCore::isValidKeywordPropertyAndValue):
29404         Update values supported for CSSPropertyWebkitLineBreak.
29405
29406         * css/CSSPrimitiveValueMappings.h:
29407         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
29408         (WebCore::CSSPrimitiveValue::operator LineBreak):
29409         Update LineBreak enumeration values (previously EKHTMLLineBreak).
29410
29411         * css/CSSValueKeywords.in:
29412         Update keywords used for -webkit-line-break.
29413
29414         * css/StyleBuilder.cpp:
29415         (WebCore::StyleBuilder::StyleBuilder):
29416         Update names for line break style getter/setter.
29417
29418         * rendering/style/RenderStyle.cpp:
29419         (WebCore::RenderStyle::diff):
29420         Remove khtml prefix on line break related state.
29421
29422         * rendering/style/RenderStyle.h:
29423         Remove khtml prefix on line break related methods. Update to redefined LineBreak
29424         enumeration type.
29425
29426         * rendering/style/RenderStyleConstants.h:
29427         Rename EKHTMLLineBreak enumeration to LineBreak.
29428         Redefine LineBreak enumeration to include new CSS3 Text modes (auto, loose, strict) and
29429         use better names.
29430
29431         * rendering/style/StyleRareInheritedData.cpp:
29432         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
29433         (WebCore::StyleRareInheritedData::operator==):
29434         Remove khtml prefix on line break related state references.
29435
29436         * rendering/style/StyleRareInheritedData.h:
29437         (StyleRareInheritedData):
29438         Remove khtml prefix on line break related state. Widen field to 3 bits to support 8 values,
29439         of which 5 are now used.
29440
29441 2012-10-30  Antti Koivisto  <antti@apple.com>
29442
29443         Avoid unnecessary style recalcs on class attribute mutation
29444         https://bugs.webkit.org/show_bug.cgi?id=100776
29445
29446         Reviewed by Andreas Kling.
29447
29448         There is no need to invalidate element style on class attribute change if neither the added
29449         or removed classes featured in any active stylesheet.
29450
29451         * css/RuleFeature.cpp:
29452         (WebCore::RuleFeatureSet::add):
29453         (WebCore::RuleFeatureSet::clear):
29454         (WebCore::RuleFeatureSet::reportMemoryUsage):
29455         * css/RuleFeature.h:
29456         (RuleFeatureSet):
29457         * css/RuleSet.cpp:
29458         (WebCore::collectFeaturesFromSelector):
29459         
29460             Collect classes mentioned in CSS selectors the same way ids and attribute names are
29461             already collected.
29462
29463         * css/StyleResolver.cpp:
29464         (WebCore::StyleResolver::hasSelectorForClass):
29465         
29466             Add a method to test if a given class name is mentioned anywhere in stylehseets.
29467
29468         (WebCore):
29469         * css/StyleResolver.h:
29470         * css/StyleScopeResolver.h:
29471         (WebCore):
29472         * dom/Element.cpp:
29473         (WebCore::collectAddedAndRemovedClasses):
29474         (WebCore):
29475         (WebCore::Element::classAttributeChanged):
29476         
29477             Figure out which classes were added and removed. Test if they are present in any style
29478             rule and invalidate the style only if they are.
29479
29480         * dom/SpaceSplitString.cpp:
29481         (WebCore::SpaceSplitStringData::add):
29482         (WebCore::SpaceSplitStringData::remove):
29483         (WebCore::SpaceSplitString::add):
29484         (WebCore::SpaceSplitString::remove):
29485         
29486             Added bool return value to indicate if anything was actually removed. Reorganized 
29487             the code a bit to avoid unnecessary uniquing when nothing changes.
29488
29489         * dom/SpaceSplitString.h:
29490         (SpaceSplitStringData):
29491         (SpaceSplitString):
29492
29493 2012-10-30  Robert Hogan  <robert@webkit.org>
29494
29495         white-space: nowrap inline element beside a floated element wraps incorrectly without trailing textnode/newline
29496         https://bugs.webkit.org/show_bug.cgi?id=29648
29497
29498         Reviewed by Levi Weintraub.
29499
29500         A no-wrap child on a line inside an autowrap container should move to the next line if a float doesn't allow
29501         it to fit. This will happen if there is trailing space after the no-wrap child but not if it's the last renderer
29502         on the line. This is because nextLineBreak() is only interested in the white-space style of the current renderer 
29503         and the renderer's next sibling (if there is one) when deciding whether it needs to fit below any floats that
29504         push it beyond the edge of the container. There isn't any situation in which a no-wrap child shouldn't move 
29505         below a float on an auto-wrap line though, so this check always needs to respect the container's white-space style too.
29506
29507         Test: fast/text/whitespace/no-wrap-child-in-auto-wrap-container.html
29508
29509         * rendering/RenderBlockLineLayout.cpp:
29510         (WebCore::RenderBlock::LineBreaker::nextLineBreak):
29511
29512 2012-10-26  Alexandru Chiculita  <achicu@adobe.com>
29513
29514         [CSS Shaders] Add the ValidatedCustomFilterOperation class
29515         https://bugs.webkit.org/show_bug.cgi?id=100558
29516
29517         Reviewed by Dean Jackson.
29518
29519         Added the ValidatedCustomFilterOperation class. The file is now almost empty,
29520         but more is going to come in the following patches.
29521
29522         Added the a filter operation type VALIDATED_CUSTOM and updated the compositors to ignore
29523         such operations for now.
29524         
29525         No new tests, there is no new functionality yet.
29526
29527         * CMakeLists.txt:
29528         * GNUmakefile.list.am:
29529         * Target.pri:
29530         * WebCore.gypi:
29531         * WebCore.vcproj/WebCore.vcproj:
29532         * WebCore.xcodeproj/project.pbxproj:
29533         * css/CSSComputedStyleDeclaration.cpp:
29534         (WebCore::CSSComputedStyleDeclaration::valueForFilter):
29535         * css/StyleResolver.cpp:
29536         (WebCore::StyleResolver::createFilterOperations):
29537         * platform/graphics/blackberry/LayerWebKitThread.cpp:
29538         (WebCore::LayerWebKitThread::filtersCanBeComposited):
29539         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
29540         (PlatformCALayer::filtersCanBeComposited):
29541         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
29542         (WebCore::copyWebCoreFilterOperationsToWebFilterOperations):
29543         * platform/graphics/filters/FilterOperation.h:
29544         * platform/graphics/filters/FilterOperations.cpp:
29545         (WebCore::FilterOperations::hasCustomFilter):
29546         (WebCore::FilterOperations::getOutsets):
29547         * platform/graphics/filters/ValidatedCustomFilterOperation.cpp: Added.
29548         (WebCore):
29549         (WebCore::ValidatedCustomFilterOperation::ValidatedCustomFilterOperation):
29550         (WebCore::ValidatedCustomFilterOperation::~ValidatedCustomFilterOperation):
29551         (WebCore::ValidatedCustomFilterOperation::blend):
29552         * platform/graphics/filters/ValidatedCustomFilterOperation.h: Added.
29553         (WebCore):
29554         (ValidatedCustomFilterOperation):
29555         (WebCore::ValidatedCustomFilterOperation::create):
29556         (WebCore::ValidatedCustomFilterOperation::affectsOpacity):
29557         (WebCore::ValidatedCustomFilterOperation::movesPixels):
29558         (WebCore::ValidatedCustomFilterOperation::blendingNeedsRendererSize):
29559         (WebCore::ValidatedCustomFilterOperation::operator==):
29560
29561 2012-10-29  Anders Carlsson  <andersca@apple.com>
29562
29563         Build WebKit as C++11 on Mac
29564         https://bugs.webkit.org/show_bug.cgi?id=100720
29565
29566         Reviewed by Daniel Bates.
29567
29568         * Configurations/Base.xcconfig:
29569         Add CLANG_CXX_LANGUAGE_STANDARD=gnu++0x.
29570
29571         * platform/graphics/FontPlatformData.h:
29572         (WebCore::FontPlatformData::hash):
29573         * platform/graphics/cg/GraphicsContextCG.cpp:
29574         (WebCore::GraphicsContext::drawLine):
29575         (WebCore::GraphicsContext::strokeArc):
29576         * platform/graphics/filters/CustomFilterProgramInfo.cpp:
29577         (WebCore::CustomFilterProgramInfo::hash):
29578         (WebCore::ProtectionSpaceHash::hash):
29579         * platform/network/cf/FormDataStreamCFNet.cpp:
29580         (WebCore::setHTTPBody):
29581         Add static_casts to prevent implicit type conversions in non-constant initializer lists.
29582         
29583         * platform/mac/ClipboardMac.mm:
29584         (WebCore::ClipboardMac::createDragImage):
29585         * platform/mac/CursorMac.mm:
29586         (WebCore::createNamedCursor):
29587         * platform/mac/ScrollViewMac.mm:
29588         (WebCore::ScrollView::platformSetContentsSize):
29589         Use NSMakePoint to prevent implicit type conversions in non-constant initializer lists.
29590
29591         * platform/mac/CookieJar.mm:
29592         (WebCore::cookiesEnabled):
29593         * platform/network/mac/ResourceHandleMac.mm:
29594         (WebCore::shouldRelaxThirdPartyCookiePolicy):
29595         Add explicit casts to NSHTTPCookieAcceptPolicy.
29596
29597         * platform/mac/WebCoreNSURLExtras.h:
29598         * platform/mac/WebCoreNSURLExtras.mm:
29599         (WebCore::URLByTruncatingOneCharacterBeforeComponent):
29600         (WebCore::dataForURLComponentType):
29601         * platform/network/ProtectionSpaceHash.h:
29602         Use CFIndex instead of CFURLComponentType, the enum can be mangled differently in some cases, and these
29603         functions are exported from WebCore.
29604
29605 2012-10-30  Dan Bernstein  <mitz@apple.com>
29606
29607         <rdar://problem/12395187> REGRESSION (r121299): OS X Text Replacement forces cursor out of text fields
29608         https://bugs.webkit.org/show_bug.cgi?id=100768
29609
29610         Reviewed by Anders Carlsson.
29611
29612         r121299 introduced code to restore the paragraph range by saving its length and start offset
29613         relative to the document. The latter was obtained by iterating over the range starting at
29614         the beginning of the document and ending at the beginning of the paragraph range. However,
29615         such a range could not be constructed if the paragraph range was contained in a shadow DOM,
29616         since a range must have both its endpoints within the same shadow tree (or not in a shadow
29617         tree).
29618
29619         Test: platform/mac/editing/spelling/autocorrection-in-textarea.html
29620
29621         * editing/Editor.cpp:
29622         (WebCore::Editor::markAndReplaceFor): Changed paragraphStartIndex to be relative to the
29623         root container of paragraphRange, using the same logic used by
29624         checkForDifferentRootContainer() in Range.cpp.
29625
29626 2012-10-30  Dan Carney  <dcarney@google.com>
29627
29628         Remove ensureAuxiliaryContext
29629         https://bugs.webkit.org/show_bug.cgi?id=99975
29630
29631         Reviewed by Adam Barth.
29632
29633         Removed auxilliaryContext as use if it is problematic in IDB.
29634
29635         No new tests. No change in functionality.
29636
29637         * Modules/indexeddb/IDBCursor.cpp:
29638         (WebCore::IDBCursor::update):
29639         (WebCore::IDBCursor::setValueReady):
29640         * Modules/indexeddb/IDBCursor.h:
29641         (IDBCursor):
29642         * Modules/indexeddb/IDBObjectStore.cpp:
29643         (WebCore::generateIndexKeysForValue):
29644         (WebCore::IDBObjectStore::put):
29645         (WebCore):
29646         * Modules/indexeddb/IDBRequest.cpp:
29647         (WebCore::IDBRequest::onSuccess):
29648         (WebCore::IDBRequest::dispatchEvent):
29649         * bindings/v8/IDBBindingUtilities.cpp:
29650         (WebCore::createIDBKeyFromScriptValueAndKeyPath):
29651         (WebCore::deserializeIDBValue):
29652         (WebCore::injectIDBKeyIntoScriptValue):
29653         * bindings/v8/IDBBindingUtilities.h:
29654         (WebCore):
29655         * bindings/v8/V8Binding.cpp:
29656         (WebCore::toV8Context):
29657         (WebCore):
29658         * bindings/v8/V8Binding.h:
29659         (WebCore):
29660         * bindings/v8/V8PerIsolateData.cpp:
29661         (WebCore):
29662         * bindings/v8/V8PerIsolateData.h:
29663
29664 2012-10-30  Huang Dongsung  <luxtella@company100.net>
29665
29666         [CSS Shaders] Add CustomFilterRenderer to reuse this class by Accelerated Compositing.
29667         https://bugs.webkit.org/show_bug.cgi?id=98989
29668
29669         Reviewed by Dean Jackson.
29670
29671         Extract CustomFilterRenderer class from the rendering part of FECustomFilter.
29672         FECustomFilter now plays a role in extending FilterEffect and delegates
29673         rendering CSS Shaders to CustomFilterRenderer.
29674
29675         CustomFilterRenderer does not know Filter and FilterEffect. We can
29676         create a CustomFilterRenderer instance with only GraphicsContext3D and
29677         CustomFilterValidatedProgram. It means that Accelerated Compositing can
29678         create the CustomFilterRenderer instance if Accelerated Compositing has
29679         GraphicsContext3D and CustomFilterOperation, and it is already possible.
29680
29681         This patch prepares to enable CSS Shaders on Accelerated Compositing.
29682
29683         No new tests. Covered by css3/filters/custom
29684
29685         * CMakeLists.txt:
29686         * GNUmakefile.list.am:
29687         * Target.pri:
29688         * WebCore.gypi:
29689         * WebCore.vcproj/WebCore.vcproj:
29690         * WebCore.xcodeproj/project.pbxproj:
29691         * platform/graphics/filters/CustomFilterRenderer.cpp: Added.
29692         (WebCore):
29693         (WebCore::orthogonalProjectionMatrix):
29694         (WebCore::CustomFilterRenderer::create):
29695         (WebCore::CustomFilterRenderer::CustomFilterRenderer):
29696         (WebCore::CustomFilterRenderer::~CustomFilterRenderer):
29697         (WebCore::CustomFilterRenderer::premultipliedAlpha):
29698         (WebCore::CustomFilterRenderer::programNeedsInputTexture):
29699         (WebCore::CustomFilterRenderer::draw):
29700         (WebCore::CustomFilterRenderer::prepareForDrawing):
29701         (WebCore::CustomFilterRenderer::initializeCompiledProgramIfNeeded):
29702         (WebCore::CustomFilterRenderer::initializeMeshIfNeeded):
29703         (WebCore::CustomFilterRenderer::bindVertexAttribute):
29704         (WebCore::CustomFilterRenderer::unbindVertexAttribute):
29705         (WebCore::CustomFilterRenderer::bindProgramArrayParameters):
29706         (WebCore::CustomFilterRenderer::bindProgramNumberParameters):
29707         (WebCore::CustomFilterRenderer::bindProgramTransformParameter):
29708         (WebCore::CustomFilterRenderer::bindProgramParameters):
29709         (WebCore::CustomFilterRenderer::bindProgramAndBuffers):
29710         (WebCore::CustomFilterRenderer::unbindVertexAttributes):
29711         * platform/graphics/filters/CustomFilterRenderer.h: Copied from Source/WebCore/platform/graphics/filters/FECustomFilter.h.
29712         (WebCore):
29713         (CustomFilterRenderer):
29714           CustomFilterRenderer renders custom filters in GPU using a
29715           GraphicsContext3D.
29716         * platform/graphics/filters/FECustomFilter.cpp:
29717         (WebCore::FECustomFilter::FECustomFilter):
29718         (WebCore::FECustomFilter::create):
29719         (WebCore::FECustomFilter::deleteRenderBuffers):
29720         (WebCore::FECustomFilter::drawFilterMesh):
29721         (WebCore::FECustomFilter::prepareForDrawing):
29722         (WebCore::FECustomFilter::applyShader):
29723         (WebCore::FECustomFilter::resolveMultisampleBuffer):
29724         (WebCore::FECustomFilter::resizeMultisampleBuffers):
29725         (WebCore::FECustomFilter::resizeContext):
29726         * platform/graphics/filters/FECustomFilter.h:
29727         (WebCore):
29728         (FECustomFilter):
29729         * rendering/FilterEffectRenderer.cpp:
29730         (WebCore::createCustomFilterEffect):
29731
29732 2012-10-30  Mike West  <mkwst@chromium.org>
29733
29734         Web Inspector: Associate console messages with the requests that caused them.
29735         https://bugs.webkit.org/show_bug.cgi?id=99941
29736
29737         Reviewed by Pavel Feldman.
29738
29739         The inspector currently supports the concept of a request's "initiator"
29740         in order to add context to console messages that are generated in
29741         response to a specific request. The initiator is used as the message's
29742         anchor link iff a requestID is present, and no stack trace is present.
29743
29744         Currently, this functionality is only exposed to three specific
29745         callsites: 'InspectorConsoleAgent::didFinishXHRLoading',
29746         'InspectorConsoleAgent::didReceiveResponse', and
29747         'InspectorConsoleAgent::didFailLoading'. This patch adds a generic
29748         mechanism to associate requests with console messages by passing the
29749         request's identifier through 'ScriptExecutionContext::addConsoleMessage'
29750         or 'Console::addMessage' when relevant.
29751
29752         This patch should have no visible changes. It just installs some new
29753         piping, and adjusts the three methods mentioned above to use it.
29754         Existing tests shouldn't break.
29755
29756         * dom/Document.cpp:
29757         (WebCore::Document::addMessage):
29758         * dom/Document.h:
29759         (Document):
29760             Add a 'requestIdentifier' parameter (defaulting to 0), and pipe it
29761             through to Console::addMessage.
29762         * dom/ScriptExecutionContext.cpp:
29763         (WebCore::ScriptExecutionContext::addConsoleMessage):
29764         * dom/ScriptExecutionContext.h:
29765         (ScriptExecutionContext):
29766             Add a 'requestIdentifier' parameter (defaulting to 0), and pipe it
29767             through to the subclass' addMessage method.
29768         * inspector/ConsoleMessage.cpp:
29769         (WebCore::ConsoleMessage::ConsoleMessage):
29770             Accept an unsigned long instead of a string, and move the conversion
29771             from WebCore request identifiers to Inspector request identifiers
29772             into ConsoleMessage.
29773         * inspector/ConsoleMessage.h:
29774         (ConsoleMessage):
29775             Add 'requestIdentifier' (defaulting to 0) to the
29776             ConsoleMessage constructor that accepts a ScriptCallStack (it was
29777             already part of the constructor that accepted a line number).
29778         * inspector/IdentifiersFactory.cpp:
29779         (WebCore::IdentifiersFactory::requestId):
29780             If the provided request identifier is 0, return an empty string.
29781             This simplifies the logic at the callsite.
29782         * inspector/InspectorConsoleAgent.cpp:
29783         (WebCore::InspectorConsoleAgent::addMessageToConsole):
29784             Add a 'requestIdentifier' parameter (defaulting to 0), and pipe it
29785             through to the 'ConsoleMessage' constructor after converting it to
29786             an internal identifier via 'IdentifiersFactor::requestId'.
29787         (WebCore::InspectorConsoleAgent::didFinishXHRLoading):
29788         (WebCore::InspectorConsoleAgent::didReceiveResponse):
29789         (WebCore::InspectorConsoleAgent::didFailLoading):
29790             Use the new 'requestIdentifier' parameter on addMessageToConsole
29791             rather than replicating the behavior in each of these three methods.
29792         * inspector/InspectorConsoleAgent.h:
29793         (InspectorConsoleAgent):
29794             Add a 'requestIdentifier' parameter (defaulting to 0).
29795         * inspector/InspectorConsoleInstrumentation.h:
29796         (WebCore::InspectorInstrumentation::addMessageToConsole):
29797         * inspector/InspectorInstrumentation.cpp:
29798         (WebCore):
29799         (WebCore::InspectorInstrumentation::addMessageToConsoleImpl):
29800         * inspector/InspectorInstrumentation.h:
29801         (InspectorInstrumentation):
29802             Add a 'requestIdentifier' parameter (defaulting to 0), and pipe it
29803             through to lower levels of the stack.
29804         * page/Console.cpp:
29805         (WebCore::Console::addMessage):
29806         * page/Console.h:
29807         (Console):
29808             Add a 'requestIdentifier' parameter (defaulting to 0), and pipe it
29809             through to 'InspectorInstrumentation::addMessageToConsole'.
29810         * workers/WorkerContext.cpp:
29811         (WebCore::WorkerContext::addMessage):
29812         (WebCore::WorkerContext::addMessageToWorkerConsole):
29813         * workers/WorkerContext.h:
29814         (WorkerContext):
29815             Add a 'requestIdentifier' parameter (defaulting to 0), and pipe it
29816             through to 'InspectorInstrumentation::addMessageToConsole'.
29817
29818 2012-10-29  Anders Carlsson  <andersca@apple.com>
29819
29820         String::createCFString should return a RetainPtr
29821         https://bugs.webkit.org/show_bug.cgi?id=100419
29822
29823         Reviewed by Andreas Kling.
29824
29825         Update callers of String::createCFString.
29826
29827         * bridge/objc/objc_runtime.mm:
29828         (JSC::Bindings::callObjCFallbackObject):
29829         * html/HTMLMediaElement.cpp:
29830         (WebCore::createFileURLForApplicationCacheResource):
29831         * loader/archive/cf/LegacyWebArchive.cpp:
29832         (WebCore::LegacyWebArchive::createPropertyListRepresentation):
29833         * platform/LocalizedStrings.cpp:
29834         (WebCore::formatLocalizedString):
29835         (WebCore::contextMenuItemTagLookUpInDictionary):
29836         (WebCore::keygenKeychainItemName):
29837         (WebCore::imageTitle):
29838         * platform/RuntimeApplicationChecks.cpp:
29839         (WebCore::mainBundleIsEqualTo):
29840         * platform/cf/FileSystemCF.cpp:
29841         (WebCore::fileSystemRepresentation):
29842         (WebCore::pathAsURL):
29843         * platform/graphics/ca/win/PlatformCAAnimationWin.cpp:
29844         (PlatformCAAnimation::PlatformCAAnimation):
29845         * platform/graphics/ca/win/PlatformCALayerWin.cpp:
29846         (resubmitAllAnimations):
29847         (PlatformCALayer::addAnimationForKey):
29848         (PlatformCALayer::removeAnimationForKey):
29849         (PlatformCALayer::setName):
29850         * platform/graphics/ca/win/PlatformCALayerWinInternal.cpp:
29851         (PlatformCALayerWinInternal::updateTiles):
29852         * platform/graphics/cg/ImageBufferCG.cpp:
29853         (WebCore::utiFromMIMEType):
29854         * platform/graphics/cg/ImageSourceCGMac.mm:
29855         (WebCore::MIMETypeForImageSourceType):
29856         (WebCore::preferredExtensionForImageSourceType):
29857         * platform/mac/ClipboardMac.mm:
29858         (WebCore::cocoaTypeFromHTMLClipboardType):
29859         (WebCore::utiTypeFromCocoaType):
29860         * platform/mac/SSLKeyGeneratorMac.cpp:
29861         (WebCore::signedPublicKeyAndChallengeString):
29862         * platform/network/cf/AuthenticationCF.cpp:
29863         (WebCore::createCF):
29864         * platform/network/cf/CookieJarCFNet.cpp:
29865         (WebCore::setCookies):
29866         * platform/network/cf/DNSCFNet.cpp:
29867         (WebCore::DNSResolveQueue::platformResolve):
29868         * platform/network/cf/ResourceErrorCF.cpp:
29869         (WebCore::ResourceError::cfError):
29870         * platform/network/cf/ResourceHandleCFNet.cpp:
29871         (WebCore::setDefaultMIMEType):
29872         (WebCore::willSendRequest):
29873         (WebCore::ResourceHandle::didReceiveAuthenticationChallenge):
29874         (WebCore::ResourceHandle::setPrivateBrowsingEnabled):
29875         * platform/network/cf/ResourceRequestCFNet.cpp:
29876         (WebCore::setHeaderFields):
29877         (WebCore::ResourceRequest::doUpdatePlatformRequest):
29878         * platform/network/cf/ResourceResponseCFNet.cpp:
29879         (WebCore::ResourceResponse::cfURLResponse):
29880         * platform/network/cf/SocketStreamHandleCFNet.cpp:
29881         (WebCore::SocketStreamHandle::createStreams):
29882         (WebCore::SocketStreamHandle::addCONNECTCredentials):
29883         (WebCore::SocketStreamHandle::copyCFStreamDescription):
29884         * platform/network/mac/ResourceRequestMac.mm:
29885         (WebCore::ResourceRequest::doUpdatePlatformRequest):
29886         * platform/network/mac/WebCoreURLResponse.mm:
29887         (WebCore::adjustMIMETypeIfNecessary):
29888         * platform/text/cf/HyphenationCF.cpp:
29889         (WebCore::::createValueForKey):
29890         * platform/text/cf/StringCF.cpp:
29891         (WTF::String::createCFString):
29892         * platform/text/cf/StringImplCF.cpp:
29893         (WTF::StringImpl::createCFString):
29894         * platform/text/mac/StringImplMac.mm:
29895         (WTF::StringImpl::operator NSString *):
29896         * platform/text/mac/TextCodecMac.cpp:
29897         (WebCore::TextCodecMac::encode):
29898         * platform/win/SearchPopupMenuWin.cpp:
29899         (WebCore::autosaveKey):
29900         (WebCore::SearchPopupMenuWin::saveRecentSearches):
29901
29902 2012-10-30  Chris Fleizach  <cfleizach@apple.com>
29903
29904         AX: Support embedded SVG objects in AX tree
29905         https://bugs.webkit.org/show_bug.cgi?id=97571
29906
29907         Reviewed by Tim Horton.
29908
29909         This patch allows an SVG image from another resource to be hooked into the AX
29910         hierarchy. This is done by creating an AX wrapper for the root SVG that holds onto
29911         its native parent image. The SVGChromeClient is then used to connect to this SVG resource.
29912
29913         Test: accessibility/svg-remote-element.html
29914
29915         * CMakeLists.txt:
29916         * GNUmakefile.list.am:
29917         * WebCore.gypi:
29918         * WebCore.vcproj/WebCore.vcproj:
29919         * WebCore.xcodeproj/project.pbxproj:
29920         * accessibility/AXObjectCache.cpp:
29921         (WebCore::createFromRenderer):
29922         * accessibility/AccessibilityAllInOne.cpp:
29923         * accessibility/AccessibilityObject.h:
29924         (WebCore::AccessibilityObject::isAccessibilitySVGRoot):
29925         (AccessibilityObject):
29926         * accessibility/AccessibilityRenderObject.cpp:
29927         (WebCore::AccessibilityRenderObject::detach):
29928         (WebCore::AccessibilityRenderObject::offsetBoundingBoxForRemoteSVGElement):
29929         (WebCore::AccessibilityRenderObject::boundingBoxRect):
29930         (WebCore::AccessibilityRenderObject::remoteSVGElementHitTest):
29931         (WebCore::AccessibilityRenderObject::elementAccessibilityHitTest):
29932         (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
29933         (WebCore::AccessibilityRenderObject::isSVGImage):
29934         (WebCore::AccessibilityRenderObject::detachRemoteSVGRoot):
29935         (WebCore::AccessibilityRenderObject::remoteSVGRootElement):
29936         (WebCore::AccessibilityRenderObject::addRemoteSVGChildren):
29937         (WebCore::AccessibilityRenderObject::addChildren):
29938         * accessibility/AccessibilityRenderObject.h:
29939         (AccessibilityRenderObject):
29940         * accessibility/AccessibilitySVGRoot.cpp: Added.
29941         (WebCore::AccessibilitySVGRoot::AccessibilitySVGRoot):
29942         (WebCore::AccessibilitySVGRoot::~AccessibilitySVGRoot):
29943         (WebCore::AccessibilitySVGRoot::create):
29944         (WebCore::AccessibilitySVGRoot::parentObject):
29945         * accessibility/AccessibilitySVGRoot.h: Added.
29946         (AccessibilitySVGRoot): Class provides ability to wrap the SVG root of a remote accessibility element.
29947         (WebCore::AccessibilitySVGRoot::setParent):
29948         (WebCore::AccessibilitySVGRoot::isAccessibilitySVGRoot):
29949         (WebCore::toAccessibilitySVGRoot):
29950         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
29951         (-[WebAccessibilityObjectWrapper position]): The position of AX elements within a remote SVG element needs to be handled 
29952         in a special manner.
29953         (createAccessibilityRoleMap):
29954         * loader/EmptyClients.h:
29955         (EmptyChromeClient): Expose isEmptyChromeClient() so Accessibility will know when to apply different policies for finding
29956         the accessibility bounding rect of elements.
29957         (WebCore::EmptyChromeClient::isEmptyChromeClient):
29958         * page/ChromeClient.h:
29959         (WebCore::ChromeClient::isEmptyChromeClient):
29960         (ChromeClient):
29961         * svg/graphics/SVGImage.cpp:
29962         * svg/graphics/SVGImageChromeClient.h: Added.
29963         (SVGImageChromeClient): Expose the SVGImageChromeClient so that Accessibility can reference its image.
29964         (WebCore::SVGImageChromeClient::SVGImageChromeClient):
29965         (WebCore::SVGImageChromeClient::isSVGImageChromeClient):
29966         (WebCore::SVGImageChromeClient::image):
29967         (WebCore::SVGImageChromeClient::chromeDestroyed):
29968         (WebCore::SVGImageChromeClient::invalidateContentsAndRootView):
29969         (WebCore::toSVGImageChromeClient):
29970
29971 2012-10-30  Dan Carney  <dcarney@google.com>
29972
29973         add 7 bit strings capabilities to the v8 binding layer
29974         https://bugs.webkit.org/show_bug.cgi?id=91850
29975
29976         Reviewed by Adam Barth.
29977
29978         This change enables the v8 binding layer to make use of webkit's
29979         8 bit string capabilities. Using 8 bit strings leads to certain
29980         benchmark performance improvemnts as can be seen in
29981         https://bug-91850-attachments.webkit.org/attachment.cgi?id=163334.
29982
29983         No new tests. Test coverage already extensive.
29984
29985         * bindings/v8/V8PerIsolateData.cpp:
29986         (WebCore::V8PerIsolateData::visitExternalStrings):
29987         * bindings/v8/V8StringResource.cpp:
29988         (StringTraits):
29989         (WebCore::false):
29990         (WebCore):
29991         (WebCore::true):
29992         (WebCore::v8StringToWebCoreString):
29993         * bindings/v8/V8ValueCache.cpp:
29994         (WebCore::makeExternalString):
29995         (WebCore::WebCoreStringResourceBase::visitStrings):
29996         * bindings/v8/V8ValueCache.h:
29997         (WebCore::WebCoreStringResourceBase::WebCoreStringResourceBase):
29998         (WebCore::WebCoreStringResourceBase::~WebCoreStringResourceBase):
29999         (WebCore::WebCoreStringResourceBase::atomicString):
30000         (WebCoreStringResourceBase):
30001         (WebCore::WebCoreStringResourceBase::memoryConsumption):
30002
30003 2012-10-30  Christophe Dumez  <christophe.dumez@intel.com>
30004
30005         [AC] Fix compilation warnings when enabling Accelerated Compositing
30006         https://bugs.webkit.org/show_bug.cgi?id=100741
30007
30008         Reviewed by Kenneth Rohde Christiansen.
30009
30010         Fix a few compilation warnings when building EFL port
30011         with accelerated compositing enabled.
30012
30013         No new tests, no behavior change.
30014
30015         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
30016         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
30017         (WebCore::resolveGLMethods):
30018         (WebCore::GraphicsSurface::platformCopyToGLTexture):
30019         (WebCore::GraphicsSurface::platformLock):
30020         * platform/graphics/texmap/TextureMapperGL.cpp:
30021         (WebCore::BitmapTextureGL::updateContents):
30022
30023 2012-10-30  No'am Rosenthal  <noam.rosenthal@nokia.com>
30024
30025         [Qt] Animations jump when the page is suspended
30026         https://bugs.webkit.org/show_bug.cgi?id=100673
30027
30028         Reviewed by Kenneth Rohde Christiansen.
30029
30030         GraphicsLayerAnimations::pause() should accept time from start and not an offset.
30031
30032         We need to support the "freeze" API before this can be reliably tested.
30033         See https://bugs.webkit.org/show_bug.cgi?id=100703.
30034
30035         * platform/graphics/GraphicsLayerAnimation.cpp:
30036         (WebCore::GraphicsLayerAnimation::pause):
30037
30038 2012-10-30  Kondapally Kalyan  <kalyan.kondapally@intel.com>
30039
30040         [Qt][EFL][AC] While Using WebGL, MiniBrowser segfaults on Refreshing the page.
30041         https://bugs.webkit.org/show_bug.cgi?id=100639.
30042
30043         Reviewed by Kenneth Rohde Christiansen.
30044
30045         TextureMapperSurfaceBackingStore can import textures from a GraphicSurface.
30046         In such cases GraphicsSurfaceGLX creates an XPixmap to read texture content
30047         from a given WindowId, but doesn't create any new window.
30048         However, OffScreenRootWindow always tries to unmap window (in its destructor) resulting in segfault.
30049         With this patch OffScreenRootWindow would check for a valid window before trying to unmap it.
30050
30051         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
30052         (WebCore::OffScreenRootWindow::~OffScreenRootWindow):
30053
30054 2012-10-30  Emil A Eklund  <eae@chromium.org>
30055
30056         [subixel] Change LineWidth::shrinkAvailableWidthForNewFloatIfNeeded to not pixel snap
30057         https://bugs.webkit.org/show_bug.cgi?id=100742
30058
30059         Reviewed by Levi Weintraub.
30060
30061         As we no longer pixel snap values when computing the current width for a
30062         line we should not do it in shrinkAvailableWidthForNewFloatIfNeeded
30063         either.
30064
30065         Test: fast/sub-pixel/float-wrap-zoom.html
30066
30067         * rendering/RenderBlockLineLayout.cpp:
30068         (WebCore::LineWidth::LineWidth): Remove unnecessary ifdef.
30069         (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded): Use float values instead of pixel snapped/floored values as the line width calculations uses floats.
30070
30071 2012-10-30  Max Vujovic  <mvujovic@adobe.com>
30072
30073         [CSS Shaders] Reject vertex shaders with custom attributes
30074         https://bugs.webkit.org/show_bug.cgi?id=98973
30075
30076         Reviewed by Dean Jackson.
30077
30078         Improved CSS Custom Filters shader validation. With this patch:
30079         (1) Shaders with custom attributes do not execute (e.g. attribute float my_attribute;).
30080         (2) Shaders with a_triangleCoord defined do not execute with an attached mesh.
30081
30082         Most of the changes are from renaming CustomFilterOperation::MeshType to
30083         CustomFilterMeshType, and moving the enumeration to CustomFilterConstants.h. This avoids
30084         pulling in CustomFilterOperation for classes that only care about the mesh type.
30085
30086         Note that in CSS Custom Filters, the a_triangleCoord attribute is only available in detached
30087         meshes. In detached meshes, no vertices are shared between triangles. Thus, each vertex
30088         belongs to a specific triangle, which a_triangleCoord identifies. In attached meshes,
30089         vertices can belong to many triangles, which a_triangleCoord cannot identify because it's
30090         only a vec3.
30091
30092         Tests:
30093         Add two new checks to the test file:
30094             css3/filters/custom/invalid-custom-filter-attribute-types.html
30095         Add two new shaders:
30096             css3/filters/resources/invalid-custom-attribute.vs
30097             css3/filters/resources/invalid-a-triangle-coord-with-attached-mesh.vs
30098
30099         * WebCore.xcodeproj/project.pbxproj:
30100             Update a broken reference to CustomFilterConstants.h in the Xcode project file.
30101         * css/CSSComputedStyleDeclaration.cpp:
30102         (WebCore::CSSComputedStyleDeclaration::valueForFilter):
30103             Replace CustomFilterOperation::MeshType with CustomFilterMeshType.
30104         * css/StyleResolver.cpp:
30105         (WebCore::StyleResolver::createCustomFilterOperation): Ditto.
30106         * platform/graphics/filters/CustomFilterConstants.h:
30107             Add CustomFilterMeshType enum to share across the Custom Filters codebase, so that we
30108             don't have to include CustomFilterOperation just to access the old
30109             CustomFilterOperation::MeshType enum.
30110         * platform/graphics/filters/CustomFilterMesh.cpp:
30111         (WebCore::CustomFilterMesh::CustomFilterMesh):
30112             Replace CustomFilterOperation::MeshType with CustomFilterMeshType.
30113         * platform/graphics/filters/CustomFilterMesh.h:
30114         (WebCore::CustomFilterMesh::create): Ditto.
30115         (WebCore::CustomFilterMesh::meshType): Ditto.
30116         (CustomFilterMesh): Ditto.
30117         * platform/graphics/filters/CustomFilterMeshGenerator.cpp: Ditto.
30118         (WebCore::CustomFilterMeshGenerator::CustomFilterMeshGenerator): Ditto.
30119         (WebCore::CustomFilterMeshGenerator::dumpBuffers): Ditto.
30120         * platform/graphics/filters/CustomFilterMeshGenerator.h:
30121         (CustomFilterMeshGenerator): Ditto.
30122         (WebCore::CustomFilterMeshGenerator::floatsPerVertex): Ditto.
30123         (WebCore::CustomFilterMeshGenerator::verticesCount): Ditto.
30124         * platform/graphics/filters/CustomFilterOperation.cpp: 
30125         (WebCore::CustomFilterOperation::CustomFilterOperation): Ditto.
30126         * platform/graphics/filters/CustomFilterOperation.h:
30127         (WebCore::CustomFilterOperation::create): Ditto.
30128         (WebCore::CustomFilterOperation::meshType): Ditto.
30129         (CustomFilterOperation): Ditto.
30130         * platform/graphics/filters/CustomFilterProgram.cpp:
30131         (WebCore::CustomFilterProgram::CustomFilterProgram):
30132             Add a meshType constructor parameter because the program now needs to know the meshType
30133             to properly validate.
30134         (WebCore::CustomFilterProgram::programInfo):
30135             Pass meshType to CustomFilterProgram constructor.
30136         (WebCore::CustomFilterProgram::operator==):
30137             Check the meshType in the equals operator.
30138         * platform/graphics/filters/CustomFilterProgram.h:
30139             Make vertexShaderString() and fragmentShaderString() public so that we don't have to ask
30140             for a programInfo object just to get the shader strings in
30141             CoordinatedGraphicsArgumentCoders.cpp.
30142         * platform/graphics/filters/CustomFilterProgramInfo.cpp:
30143         (WebCore::CustomFilterProgramInfo::CustomFilterProgramInfo):
30144             Add a meshType constructor parameter.       
30145         (WebCore::CustomFilterProgramInfo::hash):
30146             Include the meshType in the validated program hash, since the same shader code can pass
30147             or fail validation based on the meshType.
30148         (WebCore::CustomFilterProgramInfo::operator==):
30149             Check the meshType in the equals operator.
30150         * platform/graphics/filters/CustomFilterProgramInfo.h:
30151         (CustomFilterProgramInfo):
30152             Update method prototype.
30153         (WebCore::CustomFilterProgramInfo::meshType):
30154             Add meshType getter.
30155         * platform/graphics/filters/CustomFilterValidatedProgram.cpp:
30156         (WebCore::CustomFilterValidatedProgram::validateSymbols):
30157             If the author defines attribute that is is not found in the built-in attribute map,
30158             reject the shader.
30159             If the author defines a_triangleCoord without a detached mesh type, reject the shader.
30160             Also, make this previously file-static function into a method of
30161             CustomFilterValidatedProgram because it now needs to access the m_meshType.
30162         * platform/graphics/filters/CustomFilterValidatedProgram.h:
30163         (CustomFilterValidatedProgram):
30164             Add a meshType constructor parameter because the program now needs to know the meshType
30165             to properly validate.
30166         * platform/graphics/filters/FECustomFilter.cpp:
30167         (WebCore::FECustomFilter::FECustomFilter):
30168             Replace CustomFilterOperation::MeshType with CustomFilterMeshType.
30169         (WebCore::FECustomFilter::create): Ditto.
30170         (WebCore::FECustomFilter::bindProgramAndBuffers): Ditto.
30171         (WebCore::FECustomFilter::unbindVertexAttributes): Ditto.
30172         * platform/graphics/filters/FECustomFilter.h:
30173         (FECustomFilter): Ditto.
30174         * rendering/style/StyleCustomFilterProgram.h:
30175         (WebCore::StyleCustomFilterProgram::create):
30176             Add a meshType constructor parameter.
30177         (WebCore::StyleCustomFilterProgram::StyleCustomFilterProgram): Ditto.
30178
30179 2012-10-30  Andrey Lushnikov  <lushnikov@google.com>
30180
30181         Web Inspector: adds isOwnProperty to remote protocol
30182         https://bugs.webkit.org/show_bug.cgi?id=100664
30183
30184         Reviewed by Pavel Feldman.
30185
30186         Test: inspector/runtime/runtime-getProperties-isOwnProperty.html
30187
30188         Adds requested 'isOwn' property to the 'PropertyDescriptor' class of the
30189         remote debugging protocol. 
30190
30191         * inspector/InjectedScriptSource.js:
30192         (.):
30193         * inspector/Inspector.json:
30194
30195 2012-10-30  Zeno Albisser  <zeno@webkit.org>
30196
30197         [Qt][Win] BitmapTextureGL::updateContents() broken after r132019.
30198         https://bugs.webkit.org/show_bug.cgi?id=100680
30199
30200         When creating a temporary for swizzling the image data,
30201         the temporary will have the target size.
30202         Therefore no offset within the available image data
30203         shall be applied in this case.
30204
30205         Reviewed by Noam Rosenthal.
30206
30207         * platform/graphics/texmap/TextureMapperGL.cpp:
30208         (WebCore::BitmapTextureGL::updateContents):
30209
30210 2012-10-30  Kent Tamura  <tkent@chromium.org>
30211
30212         Remove unused code for old input[type=date] UI
30213         https://bugs.webkit.org/show_bug.cgi?id=100734
30214
30215         Reviewed by Hajime Morita.
30216
30217         The old input[type=date] UI used in Google Chrome 20-23 (text field with
30218         a fixed placeholder) was replaced with ENABLE_INPUT_MULTIPLE_FIELDS_UI.
30219
30220         No new tests because of no behavior changes.
30221
30222         * html/DateInputType.cpp: Remove ENABLE_INPUT_TYPE_DATE_LEGACY_UI code path.
30223         * html/DateInputType.h: Ditto.
30224
30225         * html/HTMLInputElement.cpp:
30226         (WebCore::HTMLInputElement::supportsPlaceholder):
30227         Remove fixed-placeholder feature.
30228         * html/HTMLInputElement.h:
30229         (HTMLInputElement): Ditto.
30230         * html/HTMLTextFormControlElement.h:
30231         (HTMLTextFormControlElement): isPlaceholderEmpty() is not needed to be virtual
30232         * html/InputType.cpp: Remove fixed-placeholder feature.
30233         * html/InputType.h: Ditto.
30234         * html/TextFieldInputType.cpp:
30235         (WebCore::TextFieldInputType::updatePlaceholderText): Ditto.
30236
30237         * platform/text/PlatformLocale.h:
30238         (Locale): Remove dateFormatText.
30239         * platform/text/LocaleICU.cpp: Ditto.
30240         * platform/text/LocaleICU.h: Ditto.
30241         * platform/text/LocaleNone.cpp: Ditto.
30242         * platform/text/mac/LocaleMac.h: Ditto.
30243         * platform/text/mac/LocaleMac.mm: Ditto.
30244         * platform/text/win/LocaleWin.cpp: Ditto.
30245         * platform/text/win/LocaleWin.h: Ditto.
30246         * platform/LocalizedStrings.h:
30247         (WebCore): Remove unused functions; calendarTodayText,
30248         calendarClearText, dateFormatYearText, dateFormatMonthText,
30249         dateFormatDayInMonthText
30250
30251 2012-10-30  Kent Tamura  <tkent@chromium.org>
30252
30253         Fix crash by calendar picker or suggestion picker
30254         https://bugs.webkit.org/show_bug.cgi?id=100728
30255
30256         Reviewed by Hajime Morita.
30257
30258         Change DateTimeChooser so that it is ref-coutned.
30259
30260         Test: platform/chromium/fast/forms/calendar-picker/calendar-picker-type-change-onchange.html
30261
30262         * platform/DateTimeChooser.h: Made DateTimeChooser RefCounted.
30263         * page/ChromeClient.h:
30264         (ChromeClient): openDateTimeChooser should return PassRefPtr<DateTimeChooser>.
30265         * loader/EmptyClients.h:
30266         (EmptyChromeClient): Follow the above change.
30267         * loader/EmptyClients.cpp:
30268         (WebCore::EmptyChromeClient::openDateTimeChooser): Ditto.
30269
30270         * html/shadow/PickerIndicatorElement.h:
30271         (PickerIndicatorElement): Hold DateTimeChooser in RefPtr<DateTimeChooser>.
30272         * html/shadow/PickerIndicatorElement.cpp:
30273         (WebCore::PickerIndicatorElement::PickerIndicatorElement):
30274         Remove unnecessary initialization.
30275
30276 2012-10-30  Eugene Klyuchnikov  <eustas.bug@gmail.com>
30277
30278         Web Inspector: Timeline: promote "cpu activity" out of experiment
30279         https://bugs.webkit.org/show_bug.cgi?id=100726
30280
30281         Reviewed by Pavel Feldman.
30282
30283         1. CPU actibity bars redesigned
30284         2. Experiment setting removed
30285         3. Feature setting added
30286
30287         * English.lproj/localizedStrings.js: Updated setting label.
30288         * inspector/front-end/Settings.js: Replaced experiment with setting.
30289         * inspector/front-end/SettingsScreen.js: Added new setting.
30290         * inspector/front-end/TimelinePanel.js: Update cpu bars appearance.
30291         * inspector/front-end/timelinePanel.css: Ditto.
30292
30293 2012-10-30  Michelangelo De Simone  <michelangelo@webkit.org>
30294
30295         [CSS Shaders] Change the default compositing mode and the default CSS value for <fragmentShader>
30296         https://bugs.webkit.org/show_bug.cgi?id=94020
30297
30298         Reviewed by Dean Jackson.
30299
30300         The default compositing mode has been changed from "normal source-over" to
30301         "normal source-atop". This applies to the default fragment shader that will
30302         kick in when there is no explicit fragment shader or mix function defined.
30303
30304         This has required to update all the existing tests; the dummy empty fragment
30305         shader has also been removed because not needed.
30306
30307         * css/CSSComputedStyleDeclaration.cpp:
30308         (WebCore::CSSComputedStyleDeclaration::valueForFilter): An existence check
30309         for the fragment shader has been added.
30310         * css/StyleResolver.cpp:
30311         (WebCore::StyleResolver::createCustomFilterOperation): The default program
30312         has been updated: PROGRAM_TYPE_BLENDS_TEXTURE (compositing enabled) now is
30313         the default.
30314         * platform/graphics/filters/CustomFilterProgramInfo.h:
30315         (WebCore::CustomFilterProgramMixSettings::CustomFilterProgramMixSettings):
30316         New CustomFilterProgramMixSettings defaults to "source-atop" composite
30317         operator.
30318
30319 2012-10-30  Ádám Kallai  <kadam@inf.u-szeged.hu>
30320
30321         [Qt][Mac] Unreviewed build fix.
30322         https://bugs.webkit.org/show_bug.cgi?id=100727.
30323
30324         Speculative build fix after 132858. Include missing CoreFoundation/CoreFoundation.h header.
30325
30326         * platform/text/cf/AtomicStringCF.cpp:
30327
30328 2012-10-30  Gabor Rapcsanyi  <rgabor@webkit.org>
30329
30330         Optimize vclip for NEON in VectorMath
30331         https://bugs.webkit.org/show_bug.cgi?id=100737
30332
30333         Reviewed by Zoltan Herczeg.
30334
30335         Speed up vclip in VectorMath with NEON intrinsics.
30336
30337         * platform/audio/VectorMath.cpp:
30338         (WebCore::VectorMath::vclip):
30339
30340 2012-10-30  Alexandru Chiculita  <achicu@adobe.com>
30341
30342         [CSS Shaders] Software and composited filters should have a common path
30343         https://bugs.webkit.org/show_bug.cgi?id=100532
30344
30345         Reviewed by Dean Jackson.
30346
30347         Added computeFilterOperations as a common method between the software filters
30348         and hardware composited ones. The method rejects custom filters that are not
30349         loaded yet. In bug 100533 it will also convert the CustomFilterOperation to a 
30350         ValidatedCustomFilterOperation. That will help us keep the loading and verification 
30351         code for the custom filters common across all the ports.
30352
30353         No new tests, just refactoring existing code.
30354
30355         * rendering/RenderLayer.cpp:
30356         (WebCore::RenderLayer::computeFilterOperations):
30357         (WebCore):
30358         (WebCore::RenderLayer::updateOrRemoveFilterEffect):
30359         * rendering/RenderLayer.h:
30360         (WebCore):
30361         (RenderLayer):
30362         * rendering/RenderLayerBacking.cpp:
30363         (WebCore::RenderLayerBacking::updateFilters):
30364
30365 2012-10-30  Alexei Filippov  <alph@chromium.org>
30366
30367         Web Inspector: Implement native memory snapshot grid view
30368         https://bugs.webkit.org/show_bug.cgi?id=100656
30369
30370         Native memory snapshots are now shown as an expandable tree form
30371         using the grid control.
30372
30373         Reviewed by Yury Semikhatsky.
30374
30375         * inspector/front-end/NativeMemorySnapshotView.js:
30376         (WebInspector.NativeMemorySnapshotView):
30377         (WebInspector.NativeSnapshotDataGrid):
30378         (WebInspector.NativeSnapshotNode):
30379         (WebInspector.NativeSnapshotNode.prototype.createCell):
30380         (WebInspector.NativeSnapshotNode.prototype._createSizeCell):
30381         (WebInspector.NativeSnapshotNode.prototype._populate):
30382         (WebInspector.MemoryBlockViewProperties._initialize):
30383         (WebInspector.MemoryBlockViewProperties._forMemoryBlock):
30384         * inspector/front-end/dataGrid.css:
30385         (.data-grid td):
30386         * inspector/front-end/nativeMemoryProfiler.css:
30387         (.memory-bar-chart-bar):
30388         (.native-snapshot-view):
30389         (.native-snapshot-view.visible):
30390         (.native-snapshot-view .data-grid):
30391         (.native-snapshot-view .data-grid table):
30392         (.native-snapshot-view .data-grid div.size-text):
30393         (.native-snapshot-view .data-grid div.size-bar):
30394         (.native-snapshot-view .data-grid div.percent-text):
30395
30396 2012-10-30  Zoltan Nyul  <zoltan.nyul@intel.com>
30397
30398         3d rotation with [0, 0, 0] direction vector should not be applied
30399         https://bugs.webkit.org/show_bug.cgi?id=100733
30400
30401         Reviewed by Levi Weintraub.
30402
30403         As stated in the specification (http://dev.w3.org/csswg/css3-3d-transforms/#transform-functions),
30404         a direction vector that cannot be normalized, such as [0, 0, 0], will cause the rotation to not be applied,
30405         but webkit applies it with [1, 0, 0] direction vector.
30406
30407         Test: transforms/3d/general/3dtransform-values.html
30408
30409         * platform/graphics/transforms/TransformationMatrix.cpp:
30410         (WebCore::TransformationMatrix::rotate3d):
30411
30412 2012-10-30  Yury Semikhatsky  <yurys@chromium.org>
30413
30414         Memory instrumentation: report actual object address for CachedResourceClients
30415         https://bugs.webkit.org/show_bug.cgi?id=100659
30416
30417         Reviewed by Alexander Pavlov.
30418
30419         Skipped pointers to objects that are not allocated on the heap directly.
30420
30421         To test this we need to compare addresses of objects traversed by the memory
30422         insrumentation with those allocated by the memory allocator. The latter set
30423         should include the former one.
30424
30425         * css/StyleResolver.cpp:
30426         (WTF): skip pointers to RuleData structures as they are stored by value in RuleSet
30427         objects and should not be reported separately.
30428         * loader/cache/CachedResource.cpp:
30429         (WTF): do not report memory occupied by CachedResourceClients as objects implementing
30430         the interface may have address which differ from CachedResourceClient*. The clients
30431         should be reachable from their instrumented owners where we know exact type of the
30432         clients and hence can figure correct address.
30433
30434 2012-10-29  Shinya Kawanaka  <shinyak@chromium.org>
30435
30436         [Refatoring] Remove ElementShadow::insertionPointFor
30437         https://bugs.webkit.org/show_bug.cgi?id=100625
30438
30439         Reviewed by Hajime Morita.
30440
30441         Now that ElementShadow::insertionPointFor does not do any special things, and it's only used in
30442         ComposedShadowTreeWalker. So we can remove it.
30443
30444         No new tests, simple refactoring.
30445
30446         * dom/ComposedShadowTreeWalker.cpp:
30447         (WebCore::resolveReprojection):
30448         (WebCore::AncestorChainWalker::parent):
30449         * dom/ElementShadow.cpp:
30450         * dom/ElementShadow.h:
30451         (ElementShadow):
30452         * dom/ShadowRoot.h: ShadowRoot has insertionPointFor declaration, but we don't have any implementation.
30453         We should remove it.
30454
30455 2012-10-29  Andy Estes  <aestes@apple.com>
30456
30457         Fix a typo that caused SVG external resources to be blocked on
30458         platforms other than Chromium.
30459
30460         * loader/cache/CachedResourceLoader.cpp:
30461         (WebCore::CachedResourceLoader::canRequest):
30462
30463 2012-10-29  Keishi Hattori  <keishi@webkit.org>
30464
30465         NSLocale leaks in LocaleMac
30466         https://bugs.webkit.org/show_bug.cgi?id=97628
30467
30468         Reviewed by Kent Tamura.
30469
30470         We need to adopt the NSLocale object so it doesn't leak and
30471         determineLocale() should return a NSLocale without additional retain.
30472
30473         No new tests.
30474
30475         * platform/text/mac/LocaleMac.mm:
30476         (WebCore::determineLocale): Returns a RetainPtr<NSLocale>.
30477         (WebCore::Locale::create):
30478         (WebCore::LocaleMac::LocaleMac): m_locale should adopt the NSLocale object.
30479         (WebCore::LocaleMac::create): LocaleMac constructor takes NSLocale without additional retain.
30480
30481 2012-10-29  Charles Wei  <charles.wei@torchmobile.com.cn>
30482
30483         [BlackBerry] Disable redirect to data scheme for potential fishing.
30484         https://bugs.webkit.org/show_bug.cgi?id=100713
30485
30486         Reviewed by George Staikos.
30487
30488         We will disable redirect to data scheme to avoid potential security concern, 
30489         described in klevjers.com/papers/phishing.pdf.
30490
30491
30492         * platform/network/blackberry/NetworkJob.cpp:
30493         (WebCore::NetworkJob::handleRedirect):
30494
30495 2012-10-29  Vincent Scheib  <scheib@chromium.org>
30496
30497         Unreviewed, rolling out r132845.
30498         http://trac.webkit.org/changeset/132845
30499         https://bugs.webkit.org/show_bug.cgi?id=99975
30500
30501         Broke chromium builds, linker errors from
30502         IDBBindingUtilitiesTest
30503
30504         * Modules/indexeddb/IDBRequest.cpp:
30505         (WebCore::IDBRequest::IDBRequest):
30506         (WebCore::IDBRequest::onSuccess):
30507         (WebCore::IDBRequest::dispatchEvent):
30508         * Modules/indexeddb/IDBRequest.h:
30509         (IDBRequest):
30510         * bindings/v8/IDBBindingUtilities.cpp:
30511         (WebCore::createIDBKeyFromScriptValueAndKeyPath):
30512         (WebCore):
30513         (WebCore::deserializeIDBValue):
30514         (WebCore::injectIDBKeyIntoScriptValue):
30515         (WebCore::idbKeyToScriptValue):
30516         * bindings/v8/V8PerIsolateData.cpp:
30517         (WebCore::V8PerIsolateData::ensureAuxiliaryContext):
30518         (WebCore):
30519         * bindings/v8/V8PerIsolateData.h:
30520         (V8PerIsolateData):
30521
30522 2012-10-29  Anders Carlsson  <andersca@apple.com>
30523
30524         Fix Windows build.
30525
30526         * platform/network/cf/ResourceRequestCFNet.cpp:
30527         (WebCore::setHeaderFields):
30528
30529 2012-10-28  Mark Rowe  <mrowe@apple.com>
30530
30531         Simplify Xcode configuration settings that used to vary between OS versions.
30532
30533         Reviewed by Dan Bernstein.
30534
30535         * Configurations/Base.xcconfig:
30536         * Configurations/DebugRelease.xcconfig:
30537         * Configurations/WebCore.xcconfig:
30538
30539 2012-10-28  Mark Rowe  <mrowe@apple.com>
30540
30541         Remove references to unsupported OS and Xcode versions.
30542
30543         Reviewed by Anders Carlsson.
30544
30545         * Configurations/Base.xcconfig:
30546         * Configurations/CompilerVersion.xcconfig: Removed.
30547         * Configurations/DebugRelease.xcconfig:
30548         * Configurations/Version.xcconfig:
30549         * Configurations/WebCore.xcconfig:
30550         * DerivedSources.make:
30551         * WebCore.xcodeproj/project.pbxproj:
30552
30553 2012-10-29  Anders Carlsson  <andersca@apple.com>
30554
30555         AtomicString(CFStringRef) shouldn't unconditionally create a StringImpl
30556         https://bugs.webkit.org/show_bug.cgi?id=100701
30557
30558         Reviewed by Dan Bernstein.
30559
30560         * WebCore.exp.in:
30561         Export AtomicString::add(CFStringRef).
30562
30563         * Target.pri:
30564         * WebCore.gypi:
30565         * WebCore.vcproj/WebCore.vcproj:
30566         * WebCore.xcodeproj/project.pbxproj:
30567         Add AtomicStringCF.cpp 
30568
30569         * platform/text/cf/AtomicStringCF.cpp: Added.
30570         (WTF::AtomicString::add):
30571         When trying to add the atomic string to the table, first try to get a Latin-1 pointer
30572         from the string. Second, try to get a Unicode pointer from the string.
30573         If that also fails, copy the string to a temporary unicode buffer and add it from there.
30574
30575         * platform/text/cf/HyphenationCF.cpp:
30576         (WebCore::::createValueForKey):
30577         Update for AtomicString::createCFString being removed.
30578
30579 2012-10-25  Stephen Chenney  <schenney@chromium.org>
30580
30581         feImage should not be allowed to self reference
30582         https://bugs.webkit.org/show_bug.cgi?id=94652
30583
30584         Reviewed by Eric Seidel.
30585
30586         Add cycle detection for SVG filter application, and also fix a problem
30587         with graphics context restore when filters are applied. This also
30588         converts the flags in FilterData to a state tracking system, as the
30589         number of flags was getting messy and only one flag is valid at any given time.
30590
30591         Test: svg/filters/feImage-self-and-other-referencing.html
30592
30593         * rendering/svg/RenderSVGResourceFilter.cpp: Convert to new FilterData
30594         state management and enable cycle detection.
30595         (WebCore):
30596         (WebCore::RenderSVGResourceFilter::removeClientFromCache): Change isBuilt and markedForRemoval flags to state enums.
30597         (WebCore::RenderSVGResourceFilter::applyResource): Change flags to state enums and detect cycles.
30598         (WebCore::RenderSVGResourceFilter::postApplyResource): Change flags to state and add handling
30599         for the various states.
30600         (WebCore::RenderSVGResourceFilter::primitiveAttributeChanged): Change isBuilt flag to state enums.
30601         * rendering/svg/RenderSVGResourceFilter.h:
30602         (WebCore::FilterData::FilterData):
30603         (FilterData): Convert to a state tracking system.
30604         * rendering/svg/RenderSVGRoot.cpp:
30605         (WebCore::RenderSVGRoot::paintReplaced): Add a block around the
30606         SVGRenderingContext so that it applies the filter and reverts the
30607         context before the calling method restores the context.
30608
30609 2012-10-29  Dan Bernstein  <mitz@apple.com>
30610
30611         <rdar://problem/12592716> REGRESSION (r132545): With full-page accelerated drawing, a
30612         reproducible hang occurs at <http://www.cbsnews.com/stories/2010/01/24/ftn/main6136386.shtml>.
30613
30614         Reviewed by Anders Carlsson.
30615
30616         Work around <rdar://problem/12584492> by limiting the scope of the fix for <http://webkit.org/b/100413>.
30617
30618         * platform/graphics/cg/GraphicsContextCG.cpp:
30619         (WebCore::GraphicsContext::clipOut): Reverted to using CGContextGetClipBoundingBox() rather
30620         than CGRectInfinite when the context is accelerated and has a transform that is not just
30621         a translation or a scale.
30622
30623 2012-10-29  Rob Buis  <rbuis@rim.com>
30624
30625         [BlackBerry] Simplify AuthenticationChallengeManager::instance
30626         https://bugs.webkit.org/show_bug.cgi?id=100614
30627
30628         Reviewed by Yong Li.
30629         Internally reviewed by Lyon Chen.
30630
30631         Use a standard Singleton pattern here, this makes sure we create lazily.
30632
30633         * platform/blackberry/AuthenticationChallengeManager.cpp:
30634         (WebCore):
30635         * platform/blackberry/AuthenticationChallengeManager.h:
30636         (AuthenticationChallengeManager):
30637
30638 2012-10-29  Adam Barth  <abarth@webkit.org>
30639
30640         Block SVG external references pending a security review
30641         https://bugs.webkit.org/show_bug.cgi?id=100635
30642
30643         Reviewed by Eric Seidel.
30644
30645         We need to do a security review of loading external SVG references
30646         before we're sure that it is safe.
30647
30648         * css/StyleResolver.cpp:
30649         (WebCore::StyleResolver::createFilterOperations):
30650         * loader/cache/CachedResourceLoader.cpp:
30651         (WebCore::CachedResourceLoader::canRequest):
30652
30653 2012-10-29  Joshua Bell  <jsbell@chromium.org>
30654
30655         IndexedDB: Crash on checking version of corrupt backing store
30656         https://bugs.webkit.org/show_bug.cgi?id=100692
30657
30658         Reviewed by Tony Chang.
30659
30660         If the backing store fails to open (due to corruption, non-writeable disk, etc)
30661         the subsequent schema version check dereferences a null pointer. Fix to only
30662         do the schema check if the database opened.
30663
30664         Chromium tests will be included with crrev.com/11196029
30665
30666         * Modules/indexeddb/IDBLevelDBBackingStore.cpp:
30667         (WebCore::IDBLevelDBBackingStore::open):
30668
30669 2012-10-29  Philip Rogers  <pdr@google.com>
30670
30671         Let SVGElements have pending resources.
30672         https://bugs.webkit.org/show_bug.cgi?id=99694
30673
30674         Reviewed by Eric Seidel.
30675
30676         Our SVG pending resource tracking is used for handling dynamic id changes. For example,
30677         if an SVG element references an id that is not yet in the document (or has been removed),
30678         the SVG element will be 'pending' an id. When styled elements are inserted into
30679         the document, buildPendingResourcesIfNeeded() is called to force any pending elements
30680         to resolve their dependencies. Only SVGStyledElement targets can be referenced using
30681         this infrastructure, and that is not changed with this patch.
30682
30683         Previously, only SVGStyledElements could have pending resources. Some examples of where
30684         this is violated are SVGAnimateElement and SVGMPathElement which are not a styled elements
30685         but which can have pending references (they can reference styled elements and
30686         paths, respectively). This patch changes the pending resource handling to allow
30687         any SVGElement to have pending resources.
30688
30689         This patch is only a refactoring of code in preparation for WK99694 and does not
30690         affect existing functionality or tests.
30691
30692         * svg/SVGDocumentExtensions.cpp:
30693         (WebCore::SVGDocumentExtensions::addPendingResource):
30694         (WebCore::SVGDocumentExtensions::isElementPendingResources):
30695         (WebCore::SVGDocumentExtensions::isElementPendingResource):
30696         (WebCore::SVGDocumentExtensions::removeElementFromPendingResources):
30697         (WebCore::SVGDocumentExtensions::removeElementFromPendingResourcesForRemoval):
30698         * svg/SVGDocumentExtensions.h:
30699         (WebCore):
30700         (SVGDocumentExtensions):
30701         * svg/SVGElement.cpp:
30702         (WebCore::SVGElement::~SVGElement):
30703         (WebCore::SVGElement::removedFrom):
30704         (WebCore::SVGElement::hasPendingResources):
30705         (WebCore):
30706         (WebCore::SVGElement::setHasPendingResources):
30707         (WebCore::SVGElement::clearHasPendingResourcesIfPossible):
30708         * svg/SVGElement.h:
30709         (SVGElement):
30710         (WebCore::SVGElement::buildPendingResource):
30711         * svg/SVGStyledElement.cpp:
30712         (WebCore):
30713         (WebCore::SVGStyledElement::buildPendingResourcesIfNeeded):
30714         (WebCore::SVGStyledElement::removedFrom):
30715         * svg/SVGStyledElement.h:
30716         (SVGStyledElement):
30717         (WebCore::SVGStyledElement::selfHasRelativeLengths):
30718
30719 2012-10-29  Dan Carney  <dcarney@google.com>
30720
30721         Remove ensureAuxiliaryContext
30722         https://bugs.webkit.org/show_bug.cgi?id=99975
30723
30724         Reviewed by Adam Barth.
30725
30726         Removed auxilliaryContext as use if it is problematic in IDB.
30727
30728         No new tests. No change in functionality.
30729
30730         * Modules/indexeddb/IDBCursor.cpp:
30731         (WebCore::IDBCursor::update):
30732         (WebCore::IDBCursor::setValueReady):
30733         * Modules/indexeddb/IDBCursor.h:
30734         (IDBCursor):
30735         * Modules/indexeddb/IDBObjectStore.cpp:
30736         (WebCore::generateIndexKeysForValue):
30737         (WebCore::IDBObjectStore::put):
30738         (WebCore):
30739         * Modules/indexeddb/IDBRequest.cpp:
30740         (WebCore::IDBRequest::onSuccess):
30741         (WebCore::IDBRequest::dispatchEvent):
30742         * bindings/v8/IDBBindingUtilities.cpp:
30743         (WebCore::createIDBKeyFromScriptValueAndKeyPath):
30744         (WebCore::deserializeIDBValue):
30745         (WebCore::injectIDBKeyIntoScriptValue):
30746         * bindings/v8/IDBBindingUtilities.h:
30747         (WebCore):
30748         * bindings/v8/V8Binding.cpp:
30749         (WebCore::toV8Context):
30750         (WebCore):
30751         * bindings/v8/V8Binding.h:
30752         (WebCore):
30753         * bindings/v8/V8PerIsolateData.cpp:
30754         (WebCore):
30755         * bindings/v8/V8PerIsolateData.h:
30756
30757 2012-10-29  Alpha Lam  <hclam@chromium.org>
30758
30759         [skia] Handle mask box image.
30760         https://bugs.webkit.org/show_bug.cgi?id=100570
30761
30762         Reviewed by James Robinson.
30763
30764         When drawing an image with source rectangle it should intersect with image rectangle.
30765         This should be the case for drawing single image and tiling an image.
30766
30767         Test: fast/images/mask-box-image-crash.html
30768
30769         * platform/graphics/skia/ImageSkia.cpp:
30770         (WebCore::Image::drawPattern):
30771         (WebCore::BitmapImage::draw):
30772         (WebCore::BitmapImageSingleFrameSkia::draw):
30773
30774 2012-10-29  Eric Carlson  <eric.carlson@apple.com>
30775
30776         Support captions when PLUGIN_PROXY_FOR_VIDEO
30777         https://bugs.webkit.org/show_bug.cgi?id=100690
30778
30779         Reviewed by Simon Fraser.
30780
30781         When built with PLUGIN_PROXY_FOR_VIDEO, WebCore uses a plug-in for the media element's
30782         platform media engine. Update this code path so the shadow DOM elements used to display
30783         text tracks are created and configured correctly.
30784
30785         * html/HTMLMediaElement.cpp:
30786         (WebCore::HTMLMediaElement::configureMediaControls): Create media controls if necessary.
30787
30788         * rendering/RenderEmbeddedObject.cpp:
30789         (WebCore::RenderEmbeddedObject::layout): Set the position and size of the shadow DOM when the
30790             position of the embedded element changes.
30791         * rendering/RenderEmbeddedObject.h:
30792
30793 2012-10-29  Justin Novosad  <junov@google.com>
30794
30795         [Chromium] flickering observed when copying 2D canvas to webGL texture
30796         https://bugs.webkit.org/show_bug.cgi?id=100691
30797
30798         Reviewed by Stephen White.
30799
30800         Added a flush to the webgl context after texture upload from an image
30801         buffer to ensure proper graphics context synchronization with respect
30802         to subsequent changes to the source image.
30803
30804         Tests: fast/canvas/webgl/canvas-2d-webgl-texture.html
30805
30806         * platform/graphics/skia/ImageBufferSkia.cpp:
30807         (WebCore::ImageBuffer::copyToPlatformTexture):
30808
30809 2012-10-29  Glenn Adams  <glenn@skynav.com>
30810
30811         [CSSOM] Extraneous whitespace in CSSImportRule.cssText
30812         https://bugs.webkit.org/show_bug.cgi?id=100657
30813
30814         Reviewed by Simon Fraser.
30815
30816         Remove extraneous whitespace when serializing CSSImportRule.cssText when
30817         media list is empty.
30818
30819         Test: cssom/cssimportrule-media.html
30820
30821         * css/CSSImportRule.cpp:
30822         (WebCore::CSSImportRule::cssText):
30823         Don't append extra whitespace if mediaText is empty.
30824
30825 2012-10-29  Arnaud Renevier  <a.renevier@sisa.samsung.com>
30826
30827         webview not redrawn as needed when accelerated compositing is enabled.
30828         https://bugs.webkit.org/show_bug.cgi?id=99109
30829
30830         Reviewed by Martin Robinson.
30831
30832         GL shared display is not in the gtk loop and therefore, its events are
30833         not captured by gtk. So, we use gdk default instead.
30834
30835         No new tests, covered by existing tests.
30836
30837         * platform/gtk/RedirectedXCompositeWindow.cpp:
30838         (WebCore::RedirectedXCompositeWindow::RedirectedXCompositeWindow):
30839         (WebCore::RedirectedXCompositeWindow::~RedirectedXCompositeWindow):
30840         (WebCore::RedirectedXCompositeWindow::resize):
30841
30842 2012-10-29  Pavel Feldman  <pfeldman@chromium.org>
30843
30844         Web Inspector: bind redo to Ctrl+Y on non-mac platforms
30845         https://bugs.webkit.org/show_bug.cgi?id=100685
30846
30847         Reviewed by Vsevolod Vlasov.
30848
30849         * inspector/front-end/DefaultTextEditor.js:
30850         (WebInspector.DefaultTextEditor.prototype._registerShortcuts):
30851
30852 2012-10-29  Enrica Casucci  <enrica@apple.com>
30853
30854         Add ENABLE_USERSELECT_ALL feature flag.
30855         https://bugs.webkit.org/show_bug.cgi?id=100559
30856
30857         Reviewed by Eric Seidel.
30858
30859         * Configurations/FeatureDefines.xcconfig:
30860
30861 2012-10-29  Alexandru Chiculita  <achicu@adobe.com>
30862
30863         [CSS Shaders] Extract the CustomFilterParameterList to its own file
30864         https://bugs.webkit.org/show_bug.cgi?id=100548
30865
30866         Reviewed by Dean Jackson.
30867
30868         Moved all the CustomFilterParameterList related methods to their own file.
30869         Also made CustomFilterParameterList inherit from Vector instead of typedefing it,
30870         so that we can add a different operator== and a blend method to it.
30871
30872         No new tests, just refactoring existing code.
30873
30874         * CMakeLists.txt:
30875         * GNUmakefile.list.am:
30876         * Target.pri:
30877         * WebCore.gypi:
30878         * WebCore.xcodeproj/project.pbxproj:
30879         * css/StyleResolver.h:
30880         * platform/graphics/filters/CustomFilterOperation.cpp:
30881         (WebCore::CustomFilterOperation::CustomFilterOperation):
30882         (WebCore::CustomFilterOperation::blend):
30883         * platform/graphics/filters/CustomFilterOperation.h:
30884         (WebCore):
30885         (WebCore::CustomFilterOperation::operator==):
30886         * platform/graphics/filters/CustomFilterParameterList.cpp: Added.
30887         (WebCore):
30888         (WebCore::CustomFilterParameterList::operator==):
30889         (WebCore::CustomFilterParameterList::checkAlphabeticalOrder):
30890         (WebCore::CustomFilterParameterList::blend):
30891         * platform/graphics/filters/CustomFilterParameterList.h: Added.
30892         (WebCore):
30893         (CustomFilterParameterList):
30894
30895 2012-10-29  Brady Eidson  <beidson@apple.com>
30896
30897         Try to fix 32-bit builds after my incompletely tested m_identifier change.
30898
30899         Not reviewed.
30900
30901         * loader/ResourceLoader.h:
30902         (WebCore::ResourceLoader::identifier): Revert my "unsigned long" -> "uint64_t" change in two places.
30903
30904 2012-10-29  Csaba Osztrogonác  <ossy@webkit.org>
30905
30906         [Qt] Text with zero font size renders as X px sometimes, causing fast/text/zero-font-size-2.html to fail
30907         https://bugs.webkit.org/show_bug.cgi?id=100115
30908
30909         Reviewed by Noam Rosenthal.
30910
30911         * platform/graphics/qt/FontQt.cpp:
30912         (WebCore::Font::drawGlyphs):
30913
30914 2012-10-29  Huang Dongsung  <luxtella@company100.net>
30915
30916         [TexMap] Make GraphicsLayerAnimation choose a proper timing function.
30917         https://bugs.webkit.org/show_bug.cgi?id=100623
30918
30919         Reviewed by Noam Rosenthal.
30920
30921         Currently, GraphicsLayerAnimation chooses a timing function in the wrong
30922         way. Other GraphicsLayers choose a timing function in the similar way to
30923         GraphicsLayerCA::timingFunctionForAnimationValue(). The way consists of
30924         the following steps.
30925         1. Try to query the timing function of the current keyframe animation value.
30926         2. If the timing function of #1 is null, try to query the timing function of Animation.
30927         3. If the timing function of #2 is null, return CubicBezierTimingFunction::defaultTimingFunction().
30928
30929         This patch makes GraphicsLayerAnimation choose a timing function in the same way
30930         to other implementations.
30931
30932         Covered by existing animations tests.
30933
30934         * platform/graphics/GraphicsLayerAnimation.cpp:
30935         (WebCore::timingFunctionForAnimationValue):
30936         (WebCore::GraphicsLayerAnimation::apply):
30937
30938 2012-10-29  Patrick Dubroy  <dubroy@chromium.org>
30939
30940         Web Inspector: Toolbar overflow appears outside window
30941         https://bugs.webkit.org/show_bug.cgi?id=100663
30942
30943         Reviewed by Pavel Feldman.
30944
30945         Since the search bar was removed from the toolbar, the overflow menu appears too far
30946         to the right, and is unreadable. Fixed this by aligning it relative to the right side
30947         of the window, rather than the left.
30948
30949         * inspector/front-end/Toolbar.js:
30950         (WebInspector.ToolbarDropdown.prototype.show):
30951         * inspector/front-end/inspector.css:
30952         (#toolbar-dropdown .toolbar-label):
30953
30954 2012-10-29  Michelangelo De Simone  <michelangelo@webkit.org>
30955
30956         [CSS Shaders] Implement CustomFilterArrayParameter::blend
30957         https://bugs.webkit.org/show_bug.cgi?id=96437
30958
30959         Reviewed by Dean Jackson.
30960
30961         This patch adds the missing code to blend values within
30962         an array() when using Custom Filters.
30963
30964         Test: css3/filters/custom/custom-filter-array-blending.html
30965
30966         * platform/graphics/filters/CustomFilterArrayParameter.h:
30967         (WebCore::CustomFilterArrayParameter::blend):
30968
30969 2012-10-29  Alexander Pavlov  <apavlov@chromium.org>
30970
30971         Web Inspector: Drag and drop a URL in inspector is not working as expected
30972         https://bugs.webkit.org/show_bug.cgi?id=100527
30973
30974         Reviewed by Yury Semikhatsky.
30975
30976         Inhibit custom dragstart handling when the active element is A.
30977
30978         * inspector/front-end/ElementsTreeOutline.js:
30979         (WebInspector.ElementsTreeOutline.prototype._ondragstart):
30980
30981 2012-10-29  Mike West  <mkwst@chromium.org>
30982
30983         Web Inspector: Error/warning count is one pixel off.
30984         https://bugs.webkit.org/show_bug.cgi?id=100660
30985
30986         Reviewed by Pavel Feldman.
30987
30988         The error/warning count div had a top padding of 6. That was one pixel
30989         too many.
30990
30991         * inspector/front-end/inspector.css:
30992         (#error-warning-count):
30993
30994 2012-10-29  Shinya Kawanaka  <shinyak@chromium.org> 
30995
30996         [Refactoring] Use isActiveInsertionPoint() instead of isInsertionPoint()
30997         https://bugs.webkit.org/show_bug.cgi?id=100459
30998
30999         Reviewed by Hajime Morita.
31000
31001         Checking InsertionPoint and its activeness with two if-statement is error-prone. We would like to
31002         use a utility function which checks both at once.
31003
31004         We rewrite some lines with such function.
31005
31006         No new tests, simple refactoring.
31007
31008         * dom/ComposedShadowTreeWalker.cpp:
31009         (WebCore::ComposedShadowTreeWalker::traverseNode):
31010         * html/shadow/ContentDistributor.cpp:
31011         (WebCore::ContentDistributor::populate):
31012         (WebCore::ContentDistributor::distribute):
31013         (WebCore::ContentDistributor::distributeNodeChildrenTo):
31014         * html/shadow/InsertionPoint.h:
31015         (WebCore::isInsertionPoint): Since our convention is the argument of this kind of function should not be null,
31016         we would like to make it similar to the other functions.
31017         (WebCore::toInsertionPoint):
31018         (WebCore::isLowerEncapsulationBoundary):
31019
31020 2012-10-29  Patrick Dubroy  <dubroy@chromium.org>
31021
31022         Web Inspector: Fix vertical alignment in toolbar backgrounds and overflow button.
31023         https://bugs.webkit.org/show_bug.cgi?id=100373
31024
31025         Reviewed by Pavel Feldman.
31026
31027         Fix the background image for the selected toolbar item to be vertically centered.
31028         Make close button and toolbar overflow button vertically centered for any toolbar
31029         height.
31030
31031         * inspector/front-end/Toolbar.js: Remove unused variable.
31032         * inspector/front-end/inspector.css:
31033         (.toolbar-item.toggleable):
31034         (body.compact .toolbar-item.toggleable):
31035         (.toolbar-item.toggleable.toggled-on):
31036         (body.compact .toolbar-label):
31037         (#toolbar-dropdown-arrow):
31038         (#close-button-left, #close-button-right):
31039         (.toolbar-item.close-left):
31040         * inspector/front-end/inspector.html:
31041
31042 2012-10-29  Eugene Klyuchnikov  <eustas.bug@gmail.com>
31043
31044         Web Inspector: Timeline: Overview bars do not correspond to timeline bars
31045         https://bugs.webkit.org/show_bug.cgi?id=100500
31046
31047         Reviewed by Yury Semikhatsky.
31048
31049         Fix: do not shorten bars by nested records of the same category.
31050
31051         * inspector/front-end/TimelineOverviewPane.js: Check added.
31052
31053 2012-10-29  Eugene Klyuchnikov  <eustas.bug@gmail.com>
31054
31055         Web Inspector: Timeline: make cpu-monitoring feature available only on capable browsers
31056         https://bugs.webkit.org/show_bug.cgi?id=100530
31057
31058         Reviewed by Yury Semikhatsky.
31059
31060         Motivation: cpu-monitoring feature looks like a glitch,
31061         when it is not supported by browser.
31062
31063         * inspector/Inspector.json: Added capability getter to protocol.
31064         * inspector/InspectorClient.h: Added capability getter.
31065         * inspector/InspectorTimelineAgent.cpp: Proxy to request to client.
31066         * inspector/InspectorTimelineAgent.h: Added capability getter.
31067         * inspector/front-end/Settings.js: Added capability field.
31068         * inspector/front-end/TimelinePanel.js: Check capability.
31069         * inspector/front-end/inspector.js: Forward capability value.
31070
31071 2012-10-29  Antti Koivisto  <antti@apple.com>
31072
31073         Move seamless stylesheet collecting to DocumentStyleSheetCollection
31074         https://bugs.webkit.org/show_bug.cgi?id=100655
31075
31076         Reviewed by Andreas Kling.
31077
31078         Move the code from StyleResolver to DocumentStyleSheetCollection. StyleResolver should focus on resolving style.
31079
31080         * css/StyleResolver.cpp:
31081         (WebCore::StyleResolver::StyleResolver):
31082         
31083             Use standard create() pattern.
31084
31085         (WebCore):
31086         * css/StyleResolver.h:
31087         (StyleResolver):
31088         * dom/Document.cpp:
31089         (WebCore::Document::Document):
31090         * dom/DocumentStyleSheetCollection.cpp:
31091         (WebCore::collectActiveCSSStyleSheetsFromSeamlessParents):
31092         
31093             Since parent activeAuthorStyleSheets() contains all seamlessly inherited sheets too, this does not need to
31094             iterate to ancestors anymore.
31095
31096         (WebCore):
31097         (WebCore::DocumentStyleSheetCollection::updateActiveStyleSheets):
31098         * dom/DocumentStyleSheetCollection.h:
31099         (WebCore::DocumentStyleSheetCollection::create):
31100         (DocumentStyleSheetCollection):
31101         (WebCore::DocumentStyleSheetCollection::styleSheetsForStyleSheetList):
31102         (WebCore::DocumentStyleSheetCollection::activeAuthorStyleSheets):
31103         
31104             activeAuthorStyleSheets() now includes the stylesheets inherited from the seamless parent too.
31105
31106         (WebCore::DocumentStyleSheetCollection::needsUpdateActiveStylesheetsOnStyleRecalc):
31107
31108 2012-10-29  Andreas Kling  <kling@webkit.org>
31109
31110         Don't expose implementation details of StylePropertySet storage.
31111         <http://webkit.org/b/100644>
31112
31113         Reviewed by Antti Koivisto.
31114
31115         Add a StylePropertySet::PropertyReference class, now returned by propertyAt(index).
31116         This will allow us to refactor the internal storage of StylePropertySet without
31117         breaking its API.
31118
31119         A PropertyReference is a simple inlinable wrapper around a StylePropertySet&/index pair.
31120
31121         * css/CSSComputedStyleDeclaration.cpp:
31122         * css/CSSParser.cpp:
31123         * css/CSSParser.h:
31124         * css/SVGCSSParser.cpp:
31125         * css/StylePropertySet.cpp:
31126         (WebCore::StylePropertySet::asText):
31127         (WebCore::StylePropertySet::mergeAndOverrideOnConflict):
31128         (WebCore::StylePropertySet::findPropertyWithId):
31129         (WebCore::StylePropertySet::reportMemoryUsage):
31130         * css/StylePropertySet.h:
31131         (StylePropertySet):
31132         (PropertyReference):
31133         (WebCore::StylePropertySet::PropertyReference::PropertyReference):
31134         (WebCore::StylePropertySet::PropertyReference::id):
31135         (WebCore::StylePropertySet::PropertyReference::isImportant):
31136         (WebCore::StylePropertySet::PropertyReference::isInherited):
31137         (WebCore::StylePropertySet::PropertyReference::cssName):
31138         (WebCore::StylePropertySet::PropertyReference::cssText):
31139         (WebCore::StylePropertySet::PropertyReference::value):
31140         (WebCore::StylePropertySet::PropertyReference::propertyInternal):
31141         (WebCore::StylePropertySet::propertyAt):
31142         (WebCore::StylePropertySet::propertyAtInternal):
31143         (WebCore):
31144         * css/StyleResolver.cpp:
31145         (WebCore::attributeStylesEqual):
31146         (WebCore::StyleResolver::applyProperties):
31147         (WebCore::StyleResolver::resolveVariables):
31148         * editing/ApplyStyleCommand.cpp:
31149         * editing/EditingStyle.cpp:
31150         (WebCore::EditingStyle::mergeStyle):
31151         (WebCore::EditingStyle::mergeStyleFromRulesForSerialization):
31152         * editing/Editor.cpp:
31153         * editing/markup.cpp:
31154         * page/Frame.cpp:
31155         * svg/SVGFontFaceElement.cpp:
31156
31157 2012-10-29  Kent Tamura  <tkent@chromium.org>
31158
31159         Move LocaleWin.{cpp,h} to platform/text/win/
31160         https://bugs.webkit.org/show_bug.cgi?id=100641
31161
31162         Reviewed by Kentaro Hara.
31163
31164         We have platform/text/win/ directory. Windows-specific files should be
31165         in it.
31166         Note that these files are used only in Chromium-win for now.
31167
31168         No new tests. This doesn't change any behavior.
31169
31170         * WebCore.gyp/WebCore.gyp: Fix path names.
31171         * WebCore.gypi: Ditto.
31172         * platform/text/win/LocaleWin.cpp: Renamed from Source/WebCore/platform/text/LocaleWin.cpp.
31173         * platform/text/win/LocaleWin.h: Renamed from Source/WebCore/platform/text/LocaleWin.h.
31174
31175 2012-10-29  Kent Tamura  <tkent@chromium.org>
31176
31177         Rename Localizer to Locale
31178         https://bugs.webkit.org/show_bug.cgi?id=100634
31179
31180         Reviewed by Kentaro Hara.
31181
31182         - Rename Localizer class to Locale
31183         - Rename localizer with locale in variable names
31184         - Rename localizer with locale in function names
31185
31186         No new tests. This doesn't make any behavior changes.
31187
31188         * dom/Document.h:
31189         (WebCore): Declare Locale instead of Localizer.
31190         (Document):
31191         - Rename getCachedLocalizer to getCachedLocale.
31192         - Rename LocaleToLocalizerMap to LocaleIdentifierToLocaleMap.
31193         - Rename m_localizerCache to m_localeCache.
31194         * dom/Document.cpp:
31195         (WebCore::Document::getCachedLocale): Follow renamings.
31196         * dom/Element.h:
31197         (WebCore): Declare Locale instead of Localizer.
31198         (Element): Rename localizer() to locale().
31199         * dom/Element.cpp:
31200         (WebCore::Element::locale): Follow renamings.
31201
31202         * html/BaseDateAndTimeInputType.cpp:
31203         (WebCore::BaseDateAndTimeInputType::localizeValue): Ditto.
31204         (WebCore::BaseDateAndTimeInputType::convertFromVisibleValue): Ditto.
31205         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
31206         (WebCore::BaseMultipleFieldsDateAndTimeInputType::updateInnerTextValue): Ditto.
31207         * html/DateInputType.cpp:
31208         (WebCore::DateInputType::fixedPlaceholder): Ditto.
31209         (WebCore::DateInputType::setupLayoutParameters): Ditto.
31210         * html/DateTimeInputType.cpp:
31211         (WebCore::DateTimeInputType::setupLayoutParameters): Ditto.
31212         * html/DateTimeLocalInputType.cpp:
31213         (WebCore::DateTimeLocalInputType::setupLayoutParameters): Ditto.
31214         * html/MonthInputType.cpp:
31215         (WebCore::MonthInputType::setupLayoutParameters): Ditto.
31216         * html/NumberInputType.cpp:
31217         (WebCore::NumberInputType::localizeValue): Ditto.
31218         (WebCore::NumberInputType::convertFromVisibleValue): Ditto.
31219         * html/TimeInputType.cpp:
31220         (WebCore::TimeInputType::localizeValue): Ditto.
31221         (WebCore::TimeInputType::setupLayoutParameters): Ditto.
31222
31223         * html/shadow/DateTimeEditElement.h:
31224         (WebCore): Declare Locale instead of Localizer.
31225         (LayoutParameters): Rename localizer data member to locale.
31226         (WebCore::DateTimeEditElement::LayoutParameters::LayoutParameters): Follow renamings.
31227         * html/shadow/DateTimeEditElement.cpp:
31228         (WebCore::DateTimeEditBuilder::visitField): Ditto.
31229         * html/shadow/DateTimeNumericFieldElement.h:
31230         (DateTimeNumericFieldElement): Rename localizerForOwner to localeForOwner.
31231         * html/shadow/DateTimeNumericFieldElement.cpp:
31232         (WebCore::DateTimeNumericFieldElement::formatValue): Follow renamings.
31233         (WebCore::DateTimeNumericFieldElement::handleKeyboardEvent): Ditto.
31234         (WebCore::DateTimeNumericFieldElement::localeForOwner): Ditto.
31235         * page/PagePopupClient.h:
31236         (WebCore): Declare Locale instead of Localizer.
31237         (PagePopupClient): Rename localizer member function to locale.
31238         * page/PagePopupController.cpp:
31239         (WebCore::PagePopupController::localizeNumberString): Follow renamings.
31240
31241         * platform/text/PlatformLocale.cpp: Rename the Localizer class to Locale.
31242         (DateTimeStringBuilder):
31243         (WebCore::DateTimeStringBuilder::DateTimeStringBuilder):
31244         (WebCore::Locale::~Locale):
31245         (WebCore::Locale::setLocaleData): Renamed from setLocalizerData.
31246         (WebCore::Locale::convertToLocalizedNumber):
31247         (WebCore::Locale::detectSignAndGetDigitRange):
31248         (WebCore::Locale::matchedDecimalSymbolIndex):
31249         (WebCore::Locale::convertFromLocalizedNumber):
31250         (WebCore::Locale::localizedDecimalSeparator):
31251         (WebCore::Locale::dateTimeFormatWithSeconds):
31252         (WebCore::Locale::dateTimeFormatWithoutSeconds):
31253         (WebCore::Locale::formatDateTime):
31254         * platform/text/PlatformLocale.h: Update the ifndef macro.
31255         (Locale): Renamed from Localizer. Also, renamed the followings:
31256          - initializeLocalizerData -> initializeLocaleData
31257          - setLocalizerData -> setLocaleData
31258          - m_hasLocalizerData -> m_hasLocaleData
31259         (WebCore::Locale::Locale):
31260         (WebCore::Locale::createDefault):
31261         * platform/text/LocaleICU.cpp: Follow renamings.
31262         * platform/text/LocaleICU.h: Ditto.
31263         * platform/text/LocaleNone.cpp: Ditto.
31264         * platform/text/LocaleWin.cpp: Ditto.
31265         * platform/text/LocaleWin.h: Ditto.
31266         * platform/text/mac/LocaleMac.h: Ditto.
31267         * platform/text/mac/LocaleMac.mm: Ditto.
31268
31269 2012-10-29  Mike West  <mkwst@chromium.org>
31270
31271         Web Inspector: Error messages lines in console are 1px taller than regular messages
31272         https://bugs.webkit.org/show_bug.cgi?id=100521
31273
31274         Reviewed by Pavel Feldman.
31275
31276         The inspector is adding a 1px bottom border to list elements inside
31277         a disclosure list. This is unnecessary in the current layout; it's
31278         causing console messages with stack traces to be one pixel taller than
31279         other console messages, which this patch fixes.
31280
31281         As a drive-by, this patch also adjusts the disclosure triangle's
31282         position to match.
31283
31284         * inspector/front-end/inspector.css:
31285         (.outline-disclosure li):
31286         (.outline-disclosure li.parent::before):
31287
31288 2012-10-29  Mike West  <mkwst@chromium.org>
31289
31290         Web Inspector: The bubble for repeated errors is misplaced.
31291         https://bugs.webkit.org/show_bug.cgi?id=100525
31292
31293         Reviewed by Pavel Feldman.
31294
31295         The repeated-message bubble is displayed as an inline-block element,
31296         which works well as long as no stack trace is present. If present, the
31297         message is wrapped in an 'ol' element displayed as a block, which pushes
31298         itself down to the next line.
31299
31300         To avoid that issue, this patch switches the wrapper element to flexbox,
31301         glorious flexbox.
31302
31303         * inspector/front-end/inspector.css:
31304         (.console-message .bubble):
31305         (.repeated-message .outline-disclosure):
31306         (.filter-all .console-log-level.repeated-message, .filter-logs .console-log-level.repeated-message):
31307
31308 2012-10-29  Alexander Pavlov  <apavlov@chromium.org>
31309
31310         Web Inspector: [Styles] Handle non-parsedOk properties as inactive ones
31311         https://bugs.webkit.org/show_bug.cgi?id=100119
31312
31313         Reviewed by Vsevolod Vlasov.
31314
31315         Test: inspector/styles/inactive-properties.html
31316
31317         * inspector/front-end/StylesSidebarPane.js:
31318         (WebInspector.StylesSidebarPane.createExclamationMark):
31319         (WebInspector.ComputedStylePropertiesSection.prototype.rebuildComputedTrace):
31320         * inspector/front-end/elementsPanel.css:
31321         (.styles-section.computed-style .properties li.not-parsed-ok):
31322         (.styles-section.computed-style .properties li.not-parsed-ok img.exclamation-mark):
31323         (.styles-section .properties .not-parsed-ok):
31324
31325 2012-10-29  Eric Seidel  <eric@webkit.org>
31326
31327         Make rendering tables with <colgroups> twice as fast by avoiding walking the DOM for colgroups 4 times for each cell
31328         https://bugs.webkit.org/show_bug.cgi?id=100630
31329
31330         Reviewed by Ojan Vafai.
31331
31332         This is not a complete fix.  Our rendering of this large tables still takes 7.8 seconds
31333         on my retina MBP (down from 14.3s before this change).
31334         It's very expensive to walk the DOM each time we call RenderTable::colElement
31335         so this caches the RenderTableCol* in a vector for easier walking.
31336         We invalidate the cache any time a RenderTableCol is added or removed from the
31337         rendering sub-tree to avoid holding a bad pointer.
31338
31339         * rendering/RenderTable.cpp:
31340         (WebCore::RenderTable::RenderTable):
31341         (WebCore::RenderTable::invalidateCachedColumns):
31342         (WebCore):
31343         (WebCore::RenderTable::addColumn):
31344         (WebCore::RenderTable::removeColumn):
31345         (WebCore::RenderTable::updateColumnCache):
31346         (WebCore::RenderTable::slowColElement):
31347         * rendering/RenderTable.h:
31348         (RenderTable):
31349         * rendering/RenderTableCol.cpp:
31350         (WebCore::RenderTableCol::insertedIntoTree):
31351         (WebCore):
31352         (WebCore::RenderTableCol::willBeRemovedFromTree):
31353         * rendering/RenderTableCol.h:
31354
31355 2012-10-28  Kent Tamura  <tkent@chromium.org>
31356
31357         Rename Localizer.{cpp,h} to PlatformLocale.{cpp,h}
31358         https://bugs.webkit.org/show_bug.cgi?id=100627
31359
31360         Reviewed by Yuta Kitamura.
31361
31362         We'd like to rename Localizer class to Locale class. However we use
31363         PlatformLocale.cpp and PlatformLocale.h as their file names because
31364         <locale.h> exists in the C standard.  In this patch, we rename only file
31365         names. We're going to rename the class name later.
31366
31367         No new tests. This doesn't make any behavior change.
31368
31369         * platform/text/PlatformLocale.h: Renamed from Source/WebCore/platform/text/Localizer.h.
31370         * platform/text/PlatformLocale.cpp: Renamed from Source/WebCore/platform/text/Localizer.cpp.
31371         Follow the Localizer.h -> PlatformLocale.cpp renaming.
31372
31373         * CMakeLists.txt: Follow the file name renaming.
31374         * GNUmakefile.list.am: Ditto.
31375         * Target.pri: Ditto.
31376         * WebCore.gypi: Ditto.
31377         * WebCore.vcproj/WebCore.vcproj: Ditto.
31378         * WebCore.xcodeproj/project.pbxproj: Ditto.
31379         * dom/Document.cpp: Ditto.
31380         * html/BaseDateAndTimeInputType.cpp: Ditto.
31381         * html/BaseMultipleFieldsDateAndTimeInputType.cpp: Ditto.
31382         * html/DateInputType.cpp: Ditto.
31383         * html/DateTimeInputType.cpp: Ditto.
31384         * html/DateTimeLocalInputType.cpp: Ditto.
31385         * html/MonthInputType.cpp: Ditto.
31386         * html/NumberInputType.cpp: Ditto.
31387         * html/TimeInputType.cpp: Ditto.
31388         * html/shadow/DateTimeEditElement.cpp: Ditto.
31389         * html/shadow/DateTimeNumericFieldElement.cpp: Ditto.
31390         * page/PagePopupController.cpp: Ditto.
31391         * platform/text/LocaleICU.h: Ditto.
31392         * platform/text/LocaleNone.cpp: Ditto.
31393         * platform/text/LocaleWin.h: Ditto.
31394         * platform/text/mac/LocaleMac.h: Ditto.
31395
31396 2012-10-28  Shinya Kawanaka  <shinyak@chromium.org>
31397
31398         The shadow element is not reprojected to a nested ShadowRoot.
31399         https://bugs.webkit.org/show_bug.cgi?id=99228
31400
31401         Reviewed by Dimitri Glazkov.
31402
31403         We support shadow reprojection; elements distributed to <shadow> element can be reprojected to <content> now.
31404
31405         First, we have a distribution vector for each InsertionPoint, even if InsertionPoint is a shadow insertion point.
31406         And we update a node-distribution map. Basically We're creating a map from node to InsertionPoint in ElementShadow.
31407         If a node can be distributed to several InsertionPoint (e.g. in case reprojection happens),
31408         the InsertionPoint in older ShadowDOM is chosen.
31409
31410         We also fix ComposedShadowTreeWalker to consider shadow reprojection.
31411
31412         Tests: fast/dom/shadow/composed-shadow-tree-walker-shadow-reprojection.html
31413                fast/dom/shadow/shadow-reprojection-click.html
31414                fast/dom/shadow/shadow-reprojection-dynamic.html
31415                fast/dom/shadow/shadow-reprojection-fallback.html
31416                fast/dom/shadow/shadow-reprojection.html
31417                fast/dom/shadow/shadow-reprojection2.html
31418
31419         * css/StyleResolver.cpp:
31420         (WebCore::shouldResetStyleInheritance): Now context.insertionPoint() returns the final insertion point where
31421         a node is distributed. So we don't have to trace shadow insertion point anymore here.
31422         (WebCore::StyleResolver::styleForElement): Since a direct child of ShadowRoot can be distributed now. In that case,
31423         we don't have any parentElement. The parent node is a ShadowRoot in that case.
31424         * dom/ComposedShadowTreeWalker.cpp:
31425         (WebCore::nodeCanBeDistributed): If a node can be distributed, returns true.
31426         (WebCore):
31427         (WebCore::resolveReprojection): Resolves content-reprojection and shadow-reprojection both.
31428         (WebCore::ComposedShadowTreeWalker::traverseSiblingOrBackToInsertionPoint):
31429         (WebCore::ComposedShadowTreeWalker::traverseParent):
31430         (WebCore::ComposedShadowTreeWalker::traverseParentBackToYoungerShadowRootOrHost): A case ShadowRoot is assigned
31431         to some InsertionPoint should be handled with in traverseSiblingOrBackToInsertionPoint. So we remove it.
31432         (WebCore::AncestorChainWalker::parent): Now we have a case that a direct child of ShadowRoot can be distributed.
31433         In that case, we should not update m_distributedNode.
31434         * dom/ElementShadow.cpp:
31435         (WebCore::ElementShadow::insertionPointFor): Since we have a distribution vector for each InsertionPoint,
31436         we don't have a special case that a ShadowRoot is assigned to some InsertionPoint. Actually the existing code
31437         is not correct now due to shadow reprojection.
31438         * html/shadow/ContentDistributor.cpp:
31439         (WebCore::ContentDistributor::populate): Populate a POOL. If a node is InsertionPoint, we fill it with the
31440         distributed nodes.
31441         (WebCore):
31442         (WebCore::ContentDistributor::distribute): Since we want to make a distribution vector for each InsertionPoint,
31443         we have to resolve a shadow InsertionPoint
31444         (WebCore::ContentDistributor::distributeNodeChildrenTo):
31445         * html/shadow/ContentDistributor.h:
31446         (ContentDistributor):
31447         * html/shadow/HTMLShadowElement.h:
31448         (WebCore::toHTMLShadowElement):
31449         (WebCore):
31450         * html/shadow/InsertionPoint.h:
31451         (WebCore::parentNodeForDistribution):
31452         (WebCore::parentElementForDistribution):
31453         (WebCore):
31454
31455 2012-10-28  Kunihiko Sakamoto  <ksakamoto@chromium.org>
31456
31457         Webkit adds a boundary to the Content-Type: text/plain POST header
31458         https://bugs.webkit.org/show_bug.cgi?id=100445
31459
31460         Reviewed by Kent Tamura.
31461
31462         Fixed a bug where an empty boundary parameter was added to Content-Type
31463         header when POSTing forms with enctype=text/plain.
31464
31465         Test: http/tests/misc/form-post-textplain.html
31466
31467         * loader/FormSubmission.cpp:
31468         (WebCore::FormSubmission::populateFrameLoadRequest): Add boundary parameter to
31469         Content-Type only when a boundary string is generated.
31470
31471 2012-10-28  Philip Rogers  <pdr@google.com>
31472
31473         Cache calcMode() value for SVG animations.
31474         https://bugs.webkit.org/show_bug.cgi?id=99694
31475
31476         Reviewed by Eric Seidel.
31477
31478         This patch refactors SVGAnimationElement::calcMode() to return a cached value instead
31479         of recalculating its value on every call. On a simple test of 100 rectangles with 100
31480         animations each, calls to calcMode() account for 3% of the total animation. After this
31481         patch, calcMode() no longer appears in animation profiles at all.
31482
31483         No new tests as this functionality is covered by existing tests.
31484
31485         * svg/SVGAnimateMotionElement.cpp:
31486         (WebCore::SVGAnimateMotionElement::SVGAnimateMotionElement):
31487
31488             The default calcMode for all animation types is linear except AnimateMotion,
31489             which defaults to CalcModePaced.
31490             See: http://www.w3.org/TR/SVG/single-page.html#animate-CalcModeAttribute
31491
31492         * svg/SVGAnimationElement.cpp:
31493         (WebCore::SVGAnimationElement::SVGAnimationElement):
31494         (WebCore::SVGAnimationElement::isSupportedAttribute):
31495         (WebCore::SVGAnimationElement::parseAttribute):
31496         (WebCore::SVGAnimationElement::setCalcMode):
31497         * svg/SVGAnimationElement.h:
31498         (WebCore::SVGAnimationElement::calcMode):
31499         (WebCore::SVGAnimationElement::setCalcMode):
31500         (SVGAnimationElement):
31501
31502 2012-10-28  Dimitri Glazkov  <dglazkov@chromium.org>
31503
31504         Get rid of StyleResolver state related to unknown pseudo-elements.
31505         https://bugs.webkit.org/show_bug.cgi?id=100582
31506
31507         Reviewed by Eric Seidel.
31508
31509         All of the state, related to unknown pseudo-elements is already understood at the time of collecting rules.
31510         We can just get rid of most of this code in StyleResolver.
31511
31512         At the time of matching rules, we know for certain that only rules that contain unknown pseudo-elements,
31513         or are UA rules, or are explicitly invited by a TreeScope will match. So we can just return early in many cases.
31514
31515         No change in behavior, covered by existing tests.
31516
31517         * css/SelectorChecker.cpp:
31518         (WebCore::SelectorChecker::checkSelector): Removed now-unnecessary param.
31519         (WebCore::SelectorChecker::checkOneSelector): Ditto.
31520         * css/SelectorChecker.h:
31521         (SelectorChecker): Ditto.
31522         * css/StyleResolver.cpp:
31523         (WebCore::StyleResolver::StyleResolver): Ditto.
31524         (MatchingUARulesScope): Moved class definition here, since we now use it in a different place.
31525         (WebCore::StyleResolver::collectMatchingRules): Changed the logic to stop matching rules that definitely won't match in a different scope.
31526         (WebCore::StyleResolver::collectMatchingRulesForList): Removed code that's now unnecesssary.
31527         (WebCore::StyleResolver::checkSelector): Removed now-unnecessary param.
31528         (WebCore::StyleResolver::checkRegionSelector): Removed weird dead code.
31529         * css/StyleResolver.h:
31530         (StyleResolver): Removed now-unnecessary member.
31531
31532 2012-10-28  Sheriff Bot  <webkit.review.bot@gmail.com>
31533
31534         Unreviewed, rolling out r132696.
31535         http://trac.webkit.org/changeset/132696
31536         https://bugs.webkit.org/show_bug.cgi?id=100609
31537
31538         Needs a bit more clean-up on Chrome Web UI side. (Requested by
31539         dglazkov on #webkit).
31540
31541         * rendering/RenderBlock.cpp:
31542         (WebCore::RenderBlock::updateFirstLetter):
31543         * rendering/RenderListBox.h:
31544         * rendering/RenderObjectChildList.cpp:
31545         (WebCore::RenderObjectChildList::updateBeforeAfterContent):
31546
31547 2012-10-27  Alexey Proskuryakov  <ap@apple.com>
31548
31549         All tests crash in WebKit1 mode
31550         https://bugs.webkit.org/show_bug.cgi?id=100602
31551
31552         Reviewed by Sam Weinig.
31553
31554         * platform/PlatformStrategies.cpp: (WebCore::setPlatformStrategies): Fix an incorrect
31555         assertion - if this function is called twice, it should be with the same strategy.
31556
31557 2012-10-27  Anders Carlsson  <andersca@apple.com>
31558
31559         Fix AVFoundation build.
31560
31561         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
31562         (WebCore::MediaPlayerPrivateAVFoundationObjC::addKey):
31563
31564 2012-10-27  David Barton  <dbarton@mathscribe.com>
31565
31566         ASSERTION FAILED: m_next in LayoutState.cpp
31567         https://bugs.webkit.org/show_bug.cgi?id=99796
31568
31569         Reviewed by Eric Seidel.
31570
31571         Before RenderMathMLBlock::computeChildrenPreferredLogicalHeights calls child->layoutIfNeeded(),
31572         it must ensure a layoutState exists. We disable it in any case, since we are just calculating
31573         metrics here, and the final layout may well happen again.
31574
31575         No new tests. I don't know how to create an automated test for this. The crashes users are
31576         seeing are flaky.
31577
31578         * rendering/mathml/RenderMathMLBlock.cpp:
31579         (WebCore::RenderMathMLBlock::computeChildrenPreferredLogicalHeights):
31580
31581 2012-10-27  David Barton  <dbarton@mathscribe.com>
31582
31583         [MathML] Improve some addChild methods
31584         https://bugs.webkit.org/show_bug.cgi?id=98791
31585
31586         Reviewed by Eric Seidel.
31587
31588         MathML addChild methods need to handle any anonymous renderers correctly. Actually, most MathML elements have a fixed
31589         number of children, so conformant javascript won't be doing arbitrary addChild and removeChild calls. However, we don't
31590         want any assertions to fail, and we do want addChild to work correctly when beforeChild == 0, to build up the original
31591         renderer, and then replaceChild at least should work correctly after that. We therefore clean up these routines before
31592         giving them to the chromium fuzzers.
31593         
31594         It's best to build the anonymous wrappers just once initially if possible, so empty wrappers aren't left in the render
31595         tree after later removeChild calls.
31596
31597         Test: mathml/presentation/dynamic.html added for mfrac and msqrt. There are already tests for dynamically changing
31598         msub/sup elements, in mathml/presentation/m*-changed.xhtml.
31599
31600         * rendering/mathml/RenderMathMLFraction.cpp:
31601         (WebCore::RenderMathMLFraction::addChild):
31602             - The two wrappers are built initially. Also, the old RenderMathMLBlock::addChild(row, beforeChild); doesn't really
31603               work because beforeChild is buried inside a wrapper. This new routine allows the numerator and denominator to be
31604               added initially, and then later replaced with replaceChild. It's not clear whether e.g. a plain removeChild of a
31605               numerator should move the remaining child from the denominator to the numerator or not, so we ignore that for now.
31606         * rendering/mathml/RenderMathMLRoot.cpp:
31607         (WebCore::RenderMathMLRoot::addChild):
31608             - A bit of bullet-proofing for the fuzzers.
31609         * rendering/mathml/RenderMathMLSubSup.cpp:
31610         (WebCore::RenderMathMLSubSup::addChild):
31611             - Like RenderMathMLFraction::addChild, we create the wrappers once initially, and then fill them dynamically.
31612
31613 2012-10-27  Levi Weintraub  <leviw@chromium.org>
31614
31615         Background images can incorrectly repeat with sub-pixel layout
31616         https://bugs.webkit.org/show_bug.cgi?id=94622
31617
31618         Reviewed by Emil A Eklund.
31619
31620         Attempting to better match author expectations when painting tiled background images. When under
31621         the effects of zoom with sub-pixel layout enabled, the drawn size of a rendered element can
31622         differ depending on its location. This change looks at the size of the scaled tiled background
31623         image size, and either ceils or floors that value depending on if tiling that value will
31624         result in us being one pixel or less short of covering the background size. This is a heuristic,
31625         as sub-pixel/zooming isn't specced.
31626
31627         Test: fast/sub-pixel/scaled-background-image.html
31628
31629         * rendering/RenderBoxModelObject.cpp:
31630         (WebCore::applySubPixelHeuristicForTileSize):
31631         (WebCore):
31632         (WebCore::RenderBoxModelObject::calculateFillTileSize):
31633
31634 2012-10-27  Sheriff Bot  <webkit.review.bot@gmail.com>
31635
31636         Unreviewed, rolling out r132725.
31637         http://trac.webkit.org/changeset/132725
31638         https://bugs.webkit.org/show_bug.cgi?id=100596
31639
31640         it broke linking on chromium debug bots (Requested by loislo
31641         on #webkit).
31642
31643         * inspector/InspectorMemoryAgent.cpp:
31644         (WebCore::addPlatformComponentsInfo):
31645         (WebCore):
31646         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
31647         * platform/MemoryUsageSupport.cpp:
31648         (WebCore::MemoryUsageSupport::memoryUsageByComponents):
31649         * platform/MemoryUsageSupport.h:
31650         (ComponentInfo):
31651         (WebCore::MemoryUsageSupport::ComponentInfo::ComponentInfo):
31652         (MemoryUsageSupport):
31653         * platform/PlatformMemoryInstrumentation.cpp:
31654         (WebCore):
31655         * platform/PlatformMemoryInstrumentation.h:
31656         (PlatformMemoryTypes):
31657         * platform/chromium/MemoryUsageSupportChromium.cpp:
31658         (WebCore::MemoryUsageSupport::memoryUsageByComponents):
31659         * platform/qt/MemoryUsageSupportQt.cpp:
31660         (WebCore::MemoryUsageSupport::memoryUsageByComponents):
31661
31662 2012-10-27  Dan Bernstein  <mitz@apple.com>
31663
31664         REAL_PLATFORM_NAME build setting is no longer needed
31665         https://bugs.webkit.org/show_bug.cgi?id=100587
31666
31667         Reviewed by Mark Rowe.
31668
31669         Removed the definition of REAL_PLATFORM_NAME and replaced references to it with references
31670         to PLATFORM_NAME.
31671
31672         * Configurations/Base.xcconfig:
31673         * Configurations/CompilerVersion.xcconfig:
31674         * Configurations/DebugRelease.xcconfig:
31675         * Configurations/FeatureDefines.xcconfig:
31676         * Configurations/Version.xcconfig:
31677         * Configurations/WebCore.xcconfig:
31678
31679 2012-10-27  Tony Chang  <tony@chromium.org>
31680
31681         Remove internals shouldDisplayTrackKind methods; these are also on internals.settings
31682         https://bugs.webkit.org/show_bug.cgi?id=100564
31683
31684         Reviewed by Adam Barth.
31685
31686         Remove duplicate methods from internals that was just forwarding on the call to internals.settings.
31687         Also fix a bug where we didn't reset these settings properly.
31688
31689         No new tests, this is covered by existing media/track tests.
31690
31691         * testing/InternalSettings.cpp:
31692         (WebCore::InternalSettings::Backup::Backup): Properly save display track settings.
31693         (WebCore::InternalSettings::Backup::restoreTo): Restore display track settings.
31694         * testing/InternalSettings.h:
31695         * testing/InternalSettings.idl: Use [Conditional=VIDEO_TRACK].
31696         * testing/Internals.cpp: Remove code.
31697         * testing/Internals.h: Remove code.
31698         * testing/Internals.idl: Remove code.
31699
31700 2012-10-26  Ilya Tikhonovsky  <loislo@chromium.org>
31701
31702         Web Inspector: instrument chromium GlyphCache. It keeps ~2mb.
31703         https://bugs.webkit.org/show_bug.cgi?id=100515
31704
31705         Reviewed by Yury Semikhatsky.
31706
31707         I replaced old version with an abstract number with new one which precisely reports allocated SkGlyphCache objects and their sizes.
31708
31709         * inspector/InspectorMemoryAgent.cpp:
31710         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
31711         * platform/MemoryUsageSupport.cpp:
31712         (WebCore::MemoryUsageSupport::reportMemoryUsage):
31713         * platform/MemoryUsageSupport.h:
31714         (MemoryUsageSupport):
31715         * platform/PlatformMemoryInstrumentation.cpp:
31716         (WebCore):
31717         * platform/PlatformMemoryInstrumentation.h:
31718         (PlatformMemoryTypes):
31719         * platform/chromium/MemoryUsageSupportChromium.cpp:
31720         (reportMemoryUsage):
31721         (WebCore::reportGlyphCache):
31722         (WebCore):
31723         (WebCore::MemoryUsageSupport::reportMemoryUsage):
31724         * platform/qt/MemoryUsageSupportQt.cpp:
31725         (WebCore::MemoryUsageSupport::reportMemoryUsage):
31726
31727 2012-10-26  Philip Rogers  <pdr@google.com>
31728
31729         Prevent NaN offset values in ElementTimeControl.
31730         https://bugs.webkit.org/show_bug.cgi?id=100322
31731
31732         Reviewed by Abhishek Arya.
31733
31734         NaN values can cause ElementTimeControl to go back in time!
31735         If a value of NaN is passed to ElementTimeControl::beginElementAt(offset),
31736         subsequent sorting will cause an assert in SVGSMILElement::findInstanceTime
31737         because NaN values are not properly sorted. NaN SMILTime values
31738         should not be allowed at all, so this patch adds a check for them in
31739         ElementTimeControl's setters.
31740  
31741         This patch also adds preventative asserts to catch if SMILTime is ever
31742         initialized with NaN, or if addEndTime/addBeginTime are ever called
31743         with NaN values.
31744
31745         Test: svg/custom/elementTimeControl-nan-crash.html
31746
31747         * svg/SVGAnimationElement.cpp:
31748         (WebCore::SVGAnimationElement::beginElementAt):
31749         (WebCore::SVGAnimationElement::endElementAt):
31750         * svg/animation/SMILTime.h:
31751         (WebCore::SMILTime::SMILTime):
31752         * svg/animation/SVGSMILElement.cpp:
31753         (WebCore::SVGSMILElement::addBeginTime):
31754         (WebCore::SVGSMILElement::addEndTime):
31755
31756 2012-10-26  Charles Wei  <charles.wei@torchmobile.com.cn>
31757
31758         [BlackBerry] Browser prematurely sends wrong credentials
31759         https://bugs.webkit.org/show_bug.cgi?id=100585
31760
31761         Reviewed by Yong Li.
31762
31763         Manually revert the patch for bug 96362, which causes regressions and the right patch has been
31764         submitted with patch for bug 100448. Since the auto-revert fails, we use this patch to manually
31765         revert.
31766
31767         No new tests. The test is coverted by patch for 100448.
31768
31769         * platform/network/blackberry/CredentialBackingStore.cpp:
31770         * platform/network/blackberry/CredentialBackingStore.h:
31771         (CredentialBackingStore):
31772         * platform/network/blackberry/NetworkManager.cpp:
31773         (WebCore::NetworkManager::startJob):
31774
31775 2012-10-26  Brady Eidson  <beidson@apple.com>
31776
31777         Have NetworkProcess manage resource load scheduling.
31778         https://bugs.webkit.org/show_bug.cgi?id=100479
31779
31780         Reviewed by Alexey Proskuryakov.
31781
31782         Down in WebCore we need to virtualize a handful of ResourceLoadScheduler methods
31783         to be overridden by WebKit's implementation.
31784
31785         No new tests (No change in Core behavior).
31786
31787         * WebCore.exp.in:
31788         * WebCore.xcodeproj/project.pbxproj:
31789
31790         * loader/ResourceLoadScheduler.cpp:
31791         (WebCore::resourceLoadScheduler): Gracefully handle LoaderStrategies wanting to return the default scheduler.
31792         (WebCore::ResourceLoadScheduler::scheduleLoad): Call notifyDidScheduleResourceRequest.
31793         (WebCore::ResourceLoadScheduler::notifyDidScheduleResourceRequest): Moved InspectorInstrumentation call
31794           here so derived classes can do it indirectly.
31795         (WebCore::ResourceLoadScheduler::startResourceLoader): To allow derived classes the ability to call
31796           ResourceLoader::start() which only ResourceLoadScheduler can do.
31797
31798         * loader/ResourceLoadScheduler.h:
31799         (ResourceLoadScheduler): Virtualize some core public methods so they can be overridden.
31800         (WebCore::ResourceLoadScheduler::setSerialLoadingEnabled): Make virtual.
31801         (WebCore::ResourceLoadScheduler::isSuspendingPendingRequests): Make private as it's internal only.
31802
31803         * loader/ResourceLoader.cpp:
31804         (WebCore::ResourceLoader::setIdentifier): Add this setter so outside clients can manually change the identifier.
31805
31806         * loader/ResourceLoader.h:
31807         (WebCore::ResourceLoader::identifier): Change identifier to explicitly be uint64_t.
31808         (WebCore::ResourceLoader::request): Make public.
31809         (ResourceLoader):
31810
31811 2012-10-26  Chris Rogers  <crogers@google.com>
31812
31813         Implement AudioBufferSourceNode .loopStart and .loopEnd attributes
31814         https://bugs.webkit.org/show_bug.cgi?id=100170
31815
31816         Reviewed by Kenneth Russell.
31817
31818         AudioBufferSourceNode currently only supports looping of an entire AudioBuffer.
31819         Sample-based synthesis is a very common technique which requires "internal" loop-points.
31820         For example, the first part of the sample data might represent the attack portion of
31821         a synthesized instrument, which then enters a loop portion.
31822
31823         Tests: webaudio/audiobuffersource-loop-comprehensive.html
31824                webaudio/audiobuffersource-loop-points.html
31825
31826         * Modules/webaudio/AudioBufferSourceNode.cpp:
31827         (WebCore::AudioBufferSourceNode::AudioBufferSourceNode):
31828         (WebCore::AudioBufferSourceNode::process):
31829         (WebCore::AudioBufferSourceNode::renderFromBuffer):
31830         * Modules/webaudio/AudioBufferSourceNode.h:
31831         (AudioBufferSourceNode):
31832         (WebCore::AudioBufferSourceNode::loopStart):
31833         (WebCore::AudioBufferSourceNode::loopEnd):
31834         (WebCore::AudioBufferSourceNode::setLoopStart):
31835         (WebCore::AudioBufferSourceNode::setLoopEnd):
31836         * Modules/webaudio/AudioBufferSourceNode.idl:
31837
31838 2012-10-26  Daniel Cheng  <dcheng@chromium.org>
31839
31840         dragover's default action should prevent drop for file drags
31841         https://bugs.webkit.org/show_bug.cgi?id=79173
31842
31843         Reviewed by Tony Chang.
31844
31845         During a file drag, we need to keep track of whether or not the document has cancelled the
31846         dragover action. We should only send a drop event if the dragover event was cancelled; this
31847         matches the behavior of the spec, as well as IE, Gecko, and Opera. The relevant sections
31848         from the spec are the sections pertaining to dragover and drop events at:
31849         http://www.whatwg.org/specs/web-apps/current-work/#drag-and-drop-processing-model
31850
31851         Test: fast/events/only-valid-drop-targets-receive-file-drop.html
31852
31853         * page/DragController.cpp:
31854         (WebCore::DragController::performDrag):
31855         (WebCore::DragController::dragEnteredOrUpdated):
31856         (WebCore::DragController::tryDocumentDrag):
31857         * page/DragController.h:
31858         (DragController): Cleanup to repurpose a variable that doesn't need to be a member anymore
31859                           and remove the corresponding getter/setter.
31860
31861 2012-10-26  Nico Weber  <thakis@chromium.org>
31862
31863         Fix a operator ordering bug in SVGSMILElement::calculateAnimationPercentAndRepeat
31864         https://bugs.webkit.org/show_bug.cgi?id=94756
31865
31866         Reviewed by Dirk Schulze.
31867
31868         The function has an early exit for !simpleDuration.value(), so
31869         !simpleDuration.value() always is 0 when passed as second parameter to
31870         fmod(), which means fmod() always returns NaN, which always evaluates
31871         to true. Simplify the code by removing that explicit check.
31872
31873         No observable behavior change.
31874
31875         Covered by existing svg tests.
31876
31877         * svg/animation/SVGSMILElement.cpp:
31878         (WebCore::SVGSMILElement::calculateAnimationPercentAndRepeat):
31879
31880 2012-10-26  Sheriff Bot  <webkit.review.bot@gmail.com>
31881
31882         Unreviewed, rolling out r132695.
31883         http://trac.webkit.org/changeset/132695
31884         https://bugs.webkit.org/show_bug.cgi?id=100581
31885
31886         caused 20+ test crashes on bots (Requested by estes on
31887         #webkit).
31888
31889         * dom/ContainerNode.cpp:
31890         (WebCore::ContainerNode::suspendPostAttachCallbacks):
31891         (WebCore::ContainerNode::resumePostAttachCallbacks):
31892         * loader/MainResourceLoader.cpp:
31893         (WebCore::MainResourceLoader::loadNow):
31894         * loader/ResourceLoadScheduler.cpp:
31895         (WebCore::resourceLoadScheduler):
31896         * loader/ResourceLoadScheduler.h:
31897         * loader/ResourceLoader.cpp:
31898         (WebCore::ResourceLoader::releaseResources):
31899         (WebCore::ResourceLoader::willSendRequest):
31900         * loader/cache/CachedResource.cpp:
31901         (WebCore::CachedResource::load):
31902         * loader/cache/CachedResourceLoader.cpp:
31903         (WebCore::CachedResourceLoader::performPostLoadActions):
31904
31905 2012-10-26  Vincent Scheib  <scheib@chromium.org>
31906
31907         Unreviewed, rolling out r132702.
31908         http://trac.webkit.org/changeset/132702
31909         https://bugs.webkit.org/show_bug.cgi?id=100322
31910
31911         Compile error on Chromium Linux dbg builder (and others)
31912
31913         * svg/SVGAnimationElement.cpp:
31914         (WebCore::SVGAnimationElement::beginElementAt):
31915         (WebCore::SVGAnimationElement::endElementAt):
31916         * svg/animation/SMILTime.h:
31917         (WebCore::SMILTime::SMILTime):
31918         * svg/animation/SVGSMILElement.cpp:
31919         (WebCore::SVGSMILElement::addBeginTime):
31920         (WebCore::SVGSMILElement::addEndTime):
31921
31922 2012-10-26  Philip Rogers  <pdr@google.com>
31923
31924         Prevent NaN offset values in ElementTimeControl.
31925         https://bugs.webkit.org/show_bug.cgi?id=100322
31926
31927         Reviewed by Abhishek Arya.
31928
31929         NaN values can cause ElementTimeControl to go back in time!
31930         If a value of NaN is passed to ElementTimeControl::beginElementAt(offset),
31931         subsequent sorting will cause an assert in SVGSMILElement::findInstanceTime
31932         because NaN values are not properly sorted. NaN SMILTime values
31933         should not be allowed at all, so this patch adds a check for them in
31934         ElementTimeControl's setters.
31935
31936         This patch also adds preventative asserts to catch if SMILTime is ever
31937         initialized with NaN, or if addEndTime/addBeginTime are ever called
31938         with NaN values.
31939
31940         Test: svg/custom/elementTimeControl-nan-crash.html
31941
31942         * svg/SVGAnimationElement.cpp:
31943         (WebCore::SVGAnimationElement::beginElementAt):
31944         (WebCore::SVGAnimationElement::endElementAt):
31945         * svg/animation/SMILTime.h:
31946         (WebCore::SMILTime::SMILTime):
31947         * svg/animation/SVGSMILElement.cpp:
31948         (WebCore::SVGSMILElement::addBeginTime):
31949         (WebCore::SVGSMILElement::addEndTime):
31950
31951 2012-10-26  Tony Chang  <tony@chromium.org>
31952
31953         Move non-Settings Inspector methods from internals.settings to internals
31954         https://bugs.webkit.org/show_bug.cgi?id=100392
31955
31956         Reviewed by Adam Barth.
31957
31958         These methods don't have to do with the WebCore Settings object, so move them up to internals.
31959         I moved the reset code from InternalSettings to Internals.
31960
31961         No new tests, this is just a rename. Existing tests should pass.
31962
31963         * testing/InternalSettings.cpp:
31964         (WebCore::InternalSettings::Backup::Backup): Remove inspector methods.
31965         (WebCore::InternalSettings::Backup::restoreTo): Remove inspector methods.
31966         * testing/InternalSettings.h:
31967         * testing/InternalSettings.idl:
31968         * testing/Internals.cpp:
31969         (WebCore::Internals::resetToConsistentState): New method for resetting page state. Named after similar
31970         methods in WTR.
31971         (WebCore::Internals::setInspectorResourcesDataSizeLimits): Moved from InspectorSettings.
31972         (WebCore::Internals::setJavaScriptProfilingEnabled): Moved from InspectorSettings.
31973         * testing/Internals.h:
31974         * testing/Internals.idl:
31975         * testing/js/WebCoreTestSupport.cpp:
31976         (WebCoreTestSupport::resetInternalsObject): Reset state in Internals.
31977         * testing/v8/WebCoreTestSupport.cpp:
31978         (WebCoreTestSupport::resetInternalsObject): Reset state in Internals.
31979
31980 2012-10-26  Dominic Mazzoni  <dmazzoni@google.com>
31981
31982         AX: Notification should be sent when accessibilityIsIgnored changes
31983         https://bugs.webkit.org/show_bug.cgi?id=99547
31984
31985         Reviewed by Chris Fleizach.
31986
31987         Adds a new flag in AccessibilityObject that keeps track of the most recent
31988         value of accessibilityIsIgnored(). After certain events such as an ARIA
31989         attribute change or content change, checks the new value of
31990         accessibilityIsIgnored() and posts a "children changed" notification on the
31991         parent node if it changed, making sure the parent recomputes its vector of
31992         (unignored) children.
31993
31994         Also moves handling of attribute changes to AXObjectCache, and sends
31995         notifications for some attribute changes that were previously silent. On
31996         Chromium, all changes to an accessibility object's attributes should
31997         result in some notification.
31998
31999         Some tests would have broken because an AccessibilityScrollView was created
32000         and holding a reference to a ScrollView for an iframe after it was deleted,
32001         so this change switches AccessibilityScrollView to hold a weak reference
32002         to ScrollView instead.
32003
32004         Tests: platform/chromium/accessibility/is-ignored-change-sends-notification.html
32005                platform/chromium/accessibility/other-aria-attribute-change-sends-notification.html
32006                platform/chromium/accessibility/text-change-notification.html
32007
32008         * accessibility/AXObjectCache.cpp:
32009         (WebCore::AXObjectCache::focusedUIElementForPage):
32010         (WebCore::AXObjectCache::getOrCreate):
32011         (WebCore::AXObjectCache::textChanged):
32012         (WebCore):
32013         (WebCore::AXObjectCache::childrenChanged):
32014         (WebCore::AXObjectCache::handleAriaRoleChanged):
32015         (WebCore::AXObjectCache::handleAttributeChanged):
32016         (WebCore::AXObjectCache::labelChanged):
32017         (WebCore::AXObjectCache::recomputeIsIgnored):
32018         * accessibility/AXObjectCache.h:
32019         (AXObjectCache):
32020         (WebCore::AXObjectCache::childrenChanged):
32021         (WebCore::AXObjectCache::textChanged):
32022         (WebCore::AXObjectCache::handleAttributeChanged):
32023         (WebCore::AXObjectCache::recomputeIsIgnored):
32024         * accessibility/AccessibilityNodeObject.cpp:
32025         (WebCore::AccessibilityNodeObject::insertChild):
32026         * accessibility/AccessibilityObject.cpp:
32027         (WebCore::AccessibilityObject::AccessibilityObject):
32028         (WebCore::AccessibilityObject::cachedIsIgnoredValue):
32029         (WebCore):
32030         (WebCore::AccessibilityObject::setCachedIsIgnoredValue):
32031         (WebCore::AccessibilityObject::notifyIfIgnoredValueChanged):
32032         * accessibility/AccessibilityObject.h:
32033         (WebCore::AccessibilityObject::textChanged):
32034         (AccessibilityObject):
32035         * accessibility/AccessibilityRenderObject.cpp:
32036         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
32037         (WebCore::AccessibilityRenderObject::correspondingControlForLabelElement):
32038         (WebCore::AccessibilityRenderObject::textChanged):
32039         (WebCore::AccessibilityRenderObject::addHiddenChildren):
32040         (WebCore::AccessibilityRenderObject::addChildren):
32041         * accessibility/AccessibilityRenderObject.h:
32042         (AccessibilityRenderObject):
32043         * accessibility/AccessibilityScrollView.cpp:
32044         (WebCore::AccessibilityScrollView::~AccessibilityScrollView):
32045         (WebCore):
32046         (WebCore::AccessibilityScrollView::detach):
32047         (WebCore::AccessibilityScrollView::isAttachment):
32048         (WebCore::AccessibilityScrollView::widgetForAttachmentView):
32049         (WebCore::AccessibilityScrollView::updateScrollbars):
32050         (WebCore::AccessibilityScrollView::webAreaObject):
32051         (WebCore::AccessibilityScrollView::elementRect):
32052         (WebCore::AccessibilityScrollView::documentFrameView):
32053         (WebCore::AccessibilityScrollView::parentObject):
32054         (WebCore::AccessibilityScrollView::parentObjectIfExists):
32055         (WebCore::AccessibilityScrollView::getScrollableAreaIfScrollable):
32056         (WebCore::AccessibilityScrollView::scrollTo):
32057         * accessibility/AccessibilityScrollView.h:
32058         (WebCore::AccessibilityScrollView::scrollView):
32059         (AccessibilityScrollView):
32060         * accessibility/AccessibilityTable.cpp:
32061         (WebCore::AccessibilityTable::isDataTable):
32062         * accessibility/chromium/AXObjectCacheChromium.cpp:
32063         (WebCore::AXObjectCache::postPlatformNotification):
32064         * dom/Element.cpp:
32065         (WebCore::Element::attributeChanged):
32066         * rendering/RenderBlock.cpp:
32067         (WebCore::RenderBlock::deleteLineBoxTree):
32068         (WebCore::RenderBlock::createAndAppendRootInlineBox):
32069         * rendering/RenderObject.cpp:
32070         (WebCore::RenderObject::styleWillChange):
32071         * rendering/RenderText.cpp:
32072         (WebCore::RenderText::setText):
32073
32074 2012-10-26  Joshua Bell  <jsbell@chromium.org>
32075
32076         [WebKitIDL] Optional dictionary types should have default values of empty dictionary
32077         https://bugs.webkit.org/show_bug.cgi?id=100547
32078
32079         Reviewed by Adam Barth.
32080
32081         Per WebIDL, "Optional dictionary type arguments are always considered to have a default
32082         value of an empty dictionary." WebKitIDL already supported this via the extended attribute
32083         [Optional=DefaultIsUndefined] but make this the default for Dictionary.
32084
32085         Binding test expectations updated.
32086
32087         * Modules/filesystem/DirectoryEntry.h: Remove default parameters.
32088         (DirectoryEntry):
32089         * Modules/indexeddb/IDBDatabase.h: Remove overloads.
32090         (IDBDatabase):
32091         * Modules/indexeddb/IDBObjectStore.h: Remove overloads.
32092         (IDBObjectStore):
32093         * Modules/mediastream/RTCPeerConnection.idl: Remove DefaultIsUndefined annotations.
32094         * bindings/scripts/CodeGeneratorJS.pm: Special case for Optional Dictionary.
32095         (GenerateParametersCheck):
32096         * bindings/scripts/CodeGeneratorV8.pm: Ditto.
32097         (GenerateParametersCheck):
32098         * bindings/scripts/test/JS/JSTestObj.cpp:
32099         (WebCore::jsTestObjPrototypeFunctionOptionsObject): Updated expectation - no early call.
32100         * bindings/scripts/test/V8/V8TestObj.cpp:
32101         (WebCore::TestObjV8Internal::optionsObjectCallback): Ditto.
32102
32103 2012-10-26  Vincent Scheib  <scheib@chromium.org>
32104
32105         Generated should not be supported for things with a shadow
32106         https://bugs.webkit.org/show_bug.cgi?id=98836
32107
32108         Unreviewed rollout of rollout of http://trac.webkit.org/changeset/132269.
32109         Initial rollout was speculative and was shown not to be related to crashes.
32110         Change author: Elliott Sprehn  <esprehn@chromium.org>
32111
32112         As far as CSS is concerned inputs and things with shadow content inside 
32113         shouldn't support pseudo elements like :before, :after or :first-letter.
32114         Neither Gecko or Presto supports it, and we only accidentally supported 
32115         it. 
32116  
32117         Until the spec tells us what to do we should disable support. This is 
32118         also neccesary because the new generated content implementation doesn't 
32119         support shadows. 
32120
32121         Test: fast/forms/pseudo-elements.html
32122
32123         * rendering/RenderBlock.cpp:
32124         (WebCore::RenderBlock::updateFirstLetter):
32125         * rendering/RenderListBox.h:
32126         * rendering/RenderObjectChildList.cpp:
32127         (WebCore::RenderObjectChildList::updateBeforeAfterContent):
32128
32129 2012-10-26  Brady Eidson  <beidson@apple.com>
32130
32131         Crash in WebProces at WebCore::ResourceLoadScheduler::crossOriginRedirectReceived + 78
32132         <rdar://problem/12575514> and https://bugs.webkit.org/show_bug.cgi?id=100554
32133
32134         Reviewed by Alexey Proskuryakov.
32135
32136         This was fallout from http://trac.webkit.org/changeset/132501 where I missed some of the 
32137         spots that call resourceLoadScheduler().
32138
32139         As a result we were creating more than one ResourceLoadScheduler, allowing the host records 
32140         to get out of sync.
32141
32142         The fix that also results in less #ifdefs scattered throughout the code is to use a single 
32143         choke point for all ResourceLoadScheduler access.
32144
32145         No new tests 
32146         (No change of behavior for the default config, not testable at this time in the repro config)
32147
32148         Add a single choke point for accessing the correct ResourceLoadScheduler:
32149         * loader/ResourceLoadScheduler.cpp:
32150         (WebCore::defaultResourceLoadScheduler): New private function that keeps the singleton default ResourceLoadScheduler.
32151         (WebCore::resourceLoadScheduler): Refactor this function to either ask the LoaderStrategy or call through to
32152
32153         Revert back to using that single choke point everywhere:
32154         * dom/ContainerNode.cpp:
32155         (WebCore::ContainerNode::suspendPostAttachCallbacks):
32156         (WebCore::ContainerNode::resumePostAttachCallbacks):
32157
32158         * loader/MainResourceLoader.cpp:
32159         (WebCore::MainResourceLoader::loadNow):
32160
32161         * loader/ResourceLoader.cpp:
32162         (WebCore::ResourceLoader::releaseResources):
32163         (WebCore::ResourceLoader::willSendRequest):
32164
32165         * loader/cache/CachedResource.cpp:
32166         (WebCore::CachedResource::load):
32167
32168         * loader/cache/CachedResourceLoader.cpp:
32169         (WebCore::CachedResourceLoader::performPostLoadActions):
32170
32171 2012-10-26  Elliott Sprehn  <esprehn@chromium.org>
32172
32173         Try to fix the windows build
32174         https://bugs.webkit.org/show_bug.cgi?id=100556
32175
32176         Reviewed by Eric Seidel.
32177
32178         Touch files by adding whitespace to try and make the windows
32179         build bot regenerate files.
32180
32181         No new tests, just kick the bot.
32182
32183         * dom/DOMAllInOne.cpp:
32184         * html/HTMLElementsAllInOne.cpp:
32185         * html/shadow/TextControlInnerElements.cpp:
32186
32187 2012-10-26  Rob Buis  <rbuis@rim.com>
32188
32189         [BlackBerry] Platform Abstraction for WebKit Resource/Image Loading
32190         https://bugs.webkit.org/show_bug.cgi?id=100518
32191
32192         PR 231732
32193
32194         Reviewed by Yong Li.
32195
32196         Use the new resource/image loading abstraction ResourceStore.
32197
32198         * platform/graphics/blackberry/ImageBlackBerry.cpp:
32199         (WebCore::Image::loadPlatformResource):
32200
32201 2012-10-26  Bear Travis  <betravis@adobe.com>
32202
32203         [CSS Exclusions] Block children have incorrect offset when shape-inside element lays out below other elements
32204         https://bugs.webkit.org/show_bug.cgi?id=98189
32205
32206         Reviewed by Dirk Schulze.
32207
32208         The initial code assumed that each block created a new layout state, such that
32209         LayoutState::layoutOffset would be specific to each block child of a shape-inside.
32210         Typically, however, block children of a shape-inside do not create a new layout state,
32211         and therefore we use the current element's offset instead.
32212
32213         Test: fast/exclusions/shape-inside/shape-inside-subsequent-blocks.html
32214
32215         * rendering/RenderBlockLineLayout.cpp:
32216         (WebCore::RenderBlock::layoutRunsAndFloatsInRange): Modified to use only logicalTop
32217         rather than LayoutState::layoutOffset::width/height and logicalTop.
32218
32219 2012-10-26  Elliott Sprehn  <esprehn@chromium.org>
32220
32221         Remove setRenderStyle in favor of callbacks on HTMLOptionElement and HTMLOptGroupElement
32222         https://bugs.webkit.org/show_bug.cgi?id=100397
32223
32224         Reviewed by Ojan Vafai.
32225
32226         Use Node custom callbacks to support the non-renderer style caching for option
32227         and optgroup eliminating the need for setRenderStyle.
32228
32229         setRenderStyle only existed to support HTMLOptionElement and HTMLOptGroupElement
32230         so they could store their RenderStyle even though they have no renderer. This
32231         means all style setting went through the virtual call to setRenderStyle, and it
32232         also hid the if statement protecting against null renderers meaning we end up
32233         checking if the renderer is null repeatedly in recalcStyle. This refactor cleans
32234         up recalcStyle to be more clear about what's going on.
32235
32236         No new tests needed, this is just a refactor.
32237
32238         * dom/Element.cpp:
32239         (WebCore::Element::pseudoStyleCacheIsInvalid):
32240         (WebCore::Element::recalcStyle):
32241         * dom/Node.cpp:
32242         (WebCore::Node::createRenderer):
32243         (WebCore::Node::setRenderStyle):
32244             Removed this method because it was only here to support HTMLOptionElement
32245             and HTMLOptGroupElement. Instead we can use node custom callbacks.
32246         * dom/Node.h:
32247         (WebCore::Node::nonRendererStyle): Renamed from nonRendererRenderStyle to match other style methods.
32248         * dom/NodeRenderStyle.h:
32249         (WebCore::Node::renderStyle):
32250         * html/HTMLOptGroupElement.cpp:
32251         (WebCore::HTMLOptGroupElement::HTMLOptGroupElement):
32252         (WebCore::HTMLOptGroupElement::attach): Reorder the logic to avoid calling styleForRenderer twice.
32253         (WebCore::HTMLOptGroupElement::updateNonRenderStyle): Updates the cached non-renderer style.
32254         (WebCore::HTMLOptGroupElement::nonRendererStyle):
32255         (WebCore::HTMLOptGroupElement::customStyleForRenderer):
32256         * html/HTMLOptGroupElement.h:
32257         * html/HTMLOptionElement.cpp:
32258         (WebCore::HTMLOptionElement::HTMLOptionElement):
32259         (WebCore::HTMLOptionElement::attach): Reorder the logic to avoid calling styleForRenderer twice.
32260         (WebCore::HTMLOptionElement::updateNonRenderStyle): Updates the cached non-renderer style.
32261         (WebCore::HTMLOptionElement::nonRendererStyle):
32262         (WebCore::HTMLOptionElement::customStyleForRenderer):
32263         (WebCore::HTMLOptionElement::didRecalcStyle): Requests the repaint of the select like setRenderStyle used to.
32264         * html/HTMLOptionElement.h:
32265
32266 2012-10-26  Dirk Schulze  <krit@webkit.org>
32267
32268         -webkit-clip-path property should just reference clipPath
32269         https://bugs.webkit.org/show_bug.cgi?id=100531
32270
32271         Reviewed by Eric Seidel.
32272
32273         The -webkit-clip-path property should just reference clipPath. Added a check for that.
32274
32275         Test: css3/masking/clip-path-reference-of-fake-clipPath.html
32276
32277         * rendering/RenderLayer.cpp:
32278         (WebCore::RenderLayer::paintLayerContents):
32279
32280 2012-10-26  Aaron Colwell  <acolwell@chromium.org>
32281
32282         Remove the circular reference between TextTrack and TextTrackCue
32283         https://bugs.webkit.org/show_bug.cgi?id=100300
32284
32285         Reviewed by Eric Carlson.
32286
32287         Changed TextTrackCue.m_track to a normal pointer to break the circular
32288         reference that was keeping both objects from ever getting deleted.
32289
32290         No new tests. This simply fixes a memory leak.
32291
32292         * html/track/TextTrack.cpp:
32293         (WebCore::TextTrack::~TextTrack):
32294         * html/track/TextTrackCue.cpp:
32295         (WebCore::TextTrackCue::TextTrackCue):
32296         (WebCore::TextTrackCue::~TextTrackCue):
32297         (WebCore::TextTrackCue::track):
32298         (WebCore::TextTrackCue::setTrack):
32299         * html/track/TextTrackCue.h:
32300         (TextTrackCue):
32301
32302 2012-10-26  Vsevolod Vlasov  <vsevik@chromium.org>
32303
32304         Web Inspector: Breakpoints are not managed correctly when editing uiSourceCode that was bound to ScriptFile after JavaScriptSourceFrame creation.
32305         https://bugs.webkit.org/show_bug.cgi?id=100535
32306
32307         Reviewed by Pavel Feldman.
32308
32309         Added SourceMappingChanged event to UISourceCode and made
32310         JavaScriptSourceFrame update ScriptFile events listeners on it.
32311
32312         * inspector/front-end/JavaScriptSourceFrame.js:
32313         (WebInspector.JavaScriptSourceFrame):
32314         (WebInspector.JavaScriptSourceFrame.prototype._onSourceMappingChanged):
32315         (WebInspector.JavaScriptSourceFrame.prototype._updateScriptFile):
32316         * inspector/front-end/ResourceScriptMapping.js:
32317         (WebInspector.ResourceScriptMapping.prototype._bindUISourceCodeToScripts):
32318         * inspector/front-end/UISourceCode.js:
32319         (WebInspector.UISourceCode.prototype.setSourceMapping):
32320
32321 2012-10-26  Vincent Scheib  <scheib@chromium.org>
32322
32323         Unreviewed, rolling out r132644.
32324         http://trac.webkit.org/changeset/132644
32325         https://bugs.webkit.org/show_bug.cgi?id=100497
32326
32327         Causes webkit_unit_tests
32328         MemoryInstrumentationTest.ImageObserver to fail.
32329
32330         * platform/network/ResourceRequestBase.cpp:
32331         (WebCore::ResourceRequestBase::reportMemoryUsage):
32332         * platform/network/ResourceRequestBase.h:
32333         (ResourceRequestBase):
32334         * platform/network/chromium/ResourceRequest.cpp:
32335         * platform/network/chromium/ResourceRequest.h:
32336
32337 2012-10-26  Zeno Albisser  <zeno@webkit.org>
32338
32339         [Qt] MiniBrowser segfaults on exit after using WebGL.
32340         https://bugs.webkit.org/show_bug.cgi?id=100523
32341
32342         The display connection must not be closed before
32343         destroying the offscreen window.
32344         Therefore opening the connection is moved to the
32345         getXWindow() function. And closing the connection
32346         is being moved to the destructor of the offscreen window.
32347
32348         Reviewed by Kenneth Rohde Christiansen.
32349
32350
32351         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
32352         (WebCore::OffScreenRootWindow::OffScreenRootWindow):
32353         (WebCore::OffScreenRootWindow::getXWindow):
32354         (OffScreenRootWindow):
32355         (WebCore::OffScreenRootWindow::display):
32356         (WebCore::OffScreenRootWindow::~OffScreenRootWindow):
32357         (WebCore):
32358         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
32359         (WebCore::GraphicsSurfacePrivate::~GraphicsSurfacePrivate):
32360         (WebCore::GraphicsSurfacePrivate::createSurface):
32361
32362 2012-10-26  Parth Patel  <parpatel@rim.com>
32363
32364         [BlackBerry] Extending existing ThreadUnsafe singletons in webkit to
32365         Generic ThreadUnsafe Singleton
32366         https://bugs.webkit.org/show_bug.cgi?id=100529
32367
32368         Reviewed by Yong Li.
32369
32370         No new tests added as there was no behavioural change.
32371
32372         * platform/network/blackberry/NetworkManager.cpp:
32373         (WebCore):
32374         * platform/network/blackberry/NetworkManager.h:
32375         (NetworkManager):
32376
32377 2012-10-26  Mike West  <mkwst@chromium.org>
32378
32379         Web Inspector: Fix log-type icon alignment.
32380         https://bugs.webkit.org/show_bug.cgi?id=100520
32381
32382         Reviewed by Yury Semikhatsky.
32383
32384         The icons are just a pixel or two off, and it's driving me nuts.
32385
32386         * inspector/front-end/inspector.css:
32387         (.console-message::before, .console-user-command::before, #console-prompt::before, .console-group-title::before):
32388         (.console-warning-level::before):
32389
32390 2012-10-26  Erik Arvidsson  <arv@chromium.org>
32391
32392         Replaceable attributes should also have readonly
32393         https://bugs.webkit.org/show_bug.cgi?id=91768
32394
32395         Reviewed by Adam Barth.
32396
32397         This updates the code generators for JSC and V8 to handle this case correctly.
32398
32399         * Modules/intents/DOMWindowIntents.idl:
32400         * bindings/scripts/CodeGeneratorJS.pm:
32401         * bindings/scripts/CodeGeneratorV8.pm:
32402         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
32403         * bindings/scripts/test/ObjC/DOMTestObj.h:
32404         * bindings/scripts/test/ObjC/DOMTestObj.mm:
32405         * bindings/scripts/test/TestObj.idl:
32406         * bindings/scripts/test/V8/V8TestObj.cpp:
32407         * page/DOMWindow.idl:
32408         * workers/WorkerContext.idl:
32409
32410 2012-10-26  Nico Weber  <thakis@chromium.org>
32411
32412         Clear m_orientation in FrameData::clear() for skia
32413         https://bugs.webkit.org/show_bug.cgi?id=100456
32414
32415         Reviewed by Stephen White.
32416
32417         clear() is only called by the FrameData destructor and for multi-image
32418         images in BitmapImage::destroyDecodedData(). Multi-frame images don't
32419         have exif data, so this patch should have no effect in practice. It
32420         makes the skia code match the CG code in BitmapImageCG.cpp though.
32421
32422         * platform/graphics/skia/ImageSkia.cpp:
32423         (WebCore::FrameData::clear):
32424
32425 2012-10-26  Florin Malita  <fmalita@chromium.org>
32426
32427         Crash on loading SVG filter resource on HTML element
32428         https://bugs.webkit.org/show_bug.cgi?id=100491
32429
32430         Reviewed by Dirk Schulze.
32431
32432         Skip non-filter elements referenced via -webkit-filter.
32433
32434         Test: svg/filters/filter-reference-crash.html
32435
32436         * rendering/RenderLayerFilterInfo.cpp:
32437         (WebCore::RenderLayerFilterInfo::updateReferenceFilterClients):
32438
32439 2012-10-26  Antti Koivisto  <antti@apple.com>
32440
32441         Lots of time spent under DNSResolveQueue::platformProxyIsEnabledInSystemPreferences
32442         https://bugs.webkit.org/show_bug.cgi?id=100514
32443
32444         Reviewed by Anders Carlsson.
32445
32446         DNSResolveQueue::platformProxyIsEnabledInSystemPreferences gets called for every link in
32447         the document. The function is relatively slow.
32448         
32449         This patch caches the result of the last check for 5 seconds. Based on code comments
32450         prefetching is disabled with proxies due to regressing performance with some configurations.
32451         Proxy status changes rarely and a slight reaction delay shoudn't cause practical problems.
32452
32453         * platform/network/DNSResolveQueue.cpp:
32454         (WebCore::DNSResolveQueue::DNSResolveQueue):
32455         
32456             Add constructor. Also fixes a bug, m_requestsInFlight was not initialized.
32457             
32458         (WebCore):
32459         (WebCore::DNSResolveQueue::isUsingProxy):
32460         (WebCore::DNSResolveQueue::add):
32461         (WebCore::DNSResolveQueue::fired):
32462         * platform/network/DNSResolveQueue.h:
32463         (DNSResolveQueue):
32464
32465 2012-10-26  Sheriff Bot  <webkit.review.bot@gmail.com>
32466
32467         Unreviewed, rolling out r132662.
32468         http://trac.webkit.org/changeset/132662
32469         https://bugs.webkit.org/show_bug.cgi?id=100528
32470
32471         It is not necessary any more. (Requested by loislo on
32472         #webkit).
32473
32474         * platform/qt/MemoryUsageSupportQt.cpp:
32475         (WebCore::MemoryUsageSupport::memoryUsageByComponents):
32476         (WebCore):
32477
32478 2012-10-26  Ilya Tikhonovsky  <loislo@chromium.org>
32479
32480         Unreviewed build fix for Qt builders.
32481
32482         * platform/qt/MemoryUsageSupportQt.cpp:
32483
32484 2012-10-26  Csaba Osztrogonác  <ossy@webkit.org>
32485
32486         Unreviewed, rolling out r132658.
32487         http://trac.webkit.org/changeset/132658
32488         https://bugs.webkit.org/show_bug.cgi?id=100515
32489
32490         It broke the Qt build
32491
32492         * inspector/InspectorMemoryAgent.cpp:
32493         (WebCore::addPlatformComponentsInfo):
32494         (WebCore):
32495         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
32496         * platform/MemoryUsageSupport.cpp:
32497         (WebCore::MemoryUsageSupport::memoryUsageByComponents):
32498         * platform/MemoryUsageSupport.h:
32499         (ComponentInfo):
32500         (WebCore::MemoryUsageSupport::ComponentInfo::ComponentInfo):
32501         (MemoryUsageSupport):
32502         * platform/PlatformMemoryInstrumentation.cpp:
32503         (WebCore):
32504         * platform/PlatformMemoryInstrumentation.h:
32505         (PlatformMemoryTypes):
32506         * platform/chromium/MemoryUsageSupportChromium.cpp:
32507         (WebCore::MemoryUsageSupport::memoryUsageByComponents):
32508
32509 2012-10-26  Vsevolod Vlasov  <vsevik@chromium.org>
32510
32511         Web Inspector: Some context menu items are duplicated on Resources and Sources panels.
32512         https://bugs.webkit.org/show_bug.cgi?id=100522
32513
32514         Reviewed by Pavel Feldman.
32515
32516         Method appendApplicableItems now receives event as a parameter.
32517         HandlerRegistry now makes sure that it is not called more than once for certain context menu event.
32518
32519         * inspector/front-end/BreakpointsSidebarPane.js:
32520         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._emptyElementContextMenu):
32521         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointContextMenu):
32522         (WebInspector.XHRBreakpointsSidebarPane.prototype._emptyElementContextMenu):
32523         (WebInspector.XHRBreakpointsSidebarPane.prototype._contextMenu):
32524         * inspector/front-end/CallStackSidebarPane.js:
32525         (WebInspector.CallStackSidebarPane.Placard.prototype._placardContextMenu):
32526         * inspector/front-end/ConsoleView.js:
32527         * inspector/front-end/ContextMenu.js:
32528         (WebInspector.ContextMenu):
32529         (WebInspector.ContextMenu.prototype.show):
32530         (WebInspector.ContextMenu.prototype.appendApplicableItems):
32531         (WebInspector.ContextMenu.Provider.prototype.appendApplicableItems):
32532         * inspector/front-end/CookieItemsView.js:
32533         (WebInspector.CookieItemsView.prototype._contextMenu):
32534         * inspector/front-end/DOMBreakpointsSidebarPane.js:
32535         (WebInspector.DOMBreakpointsSidebarPane.prototype._contextMenu):
32536         * inspector/front-end/DataGrid.js:
32537         (WebInspector.DataGrid.prototype._contextMenuInDataTable):
32538         * inspector/front-end/DefaultTextEditor.js:
32539         (WebInspector.DefaultTextEditor.prototype._contextMenu):
32540         * inspector/front-end/ElementsPanel.js:
32541         (WebInspector.ElementsPanel.prototype._contextMenuEventFired.set get var):
32542         * inspector/front-end/ElementsPanelDescriptor.js:
32543         (WebInspector.ElementsPanelDescriptor.prototype.appendApplicableItems):
32544         * inspector/front-end/ElementsTreeOutline.js:
32545         (WebInspector.ElementsTreeOutline.prototype._contextMenuEventFired):
32546         * inspector/front-end/HandlerRegistry.js:
32547         (WebInspector.HandlerRegistry.prototype.appendApplicableItems):
32548         * inspector/front-end/ImageView.js:
32549         (WebInspector.ImageView.prototype._contextMenu):
32550         * inspector/front-end/NavigatorView.js:
32551         (WebInspector.NavigatorView.prototype.handleContextMenu):
32552         * inspector/front-end/NetworkPanel.js:
32553         (WebInspector.NetworkLogView.prototype._contextMenu):
32554         * inspector/front-end/NetworkPanelDescriptor.js:
32555         (WebInspector.NetworkPanelDescriptor.prototype.appendApplicableItems):
32556         * inspector/front-end/ObjectPropertiesSection.js:
32557         (WebInspector.ObjectPropertiesSection.prototype._contextMenuEventFired):
32558         (WebInspector.ObjectPropertyTreeElement.prototype._contextMenuFired):
32559         * inspector/front-end/ProfilesPanel.js:
32560         (WebInspector.ProfilesPanel.prototype._handleContextMenuEvent):
32561         (WebInspector.ProfileSidebarTreeElement.prototype.handleContextMenuEvent):
32562         * inspector/front-end/ResourcesPanel.js:
32563         (WebInspector.FrameResourceTreeElement.prototype._handleContextMenuEvent):
32564         (WebInspector.IndexedDBTreeElement.prototype._handleContextMenuEvent):
32565         (WebInspector.FileSystemListTreeElement.prototype._handleContextMenuEvent):
32566         (WebInspector.IDBDatabaseTreeElement.prototype._handleContextMenuEvent):
32567         * inspector/front-end/ScriptsNavigator.js:
32568         (WebInspector.SnippetsNavigatorView.prototype.handleContextMenu):
32569         * inspector/front-end/ScriptsPanel.js:
32570         (WebInspector.ScriptsPanel.prototype.appendApplicableItems):
32571         * inspector/front-end/ScriptsPanelDescriptor.js:
32572         (WebInspector.ScriptsPanelDescriptor.prototype.appendApplicableItems):
32573         * inspector/front-end/StylesSidebarPane.js:
32574         (WebInspector.StylesSidebarPane.prototype._contextMenuEventFired):
32575         * inspector/front-end/TabbedPane.js:
32576         (WebInspector.TabbedPaneTab.prototype._tabContextMenu):
32577         * inspector/front-end/TimelinePanel.js:
32578         (WebInspector.TimelinePanel.prototype._contextMenu):
32579         * inspector/front-end/WatchExpressionsSidebarPane.js:
32580         (WebInspector.WatchExpressionsSection.prototype._emptyElementContextMenu):
32581         (WebInspector.WatchExpressionTreeElement.prototype._contextMenu):
32582
32583 2012-10-26  Ilya Tikhonovsky  <loislo@chromium.org>
32584
32585         Web Inspector: instrument chromium GlyphCache. It keeps ~2mb data on gmail.
32586         https://bugs.webkit.org/show_bug.cgi?id=100515
32587
32588         Reviewed by Yury Semikhatsky.
32589
32590         I replaced old version with an abstract number with new one which precisely reports allocated SkGlyphCache objects and their sizes.
32591
32592         * inspector/InspectorMemoryAgent.cpp:
32593         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
32594         * platform/MemoryUsageSupport.cpp:
32595         (WebCore::MemoryUsageSupport::reportMemoryUsage):
32596         * platform/MemoryUsageSupport.h:
32597         (MemoryUsageSupport):
32598         * platform/PlatformMemoryInstrumentation.cpp:
32599         (WebCore):
32600         * platform/PlatformMemoryInstrumentation.h:
32601         (PlatformMemoryTypes):
32602         * platform/chromium/MemoryUsageSupportChromium.cpp:
32603         (reportMemoryUsage):
32604         (WebCore::reportGlyphCache):
32605         (WebCore):
32606         (WebCore::MemoryUsageSupport::reportMemoryUsage):
32607
32608 2012-10-26  Kent Tamura  <tkent@chromium.org>
32609
32610         [Chromium] Build fix for r132650.
32611         https://bugs.webkit.org/show_bug.cgi?id=100482
32612
32613         * platform/text/LocaleWin.cpp:
32614         (WebCore::LocaleWin::timeFormat):
32615
32616 2012-10-26  Yury Semikhatsky  <yurys@chromium.org>
32617
32618         [v8] Memory instrumentation: don't count memory of WrapperTypeInfo
32619         https://bugs.webkit.org/show_bug.cgi?id=100517
32620
32621         Reviewed by Alexander Pavlov.
32622
32623         * bindings/v8/V8PerIsolateData.cpp: when estimating bindings memory size skip
32624         pointers to WrapperTypeInfo objects as they are static fields and belong to
32625         the data segment.
32626         (WTF):
32627
32628 2012-10-26  Kent Tamura  <tkent@chromium.org>
32629
32630         Refactor Localizer-related classes.
32631         https://bugs.webkit.org/show_bug.cgi?id=100482
32632
32633         Reviewed by Kentaro Hara.
32634
32635         - Localizer has unused code
32636          Localizer should have function implementations only if they are used in
32637          multiple subclasses.
32638         - Some Localizer subclasses hide Localizer data members
32639         - Should use String::isNull to check initialization-or-not
32640
32641         No new tests. This should not change any behavior.
32642
32643         * platform/text/Localizer.h:
32644         (Localizer):
32645         - timeFormat, shortTimeFormat, and timeAMPMLabels should be pure virtual.
32646         - Remove m_localizedDateFormatText, m_localizedShortTimeFormatText, and
32647           m_timeAMPMLabels
32648         * platform/text/Localizer.cpp:
32649         Remove implementations of timeFormat, shortTimeFormat, and timeAMPMLabels.
32650
32651         * platform/text/LocaleICU.h:
32652         (LocaleICU): Introduce m_timeFormatWithSeconds and m_timeFormatWithoutSeconds.
32653         * platform/text/LocaleICU.cpp:
32654         (WebCore::LocaleICU::initializeDateTimeFormat):
32655         Use new data members instead of Localizer data members.
32656         (WebCore::LocaleICU::dateFormat): Use isNull.
32657
32658         * platform/text/LocaleNone.cpp:
32659         (LocaleNone): Add timeFormat, shortTimeFormat, timeAMPMLabels
32660         implementations, and m_timeAMPMLabels.
32661         (WebCore::LocaleNone::timeFormat): Returns the HTML time format.
32662         (WebCore::LocaleNone::shortTimeFormat): Returns the HTML time format.
32663         (WebCore::LocaleNone::timeAMPMLabels): Returns "AM" and "PM".
32664
32665         * platform/text/LocaleWin.h:
32666         (LocaleWin): Add m_timeFormatWithSeconds.
32667         * platform/text/LocaleWin.cpp:
32668         (WebCore::LocaleWin::dateFormat): Use isNull.
32669         (WebCore::LocaleWin::timeFormat): Use m_timeFormatWithSeconds.
32670
32671         * platform/text/mac/LocaleMac.h:
32672         (LocaleMac): Rename m_localized*TimeFormatText to m_timeFormatWith*Seconds.
32673         * platform/text/mac/LocaleMac.mm:
32674         (WebCore::LocaleMac::timeFormat): Follow the renaming.
32675         (WebCore::LocaleMac::shortTimeFormat): Ditto.
32676
32677 2012-10-26  Kent Tamura  <tkent@chromium.org>
32678
32679         Crash in PagePopupController by events after WebPagePopupImpl::closePopup
32680         https://bugs.webkit.org/show_bug.cgi?id=100454
32681
32682         Reviewed by Hajime Morita.
32683
32684         No new tests. The bug is timing-dependent.
32685
32686         * page/DOMWindowPagePopup.cpp:
32687         (WebCore::DOMWindowPagePopup::~DOMWindowPagePopup):
32688         Calls clearPagePopupClient for the associalated PagePopupController object.
32689         * page/PagePopupController.cpp:
32690         (WebCore::PagePopupController::setValueAndClosePopup):
32691         Do nothing if m_popupClient is 0.
32692         (WebCore::PagePopupController::localizeNumberString): Ditto.
32693         (WebCore::PagePopupController::clearPagePopupClient): Added.
32694         * page/PagePopupController.h:
32695         (PagePopupController): Declare clearPagePopupClient.
32696
32697 2012-10-25  Alexander Pavlov  <apavlov@chromium.org>
32698
32699         Web Inspector: Bring device geolocation and orientation emulation from behind the experiment
32700         https://bugs.webkit.org/show_bug.cgi?id=100220
32701
32702         Reviewed by Yury Semikhatsky.
32703
32704         * inspector/front-end/Settings.js:
32705         (WebInspector.ExperimentsSettings):
32706         * inspector/front-end/SettingsScreen.js:
32707         (WebInspector.UserAgentSettingsTab):
32708
32709 2012-10-26  Yury Semikhatsky  <yurys@chromium.org>
32710
32711         Memory instrumentation: report memory occupied by ResourceRequest instead of its base ResourceRequestBase
32712         https://bugs.webkit.org/show_bug.cgi?id=100497
32713
32714         Reviewed by Alexander Pavlov.
32715
32716         Added memory reporting method to Chromium implementation of ResourceRequest.
32717
32718         * platform/network/ResourceRequestBase.cpp:
32719         (WebCore::ResourceRequestBase::reportMemoryUsageBase): Renamed reportMemoryUsage
32720         on ResourceRequestBase to reportMemoryUsageBase and made it protected. I'd
32721         rather make ResourceRequestBase::reportMemoryUsage virtual and override it
32722         in the descendant but ResourceRequestBase doesn't have any virtual methods
32723         and shouldn't be used directly (ResourceRequest should be used instead).
32724         * platform/network/ResourceRequestBase.h:
32725         (ResourceRequestBase):
32726         * platform/network/chromium/ResourceRequest.cpp:
32727         (WebCore::ResourceRequest::reportMemoryUsage):
32728         (WebCore):
32729         * platform/network/chromium/ResourceRequest.h:
32730         (ResourceRequest):
32731
32732 2012-10-26  Alexander Pavlov  <apavlov@chromium.org>
32733
32734         Web Inspector: Remove the on-hover highlighting of console messages
32735         https://bugs.webkit.org/show_bug.cgi?id=100511
32736
32737         Reviewed by Pavel Feldman.
32738
32739         This clashes with the hovered element highlight in console messages.
32740
32741         * inspector/front-end/inspector.css:
32742         (ol.watch-expressions > li.hovered):
32743
32744 2012-10-26  Sheriff Bot  <webkit.review.bot@gmail.com>
32745
32746         Unreviewed, rolling out r132612.
32747         http://trac.webkit.org/changeset/132612
32748         https://bugs.webkit.org/show_bug.cgi?id=100512
32749
32750         Crashes fast/events/tabindex-focus-blur-all.html in debug mode
32751         (Requested by pfeldman on #webkit).
32752
32753         * rendering/AutoTableLayout.cpp:
32754         (WebCore::AutoTableLayout::recalcColumn):
32755         * rendering/FixedTableLayout.cpp:
32756         (WebCore::FixedTableLayout::calcWidthArray):
32757         * rendering/RenderTable.cpp:
32758         (WebCore::RenderTable::layout):
32759         * rendering/RenderTableCol.cpp:
32760         (WebCore::RenderTableCol::styleDidChange):
32761         (WebCore::RenderTableCol::updateFromElement):
32762         (WebCore::RenderTableCol::computePreferredLogicalWidths):
32763         * rendering/RenderTableCol.h:
32764         (RenderTableCol):
32765
32766 2012-10-26  Pavel Feldman  <pfeldman@chromium.org>
32767
32768         Web Inspector: fast return upon setting the same dock side.
32769         https://bugs.webkit.org/show_bug.cgi?id=100510
32770
32771         Reviewed by Vsevolod Vlasov.
32772
32773         Added fast return.
32774
32775         * inspector/front-end/DockController.js:
32776
32777 2012-10-26  Simon Hausmann  <simon.hausmann@digia.com>
32778
32779         Unreviewed trivial build fix: It's glXGetCurrentContext not glxGetCurrentContext :)
32780
32781         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
32782         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
32783
32784 2012-10-26  Kenneth Rohde Christiansen  <kenneth@webkit.org>
32785
32786         Printing should use use high resolution images when available
32787         https://bugs.webkit.org/show_bug.cgi?id=100488
32788
32789         Reviewed by Antti Koivisto.
32790
32791         The images loaded using -webkit-device-pixel-ratio depends on
32792         the display type (deviceScaleFactor) and thus affects which
32793         images are being used for printing. Printing should always
32794         use the higher resolution images (aka 'retina' images).
32795
32796         Test: fast/media/mq-pixel-ratio-print.html
32797
32798         * css/MediaQueryEvaluator.cpp:
32799         (WebCore::device_pixel_ratioMediaFeatureEval):
32800
32801 2012-10-26  Ilya Tikhonovsky  <loislo@chromium.org>
32802
32803         Web Inspector: NMI instrument InspectorResourceAgent. it caches resources for the front-end.
32804         https://bugs.webkit.org/show_bug.cgi?id=100496
32805
32806         Reviewed by Yury Semikhatsky.
32807
32808         It is plain instrumentation for InspectorResourceAgent and NetworkResourceData which is used by the agent.
32809
32810         * dom/WebCoreMemoryInstrumentation.cpp:
32811         (WebCore):
32812         * dom/WebCoreMemoryInstrumentation.h:
32813         (WebCoreMemoryTypes):
32814         * inspector/InspectorResourceAgent.cpp:
32815         (WebCore::InspectorResourceAgent::reportMemoryUsage):
32816         (WebCore):
32817         * inspector/InspectorResourceAgent.h:
32818         (InspectorResourceAgent):
32819         * inspector/NetworkResourcesData.cpp:
32820         (WebCore::XHRReplayData::reportMemoryUsage):
32821         (WebCore):
32822         (WebCore::NetworkResourcesData::ResourceData::reportMemoryUsage):
32823         (WebCore::NetworkResourcesData::reportMemoryUsage):
32824         * inspector/NetworkResourcesData.h:
32825         (XHRReplayData):
32826         (ResourceData):
32827         (NetworkResourcesData):
32828
32829 2012-10-26  Sheriff Bot  <webkit.review.bot@gmail.com>
32830
32831         Unreviewed, rolling out r132493.
32832         http://trac.webkit.org/changeset/132493
32833         https://bugs.webkit.org/show_bug.cgi?id=100509
32834
32835         It didn't fix the tests on the bot as we had hoped. (Requested
32836         by drott on #webkit).
32837
32838         * platform/network/cf/ResourceErrorCF.cpp:
32839         (WebCore::ResourceError::ResourceError):
32840
32841 2012-10-26  Zeno Albisser  <zeno@webkit.org>
32842
32843         [Qt] Temporarily disable use of QXcbNativeInterface in GraphicsSurfaceGLX.
32844         https://bugs.webkit.org/show_bug.cgi?id=100493
32845
32846         Once QXcbNativeInterface::nativeResourceForContext() can provide the
32847         GLXContext for an existing QOpenGLContext, this patch shall be reverted.
32848
32849         Reviewed by Simon Hausmann.
32850
32851         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
32852         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
32853
32854 2012-10-26  Zeno Albisser  <zeno@webkit.org>
32855
32856         [Qt] Remove QOpenGL specific code from GraphicsSurfaceGLX.
32857         https://bugs.webkit.org/show_bug.cgi?id=100492
32858
32859         This patch removes most of the QOpenGLContext related code
32860         from GraphicsSurfaceGLX. This allows sharing almost all
32861         GraphicsSurfaceGLX code with EFL, by relying on pure GLX.
32862
32863         Reviewed by Kenneth Rohde Christiansen.
32864
32865         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
32866         (WebCore::OffScreenRootWindow::get):
32867         (WebCore::OffScreenRootWindow::~OffScreenRootWindow):
32868         (OffScreenRootWindow):
32869         (WebCore):
32870         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
32871         (WebCore::GraphicsSurfacePrivate::createSurface):
32872         (WebCore::GraphicsSurfacePrivate::makeCurrent):
32873         (WebCore::GraphicsSurfacePrivate::doneCurrent):
32874         (WebCore::GraphicsSurfacePrivate::swapBuffers):
32875         (WebCore::GraphicsSurfacePrivate::copyFromTexture):
32876         (GraphicsSurfacePrivate):
32877         (WebCore::resolveGLMethods):
32878
32879 2012-10-26  Regina Chung  <heejin.r.chung@samsung.com>
32880
32881         [EFL][WK2] Enable WebGL
32882         https://bugs.webkit.org/show_bug.cgi?id=97652
32883
32884         Reviewed by Gyuyoung Kim.
32885
32886         Implemented GraphicsSurface for EFL to enable WebGL for WebKit2.
32887         Depends on GLX since Evas doesn't provide the necessary functionality.
32888
32889         No new tests. Covered by existing tests.
32890
32891         * PlatformEfl.cmake:
32892         * platform/graphics/GraphicsContext3D.h:
32893         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
32894         (WebCore::GraphicsContext3D::createGraphicsSurfaces):
32895         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
32896         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
32897         (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
32898         (WebCore):
32899         (WebCore::GraphicsContext3DPrivate::createGraphicsSurfaces):
32900         (WebCore::GraphicsContext3DPrivate::copyToGraphicsSurface):
32901         (WebCore::GraphicsContext3DPrivate::graphicsSurfaceToken):
32902         * platform/graphics/efl/GraphicsContext3DPrivate.h:
32903         (GraphicsContext3DPrivate):
32904         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
32905         (WebCore::GraphicsContext3D::reshape):
32906         * platform/graphics/surfaces/efl: Added.
32907         * platform/graphics/surfaces/efl/GraphicsSurfaceEfl.cpp: Added.
32908         (WebCore):
32909         (WebCore::OffScreenRootWindow::get):
32910         (WebCore::OffScreenRootWindow::~OffScreenRootWindow):
32911         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
32912         (WebCore::GraphicsSurfacePrivate::createSurface):
32913         (WebCore::GraphicsSurfacePrivate::makeCurrent):
32914         (WebCore::GraphicsSurfacePrivate::doneCurrent):
32915         (WebCore::GraphicsSurfacePrivate::swapBuffers):
32916         (WebCore::GraphicsSurface::platformBeginPaint):
32917         (WebCore::GraphicsSurface::createReadOnlyImage):
32918         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
32919         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.h: Added.
32920         (WebCore):
32921         (OffScreenRootWindow):
32922         (WebCore::OffScreenRootWindow::OffScreenRootWindow):
32923         (GraphicsSurfacePrivate):
32924         (WebCore::GraphicsSurfacePrivate::~GraphicsSurfacePrivate):
32925         (WebCore::GraphicsSurfacePrivate::createPixmap):
32926         (WebCore::GraphicsSurfacePrivate::copyFromTexture):
32927         (WebCore::GraphicsSurfacePrivate::display):
32928         (WebCore::GraphicsSurfacePrivate::glxPixmap):
32929         (WebCore::GraphicsSurfacePrivate::size):
32930         (WebCore::GraphicsSurfacePrivate::glContext):
32931         (WebCore::resolveGLMethods):
32932         * platform/graphics/surfaces/qt/GraphicsSurfaceQt.cpp:
32933         (WebCore):
32934         (WebCore::OffScreenRootWindow::OffScreenRootWindow::get):
32935         (WebCore::OffScreenRootWindow::~OffScreenRootWindow):
32936         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
32937         (WebCore::GraphicsSurfacePrivate::createSurface):
32938         (WebCore::GraphicsSurfacePrivate::makeCurrent):
32939         (WebCore::GraphicsSurfacePrivate::doneCurrent):
32940         (WebCore::GraphicsSurfacePrivate::swapBuffers):
32941
32942 2012-10-26  Alexander Pavlov  <apavlov@chromium.org>
32943
32944         Web Inspector: [Overrides] Do not persist the User Agent "master switch"
32945         https://bugs.webkit.org/show_bug.cgi?id=100484
32946
32947         Reviewed by Yury Semikhatsky.
32948
32949         The User Agent override state is managed in the front-end, just like for other override-able parameters.
32950
32951         * inspector/InspectorResourceAgent.cpp:
32952         (WebCore::InspectorResourceAgent::disable):
32953         * inspector/front-end/NetworkManager.js:
32954         (WebInspector.NetworkManager.get NetworkAgent):
32955         (WebInspector.NetworkManager):
32956         * inspector/front-end/SettingsScreen.js:
32957         (WebInspector.UserAgentSettingsTab.prototype._createUserAgentSelectRowElement.set checkboxClicked):
32958         (WebInspector.UserAgentSettingsTab.prototype._createUserAgentSelectRowElement):
32959         * inspector/front-end/UserAgentSupport.js:
32960         (WebInspector.UserAgentSupport):
32961         (WebInspector.UserAgentSupport.prototype.toggleUserAgentOverride):
32962         (WebInspector.UserAgentSupport.prototype._userAgentChanged):
32963
32964 2012-10-26  Takashi Sakamoto  <tasak@google.com>
32965
32966         [Shadow]: removing styles in shadow dom subtree causes crash.
32967         https://bugs.webkit.org/show_bug.cgi?id=100455
32968
32969         Reviewed by Hajime Morita.
32970
32971         To quickly check whether shadow roots or elements have any scoped
32972         styles or not, elements have hasStyleScoped flag. If elements have
32973         any scoped styles, the styles are direct children of the element.
32974         The original code just sees how many chilren are scoped style or not.
32975         However styles in shadow dom subtree are registered with the shadow
32976         root but are not always direct children of shadow roots. So to check
32977         whether shadow roots have any scoped styles, modified to count
32978         number of styles registered with the shadow root.
32979
32980         Test: fast/dom/shadow/remove-styles-in-shadow-crash.html
32981
32982         * dom/Node.cpp:
32983         (WebCore::Node::registerScopedHTMLStyleChild):
32984         (WebCore::Node::unregisterScopedHTMLStyleChild):
32985         Made the above two method virtual. class ShadowRoot overrides these
32986         methods.
32987         (WebCore::Node::numberOfScopedHTMLStyleChildren):
32988         Moved HTMLStyleElement.cpp to Node.cpp, because the above two methods
32989         are moved into Node.cpp.
32990         * dom/Node.h:
32991         (Node):
32992         * dom/ShadowRoot.cpp:
32993         (WebCore::ShadowRoot::ShadowRoot):
32994         (WebCore::ShadowRoot::registerScopedHTMLStyleChild):
32995         (WebCore::ShadowRoot::unregisterScopedHTMLStyleChild):
32996         Modify to count how many styles are registered with the shadow root.
32997         The "counting" is done when styles are registered and unregistered
32998         with the shadow root, i.e. style element is inserted into document or
32999         removed from document. When unregister some style, there are no more
33000         styles registered with the shadow root. Set style scoped flag false.
33001         * dom/ShadowRoot.h:
33002         (ShadowRoot):
33003         * html/HTMLStyleElement.cpp:
33004         * html/HTMLStyleElement.h:
33005         (WebCore::HTMLStyleElement::isRegisteredAsScoped):
33006         Now isRegisteredAsScoped is used in Node.cpp, so removed inline and
33007         moved .cpp to .h.
33008
33009 2012-10-26  Sheriff Bot  <webkit.review.bot@gmail.com>
33010
33011         Unreviewed, rolling out r132589.
33012         http://trac.webkit.org/changeset/132589
33013         https://bugs.webkit.org/show_bug.cgi?id=100498
33014
33015         Breaks font-face layout tests (Requested by pfeldman on
33016         #webkit).
33017
33018         * css/CSSFontFaceSource.cpp:
33019         (WebCore::CSSFontFaceSource::getFontData):
33020
33021 2012-10-26  Takashi Sakamoto  <tasak@google.com>
33022
33023         [Shadow DOM] Needs @host rule for ShadowDOM styling
33024         https://bugs.webkit.org/show_bug.cgi?id=88606
33025
33026         Reviewed by Hajime Morita.
33027
33028         Implemented @host-@rules according to the shadow dom spec:
33029         http://dvcs.w3.org/hg/webcomponents/raw-file/tip/spec/shadow/index.html#host-at-rule
33030         The design doc is:
33031         https://docs.google.com/document/d/1P2yorchF8lci2sccr-mVSRf2dtvjKeiuyQWzCB2bEA8/edit
33032
33033         Test: fast/dom/shadow/athost-atrules.html
33034
33035         * css/CSSGrammar.y.in:
33036         Added rules for parsing @host @-rules.
33037         * css/CSSParser.cpp:
33038         (WebCore::CSSParser::detectAtToken):
33039         Added a new token "@host".
33040         (WebCore::CSSParser::createHostRule):
33041         Added a new method to create an @host @-rule, which is invoked from
33042         (WebCore):
33043         * css/CSSParser.h:
33044         Added a declaration of the above new method: createHostRule.
33045         * css/CSSPropertySourceData.h:
33046         Added HOST_RULE to enum Type.
33047         * css/RuleSet.cpp:
33048         (WebCore::RuleData::RuleData):
33049         Modified multiple bool arguments into one argument. Now it
33050         uses combinations of values from enum AddRuleFlags.
33051         (WebCore::RuleSet::addRule):
33052         (WebCore::RuleSet::addRegionRule):
33053         (WebCore::RuleSet::addStyleRule):
33054         Updated according to the RuleData's change.
33055         Modified to Invoke increaseSpecificity if the given rule is @host
33056         @-rule.
33057         (WebCore::RuleSet::addRulesFromSheet):
33058         Invoked addHostRule if the given rule is @host @-rule.
33059         * css/RuleSet.h:
33060         (RuleData):
33061         (WebCore::RuleData::increaseSpecificity):
33062         Added a new method to increase selector's specificity. This method is
33063         used to make @host @-rules' specificity larger than normal author
33064         rules' specificity.
33065         (RuleSet):
33066         * css/StyleResolver.cpp:
33067         (WebCore::makeRuleSet):
33068         (WebCore::StyleResolver::addHostRule):
33069         A wrapper method to invoke StyleScopeResolver::addHostRule. The method
33070         is used to make only StyleResolver know an implementation detail about
33071         class StyleScopeResolver.
33072         (WebCore::StyleResolver::appendAuthorStylesheets):
33073         Updated according to the RuleData's change.
33074         (WebCore::StyleResolver::styleSharingCandidateMatchesHostRules):
33075         A new method to find matched host rules when an element is given.
33076         This method invokes
33077         StyleScopeResolver::styleSharingCandidateMatchesHostRules to find
33078         matched host rules.
33079         (WebCore):
33080         (WebCore::StyleResolver::matchHostRules):
33081         A new method to find matched host rules when an element is given.
33082         This method invokes StyleScopeResolver::matchHostRules to find
33083         matched host rules.
33084         (WebCore::StyleResolver::matchScopedAuthorRules):
33085         Modified to invoke matchHostRules.
33086         (WebCore::StyleResolver::locateSharedStyle):
33087         Disable sibling style cache if the given element is a shadow host and
33088         any @host @-rules are applied to the element.
33089         * css/StyleResolver.h:
33090         (WebCore::StyleResolver::ensureScopeResolver):
33091         If no scopeResolver is created, create and return the instance.
33092         If created, just return the instance.
33093         (StyleResolver):
33094         * css/StyleRule.cpp:
33095         (WebCore::StyleRuleBase::reportMemoryUsage):
33096         (WebCore::StyleRuleBase::destroy):
33097         (WebCore::StyleRuleBase::copy):
33098         (WebCore::StyleRuleBase::createCSSOMWrapper):
33099         (WebCore::StyleRuleHost::StyleRuleHost):
33100         Implemented class StyleRuleHost. The class is almost the same as
33101         StyleRuleBlock except type.
33102         (WebCore):
33103         * css/StyleRule.h:
33104         (WebCore::StyleRuleBase::isHostRule):
33105         (StyleRuleHost):
33106         (WebCore::StyleRuleHost::create):
33107         (WebCore::StyleRuleHost::copy):
33108         (WebCore):
33109         * css/StyleScopeResolver.cpp:
33110         (WebCore::StyleScopeResolver::ensureAtHostRuleSetFor):
33111         A new method to create a new RuleSet for the given shadow root.
33112         (WebCore):
33113         (WebCore::StyleScopeResolver::atHostRuleSetFor):
33114         A new private inline method to obtain @host @-rules declared in
33115         the given shadow root.
33116         (WebCore::StyleScopeResolver::addHostRule):
33117         Added a new method to register @host @-rules with shadow roots.
33118         (WebCore::StyleScopeResolver::styleSharingCandidateMatchesHostRules):
33119         A new method to find whether any @host @-rules are applied to
33120         the given host element.
33121         (WebCore::StyleScopeResolver::matchHostRules):
33122         A new method to find matched rules for the given host element.
33123         (WebCore::StyleScopeResolver::reportMemoryUsage):
33124         * css/StyleScopeResolver.h:
33125         (WebCore):
33126         (StyleScopeResolver):
33127         * css/StyleSheetContents.cpp:
33128         (WebCore::childRulesHaveFailedOrCanceledSubresources):
33129
33130 2012-10-26  Jaehun Lim  <ljaehun.lim@samsung.com>
33131
33132         [CMAKE] Add TextAutosizer.cpp in WebCore/CMakeLists.txt
33133         https://bugs.webkit.org/show_bug.cgi?id=100476
33134
33135         Reviewed by Kentaro Hara.
33136
33137         ENABLE_TEXT_AUTOSIZING option is added in CMAKE,
33138         but the source file for that feature is omitted.
33139
33140         No new tests. Covered by existing tests.
33141
33142         * CMakeLists.txt:
33143
33144 2012-10-26  Julien Chaffraix  <jchaffraix@webkit.org>
33145
33146         RenderTableCol::computePreferredLogicalWidths and RenderTableCol::layout should never be called
33147         https://bugs.webkit.org/show_bug.cgi?id=99861
33148
33149         Reviewed by Ojan Vafai.
33150
33151         RenderTableCol's computePreferredLogicalWidths and layout's only purpose were to clear the preferred logical
33152         widths dirty / layout flag so that we would properly propagate the information to our containing table. This
33153         led to clunky code where the table layout code had to forcefully call RenderTableCol::computePreferredLogicalWidths
33154         or else we would ignore the next layout hint on the <col> or <colgroup>.
33155
33156         Tests: fast/table/col-span-change-relayout.html
33157                fast/table/simplified-layout-table.html
33158
33159         * rendering/AutoTableLayout.cpp:
33160         (WebCore::AutoTableLayout::recalcColumn):
33161         * rendering/RenderTable.cpp:
33162         (WebCore::RenderTable::layout):
33163         Simplified the code now that we only need to iterate over the sections.
33164
33165         * rendering/FixedTableLayout.cpp:
33166         (WebCore::FixedTableLayout::calcWidthArray):
33167         Removed call to computePreferredLogicalWidths.
33168
33169         * rendering/RenderTableCol.cpp:
33170         (WebCore::RenderTableCol::styleDidChange):
33171         (WebCore::RenderTableCol::updateFromElement):
33172         Forward a layout hint to the table so that we properly recompute the cell's logical withs.
33173
33174         (WebCore::RenderTableCol::computePreferredLogicalWidths):
33175         (WebCore::RenderTableCol::layout):
33176         Change our implementations of those 2 methods to be no-ops, while enforcing that they are
33177         never called when it was possible.
33178
33179         (WebCore::RenderTableCol::propagateLayoutCueToTable):
33180         New helper function that forward any layout cue to the containing table, this works around
33181         us not clearing the flags which confuses RenderObject markContainingBlocksForLayout and
33182         invalidateContainerPreferredLogicalWidths.
33183
33184         * rendering/RenderTableCol.h:
33185         Made the function that we are not expected to be called private.
33186
33187 2012-10-26  Sheriff Bot  <webkit.review.bot@gmail.com>
33188
33189         Unreviewed, rolling out r132601.
33190         http://trac.webkit.org/changeset/132601
33191         https://bugs.webkit.org/show_bug.cgi?id=100494
33192
33193         It broke the Qt build (Requested by Ossy on #webkit).
33194
33195         * PlatformEfl.cmake:
33196         * platform/graphics/GraphicsContext3D.h:
33197         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
33198         (WebCore::GraphicsContext3D::createGraphicsSurfaces):
33199         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
33200         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
33201         (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
33202         (WebCore):
33203         * platform/graphics/efl/GraphicsContext3DPrivate.h:
33204         (GraphicsContext3DPrivate):
33205         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
33206         (WebCore::GraphicsContext3D::reshape):
33207         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
33208         (WebCore::OffScreenRootWindow::get):
33209         (WebCore::OffScreenRootWindow::~OffScreenRootWindow):
33210         (OffScreenRootWindow):
33211         (WebCore):
33212         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
33213         (WebCore::GraphicsSurfacePrivate::createSurface):
33214         (WebCore::GraphicsSurfacePrivate::makeCurrent):
33215         (WebCore::GraphicsSurfacePrivate::doneCurrent):
33216         (WebCore::GraphicsSurfacePrivate::swapBuffers):
33217         (WebCore::GraphicsSurfacePrivate::copyFromTexture):
33218         (GraphicsSurfacePrivate):
33219         (WebCore::resolveGLMethods):
33220
33221 2012-10-26  Yury Semikhatsky  <yurys@chromium.org>
33222
33223         Memory instrumentation: do not report memory occupied by v8::String
33224         https://bugs.webkit.org/show_bug.cgi?id=100487
33225
33226         Reviewed by Alexander Pavlov.
33227
33228         Pointers to v8::String are skipped when reporting memory usage of V8 bindings'
33229         string cache.
33230
33231         * bindings/v8/V8Binding.cpp:
33232         (WTF):
33233
33234 2012-10-26  Mihnea Ovidenie  <mihnea@adobe.com>
33235
33236         [CSSRegions] Add support for auto-height regions with region-breaks
33237         https://bugs.webkit.org/show_bug.cgi?id=99952
33238
33239         Reviewed by David Hyatt.
33240
33241         This patch takes region breaks into account when computing the height for auto logical height regions.
33242         When a region break is encountered before/after an element from within a flow thread and we are in the layout
33243         phase in which we lay out the flow threads in regions unconstrained, we use the region break to
33244         compute the region override logical content height if the region break fits inside an auto logical height region.
33245         A region break inside an auto logical height region determines the region override logical content height, taking
33246         min/max height into account.
33247
33248         Tests: fast/regions/autoheight-allregions-nobreaks.html
33249                fast/regions/autoheight-allregions.html
33250                fast/regions/autoheight-breakafteralways-maxheight.html
33251                fast/regions/autoheight-breakbeforealways.html
33252                fast/regions/autoheight-firstregion-breakalways.html
33253                fast/regions/autoheight-lastregion-overflowauto-breaksignored.html
33254                fast/regions/autoheight-lastregion-overflowauto.html
33255                fast/regions/autoheight-middleregion.html
33256                fast/regions/autoheight-secondregion-breakoutside.html
33257                fast/regions/autoheight-secondregion.html
33258                fast/regions/autoheight-singleregion-breakafteralways-maxheight.html
33259                fast/regions/autoheight-singleregion-breakafteralways.html
33260                fast/regions/autoheight-singleregion-breakaftermargin.html
33261                fast/regions/autoheight-singleregion-breakbeforealways-minheight.html
33262                fast/regions/autoheight-singleregion-breakbeforealways.html
33263                fast/regions/autoheight-singleregion-multiplebreaks.html
33264                fast/regions/autoheight-singleregion-overflowauto-breaksignored.html
33265                fast/regions/autoheight-singleregion-overflowauto.html
33266
33267         * rendering/RenderBlock.cpp: When encounter a region break before/after an element inside a flow thread,
33268         try to use it to determine the override logical content height for auto logical height regions.
33269         (WebCore::RenderBlock::applyBeforeBreak):
33270         (WebCore::RenderBlock::applyAfterBreak):
33271         * rendering/RenderFlowThread.cpp:
33272         (WebCore::RenderFlowThread::layout):
33273         (WebCore::RenderFlowThread::computeOverflowStateForRegions):
33274         Simulate a region break at the end of the flow thread content.
33275         (WebCore::RenderFlowThread::updateRegionsFlowThreadPortionRect):
33276         (WebCore::RenderFlowThread::clearOverrideLogicalContentHeightInRegions):
33277         Helper method used to clear the overrideLogicalContentHeight for auto logical height regions.
33278         (WebCore::RenderFlowThread::addForcedRegionBreak):
33279         Extend the method to process region breaks. The method returns true if at least one auto logical height region
33280         has its override logical content height computed.        
33281         * rendering/RenderFlowThread.h:
33282         * rendering/RenderRegion.cpp: Make these methods work with auto logical height regions.
33283         (WebCore::RenderRegion::pageLogicalHeight):
33284         (WebCore::RenderRegion::logicalHeightOfAllFlowThreadContent):
33285
33286 2012-10-26  Regina Chung  <heejin.r.chung@samsung.com>
33287
33288         [EFL][WK2] Enable WebGL
33289         https://bugs.webkit.org/show_bug.cgi?id=97652
33290
33291         Reviewed by Gyuyoung Kim.
33292
33293         Implemented GraphicsSurface for EFL to enable WebGL for WebKit2.
33294         Depends on GLX since Evas doesn't provide the necessary functionality.
33295
33296         No new tests. Covered by existing tests.
33297
33298         * PlatformEfl.cmake:
33299         * platform/graphics/GraphicsContext3D.h:
33300         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
33301         (WebCore::GraphicsContext3D::createGraphicsSurfaces):
33302         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
33303         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
33304         (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
33305         (WebCore):
33306         (WebCore::GraphicsContext3DPrivate::createGraphicsSurfaces):
33307         (WebCore::GraphicsContext3DPrivate::copyToGraphicsSurface):
33308         (WebCore::GraphicsContext3DPrivate::graphicsSurfaceToken):
33309         * platform/graphics/efl/GraphicsContext3DPrivate.h:
33310         (GraphicsContext3DPrivate):
33311         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
33312         (WebCore::GraphicsContext3D::reshape):
33313         * platform/graphics/surfaces/efl: Added.
33314         * platform/graphics/surfaces/efl/GraphicsSurfaceEfl.cpp: Added.
33315         (WebCore):
33316         (WebCore::OffScreenRootWindow::get):
33317         (WebCore::OffScreenRootWindow::~OffScreenRootWindow):
33318         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
33319         (WebCore::GraphicsSurfacePrivate::createSurface):
33320         (WebCore::GraphicsSurfacePrivate::makeCurrent):
33321         (WebCore::GraphicsSurfacePrivate::doneCurrent):
33322         (WebCore::GraphicsSurfacePrivate::swapBuffers):
33323         (WebCore::GraphicsSurface::platformBeginPaint):
33324         (WebCore::GraphicsSurface::createReadOnlyImage):
33325         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
33326         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.h: Added.
33327         (WebCore):
33328         (OffScreenRootWindow):
33329         (WebCore::OffScreenRootWindow::OffScreenRootWindow):
33330         (GraphicsSurfacePrivate):
33331         (WebCore::GraphicsSurfacePrivate::~GraphicsSurfacePrivate):
33332         (WebCore::GraphicsSurfacePrivate::createPixmap):
33333         (WebCore::GraphicsSurfacePrivate::copyFromTexture):
33334         (WebCore::GraphicsSurfacePrivate::display):
33335         (WebCore::GraphicsSurfacePrivate::glxPixmap):
33336         (WebCore::GraphicsSurfacePrivate::size):
33337         (WebCore::GraphicsSurfacePrivate::glContext):
33338         (WebCore::resolveGLMethods):
33339         * platform/graphics/surfaces/qt/GraphicsSurfaceQt.cpp:
33340         (WebCore):
33341         (WebCore::OffScreenRootWindow::OffScreenRootWindow::get):
33342         (WebCore::OffScreenRootWindow::~OffScreenRootWindow):
33343         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
33344         (WebCore::GraphicsSurfacePrivate::createSurface):
33345         (WebCore::GraphicsSurfacePrivate::makeCurrent):
33346         (WebCore::GraphicsSurfacePrivate::doneCurrent):
33347         (WebCore::GraphicsSurfacePrivate::swapBuffers):
33348
33349 2012-10-26  Thiago Marcos P. Santos  <thiago.santos@intel.com>
33350
33351         Add feature flags for CSS Device Adaptation
33352         https://bugs.webkit.org/show_bug.cgi?id=95960
33353
33354         Reviewed by Kenneth Rohde Christiansen.
33355
33356         * Configurations/FeatureDefines.xcconfig:
33357         * GNUmakefile.am:
33358         * GNUmakefile.features.am:
33359
33360 2012-10-26  Li Yin  <li.yin@intel.com>
33361
33362         fast/forms/file/input-file-write-files.html should cover correct setting value
33363         https://bugs.webkit.org/show_bug.cgi?id=100085
33364
33365         Reviewed by Kentaro Hara.
33366
33367         From Spec: http://dev.w3.org/html5/spec/single-page.html#dom-input-value-filename
33368         On setting, if the new value is the empty string, it must empty the list of selected
33369         files; otherwise, it must throw an InvalidStateError exception.
33370
33371         Test: fast/forms/file/input-file-value.html
33372
33373         * html/HTMLInputElement.cpp:
33374         (WebCore::HTMLInputElement::setValue):
33375         (WebCore):
33376         * html/HTMLInputElement.h:
33377         (HTMLInputElement):
33378         * html/HTMLInputElement.idl:
33379
33380 2012-10-26  Keishi Hattori  <keishi@webkit.org>
33381
33382         Refactor calendar picker to remove _x/_y from DaysTable
33383         https://bugs.webkit.org/show_bug.cgi?id=100460
33384
33385         Reviewed by Kent Tamura.
33386
33387         _x/_y properties keep the coordinates for the selection but when we add
33388         week and month picking capabilities, the selection can't be expressed as
33389         a set of coordinates. This change will remove it.
33390
33391         No new tests. Covered by calendar-picker-*.html tests.
33392
33393         * Resources/pagepopups/calendarPicker.js:
33394         (DaysTable): Removed _x/_y properties.
33395         (DaysTable.prototype._hasSelection): Changed to refer to the DOM to see if we have a selection.
33396         (DaysTable.prototype.navigateToMonthAndKeepSelectionPosition): Lookup the selection position.
33397         (DaysTable.prototype.selectDate): Deselect first so we don't have two selections.
33398         (DaysTable.prototype._selectRangeContainingNode): Selects date/week/month containing the given day node.
33399         (DaysTable.prototype._selectRangeAtPosition): Selects date/week/month at the given position.
33400         (DaysTable.prototype._firstNodeInSelectedRange): Returns first selected day node.
33401         (DaysTable.prototype._deselect): Deselects all selections.
33402         (DaysTable.prototype._handleMouseOver): Use _selectRangeContainingNode so we don't have many places handling the selection.
33403         (DaysTable.prototype._handleMouseOut): Use _deselect.
33404         (DaysTable.prototype._handleKey): Lookup the selection position.
33405         (DaysTable.prototype.updateSelection): Use _selectRangeAtPosition.
33406
33407 2012-10-26  Ningxin Hu  <ningxin.hu@intel.com>
33408
33409         FileReader abort case causes Chromium renderer crash
33410         https://bugs.webkit.org/show_bug.cgi?id=99142
33411
33412         Reviewed by Kentaro Hara.
33413
33414         Before dispatching load event, FileReader should check if it is
33415         in aborting.
33416
33417         Test: manually launch fast/files/file-reader-abort.html in Chromium
33418         browser and compare the result with
33419         fast/files/file-reader-abort-expected.txt.
33420
33421         * fileapi/FileReader.cpp:
33422         (WebCore::FileReader::didFinishLoading):
33423
33424 2012-10-26  Julien Chaffraix  <jchaffraix@webkit.org>
33425
33426         Generate less repaint calls during subtree detaching
33427         https://bugs.webkit.org/show_bug.cgi?id=99741
33428
33429         Reviewed by Eric Seidel.
33430
33431         Following bug 98336, detach is now a subtree top-down operation. Because we
33432         track visual overflow from our children during layout for most cases, we can
33433         generate a repaint only on the subtree root.
33434
33435         On http://dglazkov.github.com/performance-tests/redraw.html, this ups the FPS to
33436         26 fps from 22 fps on my MBP (+ 15%). On PerformanceTests/layout/subtree-detach.html,
33437         it decreases the time by 35%. This is due to being the best case and we now generate
33438         only one repaint per detach phase.
33439
33440         Covered by existing pixels tests (including but not limited to repaint ones).
33441
33442         * rendering/RenderObject.cpp:
33443         (WebCore::RenderObject::destroyAndCleanupAnonymousWrappers):
33444         Changed the function not to be recursive anymore to generate one painting for
33445         our root only. Added a FIXME about using our RenderLayer for repainting to avoid
33446         the cost of computing our absolute repaint rectangle.
33447
33448         * rendering/RenderObjectChildList.cpp:
33449         (WebCore::RenderObjectChildList::removeChildNode):
33450         Removed the logic for repainting in the general case. However we still force a repaint
33451         if we have a RenderLayer as we don't track their overflow in some cases (e.g. positioned
33452         objects). This check is conservative and could be narrowed down (e.g overflow RenderLayers
33453         are properly accounted for in our clipppedOverflowRectForRepaint).
33454
33455 2012-10-26  Kenichi Ishibashi  <bashi@chromium.org>
33456
33457         local(Helvetica) in src descriptor prevent fallback
33458         https://bugs.webkit.org/show_bug.cgi?id=100446
33459
33460         Reviewed by Dan Bernstein.
33461
33462         FontCache::getCachedFontData() has a mechanism that aliases a few pairs
33463         of font family names, so that if the family name specified in the font-family
33464         property is not available on the system, but the its alias is available,
33465         it will be used instead. This is appropriate for the font-family property,
33466         but not for font family names specified in the local() function of the src
33467         descriptor in a @font-face rule.
33468
33469         This patch disables the mechanism while checking src descriptor of @font-face.
33470
33471         No new tests. It's difficult to test the change because 'Helvetica' can
33472         be mapped any other font. For example, chromium DRT uses FontConfig to
33473         map Helvetica to Times New Roman. Other ports may map Helvetica to other
33474         fonts. We can't define the expected result.
33475
33476         * css/CSSFontFaceSource.cpp:
33477         (WebCore::CSSFontFaceSource::getFontData):
33478         Call fontCache()->getCachedFontData() with checkingAlternateName = true.
33479         This disables aliasing font family names in FontCache.
33480
33481 2012-10-26  Eugene Klyuchnikov  <eustas.bug@gmail.com>
33482
33483         Web Inspector: Doctype Audits panel code
33484         https://bugs.webkit.org/show_bug.cgi?id=100371
33485
33486         Reviewed by Alexander Pavlov.
33487
33488         This is a preparation step for ongoing refactoring.
33489         It is much easier to read doctyped code.
33490
33491         * inspector/front-end/AuditRules.js:
33492         (WebInspector.AuditRules.MinimizeDnsLookupsRule.prototype.doRun):
33493         Replaced "undefined" with "null"
33494         * inspector/front-end/AuditsPanel.js:
33495         (WebInspector.AuditCategory.prototype.callbackWrapper):
33496         Removed callback parameter indirection.        
33497         (WebInspector.AuditRuleResult.prototype.addFormatted):
33498         Converted private instance function to scoped function.
33499
33500 2012-10-26  János Badics  <jbadics@inf.u-szeged.hu>
33501
33502         [Qt]REGRESSION(r131428): cookies.db created on wrong place
33503         https://bugs.webkit.org/show_bug.cgi?id=99445
33504
33505         Reviewed by Simon Hausmann.
33506
33507         Added a slash to the path of cookies.db in CookieJarQt.cpp.
33508
33509         * platform/qt/CookieJarQt.cpp:
33510         (WebCore::SharedCookieJarQt::SharedCookieJarQt):
33511
33512 2012-10-26  Adam Barth  <abarth@webkit.org>
33513
33514         Unreviewed. This ASSERT is no longer correct (and fires on many tests.)
33515
33516         * bindings/v8/V8DOMWrapper.h:
33517         (WebCore::V8DOMWrapper::setJSWrapperForDOMObject):
33518
33519 2012-10-26  Kent Tamura  <tkent@chromium.org>
33520
33521         [Chromium-Win] Support shortTimeFormat
33522         https://bugs.webkit.org/show_bug.cgi?id=100471
33523
33524         Reviewed by Kentaro Hara.
33525
33526         No new tests. Covered by fast/forms/time-multiple-fields/ and
33527         WebKit/chromium/tests/LocaleWinTest.
33528
33529         * platform/text/LocaleWin.cpp:
33530         (WebCore::LocaleWin::shortTimeFormat):
33531         Gets a format by LOCALE_SSHORTTIME. If it fails, remove "<delimiter>ss"
33532         from the format by LOCALE_STIMEFORMAT.
33533         * platform/text/LocaleWin.h:
33534         (LocaleWin): Declare m_timeFormatWithoutSeconds.
33535
33536 2012-10-26  Adam Barth  <abarth@webkit.org>
33537
33538         Unreviewed. Update run-bindings-tests results after recent active DOM
33539         object changes.
33540
33541         * bindings/scripts/test/V8/V8TestInterface.cpp:
33542         (WebCore::V8TestInterface::constructorCallback):
33543         (WebCore::V8TestInterface::wrapSlow):
33544         * bindings/scripts/test/V8/V8TestInterface.h:
33545         (WebCore::V8TestInterface::wrap):
33546         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
33547         (WebCore::V8TestNamedConstructorConstructorCallback):
33548         (WebCore::V8TestNamedConstructor::wrapSlow):
33549         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
33550         (WebCore::V8TestNamedConstructor::wrap):
33551
33552 2012-10-26  MORITA Hajime  <morrita@google.com>
33553
33554         [V8] REGRESSION(132540) Assertion failure on V8DOMWrapper::setJSWrapperForDOMNode()
33555         https://bugs.webkit.org/show_bug.cgi?id=100462
33556
33557         Reviewed by Adam Barth.
33558
33559         Removed the no longer correct assertion statement.
33560
33561         No new tests. Covered by breaking tests.
33562
33563         * bindings/v8/V8DOMWrapper.cpp:
33564         (WebCore::V8DOMWrapper::setJSWrapperForDOMNode):
33565
33566 2012-10-25  Adam Barth  <abarth@webkit.org>
33567
33568         [V8] WorkerContextExecutionProxy should use ScopedPersistent
33569         https://bugs.webkit.org/show_bug.cgi?id=100443
33570
33571         Reviewed by Eric Seidel.
33572
33573         This class was manually re-implementing the ScopedPersistent pattern.
33574
33575         * bindings/v8/WorkerContextExecutionProxy.cpp:
33576         (WebCore::WorkerContextExecutionProxy::dispose):
33577         (WebCore::WorkerContextExecutionProxy::initializeIfNeeded):
33578         (WebCore::WorkerContextExecutionProxy::evaluate):
33579         * bindings/v8/WorkerContextExecutionProxy.h:
33580         (WebCore::WorkerContextExecutionProxy::context):
33581         (WorkerContextExecutionProxy):
33582
33583 2012-10-25  Peter Wang  <peter.wang@torchmobile.com.cn>
33584
33585         A mistake in WebCore::JavaScriptCallFrame::evaluate which will cause assert failed
33586         https://bugs.webkit.org/show_bug.cgi?id=100347
33587
33588         Reviewed by Mark Lam and Filip Pizlo.
33589
33590         In worker context, calling "JSDOMWindowBase::commonJSGlobalData" will cause assert,
33591         since there is "ASSERT(isMainThread())" in "JSDOMWindowBase::commonJSGlobalData".
33592
33593         No new test case, since no behaviour changed.
33594
33595         * bindings/js/JavaScriptCallFrame.cpp:
33596         (WebCore::JavaScriptCallFrame::evaluate):
33597
33598 2012-10-25  Adam Barth  <abarth@webkit.org>
33599
33600         [V8] We can merge the wrapper maps for DOM objects and active DOM objects
33601         https://bugs.webkit.org/show_bug.cgi?id=100432
33602
33603         Reviewed by Eric Seidel.
33604
33605         Now that we use the same object to visit both DOM objects and active
33606         DOM objects, there's no reason to keep them in separate hash maps.
33607
33608         * bindings/scripts/CodeGeneratorV8.pm:
33609         (GetDomMapName):
33610         * bindings/v8/DOMDataStore.cpp:
33611         (WebCore::DOMDataStore::DOMDataStore):
33612         (WebCore::DOMDataStore::~DOMDataStore):
33613         (WebCore::DOMDataStore::reportMemoryUsage):
33614         * bindings/v8/DOMDataStore.h:
33615         (DOMDataStore):
33616         * bindings/v8/V8DOMMap.cpp:
33617         * bindings/v8/V8DOMMap.h:
33618         (NodeWrapperVisitor):
33619         (WebCore):
33620         * bindings/v8/V8DOMWrapper.h:
33621         (V8DOMWrapper):
33622         * bindings/v8/V8GCController.cpp:
33623         (WebCore::V8GCController::majorGCPrologue):
33624         * bindings/v8/custom/V8WebSocketCustom.cpp:
33625         (WebCore::V8WebSocket::constructorCallback):
33626         * bindings/v8/custom/V8XMLHttpRequestConstructor.cpp:
33627         (WebCore::V8XMLHttpRequest::constructorCallback):
33628
33629 2012-10-25  Charles Wei  <charles.wei@torchmobile.com.cn>
33630
33631         [BlackBerry] User Challenged again after browser restart for HTTP/FTP sites already successfully authenticated.
33632         https://bugs.webkit.org/show_bug.cgi?id=100448
33633
33634         Reviewed by George Staikos.
33635
33636         Internally reviewed by Joe Mason.
33637
33638         We didn't check the persistent Credential Storage for Credentials when challenged by the server.
33639
33640         Manual Test: login to ftp://localhost on BlackBerry device, and restart the browser to login again.
33641
33642         * platform/network/blackberry/NetworkJob.cpp:
33643         (WebCore::NetworkJob::sendRequestWithCredentials):
33644
33645 2012-10-25  Joshua Bell  <jsbell@chromium.org>
33646
33647         IndexedDB: Add histogram statistics for backing store errors
33648         https://bugs.webkit.org/show_bug.cgi?id=98465
33649
33650         Reviewed by Adam Barth.
33651
33652         Define a macro for consistent asserting (during development), logging, and recording
33653         internal backing store errors via histograms. Define specific histogram values to
33654         track issues with opening backing stores to gather stats on corruption.
33655
33656         No new tests - just the stats, ma'am, just the stats.
33657
33658         * Modules/indexeddb/IDBLevelDBBackingStore.cpp:
33659         (WebCore):
33660         (WebCore::setUpMetadata):
33661         (WebCore::IDBLevelDBBackingStore::open):
33662         (WebCore::IDBLevelDBBackingStore::getIDBDatabaseMetaData):
33663         (WebCore::IDBLevelDBBackingStore::createIDBDatabaseMetaData):
33664         (WebCore::IDBLevelDBBackingStore::updateIDBDatabaseIntVersion):
33665         (WebCore::IDBLevelDBBackingStore::updateIDBDatabaseMetaData):
33666         (WebCore::deleteRange):
33667         (WebCore::IDBLevelDBBackingStore::getObjectStores):
33668         (WebCore::IDBLevelDBBackingStore::createObjectStore):
33669         (WebCore::IDBLevelDBBackingStore::putObjectStoreRecord):
33670         (WebCore::IDBLevelDBBackingStore::maybeUpdateKeyGeneratorCurrentNumber):
33671         (WebCore::IDBLevelDBBackingStore::forEachObjectStoreRecord):
33672         (WebCore::IDBLevelDBBackingStore::getIndexes):
33673         (WebCore::IDBLevelDBBackingStore::createIndex):
33674         (WebCore::IDBLevelDBBackingStore::deleteIndex):
33675         (WebCore::IDBLevelDBBackingStore::findKeyInIndex):
33676
33677 2012-10-25  Adam Barth  <abarth@webkit.org>
33678
33679         [V8] We can merge ActiveDOMObjectPrologueVisitor with ObjectVisitor
33680         https://bugs.webkit.org/show_bug.cgi?id=100430
33681
33682         Reviewed by Eric Seidel.
33683
33684         There's no reason for these visitors to be separate objects anymore.
33685
33686         * bindings/v8/V8GCController.cpp:
33687         (WebCore::ObjectVisitor::ObjectVisitor):
33688         (WebCore::ObjectVisitor::visitDOMWrapper):
33689         (WebCore::V8GCController::majorGCPrologue):
33690
33691 2012-10-25  Tony Chang  <tony@chromium.org>
33692
33693         Remove unused static methods from DOMTimer.h
33694         https://bugs.webkit.org/show_bug.cgi?id=100427
33695
33696         Reviewed by Kenneth Russell.
33697
33698         Since these values got moved into Settings, these methods are no longer called.
33699
33700         No new tests, removing dead code.
33701
33702         * page/DOMTimer.h:
33703         (DOMTimer): Remove unused getters.
33704
33705 2012-10-25  Leo Yang  <leoyang@rim.com>
33706
33707         [BlackBerry] Infinite redirect loop is not displayed to user
33708         https://bugs.webkit.org/show_bug.cgi?id=100420
33709
33710         Reviewed by George Staikos.
33711
33712         CNN.com is redirecting us infinitely with 302 http code and response body. We catch
33713         it my setting our extended error code as we defined. But we were not trying to notify
33714         error because we have received body. This was wrong. For extended http status code
33715         which is less than 0 we should display our own error page regardless there was data
33716         received from the server or not.
33717
33718         Tested by manually loading CNN.com.
33719
33720         * platform/network/blackberry/NetworkJob.cpp:
33721         (WebCore::NetworkJob::shouldNotifyClientFailed):
33722
33723 2012-10-25  Nico Weber  <thakis@chromium.org>
33724
33725         Flip ImageOrientation coordinate system from lefthanded to righthanded
33726         https://bugs.webkit.org/show_bug.cgi?id=100414
33727
33728         Reviewed by Eric Seidel.
33729
33730         platform/graphics, noteably GraphicsContext uses a right-handed
33731         coordinate system (origin in the top left corner, x growing to the
33732         right, y to the bottom).  ImageOrientation was an outlier from
33733         and used a left-handed coordinate system.  This patch makes
33734         ImageOrientation match the rest of platform/graphics.
33735
33736         This is a pure refactoring and has no observable effects.
33737
33738         * platform/chromium/DragImageChromiumSkia.cpp:
33739         (WebCore::createDragImageFromImage):
33740         * platform/graphics/ImageOrientation.cpp:
33741         (WebCore::ImageOrientation::transformFromDefault):
33742         * platform/graphics/cg/GraphicsContextCG.cpp:
33743         (WebCore::GraphicsContext::drawNativeImage):
33744         * platform/graphics/skia/ImageSkia.cpp:
33745         (WebCore::BitmapImage::draw):
33746         * platform/mac/DragImageMac.mm:
33747         (WebCore::createDragImageFromImage):
33748         * rendering/RenderObject.cpp:
33749         (WebCore::RenderObject::shouldRespectImageOrientation):
33750
33751 2012-10-25  Keishi Hattori  <keishi@webkit.org>
33752
33753         Hide popup while transitioning from the suggestion picker to the calendar picker
33754         https://bugs.webkit.org/show_bug.cgi?id=99537
33755
33756         Reviewed by Kent Tamura.
33757
33758         Right now you can see a squished calendar picker while transitioning
33759         from suggestion picker from calendar picker. This change will hide the
33760         popup before opening the calendar picker.
33761
33762         No new tests.
33763
33764         * Resources/pagepopups/pickerCommon.js: Hiding the window will also trigger a resize event so I created a separate event, didOpenPicker.
33765         (hideWindow): Resize the window to 1x1 because we can't resize to 0x0.
33766         * Resources/pagepopups/suggestionPicker.js:
33767         (SuggestionPicker.prototype.selectEntry): Hide the window first and then open the calendar picker.
33768
33769 2012-10-25  Anders Carlsson  <andersca@apple.com>
33770
33771         Fix build.
33772
33773         * page/mac/EventHandlerMac.mm:
33774         (WebCore::EventHandler::needsKeyboardEventDisambiguationQuirks):
33775
33776 2012-10-25  Anders Carlsson  <andersca@apple.com>
33777
33778         Remove feed and feeds URL scheme workarounds
33779         https://bugs.webkit.org/show_bug.cgi?id=100442
33780
33781         Reviewed by Dan Bernstein.
33782
33783         * dom/DocumentEventQueue.cpp:
33784         (WebCore::DocumentEventQueue::enqueueOrDispatchScrollEvent):
33785         * page/mac/EventHandlerMac.mm:
33786         (WebCore::EventHandler::needsKeyboardEventDisambiguationQuirks):
33787
33788 2012-10-25  Sheriff Bot  <webkit.review.bot@gmail.com>
33789
33790         Unreviewed, rolling out r132514.
33791         http://trac.webkit.org/changeset/132514
33792         https://bugs.webkit.org/show_bug.cgi?id=100440
33793
33794         "Broke chromium content_browsertests AccessibilityAriaMenu
33795         AccessibilityInputRange AccessibilityListMarkers" (Requested
33796         by scheib on #webkit).
33797
33798         * accessibility/AXObjectCache.cpp:
33799         (WebCore::AXObjectCache::getOrCreate):
33800         (WebCore::AXObjectCache::contentChanged):
33801         (WebCore::AXObjectCache::childrenChanged):
33802         (WebCore::AXObjectCache::handleAriaRoleChanged):
33803         * accessibility/AXObjectCache.h:
33804         (AXObjectCache):
33805         (WebCore::AXObjectCache::contentChanged):
33806         * accessibility/AccessibilityObject.cpp:
33807         (WebCore::AccessibilityObject::AccessibilityObject):
33808         * accessibility/AccessibilityObject.h:
33809         (WebCore::AccessibilityObject::contentChanged):
33810         (AccessibilityObject):
33811         * accessibility/AccessibilityRenderObject.cpp:
33812         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
33813         (WebCore::AccessibilityRenderObject::correspondingControlForLabelElement):
33814         (WebCore::AccessibilityRenderObject::contentChanged):
33815         * accessibility/AccessibilityRenderObject.h:
33816         (AccessibilityRenderObject):
33817         * accessibility/AccessibilityScrollView.cpp:
33818         (WebCore::AccessibilityScrollView::isAttachment):
33819         (WebCore::AccessibilityScrollView::widgetForAttachmentView):
33820         (WebCore::AccessibilityScrollView::updateScrollbars):
33821         (WebCore::AccessibilityScrollView::webAreaObject):
33822         (WebCore::AccessibilityScrollView::elementRect):
33823         (WebCore::AccessibilityScrollView::documentFrameView):
33824         (WebCore::AccessibilityScrollView::parentObject):
33825         (WebCore::AccessibilityScrollView::parentObjectIfExists):
33826         (WebCore::AccessibilityScrollView::getScrollableAreaIfScrollable):
33827         (WebCore::AccessibilityScrollView::scrollTo):
33828         * accessibility/AccessibilityScrollView.h:
33829         (WebCore::AccessibilityScrollView::scrollView):
33830         (AccessibilityScrollView):
33831         * accessibility/AccessibilityTable.cpp:
33832         (WebCore::AccessibilityTable::isDataTable):
33833         * accessibility/chromium/AXObjectCacheChromium.cpp:
33834         (WebCore::AXObjectCache::postPlatformNotification):
33835         * dom/Element.cpp:
33836         (WebCore::Element::attributeChanged):
33837         * rendering/RenderBlock.cpp:
33838         (WebCore::RenderBlock::deleteLineBoxTree):
33839         (WebCore::RenderBlock::createAndAppendRootInlineBox):
33840         * rendering/RenderObject.cpp:
33841         (WebCore::RenderObject::styleWillChange):
33842         * rendering/RenderText.cpp:
33843         (WebCore::RenderText::setText):
33844
33845 2012-10-25  Dan Bernstein  <mitz@apple.com>
33846
33847         <rdar://problem/12544626> [cg] RenderBlock::selectionGaps() is extremely slow when there are many floats
33848         https://bugs.webkit.org/show_bug.cgi?id=100413
33849
33850         Reviewed by Anders Carlsson.
33851
33852         RenderBlock::selectionGaps() calls GraphicsContext::clipOut(const IntRect&) for each float.
33853         Sped up the Core Graphics implementation of this function considerably by removing an
33854         unnecessary call to CGContextGetClipBoundingBox.
33855
33856         * platform/graphics/cg/GraphicsContextCG.cpp:
33857         (WebCore::GraphicsContext::clipOut): Changed to use CGRectInfinite rather than the bounding
33858         box of the current clip.
33859
33860 2012-10-25  Tim Horton  <timothy_horton@apple.com>
33861
33862         REGRESSION (132422): Tiles don't move when the Find dialog causes programmatic scrolls
33863         https://bugs.webkit.org/show_bug.cgi?id=100433
33864         <rdar://problem/12575582>
33865
33866         Reviewed by Simon Fraser.
33867
33868         Actually update GraphicsLayer positions from updateMainFrameScrollPosition if
33869         we're doing a programmatic scroll; otherwise programmatic scrolls while scrolling
33870         on the main thread will short-circuit and end up only updating the GraphicsLayer's
33871         notion of its current position, but never synchronizing that to the layer itself.
33872
33873         No new tests, as this is currently untestable.
33874
33875         * page/scrolling/ScrollingCoordinator.cpp:
33876         (WebCore::ScrollingCoordinator::updateMainFrameScrollPosition):
33877
33878 2012-10-25  Simon Fraser  <simon.fraser@apple.com>
33879
33880         Tiled layers are missing content on zooming
33881         https://bugs.webkit.org/show_bug.cgi?id=100422
33882
33883         Reviewed by Beth Dakin.
33884
33885         Tiled layers using TileCaches were missing content after
33886         zooming. TileCache was confused in the presence of scaling;
33887         it unapplies the scale on the layer above the tiles (so the tiles
33888         live in screen space), and computed the tile coverage rect
33889         in these tile coordinates. This worked for the page tile cache,
33890         because its visibleRect was sent in pre-scaled. However, for
33891         tiled layer TileCaches this was wrong.
33892         
33893         Fix by scaling the tile coverage rect by m_scale before
33894         using it to compute which tiles to throw away and bring in.
33895         
33896         To fix the problem of the visibleRect being pre-scaled
33897         for the page tile cache, remove the setting of the visibleRect
33898         in RenderLayerCompositor::frameViewDidScroll(), and rely on 
33899         GraphicsLayerCA::updateVisibleRect() which computes the
33900         visible rect in the correct, layer coordinates.
33901
33902         Test: compositing/tiling/tile-cache-zoomed.html
33903
33904         * platform/graphics/ca/GraphicsLayerCA.cpp:
33905         (WebCore::GraphicsLayerCA::updateVisibleRect): Call setVisibleRect()
33906         for all tile cache layers, not just tiled layer ones, but only do
33907         the visible rect adjustment for those that are not the page tile cache.
33908         * platform/graphics/ca/mac/TileCache.mm:
33909         (WebCore::TileCache::revalidateTiles): Use a coverageRectInTileCoords rect,
33910         which is scaled to be in the same coordinate space as the tile grid.
33911         * rendering/RenderLayerCompositor.cpp:
33912         (WebCore::RenderLayerCompositor::frameViewDidScroll): Remove the code
33913         that sets the setVisibleRect() on the TiledBacking.
33914
33915 2012-10-25  Adam Barth  <abarth@webkit.org>
33916
33917         [V8] ActiveDOMNodes no longer require a separate wrapper map
33918         https://bugs.webkit.org/show_bug.cgi?id=100352
33919
33920         Reviewed by Eric Seidel.
33921
33922         There is no longer any reason to keep a separate DOM wrapper map for
33923         active DOM nodes. We can simply store them in the normal DOM node
33924         wrapper map (which is more efficient because it doesn't use a HashMap).
33925
33926         * bindings/scripts/CodeGeneratorV8.pm:
33927         (GetDomMapName):
33928         * bindings/v8/DOMDataStore.cpp:
33929         (WebCore::DOMDataStore::DOMDataStore):
33930         (WebCore::DOMDataStore::~DOMDataStore):
33931         (WebCore::DOMDataStore::reportMemoryUsage):
33932         * bindings/v8/DOMDataStore.h:
33933         (DOMDataStore):
33934         * bindings/v8/IntrusiveDOMWrapperMap.h:
33935         * bindings/v8/V8DOMMap.cpp:
33936         * bindings/v8/V8DOMMap.h:
33937         (WebCore):
33938         * bindings/v8/V8DOMWrapper.cpp:
33939         * bindings/v8/V8DOMWrapper.h:
33940         (V8DOMWrapper):
33941         (WebCore::V8DOMWrapper::getCachedWrapper):
33942
33943 2012-10-25  Tony Chang  <tony@chromium.org>
33944
33945         Unreviewed, fix the build on Mac.
33946
33947         Putting the getter in the Settings.h caused the global variable to be inlined and needing it to be exported.
33948         Instead, put the implementation in the cpp file.
33949
33950         * page/Settings.cpp:
33951         (WebCore::Settings::defaultMinDOMTimerInterval):
33952         (WebCore):
33953         (WebCore::Settings::defaultDOMTimerAlignmentInterval):
33954         * page/Settings.h:
33955         (Settings):
33956
33957 2012-10-25  Tony Chang  <tony@chromium.org>
33958
33959         Move default DOM Timer values into Settings
33960         https://bugs.webkit.org/show_bug.cgi?id=100405
33961
33962         Reviewed by Kenneth Russell.
33963
33964         Move the global values for defaultMinDOMTimerInterval and defaultDOMTimerAlignmentInterval into
33965         the Settings object. This is more consistent with other global settings and allows us to remove
33966         the setters on the DOMTimer object.
33967
33968         No new tests, this is a refactor.
33969
33970         * page/DOMTimer.cpp: Remove globals.
33971         * page/DOMTimer.h:
33972         (WebCore::DOMTimer::defaultMinTimerInterval): Call through to Settings
33973         (WebCore::DOMTimer::defaultTimerAlignmentInterval): Call through to Settings.
33974         (DOMTimer): Remove setters.
33975         * page/Settings.cpp:
33976         (WebCore::Settings::setDefaultMinDOMTimerInterval): Use a global in Settings.
33977         (WebCore::Settings::setDefaultDOMTimerAlignmentInterval): Use a global in Settings.
33978         * page/Settings.h:
33979         (WebCore::Settings::defaultMinDOMTimerInterval): Inline the getter.
33980         (WebCore::Settings::defaultDOMTimerAlignmentInterval): Inline the getter.
33981         (Settings): Add globals.
33982
33983 2012-10-25  Simon Fraser  <simon.fraser@apple.com>
33984
33985         Report the tile coverage rect in layer coords, and add some tests for tiled backing and zooming
33986         https://bugs.webkit.org/show_bug.cgi?id=100416
33987
33988         Reviewed by Beth Dakin.
33989
33990         The tileCoverageRect is computed in "tile" coordinates, which don't match
33991         the visibleRect coordinates. It's more useful when testing to see the
33992         tile coverage relative to the view bounds, so unapply the scale whem
33993         reporting tile coverage in tests.
33994
33995         Tests: platform/mac/tiled-drawing/tiled-drawing-zoom-scrolled.html
33996                platform/mac/tiled-drawing/tiled-drawing-zoom.html
33997
33998         * platform/graphics/ca/mac/TileCache.h:
33999         * platform/graphics/ca/mac/TileCache.mm:
34000         (WebCore::TileCache::tileCoverageRect):
34001
34002 2012-10-25  Sheriff Bot  <webkit.review.bot@gmail.com>
34003
34004         Unreviewed, rolling out r132269.
34005         http://trac.webkit.org/changeset/132269
34006         https://bugs.webkit.org/show_bug.cgi?id=100412
34007
34008         "Speculative rollout of r132269 in hopes of fixing a
34009         mysterious recalcStyle crasher" (Requested by eseidel on
34010         #webkit).
34011
34012         * rendering/RenderBlock.cpp:
34013         (WebCore::RenderBlock::updateFirstLetter):
34014         * rendering/RenderListBox.h:
34015         * rendering/RenderObjectChildList.cpp:
34016         (WebCore::RenderObjectChildList::updateBeforeAfterContent):
34017
34018 2012-10-25  Stephen White  <senorblanco@chromium.org>
34019
34020         Change ReferenceFilterOperations to reference (own) the data passed to
34021         them.
34022         https://bugs.webkit.org/show_bug.cgi?id=97715
34023
34024         Reviewed by Nate Chapin.
34025
34026         Covered by css3/filters/reference-filter-update-after-remove.html
34027
34028         * css/CachedSVGDocumentReference.h: Added.
34029         (CachedSVGDocumentReference):
34030         New class which holds a CachedResourceHandle<CachedSVGDocument>, but
34031         can be placed in ReferenceFilterOperation's Data.  It also calls
34032         addClient() / removeClient(), in order to keep the CachedSVGDocument
34033         alive until the FilterEffectRenderer can get it.
34034         (WebCore::CachedSVGDocumentReference::CachedSVGDocumentReference):
34035         (WebCore::CachedSVGDocumentReference::~CachedSVGDocumentReference):
34036         (WebCore::CachedSVGDocumentReference::document):
34037         Accessor for the underlying document.
34038         * css/StyleResolver.cpp:
34039         (WebCore::StyleResolver::loadPendingSVGDocuments):
34040         Wrap the CachedSVGDocument handle in a CachedSVGDocumentReference, and
34041         transfer ownership to the ReferenceFilterOperation.
34042         (WebCore::StyleResolver::createFilterOperations):
34043         Same as above.
34044         * platform/graphics/filters/FilterOperation.h:
34045         (Data):
34046         New base class for generic data which can be deleted polymorphically.
34047         (WebCore::FilterOperation::ReferenceFilterOperation::data):
34048         (WebCore::FilterOperation::ReferenceFilterOperation::setData):
34049         Use the above-mentioned Data class, instead of a void *.
34050         (WebCore::FilterOperation::ReferenceFilterOperation::ReferenceFilterOperation):
34051         Don't initialize data to null; OwnPtr will do that for us.
34052         * rendering/FilterEffectRenderer.cpp:
34053         (WebCore::FilterEffectRenderer::buildReferenceFilter):
34054         Extract the cached SVG document from the reference data.
34055         * rendering/RenderLayerFilterInfo.cpp:
34056         (WebCore::RenderLayerFilterInfo::updateReferenceFilterClients):
34057         Extract the cached SVG document from the reference data.
34058
34059 2012-10-25  Simon Fraser  <simon.fraser@apple.com>
34060
34061         Incorrect tile size in the slow scrolling case
34062         https://bugs.webkit.org/show_bug.cgi?id=100411
34063
34064         Reviewed by Beth Dakin.
34065
34066         If we're in slow scrolling mode, we don't want to inflate the
34067         coverage rect based on scrollability. This ensures that the few
34068         big tiles we create have the correct size.
34069
34070         * platform/graphics/ca/mac/TileCache.mm:
34071         (WebCore::TileCache::computeTileCoverageRect):
34072
34073 2012-10-25  Nico Weber  <thakis@chromium.org>
34074
34075         Move ImageOrientation transform back in CG space (lower-left origin), adapt the skia code to work with that, turn on feature for chromium
34076         https://bugs.webkit.org/show_bug.cgi?id=100401
34077
34078         Reviewed by Eric Seidel.
34079
34080         This is an alternative fix for the regression caused by r132384 / bug
34081         100179. The bug exists because different pieces of code didn't agree
34082         which space the transformation returned by ImageOrientation was in.
34083
34084         r132384 moved it from CG coordinates to skia coordinates, but didn't
34085         do it completetely. This CL reverts this part of r132384 so that the
34086         transformation is in CG coordinates again, and adapts the skia code to
34087         work in that space.
34088
34089         Alternatively, https://bugs.webkit.org/show_bug.cgi?id=100319 woudl
34090         make the cg code work with the transform in skia coordinates.
34091
34092         Covered by fast/images/exif-orientation.html
34093
34094         * platform/chromium/DragImageChromiumSkia.cpp:
34095         (WebCore::createDragImageFromImage):
34096         * platform/graphics/ImageOrientation.cpp:
34097         (WebCore::ImageOrientation::transformFromDefault):
34098         * platform/graphics/ImageOrientation.h:
34099         (WebCore):
34100         (WebCore::ImageOrientation::usesWidthAsHeight):
34101         (WebCore::ImageOrientation::fromEXIFValue):
34102         (ImageOrientation):
34103         * platform/graphics/cg/GraphicsContextCG.cpp:
34104         (WebCore::GraphicsContext::drawNativeImage):
34105         * platform/graphics/skia/ImageSkia.cpp:
34106         (WebCore::BitmapImage::draw):
34107         * platform/mac/DragImageMac.mm:
34108         (WebCore::createDragImageFromImage):
34109         * rendering/RenderObject.cpp:
34110         (WebCore::RenderObject::shouldRespectImageOrientation):
34111
34112 2012-10-25  Simon Fraser  <simon.fraser@apple.com>
34113
34114         Log the tile cache tile size in test output
34115         https://bugs.webkit.org/show_bug.cgi?id=100409
34116
34117         Reviewed by Beth Dakin.
34118
34119         When dumping tile cache information in tests, also dump the tile size.
34120
34121         * platform/graphics/TiledBacking.h:
34122         * platform/graphics/ca/GraphicsLayerCA.cpp:
34123         (WebCore::GraphicsLayerCA::dumpAdditionalProperties):
34124         * platform/graphics/ca/mac/TileCache.h:
34125
34126 2012-10-25  Arnaud Renevier  <a.renevier@sisa.samsung.com>
34127
34128         do not multiply/demultiply colors when alpha is 255
34129         https://bugs.webkit.org/show_bug.cgi?id=89246
34130
34131         Reviewed by Kenneth Rohde Christiansen.
34132
34133         Do not use colorFromPremultipliedARGB in getImageData nor
34134         premultipliedARGBFromColor in putByteArray. Avoiding object creation
34135         and function call make canvas.getImageData about 10% faster and
34136         canvas.putImageData about 30% faster.
34137
34138         Also, we avoid multiplication/demultiplication computation when alpha
34139         is 255. Result is the same, but when there is no transparency,
34140         canvas.getImageData is about 4x faster, and canvas.putImageData is
34141         about 2x faster.
34142
34143         No new tests. No change in behavior.
34144
34145         * platform/graphics/cairo/ImageBufferCairo.cpp:
34146         (WebCore::getImageData):
34147         (WebCore::ImageBuffer::putByteArray):
34148
34149 2012-10-25  Nate Chapin  <japhet@chromium.org>
34150
34151         Add a main resource type to the memory cache
34152         https://bugs.webkit.org/show_bug.cgi?id=99864
34153
34154         Reviewed by Adam Barth.
34155
34156         No new tests, no functionality change.
34157
34158         * inspector/InspectorPageAgent.cpp:
34159         (WebCore::hasTextContent):
34160         (WebCore::InspectorPageAgent::cachedResourceType):
34161         * loader/SubresourceLoader.cpp:
34162         (WebCore::SubresourceLoader::willSendRequest):
34163         (WebCore::SubresourceLoader::didReceiveResponse):
34164         (WebCore::SubresourceLoader::didFail):
34165         * loader/cache/CachedRawResource.cpp:
34166         (WebCore::CachedRawResource::CachedRawResource):
34167         (WebCore::CachedRawResource::addAdditionalRequestHeaders):
34168         (WebCore):
34169         (WebCore::CachedRawResource::setShouldBufferData):
34170         (WebCore::CachedRawResource::loader):
34171         (WebCore::CachedRawResource::clear):
34172         * loader/cache/CachedRawResource.h:
34173         (WebCore):
34174         (CachedRawResource):
34175         * loader/cache/CachedResource.cpp:
34176         (WebCore::defaultPriorityForResourceType):
34177         (WebCore::cachedResourceTypeToTargetType):
34178         (WebCore::CachedResource::updateResourceRequest):
34179         (WebCore):
34180         * loader/cache/CachedResource.h:
34181         (WebCore::CachedResource::setResourceError):
34182         (WebCore::CachedResource::resourceError):
34183         (CachedResource):
34184         (WebCore::CachedResource::ignoreForRequestCount):
34185         * loader/cache/CachedResourceLoader.cpp:
34186         (WebCore::createResource):
34187         (WebCore::CachedResourceLoader::requestRawResource):
34188         (WebCore::CachedResourceLoader::checkInsecureContent):
34189         (WebCore::CachedResourceLoader::canRequest):
34190         (WebCore::CachedResourceLoader::determineRevalidationPolicy):
34191         * loader/cache/CachedResourceLoader.h:
34192         (CachedResourceLoader):
34193         * platform/network/ResourceLoadPriority.h:
34194         * platform/network/cf/ResourceRequestCFNet.h:
34195         (WebCore::toResourceLoadPriority):
34196         (WebCore::toHTTPPipeliningPriority):
34197
34198 2012-10-25  Ojan Vafai  <ojan@chromium.org>
34199
34200         [V8] Add histograms to measure V8 work done during window close and navigation
34201         https://bugs.webkit.org/show_bug.cgi?id=100358
34202
34203         Reviewed by Adam Barth.
34204
34205         * bindings/v8/ScriptController.cpp:
34206         (WebCore::ScriptController::clearForClose):
34207         (WebCore::ScriptController::clearWindowShell):
34208
34209 2012-10-25  Antti Koivisto  <antti@apple.com>
34210
34211         Avoid unnecessary style recalcs on id attribute mutation.
34212         https://bugs.webkit.org/show_bug.cgi?id=100395
34213
34214         Reviewed by Andreas Kling.
34215
34216         There is no need to invalidate element style on id attribute change if neither the old nor the new id were 
34217         mentioned in any stylesheet. This is similar to the optimization we already have for class attributes.
34218         
34219         Recalculating element style is expensive. It seems id attribute mutation is often used in scripts for purposes other than styling. 
34220
34221         * css/StyleResolver.cpp:
34222         (WebCore::StyleResolver::hasSelectorForId):
34223         (WebCore):
34224         * css/StyleResolver.h:
34225         * dom/Element.cpp:
34226         (WebCore::makeIdForStyleResolution):
34227         (WebCore):
34228         (WebCore::Element::attributeChanged):
34229
34230 2012-10-25  Dominic Mazzoni  <dmazzoni@google.com>
34231
34232         AX: Notification should be sent when accessibilityIsIgnored changes
34233         https://bugs.webkit.org/show_bug.cgi?id=99547
34234
34235         Reviewed by Chris Fleizach.
34236
34237         Adds a new flag in AccessibilityObject that keeps track of the most recent
34238         value of accessibilityIsIgnored(). After certain events such as an ARIA
34239         attribute change or content change, checks the new value of
34240         accessibilityIsIgnored() and posts a "children changed" notification on the
34241         parent node if it changed, making sure the parent recomputes its vector of
34242         (unignored) children.
34243
34244         Also moves handling of attribute changes to AXObjectCache, and sends
34245         notifications for some attribute changes that were previously silent. On
34246         Chromium, all changes to an accessibility object's attributes should
34247         result in some notification.
34248
34249         Some tests would have broken because an AccessibilityScrollView was created
34250         and holding a reference to a ScrollView for an iframe after it was deleted,
34251         so this change switches AccessibilityScrollView to hold a weak reference
34252         to ScrollView instead.
34253
34254         Tests: platform/chromium/accessibility/is-ignored-change-sends-notification.html
34255                platform/chromium/accessibility/other-aria-attribute-change-sends-notification.html
34256                platform/chromium/accessibility/text-change-notification.html
34257
34258         * accessibility/AXObjectCache.cpp:
34259         (WebCore::AXObjectCache::focusedUIElementForPage):
34260         (WebCore::AXObjectCache::getOrCreate):
34261         (WebCore::AXObjectCache::textChanged):
34262         (WebCore):
34263         (WebCore::AXObjectCache::childrenChanged):
34264         (WebCore::AXObjectCache::handleAriaRoleChanged):
34265         (WebCore::AXObjectCache::handleAttributeChanged):
34266         (WebCore::AXObjectCache::labelChanged):
34267         (WebCore::AXObjectCache::recomputeIsIgnored):
34268         * accessibility/AXObjectCache.h:
34269         (AXObjectCache):
34270         (WebCore::AXObjectCache::childrenChanged):
34271         (WebCore::AXObjectCache::textChanged):
34272         (WebCore::AXObjectCache::handleAttributeChanged):
34273         (WebCore::AXObjectCache::recomputeIsIgnored):
34274         * accessibility/AccessibilityNodeObject.cpp:
34275         (WebCore::AccessibilityNodeObject::insertChild):
34276         * accessibility/AccessibilityObject.cpp:
34277         (WebCore::AccessibilityObject::AccessibilityObject):
34278         (WebCore::AccessibilityObject::cachedIsIgnoredValue):
34279         (WebCore):
34280         (WebCore::AccessibilityObject::setCachedIsIgnoredValue):
34281         (WebCore::AccessibilityObject::notifyIfIgnoredValueChanged):
34282         * accessibility/AccessibilityObject.h:
34283         (WebCore::AccessibilityObject::textChanged):
34284         (AccessibilityObject):
34285         * accessibility/AccessibilityRenderObject.cpp:
34286         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
34287         (WebCore::AccessibilityRenderObject::correspondingControlForLabelElement):
34288         (WebCore::AccessibilityRenderObject::textChanged):
34289         (WebCore::AccessibilityRenderObject::addHiddenChildren):
34290         (WebCore::AccessibilityRenderObject::addChildren):
34291         * accessibility/AccessibilityRenderObject.h:
34292         (AccessibilityRenderObject):
34293         * accessibility/AccessibilityScrollView.cpp:
34294         (WebCore::AccessibilityScrollView::~AccessibilityScrollView):
34295         (WebCore):
34296         (WebCore::AccessibilityScrollView::detach):
34297         (WebCore::AccessibilityScrollView::isAttachment):
34298         (WebCore::AccessibilityScrollView::widgetForAttachmentView):
34299         (WebCore::AccessibilityScrollView::updateScrollbars):
34300         (WebCore::AccessibilityScrollView::webAreaObject):
34301         (WebCore::AccessibilityScrollView::elementRect):
34302         (WebCore::AccessibilityScrollView::documentFrameView):
34303         (WebCore::AccessibilityScrollView::parentObject):
34304         (WebCore::AccessibilityScrollView::parentObjectIfExists):
34305         (WebCore::AccessibilityScrollView::getScrollableAreaIfScrollable):
34306         (WebCore::AccessibilityScrollView::scrollTo):
34307         * accessibility/AccessibilityScrollView.h:
34308         (WebCore::AccessibilityScrollView::scrollView):
34309         (AccessibilityScrollView):
34310         * accessibility/AccessibilityTable.cpp:
34311         (WebCore::AccessibilityTable::isDataTable):
34312         * accessibility/chromium/AXObjectCacheChromium.cpp:
34313         (WebCore::AXObjectCache::postPlatformNotification):
34314         * dom/Element.cpp:
34315         (WebCore::Element::attributeChanged):
34316         * rendering/RenderBlock.cpp:
34317         (WebCore::RenderBlock::deleteLineBoxTree):
34318         (WebCore::RenderBlock::createAndAppendRootInlineBox):
34319         * rendering/RenderObject.cpp:
34320         (WebCore::RenderObject::styleWillChange):
34321         * rendering/RenderText.cpp:
34322         (WebCore::RenderText::setText):
34323
34324 2012-10-25  Dominik Röttsches  <dominik.rottsches@intel.com>
34325
34326         Conditionalize XHR timeout support
34327         https://bugs.webkit.org/show_bug.cgi?id=100356
34328
34329         Reviewed by Adam Barth.
34330
34331         Adding feature for XHR_TIMEOUT to disable it on ports that don't have
34332         network backend support for setTimeoutInterval.
34333
34334         No new tests, covered by http/tests/xmlhttprequest/timeout/*
34335
34336         * Configurations/FeatureDefines.xcconfig: Default ON on mac.
34337         * GNUmakefile.am:
34338         * GNUmakefile.features.am:
34339           Autotools support for the flag.
34340         * xml/XMLHttpRequest.cpp: #if ENABLE(XHR_TIMEOUT) wrapping
34341         (WebCore::XMLHttpRequest::XMLHttpRequest):
34342         (WebCore):
34343         (WebCore::XMLHttpRequest::open):
34344         (WebCore::XMLHttpRequest::createRequest):
34345         (WebCore::XMLHttpRequest::didFail):
34346         * xml/XMLHttpRequest.h: #if ENABLE(XHR_TIMEOUT) wrapping
34347         (XMLHttpRequest):
34348         * xml/XMLHttpRequest.idl: Conditional properties timeout and ontimeout (event handler).
34349
34350 2012-10-25  Tom Sepez  <tsepez@chromium.org>
34351
34352         XSSAuditor must replace form action with about:blank when reflected action detected.
34353         https://bugs.webkit.org/show_bug.cgi?id=100280
34354
34355         Reviewed by Daniel Bates.
34356
34357         Changes empty string form-action replacement to about:blank.
34358         Existing form-action.html test modified to check this case.
34359         
34360         * html/parser/XSSAuditor.cpp:
34361         (WebCore::XSSAuditor::filterFormToken):
34362
34363 2012-10-25  Kevin Ellis  <kevers@chromium.org>
34364
34365         Touch adjustment snaps to wrong target at a plugin boundary.
34366         https://bugs.webkit.org/show_bug.cgi?id=99938
34367
34368         Reviewed by Antonio Gomes.
34369
34370         Inidcate that an <embed> element can respond to
34371         mouse click events, since mouse events are forwarded
34372         to the plugin.  Fixes touch adjustment at a plugin
34373         boundary.  Prior to the patch a clickable element 
34374         adjacent to the plugin would capture synthetic mouse
34375         events from tap gestures that spanned the plugin
34376         boundary.
34377
34378         Test: touchadjustment/plugin.html
34379
34380         * html/HTMLEmbedElement.cpp:
34381         (WebCore::HTMLEmbedElement::willRespondToMouseClickEvents):
34382         (WebCore):
34383         * html/HTMLEmbedElement.h:
34384
34385 2012-10-25  Ojan Vafai  <ojan@chromium.org>
34386
34387         Get rid of ScriptController::clearForNavigation
34388         https://bugs.webkit.org/show_bug.cgi?id=100390
34389
34390         Reviewed by Adam Barth.
34391
34392         Get rid of clearForNavigation and change resetIsolatedWorlds
34393         to reset so that it can also do the hintForCollectGarbage call.
34394         No new tests. No behavior change.
34395
34396         * bindings/v8/ScriptController.cpp:
34397         (WebCore::ScriptController::reset):
34398         (WebCore::ScriptController::clearForClose):
34399         (WebCore::ScriptController::clearWindowShell):
34400         * bindings/v8/ScriptController.h:
34401         (ScriptController):
34402
34403 2012-10-25  Simon Fraser  <simon.fraser@apple.com>
34404
34405         r132427 changed the tiling behavior of tiled layer TileCaches as well as the page tile cache
34406         https://bugs.webkit.org/show_bug.cgi?id=100323
34407
34408         Reviewed by Anders Carlsson.
34409
34410         r132427 assumed that TileCaches were only used for the page, and changed the tile
34411         size behavior of all non-page TileCaches.
34412         
34413         Fix by giving TiledBacking a new 'CoverageForSlowScrolling' flag which
34414         affects the tile size behavior.
34415         
34416         Consolidated the two places that set TileCoverage into one, and in the process
34417         reduced FrameView's direct communication with TiledBacking.
34418
34419         No new tests because we can't test tile size via tests.
34420
34421         * page/FrameView.cpp:
34422         (WebCore::FrameView::didMoveOnscreen): Rely on RenderLayerCompositor to
34423         call setIsInWindow() on the main page tile cache.
34424         (WebCore::FrameView::willMoveOffscreen): Ditto.
34425         (WebCore::FrameView::performPostLayoutTasks): Rather than explicitly tell
34426         the TiledBacking that it should do stuff, just tell the compositor that
34427         layout happened.
34428         * platform/graphics/TiledBacking.h: New CoverageForSlowScrolling flag.
34429         * platform/graphics/ca/mac/TileCache.mm:
34430         (WebCore::TileCache::tileSizeForCoverageRect): Only use one big tile
34431         if the CoverageForSlowScrolling flag is set.
34432         * rendering/RenderLayerBacking.cpp:
34433         (WebCore::RenderLayerBacking::RenderLayerBacking): layer->isRootLayer()
34434         is equivalent to renderer()->isRenderView() and clearer.
34435         (WebCore::RenderLayerBacking::tiledBacking): Call adjustTileCacheCoverage().
34436         It would be nice to move the rest of this TiledBacking code from here somehow.
34437         (WebCore::RenderLayerBacking::adjustTileCacheCoverage): Update the TileCoverage
34438         flags, taking into account horizontal and vertical scrollability independently,
34439         and whether we're in slow scrolling mode.
34440         * rendering/RenderLayerBacking.h:
34441         (RenderLayerBacking):
34442         * rendering/RenderLayerCompositor.cpp:
34443         (WebCore::RenderLayerCompositor::frameViewDidLayout): Have the page
34444         tiled backing update it's coverage flags.
34445         (WebCore::RenderLayerCompositor::pageTiledBacking): Utility function.
34446         (WebCore::RenderLayerCompositor::didMoveOnscreen): Moved from FrameView.
34447         (WebCore::RenderLayerCompositor::willMoveOffscreen): Ditto.
34448         * rendering/RenderLayerCompositor.h:
34449         (RenderLayerCompositor):
34450
34451 2012-10-25  Elliott Sprehn  <esprehn@chromium.org>
34452
34453         Everything that sets RenderObject::m_style should go through setStyleInternal
34454         https://bugs.webkit.org/show_bug.cgi?id=100338
34455
34456         Reviewed by Ojan Vafai.
34457
34458         Whenever we set m_style in RenderObject go through setStyleInternal and make
34459         it inline. This gives a common place to put printfs and makes the code cleaner.
34460
34461         No new tests, just a refactor.
34462
34463         * rendering/RenderObject.cpp:
34464         (WebCore::RenderObject::createObject):
34465         (WebCore::RenderObject::setStyle):
34466         * rendering/RenderObject.h:
34467         (WebCore::RenderObject::setStyleInternal):
34468
34469 2012-10-25  Brady Eidson  <beidson@apple.com>
34470
34471         Allow LoaderStrategy to override the ResourceLoadScheduler
34472         https://bugs.webkit.org/show_bug.cgi?id=100355
34473
34474         Reviewed by Anders Carlsson.
34475
34476         Allow LoaderStrategy to override the implementation of the ResourceLoadScheduler.
34477         Add a default implementation that just returns the current ResourceLoadScheduler.
34478
34479         No new tests (No behavior change).
34480
34481         Project file stuff:
34482         * CMakeLists.txt:
34483         * GNUmakefile.list.am:
34484         * Target.pri:
34485         * WebCore.exp.in:
34486         * WebCore.gypi:
34487         * WebCore.vcproj/WebCore.vcproj:
34488         * WebCore.xcodeproj/project.pbxproj:
34489
34490         "Virtualize" ResourceLoadScheduler to expose build issues in preparation for future virtualization:
34491         * loader/ResourceLoadScheduler.cpp:
34492         (WebCore::ResourceLoadScheduler::~ResourceLoadScheduler):
34493         * loader/ResourceLoadScheduler.h:
34494         (ResourceLoadScheduler):
34495
34496         Add the new method plus a default implementation:
34497          * loader/LoaderStrategy.cpp: 
34498         (WebCore::LoaderStrategy::resourceLoadScheduler):
34499         * loader/LoaderStrategy.h:
34500
34501         When strategies are enabled, use the LoaderStrategy for this:
34502         * dom/ContainerNode.cpp:
34503         (WebCore::ContainerNode::suspendPostAttachCallbacks):
34504         (WebCore::ContainerNode::resumePostAttachCallbacks):
34505
34506         * loader/MainResourceLoader.cpp:
34507         (WebCore::MainResourceLoader::loadNow):
34508
34509         * loader/ResourceLoader.cpp:
34510         (WebCore::ResourceLoader::releaseResources):
34511         (WebCore::ResourceLoader::willSendRequest):
34512
34513         * loader/cache/CachedResource.cpp:
34514         (WebCore::CachedResource::load):
34515
34516         * loader/cache/CachedResourceLoader.cpp:
34517         (WebCore::CachedResourceLoader::performPostLoadActions):
34518
34519 2012-10-25  Yury Semikhatsky  <yurys@chromium.org>
34520
34521         Web Inspector: inspector tests failing after r132454
34522         https://bugs.webkit.org/show_bug.cgi?id=100381
34523
34524         Reviewed by Pavel Feldman.
34525
34526         Added implementation for DOMNodeWrapperMap::reportMemoryUsage method,
34527         otherwise no actual pointer is reported which breaks instrumentation.
34528
34529         * bindings/v8/IntrusiveDOMWrapperMap.h:
34530
34531 2012-10-25  Dominik Röttsches  <dominik.rottsches@intel.com>
34532
34533         Init timeout flag in ResourceErrorCF
34534         https://bugs.webkit.org/show_bug.cgi?id=100349
34535
34536         Reviewed by Alexey Proskuryakov.
34537
34538         Initialize the timeout property to true if the network error was a timeout error.
34539         This is a speculative fix for the XHR timeout test cases failing on Apple Win -
34540         I can't verify this on a local machine.
34541
34542         No new tests, covered by
34543         LayoutTests/http/tests/xmlhttprequest/timeout/*
34544
34545         * platform/network/cf/ResourceErrorCF.cpp:
34546         (WebCore::ResourceError::ResourceError): Init m_timeout from error code.
34547
34548 2012-10-25  Kenneth Rohde Christiansen  <kenneth@webkit.org>
34549
34550         'resolution' MQ: Printing should use use high resolution images when available
34551         https://bugs.webkit.org/show_bug.cgi?id=100382
34552
34553         Reviewed by Antti Koivisto.
34554
34555         Special case print to not use the dpi of the screen, but one of 300.
34556
34557         Updated the resolution media query test to cover this.
34558
34559         * css/MediaQueryEvaluator.cpp:
34560         (WebCore::resolutionMediaFeatureEval): Update compared decimal points
34561         to three, due to 300 / 96 being equal to 3.125.
34562
34563 2012-10-25  Kinuko Yasuda  <kinuko@chromium.org>
34564
34565         [chromium] External FileSystem should use the root path returned by requestFileSystem
34566         https://bugs.webkit.org/show_bug.cgi?id=100372
34567
34568         Reviewed by Kentaro Hara.
34569
34570         External FileSystem should use the root path returned by
34571         requestFileSystem as other type is doing. Current implementation
34572         completely ignore the returned path.
34573
34574         New tests are to be added in chromium (as the type is only available in chromeos and chrome extensions)
34575
34576         * Modules/filesystem/chromium/DOMFileSystemChromium.cpp:
34577         (WebCore::DOMFileSystemBase::createFileSystemURL):
34578
34579 2012-10-25  Kevin Ellis  <kevers@chromium.org>
34580
34581         Can't easily position the cursor on an empty line in a textarea with touch if touch adjustment is enabled
34582         https://bugs.webkit.org/show_bug.cgi?id=97576
34583
34584         Reviewed by Antonio Gomes.
34585
34586         Consolidate touch adjustment candidates that are
34587         editable.  Adjustment becomes coarse being based
34588         on the bounds of the outermost editable element.
34589         This fix allows tap positioning of the text caret
34590         on a blank line immediately above or below another
34591         element.
34592
34593         Test: touchadjustment/editable-content.html
34594
34595         * page/TouchAdjustment.cpp:
34596         (WebCore::TouchAdjustment::compileSubtargetList):
34597         (WebCore::TouchAdjustment::hybridDistanceFunction):
34598
34599 2012-10-25  Yury Semikhatsky  <yurys@chromium.org>
34600
34601         Memory instrumentation: add reportMemoryUsage to ImageObserver interface
34602         https://bugs.webkit.org/show_bug.cgi?id=100091
34603
34604         Reviewed by Pavel Feldman.
34605
34606         Added reportMemoryUsage method to ImageObserver to make sure it is reported as
34607         appropriate descendant(with pointer adjusted due to offsets added by inheritance)
34608         rather than as a standalone memory block.
34609
34610         * platform/graphics/ImageObserver.h:
34611         (ImageObserver):
34612
34613 2012-10-25  Alexander Pavlov  <apavlov@chromium.org>
34614
34615         Web Inspector: [Overrides] Add latitude and longitude labels for the geolocation fields
34616         https://bugs.webkit.org/show_bug.cgi?id=100375
34617
34618         Reviewed by Yury Semikhatsky.
34619
34620         No new tests, a UI change.
34621
34622         * English.lproj/localizedStrings.js:
34623         * inspector/front-end/SettingsScreen.js:
34624         (WebInspector.UserAgentSettingsTab.prototype._createGeolocationOverrideElement):
34625
34626 2012-10-25  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
34627
34628         Add setMediaTypeOverride to window.internals.settings
34629         https://bugs.webkit.org/show_bug.cgi?id=100249
34630
34631         Reviewed by Kenneth Rohde Christiansen.
34632
34633         Added setMediaTypeOverride to window.internals.settings.
34634
34635         Test: fast/media/print-restores-previous-mediatype.html
34636
34637         * WebCore.exp.in: Exported WebCore::Settings::setMediaTypeOverride(WTF::String const&) for MAC.
34638         * page/Settings.cpp:
34639         (WebCore::Settings::Settings):
34640         (WebCore::Settings::setMediaTypeOverride):
34641         (WebCore):
34642         * page/Settings.h:
34643         (Settings):
34644         (WebCore::Settings::mediaTypeOverride):
34645         * testing/InternalSettings.cpp:
34646         (WebCore::InternalSettings::Backup::Backup):
34647         (WebCore::InternalSettings::Backup::restoreTo):
34648         (WebCore::InternalSettings::setMediaTypeOverride):
34649         (WebCore):
34650         * testing/InternalSettings.h:
34651         (Backup):
34652         (InternalSettings):
34653         * testing/InternalSettings.idl:
34654
34655 2012-10-22  Mikhail Naganov  <mnaganov@chromium.org>
34656
34657         [Chromium] Add supportMultipleWindows setting, needed for Android
34658         https://bugs.webkit.org/show_bug.cgi?id=99716
34659
34660         Reviewed by Adam Barth.
34661
34662         Add supportMultipleWindows settings for reusing the same view when
34663         opening popups. This is required for emulating the behavior of
34664         Android WebView. Adding into WebCore, as other ports might want to
34665         use this setting in the future.
34666
34667         Tests: fast/dom/HTMLAnchorElement/anchor-no-multiple-windows.html
34668                fast/dom/Window/window-open-no-multiple-windows.html
34669                fast/forms/post-popup-no-multiple-windows.html
34670
34671         * loader/FrameLoader.cpp:
34672         (WebCore::createWindow):
34673         * page/ContextMenuController.cpp:
34674         (WebCore::openNewWindow):
34675         * page/Settings.cpp:
34676         (WebCore::Settings::Settings):
34677         (WebCore::Settings::setSupportsMultipleWindows):
34678         (WebCore):
34679         * page/Settings.h:
34680         (Settings):
34681         (WebCore::Settings::supportsMultipleWindows):
34682
34683 2012-10-25  Alexander Pavlov  <apavlov@chromium.org>
34684
34685         Unreviewed, fix Web Inspector frontend compilability
34686
34687         * inspector/front-end/ElementsTreeOutline.js:
34688         (WebInspector.ElementsTreeOutline.prototype._ondragstart):
34689         * inspector/front-end/StylesSidebarPane.js:
34690         (WebInspector.StylePropertiesSection.prototype._handleEmptySpaceClick):
34691         (WebInspector.StylePropertyTreeElement.prototype):
34692
34693 2012-10-23  Alexander Pavlov  <apavlov@chromium.org>
34694
34695         Web Inspector: Drag and drop property value from Inspector is not working as expected
34696         https://bugs.webkit.org/show_bug.cgi?id=100040
34697
34698         Reviewed by Vsevolod Vlasov.
34699
34700         Do not start a custom drag for a tree element if there is a non-collapsed selection in the Inspector.
34701
34702         * inspector/front-end/ElementsTreeOutline.js:
34703         (WebInspector.ElementsTreeOutline.prototype._ondragstart):
34704
34705 2012-10-25  Ilya Tikhonovsky  <loislo@chromium.org>
34706
34707         Web Inspector: NMI instrument InspectorDebuggerAgent. It uses a lot of memory on heavy js sites because it keeps all the scripts in a map.
34708         https://bugs.webkit.org/show_bug.cgi?id=100340
34709
34710         Reviewed by Yury Semikhatsky.
34711
34712         * dom/WebCoreMemoryInstrumentation.cpp:
34713         (WebCore):
34714         * dom/WebCoreMemoryInstrumentation.h:
34715         (WebCoreMemoryTypes):
34716         * inspector/InspectorDebuggerAgent.cpp:
34717         (WebCore::InspectorDebuggerAgent::reportMemoryUsage):
34718         (WebCore):
34719         (WebCore::ScriptDebugListener::Script::reportMemoryUsage):
34720         * inspector/InspectorDebuggerAgent.h:
34721         (InspectorDebuggerAgent):
34722         * inspector/ScriptDebugListener.h:
34723         (Script):
34724
34725 2012-10-25  Adam Barth  <abarth@webkit.org>
34726
34727         [V8] We can handle ActiveDOMNodes and DOMNodes in the same GC visitor
34728         https://bugs.webkit.org/show_bug.cgi?id=100351
34729
34730         Reviewed by Eric Seidel.
34731
34732         There is no reason to handle active DOM nodes in a separate pass from
34733         regular DOM nodes anymore.
34734
34735         * bindings/v8/V8DOMMap.cpp:
34736         * bindings/v8/V8DOMMap.h:
34737         (WebCore):
34738         * bindings/v8/V8GCController.cpp:
34739         (WebCore::ActiveDOMObjectPrologueVisitor::visitDOMWrapper):
34740         (WebCore::NodeVisitor::NodeVisitor):
34741         (NodeVisitor):
34742         (WebCore::NodeVisitor::visitNodeWrapper):
34743         (WebCore::V8GCController::majorGCPrologue):
34744
34745 2012-10-25  Alexander Pavlov  <apavlov@chromium.org>
34746
34747         Web Inspector: Improper out-of-order call on a rule that is being removed from the stylesheet.
34748         https://bugs.webkit.org/show_bug.cgi?id=100357
34749
34750         Reviewed by Vsevolod Vlasov.
34751
34752         * inspector/InspectorStyleSheet.cpp:
34753         (WebCore::InspectorStyleSheet::deleteRule):
34754
34755 2012-10-25  Adam Barth  <abarth@webkit.org>
34756
34757         [V8] DOMDataStoreHandle serves no purpose and can be removed
34758         https://bugs.webkit.org/show_bug.cgi?id=100333
34759
34760         Reviewed by Eric Seidel.
34761
34762         After https://bugs.webkit.org/show_bug.cgi?id=100316,
34763         DOMDataStoreHandle is just a glorified OwnPtr.
34764
34765         * bindings/v8/DOMWrapperWorld.h:
34766         (WebCore::DOMWrapperWorld::domDataStore):
34767         (DOMWrapperWorld):
34768         (WebCore::DOMWrapperWorld::DOMWrapperWorld):
34769         * bindings/v8/V8DOMMap.cpp:
34770         * bindings/v8/V8DOMMap.h:
34771
34772 2012-10-25  Elliott Sprehn  <esprehn@chromium.org>
34773
34774         Remove dead Node::isBlockFlowOrBlockTable
34775         https://bugs.webkit.org/show_bug.cgi?id=100336
34776
34777         Reviewed by Eric Seidel.
34778
34779         Nothing uses Node::isBlockFlowOrBlockTable anymore so remove it.
34780
34781         No new tests needed, just removing dead code.
34782
34783         * dom/Node.cpp:
34784         * dom/Node.h:
34785         (Node):
34786
34787 2012-10-25  Eugene Klyuchnikov  <eustas.bug@gmail.com>
34788
34789         Web Inspector: Fix "check-inspector-strings" script and fix localized strings.
34790         https://bugs.webkit.org/show_bug.cgi?id=100090
34791
34792         Reviewed by Vsevolod Vlasov.
34793
34794         Fixed localized strings table.
34795
34796         * English.lproj/localizedStrings.js: Added missing, removed orhans.
34797         * inspector/front-end/CSSNamedFlowView.js: Removed tailing whitespaces.
34798         * inspector/front-end/NativeMemorySnapshotView.js:
34799         Removed double localization.
34800
34801 2012-10-25  Adam Barth  <abarth@webkit.org>
34802
34803         [V8] We can merge DOMDataStore, ScopedDOMDataStore, and StaticDOMDataStore into one class
34804         https://bugs.webkit.org/show_bug.cgi?id=100316
34805
34806         Reviewed by Eric Seidel.
34807
34808         Prior to this patch, DOMDataStore had two subclasses,
34809         ScopedDOMDataStore and StaticDOMDataStore, which used slighly different
34810         wrapper map base classes and had different lifetimes. This patch
34811         unifies all these classes into DOMDataStore itself. This makes this
34812         code much more straightforward.
34813
34814         * WebCore.gypi:
34815         * bindings/v8/DOMDataStore.cpp:
34816         (WebCore::DOMDataStore::DOMDataStore):
34817         (WebCore::DOMDataStore::~DOMDataStore):
34818         (WebCore::DOMDataStore::current):
34819         (WebCore::DOMDataStore::reportMemoryUsage):
34820         * bindings/v8/DOMDataStore.h:
34821         (DOMDataStore):
34822         (WebCore::DOMDataStore::domNodeMap):
34823         (WebCore::DOMDataStore::activeDomNodeMap):
34824         (WebCore::DOMDataStore::domObjectMap):
34825         (WebCore::DOMDataStore::activeDomObjectMap):
34826         * bindings/v8/ScopedDOMDataStore.cpp: Removed.
34827         * bindings/v8/ScopedDOMDataStore.h: Removed.
34828         * bindings/v8/SerializedScriptValue.cpp:
34829         (WebCore::neuterBinding):
34830         * bindings/v8/StaticDOMDataStore.cpp: Removed.
34831         * bindings/v8/StaticDOMDataStore.h: Removed.
34832         * bindings/v8/V8DOMMap.cpp:
34833         (WebCore::DOMDataStoreHandle::DOMDataStoreHandle):
34834         (WebCore::DOMDataStoreHandle::~DOMDataStoreHandle):
34835         (WebCore::visitActiveDOMNodes):
34836         (WebCore::visitDOMObjects):
34837         (WebCore::visitActiveDOMObjects):
34838         * bindings/v8/V8DOMMap.h:
34839         (WebCore):
34840         * bindings/v8/V8PerIsolateData.h:
34841         (V8PerIsolateData):
34842         * bindings/v8/WorkerScriptController.cpp:
34843         (WebCore::WorkerScriptController::WorkerScriptController):
34844         (WebCore::WorkerScriptController::~WorkerScriptController):
34845         * bindings/v8/WorkerScriptController.h:
34846         (WorkerScriptController):
34847
34848 2012-10-24  Kent Tamura  <tkent@chromium.org>
34849
34850         Minimize CSS rulesets for multiple-fields input
34851         https://bugs.webkit.org/show_bug.cgi?id=100198
34852
34853         Reviewed by Kentaro Hara.
34854
34855         - Unify rulesets for input::-webkit-datetime-edit-*-field.
34856          input::-webkit-datetime-edit-*-field had identical ruleset.
34857
34858         - Move some rulesets near to related rulesets.
34859          Move -webkit-datetime-edit-*-field:focus nearby the new unified ruleset.
34860          Move input::-webkit-datetime-edit-second-field[readonly] nearby
34861         input::-webkit-datetime-edit-minute-field[readonly].
34862
34863         No new tests. This shouldn't make any behavior change.
34864
34865         * css/html.css:
34866         (input::-webkit-datetime-edit-year-field):
34867         (input::-webkit-datetime-edit-year-field:focus):
34868         (input::-webkit-datetime-edit-second-field[readonly]):
34869
34870 2012-10-24  Kent Tamura  <tkent@chromium.org>
34871
34872         REGRESSION(r132291): Crash in BaseMultipleFieldsDateAndTimeInputType
34873         https://bugs.webkit.org/show_bug.cgi?id=100326
34874
34875         Reviewed by Eric Seidel.
34876
34877         Test: fast/forms/time-multiple-fields/time-multiple-fields-change-type.html
34878
34879         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
34880         (WebCore::BaseMultipleFieldsDateAndTimeInputType::destroyShadowSubtree):
34881         We need to disconnect m_spinButtonElement before destructing the UA shadow tree.
34882
34883 2012-10-24  Adam Barth  <abarth@webkit.org>
34884
34885         [V8] DOMData is no longer needed
34886         https://bugs.webkit.org/show_bug.cgi?id=100313
34887
34888         Reviewed by Eric Seidel.
34889
34890         This class serves no purpose anymore and can be deleted.
34891
34892         * WebCore.gypi:
34893         * bindings/v8/DOMData.cpp: Removed.
34894         * bindings/v8/DOMData.h: Removed.
34895         * bindings/v8/DOMDataStore.cpp:
34896         (WebCore::DOMDataStore::current):
34897         * bindings/v8/DOMDataStore.h:
34898         (WebCore):
34899         (DOMDataStore):
34900         * bindings/v8/SerializedScriptValue.cpp:
34901         (WebCore::neuterBinding):
34902         * bindings/v8/V8DOMMap.cpp:
34903         (WebCore::getDOMNodeMap):
34904         (WebCore::getActiveDOMNodeMap):
34905         (WebCore::getDOMObjectMap):
34906         (WebCore::getActiveDOMObjectMap):
34907         (WebCore::removeAllDOMObjects):
34908         (WebCore::visitActiveDOMNodes):
34909         (WebCore::visitDOMObjects):
34910         (WebCore::visitActiveDOMObjects):
34911
34912 2012-10-24  Kent Tamura  <tkent@chromium.org>
34913
34914         Sort an Xcode project file.
34915
34916         * WebCore.xcodeproj/project.pbxproj: Sorted.
34917
34918 2012-10-24  Adam Barth  <abarth@webkit.org>
34919
34920         [V8] AbstractWeakReferenceMap is unnecessarily general and complex
34921         https://bugs.webkit.org/show_bug.cgi?id=100175
34922
34923         Reviewed by Eric Seidel.
34924
34925         Before this patch, AbstractWeakReferenceMap served two masters:
34926
34927         1) DOM wrappers
34928         2) NPV8 function templates
34929
34930         These two uses cases pushed AbstractWeakReferenceMap to be more general
34931         and complex that needed. This patch separates these two uses cases into
34932         two separate classes. V8NPTemplateMap is all of 40 lines of code. It's
34933         not worth complicating the DOM wrapper code path to share that tiny
34934         amount of code.
34935
34936         The other thing this patch does is store a pointer to the DOM wrapper
34937         map as the weak callback context object. That means we no longer need
34938         to search through all the wrapper maps in order to find the map that
34939         contains this particular DOM wrapper.
34940
34941         * WebCore.gypi:
34942         * bindings/v8/DOMData.cpp:
34943         * bindings/v8/DOMData.h:
34944         (DOMData):
34945         * bindings/v8/DOMDataStore.cpp:
34946             - Delete all these complicated weak callback functions. The weak
34947               callback functions are now an order of magnitude simpler and
34948               declared as private member functions on the wrapper map.
34949         * bindings/v8/DOMDataStore.h:
34950         (WebCore::DOMDataStore::domNodeMap):
34951         (WebCore::DOMDataStore::activeDomNodeMap):
34952         (DOMDataStore):
34953             - We now have a consistent type to use for all these wrapper maps.
34954               Both the hash map and the intrusive map derive from
34955               DOMWrapperMap (with a single template parameter).
34956         * bindings/v8/DOMWrapperMap.h: Added.
34957         (WebCore):
34958         (DOMWrapperVisitor):
34959             - The visitor is no longer an inner class. It's just a top-level
34960               class that does the same thing.
34961         (DOMWrapperMap):
34962             - The abstract interface for DOMWrapperMap has about half as many
34963               functions as the old AbstractWeakReferenceMap because the two use
34964               cases are disentangled.
34965         (WebCore::DOMWrapperMap::~DOMWrapperMap):
34966         (DOMWrapperHashMap):
34967             - This is a concrete instance of DOMWrapperMap that uses a hash map.
34968         (WebCore::DOMWrapperHashMap::DOMWrapperHashMap):
34969         (WebCore::DOMWrapperHashMap::remove):
34970         (WebCore::DOMWrapperHashMap::defaultWeakCallback):
34971             - Notice that the context parameter now points to the hashmap
34972               itself rather than to the native object. Now that we don't need
34973               to handle the NPAPI case, we can recover the native object from
34974               the wrapper using toNative. The assert in set() ensures that this
34975               always works.
34976         * bindings/v8/DOMWrapperWorld.h:
34977         * bindings/v8/IntrusiveDOMWrapperMap.h:
34978             - These classes are now simplified because they need to implement
34979               fewer functions.
34980         (WebCore::DOMNodeWrapperMap::weakCallback):
34981             - For this weak callback, we still use the native object as the
34982               context parameter. We could also recover the native object from
34983               the wrapper, which means this context parameter is available to
34984               do other work.
34985         * bindings/v8/ScopedDOMDataStore.cpp:
34986         (WebCore::ScopedDOMDataStore::ScopedDOMDataStore):
34987             - This code no longer needs to have knowledge of which weak
34988               callbacks these objects use.
34989         (WebCore::ScopedDOMDataStore::~ScopedDOMDataStore):
34990             - We need to clear the maps before deleting them because there are
34991               still JavaScript objects that have references to the map in their
34992               weak callback parameter. Previously, we handled this case because
34993               we would search all the wrapper maps and fail to find the wrapper.
34994         * bindings/v8/ScriptProfiler.cpp:
34995         (WebCore::ScriptProfiler::visitExternalArrays):
34996         * bindings/v8/StaticDOMDataStore.cpp:
34997             - This code no longer needs to have knowledge of which weak
34998               callback these maps use.
34999         * bindings/v8/StaticDOMDataStore.h:
35000         (StaticDOMDataStore):
35001         * bindings/v8/V8DOMMap.cpp:
35002         (WebCore::getDOMNodeMap):
35003         (WebCore::getActiveDOMNodeMap):
35004         (WebCore::removeAllDOMObjects):
35005             - Rather than using some complicated visitor pattern, we can now
35006               just call clear() directly on the maps to remove all the objects.
35007         (WebCore::visitActiveDOMNodes):
35008         (WebCore::visitDOMObjects):
35009         (WebCore::visitActiveDOMObjects):
35010         * bindings/v8/V8DOMMap.h:
35011         (WebCore):
35012             - Delete the old versions of these classes.
35013         (DOMDataStoreHandle):
35014             - Style nit: one-argument constructors should be marked explicit.
35015         * bindings/v8/V8DOMWrapper.cpp:
35016         (WebCore::V8DOMWrapper::domWrapperType):
35017             - I moved this logic into WrapperTypeInfo.h to avoid a circular
35018               header dependency.
35019         * bindings/v8/V8DOMWrapper.h:
35020         (WebCore::V8DOMWrapper::getCachedWrapper):
35021         * bindings/v8/V8GCController.cpp:
35022             - EnsureWeakDOMNodeVisitor is no longer used (or needed since we no
35023               longer clear the weak callbacks in V8GCController).
35024         * bindings/v8/V8NPObject.cpp:
35025         (V8NPTemplateMap):
35026             - staticTemplateMap is no longer an instance of WeakReferenceMap.
35027               Instead, this patch just implements the functionality we need
35028               here directly.
35029         (WebCore::V8NPTemplateMap::get):
35030         (WebCore::V8NPTemplateMap::set):
35031         (WebCore::V8NPTemplateMap::sharedInstance):
35032         (WebCore::V8NPTemplateMap::weakCallback):
35033         (WebCore::V8NPTemplateMap::dispose):
35034         (WebCore::npObjectGetProperty):
35035         (WebCore):
35036         (WebCore::staticNPObjectMap):
35037         (WebCore::weakNPObjectCallback):
35038             - DOMWrapperMap no longer exposes a "forget" function. Instead, we
35039               just use the more basic "remove" and "Dispose" operations to do
35040               the same thing. This is possible now because we no longer have
35041               "removeIfPossible" to support searching all the wrapper maps for
35042               the one that has the right wrapper.
35043         (WebCore::createV8ObjectForNPObject):
35044             - DOMWrapperMap No longer has a "contains" function. Instead, we
35045               use get, which actually makes this code more efficient because we
35046               only do one hash map lookup.
35047         (WebCore::forgetV8ObjectForNPObject):
35048             - The changes here are a combination of the two sorts of changes
35049               above.
35050         * bindings/v8/WrapperTypeInfo.h:
35051         (WebCore::toNative):
35052         (WebCore::toWrapperTypeInfo):
35053             - The patch moves these functions into this header to avoid a
35054               circular header dependency.
35055
35056 2012-10-24  Arnaud Renevier  <a.renevier@sisa.samsung.com>
35057
35058         [cairo] unneeded FloatRect object creation in BitmapImage::draw
35059         https://bugs.webkit.org/show_bug.cgi?id=100298
35060
35061         Reviewed by Martin Robinson.
35062
35063         Do not copy FloatRect arguments src and dst to local variables.
35064         Instead, use src and dst directly.
35065
35066         No new tests. No change in behavior.
35067
35068         * platform/graphics/cairo/BitmapImageCairo.cpp:
35069         (WebCore::BitmapImage::draw):
35070
35071 2012-10-24  Seokju Kwon  <seokju.kwon@samsung.com>
35072
35073         [SOUP] Provide logging for SocketStreamHandleSoup
35074         https://bugs.webkit.org/show_bug.cgi?id=100215
35075
35076         Reviewed by Alexey Proskuryakov.
35077
35078         Add logging to SocketStreamHandleSoup to facilitate debugging.
35079
35080         * platform/network/soup/SocketStreamHandleSoup.cpp:
35081         (WebCore::SocketStreamHandle::SocketStreamHandle):
35082         (WebCore::SocketStreamHandle::~SocketStreamHandle):
35083         (WebCore::SocketStreamHandle::platformSend):
35084         (WebCore::SocketStreamHandle::platformClose):
35085
35086 2012-10-24  Nico Weber  <thakis@chromium.org>
35087
35088         Pass on exif orientation from ImageSource when using the open-source image decoders
35089         https://bugs.webkit.org/show_bug.cgi?id=100164
35090
35091         Reviewed by Eric Seidel.
35092
35093         The orientation is honored always for image documents, and optionally
35094         for <img> elements if shouldRespectImageOrientation is set (off by
35095         default). However, the feature needs port-specific modifications to
35096         GraphicsContext (without this, webcore will use the rotated bounds but
35097         draw the image as if it hadn't be rotated, resulting in squished
35098         pixels), and most ports don't implement these yet -- so put
35099         turning this on for image documents behind a port-specific #ifdef.
35100
35101         No observable behavior change. Once it's hooked up, it will be tested
35102         by fast/images/exif-orientation.html.
35103
35104         * platform/graphics/ImageSource.cpp:
35105         (WebCore::ImageSource::size):
35106         (WebCore::ImageSource::frameSizeAtIndex):
35107         (WebCore::ImageSource::orientationAtIndex):
35108         * platform/graphics/chromium/DeferredImageDecoder.cpp:
35109         (WebCore::DeferredImageDecoder::orientation):
35110         (WebCore):
35111         * platform/graphics/chromium/DeferredImageDecoder.h:
35112         (DeferredImageDecoder):
35113         * platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
35114         (WebCore::readImageOrientation):
35115         * rendering/RenderObject.cpp:
35116         (WebCore::RenderObject::shouldRespectImageOrientation):
35117
35118 2012-10-24  Beth Dakin  <bdakin@apple.com>
35119
35120         https://bugs.webkit.org/show_bug.cgi?id=100169
35121         We should make TileCache tiles the size of the tile coverage rect 
35122         when we can't do fast scrolling
35123         -and-
35124         <rdar://problem/12505021>
35125
35126         Reviewed by Simon Fraser.
35127
35128         Some websites that don't do fast scrolling still scroll slower than 
35129         they do with tiled drawing disabled. 
35130         https://bugs.webkit.org/show_bug.cgi?id=99768 addressed some of this 
35131         performance problem, but there is still more ground to make up. This 
35132         patch addresses the remaining issue by making tiles the size of the 
35133         window when we can't do fast scrolling. 
35134
35135         The constructor and create function no longer take a size parameter. 
35136         That's all fully controlled within TileCache now. m_tileSize is no 
35137         longer const.
35138         * platform/graphics/ca/mac/TileCache.h:
35139
35140         Store the current default size as constants so that we can access it 
35141         in both the constructor and adjustTileSizeForCoverageRect().
35142         * platform/graphics/ca/mac/TileCache.mm:
35143         (WebCore::TileCache::TileCache):
35144
35145         This new function will set m_tileSize to the size of the tile 
35146         coverage rect if the tile coverage is limited to the visible area. 
35147         Otherwise, the tiles are set to be the default size.
35148         (WebCore::TileCache::adjustTileSizeForCoverageRect):
35149         
35150         Call adjustTileSizeForCoverageRect().
35151         (WebCore::TileCache::revalidateTiles):
35152
35153         No need to send in a size anymore.
35154         * platform/graphics/ca/mac/WebTileCacheLayer.h:
35155         (WebCore):
35156
35157 2012-10-24  David Barton  <dbarton@mathscribe.com>
35158
35159         MathML tests trigger font cache assertions in debug bots
35160         https://bugs.webkit.org/show_bug.cgi?id=100268
35161
35162         Reviewed by Eric Seidel.
35163
35164         Add a FontCachePurgePreventer to fix this.
35165
35166         Tested by existing tests.
35167
35168         * rendering/mathml/RenderMathMLOperator.cpp:
35169         (WebCore::RenderMathMLOperator::updateFromElement):
35170
35171 2012-10-24  Tim Horton  <timothy_horton@apple.com>
35172
35173         Update main frame scroll position immediately for programmatic scrolls
35174         https://bugs.webkit.org/show_bug.cgi?id=98074
35175
35176         Reviewed by Simon Fraser.
35177
35178         Immediately update the main frame scroll position after a programmatic scroll,
35179         so that performing a scrollBy or scrollTo will be instantly reflected in
35180         all of the scroll offset accessors.
35181
35182         No new tests; this will be tested by many scrolling tests once WebKitTestRunner
35183         can use threaded scrolling.
35184
35185         * page/scrolling/ScrollingCoordinator.cpp:
35186         (WebCore::ScrollingCoordinator::requestScrollPositionUpdate):
35187
35188 2012-10-24  Mihai Parparita  <mihaip@chromium.org>
35189
35190         [Chromium] Allow pushState and related history APIs to be disabled per context
35191         https://bugs.webkit.org/show_bug.cgi?id=99780
35192
35193         Reviewed by Adam Barth.
35194
35195         Chrome Apps do not support the history API (or navigation in general).
35196         Since pushState is generally feature detected, it's cleanest to disable
35197         it via a V8 per-context feature, so that applications can have the
35198         appropriate fallback behavior (other history APIs are re-mapped to throw
35199         exceptions, since history.back() and the link are not feature detected).
35200
35201         * dom/ContextFeatures.cpp:
35202         (WebCore::ContextFeatures::pushStateEnabled):
35203         (WebCore):
35204         * dom/ContextFeatures.h:
35205         * dom/Document.cpp:
35206         (WebCore::Document::enqueuePopstateEvent):
35207         * page/History.idl:
35208
35209 2012-10-24  Tommy Widenflycht  <tommyw@google.com>
35210
35211         MediaStream API: Make sure all events are dispatched asynchronously
35212         https://bugs.webkit.org/show_bug.cgi?id=100286
35213
35214         Reviewed by Adam Barth.
35215
35216         This is necessary to safeguard against if the UA uses synchronous UA->WebKit calls,
35217         and the web application calls methods on the RTCPeerConnection in the event callbacks.
35218
35219         Test: fast/mediastream/RTCPeerConnection-events.html
35220         Also tested by the chromium webrtc fuzz tests.
35221
35222         * Modules/mediastream/RTCPeerConnection.cpp:
35223         (WebCore::RTCPeerConnection::RTCPeerConnection):
35224         (WebCore::RTCPeerConnection::negotiationNeeded):
35225         (WebCore::RTCPeerConnection::didGenerateIceCandidate):
35226         (WebCore::RTCPeerConnection::didAddRemoteStream):
35227         (WebCore::RTCPeerConnection::didRemoveRemoteStream):
35228         (WebCore::RTCPeerConnection::didAddRemoteDataChannel):
35229         (WebCore::RTCPeerConnection::changeReadyState):
35230         (WebCore::RTCPeerConnection::changeIceState):
35231         (WebCore):
35232         (WebCore::RTCPeerConnection::scheduleDispatchEvent):
35233         (WebCore::RTCPeerConnection::scheduledEventTimerFired):
35234         * Modules/mediastream/RTCPeerConnection.h:
35235         (RTCPeerConnection):
35236
35237 2012-10-24  Mark Pilgrim  <pilgrim@chromium.org>
35238
35239         [Chromium] Remove screen-related functions from PlatformSupport
35240         https://bugs.webkit.org/show_bug.cgi?id=97474
35241
35242         Reviewed by Adam Barth.
35243
35244         Screen-related functions like screenHorizontalDPI that
35245         used to be on PlatformSupport are now accessed through a new
35246         PlatformPageClient attached to Widget in WebCore-land, which is
35247         implemented by ChromeClientImpl in WebKit-land, which proxies
35248         calls to WebWidgetClient, which is actually implemented in
35249         Chromium-land.
35250
35251         * WebCore.gypi:
35252         * platform/Widget.h:
35253         * platform/chromium/PageClientChromium.h: Copied from Source/WebCore/platform/chromium/PlatformWidget.h.
35254         (PageClientChromium):
35255         * platform/chromium/PlatformScreenChromium.cpp:
35256         (WebCore::toPlatformPageClient):
35257         (WebCore):
35258         (WebCore::screenHorizontalDPI):
35259         (WebCore::screenVerticalDPI):
35260         (WebCore::screenDepth):
35261         (WebCore::screenDepthPerComponent):
35262         (WebCore::screenIsMonochrome):
35263         (WebCore::screenRect):
35264         (WebCore::screenAvailableRect):
35265         * platform/chromium/PlatformSupport.h:
35266         (PlatformSupport):
35267
35268 2012-10-24  Adam Barth  <abarth@webkit.org>
35269
35270         [V8] WorkerContextExecutionProxy doesn't need to track events
35271         https://bugs.webkit.org/show_bug.cgi?id=100295
35272
35273         Reviewed by Eric Seidel.
35274
35275         This code was added when this code was originally upstreamed as part of
35276         the Chromium port. There doesn't appear to be any reason why
35277         WorkerContextExecutionProxy needs to keep a Vector of raw event
35278         pointers. Those points are likely to become dangling, making the rest
35279         of what this code does very sketchy.
35280
35281         * bindings/v8/V8WorkerContextEventListener.cpp:
35282         (WebCore::V8WorkerContextEventListener::callListenerFunction):
35283         * bindings/v8/WorkerContextExecutionProxy.cpp:
35284         (WebCore::WorkerContextExecutionProxy::dispose):
35285         * bindings/v8/WorkerContextExecutionProxy.h:
35286         (WebCore::WorkerContextExecutionState::WorkerContextExecutionState):
35287         (WorkerContextExecutionProxy):
35288
35289 2012-10-24  Max Vujovic  <mvujovic@adobe.com>
35290
35291         [CSS Shaders] The mesh should be specified using <column, row> order
35292         https://bugs.webkit.org/show_bug.cgi?id=96285
35293
35294         Reviewed by Dean Jackson.
35295
35296         Change StyleResolver and CSSComputedStyleDeclaration to handle the mesh parameters in
35297         column, row order.
35298
35299         Test: css3/filters/custom/custom-filter-mesh-column-row-order.html
35300
35301         * css/CSSComputedStyleDeclaration.cpp:
35302         (WebCore::CSSComputedStyleDeclaration::valueForFilter):
35303             Append the number of columns before the number of rows in the meshParameters
35304             CSSValueList.
35305         * css/StyleResolver.cpp:
35306         (WebCore::StyleResolver::createCustomFilterOperation):
35307             Store the second mesh parameter in meshRows instead of meshColumns.
35308
35309 2012-10-24  Jae Hyun Park  <jae.park@company100.net>
35310
35311         loaderRunLoop() should use synchronization instead of while loop
35312         https://bugs.webkit.org/show_bug.cgi?id=55402
35313
35314         Reviewed by Alexey Proskuryakov.
35315
35316         Originally, loaderRunLoop() sleeps until a thread has started and set
35317         the loaderRunLoopObject static variable. This patch uses
35318         ThreadCondition to synchronize instead of a while loop.
35319
35320         No new tests (No behavior change).
35321
35322         * platform/network/cf/LoaderRunLoopCF.cpp:
35323         (WebCore::runLoaderThread):
35324         (WebCore::loaderRunLoop):
35325         * platform/network/cf/LoaderRunLoopCF.h:
35326         (WebCore):
35327
35328 2012-10-24  Sailesh Agrawal  <sail@chromium.org>
35329
35330         Incorrect keycodes for numpad /, -, +, .
35331         https://bugs.webkit.org/show_bug.cgi?id=99188
35332
35333         Reviewed by Tony Chang.
35334
35335         In r57951 we switched to mapping keys by character code.
35336         This regressed the numpad keys which no longer match the Windows virtual key codes.
35337         This CL fixes this by never mapping numpad keys by character code.
35338
35339         Test: platform/mac/fast/events/numpad-keycode-mapping.html
35340
35341         * platform/mac/PlatformEventFactoryMac.mm:
35342         (WebCore::windowsKeyCodeForKeyEvent):
35343
35344 2012-10-24  Simon Fraser  <simon.fraser@apple.com>
35345
35346         Null-check the RenderView in ocument::windowScreenDidChange to fix a crash when saving PDFs
35347         https://bugs.webkit.org/show_bug.cgi?id=100141
35348         <rdar://problem/12559147>
35349
35350         Reviewed by Tim Horton.
35351
35352         For PDF documents the RenderView is null, so null-check it to avoid a crash
35353         when saving PDFs.
35354
35355         * dom/Document.cpp:
35356         (WebCore::Document::windowScreenDidChange):
35357
35358 2012-10-24  Terry Anderson  <tdanderson@chromium.org>
35359
35360         Handle two-finger tap gestures in the same way as long-press gestures
35361         https://bugs.webkit.org/show_bug.cgi?id=99947
35362
35363         Reviewed by Adam Barth.
35364
35365         Currently a long-press gesture is used to dispatch a context menu (for platforms 
35366         defining CONTEXT_MENUS) or to select text (for Android). Additionally, for platforms 
35367         defining TOUCH_ADJUSTMENT, gesture target fuzzing is performed on the location and 
35368         touch area of the long-press gesture.
35369
35370         This CL will cause two-finger tap gestures to be handled in the same way as long-press 
35371         gestures. The location and touch area of a two-finger tap gesture will correspond to 
35372         the location and touch area of the first finger down; the location/area of the second 
35373         finger will be ignored.
35374
35375         Test: touchadjustment/touch-links-two-finger-tap.html
35376
35377         * page/EventHandler.cpp:
35378         (WebCore::EventHandler::handleGestureLongPress):
35379         (WebCore):
35380         (WebCore::EventHandler::handleGestureForTextSelectionOrContextMenu):
35381         (WebCore::EventHandler::handleGestureTwoFingerTap):
35382         (WebCore::EventHandler::adjustGesturePosition):
35383         * page/EventHandler.h:
35384         (EventHandler):
35385
35386 2012-10-24  Chris Fleizach  <cfleizach@apple.com>
35387
35388         AX:When aria-label is used, the text under an element is still appearing as the AXTitle
35389         https://bugs.webkit.org/show_bug.cgi?id=98167
35390
35391         Reviewed by Beth Dakin.
35392
35393         According to WAI-ARIA text computation, the presence of aria-label and alternative text
35394         should override the visible text within an element.
35395
35396         Test: platform/mac/accessibility/aria-label-overrides-visible-text.html
35397
35398         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
35399         (-[WebAccessibilityObjectWrapper accessibilityTitle]):
35400
35401 2012-10-24  Sheriff Bot  <webkit.review.bot@gmail.com>
35402
35403         Unreviewed, rolling out r132303 and r132312.
35404         http://trac.webkit.org/changeset/132303
35405         http://trac.webkit.org/changeset/132312
35406         https://bugs.webkit.org/show_bug.cgi?id=100287
35407
35408         Triggering crashes on many popular websites (Requested by
35409         leviw|gardening on #webkit).
35410
35411         * css/CSSGrammar.y.in:
35412         * css/CSSParser.cpp:
35413         (WebCore::CSSParser::detectAtToken):
35414         * css/CSSParser.h:
35415         * css/CSSPropertySourceData.h:
35416         * css/RuleSet.cpp:
35417         (WebCore::RuleData::RuleData):
35418         (WebCore::RuleSet::addRule):
35419         (WebCore::RuleSet::addRegionRule):
35420         (WebCore::RuleSet::addRulesFromSheet):
35421         (WebCore::RuleSet::addStyleRule):
35422         * css/RuleSet.h:
35423         (RuleData):
35424         (RuleSet):
35425         * css/StyleResolver.cpp:
35426         (WebCore::makeRuleSet):
35427         (WebCore::StyleResolver::appendAuthorStyleSheets):
35428         (WebCore::StyleResolver::matchScopedAuthorRules):
35429         (WebCore::StyleResolver::locateSharedStyle):
35430         * css/StyleResolver.h:
35431         (StyleResolver):
35432         * css/StyleRule.cpp:
35433         (WebCore::StyleRuleBase::reportMemoryUsage):
35434         (WebCore::StyleRuleBase::destroy):
35435         (WebCore::StyleRuleBase::copy):
35436         (WebCore::StyleRuleBase::createCSSOMWrapper):
35437         * css/StyleRule.h:
35438         * css/StyleScopeResolver.cpp:
35439         (WebCore::StyleScopeResolver::reportMemoryUsage):
35440         * css/StyleScopeResolver.h:
35441         (WebCore):
35442         (StyleScopeResolver):
35443         * css/StyleSheetContents.cpp:
35444         (WebCore::childRulesHaveFailedOrCanceledSubresources):
35445
35446 2012-10-24  Joshua Bell  <jsbell@chromium.org>
35447
35448         IndexedDB: Cursor property value identities should be preserved
35449         https://bugs.webkit.org/show_bug.cgi?id=100051
35450
35451         Reviewed by Tony Chang.
35452
35453         Some W3C test submissions point out that subsequent accesses to cursor properties should
35454         yield the same value until the cursor advances. We handled this with custom binding code for
35455         IDBCursor.value but not IDBCursor.key or IDBCursor.primaryKey. The custom value code is
35456         being removed in webkit.org/b/100034 in favor of returning ScriptValue and the same fix can
35457         be applied to key/primaryKey.
35458
35459         Test: storage/indexeddb/cursor-properties.html
35460
35461         * Modules/indexeddb/IDBCursor.cpp: Compute/store/serve up ScriptValues instead of IDBKeys
35462         (WebCore::IDBCursor::key):
35463         (WebCore::IDBCursor::primaryKey):
35464         (WebCore::IDBCursor::setValueReady):
35465         * Modules/indexeddb/IDBCursor.h:
35466         (IDBCursor):
35467         (WebCore::IDBCursor::idbPrimaryKey): Expose this for callers that need access to the IDBKey
35468         * Modules/indexeddb/IDBCursor.idl:
35469         * Modules/indexeddb/IDBObjectStore.cpp: ... like this one.
35470         (WebCore):
35471         * Modules/indexeddb/IDBRequest.cpp:
35472         (WebCore::IDBRequest::dispatchEvent): Pass along script context, for the conversion.
35473         * bindings/v8/IDBBindingUtilities.cpp:
35474         (WebCore::idbKeyToScriptValue): New method for explicit conversion.
35475         (WebCore):
35476         * bindings/v8/IDBBindingUtilities.h:
35477         (WebCore):
35478
35479 2012-10-24  Ami Fischman  <fischman@chromium.org>
35480
35481         call to setNeedsLayout during RenderVideo::paintReplaced
35482         https://bugs.webkit.org/show_bug.cgi?id=100265
35483
35484         Reviewed by Eric Carlson.
35485
35486         Removed unnecessary call and added new defensive guards to catch erroneous setNeedsLayout() calls
35487         during paints earlier (so the offending calls are in the emitted stacktrace).
35488
35489         No new tests - new defensive checks are triggered by existing tests.
35490
35491         * page/FrameView.cpp:
35492         (WebCore::FrameView::paintContents): forbid setNeedsLayout() during painting
35493         * rendering/RenderObject.cpp:
35494         (WebCore):
35495         (WebCore::RenderObject::SetLayoutNeededForbiddenScope::SetLayoutNeededForbiddenScope):
35496         (WebCore::RenderObject::SetLayoutNeededForbiddenScope::~SetLayoutNeededForbiddenScope):
35497         * rendering/RenderObject.h:
35498         (RenderObject):
35499         (SetLayoutNeededForbiddenScope): added helper class for forbidding setNeedsLayout() in a scope.
35500         * rendering/RenderVideo.cpp:
35501         (WebCore::RenderVideo::paintReplaced): drop the offending & unnecessary call to updatePlayer().
35502
35503 2012-10-24  Adam Barth  <abarth@webkit.org>
35504
35505         [V8] ActiveDOMObjectEpilogueVisitor is unnecessary and can be deleted
35506         https://bugs.webkit.org/show_bug.cgi?id=100208
35507
35508         Reviewed by Eric Seidel.
35509
35510         Rather than clearing and re-establishing the weak callback for
35511         ActiveDOMObjects during every GC, this patch puts all the
35512         ActiveDOMObjects with pending activity into an object group with a live
35513         object, causing them not to be garbage collected.
35514
35515         In addition to simplifying this code, this patch makes the patch in
35516         https://bugs.webkit.org/show_bug.cgi?id=100175 much easier because
35517         V8GCController no longer needs to know how to configure the weak
35518         callbacks for these objects.
35519
35520         * bindings/v8/V8GCController.cpp:
35521         (WebCore::ActiveDOMObjectPrologueVisitor::ActiveDOMObjectPrologueVisitor):
35522         (ActiveDOMObjectPrologueVisitor):
35523         (WebCore::ActiveDOMObjectPrologueVisitor::visitDOMWrapper):
35524         (WebCore::V8GCController::majorGCPrologue):
35525         (WebCore::V8GCController::majorGCEpilogue):
35526         * bindings/v8/V8PerIsolateData.cpp:
35527         (WebCore::V8PerIsolateData::V8PerIsolateData):
35528         * bindings/v8/V8PerIsolateData.h:
35529         (WebCore::V8PerIsolateData::liveRoot):
35530         (V8PerIsolateData):
35531
35532 2012-10-24  Brady Eidson  <beidson@apple.com>
35533
35534         Add a strategy for loader customization.
35535         https://bugs.webkit.org/show_bug.cgi?id=100278
35536
35537         Reviewed by Alexey Proskuryakov.
35538
35539         It's empty for now and does nothing, just like the goggles.
35540
35541         * WebCore.gypi:
35542         * WebCore.vcproj/WebCore.vcproj:
35543         * WebCore.xcodeproj/project.pbxproj:
35544         * platform/PlatformStrategies.h:
35545         (WebCore::PlatformStrategies::loaderStrategy):
35546         (PlatformStrategies):
35547         (WebCore::PlatformStrategies::PlatformStrategies):
35548
35549 2012-10-24  Tony Chang  <tony@chromium.org>
35550
35551         Setting width of a flexitem causes the adjacent flex item to be displayed poorly.
35552         https://bugs.webkit.org/show_bug.cgi?id=99925
35553
35554         Reviewed by Ojan Vafai.
35555
35556         Make sure that we always repaint when moving a child. This is similar to what RenderDeprecatedFlexibleBox does.
35557
35558         Test: css3/flexbox/repaint-during-resize-no-flex.html
35559
35560         * rendering/RenderFlexibleBox.cpp:
35561         (WebCore::RenderFlexibleBox::setFlowAwareLocationForChild): Move logic for repaining into the helper method
35562         for setting the location of a child.
35563         (WebCore::RenderFlexibleBox::layoutColumnReverse): Remove code for repaint since it's now in setFlowAwareLocationForChild.
35564         (WebCore::RenderFlexibleBox::adjustAlignmentForChild): Remove code for repaint since it's now in setFlowAwareLocationForChild.
35565
35566 2012-10-24  Simon Fraser  <simon.fraser@apple.com>
35567
35568         Fix CALayer hiearchy when combining tiling with preserve-3d
35569         https://bugs.webkit.org/show_bug.cgi?id=100205
35570
35571         Reviewed by Dean Jackson.
35572
35573         When an element has "transform-style: preserve-3d", its GraphicsLayerCA has a
35574         m_structuralLayer which is a CATransformLayer. The primary CALayer which contains rendered
35575         content becomes a sublayer of the CATransformLayer. If the element has backface-visibility:hidden,
35576         it is the primary layer that is set to be single-sided.
35577         
35578         In r131940 we started to use TileCaches in place of CATiledLayer. TileCaches work via
35579         "customSublayers" returned from the PlatformCALayer, where the custom sublayer is 
35580         the tile cache container layer. However, the custom sublayers were being added as
35581         children of the structural (CATransformLayer) layer, not of the primary (CALayer) layer,
35582         thus they were not affected by the doubleSided property.
35583         
35584         This change cleans up the confusing code in GraphicsLayerCA::updateSublayerList()
35585         by maintaining two vectors of PlatformCALayers, one for sublayers of the structural
35586         layer, and one for sublayers of the primary layer. It adds custom sublayers to
35587         the latter list, so now the tile cache container layer becomes a sublayer of
35588         the primary layer, so is affected by that layer's doubleSided property.
35589
35590         Test: compositing/tiling/backface-preserve-3d-tiled.html
35591
35592         * platform/graphics/ca/GraphicsLayerCA.cpp:
35593         (WebCore::GraphicsLayerCA::updateSublayerList):
35594
35595 2012-10-23  Zhenyao Mo  <zmo@google.com>
35596
35597         Update mozilla's CheckedInt.h to the latest version
35598         https://bugs.webkit.org/show_bug.cgi?id=100177
35599
35600         Reviewed by Kenneth Russell.
35601
35602         * html/canvas/CheckedInt.h: Sync with mozilla's copy with minumum modifications.
35603         (detail):
35604         (IsSupportedPass2):
35605         (IsSupported):
35606         (UnsignedType):
35607         (IsSigned):
35608         (TwiceBiggerType):
35609         (PositionOfSignBit):
35610         (MinValue):
35611         (MaxValue):
35612         (WebCore::detail::HasSignBit):
35613         (WebCore::detail::BinaryComplement):
35614         (WebCore::detail::IsInRange):
35615         (WebCore::detail::IsAddValid):
35616         (WebCore::detail::IsSubValid):
35617         (WebCore::detail::IsMulValid):
35618         (WebCore::detail::IsDivValid):
35619         (WebCore::detail::OppositeIfSignedImpl::run):
35620         (WebCore::detail::OppositeIfSigned):
35621         (WebCore):
35622         (CheckedInt):
35623         (WebCore::CheckedInt::CheckedInt):
35624         (WebCore::CheckedInt::value):
35625         (WebCore::CheckedInt::isValid):
35626         (WebCore::CheckedInt::operator -):
35627         (WebCore::CheckedInt::operator ==):
35628         (WebCore::CheckedInt::operator++):
35629         (WebCore::CheckedInt::operator--):
35630         (CastToCheckedIntImpl):
35631         (WebCore::detail::CastToCheckedIntImpl::run):
35632         (WebCore::castToCheckedInt):
35633         (WebCore::operator ==):
35634         * html/canvas/DataView.cpp: change valid() to isValid().
35635         (WebCore::DataView::create):
35636         * html/canvas/WebGLBuffer.cpp: Ditto.
35637         (WebCore::WebGLBuffer::associateBufferDataImpl):
35638         (WebCore::WebGLBuffer::associateBufferSubDataImpl):
35639         * html/canvas/WebGLRenderingContext.cpp: Ditto.
35640         (WebCore):
35641         (WebCore::WebGLRenderingContext::drawArrays):
35642         * platform/graphics/GraphicsContext3D.cpp: Ditto.
35643         (WebCore::GraphicsContext3D::computeImageSizeInBytes):
35644
35645 2012-10-24  Noam Rosenthal  <noam.rosenthal@nokia.com>
35646
35647         [Qt-on-Mac] GraphicsSurfaces should not create a global IOSurface handle
35648         https://bugs.webkit.org/show_bug.cgi?id=89885
35649
35650         Reviewed by Kenneth Rohde Christiansen.
35651
35652         Use mach_port instead of global tokens for IOSurfaces.
35653         Global IOSurfaces are accessible from other processes using their handle, while mach_ports
35654         can only be shared directly via IPC.
35655
35656         Tested by existing WebGL tests.
35657
35658         * platform/graphics/surfaces/GraphicsSurfaceToken.h:
35659         (GraphicsSurfaceToken):
35660         * platform/graphics/surfaces/mac/GraphicsSurfaceMac.cpp:
35661         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
35662         (WebCore::GraphicsSurfacePrivate::~GraphicsSurfacePrivate):
35663
35664 2012-10-24  Rick Byers  <rbyers@chromium.org>
35665
35666         image-set doesn't round-trip properly with cssText
35667         https://bugs.webkit.org/show_bug.cgi?id=99725
35668
35669         Reviewed by Beth Dakin.
35670
35671         Fix serialization of -webkit-image-set rules to use the same format as
35672         is used for parsing.
35673
35674         Test: fast/css/image-set-setting.html
35675
35676         * css/CSSImageSetValue.cpp:
35677         (WebCore::CSSImageSetValue::customCssText):
35678         * css/CSSValueList.h:
35679         (WebCore::CSSValueList::item): Add const overload
35680
35681 2012-10-24  Jonathan Feldstein  <jfeldstein@rim.com>
35682
35683         BlackBerry fix for webgl-depth-texture.html
35684         https://bugs.webkit.org/show_bug.cgi?id=100258
35685
35686         Reviewed by Yong Li.
35687
35688         Removed a platform specific define that is unnecessary.
35689
35690         * platform/graphics/GraphicsContext3D.cpp:
35691         (WebCore::GraphicsContext3D::computeFormatAndTypeParameters):
35692
35693 2012-10-24  Nico Weber  <thakis@chromium.org>
35694
35695         Honor image orientation in GraphicsContextSkia
35696         https://bugs.webkit.org/show_bug.cgi?id=100179
35697
35698         Reviewed by Stephen White.
35699
35700         Also fix a bug in ImageOrientation.h: Some of the values were
35701         switched. They now match the description in the exif spec at
35702         http://www.exif.org/Exif2-2.PDF page 18, and the notes at
35703         http://www.sno.phy.queensu.ca/~phil/exiftool/TagNames/EXIF.html and
35704         the picture at http://www.80sidea.com/archives/2316.
35705
35706         They showed up correctly in Safari because the orientation transform
35707         was done after flipping Y. Let the flipping happen later. I verified
35708         that flipping transformation order and fixing the exif enum cancelled
35709         each other out, so this has no effect on the apple port.
35710
35711         Not hooked up yet, so no observable difference.
35712
35713         * platform/graphics/BitmapImage.h:
35714         * platform/graphics/ImageOrientation.h:
35715         (WebCore::ImageOrientation::usesWidthAsHeight):
35716         (WebCore::ImageOrientation::fromEXIFValue):
35717         * platform/graphics/cg/GraphicsContextCG.cpp:
35718         (WebCore::GraphicsContext::drawNativeImage):
35719         * platform/graphics/skia/ImageSkia.cpp:
35720         (WebCore::paintSkBitmap):
35721         (WebCore::BitmapImage::draw):
35722         (WebCore):
35723
35724 2012-10-24  Alexey Proskuryakov  <ap@apple.com>
35725
35726         Fixed Windows path for SharedWorkerStrategy.h - it's in workers/, not platform/.
35727
35728         * WebCore.vcproj/WebCore.vcproj:
35729
35730 2012-10-24  Chris Fleizach  <cfleizach@apple.com>
35731
35732         AX: WebKit exposes abstract ARIA role range as AXSlider; should be generic AXGroup
35733         https://bugs.webkit.org/show_bug.cgi?id=100204
35734
35735         Reviewed by Beth Dakin.
35736
35737         Remove the "range" role as a valid ARIA role.
35738
35739         Test: platform/mac/accessibility/aria-slider-value.html
35740
35741         * accessibility/AccessibilityObject.cpp:
35742         (WebCore::createARIARoleMap):
35743
35744 2012-10-24  Florin Malita  <fmalita@chromium.org>
35745
35746         [Chromium] SVG repaint issues
35747         https://bugs.webkit.org/show_bug.cgi?id=99874
35748
35749         Reviewed by Levi Weintraub.
35750
35751         RenderSVGRoot::paintReplaced() converts the container offsets to a relative transform,
35752         but in doing so it ends up accumulating subpixel rounding deltas twice: first for 
35753         adjustedPaintOffset and second in localToParentTransform(). If coordinates are on
35754         half-pixel boundaries, the 2x rounding delta yields a full pixel drift and we end up
35755         painting at the wrong location.
35756
35757         This can be avoided by using localToBorderBoxTransform() directly, which (unlike
35758         localToParentTransform()) doesn't perform rounding.
35759
35760         No new tests: existing pixel results cover this change after rebaseline.
35761
35762         * rendering/svg/RenderSVGRoot.cpp:
35763         (WebCore::RenderSVGRoot::paintReplaced):
35764
35765 2012-10-24  Levi Weintraub  <leviw@chromium.org>
35766
35767         Fixing the Chromium build after typo in r132367.
35768
35769         * WebCore.gypi:
35770
35771 2012-10-24  Nico Weber  <thakis@chromium.org>
35772
35773         [chromium] Respect image orientation in image dragging code
35774         https://bugs.webkit.org/show_bug.cgi?id=100200
35775
35776         Reviewed by Tony Chang.
35777
35778         Based on the corresponding code in DragImageMac.mm.  The image
35779         rotation code isn't hooked up yet, so no observable effect for now.
35780
35781         * platform/chromium/DragImageChromiumSkia.cpp:
35782         (WebCore::createDragImageFromImage):
35783
35784 2012-10-24  Michael Saboff  <msaboff@apple.com>
35785
35786         Code cleanup after r132165
35787         https://bugs.webkit.org/show_bug.cgi?id=100135
35788
35789         Reviewed by Geoffrey Garen.
35790
35791         Fixed up some unneccesary and inefficient constructs in MarkupTokenBase.h.
35792
35793         Code clean up without functional changes, therefore no new tests.
35794
35795         * xml/parser/MarkupTokenBase.h:
35796         (WebCore::MarkupTokenBase::beginEndTag): Changed argument to be const Vector<LChar, 32>&.
35797         (WebCore::MarkupTokenBase::appendToCharacter): Changed argument to be const Vector<LChar, 32>&.
35798         (WebCore::MarkupTokenBase::appendToName): Elimintated inline.
35799         (WebCore::MarkupTokenBase::name): Elimintated inline.
35800         (WebCore::MarkupTokenBase::nameString): Elimintated inline.
35801
35802 2012-10-24  Toni Barzic  <tbarzic@chromium.org>
35803
35804         Crash when trying to write exception message to null console
35805         https://bugs.webkit.org/show_bug.cgi?id=99658
35806
35807         Reviewed by Adam Barth.
35808
35809         DOMWindow::console may return NULL, so we should do a NULL check before adding message to it.
35810         This may happen e.g. if a worker throws an exception just as the document is being replaced in the view.
35811         The exception task could be processes after current window in the frame changes, and console in the document window is nulled.
35812
35813         Test: fast/workers/worker-exception-during-navigation.html
35814
35815         * dom/Document.cpp:
35816         (WebCore::Document::addMessage):
35817
35818 2012-10-24  Cosmin Truta  <ctruta@rim.com>
35819
35820         Incorrect conditional use of LogFTP
35821         https://bugs.webkit.org/show_bug.cgi?id=100260
35822
35823         Reviewed by Alexey Proskuryakov.
35824
35825         Use LogFTP if !LOG_DISABLED, to allow toggling ASSERTIONS_DISABLED_DEFAULT
35826         without breaking the build.
35827
35828         * html/FTPDirectoryDocument.cpp:
35829         (WebCore::FTPDirectoryDocument::FTPDirectoryDocument):
35830
35831 2012-10-23  Alexey Proskuryakov  <ap@apple.com>
35832
35833         Add a strategy for shared workers
35834         https://bugs.webkit.org/show_bug.cgi?id=100165
35835
35836         Reviewed by Brady Eidson.
35837
35838         Also a little bit of alphabetization.
35839
35840         * WebCore.gypi:
35841         * WebCore.vcproj/WebCore.vcproj:
35842         * WebCore.xcodeproj/project.pbxproj:
35843         * platform/PlatformStrategies.h:
35844         * workers/SharedWorkerStrategy.h: Added.
35845
35846 2012-10-24  David Barton  <dbarton@mathscribe.com>
35847
35848         [MathML] Timeouts on linux after r132264
35849         https://bugs.webkit.org/show_bug.cgi?id=100202
35850
35851         Reviewed by Eric Seidel.
35852
35853         When building a stretched operator, such as a large parenthesis or bracket, we need to
35854         check that the extension glyph's height is > 0, to avoid an infinite loop. The 0 height
35855         can occur if the glyph is missing on the host system.
35856
35857         Tested by existing tests.
35858
35859         * rendering/mathml/RenderMathMLOperator.cpp:
35860         (WebCore::RenderMathMLOperator::updateFromElement):
35861
35862 2012-10-24  Parth Patel  <parpatel@rim.com>
35863
35864         [BlackBerry] Extending existing ThreadUnsafe singletons in webkit to
35865         Generic ThreadUnsafe Singleton
35866         https://bugs.webkit.org/show_bug.cgi?id=100145
35867
35868         Reviewed by Rob Buis.
35869
35870         Extending the singletons to generic singleton and changing
35871         getInstance() in IconDatabaseClientBlackBerry to instance()
35872         to match the generic singleton template.
35873
35874         Reviewed Internally by Yong Li.
35875
35876         Tests are not modified and added as there was no behavioural change.
35877
35878         * platform/blackberry/SharedTimerBlackBerry.cpp:
35879         (SharedTimerBlackBerry):
35880         (WebCore):
35881
35882 2012-10-24  Ilya Tikhonovsky  <loislo@chromium.org>
35883
35884         Web Inspector: NMI add instrumentation for ResourceBuffer. It gives us 10mb on gmail
35885         https://bugs.webkit.org/show_bug.cgi?id=100254
35886
35887         Reviewed by Yury Semikhatsky.
35888
35889         * loader/ResourceBuffer.cpp:
35890         (WebCore::ResourceBuffer::reportMemoryUsage):
35891         (WebCore):
35892         * loader/ResourceBuffer.h:
35893         (ResourceBuffer):
35894
35895 2012-10-24  Eric Carlson  <eric.carlson@apple.com>
35896
35897         Allow ports to override text track rendering style
35898         https://bugs.webkit.org/show_bug.cgi?id=97800
35899         <rdar://problem/12044964>
35900
35901         Unreviewed Build fix.
35902         
35903         CGFloat is already a float in a 32-bit build so narrowPrecisionToFloat() is unnecessary
35904
35905         * page/CaptionUserPreferencesMac.mm:
35906         (WebCore::CaptionUserPreferencesMac::captionFontSizeScale):
35907
35908 2012-10-24  Eric Carlson  <eric.carlson@apple.com>
35909
35910         Allow ports to override text track rendering style
35911         https://bugs.webkit.org/show_bug.cgi?id=97800
35912         <rdar://problem/12044964>
35913
35914         Reviewed by Maciej Stachowiak.
35915
35916         * WebCore.exp.in: Export new WebkitSystemInterface functions.
35917         * WebCore.xcodeproj/project.pbxproj: Add CaptionUserPreferences.h, CaptionUserPreferencesMac.mm,
35918             and CaptionUserPreferencesMac.h.
35919
35920         * css/mediaControls.css: Rearrange the caption CSS so it is possible to style the cue window,
35921             background, and text independently.
35922
35923         * html/HTMLMediaElement.cpp:
35924         (WebCore::HTMLMediaElement::HTMLMediaElement): Initialize m_disableCaptions with theme->userPrefersCaptions().
35925         (WebCore::HTMLMediaElement::attach): Register for caption preferences change callbacks.
35926         (WebCore::HTMLMediaElement::detach): Unregister for caption preferences change callbacks.
35927         (WebCore::HTMLMediaElement::userPrefersCaptions): Return theme->userPrefersCaptions().
35928         (WebCore::HTMLMediaElement::userIsInterestedInThisTrackKind): Consider userPrefersCaptions().
35929         (WebCore::HTMLMediaElement::setClosedCaptionsVisible): Move the code that marks all tracks as
35930             un-configured to markCaptionAndSubtitleTracksAsUnconfigured so it can be reused.
35931         (WebCore::HTMLMediaElement::captionPreferencesChanged): New, force a reevaluation of all text tracks.
35932         (WebCore::HTMLMediaElement::markCaptionAndSubtitleTracksAsUnconfigured): New, code moved from 
35933             setClosedCaptionsVisible
35934         * html/HTMLMediaElement.h: Inherit from CaptionPreferencesChangedListener.
35935
35936         * html/shadow/MediaControlElements.cpp:
35937         (WebCore::MediaControlTextTrackContainerElement::updateSizes): Get rid of unnecessary member
35938             variable. Get caption font scale from theme instead of hard coding.
35939         * html/shadow/MediaControlElements.h:
35940
35941         * html/track/TextTrack.cpp:
35942         (WebCore::TextTrack::TextTrack): Change attributes from String to AtomicString.
35943         (WebCore::TextTrack::isValidKindKeyword): Ditto.
35944         (WebCore::TextTrack::setKind): Ditto.
35945         (WebCore::TextTrack::setMode): Ditto.
35946         (WebCore::TextTrack::mode): Ditto.
35947         * html/track/TextTrack.h:
35948         (WebCore::TextTrack::create): Ditto.
35949         (WebCore::TextTrack::kind): Ditto.
35950         (WebCore::TextTrack::label): Ditto.
35951         (WebCore::TextTrack::setLabel): Ditto.
35952         (WebCore::TextTrack::language): Ditto.
35953         (WebCore::TextTrack::setLanguage): Ditto.
35954
35955         * html/track/TextTrackCue.cpp:
35956         (WebCore::TextTrackCueBox::TextTrackCueBox): Set the shadow pseudo id.
35957         (WebCore::TextTrackCueBox::textTrackCueBoxShadowPseudoId): New, class method to return the 
35958             shadow pseudo id so it can be used elsewhere.
35959         (WebCore::TextTrackCueBox::shadowPseudoId): Call textTrackCueBoxShadowPseudoId.
35960         (WebCore::TextTrackCue::pastNodesShadowPseudoId): New, class method to return the 
35961             shadow pseudo id so it can be used elsewhere.
35962         (WebCore::TextTrackCue::futureNodesShadowPseudoId): Ditto.
35963         (WebCore::TextTrackCue::updateDisplayTree):
35964         * html/track/TextTrackCue.h:
35965
35966         * page/CaptionUserPreferences.h: Added.
35967         * page/CaptionUserPreferencesMac.h: Added.
35968         * page/CaptionUserPreferencesMac.mm: Added.
35969         (WebCore::userCaptionPreferencesChangedNotificationCallback):
35970         (WebCore::CaptionUserPreferencesMac::CaptionUserPreferencesMac):
35971         (WebCore::CaptionUserPreferencesMac::~CaptionUserPreferencesMac):
35972         (WebCore::CaptionUserPreferencesMac::userHasCaptionPreferences): New, passthrough to WKSI function.
35973         (WebCore::CaptionUserPreferencesMac::userPrefersCaptions): Ditto.
35974         (WebCore::CaptionUserPreferencesMac::captionsWindowColor): Return Color with user's caption window color preference.
35975         (WebCore::CaptionUserPreferencesMac::captionsBackgroundColor): Return Color with user's caption 
35976             background color preference.
35977         (WebCore::CaptionUserPreferencesMac::captionsTextColor): Return Color with user's caption text color preference.
35978         (WebCore::CaptionUserPreferencesMac::captionsEdgeColorForTextColor): Return Color for text edge effect.
35979         (WebCore::CaptionUserPreferencesMac::cssPropertyWithTextEdgeColor): Return String with CSS to set a text-shadow
35980             or webkit-text-stroke property.
35981         (WebCore::CaptionUserPreferencesMac::cssColorProperty): Return a String with css to set a property 
35982             with a color value.
35983         (WebCore::CaptionUserPreferencesMac::captionsTextEdgeStyle): Return a String with css to style caption 
35984             text with the user's preferred text edge stye.
35985         (WebCore::CaptionUserPreferencesMac::captionsDefaultFont): Return a String with css to style caption
35986             text with the user's preferred font.
35987         (WebCore::CaptionUserPreferencesMac::captionsStyleSheetOverride): Return a String with css to style captions
35988             with the user's preferred style.
35989         (WebCore::CaptionUserPreferencesMac::captionFontSizeScale): Return the user's preferred caption font scale.
35990         (WebCore::CaptionUserPreferencesMac::captionPreferencesChanged): Notify listeners of caption preference change.
35991         (WebCore::CaptionUserPreferencesMac::registerForCaptionPreferencesChangedCallbacks): Add a caption preferences 
35992             changes listener.
35993         (WebCore::CaptionUserPreferencesMac::unregisterForCaptionPreferencesChangedCallbacks): Remove a caption preferences
35994             changes listener.
35995         (WebCore::CaptionUserPreferencesMac::updateCaptionStyleSheetOveride): New, if theme has a captions style sheet override,
35996             inject it into the current page group, otherwise remove injected sheet.
35997
35998         * page/PageGroup.cpp:
35999         (WebCore::PageGroup::captionPreferences):
36000         (WebCore::PageGroup::registerForCaptionPreferencesChangedCallbacks): New, passthrough to platform specific function
36001             of the same name.
36002         (WebCore::PageGroup::unregisterForCaptionPreferencesChangedCallbacks): Ditto.
36003         (WebCore::PageGroup::userPrefersCaptions): Ditto.
36004         (WebCore::PageGroup::userHasCaptionPreferences): Ditto.
36005         (WebCore::PageGroup::captionFontSizeScale): Ditto.
36006         * page/PageGroup.h:
36007
36008         * platform/mac/WebCoreSystemInterface.h: Updated.
36009         * platform/mac/WebCoreSystemInterface.mm: Ditto.
36010
36011 2012-10-24  Vsevolod Vlasov  <vsevik@chromium.org>
36012
36013         Web Inspector: Introduce workspace provider as a content providing backend for project.
36014         https://bugs.webkit.org/show_bug.cgi?id=100244
36015
36016         Reviewed by Pavel Feldman.
36017
36018         Introduced WorkspaceProvider interface as a content providing backend for project.
36019         Added NetworkWorkspaceProvider as a network based (default) implementation.
36020
36021         * WebCore.gypi:
36022         * WebCore.vcproj/WebCore.vcproj:
36023         * inspector/compile-front-end.py:
36024         * inspector/front-end/CompilerScriptMapping.js:
36025         (WebInspector.CompilerScriptMapping):
36026         * inspector/front-end/DebuggerScriptMapping.js:
36027         (WebInspector.DebuggerScriptMapping):
36028         * inspector/front-end/NetworkUISourceCodeProvider.js:
36029         (WebInspector.NetworkUISourceCodeProvider):
36030         (WebInspector.NetworkUISourceCodeProvider.prototype._parsedScriptSource):
36031         (WebInspector.NetworkUISourceCodeProvider.prototype._resourceAdded):
36032         (WebInspector.NetworkUISourceCodeProvider.prototype._addFile):
36033         * inspector/front-end/NetworkWorkspaceProvider.js: Added.
36034         (WebInspector.NetworkWorkspaceProvider):
36035         (WebInspector.NetworkWorkspaceProvider.prototype.requestFileContent):
36036         (WebInspector.NetworkWorkspaceProvider.prototype.setFileContent):
36037         (WebInspector.NetworkWorkspaceProvider.prototype.searchInFileContent):
36038         (WebInspector.NetworkWorkspaceProvider.prototype.addFile):
36039         (WebInspector.NetworkWorkspaceProvider.prototype.removeFile):
36040         (WebInspector.NetworkWorkspaceProvider.prototype.reset):
36041         * inspector/front-end/SASSSourceMapping.js:
36042         (WebInspector.SASSSourceMapping):
36043         (_bindUISourceCode):
36044         * inspector/front-end/ScriptSnippetModel.js:
36045         (WebInspector.ScriptSnippetModel):
36046         (WebInspector.ScriptSnippetModel.prototype._addScriptSnippet):
36047         * inspector/front-end/WebKit.qrc:
36048         * inspector/front-end/Workspace.js:
36049         (WebInspector.FileDescriptor):
36050         (WebInspector.WorkspaceProvider):
36051         (WebInspector.WorkspaceProvider.prototype.requestFileContent):
36052         (WebInspector.WorkspaceProvider.prototype.searchInFileContent):
36053         (WebInspector.WorkspaceProvider.prototype.addEventListener):
36054         (WebInspector.WorkspaceProvider.prototype.removeEventListener):
36055         (WebInspector.Project):
36056         (WebInspector.Project.prototype.reset):
36057         (WebInspector.Project.prototype._fileAdded):
36058         (WebInspector.Project.prototype._fileRemoved):
36059         (WebInspector.Project.prototype.requestFileContent):
36060         (WebInspector.Project.prototype.searchInFileContent):
36061         (WebInspector.Workspace):
36062         (WebInspector.Workspace.prototype.addProject):
36063         (WebInspector.Workspace.prototype.project):
36064         * inspector/front-end/inspector.html:
36065         * inspector/front-end/inspector.js:
36066
36067 2012-10-24  Nikita Vasilyev  <me@elv1s.ru>
36068
36069         Web Inspector: Styles pane: Don't select whole value when I select just a part
36070         https://bugs.webkit.org/show_bug.cgi?id=100242
36071
36072         Reviewed by Alexander Pavlov.
36073
36074         * inspector/front-end/StylesSidebarPane.js:
36075         (WebInspector.StylePropertiesSection.prototype._handleEmptySpaceClick):
36076         (WebInspector.StylePropertyTreeElement.prototype):
36077
36078 2012-10-24  Vsevolod Vlasov  <vsevik@chromium.org>
36079
36080         Web Inspector: UiSourceCode should rely on the workspace as a content provider.
36081         https://bugs.webkit.org/show_bug.cgi?id=100216
36082
36083         Reviewed by Pavel Feldman.
36084
36085         Workspace is now passed to UISourceCode to be used as a content provider.
36086         Content providers are now stored in the workspace/project.
36087         Next step would be to move content providers to workspace providers.
36088
36089         * inspector/front-end/BreakpointManager.js:
36090         (WebInspector.BreakpointManager.breakpointStorageId):
36091         * inspector/front-end/UISourceCode.js:
36092         (WebInspector.UISourceCode):
36093         (WebInspector.UISourceCode.prototype.contentType):
36094         (WebInspector.UISourceCode.prototype.requestContent):
36095         (WebInspector.UISourceCode.prototype.requestOriginalContent):
36096         (WebInspector.UISourceCode.prototype._commitContent):
36097         (WebInspector.UISourceCode.prototype.searchInContent):
36098         * inspector/front-end/Workspace.js:
36099         (WebInspector.WorkspaceController.prototype._mainFrameNavigated):
36100         (WebInspector.Project):
36101         (WebInspector.Project.prototype.addUISourceCode):
36102         (WebInspector.Project.prototype.removeUISourceCode):
36103         (WebInspector.Project.prototype.uiSourceCodes):
36104         (WebInspector.Project.prototype.requestFileContent):
36105         (WebInspector.Project.prototype.searchInFileContent):
36106         (WebInspector.Workspace):
36107         (WebInspector.Workspace.prototype.addTemporaryUISourceCode):
36108         (WebInspector.Workspace.prototype.removeTemporaryUISourceCode):
36109         (WebInspector.Workspace.prototype.reset):
36110
36111 2012-10-24  Zeno Albisser  <zeno@webkit.org>
36112
36113         Implement GraphicsSurface for Windows.
36114         https://bugs.webkit.org/show_bug.cgi?id=98147
36115
36116         Reviewed by Kenneth Rohde Christiansen.
36117
36118         * Target.pri:
36119             Include GraphicsSurfaceWin.cpp in SOURCES on Windows.
36120         * platform/graphics/surfaces/GraphicsSurface.h:
36121             Add typedef for PlatformGraphicsSurface on Windows.
36122         * platform/graphics/surfaces/GraphicsSurfaceToken.h:
36123             Add typedef for BufferHandle on Windows.
36124         (GraphicsSurfaceToken):
36125         * platform/graphics/surfaces/win/GraphicsSurfaceWin.cpp: Added.
36126             The GraphicsSurface implementation on Windows relies on the
36127             availability of ANGLE and the EGL_ANGLE_query_surface_pointer extension.
36128             For Qt this requirements are implicitly satisfied, when Qt is built
36129             on Windows and QT_CONFIG contains OpenGLES2.
36130             The GraphicsSurface then renders a given texture onto an offscreen
36131             pixel buffer surface, queries the surface pointer using the
36132             EGL_ANGLE_query_surface_pointer extension, and transmits the received
36133             surface pointer (share handle) over IPC.
36134             On the UIProcess side, the surface pointer can then be resolved
36135             using eglCreatePbufferFromClientBuffer.
36136         (WebCore):
36137         (WebCore::loadShader):
36138             Initialize the shaders needed for drawing onto the GraphicsSurface.
36139         (GraphicsSurfacePrivate):
36140         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
36141             In case of the instance being on the WebProcess side,
36142             create an EGLContext that shares the texture objects with the provided
36143             share context. Also create two pixel buffer surfaces, one as front- and
36144             one as backbuffer.
36145             Query the surface pointers for the pixel buffer surfaces and initialize
36146             the GraphicsSurfaceToken that can be passed over IPC later.
36147         (WebCore::GraphicsSurfacePrivate::~GraphicsSurfacePrivate):
36148             Release all aquired resources and destroy the pixel buffer surfaces.
36149             Also close the EGL-Display connection.
36150         (WebCore::GraphicsSurfacePrivate::copyFromTexture):
36151             Make the belonging context current on the back buffer surface
36152             and use drawTexture() to draw the provided texture onto the GraphicsSurface.
36153         (WebCore::GraphicsSurfacePrivate::makeCurrent):
36154             Save the previously current context, then make the context belonging
36155             to the GraphicsSurface current.
36156         (WebCore::GraphicsSurfacePrivate::doneCurrent):
36157             Restore the context that was current before calling makeCurrent().
36158         (WebCore::GraphicsSurfacePrivate::swapBuffers):
36159             Swap front and back buffer surfaces and handles.
36160         (WebCore::GraphicsSurfacePrivate::token):
36161         (WebCore::GraphicsSurfacePrivate::frontBufferTextureID):
36162             This function is meant to be called from the UIProcess side.
36163             If no front buffer surface has been created before for the current
36164             front buffer handle, one will be created.
36165             Then eglBindTexImage will be used to actually bind the current
36166             front buffer surface to a texture as a source for drawing.
36167         (WebCore::GraphicsSurfacePrivate::initialFrontBufferShareHandle):
36168         (WebCore::GraphicsSurfacePrivate::frontBufferShareHandle):
36169         (WebCore::GraphicsSurfacePrivate::backBufferShareHandle):
36170         (WebCore::GraphicsSurfacePrivate::releaseFrontBufferTexture):
36171             Free the resources related to the front buffer surface.
36172             On the UIProcess side we never actually bind the back buffer.
36173         (WebCore::GraphicsSurfacePrivate::initializeShaderProgram):
36174             Initialize and link the shader programs necessary for drawing
36175             onto the GraphicsSurface.
36176         (WebCore::GraphicsSurfacePrivate::createSurfaceFromShareHandle):
36177             Creates a single pixel buffer surface from a share Handle.
36178             This function will be called on the UIProcess side,
36179             for the front buffer handle, whenever the buffers have been swapped.
36180         (WebCore::GraphicsSurfacePrivate::drawTexture):
36181             The WebProcess uses this function to draw a given
36182             texture onto the GraphicsSurface's back buffer.
36183         (WebCore::GraphicsSurface::platformExport):
36184         (WebCore::GraphicsSurface::platformGetTextureID):
36185         (WebCore::GraphicsSurface::platformCopyToGLTexture):
36186         (WebCore::GraphicsSurface::platformCopyFromTexture):
36187         (WebCore::GraphicsSurface::platformPaintToTextureMapper):
36188             Uses TextureMapperGL::drawTexture() to draw the front buffer texture
36189             to the TextureMapper on the UIProcess side.
36190         (WebCore::GraphicsSurface::platformFrontBuffer):
36191         (WebCore::GraphicsSurface::platformSwapBuffers):
36192         (WebCore::GraphicsSurface::platformCreate):
36193         (WebCore::GraphicsSurface::platformImport):
36194         (WebCore::GraphicsSurface::platformLock):
36195         (WebCore::GraphicsSurface::platformUnlock):
36196         (WebCore::GraphicsSurface::platformDestroy):
36197
36198 2012-09-27  Yury Semikhatsky  <yurys@chromium.org>
36199
36200         Web Inspector: provide memory instrumentation for ListHashSet
36201         https://bugs.webkit.org/show_bug.cgi?id=97786
36202
36203         Reviewed by Vsevolod Vlasov.
36204
36205         Switched existing usages of addListHashSet to the generic instrumentation mechanism
36206         as it should work just just fine now that there is a memory instrumentation of
36207         ListHashSet.
36208
36209         * dom/DocumentEventQueue.cpp:
36210         * dom/DocumentStyleSheetCollection.cpp:
36211         (WebCore::DocumentStyleSheetCollection::reportMemoryUsage):
36212         * loader/cache/CachedResourceLoader.cpp:
36213         (WebCore::CachedResourceLoader::reportMemoryUsage):
36214
36215 2012-10-24  Charles Wei  <charles.wei@torchmobile.com.cn>
36216
36217         [BlackBerry] Credentials not re-used for a redirected request to the same domain
36218         https://bugs.webkit.org/show_bug.cgi?id=100193
36219
36220         Reviewed by George Staikos.
36221
36222         We should store the credentials in the redirection response handler, if the request is challenged.
36223         Because the redirect response suggests the authentication succeeds. 
36224
36225         Test: http://browsertest01.rim.net/authbasic
36226
36227         * platform/network/blackberry/NetworkJob.cpp:
36228         (WebCore::NetworkJob::handleRedirect):
36229
36230 2012-10-24  Alexander Pavlov  <apavlov@chromium.org>
36231
36232         Web Inspector: Implement CSS reload upon related SASS resource saving
36233         https://bugs.webkit.org/show_bug.cgi?id=98024
36234
36235         Reviewed by Vsevolod Vlasov.
36236
36237         SASS-generated debug info in CSS is parsed to find out which SASS files contributed to this stylesheet.
36238         Upon SASS file save in the Sources panel, all affected external CSS stylesheets are reloaded to update
36239         the page styles (presuming that SASS is running in the "watch" mode during the development cycle).
36240
36241         * English.lproj/localizedStrings.js:
36242         * inspector/front-end/SASSSourceMapping.js:
36243         (WebInspector.SASSSourceMapping):
36244         (WebInspector.SASSSourceMapping.prototype._fileSaveFinished.callback):
36245         (WebInspector.SASSSourceMapping.prototype._reloadCSS):
36246         (_bindUISourceCode):
36247         (_addCSSURLforSASSURL):
36248         * inspector/front-end/Settings.js:
36249         * inspector/front-end/SettingsScreen.js:
36250         (WebInspector.GenericSettingsTab):
36251
36252 2012-10-23  Yury Semikhatsky  <yurys@chromium.org>
36253
36254         Memory instrumentation: don't count agent-specific front-ends separately
36255         https://bugs.webkit.org/show_bug.cgi?id=100087
36256
36257         Reviewed by Alexander Pavlov.
36258
36259         Pointers to domain-specific inspector front-end interfaces are reported as
36260         weak pointers instead of members to avoid double-counting.
36261
36262         Test by comparing set of reported instrumented objects with the set of objects
36263         allocated by tcmalloc.
36264
36265         * inspector/InspectorDOMStorageAgent.cpp:
36266         (WebCore::InspectorDOMStorageAgent::reportMemoryUsage):
36267         * inspector/InspectorDOMStorageResource.cpp:
36268         (WebCore::InspectorDOMStorageResource::reportMemoryUsage):
36269         * inspector/InspectorProfilerAgent.cpp:
36270         (WebCore::InspectorProfilerAgent::reportMemoryUsage):
36271
36272 2012-10-23  Christophe Dumez  <christophe.dumez@intel.com>
36273
36274         Regression(r132303) Broke debug build when SHADOW_DOM is enabled but STYLE_SCOPED is disabled
36275         https://bugs.webkit.org/show_bug.cgi?id=100203
36276
36277         Unreviewed Build fix.
36278
36279         Fix compilation error in StyleResolver.h when SHADOW_DOM flag is
36280         set and STYLE_SCOPED is not.
36281
36282         No new tests, no behavior change.
36283
36284         * css/StyleResolver.h:
36285         (WebCore::StyleResolver::ensureScopeResolver):
36286
36287 2012-10-23  Andreas Kling  <kling@webkit.org>
36288
36289         Remove specialized hash traits for GlyphPages.
36290         <http://webkit.org/b/100185>
36291
36292         Reviewed by Dan Bernstein.
36293
36294         Now that the default minimum table size has been lowered for all tables, there's no need
36295         for this specialization anymore.
36296
36297         * platform/graphics/FontFallbackList.h:
36298         (FontFallbackList):
36299
36300 2012-10-23  Kent Tamura  <tkent@chromium.org>
36301
36302         Multiple fields input UI: Don't use CSS properties for physical direction
36303         https://bugs.webkit.org/show_bug.cgi?id=100195
36304
36305         Reviewed by Kentaro Hara.
36306
36307         CSS declarations such as "padding: 0 0 0 1px;" "margin-left: 0.2em;" are
36308         not direction-neutral, and makes unexpected appearance in RTL. We should
36309         use -webkit-padding-start or -webkit-margin-start.
36310
36311         No new tests. Covered by date-multiple-fields-appearance-l10n.html and
36312         month-multiple-fields-appearance-l10n.html
36313
36314         * css/html.css:
36315         (input[type="date"]): Use padding:0 and -webkit-padding-start:1px;
36316         (input[type="datetime"]): Ditto.
36317         (input[type="datetime-local"]): Ditto.
36318         (input[type="month"]): Ditto.
36319         (input[type="time"]): Ditto.
36320         (input[type="week"]): Ditto.
36321         (input[type="week"]::-webkit-inner-spin-button):
36322         Use -webkit-margin-start. Also use an integral pixel size instead of
36323         avoid a fractional relative size to avoid subpixel layout rounding.
36324
36325 2012-10-23  Dan Bernstein  <mitz@apple.com>
36326
36327         The font cache evicts inactive font data too aggressively when not under memory pressure
36328         https://bugs.webkit.org/show_bug.cgi?id=100194
36329
36330         Reviewed by Sam Weinig.
36331
36332         Increasing the number of inactive font data objects the cache may hold increases the hit
36333         rate, leading to improved page load performance. When memory pressure is detected,
36334         MemoryPressureHandler evicts all inactive objects, regardless of the limits we are
36335         increasing here.
36336
36337         * platform/graphics/FontCache.cpp:
36338         (WebCore): Increased the maximum number of inactive font data objects in the cache from 50
36339         to 225, and the number of objects to evict once the limit is met from 20 to 25.
36340
36341 2012-10-23  Takashi Sakamoto  <tasak@google.com>
36342
36343         [Shadow DOM] Needs @host rule for ShadowDOM styling
36344         https://bugs.webkit.org/show_bug.cgi?id=88606
36345
36346         Reviewed by Hajime Morita.
36347
36348         Implemented @host-@rules according to the shadow dom spec:
36349         http://dvcs.w3.org/hg/webcomponents/raw-file/tip/spec/shadow/index.html#host-at-rule
36350         The design doc is:
36351         https://docs.google.com/document/d/1P2yorchF8lci2sccr-mVSRf2dtvjKeiuyQWzCB2bEA8/edit
36352
36353         Test: fast/dom/shadow/athost-atrules.html
36354
36355         * css/CSSGrammar.y.in:
36356         Added rules for parsing @host @-rules.
36357         * css/CSSParser.cpp:
36358         (WebCore::CSSParser::detectAtToken):
36359         Added a new token "@host".
36360         (WebCore::CSSParser::createHostRule):
36361         Added a new method to create an @host @-rule, which is invoked from
36362         (WebCore):
36363         * css/CSSParser.h:
36364         Added a declaration of the above new method: createHostRule.
36365         * css/CSSPropertySourceData.h:
36366         Added HOST_RULE to enum Type.
36367         * css/RuleSet.cpp:
36368         (WebCore::RuleData::RuleData):
36369         Modified multiple bool arguments into one argument. Now it
36370         uses combinations of values from enum AddRuleFlags.
36371         (WebCore::RuleSet::addRule):
36372         (WebCore::RuleSet::addRegionRule):
36373         (WebCore::RuleSet::addStyleRule):
36374         Updated according to the RuleData's change.
36375         Modified to Invoke increaseSpecificity if the given rule is @host
36376         @-rule.
36377         (WebCore::RuleSet::addRulesFromSheet):
36378         Invoked addHostRule if the given rule is @host @-rule.
36379         * css/RuleSet.h:
36380         (RuleData):
36381         (WebCore::RuleData::increaseSpecificity):
36382         Added a new method to increase selector's specificity. This method is
36383         used to make @host @-rules' specificity larger than normal author
36384         rules' specificity.
36385         (RuleSet):
36386         * css/StyleResolver.cpp:
36387         (WebCore::makeRuleSet):
36388         (WebCore::StyleResolver::addHostRule):
36389         A wrapper method to invoke StyleScopeResolver::addHostRule. The method
36390         is used to make only StyleResolver know an implementation detail about
36391         class StyleScopeResolver.
36392         (WebCore::StyleResolver::appendAuthorStylesheets):
36393         Updated according to the RuleData's change.
36394         (WebCore::StyleResolver::styleSharingCandidateMatchesHostRules):
36395         A new method to find matched host rules when an element is given.
36396         This method invokes
36397         StyleScopeResolver::styleSharingCandidateMatchesHostRules to find
36398         matched host rules.
36399         (WebCore):
36400         (WebCore::StyleResolver::matchHostRules):
36401         A new method to find matched host rules when an element is given.
36402         This method invokes StyleScopeResolver::matchHostRules to find
36403         matched host rules.
36404         (WebCore::StyleResolver::matchScopedAuthorRules):
36405         Modified to invoke matchHostRules.
36406         (WebCore::StyleResolver::locateSharedStyle):
36407         Disable sibling style cache if the given element is a shadow host and
36408         any @host @-rules are applied to the element.
36409         * css/StyleResolver.h:
36410         (WebCore::StyleResolver::ensureScopeResolver):
36411         If no scopeResolver is created, create and return the instance.
36412         If created, just return the instance.
36413         (StyleResolver):
36414         * css/StyleRule.cpp:
36415         (WebCore::StyleRuleBase::reportMemoryUsage):
36416         (WebCore::StyleRuleBase::destroy):
36417         (WebCore::StyleRuleBase::copy):
36418         (WebCore::StyleRuleBase::createCSSOMWrapper):
36419         (WebCore::StyleRuleHost::StyleRuleHost):
36420         Implemented class StyleRuleHost. The class is almost the same as
36421         StyleRuleBlock except type.
36422         (WebCore):
36423         * css/StyleRule.h:
36424         (WebCore::StyleRuleBase::isHostRule):
36425         (StyleRuleHost):
36426         (WebCore::StyleRuleHost::create):
36427         (WebCore::StyleRuleHost::copy):
36428         (WebCore):
36429         * css/StyleScopeResolver.cpp:
36430         (WebCore::StyleScopeResolver::ensureAtHostRuleSetFor):
36431         A new method to create a new RuleSet for the given shadow root.
36432         (WebCore):
36433         (WebCore::StyleScopeResolver::atHostRuleSetFor):
36434         A new private inline method to obtain @host @-rules declared in
36435         the given shadow root.
36436         (WebCore::StyleScopeResolver::addHostRule):
36437         Added a new method to register @host @-rules with shadow roots.
36438         (WebCore::StyleScopeResolver::styleSharingCandidateMatchesHostRules):
36439         A new method to find whether any @host @-rules are applied to
36440         the given host element.
36441         (WebCore::StyleScopeResolver::matchHostRules):
36442         A new method to find matched rules for the given host element.
36443         (WebCore::StyleScopeResolver::reportMemoryUsage):
36444         * css/StyleScopeResolver.h:
36445         (WebCore):
36446         (StyleScopeResolver):
36447         * css/StyleSheetContents.cpp:
36448         (WebCore::childRulesHaveFailedOrCanceledSubresources):
36449
36450 2012-10-23  Andreas Kling  <kling@webkit.org>
36451
36452         REGRESSION(r130643): ASSERTION FAILED: result.iterator != end() below PluginDatabase::add
36453         <http://webkit.org/b/100065>
36454
36455         Reviewed by Anders Carlsson.
36456
36457         Restore the pre-r130643 hash table size for PluginDatabase to prevent these easily reproducible
36458         collisions. This will need a proper fix at some point.
36459
36460         * plugins/PluginDatabase.h:
36461         * plugins/PluginPackage.h:
36462         (PluginPackageHashTraits):
36463
36464 2012-10-23  Simon Fraser  <simon.fraser@apple.com>
36465
36466         Allow tests to run with a tile cache, and optionally dump the tile cache via layerTreeAsText()
36467         https://bugs.webkit.org/show_bug.cgi?id=100159
36468
36469         Reviewed by Tim Horton.
36470
36471         Add a LAYER_TREE_INCLUDES_PAGE_TILE_CACHE flag for layerTreeAsText(), and plumb it
36472         through to GraphicsLayerCA, which dumps the TiledBacking tile coverage rect.
36473
36474         Test: platform/mac/tiled-drawing/use-tiled-drawing.html
36475
36476         * page/Frame.h:
36477         * platform/graphics/GraphicsLayer.cpp:
36478         (showGraphicsLayerTree):
36479         * platform/graphics/GraphicsLayer.h:
36480         (WebCore::GraphicsLayer::tiledBacking):
36481         * platform/graphics/TiledBacking.h:
36482         * platform/graphics/ca/GraphicsLayerCA.cpp:
36483         (WebCore::GraphicsLayerCA::tiledBacking):
36484         (WebCore::GraphicsLayerCA::dumpAdditionalProperties):
36485         * platform/graphics/ca/GraphicsLayerCA.h:
36486         (GraphicsLayerCA):
36487         * platform/graphics/ca/mac/TileCache.h:
36488         (WebCore::TileCache::tileCoverageRect):
36489         (TileCache):
36490         * platform/graphics/ca/mac/TileCache.mm:
36491         (WebCore::TileCache::computeTileCoverageRect):
36492         (WebCore::TileCache::revalidateTiles):
36493         * rendering/RenderLayerCompositor.cpp:
36494         (WebCore::RenderLayerCompositor::layerTreeAsText):
36495         * testing/Internals.cpp:
36496         (WebCore::Internals::layerTreeAsText):
36497         * testing/Internals.h:
36498         * testing/Internals.idl:
36499
36500 2012-10-23  Simon Fraser  <simon.fraser@apple.com>
36501
36502         Flush pending GraphicsLayer changes when reattaching compositing layers if necessary
36503         https://bugs.webkit.org/show_bug.cgi?id=100187
36504         <rdar://problem/12546770>
36505
36506         Reviewed by Dan Bernstein.
36507
36508         Fix a regression from r131940. That revision changed RenderLayerCompositor::flushPendingLayerChanges()
36509         to bail if the root layer is unattached, which indicates that we're in the page cache, or in a
36510         background tab. However, that dropped the layer flush on the floor, so that any subsequent changes
36511         to GraphicsLayerCAs would just pile up and never get flushed. This was most evident on pages
36512         that require frequent flushing, such as those running animated GIFs.
36513         
36514         Fix by setting a flag in flushPendingLayerChanges() if we're unattached. Consult the flag
36515         when re-attaching the root layer, and if it's set, flush the GraphicsLayers.
36516         
36517         Not testable because we can't test detaching and re-adding web views in DRT/WTR.
36518
36519         * rendering/RenderLayerCompositor.cpp:
36520         (WebCore::RenderLayerCompositor::RenderLayerCompositor): Initialize m_shouldFlushOnReattach to false.
36521         (WebCore::RenderLayerCompositor::flushPendingLayerChanges): If the root layer attachment
36522         is RootLayerUnattached, set the m_shouldFlushOnReattach flag before returning.
36523         (WebCore::RenderLayerCompositor::attachRootLayer): If m_shouldFlushOnReattach, flush the layers,
36524         saying that we're the flush root.
36525         * rendering/RenderLayerCompositor.h:
36526         (RenderLayerCompositor): Add m_shouldFlushOnReattach flag.
36527
36528 2012-10-23  Sheriff Bot  <webkit.review.bot@gmail.com>
36529
36530         Unreviewed, rolling out r132276.
36531         http://trac.webkit.org/changeset/132276
36532         https://bugs.webkit.org/show_bug.cgi?id=100189
36533
36534         It broke the Qt-WK2 build intentionally (Requested by
36535         Ossy_night on #webkit).
36536
36537         * page/Frame.h:
36538         * platform/graphics/GraphicsLayer.cpp:
36539         (showGraphicsLayerTree):
36540         * platform/graphics/GraphicsLayer.h:
36541         (WebCore::GraphicsLayer::tiledBacking):
36542         * platform/graphics/TiledBacking.h:
36543         * platform/graphics/ca/GraphicsLayerCA.cpp:
36544         (WebCore::GraphicsLayerCA::tiledBacking):
36545         (WebCore::GraphicsLayerCA::dumpAdditionalProperties):
36546         * platform/graphics/ca/GraphicsLayerCA.h:
36547         (GraphicsLayerCA):
36548         * platform/graphics/ca/mac/TileCache.h:
36549         * platform/graphics/ca/mac/TileCache.mm:
36550         (WebCore::TileCache::tileCoverageRect):
36551         (WebCore::TileCache::revalidateTiles):
36552         * rendering/RenderLayerCompositor.cpp:
36553         (WebCore::RenderLayerCompositor::layerTreeAsText):
36554         * testing/Internals.cpp:
36555         (WebCore::Internals::layerTreeAsText):
36556         * testing/Internals.h:
36557         * testing/Internals.idl:
36558
36559 2012-10-23  Philip Rogers  <pdr@google.com>
36560
36561         Add extra check for data() in PageSerializer.
36562         https://bugs.webkit.org/show_bug.cgi?id=99102
36563
36564         Reviewed by Eric Seidel.
36565
36566         The image returned from imageForRenderer() does not contain the raw SVG data
36567         so this patch adds a check for image->image()->data() before writing SVG
36568         in PageSerializer::addImageToResources.
36569
36570         Covered by existing test WebPageNewSerializeTest.SVGImageDontCrash.
36571
36572         * page/PageSerializer.cpp:
36573         (WebCore::PageSerializer::addImageToResources):
36574
36575 2012-10-23  Kent Tamura  <tkent@chromium.org>
36576
36577         Move appendAsLDMLLiteral in LocaleWin.cpp to a common place
36578         https://bugs.webkit.org/show_bug.cgi?id=100129
36579
36580         Reviewed by Kentaro Hara.
36581
36582         We're going to use appendAsLDMLLiteral in other code, and it is
36583         related to DateTimeFormat class.  So we move it to DateTimeFormat
36584         class as quoteAndAppendLiteral.
36585
36586         No new tests because of no behavior change.
36587
36588         * platform/text/DateTimeFormat.cpp:
36589         (WebCore::DateTimeFormat::quoteAndAppendLiteral):
36590         Moved from LocaleWin.cpp
36591         * platform/text/DateTimeFormat.h:
36592         Declare StringBuilder by wtf/Forward.h. It also declares String.
36593         (DateTimeFormat): Declare quoteAndAppendLiteral.
36594         * platform/text/LocaleWin.cpp:
36595         (WebCore): Move appendLDMLLiteral to DateTimeFormat.
36596         (WebCore::convertWindowsDateFormatToLDML):
36597         Follow the moving.
36598
36599 2012-10-23  Kent Tamura  <tkent@chromium.org>
36600
36601         REGRESSION(r131421): Text baseline is not aligned in some locales
36602         https://bugs.webkit.org/show_bug.cgi?id=100088
36603
36604         Reviewed by Hajime Morita.
36605
36606         Before this patch, the element with ::-webkit-datetime-edit had
36607         -webkit-align-items:center. It was incorrect at all because it
36608         ignores baselines of each of inner fields. We need to change it to
36609         -webkit-align-items:baseline, or stop using -webkit-flex.
36610
36611         However -webkit-align-items:baseline doesn't work because a spin
36612         button element in the element doesn't have the baseline. If we
36613         specified -webkit-align-items:baseline, the spin button would
36614         shift up.
36615
36616         So, we change the element structure for multiple fields input
36617         elements. Before this patch, the structure was:
36618
36619         input
36620           |
36621            - ::-webkit-date-and-time-container (flex cotainer)
36622              |
36623              |- ::-webkit-datetime-edit (has flexibility in date-and-time-container, also this is a flex container)
36624              |  |- ::-webkit-datetime-edit-foo
36625              |  |      :
36626              |  |
36627              |  |- ::-webkit-date-time-edit-gap  (has flexibility in datetime-edit)
36628              |   - ::-webkit-inne-spin-button
36629               - ::-webkit-calendar-picker-indicator
36630
36631         After the patch, the structure will be:
36632
36633         input
36634           |
36635            - ::-webkit-date-and-time-container (flexible box)
36636              |
36637              |- ::-webkit-datetime-edit (has flexibility in date-and-time-container)
36638              |  |- ::-webkit-datetime-edit-foo
36639              |  |      :
36640              |  |
36641              |
36642              |- ::-webkit-inne-spin-button
36643               - ::-webkit-calendar-picker-indicator
36644
36645         Because the spin button owner is date-and-time-container, we don't
36646         need to make the datetime-edit element a flex container.
36647
36648         Also, we had rounding error by subpixel layout. To avoid it, we
36649         stop using fractional paddings.
36650
36651         In order to implement this, we need to change the SpinButtonOwner
36652         interface provider from DateTimeEditElement to
36653         BaseMultipleFieldsDateAndTimeInputType.
36654
36655         No new tests. Covered by month-multiple-fields-appearance-l10n.html.
36656
36657         * css/html.css:
36658         (input::-webkit-datetime-edit): Stop making this a flex
36659         container. Inner fields in this use the single baseline.
36660         (input::-webkit-datetime-edit-ampm-field):
36661         Don't use fractional paddings to avoid rounding erros of subpixel
36662         layout.  Use integral margin instead to avoid overwrap of focus
36663         ring and background-color of the field.
36664         (input::-webkit-datetime-edit-day-field): Ditto.
36665         (input::-webkit-datetime-edit-hour-field): Ditto.
36666         (input::-webkit-datetime-edit-millisecond-field): Ditto.
36667         (input::-webkit-datetime-edit-minute-field): Ditto.
36668         (input::-webkit-datetime-edit-month-field): Ditto.
36669         (input::-webkit-datetime-edit-second-field): Ditto.
36670         (input::-webkit-datetime-edit-week-field): Ditto.
36671         (input::-webkit-datetime-edit-year-field): Ditto.
36672         (input::-webkit-date-and-time-container): Ditto.
36673
36674         * html/BaseMultipleFieldsDateAndTimeInputType.h:
36675         (BaseMultipleFieldsDateAndTimeInputType): Overrides
36676         SpinButtonOwner functions, and add m_spinButtonElement.
36677         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
36678         (WebCore::BaseMultipleFieldsDateAndTimeInputType::focusAndSelectSpinButtonOwner):
36679         Just delegate to DateTimeEditElement::focusIfNoFocus.
36680         (WebCore::BaseMultipleFieldsDateAndTimeInputType::shouldSpinButtonRespondToMouseEvents):
36681         Moved from DateTimeEditElement::shouldSpinButtonRespondToMouseEvents.
36682         (WebCore::BaseMultipleFieldsDateAndTimeInputType::shouldSpinButtonRespondToWheelEvents):
36683         Moved from DateTimeEditElement::shouldSpinButtonRespondToWheelEvents.
36684         (WebCore::BaseMultipleFieldsDateAndTimeInputType::spinButtonStepDown):
36685         Delegate to DateTimeEditElement::stepDown.
36686         (WebCore::BaseMultipleFieldsDateAndTimeInputType::spinButtonStepUp):
36687         Delegate to DateTimeEditElement::stepUp.
36688         (WebCore::BaseMultipleFieldsDateAndTimeInputType::BaseMultipleFieldsDateAndTimeInputType):
36689         Initialize m_spinButtonElement.
36690         (WebCore::BaseMultipleFieldsDateAndTimeInputType::~BaseMultipleFieldsDateAndTimeInputType):
36691         Reset SpinButtonOwner for m_spinButtonElement like the old code of ~DateTimeEditElement.
36692         (WebCore::BaseMultipleFieldsDateAndTimeInputType::createShadowSubtree):
36693         Put a SpinButtonElement between the DateTimeEditElement and the PickerIndicatorElement.
36694         (WebCore::BaseMultipleFieldsDateAndTimeInputType::forwardEvent):
36695         Take care of SpinButtonElement.
36696         (WebCore::BaseMultipleFieldsDateAndTimeInputType::disabledAttributeChanged):
36697         Release capture of SpinButtonElement. This corresponds to the old
36698         code of DateTimeEditElement::updateUIState.
36699         (WebCore::BaseMultipleFieldsDateAndTimeInputType::readonlyAttributeChanged): Ditto.
36700
36701         * html/TextFieldInputType.h:
36702         Make SpinButtonElement::SpinButtonOwner protected to allow overriding.
36703
36704         * html/shadow/DateTimeEditElement.h:
36705         (DateTimeEditElement): Remove SpniButtonOwner implementation,
36706         m_spinButton, and rename some functions.
36707         * html/shadow/DateTimeEditElement.cpp:
36708         (WebCore::DateTimeEditElement::DateTimeEditElement):
36709         Remove m_spinButton.
36710         (WebCore::DateTimeEditElement::~DateTimeEditElement): Ditto.
36711         (WebCore::DateTimeEditElement::focusIfNoFocus):
36712         Renamed from focusAndSelectSpinButtonOwner. This is called
36713         BaseMultipleFieldsDateAndTimeInputType::focusAndSelectSpinButtonOwner.
36714         (WebCore::DateTimeEditElement::layout):
36715         Remove creation code for -webkit-datetime-edit-gap and SpinButtonElement.
36716         (WebCore::DateTimeEditElement::defaultEventHandler):
36717         Move the code for m_spinButton to
36718         BaseMultipleFieldsDateAndTimeInputType::forwardEvent.
36719         (WebCore::DateTimeEditElement::hasFocusedField): A helper for
36720         BaseMultipleFieldsDateAndTimeInputType::shouldSpinButtonRespondToWheelEvents.
36721         (WebCore::DateTimeEditElement::stepDown): A helper for
36722         BaseMultipleFieldsDateAndTimeInputType::spinButtonStepDown.
36723         (WebCore::DateTimeEditElement::stepUp): A helper for
36724         BaseMultipleFieldsDateAndTimeInputType::spinButtonStepUp.
36725         (WebCore::DateTimeEditElement::updateUIState): Move the code to
36726         BaseMultipleFieldsDateAndTimeInputType::disabledAttributeChanged
36727         and readonlyAttributeChanged.
36728
36729 2012-10-23  Andreas Kling  <kling@webkit.org>
36730
36731         Shrink immutable ElementAttributeData and StylePropertySet by one pointer each.
36732         <http://webkit.org/b/100123>
36733
36734         Reviewed by Anders Carlsson.
36735
36736         Remove one pointer of unintentional padding in the immutable versions of these objects.
36737         583kB progression on Membuster3.
36738
36739         * css/StylePropertySet.cpp:
36740         (WebCore::immutableStylePropertySetSize):
36741         * dom/ElementAttributeData.cpp:
36742         (WebCore::immutableElementAttributeDataSize):
36743
36744 2012-10-23  Nate Chapin  <japhet@chromium.org>
36745
36746         Crash in WebCore::SubresourceLoader::willSendRequest.
36747         https://bugs.webkit.org/show_bug.cgi?id=100147
36748
36749         Reviewed by Abhishek Arya.
36750
36751         No new tests. There is a test case that should cover this, but it doesn't
36752         work correctly on many platforms due to its use of testRunner.addURLToRedirect().
36753         See http/tests/loading/cross-origin-XHR-willLoadRequest.html.
36754         Tested manually on http://www.nick.co.uk/shows/spongebob
36755
36756         * loader/SubresourceLoader.cpp:
36757         (WebCore::SubresourceLoader::willSendRequest):
36758
36759 2012-10-23  Martin Robinson  <mrobinson@igalia.com>
36760
36761         [GTK][Soup] Implement the default authentication dialog via WebCoreSupport
36762         https://bugs.webkit.org/show_bug.cgi?id=99351
36763
36764         Reviewed by Carlos Garcia Campos.
36765
36766         Instead of connecting to the SoupSession::authenticate signal in the API layer
36767         via a SoupSessionFeature, route the message through the typical WebCore authentication
36768         mechanism. This is a step on the path to having full-blown support for authentication
36769         in the API allowing for custom authentication dialogs and behavior in clients.
36770
36771         No new tests. This should not change behavior.
36772
36773         * GNUmakefile.list.am: Add the new implementation file for the AuthenticationChallenge.
36774         * loader/ResourceLoader.cpp:
36775         (WebCore::ResourceLoader::didReceiveAuthenticationChallenge): Include GTK+ here as well.
36776         * platform/gtk/GtkAuthenticationDialog.cpp: Instead of carrying a raw pointer to a SoupAuth
36777         carry a GRefPtr which will allow the dialog to be used even after the AuthenticationChallenge
36778         is destroyed.
36779         * platform/gtk/GtkAuthenticationDialog.h: ditto.
36780         * platform/network/ResourceHandle.h: Add a didReceiveAuthenticationChallenge method.
36781         * platform/network/ResourceHandleInternal.h:
36782         (ResourceHandleInternal): Remove the getter for the initiating page ID.
36783         * platform/network/soup/AuthenticationChallenge.h: Added an implementation of AuthenticationChallenge
36784         that takes a bit of data from the handle including SoupMessage, SoupAuth, and SoupSession.
36785         * platform/network/soup/AuthenticationChallengeSoup.cpp: Added. Ditto.
36786         * platform/network/soup/ResourceError.h:
36787         (ResourceError): Added a factory for authentication errors.
36788         * platform/network/soup/ResourceErrorSoup.cpp: Ditto.
36789         * platform/network/soup/ResourceHandleSoup.cpp:
36790         (WebCore::setSoupRequestInitiaingPageID): Just get the page directly from the NetworkingContext.
36791         (WebCore::createSoupMessageForHandleAndRequest): Always set the "handle" data on the message.
36792         It's always used now.
36793         (WebCore::ResourceHandle::start): Get the initiating page ID directly from the NetworkingContext.
36794         (WebCore::ResourceHandle::didReceiveAuthenticationChallenge): Added this method which routes
36795         the authentication challenge to the client.
36796         (WebCore::ResourceHandle::receivedRequestToContinueWithoutCredential): Added a stub for this method.
36797         (WebCore::ResourceHandle::loadResourceSynchronously): Don't pass the session to the loader.
36798         (WebCore::authenicateCallback): Added.
36799         (WebCore::ResourceHandle::defaultSession): Connect the authenticate callback.
36800
36801 2012-10-23  Adam Barth  <abarth@webkit.org>
36802
36803         [V8] Simplify GCEpilogueVisitor along the same lines as GCPrologueVisitor
36804         https://bugs.webkit.org/show_bug.cgi?id=100157
36805
36806         Reviewed by Eric Seidel.
36807
36808         This patch removes the traits template parameter from GCEpilogueVisitor
36809         and makes it mirror GCPrologueVisitor again.
36810
36811         * bindings/v8/V8GCController.cpp:
36812         (WebCore):
36813         (ActiveDOMObjectEpilogueVisitor):
36814         (WebCore::ActiveDOMObjectEpilogueVisitor::ActiveDOMObjectEpilogueVisitor):
36815         (WebCore::ActiveDOMObjectEpilogueVisitor::visitDOMWrapper):
36816         (WebCore::V8GCController::majorGCEpilogue):
36817
36818 2012-10-23  Varun Jain  <varunjain@chromium.org>
36819
36820         Context menu generated from touch gestures on textareas has
36821         context of the cursor position instead of the position where the event occurs.
36822         https://bugs.webkit.org/show_bug.cgi?id=99520
36823
36824         Reviewed by Kenneth Rohde Christiansen.
36825
36826         Send a synthetic mouse down event for context menu-summoning-gesture events so
36827         that textareas can correctly set cursors before receiving the context menu event.
36828
36829         Test: fast/events/touch/gesture/right-click-gestures-set-cursor-at-correct-position.html
36830
36831         * page/EventHandler.cpp:
36832         (WebCore::EventHandler::handleGestureEvent):
36833         (WebCore::EventHandler::handleGestureTwoFingerTap):
36834         (WebCore):
36835         (WebCore::EventHandler::sendContextMenuEventForGesture):
36836         * page/EventHandler.h:
36837         (EventHandler):
36838
36839 2012-10-23  Andy Estes  <aestes@apple.com>
36840
36841         [WebKit2 API] Add properties to get textRects from a WKDOMRange or WKDOMNode
36842         https://bugs.webkit.org/show_bug.cgi?id=100162
36843
36844         Reviewed by Sam Weinig.
36845
36846         * WebCore.exp.in: Exported symbols needed by WebKit2.
36847         * bindings/objc/DOM.mm:
36848         (-[DOMNode textRects]): Moved some logic into Node::textRects()
36849         (everything but the call to updateLayoutIgnorePendingStylesheets()).
36850         * dom/Node.cpp:
36851         (WebCore::Node::textRects):
36852         * dom/Node.h:
36853
36854 2012-10-23  Adam Barth  <abarth@webkit.org>
36855
36856         [V8] Remove unused function from DOM wrapper visitor
36857         https://bugs.webkit.org/show_bug.cgi?id=100163
36858
36859         Reviewed by Eric Seidel.
36860
36861         No one overrides these virtual functions. They were added in
36862         http://trac.webkit.org/changeset/73491, but we don't use them in the GC
36863         controller anymore.
36864
36865         * bindings/v8/V8DOMMap.h:
36866         (WebCore::WeakReferenceMap::visit):
36867
36868 2012-10-23  Aaron Colwell  <acolwell@chromium.org>
36869
36870         Clear m_mediaSource reference when the MediaSource is closed
36871         https://bugs.webkit.org/show_bug.cgi?id=100047
36872
36873         Reviewed by Eric Carlson.
36874
36875         The m_mediaSource object shouldn't be accessed after the object
36876         transitions to closed so this change simply clears the reference
36877         when that transition happens.
36878
36879         No new tests because the change isn't visible to JavaScript.
36880
36881         * html/HTMLMediaElement.cpp:
36882         (WebCore::HTMLMediaElement::loadResource): Removed a closed transition that is actually dead code.
36883         (WebCore::HTMLMediaElement::setSourceState): Clear the m_mediaSource reference on closed transition.
36884
36885 2012-10-23  Simon Fraser  <simon.fraser@apple.com>
36886
36887         Allow tests to run with a tile cache, and optionally dump the tile cache via layerTreeAsText()
36888         https://bugs.webkit.org/show_bug.cgi?id=100159
36889
36890         Reviewed by Tim Horton.
36891
36892         Add a LAYER_TREE_INCLUDES_PAGE_TILE_CACHE flag for layerTreeAsText(), and plumb it
36893         through to GraphicsLayerCA, which dumps the TiledBacking tile coverage rect.
36894
36895         Test: platform/mac/tiled-drawing/use-tiled-drawing.html
36896
36897         * page/Frame.h:
36898         * platform/graphics/GraphicsLayer.cpp:
36899         (showGraphicsLayerTree):
36900         * platform/graphics/GraphicsLayer.h:
36901         (WebCore::GraphicsLayer::tiledBacking):
36902         * platform/graphics/TiledBacking.h:
36903         * platform/graphics/ca/GraphicsLayerCA.cpp:
36904         (WebCore::GraphicsLayerCA::tiledBacking):
36905         (WebCore::GraphicsLayerCA::dumpAdditionalProperties):
36906         * platform/graphics/ca/GraphicsLayerCA.h:
36907         (GraphicsLayerCA):
36908         * platform/graphics/ca/mac/TileCache.h:
36909         (WebCore::TileCache::tileCoverageRect):
36910         (TileCache):
36911         * platform/graphics/ca/mac/TileCache.mm:
36912         (WebCore::TileCache::computeTileCoverageRect):
36913         (WebCore::TileCache::revalidateTiles):
36914         * rendering/RenderLayerCompositor.cpp:
36915         (WebCore::RenderLayerCompositor::layerTreeAsText):
36916         * testing/Internals.cpp:
36917         (WebCore::Internals::layerTreeAsText):
36918         * testing/Internals.h:
36919         * testing/Internals.idl:
36920
36921 2012-10-23  No'am Rosenthal  <noam.rosenthal@nokia.com>
36922
36923         Coordinated Graphics: Enable threaded/IPC animations
36924         https://bugs.webkit.org/show_bug.cgi?id=93146
36925
36926         Reviewed by Kenneth Rohde Christiansen.
36927
36928         Add enablers to TextureMapper and GraphicsLayerAnimation so that they could be used
36929         across processes with IPC. Added some public accessors to GraphicsLayerAnimation,
36930         and allowed a GraphicsLayerTextureMapper to receive a full list of animations.
36931
36932         Covered by existing animation and compositing tests.
36933
36934         * platform/graphics/GraphicsLayerAnimation.cpp:
36935         (WebCore::GraphicsLayerAnimation::GraphicsLayerAnimation):
36936             Initialize the animation with the startTime instead of the offset.
36937
36938         (WebCore::GraphicsLayerAnimations::getActiveAnimations):
36939         * platform/graphics/GraphicsLayerAnimation.h:
36940         (WebCore::GraphicsLayerAnimation::setState):
36941             Allow setting the pause time as well.
36942
36943         (WebCore::GraphicsLayerAnimation::boxSize):
36944         (WebCore::GraphicsLayerAnimation::startTime):
36945         (WebCore::GraphicsLayerAnimation::pauseTime):
36946         (WebCore::GraphicsLayerAnimation::animation):
36947         (WebCore::GraphicsLayerAnimation::keyframes):
36948         (WebCore::GraphicsLayerAnimation::listsMatch):
36949         (WebCore::GraphicsLayerAnimations::size):
36950         (WebCore::GraphicsLayerAnimations::animations):
36951             Add public accessors to GraphicsLayerAnimation properties.
36952
36953         (GraphicsLayerAnimation):
36954         (GraphicsLayerAnimations):
36955         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
36956         (WebCore::GraphicsLayerTextureMapper::addAnimation):
36957         (WebCore::GraphicsLayerTextureMapper::setAnimations):
36958             Allow replacing the entire list of animations.
36959
36960         (WebCore):
36961         * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
36962         (GraphicsLayerTextureMapper):
36963         * platform/graphics/texmap/TextureMapperLayer.cpp:
36964         (WebCore::TextureMapperLayer::applyAnimationsRecursively):
36965         (WebCore):
36966         * platform/graphics/texmap/TextureMapperLayer.h:
36967         (TextureMapperLayer):
36968
36969 2012-10-23  Chris Rogers  <crogers@google.com>
36970
36971         Change setTargetValueAtTime() to setTargetAtTime()
36972         https://bugs.webkit.org/show_bug.cgi?id=100153
36973
36974         Reviewed by Adam Barth.
36975
36976         The AudioParam method name has changed due to Web Audio API spec review.
36977         Keep legacy support for the old name.
36978
36979         Test: webaudio/audioparam-setTargetAtTime.html
36980
36981         * Modules/webaudio/AudioParam.h:
36982         (WebCore::AudioParam::setTargetAtTime):
36983         * Modules/webaudio/AudioParam.idl:
36984         * Modules/webaudio/AudioParamTimeline.cpp:
36985         (WebCore::AudioParamTimeline::setTargetAtTime):
36986         (WebCore::AudioParamTimeline::valuesForTimeRangeImpl):
36987         * Modules/webaudio/AudioParamTimeline.h:
36988         (AudioParamTimeline):
36989
36990 2012-10-23  Benjamin Poulain  <benjamin@webkit.org>
36991
36992         [Mac] Remove extraneous conversion to String->NSString
36993         https://bugs.webkit.org/show_bug.cgi?id=100044
36994
36995         Reviewed by Darin Adler.
36996
36997         Improve some unfortunate use of String->NSString.
36998
36999         * accessibility/mac/AXObjectCacheMac.mm:
37000         (WebCore::AXObjectCache::postPlatformNotification): The variable macNotification is ultimately
37001         needed as NSString, and all its value are or can be NSString.
37002         Convert the last 3 char* values to NSString literal and use NSString* all the way.
37003
37004         * loader/mac/LoaderNSURLExtras.h:
37005         * loader/mac/LoaderNSURLExtras.mm:
37006         (suggestedFilenameWithMIMEType):
37007         We converted the String to NSString to pass to suggestedFilenameWithMIMEType. There is no need
37008         for the string to be a NSSTring there, we can leave it in its original type.
37009
37010         The case checking for a nil MIMEType was dead code because the implicit conversion never returns nil.
37011
37012         * platform/mac/DragImageMac.mm:
37013         (WebCore::createDragImageForLink):
37014         Use String's nsStringNilIfEmpty().
37015
37016         * platform/mac/HTMLConverter.mm:
37017         (-[WebHTMLConverter _addAttachmentForElement:URL:needsParagraph:usePlaceholder:]):
37018         Fix the coding style. Do the conversion to NSString only when needed.
37019
37020 2012-10-23  Roger Fong  <roger_fong@apple.com>
37021
37022         [Win] Popup menus positioning needs to take multiple monitors into account.
37023         https://bugs.webkit.org/show_bug.cgi?id=100158
37024
37025         Reviewed by Timothy Horton.
37026
37027         Add screen.x() to repositioning check to account for position of current monitor.
37028
37029         * platform/win/PopupMenuWin.cpp:
37030         (WebCore::PopupMenuWin::calculatePositionAndSize):
37031
37032 2012-10-23  Huang Dongsung  <luxtella@company100.net>
37033
37034         [CSS Shaders] Set FilterOperations on GraphicsLayer after the program of CSS Shaders is loaded.
37035         https://bugs.webkit.org/show_bug.cgi?id=99908
37036
37037         Reviewed by Dean Jackson.
37038
37039         CSS Shaders can not render anything until the program is loaded. If there is
37040         partial loaded shaders program, whole FilterOperations chain can not render
37041         anything. It occurs a flash. So We have to wait until the program is loaded, to
37042         prevent a flash as RenderLayerBacking::updateImageContents() waits until an
37043         image is fully loaded.
37044
37045         No new tests, CSS Shaders on Accelerated Compositing are not activated yet.
37046
37047         * rendering/RenderLayerBacking.cpp:
37048         (WebCore::RenderLayerBacking::updateFilters):
37049
37050 2012-10-23  Elliott Sprehn  <esprehn@chromium.org>
37051
37052         Generated should not be supported for things with a shadow
37053         https://bugs.webkit.org/show_bug.cgi?id=98836
37054
37055         Reviewed by Dimitri Glazkov.
37056
37057         As far as CSS is concerned inputs and things with shadow content inside
37058         shouldn't support pseudo elements like :before, :after or :first-letter.
37059         Neither Gecko or Presto supports it, and we only accidentally supported
37060         it.
37061
37062         Until the spec tells us what to do we should disable support. This is
37063         also neccesary because the new generated content implementation doesn't
37064         support shadows.
37065
37066         Test: fast/forms/pseudo-elements.html
37067
37068         * rendering/RenderBlock.cpp:
37069         (WebCore::RenderBlock::updateFirstLetter):
37070         * rendering/RenderListBox.h: Added missing canHaveGeneratedChildren() that returns false.
37071         * rendering/RenderObjectChildList.cpp:
37072         (WebCore::RenderObjectChildList::updateBeforeAfterContent):
37073
37074 2012-10-23  Huang Dongsung  <luxtella@company100.net>
37075
37076         [CSS Shaders] Implement overlay, color-dodge, color-burn, hard-light, soft-light blend modes.
37077         https://bugs.webkit.org/show_bug.cgi?id=98504
37078
37079         Reviewed by Dean Jackson.
37080
37081         Add expressions for the aforementioned blend modes. The expressions are lifted
37082         directly from the CSS Compositing and Blending spec [1]. WebKit adds these
37083         blending expressions to the author's shader.
37084
37085         [1]: https://dvcs.w3.org/hg/FXTF/rawfile/tip/compositing/index.html#blendingnormal
37086
37087         Test: css3/filters/custom/custom-filter-blend-modes.html
37088
37089         * platform/graphics/filters/CustomFilterValidatedProgram.cpp:
37090         (WebCore::CustomFilterValidatedProgram::rewriteMixFragmentShader):
37091         (WebCore::CustomFilterValidatedProgram::blendFunctionString):
37092
37093 2012-10-23  Huang Dongsung  <luxtella@company100.net>
37094
37095         [CSS Shaders] Implement all composite operators except destination and lighter.
37096         https://bugs.webkit.org/show_bug.cgi?id=97859
37097
37098         Reviewed by Dean Jackson.
37099
37100         Add expressions for all composite operators except destination and
37101         lighter. The expressions are lifted directly from the CSS Compositing
37102         and Blending spec [1]. WebKit adds these compositing expressions to the
37103         author's shader.
37104
37105         [1]: https://dvcs.w3.org/hg/FXTF/rawfile/tip/compositing/index.html#advancedcompositing
37106
37107         Test: css3/filters/custom/custom-filter-composite-operators.html
37108
37109         * platform/graphics/filters/CustomFilterCompiledProgram.cpp:
37110         (WebCore::CustomFilterCompiledProgram::initializeParameterLocations):
37111             Remove ASSERTION checking if glGetUniformLocation returns negative,
37112             because ASSERTION can fail with clear and copy composite operations.
37113             Clear and copy composite operations do not need "css_u_texture"
37114             representing the DOM element texture. If the driver compiler is
37115             smart, "css_u_texture" is not regarded as an active uniform, so
37116             glGetuniformLocation returns -1. glGetAttribLocation ditto.
37117         * platform/graphics/filters/CustomFilterValidatedProgram.cpp:
37118         (WebCore::CustomFilterValidatedProgram::compiledProgram):
37119             Move the above ASSERTION in CustomFilterCompiledProgram to here.
37120             ASSERTION checks if m_samplerLocation is not -1 when the author
37121             shader needs an input texture.
37122         (WebCore::CustomFilterValidatedProgram::needsInputTexture):
37123         (WebCore):
37124         (WebCore::CustomFilterValidatedProgram::compositeFunctionString):
37125         * platform/graphics/filters/CustomFilterValidatedProgram.h:
37126         (CustomFilterValidatedProgram):
37127
37128 2012-10-23  Max Vujovic  <mvujovic@adobe.com>
37129
37130         [CSS Shaders] Changing the blend mode in CSS doesn't update the custom filter rendering
37131         https://bugs.webkit.org/show_bug.cgi?id=99887
37132
37133         Reviewed by Dirk Schulze.
37134
37135         Before this patch, WebKit would not recompute an element's style when just its custom filter
37136         blend mode changed.
37137
37138         For example, suppose an element initially has the style:
37139         -webkit-filter: custom(none mix(url(shader.fs) multiply source-atop));
37140
37141         Then, we change the blend mode from "multiply" to "normal":
37142         -webkit-filter: custom(none mix(url(shader.fs) normal source-atop));
37143
37144         WebKit now detects this change and recomputes the style.
37145
37146         CustomFilterProgram now has an equals operator that considers the program type and the mix
37147         settings. The mix settings contain the blend mode.
37148
37149         Test: css3/filters/custom/custom-filter-change-blend-mode.html
37150
37151         * platform/graphics/filters/CustomFilterProgram.cpp:
37152         (WebCore::CustomFilterProgram::operator==):
37153             Previously, the equals operator was pure virtual in CustomFilterProgram. Now,
37154             CustomFilterProgram implements it and compares the program type and mix settings, if
37155             appropriate.
37156         (WebCore):
37157         * platform/graphics/filters/CustomFilterProgram.h:
37158         * platform/graphics/filters/CustomFilterProgramInfo.cpp:
37159         (WebCore::CustomFilterProgramInfo::hash):
37160             Refactor a repeated condition into a boolean to improve readability.
37161         (WebCore::CustomFilterProgramInfo::operator==):
37162             Refactor repeated conditions to improve readability. Reorder the conditions so the less
37163             expensive ones occur first.
37164         * rendering/style/StyleCustomFilterProgram.h:
37165         (WebCore::StyleCustomFilterProgram::operator==):
37166             Call the base class's equals operator.
37167
37168 2012-10-23  David Barton  <dbarton@mathscribe.com>
37169
37170         [MathML] Symbol font uses greek letters for roman ones on linux and Windows
37171         https://bugs.webkit.org/show_bug.cgi?id=99921
37172
37173         Reviewed by Eric Seidel.
37174
37175         For parts of stretched parentheses and brackets, mathml.css currently uses the Symbol font,
37176         which on linux and Windows has greek letters at roman code points. To fix this, we switch
37177         to the STIXSizeOneSym font when available. However, this can cause vertical gaps between
37178         glyph parts, because of hard-coded constants in RenderMathMLOperator.cpp. We eliminate all
37179         these constants. We also shift glyphs upward by 1px and truncate them to avoid the gaps.
37180
37181         Tested by existing tests, and one test added to LayoutTests/mathml/presentation/mo.xhtml.
37182
37183         * css/mathml.css:
37184         (math, mfenced > *):
37185             - Set font-family for mn, mi, etc.
37186         (mo, mfenced):
37187             - Set font-family for mo and anonymous operators, including extension glyphs for
37188               stretched operators like parentheses and brackets.
37189         (math):
37190         * rendering/mathml/RenderMathMLOperator.cpp:
37191         (WebCore):
37192             - Change 0x23d0 to 0x23aa for STIX & Cambria Math fonts.
37193         (WebCore::RenderMathMLOperator::glyphHeightForCharacter):
37194         (WebCore::RenderMathMLOperator::updateFromElement):
37195         (WebCore::RenderMathMLOperator::createStackableStyle):
37196             - Eliminate unused lineHeight and topRelative parameters, and the hard-coded font size
37197               of 14.
37198         (WebCore::RenderMathMLOperator::createGlyph):
37199             - Eliminate unused lineHeight and topRelative parameters.
37200         * rendering/mathml/RenderMathMLOperator.h:
37201         (RenderMathMLOperator):
37202
37203 2012-10-23  Benjamin Poulain  <benjamin@webkit.org>
37204
37205         WTFURL: Implement KURL::setPort()
37206         https://bugs.webkit.org/show_bug.cgi?id=99898
37207
37208         Reviewed by Adam Barth.
37209
37210         * platform/KURLWTFURL.cpp:
37211         (WebCore::KURL::setPort):
37212
37213 2012-10-23  Nico Weber  <thakis@chromium.org>
37214
37215         In the open-source jpeg decoder, read image orientation from the exif data
37216         https://bugs.webkit.org/show_bug.cgi?id=100144
37217
37218         Reviewed by Eric Seidel.
37219
37220         This will be used to implement the shouldRespectImageOrientation
37221         setting (see bug 19688). Currently this isn't hooked up anywhere, so
37222         it has no observable effect for now.
37223
37224         Once it's hooked up, it will be tested by
37225         fast/images/exif-orientation.html
37226
37227         * platform/graphics/BitmapImage.h:
37228         * platform/image-decoders/ImageDecoder.h:
37229         (WebCore::ImageDecoder::orientation):
37230         (ImageDecoder):
37231         * platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
37232         (WebCore::readUint16):
37233         (WebCore):
37234         (WebCore::readUint32):
37235         (WebCore::checkExifHeader):
37236         (WebCore::readImageOrientation):
37237         (WebCore::JPEGImageReader::JPEGImageReader):
37238         (WebCore::JPEGImageReader::decode):
37239         * platform/image-decoders/jpeg/JPEGImageDecoder.h:
37240         (WebCore::JPEGImageDecoder::setOrientation):
37241
37242 2012-10-23  Chris Rogers  <crogers@google.com>
37243
37244         Fix thread safety issue in AudioParamTimeline
37245         https://bugs.webkit.org/show_bug.cgi?id=100154
37246
37247         Reviewed by Kenneth Russell.
37248
37249         Add appropriate locking in AudioParamTimeline::valueForContextTime()
37250
37251         * Modules/webaudio/AudioParamTimeline.cpp:
37252         (WebCore::AudioParamTimeline::valueForContextTime):
37253
37254 2012-10-23  Alec Flett  <alecflett@chromium.org>
37255
37256         IndexedDB: refactor backend to use IDB*Metadata
37257         https://bugs.webkit.org/show_bug.cgi?id=100055
37258
37259         Reviewed by Tony Chang.
37260
37261         This further encapsulates the static data in
37262         IDBObjectStoreBackendImpl and IDBIndexBackendImp into their
37263         respective IDB*Metadata structs, in preparation for
37264         https://bugs.webkit.org/show_bug.cgi?id=99774.
37265
37266         No new tests as this is purely a refactor.
37267
37268         * Modules/indexeddb/IDBBackingStore.h:
37269         (IDBBackingStore):
37270         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
37271         (WebCore::IDBDatabaseBackendImpl::createObjectStore):
37272         (WebCore::IDBDatabaseBackendImpl::loadObjectStores):
37273         * Modules/indexeddb/IDBIndexBackendImpl.cpp:
37274         (WebCore::IDBIndexBackendImpl::IDBIndexBackendImpl):
37275         (WebCore::IDBIndexBackendImpl::metadata):
37276         * Modules/indexeddb/IDBIndexBackendImpl.h:
37277         (WebCore::IDBIndexBackendImpl::create):
37278         (WebCore::IDBIndexBackendImpl::id):
37279         (WebCore::IDBIndexBackendImpl::setId):
37280         (WebCore::IDBIndexBackendImpl::hasValidId):
37281         (WebCore::IDBIndexBackendImpl::name):
37282         (WebCore::IDBIndexBackendImpl::keyPath):
37283         (WebCore::IDBIndexBackendImpl::unique):
37284         (WebCore::IDBIndexBackendImpl::multiEntry):
37285         (IDBIndexBackendImpl):
37286         * Modules/indexeddb/IDBLevelDBBackingStore.cpp:
37287         (WebCore::IDBLevelDBBackingStore::getObjectStores):
37288         (WebCore::IDBLevelDBBackingStore::getIndexes):
37289         * Modules/indexeddb/IDBLevelDBBackingStore.h:
37290         (IDBLevelDBBackingStore):
37291         * Modules/indexeddb/IDBMetadata.h:
37292         (WebCore::IDBObjectStoreMetadata::IDBObjectStoreMetadata):
37293         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
37294         (WebCore::IDBObjectStoreBackendImpl::IDBObjectStoreBackendImpl):
37295         (WebCore::IDBObjectStoreBackendImpl::metadata):
37296         (WebCore::IDBObjectStoreBackendImpl::setIndexKeys):
37297         (WebCore::IDBObjectStoreBackendImpl::putInternal):
37298         (WebCore::IDBObjectStoreBackendImpl::createIndex):
37299         (WebCore::IDBObjectStoreBackendImpl::loadIndexes):
37300         * Modules/indexeddb/IDBObjectStoreBackendImpl.h:
37301         (WebCore::IDBObjectStoreBackendImpl::create):
37302         (WebCore::IDBObjectStoreBackendImpl::id):
37303         (WebCore::IDBObjectStoreBackendImpl::setId):
37304         (WebCore::IDBObjectStoreBackendImpl::name):
37305         (WebCore::IDBObjectStoreBackendImpl::keyPath):
37306         (WebCore::IDBObjectStoreBackendImpl::autoIncrement):
37307         (IDBObjectStoreBackendImpl):
37308
37309 2012-10-19  Roger Fong  <roger_fong@apple.com>
37310
37311         [WebGL] conformance/textures/texture-size.html is failing on Apple Mountain Lion
37312         https://bugs.webkit.org/show_bug.cgi?id=94041
37313
37314         Reviewed by Dean Jackson.
37315
37316         When binding a texture to GL_TEXTURE_2D when GL_ACTIVE_TEXTURE is 0, we set m_boundTexture0 to the texture unit. 
37317         However when we delete the texture, we need to be setting m_boundTexture0 to 0.
37318         Otherwise when we draw to the screen we bind m_boundTexture0 in the prepareTexture() method and since the associated texture 
37319         has already been deleted we end up in an error state.
37320
37321         Tested using Khronos WebGL conformance suite:
37322         conformance/textures/texture-size.html
37323
37324         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
37325         (WebCore::GraphicsContext3D::deleteTexture):
37326
37327 2012-10-22  Dirk Schulze  <krit@webkit.org>
37328
37329         BasicShapePolygon::path takes width instead of height for boundary calculation
37330         https://bugs.webkit.org/show_bug.cgi?id=99919
37331
37332         Reviewed by Darin Adler.
37333
37334         The 'y' parameters of polygon were calculated by the with of the bounding box of the object.
37335         This caused problems on percentage values for point positions. 
37336         Changed it to the height of the bounding box.
37337
37338         Test: css3/masking/clip-path-polygon-percentage.html
37339
37340         * rendering/style/BasicShapes.cpp:
37341         (WebCore::BasicShapePolygon::path):
37342
37343 2012-10-23  Dominik Röttsches  <dominik.rottsches@intel.com>
37344
37345         Add timeout support to XMLHttpRequest
37346         https://bugs.webkit.org/show_bug.cgi?id=74802
37347
37348         Reviewed by Nate Chapin.
37349
37350         An implementation of XHR2 timeouts by using ResourceRequest's setTimeoutInterval.
37351         This made several changes necessary in CachedResource and SubresourceLoader in order
37352         to distinguish and forward the timeout case from there.
37353
37354         The case of late updates to the timeout property, changing the timeout value after send()
37355         is not supported yet and handled separately in bug 98156.
37356
37357         XHR2 timeout tests were initially written by Mozilla's Alex Vincent's. He granted
37358         permission to reuse them under PD/BSD license
37359         in https://bugzilla.mozilla.org/show_bug.cgi?id=525816#c86 - big thanks!
37360         I adapted them for W3C testharness.js and split them into groups with shorter test running time
37361         so that they can be used as WebKit layout tests.
37362
37363         Tests: http/tests/xmlhttprequest/timeout/xmlhttprequest-timeout-aborted.html
37364                http/tests/xmlhttprequest/timeout/xmlhttprequest-timeout-abortedonmain.html
37365                http/tests/xmlhttprequest/timeout/xmlhttprequest-timeout-overridesexpires.html
37366                http/tests/xmlhttprequest/timeout/xmlhttprequest-timeout-simple.html
37367                http/tests/xmlhttprequest/timeout/xmlhttprequest-timeout-synconmain.html
37368                http/tests/xmlhttprequest/timeout/xmlhttprequest-timeout-twice.html
37369                http/tests/xmlhttprequest/timeout/xmlhttprequest-timeout-worker-aborted.html
37370                http/tests/xmlhttprequest/timeout/xmlhttprequest-timeout-worker-overridesexpires.html
37371                http/tests/xmlhttprequest/timeout/xmlhttprequest-timeout-worker-simple.html
37372                http/tests/xmlhttprequest/timeout/xmlhttprequest-timeout-worker-synconworker.html
37373                http/tests/xmlhttprequest/timeout/xmlhttprequest-timeout-worker-twice.html
37374
37375         * loader/DocumentThreadableLoader.cpp:
37376         (WebCore::DocumentThreadableLoader::notifyFinished): Forward information about timeout case.
37377         * loader/SubresourceLoader.cpp:
37378         (WebCore::SubresourceLoader::didFail): Distinguish timeout case when informing client.
37379         * loader/cache/CachedResource.h: Distinguishing timeout case for errors.
37380         (WebCore::CachedResource::errorOccurred):
37381         (WebCore::CachedResource::loadFailedOrCanceled):
37382         (WebCore::CachedResource::timedOut):
37383         * xml/XMLHttpRequest.cpp:
37384         (WebCore::XMLHttpRequest::XMLHttpRequest): Initializing m_timeout value to zero.
37385         (WebCore::XMLHttpRequest::setTimeout): Setter function, possibly raising JS exception.
37386         (WebCore):
37387         (WebCore::XMLHttpRequest::open): Open call may raise exception for synchronous requests when timeout value is set.
37388         (WebCore::XMLHttpRequest::createRequest): Assigning timeout value to ResourceRequest.
37389         (WebCore::XMLHttpRequest::didFail): Handling timeout case separately.
37390         (WebCore::XMLHttpRequest::didTimeout): Timeout case state transisition and event firing as spec'ed.
37391         * xml/XMLHttpRequest.h: New event listener, member and callback for handling timeout.
37392         (WebCore::XMLHttpRequest::timeout):
37393         (XMLHttpRequest):
37394         * xml/XMLHttpRequest.idl: New event listener and property added.
37395         * xml/XMLHttpRequestException.cpp:
37396         * xml/XMLHttpRequestException.h: Added an exception value for the timeout case.
37397
37398
37399 2012-10-23  Christophe Dumez  <christophe.dumez@intel.com>
37400
37401         Possible assertion hit in WebCore::HTMLSelectElement::updateListBoxSelection()
37402         https://bugs.webkit.org/show_bug.cgi?id=99967
37403
37404         Reviewed by Tony Chang.
37405
37406         Fix assertion hit in WebCore::HTMLSelectElement::updateListBoxSelection() when
37407         pressing the left mouse button outside a multiselect and then moving the cursor
37408         over the multiselect element while holding the button down.
37409
37410         The issue is that the HTMLSelectElement handler for the mouse move event does
37411         not check if there is a selection before trying to extend the selection.
37412
37413         Test: fast/dom/HTMLSelectElement/select-selectedIndex-noAnchorIndex-crash.html
37414
37415         * html/HTMLSelectElement.cpp:
37416         (WebCore::HTMLSelectElement::listBoxDefaultEventHandler):
37417
37418 2012-10-23  Adam Barth  <abarth@webkit.org>
37419
37420         [V8] ScriptWrappable should hold the wrapper handle directly (Dromaeo/dom-modify and dom-traverse get ~2.5% faster)
37421         https://bugs.webkit.org/show_bug.cgi?id=97974
37422
37423         Reviewed by Eric Seidel.
37424
37425         Previously, we stored a pointer to a handle to a wrapper in Node. That
37426         is an extra layer of indirection that slows down finding the wrapper
37427         for the node. A handle is just a pointer, so we might as we just store
37428         the handle in the Node directly. That speeds up dom-modify and
37429         dom-traverse by about 2.5%.
37430
37431         This change also lets us get rid of the ChunkedTable we were using to
37432         store all the wrappers because they're now stored in the Nodes
37433         directly.
37434
37435         * bindings/scripts/CodeGeneratorV8.pm:
37436         (GenerateHeader):
37437         * bindings/v8/IntrusiveDOMWrapperMap.h:
37438         (WebCore::IntrusiveDOMWrapperMap::IntrusiveDOMWrapperMap):
37439         (WebCore::IntrusiveDOMWrapperMap::get):
37440         (WebCore::IntrusiveDOMWrapperMap::set):
37441         (WebCore::IntrusiveDOMWrapperMap::contains):
37442         (WebCore::IntrusiveDOMWrapperMap::visit):
37443         (WebCore::IntrusiveDOMWrapperMap::removeIfPresent):
37444         (WebCore::IntrusiveDOMWrapperMap::clear):
37445         * bindings/v8/ScriptWrappable.h:
37446         (WebCore::ScriptWrappable::ScriptWrappable):
37447         (WebCore::ScriptWrappable::wrapper):
37448         (WebCore::ScriptWrappable::setWrapper):
37449         (WebCore::ScriptWrappable::disposeWrapper):
37450         (WebCore::ScriptWrappable::reportMemoryUsage):
37451         (ScriptWrappable):
37452         * bindings/v8/V8DOMWrapper.h:
37453         (WebCore::V8DOMWrapper::getCachedWrapper):
37454
37455 2012-10-23  Kentaro Hara  <haraken@chromium.org>
37456
37457         [V8] Replace SetGlobalGCPrologueCallback() with AddGCPrologueCallback()
37458         https://bugs.webkit.org/show_bug.cgi?id=100140
37459
37460         Reviewed by Adam Barth.
37461
37462         SetGlobalGCPrologueCallback() and SetGlobalGCEpilogueCallback()
37463         are deprecated (See http://code.google.com/codesearch#OAMlx_jo-ck/src/v8/include/v8.h&exact_package=chromium&q=v8.h&type=cs&l=3149)
37464         Instead we should use AddGCPrologueCallback()
37465         and AddGCEpilogueCallback().
37466
37467         No tests. No change in behavior.
37468
37469         * bindings/v8/V8DOMWindowShell.cpp:
37470         (WebCore::initializeV8IfNeeded):
37471         * bindings/v8/V8GCController.cpp:
37472         (WebCore::V8GCController::gcPrologue):
37473         (WebCore):
37474         (WebCore::V8GCController::minorGCPrologue):
37475         (WebCore::V8GCController::majorGCPrologue):
37476         (WebCore::V8GCController::gcEpilogue):
37477         (WebCore::V8GCController::minorGCEpilogue):
37478         (WebCore::V8GCController::majorGCEpilogue):
37479         * bindings/v8/V8GCController.h:
37480         (V8GCController):
37481         * bindings/v8/WorkerContextExecutionProxy.cpp:
37482         (WebCore::WorkerContextExecutionProxy::initIsolate):
37483
37484 2012-10-23  Adam Barth  <abarth@webkit.org>
37485
37486         [V8] Enumerate Nodes via the V8 heap rather than via a list in WebCore
37487         https://bugs.webkit.org/show_bug.cgi?id=100033
37488
37489         Reviewed by Eric Seidel.
37490
37491         This patch changes how we enumerate nodes during garbage collection.
37492         After this patch, we use V8's list of open handles to enumerate node
37493         wrappers rather than using a separate list that we maintain in WebCore
37494         for this purpose. A future patch will remove the list in WebCore for a
37495         DOM performance gain.
37496
37497         * bindings/js/ScriptProfiler.h:
37498         (WebCore):
37499         (WebCore::ScriptProfiler::visitNodeWrappers):
37500         * bindings/scripts/CodeGeneratorV8.pm:
37501         (GenerateToV8Converters):
37502         * bindings/scripts/test/V8/V8TestNode.cpp:
37503         (WebCore::V8TestNode::wrapSlow):
37504         * bindings/v8/IntrusiveDOMWrapperMap.h:
37505         (WebCore::IntrusiveDOMWrapperMap::set):
37506         * bindings/v8/ScriptProfiler.cpp:
37507         (WebCore::ScriptProfiler::visitNodeWrappers):
37508         * bindings/v8/ScriptProfiler.h:
37509         (WebCore):
37510         (ScriptProfiler):
37511         * bindings/v8/V8DOMMap.cpp:
37512         (WebCore::NodeWrapperVisitor::~NodeWrapperVisitor):
37513         (WebCore):
37514         (WebCore::visitAllDOMNodes):
37515         * bindings/v8/V8DOMMap.h:
37516         (WebCore):
37517         (NodeWrapperVisitor):
37518         * bindings/v8/V8DOMWrapper.cpp:
37519         (WebCore::V8DOMWrapper::setJSWrapperForDOMNode):
37520         (WebCore::V8DOMWrapper::setJSWrapperForActiveDOMNode):
37521         * bindings/v8/V8GCController.cpp:
37522         (WebCore::NodeVisitor::visitNodeWrapper):
37523         (WebCore::V8GCController::gcPrologue):
37524         (WebCore::V8GCController::gcEpilogue):
37525         * inspector/BindingVisitors.h:
37526         (WebCore::WrappedNodeVisitor::~WrappedNodeVisitor):
37527         * inspector/InspectorMemoryAgent.cpp:
37528         (WebCore):
37529
37530 2012-10-22  Andrey Kosyakov  <caseq@chromium.org>
37531
37532         Web Inspector: paint rectangles are incorrectly shown in case subframes are present
37533         https://bugs.webkit.org/show_bug.cgi?id=99849
37534
37535         Reviewed by Pavel Feldman.
37536
37537         Move GraphicsContext and paint rectangle from willPaint() to didPaint(), so we don't have
37538         to store them as a state of InspectorPageAgent
37539
37540         * inspector/InspectorInstrumentation.cpp:
37541         (WebCore):
37542         (WebCore::InspectorInstrumentation::willPaintImpl):
37543         (WebCore::InspectorInstrumentation::didPaintImpl):
37544         * inspector/InspectorInstrumentation.h:
37545         (InspectorInstrumentation):
37546         (WebCore::InspectorInstrumentation::willPaint):
37547         (WebCore::InspectorInstrumentation::didPaint):
37548         * inspector/InspectorPageAgent.cpp:
37549         (WebCore::InspectorPageAgent::didPaint):
37550         * inspector/InspectorPageAgent.h:
37551         * inspector/InspectorTimelineAgent.cpp:
37552         (WebCore::InspectorTimelineAgent::willPaint):
37553         (WebCore::InspectorTimelineAgent::didPaint):
37554         * inspector/InspectorTimelineAgent.h:
37555         (InspectorTimelineAgent):
37556         * inspector/TimelineRecordFactory.cpp:
37557         * inspector/TimelineRecordFactory.h:
37558         (TimelineRecordFactory):
37559         * page/FrameView.cpp:
37560         (WebCore::FrameView::paintContents):
37561         * rendering/RenderLayerBacking.cpp:
37562         (WebCore::RenderLayerBacking::paintContents):
37563
37564 2012-10-23  Pavel Feldman  <pfeldman@chromium.org>
37565
37566         Web Inspector: array grouping does not work for arrays with exactly 10000 elements.
37567         https://bugs.webkit.org/show_bug.cgi?id=100131
37568
37569         Reviewed by Vsevolod Vlasov.
37570
37571         Using ceil() - 1 instead of floor() in bucket size calculation.
37572
37573         * inspector/front-end/ObjectPropertiesSection.js:
37574
37575 2012-10-23  Shinya Kawanaka  <shinyak@chromium.org>
37576
37577         The order of resolving distribution in tree composition is wrong.
37578         https://bugs.webkit.org/show_bug.cgi?id=99552
37579
37580         Reviewed by Dimitri Glazkov.
37581
37582         According to the current ShadowDOM spec, we have to resolve <content> first, then resolve <shadow>.
37583         However, the order of resolution is now the mixed tree order of <content> and <shadow>.
37584
37585         Test: fast/dom/shadow/content-reprojection-order.html
37586
37587         * html/shadow/ContentDistributor.cpp:
37588         (WebCore::ContentDistributor::distribute): We should resolve <content> before <shadow>.
37589         Only the first active shadow insertion point can select the rest of contents.
37590         * html/shadow/HTMLContentElement.h:
37591         (HTMLContentElement):
37592         * html/shadow/HTMLShadowElement.cpp:
37593         * html/shadow/HTMLShadowElement.h:
37594         (WebCore::isHTMLShadowElement):
37595         (WebCore):
37596         (WebCore::toHTMLShadowElement):
37597         * html/shadow/InsertionPoint.h:
37598         (InsertionPoint): We don't need doesSelectFromHostChildren() anymore.
37599
37600 2012-10-23  Vsevolod Vlasov  <vsevik@chromium.org>
37601
37602         Web Inspector: Move UISourceCode creation out of mappings to workspace.
37603         https://bugs.webkit.org/show_bug.cgi?id=100092
37604
37605         Reviewed by Pavel Feldman.
37606
37607         Moved uiSourceCode constructor calls out of mappings to workspace.
37608
37609         * inspector/front-end/CompilerScriptMapping.js:
37610         * inspector/front-end/NetworkUISourceCodeProvider.js:
37611         (WebInspector.NetworkUISourceCodeProvider.prototype._parsedScriptSource):
37612         (WebInspector.NetworkUISourceCodeProvider.prototype._addUISourceCode):
37613         * inspector/front-end/ResourceScriptMapping.js:
37614         (WebInspector.ResourceScriptMapping.prototype._deleteOriginalUISourceCodeForScripts):
37615         (WebInspector.ResourceScriptMapping.prototype._deleteTemporaryUISourceCodeForScripts):
37616         (WebInspector.ResourceScriptMapping.prototype._bindUISourceCodeToScripts):
37617         (WebInspector.ResourceScriptMapping.prototype._createUISourceCode):
37618         (WebInspector.ResourceScriptMapping.prototype._getOrCreateTemporaryUISourceCode):
37619         (WebInspector.ResourceScriptMapping.prototype._getOrCreateOriginalUISourceCode):
37620         * inspector/front-end/SASSSourceMapping.js:
37621         (_bindUISourceCode):
37622         * inspector/front-end/ScriptSnippetModel.js:
37623         (WebInspector.ScriptSnippetModel.prototype._addScriptSnippet):
37624         (WebInspector.ScriptSnippetModel.prototype._createUISourceCodeForScript):
37625         * inspector/front-end/Workspace.js:
37626         (WebInspector.Project.prototype.addUISourceCode):
37627         (WebInspector.Project.prototype.removeUISourceCode):
37628         (WebInspector.Workspace.prototype.addTemporaryUISourceCode):
37629         (WebInspector.Workspace.prototype.removeTemporaryUISourceCode):
37630
37631 2012-10-23  Emil A Eklund  <eae@chromium.org>
37632
37633         Remove unnecessary m_layoutDelta[XY]Saturated initialization
37634         https://bugs.webkit.org/show_bug.cgi?id=100018
37635
37636         Reviewed by Julien Chaffraix.
37637         
37638         Remove unnecessary initialization from LayoutState constructor
37639         added in r132105.
37640
37641         No new tests, no change in functionality.
37642
37643         * rendering/LayoutState.cpp:
37644         (WebCore::LayoutState::LayoutState):
37645
37646 2012-10-23  Zeno Albisser  <zeno@webkit.org>
37647
37648         [Texmap] Fix drawTextureRectangleARB after r131485.
37649         https://bugs.webkit.org/show_bug.cgi?id=100133
37650
37651         Consistently rename u_textureSize to u_samplerSize.
37652
37653         Reviewed by Noam Rosenthal.
37654
37655         * platform/graphics/texmap/TextureMapperGL.cpp:
37656         (WebCore::TextureMapperGL::drawTextureRectangleARB):
37657         * platform/graphics/texmap/TextureMapperShaderManager.cpp:
37658         (WebCore::getShaderSpec):
37659         * platform/graphics/texmap/TextureMapperShaderManager.h:
37660         (TextureMapperShaderProgram):
37661
37662 2012-10-23  Mike West  <mkwst@chromium.org>
37663
37664         Web Inspector: 'data:' URLs should be properly trimmed for readability.
37665         https://bugs.webkit.org/show_bug.cgi?id=100083
37666
37667         Reviewed by Pavel Feldman.
37668
37669         We recently landed a patch to trim the middle out of long URLs in
37670         console messages in order to improve readability. That patch didn't
37671         effect 'data:' URLs, as they didn't match the regex in the linkifier.
37672         This patch ensures that 'data:' URLs are properly trimmed down to
37673         size.
37674
37675         This problem came to light while resolving a different, smaller issue:
37676         'image/jpg' wasn't whitelisted as an image MIME type. That trivial fix
37677         is included in this patch.
37678
37679         Test: http/tests/inspector/network/image-as-text-loading-data-url.html
37680
37681         * inspector/front-end/NetworkManager.js:
37682         (WebInspector.NetworkManager):
37683             Adds 'image/jpg' as a valid image type.
37684         * inspector/front-end/ResourceUtils.js:
37685         (WebInspector.linkifyStringAsFragmentWithCustomLinkifier):
37686             Supports 'data:' URLs in the linkifier's regex.
37687
37688 2012-10-23  Mike West  <mkwst@chromium.org>
37689
37690         Web Inspector: Floated anchor element sometimes overlaps following content.
37691         https://bugs.webkit.org/show_bug.cgi?id=100105
37692
37693         Reviewed by Pavel Feldman.
37694
37695         This patch ensures that each console message clears the
37696         potentially-overlapping floated anchor element.
37697
37698         * inspector/front-end/inspector.css:
37699         (#console-prompt):
37700         (.console-message, .console-user-command):
37701             Clear the float, and flip the border from the bottom of the
37702             message to the top. Do the same for the prompt.
37703         (.console-message:first-child):
37704             Ensure that the first message doesn't have a top border.
37705
37706 2012-10-23  Alexander Pavlov  <apavlov@chromium.org>
37707
37708         Web Inspector: Crash when adding a keyframes rule in the Styles pane
37709         https://bugs.webkit.org/show_bug.cgi?id=99826
37710
37711         Reviewed by Pavel Feldman.
37712
37713         The client-supplied selector text is first parsed to make sure it results in a valid style rule selector.
37714
37715         Test: inspector/styles/add-new-rule-invalid-selector.html
37716
37717         * inspector/InspectorStyleSheet.cpp:
37718         (WebCore::createCSSParser):
37719         (WebCore):
37720         (WebCore::InspectorStyle::setPropertyText):
37721         (WebCore::checkStyleRuleSelector):
37722         (WebCore::InspectorStyleSheet::addRule):
37723         (WebCore::InspectorStyleSheet::ensureSourceData):
37724         (WebCore::InspectorStyleSheetForInlineStyle::getStyleAttributeRanges):
37725
37726 2012-10-15  Kenneth Rohde Christiansen  <kenneth@webkit.org>
37727
37728         Add support for resolution media query
37729         https://bugs.webkit.org/show_bug.cgi?id=99077
37730
37731         Reviewed by Antti Koivisto.
37732
37733         Add support for 'resolution' media query feature.
37734
37735         Background info:
37736         http://www.w3.org/blog/CSS/2012/06/14/unprefix-webkit-device-pixel-ratio
37737
37738         Related spec links:
37739         http://www.w3.org/TR/css3-mediaqueries/#resolution (recommendation)
37740         http://www.w3.org/TR/css3-values/#resolution (candidate recommentation)
37741
37742         Add infrastructure to make it testable.
37743
37744         Test: fast/media/mq-resolution.html
37745
37746         * css/CSSParser.cpp:
37747         (WebCore::CSSParser::validUnit):
37748         (WebCore::CSSParser::createPrimitiveNumericValue):
37749         (WebCore::CSSParser::parseValidPrimitive):
37750         (WebCore::CSSParser::detectNumberToken):
37751         * css/CSSParser.h:
37752         * css/CSSPrimitiveValue.cpp:
37753         (WebCore::isValidCSSUnitTypeForDoubleConversion):
37754         (WebCore::unitCategory):
37755         (WebCore::CSSPrimitiveValue::canonicalUnitTypeForCategory):
37756         (WebCore::CSSPrimitiveValue::customCssText):
37757         (WebCore::CSSPrimitiveValue::cloneForCSSOM):
37758         * css/CSSPrimitiveValue.h:
37759
37760             Enable dpi, dpcm and dppx units when RESOLUTION_MEDIA_QUERY
37761             is enabled.
37762
37763         * WebCore.exp.in:
37764
37765             Export the WebCore::Settings setting.
37766
37767         * css/CSSPrimitiveValue.h:
37768         (WebCore::CSSPrimitiveValue::isDotsPerInch):
37769         (WebCore::CSSPrimitiveValue::isDotsPerPixel):
37770         (WebCore::CSSPrimitiveValue::isDotsPerCentimeter):
37771         (CSSPrimitiveValue):
37772
37773             Add function for checking the recently added density types.
37774
37775         * css/MediaFeatureNames.h:
37776         (MediaFeatureNames):
37777
37778             Add support for resolution, min-resolution and max-resolution.
37779
37780         * css/MediaQueryEvaluator.cpp:
37781         (WebCore::compareResolution): Add methods for comparing resolutions.
37782         (WebCore):
37783         (WebCore::resolutionMediaFeatureEval):
37784         (WebCore::min_resolutionMediaFeatureEval):
37785         (WebCore::max_resolutionMediaFeatureEval):
37786
37787             Implement the resolution method evaluation.
37788
37789         * css/MediaQueryExp.cpp:
37790         (WebCore::featureWithValidPositiveDensity):
37791         (WebCore):
37792         (WebCore::featureWithoutValue):
37793         (WebCore::MediaQueryExp::MediaQueryExp):
37794
37795             Hook up resolution with the right pre-checks.
37796
37797        * page/Screen.cpp:
37798         (WebCore::Screen::horizontalDPI):
37799         (WebCore::Screen::verticalDPI):
37800
37801             Check whether an override exists, and if so, uses it.
37802             If not calculate the value given the device scale factor.
37803
37804         * page/Settings.cpp:
37805         (WebCore::Settings::setResolutionOverride):
37806         (WebCore):
37807         * page/Settings.h:
37808         (Settings):
37809         (WebCore::Settings::resolutionOverride):
37810
37811             Add a resolution override to settings.
37812
37813         * testing/InternalSettings.cpp:
37814         (WebCore::InternalSettings::Backup::Backup):
37815         (WebCore::InternalSettings::Backup::restoreTo):
37816         (WebCore::InternalSettings::setResolutionOverride):
37817         (WebCore):
37818         * testing/InternalSettings.h:
37819         (Backup):
37820         (InternalSettings):
37821         * testing/InternalSettings.idl:
37822
37823             Add a new setResolutionOverride method to internals.settings.
37824
37825 2012-10-23  Filip Spacek  <fspacek@rim.com>
37826
37827         [BlackBerry] Improve the use of stencil buffer during compositing
37828         https://bugs.webkit.org/show_bug.cgi?id=100020
37829
37830         We always want to scissor so remove the define.
37831         Only turn stenciling on if needed.
37832
37833         Reviewed by Rob Buis.
37834
37835         Reviewed internally by Arvid Nilsson.
37836
37837         * platform/graphics/blackberry/LayerRenderer.cpp:
37838         (WebCore::LayerRenderer::setViewport):
37839         (WebCore::LayerRenderer::compositeLayers):
37840         (WebCore::LayerRenderer::drawLayersOnSurfaces):
37841         (WebCore::LayerRenderer::compositeLayersRecursive):
37842         (WebCore::LayerRenderer::updateScissorIfNeeded):
37843
37844 2012-10-23  'Pavel Feldman'  <pfeldman@chromium.org>
37845
37846         Not reviewed: kick out non-chromium files from WebCore.gypi.
37847
37848         * WebCore.gypi:
37849
37850 2012-10-23  Alexander Shalamov  <alexander.shalamov@intel.com>
37851
37852         [EFL][WK2] ecore_x should be initialised in WebProcess to avoid re-initialization by PlatformScreenEfl utilities and systemBeep() function
37853         https://bugs.webkit.org/show_bug.cgi?id=100110
37854
37855         Reviewed by Kenneth Rohde Christiansen.
37856
37857         Removed initialization of ecore_x, since it is initialized when process starts.
37858
37859         test: fast/media/*
37860
37861         * platform/efl/PlatformScreenEfl.cpp:
37862         (WebCore::screenDepth):
37863         (WebCore::screenRect):
37864         * platform/efl/SoundEfl.cpp:
37865         (WebCore::systemBeep):
37866
37867 2012-10-23  Adam Klein  <adamk@chromium.org>
37868
37869         Always parse pasted fragments as HTML even on XHTML pages
37870         https://bugs.webkit.org/show_bug.cgi?id=99880
37871
37872         Reviewed by Ojan Vafai.
37873
37874         When pasting HTML into a page, using the XML parser is unlikely
37875         to work correctly, as the contents of the clipboard are unlikely
37876         to be properly-formed XHTML. Thus, for the pasting case, it's always
37877         better to use HTML parsing, which will properly parse either HTML
37878         (which is what's usually in the clipboard) or XHTML (which is
37879         sometimes there as well).
37880
37881         The Mac port previously worked around this problem by falling back to plain text
37882         when parsing failed, but switching to HTML seems like a clear improvement.
37883
37884         This also fixes a crash in Chromium (see http://webkit.org/b/99607
37885         and http://crbug.com/136218); it erroneously assumed that createFragmentFromMarkup()
37886         would never return null. This patch makes that true.
37887
37888         * editing/markup.cpp:
37889         (WebCore::createFragmentFromMarkup): Don't delegate to createContextualFragment:
37890         we already know our context element is safe (i.e., it's <body>),
37891         and we want to force HTML (not XML) parsing.
37892
37893 2012-10-23  Allan Sandfeld Jensen  <allan.jensen@digia.com>
37894
37895         [Qt] REGRESSION (r130851): fast/text/word-space-with-kerning.html fails
37896         https://bugs.webkit.org/show_bug.cgi?id=98876
37897
37898         Reviewed by Simon Hausmann.
37899
37900         Do not add word-spacing for leading space. This matches what simple path font-width does.
37901
37902         Tested by existing tests.
37903
37904         * platform/graphics/qt/FontQt.cpp:
37905         (WebCore::Font::floatWidthForComplexText):
37906
37907 2012-10-23  Alexander Pavlov  <apavlov@chromium.org>
37908
37909         Web Inspector: Incorrect resolution of relative URLs containing a scheme in query parameters
37910         https://bugs.webkit.org/show_bug.cgi?id=100084
37911
37912         Reviewed by Vsevolod Vlasov.
37913
37914         Use the RFC 3986 grammar for the URL scheme.
37915
37916         * inspector/front-end/ParsedURL.js:
37917         (WebInspector.ParsedURL):
37918
37919 2012-10-23  Eugene Klyuchnikov  <eustas.bug@gmail.com>
37920
37921         Web Inspector: Elaborate source panel sidebar context menus.
37922         https://bugs.webkit.org/show_bug.cgi?id=99980
37923
37924         Reviewed by Vsevolod Vlasov.
37925
37926         - Watches: add "Add watch expression" item to items and empty element
37927         - Watches: hide "Remove watch expression" from editing prompt context menu
37928         - Watches: add titles to header buttons
37929         - XHR Breakpoints: add "Add Breakpoint" item to items and empty element
37930         - XHR Breakpoints: add "Remove all breakpoints" item to items (when >1)
37931         - XHR Breakpoints: add title to header button
37932         - JS Breakpoints: hide "Remove/(De)Activate breakpoints" when only 1 item present
37933         - JS Breakpoints: add "(De)Activate breakpoints" to empty element context menu
37934
37935         * English.lproj/localizedStrings.js: Added corresponding strings.
37936         * inspector/front-end/BreakpointsSidebarPane.js: Adjusted context menu.
37937         (WebInspector.XHRBreakpointsSidebarPane): Ditto.
37938         * inspector/front-end/ObjectPropertiesSection.js: Added "isEditing()"
37939         * inspector/front-end/WatchExpressionsSidebarPane.js: Adjusted context menu.
37940
37941 2012-10-23  Kent Tamura  <tkent@chromium.org>
37942
37943         Update binding test results for r132194
37944         https://bugs.webkit.org/show_bug.cgi?id=100097
37945
37946         * bindings/scripts/test/V8/V8TestObj.cpp:
37947         (WebCore::V8TestObj::installPerContextProperties):
37948
37949 2012-10-23  Alexander Pavlov  <apavlov@chromium.org>
37950
37951         Web Inspector: Sass can only resolve same folder paths
37952         https://bugs.webkit.org/show_bug.cgi?id=99259
37953
37954         Reviewed by Vsevolod Vlasov.
37955
37956         The actual reason is that the rule source location linkifier tries to linkify a resource (*.scss), which does not exist,
37957         and falls back to just stripping the main page URL prefix from the rule location URL. This change introduces LiveLocations
37958         for CSSRule locations and makes sure they are linkified using uiSourceCode's parsedURL.displayName.
37959
37960         * inspector/front-end/CSSStyleModel.js:
37961         (WebInspector.CSSStyleModel): Introduced LiveLocation management for CSSRules.
37962         (WebInspector.CSSStyleModel.prototype.setSourceMapping):
37963         (WebInspector.CSSStyleModel.prototype._updateLocations):
37964         (WebInspector.CSSStyleModel.prototype.createLiveLocation):
37965         (WebInspector.CSSStyleModel.prototype.updateLocations):
37966         (WebInspector.CSSStyleModel.LiveLocation): A LiveLocation for the CSS domain.
37967         (WebInspector.CSSStyleModel.LiveLocation.prototype.uiLocation):
37968         (WebInspector.CSSStyleModel.LiveLocation.prototype.dispose):
37969         * inspector/front-end/Linkifier.js:
37970         (WebInspector.Linkifier.prototype.linkifyCSSRuleLocation): CSSRule LiveLocation-based link builder.
37971         (WebInspector.Linkifier.DefaultFormatter.prototype.formatLiveAnchor): Add a title for anchors.
37972         (WebInspector.Linkifier.DefaultCSSFormatter): Formatter for CSS location links.
37973         (WebInspector.Linkifier.DefaultCSSFormatter.prototype.formatLiveAnchor):
37974         * inspector/front-end/ResourceUtils.js:
37975         (WebInspector.displayNameForURL): Use parsedURL.displayName if uiSourceCode is present for the specified URL.
37976         * inspector/front-end/SASSSourceMapping.js:
37977         * inspector/front-end/StylesSidebarPane.js:
37978         (WebInspector.StylesSidebarPane):
37979         (WebInspector.StylesSidebarPane.prototype._innerRebuildUpdate):
37980         * inspector/front-end/inspector.html:
37981
37982 2012-10-23  Sheriff Bot  <webkit.review.bot@gmail.com>
37983
37984         Unreviewed, rolling out r132149.
37985         http://trac.webkit.org/changeset/132149
37986         https://bugs.webkit.org/show_bug.cgi?id=100098
37987
37988         Breaks inspector profiler tests in debug mode. (Requested by
37989         pfeldman1 on #webkit).
37990
37991         * rendering/AutoTableLayout.cpp:
37992         (WebCore::AutoTableLayout::recalcColumn):
37993         * rendering/FixedTableLayout.cpp:
37994         (WebCore::FixedTableLayout::calcWidthArray):
37995         * rendering/RenderTable.cpp:
37996         (WebCore::RenderTable::layout):
37997         * rendering/RenderTableCol.cpp:
37998         (WebCore::RenderTableCol::styleDidChange):
37999         (WebCore::RenderTableCol::updateFromElement):
38000         (WebCore::RenderTableCol::computePreferredLogicalWidths):
38001         * rendering/RenderTableCol.h:
38002         (RenderTableCol):
38003
38004 2012-10-23  Simon Hausmann  <simon.hausmann@digia.com>
38005
38006         Unreviewed trivial Qt build fix: Fix build without USE_3D_GRAPHICS
38007
38008         Move the #if USE(GRAPHICS_SURFACE) up to protect the inclusion of
38009         GraphicsContext3D.h to be done only if we use the surface.
38010
38011         * platform/graphics/surfaces/GraphicsSurface.h:
38012
38013 2012-10-23  Sheriff Bot  <webkit.review.bot@gmail.com>
38014
38015         Unreviewed, rolling out r132033.
38016         http://trac.webkit.org/changeset/132033
38017         https://bugs.webkit.org/show_bug.cgi?id=100097
38018
38019         Broke calendar picker (Requested by tkent on #webkit).
38020
38021         * bindings/scripts/CodeGeneratorV8.pm:
38022         (GenerateImplementation):
38023
38024 2012-10-23  Andras Becsi  <andras.becsi@digia.com>
38025
38026         Remove devicePixelRatio from ViewportAttributes
38027         https://bugs.webkit.org/show_bug.cgi?id=99845
38028
38029         Reviewed by Adam Barth.
38030
38031         Since r121555 the devicePixelRatio is not calculated any more
38032         and the scale factor is stored in Page::m_deviceScaleFactor,
38033         thus it can be removed from ViewportAttributes to reduce
38034         redundancy and unnecessary client code.
38035         Use a new parameter in viewport calculation functions using
38036         the visible viewport size (instead of passing the adjusted
38037         viewport size) so that after this change clients do not end
38038         up using the unadjusted viewport size for calculations.
38039
38040         No behavioural change, no new tests needed.
38041
38042         * WebCore.exp.in:
38043         * dom/ViewportArguments.cpp:
38044         (WebCore::computeViewportAttributes):
38045         (WebCore::computeMinimumScaleFactorForContentContained):
38046         Add the devicePixelRatio as a parameter.
38047         (WebCore::restrictMinimumScaleFactorToViewportSize): Ditto.
38048         * dom/ViewportArguments.h:
38049         (ViewportAttributes):
38050         (WebCore):
38051         * testing/InternalSettings.cpp:
38052         (WebCore::InternalSettings::configurationForViewport):
38053
38054 2012-10-23  Kent Tamura  <tkent@chromium.org>
38055
38056         Support full month names in DateTimeEditElement, and use them in input[type=month] by default
38057         https://bugs.webkit.org/show_bug.cgi?id=100060
38058
38059         Reviewed by Kentaro Hara.
38060
38061         According to https://plus.google.com/104770450049736549185/posts/4zsoeHoa7SM
38062         no one wants to show abbreviated month names for input[type=month].
38063         This change add support for full month names in DateTimeEditELement, and
38064         LocaleICU and LocaleMac retun month formats with full month names. Note
38065         that LocaleWin::monthFormat returns formats for full month names.
38066
38067         No new tests. Covered by fast/forms/month-multiple-fields/month-multiple-fields-appearance-*.html
38068
38069         * html/shadow/DateTimeEditElement.cpp:
38070         (WebCore::DateTimeEditBuilder::visitField):
38071         If count is 4, use Localizer::monthLabels or standAloneMonthLabels.
38072         * platform/text/LocaleICU.cpp:
38073         (WebCore::LocaleICU::monthFormat):
38074         Returns a format for full month names.
38075         * platform/text/mac/LocaleMac.mm:
38076         (WebCore::LocaleMac::monthFormat): Ditto.
38077
38078 2012-10-23  Mike West  <mkwst@chromium.org>
38079
38080         Viewport errors should be slightly friendlier with regard to ';'.
38081         https://bugs.webkit.org/show_bug.cgi?id=100003
38082
38083         Reviewed by Adam Barth.
38084
38085         This patch scans viewport values that cause errors for ';'. If found,
38086         a quick message is appended to the error, noting that semicolons are
38087         not valid separators in viewport contents, and that commas would be
38088         the proper substitute.
38089
38090         No functional changes, just a better error message.
38091
38092         * dom/ViewportArguments.cpp:
38093         (WebCore::reportViewportWarning):
38094
38095 2012-10-23  Timothy Hatcher  <timothy@apple.com>
38096
38097         Docking/undocking the Web Inspector does not work correctly in Safari.
38098
38099         The "docked" and "bottom" strings need quoted instead of being passed as identifiers.
38100
38101         https://bugs.webkit.org/show_bug.cgi?id=100080
38102
38103         Reviewed by Yury Semikhatsky.
38104
38105         * inspector/InspectorFrontendClientLocal.cpp:
38106         (WebCore::InspectorFrontendClientLocal::setAttachedWindow): Put quotes around the %s.
38107
38108 2012-10-23  Sudarsana Nagineni  <sudarsana.nagineni@intel.com>
38109
38110         [EFL][WK2] Compilation warning in GraphicsContext3DPrivate.cpp when AC is enabled
38111         https://bugs.webkit.org/show_bug.cgi?id=99723
38112
38113         Reviewed by Kenneth Rohde Christiansen.
38114
38115         Fix compilation warning in GraphicsContext3DPrivate.cpp when AC is
38116         enabled.
38117
38118         No new tests, no change in behavior.
38119
38120         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
38121         (WebCore::GraphicsContext3DPrivate::createSurface):
38122
38123 2012-10-23  Dan Carney  <dcarney@google.com>
38124
38125         When blocking localStorage, Firefox throws a security exception on access, and maybe so should we
38126         https://bugs.webkit.org/show_bug.cgi?id=63257
38127
38128         Reviewed by Jochen Eisinger.
38129
38130         Throw security exception when local storage is accessed
38131         under certain circumstances to match firefox.
38132
38133         No new tests. Existing tests modified.
38134
38135         * bindings/js/JSStorageCustom.cpp:
38136         (WebCore::JSStorage::canGetItemsForName):
38137         (WebCore::JSStorage::nameGetter):
38138         (WebCore::JSStorage::deleteProperty):
38139         (WebCore::JSStorage::getOwnPropertyNames):
38140         * bindings/v8/custom/V8StorageCustom.cpp:
38141         (WebCore):
38142         (WebCore::setDOMException):
38143         (WebCore::V8Storage::namedPropertyEnumerator):
38144         (WebCore::storageGetter):
38145         (WebCore::V8Storage::namedPropertyQuery):
38146         (WebCore::storageDeleter):
38147         * inspector/InspectorDOMStorageAgent.cpp:
38148         (WebCore::InspectorDOMStorageAgent::getDOMStorageEntries):
38149         (WebCore::InspectorDOMStorageAgent::removeDOMStorageItem):
38150         * page/DOMWindow.cpp:
38151         (WebCore::DOMWindow::sessionStorage):
38152         (WebCore::DOMWindow::localStorage):
38153         * storage/Storage.cpp:
38154         * storage/Storage.h:
38155         (WebCore):
38156         (WebCore::Storage::length):
38157         (WebCore::Storage::key):
38158         (WebCore::Storage::getItem):
38159         (WebCore::Storage::setItem):
38160         (WebCore::Storage::removeItem):
38161         (WebCore::Storage::clear):
38162         (WebCore::Storage::contains):
38163         * storage/Storage.idl:
38164         * storage/StorageArea.h:
38165         (StorageArea):
38166         * storage/StorageAreaImpl.cpp:
38167         (WebCore::StorageAreaImpl::canAccessStorage): Checks whether access to storage is a security violation.
38168         (WebCore):
38169         (WebCore::StorageAreaImpl::disabledByPrivateBrowsingInFrame):
38170         (WebCore::StorageAreaImpl::length):
38171         (WebCore::StorageAreaImpl::key):
38172         (WebCore::StorageAreaImpl::getItem):
38173         (WebCore::StorageAreaImpl::setItem):
38174         (WebCore::StorageAreaImpl::removeItem):
38175         (WebCore::StorageAreaImpl::clear):
38176         (WebCore::StorageAreaImpl::contains):
38177         * storage/StorageAreaImpl.h:
38178         (StorageAreaImpl):
38179
38180 2012-10-22  Joshua Bell  <jsbell@chromium.org>
38181
38182         IndexedDB: Remove custom binding code for IDBCursor.value
38183         https://bugs.webkit.org/show_bug.cgi?id=100034
38184
38185         Reviewed by Kentaro Hara.
38186
38187         Now that we're using ScriptValue instead of SerializedScriptValue we can just expose
38188         IDBCursor.value as an |any| (IDL) or |ScriptValue| (C++) to maintain the specified
38189         semantics that the object identity is retained across accesses.
38190
38191         Test: storage/indexeddb/cursor-value.html
38192
38193         * Modules/indexeddb/IDBCursor.cpp: Remove "dirty" tracking.
38194         (WebCore::IDBCursor::IDBCursor):
38195         (WebCore::IDBCursor::value):
38196         (WebCore::IDBCursor::setValueReady):
38197         * Modules/indexeddb/IDBCursor.h: IDBAny -> ScriptValue
38198         (IDBCursor):
38199         * Modules/indexeddb/IDBCursorWithValue.idl: IDBAny -> any
38200         * Modules/indexeddb/IDBObjectStore.cpp: No need to route through IDBAny to get ScriptValue.
38201         (WebCore):
38202         * UseV8.cmake: Remove references to IDBCustomBindings.cpp
38203         * WebCore.gypi: Ditto.
38204         * WebCore.vcproj/WebCore.vcproj: Ditto.
38205         * bindings/v8/IDBCustomBindings.cpp: Removed.
38206
38207 2012-10-22  Dan Bernstein  <mitz@apple.com>
38208
38209         Font’s fast code path is used for partial runs with kerning and ligatures, but shouldn’t be
38210         https://bugs.webkit.org/show_bug.cgi?id=100068
38211
38212         Reviewed by Sam Weinig.
38213
38214         As described in <http://webkit.org/b/100050>, the fast code path doesn’t handle partial runs
38215         correctly when kerning or ligatures are enabled. Since the partial-run case is uncommon,
38216         for now just use the complex code path in this case.
38217
38218         * platform/graphics/Font.cpp:
38219         (WebCore::Font::drawText): Changed to use the complex path for partial runs if there are any
38220         typesetting features.
38221         (WebCore::Font::drawEmphasisMarks): Ditto.
38222         (WebCore::Font::selectionRectForText): Ditto.
38223         (WebCore::Font::offsetForPosition): Changed to use the complex path if there are any
38224         typesetting features.
38225
38226 2012-10-22  Peter Wang  <peter.wang@torchmobile.com.cn>
38227
38228         [BlackBerry] Missing some cookies in HTTP response header when set several cookies in one "Set-Cookie" header.
38229         https://bugs.webkit.org/show_bug.cgi?id=99950
38230
38231         Reviewed by George Staikos.
38232
38233         In "NetworkJob::handleNotifyHeaderReceived", if there are several "Set-Cookie" headers, 
38234         we should combine the following ones with the first.
38235
38236         No new test case.
38237
38238         * platform/network/blackberry/NetworkJob.cpp:
38239         (WebCore::NetworkJob::handleNotifyHeaderReceived):
38240
38241 2012-10-22  MORITA Hajime  <morrita@google.com>
38242
38243         Assertion failed at WebCore::toInsertionPoint / WebCore::ContentDistributor::distribute
38244         https://bugs.webkit.org/show_bug.cgi?id=100038
38245
38246         Reviewed by Kent Tamura.
38247
38248         isHTMLContentElement() assumes that the content element always has
38249         a tag name "content" but it doesn't when Shadow DOM feature is
38250         disabled. This fix let the function see the correct tag name.
38251
38252         Test: fast/dom/shadow/insertion-points-with-shadow-disabled.html
38253
38254         * html/shadow/HTMLContentElement.cpp:
38255         (WebCore::HTMLContentElement::contentTagName):
38256         * html/shadow/HTMLContentElement.h:
38257         (HTMLContentElement):
38258         (WebCore::isHTMLContentElement):
38259
38260 2012-10-22  Shinya Kawanaka  <shinyak@chromium.org>
38261
38262         [Shadow] Fallback content should also be reprojection.
38263         https://bugs.webkit.org/show_bug.cgi?id=99750
38264
38265         Reviewed by Dimitri Glazkov.
38266
38267         Fallback content of InsertionPoint should be reprojected. The existing assumption that
38268         only the direct child of host element can be distributed to InsertionPoint does not hold anymore.
38269         So, if the parent of an element is InsertionPoint which should show fallback element, we have to
38270         check the grand parent of the element instead of the element.
38271
38272         Tests: fast/dom/shadow/content-reprojection-fallback-reprojection.html
38273                fast/dom/shadow/content-reprojection-fallback.html
38274
38275         * css/StyleResolver.cpp:
38276         (WebCore::shouldResetStyleInheritance): Checks the grandparent of the element if the parent is
38277         an InsertionPoint which uses fallback content.
38278         * dom/ComposedShadowTreeWalker.cpp:
38279         (WebCore::shadowOfParentForDistribution):
38280         (WebCore):
38281         (WebCore::resolveReprojection):
38282         (WebCore::ComposedShadowTreeWalker::traverseParent):
38283         * html/shadow/InsertionPoint.cpp:
38284         (WebCore::InsertionPoint::shouldUseFallbackElements): True if the InsertionPoint should use fallback content.
38285         (WebCore):
38286         * html/shadow/InsertionPoint.h:
38287         (WebCore::parentElementForDistribution): Returns the grandparent element if the parent is InsertionPoint which uses
38288         fallback content. Returns parent element otherwise.
38289         (WebCore):
38290
38291 2012-10-22  Keishi Hattori  <keishi@webkit.org>
38292
38293         Label position is wrong in the suggestion picker when all the suggestions have labels
38294         https://bugs.webkit.org/show_bug.cgi?id=99965
38295
38296         Reviewed by Kent Tamura.
38297
38298         Somehow the scrollbar was appearing and so the label element was being wrapped to the next line.
38299
38300         No new tests. Can't reproduce in layout test.
38301
38302         * Resources/pagepopups/suggestionPicker.css:
38303         (.suggestion-list):
38304         * Resources/pagepopups/suggestionPicker.js:
38305         (SuggestionPicker.prototype._fixWindowSize): Explicitly show the scroll bar.
38306
38307 2012-10-22  MORITA Hajime  <morrita@google.com>
38308
38309         [Chromium] Needs to track ShadowRoot usage
38310         https://bugs.webkit.org/show_bug.cgi?id=99955
38311
38312         Reviewed by Dimitri Glazkov.
38313
38314         Added an UMA instrumentation.
38315
38316         * dom/ShadowRoot.cpp:
38317         (WebCore::determineUsageType):
38318         (WebCore):
38319         (WebCore::ShadowRoot::create):
38320
38321 2012-10-22  Kent Tamura  <tkent@chromium.org>
38322
38323         Introduce Localizer::standAloneMonthLabels
38324         https://bugs.webkit.org/show_bug.cgi?id=99963
38325
38326         Reviewed by Kentaro Hara.
38327
38328         We realized full month names and full stand-alone month names were
38329         necessary for input[type=month] UI. We change the compile-flag for
38330         Localizer::monthLabels from "ENABLE(CALENDAR_PICKER)" to
38331         "ENABLE(CALENDAR_PICKER) || ENABLE(INPUT_MULTIPLE_FIELDS_UI)," and
38332         introduce Localizer::standAloneMonthLabels.
38333
38334         Tests: Add some test cases to Source/WebKit/chromium/LocaleMacTest.cpp
38335         and LocalizedDateICUTest.cpp.
38336
38337         * platform/text/Localizer.h:
38338         (Localizer):
38339         - Add pure virtual standAloneMonthLabels.
38340         - Change the condition for monthLabels.
38341
38342         * platform/text/LocaleNone.cpp:
38343         (LocaleNone): Declare monthLabels, standAloneMonthLabels, and m_monthLabels.
38344         (WebCore::LocaleNone::monthLabels):
38345         Added. It always returns English month names.
38346         (WebCore::LocaleNone::standAloneMonthLabels):
38347         Added. Just calls monthLabels.
38348
38349         * platform/text/LocaleWin.h:
38350         (LocaleWin):
38351         Declare standAloneMonthLabels, and change the condition for monthLabels.
38352         * platform/text/LocaleWin.cpp:
38353         (WebCore): Change the condition for monthLabels.
38354         (WebCore::LocaleWin::standAloneMonthLabels):
38355         Added. Just calls monthLabels.
38356
38357         * platform/text/mac/LocaleMac.h:
38358         (LocaleMac):
38359         - Add standAloneMonthLabels and m_standAloneMonthLabels
38360         - Change the condition for monthLabels and m_monthLabels.
38361         * platform/text/mac/LocaleMac.mm:
38362         (WebCore): Change the condition for monthLabels.
38363         (WebCore::LocaleMac::standAloneMonthLabels):
38364         Added. Get the information with NSDateFormatter::standaloneMonthSymbols.
38365
38366         * platform/text/LocaleICU.h:
38367         (LocaleICU):
38368         - Add standAloneMonthLabels and m_standAloneMonthLabels
38369         - Change the condition for monthLabels and m_monthLabels.
38370         * platform/text/LocaleICU.cpp:
38371         (WebCore::LocaleICU::initializeCalendar):
38372         Remove m_monthLabels initialization in order to avoid dependecy from monthLabels.
38373         (WebCore):
38374         (WebCore::createFallbackMonthLabels): Change the compile condition.
38375         (WebCore::LocaleICU::monthLabels):
38376         - Change the compile condition.
38377         - Don't depend on initializeCalendar to make the code for
38378         ENABLE(INPUT_MULTIPLE_FIELDS_UI) && !ENABLE(CALENDAR_PICKER) minimal.
38379         (WebCore::LocaleICU::standAloneMonthLabels):
38380         Added. The code is similar to shortStandAloneMonthLabels.
38381
38382 2012-10-22  Shinya Kawanaka  <shinyak@chromium.org>
38383
38384         Refactoring around ContainerNode::attachChildren
38385         https://bugs.webkit.org/show_bug.cgi?id=99968
38386
38387         Reviewed by Hajime Morita.
38388
38389         Since ContainerNode::attach() is now equivalent to ContainerNode::attachChildren() + Node::attach(), we should call
38390         ContainerNode::attach() instead of calling them.
38391
38392         No new tests, no change in behavior.
38393
38394         * dom/ContainerNode.h:
38395         (ContainerNode):
38396         * dom/Element.cpp:
38397         (WebCore::Element::attach):
38398         * dom/ShadowRoot.cpp:
38399         (WebCore::ShadowRoot::attach):
38400
38401 2012-10-22  Michael Saboff  <msaboff@apple.com>
38402
38403         HTML Parser should produce 8 bit strings for doctype, comment and tagName tokens
38404         https://bugs.webkit.org/show_bug.cgi?id=99889
38405
38406         Reviewed by Geoffrey Garen.
38407
38408         Added 8 bit check for accumulating all token data in MarkupTokenBase.  Added code to convert
38409         "name" token data directly to a string (8 or 16 as appropriate).  Changed to accumulate
38410         m_bufferedEndTagName as LChar's.
38411
38412         No new tests, covered by existing tests.
38413
38414         * html/parser/HTMLToken.h:
38415         (HTMLToken):
38416         * html/parser/HTMLTokenizer.cpp:
38417         (WebCore::HTMLTokenizer::nextToken):
38418         (WebCore::HTMLTokenizer::addToPossibleEndTag):
38419         (WebCore::HTMLTokenizer::isAppropriateEndTag):
38420         * html/parser/HTMLTokenizer.h:
38421         (HTMLTokenizer):
38422         * html/parser/HTMLTreeBuilder.cpp:
38423         (WebCore::HTMLTreeBuilder::ExternalCharacterTokenBuffer::takeLeading):
38424         * xml/parser/MarkupTokenBase.h:
38425         (WebCore::MarkupTokenBase::beginStartTag):
38426         (WebCore::MarkupTokenBase::beginEndTag):
38427         (MarkupTokenBase):
38428         (WebCore::MarkupTokenBase::beginDOCTYPE):
38429         (WebCore::MarkupTokenBase::appendToComment):
38430         (WebCore::MarkupTokenBase::appendToName):
38431         (WebCore::MarkupTokenBase::nameString):
38432         (WebCore::AtomicMarkupTokenBase::AtomicMarkupTokenBase):
38433
38434 2012-10-22  Tony Chang  <tony@chromium.org>
38435
38436         margin-top/bottom has no effect for child nodes of flex items
38437         https://bugs.webkit.org/show_bug.cgi?id=99923
38438
38439         Reviewed by Ojan Vafai.
38440
38441         Flexitems, like table cells, shouldn't collapse margins.
38442
38443         Test: css3/flexbox/flexitem-no-margin-collapsing.html
38444
38445         * rendering/RenderBlock.cpp:
38446         (WebCore::RenderBlock::MarginInfo::MarginInfo): Check to see if the parent is a flexible box.
38447         We should always have a parent if we make it this far in the check.
38448
38449 2012-10-22  Marja Hölttä  <marja@chromium.org>
38450
38451         Refactor CachedResourceLoader: add CachedResourceRequest
38452         https://bugs.webkit.org/show_bug.cgi?id=99736
38453
38454         Reviewed by Adam Barth.
38455
38456         For fixing bugs 84883 and 92761,
38457         CachedResourceLoader::requestResource should take as parameter
38458         information about who initiated the request. But the parameter
38459         list was already long. This gathers all the parameters into a
38460         separate class, CachedResourceRequest. The next step is to add
38461         information about who initiated the request into
38462         CachedResourceRequest.
38463
38464         No new tests because no changes in functionality, just moving code
38465         around.
38466
38467         * CMakeLists.txt:
38468         * GNUmakefile.list.am:
38469         * Target.pri:
38470         * WebCore.gypi:
38471         * WebCore.vcproj/WebCore.vcproj:
38472         * WebCore.xcodeproj/project.pbxproj:
38473         * css/CSSFontFaceSrcValue.cpp:
38474         (WebCore::CSSFontFaceSrcValue::cachedFont):
38475         * css/CSSImageSetValue.cpp:
38476         (WebCore::CSSImageSetValue::cachedImageSet):
38477         * css/CSSImageValue.cpp:
38478         (WebCore::CSSImageValue::cachedImage):
38479         * css/StyleRuleImport.cpp:
38480         (WebCore::StyleRuleImport::requestStyleSheet):
38481         * css/WebKitCSSSVGDocumentValue.cpp:
38482         (WebCore::WebKitCSSSVGDocumentValue::load):
38483         * css/WebKitCSSShaderValue.cpp:
38484         (WebCore::WebKitCSSShaderValue::cachedShader):
38485         * dom/ProcessingInstruction.cpp:
38486         (WebCore::ProcessingInstruction::checkStyleSheet):
38487         * dom/ScriptElement.cpp:
38488         (WebCore::ScriptElement::requestScript):
38489         * html/HTMLLinkElement.cpp:
38490         (WebCore::HTMLLinkElement::process):
38491         * loader/DocumentThreadableLoader.cpp:
38492         (WebCore::DocumentThreadableLoader::loadRequest):
38493         * loader/ImageLoader.cpp:
38494         (WebCore::ImageLoader::updateFromElement):
38495         * loader/LinkLoader.cpp:
38496         (WebCore::LinkLoader::loadLink):
38497         * loader/TextTrackLoader.cpp:
38498         (WebCore::TextTrackLoader::load):
38499         * loader/cache/CachedResourceLoader.cpp:
38500         (WebCore::CachedResourceLoader::requestImage):
38501         (WebCore::CachedResourceLoader::requestFont):
38502         (WebCore::CachedResourceLoader::requestTextTrack):
38503         (WebCore::CachedResourceLoader::requestShader):
38504         (WebCore::CachedResourceLoader::requestCSSStyleSheet):
38505         (WebCore::CachedResourceLoader::requestUserCSSStyleSheet):
38506         (WebCore::CachedResourceLoader::requestScript):
38507         (WebCore::CachedResourceLoader::requestXSLStyleSheet):
38508         (WebCore::CachedResourceLoader::requestSVGDocument):
38509         (WebCore::CachedResourceLoader::requestLinkResource):
38510         (WebCore::CachedResourceLoader::requestRawResource):
38511         (WebCore::CachedResourceLoader::requestResource):
38512         (WebCore::CachedResourceLoader::requestPreload):
38513         (WebCore::CachedResourceLoader::defaultCachedResourceOptions):
38514         (WebCore):
38515         * loader/cache/CachedResourceLoader.h:
38516         (WebCore):
38517         (CachedResourceLoader):
38518         * loader/cache/CachedResourceRequest.cpp: Added.
38519         (WebCore):
38520         (WebCore::CachedResourceRequest::CachedResourceRequest):
38521         * loader/cache/CachedResourceRequest.h: Added.
38522         (WebCore):
38523         (CachedResourceRequest):
38524         (WebCore::CachedResourceRequest::mutableResourceRequest):
38525         (WebCore::CachedResourceRequest::resourceRequest):
38526         (WebCore::CachedResourceRequest::charset):
38527         (WebCore::CachedResourceRequest::setCharset):
38528         (WebCore::CachedResourceRequest::options):
38529         (WebCore::CachedResourceRequest::priority):
38530         (WebCore::CachedResourceRequest::forPreload):
38531         (WebCore::CachedResourceRequest::setForPreload):
38532         (WebCore::CachedResourceRequest::defer):
38533         (WebCore::CachedResourceRequest::setDefer):
38534         * loader/icon/IconLoader.cpp:
38535         (WebCore::IconLoader::startLoading):
38536         * svg/SVGFEImageElement.cpp:
38537         (WebCore::SVGFEImageElement::requestImageResource):
38538         * svg/SVGFontFaceUriElement.cpp:
38539         (WebCore::SVGFontFaceUriElement::loadFont):
38540         * svg/SVGUseElement.cpp:
38541         (WebCore::SVGUseElement::svgAttributeChanged):
38542         * xml/XSLImportRule.cpp:
38543         (WebCore::XSLImportRule::loadSheet):
38544
38545 2012-10-22  Adam Barth  <abarth@webkit.org>
38546
38547         [V8] ASSERT that removeAllDOMObjects() is called only on worker threads
38548         https://bugs.webkit.org/show_bug.cgi?id=100046
38549
38550         Reviewed by Eric Seidel.
38551
38552         This function is called only on worker threads. We should ASSERT that
38553         fact and remove the dead code that tries to handle the main thread
38554         case.
38555
38556         * bindings/v8/V8DOMMap.cpp:
38557         (WebCore::removeAllDOMObjects):
38558
38559 2012-10-22  Adam Barth  <abarth@webkit.org>
38560
38561         [V8] We should call the faster v8::Integer::New APIs
38562         https://bugs.webkit.org/show_bug.cgi?id=100016
38563
38564         Reviewed by Eric Seidel.
38565
38566         In working to remove the integer cache, I added some faster APIs for
38567         creating v8::Integers. These APIs are faster than the old APIs, but not
38568         quite fast enough to replace the integer cache. We should still use
38569         them when we miss the integer cache.
38570
38571         I've also included a small refactoring to V8PerIsolateData to make it
38572         clearer when we're calling v8::Isolate::GetCurrent().
38573
38574         * bindings/v8/DOMData.cpp:
38575         (WebCore::DOMData::getCurrentStore):
38576         * bindings/v8/V8Binding.h:
38577         (WebCore::v8ExternalString):
38578         (WebCore::v8Integer):
38579         (WebCore::v8UnsignedInteger):
38580         * bindings/v8/V8PerIsolateData.h:
38581         (WebCore::V8PerIsolateData::current):
38582         (WebCore::V8PerIsolateData::from):
38583         * bindings/v8/V8ValueCache.cpp:
38584         (WebCore::StringCache::v8ExternalStringSlow):
38585         (WebCore::IntegerCache::createSmallIntegers):
38586         * bindings/v8/V8ValueCache.h:
38587         (WebCore::IntegerCache::v8Integer):
38588         (WebCore::IntegerCache::v8UnsignedInteger):
38589         (IntegerCache):
38590         * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
38591         (WebCore::V8HTMLCanvasElement::getContextCallback):
38592
38593 2012-10-22  Julien Chaffraix  <jchaffraix@webkit.org>
38594
38595         RenderTableCol::computePreferredLogicalWidths and RenderTableCol::layout should never be called
38596         https://bugs.webkit.org/show_bug.cgi?id=99861
38597
38598         Reviewed by Ojan Vafai.
38599
38600         RenderTableCol's computePreferredLogicalWidths and layout's only purpose were to clear the preferred logical
38601         widths dirty / layout flag so that we would properly propagate the information to our containing table. This
38602         led to clunky code where the table layout code had to forcefully call RenderTableCol::computePreferredLogicalWidths
38603         or else we would ignore the next layout hint on the <col> or <colgroup>.
38604
38605         Test: fast/table/col-span-change-relayout.html
38606
38607         * rendering/AutoTableLayout.cpp:
38608         (WebCore::AutoTableLayout::recalcColumn):
38609         * rendering/RenderTable.cpp:
38610         (WebCore::RenderTable::layout):
38611         Simplified the code now that we only need to iterate over the sections.
38612
38613         * rendering/FixedTableLayout.cpp:
38614         (WebCore::FixedTableLayout::calcWidthArray):
38615         Removed call to computePreferredLogicalWidths.
38616
38617         * rendering/RenderTableCol.cpp:
38618         (WebCore::RenderTableCol::styleDidChange):
38619         (WebCore::RenderTableCol::updateFromElement):
38620         Forward a layout hint to the table so that we properly recompute the cell's logical withs.
38621
38622         (WebCore::RenderTableCol::computePreferredLogicalWidths):
38623         (WebCore::RenderTableCol::layout):
38624         Change our implementations of those 2 methods to be no-ops, while enforcing that they are
38625         never called.
38626
38627         (WebCore::RenderTableCol::propagateLayoutCueToTable):
38628         New helper function that forward any layout cue to the containing table, this works around
38629         us not clearing the flags which confuses RenderObject markContainingBlocksForLayout and
38630         invalidateContainerPreferredLogicalWidths.
38631
38632         * rendering/RenderTableCol.h:
38633         Made the function that we are not expected to be called private.
38634
38635 2012-10-22  Pan Deng  <pan.deng@intel.com>
38636
38637         [User Timing]Integrate with Perforamnce Timeline.
38638         https://bugs.webkit.org/show_bug.cgi?id=91072.
38639
38640         Reviewed by Tony Gentilcore.
38641
38642         This patch expose user timing entries via performance timeline interface. JavaScriptCore custom binding will be another patch
38643
38644         No new tests, user timing test cases have been landed.
38645
38646         * page/Performance.cpp:
38647         (WebCore::Performance::Performance):
38648         (WebCore::Performance::webkitGetEntries):
38649         (WebCore::Performance::webkitGetEntriesByType):
38650         (WebCore::Performance::webkitGetEntriesByName):
38651         * page/PerformanceEntry.h:
38652         (WebCore::PerformanceEntry::startTimeCompareLessThan):
38653         (PerformanceEntry):
38654         * page/PerformanceEntryList.cpp:
38655         (WebCore::PerformanceEntryList::sort):
38656         (WebCore):
38657         * page/PerformanceEntryList.h:
38658         (PerformanceEntryList):
38659         * page/PerformanceUserTiming.cpp:
38660         (WebCore::convertToEntrySequence):
38661         (WebCore):
38662         (WebCore::getEntrySequenceByName):
38663         (WebCore::UserTiming::getMarks):
38664         (WebCore::UserTiming::getMeasures):
38665         * page/PerformanceUserTiming.h:
38666         (UserTiming):
38667
38668 2012-10-22  Pan Deng  <pan.deng@intel.com>
38669
38670         Modify obsolete code in User Timing
38671         https://bugs.webkit.org/show_bug.cgi?id=99851
38672
38673         Reviewed by Tony Gentilcore.
38674
38675         Modify user timing implementation as PlatformString.h, prefix of webkitNow is removed, etc.
38676
38677         No new tests.
38678
38679         * page/PerformanceUserTiming.cpp:
38680         (WebCore::insertPerformanceEntry):
38681         (WebCore::UserTiming::mark):
38682         (WebCore::UserTiming::measure):
38683         * page/PerformanceUserTiming.h:
38684
38685 2012-10-22  Mark Lam  <mark.lam@apple.com>
38686
38687         Change stack recursion checks to be based on stack availability.
38688         https://bugs.webkit.org/show_bug.cgi?id=99872.
38689
38690         Reviewed by Filip Pizlo and Geoffrey Garen.
38691
38692         Removed the use of ThreadStackType. Enabled the reserved JSStack space
38693         for error processing before doing work in reportException().
38694
38695         * bindings/js/JSDOMBinding.cpp:
38696         (WebCore::reportException):
38697         * bindings/js/JSDOMWindowBase.cpp:
38698         (WebCore::JSDOMWindowBase::commonJSGlobalData):
38699         * bindings/js/WorkerScriptController.cpp:
38700         (WebCore::WorkerScriptController::WorkerScriptController):
38701
38702 2012-10-22  Andreas Kling  <kling@webkit.org>
38703
38704         REGRESSION(r131104): Heap-use-after-free in WebCore::Element::attributeChanged
38705         <http://webkit.org/b/99937>
38706
38707         Reviewed by Anders Carlsson.
38708
38709         Setting the "type" attribute on an HTMLInputElement that has no "value" attribute set will cause the
38710         input type changing mechanism to write a value attribute onto the element. This happens in
38711         HTMLInputElement::updateType(), below parseAttribute().
38712
38713         It's done via Element::setAttribute(), so we end up re-entering Element::setAttributeInternal()
38714         where the 'existingAttribute' pointer may now be invalid if adding the "value" attribute caused
38715         a reallocation in the ElementAttributeData's underlying Vector<Attribute>.
38716
38717         To make it harder to introduce this kind of bug in the future, I changed almost all functions that take
38718         a "const Attribute&" to take a QualifiedName/AtomicString couple instead (the idea being that the 
38719         fewer references into the attribute store we have, the better.)
38720
38721         Test: fast/html/input-type-change-crash.html
38722
38723         * dom/Attr.cpp:
38724         (WebCore::Attr::setValue):
38725         (WebCore::Attr::childrenChanged):
38726         * dom/Element.cpp:
38727         (WebCore::Element::setAttributeInternal):
38728         (WebCore::Element::attributeChanged):
38729         (WebCore::Element::parserSetAttributes):
38730         (WebCore::Element::addAttributeInternal):
38731         (WebCore::Element::didAddAttribute):
38732         (WebCore::Element::didModifyAttribute):
38733         (WebCore::Element::didRemoveAttribute):
38734         * dom/Element.h:
38735         (Element):
38736         * dom/ElementAttributeData.cpp:
38737         (WebCore::ElementAttributeData::cloneDataFrom):
38738         * dom/StyledElement.cpp:
38739         (WebCore::StyledElement::attributeChanged):
38740         * dom/StyledElement.h:
38741         * html/HTMLInputElement.cpp:
38742         (WebCore::HTMLInputElement::updateType):
38743         * svg/SVGElement.cpp:
38744         (WebCore::SVGElement::attributeChanged):
38745         * svg/SVGElement.h:
38746         (SVGElement):
38747
38748 2012-10-22  Joshua Bell  <jsbell@chromium.org>
38749
38750         IndexedDB: Bounds check for IDBCursor.advance() incorrect
38751         https://bugs.webkit.org/show_bug.cgi?id=100014
38752
38753         Reviewed by Tony Chang.
38754
38755         Fix introduced by trac.webkit.org/changeset/131658 restricted cursor.advance()'s argument
38756         as [EnforceRange] unsigned long long, but it's typed as [EnforceRange] unsigned long; the
38757         useless comparison was caught by a clang check.
38758
38759         In lieu of webkit.org/b/96798 make it long long and correct the range check.
38760
38761         Test: storage/indexeddb/cursor-advance.html
38762
38763         * Modules/indexeddb/IDBCursor.cpp:
38764         (WebCore::IDBCursor::advance):
38765         * Modules/indexeddb/IDBCursor.h:
38766         (IDBCursor):
38767         * Modules/indexeddb/IDBCursor.idl:
38768
38769 2012-10-22  Tony Chang  <tony@chromium.org>
38770
38771         WebKit does not support 'flex-wrap: nowrap'
38772         https://bugs.webkit.org/show_bug.cgi?id=99924
38773
38774         Reviewed by Ojan Vafai.
38775
38776         The spec changed back from using none to nowrap for the single-line
38777         flexbox case.
38778         http://dev.w3.org/csswg/css3-flexbox/#flex-wrap-property
38779
38780         No new tests, covered by css3/flexbox/css-properties.html and others.
38781
38782         * css/CSSParser.cpp:
38783         (WebCore::isValidKeywordPropertyAndValue):
38784         * css/CSSPrimitiveValueMappings.h:
38785         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
38786         (WebCore::CSSPrimitiveValue::operator EFlexWrap):
38787         * css/CSSValueKeywords.in:
38788         * rendering/RenderBox.cpp:
38789         (WebCore::isStretchingColumnFlexItem):
38790         (WebCore::RenderBox::sizesLogicalWidthToFitContent):
38791         * rendering/RenderFlexibleBox.cpp:
38792         (WebCore::RenderFlexibleBox::isMultiline):
38793         * rendering/style/RenderStyle.h:
38794         * rendering/style/RenderStyleConstants.h:
38795
38796 2012-10-22  Mike West  <mkwst@chromium.org>
38797
38798         'image/pjpeg' should be treated as an image by Web Inspector.
38799         https://bugs.webkit.org/show_bug.cgi?id=100001
38800
38801         Reviewed by Pavel Feldman.
38802
38803         It's not exactly a "real" MIME type, but it's in use.
38804
38805         * inspector/front-end/NetworkManager.js:
38806         (WebInspector.NetworkManager):
38807             Adding 'image/pjpeg' as an image MIME type.
38808
38809 2012-10-22  Sheriff Bot  <webkit.review.bot@gmail.com>
38810
38811         Unreviewed, rolling out r132119.
38812         http://trac.webkit.org/changeset/132119
38813         https://bugs.webkit.org/show_bug.cgi?id=100019
38814
38815         Fails its own test on Mac platforms. (Requested by leviw on
38816         #webkit).
38817
38818         * page/EventHandler.cpp:
38819         (WebCore::EventHandler::handleGestureEvent):
38820         (WebCore::EventHandler::sendContextMenuEventForGesture):
38821         * page/EventHandler.h:
38822         (EventHandler):
38823
38824 2012-10-22  Hans Muller  <hmuller@adobe.com>
38825
38826         [CSS Exclusions] Points on the bottom and right edges of an exclusion shape should be classified as "outside"
38827         https://bugs.webkit.org/show_bug.cgi?id=98967
38828
38829         Reviewed by Dirk Schulze.
38830
38831         Changed the way lines are represented in the ExclusionShapeInsideInfo and ExclusionShape classes
38832         so that they're consistent with the rendering code that depends on them.  Lines are now defined
38833         by logicalTop, logicalHeight, instead of logicalTop,logicalBottom.  This a clean-up, not a change
38834         in functionality. It's already covered by the existing fast/exclusions LayoutTests.
38835
38836         Test: fast/exclusions/shape-inside/shape-inside-bottom-edge.html
38837
38838         * rendering/ExclusionPolygon.cpp:
38839         (WebCore::ExclusionPolygon::getExcludedIntervals):
38840         (WebCore::ExclusionPolygon::getIncludedIntervals):
38841         * rendering/ExclusionPolygon.h:
38842         * rendering/ExclusionRectangle.cpp:
38843         (WebCore::ExclusionRectangle::getExcludedIntervals):
38844         (WebCore::ExclusionRectangle::getIncludedIntervals):
38845         * rendering/ExclusionRectangle.h:
38846         * rendering/ExclusionShape.h:
38847         (LineSegment): Moved the struct fields below the constructor per webkit style.
38848         (ExclusionShape):
38849         (WebCore::ExclusionShape::minYForLogicalLine):
38850         (WebCore::ExclusionShape::maxYForLogicalLine):
38851         * rendering/ExclusionShapeInsideInfo.cpp:
38852         (WebCore::ExclusionShapeInsideInfo::computeSegmentsForLine):
38853         * rendering/ExclusionShapeInsideInfo.h:
38854         (ExclusionShapeInsideInfo):
38855         (WebCore::ExclusionShapeInsideInfo::lineOverlapsShapeBounds): Changed the test to not include
38856             lines whose logicalTop is equal to the shape's top+height.
38857         * rendering/RenderBlockLineLayout.cpp:
38858         (WebCore::RenderBlock::layoutRunsAndFloatsInRange):
38859
38860 2012-10-22  Chris Rogers  <crogers@google.com>
38861
38862         Update some AudioContext create() method names to latest Web Audio spec
38863         https://bugs.webkit.org/show_bug.cgi?id=99888
38864
38865         Reviewed by Adam Barth.
38866
38867         The following AudioContext method names are being changed, with legacy support for the old names:
38868         createGainNode -> createGain
38869         createDelayNode -> createDelay
38870         createJavaScriptNode -> createScriptProcessor
38871
38872         For details:
38873         https://www.w3.org/Bugs/Public/show_bug.cgi?id=18332
38874
38875         Tests changed: webaudio/delaynode.html, webaudio/gain.html, webaudio/javascriptaudionode.html
38876         to test coverage of the new names.
38877
38878         * Modules/webaudio/AudioBufferSourceNode.idl:
38879         * Modules/webaudio/AudioContext.cpp:
38880         (WebCore::AudioContext::createScriptProcessor):
38881         (WebCore::AudioContext::createGain):
38882         (WebCore::AudioContext::createDelay):
38883         * Modules/webaudio/AudioContext.h:
38884         (AudioContext):
38885         * Modules/webaudio/AudioContext.idl:
38886         * page/FeatureObserver.h:
38887
38888 2012-10-22  Varun Jain  <varunjain@chromium.org>
38889
38890         Context menu generated from touch gestures on textareas has
38891         context of the cursor position instead of the position where the event occurs.
38892         https://bugs.webkit.org/show_bug.cgi?id=99520
38893
38894         Reviewed by Kenneth Rohde Christiansen.
38895
38896         Send a synthetic mouse down event for context menu-summoning-gesture events so
38897         that textareas can correctly set cursors before receiving the context menu event.
38898
38899         Test: fast/events/touch/gesture/right-click-gestures-set-cursor-at-correct-position.html
38900
38901         * page/EventHandler.cpp:
38902         (WebCore::EventHandler::handleGestureEvent):
38903         (WebCore::EventHandler::handleGestureTwoFingerTap):
38904         (WebCore):
38905         (WebCore::EventHandler::sendContextMenuEventForGesture):
38906         * page/EventHandler.h:
38907         (EventHandler):
38908
38909 2012-10-22  Zeno Albisser  <zeno@webkit.org>
38910
38911         TextureMapperSurfaceBackingStore should check if GraphicsSurface is valid.
38912         https://bugs.webkit.org/show_bug.cgi?id=100002
38913
38914         Reviewed by Kenneth Rohde Christiansen.
38915
38916         * platform/graphics/texmap/TextureMapperBackingStore.cpp:
38917         (WebCore::TextureMapperSurfaceBackingStore::setGraphicsSurface):
38918             Check if a surface has been created before accessing the pointer.
38919         (WebCore::TextureMapperSurfaceBackingStore::paintToTextureMapper):
38920             Check if m_graphicsSurface is a valid pointer before dereferencing it.
38921
38922 2012-10-22  Michael Saboff  <msaboff@apple.com>
38923
38924         r131955 is has improper function call in LinkHashChromium.cpp
38925         https://bugs.webkit.org/show_bug.cgi?id=100008
38926
38927         Reviewed by Alexey Proskuryakov.
38928
38929         Followup fix to r131955 for chromium platform.  Added call to 
38930         (const UChar*, unsigned) version of visitedLinkHash from String& version.
38931
38932         * platform/chromium/LinkHashChromium.cpp:
38933         (WebCore::visitedLinkHash):
38934
38935 2012-10-22  Aaron Colwell  <acolwell@chromium.org>
38936
38937         webkitsourceopen event doesn't always fire
38938         https://bugs.webkit.org/show_bug.cgi?id=99868
38939
38940         Reviewed by Adam Barth.
38941
38942         Changed MediaSource to derive from ActiveDOMObject so that event listeners
38943         will still fire even if all references to the object go out of scope.
38944
38945         Test: http/tests/media/media-source/video-media-source-garbage-collection-before-sourceopen.html
38946
38947         * Modules/mediasource/MediaSource.cpp:
38948         (WebCore::MediaSource::create):
38949         (WebCore::MediaSource::MediaSource):
38950         (WebCore::MediaSource::scriptExecutionContext):
38951         (WebCore):
38952         (WebCore::MediaSource::hasPendingActivity):
38953         (WebCore::MediaSource::stop): Clears m_player & m_asyncEventQueue so they don't indicate pending activity anymore.
38954         * Modules/mediasource/MediaSource.h:
38955         (MediaSource):
38956         * Modules/mediasource/MediaSource.idl:
38957         * Modules/mediasource/MediaSourceRegistry.cpp:
38958         (WebCore::MediaSourceRegistry::registerMediaSourceURL): Added setPendingActivity() call so the MediaSource object stays active while in the registry.
38959         (WebCore::MediaSourceRegistry::unregisterMediaSourceURL): Added unsetPendingActivity() call so the MediaSource object can become inactive after being removed from the registry.
38960
38961 2012-10-22  Adam Barth  <abarth@webkit.org>
38962
38963         [V8] Vastly simplify V8GCController's NodeVisitor
38964         https://bugs.webkit.org/show_bug.cgi?id=99884
38965
38966         Reviewed by Kentaro Hara.
38967
38968         NodeVisitor was vastly more complicated than necessary.
38969
38970         This patch improve performance on these new gc benchmarks:
38971
38972         gc-forest: 1.14% better
38973         gc-mini-tree: 5.09% better
38974         gc-tree: 4.60% better
38975
38976         * bindings/v8/V8GCController.cpp:
38977         (WebCore::ObjectVisitor::visitDOMWrapper):
38978         (WebCore::addImplicitReferencesForNodeWithEventListeners):
38979         (WebCore::rootForGC):
38980         (WebCore::NodeVisitor::visitDOMWrapper):
38981         (WebCore::NodeVisitor::applyGrouping):
38982         (NodeVisitor):
38983
38984 2012-10-22  Emil A Eklund  <eae@chromium.org>
38985
38986         Change baselinePosition and maxAscent/maxDescent to int
38987         https://bugs.webkit.org/show_bug.cgi?id=99767
38988
38989         Reviewed by Levi Weintraub.
38990
38991         Currently baselinePostion, maxAscent and maxDescent are
38992         LayoutUnits while ascent, descent and m_lineHeight are ints.
38993         This can lead to subtle alignment and rounding problems.
38994
38995         Change baselinePosition and maxAscent/maxDescent to int to avoid
38996         these issues.
38997
38998         Test: fast/sub-pixel/replaced-element-baseline.html
38999
39000         * editing/FrameSelection.cpp:
39001         (WebCore::repaintRectForCaret):
39002         Inflate Y dimension just like we do for X to ensure that the
39003         repaint rect fully contains the caret.
39004
39005         * rendering/InlineBox.cpp:
39006         (WebCore::InlineBox::baselinePosition):
39007         * rendering/InlineBox.h:
39008         (InlineBox):
39009         * rendering/InlineFlowBox.cpp:
39010         (WebCore::InlineFlowBox::adjustMaxAscentAndDescent):
39011         (WebCore::InlineFlowBox::computeLogicalBoxHeights):
39012         (WebCore::InlineFlowBox::placeBoxesInBlockDirection):
39013         Change maxAscent/maxDescent to int to match ascent/descent.
39014         
39015         * rendering/InlineFlowBox.h:
39016         (InlineFlowBox):
39017         * rendering/InlineTextBox.cpp:
39018         (WebCore::InlineTextBox::baselinePosition):
39019         * rendering/InlineTextBox.h:
39020         (InlineTextBox):
39021         * rendering/RenderBlock.cpp:
39022         (WebCore::RenderBlock::baselinePosition):
39023         (WebCore::RenderBlock::firstLineBoxBaseline):
39024         (WebCore::RenderBlock::lastLineBoxBaseline):
39025         * rendering/RenderBlock.h:
39026         (RenderBlock):
39027         * rendering/RenderBox.cpp:
39028         (WebCore::RenderBox::baselinePosition):
39029         * rendering/RenderBox.h:
39030         (WebCore::RenderBox::firstLineBoxBaseline):
39031         (WebCore::RenderBox::lastLineBoxBaseline):
39032         (RenderBox):
39033         * rendering/RenderBoxModelObject.h:
39034         (RenderBoxModelObject):
39035         * rendering/RenderFlexibleBox.cpp:
39036         (WebCore::RenderFlexibleBox::baselinePosition):
39037         (WebCore::RenderFlexibleBox::firstLineBoxBaseline):
39038         * rendering/RenderFlexibleBox.h:
39039         * rendering/RenderInline.cpp:
39040         (WebCore::RenderInline::baselinePosition):
39041         * rendering/RenderInline.h:
39042         (RenderInline):
39043         * rendering/RenderListBox.cpp:
39044         (WebCore::RenderListBox::baselinePosition):
39045         * rendering/RenderListBox.h:
39046         (RenderListBox):
39047         * rendering/RenderListMarker.cpp:
39048         (WebCore::RenderListMarker::baselinePosition):
39049         * rendering/RenderListMarker.h:
39050         (RenderListMarker):
39051         * rendering/RenderSlider.cpp:
39052         (WebCore::RenderSlider::baselinePosition):
39053         * rendering/RenderSlider.h:
39054         (RenderSlider):
39055         * rendering/RenderTable.cpp:
39056         (WebCore::RenderTable::baselinePosition):
39057         (WebCore::RenderTable::lastLineBoxBaseline):
39058         (WebCore::RenderTable::firstLineBoxBaseline):
39059         * rendering/RenderTable.h:
39060         (RenderTable):
39061         * rendering/RenderTableSection.cpp:
39062         (WebCore::RenderTableSection::firstLineBoxBaseline):
39063         * rendering/RenderTableSection.h:
39064         (RenderTableSection):
39065         * rendering/RenderTextControlMultiLine.cpp:
39066         (WebCore::RenderTextControlMultiLine::baselinePosition):
39067         * rendering/RenderTextControlMultiLine.h:
39068         (RenderTextControlMultiLine):
39069         * rendering/RenderTheme.cpp:
39070         (WebCore::RenderTheme::baselinePosition):
39071         * rendering/RenderTheme.h:
39072         (RenderTheme):
39073         * rendering/RenderThemeSafari.cpp:
39074         (WebCore::RenderThemeSafari::baselinePosition):
39075         * rendering/RenderThemeSafari.h:
39076         (RenderThemeSafari):
39077         * rendering/RootInlineBox.cpp:
39078         (WebCore::RootInlineBox::baselinePosition):
39079         (WebCore::RootInlineBox::alignBoxesInBlockDirection):
39080         * rendering/RootInlineBox.h:
39081         (RootInlineBox):
39082         * rendering/mathml/RenderMathMLBlock.cpp:
39083         (WebCore::RenderMathMLBlock::baselinePosition):
39084         (WebCore::RenderMathMLTable::firstLineBoxBaseline):
39085         * rendering/mathml/RenderMathMLBlock.h:
39086         (RenderMathMLBlock):
39087         (RenderMathMLTable):
39088         * rendering/mathml/RenderMathMLFraction.cpp:
39089         (WebCore::RenderMathMLFraction::firstLineBoxBaseline):
39090         * rendering/mathml/RenderMathMLFraction.h:
39091         (RenderMathMLFraction):
39092         * rendering/mathml/RenderMathMLOperator.cpp:
39093         (WebCore::RenderMathMLOperator::firstLineBoxBaseline):
39094         * rendering/mathml/RenderMathMLOperator.h:
39095         * rendering/mathml/RenderMathMLUnderOver.cpp:
39096         (WebCore::RenderMathMLUnderOver::firstLineBoxBaseline):
39097         * rendering/mathml/RenderMathMLUnderOver.h:
39098         (RenderMathMLUnderOver):
39099
39100 2012-10-22  Emil A Eklund  <eae@chromium.org>
39101
39102         Modify LayoutState ASSERTS to support SATURATED_LAYOUT_ARITHMETIC
39103         https://bugs.webkit.org/show_bug.cgi?id=98692
39104
39105         Reviewed by Dan Bernstein.
39106
39107         We currently overflow/wrap when computing the delta in
39108         RenderBlock::setLogicalTopForChild in cases where we have an
39109         element with a width or height exceeding maxLayoutUnit. When
39110         the delta is later added back in RenderBlock::layoutBlockChild
39111         the number wraps again getting us back to the correct value.
39112
39113         With SATURATED_LAYOUT_ARITHMETIC enabled the values no longer
39114         wraps, which seems like the correct thing to do however this
39115         causes the compare to fail for obvious reasons. By accounting
39116         for this we can keep the asserts (which have proven very
39117         helpful) even when SATURATED_LAYOUT_ARITHMETIC is turned on.
39118
39119         No new tests, covered by existing tests.
39120
39121         * rendering/LayoutState.cpp:
39122         (WebCore::LayoutState::LayoutState):
39123         * rendering/LayoutState.h:
39124         (WebCore::LayoutState::LayoutState):
39125         (LayoutState):
39126         * rendering/RenderBlock.cpp:
39127         (WebCore::RenderBlock::layoutBlockChild):
39128         * rendering/RenderView.cpp:
39129         (WebCore::RenderView::layout):
39130         * rendering/RenderView.h:
39131         (WebCore::RenderView::addLayoutDelta):
39132         (RenderView):
39133         (WebCore::RenderView::layoutDeltaMatches):
39134
39135 2012-10-22  Tony Chang  <tony@chromium.org>
39136
39137         Fix some baseline flexbox alignment
39138         https://bugs.webkit.org/show_bug.cgi?id=99879
39139
39140         Reviewed by Ojan Vafai.
39141
39142         Fix a bug where we weren't handling margin properly on inline-flexbox.
39143         Fix a bug where we weren't getting the edge of the content box properly when synthesizing
39144         a baseline.
39145
39146         Test: css3/flexbox/flexbox-baseline-margins.html
39147
39148         * rendering/RenderBlock.cpp:
39149         (WebCore::RenderBlock::baselinePosition):
39150         (WebCore::RenderBlock::inlineBlockBaseline): Add a new method that is used when calculating an inline-block's
39151         baseline. Previously we would use lastLineBoxBaseline.
39152         (WebCore::RenderBlock::lastLineBoxBaseline): Pass in direction and when searching children, use inlineBlockBaseline.
39153         * rendering/RenderBlock.h:
39154         (RenderBlock): Make lastLineBoxBaseline non-virtual.
39155         * rendering/RenderBox.h:
39156         (WebCore::RenderBox::inlineBlockBaseline): Replace lastLineBoxBaseline with inlineBlockBaseline.
39157         * rendering/RenderFlexibleBox.cpp:
39158         (WebCore::synthesizedBaselineFromContentBox): Helper method for getting the baseline from the content box.
39159         (WebCore::RenderFlexibleBox::baselinePosition): Always include the margin. This fixes the inline-flexbox case.
39160         (WebCore::RenderFlexibleBox::firstLineBoxBaseline): Fix a case where we didn't synthesize a baseline.  Returning -1 means there is no baseline, but we can
39161         synthesize a baseline if we have a flexitem without text.
39162         (WebCore::RenderFlexibleBox::inlineBlockBaseline):
39163         * rendering/RenderFlexibleBox.h:
39164         * rendering/RenderTable.cpp: Replace lastLineBoxBaseline with inlineBlockBaseline.
39165         (WebCore::RenderTable::inlineBlockBaseline): Try to make comment more direct.
39166         * rendering/RenderTable.h:
39167         (RenderTable): Replace lastLineBoxBaseline with inlineBlockBaseline.
39168
39169 2012-10-22  Levi Weintraub  <leviw@chromium.org>
39170
39171         Unreviewed Chromium build fix following r132074.
39172
39173         * WebCore.gypi:
39174
39175 2012-10-22  Mario Sanchez Prada  <msanchez@igalia.com>
39176
39177         [GTK] Don't use deprecated AccessibilityObject methods after r99502
39178         https://bugs.webkit.org/show_bug.cgi?id=99985
39179
39180         Reviewed by Chris Fleizach.
39181
39182         Update callers for AccessibilityObject's title() and
39183         accessibilityDescription() so they now use AccessibilityText.
39184
39185         * accessibility/gtk/WebKitAccessibleUtil.cpp:
39186         (titleTagShouldBeUsedInDescriptionField): Internal helper function.
39187         (accessibilityTitle): New helper function, returns an String with
39188         the title for a AccessibilityObject, using AccessibleText.
39189         (accessibilityDescription): New helper function, returns an String with
39190         the description for a AccessibilityObject, using AccessibleText.
39191         * accessibility/gtk/WebKitAccessibleUtil.h: Added public
39192         declarations for accessibilityTitle and accessibilityDescription.
39193
39194         * accessibility/gtk/WebKitAccessibleWrapperAtk.cpp:
39195         (webkitAccessibleGetName): Use new helpers for retrieving the title.
39196         (webkitAccessibleGetDescription): Use new helpers for retrieving
39197         the title and description.
39198
39199         * accessibility/gtk/WebKitAccessibleInterfaceImage.cpp:
39200         (webkitAccessibleImageGetImageDescription): Use new helpers for
39201         retrieving the title.
39202
39203 2012-10-16  Andrey Kosyakov  <caseq@chromium.org>
39204
39205         Web Inspector: add timeline instrumentation for scrolling of a layer
39206         https://bugs.webkit.org/show_bug.cgi?id=99461
39207
39208         Reviewed by Pavel Feldman.
39209
39210         - added timeline instrumentation for scrolling of a layer;
39211         - added TRACE_EVENT for ScrollableArea::scrollPositionChanged()
39212
39213         * inspector/InspectorInstrumentation.cpp:
39214         (WebCore):
39215         (WebCore::InspectorInstrumentation::willScrollLayerImpl):
39216         (WebCore::InspectorInstrumentation::didScrollLayerImpl):
39217         * inspector/InspectorInstrumentation.h:
39218         (InspectorInstrumentation):
39219         (WebCore::InspectorInstrumentation::willScrollLayer):
39220         (WebCore):
39221         (WebCore::InspectorInstrumentation::didScrollLayer):
39222         * inspector/InspectorTimelineAgent.cpp:
39223         (TimelineRecordType):
39224         (WebCore::InspectorTimelineAgent::willScroll):
39225         (WebCore):
39226         (WebCore::InspectorTimelineAgent::didScroll):
39227         * inspector/InspectorTimelineAgent.h:
39228         (InspectorTimelineAgent):
39229         * inspector/front-end/TimelineModel.js:
39230         * inspector/front-end/TimelinePresentationModel.js:
39231         (WebInspector.TimelinePresentationModel._initRecordStyles):
39232         * rendering/RenderLayer.cpp:
39233         (WebCore::RenderLayer::scrollTo):
39234         * platform/ScrollableArea.cpp:
39235         (WebCore::ScrollableArea::scrollPositionChanged):
39236
39237 2012-10-22  Jan Keromnes  <janx@linux.com>
39238
39239         Moved cmdevtools.js to folder cm/
39240
39241         Web Inspector: Move file `cmdevtools.css` to `cm/`
39242         https://bugs.webkit.org/show_bug.cgi?id=99956
39243
39244         Reviewed by Pavel Feldman.
39245
39246         The file cmdevtools.js belongs to the CodeMirror editor experiment in cm/.
39247
39248         * WebCore.gypi:
39249         * WebCore.vcproj/WebCore.vcproj:
39250         * inspector/front-end/WebKit.qrc:
39251         * inspector/front-end/cm/cmdevtools.css: Renamed from Source/WebCore/inspector/front-end/cmdevtools.css.
39252         (.CodeMirror):
39253         (.CodeMirror-scroll):
39254         (.cm-highlight):
39255         (@-webkit-keyframes fadeout):
39256         (to):
39257         (.cm-breakpoint):
39258         (.cm-breakpoint-disabled):
39259         (.cm-breakpoint-conditional):
39260         (.cm-execution-line):
39261         (.cm-s-web-inspector-js span.cm-keyword):
39262         (.cm-s-web-inspector-js span.cm-number):
39263         (.cm-s-web-inspector-js span.cm-comment):
39264         (.cm-s-web-inspector-js span.cm-string):
39265         (.cm-s-web-inspector-js span.cm-string-2):
39266         (.cm-s-web-inspector-css span.cm-keyword):
39267         (.cm-s-web-inspector-css span.cm-number):
39268         (.cm-s-web-inspector-css span.cm-comment):
39269         (.cm-s-web-inspector-css span.cm-string):
39270         (.cm-s-web-inspector-css span.cm-string-2):
39271         (.cm-s-web-inspector-css span.cm-link):
39272         (.cm-s-web-inspector-css span.cm-variable):
39273         (.cm-s-web-inspector-html span.cm-meta):
39274         (.cm-s-web-inspector-html span.cm-comment):
39275         (.cm-s-web-inspector-html span.cm-string):
39276         (.cm-s-web-inspector-html span.cm-tag):
39277         (.cm-s-web-inspector-html span.cm-attribute):
39278         (.cm-s-web-inspector-html span.cm-link):
39279         (.webkit-html-message-bubble):
39280         (.webkit-html-warning-message):
39281         (.webkit-html-error-message):
39282         (.webkit-html-message-line):
39283         (.webkit-html-message-line-hover):
39284
39285 2012-10-22  Vsevolod Vlasov  <vsevik@chromium.org>
39286
39287         Web Inspector: Prepare mappings to moving uiSourceCodes creation out of them to workspace.
39288         https://bugs.webkit.org/show_bug.cgi?id=99997
39289
39290         Reviewed by Pavel Feldman.
39291
39292         Source mappings could now store a link to temporary uiSourceCodes only.
39293         Otherwise it should retrieve uiSourceCodes from workspace by URL.
39294         Original uiSourceCodes are now temporary in CompilerScriptMapping.
39295
39296         * inspector/front-end/CompilerScriptMapping.js:
39297         (WebInspector.CompilerScriptMapping):
39298         (WebInspector.CompilerScriptMapping.prototype.rawLocationToUILocation):
39299         (WebInspector.CompilerScriptMapping.prototype.loadSourceMapForScript):
39300         (WebInspector.CompilerScriptMapping.prototype._reset):
39301         * inspector/front-end/NetworkUISourceCodeProvider.js:
39302         (WebInspector.NetworkUISourceCodeProvider):
39303         (WebInspector.NetworkUISourceCodeProvider.prototype._parsedScriptSource):
39304         (WebInspector.NetworkUISourceCodeProvider.prototype._resourceAdded):
39305         (WebInspector.NetworkUISourceCodeProvider.prototype._addUISourceCode):
39306         (WebInspector.NetworkUISourceCodeProvider.prototype._projectWillReset):
39307         * inspector/front-end/SASSSourceMapping.js:
39308         (WebInspector.SASSSourceMapping):
39309         (_bindUISourceCode):
39310         (_reset):
39311
39312 2012-10-22  Nicolas Dufresne <nicolas.dufresne@collabora.com>
39313
39314         Gstreamer 1.0 not working
39315         https://bugs.webkit.org/show_bug.cgi?id=99852
39316
39317         Reviewed by Philippe Normand.
39318
39319         There was a series of trivial issue, g_object_is_floating() was called
39320         on type GstCaps (which is not a GObject), webkitGstGetPadCaps() was
39321         returning non-fixed caps and GST_MESSAGE_DURATION has been renamed
39322         to GST_MESSAGE_DURATION_CHANGED.
39323
39324         Most failing test passes now.
39325
39326         * platform/graphics/gstreamer/GRefPtrGStreamer.cpp:
39327         (WTF::adoptGRef):
39328         * platform/graphics/gstreamer/GStreamerVersioning.cpp:
39329         (webkitGstGetPadCaps):
39330         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
39331         (WebCore::MediaPlayerPrivateGStreamer::handleMessage):
39332
39333 2012-10-22  Vsevolod Vlasov  <vsevik@chromium.org>
39334
39335         Web Inspector: Treat dynamic anonymous scripts as other anonymous and fix anonymous script editing and breakpoints.
39336         https://bugs.webkit.org/show_bug.cgi?id=99989
39337
39338         Reviewed by Pavel Feldman.
39339
39340         Dynamic anonymous scripts are now mapped to anonymous temporary uiSourceCodes.
39341         ResourceScriptMapping now supports two types of temporary uiSourceCodes:
39342          - original uiSourceCodes represent scripts while main uiSourceCodes are diverged;
39343          - temporary uiSourceCodes represent scripts for which resources are not yet loaded.
39344
39345         * inspector/front-end/BreakpointManager.js:
39346         (WebInspector.BreakpointManager.breakpointStorageId):
39347         (WebInspector.BreakpointManager.Storage.prototype._updateBreakpoint):
39348         * inspector/front-end/NetworkUISourceCodeProvider.js:
39349         (WebInspector.NetworkUISourceCodeProvider.prototype._parsedScriptSource):
39350         * inspector/front-end/ResourceScriptMapping.js:
39351         (WebInspector.ResourceScriptMapping):
39352         (WebInspector.ResourceScriptMapping.prototype.rawLocationToUILocation):
39353         (WebInspector.ResourceScriptMapping.prototype._hasMergedToVM):
39354         (WebInspector.ResourceScriptMapping.prototype.addScript):
39355         (WebInspector.ResourceScriptMapping.prototype._deleteOriginalUISourceCodeForScripts):
39356         (WebInspector.ResourceScriptMapping.prototype._deleteTemporaryUISourceCodeForScripts):
39357         (WebInspector.ResourceScriptMapping.prototype._bindUISourceCodeToScripts):
39358         (WebInspector.ResourceScriptMapping.prototype._createUISourceCode):
39359         (WebInspector.ResourceScriptMapping.prototype._getOrCreateTemporaryUISourceCode):
39360         (WebInspector.ResourceScriptMapping.prototype._getOrCreateOriginalUISourceCode):
39361         (WebInspector.ResourceScriptMapping.prototype._uiSourceCodeAddedToWorkspace):
39362         (WebInspector.ResourceScriptMapping.prototype._scriptsForUISourceCode.get if):
39363         (WebInspector.ResourceScriptMapping.prototype._reset):
39364
39365 2012-10-22  Bruno de Oliveira Abinader  <bruno.abinader@basyskom.com>
39366
39367         [css3-text] Add rendering support for -webkit-text-decoration-style
39368         https://bugs.webkit.org/show_bug.cgi?id=94094
39369
39370         Reviewed by Julien Chaffraix.
39371
39372         This patch implements the "text-decoration-style" property rendering as
39373         specified in CSS3 working draft, with "-webkit-" prefix. The specification can
39374         be found here: http://dev.w3.org/csswg/css3-text/#text-decoration-style
39375
39376         Additionally, Mozilla implementation details can be found here:
39377         https://developer.mozilla.org/en/CSS/text-decoration-style
39378
39379         Tests: fast/css3-text/css3-text-decoration/repaint/repaint-text-decoration-style.html
39380                fast/css3-text/css3-text-decoration/text-decoration-style.html
39381
39382         * platform/graphics/GraphicsContext.h:
39383         * platform/graphics/cairo/GraphicsContextCairo.cpp:
39384         (WebCore::GraphicsContext::setPlatformStrokeStyle):
39385         * platform/graphics/cg/GraphicsContextCG.cpp:
39386         (WebCore::GraphicsContext::drawLine):
39387         * platform/graphics/qt/GraphicsContextQt.cpp:
39388         (WebCore::toQPenStyle):
39389         (WebCore::GraphicsContext::drawLine):
39390         * platform/graphics/skia/PlatformContextSkia.cpp:
39391         (WebCore::PlatformContextSkia::setupPaintForStroking):
39392         * platform/graphics/wince/GraphicsContextWinCE.cpp:
39393         (WebCore::createPen):
39394         * platform/graphics/wx/GraphicsContextWx.cpp:
39395         (WebCore::strokeStyleToWxPenStyle):
39396         Added 'DoubleStroke' and 'WavyStroke' to StrokeStyle enum and updated
39397         platform-specific stroke handling. Some styles requires
39398         platform-specific implementation (handled in bug 92868).
39399         * rendering/InlineTextBox.cpp:
39400         (WebCore::InlineTextBox::paint):
39401         (WebCore::textDecorationStyleToStrokeStyle): Added static function that
39402         translates text decoration to stroke styles.
39403         (WebCore::InlineTextBox::paintDecoration): Text decoration style does
39404         not specify a property for line thickness (like border-width does for
39405         border style), so we statically set it to 1 for now. The 'double' style
39406         implementation simply adds a parallel line (depending if it is
39407         underline, overline or line-through) and the space between lines follows
39408         the approach used by border's 'double' style.
39409         * rendering/InlineTextBox.h:
39410         (InlineTextBox):
39411         * rendering/style/RenderStyle.h:
39412         * rendering/style/RenderStyleConstants.h:
39413         Added text decoration style rendering support to
39414         InlineTextBox::paintDecoration().
39415
39416 2012-10-22  Allan Sandfeld Jensen  <allan.jensen@digia.com>
39417
39418         [Qt] Use the DNS resolve queue
39419         https://bugs.webkit.org/show_bug.cgi?id=99994
39420
39421         Reviewed by Simon Hausmann.
39422
39423         Use the DNS resolve queue, to ensure we can prefetch more than just the first 10 hostname encountered
39424         during parsing. It also ensure each hostname is only appears once in the queue.
39425
39426         * Target.pri:
39427         * platform/network/qt/DNSQt.cpp: Added.
39428         (DnsPrefetchHelper):
39429         (WebCore::DnsPrefetchHelper::DnsPrefetchHelper):
39430         (WebCore::DnsPrefetchHelper::lookup):
39431         (WebCore::DnsPrefetchHelper::lookedUp):
39432         (WebCore::prefetchDNS):
39433         (WebCore::DNSResolveQueue::platformProxyIsEnabledInSystemPreferences):
39434         (WebCore::DNSResolveQueue::platformResolve):
39435         * platform/network/qt/DnsPrefetchHelper.cpp: Removed.
39436         * platform/network/qt/DnsPrefetchHelper.h: Removed.
39437         (DnsPrefetchHelper):
39438
39439 2012-10-22  Erik Arvidsson  <arv@chromium.org>
39440
39441         HTMLBaseElement href attribute binding returns wrong URL
39442         https://bugs.webkit.org/show_bug.cgi?id=98184
39443
39444         Reviewed by Ojan Vafai.
39445
39446         Resolve the href attribute binding relative to the document URL instead of resolving it to the
39447         base element itself. If there is no href attribute this should return the fallback base URL.
39448
39449         http://www.whatwg.org/specs/web-apps/current-work/multipage/semantics.html#the-base-element
39450
39451         Tests: fast/dom/HTMLAnchorElement/set-href-attribute-rebase.html
39452                fast/dom/HTMLBaseElement/href-attribute-resolves-with-respect-to-document.html
39453
39454         * html/HTMLBaseElement.cpp:
39455         (WebCore::HTMLBaseElement::href): Don't use completeURL. Resolve href based on document's URL instead
39456         of the generic [Reflect, URL] binding.
39457         (WebCore::HTMLBaseElement::setHref): Just sets the attribute.
39458         * html/HTMLBaseElement.h:
39459         * html/HTMLBaseElement.idl: We can no longer use [Reflect, URL]
39460
39461 2012-10-22  Vsevolod Vlasov  <vsevik@chromium.org>
39462
39463         Web Inspector: Revisions should not be restored and persisted for anonymous uiSourceCodes.
39464         https://bugs.webkit.org/show_bug.cgi?id=99991
39465
39466         Reviewed by Alexander Pavlov.
39467
39468         * inspector/front-end/UISourceCode.js:
39469         (WebInspector.UISourceCode):
39470
39471 2012-10-22  Florin Malita  <fmalita@chromium.org>
39472
39473         Incorrect embedded SVG image sizing on first load
39474         https://bugs.webkit.org/show_bug.cgi?id=99489
39475
39476         Reviewed by Nikolas Zimmermann.
39477
39478         RenderSVGImage::updateImageViewport() must be called after the image loader is finished,
39479         to ensure that a SVGImageCache::SizeAndScalesMap entry is created even if layout has
39480         already been performed.
39481
39482         Test: svg/custom/svg-image-initial-size.html
39483
39484         * rendering/svg/RenderSVGImage.cpp:
39485         (WebCore::RenderSVGImage::imageChanged):
39486
39487 2012-10-22  Keishi Hattori  <keishi@webkit.org>
39488
39489         Remove monthFormatInLDML
39490         https://bugs.webkit.org/show_bug.cgi?id=99971
39491
39492         Reviewed by Kent Tamura.
39493
39494         Removing monthFormatInLDML from localized strings because Localizer class now provides the same functionality.
39495
39496         No new tests. Just removing unused code.
39497
39498         * platform/LocalizedStrings.h:
39499         (WebCore):
39500
39501 2012-10-22  Zan Dobersek  <zandobersek@gmail.com>
39502
39503         [GTK] Enable Microdata DOM API
39504         https://bugs.webkit.org/show_bug.cgi?id=99033
39505
39506         Reviewed by Martin Robinson.
39507
39508         Enable the Microdata DOM API, but still disable it when the unstable
39509         features should be disabled (for instance in release builds).
39510
39511         No new tests - related tests are being unskipped and are expected to pass.
39512
39513         * GNUmakefile.am:
39514         * GNUmakefile.features.am:
39515         * bindings/gobject/GNUmakefile.am: Add the required files so the Microdata
39516         API GObject bindings are generated and built.
39517
39518 2012-10-22  Zan Dobersek  <zandobersek@gmail.com>
39519
39520         [GTK] Enable CSP 1.1
39521         https://bugs.webkit.org/show_bug.cgi?id=99064
39522
39523         Reviewed by Martin Robinson.
39524
39525         Enable CSP 1.1 in development builds but keep it disabled when the
39526         unstable features should not be enabled (like in stable releases).
39527
39528         No new tests - they already exist and will be unskipped.
39529
39530         * GNUmakefile.am:
39531         * GNUmakefile.features.am:
39532
39533 2012-10-22  Jocelyn Turcotte  <jocelyn.turcotte@digia.com>
39534
39535         [Qt] Fix "ASSERTION FAILED: !document->inPageCache()" when loading a page
39536         https://bugs.webkit.org/show_bug.cgi?id=98514
39537
39538         Reviewed by Kenneth Rohde Christiansen.
39539
39540         The problem is that we call setFixedVisibleContentRect, which triggers
39541         a layout, after the document has been put in the page cache and before
39542         the load has been actually committed.
39543
39544         This applies the same trick as with setFixedLayoutSize by passing the rect
39545         in Frame::createView and calling setFixedVisibleContentRect before the
39546         new FrameView gets attached to the Frame/Document to prevent the layout.
39547
39548         * WebCore.exp.in:
39549         * page/Frame.cpp:
39550         (WebCore::Frame::createView): Give a default value to the fixedLayoutSize and
39551         useFixedLayout arguments as well since they are used exceptionally.
39552         * page/Frame.h:
39553         (Frame):
39554
39555 2012-10-22  Allan Sandfeld Jensen  <allan.jensen@digia.com>
39556
39557         [Qt] Handle GET of blob URLs.
39558         https://bugs.webkit.org/show_bug.cgi?id=99053
39559
39560         Reviewed by Simon Hausmann.
39561
39562         Let BlobResourceHandle handle Blob request internally.
39563
39564         * platform/network/qt/ResourceHandleQt.cpp:
39565         (WebCore::ResourceHandle::loadResourceSynchronously):
39566
39567 2012-10-22  Kenichi Ishibashi  <bashi@chromium.org>
39568
39569         HarfBuzzShaper::shape() should return false when it adds no glyph to GlyphBuffer
39570         https://bugs.webkit.org/show_bug.cgi?id=99966
39571
39572         Reviewed by Kent Tamura.
39573
39574         If no glyph is added to GlyphBuffer, HarfBuzzShaper::shape() returns false.
39575
39576         No new tests. Confirmed the fix by using Address Sanitizer.
39577
39578         * platform/graphics/harfbuzz/ng/HarfBuzzShaper.cpp:
39579         (WebCore::HarfBuzzShaper::shape):
39580         (WebCore::HarfBuzzShaper::fillGlyphBuffer): Returns false when glyphBuffer.size() == 0
39581         * platform/graphics/harfbuzz/ng/HarfBuzzShaper.h:
39582         (HarfBuzzShaper):
39583
39584 2012-10-22  Shinya Kawanaka  <shinyak@chromium.org>
39585
39586         [Shadow] ASSERT triggered when we try reprojecting fallback elements.
39587         https://bugs.webkit.org/show_bug.cgi?id=99815
39588
39589         Reviewed by Hajime Morita.
39590
39591         When fallback elements of InsertionPoint is reprojected, they were attached twice.
39592         We have to skip attaching them if they are attached. We also add a few ASSERT not to
39593         allow attaching twice if not necessary.
39594
39595         We have confirmed that this patch does not regress the performance. The summary of the
39596         performance test is the following:
39597
39598         Dromaeo/dom-modify.html [runs/s]:
39599                                median stdev    min    max
39600            without this patch:   3928   184   3655   4361
39601            with this patch   :   3925   178   3652   4350
39602
39603         Parser/html5-full-render.html [s]:
39604                                median stdev    min    max
39605            without this patch:   3821    17   3811   3850
39606            with this patch   :   3838   4.4   3833   3844
39607
39608         Test: fast/dom/shadow/content-reprojection-fallback-crash.html
39609
39610         * dom/ContainerNode.cpp:
39611         (WebCore):
39612         (WebCore::childAttachedAllowedWhenAttachingChildren): If true, children of this node might
39613         be attached in advance because of ShadowDOM attaching process.
39614         * dom/ContainerNode.h:
39615         (ContainerNode):
39616         (WebCore):
39617         (WebCore::ContainerNode::attachChildren):
39618         * dom/Element.cpp:
39619         (WebCore::Element::attach):
39620         * dom/ShadowRoot.cpp:
39621         (WebCore::ShadowRoot::attach):
39622
39623 2012-10-22  Pavel Feldman  <pfeldman@chromium.org>
39624
39625         Web Inspector: merge "docked" state into the "dock side" enum.
39626         https://bugs.webkit.org/show_bug.cgi?id=99717
39627
39628         Reviewed by Vsevolod Vlasov.
39629
39630         Otherwise, it is hard to manage these inter-dependent flags.
39631
39632         * WebCore.exp.in:
39633         * inspector/InspectorFrontendClient.h:
39634         (InspectorFrontendClient):
39635         * inspector/InspectorFrontendClientLocal.cpp:
39636         (WebCore::InspectorFrontendClientLocal::requestSetDockSide):
39637         (WebCore::InspectorFrontendClientLocal::setAttachedWindow):
39638         * inspector/InspectorFrontendClientLocal.h:
39639         (InspectorFrontendClientLocal):
39640         * inspector/InspectorFrontendHost.cpp:
39641         (WebCore::InspectorFrontendHost::requestSetDockSide):
39642         * inspector/InspectorFrontendHost.h:
39643         (InspectorFrontendHost):
39644         * inspector/InspectorFrontendHost.idl:
39645         * inspector/front-end/DockController.js:
39646         (WebInspector.DockController):
39647         (WebInspector.DockController.prototype._updateUI.get sides):
39648         (WebInspector.DockController.prototype._updateUI):
39649         (WebInspector.DockController.prototype._toggleDockState):
39650         * inspector/front-end/InspectorFrontendAPI.js:
39651         (InspectorFrontendAPI.setAttachedWindow):
39652         (InspectorFrontendAPI.setDockSide):
39653         * inspector/front-end/InspectorFrontendHostStub.js:
39654         (.WebInspector.InspectorFrontendHostStub.prototype.requestSetDockSide):
39655         * inspector/front-end/externs.js:
39656
39657 2012-10-22  MORITA Hajime  <morrita@google.com>
39658
39659         Unreviewed follow up to update test result after r132033.
39660
39661         * bindings/scripts/test/V8/V8TestObj.cpp:
39662         (WebCore::V8TestObj::installPerContextProperties):
39663
39664 2012-10-21  MORITA Hajime  <morrita@google.com>
39665
39666         [V8] V8EnablePerContext shouldn't require document() accessor to the native object.
39667         https://bugs.webkit.org/show_bug.cgi?id=99954
39668
39669         Reviewed by Kentaro Hara.
39670
39671         It now refers ScriptExecutionContext of the creation context instead of document() of
39672         wrapped object.
39673
39674         No new tests. No behavior change at this time.
39675
39676         * bindings/scripts/CodeGeneratorV8.pm:
39677         (GenerateImplementation):
39678
39679 2012-10-21  Kent Tamura  <tkent@chromium.org>
39680
39681         Page popup: Fix crash by events after closing
39682         https://bugs.webkit.org/show_bug.cgi?id=99951
39683
39684         Reviewed by Hajime Morita.
39685
39686         WebCore should provide a way to uninstall a DOMWindowPagePopup supplement.
39687
39688         No new tests. The bug is timing-dependent.
39689
39690         * page/DOMWindowPagePopup.cpp:
39691         (WebCore::DOMWindowPagePopup::uninstall):
39692         Added. Calls Supplementable::removeSupplement.
39693         * page/DOMWindowPagePopup.h:
39694         (DOMWindowPagePopup): Declare uninstall.
39695         * platform/Supplementable.h:
39696         (WebCore::Supplementable::removeSupplement): Added.
39697
39698 2012-10-21  Keishi Hattori  <keishi@webkit.org>
39699
39700         Refactor picker tests to fix flakiness and share code
39701         https://bugs.webkit.org/show_bug.cgi?id=99671
39702
39703         Reviewed by Kent Tamura.
39704
39705         Disable transitions until the picker is fully ready. This should fix flakiness.
39706
39707         No new tests.
39708
39709         * Resources/pagepopups/calendarPicker.css:
39710         (.preparing .unavailable): Disable transitions.
39711         (.preparing .available): Disable transitions.
39712         * Resources/pagepopups/calendarPicker.js:
39713         (CalendarPicker): Set "preparing" class.
39714         (CalendarPicker.prototype._handleWindowResize): Remove the "preparing" class when the window finishes resizing.
39715
39716 2012-10-21  Shinya Kawanaka  <shinyak@chromium.org>
39717
39718         Web Inspector: Shadow DOM: Node removal doesn't reflect.
39719         https://bugs.webkit.org/show_bug.cgi?id=99567
39720
39721         Reviewed by Pavel Feldman.
39722
39723         We have to call InspectorInstrumentation::willRemoveDOMNode() even if a node is in a shadow tree.
39724         Otherwise, node won't be removed from the inspector.
39725
39726         Test: inspector/elements/update-shadowdom.html
39727
39728         * dom/ContainerNode.cpp:
39729         (WebCore::dispatchChildRemovalEvents):
39730
39731 2012-10-21  Andreas Kling  <kling@webkit.org>
39732
39733         Remove Page::javaScriptURLsAreAllowed setting.
39734         <http://webkit.org/b/99944>
39735
39736         Reviewed by Anders Carlsson.
39737
39738         This setting was exposed through internal WebView API in Apple's WebKit1.
39739         There are no longer any clients of that API.
39740
39741         This is a step towards preventing elements from modifying their own attributes
39742         below attributeChanged().
39743
39744         * WebCore.exp.in:
39745         * WebCore.order:
39746         * bindings/ScriptControllerBase.cpp:
39747         (WebCore::ScriptController::executeIfJavaScriptURL):
39748         * html/HTMLAnchorElement.cpp:
39749         (WebCore::HTMLAnchorElement::parseAttribute):
39750         * page/Page.cpp:
39751         (WebCore::Page::Page):
39752         * page/Page.h:
39753         (Page):
39754
39755 2012-10-21  Hyungchan Kim  <hyungchan2.kim@lge.com>
39756
39757         Add a separate flag for rgb swizzling whether it can be modified or not
39758         https://bugs.webkit.org/show_bug.cgi?id=98728
39759
39760         BitmapTexture swizzles the source image if the OpenGL driver
39761         doesn't support the BGRA extension.
39762         In case of directly composited images, the source image should not
39763         be modified.
39764
39765         http://www.satine.org/research/webkit/snowleopard/snowstack.html
39766
39767         Reviewed by Noam Rosenthal.
39768
39769         No new tests as this is only testable on specific hardware and
39770         currently not avaiable in the bots.
39771
39772         * platform/graphics/texmap/TextureMapper.h:
39773         (BitmapTexture):
39774         * platform/graphics/texmap/TextureMapperBackingStore.cpp:
39775         (WebCore::TextureMapperTile::updateContents):
39776         (WebCore::TextureMapperTiledBackingStore::updateContentsFromImageIfNeeded):
39777         (WebCore::TextureMapperTiledBackingStore::updateContents):
39778         * platform/graphics/texmap/TextureMapperBackingStore.h:
39779         (TextureMapperTile):
39780         (TextureMapperTiledBackingStore):
39781         (WebCore::TextureMapperTiledBackingStore::updateContents):
39782         * platform/graphics/texmap/TextureMapperGL.cpp:
39783         (WebCore::TextureMapperGL::drawRepaintCounter):
39784         (WebCore::BitmapTextureGL::updateContents):
39785         * platform/graphics/texmap/TextureMapperGL.h:
39786         (BitmapTextureGL):
39787         * platform/graphics/texmap/TextureMapperImageBuffer.cpp:
39788         (WebCore::BitmapTextureImageBuffer::updateContents):
39789         * platform/graphics/texmap/TextureMapperImageBuffer.h:
39790         (BitmapTextureImageBuffer):
39791         * platform/graphics/texmap/TextureMapperLayer.cpp:
39792         (WebCore::TextureMapperLayer::updateBackingStore):
39793
39794 2012-10-21  Antti Koivisto  <antti@apple.com>
39795
39796         Factor stylesheet invalidation analysis code into a class
39797         https://bugs.webkit.org/show_bug.cgi?id=99933
39798
39799         Reviewed by Sam Weinig.
39800
39801         Currently the stylesheet analysis code is all over the place. It should be factored into a class to make
39802         further progress easier.
39803
39804         The patch adds StyleInvalidationAnalysis class and moves a bunch of code from SelectorChecker, StyleResolver
39805         and DocumentStyleSheetCollection there. No functional changes.
39806
39807         * CMakeLists.txt:
39808         * GNUmakefile.list.am:
39809         * Target.pri:
39810         * WebCore.gypi:
39811         * WebCore.vcproj/WebCore.vcproj:
39812         * WebCore.xcodeproj/project.pbxproj:
39813         * css/SelectorChecker.cpp:
39814         (WebCore):
39815         * css/SelectorChecker.h:
39816         (WebCore):
39817         * css/StyleInvalidationAnalysis.cpp: Added.
39818         (WebCore):
39819         (WebCore::StyleInvalidationAnalysis::StyleInvalidationAnalysis):
39820         (WebCore::StyleInvalidationAnalysis::create):
39821         (WebCore::determineSelectorScopes):
39822         (WebCore::StyleInvalidationAnalysis::analyzeStyleSheet):
39823         (WebCore::elementMatchesSelectorScopes):
39824         (WebCore::StyleInvalidationAnalysis::invalidateStyle):
39825         * css/StyleInvalidationAnalysis.h: Added.
39826         (WebCore):
39827         (StyleInvalidationAnalysis):
39828         (WebCore::StyleInvalidationAnalysis::dirtiesAllStyle):
39829         * css/StyleResolver.cpp:
39830         (WebCore::StyleResolver::checkRegionSelector):
39831         * css/StyleResolver.h:
39832         (StyleResolver):
39833         * dom/DocumentStyleSheetCollection.cpp:
39834         (WebCore):
39835         (WebCore::DocumentStyleSheetCollection::analyzeStyleSheetChange):
39836         * dom/DocumentStyleSheetCollection.h:
39837         (DocumentStyleSheetCollection):
39838
39839 2012-10-08  Robert Hogan  <robert@webkit.org>
39840
39841         In some float situations, the original layout is wrong and only corrects itself on repaint
39842         https://bugs.webkit.org/show_bug.cgi?id=18939
39843
39844         Reviewed by Levi Weintraub.
39845
39846         A <br> that follows collapsing spaces and has clearance set always needs to get a run and a linebox of its own.
39847         This allows the line below it to check for clearance from the <br> if it gets dirtied but the line with the <br>
39848         does not.
39849
39850         Test: fast/block/br-with-clearance-after-collapsing-space.html
39851
39852         * rendering/RenderBlockLineLayout.cpp:
39853         (WebCore::RenderBlock::LineBreaker::nextLineBreak):
39854
39855 2012-10-08  Robert Hogan  <robert@webkit.org>
39856
39857         floated element with negative margin causes text wrap bug
39858         https://bugs.webkit.org/show_bug.cgi?id=94825
39859
39860         Reviewed by Levi Weintraub.
39861
39862         Avoid over-estimating the available width on the line by ensuring that the offset taken to avoid
39863         floats on the line is at least as much as the offset given by border, margin and padding. This only
39864         happens when a negative margin on the float brings its edge back before the offset
39865         given by the border, margin and padding of its parents.
39866
39867         Test: fast/block/float/float-on-line-obeys-container-padding.html
39868
39869         * rendering/RenderBlockLineLayout.cpp:
39870         (WebCore::LineWidth::shrinkAvailableWidthForNewFloatIfNeeded):
39871
39872 2012-10-20  Martin Robinson  <mrobinson@igalia.com>
39873
39874         Fix 'make dist' for the GTK+ port
39875
39876         * GNUmakefile.am: Add missing files to the source list.
39877         * GNUmakefile.list.am: Ditto.
39878
39879 2012-10-20  Dan Bernstein  <mitz@apple.com>
39880
39881         <rdar://problem/12512710> [mac] Text with zero font size renders as 12px sometimes
39882         https://bugs.webkit.org/show_bug.cgi?id=99918
39883
39884         Reviewed by Geoff Garen.
39885
39886         -[NSFont fontWithName:size:] returns an NSFont of size 12 (the default User Font size) when
39887         asked for size 0, and this is what Font::drawGlyphs uses to draw the text.
39888
39889         Test: fast/text/zero-font-size-2.html
39890
39891         * platform/graphics/mac/FontMac.mm:
39892         (WebCore::Font::drawGlyphs): Added an early return if the size is zero.
39893
39894 2012-10-20  Andreas Kling  <kling@webkit.org>
39895
39896         Clean up QualifiedName-as-hash-key scenario.
39897         <http://webkit.org/b/99394>
39898
39899         Reviewed by Anders Carlsson.
39900
39901         Cache the hash on QualifiedNameImpl after the first time it's computed.
39902         This grows QualifiedNameImpl by 4 bytes on 32-bit (no change on 64-bit due to base class padding)
39903         which I believe is fine, since QualifiedName is a shared object.
39904
39905         Add a global nullQName() function that returns a QualifiedName(nullAtom, nullAtom, nullAtom)
39906         and use this to implement HashTraits<QualifiedName>::emptyValue(). The old implementation would
39907         create a new QualifiedName(nullAtom, nullAtom, nullAtom) each time, which had to be hashed,
39908         added to  the global QualifiedName cache, etc.
39909
39910         Finally, don't have SVGAttributeHashTranslator create a temporary QualifiedName just to compute
39911         the hash of a (namespace, prefix, localName) tuple, use QualifiedNameComponents and hashComponents()
39912         directly instead.
39913
39914         Altogether this shaves ~100ms off of the RoboHornet svgresize.html benchmark on my MBP.
39915
39916         * dom/QualifiedName.cpp:
39917         (WebCore::nullQName):
39918         (WebCore::QualifiedName::QualifiedNameImpl::computeHash):
39919         * dom/QualifiedName.h:
39920         (QualifiedNameImpl):
39921         (WebCore::QualifiedName::QualifiedNameImpl::QualifiedNameImpl):
39922         (WebCore::QualifiedNameHash::hash):
39923         * svg/SVGElement.h:
39924         (WebCore::SVGAttributeHashTranslator::hash):
39925
39926 2012-10-20  Yael Aharon  <yael.aharon@intel.com>
39927
39928         [EFL][AC] Build fix after r131933
39929         https://bugs.webkit.org/show_bug.cgi?id=99901
39930
39931         Reviewed by Kentaro Hara.
39932
39933         Add ArrayBoundsClamper.cpp to WebCore/CMakeLists.txt.
39934
39935         No new tests.
39936
39937         * CMakeLists.txt:
39938
39939 2012-10-19  Adam Barth  <abarth@webkit.org>
39940
39941         [V8] V8DOMWrapper should avoid using its document parameter (so we can remove it soon)
39942         https://bugs.webkit.org/show_bug.cgi?id=99876
39943
39944         Reviewed by Kentaro Hara.
39945
39946         We want to remove the document parameter to instantiateV8Object. There
39947         isn't always a Document available, so it doesn't make sense to pass it
39948         as a parameter. We're just waiting for a V8 API change so we can still
39949         construct Node wrappers quickly.
39950
39951         This patch removes a use of the document that snuck in. Rather than
39952         passing the ScriptExecutionContext around, we get it from the
39953         CreationContext of the prototype object (and only when we actually need
39954         it).
39955
39956         * Modules/notifications/NotificationCenter.cpp:
39957         * Modules/notifications/NotificationCenter.h:
39958         (NotificationCenter):
39959         * bindings/scripts/CodeGeneratorV8.pm:
39960         (GenerateHeader):
39961         (GenerateConstructorGetter):
39962         (GenerateImplementation):
39963         (GenerateToV8Converters):
39964         * bindings/v8/V8DOMWindowShell.cpp:
39965         (WebCore::V8DOMWindowShell::installDOMWindow):
39966         * bindings/v8/V8DOMWrapper.cpp:
39967         (WebCore::V8DOMWrapper::instantiateV8Object):
39968         * bindings/v8/V8PerContextData.cpp:
39969         (WebCore::V8PerContextData::createWrapperFromCacheSlowCase):
39970         (WebCore::V8PerContextData::constructorForTypeSlowCase):
39971         * bindings/v8/V8PerContextData.h:
39972         (WebCore::V8PerContextData::createWrapperFromCache):
39973         (WebCore::V8PerContextData::constructorForType):
39974         (V8PerContextData):
39975         * bindings/v8/WorkerContextExecutionProxy.cpp:
39976         (WebCore::WorkerContextExecutionProxy::initializeIfNeeded):
39977         * bindings/v8/WrapperTypeInfo.h:
39978         (WebCore):
39979         (WebCore::WrapperTypeInfo::installPerContextPrototypeProperties):
39980
39981 2012-10-19  Florin Malita  <fmalita@chromium.org>
39982
39983         Incorrect pattern scaling
39984         https://bugs.webkit.org/show_bug.cgi?id=99870
39985
39986         Reviewed by Dirk Schulze.
39987
39988         The pattern space transform scale should reflect the tile_size(user space)
39989         to tile_image_size ratio, instead of tile_size to absolute_tile_size.
39990
39991         Test: svg/custom/pattern-scaling.svg
39992
39993         * rendering/svg/RenderSVGResourcePattern.cpp:
39994         (WebCore::RenderSVGResourcePattern::applyResource):
39995
39996 2012-10-19  Tony Chang  <tony@chromium.org>
39997
39998         RenderFlexibleBox::preferredMainAxisContentExtentForChild can return a negative value
39999         https://bugs.webkit.org/show_bug.cgi?id=97827
40000
40001         Reviewed by Ojan Vafai.
40002
40003         I'm pretty sure this isn't possible (logicalHeight and maxPreferredLogicalWidth should always include
40004         border and padding), so just add an assert.
40005
40006         No new tests, the assert is for code clarity.
40007
40008         * rendering/RenderFlexibleBox.cpp:
40009         (WebCore::RenderFlexibleBox::preferredMainAxisContentExtentForChild):
40010
40011 2012-10-19  Tony Chang  <tony@chromium.org>
40012
40013         Replace calls to updateLogicalHeight with calls to computeLogicalHeight
40014         https://bugs.webkit.org/show_bug.cgi?id=99883
40015
40016         Reviewed by Ojan Vafai.
40017
40018         In RenderBox and RenderBlock, switch to using computeLogicalHeight instead of
40019         saving the old height, calling update logical height, then restoring the old height.
40020
40021         No new tests, this is just a refactoring.
40022
40023         * rendering/RenderBlock.cpp:
40024         (WebCore::RenderBlock::computeBlockPreferredLogicalWidths): Simple replace.
40025         * rendering/RenderBox.cpp:
40026         (WebCore::RenderBox::computePercentageLogicalHeight): Adjust for content height.
40027         (WebCore::RenderBox::computeReplacedLogicalHeightUsing): Adjust for content height.
40028         (WebCore::RenderBox::availableLogicalHeightUsing): Adjust for content height.
40029
40030 2012-10-19  Pablo Flouret  <pablof@motorola.com>
40031
40032         Implement setRangeText() on text controls
40033         https://bugs.webkit.org/show_bug.cgi?id=91907
40034
40035         Reviewed by Kent Tamura.
40036
40037         setRangeText() replaces a range of text with some other text, and
40038         adjusts the existing selection according to its parameters.
40039
40040         Spec: http://www.whatwg.org/specs/web-apps/current-work/multipage/association-of-controls-and-forms.html#dom-textarea/input-setrangetext
40041
40042         Tests: fast/forms/color/color-setrangetext.html
40043                fast/forms/date/date-setrangetext.html
40044                fast/forms/datetime/datetime-setrangetext.html
40045                fast/forms/datetimelocal/datetimelocal-setrangetext.html
40046                fast/forms/file/file-setrangetext.html
40047                fast/forms/hidden/hidden-setrangetext.html
40048                fast/forms/image/image-setrangetext.html
40049                fast/forms/month/month-setrangetext.html
40050                fast/forms/number/number-setrangetext.html
40051                fast/forms/range/range-setrangetext.html
40052                fast/forms/search/search-setrangetext.html
40053                fast/forms/setrangetext.html
40054                fast/forms/textarea/textarea-setrangetext.html
40055                fast/forms/time/time-setrangetext.html
40056                fast/forms/week/week-setrangetext.html
40057
40058
40059         * bindings/scripts/CodeGeneratorGObject.pm:
40060         (SkipFunction):
40061             The GObject generator doesn't support function overloads, so skip the
40062             version of setRangeText() that has only one argument, its behavior
40063             can be emulated with the four-argument version.
40064
40065         * html/InputType.cpp:
40066         (WebCore::InputType::supportsSelectionAPI):
40067         (WebCore):
40068         * html/InputType.h:
40069         (InputType):
40070             Add supportsSelectionAPI() which indicates whether the various
40071             selection api functions like setRangeText, setSelectionRange, etc.
40072             are supported by this input element.
40073
40074         * html/BaseTextInputType.cpp:
40075         (WebCore::BaseTextInputType::supportsSelectionAPI):
40076         (WebCore):
40077         * html/BaseTextInputType.h:
40078         (BaseTextInputType):
40079             Text-based input types support the selection APIs.
40080
40081         * html/EmailInputType.cpp:
40082         (WebCore::EmailInputType::supportsSelectionAPI):
40083         (WebCore):
40084         * html/EmailInputType.h:
40085         (EmailInputType):
40086             Email inputs don't support the selection APIs.
40087
40088         * html/HTMLInputElement.cpp:
40089         (WebCore::HTMLInputElement::setRangeText):
40090         * html/HTMLInputElement.h:
40091         (HTMLInputElement):
40092             Add a setRangeText override which checks if it should apply to the
40093             input type, and calls the actual implementation on the parent class.
40094         * html/HTMLInputElement.idl:
40095         * html/HTMLTextAreaElement.idl:
40096
40097         * html/HTMLTextFormControlElement.cpp:
40098         (WebCore::HTMLTextFormControlElement::setRangeText):
40099         * html/HTMLTextFormControlElement.h:
40100         (HTMLTextFormControlElement):
40101             setRangeText implementation.
40102
40103
40104 2012-10-19  Luke Macpherson   <macpherson@chromium.org>
40105
40106         Remove HANDLE_INHERIT_AND_INITIAL_AND_PRIMITIVE macro in StyleResolver.
40107         https://bugs.webkit.org/show_bug.cgi?id=99782
40108
40109         Reviewed by Sam Weinig.
40110
40111         Removes last usage of HANDLE_INHERIT_AND_INITIAL_AND_PRIMITIVE macro, so that in future there will be no temptation
40112         to use it instead of adding a line to StyleBuilder.
40113         Also removes redundant checks for inital and inherit (HANDLE_INHERIT_AND_INTIAL already returns in those cases).
40114         I don't want to move this code into StyleBuilder until the FIXME that is already there is fixed.
40115
40116         Covered by many existing writing mode tests (eg. fast/html/details-writing-mode.html)
40117
40118         * css/StyleResolver.cpp:
40119         (WebCore):
40120         (WebCore::StyleResolver::applyProperty):
40121
40122 2012-10-19  Joshua Bell  <jsbell@chromium.org>
40123
40124         IndexedDB: Hidden indexing events are visible to script via bubbling/capture
40125         https://bugs.webkit.org/show_bug.cgi?id=96566
40126
40127         Reviewed by Tony Chang.
40128
40129         Stop propagation of error events fired at internal indexing requests as a result of
40130         aborting, as they should not be visible to scripts.
40131
40132         Test: storage/indexeddb/index-population.html
40133
40134         * Modules/indexeddb/IDBObjectStore.cpp:
40135         (WebCore::IDBObjectStore::createIndex):
40136         * Modules/indexeddb/IDBRequest.cpp:
40137         (WebCore::IDBRequest::IDBRequest):
40138         (WebCore::IDBRequest::dispatchEvent):
40139         * Modules/indexeddb/IDBRequest.h:
40140         (WebCore::IDBRequest::preventPropagation):
40141         (IDBRequest):
40142
40143 2012-10-19  Simon Fraser  <simon.fraser@apple.com>
40144
40145         Remove .get() calls in assertions as suggested by Darin Adler.
40146         
40147         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
40148         (PlatformCALayer::appendSublayer):
40149         (PlatformCALayer::insertSublayer):
40150         (PlatformCALayer::replaceSublayer):
40151
40152 2012-10-19  Simon Fraser  <simon.fraser@apple.com>
40153
40154         Fix a hang when combining tile cache layers with preserve-3d or reflections
40155         https://bugs.webkit.org/show_bug.cgi?id=99890
40156         <rdar://problem/12539560>
40157
40158         Reviewed by Dean Jackson.
40159
40160         The new tile cache code added an updateSublayers() call when switching to/from
40161         tiled layers. This confused later sublayer rebuilding, causing us to attempt to
40162         add a layer as a child of itself, causing a hang in CA.
40163         
40164         Fix by removing all the explicit calls to updateFoo when updating the structural
40165         layer and switching to/from tiled layers. Instead, we set dirty flags, and rely
40166         on the fact that these flag-dirtying functions get called before the later functions
40167         that process those dirty flags. This is assured by some reordering of the update
40168         function calls.
40169         
40170         A final wrinkle is that ensureStructuralLayer() can change the layer that our
40171         parent GraphicsLayer put in its sublayer list. Rather than diddle with that sublayer
40172         list directly like we used to, just call noteSublayersChanged() on the parent, and have
40173         commitLayerChangesAfterSublayers() check the ChildrenChanged and do a second update
40174         of sublayers if necessary (we clear the flag in commitLayerChangesBeforeSublayers(), so
40175         only do this work if a sublayer requested it).
40176         
40177         Tests: compositing/tiling/preserve3d-tiled.html
40178                compositing/tiling/reflected-tiled.html
40179
40180         * platform/graphics/ca/GraphicsLayerCA.cpp:
40181         (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers):
40182         (WebCore::GraphicsLayerCA::commitLayerChangesAfterSublayers):
40183         (WebCore::GraphicsLayerCA::ensureStructuralLayer):
40184         (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
40185         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
40186         (PlatformCALayer::appendSublayer): Add assertion about adding a layer to itself.
40187         (PlatformCALayer::insertSublayer): Ditto.
40188         (PlatformCALayer::replaceSublayer): Ditto.
40189
40190 2012-10-19  Chris Fleizach  <cfleizach@apple.com>
40191
40192         AX: aria-hidden=false does not work as expected
40193         https://bugs.webkit.org/show_bug.cgi?id=98787
40194
40195         Reviewed by Beth Dakin.
40196
40197         ARIA requires that aria-hidden=false override an element's native visibility and include that
40198         node in the AX hierarchy.
40199
40200         To accomplish this we have to allow invisible items to be included, as well as items that
40201         have no renderers associated with them.
40202
40203         Test: accessibility/aria-hidden-negates-no-visibility.html
40204
40205         * accessibility/AXObjectCache.cpp:
40206         (WebCore::AXObjectCache::getOrCreate):
40207         * accessibility/AccessibilityARIAGrid.cpp:
40208         (WebCore::AccessibilityARIAGrid::addTableCellChild):
40209         (WebCore::AccessibilityARIAGrid::addChildren):
40210         * accessibility/AccessibilityARIAGrid.h:
40211         (AccessibilityARIAGrid):
40212         * accessibility/AccessibilityNodeObject.cpp:
40213         (WebCore):
40214        (WebCore::AccessibilityNodeObject::boundingBoxRect):
40215         (WebCore::AccessibilityNodeObject::insertChild):
40216         (WebCore::AccessibilityNodeObject::addChild):
40217         (WebCore::AccessibilityNodeObject::addChildren):
40218         (WebCore::AccessibilityNodeObject::textUnderElement):
40219         * accessibility/AccessibilityNodeObject.h:
40220         (AccessibilityNodeObject):
40221         * accessibility/AccessibilityObject.cpp:
40222         (WebCore::AccessibilityObject::textIteratorBehaviorForTextRange):
40223         (WebCore):
40224         * accessibility/AccessibilityObject.h:
40225         (AccessibilityObject):
40226         (WebCore::AccessibilityObject::addChild):
40227         (WebCore::AccessibilityObject::insertChild):
40228         * accessibility/AccessibilityRenderObject.cpp:
40229         (WebCore):
40230         (WebCore::AccessibilityRenderObject::accessibilityIsIgnoredBase):
40231         (WebCore::AccessibilityRenderObject::addHiddenChildren):
40232         (WebCore::AccessibilityRenderObject::addChildren):
40233         * accessibility/AccessibilityRenderObject.h:
40234         (AccessibilityRenderObject):
40235
40236 2012-10-19  Michael Saboff  <msaboff@apple.com>
40237
40238         Add String version of visitedLinkHash() to properly handle 8-bit URL Strings.
40239         https://bugs.webkit.org/show_bug.cgi?id=99735
40240
40241         Reviewed by Filip Pizlo.
40242
40243         Added String version of visitedLinkHash().  Made speculative addition of visitedLinkHash()
40244         to chromium platform version of LinkHashChromium.cpp.
40245         Changed calls in the form of visitedLinkHash(string.characters(), string.length()) to use the
40246         new form.
40247
40248         No changes to functionality, so no new tests.
40249
40250         * WebCore.exp.in:
40251         * loader/HistoryController.cpp:
40252         (WebCore::addVisitedLink):
40253         * page/PageGroup.cpp:
40254         (WebCore::PageGroup::addVisitedLink):
40255         * platform/LinkHash.cpp:
40256         (WebCore::visitedLinkHashInline):
40257         (WebCore::visitedLinkHash):
40258         * platform/LinkHash.h:
40259         * platform/chromium/LinkHashChromium.cpp:
40260         (WebCore::visitedLinkHash):
40261
40262 2012-10-19  Michael Saboff  <msaboff@apple.com>
40263
40264         String(CFStringRef) should try to converting to an 8 bit string before converting to  16 bit string
40265         https://bugs.webkit.org/show_bug.cgi?id=99794
40266
40267         Reviewed by Filip Pizlo.
40268
40269         Try getting a Latin1 byte string before getting a UTF16 (UChar*) string.
40270
40271         No new test, added 8 bit path.
40272
40273         * platform/text/cf/StringCF.cpp:
40274         (WTF::String::String):
40275
40276 2012-10-19  Dima Gorbik  <dgorbik@apple.com>
40277
40278         Page should be removed from the cache right after restore was called.
40279         https://bugs.webkit.org/show_bug.cgi?id=99737
40280
40281         Reviewed by Brady Eidson.
40282
40283         The pageCache was inconsistent after the restoration for a period of time because the cachedFrame is being nulled,
40284         but the page is still in the Cache. Now the page is being removed from the cache right after the restoration.
40285         This issue was spotted in a custom built application using WebKit and unfortunately there is no way to test this
40286         behavior in LayoutTests. All the current tests that exercise the page cache do pass.
40287
40288         No new tests.
40289
40290         * loader/FrameLoader.cpp:
40291         (WebCore::FrameLoader::commitProvisionalLoad):
40292
40293 2012-10-19  Max Vujovic  <mvujovic@adobe.com>
40294
40295         [WebGL] getUniformLocation fails for uniform array name without array brackets
40296         https://bugs.webkit.org/show_bug.cgi?id=99854
40297
40298         Reviewed by Dean Jackson.
40299
40300         Before this patch, gl.getUniformLocation(program, "array[0]") would return the array
40301         location, but gl.getUniformLocation(program, "array") would not. Now, the latter also
40302         returns the array location.
40303
40304         In the process of adding a check to the following Khronos WebGL conformance test:
40305         conformance/glsl/misc/glsl-long-variable-names.html
40306
40307         * platform/graphics/ANGLEWebKitBridge.cpp:
40308         (WebCore::getSymbolInfo):
40309             Before, we used to check that the symbol size was greater than one to determine that the
40310             symbol was an array. However, this doesn't identify arrays of length one. Now, we check
40311             if the symbol name ends in "[0]", since ANGLE appends this suffix to array symbol
40312             names.
40313             If the symbol is an array, we strip off the "[0]" and add a symbol with just the base
40314             name. We set the isArray flag on the symbol, so we don't lose the information that it is
40315             an array.
40316             Then, we create symbols for each array element like before. However, instead of
40317             replacing the "0" in array[0]" with each index, we take the base name "array" and
40318             append array brackets containing each index (e.g. "array" + "[7]").
40319         * platform/graphics/ANGLEWebKitBridge.h:
40320         (ANGLEShaderSymbol):
40321             Add isArray boolean to ANGLEShaderSymbol. Since array symbols don't end in "[0]"
40322             anymore, this is the only way to identify arrays.
40323
40324 2012-10-19  Csaba Osztrogonác  <ossy@webkit.org>
40325
40326         Unreviewed, rolling out r131915.
40327         http://trac.webkit.org/changeset/131915
40328         https://bugs.webkit.org/show_bug.cgi?id=98787
40329
40330         It broke the build on platforms with \!HAVE(ACCESSIBILITY)
40331
40332         * accessibility/AXObjectCache.cpp:
40333         (WebCore::AXObjectCache::getOrCreate):
40334         (WebCore::AXObjectCache::nodeIsTextControl):
40335         * accessibility/AXObjectCache.h:
40336         (WebCore):
40337         * accessibility/AccessibilityARIAGrid.cpp:
40338         (WebCore::AccessibilityARIAGrid::addChild):
40339         (WebCore::AccessibilityARIAGrid::addChildren):
40340         * accessibility/AccessibilityARIAGrid.h:
40341         (AccessibilityARIAGrid):
40342         * accessibility/AccessibilityNodeObject.cpp:
40343         (WebCore::AccessibilityNodeObject::elementRect):
40344         (WebCore::AccessibilityNodeObject::addChildren):
40345         (WebCore::AccessibilityNodeObject::textUnderElement):
40346         * accessibility/AccessibilityNodeObject.h:
40347         (AccessibilityNodeObject):
40348         * accessibility/AccessibilityObject.cpp:
40349         * accessibility/AccessibilityObject.h:
40350         (AccessibilityObject):
40351         * accessibility/AccessibilityRenderObject.cpp:
40352         (WebCore::textIteratorBehaviorForTextRange):
40353         (WebCore):
40354         (WebCore::AccessibilityRenderObject::accessibilityIsIgnoredBase):
40355         (WebCore::AccessibilityRenderObject::addChildren):
40356         * accessibility/AccessibilityRenderObject.h:
40357         (AccessibilityRenderObject):
40358
40359 2012-10-19  Tony Chang  <tony@chromium.org>
40360
40361         Unreviewed, rolling out r131936.
40362         http://trac.webkit.org/changeset/131936
40363         https://bugs.webkit.org/show_bug.cgi?id=99717
40364
40365         Broke the clang build
40366
40367         * WebCore.exp.in:
40368         * inspector/InspectorFrontendClient.h:
40369         (InspectorFrontendClient):
40370         * inspector/InspectorFrontendClientLocal.cpp:
40371         (WebCore::InspectorFrontendClientLocal::requestAttachWindow):
40372         (WebCore):
40373         (WebCore::InspectorFrontendClientLocal::requestDetachWindow):
40374         (WebCore::InspectorFrontendClientLocal::setAttachedWindow):
40375         * inspector/InspectorFrontendClientLocal.h:
40376         (InspectorFrontendClientLocal):
40377         (WebCore::InspectorFrontendClientLocal::requestSetDockSide):
40378         * inspector/InspectorFrontendHost.cpp:
40379         (WebCore::InspectorFrontendHost::requestAttachWindow):
40380         (WebCore):
40381         (WebCore::InspectorFrontendHost::requestDetachWindow):
40382         (WebCore::InspectorFrontendHost::requestSetDockSide):
40383         * inspector/InspectorFrontendHost.h:
40384         (InspectorFrontendHost):
40385         * inspector/InspectorFrontendHost.idl:
40386         * inspector/front-end/DockController.js:
40387         (WebInspector.DockController):
40388         (WebInspector.DockController.prototype.setDocked):
40389         (WebInspector.DockController.prototype._innerSetDocked.set if):
40390         (WebInspector.DockController.prototype._innerSetDocked):
40391         (WebInspector.DockController.prototype._updateUI.get states):
40392         (WebInspector.DockController.prototype._updateUI):
40393         (WebInspector.DockController.prototype._toggleDockState):
40394         * inspector/front-end/InspectorFrontendAPI.js:
40395         (InspectorFrontendAPI.setAttachedWindow):
40396         (InspectorFrontendAPI.setDockSide):
40397         * inspector/front-end/InspectorFrontendHostStub.js:
40398         (.WebInspector.InspectorFrontendHostStub.prototype.requestAttachWindow):
40399         (.WebInspector.InspectorFrontendHostStub.prototype.requestDetachWindow):
40400         (.WebInspector.InspectorFrontendHostStub.prototype.requestSetDockSide):
40401         * inspector/front-end/externs.js:
40402         (InspectorFrontendHostAPI.prototype.requestAttachWindow):
40403         (InspectorFrontendHostAPI.prototype.requestDetachWindow):
40404
40405 2012-10-09  Martin Robinson  <mrobinson@igalia.com>
40406
40407         REGRESSION (r130699): 5 various fast/ tests started failing
40408         https://bugs.webkit.org/show_bug.cgi?id=98729
40409
40410         Reviewed by Xan Lopez.
40411
40412         Do not try to remove the URL fragment for data URLs. This will likely
40413         just corrupt the URL.
40414
40415         No new tests. This unskips some previously failing tests.
40416
40417         * platform/network/soup/ResourceRequestSoup.cpp:
40418         (WebCore::ResourceRequest::urlStringForSoup): Do nothing for data URLs.
40419
40420 2012-10-19  Simon Fraser  <simon.fraser@apple.com>
40421
40422         Use tile caches in place of CATiledLayer
40423         https://bugs.webkit.org/show_bug.cgi?id=99806
40424         <rdar://problem/6474145>
40425
40426         Reviewed by Tim Horton.
40427
40428         Have GraphicsLayerCA use TileCaches instead of CATiledLayer now for
40429         layers that exceed the 2000px size threshold.
40430
40431         * platform/graphics/TiledBacking.h:
40432         (TiledBacking): Have normal getter and setter for the visible rect.
40433         * platform/graphics/ca/GraphicsLayerCA.cpp:
40434         (WebCore::GraphicsLayerCA::flushCompositingStateForThisLayerOnly): We need
40435         to pass in an old visibleRect to commitLayerChangesBeforeSublayers(). Just use
40436         our current visible rect, which result in no tile area work.
40437         (WebCore::GraphicsLayerCA::computeVisibleRect): Make this const and have it
40438         return the rect, for clarity.
40439         (WebCore::GraphicsLayerCA::recursiveCommitChanges): Keep track of the old
40440         visible rect, and use the change flags mechanism to ensure that we recompute
40441         tile areas later.
40442         When calling commitLayerChangesBeforeSublayers() on the mask layer, just pass
40443         its own visible rect as the old visible rect.
40444         (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers): Pass in the
40445         oldVisibleRect so that updateVisibleRect() can use this to see how the
40446         visibleRect is changing.
40447         (WebCore::GraphicsLayerCA::adjustTiledLayerVisibleRect): This member function
40448         compares the old and new visible rects, and extends the tile coverage area
40449         in directions where more content is being exposed. It takes care to avoid
40450         "jitter" in the visible rect deltas causing edge tiles to get created then
40451         destroyed by keeping any extra padding that already exists in a direction
40452         where more content is being exposed.
40453         (WebCore::GraphicsLayerCA::updateVisibleRect): Call adjustTiledLayerVisibleRect()
40454         and use the result to update the TiledBacking's visibleRect.
40455         (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer): Create layers of type
40456         LayerTypeTileCacheLayer instead of LayerTypeWebTiledLayer. Because tile
40457         cache layers involve adding an extra layer to the hierarchy (the tile container),
40458         we call updateSublayerList() when changing layer type.
40459         * platform/graphics/ca/GraphicsLayerCA.h: New m_sizeAtLastVisibleRectUpdate member
40460         that is used to prevent the adjustTiledLayerVisibleRect() logic being confused by
40461         size changes.
40462         (WebCore::GraphicsLayerCA::visibleRect):
40463         * platform/graphics/ca/mac/TileCache.h: Have normal getter and setter for the visible rect.
40464         * platform/graphics/ca/mac/TileCache.mm:
40465         (WebCore::TileCache::setVisibleRect): Renamed to setVisibleRect().
40466         * rendering/RenderLayerCompositor.cpp:
40467         (WebCore::RenderLayerCompositor::flushPendingLayerChanges): Avoid doing work
40468         for pages in the page cache, for which the root layer is unattached.
40469         (WebCore::RenderLayerCompositor::frameViewDidScroll): visibleRectChanged() was renamed
40470         to setVisibleRect().
40471
40472 2012-10-19  Beth Dakin  <bdakin@apple.com>
40473
40474         https://bugs.webkit.org/show_bug.cgi?id=99768
40475         We should limit the tile cache coverage when a page can't take 
40476         advantage of fast tile scrolling anyway
40477
40478         Reviewed by Simon Fraser.
40479
40480         When sites can't use fast-scrolling, there is no need to inflate the 
40481         tile cache. In fact, we get a performance boost by keeping it small 
40482         on painting-intensive sites. 
40483
40484         Instead of just looking a whether or not the FrameView 
40485         canHaveScrollbar(), consult 
40486         shouldUpdateScrollLayerPositionOnMainThread().
40487         * page/FrameView.cpp:
40488         (WebCore::FrameView::performPostLayoutTasks):
40489         * rendering/RenderLayerBacking.cpp:
40490         (WebCore::RenderLayerBacking::RenderLayerBacking):
40491         
40492         Expose shouldUpdateScrollLayerPositionOnMainThread().
40493         * page/scrolling/ScrollingCoordinator.cpp:
40494         (WebCore::ScrollingCoordinator::hasNonLayerFixedObjects):
40495         (WebCore::ScrollingCoordinator::shouldUpdateScrollLayerPositionOnMainThread):
40496         (WebCore):
40497         (WebCore::ScrollingCoordinator::updateShouldUpdateScrollLayerPositionOnMainThread):
40498         * page/scrolling/ScrollingCoordinator.h:
40499         (ScrollingCoordinator):
40500
40501         Bug fix. Should be bitwise and.
40502         * platform/graphics/ca/mac/TileCache.mm:
40503         (WebCore::TileCache::tileCoverageRect):
40504
40505 2012-10-19  Mark Lam  <mark.lam@apple.com>
40506
40507         Added WTF::StackStats mechanism.
40508         https://bugs.webkit.org/show_bug.cgi?id=99805.
40509
40510         Reviewed by Geoffrey Garen.
40511
40512         Added StackStats probes in layout methods.
40513
40514         * dom/Document.cpp:
40515         (WebCore::Document::updateLayout):
40516         * rendering/RenderBlock.cpp:
40517         (WebCore::RenderBlock::layout):
40518         * rendering/RenderBox.cpp:
40519         (WebCore::RenderBox::layout):
40520         * rendering/RenderDialog.cpp:
40521         (WebCore::RenderDialog::layout):
40522         * rendering/RenderEmbeddedObject.cpp:
40523         (WebCore::RenderEmbeddedObject::layout):
40524         * rendering/RenderFlowThread.cpp:
40525         (WebCore::RenderFlowThread::layout):
40526         * rendering/RenderFrameSet.cpp:
40527         (WebCore::RenderFrameSet::layout):
40528         * rendering/RenderIFrame.cpp:
40529         (WebCore::RenderIFrame::layout):
40530         * rendering/RenderImage.cpp:
40531         (WebCore::RenderImage::layout):
40532         * rendering/RenderListBox.cpp:
40533         (WebCore::RenderListBox::layout):
40534         * rendering/RenderListItem.cpp:
40535         (WebCore::RenderListItem::layout):
40536         * rendering/RenderListMarker.cpp:
40537         (WebCore::RenderListMarker::layout):
40538         * rendering/RenderMedia.cpp:
40539         (WebCore::RenderMedia::layout):
40540         * rendering/RenderObject.cpp:
40541         (WebCore::RenderObject::layout):
40542         * rendering/RenderObject.h:
40543         * rendering/RenderRegion.cpp:
40544         (WebCore::RenderRegion::layout):
40545         * rendering/RenderReplaced.cpp:
40546         (WebCore::RenderReplaced::layout):
40547         * rendering/RenderReplica.cpp:
40548         (WebCore::RenderReplica::layout):
40549         * rendering/RenderRubyRun.cpp:
40550         (WebCore::RenderRubyRun::layoutSpecialExcludedChild):
40551         * rendering/RenderScrollbarPart.cpp:
40552         (WebCore::RenderScrollbarPart::layout):
40553         * rendering/RenderSlider.cpp:
40554         (WebCore::RenderSlider::layout):
40555         * rendering/RenderTable.cpp:
40556         (WebCore::RenderTable::layout):
40557         * rendering/RenderTableCell.cpp:
40558         (WebCore::RenderTableCell::layout):
40559         * rendering/RenderTableRow.cpp:
40560         (WebCore::RenderTableRow::layout):
40561         * rendering/RenderTableSection.cpp:
40562         (WebCore::RenderTableSection::layout):
40563         * rendering/RenderTextControlSingleLine.cpp:
40564         (WebCore::RenderTextControlSingleLine::layout):
40565         * rendering/RenderTextTrackCue.cpp:
40566         (WebCore::RenderTextTrackCue::layout):
40567         * rendering/RenderVideo.cpp:
40568         (WebCore::RenderVideo::layout):
40569         * rendering/RenderView.cpp:
40570         (WebCore::RenderView::layout):
40571         * rendering/RenderWidget.cpp:
40572         (WebCore::RenderWidget::layout):
40573         * rendering/svg/RenderSVGContainer.cpp:
40574         (WebCore::RenderSVGContainer::layout):
40575         * rendering/svg/RenderSVGForeignObject.cpp:
40576         (WebCore::RenderSVGForeignObject::layout):
40577         * rendering/svg/RenderSVGGradientStop.cpp:
40578         (WebCore::RenderSVGGradientStop::layout):
40579         * rendering/svg/RenderSVGHiddenContainer.cpp:
40580         (WebCore::RenderSVGHiddenContainer::layout):
40581         * rendering/svg/RenderSVGImage.cpp:
40582         (WebCore::RenderSVGImage::layout):
40583         * rendering/svg/RenderSVGResourceContainer.cpp:
40584         (WebCore::RenderSVGResourceContainer::layout):
40585         * rendering/svg/RenderSVGResourceMarker.cpp:
40586         (WebCore::RenderSVGResourceMarker::layout):
40587         * rendering/svg/RenderSVGRoot.cpp:
40588         (WebCore::RenderSVGRoot::layout):
40589         * rendering/svg/RenderSVGShape.cpp:
40590         (WebCore::RenderSVGShape::layout):
40591         * rendering/svg/RenderSVGText.cpp:
40592         (WebCore::RenderSVGText::layout):
40593
40594 2012-10-19  Pavel Feldman  <pfeldman@chromium.org>
40595
40596         Web Inspector: merge "docked" state into the "dock side" enum.
40597         https://bugs.webkit.org/show_bug.cgi?id=99717
40598
40599         Reviewed by Vsevolod Vlasov.
40600
40601         Otherwise, it is hard to manage these inter-dependent flags.
40602
40603         * inspector/InspectorFrontendClient.h:
40604         (InspectorFrontendClient):
40605         * inspector/InspectorFrontendClientLocal.cpp:
40606         (WebCore::InspectorFrontendClientLocal::requestSetDockSide):
40607         (WebCore::InspectorFrontendClientLocal::setAttachedWindow):
40608         * inspector/InspectorFrontendClientLocal.h:
40609         (InspectorFrontendClientLocal):
40610         * inspector/InspectorFrontendHost.cpp:
40611         (WebCore::InspectorFrontendHost::requestSetDockSide):
40612         * inspector/InspectorFrontendHost.h:
40613         (InspectorFrontendHost):
40614         * inspector/InspectorFrontendHost.idl:
40615         * inspector/front-end/DockController.js:
40616         (WebInspector.DockController):
40617         (WebInspector.DockController.prototype._updateUI.get sides):
40618         (WebInspector.DockController.prototype._updateUI):
40619         (WebInspector.DockController.prototype._toggleDockState):
40620         * inspector/front-end/InspectorFrontendAPI.js:
40621         (InspectorFrontendAPI.setAttachedWindow):
40622         * inspector/front-end/InspectorFrontendHostStub.js:
40623         (.WebInspector.InspectorFrontendHostStub.prototype.requestSetDockSide):
40624
40625 2012-10-19  Joshua Bell  <jsbell@chromium.org>
40626
40627         [V8] IndexedDB: Crash when lazy-indexing Date keys
40628         https://bugs.webkit.org/show_bug.cgi?id=99860
40629
40630         Reviewed by Adam Barth.
40631
40632         Missing a scope/context needed when digging values out of Date objects
40633         in an indexing callback.
40634
40635         Test: storage/indexeddb/lazy-index-types.html
40636
40637         * bindings/v8/IDBBindingUtilities.cpp:
40638         (WebCore::createIDBKeyFromScriptValueAndKeyPath):
40639
40640 2012-10-18  Dean Jackson  <dino@apple.com>
40641
40642         Shader translator needs option to clamp uniform array accesses in vertex shaders
40643         https://bugs.webkit.org/show_bug.cgi?id=98977
40644         https://code.google.com/p/angleproject/issues/detail?id=49
40645
40646         Reviewed by Alok Priyadarshi and Ken Russell.
40647
40648         WebGL forbids out-of-bounds array access in shaders. Rewrite any shaders to
40649         ensure that non-direct array indexing is clamped to the bounds of the array.
40650
40651         Test: fast/canvas/webgl/array-bounds-clamping.html
40652
40653         * platform/graphics/ANGLEWebKitBridge.cpp:
40654         (WebCore::ANGLEWebKitBridge::compileShaderSource): Pass new compiler option SH_CLAMP_INDIRECT_ARRAY_BOUNDS
40655
40656 2012-10-19  Justin Novosad  <junov@chromium.org>
40657
40658         [Chromium] Reduce memory footprint of canvas pattern object with deferred rendering
40659         https://bugs.webkit.org/show_bug.cgi?id=99856
40660
40661         Reviewed by Stephen White.
40662
40663         Marking internal bitmap copy as immutable to prevent it from being
40664         unnecessarily duplicated in skia by SkBitmapHeap.
40665
40666         No new tests: code path already well covered by existing layout tests 
40667         fast/canvas/canvas-pattern-*
40668
40669         * platform/graphics/skia/PatternSkia.cpp:
40670         (WebCore::Pattern::platformPattern):
40671
40672 2012-10-19  Antti Koivisto  <antti@apple.com>
40673
40674         Maintain a list of active CSS stylesheets
40675         https://bugs.webkit.org/show_bug.cgi?id=99843
40676
40677         Reviewed by Andreas Kling.
40678
40679         Currently we maintain a per-document list of stylesheets that matches what is returned by the StyleSheetList DOM API. 
40680         This list contains both CSS and XSLT stylesheets which internally have basically nothing in common. Maintaining 
40681         a list of active CSS stylesheets separately simplifies code in number of places.
40682
40683         * css/StyleResolver.cpp:
40684         (WebCore::StyleResolver::StyleResolver):
40685         (WebCore::StyleResolver::addStylesheetsFromSeamlessParents):
40686         (WebCore::StyleResolver::appendAuthorStyleSheets):
40687         (WebCore::collectCSSOMWrappers):
40688         * css/StyleResolver.h:
40689         (StyleResolver):
40690         * css/StyleSheetList.cpp:
40691         (WebCore::StyleSheetList::styleSheets):
40692         (WebCore::StyleSheetList::detachFromDocument):
40693         * dom/Document.cpp:
40694         (WebCore::Document::setCompatibilityMode):
40695         * dom/DocumentStyleSheetCollection.cpp:
40696         (WebCore::DocumentStyleSheetCollection::analyzeStyleSheetChange):
40697         (WebCore::styleSheetsUseRemUnits):
40698         (WebCore::filterEnabledCSSStyleSheets):
40699         (WebCore):
40700         (WebCore::DocumentStyleSheetCollection::updateActiveStyleSheets):
40701         (WebCore::DocumentStyleSheetCollection::reportMemoryUsage):
40702         * dom/DocumentStyleSheetCollection.h:
40703         (WebCore::DocumentStyleSheetCollection::styleSheetsForStyleSheetList):
40704         (DocumentStyleSheetCollection):
40705         (WebCore::DocumentStyleSheetCollection::activeAuthorStyleSheets):
40706
40707 2012-09-08  Alpha Lam  <hclam@chromium.org>
40708
40709         [chromium] Implement deferred image decoding
40710         https://bugs.webkit.org/show_bug.cgi?id=94240
40711
40712         Reviewed by Stephen White.
40713
40714         Objectives:
40715
40716         To record image decoding operations during painting and to defer
40717         decoding operations until rasterization.
40718
40719         Rationale:
40720
40721         This is a key feature that enables impl-side painting which requires
40722         fast recording of drawing operations. The existing decode-on-draw
40723         restricts that recording has to block on expensive decoding operations.
40724         This change allows recording of image decoding operations during paint
40725         time.
40726
40727         Design:
40728
40729         Image decoding happens when a BitmapImage is drawn into a
40730         GraphicsContext. When per-tile painting is enabled GraphicsContext
40731         is backed by SkCanvas in recording mode. This SkCanvas records drawing
40732         and image decoding operations to minimize recording time.
40733
40734         An image decoding operation is recorded as a SkPixelRef object
40735         implemented by LazyDecodingPixelRef. This object references raw encoded
40736         data, regions to be decoded and scaling information.
40737
40738         When used in conjunction with per-tile painting this feature defers
40739         image decoding until the SkCanvas referencing the image is rasterized.
40740
40741         Both recording and rasterization happen on the main thread.
40742
40743         Performance Impact:
40744
40745         This feature is enabled by WebKit::setDeferredImageDecodingEnabled()
40746         and does not have an impact when disabled.
40747
40748         This feature is disabled by default.
40749
40750         Upcoming Changes:
40751
40752         1. Implement a full-featured image cache in ImageDecodingStore.
40753         2. Allow rasterization and decoding on impl thread.
40754
40755         Classes Involved:
40756
40757         BitmapImage
40758
40759         BitmapImage is the entry point for deferred image decoding. When
40760         drawing a BitmapImage into a GraphicsContext it makes a request to
40761         create a NativeImageSkia. We substitute the content in NativeImageSkia
40762         such that it is lazily decoded.
40763
40764         DeferredImageDecoder
40765
40766         This is the platform implementation of a image decoder for Chromium.
40767         This is a bridge layer that either delegates calls to the actual
40768         ImageDecoder or create a lazily-decoded SkBitmap and delegates calls
40769         to ImageDecodingStore.
40770
40771         ImageDecodingStore
40772
40773         This object manages all encoded images. It keeps track of encoded
40774         data and the corresponding ImageDecoder for doing actual decoding. It
40775         is also responsible for generating lazily decoded SkBitmaps. This
40776         SkBitmap contains a LazyDecodingPixelRef object which references to an
40777         image entry in ImageDecodingStore.
40778
40779         ScaledImageFragment
40780
40781         A container for a scaled image fragment. In addition to bitmap pixels
40782         it contains information about the ID of the image, scale and clipping.
40783
40784         ImageFrameGenerator
40785
40786         This object is responsible for generating decoded pixels. It is also
40787         a container for encoded image data and corresponding image decoder.
40788
40789         LazyDecodingPixelRef
40790
40791         This object is embedded in a SkBitmap to enable lazy decoding. When
40792         SkBitmap needs to access pixels LazyDecodingPixelRef is locked. It
40793         contains information to locate an image and scaling info, these
40794         information is submitted to ImageDecodingStore to access actual pixels.
40795
40796         Layout tests. There are about 80 tests in this virtual test suite
40797         running this feature in this directory:
40798
40799         platform/chromium/virtual/deferred/fast/images
40800
40801         Unit tests. Added DeferredImageDecoderTest to verify deferred
40802         image decoding behavior.
40803
40804         * WebCore.gypi:
40805         * platform/graphics/ImageSource.cpp:
40806         (WebCore::ImageSource::setData):
40807         * platform/graphics/ImageSource.h:
40808         (WebCore):
40809         (ImageSource):
40810         * platform/graphics/chromium/DeferredImageDecoder.cpp: Added.
40811         (WebCore):
40812         (WebCore::DeferredImageDecoder::DeferredImageDecoder):
40813         (WebCore::DeferredImageDecoder::~DeferredImageDecoder):
40814         (WebCore::DeferredImageDecoder::create):
40815         (WebCore::DeferredImageDecoder::createForTesting):
40816         (WebCore::DeferredImageDecoder::filenameExtension):
40817         (WebCore::DeferredImageDecoder::frameBufferAtIndex):
40818         (WebCore::DeferredImageDecoder::setData):
40819         (WebCore::DeferredImageDecoder::isSizeAvailable):
40820         (WebCore::DeferredImageDecoder::size):
40821         (WebCore::DeferredImageDecoder::frameSizeAtIndex):
40822         (WebCore::DeferredImageDecoder::frameCount):
40823         (WebCore::DeferredImageDecoder::repetitionCount):
40824         (WebCore::DeferredImageDecoder::clearFrameBufferCache):
40825         (WebCore::DeferredImageDecoder::frameHasAlphaAtIndex):
40826         (WebCore::DeferredImageDecoder::frameBytesAtIndex):
40827         * platform/graphics/chromium/DeferredImageDecoder.h: Added.
40828         (WebCore):
40829         (DeferredImageDecoder):
40830         * platform/graphics/chromium/ImageDecodingStore.cpp: Added.
40831         (WebCore::ImageDecodingStore::ImageDecodingStore):
40832         (WebCore):
40833         (WebCore::ImageDecodingStore::~ImageDecodingStore):
40834         (WebCore::ImageDecodingStore::instanceOnMainThread):
40835         (WebCore::ImageDecodingStore::initializeOnMainThread):
40836         (WebCore::ImageDecodingStore::shutdown):
40837         (WebCore::ImageDecodingStore::isLazyDecoded):
40838         (WebCore::ImageDecodingStore::createLazyDecodedSkBitmap):
40839         (WebCore::ImageDecodingStore::resizeLazyDecodedSkBitmap):
40840         (WebCore::ImageDecodingStore::setData):
40841         (WebCore::ImageDecodingStore::lockPixels):
40842         (WebCore::ImageDecodingStore::unlockPixels):
40843         (WebCore::ImageDecodingStore::frameGeneratorBeingDestroyed):
40844         (WebCore::ImageDecodingStore::calledOnValidThread):
40845         (WebCore::ImageDecodingStore::lookupFrameCache):
40846         (WebCore::ImageDecodingStore::deleteFrameCache):
40847         * platform/graphics/chromium/ImageDecodingStore.h: Added.
40848         (WebCore):
40849         (ImageDecodingStore):
40850         (WebCore::ImageDecodingStore::create):
40851         * platform/graphics/chromium/ScaledImageFragment.cpp: Added.
40852         (WebCore):
40853         (WebCore::ScaledImageFragment::~ScaledImageFragment):
40854         (WebCore::ScaledImageFragment::ScaledImageFragment):
40855         (WebCore::ScaledImageFragment::isEqual):
40856         * platform/graphics/chromium/ScaledImageFragment.h: Added.
40857         (WebCore):
40858         (ScaledImageFragment):
40859         (WebCore::ScaledImageFragment::create):
40860         (WebCore::ScaledImageFragment::bitmap):
40861         (WebCore::ScaledImageFragment::isComplete):
40862         * platform/graphics/chromium/ImageFrameGenerator.cpp: Added.
40863         (WebCore):
40864         (WebCore::ImageFrameGenerator::ImageFrameGenerator):
40865         (WebCore::ImageFrameGenerator::~ImageFrameGenerator):
40866         (WebCore::ImageFrameGenerator::decoder):
40867         (WebCore::ImageFrameGenerator::setData):
40868         * platform/graphics/chromium/ImageFrameGenerator.h: Added.
40869         (WebCore):
40870         (ImageFrameGenerator):
40871         (WebCore::ImageFrameGenerator::create):
40872         (WebCore::ImageFrameGenerator::size):
40873         (WebCore::ImageFrameGenerator::imageId):
40874         * platform/graphics/chromium/LazyDecodingPixelRef.cpp: Added.
40875         (WebCore):
40876         (WebCore::LazyDecodingPixelRef::LazyDecodingPixelRef):
40877         (WebCore::LazyDecodingPixelRef::~LazyDecodingPixelRef):
40878         (WebCore::LazyDecodingPixelRef::isScaled):
40879         (WebCore::LazyDecodingPixelRef::isClipped):
40880         (WebCore::LazyDecodingPixelRef::onLockPixels):
40881         (WebCore::LazyDecodingPixelRef::onUnlockPixels):
40882         (WebCore::LazyDecodingPixelRef::onLockPixelsAreWritable):
40883         * platform/graphics/chromium/LazyDecodingPixelRef.h: Added.
40884         (WebCore):
40885         (LazyDecodingPixelRef):
40886         (WebCore::LazyDecodingPixelRef::frameGenerator):
40887         * platform/graphics/skia/NativeImageSkia.cpp:
40888         (WebCore::NativeImageSkia::resizedBitmap):
40889         * platform/image-decoders/ImageDecoder.h:
40890         (ImageFrame):
40891         (WebCore::ImageFrame::setSkBitmap):
40892         (WebCore::ImageFrame::getSkBitmap):
40893
40894 2012-10-18  Yael Aharon  <yael.aharon@intel.com>
40895
40896         [EFL] GraphicsContext3D::m_renderStyle is not initialized
40897         https://bugs.webkit.org/show_bug.cgi?id=99721
40898
40899         Reviewed by Antonio Gomes.
40900
40901         Initialize GraphicsContext3D::m_renderStyle.
40902
40903         No new tests, no new functionality.
40904
40905         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
40906         (WebCore::GraphicsContext3D::GraphicsContext3D):
40907
40908 2012-10-19  Dongwoo Joshua Im  <dw.im@samsung.com>
40909
40910         Rename ENABLE_CSS3_TEXT_DECORATION to ENABLE_CSS3_TEXT
40911         https://bugs.webkit.org/show_bug.cgi?id=99804
40912
40913         Reviewed by Julien Chaffraix.
40914
40915         CSS3 text related properties will be implemented under this flag,
40916         including text decoration, text-align-last, and text-justify.
40917
40918         No new functionality, no new test.
40919
40920         * Configurations/FeatureDefines.xcconfig:
40921         * GNUmakefile.am:
40922         * GNUmakefile.features.am:
40923         * css/CSSComputedStyleDeclaration.cpp:
40924         (WebCore):
40925         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
40926         * css/CSSParser.cpp:
40927         (WebCore::CSSParser::parseValue):
40928         (WebCore::CSSParser::addTextDecorationProperty):
40929         (WebCore::CSSParser::parseTextDecoration):
40930         * css/CSSPrimitiveValueMappings.h:
40931         (WebCore):
40932         * css/CSSProperty.cpp:
40933         (WebCore::CSSProperty::isInheritedProperty):
40934         * css/CSSPropertyNames.in:
40935         * css/CSSValueKeywords.in:
40936         * css/StyleBuilder.cpp:
40937         (WebCore::StyleBuilder::StyleBuilder):
40938         * css/StyleResolver.cpp:
40939         (WebCore::StyleResolver::applyProperty):
40940         * rendering/style/RenderStyle.cpp:
40941         (WebCore::RenderStyle::diff):
40942         * rendering/style/RenderStyle.h:
40943         * rendering/style/RenderStyleConstants.h:
40944         (WebCore):
40945         * rendering/style/StyleRareNonInheritedData.cpp:
40946         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
40947         (WebCore::StyleRareNonInheritedData::operator==):
40948         * rendering/style/StyleRareNonInheritedData.h:
40949         (StyleRareNonInheritedData):
40950
40951 2012-10-19  Nate Chapin  <japhet@chromium.org>
40952
40953         Reorder some functions in SubresourceLoader to permit main resources
40954         https://bugs.webkit.org/show_bug.cgi?id=99769
40955
40956         Reviewed by Adam Barth.
40957
40958         Most resource types that go through the memory cache (and therefore
40959         through SubresourceLoader) are not sensitive to the exact ordering of
40960         the callbacks they receive, particularly as it relates to ResourceLoadNotifier
40961         calls.  Main resources are not so lenient.  For main resources to be cacheable
40962         and maintain the current behavior as precisely as possible, we will need to
40963         rearrange SubresourceLoader's willSendRequest() and didReceiveData().
40964
40965         No new tests, refactor only.
40966
40967         * loader/SubresourceLoader.cpp:
40968         (WebCore::SubresourceLoader::willSendRequest): There are a series of checks that can result
40969             in the request being canceled, plus calls to CachedResource::willSendRequest() and
40970             ResourceLoader::willSendRequest().  MainResourceLoader (which will be a
40971             CachedResourceClient) has work it expects to do before ResourceLoader::willSendRequest()
40972             is called, but the calls are out of order for that, so swap those.
40973         (WebCore::SubresourceLoader::didReceiveData): We need to populate ResourceLoader::m_resourceData
40974             before notifying CachedResource of new data, but we also want to do CachedResourceClients calls
40975             before calling ResourceLoadNotifier. This means we can't delegate to ResourceLoader.
40976
40977 2012-10-19  Chris Fleizach  <cfleizach@apple.com>
40978
40979         AX: aria-hidden=false does not work as expected
40980         https://bugs.webkit.org/show_bug.cgi?id=98787
40981
40982         Reviewed by Beth Dakin.
40983
40984         ARIA requires that aria-hidden=false override an element's native visibility and include that
40985         node in the AX hierarchy.
40986  
40987         To accomplish this we have to allow invisible items to be included, as well as items that
40988         have no renderers associated with them.
40989
40990         Test: accessibility/aria-hidden-negates-no-visibility.html
40991
40992         * accessibility/AXObjectCache.cpp:
40993         (WebCore::AXObjectCache::getOrCreate):
40994         * accessibility/AccessibilityARIAGrid.cpp:
40995         (WebCore::AccessibilityARIAGrid::addTableCellChild):
40996         (WebCore::AccessibilityARIAGrid::addChildren):
40997         * accessibility/AccessibilityARIAGrid.h:
40998         (AccessibilityARIAGrid):
40999         * accessibility/AccessibilityNodeObject.cpp:
41000         (WebCore):
41001         (WebCore::AccessibilityNodeObject::boundingBoxRect):
41002         (WebCore::AccessibilityNodeObject::insertChild):
41003         (WebCore::AccessibilityNodeObject::addChild):
41004         (WebCore::AccessibilityNodeObject::addChildren):
41005         (WebCore::AccessibilityNodeObject::textUnderElement):
41006         * accessibility/AccessibilityNodeObject.h:
41007         (AccessibilityNodeObject):
41008         * accessibility/AccessibilityObject.cpp:
41009         (WebCore::AccessibilityObject::textIteratorBehaviorForTextRange):
41010         (WebCore):
41011         * accessibility/AccessibilityObject.h:
41012         (AccessibilityObject):
41013         (WebCore::AccessibilityObject::addChild):
41014         (WebCore::AccessibilityObject::insertChild):
41015         * accessibility/AccessibilityRenderObject.cpp:
41016         (WebCore):
41017         (WebCore::AccessibilityRenderObject::accessibilityIsIgnoredBase):
41018         (WebCore::AccessibilityRenderObject::addHiddenChildren):
41019         (WebCore::AccessibilityRenderObject::addChildren):
41020         * accessibility/AccessibilityRenderObject.h:
41021         (AccessibilityRenderObject):
41022
41023 2012-10-19  Tommy Widenflycht  <tommyw@google.com>
41024
41025         MediaStream API: Rename owner to client in MediaStreamDescriptor
41026         https://bugs.webkit.org/show_bug.cgi?id=99593
41027
41028         Reviewed by Adam Barth.
41029
41030         This patch renames owner to client in MediaStreamDescriptor as discussed in #99080.
41031
41032         No new tests needed, covered by existing tests.
41033
41034         * Modules/mediastream/MediaStream.cpp:
41035         (WebCore::MediaStream::MediaStream):
41036         (WebCore::MediaStream::~MediaStream):
41037         * Modules/mediastream/MediaStream.h:
41038         (MediaStream):
41039         * Modules/mediastream/PeerConnection00.cpp:
41040         (WebCore::PeerConnection00::didRemoveRemoteStream):
41041         * Modules/mediastream/RTCPeerConnection.cpp:
41042         (WebCore::RTCPeerConnection::didRemoveRemoteStream):
41043         * platform/mediastream/MediaStreamCenter.cpp:
41044         (WebCore::MediaStreamCenter::endLocalMediaStream):
41045         (WebCore::MediaStreamCenter::addMediaStreamTrack):
41046         (WebCore::MediaStreamCenter::removeMediaStreamTrack):
41047         * platform/mediastream/MediaStreamDescriptor.h:
41048         (WebCore::MediaStreamDescriptorClient::~MediaStreamDescriptorClient):
41049         (WebCore::MediaStreamDescriptor::client):
41050         (WebCore::MediaStreamDescriptor::setClient):
41051         (WebCore::MediaStreamDescriptor::MediaStreamDescriptor):
41052         (MediaStreamDescriptor):
41053
41054 2012-10-19  Shinya Kawanaka  <shinyak@chromium.org>
41055
41056         Elements assigned to <shadow> should not be reprojected.
41057         https://bugs.webkit.org/show_bug.cgi?id=99680
41058
41059         Reviewed by Dimitri Glazkov.
41060
41061         In the current spec, we don't have shadow reprojection, i.e. elements assigned to <shadow> should not be
41062         reprojected to content. However, we can select them by <shadow>.
41063
41064         Tests: fast/dom/shadow/content-reprojection-complex.html
41065                fast/dom/shadow/content-reprojection-shadow.html
41066                fast/dom/shadow/shadow-reprojection-prohibited.html
41067
41068         * html/shadow/ContentDistributor.cpp:
41069         (WebCore::ContentDistributor::distribute): When a node is <shadow>, we should not add elements assigned to <shadow>
41070         to POOL. Instead, <shadow> itself should be added to POOL.
41071         * html/shadow/HTMLContentElement.h:
41072         (WebCore::isHTMLContentElement):
41073         (WebCore):
41074
41075 2012-10-19  Chris Fleizach  <cfleizach@apple.com>
41076
41077         VO issues with hidden <legend> and last explicitly labelled element within a group <fieldset>
41078         https://bugs.webkit.org/show_bug.cgi?id=96325
41079
41080         Reviewed by Beth Dakin.
41081
41082          When finding a <legend> for accessibility, we need to consider those that are offscreen. This patch
41083          modifies the original findLegend method to take a parameter to determine what should be done.
41084
41085         Test: accessibility/hidden-legend.html
41086
41087         * accessibility/AccessibilityRenderObject.cpp:
41088         (WebCore::AccessibilityRenderObject::titleUIElement):
41089         * rendering/RenderFieldset.cpp:
41090         (WebCore::RenderFieldset::findLegend):
41091         * rendering/RenderFieldset.h:
41092
41093 2012-10-17  Chris Fleizach  <cfleizach@apple.com>
41094
41095         AX: Refactor accessibility name computation so it's more platform independent
41096         https://bugs.webkit.org/show_bug.cgi?id=99502
41097
41098         Reviewed by Beth Dakin.
41099
41100         The current model of determining the accessible text for an object has a lot of Mac biases built in
41101         due to legacy implementation. 
41102
41103         This change categorizes and orders accessibility text based on WAI-ARIA text computation rules and then
41104         allows the platform (only Mac right now) to decide how best to apply that text to its own AX API.
41105         http://www.w3.org/TR/wai-aria/roles#textalternativecomputation
41106
41107         This change tried very hard not to change any test behavior, even though it exposed a number of weird
41108         edge cases where we were treating attributes differently based on element type. 
41109
41110         Future patches will resolve those discrepancies.
41111
41112         * accessibility/AccessibilityImageMapLink.cpp:
41113         (WebCore::AccessibilityImageMapLink::accessibilityText):
41114         * accessibility/AccessibilityImageMapLink.h:
41115         (AccessibilityImageMapLink):
41116         * accessibility/AccessibilityMediaControls.cpp:
41117         (WebCore::AccessibilityMediaControl::accessibilityText):
41118         * accessibility/AccessibilityMediaControls.h:
41119         (AccessibilityMediaControl):
41120         (WebCore::AccessibilityMediaTimeDisplay::isMediaControlLabel):
41121         * accessibility/AccessibilityNodeObject.cpp:
41122         (WebCore::AccessibilityNodeObject::titleElementText):
41123         (WebCore::AccessibilityNodeObject::accessibilityText):
41124         (WebCore::AccessibilityNodeObject::ariaLabeledByText):
41125         (WebCore::AccessibilityNodeObject::alternativeText):
41126         (WebCore::AccessibilityNodeObject::alternativeTextForWebArea):
41127         (WebCore::AccessibilityNodeObject::visibleText):
41128         (WebCore::AccessibilityNodeObject::helpText):
41129         (WebCore::AccessibilityNodeObject::ariaDescribedByAttribute):
41130         * accessibility/AccessibilityNodeObject.h:
41131         (AccessibilityNodeObject):
41132         * accessibility/AccessibilityObject.h:
41133         (AccessibilityText):
41134         (WebCore::AccessibilityText::AccessibilityText):
41135         (WebCore::AccessibilityObject::isMediaControlLabel):
41136         (AccessibilityObject):
41137         (WebCore::AccessibilityObject::accessibilityText):
41138         (WebCore::AccessibilityObject::setAccessibleName):
41139         (WebCore::AccessibilityObject::accessibilityDescription):
41140         (WebCore::AccessibilityObject::title):
41141         (WebCore::AccessibilityObject::helpText):
41142         (WebCore::AccessibilityObject::stringValue):
41143         (WebCore::AccessibilityObject::textUnderElement):
41144         (WebCore::AccessibilityObject::text):
41145         (WebCore::AccessibilityObject::textLength):
41146         (WebCore::AccessibilityObject::setRoleValue):
41147         (WebCore::AccessibilityObject::roleValue):
41148         (WebCore::AccessibilityObject::selection):
41149         (WebCore::AccessibilityObject::hierarchicalLevel):
41150         * accessibility/AccessibilityRenderObject.cpp:
41151         * accessibility/AccessibilityRenderObject.h:
41152         (AccessibilityRenderObject):
41153         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
41154         (-[WebAccessibilityObjectWrapper titleTagShouldBeUsedInDescriptionField]):
41155         (-[WebAccessibilityObjectWrapper accessibilityTitle]):
41156         (-[WebAccessibilityObjectWrapper accessibilityDescription]):
41157         (-[WebAccessibilityObjectWrapper accessibilityHelpText]):
41158         (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
41159         * platform/LocalizedStrings.cpp:
41160         (WebCore::localizedMediaControlElementHelpText):
41161
41162 2012-10-19  Kent Tamura  <tkent@chromium.org>
41163
41164         Use Localizer::monthFormat to construct input[type=month] UI
41165         https://bugs.webkit.org/show_bug.cgi?id=99818
41166
41167         Reviewed by Kentaro Hara.
41168
41169         Use an LDML format returned by Localizer::monthFormat for
41170         input[type=month] UI.
41171
41172         Because the format may contain symbolic month names and symbolic
41173         stand-alone month names, we need to add:
41174          - Symbolic/numeric detection in DateTimeEditBuilder
41175          - Normal/stand-alone detection in DateTimeEditBuilder
41176          - Symbolic edit field for months
41177
41178         Test: fast/forms/month-multiple-fields/month-multiple-fields-appearance-l10n.html,
41179               fast/forms/month-multiple-fields/month-multiple-fields-keyboard-events.html
41180
41181         * html/MonthInputType.cpp:
41182         (WebCore::MonthInputType::setupLayoutParameters):
41183         Use Localizer::monthFormat.
41184
41185         * html/shadow/DateTimeEditElement.cpp:
41186         (WebCore::DateTimeEditBuilder::visitField):
41187         - If the number of continuous field character is greater than 2, use
41188         DateTimeSymbolicMonthFieldElement.
41189         - Supports stand-alone month field.
41190
41191         * html/shadow/DateTimeFieldElements.h:
41192         (DateTimeSymbolicMonthFieldElement): Added. A subclass of DateTimeSymbolicFieldElement.
41193         * html/shadow/DateTimeFieldElements.cpp:
41194         (WebCore::DateTimeSymbolicMonthFieldElement::DateTimeSymbolicMonthFieldElement):
41195         Added.
41196         (WebCore::DateTimeSymbolicMonthFieldElement::create): Added.
41197         (WebCore::DateTimeSymbolicMonthFieldElement::populateDateTimeFieldsState):
41198         We need to add 1 because the internal integer representation is 0-based
41199         and DateTimeFieldsState uses 1-based month.
41200         (WebCore::DateTimeSymbolicMonthFieldElement::setValueAsDate):
41201         DateComponents::month is 0-based.
41202         (WebCore::DateTimeSymbolicMonthFieldElement::setValueAsDateTimeFieldsState):
41203         We need to subtract 1 because the internal integer representation is 0-based
41204         and DateTimeFieldsState uses 1-based month.
41205
41206         * html/shadow/DateTimeSymbolicFieldElement.h:
41207         (WebCore::DateTimeSymbolicFieldElement::symbolsSize):
41208         Added for DateTimeSymbolicMonthFieldElement::setValueAsDateTimeFieldsState.
41209
41210 2012-10-19  Vsevolod Vlasov  <vsevik@chromium.org>
41211
41212         Web Inspector: inspector/styles/styles-history.html is failing Text on Windows and Linux
41213         https://bugs.webkit.org/show_bug.cgi?id=99519
41214
41215         Reviewed by Alexander Pavlov.
41216
41217         Extracted _styleContentSet callback in a class method to make it sniffable by tests.
41218
41219         * inspector/front-end/StylesSourceMapping.js:
41220         (WebInspector.StyleFile.prototype._commitIncrementalEdit):
41221         (WebInspector.StyleFile.prototype._styleContentSet):
41222
41223 2012-10-19  Pavel Feldman  <pfeldman@chromium.org>
41224
41225         Web Inspector: add object-src 'none' to the inspector.html
41226         https://bugs.webkit.org/show_bug.cgi?id=99728
41227
41228         Reviewed by Vsevolod Vlasov.
41229
41230         * inspector/front-end/inspector.html:
41231
41232 2012-10-19  Vsevolod Vlasov  <vsevik@chromium.org>
41233
41234         Web Inspector: Get rid of isSnippetEvaluation flag on UISourceCode
41235         https://bugs.webkit.org/show_bug.cgi?id=99823
41236
41237         Reviewed by Yury Semikhatsky.
41238
41239         Replaced isSnippetEvaluation flag with a pair of isSnippet and isTemporary set.
41240
41241         * inspector/front-end/ResourceScriptMapping.js:
41242         (WebInspector.ResourceScriptMapping.prototype._getOrCreateTemporaryUISourceCode):
41243         * inspector/front-end/ScriptSnippetModel.js:
41244         (WebInspector.ScriptSnippetModel.prototype._releasedUISourceCodes):
41245         (WebInspector.ScriptSnippetModel.prototype._createUISourceCodeForScript):
41246         * inspector/front-end/ScriptsNavigator.js:
41247         (WebInspector.ScriptsNavigator.prototype._snippetsNavigatorViewForUISourceCode):
41248         (WebInspector.ScriptsNavigator.prototype.revealUISourceCode):
41249         * inspector/front-end/ScriptsPanel.js:
41250         (WebInspector.ScriptsPanel.prototype._createSourceFrame):
41251         * inspector/front-end/Workspace.js:
41252         (WebInspector.Project.prototype.addTemporaryUISourceCode):
41253
41254 2012-10-19  Alexander Pavlov  <apavlov@chromium.org>
41255
41256         Web Inspector: Invalid Regex in SASSSourceMapping/didRequestContent, breaks Support for Sass experiment
41257         https://bugs.webkit.org/show_bug.cgi?id=99729
41258
41259         Reviewed by Vsevolod Vlasov.
41260
41261         Decode only the first line number digit written in a six-character escaped Unicode format.
41262
41263         * inspector/front-end/SASSSourceMapping.js:
41264         (WebInspector.SASSSourceMapping.prototype._resourceAdded.didRequestContent):
41265         (WebInspector.SASSSourceMapping.prototype._resourceAdded):
41266
41267 2012-10-19  Tommy Widenflycht  <tommyw@google.com>
41268
41269         MediaStream API: Update the RuntimeEnabledFeatures flags
41270         https://bugs.webkit.org/show_bug.cgi?id=99714
41271
41272         Reviewed by Adam Barth.
41273
41274         Updating the RuntimeEnabledFeatures flags to match reality:
41275         isMediaStreamEnabled and isPeerConnectionEnabled should be true by default and
41276         isDeprecatedPeerConnectionEnabled false.
41277
41278         Patch covered by existing tests.
41279
41280         * bindings/generic/RuntimeEnabledFeatures.cpp:
41281         (WebCore):
41282
41283 2012-10-19  Adam Barth  <abarth@webkit.org>
41284
41285         [V8] Simplify GCPrologueVisitor
41286         https://bugs.webkit.org/show_bug.cgi?id=99819
41287
41288         Reviewed by Kentaro Hara.
41289
41290         Previously, GCPrologueVisitor used a complicated traits-based template
41291         design. That's not necessary. We can just implement it directly without
41292         template magic.
41293
41294         The one subtly here is that MessagePort is not actually a subclass of
41295         ActiveDOMObject. The next stage of this cleanup is to make MessagePort
41296         inherit from ActiveDOMObject and remove this special case entirely.
41297
41298         * bindings/v8/V8GCController.cpp:
41299         (WebCore::EnsureWeakDOMNodeVisitor::visitDOMWrapper):
41300         (WebCore):
41301         (WebCore::ActiveDOMObjectPrologueVisitor::visitDOMWrapper):
41302         (WebCore::NodeVisitor::visitDOMWrapper):
41303         (WebCore::V8GCController::gcPrologue):
41304
41305 2012-10-19  Eugene Klyuchnikov  <eustas.bug@gmail.com>
41306
41307         Web Inspector: Saving HAR, snapshots and timeline data do not work in remote debugging mode
41308         https://bugs.webkit.org/show_bug.cgi?id=99179
41309
41310         Reviewed by Yury Semikhatsky.
41311
41312         Added method "close" to InspectorFrontendHost.
41313         Symantically, this method forces to flush all unsaved buffers for
41314         specified file. In native implementation this turns to be no-op.
41315
41316         In stub implementation "close" causes compilation of blob object an
41317         navigating to blob-schema url.
41318
41319         Removed "canAppend", as appending in now suppurted
41320         by all implementations.
41321
41322         Repaced schema "data" with "blob" in InspectorFrontendHostStub "save"
41323         to avoid out-of-memory errors.
41324
41325         * inspector/InspectorFrontendHost.cpp:
41326         (WebCore::InspectorFrontendHost::close): Compiles blob object and
41327         navigates to blob-object url.
41328         (WebCore):
41329         * inspector/InspectorFrontendHost.h: Added "close" method.
41330         * inspector/InspectorFrontendHost.idl: Ditto.
41331         * inspector/front-end/FileManager.js:
41332         (WebInspector.FileManager.prototype.close): Proxy to InspectorFrontend.
41333         * inspector/front-end/FileUtils.js:
41334         (WebInspector.FileOutputStream.prototype.close):
41335         Invoke "close" on FileManager.
41336         (WebInspector.FileOutputStream.prototype._onAppendDone): Ditto.
41337         * inspector/front-end/HandlerRegistry.js: Added mandatory "close" call.
41338         * inspector/front-end/HeapSnapshotView.js:
41339         (WebInspector.HeapProfileHeader.prototype.canSaveToFile): Fixed check.
41340         * inspector/front-end/InspectorFrontendHostStub.js:
41341         (.WebInspector.InspectorFrontendHostStub):
41342         Added "appendable" behaviour emulation.
41343         * inspector/front-end/SourceFrame.js: Added mandatory "close" call.
41344         * inspector/front-end/externs.js: Replaced "canAppend" with "close"
41345
41346 2012-10-18  Dominic Mazzoni  <dmazzoni@google.com>
41347
41348         AX: labelForElement is slow when there are a lot of DOM elements
41349         https://bugs.webkit.org/show_bug.cgi?id=97825
41350
41351         Reviewed by Ryosuke Niwa.
41352
41353         Adds a DocumentOrderedMap to TreeScope that allows accessibility to
41354         quickly map from an id to the label for that id. This speeds up
41355         AccessibilityNode::labelForElement, which was a bottleneck in Chromium
41356         when accessibility was on.
41357
41358         Tests: accessibility/title-ui-element-correctness.html
41359                perf/accessibility-title-ui-element.html
41360
41361         * accessibility/AccessibilityNodeObject.cpp:
41362         (WebCore::AccessibilityNodeObject::labelForElement):
41363         * dom/DocumentOrderedMap.cpp:
41364         (WebCore::keyMatchesLabelForAttribute):
41365         (WebCore):
41366         (WebCore::DocumentOrderedMap::get):
41367         (WebCore::DocumentOrderedMap::getElementByLabelForAttribute):
41368         * dom/DocumentOrderedMap.h:
41369         (DocumentOrderedMap):
41370         * dom/Element.cpp:
41371         (WebCore::Element::insertedInto):
41372         (WebCore::Element::removedFrom):
41373         (WebCore::Element::updateLabel):
41374         (WebCore):
41375         (WebCore::Element::willModifyAttribute):
41376         * dom/Element.h:
41377         (Element):
41378         * dom/TreeScope.cpp:
41379         (WebCore::TreeScope::TreeScope):
41380         (WebCore::TreeScope::destroyTreeScopeData):
41381         (WebCore::TreeScope::addLabel):
41382         (WebCore):
41383         (WebCore::TreeScope::removeLabel):
41384         (WebCore::TreeScope::labelElementForId):
41385         * dom/TreeScope.h:
41386         (WebCore):
41387         (TreeScope):
41388         (WebCore::TreeScope::shouldCacheLabelsByForAttribute):
41389
41390 2012-10-19  Eugene Klyuchnikov  <eustas.bug@gmail.com>
41391
41392         Web Inspector: Update localizedStrings.js
41393         https://bugs.webkit.org/show_bug.cgi?id=99701
41394
41395         Reviewed by Yury Semikhatsky.
41396
41397         Fixed most of missing strings and orphans.
41398
41399         * English.lproj/localizedStrings.js:
41400         * inspector/front-end/SettingsScreen.js:
41401
41402 2012-10-17  Ilya Tikhonovsky  <loislo@chromium.org>
41403
41404         Web Inspector: NMI provide data for mixing with tcmalloc heap dumps.
41405         https://bugs.webkit.org/show_bug.cgi?id=99457
41406
41407         Reviewed by Yury Semikhatsky.
41408
41409         countObjectSize now accepts ptr as the first argument and saves it into HashMap if the binary was ran with HEAPPROFILE env variable.
41410         getProcessMemoryDistribution does snapshot and calls the downstream code with the map of counted objects.
41411
41412         * inspector/InspectorClient.h:
41413         (WebCore::InspectorClient::dumpUncountedAllocatedObjects):
41414         * inspector/InspectorMemoryAgent.cpp:
41415         (WebCore::reportJSHeapInfo):
41416         (WebCore::reportRenderTreeInfo):
41417         (WebCore):
41418         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
41419         * inspector/MemoryInstrumentationImpl.cpp:
41420         (WebCore::MemoryInstrumentationClientImpl::countObjectSize):
41421         (WebCore::MemoryInstrumentationClientImpl::reportMemoryUsage):
41422         * inspector/MemoryInstrumentationImpl.h:
41423         (MemoryInstrumentationClientImpl):
41424         (WebCore::MemoryInstrumentationClientImpl::countedObjects):
41425
41426 2012-10-19  Adam Barth  <abarth@webkit.org>
41427
41428         [V8] DOMObjectVisitor does nothing
41429         https://bugs.webkit.org/show_bug.cgi?id=99812
41430
41431         Reviewed by Kentaro Hara.
41432
41433         This code doesn't do anything, even in Debug! We should just remove it.
41434
41435         * bindings/v8/V8GCController.cpp:
41436         (WebCore):
41437         (WebCore::V8GCController::gcPrologue):
41438         (WebCore::V8GCController::gcEpilogue):
41439
41440 2012-10-19  Adam Barth  <abarth@webkit.org>
41441
41442         [V8] Remove unused typedef from V8GCController.cpp
41443         https://bugs.webkit.org/show_bug.cgi?id=99808
41444
41445         Reviewed by Kentaro Hara.
41446
41447         This typedef is not used.
41448
41449         * bindings/v8/V8GCController.cpp:
41450
41451 2012-10-18  Alexander Pavlov  <apavlov@chromium.org>
41452
41453         Web Inspector: [Styles] Property considered overridden if it is non-inherited important property in inherited style
41454         https://bugs.webkit.org/show_bug.cgi?id=99720
41455
41456         Reviewed by Yury Semikhatsky.
41457
41458         Non-inherited properties are now disregarded in inherited styles.
41459
41460         * inspector/front-end/StylesSidebarPane.js:
41461         (WebInspector.StylesSidebarPane.prototype._refreshStyleRules):
41462         (WebInspector.StylesSidebarPane.prototype._markUsedProperties):
41463
41464 2012-10-18  Adam Barth  <abarth@webkit.org>
41465
41466         [V8] GrouperVisitor is secretly two entirely separate objects
41467         https://bugs.webkit.org/show_bug.cgi?id=99810
41468
41469         Reviewed by Kentaro Hara.
41470
41471         We can separate out the two things that GrouperVisitor is trying to do
41472         because they have nothing to do with each other.
41473
41474         * bindings/v8/V8GCController.cpp:
41475         (ObjectVisitor):
41476         (WebCore::ObjectVisitor::visitDOMWrapper):
41477         (WebCore):
41478         (WebCore::V8GCController::gcPrologue):
41479
41480 2012-10-18  Kiran Muppala  <cmuppala@apple.com>
41481
41482         Automatically start plugins created within a user gesture, skipping snapshotting
41483         https://bugs.webkit.org/show_bug.cgi?id=99778
41484
41485         Reviewed by Alexey Proskuryakov.
41486
41487         If a user gesture is being processed, do not set the display state of
41488         HTMLPluginImageElement to WaitingForSnapshot.
41489
41490         No new tests, since it only affects when plugins switch from snapshot to running
41491         state.  Does not affect rendering of other elements.
41492
41493         * html/HTMLPlugInImageElement.cpp:
41494         (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement):
41495
41496 2012-10-18  Kent Tamura  <tkent@chromium.org>
41497
41498         Add shortMonthLabels and shortStandAloneMonthLabels to Localizer
41499         https://bugs.webkit.org/show_bug.cgi?id=99787
41500
41501         Reviewed by Kentaro Hara.
41502
41503         This is going to be used for input[type=month] UI. This doesn't affect
41504         any bahevior yet.
41505
41506         Tests: Add some tests to Source/WebKit/chromium/tests/, and will add
41507         layout tests later.
41508
41509         * platform/text/Localizer.h:
41510         (Localizer): Add shortMonthLabels and shortStandAloneMonthLabels as pure
41511         virtual member functions.
41512
41513         * platform/text/LocaleICU.h:
41514         (LocaleICU): Declare shortMonthLabels and shortStandAloneMonthLabels.
41515         * platform/text/LocaleICU.cpp:
41516         (WebCore::LocaleICU::shortMonthLabels): Added.
41517         (WebCore::LocaleICU::shortStandAloneMonthLabels): Added.
41518
41519         * platform/text/LocaleNone.cpp:
41520         (LocaleNone): Declare shortMonthLabels and shortStandAloneMonthLabels.
41521         (WebCore::LocaleNone::shortMonthLabels):
41522         Added. Always returns English labels.
41523         (WebCore::LocaleNone::shortStandAloneMonthLabels):
41524         Addes. Just calls shortMonthLabels.
41525
41526         * platform/text/LocaleWin.h:
41527         (LocaleWin): Declare shortMonthLabels and shortStandAloneMonthLabels.
41528         * platform/text/LocaleWin.cpp:
41529         (WebCore::LocaleWin::shortMonthLabels): Added.
41530         (WebCore::LocaleWin::shortStandAloneMonthLabels):
41531         Added. Always returns shortMonthLabels.
41532
41533         * platform/text/mac/LocaleMac.h:
41534         (LocaleMac): Declare shortMonthLabels and shortStandAloneMonthLabels.
41535         * platform/text/mac/LocaleMac.mm:
41536         (WebCore::LocaleMac::shortMonthLabels): Added.
41537         (WebCore::LocaleMac::shortStandAloneMonthLabels): Added.
41538
41539 2012-10-18  Kunihiko Sakamoto  <ksakamoto@chromium.org>
41540
41541         Implement value sanitization algorithm for type=datetime
41542         https://bugs.webkit.org/show_bug.cgi?id=76893
41543
41544         Reviewed by Kent Tamura.
41545
41546         Implement the value sanitization algorithm for type=datetime that adjusts
41547         the value to a valid normalized forced-UTC global date and time string.
41548         See http://www.whatwg.org/specs/web-apps/current-work/multipage/common-microsyntaxes.html#valid-normalized-forced-utc-global-date-and-time-string
41549
41550         Test: fast/forms/datetime/datetime-value-sanitization.html
41551
41552         * html/DateTimeInputType.cpp:
41553         (WebCore::DateTimeInputType::sanitizeValue): Implemented.
41554         (WebCore):
41555         * html/DateTimeInputType.h:
41556         (DateTimeInputType): Add sanitizeValue.
41557         * platform/DateComponents.cpp:
41558         (WebCore::DateComponents::addMinute): Fixed a bug that caused wrong adjustment
41559         of timezone offset (e.g. 2012-10-17T01:00+01:00 -> 2012-10-17T01:-60Z).
41560
41561 2012-10-18  Byungwoo Lee  <bw80.lee@samsung.com>
41562
41563         Fix build warning.
41564         https://bugs.webkit.org/show_bug.cgi?id=99788
41565
41566         Reviewed by Kentaro Hara.
41567
41568         Use UNUSED_PARAM macro for removing -Wunused-parameter.
41569
41570         * rendering/RenderLayer.cpp:
41571         (WebCore::RenderLayer::currentTransform):
41572
41573 2012-10-18  Benjamin Poulain  <bpoulain@apple.com>
41574
41575         [WK2] WebKit2 does not build without PLUGIN_PROCESS on Mac
41576         https://bugs.webkit.org/show_bug.cgi?id=99771
41577
41578         Reviewed by Anders Carlsson.
41579
41580         * WebCore.exp.in: The symbol is used by WebCore Test Support, move it
41581         to the general section.
41582
41583 2012-10-18  Adam Barth  <abarth@webkit.org>
41584
41585         [V8] fast/dom/gc-9.html fails for document.styleSheets
41586         https://bugs.webkit.org/show_bug.cgi?id=99786
41587
41588         Reviewed by Kentaro Hara.
41589
41590         V8 needs to know about this IDL attribute as well.
41591
41592         * css/StyleSheetList.idl:
41593
41594 2012-10-18  Adam Barth  <abarth@webkit.org>
41595
41596         [V8] fast/dom/gc-9.html fails for document.implementation
41597         https://bugs.webkit.org/show_bug.cgi?id=99783
41598
41599         Reviewed by Kentaro Hara.
41600
41601         In order to correctly manage the lifetime of document.implementation,
41602         we need to implement GenerateIsReachable=ImplDocument.
41603
41604         * bindings/scripts/CodeGeneratorV8.pm:
41605         (GenerateVisitDOMWrapper):
41606         * bindings/scripts/IDLAttributes.txt:
41607         * dom/DOMImplementation.idl:
41608
41609 2012-10-18  Chris Fleizach  <cfleizach@apple.com>
41610
41611         AX: Crashes in WebProcess at com.apple.WebCore: -[AccessibilityObjectWrapper remoteAccessibilityParentObject] + 78
41612         https://bugs.webkit.org/show_bug.cgi?id=96443
41613
41614         Reviewed by Beth Dakin.
41615
41616         Separate out the chain of calls so that the number of times document() is called is reduced and it will be easier
41617         to determine which line this crash is happening on.
41618
41619         * accessibility/mac/WebAccessibilityObjectWrapper.mm:
41620         (-[WebAccessibilityObjectWrapper remoteAccessibilityParentObject]):
41621
41622 2012-10-18  Alec Flett  <alecflett@chromium.org>
41623
41624         IndexedDB: Refactor IDBDatabaseBackendImpl to use IDBDatabaseMetadata
41625         https://bugs.webkit.org/show_bug.cgi?id=99773
41626
41627         Reviewed by Tony Chang.
41628
41629         Refactor to begin separating out metadata from stateful backend objects,
41630         in preparation for https://bugs.webkit.org/show_bug.cgi?id=99774.
41631
41632         Also includes some #include dependency cleanup so that the backing store
41633         depends less on the stateful backend objects.
41634
41635         No new tests as this is purely a refactor.
41636
41637         * Modules/indexeddb/IDBBackingStore.h:
41638         (WebCore):
41639         (IDBBackingStore):
41640         * Modules/indexeddb/IDBCursor.h:
41641         * Modules/indexeddb/IDBCursorBackendImpl.h:
41642         (WebCore):
41643         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
41644         (WebCore::IDBDatabaseBackendImpl::IDBDatabaseBackendImpl):
41645         (WebCore::IDBDatabaseBackendImpl::openInternal):
41646         (WebCore::IDBDatabaseBackendImpl::metadata):
41647         (WebCore::IDBDatabaseBackendImpl::createObjectStore):
41648         (WebCore::IDBDatabaseBackendImpl::setVersion):
41649         (WebCore::IDBDatabaseBackendImpl::setVersionInternal):
41650         (WebCore::IDBDatabaseBackendImpl::setIntVersionInternal):
41651         (WebCore::IDBDatabaseBackendImpl::processPendingCalls):
41652         (WebCore::IDBDatabaseBackendImpl::openConnection):
41653         (WebCore::IDBDatabaseBackendImpl::runIntVersionChangeTransaction):
41654         (WebCore::IDBDatabaseBackendImpl::openConnectionWithVersion):
41655         (WebCore::IDBDatabaseBackendImpl::deleteDatabase):
41656         (WebCore::IDBDatabaseBackendImpl::loadObjectStores):
41657         (WebCore::IDBDatabaseBackendImpl::resetVersion):
41658         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
41659         (WebCore::IDBDatabaseBackendImpl::id):
41660         (IDBDatabaseBackendImpl):
41661         * Modules/indexeddb/IDBLevelDBBackingStore.cpp:
41662         (WebCore::IDBLevelDBBackingStore::getIDBDatabaseMetaData):
41663         (WebCore::IDBLevelDBBackingStore::deleteDatabase):
41664         * Modules/indexeddb/IDBLevelDBBackingStore.h:
41665         (IDBLevelDBBackingStore):
41666         * Modules/indexeddb/IDBObjectStoreBackendInterface.h:
41667         * Modules/indexeddb/IDBTransaction.h:
41668         (WebCore):
41669
41670 2012-10-18  Peter Kasting  <pkasting@google.com>
41671
41672         [Skia] Set m_hasAlpha correctly in ImageFrame::copyBitmapData.
41673         https://bugs.webkit.org/show_bug.cgi?id=99781
41674
41675         Reviewed by Adam Barth.
41676
41677         No tests, since the actual effects of this bug are fickle and it's not
41678         clear how to extract and check particular subframes of an animated GIF.
41679
41680         * platform/image-decoders/skia/ImageDecoderSkia.cpp:
41681         (WebCore::ImageFrame::copyBitmapData):
41682
41683 2012-10-18  Pan Deng  <pan.deng@intel.com>
41684
41685         [Resource Timing]Implementation of resource timing buffer size restriction functionality
41686         https://bugs.webkit.org/show_bug.cgi?id=84885.
41687
41688         Reviewed by Tony Gentilcore.
41689
41690         http://www.w3.org/TR/2012/CR-resource-timing-20120522/
41691         This patch enable functionality of set buffer size(default is 150 as spec). When buffer is full, resourceTimingBufferFull event will be fired. Incoming entries will be dropped if no more space for them. 
41692
41693         Tests: http/tests/w3c/webperf/submission/Intel/resource-timing/test_resource_timing_buffer_full_when_populate_entries.html
41694                http/tests/w3c/webperf/submission/Intel/resource-timing/test_resource_timing_buffer_full_when_shrink_buffer_size.html
41695                http/tests/w3c/webperf/submission/Intel/resource-timing/test_resource_timing_buffer_size_restriction.html
41696                http/tests/w3c/webperf/submission/Intel/resource-timing/test_resource_timing_clear_resource_timing_functionality.html
41697                http/tests/w3c/webperf/submission/Intel/resource-timing/test_resource_timing_on_shrink_buffer_size.html
41698                http/tests/w3c/webperf/submission/Intel/resource-timing/test_resource_timing_store_and_clear_during_callback.html
41699
41700         * page/Performance.cpp:
41701         (WebCore):
41702         (WebCore::Performance::Performance):
41703         (WebCore::Performance::webkitSetResourceTimingBufferSize):
41704         (WebCore::Performance::addResourceTiming):
41705         (WebCore::Performance::isResourceTimingBufferFull):
41706         * page/Performance.h:
41707         (Performance):
41708
41709 2012-10-18  Ryosuke Niwa  <rniwa@webkit.org>
41710
41711         REGRESSION(r130411): Copying & pasting the first line of text can move caret to the end of text area
41712         https://bugs.webkit.org/show_bug.cgi?id=99663
41713
41714         Reviewed by Enrica Casucci and Levi Weintraub.
41715
41716         The bug was caused by positionOnlyToBeUpdated's offset not being shifted correctly in
41717         ReplaceSelectionCommand::mergeTextNodesAroundPosition. Suppose we have text nodes t1 and t2 and
41718         positionOnlyToBeUpdated had offset k in t2. When t2 is merged into t1, positionOnlyToBeUpdated should be
41719         moved to (t1, n + k) where n is the ORIGINAL length of t1 before t2 is merged. But we were using
41720         the length after t2 is merged.
41721
41722         Fixed the bug by saving the original length of t1 and using that in the offset adjustment.
41723         Also use the right offset.
41724
41725         Test: editing/pasteboard/copy-paste-first-line-in-textarea.html
41726
41727         * editing/ReplaceSelectionCommand.cpp:
41728         (WebCore::ReplaceSelectionCommand::mergeTextNodesAroundPosition):
41729
41730 2012-10-18  Claudio Saavedra  <csaavedra@igalia.com>
41731
41732         [GTK] Invalid read from WebKit::DOMObjectCache::clearByFrame
41733         https://bugs.webkit.org/show_bug.cgi?id=82882
41734
41735         Reviewed by Xan Lopez.
41736
41737         Based on a patch by Milan Crha <mcrha@redhat.com>
41738
41739         Prevent an invalid access to a pointer while clearing the DOM
41740         object cache.
41741         * bindings/gobject/DOMObjectCache.cpp:
41742         (WebKit::DOMObjectCache::clearByFrame): Prevent an invalid access.
41743
41744 2012-10-18  Sheriff Bot  <webkit.review.bot@gmail.com>
41745
41746         Unreviewed, rolling out r131810.
41747         http://trac.webkit.org/changeset/131810
41748         https://bugs.webkit.org/show_bug.cgi?id=99762
41749
41750         Broke linux debug webkit_unit_tests (Requested by
41751         danakj|gardening on #webkit).
41752
41753         * WebCore.gypi:
41754         * platform/graphics/ImageSource.cpp:
41755         (WebCore::ImageSource::setData):
41756         * platform/graphics/ImageSource.h:
41757         (WebCore):
41758         (ImageSource):
41759         * platform/graphics/chromium/DeferredImageDecoder.cpp: Removed.
41760         * platform/graphics/chromium/DeferredImageDecoder.h: Removed.
41761         * platform/graphics/chromium/ImageDecodingStore.cpp: Removed.
41762         * platform/graphics/chromium/ImageDecodingStore.h: Removed.
41763         * platform/graphics/chromium/ImageFrameGenerator.cpp: Removed.
41764         * platform/graphics/chromium/ImageFrameGenerator.h: Removed.
41765         * platform/graphics/chromium/LazyDecodingPixelRef.cpp: Removed.
41766         * platform/graphics/chromium/LazyDecodingPixelRef.h: Removed.
41767         * platform/graphics/chromium/ScaledImageFragment.cpp: Removed.
41768         * platform/graphics/chromium/ScaledImageFragment.h: Removed.
41769         * platform/graphics/skia/NativeImageSkia.cpp:
41770         (WebCore::NativeImageSkia::resizedBitmap):
41771         * platform/image-decoders/ImageDecoder.h:
41772         (ImageFrame):
41773
41774 2012-10-18  Tommy Widenflycht  <tommyw@google.com>
41775
41776         MediaStream API: Do some cleanup in the chromium WebKit API
41777         https://bugs.webkit.org/show_bug.cgi?id=99713
41778
41779         Reviewed by Adam Barth.
41780
41781         Removing the deprecated version of WebMediaStreamDescriptor::initialize.
41782
41783         No testing needed since only an unused function is removed.
41784
41785         * platform/chromium/support/WebMediaStreamDescriptor.cpp:
41786
41787 2012-10-18  Alpha Lam  <hclam@chromium.org>
41788
41789         [chromium] Implement deferred image decoding
41790         https://bugs.webkit.org/show_bug.cgi?id=94240
41791
41792         Reviewed by Stephen White.
41793
41794         Objectives:
41795
41796         To record image decoding operations during painting and to defer
41797         decoding operations until rasterization.
41798
41799         Rationale:
41800
41801         This is a key feature that enables impl-side painting which requires
41802         fast recording of drawing operations. The existing decode-on-draw
41803         restricts that recording has to block on expensive decoding operations.
41804         This change allows recording of image decoding operations during paint
41805         time.
41806
41807         Design:
41808
41809         Image decoding happens when a BitmapImage is drawn into a
41810         GraphicsContext. When per-tile painting is enabled GraphicsContext
41811         is backed by SkCanvas in recording mode. This SkCanvas records drawing
41812         and image decoding operations to minimize recording time.
41813
41814         An image decoding operation is recorded as a SkPixelRef object
41815         implemented by LazyDecodingPixelRef. This object references raw encoded
41816         data, regions to be decoded and scaling information.
41817
41818         When used in conjunction with per-tile painting this feature defers
41819         image decoding until the SkCanvas referencing the image is rasterized.
41820
41821         Both recording and rasterization happen on the main thread.
41822
41823         Performance Impact:
41824
41825         This feature is enabled by WebKit::setDeferredImageDecodingEnabled()
41826         and does not have an impact when disabled.
41827
41828         This feature is disabled by default.
41829
41830         Upcoming Changes:
41831
41832         1. Implement a full-featured image cache in ImageDecodingStore.
41833         2. Allow rasterization and decoding on impl thread.
41834
41835         Classes Involved:
41836
41837         BitmapImage
41838
41839         BitmapImage is the entry point for deferred image decoding. When
41840         drawing a BitmapImage into a GraphicsContext it makes a request to
41841         create a NativeImageSkia. We substitute the content in NativeImageSkia
41842         such that it is lazily decoded.
41843
41844         DeferredImageDecoder
41845
41846         This is the platform implementation of a image decoder for Chromium.
41847         This is a bridge layer that either delegates calls to the actual
41848         ImageDecoder or create a lazily-decoded SkBitmap and delegates calls
41849         to ImageDecodingStore.
41850
41851         ImageDecodingStore
41852
41853         This object manages all encoded images. It keeps track of encoded
41854         data and the corresponding ImageDecoder for doing actual decoding. It
41855         is also responsible for generating lazily decoded SkBitmaps. This
41856         SkBitmap contains a LazyDecodingPixelRef object which references to an
41857         image entry in ImageDecodingStore.
41858
41859         ScaledImageFragment
41860
41861         A container for a scaled image fragment. In addition to bitmap pixels
41862         it contains information about the ID of the image, scale and clipping.
41863
41864         ImageFrameGenerator
41865
41866         This object is responsible for generating decoded pixels. It is also
41867         a container for encoded image data and corresponding image decoder.
41868
41869         LazyDecodingPixelRef
41870
41871         This object is embedded in a SkBitmap to enable lazy decoding. When
41872         SkBitmap needs to access pixels LazyDecodingPixelRef is locked. It
41873         contains information to locate an image and scaling info, these
41874         information is submitted to ImageDecodingStore to access actual pixels.
41875
41876         Layout tests. There are about 80 tests in this virtual test suite
41877         running this feature in this directory:
41878
41879         platform/chromium/virtual/deferred/fast/images
41880
41881         Unit tests. Added DeferredImageDecoderTest to verify deferred
41882         image decoding behavior.
41883
41884         * WebCore.gypi:
41885         * platform/graphics/ImageSource.cpp:
41886         (WebCore::ImageSource::setData):
41887         * platform/graphics/ImageSource.h:
41888         (WebCore):
41889         (ImageSource):
41890         * platform/graphics/chromium/DeferredImageDecoder.cpp: Added.
41891         (WebCore):
41892         (WebCore::DeferredImageDecoder::DeferredImageDecoder):
41893         (WebCore::DeferredImageDecoder::~DeferredImageDecoder):
41894         (WebCore::DeferredImageDecoder::create):
41895         (WebCore::DeferredImageDecoder::createForTesting):
41896         (WebCore::DeferredImageDecoder::filenameExtension):
41897         (WebCore::DeferredImageDecoder::frameBufferAtIndex):
41898         (WebCore::DeferredImageDecoder::setData):
41899         (WebCore::DeferredImageDecoder::isSizeAvailable):
41900         (WebCore::DeferredImageDecoder::size):
41901         (WebCore::DeferredImageDecoder::frameSizeAtIndex):
41902         (WebCore::DeferredImageDecoder::frameCount):
41903         (WebCore::DeferredImageDecoder::repetitionCount):
41904         (WebCore::DeferredImageDecoder::clearFrameBufferCache):
41905         (WebCore::DeferredImageDecoder::frameHasAlphaAtIndex):
41906         (WebCore::DeferredImageDecoder::frameBytesAtIndex):
41907         * platform/graphics/chromium/DeferredImageDecoder.h: Added.
41908         (WebCore):
41909         (DeferredImageDecoder):
41910         * platform/graphics/chromium/ImageDecodingStore.cpp: Added.
41911         (WebCore::ImageDecodingStore::ImageDecodingStore):
41912         (WebCore):
41913         (WebCore::ImageDecodingStore::~ImageDecodingStore):
41914         (WebCore::ImageDecodingStore::instanceOnMainThread):
41915         (WebCore::ImageDecodingStore::initializeOnMainThread):
41916         (WebCore::ImageDecodingStore::shutdown):
41917         (WebCore::ImageDecodingStore::isLazyDecoded):
41918         (WebCore::ImageDecodingStore::createLazyDecodedSkBitmap):
41919         (WebCore::ImageDecodingStore::resizeLazyDecodedSkBitmap):
41920         (WebCore::ImageDecodingStore::setData):
41921         (WebCore::ImageDecodingStore::lockPixels):
41922         (WebCore::ImageDecodingStore::unlockPixels):
41923         (WebCore::ImageDecodingStore::frameGeneratorBeingDestroyed):
41924         (WebCore::ImageDecodingStore::calledOnValidThread):
41925         (WebCore::ImageDecodingStore::lookupFrameCache):
41926         (WebCore::ImageDecodingStore::deleteFrameCache):
41927         * platform/graphics/chromium/ImageDecodingStore.h: Added.
41928         (WebCore):
41929         (ImageDecodingStore):
41930         (WebCore::ImageDecodingStore::create):
41931         * platform/graphics/chromium/ScaledImageFragment.cpp: Added.
41932         (WebCore):
41933         (WebCore::ScaledImageFragment::~ScaledImageFragment):
41934         (WebCore::ScaledImageFragment::ScaledImageFragment):
41935         (WebCore::ScaledImageFragment::isEqual):
41936         * platform/graphics/chromium/ScaledImageFragment.h: Added.
41937         (WebCore):
41938         (ScaledImageFragment):
41939         (WebCore::ScaledImageFragment::create):
41940         (WebCore::ScaledImageFragment::bitmap):
41941         (WebCore::ScaledImageFragment::isComplete):
41942         * platform/graphics/chromium/ImageFrameGenerator.cpp: Added.
41943         (WebCore):
41944         (WebCore::ImageFrameGenerator::ImageFrameGenerator):
41945         (WebCore::ImageFrameGenerator::~ImageFrameGenerator):
41946         (WebCore::ImageFrameGenerator::decoder):
41947         (WebCore::ImageFrameGenerator::setData):
41948         * platform/graphics/chromium/ImageFrameGenerator.h: Added.
41949         (WebCore):
41950         (ImageFrameGenerator):
41951         (WebCore::ImageFrameGenerator::create):
41952         (WebCore::ImageFrameGenerator::size):
41953         (WebCore::ImageFrameGenerator::imageId):
41954         * platform/graphics/chromium/LazyDecodingPixelRef.cpp: Added.
41955         (WebCore):
41956         (WebCore::LazyDecodingPixelRef::LazyDecodingPixelRef):
41957         (WebCore::LazyDecodingPixelRef::~LazyDecodingPixelRef):
41958         (WebCore::LazyDecodingPixelRef::isScaled):
41959         (WebCore::LazyDecodingPixelRef::isClipped):
41960         (WebCore::LazyDecodingPixelRef::onLockPixels):
41961         (WebCore::LazyDecodingPixelRef::onUnlockPixels):
41962         (WebCore::LazyDecodingPixelRef::onLockPixelsAreWritable):
41963         * platform/graphics/chromium/LazyDecodingPixelRef.h: Added.
41964         (WebCore):
41965         (LazyDecodingPixelRef):
41966         (WebCore::LazyDecodingPixelRef::frameGenerator):
41967         * platform/graphics/skia/NativeImageSkia.cpp:
41968         (WebCore::NativeImageSkia::resizedBitmap):
41969         * platform/image-decoders/ImageDecoder.h:
41970         (ImageFrame):
41971         (WebCore::ImageFrame::setSkBitmap):
41972         (WebCore::ImageFrame::getSkBitmap):
41973
41974 2012-10-18  Yael Aharon  <yael.aharon@intel.com>
41975
41976         [EFL] GraphicsContext3D::m_renderStyle is not initialized
41977         https://bugs.webkit.org/show_bug.cgi?id=99721
41978
41979         Reviewed by Antonio Gomes.
41980
41981         Initialize GraphicsContext3D::m_renderStyle.
41982
41983         No new tests, no new functionality.
41984
41985         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
41986         (WebCore::GraphicsContext3D::GraphicsContext3D):
41987
41988 2012-10-18  Max Vujovic  <mvujovic@adobe.com>
41989
41990         [CSS Shaders] Validate types of built-in vertex attributes
41991         https://bugs.webkit.org/show_bug.cgi?id=98972
41992
41993         Reviewed by Dean Jackson.
41994
41995         Reject custom filters in which the author defined built-in attributes with the wrong type.
41996         For example, the GLSL declaration "attribute float a_position" is incorrect because
41997         a_position should be a vec4, not a float.
41998
41999         Test: css3/filters/custom/invalid-custom-filter-attribute-types.html
42000
42001         * platform/graphics/ANGLEWebKitBridge.h:
42002         (WebCore::ANGLEShaderSymbol::isSampler):
42003             Add const qualifier to isSampler method.
42004         * platform/graphics/filters/CustomFilterValidatedProgram.cpp:
42005         (WebCore):
42006         (WebCore::builtInAttributeNameToTypeMap):
42007             New file static function. Returns a map of the CSS Custom Filters built-in attribute
42008             names and their expected types.
42009         (WebCore::validateSymbols):
42010             New file static function. Loop through all of the symbols. Reject the shader if we find
42011             a built-in attribute defined with the wrong type.
42012         (WebCore::CustomFilterValidatedProgram::CustomFilterValidatedProgram):
42013             Call the new validateSymbols function. If it returns false, exit the constructor early,
42014             which rejects the program.
42015             Move the loop that checks if any uniform is a sampler into the the validateSymbols
42016             function.
42017
42018 2012-10-18  Mike Reed  <reed@google.com>
42019
42020         Handle if we fail to allocate nonPlatformCanvas in ImageBuffer constructor
42021         https://bugs.webkit.org/show_bug.cgi?id=99752
42022
42023         Reviewed by Stephen White.
42024
42025         Current code does not check if we were able to allocate the pixels, but still returns the canvas.
42026         However, the caller explicitly is checking for null on failure, so it will continue (and possibly
42027         crash later on).
42028         This change brings the nonPlatformCanvas behavior inline with createAcceleratedCanvas and
42029         TryCreateBitmapCanvas, both of which are also called by ImageBuffer's constructor.
42030
42031         No new tests. Existing tests exercise ImageBuffer constructor.
42032
42033         * platform/graphics/skia/ImageBufferSkia.cpp:
42034         (WebCore::createNonPlatformCanvas):
42035
42036 2012-10-18  Beth Dakin  <bdakin@apple.com>
42037
42038         https://bugs.webkit.org/show_bug.cgi?id=99668
42039         REGRESSION: Crash in 
42040         WebCore::ScrollingStateScrollingNode::setNonFastScrollableRegion
42041         -and corresponding-
42042         <rdar://problem/12491901>
42043
42044         Reviewed by Simon Fraser.
42045
42046         http://trac.webkit.org/changeset/130783 changed the lifetime of the 
42047         ScrollingStateTree's rootStateNode. Before that patch, the root state 
42048         node was never destroyed. It was just constantly re-used for 
42049         different RenderLayerBackings. This crash is just one of a few bugs 
42050         that has occurred because of that change. I have fixed the other bugs 
42051         individually, but I think that long-term, it is the safest solution 
42052         to go back to the original ownership model.
42053
42054         So this patch ensures that the state tree will always have a root 
42055         state node. Instead of destroying and re-creating the root node when 
42056         it's scroll ID changes, we just update the ID.
42057
42058         attachToStateTree() now takes an additional ID representing the ID of 
42059         the parent node.
42060         * page/scrolling/ScrollingCoordinator.h:
42061         (WebCore::ScrollingCoordinator::attachToStateTree):
42062
42063         Add a way to set the scrolling node ID.
42064         * page/scrolling/ScrollingStateNode.h:
42065         (WebCore::ScrollingStateNode::setScrollingNodeID):
42066
42067         This code that provided a way to mark all properties as having 
42068         changed was added in http://trac.webkit.org/changeset/130989 as a way 
42069         to ensure we would re-set ScrollingThread's nodes when we destroyed 
42070         and re-created the rootStateNode. Now that we are no longer 
42071         destroying and re-creating the rootStateNode, this code is no longer 
42072         necessary.
42073         * page/scrolling/ScrollingStateScrollingNode.cpp:
42074         * page/scrolling/ScrollingStateScrollingNode.h:
42075
42076         create m_rootStateNode right in the ScrollingStateTree's constructor.
42077         * page/scrolling/ScrollingStateTree.cpp:
42078         (WebCore::ScrollingStateTree::ScrollingStateTree):
42079
42080         Don't let removeNode() destroy m_rootStateNode.
42081         (WebCore::ScrollingStateTree::removeNode):
42082
42083         Also a part of r130989 that is no longer needed.
42084         (WebCore::ScrollingStateTree::rootLayerDidChange():
42085         * page/scrolling/ScrollingStateTree.h:
42086         (WebCore::ScrollingStateTree::rootStateNode):
42087         (ScrollingStateTree):
42088         (WebCore::ScrollingStateTree::setRootStateNode):
42089
42090         attachToStateTree() now takes an additional ID representing the ID of 
42091         the parent node.
42092         * page/scrolling/mac/ScrollingCoordinatorMac.h:
42093         (ScrollingCoordinatorMac):
42094
42095         We no longer need ScrollingStateTree::rootLayerDidChange()
42096         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
42097         (WebCore::ScrollingCoordinatorMac::frameViewRootLayerDidChange):
42098
42099         Do not destroy and re-create the state node. Just update its ID. When 
42100         we support child nodes soon, we will create them in this function.
42101         (WebCore::ScrollingCoordinatorMac::attachToStateTree):
42102
42103         No need to null-check the rootStateNode.
42104         (WebCore::ScrollingCoordinatorMac::clearStateTree):
42105
42106         Send 0 as the parent node ID to attachToStateTree() to represent the 
42107         root node.
42108         (WebCore::ScrollingCoordinatorMac::ensureRootStateNodeForFrameView):
42109         * rendering/RenderLayerBacking.cpp:
42110
42111         RenderLayerBacking::attachToScrollingCoordinator() now takes a parent 
42112         layer.
42113         (WebCore::RenderLayerBacking::attachToScrollingCoordinator):
42114         * rendering/RenderLayerBacking.h:
42115         (RenderLayerBacking):
42116
42117         Since this is the root, send 0 to represent the parent layer.
42118         * rendering/RenderLayerCompositor.cpp:
42119         (WebCore::RenderLayerCompositor::updateBacking):
42120
42121 2012-10-18  Yael Aharon  <yael.aharon@intel.com>
42122
42123         [EFL] GraphicsContext3D::m_renderStyle is not initialized
42124         https://bugs.webkit.org/show_bug.cgi?id=99721
42125
42126         Reviewed by Antonio Gomes.
42127
42128         Initialize GraphicsContext3D::m_renderStyle.
42129
42130         No new tests, no new functionality.
42131
42132         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
42133         (WebCore::GraphicsContext3D::GraphicsContext3D):
42134
42135 2012-10-18  Brian White  <bcwhite@chromium.org>
42136
42137         WebKit Doesn't Recognize Content-Language HTTP Header
42138         https://bugs.webkit.org/show_bug.cgi?id=97929
42139
42140         Reviewed by Alexey Proskuryakov.
42141
42142         The HTTP "Content-Language" header may be present and include the
42143         language of the page contents (as opposed to an embedded meta tag).
42144
42145         * loader/FrameLoader.cpp:
42146         (WebCore::FrameLoader::didBeginDocument):
42147
42148 2012-10-18  Jer Noble  <jer.noble@apple.com>
42149
42150         Crash in WebCore::Document::webkitExitFullscreen + 618
42151         https://bugs.webkit.org/show_bug.cgi?id=99496
42152
42153         Reviewed by Eric Carlson.
42154
42155         Prospective fix for null-dereference crash in Document::webkitExitFullscreen().
42156
42157         * dom/Document.cpp:
42158         (WebCore::Document::webkitExitFullscreen): Null check page() before calling page()->chrome.
42159
42160 2012-10-18  Pablo Flouret  <pablof@motorola.com>
42161
42162         Implement css3-conditional's @supports rule
42163         https://bugs.webkit.org/show_bug.cgi?id=86146
42164
42165         Reviewed by Antti Koivisto.
42166
42167         The "@supports" rule is a conditional group rule whose condition tests
42168         whether the user agent supports CSS property:value pairs.
42169
42170         http://dev.w3.org/csswg/css3-conditional/#at-supports
42171
42172         Test: css3/supports.html
42173
42174         * Configurations/FeatureDefines.xcconfig:
42175         * GNUmakefile.am:
42176         * GNUmakefile.features.am:
42177             Add an ENABLE_CSS3_CONDITIONAL_RULES flag.
42178
42179         * css/CSSGrammar.y.in:
42180         * css/CSSParser.cpp:
42181         (WebCore):
42182         (WebCore::CSSParser::detectSupportsToken): Tries to find 'and', 'not' and 'or' tokens.
42183         (WebCore::CSSParser::detectAtToken): Enter SupportsMode if @supports is detected.
42184         (WebCore::CSSParser::realLex): Try to detect supports tokens when in SupportsMode.
42185         * css/CSSParser.h: Added new SupportsMode parsing mode.
42186         (CSSParser):
42187
42188 2012-10-18  Marja Hölttä  <marja@chromium.org>
42189
42190         Fix: CachedResourceLoader::requestSVGDocument was passing an URL as charset
42191         https://bugs.webkit.org/show_bug.cgi?id=99730
42192
42193         Reviewed by Jochen Eisinger.
42194
42195         * loader/cache/CachedResourceLoader.cpp:
42196         (WebCore::CachedResourceLoader::requestSVGDocument):
42197
42198 2012-10-18  Jer Noble  <jer.noble@apple.com>
42199
42200         Fullscreen movie controls behave incorrectly when clicked (and dragged)
42201         https://bugs.webkit.org/show_bug.cgi?id=99610
42202
42203         Reviewed by Eric Carlson.
42204
42205         Do not reset the relative drag position to 0,0 at the beginning of every drag.  Instead,
42206         store the cumulative drag offset and accumulate during each additional drag.
42207
42208         No new tests; modified the fullscreen/video-controls-drag.html test.
42209
42210         * html/shadow/MediaControlElements.cpp:
42211         (WebCore::MediaControlPanelElement::startDrag): Reset m_lastDragEventLocation.
42212         (WebCore::MediaControlPanelElement::continueDrag): Accumulate drag distance in m_cumulativeDragOffset.
42213         (WebCore::MediaControlPanelElement::resetPosition): Reset m_cumulativeDragOffset.
42214         * html/shadow/MediaControlElements.h:
42215
42216 2012-10-18  Brandon Jones  <bajones@google.com>
42217
42218         Implement OES_element_index_uint / WEBKIT_OES_element_index_uint
42219         https://bugs.webkit.org/show_bug.cgi?id=97400
42220
42221         Reviewed by Kenneth Russell.
42222
42223         Implemented OES_element_index_uint WebGL extension
42224
42225         Test: fast/canvas/webgl/oes-element-index-uint.html
42226
42227         * CMakeLists.txt:
42228         * DerivedSources.make:
42229         * DerivedSources.pri:
42230         * GNUmakefile.list.am:
42231         * Target.pri:
42232         * WebCore.gypi:
42233         * WebCore.xcodeproj/project.pbxproj:
42234         * bindings/js/JSWebGLRenderingContextCustom.cpp:
42235         (WebCore::toJS):
42236         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
42237         (WebCore::toV8Object):
42238         * html/canvas/OESElementIndexUint.cpp: Copied from Source/WebCore/html/canvas/WebGLExtension.h.
42239         (WebCore):
42240         (WebCore::OESElementIndexUint::OESElementIndexUint):
42241         (WebCore::OESElementIndexUint::~OESElementIndexUint):
42242         (WebCore::OESElementIndexUint::getName):
42243         (WebCore::OESElementIndexUint::create):
42244         * html/canvas/OESElementIndexUint.h: Copied from Source/WebCore/html/canvas/WebGLExtension.h.
42245         (WebCore):
42246         (OESElementIndexUint):
42247         * html/canvas/OESElementIndexUint.idl: Copied from Source/WebCore/html/canvas/WebGLExtension.h.
42248         * html/canvas/WebGLExtension.h:
42249         * html/canvas/WebGLRenderingContext.cpp:
42250         (WebCore):
42251         (WebCore::WebGLRenderingContext::validateElementArraySize):
42252         (WebCore::WebGLRenderingContext::validateIndexArrayConservative):
42253         (WebCore::WebGLRenderingContext::validateIndexArrayPrecise):
42254         (WebCore::WebGLRenderingContext::validateRenderingState):
42255         (WebCore::WebGLRenderingContext::drawElements):
42256         (WebCore::WebGLRenderingContext::getExtension):
42257         (WebCore::WebGLRenderingContext::getSupportedExtensions):
42258         * html/canvas/WebGLRenderingContext.h:
42259         (WebCore):
42260         (WebGLRenderingContext):
42261         * platform/graphics/Extensions3D.h:
42262         (Extensions3D):
42263         * platform/graphics/opengl/Extensions3DOpenGL.cpp:
42264         (WebCore::Extensions3DOpenGL::supportsExtension):
42265
42266 2012-10-18  Jer Noble  <jer.noble@apple.com>
42267
42268         Add diagnostic logging to track per-page media engine usage.
42269         https://bugs.webkit.org/show_bug.cgi?id=99615
42270         <rdar://problem/12476473>
42271
42272         Reviewed by Eric Carlson.
42273
42274         Add diagnostic logging triggered only once-per-page and once-per-page-per-engine.
42275
42276         * html/HTMLMediaElement.cpp:
42277         (WebCore::logMediaLoadRequest): Encapsulate diagnostic logging into single static method.
42278         (WebCore::HTMLMediaElement::mediaLoadingFailed): Call logMediaLoadRequest.
42279         (WebCore::HTMLMediaElement::setReadyState): Ditto.
42280         * loader/FrameLoader.cpp:
42281         (WebCore::FrameLoader::dispatchDidCommitLoad): Reset the set of seen media engines.
42282
42283         Add new methods to Page to track per-page media engine diagnostic info, similar to plugin diagnostic info.
42284         * page/Page.cpp:
42285         (WebCore::Page::hasSeenAnyMediaEngine):
42286         (WebCore::Page::hasSeenMediaEngine):
42287         (WebCore::Page::sawMediaEngine):
42288         (WebCore::Page::resetSeenMediaEngines):
42289         * page/Page.h:
42290
42291         Add new static logging key definitions:
42292         * page/DiagnosticLoggingKeys.cpp:
42293         (WebCore::DiagnosticLoggingKeys::pageContainsMediaEngineKey):
42294         (WebCore::DiagnosticLoggingKeys::pageContainsAtLeastOneMediaEngineKey):
42295         * page/DiagnosticLoggingKeys.h:
42296
42297 2012-10-18  Michael Saboff  <msaboff@apple.com>
42298
42299         Add 8-bit path to RenderBlock::handleTrailingSpaces()
42300         https://bugs.webkit.org/show_bug.cgi?id=99731
42301
42302         Reviewed by Dan Bernstein.
42303
42304         Factored out and added findFirstTrailingSpace() templated helper function that is called with the 
42305         approriate character pointer type.
42306
42307         No tests needed, change covered by existing tests.
42308
42309         * rendering/RenderBlockLineLayout.cpp:
42310         (WebCore::findFirstTrailingSpace):
42311         (WebCore::RenderBlock::handleTrailingSpaces):
42312
42313 2012-10-18  Hans Muller  <hmuller@adobe.com>
42314
42315         [CSS Exclusions] Add ExclusionShape::shapeBoundingBox() method
42316         https://bugs.webkit.org/show_bug.cgi?id=99216
42317
42318         Reviewed by Dirk Schulze.
42319
42320         Added a FloatRect::extend() method which simplifies writing loops that
42321         accumulate the bounding box for a sequence of FloatPoints. The new method
42322         is used by ExclusionPolygon to initialize the shape's logical and physical
42323         bounding boxes. This a clean-up, not a change in functionality. It's already
42324         covered by the existing fast/exclusions LayoutTests.
42325
42326         * platform/graphics/FloatRect.cpp:
42327         (WebCore::FloatRect::extend): Extend the FloatRect's bounds to include a FloatPoint.
42328         (WebCore):
42329         * platform/graphics/FloatRect.h:
42330         (FloatRect): Added extend() method.
42331         * rendering/ExclusionPolygon.cpp:
42332         (WebCore::ExclusionPolygon::ExclusionPolygon): Use FloatRect::extend() to compute the polygon's internal bounding box.
42333         * rendering/ExclusionShape.cpp:
42334         (WebCore::ExclusionShape::createExclusionShape): Use FloatRect::extend() to compute the polygon's physical bounding box.
42335         * rendering/ExclusionShape.h:
42336         (WebCore::ExclusionShape::shapeBoundingBox): Return the shape's bounding box in physical coordinates.
42337         (ExclusionShape):
42338
42339 2012-10-18  Hans Muller  <hmuller@adobe.com>
42340
42341         [CSS Exclusions] Handle special case "empty" shapes
42342         https://bugs.webkit.org/show_bug.cgi?id=99342
42343
42344         Reviewed by Dirk Schulze.
42345
42346         Provide expclit coverage of the simple "empty" shape-inside shapes.
42347         Shapes will be considered "empty" in the sense that ExclusionShape::getIncludedIntervals()
42348         and ExclusionShape::getExcludedIntervals() will always return empty lists of intervals.
42349         This patch covers rectangles of zero width or height, circles with 0 radius, ellipses
42350         with 0 radiusX or radiusY, polygons with less than 3 vertices.
42351
42352         Test: fast/exclusions/shape-inside/shape-inside-empty.html
42353
42354         * rendering/ExclusionPolygon.cpp:
42355         (WebCore::ExclusionPolygon::ExclusionPolygon): Initialize the m_empty flag.
42356         (WebCore::ExclusionPolygon::getExcludedIntervals): Added short-circuit return when the polygon is empty.
42357         (WebCore::ExclusionPolygon::getIncludedIntervals): Added short-circuit return when the polygon is empty.
42358         * rendering/ExclusionPolygon.h: Added the isEmpty() method.
42359         * rendering/ExclusionRectangle.cpp:
42360         (WebCore::ExclusionRectangle::getExcludedIntervals): Added short-circuit return when the rectangle is empty.
42361         (WebCore::ExclusionRectangle::getIncludedIntervals): Added short-circuit return when the rectangle is empty.
42362         * rendering/ExclusionRectangle.h: Added the isEmpty() method.
42363         * rendering/ExclusionShape.h: Added a virtual isEmpty() ExclusionShape method.
42364         (ExclusionShape):
42365
42366 2012-10-18  Takashi Sakamoto  <tasak@google.com>
42367
42368         REGRESSION(r131464): Null-pointer crash in StyleResolver::styleForElement
42369         https://bugs.webkit.org/show_bug.cgi?id=99587
42370
42371         Reviewed by Dimitri Glazkov.
42372
42373         Since contents in datalist are not shown, summary in datalist is not
42374         shown either. So the summary has no render style. On the other hand,
42375         the summary is implemented by shadow DOM and it has some insertion
42376         point. Its child, e.g. title in the below test, is distributed.
42377         To solve the child's user-modify, looking at shadow host(=summary)'s
42378         style causes null-pointer crash.
42379
42380         Test: fast/dom/shadow/user-modify-in-datalist-crash.html
42381
42382         * css/StyleResolver.cpp:
42383         (WebCore::StyleResolver::styleForElement):
42384         Added a code to check whether the shadow host has any style or not.
42385
42386 2012-10-17  Philippe Normand  <pnormand@igalia.com>
42387
42388         [GTK] AudioBusGtk sometimes fails to load the HRTF database
42389         https://bugs.webkit.org/show_bug.cgi?id=99601
42390
42391         Reviewed by Martin Robinson.
42392
42393         AudioBusGtk now first lookup for the uninstalled resource files,
42394         if the AUDIO_RESOURCES_PATH environment variable is
42395         set. Additionally the audio file reader is now better dealing with
42396         errors, returning an empty AudioBus in such cases and issuing
42397         warnings on the console output. The cleanup of some member
42398         variables was also moved to the destructor.
42399
42400         * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:
42401         (AudioFileReader):
42402         (WebCore::AudioFileReader::AudioFileReader):
42403         (WebCore::AudioFileReader::~AudioFileReader): Clear and free
42404         member variables. This was done in createBus before.
42405         (WebCore::AudioFileReader::handleMessage): Issue warnings in case
42406         of error and exit from the main loop so the pipeline is not
42407         forever stuck.
42408         (WebCore::AudioFileReader::createBus): Return an empty bus in case
42409         of error.
42410         * platform/audio/gtk/AudioBusGtk.cpp:
42411         (WebCore::AudioBus::loadPlatformResource): Load uninstalled
42412         resources first if AUDIO_RESOURCES_PATH is set.
42413
42414 2012-10-18  Pavel Feldman  <pfeldman@chromium.org>
42415
42416         Web Inspector: provisional change for merging "doced" state into the "dock side" enum.
42417         https://bugs.webkit.org/show_bug.cgi?id=99718
42418
42419         Reviewed by Vsevolod Vlasov.
42420
42421         Adds stub method that could be executed from the embedder.
42422
42423         * inspector/front-end/InspectorFrontendAPI.js:
42424         (InspectorFrontendAPI.setDockSide):
42425
42426 2012-10-18  Kent Tamura  <tkent@chromium.org>
42427
42428         Add Localizer::monthFormat and implementations
42429         https://bugs.webkit.org/show_bug.cgi?id=99704
42430
42431         Reviewed by Kentaro Hara.
42432
42433         Localizer::monthFormat will be used for constructing input[type=month] UI.
42434
42435         Tests: Add unit tests to Source/WebKit/chromium/tests/.
42436
42437         * platform/text/Localizer.h:
42438         (Localizer): Declare pure virtual monthFormat function.
42439
42440         * platform/text/LocaleNone.cpp:
42441         (LocaleNone): Declare monthFormat.
42442         (WebCore::LocaleNone::monthFormat):
42443         Added. Always reutrns an ISO-8601 format, "yyyy-MM"
42444
42445         * platform/text/LocaleICU.h:
42446         (LocaleICU): Declare monthFormat.
42447         * platform/text/LocaleICU.cpp:
42448         (WebCore::getFormatForSkeleton):
42449         A helper to get a format for the specified skeleton.
42450         The overflow-allocalte-try-again pattern is similar to
42451         LocaleICU::decimalSymbol and LocaleICU::decimalTextAttribute.
42452         (WebCore::LocaleICU::monthFormat):
42453         Added. Calls getFormatForSkeleton with "yyyyMMM".
42454
42455         * platform/text/mac/LocaleMac.h:
42456         (LocaleMac): Declare monthFormat.
42457         * platform/text/mac/LocaleMac.mm:
42458         (WebCore::LocaleMac::monthFormat):
42459         Added. Calls NSDateFormatter::dateFormatFromTemplate with "yyyyMMM".
42460
42461         * platform/text/LocaleWin.h:
42462         (LocaleWin): Declare monthFormat.
42463         * platform/text/LocaleWin.cpp:
42464         (WebCore::LocaleWin::monthFormat):
42465         Get a format by LOCALE_SYEARMONTH, and convert it to an LDML format.
42466
42467 2012-10-18  Pavel Feldman  <pfeldman@chromium.org>
42468
42469         Web Inspector: add X-WebKit-CSP header into inspector.html
42470         https://bugs.webkit.org/show_bug.cgi?id=99710
42471
42472         Reviewed by Vsevolod Vlasov.
42473
42474         A simple sanity measure.
42475
42476         * inspector/front-end/inspector.html:
42477
42478 2012-10-18  Huang Dongsung  <luxtella@company100.net>
42479
42480         [WK2] Add CustomFilterOperation serialization in ArgumentCoder.
42481         https://bugs.webkit.org/show_bug.cgi?id=98733
42482
42483         Reviewed by Noam Rosenthal.
42484
42485         Change CustomFilterOperation::parameters() to const function, because
42486         this method is a getter and a const instance needs to call this method.
42487
42488         No new tests because there is no change in behavior.
42489
42490         * platform/graphics/filters/CustomFilterOperation.h:
42491         (WebCore::CustomFilterOperation::parameters):
42492
42493 2012-10-18  Hayato Ito  <hayato@chromium.org>
42494
42495         treeScopeOfParent doesn't return the TreeScope of the parent
42496         https://bugs.webkit.org/show_bug.cgi?id=98207
42497
42498         Reviewed by Hajime Morita.
42499
42500         A minor clean up. Remove treeScopeOfParent() in Element.cpp.
42501
42502         No tests needed, this is just a clean up.
42503
42504         * dom/Element.cpp:
42505         (WebCore::Element::removedFrom):
42506
42507 2012-10-18  Alexander Pavlov  <apavlov@chromium.org>
42508
42509         Web Inspector: [Styles] Forcibly invoke property names suggestion box for empty prefix
42510         https://bugs.webkit.org/show_bug.cgi?id=99711
42511
42512         Reviewed by Vsevolod Vlasov.
42513
42514         Suggestions should be returned unconditionally for CSS property names, regardless of the prefix.
42515
42516         * inspector/front-end/CSSCompletions.js:
42517         (WebInspector.CSSCompletions):
42518         (WebInspector.CSSCompletions.requestCSSNameCompletions):
42519         (WebInspector.CSSCompletions.prototype._firstIndexOfPrefix):
42520         * inspector/front-end/CSSKeywordCompletions.js:
42521         (WebInspector.CSSKeywordCompletions.forProperty):
42522
42523 2012-10-18  Raphael Kubo da Costa  <raphael.kubo.da.costa@intel.com>
42524
42525         Unreviewed, do not make UseV8.cmake executable.
42526
42527         * UseV8.cmake: Removed property svn:executable.
42528
42529 2012-10-18  Tommy Widenflycht  <tommyw@google.com>
42530
42531         MediaStream API: Add better RTCPeerConnectionHandler creation logic
42532         https://bugs.webkit.org/show_bug.cgi?id=99308
42533
42534         Reviewed by Adam Barth.
42535
42536         This patch makes sure that if the RTCPeerConnectionHandler can't be fully initialized/created
42537         the RTCPeerConnection constructor throws an exception.
42538
42539         Not full testable, existing tests cover the normal case though.
42540
42541         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp:
42542         (WebCore::RTCPeerConnectionHandler::create):
42543         (WebCore::RTCPeerConnectionHandlerChromium::RTCPeerConnectionHandlerChromium):
42544         (WebCore::RTCPeerConnectionHandlerChromium::createWebHandler):
42545         (WebCore::RTCPeerConnectionHandlerChromium::initialize):
42546         (WebCore::RTCPeerConnectionHandlerChromium::createOffer):
42547         (WebCore::RTCPeerConnectionHandlerChromium::createAnswer):
42548         (WebCore::RTCPeerConnectionHandlerChromium::setLocalDescription):
42549         (WebCore::RTCPeerConnectionHandlerChromium::setRemoteDescription):
42550         (WebCore::RTCPeerConnectionHandlerChromium::updateIce):
42551         (WebCore::RTCPeerConnectionHandlerChromium::addIceCandidate):
42552         (WebCore::RTCPeerConnectionHandlerChromium::localDescription):
42553         (WebCore::RTCPeerConnectionHandlerChromium::remoteDescription):
42554         (WebCore::RTCPeerConnectionHandlerChromium::addStream):
42555         (WebCore::RTCPeerConnectionHandlerChromium::removeStream):
42556         (WebCore::RTCPeerConnectionHandlerChromium::getStats):
42557         (WebCore::RTCPeerConnectionHandlerChromium::openDataChannel):
42558         (WebCore::RTCPeerConnectionHandlerChromium::sendStringData):
42559         (WebCore::RTCPeerConnectionHandlerChromium::sendRawData):
42560         (WebCore::RTCPeerConnectionHandlerChromium::closeDataChannel):
42561         (WebCore::RTCPeerConnectionHandlerChromium::stop):
42562         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h:
42563         (RTCPeerConnectionHandlerChromium):
42564
42565 2012-10-19  Zeno Albisser  <zeno@webkit.org>
42566
42567         Temporarily disable use of QCocoaNativeInterface in GraphicsSurfaceMac.
42568         https://bugs.webkit.org/show_bug.cgi?id=99320
42569
42570         The current version of Qt5 deployed on the buildbots does not yet have
42571         an implementation for QCocoaNativeInterface::nativeResourceForContext().
42572         Therefore we disable this code path until Qt5/qtbase has been updated to
42573         a revision above Change-Id: Id00efc88a73d7df04a68c022f19d9d1c4f6d386b.
42574
42575         Once Qt5 has been updated, this patch must be reverted.
42576
42577         Reviewed by Noam Rosenthal.
42578
42579         * platform/graphics/surfaces/mac/GraphicsSurfaceMac.cpp:
42580         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
42581
42582 2012-10-18  Zeno Albisser  <zeno@webkit.org>
42583
42584         GraphicsSurface should not modify the current GL context.
42585         https://bugs.webkit.org/show_bug.cgi?id=99320
42586
42587         Instead of reusing the currently bound GL context for drawing
42588         the texture onto the GraphicsSurface, GraphicsSurface should
42589         create a new context that shares the texture names with a context
42590         provided by the caller.
42591         This way the OpenGL states are clearly separated and we do not
42592         risk interfeering with the currently bound GL context.
42593
42594         Reviewed by Noam Rosenthal.
42595
42596         * platform/graphics/qt/GraphicsContext3DQt.cpp:
42597         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
42598             When creating a GraphicsSurface pass the platform GL context
42599             as a parameter, so it can be used for sharing textures with.
42600         (WebCore::GraphicsContext3DPrivate::copyToGraphicsSurface):
42601             Pass the texture instead of the FBO. A Texture can be drawn
42602             directly or bound to another FBO, where a framebuffer
42603             always needs to be blit onto the surface.
42604         (WebCore::GraphicsContext3DPrivate::createGraphicsSurfaces):
42605             Pass the platform GL context as a parameter.
42606         * platform/graphics/surfaces/GraphicsSurface.cpp:
42607         (WebCore::GraphicsSurface::create):
42608         (WebCore::GraphicsSurface::copyFromTexture):
42609         * platform/graphics/surfaces/GraphicsSurface.h:
42610         (GraphicsSurface):
42611         * platform/graphics/surfaces/mac/GraphicsSurfaceMac.cpp:
42612         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
42613             Create a new GL context that shares the textures with the
42614             context provided by the caller.
42615         (WebCore::GraphicsSurfacePrivate::~GraphicsSurfacePrivate):
42616         (WebCore::GraphicsSurfacePrivate::makeCurrent):
42617             Add a convenience function to make the context that
42618             belongs to the surface current.
42619         (GraphicsSurfacePrivate):
42620         (WebCore::GraphicsSurfacePrivate::doneCurrent):
42621             Add a convenience function to make the previously
42622             bound context current again.
42623         (WebCore::GraphicsSurfacePrivate::copyFromTexture):
42624             Move blitting of the texture onto the surface
42625             into a separate function within GraphicsSurfacePrivate.
42626         (WebCore::GraphicsSurface::platformCopyFromTexture):
42627             Rename function platformCopyFromFramebuffer to
42628             platformCopyFromTexture, as we are now passing the texture only.
42629         (WebCore::GraphicsSurface::platformCreate):
42630         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
42631         (WebCore):
42632         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
42633         (WebCore::GraphicsSurfacePrivate::makeCurrent):
42634             Add a convenience function to make the context that
42635             belongs to the surface current.
42636         (GraphicsSurfacePrivate):
42637         (WebCore::GraphicsSurfacePrivate::doneCurrent):
42638             Add a convenience function to make the previously
42639         (WebCore::GraphicsSurfacePrivate::copyFromTexture):
42640             Move blitting of the texture onto the surface
42641             into a separate function within GraphicsSurfacePrivate.
42642         (WebCore::resolveGLMethods):
42643             Resolve additional GL methods necessary for this change.
42644         (WebCore::GraphicsSurface::platformCopyFromTexture):
42645             Rename function platformCopyFromFramebuffer to
42646             platformCopyFromTexture, as we are now passing the texture only.
42647         (WebCore::GraphicsSurface::platformCreate):
42648
42649 2012-10-18  Kent Tamura  <tkent@chromium.org>
42650
42651         Set min-width property instead of width property for date/time fields
42652         https://bugs.webkit.org/show_bug.cgi?id=99673
42653
42654         Reviewed by Hajime Morita.
42655
42656         A field can have a text wider than pre-computed width because of
42657         :first-letter property. So, we should set min-width, not width.
42658
42659         Tests: Covered by fast/forms/*-multiple-fields/*-multipe-fields-appearance-style.html
42660
42661         * html/shadow/DateTimeNumericFieldElement.cpp:
42662         (WebCore::DateTimeNumericFieldElement::customStyleForRenderer):
42663         Set min-width instead of width.
42664         * html/shadow/DateTimeSymbolicFieldElement.cpp:
42665         (WebCore::DateTimeSymbolicFieldElement::customStyleForRenderer): Ditto.
42666
42667 2012-10-18  MORITA Hajime  <morrita@google.com>
42668
42669         Assertion failure at TreeScopeAdopter::moveNodeToNewDocument()
42670         https://bugs.webkit.org/show_bug.cgi?id=99510
42671
42672         Reviewed by Kent Tamura.
42673
42674         Shadow DOM notification call didn't have checks for mutation detection.
42675         This change adds such checks.
42676
42677         Test: fast/forms/textarea/textarea-autofocus-removal-while-focusing-with-style.html
42678
42679         * dom/ContainerNodeAlgorithms.cpp:
42680         (WebCore::ChildNodeInsertionNotifier::notifyDescendantInsertedIntoDocument):
42681         (WebCore::ChildNodeRemovalNotifier::notifyDescendantRemovedFromDocument):
42682
42683 2012-10-17  Kentaro Hara  <haraken@chromium.org>
42684
42685         Unreviewed. Rebaselined run-bindings-tests.
42686
42687         * bindings/scripts/test/V8/V8Float64Array.h:
42688         (V8Float64Array):
42689         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
42690         (V8TestActiveDOMObject):
42691         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
42692         (V8TestCustomNamedGetter):
42693         * bindings/scripts/test/V8/V8TestEventConstructor.h:
42694         (V8TestEventConstructor):
42695         * bindings/scripts/test/V8/V8TestEventTarget.h:
42696         (V8TestEventTarget):
42697         * bindings/scripts/test/V8/V8TestException.h:
42698         (V8TestException):
42699         * bindings/scripts/test/V8/V8TestInterface.h:
42700         (V8TestInterface):
42701         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
42702         (V8TestMediaQueryListListener):
42703         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
42704         (V8TestNamedConstructor):
42705         * bindings/scripts/test/V8/V8TestNode.h:
42706         (V8TestNode):
42707         * bindings/scripts/test/V8/V8TestObj.h:
42708         (V8TestObj):
42709         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
42710         (V8TestSerializedScriptValueInterface):
42711
42712 2012-10-17  Mike West  <mkwst@chromium.org>
42713
42714         Move mixed content logic out of FrameLoader
42715         https://bugs.webkit.org/show_bug.cgi?id=45638
42716
42717         Reviewed by Eric Seidel.
42718
42719         This change moves checks for mixed content out of FrameLoader, and into
42720         a new MixedContentChecker object. It's a pretty straightforward
42721         refactoring with no change to the overall logic, and only minor changes
42722         to the code to reduce repetition.
42723
42724         The only substantive change is renaming the methods from 'checkIf*' to
42725         'can*' to reflect the value of the boolean they return.
42726
42727         The visible functionality shouldn't change; this change should be
42728         covered by existing tests in http/tests/security/mixedContent.
42729
42730         This patch is mostly a revitalization of Eric Sidel's original
42731         patch: https://bugs.webkit.org/attachment.cgi?id=67432&action=prettypatch
42732
42733         * CMakeLists.txt:
42734         * GNUmakefile.list.am:
42735         * Target.pri:
42736         * WebCore.gypi:
42737         * WebCore.vcproj/WebCore.vcproj:
42738         * WebCore.xcodeproj/project.pbxproj:
42739             Hey, look! A new file!
42740         * loader/FrameLoader.cpp:
42741         (WebCore::FrameLoader::FrameLoader):
42742         * loader/FrameLoader.h:
42743         (WebCore::FrameLoader::mixedContentChecker):
42744         (FrameLoader):
42745         * loader/MixedContentChecker.cpp: Added.
42746         (WebCore):
42747         (WebCore::MixedContentChecker::MixedContentChecker):
42748         (WebCore::MixedContentChecker::client):
42749         (WebCore::asUTF8):
42750         (WebCore::MixedContentChecker::isMixedContent):
42751         (WebCore::MixedContentChecker::canDisplayInsecureContent):
42752         (WebCore::MixedContentChecker::canRunInsecureContent):
42753         (WebCore::MixedContentChecker::logWarning):
42754         * loader/MixedContentChecker.h: Added.
42755         (WebCore):
42756         (MixedContentChecker):
42757             Migrate functionality from FrameLoader::checkIf* to
42758             MixedContentChecker::can*.
42759         * loader/MainResourceLoader.cpp:
42760         (WebCore::MainResourceLoader::willSendRequest):
42761         * loader/SubframeLoader.cpp:
42762         (WebCore::SubframeLoader::pluginIsLoadable):
42763         (WebCore::SubframeLoader::loadMediaPlayerProxyPlugin):
42764         * loader/cache/CachedResourceLoader.cpp:
42765         (WebCore::CachedResourceLoader::checkInsecureContent):
42766             Use the new method locations.
42767
42768 2012-10-17  Dan Bernstein  <mitz@apple.com>
42769
42770         REGRESSION (r95391): ComplexTextController is unnecessarily slow with characters with combining marks when the base character is not covered by any font
42771         https://bugs.webkit.org/show_bug.cgi?id=99654
42772
42773         Reviewed by Adele Peterson.
42774
42775         When the base character of a combining character sequence is not covered by any one of the
42776         available fonts, there is no point looking for a font that covers the entire sequence, nor
42777         to try to use a combination of fallback fonts for the entire sequence.
42778
42779         * platform/graphics/SimpleFontData.h:
42780         (WebCore::SimpleFontData::systemFallback): Moved ComplexTextController::systemFallbackFontData
42781         here and renamed it.
42782         * platform/graphics/mac/ComplexTextController.cpp:
42783         (WebCore::ComplexTextController::collectComplexTextRuns): This function used to use
42784         systemFallbackFontData() whenever Font::fontDataForCombiningCharacterSequence returned 0
42785         for a base character with combining marks, regardless of whether the base character was
42786         covered by any font. Changed it to preserve the return value of
42787         fontDataForCombiningCharacterSequence, which is now 0 only if the base charcater is not in
42788         any font, while systemFallbackFontData() is used to indicate that no single font in the
42789         fallback list covers all characters in the sequence, but the base character is in some font.
42790         * platform/graphics/mac/ComplexTextController.h:
42791         (ComplexTextController): Moved systemFallbackFontData from here to SimpleFontData.
42792         * platform/graphics/mac/ComplexTextControllerCoreText.mm:
42793         (WebCore::ComplexTextController::collectComplexTextRunsForCharacters): Updated for the above
42794         move.
42795         * platform/graphics/mac/FontComplexTextMac.cpp:
42796         (WebCore::Font::fontDataForCombiningCharacterSequence): Changed to return
42797         systemFallbackFontData() if no single font in the fallback list covers all characters in the
42798         sequence, while using 0 to signal the base character does not exist in any font.
42799
42800 2012-10-17  Dan Bernstein  <mitz@apple.com>
42801
42802         Try to fix the build after r131701.
42803
42804         * WebCore.exp.in:
42805
42806 2012-10-17  Hayato Ito  <hayato@chromium.org>
42807
42808         Content element does not expose distributedNodes property.
42809         https://bugs.webkit.org/show_bug.cgi?id=99232
42810
42811         Reviewed by Dimitri Glazkov.
42812
42813         Add getDistributedNodes() to HTMLContentElement's IDL, which returns a
42814         static NodeList whose node are distributed to the content element.
42815
42816         Test: fast/dom/shadow/content-element-distributed-nodes.html
42817
42818         * html/shadow/HTMLContentElement.idl:
42819         * html/shadow/InsertionPoint.cpp:
42820         (WebCore::InsertionPoint::getDistributedNodes):
42821         * html/shadow/InsertionPoint.h:
42822         (InsertionPoint):
42823         * testing/Internals.cpp:
42824         * testing/Internals.h:
42825         (Internals):
42826         * testing/Internals.idl:
42827
42828 2012-10-17  Pan Deng  <pan.deng@intel.com>
42829
42830         [User Timing] implement main interface in of User Timing, according to http://www.w3.org/TR/2012/CR-user-timing-20120726/
42831         https://bugs.webkit.org/show_bug.cgi?id=90963
42832
42833         Reviewed by Tony Gentilcore.
42834
42835         This patch implemented mark(), measure(), clearMarks() and clearMeasures() interface of User Timing. Getters are not exposed by Performance Timeline yet, it will be future patch.
42836
42837         Tests: http/tests/w3c/webperf/submission/user-timing/test_user_timing_clearMarks.html
42838                http/tests/w3c/webperf/submission/user-timing/test_user_timing_clearMeasures.html
42839                http/tests/w3c/webperf/submission/user-timing/test_user_timing_mark.html
42840                http/tests/w3c/webperf/submission/user-timing/test_user_timing_mark_exception.html
42841                http/tests/w3c/webperf/submission/user-timing/test_user_timing_measure.html
42842                http/tests/w3c/webperf/submission/user-timing/test_user_timing_measure_associate_with_navigation_timing.html
42843                http/tests/w3c/webperf/submission/user-timing/test_user_timing_measure_exception.html
42844                http/tests/w3c/webperf/submission/user-timing/test_user_timing_method_exist.html
42845
42846         * GNUmakefile.list.am:
42847         * WebCore.gypi:
42848         * page/Performance.cpp:
42849         (WebCore::Performance::webkitGetEntries):
42850         (WebCore::Performance::webkitGetEntriesByType):
42851         (WebCore::Performance::webkitGetEntriesByName):
42852         (WebCore):
42853         (WebCore::Performance::webkitMark):
42854         (WebCore::Performance::webkitClearMarks):
42855         (WebCore::Performance::webkitMeasure):
42856         (WebCore::Performance::webkitClearMeasures):
42857         * page/Performance.h:
42858         (WebCore):
42859         (Performance):
42860         * page/Performance.idl:
42861         * page/PerformanceMark.h: Added.
42862         (WebCore):
42863         (PerformanceMark):
42864         (WebCore::PerformanceMark::create):
42865         (WebCore::PerformanceMark::PerformanceMark):
42866         (WebCore::PerformanceMark::~PerformanceMark):
42867         * page/PerformanceMark.idl: Added.
42868         * page/PerformanceMeasure.h: Added.
42869         (WebCore):
42870         (PerformanceMeasure):
42871         (WebCore::PerformanceMeasure::create):
42872         (WebCore::PerformanceMeasure::PerformanceMeasure):
42873         (WebCore::PerformanceMeasure::~PerformanceMeasure):
42874         * page/PerformanceMeasure.idl: Added.
42875         * page/PerformanceUserTiming.cpp: Added.
42876         (WebCore):
42877         (WebCore::UserTiming::UserTiming):
42878         (WebCore::insertPerformanceEntry):
42879         (WebCore::clearPeformanceEntries):
42880         (WebCore::UserTiming::mark):
42881         (WebCore::UserTiming::clearMarks):
42882         (WebCore::UserTiming::findExistingMarkStartTime):
42883         (WebCore::UserTiming::measure):
42884         (WebCore::UserTiming::clearMeasures):
42885         * page/PerformanceUserTiming.h: Added.
42886         (WebCore):
42887         (UserTiming):
42888         (WebCore::UserTiming::create):
42889
42890 2012-10-17  James Robinson  <jamesr@chromium.org>
42891
42892         Unreviewed clang compile fix - GraphicsLayerUpdater needs a virtual destructor.
42893
42894         * platform/graphics/GraphicsLayerUpdater.h:
42895         (GraphicsLayerUpdater):
42896
42897 2012-10-17  Ryuan Choi  <ryuan.choi@samsung.com>
42898
42899         Attempt to fix the build after r131680.
42900
42901         Unreviewed build fix.
42902
42903         * dom/Document.cpp: Guard ACCELERATED_COMPOSITING for RenderLayerCompositor.h
42904
42905 2012-10-17  Elliott Sprehn  <esprehn@chromium.org>
42906
42907         StyleRareNonInheritedData::contentDataEquivalent only looks at the first ContentData
42908         https://bugs.webkit.org/show_bug.cgi?id=99560
42909
42910         Reviewed by Eric Seidel.
42911
42912         Previously we only compared the first ContentData in the linked
42913         list of ContentData's which meant that if the resolved style
42914         for content had the same prefix we wouldn't update the content.
42915
42916         This patch adds a loop to compare each of the ContentData objects
42917         in the linked list.
42918
42919         Test: fast/css-generated-content/content-property-change.html
42920
42921         * rendering/style/StyleRareNonInheritedData.cpp:
42922         (WebCore::StyleRareNonInheritedData::contentDataEquivalent):
42923
42924 2012-10-17  Elliott Sprehn  <esprehn@chromium.org>
42925
42926         Remove StyleContentType since it's not used anymore
42927         https://bugs.webkit.org/show_bug.cgi?id=99659
42928
42929         Reviewed by Eric Seidel.
42930
42931         Remove StyleContentType enum since it's not used anymore and
42932         make the is*() type checking methods on ContentData public.
42933
42934         No new tests needed, this is just deleting dead code.
42935
42936         * rendering/style/ContentData.h:
42937         (ContentData):
42938         * rendering/style/RenderStyleConstants.h:
42939
42940 2012-10-17  Simon Fraser  <simon.fraser@apple.com>
42941
42942         Create a GraphicsLayerUpdater class that will do periodic layer flushes for layer trees containing tile caches
42943         https://bugs.webkit.org/show_bug.cgi?id=99518
42944
42945         Reviewed by Dean Jackson.
42946
42947         When using tile caches in place of tiled layers, we need to recompute their
42948         visible area periodically while animations and scrolling are happening.
42949         Make a new class, GraphicsLayerUpdater, to handle this updating.
42950         Internally, it uses DisplayRefreshMonitor to generate the periodic updates.
42951         
42952         GraphicsLayer clients are notified that layers need periodic updates. Clients
42953         are free to make use of GraphicsLayerUpdater to handle this updating, as
42954         RenderLayerCompositor does.
42955         
42956         Also do some minor refactoring of methods in RenderLayerCompositor that
42957         get to Page.
42958
42959         * CMakeLists.txt: Add GraphicsLayerUpdater.cpp to the build.
42960         * GNUmakefile.list.am: Ditto.
42961         * PlatformBlackBerry.cmake: Ditto.
42962         * Target.pri: Ditto.
42963         * WebCore.gypi: Ditto.
42964         * WebCore.vcproj/WebCore.vcproj: Ditto.
42965         * WebCore.xcodeproj/project.pbxproj: Ditto.
42966         * dom/Document.cpp:
42967         (WebCore::Document::windowScreenDidChange): Tell the compositor that the screen
42968         changed, so it can tell the GraphicsLayerUpdater if it has one.
42969         * platform/graphics/GraphicsLayerClient.h:
42970         (WebCore::GraphicsLayerClient::notifyFlushBeforeDisplayRefresh): Method called
42971         for layers that need periodic updates, like tile cache layers.
42972         * platform/graphics/GraphicsLayerUpdater.cpp: Added. Uses DisplayRefreshMonitorManager
42973         to flush layers before the next refresh.
42974         (WebCore::GraphicsLayerUpdater::GraphicsLayerUpdater):
42975         (WebCore::GraphicsLayerUpdater::~GraphicsLayerUpdater):
42976         (WebCore::GraphicsLayerUpdater::scheduleUpdate):
42977         (WebCore::GraphicsLayerUpdater::screenDidChange):
42978         (WebCore::GraphicsLayerUpdater::displayRefreshFired):
42979         * platform/graphics/GraphicsLayerUpdater.h: Added.
42980         (GraphicsLayerUpdaterClient): Clients need to implement flushLayers().
42981         (WebCore::GraphicsLayerUpdaterClient::~GraphicsLayerUpdaterClient):
42982         * platform/graphics/ca/GraphicsLayerCA.cpp:
42983         (WebCore::GraphicsLayerCA::recursiveCommitChanges): For tile cache layers,
42984         tell the client that this layer should be updated soon to update the visible rect.
42985         * rendering/RenderLayerBacking.cpp:
42986         (WebCore::RenderLayerBacking::notifyFlushBeforeDisplayRefresh): Pass this message
42987         on to the compositor.
42988         * rendering/RenderLayerBacking.h:
42989         (RenderLayerBacking): Implement notifyFlushBeforeDisplayRefresh.
42990         Add OVERRIDE to all the client overrides.
42991         * rendering/RenderLayerCompositor.cpp:
42992         (WebCore::RenderLayerCompositor::cacheAcceleratedCompositingFlags): Use helper to get to Page.
42993         (WebCore::RenderLayerCompositor::scheduleLayerFlush): Ditto.
42994         (WebCore::RenderLayerCompositor::flushPendingLayerChanges): Soon we're going to be asking
42995         about the current state of animations inside the flush (for visible rect computation), so we
42996         need a AnimationUpdateBlock to make sure all the animation times are in sync.
42997         (WebCore::RenderLayerCompositor::notifyFlushBeforeDisplayRefresh): Make a GraphicsLayerUpdater
42998         if necessary, and tell it to update soon.
42999         (WebCore::RenderLayerCompositor::flushLayers): The GraphicsLayerUpdater client method.
43000         Just does a flush. For now, considers this Frame as the flush root, which will need fixing for iframes.
43001         (WebCore::RenderLayerCompositor::shouldPropagateCompositingToEnclosingFrame): Use helper to get to Page.
43002         (WebCore::RenderLayerCompositor::deviceScaleFactor): Ditto.
43003         (WebCore::RenderLayerCompositor::pageScaleFactor): Ditto.
43004         (WebCore::RenderLayerCompositor::destroyRootLayer): Ditto.
43005         (WebCore::RenderLayerCompositor::windowScreenDidChange): Tell the updater if we have one.
43006         (WebCore::RenderLayerCompositor::scrollingCoordinator): Use helper to get to Page.
43007         (WebCore::RenderLayerCompositor::graphicsLayerFactory): Use helper to get to Page.
43008         (WebCore::RenderLayerCompositor::page): The helper.
43009         * rendering/RenderLayerCompositor.h:
43010         (RenderLayerCompositor): Add OVERRIDE to all the client overrides.
43011
43012 2012-10-17  Eric Seidel  <eric@webkit.org>
43013
43014         Make dom-query.html slightly faster by removing unnecessary ref-churn in StringTraits
43015         https://bugs.webkit.org/show_bug.cgi?id=99652
43016
43017         Reviewed by Adam Barth.
43018
43019         My testing showed this moved dom-query.html from  465560 runs/s to 479019
43020         which is about 2% if I'm doing my math correctly.
43021
43022         I suspect that's due to avoiding the ref-churn we were incurring by using
43023         return-by-value symantics here.
43024
43025         This is just the tip of the iceburg. :)
43026
43027         * bindings/v8/V8StringResource.cpp:
43028         (StringTraits):
43029         * bindings/v8/V8ValueCache.h:
43030         (WebCore::WebCoreStringResource::webcoreString):
43031         (WebCore::WebCoreStringResource::atomicString):
43032
43033 2012-10-17  Luke Macpherson   <macpherson@chromium.org>
43034
43035         Move handling of CSSPropertyWebkitLineClamp from StyleResolver into StyleBuilder.
43036         https://bugs.webkit.org/show_bug.cgi?id=99534
43037
43038         Reviewed by Alexis Menard.
43039
43040         One small step towards removing the giant switch statement in StyleResolver, this patch moves line clamp handling into StyleBuilder.
43041
43042         Covered by fast/overflow/line-clamp.html
43043
43044         * css/StyleBuilder.cpp:
43045         (WebCore::StyleBuilder::StyleBuilder):
43046         * css/StyleResolver.cpp:
43047         (WebCore::StyleResolver::applyProperty):
43048
43049 2012-10-17  Andy Estes  <aestes@apple.com>
43050
43051         [WebKit2] Add removeChild: to WKDOMNode and make WKDOMText.data read/write
43052         https://bugs.webkit.org/show_bug.cgi?id=99662
43053
43054         Reviewed by Sam Weinig.
43055
43056         Export needed symbols.
43057
43058         * WebCore.exp.in:
43059
43060 2012-10-17  Adam Barth  <abarth@webkit.org>
43061
43062         [V8] Don't generate code that declares visitDOMWrapper if we're not going to generate the implementation
43063         https://bugs.webkit.org/show_bug.cgi?id=99653
43064
43065         Reviewed by Eric Seidel.
43066
43067         * bindings/scripts/CodeGeneratorV8.pm:
43068         (GenerateHeader):
43069
43070 2012-10-17  David Grogan  <dgrogan@chromium.org>
43071
43072         IndexedDB: Destroy leveldb directory if unknown schema is detected
43073         https://bugs.webkit.org/show_bug.cgi?id=99636
43074
43075         Reviewed by Tony Chang.
43076
43077         chromium browser test in progress at
43078         https://codereview.chromium.org/11196029
43079
43080         * Modules/indexeddb/IDBLevelDBBackingStore.cpp:
43081         (WebCore):
43082         (WebCore::isSchemaKnown):
43083         Return true when the schema key doesn't exist because new databases
43084         won't have one.
43085
43086         (WebCore::setUpMetadata):
43087         (WebCore::IDBLevelDBBackingStore::open):
43088         Piggy-back on existing leveldb::destroy code.
43089
43090 2012-10-17  Arpita Bahuguna  <arpitabahuguna@gmail.com>
43091
43092         Incorrect rendering of borders on <col> with span > 1
43093         https://bugs.webkit.org/show_bug.cgi?id=76246
43094
43095         Reviewed by Julien Chaffraix.
43096
43097         The HTML5 rendering specification [10.2.2 - Display Types] states that
43098         "For the purposes of the CSS table model, the col element is expected to
43099         be treated as if it was present as many times as its span attribute
43100         specifies."
43101         We should thus apply a col element's border as if the element is present
43102         as many number of times as its span attribute.
43103
43104         Apart from this, we should also treat the col and its enclosing colgroup
43105         separately while computing the collapsed borders.
43106
43107         Test: fast/table/border-collapsing/collapsed-border-with-col-colgroup-span.html
43108
43109         * rendering/RenderTableCell.cpp:
43110         (WebCore::RenderTableCell::computeCollapsedStartBorder):
43111         (WebCore::RenderTableCell::computeCollapsedEndBorder):
43112         Borders from col and its enclosing colgroup element should be handled
43113         separately, while considering the preceeding col's end border (for start
43114         border computation) and the next col's start border (for end border
43115         computation).
43116
43117         Also, have made changes for handling of col elements with span attribute as
43118         per the specification. We now apply the border (start or end) of the col
43119         element irrespective of whether it has any span specified for it or not.
43120
43121 2012-10-17  Tom Sepez  <tsepez@chromium.org>
43122
43123         Crash in ContainerNode::removeAllChildren()
43124         https://bugs.webkit.org/show_bug.cgi?id=98443
43125
43126         Reviewed by Eric Carlson.
43127
43128         This patch makes the errorEventSender added in WebKit Revision 112190 interact
43129         with the updatedHasPendingLoadEvent() mechanism in the same manner as the other
43130         existing event senders.
43131
43132         Test: http/tests/security/video-poster-cross-origin-crash2.html
43133
43134         * loader/ImageLoader.cpp:
43135         (WebCore::ImageLoader::setImage):
43136         (WebCore::ImageLoader::updateFromElement):
43137         (WebCore::ImageLoader::notifyFinished):
43138         (WebCore::ImageLoader::updatedHasPendingEvent):
43139         (WebCore::ImageLoader::dispatchPendingBeforeLoadEvent):
43140         (WebCore::ImageLoader::dispatchPendingLoadEvent):
43141         * loader/ImageLoader.h:
43142         (ImageLoader):
43143
43144 2012-10-17  Joshua Bell  <jsbell@chromium.org>
43145
43146         IndexedDB: Closing connection in upgradeneeded should result in error event
43147         https://bugs.webkit.org/show_bug.cgi?id=99486
43148
43149         Reviewed by Tony Chang.
43150
43151         The IDB spec requires that "...if connection is closed, return a DOMError of type AbortError".
43152         This was being handled during the "enqueue" phase, which was too early either for synchronously
43153         executing scripts or asynchronous messaging in multiprocess ports (crbug.com/150691). Move the
43154         logic to the "dispatch" phase.
43155
43156         Test: storage/indexeddb/intversion-close-in-oncomplete.html
43157
43158         * Modules/indexeddb/IDBOpenDBRequest.cpp:
43159         (WebCore::IDBOpenDBRequest::onSuccess): Move success to error morphing from here...
43160         (WebCore::IDBOpenDBRequest::dispatchEvent): To here.
43161         * Modules/indexeddb/IDBOpenDBRequest.h:
43162         (IDBOpenDBRequest):
43163
43164 2012-10-17  Elliott Sprehn  <esprehn@chromium.org>
43165
43166         Use virtual dispatch to create ContentData renderers
43167         https://bugs.webkit.org/show_bug.cgi?id=99646
43168
43169         Reviewed by Eric Seidel.
43170
43171         ContentData are conceptually very similar to Nodes and we can use
43172         the same createRenderer pattern on them to simplify creating
43173         renderers for generated content. Now each ContentData class knows
43174         how to create its own renderer.
43175
43176         Previously we switched over the StyleContentType which required a
43177         case for CONTENT_NONE and made the code look like it could return
43178         null, but this case is actually impossible because no ContentData
43179         class ever has a type of CONTENT_NONE and no null checks are really
43180         needed.
43181
43182         This is the final step in removing dependence on StyleContentType.
43183
43184         No new tests needed, this is just a refactor.
43185
43186         * rendering/RenderObjectChildList.cpp: Remove createRendererForBeforeAfterContent.
43187         (WebCore::RenderObjectChildList::updateBeforeAfterContent):
43188         * rendering/style/ContentData.cpp:
43189         (WebCore::ImageContentData::createRenderer):
43190         (WebCore):
43191         (WebCore::TextContentData::createRenderer):
43192         (WebCore::CounterContentData::createRenderer):
43193         (WebCore::QuoteContentData::createRenderer):
43194         * rendering/style/ContentData.h: Added a new virtual method createRenderer.
43195         (WebCore):
43196         (ContentData):
43197         (ImageContentData):
43198         (TextContentData):
43199         (CounterContentData):
43200         (QuoteContentData):
43201
43202 2012-10-17  Julien Chaffraix  <jchaffraix@webkit.org>
43203
43204         RenderLayer subtrees without any self-painting layer shouldn't be walked during hit testing
43205         https://bugs.webkit.org/show_bug.cgi?id=89393
43206
43207         Reviewed by Eric Seidel.
43208
43209         Performance optimization, covered by existing tests.
43210
43211         Bug 88888 added an peformance optimization for painting. As hit testing is very similar to
43212         painting, it would benefit from the same optimization.
43213
43214         On http://dglazkov.github.com/performance-tests/biggrid.html, with a 10,000 * 100 tables,
43215         it reduces the time to select some text inside a cell from 1-2 seconds to a usable time
43216         (I didn't measure the exact timing).
43217
43218         Note that as in bug 88888, the multi-column code is not covered by this optimization.
43219
43220         * rendering/RenderLayer.cpp:
43221         (WebCore::RenderLayer::hitTest):
43222         This is the entrance to the hit testing code so we check if we can bail out early.
43223
43224         (WebCore::RenderLayer::hitTestList):
43225         If we have no self-painting descendant layers, we can bail out.
43226
43227         (WebCore::RenderLayer::hitTestContents):
43228         (WebCore::RenderLayer::hitTestLayer):
43229         hitTest should filter the layers that call these functions. Added some ASSERT to
43230         make sure we don't mistakenly call them when could avoid it.
43231
43232 2012-10-17  Allan Sandfeld Jensen  <allan.jensen@digia.com>
43233
43234         [Qt] Certain SVG content freezes QtWebKit
43235         https://bugs.webkit.org/show_bug.cgi?id=97258
43236
43237         Reviewed by Simon Hausmann.
43238
43239         Ensure dashpattern is well-formed by avoiding divisions by zero.
43240
43241         Test: svg/stroke/zero-width-hang.html
43242
43243         * platform/graphics/qt/GraphicsContextQt.cpp:
43244         (WebCore::GraphicsContext::setLineDash):
43245
43246 2012-10-17  Alec Flett  <alecflett@chromium.org>
43247
43248         IndexedDB: Explicitly send null/undefined/integers to frontend IDBCallbacks
43249         https://bugs.webkit.org/show_bug.cgi?id=99619
43250
43251         Reviewed by Adam Barth.
43252
43253         Rather than pass SerializedScriptValue tokens from the backend,
43254         send explicit null, (as onSuccess(static_cast<SerializedScriptValue*>(0)))
43255         undefined, (as onSucess()), and integers (as onSuccess(long long))
43256
43257         This reduces backend dependency on things that might require a JS
43258         interpreter on the backend.
43259
43260         No new tests, this is a refactor and existing tests cover
43261         correctness. Tests that might fail include:
43262
43263         Test: storage/indexeddb/index-count.html
43264         Test: storage/indexeddb/objectstore-count.html
43265         Test: storage/indexeddb/database-basics.html
43266
43267         * Modules/indexeddb/IDBCallbacks.h:
43268         (IDBCallbacks):
43269         * Modules/indexeddb/IDBCursorBackendImpl.cpp:
43270         (WebCore::IDBCursorBackendImpl::advanceInternal):
43271         (WebCore::IDBCursorBackendImpl::continueFunctionInternal):
43272         (WebCore::IDBCursorBackendImpl::prefetchContinueInternal):
43273         * Modules/indexeddb/IDBCursorBackendImpl.h:
43274         (WebCore::IDBCursorBackendImpl::value):
43275         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
43276         (WebCore::IDBDatabaseBackendImpl::deleteDatabase):
43277         * Modules/indexeddb/IDBIndex.cpp:
43278         * Modules/indexeddb/IDBIndexBackendImpl.cpp:
43279         (WebCore::IDBIndexBackendImpl::openCursorInternal):
43280         (WebCore::IDBIndexBackendImpl::countInternal):
43281         (WebCore::IDBIndexBackendImpl::getInternal):
43282         * Modules/indexeddb/IDBObjectStore.cpp:
43283         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
43284         (WebCore::IDBObjectStoreBackendImpl::getInternal):
43285         (WebCore::IDBObjectStoreBackendImpl::deleteInternal):
43286         (WebCore::IDBObjectStoreBackendImpl::clearInternal):
43287         (WebCore::IDBObjectStoreBackendImpl::openCursorInternal):
43288         (WebCore::IDBObjectStoreBackendImpl::countInternal):
43289         * Modules/indexeddb/IDBRequest.cpp:
43290         (WebCore::IDBRequest::onSuccess):
43291         (WebCore):
43292         * Modules/indexeddb/IDBRequest.h:
43293         * Modules/indexeddb/IDBTransaction.cpp:
43294         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
43295         * Modules/indexeddb/IDBTransactionBackendImpl.h:
43296         * Modules/indexeddb/IDBTransactionBackendInterface.h:
43297         * bindings/v8/IDBBindingUtilities.cpp:
43298         (WebCore::deserializeIDBValue):
43299         * inspector/InspectorIndexedDBAgent.cpp:
43300         (WebCore):
43301
43302 2012-10-17  Nate Chapin  <japhet@chromium.org>
43303
43304         Move ResourceRequest construction out of SubresourceLoader
43305         https://bugs.webkit.org/show_bug.cgi?id=99627
43306
43307         Reviewed by Adam Barth.
43308
43309         CachedResource::load() fills out a bunch of http headers.
43310         SubresourceLoader::create() adds a bunch more. Merge them.
43311         Note that this merge requires a bit more care in CachedRawResource::canReuse(),
43312         because more headers are set directly on CachedResource::m_resourceRequest, rather
43313         than on a copy of it.
43314
43315         No new tests, no functionality change intended.
43316
43317         * loader/SubresourceLoader.cpp:
43318         (WebCore::SubresourceLoader::create):
43319         * loader/cache/CachedRawResource.cpp:
43320         (WebCore::shouldIgnoreHeaderForCacheReuse):
43321         (WebCore):
43322         (WebCore::CachedRawResource::canReuse):
43323         * loader/cache/CachedResource.cpp:
43324         (WebCore::CachedResource::failBeforeStarting):
43325         (WebCore):
43326         (WebCore::CachedResource::addAdditionalRequestHeaders):
43327         (WebCore::CachedResource::load):
43328         * loader/cache/CachedResource.h:
43329         (CachedResource):
43330
43331 2012-10-17  Anders Carlsson  <andersca@apple.com>
43332
43333         Clean up Vector.h
43334         https://bugs.webkit.org/show_bug.cgi?id=99622
43335
43336         Reviewed by Benjamin Poulain.
43337
43338         Fix fallout from removing std::max and std::min using declarations.
43339
43340         * loader/cache/CachedResource.cpp:
43341         (WebCore::CachedResource::currentAge):
43342
43343 2012-10-17  Joshua Bell  <jsbell@chromium.org>
43344
43345         IndexedDB: Enforce unsigned long/unsigned long long ranges
43346         https://bugs.webkit.org/show_bug.cgi?id=99637
43347
43348         Reviewed by Tony Chang.
43349
43350         The IndexedDB spec has [EnforceRange] specified on unsigned long and unsigned long long
43351         arguments, which requires the implementation to throw TypeError for negative values or
43352         values that exceed 2^53-1 (maximum JS number that behaves like an integer) - and 0 is
43353         specifically forbidden by the APIs as well.
43354
43355         A more correct fix in the binding layer is in webkit.org/b/96798 but we can temporarily
43356         address this in the implementation.
43357
43358         Also refactor to prevent IDBFactory.open(name, -1) from triggering an internal code path.
43359
43360         Tests: storage/indexeddb/cursor-advance.html
43361                storage/indexeddb/intversion-bad-parameters.html
43362                storage/indexeddb/intversion-encoding.html
43363
43364         * Modules/indexeddb/IDBCursor.cpp:
43365         (WebCore::IDBCursor::advance): Validate argument range.
43366         * Modules/indexeddb/IDBCursor.h:
43367         (IDBCursor):
43368         * Modules/indexeddb/IDBCursor.idl: Drop "unsigned" qualifier as the binding code is
43369         not yet doing the correct validation.
43370         * Modules/indexeddb/IDBFactory.cpp: Refactor to prevent open(name, -1)
43371         (WebCore):
43372         (WebCore::IDBFactory::open): Validate the int version here, then pass to...
43373         (WebCore::IDBFactory::openInternal): ... this method.
43374         * Modules/indexeddb/IDBFactory.h:
43375         (IDBFactory):
43376         * Modules/indexeddb/IDBFactory.idl: Drop "unsigned" qualifier; meaningless to binding
43377         code right now, can be re-added once webkit.org/b/96798 lands.
43378
43379 2012-10-17  Tony Chang  <tony@chromium.org>
43380
43381         fast/forms/range/input-appearance-range-rtl.html off by one pixel
43382         https://bugs.webkit.org/show_bug.cgi?id=99625
43383
43384         Reviewed by Ojan Vafai.
43385
43386         Previously, we would assume that a vertical slider in RTL would render identically to
43387         a vertical slider in LTR. Due to differing thumb sizes, there is an off by one.
43388
43389         This worked in deprecated flexbox because it doesn't adjust for RTL when applying
43390         box-align: center.
43391
43392         Tests: fast/forms/range/input-appearance-range-rtl.html
43393
43394         * html/shadow/SliderThumbElement.cpp:
43395         (WebCore::RenderSliderContainer::layout): Force LTR for flexbox layout when vertical. We have to restore the old value
43396         just in case the user switches from vertical to horizontal.
43397
43398 2012-10-17  Michael Saboff  <msaboff@apple.com>
43399
43400         Creating a String from an NSString should check for all 8 bit strings
43401         https://bugs.webkit.org/show_bug.cgi?id=99392
43402
43403         Reviewed by Geoffrey Garen.
43404
43405         Use CFStringGetBytes() to try to get Latin1 data to create an 8 bit string.
43406
43407         No functional change, change covered by existing tests.
43408
43409         * platform/text/mac/StringMac.mm:
43410         (WTF::String::String):
43411
43412 2012-10-17  Raphael Kubo da Costa  <raphael.kubo.da.costa@intel.com>
43413
43414         [EFL] Remove redundant OpenGL library addition from the build system.
43415         https://bugs.webkit.org/show_bug.cgi?id=99629
43416
43417         Reviewed by Rob Buis.
43418
43419         * PlatformEfl.cmake: Do not add OPENGL_gl_LIBRARY to
43420         WebCore_LIBRARIES, this is already done in CMakeLists.txt these
43421         days.
43422
43423 2012-10-17  Raphael Kubo da Costa  <raphael.kubo.da.costa@intel.com>
43424
43425         [CMake] Set WebCore_LIBRARIES earlier.
43426         https://bugs.webkit.org/show_bug.cgi?id=99630
43427
43428         Reviewed by Rob Buis.
43429
43430         * CMakeLists.txt: Follow the style we use in other CMakeList.txt
43431         files and set the Foo_LIBRARIES variables before we start checking
43432         for optional features, as they might append other libraries to the
43433         list (it already happens with WTF_USE_3D_GRAPHICS, for example).
43434
43435 2012-10-17  Philip Rogers  <pdr@google.com>
43436
43437         Allow lazy initialization of SVG XML animated properties.
43438         https://bugs.webkit.org/show_bug.cgi?id=84657
43439
43440         Reviewed by Tim Horton.
43441
43442         When animating a property in the shadow tree, instance properties and tearoffs are created
43443         but they simply reference the animated element's animating properties.
43444
43445         When starting an animation for the first time (see SVGAnimateElement::resetAnimatedType),
43446         we initialize the root property and instance properties using startAnimValAnimation(...).
43447         If an instance property is added while the root property is animating, this initialization
43448         will not occur and we crash.
43449
43450         This patch updates the resetAnimValToBaseVal codepath to start (and initialize) an animated
43451         property if it is not already animating. After this patch, instance properties can be added
43452         in the middle of animation and they will be properly started/initialized.
43453
43454         Test: svg/animations/use-while-animating-crash.html
43455
43456         * svg/SVGAnimatedTypeAnimator.h:
43457         (WebCore::SVGAnimatedTypeAnimator::resetFromBaseValue):
43458         (WebCore::SVGAnimatedTypeAnimator::resetFromBaseValues):
43459         (WebCore::SVGAnimatedTypeAnimator::executeAction):
43460
43461 2012-10-17  Dan Carney  <dcarney@google.com>
43462
43463         Bind isolatedWorldSecurityOrigin to world
43464         https://bugs.webkit.org/show_bug.cgi?id=99582
43465
43466         Reviewed by Adam Barth.
43467
43468         Security origin of isolated worlds was not previously set at the world
43469         level, although it could have been. 
43470
43471         No new tests. No change in functionality.
43472
43473         * bindings/v8/DOMWrapperWorld.cpp:
43474         (WebCore::DOMWrapperWorld::deallocate):
43475         (WebCore):
43476         (WebCore::isolatedWorldSecurityOrigins):
43477         (WebCore::DOMWrapperWorld::isolatedWorldSecurityOrigin):
43478         (WebCore::DOMWrapperWorld::setIsolatedWorldSecurityOrigin):
43479         (WebCore::DOMWrapperWorld::clearIsolatedWorldSecurityOrigin):
43480         * bindings/v8/DOMWrapperWorld.h:
43481         (DOMWrapperWorld):
43482         (WebCore::DOMWrapperWorld::isIsolatedWorldId):
43483         (WebCore::DOMWrapperWorld::isIsolatedWorld):
43484         * bindings/v8/ScriptController.cpp:
43485         (WebCore::ScriptController::resetIsolatedWorlds):
43486         (WebCore::ScriptController::evaluateInIsolatedWorld):
43487         (WebCore::ScriptController::collectIsolatedContexts):
43488         * bindings/v8/ScriptController.h:
43489         (ScriptController):
43490         (WebCore::ScriptController::setIsolatedWorldSecurityOrigin):
43491         * bindings/v8/V8DOMWindowShell.cpp:
43492         (WebCore::V8DOMWindowShell::initializeIfNeeded):
43493         * bindings/v8/V8DOMWindowShell.h:
43494         (V8DOMWindowShell):
43495         * bindings/v8/custom/V8XMLHttpRequestConstructor.cpp:
43496         (WebCore::V8XMLHttpRequest::constructorCallback):
43497
43498 2012-10-17  Simon Fraser  <simon.fraser@apple.com>
43499
43500         GraphicsLayer visible rect computation needs to use the current animating transform
43501         https://bugs.webkit.org/show_bug.cgi?id=99529
43502
43503         Reviewed by Dean Jackson.
43504
43505         If we're running an accelerated animation of transform
43506         on a GraphicsLayerCA, the current value of the transform won't
43507         be reflected in the GraphicsLayer's m_transform. However,
43508         we need the current value of the transform in order to correctly
43509         compute the visible rect of this layer and descendants.
43510         
43511         Add a function to GraphicsLayerClient to retrieve the current
43512         value of the transform from the client.
43513         
43514         RenderLayer's currentTransform() used to return a transform
43515         with transform-origin baked in; GraphicsLayerClient needs one
43516         that excludes transform-origin, so enhance RenderLayer::currentTransform()
43517         to be able to produce either.
43518
43519         Tests: compositing/visible-rect/animated-from-none.html
43520                compositing/visible-rect/animated.html
43521
43522         * platform/graphics/GraphicsLayerClient.h:
43523         (WebCore):
43524         (GraphicsLayerClient):
43525         (WebCore::GraphicsLayerClient::getCurrentTransform):
43526         * platform/graphics/ca/GraphicsLayerCA.cpp:
43527         (WebCore::GraphicsLayerCA::computeVisibleRect):
43528         * rendering/RenderLayer.cpp:
43529         (WebCore::RenderLayer::currentTransform):
43530         * rendering/RenderLayer.h:
43531         * rendering/RenderLayerBacking.cpp:
43532         (WebCore::RenderLayerBacking::currentTransform):
43533         * rendering/RenderLayerBacking.h:
43534         (RenderLayerBacking):
43535
43536 2012-10-17  Sadrul Habib Chowdhury  <sadrul@chromium.org>
43537
43538         plugins: Allow a plugin to dictate whether it can receive drag events or not.
43539         https://bugs.webkit.org/show_bug.cgi?id=99355
43540
43541         Reviewed by Tony Chang.
43542
43543         When doing a drag over a plugin, ask the plugin whether it can accept
43544         drag/drop to decide whether drag/drop is possible or not. At present,
43545         plugins do not receive drag events through WebCore (i.e. various
43546         implementations of PluginView::handleMouseEvent ignores the
43547         drop-events). This change makes it possible for the ports to ask the
43548         plugin first to decide whether it can (or wants to) accept drag events.
43549         The default implementation remains the same, i.e. plugins do not receive
43550         drag events. For chromium, the overridden implementation uses the
43551         WebPlugin interface to check whether the plugin can accept drag events.
43552
43553         * html/HTMLPlugInElement.cpp:
43554         (WebCore::HTMLPlugInElement::canProcessDrag):
43555         (WebCore):
43556         * html/HTMLPlugInElement.h:
43557         (WebCore):
43558         (HTMLPlugInElement):
43559         * page/DragController.cpp:
43560         (WebCore::DragController::canProcessDrag):
43561         * plugins/PluginViewBase.h:
43562         (WebCore):
43563         (WebCore::PluginViewBase::canProcessDrag):
43564
43565 2012-10-17  Andreas Kling  <kling@webkit.org>
43566
43567         Shrink EventTargetData by making firingEventListeners vector optional.
43568         <http://webkit.org/b/99532>
43569         <rdar://problem/12515099>
43570
43571         Reviewed by Anders Carlsson.
43572
43573         The majority of event listeners never actually fire, and EventTargetData::firingEventListeners
43574         is just sitting there taking up space. Make it an OwnPtr instead, shrinking EventTargetData
43575         by 48 bytes and progressing Membuster3 by 395kB.
43576
43577         * dom/EventTarget.cpp:
43578         (WebCore::EventTarget::removeEventListener):
43579         (WebCore::EventTarget::fireEventListeners):
43580         (WebCore::EventTarget::removeAllEventListeners):
43581         * dom/EventTarget.h:
43582         (WebCore::EventTarget::isFiringEventListeners):
43583
43584 2012-10-17  Christophe Dumez  <christophe.dumez@intel.com>
43585
43586         xss-DENIED-xsl-document-securityOrigin.xml crashes with icon assertion
43587         https://bugs.webkit.org/show_bug.cgi?id=99571
43588
43589         Reviewed by Kenneth Rohde Christiansen.
43590
43591         Check that the iconURL is not empty in IconController::continueLoadWithDecision()
43592         to avoid hitting assertions later when trying to commit this empty URL to the
43593         database. IconController::url() may indeed return an empty URL but there was
43594         no check for it.
43595
43596         No new tests, already covered by http/tests/security/xss-DENIED-xsl-document-securityOrigin.xml.
43597
43598         * loader/icon/IconController.cpp:
43599         (WebCore::IconController::continueLoadWithDecision):
43600
43601 2012-10-17  Byungwoo Lee  <bw80.lee@samsung.com>
43602
43603         Fix build warnings : -Wunused-parameter, -Wunused-variable
43604         https://bugs.webkit.org/show_bug.cgi?id=99539
43605
43606         Reviewed by Kentaro Hara.
43607
43608         Fix build warnings about unused parameter or unused variable when
43609         WTF_USE_TILED_BACKING_STORE option is enabled.
43610
43611         * html/shadow/HTMLContentElement.cpp:
43612         (WebCore::contentTagName):
43613         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
43614         (WebCore::GraphicsContext3D::getImageData):
43615         * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
43616         (WebCore::GraphicsContext3DPrivate::createSurface):
43617         (WebCore::GraphicsContext3DPrivate::paintToTextureMapper):
43618         * platform/graphics/opengl/Extensions3DOpenGL.cpp:
43619         (WebCore::Extensions3DOpenGL::bindVertexArrayOES):
43620         * platform/graphics/texmap/TextureMapper.h:
43621         (WebCore::BitmapTexture::canReuseWith):
43622         (WebCore::TextureMapper::beginPainting):
43623         * platform/graphics/texmap/TextureMapperGL.cpp:
43624         (WebCore::TextureMapperGL::drawRepaintCounter):
43625         * platform/graphics/texmap/TextureMapperImageBuffer.cpp:
43626         (WebCore::BitmapTextureImageBuffer::updateContents):
43627         * platform/graphics/texmap/TextureMapperImageBuffer.h:
43628         * platform/graphics/texmap/TextureMapperLayer.cpp:
43629         (WebCore::TextureMapperLayer::sortByZOrder):
43630         (WebCore::TextureMapperLayer::flushCompositingStateSelf):
43631         * rendering/RenderLayerCompositor.cpp:
43632         (WebCore::RenderLayerCompositor::allowsIndependentlyCompositedFrames):
43633
43634 2012-10-17  Shinya Kawanaka  <shinyak@chromium.org>
43635
43636         Dynamically added elements do not get re-projected.
43637         https://bugs.webkit.org/show_bug.cgi?id=99227
43638
43639         Reviewed by Dimitri Glazkov.
43640
43641         When distribution happens, we have to invalidate its host shadow's distribution, since the children of the host
43642         is changed.
43643
43644         Test: fast/dom/shadow/content-reprojection-dynamic.html
43645
43646         * html/shadow/ContentDistributor.cpp:
43647         (WebCore::ContentDistributor::distribute):
43648
43649 2012-10-17  Yury Semikhatsky  <yurys@chromium.org>
43650
43651         Web Inspector: no "delete watch expression" context menu item when clicking on the expression value
43652         https://bugs.webkit.org/show_bug.cgi?id=99602
43653
43654         Reviewed by Pavel Feldman.
43655
43656         Add delete items to the watch expression's value's context menu.
43657
43658         * inspector/front-end/ObjectPropertiesSection.js:
43659         (WebInspector.ObjectPropertyTreeElement.prototype._contextMenuFired):
43660         (WebInspector.ObjectPropertyTreeElement.prototype.populateContextMenu):
43661         * inspector/front-end/WatchExpressionsSidebarPane.js:
43662         (WebInspector.WatchExpressionTreeElement.prototype.populateContextMenu):
43663         (WebInspector.WatchExpressionTreeElement.prototype._contextMenu):
43664
43665 2012-10-17  Vsevolod Vlasov  <vsevik@chromium.org>
43666
43667         Web Inspector: [Regression] Undoing script changes does not restore breakpoints.
43668         https://bugs.webkit.org/show_bug.cgi?id=99598
43669
43670         Reviewed by Pavel Feldman.
43671
43672         workingCopyChanged now dispatches did/willMergeToVM instead of did/willDivergeFromVM
43673         when change returns uiSourceCode to non dirty state.
43674         Added wasDirty parameter to workingCopyChanged event.
43675
43676         Test: inspector/debugger/live-edit-breakpoints.html
43677
43678         * inspector/front-end/ResourceScriptMapping.js:
43679         (WebInspector.ResourceScriptFile.prototype._workingCopyCommitted):
43680         (WebInspector.ResourceScriptFile.prototype._workingCopyChanged):
43681         * inspector/front-end/UISourceCode.js:
43682         (WebInspector.UISourceCode.prototype.setWorkingCopy):
43683
43684 2012-10-17  Simon Hausmann  <simon.hausmann@digia.com>
43685
43686         [Qt] Avoid re-creating CSSGrammar.cpp with each (incremental) build
43687
43688         Reviewed by Tor Arne Vestbø.
43689
43690         The expected output is CSSGrammar.cpp and the input file used to be CSSGrammar.y,
43691         so ${QMAKE_FILE_BASE}.cpp did the correct transformation. Recently the input has
43692         changed to CSSGrammar.y.in, in which case the ${QMAKE_FILE_BASE} is CSSGrammar.y
43693         unfortunately. The resulting target CSSGrammar.y.cpp will never be created and
43694         therefore the target will always run.
43695
43696         * DerivedSources.pri:
43697
43698 2012-10-17  Ilya Tikhonovsky  <loislo@chromium.org>
43699
43700         Unreviewed fix for ImageSourceCG.
43701
43702         * platform/graphics/cg/ImageSourceCG.cpp:
43703         (WebCore::ImageSource::reportMemoryUsage):
43704
43705 2012-10-17  Ilya Tikhonovsky  <loislo@chromium.org>
43706
43707         Unreviewed fix for compilation on CG bots.
43708
43709         * platform/graphics/cg/ImageSourceCG.cpp:
43710
43711 2012-10-16  Ilya Tikhonovsky  <loislo@chromium.org>
43712
43713         Web Inspector: NMI instrument ImageDecoder. It owns a buffer that could be quite big.
43714         https://bugs.webkit.org/show_bug.cgi?id=99540
43715
43716         Reviewed by Yury Semikhatsky.
43717
43718         * platform/graphics/ImageSource.cpp:
43719         (WebCore::ImageSource::reportMemoryUsage):
43720         (WebCore):
43721         * platform/graphics/ImageSource.h:
43722         (ImageSource):
43723         * platform/image-decoders/ImageDecoder.cpp:
43724         (WebCore::ImageFrame::reportMemoryUsage):
43725         (WebCore):
43726         (WebCore::ImageDecoder::reportMemoryUsage):
43727         * platform/image-decoders/ImageDecoder.h:
43728         (ImageFrame):
43729         (ImageDecoder):
43730         * platform/image-decoders/skia/ImageDecoderSkia.cpp:
43731         (WebCore::ImageFrame::reportMemoryUsage):
43732         (WebCore):
43733
43734 2012-10-17  Zeno Albisser  <zeno@webkit.org>
43735
43736         [Qt] Fix build on Mac OSX 10.6 and earlier.
43737         https://bugs.webkit.org/show_bug.cgi?id=99595
43738
43739         Reviewed by Simon Hausmann.
43740
43741         * Target.pri:
43742
43743 2012-10-17  Pavel Feldman  <pfeldman@chromium.org>
43744
43745         Web Inspector: display "disconnected" message when remote debugging terminates
43746         https://bugs.webkit.org/show_bug.cgi?id=99316
43747
43748         Reviewed by Yury Semikhatsky.
43749
43750         Otherwise, it is not clear that the front-end is no longer functional.
43751
43752         * inspector/front-end/InspectorFrontendHostStub.js:
43753         (WebInspector.RemoteDebuggingTerminatedScreen):
43754         * inspector/front-end/inspector.js:
43755         (WebInspector.loaded.WebInspector.socket.onclose):
43756         (WebInspector.loaded):
43757
43758 2012-10-17  Yury Semikhatsky  <yurys@chromium.org>
43759
43760         Web Inspector: delete watch expression button overlaps with the expression value
43761         https://bugs.webkit.org/show_bug.cgi?id=99569
43762
43763         Reviewed by Vsevolod Vlasov.
43764
43765         Delete watch expression button now doesn't overlap with the watch expression.
43766
43767         * inspector/front-end/inspector.css:
43768         (.properties-tree.watch-expressions > li > .value):
43769
43770 2012-10-17  Luke Macpherson   <macpherson@chromium.org>
43771
43772         Move handling of CSSPropertyPointerEvents from StyleResolver into StyleBuilder.
43773         https://bugs.webkit.org/show_bug.cgi?id=99536
43774
43775         Reviewed by Alexis Menard.
43776
43777         One small step towards removing the giant switch statement in StyleResolver,
43778         this patch moves pointer event property into StyleBuilder.
43779
43780         Covered by fast/events/pointer-events.html and fast/events/pointer-events-2.html.
43781
43782         * css/StyleBuilder.cpp:
43783         (WebCore::StyleBuilder::StyleBuilder):
43784         * css/StyleResolver.cpp:
43785         (WebCore::StyleResolver::applyProperty):
43786
43787 2012-10-17  Keishi Hattori  <keishi@webkit.org>
43788
43789         Localized date should be based on LDML
43790         https://bugs.webkit.org/show_bug.cgi?id=99570
43791
43792         Reviewed by Kent Tamura.
43793
43794         Localized date should be based on LDML to match the format inside DateTimeEditElement.
43795
43796         No new tests. Covered by LocaleMacTest.formatDate and LocaleWinTest.formatDate.
43797
43798         * platform/text/LocaleICU.cpp: Removed formatDateTime.
43799         * platform/text/LocaleICU.h:
43800         (LocaleICU):
43801         * platform/text/LocaleNone.cpp: Removed formatDateTime.
43802         (LocaleNone):
43803         * platform/text/LocaleWin.cpp: Removed formatDateTime and formatDate.
43804         (WebCore):
43805         * platform/text/LocaleWin.h:
43806         (LocaleWin):
43807         * platform/text/Localizer.cpp:
43808         (WebCore::DateTimeStringBuilder::visitField): Added support for year/month/day.
43809         (WebCore::Localizer::formatDateTime): Creates the formatted string based on the format from dateFormat().
43810         * platform/text/Localizer.h:
43811         * platform/text/mac/LocaleMac.h:
43812         (LocaleMac):
43813         * platform/text/mac/LocaleMac.mm: Removed formatDateTime.
43814
43815 2012-10-17  Harald Alvestrand  <hta@google.com>
43816
43817         Implement the Selector argument to RTCPeerConnection.getStats
43818         https://bugs.webkit.org/show_bug.cgi?id=99460
43819
43820         Reviewed by Adam Barth.
43821
43822         The change adds two new parameters to the RTCStatsRequest object:
43823         stream and component. Together these are enough to identify a
43824         MediaStreamTrack.
43825
43826         Test: fast/mediastream/RTCPeerConnection-statsSelector.html
43827
43828         * Modules/mediastream/MediaStreamTrack.cpp:
43829         (WebCore::MediaStreamTrack::streamDescriptor):
43830         (WebCore):
43831         * Modules/mediastream/MediaStreamTrack.h:
43832         * Modules/mediastream/RTCPeerConnection.cpp:
43833         (WebCore::RTCPeerConnection::getStats):
43834         * Modules/mediastream/RTCStatsRequestImpl.cpp:
43835         (WebCore::RTCStatsRequestImpl::create):
43836         (WebCore::RTCStatsRequestImpl::RTCStatsRequestImpl):
43837         (WebCore::RTCStatsRequestImpl::hasSelector):
43838         (WebCore):
43839         (WebCore::RTCStatsRequestImpl::stream):
43840         (WebCore::RTCStatsRequestImpl::component):
43841         * Modules/mediastream/RTCStatsRequestImpl.h:
43842         (RTCStatsRequestImpl):
43843         * platform/chromium/support/WebRTCStatsRequest.cpp:
43844         (WebKit):
43845         (WebKit::WebRTCStatsRequest::hasSelector):
43846         (WebKit::WebRTCStatsRequest::stream):
43847         (WebKit::WebRTCStatsRequest::component):
43848         * platform/mediastream/RTCStatsRequest.h:
43849         (WebCore):
43850         (RTCStatsRequest):
43851
43852 2012-10-17  Simon Hausmann  <simon.hausmann@digia.com>
43853
43854         [Qt] Enable use of more AllInOne files
43855         https://bugs.webkit.org/show_bug.cgi?id=99579
43856
43857         Reviewed by Tor Arne Vestbø.
43858
43859         The AllInOne files reduce pressure during final link time because the object files contain less duplicated
43860         symbols.
43861
43862         * Target.pri: Add HTMLElementsAllInOne, EditingAllInOne and RenderingAllInOne to the build
43863         * editing/EditingAllInOne.cpp: Place a #if USE(CF) around the inclusion of SmartReplaceCF.cpp
43864         * html/HTMLElementsAllInOne.cpp: Move HTMLPlugInElement.cpp to the top to fix builds on X11 based platforms
43865         where the X headers get confused by the "Region" type that's also declared in WebCore.
43866         * rendering/RenderingAllInOne.cpp: Fix build on case-sensitive file systems (Plugin -> PlugIn) and added a
43867         #if PLATFORM(WIN) around the inclusion of RenderThemeWin.cpp.
43868
43869 2012-10-17  Kent Tamura  <tkent@chromium.org>
43870
43871         REGRESSION(r131421): Text baseline becomes incorrect after re-layout of input[type=time]
43872         https://bugs.webkit.org/show_bug.cgi?id=99572
43873
43874         Reviewed by Kentaro Hara.
43875
43876         We use flexible box since r131421, and it seems text baseline becomes
43877         incorrect if there are text nodes in a flex container.
43878
43879         Test: fast/forms/time-multiple-fields/time-multiple-fields-static-relayout.html
43880
43881         * css/html.css:
43882         (input::-webkit-datetime-edit-text): Added.
43883         * html/shadow/DateTimeEditElement.cpp:
43884         (WebCore::DateTimeEditBuilder::visitLiteral):
43885         Wrap text with an element with ::-webkit-datetime-edit-text.
43886
43887 2012-10-17  Grzegorz Czajkowski  <g.czajkowski@samsung.com>, Michal Roj <m.roj@samsung.com>
43888
43889         [WK2][EFL] Implementation of spellchecking feature.
43890         https://bugs.webkit.org/show_bug.cgi?id=91854
43891
43892         Reviewed by Gyuyoung Kim.
43893
43894         * PlatformEfl.cmake:
43895         Add enchant-related compiler flags: header paths and the library flag.
43896
43897 2012-10-17  Alexander Pavlov  <apavlov@chromium.org>
43898
43899         Web Inspector: Avoid style updates when retrieving the inline stylesheet text
43900         https://bugs.webkit.org/show_bug.cgi?id=99576
43901
43902         Reviewed by Vsevolod Vlasov.
43903
43904         Avoid using innerText() to retrieve inline stylesheet text, which may result in style and layout updates.
43905
43906         * inspector/InspectorStyleSheet.cpp:
43907         (WebCore::InspectorStyleSheet::inlineStyleSheetText):
43908
43909 2012-10-17  Patrick Gansterer  <paroga@webkit.org>
43910
43911         Build fix for WinCE after r131365.
43912
43913         * platform/graphics/GlyphBuffer.h:
43914         (WebCore::GlyphBufferAdvance::width):
43915         * platform/graphics/wince/FontWinCE.cpp:
43916         (WebCore::cursorToX):
43917         * platform/graphics/wince/GraphicsContextWinCE.cpp:
43918         (WebCore::GraphicsContext::drawText):
43919
43920 2012-10-17  Mike West  <mkwst@chromium.org>
43921
43922         V8 should throw a more descriptive exception when blocking 'eval' via CSP.
43923         https://bugs.webkit.org/show_bug.cgi?id=94332
43924
43925         Reviewed by Adam Barth.
43926
43927         Following up on https://bugs.webkit.org/show_bug.cgi?id=94331, this
43928         patch wires up the new error message mechanism to V8, and updates the
43929         Chromium test expectations accordingly.
43930
43931         * bindings/v8/ScriptController.cpp:
43932         (WebCore::ScriptController::disableEval):
43933             Pass 'errorMessage' through to V8.
43934         * bindings/v8/V8DOMWindowShell.cpp:
43935         (WebCore::V8DOMWindowShell::initializeIfNeeded):
43936             Grab the error message from ContentSecurityPolicy, and pass it
43937             through to V8.
43938         * bindings/v8/WorkerContextExecutionProxy.cpp:
43939         (WebCore::WorkerContextExecutionProxy::WorkerContextExecutionProxy):
43940         (WebCore::WorkerContextExecutionProxy::evaluate):
43941         (WebCore::WorkerContextExecutionProxy::setEvalAllowed):
43942         * bindings/v8/WorkerContextExecutionProxy.h:
43943         (WorkerContextExecutionProxy):
43944             Convert 'm_disableEvalPending' to a string to store the current
43945             error message, and use it to set the eval state.
43946         * bindings/v8/WorkerScriptController.cpp:
43947         (WebCore::WorkerScriptController::disableEval):
43948             Pass 'errorMessage' through to V8.
43949
43950 2012-10-17  MORITA Hajime  <morrita@google.com>
43951
43952         Assertion failed on HTMLFormControlElement.cpp: updateFromElementCallback()
43953         https://bugs.webkit.org/show_bug.cgi?id=99566
43954
43955         Reviewed by Kent Tamura.
43956
43957         It had a too optimistic assertion. This change removes it.
43958
43959         Test: fast/forms/textarea/textarea-autofocus-removal-while-focusing.html
43960
43961         * html/HTMLFormControlElement.cpp:
43962         (WebCore::updateFromElementCallback):
43963
43964 2012-10-17  Vsevolod Vlasov  <vsevik@chromium.org>
43965
43966         Web Inspector: When dirty uiSourceCode is saved to disk from scripts navigator context menu working copy is not committed.
43967         https://bugs.webkit.org/show_bug.cgi?id=99555
43968
43969         Reviewed by Yury Semikhatsky.
43970
43971         Save As context menu handler now commits working copy for dirty UISourceCodes.
43972
43973         * inspector/front-end/HandlerRegistry.js:
43974
43975 2012-10-17  Vsevolod Vlasov  <vsevik@chromium.org>
43976
43977         Web Inspector: Stylesheets saved with FileManager are not saved to disk when edited from Elements panel.
43978         https://bugs.webkit.org/show_bug.cgi?id=99554
43979
43980         Reviewed by Yury Semikhatsky.
43981
43982         Moved saving to disk from SourceFrame to UISourceCode.
43983
43984         * inspector/front-end/SourceFrame.js:
43985         (WebInspector.SourceFrame.prototype._commitEditing):
43986         * inspector/front-end/UISourceCode.js:
43987         (WebInspector.UISourceCode.prototype._commitContent):
43988
43989 2012-10-17  Vsevolod Vlasov  <vsevik@chromium.org>
43990
43991         Web Inspector: [Regression] SASS sources are not saved to disk.
43992         https://bugs.webkit.org/show_bug.cgi?id=99551
43993
43994         Reviewed by Yury Semikhatsky.
43995
43996         Added resource null checks.
43997
43998         * inspector/front-end/StylesSourceMapping.js:
43999         (WebInspector.StylesSourceMapping.prototype._uiSourceCodeAddedToWorkspace):
44000
44001 2012-10-17  Elliott Sprehn  <esprehn@chromium.org>
44002
44003         Clean up ContentData operator overloads
44004         https://bugs.webkit.org/show_bug.cgi?id=99556
44005
44006         Reviewed by Eric Seidel.
44007
44008         Use virtual dispatch for checking ContentData equality instead
44009         of a switch over the type. This the first step in getting rid
44010         of the StyleContentType enum and all the switch statements over
44011         the type().
44012
44013         No tests needed, this is just a refactor.        
44014
44015         * rendering/style/ContentData.cpp:
44016         * rendering/style/ContentData.h:
44017         (ContentData):
44018         (WebCore::operator==):
44019         (WebCore):
44020         (WebCore::operator!=):
44021
44022 2012-10-17  Gabor Rapcsanyi  <rgabor@webkit.org>
44023
44024         NEON intrinsics Gauss filter does not work properly
44025         https://bugs.webkit.org/show_bug.cgi?id=98875
44026
44027         Reviewed by Zoltan Herczeg.
44028
44029         Fixing the NEON intrinsics Gauss filter. The stride parameter
44030         was missing from the intrinsics algorithm. Tested with pixel
44031         checks, now it's working properly.
44032
44033         * platform/graphics/filters/arm/FEGaussianBlurNEON.h:
44034         (WebCore::boxBlurNEON):
44035
44036 2012-10-17  MORITA Hajime  <morrita@google.com>
44037
44038         Crash on Frame::inScope() part 2
44039         https://bugs.webkit.org/show_bug.cgi?id=99543
44040
44041         Reviewed by Kent Tamura.
44042
44043         FrameTree::scopedChildCount() can be called even when the one of child frames
44044         is in orphan state. This change added a guard for that case.
44045
44046         No new tests. A hard-to-test timing issue.
44047
44048         * page/Frame.cpp:
44049         (WebCore::Frame::inScope):
44050
44051 2012-10-17  Shinya Kawanaka  <shinyak@chromium.org>
44052
44053         Remove shadowAncestorNode() from VisibleSelection
44054         https://bugs.webkit.org/show_bug.cgi?id=99544
44055
44056         Reviewed by Hajime Morita.
44057
44058         An effort to replace shadowAncestorNode() with shadowHost(), since shadowAncestorNode() is now deprecated.
44059
44060         No new tests, no change in behavior.
44061
44062         * editing/VisibleSelection.cpp:
44063         (WebCore::VisibleSelection::adjustSelectionToAvoidCrossingEditingBoundaries): Since shadowHost() returns 0 if
44064         an element is not in shadowRoot, it's ok to compare shadowAncestor to 0.
44065
44066 2012-10-17  Douglas Stockwell  <dstockwell@chromium.org>
44067
44068         Content of replaced elements should be trimmed to the content edge curve.
44069         https://bugs.webkit.org/show_bug.cgi?id=63899
44070
44071         Reviewed by Simon Fraser.
44072
44073         When a border-radius is specified the content of replaced elements needs to be clipped to avoid
44074         being painted over the padding or border in the corners. Previously the clip that was applied
44075         was set to the border-edge curve, this patch contracts the clip by the size of the border and
44076         padding (the content-edge curve) to match the css3 spec.
44077         Spec: http://www.w3.org/TR/css3-background/#corner-clipping
44078
44079         Test: fast/replaced/border-radius-clip-content-edge.html
44080
44081         * rendering/RenderBoxModelObject.h:
44082         (RenderBoxModelObject):
44083         * rendering/RenderReplaced.cpp:
44084         (WebCore::RenderReplaced::paint):
44085         * rendering/RenderWidget.cpp:
44086         (WebCore::RenderWidget::paint):
44087
44088 2012-10-17  Kunihiko Sakamoto  <ksakamoto@chromium.org>
44089
44090         The HTML5 formtarget/formaction/formenctyp/formmethod/formnovalidate attributes don't work in button tags with nested elements
44091         https://bugs.webkit.org/show_bug.cgi?id=90539
44092
44093         Reviewed by Kent Tamura.
44094
44095         Fix a bug where form(action|enctype|method|target) attributes of <button> are not
44096         honored if the target of the click event is an element nested within the button.
44097
44098         Test: fast/forms/formaction-attribute.html
44099
44100         * loader/FormSubmission.cpp:
44101         (WebCore::FormSubmission::create): Looks for the attributes for form submission
44102         from the nearest FormControlElement ancestor of the event target.
44103
44104 2012-10-16  MORITA Hajime  <morrita@google.com>
44105
44106         [Shadow DOM][V8] WebCore::V8DOMWindow::installPerContextProperties() is slow when shadowDOMEnabled flag is on.
44107         https://bugs.webkit.org/show_bug.cgi?id=99428
44108
44109         Reviewed by Adam Barth.
44110
44111         A benchmark unveiled that installPerContextProperties() could have made DOMWindow setup slower when
44112         - Some properties are added per-context basis by turnin the flag on and
44113         - There are bunch of DOMWindow object in the page (that is, there are many iframes.)
44114
44115         This change eliminates Shadow DOM related per-context properties from DOMWindow for getting rid of that slowness.
44116
44117         * dom/ContextFeatures.cpp:
44118         * dom/ContextFeatures.h: Removed shadowDOMEnabled() method and related enum entry.
44119         * dom/Position.cpp:
44120         (WebCore::Position::Position):
44121         (WebCore::Position::findParent):
44122         * dom/TreeScope.cpp:
44123         (WebCore::TreeScope::getSelection):
44124         * dom/make_names.pl: Re-introduced "runtimeConditional" directive.
44125         (defaultTagPropertyHash):
44126         (printConstructorInterior):
44127         (printFactoryCppFile):
44128         (printWrapperFunctions):
44129         (printWrapperFactoryCppFile):
44130         * html/HTMLTagNames.in:
44131         * html/shadow/HTMLContentElement.cpp:
44132         (WebCore::contentTagName):
44133         * page/DOMWindow.idl:
44134
44135 2012-10-16  Julien Chaffraix  <jchaffraix@webkit.org>
44136
44137         Make RenderObject destruction during detach a top-down operation
44138         https://bugs.webkit.org/show_bug.cgi?id=98336
44139
44140         Reviewed by Eric Seidel.
44141
44142         detach() is a DOM-driven operation that destroys the renderers bottom-up.
44143         While this is correct, it causes extra-work to be done (tree cleaning, ...)
44144         as it doesn't know about the render tree's structure.
44145
44146         The render tree on the other side already supports top-down operations
44147         but it was overriden by the DOM side of detach.
44148
44149         This change only makes ContainerNode::detach do a top-down render tree
44150         destruction. This is a required step towards doing smarter destruction.
44151
44152         Refactoring covered by existing tests.
44153
44154         * dom/ContainerNode.cpp:
44155         (WebCore::ContainerNode::detach):
44156         Changed the method to do a top-down destruction.
44157
44158         * dom/Node.cpp:
44159         (WebCore::Node::detach):
44160         Added this ASSERT that ensures that we have properly cleaned up the
44161         whole DOM subtree. The only exception is child content belonging to a
44162         flow-thread as the code will shuffle the renderers under the flow-thread.
44163
44164         * rendering/RenderObject.cpp:
44165         (WebCore::RenderObject::willBeDestroyed):
44166         As we don't update the node's renderer on the DOM side, do it here.
44167         The upside is that it ensures that we don't left any stray renderer
44168         in the tree.
44169
44170         * rendering/RenderObjectChildList.cpp:
44171         (WebCore::RenderObjectChildList::destroyLeftoverChildren):
44172         Removed the calls to setRenderer as they are redundant with what we do
44173         in willBeDestroyed.
44174
44175         * rendering/RenderTextFragment.cpp:
44176         (WebCore::RenderTextFragment::setText):
44177         Removed some now unneeded code, replaced by an ASSERT. This is because
44178         destroying m_firstLetter would automatically reset the node's renderer
44179         in destroyLeftoverChildren.
44180
44181 2012-10-16  Joseph Pecoraro  <pecoraro@apple.com>
44182
44183         HTMLSelectElement::optionSelectedByUser confuses listIndex and optionIndex
44184         https://bugs.webkit.org/show_bug.cgi?id=99523
44185
44186         Reviewed by Simon Fraser.
44187
44188         There was a call site where the optionIndex was being passed to a
44189         function that expected the listIndex. Convert appropriately.
44190
44191         Extends Test: platform/mac/fast/objc/dom-html-select-activate.html
44192
44193         * html/HTMLSelectElement.cpp:
44194         (WebCore::HTMLSelectElement::optionSelectedByUser):
44195
44196 2012-10-16  Jian Li  <jianli@chromium.org>
44197
44198         Rename feature define ENABLE_WIDGET_REGION to ENABLE_DRAGGBALE_REGION
44199         https://bugs.webkit.org/show_bug.cgi?id=98975
44200
44201         Reviewed by Adam Barth.
44202
44203         Renaming is needed to better match with the draggable region code.
44204
44205         No new tests due to no functional change.
44206
44207         * Configurations/FeatureDefines.xcconfig:
44208         * DerivedSources.make:
44209         * WebCore.exp.in:
44210         * css/CSSComputedStyleDeclaration.cpp:
44211         (WebCore):
44212         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
44213         * css/CSSParser.cpp:
44214         (WebCore::CSSParser::parseValue):
44215         * css/CSSProperty.cpp:
44216         (WebCore::CSSProperty::isInheritedProperty):
44217         * css/CSSPropertyNames.in:
44218         * css/CSSValueKeywords.in:
44219         * css/StyleResolver.cpp:
44220         (WebCore::StyleResolver::applyProperty):
44221         * dom/Document.cpp:
44222         (WebCore::Document::Document):
44223         (WebCore):
44224         (WebCore::Document::reportMemoryUsage):
44225         * dom/Document.h:
44226         (WebCore):
44227         (Document):
44228         * page/Chrome.cpp:
44229         (WebCore):
44230         * page/ChromeClient.h:
44231         (ChromeClient):
44232         * page/FrameView.cpp:
44233         (WebCore::FrameView::layout):
44234         (WebCore):
44235         (WebCore::FrameView::paintContents):
44236         * page/FrameView.h:
44237         (FrameView):
44238         * rendering/RenderInline.cpp:
44239         (WebCore):
44240         (WebCore::RenderInline::addAnnotatedRegions):
44241         * rendering/RenderInline.h:
44242         (RenderInline):
44243         * rendering/RenderLayer.cpp:
44244         (WebCore::RenderLayer::scrollTo):
44245         (WebCore::RenderLayer::setHasHorizontalScrollbar):
44246         (WebCore::RenderLayer::setHasVerticalScrollbar):
44247         (WebCore::RenderLayer::updateScrollbarsAfterLayout):
44248         * rendering/RenderListBox.cpp:
44249         (WebCore::RenderListBox::setHasVerticalScrollbar):
44250         * rendering/RenderObject.cpp:
44251         (WebCore::RenderObject::styleWillChange):
44252         (WebCore):
44253         (WebCore::RenderObject::addAnnotatedRegions):
44254         * rendering/RenderObject.h:
44255         (WebCore::AnnotatedRegionValue::operator==):
44256         (AnnotatedRegionValue):
44257         (RenderObject):
44258         * rendering/style/RenderStyle.h:
44259         * rendering/style/RenderStyleConstants.h:
44260         * rendering/style/StyleRareNonInheritedData.cpp:
44261         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
44262         (WebCore::StyleRareNonInheritedData::operator==):
44263         * rendering/style/StyleRareNonInheritedData.h:
44264         (StyleRareNonInheritedData):
44265
44266 2012-10-16  James Simonsen  <simonjam@chromium.org>
44267
44268         [Page Visibility API] View-less documents should report as hidden
44269         https://bugs.webkit.org/show_bug.cgi?id=99410
44270
44271         Reviewed by Tony Gentilcore.
44272
44273         Test: fast/events/page-visibility-null-view.html
44274
44275         * dom/Document.cpp:
44276         (WebCore::Document::visibilityState):
44277
44278 2012-10-16  Michael Saboff  <msaboff@apple.com>
44279
44280         Change WTF_USE_8BIT_TEXTRUN to ENABLE_8BIT_TEXTRUN
44281         https://bugs.webkit.org/show_bug.cgi?id=99484
44282
44283         Reviewed by Eric Seidel.
44284
44285         Changed macro name to align with it's purpose, therefore changed USE(8BIT_TEXTRUN) to ENABLE(8BIT_TEXTRUN).
44286
44287         No new tests.  Changed macro name, no functional change.
44288
44289         * platform/graphics/TextRun.h:
44290         (WebCore::TextRun::TextRun):
44291         (WebCore::TextRun::subRun):
44292         * rendering/RenderBlock.cpp:
44293         (WebCore::RenderBlock::constructTextRun):
44294         * rendering/RenderBlock.h:
44295         (RenderBlock):
44296
44297 2012-10-16  Noam Rosenthal  <noam.rosenthal@nokia.com>
44298
44299         [Qt] REGRESSION(r131485): It broke the build
44300         https://bugs.webkit.org/show_bug.cgi?id=99499
44301
44302         Unreviewed build (warning) fix.
44303
44304         * platform/graphics/texmap/TextureMapperShaderManager.cpp:
44305         (WebCore::TextureMapperShaderProgram::getLocation):
44306
44307 2012-10-16  David Grogan  <dgrogan@chromium.org>
44308
44309         Inspector: Don't fire assert when inspecting an empty db
44310         https://bugs.webkit.org/show_bug.cgi?id=99370
44311
44312         Reviewed by Vsevolod Vlasov.
44313
44314         * inspector/InspectorIndexedDBAgent.cpp:
44315         (WebCore):
44316
44317 2012-10-16  Tony Chang  <tony@chromium.org>
44318
44319         Unreviewed, try to fix the Apple Win build by forcing a rebuild of RenderingAllInOne.cpp.
44320
44321         * rendering/RenderingAllInOne.cpp:
44322
44323 2012-10-16  Andrew Scherkus  <scherkus@chromium.org>
44324
44325         Fix crash in WebCore::MediaControlPanelElement::makeTransparent()
44326         https://bugs.webkit.org/show_bug.cgi?id=97951
44327
44328         Reviewed by Simon Fraser.
44329
44330         No new tests as it's a speculative fix based on crash dump analysis.
44331      
44332         Despite MediaControlPanelElement checking for document()->page() nullity in other places, it forgot one check in makeTransparent().
44333
44334         * html/shadow/MediaControlElements.cpp:
44335         (WebCore::MediaControlPanelElement::makeTransparent):
44336
44337 2012-10-16  Emil A Eklund  <eae@chromium.org>
44338
44339         Remove special-case flooring of baselinePosition for replaced elements in InlineFlowBox::placeBoxesInBlockDirection
44340         https://bugs.webkit.org/show_bug.cgi?id=99376
44341
44342         Reviewed by Levi Weintraub.
44343
44344         In r122769 (bug 91410) we added a special-case handling for
44345         replaced elements in InlineFlowBox::placeBoxesInBlockDirection
44346         to work around positioning issues in a couple of svg tests.
44347         This was needed to compensate for a workaround in the table
44348         painting code that was fixed in r131358 (bug 99364). As such the
44349         special-case handling for replaced elements is no longer needed
44350         in InlineFlowBox::placeBoxesInBlockDirection.
44351
44352         Furthermore this caused problems with caret repainting leaving
44353         residual pixels which motivated this change.
44354
44355         No new tests, have not been able to write a repaint test to
44356         demonstrate the caret repaint issue.
44357
44358         * rendering/InlineFlowBox.cpp:
44359         (WebCore::InlineFlowBox::placeBoxesInBlockDirection):
44360
44361 2012-10-16  Simon Fraser  <simon.fraser@apple.com>
44362
44363         Some #include hygiene
44364         https://bugs.webkit.org/show_bug.cgi?id=99500
44365
44366         Reviewed by Tony Chang.
44367
44368         Clean up some #includes, mostly related to GraphicsLayer.h. In many
44369         cases this can be replaced by PlatformLayer.h.
44370         
44371         Remove an #include of PluginViewBase.h from Page.h, which was a source
44372         of #include fan-out.
44373
44374         * html/canvas/CanvasRenderingContext2D.h:
44375         * page/Page.h:
44376         * page/scrolling/ScrollingCoordinator.h:
44377         * page/scrolling/ScrollingStateNode.h:
44378         * page/scrolling/mac/ScrollingStateNodeMac.mm:
44379         * platform/graphics/GraphicsContext3D.h:
44380         * platform/graphics/MediaPlayer.h:
44381         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
44382         * platform/graphics/gpu/DrawingBuffer.h:
44383         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
44384         * plugins/PluginViewBase.h:
44385
44386 2012-10-16  Adam Barth  <abarth@webkit.org>
44387
44388         Document::adoptNode shouldn't special-case <iframe>
44389         https://bugs.webkit.org/show_bug.cgi?id=99247
44390
44391         Reviewed by Ryosuke Niwa.
44392
44393         The special case was added in http://trac.webkit.org/changeset/75293 to
44394         fix a bug with magic iframes. Originally, I planned to remove this
44395         special case, but further investigation reveals that other browsers
44396         throw exceptions for other frame owner elements as well. Now we treat
44397         all frame owner elements the same way.
44398
44399         Test: fast/frames/adopt-object-into-itself.html
44400
44401         * dom/Document.cpp:
44402         (WebCore::Document::adoptNode):
44403
44404 2012-10-16  Dominik Röttsches  <dominik.rottsches@intel.com>
44405
44406         Init timeout flag in ResourceErrorMac
44407         https://bugs.webkit.org/show_bug.cgi?id=99478
44408
44409         Reviewed by Alexey Proskuryakov.
44410
44411         On construction from platform error types, initialize the timeout flag 
44412         to true if the error results from a timeout.
44413
44414         No new tests, covered by tests that will be added in bug 74802.
44415
44416         * platform/network/mac/ResourceErrorMac.mm:
44417         (WebCore::ResourceError::platformLazyInit): Initializing timeout flag if the error was a timeout.
44418
44419 2012-10-16  Tony Chang  <tony@chromium.org>
44420
44421         input[type=range] as a flex item renders thumb at wrong position
44422         https://bugs.webkit.org/show_bug.cgi?id=98666
44423
44424         Reviewed by Ojan Vafai.
44425
44426         Replace RenderSlider implementation with new flexbox and clean up the shadow DOM.
44427         The previous code was trying to set the height to 100% and had a bunch of hacks in
44428         the renderer code to set an explicit height. Using the new flexbox allows us to
44429         remove these renderer hacks.
44430
44431         Test: css3/flexbox/flexitem-stretch-range.html
44432
44433         * css/html.css:
44434         (input[type="range"]::-webkit-slider-container, input[type="range"]::-webkit-media-slider-container): Use new flexbox.
44435         (input[type="range"]::-webkit-slider-runnable-track): Use new flexbox.
44436         (input[type="range"]::-webkit-slider-thumb, input[type="range"]::-webkit-media-slider-thumb): Remove relative positioning since we're
44437         no longer setting top/left in the layout code.
44438         * css/mediaControlsChromium.css: Remove redundant styles and bottom: 1px hack.
44439         * css/mediaControlsChromiumAndroid.css: Remove redundant styles and bottom: 1px hack.
44440         * html/RangeInputType.cpp:
44441         (WebCore::RangeInputType::listAttributeTargetChanged): We need to force a layout
44442         since the height of the control should change when adding/removing a datalist.
44443         * html/shadow/SliderThumbElement.cpp:
44444         (WebCore::RenderSliderContainer::RenderSliderContainer): Use new flexbox.
44445         (WebCore::RenderSliderContainer::computeLogicalHeight): Rather than setting style()->height() in layout, just compute the correct
44446         height when asked.  If we have a datalist, we increase the height (same code as before).  If we're vertical,
44447         we use the intrinsic size.
44448         (WebCore::RenderSliderContainer::layout): Remove extra layout code, but handle the position of the thumb.
44449         This used to be handled in the thumb's layout method, but I deleted that.
44450         * html/shadow/SliderThumbElement.h:
44451         * rendering/RenderSlider.cpp:
44452         (WebCore::RenderSlider::RenderSlider): Use new flexbox.
44453         (WebCore::RenderSlider::layout): Set the limiter size to the size of the thumb. This is necessary
44454         for fast/css/unknown-pseudo-element-matching.html which tries to set the height of the thumb to 1px
44455         and expects the input to also have a height of 1px.  It worked before because the height of the input
44456         didn't depend on the height of its children.
44457         * rendering/RenderSlider.h: Fix indentation.
44458         (RenderSlider): Use new flexible box.
44459
44460 2012-10-16  Dima Gorbik  <dgorbik@apple.com>
44461
44462         Remove Platform.h include from the header files.
44463         https://bugs.webkit.org/show_bug.cgi?id=98665
44464
44465         Reviewed by Eric Seidel.
44466
44467         We don't want other clients that include WebKit headers to know about Platform.h.
44468
44469         No new tests.
44470
44471         * platform/MemoryPressureHandler.h:
44472         * platform/graphics/filters/arm/FECompositeArithmeticNEON.h:
44473         * platform/graphics/filters/arm/FEGaussianBlurNEON.h:
44474         * platform/graphics/filters/arm/FELightingNEON.h:
44475
44476 2012-10-16  Xianzhu Wang  <wangxianzhu@chromium.org>
44477
44478         [Chromium] Android: Need a way to get appropriate font for some specific characters.
44479         https://bugs.webkit.org/show_bug.cgi?id=67587
44480
44481         Reviewed by Adam Barth.
44482
44483         Use the new Skia API SkGetFallbackFamilyNameForChar() to get the family name for individual characters.
44484
44485         No new tests. The following existing tests pass with the change:
44486         fast/writing-mode/vertical-subst-font-vert-no-dflt.html
44487         fast/dynamic/text-combine.html
44488         fast/writing-mode/japanese-rl-text.html
44489         fast/writing-mode/japanese-rl-selection.html
44490         fast/writing-mode/japanese-lr-text.html
44491         fast/repaint/japanese-rl-selection-repaint.html
44492         fast/writing-mode/border-vertical-lr.html
44493
44494         * platform/graphics/chromium/FontCacheAndroid.cpp:
44495         (WebCore::FontCache::getFontDataForCharacters):
44496
44497 2012-10-16  Tommy Widenflycht  <tommyw@google.com>
44498
44499         MediaStream API: Add the chromium API for RTCDataChannel
44500         https://bugs.webkit.org/show_bug.cgi?id=99435
44501
44502         Reviewed by Adam Barth.
44503
44504         Adding WebRTCDataChannel.
44505
44506         Test: fast/mediastream/RTCPeerConnection-datachannel.html
44507
44508         * WebCore.gypi:
44509         * platform/chromium/support/WebRTCDataChannel.cpp: Added.
44510         (WebKit):
44511         (ExtraDataContainer):
44512         (WebKit::ExtraDataContainer::ExtraDataContainer):
44513         (WebKit::ExtraDataContainer::extraData):
44514         (WebKit::WebRTCDataChannel::WebRTCDataChannel):
44515         (WebKit::WebRTCDataChannel::initialize):
44516         (WebKit::WebRTCDataChannel::assign):
44517         (WebKit::WebRTCDataChannel::reset):
44518         (WebKit::WebRTCDataChannel::operator PassRefPtr<WebCore::RTCDataChannelDescriptor>):
44519         (WebKit::WebRTCDataChannel::operator WebCore::RTCDataChannelDescriptor*):
44520         (WebKit::WebRTCDataChannel::extraData):
44521         (WebKit::WebRTCDataChannel::setExtraData):
44522         (WebKit::WebRTCDataChannel::label):
44523         (WebKit::WebRTCDataChannel::reliable):
44524         (WebKit::WebRTCDataChannel::setBufferedAmount):
44525         (WebKit::WebRTCDataChannel::readyStateChanged):
44526         (WebKit::WebRTCDataChannel::dataArrived):
44527         (WebKit::WebRTCDataChannel::error):
44528         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp:
44529         (WebCore::RTCPeerConnectionHandlerChromium::negotiationNeeded):
44530         (WebCore::RTCPeerConnectionHandlerChromium::didGenerateICECandidate):
44531         (WebCore):
44532         (WebCore::RTCPeerConnectionHandlerChromium::didChangeReadyState):
44533         (WebCore::RTCPeerConnectionHandlerChromium::didChangeICEState):
44534         (WebCore::RTCPeerConnectionHandlerChromium::didRemoveRemoteStream):
44535
44536 2012-10-16  Brady Eidson  <beidson@apple.com>
44537
44538         Update indentation in *ResourceLoader headers to match modern WebKit style
44539         https://bugs.webkit.org/show_bug.cgi?id=99487
44540
44541         Reviewed by Beth Dakin.
44542
44543         I'm going to be working on these classes and the indentation is driving me crazy.
44544
44545         * loader/MainResourceLoader.h:
44546         (WebCore):
44547         (MainResourceLoader):
44548         (WebCore::MainResourceLoader::isLoadingMultipartContent):
44549
44550         * loader/NetscapePlugInStreamLoader.h:
44551         (WebCore):
44552         (NetscapePlugInStreamLoaderClient):
44553         (WebCore::NetscapePlugInStreamLoaderClient::didFinishLoading):
44554         (WebCore::NetscapePlugInStreamLoaderClient::wantsAllStreams):
44555         (WebCore::NetscapePlugInStreamLoaderClient::~NetscapePlugInStreamLoaderClient):
44556         (NetscapePlugInStreamLoader):
44557
44558         * loader/ResourceLoader.h:
44559         (WebCore):
44560         (ResourceLoader):
44561         (WebCore::ResourceLoader::documentLoader):
44562         (WebCore::ResourceLoader::originalRequest):
44563         (WebCore::ResourceLoader::identifier):
44564         (WebCore::ResourceLoader::didReceiveCachedMetadata):
44565         (WebCore::ResourceLoader::willStopBufferingData):
44566         (WebCore::ResourceLoader::shouldUseCredentialStorage):
44567         (WebCore::ResourceLoader::didReceiveAuthenticationChallenge):
44568         (WebCore::ResourceLoader::didCancelAuthenticationChallenge):
44569         (WebCore::ResourceLoader::canAuthenticateAgainstProtectionSpace):
44570         (WebCore::ResourceLoader::receivedCancellation):
44571         (WebCore::ResourceLoader::url):
44572         (WebCore::ResourceLoader::handle):
44573         (WebCore::ResourceLoader::sendResourceLoadCallbacks):
44574         (WebCore::ResourceLoader::reachedTerminalState):
44575         (WebCore::ResourceLoader::request):
44576         (WebCore::ResourceLoader::cancelled):
44577         (WebCore::ResourceLoader::defersLoading):
44578
44579 2012-10-16  Beth Dakin  <bdakin@apple.com>
44580
44581         https://bugs.webkit.org/show_bug.cgi?id=99254
44582         Make ScrollingTree an actual tree of nodes, and have it reflect the 
44583         ScrollingStateTree
44584
44585         Reviewed by Simon Fraser.
44586
44587         This patch finally makes the ScrollingTree over on the 
44588         ScrollingThread aware of the changes that we have been making to the 
44589         ScrollingStateTree.
44590
44591         First, it makes ScrollingTreeNode a much more generic class, similar 
44592         to ScrollingStateNode. It is an abstract class and we will add other 
44593         types of nodes such as ScrollingTreeFixedNodes that will inherit from 
44594         this class. 
44595
44596         All of the scrolling functionality that was in ScrollingTreeNode has 
44597         been moved to ScrollingTreeScrollingNode. And likewise, 
44598         ScrollingTreeNodeMac has been re-named to 
44599         ScrollingTreeScrollingNodeMac. 
44600
44601         And finally, instead of just updating and creating the root node, 
44602         ScrollingTree now recurses through the whole ScrollingStateTree to 
44603         create and update a full tree of nodes.
44604
44605         New files and moves files.
44606         * WebCore.xcodeproj/project.pbxproj:
44607
44608         Add a getter for the children vector since we need to recurse it in 
44609         ScrollingTree.
44610         * page/scrolling/ScrollingStateNode.h:
44611         (WebCore::ScrollingStateNode::children):
44612         (ScrollingStateNode):
44613
44614         m_rootNode is now a ScrollingTreeScrollingNode.
44615         * page/scrolling/ScrollingTree.cpp:
44616         (WebCore::ScrollingTree::ScrollingTree):
44617
44618         Instead of just updating the root node, call two new functions that 
44619         will take care of updating the whole tree.
44620         (WebCore::ScrollingTree::commitNewTreeState):
44621
44622         This function ecurses through the ScrollingStateTree and updates the 
44623         corresponding ScrollingTreeNodes.
44624         (WebCore::ScrollingTree::updateNodesFromStateNode):
44625
44626         This function takes the ScrollingStateTree's list of removed nodes 
44627         and removes the corresponding nodes from the ScrollingTree. It will 
44628         destroy the nodes after removing it as long as it's not the root 
44629         node. I think it's the safest choice for now to never remove the root 
44630         node. 
44631         (WebCore::ScrollingTree::removeDestroyedNodes):
44632
44633         ScrollingTree now keeps a HashMap mapping ScrollingNodeIDs to 
44634         ScrollingTreeNodes.
44635         * page/scrolling/ScrollingTree.h:
44636
44637         All of the scrolling-related functionality has been moved from this 
44638         class to new class ScrollingTreeScrollingNode. And some basic tree 
44639         traversal functionality has been added.
44640         * page/scrolling/ScrollingTreeNode.cpp:
44641         (WebCore::ScrollingTreeNode::ScrollingTreeNode):
44642         (WebCore::ScrollingTreeNode::appendChild):
44643         (WebCore::ScrollingTreeNode::removeChild):
44644         * page/scrolling/ScrollingTreeNode.h:
44645         (WebCore):
44646         (ScrollingTreeNode):
44647         (WebCore::ScrollingTreeNode::scrollingNodeID):
44648         (WebCore::ScrollingTreeNode::setScrollingNodeID):
44649         (WebCore::ScrollingTreeNode::parent):
44650         (WebCore::ScrollingTreeNode::setParent):
44651         (WebCore::ScrollingTreeNode::scrollingTree):
44652
44653         This class contains all of the scrolling-related work that used to be 
44654         done in ScrollingTreeNode.
44655         * page/scrolling/ScrollingTreeScrollingNode.cpp: Added.
44656         (WebCore):
44657         (WebCore::ScrollingTreeScrollingNode::ScrollingTreeScrollingNode):
44658         (WebCore::ScrollingTreeScrollingNode::~ScrollingTreeScrollingNode):
44659         (WebCore::ScrollingTreeScrollingNode::update):
44660         * page/scrolling/ScrollingTreeScrollingNode.h: Added.
44661         (WebCore):
44662         (ScrollingTreeScrollingNode):
44663         (WebCore::ScrollingTreeScrollingNode::shouldUpdateScrollLayerPositionOnMainThread):
44664         (WebCore::ScrollingTreeScrollingNode::viewportRect):
44665         (WebCore::ScrollingTreeScrollingNode::contentsSize):
44666         (WebCore::ScrollingTreeScrollingNode::horizontalScrollElasticity):
44667         (WebCore::ScrollingTreeScrollingNode::verticalScrollElasticity):
44668         (WebCore::ScrollingTreeScrollingNode::hasEnabledHorizontalScrollbar):
44669         (WebCore::ScrollingTreeScrollingNode::hasEnabledVerticalScrollbar):
44670         (WebCore::ScrollingTreeScrollingNode::canHaveScrollbars):
44671         (WebCore::ScrollingTreeScrollingNode::scrollOrigin):
44672
44673         I noticed this whitespace error and had to fix it.
44674         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
44675         (WebCore::ScrollingCoordinatorMac::detachFromStateTree):
44676
44677         Include ScrollingTreeScrollingNodeMac.h instead of 
44678         ScrollingTreeNodeMac.h
44679         * page/scrolling/mac/ScrollingTreeMac.mm:
44680
44681         This class was just re-named.
44682         * page/scrolling/mac/ScrollingTreeNodeMac.h: Removed.
44683         * page/scrolling/mac/ScrollingTreeNodeMac.mm: Removed.
44684         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.h: Copied from page/scrolling/mac/ScrollingTreeNodeMac.h.
44685         (ScrollingTreeScrollingNodeMac):
44686         * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm: Copied from page/scrolling/mac/ScrollingTreeNodeMac.mm.
44687         (WebCore::ScrollingTreeScrollingNode::create):
44688         (WebCore::ScrollingTreeScrollingNodeMac::ScrollingTreeScrollingNodeMac):
44689         (WebCore::ScrollingTreeScrollingNodeMac::~ScrollingTreeScrollingNodeMac):
44690         (WebCore::ScrollingTreeScrollingNodeMac::update):
44691         (WebCore::ScrollingTreeScrollingNodeMac::handleWheelEvent):
44692         (WebCore::ScrollingTreeScrollingNodeMac::allowsHorizontalStretching):
44693         (WebCore::ScrollingTreeScrollingNodeMac::allowsVerticalStretching):
44694         (WebCore::ScrollingTreeScrollingNodeMac::stretchAmount):
44695         (WebCore::ScrollingTreeScrollingNodeMac::pinnedInDirection):
44696         (WebCore::ScrollingTreeScrollingNodeMac::canScrollHorizontally):
44697         (WebCore::ScrollingTreeScrollingNodeMac::canScrollVertically):
44698         (WebCore::ScrollingTreeScrollingNodeMac::shouldRubberBandInDirection):
44699         (WebCore::ScrollingTreeScrollingNodeMac::absoluteScrollPosition):
44700         (WebCore::ScrollingTreeScrollingNodeMac::immediateScrollBy):
44701         (WebCore::ScrollingTreeScrollingNodeMac::immediateScrollByWithoutContentEdgeConstraints):
44702         (WebCore::ScrollingTreeScrollingNodeMac::startSnapRubberbandTimer):
44703         (WebCore::ScrollingTreeScrollingNodeMac::stopSnapRubberbandTimer):
44704         (WebCore::ScrollingTreeScrollingNodeMac::scrollPosition):
44705         (WebCore::ScrollingTreeScrollingNodeMac::setScrollPosition):
44706         (WebCore::ScrollingTreeScrollingNodeMac::setScrollPositionWithoutContentEdgeConstraints):
44707         (WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):
44708         (WebCore::ScrollingTreeScrollingNodeMac::minimumScrollPosition):
44709         (WebCore::ScrollingTreeScrollingNodeMac::maximumScrollPosition):
44710         (WebCore::ScrollingTreeScrollingNodeMac::scrollBy):
44711         (WebCore::ScrollingTreeScrollingNodeMac::scrollByWithoutContentEdgeConstraints):
44712         (WebCore::ScrollingTreeScrollingNodeMac::updateMainFramePinState):
44713         (WebCore::ScrollingTreeScrollingNodeMac::logExposedUnfilledArea):
44714
44715 2012-10-16  Simon Fraser  <simon.fraser@apple.com>
44716
44717         Add a new layer type for the page tiled cache layer
44718         https://bugs.webkit.org/show_bug.cgi?id=99491
44719
44720         Reviewed by Dean Jackson.
44721
44722         In preparation for using tile cache layers in place of CATiledLayer,
44723         add a new PlatformCALayer layer type LayerTypePageTileCacheLayer,
44724         since the page tile cache will have some different behavior from
44725         other tile cache layers.
44726         
44727         Generalize code that was looking at LayerTypeTileCacheLayer to use
44728         usesTileCacheLayer() if it applies to both types of tile caches.
44729
44730         * platform/graphics/ca/GraphicsLayerCA.cpp:
44731         (WebCore::GraphicsLayerCA::GraphicsLayerCA):
44732         (WebCore::GraphicsLayerCA::recursiveCommitChanges): Show the tile
44733         wash for tiled layers as well as layers with transforms (the tile
44734         wash is just for debugging).
44735         (WebCore::GraphicsLayerCA::platformCALayerDidCreateTiles):
44736         (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
44737         * platform/graphics/ca/PlatformCALayer.h:
44738         (WebCore::PlatformCALayer::usesTileCacheLayer):
44739         (PlatformCALayer):
44740         * platform/graphics/ca/mac/PlatformCALayerMac.mm:
44741         (PlatformCALayer::PlatformCALayer):
44742         (PlatformCALayer::~PlatformCALayer):
44743         (PlatformCALayer::tiledBacking):
44744         * platform/graphics/mac/WebLayer.mm:
44745         (drawLayerContents): Avoid double-drawing the repaint counter in tile cache layers.
44746
44747 2012-10-16  Stephen Chenney  <schenney@chromium.org> 
44748         An feImage that tries to render itself should be stopped
44749         https://bugs.webkit.org/show_bug.cgi?id=94652
44750
44751         Reviewed by Eric Seidel.
44752
44753         An SVG feImage filter element will accept, as the src to render, an
44754         SVG document that makes use of the feImage itself. This causes the
44755         feImage to try to draw itself while already in the process of drawing
44756         itself. Various problems arise from this. The invariant we wish to
44757         maintain is that no element in the src tree of an feImage element
44758         refers to that feImage.
44759
44760         This patch adds a flag to all FilterData objects that tracks whether or
44761         not the filter is currently applying itself, and avoids applying the
44762         filter recursively.
44763
44764         While it may seem better to catch this problem when the src is set, or
44765         when the filter is built, that turns out to be challenging and
44766         inefficient. Say we choose to test when the src atttribute is set. To
44767         do so would require looking through all of the DOM nodes that will be
44768         rendered for the src, finding all resources used, and checking if any
44769         of them make use fo the feImage element that we are setting the source
44770         for. The infrastructure is not in place to do that, and it would
44771         involve walking a potentially very large portion of the DOM in order
44772         to detect a very rare situation. Note that it is not enough just to
44773         walk the DOM directly under the src; we also need to recursively follow any
44774         resource links to see if they use the feImage (e.g. patterns or
44775         masks or use or ...).
44776
44777         If we instead try to use the renderer node to find self referencing,
44778         we need to recursively walk a potentially very large render tree,
44779         tracing all resources in search of the feImage. This would need to be
44780         done every time the filter is built, which is again a significant
44781         overhead for a situation that is very unlikely to occur. And we do not
44782         have methods that make it easy to find feImage filter effect nodes; they are
44783         hidden behind filter resource nodes.
44784
44785         Hence the runtime check to catch the problem. The check must be in
44786         FilterData and RenderSVGResourceFilter code because we must prevent
44787         the destruction of the feImage when we encounter it recursively.
44788
44789         This patch also renames FilterData::builded to FilterData::isBuilt.
44790
44791         Test: svg/filters/feImage-self-referencing.html
44792
44793         * rendering/svg/RenderSVGResourceFilter.cpp:
44794         (WebCore::ApplyingFilterEffectGuard): Guard to ensure that, in the future, we always
44795         clear the isApplying flag even if the postApplyResource method returns early.
44796         (WebCore::RenderSVGResourceFilter::applyResource): Do not apply a resource that is already applying and
44797         rename builded to isBuilt.
44798         (WebCore::RenderSVGResourceFilter::postApplyResource): Mark a resource as applying and clear after
44799         it is done. Abort if a resource is already applying when the method begins. Rename builded to isBuilt.
44800         (WebCore::RenderSVGResourceFilter::primitiveAttributeChanged): Rename builded to isBuilt.
44801         * rendering/svg/RenderSVGResourceFilter.h:
44802         (WebCore::FilterData::FilterData):
44803         (FilterData): Add isApplying and rename builded to isBuilt.
44804
44805 2012-10-16  Nate Chapin  <japhet@chromium.org>
44806
44807         sendResourceLoadCallbacks() is poorly named
44808         https://bugs.webkit.org/show_bug.cgi?id=99482
44809
44810         Reviewed by Alexey Proskuryakov.
44811
44812         In both CachedResource and ResourceLoader, rename sendResourceLoadCallbacks()
44813         to shouldSendResourceLoadCallbacks() to better indicate that it is a simple getter.
44814
44815         No new tests, simple renaming.
44816
44817         * loader/FrameLoader.cpp:
44818         (WebCore::FrameLoader::loadedResourceFromMemoryCache):
44819         * loader/ResourceLoader.h:
44820         (WebCore::ResourceLoader::shouldSendResourceLoadCallbacks):
44821         * loader/cache/CachedResource.h:
44822         (WebCore::CachedResource::shouldSendResourceLoadCallbacks):
44823
44824 2012-10-16  Chris Rogers  <crogers@google.com>
44825
44826         Rename some AudioNodes
44827         https://bugs.webkit.org/show_bug.cgi?id=99358
44828
44829         Reviewed by Daniel Bates.
44830
44831         Here's a list of the node names, showing the changing ones:
44832             AudioBufferSourceNode
44833             MediaElementAudioSourceNode
44834             MediaStreamAudioSourceNode
44835             JavaScriptAudioNode ------------> ScriptProcessorNode
44836             RealtimeAnalyserNode ------------> AnalyserNode
44837             AudioGainNode ------------> GainNode
44838             DelayNode
44839             BiquadFilterNode
44840             AudioPannerNode ------------> PannerNode
44841             ConvolverNode
44842             AudioChannelSplitter ------------> ChannelSplitterNode
44843             AudioChannelMerger ------------> ChannelMergerNode
44844             DynamicsCompressorNode
44845             Oscillator ------------> OscillatorNode
44846
44847         * CMakeLists.txt:
44848         * DerivedSources.make:
44849         * DerivedSources.pri:
44850         * GNUmakefile.list.am:
44851         * Modules/webaudio/AnalyserNode.cpp: Renamed from Source/WebCore/Modules/webaudio/RealtimeAnalyserNode.cpp.
44852         * Modules/webaudio/AnalyserNode.idl: Renamed from Source/WebCore/Modules/webaudio/RealtimeAnalyserNode.idl.
44853         * Modules/webaudio/AudioBufferSourceNode.cpp:
44854         (WebCore::AudioBufferSourceNode::setPannerNode):
44855         * Modules/webaudio/AudioBufferSourceNode.h:
44856         (AudioBufferSourceNode):
44857         * Modules/webaudio/AudioContext.cpp:
44858         (WebCore::AudioContext::createJavaScriptNode):
44859         (WebCore::AudioContext::createPanner):
44860         (WebCore::AudioContext::createAnalyser):
44861         (WebCore::AudioContext::createGainNode):
44862         (WebCore::AudioContext::createChannelSplitter):
44863         (WebCore::AudioContext::createChannelMerger):
44864         (WebCore::AudioContext::createOscillator):
44865         * Modules/webaudio/AudioContext.h:
44866         (WebCore):
44867         (AudioContext):
44868         * Modules/webaudio/AudioContext.idl:
44869         * Modules/webaudio/ChannelMergerNode.cpp: Renamed from Source/WebCore/Modules/webaudio/AudioChannelMerger.cpp.
44870         * Modules/webaudio/ChannelMergerNode.h: Renamed from Source/WebCore/Modules/webaudio/AudioChannelMerger.h.
44871         (WebCore):
44872         (ChannelMergerNode):
44873         * Modules/webaudio/ChannelMergerNode.idl: Renamed from Source/WebCore/Modules/webaudio/AudioChannelMerger.idl.
44874         * Modules/webaudio/ChannelSplitterNode.cpp: Renamed from Source/WebCore/Modules/webaudio/AudioChannelSplitter.cpp.
44875         * Modules/webaudio/ChannelSplitterNode.h: Renamed from Source/WebCore/Modules/webaudio/AudioChannelSplitter.h.
44876         (WebCore):
44877         (ChannelSplitterNode):
44878         * Modules/webaudio/ChannelSplitterNode.idl: Renamed from Source/WebCore/Modules/webaudio/AudioChannelSplitter.idl.
44879         * Modules/webaudio/DOMWindowWebAudio.idl:
44880         * Modules/webaudio/GainNode.cpp: Renamed from Source/WebCore/Modules/webaudio/AudioGainNode.cpp.
44881         * Modules/webaudio/GainNode.h: Renamed from Source/WebCore/Modules/webaudio/AudioGainNode.h.
44882         * Modules/webaudio/GainNode.idl: Renamed from Source/WebCore/Modules/webaudio/AudioGainNode.idl.
44883         * Modules/webaudio/OscillatorNode.cpp: Renamed from Source/WebCore/Modules/webaudio/Oscillator.cpp.
44884         * Modules/webaudio/OscillatorNode.h: Renamed from Source/WebCore/Modules/webaudio/Oscillator.h.
44885         * Modules/webaudio/OscillatorNode.idl: Renamed from Source/WebCore/Modules/webaudio/Oscillator.idl.
44886         * Modules/webaudio/PannerNode.cpp: Renamed from Source/WebCore/Modules/webaudio/AudioPannerNode.cpp.
44887         * Modules/webaudio/PannerNode.h: Renamed from Source/WebCore/Modules/webaudio/AudioPannerNode.h.
44888         (WebCore):
44889         * Modules/webaudio/PannerNode.idl: Renamed from Source/WebCore/Modules/webaudio/AudioPannerNode.idl.
44890         * Modules/webaudio/ScriptProcessorNode.cpp: Renamed from Source/WebCore/Modules/webaudio/JavaScriptAudioNode.cpp.
44891         * Modules/webaudio/ScriptProcessorNode.h: Renamed from Source/WebCore/Modules/webaudio/JavaScriptAudioNode.h.
44892         (WebCore):
44893         * Modules/webaudio/ScriptProcessorNode.idl: Renamed from Source/WebCore/Modules/webaudio/JavaScriptAudioNode.idl.
44894         * Modules/webaudio/WaveTable.cpp:
44895         (WebCore::WaveTable::createSine):
44896         (WebCore::WaveTable::createSquare):
44897         (WebCore::WaveTable::createSawtooth):
44898         (WebCore::WaveTable::createTriangle):
44899         (WebCore::WaveTable::generateBasicWaveform):
44900         * Target.pri:
44901         * UseJSC.cmake:
44902         * WebCore.gypi:
44903         * WebCore.xcodeproj/project.pbxproj:
44904         * bindings/js/JSScriptProcessorNodeCustom.cpp: Renamed from Source/WebCore/bindings/js/JSJavaScriptAudioNodeCustom.cpp.
44905         (WebCore):
44906         (WebCore::JSScriptProcessorNode::visitChildren):
44907         * dom/EventTarget.h:
44908         (WebCore):
44909         * dom/EventTargetFactory.in:
44910
44911 2012-10-16  Noam Rosenthal  <noam.rosenthal@nokia.com>
44912
44913         [Texmap] Refactor TextureMapperShaderManager to be clearer
44914         https://bugs.webkit.org/show_bug.cgi?id=86048
44915
44916         Reviewed by Martin Robinson.
44917
44918         Previous implementation of TextureMapperShaderManager was very verbose, calling for too
44919         many casts and ambiguous ownership.
44920         This refactor does the following:
44921         1. TextureMapperShaderProgram is one class without subclasses.
44922         2. Uniform/Attribute accessors are generated by special macros (TEXMAP_DECLARE_...) that
44923            generate both the C++ access function, as well as the GLSL name of the variable. This
44924            allows adding/removing variables from a shader without adding broiler-plate code like
44925            before.
44926
44927         After this change TextureMapperShaderManager has only one responsibility - dealing with
44928         TextureMapperGL's built-in shaders and their lifecycle. Preparing filters etc. is done
44929         in TextureMapperGL.
44930
44931         This is a refactor without new functionality. It has been verified to not break any existing
44932         relevant test.
44933
44934         * platform/graphics/texmap/TextureMapperGL.cpp:
44935         (WebCore::TextureMapperGL::drawBorder):
44936         (WebCore::TextureMapperGL::drawQuad):
44937         (WebCore::TextureMapperGL::drawTextureRectangleARB):
44938         (WebCore::TextureMapperGL::drawTexture):
44939         (WebCore::TextureMapperGL::drawTextureWithAntialiasing):
44940         (WebCore::TextureMapperGL::drawTexturedQuadWithProgram):
44941         (WebCore::TextureMapperGL::beginClip):
44942             Use the MACRO-generated uniform accessors.
44943
44944         (WebCore):
44945         (WebCore::keyForFilterType):
44946         (WebCore::getPassesRequiredForFilter):
44947         (WebCore::gauss):
44948         (WebCore::gaussianKernel):
44949         (WebCore::prepareFilterProgram):
44950         (WebCore::TextureMapperGL::drawFiltered):
44951         (WebCore::BitmapTextureGL::applyFilters):
44952             Move the filter logic to TextureMapperGL
44953
44954         * platform/graphics/texmap/TextureMapperShaderManager.cpp:
44955         (WebCore::TextureMapperShaderProgram::TextureMapperShaderProgram):
44956         (WebCore::TextureMapperShaderProgram::getLocation):
44957         (ShaderSpec):
44958         (WebCore::ShaderSpec::ShaderSpec):
44959         (WebCore::getShaderSpec):
44960         (WebCore::TextureMapperShaderManager::TextureMapperShaderManager):
44961         (WebCore::TextureMapperShaderManager::~TextureMapperShaderManager):
44962         (WebCore::TextureMapperShaderManager::getShaderProgram):
44963         * platform/graphics/texmap/TextureMapperShaderManager.h:
44964         (WebCore):
44965         (WebCore::TextureMapperShaderProgram::programID):
44966         (WebCore::TextureMapperShaderProgram::context):
44967         (WebCore::TextureMapperShaderProgram::create):
44968         (TextureMapperShaderProgram):
44969         (TextureMapperShaderManager):
44970             See description.
44971
44972 2012-10-16  Nico Weber  <thakis@chromium.org>
44973
44974         [chromium/mac] Make spelling indicator HighDPI
44975         https://bugs.webkit.org/show_bug.cgi?id=99417
44976
44977         Reviewed by Stephen White.
44978
44979         This is the mac version of http://trac.webkit.org/changeset/130940
44980         Since the mac and non-mac code are very similar again, merge the two
44981         code paths again.
44982
44983         Covered by editing/spelling/(inline-spelling|grammar)-markers-hidpi.html
44984
44985         * platform/graphics/skia/GraphicsContextSkia.cpp:
44986         (WebCore::GraphicsContext::drawLineForDocumentMarker):
44987
44988 2012-10-16  Tony Chang  <tony@chromium.org>
44989
44990         in a column flexbox, input overflows the box when stretched
44991         https://bugs.webkit.org/show_bug.cgi?id=99273
44992
44993         Reviewed by Ojan Vafai.
44994
44995         Fix a bug where we didn't properly subtract padding and border when overriding the child size.
44996         We didn't see this because of a performance optimization in RenderBox where we stretch children.
44997         Also apply this performance optimization in new flexbox for form controls.
44998
44999         Test: css3/flexbox/stretch-input-in-column.html
45000
45001         * rendering/RenderBox.cpp:
45002         (WebCore::flexboxChildHasStretchAlignment):
45003         (WebCore::isStretchingVerticalFlexboxChild):
45004         (WebCore::RenderBox::sizesLogicalWidthToFitContent): Apply performance optimization to form controls in new flexbox.
45005         * rendering/RenderFlexibleBox.cpp:
45006         (WebCore::RenderFlexibleBox::applyStretchAlignmentToChild): Properly subtract border and padding.
45007
45008 2012-10-16  Simon Fraser  <simon.fraser@apple.com>
45009
45010         REGRESSION (r128787): Fixed position div causes other elements to not update correctly
45011         https://bugs.webkit.org/show_bug.cgi?id=98579
45012
45013         Reviewed by Beth Dakin.
45014
45015         RenderLayers cache repaint rects which are computed relative to the repaint container.
45016         Repaint containers depend on whether a RenderLayerBacking has its own backing store,
45017         so if that changes, we need to recompute repaint rects for all descendants.
45018         
45019         Test: compositing/repaint/requires-backing-repaint.html
45020
45021         * rendering/RenderLayerBacking.cpp:
45022         (WebCore::RenderLayerBacking::setRequiresOwnBackingStore):
45023
45024 2012-10-16  Zan Dobersek  <zandobersek@gmail.com>
45025
45026         [GStreamer] GstBuffer ref race in WebKitWebAudioSrcLoop
45027         https://bugs.webkit.org/show_bug.cgi?id=95833
45028
45029         Reviewed by Philippe Normand.
45030
45031         The render bus used in GStreamer's implementation of AudioDestination no longer
45032         allocates memory for each of its channels. Rather than that, when looping, the
45033         data is rendered into a channel-specific GstBuffer. Each buffer is then chained
45034         to the appropriate GstPad, as has been the case before.
45035
45036         No new tests - there are tests covering this change but they are not yet working
45037         on the GTK port or any other GStreamer implementation of Web Audio.
45038
45039         * platform/audio/gstreamer/AudioDestinationGStreamer.cpp:
45040         (WebCore::AudioDestinationGStreamer::AudioDestinationGStreamer):
45041         * platform/audio/gstreamer/WebKitWebAudioSourceGStreamer.cpp:
45042         (_WebKitWebAudioSourcePrivate): Remove an unused member variable.
45043         (webkit_web_audio_src_init): Remove an unnecessary line.
45044         (webKitWebAudioSrcConstructed): Ditto.
45045         (webKitWebAudioSrcLoop):
45046
45047 2012-10-16  Pablo Flouret  <pablof@motorola.com>
45048
45049         Pre-process CSSGrammar.y before running through bison.
45050         https://bugs.webkit.org/show_bug.cgi?id=94290
45051
45052         Reviewed by Tony Chang.
45053
45054         Running CSSGrammar.y through a preprocessor allows the use of feature
45055         defines in all places of the yacc file (i.e. not just in C blocks).
45056         Mostly useful to be able to keep every part of a feature under feature
45057         flags for self-documenting purposes.
45058
45059         No new tests, CSSGrammar.y should be generated correctly and everything
45060         should keep working as before.
45061
45062         * CMakeLists.txt:
45063         * DerivedSources.make:
45064         * DerivedSources.pri:
45065         * GNUmakefile.am:
45066             Modify build systems to use makegrammar.pl to generate the .y files
45067             and run those through bison.
45068
45069         * WebCore.gyp/WebCore.gyp:
45070             Add a new action to preprocess the CSSGrammar.y.in file before the
45071             bison rule is run.
45072
45073         * WebCore.vcproj/WebCore.vcproj:
45074         * WebCore.xcodeproj/project.pbxproj:
45075             Add the new .y.in / .y.includes files.
45076
45077         * css/CSSGrammar.y.in: Renamed from Source/WebCore/css/CSSGrammar.y.
45078             Also moved the top declarations section that has includes, defines,
45079             etc. to its own file. These shouldn't be touched by the first
45080             pass of the preprocessor. And changed the existing ENABLE(FEATURE)
45081             ifdefs to ENABLE_FEATURE since the ENABLE() macro is not available
45082             yet.
45083         * css/CSSGrammar.y.includes: Added.
45084             The aforementioned declarations header section. After the .y.in file
45085             is processed it will be concatenated with this one to make the
45086             CSSGrammar.y file.
45087
45088         * css/makegrammar.pl:
45089             Modify the script to handle .y.in files.
45090
45091 2012-10-16  Raphael Kubo da Costa  <raphael.kubo.da.costa@intel.com>
45092
45093         Implement testRunner.dumpSelectionRect() in WebKitTestRunner
45094         https://bugs.webkit.org/show_bug.cgi?id=69545
45095
45096         Reviewed by Simon Fraser.
45097
45098         * WebCore.exp.in:
45099
45100 2012-10-16  Allan Sandfeld Jensen  <allan.jensen@digia.com>
45101
45102         [Qt] Implement fastBoundingPath/boundingPath distinction.
45103         https://bugs.webkit.org/show_bug.cgi?id=99471
45104
45105         Reviewed by Noam Rosenthal.
45106
45107         Tested by existing test: svg/custom/getBBox-path.svg
45108
45109         * platform/graphics/Path.cpp:
45110         * platform/graphics/qt/PathQt.cpp:
45111         (WebCore::Path::fastBoundingRect):
45112         (WebCore::Path::boundingRect):
45113
45114 2012-10-16  Rob Buis  <rbuis@rim.com>
45115
45116         [BlackBerry] replace BlackBerry::Platform::log() with BBLOG()
45117         https://bugs.webkit.org/show_bug.cgi?id=99302
45118
45119         Reviewed by Yong Li.
45120
45121         Fix a warning introduced by r131335. Since in release BBLOG is empty, only enable this block in debug builds.
45122
45123         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
45124         (WebCore::GraphicsContext3D::compileShader):
45125
45126 2012-10-16  Antoine Quint  <graouts@apple.com>
45127
45128         Inspector should allow reading the compositing debug settings
45129         https://bugs.webkit.org/show_bug.cgi?id=99458
45130
45131         Reviewed by Timothy Hatcher.
45132
45133         * inspector/Inspector.json:
45134         * inspector/InspectorPageAgent.cpp:
45135         (WebCore::InspectorPageAgent::getCompositingBordersVisible):
45136         * inspector/InspectorPageAgent.h:
45137
45138 2012-10-16  Dan Bernstein  <mitz@apple.com>
45139
45140         Code to reverse a GlyphBuffer range is repeated in several places
45141         https://bugs.webkit.org/show_bug.cgi?id=99424
45142
45143         Reviewed by Adele Peterson.
45144
45145         * platform/graphics/FontFastPath.cpp:
45146         (WebCore::Font::getGlyphsAndAdvancesForSimpleText): Replaced for loop with a call to
45147         GlyphBuffer::reverse.
45148         * platform/graphics/GlyphBuffer.h:
45149         (WebCore::GlyphBuffer::reverse): Added. Reverses the given range.
45150         (WebCore::GlyphBuffer::swap): Made private.
45151         * platform/graphics/WidthIterator.cpp:
45152         (WebCore::applyFontTransforms): Replaced for loops with calls to GlyphBuffer::reverse and
45153         corrected their bounds.
45154         * platform/graphics/mac/FontComplexTextMac.cpp:
45155         (WebCore::Font::getGlyphsAndAdvancesForComplexText): Replaced for loop with a call to
45156         GlyphBuffer::range.
45157
45158 2012-10-16  Nate Chapin  <japhet@chromium.org>
45159
45160         Re-order CachedRawResource::data() to set m_data earlier
45161         https://bugs.webkit.org/show_bug.cgi?id=99361
45162
45163         Reviewed by Adam Barth.
45164
45165         Currently, we calculate the diff between the data parameter and m_data, call
45166         dataReceived(), then set m_data to data. If something inside dataReceived()
45167         tries to access m_data via CachedResource::resourceBuffer(), it will see the
45168         old data instead of the new data, which seems inconsistent.
45169
45170         No new tests, as no one appears to try to access m_data within dataReceived() currently.
45171
45172         * loader/cache/CachedRawResource.cpp:
45173         (WebCore::CachedRawResource::data):
45174
45175 2012-10-16  Julien Chaffraix  <jchaffraix@webkit.org>
45176
45177         Fold setCellLogicalWidths logic into RenderTableSection layout
45178         https://bugs.webkit.org/show_bug.cgi?id=99382
45179
45180         Reviewed by Eric Seidel.
45181
45182         setCellLogicalWidths was implemented as a pre-phase to laying out
45183         the table's sections. This split was artificial as any change in
45184         the columns' logical width should trigger a sections' relayout, which
45185         could propagate and mark the cells / rows as needed.
45186
45187         Merging setCellLogicalWidths into RenderTableSection::layout removes
45188         an unneeded cells walking and some clunkiness from our implementation.
45189
45190         Refactoring covered by the existing tests.
45191
45192         * rendering/RenderTable.cpp:
45193         (WebCore::RenderTable::RenderTable): Initialize our new boolean.
45194         (WebCore::RenderTable::layout):
45195         If m_columnLogicalWidthChanged, we force a relayout on our sections so that the cells and rows
45196         are marked for layout if there is the logical width change.
45197
45198         * rendering/RenderTable.h:
45199         (WebCore::RenderTable):
45200         Added a new boolean to track if a column logical width changed (m_columnLogicalWidthChanged).
45201
45202         (WebCore::RenderTable::setColumnPosition):
45203         If a column position changed, register that our column logical widths changed. This is not
45204         totally true, so added a comment about when it will be wrong.
45205
45206         * rendering/RenderTableCell.h:
45207         * rendering/RenderTableCell.cpp:
45208         (WebCore::RenderTableCell::setCellLogicalWidth):
45209         Updated the function to mark the cell and the row for layout. Also changed the argument to
45210         be an 'int' as this was what was passed in.
45211
45212         * rendering/RenderTableSection.cpp:
45213         (WebCore::RenderTableSection::layout):
45214         * rendering/RenderTableSection.h:
45215         Removed setCellLogicalWidths and merged the logic into RenderTableSection::layout. We propagate
45216         the table layout's logical widths first so that rows are marked as needing layout as appropriate.
45217
45218 2012-10-16  Takashi Sakamoto  <tasak@google.com>
45219
45220         [Meta] [Shadow] contenteditable attribute for distributed nodes.
45221         https://bugs.webkit.org/show_bug.cgi?id=90017
45222
45223         Reviewed by Dimitri Glazkov.
45224
45225         If an element is distributed to an insertion point, the element's
45226         webkit-user-modify is inherited from its shadow host.
45227
45228         No new tests, because the existing test: user-modify-inheritance.html
45229         covers this change.
45230
45231         * css/StyleResolver.cpp:
45232         (WebCore::StyleResolver::styleForElement):
45233         After an element inherits a style from its parent, override user-modify
45234         by using the shadow host's style if the element is distributed.
45235
45236 2012-10-16  Vsevolod Vlasov  <vsevik@chromium.org>
45237
45238         Web Inspector: Get rid of (now empty) JavaScriptSource and StyleSource, rename all usages to UISourceCode.
45239         https://bugs.webkit.org/show_bug.cgi?id=99469
45240
45241         Reviewed by Pavel Feldman.
45242
45243         * WebCore.gypi:
45244         * WebCore.vcproj/WebCore.vcproj:
45245         * inspector/compile-front-end.py:
45246         * inspector/front-end/BreakpointManager.js:
45247         (WebInspector.BreakpointManager.prototype._uiSourceCodeAdded):
45248         (WebInspector.BreakpointManager.prototype._uiSourceCodeRemoved):
45249         * inspector/front-end/CompilerScriptMapping.js:
45250         * inspector/front-end/JavaScriptSource.js: Removed.
45251         * inspector/front-end/JavaScriptSourceFrame.js:
45252         (WebInspector.JavaScriptSourceFrame):
45253         (WebInspector.JavaScriptSourceFrame.prototype.canEditSource):
45254         (WebInspector.JavaScriptSourceFrame.prototype._onWorkingCopyChanged):
45255         (WebInspector.JavaScriptSourceFrame.prototype._onWorkingCopyCommitted):
45256         (WebInspector.JavaScriptSourceFrame.prototype._innerSetContent):
45257         (WebInspector.JavaScriptSourceFrame.prototype.populateLineGutterContextMenu):
45258         (WebInspector.JavaScriptSourceFrame.prototype.populateTextAreaContextMenu):
45259         (WebInspector.JavaScriptSourceFrame.prototype.onTextChanged):
45260         (WebInspector.JavaScriptSourceFrame.prototype._supportsEnabledBreakpointsWhileEditing):
45261         (WebInspector.JavaScriptSourceFrame.prototype._restoreBreakpointsAfterEditing):
45262         (WebInspector.JavaScriptSourceFrame.prototype._breakpointAdded):
45263         (WebInspector.JavaScriptSourceFrame.prototype._breakpointRemoved):
45264         (WebInspector.JavaScriptSourceFrame.prototype.onTextEditorContentLoaded):
45265         (WebInspector.JavaScriptSourceFrame.prototype._handleGutterClick):
45266         (WebInspector.JavaScriptSourceFrame.prototype._toggleBreakpoint):
45267         (WebInspector.JavaScriptSourceFrame.prototype._setBreakpoint):
45268         (WebInspector.JavaScriptSourceFrame.prototype._continueToLine):
45269         * inspector/front-end/NetworkUISourceCodeProvider.js:
45270         (WebInspector.NetworkUISourceCodeProvider.prototype._parsedScriptSource):
45271         (WebInspector.NetworkUISourceCodeProvider.prototype._resourceAdded):
45272         * inspector/front-end/ResourceScriptMapping.js:
45273         (WebInspector.ResourceScriptMapping.prototype._getOrCreateTemporaryUISourceCode):
45274         * inspector/front-end/ScriptSnippetModel.js:
45275         (WebInspector.ScriptSnippetModel):
45276         (WebInspector.ScriptSnippetModel.prototype._addScriptSnippet):
45277         (WebInspector.ScriptSnippetModel.prototype.evaluateScriptSnippet.get var):
45278         (WebInspector.ScriptSnippetModel.prototype.evaluateScriptSnippet.compileCallback):
45279         (WebInspector.ScriptSnippetModel.prototype.evaluateScriptSnippet):
45280         (WebInspector.ScriptSnippetModel.prototype._createUISourceCodeForScript):
45281         (WebInspector.ScriptSnippetModel.prototype._removeBreakpoints):
45282         (WebInspector.ScriptSnippetModel.prototype._projectWillReset):
45283         (WebInspector.SnippetScriptFile):
45284         (WebInspector.SnippetScriptFile.prototype._workingCopyCommitted):
45285         (WebInspector.SnippetScriptFile.prototype._workingCopyChanged):
45286         * inspector/front-end/ScriptsNavigator.js:
45287         (WebInspector.SnippetsNavigatorView.prototype._handleEvaluateSnippet):
45288         (WebInspector.SnippetsNavigatorView.prototype._handleRemoveSnippet):
45289         * inspector/front-end/ScriptsPanel.js:
45290         (WebInspector.ScriptsPanel.prototype._createSourceFrame):
45291         (WebInspector.ScriptsPanel.prototype._uiSourceCodeFormatted):
45292         (WebInspector.ScriptsPanel.prototype._showOutlineDialog):
45293         (WebInspector.ScriptsPanel.prototype.set _fileRenamed):
45294         (WebInspector.ScriptsPanel.prototype._snippetCreationRequested.callback):
45295         (WebInspector.ScriptsPanel.prototype._snippetCreationRequested):
45296         * inspector/front-end/SnippetJavaScriptSourceFrame.js:
45297         (WebInspector.SnippetJavaScriptSourceFrame):
45298         (WebInspector.SnippetJavaScriptSourceFrame.prototype._runButtonClicked):
45299         * inspector/front-end/StyleSheetOutlineDialog.js:
45300         (WebInspector.StyleSheetOutlineDialog):
45301         (WebInspector.StyleSheetOutlineDialog.show):
45302         (WebInspector.StyleSheetOutlineDialog.prototype.requestItems):
45303         * inspector/front-end/StyleSource.js: Removed.
45304         * inspector/front-end/WebKit.qrc:
45305         * inspector/front-end/inspector.html:
45306
45307 2012-10-15  Jer Noble  <jer.noble@apple.com>
45308
45309         WebAudio: limit output level to 0db
45310         https://bugs.webkit.org/show_bug.cgi?id=95792
45311         <rdar://problem/11966135>
45312
45313         Reviewed by Chris Rogers.
45314
45315         Clamp the output buffer data to the range of [-1,1], which limits
45316         output volume to 0db. This ensures that malicious or poorly-written
45317         pages will not be able to blow through the system volume limit by
45318         creating >0db buffers and effects.
45319
45320         No new tests; added ManualTests/webaudio/limit-level-0db.html.
45321
45322         Clamp the output vector to values of [-1,1]:
45323         * platform/audio/mac/AudioDestinationMac.cpp:
45324         (WebCore::AudioDestinationMac::render):
45325
45326         Add a VectorMath wrapper for vDSP_clip to provide accelerated vector threshold operations:
45327         * platform/audio/VectorMath.h:
45328         * platform/audio/VectorMath.cpp:
45329         (VectorMath):
45330         (WebCore::VectorMath::vclip):
45331
45332 2012-10-15  Vsevolod Vlasov  <vsevik@chromium.org>
45333
45334         Web Inspector: Extract domain specific editing handling logic from UISourceCode (step 2).
45335         https://bugs.webkit.org/show_bug.cgi?id=99301
45336
45337         Reviewed by Pavel Feldman.
45338
45339         StyleFile and ScriptFile now listen for the UISourceCode WorkingCopyChanged/Committed events and process
45340         them instead of being called explicitly.
45341
45342         * inspector/front-end/JavaScriptSourceFrame.js:
45343         (WebInspector.JavaScriptSourceFrame):
45344         (WebInspector.JavaScriptSourceFrame.prototype.onTextChanged):
45345         (WebInspector.JavaScriptSourceFrame.prototype._willMergeToVM):
45346         (WebInspector.JavaScriptSourceFrame.prototype._didMergeToVM):
45347         (WebInspector.JavaScriptSourceFrame.prototype._willDivergeFromVM):
45348         (WebInspector.JavaScriptSourceFrame.prototype._didDivergeFromVM):
45349         (WebInspector.JavaScriptSourceFrame.prototype._muteBreakpointsWhileEditing):
45350         (WebInspector.JavaScriptSourceFrame.prototype._restoreBreakpointsAfterEditing):
45351         * inspector/front-end/ResourceScriptMapping.js:
45352         (WebInspector.ResourceScriptMapping.prototype._hasMergedToVM):
45353         (WebInspector.ResourceScriptMapping.prototype._hasDivergedFromVM):
45354         (WebInspector.ResourceScriptMapping.prototype._bindUISourceCodeToScripts):
45355         (WebInspector.ResourceScriptFile):
45356         (WebInspector.ResourceScriptFile.prototype._workingCopyCommitted):
45357         (WebInspector.ResourceScriptFile.prototype._workingCopyChanged):
45358         * inspector/front-end/ScriptSnippetModel.js:
45359         (WebInspector.SnippetScriptFile):
45360         (WebInspector.SnippetScriptFile.prototype._workingCopyCommitted):
45361         (WebInspector.SnippetScriptFile.prototype._workingCopyChanged):
45362         * inspector/front-end/StylesSourceMapping.js:
45363         (WebInspector.StyleFile):
45364         (WebInspector.StyleFile.prototype._workingCopyCommitted):
45365         (WebInspector.StyleFile.prototype._workingCopyChanged):
45366         (WebInspector.StyleFile.prototype._commitIncrementalEdit):
45367         (WebInspector.StyleFile.prototype._clearIncrementalUpdateTimer):
45368         (WebInspector.StyleFile.prototype.addRevision):
45369         (WebInspector.StyleContentBinding.prototype._innerStyleSheetChanged):
45370         * inspector/front-end/UISourceCode.js:
45371         (WebInspector.UISourceCode.prototype.setWorkingCopy):
45372         (WebInspector.UISourceCode.prototype.commitWorkingCopy):
45373
45374 2012-10-16  Alexander Pavlov  <apavlov@chromium.org>
45375
45376         Web Inspector: [Elements] Double-click to live edit style tags changes text to 'undefined' in some situations
45377         https://bugs.webkit.org/show_bug.cgi?id=99336
45378
45379         Reviewed by Vsevolod Vlasov.
45380
45381         Before editing text nodes, set their textContent to the nodeValue() of the corresponding WebInspector.DOMNode in the UI.
45382         Drive-by: fix text node editing artifact in the DOM tree.
45383
45384         * inspector/front-end/ElementsTreeOutline.js:
45385         (WebInspector.ElementsTreeElement.prototype._startEditingTextNode):
45386         (WebInspector.ElementsTreeElement.prototype._tagNameEditingCommitted):
45387
45388 2012-10-16  Mike West  <mkwst@chromium.org>
45389
45390         Web Inspector: Whitelist safe styles for 'console.log('%c...', ...)'.
45391         https://bugs.webkit.org/show_bug.cgi?id=98945
45392
45393         Reviewed by Pavel Feldman.
45394
45395         Support for styling console messages via '%c' landed without any
45396         parsing of the style information provided. This means that it's fairly
45397         simple to accidentally or maliciously break the console with cleverly
45398         styled messages. To mitigate this risk, whitelisting a safe subset of
45399         CSS seems appropriate.
45400
45401         As a first pass at a reasonable whitelist, this patch allows
45402         'background[-*]', 'border[-*]', 'color[-*]', 'font[-*]',
45403         'margin[-*]', 'padding[-*]', 'text[-*]', '-webkit-background[-*]',
45404         '-webkit-border[-*]', '-webkit-font[-*]', '-webkit-margin[-*]',
45405         '-webkit-padding[-*]', and '-webkit-text[-*]'.
45406
45407         Test: inspector/console/console-format-style-whitelist.html
45408
45409         * inspector/front-end/ConsoleMessage.js:
45410         (WebInspector.ConsoleMessageImpl.prototype._formatWithSubstitutionString.styleFormatter):
45411             Create a buffer element onto which the user-provided styles are
45412             applied. Whitelisted styles are transfered from the buffer onto
45413             the actual console message.
45414         (WebInspector.ConsoleMessageImpl.prototype._formatWithSubstitutionString.isWhitelistedProperty):
45415              Returns true if the specific style is whitelisted. Expects styles
45416              in the hyphenated form (that is, '-webkit-padding-start' rather than
45417              CSSOM's 'webkitPaddingStart').
45418
45419 2012-10-16  Luke Macpherson   <macpherson@chromium.org>
45420
45421         Handle CSSPropertyOpacity in StyleBuilder.
45422         https://bugs.webkit.org/show_bug.cgi?id=99418
45423
45424         Reviewed by Alexis Menard.
45425
45426         One small step in moving from the huge switch in StyleResolver::applyProperty() to the StyleBuilder approach.
45427
45428         Covered by many existing tests, for example fast/text/complex-text-opacity.html.
45429
45430         * css/StyleBuilder.cpp:
45431         (WebCore::StyleBuilder::StyleBuilder):
45432         * css/StyleResolver.cpp:
45433         (WebCore::StyleResolver::applyProperty):
45434
45435 2012-10-16  Kent Tamura  <tkent@chromium.org>
45436
45437         Fix some appearance glitches of multiple fields input elements
45438         https://bugs.webkit.org/show_bug.cgi?id=99412
45439
45440         A follow-up change for r131421.
45441
45442         * css/themeWin.css:
45443         (input[type="text"]): Don't reset paddings for date/time types.
45444
45445 2012-10-16  Kenichi Ishibashi  <bashi@chromium.org>
45446
45447         hb_face_t instances should not depend on FontPlatformData
45448         https://bugs.webkit.org/show_bug.cgi?id=99430
45449
45450         Reviewed by Kent Tamura.
45451
45452         Use platform specific font data (e.g. SkTypeface) to get
45453         font tables for harfbuzz-ng.
45454
45455         No new tests. No changes in behavior.
45456
45457         * platform/graphics/harfbuzz/ng/HarfBuzzNGFaceCairo.cpp:
45458         (WebCore::harfbuzzCairoGetTable): Takes cairo_scaled_font_t* as userData.
45459         (WebCore::HarfBuzzNGFace::createFace):
45460         * platform/graphics/harfbuzz/ng/HarfBuzzNGFaceCoreText.cpp:
45461         (WebCore::harfbuzzCoreTextGetTable): Takes CGFontRef as userData.
45462         (WebCore::HarfBuzzNGFace::createFace):
45463         * platform/graphics/harfbuzz/ng/HarfBuzzNGFaceSkia.cpp:
45464         (WebCore::harfbuzzSkiaGetTable): Takes SkFontID as userData.
45465         (WebCore::HarfBuzzNGFace::createFace):
45466
45467 2012-10-16  Sheriff Bot  <webkit.review.bot@gmail.com>
45468
45469         Unreviewed, rolling out r131418.
45470         http://trac.webkit.org/changeset/131418
45471         https://bugs.webkit.org/show_bug.cgi?id=99431
45472
45473         since 131403 seems innocent (Requested by shinyak|_ on
45474         #webkit).
45475
45476         * dom/Document.cpp:
45477         (WebCore::isValidNameNonASCII):
45478         (WebCore):
45479         (WebCore::Document::isValidName):
45480
45481 2012-10-16  Ilya Tikhonovsky  <loislo@chromium.org>
45482
45483         Web Inspector: NMI Instrument InspectorOverlay. It costs us ~9Mb because it creates page size canvas.
45484         https://bugs.webkit.org/show_bug.cgi?id=99426
45485
45486         Reviewed by Yury Semikhatsky.
45487
45488         New object type InspectorOverlay was added. InspectorOverlay was instrumented.
45489         The instrumentation code automatically visits all the objects that can be reached via m_overlayPage.
45490
45491         * dom/WebCoreMemoryInstrumentation.cpp:
45492         (WebCore):
45493         * dom/WebCoreMemoryInstrumentation.h:
45494         (WebCoreMemoryTypes):
45495         * inspector/InspectorOverlay.cpp:
45496         (WebCore::InspectorOverlay::reportMemoryUsage):
45497         (WebCore):
45498         * inspector/InspectorOverlay.h:
45499         (InspectorOverlay):
45500
45501 2012-10-16  Kent Tamura  <tkent@chromium.org>
45502
45503         Remove unused functions in Locale* classes
45504         https://bugs.webkit.org/show_bug.cgi?id=99425
45505
45506         Reviewed by Yuta Kitamura.
45507
45508         Locale*::currentLocale has been unused since LocalizedDate* and
45509         LocalizedNumber* were removed.
45510
45511         No new tests. This shouldn't change any behavior.
45512
45513         * platform/text/LocaleICU.cpp: Remove createForCurrentLocale and currentLocale.
45514         * platform/text/LocaleICU.h: Ditto.
45515         * platform/text/LocaleWin.cpp: Remove currentLocale.
45516         * platform/text/LocaleWin.h: Ditto.
45517         * platform/text/mac/LocaleMac.h: Remove currentLocale.
45518         * platform/text/mac/LocaleMac.mm: Ditto.
45519
45520 2012-10-15  Kent Tamura  <tkent@chromium.org>
45521
45522         Fix some appearance glitches of multiple fields input elements
45523         https://bugs.webkit.org/show_bug.cgi?id=99412
45524
45525         Reviewed by Kentaro Hara.
45526
45527         1. If CSS-specified width is wider than the intrinsic width of an input,
45528         the spin button and the picker indicator triangle should be put at the
45529         right side of the content area.
45530
45531         2. Remove top, right, and bottom paddings to match input[type=number]
45532         appearance as possible.
45533
45534         3. Remove unnecessary position:relative for spin buttons.
45535
45536         4. Center content vertically if the height is taller than the intrinsic height.
45537
45538         Tests: Update all of rendering tests for input element with multiple fields UI.
45539
45540         * css/html.css:
45541         (input[type="date"]):
45542         - Specify display:-webkit-inline-flex and -webkit-align-items:stretch to center contents.
45543         - Remove top/right/bottom paddings.
45544         (input[type="datetime"]): Ditto.
45545         (input[type="datetime-local"]): Ditto.
45546         (input[type="month"]): Ditto.
45547         (input[type="time"]): Ditto.
45548         (input[type="week"]): Ditto.
45549         (input::-webkit-datetime-edit):
45550         - Switch to the starndard flexible box from the legacy one.
45551         - Add white-space:pre to avoid to collapse white spaces.
45552         (input::-webkit-datetime-edit-gap):
45553         Added. This element is added to push a spin button to the right side.
45554         (input::-webkit-date-and-time-container):
45555         Add -webkit-flex:1 for the input flexible box.
45556         Sort properties.
45557         (input[type="week"]::-webkit-inner-spin-button):
45558         - Use this in date, datetime, datetime-local, and week types.
45559         - Add display:inline-block because other elements in -webkit-datetime-edit is inilne.
45560         - Add position:static to cancel position:relative below.
45561
45562         * html/shadow/DateTimeEditElement.cpp:
45563         (WebCore::DateTimeEditElement::layout):
45564         Add an element with -webkit-datetime-edit-gap before a spin button.
45565
45566 2012-10-15  Yury Semikhatsky  <yurys@chromium.org>
45567
45568         Web Inspector: can't click delete button if watch expression is very long
45569         https://bugs.webkit.org/show_bug.cgi?id=99414
45570
45571         Reviewed by Vsevolod Vlasov.
45572
45573         Minus button in watch expression section doesn't overlap with the
45574         expression/value anymore.
45575
45576         * inspector/front-end/inspector.css:
45577         (.properties-tree.watch-expressions > li.hovered):
45578
45579 2012-10-15  Sheriff Bot  <webkit.review.bot@gmail.com>
45580
45581         Unreviewed, rolling out r131403.
45582         http://trac.webkit.org/changeset/131403
45583         https://bugs.webkit.org/show_bug.cgi?id=99420
45584
45585         Suspicious to cause Performance test failing (Requested by
45586         shinyak|gardenin on #webkit).
45587
45588         * dom/Document.cpp:
45589         (WebCore::Document::isValidName):
45590
45591 2012-10-15  Yury Semikhatsky  <yurys@chromium.org>
45592
45593         Web Inspector: restore watch expression expansion state
45594         https://bugs.webkit.org/show_bug.cgi?id=99304
45595
45596         Reviewed by Pavel Feldman.
45597
45598         Expand watch expression value and its properties if they were expanded
45599         before update.
45600
45601         Test: inspector/debugger/watch-expressions-preserve-expansion.html
45602
45603         * inspector/front-end/WatchExpressionsSidebarPane.js:
45604         (WebInspector.WatchExpressionTreeElement.prototype.onexpand):
45605         (WebInspector.WatchExpressionTreeElement.prototype.oncollapse):
45606         (WebInspector.WatchExpressionTreeElement.prototype.onattach):
45607         (WebInspector.WatchExpressionTreeElement.prototype._expression):
45608         (WebInspector.WatchedPropertyTreeElement):
45609         (WebInspector.WatchedPropertyTreeElement.prototype.onattach):
45610         (WebInspector.WatchedPropertyTreeElement.prototype.onexpand):
45611         (WebInspector.WatchedPropertyTreeElement.prototype.oncollapse):
45612         (WebInspector.WatchedPropertyTreeElement.prototype._propertyPath):
45613
45614 2012-10-15  Mike West  <mkwst@chromium.org>
45615
45616         Warn when CSP headers don't separate directives with ';'.
45617         https://bugs.webkit.org/show_bug.cgi?id=99274
45618
45619         Reviewed by Adam Barth.
45620
45621         A recent bug report exhibited confusion as to what role, exactly,
45622         semicolons play in Content Security Policy definitions. This patch
45623         adjusts the parser to warn web authors if a directive name is
45624         encountered while parsing a source list, which would almost certainly
45625         point to a missing semicolon. For example, something like:
45626
45627             script-src 'self' object-src 'self' style-src *
45628
45629         would throw two warnings, noting that 'object-src' and 'style-src' are
45630         probably meant as directives, and not as source expressions in the
45631         'script-src' source list.
45632
45633         Test: http/tests/security/contentSecurityPolicy/source-list-parsing-no-semicolon.html
45634
45635         * page/ContentSecurityPolicy.cpp:
45636         (WebCore::CSPSourceList::parse):
45637             Throw the new warning onto the console if the hostname of a source
45638             expression matches a CSP directive name.
45639         (WebCore::CSPDirectiveList::addDirective):
45640             Use the exciting new static variables so that the names of various
45641             directives are available outside of CSPDirectiveList::addDirective.
45642             These were previously defined as local static ASCIILiterals. Now
45643             they're static const char[] in an anonymous namespace.
45644         (WebCore::ContentSecurityPolicy::isDirectiveName):
45645             Static method that compares a string to all the known directive
45646             names, returning true if there's a (case-insensitive) match.
45647         (WebCore):
45648         (WebCore::ContentSecurityPolicy::reportDirectiveAsSourceExpression):
45649             A new warning message which should be printed when a directive name
45650             is encountered as a source expression. Matching the directive name
45651             is done via a new 'isDirectiveName' function which lives in an
45652             anonymous namespace along with the other CSP helper functions.
45653         * page/ContentSecurityPolicy.h:
45654             Added 'reportDirectiveAsSourceExpression' signature.
45655
45656 2012-10-15  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
45657
45658         Unreviewed, rolling out r131349.
45659         http://trac.webkit.org/changeset/131349
45660         https://bugs.webkit.org/show_bug.cgi?id=97173
45661
45662         Revert r131349 because API test is broken by this commit.
45663
45664         * platform/efl/RunLoopEfl.cpp:
45665         (WebCore::RunLoop::RunLoop):
45666         (WebCore::RunLoop::~RunLoop):
45667
45668 2012-10-15  Nate Chapin  <japhet@chromium.org>
45669
45670         ResourceLoader::sendResourceLoadCallbacks() is backwards
45671         https://bugs.webkit.org/show_bug.cgi?id=99366
45672
45673         Reviewed by Daniel Bates.
45674
45675         No new tests, this function is uncalled but will be used
45676         in a later patch.
45677
45678         * loader/ResourceLoader.h:
45679         (WebCore::ResourceLoader::sendResourceLoadCallbacks):
45680
45681 2012-10-15  Dan Bernstein  <mitz@apple.com>
45682
45683         REGRESSION (r131365): WidthIterator::advance() is needlessly passed a GlyphBuffer in many cases
45684         https://bugs.webkit.org/show_bug.cgi?id=99413
45685
45686         Reviewed by Adele Peterson.
45687
45688         r131365 made Font::width() always pass a GlyphBuffer pointer to floatWidthForSimpleText and
45689         from there down to WidthIterator::advance(). However, when measuring the width of a run, a
45690         GlyphBuffer is only needed if font transforms (kerning and ligatures) need to be applied.
45691
45692         No new test, because there is no change in behavior.
45693
45694         * platform/graphics/Font.cpp:
45695         (WebCore::Font::width): Removed the local GlyphBuffer that was passed down to
45696         floatWidthForSimpleText().
45697         * platform/graphics/Font.h: Removed the GlyphBuffer* parameter to floatWidthForSimpleText.
45698         All but the above caller were passing 0.
45699         * platform/graphics/FontFastPath.cpp:
45700         (WebCore::Font::floatWidthForSimpleText): Removed the GlyphBuffer* parameter and added a
45701         local GlyphBuffer, which is passed by reference to WidthIterator::advance() only if
45702         typesetting features require it.
45703         (WebCore::Font::offsetForPositionForSimpleText): Updated for change to
45704         floatWidthForSimpleText.
45705         * platform/graphics/pango/FontPango.cpp:
45706         (WebCore::Font::floatWidthForComplexText): Ditto.
45707
45708 2012-10-15  Pablo Flouret  <pablof@motorola.com>
45709
45710         Add force parameter to DOMTokenList.toggle
45711         https://bugs.webkit.org/show_bug.cgi?id=99375
45712
45713         Reviewed by Darin Adler.
45714
45715         See http://dom.spec.whatwg.org/#dom-domtokenlist-toggle and
45716         https://www.w3.org/Bugs/Public/show_bug.cgi?id=18463
45717
45718         Essentially, the optional boolean force parameter, if present, makes
45719         toggle always add or remove a class.
45720
45721         No new tests, modified fast/dom/HTMLElement/script-tests/class-list.js
45722
45723         * html/DOMTokenList.cpp:
45724         (WebCore::DOMTokenList::toggle):
45725         (WebCore):
45726         * html/DOMTokenList.h:
45727         (DOMTokenList):
45728         * html/DOMTokenList.idl:
45729             New toggle() overload that takes a force parameter and calls
45730             addInternal() or removeInternal() based on it.
45731
45732 2012-10-15  Dan Bernstein  <mitz@apple.com>
45733
45734         Layout Test fast/text/justify-ideograph-leading-expansion.html is failing an assertion chromium mac
45735         https://bugs.webkit.org/show_bug.cgi?id=99406
45736
45737         Reviewed by Darin Adler.
45738
45739         * platform/graphics/WidthIterator.cpp:
45740         * platform/graphics/WidthIterator.h:
45741         (WebCore::WidthIterator::shouldApplyFontTransforms): Changed to return false if the run is
45742         shorter than 2 characters. 1-character runs are invariant under font transforms, and therefore
45743         Font::codePath() sends them through WidthIterator even on platforms where WidthIterator
45744         does not support kerning and ligatures.
45745
45746 2012-10-15  Michael Saboff  <msaboff@apple.com>
45747
45748         Add 8 bit patch to Document::isValidName() for the non ASCII case
45749         https://bugs.webkit.org/show_bug.cgi?id=99402
45750
45751         Reviewed by Darin Adler.
45752
45753         Added 8 bit path to complete the processing of an 8 bit names without up-converting.
45754
45755         * dom/Document.cpp:
45756         (WebCore::isValidNameNonASCII):
45757         (WebCore::Document::isValidName):
45758
45759 2012-10-15  Vlad Grecescu  <igrecesc@adobe.com>, Douglas Stockwell  <dstockwell@chromium.org>
45760
45761         Support for background-clip:content-box and padding-box with border-radius
45762         https://bugs.webkit.org/show_bug.cgi?id=23166
45763
45764         Reviewed by Simon Fraser.
45765
45766         Test: fast/css/background-clip-radius-values.html
45767
45768         * rendering/RenderBoxModelObject.cpp:
45769         (WebCore::RenderBoxModelObject::clipRoundedInnerRect):
45770         (WebCore):
45771         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
45772         * rendering/RenderBoxModelObject.h:
45773
45774 2012-10-15  Byungwoo Lee  <bw80.lee@samsung.com>
45775
45776         Fix unused parameter build warning.
45777         https://bugs.webkit.org/show_bug.cgi?id=99400
45778
45779         Reviewed by Gyuyoung Kim.
45780
45781         Remove the name of unused parameters to fix the build warning (-Wunused-parameter).
45782
45783         * platform/network/soup/ResourceErrorSoup.cpp:
45784         (WebCore::ResourceError::tlsError):
45785
45786 2012-10-15  Kenichi Ishibashi  <bashi@chromium.org>
45787
45788         [WebSocket] WebSocketInflater should handle BFINAL = 1 blocks
45789         https://bugs.webkit.org/show_bug.cgi?id=99282
45790
45791         Reviewed by Yuta Kitamura.
45792
45793         Reset decompression state if WebSocketInflater decompress a block with
45794         BFINAL set to 1.
45795
45796         Test: http/tests/websocket/tests/hybi/deflate-frame-set-bfinal.html
45797
45798         * Modules/websockets/WebSocketDeflater.cpp:
45799         (WebCore::WebSocketInflater::addBytes):
45800         Reset decompression state if inflate() returns Z_STREAM_END, which means the BFINAL
45801         of the current block was set to 1.
45802         (WebCore::WebSocketInflater::finish): Add an assertion.
45803
45804 2012-10-15  Simon Fraser  <simon.fraser@apple.com>
45805
45806         Fix GraphicsLayer visible rect computation when scrolling in WebKit1
45807         https://bugs.webkit.org/show_bug.cgi?id=99385
45808
45809         Reviewed by Dean Jackson, Tim Horton.
45810
45811         RenderLayerCompositor always used frameView->frameRect() as the visible
45812         rect on the root used for GraphicsLayer visibleRect computation. This
45813         was wrong for subframes, which require a rect with an origin of (0,0)
45814         and size of the contentsSize().
45815         
45816         It was also wrong when the scrolling is not represented in the GraphicsLayer
45817         tree. When scrolling is done elsewhere, we need to use the ScrollView's
45818         visibleContentRect().
45819
45820         Tests: compositing/visible-rect/scrolled.html
45821                compositing/visible-rect/iframe-and-layers.html
45822                compositing/visible-rect/iframe-no-layers.html
45823
45824         * rendering/RenderLayerCompositor.cpp:
45825         (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
45826
45827 2012-10-15  Julien Chaffraix  <jchaffraix@webkit.org>
45828
45829         Remove page visibility hidden histograms
45830         https://bugs.webkit.org/show_bug.cgi?id=99360
45831
45832         Reviewed by Ojan Vafai.
45833
45834         The 2 page visibility hidden histograms were added in http://webkit.org/b/85537 to
45835         investigate a potential optimization where we would destroy the render tree when
45836         a tab was hidden. The optimization was abandoned but the histograms were never
45837         removed. They are too narrow to be reused so this change removes them.
45838
45839         * page/Page.cpp:
45840         (WebCore::Page::setVisibilityState):
45841
45842 2012-10-15  Ryuan Choi  <ryuan.choi@samsung.com>
45843
45844         REGRESSION: Build break after r131373 when ACCELERATED_COMPOSITING disabled
45845         https://bugs.webkit.org/show_bug.cgi?id=99397
45846
45847         Unreviewed, build fix.
45848
45849         * page/scrolling/ScrollingCoordinator.cpp:
45850         (WebCore::ScrollingCoordinator::updateMainFrameScrollPosition):
45851
45852 2012-10-14  Kent Tamura  <tkent@chromium.org>
45853
45854         Input elements with multiple fields UI should set appropriate direction for browser locale automatically
45855         https://bugs.webkit.org/show_bug.cgi?id=99291
45856
45857         Reviewed by Hajime Morita.
45858
45859         Input elemnts with multiple fields UI ignores HTML dir attribute or CSS
45860         direction property, and their direction should be decided by the browser
45861         locale. If the browser locale is a RTL language, date/time input fields
45862         show formats/digits for the RTL language. The layout should be always
45863         RTL regardless of the direction in such case.
45864
45865         Test: fast/forms/date-multiple-fields/date-multiple-fields-appearance-l10n.html
45866
45867         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
45868         (WebCore::BaseMultipleFieldsDateAndTimeInputType::updateInnerTextValue):
45869         Set approriate dir attribute value to the child element of the UA shadow root.
45870
45871 2012-10-15  Andreas Kling  <kling@webkit.org>
45872
45873         StyleResolver: Garbage collect the matched properties cache on a timer.
45874         <http://webkit.org/b/98625>
45875
45876         Reviewed by Eric Seidel.
45877
45878         Sweeping the matched properties cache once every 100 additions ended up choking RoboHornet's
45879         svgresize.html benchmark. Move it to a single-shot timer that's refreshed every 100 additions
45880         and defers the actual sweep for 60 seconds.
45881
45882         * css/StyleResolver.cpp:
45883         (WebCore::StyleResolver::StyleResolver):
45884         (WebCore::StyleResolver::sweepMatchedPropertiesCache):
45885         (WebCore::StyleResolver::addToMatchedPropertiesCache):
45886         * css/StyleResolver.h:
45887         (StyleResolver):
45888
45889 2012-10-15  Arnaud Renevier  <a.renevier@sisa.samsung.com>
45890
45891         [GStreamer] GstCaps are leaked when building with gstreamer-1.0
45892         https://bugs.webkit.org/show_bug.cgi?id=99362
45893
45894         Reviewed by Martin Robinson.
45895
45896         Implement GRefPtr<GstCaps> adoptGRef(GstCaps*).
45897
45898         Change webkitGstGetPadCaps signature to return a GRefPtr<GstCaps>, and
45899         use GRefPtr<GstCaps> also in webkitVideoSinkRender to simply GstCaps
45900         refeference count.
45901
45902         Covered by existing tests.
45903
45904         * platform/graphics/gstreamer/GRefPtrGStreamer.cpp:
45905         (WTF::adoptGRef):
45906         (WTF):
45907         * platform/graphics/gstreamer/GRefPtrGStreamer.h:
45908         (WTF):
45909         * platform/graphics/gstreamer/GStreamerVersioning.cpp:
45910         (webkitGstGetPadCaps):
45911         * platform/graphics/gstreamer/GStreamerVersioning.h:
45912         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
45913         (WebCore::MediaPlayerPrivateGStreamer::naturalSize):
45914         * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
45915         (webkitVideoSinkRender):
45916
45917 2012-10-15  Tony Chang  <tony@chromium.org>
45918
45919         Unreviewed, rolling out r131367.
45920         http://trac.webkit.org/changeset/131367
45921         https://bugs.webkit.org/show_bug.cgi?id=98666
45922
45923         crashes on Apple Mac
45924
45925         * css/html.css:
45926         (input[type="range"]::-webkit-slider-container, input[type="range"]::-webkit-media-slider-container):
45927         (input[type="range"]::-webkit-slider-runnable-track):
45928         (input[type="range"]::-webkit-slider-thumb, input[type="range"]::-webkit-media-slider-thumb):
45929         * css/mediaControlsChromium.css:
45930         (input[type="range"]::-webkit-media-slider-thumb):
45931         * css/mediaControlsChromiumAndroid.css:
45932         (input[type="range"]::-webkit-media-slider-thumb):
45933         * html/RangeInputType.cpp:
45934         (WebCore::RangeInputType::listAttributeTargetChanged):
45935         * html/shadow/SliderThumbElement.cpp:
45936         (WebCore::RenderSliderThumb::layout):
45937         (WebCore):
45938         (WebCore::RenderSliderContainer::RenderSliderContainer):
45939         (RenderSliderContainer):
45940         (WebCore::RenderSliderContainer::layout):
45941         * html/shadow/SliderThumbElement.h:
45942         (RenderSliderThumb):
45943         * rendering/RenderSlider.cpp:
45944         (WebCore):
45945         (WebCore::RenderSlider::RenderSlider):
45946         (WebCore::RenderSlider::layout):
45947         * rendering/RenderSlider.h:
45948         (WebCore):
45949         (RenderSlider):
45950         (WebCore::RenderSlider::renderName):
45951         (WebCore::RenderSlider::isSlider):
45952         (WebCore::RenderSlider::requiresForcedStyleRecalcPropagation):
45953         (WebCore::toRenderSlider):
45954
45955 2012-10-15  Dan Bernstein  <mitz@apple.com>
45956
45957         Try to fix the build again after r131375.
45958
45959         * platform/graphics/WidthIterator.h:
45960         (WebCore::WidthIterator::shouldApplyFontTransforms): Removed the length check from here.
45961
45962 2012-10-15  Dan Bernstein  <mitz@apple.com>
45963
45964         Try to fix assertion failures on ports that do not support kerning and ligatures on the fast
45965         code path after r131365.
45966
45967         * platform/graphics/WidthIterator.cpp:
45968         (WebCore::applyFontTransforms): Changed the early return condition to not bother with 1-glyph
45969         sequences.
45970         * platform/graphics/WidthIterator.h:
45971         (WebCore::WidthIterator::shouldApplyFontTransforms): Changed to return false if the run is
45972         shorter than 2 characters.
45973
45974 2012-10-15  Dan Bernstein  <mitz@apple.com>
45975
45976         Try to fix the Chromium Mac build after r131365.
45977
45978         * platform/graphics/GlyphBuffer.h:
45979         (WebCore::GlyphBufferAdvance::height): Added.
45980         * platform/graphics/skia/FontSkia.cpp:
45981         (WebCore::Font::drawGlyphs): Changed to use accessors for the GlyphBufferAdvance’s width and height.
45982
45983 2012-10-15  Simon Fraser  <simon.fraser@apple.com>
45984
45985         Ensure that GraphicsLayer positions are updated while doing threaded scrolling
45986         https://bugs.webkit.org/show_bug.cgi?id=99372
45987
45988         Reviewed by Anders Carlsson.
45989
45990         When doing threaded scrolling, the scrolling thread updates the positions of CALayers,
45991         but doesn't update GraphicsLayers. This means that code that relies on GraphicsLayer positions
45992         works incorrectly.
45993         
45994         Threaded scrolling is not testabled in layout tests.
45995
45996         * page/scrolling/ScrollingCoordinator.cpp:
45997         (WebCore::ScrollingCoordinator::updateMainFrameScrollPosition):
45998         * platform/graphics/GraphicsLayer.h:
45999         (GraphicsLayer):
46000         (WebCore::GraphicsLayer::syncPosition):
46001
46002 2012-10-15  Tommy Widenflycht  <tommyw@google.com>
46003
46004         MediaStream API: Implement RTCDataChannel
46005         https://bugs.webkit.org/show_bug.cgi?id=99080
46006
46007         Reviewed by Adam Barth.
46008
46009         This patch introduces RTCDataChannel which is a pipe for sending data between two RTCPeerConnections.
46010         Since the data channel belongs to a peer connection object I have reused part of its infrastructure.
46011
46012         Not currently testable. My next patch will add the chromium WebKit functionality, together with mocks and tests.
46013
46014         * CMakeLists.txt:
46015         * GNUmakefile.list.am:
46016         * Modules/mediastream/RTCDataChannel.cpp: Added.
46017         (WebCore):
46018         (WebCore::RTCDataChannel::create):
46019         (WebCore::RTCDataChannel::RTCDataChannel):
46020         (WebCore::RTCDataChannel::~RTCDataChannel):
46021         (WebCore::RTCDataChannel::label):
46022         (WebCore::RTCDataChannel::reliable):
46023         (WebCore::RTCDataChannel::readyState):
46024         (WebCore::RTCDataChannel::bufferedAmount):
46025         (WebCore::RTCDataChannel::binaryType):
46026         (WebCore::RTCDataChannel::setBinaryType):
46027         (WebCore::RTCDataChannel::send):
46028         (WebCore::RTCDataChannel::close):
46029         (WebCore::RTCDataChannel::readyStateChanged):
46030         (WebCore::RTCDataChannel::dataArrived):
46031         (WebCore::RTCDataChannel::error):
46032         (WebCore::RTCDataChannel::descriptor):
46033         (WebCore::RTCDataChannel::interfaceName):
46034         (WebCore::RTCDataChannel::scriptExecutionContext):
46035         (WebCore::RTCDataChannel::stop):
46036         (WebCore::RTCDataChannel::eventTargetData):
46037         (WebCore::RTCDataChannel::ensureEventTargetData):
46038         * Modules/mediastream/RTCDataChannel.h: Added.
46039         (WebCore):
46040         (RTCDataChannel):
46041         (WebCore::RTCDataChannel::refEventTarget):
46042         (WebCore::RTCDataChannel::derefEventTarget):
46043         * Modules/mediastream/RTCDataChannel.idl: Added.
46044         * Modules/mediastream/RTCDataChannelEvent.cpp: Added.
46045         (WebCore):
46046         (WebCore::RTCDataChannelEvent::create):
46047         (WebCore::RTCDataChannelEvent::RTCDataChannelEvent):
46048         (WebCore::RTCDataChannelEvent::~RTCDataChannelEvent):
46049         (WebCore::RTCDataChannelEvent::channel):
46050         (WebCore::RTCDataChannelEvent::interfaceName):
46051         * Modules/mediastream/RTCDataChannelEvent.h: Added.
46052         (WebCore):
46053         (RTCDataChannelEvent):
46054         * Modules/mediastream/RTCDataChannelEvent.idl: Added.
46055         * Modules/mediastream/RTCPeerConnection.cpp:
46056         (WebCore::RTCPeerConnection::createDataChannel):
46057         (WebCore):
46058         (WebCore::RTCPeerConnection::close):
46059         (WebCore::RTCPeerConnection::didAddRemoteDataChannel):
46060         (WebCore::RTCPeerConnection::stop):
46061         * Modules/mediastream/RTCPeerConnection.h:
46062         (WebCore):
46063         (RTCPeerConnection):
46064         * Modules/mediastream/RTCPeerConnection.idl:
46065         * WebCore.gypi:
46066         * dom/EventNames.h:
46067         (WebCore):
46068         * dom/EventNames.in:
46069         * dom/EventTargetFactory.in:
46070         * platform/mediastream/RTCDataChannelDescriptor.cpp: Added.
46071         (WebCore):
46072         (WebCore::RTCDataChannelDescriptor::create):
46073         (WebCore::RTCDataChannelDescriptor::RTCDataChannelDescriptor):
46074         (WebCore::RTCDataChannelDescriptor::~RTCDataChannelDescriptor):
46075         (WebCore::RTCDataChannelDescriptor::readyStateChanged):
46076         (WebCore::RTCDataChannelDescriptor::dataArrived):
46077         (WebCore::RTCDataChannelDescriptor::error):
46078         * platform/mediastream/RTCDataChannelDescriptor.h: Added.
46079         (WebCore):
46080         (RTCDataChannelDescriptorClient):
46081         (WebCore::RTCDataChannelDescriptorClient::~RTCDataChannelDescriptorClient):
46082         (RTCDataChannelDescriptor):
46083         (ExtraData):
46084         (WebCore::RTCDataChannelDescriptor::ExtraData::~ExtraData):
46085         (WebCore::RTCDataChannelDescriptor::client):
46086         (WebCore::RTCDataChannelDescriptor::setClient):
46087         (WebCore::RTCDataChannelDescriptor::label):
46088         (WebCore::RTCDataChannelDescriptor::reliable):
46089         (WebCore::RTCDataChannelDescriptor::readyState):
46090         (WebCore::RTCDataChannelDescriptor::bufferedAmount):
46091         (WebCore::RTCDataChannelDescriptor::setBufferedAmount):
46092         (WebCore::RTCDataChannelDescriptor::extraData):
46093         (WebCore::RTCDataChannelDescriptor::setExtraData):
46094         * platform/mediastream/RTCPeerConnectionHandler.cpp:
46095         (RTCPeerConnectionHandlerDummy):
46096         (WebCore::RTCPeerConnectionHandlerDummy::openDataChannel):
46097         (WebCore):
46098         (WebCore::RTCPeerConnectionHandlerDummy::sendStringData):
46099         (WebCore::RTCPeerConnectionHandlerDummy::sendRawData):
46100         (WebCore::RTCPeerConnectionHandlerDummy::closeDataChannel):
46101         * platform/mediastream/RTCPeerConnectionHandler.h:
46102         (WebCore):
46103         (RTCPeerConnectionHandler):
46104         * platform/mediastream/RTCPeerConnectionHandlerClient.h:
46105         (WebCore):
46106         (RTCPeerConnectionHandlerClient):
46107         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp:
46108         (WebCore::RTCPeerConnectionHandlerChromium::openDataChannel):
46109         (WebCore):
46110         (WebCore::RTCPeerConnectionHandlerChromium::sendStringData):
46111         (WebCore::RTCPeerConnectionHandlerChromium::sendRawData):
46112         (WebCore::RTCPeerConnectionHandlerChromium::closeDataChannel):
46113         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h:
46114         (RTCPeerConnectionHandlerChromium):
46115
46116 2012-10-15  Joshua Bell  <jsbell@chromium.org>
46117
46118         IndexedDB: Pass type of error causing abort to IDBTransaction::onAbort
46119         https://bugs.webkit.org/show_bug.cgi?id=99097
46120
46121         Reviewed by Tony Chang.
46122
46123         Include the error causing the abort in the callback from back end to
46124         front end so it can be exposed on the IDBTransaction.error property.
46125
46126         Test: lazy-index-population.html
46127
46128         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
46129         (WebCore::IDBDatabaseBackendImpl::setVersionInternal):
46130         (WebCore::IDBDatabaseBackendImpl::setIntVersionInternal):
46131         * Modules/indexeddb/IDBDatabaseCallbacks.h:
46132         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
46133         (WebCore::IDBObjectStoreBackendImpl::setIndexKeys):
46134         (WebCore::IDBObjectStoreBackendImpl::putInternal):
46135         * Modules/indexeddb/IDBTransaction.cpp:
46136         (WebCore::IDBTransaction::onAbort):
46137         * Modules/indexeddb/IDBTransaction.h:
46138         (IDBTransaction):
46139         * Modules/indexeddb/IDBTransactionBackendImpl.cpp:
46140         (WebCore::IDBTransactionBackendImpl::abort):
46141         (WebCore):
46142         (WebCore::IDBTransactionBackendImpl::commit):
46143         * Modules/indexeddb/IDBTransactionBackendImpl.h:
46144         (IDBTransactionBackendImpl):
46145         * Modules/indexeddb/IDBTransactionCallbacks.h:
46146         (IDBTransactionCallbacks):
46147         * inspector/InspectorIndexedDBAgent.cpp:
46148         (WebCore):
46149
46150 2012-10-15  Mike Reed  <reed@google.com>
46151
46152         In Skia's ImageFrame, only set the isOpaque flag when the frame is complete
46153         https://bugs.webkit.org/show_bug.cgi?id=99326
46154
46155         Reviewed by Stephen White.
46156
46157         No new tests -- existing layouttests exercise this, esp. 
46158           png-partial-load-no-alpha.html
46159           webp-partial-load.html
46160         These two fail if skia is told that these are opaque, which it is w/o this CL.
46161
46162         At the moment, Skia has a hack to ignore the opaque-setting, so that these tests will pass as is.
46163         This change is to first, correct webkit to only set isOpaque when the frame is complete, so that
46164         in a later change, Skia can remove the hack, and re-enable its opaqueness optimization.
46165
46166         * platform/image-decoders/skia/ImageDecoderSkia.cpp:
46167         (WebCore::ImageFrame::ImageFrame):
46168         (WebCore::ImageFrame::operator=):
46169         (WebCore::ImageFrame::zeroFillPixelData):
46170         (WebCore::ImageFrame::hasAlpha):
46171         (WebCore::ImageFrame::setHasAlpha):
46172         (WebCore::ImageFrame::setStatus):
46173
46174 2012-10-12  Tony Chang  <tony@chromium.org>
46175
46176         input[type=range] as a flex item renders thumb at wrong position
46177         https://bugs.webkit.org/show_bug.cgi?id=98666
46178
46179         Reviewed by Ojan Vafai.
46180
46181         Replace RenderSlider implementation with new flexbox and clean up the shadow DOM.
46182         The previous code was trying to set the height to 100% and had a bunch of hacks in
46183         the renderer code to set an explicit height. Using the new flexbox allows us to
46184         remove these renderer hacks.
46185
46186         Test: css3/flexbox/flexitem-stretch-range.html
46187
46188         * css/html.css:
46189         (input[type="range"]::-webkit-slider-container, input[type="range"]::-webkit-media-slider-container): Use new flexbox.
46190         (input[type="range"]::-webkit-slider-runnable-track): Use new flexbox.
46191         (input[type="range"]::-webkit-slider-thumb, input[type="range"]::-webkit-media-slider-thumb): Remove relative positioning since we're
46192         no longer setting top/left in the layout code.
46193         * css/mediaControlsChromium.css: Remove redundant styles and bottom: 1px hack.
46194         * css/mediaControlsChromiumAndroid.css: Remove redundant styles and bottom: 1px hack.
46195         * html/RangeInputType.cpp:
46196         (WebCore::RangeInputType::listAttributeTargetChanged): We need to force a layout
46197         since the height of the control should change when adding/removing a datalist.
46198         * html/shadow/SliderThumbElement.cpp:
46199         (WebCore::RenderSliderContainer::RenderSliderContainer): Use new flexbox.
46200         (WebCore::RenderSliderContainer::computeLogicalHeight): Rather than setting style()->height() in layout, just compute the correct
46201         height when asked.  If we have a datalist, we increase the height (same code as before).  If we're vertical,
46202         we use the intrinsic size.
46203         (WebCore::RenderSliderContainer::layout): Remove extra layout code, but handle the position of the thumb.
46204         This used to be handled in the thumb's layout method, but I deleted that.
46205         * html/shadow/SliderThumbElement.h:
46206         * rendering/RenderSlider.cpp:
46207         (WebCore::RenderSlider::RenderSlider): Use new flexbox.
46208         (WebCore::RenderSlider::layout): Set the limiter size to the size of the thumb. This is necessary
46209         for fast/css/unknown-pseudo-element-matching.html which tries to set the height of the thumb to 1px
46210         and expects the input to also have a height of 1px.  It worked before because the height of the input
46211         didn't depend on the height of its children.
46212         * rendering/RenderSlider.h: Fix indentation.
46213         (RenderSlider): Use new flexible box.
46214
46215 2012-10-15  Julien Chaffraix  <jchaffraix@webkit.org>
46216
46217         Make RenderTable columns() and columnPositions() return a const reference
46218         https://bugs.webkit.org/show_bug.cgi?id=99339
46219
46220         Reviewed by Abhishek Arya.
46221
46222         The 2 getters were returning a non-const reference. This means that callers
46223         could have modified the Vector's where only FixedTableLayout and AutoTableLayout
46224         were expected to (for columnPositions(), no one should modify columns()).
46225
46226         Refactoring covered by existing tests.
46227
46228         * rendering/AutoTableLayout.cpp:
46229         (WebCore::AutoTableLayout::layout):
46230         * rendering/FixedTableLayout.cpp:
46231         (WebCore::FixedTableLayout::layout):
46232         Updated those functions to use the new setter.
46233
46234         * rendering/RenderTable.h:
46235         (WebCore::RenderTable::columns):
46236         (WebCore::RenderTable::columnPositions):
46237         Made the 2 functions return a const reference. They are also const now!
46238
46239         (WebCore::RenderTable::setColumnPosition):
46240         Added this setter.
46241
46242         * rendering/RenderTableSection.cpp:
46243         (WebCore::RenderTableSection::addCell):
46244         (WebCore::RenderTableSection::setCellLogicalWidths):
46245         (WebCore::RenderTableSection::dirtiedColumns):
46246         Updated to use a const reference.
46247
46248 2012-10-15  Dan Bernstein  <mitz@apple.com>
46249
46250         WebCore part of <rdar://problem/12470680> Font’s fast code path doesn’t support kerning and ligatures
46251         https://bugs.webkit.org/show_bug.cgi?id=99113
46252
46253         Reviewed by Tim Horton.
46254
46255         * WebCore.exp.in: Exported wkCTFontTransformGlyphs.
46256         * platform/graphics/Font.cpp:
46257         (WebCore::Font::width): Added a local GlyphBuffer to pass to floatWidthForSimpleText().
46258         (WebCore::Font::codePath): Rather than always use the complex code path when any typesetting
46259         features are enabled, changed to do so only if WidthIterator doesn’t support this Font’s
46260         typesetting features.
46261         * platform/graphics/FontFastPath.cpp:
46262         (WebCore::Font::getGlyphsAndAdvancesForSimpleText): Added a local GlyphBuffer to pass to
46263         WidthIterator::advance() when advancing to or from the range of interest. Added a FIXME
46264         about how this is not entirely correct when kerning or ligatures are enabled.
46265         (WebCore::Font::selectionRectForSimpleText): Added a local GlyphBuffer to pass to
46266         WidthIterator::advance() when advancing to or from the range of interest.
46267         (WebCore::Font::offsetForPositionForSimpleText): Updated for the change to
46268         WidthIterator::advanceOneCharacter().
46269         * platform/graphics/SimpleFontData.h:
46270         (WebCore::SimpleFontData::applyTransforms): Added. Calls wkCTFontTransformGlyphs() where
46271         available.
46272         * platform/graphics/WidthIterator.cpp:
46273         (WebCore::WidthIterator::WidthIterator): Added initializer for the new m_typesettingFeatures
46274         data member.
46275         (OriginalAdvancesForCharacterTreatedAsSpace): Added this data type, used to track spaces and
46276         characters treated as spaces.
46277         (WebCore::applyFontTransforms): Added. Applies shaping and positioning transforms, as
46278         required by the typesetting features, to the glyphs recently added to a GlyphBuffer, while
46279         maintaining the advances of characters that are treated as spaces and the characters
46280         preceding them, if necessary.
46281         (WebCore::WidthIterator::advanceInternal): Added calls to applyFontTransforms() at the end
46282         of each contiguous run of glyphs from the same font. Also added code to maintain a vector
46283         of spaces and characters treated as space.
46284         (WebCore::WidthIterator::advanceOneCharacter): Changed the parameter type from a pointer to
46285         a reference.
46286         * platform/graphics/WidthIterator.h:
46287         (WebCore::WidthIterator::supportsTypesettingFeatures): Added. Returns whether WidthIterator
46288         instances support the typesetting features of the given font. Returns true if the font is
46289         not a screen font and its typesetting features are kerning, ligatures or both.
46290         (WebCore::WidthIterator::shouldApplyFontTransforms): Added. Returns true if the typesetting
46291         features include kerning or ligatures.
46292         * platform/mac/WebCoreSystemInterface.h: Defined wkCTFontTransformOptions and declared
46293         wkCTFontTransformGlyphs.
46294         * platform/mac/WebCoreSystemInterface.mm: Defined wkCTFontTransformGlyphs.
46295         * rendering/svg/SVGTextMetricsBuilder.cpp:
46296         (WebCore::SVGTextMetricsBuilder::advanceSimpleText): Added a local GlyphBuffer to pass to
46297         WidthIterator::advance().
46298         * rendering/svg/SVGTextRunRenderingContext.cpp:
46299         (WebCore::SVGTextRunRenderingContext::floatWidthUsingSVGFont): Ditto.
46300
46301 2012-10-15  Mark Lam  <mark.lam@apple.com>
46302
46303         Fix build broken by r131348.
46304         https://bugs.webkit.org/show_bug.cgi?id=97533.
46305
46306         Not reviewed.
46307
46308         * rendering/RenderView.cpp:
46309         (WebCore::RenderView::layoutContent):
46310
46311 2012-10-15  Andreas Kling  <kling@webkit.org>
46312
46313         Remove WTF::fastDeleteAllValues().
46314         <http://webkit.org/b/99345>
46315
46316         Reviewed by Eric Seidel.
46317
46318         It was only used to fastDelete() a class that was already overriding operator delete
46319         by way of WTF_MAKE_FAST_ALLOCATED anyway.
46320
46321         * css/CSSParser.cpp:
46322         (WebCore::CSSParser::~CSSParser):
46323
46324 2012-10-15  Levi Weintraub  <leviw@chromium.org>
46325
46326         Regression r130057: incorrect block pref width for alternating InlineFlow and inline Replaced
46327         https://bugs.webkit.org/show_bug.cgi?id=99194
46328
46329         Reviewed by Eric Seidel.
46330
46331         Correctly breaking lines after inline replaced elements that follow inline flows. Previously, alternating
46332         these two types of elements would cause us to increase our preferred width forever.
46333
46334         Test: fast/block/block-with-inline-replaced-children-in-inline-flows.html
46335
46336         * rendering/RenderBlock.cpp:
46337         (WebCore::RenderBlock::computeInlinePreferredLogicalWidths):
46338
46339 2012-10-15  Emil A Eklund  <eae@chromium.org>
46340
46341         Revert rounding change in RenderTable::paintObject
46342         https://bugs.webkit.org/show_bug.cgi?id=99364
46343
46344         Reviewed by Levi Weintraub.
46345
46346         Bug 91410 changed RenderTable::paintObject to round the offset
46347         in order to avoid table-background bleed through. The root cause
46348         for that has since been fixed and the rounding workaround is no
46349         longer needed. This change reverts the code change from bug
46350         91410 while preserving the test added as a part of that change
46351         as it now passes without the workaround.
46352
46353         No new tests, covered by fast/sub-pixel/table-rows-no-gaps-expected.html
46354
46355         * rendering/RenderTable.cpp:
46356         (WebCore::RenderTable::paintObject):
46357         Remove unnecessary rounding.
46358
46359 2012-10-15  Michelangelo De Simone  <michelangelo@webkit.org>
46360
46361         [CSS Shaders] Add CustomFilterProgramType to CustomFilterProgramInfo
46362         https://bugs.webkit.org/show_bug.cgi?id=96448
46363
46364         Reviewed by Kenneth Rohde Christiansen.
46365
46366         CustomFilterProgramInfo has been refactored to decouple the CustomFilterProgramType from
46367         the CustomFilterProgramMixSetting: m_mixSettings.enabled was redundant in light of the fact
46368         that m_programType encoded the very same information. Dependencies have been updated to reflect
46369         this change.
46370
46371         Current tests already cover this code.
46372
46373         * css/CSSComputedStyleDeclaration.cpp: 
46374         (WebCore::CSSComputedStyleDeclaration::valueForFilter): The check for mixSettings.enabled has been replaced
46375         by an explicit check for PROGRAM_TYPE_BLENDS_ELEMENT_TEXTURE program type.
46376         * css/StyleResolver.cpp:
46377         (WebCore::StyleResolver::createCustomFilterOperation): Setting the program type explicitly while creating a
46378         new filter program.
46379         * platform/graphics/filters/CustomFilterProgram.cpp:
46380         (WebCore::CustomFilterProgram::CustomFilterProgram): CustomFilterProgram's constructor has been updated to
46381         reflect the need of setting the program type explicitly.
46382         (WebCore::CustomFilterProgram::programInfo): Updated to create new CustomFilterProgramInfo setting the program
46383         type explicitly.
46384         * platform/graphics/filters/CustomFilterProgram.h:
46385         * platform/graphics/filters/CustomFilterProgramInfo.cpp:
46386         (WebCore::CustomFilterProgramInfo::CustomFilterProgramInfo): Added m_programType and udpated the related getter.
46387         (WebCore::CustomFilterProgramInfo::hash): ditto
46388         (WebCore::CustomFilterProgramInfo::operator==): MixSettings' equality check is being performed only whether
46389         the CustomFilterProgramInfo's program type is PROGRAM_TYPE_BLENDS_ELEMENT_TEXTURE.
46390         * platform/graphics/filters/CustomFilterProgramInfo.h:
46391         (WebCore::CustomFilterProgramMixSettings::CustomFilterProgramMixSettings): Got rid of the redundant enabled flag.
46392         (WebCore::CustomFilterProgramMixSettings::operator==): ditto
46393         (CustomFilterProgramInfo):
46394         (WebCore::CustomFilterProgramInfo::programType):
46395         * platform/graphics/filters/CustomFilterValidatedProgram.cpp: The right shader validator is now being
46396         created according to the program type.
46397         (WebCore::CustomFilterValidatedProgram::CustomFilterValidatedProgram):
46398         (WebCore::CustomFilterValidatedProgram::rewriteMixVertexShader): The reference to MixSettings' enabled flag
46399         has been replaced with a check for the program type.
46400         (WebCore::CustomFilterValidatedProgram::rewriteMixFragmentShader): ditto
46401         * rendering/style/StyleCustomFilterProgram.h:
46402         (WebCore::StyleCustomFilterProgram::create): Updated to be aware of the program type.
46403         (WebCore::StyleCustomFilterProgram::StyleCustomFilterProgram): ditto
46404
46405 2012-10-15  Joshua Bell  <jsbell@chromium.org>
46406
46407         IndexedDB: Key paths should support non-ASCII identifiers
46408         https://bugs.webkit.org/show_bug.cgi?id=98814
46409
46410         Reviewed by Kentaro Hara.
46411
46412         Update the parser for key paths to use the unicode classes from
46413         the IdentifierName production in ECMA-262.
46414
46415         Test: storage/indexeddb/keypath-basics.html
46416
46417         * Modules/indexeddb/IDBKeyPath.cpp:
46418         (WebCore):
46419         (WebCore::IDBKeyPathLexer::lexIdentifier):
46420
46421 2012-10-15  Yael Aharon  <yael.aharon@intel.com>
46422
46423         [EFL][WK2][Texmap] Set gl context in GraphicsContext3DPrivate
46424         https://bugs.webkit.org/show_bug.cgi?id=99325
46425
46426         Reviewed by Kenneth Rohde Christiansen.
46427
46428         Based on a patch from Regina Chung.
46429         This piece of code was lost in the final patch of https://bugs.webkit.org/show_bug.cgi?id=96627.
46430         The gl context is used as key in a hash map and cannot be NULL.
46431
46432         No new tests. Accelerated compositing is not yet enabled in the EFL port.
46433
46434         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
46435         (WebCore::GraphicsContext3D::GraphicsContext3D):
46436
46437 2012-10-15  Mike West  <mkwst@chromium.org>
46438
46439         Console messages containing long URLs should cut at some reasonable length.
46440         https://bugs.webkit.org/show_bug.cgi?id=97980
46441
46442         Reviewed by Pavel Feldman.
46443
46444         This patch lightly modifies the current styling of linkified URLs inside
46445         console messages in order to cut them down to some reasonable size for
46446         viewing. The middle of the URL is snipped out such that the whole
46447         thing fits into 150 characters. This only effects the displayed text;
46448         the link's href isn't changed; the link remains available via the
46449         context menu, accessible via the title attribute, and clicking it still
46450         takes the user directly to the resource in question.
46451
46452         Test: inspector/console/console-trim-long-urls.html
46453
46454         * inspector/front-end/ResourceUtils.js:
46455         (WebInspector.linkifyURLAsNode):
46456             Trim the middle of the URL to bring the whole string down to  down
46457             to 150 characters, and set the link's title to the full URL.
46458
46459 2012-10-15  Tony Chang  <tony@chromium.org>
46460
46461         Add computeLogicalHeight override methods to RenderView and RenderMultiColumnSet
46462         https://bugs.webkit.org/show_bug.cgi?id=99348
46463
46464         Reviewed by Ojan Vafai.
46465
46466         Add computeLogicalHeight to the last 2 RenderBoxes that override the method.
46467         I'm unable to remove RenderMultiColumnSet::updateLogicalHeight and make the method
46468         non-virtual since it sets ComputedColumnHeight.  I'd like to remove this
46469         eventually.
46470
46471         No new tests, this is just a code refactor.
46472
46473         * rendering/RenderMultiColumnSet.cpp:
46474         (WebCore::RenderMultiColumnSet::updateLogicalHeight): Set computedColumnHeight.
46475         (WebCore::RenderMultiColumnSet::computeLogicalHeight):
46476         (WebCore):
46477         * rendering/RenderMultiColumnSet.h:
46478         (RenderMultiColumnSet):
46479         * rendering/RenderView.cpp:
46480         (WebCore::RenderView::computeLogicalHeight):
46481         * rendering/RenderView.h:
46482
46483 2012-10-15  Eunmi Lee  <eunmi15.lee@samsung.com>
46484
46485         [EFL][WK2] Refactoring initialization and shutdown codes of EFL libraries.
46486         https://bugs.webkit.org/show_bug.cgi?id=97173
46487
46488         Reviewed by Gyuyoung Kim.
46489
46490         Remove codes to initialize and shutdown the EFL libraries from
46491         RunLoopEfl.cpp. Initialization and shutdown will be done in the
46492         ewk_main.cpp for ui process and WebProcessMainEfl.cpp for web
46493         process.
46494
46495         No new tests. This patch doesn't change behavior.
46496
46497         * platform/efl/RunLoopEfl.cpp:
46498         (WebCore::RunLoop::RunLoop):
46499         (WebCore::RunLoop::~RunLoop):
46500
46501 2012-10-15  Mihnea Ovidenie  <mihnea@adobe.com>
46502
46503         [CSSRegions]Add support for auto-height regions (without region-breaks)
46504         https://bugs.webkit.org/show_bug.cgi?id=97533
46505
46506         Reviewed by Julien Chaffraix.
46507
46508         Implement the 2pass layout algorithm for computing the height of regions with auto logical height, without taking region breaks into account.
46509         The algorithm is described in the CSSRegions spec: http://dev.w3.org/csswg/css3-regions/#regions-visual-formatting-steps
46510
46511         When the flow thread contains regions with auto logical height, a 2pass layout algorithm is needed to determine the height of auto logical height regions.
46512         In each step of the layout, the regions are laid out before the flow thread is laid out.
46513
46514         In the first pass of layout (normal layout phase), the content of the flow thread is laid out unconstrained in the regions. The region marked as having auto logical height
46515         displays all the corresponding content from the flow thread (taking min-height and max-height into account), and the height of the content displayed
46516         determines the overridden logical content height. Thus, after the first pass of layout, each auto logical height region will store the logical height
46517         value for the second pass in its overridden logical content height property.
46518
46519         In the second pass of layout (constrained flow threads layout phase), when the content of the flow thread is laid out constrained in the regions, the regions are laid out again and they are using
46520         the overridden logical content height from the first pass to update their logical height. Then, the flow thread content is laid out in the associated region chain,
46521         for which the auto logical height regions have proper logical height.
46522
46523         A future patch will properly take region breaks into account for the first pass of layout.
46524
46525         Tests: fast/regions/autoheight-abspos-region.html
46526                fast/regions/autoheight-floatright-region.html
46527                fast/regions/autoheight-horizontal-bt.html
46528                fast/regions/autoheight-inlineblock-normalflow-region.html
46529                fast/regions/autoheight-maxheight-region.html
46530                fast/regions/autoheight-minheight-region.html
46531                fast/regions/autoheight-normalflow-region.html
46532                fast/regions/autoheight-vertical-lr.html
46533                fast/regions/autoheight-vertical-rl.html
46534
46535         * rendering/FlowThreadController.cpp:
46536         (WebCore::FlowThreadController::resetRegionsOverrideLogicalContentHeight):
46537         For all the auto logical height regions, resets their associated overrideLogicalContentHeight.
46538         Those regions are marked as needing layout (along with their ancestors).
46539         (WebCore::FlowThreadController::markAutoLogicalHeightRegionsForLayout):
46540         Mark all the auto logical height regions and their associated flow thread as needing layout (along with their ancestors).
46541         * rendering/FlowThreadController.h:
46542         * rendering/RenderBox.cpp:
46543         Add helper functions to clear out individual logical content width/height.
46544         (WebCore::RenderBox::clearOverrideLogicalContentHeight):
46545         (WebCore::RenderBox::clearOverrideLogicalContentWidth):
46546         (WebCore::RenderBox::clearOverrideSize):
46547         * rendering/RenderBox.h:
46548         * rendering/RenderFlowThread.cpp:
46549         (WebCore::RenderFlowThread::layout):
46550         (WebCore::RenderFlowThread::computeLogicalHeight):
46551         If the flow thread has an auto logical height region for which we did not yet compute the overrideLogicalContentHeight value,
46552         bail out early since we cannot compute the flow thread logical height.
46553         (WebCore::RenderFlowThread::regionAtBlockOffset):
46554         If the offset is inside an auto logical height region for which we did not compute the overrideLogicalContentHeight, then we consider this region tall enough to accommodate all
46555         the content and we return this region. Otherwise, for an auto logical height region, we use either the overrideLogicalContentHeight (if we are in the first layout phase) or
46556         the logicalHeight if we are in the second layout phase (because the overriderLogicalContentHeight was already transferred into region logical height).
46557         (WebCore::RenderFlowThread::pageLogicalHeightForOffset):
46558         (WebCore::RenderFlowThread::pageRemainingLogicalHeightForOffset):
46559         (WebCore::RenderFlowThread::computeOverflowStateForRegions):
46560         (WebCore::RenderFlowThread::resetRegionsOverrideLogicalContentHeight):
46561         (WebCore::RenderFlowThread::markAutoLogicalHeightRegionsForLayout):
46562         (WebCore::RenderFlowThread::updateRegionsFlowThreadPortionRect):
46563         (WebCore::RenderFlowThread::addForcedRegionBreak):
46564         Simulate a region break at the specified offset. It will be extended to properly process the region breaks. At this moment, only one auto height region for a thread
46565         can have its height properly computed.
46566         * rendering/RenderFlowThread.h:
46567         * rendering/RenderNamedFlowThread.cpp:
46568         (WebCore::boxIntersectsRegion):
46569         * rendering/RenderRegion.cpp:
46570         (WebCore::RenderRegion::updateLogicalHeight):
46571         If the auto logical height region has an overrideLogicalContentHeight and we are in the second pass of layout,
46572         we use the overrideLogicalContentHeight to update the region logical height.
46573         (WebCore::RenderRegion::needsOverrideLogicalContentHeightComputation):
46574         * rendering/RenderRegion.h:
46575         * rendering/RenderView.cpp:
46576         (WebCore::RenderView::RenderView):
46577         (WebCore::RenderView::layoutContent):
46578         Added a new function to contain the RenderView block layout and flow threads layout.
46579         (WebCore::RenderView::checkLayoutState):
46580         Helper function keeping the original asserts from RenderView, used in more than one place.
46581         (WebCore::RenderView::layout):
46582         * rendering/RenderView.h:
46583         (WebCore::RenderView::normalLayoutPhase):
46584         (WebCore::RenderView::constrainedFlowThreadsLayoutPhase):
46585
46586 2012-10-15  Eugene Klyuchnikov  <eustas.bug@gmail.com>
46587
46588         Web Inspector: Fix memory leak in TreeOutline
46589         https://bugs.webkit.org/show_bug.cgi?id=99307
46590
46591         Reviewed by Alexander Pavlov.
46592
46593         Added cleanup of empty buckets in elements cache.
46594
46595         * inspector/front-end/treeoutline.js:
46596
46597 2012-10-15  Eugene Klyuchnikov  <eustas.bug@gmail.com>
46598
46599         Web Inspector: Hide useless controls in remote-debugging mode.
46600         https://bugs.webkit.org/show_bug.cgi?id=99300
46601
46602         Reviewed by Vsevolod Vlasov.
46603
46604         "Close inspector" and "change docking mode" buttons seem to be rather
46605         useless in remote debugging mode.
46606
46607         * inspector/front-end/inspector.css:
46608         (body.remote .toolbar-item.close-left, body.remote .toolbar-item.close-right):
46609         (body.remote .dock-status-bar-item):
46610
46611 2012-10-15  Christophe Dumez  <christophe.dumez@intel.com>
46612
46613         [EFL][WK2] Implement Favicons API
46614         https://bugs.webkit.org/show_bug.cgi?id=99087
46615
46616         Reviewed by Kenneth Rohde Christiansen.
46617
46618         Moved ewk_util from WebKit to WebCore and rename it
46619         to CairoUtilityEfl so that the code can be shared
46620         between WebKit1 and WebKit2. Some related utility
46621         code was also moved from RenderThemeEfl to
46622         CairoUtilityEfl.
46623
46624         No new tests, no behavior change.
46625
46626         * PlatformEfl.cmake:
46627         * platform/efl/RenderThemeEfl.cpp:
46628         * platform/graphics/efl/CairoUtilitiesEfl.cpp: Renamed from Source/WebKit/efl/ewk/ewk_util.cpp.
46629         (WebCore):
46630         (WebCore::evasObjectFromCairoImageSurface):
46631         (WebCore::createSurfaceForBackingStore):
46632         * platform/graphics/efl/CairoUtilitiesEfl.h: Renamed from Source/WebKit/efl/ewk/ewk_util_private.h.
46633         (WebCore):
46634
46635 2012-10-15  Beth Dakin  <bdakin@apple.com>
46636
46637         https://bugs.webkit.org/show_bug.cgi?id=99350
46638         REGRESSION (r131238): Repro crash in 
46639        WebCore::ScrollingStateTree::removeNode(WebCore::ScrollingStateNode*) 
46640         opening pdf page
46641         -and corresponding-
46642         <rdar://problem/12499839>
46643
46644         Reviewed by Simon Fraser.
46645
46646         We have to null-check node here. It won't be found if  
46647         clearStateTree() was recently called.
46648         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
46649         (WebCore::ScrollingCoordinatorMac::detachFromStateTree):
46650
46651 2012-10-15  Jonathan Dong  <jonathan.dong@torchmobile.com.cn>
46652
46653         [BlackBerry] replace BlackBerry::Platform::log() with BBLOG()
46654         https://bugs.webkit.org/show_bug.cgi?id=99302
46655
46656         Reviewed by Rob Buis.
46657
46658         RIM PR: 210884
46659         The marco BBLOG() is defined as a no-op in release mode which will
46660         save a function call in the release build.
46661         Internally reviewed by Charles Wei.
46662
46663         No new tests since there's no functional change.
46664
46665         * platform/blackberry/PlatformKeyboardEventBlackBerry.cpp:
46666         (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
46667         * platform/graphics/blackberry/GraphicsContext3DBlackBerry.cpp:
46668         (WebCore::GraphicsContext3D::logFrameBufferStatus):
46669         * platform/graphics/blackberry/LayerCompositingThread.cpp:
46670         (WebCore::LayerCompositingThread::getTransformedHolePunchRect):
46671         * platform/graphics/blackberry/VideoLayerWebKitThread.cpp:
46672         (WebCore::VideoLayerWebKitThread::setHolePunchRect):
46673         (WebCore::VideoLayerWebKitThread::boundsChanged):
46674         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
46675         (WebCore::GraphicsContext3D::compileShader):
46676
46677 2012-10-15  Christophe Dumez  <christophe.dumez@intel.com>
46678
46679         [EFL] Provide logging for OnlineState detection code
46680         https://bugs.webkit.org/show_bug.cgi?id=99299
46681
46682         Reviewed by Kenneth Rohde Christiansen.
46683
46684         Add logging to NetworkStateNotifierEfl.cpp to facilitate
46685         debugging of this functionality.
46686
46687         No new tests, no behavior change.
46688
46689         * platform/network/efl/NetworkStateNotifierEfl.cpp:
46690         (WebCore::NetworkStateNotifier::updateState):
46691
46692 2012-10-15  MORITA Hajime  <morrita@google.com>
46693
46694         [Regression r131167] run-webkit-tests fails
46695         https://bugs.webkit.org/show_bug.cgi?id=99279
46696
46697         Reviewed by Kentaro Hara.
46698
46699         CodeGeneratorV8.pm assumed that there are only two objects which have constructor getters and
46700         overlooked TestObj. This fix relaxes that assumption to accept it.
46701
46702         No new tests. Fixing an existing test.
46703
46704         * bindings/scripts/CodeGeneratorV8.pm:
46705         (GenerateConstructorGetter):
46706         * bindings/scripts/test/V8/V8TestObj.cpp:
46707         (WebCore::TestObjV8Internal::TestObjConstructorGetter):
46708
46709 2012-10-15  Joe Mason  <jmason@rim.com>
46710
46711         [BlackBerry] Fix WebSockets which was disabled by recent string changes
46712         https://bugs.webkit.org/show_bug.cgi?id=99248
46713
46714         Reviewed by George Staikos.
46715
46716         PR 223681: The signature of FilterStream::notifyStatusReceived changed to take a
46717         BlackBerry::Platform::String instead of a char *. But SocketStreamHandleBlackBerry was not
46718         updated to the new signature, so the status message is not getting passed on because it is
46719         not calling the correct override.
46720
46721         No new tests because this is fixing a regression.
46722
46723         * platform/network/blackberry/SocketStreamHandle.h:
46724         (SocketStreamHandle):
46725         * platform/network/blackberry/SocketStreamHandleBlackBerry.cpp:
46726         (WebCore::SocketStreamHandle::notifyStatusReceived):
46727
46728 2012-10-15  Rob Buis  <rbuis@rim.com>
46729
46730         Remove RenderTextControl::isSelectableElement
46731         https://bugs.webkit.org/show_bug.cgi?id=99334
46732
46733         Reviewed by Andreas Kling.
46734
46735         It seems this method is not used anymore.
46736
46737         * WebCore.order:
46738         * rendering/RenderTextControl.h:
46739
46740 2012-10-15  Mike West  <mkwst@chromium.org>
46741
46742         CSP source expressions should support paths at file-level granularity.
46743         https://bugs.webkit.org/show_bug.cgi?id=99250
46744
46745         Reviewed by Adam Barth.
46746
46747         After a bit of discussion on public-webappsec[1], path support for CSP
46748         source expressions has been tuned to support file-level granularity. In
46749         particular, this means that:
46750
46751         - 'example.com/js' matches a file named 'js'
46752         - 'example.com/js/' matches all files under a directory named 'js'
46753           (note the trailing slash)
46754         - 'example.com/js/file.js' matches only a file named 'file.js'
46755           inside a directory named 'js'
46756
46757         Though this is part of the CSP 1.1 spec, it continues to be exposed
46758         outside the CSP_NEXT flag for back-compatibility.
46759
46760         Test cases have been added to the existing
46761         http/tests/security/contentSecurityPolicy/source-list-parsing-paths-*
46762         in order ensure that the new functionality works correctly.
46763
46764         * page/ContentSecurityPolicy.cpp:
46765         (WebCore::CSPSource::pathMatches):
46766             If the path ends with '/', do a prefix check. If not, check for an
46767             exact match.
46768         (WebCore::CSPSourceList::parsePath):
46769             Don't automatically append a '/' to paths.
46770
46771 2012-10-15  George Staikos  <staikos@webkit.org>
46772
46773         [BlackBerry] Adapt to Platform API changes in string handling
46774         https://bugs.webkit.org/show_bug.cgi?id=99248
46775
46776         Reviewed by Yong Li.
46777
46778         Convert usage of WebString, char* and std::string to BlackBerry::Platform::String.
46779
46780         * html/track/TextTrack.cpp:
46781         (WebCore::TextTrack::TextTrack): Fix the build for BlackBerry.
46782         * page/blackberry/SettingsBlackBerry.cpp:
46783         (WebCore):
46784         (WebCore::Settings::initializeDefaultFontFamilies):
46785         * platform/blackberry/LocalizedStringsBlackBerry.cpp:
46786         * platform/blackberry/MIMETypeRegistryBlackBerry.cpp:
46787         (WebCore::MIMETypeRegistry::getMIMETypeForExtension):
46788         (WebCore::MIMETypeRegistry::getPreferredExtensionForMIMEType):
46789         * platform/blackberry/PasteboardBlackBerry.cpp:
46790         (WebCore::Pasteboard::writeSelection):
46791         (WebCore::Pasteboard::writeURL):
46792         (WebCore::Pasteboard::writePlainText):
46793         (WebCore::Pasteboard::plainText):
46794         (WebCore::Pasteboard::documentFragment):
46795         * platform/blackberry/ReadOnlyLatin1String.h: Removed.
46796         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
46797         (WebCore::MediaPlayerPrivate::getSupportedTypes):
46798         (WebCore::MediaPlayerPrivate::supportsType):
46799         (WebCore::MediaPlayerPrivate::setCertificatePath):
46800         (WebCore::MediaPlayerPrivate::load):
46801         (WebCore::generateProtectionSpaceFromMMRAuthChallenge):
46802         (WebCore::MediaPlayerPrivate::onAuthenticationNeeded):
46803         (WebCore::MediaPlayerPrivate::onAuthenticationAccepted):
46804         (WebCore::MediaPlayerPrivate::lookupMediaStream):
46805         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.h:
46806         (MediaPlayerPrivate):
46807         (WebCore::MediaPlayerPrivate::engineDescription):
46808         * platform/network/blackberry/DNSBlackBerry.cpp:
46809         (WebCore::prefetchDNS):
46810         * platform/network/blackberry/NetworkJob.cpp:
46811         (WebCore::NetworkJob::initialize):
46812         (WebCore::NetworkJob::notifyStatusReceived):
46813         (WebCore::NetworkJob::notifyHeadersReceived):
46814         (WebCore::NetworkJob::handleNotifyClose):
46815         (WebCore::NetworkJob::sendRequestWithCredentials):
46816         * platform/network/blackberry/NetworkJob.h:
46817         (NetworkJob):
46818         * platform/network/blackberry/NetworkManager.cpp:
46819         (WebCore::NetworkManager::startJob):
46820         * platform/network/blackberry/ResourceRequestBlackBerry.cpp:
46821         (WebCore::ResourceRequest::initializePlatformRequest):
46822         * platform/network/blackberry/SocketStreamHandleBlackBerry.cpp:
46823         (WebCore::SocketStreamHandle::SocketStreamHandle):
46824         * platform/text/blackberry/StringBlackBerry.cpp:
46825         (WTF::String::String):
46826         (WTF::String::operator BlackBerry::Platform::String):
46827         * platform/text/blackberry/TextBreakIteratorInternalICUBlackBerry.cpp:
46828
46829 2012-10-15  Jay Civelli  <jcivelli@chromium.org>
46830
46831         Calling WebCore::SharedBuffer::append(data, 0) on a shared buffer when
46832         its current position is at a segment boundary (4096) ends up adding an
46833         unitialized segment (with uninitialized memory) to the SharedBuffer.
46834         https://bugs.webkit.org/show_bug.cgi?id=99000
46835
46836         Reviewed by Adam Barth.
46837
46838         * platform/SharedBuffer.cpp:
46839         (WebCore::SharedBuffer::append):
46840
46841 2012-10-15  Luke Macpherson   <macpherson@chromium.org>
46842
46843         Make CSS variable names case-insensitive.
46844         https://bugs.webkit.org/show_bug.cgi?id=98712
46845
46846         Reviewed by Tony Chang.
46847
46848         This patch modifies the parser to normalize all variable names to lower case,
46849         making variable definitions consistent with other property names, which are also case insensitive.
46850         Spec: http://dev.w3.org/csswg/css-variables/#defining-variables
46851
46852         Test: fast/css/variables/case-insensitive.html
46853
46854         * css/CSSParser.cpp:
46855         (WebCore::CSSParser::createPrimitiveNumericValue):
46856         (WebCore):
46857         (WebCore::CSSParser::createPrimitiveVariableNameValue):
46858         (WebCore::CSSParser::parseValidPrimitive):
46859         (WebCore::CSSParser::parseValue):
46860         (WebCore::CSSParser::storeVariableDeclaration):
46861         (WebCore::CSSParserString::lowerSubstring):
46862         Added function to compute a lower case substring as an AtomicString from a CSSParserString.
46863         * css/CSSParser.h:
46864         (CSSParser):
46865         * css/CSSParserValues.h:
46866         (CSSParserString):
46867         (WebCore::CSSParserString::lowerSubstring):
46868
46869 2012-10-15  Michael Saboff  <msaboff@apple.com>
46870
46871         Update RenderText to use String instead of UChar* for text
46872         https://bugs.webkit.org/show_bug.cgi?id=96979
46873
46874         Reviewed by Dan Bernstein.
46875
46876         RenderText now uses a String for text.  It keeps a cached LCHar* or UChar* pointer to the
46877         actual text data for performance.  Added a characterAt() indexed accessor to RenderText to avoid the
46878         somewhat confusing construct for a RenderText* rt, e.g. (*re)[n] or rt->characters()[n].  This is
46879         now written as rt->characterAt(n).
46880         Enabled patch in the HTML parser to create 8 bit text data.  Modified TextRun to create 
46881         text runs using 8 bit string data where possible.  Added several flavors of RenderBlock::constructTextRun
46882         to create TextRuns from RenderText objects including with an offset.  Added an LChar flavor of constructTextRun()
46883         as well.  Eliminated the TextRunFlags argument to all but the String flavor as all other flavors used the default
46884         parameter.  
46885         Encased the code that creates 8 bit TextRun's in #if USE(8BIT_TEXTRUN).  Enabled WTF_USE_8BIT_TEXTRUN
46886         for PLATFORM(MAC).  Other platform can update this setting in Platform.h when their platform specific code is
46887         updated to TextRun's with 8 bit data.
46888         Added many 8/16 bit aware paths.  Cleanup up some int / unsigned confusion in RenderBlockLineLayout.cpp.
46889
46890         No function change therefore no new tests.
46891
46892         * html/parser/HTMLTokenizer.cpp:
46893         (WebCore::vectorEqualsString):
46894         (WebCore::HTMLTokenizer::nextToken):
46895         * html/parser/HTMLTokenizer.h:
46896         (HTMLTokenizer):
46897         * html/track/WebVTTTokenizer.cpp:
46898         (WebCore::vectorEqualsString):
46899         (WebCore::WebVTTTokenizer::nextToken):
46900         * html/track/WebVTTTokenizer.h:
46901         (WebVTTTokenizer):
46902         * platform/graphics/Font.h:
46903         (WebCore::Font::glyphDataForCharacter):
46904         * platform/graphics/FontFastPath.cpp:
46905         (WebCore):
46906         * platform/graphics/TextRun.h:
46907         (WebCore::TextRun::TextRun):
46908         (WebCore::TextRun::subRun):
46909         (TextRun):
46910         * platform/graphics/mac/ComplexTextController.cpp:
46911         (WebCore::TextLayout::isNeeded):
46912         (WebCore::TextLayout::constructTextRun):
46913         * rendering/InlineFlowBox.cpp:
46914         (WebCore::InlineFlowBox::placeBoxesInInlineDirection):
46915         * rendering/InlineIterator.h:
46916         (WebCore::InlineIterator::atTextParagraphSeparator):
46917         (WebCore::InlineIterator::current):
46918         (WebCore::InlineIterator::previousInSameNode):
46919         * rendering/InlineTextBox.cpp:
46920         (WebCore::adjustCharactersAndLengthForHyphen):
46921         (WebCore::InlineTextBox::paint):
46922         (WebCore::InlineTextBox::paintSelection):
46923         (WebCore::InlineTextBox::constructTextRun):
46924         * rendering/InlineTextBox.h:
46925         (InlineTextBox):
46926         * rendering/RenderBlock.cpp:
46927         (WebCore::constructTextRunInternal):
46928         (WebCore::RenderBlock::constructTextRun):
46929         * rendering/RenderBlock.h:
46930         (RenderBlock):
46931         * rendering/RenderBlockLineLayout.cpp:
46932         (WebCore::endsWithASCIISpaces):
46933         (WebCore::reachedEndOfTextRenderer):
46934         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine):
46935         (WebCore::shouldSkipWhitespaceAfterStartObject):
46936         (WebCore::textWidth):
46937         (WebCore::tryHyphenating):
46938         (WebCore::RenderBlock::LineBreaker::nextLineBreak):
46939         * rendering/RenderCombineText.cpp:
46940         (WebCore::RenderCombineText::getStringToRender):
46941         (WebCore::RenderCombineText::combineText):
46942         * rendering/RenderCombineText.h:
46943         (RenderCombineText):
46944         * rendering/RenderText.cpp:
46945         (SameSizeAsRenderText):
46946         (WebCore::RenderText::RenderText):
46947         (WebCore::RenderText::widthFromCache):
46948         (WebCore::RenderText::computePreferredLogicalWidths):
46949         (WebCore::RenderText::setTextInternal):
46950         (WebCore::RenderText::width):
46951         * rendering/RenderText.h:
46952         (WebCore::RenderText::is8Bit):
46953         (WebCore::RenderText::characters8):
46954         (WebCore::RenderText::characters16):
46955         (WebCore::RenderText::characterAt):
46956         (WebCore::RenderText::operator[]):
46957         (RenderText):
46958         * xml/parser/MarkupTokenBase.h:
46959         (WebCore::MarkupTokenBase::appendToCharacter):
46960         (MarkupTokenBase):
46961         (WebCore::MarkupTokenBase::isAll8BitData):
46962
46963 2012-10-15  Vsevolod Vlasov  <vsevik@chromium.org>
46964
46965         Web Inspector: Scripts for dynamically added script elements are not shown in sources panel.
46966         https://bugs.webkit.org/show_bug.cgi?id=99324
46967
46968         Reviewed by Pavel Feldman.
46969
46970         NetworkUISourceCodeProvider now adds uiSourceCodes for dynamic anonymous scripts
46971         and dynamic scripts loaded before inspector was opened.
46972
46973         Tests: http/tests/inspector-enabled/dynamic-scripts.html
46974                inspector/debugger/dynamic-scripts.html
46975
46976         * inspector/front-end/NetworkLog.js:
46977         (WebInspector.NetworkLog.prototype.requestForURL):
46978         * inspector/front-end/NetworkUISourceCodeProvider.js:
46979         (WebInspector.NetworkUISourceCodeProvider):
46980         (WebInspector.NetworkUISourceCodeProvider.prototype._parsedScriptSource):
46981         (WebInspector.NetworkUISourceCodeProvider.prototype._projectWillReset):
46982
46983 2012-10-15  Dominik Röttsches  <dominik.rottsches@intel.com>
46984
46985         REGRESSION(130613): Reintroduces crashes when using soup's timeout functionality
46986         https://bugs.webkit.org/show_bug.cgi?id=99311
46987
46988         Reviewed by Gustavo Noronha Silva.
46989
46990         Removing the cleanupSoupRequestOperation call, since the cancel() call will eventually trigger the
46991         cleanup already setting the right flag. Cleaning the handle already here will result in crashes when
46992         using the soup timeout functionality.
46993         The explicit cleanup call reintroduced in r130613, after it had been previously removed in r130348.
46994
46995         No new tests, tests that catch this will be part of bug 74802 for XHR timeout support.
46996
46997         * platform/network/soup/ResourceHandleSoup.cpp:
46998         (WebCore::requestTimeoutCallback):
46999
47000 2012-10-15  Ilya Tikhonovsky  <loislo@chromium.org>
47001
47002         Web Inspector: convert manual size calculation of different WebKit things into MemoryInstrumentation.
47003         https://bugs.webkit.org/show_bug.cgi?id=99309
47004
47005         Reviewed by Yury Semikhatsky.
47006
47007         JSHeap, DOMStorage and HeapProfiler data were counted manually.
47008         Now we count the sizes more generic way.
47009
47010         * dom/WebCoreMemoryInstrumentation.cpp:
47011         * dom/WebCoreMemoryInstrumentation.h:
47012         (WebCoreMemoryTypes): new string identifiers were added for Inspector's data.
47013         * inspector/InspectorBaseAgent.cpp:
47014         (WebCore::InspectorBaseAgentInterface::InspectorBaseAgentInterface): common data members were moved from template to base class.
47015         (WebCore::InspectorBaseAgentInterface::reportMemoryUsage): NMI instrumentation was added to the base template.
47016         * inspector/InspectorBaseAgent.h:
47017         (InspectorBaseAgentInterface): ditto
47018         (WebCore::InspectorBaseAgent::InspectorBaseAgent): ditto
47019         * inspector/InspectorController.cpp:
47020         (WebCore::InspectorController::reportMemoryUsage): NMI instrumentation was added to the class.
47021         * inspector/InspectorController.h:
47022         * inspector/InspectorDOMStorageAgent.cpp:
47023         (WebCore::InspectorDOMStorageAgent::reportMemoryUsage): NMI instrumentation was added to the class.
47024         * inspector/InspectorDOMStorageAgent.h:
47025         * inspector/InspectorDOMStorageResource.cpp:
47026         (WebCore::InspectorDOMStorageResource::reportMemoryUsage): NMI instrumentation was added to the class.
47027         * inspector/InspectorDOMStorageResource.h:
47028         * inspector/InspectorMemoryAgent.cpp:
47029         (WebCore::reportJSHeapInfo): these methods now use MemoryInstrumentation for reporting the size of underlying data.
47030         (WebCore::reportRenderTreeInfo):
47031         (WebCore::collectDomTreeInfo):
47032         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
47033         (WebCore::InspectorMemoryAgent::reportMemoryUsage): NMI instrumentation was added to the class.
47034         * inspector/InspectorMemoryAgent.h:
47035         * inspector/InspectorProfilerAgent.cpp:
47036         (WebCore::InspectorProfilerAgent::reportMemoryUsage):
47037         * inspector/InspectorProfilerAgent.h:
47038         (InspectorProfilerAgent): NMI instrumentation was added to the class.
47039         * inspector/MemoryInstrumentationImpl.cpp: allocatedObjects map was converted from InspectorMemoryAgent::getProcessMemoryDistribution local variable to member variable.
47040         (WebCore::MemoryInstrumentationClientImpl::checkCountedObject):
47041         (WebCore::MemoryInstrumentationClientImpl::reportMemoryUsage): NMI instrumentation was added to the class.
47042         (WebCore::MemoryInstrumentationImpl::reportMemoryUsage): NMI instrumentation was added to the class.
47043         * inspector/MemoryInstrumentationImpl.h:
47044         (WebCore::MemoryInstrumentationClientImpl::MemoryInstrumentationClientImpl):
47045         (WebCore::MemoryInstrumentationClientImpl::allocatedObjects):
47046         (WebCore::MemoryInstrumentationClientImpl::checkInstrumentedObjects):
47047         * inspector/front-end/NativeMemorySnapshotView.js:
47048         (WebInspector.MemoryBlockViewProperties._initialize):
47049         (WebInspector.NativeMemoryBarChart.prototype._updateView):
47050         * page/Page.cpp:
47051         (WebCore::Page::reportMemoryUsage): NMI instrumentation was added to the class.
47052         * page/Page.h:
47053
47054 2012-10-15  Kent Tamura  <tkent@chromium.org>
47055
47056         Improve code of LocaleMac.mm
47057         https://bugs.webkit.org/show_bug.cgi?id=98383
47058
47059         Reviewed by Darin Adler.
47060
47061         - Use isNull instead of isEmpty because isNull is more efficient.
47062         - create*Formatter should return RetainPtr to avoid to retain in each of callsites.
47063         - Explicit String conversion is not needed.
47064
47065         No new tests. This doesn't change any behavior.
47066
47067         * platform/text/mac/LocaleMac.h:
47068         (LocaleMac):
47069         - Change the return types of createShortDateFormatter,
47070         createTimeFormatter, and createShortTimeFormatter from NSDateFormatter*
47071         to RetainPtr<NSDateFormatter>.
47072         - Omit 'create' from their names.
47073         - Add m_gregorianCalendar.
47074         * platform/text/mac/LocaleMac.mm:
47075         (WebCore::createDateTimeFormatter):
47076         Change the return type from NSDateFormatter* to RetainPtr<NSDateFormatter>.
47077         Add an NSCalendar argument.
47078         (WebCore::LocaleMac::shortDateFormatter):
47079         Renamed from createShortTimeFormatter.
47080         Change the return type from NSDateFormatter* to RetainPtr<NSDateFormatter>.
47081         (WebCore::LocaleMac::parseDateTime): Follow the return type change and the renaming.
47082         (WebCore::LocaleMac::formatDateTime): Ditto. Also, remove explicit String construction.
47083         (WebCore::LocaleMac::dateFormatText): Ditto. Also, use isNull.
47084         (WebCore::LocaleMac::monthLabels): Follow the return type change and the renaming.
47085         (WebCore::LocaleMac::weekDayShortLabels): Ditto.
47086         (WebCore::LocaleMac::timeFormatter):
47087         Change the return type from NSDateFormatter* to RetainPtr<NSDateFormatter>.
47088         Renamed from createTimeFormatter.
47089         (WebCore::LocaleMac::shortTimeFormatter): Ditto.
47090         (WebCore::LocaleMac::dateFormat):
47091         Use isNull. Remove explicit String construction. Follow the return type
47092         change and the renaming.
47093         (WebCore::LocaleMac::timeFormat): ditto.
47094         (WebCore::LocaleMac::shortTimeFormat): ditto.
47095         (WebCore::LocaleMac::timeAMPMLabels):
47096         Remove explicit String construction. Follow the return type change.
47097         (WebCore::LocaleMac::initializeLocalizerData):
47098         Remove explicit String construction.
47099
47100 2012-10-12  Ilya Tikhonovsky  <loislo@chromium.org>
47101
47102         Web Inspector: NMI remove hand made object builders with automatic builder.
47103         https://bugs.webkit.org/show_bug.cgi?id=99186
47104
47105         Reviewed by Yury Semikhatsky.
47106
47107         Old builders were replaced with single automatic builder.
47108         It does the next things:
47109         a) deduplicates entries in the MemoryInstrumentationClient's map and converts objectType pointers to String;
47110         b) creates parent entries and assigns their aggregated sizes;
47111         c) creates the hierarchy of MemoryBlocks recursively.
47112
47113         * dom/WebCoreMemoryInstrumentation.cpp:
47114         (WebCore):
47115         * dom/WebCoreMemoryInstrumentation.h:
47116         (WebCoreMemoryTypes):
47117         * inspector/InspectorMemoryAgent.cpp:
47118         (WebCore):
47119         (WebCore::jsHeapInfo):
47120         (WebCore::renderTreeInfo):
47121         (WebCore::addPlatformComponentsInfo):
47122         (WebCore::InspectorMemoryAgent::getProcessMemoryDistribution):
47123         * inspector/MemoryInstrumentationImpl.cpp:
47124         (WebCore::MemoryInstrumentationClientImpl::sizesMap):
47125         (WebCore):
47126         * inspector/MemoryInstrumentationImpl.h:
47127         (WebCore):
47128         (MemoryInstrumentationClientImpl):
47129
47130 2012-10-14  Sam Weinig  <sam@webkit.org>
47131
47132         Simplify user content in WebKit2 by using WebCore::UserStyleSheet and WebCore::UserScript directly
47133         https://bugs.webkit.org/show_bug.cgi?id=99276
47134
47135         Reviewed by Anders Carlsson.
47136
47137         Add default constructors for UserScript and UserStyleSheet so they can be used in CoreIPC encoding/decoding.
47138
47139         * page/UserScript.h:
47140         (WebCore::UserScript::UserScript):
47141         (UserScript):
47142         * page/UserStyleSheet.h:
47143         (WebCore::UserStyleSheet::UserStyleSheet):
47144         (UserStyleSheet):
47145
47146 2012-10-14  Jon Lee  <jonlee@apple.com>
47147
47148         Allow notification origin permission request when no js callback is provided
47149         https://bugs.webkit.org/show_bug.cgi?id=63615
47150         <rdar://problem/11059590>
47151
47152         Reviewed by Sam Weinig.
47153
47154         Instead of throwing a type error when no callback is provided, we pass a null callback.
47155
47156         Test: http/tests/notifications/legacy/request-no-callback.html
47157
47158         * bindings/js/JSDesktopNotificationsCustom.cpp:
47159         (WebCore::JSNotificationCenter::requestPermission):
47160
47161 2012-10-12  Anders Carlsson  <andersca@apple.com>
47162
47163         Move QDataStream functions into HistoryItemQt.cpp
47164         https://bugs.webkit.org/show_bug.cgi?id=99203
47165
47166         Reviewed by Andreas Kling.
47167
47168         It seems like the QDataStream stream operators are only used from HistoryItemQt.cpp
47169         inside WebCore, so move them there. If in the future they are required elsewhere, they should
47170         be moved into a separate header instead of polluting headers unnecessarily.
47171
47172         * history/qt/HistoryItemQt.cpp:
47173         (operator<<):
47174         (operator>>):
47175         * platform/FractionalLayoutUnit.h:
47176         * platform/graphics/IntPoint.h:
47177
47178 2012-10-14  Sam Weinig  <sam@webkit.org>
47179
47180         Make UserScript and UserStyleSheet value objects that are copyable
47181         https://bugs.webkit.org/show_bug.cgi?id=99275
47182
47183         Reviewed by Tim Horton.
47184
47185         Simplify UserScript and UserStyleSheet and make them more easily usable
47186         without sticking them in an OwnPtr.
47187
47188         * WebCore.exp.in:
47189         Update exports.
47190
47191         * page/PageGroup.cpp:
47192         (WebCore::PageGroup::addUserScriptToWorld):
47193         (WebCore::PageGroup::addUserStyleSheetToWorld):
47194         * page/PageGroup.h:
47195         (PageGroup):
47196         * page/UserContentURLPattern.cpp:
47197         (WebCore::UserContentURLPattern::matchesPatterns):
47198         * page/UserContentURLPattern.h:
47199         (UserContentURLPattern):
47200         Update to not assume whitelist and blacklist are in Vector<String>*.
47201
47202         * page/UserScript.h:
47203         (UserScript):
47204         (WebCore::UserScript::UserScript):
47205         (WebCore::UserScript::whitelist):
47206         (WebCore::UserScript::blacklist):
47207         * page/UserStyleSheet.h:
47208         (UserStyleSheet):
47209         (WebCore::UserStyleSheet::UserStyleSheet):
47210         (WebCore::UserStyleSheet::whitelist):
47211         (WebCore::UserStyleSheet::blacklist):
47212         Switch OwnPtr<Vector<String> > to Vector<String> and remove Noncopyable restriction.
47213
47214 2012-10-14  Tim Horton  <timothy_horton@apple.com>
47215
47216         [wk2] Implement PDFPlugin
47217         https://bugs.webkit.org/show_bug.cgi?id=99206
47218
47219         Unreviewed build fix, export __ZN7WebCore8IntPointC1ERK7CGPoint.
47220
47221         * WebCore.exp.in:
47222
47223 2012-10-14  Tim Horton  <timothy_horton@apple.com>
47224
47225         [wk2] Implement PDFPlugin
47226         https://bugs.webkit.org/show_bug.cgi?id=99206
47227
47228         Reviewed by Dan Bernstein.
47229
47230         Add a plug-in that uses PDFKit to display PDFs, instead of using PDFKit in the
47231         UIProcess for full-page PDFs. This new plugin will also be used for inline PDFs
47232         in place of SimplePDFPlugin (née BuiltInPDFView).
47233
47234         * WebCore.exp.in:
47235         Export a few more methods to WebKit(2).
47236
47237         * WebCore.xcodeproj/project.pbxproj:
47238         Expose Pasteboard.h as a private header so PDFPlugin can use it.
47239
47240         * platform/ScrollableArea.h:
47241         Make invalidateScrollbar/invalidateScrollCorner virtual.
47242
47243 2012-10-14  Antoine Quint  <graouts@apple.com>
47244
47245         InspectorPageAgent should expose a method to control the compositing debug settings.
47246         https://bugs.webkit.org/show_bug.cgi?id=99253
47247
47248         Reviewed by Timothy Hatcher.
47249
47250         * inspector/Inspector.json:
47251         * inspector/InspectorPageAgent.cpp:
47252         (WebCore::InspectorPageAgent::setCompositingBordersVisible):
47253         * inspector/InspectorPageAgent.h:
47254
47255 2012-10-13  Chris Rogers  <crogers@google.com>
47256
47257         WebAudioBus needs support for resizing bus to a smaller size
47258         https://bugs.webkit.org/show_bug.cgi?id=99215
47259
47260         Reviewed by Dimitri Glazkov.
47261
47262         Upgrade AudioBus and WebAudioBus to support resizing to a smaller size, once it has been created.
47263         This is useful, for example, when decoding VBR formats and the actual length can't be exactly determined
47264         until the entire file is decoded.
47265
47266         * platform/audio/AudioBus.cpp:
47267         (WebCore::AudioBus::resizeSmaller):
47268         (WebCore):
47269         * platform/audio/AudioBus.h:
47270         (AudioBus):
47271         * platform/audio/AudioChannel.cpp:
47272         (WebCore::AudioChannel::resizeSmaller):
47273         (WebCore):
47274         * platform/audio/AudioChannel.h:
47275         (AudioChannel):
47276         * platform/chromium/support/WebAudioBus.cpp:
47277         (WebKit::WebAudioBus::resizeSmaller):
47278         (WebKit):
47279
47280 2012-10-13  Gregg Tavares  <gman@google.com>
47281
47282         Add warning for unrenderable textures
47283         https://bugs.webkit.org/show_bug.cgi?id=99235
47284
47285         Reviewed by Kenneth Russell.
47286
47287         Unrenderable textures are often hard to debug. Adds a message to that
47288         appears in the JavaScript console to help developers find the issue.
47289
47290         No new tests as no new functionality.
47291
47292         * html/canvas/WebGLRenderingContext.cpp:
47293         (WebCore):
47294         (WebCore::WebGLRenderingContext::drawArrays):
47295         (WebCore::WebGLRenderingContext::drawElements):
47296         (WebCore::WebGLRenderingContext::handleNPOTTextures):
47297         * html/canvas/WebGLRenderingContext.h:
47298         (WebGLRenderingContext):
47299
47300 2012-10-13  Geoffrey Garen  <ggaren@apple.com>
47301
47302         Not reviewed.
47303
47304         Updated bindings test results.
47305
47306         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
47307         (WebCore::JSTestEventTarget::getOwnPropertySlotByIndex):
47308
47309 2012-10-12  Geoffrey Garen  <ggaren@apple.com>
47310
47311         I pity da foo' who's converting numbers to strings
47312         https://bugs.webkit.org/show_bug.cgi?id=99197
47313
47314         Reviewed by Gavin Barraclough.
47315
47316         40% speedup on PerformanceTests/Dromaeo/dom-traverse.html. Probably speeds
47317         some other things up too.
47318
47319         Credit to Eric Seidel for spotting this.
47320
47321         * bindings/scripts/CodeGeneratorJS.pm:
47322         (GenerateImplementation): getOwnPropertySlotByIndex doesn't need to prefer
47323         string lookup in the static table because our static tables don't contain
47324         properties that are numbers.
47325
47326         I believe this is low-hanging fruit left behind by Phil's
47327         getOwnPropertySlotByIndex optimization, but it's also possible that this was a
47328         regression at some point. I didn't check.
47329
47330 2012-10-13  Adam Barth  <abarth@webkit.org>
47331
47332         Remove dead code in Node.idl
47333         https://bugs.webkit.org/show_bug.cgi?id=99237
47334
47335         Reviewed by Maciej Stachowiak.
47336
47337         We don't implement this feature. This code is dead and should be
47338         removed.
47339
47340         * dom/Node.idl:
47341
47342 2012-10-12  Simon Fraser  <simon.fraser@apple.com>
47343
47344         Fix GraphicsLayerCA visible rect computation in the face of perspective and preserve-3d
47345         https://bugs.webkit.org/show_bug.cgi?id=99212
47346
47347         Reviewed by Tim Horton.
47348
47349         GraphicsLayerCA::computeVisibleRect() was incorrect for layer trees with perspective
47350         and preserve-3d, so fix that, and add some tests.
47351         
47352         Perspective is implemented via childrenTransform(); if our parent has one,
47353         we have to left-multiply this into the transformation matrix.
47354         
47355         We have to test both this layer and its parent when deciding whether to accumulate
47356         or flatten.
47357         
47358         Use state.mappedQuad() rather than state.lastPlanarQuad(), because the last planar
47359         quad might be for some distant ancestor, and there may be intermediate preserve-3d
47360         layers.
47361
47362         Tests: compositing/visible-rect/3d-transform-style.html
47363                compositing/visible-rect/3d-transformed.html
47364                compositing/visible-rect/nested-transform.html
47365
47366         * platform/graphics/ca/GraphicsLayerCA.cpp:
47367         (WebCore::GraphicsLayerCA::computeVisibleRect):
47368
47369 2012-10-11  Simon Fraser  <simon.fraser@apple.com>
47370
47371         Move TransformState code into its own member function, and remove a test that was prematurely added
47372         https://bugs.webkit.org/show_bug.cgi?id=99117
47373
47374         Reviewed by Tim Horton.
47375
47376         The code that manipulates the TransformState and computes the visible rect is going to get
47377         more complex, so move it into a new member function.
47378
47379         * platform/graphics/ca/GraphicsLayerCA.cpp:
47380         (WebCore::GraphicsLayerCA::computeVisibleRect):
47381         (WebCore::GraphicsLayerCA::recursiveCommitChanges):
47382         * platform/graphics/ca/GraphicsLayerCA.h:
47383         (GraphicsLayerCA):
47384
47385 2012-10-12  Simon Fraser  <simon.fraser@apple.com>
47386
47387         Add some initial visible rect tests and tweak the visible wash layer
47388         https://bugs.webkit.org/show_bug.cgi?id=99095
47389
47390         Reviewed by Tim Horton.
47391
47392         Make the m_visibleTileWashLayer more useful by showing it for all
47393         layers with transforms, not just tiled layers. This is a debugging
47394         layer normally disabled, but enabled by #defining VISIBLE_TILE_WASH.
47395
47396         Tests: compositing/visible-rect/2d-transformed.html
47397                compositing/visible-rect/3d-transformed.html
47398                compositing/visible-rect/clipped-by-viewport copy.html
47399                compositing/visible-rect/clipped-by-viewport.html
47400                compositing/visible-rect/clipped-visible-rect.html
47401
47402         * platform/graphics/ca/GraphicsLayerCA.cpp:
47403         (WebCore::GraphicsLayerCA::recursiveCommitChanges):
47404         (WebCore::GraphicsLayerCA::swapFromOrToTiledLayer):
47405         * platform/graphics/ca/GraphicsLayerCA.h:
47406
47407 2012-10-12  Pablo Flouret  <pablof@motorola.com>
47408
47409         Teach GeneratorGObject about [ImplementedAs] extended attribute in functions
47410         https://bugs.webkit.org/show_bug.cgi?id=99214
47411
47412         Reviewed by Kentaro Hara.
47413
47414         No new tests, updated the binding tests results.
47415
47416         * bindings/scripts/CodeGeneratorGObject.pm:
47417         (GenerateFunction):
47418         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
47419         (webkit_dom_test_obj_orange):
47420
47421 2012-10-12  Beth Dakin  <bdakin@apple.com>
47422
47423         https://bugs.webkit.org/show_bug.cgi?id=99211
47424         When ScrollingStateNodes are destroyed, they should be removed 
47425         ScrollingCoordinator's HashMap
47426
47427         Reviewed by Sam Weinig.
47428
47429         This patch adds a new member variable to ScrollingStateTree. It's a 
47430         Vector of ScrollingNodeIDs. It will contain the IDs of nodes that 
47431         have been removed from the tree since the last time the tree was 
47432         committed.
47433         * page/scrolling/ScrollingStateTree.cpp:
47434         (WebCore::ScrollingStateTree::ScrollingStateTree):
47435
47436         When we do commit, copy the Vector over into the cloned tree, and 
47437         then clear our own Vector.
47438         (WebCore::ScrollingStateTree::commit):
47439
47440         Call didRemoveNode().
47441         (WebCore::ScrollingStateTree::removeNode):
47442
47443         Append the removed node's id to the vector.
47444         (WebCore::ScrollingStateTree::didRemoveNode):
47445         (WebCore):
47446         * page/scrolling/ScrollingStateTree.h:
47447         (ScrollingStateTree):
47448
47449         Call didRemoveNode().
47450         * page/scrolling/ScrollingStateNode.cpp:
47451         (WebCore::ScrollingStateNode::removeChild):
47452
47453         Fix the FIXME!
47454         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
47455         (WebCore::ScrollingCoordinatorMac::detachFromStateTree):
47456
47457 2012-10-12  Brady Eidson  <beidson@apple.com>
47458
47459         Setup basic NetworkProcess messaging and initialization.
47460         https://bugs.webkit.org/show_bug.cgi?id=99198
47461
47462         Reviewed by Sam Weinig.
47463
47464         * English.lproj/Localizable.strings: Update for the Network Process UI name.
47465
47466 2012-10-12  Levi Weintraub  <leviw@chromium.org>
47467
47468         Remove unnecessary mode identifiers added in r131111
47469         https://bugs.webkit.org/show_bug.cgi?id=99208
47470
47471         Reviewed by Emil A Eklund.
47472
47473         Removing unnecessary mode identifiers from coordinate conversion methods. These
47474         were added in http://trac.webkit.org/changeset/131111
47475
47476         No new tests. No change in behavior.
47477
47478         * rendering/RenderBox.h:
47479         (RenderBox):
47480         * rendering/RenderBoxModelObject.h:
47481         (RenderBoxModelObject):
47482         * rendering/RenderInline.h:
47483         (RenderInline):
47484         * rendering/RenderObject.h:
47485         (RenderObject):
47486         * rendering/RenderView.h:
47487         (RenderView):
47488         * rendering/svg/RenderSVGForeignObject.h:
47489         (RenderSVGForeignObject):
47490         * rendering/svg/RenderSVGInline.h:
47491         (RenderSVGInline):
47492         * rendering/svg/RenderSVGModelObject.h:
47493         (RenderSVGModelObject):
47494         * rendering/svg/RenderSVGRoot.h:
47495         (RenderSVGRoot):
47496         * rendering/svg/RenderSVGText.h:
47497         (RenderSVGText):
47498
47499 2012-10-12  Sheriff Bot  <webkit.review.bot@gmail.com>
47500
47501         Unreviewed, rolling out r131224.
47502         http://trac.webkit.org/changeset/131224
47503         https://bugs.webkit.org/show_bug.cgi?id=99210
47504
47505         It broke the build (Requested by andersca on #webkit).
47506
47507         * history/qt/HistoryItemQt.cpp:
47508         * platform/FractionalLayoutUnit.h:
47509         (WebCore):
47510         (WebCore::operator<<):
47511         (WebCore::operator>>):
47512         * platform/graphics/IntPoint.h:
47513         (WebCore):
47514         (WebCore::operator<<):
47515         (WebCore::operator>>):
47516
47517 2012-10-12  Anders Carlsson  <andersca@apple.com>
47518
47519         Move QDataStream functions into HistoryItemQt.cpp
47520         https://bugs.webkit.org/show_bug.cgi?id=99203
47521
47522         Reviewed by Andreas Kling.
47523
47524         It seems like the QDataStream stream operators are only used from HistoryItemQt.cpp
47525         inside WebCore, so move them there. If in the future they are required elsewhere, they should
47526         be moved into a separate header instead of polluting headers unnecessarily.
47527
47528         * history/qt/HistoryItemQt.cpp:
47529         (operator<<):
47530         (operator>>):
47531         * platform/FractionalLayoutUnit.h:
47532         * platform/graphics/IntPoint.h:
47533
47534 2012-10-12  Beth Dakin  <bdakin@apple.com>
47535
47536         https://bugs.webkit.org/show_bug.cgi?id=99204
47537         ScrollingStateNodes should keep track of their IDs
47538
47539         Reviewed by Simon Fraser.
47540
47541         There is a HashMap in ScrollingCoordinatorMac that maps 
47542         ScrollingNodeIDs to ScrollingStateNodes. The nodes themselves should 
47543         keep track of this id. Then the id can be used to make sure 
47544         ScrollingStateNodes remove themselves from the HashMap when they are 
47545         destroyed, and it will also be useful for associating 
47546         ScrollingStateNodes with ScrollingTreeNodes over on the scrolling 
47547         thread.
47548   
47549         This patch only has the ScrollingStateNodes cache the id. I will 
47550         actually make use of the id in follow-up patches.
47551
47552         * page/scrolling/ScrollingStateNode.cpp:
47553         (WebCore::ScrollingStateNode::ScrollingStateNode):
47554         * page/scrolling/ScrollingStateNode.h:
47555         (ScrollingStateNode):
47556         (WebCore::ScrollingStateNode::scrollingNodeID):
47557         * page/scrolling/ScrollingStateScrollingNode.cpp:
47558         (WebCore::ScrollingStateScrollingNode::create):
47559         (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
47560         * page/scrolling/ScrollingStateScrollingNode.h:
47561         (ScrollingStateScrollingNode):
47562         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
47563         (WebCore::ScrollingCoordinatorMac::attachToStateTree):
47564
47565 2012-10-01  Jer Noble  <jer.noble@apple.com>
47566
47567         Add LSKD support to MediaPlayerPrivateAVFoundation.
47568         https://bugs.webkit.org/show_bug.cgi?id=98090
47569
47570         Reviewed by Anders Carlsson.
47571
47572         Add support for LSKD key system to MediaPlayerPrivateAVFoundation.
47573
47574         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
47575         (MediaPlayerPrivateAVFoundationObjC): Add m_loaderDelegate, m_keyURIToRequestMap, and m_sessionToRequestMap.
47576         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
47577         (globalLoaderDelegateQueue): Static accessor for the dispatch queue to use for the loader delegate.
47578         (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC):
47579         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Add the loader delegate to the AVURLAsset.
47580         (WebCore::keySystemIsSupported): Convenience function; checks that the key system matches "com.apple.lskd"
47581         (WebCore::MediaPlayerPrivateAVFoundationObjC::extendedSupportsType): Check the key system matches.
47582         (WebCore::MediaPlayerPrivateAVFoundationObjC::shouldWaitForLoadingOfResource): Fire a needkey event with an initData containing
47583             the key URI.
47584         (WebCore::extractKeyURIKeyIdAndCertificateFromInitData): Extract the keyURI, keyID, and the app certificate from the initData.
47585         (WebCore::MediaPlayerPrivateAVFoundationObjC::generateKeyRequest): Generate a streaming key request from AVFoundation and 
47586             fire a keymessage event.
47587         (WebCore::MediaPlayerPrivateAVFoundationObjC::addKey): Pass to AVFoundation through the AVAssetResourceLoader.
47588         (WebCore::MediaPlayerPrivateAVFoundationObjC::cancelKeyRequest): Release the loader delegate.
47589         (-[WebCoreAVFLoaderDelegate initWithCallback:]): Simple constructor.
47590         (-[WebCoreAVFLoaderDelegate resourceLoader:shouldWaitForLoadingOfRequestedResource:]): Pass to the MediaPlayerPrivateAVFoundationObjC.
47591
47592 2012-10-12  James Simonsen  <simonjam@chromium.org>
47593
47594         [RequestAnimationFrame] Remove vendor prefix
47595         https://bugs.webkit.org/show_bug.cgi?id=99116
47596
47597         Reviewed by Adam Barth.
47598
47599         Test: Existing rAF tests without prefix.
47600
47601         * dom/Document.cpp:
47602         (WebCore::Document::requestAnimationFrame):
47603         (WebCore::Document::cancelAnimationFrame):
47604         * dom/Document.h:
47605         (Document):
47606         * page/DOMWindow.cpp:
47607         (WebCore::DOMWindow::requestAnimationFrame):
47608         (WebCore::DOMWindow::cancelAnimationFrame):
47609         * page/DOMWindow.h:
47610         (DOMWindow):
47611         * page/DOMWindow.idl:
47612
47613 2012-10-12  Andreas Kling  <kling@webkit.org>
47614
47615         REGRESSION: Rapid memory growth calling DOM APIs with large strings.
47616         <http://webkit.org/b/98498>
47617         <rdar://problem/12443926>
47618
47619         Reviewed by Geöff Gären and Änders Cärlssön.
47620
47621         Prevent the selector query cache from growing indefinitely by setting a relaxed limit of 256 entries.
47622         If the cache fills up, remove a random entry before inserting a new one.
47623
47624         While this is unlikely to be a problem on real websites, we definitely shouldn't be adding boundless
47625         caches to WebKit.
47626
47627         * dom/SelectorQuery.cpp:
47628         (WebCore::SelectorQueryCache::add):
47629
47630 2012-10-12  Roger Fong  <roger_fong@apple.com>
47631
47632         Update method signature for platformCALayerShowRepaintCounter in MediaPlayerPlayerPrivateAVFoundationCF's LayerClient class.
47633         https://bugs.webkit.org/show_bug.cgi?id=99190
47634
47635         Reviewed by Simon Fraser.
47636
47637         LayerClient's base class (PlatformCALayerClient) method signature for abstract method platformCALayerShowRepaintCounter
47638         was updated in http://trac.webkit.org/changeset/130676 so it needs to be changed in LayerClient as well.
47639
47640         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
47641         (WebCore::LayerClient::platformCALayerShowRepaintCounter):
47642
47643 2012-10-12  Scott Graham  <scottmg@chromium.org>
47644
47645         Local disable of stack corruption warning when compiling on VS2012
47646         https://bugs.webkit.org/show_bug.cgi?id=99106
47647
47648         Reviewed by Ryosuke Niwa.
47649
47650         Warning is:
47651
47652         ...\FEConvolveMatrix.cpp(274) : warning C4789: buffer 'totals' of size 12 bytes will be overrun; 4 bytes will be written starting at offset 12.
47653
47654         And similar at lines 281, 355, and 365. This appears to be incorrect
47655         as the writes at offset 12 occur only when preserveAlphaValues is
47656         false, and when it's false, totals will be 16 bytes long.
47657
47658         No new tests.
47659
47660         * platform/graphics/filters/FEConvolveMatrix.cpp:
47661         (WebCore):
47662
47663 2012-10-11  Emil A Eklund  <eae@chromium.org>
47664
47665         [Sub pixel layout] Change RenderBox to not round logicalTop/Left for RenderReplaced
47666         https://bugs.webkit.org/show_bug.cgi?id=99108
47667
47668         Reviewed by Levi Weintraub.
47669
47670         Change RenderBox::computePositionedLogicalHeightReplaced and
47671         computePositionedLogicalWidthReplaced to not round position.
47672
47673         Covered by existing tests.
47674
47675         * rendering/InlineFlowBox.cpp:
47676         (WebCore::InlineFlowBox::placeBoxesInBlockDirection):
47677         Floor baselinePosition for replaced elements to match logic in
47678         RootInlineBox::ascentAndDescentForBox where the ascent is
47679         computed from the floored baselinePosition.
47680         
47681         * rendering/RenderBox.cpp:
47682         (WebCore::RenderBox::computePositionedLogicalWidthReplaced):
47683         (WebCore::RenderBox::computePositionedLogicalHeightReplaced):
47684         Remove .round() call for m_position, preserving precision.
47685
47686 2012-10-01  Jer Noble  <jer.noble@apple.com>
47687
47688         Enable ENCRYPTED_MEDIA support on Mac.
47689         https://bugs.webkit.org/show_bug.cgi?id=98044
47690
47691         Reviewed by Anders Carlsson.
47692
47693         Enable the ENCRYPTED_MEDIA conditional on the Mac port.
47694
47695         No new tests; Existing media/encrypted-media tests require org.w3.clearkey support, which is not implemented.
47696
47697         * Configurations/FeatureDefines.xcconfig: Enable the ENCRYPTED_MEDIA flag.
47698         * DerivedSources.make: Add the MediaKeyError and MediaKeyEvent classes.
47699         * WebCore.xcodeproj/project.pbxproj: Ditto.
47700         * bindings/js/JSDictionary.cpp:
47701         (WebCore::JSDictionary::convertValue): Add convertValue functions for Uint8Array and MediaKeyError.
47702         * bindings/js/JSDictionary.h:
47703         * html/HTMLMediaElement.cpp:
47704         (WebCore::HTMLMediaElement::mediaPlayerKeyNeeded): Throw an error if no "needkey"
47705             handler is registered.
47706         * html/HTMLMediaElement.h:
47707         * html/HTMLMediaElement.idl: Change keySystem to DefaultIsUndefined.
47708         * platform/graphics/MediaPlayer.cpp:
47709         (WebCore::MediaPlayer::keyNeeded): Return a bool indicating whether the process was aborted
47710             due to a lack of "needkey" listener.
47711         * platform/graphics/MediaPlayer.h:
47712         (WebCore::MediaPlayerClient::mediaPlayerKeyAdded): Remove unused parameter names.
47713         (WebCore::MediaPlayerClient::mediaPlayerKeyError): Ditto.
47714         (WebCore::MediaPlayerClient::mediaPlayerKeyMessage): Ditto.
47715         (WebCore::MediaPlayerClient::mediaPlayerKeyNeeded): Ditto.
47716         * platform/graphics/MediaPlayerPrivate.h:
47717         (WebCore::MediaPlayerPrivateInterface::addKey): Ditto.
47718         (WebCore::MediaPlayerPrivateInterface::generateKeyRequest): Ditto.
47719         (WebCore::MediaPlayerPrivateInterface::cancelKeyRequest): Ditto.
47720         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
47721         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
47722         (WebCore::MediaPlayerPrivateAVFoundationObjC::registerMediaEngine): Call extendedSupportsType.
47723         (WebCore::MediaPlayerPrivateAVFoundationObjC::extendedSupportsType): Stub. Pass through to supportsType.
47724         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
47725         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
47726         (WebCore::MediaPlayerPrivateQTKit::registerMediaEngine): Call extendedSupportsType.
47727         (WebCore::MediaPlayerPrivateQTKit::extendedSupportsType): Stub. Pass through to supportsType.
47728
47729 2012-10-12  Jaehun Lim  <ljaehun.lim@samsung.com>
47730
47731         Check parameter's safety first
47732         https://bugs.webkit.org/show_bug.cgi?id=99136
47733
47734         Reviewed by Chris Rogers.
47735
47736         Pointer parameter was used before NULL checking.
47737         This patch moves safety checking statements to the head of the function.
47738
47739         No new tests. No behavior change.
47740
47741         * platform/audio/AudioChannel.cpp:
47742         (WebCore::AudioChannel::copyFromRange):
47743         (WebCore::AudioChannel::sumFrom):
47744         * platform/audio/EqualPowerPanner.cpp:
47745         (WebCore::EqualPowerPanner::pan):
47746
47747 2012-10-12  Andreas Kling  <kling@webkit.org>
47748
47749         RenderBR should share its constant newline string between instances.
47750         <http://webkit.org/b/99121>
47751
47752         Reviewed by Anders Carlsson.
47753
47754         * rendering/RenderBR.cpp:
47755         (WebCore::newlineString):
47756         (WebCore::RenderBR::RenderBR):
47757
47758 2012-10-12  Alexander Pavlov  <apavlov@chromium.org>
47759
47760         Web Inspector: [Styles] !important priority not honored inside the same declaration
47761         https://bugs.webkit.org/show_bug.cgi?id=99170
47762
47763         Reviewed by Yury Semikhatsky.
47764
47765         Property priorities were not considered inside the same CSS rule. !important properties should stay active
47766         even if followed by non-!important properties with the same name.
47767
47768         * inspector/InspectorStyleSheet.cpp:
47769         (WebCore::InspectorStyle::styleWithProperties):
47770         * inspector/front-end/StylesSidebarPane.js:
47771         (WebInspector.StylePropertiesSection.prototype.onpopulate):
47772         (WebInspector.ComputedStylePropertiesSection.prototype.rebuildComputedTrace):
47773
47774 2012-10-12  Pavel Feldman  <pfeldman@chromium.org>
47775
47776         Web Inspector: use hard-coded zoom factors instead of 1.2 powers.
47777         https://bugs.webkit.org/show_bug.cgi?id=99173
47778
47779         Reviewed by Vsevolod Vlasov.
47780
47781         Overwise we step too fast.
47782
47783         * inspector/front-end/inspector.js:
47784         (WebInspector._zoomIn):
47785         (WebInspector._zoomOut):
47786         (WebInspector):
47787
47788 2012-10-12  Yury Semikhatsky  <yurys@chromium.org>
47789
47790         Web Inspector: move delete watch expression farther from the expand triangle
47791         https://bugs.webkit.org/show_bug.cgi?id=99166
47792
47793         Reviewed by Pavel Feldman.
47794
47795         Aligned 'delete watch expression' button on the right side (was on the left) so
47796         that it is hard to click it when expanding watched value.
47797
47798         * inspector/front-end/inspector.css:
47799         (.properties-tree.watch-expressions):
47800         (.section .properties .delete-button):
47801
47802 2012-10-12  Pavel Feldman  <pfeldman@chromium.org>
47803
47804         Web Inspector: trim filename in the call stack sidebar
47805         https://bugs.webkit.org/show_bug.cgi?id=99169
47806
47807         Reviewed by Yury Semikhatsky.
47808
47809         Otherwise long file names are rendered poorly.
47810
47811         * inspector/front-end/CallStackSidebarPane.js:
47812         (WebInspector.CallStackSidebarPane.Placard.prototype._update):
47813         * inspector/front-end/inspector.css:
47814         (.placard .subtitle):
47815
47816 2012-10-12  Vsevolod Vlasov  <vsevik@chromium.org>
47817
47818         Web Inspector: Resume button in element inspector -> scripts has tooltip 'pause script execution'
47819         https://bugs.webkit.org/show_bug.cgi?id=99165
47820
47821         Reviewed by Pavel Feldman.
47822
47823         Pause/resume button title is now updated when debugger is paused/resumed.
47824
47825         * English.lproj/localizedStrings.js:
47826         * inspector/front-end/ScriptsPanel.js:
47827         (WebInspector.ScriptsPanel.prototype._updateDebuggerButtons):
47828         (WebInspector.ScriptsPanel.prototype._createDebugToolbar):
47829         (WebInspector.ScriptsPanel.prototype._updateButtonTitle):
47830         (WebInspector.ScriptsPanel.prototype._createButtonAndRegisterShortcuts):
47831
47832 2012-10-12  Kentaro Hara  <haraken@chromium.org>
47833
47834         Unreviewed. Fix run-binding-tests failures introduced in r131167.
47835
47836         * bindings/scripts/CodeGeneratorV8.pm:
47837         (GenerateConstructorGetter):
47838         * bindings/scripts/test/V8/V8TestObj.cpp:
47839         (WebCore):
47840         (WebCore::TestObjV8Internal::TestObjConstructorGetter):
47841         (WebCore::V8TestObj::installPerContextProperties):
47842         (WebCore::V8TestObj::installPerContextPrototypeProperties):
47843         (WebCore::V8TestObj::wrapSlow):
47844         * bindings/scripts/test/V8/V8TestObj.h:
47845         (V8TestObj):
47846
47847 2012-10-12  Pavel Feldman  <pfeldman@chromium.org>
47848
47849         Web Inspector: relies on current Function.prototype.bind in the frame
47850         https://bugs.webkit.org/show_bug.cgi?id=99164
47851
47852         Reviewed by Yury Semikhatsky.
47853
47854         InjectedScriptSource should not depend on the bind override.
47855
47856         Test: inspector/console/console-bind-fake.html
47857
47858         * inspector/InjectedScriptSource.js:
47859         (.):
47860
47861 2012-10-12  Alexander Pavlov  <apavlov@chromium.org>
47862
47863         Web Inspector: [Styles] Colors should be "As authored" by default
47864         https://bugs.webkit.org/show_bug.cgi?id=99017
47865
47866         Reviewed by Vsevolod Vlasov.
47867
47868         Use "original" as the default value of WebInspector.settings.colorFormat.
47869
47870         * inspector/front-end/Settings.js:
47871
47872 2012-10-12  Takashi Sakamoto  <tasak@google.com>
47873
47874         [WebKit IDL] move extended attributes to left of interface, exception...
47875         https://bugs.webkit.org/show_bug.cgi?id=99012
47876
47877         Reviewed by Kentaro Hara.
47878
47879         According to WebIDL spec, moved all extended attributes to the left
47880         of interface / attribute / readonly attribute / exception.
47881
47882         No new tests. I ran run-bindings-tests and all tests passed.
47883
47884         * Modules/battery/BatteryManager.idl:
47885         * Modules/battery/NavigatorBattery.idl:
47886         * Modules/filesystem/DOMFileSystem.idl:
47887         * Modules/filesystem/DOMFileSystemSync.idl:
47888         * Modules/filesystem/DOMWindowFileSystem.idl:
47889         * Modules/filesystem/DataTransferItemFileSystem.idl:
47890         * Modules/filesystem/DirectoryEntry.idl:
47891         * Modules/filesystem/DirectoryEntrySync.idl:
47892         * Modules/filesystem/DirectoryReader.idl:
47893         * Modules/filesystem/DirectoryReaderSync.idl:
47894         * Modules/filesystem/EntriesCallback.idl:
47895         * Modules/filesystem/Entry.idl:
47896         * Modules/filesystem/EntryArray.idl:
47897         * Modules/filesystem/EntryArraySync.idl:
47898         * Modules/filesystem/EntryCallback.idl:
47899         * Modules/filesystem/EntrySync.idl:
47900         * Modules/filesystem/ErrorCallback.idl:
47901         * Modules/filesystem/FileCallback.idl:
47902         * Modules/filesystem/FileEntry.idl:
47903         * Modules/filesystem/FileEntrySync.idl:
47904         * Modules/filesystem/FileSystemCallback.idl:
47905         * Modules/filesystem/FileWriter.idl:
47906         * Modules/filesystem/FileWriterCallback.idl:
47907         * Modules/filesystem/FileWriterSync.idl:
47908         * Modules/filesystem/HTMLInputElementFileSystem.idl:
47909         * Modules/filesystem/Metadata.idl:
47910         * Modules/filesystem/MetadataCallback.idl:
47911         * Modules/filesystem/WorkerContextFileSystem.idl:
47912         * Modules/gamepad/Gamepad.idl:
47913         * Modules/gamepad/GamepadList.idl:
47914         * Modules/gamepad/NavigatorGamepad.idl:
47915         * Modules/geolocation/Geolocation.idl:
47916         * Modules/geolocation/Geoposition.idl:
47917         * Modules/geolocation/NavigatorGeolocation.idl:
47918         * Modules/geolocation/PositionCallback.idl:
47919         * Modules/geolocation/PositionError.idl:
47920         * Modules/geolocation/PositionErrorCallback.idl:
47921         * Modules/indexeddb/DOMWindowIndexedDatabase.idl:
47922         * Modules/indexeddb/IDBAny.idl:
47923         * Modules/indexeddb/IDBCursor.idl:
47924         * Modules/indexeddb/IDBCursorWithValue.idl:
47925         * Modules/indexeddb/IDBDatabase.idl:
47926         * Modules/indexeddb/IDBDatabaseException.idl:
47927         * Modules/indexeddb/IDBFactory.idl:
47928         * Modules/indexeddb/IDBIndex.idl:
47929         * Modules/indexeddb/IDBKey.idl:
47930         * Modules/indexeddb/IDBKeyRange.idl:
47931         * Modules/indexeddb/IDBObjectStore.idl:
47932         * Modules/indexeddb/IDBOpenDBRequest.idl:
47933         * Modules/indexeddb/IDBRequest.idl:
47934         * Modules/indexeddb/IDBTransaction.idl:
47935         * Modules/indexeddb/IDBUpgradeNeededEvent.idl:
47936         * Modules/indexeddb/IDBVersionChangeEvent.idl:
47937         * Modules/indexeddb/IDBVersionChangeRequest.idl:
47938         * Modules/indexeddb/WorkerContextIndexedDatabase.idl:
47939         * Modules/intents/DOMWindowIntents.idl:
47940         * Modules/intents/DeliveredIntent.idl:
47941         * Modules/intents/NavigatorIntents.idl:
47942         * Modules/mediasource/MediaSource.idl:
47943         * Modules/mediasource/SourceBuffer.idl:
47944         * Modules/mediasource/SourceBufferList.idl:
47945         * Modules/mediastream/DOMWindowMediaStream.idl:
47946         * Modules/mediastream/IceCallback.idl:
47947         * Modules/mediastream/IceCandidate.idl:
47948         * Modules/mediastream/LocalMediaStream.idl:
47949         * Modules/mediastream/MediaStream.idl:
47950         * Modules/mediastream/MediaStreamEvent.idl:
47951         * Modules/mediastream/MediaStreamList.idl:
47952         * Modules/mediastream/MediaStreamTrack.idl:
47953         * Modules/mediastream/MediaStreamTrackEvent.idl:
47954         * Modules/mediastream/MediaStreamTrackList.idl:
47955         * Modules/mediastream/NavigatorMediaStream.idl:
47956         * Modules/mediastream/NavigatorUserMediaError.idl:
47957         * Modules/mediastream/NavigatorUserMediaErrorCallback.idl:
47958         * Modules/mediastream/NavigatorUserMediaSuccessCallback.idl:
47959         * Modules/mediastream/PeerConnection00.idl:
47960         * Modules/mediastream/RTCErrorCallback.idl:
47961         * Modules/mediastream/RTCIceCandidate.idl:
47962         * Modules/mediastream/RTCIceCandidateEvent.idl:
47963         * Modules/mediastream/RTCPeerConnection.idl:
47964         * Modules/mediastream/RTCSessionDescription.idl:
47965         * Modules/mediastream/RTCSessionDescriptionCallback.idl:
47966         * Modules/mediastream/RTCStatsCallback.idl:
47967         * Modules/mediastream/RTCStatsElement.idl:
47968         * Modules/mediastream/RTCStatsReport.idl:
47969         * Modules/mediastream/RTCStatsResponse.idl:
47970         * Modules/mediastream/SessionDescription.idl:
47971         * Modules/navigatorcontentutils/NavigatorContentUtils.idl:
47972         * Modules/networkinfo/NavigatorNetworkInfoConnection.idl:
47973         * Modules/networkinfo/NetworkInfoConnection.idl:
47974         * Modules/notifications/DOMWindowNotifications.idl:
47975         * Modules/notifications/Notification.idl:
47976         * Modules/notifications/NotificationCenter.idl:
47977         * Modules/notifications/NotificationPermissionCallback.idl:
47978         * Modules/notifications/WorkerContextNotifications.idl:
47979         * Modules/proximity/DeviceProximityEvent.idl:
47980         * Modules/quota/DOMWindowQuota.idl:
47981         * Modules/quota/StorageInfo.idl:
47982         * Modules/quota/StorageInfoErrorCallback.idl:
47983         * Modules/quota/StorageInfoQuotaCallback.idl:
47984         * Modules/quota/StorageInfoUsageCallback.idl:
47985         * Modules/speech/DOMWindowSpeech.idl:
47986         * Modules/speech/SpeechGrammar.idl:
47987         * Modules/speech/SpeechGrammarList.idl:
47988         * Modules/speech/SpeechRecognition.idl:
47989         * Modules/speech/SpeechRecognitionAlternative.idl:
47990         * Modules/speech/SpeechRecognitionError.idl:
47991         * Modules/speech/SpeechRecognitionEvent.idl:
47992         * Modules/speech/SpeechRecognitionResult.idl:
47993         * Modules/speech/SpeechRecognitionResultList.idl:
47994         * Modules/vibration/NavigatorVibration.idl:
47995         * Modules/webaudio/AudioBuffer.idl:
47996         * Modules/webaudio/AudioBufferCallback.idl:
47997         * Modules/webaudio/AudioBufferSourceNode.idl:
47998         * Modules/webaudio/AudioChannelMerger.idl:
47999         * Modules/webaudio/AudioChannelSplitter.idl:
48000         * Modules/webaudio/AudioContext.idl:
48001         * Modules/webaudio/AudioDestinationNode.idl:
48002         * Modules/webaudio/AudioGain.idl:
48003         * Modules/webaudio/AudioGainNode.idl:
48004         * Modules/webaudio/AudioListener.idl:
48005         * Modules/webaudio/AudioNode.idl:
48006         * Modules/webaudio/AudioPannerNode.idl:
48007         * Modules/webaudio/AudioParam.idl:
48008         * Modules/webaudio/AudioProcessingEvent.idl:
48009         * Modules/webaudio/AudioSourceNode.idl:
48010         * Modules/webaudio/BiquadFilterNode.idl:
48011         * Modules/webaudio/ConvolverNode.idl:
48012         * Modules/webaudio/DOMWindowWebAudio.idl:
48013         * Modules/webaudio/DelayNode.idl:
48014         * Modules/webaudio/DynamicsCompressorNode.idl:
48015         * Modules/webaudio/JavaScriptAudioNode.idl:
48016         * Modules/webaudio/MediaElementAudioSourceNode.idl:
48017         * Modules/webaudio/MediaStreamAudioSourceNode.idl:
48018         * Modules/webaudio/OfflineAudioCompletionEvent.idl:
48019         * Modules/webaudio/Oscillator.idl:
48020         * Modules/webaudio/RealtimeAnalyserNode.idl:
48021         * Modules/webaudio/WaveShaperNode.idl:
48022         * Modules/webaudio/WaveTable.idl:
48023         * Modules/webdatabase/DOMWindowWebDatabase.idl:
48024         * Modules/webdatabase/Database.idl:
48025         * Modules/webdatabase/DatabaseCallback.idl:
48026         * Modules/webdatabase/DatabaseSync.idl:
48027         * Modules/webdatabase/SQLError.idl:
48028         * Modules/webdatabase/SQLException.idl:
48029         * Modules/webdatabase/SQLResultSet.idl:
48030         * Modules/webdatabase/SQLResultSetRowList.idl:
48031         * Modules/webdatabase/SQLStatementCallback.idl:
48032         * Modules/webdatabase/SQLStatementErrorCallback.idl:
48033         * Modules/webdatabase/SQLTransaction.idl:
48034         * Modules/webdatabase/SQLTransactionCallback.idl:
48035         * Modules/webdatabase/SQLTransactionErrorCallback.idl:
48036         * Modules/webdatabase/SQLTransactionSync.idl:
48037         * Modules/webdatabase/SQLTransactionSyncCallback.idl:
48038         * Modules/webdatabase/WorkerContextWebDatabase.idl:
48039         * Modules/websockets/CloseEvent.idl:
48040         * Modules/websockets/DOMWindowWebSocket.idl:
48041         * Modules/websockets/WebSocket.idl:
48042         * Modules/websockets/WorkerContextWebSocket.idl:
48043         * bindings/scripts/test/TestCallback.idl:
48044         * bindings/scripts/test/TestCustomNamedGetter.idl:
48045         * bindings/scripts/test/TestDomainSecurity.idl:
48046         * bindings/scripts/test/TestEventConstructor.idl:
48047         * bindings/scripts/test/TestEventTarget.idl:
48048         * bindings/scripts/test/TestInterface.idl:
48049         * bindings/scripts/test/TestNamedConstructor.idl:
48050         * bindings/scripts/test/TestNode.idl:
48051         * bindings/scripts/test/TestObj.idl:
48052         * bindings/scripts/test/TestSerializedScriptValueInterface.idl:
48053         * bindings/scripts/test/TestSupplemental.idl:
48054         * bindings/scripts/test/TestTypedArray.idl:
48055         * css/CSSCharsetRule.idl:
48056         * css/CSSImportRule.idl:
48057         * css/CSSPageRule.idl:
48058         * css/CSSRule.idl:
48059         * css/CSSRuleList.idl:
48060         * css/CSSStyleDeclaration.idl:
48061         * css/CSSStyleRule.idl:
48062         * css/CSSStyleSheet.idl:
48063         * css/CSSUnknownRule.idl:
48064         * css/CSSValue.idl:
48065         * css/CSSValueList.idl:
48066         * css/MediaList.idl:
48067         * css/MediaQueryListListener.idl:
48068         * css/StyleMedia.idl:
48069         * css/StyleSheet.idl:
48070         * css/StyleSheetList.idl:
48071         * css/WebKitCSSFilterValue.idl:
48072         * css/WebKitCSSKeyframesRule.idl:
48073         * css/WebKitCSSMatrix.idl:
48074         * css/WebKitCSSRegionRule.idl:
48075         * css/WebKitCSSTransformValue.idl:
48076         * dom/Attr.idl:
48077         * dom/BeforeLoadEvent.idl:
48078         * dom/CharacterData.idl:
48079         * dom/ClientRectList.idl:
48080         * dom/Clipboard.idl:
48081         * dom/CustomEvent.idl:
48082         * dom/DOMCoreException.idl:
48083         * dom/DOMImplementation.idl:
48084         * dom/DOMNamedFlowCollection.idl:
48085         * dom/DOMStringList.idl:
48086         * dom/DOMStringMap.idl:
48087         * dom/DataTransferItem.idl:
48088         * dom/DataTransferItemList.idl:
48089         * dom/DeviceMotionEvent.idl:
48090         * dom/DeviceOrientationEvent.idl:
48091         * dom/Document.idl:
48092         * dom/DocumentType.idl:
48093         * dom/Element.idl:
48094         * dom/Entity.idl:
48095         * dom/ErrorEvent.idl:
48096         * dom/Event.idl:
48097         * dom/EventException.idl:
48098         * dom/EventListener.idl:
48099         * dom/EventTarget.idl:
48100         * dom/HashChangeEvent.idl:
48101         * dom/MessageChannel.idl:
48102         * dom/MessageEvent.idl:
48103         * dom/MessagePort.idl:
48104         * dom/MouseEvent.idl:
48105         * dom/MutationCallback.idl:
48106         * dom/MutationObserver.idl:
48107         * dom/MutationRecord.idl:
48108         * dom/NamedNodeMap.idl:
48109         * dom/Node.idl:
48110         * dom/NodeFilter.idl:
48111         * dom/NodeIterator.idl:
48112         * dom/NodeList.idl:
48113         * dom/Notation.idl:
48114         * dom/OverflowEvent.idl:
48115         * dom/PageTransitionEvent.idl:
48116         * dom/PopStateEvent.idl:
48117         * dom/ProcessingInstruction.idl:
48118         * dom/ProgressEvent.idl:
48119         * dom/PropertyNodeList.idl:
48120         * dom/RangeException.idl:
48121         * dom/RequestAnimationFrameCallback.idl:
48122         * dom/ShadowRoot.idl:
48123         * dom/StringCallback.idl:
48124         * dom/Touch.idl:
48125         * dom/TouchEvent.idl:
48126         * dom/TouchList.idl:
48127         * dom/TreeWalker.idl:
48128         * dom/WebKitAnimationEvent.idl:
48129         * dom/WebKitNamedFlow.idl:
48130         * dom/WebKitTransitionEvent.idl:
48131         * editing/DOMTransaction.idl:
48132         * editing/UndoManager.idl:
48133         * fileapi/Blob.idl:
48134         * fileapi/File.idl:
48135         * fileapi/FileError.idl:
48136         * fileapi/FileException.idl:
48137         * fileapi/FileList.idl:
48138         * fileapi/FileReader.idl:
48139         * fileapi/FileReaderSync.idl:
48140         * html/DOMFormData.idl:
48141         * html/DOMSettableTokenList.idl:
48142         * html/DOMTokenList.idl:
48143         * html/DOMURL.idl:
48144         * html/HTMLAllCollection.idl:
48145         * html/HTMLAnchorElement.idl:
48146         * html/HTMLAppletElement.idl:
48147         * html/HTMLAreaElement.idl:
48148         * html/HTMLAudioElement.idl:
48149         * html/HTMLBRElement.idl:
48150         * html/HTMLBaseElement.idl:
48151         * html/HTMLBaseFontElement.idl:
48152         * html/HTMLBodyElement.idl:
48153         * html/HTMLButtonElement.idl:
48154         * html/HTMLCanvasElement.idl:
48155         * html/HTMLCollection.idl:
48156         * html/HTMLDListElement.idl:
48157         * html/HTMLDataListElement.idl:
48158         * html/HTMLDetailsElement.idl:
48159         * html/HTMLDialogElement.idl:
48160         * html/HTMLDirectoryElement.idl:
48161         * html/HTMLDivElement.idl:
48162         * html/HTMLDocument.idl:
48163         * html/HTMLElement.idl:
48164         * html/HTMLEmbedElement.idl:
48165         * html/HTMLFieldSetElement.idl:
48166         * html/HTMLFontElement.idl:
48167         * html/HTMLFormElement.idl:
48168         * html/HTMLFrameElement.idl:
48169         * html/HTMLFrameSetElement.idl:
48170         * html/HTMLHRElement.idl:
48171         * html/HTMLHeadElement.idl:
48172         * html/HTMLHeadingElement.idl:
48173         * html/HTMLHtmlElement.idl:
48174         * html/HTMLIFrameElement.idl:
48175         * html/HTMLImageElement.idl:
48176         * html/HTMLInputElement.idl:
48177         * html/HTMLIntentElement.idl:
48178         * html/HTMLKeygenElement.idl:
48179         * html/HTMLLIElement.idl:
48180         * html/HTMLLabelElement.idl:
48181         * html/HTMLLegendElement.idl:
48182         * html/HTMLLinkElement.idl:
48183         * html/HTMLMapElement.idl:
48184         * html/HTMLMarqueeElement.idl:
48185         * html/HTMLMediaElement.idl:
48186         * html/HTMLMenuElement.idl:
48187         * html/HTMLMetaElement.idl:
48188         * html/HTMLMeterElement.idl:
48189         * html/HTMLModElement.idl:
48190         * html/HTMLOListElement.idl:
48191         * html/HTMLObjectElement.idl:
48192         * html/HTMLOptGroupElement.idl:
48193         * html/HTMLOptionElement.idl:
48194         * html/HTMLOptionsCollection.idl:
48195         * html/HTMLOutputElement.idl:
48196         * html/HTMLParagraphElement.idl:
48197         * html/HTMLParamElement.idl:
48198         * html/HTMLPreElement.idl:
48199         * html/HTMLProgressElement.idl:
48200         * html/HTMLPropertiesCollection.idl:
48201         * html/HTMLQuoteElement.idl:
48202         * html/HTMLScriptElement.idl:
48203         * html/HTMLSelectElement.idl:
48204         * html/HTMLSourceElement.idl:
48205         * html/HTMLStyleElement.idl:
48206         * html/HTMLTableCaptionElement.idl:
48207         * html/HTMLTableCellElement.idl:
48208         * html/HTMLTableColElement.idl:
48209         * html/HTMLTableElement.idl:
48210         * html/HTMLTableRowElement.idl:
48211         * html/HTMLTableSectionElement.idl:
48212         * html/HTMLTextAreaElement.idl:
48213         * html/HTMLTitleElement.idl:
48214         * html/HTMLTrackElement.idl:
48215         * html/HTMLUListElement.idl:
48216         * html/HTMLVideoElement.idl:
48217         * html/ImageData.idl:
48218         * html/MediaController.idl:
48219         * html/MediaError.idl:
48220         * html/MediaKeyError.idl:
48221         * html/MediaKeyEvent.idl:
48222         * html/MicroDataItemValue.idl:
48223         * html/RadioNodeList.idl:
48224         * html/TimeRanges.idl:
48225         * html/ValidityState.idl:
48226         * html/VoidCallback.idl:
48227         * html/canvas/ArrayBuffer.idl:
48228         * html/canvas/ArrayBufferView.idl:
48229         * html/canvas/CanvasRenderingContext.idl:
48230         * html/canvas/CanvasRenderingContext2D.idl:
48231         * html/canvas/DataView.idl:
48232         * html/canvas/EXTTextureFilterAnisotropic.idl:
48233         * html/canvas/Float32Array.idl:
48234         * html/canvas/Float64Array.idl:
48235         * html/canvas/Int16Array.idl:
48236         * html/canvas/Int32Array.idl:
48237         * html/canvas/Int8Array.idl:
48238         * html/canvas/OESStandardDerivatives.idl:
48239         * html/canvas/OESTextureFloat.idl:
48240         * html/canvas/OESVertexArrayObject.idl:
48241         * html/canvas/Uint16Array.idl:
48242         * html/canvas/Uint32Array.idl:
48243         * html/canvas/Uint8Array.idl:
48244         * html/canvas/Uint8ClampedArray.idl:
48245         * html/canvas/WebGLActiveInfo.idl:
48246         * html/canvas/WebGLBuffer.idl:
48247         * html/canvas/WebGLCompressedTextureS3TC.idl:
48248         * html/canvas/WebGLContextAttributes.idl:
48249         * html/canvas/WebGLContextEvent.idl:
48250         * html/canvas/WebGLDebugRendererInfo.idl:
48251         * html/canvas/WebGLDebugShaders.idl:
48252         * html/canvas/WebGLDepthTexture.idl:
48253         * html/canvas/WebGLFramebuffer.idl:
48254         * html/canvas/WebGLLoseContext.idl:
48255         * html/canvas/WebGLProgram.idl:
48256         * html/canvas/WebGLRenderbuffer.idl:
48257         * html/canvas/WebGLRenderingContext.idl:
48258         * html/canvas/WebGLShader.idl:
48259         * html/canvas/WebGLShaderPrecisionFormat.idl:
48260         * html/canvas/WebGLTexture.idl:
48261         * html/canvas/WebGLUniformLocation.idl:
48262         * html/canvas/WebGLVertexArrayObjectOES.idl:
48263         * html/shadow/HTMLContentElement.idl:
48264         * html/shadow/HTMLShadowElement.idl:
48265         * html/track/TextTrack.idl:
48266         * html/track/TextTrackCue.idl:
48267         * html/track/TextTrackCueList.idl:
48268         * html/track/TextTrackList.idl:
48269         * html/track/TrackEvent.idl:
48270         * inspector/InjectedScriptHost.idl:
48271         * inspector/InspectorFrontendHost.idl:
48272         * inspector/JavaScriptCallFrame.idl:
48273         * inspector/ScriptProfile.idl:
48274         * inspector/ScriptProfileNode.idl:
48275         * loader/appcache/DOMApplicationCache.idl:
48276         * page/AbstractView.idl:
48277         * page/BarInfo.idl:
48278         * page/Console.idl:
48279         * page/Coordinates.idl:
48280         * page/Crypto.idl:
48281         * page/DOMSecurityPolicy.idl:
48282         * page/DOMSelection.idl:
48283         * page/DOMWindow.idl:
48284         * page/DOMWindowPagePopup.idl:
48285         * page/EventSource.idl:
48286         * page/History.idl:
48287         * page/Location.idl:
48288         * page/MemoryInfo.idl:
48289         * page/Navigator.idl:
48290         * page/PagePopupController.idl:
48291         * page/Performance.idl:
48292         * page/PerformanceEntry.idl:
48293         * page/PerformanceEntryList.idl:
48294         * page/PerformanceNavigation.idl:
48295         * page/PerformanceResourceTiming.idl:
48296         * page/PerformanceTiming.idl:
48297         * page/Screen.idl:
48298         * page/SpeechInputEvent.idl:
48299         * page/SpeechInputResult.idl:
48300         * page/SpeechInputResultList.idl:
48301         * page/WebKitAnimation.idl:
48302         * page/WebKitAnimationList.idl:
48303         * page/WebKitPoint.idl:
48304         * page/WorkerNavigator.idl:
48305         * plugins/DOMMimeType.idl:
48306         * plugins/DOMMimeTypeArray.idl:
48307         * plugins/DOMPlugin.idl:
48308         * plugins/DOMPluginArray.idl:
48309         * storage/Storage.idl:
48310         * storage/StorageEvent.idl:
48311         * svg/ElementTimeControl.idl:
48312         * svg/SVGAElement.idl:
48313         * svg/SVGAltGlyphDefElement.idl:
48314         * svg/SVGAltGlyphElement.idl:
48315         * svg/SVGAltGlyphItemElement.idl:
48316         * svg/SVGAngle.idl:
48317         * svg/SVGAnimateColorElement.idl:
48318         * svg/SVGAnimateElement.idl:
48319         * svg/SVGAnimateMotionElement.idl:
48320         * svg/SVGAnimateTransformElement.idl:
48321         * svg/SVGAnimatedAngle.idl:
48322         * svg/SVGAnimatedBoolean.idl:
48323         * svg/SVGAnimatedEnumeration.idl:
48324         * svg/SVGAnimatedInteger.idl:
48325         * svg/SVGAnimatedLength.idl:
48326         * svg/SVGAnimatedLengthList.idl:
48327         * svg/SVGAnimatedNumber.idl:
48328         * svg/SVGAnimatedNumberList.idl:
48329         * svg/SVGAnimatedPreserveAspectRatio.idl:
48330         * svg/SVGAnimatedRect.idl:
48331         * svg/SVGAnimatedString.idl:
48332         * svg/SVGAnimatedTransformList.idl:
48333         * svg/SVGAnimationElement.idl:
48334         * svg/SVGCircleElement.idl:
48335         * svg/SVGClipPathElement.idl:
48336         * svg/SVGColor.idl:
48337         * svg/SVGComponentTransferFunctionElement.idl:
48338         * svg/SVGCursorElement.idl:
48339         * svg/SVGDefsElement.idl:
48340         * svg/SVGDescElement.idl:
48341         * svg/SVGDocument.idl:
48342         * svg/SVGElement.idl:
48343         * svg/SVGElementInstance.idl:
48344         * svg/SVGElementInstanceList.idl:
48345         * svg/SVGEllipseElement.idl:
48346         * svg/SVGException.idl:
48347         * svg/SVGExternalResourcesRequired.idl:
48348         * svg/SVGFEBlendElement.idl:
48349         * svg/SVGFEColorMatrixElement.idl:
48350         * svg/SVGFEComponentTransferElement.idl:
48351         * svg/SVGFECompositeElement.idl:
48352         * svg/SVGFEConvolveMatrixElement.idl:
48353         * svg/SVGFEDiffuseLightingElement.idl:
48354         * svg/SVGFEDisplacementMapElement.idl:
48355         * svg/SVGFEDistantLightElement.idl:
48356         * svg/SVGFEDropShadowElement.idl:
48357         * svg/SVGFEFloodElement.idl:
48358         * svg/SVGFEFuncAElement.idl:
48359         * svg/SVGFEFuncBElement.idl:
48360         * svg/SVGFEFuncGElement.idl:
48361         * svg/SVGFEFuncRElement.idl:
48362         * svg/SVGFEGaussianBlurElement.idl:
48363         * svg/SVGFEImageElement.idl:
48364         * svg/SVGFEMergeElement.idl:
48365         * svg/SVGFEMergeNodeElement.idl:
48366         * svg/SVGFEMorphologyElement.idl:
48367         * svg/SVGFEOffsetElement.idl:
48368         * svg/SVGFEPointLightElement.idl:
48369         * svg/SVGFESpecularLightingElement.idl:
48370         * svg/SVGFESpotLightElement.idl:
48371         * svg/SVGFETileElement.idl:
48372         * svg/SVGFETurbulenceElement.idl:
48373         * svg/SVGFilterElement.idl:
48374         * svg/SVGFilterPrimitiveStandardAttributes.idl:
48375         * svg/SVGFitToViewBox.idl:
48376         * svg/SVGFontElement.idl:
48377         * svg/SVGFontFaceElement.idl:
48378         * svg/SVGFontFaceFormatElement.idl:
48379         * svg/SVGFontFaceNameElement.idl:
48380         * svg/SVGFontFaceSrcElement.idl:
48381         * svg/SVGFontFaceUriElement.idl:
48382         * svg/SVGForeignObjectElement.idl:
48383         * svg/SVGGElement.idl:
48384         * svg/SVGGlyphElement.idl:
48385         * svg/SVGGlyphRefElement.idl:
48386         * svg/SVGGradientElement.idl:
48387         * svg/SVGHKernElement.idl:
48388         * svg/SVGImageElement.idl:
48389         * svg/SVGLangSpace.idl:
48390         * svg/SVGLength.idl:
48391         * svg/SVGLengthList.idl:
48392         * svg/SVGLineElement.idl:
48393         * svg/SVGLinearGradientElement.idl:
48394         * svg/SVGLocatable.idl:
48395         * svg/SVGMPathElement.idl:
48396         * svg/SVGMarkerElement.idl:
48397         * svg/SVGMaskElement.idl:
48398         * svg/SVGMatrix.idl:
48399         * svg/SVGMetadataElement.idl:
48400         * svg/SVGMissingGlyphElement.idl:
48401         * svg/SVGNumber.idl:
48402         * svg/SVGNumberList.idl:
48403         * svg/SVGPaint.idl:
48404         * svg/SVGPathElement.idl:
48405         * svg/SVGPathSeg.idl:
48406         * svg/SVGPathSegArcAbs.idl:
48407         * svg/SVGPathSegArcRel.idl:
48408         * svg/SVGPathSegClosePath.idl:
48409         * svg/SVGPathSegCurvetoCubicAbs.idl:
48410         * svg/SVGPathSegCurvetoCubicRel.idl:
48411         * svg/SVGPathSegCurvetoCubicSmoothAbs.idl:
48412         * svg/SVGPathSegCurvetoCubicSmoothRel.idl:
48413         * svg/SVGPathSegCurvetoQuadraticAbs.idl:
48414         * svg/SVGPathSegCurvetoQuadraticRel.idl:
48415         * svg/SVGPathSegCurvetoQuadraticSmoothAbs.idl:
48416         * svg/SVGPathSegCurvetoQuadraticSmoothRel.idl:
48417         * svg/SVGPathSegLinetoAbs.idl:
48418         * svg/SVGPathSegLinetoHorizontalAbs.idl:
48419         * svg/SVGPathSegLinetoHorizontalRel.idl:
48420         * svg/SVGPathSegLinetoRel.idl:
48421         * svg/SVGPathSegLinetoVerticalAbs.idl:
48422         * svg/SVGPathSegLinetoVerticalRel.idl:
48423         * svg/SVGPathSegList.idl:
48424         * svg/SVGPathSegMovetoAbs.idl:
48425         * svg/SVGPathSegMovetoRel.idl:
48426         * svg/SVGPatternElement.idl:
48427         * svg/SVGPoint.idl:
48428         * svg/SVGPointList.idl:
48429         * svg/SVGPolygonElement.idl:
48430         * svg/SVGPolylineElement.idl:
48431         * svg/SVGPreserveAspectRatio.idl:
48432         * svg/SVGRadialGradientElement.idl:
48433         * svg/SVGRect.idl:
48434         * svg/SVGRectElement.idl:
48435         * svg/SVGRenderingIntent.idl:
48436         * svg/SVGSVGElement.idl:
48437         * svg/SVGScriptElement.idl:
48438         * svg/SVGSetElement.idl:
48439         * svg/SVGStopElement.idl:
48440         * svg/SVGStringList.idl:
48441         * svg/SVGStylable.idl:
48442         * svg/SVGStyleElement.idl:
48443         * svg/SVGSwitchElement.idl:
48444         * svg/SVGSymbolElement.idl:
48445         * svg/SVGTRefElement.idl:
48446         * svg/SVGTSpanElement.idl:
48447         * svg/SVGTests.idl:
48448         * svg/SVGTextContentElement.idl:
48449         * svg/SVGTextElement.idl:
48450         * svg/SVGTextPathElement.idl:
48451         * svg/SVGTextPositioningElement.idl:
48452         * svg/SVGTitleElement.idl:
48453         * svg/SVGTransform.idl:
48454         * svg/SVGTransformList.idl:
48455         * svg/SVGTransformable.idl:
48456         * svg/SVGURIReference.idl:
48457         * svg/SVGUnitTypes.idl:
48458         * svg/SVGUseElement.idl:
48459         * svg/SVGVKernElement.idl:
48460         * svg/SVGViewElement.idl:
48461         * svg/SVGViewSpec.idl:
48462         * svg/SVGZoomAndPan.idl:
48463         * svg/SVGZoomEvent.idl:
48464         * testing/InternalSettings.idl:
48465         * testing/Internals.idl:
48466         * testing/MallocStatistics.idl:
48467         * workers/AbstractWorker.idl:
48468         * workers/DedicatedWorkerContext.idl:
48469         * workers/SharedWorker.idl:
48470         * workers/SharedWorkerContext.idl:
48471         * workers/Worker.idl:
48472         * workers/WorkerContext.idl:
48473         * workers/WorkerLocation.idl:
48474         * xml/DOMParser.idl:
48475         * xml/XMLHttpRequest.idl:
48476         * xml/XMLHttpRequestException.idl:
48477         * xml/XMLHttpRequestProgressEvent.idl:
48478         * xml/XMLHttpRequestUpload.idl:
48479         * xml/XMLSerializer.idl:
48480         * xml/XPathEvaluator.idl:
48481         * xml/XPathException.idl:
48482         * xml/XPathNSResolver.idl:
48483         * xml/XPathResult.idl:
48484         * xml/XSLTProcessor.idl:
48485         Moved extended attributes.
48486
48487 2012-10-12  Pavel Feldman  <pfeldman@chromium.org>
48488
48489         Web Inspector: never expand global scope automatically
48490         https://bugs.webkit.org/show_bug.cgi?id=99159
48491
48492         Reviewed by Vsevolod Vlasov.
48493
48494         Otherwise, stepping is slow.
48495
48496         * inspector/front-end/ScopeChainSidebarPane.js:
48497         (WebInspector.ScopeChainSidebarPane.prototype.update):
48498
48499 2012-10-10  Vsevolod Vlasov  <vsevik@chromium.org>
48500
48501         Web Inspector: Refactor UISourceCode, make it possible to distinguish working copy changes/commits from formatting.
48502         https://bugs.webkit.org/show_bug.cgi?id=98911
48503
48504         Reviewed by Pavel Feldman.
48505
48506         ContentChanged was dispatched both when working copy was committed and UISourceCode was formatted before.
48507         WorkingCopyChanged event was dispatched when working copy was set.
48508         Now there are three explicit events: WorkingCopyChanged, WorkingCopyCommitted, FormattedChanged.
48509         No events are dispatched now during revisions restoring.
48510         Reverting to revisions is now implemented based on the working copy editing.
48511
48512         * inspector/front-end/JavaScriptSourceFrame.js:
48513         (WebInspector.JavaScriptSourceFrame):
48514         (WebInspector.JavaScriptSourceFrame.prototype._onFormattedChanged):
48515         (WebInspector.JavaScriptSourceFrame.prototype._onWorkingCopyChanged):
48516         (WebInspector.JavaScriptSourceFrame.prototype._onWorkingCopyCommitted):
48517         (WebInspector.JavaScriptSourceFrame.prototype._innerSetContent):
48518         (WebInspector.JavaScriptSourceFrame.prototype.onTextChanged):
48519         * inspector/front-end/NavigatorView.js:
48520         (WebInspector.NavigatorView.prototype._uiSourceCodeWorkingCopyCommitted):
48521         (WebInspector.NavigatorView.prototype._uiSourceCodeFormattedChanged):
48522         (WebInspector.NavigatorView.prototype._addUISourceCodeListeners):
48523         (WebInspector.NavigatorView.prototype._removeUISourceCodeListeners):
48524         * inspector/front-end/TabbedEditorContainer.js:
48525         (WebInspector.TabbedEditorContainer.prototype._addUISourceCodeListeners):
48526         (WebInspector.TabbedEditorContainer.prototype._removeUISourceCodeListeners):
48527         (WebInspector.TabbedEditorContainer.prototype._uiSourceCodeWorkingCopyCommitted):
48528         (WebInspector.TabbedEditorContainer.prototype._uiSourceCodeFormattedChanged):
48529         * inspector/front-end/UISourceCode.js:
48530         (WebInspector.UISourceCode):
48531         (WebInspector.UISourceCode.prototype._commitContent):
48532         (WebInspector.UISourceCode.prototype.addRevision):
48533         (WebInspector.UISourceCode.prototype._restoreRevisionHistory):
48534         (WebInspector.UISourceCode.prototype.revertToOriginal):
48535         (WebInspector.UISourceCode.prototype.revertAndClearHistory):
48536         (WebInspector.UISourceCode.prototype.setWorkingCopy):
48537         (WebInspector.UISourceCode.prototype.commitWorkingCopy):
48538         (WebInspector.UISourceCode.prototype.setFormatted.didGetContent.formattedChanged):
48539         (WebInspector.UISourceCode.prototype.setFormatted.didGetContent):
48540         (WebInspector.UISourceCode.prototype.setFormatted):
48541         (WebInspector.Revision.prototype.revertToThis):
48542         * inspector/front-end/UISourceCodeFrame.js:
48543         (WebInspector.UISourceCodeFrame):
48544         (WebInspector.UISourceCodeFrame.prototype.onTextChanged):
48545         (WebInspector.UISourceCodeFrame.prototype._onFormattedChanged):
48546         (WebInspector.UISourceCodeFrame.prototype._onWorkingCopyChanged):
48547         (WebInspector.UISourceCodeFrame.prototype._onWorkingCopyCommitted):
48548         (WebInspector.UISourceCodeFrame.prototype._innerSetContent):
48549
48550 2012-10-12  Balazs Kelemen  <kbalazs@webkit.org>
48551
48552         [WK2] Serialization of Resource[Request,Response,Error] should be shared across ports
48553         https://bugs.webkit.org/show_bug.cgi?id=90142
48554
48555         Reviewed by Simon Hausmann.
48556
48557         Added a setter for the certificate of ResourceError.
48558
48559         No change in behavior so no new tests.
48560
48561         * platform/network/cf/ResourceError.h:
48562         (ResourceError):
48563         * platform/network/cf/ResourceErrorCF.cpp:
48564         (WebCore):
48565         (WebCore::ResourceError::setCertificate):
48566
48567 2012-10-12  MORITA Hajime  <morrita@google.com>
48568
48569         [V8] PerContextEnabled methods should be installed when the constructor is created
48570         https://bugs.webkit.org/show_bug.cgi?id=99129
48571
48572         Reviewed by Kentaro Hara.
48573
48574         Before this change, generated installPerContextProperties() method
48575         injected both per-context attributes and functions, and functions
48576         were injected into the prototye object.  This means that the
48577         functions are injected into the prototype repeatedly for each
48578         intance creation.  This injection can be happened only once per
48579         prototype object, which is clearer and is faster.
48580
48581         This change introduces installPerContextPrototypeProperties()
48582         generated method, which is designed to be called for each time when the prototype
48583         object is created.
48584
48585         To do that, WrapperTypeInfo is extended to hold an additional
48586         function pointer to an installPerContextPrototypeProperties()
48587         implementation so that we call it from V8PerContextData::constructorForTypeSlowCase(),
48588         where the prototype instance is created.
48589
48590         Other changes:
48591         - Added some modification to pass around the parameter to constructorForTypeSlowCase().
48592         - installPerContextProperties() are now always generated for simplicity. Empty implementations are inlined thus
48593           no speed penalty.
48594
48595         No new tests. Covered by existing tests.
48596
48597         * Modules/notifications/NotificationCenter.cpp:
48598         (WebCore::NotificationCenter::document):
48599         * Modules/notifications/NotificationCenter.h:
48600         (NotificationCenter):
48601         * bindings/scripts/CodeGeneratorV8.pm:
48602         (GenerateHeader):
48603         (GenerateConstructorGetter):
48604         (GenerateNamedConstructorCallback):
48605         (GenerateImplementation): Extracted per-context function additions to new installPerContextPrototypeProperties() function.
48606         (GenerateToV8Converters):
48607         * bindings/scripts/test/V8/V8Float64Array.cpp:
48608         (WebCore):
48609         (WebCore::V8Float64Array::wrapSlow):
48610         * bindings/scripts/test/V8/V8Float64Array.h:
48611         (WebCore::V8Float64Array::installPerContextProperties):
48612         (WebCore::V8Float64Array::installPerContextPrototypeProperties):
48613         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
48614         (WebCore):
48615         (WebCore::V8TestActiveDOMObject::wrapSlow):
48616         * bindings/scripts/test/V8/V8TestActiveDOMObject.h:
48617         (WebCore::V8TestActiveDOMObject::installPerContextProperties):
48618         (WebCore::V8TestActiveDOMObject::installPerContextPrototypeProperties):
48619         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
48620         (WebCore):
48621         (WebCore::V8TestCustomNamedGetter::wrapSlow):
48622         * bindings/scripts/test/V8/V8TestCustomNamedGetter.h:
48623         (WebCore::V8TestCustomNamedGetter::installPerContextProperties):
48624         (WebCore::V8TestCustomNamedGetter::installPerContextPrototypeProperties):
48625         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
48626         (WebCore):
48627         (WebCore::V8TestEventConstructor::wrapSlow):
48628         * bindings/scripts/test/V8/V8TestEventConstructor.h:
48629         (WebCore::V8TestEventConstructor::installPerContextProperties):
48630         (WebCore::V8TestEventConstructor::installPerContextPrototypeProperties):
48631         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
48632         (WebCore):
48633         (WebCore::V8TestEventTarget::wrapSlow):
48634         * bindings/scripts/test/V8/V8TestEventTarget.h:
48635         (WebCore::V8TestEventTarget::installPerContextProperties):
48636         (WebCore::V8TestEventTarget::installPerContextPrototypeProperties):
48637         * bindings/scripts/test/V8/V8TestException.cpp:
48638         (WebCore):
48639         (WebCore::V8TestException::wrapSlow):
48640         * bindings/scripts/test/V8/V8TestException.h:
48641         (WebCore::V8TestException::installPerContextProperties):
48642         (WebCore::V8TestException::installPerContextPrototypeProperties):
48643         * bindings/scripts/test/V8/V8TestInterface.cpp:
48644         (WebCore):
48645         (WebCore::V8TestInterface::wrapSlow):
48646         * bindings/scripts/test/V8/V8TestInterface.h:
48647         (WebCore::V8TestInterface::installPerContextProperties):
48648         (WebCore::V8TestInterface::installPerContextPrototypeProperties):
48649         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
48650         (WebCore):
48651         (WebCore::V8TestMediaQueryListListener::wrapSlow):
48652         * bindings/scripts/test/V8/V8TestMediaQueryListListener.h:
48653         (WebCore::V8TestMediaQueryListListener::installPerContextProperties):
48654         (WebCore::V8TestMediaQueryListListener::installPerContextPrototypeProperties):
48655         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
48656         (WebCore):
48657         (WebCore::V8TestNamedConstructor::wrapSlow):
48658         * bindings/scripts/test/V8/V8TestNamedConstructor.h:
48659         (WebCore::V8TestNamedConstructor::installPerContextProperties):
48660         (WebCore::V8TestNamedConstructor::installPerContextPrototypeProperties):
48661         * bindings/scripts/test/V8/V8TestNode.cpp:
48662         (WebCore):
48663         (WebCore::V8TestNode::wrapSlow):
48664         * bindings/scripts/test/V8/V8TestNode.h:
48665         (WebCore::V8TestNode::installPerContextProperties):
48666         (WebCore::V8TestNode::installPerContextPrototypeProperties):
48667         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
48668         (WebCore):
48669         (WebCore::V8TestSerializedScriptValueInterface::wrapSlow):
48670         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.h:
48671         (WebCore::V8TestSerializedScriptValueInterface::installPerContextProperties):
48672         (WebCore::V8TestSerializedScriptValueInterface::installPerContextPrototypeProperties):
48673         * bindings/v8/NPV8Object.cpp:
48674         (WebCore::npObjectTypeInfo):
48675         * bindings/v8/V8DOMWindowShell.cpp:
48676         (WebCore::V8DOMWindowShell::installDOMWindow):
48677         * bindings/v8/V8DOMWrapper.cpp:
48678         (WebCore::V8DOMWrapper::instantiateV8Object):
48679         * bindings/v8/V8PerContextData.cpp:
48680         (WebCore::V8PerContextData::createWrapperFromCacheSlowCase):
48681         (WebCore::V8PerContextData::constructorForTypeSlowCase): Now invokes installPerContextPrototypeProperties()
48682         * bindings/v8/V8PerContextData.h:
48683         (WebCore::V8PerContextData::createWrapperFromCache):
48684         (WebCore::V8PerContextData::constructorForType):
48685         (V8PerContextData):
48686         * bindings/v8/WorkerContextExecutionProxy.cpp:
48687         (WebCore::WorkerContextExecutionProxy::initializeIfNeeded):
48688         * bindings/v8/WrapperTypeInfo.h:
48689         (WebCore):
48690         (WebCore::WrapperTypeInfo::installPerContextPrototypeProperties): Added.
48691         (WrapperTypeInfo):
48692         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
48693         (WebCore):
48694
48695 2012-10-12  Pavel Feldman  <pfeldman@chromium.org>
48696
48697         Web Inspector: Add "goto tab 1,2,3" hotkeys
48698         https://bugs.webkit.org/show_bug.cgi?id=99157
48699
48700         Reviewed by Alexander Pavlov.
48701
48702         Ctrl/Cmd + digit shortcuts should select corresponding tabs
48703
48704         * inspector/front-end/InspectorView.js:
48705         (WebInspector.InspectorView.prototype._keyDown):
48706         (WebInspector.InspectorView.prototype._keyDownInternal):
48707
48708 2012-10-12  Vsevolod Vlasov  <vsevik@chromium.org>
48709
48710         Web Inspector: Extract domain specific editing handling logic from UISourceCode descendants (step 1).
48711         https://bugs.webkit.org/show_bug.cgi?id=98912
48712
48713         Reviewed by Pavel Feldman.
48714
48715         This is the first step that introduces StyleFile and ScriptFile and extracts domain specific editing handling logic.
48716         StyleFile and ScriptFile should listen for the UISourceCode events and process them, this will be done in the next patch.
48717
48718         * inspector/front-end/BreakpointManager.js:
48719         (WebInspector.BreakpointManager.Breakpoint.prototype._updateBreakpoint):
48720         * inspector/front-end/JavaScriptSource.js:
48721         * inspector/front-end/JavaScriptSourceFrame.js:
48722         (WebInspector.JavaScriptSourceFrame):
48723         (WebInspector.JavaScriptSourceFrame.prototype.onTextChanged):
48724         * inspector/front-end/ResourceScriptMapping.js:
48725         (WebInspector.ResourceScriptMapping.prototype.rawLocationToUILocation):
48726         (WebInspector.ResourceScriptMapping.prototype._hasDivergedFromVMChanged):
48727         (WebInspector.ResourceScriptMapping.prototype._bindUISourceCodeToScripts):
48728         (WebInspector.ScriptFile):
48729         (WebInspector.ScriptFile.prototype.hasDivergedFromVM):
48730         (WebInspector.ScriptFile.prototype.isDivergingFromVM):
48731         (WebInspector.ScriptFile.prototype.addEventListener):
48732         (WebInspector.ScriptFile.prototype.removeEventListener):
48733         (WebInspector.ResourceScriptFile):
48734         (WebInspector.ResourceScriptFile.prototype.workingCopyCommitted):
48735         (WebInspector.ResourceScriptFile.prototype.workingCopyChanged):
48736         (WebInspector.ResourceScriptFile.prototype.fireHasDivergedFromVMChanged):
48737         (WebInspector.ResourceScriptFile.prototype.hasDivergedFromVM):
48738         (WebInspector.ResourceScriptFile.prototype.isDivergingFromVM):
48739         * inspector/front-end/ScriptSnippetModel.js:
48740         (WebInspector.ScriptSnippetModel.prototype._addScriptSnippet):
48741         (WebInspector.SnippetScriptFile):
48742         (WebInspector.SnippetScriptFile.prototype.hasDivergedFromVM):
48743         (WebInspector.SnippetScriptFile.prototype.setHasDivergedFromVM):
48744         (WebInspector.SnippetScriptFile.prototype.isDivergingFromVM):
48745         (WebInspector.SnippetScriptFile.prototype.setIsDivergingFromVM):
48746         (WebInspector.SnippetScriptFile.prototype.workingCopyCommitted):
48747         (WebInspector.SnippetScriptFile.prototype.workingCopyChanged):
48748         * inspector/front-end/ScriptsPanel.js:
48749         (WebInspector.ScriptsPanel.prototype._revealExecutionLine):
48750         * inspector/front-end/StyleSource.js:
48751         * inspector/front-end/StylesSourceMapping.js:
48752         (WebInspector.StylesSourceMapping.prototype._uiSourceCodeAddedToWorkspace):
48753         (WebInspector.StylesSourceMapping.prototype._addUISourceCode):
48754         (WebInspector.StyleFile):
48755         (WebInspector.StyleFile.prototype.workingCopyCommitted):
48756         (WebInspector.StyleFile.prototype.workingCopyChanged):
48757         (WebInspector.StyleFile.prototype._callOrSetTimeout):
48758         (WebInspector.StyleFile.prototype._commitIncrementalEdit):
48759         (WebInspector.StyleFile.prototype._clearIncrementalUpdateTimer):
48760         * inspector/front-end/UISourceCode.js:
48761         (WebInspector.UISourceCode.prototype.scriptFile):
48762         (WebInspector.UISourceCode.prototype.setScriptFile):
48763         (WebInspector.UISourceCode.prototype.styleFile):
48764         (WebInspector.UISourceCode.prototype.setStyleFile):
48765         (WebInspector.UISourceCode.prototype.setWorkingCopy):
48766         (WebInspector.UISourceCode.prototype.commitWorkingCopy):
48767
48768 2012-10-12  Zeno Albisser  <zeno@webkit.org>
48769
48770         [Qt][WK2] GraphicsSurfaceGLX should keep track of previous GL context.
48771         https://bugs.webkit.org/show_bug.cgi?id=99076
48772
48773         In GraphicsSurfaceGLX/GraphicsSurfacePrivate we create a new
48774         QOpenGLContext for resolving GL methods.
48775         This context is implicitly made current on creation.
48776         Therefore we need to keep track of the previously bound context
48777         and make that one current again after calling create.
48778
48779         Reviewed by Kenneth Rohde Christiansen.
48780
48781         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
48782         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
48783
48784 2012-10-12  Balazs Kelemen  <kbalazs@webkit.org>
48785
48786         Unreviewed, rolling out r130389.
48787         http://trac.webkit.org/changeset/130389
48788         https://bugs.webkit.org/show_bug.cgi?id=98048
48789
48790         It broke chromium
48791
48792         * WebCore.exp.in:
48793         * page/Settings.cpp:
48794         (WebCore::Settings::setAcceleratedCompositingEnabled):
48795         * page/Settings.h:
48796         (WebCore::Settings::setForceCompositingMode):
48797         (WebCore::Settings::forceCompositingMode):
48798
48799 2012-10-12  Vsevolod Vlasov  <vsevik@chromium.org>
48800
48801         Web Inspector: Show request body source in request headers view.
48802         https://bugs.webkit.org/show_bug.cgi?id=99145
48803
48804         Reviewed by Pavel Feldman.
48805
48806         Added view source toggle to query parameters and form data elements.
48807
48808         * inspector/front-end/NetworkPanel.js: fixed queryString getter usage.
48809         (WebInspector.NetworkDataGridNode.prototype._fileName):
48810         (WebInspector.NetworkDataGridNode.NameComparator):
48811         * inspector/front-end/NetworkRequest.js: Extracted queryString getter.
48812         (WebInspector.NetworkRequest.prototype.queryString):
48813         (WebInspector.NetworkRequest.prototype.get queryParameters):
48814         * inspector/front-end/RequestHeadersView.js:
48815         (WebInspector.RequestHeadersView.prototype._refreshQueryString):
48816         (WebInspector.RequestHeadersView.prototype._refreshFormData):
48817         (WebInspector.RequestHeadersView.prototype._populateTreeElementWithSourceText):
48818         extracted common method to populate elememnt with raw source text.
48819         (WebInspector.RequestHeadersView.prototype._refreshParams.toggleViewSource):
48820         (WebInspector.RequestHeadersView.prototype._refreshParams):
48821         (WebInspector.RequestHeadersView.prototype._toggleURLDecoding):
48822         (WebInspector.RequestHeadersView.prototype._refreshHeadersText):
48823         * inspector/front-end/networkPanel.css:A removed redundant raw-form-data style rule.
48824
48825 2012-10-12  Shinya Kawanaka  <shinyak@chromium.org>
48826
48827         Optimzie SelectorCheckingContext memory layout
48828         https://bugs.webkit.org/show_bug.cgi?id=99139
48829
48830         Reviewed by Hajime Morita.
48831
48832         Since VisitedMatchType and PseudoId are both enum, we can make SelectorChecker more compact
48833         if these two fields are continuously placed.
48834
48835         No new tests, no change in behavior.
48836
48837         * css/SelectorChecker.h:
48838         (WebCore::SelectorChecker::SelectorCheckingContext::SelectorCheckingContext):
48839         (SelectorCheckingContext):
48840
48841 2012-10-12  Kenichi Ishibashi  <bashi@chromium.org>
48842
48843         [WebSocket] Add "Cache-Control: no-cache" to handshake request
48844         https://bugs.webkit.org/show_bug.cgi?id=98000
48845
48846         Reviewed by Yuta Kitamura.
48847
48848         Add no-cache headers to opening handshake.
48849         This is for compatibility improvement.
48850         Some proxies rewrite "Connection: upgrade" to "Connection: close"
48851         when a request doesn't contain no-cache headers.
48852
48853         Test: http/tests/websocket/tests/hybi/nocache.html
48854
48855         * Modules/websockets/WebSocketHandshake.cpp:
48856         (WebCore::WebSocketHandshake::clientHandshakeMessage):
48857         (WebCore::WebSocketHandshake::clientHandshakeRequest):
48858
48859 2012-10-11  Andy Estes  <aestes@apple.com>
48860
48861         Add some basic methods and properties to the injected bundle Objective-C DOM API
48862         https://bugs.webkit.org/show_bug.cgi?id=99137
48863
48864         Reviewed by Sam Weinig.
48865
48866         Export needed symbols.
48867
48868         * WebCore.exp.in:
48869
48870 2012-10-11  Rik Cabanier  <cabanier@adobe.com>
48871
48872         Bad copy constructor in StyleRareNonInheritedData
48873         https://bugs.webkit.org/show_bug.cgi?id=98950
48874
48875         Reviewed by Eric Seidel.
48876
48877         Typo in copy constructor caused blendmode to always be the default.
48878
48879         * rendering/style/StyleRareNonInheritedData.cpp:
48880         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
48881
48882 2012-10-11  Takashi Sakamoto  <tasak@google.com>
48883
48884         [WebKit IDL] remove all module from idl files.
48885         https://bugs.webkit.org/show_bug.cgi?id=99007
48886
48887         Reviewed by Kentaro Hara.
48888
48889         Since current WebIDL spec doesn't support "module", remove
48890         module from all idl files.
48891
48892         No new tests. I ran run-bindings-tests and no error was reported.
48893
48894         * Modules/battery/BatteryManager.idl:
48895         * Modules/battery/NavigatorBattery.idl:
48896         * Modules/filesystem/DOMFileSystem.idl:
48897         * Modules/filesystem/DOMFileSystemSync.idl:
48898         * Modules/filesystem/DOMWindowFileSystem.idl:
48899         * Modules/filesystem/DataTransferItemFileSystem.idl:
48900         * Modules/filesystem/DirectoryEntry.idl:
48901         * Modules/filesystem/DirectoryEntrySync.idl:
48902         * Modules/filesystem/DirectoryReader.idl:
48903         * Modules/filesystem/DirectoryReaderSync.idl:
48904         * Modules/filesystem/EntriesCallback.idl:
48905         * Modules/filesystem/Entry.idl:
48906         * Modules/filesystem/EntryArray.idl:
48907         * Modules/filesystem/EntryArraySync.idl:
48908         * Modules/filesystem/EntryCallback.idl:
48909         * Modules/filesystem/EntrySync.idl:
48910         * Modules/filesystem/ErrorCallback.idl:
48911         * Modules/filesystem/FileCallback.idl:
48912         * Modules/filesystem/FileEntry.idl:
48913         * Modules/filesystem/FileEntrySync.idl:
48914         * Modules/filesystem/FileSystemCallback.idl:
48915         * Modules/filesystem/FileWriter.idl:
48916         * Modules/filesystem/FileWriterCallback.idl:
48917         * Modules/filesystem/FileWriterSync.idl:
48918         * Modules/filesystem/HTMLInputElementFileSystem.idl:
48919         * Modules/filesystem/Metadata.idl:
48920         * Modules/filesystem/MetadataCallback.idl:
48921         * Modules/filesystem/WorkerContextFileSystem.idl:
48922         * Modules/gamepad/Gamepad.idl:
48923         * Modules/gamepad/GamepadList.idl:
48924         * Modules/gamepad/NavigatorGamepad.idl:
48925         * Modules/geolocation/Geolocation.idl:
48926         * Modules/geolocation/Geoposition.idl:
48927         * Modules/geolocation/NavigatorGeolocation.idl:
48928         * Modules/geolocation/PositionCallback.idl:
48929         * Modules/geolocation/PositionError.idl:
48930         * Modules/geolocation/PositionErrorCallback.idl:
48931         * Modules/indexeddb/DOMWindowIndexedDatabase.idl:
48932         * Modules/indexeddb/IDBAny.idl:
48933         * Modules/indexeddb/IDBCursor.idl:
48934         * Modules/indexeddb/IDBCursorWithValue.idl:
48935         * Modules/indexeddb/IDBDatabase.idl:
48936         * Modules/indexeddb/IDBDatabaseException.idl:
48937         * Modules/indexeddb/IDBFactory.idl:
48938         * Modules/indexeddb/IDBIndex.idl:
48939         * Modules/indexeddb/IDBKey.idl:
48940         * Modules/indexeddb/IDBKeyRange.idl:
48941         * Modules/indexeddb/IDBObjectStore.idl:
48942         * Modules/indexeddb/IDBOpenDBRequest.idl:
48943         * Modules/indexeddb/IDBRequest.idl:
48944         * Modules/indexeddb/IDBTransaction.idl:
48945         * Modules/indexeddb/IDBUpgradeNeededEvent.idl:
48946         * Modules/indexeddb/IDBVersionChangeEvent.idl:
48947         * Modules/indexeddb/IDBVersionChangeRequest.idl:
48948         * Modules/indexeddb/WorkerContextIndexedDatabase.idl:
48949         * Modules/intents/DOMWindowIntents.idl:
48950         * Modules/intents/DeliveredIntent.idl:
48951         * Modules/intents/Intent.idl:
48952         * Modules/intents/IntentResultCallback.idl:
48953         * Modules/intents/NavigatorIntents.idl:
48954         * Modules/mediasource/MediaSource.idl:
48955         * Modules/mediasource/SourceBuffer.idl:
48956         * Modules/mediasource/SourceBufferList.idl:
48957         * Modules/mediastream/DOMWindowMediaStream.idl:
48958         * Modules/mediastream/IceCallback.idl:
48959         * Modules/mediastream/IceCandidate.idl:
48960         * Modules/mediastream/LocalMediaStream.idl:
48961         * Modules/mediastream/MediaStream.idl:
48962         * Modules/mediastream/MediaStreamEvent.idl:
48963         * Modules/mediastream/MediaStreamList.idl:
48964         * Modules/mediastream/MediaStreamTrack.idl:
48965         * Modules/mediastream/MediaStreamTrackEvent.idl:
48966         * Modules/mediastream/MediaStreamTrackList.idl:
48967         * Modules/mediastream/NavigatorMediaStream.idl:
48968         * Modules/mediastream/NavigatorUserMediaError.idl:
48969         * Modules/mediastream/NavigatorUserMediaErrorCallback.idl:
48970         * Modules/mediastream/NavigatorUserMediaSuccessCallback.idl:
48971         * Modules/mediastream/PeerConnection00.idl:
48972         * Modules/mediastream/RTCErrorCallback.idl:
48973         * Modules/mediastream/RTCIceCandidate.idl:
48974         * Modules/mediastream/RTCIceCandidateEvent.idl:
48975         * Modules/mediastream/RTCPeerConnection.idl:
48976         * Modules/mediastream/RTCSessionDescription.idl:
48977         * Modules/mediastream/RTCSessionDescriptionCallback.idl:
48978         * Modules/mediastream/RTCStatsCallback.idl:
48979         * Modules/mediastream/RTCStatsElement.idl:
48980         * Modules/mediastream/RTCStatsReport.idl:
48981         * Modules/mediastream/RTCStatsResponse.idl:
48982         * Modules/mediastream/SessionDescription.idl:
48983         * Modules/navigatorcontentutils/NavigatorContentUtils.idl:
48984         * Modules/networkinfo/NavigatorNetworkInfoConnection.idl:
48985         * Modules/networkinfo/NetworkInfoConnection.idl:
48986         * Modules/notifications/DOMWindowNotifications.idl:
48987         * Modules/notifications/Notification.idl:
48988         * Modules/notifications/NotificationCenter.idl:
48989         * Modules/notifications/NotificationPermissionCallback.idl:
48990         * Modules/notifications/WorkerContextNotifications.idl:
48991         * Modules/proximity/DeviceProximityEvent.idl:
48992         * Modules/quota/DOMWindowQuota.idl:
48993         * Modules/quota/StorageInfo.idl:
48994         * Modules/quota/StorageInfoErrorCallback.idl:
48995         * Modules/quota/StorageInfoQuotaCallback.idl:
48996         * Modules/quota/StorageInfoUsageCallback.idl:
48997         * Modules/speech/DOMWindowSpeech.idl:
48998         * Modules/speech/SpeechGrammar.idl:
48999         * Modules/speech/SpeechGrammarList.idl:
49000         * Modules/speech/SpeechRecognition.idl:
49001         * Modules/speech/SpeechRecognitionAlternative.idl:
49002         * Modules/speech/SpeechRecognitionError.idl:
49003         * Modules/speech/SpeechRecognitionEvent.idl:
49004         * Modules/speech/SpeechRecognitionResult.idl:
49005         * Modules/speech/SpeechRecognitionResultList.idl:
49006         * Modules/vibration/NavigatorVibration.idl:
49007         * Modules/webaudio/AudioBuffer.idl:
49008         * Modules/webaudio/AudioBufferCallback.idl:
49009         * Modules/webaudio/AudioBufferSourceNode.idl:
49010         * Modules/webaudio/AudioChannelMerger.idl:
49011         * Modules/webaudio/AudioChannelSplitter.idl:
49012         * Modules/webaudio/AudioContext.idl:
49013         * Modules/webaudio/AudioDestinationNode.idl:
49014         * Modules/webaudio/AudioGain.idl:
49015         * Modules/webaudio/AudioGainNode.idl:
49016         * Modules/webaudio/AudioListener.idl:
49017         * Modules/webaudio/AudioNode.idl:
49018         * Modules/webaudio/AudioPannerNode.idl:
49019         * Modules/webaudio/AudioParam.idl:
49020         * Modules/webaudio/AudioProcessingEvent.idl:
49021         * Modules/webaudio/AudioSourceNode.idl:
49022         * Modules/webaudio/BiquadFilterNode.idl:
49023         * Modules/webaudio/ConvolverNode.idl:
49024         * Modules/webaudio/DOMWindowWebAudio.idl:
49025         * Modules/webaudio/DelayNode.idl:
49026         * Modules/webaudio/DynamicsCompressorNode.idl:
49027         * Modules/webaudio/JavaScriptAudioNode.idl:
49028         * Modules/webaudio/MediaElementAudioSourceNode.idl:
49029         * Modules/webaudio/MediaStreamAudioSourceNode.idl:
49030         * Modules/webaudio/OfflineAudioCompletionEvent.idl:
49031         * Modules/webaudio/Oscillator.idl:
49032         * Modules/webaudio/RealtimeAnalyserNode.idl:
49033         * Modules/webaudio/WaveShaperNode.idl:
49034         * Modules/webaudio/WaveTable.idl:
49035         * Modules/webdatabase/DOMWindowWebDatabase.idl:
49036         * Modules/webdatabase/Database.idl:
49037         * Modules/webdatabase/DatabaseCallback.idl:
49038         * Modules/webdatabase/DatabaseSync.idl:
49039         * Modules/webdatabase/SQLError.idl:
49040         * Modules/webdatabase/SQLException.idl:
49041         * Modules/webdatabase/SQLResultSet.idl:
49042         * Modules/webdatabase/SQLResultSetRowList.idl:
49043         * Modules/webdatabase/SQLStatementCallback.idl:
49044         * Modules/webdatabase/SQLStatementErrorCallback.idl:
49045         * Modules/webdatabase/SQLTransaction.idl:
49046         * Modules/webdatabase/SQLTransactionCallback.idl:
49047         * Modules/webdatabase/SQLTransactionErrorCallback.idl:
49048         * Modules/webdatabase/SQLTransactionSync.idl:
49049         * Modules/webdatabase/SQLTransactionSyncCallback.idl:
49050         * Modules/webdatabase/WorkerContextWebDatabase.idl:
49051         * Modules/websockets/CloseEvent.idl:
49052         * Modules/websockets/DOMWindowWebSocket.idl:
49053         * Modules/websockets/WebSocket.idl:
49054         * Modules/websockets/WorkerContextWebSocket.idl:
49055         * bindings/scripts/test/TestCallback.idl:
49056         * bindings/scripts/test/TestCustomNamedGetter.idl:
49057         * bindings/scripts/test/TestDomainSecurity.idl:
49058         * bindings/scripts/test/TestEventConstructor.idl:
49059         * bindings/scripts/test/TestEventTarget.idl:
49060         * bindings/scripts/test/TestException.idl:
49061         * bindings/scripts/test/TestInterface.idl:
49062         * bindings/scripts/test/TestMediaQueryListListener.idl:
49063         * bindings/scripts/test/TestNamedConstructor.idl:
49064         * bindings/scripts/test/TestNode.idl:
49065         * bindings/scripts/test/TestObj.idl:
49066         * bindings/scripts/test/TestSerializedScriptValueInterface.idl:
49067         * bindings/scripts/test/TestSupplemental.idl:
49068         * bindings/scripts/test/TestTypedArray.idl:
49069         * css/CSSCharsetRule.idl:
49070         * css/CSSFontFaceRule.idl:
49071         * css/CSSImportRule.idl:
49072         * css/CSSMediaRule.idl:
49073         * css/CSSPageRule.idl:
49074         * css/CSSPrimitiveValue.idl:
49075         * css/CSSRule.idl:
49076         * css/CSSRuleList.idl:
49077         * css/CSSStyleDeclaration.idl:
49078         * css/CSSStyleRule.idl:
49079         * css/CSSStyleSheet.idl:
49080         * css/CSSUnknownRule.idl:
49081         * css/CSSValue.idl:
49082         * css/CSSValueList.idl:
49083         * css/Counter.idl:
49084         * css/MediaList.idl:
49085         * css/MediaQueryList.idl:
49086         * css/MediaQueryListListener.idl:
49087         * css/RGBColor.idl:
49088         * css/Rect.idl:
49089         * css/StyleMedia.idl:
49090         * css/StyleSheet.idl:
49091         * css/StyleSheetList.idl:
49092         * css/WebKitCSSFilterValue.idl:
49093         * css/WebKitCSSKeyframeRule.idl:
49094         * css/WebKitCSSKeyframesRule.idl:
49095         * css/WebKitCSSMatrix.idl:
49096         * css/WebKitCSSRegionRule.idl:
49097         * css/WebKitCSSTransformValue.idl:
49098         * dom/Attr.idl:
49099         * dom/BeforeLoadEvent.idl:
49100         * dom/CDATASection.idl:
49101         * dom/CharacterData.idl:
49102         * dom/ClientRect.idl:
49103         * dom/ClientRectList.idl:
49104         * dom/Clipboard.idl:
49105         * dom/Comment.idl:
49106         * dom/CompositionEvent.idl:
49107         * dom/CustomEvent.idl:
49108         * dom/DOMCoreException.idl:
49109         * dom/DOMError.idl:
49110         * dom/DOMImplementation.idl:
49111         * dom/DOMNamedFlowCollection.idl:
49112         * dom/DOMStringList.idl:
49113         * dom/DOMStringMap.idl:
49114         * dom/DataTransferItem.idl:
49115         * dom/DataTransferItemList.idl:
49116         * dom/DeviceMotionEvent.idl:
49117         * dom/DeviceOrientationEvent.idl:
49118         * dom/Document.idl:
49119         * dom/DocumentFragment.idl:
49120         * dom/DocumentType.idl:
49121         * dom/Element.idl:
49122         * dom/Entity.idl:
49123         * dom/EntityReference.idl:
49124         * dom/ErrorEvent.idl:
49125         * dom/Event.idl:
49126         * dom/EventException.idl:
49127         * dom/EventListener.idl:
49128         * dom/EventTarget.idl:
49129         * dom/HashChangeEvent.idl:
49130         * dom/KeyboardEvent.idl:
49131         * dom/MessageChannel.idl:
49132         * dom/MessageEvent.idl:
49133         * dom/MessagePort.idl:
49134         * dom/MouseEvent.idl:
49135         * dom/MutationCallback.idl:
49136         * dom/MutationEvent.idl:
49137         * dom/MutationObserver.idl:
49138         * dom/MutationRecord.idl:
49139         * dom/NamedNodeMap.idl:
49140         * dom/Node.idl:
49141         * dom/NodeFilter.idl:
49142         * dom/NodeIterator.idl:
49143         * dom/NodeList.idl:
49144         * dom/Notation.idl:
49145         * dom/OverflowEvent.idl:
49146         * dom/PageTransitionEvent.idl:
49147         * dom/PopStateEvent.idl:
49148         * dom/ProcessingInstruction.idl:
49149         * dom/ProgressEvent.idl:
49150         * dom/PropertyNodeList.idl:
49151         * dom/Range.idl:
49152         * dom/RangeException.idl:
49153         * dom/RequestAnimationFrameCallback.idl:
49154         * dom/ShadowRoot.idl:
49155         * dom/StringCallback.idl:
49156         * dom/Text.idl:
49157         * dom/TextEvent.idl:
49158         * dom/Touch.idl:
49159         * dom/TouchEvent.idl:
49160         * dom/TouchList.idl:
49161         * dom/TreeWalker.idl:
49162         * dom/UIEvent.idl:
49163         * dom/WebKitAnimationEvent.idl:
49164         * dom/WebKitNamedFlow.idl:
49165         * dom/WebKitTransitionEvent.idl:
49166         * dom/WheelEvent.idl:
49167         * editing/DOMTransaction.idl:
49168         * editing/UndoManager.idl:
49169         * fileapi/Blob.idl:
49170         * fileapi/File.idl:
49171         * fileapi/FileError.idl:
49172         * fileapi/FileException.idl:
49173         * fileapi/FileList.idl:
49174         * fileapi/FileReader.idl:
49175         * fileapi/FileReaderSync.idl:
49176         * html/DOMFormData.idl:
49177         * html/DOMSettableTokenList.idl:
49178         * html/DOMTokenList.idl:
49179         * html/DOMURL.idl:
49180         * html/HTMLAllCollection.idl:
49181         * html/HTMLAnchorElement.idl:
49182         * html/HTMLAppletElement.idl:
49183         * html/HTMLAreaElement.idl:
49184         * html/HTMLAudioElement.idl:
49185         * html/HTMLBRElement.idl:
49186         * html/HTMLBaseElement.idl:
49187         * html/HTMLBaseFontElement.idl:
49188         * html/HTMLBodyElement.idl:
49189         * html/HTMLButtonElement.idl:
49190         * html/HTMLCanvasElement.idl:
49191         * html/HTMLCollection.idl:
49192         * html/HTMLDListElement.idl:
49193         * html/HTMLDataListElement.idl:
49194         * html/HTMLDetailsElement.idl:
49195         * html/HTMLDialogElement.idl:
49196         * html/HTMLDirectoryElement.idl:
49197         * html/HTMLDivElement.idl:
49198         * html/HTMLDocument.idl:
49199         * html/HTMLElement.idl:
49200         * html/HTMLEmbedElement.idl:
49201         * html/HTMLFieldSetElement.idl:
49202         * html/HTMLFontElement.idl:
49203         * html/HTMLFormElement.idl:
49204         * html/HTMLFrameElement.idl:
49205         * html/HTMLFrameSetElement.idl:
49206         * html/HTMLHRElement.idl:
49207         * html/HTMLHeadElement.idl:
49208         * html/HTMLHeadingElement.idl:
49209         * html/HTMLHtmlElement.idl:
49210         * html/HTMLIFrameElement.idl:
49211         * html/HTMLImageElement.idl:
49212         * html/HTMLInputElement.idl:
49213         * html/HTMLIntentElement.idl:
49214         * html/HTMLKeygenElement.idl:
49215         * html/HTMLLIElement.idl:
49216         * html/HTMLLabelElement.idl:
49217         * html/HTMLLegendElement.idl:
49218         * html/HTMLLinkElement.idl:
49219         * html/HTMLMapElement.idl:
49220         * html/HTMLMarqueeElement.idl:
49221         * html/HTMLMediaElement.idl:
49222         * html/HTMLMenuElement.idl:
49223         * html/HTMLMetaElement.idl:
49224         * html/HTMLMeterElement.idl:
49225         * html/HTMLModElement.idl:
49226         * html/HTMLOListElement.idl:
49227         * html/HTMLObjectElement.idl:
49228         * html/HTMLOptGroupElement.idl:
49229         * html/HTMLOptionElement.idl:
49230         * html/HTMLOptionsCollection.idl:
49231         * html/HTMLOutputElement.idl:
49232         * html/HTMLParagraphElement.idl:
49233         * html/HTMLParamElement.idl:
49234         * html/HTMLPreElement.idl:
49235         * html/HTMLProgressElement.idl:
49236         * html/HTMLPropertiesCollection.idl:
49237         * html/HTMLQuoteElement.idl:
49238         * html/HTMLScriptElement.idl:
49239         * html/HTMLSelectElement.idl:
49240         * html/HTMLSourceElement.idl:
49241         * html/HTMLSpanElement.idl:
49242         * html/HTMLStyleElement.idl:
49243         * html/HTMLTableCaptionElement.idl:
49244         * html/HTMLTableCellElement.idl:
49245         * html/HTMLTableColElement.idl:
49246         * html/HTMLTableElement.idl:
49247         * html/HTMLTableRowElement.idl:
49248         * html/HTMLTableSectionElement.idl:
49249         * html/HTMLTextAreaElement.idl:
49250         * html/HTMLTitleElement.idl:
49251         * html/HTMLTrackElement.idl:
49252         * html/HTMLUListElement.idl:
49253         * html/HTMLUnknownElement.idl:
49254         * html/HTMLVideoElement.idl:
49255         * html/ImageData.idl:
49256         * html/MediaController.idl:
49257         * html/MediaError.idl:
49258         * html/MediaKeyError.idl:
49259         * html/MediaKeyEvent.idl:
49260         * html/MicroDataItemValue.idl:
49261         * html/RadioNodeList.idl:
49262         * html/TextMetrics.idl:
49263         * html/TimeRanges.idl:
49264         * html/ValidityState.idl:
49265         * html/VoidCallback.idl:
49266         * html/canvas/ArrayBuffer.idl:
49267         * html/canvas/ArrayBufferView.idl:
49268         * html/canvas/CanvasGradient.idl:
49269         * html/canvas/CanvasPattern.idl:
49270         * html/canvas/CanvasRenderingContext.idl:
49271         * html/canvas/CanvasRenderingContext2D.idl:
49272         * html/canvas/DataView.idl:
49273         * html/canvas/EXTTextureFilterAnisotropic.idl:
49274         * html/canvas/Float32Array.idl:
49275         * html/canvas/Float64Array.idl:
49276         * html/canvas/Int16Array.idl:
49277         * html/canvas/Int32Array.idl:
49278         * html/canvas/Int8Array.idl:
49279         * html/canvas/OESStandardDerivatives.idl:
49280         * html/canvas/OESTextureFloat.idl:
49281         * html/canvas/OESVertexArrayObject.idl:
49282         * html/canvas/Uint16Array.idl:
49283         * html/canvas/Uint32Array.idl:
49284         * html/canvas/Uint8Array.idl:
49285         * html/canvas/Uint8ClampedArray.idl:
49286         * html/canvas/WebGLActiveInfo.idl:
49287         * html/canvas/WebGLBuffer.idl:
49288         * html/canvas/WebGLCompressedTextureS3TC.idl:
49289         * html/canvas/WebGLContextAttributes.idl:
49290         * html/canvas/WebGLContextEvent.idl:
49291         * html/canvas/WebGLDebugRendererInfo.idl:
49292         * html/canvas/WebGLDebugShaders.idl:
49293         * html/canvas/WebGLDepthTexture.idl:
49294         * html/canvas/WebGLFramebuffer.idl:
49295         * html/canvas/WebGLLoseContext.idl:
49296         * html/canvas/WebGLProgram.idl:
49297         * html/canvas/WebGLRenderbuffer.idl:
49298         * html/canvas/WebGLRenderingContext.idl:
49299         * html/canvas/WebGLShader.idl:
49300         * html/canvas/WebGLShaderPrecisionFormat.idl:
49301         * html/canvas/WebGLTexture.idl:
49302         * html/canvas/WebGLUniformLocation.idl:
49303         * html/canvas/WebGLVertexArrayObjectOES.idl:
49304         * html/shadow/HTMLContentElement.idl:
49305         * html/shadow/HTMLShadowElement.idl:
49306         * html/track/TextTrack.idl:
49307         * html/track/TextTrackCue.idl:
49308         * html/track/TextTrackCueList.idl:
49309         * html/track/TextTrackList.idl:
49310         * html/track/TrackEvent.idl:
49311         * inspector/InjectedScriptHost.idl:
49312         * inspector/InspectorFrontendHost.idl:
49313         * inspector/JavaScriptCallFrame.idl:
49314         * inspector/ScriptProfile.idl:
49315         * inspector/ScriptProfileNode.idl:
49316         * loader/appcache/DOMApplicationCache.idl:
49317         * page/AbstractView.idl:
49318         * page/BarInfo.idl:
49319         * page/Console.idl:
49320         * page/Coordinates.idl:
49321         * page/Crypto.idl:
49322         * page/DOMSecurityPolicy.idl:
49323         * page/DOMSelection.idl:
49324         * page/DOMWindow.idl:
49325         * page/DOMWindowPagePopup.idl:
49326         * page/EventSource.idl:
49327         * page/History.idl:
49328         * page/Location.idl:
49329         * page/MemoryInfo.idl:
49330         * page/Navigator.idl:
49331         * page/PagePopupController.idl:
49332         * page/Performance.idl:
49333         * page/PerformanceEntry.idl:
49334         * page/PerformanceEntryList.idl:
49335         * page/PerformanceNavigation.idl:
49336         * page/PerformanceResourceTiming.idl:
49337         * page/PerformanceTiming.idl:
49338         * page/Screen.idl:
49339         * page/SpeechInputEvent.idl:
49340         * page/SpeechInputResult.idl:
49341         * page/SpeechInputResultList.idl:
49342         * page/WebKitAnimation.idl:
49343         * page/WebKitAnimationList.idl:
49344         * page/WebKitPoint.idl:
49345         * page/WorkerNavigator.idl:
49346         * plugins/DOMMimeType.idl:
49347         * plugins/DOMMimeTypeArray.idl:
49348         * plugins/DOMPlugin.idl:
49349         * plugins/DOMPluginArray.idl:
49350         * storage/Storage.idl:
49351         * storage/StorageEvent.idl:
49352         * svg/ElementTimeControl.idl:
49353         * svg/SVGAElement.idl:
49354         * svg/SVGAltGlyphDefElement.idl:
49355         * svg/SVGAltGlyphElement.idl:
49356         * svg/SVGAltGlyphItemElement.idl:
49357         * svg/SVGAngle.idl:
49358         * svg/SVGAnimateColorElement.idl:
49359         * svg/SVGAnimateElement.idl:
49360         * svg/SVGAnimateMotionElement.idl:
49361         * svg/SVGAnimateTransformElement.idl:
49362         * svg/SVGAnimatedAngle.idl:
49363         * svg/SVGAnimatedBoolean.idl:
49364         * svg/SVGAnimatedEnumeration.idl:
49365         * svg/SVGAnimatedInteger.idl:
49366         * svg/SVGAnimatedLength.idl:
49367         * svg/SVGAnimatedLengthList.idl:
49368         * svg/SVGAnimatedNumber.idl:
49369         * svg/SVGAnimatedNumberList.idl:
49370         * svg/SVGAnimatedPreserveAspectRatio.idl:
49371         * svg/SVGAnimatedRect.idl:
49372         * svg/SVGAnimatedString.idl:
49373         * svg/SVGAnimatedTransformList.idl:
49374         * svg/SVGAnimationElement.idl:
49375         * svg/SVGCircleElement.idl:
49376         * svg/SVGClipPathElement.idl:
49377         * svg/SVGColor.idl:
49378         * svg/SVGComponentTransferFunctionElement.idl:
49379         * svg/SVGCursorElement.idl:
49380         * svg/SVGDefsElement.idl:
49381         * svg/SVGDescElement.idl:
49382         * svg/SVGDocument.idl:
49383         * svg/SVGElement.idl:
49384         * svg/SVGElementInstance.idl:
49385         * svg/SVGElementInstanceList.idl:
49386         * svg/SVGEllipseElement.idl:
49387         * svg/SVGException.idl:
49388         * svg/SVGExternalResourcesRequired.idl:
49389         * svg/SVGFEBlendElement.idl:
49390         * svg/SVGFEColorMatrixElement.idl:
49391         * svg/SVGFEComponentTransferElement.idl:
49392         * svg/SVGFECompositeElement.idl:
49393         * svg/SVGFEConvolveMatrixElement.idl:
49394         * svg/SVGFEDiffuseLightingElement.idl:
49395         * svg/SVGFEDisplacementMapElement.idl:
49396         * svg/SVGFEDistantLightElement.idl:
49397         * svg/SVGFEDropShadowElement.idl:
49398         * svg/SVGFEFloodElement.idl:
49399         * svg/SVGFEFuncAElement.idl:
49400         * svg/SVGFEFuncBElement.idl:
49401         * svg/SVGFEFuncGElement.idl:
49402         * svg/SVGFEFuncRElement.idl:
49403         * svg/SVGFEGaussianBlurElement.idl:
49404         * svg/SVGFEImageElement.idl:
49405         * svg/SVGFEMergeElement.idl:
49406         * svg/SVGFEMergeNodeElement.idl:
49407         * svg/SVGFEMorphologyElement.idl:
49408         * svg/SVGFEOffsetElement.idl:
49409         * svg/SVGFEPointLightElement.idl:
49410         * svg/SVGFESpecularLightingElement.idl:
49411         * svg/SVGFESpotLightElement.idl:
49412         * svg/SVGFETileElement.idl:
49413         * svg/SVGFETurbulenceElement.idl:
49414         * svg/SVGFilterElement.idl:
49415         * svg/SVGFilterPrimitiveStandardAttributes.idl:
49416         * svg/SVGFitToViewBox.idl:
49417         * svg/SVGFontElement.idl:
49418         * svg/SVGFontFaceElement.idl:
49419         * svg/SVGFontFaceFormatElement.idl:
49420         * svg/SVGFontFaceNameElement.idl:
49421         * svg/SVGFontFaceSrcElement.idl:
49422         * svg/SVGFontFaceUriElement.idl:
49423         * svg/SVGForeignObjectElement.idl:
49424         * svg/SVGGElement.idl:
49425         * svg/SVGGlyphElement.idl:
49426         * svg/SVGGlyphRefElement.idl:
49427         * svg/SVGGradientElement.idl:
49428         * svg/SVGHKernElement.idl:
49429         * svg/SVGImageElement.idl:
49430         * svg/SVGLangSpace.idl:
49431         * svg/SVGLength.idl:
49432         * svg/SVGLengthList.idl:
49433         * svg/SVGLineElement.idl:
49434         * svg/SVGLinearGradientElement.idl:
49435         * svg/SVGLocatable.idl:
49436         * svg/SVGMPathElement.idl:
49437         * svg/SVGMarkerElement.idl:
49438         * svg/SVGMaskElement.idl:
49439         * svg/SVGMatrix.idl:
49440         * svg/SVGMetadataElement.idl:
49441         * svg/SVGMissingGlyphElement.idl:
49442         * svg/SVGNumber.idl:
49443         * svg/SVGNumberList.idl:
49444         * svg/SVGPaint.idl:
49445         * svg/SVGPathElement.idl:
49446         * svg/SVGPathSeg.idl:
49447         * svg/SVGPathSegArcAbs.idl:
49448         * svg/SVGPathSegArcRel.idl:
49449         * svg/SVGPathSegClosePath.idl:
49450         * svg/SVGPathSegCurvetoCubicAbs.idl:
49451         * svg/SVGPathSegCurvetoCubicRel.idl:
49452         * svg/SVGPathSegCurvetoCubicSmoothAbs.idl:
49453         * svg/SVGPathSegCurvetoCubicSmoothRel.idl:
49454         * svg/SVGPathSegCurvetoQuadraticAbs.idl:
49455         * svg/SVGPathSegCurvetoQuadraticRel.idl:
49456         * svg/SVGPathSegCurvetoQuadraticSmoothAbs.idl:
49457         * svg/SVGPathSegCurvetoQuadraticSmoothRel.idl:
49458         * svg/SVGPathSegLinetoAbs.idl:
49459         * svg/SVGPathSegLinetoHorizontalAbs.idl:
49460         * svg/SVGPathSegLinetoHorizontalRel.idl:
49461         * svg/SVGPathSegLinetoRel.idl:
49462         * svg/SVGPathSegLinetoVerticalAbs.idl:
49463         * svg/SVGPathSegLinetoVerticalRel.idl:
49464         * svg/SVGPathSegList.idl:
49465         * svg/SVGPathSegMovetoAbs.idl:
49466         * svg/SVGPathSegMovetoRel.idl:
49467         * svg/SVGPatternElement.idl:
49468         * svg/SVGPoint.idl:
49469         * svg/SVGPointList.idl:
49470         * svg/SVGPolygonElement.idl:
49471         * svg/SVGPolylineElement.idl:
49472         * svg/SVGPreserveAspectRatio.idl:
49473         * svg/SVGRadialGradientElement.idl:
49474         * svg/SVGRect.idl:
49475         * svg/SVGRectElement.idl:
49476         * svg/SVGRenderingIntent.idl:
49477         * svg/SVGSVGElement.idl:
49478         * svg/SVGScriptElement.idl:
49479         * svg/SVGSetElement.idl:
49480         * svg/SVGStopElement.idl:
49481         * svg/SVGStringList.idl:
49482         * svg/SVGStylable.idl:
49483         * svg/SVGStyleElement.idl:
49484         * svg/SVGSwitchElement.idl:
49485         * svg/SVGSymbolElement.idl:
49486         * svg/SVGTRefElement.idl:
49487         * svg/SVGTSpanElement.idl:
49488         * svg/SVGTests.idl:
49489         * svg/SVGTextContentElement.idl:
49490         * svg/SVGTextElement.idl:
49491         * svg/SVGTextPathElement.idl:
49492         * svg/SVGTextPositioningElement.idl:
49493         * svg/SVGTitleElement.idl:
49494         * svg/SVGTransform.idl:
49495         * svg/SVGTransformList.idl:
49496         * svg/SVGTransformable.idl:
49497         * svg/SVGURIReference.idl:
49498         * svg/SVGUnitTypes.idl:
49499         * svg/SVGUseElement.idl:
49500         * svg/SVGVKernElement.idl:
49501         * svg/SVGViewElement.idl:
49502         * svg/SVGViewSpec.idl:
49503         * svg/SVGZoomAndPan.idl:
49504         * svg/SVGZoomEvent.idl:
49505         * testing/InternalSettings.idl:
49506         * testing/Internals.idl:
49507         * testing/MallocStatistics.idl:
49508         * workers/AbstractWorker.idl:
49509         * workers/DedicatedWorkerContext.idl:
49510         * workers/SharedWorker.idl:
49511         * workers/SharedWorkerContext.idl:
49512         * workers/Worker.idl:
49513         * workers/WorkerContext.idl:
49514         * workers/WorkerLocation.idl:
49515         * xml/DOMParser.idl:
49516         * xml/XMLHttpRequest.idl:
49517         * xml/XMLHttpRequestException.idl:
49518         * xml/XMLHttpRequestProgressEvent.idl:
49519         * xml/XMLHttpRequestUpload.idl:
49520         * xml/XMLSerializer.idl:
49521         * xml/XPathEvaluator.idl:
49522         * xml/XPathException.idl:
49523         * xml/XPathExpression.idl:
49524         * xml/XPathNSResolver.idl:
49525         * xml/XPathResult.idl:
49526         * xml/XSLTProcessor.idl:
49527         Removed "module".
49528
49529 2012-10-11  Beth Dakin  <bdakin@apple.com>
49530
49531         https://bugs.webkit.org/show_bug.cgi?id=98700
49532         ScrollingCoordinator is a hot mess of if-defs
49533
49534         Reviewed by Anders Carlsson.
49535
49536         This patch moves all of the threaded scrolling code in 
49537         ScrollingCoordinator into a new class called ScrollingCoordinatorMac 
49538         which inherits from ScrollingCoordinator. 
49539
49540         It also adds ScrollingCoordinatorChromium to do Chromium-specific work. 
49541         ScrollingCoordinator itself does work that is cross-platform. 
49542         
49543         Finally, this patch also eliminates ScrollingCoordinatorNone. 
49544         ScrollingCoordinator is now sufficient for platforms that relied on 
49545         ScrollingCoordinatorNone to build.
49546
49547         * CMakeLists.txt:
49548         * GNUmakefile.list.am:
49549         * Target.pri:
49550         * WebCore.exp.in:
49551         * WebCore.xcodeproj/project.pbxproj:
49552         * page/scrolling/ScrollingCoordinator.cpp:
49553         (WebCore::ScrollingCoordinator::create):
49554         (WebCore):
49555         (WebCore::ScrollingCoordinator::ScrollingCoordinator):
49556         (WebCore::ScrollingCoordinator::~ScrollingCoordinator):
49557         (WebCore::ScrollingCoordinator::pageDestroyed):
49558         (WebCore::ScrollingCoordinator::computeNonFastScrollableRegion):
49559         (WebCore::ScrollingCoordinator::computeCurrentWheelEventHandlerCount):
49560         (WebCore::ScrollingCoordinator::scrollLayerForFrameView):
49561         (WebCore::ScrollingCoordinator::frameViewRootLayerDidChange):
49562         * page/scrolling/ScrollingCoordinator.h:
49563         (WebCore):
49564         (ScrollingCoordinator):
49565         (WebCore::ScrollingCoordinator::scrollingTree):
49566         (WebCore::ScrollingCoordinator::commitTreeStateIfNeeded):
49567         (WebCore::ScrollingCoordinator::frameViewLayoutUpdated):
49568         (WebCore::ScrollingCoordinator::supportsFixedPositionLayers):
49569         (WebCore::ScrollingCoordinator::requestScrollPositionUpdate):
49570         (WebCore::ScrollingCoordinator::handleWheelEvent):
49571         (WebCore::ScrollingCoordinator::updateMainFrameScrollPositionAndScrollLayerPosition):
49572         (WebCore::ScrollingCoordinator::attachToStateTree):
49573         (WebCore::ScrollingCoordinator::detachFromStateTree):
49574         (WebCore::ScrollingCoordinator::clearStateTree):
49575         (WebCore::ScrollingCoordinator::frameViewHorizontalScrollbarLayerDidChange):
49576         (WebCore::ScrollingCoordinator::frameViewVerticalScrollbarLayerDidChange):
49577         (WebCore::ScrollingCoordinator::scrollableAreaScrollLayerDidChange):
49578         (WebCore::ScrollingCoordinator::setLayerIsContainerForFixedPositionLayers):
49579         (WebCore::ScrollingCoordinator::setLayerIsFixedToContainerLayer):
49580         (WebCore::ScrollingCoordinator::recomputeWheelEventHandlerCountForFrameView):
49581         (WebCore::ScrollingCoordinator::setShouldUpdateScrollLayerPositionOnMainThread):
49582         * page/scrolling/ScrollingCoordinatorNone.cpp: Removed.
49583         * page/scrolling/chromium/ScrollingCoordinatorChromium.cpp:
49584         (WebCore::ScrollingCoordinatorChromium::ScrollingCoordinatorChromium):
49585         (WebCore::ScrollingCoordinatorChromium::~ScrollingCoordinatorChromium):
49586         (WebCore::ScrollingCoordinatorChromium::frameViewLayoutUpdated):
49587         (WebCore):
49588         (WebCore::ScrollingCoordinatorChromium::frameViewRootLayerDidChange):
49589         (WebCore::ScrollingCoordinatorChromium::frameViewHorizontalScrollbarLayerDidChange):
49590         (WebCore::ScrollingCoordinatorChromium::frameViewVerticalScrollbarLayerDidChange):
49591         (WebCore::ScrollingCoordinatorChromium::setScrollLayer):
49592         (WebCore::ScrollingCoordinatorChromium::setNonFastScrollableRegion):
49593         (WebCore::ScrollingCoordinatorChromium::setWheelEventHandlerCount):
49594         (WebCore::ScrollingCoordinatorChromium::setShouldUpdateScrollLayerPositionOnMainThread):
49595         (WebCore::ScrollingCoordinatorChromium::setLayerIsContainerForFixedPositionLayers):
49596         (WebCore::ScrollingCoordinatorChromium::setLayerIsFixedToContainerLayer):
49597         (WebCore::ScrollingCoordinatorChromium::scrollableAreaScrollLayerDidChange):
49598         (WebCore::ScrollingCoordinatorChromium::recomputeWheelEventHandlerCountForFrameView):
49599         * page/scrolling/chromium/ScrollingCoordinatorChromium.h: Added.
49600         (WebCore):
49601         (ScrollingCoordinatorChromium):
49602         (WebCore::ScrollingCoordinatorChromium::supportsFixedPositionLayers):
49603         * page/scrolling/mac/ScrollingCoordinatorMac.h: Added.
49604         (WebCore):
49605         (ScrollingCoordinatorMac):
49606         (ScrollParameters):
49607         * page/scrolling/mac/ScrollingCoordinatorMac.mm:
49608         (WebCore::ScrollingCoordinatorMac::ScrollingCoordinatorMac):
49609         (WebCore::ScrollingCoordinatorMac::~ScrollingCoordinatorMac):
49610         (WebCore::ScrollingCoordinatorMac::pageDestroyed):
49611         (WebCore):
49612         (WebCore::ScrollingCoordinatorMac::scrollingTree):
49613         (WebCore::ScrollingCoordinatorMac::commitTreeStateIfNeeded):
49614         (WebCore::ScrollingCoordinatorMac::frameViewLayoutUpdated):
49615         (WebCore::ScrollingCoordinatorMac::recomputeWheelEventHandlerCountForFrameView):
49616         (WebCore::ScrollingCoordinatorMac::frameViewRootLayerDidChange):
49617         (WebCore::ScrollingCoordinatorMac::frameViewHorizontalScrollbarLayerDidChange):
49618         (WebCore::ScrollingCoordinatorMac::frameViewVerticalScrollbarLayerDidChange):
49619         (WebCore::ScrollingCoordinatorMac::requestScrollPositionUpdate):
49620         (WebCore::ScrollingCoordinatorMac::handleWheelEvent):
49621         (WebCore::ScrollingCoordinatorMac::updateMainFrameScrollPositionAndScrollLayerPosition):
49622         (WebCore::ScrollingCoordinatorMac::attachToStateTree):
49623         (WebCore::ScrollingCoordinatorMac::detachFromStateTree):
49624         (WebCore::ScrollingCoordinatorMac::clearStateTree):
49625         (WebCore::ScrollingCoordinatorMac::stateNodeForID):
49626         (WebCore::ScrollingCoordinatorMac::ensureRootStateNodeForFrameView):
49627         (WebCore::ScrollingCoordinatorMac::setScrollLayerForNode):
49628         (WebCore::ScrollingCoordinatorMac::setNonFastScrollableRegionForNode):
49629         (WebCore::ScrollingCoordinatorMac::setScrollParametersForNode):
49630         (WebCore::ScrollingCoordinatorMac::setWheelEventHandlerCountForNode):
49631         (WebCore::ScrollingCoordinatorMac::setShouldUpdateScrollLayerPositionOnMainThread):
49632         (WebCore::ScrollingCoordinatorMac::updateMainFrameScrollLayerPosition):
49633         (WebCore::ScrollingCoordinatorMac::scheduleTreeStateCommit):
49634         (WebCore::ScrollingCoordinatorMac::scrollingStateTreeCommitterTimerFired):
49635         (WebCore::ScrollingCoordinatorMac::commitTreeState):
49636
49637 2012-10-11  Takashi Sakamoto  <tasak@google.com>
49638
49639         [Shadow DOM] Insertion points need resetStyleInheritance
49640         https://bugs.webkit.org/show_bug.cgi?id=93922
49641
49642         Reviewed by Dimitri Glazkov.
49643
49644         Implemented resetStyleInheritance of insertion points.
49645         Its spec link is http://dvcs.w3.org/hg/webcomponents/raw-file/tip/spec/shadow/index.html#api-html-content-element-reset-style-inheritance
49646
49647         Test: fast/dom/shadow/insertion-point-resetStyleInheritance.html
49648
49649         * css/StyleResolver.cpp:
49650         (WebCore::isResetStyleInheritance):
49651         Added a new function to check whether there exists any insertion
49652         point which has reset-style-inhertiance flag set to be true.
49653         (WebCore::StyleResolver::initForStyleResolve):
49654         Modified to use the above function to check reset-style-inheritance.
49655         * html/shadow/HTMLContentElement.idl:
49656         * html/shadow/HTMLShadowElement.idl:
49657         Added a new attribute for reset-style-inheritance.
49658         * html/shadow/InsertionPoint.cpp:
49659         (WebCore::InsertionPoint::InsertionPoint):
49660         Initialized a new member variable for reset-style-inheritance.
49661         (WebCore::InsertionPoint::resetStyleInheritance):
49662         (WebCore::InsertionPoint::setResetStyleInheritance):
49663         Implemented setter/getter for reset-style-inheritance.
49664         * html/shadow/InsertionPoint.h:
49665         (InsertionPoint):
49666         Added a new member variable for reset-style-inheritance.
49667
49668 2012-10-11  Anders Carlsson  <andersca@apple.com>
49669
49670         Attempt to fix build broken by r131125.
49671
49672         * page/PageSerializer.cpp:
49673         (WebCore::PageSerializer::addImageToResources):
49674         KURL::utf8String() is apparently a USE(GOOGLEURL) feature. Call url.string().utf8() instead.
49675
49676 2012-10-11  Kenichi Ishibashi  <bashi@chromium.org>
49677
49678         [Chromium] Use harfbuzz-ng by default on Linux
49679         https://bugs.webkit.org/show_bug.cgi?id=97281
49680
49681         Reviewed by Tony Chang.
49682
49683         Switch old harfbuzz to harfbuzz-ng on chromium linux port.
49684
49685         No new tests. Existing tests should cover this switch.
49686         Test expectations will be updated.
49687
49688         * WebCore.gyp/WebCore.gyp:
49689
49690 2012-10-11  Nat Duca  <nduca@chromium.org>
49691
49692         Expose high-resolution on requestAnimationFrame callback
49693         https://bugs.webkit.org/show_bug.cgi?id=66683
49694
49695         This changes requestAnimationFrame's animationStartTime argument
49696         to be a high resolution DOM timestamp, per disucssion here:
49697         http://lists.w3.org/Archives/Public/public-web-perf/2012Apr/0004.html
49698
49699         Reviewed by James Robinson.
49700
49701         Covered by existing requestAnimationFrame tests.
49702
49703         * dom/Document.cpp:
49704         (WebCore::Document::serviceScriptedAnimations):
49705         * dom/Document.h:
49706         (Document):
49707         * dom/ScriptedAnimationController.cpp:
49708         (WebCore::ScriptedAnimationController::ScriptedAnimationController):
49709         (WebCore::ScriptedAnimationController::serviceScriptedAnimations):
49710         (WebCore):
49711         (WebCore::ScriptedAnimationController::windowScreenDidChange):
49712         (WebCore::ScriptedAnimationController::scheduleAnimation):
49713         (WebCore::ScriptedAnimationController::animationTimerFired):
49714         (WebCore::ScriptedAnimationController::displayRefreshFired):
49715         * dom/ScriptedAnimationController.h:
49716         (ScriptedAnimationController):
49717         * page/FrameView.cpp:
49718         (WebCore::FrameView::serviceScriptedAnimations):
49719         * page/FrameView.h:
49720         (FrameView):
49721         * platform/graphics/DisplayRefreshMonitor.cpp:
49722         (WebCore::DisplayRefreshMonitor::DisplayRefreshMonitor):
49723         (WebCore::DisplayRefreshMonitor::notifyClients):
49724         * platform/graphics/DisplayRefreshMonitor.h:
49725         (DisplayRefreshMonitor):
49726         * platform/graphics/blackberry/DisplayRefreshMonitorBlackBerry.cpp:
49727         (WebCore::DisplayRefreshMonitor::displayLinkFired):
49728         * platform/graphics/mac/DisplayRefreshMonitorMac.cpp:
49729         (WebCore):
49730         (WebCore::DisplayRefreshMonitor::requestRefreshCallback):
49731         (WebCore::DisplayRefreshMonitor::displayLinkFired):
49732
49733 2012-10-11  Sheriff Bot  <webkit.review.bot@gmail.com>
49734
49735         Unreviewed, rolling out r131100.
49736         http://trac.webkit.org/changeset/131100
49737         https://bugs.webkit.org/show_bug.cgi?id=99127
49738
49739         Caused an ASSERT (Requested by abarth|gardening on #webkit).
49740
49741         * platform/graphics/filters/CustomFilterValidatedProgram.cpp:
49742         (WebCore::CustomFilterValidatedProgram::compositeFunctionString):
49743
49744 2012-10-11  Kenichi Ishibashi  <bashi@chromium.org>
49745
49746         [Chromium] Improve vertical text rendering of HarfBuzzShaper (Re-land)
49747         https://bugs.webkit.org/show_bug.cgi?id=98979
49748
49749         Reviewed by Tony Chang.
49750
49751         - Specify 'vert' and 'vrt2' features when we render vertical text.
49752         - Set appropriate script so that harfbuzz-ng can use the features.
49753
49754         No new tests. fast/text/international/text-spliced-font.html should cover this change.
49755         This change will affect after switching to harfbuzz-ng.
49756
49757         * platform/graphics/harfbuzz/ng/HarfBuzzNGFace.cpp:
49758         (WebCore::HarfBuzzNGFace::HarfBuzzNGFace):
49759         (WebCore::findScriptForVerticalGlyphSubstitution): Added.
49760         (WebCore):
49761         (WebCore::HarfBuzzNGFace::setScriptForVerticalGlyphSubstitution): Added.
49762         * platform/graphics/harfbuzz/ng/HarfBuzzNGFace.h:
49763         (HarfBuzzNGFace): Added m_scriptForVerticalText.
49764         * platform/graphics/harfbuzz/ng/HarfBuzzShaper.cpp:
49765         (WebCore::HarfBuzzShaper::setFontFeatures):
49766         Set 'vert' and 'vrt2' features when orientation() == Vertical.
49767         (WebCore::HarfBuzzShaper::shapeHarfBuzzRuns):
49768         Call setScriptForVerticalGlyphSubstitution() when orientation() == Vertical.
49769
49770 2012-10-11  Jay Civelli  <jcivelli@chromium.org>
49771
49772         Fix for a crasher when generating MHTML for a page containing SVG images.
49773         https://bugs.webkit.org/show_bug.cgi?id=99105
49774
49775         Reviewed by Adam Barth.
49776
49777         * page/PageSerializer.cpp:
49778         (WebCore::PageSerializer::serializeCSSStyleSheet):
49779         (WebCore::PageSerializer::addImageToResources):
49780
49781 2012-10-11  Sheriff Bot  <webkit.review.bot@gmail.com>
49782
49783         Unreviewed, rolling out r131107.
49784         http://trac.webkit.org/changeset/131107
49785         https://bugs.webkit.org/show_bug.cgi?id=99126
49786
49787         Causes an ASSERT (Requested by abarth|gardening on #webkit).
49788
49789         * accessibility/AccessibilityNodeObject.cpp:
49790         (WebCore::AccessibilityNodeObject::labelForElement):
49791         * dom/DocumentOrderedMap.cpp:
49792         * dom/DocumentOrderedMap.h:
49793         (DocumentOrderedMap):
49794         * dom/Element.cpp:
49795         (WebCore::Element::insertedInto):
49796         (WebCore::Element::removedFrom):
49797         (WebCore):
49798         (WebCore::Element::willModifyAttribute):
49799         * dom/Element.h:
49800         (Element):
49801         * dom/TreeScope.cpp:
49802         (WebCore::TreeScope::TreeScope):
49803         * dom/TreeScope.h:
49804         (WebCore):
49805         (TreeScope):
49806
49807 2012-10-11  Tim Horton  <timothy_horton@apple.com>
49808
49809         LocalCurrentGraphicsContext will never restore the current context to null
49810         https://bugs.webkit.org/show_bug.cgi?id=99122
49811
49812         Reviewed by Simon Fraser.
49813
49814         LocalCurrentGraphicsContext is meant to cause temporary changes to
49815         NSGraphicsContext's currentContext. However, if it is entered when
49816         currentContext is null, it will not restore to null, as a null
49817         m_savedNSGraphicsContext was being used to indicate that the current and
49818         passed-in graphics contexts were equal (and thus no save/restore was required).
49819
49820         Add a separate flag for whether or not we need to restore the context.
49821
49822         Also flip the order of calls to restore graphics context state so that
49823         exiting LocalCurrentGraphicsContext does things in exactly the opposite
49824         of entry.
49825
49826         * platform/mac/LocalCurrentGraphicsContext.h:
49827         (LocalCurrentGraphicsContext):
49828         * platform/mac/LocalCurrentGraphicsContext.mm:
49829         (WebCore::LocalCurrentGraphicsContext::LocalCurrentGraphicsContext):
49830         (WebCore::LocalCurrentGraphicsContext::~LocalCurrentGraphicsContext):
49831
49832 2012-10-11  Sheriff Bot  <webkit.review.bot@gmail.com>
49833
49834         Unreviewed, rolling out r131109.
49835         http://trac.webkit.org/changeset/131109
49836         https://bugs.webkit.org/show_bug.cgi?id=99124
49837
49838         Does not compile on chromium-mac (Requested by
49839         abarth|gardening on #webkit).
49840
49841         * platform/graphics/harfbuzz/ng/HarfBuzzNGFace.cpp:
49842         (WebCore::HarfBuzzNGFace::HarfBuzzNGFace):
49843         * platform/graphics/harfbuzz/ng/HarfBuzzNGFace.h:
49844         (HarfBuzzNGFace):
49845         * platform/graphics/harfbuzz/ng/HarfBuzzShaper.cpp:
49846         (WebCore::HarfBuzzShaper::setFontFeatures):
49847         (WebCore::HarfBuzzShaper::shapeHarfBuzzRuns):
49848
49849 2012-10-11  Beth Dakin  <bdakin@apple.com>
49850
49851         https://bugs.webkit.org/show_bug.cgi?id=99111
49852         ScrollingStateNode should keep its Vector of children in an OwnPtr
49853
49854         Reviewed by Ada Chan.
49855
49856         Vector<OwnPtr<ScrollingStateNode> >* m_children; is now:
49857          OwnPtr<Vector<OwnPtr<ScrollingStateNode> > > m_children;
49858         * page/scrolling/ScrollingStateNode.cpp:
49859         (WebCore::ScrollingStateNode::ScrollingStateNode):
49860         (WebCore::ScrollingStateNode::~ScrollingStateNode):
49861         (WebCore::ScrollingStateNode::appendChild):
49862         * page/scrolling/ScrollingStateNode.h:
49863         (ScrollingStateNode):
49864
49865 2012-10-11  Levi Weintraub  <leviw@chromium.org>
49866
49867         [Sub pixel layout] Fast-path iframe scrolling can picks up an extra pixel
49868         https://bugs.webkit.org/show_bug.cgi?id=98571
49869
49870         Reviewed by Emil A Eklund.
49871
49872         Refactoring all coordinate-switching functionality to use a single "mode" flag
49873         as opposed to having a bunch of boolean values. This enables the same set of
49874         options across the board, and a consistent interface. This was previously
49875         done for mapLocalToContainer.
49876
49877         The imptetus for this for this stems from the one logical change in this patch
49878         which only effects sub-pixel layout. FrameView::convertToRenderer and
49879         convertFromRenderer return IntPoint coordinates, and need to also snap transform
49880         offsets to determine proper rects for scrolling.
49881
49882         Unlabeled functions below are simply being updated to these new interfaces.
49883
49884         Test: fast/sub-pixel/sub-pixel-iframe-copy-on-scroll.html
49885
49886         * WebCore.exp.in:
49887         * dom/ContainerNode.cpp:
49888         (WebCore::ContainerNode::getUpperLeftCorner):
49889         (WebCore::ContainerNode::getLowerRightCorner):
49890         * dom/Element.cpp:
49891         (WebCore::Element::boundsInRootViewSpace):
49892         * dom/MouseRelatedEvent.cpp:
49893         (WebCore::MouseRelatedEvent::computeRelativePosition):
49894         * dom/Node.cpp:
49895         (WebCore::Node::convertToPage):
49896         (WebCore::Node::convertFromPage):
49897         * html/HTMLSelectElement.cpp:
49898         (WebCore::HTMLSelectElement::listBoxDefaultEventHandler):
49899         * html/shadow/SliderThumbElement.cpp:
49900         (WebCore::SliderThumbElement::setPositionFromPoint):
49901         * html/shadow/SpinButtonElement.cpp:
49902         (WebCore::SpinButtonElement::defaultEventHandler):
49903         * page/FrameView.cpp:
49904         (WebCore::FrameView::convertToRenderer): Now pixel-snaps offsets before passing
49905         them to TransformState, which transforms the coordinates.
49906         (WebCore::FrameView::convertFromRenderer): Ditto.
49907         * rendering/LayoutState.cpp:
49908         (WebCore::LayoutState::LayoutState):
49909         * rendering/RenderBlock.cpp:
49910         (WebCore::RenderBlock::absoluteQuads):
49911         * rendering/RenderBox.cpp:
49912         (WebCore::RenderBox::absoluteQuads):
49913         (WebCore::RenderBox::mapLocalToContainer):
49914         (WebCore::RenderBox::mapAbsoluteToLocalPoint):
49915         * rendering/RenderBox.h:
49916         (RenderBox):
49917         * rendering/RenderBoxModelObject.cpp:
49918         (WebCore::RenderBoxModelObject::mapAbsoluteToLocalPoint):
49919         * rendering/RenderBoxModelObject.h:
49920         (RenderBoxModelObject):
49921         * rendering/RenderEmbeddedObject.cpp:
49922         (WebCore::RenderEmbeddedObject::isInUnavailablePluginIndicator):
49923         * rendering/RenderFrameSet.cpp:
49924         (WebCore::RenderFrameSet::userResize):
49925         * rendering/RenderGeometryMap.cpp:
49926         (WebCore::RenderGeometryMap::absolutePoint):
49927         * rendering/RenderInline.cpp:
49928         (WebCore::RenderInline::mapLocalToContainer):
49929         * rendering/RenderInline.h:
49930         (RenderInline):
49931         * rendering/RenderLayer.cpp:
49932         (WebCore::RenderLayer::absoluteToContents):
49933         (WebCore::RenderLayer::calculateClipRects):
49934         * rendering/RenderMediaControls.cpp:
49935         (WebCore::RenderMediaControls::volumeSliderOffsetFromMuteButton):
49936         * rendering/RenderMenuList.cpp:
49937         (WebCore::RenderMenuList::showPopup):
49938         * rendering/RenderObject.cpp:
49939         (WebCore::RenderObject::localToAbsolute):
49940         (WebCore::RenderObject::absoluteToLocal):
49941         (WebCore::RenderObject::mapLocalToContainer):
49942         (WebCore::RenderObject::mapAbsoluteToLocalPoint):
49943         (WebCore::RenderObject::localToContainerQuad):
49944         (WebCore::RenderObject::localToContainerPoint):
49945         * rendering/RenderObject.h:
49946         (RenderObject): MapLocalToContainerFlags is now MapCoordinatesFlags since it's
49947         now used for other conversion methods.
49948         (WebCore::RenderObject::localToAbsoluteQuad):
49949         * rendering/RenderTheme.cpp:
49950         (WebCore::RenderTheme::volumeSliderOffsetFromMuteButton):
49951         * rendering/RenderView.cpp:
49952         (WebCore::RenderView::mapLocalToContainer):
49953         (WebCore::RenderView::mapAbsoluteToLocalPoint):
49954         * rendering/RenderView.h:
49955         (RenderView):
49956         * rendering/svg/RenderSVGForeignObject.cpp:
49957         (WebCore::RenderSVGForeignObject::mapLocalToContainer):
49958         * rendering/svg/RenderSVGForeignObject.h:
49959         (RenderSVGForeignObject):
49960         * rendering/svg/RenderSVGInline.cpp:
49961         (WebCore::RenderSVGInline::mapLocalToContainer):
49962         * rendering/svg/RenderSVGInline.h:
49963         (RenderSVGInline):
49964         * rendering/svg/RenderSVGModelObject.cpp:
49965         (WebCore::RenderSVGModelObject::mapLocalToContainer):
49966         * rendering/svg/RenderSVGModelObject.h:
49967         (RenderSVGModelObject):
49968         * rendering/svg/RenderSVGRoot.cpp:
49969         (WebCore::RenderSVGRoot::mapLocalToContainer):
49970         * rendering/svg/RenderSVGRoot.h:
49971         (RenderSVGRoot):
49972         * rendering/svg/RenderSVGText.cpp:
49973         (WebCore::RenderSVGText::mapLocalToContainer):
49974         * rendering/svg/RenderSVGText.h:
49975         (RenderSVGText):
49976         * rendering/svg/SVGRenderSupport.cpp:
49977         (WebCore::SVGRenderSupport::mapLocalToContainer):
49978         * svg/SVGSVGElement.cpp:
49979         (WebCore::SVGSVGElement::localCoordinateSpaceTransform):
49980
49981 2012-10-11  Adam Barth  <abarth@webkit.org>
49982
49983         Incorrect/Illegal static cast in FrameView.cpp
49984         https://bugs.webkit.org/show_bug.cgi?id=98943
49985
49986         Reviewed by Eric Seidel.
49987
49988         HTMLFrameElementBase is the common base class for <frame> and <iframe>.
49989
49990         * page/FrameView.cpp:
49991         (WebCore::FrameView::init):
49992
49993 2012-10-11  Kenichi Ishibashi  <bashi@chromium.org>
49994
49995         [Chromium] Improve vertical text rendering of HarfBuzzShaper
49996         https://bugs.webkit.org/show_bug.cgi?id=98979
49997
49998         Reviewed by Tony Chang.
49999
50000         - Specify 'vert' and 'vrt2' features when we render vertical text.
50001         - Set appropriate script so that harfbuzz-ng can use the features.
50002
50003         No new tests. fast/text/international/text-spliced-font.html should cover this change.
50004         This change will affect after switching to harfbuzz-ng.
50005
50006         * platform/graphics/harfbuzz/ng/HarfBuzzNGFace.cpp:
50007         (WebCore::HarfBuzzNGFace::HarfBuzzNGFace):
50008         (WebCore::findScriptForVerticalGlyphSubstitution): Added.
50009         (WebCore):
50010         (WebCore::HarfBuzzNGFace::setScriptForVerticalGlyphSubstitution): Added.
50011         * platform/graphics/harfbuzz/ng/HarfBuzzNGFace.h:
50012         (HarfBuzzNGFace): Added m_scriptForVerticalText.
50013         * platform/graphics/harfbuzz/ng/HarfBuzzShaper.cpp:
50014         (WebCore::HarfBuzzShaper::setFontFeatures):
50015         Set 'vert' and 'vrt2' features when orientation() == Vertical.
50016         (WebCore::HarfBuzzShaper::shapeHarfBuzzRuns):
50017         Call setScriptForVerticalGlyphSubstitution() when orientation() == Vertical.
50018
50019 2012-10-11  Dominic Mazzoni  <dmazzoni@google.com>
50020
50021         AX: labelForElement is slow when there are a lot of DOM elements
50022         https://bugs.webkit.org/show_bug.cgi?id=97825
50023
50024         Reviewed by Ryosuke Niwa.
50025
50026         Adds a DocumentOrderedMap to TreeScope that allows accessibility to
50027         quickly map from an id to the label for that id. This speeds up
50028         AccessibilityNode::labelForElement, which was a bottleneck in Chromium
50029         when accessibility was on.
50030
50031         Tests: accessibility/title-ui-element-correctness.html
50032                perf/accessibility-title-ui-element.html
50033
50034         * accessibility/AccessibilityNodeObject.cpp:
50035         (WebCore::AccessibilityNodeObject::labelForElement):
50036         * dom/DocumentOrderedMap.cpp:
50037         (WebCore::keyMatchesLabelForAttribute):
50038         (WebCore):
50039         (WebCore::DocumentOrderedMap::getElementByLabelForAttribute):
50040         * dom/DocumentOrderedMap.h:
50041         (DocumentOrderedMap):
50042         * dom/Element.cpp:
50043         (WebCore::Element::insertedInto):
50044         (WebCore::Element::removedFrom):
50045         (WebCore::Element::updateLabel):
50046         (WebCore):
50047         (WebCore::Element::willModifyAttribute):
50048         * dom/Element.h:
50049         (Element):
50050         * dom/TreeScope.cpp:
50051         (WebCore::TreeScope::TreeScope):
50052         (WebCore::TreeScope::addLabel):
50053         (WebCore):
50054         (WebCore::TreeScope::removeLabel):
50055         (WebCore::TreeScope::labelElementForId):
50056         * dom/TreeScope.h:
50057         (WebCore):
50058         (TreeScope):
50059         (WebCore::TreeScope::shouldCacheLabelsByForAttribute):
50060
50061 2012-10-11  James Simonsen  <simonjam@chromium.org>
50062
50063         unprefix window.performance.webkitNow()
50064         https://bugs.webkit.org/show_bug.cgi?id=88278
50065
50066         Reviewed by Tony Gentilcore.
50067
50068         Test: fast/dom/Window/window-properties-performance.html
50069               fast/performance/performance-now-timestamps.html
50070
50071         * page/Performance.cpp:
50072         (WebCore::Performance::now):
50073         * page/Performance.h:
50074         (Performance):
50075         * page/Performance.idl:
50076
50077 2012-10-11  Roger Fong  <roger_fong@apple.com>
50078
50079         [WebGL] [Mac] only the mapped symbol for the first element of a uniform/attribute array is stored.
50080         https://bugs.webkit.org/show_bug.cgi?id=98966
50081
50082         Reviewed by Dean Jackson.
50083
50084         We currently do not add name/mappedName symbol pairs for each element of a uniform/attribute array.
50085         This is because we only add a number of symbols equal to how many symbols the shader compiler tells us there are.
50086         The shader compiler treats an array as a single uniform. We need to be adding in symbols to the map for each element of the array ourselves.
50087         The mappedName of each array element is the same between elements except for the "[index]" at the end so this is easy to do.
50088
50089         Tested using Khronos WebGL conformance suite:
50090         conformance/glsl/misc/glsl-long-variable-names.html
50091
50092         * platform/graphics/ANGLEWebKitBridge.cpp:
50093         (WebCore::getSymbolInfo):
50094
50095 2012-10-11  Andreas Kling  <kling@webkit.org>
50096
50097         ElementAttributeData shouldn't be managing Element's callbacks.
50098         <http://webkit.org/b/98987>
50099
50100         Reviewed by Anders Carlsson.
50101
50102         Dispatch the following attribute-related Element callbacks from within Element
50103         instead of ElementAttributeData. Also made them private.
50104
50105             - willModifyAttribute
50106             - didModifyAttribute
50107             - didAddAttribute
50108             - didRemoveAttribute
50109
50110         No behavior change, just making ElementAttributeData a bit dumber (a good thing.)
50111
50112         * dom/Element.cpp:
50113         (WebCore::Element::detachAttribute):
50114         (WebCore::Element::removeAttribute):
50115         (WebCore::Element::setAttributeInternal):
50116         (WebCore::Element::removeAttributeInternal):
50117         (WebCore::Element::addAttributeInternal):
50118         * dom/Element.h:
50119         * dom/ElementAttributeData.cpp:
50120         (WebCore::ElementAttributeData::addAttribute):
50121         (WebCore::ElementAttributeData::removeAttribute):
50122         * dom/ElementAttributeData.h:
50123
50124 2012-10-11  Huang Dongsung  <luxtella@company100.net>
50125
50126         [CSS Shaders] Make custom filters use a premultiplied buffer.
50127         https://bugs.webkit.org/show_bug.cgi?id=98396
50128
50129         Reviewed by Dean Jackson.
50130
50131         Currently, a GLSL css_Composite function returns a premultiplied color, so
50132         FECustomFilter must make a premultiplied buffer in the case when an author is
50133         using the CSS mix function.
50134
50135         In addition, there are two performance benefits when FECustomFilter uses a premultiplied buffer.
50136         1. FilterEffect::asImageBuffer is faster.
50137         2. In the future when Accelerated Compositing implementations use
50138         FECustomFilter, they do not need to convert an unmultiplied buffer to a
50139         premultiplied buffer.
50140
50141         Test: css3/filters/custom/custom-filter-composite-fractional-source-alpha.html
50142
50143         * platform/graphics/filters/FECustomFilter.cpp:
50144         (WebCore::FECustomFilter::applyShader):
50145
50146 2012-10-11  Rob Buis  <rbuis@rim.com>
50147
50148         [CMAKE] Do not add include dirs twice
50149         https://bugs.webkit.org/show_bug.cgi?id=99099
50150
50151         Reviewed by Yong Li.
50152
50153         Do not add WebCore_INCLUDE_DIRECTORIES to WebCoreTestSupport_INCLUDE_DIRECTORIES, the includes_directory
50154         call does this for us.
50155
50156         * CMakeLists.txt:
50157
50158 2012-10-11  Huang Dongsung  <luxtella@company100.net>
50159
50160         [CSS Shaders] Implement all composite operators except destination and lighter.
50161         https://bugs.webkit.org/show_bug.cgi?id=97859
50162
50163         Reviewed by Dean Jackson.
50164
50165         Add expressions for all composite operators except destination and
50166         lighter. The expressions are lifted directly from the CSS Compositing
50167         and Blending spec [1]. WebKit adds these compositing expressions to the
50168         author's shader.
50169
50170         [1]: https://dvcs.w3.org/hg/FXTF/rawfile/tip/compositing/index.html#advancedcompositing
50171
50172         Test: css3/filters/custom/custom-filter-composite-operators.html
50173
50174         * platform/graphics/filters/CustomFilterValidatedProgram.cpp:
50175         (WebCore::CustomFilterValidatedProgram::compositeFunctionString):
50176
50177 2012-10-11  Joshua Bell  <jsbell@chromium.org>
50178
50179         IndexedDB: IDL types defined in spec should be visible to scripts
50180         https://bugs.webkit.org/show_bug.cgi?id=99093
50181
50182         Reviewed by Adam Barth.
50183
50184         Interfaces defined in the spec WebIDL, such as IDBCursorWithValue, should be exposed
50185         to scripts as properties of the global object. A few types were missing - add them.
50186
50187         Test: storage/indexeddb/interfaces.html
50188
50189         * Modules/indexeddb/DOMWindowIndexedDatabase.idl:
50190         * Modules/indexeddb/WorkerContextIndexedDatabase.idl:
50191
50192 2012-10-11  Geoffrey Garen  <ggaren@apple.com>
50193
50194         Removed ASSERT_CLASS_FITS_IN_CELL
50195         https://bugs.webkit.org/show_bug.cgi?id=97634
50196
50197         Reviewed by Mark Hahnenberg.
50198
50199         * bindings/js/JSDOMWindowShell.cpp:
50200         (WebCore):
50201         * bindings/js/JSImageConstructor.cpp:
50202         (WebCore):
50203         * bindings/js/JSNodeFilterCondition.cpp:
50204         (WebCore):
50205         * bindings/js/JSWorkerContextBase.cpp:
50206         (WebCore):
50207         * bindings/scripts/CodeGeneratorJS.pm:
50208         (GenerateImplementation):
50209         * bindings/scripts/test/JS/JSFloat64Array.cpp:
50210         (WebCore):
50211         * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
50212         (WebCore):
50213         * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
50214         (WebCore):
50215         * bindings/scripts/test/JS/JSTestEventConstructor.cpp:
50216         (WebCore):
50217         * bindings/scripts/test/JS/JSTestEventTarget.cpp:
50218         (WebCore):
50219         * bindings/scripts/test/JS/JSTestException.cpp:
50220         (WebCore):
50221         * bindings/scripts/test/JS/JSTestInterface.cpp:
50222         (WebCore):
50223         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
50224         (WebCore):
50225         * bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
50226         (WebCore):
50227         * bindings/scripts/test/JS/JSTestNode.cpp:
50228         (WebCore):
50229         * bindings/scripts/test/JS/JSTestObj.cpp:
50230         (WebCore):
50231         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
50232         (WebCore):
50233         * bridge/runtime_method.cpp:
50234         (JSC):
50235
50236 2012-10-10  Brady Eidson  <beidson@apple.com>
50237
50238         Switch ResourceLoader::resourceData() from SharedBuffer to ResourceBuffer
50239         https://bugs.webkit.org/show_bug.cgi?id=98976
50240
50241         Reviewed by Anders Carlsson.
50242
50243         No new tests (No change in behavior).
50244
50245         * WebCore.exp.in:
50246         * html/ImageDocument.cpp:
50247         (WebCore::ImageDocumentParser::appendBytes):
50248         (WebCore::ImageDocumentParser::finish):
50249         * inspector/InspectorPageAgent.cpp:
50250         (WebCore::InspectorPageAgent::mainResourceContent):
50251         (WebCore::InspectorPageAgent::sharedBufferContent):
50252         (WebCore):
50253         (WebCore::InspectorPageAgent::dataContent):
50254         * inspector/InspectorPageAgent.h:
50255         * inspector/InspectorResourceAgent.cpp:
50256         (WebCore::InspectorResourceAgent::didFinishLoading):
50257         (WebCore::InspectorResourceAgent::didFailLoading):
50258         * loader/DocumentLoader.cpp:
50259         (WebCore::DocumentLoader::mainResourceData):
50260         (WebCore::DocumentLoader::setupForReplaceByMIMEType):
50261         (WebCore::DocumentLoader::maybeCreateArchive):
50262         (WebCore::DocumentLoader::mainResource):
50263         (WebCore::DocumentLoader::maybeFinishLoadingMultipartContent):
50264         * loader/DocumentLoader.h:
50265         (WebCore):
50266         (DocumentLoader):
50267         * loader/ResourceBuffer.cpp:
50268         (WebCore::ResourceBuffer::append):
50269         (WebCore):
50270         (WebCore::ResourceBuffer::clear):
50271         * loader/ResourceBuffer.h:
50272         (ResourceBuffer):
50273         * loader/ResourceLoader.cpp:
50274         (WebCore::ResourceLoader::resourceData):
50275         (WebCore::ResourceLoader::addData):
50276         (WebCore::ResourceLoader::willStopBufferingData):
50277         * loader/ResourceLoader.h:
50278         (WebCore):
50279         (ResourceLoader):
50280         * loader/SubresourceLoader.cpp:
50281         (WebCore::SubresourceLoader::didReceiveResponse):
50282         (WebCore::SubresourceLoader::sendDataToResource):
50283         (WebCore::SubresourceLoader::didFinishLoading):
50284         * loader/appcache/ApplicationCacheGroup.cpp:
50285         (WebCore::ApplicationCacheGroup::finishedLoadingMainResource):
50286
50287 2012-10-11  Konrad Piascik  <kpiascik@rim.com>
50288
50289         Web Inspector: node search does not work with elements on touch start listener
50290         https://bugs.webkit.org/show_bug.cgi?id=95252
50291
50292         Reviewed by Pavel Feldman.
50293
50294         Added new InspectorInstrumentation::handleTouchEvent() method which
50295         will prevent a touch handler from firing and inspect and element if we
50296         are already searching for a node to highlight.
50297         Now when a user has chosen to inspect element (magnifying glass icon)
50298         and touches on a page the event will be directed to inspector and
50299         handled appropriately.
50300
50301         Not testable.
50302
50303         * inspector/InspectorDOMAgent.cpp:
50304         (WebCore::InspectorDOMAgent::handleTouchEvent):
50305         (WebCore):
50306         * inspector/InspectorDOMAgent.h:
50307         (InspectorDOMAgent):
50308         * inspector/InspectorInstrumentation.cpp:
50309         (WebCore):
50310         (WebCore::InspectorInstrumentation::handleTouchEventImpl):
50311         * inspector/InspectorInstrumentation.h:
50312         (InspectorInstrumentation):
50313         (WebCore::InspectorInstrumentation::handleTouchEvent):
50314         (WebCore):
50315         * page/EventHandler.cpp:
50316         (WebCore::EventHandler::handleTouchEvent):
50317
50318 2012-10-11  Otto Derek Cheung  <otcheung@rim.com>
50319
50320         [BlackBerry] Credentials for HTTPS urls are saved in the HTTP protection space
50321         https://bugs.webkit.org/show_bug.cgi?id=99082
50322
50323         Reviewed by Rob Buis.
50324
50325         Adding support for secure ProtectionSpaces in Credentials
50326         to prevent credentials from being overwritten/used when the user
50327         accesses both versions of the same url.
50328
50329         PR 199457
50330
50331         The issue was the secure/non-secure version of the same protocol
50332         were using the same ProtectionSpace enum in the network stack. When
50333         the credentials are saved, it will overwrite each other since the
50334         protection object is identical.
50335
50336         The fix is to use the WebKit provided secure enums when the protcol is secure.
50337
50338         To test this, access a restricted site that is running on http. Save the
50339         password and access the same restricted site (same domain
50340         and path) but on https. The browser should prompt for credentials.
50341
50342         * platform/network/blackberry/NetworkJob.cpp:
50343         (WebCore::NetworkJob::notifyAuthReceived):
50344         (WebCore::NetworkJob::handleFTPHeader):
50345         (WebCore::NetworkJob::sendRequestWithCredentials):
50346         (WebCore::NetworkJob::storeCredentials):
50347         * platform/network/blackberry/NetworkManager.cpp:
50348         (WebCore::NetworkManager::startJob):
50349
50350 2012-10-11  Arnaud Renevier  <a.renevier@sisa.samsung.com>
50351
50352         [texmap] logic error in BitmapTextureGL::updateContents
50353         https://bugs.webkit.org/show_bug.cgi?id=98969
50354
50355         Reviewed by Noam Rosenthal.
50356
50357         Incorrect test (bytesPerLine == targetRect.width() / 4) never
50358         evaluates to true. Change it to correct test 
50359         (bytesPerLine == targetRect.width() * 4)
50360
50361         No new tests because no functional change.
50362
50363         * platform/graphics/texmap/TextureMapperGL.cpp:
50364         (WebCore::BitmapTextureGL::updateContents):
50365
50366 2012-10-11  Dan Bernstein  <mitz@apple.com>
50367
50368         <rdar://problem/12477191> Combined text reverts to full-width font after a style change
50369         https://bugs.webkit.org/show_bug.cgi?id=99009
50370
50371         Reviewed by John Sullivan.
50372
50373         Test: fast/text/text-combine-width-after-style-change.html
50374
50375         * rendering/RenderCombineText.cpp:
50376         (WebCore::RenderCombineText::styleDidChange): Changed to reset m_isCombined to false, to
50377         ensure that combineText() is called on the next layout.
50378
50379 2012-10-11  Arnaud Renevier  <a.renevier@sisa.samsung.com>
50380
50381         accelerated compositing does not work with ati driver
50382         https://bugs.webkit.org/show_bug.cgi?id=97472
50383
50384         Reviewed by Martin Robinson.
50385
50386         Create m_parentWindow at positive position. Otherwise, parts of it are
50387         not displayed on ati drivers.
50388
50389         Covered by existing tests.
50390
50391         * platform/gtk/RedirectedXCompositeWindow.cpp:
50392         (WebCore::RedirectedXCompositeWindow::RedirectedXCompositeWindow):
50393
50394 2012-10-11  Jaehun Lim  <ljaehun.lim@samsung.com>
50395
50396         Fix JPEG decoding faiure when IMAGE_DECODER_DOWN_SAMPLING is enabled
50397         https://bugs.webkit.org/show_bug.cgi?id=98878
50398
50399         Reviewed by Kenneth Russell.
50400
50401         When using libjpeg-turbo and enabling IMAGE_DECODER_DOWN_SAMPLING,
50402         JPEG decoding failed because of no support for JCS_EXT_RGBA, JCS_EXT_BGRA.
50403         Set RGBA values when color space is JCS_EXT_RGBA or JCS_EXT_BGRA.
50404
50405         No new tests.
50406
50407         * platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
50408         (WebCore::JPEGImageDecoder::outputScanlines):
50409
50410 2012-10-11  Vsevolod Vlasov  <vsevik@chromium.org>
50411
50412         Web Inspector: Preview HTML in ajax responses in network panel
50413         https://bugs.webkit.org/show_bug.cgi?id=99066
50414
50415         Reviewed by Yury Semikhatsky.
50416
50417         HTML preview is now shown for XHR responses with text/html mime types.
50418         Also RequestHTMLView is refactored to use sandbox iframe correctly.
50419         Also extracted a method to generate dataURL from resource/request content.
50420
50421         * inspector/front-end/NetworkRequest.js:
50422         (WebInspector.NetworkRequest):
50423         (WebInspector.NetworkRequest.prototype.populateImageSource):
50424         (WebInspector.NetworkRequest.prototype.asDataURL):
50425         * inspector/front-end/RequestHTMLView.js:
50426         (WebInspector.RequestHTMLView):
50427         (WebInspector.RequestHTMLView.prototype._createIFrame):
50428         * inspector/front-end/RequestPreviewView.js:
50429         (WebInspector.RequestPreviewView.prototype._createPreviewView):
50430         * inspector/front-end/Resource.js:
50431         (WebInspector.Resource.prototype.populateImageSource):
50432         * inspector/front-end/ResourceUtils.js:
50433         (WebInspector.contentAsDataURL):
50434
50435 2012-10-11  Christophe Dumez  <christophe.dumez@intel.com>
50436
50437         Regression(r131058): Broke EFL build
50438         https://bugs.webkit.org/show_bug.cgi?id=99079
50439
50440         Unreviewed build fix.
50441
50442         Use iterator::value instead of iterator::second to fix
50443         build break after r131058.
50444
50445         * platform/graphics/freetype/SimpleFontDataFreeType.cpp:
50446         (WebCore::SimpleFontData::canRenderCombiningCharacterSequence):
50447
50448 2012-10-11  Mihai Balan  <mibalan@adobe.com>
50449
50450         Always enable the experiments tab for WebKit nightly
50451
50452         Web Inspector: Enabling experiments tab in WebKit nightly.
50453         https://bugs.webkit.org/show_bug.cgi?id=98923
50454
50455         Reviewed by Pavel Feldman.
50456
50457         Enabling Web Inspector experiments tab in WebKit nightly. This is done by adding a new
50458         Preference key, Preferences.experimentsEnabled. Default values are true for WebKit and false
50459         for Chromium. They can also be overridden as before (in Chromium)
50460
50461         * inspector/front-end/Settings.js:
50462         (WebInspector.ExperimentsSettings.prototype.get experimentsEnabled):
50463
50464 2012-10-11  Hayato Ito  <hayato@chromium.org>
50465
50466         Support re-projection for Shadow DOM.
50467         https://bugs.webkit.org/show_bug.cgi?id=97151
50468
50469         Reviewed by Dimitri Glazkov.
50470
50471         Update node distribution algorithm so that nodes can be re-projected to insertion points
50472         in nested shadow subtree.
50473
50474         See the latest Shadow DOM spec for what 're-projected' means:
50475         - http://dvcs.w3.org/hg/webcomponents/raw-file/tip/spec/shadow/index.html
50476         Also see the related W3C bug:
50477         - http://www.w3.org/Bugs/Public/show_bug.cgi?id=18513
50478
50479         Since this change breaks existing behavior, we have to update several code at once, which includes:
50480         - ContentDistributer: ContentDistributor now re-projects distributed nodes.
50481         - ComposedShadowTreeWalker: ComposedShadowTreeWalker is now aware of re-projection. That can
50482           resolve re-projection transparently.
50483         - AncestorChainWalker (formerly named ComposedShadowTreeParentWallker):
50484           AncestorChainWalker is now aware of re-projection. I've also added a crossingInsertionPoint()
50485           member function so that clients of the walker can know whether the walker is just crossing
50486           insertion points for a re-projected node.
50487         - EventDispatcher: EventDispatcher now uses the updated AncestorChainWalker and its
50488           crossingInsertionPoint() so that EventDispatcher can compute relative target for each ancestor correctly.
50489
50490         I've also updated existing layout tests and added some layout tests for re-projection.
50491         Re-projection for multiple shadow root is not supported yet. I'll address that in another bug.
50492
50493         Tests: fast/dom/shadow/composed-shadow-tree-walker.html
50494                fast/dom/shadow/shadow-dom-event-dispatching.html
50495                fast/dom/shadow/shadowdom-reprojection-1.html
50496                fast/dom/shadow/shadowdom-reprojection-2.html
50497
50498         * dom/ComposedShadowTreeWalker.cpp:
50499         (WebCore::resolveReprojection):
50500         (WebCore):
50501         (WebCore::ComposedShadowTreeWalker::traverseSiblingOrBackToInsertionPoint):
50502         (WebCore::ComposedShadowTreeWalker::traverseParent):
50503         (WebCore::AncestorChainWalker::AncestorChainWalker):
50504         (WebCore::AncestorChainWalker::parent):
50505         * dom/ComposedShadowTreeWalker.h:
50506         (AncestorChainWalker):
50507         (WebCore::AncestorChainWalker::crossingInsertionPoint):
50508         * dom/EventDispatcher.cpp:
50509         (WebCore::EventRelatedTargetAdjuster::adjust):
50510         (WebCore::EventDispatcher::ensureEventAncestors):
50511         * dom/TreeScope.cpp:
50512         (WebCore::TreeScope::focusedNode):
50513         * html/HTMLLIElement.cpp:
50514         (WebCore::HTMLLIElement::attach):
50515         * html/shadow/ContentDistributor.cpp:
50516         (WebCore::ContentDistributor::distribute):
50517         * page/EventHandler.cpp:
50518         (WebCore::EventHandler::updateMouseEventTargetNode):
50519
50520 2012-10-11  Shinya Kawanaka  <shinyak@chromium.org>
50521
50522         Make ContentSelectorQuery work when siblings are passed explicitly.
50523         https://bugs.webkit.org/show_bug.cgi?id=96990
50524
50525         Reviewed by Dimitri Glazkov.
50526
50527         When we implement content reprojection in ShadowDOM, we have to pass a node pool to SelectorChecker.
50528         We introdue ShadowDOMSiblingTraversalStrategy, which traverses a node pool instead of real node siblings.
50529
50530         Since ContentSelector is a very hot place, we don't want to regress performance. In the previous patch,
50531         we've make ContentSelector::checkOneSelector template to take SiblingTraversalStrategy as an argument.
50532
50533         We also move DOMSiblingTraversalStrategy to SiblingTraversalStrategies.h.
50534
50535         * GNUmakefile.list.am:
50536         * Target.pri:
50537         * WebCore.gypi:
50538         * WebCore.vcproj/WebCore.vcproj:
50539         * WebCore.xcodeproj/project.pbxproj:
50540         * css/SelectorChecker.cpp:
50541         (WebCore):
50542         * css/SelectorChecker.h:
50543         * css/SiblingTraversalStrategies.h: Added.
50544         (WebCore):
50545         (DOMSiblingTraversalStrategy): Moved from SelectorChecker.
50546         (WebCore::DOMSiblingTraversalStrategy::isFirstChild):
50547         (WebCore::DOMSiblingTraversalStrategy::isLastChild):
50548         (WebCore::DOMSiblingTraversalStrategy::isFirstOfType):
50549         (WebCore::DOMSiblingTraversalStrategy::isLastOfType):
50550         (WebCore::DOMSiblingTraversalStrategy::countElementsBefore):
50551         (WebCore::DOMSiblingTraversalStrategy::countElementsOfTypeBefore):
50552         (WebCore::DOMSiblingTraversalStrategy::countElementsAfter):
50553         (WebCore::DOMSiblingTraversalStrategy::countElementsOfTypeAfter):
50554         (WebCore::ShadowDOMSiblingTraversalStrategy::ShadowDOMSiblingTraversalStrategy):
50555         (ShadowDOMSiblingTraversalStrategy): SiblingTraversalStrategy which uses a node pool instead of a real element
50556         siblings. This strategy takes a vector of node which we traverse.
50557         (WebCore::ShadowDOMSiblingTraversalStrategy::isFirstChild):
50558         (WebCore::ShadowDOMSiblingTraversalStrategy::isLastChild):
50559         (WebCore::ShadowDOMSiblingTraversalStrategy::isFirstOfType):
50560         (WebCore::ShadowDOMSiblingTraversalStrategy::isLastOfType):
50561         (WebCore::ShadowDOMSiblingTraversalStrategy::countElementsBefore):
50562         (WebCore::ShadowDOMSiblingTraversalStrategy::countElementsAfter):
50563         (WebCore::ShadowDOMSiblingTraversalStrategy::countElementsOfTypeBefore):
50564         (WebCore::ShadowDOMSiblingTraversalStrategy::countElementsOfTypeAfter):
50565         * css/StyleResolver.cpp:
50566         * html/shadow/ContentDistributor.cpp:
50567         (WebCore::ContentDistributor::distributeSelectionsTo):
50568         * html/shadow/ContentSelectorQuery.cpp: Uses ShadowDOMSiblingTraversalStrategy instead of DOMSiblingTraversalStrategy.
50569         (WebCore::ContentSelectorChecker::ContentSelectorChecker):
50570         (WebCore):
50571         (WebCore::ContentSelectorChecker::checkContentSelector):
50572         (WebCore::ContentSelectorDataList::initialize):
50573         (WebCore::ContentSelectorDataList::matches):
50574         (WebCore::ContentSelectorQuery::ContentSelectorQuery):
50575         (WebCore::ContentSelectorQuery::matches):
50576         * html/shadow/ContentSelectorQuery.h:
50577         (ContentSelectorChecker):
50578         (WebCore):
50579         (ContentSelectorDataList):
50580         (ContentSelectorQuery):
50581
50582 2012-10-11  Balazs Kelemen  <kbalazs@webkit.org>
50583
50584         [Qt] GraphicsContextPlatformPrivate is leaking it's ShadowBlur
50585         https://bugs.webkit.org/show_bug.cgi?id=99073
50586
50587         Reviewed by Noam Rosenthal.
50588
50589         Stop leaking GraphicsContextPlatformPrivate::shadow.
50590
50591         No change in behavior so no new tests.
50592
50593         * platform/graphics/qt/GraphicsContextQt.cpp:
50594         (WebCore::GraphicsContextPlatformPrivate::~GraphicsContextPlatformPrivate):
50595         Always destroy shadow. It is obviously owned by the context so it has
50596         nothing to do with the erly return.
50597
50598 2012-10-11  Joshua Bell  <jsbell@chromium.org>
50599
50600         WebIDL: overloaded methods prevent number -> string conversion
50601         https://bugs.webkit.org/show_bug.cgi?id=85326
50602
50603         Reviewed by Kentaro Hara.
50604
50605         Make the default behavior for overloaded methods matching DOMString arguments match the
50606         default behavior for non-overloaded methods, which more closely matches the WebIDL spec.
50607         Enable legacy behavior of only matching undefined/null/string/object(and not number,
50608         boolean, etc) via the StrictTypeChecking attribute.
50609
50610         Tests: storage/indexeddb/cursor-overloads.html
50611                storage/indexeddb/legacy-constants.html
50612                ... and run-bindings-tests
50613
50614         * Modules/indexeddb/IDBCursor.cpp:
50615         (WebCore::IDBCursor::stringToDirection): Handle "0"..."4" as stringified legacy constants.
50616         * Modules/indexeddb/IDBCursor.h:
50617         * Modules/indexeddb/IDBDatabase.cpp: Remove redundant overloads.
50618         (WebCore::IDBDatabase::transaction): Remove redundant overloads.
50619         * Modules/indexeddb/IDBDatabase.h:
50620         (IDBDatabase):
50621         * Modules/indexeddb/IDBDatabase.idl: Remove redundant overloads.
50622         * Modules/indexeddb/IDBIndex.cpp: Remove redundant overloads.
50623         (WebCore::IDBIndex::openCursor):
50624         (WebCore::IDBIndex::openKeyCursor):
50625         * Modules/indexeddb/IDBIndex.h: Remove redundant overloads.
50626         (IDBIndex):
50627         * Modules/indexeddb/IDBIndex.idl: Remove redundant overloads.
50628         * Modules/indexeddb/IDBObjectStore.cpp: Remove redundant overloads.
50629         (WebCore::IDBObjectStore::openCursor):
50630         * Modules/indexeddb/IDBObjectStore.h: Remove redundant overloads.
50631         (IDBObjectStore):
50632         * Modules/indexeddb/IDBObjectStore.idl: Remove redundant overloads.
50633         * Modules/indexeddb/IDBTransaction.cpp:
50634         (WebCore::IDBTransaction::stringToMode): Handle "0"..."4" as stringified legacy constants.
50635         * Modules/indexeddb/IDBTransaction.h:
50636         * bindings/scripts/CodeGeneratorJS.pm: Check for StrictTypeChecking attribute.
50637         (GenerateParametersCheckExpression):
50638         * bindings/scripts/CodeGeneratorV8.pm: Ditto.
50639         (GenerateParametersCheckExpression):
50640         * bindings/scripts/test/JS/JSTestObj.cpp: Rebaselined.
50641         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod11):
50642         (WebCore):
50643         (WebCore::jsTestObjPrototypeFunctionOverloadedMethod):
50644         * bindings/scripts/test/TestObj.idl: Added [StrictTypeChecking] to DOMString overloads,
50645         plus a new DOMString overload w/o it.
50646         * bindings/scripts/test/V8/V8TestObj.cpp: Rebaselined.
50647         (WebCore::TestObjV8Internal::overloadedMethod11Callback):
50648         (TestObjV8Internal):
50649         (WebCore::TestObjV8Internal::overloadedMethodCallback):
50650         * html/canvas/CanvasRenderingContext2D.idl: Tag legacy overloads with [StrictTypeChecking].
50651         * xml/XMLHttpRequest.idl: Ditto.
50652
50653 2012-10-11  Justin Novosad  <junov@chromium.org>
50654
50655         [Chromium][Mac] r130994 seems to break chromium gpu test
50656         https://bugs.webkit.org/show_bug.cgi?id=98995
50657
50658         Reviewed by Stephen White.
50659
50660         Removing unnecessary assertion that was based on an invalid assumption
50661         that 2d canvas draw operations were always called from within WebThread
50662         tasks.
50663
50664         Test: Canvas2DAllowed chromium gpu_test
50665
50666         * platform/graphics/chromium/Canvas2DLayerManager.cpp:
50667         (WebCore::Canvas2DLayerManager::willProcessTask):
50668
50669 2012-10-11  Kenichi Ishibashi <bashi@chromium.org>
50670
50671         REGRESSION(130231): Causes 3 complex font test failures on EFL / Harfbuzz+Freetype
50672         https://bugs.webkit.org/show_bug.cgi?id=98247
50673
50674         Reviewed by Kenneth Rohde Christiansen.
50675
50676         Implement canRenderCombiningCharacterSequence() for the Freetype case.
50677
50678         No new tests, covered by existing tests. Actually the lack of the implementation made
50679         fast/text/atsui-multiple-renderers.html,  fast/text/atsui-spacing-features.html and
50680         fast/text/wide-zero-width-space.html fail on EFL.
50681
50682         * platform/graphics/freetype/SimpleFontDataFreeType.cpp: Implement canRenderCombiningCharacterSequence().
50683         (WebCore::SimpleFontData::canRenderCombiningCharacterSequence):
50684
50685 2012-10-11  Keishi Hattori  <keishi@webkit.org>
50686
50687         F4 key should open the picker popup on Windows and Linux
50688         https://bugs.webkit.org/show_bug.cgi?id=98754
50689
50690         Reviewed by Kent Tamura.
50691
50692         On Windows, F4 key is used to open the combo box popup. We will introduce the same keybinding for picker popups.
50693
50694         Added test to calendar-picker-key-operations.html, date-suggestion-picker-key-operations.html, time-suggestion-picker-key-operations.html.
50695
50696         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
50697         (WebCore::BaseMultipleFieldsDateAndTimeInputType::handleKeydownEvent): Open picker on F4 key if it is enabled.
50698         * rendering/RenderTheme.cpp:
50699         (WebCore::RenderTheme::shouldOpenPickerWithF4Key): Returns true if we want to enable the F4 key binding on this platform. Return false for default.
50700         (WebCore):
50701         * rendering/RenderTheme.h:
50702         (RenderTheme):
50703         * rendering/RenderThemeChromiumLinux.cpp:
50704         (WebCore::RenderThemeChromiumLinux::shouldOpenPickerWithF4Key): Returns true.
50705         (WebCore):
50706         * rendering/RenderThemeChromiumLinux.h:
50707         * rendering/RenderThemeChromiumWin.cpp:
50708         (WebCore):
50709         (WebCore::RenderThemeChromiumWin::shouldOpenPickerWithF4Key): Returns true.
50710         * rendering/RenderThemeChromiumWin.h:
50711         (RenderThemeChromiumWin):
50712
50713 2012-10-11  John J. Barton  <johnjbarton@chromium.org>
50714
50715         Web Inspector: Zebra stripe the console
50716         https://bugs.webkit.org/show_bug.cgi?id=98701
50717
50718         Reviewed by Pavel Feldman.
50719
50720         Add .console-message:hover rule to lightly highlight the message line.
50721
50722         * inspector/front-end/inspector.css:
50723         (.console-message:hover):
50724
50725 2012-10-11  Vsevolod Vlasov  <vsevik@chromium.org>
50726
50727         Web Inspector: Filter out embedder injected content scripts
50728         https://bugs.webkit.org/show_bug.cgi?id=99039
50729
50730         Reviewed by Yury Semikhatsky.
50731
50732         * inspector/front-end/NetworkUISourceCodeProvider.js:
50733         (WebInspector.NetworkUISourceCodeProvider.prototype._parsedScriptSource):
50734
50735 2012-10-11  Pavel Feldman  <pfeldman@chromium.org>
50736
50737         Not reviewed: revert 131004, 131012, 131016, 131042, 131043 for breaking inspector console
50738         https://bugs.webkit.org/show_bug.cgi?id=99042
50739
50740         One can't type in the inspector console after 131004.
50741
50742         * CMakeLists.txt:
50743         * GNUmakefile.list.am:
50744         * Target.pri:
50745         * WebCore.gypi:
50746         * WebCore.vcproj/WebCore.vcproj:
50747         * WebCore.xcodeproj/project.pbxproj:
50748         * dom/DOMAllInOne.cpp:
50749         * dom/Element.cpp:
50750         (WebCore::Element::attach):
50751         (WebCore::Element::detach):
50752         (WebCore::Element::recalcStyle):
50753         * dom/Element.h:
50754         (WebCore):
50755         (Element):
50756         * dom/ElementRareData.h:
50757         (ElementRareData):
50758         * dom/Node.cpp:
50759         (WebCore::checkAcceptChild):
50760         * dom/Node.h:
50761         (Node):
50762         * dom/NodeRenderingContext.cpp:
50763         (WebCore::NodeRenderingContext::nextRenderer):
50764         * dom/PseudoElement.cpp: Removed.
50765         * dom/PseudoElement.h: Removed.
50766         * rendering/HitTestResult.cpp:
50767         (WebCore::HitTestResult::setInnerNode):
50768         (WebCore::HitTestResult::setInnerNonSharedNode):
50769         * rendering/RenderBlock.cpp:
50770         (WebCore::RenderBlock::styleDidChange):
50771         (WebCore::RenderBlock::updateBeforeAfterContent):
50772         (WebCore):
50773         (WebCore::RenderBlock::splitBlocks):
50774         (WebCore::RenderBlock::addChildIgnoringAnonymousColumnBlocks):
50775         (WebCore::RenderBlock::createReplacementRunIn):
50776         (WebCore::RenderBlock::renderName):
50777         * rendering/RenderBlock.h:
50778         (RenderBlock):
50779         * rendering/RenderButton.cpp:
50780         (WebCore::RenderButton::updateBeforeAfterContent):
50781         (WebCore):
50782         * rendering/RenderButton.h:
50783         (RenderButton):
50784         * rendering/RenderCounter.cpp:
50785         (WebCore::RenderCounter::originalText):
50786         * rendering/RenderDeprecatedFlexibleBox.cpp:
50787         (WebCore::RenderDeprecatedFlexibleBox::renderName):
50788         * rendering/RenderGrid.cpp:
50789         (WebCore::RenderGrid::renderName):
50790         * rendering/RenderInline.cpp:
50791         (WebCore::RenderInline::styleDidChange):
50792         (WebCore::RenderInline::addChildIgnoringContinuation):
50793         (WebCore::RenderInline::splitInlines):
50794         (WebCore::RenderInline::renderName):
50795         * rendering/RenderListItem.cpp:
50796         (WebCore::RenderListItem::updateMarkerLocation):
50797         * rendering/RenderMultiColumnBlock.cpp:
50798         (WebCore::RenderMultiColumnBlock::renderName):
50799         * rendering/RenderObject.cpp:
50800         (WebCore::RenderObject::createObject):
50801         * rendering/RenderObject.h:
50802         (WebCore::RenderObject::generatingNode):
50803         * rendering/RenderObjectChildList.cpp:
50804         (WebCore):
50805         (WebCore::findBeforeAfterParent):
50806         (WebCore::RenderObjectChildList::updateBeforeAfterStyle):
50807         (WebCore::createRendererForBeforeAfterContent):
50808         (WebCore::ensureBeforeAfterContainer):
50809         (WebCore::RenderObjectChildList::updateBeforeAfterContent):
50810         * rendering/RenderObjectChildList.h:
50811         (RenderObjectChildList):
50812         * rendering/RenderRubyText.cpp:
50813         (WebCore::RenderRubyText::updateBeforeAfterContent):
50814         (WebCore):
50815         * rendering/RenderRubyText.h:
50816         (RenderRubyText):
50817         * rendering/RenderTableCell.h:
50818         (WebCore::RenderTableCell::renderName):
50819         * rendering/RenderTableRow.cpp:
50820         (WebCore::RenderTableRow::updateBeforeAndAfterContent):
50821         (WebCore):
50822         (WebCore::RenderTableRow::styleDidChange):
50823         * rendering/RenderTableRow.h:
50824         (RenderTableRow):
50825         (WebCore::RenderTableRow::renderName):
50826         * rendering/RenderTableSection.cpp:
50827         (WebCore::RenderTableSection::addChild):
50828         * rendering/RenderTableSection.h:
50829         (WebCore::RenderTableSection::renderName):
50830         * rendering/RenderTreeAsText.cpp:
50831         (WebCore::RenderTreeAsText::writeRenderObject):
50832
50833 2012-10-11  Arpita Bahuguna  <arpitabahuguna@gmail.com>
50834
50835         REGRESSION (r96393): In some cases, generated content is never shown
50836         https://bugs.webkit.org/show_bug.cgi?id=88196
50837
50838         Reviewed by Antti Koivisto.
50839
50840         Elements with style specified from an attribute selector in conjunction
50841         with a pseudo-element should not take on the shared style of their
50842         previous matching sibling (if any).
50843
50844         The problem here is that an attribute selector appended by a pseudo-element
50845         does not return any matched rules for the call (matchesRuleSet(m_uncommonAttributeRuleSet.get()))
50846         in StyleResolver::locateSharedStyle().
50847
50848         This is because of the way pseudo-elements are handled in
50849         SelectorChecker::checkSelector(). For a pseudo-element selector we check
50850         for the condition (!context.elementStyle && m_mode == ResolvingStyle) and
50851         since for this particular flow the SelectorChecker mode is set to ResolvingStyle
50852         and since the current element's style is still not available we fail this
50853         initial check and return SelectorFailsLocally from checkSelector(). This is
50854         incorrect behavior since the element does have an attribute selector specified
50855         for it.
50856
50857         Have thus introduced another enum value: SharingRules for SelectorChecker's Mode.
50858         SelectorChecker's mode should be set to SharingRules before making the
50859         call to collectMatchingRules() and then reset (back to ResolvingStyle) thereafter.
50860
50861         Existing Mode value: CollectingRules although appropriate cannot be used in this
50862         scenario because we also don't want to set any value to dynamicPseudo for this flow.
50863
50864         Test: fast/selectors/style-sharing-attribute-selector-with-pseudo-element.html
50865
50866         * css/SelectorChecker.cpp:
50867         (WebCore::SelectorChecker::checkSelector):
50868         Added additional check for SelectorChecker's mode: SharingRules when
50869         trying to match for the pseudo-element selector.
50870
50871         * css/SelectorChecker.h:
50872         Added SharingRules to Mode enum.
50873
50874         * css/StyleResolver.cpp:
50875         (WebCore::StyleResolver::styleSharingCandidateMatchesRuleSet):
50876         (WebCore::StyleResolver::locateSharedStyle):
50877         * css/StyleResolver.h:
50878         (StyleResolver):
50879         Renamed matchesRuleSet() to a more descriptive styleSharingCandidateMatchesRuleSet().
50880         Also, setting the SelectorChecker's mode to SharingRules before calling
50881         on collectMatchingRules() from styleSharingCandidateMatchesRuleSet().
50882
50883 2012-10-11  Shinya Kawanaka  <shinyak@chromium.org>
50884
50885         Some shadow roots are not showing up in Inspector.
50886         https://bugs.webkit.org/show_bug.cgi?id=88251
50887
50888         Reviewed by Pavel Feldman.
50889
50890         When an element has only text node, its shadow root is not showing up in Inspector, since
50891         child text is shown in oneline. We had to prevent from inlining child text when a shadow root is
50892         added.
50893
50894         Test: inspector/elements/shadow-root.html
50895
50896         * inspector/front-end/DOMAgent.js:
50897         (WebInspector.DOMNode):
50898         (WebInspector.DOMNode.prototype.hasShadowRoots):
50899         * inspector/front-end/ElementsTreeOutline.js:
50900
50901 2012-10-11  Allan Sandfeld Jensen  <allan.jensen@digia.com>
50902
50903         [Qt] More responsive scroll animations
50904         https://bugs.webkit.org/show_bug.cgi?id=99016
50905
50906         Reviewed by Jocelyn Turcotte.
50907
50908         Changes the scrolling animations so they accelerate faster than they deccelerate,
50909         making the animation respond faster to user input.
50910
50911         * platform/ScrollAnimatorNone.cpp:
50912         (WebCore::ScrollAnimatorNone::parametersForScrollGranularity):
50913         * platform/ScrollAnimatorNone.h:
50914         (ScrollAnimatorNone):
50915
50916 2012-10-11  Alexander Shalamov  <alexander.shalamov@intel.com>
50917
50918         [CSS3 Media Queries] Aspect ratio value re-parsed when media query expression is evaluated
50919         https://bugs.webkit.org/show_bug.cgi?id=99003
50920
50921         Reviewed by Kenneth Rohde Christiansen.
50922
50923         Use CSSAspectRatioValue instead of CSSValueList to store aspect ratio value
50924         in order to avoid re-parsing of aspect ratio data during media expression evaluation.
50925
50926         test: fast/media/w3c/test_media_queries.html
50927
50928         * css/MediaQueryEvaluator.cpp:
50929         (WebCore::compareAspectRatioValue):
50930         (WebCore):
50931         (WebCore::aspect_ratioMediaFeatureEval):
50932         (WebCore::device_aspect_ratioMediaFeatureEval):
50933         * css/MediaQueryExp.cpp:
50934         (WebCore::MediaQueryExp::MediaQueryExp):
50935
50936 2012-10-11  Zeno Albisser  <zeno@webkit.org>
50937
50938         [Qt] Implement GraphicsSurfaceToken to replace uint64_t as token type.
50939         https://bugs.webkit.org/show_bug.cgi?id=98501
50940
50941         Replace the token type for GraphicsSurface with a new class GraphicsSurfaceToken.
50942         This is necessary in order to implement GraphicsSurface for Windows.
50943         Depending on the platform a GraphicsSurfaceToken might contain a
50944         WindowID (Linux/GLX), two IOSurfaceIDs (Mac) or in the future two HANDLEs (Windows).
50945         The simple uint64_t is not sufficient anymore, since a single HANDLE in windows
50946         can be 64bit already.
50947
50948         Reviewed by Noam Rosenthal.
50949
50950         * Target.pri:
50951         * platform/graphics/qt/GraphicsContext3DQt.cpp:
50952         (GraphicsContext3DPrivate):
50953         (WebCore::GraphicsContext3DPrivate::graphicsSurfaceToken):
50954         * platform/graphics/surfaces/GraphicsSurface.cpp:
50955         (WebCore::GraphicsSurface::create):
50956         (WebCore::GraphicsSurface::exportToken):
50957         * platform/graphics/surfaces/GraphicsSurface.h:
50958         (GraphicsSurface):
50959         * platform/graphics/surfaces/GraphicsSurfaceToken.h: Added.
50960         (WebCore):
50961         (GraphicsSurfaceToken):
50962         (WebCore::GraphicsSurfaceToken::GraphicsSurfaceToken):
50963         (WebCore::GraphicsSurfaceToken::operator!=):
50964         (WebCore::GraphicsSurfaceToken::isValid):
50965         * platform/graphics/surfaces/mac/GraphicsSurfaceMac.cpp:
50966         (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
50967         (WebCore::GraphicsSurfacePrivate::token):
50968         (GraphicsSurfacePrivate):
50969         (WebCore::GraphicsSurface::platformExport):
50970         (WebCore::GraphicsSurface::platformImport):
50971         * platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:
50972         (WebCore::GraphicsSurface::platformExport):
50973         (WebCore::GraphicsSurface::platformImport):
50974         * platform/graphics/texmap/TextureMapperBackingStore.cpp:
50975         (WebCore::TextureMapperSurfaceBackingStore::setGraphicsSurface):
50976         (WebCore::TextureMapperSurfaceBackingStore::setSurface):
50977         * platform/graphics/texmap/TextureMapperBackingStore.h:
50978         (TextureMapperSurfaceBackingStore):
50979         (WebCore::TextureMapperSurfaceBackingStore::TextureMapperSurfaceBackingStore):
50980         * platform/graphics/texmap/TextureMapperPlatformLayer.h:
50981         (WebCore::TextureMapperPlatformLayer::graphicsSurfaceToken):
50982
50983 2012-10-11  Alexander Pavlov  <apavlov@chromium.org>
50984
50985         Web Inspector: [Elements] Breadcrumbs are not updated upon involved elements' className changes
50986         https://bugs.webkit.org/show_bug.cgi?id=98887
50987
50988         Reviewed by Vsevolod Vlasov.
50989
50990         Breadcrumbs should be updated upon the "class" and "id" attribute changes of elements participating in the breadcrumb path.
50991
50992         Test: inspector/elements/breadcrumb-updates.html
50993
50994         * inspector/front-end/ElementsPanel.js:
50995         (WebInspector.ElementsPanel):
50996         (WebInspector.ElementsPanel.prototype._updateBreadcrumbIfNeeded):
50997
50998 2012-10-11  Kunihiko Sakamoto  <ksakamoto@chromium.org>
50999
51000         Final newline (LF or CRLF) in paste buffer is converted to space
51001         https://bugs.webkit.org/show_bug.cgi?id=80838
51002
51003         Reviewed by Ryosuke Niwa.
51004
51005         Currently newline characters are replaced with spaces when pasted
51006         to text input. This behavior was introduced in r37539, with the
51007         intention to follow the FireFox's behavior (see
51008         https://bugs.webkit.org/show_bug.cgi?id=20461). However, FireFox
51009         truncates newlines at the end of pasted text, instead of replacing
51010         them with spaces. So this patch changes TextFieldInputType to cut
51011         trailing newlines of inserted text.
51012
51013         Test: fast/forms/paste-multiline-text-input.html
51014
51015         * html/TextFieldInputType.cpp:
51016         (WebCore::TextFieldInputType::handleBeforeTextInsertedEvent):
51017         Truncates trailing newlines.
51018
51019 2012-10-11  Kent Tamura  <tkent@chromium.org>
51020
51021         Introduce Localizer::isRTL, and use it in DateTimeChooserImpl
51022         https://bugs.webkit.org/show_bug.cgi?id=98992
51023
51024         * platform/text/LocaleICU.cpp:
51025         (WebCore::LocaleICU::isRTL): Need to initialize 'status'.
51026
51027 2012-10-11  Eugene Klyuchnikov  <eustas.bug@gmail.com>
51028
51029         Web Inspector: The 'X' of the close button of Settings view is not centered
51030         https://bugs.webkit.org/show_bug.cgi?id=99008
51031
51032         Reviewed by Alexander Pavlov.
51033
51034         Fixed text positioning in CSS.
51035
51036         * inspector/front-end/helpScreen.css:
51037         (.help-close-button):
51038
51039 2012-10-11  Kent Tamura  <tkent@chromium.org>
51040
51041         Introduce Localizer::isRTL, and use it in DateTimeChooserImpl
51042         https://bugs.webkit.org/show_bug.cgi?id=98992
51043
51044         Reviewed by Kentaro Hara.
51045
51046         - Move the RTL detection code in
51047           WebKit/chromium/src/DateTimeChooserImpl.cpp to LocaleWin::isRTL()
51048         - Introduce Localizer::isRTL as a pure virtual function
51049         - Implement LocaleMac::isRTL with native API
51050         - Implement LocaleICU::isRTL with ICU API
51051         - Add dummy implementation: LocaleNone::isRTL
51052
51053         Add some tests to WebKit/chromium/tests/.
51054
51055         * platform/text/Localizer.h:
51056         (Localizer): Declare pure virtual isRTL.
51057
51058         * platform/text/LocaleICU.h:
51059         (LocaleICU): Declare isRTL.
51060         * platform/text/LocaleICU.cpp:
51061         (WebCore::LocaleICU::isRTL): Implemented with uloc_getCharacterOrientation.
51062
51063         * platform/text/LocaleNone.cpp:
51064         (LocaleNone): Declare isRTL.
51065         (WebCore::LocaleNone::isRTL): Added.
51066
51067         * platform/text/LocaleWin.h:
51068         (LocaleWin): Declare isRTL.
51069         * platform/text/LocaleWin.cpp:
51070         (WebCore::LocaleWin::isRTL): Implemented.
51071
51072         * platform/text/mac/LocaleMac.h:
51073         (LocaleMac): Declare isRTL.
51074         * platform/text/mac/LocaleMac.mm:
51075         (WebCore::LocaleMac::isRTL): Implemented.
51076
51077 2012-10-11  Vsevolod Vlasov  <vsevik@chromium.org>
51078
51079         Web Inspector: TypeError in ConsoleMessage.js
51080         https://bugs.webkit.org/show_bug.cgi?id=98999
51081
51082         Reviewed by Alexander Pavlov.
51083
51084         This patch is based on patch by John J. Barton.
51085         Added a check that stack length is equal.
51086
51087         * inspector/front-end/ConsoleMessage.js:
51088         (WebInspector.ConsoleMessageImpl.prototype.isEqual):
51089
51090 2012-10-10  Jer Noble  <jer.noble@apple.com>
51091
51092         Disallow full screen mode keyboard access by default.
51093         https://bugs.webkit.org/show_bug.cgi?id=98971
51094         <rdar://problem/12474226>
51095
51096         Reviewed by Sam Weinig.
51097
51098         Fall back to requesting non-keyboard access if the client refuses to allow keyboard access.
51099
51100         * dom/Document.cpp:
51101         (WebCore::Document::requestFullScreenForElement):
51102
51103 2012-10-10  Ilya Tikhonovsky  <loislo@chromium.org>
51104
51105         Web Inspector: NMI instrument HTMLCanvas element.
51106         https://bugs.webkit.org/show_bug.cgi?id=98917
51107
51108         Reviewed by Yury Semikhatsky.
51109
51110         It also includes non intrusive instrumentation for skia classes.
51111
51112         Test: inspector/profiler/memory-instrumentation-canvas.html
51113
51114         * WebCore.gypi:
51115         * html/HTMLCanvasElement.cpp:
51116         (WebCore::HTMLCanvasElement::reportMemoryUsage):
51117         (WebCore):
51118         * html/HTMLCanvasElement.h:
51119         (HTMLCanvasElement):
51120         * platform/graphics/ImageBuffer.cpp:
51121         (WebCore::ImageBuffer::reportMemoryUsage):
51122         (WebCore):
51123         * platform/graphics/ImageBuffer.h:
51124         (ImageBuffer):
51125         * platform/graphics/chromium/ImageBufferDataSkia.h:
51126         (ImageBufferData):
51127         * platform/graphics/skia/ImageBufferSkia.cpp:
51128         (WebCore::ImageBufferData::reportMemoryUsage):
51129         (WebCore):
51130         * platform/graphics/skia/MemoryInstrumentationSkia.cpp: Copied from Source/WebCore/platform/graphics/chromium/ImageBufferDataSkia.h.
51131         (reportMemoryUsage):
51132         * platform/graphics/skia/MemoryInstrumentationSkia.h: Copied from Source/WebCore/platform/graphics/chromium/ImageBufferDataSkia.h.
51133         * platform/graphics/skia/NativeImageSkia.cpp:
51134
51135 2012-10-10  Mike West  <mkwst@google.com>
51136
51137         Document calls createElement with the wrong parameters.
51138         https://bugs.webkit.org/show_bug.cgi?id=98907
51139
51140         Reviewed by Kent Tamura.
51141
51142         Document::importNode calls Document::createElement with a QualifiedName
51143         and ExceptionCode. The Document::createElement that takes a
51144         QualifiedName doesn't generate an exception; the second argument is a
51145         bool, which the ExceptionCode autocasts into.
51146
51147         Changing the argument to an explicit bool shouldn't have any visible
51148         effect; no new tests are required.
51149
51150         * dom/Document.cpp:
51151         (WebCore::Document::importNode):
51152
51153 2012-10-10  Lianghui Chen  <liachen@rim.com>
51154
51155         [BlackBerry] Fix assertion in NetworkJob::notifyChallengeResult.
51156         https://bugs.webkit.org/show_bug.cgi?id=97397
51157         Internal PR: 186597.
51158
51159         Internally reviewed by Yong Li, Joe Mason.
51160         Reviewed by George Staikos.
51161
51162         Add a singleton AuthenticationChallengeManager to manage authentication
51163         challenge dialog. It does following things:
51164         Record page creation/deletion, so it knows what page is present or not.
51165         Record page visibility change so it knows when to display a dialog or not.
51166         Accept authentication challenge, and decide whether to postpone the
51167             challenge dialog based on whether there is active authentication challenge
51168             dialog already and whether its page is visible or not.
51169         When a challenge result comes back, notify the result to all clients
51170             authenticating for the same protection space, and then start the next
51171             authentication challenge from the same page, if there is one.
51172         When a page becomes visible, start the first authentication challenge
51173             dialog that has been blocked before.
51174         When an authentication challenge is requested, the NetworkJob will be
51175             deferred so its initial response will be saved while waiting for
51176             user decision on the challenge.
51177
51178         No new tests for platform specific internal change.
51179
51180         * PlatformBlackBerry.cmake:
51181         * platform/blackberry/AuthenticationChallengeManager.cpp: Added.
51182         (WebCore):
51183         (ChallengeInfo):
51184         (WebCore::ChallengeInfo::ChallengeInfo):
51185         (AuthenticationChallengeManagerPrivate):
51186         (WebCore::AuthenticationChallengeManagerPrivate::AuthenticationChallengeManagerPrivate):
51187         (WebCore::AuthenticationChallengeManagerPrivate::resumeAuthenticationChallenge):
51188         (WebCore::AuthenticationChallengeManagerPrivate::startAuthenticationChallenge):
51189         (WebCore::AuthenticationChallengeManagerPrivate::pageExists):
51190         (WebCore::AuthenticationChallengeManager::AuthenticationChallengeManager):
51191         (WebCore::AuthenticationChallengeManager::pageCreated):
51192         (WebCore::AuthenticationChallengeManager::pageDeleted):
51193         (WebCore::AuthenticationChallengeManager::pageVisibilityChanged):
51194         (WebCore::AuthenticationChallengeManager::authenticationChallenge):
51195         (WebCore::AuthenticationChallengeManager::cancelAuthenticationChallenge):
51196         (WebCore::AuthenticationChallengeManager::notifyChallengeResult):
51197         (WebCore::AuthenticationChallengeManager::instance):
51198         (WebCore::AuthenticationChallengeManager::init):
51199         * platform/blackberry/AuthenticationChallengeManager.h:
51200         (WebCore):
51201         (AuthenticationChallengeManager):
51202         * platform/blackberry/PageClientBlackBerry.h:
51203         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp:
51204         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
51205         (WebCore::MediaPlayerPrivate::~MediaPlayerPrivate):
51206         (WebCore::MediaPlayerPrivate::onAuthenticationNeeded):
51207         (WebCore::MediaPlayerPrivate::notifyChallengeResult):
51208         * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.h:
51209         (MediaPlayerPrivate):
51210         * platform/network/blackberry/NetworkJob.cpp:
51211         (WebCore::NetworkJob::NetworkJob):
51212         (WebCore::NetworkJob::~NetworkJob):
51213         (WebCore):
51214         (WebCore::NetworkJob::handleNotifyStatusReceived):
51215         (WebCore::NetworkJob::handleNotifyClose):
51216         (WebCore::NetworkJob::shouldReleaseClientResource):
51217         (WebCore::NetworkJob::sendRequestWithCredentials):
51218         (WebCore::NetworkJob::notifyChallengeResult):
51219         * platform/network/blackberry/NetworkJob.h:
51220         (NetworkJob):
51221
51222 2012-10-10  Simon Fraser  <simon.fraser@apple.com>
51223
51224         compositing/tiling/crash-reparent-tiled-layer.html is flakey
51225         https://bugs.webkit.org/show_bug.cgi?id=82546
51226
51227         Reviewed by Beth Dakin.
51228
51229         When calling layerTreeAsText() inside the document load event,
51230         GraphicsLayerCA may have not flushed layers yet, so layer tree
51231         properties that are affected by flushing (tiled layer, visible
51232         rects) appeared flakey in tests.
51233         
51234         Fix by forcing a flush before dumping the layer tree.        
51235         
51236         * rendering/RenderLayerCompositor.cpp:
51237         (WebCore::RenderLayerCompositor::layerTreeAsText):
51238
51239 2012-10-10  Beth Dakin  <bdakin@apple.com>
51240
51241         https://bugs.webkit.org/show_bug.cgi?id=98984
51242         REGRESSION: Crash happens after we add non-top-level frame to the 
51243         ScrollingStateTree
51244
51245         Reviewed by Simon Fraser.
51246
51247         isRootLayer() can return true for layers that do not correspond to 
51248         the main frame. But we only want the ones that DO correspond to the 
51249         main frame!
51250         * rendering/RenderLayerCompositor.cpp:
51251         (WebCore::RenderLayerCompositor::updateBacking):
51252
51253 2012-10-10  Dan Bernstein  <mitz@apple.com>
51254
51255         <rdar://problem/12472460> text-combine doesn’t use third- and quarter-width variants when used with @font-face
51256         https://bugs.webkit.org/show_bug.cgi?id=98961
51257
51258         Reviewed by Tim Horton.
51259
51260         Test: fast/text/text-combine-with-font-face.html
51261
51262         * css/CSSSegmentedFontFace.cpp:
51263         (WebCore::CSSSegmentedFontFace::getFontData): Added the width variant to the
51264         key used for entries in the font data table, so that we can return different
51265         font data for different width variants.
51266         * platform/graphics/FontWidthVariant.h: Defined FontWidthVariantWidth for
51267         use in the computation of the above key.
51268         * rendering/RenderCombineText.cpp:
51269         (WebCore::RenderCombineText::combineText): Added a local variable to store
51270         the font selector before changing the font description. Previously, by the time
51271         we tried to get the font selector from the font, it had already been cleared,
51272         so we called Font::update() with a 0 font selector, meaning @font-face fonts
51273         could not be selected.
51274
51275 2012-10-10  Elliott Sprehn  <esprehn@chromium.org>
51276
51277         Move :before and :after into the DOM        
51278         https://bugs.webkit.org/show_bug.cgi?id=95117
51279
51280         Reviewed by Eric Seidel.
51281
51282         Reimplement generated content :before and :after as DOM Elements. Now ElementRareData has
51283         two RefPtrs to PseudoElements for the generated content and Node has methods for traversing
51284         the tree including generated content.
51285
51286         This allows the generated content to be treated as real nodes instead of anonymous and take
51287         part in the usual recalcStyle and attach flow which fixes many bugs and vastly simplifies the
51288         lifecycle of generated content.
51289
51290         No new tests needed for now.
51291
51292         * CMakeLists.txt:
51293         * GNUmakefile.list.am:
51294         * Target.pri:
51295         * WebCore.gypi:
51296         * WebCore.vcproj/WebCore.vcproj:
51297         * WebCore.xcodeproj/project.pbxproj:
51298         * dom/DOMAllInOne.cpp:
51299         * dom/Element.cpp:
51300         (WebCore::Element::attach): Add generated content if needed.
51301         (WebCore::Element::detach): Remove all child generated content.
51302         (WebCore::Element::recalcStyle): Add or remove generated content based on the new style.
51303         (WebCore::Element::updatePseudoElement): Updates pseudo content based on a pseudoId.
51304         (WebCore):
51305         (WebCore::Element::createPseudoElementIfNeeded):
51306         (WebCore::Element::beforePseudoElement):
51307         (WebCore::Element::afterPseudoElement):
51308         * dom/Element.h:
51309         (WebCore):
51310         (Element):
51311         * dom/ElementRareData.h:
51312         (ElementRareData):
51313         (WebCore::ElementRareData::setPseudoElement):
51314         (WebCore):
51315         (WebCore::ElementRareData::pseudoElement):
51316         * dom/Node.cpp:
51317         (WebCore::Node::pseudoAwarePreviousSibling):
51318         (WebCore):
51319         (WebCore::Node::pseudoAwareNextSibling):
51320         (WebCore::checkAcceptChild): Forbid moving PseudoElements for sanity. The code never does this.
51321         * dom/Node.h:
51322         (Node):
51323         (WebCore::Node::isPseudoElement):
51324         (WebCore::Node::pseudoId): Fast path that only calls virtualPseudoId if the node has custom callbacks so isPseudoElement is fast.
51325         (WebCore::Node::virtualPseudoId):
51326         (WebCore::Node::isBeforePseudoElement):
51327         (WebCore::Node::isAfterPseudoElement):
51328         * dom/NodeRenderingContext.cpp:
51329         (WebCore::NodeRenderingContext::nextRenderer): Changed to find the next sibling of pseudos for insertion.
51330         * dom/PseudoElement.cpp: Added.
51331         (WebCore):
51332         (WebCore::pseudoElementName):
51333         (WebCore::PseudoElement::PseudoElement):
51334         (WebCore::PseudoElement::pseudoRendererIsNeeded):
51335         (WebCore::PseudoElement::customStyleForRenderer):
51336         (WebCore::PseudoElement::attach):
51337         (WebCore::PseudoElement::rendererIsNeeded):
51338         (WebCore::PseudoElement::updateChildStyle): Propagates the style downward into the anonymous renderers for the content.
51339         (WebCore::PseudoElement::didRecalcStyle):
51340         (WebCore::PseudoElement::createRendererForContent): Refactored from RenderObjectChildList.
51341         * dom/PseudoElement.h: Added.
51342         (WebCore):
51343         (PseudoElement):
51344         (WebCore::PseudoElement::create):
51345         (WebCore::toPseudoElement):
51346         * rendering/HitTestResult.cpp:
51347         (WebCore::HitTestResult::setInnerNode): Hit testing a PseudoElement should really hit the parent.
51348         (WebCore::HitTestResult::setInnerNonSharedNode): Same as above.
51349         * rendering/RenderBlock.cpp:
51350         (WebCore::RenderBlock::styleDidChange): Remove old generated content code, same for below.
51351         (WebCore::RenderBlock::splitBlocks):
51352         (WebCore::RenderBlock::addChildIgnoringAnonymousColumnBlocks):
51353         (WebCore::RenderBlock::createReplacementRunIn):
51354         (WebCore::RenderBlock::renderName):
51355         * rendering/RenderBlock.h:
51356         (RenderBlock):
51357         * rendering/RenderButton.cpp:
51358         * rendering/RenderButton.h:
51359         (RenderButton):
51360         * rendering/RenderCounter.cpp:
51361         (WebCore::RenderCounter::originalText):
51362         * rendering/RenderDeprecatedFlexibleBox.cpp:
51363         (WebCore::RenderDeprecatedFlexibleBox::renderName):
51364         * rendering/RenderGrid.cpp:
51365         (WebCore::RenderGrid::renderName):
51366         * rendering/RenderInline.cpp:
51367         (WebCore::RenderInline::styleDidChange):
51368         (WebCore::RenderInline::addChildIgnoringContinuation):
51369         (WebCore::RenderInline::splitInlines):
51370         (WebCore::RenderInline::renderName):
51371         * rendering/RenderListItem.cpp:
51372         (WebCore::RenderListItem::updateMarkerLocation):
51373         * rendering/RenderMultiColumnBlock.cpp:
51374         (WebCore::RenderMultiColumnBlock::renderName):
51375         * rendering/RenderObject.cpp:
51376         (WebCore::RenderObject::createObject):
51377         * rendering/RenderObject.h:
51378         (WebCore::RenderObject::isPseudoElement):
51379         (RenderObject):
51380         (WebCore::RenderObject::generatingNode):
51381         * rendering/RenderObjectChildList.cpp:
51382         * rendering/RenderObjectChildList.h:
51383         (RenderObjectChildList):
51384         * rendering/RenderRubyText.cpp:
51385         * rendering/RenderRubyText.h:
51386         (RenderRubyText):
51387         * rendering/RenderTableCell.h:
51388         (WebCore::RenderTableCell::renderName):
51389         * rendering/RenderTableRow.cpp:
51390         (WebCore::RenderTableRow::styleDidChange):
51391         * rendering/RenderTableRow.h:
51392         (WebCore::RenderTableRow::renderName):
51393         * rendering/RenderTableSection.cpp:
51394         (WebCore::RenderTableSection::addChild):
51395         * rendering/RenderTableSection.h:
51396         (WebCore::RenderTableSection::renderName):
51397         * rendering/RenderTreeAsText.cpp:
51398         (WebCore::RenderTreeAsText::writeRenderObject):
51399
51400 2012-10-10  Sam Weinig  <sam@webkit.org>
51401
51402         Add more Objective-C WebKit2 DOM API skeletons.
51403         https://bugs.webkit.org/show_bug.cgi?id=98981
51404
51405         Reviewed by Anders Carlsson.
51406
51407         * WebCore.exp.in:
51408         Add necessary export.
51409
51410 2012-10-10  Dimitri Glazkov  <dglazkov@chromium.org>
51411
51412         Minimize the recent template explosion in SelectorChecker.
51413         https://bugs.webkit.org/show_bug.cgi?id=98829
51414
51415         Reviewed by Antti Koivisto.
51416
51417         We've recently added the capability to switch sibling traversal strategy to SelectorChecker, at some readability/clarity expense.
51418         This patch tries to minimize the surface of this expense to SelectorChecker::checkOneSelector. 
51419
51420         No new tests, no change in behavior.
51421
51422         * css/SelectorChecker.cpp:
51423         (WebCore::SelectorChecker::checkSelector): Turned back into a function.
51424         (WebCore::SelectorChecker::checkOneSelector): Changed to specialize on traversal strategy, rather than the context, which was less clear.
51425         (WebCore::SelectorChecker::DOMTraversalStrategy::isFirstChild): Turned into a function.
51426         (WebCore::SelectorChecker::DOMTraversalStrategy::isLastChild): Ditto.
51427         (WebCore::SelectorChecker::DOMTraversalStrategy::isFirstOfType): Ditto.
51428         (WebCore::SelectorChecker::DOMTraversalStrategy::isLastOfType): Ditto.
51429         (WebCore::SelectorChecker::DOMTraversalStrategy::countElementsBefore): Ditto.
51430         (WebCore::SelectorChecker::DOMTraversalStrategy::countElementsOfTypeBefore): Ditto.
51431         (WebCore::SelectorChecker::DOMTraversalStrategy::countElementsAfter): Ditto.
51432         (WebCore::SelectorChecker::DOMTraversalStrategy::countElementsOfTypeAfter): Ditto.
51433         * css/SelectorChecker.h:
51434         (DOMTraversalStrategy): Changed into a class, rather than a template.
51435         (SelectorChecker): Turned back into a function.
51436
51437 2012-10-10  James Simonsen  <simonjam@chromium.org>
51438
51439         High res times should start at 0
51440         https://bugs.webkit.org/show_bug.cgi?id=84912
51441
51442         Reviewed by Tony Gentilcore.
51443
51444         Test: Existing Navigation Timing tests.
51445
51446         * inspector/InspectorInstrumentation.cpp: Use legacy document time, pending 98223.
51447         (WebCore):
51448         (WebCore::InspectorInstrumentation::didFinishLoadingImpl):
51449         * inspector/InspectorResourceAgent.cpp:
51450         (WebCore::buildObjectForTiming):
51451         * loader/DocumentLoadTiming.cpp:
51452         (WebCore::DocumentLoadTiming::convertMonotonicTimeToLegacyDocumentTime):
51453         (WebCore):
51454         (WebCore::DocumentLoadTiming::convertMonotonicTimeToZeroBasedDocumentTime):
51455         (WebCore::DocumentLoadTiming::markNavigationStart):
51456         * loader/DocumentLoadTiming.h:
51457         (DocumentLoadTiming):
51458         (WebCore::DocumentLoadTiming::navigationStart): These just report raw monotonic times now.
51459         (WebCore::DocumentLoadTiming::unloadEventStart):
51460         (WebCore::DocumentLoadTiming::unloadEventEnd):
51461         (WebCore::DocumentLoadTiming::redirectStart):
51462         (WebCore::DocumentLoadTiming::redirectEnd):
51463         (WebCore::DocumentLoadTiming::fetchStart):
51464         (WebCore::DocumentLoadTiming::responseEnd):
51465         (WebCore::DocumentLoadTiming::loadEventStart):
51466         (WebCore::DocumentLoadTiming::loadEventEnd):
51467         * page/PerformanceTiming.cpp:
51468         (WebCore::PerformanceTiming::navigationStart): Convert these back to legacy document times.
51469         (WebCore::PerformanceTiming::unloadEventStart):
51470         (WebCore::PerformanceTiming::unloadEventEnd):
51471         (WebCore::PerformanceTiming::redirectStart):
51472         (WebCore::PerformanceTiming::redirectEnd):
51473         (WebCore::PerformanceTiming::fetchStart):
51474         (WebCore::PerformanceTiming::responseEnd):
51475         (WebCore::PerformanceTiming::loadEventStart):
51476         (WebCore::PerformanceTiming::loadEventEnd):
51477         (WebCore::PerformanceTiming::resourceLoadTimeRelativeToAbsolute):
51478         (WebCore::PerformanceTiming::monotonicTimeToIntegerMilliseconds):
51479         * platform/network/ResourceLoadTiming.cpp:
51480         (WebCore::ResourceLoadTiming::convertResourceLoadTimeToMonotonicTime):
51481         * platform/network/ResourceLoadTiming.h:
51482         (ResourceLoadTiming):
51483
51484 2012-10-10  Levi Weintraub  <leviw@chromium.org>
51485
51486         Tests failure on Chromium Mac after r130821
51487         https://bugs.webkit.org/show_bug.cgi?id=98865
51488
51489         Reviewed by Adam Barth.
51490
51491         Updating the check for USE(HARFBUZZ_NG) to check for Mac Chromium, as the HARFBUZZ_NG flag isn't
51492         actually set, despite us using Harfbuzz. This unbreaks Chromium Mac as we diagnose the root
51493         cause of this issue.
51494
51495         * rendering/RenderBlockLineLayout.cpp:
51496         (WebCore::setLogicalWidthForTextRun):
51497
51498 2012-10-10  Stephen Chenney  <schenney@chromium.org>
51499
51500         SVGTextRunRenderingContext changes font data in the glyph page, but it shouldn't
51501         https://bugs.webkit.org/show_bug.cgi?id=98755
51502
51503         Reviewed by Eric Seidel.
51504
51505         The code in SVGTextRunRenderingContext::glyphDataForCharacter, when it
51506         encounters an <altglyph> tag, immediately replaces the font data for a
51507         glyph with font data for the primary font, presumably to meet the SVG
51508         spec requirement: "If the references to alternate glyphs do not result
51509         in successful identification of alternate glyphs to use, then the
51510         character(s) that are inside of the ‘altGlyph’ element are rendered as
51511         if the ‘altGlyph’ element were a ‘tspan’ element instead."
51512
51513         If the alt glyph is not then found we are in the case from the spec
51514         and indeed we should use the primary font. However, we end up replacing the GlyphPage
51515         entry for the character with primary font data, which we should not do
51516         because the glyph page might be used in some place that does not have
51517         the alt glyph tag.
51518
51519         Furthermore, this causes object lifetime problems for font data, because
51520         in cases where the font data that is replaced is for the system fallback
51521         font the GlyphPage will live forever with no knowldege that it contains
51522         font data pointers into font data other that the system fallback. The
51523         replaced font data may be deleted while the pointer lives on in the
51524         system fallback page.
51525
51526         The fix is simply not to replace the font data in the page.
51527
51528         Test: svg/text/alt-glpyh-on-fallback-font-crash.html
51529
51530         * rendering/svg/SVGTextRunRenderingContext.cpp:
51531         (WebCore::SVGTextRunRenderingContext::glyphDataForCharacter): Keep track of the original font data and put it back
51532         in the glyph page when the method has finished.
51533
51534 2012-10-10  Tab Atkins  <jackalmage@gmail.com>
51535
51536         column-count: 0 should not prevent margin-collapse through
51537         https://bugs.webkit.org/show_bug.cgi?id=65159
51538
51539         Reviewed by Tony Chang.
51540
51541         This patch makes "column-count:0" be properly recognized as invalid syntax,
51542         as it violates the property grammar in the spec.
51543
51544         Tests: fast/multicol/zeroColumnCount.html
51545
51546         * css/CSSParser.cpp:
51547         (WebCore::CSSParser::validUnit):
51548         (WebCore::CSSParser::parseValue):
51549         * css/CSSParser.h:
51550
51551 2012-10-10  Benjamin Poulain  <bpoulain@apple.com>
51552
51553         [WK2] Safari crashes on error when using CFNetwork
51554         https://bugs.webkit.org/show_bug.cgi?id=98965
51555
51556         Reviewed by Sam Weinig.
51557
51558         The code of ResourceErrorMac when using CFNetwork was assuming
51559         there is always either a CFError or an NSError associated with
51560         any ResourceError.
51561
51562         This is not true on WebKit2 where error can be generic errors
51563         in the WebProcess (for example a cannotShowURLError).
51564         The code was crashing when trying to invoke function on the
51565         non-existing CFError.
51566
51567         This patch fixes the issue by handling that third case separately.
51568         If the ResourceError is a generic error, a new NSError is created,
51569         similarily to what is done in the non-CFNetwork case.
51570
51571         * platform/network/mac/ResourceErrorMac.mm:
51572         (WebCore::ResourceError::nsError):
51573
51574 2012-10-10  Alexander Shalamov  <alexander.shalamov@intel.com>
51575
51576         Invalid values for media query features are not handled
51577         https://bugs.webkit.org/show_bug.cgi?id=97006
51578
51579         Reviewed by Kenneth Rohde Christiansen.
51580
51581         This patch improves pass rate of CSS3 Media Queries test suite
51582         by making media expressions compliant with W3C specification. Few
51583         performance issues are fixed by removal of string comparison during
51584         media expression evaluation.
51585
51586         Tests: fast/media/w3c/test_media_queries.html
51587
51588         * css/CSSGrammar.y: Handle media query expression with specified media restrictor as invalid.
51589         * css/MediaQuery.cpp:
51590         (WebCore::MediaQuery::serialize): Serialize invalid query according to specification.
51591         * css/MediaQueryEvaluator.cpp:
51592         (WebCore::orientationMediaFeatureEval): Compare CSSValueID instead of strings.
51593         (WebCore::view_modeMediaFeatureEval): Compare CSSValueID instead of strings.
51594         (WebCore::pointerMediaFeatureEval): Compare CSSValueID instead of strings.
51595         * css/MediaQueryExp.cpp:
51596         (WebCore::MediaQueryExp::MediaQueryExp): Check that media features initialized with correct values.
51597
51598 2012-10-10  Justin Novosad  <junov@chromium.org>
51599
51600         [Chromium] Smoother animation for non-RAF 2D canvas animations
51601         https://bugs.webkit.org/show_bug.cgi?id=97918
51602
51603         Reviewed by Stephen White.
51604
51605         Reduces animation jank by preventing the accumulation of multiple
51606         frames of backlog in the deferred canvas rendering queue. When the
51607         animation is more than one full frame ahead of the compositor, an
51608         immediate flush is triggered.  This takes into account overdraw
51609         elimination by the skip-on-clear optimization that is built-in to
51610         SkDeferredCanvas, to allow non-RAF animations that clear the canvas at
51611         each frame to run without any rate limiting. This change also
51612         incidentally improves frame rate in many cases by providing more
51613         granular batching of GPU API calls, resulting in better pipelining
51614         through the command buffer.
51615
51616         Test: webkit_unit_test Canvas2DLayerManagerTest.testDeferredFrame
51617
51618         * platform/graphics/chromium/Canvas2DLayerBridge.cpp:
51619         (WebCore::Canvas2DLayerBridge::Canvas2DLayerBridge):
51620         (WebCore::Canvas2DLayerBridge::limitPendingFrames):
51621         Called at the end of a task (usually a scheduled script action) that
51622         invoked 2d canvas rendering context methods. The end of the task
51623         marks the completion of a displayable frame. This method will trigger
51624         a flush if it detects that the layer has pending draw commands that
51625         are more that one frame old.
51626         (WebCore):
51627         (WebCore::Canvas2DLayerBridge::flushedDrawCommands):
51628         (WebCore::Canvas2DLayerBridge::didFlushPendingCommands):
51629         (WebCore::Canvas2DLayerBridge::skippedPendingDrawCommands):
51630         (WebCore::Canvas2DLayerBridge::flush):
51631         (WebCore::Canvas2DLayerBridge::contextAcquired):
51632         * platform/graphics/chromium/Canvas2DLayerBridge.h:
51633         (Canvas2DLayerBridge):
51634         * platform/graphics/chromium/Canvas2DLayerManager.cpp:
51635         (WebCore::Canvas2DLayerManager::~Canvas2DLayerManager):
51636         (WebCore::Canvas2DLayerManager::willProcessTask):
51637         (WebCore):
51638         (WebCore::Canvas2DLayerManager::didProcessTask):
51639         (WebCore::Canvas2DLayerManager::layerDidDraw):
51640         * platform/graphics/chromium/Canvas2DLayerManager.h:
51641         (Canvas2DLayerManager):
51642
51643 2012-10-10  Beth Dakin  <bdakin@apple.com>
51644
51645         https://bugs.webkit.org/show_bug.cgi?id=98968
51646         REGRESSION: Unable to scroll with trackpad on some websites after 
51647         r130783
51648
51649         Reviewed by Simon Fraser.
51650
51651         This bug seems to reproduce mostly on web pages that require login. 
51652         The re-routing causes extra churn of the RenderLayerBacking, and we 
51653         end up destroying and re-creating the backing and therefore the 
51654         ScrollingStateNodes, and when the timing is just wrong we get into a 
51655         state where the ScrollingTree has a set of incorrect information. 
51656         This patch fixes the bug by making sure the ScrollingStateNodes keep 
51657         the ScrollingTree in synch with their re-set data.
51658
51659         Tell the ScrollingStateTree that the root layer has changed.
51660         * page/scrolling/ScrollingCoordinator.cpp:
51661         (WebCore::ScrollingCoordinator::frameViewRootLayerDidChange):
51662
51663         New virtual function will set every property as having changed.
51664         * page/scrolling/ScrollingStateNode.h:
51665         (WebCore::ScrollingStateNode::setHasChangedProperties):
51666         * page/scrolling/ScrollingStateScrollingNode.cpp:
51667         (WebCore::ScrollingStateScrollingNode::setHasChangedProperties):
51668         (WebCore):
51669         * page/scrolling/ScrollingStateScrollingNode.h:
51670
51671         When the root layer changes, make sure we update the ScrollingTree 
51672         appropriately by indicating that every property could have changed.
51673         * page/scrolling/ScrollingStateTree.cpp:
51674         (WebCore::ScrollingStateTree::rootLayerDidChange):
51675         (WebCore):
51676         * page/scrolling/ScrollingStateTree.h:
51677         (ScrollingStateTree):
51678
51679 2012-10-10  MORITA Hajime  <morrita@google.com>
51680
51681         [Chromium] Crash on SpellChecker::didCheck()
51682         https://bugs.webkit.org/show_bug.cgi?id=98476
51683
51684         Reviewed by Kent Tamura.
51685
51686         SpellChecker::didCheck() assumed m_processingRequest is non-NULL. However, SpellChecker::invokeRequest()
51687         calls SpellCheckRequest::didCancel(), which results didCheck() with NULL m_processingRequest.
51688         This chagne eliminates the problematic didCheck().
51689
51690         No new tests. The case depends on specific timing and is hard to hit by automated testing.
51691
51692         * editing/SpellChecker.cpp:
51693         (WebCore::SpellChecker::didCheck):
51694
51695 2012-10-10  MORITA Hajime  <morrita@google.com>
51696
51697         https://bugs.webkit.org/show_bug.cgi?id=95664
51698         [Shadow DOM] should be able to be available without <style scoped>
51699
51700         Reviewed by Dimitri Glazkov.
51701
51702         This change relaxes ENABLE(STYLE_SCOPED) compilation guard
51703         and styleScopedEnabled() runtime guard. The flags now masks
51704         user visible bits of the code, rather than all of it.
51705         This change also eliminates some redundant guards for simplicity.
51706
51707         Test: fast/dom/shadow/style-scoped-not-enabled.html
51708
51709         * css/StyleResolver.cpp:
51710         (WebCore::StyleResolver::matchScopedAuthorRules):
51711         (WebCore::StyleResolver::locateCousinList):
51712         (WebCore::StyleResolver::canShareStyleWithElement):
51713         (WebCore::StyleResolver::locateSharedStyle):
51714         * css/StyleScopeResolver.cpp:
51715         (WebCore::StyleScopeResolver::scopeFor):
51716         * css/StyleScopeResolver.h:
51717         (WebCore):
51718         * html/HTMLStyleElement.cpp:
51719         (WebCore::HTMLStyleElement::HTMLStyleElement):
51720         (WebCore::HTMLStyleElement::parseAttribute):
51721         (WebCore::HTMLStyleElement::scopedAttributeChanged):
51722         (WebCore::HTMLStyleElement::isRegisteredAsScoped):
51723         (WebCore::HTMLStyleElement::registerWithScopingNode):
51724         (WebCore::HTMLStyleElement::unregisterWithScopingNode):
51725         (WebCore::HTMLStyleElement::insertedInto):
51726         (WebCore::HTMLStyleElement::removedFrom):
51727         (WebCore::HTMLStyleElement::scoped):
51728         (WebCore::HTMLStyleElement::scopingElement):
51729         * html/HTMLStyleElement.h:
51730         (HTMLStyleElement):
51731         * testing/InternalSettings.cpp: Exporsing a flag for testing.
51732         (WebCore::InternalSettings::Backup::Backup):
51733         (WebCore::InternalSettings::Backup::restoreTo):
51734         (WebCore::InternalSettings::setStyleScopedEnabled):
51735         (WebCore):
51736         * testing/InternalSettings.h: Exporsing a flag for testing.
51737         (Backup):
51738         (InternalSettings):
51739         * testing/InternalSettings.idl: Exporsing a flag for testing.
51740
51741 2012-10-10  Roger Fong  <roger_fong@apple.com>
51742
51743         [WebGL] [On Mac] queried attributes and uniforms need to return the original variable name, not the mapped name.
51744         https://bugs.webkit.org/show_bug.cgi?id=98470
51745
51746         Reviewed by Timothy Horton.
51747
51748         When a variable name is too long we translate to a shorter version and keep a mapping between the long and short names.
51749         However, when querying for a variable client side using getActiveAttrib or getActiveUniform, we accidentally return the 
51750         translated names. This fix makes these methods return the original variable names.
51751
51752         Tested using Khronos WebGL conformance suite:
51753         conformance/glsl/misc/glsl-long-variable-names.html
51754
51755         * platform/graphics/GraphicsContext3D.h:
51756         (GraphicsContext3D):
51757         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp: getActiveAttrib and getActiveUniform
51758         now use GraphicsContext3D::originalSymbolName to find the original variable name.
51759         (WebCore::GraphicsContext3D::getActiveAttrib):
51760         (WebCore::GraphicsContext3D::getActiveUniform):
51761         (WebCore):
51762         (WebCore::GraphicsContext3D::originalSymbolName): This method returns the original variable name given 
51763         the mapped name.
51764
51765 2012-10-10 Brady Eidson  <beidson@apple.com>
51766
51767         Switch over CachedResource::data() from taking a SharedBuffer to taking a ResourceBuffer.
51768         https://bugs.webkit.org/show_bug.cgi?id=98952
51769
51770         Reviewed by Anders Carlsson.
51771
51772         No new tests (No behavior change).
51773
51774         * html/ImageDocument.cpp:
51775         (WebCore::ImageDocumentParser::appendBytes):
51776         (WebCore::ImageDocumentParser::finish):
51777         * loader/SubresourceLoader.cpp:
51778         (WebCore::SubresourceLoader::sendDataToResource):
51779         (WebCore::SubresourceLoader::didFinishLoading):
51780         * loader/cache/CachedCSSStyleSheet.cpp:
51781         (WebCore::CachedCSSStyleSheet::data):
51782         * loader/cache/CachedCSSStyleSheet.h:
51783         (WebCore):
51784         (CachedCSSStyleSheet):
51785         * loader/cache/CachedFont.cpp:
51786         (WebCore::CachedFont::data):
51787         * loader/cache/CachedFont.h:
51788         (WebCore):
51789         (CachedFont):
51790         * loader/cache/CachedImage.cpp:
51791         (WebCore::CachedImage::data):
51792         * loader/cache/CachedImage.h:
51793         (CachedImage):
51794         * loader/cache/CachedRawResource.cpp:
51795         (WebCore::CachedRawResource::data):
51796         * loader/cache/CachedRawResource.h:
51797         (CachedRawResource):
51798         * loader/cache/CachedResource.cpp:
51799         (WebCore::CachedResource::data):
51800         * loader/cache/CachedResource.h:
51801         (CachedResource):
51802         * loader/cache/CachedSVGDocument.cpp:
51803         (WebCore::CachedSVGDocument::data):
51804         * loader/cache/CachedSVGDocument.h:
51805         (CachedSVGDocument):
51806         * loader/cache/CachedScript.cpp:
51807         (WebCore::CachedScript::data):
51808         * loader/cache/CachedScript.h:
51809         (CachedScript):
51810         * loader/cache/CachedShader.cpp:
51811         (WebCore::CachedShader::data):
51812         * loader/cache/CachedShader.h:
51813         (CachedShader):
51814         * loader/cache/CachedTextTrack.cpp:
51815         (WebCore::CachedTextTrack::data):
51816         * loader/cache/CachedTextTrack.h:
51817         (CachedTextTrack):
51818         * loader/cache/CachedXSLStyleSheet.cpp:
51819         (WebCore::CachedXSLStyleSheet::data):
51820         * loader/cache/CachedXSLStyleSheet.h:
51821         (CachedXSLStyleSheet):
51822
51823 2012-10-10  Jon Lee  <jonlee@apple.com>
51824
51825         [WK2] Activate plugins when user clicks on snapshot
51826         https://bugs.webkit.org/show_bug.cgi?id=98328
51827         <rdar://problem/12426681>
51828
51829         Reviewed by Brady Eidson.
51830
51831         Extend the default event handler to deal with plugins with snapshots.
51832         When the user clicks on the placeholder, the plugin is recreated and displayed.
51833
51834         * loader/FrameLoaderClient.h: Add new client function recreatePlugin(), which is
51835         expected to re-create the plugin with the same parameters as when it was run to
51836         obtain the plugin's snapshot placeholder.
51837
51838         * loader/EmptyClients.cpp: Stub implementation of recreatePlugin().
51839         * loader/EmptyClients.h:
51840         * WebCore.exp.in: Expose HTMLPlugInElement::pluginWidget().
51841
51842         * html/HTMLPlugInElement.cpp:
51843         (WebCore::HTMLPlugInElement::defaultEventHandler): Update to look for
51844         RenderSnapshottedPlugIn. If the plugin is not playing, have the renderer handle the
51845         event.
51846
51847         * rendering/RenderSnapshottedPlugIn.cpp:
51848         (WebCore::RenderSnapshottedPlugin::getCursor): Set to hand cursor when the plugin is not
51849         playing.
51850         (WebCore::RenderSnapshottedPlugIn::handleEvent): If the user clicked on the plugin using the
51851         left button, update the state of the element to playing. Recreate the plugin if the widget exists
51852         to begin with. The cached snapshot image will be saved for possible reuse on back/forward navigation.
51853         * rendering/RenderSnapshottedPlugIn.h:
51854         (RenderSnapshottedPlugIn):
51855
51856 2012-10-10  Kenichi Ishibashi  <bashi@chromium.org>
51857
51858         FontVerticalDataCache should allow zero as a key value
51859         https://bugs.webkit.org/show_bug.cgi?id=98877
51860
51861         Reviewed by Tony Chang.
51862
51863         Use WTF::UnsignedWithZeroKeyHashTraits for type definition of
51864         FontVerticalDataCache.
51865
51866         No new tests because there is no certain way to make
51867         FontPlatformDataHarfBuzz::uniqueID() be zero.
51868
51869         * platform/graphics/FontCache.cpp:
51870         (WebCore):
51871         * platform/graphics/harfbuzz/FontPlatformDataHarfBuzz.cpp:
51872         (WebCore::FontPlatformData::verticalData): Removed zero check of uniqueID().
51873         (WebCore::FontPlatformData::openTypeTable): Ditto.
51874
51875 2012-10-10  Regina Chung  <heejin.r.chung@samsung.com>
51876
51877         [EFL] Use the shareable GraphicsContext3DOpenGL* implementation.
51878         https://bugs.webkit.org/show_bug.cgi?id=96627
51879
51880         Reviewed by Kenneth Rohde Christiansen.
51881
51882         Changed EFL implementation of GraphicsContext3D(GC3D) to use GraphicsContext3DOpenGL*.
51883         It was initially implemented in a different way, due to characteristics of Evas,
51884         but it would be better to use the common implementation and find another way
51885         to deal with Evas, especially because all the duplicated code.
51886
51887         No new tests. No functional changes.
51888
51889         * PlatformEfl.cmake: Removed cairo implementation of GC3D and added efl files to WebCore_SOURCES.
51890         * platform/graphics/efl/GraphicsContext3DEfl.cpp: Modified code so GC3DOpenGL* can be used.
51891         (WebCore::GraphicsContext3D::create):
51892         (WebCore::GraphicsContext3D::GraphicsContext3D):
51893         (WebCore::GraphicsContext3D::platformLayer):
51894         (WebCore::GraphicsContext3D::makeContextCurrent):
51895         (WebCore::GraphicsContext3D::setContextLostCallback):
51896         (WebCore::GraphicsContext3D::setErrorMessageCallback):
51897         (WebCore::GraphicsContext3D::paintToCanvas):
51898         (WebCore):
51899         (WebCore::GraphicsContext3D::createGraphicsSurfaces):
51900         (WebCore::GraphicsContext3D::releaseShaderCompiler):
51901         (WebCore::GraphicsContext3D::getImageData):
51902         * platform/graphics/efl/GraphicsContext3DPrivate.cpp: Removed functions implemented in GC3DOpenGL*
51903         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
51904         (WebCore):
51905         (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
51906         (WebCore::GraphicsContext3DPrivate::createSurface):
51907         (WebCore::GraphicsContext3DPrivate::platformGraphicsContext3D):
51908         (WebCore::GraphicsContext3DPrivate::makeContextCurrent):
51909         (WebCore::GraphicsContext3DPrivate::isGLES2Compliant):
51910         (WebCore::GraphicsContext3DPrivate::paintToTextureMapper):
51911         * platform/graphics/efl/GraphicsContext3DPrivate.h: Removed functions implemented in GC3DOpenGL*
51912         (GraphicsContext3DPrivate):
51913
51914 2012-10-10  Tony Chang  <tony@chromium.org>
51915
51916         Unreviewed, rolling out r130937, r130949, r130955, and
51917         r130957.
51918         http://trac.webkit.org/changeset/130937
51919         http://trac.webkit.org/changeset/130949
51920         http://trac.webkit.org/changeset/130955
51921         http://trac.webkit.org/changeset/130957
51922         https://bugs.webkit.org/show_bug.cgi?id=94290
51923
51924         Breaks Qt build
51925
51926         * CMakeLists.txt:
51927         * DerivedSources.make:
51928         * DerivedSources.pri:
51929         * GNUmakefile.am:
51930         * WebCore.gyp/WebCore.gyp:
51931         * WebCore.gyp/scripts/action_preprocessgrammar.py: Removed.
51932         * WebCore.vcproj/WebCore.vcproj:
51933         * WebCore.xcodeproj/project.pbxproj:
51934         * css/CSSGrammar.y: Renamed from Source/WebCore/css/CSSGrammar.y.in.
51935         * css/CSSGrammar.y.includes: Removed.
51936         * css/makegrammar.pl:
51937
51938 2012-10-10  Rob Buis  <rbuis@rim.com>
51939
51940         [BlackBerry] Adapt to new image for search-cancel
51941         https://bugs.webkit.org/show_bug.cgi?id=98954
51942
51943         Reviewed by Antonio Gomes.
51944
51945         The new image for search-cancel is bigger than the old one, so invert the scaling.
51946
51947         * platform/blackberry/RenderThemeBlackBerry.cpp:
51948         (WebCore::RenderThemeBlackBerry::adjustSearchFieldCancelButtonStyle):
51949
51950 2012-10-10  Tony Chang  <tony@chromium.org>
51951
51952         Unreviewed, another speculative fix for Qt Win.
51953
51954         * DerivedSources.pri: Pass --preprocessor to the perl script.
51955         * css/makegrammar.pl: Use --preprocessor instead of /usr/bin/gcc.
51956
51957 2012-10-10  Tony Chang  <tony@chromium.org>
51958
51959         Unreviewed, another speculative fix for Qt Win.
51960
51961         * DerivedSources.pri: Make the path slash marks be forward slashes to the .in file.
51962
51963 2012-10-10  David Barton  <dbarton@mathscribe.com>
51964
51965         Turn on ENABLE_MATHML for Chromium
51966         https://bugs.webkit.org/show_bug.cgi?id=96960
51967
51968         Reviewed by Adam Barth.
51969
51970         Add the rendering/mathml directory to search.
51971
51972         * WebCore.gyp/WebCore.gyp:
51973
51974 2012-10-10  Tony Chang  <tony@chromium.org>
51975
51976         Unreviewed, speculative build fix for Qt Win.
51977
51978         * css/makegrammar.pl: Rather than making a temp file, use a pipe to
51979         pass data from gcc to the final output file.
51980
51981 2012-10-10  Brady Eidson  <beidson@apple.com>
51982
51983         Switch CachedResource over from SharedBuffer to a new ResourceBuffer
51984         https://bugs.webkit.org/show_bug.cgi?id=98541
51985
51986         Reviewed by Anders Carlsson.
51987
51988         As part of preparation for a WebKit2 NetworkProcess, we need to change the data handle shared
51989         between CachedResources and ResourceLoaders to be one that can be backed by something other
51990         than a SharedBuffer.
51991
51992         ResourceBuffer is this new object. Right now it is directly backed by a SharedBuffer and there
51993         should be no change in behavior.
51994
51995         No new tests (No behavior change).
51996
51997         * WebCore.exp.in:
51998         * WebCore.xcodeproj/project.pbxproj:
51999         * WebCore.vcproj/WebCore.vcproj:
52000         * CMakeLists.txt:
52001         * GNUmakefile.list.am:
52002         * Target.pri:
52003         * WebCore.gypi:
52004
52005         Implementation of the new ResourceBuffer, backed directly by a SharedBuffer:
52006         * loader/ResourceBuffer.cpp: Added.
52007         (WebCore):
52008         (WebCore::ResourceBuffer::ResourceBuffer):
52009         (WebCore::ResourceBuffer::~ResourceBuffer):
52010         (WebCore::ResourceBuffer::data):
52011         (WebCore::ResourceBuffer::size):
52012         (WebCore::ResourceBuffer::isEmpty):
52013         (WebCore::ResourceBuffer::getSomeData):
52014         (WebCore::ResourceBuffer::sharedBuffer):
52015         (WebCore::ResourceBuffer::copy):
52016         (WebCore::ResourceBuffer::hasPurgeableBuffer):
52017         (WebCore::ResourceBuffer::releasePurgeableBuffer):
52018         (WebCore::ResourceBuffer::createCFData):
52019
52020         * loader/ResourceBuffer.h: Added.
52021         (WebCore):
52022         (ResourceBuffer):
52023         (WebCore::ResourceBuffer::create):
52024         (WebCore::ResourceBuffer::adoptSharedBuffer):
52025         * loader/mac/ResourceBuffer.mm: Added.
52026
52027         (WebCore):
52028         (WebCore::ResourceBuffer::createNSData):
52029
52030         Switch CachedResource over to using it:
52031         * loader/cache/CachedResource.cpp:
52032         (WebCore::CachedResource::makePurgeable):
52033
52034         * loader/cache/CachedResource.h:
52035         (WebCore):
52036         (WebCore::CachedResource::resourceBuffer):
52037         (CachedResource):
52038
52039         Switch all the other CachedResource subclasses over to using it:
52040         * loader/cache/CachedCSSStyleSheet.cpp:
52041         (WebCore::CachedCSSStyleSheet::data):
52042
52043         * loader/cache/CachedFont.cpp:
52044         (WebCore::CachedFont::data):
52045         (WebCore::CachedFont::ensureCustomFontData):
52046
52047         * loader/cache/CachedImage.cpp:
52048         (WebCore::CachedImage::didAddClient):
52049         (WebCore::CachedImage::data):
52050
52051         * loader/cache/CachedRawResource.cpp:
52052         (WebCore::CachedRawResource::data):
52053
52054         * loader/cache/CachedScript.cpp:
52055         (WebCore::CachedScript::data):
52056
52057         * loader/cache/CachedShader.cpp:
52058         (WebCore::CachedShader::data):
52059
52060         * loader/cache/CachedTextTrack.cpp:
52061         (WebCore::CachedTextTrack::data):
52062         
52063         * loader/cache/CachedXSLStyleSheet.cpp:
52064         (WebCore::CachedXSLStyleSheet::data):
52065
52066         Switch other affect parties over to using it:
52067         * inspector/InspectorPageAgent.cpp:
52068         (WebCore::decodeBuffer):
52069         (WebCore::InspectorPageAgent::cachedResourceContent):
52070         (WebCore::InspectorPageAgent::sharedBufferContent):
52071
52072         * loader/DocumentLoader.cpp:
52073         (WebCore::DocumentLoader::subresource):
52074
52075         * loader/TextTrackLoader.cpp:
52076         (WebCore::TextTrackLoader::processNewCueData):
52077         (WebCore::TextTrackLoader::didReceiveData):
52078
52079         * loader/archive/cf/LegacyWebArchive.cpp:
52080         (WebCore::LegacyWebArchive::create):
52081
52082         * loader/icon/IconLoader.cpp:
52083         (WebCore::IconLoader::notifyFinished):
52084
52085         * platform/mac/PasteboardMac.mm:
52086         (WebCore::fileWrapperForImage):
52087
52088 2012-10-10  Julien Chaffraix  <jchaffraix@webkit.org>
52089
52090         Unreviewed build fix after r130940.
52091
52092         * platform/graphics/skia/GraphicsContextSkia.cpp:
52093         (WebCore::GraphicsContext::drawLineForDocumentMarker):
52094         Avoid redefining the same variable twice.
52095
52096 2012-10-10  Alexis Menard  <alexis@webkit.org>
52097
52098         [Mac] Deprecate getPropertyShorthand from objective c bindings for future removal
52099         https://bugs.webkit.org/show_bug.cgi?id=98916
52100
52101         Reviewed by Timothy Hatcher.
52102
52103         Mark getPropertyShorthand as deprecated so we can remove it later. It will allow us
52104         to remove getPropertyShorthand from the web exposed API (this function is not part of
52105         any specification, it was there for historical reason).
52106
52107         No new tests : just mark a function as deprecated.
52108
52109         * bindings/objc/PublicDOMInterfaces.h:
52110
52111 2012-10-10  Mike West  <mkwst@chromium.org>
52112
52113         Web Inspector: add support for %c (style) in console API
52114         https://bugs.webkit.org/show_bug.cgi?id=69401
52115
52116         Reviewed by Pavel Feldman.
52117
52118         This patch mimics Firebug's '%c' option when calling 'console.log'
52119         messages. 'console.log("%cBlue!", "color: blue;");' will write blue
52120         text to the console, and so on.
52121
52122         To match Firebug's behavior, multiple '%c' entries will overwrite each
52123         other: only one style will be applied. Sorry, folks.
52124
52125         Test: inspector/console/console-format-style.html
52126
52127         * inspector/front-end/ConsoleMessage.js:
52128         (WebInspector.ConsoleMessageImpl.prototype._formatWithSubstitutionString.styleFormatter):
52129         (WebInspector.ConsoleMessageImpl.prototype._formatWithSubstitutionString.append):
52130         (WebInspector.ConsoleMessageImpl.prototype._formatWithSubstitutionString):
52131
52132 2012-10-10  Varun Jain  <varunjain@chromium.org>
52133
52134         [chromium] Spelling and grammar markers are pixelated in hidpi.
52135         https://bugs.webkit.org/show_bug.cgi?id=98339
52136
52137         Reviewed by Stephen White.
52138
52139         We create separate bitmaps for markers in normal and hidpi mode as per
52140         specification from UX and choose the right bitmap based on the current
52141         device scale factor.
52142
52143         Tests: editing/spelling/grammar-markers-hidpi.html
52144                editing/spelling/inline-spelling-markers-hidpi.html
52145
52146         * platform/graphics/skia/GraphicsContextSkia.cpp:
52147         (WebCore::draw2xMarker):
52148         (WebCore):
52149         (WebCore::draw1xMarker):
52150         (WebCore::GraphicsContext::drawLineForDocumentMarker):
52151         * platform/graphics/skia/PlatformContextSkia.cpp:
52152         (WebCore::PlatformContextSkia::PlatformContextSkia):
52153         * platform/graphics/skia/PlatformContextSkia.h:
52154         (WebCore::PlatformContextSkia::deviceScaleFactor):
52155         (WebCore::PlatformContextSkia::setDeviceScaleFactor):
52156         (PlatformContextSkia):
52157
52158 2012-10-10  Pablo Flouret  <pablof@motorola.com>
52159
52160         Pre-process CSSGrammar.y before running through bison.
52161         https://bugs.webkit.org/show_bug.cgi?id=94290
52162
52163         Reviewed by Tony Chang.
52164
52165         Running CSSGrammar.y through a preprocessor allows the use of feature
52166         defines in all places of the yacc file (i.e. not just in C blocks).
52167         Mostly useful to be able to keep every part of a feature under feature
52168         flags for self-documenting purposes.
52169
52170         No new tests, CSSGrammar.y should be generated correctly and everything
52171         should keep working as before.
52172
52173         * CMakeLists.txt:
52174         * DerivedSources.make:
52175         * DerivedSources.pri:
52176         * GNUmakefile.am:
52177             Modify build systems to use makegrammar.pl to generate the .y files
52178             and run those through bison.
52179
52180         * WebCore.gyp/WebCore.gyp:
52181         * WebCore.gyp/scripts/action_preprocessgrammar.py: Added.
52182             Add a new action to preprocess the CSSGrammar.y.in file before the
52183             bison rule is run.
52184
52185         * WebCore.vcproj/WebCore.vcproj:
52186         * WebCore.xcodeproj/project.pbxproj:
52187             Add the new .y.in / .y.includes files.
52188
52189         * css/CSSGrammar.y.in: Renamed from Source/WebCore/css/CSSGrammar.y.
52190             Also moved the top declarations section that has includes, defines,
52191             etc. to its own file. These shouldn't be touched by the first
52192             pass of the preprocessor. And changed the existing ENABLE(FEATURE)
52193             ifdefs to ENABLE_FEATURE since the ENABLE() macro is not available
52194             yet.
52195         * css/CSSGrammar.y.includes: Added.
52196             The aforementioned declarations header section. After the .y.in file
52197             is processed it will be concatenated with this one to make the
52198             CSSGrammar.y file.
52199
52200         * css/makegrammar.pl:
52201             Modify the script to handle .y.in files.
52202
52203 2012-10-10  Luciano Wolf  <luciano.wolf@openbossa.org>
52204
52205         EventHandler::handleGestureLongPress breaks compilation if CONTEXT_MENUS isn't set
52206         https://bugs.webkit.org/show_bug.cgi?id=98890
52207
52208         Reviewed by Caio Marcelo de Oliveira Filho.
52209
52210         * page/EventHandler.cpp:
52211         (WebCore::EventHandler::handleGestureLongPress):
52212
52213 2012-10-10  David Grogan  <dgrogan@chromium.org>
52214
52215         Inspector: display IndexedDB integer versions
52216         https://bugs.webkit.org/show_bug.cgi?id=95816
52217
52218         Reviewed by Vsevolod Vlasov.
52219
52220         Added basic test to database-structure.html
52221
52222         * inspector/Inspector.json:
52223         * inspector/InspectorIndexedDBAgent.cpp:
52224         (WebCore):
52225         * inspector/front-end/IndexedDBModel.js:
52226         (WebInspector.IndexedDBModel.prototype._loadDatabase.callback):
52227         (WebInspector.IndexedDBModel.prototype._loadDatabase):
52228         (WebInspector.IndexedDBModel.Database):
52229         * inspector/front-end/IndexedDBViews.js:
52230         (WebInspector.IDBDatabaseView):
52231         (WebInspector.IDBDatabaseView.prototype._refreshDatabase):
52232
52233 2012-10-10  Simon Fraser  <simon.fraser@apple.com>
52234
52235         Store a visible rect in GraphicsLayers, and optionally dump it in layerTreeAsText
52236         https://bugs.webkit.org/show_bug.cgi?id=98839
52237
52238         Reviewed by Sam Weinig.
52239
52240         To replace CATiledLayer with TileCaches, we need to be able to compute the visible part of a GraphicsLayer,
52241         in order to limit the extent of TileCache tiles. Reuse the existing code in GraphicsLayerCA for this,
52242         but store the computed rect in m_visibleRect.
52243         
52244         Add a flag to layerTreeAsText() so that tests can optionally include this visible rect in
52245         layer tree dumps. This output will be platform-specific, so we don't want to do it unconditionally.
52246
52247         * WebCore.exp.in: Signature of Frame::layerTreeAsText() changed.
52248         * page/Frame.cpp:
52249         (WebCore::Frame::layerTreeAsText): Change to take some enum flags rather than just a bool.
52250         * page/Frame.h:
52251         * platform/graphics/GraphicsLayer.cpp:
52252         (WebCore::GraphicsLayer::writeIndent): Make into a static class method so subclasses can use it.
52253         (WebCore::GraphicsLayer::dumpProperties): Call a virtual dumpAdditionalProperties() for subclasses.
52254         (showGraphicsLayerTree):
52255         * platform/graphics/GraphicsLayer.h:
52256         (GraphicsLayer): New LayerTreeAsTextIncludeVisibleRects flag.
52257         (WebCore::GraphicsLayer::dumpAdditionalProperties): New virtual method.
52258         * platform/graphics/ca/GraphicsLayerCA.cpp:
52259         (WebCore::GraphicsLayerCA::recursiveCommitChanges): clipRectForChildren and clipRectForSelf
52260         were previously unused and buggy. Fix to correctly compute clipRectForSelf, to assign
52261         to m_visibleRect.
52262         (WebCore::GraphicsLayerCA::dumpAdditionalProperties): Dump m_visibleRect.
52263         * platform/graphics/ca/GraphicsLayerCA.h:
52264         (GraphicsLayerCA):
52265         * rendering/RenderLayerCompositor.cpp:
52266         (WebCore::RenderLayerCompositor::layerTreeAsText): Convert the flags from Frame flags
52267         to GraphicsLayerFlags and pass them along.
52268         * rendering/RenderLayerCompositor.h:
52269         (RenderLayerCompositor):
52270         * testing/Internals.cpp:
52271         (WebCore::Internals::layerTreeAsText): Overloaded method to handle the optional IDL arguments.
52272         * testing/Internals.h: Add enum.
52273         * testing/Internals.idl: Add optional flags, and a const short to describe the flags.
52274
52275 2012-10-10  Shinya Kawanaka  <shinyak@chromium.org>
52276
52277         Needs internal API to return distributed nodes for InsertionPoint
52278         https://bugs.webkit.org/show_bug.cgi?id=98868
52279
52280         Reviewed by Hajime Morita.
52281
52282         When testing insertion points, we would like to have an internal API which returns a node list
52283         distributed to an insertion point.
52284
52285         We've added the API in Internals.
52286
52287         Test: fast/dom/shadow/distributed-nodes.html
52288
52289         * WebCore.exp.in:
52290         * html/shadow/InsertionPoint.cpp:
52291         (WebCore::InsertionPoint::distributedNodes): Returns the distributed nodes. When InsertionPoint is not
52292         attached, the result will be null, since the distribution is not calculated correctly.
52293         (WebCore):
52294         * html/shadow/InsertionPoint.h:
52295         (InsertionPoint):
52296         * testing/Internals.cpp:
52297         (WebCore::Internals::distributedNodes):
52298         (WebCore):
52299         * testing/Internals.h:
52300         (Internals):
52301         * testing/Internals.idl:
52302
52303 2012-10-10  Wei James  <james.wei@intel.com>
52304
52305         [Chromium]Android x86 content shell debug build warning for uninitialized value used as error with gcc 4.6
52306         https://bugs.webkit.org/show_bug.cgi?id=98629
52307
52308         Reviewed by Adam Barth.
52309
52310         Warning was taken as error for uninitialized value being used when
52311         building content shell for Android x86 with gcc 4.6.
52312
52313         * WebCore.gyp/WebCore.gyp:
52314
52315 2012-10-10  Andrei Bucur  <abucur@adobe.com>
52316
52317         [CSS Regions] Create a separate list for the invalid regions
52318         https://bugs.webkit.org/show_bug.cgi?id=98752
52319
52320         Reviewed by Andreas Kling.
52321
52322         This patch moves the invalid regions in a low traffic data structure, outside the main region list. This should add a small performance boost (there's no test for it) and simplifies the code in the following ways:
52323         - iterations through the region list don't need to worry about invalid regions
52324         - accessing the first/last region is straightforward
52325         - list manipulations are easier to implement (e.g. binary search for a region)
52326
52327         Tests: Adapted fast/regions/flows-dependency-same-flow.html to use the new dump format for the region chain.
52328
52329         * dom/WebKitNamedFlow.cpp:
52330         (WebCore::WebKitNamedFlow::getRegionsByContent): Now returns only the valid regions.
52331         (WebCore::WebKitNamedFlow::getRegions): Now returns only the valid regions.
52332         * rendering/RenderFlowThread.cpp:
52333         (WebCore::RenderFlowThread::RenderFlowThread):
52334         (WebCore::RenderFlowThread::layout):
52335         (WebCore::RenderFlowThread::updateLogicalWidth):
52336         (WebCore::RenderFlowThread::computeLogicalHeight):
52337         (WebCore::RenderFlowThread::repaintRectangleInRegions):
52338         (WebCore::RenderFlowThread::regionAtBlockOffset):
52339         (WebCore::RenderFlowThread::removeRenderBoxRegionInfo):
52340         (WebCore::RenderFlowThread::logicalWidthChangedInRegions):
52341         (WebCore::RenderFlowThread::firstRegion):
52342         (WebCore::RenderFlowThread::lastRegion):
52343         (WebCore::RenderFlowThread::computeOverflowStateForRegions):
52344         (WebCore::RenderFlowThread::regionInRange):
52345         (WebCore::RenderFlowThread::checkRegionsWithStyling):
52346         (WebCore::RenderFlowThread::objectInFlowRegion):
52347         (WebCore::RenderFlowThread::autoLogicalHeightRegionsCount):
52348         * rendering/RenderFlowThread.h:
52349         * rendering/RenderNamedFlowThread.cpp:
52350         (WebCore):
52351         (WebCore::addRegionToList):
52352         (WebCore::RenderNamedFlowThread::addRegionToThread):
52353         (WebCore::RenderNamedFlowThread::removeRegionFromThread):
52354         (WebCore::RenderNamedFlowThread::checkInvalidRegions):
52355         * rendering/RenderNamedFlowThread.h:
52356         (WebCore::RenderNamedFlowThread::invalidRenderRegionList):
52357         (RenderNamedFlowThread):
52358         (WebCore::RenderNamedFlowThread::canBeDestroyed):
52359         * rendering/RenderTreeAsText.cpp:
52360         (WebCore::writeRenderRegionList):
52361         (WebCore):
52362         (WebCore::writeRenderNamedFlowThreads): The valid regions are listed first followed by the invalid regions.
52363
52364 2012-10-10  Vsevolod Vlasov  <vsevik@chromium.org>
52365
52366         Web Inspector: [Regression] Stale revisions are not cleared when inspector is opened for the already loaded page.
52367         https://bugs.webkit.org/show_bug.cgi?id=98915
52368
52369         Reviewed by Alexander Pavlov.
52370
52371         WorkspaceController now clears stale revisions on navigation as well.
52372
52373         * inspector/front-end/Workspace.js:
52374         (WebInspector.WorkspaceController):
52375         (WebInspector.WorkspaceController.prototype._mainFrameNavigated):
52376
52377 2012-10-10  Vsevolod Vlasov  <vsevik@chromium.org>
52378
52379         Web Inspector: Exception when committing java script editing with revision history view open.
52380         https://bugs.webkit.org/show_bug.cgi?id=98908
52381
52382         Reviewed by Alexander Pavlov.
52383
52384         Added null check.
52385
52386         * inspector/front-end/RevisionHistoryView.js:
52387
52388 2012-10-10  Pavel Feldman  <pfeldman@chromium.org>
52389
52390         Web Inspector: protect node in the InspectorDOMNode::inspect
52391         https://bugs.webkit.org/show_bug.cgi?id=98914
52392
52393         Reviewed by Yury Semikhatsky.
52394
52395         * inspector/InspectorDOMAgent.cpp:
52396         (WebCore::InspectorDOMAgent::inspect):
52397
52398 2012-10-10  Mike West  <mkwst@google.com>
52399
52400         EditorCommand calls setProperty with the wrong parameters.
52401         https://bugs.webkit.org/show_bug.cgi?id=98896
52402
52403         Reviewed by Jochen Eisinger.
52404
52405         EditorCommand::executeToggleStyleInList calls
52406         StylePropertySet::setProperty with an ExceptionCode as the final
52407         argument. This only succeeds because it's automagically cast to a bool,
52408         which is what the method actually expects.
52409
52410         Implicitly passing in 'false' by dropping the parameter shouldn't change
52411         any visible functionality; no new tests are required.
52412
52413         * editing/EditorCommand.cpp:
52414         (WebCore::executeToggleStyleInList):
52415
52416 2012-10-10  Mike West  <mkwst@google.com>
52417
52418         HTMLTextFormControlElement calls setInlineStyleProperty with the wrong parameters.
52419         https://bugs.webkit.org/show_bug.cgi?id=98892
52420
52421         Reviewed by Jochen Eisinger.
52422
52423         HTMLTextFormControlElement::updatePlaceholderVisibility calls
52424         HTMLElement::setInlineStyleProperty with an ExceptionCode as the last
52425         parameter. This only succeeds because it's automagically cast to a bool,
52426         which is what the method actually expects.
52427
52428         Implicitly passing in 'false' by dropping the parameter shouldn't change
52429         any functionality; so no new tests are required.
52430
52431         * html/HTMLTextFormControlElement.cpp:
52432         (WebCore::HTMLTextFormControlElement::updatePlaceholderVisibility):
52433
52434 2012-10-10  Christophe Dumez  <christophe.dumez@intel.com>
52435
52436         SQLResultSet.rowsAffected not cleared
52437         https://bugs.webkit.org/show_bug.cgi?id=46070
52438
52439         Reviewed by Kenneth Rohde Christiansen.
52440
52441         SQLResultSet.rowsAffected is supposed to return the number
52442         of rows that were changed by the statement. For "SELECT"
52443         statements, it should return 0.
52444
52445         However, our implementation currently relies on sqlite3_changes()
52446         to compute this value. sqlite3_changes() returns the number of
52447         direct row changes in the most recent INSERT, UPDATE, or DELETE
52448         statement within the same trigger context. Unfortunately, the
52449         most recent INSERT, UPDATE, or DELETE statement may not be the
52450         last statement. As a consequence, if you INSERT 1 row, then
52451         do a SELECT, SQLResultSet.rowsAffected will be 1 for both the
52452         INSERT and the SELECT statements.
52453
52454         The proposed solution is to use sqlite3_total_changes() instead
52455         of sqlite3_changes(). sqlite3_total_changes() returns the number
52456         of row changes caused by INSERT, UPDATE or DELETE statements since
52457         the database connection was opened. We now store the value
52458         returned by sqlite3_total_changes() before each statement in
52459         order to return the count difference in
52460         SQLiteDatabase::lastChanges().
52461
52462         Test: storage/websql/execute-sql-rowsAffected.html
52463
52464         * platform/sql/SQLiteDatabase.cpp:
52465         (WebCore::SQLiteDatabase::SQLiteDatabase):
52466         (WebCore::SQLiteDatabase::updateLastChangesCount):
52467         (WebCore):
52468         (WebCore::SQLiteDatabase::lastChanges):
52469         * platform/sql/SQLiteDatabase.h:
52470         (SQLiteDatabase):
52471         * platform/sql/SQLiteStatement.cpp:
52472         (WebCore::SQLiteStatement::step):
52473
52474 2012-10-10  Keishi Hattori  <keishi@webkit.org>
52475
52476         REGRESSION (r129738): Calendar picker is too wide when the input is rtl
52477         https://bugs.webkit.org/show_bug.cgi?id=98881
52478
52479         Reviewed by Kent Tamura.
52480
52481         Calendar picker should use param.isCalendarRTL instead of param.isRTL but some were left.
52482
52483         No new tests. Covered by ManualTests/forms/calendar-picker.html.
52484
52485         * Resources/pagepopups/calendarPicker.js:
52486         (CalendarPicker.prototype.fixWindowSize): Calendar picker should use param.isCalendarRTL instead of param.isRTL.
52487         (DaysTable.prototype._handleKey): Ditto.
52488
52489 2012-10-10  Alexander Pavlov  <apavlov@chromium.org>
52490
52491         Web Inspector: Semantically incorrect CSS rules result in broken source code data
52492         https://bugs.webkit.org/show_bug.cgi?id=98520
52493
52494         Reviewed by Vsevolod Vlasov.
52495
52496         Pop and throw away rule data from the stack when data have been collected for a semantically invalid CSS rule
52497         (which is not going to be created).
52498
52499         * css/CSSParser.cpp:
52500         (WebCore::CSSParser::createImportRule):
52501         (WebCore::CSSParser::createFontFaceRule):
52502         (WebCore::CSSParser::createPageRule):
52503         (WebCore::CSSParser::createRegionRule):
52504
52505 2012-10-10  Zeno Albisser  <zeno@webkit.org>
52506
52507         [Qt][Mac] GL_ARB_texture_rectangle must be activated when using ANGLE.
52508         https://bugs.webkit.org/show_bug.cgi?id=98387
52509
52510         Check for the availability of GL_ARB_texture_rectangle extension.
52511         In case it is available, we activate the extension for ANGLE.
52512         This is necessary for WebGL on mac, because the GraphicsSurface
52513         on this platform is based on an IOSurface, which requires this extension.
52514
52515         Reviewed by Noam Rosenthal.
52516
52517         * platform/graphics/qt/GraphicsContext3DQt.cpp:
52518         (WebCore::GraphicsContext3DPrivate::initializeANGLE):
52519
52520 2012-10-10  Andreas Kling  <kling@webkit.org>
52521
52522         ElementAttributeData: tighten member packing on 64-bit.
52523         <http://webkit.org/b/98861>
52524
52525         Reviewed by Anders Carlsson.
52526
52527         Pack m_isMutable and m_arraySize into the slack from the RefCounted base on 64-bit.
52528         218kB progression on Membuster3.
52529
52530         * dom/ElementAttributeData.h:
52531         (ElementAttributeData):
52532
52533 2012-10-10  Alexandre Elias  <aelias@chromium.org>
52534
52535         Text Autosizing: Counteract funky window sizing on Android.
52536         https://bugs.webkit.org/show_bug.cgi?id=98809
52537
52538         Reviewed by Adam Barth.
52539
52540         In Chrome for Android, the window sizes provided to WebCore are
52541         currently in physical screen pixels instead of
52542         device-scale-adjusted units. For example window width on a
52543         Galaxy Nexus is 720 instead of 360.  Text autosizing expects
52544         device-independent pixels.  When Chrome for Android cuts over to
52545         the new coordinate space, it will be tied to the setting
52546         applyPageScaleFactorInCompositor.
52547
52548         No new tests.
52549
52550         * rendering/TextAutosizer.cpp:
52551         (WebCore::TextAutosizer::processSubtree):
52552
52553 2012-10-09  Philip Rogers  <pdr@google.com>
52554
52555         Recursively detach SVGElementInstances
52556         https://bugs.webkit.org/show_bug.cgi?id=98851
52557
52558         Reviewed by Ryosuke Niwa and Abhishek Arya
52559
52560         Before this patch, SVGElementInstance child nodes were not being detached. This
52561         patch makes detach() recursively detach SVGElementInstances.
52562
52563         * svg/SVGElementInstance.cpp:
52564         (WebCore::SVGElementInstance::detach):
52565
52566 2012-10-09  Kenichi Ishibashi  <bashi@chromium.org>
52567
52568         [Chromium] Fix harfbuzz-ng related code after r130231
52569         https://bugs.webkit.org/show_bug.cgi?id=98858
52570
52571         Reviewed by Kent Tamura.
52572
52573         Replace first/second with key/value.
52574
52575         No new tests. No changes in behavior.
52576
52577         * platform/graphics/harfbuzz/ng/HarfBuzzNGFaceSkia.cpp:
52578         (WebCore::harfbuzzGetGlyph):
52579         * platform/graphics/skia/SimpleFontDataSkia.cpp:
52580         (WebCore::SimpleFontData::canRenderCombiningCharacterSequence):
52581
52582 2012-10-09  Enrica Casucci  <enrica@apple.com>
52583
52584         Only measure text once instead of twice when performing line layout.
52585         https://bugs.webkit.org/show_bug.cgi?id=98317
52586         <rdar://problem/12080821>
52587
52588         Reviewed by Dan Bernstein.
52589
52590         Since we are measuring each word to find out where the line break should occur,
52591         we should cache that information to avoid measuring the run again when
52592         creating the line box. The bulk of the change is in nextLineBreak, where
52593         the measurements are collected and placed in a vector so that they can
52594         be consumed in setLogicalWidthForTextRun where we used to measure the
52595         text one more time.
52596         Each entry in the vector is a WordMeasurement object that contains information
52597         about the start and end offset in the run, the renderer, the measured width
52598         and, possibly, a list of fallback fonts.
52599         When we need to compute the width of the run to create the line box, we add
52600         all the measurements for the given renderer in the run to get the total width.
52601         This optiomization is currently disabled for platforms using HarfBuzz.
52602
52603         * platform/graphics/Font.cpp:
52604         (WebCore::Font::width): Added fallback fonts parameter.
52605         * platform/graphics/Font.h:
52606         (Font): Added fallback fonts parameter to the width static member function.
52607         This method is called when we compute the width using TextLayout.
52608         * platform/graphics/mac/ComplexTextController.cpp:
52609         (WebCore::TextLayout::width): Added fallback fonts parameter.
52610         (WebCore::Font::width):
52611         (WebCore::ComplexTextController::advance):
52612         * platform/graphics/mac/ComplexTextController.h:
52613         (ComplexTextController): Added fallback fonts parameter to advance method.
52614         * rendering/RenderBlock.h: Added WordMeasures parameter to few methods.
52615         * rendering/RenderBlockLineLayout.cpp:
52616         (WordMeasurement): Added new class to hold measurement information.
52617         (WebCore::setLogicalWidthForTextRun): This is where we compute the run width using the
52618         cached information.
52619         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine): Added wordMeasures parameter.
52620         (WebCore::RenderBlock::createLineBoxesFromBidiRuns): Added wordMeasures parameter.
52621         (WebCore::RenderBlock::layoutRunsAndFloatsInRange): Added declaration of the WordMeasures
52622         vector and its use.
52623         (WebCore::textWidth): Added fallbackFonts parameter, since now we only measure once.
52624         (WebCore::RenderBlock::LineBreaker::nextLineBreak): This method has been modified to collect
52625         the measurements of the individual words and add them to the vector.
52626
52627 2012-10-09  Andreas Kling  <kling@webkit.org>
52628
52629         GlyphPageTreeNode should use HashMap<OwnPtr>.
52630         <http://webkit.org/b/98845>
52631
52632         Reviewed by Dan Bernstein.
52633
52634         - Replace manual memory management by OwnPtrs.
52635         - Added a GlyphPageTreeNodeMap typedef to make call sites look a bit nicer.
52636         = Changed some hashmap get()/remove() pairs to use the more efficient take() instead.
52637         - Made the constructor private, it has no external clients.
52638
52639         * platform/graphics/GlyphPageTreeNode.cpp:
52640         (WebCore::GlyphPageTreeNode::getRoot):
52641         (WebCore::GlyphPageTreeNode::pageCount):
52642         (WebCore::GlyphPageTreeNode::getChild):
52643         (WebCore::GlyphPageTreeNode::pruneCustomFontData):
52644         (WebCore::GlyphPageTreeNode::pruneFontData):
52645         (WebCore::GlyphPageTreeNode::showSubtree):
52646         * platform/graphics/GlyphPageTreeNode.h:
52647         (GlyphPageTreeNode):
52648         (WebCore::GlyphPageTreeNode::GlyphPageTreeNode):
52649
52650 2012-10-09  Kent Tamura  <tkent@chromium.org>
52651
52652         Sub-fields in input[type=time] should not be focusable if the input is disabled or read-only
52653         https://bugs.webkit.org/show_bug.cgi?id=98850
52654
52655         Reviewed by Kentaro Hara.
52656
52657         Covered by additional test cases of
52658         time-multiple-fields/time-multiple-fields-keyboard-events.html and
52659         time-multiple-fields/time-multiple-fields-mouse-events.html.
52660
52661         * html/shadow/DateTimeFieldElement.h:
52662         (FieldOwner): Add isFieldOwnerDisabledOrReadOnly.
52663         * html/shadow/DateTimeFieldElement.cpp:
52664         (WebCore::DateTimeFieldElement::isFocusable):
52665         Check isFieldOwnerDisabledOrReadOnly, and calls HTMLElement::isFocusable()
52666         just in case.
52667         * html/shadow/DateTimeEditElement.cpp:
52668         (WebCore::DateTimeEditElement::isFieldOwnerDisabledOrReadOnly): Added.
52669         * html/shadow/DateTimeEditElement.h:
52670         (DateTimeEditElement): Declare isFieldOwnerDisabledOrReadOnly.
52671
52672 2012-10-09  Robert Kroeger  <rjkroege@chromium.org>
52673
52674         [chromium] revert fling deacceleration parameter change
52675         https://bugs.webkit.org/show_bug.cgi?id=98820
52676
52677         Reviewed by Adrienne Walker.
52678
52679         After an extended discussion, it has been decided that a previous
52680         adjustment to fling deacceleration parameters should be reverted.
52681
52682         Tested by existing unit tests.
52683
52684         * platform/TouchFlingPlatformGestureCurve.cpp:
52685         (WebCore::TouchFlingPlatformGestureCurve::createForTouchPad):
52686         (WebCore::TouchFlingPlatformGestureCurve::createForTouchScreen):
52687
52688 2012-10-09  Kent Tamura  <tkent@chromium.org>
52689
52690         Should reject invalid dates constructed with multiple fields UI
52691         https://bugs.webkit.org/show_bug.cgi?id=98727
52692
52693         Reviewed by Hajime Morita.
52694
52695         In input[type=date] with multiple fields UI, we allow users to set
52696         day-of-month value to 1-31 regardless of the month value. So users can
52697         construct an invalid date such as "2012-02-31". We should sanitize such
52698         values.
52699
52700         This change affects platforms with ENABLE_INPUT_TYPE_DATE &&
52701         ENABLE_INPUT_MULTIPLE_FIELDS_UI.
52702
52703         Test: fast/forms/date-multiple-fields/date-multiple-fields-keyboard-events.html
52704
52705         * html/BaseDateAndTimeInputType.h:
52706         (BaseDateAndTimeInputType): Make sanitizeValue protected to be called from
52707         BaseMultipleFieldsDateAndTimeInputType.
52708         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
52709         (WebCore::BaseMultipleFieldsDateAndTimeInputType::editControlValueChanged):
52710         Apply sanitizeValue to a value constructed in UI.
52711         (WebCore::BaseMultipleFieldsDateAndTimeInputType::restoreFormControlState):
52712         Ditto.
52713
52714 2012-10-09  Joe Mason  <jmason@rim.com>
52715
52716         Check for null m_frame in NetworkJob
52717         https://bugs.webkit.org/show_bug.cgi?id=98830
52718
52719         Reviewed by George Staikos.
52720
52721         PR 220025
52722
52723         * platform/network/blackberry/NetworkJob.cpp:
52724         (WebCore::NetworkJob::sendRequestWithCredentials):
52725         (WebCore::NetworkJob::storeCredentials):
52726
52727 2012-10-09  Jian Li  <jianli@chromium.org>
52728
52729         Update the CSS property used to support draggable regions.
52730         https://bugs.webkit.org/show_bug.cgi?id=97156
52731
52732         Reviewed by Adam Barth.
52733
52734         The CSS property to support draggable regions has been changed from
52735         "-webkit-widget-region" to "-webkit-app-region" in the following syntax:
52736            -webkit-app-region: drag|no-drag
52737
52738         The CSS parsing code for draggable regions is now different from the CSS
52739         parsing code for dashboard regions since we have quite different syntax.
52740
52741         We still try to share as much rendering update code as possible for
52742         these two features. To make the shared code easier to understand for
52743         both features, the name "DashboardRegions" in the shared code is changed
52744         to "AnnotatedRegions" to work for both dashboard regions and draggable
52745         regions.
52746
52747         Note that we still using WIDGET_REGION as feature name in order not to
52748         add more changes to this patch. It will be renamed to a more appropriate
52749         name in next patch. WIDGET_REGION is now only turned on for the chromium
52750         port.
52751
52752         Test: fast/css/draggable-region-parser.html
52753
52754         * Configurations/FeatureDefines.xcconfig: Disable WIDGET_REGION feature.
52755         * WebCore.exp.in: Update the exported symbol due to renaming.
52756         * css/CSSComputedStyleDeclaration.cpp: Update the CSS parsing.
52757         (WebCore):
52758         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
52759         * css/CSSParser.cpp: Update the CSS parsing.
52760         (WebCore::CSSParser::parseValue):
52761         (WebCore):
52762         (WebCore::CSSParser::parseDashboardRegions):
52763         * css/CSSParserValues.cpp: Update the CSS parsing.
52764         (WebCore::CSSParserValue::createCSSValue):
52765         * css/CSSPrimitiveValue.cpp: Update the CSS parsing.
52766         (WebCore::isValidCSSUnitTypeForDoubleConversion):
52767         (WebCore):
52768         (WebCore::CSSPrimitiveValue::cleanup):
52769         (WebCore::CSSPrimitiveValue::customCssText):
52770         (WebCore::CSSPrimitiveValue::cloneForCSSOM):
52771         (WebCore::CSSPrimitiveValue::reportDescendantMemoryUsage):
52772         * css/CSSPrimitiveValue.h: Update the CSS parsing.
52773         (CSSPrimitiveValue):
52774         * css/CSSProperty.cpp:
52775         (WebCore::CSSProperty::isInheritedProperty):
52776         * css/CSSPropertyNames.in: Rename the CSS property for draggable region.
52777         * css/CSSValueKeywords.in: Add the keywords supported for the draggable region.
52778         * css/DashboardRegion.h: Remove WIDGET_REGION guard.
52779         (DashboardRegion):
52780         * css/StyleResolver.cpp: Update the CSS parsing.
52781         (WebCore::StyleResolver::collectMatchingRulesForList):
52782         * dom/Document.cpp: Rename dashboardRegions to annotatedRegions.
52783         (WebCore::Document::Document):
52784         (WebCore::Document::annotatedRegions):
52785         (WebCore::Document::setAnnotatedRegions):
52786         (WebCore::Document::reportMemoryUsage):
52787         * dom/Document.h: Rename dashboardRegions to annotatedRegions.
52788         (WebCore):
52789         (WebCore::Document::setAnnotatedRegionsDirty):
52790         (WebCore::Document::annotatedRegionsDirty):
52791         (WebCore::Document::hasAnnotatedRegions):
52792         (WebCore::Document::setHasAnnotatedRegions):
52793         (Document):
52794         * page/Chrome.cpp: Rename dashboardRegions to annotatedRegions.
52795         (WebCore::ChromeClient::annotatedRegionsChanged):
52796         * page/ChromeClient.h: Rename dashboardRegions to annotatedRegions.
52797         (ChromeClient):
52798         * page/FrameView.cpp: Rename dashboardRegions to annotatedRegions.
52799         (WebCore::FrameView::layout):
52800         (WebCore::FrameView::updateAnnotatedRegions):
52801         (WebCore::FrameView::paintContents):
52802         * page/FrameView.h: Rename dashboardRegions to annotatedRegions.
52803         (FrameView):
52804         * rendering/RenderInline.cpp:
52805         (WebCore::RenderInline::addAnnotatedRegions):
52806         * rendering/RenderInline.h: Rename dashboardRegions to annotatedRegions.
52807         (RenderInline):
52808         * rendering/RenderLayer.cpp: Rename dashboardRegions to annotatedRegions.
52809         (WebCore::RenderLayer::scrollTo):
52810         (WebCore::RenderLayer::setHasHorizontalScrollbar):
52811         (WebCore::RenderLayer::setHasVerticalScrollbar):
52812         (WebCore::RenderLayer::updateScrollbarsAfterLayout):
52813         * rendering/RenderListBox.cpp: Rename dashboardRegions to annotatedRegions.
52814         (WebCore::RenderListBox::setHasVerticalScrollbar):
52815         * rendering/RenderObject.cpp: Rename dashboardRegions to annotatedRegions.
52816         (WebCore::RenderObject::styleWillChange):
52817         (WebCore::RenderObject::addAnnotatedRegions):
52818         (WebCore::RenderObject::collectAnnotatedRegions):
52819         * rendering/RenderObject.h: Rename dashboardRegions to annotatedRegions.
52820         (WebCore::AnnotatedRegionValue::operator==):
52821         (WebCore::AnnotatedRegionValue::operator!=):
52822         (AnnotatedRegionValue):
52823         (RenderObject):
52824         * rendering/style/RenderStyle.cpp: Update the CSS parsing.
52825         (WebCore::RenderStyle::diff):
52826         (WebCore):
52827         * rendering/style/RenderStyle.h: Update the CSS parsing.
52828         * rendering/style/RenderStyleConstants.h: Update the CSS parsing.
52829         * rendering/style/StyleDashboardRegion.h: Update the CSS parsing.
52830         * rendering/style/StyleRareNonInheritedData.cpp: Update the CSS parsing.
52831         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
52832         (WebCore::StyleRareNonInheritedData::operator==):
52833         * rendering/style/StyleRareNonInheritedData.h: Update the CSS parsing.
52834         (WebCore):
52835         (StyleRareNonInheritedData):
52836
52837 2012-10-09  Sheriff Bot  <webkit.review.bot@gmail.com>
52838
52839         Unreviewed, rolling out r130811 and r130821.
52840         http://trac.webkit.org/changeset/130811
52841         http://trac.webkit.org/changeset/130821
52842         https://bugs.webkit.org/show_bug.cgi?id=98831
52843
52844         Broke date-suggestion-picker-appearance-with-scroll-bar.html
52845         (Requested by abarth|gardening on #webkit).
52846
52847         * WebCore.exp.in:
52848         * dom/ContainerNode.cpp:
52849         (WebCore::ContainerNode::getUpperLeftCorner):
52850         (WebCore::ContainerNode::getLowerRightCorner):
52851         * dom/MouseRelatedEvent.cpp:
52852         (WebCore::MouseRelatedEvent::computeRelativePosition):
52853         * dom/Node.cpp:
52854         (WebCore::Node::convertToPage):
52855         (WebCore::Node::convertFromPage):
52856         * editing/FrameSelection.cpp:
52857         (WebCore::CaretBase::absoluteBoundsForLocalRect):
52858         * editing/RenderedPosition.cpp:
52859         (WebCore::RenderedPosition::absoluteRect):
52860         * editing/VisiblePosition.cpp:
52861         (WebCore::VisiblePosition::absoluteCaretBounds):
52862         * html/HTMLSelectElement.cpp:
52863         (WebCore::HTMLSelectElement::listBoxDefaultEventHandler):
52864         * html/shadow/SliderThumbElement.cpp:
52865         (WebCore::SliderThumbElement::setPositionFromPoint):
52866         * html/shadow/SpinButtonElement.cpp:
52867         (WebCore::SpinButtonElement::defaultEventHandler):
52868         * page/FrameView.cpp:
52869         (WebCore::FrameView::convertFromRenderer):
52870         (WebCore::FrameView::convertToRenderer):
52871         * rendering/InlineTextBox.cpp:
52872         (WebCore::InlineTextBox::paintDocumentMarker):
52873         (WebCore::InlineTextBox::paintTextMatchMarker):
52874         (WebCore::InlineTextBox::computeRectForReplacementMarker):
52875         * rendering/LayoutState.cpp:
52876         (WebCore::LayoutState::LayoutState):
52877         * rendering/RenderBlock.cpp:
52878         (WebCore::RenderBlock::absoluteQuads):
52879         * rendering/RenderBox.cpp:
52880         (WebCore::RenderBox::absoluteQuads):
52881         (WebCore::RenderBox::absoluteContentBox):
52882         (WebCore::RenderBox::mapLocalToContainer):
52883         (WebCore::RenderBox::mapAbsoluteToLocalPoint):
52884         * rendering/RenderBox.h:
52885         (RenderBox):
52886         * rendering/RenderBoxModelObject.cpp:
52887         (WebCore::RenderBoxModelObject::computeStickyPositionConstraints):
52888         (WebCore::RenderBoxModelObject::mapAbsoluteToLocalPoint):
52889         * rendering/RenderBoxModelObject.h:
52890         (RenderBoxModelObject):
52891         * rendering/RenderEmbeddedObject.cpp:
52892         (WebCore::RenderEmbeddedObject::isInUnavailablePluginIndicator):
52893         * rendering/RenderFrameSet.cpp:
52894         (WebCore::RenderFrameSet::userResize):
52895         * rendering/RenderGeometryMap.cpp:
52896         (WebCore::RenderGeometryMap::absolutePoint):
52897         * rendering/RenderInline.cpp:
52898         (WebCore::RenderInline::mapLocalToContainer):
52899         * rendering/RenderInline.h:
52900         (RenderInline):
52901         * rendering/RenderLayer.cpp:
52902         (WebCore::RenderLayer::absoluteToContents):
52903         (WebCore::RenderLayer::convertToLayerCoords):
52904         (WebCore::RenderLayer::scrollTo):
52905         (WebCore::RenderLayer::calculateClipRects):
52906         (WebCore::RenderLayer::childrenClipRect):
52907         (WebCore::RenderLayer::selfClipRect):
52908         * rendering/RenderLayerBacking.cpp:
52909         (WebCore::RenderLayerBacking::contentsVisible):
52910         * rendering/RenderMediaControls.cpp:
52911         (WebCore::RenderMediaControls::volumeSliderOffsetFromMuteButton):
52912         * rendering/RenderMenuList.cpp:
52913         (WebCore::RenderMenuList::showPopup):
52914         * rendering/RenderObject.cpp:
52915         (WebCore::RenderObject::absoluteFocusRingQuads):
52916         (WebCore::RenderObject::localToAbsolute):
52917         (WebCore::RenderObject::absoluteToLocal):
52918         (WebCore::RenderObject::mapLocalToContainer):
52919         (WebCore::RenderObject::mapAbsoluteToLocalPoint):
52920         (WebCore::RenderObject::localToContainerQuad):
52921         (WebCore::RenderObject::localToContainerPoint):
52922         * rendering/RenderObject.h:
52923         (RenderObject):
52924         (WebCore::RenderObject::localToAbsoluteQuad):
52925         * rendering/RenderText.cpp:
52926         (WebCore::RenderText::absoluteRectsForRange):
52927         (WebCore::RenderText::absoluteQuads):
52928         (WebCore::RenderText::absoluteQuadsForRange):
52929         * rendering/RenderTheme.cpp:
52930         (WebCore::RenderTheme::volumeSliderOffsetFromMuteButton):
52931         * rendering/RenderView.cpp:
52932         (WebCore::RenderView::mapLocalToContainer):
52933         (WebCore::RenderView::mapAbsoluteToLocalPoint):
52934         (WebCore::RenderView::selectionBounds):
52935         * rendering/RenderView.h:
52936         (RenderView):
52937         * rendering/RenderWidget.cpp:
52938         (WebCore::RenderWidget::updateWidgetGeometry):
52939         * rendering/svg/RenderSVGForeignObject.cpp:
52940         (WebCore::RenderSVGForeignObject::mapLocalToContainer):
52941         * rendering/svg/RenderSVGForeignObject.h:
52942         (RenderSVGForeignObject):
52943         * rendering/svg/RenderSVGInline.cpp:
52944         (WebCore::RenderSVGInline::mapLocalToContainer):
52945         * rendering/svg/RenderSVGInline.h:
52946         (RenderSVGInline):
52947         * rendering/svg/RenderSVGModelObject.cpp:
52948         (WebCore::RenderSVGModelObject::mapLocalToContainer):
52949         (WebCore::RenderSVGModelObject::absoluteQuads):
52950         * rendering/svg/RenderSVGModelObject.h:
52951         (RenderSVGModelObject):
52952         * rendering/svg/RenderSVGRoot.cpp:
52953         (WebCore::RenderSVGRoot::mapLocalToContainer):
52954         * rendering/svg/RenderSVGRoot.h:
52955         (RenderSVGRoot):
52956         * rendering/svg/RenderSVGText.cpp:
52957         (WebCore::RenderSVGText::mapLocalToContainer):
52958         (WebCore::RenderSVGText::absoluteQuads):
52959         * rendering/svg/RenderSVGText.h:
52960         (RenderSVGText):
52961         * rendering/svg/SVGRenderSupport.cpp:
52962         (WebCore::SVGRenderSupport::mapLocalToContainer):
52963         * svg/SVGSVGElement.cpp:
52964         (WebCore::SVGSVGElement::localCoordinateSpaceTransform):
52965
52966 2012-10-09  Sheriff Bot  <webkit.review.bot@gmail.com>
52967
52968         Unreviewed, rolling out r130812.
52969         http://trac.webkit.org/changeset/130812
52970         https://bugs.webkit.org/show_bug.cgi?id=98826
52971
52972         Caused fast/text/shaping/shaping-selection-rect to fail
52973         (Requested by abarth|gardening on #webkit).
52974
52975         * platform/graphics/Font.cpp:
52976         (WebCore::Font::width):
52977         * platform/graphics/Font.h:
52978         (Font):
52979         * platform/graphics/mac/ComplexTextController.cpp:
52980         (WebCore::TextLayout::width):
52981         (WebCore::Font::width):
52982         (WebCore::ComplexTextController::advance):
52983         * platform/graphics/mac/ComplexTextController.h:
52984         (ComplexTextController):
52985         * rendering/RenderBlock.h:
52986         (WebCore):
52987         (LineBreaker):
52988         (RenderBlock):
52989         * rendering/RenderBlockLineLayout.cpp:
52990         (WebCore::setLogicalWidthForTextRun):
52991         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine):
52992         (WebCore::RenderBlock::createLineBoxesFromBidiRuns):
52993         (WebCore::RenderBlock::layoutRunsAndFloatsInRange):
52994         (WebCore::textWidth):
52995         (WebCore::RenderBlock::LineBreaker::nextLineBreak):
52996
52997 2012-10-09  Ryosuke Niwa  <rniwa@webkit.org>
52998
52999         DOM/textarea-edit.html spends 35% of time in numGraphemeClusters
53000         https://bugs.webkit.org/show_bug.cgi?id=98711
53001
53002         Reviewed by Kent Tamura.
53003
53004         Since the number of characters is always greater than the number of grapheme clusters,
53005         we can avoid calling computeLengthForSubmission when the number of characters is less
53006         than maxlength. We still have to count the number of LFs since they all need to be
53007         converted into CRLFs. This improves WebKit's score on DOM/textarea-edit.html by 45%.
53008
53009         * html/HTMLTextAreaElement.cpp:
53010         (WebCore::computeLengthForSubmission):
53011         (WebCore::numberOfLineBreaks):
53012         (WebCore::upperBoundForLengthForSubmission): Added.
53013         (WebCore::HTMLTextAreaElement::handleBeforeTextInsertedEvent):
53014         (WebCore::HTMLTextAreaElement::tooLong):
53015
53016 2012-10-09  Nate Chapin  <japhet@chromium.org>
53017
53018         Make CachedResourceLoader RefCounted and have both Document
53019         and DocumentLoader hold RefPtrs. This is in preparation for
53020         caching main resources.
53021         https://bugs.webkit.org/show_bug.cgi?id=86787
53022
53023         Reviewed by Adam Barth.
53024
53025         No new tests, no functionality changes at this time.
53026
53027         * WebCore.exp.in:
53028         * WebCore.xcodeproj/project.pbxproj:
53029         * dom/Document.cpp:
53030         (WebCore::Document::Document): Only create our own CachedResourceLoader
53031             if we were given a null frame.
53032         (WebCore::Document::~Document):
53033         (WebCore::Document::cachedResourceLoader):
53034         (WebCore):
53035         * dom/Document.h:
53036         (Document):
53037         * loader/DocumentLoader.cpp: Throughout, use our m_cachedResourceLoader instead
53038             of the Document's pointer.
53039         (WebCore::DocumentLoader::DocumentLoader): Create a CachedResourceLoader.
53040         (WebCore::DocumentLoader::~DocumentLoader):
53041         (WebCore::DocumentLoader::isLoadingInAPISense):
53042         (WebCore::DocumentLoader::subresource):
53043         (WebCore::DocumentLoader::getSubresources):
53044         * loader/DocumentLoader.h:
53045         (WebCore::DocumentLoader::cachedResourceLoader):
53046         (DocumentLoader):
53047         * loader/SubresourceLoader.cpp: Remove m_document, since it only existed to keep alive and access the CachedResourceLoader.
53048             It can now be accessed from m_documentLoader.
53049         (WebCore::SubresourceLoader::SubresourceLoader):
53050         (WebCore::SubresourceLoader::~SubresourceLoader):
53051         (WebCore::SubresourceLoader::willSendRequest):
53052         (WebCore::SubresourceLoader::releaseResources):
53053         * loader/SubresourceLoader.h:
53054         (SubresourceLoader):
53055         * loader/cache/CachedResourceLoader.cpp: Handle the possibility of a null Document in several places.
53056         (WebCore::CachedResourceLoader::CachedResourceLoader):
53057         (WebCore::CachedResourceLoader::~CachedResourceLoader):
53058         (WebCore::CachedResourceLoader::frame):
53059         (WebCore::CachedResourceLoader::canRequest):
53060         (WebCore::CachedResourceLoader::determineRevalidationPolicy):
53061         (WebCore::CachedResourceLoader::printAccessDeniedMessage):
53062         (WebCore::CachedResourceLoader::loadDone):
53063         * loader/cache/CachedResourceLoader.h:
53064         (WebCore):
53065         (WebCore::CachedResourceLoader::create): Add create(), make constructor private.
53066         (CachedResourceLoader):
53067         (WebCore::CachedResourceLoader::document):
53068         (WebCore::CachedResourceLoader::setDocument):
53069         (WebCore::CachedResourceLoader::clearDocumentLoader):
53070
53071 2012-10-09  Alexander Shalamov  <alexander.shalamov@intel.com>
53072
53073         CSS Style is not recalculated when media attribute of style element is changed
53074         https://bugs.webkit.org/show_bug.cgi?id=96752
53075
53076         Reviewed by Kenneth Rohde Christiansen.
53077
53078         When "media" attribute of style element is changed, style should be recalculated.
53079         This patch modifies HTMLStyleElement::parseAttribute, so that when the media attribute
53080         is updated, new MediaQuerySet is created and applied to the style element then, document
53081         style is recalculated. Since media query set is updated for CSSStyleSheet, CSSOM wrapper
53082         for media query should be updated as well in order to sync with new media query set value.
53083
53084         Test: fast/media/mq-js-update-media.html
53085
53086         * css/CSSStyleSheet.cpp:
53087         (WebCore::CSSStyleSheet::setMediaQueries):
53088         * html/HTMLStyleElement.cpp:
53089         (WebCore::HTMLStyleElement::parseAttribute):
53090
53091 2012-10-09  Ben Murdoch  <benm@google.com>
53092
53093         [chromium][Android] Add WebSecurityOrigin::grantLoadLocalResources()
53094         https://bugs.webkit.org/show_bug.cgi?id=97689
53095
53096         Reviewed by Adam Barth.
53097
53098         In addition to the WebKit/chromium side of the change, remove the
53099         ASSERT in SecurityOrigin::grantLoadLocalResources(). Android WebView
53100         is a legitimate user of this API in cases where neither of the
53101         ASSERT'd conditions hold.
53102
53103         * page/SecurityOrigin.cpp:
53104         (WebCore::SecurityOrigin::grantLoadLocalResources): Remove ASSERT.
53105
53106 2012-10-09  Jon Lee  <jonlee@apple.com>
53107
53108         Build fix for Qt Windows.
53109
53110         * html/HTMLPlugInElement.h: Include Image.h.
53111
53112 2012-10-09  Enrica Casucci  <enrica@apple.com>
53113
53114         Only measure text once instead of twice when performing line layout.
53115         https://bugs.webkit.org/show_bug.cgi?id=98317
53116         <rdar://problem/12080821>
53117
53118         Reviewed by Dan Bernstein.
53119
53120         Since we are measuring each word to find out where the line break should occur,
53121         we should cache that information to avoid measuring the run again when
53122         creating the line box. The bulk of the change is in nextLineBreak, where
53123         the measurements are collected and placed in a vector so that they can
53124         be consumed in setLogicalWidthForTextRun where we used to measure the
53125         text one more time.
53126         Each entry in the vector is a WordMeasurement object that contains information
53127         about the start and end offset in the run, the renderer, the measured width
53128         and, possibly, a list of fallback fonts.
53129         When we need to compute the width of the run to create the line box, we add
53130         all the measurements for the given renderer in the run to get the total width.
53131
53132         * platform/graphics/Font.cpp:
53133         (WebCore::Font::width): Added fallback fonts parameter.
53134         * platform/graphics/Font.h:
53135         (Font): Added fallback fonts parameter to the width static member function.
53136         This method is called when we compute the width using TextLayout.
53137         * platform/graphics/mac/ComplexTextController.cpp:
53138         (WebCore::TextLayout::width): Added fallback fonts parameter.
53139         (WebCore::Font::width):
53140         (WebCore::ComplexTextController::advance):
53141         * platform/graphics/mac/ComplexTextController.h:
53142         (ComplexTextController): Added fallback fonts parameter to advance method.
53143         * rendering/RenderBlock.h: Added WordMeasures parameter to few methods.
53144         * rendering/RenderBlockLineLayout.cpp:
53145         (WordMeasurement): Added new class to hold measurement information.
53146         (WebCore::setLogicalWidthForTextRun): This is where we compute the run width using the
53147         cached information.
53148         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine): Added wordMeasures parameter.
53149         (WebCore::RenderBlock::createLineBoxesFromBidiRuns): Added wordMeasures parameter.
53150         (WebCore::RenderBlock::layoutRunsAndFloatsInRange): Added declaration of the WordMeasures
53151         vector and its use.
53152         (WebCore::textWidth): Added fallbackFonts parameter, since now we only measure once.
53153         (WebCore::RenderBlock::LineBreaker::nextLineBreak): This method has been modified to collect
53154         the measurements of the individual words and add them to the vector.
53155
53156 2012-10-09  Levi Weintraub  <leviw@chromium.org>
53157
53158         [Sub pixel layout] Fast-path iframe scrolling can picks up an extra pixel
53159         https://bugs.webkit.org/show_bug.cgi?id=98571
53160
53161         Reviewed by Emil A Eklund.
53162
53163         Refactoring all coordinate-switching functionality to use a single "mode" flag
53164         as opposed to having a bunch of boolean values. This enables the same set of
53165         options across the board, and a consistent interface. This was previously
53166         done for mapLocalToContainer.
53167
53168         The imptetus for this for this stems from the one logical change in this patch
53169         which only effects sub-pixel layout. FrameView::convertToRenderer and
53170         convertFromRenderer return IntPoint coordinates, and need to also snap transform
53171         offsets to determine proper rects for scrolling.
53172
53173         Unlabeled functions below are simply being updated to these new interfaces.
53174
53175         Test: fast/sub-pixel/sub-pixel-iframe-copy-on-scroll.html
53176
53177         * WebCore.exp.in:
53178         * dom/ContainerNode.cpp:
53179         (WebCore::ContainerNode::getUpperLeftCorner):
53180         (WebCore::ContainerNode::getLowerRightCorner):
53181         * dom/Element.cpp:
53182         (WebCore::Element::boundsInRootViewSpace):
53183         * dom/MouseRelatedEvent.cpp:
53184         (WebCore::MouseRelatedEvent::computeRelativePosition):
53185         * dom/Node.cpp:
53186         (WebCore::Node::convertToPage):
53187         (WebCore::Node::convertFromPage):
53188         * html/HTMLSelectElement.cpp:
53189         (WebCore::HTMLSelectElement::listBoxDefaultEventHandler):
53190         * html/shadow/SliderThumbElement.cpp:
53191         (WebCore::SliderThumbElement::setPositionFromPoint):
53192         * html/shadow/SpinButtonElement.cpp:
53193         (WebCore::SpinButtonElement::defaultEventHandler):
53194         * page/FrameView.cpp:
53195         (WebCore::FrameView::convertToRenderer): Now pixel-snaps offsets before passing
53196         them to TransformState, which transforms the coordinates.
53197         (WebCore::FrameView::convertFromRenderer): Ditto.
53198         * rendering/LayoutState.cpp:
53199         (WebCore::LayoutState::LayoutState):
53200         * rendering/RenderBlock.cpp:
53201         (WebCore::RenderBlock::absoluteQuads):
53202         * rendering/RenderBox.cpp:
53203         (WebCore::RenderBox::absoluteQuads):
53204         (WebCore::RenderBox::mapLocalToContainer):
53205         (WebCore::RenderBox::mapAbsoluteToLocalPoint):
53206         * rendering/RenderBox.h:
53207         (RenderBox):
53208         * rendering/RenderBoxModelObject.cpp:
53209         (WebCore::RenderBoxModelObject::mapAbsoluteToLocalPoint):
53210         * rendering/RenderBoxModelObject.h:
53211         (RenderBoxModelObject):
53212         * rendering/RenderEmbeddedObject.cpp:
53213         (WebCore::RenderEmbeddedObject::isInUnavailablePluginIndicator):
53214         * rendering/RenderFrameSet.cpp:
53215         (WebCore::RenderFrameSet::userResize):
53216         * rendering/RenderGeometryMap.cpp:
53217         (WebCore::RenderGeometryMap::absolutePoint):
53218         * rendering/RenderInline.cpp:
53219         (WebCore::RenderInline::mapLocalToContainer):
53220         * rendering/RenderInline.h:
53221         (RenderInline):
53222         * rendering/RenderLayer.cpp:
53223         (WebCore::RenderLayer::absoluteToContents):
53224         (WebCore::RenderLayer::calculateClipRects):
53225         * rendering/RenderMediaControls.cpp:
53226         (WebCore::RenderMediaControls::volumeSliderOffsetFromMuteButton):
53227         * rendering/RenderMenuList.cpp:
53228         (WebCore::RenderMenuList::showPopup):
53229         * rendering/RenderObject.cpp:
53230         (WebCore::RenderObject::localToAbsolute):
53231         (WebCore::RenderObject::absoluteToLocal):
53232         (WebCore::RenderObject::mapLocalToContainer):
53233         (WebCore::RenderObject::mapAbsoluteToLocalPoint):
53234         (WebCore::RenderObject::localToContainerQuad):
53235         (WebCore::RenderObject::localToContainerPoint):
53236         * rendering/RenderObject.h:
53237         (RenderObject): MapLocalToContainerFlags is now MapCoordinatesFlags since it's
53238         now used for other conversion methods.
53239         (WebCore::RenderObject::localToAbsoluteQuad):
53240         * rendering/RenderTheme.cpp:
53241         (WebCore::RenderTheme::volumeSliderOffsetFromMuteButton):
53242         * rendering/RenderView.cpp:
53243         (WebCore::RenderView::mapLocalToContainer):
53244         (WebCore::RenderView::mapAbsoluteToLocalPoint):
53245         * rendering/RenderView.h:
53246         (RenderView):
53247         * rendering/svg/RenderSVGForeignObject.cpp:
53248         (WebCore::RenderSVGForeignObject::mapLocalToContainer):
53249         * rendering/svg/RenderSVGForeignObject.h:
53250         (RenderSVGForeignObject):
53251         * rendering/svg/RenderSVGInline.cpp:
53252         (WebCore::RenderSVGInline::mapLocalToContainer):
53253         * rendering/svg/RenderSVGInline.h:
53254         (RenderSVGInline):
53255         * rendering/svg/RenderSVGModelObject.cpp:
53256         (WebCore::RenderSVGModelObject::mapLocalToContainer):
53257         * rendering/svg/RenderSVGModelObject.h:
53258         (RenderSVGModelObject):
53259         * rendering/svg/RenderSVGRoot.cpp:
53260         (WebCore::RenderSVGRoot::mapLocalToContainer):
53261         * rendering/svg/RenderSVGRoot.h:
53262         (RenderSVGRoot):
53263         * rendering/svg/RenderSVGText.cpp:
53264         (WebCore::RenderSVGText::mapLocalToContainer):
53265         * rendering/svg/RenderSVGText.h:
53266         (RenderSVGText):
53267         * rendering/svg/SVGRenderSupport.cpp:
53268         (WebCore::SVGRenderSupport::mapLocalToContainer):
53269         * svg/SVGSVGElement.cpp:
53270         (WebCore::SVGSVGElement::localCoordinateSpaceTransform):
53271
53272 2012-10-09  Jon Lee  <jonlee@apple.com>
53273
53274         [WK2] Have plugins render offscreen to capture snapshot
53275         https://bugs.webkit.org/show_bug.cgi?id=98326
53276         <rdar://problem/12426658>
53277
53278         Reviewed by Simon Fraser.
53279
53280         Change updateSnapshot() to use a PassRefPtr<Image> instead of Image*. WebKit2 ultimately
53281         hands the image off to RenderSnapshottedPlugin. A CachedImage instance then manages the
53282         lifetime of the Image.
53283
53284         * html/HTMLPlugInElement.h:
53285         (WebCore::HTMLPlugInElement::updateSnapshot):
53286         * html/HTMLPlugInImageElement.cpp:
53287         (WebCore::HTMLPlugInImageElement::updateSnapshot):
53288         * html/HTMLPlugInImageElement.h:
53289         (HTMLPlugInImageElement):
53290         * rendering/RenderSnapshottedPlugIn.cpp:
53291         (WebCore::RenderSnapshottedPlugIn::updateSnapshot): Updated to use the PassRefPtr<Image>
53292         pointer.
53293         * rendering/RenderSnapshottedPlugIn.h:
53294         (RenderSnapshottedPlugIn):
53295
53296 2012-10-09  Adam Barth  <abarth@webkit.org>
53297
53298         Unreviewed. Move this file to where the build systems think it should
53299         be. See https://bugs.webkit.org/show_bug.cgi?id=94755
53300
53301         * platform/graphics/CustomFilterConstants.h: Removed.
53302         * platform/graphics/filters/CustomFilterConstants.h: Copied from Source/WebCore/platform/graphics/CustomFilterConstants.h.
53303
53304 2012-10-09  Tony Chang  <tony@chromium.org>
53305
53306         Use computeLogical* methods instead of updateLogical* methods in RenderImage
53307         https://bugs.webkit.org/show_bug.cgi?id=98802
53308
53309         Reviewed by Eric Seidel.
53310
53311         We were storing the old values of width/height, calling updateLogical{Width,Height}, then restoring
53312         the old values.  Instead, use the computeLogical{Width,Height} methods so we don't have to overwrite
53313         the current values.
53314
53315         No new tests, this is just a refactoring.
53316
53317         * rendering/RenderImage.cpp:
53318         (WebCore::RenderImage::imageDimensionsChanged):
53319
53320 2012-10-09  Enrica Casucci  <enrica@apple.com>
53321
53322         [chromium] fast/text/international/text-spliced-font.html and fast/writing-mode/Kusa-Makura-
53323         background-canvas.html failing on the Mac after r130443
53324         https://bugs.webkit.org/show_bug.cgi?id=98545
53325
53326         Reviewed by Tony Chang.
53327
53328         Adding back the ! removed by mistake before submitting r130779. 
53329
53330         * platform/graphics/FontFastPath.cpp:
53331         (WebCore::Font::glyphDataAndPageForCharacter):
53332
53333 2012-10-09  Artem Simonov  <asimonov@rim.com>
53334
53335         [BlackBerry] EGL Context deleted prematurely in GraphicsContext3D destructor
53336         https://bugs.webkit.org/show_bug.cgi?id=98796
53337
53338         Reviewed by George Staikos.
53339
53340         Reordered destruction of GraphicsContext3D so that the compositing layer is
53341         destroyed first.
53342
53343         * platform/graphics/blackberry/GraphicsContext3DBlackBerry.cpp:
53344         (WebCore::GraphicsContext3D::~GraphicsContext3D):
53345
53346 2012-10-09  Ben Wagner  <bungeman@chromium.org>
53347
53348         Disable hinting when webkit-font-smoothing:antialiased is used on Mac.
53349         https://bugs.webkit.org/show_bug.cgi?id=98061
53350
53351         Reviewed by Stephen White.
53352
53353         Normal anti-aliased text matches subpixel anti-aliased text.
53354         However, text marked with webkit-font-smoothing:antialiased should be drawn without hinting to match Safari.
53355         See crbug.com/152304 . 
53356
53357         Test is fast/css/font-smoothing.html, but DRT runs with font smoothing disabled, so no change visible. 
53358
53359         * platform/graphics/skia/FontSkia.cpp:
53360         (WebCore::setupPaint):
53361         Set kNo_Hinting when webkit-font-smoothing is antialiased.
53362
53363 2012-10-09  Max Vujovic  <mvujovic@adobe.com>
53364
53365         [CSS Shaders] Create constants for vertex attribute sizes and offsets
53366         https://bugs.webkit.org/show_bug.cgi?id=94755
53367
53368         Reviewed by Dean Jackson.
53369
53370         Factor out the vertex attribute size and offset constants into a new file,
53371         CustomFilterConstants.h. Replace literals in CustomFilterMeshGenerator with the constants.
53372
53373         I could have added the constants to CustomFilterMeshGenerator.h, but this would make
53374         FECustomFilter depend on CustomFilterMeshGenerator.
53375
53376         I also could have added the constants to CustomFilterMesh.h, but this would make
53377         CustomFilterMeshGenerator depend on CustomFilterMesh.
53378
53379         No new tests. No change in behavior.
53380
53381         * GNUmakefile.list.am:
53382         * Target.pri:
53383         * WebCore.gypi:
53384         * WebCore.vcproj/WebCore.vcproj:
53385         * WebCore.xcodeproj/project.pbxproj:
53386         * platform/graphics/CustomFilterConstants.h: Added.
53387         (WebCore):
53388         * platform/graphics/filters/CustomFilterMeshGenerator.h:
53389         (WebCore::CustomFilterMeshGenerator::floatsPerVertex):
53390             Use the new constants instead of literal values.
53391         * platform/graphics/filters/FECustomFilter.cpp:
53392         (WebCore::FECustomFilter::bindProgramAndBuffers):
53393             Pull the constant definitions out of here.
53394
53395 2012-10-09  Michael Saboff  <msaboff@apple.com>
53396
53397         MarkupAccumulator should optimally handle 8 bit Strings
53398         https://bugs.webkit.org/show_bug.cgi?id=98224
53399
53400         Reviewed by Ryosuke Niwa.
53401
53402         Updated appendCharactersReplacingEntities to take a string, offset and length and process 8 or 16 bit
53403         data as appropriate.  Also made it a member function of MarkupAccumulator.
53404
53405         No new tests, behavior covered by existing tests.
53406
53407         * editing/MarkupAccumulator.cpp:
53408         (WebCore::MarkupAccumulator::appendCharactersReplacingEntities):
53409         (WebCore::MarkupAccumulator::appendAttributeValue):
53410         (WebCore::MarkupAccumulator::appendNodeValue):
53411         * editing/MarkupAccumulator.h:
53412         (MarkupAccumulator):
53413         * editing/markup.cpp:
53414         (WebCore::StyledMarkupAccumulator::appendText):
53415         (WebCore::urlToMarkup):
53416
53417 2012-10-09  Joshua Bell  <jsbell@chromium.org>
53418
53419         IndexedDB: Overflowing key generator should throw ConstraintError
53420         https://bugs.webkit.org/show_bug.cgi?id=98807
53421
53422         Reviewed by Tony Chang.
53423
53424         After the WebKit implementation landed throwing DataError, public-webapps
53425         consensus was that the exception thrown should be ConstraintError. Trivial
53426         change, and we pass one more W3C test submission.
53427
53428         Test: storage/indexeddb/key-generator.html
53429
53430         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
53431         (WebCore::IDBObjectStoreBackendImpl::putInternal):
53432
53433 2012-10-08  Martin Robinson  <mrobinson@igalia.com>
53434
53435         Fix the order of the statements in my previous build fix.
53436
53437         Reviewed by Gustavo Noronha Silva.
53438
53439         My previous build build fix for ResourceHandleSoup ordered the assignment
53440         of the local ResourceHandleInternal incorrectly. Instead of being before
53441         both assertions, it should be interspersed among them.
53442
53443         * platform/network/soup/ResourceHandleSoup.cpp:
53444         (WebCore::createSoupMessageForHandleAndRequest):
53445
53446 2012-10-09  Beth Dakin  <bdakin@apple.com>
53447
53448         https://bugs.webkit.org/show_bug.cgi?id=98457
53449         ScrollingStateNodes should be referenced via IDs on 
53450         RenderLayerBacking
53451
53452         Reviewed by Simon Fraser.
53453
53454         This patch associates all ScrollingStateNodes with a 
53455         RenderLayerBacking via a HashMap from RenderLayerBackings to 
53456         ScrollingStateNodes on ScrollingCoordinator. Prior to this patch, the 
53457         root ScrollingStateNode was created immediately upon creation of the 
53458         ScrollingCoordinator, and it was constantly re-used for every main 
53459         FrameView. This doesn't work in the new model since that doesn't 
53460         allow that ScrollingStateNode to have a definite association with a 
53461         RenderLayerBacking. So this patch does also introduce some lifetime 
53462         differences with the ScrollingStateNodes.
53463
53464         If a page is going into the page cache, we should clear the state 
53465         tree. When the page is in the cache, we won't have access to the 
53466         RenderLayerBacking, and we don't want to be doing anything with the 
53467         ScrollingStateNodes anyway.
53468         * dom/Document.cpp:
53469         (WebCore::Document::setInPageCache):
53470
53471         When a page is restored from the page cache, call 
53472         frameViewRootLayerDidChange() to re-create the state tree.
53473         * loader/HistoryController.cpp:
53474         (WebCore::HistoryController::restoreScrollPositionAndViewState):
53475
53476         This new FrameView function will return the scrollLayerID for a given FrameView.
53477         * page/FrameView.cpp:
53478         (WebCore::FrameView::scrollLayerID):
53479         (WebCore):
53480         * page/FrameView.h:
53481         (FrameView):
53482
53483         There is a lot of unfortunate fiddling with the terrible 
53484         if-defs in ScrollingCoordinator. I added a FIXME to the header
53485         noting how we can avoid this in the future.
53486         * page/scrolling/ScrollingCoordinator.cpp:
53487
53488         All of this code used to refer to the rootStateNode directly. 
53489         Instead, now it looks up the proper ScrollingStateNode for the given 
53490         FrameView in the HashMap.
53491         (WebCore::ScrollingCoordinator::frameViewLayoutUpdated):
53492         (WebCore::ScrollingCoordinator::frameViewWheelEventHandlerCountChanged):
53493         (WebCore::ScrollingCoordinator::frameViewRootLayerDidChange):
53494         (WebCore::ScrollingCoordinator::requestScrollPositionUpdate):
53495         (WebCore::ScrollingCoordinator::updateMainFrameScrollLayerPosition):
53496         (WebCore::ScrollingCoordinator::recomputeWheelEventHandlerCountForFrameView):
53497         (WebCore::ScrollingCoordinator::setScrollLayerForNode):
53498         (WebCore::ScrollingCoordinator::setNonFastScrollableRegionForNode):
53499         (WebCore::ScrollingCoordinator::setScrollParametersForNode):
53500         (WebCore::ScrollingCoordinator::setWheelEventHandlerCountForNode):
53501
53502         Returns the existing ScrollingStateNode for a given FrameView by 
53503         looking it up in the HashMap.
53504         (WebCore::ScrollingCoordinator::stateNodeForFrameView):
53505
53506         This is called when a RenderLayerBacking is destroyed. At that time, 
53507         its associated ScrollingStateNode is destroyed.
53508         (WebCore::ScrollingCoordinator::detachFromStateTree):
53509
53510         clearStateTree() clears the HashMap and destroys all of the nodes in 
53511         the current state tree.
53512         (WebCore::ScrollingCoordinator::clearStateTree):
53513
53514         Creates a new root state node for the given FrameView.
53515         (WebCore::ScrollingCoordinator::ensureRootStateNodeForFrameView):
53516
53517         Some new functions for the new node stuff.
53518         * page/scrolling/ScrollingCoordinator.h:
53519         * page/scrolling/ScrollingCoordinatorNone.cpp:
53520         (WebCore::ScrollingCoordinator::setShouldUpdateScrollLayerPositionOnMainThread):
53521         (WebCore::ScrollingCoordinator::supportsFixedPositionLayers):
53522         (WebCore::ScrollingCoordinator::setLayerIsContainerForFixedPositionLayers):
53523         (WebCore::ScrollingCoordinator::setLayerIsFixedToContainerLayer):
53524         (WebCore::ScrollingCoordinator::scrollableAreaScrollLayerDidChange):
53525         (WebCore::ScrollingCoordinator::detachFromStateTree):
53526         (WebCore::ScrollingCoordinator::clearStateTree):
53527         (WebCore::ScrollingCoordinator::ensureRootStateNodeForFrameView):
53528         (WebCore::setScrollParameters):
53529         (WebCore::setWheelEventHandlerCount):
53530
53531         New remove functions are used when the sate tree is cleared and when 
53532         a RenderLayerBacking is destroyed.
53533         * page/scrolling/ScrollingStateNode.cpp:
53534         (WebCore::ScrollingStateNode::removeChild):
53535         (WebCore):
53536         * page/scrolling/ScrollingStateNode.h:
53537         (WebCore::ScrollingStateNode::isScrollingStateScrollingNode):
53538         (ScrollingStateNode):
53539         (WebCore::ScrollingStateNode::parent):
53540
53541         New convenience function for casting to ScrollingStateScrollingNodes.
53542         * page/scrolling/ScrollingStateScrollingNode.h:
53543         (WebCore::toScrollingStateScrollingNode):
53544         (WebCore):
53545
53546         No longer automatically create a root node upon creation of the 
53547         ScrollingStateTree. We now want to wait to create the root node until 
53548         we have a RenderLayerBacking to associate it with.
53549         * page/scrolling/ScrollingStateTree.cpp:
53550         (WebCore::ScrollingStateTree::ScrollingStateTree):
53551         (WebCore::ScrollingStateTree::removeNode):
53552         (WebCore):
53553         * page/scrolling/ScrollingStateTree.h:
53554         (WebCore::ScrollingStateTree::setRootStateNode):
53555         (ScrollingStateTree):
53556
53557         RenderLayerBacking has a new data member called m_scrollLayerID. If 
53558         this RenderLayerBacking is represented in the scrolling tree, then 
53559         the ID with be unique and non-zero. 
53560         * rendering/RenderLayerBacking.cpp:
53561         (WebCore::RenderLayerBacking::RenderLayerBacking):
53562         (WebCore::RenderLayerBacking::~RenderLayerBacking):
53563         (WebCore::generateScrollLayerID):
53564         (WebCore):
53565         (WebCore::RenderLayerBacking::attachToScrollingCoordinator):
53566         (WebCore::RenderLayerBacking::detachFromScrollingCoordinator):
53567         * rendering/RenderLayerBacking.h:
53568         (RenderLayerBacking):
53569         (WebCore::RenderLayerBacking::scrollLayerID):
53570
53571         Move the call to ScrollingCooridinator::frameViewRootLayerDidChange() 
53572         from RenderLayerCompositor::attachRootLayer() to 
53573         RenderLayerCompositor:: updateBacking(). The problem with the old call 
53574         site is that there is no backing at that time, so we are trying to set 
53575         state on the root scrolling state node before we have enough 
53576         information to create that node and add it to the HashMap.
53577         * rendering/RenderLayerCompositor.cpp:
53578         (WebCore::RenderLayerCompositor::updateBacking):
53579         (WebCore::RenderLayerCompositor::attachRootLayer):
53580
53581 2012-10-09  Florin Malita  <fmalita@chromium.org>
53582
53583         SVGResources should use HashSet<AtomicString> instead of HashSet<AtomicStringImpl*>
53584         https://bugs.webkit.org/show_bug.cgi?id=98683
53585
53586         Reviewed by Darin Adler.
53587
53588         Eric's notes:
53589
53590         SVGResources should use HashSet<AtomicString> instead of HashSet<AtomicStringImpl*>
53591         They do basically the same thing, and the former is much more common (and less code). It's
53592         also safe, on the off-chance that we're using AtomicStrings which might otherwise go away.
53593
53594         No new tests, refactoring. 
53595
53596         * rendering/svg/SVGResources.cpp:
53597         (WebCore::clipperFilterMaskerTags):
53598         (WebCore::markerTags):
53599         (WebCore::fillAndStrokeTags):
53600         (WebCore::chainableResourceTags):
53601         (WebCore::SVGResources::buildCachedResources):
53602
53603 2012-10-09  Enrica Casucci  <enrica@apple.com>
53604
53605         [chromium] fast/text/international/text-spliced-font.html and fast/writing-mode/Kusa-Makura-background-canvas.html
53606         failing on the Mac after r130443
53607         https://bugs.webkit.org/show_bug.cgi?id=98545
53608
53609         Reviewed by Tony Chang.
53610
53611         Fixes a regression introduced with r130443.
53612         No new tests added since we already have tests covering this.
53613         Updated TestExpectations for chromium and mac.
53614
53615         * platform/graphics/FontFastPath.cpp:
53616         (WebCore::Font::glyphDataAndPageForCharacter): Text orientation should not be
53617         taken into account if the character is an ideograph or a symbol.
53618
53619 2012-10-09  Philip Rogers  <pdr@google.com>
53620
53621         Prevent animation when CSS attributeType is invalid.
53622         https://bugs.webkit.org/show_bug.cgi?id=94569
53623
53624         Reviewed by Dirk Schulze.
53625
53626         This patch changes hasValidAttributeType() to return false when
53627         we have attributeType=CSS with a non-CSS attribute name.
53628
53629         Previously we would animate non-CSS attributes when attributeType was
53630         CSS which resulted in crashes. To track this case, this patch catches
53631         changes to targetElement, attributeName, and attributeType and checks
53632         if an invalid combination is present. If invalid, hasInvalidCSSAttributeType()
53633         will return true causing hasValidAttributeType() to return false and prevent
53634         the animation from running.
53635
53636         Tests: svg/animations/animate-css-xml-attributeType.html
53637                svg/animations/invalid-css-attribute-crash-expected.svg
53638                svg/animations/invalid-css-attribute-crash.svg
53639
53640         * svg/SVGAnimateElement.cpp:
53641         (WebCore::SVGAnimateElement::hasValidAttributeType):
53642         (WebCore::SVGAnimateElement::targetElementWillChange):
53643         * svg/SVGAnimationElement.cpp:
53644         (WebCore::SVGAnimationElement::SVGAnimationElement):
53645         (WebCore::SVGAnimationElement::isSupportedAttribute):
53646
53647             This now supports the attributeType attribute which is stored in m_attributeType.
53648
53649         (WebCore::SVGAnimationElement::parseAttribute):
53650         (WebCore::SVGAnimationElement::setAttributeType):
53651
53652             Changes to attributeType, attributeName, and targetElement need to be tracked
53653             to determine when an invalid combination happens.
53654
53655         (WebCore::SVGAnimationElement::targetElementWillChange):
53656         (WebCore):
53657         (WebCore::SVGAnimationElement::setAttributeName):
53658         (WebCore::SVGAnimationElement::checkInvalidCSSAttributeType):
53659         * svg/SVGAnimationElement.h:
53660         (WebCore::SVGAnimationElement::attributeType):
53661         (SVGAnimationElement):
53662         (WebCore::SVGAnimationElement::hasInvalidCSSAttributeType):
53663         * svg/animation/SVGSMILElement.cpp:
53664         (WebCore::SVGSMILElement::targetElement):
53665         * svg/animation/SVGSMILElement.h:
53666         (SVGSMILElement):
53667
53668 2012-10-09  Pravin D  <pravind.2k4@gmail.com>
53669
53670         max-width property is does not overriding the width properties for css tables(display:table)
53671         https://bugs.webkit.org/show_bug.cgi?id=98455
53672
53673         Reviewed by Tony Chang.
53674
53675         The max-width property determines the maximum computed width an element can have. In case of css tables(display:table),
53676         the computed was not being limited by the max-width property. The current patch fixes this issue.
53677
53678         Test: fast/table/css-table-max-width.html
53679
53680         * rendering/RenderTable.cpp:
53681         (WebCore::RenderTable::updateLogicalWidth):
53682          Logic to compute the logical width of an element such that it does not exceed the max-width value.
53683          Also when both min-width and max-width are present, the following contraint is used to compute the logical width:
53684            1) min-width < Computed LogicalWidth < max-width, when min-width < max-width.
53685            2) Computed LogicalWidth = min-width, when min-width > max-width.
53686
53687 2012-10-09  Harald Alvestrand  <hta@google.com>
53688
53689         Change PeerConnection getStats function to single value local / remote
53690         elements in RTCStatsReport.
53691
53692         https://bugs.webkit.org/show_bug.cgi?id=98753
53693
53694         Reviewed by Adam Barth.
53695
53696         IDL of RTCStatsReport has been changed to make local/remote
53697         single valued RTCStatsElement attributes.
53698         The RTCStatsReport argument to index the list of RTCStatsElement
53699         in the local and remote functions has been removed.
53700
53701         Tested by modifications to RTCPeerConnection-stats.html
53702
53703         * Modules/mediastream/RTCStatsReport.cpp:
53704         (WebCore::RTCStatsReport::addElement):
53705         (WebCore::RTCStatsReport::addStatistic):
53706         * Modules/mediastream/RTCStatsReport.h:
53707         (WebCore::RTCStatsReport::local):
53708         (WebCore::RTCStatsReport::remote):
53709         (RTCStatsReport):
53710         * Modules/mediastream/RTCStatsReport.idl:
53711         * Modules/mediastream/RTCStatsResponse.cpp:
53712         (WebCore::RTCStatsResponse::addElement):
53713         (WebCore::RTCStatsResponse::addStatistic):
53714         * Modules/mediastream/RTCStatsResponse.h:
53715         (RTCStatsResponse):
53716         * platform/chromium/support/WebRTCStatsResponse.cpp:
53717         (WebKit::WebRTCStatsResponse::addElement):
53718         (WebKit::WebRTCStatsResponse::addStatistic):
53719         * platform/mediastream/RTCStatsResponseBase.h:
53720         (RTCStatsResponseBase):
53721
53722 2012-10-09  Antonio Gomes  <agomes@rim.com>
53723
53724         Get rid of FIXED_POSITION_CREATES_STACKING_CONTEXT in favor of Settings::fixedPositionCreatesStackingContext()
53725         https://bugs.webkit.org/show_bug.cgi?id=98756
53726
53727         Reviewed by Rob Buis.
53728
53729         No behavior change so no new tests.
53730
53731         * css/StyleResolver.cpp:
53732         (WebCore::StyleResolver::collectMatchingRulesForList):
53733
53734 2012-10-09  Simon Hausmann  <simon.hausmann@digia.com>
53735
53736         [Qt] Fix build with QtMultimedia
53737
53738         Reviewed by Tor Arne Vestbø.
53739
53740         This is an initial rudimentary port to of the QtMultimedia back-end,
53741         adapted to slight API changes and (more importantly) to the
53742         implementation of QAbstractVideoSurface instead of using
53743         QGraphicsVideoItem (which is in QtMultimediaWidgets).
53744
53745         * WebCore.pri:
53746         * platform/graphics/qt/MediaPlayerPrivateQt.cpp:
53747         (WebCore::MediaPlayerPrivateQt::supportsType):
53748         (WebCore::MediaPlayerPrivateQt::MediaPlayerPrivateQt):
53749         (WebCore::MediaPlayerPrivateQt::~MediaPlayerPrivateQt):
53750         (WebCore::MediaPlayerPrivateQt::didLoadingProgress):
53751         (WebCore::MediaPlayerPrivateQt::totalBytes):
53752         (WebCore::MediaPlayerPrivateQt::setVisible):
53753         (WebCore::MediaPlayerPrivateQt::surfaceFormatChanged):
53754         (WebCore::MediaPlayerPrivateQt::setSize):
53755         (WebCore::MediaPlayerPrivateQt::removeVideoItem):
53756         (WebCore::MediaPlayerPrivateQt::restoreVideoItem):
53757         (WebCore):
53758         (WebCore::MediaPlayerPrivateQt::start):
53759         (WebCore::MediaPlayerPrivateQt::supportedPixelFormats):
53760         (WebCore::MediaPlayerPrivateQt::present):
53761         (WebCore::MediaPlayerPrivateQt::paint):
53762         (WebCore::MediaPlayerPrivateQt::paintCurrentFrameInContext):
53763         (WebCore::MediaPlayerPrivateQt::paintToTextureMapper):
53764         * platform/graphics/qt/MediaPlayerPrivateQt.h:
53765         (MediaPlayerPrivateQt):
53766
53767 2012-10-09  Garrett Casto  <gcasto@chromium.org>
53768
53769         Allow users to specify a different hover image for TextFieldDecorationElement
53770         https://bugs.webkit.org/show_bug.cgi?id=93662
53771
53772         Reviewed by Kent Tamura.
53773
53774         * html/shadow/TextFieldDecorationElement.cpp:
53775         (WebCore::TextFieldDecorationElement::TextFieldDecorationElement):
53776         (WebCore::TextFieldDecorationElement::updateImage):
53777         (WebCore::TextFieldDecorationElement::defaultEventHandler): Handles mouseover and mouseout events.
53778         (WebCore::TextFieldDecorationElement::willRespondToMouseMoveEvents): Now returns true if the element is not disabled.
53779         (WebCore):
53780         * html/shadow/TextFieldDecorationElement.h:
53781         (TextFieldDecorator):
53782         (TextFieldDecorationElement):
53783
53784 2012-10-09  Allan Sandfeld Jensen  <allan.jensen@digia.com>
53785
53786         [Qt] Uploading images to Google+ using QtWebKit does not work.
53787         https://bugs.webkit.org/show_bug.cgi?id=72329
53788
53789         Reviewed by Jocelyn Turcotte.
53790
53791         Implement handling of Blob FormData, including its extensions to the File FormData.
53792
53793         * platform/network/qt/QNetworkReplyHandler.cpp:
53794         (WebCore::FormDataIODevice::FormDataIODevice):
53795         (WebCore::appendBlobResolved):
53796         (WebCore::FormDataIODevice::prepareFormElements):
53797         (WebCore::FormDataIODevice::computeSize):
53798         (WebCore::FormDataIODevice::moveToNextElement):
53799         (WebCore::FormDataIODevice::prepareCurrentElement):
53800         (WebCore::FormDataIODevice::openFileForCurrentElement):
53801         (WebCore::FormDataIODevice::readData):
53802         (WebCore::QNetworkReplyHandler::sendNetworkRequest):
53803         * platform/network/qt/QNetworkReplyHandler.h:
53804         (FormDataIODevice):
53805
53806 2012-10-09  Arpita Bahuguna  <arpitabahuguna@gmail.com>
53807
53808         Text decorations specified on the containing block are not properly applied when ::first-line is present.
53809         https://bugs.webkit.org/show_bug.cgi?id=93829
53810
53811         Reviewed by Abhishek Arya.
53812
53813         If a container's style and its pseudo :first-line style have unique
53814         text-decorations specified for them, only the :first-line text-decoarations
53815         were being applied.
53816
53817         The uploaded patch intends to first compute the text decoration colors
53818         for the containing box, followed by that of the first-line (if specified).
53819
53820         This thus avoids the condition wherein our containing box's text-decorations
53821         were not getting applied at all since initially we were only computing
53822         for the first-line style.
53823
53824         Test: fast/css/text-decorations-on-first-line-and-containing-block.html
53825
53826         * rendering/InlineTextBox.cpp:
53827         (WebCore::InlineTextBox::paintDecoration):
53828         getTextDecorationColors() is first called for computing the containing box's
53829         text-decoration values and then for first-line style's text-decorations,
53830         if specified.
53831
53832 2012-10-09  Sheriff Bot  <webkit.review.bot@gmail.com>
53833
53834         Unreviewed, rolling out r130746.
53835         http://trac.webkit.org/changeset/130746
53836         https://bugs.webkit.org/show_bug.cgi?id=98749
53837
53838         It made 45 tests crash on Qt (Requested by Ossy on #webkit).
53839
53840         * platform/network/qt/QNetworkReplyHandler.cpp:
53841         (WebCore::FormDataIODevice::FormDataIODevice):
53842         (WebCore::FormDataIODevice::computeSize):
53843         (WebCore::FormDataIODevice::moveToNextElement):
53844         (WebCore::FormDataIODevice::openFileForCurrentElement):
53845         (WebCore::FormDataIODevice::readData):
53846         (WebCore::QNetworkReplyHandler::getIODevice):
53847         (WebCore::QNetworkReplyHandler::sendNetworkRequest):
53848         * platform/network/qt/QNetworkReplyHandler.h:
53849         (QNetworkReplyHandler):
53850         (FormDataIODevice):
53851
53852 2012-10-09  Allan Sandfeld Jensen  <allan.jensen@digia.com>
53853
53854         [Qt] Uploading images to Google+ using QtWebKit does not work.
53855         https://bugs.webkit.org/show_bug.cgi?id=72329
53856
53857         Reviewed by Jocelyn Turcotte.
53858
53859         Implement handling of Blob FormData, including its extensions to the File FormData.
53860
53861         * platform/network/qt/QNetworkReplyHandler.cpp:
53862         (WebCore::FormDataIODevice::FormDataIODevice):
53863         (WebCore::FormDataIODevice::computeSize):
53864         (WebCore::FormDataIODevice::moveToNextElement):
53865         (WebCore::FormDataIODevice::prepareCurrentElement):
53866         (WebCore::FormDataIODevice::openFileForCurrentElement):
53867         (WebCore::FormDataIODevice::readData):
53868         (WebCore::QNetworkReplyHandler::getIODevice):
53869         (WebCore::QNetworkReplyHandler::handleBlobDataIfAny):
53870         (WebCore::QNetworkReplyHandler::sendNetworkRequest):
53871         * platform/network/qt/QNetworkReplyHandler.h:
53872         (QNetworkReplyHandler):
53873         (FormDataIODevice):
53874
53875 2012-10-09  Keishi Hattori  <keishi@webkit.org>
53876
53877         Page popup should be smarter about its layout
53878         https://bugs.webkit.org/show_bug.cgi?id=98499
53879
53880         Reviewed by Kent Tamura.
53881
53882         This change fixes these two issues:
53883         1. Page popup should reposition itself so it won't get clipped by screen(Win/Linux) or rootview(Mac) bounds.
53884         2. Page popup should resize itself when it doesn't fit.
53885
53886         Test: platform/chromium/fast/forms/page-popup/page-popup-adjust-rect.html
53887
53888         * Resources/pagepopups/calendarPicker.js:
53889         (initialize): We need to set global.params at the beginning because we need it for resizeWindow().
53890         * Resources/pagepopups/colorSuggestionPicker.js: Added global.params.
53891         (handleMessage):
53892         (initialize):
53893         (handleArgumentsTimeout):
53894         * Resources/pagepopups/pickerCommon.js:
53895         (Rect): Represents an axis aligned rectangle.
53896         (Rect.prototype.get maxX): Gets position of right edge.
53897         (Rect.prototype.get maxY): Gets position of bottom edge.
53898         (Rect.prototype.toString):
53899         (Rect.intersection): Returns the intersection of two rectangles.
53900         (resizeWindow): Resize window to a certain size. Don't allow shrinking.
53901         (adjustWindowRect): Calculates the best position and size for the popup.
53902         (_adjustWindowRectVertically):
53903         (_adjustWindowRectHorizontally):
53904         (setWindowRect): Sets the position and size of the popup to the given rect.
53905         * Resources/pagepopups/suggestionPicker.css:
53906         (.suggestion-list): Don't show horizontal scroll bar.
53907         * Resources/pagepopups/suggestionPicker.js:
53908         (SuggestionPicker.prototype._fixWindowSize): 
53909         * page/PagePopupClient.cpp:
53910         (WebCore::PagePopupClient::addProperty): For adding an int to JSON.
53911         (WebCore::PagePopupClient::addProperty): For adding an IntRect to JSON.
53912         (WebCore):
53913         * page/PagePopupClient.h:
53914         (PagePopupClient):
53915
53916 2012-10-09  Hajime Morrita  <morrita@google.com>
53917
53918         [Refactoring] Scoped Style related code should have its own class.
53919         https://bugs.webkit.org/show_bug.cgi?id=98244
53920
53921         Reviewed by Dimitri Glazkov.
53922
53923         This change extracts StyleScopeResolver from StyleResolver to clarify
53924         the responsibility of the style scope handling. Now we can easily see
53925         where the style scoping needs to be involed.
53926
53927         Coming Shadow DOM related change like @host rules will fit within this class.
53928
53929         No new tests, refactoring.
53930
53931         * CMakeLists.txt:
53932         * GNUmakefile.list.am:
53933         * Target.pri:
53934         * WebCore.gypi:
53935         * WebCore.xcodeproj/project.pbxproj:
53936         * css/CSSAllInOne.cpp:
53937         * css/StyleResolver.cpp:
53938         (WebCore::StyleResolver::StyleResolver):
53939         (WebCore::StyleResolver::collectFeatures):
53940         (WebCore::StyleResolver::appendAuthorStylesheets):
53941         (WebCore::StyleResolver::pushParentElement):
53942         (WebCore::StyleResolver::popParentElement):
53943         (WebCore::StyleResolver::pushParentShadowRoot):
53944         (WebCore::StyleResolver::popParentShadowRoot):
53945         (WebCore::StyleResolver::matchScopedAuthorRules):
53946         (WebCore::StyleResolver::collectMatchingRulesForList):
53947         (WebCore::StyleResolver::reportMemoryUsage):
53948         * css/StyleResolver.h:
53949         (StyleResolver):
53950         * css/StyleScopeResolver.cpp: Added.
53951         (WebCore):
53952         (WebCore::StyleScopeResolver::StyleScopeResolver):
53953         (WebCore::StyleScopeResolver::~StyleScopeResolver):
53954         (WebCore::StyleScopeResolver::scopeFor):
53955         (WebCore::StyleScopeResolver::ruleSetFor):
53956         (WebCore::StyleScopeResolver::ensureRuleSetFor):
53957         (WebCore::StyleScopeResolver::setupStack):
53958         (WebCore::StyleScopeResolver::push):
53959         (WebCore::StyleScopeResolver::pop):
53960         (WebCore::StyleScopeResolver::collectFeaturesTo):
53961         (WebCore::StyleScopeResolver::reportMemoryUsage):
53962         * css/StyleScopeResolver.h: Added.
53963         (WebCore):
53964         (StyleScopeResolver):
53965         (WebCore::StyleScopeResolver::StackFrame::StackFrame):
53966         (StackFrame):
53967         (WebCore::StyleScopeResolver::hasScopedStyles):
53968         (WebCore::StyleScopeResolver::stackSize):
53969         (WebCore::StyleScopeResolver::stackFrameAt):
53970         (WebCore::StyleScopeResolver::matchesStyleBounds):
53971         (WebCore::StyleScopeResolver::stackIsConsistent):
53972         (WebCore::StyleScopeResolver::ensureStackConsistency):
53973         (WebCore::StyleScopeResolver::scopeFor):
53974         (WebCore::StyleScopeResolver::ensureRuleSetFor):
53975
53976 2012-10-08  Simon Hausmann  <simon.hausmann@digia.com>
53977
53978         [Qt] Make RenderThemeQStyle/ScrollbarThemeQStyle compile without QStyle/QtWidgets
53979         https://bugs.webkit.org/show_bug.cgi?id=98268
53980
53981         Reviewed by Tor Arne Vestbø.
53982
53983         Extracted QStyle/QWidget related code into a QWebStyle class that implements the QStyleFacade interface.
53984
53985         QStyleFacade is a pure interface that lives in WebCore/platform/qt
53986         (next to RenderThemeQStyle and ScrollbarThemeQStyle) and provides a
53987         minimal interface of what we need to draw with QStyle as well as basic
53988         hit testing and metric retrieval. It also provides a
53989         QStyleFacadeOption class that aggregates common meta-data for
53990         rendering primitives, such as direction, rectangle, state (sunken,
53991         enabled, etc.) or palette. It also provides some more slider/scrollbar
53992         specific fields in a slider sub-structure.
53993
53994         RenderThemeQStyle/ScrollbarThemeQStyle used to instantiate specific QStyleOption sub-classes and populate
53995         them with state information from render objects, before calling straight to QStyle. Most of the common code
53996         was encapsulated in StylePainterQStyle.
53997
53998         The new RenderThemeQStyle/ScrolllbarThemeQStyle uses common code in
53999         StylePainterQStyle to populate state into QStyleFacadeOption before
54000         calling into QStyleFacade.
54001
54002         The style facade is then implemented by QStyleFacadeImp, which extracts
54003         meta-data from QStyleFacadeOption arguments, populates style
54004         primitive specific QStyleOption objects and then calls on QStyle.
54005
54006         RenderThemeQStyle/ScrollbarThemeQStyle can only use interface methods
54007         from QStyleFacade. QStyleFacadeImp on the other hand will live in the
54008         separate QtWebKitWidgets library in the future and therefore cannot use
54009         any WebCore types.
54010
54011         * Target.pri:
54012         * platform/qt/QStyleFacade.cpp: Added.
54013         (WebCore):
54014         (WebCore::QStyleFacade::styleForPage):
54015         * platform/qt/QStyleFacade.h: Added.
54016         (WebCore):
54017         (QStyleFacade):
54018         (WebCore::QStyleFacade::~QStyleFacade):
54019         (WebCore::QStyleFacadeOption::QStyleFacadeOption):
54020         (QStyleFacadeOption):
54021         * platform/qt/RenderThemeQStyle.cpp: Renamed from Source/WebKit/qt/WebCoreSupport/RenderThemeQStyle.cpp.
54022         (WebCore):
54023         (WebCore::RenderThemeQStyle::getStylePainter):
54024         (WebCore::StylePainterQStyle::StylePainterQStyle):
54025         (WebCore::StylePainterQStyle::init):
54026         (WebCore::RenderThemeQStyle::create):
54027         (WebCore::RenderThemeQStyle::setStyleFactoryFunction):
54028         (WebCore::RenderThemeQStyle::styleFactory):
54029         (WebCore::RenderThemeQStyle::RenderThemeQStyle):
54030         (WebCore::RenderThemeQStyle::~RenderThemeQStyle):
54031         (WebCore::RenderThemeQStyle::setPaletteFromPageClientIfExists):
54032         (WebCore::RenderThemeQStyle::inflateButtonRect):
54033         (WebCore::RenderThemeQStyle::computeSizeBasedOnStyle):
54034         (WebCore::RenderThemeQStyle::adjustButtonStyle):
54035         (WebCore::RenderThemeQStyle::setButtonPadding):
54036         (WebCore::RenderThemeQStyle::paintButton):
54037         (WebCore::RenderThemeQStyle::paintTextField):
54038         (WebCore::RenderThemeQStyle::adjustTextAreaStyle):
54039         (WebCore::RenderThemeQStyle::paintTextArea):
54040         (WebCore::RenderThemeQStyle::setPopupPadding):
54041         (WebCore::RenderThemeQStyle::colorPalette):
54042         (WebCore::RenderThemeQStyle::paintMenuList):
54043         (WebCore::RenderThemeQStyle::adjustMenuListButtonStyle):
54044         (WebCore::RenderThemeQStyle::paintMenuListButton):
54045         (WebCore::RenderThemeQStyle::animationDurationForProgressBar):
54046         (WebCore::RenderThemeQStyle::paintProgressBar):
54047         (WebCore::RenderThemeQStyle::paintSliderTrack):
54048         (WebCore::RenderThemeQStyle::adjustSliderTrackStyle):
54049         (WebCore::RenderThemeQStyle::paintSliderThumb):
54050         (WebCore::RenderThemeQStyle::adjustSliderThumbStyle):
54051         (WebCore::RenderThemeQStyle::paintSearchField):
54052         (WebCore::RenderThemeQStyle::adjustSearchFieldDecorationStyle):
54053         (WebCore::RenderThemeQStyle::paintSearchFieldDecoration):
54054         (WebCore::RenderThemeQStyle::adjustSearchFieldResultsDecorationStyle):
54055         (WebCore::RenderThemeQStyle::paintSearchFieldResultsDecoration):
54056         (WebCore::RenderThemeQStyle::paintInnerSpinButton):
54057         (WebCore::RenderThemeQStyle::initializeCommonQStyleOptions):
54058         (WebCore::RenderThemeQStyle::adjustSliderThumbSize):
54059         * platform/qt/RenderThemeQStyle.h: Renamed from Source/WebKit/qt/WebCoreSupport/RenderThemeQStyle.h.
54060         (WebCore):
54061         (RenderThemeQStyle):
54062         (WebCore::RenderThemeQStyle::qStyle):
54063         (StylePainterQStyle):
54064         (WebCore::StylePainterQStyle::isValid):
54065         (WebCore::StylePainterQStyle::paintButton):
54066         (WebCore::StylePainterQStyle::paintTextField):
54067         (WebCore::StylePainterQStyle::paintComboBox):
54068         (WebCore::StylePainterQStyle::paintComboBoxArrow):
54069         (WebCore::StylePainterQStyle::paintSliderTrack):
54070         (WebCore::StylePainterQStyle::paintSliderThumb):
54071         (WebCore::StylePainterQStyle::paintInnerSpinButton):
54072         (WebCore::StylePainterQStyle::paintProgressBar):
54073         (WebCore::StylePainterQStyle::paintScrollCorner):
54074         (WebCore::StylePainterQStyle::paintScrollBar):
54075         * platform/qt/ScrollbarThemeQStyle.cpp: Renamed from Source/WebKit/qt/WebCoreSupport/ScrollbarThemeQStyle.cpp.
54076         (WebCore):
54077         (WebCore::ScrollbarThemeQStyle::ScrollbarThemeQStyle):
54078         (WebCore::ScrollbarThemeQStyle::~ScrollbarThemeQStyle):
54079         (WebCore::scPart):
54080         (WebCore::scrollbarPart):
54081         (WebCore::initSliderStyleOption):
54082         (WebCore::ScrollbarThemeQStyle::paint):
54083         (WebCore::ScrollbarThemeQStyle::hitTest):
54084         (WebCore::ScrollbarThemeQStyle::shouldCenterOnThumb):
54085         (WebCore::ScrollbarThemeQStyle::invalidatePart):
54086         (WebCore::ScrollbarThemeQStyle::scrollbarThickness):
54087         (WebCore::ScrollbarThemeQStyle::thumbPosition):
54088         (WebCore::ScrollbarThemeQStyle::thumbLength):
54089         (WebCore::ScrollbarThemeQStyle::trackPosition):
54090         (WebCore::ScrollbarThemeQStyle::trackLength):
54091         (WebCore::ScrollbarThemeQStyle::paintScrollCorner):
54092         * platform/qt/ScrollbarThemeQStyle.h: Renamed from Source/WebKit/qt/WebCoreSupport/ScrollbarThemeQStyle.h.
54093         (WebCore):
54094         (ScrollbarThemeQStyle):
54095         (WebCore::ScrollbarThemeQStyle::qStyle):
54096
54097 2012-10-08  Kiran Muppala  <cmuppala@apple.com>
54098
54099         Throttle DOM timers on hidden pages.
54100         https://bugs.webkit.org/show_bug.cgi?id=98474
54101
54102         Reviewed by Maciej Stachowiak.
54103
54104         When the visibility of a page changes to "hidden", all it's DOM timers are
54105         updated to align their fire times on one second intervals.  This limits the
54106         number of CPU wakes due to a hidden pages to one per second.
54107
54108         Test: fast/dom/timer-throttling-hidden-page.html
54109
54110         * Configurations/FeatureDefines.xcconfig:
54111         * WebCore.exp.in:
54112         * dom/Document.cpp:
54113         (WebCore):
54114         (WebCore::Document::timerAlignmentInterval):
54115         Read Page::timerAlignmentInterval and pass it along to DOMTimer.
54116
54117         * dom/Document.h:
54118         (Document):
54119         * dom/ScriptExecutionContext.cpp:
54120         (WebCore):
54121         (WebCore::ScriptExecutionContext::didChangeTimerAlignmentInterval):
54122         Scan through self DOM Timers and tell them to recompute their fire
54123         time based on the updated alignment interval.
54124         (WebCore::ScriptExecutionContext::timerAlignmentInterval):
54125
54126         * dom/ScriptExecutionContext.h:
54127         (ScriptExecutionContext):
54128         * page/DOMTimer.cpp:
54129         (WebCore):
54130         (WebCore::DOMTimer::alignedFireTime):
54131         If the document's alignment interval is non zero, round up the fire
54132         time to the next multiple of alignment interval.
54133
54134         * page/DOMTimer.h:
54135         (DOMTimer):
54136         (WebCore::DOMTimer::defaultTimerAlignmentInterval):
54137         (WebCore::DOMTimer::setDefaultTimerAlignmentInterval):
54138         * page/Page.cpp:
54139         (WebCore::Page::Page):
54140         (WebCore):
54141         (WebCore::Page::setTimerAlignmentInterval):
54142         (WebCore::Page::timerAlignmentInterval):
54143         (WebCore::Page::setVisibilityState):
54144         Getter and Setter for alignment interval.  Expose setVisibilityState
54145         if either PAGE_VISIBILITY_API is enabled or if HIDDEN_PAGE_DOM_TIMER_REDUCTION
54146         is enabled.
54147
54148         * page/Page.h:
54149         (Page):
54150         * page/Settings.cpp:
54151         (WebCore):
54152         (WebCore::Settings::setDefaultDOMTimerAlignmentInterval):
54153         (WebCore::Settings::defaultDOMTimerAlignmentInterval):
54154         (WebCore::Settings::setDOMTimerAlignmentInterval):
54155         (WebCore::Settings::domTimerAlignmentInterval):
54156         * page/Settings.h:
54157         (Settings):
54158         * page/SuspendableTimer.cpp:
54159         (WebCore::SuspendableTimer::suspend):
54160         Save the time remaining to the original unaligned fire time, so that
54161         on resuming, the fire time will be correctly aligned using the latest
54162         alignment interval.
54163
54164         * platform/ThreadTimers.cpp:
54165         (WebCore::ThreadTimers::sharedTimerFiredInternal):
54166         Clear m_unalignedNextFireTime along with m_nextFireTime to keep
54167         them always in sync.
54168
54169         * platform/Timer.cpp:
54170         (WebCore::TimerBase::TimerBase):
54171         (WebCore::TimerBase::setNextFireTime):
54172         Save the requested fire time in m_unalignedNextFireTime and
54173         set m_nextFireTime to the aligned value.  The unalinged value
54174         is used to recompute fire time if alignment interval changes.
54175         (WebCore):
54176         (WebCore::TimerBase::didChangeAlignmentInterval):
54177         Recompute next fire time from m_unalignedNextFireTime.
54178         (WebCore::TimerBase::nextUnalignedFireInterval):
54179         Interval from current time to the original unaligned fire time.
54180
54181         * platform/Timer.h:
54182         (TimerBase):
54183         (WebCore::TimerBase::alignedFireTime):
54184
54185 2012-10-08  Andreas Kling  <kling@webkit.org>
54186
54187         1.18MB below RenderTableSection::setCachedCollapsedBorderValue() on Membuster3.
54188         <http://webkit.org/b/98670>
54189         <rdar://problem/12454276>
54190
54191         Reviewed by Anders Carlsson.
54192
54193         Refactor CollapsedBorderValue to only store the bits and pieces from the BorderValue
54194         that it actually needs. Packed the whole thing into 64 bits.
54195
54196         Reduces memory consumption by 547kB on Membuster3.
54197
54198         * rendering/RenderTableCell.cpp:
54199
54200             Add compile-time size assertion for CollapsedBorderValue.
54201
54202         * rendering/style/CollapsedBorderValue.h:
54203         (WebCore::CollapsedBorderValue::CollapsedBorderValue):
54204         (WebCore::CollapsedBorderValue::width):
54205         (WebCore::CollapsedBorderValue::style):
54206         (WebCore::CollapsedBorderValue::color):
54207         (WebCore::CollapsedBorderValue::isTransparent):
54208         (WebCore::CollapsedBorderValue::precedence):
54209         (WebCore::CollapsedBorderValue::isSameIgnoringColor):
54210         (CollapsedBorderValue):
54211
54212             Apply shrinkwrap to CollapsedBorderValue. Removed specialized copy constructor since
54213             the class only has primitive members now.
54214
54215 2012-10-08  Yoshifumi Inoue  <yosin@chromium.org>
54216
54217         HTMLSelectElement::typeAheadFind depends on implementation dependent behavior
54218         https://bugs.webkit.org/show_bug.cgi?id=98710
54219
54220         Reviewed by Kent Tamura.
54221
54222         This patch gets rid of C/C++ implementation dependent behavior from
54223         HTMLSelectElement::typeAheadFind() which does modulo operation with
54224         a negative operand.
54225
54226         HTMLSelectElement::typeAheadFind() contains expression with modulo
54227         operator and dividend can be -1 when the "select" element without
54228         "option" element but "optgroup" element.
54229
54230         Test: fast/forms/select/select-typeahead-crash.html
54231
54232         * html/HTMLSelectElement.cpp:
54233         (WebCore::HTMLSelectElement::typeAheadFind): Changed to do modulo
54234         operation with both operands are non-negative.
54235
54236 2012-10-08  Kent Tamura  <tkent@chromium.org>
54237
54238         Take account of overflowing values for width calculation of a year sub-field
54239         https://bugs.webkit.org/show_bug.cgi?id=98506
54240
54241         Reviewed by Eric Seidel.
54242
54243         When we decide the width of a year field of an input[type=date]
54244         with the multiple fields UI, we need to take account of the
54245         current value width because we allow to set overflowing values to
54246         the input[type=date].
54247
54248         This change affects only platforms with INPUT_TYPE_DATE &&
54249         INPUT_MULTIPLE_FIELDS_UI.
54250
54251         Test: fast/forms/date-multiple-fields/date-multiple-fields-change-layout-by-value.html
54252
54253         * html/shadow/DateTimeNumericFieldElement.cpp:
54254         (WebCore::DateTimeNumericFieldElement::customStyleForRenderer):
54255         Take account of the current value width.
54256
54257 2012-10-08  Tony Chang  <tony@chromium.org>
54258
54259         image not displayed in flexbox
54260         https://bugs.webkit.org/show_bug.cgi?id=98611
54261
54262         Reviewed by Ojan Vafai.
54263
54264         Flexbox will override the width of a child and when stretching, will override the height of the child.
54265         When this happens, when an image loads, it checks to see if it's width/height has
54266         changed, and if so, does a relayout.  The overridden width/height was preventing this
54267         relayout from happening.
54268
54269         To fix, we clear all the override sizes when we're done laying out the flex children.
54270
54271         Test: css3/flexbox/relayout-image-load.html
54272
54273         * rendering/RenderFlexibleBox.cpp:
54274         (WebCore::RenderFlexibleBox::layoutBlock): Clear child override sizes.
54275         (WebCore::RenderFlexibleBox::clearChildOverrideSizes):
54276         (WebCore::RenderFlexibleBox::computeMainAxisPreferredSizes): No longer need to clear the override size
54277         here since it should have already been cleared.
54278         * rendering/RenderFlexibleBox.h:
54279
54280 2012-10-08  Andreas Kling  <kling@webkit.org>
54281
54282         REGRESSION(r130643): editing/pasteboard/data-transfer-item is failing on chromium.
54283         <http://webkit.org/b/98686>
54284
54285         Reviewed by Tony Chang.
54286
54287         Change ChromiumDataObject::createFromPasteboard() to use a ListHashSet instead of a HashSet so that
54288         item order is preserved.
54289
54290         * platform/chromium/ChromiumDataObject.cpp:
54291         (WebCore::ChromiumDataObject::createFromPasteboard):
54292
54293 2012-10-08  Eric Seidel  <eric@webkit.org>
54294
54295         Inline logicalHeightForRowSizing to shave another 2-3% off robohornet's resizecol.html
54296         https://bugs.webkit.org/show_bug.cgi?id=98703
54297
54298         Reviewed by Emil A Eklund.
54299
54300         This is very small potatoes.  There are much bigger wins for table layout yet, but
54301         this was an easy win.
54302
54303         This function should probably be converted to use int's only, as table cells are pixel-sized
54304         according to our subpixel-experts.
54305
54306         Also, I suspect there should be ways to early return with less-math in the common cases, but
54307         I've saved such for a later patch.
54308
54309         Note that I changed from using paddingBefore/paddingAfter (which include the instrinsic padding)
54310         to calling computedCSSPaddingBefore/computedCSSPaddingAfter directly as well.
54311
54312         This single function is about 11% of total time for robohornet's resizecol.
54313
54314         * rendering/RenderTableCell.cpp:
54315         * rendering/RenderTableCell.h:
54316         (WebCore::RenderTableCell::logicalHeightForRowSizing):
54317
54318 2012-10-08  Alec Flett  <alecflett@chromium.org>
54319
54320         IndexedDB: remove autogenerated objectStore/index id code
54321         https://bugs.webkit.org/show_bug.cgi?id=98085
54322
54323         Reviewed by Tony Chang.
54324
54325         Remove support for backend-generated objectstore and index
54326         ids. The frontend objects now manage that state during
54327         versionchange transactions. The IDBDatabaseBackendInterface and
54328         IDBObjectStoreBackendInterface methods will go away when
54329         https://bugs.webkit.org/show_bug.cgi?id=98682 lands.
54330
54331         No new tests as this is part of a refactoring, existing indexeddb
54332         tests cover correctness.
54333
54334         * Modules/indexeddb/IDBBackingStore.h:
54335         (IDBBackingStore):
54336         * Modules/indexeddb/IDBDatabase.cpp:
54337         (WebCore::IDBDatabase::createObjectStore):
54338         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
54339         (WebCore::IDBDatabaseBackendImpl::createObjectStore):
54340         (WebCore::IDBDatabaseBackendImpl::createObjectStoreInternal):
54341         (WebCore::IDBDatabaseBackendImpl::loadObjectStores):
54342         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
54343         (IDBDatabaseBackendInterface):
54344         * Modules/indexeddb/IDBLevelDBBackingStore.cpp:
54345         (WebCore::IDBLevelDBBackingStore::createObjectStore):
54346         (WebCore::setMaxIndexId):
54347         (WebCore::IDBLevelDBBackingStore::createIndex):
54348         * Modules/indexeddb/IDBLevelDBBackingStore.h:
54349         (IDBLevelDBBackingStore):
54350         * Modules/indexeddb/IDBObjectStore.cpp:
54351         (WebCore::IDBObjectStore::createIndex):
54352         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
54353         (WebCore::IDBObjectStoreBackendImpl::IDBObjectStoreBackendImpl):
54354         (WebCore::IDBObjectStoreBackendImpl::createIndex):
54355         (WebCore::IDBObjectStoreBackendImpl::createIndexInternal):
54356         * Modules/indexeddb/IDBObjectStoreBackendInterface.h:
54357
54358 2012-10-08  Jaehun Lim  <ljaehun.lim@samsung.com>
54359
54360         [CAIRO] Adjust the source rect size when IMAGE_DECODER_DOWN_SAMPLING is enabled
54361         https://bugs.webkit.org/show_bug.cgi?id=98630
54362
54363         Reviewed by Martin Robinson.
54364
54365         IMAGE_DECODER_DOWN_SAMPLING scales down the size of the big image.
54366         CAIRO needs to adjust the source size to the scaled value.
54367
54368         No new tests.
54369
54370         * platform/graphics/cairo/BitmapImageCairo.cpp:
54371         (WebCore::BitmapImage::draw):
54372
54373 2012-10-08  Adam Barth  <abarth@webkit.org>
54374
54375         Remove unused features of BlobBuilder
54376         https://bugs.webkit.org/show_bug.cgi?id=98331
54377
54378         Reviewed by Eric Seidel.
54379
54380         Now that we don't expose BlobBuilder as a web platform API, we can
54381         strip down the class to handle only those cases that are needed by the
54382         Blob constructor.
54383
54384         I've also renamed the class from WebKitBlobBuilder to BlobBuilder and
54385         made it stack allocated rather than RefCounted. A future patch will
54386         actually move the files around. (I didn't want to mix moving code
54387         around with modifying the code.)
54388
54389         * bindings/js/JSBlobCustom.cpp:
54390         (WebCore::JSBlobConstructor::constructJSBlob):
54391         * bindings/v8/custom/V8BlobCustom.cpp:
54392         (WebCore::V8Blob::constructorCallback):
54393         * fileapi/WebKitBlobBuilder.cpp:
54394         (WebCore):
54395         (WebCore::BlobBuilder::BlobBuilder):
54396         (WebCore::BlobBuilder::getBuffer):
54397         (WebCore::BlobBuilder::append):
54398         (WebCore::BlobBuilder::appendBytesData):
54399         (WebCore::BlobBuilder::getBlob):
54400         * fileapi/WebKitBlobBuilder.h:
54401         (WebCore):
54402         (BlobBuilder):
54403         * page/FeatureObserver.h:
54404
54405 2012-10-08  Martin Robinson  <mrobinson@igalia.com>
54406
54407         Try to fix the debug build after r130699
54408
54409         Move the assignment of the ResourceHandleInternal local to before
54410         the include statement where it is used.
54411
54412         * platform/network/soup/ResourceHandleSoup.cpp:
54413         (WebCore::createSoupMessageForHandleAndRequest):
54414
54415 2012-10-08  Nate Chapin  <japhet@chromium.org>
54416
54417         Post-r130226 Cleanup: Comment a complicated if statement and make it a helper.
54418         https://bugs.webkit.org/show_bug.cgi?id=98463
54419
54420         Reviewed by Eric Seidel.
54421
54422         No new tests, refactor only.
54423
54424         * rendering/RenderLayer.cpp:
54425         (WebCore::frameElementAndViewPermitScroll):
54426         (WebCore::RenderLayer::scrollRectToVisible):
54427
54428 2012-10-06  Martin Robinson  <mrobinson@igalia.com>
54429
54430         [Soup] Simplify the way that requests are started
54431         https://bugs.webkit.org/show_bug.cgi?id=98532
54432
54433         Reviewed by Gustavo Noronha Silva.
54434
54435         Simplify the creation of the libsoup request and message when kicking off
54436         requests, by elminating a bit of duplicate code.
54437
54438         No new tests. This should not change any behavior.
54439
54440         * platform/network/ResourceHandle.h:
54441         (ResourceHandle):
54442         * platform/network/soup/ResourceHandleSoup.cpp:
54443         (WebCore):
54444         (WebCore::ResourceHandleInternal::soupSession): Ensure the session
54445         is initialized when passing it to the caller.
54446         (WebCore::createSoupMessageForHandleAndRequest): Added this helper which
54447         takes care of creating the SoupMessage for HTTP/HTTPS requests.
54448         (WebCore::createSoupRequestAndMessageForHandle): Collapsed the HTTP and
54449         non-HTTP request creation into this helper.
54450         (WebCore::ResourceHandle::start): Call the new helper now and then sendPendingRequest.
54451         (WebCore::ResourceHandle::sendPendingRequest): Instead of having special
54452         helpers to create and send the request, duplicating the logic for sending it
54453         across the file, add this method which can be used in both cases.
54454         (WebCore::waitingToSendRequest): Reworked the hasBeenSent method to answer
54455         the question of whether or not the request is ready to be sent, but is unsent.
54456         (WebCore::ResourceHandle::platformSetDefersLoading): Use the new helper.
54457         * platform/network/soup/ResourceRequest.h:
54458         (ResourceRequest): Added a new method for getting the URL string for soup.
54459         * platform/network/soup/ResourceRequestSoup.cpp:
54460         (WebCore::ResourceRequest::urlStringForSoup): Added.
54461
54462 2012-10-08  Eric Seidel  <eric@webkit.org>
54463
54464         Make no-column table-layout cases a little faster with inlining
54465         https://bugs.webkit.org/show_bug.cgi?id=98566
54466
54467         Reviewed by Julien Chaffraix.
54468
54469         This change is almost not worth it at only a couple percent boost on
54470         http://www.robohornet.org/tests/resizecol.html
54471         However, I think the logicalWidthFromTableColumn split it kinda nice
54472         so I've decided to post it anyway.
54473
54474         * rendering/RenderTable.cpp:
54475         (WebCore::RenderTable::slowColElement):
54476         * rendering/RenderTable.h:
54477         (WebCore::RenderTable::colElement):
54478         (RenderTable):
54479         * rendering/RenderTableCell.cpp:
54480         (WebCore::RenderTableCell::logicalWidthFromTableColumn):
54481         * rendering/RenderTableCell.h:
54482         (WebCore::RenderTableCell::styleOrColLogicalWidth):
54483         (RenderTableCell):
54484
54485 2012-10-08  Arpita Bahuguna  <arpitabahuguna@gmail.com>
54486
54487         Rename RenderObject::firstLineStyleSlowCase() to a more appropriate cachedFirstLineStyle()
54488         https://bugs.webkit.org/show_bug.cgi?id=98631
54489
54490         Reviewed by Eric Seidel.
54491
54492         Renaming firstLineStyleSlowCase() to cachedFirstLineStyle().
54493
54494         The current name is confusing since the function actually gets the
54495         the cached first-line styles.
54496         It also makes the name more descriptive of its functionality
54497         and in accordance with RenderObject::uncachedFirstLineStyle().
54498
54499         No new tests required for this change since no change in behavior is expected.
54500
54501         * rendering/RenderObject.cpp:
54502         (WebCore::RenderObject::cachedFirstLineStyle):
54503         * rendering/RenderObject.h:
54504         (WebCore::RenderObject::firstLineStyle):
54505         (RenderObject):
54506         Renamed RenderObject::firstLineStyleSlowCase() to cachedFirstLineStyle()
54507         and made the associated changes.
54508
54509 2012-10-08  Sami Kyostila  <skyostil@chromium.org>
54510
54511         Some non-scrollable elements are added to non-fast-scrollable region
54512         https://bugs.webkit.org/show_bug.cgi?id=97927
54513
54514         Reviewed by James Robinson.
54515
54516         Only RenderLayers that can actually be scrolled should be added to the
54517         ScrollingCoordinator's non-fast scrollable region. Otherwise we may
54518         needlessly fall back to main thread scrolling.
54519
54520         Test: ScrollingCoordinatorChromiumTest.clippedBodyTest
54521
54522         * rendering/RenderLayer.cpp:
54523         (WebCore::RenderLayer::updateScrollbarsAfterLayout):
54524         (WebCore::RenderLayer::updateScrollbarsAfterStyleChange):
54525
54526 2012-10-08  Simon Fraser  <simon.fraser@apple.com>
54527
54528         Move layerTreeAsText to window.internals
54529         https://bugs.webkit.org/show_bug.cgi?id=98690
54530
54531         Reviewed by James Robinson.
54532
54533         Add window.internals.layerTreeAsText(document), and change the tests to use it.
54534         I'll remove testRunner.layerTreeAsText() in a later patch.
54535
54536         * testing/Internals.cpp:
54537         (WebCore::Internals::layerTreeAsText):
54538         * testing/Internals.h:
54539         (Internals):
54540         * testing/Internals.idl:
54541
54542 2012-10-08  Jon Lee  <jonlee@apple.com>
54543
54544         Add render object that paints plugin snapshots
54545         https://bugs.webkit.org/show_bug.cgi?id=98322
54546         <rdar://problem/12426546>
54547
54548         Reviewed by Simon Fraser.
54549
54550         First, teach plugins to maintain a set of states when plugin snapshotting is enabled.
54551
54552         Second, a new RenderSnapshottedPlugIn class is a RenderEmbeddedObject that knows how to paint
54553         snapshots when the plugin is not visibly playing. It maintains a RenderImageResource to
54554         the generated poster image.
54555
54556         * html/HTMLPlugInElement.cpp:
54557         (WebCore::HTMLPlugInElement::HTMLPlugInElement): By default all plugins play on load.
54558         * html/HTMLPlugInElement.h: Move the inheritance of ImageLoaderClientBase down to
54559         HTMLPlugInImageElement, since that is the class that actually deals with image-based plugins.
54560         (WebCore::HTMLPlugInElement::displayState): Add bit for display state.
54561         (WebCore::HTMLPlugInElement::setDisplayState):
54562         (WebCore::HTMLPlugInElement::updateSnapshot):
54563
54564         * html/HTMLPlugInImageElement.cpp:
54565         (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement): If plugin snapshotting is
54566         enabled, plugin state is set to wait for a poster image.
54567         (WebCore::HTMLPlugInImageElement::createRenderer): Create RenderSnapshottedPlugIn if
54568         plugin snapshotting is enabled.
54569         (WebCore::HTMLPlugInImageElement::updateSnapshot): Once a snapshot is available, update the
54570         renderer and set its state to wait for user input to start the plugin.
54571         * html/HTMLPlugInImageElement.h:
54572         (HTMLPlugInImageElement):
54573
54574         * rendering/RenderObject.h:
54575         (WebCore::RenderObject::isSnapshottedPlugIn): Add new function to identify
54576         RenderSnapshottedPlugIn instances. Since RenderSnapshottedPlugIn inherits from
54577         RenderEmbeddedObject, isEmbeddedObject() still returns true.
54578         * rendering/RenderEmbeddedObject.h:
54579         (RenderEmbeddedObject): Elevate a few virtual methods to protected for
54580         RenderSnapshottedPlugIn to override.
54581
54582         * rendering/RenderSnapshottedPlugIn.cpp: Added.
54583         (WebCore::RenderSnapshottedPlugIn::RenderSnapshottedPlugIn): Initialize snapshot
54584         resource.
54585         (WebCore::RenderSnapshottedPlugIn::~RenderSnapshottedPlugIn): Shut down snapshot
54586         image resource to remove the renderer as a client, and remove image from memory cache.
54587         (WebCore::RenderSnapshottedPlugIn::plugInImageElement): Convenience function to get the
54588         HTML element.
54589         (WebCore::RenderSnapshottedPlugIn::updateSnapshot): Cache the snapshot, and repaint.
54590         (WebCore::RenderSnapshottedPlugIn::paint): If the plugin is not playing, paint like a
54591         RenderImage does.
54592         (WebCore::RenderSnapshottedPlugIn::paintReplaced): Paint the snapshot and overlay if the
54593         plugin is not playing.
54594         (WebCore::RenderSnapshottedPlugIn::paintReplacedSnapshot): Inspired by
54595         RenderImage::paintReplaced() and RenderImage::paintIntoRect().
54596         * rendering/RenderSnapshottedPlugIn.h: Added.
54597         (WebCore::RenderSnapshottedPlugIn::isSnapshottedPlugin): Returns true.
54598
54599         * rendering/RenderTheme.h: Add a function that paints the overlay on top of the snapshot.
54600         * rendering/RenderThemeMac.h:
54601         * rendering/RenderThemeMac.mm:
54602         (WebCore::RenderThemeMac::paintPlugInSnapshotOverlay):
54603
54604         * WebCore.xcodeproj/project.pbxproj: Add new RenderSnapshottedPlugIn class.
54605         * CMakeLists.txt: Ditto.
54606         * GNUmakefile.list.am: Ditto.
54607         * Target.pri: Ditto.
54608         * WebCore.gypi: Ditto.
54609         * WebCore.vcproj/WebCore.vcproj: Ditto.
54610         * rendering/RenderingAllInOne.cpp: Ditto.
54611
54612 2012-10-08  Hans Muller  <hmuller@adobe.com>
54613
54614         [CSS Exclusions] Add support for polygonal shapes
54615         https://bugs.webkit.org/show_bug.cgi?id=96811
54616
54617         Reviewed by Dirk Schulze.
54618
54619         Initial version of the layout support for polygonal exclusion shapes: the ExclusionPolygon class.
54620         Supports the public ExclusionShape operations using the algorithm described here:
54621         http://hansmuller-webkit.blogspot.com/2012/06/horizontal-box-polygon-intersection-for.html.
54622         Although both the "included" and "excluded" operations are supported, only the former is
54623         used, since only shape-inside is supported at the moment.
54624
54625         The ExclusionPolygon class stores the polygon's edges in an interval tree.
54626
54627         Polygon edges are represented by the ExclusionPolygonEdge struct, which records the indices of
54628         the pair of vertices joined by the edge.  Edge vertex index1 is usually less than index2, except
54629         the last edge where index2 is 0.  We plan to improve the algorithm that creates the edges
54630         by spanning vertices contained in sequences of more than two colinear vertices. For example,
54631         a triangular polygon might be specified with 5 vertices like this: 3,0 5,0, 5,5, 4,4 2,2, 0,0.
54632         By spanning the extra colinear points: 0,0 5,0, 5,5, which implies index1-index2 edges: 5-1 1-2 2-5.
54633
54634         Although the implementation supports complex polygons, the layout code is limited to
54635         essentially rectangular shapes until a patch for https://bugs.webkit.org/show_bug.cgi?id=96813
54636         lands.
54637
54638         Tests: fast/exclusions/shape-inside/shape-inside-polygon-rectangle.html
54639                fast/exclusions/shape-inside/shape-inside-simple-polygon-001.html
54640                fast/exclusions/shape-inside/shape-inside-simple-polygon-002.html
54641                fast/exclusions/shape-inside/shape-inside-simple-polygon-003.html
54642                fast/exclusions/shape-inside/shape-inside-simple-polygon-004.html
54643
54644         * CMakeLists.txt:
54645         * GNUmakefile.list.am:
54646         * Target.pri:
54647         * WebCore.gypi:
54648         * WebCore.vcproj/WebCore.vcproj:
54649         * WebCore.xcodeproj/project.pbxproj:
54650         * rendering/ExclusionPolygon.cpp: Added.
54651         (WebCore):
54652         (EdgeIntersection): Internal description of the intersection of a polygon edge and a horizontal line.
54653         (WebCore::ExclusionPolygon::ExclusionPolygon): See the introductory text above for a description of this type.
54654         (WebCore::computeXIntersection): Find and classify the X intercept of a polygon edge with horizontal line, if any.
54655         (WebCore::ExclusionPolygon::rightVertexY): This method is used to decide if a horizontal line "crosses" a vertex.
54656         (WebCore::appendIntervalX): Append an x coordinate to a vector of ExclusionIntervals.
54657         (WebCore::ExclusionPolygon::computeXIntersections): Return a vector of the intersections of a horizontal line with the polygon's edges.
54658         (WebCore::ExclusionPolygon::computeEdgeIntersections): Return a vector of the X projections of the edges that overlap a horizonal rectangle.
54659         (WebCore::ExclusionPolygon::getExcludedIntervals): Return a SegmentList of the X intervals within a horizontal rectangle that overlap the polygon.
54660         (WebCore::ExclusionPolygon::getIncludedIntervals): Return the X intervals within a horizontal rectangle that fit inside the polygon.
54661         * rendering/ExclusionPolygon.h: Added.
54662         (WebCore):
54663         (ExclusionPolygon):
54664         (WebCore::ExclusionPolygon::getXAt): X coordinate of a polygon vertex
54665         (WebCore::ExclusionPolygon::getYAt): Y coordinate of a polygon vertex
54666         (WebCore::ExclusionPolygon::numberOfVertices):
54667         (WebCore::ExclusionPolygon::fillRule): A WindRule value that defines "inside" for self-intersecting polygons.
54668         (ExclusionPolygonEdge):
54669         (WebCore::ExclusionPolygonEdge::ExclusionPolygonEdge):
54670         (WebCore::ExclusionPolygonEdge::vertex1):
54671         (WebCore::ExclusionPolygonEdge::vertex2):
54672         (WebCore::ExclusionPolygonEdge::minX):
54673         (WebCore::ExclusionPolygonEdge::minY):
54674         (WebCore::ExclusionPolygonEdge::maxX):
54675         (WebCore::ExclusionPolygonEdge::maxY):
54676         * rendering/ExclusionShape.cpp:
54677         (WebCore::createExclusionPolygon): Return a new ExclusionPolygon.
54678         (WebCore):
54679         (WebCore::ExclusionShape::createExclusionShape): Added support for BasicShape::BASIC_SHAPE_POLYGON.
54680         * rendering/ExclusionShapeInsideInfo.cpp:
54681         (WebCore::ExclusionShapeInsideInfo::isExclusionShapeInsideInfoEnabledForRenderBlock): Enable BASIC_SHAPE_POLYGON shapes for RenderBlocks.
54682
54683 2012-10-08  Tony Chang  <tony@chromium.org>
54684
54685         Replace 2 uses of updateLogicalHeight with computeLogicalHeight
54686         https://bugs.webkit.org/show_bug.cgi?id=98677
54687
54688         Reviewed by Ojan Vafai.
54689
54690         This is part of bug 96804.  Convert RenderTextControl and RenderSVGForeignObject to
54691         override the const computeLogicalHeight method rather than the updateLogicalHeight
54692         setter method.
54693
54694         No new tests, there should be no behavior change as this is just a refactor.
54695
54696         * rendering/RenderTextControl.cpp:
54697         (WebCore::RenderTextControl::computeLogicalHeight): Pass logicalHeight through rather than setting height.
54698         This is a slight correctness fix, although we don't support vertical inputs yet.
54699         * rendering/RenderTextControl.h:
54700         (RenderTextControl):
54701         * rendering/svg/RenderSVGForeignObject.cpp:
54702         (WebCore::RenderSVGForeignObject::computeLogicalHeight):
54703         * rendering/svg/RenderSVGForeignObject.h:
54704         (RenderSVGForeignObject):
54705
54706 2012-10-08  Min Qin  <qinmin@chromium.org>
54707
54708         Upstream some tweaks for overlay play button on Android
54709         https://bugs.webkit.org/show_bug.cgi?id=98671
54710
54711         Reviewed by Adam Barth.
54712
54713         This change stops displaying the overlay play button if video height is too small
54714         No test for this. Will rebase layout test expectations for android later.
54715
54716         * css/mediaControlsChromiumAndroid.css:
54717         (video::-webkit-media-controls-overlay-enclosure):
54718
54719 2012-10-08  Simon Fraser  <simon.fraser@apple.com>
54720
54721         Some GraphicsLayer cleanup to separate the concepts of using a tile cache, and being the main tile cache layer
54722         https://bugs.webkit.org/show_bug.cgi?id=98574
54723
54724         Reviewed by Dean Jackson.
54725
54726         GraphicsLayerCA assumed that using a TileCache equated to being the main page tile
54727         cache layer, which has some special considerations. Make these two concepts separate
54728         to get closer to being able to use TileCaches in place of CATiledLayer.
54729
54730         * platform/graphics/GraphicsLayer.h:
54731         (GraphicsLayer): Remove m_usingTileCache member, which was not appropriate
54732         for this class to have.
54733         * platform/graphics/GraphicsLayer.cpp:
54734         (WebCore::GraphicsLayer::GraphicsLayer): Remove init of m_usingTileCache.
54735         (WebCore::GraphicsLayer::debugBorderInfo): Can no longer use m_usingTileCache to
54736         get the blue color, so moved code into a virtual debugBorderInfo() method.
54737         (WebCore::GraphicsLayer::updateDebugIndicators): Call the virtual debugBorderInfo().
54738         * platform/graphics/GraphicsLayerClient.h: Remove the usingTileCache() callback;
54739         we now just cache this information in the GraphicsLayerCA on creation.
54740         * platform/graphics/ca/GraphicsLayerCA.cpp:
54741         (WebCore::GraphicsLayerCA::GraphicsLayerCA): Init m_isPageTileCacheLayer to false,
54742         then set to m_isPageTileCacheLayer if the client says we should create a tile cache.
54743         (WebCore::GraphicsLayerCA::platformCALayerShowRepaintCounter): Overidden to avoid duplicate repaint
54744         counters in the top-left tile.
54745         (WebCore::GraphicsLayerCA::updateLayerBackgroundColor): If this layer is the page tile cache layer,
54746         we allow setting of its background color.
54747         (WebCore::GraphicsLayerCA::debugBorderInfo): Overidden to use a blue color for tiles.
54748         (WebCore::GraphicsLayerCA::requiresTiledLayer): Don't make CATiledLayers for the page tile cache.
54749         * platform/graphics/ca/GraphicsLayerCA.h:
54750         (GraphicsLayerCA):
54751         * platform/graphics/ca/PlatformCALayerClient.h:
54752         (PlatformCALayerClient): Need to pass the platform layer into platformCALayerShowRepaintCounter()
54753         so we can distinguish between calls for tiles, and calls for the tile cache layer itself.
54754         * platform/graphics/ca/mac/TileCache.mm:
54755         (WebCore::TileCache::shouldShowRepaintCounters): Pass 0 to platformCALayerShowRepaintCounter() to
54756         indicate that we're asking about a tile.
54757         * platform/graphics/mac/WebLayer.mm:
54758         (drawLayerContents): Now we can just rely on platformCALayerShowRepaintCounter() to tell us whether
54759         to draw the repaint counter.
54760         (-[WebLayer setNeedsDisplayInRect:]):
54761         * platform/graphics/mac/WebTiledLayer.mm:
54762         (-[WebTiledLayer setNeedsDisplayInRect:]):
54763         * rendering/RenderLayerBacking.h:
54764         (WebCore::RenderLayerBacking::usingTileCache):
54765         (RenderLayerBacking):
54766         * rendering/RenderLayerCompositor.cpp:
54767         (WebCore::RenderLayerCompositor::documentBackgroundColorDidChange): We can ask the RenderLayerBacking
54768         whether it's for the tile cache, rather than going to the GraphicsLayer.
54769         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
54770         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::LayerClient::platformCALayerShowRepaintCounter):
54771
54772 2012-10-08  Huang Dongsung  <luxtella@company100.net>
54773
54774         [Qt] Make ImageBufferQt use premultiplied converting functions in Color.h instead of its own mechanism.
54775         https://bugs.webkit.org/show_bug.cgi?id=98582
54776
54777         Reviewed by Eric Seidel.
54778
54779         Only Qt port failed canvas/philip/tests/2d.imageData.put.unchanged.html because
54780         ImageBufferQt converts from or to a premultiplied color using its own code. When
54781         we convert twice from an unmultiplied color to a premultiplied color and then to
54782         an unmultiplied color using this code, the calculated result are pretty
54783         different against the input color. It is why Gtk passes this test although Qt
54784         fails. Gtk port uses them in Color.h.
54785
54786         In addition, Qt should use the functions in Color.h to reduce duplicated codes.
54787
54788         Tests: canvas/philip/tests/2d.imageData.put.unchanged.html: Fixed a test case
54789
54790         * platform/graphics/qt/ImageBufferQt.cpp:
54791         (WebCore::getImageData):
54792         (WebCore::convertBGRAToRGBA):
54793         (WebCore::ImageBuffer::putByteArray):
54794
54795 2012-10-08  Tab Atkins  <jackalmage@gmail.com>
54796
54797         Remove "orphaned units" quirk
54798         https://bugs.webkit.org/show_bug.cgi?id=98553
54799
54800         Reviewed by Eric Seidel.
54801
54802         This patch removes our "orphaned units" quirk.
54803         We have an "orphaned units" quirk to match IE, which allows things like "width: 20 px;".
54804         But FF and Opera don't have it and aren't aware of bugs for it,
54805         and it's not in Simon Pieters' Quirks Mode spec <http://dvcs.w3.org/hg/quirks-mode/raw-file/tip/Overview.html>
54806
54807         No new tests, because I'm killing a quirk.
54808
54809         * css/CSSParser.cpp:
54810         (WebCore::CSSParser::parseValue):
54811         * css/CSSParser.h:
54812         (CSSParser):
54813
54814 2012-10-08  Robert Hogan  <robert@webkit.org>
54815
54816         Border, margin and padding of an inline's inline ancestors counted twice
54817         https://bugs.webkit.org/show_bug.cgi?id=63074
54818
54819         Reviewed by David Hyatt.
54820
54821         In a line such as '<span><span><img>Text' the border, padding and margin belonging
54822         to the two spans was counted twice by RenderBlockLineLayout::nextLineBreak(): once
54823         when adding the width of the <img> object to the line, and a second time when adding
54824         the 'Text'. The result was that nextLineBreak() now had a length for the line that 
54825         exceeded the line's maximum length and inserted a bogus line break.
54826
54827         This all happened because the helper function that is used to add in the border etc.
54828         from inline ancestors was crawling up the tree each time. It doesn't need to do that, it
54829         should stop crawling up the tree when the current object is not the first or last sibling below a parent.
54830
54831         Test: fast/inline/bpm-inline-ancestors.html
54832
54833         * rendering/RenderBlockLineLayout.cpp:
54834         (WebCore::shouldAddBorderPaddingMargin): Broke this check out into a helper function so that it 
54835         can help inlineLogicalWidth() return early and also treat empty RenderTexts the same as no previous/next
54836         sibling on the line. This ensures that collapsed leading space does not interfere with the decision to
54837         crawl up the ancestors accumulating border, padding, and margin.
54838         (WebCore):
54839         (WebCore::inlineLogicalWidth): Return early once the current child is no longer on the edge of its line - 
54840         this ensures the border, padding and margin of ancestors is not counted twice. 
54841
54842 2012-10-08  Mike West  <mkwst@chromium.org>
54843
54844         Null-check for DOMWindow before feeding it to FeatureObserver.
54845         https://bugs.webkit.org/show_bug.cgi?id=98624
54846
54847         Reviewed by Adam Barth.
54848
54849         We shouldn't call out to FeatureObserver in
54850         ContentSecurityPolicy::didReceiveHeader if the policy's document doesn't
54851         have a DOMWindow.
54852
54853         Test: http/tests/security/contentSecurityPolicy/xmlhttprequest-protected-resource-does-not-crash.html
54854
54855         * page/ContentSecurityPolicy.cpp:
54856         (WebCore::ContentSecurityPolicy::didReceiveHeader):
54857             Null check 'document->domWindow' before passing it on.
54858         * page/FeatureObserver.cpp:
54859         (WebCore::FeatureObserver::observe):
54860             ASSERT 'domWindow'.
54861
54862 2012-10-08  Nate Chapin  <japhet@chromium.org>
54863
54864         Loader cleanup : Simplify FrameLoader/DocumentLoader setupForReplace()
54865         https://bugs.webkit.org/show_bug.cgi?id=49072
54866
54867         Reviewed by Eric Seidel.
54868
54869         This patch contains one small known behavior change: multipart/x-mixed-replace main resources with text/html parts
54870         will no longer load the text/html progressively. In practice, loading the html progressively causes the document
54871         to get cleared as soon as the next part's data starts arriving, which leads to a blank page most of the time. This case
54872         seems to be pathological, as IE, FF, Opera and WebKit all do something different currently. This patch will cause
54873         us to behave like Firefox, which is the most sane of the current behaviors.
54874
54875         Test: http/tests/multipart/multipart-html.php
54876
54877         * loader/DocumentLoader.cpp:
54878         (WebCore::DocumentLoader::commitData): Use isMultipartReplacingLoad() helper.
54879         (WebCore::DocumentLoader::receivedData):
54880         (WebCore::DocumentLoader::setupForReplace): Renamed from setupForReplaceByMIMEType(). Call maybeFinishLoadingMultipartContent()
54881             instead of doing identical work inline. After we call frameLoader()->setReplacing(), we will never load progressively, so remove
54882             the if (doesProgressiveLoad(newMIMEType)) {} block.
54883         (WebCore::DocumentLoader::isMultipartReplacingLoad):
54884         (WebCore::DocumentLoader::maybeFinishLoadingMultipartContent): Inline the old DocumentLoader::setupForeReplace(), check
54885             frameLoader()->isReplacing() instead of the delete doesProgressiveLoad().
54886         * loader/DocumentLoader.h:
54887         * loader/FrameLoader.cpp:
54888         (WebCore::FrameLoader::setupForReplace): Move all calls to revertToProvisionalState here.
54889         * loader/MainResourceLoader.cpp:
54890         (WebCore::MainResourceLoader::didReceiveResponse): Call setupForReplace(), renamed from setupForReplaceByMIMEType().
54891
54892 2012-10-08  Zoltan Horvath  <zoltan@webkit.org>
54893
54894         [Qt] r122720 causes performance regression with DirectFB on ARMv7
54895         https://bugs.webkit.org/show_bug.cgi?id=97548
54896
54897         Reviewed by Jocelyn Turcotte.
54898
54899         Revert the rest of r122720. This change modifies the NativeImagePtr from QImage* to QPixmap*.
54900
54901         Covered by existing tests.
54902
54903         * bridge/qt/qt_pixmapruntime.cpp:
54904         (JSC::Bindings::assignToHTMLImageElement):
54905         (JSC::Bindings::QtPixmapRuntime::toQt):
54906         * platform/DragImage.h:
54907         (WebCore):
54908         * platform/graphics/GraphicsContext.h:
54909         (GraphicsContext):
54910         * platform/graphics/Image.h:
54911         (Image):
54912         * platform/graphics/NativeImagePtr.h:
54913         (WebCore):
54914         * platform/graphics/gstreamer/ImageGStreamer.h:
54915         * platform/graphics/gstreamer/ImageGStreamerQt.cpp:
54916         (ImageGStreamer::ImageGStreamer):
54917         * platform/graphics/qt/GraphicsContext3DQt.cpp:
54918         (WebCore::GraphicsContext3D::getImageData):
54919         * platform/graphics/qt/GraphicsContextQt.cpp:
54920         (WebCore::GraphicsContext::pushTransparencyLayerInternal):
54921         (WebCore::GraphicsContext::beginPlatformTransparencyLayer):
54922         (WebCore::GraphicsContext::endPlatformTransparencyLayer):
54923         * platform/graphics/qt/ImageBufferDataQt.h:
54924         (ImageBufferData):
54925         * platform/graphics/qt/ImageBufferQt.cpp:
54926         (WebCore::ImageBufferData::ImageBufferData):
54927         (WebCore):
54928         (WebCore::ImageBufferData::toQImage):
54929         (WebCore::ImageBuffer::copyImage):
54930         (WebCore::ImageBuffer::clip):
54931         (WebCore::ImageBuffer::platformTransformColorSpace):
54932         (WebCore::getImageData):
54933         (WebCore::ImageBuffer::putByteArray):
54934         (WebCore::encodeImage):
54935         (WebCore::ImageBuffer::toDataURL):
54936         * platform/graphics/qt/ImageDecoderQt.cpp:
54937         (WebCore::ImageFrame::asNewNativeImage):
54938         * platform/graphics/qt/ImageQt.cpp:
54939         (graphics):
54940         (loadResourcePixmap):
54941         (WebCore::Image::loadPlatformResource):
54942         (WebCore::Image::setPlatformResource):
54943         (WebCore::Image::drawPattern):
54944         (WebCore::BitmapImage::BitmapImage):
54945         (WebCore::BitmapImage::draw):
54946         (WebCore::BitmapImage::checkForSolidColor):
54947         (WebCore::BitmapImage::create):
54948         * platform/graphics/qt/PatternQt.cpp:
54949         (WebCore::Pattern::createPlatformPattern):
54950         * platform/graphics/qt/StillImageQt.cpp:
54951         (WebCore::StillImage::StillImage):
54952         (WebCore::StillImage::~StillImage):
54953         (WebCore::StillImage::currentFrameHasAlpha):
54954         (WebCore::StillImage::size):
54955         (WebCore::StillImage::nativeImageForCurrentFrame):
54956         (WebCore::StillImage::draw):
54957         * platform/graphics/qt/StillImageQt.h:
54958         (WebCore::StillImage::create):
54959         (WebCore::StillImage::createForRendering):
54960         (StillImage):
54961         * platform/graphics/qt/TransparencyLayer.h:
54962         (WebCore::TransparencyLayer::TransparencyLayer):
54963         (TransparencyLayer):
54964         * platform/graphics/surfaces/qt/GraphicsSurfaceQt.cpp:
54965         (WebCore::GraphicsSurface::createReadOnlyImage):
54966         * platform/graphics/texmap/TextureMapperGL.cpp:
54967         (WebCore::BitmapTextureGL::updateContents):
54968         * platform/qt/ClipboardQt.cpp:
54969         (WebCore::ClipboardQt::createDragImage):
54970         (WebCore::ClipboardQt::declareAndWriteDragImage):
54971         * platform/qt/CursorQt.cpp:
54972         (WebCore::createCustomCursor):
54973         * platform/qt/DragImageQt.cpp:
54974         (WebCore::createDragImageFromImage):
54975         * platform/qt/PasteboardQt.cpp:
54976         (WebCore::Pasteboard::writeImage):
54977
54978 2012-10-08  Carlos Garcia Campos  <cgarcia@igalia.com>
54979
54980         Unreviewed. Fix make distcheck.
54981
54982         * GNUmakefile.list.am: Add missing header file to compilation.
54983
54984 2012-10-08  Sheriff Bot  <webkit.review.bot@gmail.com>
54985
54986         Unreviewed, rolling out r130619.
54987         http://trac.webkit.org/changeset/130619
54988         https://bugs.webkit.org/show_bug.cgi?id=98634
54989
54990         Causes many crashes on the EFL bots. (Requested by rakuco on
54991         #webkit).
54992
54993         * platform/RunLoop.h:
54994         (RunLoop):
54995         * platform/efl/RunLoopEfl.cpp:
54996         (WebCore::RunLoop::RunLoop):
54997         (WebCore::RunLoop::wakeUpEvent):
54998         (WebCore::RunLoop::wakeUp):
54999
55000 2012-10-08  Byungwoo Lee  <bw80.lee@samsung.com>
55001
55002         [EFL] Use ecore_main_loop_thread_safe_call_async() to wakeup main loop.
55003         https://bugs.webkit.org/show_bug.cgi?id=98505
55004
55005         Reviewed by Kenneth Rohde Christiansen.
55006
55007         Instead of ecore_pipe_write(),
55008         use ecore_main_loop_thread_safe_call_async() to wakeup ecore main loop.
55009
55010         According to the EFL API document, this function is designed to dispatch
55011         a function on ecore main loop by avoiding dead lock or race condition. 
55012         With this function, webkit doesn't need to maintain ecore pipe also.
55013
55014         No new tests. The function to wakeup main loop is changed.
55015
55016         * platform/RunLoop.h:
55017         (RunLoop):
55018         * platform/efl/RunLoopEfl.cpp:
55019         (WebCore::RunLoop::RunLoop):
55020         (WebCore::RunLoop::wakeUpEvent):
55021         (WebCore::RunLoop::wakeUp):
55022
55023 2012-10-07  Arpita Bahuguna  <arpitabahuguna@gmail.com>
55024
55025         :first-line pseudo selector ignoring words created from :before
55026         https://bugs.webkit.org/show_bug.cgi?id=80794
55027
55028         Reviewed by Daniel Bates.
55029
55030         The :first-line pseudo-element style is not applied for content
55031         which is generated from the :before/:after pseudo-elements.
55032
55033         Test: fast/css/first-line-style-for-before-after-content.html
55034
55035         * rendering/RenderObject.cpp:
55036         (WebCore::firstLineStyleForCachedUncachedType):
55037         Added a new static helper function incorporating the common
55038         functionality of both uncachedFirstLineStyle() and firstLineStyleSlowCase()
55039         functions. It also modifies the functionality to handle the
55040         scenario when :first-line style needs to be applied on content
55041         generated from :before/:after.
55042
55043         While getting the :first-line style we should also consider the case
55044         when the content is generated from a :before/:after pseudo-element in
55045         which case the RenderInline's parent should be considered for
55046         obtaining the first-line style.
55047
55048         (WebCore):
55049         (WebCore::RenderObject::uncachedFirstLineStyle):
55050         (WebCore::RenderObject::firstLineStyleSlowCase):
55051         Moved the duplicate code between the two functions to the common
55052         helper function firstLineStyleForCachedUncachedType().
55053
55054 2012-10-07  Peter Wang  <peter.wang@torchmobile.com.cn>
55055
55056         Web Inspector: The front-end should provide the position in original source file when set a breakpoint
55057         https://bugs.webkit.org/show_bug.cgi?id=93473
55058
55059         Reviewed by Yury Semikhatsky.
55060
55061         Since frontend truncates the indent, the first statement in a line must match the breakpoint (line, 0).
55062         With this patch JSC debugger can support both normal and "Pretty Print" mode.
55063
55064         No new test case. This patch can be verified with cases in "LayoutTests/inspector/debugger/".
55065
55066         * bindings/js/ScriptDebugServer.cpp:
55067         (WebCore::ScriptDebugServer::ScriptDebugServer):
55068         (WebCore::ScriptDebugServer::hasBreakpoint):
55069         (WebCore::ScriptDebugServer::createCallFrameAndPauseIfNeeded):
55070         (WebCore::ScriptDebugServer::pauseIfNeeded):
55071         * bindings/js/ScriptDebugServer.h:
55072         (ScriptDebugServer):
55073
55074 2012-10-07  Martin Robinson  <mrobinson@igalia.com>
55075
55076         [Soup] Clean up ResourceError creation
55077         https://bugs.webkit.org/show_bug.cgi?id=98521
55078
55079         Reviewed by Carlos Garcia Campos.
55080
55081         Simplify the creation of ResourcErrors in ResourceHandleSoup. This is
55082         part of a process to make the libsoup networking backend more hackable.
55083
55084         No new tests. This shouldn't change functionality.
55085
55086         * GNUmakefile.list.am: Added new file.
55087         * PlatformEfl.cmake: Added new file.
55088         * platform/network/soup/ResourceError.h:
55089         (ResourceError): Added new factories.
55090         * platform/network/soup/ResourceErrorSoup.cpp: Added.
55091         (WebCore::failingURI): Added this helper.
55092         (WebCore::ResourceError::httpError): New factory.
55093         (WebCore::ResourceError::genericIOError): Ditto.
55094         (WebCore::ResourceError::tlsError): Ditto.
55095         (WebCore::ResourceError::timeoutError): Ditto.
55096         * platform/network/soup/ResourceHandleSoup.cpp:
55097         (WebCore::handleUnignoredTLSErrors): Created this helper which merges
55098         some of the logic from sendRequestCallback.
55099         (WebCore::sendRequestCallback): Use the new helper.
55100         (WebCore::requestTimeoutCallback): Use the new factory.
55101
55102 2012-10-07  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
55103
55104         Rename first/second to key/value in HashMap iterators
55105         https://bugs.webkit.org/show_bug.cgi?id=82784
55106
55107         Reviewed by Eric Seidel.
55108
55109         * Modules/geolocation/Geolocation.cpp:
55110         (WebCore::Geolocation::Watchers::find):
55111         (WebCore::Geolocation::Watchers::remove):
55112         * Modules/indexeddb/IDBDatabase.cpp:
55113         (WebCore::IDBDatabase::objectStoreNames):
55114         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
55115         (WebCore::IDBDatabaseBackendImpl::metadata):
55116         * Modules/indexeddb/IDBFactoryBackendImpl.cpp:
55117         (WebCore::IDBFactoryBackendImpl::deleteDatabase):
55118         (WebCore::IDBFactoryBackendImpl::openBackingStore):
55119         (WebCore::IDBFactoryBackendImpl::open):
55120         * Modules/indexeddb/IDBObjectStore.cpp:
55121         (WebCore::IDBObjectStore::indexNames):
55122         (WebCore::IDBObjectStore::put):
55123         (WebCore::IDBObjectStore::index):
55124         (WebCore::IDBObjectStore::deleteIndex):
55125         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
55126         (WebCore::IDBObjectStoreBackendImpl::metadata):
55127         (WebCore::makeIndexWriters):
55128         (WebCore::IDBObjectStoreBackendImpl::deleteInternal):
55129         * Modules/indexeddb/IDBTransaction.cpp:
55130         (WebCore::IDBTransaction::objectStore):
55131         (WebCore::IDBTransaction::objectStoreDeleted):
55132         (WebCore::IDBTransaction::onAbort):
55133         (WebCore::IDBTransaction::dispatchEvent):
55134         * Modules/mediastream/MediaConstraintsImpl.cpp:
55135         (WebCore::MediaConstraintsImpl::getMandatoryConstraints):
55136         (WebCore::MediaConstraintsImpl::getMandatoryConstraintValue):
55137         * Modules/webdatabase/AbstractDatabase.cpp:
55138         (WebCore::AbstractDatabase::performOpenAndVerify):
55139         * Modules/webdatabase/DatabaseTracker.cpp:
55140         (WebCore::DatabaseTracker::interruptAllDatabasesForContext):
55141         * Modules/webdatabase/OriginUsageRecord.cpp:
55142         (WebCore::OriginUsageRecord::diskUsage):
55143         * Modules/webdatabase/SQLTransactionCoordinator.cpp:
55144         (WebCore::SQLTransactionCoordinator::acquireLock):
55145         (WebCore::SQLTransactionCoordinator::releaseLock):
55146         (WebCore::SQLTransactionCoordinator::shutdown):
55147         * Modules/webdatabase/chromium/DatabaseTrackerChromium.cpp:
55148         (WebCore::DatabaseTracker::interruptAllDatabasesForContext):
55149         * Modules/webdatabase/chromium/QuotaTracker.cpp:
55150         (WebCore::QuotaTracker::getDatabaseSizeAndSpaceAvailableToOrigin):
55151         (WebCore::QuotaTracker::updateDatabaseSize):
55152         * Modules/websockets/WebSocketDeflateFramer.cpp:
55153         (WebCore::WebSocketExtensionDeflateFrame::processResponse):
55154         * Modules/websockets/WebSocketExtensionDispatcher.cpp:
55155         (WebCore::WebSocketExtensionDispatcher::appendAcceptedExtension):
55156         * accessibility/AXObjectCache.cpp:
55157         (WebCore::AXObjectCache::~AXObjectCache):
55158         * bindings/gobject/DOMObjectCache.cpp:
55159         (WebKit::DOMObjectCache::clearByFrame):
55160         * bindings/js/DOMObjectHashTableMap.h:
55161         (WebCore::DOMObjectHashTableMap::~DOMObjectHashTableMap):
55162         (WebCore::DOMObjectHashTableMap::get):
55163         * bindings/js/JSDOMBinding.cpp:
55164         (WebCore::cacheDOMStructure):
55165         * bindings/js/JSDOMGlobalObject.cpp:
55166         (WebCore::JSDOMGlobalObject::visitChildren):
55167         * bindings/js/JSDOMGlobalObject.h:
55168         (WebCore::getDOMConstructor):
55169         * bindings/js/PageScriptDebugServer.cpp:
55170         (WebCore::PageScriptDebugServer::addListener):
55171         (WebCore::PageScriptDebugServer::removeListener):
55172         * bindings/js/ScriptCachedFrameData.cpp:
55173         (WebCore::ScriptCachedFrameData::ScriptCachedFrameData):
55174         (WebCore::ScriptCachedFrameData::restore):
55175         * bindings/js/ScriptController.cpp:
55176         (WebCore::ScriptController::~ScriptController):
55177         (WebCore::ScriptController::clearWindowShell):
55178         (WebCore::ScriptController::attachDebugger):
55179         (WebCore::ScriptController::updateDocument):
55180         (WebCore::ScriptController::createRootObject):
55181         (WebCore::ScriptController::collectIsolatedContexts):
55182         (WebCore::ScriptController::cleanupScriptObjectsForPlugin):
55183         (WebCore::ScriptController::clearScriptObjects):
55184         * bindings/js/ScriptController.h:
55185         (WebCore::ScriptController::windowShell):
55186         (WebCore::ScriptController::existingWindowShell):
55187         * bindings/js/ScriptDebugServer.cpp:
55188         (WebCore::ScriptDebugServer::setBreakpoint):
55189         (WebCore::ScriptDebugServer::removeBreakpoint):
55190         (WebCore::ScriptDebugServer::hasBreakpoint):
55191         * bindings/js/SerializedScriptValue.cpp:
55192         (WebCore::CloneSerializer::checkForDuplicate):
55193         (WebCore::CloneSerializer::dumpIfTerminal):
55194         (WebCore::CloneSerializer::write):
55195         * bindings/scripts/CodeGeneratorV8.pm:
55196         (GenerateImplementation):
55197         * bindings/scripts/test/V8/V8Float64Array.cpp:
55198         (WebCore::V8Float64Array::GetRawTemplate):
55199         (WebCore::V8Float64Array::GetTemplate):
55200         * bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
55201         (WebCore::V8TestActiveDOMObject::GetRawTemplate):
55202         (WebCore::V8TestActiveDOMObject::GetTemplate):
55203         * bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
55204         (WebCore::V8TestCustomNamedGetter::GetRawTemplate):
55205         (WebCore::V8TestCustomNamedGetter::GetTemplate):
55206         * bindings/scripts/test/V8/V8TestEventConstructor.cpp:
55207         (WebCore::V8TestEventConstructor::GetRawTemplate):
55208         (WebCore::V8TestEventConstructor::GetTemplate):
55209         * bindings/scripts/test/V8/V8TestEventTarget.cpp:
55210         (WebCore::V8TestEventTarget::GetRawTemplate):
55211         (WebCore::V8TestEventTarget::GetTemplate):
55212         * bindings/scripts/test/V8/V8TestException.cpp:
55213         (WebCore::V8TestException::GetRawTemplate):
55214         (WebCore::V8TestException::GetTemplate):
55215         * bindings/scripts/test/V8/V8TestInterface.cpp:
55216         (WebCore::V8TestInterface::GetRawTemplate):
55217         (WebCore::V8TestInterface::GetTemplate):
55218         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
55219         (WebCore::V8TestMediaQueryListListener::GetRawTemplate):
55220         (WebCore::V8TestMediaQueryListListener::GetTemplate):
55221         * bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
55222         (WebCore::V8TestNamedConstructor::GetRawTemplate):
55223         (WebCore::V8TestNamedConstructor::GetTemplate):
55224         * bindings/scripts/test/V8/V8TestNode.cpp:
55225         (WebCore::V8TestNode::GetRawTemplate):
55226         (WebCore::V8TestNode::GetTemplate):
55227         * bindings/scripts/test/V8/V8TestObj.cpp:
55228         (WebCore::V8TestObj::GetRawTemplate):
55229         (WebCore::V8TestObj::GetTemplate):
55230         * bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
55231         (WebCore::V8TestSerializedScriptValueInterface::GetRawTemplate):
55232         (WebCore::V8TestSerializedScriptValueInterface::GetTemplate):
55233         * bindings/v8/DOMWrapperWorld.cpp:
55234         (WebCore::DOMWrapperWorld::deallocate):
55235         (WebCore::DOMWrapperWorld::ensureIsolatedWorld):
55236         * bindings/v8/NPV8Object.cpp:
55237         (WebCore::freeV8NPObject):
55238         (WebCore::npCreateV8ScriptObject):
55239         * bindings/v8/ScriptController.cpp:
55240         (WebCore::ScriptController::clearScriptObjects):
55241         (WebCore::ScriptController::resetIsolatedWorlds):
55242         (WebCore::ScriptController::ensureIsolatedWorldContext):
55243         (WebCore::ScriptController::existingWindowShellInternal):
55244         (WebCore::ScriptController::evaluateInIsolatedWorld):
55245         (WebCore::ScriptController::setIsolatedWorldSecurityOrigin):
55246         (WebCore::ScriptController::cleanupScriptObjectsForPlugin):
55247         (WebCore::ScriptController::collectIsolatedContexts):
55248         * bindings/v8/SerializedScriptValue.cpp:
55249         * bindings/v8/V8DOMMap.h:
55250         (WebCore::WeakReferenceMap::removeIfPresent):
55251         (WebCore::WeakReferenceMap::visit):
55252         * bindings/v8/V8PerContextData.cpp:
55253         (WebCore::V8PerContextData::dispose):
55254         * bindings/v8/npruntime.cpp:
55255         * bridge/IdentifierRep.cpp:
55256         (WebCore::IdentifierRep::get):
55257         * bridge/NP_jsobject.cpp:
55258         (ObjectMap::add):
55259         (ObjectMap::remove):
55260         * bridge/runtime_root.cpp:
55261         (JSC::Bindings::RootObject::invalidate):
55262         * css/CSSCanvasValue.cpp:
55263         (WebCore::CSSCanvasValue::canvasChanged):
55264         (WebCore::CSSCanvasValue::canvasResized):
55265         * css/CSSComputedStyleDeclaration.cpp:
55266         (WebCore::counterToCSSValue):
55267         * css/CSSCrossfadeValue.cpp:
55268         (WebCore::CSSCrossfadeValue::crossfadeChanged):
55269         * css/CSSFontFaceSource.cpp:
55270         (WebCore::CSSFontFaceSource::getFontData):
55271         * css/CSSFontSelector.cpp:
55272         (WebCore::CSSFontSelector::addFontFaceRule):
55273         (WebCore::CSSFontSelector::getFontData):
55274         * css/CSSImageGeneratorValue.cpp:
55275         (WebCore::CSSImageGeneratorValue::addClient):
55276         (WebCore::CSSImageGeneratorValue::removeClient):
55277         (WebCore::CSSImageGeneratorValue::getImage):
55278         * css/CSSSegmentedFontFace.cpp:
55279         (WebCore::CSSSegmentedFontFace::getFontData):
55280         * css/CSSSelector.cpp:
55281         (WebCore::CSSSelector::parsePseudoType):
55282         * css/CSSValuePool.cpp:
55283         (WebCore::CSSValuePool::createColorValue):
55284         (WebCore::CSSValuePool::createFontFamilyValue):
55285         (WebCore::CSSValuePool::createFontFaceValue):
55286         * css/PropertySetCSSStyleDeclaration.cpp:
55287         (WebCore::PropertySetCSSStyleDeclaration::cloneAndCacheForCSSOM):
55288         * css/RuleSet.cpp:
55289         (WebCore::reportAtomRuleMap):
55290         (WebCore::RuleSet::addToRuleSet):
55291         (WebCore::shrinkMapVectorsToFit):
55292         * css/StyleBuilder.cpp:
55293         (WebCore::ApplyPropertyCounter::applyInheritValue):
55294         (WebCore::ApplyPropertyCounter::applyValue):
55295         * css/StyleResolver.cpp:
55296         (WebCore::StyleResolver::collectFeatures):
55297         (WebCore::StyleResolver::ruleSetForScope):
55298         (WebCore::StyleResolver::appendAuthorStylesheets):
55299         (WebCore::StyleResolver::sweepMatchedPropertiesCache):
55300         (WebCore::StyleResolver::collectMatchingRulesForList):
55301         * css/StyleSheetContents.cpp:
55302         (WebCore::StyleSheetContents::parserAddNamespace):
55303         (WebCore::StyleSheetContents::determineNamespace):
55304         * dom/CheckedRadioButtons.cpp:
55305         (WebCore::CheckedRadioButtons::addButton):
55306         (WebCore::CheckedRadioButtons::removeButton):
55307         * dom/ChildListMutationScope.cpp:
55308         (WebCore::ChildListMutationAccumulator::getOrCreate):
55309         * dom/Document.cpp:
55310         (WebCore::Document::windowNamedItems):
55311         (WebCore::Document::documentNamedItems):
55312         (WebCore::Document::getCSSCanvasElement):
55313         (WebCore::Document::cachedImmutableAttributeData):
55314         (WebCore::Document::getCachedLocalizer):
55315         * dom/DocumentMarkerController.cpp:
55316         (WebCore::DocumentMarkerController::markerContainingPoint):
55317         (WebCore::DocumentMarkerController::renderedRectsForMarkers):
55318         (WebCore::DocumentMarkerController::removeMarkers):
55319         (WebCore::DocumentMarkerController::repaintMarkers):
55320         (WebCore::DocumentMarkerController::invalidateRenderedRectsForMarkersInRect):
55321         (WebCore::DocumentMarkerController::showMarkers):
55322         * dom/DocumentOrderedMap.cpp:
55323         (WebCore::DocumentOrderedMap::remove):
55324         * dom/DocumentStyleSheetCollection.cpp:
55325         (WebCore::DocumentStyleSheetCollection::pageGroupUserSheets):
55326         * dom/ElementAttributeData.cpp:
55327         (WebCore::ensureAttrListForElement):
55328         * dom/EventDispatcher.cpp:
55329         (WebCore::EventRelatedTargetAdjuster::findRelatedTarget):
55330         * dom/IdTargetObserverRegistry.cpp:
55331         (WebCore::IdTargetObserverRegistry::addObserver):
55332         (WebCore::IdTargetObserverRegistry::removeObserver):
55333         * dom/MutationObserverInterestGroup.cpp:
55334         (WebCore::MutationObserverInterestGroup::isOldValueRequested):
55335         (WebCore::MutationObserverInterestGroup::enqueueMutationRecord):
55336         * dom/Node.cpp:
55337         (WebCore::Node::dumpStatistics):
55338         (WebCore::Node::clearRareData):
55339         (WebCore::NodeListsNodeData::invalidateCaches):
55340         (WebCore::collectMatchingObserversForMutation):
55341         * dom/NodeRareData.h:
55342         (WebCore::NodeListsNodeData::addCacheWithAtomicName):
55343         (WebCore::NodeListsNodeData::addCacheWithName):
55344         (WebCore::NodeListsNodeData::addCacheWithQualifiedName):
55345         (WebCore::NodeListsNodeData::adoptTreeScope):
55346         * dom/ProcessingInstruction.cpp:
55347         (WebCore::ProcessingInstruction::checkStyleSheet):
55348         * dom/ScriptExecutionContext.cpp:
55349         (WebCore::ScriptExecutionContext::canSuspendActiveDOMObjects):
55350         (WebCore::ScriptExecutionContext::suspendActiveDOMObjects):
55351         (WebCore::ScriptExecutionContext::resumeActiveDOMObjects):
55352         (WebCore::ScriptExecutionContext::stopActiveDOMObjects):
55353         (WebCore::ScriptExecutionContext::adjustMinimumTimerInterval):
55354         * dom/SelectorQuery.cpp:
55355         (WebCore::SelectorQueryCache::add):
55356         * dom/SpaceSplitString.cpp:
55357         (WebCore::SpaceSplitStringData::create):
55358         * dom/StyledElement.cpp:
55359         (WebCore::StyledElement::updateAttributeStyle):
55360         * editing/mac/AlternativeTextUIController.mm:
55361         (WebCore::AlternativeTextUIController::AlernativeTextContextController::alternativesForContext):
55362         * html/FormController.cpp:
55363         (WebCore::SavedFormState::serializeTo):
55364         (WebCore::SavedFormState::appendControlState):
55365         (WebCore::SavedFormState::takeControlState):
55366         (WebCore::SavedFormState::getReferencedFilePaths):
55367         (WebCore::FormKeyGenerator::formKey):
55368         (WebCore::FormController::createSavedFormStateMap):
55369         (WebCore::FormController::formElementsState):
55370         (WebCore::FormController::takeStateForFormElement):
55371         (WebCore::FormController::getReferencedFilePaths):
55372         * html/HTMLCollection.cpp:
55373         (WebCore::HTMLCollectionCacheBase::append):
55374         * html/canvas/WebGLFramebuffer.cpp:
55375         (WebCore::WebGLFramebuffer::getAttachment):
55376         (WebCore::WebGLFramebuffer::removeAttachmentFromBoundFramebuffer):
55377         (WebCore::WebGLFramebuffer::checkStatus):
55378         (WebCore::WebGLFramebuffer::deleteObjectImpl):
55379         (WebCore::WebGLFramebuffer::initializeAttachments):
55380         * inspector/CodeGeneratorInspector.py:
55381         * inspector/DOMPatchSupport.cpp:
55382         (WebCore::DOMPatchSupport::diff):
55383         (WebCore::DOMPatchSupport::innerPatchChildren):
55384         (WebCore::DOMPatchSupport::removeChildAndMoveToNew):
55385         * inspector/InjectedScriptManager.cpp:
55386         (WebCore::InjectedScriptManager::injectedScriptForId):
55387         (WebCore::InjectedScriptManager::injectedScriptIdFor):
55388         (WebCore::InjectedScriptManager::discardInjectedScriptsFor):
55389         (WebCore::InjectedScriptManager::releaseObjectGroup):
55390         (WebCore::InjectedScriptManager::injectedScriptFor):
55391         * inspector/InspectorCSSAgent.cpp:
55392         (WebCore::SelectorProfile::commitSelector):
55393         (WebCore::SelectorProfile::commitSelectorTime):
55394         (WebCore::SelectorProfile::toInspectorObject):
55395         (WebCore::UpdateRegionLayoutTask::onTimer):
55396         (WebCore::InspectorCSSAgent::forcePseudoState):
55397         (WebCore::InspectorCSSAgent::asInspectorStyleSheet):
55398         (WebCore::InspectorCSSAgent::assertStyleSheetForId):
55399         (WebCore::InspectorCSSAgent::didRemoveDOMNode):
55400         (WebCore::InspectorCSSAgent::didModifyDOMAttr):
55401         (WebCore::InspectorCSSAgent::resetPseudoStates):
55402         * inspector/InspectorConsoleAgent.cpp:
55403         (WebCore::InspectorConsoleAgent::stopTiming):
55404         (WebCore::InspectorConsoleAgent::count):
55405         * inspector/InspectorDOMAgent.cpp:
55406         (WebCore::InspectorDOMAgent::nodeForId):
55407         (WebCore::InspectorDOMAgent::performSearch):
55408         (WebCore::InspectorDOMAgent::getSearchResults):
55409         * inspector/InspectorDOMDebuggerAgent.cpp:
55410         (WebCore::InspectorDOMDebuggerAgent::willSendXMLHttpRequest):
55411         * inspector/InspectorDOMStorageAgent.cpp:
55412         (WebCore::InspectorDOMStorageAgent::clearFrontend):
55413         (WebCore::InspectorDOMStorageAgent::enable):
55414         (WebCore::InspectorDOMStorageAgent::storageId):
55415         (WebCore::InspectorDOMStorageAgent::getDOMStorageResourceForId):
55416         (WebCore::InspectorDOMStorageAgent::didUseDOMStorage):
55417         (WebCore::InspectorDOMStorageAgent::memoryBytesUsedByStorageCache):
55418         * inspector/InspectorDatabaseAgent.cpp:
55419         (WebCore::InspectorDatabaseAgent::enable):
55420         (WebCore::InspectorDatabaseAgent::databaseId):
55421         (WebCore::InspectorDatabaseAgent::findByFileName):
55422         (WebCore::InspectorDatabaseAgent::databaseForId):
55423         * inspector/InspectorDebuggerAgent.cpp:
55424         (WebCore::InspectorDebuggerAgent::setBreakpointByUrl):
55425         (WebCore::InspectorDebuggerAgent::removeBreakpoint):
55426         (WebCore::InspectorDebuggerAgent::resolveBreakpoint):
55427         (WebCore::InspectorDebuggerAgent::searchInContent):
55428         (WebCore::InspectorDebuggerAgent::getScriptSource):
55429         (WebCore::InspectorDebuggerAgent::didParseSource):
55430         * inspector/InspectorIndexedDBAgent.cpp:
55431         (WebCore):
55432         * inspector/InspectorMemoryAgent.cpp:
55433         (WebCore):
55434         * inspector/InspectorPageAgent.cpp:
55435         (WebCore::cachedResourcesForFrame):
55436         (WebCore::InspectorPageAgent::didClearWindowObjectInWorld):
55437         (WebCore::InspectorPageAgent::frameDetached):
55438         * inspector/InspectorProfilerAgent.cpp:
55439         (WebCore::InspectorProfilerAgent::getProfileHeaders):
55440         (WebCore):
55441         (WebCore::InspectorProfilerAgent::getProfile):
55442         * inspector/InspectorResourceAgent.cpp:
55443         (WebCore::buildObjectForHeaders):
55444         (WebCore::InspectorResourceAgent::willSendRequest):
55445         (WebCore::InspectorResourceAgent::documentThreadableLoaderStartedLoadingForClient):
55446         (WebCore::InspectorResourceAgent::willLoadXHR):
55447         (WebCore::InspectorResourceAgent::replayXHR):
55448         * inspector/InspectorState.cpp:
55449         (WebCore::InspectorState::getBoolean):
55450         (WebCore::InspectorState::getString):
55451         (WebCore::InspectorState::getLong):
55452         (WebCore::InspectorState::getDouble):
55453         (WebCore::InspectorState::getObject):
55454         * inspector/InspectorStyleSheet.cpp:
55455         (WebCore::InspectorStyle::styleWithProperties):
55456         (WebCore::InspectorStyleSheet::inspectorStyleForId):
55457         * inspector/InspectorValues.cpp:
55458         (WebCore::InspectorObjectBase::get):
55459         (WebCore::InspectorObjectBase::writeJSON):
55460         * inspector/InspectorWorkerAgent.cpp:
55461         (WebCore::InspectorWorkerAgent::workerContextTerminated):
55462         (WebCore::InspectorWorkerAgent::createWorkerFrontendChannelsForExistingWorkers):
55463         (WebCore::InspectorWorkerAgent::destroyWorkerFrontendChannels):
55464         * inspector/MemoryInstrumentationImpl.cpp:
55465         (WebCore::MemoryInstrumentationClientImpl::countObjectSize):
55466         * inspector/MemoryInstrumentationImpl.h:
55467         (WebCore::MemoryInstrumentationClientImpl::totalSize):
55468         (WebCore::MemoryInstrumentationClientImpl::reportedSizeForAllTypes):
55469         * inspector/NetworkResourcesData.cpp:
55470         (WebCore::NetworkResourcesData::setXHRReplayData):
55471         (WebCore::NetworkResourcesData::removeCachedResource):
55472         (WebCore::NetworkResourcesData::clear):
55473         * loader/CrossOriginAccessControl.cpp:
55474         (WebCore::isSimpleCrossOriginAccessRequest):
55475         (WebCore::createAccessControlPreflightRequest):
55476         * loader/CrossOriginPreflightResultCache.cpp:
55477         (WebCore::CrossOriginPreflightResultCacheItem::allowsCrossOriginHeaders):
55478         (WebCore::CrossOriginPreflightResultCache::canSkipPreflight):
55479         * loader/DocumentLoader.cpp:
55480         (WebCore::DocumentLoader::getSubresources):
55481         (WebCore::DocumentLoader::substituteResourceDeliveryTimerFired):
55482         * loader/MainResourceLoader.cpp:
55483         (WebCore::MainResourceLoader::didReceiveResponse):
55484         * loader/ResourceLoadScheduler.cpp:
55485         (WebCore::ResourceLoadScheduler::servePendingRequests):
55486         * loader/appcache/ApplicationCache.cpp:
55487         (WebCore::ApplicationCache::removeResource):
55488         (WebCore::ApplicationCache::clearStorageID):
55489         (WebCore::ApplicationCache::dump):
55490         * loader/appcache/ApplicationCacheGroup.cpp:
55491         (WebCore::ApplicationCacheGroup::didFinishLoadingManifest):
55492         (WebCore::ApplicationCacheGroup::startLoadingEntry):
55493         (WebCore::ApplicationCacheGroup::addEntry):
55494         * loader/appcache/ApplicationCacheHost.cpp:
55495         (WebCore::ApplicationCacheHost::fillResourceList):
55496         * loader/appcache/ApplicationCacheResource.cpp:
55497         (WebCore::ApplicationCacheResource::estimatedSizeInStorage):
55498         * loader/appcache/ApplicationCacheStorage.cpp:
55499         (WebCore::ApplicationCacheStorage::findOrCreateCacheGroup):
55500         (WebCore::ApplicationCacheStorage::cacheGroupForURL):
55501         (WebCore::ApplicationCacheStorage::fallbackCacheGroupForURL):
55502         (WebCore::ApplicationCacheStorage::store):
55503         (WebCore::ApplicationCacheStorage::empty):
55504         (WebCore::ApplicationCacheStorage::storeCopyOfCache):
55505         * loader/archive/ArchiveFactory.cpp:
55506         (WebCore::ArchiveFactory::registerKnownArchiveMIMETypes):
55507         * loader/cache/CachedRawResource.cpp:
55508         (WebCore::CachedRawResource::canReuse):
55509         * loader/cache/CachedResource.cpp:
55510         (WebCore::CachedResource::switchClientsToRevalidatedResource):
55511         (WebCore::CachedResource::updateResponseAfterRevalidation):
55512         * loader/cache/CachedResourceClientWalker.h:
55513         (WebCore::CachedResourceClientWalker::CachedResourceClientWalker):
55514         * loader/cache/CachedResourceLoader.cpp:
55515         (WebCore::CachedResourceLoader::~CachedResourceLoader):
55516         (WebCore::CachedResourceLoader::requestResource):
55517         (WebCore::CachedResourceLoader::reloadImagesIfNotDeferred):
55518         (WebCore::CachedResourceLoader::removeCachedResource):
55519         (WebCore::CachedResourceLoader::garbageCollectDocumentResources):
55520         * loader/cache/MemoryCache.cpp:
55521         (WebCore::MemoryCache::removeResourcesWithOrigin):
55522         (WebCore::MemoryCache::getOriginsWithCache):
55523         (WebCore::MemoryCache::getStatistics):
55524         (WebCore::MemoryCache::setDisabled):
55525         * loader/icon/IconDatabase.cpp:
55526         (WebCore::IconDatabase::removeAllIcons):
55527         (WebCore::IconDatabase::iconRecordCountWithData):
55528         (WebCore::IconDatabase::performPendingRetainAndReleaseOperations):
55529         * page/DOMWindow.cpp:
55530         (WebCore::DOMWindow::dispatchAllPendingBeforeUnloadEvents):
55531         (WebCore::DOMWindow::dispatchAllPendingUnloadEvents):
55532         * page/EventHandler.cpp:
55533         (WebCore::EventHandler::handleTouchEvent):
55534         * page/Frame.cpp:
55535         (WebCore::Frame::injectUserScripts):
55536         * page/PageGroup.cpp:
55537         (WebCore::PageGroup::pageGroup):
55538         (WebCore::PageGroup::closeLocalStorage):
55539         (WebCore::PageGroup::clearLocalStorageForAllOrigins):
55540         (WebCore::PageGroup::clearLocalStorageForOrigin):
55541         (WebCore::PageGroup::syncLocalStorage):
55542         (WebCore::PageGroup::addUserScriptToWorld):
55543         (WebCore::PageGroup::addUserStyleSheetToWorld):
55544         (WebCore::PageGroup::removeUserScriptFromWorld):
55545         (WebCore::PageGroup::removeUserStyleSheetFromWorld):
55546         * page/PageSerializer.cpp:
55547         (WebCore::PageSerializer::urlForBlankFrame):
55548         * page/SecurityPolicy.cpp:
55549         (WebCore::SecurityPolicy::addOriginAccessWhitelistEntry):
55550         (WebCore::SecurityPolicy::removeOriginAccessWhitelistEntry):
55551         * page/Settings.cpp:
55552         (WebCore::setGenericFontFamilyMap):
55553         (WebCore::getGenericFontFamilyForScript):
55554         * page/SpeechInput.cpp:
55555         (WebCore::SpeechInput::registerListener):
55556         * page/TouchDisambiguation.cpp:
55557         (WebCore::findGoodTouchTargets):
55558         * page/WindowFeatures.cpp:
55559         (WebCore::WindowFeatures::boolFeature):
55560         (WebCore::WindowFeatures::floatFeature):
55561         * page/animation/AnimationController.cpp:
55562         (WebCore::AnimationControllerPrivate::updateAnimations):
55563         (WebCore::AnimationControllerPrivate::suspendAnimationsForDocument):
55564         (WebCore::AnimationControllerPrivate::resumeAnimationsForDocument):
55565         (WebCore::AnimationControllerPrivate::numberOfActiveAnimations):
55566         * page/animation/CompositeAnimation.cpp:
55567         (WebCore::CompositeAnimation::clearRenderer):
55568         (WebCore::CompositeAnimation::updateTransitions):
55569         (WebCore::CompositeAnimation::updateKeyframeAnimations):
55570         (WebCore::CompositeAnimation::animate):
55571         (WebCore::CompositeAnimation::getAnimatedStyle):
55572         (WebCore::CompositeAnimation::setAnimating):
55573         (WebCore::CompositeAnimation::timeToNextService):
55574         (WebCore::CompositeAnimation::getAnimationForProperty):
55575         (WebCore::CompositeAnimation::suspendAnimations):
55576         (WebCore::CompositeAnimation::resumeAnimations):
55577         (WebCore::CompositeAnimation::overrideImplicitAnimations):
55578         (WebCore::CompositeAnimation::resumeOverriddenImplicitAnimations):
55579         (WebCore::CompositeAnimation::isAnimatingProperty):
55580         (WebCore::CompositeAnimation::numberOfActiveAnimations):
55581         * platform/Language.cpp:
55582         (WebCore::languageDidChange):
55583         * platform/MIMETypeRegistry.cpp:
55584         (WebCore::MIMETypeRegistry::getNormalizedMIMEType):
55585         * platform/audio/HRTFElevation.cpp:
55586         (WebCore::getConcatenatedImpulseResponsesForSubject):
55587         * platform/blackberry/CookieManager.cpp:
55588         (WebCore::CookieManager::generateHtmlFragmentForCookies):
55589         (WebCore::CookieManager::removeAllCookies):
55590         * platform/blackberry/CookieMap.cpp:
55591         (WebCore::CookieMap::removeOldestCookie):
55592         (WebCore::CookieMap::getAllChildCookies):
55593         * platform/cf/BinaryPropertyList.cpp:
55594         (WebCore::BinaryPropertyListPlan::writeIntegerArray):
55595         * platform/chromium/support/WebHTTPLoadInfo.cpp:
55596         (WebKit::addHeader):
55597         * platform/chromium/support/WebURLRequest.cpp:
55598         (WebKit::WebURLRequest::visitHTTPHeaderFields):
55599         * platform/chromium/support/WebURLResponse.cpp:
55600         (WebKit::WebURLResponse::addHTTPHeaderField):
55601         (WebKit::WebURLResponse::visitHTTPHeaderFields):
55602         * platform/graphics/DisplayRefreshMonitor.cpp:
55603         (WebCore::DisplayRefreshMonitorManager::ensureMonitorForClient):
55604         (WebCore::DisplayRefreshMonitorManager::unregisterClient):
55605         * platform/graphics/FontCache.cpp:
55606         (WebCore::FontCache::getCachedFontPlatformData):
55607         (WebCore::FontCache::getVerticalData):
55608         (WebCore::FontCache::getCachedFontData):
55609         (WebCore::FontCache::releaseFontData):
55610         (WebCore::FontCache::purgeInactiveFontData):
55611         * platform/graphics/GlyphPageTreeNode.cpp:
55612         (WebCore::GlyphPageTreeNode::treeGlyphPageCount):
55613         (WebCore::GlyphPageTreeNode::pageCount):
55614         (WebCore::GlyphPageTreeNode::pruneTreeCustomFontData):
55615         (WebCore::GlyphPageTreeNode::pruneTreeFontData):
55616         (WebCore::GlyphPageTreeNode::pruneCustomFontData):
55617         (WebCore::GlyphPageTreeNode::pruneFontData):
55618         (WebCore::GlyphPageTreeNode::showSubtree):
55619         (showGlyphPageTrees):
55620         * platform/graphics/TiledBackingStore.cpp:
55621         (WebCore::TiledBackingStore::updateTileBuffers):
55622         (WebCore::TiledBackingStore::resizeEdgeTiles):
55623         (WebCore::TiledBackingStore::setKeepRect):
55624         * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
55625         (WebCore::AVFWrapper::avfWrapperForCallbackContext):
55626         * platform/graphics/blackberry/LayerTiler.cpp:
55627         (WebCore::LayerTiler::layerVisibilityChanged):
55628         (WebCore::LayerTiler::uploadTexturesIfNeeded):
55629         (WebCore::LayerTiler::addTileJob):
55630         (WebCore::LayerTiler::deleteTextures):
55631         (WebCore::LayerTiler::pruneTextures):
55632         (WebCore::LayerTiler::bindContentsTexture):
55633         * platform/graphics/blackberry/TextureCacheCompositingThread.cpp:
55634         (WebCore::TextureCacheCompositingThread::textureForTiledContents):
55635         (WebCore::TextureCacheCompositingThread::textureForColor):
55636         * platform/graphics/ca/GraphicsLayerCA.cpp:
55637         (WebCore::GraphicsLayerCA::moveOrCopyAnimations):
55638         (WebCore::GraphicsLayerCA::pauseAnimation):
55639         (WebCore::GraphicsLayerCA::layerDidDisplay):
55640         (WebCore::GraphicsLayerCA::updateGeometry):
55641         (WebCore::GraphicsLayerCA::updateTransform):
55642         (WebCore::GraphicsLayerCA::updateChildrenTransform):
55643         (WebCore::GraphicsLayerCA::updateMasksToBounds):
55644         (WebCore::GraphicsLayerCA::updateContentsVisibility):
55645         (WebCore::GraphicsLayerCA::updateContentsOpaque):
55646         (WebCore::GraphicsLayerCA::updateBackfaceVisibility):
55647         (WebCore::GraphicsLayerCA::updateFilters):
55648         (WebCore::GraphicsLayerCA::ensureStructuralLayer):
55649         (WebCore::GraphicsLayerCA::updateLayerDrawsContent):
55650         (WebCore::GraphicsLayerCA::updateContentsImage):
55651         (WebCore::GraphicsLayerCA::updateContentsRect):
55652         (WebCore::GraphicsLayerCA::updateMaskLayer):
55653         (WebCore::GraphicsLayerCA::updateLayerAnimations):
55654         (WebCore::GraphicsLayerCA::setAnimationOnLayer):
55655         (WebCore::GraphicsLayerCA::removeCAAnimationFromLayer):
55656         (WebCore::GraphicsLayerCA::pauseCAAnimationOnLayer):
55657         (WebCore::GraphicsLayerCA::suspendAnimations):
55658         (WebCore::GraphicsLayerCA::resumeAnimations):
55659         (WebCore::GraphicsLayerCA::findOrMakeClone):
55660         (WebCore::GraphicsLayerCA::setOpacityInternal):
55661         (WebCore::GraphicsLayerCA::updateOpacityOnLayer):
55662         * platform/graphics/ca/mac/TileCache.mm:
55663         (WebCore::TileCache::~TileCache):
55664         (WebCore::TileCache::setNeedsDisplay):
55665         (WebCore::TileCache::setScale):
55666         (WebCore::TileCache::setAcceleratesDrawing):
55667         (WebCore::TileCache::setTileDebugBorderWidth):
55668         (WebCore::TileCache::setTileDebugBorderColor):
55669         (WebCore::TileCache::revalidateTiles):
55670         * platform/graphics/ca/win/PlatformCALayerWin.cpp:
55671         (PlatformCALayer::animationStarted):
55672         (resubmitAllAnimations):
55673         (PlatformCALayer::animationForKey):
55674         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
55675         (WebCore::LookupAltName):
55676         (WebCore::fontContainsCharacter):
55677         * platform/graphics/chromium/FontUtilsChromiumWin.cpp:
55678         (WebCore::getDerivedFontData):
55679         * platform/graphics/filters/CustomFilterGlobalContext.cpp:
55680         (WebCore::CustomFilterGlobalContext::~CustomFilterGlobalContext):
55681         (WebCore::CustomFilterGlobalContext::getValidatedProgram):
55682         (WebCore::CustomFilterGlobalContext::removeValidatedProgram):
55683         * platform/graphics/filters/CustomFilterProgram.cpp:
55684         (WebCore::CustomFilterProgram::notifyClients):
55685         * platform/graphics/harfbuzz/HarfBuzzSkia.cpp:
55686         (WebCore::getCachedHarfbuzzFace):
55687         (WebCore::releaseCachedHarfbuzzFace):
55688         * platform/graphics/harfbuzz/ng/HarfBuzzNGFace.cpp:
55689         (WebCore::HarfBuzzNGFace::HarfBuzzNGFace):
55690         (WebCore::HarfBuzzNGFace::~HarfBuzzNGFace):
55691         * platform/graphics/mac/SimpleFontDataCoreText.cpp:
55692         (WebCore::SimpleFontData::getCFStringAttributes):
55693         * platform/graphics/mac/SimpleFontDataMac.mm:
55694         (WebCore::SimpleFontData::canRenderCombiningCharacterSequence):
55695         * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
55696         (WebCore::Extensions3DOpenGLCommon::getTranslatedShaderSourceANGLE):
55697         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
55698         (WebCore::GraphicsContext3D::compileShader):
55699         (WebCore::GraphicsContext3D::mappedSymbolName):
55700         (WebCore::GraphicsContext3D::getShaderiv):
55701         (WebCore::GraphicsContext3D::getShaderInfoLog):
55702         (WebCore::GraphicsContext3D::getShaderSource):
55703         * platform/graphics/openvg/EGLDisplayOpenVG.cpp:
55704         (WebCore::EGLDisplayOpenVG::~EGLDisplayOpenVG):
55705         (WebCore::EGLDisplayOpenVG::destroySurface):
55706         (WebCore::EGLDisplayOpenVG::contextForSurface):
55707         * platform/graphics/texmap/TextureMapperGL.cpp:
55708         (WebCore::TextureMapperGLData::SharedGLData::currentSharedGLData):
55709         (WebCore::TextureMapperGLData::SharedGLData::~SharedGLData):
55710         * platform/graphics/texmap/TextureMapperShaderManager.cpp:
55711         (WebCore::TextureMapperShaderManager::getShaderProgram):
55712         (WebCore::TextureMapperShaderManager::getShaderForFilter):
55713         * platform/graphics/wince/FontPlatformData.cpp:
55714         (WebCore::FixedSizeFontData::create):
55715         * platform/gtk/DataObjectGtk.cpp:
55716         (WebCore::DataObjectGtk::forClipboard):
55717         * platform/gtk/GtkDragAndDropHelper.cpp:
55718         (WebCore::GtkDragAndDropHelper::handleGetDragData):
55719         (WebCore::GtkDragAndDropHelper::handleDragLeave):
55720         (WebCore::GtkDragAndDropHelper::handleDragMotion):
55721         (WebCore::GtkDragAndDropHelper::handleDragDataReceived):
55722         (WebCore::GtkDragAndDropHelper::handleDragDrop):
55723         * platform/gtk/RedirectedXCompositeWindow.cpp:
55724         (WebCore::filterXDamageEvent):
55725         * platform/gtk/RenderThemeGtk3.cpp:
55726         (WebCore::gtkStyleChangedCallback):
55727         (WebCore::getStyleContext):
55728         * platform/mac/ScrollbarThemeMac.mm:
55729         (+[WebScrollbarPrefsObserver appearancePrefsChanged:]):
55730         * platform/network/CredentialStorage.cpp:
55731         (WebCore::CredentialStorage::set):
55732         (WebCore::CredentialStorage::get):
55733         * platform/network/HTTPHeaderMap.cpp:
55734         (WebCore::HTTPHeaderMap::copyData):
55735         (WebCore::HTTPHeaderMap::get):
55736         * platform/network/MIMEHeader.cpp:
55737         (WebCore::MIMEHeader::parseHeader):
55738         * platform/network/ResourceHandle.cpp:
55739         (WebCore::ResourceHandle::create):
55740         * platform/network/ResourceRequestBase.cpp:
55741         (WebCore::ResourceRequestBase::addHTTPHeaderField):
55742         (WebCore::ResourceRequestBase::addHTTPHeaderFields):
55743         * platform/network/blackberry/ResourceRequestBlackBerry.cpp:
55744         (WebCore::ResourceRequest::targetTypeFromMimeType):
55745         (WebCore::ResourceRequest::initializePlatformRequest):
55746         * platform/network/cf/ResourceHandleCFNet.cpp:
55747         (WebCore::makeFinalRequest):
55748         * platform/network/cf/ResourceRequestCFNet.cpp:
55749         (WebCore::setHeaderFields):
55750         * platform/network/curl/ResourceHandleManager.cpp:
55751         (WebCore::ResourceHandleManager::initializeHandle):
55752         * platform/network/mac/ResourceRequestMac.mm:
55753         (WebCore::ResourceRequest::doUpdatePlatformRequest):
55754         * platform/network/qt/ResourceRequestQt.cpp:
55755         (WebCore::ResourceRequest::toNetworkRequest):
55756         * platform/network/soup/ResourceHandleSoup.cpp:
55757         (WebCore::sendRequestCallback):
55758         (WebCore::ResourceHandle::setClientCertificate):
55759         * platform/network/soup/ResourceRequestSoup.cpp:
55760         (WebCore::ResourceRequest::updateSoupMessage):
55761         (WebCore::ResourceRequest::toSoupMessage):
55762         * platform/network/soup/ResourceResponseSoup.cpp:
55763         (WebCore::ResourceResponse::toSoupMessage):
55764         * platform/network/win/ResourceHandleWin.cpp:
55765         (WebCore::ResourceHandle::start):
55766         * platform/qt/RunLoopQt.cpp:
55767         (WebCore::RunLoop::TimerBase::timerFired):
55768         * platform/text/LocaleToScriptMappingDefault.cpp:
55769         (WebCore::scriptNameToCode):
55770         (WebCore::localeToScriptCodeForFontSelection):
55771         * platform/text/TextEncodingRegistry.cpp:
55772         (WebCore::pruneBlacklistedCodecs):
55773         (WebCore::dumpTextEncodingNameMap):
55774         * platform/text/transcoder/FontTranscoder.cpp:
55775         (WebCore::FontTranscoder::converterType):
55776         * platform/text/win/TextCodecWin.cpp:
55777         (WebCore::LanguageManager::LanguageManager):
55778         (WebCore::getCodePage):
55779         (WebCore::TextCodecWin::registerExtendedEncodingNames):
55780         (WebCore::TextCodecWin::registerExtendedCodecs):
55781         (WebCore::TextCodecWin::enumerateSupportedEncodings):
55782         * platform/win/ClipboardUtilitiesWin.cpp:
55783         (WebCore::getDataMapItem):
55784         (WebCore::getClipboardData):
55785         (WebCore::setClipboardData):
55786         * platform/win/ClipboardWin.cpp:
55787         (WebCore::ClipboardWin::types):
55788         * platform/win/FileSystemWin.cpp:
55789         (WebCore::cachedStorageDirectory):
55790         * platform/win/RunLoopWin.cpp:
55791         (WebCore::RunLoop::TimerBase::timerFired):
55792         * platform/win/WCDataObject.cpp:
55793         (WebCore::WCDataObject::createInstance):
55794         * platform/wince/MIMETypeRegistryWinCE.cpp:
55795         (WebCore::MIMETypeRegistry::getPreferredExtensionForMIMEType):
55796         * platform/wx/ContextMenuWx.cpp:
55797         (WebCore::ContextMenu::appendItem):
55798         * plugins/PluginDatabase.cpp:
55799         (WebCore::PluginDatabase::refresh):
55800         (WebCore::PluginDatabase::MIMETypeForExtension):
55801         (WebCore::PluginDatabase::remove):
55802         * plugins/PluginMainThreadScheduler.cpp:
55803         (WebCore::PluginMainThreadScheduler::scheduleCall):
55804         (WebCore::PluginMainThreadScheduler::dispatchCalls):
55805         * plugins/PluginStream.cpp:
55806         (WebCore::PluginStream::startStream):
55807         * plugins/blackberry/PluginDataBlackBerry.cpp:
55808         (WebCore::PluginData::initPlugins):
55809         * plugins/wx/PluginDataWx.cpp:
55810         (WebCore::PluginData::initPlugins):
55811         * rendering/ExclusionShapeInsideInfo.cpp:
55812         (WebCore::ExclusionShapeInsideInfo::ensureExclusionShapeInsideInfoForRenderBlock):
55813         * rendering/FlowThreadController.cpp:
55814         (WebCore::FlowThreadController::unregisterNamedFlowContentNode):
55815         * rendering/InlineFlowBox.cpp:
55816         (WebCore::InlineFlowBox::requiresIdeographicBaseline):
55817         (WebCore::InlineFlowBox::addTextBoxVisualOverflow):
55818         * rendering/RenderBlock.cpp:
55819         (WebCore::RenderBlock::clearFloats):
55820         * rendering/RenderBlockLineLayout.cpp:
55821         (WebCore::setLogicalWidthForTextRun):
55822         * rendering/RenderBoxModelObject.cpp:
55823         (WebCore::ImageQualityController::highQualityRepaintTimerFired):
55824         (WebCore::ImageQualityController::shouldPaintAtLowQuality):
55825         * rendering/RenderCounter.cpp:
55826         (WebCore::RenderCounter::destroyCounterNodes):
55827         (WebCore::RenderCounter::destroyCounterNode):
55828         (WebCore::updateCounters):
55829         (WebCore::RenderCounter::rendererStyleChanged):
55830         * rendering/RenderFlowThread.cpp:
55831         (WebCore::RenderFlowThread::setRegionRangeForBox):
55832         (WebCore::RenderFlowThread::getRegionRangeForBox):
55833         * rendering/RenderLayer.cpp:
55834         (WebCore::RenderLayer::paint):
55835         (WebCore::performOverlapTests):
55836         * rendering/RenderLayerFilterInfo.cpp:
55837         (WebCore::RenderLayerFilterInfo::filterInfoForRenderLayer):
55838         (WebCore::RenderLayerFilterInfo::createFilterInfoForRenderLayerIfNeeded):
55839         * rendering/RenderNamedFlowThread.cpp:
55840         (WebCore::RenderNamedFlowThread::dependsOn):
55841         (WebCore::RenderNamedFlowThread::pushDependencies):
55842         * rendering/RenderRegion.cpp:
55843         (WebCore::RenderRegion::setRenderBoxRegionInfo):
55844         (WebCore::RenderRegion::setRegionObjectsRegionStyle):
55845         (WebCore::RenderRegion::restoreRegionObjectsOriginalStyle):
55846         (WebCore::RenderRegion::computeChildrenStyleInRegion):
55847         * rendering/RenderTableSection.cpp:
55848         (WebCore::RenderTableSection::cachedCollapsedBorder):
55849         * rendering/RenderThemeMac.mm:
55850         (WebCore::RenderThemeMac::systemColor):
55851         * rendering/RenderView.cpp:
55852         (WebCore::RenderView::selectionBounds):
55853         (WebCore::RenderView::setSelection):
55854         * rendering/RenderWidget.cpp:
55855         (WebCore::WidgetHierarchyUpdatesSuspensionScope::moveWidgets):
55856         * rendering/RootInlineBox.cpp:
55857         (WebCore::RootInlineBox::ascentAndDescentForBox):
55858         * rendering/VerticalPositionCache.h:
55859         (WebCore::VerticalPositionCache::get):
55860         * rendering/svg/RenderSVGInlineText.cpp:
55861         (WebCore::RenderSVGInlineText::characterStartsNewTextChunk):
55862         * rendering/svg/RenderSVGResourceFilter.cpp:
55863         (WebCore::RenderSVGResourceFilter::primitiveAttributeChanged):
55864         * rendering/svg/RenderSVGResourceGradient.cpp:
55865         (WebCore::RenderSVGResourceGradient::applyResource):
55866         * rendering/svg/RenderSVGResourcePattern.cpp:
55867         (WebCore::RenderSVGResourcePattern::applyResource):
55868         * rendering/svg/SVGResourcesCache.cpp:
55869         (WebCore::SVGResourcesCache::resourceDestroyed):
55870         * rendering/svg/SVGRootInlineBox.cpp:
55871         (WebCore::swapItemsInLayoutAttributes):
55872         * rendering/svg/SVGTextLayoutAttributes.cpp:
55873         (WebCore::SVGTextLayoutAttributes::dump):
55874         * rendering/svg/SVGTextLayoutAttributesBuilder.cpp:
55875         (WebCore::SVGTextLayoutAttributesBuilder::buildCharacterDataMap):
55876         (WebCore::SVGTextLayoutAttributesBuilder::fillCharacterDataMap):
55877         * rendering/svg/SVGTextLayoutEngine.cpp:
55878         (WebCore::SVGTextLayoutEngine::layoutTextOnLineOrPath):
55879         * rendering/svg/SVGTextMetricsBuilder.cpp:
55880         (WebCore::SVGTextMetricsBuilder::measureTextRenderer):
55881         * storage/StorageAreaSync.cpp:
55882         (WebCore::StorageAreaSync::syncTimerFired):
55883         (WebCore::StorageAreaSync::performImport):
55884         (WebCore::StorageAreaSync::sync):
55885         * storage/StorageMap.cpp:
55886         (WebCore::StorageMap::key):
55887         (WebCore::StorageMap::setItem):
55888         * storage/StorageNamespaceImpl.cpp:
55889         (WebCore::StorageNamespaceImpl::localStorageNamespace):
55890         (WebCore::StorageNamespaceImpl::copy):
55891         (WebCore::StorageNamespaceImpl::close):
55892         (WebCore::StorageNamespaceImpl::clearAllOriginsForDeletion):
55893         (WebCore::StorageNamespaceImpl::sync):
55894         * svg/SVGDocumentExtensions.cpp:
55895         (WebCore::SVGDocumentExtensions::removeAnimationElementFromTarget):
55896         (WebCore::SVGDocumentExtensions::removeAllAnimationElementsFromTarget):
55897         (WebCore::SVGDocumentExtensions::addPendingResource):
55898         (WebCore::SVGDocumentExtensions::isElementPendingResources):
55899         (WebCore::SVGDocumentExtensions::removeElementFromPendingResources):
55900         (WebCore::SVGDocumentExtensions::setOfElementsReferencingTarget):
55901         (WebCore::SVGDocumentExtensions::removeAllTargetReferencesForElement):
55902         (WebCore::SVGDocumentExtensions::removeAllElementReferencesForTarget):
55903         * svg/SVGElement.cpp:
55904         (WebCore::SVGElement::~SVGElement):
55905         * svg/animation/SMILTimeContainer.cpp:
55906         (WebCore::SMILTimeContainer::setElapsed):
55907         (WebCore::SMILTimeContainer::updateAnimations):
55908         * svg/graphics/SVGImageCache.cpp:
55909         (WebCore::SVGImageCache::~SVGImageCache):
55910         (WebCore::SVGImageCache::removeClientFromCache):
55911         (WebCore::SVGImageCache::requestedSizeAndScales):
55912         (WebCore::SVGImageCache::imageContentChanged):
55913         (WebCore::SVGImageCache::redraw):
55914         (WebCore::SVGImageCache::lookupOrCreateBitmapImageForRenderer):
55915         * svg/graphics/filters/SVGFilterBuilder.h:
55916         (WebCore::SVGFilterBuilder::effectReferences):
55917         (WebCore::SVGFilterBuilder::addBuiltinEffects):
55918         * svg/properties/SVGAnimatedProperty.h:
55919         (WebCore::SVGAnimatedProperty::~SVGAnimatedProperty):
55920         * svg/properties/SVGAttributeToPropertyMap.cpp:
55921         (WebCore::SVGAttributeToPropertyMap::addProperties):
55922         (WebCore::SVGAttributeToPropertyMap::synchronizeProperties):
55923         * workers/WorkerContext.cpp:
55924         (WebCore::WorkerContext::hasPendingActivity):
55925         * workers/WorkerEventQueue.cpp:
55926         (WebCore::WorkerEventQueue::close):
55927         * xml/XMLHttpRequest.cpp:
55928         (WebCore::XMLHttpRequest::setRequestHeaderInternal):
55929         (WebCore::XMLHttpRequest::getAllResponseHeaders):
55930         * xml/XPathFunctions.cpp:
55931         (WebCore::XPath::createFunction):
55932         * xml/XPathParser.cpp:
55933         (isAxisName):
55934         * xml/XSLTProcessorLibxslt.cpp:
55935         (WebCore::xsltParamArrayFromParameterMap):
55936         * xml/XSLTProcessorQt.cpp:
55937         (WebCore::XSLTProcessor::transformToString):
55938
55939 2012-10-07  Geoffrey Garen  <ggaren@apple.com>
55940
55941         REGRESSION (r130584): Crashes in JSC::MarkedAllocator::allocateSlowCase, failing fast/dom/gc-dom-tree-lifetime.html
55942         https://bugs.webkit.org/show_bug.cgi?id=98612
55943
55944         Reviewed by Darin Adler.
55945
55946         Since DOM modification can happen outside of JS, calls into JS due to
55947         DOM modification need to take the JS lock.
55948
55949         * bindings/js/JSNodeCustom.cpp:
55950         (WebCore::willCreatePossiblyOrphanedTreeByRemovalSlowCase): Take the JS
55951         lock before doing a JS allocation, since this may be a JS entrypoint.
55952
55953         * bindings/js/JSNodeCustom.h:
55954         (WebCore::willCreatePossiblyOrphanedTreeByRemoval): Split out a slow case
55955         to help the inliner.
55956
55957 2012-10-07  Nick Carter  <nick@chromium.org>
55958
55959         [chromium] Crash in WebCore::GraphicsLayerChromium::setContentsToImage
55960         https://bugs.webkit.org/show_bug.cgi?id=98456
55961
55962         Reviewed by James Robinson.
55963
55964         Handle null return of nativeImageForCurrentFrame.
55965
55966         Test: compositing/images/truncated-direct-png-image.html
55967
55968         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
55969         (WebCore::GraphicsLayerChromium::setContentsToImage):
55970
55971 2012-10-07  Benjamin Poulain  <benjamin@webkit.org>
55972
55973         WTFURL: implement URL port removal for HTMLAnchorElement
55974         https://bugs.webkit.org/show_bug.cgi?id=98604
55975
55976         Reviewed by Adam Barth.
55977
55978         * platform/KURLWTFURL.cpp:
55979         (WebCore::KURL::hasPort):
55980         (WebCore::KURL::removePort):
55981         (WebCore::KURL::isHierarchical):
55982         Implement those methods to pass the port removal test of HTMLAnchorElement.
55983
55984 2012-10-05  Dirk Schulze  <krit@webkit.org>
55985
55986         SVG radialGradient should support 'fr' for focal radius (just like Canvas)
55987         https://bugs.webkit.org/show_bug.cgi?id=97986
55988
55989         Reviewed by Daniel Bates.
55990
55991         Update SVGRadialGradient to the changed behavior in SVG2: http://www.w3.org/TR/SVG2/pservers.html#RadialGradients
55992         SVG2 adds the focal radius for radial gradients. Color stops will start from the edge of
55993         the focal radius.
55994         The new specification does not limit the focal point to be inside the radial gradients radius.
55995         This makes SVGRadialGradient consistent with the radial gradient on Canvas.
55996
55997         Test: svg/custom/radialGradient-focal-radius.svg
55998
55999         * rendering/svg/RenderSVGResourceRadialGradient.cpp:
56000             Remove checks for position of focal point. The focal point
56001             can be placed every where outside the radius of the gradient now.
56002         (WebCore::RenderSVGResourceRadialGradient::focalRadius):
56003             Add new method to get the focal radius from SVGRadialGradientElement.
56004         (WebCore::RenderSVGResourceRadialGradient::buildGradient):
56005         * rendering/svg/RenderSVGResourceRadialGradient.h:
56006         (RenderSVGResourceRadialGradient):
56007         * rendering/svg/SVGRenderTreeAsText.cpp:
56008         (WebCore::writeSVGResourceContainer):
56009             Modify DRT output to include the focal radius.
56010         * svg/RadialGradientAttributes.h:
56011         (WebCore::RadialGradientAttributes::RadialGradientAttributes):
56012         (WebCore::RadialGradientAttributes::fr):
56013         (WebCore::RadialGradientAttributes::setFr):
56014         (WebCore::RadialGradientAttributes::hasFr):
56015         (RadialGradientAttributes):
56016             New setters and getters for focal radius.
56017         * svg/SVGRadialGradientElement.cpp:
56018         (WebCore):
56019         (WebCore::SVGRadialGradientElement::SVGRadialGradientElement):
56020         (WebCore::SVGRadialGradientElement::isSupportedAttribute):
56021         (WebCore::SVGRadialGradientElement::parseAttribute):
56022         (WebCore::SVGRadialGradientElement::collectGradientAttributes):
56023         (WebCore::SVGRadialGradientElement::selfHasRelativeLengths):
56024             Ditto.
56025         * svg/SVGRadialGradientElement.h:
56026         (SVGRadialGradientElement):
56027         * svg/SVGRadialGradientElement.idl:
56028         * svg/svgattrs.in:
56029             Add 'fr' as new attribute to the SVG attribute list.
56030
56031 2012-10-07  Glenn Adams  <glenn@skynav.com>
56032
56033         Use start instead of -webkit-auto in default and quirks mode stylesheets.
56034         https://bugs.webkit.org/show_bug.cgi?id=98609
56035
56036         Reviewed by Antti Koivisto.
56037
56038         Change text-align use of legacy '-webkit-auto' to 'start' in the few places where it is used
56039         in default/quirks stylesheets.
56040         
56041         No new tests. No change of rendering/styling behavior. No performance impact.
56042
56043         * css/html.css:
56044         (input, textarea, keygen, select, button, isindex):
56045         (ruby > rt):
56046         * css/quirks.css:
56047         (table):
56048
56049 2012-10-06  Raul Hudea  <rhudea@adobe.com>
56050
56051         -webkit-clip-path should parse IRIs
56052         https://bugs.webkit.org/show_bug.cgi?id=96381
56053
56054         Reviewed by Andreas Kling.
56055
56056         Implemented the clipping via referencing a SVG clipPath. Currently it works only if the clipPath is defined
56057         before using it on an HTML element. The forward reference issue is tracked via https://bugs.webkit.org/show_bug.cgi?id=90405.
56058
56059         Tests: css3/masking/clip-path-reference-userSpaceOnUse.html
56060                css3/masking/clip-path-reference.html
56061                fast/masking/parsing-clip-path-iri.html
56062
56063         * css/CSSComputedStyleDeclaration.cpp:
56064         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): Add handling for SVG clipPath references.
56065         * css/CSSParser.cpp:
56066         (WebCore::CSSParser::parseValue): Add handling for SVG clipPath references.
56067         * css/StyleBuilder.cpp:
56068         (WebCore::ApplyPropertyClipPath::applyValue): Add handling for SVG references.
56069         * rendering/ClipPathOperation.h:
56070         (ReferenceClipPathOperation): Added a new class corresponding to SVG referenced clipPath.
56071         (WebCore::ReferenceClipPathOperation::create):
56072         (WebCore::ReferenceClipPathOperation::url):
56073         (WebCore::ReferenceClipPathOperation::fragment):
56074         (WebCore::ReferenceClipPathOperation::operator==):
56075         (WebCore::ReferenceClipPathOperation::ReferenceClipPathOperation):
56076         (WebCore):
56077         * rendering/RenderLayer.cpp:
56078         (WebCore::RenderLayer::paintLayerContents): Add handling for ReferenceClipPathOperation.
56079         * rendering/svg/RenderSVGResourceClipper.h:
56080         (RenderSVGResourceClipper): Made applyClippingToContext public as it needs to be called directly for HTML elements.
56081
56082 2012-10-06  Pratik Solanki  <psolanki@apple.com>
56083
56084         Reduce calls to CGImageSourceCopyPropertiesAtIndex from frameSizeAtIndex
56085         https://bugs.webkit.org/show_bug.cgi?id=98607
56086
56087         Reviewed by Dan Bernstein.
56088
56089         Refactor code so that we avoid a second call to CGImageSourceCopyPropertiesAtIndex under
56090         ImageSource::frameSizeAtIndex().
56091
56092         No new tests because no functional change.
56093
56094         * platform/graphics/cg/ImageSourceCG.cpp:
56095         (WebCore::orientationFromProperties):
56096         (WebCore):
56097         (WebCore::ImageSource::frameSizeAtIndex):
56098         (WebCore::ImageSource::orientationAtIndex):
56099
56100 2012-10-06  Mark Rowe  <mrowe@apple.com>
56101
56102         Build fix.
56103
56104         Stop calling -[NSSliderCell setTitle:]. It's never done anything on OS X.
56105
56106         * rendering/RenderThemeMac.mm:
56107         (WebCore::RenderThemeMac::sliderThumbHorizontal):
56108         (WebCore::RenderThemeMac::sliderThumbVertical):
56109
56110 2012-10-06  Andreas Kling  <kling@webkit.org>
56111
56112         Clipboard::types() should return an ordered collection.
56113         <http://webkit.org/b/98547>
56114
56115         Reviewed by Darin Adler.
56116
56117         Let Clipboard::types() return a ListHashSet<String> instead of a HashSet<String> to make sure
56118         it retains the order in which type strings are added.
56119
56120         No test, this fixes an issue that was uncovered when lowering the default table size of WTF
56121         hash tables, causing the HashSet<String> to rehash and reorder itself.
56122
56123         * bindings/js/JSClipboardCustom.cpp:
56124         (WebCore::JSClipboard::types):
56125         * bindings/v8/custom/V8ClipboardCustom.cpp:
56126         (WebCore::V8Clipboard::typesAccessorGetter):
56127         * dom/Clipboard.h:
56128         (Clipboard):
56129         * platform/blackberry/ClipboardBlackBerry.cpp:
56130         (WebCore::ClipboardBlackBerry::types):
56131         * platform/blackberry/ClipboardBlackBerry.h:
56132         (ClipboardBlackBerry):
56133         * platform/chromium/ChromiumDataObject.cpp:
56134         (WebCore::ChromiumDataObject::types):
56135         * platform/chromium/ChromiumDataObject.h:
56136         (ChromiumDataObject):
56137         * platform/chromium/ClipboardChromium.cpp:
56138         (WebCore::ClipboardChromium::types):
56139         * platform/chromium/ClipboardChromium.h:
56140         (ClipboardChromium):
56141         * platform/efl/ClipboardEfl.cpp:
56142         (WebCore::ClipboardEfl::types):
56143         * platform/efl/ClipboardEfl.h:
56144         (ClipboardEfl):
56145         * platform/gtk/ClipboardGtk.cpp:
56146         (WebCore::ClipboardGtk::types):
56147         * platform/gtk/ClipboardGtk.h:
56148         (ClipboardGtk):
56149         * platform/mac/ClipboardMac.h:
56150         (ClipboardMac):
56151         * platform/mac/ClipboardMac.mm:
56152         (WebCore::addHTMLClipboardTypesForCocoaType):
56153         (WebCore::ClipboardMac::types):
56154         * platform/qt/ClipboardQt.cpp:
56155         (WebCore::ClipboardQt::types):
56156         * platform/qt/ClipboardQt.h:
56157         (ClipboardQt):
56158         * platform/win/ClipboardWin.cpp:
56159         (WebCore::addMimeTypesForFormat):
56160         (WebCore::ClipboardWin::types):
56161         * platform/win/ClipboardWin.h:
56162         (ClipboardWin):
56163         * platform/wx/ClipboardWx.cpp:
56164         (WebCore::ClipboardWx::types):
56165         * platform/wx/ClipboardWx.h:
56166         (ClipboardWx):
56167
56168 2012-10-06  Geoffrey Garen  <ggaren@apple.com>
56169
56170         If Node X is reachable from JavaScript, all Nodes in the same tree should be kept alive
56171         https://bugs.webkit.org/show_bug.cgi?id=88834
56172
56173         Reviewed by Gavin Barraclough.
56174
56175         Follow-up patch to address some comments by Darin Adler.
56176
56177         * bindings/js/JSNodeCustom.h:
56178         (WebCore::willCreatePossiblyOrphanedTreeByRemoval): Save some space by
56179         collapsing comment lines. Use Node::hasChildNodes() for brevity.
56180
56181 2012-10-06  Benjamin Poulain  <benjamin@webkit.org>
56182
56183         Fix weird use of KURL's protocolIs
56184         https://bugs.webkit.org/show_bug.cgi?id=98584
56185
56186         Reviewed by Adam Barth.
56187
56188         Converting a KURL to string is a bad idea.
56189
56190         Invalid URLs can return a string that pass the tests, while an
56191         invalid URL will fail protocolIs().
56192
56193         * loader/cache/CachedResource.cpp:
56194         (WebCore::CachedResource::removeClient):
56195         * platform/graphics/MediaPlayer.cpp:
56196         (WebCore::MediaPlayer::load):
56197         * platform/network/DataURL.cpp:
56198         (WebCore::handleDataURL):
56199
56200 2012-10-06  Dan Bernstein  <mitz@apple.com>
56201
56202         WebCore part of <rdar://problem/12446507> [mac] WebKit clients cannot change the behavior of text-rendering: auto
56203         https://bugs.webkit.org/show_bug.cgi?id=98601
56204
56205         Reviewed by Darin Adler.
56206
56207         * WebCore.exp.in: Exported Font::setDefaultTypesettingFeatures().
56208         * platform/graphics/Font.cpp:
56209         (WebCore::Font::s_defaultTypesettingFeatures): Defined this static.
56210         (WebCore::Font::setDefaultTypesettingFeatures): Added this setter.
56211         (WebCore::Font::defaultTypesettingFeatures): Added this getter.
56212         * platform/graphics/Font.h:
56213         (WebCore::Font::typesettingFeatures): Changed to use the value of the new static member
56214         s_defaultTypesettingFeatures, rather than 0, if text-redering is set to auto.
56215
56216 2012-10-04  Geoffrey Garen  <ggaren@apple.com>
56217
56218         If Node X is reachable from JavaScript, all Nodes in the same tree should be kept alive
56219         https://bugs.webkit.org/show_bug.cgi?id=88834
56220
56221         Reviewed by Gavin Barraclough.
56222
56223         * bindings/js/JSNodeCustom.cpp:
56224         (WebCore::isObservable): Clarified this comment, since it seems to have
56225         misled some folks. 
56226
56227         * bindings/js/JSNodeCustom.h:
56228         (WebCore::willCreatePossiblyOrphanedTreeByRemoval): New helper function
56229         to ensure that a disconnected tree is visible to JavaScript.
56230
56231         * bindings/js/ScriptState.cpp:
56232         (WebCore::mainWorldScriptState): Need to check for null because a document's
56233         frame can be null.
56234
56235         * dom/ContainerNode.cpp:
56236         (WebCore::dispatchChildRemovalEvents): When we remove a subtree from the
56237         document, we sever the reference that JavaScript previously held by
56238         referencing its root. So, we give JavaScript an opportunity to establish
56239         a reference to the new root.
56240
56241 2012-10-06  Byungwoo Lee  <bw80.lee@samsung.com>
56242
56243         Fix build warning : -Wunused-parameter.
56244         https://bugs.webkit.org/show_bug.cgi?id=98583
56245
56246         Reviewed by Kentaro Hara.
56247
56248         Use ASSERT_UNUSED() macro to remove build warning.
56249
56250         * plugins/PluginStream.cpp:
56251         (WebCore::PluginStream::delayDeliveryTimerFired):
56252         (WebCore::PluginStream::didReceiveResponse):
56253         (WebCore::PluginStream::didReceiveData):
56254         (WebCore::PluginStream::didFail):
56255         (WebCore::PluginStream::didFinishLoading):
56256         * plugins/PluginView.cpp:
56257         (WebCore::PluginView::requestTimerFired):
56258         (WebCore::PluginView::invalidateTimerFired):
56259
56260 2012-10-05  Adam Barth  <abarth@webkit.org>
56261
56262         [V8] toV8(Node*, ...) does more work than needed (6% faster on dom-traverse)
56263         https://bugs.webkit.org/show_bug.cgi?id=98567
56264
56265         Reviewed by Kentaro Hara.
56266
56267         This patch introduces toV8Fast for Node*. This function works a
56268         differently from the existing toV8 function in two ways:
56269
56270         1) It uses the inline wrapper cache in Node to determine if we're
56271            executing in the main world. This is faster both in the case when
56272            isolated worlds exist because we don't need to retrieve any state
56273            for the current context.
56274
56275         2) It doesn't attempt to inline the hash table lookup used to find the
56276            wrapper in the isolated world. There isn't a big need to inline this
56277            code since performance in the isolated world case is dominated by
56278            the hash table lookup.
56279
56280         Because of these two changes, toV8Fast is small enough to inline into
56281         each attribute getter profitably. Over time, I would like to convert
56282         all the performance critical uses of toV8(Node*) to toV8Fast. At that
56283         point, we can delete toV8 and rename toV8Slow to toV8.
56284
56285         * bindings/scripts/CodeGeneratorV8.pm:
56286         (GenerateHeader):
56287         (GenerateNormalAttrGetter):
56288
56289 2012-10-05  Huang Dongsung  <luxtella@company100.net>
56290
56291         [mac] REGRESSION (r122215): Animated GIF outside the viewport doesn't play when scrolled into view.
56292         https://bugs.webkit.org/show_bug.cgi?id=94874
56293
56294         Reviewed by Simon Fraser.
56295
56296         Rollback previous patch because this patch caused two problems.
56297         1. GIF animation is occasionally paused when tiled scrolling is enabled.
56298         2. This change regressed Apple's Membuster benchmark by ~20% (80MB.)
56299
56300         * loader/cache/CachedImage.cpp:
56301         (WebCore::CachedImage::shouldPauseAnimation):
56302         * loader/cache/CachedImage.h:
56303         (CachedImage):
56304         * loader/cache/CachedResource.h:
56305         * loader/cache/MemoryCache.cpp:
56306         (WebCore::MemoryCache::pruneLiveResourcesToSize):
56307         * rendering/RenderObject.cpp:
56308         (WebCore::RenderObject::willRenderImage):
56309
56310 2012-10-05  Xianzhu Wang  <wangxianzhu@chromium.org>
56311
56312         OpenTypeVerticalData issue with DroidSansFallback.ttf on chromium-android and chromium-linux
56313         https://bugs.webkit.org/show_bug.cgi?id=97824
56314
56315         Reviewed by Tony Chang.
56316
56317         The issue occurred when a font that contains vert GSUB table but doesn't have
56318         a DFLT script and the first script doesn't have vert feature. Added logic to
56319         handle the case.
56320
56321         Test: fast/writing-mode/vertical-subst-font-vert-no-dflt.html
56322
56323         * platform/graphics/opentype/OpenTypeVerticalData.cpp:
56324         (FeatureList):
56325         (WebCore::OpenType::FeatureList::findFeature): Added to find the matching feature in FeatureList.
56326         (WebCore::OpenType::GSUBTable::feature): Added logic to handle the case of no DFLT script and no vert feature under the first script.
56327
56328 2012-10-05  Tony Chang  <tony@chromium.org>
56329
56330         Form controls should always be horizontal
56331         https://bugs.webkit.org/show_bug.cgi?id=98563
56332
56333         Reviewed by Ojan Vafai.
56334
56335         Fix a regression where we didn't force form controls to be horizontal.
56336
56337         Tests: fast/dom/HTMLMeterElement/meter-writing-mode.html
56338                fast/dom/HTMLProgressElement/progress-writing-mode.html
56339                fast/table/colspanMinWidth-vertical.html
56340
56341         * css/html.css:
56342         (input, textarea, keygen, select, button, isindex, meter, progress):
56343
56344 2012-10-05  Sheriff Bot  <webkit.review.bot@gmail.com>
56345
56346         Unreviewed, rolling out r130556 and r130564.
56347         http://trac.webkit.org/changeset/130556
56348         http://trac.webkit.org/changeset/130564
56349         https://bugs.webkit.org/show_bug.cgi?id=98572
56350
56351         The patch wasn't reviewed by a reviewer and it is breaking
56352         Chromium Windows (Requested by jchaffraix on #webkit).
56353
56354         * WebCore.exp.in:
56355         * WebCore.xcodeproj/project.pbxproj:
56356         * css/mediaControls.css:
56357         (video::-webkit-media-text-track-container):
56358         (video::-webkit-media-text-track-past-nodes):
56359         (video::-webkit-media-text-track-future-nodes):
56360         (video::-webkit-media-text-track-display):
56361         * html/HTMLMediaElement.cpp:
56362         (WebCore::HTMLMediaElement::HTMLMediaElement):
56363         (WebCore::HTMLMediaElement::attach):
56364         (WebCore::HTMLMediaElement::userIsInterestedInThisLanguage):
56365         (WebCore::HTMLMediaElement::userIsInterestedInThisTrackKind):
56366         (WebCore::HTMLMediaElement::setClosedCaptionsVisible):
56367         (WebCore::HTMLMediaElement::updateClosedCaptionsControls):
56368         * html/HTMLMediaElement.h:
56369         (HTMLMediaElement):
56370         * html/shadow/MediaControlElements.cpp:
56371         (WebCore):
56372         (WebCore::MediaControlTextTrackContainerElement::updateSizes):
56373         * html/shadow/MediaControlElements.h:
56374         (MediaControlTextTrackContainerElement):
56375         * html/shadow/MediaControlRootElement.cpp:
56376         (WebCore::MediaControlRootElement::updateTextTrackDisplay):
56377         * html/shadow/MediaControlRootElement.h:
56378         (MediaControlRootElement):
56379         * html/shadow/MediaControls.h:
56380         (MediaControls):
56381         * html/track/TextTrack.cpp:
56382         (WebCore::TextTrack::TextTrack):
56383         (WebCore::TextTrack::isValidKindKeyword):
56384         (WebCore::TextTrack::setKind):
56385         (WebCore::TextTrack::setMode):
56386         (WebCore::TextTrack::mode):
56387         * html/track/TextTrack.h:
56388         (WebCore::TextTrack::create):
56389         (WebCore::TextTrack::kind):
56390         (TextTrack):
56391         (WebCore::TextTrack::label):
56392         (WebCore::TextTrack::setLabel):
56393         (WebCore::TextTrack::language):
56394         (WebCore::TextTrack::setLanguage):
56395         * html/track/TextTrackCue.cpp:
56396         (WebCore::TextTrackCueBox::TextTrackCueBox):
56397         (WebCore::TextTrackCueBox::shadowPseudoId):
56398         (WebCore):
56399         (WebCore::TextTrackCue::updateDisplayTree):
56400         * html/track/TextTrackCue.h:
56401         (TextTrackCueBox):
56402         (TextTrackCue):
56403         * platform/mac/WebCoreSystemInterface.h:
56404         * platform/mac/WebCoreSystemInterface.mm:
56405         * rendering/CaptionPreferencesChangedListener.h: Removed.
56406         * rendering/RenderTheme.h:
56407         (WebCore):
56408         (RenderTheme):
56409         * rendering/RenderThemeMac.h:
56410         (RenderThemeMac):
56411         * rendering/RenderThemeMac.mm:
56412         (WebCore):
56413         (WebCore::RenderThemeMac::RenderThemeMac):
56414         (WebCore::RenderThemeMac::~RenderThemeMac):
56415
56416 2012-10-05  Tim Horton  <timothy_horton@apple.com>
56417
56418         [cg] GraphicsContextCG should ask CG whether the shadow offset workaround is required
56419         https://bugs.webkit.org/show_bug.cgi?id=98565
56420         <rdar://problem/12436468>
56421
56422         Reviewed by Simon Fraser.
56423
56424         On Mountain Lion and above, CG can tell us whether we need to work around incorrect
56425         shadow offsets. Prior to Mountain Lion, we should assume we need to apply the workaround.
56426
56427         No new tests, as this requires an obscure configuration to test.
56428
56429         * WebCore.exp.in:
56430         * platform/graphics/cg/GraphicsContextCG.cpp:
56431         (WebCore::applyShadowOffsetWorkaroundIfNeeded):
56432         (WebCore::GraphicsContext::setPlatformShadow):
56433         * platform/mac/WebCoreSystemInterface.h: Add wkCGContextDrawsWithCorrectShadowOffsets.
56434         * platform/mac/WebCoreSystemInterface.mm: Add wkCGContextDrawsWithCorrectShadowOffsets.
56435
56436 2012-10-05  Anders Carlsson  <andersca@apple.com>
56437
56438         Try to fix the build.
56439
56440         * rendering/RenderThemeMac.mm:
56441         (WebCore::RenderThemeMac::captionsWindowColor):
56442
56443 2012-10-05  Eric Seidel  <eric@webkit.org>
56444
56445         Remove needless virtual calls and inline RenderStyle::logical* to make table layout faster
56446         https://bugs.webkit.org/show_bug.cgi?id=98550
56447
56448         Reviewed by Andreas Kling.
56449
56450         This shaved another 5% (100ms) off of the runtime of resizecol.html microbenchmark:
56451         http://www.robohornet.org/tests/resizecol.html
56452
56453         * rendering/AutoTableLayout.cpp:
56454         (WebCore::AutoTableLayout::recalcColumn):
56455         * rendering/style/RenderStyle.cpp:
56456         * rendering/style/RenderStyle.h:
56457
56458 2012-10-04  Eric Carlson  <eric.carlson@apple.com>
56459
56460         Allow ports to override text track rendering style
56461         https://bugs.webkit.org/show_bug.cgi?id=97800
56462         <rdar://problem/12044964>
56463
56464         Reviewed by Silvia Pfeiffer.
56465
56466         * WebCore.exp.in: Export new WebkitSystemInterface functions.
56467         * WebCore.xcodeproj/project.pbxproj: Add CaptionPreferencesChangedListener.h.
56468
56469         * css/mediaControls.css: Rearrange the caption CSS so it is possible to style the cue window,
56470             background, and text independently.
56471
56472         * html/HTMLMediaElement.cpp:
56473         (WebCore::HTMLMediaElement::HTMLMediaElement): Initialize m_disableCaptions with theme->userPrefersCaptions().
56474         (WebCore::HTMLMediaElement::attach): Register for caption preferences change callbacks.
56475         (WebCore::HTMLMediaElement::detach): Unregister for caption preferences change callbacks.
56476         (WebCore::HTMLMediaElement::userPrefersCaptions): Return theme->userPrefersCaptions().
56477         (WebCore::HTMLMediaElement::userIsInterestedInThisTrackKind): Consider userPrefersCaptions().
56478         (WebCore::HTMLMediaElement::setClosedCaptionsVisible): Move the code that marks all tracks as
56479             un-configured to markCaptionAndSubtitleTracksAsUnconfigured so it can be reused.
56480         (WebCore::HTMLMediaElement::captionPreferencesChanged): New, force a reevaluation of all text tracks.
56481         (WebCore::HTMLMediaElement::markCaptionAndSubtitleTracksAsUnconfigured): New, code moved from 
56482             setClosedCaptionsVisible
56483         * html/HTMLMediaElement.h: Inherit from CaptionPreferencesChangedListener.
56484
56485         * html/shadow/MediaControlElements.cpp:
56486         (WebCore::MediaControlTextTrackContainerElement::userCaptionPreferencesChanged): New, if theme
56487             has a captions style sheet override, inject it into the current page group, otherwise
56488             remove injected sheet.
56489         (WebCore::MediaControlTextTrackContainerElement::updateSizes): Get rid of unnecessary member
56490             variable. Get caption font scale from theme instead of hard coding.
56491         * html/shadow/MediaControlElements.h:
56492
56493         * html/shadow/MediaControlRootElement.cpp:
56494         (WebCore::MediaControlRootElement::userCaptionPreferencesChanged): New.
56495         (WebCore::MediaControlRootElement::updateTextTrackDisplay):
56496         * html/shadow/MediaControlRootElement.h: Add userCaptionPreferencesChanged, minor cleanup.
56497
56498         * html/shadow/MediaControls.h:
56499         (WebCore::MediaControls::userCaptionPreferencesChanged): New.
56500
56501         * html/track/TextTrackCue.cpp:
56502         (WebCore::TextTrackCueBox::TextTrackCueBox): Set the shadow pseudo id.
56503         (WebCore::TextTrackCueBox::textTrackCueBoxShadowPseudoId): New, class method to return the 
56504             shadow pseudo id so it can be used elsewhere.
56505         (WebCore::TextTrackCueBox::shadowPseudoId): Call textTrackCueBoxShadowPseudoId.
56506         (WebCore::TextTrackCue::pastNodesShadowPseudoId): New, class method to return the 
56507             shadow pseudo id so it can be used elsewhere.
56508         (WebCore::TextTrackCue::futureNodesShadowPseudoId): Ditto.
56509         (WebCore::TextTrackCue::updateDisplayTree):
56510         * html/track/TextTrackCue.h:
56511
56512         * platform/mac/WebCoreSystemInterface.h: Updated.
56513         * platform/mac/WebCoreSystemInterface.mm: Ditto.
56514
56515         * rendering/CaptionPreferencesChangedListener.h: Added.
56516
56517         * rendering/RenderTheme.h:
56518         (WebCore::RenderTheme::userPrefersCaptions): New, default do-nothing implementation.
56519         (WebCore::RenderTheme::userHasCaptionPreferences): Ditto.
56520         (WebCore::RenderTheme::captionFontSizeScale): Ditto.
56521         (WebCore::RenderTheme::captionsStyleSheetOverride): Ditto.
56522         (WebCore::RenderTheme::registerForCaptionPreferencesChangedCallbacks): Ditto.
56523         (WebCore::RenderTheme::unregisterForCaptionPreferencesChangedCallbacks): Ditto.
56524
56525         * rendering/RenderThemeMac.h:
56526         * rendering/RenderThemeMac.mm:
56527         (WebCore::userCaptionPreferencesChangedNotificationCallback): New, receives preference changed notifications.
56528         (WebCore::RenderThemeMac::RenderThemeMac): Initialize m_listeningForCaptionPreferenceNotifications.
56529         (WebCore::RenderThemeMac::~RenderThemeMac): Unregister for notifications if necessary.
56530         (WebCore::RenderThemeMac::userHasCaptionPreferences): New, passthrough to WKSI function.
56531         (WebCore::RenderThemeMac::userPrefersCaptions): Ditto.
56532         (WebCore::RenderThemeMac::captionsWindowColor): Return Color with user's caption window color preference.
56533         (WebCore::RenderThemeMac::captionsBackgroundColor): Return Color with user's caption 
56534             background color preference.
56535         (WebCore::RenderThemeMac::captionsTextColor): Return Color with user's caption text color preference.
56536         (WebCore::RenderThemeMac::captionsEdgeColorForTextColor): Return Color for text edge effect.
56537         (WebCore::RenderThemeMac::cssPropertyWithTextEdgeColor): Return String with CSS to set a text-shadow
56538             or webkit-text-stroke property.
56539         (WebCore::RenderThemeMac::cssColorProperty): Return a String with css to set a property 
56540             with a color value.
56541         (WebCore::RenderThemeMac::captionsTextEdgeStyle): Return a String with css to style caption 
56542             text with the user's preferred text edge stye.
56543         (WebCore::RenderThemeMac::captionsDefaultFont): Return a String with css to style caption
56544             text with the user's preferred font.
56545         (WebCore::RenderThemeMac::captionsStyleSheetOverride): Return a String with css to style captions
56546             with the user's preferred style.
56547         (WebCore::RenderThemeMac::captionFontSizeScale): Return the user's preferred caption font scale.
56548         (WebCore::RenderThemeMac::captionPreferencesChanged): Notify listeners of caption preference change.
56549         (WebCore::RenderThemeMac::registerForCaptionPreferencesChangedCallbacks): Add a caption preferences 
56550             changes listener.
56551         (WebCore::RenderThemeMac::unregisterForCaptionPreferencesChangedCallbacks): Remove a caption preferences
56552             changes listener.
56553
56554 2012-10-05  Takashi Sakamoto  <tasak@google.com>
56555
56556         Inline continuations create :after generated content on style recalcs
56557         https://bugs.webkit.org/show_bug.cgi?id=93170
56558
56559         Reviewed by Abhishek Arya.
56560
56561         The bug is caused by RenderInline::styleDidChange's setContinuation(0).
56562         RenderObjectChildList uses continuation to know whether the given
56563         renderer should have AFTER render object or not.
56564         However, setContinuation(0) makes RenderObjectChildList to
56565         misunderstand that all continuations are last continuation.
56566         To avoid the misunderstanding, added a new flag to class
56567         RenderObejctChildList to enable/disable updating :after content (and
56568         also :before content).
56569
56570         Tests: fast/css-generated-content/after-with-inline-continuation.html
56571                fast/css-generated-content/dynamic-apply-after-for-inline.html
56572
56573         * rendering/RenderInline.cpp:
56574         (WebCore::RenderInline::styleDidChange):
56575         Disable upating :after content for continuations which are not
56576         the last one during setStyle just after setContinuation(0).
56577         The setStyle invokes RenderInline::styleDidChange and also invokes
56578         updateBeforeAfterContent via the styleDidChange. This means,
56579         the last continuation's updateBeforeAfterContent is also invoked
56580         after setContinuation(0). We have to update :after for the last
56581         continuation.
56582         * rendering/RenderObjectChildList.cpp:
56583         (WebCore):
56584         (WebCore::RenderObjectChildList::updateBeforeAfterContent):
56585         If s_updateBeforeAfterContent is false, quickly exit
56586         updateBeforeAfterContent.
56587         * rendering/RenderObjectChildList.h:
56588         (RenderObjectChildList):
56589         Added a new flag s_enableUpdateBeforeAfterContent to enable/disable
56590         updating :before or :after content.
56591
56592 2012-10-05  Simon Fraser  <simon.fraser@apple.com>
56593
56594         Don't assume that TileCache layers are opaque
56595         https://bugs.webkit.org/show_bug.cgi?id=98555
56596
56597         Reviewed by Dean Jackson.
56598
56599         TileCache previously set all its tile CALayers as opaque.
56600         However, we will need non-opaque tile caches when we use this
56601         tile cache for tiled layers, so add a member function to
56602         control tile opacity.
56603         
56604         RenderLayerBacking already calls m_graphicsLayer->setContentsOpaque()
56605         using the FrameView's notion of opaqueness, so this change will
56606         cause the main tile cache to be non-opaque if external forces have
56607         set the FrameView to be non-opaque.
56608         
56609         Also tweak the layer border widths on tiled layers.
56610
56611         * platform/graphics/ca/mac/TileCache.h:
56612         (TileCache):
56613         (WebCore::TileCache::tilesAreOpaque):
56614         * platform/graphics/ca/mac/TileCache.mm:
56615         (WebCore::TileCache::TileCache):
56616         (WebCore::TileCache::setTilesOpaque):
56617         (WebCore::TileCache::createTileLayer):
56618         * platform/graphics/ca/mac/WebTileCacheLayer.mm:
56619         (-[WebTileCacheLayer setOpaque:]):
56620         (-[WebTileCacheLayer isOpaque]):
56621         (-[WebTileCacheLayer setBorderWidth:]):
56622
56623 2012-10-05  Tony Chang  <tony@chromium.org>
56624
56625         Fix margin box ascent computation in flexbox
56626         https://bugs.webkit.org/show_bug.cgi?id=98540
56627
56628         Reviewed by Ojan Vafai.
56629
56630         The margin box ascent doesn't depend on the margin below the box.
56631
56632         Tests: css3/flexbox/flex-align.html: Fixed a test case and removed a FIXME.
56633                css3/flexbox/flex-align-vertical-writing-mode.html: Similar test case.
56634
56635         * rendering/RenderFlexibleBox.cpp:
56636         (WebCore::RenderFlexibleBox::marginBoxAscentForChild):
56637
56638 2012-10-05  Ojan Vafai  <ojan@chromium.org>
56639
56640         Deprecated flexboxes subtract scrollbar width/height twice
56641         https://bugs.webkit.org/show_bug.cgi?id=98552
56642
56643         Reviewed by Tony Chang.
56644
56645         This is a regression from http://trac.webkit.org/changeset/119507.
56646         The problem is that contentHeight subtracts the scrollbar and
56647         RenderDeprecatedFlexbox subtracts the scrollbar.
56648
56649         -Make it so that we only access override sizes if one has been set.
56650         I think this makes the calling code more clear.
56651         -If we don't have one set, grab the height/width - borderAndPadding.
56652         -Add a FIXME to change this all back to being borderbox sizes.
56653         There's something trick with making table padding/border work right for that
56654         though (noted in the original patch).
56655
56656         Test: fast/flexbox/flexing-overflow-scroll-item.html
56657
56658         * rendering/RenderBox.cpp:
56659         (WebCore::RenderBox::overrideLogicalContentWidth):
56660         (WebCore::RenderBox::overrideLogicalContentHeight):
56661         (WebCore::RenderBox::availableLogicalHeightUsing):
56662         * rendering/RenderBox.h:
56663         (RenderBox):
56664         * rendering/RenderDeprecatedFlexibleBox.cpp:
56665         (WebCore::contentWidthForChild):
56666         (WebCore):
56667         (WebCore::contentHeightForChild):
56668         (WebCore::RenderDeprecatedFlexibleBox::layoutHorizontalBox):
56669         (WebCore::RenderDeprecatedFlexibleBox::layoutVerticalBox):
56670         (WebCore::RenderDeprecatedFlexibleBox::allowedChildFlex):
56671
56672 2012-10-05  Eric Seidel  <eric@webkit.org>
56673
56674         Make tables which don't use col/row span much faster to layout
56675         https://bugs.webkit.org/show_bug.cgi?id=98221
56676
56677         Reviewed by Julien Chaffraix.
56678
56679         My sense is that most tables on webpages do not use colspan/rowspan
56680         so I stole another bit from RenderTableCell::m_column to avoid
56681         having to re-parse the colSpan/rowSpan attributes for every cell
56682         when doing table layout.
56683         This made these symbols disappear from biggrid.html/redraw.html (dglazkov's spreadsheets benchmarks)
56684         as well as moved our robohornet/resizecol.html number from an average of 3221ms to 2608ms (~20%!).
56685
56686         I removed m_hasHTMLTableCellElement (from http://trac.webkit.org/changeset/97691)
56687         since it was attempting to do the same sort of optimization.
56688
56689         * rendering/RenderTableCell.cpp:
56690         (WebCore::RenderTableCell::RenderTableCell):
56691         (WebCore::RenderTableCell::parseColSpanFromDOM):
56692         (WebCore::RenderTableCell::parseRowSpanFromDOM):
56693         (WebCore::RenderTableCell::layout):
56694         * rendering/RenderTableCell.h:
56695         (WebCore::RenderTableCell::colSpan):
56696         (WebCore::RenderTableCell::rowSpan):
56697         (RenderTableCell):
56698
56699 2012-10-05  Oli Lan  <olilan@chromium.org>
56700
56701         Allow EventHandler to handle longpress gestures, including longpress selection on Android.
56702         https://bugs.webkit.org/show_bug.cgi?id=98173
56703         
56704         Reviewed by Ryosuke Niwa.
56705
56706         Adds handling for GestureLongPress to EventHandler::handleGestureEvent, with a new
56707         handleGestureLongPress method. On Android, this method selects the closest word
56708         if the gesture event was over non-link text.
56709
56710         This is tested via a new chromium test WebViewTest.LongPressSelection.  
56711
56712         * page/EventHandler.cpp:
56713         (WebCore::EventHandler::selectClosestWordFromHitTestResult):
56714         (WebCore::EventHandler::selectClosestWordFromMouseEvent):
56715         (WebCore):
56716         (WebCore::EventHandler::handleGestureEvent):
56717         (WebCore::EventHandler::handleGestureLongPress):
56718         * page/EventHandler.h:
56719         (EventHandler):
56720
56721 2012-10-05  Tab Atkins  <jackalmage@gmail.com>
56722
56723         <marquee> element forces itself to be at least 1em high, regardless of 'height' declaration
56724         https://bugs.webkit.org/show_bug.cgi?id=18098
56725
56726         Reviewed by Eric Seidel.
56727
56728         This restriction originally existed to match IE, but IE changed some time ago to be normal instead.
56729         We're the last browser, afaict, to still enforce this de-facto restriction.
56730         This patch makes <marquee> instead act like a normal element.
56731
56732         Tests: fast/css/MarqueeLayoutTest.html (rewritten from the older, bad version)
56733
56734         * rendering/RenderMarquee.cpp:
56735         (WebCore::RenderMarquee::updateMarqueeStyle):
56736
56737 2012-10-05  Joe Mason  <jmason@rim.com>
56738
56739         [BlackBerry] Fix regression in proxy auth
56740         https://bugs.webkit.org/show_bug.cgi?id=98533
56741
56742         Reviewed by Yong Li.
56743
56744         The proxy auth dialog gets the proxy address from
56745         BlackBerry::Platform::Settings::proxyAddress, which returns
56746         "host:port", but we try to parse it with a KURL, which expects
56747         "scheme://host:port".  Since this is an http proxy, add http:// to the
56748         url to get it to parse.
56749
56750         PR 220567.
56751
56752         * platform/network/blackberry/NetworkJob.cpp:
56753         (WebCore::NetworkJob::sendRequestWithCredentials):
56754
56755 2012-10-05  Jer Noble  <jer.noble@apple.com>
56756
56757         No autorelease pool in place, causing buildup of autoreleased objects.
56758         https://bugs.webkit.org/show_bug.cgi?id=98522
56759         <rdar://problem/11647950>
56760
56761         Reviewed by Alexey Proskuryakov.
56762
56763         Wrap each timer callback in an AutodrainPool, ensuring an autorelease
56764         pool is present during calls from C/C++ into ObjC.
56765
56766         * platform/cf/RunLoopTimerCF.cpp:
56767         (WebCore::timerFired):
56768
56769 2012-10-05  Ryosuke Niwa  <rniwa@webkit.org>
56770
56771         Deleting across multiple paragraphs can change the style of surrounding text
56772         https://bugs.webkit.org/show_bug.cgi?id=97266
56773
56774         Reviewed by Levi Weintraub.
56775
56776         Preserve editing styles from CSS rules in wrappingStyleForSerialization as well as inline styles
56777         even when we're not annotating. We don't want to preserve all styles because it's against
56778         the user expectation to keep borders, etc... when merging paragraphs. We also don't want to copy
56779         styles from a mail blockquote because that's not a style the user has applied. See the comment
56780         in EditingStyle::wrappingStyleForSerialization.
56781
56782         Test: editing/deleting/merge-paragraph-with-style-from-rule.html
56783
56784         * editing/EditingStyle.cpp:
56785         (WebCore::EditingStyle::mergeInlineAndImplicitStyleOfElement):
56786         (WebCore::EditingStyle::wrappingStyleForSerialization):
56787
56788 2012-10-05  Dan Bernstein  <mitz@apple.com>
56789
56790         Reversing a GlyphBuffer needlessly queries its size multiple times
56791         https://bugs.webkit.org/show_bug.cgi?id=98530
56792
56793         Reviewed by Simon Fraser.
56794
56795         No new tests because there is no change in behavior.
56796
56797         * WebCore.xcodeproj/project.pbxproj:
56798         * platform/graphics/FontFastPath.cpp:
56799         (WebCore::Font::getGlyphsAndAdvancesForSimpleText): Replaced the condition
56800         (i < glyphBuffer.size() / 2) with the equivalent test (i < end).
56801         * platform/graphics/mac/FontComplexTextMac.cpp:
56802         (WebCore::Font::getGlyphsAndAdvancesForComplexText): Ditto.
56803
56804 2012-10-05  José Dapena Paz  <jdapena@igalia.com>
56805
56806         [GTK] Add support for creating EGL contexts
56807         https://bugs.webkit.org/show_bug.cgi?id=77921
56808
56809         Reviewed by Martin Robinson.
56810
56811         This patch adds support for EGL, using OpenGL and OpenGL ES 2. Both
56812         options are set up on compile time, with the configure options
56813         --enable-egl and --enable-gles2.
56814
56815         The implementation only adds support for EGL on top of X11, to
56816         isolate the changes to the minimum. More changes should come
56817         later to enable EGL for other targets (as Wayland).
56818
56819         No new tests required, as existing WebGL and AC tests should cover
56820         the cases.
56821
56822         * GNUmakefile.am:
56823         * GNUmakefile.list.am:
56824         * platform/graphics/GraphicsContext3D.h:
56825         (GraphicsContext3D):
56826         * platform/graphics/OpenGLESShims.h:
56827         * platform/graphics/cairo/GLContext.cpp:
56828         (WebCore):
56829         (WebCore::GLContext::sharedX11Display):
56830         (WebCore::GLContext::cleanupSharedX11Display):
56831         (WebCore::activeContextList):
56832         (WebCore::GLContext::addActiveContext):
56833         (WebCore::GLContext::removeActiveContext):
56834         (WebCore::GLContext::cleanupActiveContextsAtExit):
56835         (WebCore::GLContext::createContextForWindow):
56836         (WebCore::GLContext::createOffscreenContext):
56837         * platform/graphics/cairo/GLContext.h:
56838         (GLContext):
56839         * platform/graphics/cairo/GraphicsContext3DCairo.cpp:
56840         (WebCore::GraphicsContext3D::create):
56841         (WebCore::GraphicsContext3D::GraphicsContext3D):
56842         (WebCore::GraphicsContext3D::~GraphicsContext3D):
56843         (WebCore::GraphicsContext3D::isGLES2Compliant):
56844         * platform/graphics/cairo/GraphicsContext3DPrivate.cpp:
56845         (WebCore::GraphicsContext3DPrivate::paintToTextureMapper):
56846         * platform/graphics/clutter/GraphicsContext3DClutter.cpp:
56847         * platform/graphics/efl/GraphicsContext3DEfl.cpp:
56848         * platform/graphics/egl/GLContextEGL.cpp: Added.
56849         (WebCore):
56850         (WebCore::sharedEGLDisplay):
56851         (WebCore::getEGLConfig):
56852         (WebCore::GLContextEGL::createWindowContext):
56853         (WebCore::GLContextEGL::createPbufferContext):
56854         (WebCore::GLContextEGL::createPixmapContext):
56855         (WebCore::GLContextEGL::createContext):
56856         (WebCore::GLContextEGL::GLContextEGL):
56857         (WebCore::GLContextEGL::~GLContextEGL):
56858         (WebCore::GLContextEGL::canRenderToDefaultFramebuffer):
56859         (WebCore::GLContextEGL::defaultFrameBufferSize):
56860         (WebCore::GLContextEGL::makeContextCurrent):
56861         (WebCore::GLContextEGL::swapBuffers):
56862         (WebCore::GLContextEGL::waitNative):
56863         (WebCore::GLContextEGL::platformContext):
56864         * platform/graphics/egl/GLContextEGL.h: Added.
56865         (WebCore):
56866         (GLContextEGL):
56867         * platform/graphics/glx/GLContextGLX.cpp:
56868         (WebCore::GLContextGLX::createWindowContext):
56869         (WebCore::GLContextGLX::createPbufferContext):
56870         (WebCore::GLContextGLX::createPixmapContext):
56871         (WebCore::GLContextGLX::createContext):
56872         (WebCore::GLContextGLX::~GLContextGLX):
56873         (WebCore::GLContextGLX::defaultFrameBufferSize):
56874         (WebCore::GLContextGLX::makeContextCurrent):
56875         (WebCore::GLContextGLX::swapBuffers):
56876         (WebCore):
56877         (WebCore::GLContextGLX::waitNative):
56878         * platform/graphics/glx/GLContextGLX.h:
56879         (GLContextGLX):
56880         * platform/graphics/mac/GraphicsContext3DMac.mm:
56881         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
56882         (WebCore::GraphicsContext3D::releaseShaderCompiler):
56883         (WebCore):
56884         * platform/graphics/opengl/GraphicsContext3DOpenGLES.cpp:
56885         (WebCore::GraphicsContext3D::readPixels):
56886         (WebCore::GraphicsContext3D::reshapeFBOs):
56887         (WebCore::GraphicsContext3D::renderbufferStorage):
56888         * platform/graphics/qt/GraphicsContext3DQt.cpp:
56889         * platform/graphics/texmap/TextureMapper.h:
56890         * platform/gtk/RedirectedXCompositeWindow.cpp:
56891         (WebCore::RedirectedXCompositeWindow::RedirectedXCompositeWindow):
56892         (WebCore::RedirectedXCompositeWindow::~RedirectedXCompositeWindow):
56893         (WebCore::RedirectedXCompositeWindow::resize):
56894         * platform/gtk/RedirectedXCompositeWindow.h:
56895
56896 2012-10-04  Jon Lee  <jonlee@apple.com>
56897
56898         Add a setting to enable plugin snapshotting
56899         https://bugs.webkit.org/show_bug.cgi?id=98319
56900         <rdar://problem/12426480>
56901
56902         Reviewed by Brady Eidson.
56903
56904         Add a new bit for this preference.
56905
56906         * page/Settings.cpp:
56907         (WebCore::Settings::Settings): Preference is false by default.
56908         * page/Settings.h: Added m_plugInSnapshottingEnabled bit.
56909         (WebCore::Settings::setPlugInSnapshottingEnabled): Set the bit.
56910         (WebCore::Settings::plugInSnapshottingEnabled): Return the bit.
56911
56912 2012-10-05  Vsevolod Vlasov  <vsevik@chromium.org>
56913
56914         Unreviewed inspector front-end closure compilaiton fixes.
56915
56916         * inspector/InjectedScriptCanvasModuleSource.js:
56917         * inspector/InjectedScriptExterns.js:
56918         (InjectedScriptHost.prototype.getInternalProperties):
56919         * inspector/front-end/DockController.js:
56920         * inspector/front-end/externs.js:
56921         (InspectorFrontendHostAPI.prototype.requestSetDockSide):
56922
56923 2012-10-05  Tab Atkins  <jackalmage@gmail.com>
56924
56925         Replace uses of prefixed properties with unprefixed versions in the UA stylesheets
56926         https://bugs.webkit.org/show_bug.cgi?id=98453
56927
56928         Reviewed by Ojan Vafai.
56929
56930         Switched 'border-radius' and 'box-shadow' to their unprefixed version in the UA stylesheets.
56931
56932         No new tests, because the unprefixed properties have the same behavior as the prefixed.
56933
56934         * css/fullscreenQuickTime.css:
56935         (video:-webkit-full-screen::-webkit-media-controls-panel):
56936         * css/html.css:
56937         (keygen, select):
56938         (select[size][multiple]):
56939         (select[size="1"]):
56940         (::-webkit-validation-bubble-message):
56941         * css/themeBlackBerry.css:
56942         (input, textarea):
56943         * css/themeChromiumAndroid.css:
56944         (select[size][multiple]):
56945         * css/themeQtNoListboxes.css:
56946         (select[size][multiple]):
56947         * css/themeWin.css:
56948         (select[size="1"]):
56949         * css/view-source.css:
56950         (.webkit-html-message-bubble):
56951
56952 2012-10-05  Kevin Ellis  <kevers@chromium.org>
56953
56954         [chromium] Only inflate the height of rows in a popup menu when a touch device is detected.
56955         https://bugs.webkit.org/show_bug.cgi?id=98515
56956
56957         Reviewed by Adam Barth.
56958
56959         Enforces a minimum row height for popup menus when a touch device is
56960         detected.  In a previous patch (r127597), the sizing of popup was 
56961         consolidated for touch and non-touch.  Based on user feedback, reverting
56962         to the old behavior for non-touch and only adding padding for touch
56963         devices seems like a much safer strategy.  This patch is not a direct
56964         revert of r127567 since the padding previously used for touch is a bit
56965         excessive.
56966
56967         Covered by existing tests.
56968
56969         * platform/chromium/PopupListBox.cpp:
56970         (WebCore::PopupListBox::getRowHeight):
56971         * platform/chromium/PopupMenuChromium.cpp:
56972         (WebCore):
56973         * platform/chromium/PopupMenuChromium.h:
56974         (WebCore::PopupMenuChromium::optionRowHeightForTouch):
56975         (WebCore::PopupMenuChromium::setOptionRowHeightForTouch):
56976         (PopupMenuChromium):
56977
56978 2012-10-05  Alexander Pavlov  <apavlov@chromium.org>
56979
56980         Web Inspector: [Styles] Unable to edit properties in broken stylesheets
56981         https://bugs.webkit.org/show_bug.cgi?id=98246
56982
56983         Reviewed by Vsevolod Vlasov.
56984
56985         Pop source data for invalid rules off the stack whenever we have consecutive CSSParser::markRuleHeaderStart() invocations.
56986
56987         Test: inspector/styles/parse-stylesheet-errors.html
56988
56989         * css/CSSParser.cpp:
56990         (WebCore::CSSParser::popRuleData):
56991         (WebCore::CSSParser::markRuleHeaderStart):
56992         (WebCore::CSSParser::markRuleBodyStart):
56993         * css/CSSParser.h:
56994         (CSSParser):
56995
56996 2012-10-05  Gabor Rapcsanyi  <rgabor@webkit.org>
56997
56998         Add ARM-NEON support to VectorMath in WebAudio
56999         https://bugs.webkit.org/show_bug.cgi?id=98131
57000
57001         Reviewed by Zoltan Herczeg.
57002
57003         Speed up vector operations in WebAudio with NEON intrinsics.
57004
57005         * platform/audio/VectorMath.cpp:
57006         (WebCore::VectorMath::vsma):
57007         (WebCore::VectorMath::vsmul):
57008         (WebCore::VectorMath::vadd):
57009         (WebCore::VectorMath::vmul):
57010         (WebCore::VectorMath::zvmul):
57011         (WebCore::VectorMath::vsvesq):
57012         (WebCore::VectorMath::vmaxmgv):
57013
57014 2012-10-05  Simon Hausmann  <simon.hausmann@digia.com>
57015
57016         Unreviewed, rolling out r130495.
57017         http://trac.webkit.org/changeset/130495
57018         https://bugs.webkit.org/show_bug.cgi?id=98268
57019
57020         Made WK2 tests crash.
57021
57022         * Target.pri:
57023         * platform/qt/QStyleFacade.cpp: Removed.
57024         * platform/qt/QStyleFacade.h: Removed.
57025
57026 2012-10-05  Simon Hausmann  <simon.hausmann@digia.com>
57027
57028         [Qt] Make RenderThemeQStyle/ScrollbarThemeQStyle compile without QStyle/QtWidgets
57029         https://bugs.webkit.org/show_bug.cgi?id=98268
57030
57031         Reviewed by Tor Arne Vestbø.
57032
57033         Extracted QStyle/QWidget related code into a QWebStyle class that implements the QStyleFacade interface.
57034
57035         QStyleFacade is a pure interface that lives in WebCore/platform/qt
57036         (next to RenderThemeQStyle and ScrollbarThemeQStyle) and provides a
57037         minimal interface of what we need to draw with QStyle as well as basic
57038         hit testing and metric retrieval. It also provides a
57039         QStyleFacadeOption class that aggregates common meta-data for
57040         rendering primitives, such as direction, rectangle, state (sunken,
57041         enabled, etc.) or palette. It also provides some more slider/scrollbar
57042         specific fields in a slider sub-structure.
57043
57044         RenderThemeQStyle/ScrollbarThemeQStyle used to instantiate specific QStyleOption sub-classes and populate
57045         them with state information from render objects, before calling straight to QStyle. Most of the common code
57046         was encapsulated in StylePainterQStyle.
57047
57048         The new RenderThemeQStyle/ScrolllbarThemeQStyle uses common code in
57049         StylePainterQStyle to populate state into QStyleFacadeOption before
57050         calling into QStyleFacade.
57051
57052         The style facade is then implemented by QStyleFacadeImp, which extracts
57053         meta-data from QStyleFacadeOption arguments, populates style
57054         primitive specific QStyleOption objects and then calls on QStyle.
57055
57056         RenderThemeQStyle/ScrollbarThemeQStyle can only use interface methods
57057         from QStyleFacade. QStyleFacadeImp on the other hand will live in the
57058         separate QtWebKitWidgets library in the future and therefore cannot use
57059         any WebCore types.
57060
57061         * Target.pri:
57062         * platform/qt/QStyleFacade.cpp: Added.
57063         (WebCore):
57064         (WebCore::QStyleFacade::styleForPage):
57065         * platform/qt/QStyleFacade.h: Added.
57066         (WebCore):
57067         (QStyleFacade):
57068         (WebCore::QStyleFacade::~QStyleFacade):
57069         (WebCore::QStyleFacadeOption::QStyleFacadeOption):
57070         (QStyleFacadeOption):
57071         * platform/qt/RenderThemeQStyle.cpp: Renamed from Source/WebKit/qt/WebCoreSupport/RenderThemeQStyle.cpp.
57072         (WebCore):
57073         (WebCore::RenderThemeQStyle::getStylePainter):
57074         (WebCore::StylePainterQStyle::StylePainterQStyle):
57075         (WebCore::StylePainterQStyle::init):
57076         (WebCore::RenderThemeQStyle::create):
57077         (WebCore::RenderThemeQStyle::setStyleFactoryFunction):
57078         (WebCore::RenderThemeQStyle::styleFactory):
57079         (WebCore::RenderThemeQStyle::RenderThemeQStyle):
57080         (WebCore::RenderThemeQStyle::~RenderThemeQStyle):
57081         (WebCore::RenderThemeQStyle::setPaletteFromPageClientIfExists):
57082         (WebCore::RenderThemeQStyle::inflateButtonRect):
57083         (WebCore::RenderThemeQStyle::computeSizeBasedOnStyle):
57084         (WebCore::RenderThemeQStyle::adjustButtonStyle):
57085         (WebCore::RenderThemeQStyle::setButtonPadding):
57086         (WebCore::RenderThemeQStyle::paintButton):
57087         (WebCore::RenderThemeQStyle::paintTextField):
57088         (WebCore::RenderThemeQStyle::adjustTextAreaStyle):
57089         (WebCore::RenderThemeQStyle::paintTextArea):
57090         (WebCore::RenderThemeQStyle::setPopupPadding):
57091         (WebCore::RenderThemeQStyle::colorPalette):
57092         (WebCore::RenderThemeQStyle::paintMenuList):
57093         (WebCore::RenderThemeQStyle::adjustMenuListButtonStyle):
57094         (WebCore::RenderThemeQStyle::paintMenuListButton):
57095         (WebCore::RenderThemeQStyle::animationDurationForProgressBar):
57096         (WebCore::RenderThemeQStyle::paintProgressBar):
57097         (WebCore::RenderThemeQStyle::paintSliderTrack):
57098         (WebCore::RenderThemeQStyle::adjustSliderTrackStyle):
57099         (WebCore::RenderThemeQStyle::paintSliderThumb):
57100         (WebCore::RenderThemeQStyle::adjustSliderThumbStyle):
57101         (WebCore::RenderThemeQStyle::paintSearchField):
57102         (WebCore::RenderThemeQStyle::adjustSearchFieldDecorationStyle):
57103         (WebCore::RenderThemeQStyle::paintSearchFieldDecoration):
57104         (WebCore::RenderThemeQStyle::adjustSearchFieldResultsDecorationStyle):
57105         (WebCore::RenderThemeQStyle::paintSearchFieldResultsDecoration):
57106         (WebCore::RenderThemeQStyle::paintInnerSpinButton):
57107         (WebCore::RenderThemeQStyle::initializeCommonQStyleOptions):
57108         (WebCore::RenderThemeQStyle::adjustSliderThumbSize):
57109         * platform/qt/RenderThemeQStyle.h: Renamed from Source/WebKit/qt/WebCoreSupport/RenderThemeQStyle.h.
57110         (WebCore):
57111         (RenderThemeQStyle):
57112         (WebCore::RenderThemeQStyle::qStyle):
57113         (StylePainterQStyle):
57114         (WebCore::StylePainterQStyle::isValid):
57115         (WebCore::StylePainterQStyle::paintButton):
57116         (WebCore::StylePainterQStyle::paintTextField):
57117         (WebCore::StylePainterQStyle::paintComboBox):
57118         (WebCore::StylePainterQStyle::paintComboBoxArrow):
57119         (WebCore::StylePainterQStyle::paintSliderTrack):
57120         (WebCore::StylePainterQStyle::paintSliderThumb):
57121         (WebCore::StylePainterQStyle::paintInnerSpinButton):
57122         (WebCore::StylePainterQStyle::paintProgressBar):
57123         (WebCore::StylePainterQStyle::paintScrollCorner):
57124         (WebCore::StylePainterQStyle::paintScrollBar):
57125         * platform/qt/ScrollbarThemeQStyle.cpp: Renamed from Source/WebKit/qt/WebCoreSupport/ScrollbarThemeQStyle.cpp.
57126         (WebCore):
57127         (WebCore::ScrollbarThemeQStyle::ScrollbarThemeQStyle):
57128         (WebCore::ScrollbarThemeQStyle::~ScrollbarThemeQStyle):
57129         (WebCore::scPart):
57130         (WebCore::scrollbarPart):
57131         (WebCore::initSliderStyleOption):
57132         (WebCore::ScrollbarThemeQStyle::paint):
57133         (WebCore::ScrollbarThemeQStyle::hitTest):
57134         (WebCore::ScrollbarThemeQStyle::shouldCenterOnThumb):
57135         (WebCore::ScrollbarThemeQStyle::invalidatePart):
57136         (WebCore::ScrollbarThemeQStyle::scrollbarThickness):
57137         (WebCore::ScrollbarThemeQStyle::thumbPosition):
57138         (WebCore::ScrollbarThemeQStyle::thumbLength):
57139         (WebCore::ScrollbarThemeQStyle::trackPosition):
57140         (WebCore::ScrollbarThemeQStyle::trackLength):
57141         (WebCore::ScrollbarThemeQStyle::paintScrollCorner):
57142         * platform/qt/ScrollbarThemeQStyle.h: Renamed from Source/WebKit/qt/WebCoreSupport/ScrollbarThemeQStyle.h.
57143         (WebCore):
57144         (ScrollbarThemeQStyle):
57145         (WebCore::ScrollbarThemeQStyle::qStyle):
57146
57147 2012-10-05  Andrei Bucur  <abucur@adobe.com>
57148
57149         Incomplete repaint of boxes with inset box-shadow and padding when resized
57150         https://bugs.webkit.org/show_bug.cgi?id=59863
57151
57152         Reviewed by Simon Fraser.
57153
57154         The patch extends the repaint rectangle to include the inset shadow extent for renderers that resize and need to be repainted. The rectangle computations are also better fragmented and easier to read.
57155
57156         New Test: fast/repaint/box-shadow-inset-repaint.html
57157
57158         * rendering/RenderObject.cpp:
57159         (WebCore::RenderObject::repaintAfterLayoutIfNeeded):
57160         * rendering/style/RenderStyle.cpp:
57161         (WebCore::RenderStyle::getShadowInsetExtent):
57162         (WebCore):
57163         * rendering/style/RenderStyle.h:
57164
57165 2012-10-04  Kent Tamura  <tkent@chromium.org>
57166
57167         Fix sub-field width to the maximum width of a placeholder and the maximum value
57168         https://bugs.webkit.org/show_bug.cgi?id=98481
57169
57170         Reviewed by Hajime Morita.
57171
57172         We can't assume a placeholder text is shorter than the width of
57173         digits. The placeholder string for the year field of
57174         input[type=week] is "----", but input[type=date] will have a
57175         localized string for it.
57176
57177         We should set the 'width' CSS property to the maximum of the
57178         placeholder width and the maximum value width in order to prevent
57179         the field width from growing/narrowing.
57180
57181         Before this patch, we secured four digits space for a year field,
57182         and allowed the field to grow its width when a larger year is
57183         set. After this patch, we don't allow it to grow because the
57184         'width' property is set to the maximum width.
57185
57186         Update week-multiple-fields-appearance-basic.html, and the
57187         following tests are affected.
57188         - fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-classes.html
57189         - fast/forms/week-multiple-fields/week-multiple-fields-appearance-pseudo-elements.html
57190         - fast/forms/week-multiple-fields/week-multiple-fields-appearance-style.html
57191
57192         * html/shadow/DateTimeNumericFieldElement.cpp:
57193         (WebCore::DateTimeNumericFieldElement::DateTimeNumericFieldElement):
57194         Enable customStyleForRenderer.
57195         (WebCore::DateTimeNumericFieldElement::customStyleForRenderer):
57196         Added. The code is similar to DateTimeSymbolicFieldElement::customStyleForRenderer().
57197         (WebCore::DateTimeNumericFieldElement::formatValue):
57198         Made a function with the code in value(). This is used in
57199         customStyleForRenderer() and value().
57200         (WebCore::DateTimeNumericFieldElement::value): Use formatValue().
57201         * html/shadow/DateTimeNumericFieldElement.h:
57202         (DateTimeNumericFieldElement): Declare new functions.
57203
57204 2012-10-05  Kent Tamura  <tkent@chromium.org>
57205
57206         Improve spelling and performance of Localizer.cpp
57207         https://bugs.webkit.org/show_bug.cgi?id=98485
57208
57209         Reviewed by Kentaro Hara.
57210
57211         Some improvements pointed in webkit.org/b/98229#c5.
57212
57213         No new tests because of no behavior change.
57214
57215         * platform/text/Localizer.h:
57216         (Localizer):
57217          - Rename dateTimeFormatWithSecond to dateTimeFormatWithSeconds
57218          - Rename dateTimeFormatWithoutSecond to dateTimeFormatWithoutSeconds
57219          - Add data members: m_dateTimeFormatWithSeconds and m_dateTimeFormatWithoutSeconds.
57220         * platform/text/Localizer.cpp:
57221         (WebCore::Localizer::timeFormat): Check isNull instead of isEmpty
57222         (WebCore::Localizer::shortTimeFormat): Ditto.
57223         (WebCore::Localizer::dateTimeFormatWithSeconds):
57224         - Renamed.
57225         - Cache the concatenation result to a data member.
57226         (WebCore::Localizer::dateTimeFormatWithoutSeconds): Ditto.
57227
57228         * html/DateTimeInputType.cpp:
57229         (WebCore::DateTimeInputType::setupLayoutParameters): Follow the renaming.
57230         * html/DateTimeLocalInputType.cpp:
57231         (WebCore::DateTimeLocalInputType::setupLayoutParameters): Ditto.
57232
57233 2012-10-04  Kenichi Ishibashi  <bashi@chromium.org>
57234
57235         [WebSocket] ExtensionParser should have its own file
57236         https://bugs.webkit.org/show_bug.cgi?id=98475
57237
57238         Reviewed by Yuta Kitamura.
57239
57240         Factor out ExtensionParser from WebSocketExtensionDispatcher and rename it as WebSocketExtensionParser.
57241         WebSocketExtensionParser has its own file.
57242
57243         No changes in behavior. Added a test case for parsing Sec-WebSocket-Extensions field as a chromium unit test.
57244
57245         * CMakeLists.txt: Added WebSocketExtensionParser.
57246         * GNUmakefile.list.am: Ditto.
57247         * Modules/websockets/WebSocketExtensionDispatcher.cpp:
57248         (WebCore::WebSocketExtensionDispatcher::processHeaderValue):
57249         Use WebSocketExtensionParser::parseExtension() to parser extension header value.
57250         * Modules/websockets/WebSocketExtensionParser.cpp: Added.
57251         (WebCore):
57252         (WebCore::WebSocketExtensionParser::finished): Moved from ExtensionParser.
57253         (WebCore::WebSocketExtensionParser::parsedSuccessfully): Ditto.
57254         (WebCore::isSeparator): Ditto.
57255         (WebCore::WebSocketExtensionParser::skipSpaces): Ditto.
57256         (WebCore::WebSocketExtensionParser::consumeToken): Ditto.
57257         (WebCore::WebSocketExtensionParser::consumeQuotedString): Ditto.
57258         (WebCore::WebSocketExtensionParser::consumeQuotedStringOrToken): Ditto.
57259         (WebCore::WebSocketExtensionParser::consumeCharacter): Ditto.
57260         (WebCore::WebSocketExtensionParser::parseExtension): Moved from WebSocketExtensionDispatcher.
57261         * Modules/websockets/WebSocketExtensionParser.h: Added.
57262         (WebCore):
57263         (WebSocketExtensionParser):
57264         (WebCore::WebSocketExtensionParser::WebSocketExtensionParser):
57265         (WebCore::WebSocketExtensionParser::currentToken):
57266         * Target.pri: Added WebSocketExtensionParser.
57267         * WebCore.gypi: Ditto.
57268         * WebCore.vcproj/WebCore.vcproj: Ditto.
57269         * WebCore.xcodeproj/project.pbxproj: Ditto.
57270
57271 2012-10-04  Kunihiko Sakamoto  <ksakamoto@chromium.org>
57272
57273         <input> size attribute should throw INDEX_SIZE_ERR when set to 0
57274         https://bugs.webkit.org/show_bug.cgi?id=61675
57275
57276         Reviewed by Kent Tamura.
57277
57278         According to the spec, the size IDL attribute of input elements is limited
57279         to only non-negative numbers greater than zero. It should throw INDEX_SIZE_ERR
57280         exception when set to 0. New behavior matches both Firefox and IE.
57281         Spec: http://www.w3.org/TR/html5/common-input-element-attributes.html#the-size-attribute
57282
57283         Test: fast/dom/HTMLInputElement/input-size-attribute.html
57284
57285         * html/HTMLInputElement.cpp:
57286         (WebCore::HTMLInputElement::setSize):
57287         * html/HTMLInputElement.h:
57288         (HTMLInputElement):
57289         * html/HTMLInputElement.idl:
57290
57291 2012-10-04  Kent Tamura  <tkent@chromium.org>
57292
57293         Fix font for date/time input types.
57294         https://bugs.webkit.org/show_bug.cgi?id=98478
57295
57296         Reviewed by Kentaro Hara.
57297
57298         input[type=date] should use monospace font if
57299         ENABLE_INPUT_MULTIPLE_FIELDS_UI && ENABLE_INPUT_TYPE_DATE.
57300
57301         For other date/time types, they should use monospace font only
57302         if their types are enabled. input[type="foo"] matches input
57303         element with type="foo" even if the foo type is not supported.
57304
57305         The input[type=date] change is covered by
57306         fast/forms/date/calendar-picker-appearance.html,
57307         platform/chromium/fast/forms/date/date-suggestion-picker-appearance*.html
57308
57309         * css/html.css:
57310         (input[type="date"]):
57311         (input[type="datetime"]):
57312         (input[type="datetime-local"]):
57313         (input[type="month"]):
57314         (input[type="time"]):
57315
57316 2012-10-04  Hajime Morrita  <morrita@google.com>
57317
57318         [Refactoring] Some classes in StyleResolver.cpp/h could have its own file.
57319         https://bugs.webkit.org/show_bug.cgi?id=98469
57320
57321         Reviewed by Dimitri Glazkov.
57322
57323         This change extracts RuleData, RuleSet, RuleFeature and Featurs class
57324         to its own file: RuleSet.h/cpp and RuleFeature.h/cpp
57325
57326         RuleFeature class is moved fro StyleResolver inner class to plain WebCore class.
57327         Feaures class is renamed to RuleFeatureSet to avoid possible name conflict.
57328
57329         No new tests. Just splitting file and doing simple rename.
57330
57331         * CMakeLists.txt:
57332         * GNUmakefile.list.am:
57333         * Target.pri:
57334         * WebCore.gypi:
57335         * WebCore.xcodeproj/project.pbxproj:
57336         * css/CSSAllInOne.cpp:
57337         * css/RuleFeature.cpp: Added.
57338         (WebCore):
57339         (WebCore::RuleFeatureSet::add):
57340         (WebCore::RuleFeatureSet::clear):
57341         (WebCore::RuleFeatureSet::reportMemoryUsage):
57342         * css/RuleFeature.h: Added.
57343         (WebCore):
57344         (RuleFeature):
57345         (WebCore::RuleFeature::RuleFeature):
57346         (RuleFeatureSet):
57347         (WebCore::RuleFeatureSet::RuleFeatureSet):
57348         * css/RuleSet.cpp: Added.
57349         (WebCore):
57350         (WebCore::isSelectorMatchingHTMLBasedOnRuleHash):
57351         (WebCore::selectorListContainsUncommonAttributeSelector):
57352         (WebCore::isCommonAttributeSelectorAttribute):
57353         (WebCore::containsUncommonAttributeSelector):
57354         (WebCore::RuleData::RuleData):
57355         (WebCore::RuleData::reportMemoryUsage):
57356         (WebCore::reportAtomRuleMap):
57357         (WebCore::RuleSet::reportMemoryUsage):
57358         (WebCore::RuleSet::RuleSetSelectorPair::reportMemoryUsage):
57359         (WebCore::collectFeaturesFromSelector):
57360         (WebCore::collectFeaturesFromRuleData):
57361         (WebCore::RuleSet::addToRuleSet):
57362         (WebCore::RuleSet::addRule):
57363         (WebCore::RuleSet::addPageRule):
57364         (WebCore::RuleSet::addRegionRule):
57365         (WebCore::RuleSet::addRulesFromSheet):
57366         (WebCore::RuleSet::addStyleRule):
57367         (WebCore::shrinkMapVectorsToFit):
57368         (WebCore::RuleSet::shrinkToFit):
57369         * css/RuleSet.h: Added.
57370         (WebCore):
57371         (RuleData):
57372         (WebCore::RuleData::position):
57373         (WebCore::RuleData::rule):
57374         (WebCore::RuleData::selector):
57375         (WebCore::RuleData::selectorIndex):
57376         (WebCore::RuleData::hasFastCheckableSelector):
57377         (WebCore::RuleData::hasMultipartSelector):
57378         (WebCore::RuleData::hasRightmostSelectorMatchingHTMLBasedOnRuleHash):
57379         (WebCore::RuleData::containsUncommonAttributeSelector):
57380         (WebCore::RuleData::specificity):
57381         (WebCore::RuleData::linkMatchType):
57382         (WebCore::RuleData::hasDocumentSecurityOrigin):
57383         (WebCore::RuleData::isInRegionRule):
57384         (WebCore::RuleData::descendantSelectorIdentifierHashes):
57385         (SameSizeAsRuleData):
57386         (RuleSet):
57387         (WebCore::RuleSet::create):
57388         (WebCore::RuleSet::disableAutoShrinkToFit):
57389         (WebCore::RuleSet::features):
57390         (WebCore::RuleSet::idRules):
57391         (WebCore::RuleSet::classRules):
57392         (WebCore::RuleSet::tagRules):
57393         (WebCore::RuleSet::shadowPseudoElementRules):
57394         (WebCore::RuleSet::linkPseudoClassRules):
57395         (WebCore::RuleSet::focusPseudoClassRules):
57396         (WebCore::RuleSet::universalRules):
57397         (WebCore::RuleSet::pageRules):
57398         (WebCore::RuleSet::RuleSetSelectorPair::RuleSetSelectorPair):
57399         (RuleSetSelectorPair):
57400         (WebCore::RuleSet::RuleSet):
57401         * css/StyleResolver.cpp:
57402         (WebCore):
57403         (WebCore::makeRuleSet):
57404         (WebCore::StyleResolver::collectMatchingRulesForList):
57405         * css/StyleResolver.h:
57406         (StyleResolver):
57407
57408 2012-10-04  Adam Barth  <abarth@webkit.org>
57409
57410         FeatureObserver should distinguish between legacy HTML and text notifications
57411         https://bugs.webkit.org/show_bug.cgi?id=98441
57412
57413         Reviewed by Tony Chang.
57414
57415         We might be able to drop support for legacy HTML notifications before
57416         we can drop support for legacy text notifications. We should measure
57417         and find out.
57418
57419         * Modules/notifications/NotificationCenter.idl:
57420         * page/FeatureObserver.h:
57421
57422 2012-10-04  Pravin D  <pravind.2k4@gmail.com>
57423
57424         Removing the unused member variable m_wasMalformed from HTMLFormElement class and its related code frgment.
57425         https://bugs.webkit.org/show_bug.cgi?id=98444
57426
57427         Reviewed by Eric Seidel.
57428
57429         The member variable m_wasMalformed of HTMLFormElement class was used to determine if the <form> tag was malformed or not.
57430         This information was used elsewhere to decide if bottom margins have to be included for such a <form>.
57431         However currently this member variable is not being set by any code following code refactoring in HTML parser class.
57432
57433         Code cleanup patch. No new tests required.
57434
57435         * html/HTMLFormElement.cpp:
57436         (WebCore::HTMLFormElement::HTMLFormElement):
57437           Removed m_wasMalformed initialization.
57438
57439         * html/HTMLFormElement.h:
57440         (HTMLFormElement):
57441          Removed m_wasMalformed variable.
57442          Removed m_wasMalformed variable's setter and getter functions.
57443
57444         * rendering/RenderBlock.cpp:
57445         (WebCore::RenderBlock::layoutBlock):
57446          Removed code fragment using/dependent on m_wasMalformed.
57447
57448 2012-10-04  Rik Cabanier  <cabanier@adobe.com>
57449
57450         Turn Compositing on by default in WebKit build
57451         https://bugs.webkit.org/show_bug.cgi?id=98315
57452
57453         Reviewed by Simon Fraser.
57454
57455         enable -webkit-blend-mode on trunk.
57456
57457         No new tests. Existing blending test were updated.
57458
57459         * Configurations/FeatureDefines.xcconfig:
57460         * css/CSSPropertyNames.in:
57461         * css/CSSValueKeywords.in:
57462
57463 2012-10-04  Hayato Ito  <hayato@chromium.org>
57464
57465         [Refactoring] Introduce a traversal strategy in SelectorChecker
57466         https://bugs.webkit.org/show_bug.cgi?id=97298
57467
57468         Reviewed by Antti Koivisto.
57469
57470         We extract DOM traversal code from SelectorChecker so that we can use another traversal strategy.
57471         Another traversal strategy will be introduced in Bug 96990.
57472
57473         Since this code path is very hot, we were very careful not to regress performance.
57474         We will use template specialization to change the traversal implementation.
57475
57476         We confirmed that this patch does not regress SelectorCheckerPerformance. I have checked the performance of
57477         the added test in my Linux Box using run-perf-tests.
57478
57479         The performance of the added test before using this patch was:
57480
57481           RESULT CSS: PseudoClassSelectors= 3399.68308031 runs/s
57482           median= 3404.48685564 runs/s, stdev= 37.3480114449 runs/s, min= 3272.64871114 runs/s, max= 3438.72385184 runs/s
57483
57484         When we used this patch, the performance was:
57485
57486           RESULT CSS: PseudoClassSelectors= 3367.74473886 runs/s
57487           median= 3367.12072755 runs/s, stdev= 14.1464547639 runs/s, min= 3348.55881171 runs/s, max= 3395.98212857 runs/s
57488
57489         Test: PerformanceTests/CSS/PseudoClass-Selectors.html
57490
57491         * css/SelectorChecker.cpp:
57492         (WebCore):
57493         (WebCore::SelectorChecker::checkSelector): Make this a template method to accept another Context type.
57494         Another Context type will be introduced in coming patch.
57495         (WebCore::SelectorChecker::checkOneSelector):
57496         (WebCore::SelectorChecker::DOMTraversalStrategy::isFirstChild):
57497         (WebCore::SelectorChecker::DOMTraversalStrategy::isLastChild):
57498         (WebCore::SelectorChecker::DOMTraversalStrategy::isFirstOfType):
57499         (WebCore::SelectorChecker::DOMTraversalStrategy::isLastOfType):
57500         (WebCore::SelectorChecker::DOMTraversalStrategy::countElementsBefore):
57501         (WebCore::SelectorChecker::DOMTraversalStrategy::countElementsOfTypeBefore):
57502         (WebCore::SelectorChecker::DOMTraversalStrategy::countElementsAfter):
57503         (WebCore::SelectorChecker::DOMTraversalStrategy::countElementsOfTypeAfter):
57504         * css/SelectorChecker.h:
57505         (WebCore::SelectorChecker::SelectorCheckingContext::SelectorCheckingContext):
57506         (SelectorCheckingContext):
57507         (SelectorChecker):
57508         (DOMTraversalStrategy): Extracted the DOM traversal code from SelectorChecker. Another traversal code
57509         will be introduced the coming patch.
57510
57511 2012-10-04  Eric Seidel  <eric@webkit.org>
57512
57513         SVGAttributeHashTranslator does not need to copy QualifiedName in the common case
57514         https://bugs.webkit.org/show_bug.cgi?id=98473
57515
57516         Reviewed by Adam Barth.
57517
57518         I tested this using instruments on a test case which modified SVG attributes in a loop.
57519         I believe pdr has some perf-tests in this area, but they weren't needed here.  A simple sample showed this as a huge win,
57520         since we're no longer creating a QualifiedName (and thus adding it to the hash) on each QualifiedName-based lookup in SVG.
57521
57522         * svg/SVGElement.h:
57523         (WebCore::SVGAttributeHashTranslator::hash):
57524         (WebCore::SVGAttributeHashTranslator::equal):
57525
57526 2012-10-04  Julien Chaffraix  <jchaffraix@webkit.org>
57527
57528         Split the intrinsic padding update code out of RenderTableSection::layoutRows
57529         https://bugs.webkit.org/show_bug.cgi?id=98454
57530
57531         Reviewed by Eric Seidel.
57532
57533         RenderTableSection::layoutRows is very long and it's difficult to see what's
57534         going on. This change moves the intrinsic padding update code into RenderTableCell
57535         for clarity. While at it, cleaned up a bit the code (renaming variables, functions).
57536
57537         Change covered by existing table tests.
57538
57539         * rendering/RenderTableCell.cpp:
57540         (WebCore::RenderTableCell::computeIntrinsicPadding):
57541         Added this new function that does the update. Removed the 'default' case, replaced by
57542         the explicit label BASELINE_MIDDLE.
57543
57544         * rendering/RenderTableCell.h:
57545         (WebCore::RenderTableCell::setIntrinsicPaddingBefore):
57546         (WebCore::RenderTableCell::setIntrinsicPaddingAfter):
57547         (WebCore::RenderTableCell::setIntrinsicPadding):
57548         Moved those setters to the private section as we want other classes
57549         to use computeIntrinsicPadding.
57550
57551         * rendering/RenderTableSection.cpp:
57552         (WebCore::RenderTableSection::layoutRows):
57553         Replaced the code with a call to RenderTableCell::computeIntrinsicPadding.
57554         Also moved 2 variables in the loop per our coding style.
57555
57556         * rendering/RenderTableSection.h:
57557         (WebCore::RenderTableSection::rowBaseline):
57558         Renamed to match our coding style.
57559
57560 2012-10-04  Nate Chapin  <japhet@chromium.org>
57561
57562         Crash in EventHandler::mouseMoved().
57563         https://bugs.webkit.org/show_bug.cgi?id=98460
57564
57565         Reviewed by Abhishek Arya.
57566
57567         No new tests, this fixes fast/events/mouse-moved-remove-frame-crash.html.
57568
57569         * page/EventHandler.cpp:
57570         (WebCore::EventHandler::mouseMoved):
57571
57572 2012-10-04  Adam Barth  <abarth@webkit.org>
57573
57574         [V8] NotificationCenter leaks because it uses buggy custom bindings
57575         https://bugs.webkit.org/show_bug.cgi?id=98445
57576
57577         Reviewed by Tony Chang.
57578
57579         There's no reason to use custom bindings here. All they do is cause leaks..
57580
57581         * Modules/notifications/NotificationCenter.idl:
57582         * bindings/v8/custom/V8NotificationCenterCustom.cpp:
57583
57584 2012-10-04  Tab Atkins  <jackalmage@gmail.com>
57585
57586         Selector specificity categories "overflow" into higher categories
57587         https://bugs.webkit.org/show_bug.cgi?id=98295
57588
57589         Reviewed by Eric Seidel.
57590
57591         This patch adds per-component overflow guards for CSS selector specificity.
57592         Previously, we didn't guard against overflow. 
57593         Since we stored each component as a byte mapped into a single unsigned int for the whole specificity,
57594         256 of a particular simple selector was equivalent to 1 of the next-higher-group selector.
57595         This violated the Selectors specification,
57596         which requires the components to be compared lexicographically.
57597
57598         Tests: /fast/selectors/specificity-overflow.html
57599
57600         * css/CSSSelector.cpp:
57601         (WebCore::CSSSelector::specificity):
57602
57603 2012-10-04  Enrica Casucci  <enrica@apple.com>
57604
57605         Font::glyphDataAndPageForCharacter doesn't account for text orientation when using systemFallback on a cold cache.
57606         https://bugs.webkit.org/show_bug.cgi?id=98452.
57607
57608         Reviewed by Dan Bernstein.
57609
57610         The text orientation was considered only when there is a cache hit.
57611         This change moves the logic to handle text orientation to a separate
57612         inline function that is called also when the glyph is added to the cache.
57613
57614         Test: fast/text/vertical-rl-rtl-linebreak.html
57615
57616         * platform/graphics/FontFastPath.cpp:
57617         (WebCore::applyTextOrientationForCharacter): Added.
57618         (WebCore::Font::glyphDataAndPageForCharacter): Modified to use the new function in
57619         both cases of cold and warm cache.
57620
57621 2012-10-04  Adam Klein  <adamk@chromium.org>
57622
57623         MutationRecord attributeName should be null for non attribute changes
57624         https://bugs.webkit.org/show_bug.cgi?id=98438
57625
57626         Reviewed by Ojan Vafai.
57627
57628         Test: fast/mutation/mutation-record-nullity.html
57629
57630         * dom/MutationRecord.idl:
57631
57632 2012-10-04  Simon Fraser  <simon.fraser@apple.com>
57633
57634         Final part of "sync" to "flush" renaming
57635         https://bugs.webkit.org/show_bug.cgi?id=98430
57636
57637         Reviewed by Tim Horton.
57638
57639         Change method names on GraphicsLayer and GraphicsLayerClient that
57640         refer to "sync" to use the term "flush" instead, to be consistent
57641         with the rest of the code.
57642
57643         * platform/graphics/GraphicsLayer.h:
57644         (WebCore::GraphicsLayer::flushCompositingState):
57645         (WebCore::GraphicsLayer::flushCompositingStateForThisLayerOnly):
57646         * platform/graphics/GraphicsLayerClient.h:
57647         (GraphicsLayerClient):
57648         * platform/graphics/blackberry/GraphicsLayerBlackBerry.h:
57649         (WebCore::GraphicsLayerBlackBerry::notifyFlushRequired):
57650         * platform/graphics/blackberry/LayerWebKitThread.cpp:
57651         (WebCore::LayerWebKitThread::setNeedsCommit):
57652         * platform/graphics/ca/GraphicsLayerCA.cpp:
57653         (WebCore::GraphicsLayerCA::flushCompositingState):
57654         (WebCore::GraphicsLayerCA::flushCompositingStateForThisLayerOnly):
57655         (WebCore::GraphicsLayerCA::platformCALayerDidCreateTiles):
57656         (WebCore::GraphicsLayerCA::positionForCloneRootLayer):
57657         (WebCore::GraphicsLayerCA::noteLayerPropertyChanged):
57658         * platform/graphics/ca/GraphicsLayerCA.h:
57659         (GraphicsLayerCA):
57660         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
57661         (WebCore::GraphicsLayerTextureMapper::notifyChange):
57662         (WebCore::GraphicsLayerTextureMapper::flushCompositingStateForThisLayerOnly):
57663         (WebCore::GraphicsLayerTextureMapper::flushCompositingState):
57664         * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
57665         (GraphicsLayerTextureMapper):
57666         * platform/graphics/texmap/TextureMapperLayer.cpp:
57667         (WebCore::TextureMapperLayer::flushCompositingState):
57668         (WebCore::TextureMapperLayer::flushCompositingStateSelf):
57669         * platform/graphics/texmap/TextureMapperLayer.h:
57670         (TextureMapperLayer):
57671         * rendering/RenderLayerBacking.cpp:
57672         (WebCore::RenderLayerBacking::notifyFlushRequired):
57673         * rendering/RenderLayerBacking.h:
57674         (RenderLayerBacking):
57675         * rendering/RenderLayerCompositor.cpp:
57676         (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
57677         * rendering/RenderLayerCompositor.h:
57678         (WebCore::RenderLayerCompositor::notifyFlushRequired):
57679
57680 2012-10-04  Tab Atkins  <tabatkins@google.com>
57681
57682         1ex should equal .5em when the font has no x-height metric
57683         https://bugs.webkit.org/show_bug.cgi?id=80360
57684
57685         Reviewed by Eric Seidel.
57686
57687         Updated FontMetrics and CSSPrimitiveValue to have/use an explicit "hasXHeight" flag to determine how to size an 'ex' unit.
57688
57689         Updated a few of the platform font files to set the flag properly.
57690
57691         Patch cleanup by David Barr <davidbarr@chromium.org>.
57692
57693         Test: fast/css/ex-unit-with-no-x-height.html
57694
57695         * css/CSSPrimitiveValue.cpp:
57696         (WebCore::CSSPrimitiveValue::computeLengthDouble):
57697         * platform/graphics/FontMetrics.h:
57698         (WebCore::FontMetrics::FontMetrics):
57699         (WebCore::FontMetrics::setXHeight):
57700         (FontMetrics):
57701         (WebCore::FontMetrics::hasXHeight):
57702         (WebCore::FontMetrics::setHasXHeight):
57703         (WebCore::FontMetrics::reset):
57704         * platform/graphics/skia/SimpleFontDataSkia.cpp:
57705         (WebCore::SimpleFontData::platformInit):
57706
57707 2012-10-04  Ryosuke Niwa  <rniwa@webkit.org>
57708
57709         Build fix after r130411. Add the right offset.
57710         Also use RefPtr instead of a raw pointer for next and previous pointers.
57711
57712         * editing/ReplaceSelectionCommand.cpp:
57713         (WebCore::ReplaceSelectionCommand::mergeTextNodesAroundPosition):
57714
57715 2012-10-04  Alec Flett  <alecflett@chromium.org>
57716
57717         IndexedDB: promote objectstore/index backend ids to the frontend
57718         https://bugs.webkit.org/show_bug.cgi?id=97834
57719
57720         Reviewed by Tony Chang.
57721
57722         Expose int64-based database/objectStore/index ids to the renderer,
57723         step 1 of 2. Support both styles of createObjectStore and
57724         createIndex: those that take an explicit id, and those that take
57725         -1, meaning to autogenerate an id on the backend. In part 2, after
57726         the chromium side lands, support for the autogenerated ids will be
57727         removed. (See https://bugs.webkit.org/show_bug.cgi?id=98085)
57728
57729         This is a part of larger refactoring work to ultimately make the interface
57730         between the frontend and the backend simpler.
57731
57732         No new tests, extensive ASSERTs and existing tests cover correctness.
57733
57734         * Modules/indexeddb/IDBBackingStore.h:
57735         (IDBBackingStore):
57736         * Modules/indexeddb/IDBDatabase.cpp:
57737         (WebCore::IDBDatabase::createObjectStore):
57738         * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
57739         (WebCore::IDBDatabaseBackendImpl::IDBDatabaseBackendImpl):
57740         (WebCore::IDBDatabaseBackendImpl::openInternal):
57741         (WebCore::IDBDatabaseBackendImpl::metadata):
57742         (WebCore::IDBDatabaseBackendImpl::createObjectStore):
57743         (WebCore):
57744         (WebCore::IDBDatabaseBackendImpl::createObjectStoreInternal):
57745         (WebCore::IDBDatabaseBackendImpl::loadObjectStores):
57746         * Modules/indexeddb/IDBDatabaseBackendImpl.h:
57747         (IDBDatabaseBackendImpl):
57748         * Modules/indexeddb/IDBDatabaseBackendInterface.h:
57749         (IDBDatabaseBackendInterface):
57750         * Modules/indexeddb/IDBIndexBackendImpl.cpp:
57751         (WebCore::IDBIndexBackendImpl::metadata):
57752         * Modules/indexeddb/IDBIndexBackendImpl.h:
57753         (WebCore::IDBIndexBackendImpl::create):
57754         (IDBIndexBackendImpl):
57755         * Modules/indexeddb/IDBLevelDBBackingStore.cpp:
57756         (WebCore):
57757         (WebCore::getMaxObjectStoreId):
57758         (WebCore::IDBLevelDBBackingStore::getIDBDatabaseMetaData):
57759         (WebCore::IDBLevelDBBackingStore::deleteDatabase):
57760         (WebCore::IDBLevelDBBackingStore::getObjectStores):
57761         (WebCore::setMaxObjectStoreId):
57762         (WebCore::IDBLevelDBBackingStore::createObjectStore):
57763         (WebCore::getMaxIndexId):
57764         (WebCore::setMaxIndexId):
57765         (WebCore::IDBLevelDBBackingStore::createIndex):
57766         * Modules/indexeddb/IDBLevelDBBackingStore.h:
57767         (IDBLevelDBBackingStore):
57768         * Modules/indexeddb/IDBMetadata.h:
57769         (WebCore::IDBDatabaseMetadata::IDBDatabaseMetadata):
57770         (IDBDatabaseMetadata):
57771         (WebCore::IDBObjectStoreMetadata::IDBObjectStoreMetadata):
57772         (IDBObjectStoreMetadata):
57773         (WebCore::IDBIndexMetadata::IDBIndexMetadata):
57774         (IDBIndexMetadata):
57775         * Modules/indexeddb/IDBObjectStore.cpp:
57776         (WebCore::IDBObjectStore::createIndex):
57777         * Modules/indexeddb/IDBObjectStoreBackendImpl.cpp:
57778         (WebCore::IDBObjectStoreBackendImpl::IDBObjectStoreBackendImpl):
57779         (WebCore::IDBObjectStoreBackendImpl::metadata):
57780         (WebCore::IDBObjectStoreBackendImpl::createIndex):
57781         (WebCore):
57782         (WebCore::IDBObjectStoreBackendImpl::createIndexInternal):
57783         * Modules/indexeddb/IDBObjectStoreBackendImpl.h:
57784         (WebCore::IDBObjectStoreBackendImpl::create):
57785         (IDBObjectStoreBackendImpl):
57786         * Modules/indexeddb/IDBObjectStoreBackendInterface.h:
57787 2012-10-04  Pravin D  <pravind.2k4@gmail.com>
57788
57789         Layout broken after cloning and re-inserting a table with a misplaced <form>
57790         https://bugs.webkit.org/show_bug.cgi?id=86746
57791
57792         Reviewed by Julien Chaffraix.
57793
57794         There is a concept of demotion for a <form> contained in a table. A <form> is demoted if its immediate parent
57795         is either a <table>, table sections (tbody, etc) or a table row (tr). A renderer for such a <form> is created only
57796         if its display is one of the table display types (TABLE, INLINE_TABLE, TABLE_FOOTER_GROUP, etc).
57797         However when a <table> containing a demoted <form> is cloned, the <form> does not retain its demotion state and 
57798         results in the table getting improperly rendered.
57799
57800         Test: fast/table/form-with-non-table-display-inside-table-elements.html
57801
57802         * html/HTMLFormElement.cpp:
57803         (WebCore::HTMLFormElement::copyNonAttributePropertiesFromElement):
57804           Extended the virtual function for HTMLFormElement class specific implementation.
57805           The function is used to copy any necessary state information(member variables) associated with
57806           the <form> element being cloned to the current node.
57807           For HTMLFormElement node the member variable can be classified into five groups based on the 
57808           information they hold:
57809             1) Variables containing information regarding <form> subtree and elements associated with it.
57810                These get updated as and when an element is added to the <form> subtree.
57811             2) Variables containing <form> submit state information.
57812             3) Flag to hold information if reset() has been called.
57813             4) Flag(m_wasDemoted) that indicates whether the form is demoted or not, based on which it needs to
57814                be handled differently during creation of its renderer.
57815                This information is currently being updated only during the HTML tree construction phase.
57816             5) Flag(m_wasMalformed) to hold information if the <form> is malformed or not.
57817
57818           Variables of group (1) will be updated as and when elements are added to the <form> subtree. Whereas,
57819           (2) and (3) hold instance specific information, thus copying them is not required. Also (5) is currently not
57820           being used(not set by any code).
57821
57822           On the other hand, (4) is required to be copied during cloning as this information cannot be accessed
57823           during the cloning process.
57824
57825         (WebCore):
57826         * html/HTMLFormElement.h:
57827           Added copyNonAttributePropertiesFromElement() declaration.
57828
57829 2012-10-04  Dean Jackson  <dino@apple.com>
57830
57831         Attribute and Uniform variable names need translation in shader
57832         https://bugs.webkit.org/show_bug.cgi?id=70989
57833
57834         Reviewed by Tim Horton (and Darin Adler).
57835
57836         WebGL specifies some maximum lengths for variable names (attributes
57837         and uniforms). Also, some GL drivers have issues with long names. For
57838         that reason, ANGLE has an option to rewrite the shader, translating
57839         long names into short names. Turning this on helps shaders compile,
57840         but we need to keep a mapping between the original names and the
57841         translated names, so that we bind to the right location from user code
57842         (which won't ever see the translated source).
57843
57844         This provided an opportunity to clean up some other bits of code:
57845         CSS Filters examined the uniform names after a compilation; It can
57846         now use the variable name map. I also added a typedef for the
57847         HashMaps that keep the shader, the source code and the variable name
57848         mappings.
57849
57850         I also opened a followup bug to make sure these tables are deleted
57851         when the associated shaders (or linked programs) go away:
57852         https://bugs.webkit.org/show_bug.cgi?id=98204
57853
57854         Covered by existing tests (with some enhancements):
57855         - fast/canvas/webgl/attrib-location-length-limits.html:
57856         - fast/canvas/webgl/uniform-location-length-limits.html:
57857
57858         * platform/graphics/ANGLEWebKitBridge.cpp:
57859         (WebCore::getSymbolInfo): Extracts all the information on symbols (either attributes
57860         or uniforms) from the newly compiled shader.
57861         (WebCore):
57862         (WebCore::ANGLEWebKitBridge::compileShaderSource): New method name.
57863         * platform/graphics/ANGLEWebKitBridge.h:
57864         (WebCore::getUniforms): Deleted this method.
57865         (WebCore::ANGLEShaderSymbol::isSampler): Make sure the symbol is a uniform.
57866         (ANGLEWebKitBridge):
57867         * platform/graphics/GraphicsContext3D.h:
57868         (WebCore::GraphicsContext3D::SymbolInfo::SymbolInfo): A new object that
57869         holds the size, type and translated name of a symbol from a WebGL shader.
57870         (ShaderSourceEntry):
57871         (WebCore::GraphicsContext3D::ShaderSourceEntry::ShaderSourceEntry): Now keeps track
57872         of the translated source code and symbol mappings.
57873         (WebCore::GraphicsContext3D::ShaderSourceEntry::symbolMap): Helper function to
57874         get the member variable corresponding to the type of symbol you're asking fo.
57875         * platform/graphics/filters/CustomFilterValidatedProgram.cpp:
57876         (WebCore::CustomFilterValidatedProgram::CustomFilterValidatedProgram): Calls new method
57877         name which also produces a set of symbols to examine.
57878         * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
57879         (WebCore::Extensions3DOpenGLCommon::getTranslatedShaderSourceANGLE): We now can pass
57880         in some extra compile options to do translation of long symbol names. Also fill the
57881         map of translated symbol names.
57882         * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp:
57883         (WebCore::GraphicsContext3D::compileShader):
57884         (WebCore::GraphicsContext3D::mappedSymbolName): Returns the mapped name for
57885         a shader symbol if it was translated during compilation.
57886         (WebCore):
57887         (WebCore::GraphicsContext3D::getAttribLocation):
57888         (WebCore::GraphicsContext3D::getShaderiv):
57889         (WebCore::GraphicsContext3D::getShaderInfoLog):
57890         (WebCore::GraphicsContext3D::getShaderSource):
57891         (WebCore::GraphicsContext3D::getUniformLocation):
57892
57893 2012-10-04  Alpha Lam  <hclam@chromium.org>
57894
57895         [skia] Drawing a subrect of bitmap image is misaligned
57896         https://bugs.webkit.org/show_bug.cgi?id=95121
57897
57898         Reviewed by Stephen White.
57899
57900         When drawing a subrect of BitmapImage and the subrect is not aligned
57901         to integer boundaries, skia expands it to the closest enclosing integer
57902         rectangle. This creates prominent rendering artifacts when an image
57903         is used as background and its sub-regions are invalidated frequently.
57904
57905         This patch fixes the problem by doing alignment to integer boundaries
57906         and clipping for both cases of RESAMPLE_AWESOME and RESAMPLE_LINEAR.
57907
57908         A clip rect is applied to the canvas using original destination
57909         rectangle, while source and destination rectangles are enlarged
57910         appropriately to ensure source rectangle is aligned.
57911
57912         This patch also fixes a closely related problem. In RESAMPLE_AWESOME
57913         resampling mode the previous algorithm applies different approximated
57914         scale factor for each scaled image fragment. This caused the stitched
57915         image to look ugly.
57916
57917         Scale factor is approximated using entire image size, this gives a
57918         more accurate approximation because of greater denominator and a
57919         consistent scale factor across all fragments.
57920
57921         Changes in Skia enable caching of the scaled image and return the
57922         scaled fragment because scale factor is now consistent for all
57923         fragments.
57924
57925         Tests: fast/images/paint-subrect-grid.html
57926                fast/images/paint-subrect.html
57927                fast/images/repaint-subrect-grid.html
57928
57929         * platform/graphics/skia/ImageSkia.cpp:
57930         (WebCore::computeResamplingMode): Use float for width and height.
57931         (WebCore):
57932         (WebCore::areBoundariesIntegerAligned):
57933         (WebCore::computeBitmapDrawRects):
57934         (WebCore::extractScaledImageFragment):
57935         (WebCore::drawResampledBitmap): New algorithm for drawing scaled image fragment.
57936         (WebCore::paintSkBitmap):
57937         (WebCore::Image::drawPattern):
57938         (WebCore::BitmapImage::draw): Use SkRect instead of SkIRect.
57939         (WebCore::BitmapImageSingleFrameSkia::draw):
57940         * platform/graphics/skia/NativeImageSkia.cpp:
57941         Changing the algorithm for extracting a scaled image fragment.
57942         A fragment is now identified by (scaledImageSize, scaledImageSubset).
57943         (WebCore::NativeImageSkia::hasResizedBitmap):
57944         (WebCore::NativeImageSkia::resizedBitmap):
57945         (WebCore::NativeImageSkia::shouldCacheResampling):
57946         (WebCore::NativeImageSkia::CachedImageInfo::CachedImageInfo):
57947         (WebCore):
57948         (WebCore::NativeImageSkia::CachedImageInfo::isEqual):
57949         (WebCore::NativeImageSkia::CachedImageInfo::set):
57950         (WebCore::NativeImageSkia::CachedImageInfo::rectInSubset):
57951         * platform/graphics/skia/NativeImageSkia.h:
57952         (NativeImageSkia):
57953         (CachedImageInfo):
57954
57955 2012-10-03  Ryosuke Niwa  <rniwa@webkit.org>
57956
57957         ReplaceSelectionCommand should merge text nodes
57958         https://bugs.webkit.org/show_bug.cgi?id=98188
57959
57960         Reviewed by Levi Weintraub.
57961
57962         Added mergeTextNodesAroundPosition to ReplaceSelectionCommand to merge text nodes after the replace in
57963         completeHTMLReplacement. Also fixed a bunch of bugs in other classes and functions to make this work.
57964
57965         This behavior change is tested by existing tests.
57966
57967         * editing/InsertParagraphSeparatorCommand.cpp:
57968         (WebCore::InsertParagraphSeparatorCommand::doApply): When splitting a text node, place the insertionPosition
57969         at the end of the first half. Leaving it at the beginning of the second half confuses the rest of the code in
57970         the function. However, the logic to handle the "insignificant" white spaces needs the position at the start of
57971         the second half. So keep this position.
57972         * editing/ReplaceSelectionCommand.cpp:
57973         (WebCore::ReplaceSelectionCommand::doApply): Update visibleStart after inserting a paragraph separator so that
57974         the logic to cleanup the nested div checks the right condition (right beneath it starting with a long comment).
57975         (WebCore::ReplaceSelectionCommand::addSpacesForSmartReplace): Insert a space for smart paste at the appropriate
57976         offset instead of at the end of endNode. Also update the layout before obtaining startDownstream as we may have 
57977         modified the DOM by inserting a space for endNode. Finally, a non-breaking space should be treated like a space
57978         isCharacterSmartReplaceExempt for the purpose of smart replace. e.g. if we're inserting "world" after
57979         "hello&nbsp;", we shouldn't be inserting another space between "hello" and "world".
57980         (WebCore::ReplaceSelectionCommand::completeHTMLReplacement):
57981         (WebCore::ReplaceSelectionCommand::mergeTextNodesAroundPosition): Added. Merge text nodes around position, and
57982         adjust position and positionOnlyToBeUpdated accordingly. We need to call updatePositionForNodeRemoval when
57983         positions were before or after the text node.
57984         * editing/ReplaceSelectionCommand.h:
57985         (ReplaceSelectionCommand):
57986
57987 2012-10-04  Tony Chang  <tony@chromium.org>
57988
57989         Fix <input type="month"> tests
57990         https://bugs.webkit.org/show_bug.cgi?id=98426
57991
57992         Reviewed by Ojan Vafai.
57993
57994         The month picker uses flexbox and assumes that it will be aligned with
57995         the last line box. This looks visually correct. I will follow up on
57996         www-style to see what the expected behavior is.
57997
57998         Tests: fast/forms/month-multiple-fields tests cover this.
57999
58000         * rendering/RenderFlexibleBox.cpp:
58001         * rendering/RenderFlexibleBox.h:
58002
58003 2012-10-04  Sheriff Bot  <webkit.review.bot@gmail.com>
58004
58005         Unreviewed, rolling out r130396.
58006         http://trac.webkit.org/changeset/130396
58007         https://bugs.webkit.org/show_bug.cgi?id=98421
58008
58009         This patch is causing crashes on 4 tests on Lion Debug and
58010         Mountain Lion Debug (Requested by jernoble on #webkit).
58011
58012         * rendering/RenderLayerCompositor.cpp:
58013         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
58014         (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
58015         * rendering/RenderLayerCompositor.h:
58016         * testing/InternalSettings.cpp:
58017         (WebCore::InternalSettings::Backup::Backup):
58018         (WebCore::InternalSettings::Backup::restoreTo):
58019         * testing/InternalSettings.h:
58020         (Backup):
58021
58022 2012-10-04  Tony Chang  <tony@chromium.org>
58023
58024         inline-flex baseline is sometimes wrong
58025         https://bugs.webkit.org/show_bug.cgi?id=96188
58026
58027         Reviewed by Ojan Vafai.
58028
58029         Implement the necessary methods to get the proper baseline alignment of flexbox.
58030         We were falling back to the inline-block behavior.
58031
58032         Test: css3/flexbox/flexbox-baseline.html
58033
58034         * rendering/RenderFlexibleBox.cpp:
58035         (WebCore::RenderFlexibleBox::RenderFlexibleBox):
58036         (WebCore::RenderFlexibleBox::baselinePosition): Used to get the baseline of the box.
58037         Mostly just the first line box baseline.
58038         (WebCore):
58039         (WebCore::RenderFlexibleBox::lastLineBoxBaseline): This is used for getting the baseline when in an inline-block.
58040         We actually don't want the last line, but the flexbox's baseline.
58041         (WebCore::RenderFlexibleBox::firstLineBoxBaseline): Compute the baseline according to the rules in the spec.
58042         (WebCore::RenderFlexibleBox::repositionLogicalHeightDependentFlexItems): Keep track of the number of children on the
58043         first line so we don't have to re-compute this when getting the baseline.
58044         (WebCore::RenderFlexibleBox::crossAxisExtentForChild): Make const.
58045         (WebCore::RenderFlexibleBox::mainAxisExtentForChild): Make const.
58046         (WebCore::RenderFlexibleBox::hasAutoMarginsInCrossAxis): Make const.
58047         * rendering/RenderFlexibleBox.h: Add a size_t to keep track of how many children are in the first line.
58048
58049 2012-10-04  Xianzhu Wang  <wangxianzhu@chromium.org>
58050
58051         [Chromium] Should set unitsPerEm in SimpleFontDataSkia.cpp
58052         https://bugs.webkit.org/show_bug.cgi?id=98100
58053
58054         Reviewed by Stephen White.
58055
58056         At least on chromium-linux and chromium-android, unitsPerEm was not set
58057         according to the information in the font, causing at least problems in
58058         OpenTypeVerticalData when calculating vertical advance.
58059
58060         Test: fast/writing-mode/vertical-font-vmtx-units-per-em.html
58061
58062         * platform/graphics/skia/SimpleFontDataSkia.cpp:
58063         (WebCore::SimpleFontData::platformInit):
58064
58065 2012-10-04  Simon Fraser  <simon.fraser@apple.com>
58066
58067         Standardize on "flush" terminology for compositing layer flushing/syncing
58068         https://bugs.webkit.org/show_bug.cgi?id=98321
58069
58070         Reviewed by Simon Fraser.
58071
58072         Rename compositing-related methods that refer to "syncing" to instead
58073         refer to "flushing".
58074
58075         * WebCore.exp.in:
58076         * loader/EmptyClients.h:
58077         (WebCore::EmptyChromeClient::scheduleCompositingLayerFlush):
58078         * page/ChromeClient.h:
58079         (ChromeClient):
58080         * page/FrameView.cpp:
58081         (WebCore::FrameView::flushCompositingStateForThisFrame):
58082         (WebCore::FrameView::flushCompositingStateIncludingSubframes):
58083         (WebCore::FrameView::paintContents):
58084         * page/FrameView.h:
58085         (FrameView):
58086         * rendering/RenderLayerCompositor.cpp:
58087         (WebCore::RenderLayerCompositor::scheduleLayerFlush):
58088         (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
58089
58090 2012-10-04  Peter Rybin  <peter.rybin@gmail.com>
58091
58092         Web Inspector: expose object internal properties such as PrimitiveValue or BoundThis
58093         https://bugs.webkit.org/show_bug.cgi?id=94397
58094
58095         Reviewed by Yury Semikhatsky.
58096
58097         Internal property access is built from Injected Script to V8 debug API. JSC binding
58098         has a stub imlpementation. Protocol is updated to explicitly reflect internal properties.
58099
58100         Test: inspector-protocol/runtime-getProperties.html
58101
58102         * bindings/js/JSInjectedScriptHostCustom.cpp:
58103         (WebCore::JSInjectedScriptHost::getInternalProperties):
58104         (WebCore):
58105         * bindings/v8/DebuggerScript.js:
58106         * bindings/v8/ScriptDebugServer.cpp:
58107         (WebCore::ScriptDebugServer::getInternalProperties):
58108         (WebCore):
58109         * bindings/v8/ScriptDebugServer.h:
58110         (ScriptDebugServer):
58111         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
58112         (WebCore::V8InjectedScriptHost::getInternalPropertiesCallback):
58113         (WebCore):
58114         * inspector/InjectedScript.cpp:
58115         (WebCore::InjectedScript::getInternalProperties):
58116         (WebCore):
58117         * inspector/InjectedScript.h:
58118         (InjectedScript):
58119         * inspector/InjectedScriptHost.idl:
58120         * inspector/InjectedScriptSource.js:
58121         (.):
58122         * inspector/Inspector.json:
58123         * inspector/InspectorRuntimeAgent.cpp:
58124         (WebCore::InspectorRuntimeAgent::getProperties):
58125         * inspector/InspectorRuntimeAgent.h:
58126         (InspectorRuntimeAgent):
58127
58128 2012-10-04  Sami Kyostila  <skyostil@chromium.org>
58129
58130         Fixed position visibility check does not consider descendants
58131         https://bugs.webkit.org/show_bug.cgi?id=98144
58132
58133         Reviewed by Simon Fraser.
58134
58135         The check against creating composition layers for invisible fixed positioned
58136         elements is too aggressive in that it does not consider descendants of the
58137         fixed positioned element that may be visible even though the element itself is
58138         out of view.
58139
58140         Fix the problem by calculating the true composited bounds of the fixed
58141         element instead of just using the size of the fixed layer. Because calculating
58142         the true bounds may be expensive, it is only done if the fixed layer itself is
58143         invisible.
58144
58145         Test: compositing/layer-creation/fixed-position-absolute-descendant.html
58146
58147         * rendering/RenderLayerCompositor.cpp:
58148         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
58149         (WebCore::RenderLayerCompositor::requiresCompositingForPosition):
58150         * rendering/RenderLayerCompositor.h:
58151
58152 2012-10-04  Vsevolod Vlasov  <vsevik@chromium.org>
58153
58154         Web Inspector: When uiSourceCode content has diverged from VM script, call frames should be shown in temporary script based uiSourceCodes.
58155         https://bugs.webkit.org/show_bug.cgi?id=98385
58156
58157         Reviewed by Pavel Feldman.
58158
58159         When javaScriptSource diverges from VM, ResourceScriptMapping now switches debugging
58160         to temporary VM scripts based uiSourceCode with isDivergedReplacement property set.
58161         Added hasDivergedFromVM and isDivergingFromVM properties to JavaScriptSource.
58162         JavaScriptSourceFrame and ScriptSnippetsModel are updated to process breakpoint changes correctly.
58163
58164         * inspector/front-end/BreakpointManager.js:
58165         (WebInspector.BreakpointManager.prototype.restoreBreakpoints):
58166         (WebInspector.BreakpointManager.prototype._uiSourceCodeRemoved):
58167         * inspector/front-end/JavaScriptSource.js:
58168         (WebInspector.JavaScriptSource.prototype.workingCopyCommitted):
58169         (WebInspector.JavaScriptSource.prototype.workingCopyChanged):
58170         (WebInspector.JavaScriptSource.prototype.fireHasDivergedFromVMChanged):
58171         * inspector/front-end/JavaScriptSourceFrame.js:
58172         (WebInspector.JavaScriptSourceFrame.prototype.commitEditing):
58173         (WebInspector.JavaScriptSourceFrame.prototype._hasDivergedFromVM):
58174         (WebInspector.JavaScriptSourceFrame.prototype.onTextChanged):
58175         (WebInspector.JavaScriptSourceFrame.prototype._getBreakpointDecorations):
58176         (WebInspector.JavaScriptSourceFrame.prototype._muteBreakpointsWhileEditing):
58177         (WebInspector.JavaScriptSourceFrame.prototype._didEditContent):
58178         (WebInspector.JavaScriptSourceFrame.prototype._restoreBreakpointsAfterEditing):
58179         (WebInspector.JavaScriptSourceFrame.prototype._addBreakpointDecoration):
58180         * inspector/front-end/ResourceScriptMapping.js:
58181         (WebInspector.ResourceScriptMapping.prototype.rawLocationToUILocation):
58182         (WebInspector.ResourceScriptMapping.prototype._hasDivergedFromVMChanged):
58183         (WebInspector.ResourceScriptMapping.prototype._bindUISourceCodeToScripts):
58184         (WebInspector.ResourceScriptMapping.prototype._getOrCreateTemporaryUISourceCode):
58185         * inspector/front-end/ScriptSnippetModel.js:
58186         (WebInspector.ScriptSnippetModel.prototype._createUISourceCodeForScript):
58187         (WebInspector.ScriptSnippetModel.prototype._restoreBreakpoints):
58188         * inspector/front-end/ScriptsPanel.js:
58189         (WebInspector.ScriptsPanel.prototype._revealExecutionLine):
58190         * inspector/front-end/UISourceCode.js:
58191         (WebInspector.UISourceCode.prototype.formatted):
58192
58193 2012-10-04  Vsevolod Vlasov  <vsevik@chromium.org>
58194
58195         Web Inspector: Scripts panel should not automatically switch to snippet evaluation when previously evaluated snippet is edited.
58196         https://bugs.webkit.org/show_bug.cgi?id=98402
58197
58198         Reviewed by Pavel Feldman.
58199
58200         Scripts panel does not automatically switch to snippet evaluation when
58201         one edits previously evaluated snippet.
58202
58203         * inspector/front-end/ScriptSnippetModel.js:
58204         (WebInspector.ScriptSnippetModel.prototype._createUISourceCodeForScript):
58205         * inspector/front-end/ScriptsPanel.js:
58206         (WebInspector.ScriptsPanel.prototype._revealExecutionLine):
58207
58208 2012-10-04  Balazs Kelemen  <kbalazs@webkit.org>
58209
58210         Don't allow to disable compositing in forced compositing mode
58211         https://bugs.webkit.org/show_bug.cgi?id=98048
58212
58213         Reviewed by Jocelyn Turcotte.
58214
58215         Make forced compositing mode imply accelerated compositing. This will
58216         avoid unexpected situations for platforms that don't want to support
58217         the non-accelerated rendering path.
58218
58219         Covered by existing tests.
58220
58221         * WebCore.exp.in: Export Settings::setAcceleratedCompositingEnabled
58222         because it has been deinlined.
58223         * page/Settings.cpp:
58224         (WebCore::Settings::setAcceleratedCompositingEnabled):
58225         (WebCore::Settings::setForceCompositingMode):
58226         (WebCore):
58227         * page/Settings.h:
58228         (Settings):
58229         (WebCore::Settings::forceCompositingMode): Make it const as a side fix.
58230
58231 2012-10-04  Harald Alvestrand  <hta@google.com>
58232
58233         Change RTCPeerConnection GetStats to use Date timestamp format
58234         https://bugs.webkit.org/show_bug.cgi?id=98263
58235
58236         Reviewed by Yury Semikhatsky.
58237
58238         Tested by extension to RTCPeerConnection-stats test.
58239
58240         * Modules/mediastream/RTCStatsElement.cpp:
58241         (WebCore::RTCStatsElement::create):
58242         (WebCore::RTCStatsElement::RTCStatsElement):
58243         * Modules/mediastream/RTCStatsElement.h: long -> double
58244         (RTCStatsElement):
58245         (WebCore::RTCStatsElement::timestamp):
58246         * Modules/mediastream/RTCStatsElement.idl: long -> Date
58247         * Modules/mediastream/RTCStatsReport.cpp:
58248         (WebCore::RTCStatsReport::addElement):
58249         * Modules/mediastream/RTCStatsReport.h:
58250         (RTCStatsReport):
58251         * Modules/mediastream/RTCStatsResponse.cpp:
58252         (WebCore::RTCStatsResponse::addElement):
58253         * Modules/mediastream/RTCStatsResponse.h:
58254         (RTCStatsResponse):
58255         * platform/chromium/support/WebRTCStatsResponse.cpp:
58256         (WebKit::WebRTCStatsResponse::addElement):
58257         * platform/mediastream/RTCStatsResponseBase.h:
58258         (RTCStatsResponseBase):
58259
58260 2012-10-04  Sheriff Bot  <webkit.review.bot@gmail.com>
58261
58262         Unreviewed, rolling out r130377.
58263         http://trac.webkit.org/changeset/130377
58264         https://bugs.webkit.org/show_bug.cgi?id=98392
58265
58266         Chromium Win compilation is broken (Requested by yurys on
58267         #webkit).
58268
58269         * Modules/mediastream/RTCStatsElement.cpp:
58270         (WebCore::RTCStatsElement::create):
58271         (WebCore::RTCStatsElement::RTCStatsElement):
58272         * Modules/mediastream/RTCStatsElement.h:
58273         (RTCStatsElement):
58274         (WebCore::RTCStatsElement::timestamp):
58275         * Modules/mediastream/RTCStatsElement.idl:
58276         * Modules/mediastream/RTCStatsReport.cpp:
58277         (WebCore::RTCStatsReport::addElement):
58278         * Modules/mediastream/RTCStatsReport.h:
58279         (RTCStatsReport):
58280         * Modules/mediastream/RTCStatsResponse.cpp:
58281         (WebCore::RTCStatsResponse::addElement):
58282         * Modules/mediastream/RTCStatsResponse.h:
58283         (RTCStatsResponse):
58284         * platform/chromium/support/WebRTCStatsResponse.cpp:
58285         (WebKit::WebRTCStatsResponse::addElement):
58286         * platform/mediastream/RTCStatsResponseBase.h:
58287         (RTCStatsResponseBase):
58288
58289 2012-10-04  Harald Alvestrand  <hta@google.com>
58290
58291         Change RTCPeerConnection GetStats to use Date timestamp format
58292         https://bugs.webkit.org/show_bug.cgi?id=98263
58293
58294         Reviewed by Adam Barth.
58295
58296         Tested by extension to RTCPeerConnection-stats test.
58297
58298         * Modules/mediastream/RTCStatsElement.cpp:
58299         (WebCore::RTCStatsElement::create):
58300         (WebCore::RTCStatsElement::RTCStatsElement):
58301         * Modules/mediastream/RTCStatsElement.h: long -> double
58302         (RTCStatsElement):
58303         (WebCore::RTCStatsElement::timestamp):
58304         * Modules/mediastream/RTCStatsElement.idl: long -> Date
58305         * Modules/mediastream/RTCStatsReport.cpp:
58306         (WebCore::RTCStatsReport::addElement):
58307         * Modules/mediastream/RTCStatsReport.h:
58308         (RTCStatsReport):
58309         * Modules/mediastream/RTCStatsResponse.cpp:
58310         (WebCore::RTCStatsResponse::addElement):
58311         * Modules/mediastream/RTCStatsResponse.h:
58312         (RTCStatsResponse):
58313         * platform/chromium/support/WebRTCStatsResponse.cpp:
58314         (WebKit::WebRTCStatsResponse::addElement):
58315         * platform/mediastream/RTCStatsResponseBase.h:
58316         (RTCStatsResponseBase):
58317
58318 2012-10-05  Kent Tamura  <tkent@chromium.org>
58319
58320         [Chromium] Enable the multiple fields UI for input[type=date]
58321         https://bugs.webkit.org/show_bug.cgi?id=98351
58322
58323         Reviewed by Hajime Morita.
58324
58325         Touch files related to ENABLE_INPUT_TYPE_DATE_LEGACY_UI to avoid build
58326         issues.
58327
58328         No new tests. Many tests will be landed shortly.
58329
58330         * html/DateInputType.cpp:
58331         * html/DateInputType.h:
58332
58333 2012-10-04  Kent Tamura  <tkent@chromium.org>
58334
58335         Add code for input[type=date] with the multiple fields UI
58336         https://bugs.webkit.org/show_bug.cgi?id=98340
58337
58338         Reviewed by Hajime Morita.
58339
58340         The new code is available if !ENABLE(INPUT_TYPE_DATE_LEGACY_UI). At this
58341         moment, there are no platforms enabling the new code. We're going to
58342         enable it soon on desktop Chromium, and add tests. Then we're going to
58343         remove the code for ENABLE(INPUT_TYPE_DATE_LEGACY_UI).
58344
58345         ENABLE(INPUT_TYPE_DATE_LEGACY_UI) means the current UI; input[type=date]
58346         is represetnted as a kind of text field, and it has code to invoke a
58347         calendar picker.
58348         ENABLE(CALENDAR_PICKER) was used wrongly. It meant calendar picker
58349         support + text field UI of input[type=date]. Now it means only calendar
58350         picker support.
58351
58352         * html/DateInputType.h:
58353         (WebCore): If ENABLE(INPUT_MULTIPLE_FIELDS_UI) &&
58354         !ENABLE(INPUT_TYPE_DATE_LEGACY_UI), change the base class to the class
58355         for multiple fields UI.
58356         (DateInputType): Wrap the code for text fields behavior and calendar
58357         picker UI with ENABLE(INPUT_TYPE_DATE_LEGACY_UI). Add functions for
58358         ENABLE(INPUT_MULTIPLE_FIELDS_UI)
58359         * html/DateInputType.cpp:
58360         (WebCore::DateInputType::DateInputType):
58361         Change the flag name; CALENDAR_PICKER -> INPUT_TYPE_DATE_LEGACY_UI
58362         (WebCore): ditto.
58363         (WebCore::DateInputType::formatDateTimeFieldsState):
58364         A callback for multiple fields UI. This constructs a string value from
58365         each of values of multiple fields.
58366         Note that we don't need to do +1 to month().
58367         (WebCore::DateInputType::setupLayoutParameters):
58368         A callback for multiple fields UI. Passes information to build UI.
58369
58370         * html/BaseMultipleFieldsDateAndTimeInputType.h:
58371         (BaseMultipleFieldsDateAndTimeInputType):
58372         Add m_pickerIndicatorIsAlwaysVisible member, wrap some members with flags.
58373         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
58374         (WebCore::BaseMultipleFieldsDateAndTimeInputType::BaseMultipleFieldsDateAndTimeInputType):
58375         Initialize m_pickerIndicatorIsAlwaysVisible.
58376         (WebCore::BaseMultipleFieldsDateAndTimeInputType::createShadowSubtree):
58377         If a type supports calendar picker, we should always show the picker
58378         indicator. We introduce m_pickerIndicatorIsAlwaysVisible flag, and ask
58379         RenderTheme for support status of each of types.
58380         Add a local variable 'document' to avoid multiple element()->document().
58381         (WebCore::BaseMultipleFieldsDateAndTimeInputType::updatePickerIndicatorVisibility):
58382         - If m_pickerIndicatorIsAlwaysVisible, don't hide the picker indicator element.
58383         - Wrap the code with appropriate flags.
58384
58385         * rendering/RenderTheme.h:
58386         (WebCore::RenderTheme::supportsCalendarPicker): Added.
58387         * rendering/RenderThemeChromiumMac.h: Override supportsCalendarPicker.
58388         * rendering/RenderThemeChromiumMac.mm:
58389         (WebCore::RenderThemeChromiumMac::supportsCalendarPicker):
58390         Added. Delegate to RenderThemeChromiumCommon.
58391         * rendering/RenderThemeChromiumSkia.h: Override supportsCalendarPicker.
58392         * rendering/RenderThemeChromiumSkia.cpp:
58393         (WebCore::RenderThemeChromiumSkia::supportsCalendarPicker):
58394         Added. Delegate to RenderThemeChromiumCommon.
58395         * rendering/RenderThemeChromiumCommon.h:
58396         (RenderThemeChromiumCommon): Declare supportsCalendarPicker.
58397         * rendering/RenderThemeChromiumCommon.cpp:
58398         (WebCore::RenderThemeChromiumCommon::supportsCalendarPicker):
58399         Returns true if the type is "date."
58400
58401         * html/DateTimeFieldsState.h:
58402         (DateTimeFieldsState): Add a comment for the m_month field.
58403
58404 2012-10-04  Kent Tamura  <tkent@chromium.org>
58405
58406         DateTimeYearFieldElement should respect min/max values specified by page authors
58407         https://bugs.webkit.org/show_bug.cgi?id=98227
58408
58409         Reviewed by Hajime Morita.
58410
58411         Before this patch, we always set 1 to the minimum limit and 275760 to
58412         the maximum limit for a year field, and a user can specify any year
58413         regardless of min/max attributes. Such wide range is unnecessary for
58414         normal applications and we should provide a way to limit the range.
58415
58416         Test: fast/forms/month-multiple-fields/month-multiple-fields-keyboard-events.html
58417
58418         * html/shadow/DateTimeFieldElements.h:
58419         To add four constructor arguments, introduce Parameters struct.
58420         Actually, we add the followings;
58421          - minimum year in UI
58422          - maximum year in UI
58423          - min attribute is specified
58424          - max attribute is specified
58425         (Parameters):
58426         (WebCore::DateTimeYearFieldElement::Parameters::Parameters):
58427         (DateTimeYearFieldElement):
58428         * html/shadow/DateTimeFieldElements.cpp:
58429         (WebCore::DateTimeYearFieldElement::DateTimeYearFieldElement): ditto.
58430         (WebCore::DateTimeYearFieldElement::create): ditto.
58431         (WebCore::DateTimeYearFieldElement::clampValueForHardLimits):
58432         Override DateTimeNumericFieldElement::clampValueForHardLimits.
58433         By this, we allow to set out-of-range year values.
58434         (WebCore::currentFullYear): A helper to get the current year.
58435         (WebCore::DateTimeYearFieldElement::defaultValueForStepDown):
58436         If the field has no value and step down operation occurs,
58437          - the field has the current year if the max attribute is not specified.
58438          - the field has the maximum value otherwise.
58439         (WebCore::DateTimeYearFieldElement::defaultValueForStepUp): Similar change.
58440
58441         * html/shadow/DateTimeNumericFieldElement.h:
58442         (DateTimeNumericFieldElement): Declare clampValueForHardLimits.
58443         * html/shadow/DateTimeNumericFieldElement.cpp:
58444         (WebCore::DateTimeNumericFieldElement::clampValueForHardLimits):
58445         (WebCore::DateTimeNumericFieldElement::setValueAsInteger):
58446         Call clampValueForHardLimits instead of clampValue in order to
58447         distinguish limits for UI and limits for internal value update.
58448
58449         * html/shadow/DateTimeEditElement.h:
58450         (LayoutParameters): Add minimumYear and maximumYear members.
58451         (WebCore::DateTimeEditElement::LayoutParameters::LayoutParameters):
58452         Initialize minimumYear and maximumYear.
58453         (WebCore::DateTimeEditElement::LayoutParameters::undefinedYear):
58454         Represents 'undefined' value for minimumYear and maximumYear.
58455         * html/shadow/DateTimeEditElement.cpp:
58456         (WebCore::DateTimeEditBuilder::visitField):
58457         Preparas DateTimeYearField::Parameters and pass it to the DateTimeYearField factory.
58458
58459         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
58460         (WebCore::BaseMultipleFieldsDateAndTimeInputType::fullYear):
58461         A helper to get a year value from an attribute value string.
58462         * html/BaseMultipleFieldsDateAndTimeInputType.h:
58463         (BaseMultipleFieldsDateAndTimeInputType): Add fullYear().
58464
58465         * html/DateTimeInputType.cpp:
58466         (WebCore::DateTimeInputType::setupLayoutParameters):
58467         Set LayoutParameters::minimumYear and maximumYear.
58468         * html/DateTimeLocalInputType.cpp:
58469         (WebCore::DateTimeLocalInputType::setupLayoutParameters): ditto.
58470         * html/MonthInputType.cpp:
58471         (WebCore::MonthInputType::setupLayoutParameters): ditto.
58472         * html/WeekInputType.cpp:
58473         (WebCore::WeekInputType::setupLayoutParameters): ditto.
58474
58475 2012-10-03  Adam Barth  <abarth@webkit.org>
58476
58477         Unreviewed. Fix parse error in vcproj file.
58478
58479         * WebCore.vcproj/WebCore.vcproj:
58480
58481 2012-10-03  Keishi Hattori  <keishi@webkit.org>
58482
58483         Implement localizeValue for TimeInputType
58484         https://bugs.webkit.org/show_bug.cgi?id=98237
58485
58486         Reviewed by Kent Tamura.
58487
58488         We want to localize time values for the suggestion picker.
58489         DateTimeStringBuilder parses a format and creates a formatted string.
58490
58491         Added chromium unit test LocaleMacTest.formatTime
58492
58493         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
58494         (WebCore::BaseMultipleFieldsDateAndTimeInputType::shouldHaveSecondField): Moved from LayoutParameters because we want to use it inside localizeValue.
58495         (WebCore):
58496         * html/BaseMultipleFieldsDateAndTimeInputType.h:
58497         (BaseMultipleFieldsDateAndTimeInputType):
58498         * html/DateTimeInputType.cpp:
58499         (WebCore::DateTimeInputType::setupLayoutParameters):
58500         * html/DateTimeLocalInputType.cpp:
58501         (WebCore::DateTimeLocalInputType::setupLayoutParameters):
58502         * html/TimeInputType.cpp:
58503         (WebCore::TimeInputType::localizeValue):
58504         (WebCore):
58505         (WebCore::TimeInputType::setupLayoutParameters):
58506         * html/TimeInputType.h:
58507         (TimeInputType):
58508         * html/shadow/DateTimeEditElement.cpp:
58509         (WebCore):
58510         * html/shadow/DateTimeEditElement.h:
58511         (WebCore::DateTimeEditElement::LayoutParameters::LayoutParameters):
58512         * platform/text/LocaleICU.cpp:
58513         (WebCore::LocaleICU::formatDateTime): Calls Localizer::formatDateTime if the date component is not a date.
58514         * platform/text/LocaleICU.h:
58515         (LocaleICU):
58516         * platform/text/LocaleWin.cpp:
58517         (WebCore::LocaleWin::formatDateTime): Calls Localizer::formatDateTime if the date component is not a date.
58518         * platform/text/LocaleWin.h:
58519         (LocaleWin):
58520         * platform/text/LocaleNone.cpp:
58521         (LocaleNone):
58522         (WebCore::LocaleNone::formatDateTime):
58523         * platform/text/Localizer.cpp:
58524         (DateTimeStringBuilder):
58525         (WebCore):
58526         (WebCore::DateTimeStringBuilder::DateTimeStringBuilder): Takes a
58527         Localizer pointer. This is used inside the Localizer so the Localizer
58528         will out live the DateTimeStringBuilder.
58529         (WebCore::DateTimeStringBuilder::build): Builds a localized string for the given format.
58530         (WebCore::DateTimeStringBuilder::zeroPadString):
58531         (WebCore::DateTimeStringBuilder::appendNumber): Appends a number with left zero padding to match width.
58532         (WebCore::DateTimeStringBuilder::visitField):
58533         (WebCore::DateTimeStringBuilder::visitLiteral):
58534         (WebCore::DateTimeStringBuilder::toString): Returns the localized string.
58535         (WebCore::Localizer::formatDateTime):
58536         * platform/text/Localizer.h:
58537         * platform/text/mac/LocaleMac.h:
58538         (LocaleMac):
58539         * platform/text/mac/LocaleMac.mm:
58540         (WebCore::LocaleMac::formatDateTime): Calls Localizer::formatDateTime if the date component is not a date.
58541
58542 2012-10-03  Douglas Stockwell  <dstockwell@chromium.org>
58543
58544         Chromium needs support for border radius clipping
58545         https://bugs.webkit.org/show_bug.cgi?id=69866
58546
58547         Reviewed by Stephen White.
58548
58549         Changes to make this suitably efficient have already landed upstream in skia:
58550         http://code.google.com/p/skia/source/detail?r=2924
58551
58552         Covered by existing tests.
58553
58554         * rendering/RenderLayer.cpp:
58555
58556 2012-10-03  Benjamin Poulain  <bpoulain@apple.com>
58557
58558         Simplify attribute access in Element::computeInheritedLanguage
58559         https://bugs.webkit.org/show_bug.cgi?id=98327
58560
58561         Reviewed by Andreas Kling.
58562
58563         * dom/Element.cpp:
58564         (WebCore::Element::computeInheritedLanguage):
58565         By using Element::fastGetAttribute(), we check for the existence of attributeData twice
58566         and do a bunch of useless operation on AtomicString.
58567
58568         By using ElementAttributeData directly, we can cut it to the two important branch.
58569
58570 2012-10-03  Kangil Han  <kangil.han@samsung.com>
58571
58572         Fix unused parameter compile warnings.
58573         https://bugs.webkit.org/show_bug.cgi?id=98243
58574
58575         Reviewed by Alexey Proskuryakov.
58576
58577         Fixed unused parameter compile warning by removing parameter names and adding UNUSED_PARAM usage.
58578
58579         * plugins/PluginDebug.cpp:
58580         (WebCore::prettyNameForNPPVariable):
58581         * plugins/npapi.cpp:
58582         (NPN_MemFlush):
58583         (NPN_RequestRead):
58584         (NPN_GetJavaPeer):
58585
58586 2012-10-03  Adam Barth  <abarth@webkit.org>
58587
58588         Measure the usage of WebSQLDatabase
58589         https://bugs.webkit.org/show_bug.cgi?id=98330
58590
58591         Reviewed by Ojan Vafai.
58592
58593         WebKit is the only engine that implements WebSQLDatabase. This patch
58594         causes us to measure its usage so we can see how quickly web sites move
58595         to IndexedDB.
58596
58597         * Modules/webdatabase/DOMWindowWebDatabase.idl:
58598         * page/FeatureObserver.h:
58599
58600 2012-10-03  Arnaud Renevier  <a.renevier@sisa.samsung.com>
58601
58602         [soup] WebKit crashes when doing a http request
58603         https://bugs.webkit.org/show_bug.cgi?id=98055
58604
58605         Reviewed by Martin Robinson.
58606
58607         On i386, (d->m_firstRequest.timeoutInterval() * 1000) results in 0 if
58608         timeoutInterval() is INT_MAX. So, set default timeout to 0 to avoid
58609         calling soup_add_timeout with a 0 value.
58610
58611         Also, if resource handle is deleted before "request-started" signal is
58612         emitted, soupMessage handle points to a deleted object, and a crash
58613         occurs. So, reset soupMessage handle data in
58614         cleanupSoupRequestOperation so it won't happen anymore.
58615
58616         Lastly, if timeout occurs before request is completed, handle is
58617         deleted, and crash occurs in sendRequestCallback due to an early
58618         destroyed handle. To avoid that, call handle->cancel in
58619         requestTimeoutCallback. There is no need to call
58620         cleanupSoupRequestOperation anymore since handle->cancel will trigger
58621         sendRequestCallback, and as handle is deleted,
58622         cleanupSoupRequestOperation will be called automatically.
58623
58624         No new tests yet, tests will be added with the patch in bug 74802.
58625
58626         * platform/network/ResourceRequestBase.cpp:
58627         (WebCore):
58628         * platform/network/soup/ResourceHandleSoup.cpp:
58629         (WebCore::cleanupSoupRequestOperation):
58630         (WebCore::ResourceHandle::platformSetDefersLoading):
58631         (WebCore::requestTimeoutCallback):
58632
58633 2012-10-03  Adam Barth  <abarth@webkit.org>
58634
58635         Remove support for ENABLE(LEGACY_WEBKIT_BLOB_BUILDER)
58636         https://bugs.webkit.org/show_bug.cgi?id=98301
58637
58638         Reviewed by Eric Seidel.
58639
58640         According to anonymous usage statistics, the APIs guarded by
58641         ENABLE(LEGACY_WEBKIT_BLOB_BUILDER) are used on approximately 0.006% of
58642         web pages. Given that this feature is only enabled in GTK and Chromium,
58643         it seems likely that we should remove it.
58644
58645         * CMakeLists.txt:
58646         * DerivedSources.make:
58647         * DerivedSources.pri:
58648         * GNUmakefile.features.am:
58649         * GNUmakefile.list.am:
58650         * WebCore.gypi:
58651         * WebCore.xcodeproj/project.pbxproj:
58652         * fileapi/WebKitBlobBuilder.idl: Removed.
58653         * page/DOMWindow.idl:
58654
58655 2012-10-03  Beth Dakin  <bdakin@apple.com>
58656
58657         https://bugs.webkit.org/show_bug.cgi?id=98313
58658         ScrollingStateNode should keep a Vector of children instead of child 
58659         pointers
58660
58661         Reviewed by Simon Fraser.
58662
58663         This patch re-names ScrollingStateNode::cloneNode() to 
58664         ScrollingStateNode::cloneAndResetNode(). The new function resets the 
58665         change properties of the current node after cloning it, and it also 
58666         takes care of cloning children, which the old function did not do.
58667
58668         m_firstChild and m_nextSibling are gone. Use the m_children Vector 
58669         instead.
58670         * page/scrolling/ScrollingStateNode.cpp:
58671         (WebCore::ScrollingStateNode::cloneAndResetChildNodes):
58672         (WebCore::ScrollingStateNode::appendChild):
58673         * page/scrolling/ScrollingStateNode.h:
58674         (ScrollingStateNode):
58675         (WebCore::ScrollingStateNode::parent):
58676         (WebCore::ScrollingStateNode::setParent):
58677
58678         Reset the change properties and clone children in cloneAndResetNode()
58679         * page/scrolling/ScrollingStateScrollingNode.cpp:
58680         (WebCore::ScrollingStateScrollingNode::cloneAndResetNode):
58681         * page/scrolling/ScrollingStateScrollingNode.h:
58682
58683         Yay, this function can be vastly simplified now that we don't have 
58684         those messy child and sibling pointers.
58685         * page/scrolling/ScrollingStateTree.cpp:
58686         (WebCore::ScrollingStateTree::commit):
58687
58688 2012-10-03  Ojan Vafai  <ojan@chromium.org>
58689
58690         Replace uses of -webkit-box-sizing with box-sizing
58691         https://bugs.webkit.org/show_bug.cgi?id=98312
58692
58693         Reviewed by Tony Chang.
58694
58695         No need to use the prefixed version when the unprefixed works the same.
58696         No new tests since there's no change in behavior..
58697
58698         * css/html.css:
58699
58700 2012-10-03  Joshua Bell  <jsbell@chromium.org>
58701
58702         IndexedDB: Don't do full commit for empty transactions
58703         https://bugs.webkit.org/show_bug.cgi?id=89239
58704
58705         Reviewed by Tony Chang.
58706
58707         Don't bother creating a leveldb write batch if there's nothing in the transaction
58708         to commit. Note that a read-only transaction may still have index cleanup so may
58709         not be an empty transaction.
58710
58711         This cuts the Lookup2 benchmark in http://reyesr.github.com/html5-storage-benchmark/
58712         from 70s to 2s.
58713
58714         Covered by existing tests, e.g. storage/indexeddb/transaction-basics.html
58715
58716         * platform/leveldb/LevelDBTransaction.cpp:
58717         (WebCore::LevelDBTransaction::commit):
58718
58719 2012-10-03  Adam Klein  <adamk@chromium.org>
58720
58721         Remove bogus FIXME from Document.idl
58722         https://bugs.webkit.org/show_bug.cgi?id=98302
58723
58724         Reviewed by Adam Barth.
58725
58726         The FIXME claimed that document.body throwing an exception was not
58727         specced, but in fact it is:
58728         http://www.whatwg.org/specs/web-apps/current-work/multipage/dom.html#dom-document-body
58729
58730         * dom/Document.idl:
58731
58732 2012-10-03  Joshua Bell  <jsbell@chromium.org>
58733
58734         IndexedDB: Memory leak when deleting object stores with indexes
58735         https://bugs.webkit.org/show_bug.cgi?id=98292
58736
58737         Reviewed by Tony Chang.
58738
58739         Reference cycles between IDBObjectStore and IDBIndex instances are explicitly
58740         broken when the transaction completes (and the spec allows traversal to fail).
58741         Deleted stores need to have the reference cycle broken too.
58742
58743         Caught by running valgrind over: storage/indexeddb/keypath-basics.html
58744
58745         * Modules/indexeddb/IDBTransaction.cpp:
58746         (WebCore::IDBTransaction::objectStoreDeleted): Add store to set.
58747         (WebCore::IDBTransaction::dispatchEvent): Notify stores in set.
58748         * Modules/indexeddb/IDBTransaction.h: Add set of deleted stores.
58749
58750 2012-10-03  Adam Barth  <abarth@webkit.org>
58751
58752         CSSNamespace.h is empty and should be deleted
58753         https://bugs.webkit.org/show_bug.cgi?id=98304
58754
58755         Reviewed by Eric Seidel.
58756
58757         There's no reason to have this file in the repository.
58758
58759         * GNUmakefile.list.am:
58760         * WebCore.gypi:
58761         * WebCore.vcproj/WebCore.vcproj:
58762         * WebCore.xcodeproj/project.pbxproj:
58763         * css/CSSNamespace.h: Removed.
58764
58765 2012-10-03  Arnaud Renevier  <a.renevier@sisa.samsung.com>
58766
58767         Build failure with css filters enabled and accelerated compositing disabled
58768         https://bugs.webkit.org/show_bug.cgi?id=95908
58769
58770         Reviewed by Tony Chang.
58771
58772         Do not try to setBackingNeedsRepaint when building without accelerated
58773         compositing.
58774
58775         Also, allow painting with filter (paintsWithFilters returns true if
58776         renderer has filter) when accelerated compositing is not enabled.
58777
58778         No functional change, so no new tests.
58779
58780         * rendering/RenderLayer.cpp:
58781         (WebCore::RenderLayer::styleChanged):
58782
58783 2012-10-03  Emil A Eklund  <eae@chromium.org>
58784
58785         Round image sizes when zooming
58786         https://bugs.webkit.org/show_bug.cgi?id=98205
58787
58788         Reviewed by Eric Seidel.
58789
58790         We currently floor image sizes when zooming which can result in
58791         images being rendered at one pixel less than the actual size.
58792         This is especially likely to happen for very large images.
58793
58794         Test: fast/sub-pixel/zoomed-image-tiles.html
58795
58796         * loader/cache/CachedImage.cpp:
58797         (WebCore::CachedImage::imageSizeForRenderer):
58798
58799 2012-10-03  Hugo Parente Lima  <hugo.lima@openbossa.org>
58800
58801         [WK2] PageViewportController.cpp is supposed to be a generic WebKit2 file but only works with Qt port.
58802         https://bugs.webkit.org/show_bug.cgi?id=98186
58803
58804         Reviewed by Noam Rosenthal.
58805
58806         Remove the implicit conversion from WebCore::FloatSize to QSize.
58807
58808         * platform/graphics/FloatSize.h:
58809         (FloatSize):
58810
58811 2012-10-03  Levi Weintraub  <leviw@chromium.org>
58812
58813         [Sub-pixel layout] incorrect rendering when painting sub-layers as their own root
58814         https://bugs.webkit.org/show_bug.cgi?id=97484
58815
58816         Reviewed by Eric Seidel.
58817
58818         When in compositing mode, layer painting can be triggered through the backing store. When this
58819         happens, a non-top-level RenderLayer is called to paint as its own root. Normally, we attempt to preserve
58820         the proper sub-pixel accumulation through layers to their children, but since we're not
58821         starting with the top-level layer, we haven't properly accumulated one, and convertToLayerCoords,
58822         another source of correctly getting the sub-pixel offset for a layer, also avoids crawling
58823         past the listed root layer.
58824
58825         When painting a root layer, we're aligned to the surface we're painting to, so we round our
58826         offset to avoid moving objects around.
58827
58828         * rendering/RenderLayer.cpp:
58829         (WebCore::RenderLayer::paintLayerContents):
58830
58831 2012-10-03  Jeff Timanus  <twiz@chromium.org>
58832
58833         [chromium] Expose settings value to conditionally enable pinch-zoom scaling in the Chromium compositor.  The
58834         flag defaults to disabled, so this change should be a no-op for scaling/scrolling behaviour.
58835         https://bugs.webkit.org/show_bug.cgi?id=93292
58836
58837         Reviewed by James Robinson.
58838
58839         Tests:  Existing page-scale layout tests.
58840
58841         * page/Frame.cpp:
58842         (WebCore::Frame::frameScaleFactor):
58843         * page/Settings.cpp:
58844         (WebCore::Settings::Settings):
58845         * page/Settings.h:
58846         (WebCore::Settings::setApplyPageScaleFactorInCompositor):
58847         (WebCore::Settings::applyPageScaleFactorInCompositor):
58848         (Settings):
58849
58850 2012-10-03  Stephen Chenney  <schenney@chromium.org>
58851
58852         Font data is purged while fonts are still using it
58853         https://bugs.webkit.org/show_bug.cgi?id=93640
58854
58855         Reviewed by Eric Seidel.
58856
58857         Move the handling of custom font pruning from Document to FontFallbackList.
58858         The previous inplementation allowed fonts to be removed before all their
58859         clients were done. This change moves handling of custom font purging to the
58860         FontFallbackList class, which is the shared object that is only removed
58861         when all clients of a font are done with it. This fixes a crash in Angry
58862         Birds due to a seamless iframe and some failing tests in fast/frames/seamless.
58863
58864         The specific element that causes problems is:
58865         <iframe id="ingame_frame0" name="ingame_frame0" frameborder="0" seamless="true"
58866           src="http://chrome.angrybirds.com/ingame_graphic.html"
58867           onload="this.style.opacity = 1; parent.adLoaded();" scrolling="no"
58868           style="opacity: 1; -webkit-transition: opacity 1s ease-in-out 0s;
58869           position: absolute; border: 0px; width: 312px; height: 320px; z-index:
58870           300; overflow: hidden; visibility: visible;"></iframe>
58871         The source document uses the same font as the embedding document.
58872
58873         Tests: fast/frames/seamless/seamless-custom-font-pruning-crash.html
58874                fast/frames/seamless/seamless-nested-crash.html
58875
58876         * css/CSSFontFaceSource.cpp:
58877         (WebCore::CSSFontFaceSource::getFontData): Remove code to register the font with the document.
58878         * css/CSSSegmentedFontFace.cpp:
58879         (WebCore::CSSSegmentedFontFace::getFontData): Remove code to register the font with the document.
58880         * dom/Document.cpp:
58881         (WebCore::Document::~Document): Remove code that records and purges custom fonts.
58882         (WebCore):
58883         (WebCore::Document::reportMemoryUsage): Remove reference to non-existent objects.
58884         * dom/Document.h:
58885         (WebCore):
58886         (Document): Remove method declarations for custom font handling.
58887         * platform/graphics/FontFallbackList.h:
58888         (FontFallbackList): Moved some code around and made non-copyable.
58889         (WebCore::FontFallbackList::setGlyphPageZero): Moved.
58890         (WebCore::FontFallbackList::setGlyphPages): Moved.
58891         * platform/graphics/GlyphPageTreeNode.cpp:
58892         (WebCore::GlyphPageTreeNode::pruneFontData): Removed unnecessary null check.
58893         * platform/graphics/SegmentedFontData.cpp:
58894         (WebCore::SegmentedFontData::~SegmentedFontData): Added code to prune the Glyph pages when this is deleted.
58895         * platform/graphics/SimpleFontData.cpp:
58896         (WebCore::SimpleFontData::~SimpleFontData): Added code to prune the Glyph pages when this is deleted.
58897
58898 2012-10-03  Adam Barth  <abarth@webkit.org>
58899
58900         Crash when calling document.open during unload
58901         https://bugs.webkit.org/show_bug.cgi?id=98287
58902
58903         Reviewed by Nate Chapin.
58904
58905         Calling document.open results in us nulling out m_documentLoader. This
58906         code doesn't properly handle that case and crashes.
58907
58908         Test: fast/parser/document-open-in-unload.html
58909
58910         * loader/FrameLoader.cpp:
58911         (WebCore::FrameLoader::commitProvisionalLoad):
58912
58913 2012-10-03  Benjamin Poulain  <bpoulain@apple.com>
58914
58915         Element::computeInheritedLanguage: evaluate the while() condition after fetching the string
58916         https://bugs.webkit.org/show_bug.cgi?id=98220
58917
58918         Reviewed by Andreas Kling.
58919
58920         * dom/Element.cpp:
58921         (WebCore::Element::computeInheritedLanguage):
58922         The condition is never false on the first execution. Move the condition to the
58923         end of the loop for fun and profit.
58924
58925 2012-10-03  Hans Wennborg  <hans@chromium.org>
58926
58927         Speech JavaScript API: Add SpeechRecognition.interimResults attribute
58928         https://bugs.webkit.org/show_bug.cgi?id=98279
58929
58930         Reviewed by Adam Barth.
58931
58932         Add the interimResults attribute and pass it to the embedder. It was
58933         added to the spec draft in
58934         http://dvcs.w3.org/hg/speech-api/rev/d25fea0d029c
58935
58936         Tested in fast/speech/scripted/basics.html
58937
58938         * Modules/speech/SpeechRecognition.cpp:
58939         (WebCore::SpeechRecognition::start):
58940         (WebCore::SpeechRecognition::SpeechRecognition):
58941         * Modules/speech/SpeechRecognition.h:
58942         (WebCore::SpeechRecognition::interimResults):
58943         (WebCore::SpeechRecognition::setInterimResults):
58944         * Modules/speech/SpeechRecognition.idl:
58945         * Modules/speech/SpeechRecognitionClient.h:
58946         (SpeechRecognitionClient):
58947         * Modules/speech/SpeechRecognitionController.h:
58948         (WebCore::SpeechRecognitionController::start):
58949
58950 2012-10-03  Hans Wennborg  <hans@chromium.org>
58951
58952         Speech JavaScript API: Remove resultdeleted event
58953         https://bugs.webkit.org/show_bug.cgi?id=98272
58954
58955         Reviewed by Adam Barth.
58956
58957         Remove the resultdeleted event. This was never used, and was removed
58958         from the spec draft in
58959         http://dvcs.w3.org/hg/speech-api/rev/f9d53ab8b449
58960
58961         The fast/speech/scripted/basics.html test is updated to reflect this.
58962
58963         * Modules/speech/SpeechRecognition.cpp:
58964         * Modules/speech/SpeechRecognition.h:
58965         (SpeechRecognition):
58966         * Modules/speech/SpeechRecognition.idl:
58967         * Modules/speech/SpeechRecognitionEvent.cpp:
58968         * Modules/speech/SpeechRecognitionEvent.h:
58969         (SpeechRecognitionEvent):
58970         * dom/EventNames.h:
58971         (WebCore):
58972
58973 2012-09-16  Mark Hahnenberg  <mhahnenberg@apple.com>
58974
58975         Delayed structure sweep can leak structures without bound
58976         https://bugs.webkit.org/show_bug.cgi?id=96546
58977
58978         Reviewed by Geoffrey Garen.
58979
58980         This patch gets rid of the separate Structure allocator in the MarkedSpace and adds two new destructor-only
58981         allocators. We now have separate allocators for our three types of objects: those objects with no destructors,
58982         those objects with destructors and with immortal structures, and those objects with destructors that don't have 
58983         immortal structures. All of the objects of the third type (destructors without immortal structures) now 
58984         inherit from a new class named JSDestructibleObject (which in turn is a subclass of JSNonFinalObject), which stores 
58985         the ClassInfo for these classes at a fixed offset for safe retrieval during sweeping/destruction.
58986
58987         No new tests.
58988
58989         * ForwardingHeaders/runtime/JSDestructableObject.h: Added.
58990         * bindings/js/JSDOMWrapper.h: Inherits from JSDestructibleObject.
58991         (JSDOMWrapper):
58992         (WebCore::JSDOMWrapper::JSDOMWrapper):
58993         * bindings/scripts/CodeGeneratorJS.pm: Add finalizers to anything that inherits from JSGlobalObject,
58994         e.g. JSDOMWindow and JSWorkerContexts. For those classes we also need to define needsDestruction as true.
58995         (GenerateHeader):
58996         * bridge/objc/objc_runtime.h: Inherit from JSDestructibleObject.
58997         (ObjcFallbackObjectImp):
58998         * bridge/objc/objc_runtime.mm:
58999         (Bindings):
59000         (JSC::Bindings::ObjcFallbackObjectImp::ObjcFallbackObjectImp):
59001         * bridge/runtime_array.cpp: Use a finalizer so that JSArray isn't forced to inherit from JSDestructibleObject.
59002         (JSC):
59003         (JSC::RuntimeArray::destroy):
59004         * bridge/runtime_array.h:
59005         (JSC::RuntimeArray::create):
59006         (JSC):
59007         * bridge/runtime_object.cpp: Inherit from JSDestructibleObject.
59008         (Bindings):
59009         (JSC::Bindings::RuntimeObject::RuntimeObject):
59010         * bridge/runtime_object.h:
59011         (RuntimeObject):
59012
59013 2012-10-02  Anders Carlsson  <andersca@apple.com>
59014
59015         Change most GraphicsLayer::create calls to use the version that takes a GraphicsLayerFactory
59016         https://bugs.webkit.org/show_bug.cgi?id=98217
59017
59018         Reviewed by Andreas Kling.
59019
59020         * WebCore.exp.in:
59021         * rendering/RenderLayerBacking.cpp:
59022         (WebCore::RenderLayerBacking::createGraphicsLayer):
59023         * rendering/RenderLayerCompositor.cpp:
59024         (WebCore::RenderLayerCompositor::updateOverflowControlsLayers):
59025         (WebCore::RenderLayerCompositor::ensureRootLayer):
59026
59027 2012-10-03  Joshua Bell  <jsbell@chromium.org>
59028
59029         IndexedDB: Optimize encodeString/decodeString
59030         https://bugs.webkit.org/show_bug.cgi?id=97794
59031
59032         Reviewed by Tony Chang.
59033
59034         Optimize string encoding/decoding, which showed up as a CPU hot spot during profiling.
59035         The backing store uses big-endian ordering of 16-bit code unit strings, so a memcopy
59036         isn't sufficient, but the code used StringBuilder::append() character-by-character
59037         and custom byte-swapping which was slow.
59038
59039         Ran a test w/ DumpRenderTree (to avoid multiprocess overhead) taking a 10k character string
59040         and putting it 20k times and getting it 20k times. On my test box, mean time before the
59041         patch was 8.2s, mean time after the patch was 4.6s.
59042
59043         Tested by Chromium's webkit_unit_tests --gtest_filter='IDBLevelDBCodingTest.*String*'
59044
59045         * Modules/indexeddb/IDBLevelDBCoding.cpp:
59046         (WebCore::IDBLevelDBCoding::encodeString):
59047         (WebCore::IDBLevelDBCoding::decodeString):
59048
59049 2012-10-03  Keishi Hattori  <keishi@webkit.org>
59050
59051         Implement DataList UI for input type time on chromium
59052         https://bugs.webkit.org/show_bug.cgi?id=98240
59053
59054         Reviewed by Kent Tamura.
59055
59056         This adds datalist UI for input type time. We add the picker indicator to
59057         BaseMultipleFieldsDateAndTimeInputType. We enclose the dateTimeEdit element
59058         and picker indicator inside a new div element so we can position the picker
59059         indicator in the same place as input type=date.
59060
59061         Tests: platform/chromium/fast/forms/time/time-suggestion-picker-appearance-rtl.html
59062                platform/chromium/fast/forms/time/time-suggestion-picker-appearance-with-scroll-bar.html
59063                platform/chromium/fast/forms/time/time-suggestion-picker-appearance.html
59064                platform/chromium/fast/forms/time/time-suggestion-picker-key-operations.html
59065                platform/chromium/fast/forms/time/time-suggestion-picker-mouse-operations.html
59066
59067         * css/html.css:
59068         (input::-webkit-date-and-time-container):
59069         * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
59070         (WebCore::BaseMultipleFieldsDateAndTimeInputType::BaseMultipleFieldsDateAndTimeInputType):
59071         (WebCore::BaseMultipleFieldsDateAndTimeInputType::createShadowSubtree): Creates a picker indicator.
59072         (WebCore::BaseMultipleFieldsDateAndTimeInputType::handleKeydownEvent): Open the picker on Alt+Down.
59073         (WebCore):
59074         (WebCore::BaseMultipleFieldsDateAndTimeInputType::listAttributeTargetChanged): Updates picker visibility.
59075         (WebCore::BaseMultipleFieldsDateAndTimeInputType::updatePickerIndicatorVisibility): In the future, DateInputType can override
59076         this so the picker indicator is always visible.
59077         (WebCore::BaseMultipleFieldsDateAndTimeInputType::hidePickerIndicator):
59078         (WebCore::BaseMultipleFieldsDateAndTimeInputType::showPickerIndicator):
59079         * html/BaseMultipleFieldsDateAndTimeInputType.h:
59080         (WebCore):
59081         (BaseMultipleFieldsDateAndTimeInputType):
59082         * html/shadow/DateTimeFieldElement.cpp:
59083         (WebCore::DateTimeFieldElement::defaultKeyboardEventHandler): Ignore Alt+down because it should trigger the picker to open.
59084         * rendering/RenderThemeChromiumCommon.cpp:
59085         (WebCore::RenderThemeChromiumCommon::supportsDataListUI): Add time to the list.
59086
59087 2012-10-03  Andreas Kling  <kling@webkit.org>
59088
59089         Give CSSValueList backing vector an inline capacity.
59090         <http://webkit.org/b/98266>
59091         <rdar://problem/12421425>
59092
59093         Reviewed by Anders Carlsson.
59094
59095         Set an inline capacity of 4 on the CSSValue vector backing CSSValueList. This avoids an extra heap allocation
59096         in the common case, and reduces total memory use across the board, since the majority of CSSValueLists have
59097         at least 1 item, and the Vector will bump from 0 to 16 capacity on the first append.
59098
59099         394kB progression on Membuster3.
59100
59101         * css/CSSValueList.h:
59102         (CSSValueList):
59103
59104 2012-10-03  Ilya Tikhonovsky  <loislo@chromium.org>
59105
59106         Web Inspector: NMI: instrument NativeImageSkia.
59107         https://bugs.webkit.org/show_bug.cgi?id=96277
59108
59109         Reviewed by Yury Semikhatsky.
59110
59111         * platform/graphics/skia/NativeImageSkia.cpp:
59112         (WebCore::NativeImageSkia::reportMemoryUsage):
59113         (WebCore::reportMemoryUsage):
59114
59115 2012-10-03  Pavel Feldman  <pfeldman@chromium.org>
59116
59117         Web Inspector: remember the last dock option so that user could toggle between dock to bottom and right
59118         https://bugs.webkit.org/show_bug.cgi?id=98255
59119
59120         Reviewed by Vsevolod Vlasov.
59121
59122         - Introduced DockController.js that covers the dock mechanics
59123         - Removed dock orientation from the settings
59124         - Storing the last dock option to present it as default
59125         - Simplified the multi-option status bar button
59126
59127         * WebCore.gypi:
59128         * WebCore.vcproj/WebCore.vcproj:
59129         * inspector/compile-front-end.py:
59130         * inspector/front-end/DockController.js: Added.
59131         (WebInspector.DockController):
59132         (WebInspector.DockController.prototype.get element):
59133         (WebInspector.DockController.prototype.setDocked.set if):
59134         (WebInspector.DockController.prototype.setDocked):
59135         (WebInspector.DockController.prototype.setDockingUnavailable):
59136         (WebInspector.DockController.prototype._updateUI.get states):
59137         (WebInspector.DockController.prototype._updateUI):
59138         (WebInspector.DockController.prototype._decorateButtonForTargetState):
59139         (WebInspector.DockController.prototype._createDockOptions):
59140         (WebInspector.DockController.prototype._toggleDockState):
59141         (WebInspector.DockController.prototype.isCompactMode):
59142         (WebInspector.DockController.prototype.setCompactMode):
59143         * inspector/front-end/InspectorFrontendAPI.js:
59144         (InspectorFrontendAPI.setAttachedWindow):
59145         * inspector/front-end/InspectorFrontendHostStub.js:
59146         (.WebInspector.InspectorFrontendHostStub.prototype.requestAttachWindow):
59147         (.WebInspector.InspectorFrontendHostStub.prototype.requestDetachWindow):
59148         * inspector/front-end/Settings.js:
59149         * inspector/front-end/SettingsScreen.js:
59150         (WebInspector.GenericSettingsTab):
59151         * inspector/front-end/StatusBarButton.js:
59152         (WebInspector.StatusBarButton):
59153         * inspector/front-end/Toolbar.js:
59154         (WebInspector.Toolbar):
59155         (WebInspector.Toolbar.prototype.setCompactMode):
59156         (WebInspector.Toolbar.prototype._toolbarDragStart):
59157         (WebInspector.Toolbar.prototype._toolbarDrag):
59158         * inspector/front-end/WebKit.qrc:
59159         * inspector/front-end/externs.js:
59160         (WebInspector.toggleSearchingForNode):
59161         * inspector/front-end/inspector.css:
59162         (body.undocked.platform-mac-snowleopard #toolbar):
59163         (body.undocked.platform-mac-snowleopard #toolbar-dropdown):
59164         * inspector/front-end/inspector.html:
59165         * inspector/front-end/inspector.js:
59166         (WebInspector._createGlobalStatusBarItems):
59167         (windowLoaded):
59168         (WebInspector.setDockingUnavailable):
59169         * inspector/front-end/inspectorCommon.css:
59170         (body.dock-to-right:not(.undocked)):
59171         (body.dock-to-right.inactive:not(.undocked)):
59172
59173 2012-10-03  Vsevolod Vlasov  <vsevik@chromium.org>
59174
59175         Web Inspector: UISourceCode commitWorkingCopy should not fail when original script had syntax error.
59176         https://bugs.webkit.org/show_bug.cgi?id=97272
59177
59178         Reviewed by Pavel Feldman.
59179
59180         This patch is based on patch by John J. Barton.
59181
59182         * inspector/front-end/JavaScriptSource.js:
59183         (WebInspector.JavaScriptSource.prototype.workingCopyCommitted): added rawLocation null check.
59184
59185 2012-10-03  Alexander Pavlov  <apavlov@chromium.org>
59186
59187         Web Inspector: After "Edit as HTML", any click outside box should stop editing
59188         https://bugs.webkit.org/show_bug.cgi?id=98258
59189
59190         Reviewed by Vsevolod Vlasov.
59191
59192         Make the DOM tree OL span the entire height of its container in the Elements panel to catch mouse events.
59193
59194         * inspector/front-end/elementsPanel.css:
59195         (#elements-content > ol):
59196
59197 2012-10-03  Dongwoo Joshua Im  <dw.im@samsung.com>
59198
59199         [EFL] Skeleton code of File system API.
59200         https://bugs.webkit.org/show_bug.cgi?id=91187
59201
59202         Reviewed by Gyuyoung Kim.
59203
59204         Add skeleton code of File System API on EFL port.
59205         Implementation patches will be created later.
59206
59207         No new tests because this is just skeleton code.
59208
59209         * CMakeLists.txt: Add new files which created by other patches in Modules/filesystem/ directory.
59210         * PlatformEfl.cmake: Add AsyncFileSystemEfl.cpp.
59211         * platform/AsyncFileSystem.cpp:
59212         (WebCore):
59213         * platform/efl/AsyncFileSystemEfl.cpp: Added.
59214         * platform/efl/AsyncFileSystemEfl.h: Added.
59215
59216 2012-10-03  Andreas Kling  <kling@webkit.org>
59217
59218         Shrink ElementRareData by moving bool flags to NodeRareData.
59219         <http://webkit.org/b/98225>
59220
59221         Reviewed by Antti Koivisto.
59222
59223         Move all bool flags from ElementRareData to the bitfield in its base class NodeRareData.
59224         This shrinks ElementRareData by 8 bytes (on 64-bit) and saves a whopping 58kB on Membuster3.
59225         Also removed some double raredata hash lookups.
59226
59227         * dom/Element.cpp:
59228         (WebCore::Element::detach):
59229         (WebCore::Element::recalcStyle):
59230         (WebCore::Element::ensureShadow):
59231         (WebCore::Element::setStyleAffectedByEmpty):
59232         (WebCore::Element::styleAffectedByEmpty):
59233         (WebCore::Element::setIsInCanvasSubtree):
59234         (WebCore::Element::isInCanvasSubtree):
59235         (WebCore::Element::containsFullScreenElement):
59236         (WebCore::Element::setContainsFullScreenElement):
59237         * dom/ElementRareData.h:
59238         (ElementRareData):
59239         (WebCore::ElementRareData::ElementRareData):
59240         * dom/NodeRareData.h:
59241         (WebCore::NodeRareData::styleAffectedByEmpty):
59242         (WebCore::NodeRareData::setStyleAffectedByEmpty):
59243         (WebCore::NodeRareData::isInCanvasSubtree):
59244         (WebCore::NodeRareData::setIsInCanvasSubtree):
59245         (NodeRareData):
59246         (WebCore::NodeRareData::containsFullScreenElement):
59247         (WebCore::NodeRareData::setContainsFullScreenElement):
59248
59249 2012-10-03  Jussi Kukkonen  <jussi.kukkonen@intel.com>
59250
59251         getComputedStyle perspective-origin is based on the wrong bounding box
59252         https://bugs.webkit.org/show_bug.cgi?id=98027
59253
59254         Reviewed by Simon Fraser.
59255
59256         perspective-origin for ComputedStyleDeclaration is currently calculated using the
59257         wrong bounding box (sizingBox() which ends up as the contentbox).
59258
59259         Start using borderbox for ComputedStyleDeclaration perspective-origin, similar to
59260         what transform-origin already does.
59261
59262         Test: fast/css/getComputedStyle/getComputedStyle-origin-percentage.html
59263
59264         * css/CSSComputedStyleDeclaration.cpp:
59265         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
59266
59267 2012-10-03  Patrick Gansterer  <paroga@webkit.org>
59268
59269         Build fix for WinCE after r130160.
59270
59271         * platform/graphics/FontFastPath.cpp:
59272         (WebCore::Font::glyphDataAndPageForCharacter):
59273
59274 2012-10-03  Tommy Widenflycht  <tommyw@google.com>
59275
59276         MediaStream API: RTCPeerConnection should send down its handler via the FrameLoaderClient directly after creation.
59277         https://bugs.webkit.org/show_bug.cgi?id=98149
59278
59279         Reviewed by Adam Barth.
59280
59281         The chromium implementation needs to know which Frame created a PeerConnection so
59282         that the right housekeeping can take place correctly.
59283
59284         Not testable in DRT, but have verified the change manually and with our pyautotests.
59285
59286         * Modules/mediastream/RTCPeerConnection.cpp:
59287         (WebCore::RTCPeerConnection::RTCPeerConnection):
59288         * loader/FrameLoaderClient.h:
59289         (WebCore):
59290         (FrameLoaderClient):
59291         (WebCore::FrameLoaderClient::dispatchWillStartUsingPeerConnectionHandler):
59292         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp:
59293         (WebCore::RTCPeerConnectionHandlerChromium::toWebRTCPeerConnectionHandler):
59294         (WebCore):
59295         (WebCore::RTCPeerConnectionHandlerChromium::RTCPeerConnectionHandlerChromium):
59296         (WebCore::RTCPeerConnectionHandlerChromium::initialize):
59297         * platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h:
59298         (RTCPeerConnectionHandlerChromium):
59299
59300 2012-10-03  Eugene Klyuchnikov  <eustas.bug@gmail.com>
59301
59302         Web Inspector: Profiles: taking heap snapshot causes error message in console.
59303         https://bugs.webkit.org/show_bug.cgi?id=97890
59304
59305         Reviewed by Yury Semikhatsky.
59306
59307         Actual problem is that proxy loader is closed twice.
59308
59309         "_snapshotReceived" should never try to close receiver,
59310         because it is a callback fired by close.
59311
59312         Also minor glitches fixed:
59313          - taking snapshot shows "Loading..." status first,
59314         and then "Saving xxx%";
59315          - after all chunks are sent "Parsing" status is set and
59316         then is replaced with "Saving 100%";
59317          - removed dead code in proxy;
59318          - proxy was ignoring callback parameter;
59319          - "Loading %d\%" is not localized.
59320
59321         * English.lproj/localizedStrings.js: Added missing "Loading %d%" string.
59322         * inspector/front-end/HeapSnapshotProxy.js: Removed dead code.
59323         (WebInspector.HeapSnapshotLoaderProxy):
59324         (WebInspector.HeapSnapshotLoaderProxy.prototype.write): Make this method
59325         interface-conformant.
59326         * inspector/front-end/HeapSnapshotView.js:
59327         (WebInspector.HeapProfileHeader): Fixed update-status and
59328         finish-transfer logic.
59329
59330 2012-10-03  Jochen Eisinger  <jochen@chromium.org>
59331
59332         Make sure that user gestures can't be consumed twice
59333         https://bugs.webkit.org/show_bug.cgi?id=97483
59334
59335         Reviewed by Adam Barth.
59336
59337         Instead of a simple counter, use a ref counted token to track how many
59338         user gestures happened and where consumed. When creating a timer that
59339         is supposed to forward the user gesture, take a reference to this token
59340         and reinstantiate the UserGestureIndicator with that token when the
59341         timer is triggered.
59342
59343         Tests: platform/chromium/fast/events/popup-forwarded-gesture-blocked.html
59344                platform/chromium/fast/events/popup-forwarded-gesture.html
59345
59346         * dom/UserGestureIndicator.cpp:
59347         (WebCore):
59348         (WebCore::UserGestureIndicator::UserGestureIndicator):
59349         (WebCore::UserGestureIndicator::~UserGestureIndicator):
59350         (WebCore::UserGestureIndicator::processingUserGesture):
59351         (WebCore::UserGestureIndicator::consumeUserGesture):
59352         (WebCore::UserGestureIndicator::currentToken):
59353         * dom/UserGestureIndicator.h:
59354         (Token):
59355         (WebCore::UserGestureIndicator::Token::~Token):
59356         (UserGestureIndicator):
59357         * page/DOMTimer.cpp:
59358         (WebCore::DOMTimer::DOMTimer):
59359         (WebCore::DOMTimer::fired):
59360         * page/DOMTimer.h:
59361         (DOMTimer):
59362
59363 2012-10-03  Dominic Mazzoni  <dmazzoni@google.com>
59364
59365         AX: Heap-use-after-free when deleting a ContainerNode with an AX object
59366         https://bugs.webkit.org/show_bug.cgi?id=98073
59367
59368         Reviewed by Hajime Morita.
59369
59370         Calls axObjectCache()->remove(this) in ~ContainerNode so that the AX tree
59371         doesn't try to access the container node while walking up the parent chain
59372         from one of the container node's children.
59373
59374         Test: accessibility/container-node-delete-causes-crash.html
59375
59376         * dom/ContainerNode.cpp:
59377         (WebCore::ContainerNode::~ContainerNode):
59378         * dom/Node.cpp:
59379         (WebCore::Node::~Node):
59380         * dom/Node.h:
59381         (WebCore::Node::document):
59382         (WebCore::Node::documentInternal):
59383
59384 2012-10-03  Vsevolod Vlasov  <vsevik@chromium.org>
59385
59386         Web Inspector: SourceURL should be taken from debugger agent when possible.
59387         https://bugs.webkit.org/show_bug.cgi?id=98239
59388
59389         Reviewed by Yury Semikhatsky.
59390
59391         Removed a check that sourceURL coming from js engine is the same as the one parsed by debugger agent.
59392         Alwys use the one from debugger agent now.
59393
59394         * inspector/InspectorDebuggerAgent.cpp:
59395         (WebCore::InspectorDebuggerAgent::didParseSource):
59396
59397 2012-10-03  Ilya Tikhonovsky  <loislo@chromium.org>
59398
59399         Unreviewed. Touch FrameView.cpp file for fixing mac bot compilation.
59400
59401         * page/FrameView.cpp:
59402         (WebCore):
59403
59404 2012-10-02  Ilya Tikhonovsky  <loislo@chromium.org>
59405
59406         Web Inspector: "Load profile..." context menu item has to be shown only for left column with the list of profiles.
59407         https://bugs.webkit.org/show_bug.cgi?id=98163
59408
59409         Reviewed by Yury Semikhatsky.
59410
59411         The text was changed to "Load Heap Snapshot..."
59412         Also I changed "Save profile..." to "Save Heap Snapshot..." because other profiles don't support Save/Load operations yet.
59413         The Load context menu item will appear only when the user clicked in sidebar the tree empty space or a profile.
59414
59415         * English.lproj/localizedStrings.js:
59416         * inspector/front-end/ProfilesPanel.js:
59417         (WebInspector.ProfilesPanel.prototype._handleContextMenuEvent):
59418         (WebInspector.ProfileSidebarTreeElement.prototype.handleContextMenuEvent):
59419
59420 2012-10-03  Harald Alvestrand  <hta@google.com>
59421
59422         Add data passing to the GetStats interface of RTCPeerConnection
59423         https://bugs.webkit.org/show_bug.cgi?id=98003
59424
59425         Reviewed by Adam Barth.
59426
59427         Added an RTCStatsResponseBase interface to platform, and let the
59428         RTCStatsRequestImpl class produce an implementation of it that's returned
59429         to WebCore.
59430
59431         Tested by extension of the RTCPeerConnection-stats.html test.
59432
59433         * Modules/mediastream/RTCStatsElement.cpp:
59434         (WebCore::RTCStatsElement::addStatistic):
59435         (WebCore):
59436         * Modules/mediastream/RTCStatsElement.h:
59437         (RTCStatsElement):
59438         * Modules/mediastream/RTCStatsReport.cpp:
59439         (WebCore):
59440         (WebCore::RTCStatsReport::addElement):
59441         (WebCore::RTCStatsReport::addStatistic):
59442         * Modules/mediastream/RTCStatsReport.h:
59443         (RTCStatsReport):
59444         * Modules/mediastream/RTCStatsRequestImpl.cpp:
59445         (WebCore::RTCStatsRequestImpl::createResponse):
59446         (WebCore):
59447         (WebCore::RTCStatsRequestImpl::requestSucceeded):
59448         * Modules/mediastream/RTCStatsRequestImpl.h:
59449         (RTCStatsRequestImpl):
59450         * Modules/mediastream/RTCStatsResponse.cpp:
59451         (WebCore::RTCStatsResponse::create):
59452         (WebCore::RTCStatsResponse::addReport):
59453         (WebCore):
59454         (WebCore::RTCStatsResponse::addElement):
59455         (WebCore::RTCStatsResponse::addStatistic):
59456         * Modules/mediastream/RTCStatsResponse.h:
59457         (RTCStatsResponse):
59458         * WebCore.gypi:
59459         * platform/chromium/support/WebRTCStatsRequest.cpp:
59460         (WebKit::WebRTCStatsRequest::response):
59461         (WebKit):
59462         (WebKit::WebRTCStatsRequest::requestSucceeded):
59463         * platform/chromium/support/WebRTCStatsResponse.cpp: Added.
59464         (WebKit):
59465         (WebKit::WebRTCStatsResponse::WebRTCStatsResponse):
59466         (WebKit::WebRTCStatsResponse::assign):
59467         (WebKit::WebRTCStatsResponse::reset):
59468         (WebKit::WebRTCStatsResponse::operator WTF::PassRefPtr<WebCore::RTCStatsResponseBase>):
59469         (WebKit::WebRTCStatsResponse::addReport):
59470         (WebKit::WebRTCStatsResponse::addElement):
59471         (WebKit::WebRTCStatsResponse::addStatistic):
59472         * platform/mediastream/RTCStatsRequest.h:
59473         (WebCore):
59474         (RTCStatsRequest):
59475         * platform/mediastream/RTCStatsResponseBase.h: Added.
59476         (WebCore):
59477         (RTCStatsResponseBase):
59478         (WebCore::RTCStatsResponseBase::~RTCStatsResponseBase):
59479
59480 2012-10-02  Carlos Garcia Campos  <cgarcia@igalia.com>
59481
59482         [GTK] Add API to get the web view that initiated a custom URI request to WebKit2 GTK+
59483         https://bugs.webkit.org/show_bug.cgi?id=97895
59484
59485         Reviewed by Martin Robinson.
59486
59487         * platform/network/NetworkingContext.h:
59488         (NetworkingContext): Add initiatingPageID().
59489         * platform/network/ResourceHandle.h:
59490         (ResourceHandle): Add static method
59491         getSoupRequestInitiaingPageID().
59492         * platform/network/ResourceHandleInternal.h:
59493         (ResourceHandleInternal): Add initiatingPageID().
59494         * platform/network/soup/ResourceHandleSoup.cpp:
59495         (WebCore::ResourceHandleInternal::initiatingPageID): Get the
59496         initiating page ID of the resource handle networking context.
59497         (WebCore::setSoupRequestInitiaingPageID): Helper function to
59498         attach a page ID to a SoupRequest.
59499         (WebCore::startHTTPRequest): Call setSoupRequestInitiaingPageID()
59500         to attch the initiating page ID to the SoupRequest.
59501         (WebCore::startNonHTTPRequest): Ditto.
59502         (WebCore::ResourceHandle::getSoupRequestInitiaingPageID): Static
59503         method to get the page ID attached to a SoupRequest.
59504
59505 2012-10-03  Kent Tamura  <tkent@chromium.org>
59506
59507         Introduce DateComponents::minimumYear and maximumYear
59508         https://bugs.webkit.org/show_bug.cgi?id=98230
59509
59510         Reviewed by Kentaro Hara.
59511
59512         Share same difinitions in DateComponents.cpp and DateTimeFieldElements.cpp.
59513
59514         No new tests. This doesn't change any bahevior.
59515
59516         * platform/DateComponents.h:
59517         (WebCore::DateComponents::minimumYear): Moved from DateComponents.cpp.
59518         (WebCore::DateComponents::maximumYear): ditto.
59519         * platform/DateComponents.cpp:
59520         (WebCore): Move out static minimumYear and maximumYear.
59521         (WebCore::DateComponents::parseYear): Use DateCompnents::minimumYear and/or maximumYear.
59522         (WebCore::withinHTMLDateLimits): ditto.
59523         (WebCore::DateComponents::parseWeek): ditto.
59524         (WebCore::DateComponents::setMonthsSinceEpoch): ditto.
59525         (WebCore::DateComponents::setMillisecondsSinceEpochForWeek): ditto.
59526
59527         * html/shadow/DateTimeFieldElements.cpp:
59528         (WebCore): Remove minimumYear and maximumYear.
59529         (WebCore::DateTimeYearFieldElement::DateTimeYearFieldElement):
59530         Use DateComponents::minimumYear and maximumYear.
59531
59532
59533 2012-10-02  Arko Saha  <arko@motorola.com>
59534
59535         Microdata: itemprop names must not override builtin properties.
59536         https://bugs.webkit.org/show_bug.cgi?id=98025
59537
59538         Reviewed by Kentaro Hara.
59539
59540         We should look in the prototype for functions before assuming it as
59541         an item's name. Return false if the prototype of the object has a
59542         property (function) with propertyName.
59543         Named properties Spec: http://dev.w3.org/2006/webapi/WebIDL/#idl-named-properties
59544         Named property visibility algorithm:
59545         http://dev.w3.org/2006/webapi/WebIDL/#indexed-and-named-properties
59546         ...
59547         7. If the result of calling the [[HasProperty]] internal method on
59548         prototype with property name P is true, then return false.
59549         ...
59550         Also [OverrideBuiltins] is not declared for any of the properties,
59551         hence no overriding is allowed in this case.
59552
59553         Test: fast/dom/MicroData/itemprop-names-override-builtin-properties.html
59554
59555         * bindings/scripts/CodeGeneratorJS.pm:
59556         (GenerateGetOwnPropertySlotBody):
59557         (GenerateGetOwnPropertyDescriptorBody):
59558
59559 2012-10-02  Keishi Hattori  <keishi@webkit.org>
59560
59561         REGRESSION (r129738): Suggestion picker label is placed in the wrong location
59562         https://bugs.webkit.org/show_bug.cgi?id=98094
59563
59564         Reviewed by Kent Tamura.
59565
59566         We needed to reverse padding-left/right when rtl.
59567
59568         No new tests. Covered by date-suggestion-picker-appearance.html.
59569
59570         * Resources/pagepopups/suggestionPicker.css:
59571         (.suggestion-list-entry .label):
59572         (.rtl .suggestion-list-entry .label):
59573
59574 2012-10-02  Yury Semikhatsky  <yurys@chromium.org>
59575
59576         Provide memory instrumentation for HashCountedSet
59577         https://bugs.webkit.org/show_bug.cgi?id=98138
59578
59579         Reviewed by Pavel Feldman.
59580
59581         Replaced addHashCountedSet calls with addMember that now automatically
59582         detects HashCountedSet and calls appropriate routine.
59583
59584         * css/CSSImageGeneratorValue.cpp:
59585         (WebCore::CSSImageGeneratorValue::reportBaseClassMemoryUsage):
59586         * loader/cache/CachedResource.cpp:
59587
59588 2012-10-02  Nandor Huszka  <hnandor@inf.u-szeged.hu>
59589
59590         Buildfix after r130235.
59591
59592         Reviewed by Csaba Osztrogonác.
59593
59594         systemAllowsMultisamplingOnATICards was deleted from GraphicsContext3D,
59595         but function body remained in GraphicsContext3DOpenGLES. Delete method body.
59596
59597         * platform/graphics/opengl/GraphicsContext3DOpenGLES.cpp:
59598
59599 2012-10-02  Kent Tamura  <tkent@chromium.org>
59600
59601         Fix assertion failures on Chromium Debug bots for datetime/datetime-local input types.
59602
59603         * html/shadow/DateTimeFieldElements.cpp:
59604         If a placeholder stirng is empty, use a sequence of "-".
59605         (WebCore::DateTimeDayFieldElement::create):
59606         (WebCore::DateTimeMonthFieldElement::create):
59607         (WebCore::DateTimeYearFieldElement::create):
59608
59609 2012-10-02  MORITA Hajime  <morrita@google.com>
59610
59611         https://bugs.webkit.org/show_bug.cgi?id=98134
59612         [Refactoring] StyleResolver::matchScopedAuthorRules() could be simpler.
59613
59614         Reviewed by Dimitri Glazkov.
59615
59616         matchScopedAuthorRules() did have some optimization which only
59617         makes sense for heavily nested shadow tree. However, we don't see
59618         such type of usage of Shadow DOM and this looks premature
59619         optimization. This change unified its triple for loop into one,
59620         which makes the code much simpler.
59621
59622         No new tests. Covered by existing tests.
59623
59624         * css/StyleResolver.cpp:
59625         (WebCore::StyleResolver::matchScopedAuthorRules):
59626
59627 2012-10-02  Kent Tamura  <tkent@chromium.org>
59628
59629         Introduce Localizer::dateTimeFormatWithSecond and dateTimeFormatWithoutSecond
59630         https://bugs.webkit.org/show_bug.cgi?id=98229
59631
59632         Reviewed by Kentaro Hara.
59633
59634         Unify identical code in DateTimeInputType and DateTimeLocalInputType as
59635         Localizer member functions.
59636         They still have some common code. We'll address it later.
59637
59638         No new tests. This doesn't change any behavior.
59639
59640         * platform/text/Localizer.h:
59641         (Localizer): Add dateTimeFormatWithSecond and dateTimeFormatWithoutSecond.
59642         * platform/text/Localizer.cpp:
59643         (WebCore::Localizer::dateTimeFormatWithSecond):
59644         Implemented. Just concatenating dateFormat, a space, and timeFormat.
59645         (WebCore::Localizer::dateTimeFormatWithoutSecond):
59646         Implemented. Just concatenating dateFormat, a space, and shortTimeFormat.
59647
59648         * html/DateTimeInputType.cpp:
59649         (WebCore::DateTimeInputType::setupLayoutParameters):
59650         Use dateTimeFormatWithSecond and dateTimeFormatWithoutSecond.
59651         * html/DateTimeLocalInputType.cpp:
59652         (WebCore::DateTimeLocalInputType::setupLayoutParameters): ditto.
59653
59654 2012-10-03  Kent Tamura  <tkent@chromium.org>
59655
59656         Refactoring: DateTimeEditBuilder had better hold LayoutParameters
59657         https://bugs.webkit.org/show_bug.cgi?id=98228
59658
59659         Reviewed by Kentaro Hara.
59660
59661         Stop copying multiple members of LayoutParameters in DateTimeEditBuilder
59662         constructor. This change improves code size and runtime cost.
59663
59664         No new tests. This doesn't change user-visible behavior.
59665
59666         * html/shadow/DateTimeEditElement.cpp:
59667         (DateTimeEditBuilder): Add a comment about lifetime of objects.
59668         (WebCore::DateTimeEditBuilder::stepRange):
59669         Added. A helper to access m_parameters.stepRange.
59670         (WebCore::DateTimeEditBuilder::DateTimeEditBuilder):
59671         Remove m_stepRange, m_localizer, m_placeholderFor* members.
59672         Add m_parameters.
59673         (WebCore::DateTimeEditBuilder::needMillisecondField):
59674         Use stepRange() instead of m_stepRange.
59675         (WebCore::DateTimeEditBuilder::visitField):
59676         Use m_parameters.placeholderFor*.
59677         (WebCore::DateTimeEditBuilder::shouldMillisecondFieldReadOnly):
59678         Use stepRange() instead of m_stepRange.
59679         (WebCore::DateTimeEditBuilder::shouldMinuteFieldReadOnly): ditto.
59680         (WebCore::DateTimeEditBuilder::shouldSecondFieldReadOnly): ditto.
59681
59682 2012-10-02  Kent Tamura  <tkent@chromium.org>
59683
59684         Implement LocaleICU::dateFormat
59685         https://bugs.webkit.org/show_bug.cgi?id=98118
59686
59687         Reviewed by Hajime Morita.
59688
59689         http://trac.webkit.org/changeset/130127 introduced
59690         Localizer::dateFormat, and this is its implementation for LocaleICU
59691         classs. The code is going to be used when
59692         ENABLE_INPUT_MULTIPLE_FIELDS_UI is enabled.
59693
59694         No new tests. The function is not used yet.
59695
59696         * platform/text/LocaleICU.cpp:
59697         (WebCore::LocaleICU::dateFormat):
59698         Implemented. Note that m_shortDateFormat is a UDateFormat object, which
59699         knows various format information.
59700         * platform/text/LocaleICU.h:
59701         (LocaleICU): Add m_dateFormat to cache the format string.
59702
59703 2012-10-02  Kent Tamura  <tkent@chromium.org>
59704
59705         [Mac][Chromium-Mac] Implement LocaleMac::dateFormat
59706         https://bugs.webkit.org/show_bug.cgi?id=98116
59707
59708         Reviewed by Hajime Morita.
59709
59710         http://trac.webkit.org/changeset/130127 introduced
59711         Localizer::dateFormat, and this is its implementation for LocaleICU
59712         classs. The code is going to be used when
59713         ENABLE_INPUT_MULTIPLE_FIELDS_UI is enabled.
59714
59715         No new tests. The function is not used yet.
59716
59717         * platform/text/mac/LocaleMac.h:
59718         (LocaleMac): Declare m_dateFormat.
59719         * platform/text/mac/LocaleMac.mm:
59720         (WebCore::LocaleMac::dateFormat): Implemented.
59721
59722 2012-10-02  Kent Tamura  <tkent@chromium.org>
59723
59724         [Chromium-Win] Implement LocaleWin::dateFormat
59725         https://bugs.webkit.org/show_bug.cgi?id=98117
59726
59727         Reviewed by Kentaro Hara.
59728
59729         http://trac.webkit.org/changeset/130127 introduced
59730         Localizer::dateFormat, and this is its implementation for LocaleICU
59731         classs. The code is going to be used when
59732         ENABLE_INPUT_MULTIPLE_FIELDS_UI is enabled.
59733
59734         Tests: Added a new test to WebKit/chromium/tests/LocaleWinTest.cpp.
59735
59736         * platform/text/LocaleWin.cpp:
59737         (WebCore::parseDateFormat):
59738         Fix a continuous apostrophes parsing bug; "abc''''def" produced "abc'''def"
59739         (WebCore::appendAsLDMLLiteral):
59740         A helper function to make a literal string for LDML.
59741         (WebCore::convertWindowsDateFormatToLDML):
59742         Creates an LDML format from a parsed date format tokens.
59743         (WebCore::LocaleWin::dateFormat):
59744         Implemented. This uses convertWindowsDateFormatToLDML.
59745         (WebCore::LocaleWin::dateFormat):
59746         Added for testing. The source windows format is specified as a function
59747         argument.
59748         * platform/text/LocaleWin.h:
59749         (LocaleWin): Declare m_dateFormat and dateFormat().
59750
59751 2012-10-02  Ian Vollick  <vollick@chromium.org>
59752
59753         [chromium] Fix spelling of isNVIDIA override in Extensions3DChromium
59754         https://bugs.webkit.org/show_bug.cgi?id=98219
59755
59756         Reviewed by Dean Jackson.
59757
59758         The override in Extensions3dChromium should have been spelled isNVIDIA, not isNVidia.
59759
59760         No new tests. No change in functionality.
59761
59762         * platform/graphics/chromium/Extensions3DChromium.h:
59763         (WebCore::Extensions3DChromium::isNVIDIA):
59764
59765 2012-10-02  Anders Carlsson  <andersca@apple.com>
59766
59767         Try to fix the Snow Leopard build.
59768
59769         * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp:
59770
59771 2012-10-02  Joshua Bell  <jsbell@chromium.org>
59772
59773         Add htons/htonl definitions and implementations
59774         https://bugs.webkit.org/show_bug.cgi?id=98054
59775
59776         Reviewed by Darin Adler.
59777
59778         Update users of htons and friends to use new wtf/ByteOrder.h header.
59779
59780         No new tests - just refactoring.
59781
59782         * platform/graphics/WOFFFileFormat.cpp:
59783         * platform/graphics/chromium/VDMXParser.cpp:
59784
59785 == Rolled over to ChangeLog-2012-10-02 ==