Defer ScriptExecutionContext::Task's in Document when page loading is deferred.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-12-07  Yong Li  <yoli@rim.com>
2
3         Defer ScriptExecutionContext::Task's in Document when page loading is deferred.
4         Schedule them with timer when page loading is resumed. The tasks will be performed
5         in the original order. This fixes the problem that database callbacks could be missed
6         when page loading was deferred.
7         https://bugs.webkit.org/show_bug.cgi?id=49401
8  
9
10         Reviewed by Darin Adler.
11
12         Manual test added: ManualTests/database-callback-deferred.html. 
13
14         * dom/Document.cpp:
15         (WebCore::Document::Document):
16         (WebCore::Document::didReceiveTask):
17         (WebCore::Document::postTask):
18         (WebCore::Document::pendingTasksTimerFired):
19         (WebCore::Document::suspendScheduledTasks):
20         (WebCore::Document::resumeScheduledTasks):
21         * dom/Document.h:
22         * page/PageGroupLoadDeferrer.cpp:
23         (WebCore::PageGroupLoadDeferrer::PageGroupLoadDeferrer):
24         (WebCore::PageGroupLoadDeferrer::~PageGroupLoadDeferrer):
25
26 2011-12-07  Andreas Kling  <kling@webkit.org>
27
28         RenderObject::style(): Inline early-return condition.
29         <http://webkit.org/b/74019>
30
31         Reviewed by Anders Carlsson.
32
33         style() was very hot (6.1%) when scrolling around on youtube.com,
34         and 100% of the calls were taking the early return path.
35
36         Inlined the !isRenderFlowThread() check and renamed the function to
37         styleSlowCase().
38
39         * rendering/RenderObject.cpp:
40         (WebCore::RenderObject::styleSlowCase):
41         * rendering/RenderObject.h:
42         (WebCore::RenderObject::style):
43
44 2011-12-07  Adam Klein  <adamk@chromium.org>
45
46         Use HashMap<Node*, OwnPtr<...>> in ChildListMutationScope
47         https://bugs.webkit.org/show_bug.cgi?id=73964
48
49         Reviewed by Ryosuke Niwa.
50
51         No new tests, refactoring only.
52
53         * dom/ChildListMutationScope.cpp:
54         (WebCore::ChildListMutationAccumulator::MutationAccumulationRouter::childAdded):
55         (WebCore::ChildListMutationAccumulator::MutationAccumulationRouter::willRemoveChild):
56         (WebCore::ChildListMutationAccumulator::MutationAccumulationRouter::incrementScopingLevel):
57         (WebCore::ChildListMutationAccumulator::MutationAccumulationRouter::decrementScopingLevel):
58
59 2011-12-07  Andreas Kling  <kling@webkit.org>
60
61         RenderLayer::updateZOrderLists(): Inline early-return condition.
62         <http://webkit.org/b/74013>
63
64         Reviewed by Anders Carlsson.
65
66         updateZOrderLists() was hot (1.2%) when scrolling around on youtube.com,
67         and 85% of the calls were taking the early return path.
68
69         Inlined the two checks for the early return and renamed the function
70         to updateZOrderListsSlowCase(). Also reversed their order to avoid the
71         virtual call (RenderObject::isRenderView()) if possible.
72
73         * rendering/RenderLayer.cpp:
74         (WebCore::RenderLayer::updateZOrderListsSlowCase):
75         * rendering/RenderLayer.h:
76         (WebCore::RenderLayer::updateZOrderLists):
77
78 2011-12-07  Sheriff Bot  <webkit.review.bot@gmail.com>
79
80         Unreviewed, rolling out r102244.
81         http://trac.webkit.org/changeset/102244
82         https://bugs.webkit.org/show_bug.cgi?id=74016
83
84         caused debug test timeouts (Requested by simonjam on #webkit).
85
86         * platform/graphics/skia/ImageBufferSkia.cpp:
87         (WebCore::putImageData):
88         (WebCore::ImageBuffer::putUnmultipliedImageData):
89         (WebCore::ImageBuffer::putPremultipliedImageData):
90
91 2011-12-07  Adam Klein  <adamk@chromium.org>
92
93         Layout Test inspector/debugger/dom-breakpoints.html fails on chromium linux debug with ENABLE(MUTATION_OBSERVERS)
94         https://bugs.webkit.org/show_bug.cgi?id=73919
95
96         Reviewed by Ojan Vafai.
97
98         Use StyleAttributeMutationScope to manage DOM breakpoints for style property changes.
99
100         Instead of calling InspectorInstrumentation::didInvalidateStyleAttr()
101         directly in setNeedsStyleRecalc, set a bool in the current
102         StyleAttributeMutationScope, and delay the call until the scope's
103         counter runs down to zero. This keeps the inspector JS from re-entering
104         CSSMutableStyleDeclaration until all StyleAttributeMutationScope work is done.
105
106         Also fix a small bug in StyleAttributeMutationScope, where
107         s_shouldDeliver wasn't getting reset properly to false.
108
109         * css/CSSMutableStyleDeclaration.cpp:
110         (WebCore::CSSMutableStyleDeclaration::setNeedsStyleRecalc):
111
112 2011-12-07  Ken Buchanan <kenrb@chromium.org>
113
114         Crash from multicol spans with layers
115         https://bugs.webkit.org/show_bug.cgi?id=68030
116
117         Reviewed by David Hyatt.
118
119         The layer tree diverges from the render tree when a span is being split
120         between columns. This patch causes the layer tree to be updated when necessary.
121
122         * rendering/RenderBlock.cpp:
123         (WebCore::RenderBlock::splitFlow)
124         (WebCore::RenderBlock::splitBlocks)
125
126 2011-12-07  Alexey Proskuryakov  <ap@apple.com>
127
128         Handling of !important in inline style sets is broken
129         https://bugs.webkit.org/show_bug.cgi?id=73941
130
131         Reviewed by Dave Hyatt.
132
133         This behavior was introduced in bug 8223 to match IE and Firefox. But it doesn't appear that we're matching
134         any browser today, and CSSOM spec agrees with them.
135
136         * WebCore.exp.in: Don't export CSSStyleDeclaration::setProperty(), no one is using it.
137
138         * bindings/js/JSCSSStyleDeclarationCustom.cpp: (WebCore::JSCSSStyleDeclaration::putDelegate): Use regular
139         setProperty(), not the incorrect version that's being removed. Properties set via IDL attributes are never
140         important.
141
142         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp: (WebCore::V8CSSStyleDeclaration::namedPropertySetter):
143         Made the same fix for v8. Why did v8 bindings authors copy/paste the code?!
144
145         * css/CSSStyleDeclaration.cpp:
146         * css/CSSStyleDeclaration.h:
147         Removed a version of setProperty() that attempted to parse the value and extract !important from it.
148
149         * html/ImageDocument.cpp:
150         (WebCore::ImageDocument::resizeImageToFit):
151         (WebCore::ImageDocument::restoreImageSize):
152         (WebCore::ImageDocument::windowSizeChanged):
153         * page/DragController.cpp:
154         (WebCore::DragController::concludeEditDrag):
155         We never needed to use this version of setProperty() here, it was just unnecessarily slower.
156
157 2011-12-07  Xianzhu Wang  <wangxianzhu@chromium.org>
158
159         In FontCacheAndroid.cpp should keep the pointer valid returned from CString::data()
160         https://bugs.webkit.org/show_bug.cgi?id=73849
161
162         The changed code has been covered by many existing layout tests.
163
164         Reviewed by Adam Barth.
165
166         * platform/graphics/chromium/FontCacheAndroid.cpp:
167         (WebCore::FontCache::createFontPlatformData):
168
169 2011-12-07  Xiaomei Ji  <xji@chromium.org>
170
171         Turn on move caret by word visually for Windows platform.
172         https://bugs.webkit.org/show_bug.cgi?id=59652
173
174         Reviewed by Ryosuke Niwa.
175
176         We already support (arrow key) moving cursor by character in visual order.
177         This patch implements (ctrl/alt-arrow) moving cursor by word in visual order (in Windows).
178         It matches Firefox's default behavior.
179
180         Without this patch, ctrl(alt for mac)-arrow key or
181         selection.modify("move", "left"/"right", "word") moves cursor by word in logical order. 
182
183         IE implements moving cursor by logical order for both arrow key and ctrl-arrow key.
184         Firefox implements moving cursor by visual order for both operations.
185         From Chromium bug report, native speakers would like moving cursor by visual order since it
186         is more intuitive.
187
188         The patch is only enabled for Windows (by EditingBehavior) because current implementation
189         matches Windows' native behavior.
190         For exmaple, if the logical text is "abc def hij", the cursor positions are
191         "|abc |def |hij|" no matter pressing ctrl-left-arrow or ctrl-right-arrow.
192
193         Mac and Linux's native behavior is slightly different. In which, when pressing
194         ctrl-left-arrow, the cursor positions are "|abc |def |hij|". When pressing ctrl-right-arrow,
195         the cursor positions are "|abc| def| hij|". We will implement it next.
196
197         Test: editing/selection/move-left-right-by-word-mac.html
198
199         * editing/EditingBehavior.h:
200         (WebCore::EditingBehavior::shouldMoveLeftRightByWordInVisualOrder):
201         * editing/FrameSelection.cpp: Remove experimental enum WebKitVisualWordGranularity.
202         (WebCore::FrameSelection::modifyExtendingRight):
203         (WebCore::FrameSelection::modifyExtendingForward):
204         (WebCore::FrameSelection::modifyMovingRight):
205         (WebCore::FrameSelection::modifyMovingForward):
206         (WebCore::FrameSelection::modifyExtendingLeft):
207         (WebCore::FrameSelection::modifyExtendingBackward):
208         (WebCore::FrameSelection::modifyMovingLeft):
209         (WebCore::FrameSelection::modifyMovingBackward):
210         * editing/TextGranularity.h: Remove experimental enum WebKitVisualWordGranularity.
211         * editing/VisibleSelection.cpp: Remove experimental enum WebKitVisualWordGranularity.
212         (WebCore::VisibleSelection::setStartAndEndFromBaseAndExtentRespectingGranularity):
213         * page/DOMSelection.cpp: Remove experimental experimental flag -webkit-visual-word.
214         (WebCore::DOMSelection::modify):
215
216 2011-12-07  Jonathan Backer  <backer@chromium.org>
217
218         [chromium] Plumb damage from WebExternalTextureLayer and WebPluginContainer to CCDamageTracker
219         https://bugs.webkit.org/show_bug.cgi?id=73485
220
221         Reviewed by Darin Fisher.
222
223         * platform/graphics/chromium/PluginLayerChromium.cpp:
224         (WebCore::PluginLayerChromium::updateCompositorResources):
225         (WebCore::PluginLayerChromium::invalidateRect):
226         * platform/graphics/chromium/PluginLayerChromium.h:
227
228 2011-12-07  Mary Wu  <mary.wu@torchmobile.com.cn>
229
230         Upstream 5 files into WebCore/platform/blackberry
231         https://bugs.webkit.org/show_bug.cgi?id=73632
232
233         Reviewed by Rob Buis.
234
235         Initial upstream, no new tests.
236
237         * PlatformBlackBerry.cmake: Remove two empty files from build list.
238         * platform/blackberry/PopupMenuBlackBerry.cpp: Added.
239         (WebCore::PopupMenuBlackBerry::PopupMenuBlackBerry):
240         (WebCore::PopupMenuBlackBerry::~PopupMenuBlackBerry):
241         (WebCore::PopupMenuBlackBerry::show):
242         (WebCore::PopupMenuBlackBerry::hide):
243         (WebCore::PopupMenuBlackBerry::updateFromElement):
244         (WebCore::PopupMenuBlackBerry::disconnectClient):
245         * platform/blackberry/PopupMenuBlackBerry.h: Added.
246         (WebCore::PopupMenuBlackBerry::client):
247         * platform/blackberry/ScrollbarThemeBlackBerry.cpp: Added.
248         (WebCore::ScrollbarTheme::nativeTheme):
249         * platform/blackberry/SearchPopupMenuBlackBerry.cpp: Added.
250         (WebCore::SearchPopupMenuBlackBerry::SearchPopupMenuBlackBerry):
251         (WebCore::SearchPopupMenuBlackBerry::popupMenu):
252         (WebCore::SearchPopupMenuBlackBerry::enabled):
253         (WebCore::SearchPopupMenuBlackBerry::saveRecentSearches):
254         (WebCore::SearchPopupMenuBlackBerry::loadRecentSearches):
255         * platform/blackberry/SearchPopupMenuBlackBerry.h: Added.
256
257 2011-12-07  Dan Bernstein  <mitz@apple.com>
258
259         Fixed the definition of BUTTON_CELL_DRAW_WITH_FRAME_DRAWS_FOCUS_RING from r102246.
260
261         * platform/mac/ThemeMac.mm: Added parentheses.
262
263 2011-12-07  Dan Bernstein  <mitz@apple.com>
264
265         <rdar://problem/10542095> Focus rings are not drawn around push buttons, radio buttons and checkboxes
266
267         Reviewed by Darin Adler.
268
269         Instead of relying on -setShowsFirstResponder: to make -drawWithFrame:inView: draw the focus
270         ring, use -drawFocusRingMaskWithFrame:inView:.
271
272         * platform/mac/ThemeMac.mm:
273         (-[NSCell _web_drawFocusRingWithFrame:inView:]): Added. Sets up the focus ring style and a
274         transparency layer, then uses -drawFocusRingMaskWithFrame:inView: to draw the focus ring.
275         (WebCore::updateStates): Eliminated calls to get and set showsFirstResponder.
276         (WebCore::paintCheckbox): Changed to use -_web_drawFocusRingWithFrame:inView:.
277         (WebCore::paintRadio): Ditto.
278         (WebCore::paintButton): Ditto.
279
280 2011-12-07  Brian Salomon  <bsalomon@google.com>
281
282         [CHROMIUM/SKIA] Handle put[Un/Pre]multipliedImageData conversions in Skia rather than ImageBuffer
283         https://bugs.webkit.org/show_bug.cgi?id=73953
284
285         Reviewed by Stephen White.
286
287         Tested by existing canvas2d layout tests.
288
289         * platform/graphics/skia/ImageBufferSkia.cpp:
290         (WebCore::putImageData):
291         (WebCore::ImageBuffer::putUnmultipliedImageData):
292         (WebCore::ImageBuffer::putPremultipliedImageData):
293
294 2011-12-07  Andreas Kling  <kling@webkit.org>
295
296         Micro-optimize ScrollView::visibleContentRect().
297         <http://webkit.org/b/74001>
298
299         Reviewed by Anders Carlsson.
300
301         Reorder the scrollbar exclusion code to minimize the number of virtual calls
302         to ScrollableArea::verticalScrollbar(), ScrollableArea::horizontalScrollbar()
303         and Scrollbar::isOverlayScrollbar().
304
305         * platform/ScrollView.cpp:
306         (WebCore::ScrollView::visibleContentRect):
307
308 2011-12-07  Andreas Kling  <kling@webkit.org>
309
310         ApplyPropertyBorderImage: Remove unneeded template argument for mapNinePieceImage().
311         <http://webkit.org/b/73998>
312
313         Reviewed by Antti Koivisto.
314
315         Have ApplyPropertyBorderImage call mapNinePieceImage() directly now that it's
316         public (instead of passing it as a template argument.)
317
318         * css/CSSStyleApplyProperty.cpp:
319         (WebCore::ApplyPropertyBorderImage::applyValue):
320         (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):
321
322 2011-12-07  Jessie Berlin  <jberlin@apple.com>
323
324         Mac build fix after r102235.
325
326         * WebCore.exp.in:
327
328 2011-11-30  Simon Hausmann  <simon.hausmann@nokia.com>
329
330         [Qt] V8 debug build fixes.
331
332         Reviewed by Tor Arne Vestbø.
333
334         * Target.pri: Add missing files to the build.
335         * loader/SubresourceLoader.cpp: Add missing CString.h header file inclusion,
336         that is implicitly included with Chromium builds and only needed in ASSERTS
337         in debug builds.
338         * loader/cache/CachedResource.cpp: Ditto.
339         * page/FrameTree.cpp: Ditto.
340         * platform/graphics/MediaPlayer.cpp: Ditto.
341
342 2011-11-30  Simon Hausmann  <simon.hausmann@nokia.com>
343
344         [Qt] V8 build fixes.
345
346         Reviewed by Tor Arne Vestbø.
347
348         * Target.pri: Don't load(javascriptcore) if we're building with v8.
349
350 2011-12-07  Mary Wu  <mary.wu@torchmobile.com.cn>
351
352         Change function name InitializeLoggingChannelsIfNecessary to follow coding style guideline
353         https://bugs.webkit.org/show_bug.cgi?id=73986
354
355         Reviewed by Kenneth Rohde Christiansen.
356
357         Just function name change, no new tests.
358
359         * platform/Logging.h:
360         * platform/efl/LoggingEfl.cpp:
361         (WebCore::initializeLoggingChannelsIfNecessary):
362         * platform/gtk/LoggingGtk.cpp:
363         (WebCore::initializeLoggingChannelsIfNecessary):
364         * platform/mac/LoggingMac.mm:
365         (WebCore::initializeLoggingChannelsIfNecessary):
366         * platform/qt/LoggingQt.cpp:
367         (WebCore::initializeLoggingChannelsIfNecessary):
368         * platform/win/LoggingWin.cpp:
369         (WebCore::initializeLoggingChannelsIfNecessary):
370         * platform/wx/LoggingWx.cpp:
371         (WebCore::initializeLoggingChannelsIfNecessary):
372
373 2011-12-07  Mihnea Ovidenie  <mihnea@adobe.com>
374
375         [CSSRegions]Add support for background-color in region styling
376         https://bugs.webkit.org/show_bug.cgi?id=71488
377
378         Reviewed by David Hyatt.
379
380         Tests: fast/regions/region-style-block-background-color.html
381                fast/regions/region-style-block-background-color2.html
382                fast/regions/region-style-image-background-color.html
383                fast/regions/region-style-inline-background-color.html
384
385         * WebCore.exp.in:
386         * css/CSSStyleSelector.cpp:
387         (WebCore::RuleData::regionStyleRule):
388         (WebCore::CSSStyleSelector::CSSStyleSelector):
389         (WebCore::CSSStyleSelector::addMatchedDeclaration):
390         (WebCore::CSSStyleSelector::matchRules):
391         (WebCore::CSSStyleSelector::matchAllRules):
392         (WebCore::CSSStyleSelector::initForRegionStyling):
393         (WebCore::CSSStyleSelector::styleForElement):
394         (WebCore::CSSStyleSelector::pseudoStyleForElement):
395         (WebCore::RuleData::RuleData):
396         (WebCore::RuleSet::RuleSet):
397         (WebCore::RuleSet::addToRuleSet):
398         (WebCore::CSSStyleSelector::applyDeclarations):
399         (WebCore::isValidRegionStyleProperty):
400         (WebCore::CSSStyleSelector::applyProperty):
401         * css/CSSStyleSelector.h:
402         (WebCore::CSSStyleSelector::setRegionForStyling):
403         (WebCore::CSSStyleSelector::regionForStyling):
404         (WebCore::CSSStyleSelector::applyPropertyToRegionStyle):
405         * rendering/RenderFlowThread.cpp:
406         (WebCore::RenderFlowThread::clearRenderRegionRangeMap):
407         (WebCore::RenderFlowThread::~RenderFlowThread):
408         (WebCore::RenderFlowThread::layout):
409         (WebCore::RenderFlowThread::clearRenderObjectCustomStyle):
410         (WebCore::RenderFlowThread::setRegionRangeForBox):
411         * rendering/RenderFlowThread.h:
412         * rendering/RenderLayer.cpp:
413         (WebCore::CurrentRenderRegionMaintainer::CurrentRenderRegionMaintainer):
414         (WebCore::CurrentRenderRegionMaintainer::~CurrentRenderRegionMaintainer):
415         (WebCore::RenderLayer::paint):
416         (WebCore::RenderLayer::hitTest):
417         * rendering/RenderObject.cpp:
418         (WebCore::RenderObject::style):
419         * rendering/RenderObject.h:
420         (WebCore::RenderObject::canHaveRegionStyle):
421         * rendering/RenderObjectChildList.cpp:
422         (WebCore::RenderObjectChildList::removeChildNode):
423         * rendering/RenderRegion.cpp:
424         (WebCore::RenderRegion::layout):
425         (WebCore::RenderRegion::renderObjectRegionStyle):
426         (WebCore::RenderRegion::computeStyleInRegion):
427         (WebCore::RenderRegion::clearObjectStyleInRegion):
428         * rendering/RenderRegion.h:
429         * rendering/RenderView.cpp:
430         (WebCore::RenderView::RenderView):
431         * rendering/RenderView.h:
432         (WebCore::RenderView::currentRenderRegion):
433         (WebCore::RenderView::setCurrentRenderRegion):
434
435 2011-12-01  Vsevolod Vlasov  <vsevik@chromium.org>
436
437         Web Inspector: Extract default call stack creation and check for front-end from console.
438         https://bugs.webkit.org/show_bug.cgi?id=73566
439
440         Reviewed by Yury Semikhatsky.
441
442         * bindings/js/ScriptCallStackFactory.cpp:
443         (WebCore::createScriptCallStack):
444         * bindings/js/ScriptCallStackFactory.h:
445         * bindings/scripts/CodeGeneratorJS.pm:
446         (GenerateParametersCheck):
447         * bindings/scripts/CodeGeneratorV8.pm:
448         (GenerateFunctionCallback):
449         * bindings/scripts/test/JS/JSTestObj.cpp:
450         (WebCore::jsTestObjPrototypeFunctionCustomArgsAndException):
451         * bindings/scripts/test/V8/V8TestObj.cpp:
452         (WebCore::TestObjInternal::customArgsAndExceptionCallback):
453         * bindings/v8/ScriptCallStackFactory.cpp:
454         (WebCore::createScriptCallStack):
455         * bindings/v8/ScriptCallStackFactory.h:
456         * inspector/InspectorInstrumentation.cpp:
457         (WebCore::InspectorInstrumentation::hasFrontendForScriptContext):
458         * inspector/InspectorInstrumentation.h:
459         (WebCore::InspectorInstrumentation::hasFrontendForScriptContext):
460         * inspector/WorkerInspectorController.h:
461         (WebCore::WorkerInspectorController::hasFrontend):
462         * page/Console.cpp:
463         * page/Console.h:
464
465 2011-12-07  Shinya Kawanaka  <shinyak@google.com>
466
467         Internals should have a method to reutrn the max sequence number of spellcheck reqeust.
468         https://bugs.webkit.org/show_bug.cgi?id=73511
469
470         Reviewed by Hajime Morita.
471
472         Internal state of SpellChecker should be able to be exposed for testing SpellChecker.
473         This patch will enable us to know asynchronous spellcheck has finished or not.
474
475         Test: editing/spelling/spellcheck-sequencenum.html
476
477         * editing/SpellChecker.cpp:
478         (WebCore::SpellChecker::SpellChecker):
479         (WebCore::SpellChecker::createRequest):
480         (WebCore::SpellChecker::didCheck):
481         * editing/SpellChecker.h:
482         (WebCore::SpellChecker::lastRequestSequence):
483           Interface to take SpellCheck sequence numbers.
484         (WebCore::SpellChecker::lastProcessedSequence): ditto.
485         * testing/Internals.cpp:
486         (WebCore::spellchecker):
487         (WebCore::Internals::lastSpellCheckRequestSequence):
488         (WebCore::Internals::lastSpellCheckProcessedSequence):
489         * testing/Internals.h:
490         * testing/Internals.idl:
491
492 2011-12-07  Ryosuke Niwa  <rniwa@webkit.org>
493
494         TypingCommand duplicates code to obtain the last typing command
495         https://bugs.webkit.org/show_bug.cgi?id=73984
496
497         Reviewed by Kent Tamura.
498
499         Extracted lastTypingCommandIfStillOpenForTyping out of isOpenForMoreTypingCommand
500         and a bunch of TypingCommand static member functions.
501
502         Also made more member functions of TypingCommand private.
503
504         * editing/Editor.cpp:
505         (WebCore::Editor::setComposition):
506         * editing/FrameSelection.cpp:
507         (WebCore::FrameSelection::setSelection):
508         * editing/TypingCommand.cpp:
509         (WebCore::TypingCommand::deleteSelection):
510         (WebCore::TypingCommand::deleteKeyPressed):
511         (WebCore::TypingCommand::forwardDeleteKeyPressed):
512         (WebCore::TypingCommand::insertText):
513         (WebCore::TypingCommand::insertLineBreak):
514         (WebCore::TypingCommand::insertParagraphSeparatorInQuotedContent):
515         (WebCore::TypingCommand::insertParagraphSeparator):
516         (WebCore::TypingCommand::lastTypingCommandIfStillOpenForTyping):
517         (WebCore::TypingCommand::closeTyping):
518         * editing/TypingCommand.h:
519         (WebCore::TypingCommand::isOpenForMoreTyping):
520         (WebCore::TypingCommand::closeTyping):
521
522 2011-12-06  Mary Wu  <mary.wu@torchmobile.com.cn>
523
524         upstream BlackBerry porting of KURL/Logging
525         https://bugs.webkit.org/show_bug.cgi?id=73524
526
527         Reviewed by Antonio Gomes.
528
529         * platform/blackberry/KURLBlackBerry.cpp: Added.
530         (WebCore::KURL::fileSystemPath):
531         * platform/blackberry/LoggingBlackBerry.cpp: Added.
532         (WebCore::initializeWithUserDefault):
533         (WebCore::InitializeLoggingChannelsIfNecessary):
534
535 2011-12-06  Leo Yang  <leo.yang@torchmobile.com.cn>
536
537         [BlackBerry] Remove redundant files in PlatformBlackBerry.cmake
538         https://bugs.webkit.org/show_bug.cgi?id=73976
539
540         Reviewed by Antonio Gomes.
541
542         The listing of the following files in PlatformBlackBerry.cmake are redundant. They should be removed.
543         platform/network/blackberry/MultipartResponseDelegate.cpp
544         platform/network/blackberry/NetworkManager.cpp
545         platform/network/blackberry/NetworkStateNotifierBlackBerry.cpp
546         platform/network/blackberry/ResourceErrorBlackBerry.cpp
547         platform/network/blackberry/ResourceRequestBlackBerry.cpp
548
549         * PlatformBlackBerry.cmake:
550
551 2011-12-06  Shinya Kawanaka  <shinyak@google.com>
552
553         Refactoring: Editor::markAllMisspellingsAndBadGrammarInRanges should be refactored.
554         https://bugs.webkit.org/show_bug.cgi?id=73628
555
556         Reviewed by Hajime Morita.
557
558         Extracted a code for adding markers and replacing misspelled words from WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges.
559
560         No new tests. covered by existing tests.
561
562         * editing/Editor.cpp:
563         (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges):
564           Extracted a code for adding markers and replacing missplled words, and moved to markAndReplaceFor.
565         (WebCore::Editor::markAndReplaceFor):
566         * editing/Editor.h:
567
568 2011-12-06  Julien Chaffraix  <jchaffraix@webkit.org>
569
570         Avoid calling calculateRects in RenderLayer::paintLayer when the rectangles are not needed
571         https://bugs.webkit.org/show_bug.cgi?id=73754
572
573         Reviewed by Simon Fraser.
574
575         Performance change, no change in behavior.
576
577         RenderLayer::paintLayer can easily be called a million time when scrolling on a big table with
578         td { overflow: hidden; }. We would spend a lot of time recomputing the rectangles that we never
579         unused for painting as our layer was not self-painting (clipping layer only) and we did not paint
580         some overlay scrollbars.
581
582         * rendering/RenderLayer.cpp:
583         (WebCore::RenderLayer::paintLayer):
584         Simplified and moved the shouldPaint logic earlier in the function. Now the branches
585         are checking the same boolean which makes the logic more obvious. A consequence of
586         filling shouldPaint earlier is that we call |calculateRects| only if there is a chance
587         the rectangles will used. Also cached the result of isSelfPaintingLayer() in a local
588         variable (isSelfPaintingLayer() is fairly expensive due to several virtual calls).
589
590         * rendering/RenderLayerBacking.cpp:
591         (WebCore::RenderLayerBacking::paintIntoLayer):
592         For coherency, applied the same optimizations here too: added an early return instead
593         of conditionaly call |calculateRects| as we don't have to restore any clip.
594
595 2011-12-06  Benjamin Poulain  <benjamin@webkit.org>
596
597         Simplify KURL's checkEncodedString()
598         https://bugs.webkit.org/show_bug.cgi?id=73890
599
600         Reviewed by Andreas Kling.
601
602         The Macro UNUSED_PARAM is not supposed to be used for this case,
603         use ASSERT_UNUSED instead.
604
605         * platform/KURL.cpp:
606         (WebCore::checkEncodedString):
607
608 2011-12-06  Ryosuke Niwa  <rniwa@webkit.org>
609
610         The code to create a NodeListsNodeData is duplicated everywhere
611         https://bugs.webkit.org/show_bug.cgi?id=73961
612
613         Reviewed by Darin Adler.
614
615         Extracted the logic to create NodeListsNodeData as NodeRareData::ensureNodeLists.
616
617         * dom/Document.cpp:
618         (WebCore::Document::getItems):
619         * dom/Node.cpp:
620         (WebCore::Node::childNodes):
621         (WebCore::Node::registerDynamicNodeList):
622         (WebCore::Node::getElementsByTagName):
623         (WebCore::Node::getElementsByTagNameNS):
624         (WebCore::Node::getElementsByName):
625         (WebCore::Node::getElementsByClassName):
626         * dom/NodeRareData.h:
627         (WebCore::NodeRareData::ensureNodeLists):
628         * html/HTMLFormControlElement.cpp:
629         (WebCore::HTMLFormControlElement::labels):
630
631 2011-12-06  Leo Yang  <leo.yang@torchmobile.com.cn>
632
633         Upstream about: feature in WebKit/blackberry/WebCoreSupport/
634         https://bugs.webkit.org/show_bug.cgi?id=73612
635
636         Reviewed by Antonio Gomes.
637
638         * PlatformBlackBerry.cmake: Move platform/network/blackberry/AboutData.{h, cpp}
639                                     to WebKit/blackberry/WebCoreSupport
640
641 2011-12-06  Benjamin Poulain  <bpoulain@apple.com>
642
643         WebKit Mac does not build without CONTEXT MENU
644         https://bugs.webkit.org/show_bug.cgi?id=73962
645
646         Reviewed by Pavel Feldman.
647
648         In the patch r100903, the symbols were exported under ENABLE(CONTEXT_MENUS)
649         because the feature is triggered from the menus.
650
651         The implementation has no dependency on the context menu but is necessary to build
652         when the inspector is enabled.
653         This patch moves the exported symbols from ENABLE(CONTEXT_MENUS) to ENABLE(INSPECTOR).
654
655         * WebCore.exp.in:
656
657 2011-12-06  Adrienne Walker  <enne@google.com>
658
659         [chromium] setNeedsCommit on non-composited host layers should trigger commit
660         https://bugs.webkit.org/show_bug.cgi?id=73711
661
662         Reviewed by James Robinson.
663
664         Pipe non-composited content host syncs to setNeedsCommit.
665
666         Since now the NonCompositedContentHost generates setNeedsCommit, don't
667         call it unnecessarily, e.g. calling setBackgroundColor to the same
668         color each frame should not retrigger more commits.
669
670         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
671         (WebCore::GraphicsLayerChromium::setAnchorPoint):
672         (WebCore::GraphicsLayerChromium::setTransform):
673         (WebCore::GraphicsLayerChromium::setChildrenTransform):
674         (WebCore::GraphicsLayerChromium::setMasksToBounds):
675         (WebCore::GraphicsLayerChromium::setBackgroundColor):
676         (WebCore::GraphicsLayerChromium::clearBackgroundColor):
677         (WebCore::GraphicsLayerChromium::setContentsOpaque):
678         (WebCore::GraphicsLayerChromium::setBackfaceVisibility):
679         (WebCore::GraphicsLayerChromium::setOpacity):
680         * platform/graphics/chromium/LayerChromium.cpp:
681         (WebCore::LayerChromium::setNeedsCommit):
682         (WebCore::LayerChromium::setAnchorPoint):
683         (WebCore::LayerChromium::setAnchorPointZ):
684         (WebCore::LayerChromium::setBackgroundColor):
685         (WebCore::LayerChromium::setMasksToBounds):
686         (WebCore::LayerChromium::setMaskLayer):
687         (WebCore::LayerChromium::setOpacity):
688         (WebCore::LayerChromium::setOpaque):
689         (WebCore::LayerChromium::setPosition):
690         (WebCore::LayerChromium::setSublayerTransform):
691         (WebCore::LayerChromium::setTransform):
692         (WebCore::LayerChromium::setScrollPosition):
693         (WebCore::LayerChromium::setScrollable):
694         (WebCore::LayerChromium::setDoubleSided):
695         * platform/graphics/chromium/LayerChromium.h:
696         (WebCore::LayerChromium::setReplicaLayer):
697         * platform/graphics/chromium/NonCompositedContentHost.cpp:
698         (WebCore::NonCompositedContentHost::notifySyncRequired):
699         * platform/graphics/chromium/NonCompositedContentHost.h:
700
701 2011-12-06  Kenichi Ishibashi  <bashi@chromium.org>
702
703         [Chromium] unknown characters symbol on \n in complex script text (RTL and LTR)
704         https://bugs.webkit.org/show_bug.cgi?id=73806
705
706         Reviewed by Tony Chang.
707
708         Sets fMergeNeutralItems to 1 instead of merging script items based on their tags.
709
710         Tests: platform/chromium/fast/text/international/chromium-complex-text-non-printable-expected.html
711                platform/chromium/fast/text/international/chromium-complex-text-non-printable.html
712
713         * platform/graphics/chromium/UniscribeHelper.cpp:
714         (WebCore::UniscribeHelper::fillRuns): Removed a block which merges script items.
715
716 2011-12-06  Luke Macpherson   <macpherson@chromium.org>
717
718         Implement remaining border-image and webkit-maskbox-image properties in CSSStyleApplyProperty.
719         https://bugs.webkit.org/show_bug.cgi?id=73391
720
721         Reviewed by Hajime Morita.
722
723         No new tests / refacoring only.
724
725         * css/CSSStyleApplyProperty.cpp:
726         (WebCore::ApplyPropertyBorderImageModifier::getValue):
727         (WebCore::ApplyPropertyBorderImageModifier::setValue):
728         (WebCore::ApplyPropertyBorderImageModifier::applyInheritValue):
729         (WebCore::ApplyPropertyBorderImageModifier::applyInitialValue):
730         (WebCore::ApplyPropertyBorderImageModifier::applyValue):
731         (WebCore::ApplyPropertyBorderImageModifier::createHandler):
732         (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):
733         * css/CSSStyleSelector.cpp:
734         (WebCore::CSSStyleSelector::applyProperty):
735         * css/CSSStyleSelector.h:
736
737 2011-12-06  Pavel Feldman  <pfeldman@google.com>
738
739         Web Inspector: introduce a memory agent stub.
740         https://bugs.webkit.org/show_bug.cgi?id=73930
741
742         Reviewed by Timothy Hatcher.
743
744         We'd like to experiment with the memory stats and hence need a
745         nice home for that. Adding this undocumented agent / domain for now.
746
747         * CMakeLists.txt:
748         * GNUmakefile.list.am:
749         * Target.pri:
750         * WebCore.gypi:
751         * WebCore.vcproj/WebCore.vcproj:
752         * WebCore.xcodeproj/project.pbxproj:
753         * bindings/js/ScriptProfiler.h:
754         (WebCore::ScriptProfiler::nodeCount):
755         * bindings/v8/ScriptProfiler.cpp:
756         (WebCore::ScriptProfiler::nodeCount):
757         * bindings/v8/ScriptProfiler.h:
758         * inspector/Inspector.json:
759         * inspector/InspectorController.cpp:
760         (WebCore::InspectorController::InspectorController):
761         * inspector/InspectorMemoryAgent.cpp: Added.
762         (WebCore::InspectorMemoryAgent::~InspectorMemoryAgent):
763         (WebCore::InspectorMemoryAgent::getNodeCounter):
764         (WebCore::InspectorMemoryAgent::InspectorMemoryAgent):
765         * inspector/InspectorMemoryAgent.h: Added.
766         (WebCore::InspectorMemoryAgent::create):
767
768 2011-12-06  Julien Chaffraix  <jchaffraix@webkit.org>
769
770         Unreviewed build fix after 102183.
771
772         * rendering/style/RenderStyle.h:
773         (WebCore::InheritedFlags::initialGridTrackValue):
774         Use DEFINE_STATIC_LOCAL to avoid having an exit-time destructor.
775
776 2011-12-06  Julien Chaffraix  <jchaffraix@webkit.org>
777
778         Inline RenderObject::view()
779         https://bugs.webkit.org/show_bug.cgi?id=73733
780
781         Reviewed by Darin Adler.
782
783         Micro-performance optimization, no change in behavior.
784
785         RenderObject::view() is super hot and is taking ~4-5% of the time in some
786         benchmarks as it is called several hundred thousands times. For some reason,
787         the compiler did not inline it even though it is very simple in release builds.
788
789         * WebCore.exp.in: Removed RenderObject::view() as it is inlined now.
790
791         * rendering/RenderObject.cpp: Moved the implementation from here ...
792         * rendering/RenderView.h:
793         (WebCore::RenderObject::view): ... to here to avoid a cyclic
794         dependency between RenderObject and RenderView. Also marked the
795         function as ALWAYS_INLINE.
796
797         * rendering/RenderObject.h:
798         * rendering/svg/RenderSVGResourceContainer.cpp:
799         Added #include "RenderView.h" as the code checks for view() during repaint.
800
801 2011-12-06  Julien Chaffraix  <jchaffraix@webkit.org>
802
803         CSS Grid Layout: Add support for parsing multiple grid-columns or grid-rows
804         https://bugs.webkit.org/show_bug.cgi?id=73272
805
806         Reviewed by Tony Chang.
807
808         Test: fast/css-grid-layout/grid-columns-rows-get-set-multiple.html
809
810         Updated our supported syntax to match the following:
811         <track-list> := [ <track-breadth> ]+ | 'none'
812         <track-breadth> := <length> | <percentage> | 'auto'
813         (the naming loosely matches the specification)
814
815         * css/CSSComputedStyleDeclaration.cpp:
816         (WebCore::valueForGridTrackBreadth): Added function to handle a breadth
817         (extended with 'auto' that the spec puts in <track-minmax>).
818
819         (WebCore::valueForGridTrackList): Create a space seperated list of
820         track breadth or none.
821
822         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): Updated
823         to use the new functions.
824
825         * css/CSSParser.cpp:
826         (WebCore::CSSParser::parseGridTrackList): Extended the function to
827         match the new syntax.
828
829         * css/CSSStyleApplyProperty.cpp:
830         (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty): Removed our
831         simple implementation. Replaced by the CSSStyleSelector functions.
832
833         * css/CSSStyleSelector.cpp:
834         (WebCore::createGridTrackBreadth):
835         (WebCore::createGridTrackList):
836         Added those 2 functions to convert the CSSPrimitiveValue to a Vector
837         as expected by RenderStyle.
838
839         (WebCore::CSSStyleSelector::applyProperty): Added our 2 properties
840         now that it is not handled by CSSStyleApplyProperty.
841
842         * rendering/style/RenderStyle.h:
843         (WebCore::InheritedFlags::gridColumns):
844         (WebCore::InheritedFlags::gridRows):
845         (WebCore::InheritedFlags::setGridColumns):
846         (WebCore::InheritedFlags::setGridRows):
847         (WebCore::InheritedFlags::initialGridColumns):
848         (WebCore::InheritedFlags::initialGridRows):
849         Updated the previous methods to take a Vector of Length.
850
851         (WebCore::InheritedFlags::initialGridTrackValue):
852         Needed function to return a Vector with one 'none' Length (the initial
853         value per the specification).
854
855         * rendering/style/StyleGridData.h: Updated to use a Vector.
856
857 2011-12-06  David Reveman  <reveman@chromium.org>
858
859         [Chromium] Implement tile-sized painting using SkPicture.
860         https://bugs.webkit.org/show_bug.cgi?id=71869
861
862         Reviewed by James Robinson.
863
864         Add texture uploader that paints tile-sized chunks using SkPicture
865         recording and playback. Expose setting which allows this texture
866         updater to be enabled.
867
868         No new tests. Covered by existing tests.
869
870         * WebCore.gypi:
871         * platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.cpp: Added.
872         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::Texture::Texture):
873         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::Texture::prepareRect):
874         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::Texture::updateRect):
875         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::create):
876         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::BitmapSkPictureCanvasLayerTextureUpdater):
877         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::~BitmapSkPictureCanvasLayerTextureUpdater):
878         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::createTexture):
879         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::sampledTexelFormat):
880         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::prepareToUpdate):
881         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::paintContentsRect):
882         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::updateTextureRect):
883         * platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.h: Added.
884         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::Texture::textureUpdater):
885         (WebCore::BitmapSkPictureCanvasLayerTextureUpdater::orientation):
886         * platform/graphics/chromium/ContentLayerChromium.cpp:
887         (WebCore::ContentLayerChromium::createTextureUpdater):
888         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
889         (WebCore::CCSettings::CCSettings):
890
891 2011-12-06  Adrienne Walker  <enne@google.com>
892
893         [chromium] Don't crash if tile upload happens without painting first
894         https://bugs.webkit.org/show_bug.cgi?id=73939
895
896         Reviewed by James Robinson.
897
898         Remove at least one place (in ImageLayerChromium) where this could
899         happen.
900
901         Although this shouldn't happen, we should be robust to it in the
902         chance that other code causes it to.
903
904         * platform/graphics/chromium/ImageLayerChromium.cpp:
905         (WebCore::ImageLayerChromium::paintContentsIfDirty):
906         * platform/graphics/chromium/TiledLayerChromium.cpp:
907         (WebCore::TiledLayerChromium::updateCompositorResources):
908
909 2011-12-06  Ruben  <chromium@hybridsource.org>
910
911         Enable web audio by default on non-Mac POSIX platforms
912         https://bugs.webkit.org/show_bug.cgi?id=73491
913
914         Reviewed by Tony Chang.
915
916         No new tests, just changing gyp includes.
917
918         * WebCore.gyp/WebCore.gyp:
919
920 2011-12-06  Benjamin Poulain  <benjamin@webkit.org>
921
922         Put length in its own variable in KURL copyASCII
923         https://bugs.webkit.org/show_bug.cgi?id=73928
924
925         Reviewed by Darin Adler.
926
927         * platform/KURL.cpp:
928         (WebCore::copyASCII):
929
930 2011-12-06  Dana Jansens  <danakj@chromium.org>
931
932         [chromium] Set opaque flag for ImageLayerChromium
933         https://bugs.webkit.org/show_bug.cgi?id=72964
934
935         Reviewed by James Robinson.
936
937         Unit test in tests/ImageLayerChromiumTest.cpp.
938
939         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
940         (WebCore::GraphicsLayerChromium::setContentsToImage):
941         * platform/graphics/chromium/GraphicsLayerChromium.h:
942         (WebCore::GraphicsLayerChromium::contentsLayer):
943         * platform/graphics/chromium/ImageLayerChromium.cpp:
944         (WebCore::ImageLayerChromium::setContents):
945
946 2011-12-06  Alexandre Elias  <aelias@google.com>
947
948         [chromium] Apply sent deltas on finishCommit
949         https://bugs.webkit.org/show_bug.cgi?id=73884
950
951         Reviewed by James Robinson.
952
953         This moves scroll and pageScale "sent" deltas to be applied to
954         the layer at the end of the commit, instead of the beginning.
955
956         This has several advantages, especially for page scale:
957         - When pageScale changes, no longer any need to change the scroll's
958         coordinate space at beginning of commit, which is complex and prone to
959         bugs (this fixes a problem where we were forgetting to modify the
960         scrollPosition before).
961         - No need for non-commit-related code to consider the "sent" values.
962         m_pageScale is now always the content scale factor, and
963         m_pageScaleDelta is the scale to be on the impl-side matrix.
964         - This will make it easy to send arbitrary fake or future delta
965         values for example while pinch zooming out.
966
967         The scroll logic is similarly altered for consistency's sake.  Note that
968         I also moved the tree synchronize to the beginning of finishCommit
969         in order to avoid having to change the pageScale coordinate space of
970         sentScrollDelta in adjustScrollsForPageScaleChange().
971
972         No new tests. (Refactoring of existing code.)
973
974         * platform/graphics/chromium/LayerChromium.cpp:
975         (WebCore::LayerChromium::pushPropertiesTo):
976         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
977         (WebCore::CCLayerTreeHost::finishCommitOnImplThread):
978         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
979         (WebCore::CCLayerTreeHostImpl::setPageScaleFactorAndLimits):
980         (WebCore::CCLayerTreeHostImpl::applyPageScaleDeltaToScrollLayer):
981         (WebCore::CCLayerTreeHostImpl::processScrollDeltas):
982
983 2011-12-06  Gavin Barraclough  <barraclough@apple.com>
984
985         https://bugs.webkit.org/show_bug.cgi?id=68328
986         The generator and intrinsic fields in HashTableValue/HashEntry and associated structures and methods are redundant
987
988         Reviewed by Geoff Garen.
989
990         Intrinsic is no longer in the DFG namespace, is always in the
991         hash table. Removed ThunkGenerator.
992
993         * bindings/scripts/CodeGeneratorJS.pm:
994         (GenerateHashTable):
995
996 2011-12-06  Dimitri Glazkov  <dglazkov@chromium.org>
997
998         Unreviewed, rolling out r102091.
999         http://trac.webkit.org/changeset/102091
1000         https://bugs.webkit.org/show_bug.cgi?id=73711
1001
1002         Caused Clang Linux compile failure.
1003
1004         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
1005         (WebCore::GraphicsLayerChromium::setAnchorPoint):
1006         (WebCore::GraphicsLayerChromium::setTransform):
1007         (WebCore::GraphicsLayerChromium::setChildrenTransform):
1008         (WebCore::GraphicsLayerChromium::setMasksToBounds):
1009         (WebCore::GraphicsLayerChromium::setBackgroundColor):
1010         (WebCore::GraphicsLayerChromium::clearBackgroundColor):
1011         (WebCore::GraphicsLayerChromium::setContentsOpaque):
1012         (WebCore::GraphicsLayerChromium::setBackfaceVisibility):
1013         (WebCore::GraphicsLayerChromium::setOpacity):
1014         * platform/graphics/chromium/LayerChromium.cpp:
1015         (WebCore::LayerChromium::setNeedsCommit):
1016         * platform/graphics/chromium/LayerChromium.h:
1017         (WebCore::LayerChromium::setAnchorPoint):
1018         (WebCore::LayerChromium::setAnchorPointZ):
1019         (WebCore::LayerChromium::setBackgroundColor):
1020         (WebCore::LayerChromium::setMasksToBounds):
1021         (WebCore::LayerChromium::setMaskLayer):
1022         (WebCore::LayerChromium::setOpacity):
1023         (WebCore::LayerChromium::setOpaque):
1024         (WebCore::LayerChromium::setPosition):
1025         (WebCore::LayerChromium::setSublayerTransform):
1026         (WebCore::LayerChromium::setTransform):
1027         (WebCore::LayerChromium::setScrollPosition):
1028         (WebCore::LayerChromium::setScrollable):
1029         (WebCore::LayerChromium::setDoubleSided):
1030         (WebCore::LayerChromium::setReplicaLayer):
1031         * platform/graphics/chromium/NonCompositedContentHost.cpp:
1032         (WebCore::NonCompositedContentHost::notifySyncRequired):
1033         * platform/graphics/chromium/NonCompositedContentHost.h:
1034
1035 2011-12-06  Dana Jansens  <danakj@chromium.org>
1036
1037         [Chromium] Make root layer always opaque
1038         https://bugs.webkit.org/show_bug.cgi?id=70564
1039
1040         Reviewed by James Robinson.
1041
1042         * platform/graphics/chromium/NonCompositedContentHost.cpp:
1043         (WebCore::NonCompositedContentHost::NonCompositedContentHost):
1044         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
1045         (WebCore::CCTiledLayerImpl::draw):
1046
1047 2011-12-06  Noel Gordon  <noel.gordon@gmail.com>
1048
1049         WebPImageDecoder computes image width and height multiple times
1050         https://bugs.webkit.org/show_bug.cgi?id=73796
1051
1052         Reviewed by Adam Barth.
1053
1054         Once sufficient image data arrives, we can compute the decoded image height
1055         and width from the WEBP image header data.
1056
1057         From then on, the decoded image size is known so there's no need to re-read
1058         it from the WEBP image header again.
1059
1060         No change in behavior, so no new tests.
1061
1062         * platform/image-decoders/webp/WEBPImageDecoder.cpp:
1063         (WebCore::WEBPImageDecoder::decode):
1064
1065 2011-12-06  Mike Reed  <reed@google.com>
1066
1067         optimize TransformationMatrix::scale by not calling through to generic multiply
1068         https://bugs.webkit.org/show_bug.cgi?id=73830
1069
1070         Reviewed by Kenneth Russell.
1071
1072         No new tests. Optimization only, existing tests exercise the code
1073
1074         * platform/graphics/transforms/TransformationMatrix.cpp:
1075         (WebCore::TransformationMatrix::scaleNonUniform):
1076         (WebCore::TransformationMatrix::scale3d):
1077
1078 2011-12-06  Eric Carlson  <eric.carlson@apple.com>
1079
1080         Revert WebCore track Settings changes made in r101977
1081         https://bugs.webkit.org/show_bug.cgi?id=73879
1082
1083         Reviewed by Sam Weinig.
1084
1085         No new tests yet, still nothing to test.
1086
1087         * page/Settings.cpp: Move the preference setters back into the .h file.
1088         * page/Settings.h:
1089         (WebCore::Settings::setShouldDisplaySubtitles):
1090         (WebCore::Settings::setShouldDisplayCaptions):
1091         (WebCore::Settings::setShouldDisplayTextDescriptions):
1092
1093 2011-12-06  Andreas Kling  <kling@webkit.org>
1094
1095         MediaList: Remove constructor that takes a CSSImportRule*.
1096         <http://webkit.org/b/73833>
1097
1098         Reviewed by Antti Koivisto.
1099
1100         * css/MediaList.h:
1101         * css/MediaList.cpp:
1102
1103             Remove MediaList(CSSImportRule*, ...) constructor.
1104
1105         * css/CSSImportRule.cpp:
1106         (WebCore::CSSImportRule::CSSImportRule):
1107
1108             Have CSSImportRule construct its MediaList by passing the parent
1109             style sheet, which is exactly what the old constructor accomplished.
1110             Also assert that we're always created with a non-null parent sheet.
1111
1112 2011-12-06  Jarred Nicholls  <jarred@sencha.com>
1113
1114         getComputedStyle returns wrong value for margin-*
1115         https://bugs.webkit.org/show_bug.cgi?id=73334
1116
1117         margin-* getComputedStyle values should return the "used" absolute value when there is a renderer
1118         and the specified value is relative (percentage, auto, etc.).
1119         When there is no renderer, the specified value should be returned.
1120         See http://dev.w3.org/csswg/cssom/#resolved-values.
1121
1122         Reviewed by Darin Adler.
1123
1124         Test: fast/css/getComputedStyle/getComputedStyle-resolved-values.html
1125
1126         * css/CSSComputedStyleDeclaration.cpp:
1127         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1128
1129 2011-12-06  Alexey Proskuryakov  <ap@apple.com>
1130
1131         REGRESSION (WebKit2): Kill ring is not cleared when selection changes
1132         https://bugs.webkit.org/show_bug.cgi?id=73888
1133         <rdar://problem/10532310>
1134
1135         Reviewed by Mark Rowe.
1136
1137         Test: editing/pasteboard/emacs-ctrl-k-with-move.html
1138
1139         * editing/Editor.cpp: (WebCore::Editor::respondToChangedSelection): Moved the code to clear
1140         kill ring from Mac WebKit, as it's needed in all Mac ports at least.
1141
1142 2011-12-06  Darin Adler  <darin@apple.com>
1143
1144         Use HashMap<OwnPtr> in CollectionCache
1145         https://bugs.webkit.org/show_bug.cgi?id=73784
1146
1147         Reviewed by Andreas Kling.
1148
1149         * html/CollectionCache.cpp:
1150         (WebCore::CollectionCache::copyCacheMap): Use adoptPtr.
1151         (WebCore::CollectionCache::reset): Removed now-unneeded calls to deleteAllValues.
1152         (WebCore::append): Added. Helper function for appending elements to the maps from
1153         the collection cache.
1154
1155         * html/CollectionCache.h: Changed mapped type in NodeCacheMap to OwnPtr.
1156         Added append function.
1157
1158         * html/HTMLCollection.cpp:
1159         (WebCore::nameShouldBeVisibleInDocumentAll): Added, to factor out common code in
1160         two functions below.
1161         (WebCore::HTMLCollection::checkForNameMatch): Changed to call nameShouldBeVisibleInDocumentAll.
1162         (WebCore::HTMLCollection::updateNameCache): Ditto. Also updated cache code to use the append
1163         function, so it will work with OwnPtr. Also eliminated an unneeded get call before
1164         each hash table add; we do both at once in the new append function.
1165         * html/HTMLFormCollection.cpp:
1166         (WebCore::HTMLFormCollection::updateNameCache): More of the same.
1167
1168 2011-12-06  Yury Semikhatsky  <yurys@chromium.org>
1169
1170         [Chromium] Web Inspector: getFunctionLocation should return scriptId as String not as int
1171         https://bugs.webkit.org/show_bug.cgi?id=73892
1172
1173         Reviewed by Pavel Feldman.
1174
1175         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
1176         (WebCore::V8InjectedScriptHost::functionLocationCallback): scriptId should be a string not a number
1177         * inspector/Inspector.json: removed unused parameter
1178
1179 2011-11-21  Balazs Kelemen  <kbalazs@webkit.org>
1180
1181         Enable ParallelJobs by default
1182         https://bugs.webkit.org/show_bug.cgi?id=70032
1183
1184         Reviewed by Zoltan Herczeg.
1185
1186         Covered by existing tests.
1187
1188         According to measurements on Mac and Linux it is a
1189         considerable speedup for SVG on multicore.
1190
1191         Remove the ENABLE(PARALLEL_JOBS) guard. Fix the Windows build
1192         by qualifying ParallelJobs with the WTF namespace (otherwise
1193         MSVC believes it belongs to WebCore which is likely a compiler bug).
1194
1195         * platform/graphics/filters/FEConvolveMatrix.cpp:
1196         (WebCore::FEConvolveMatrix::setInteriorPixelsWorker):
1197         (WebCore::FEConvolveMatrix::platformApplySoftware):
1198         * platform/graphics/filters/FEConvolveMatrix.h:
1199         * platform/graphics/filters/FEGaussianBlur.cpp:
1200         (WebCore::FEGaussianBlur::platformApplyWorker):
1201         (WebCore::FEGaussianBlur::platformApply):
1202         * platform/graphics/filters/FEGaussianBlur.h:
1203         * platform/graphics/filters/FELighting.cpp:
1204         (WebCore::FELighting::platformApplyGenericWorker):
1205         (WebCore::FELighting::platformApplyGeneric):
1206         * platform/graphics/filters/FELighting.h:
1207         * platform/graphics/filters/FEMorphology.cpp:
1208         (WebCore::FEMorphology::platformApplyWorker):
1209         (WebCore::FEMorphology::platformApply):
1210         * platform/graphics/filters/FEMorphology.h:
1211         * platform/graphics/filters/FETurbulence.cpp:
1212         (WebCore::FETurbulence::fillRegionWorker):
1213         (WebCore::FETurbulence::platformApplySoftware):
1214         * platform/graphics/filters/FETurbulence.h:
1215         * platform/graphics/filters/arm/FELightingNEON.cpp:
1216         (WebCore::FELighting::platformApplyNeonWorker):
1217         * platform/graphics/filters/arm/FELightingNEON.h:
1218         (WebCore::FELighting::platformApplyNeon):
1219
1220 2011-12-06  Andreas Kling  <kling@webkit.org>
1221
1222         Unreviewed assertion fix for r102123.
1223
1224         * platform/KURL.cpp:
1225         (WebCore::checkEncodedString):
1226
1227 2011-12-06  Benjamin Poulain  <benjamin@webkit.org>
1228
1229         Simplify KURL's checkEncodedString()
1230         https://bugs.webkit.org/show_bug.cgi?id=73890
1231
1232         Reviewed by Andreas Kling.
1233
1234         The method was reimplementing String::containsOnlyASCII().
1235         Use the method from String and we can remove the #if NDEBUG.
1236
1237         * platform/KURL.cpp:
1238         (WebCore::checkEncodedString):
1239
1240 2011-12-06  Sheriff Bot  <webkit.review.bot@gmail.com>
1241
1242         Unreviewed, rolling out r102111.
1243         http://trac.webkit.org/changeset/102111
1244         https://bugs.webkit.org/show_bug.cgi?id=73902
1245
1246         Breaks compilation (Requested by vsevik on #webkit).
1247
1248         * editing/Editor.cpp:
1249         (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges):
1250         * editing/Editor.h:
1251
1252 2011-12-06  Hajime Morrita  <morrita@chromium.org>
1253
1254         [Refactoring] Accessing Node::m_document should be minimized.
1255         https://bugs.webkit.org/show_bug.cgi?id=73800
1256
1257         Reviewed by Kent Tamura.
1258
1259         No new tests. No behavioral change.
1260
1261         Replaced m_document reference with the document() accessor
1262         or temporaril variables. This is a preparation for using
1263         m_document space to point a shadow root pointer.
1264
1265         * dom/Document.h:
1266         (WebCore::Node::Node):
1267         * dom/Node.cpp:
1268         (WebCore::Node::~Node):
1269
1270 2011-12-06  Shinya Kawanaka  <shinyak@google.com>
1271
1272         https://bugs.webkit.org/show_bug.cgi?id=73889
1273         TextCheckingParagraph::offsetTo should not have a side effect.
1274
1275         Reviewed by Hajime Morita.
1276
1277         Since TextCheckingParagraph::offsetTo had a side effect, its cache often became inconsistent.
1278         This is likely to cause a bug when changing SpellChecker and Editor.
1279
1280         No new tests. Covered by existing tests.
1281
1282         * editing/TextCheckingHelper.cpp:
1283         (WebCore::TextCheckingParagraph::offsetTo):
1284
1285 2011-12-06  Eric Penner  <epenner@google.com>
1286
1287         [chromium] Set texture limits as multiples of viewport size instead of hardcoded values
1288         https://bugs.webkit.org/show_bug.cgi?id=72202
1289
1290         Reviewed by James Robinson.
1291
1292         * platform/graphics/chromium/LayerRendererChromium.cpp: 
1293         (WebCore::LayerRendererChromium::drawLayers): added viewport param
1294         (WebCore::LayerRendererChromium::initializeSharedObjects): ditto 
1295         * platform/graphics/chromium/TextureManager.cpp: 
1296         (WebCore::TextureManager::highLimitBytes): calculated based on viewport
1297         (WebCore::TextureManager::reclaimLimitBytes): ditto
1298         (WebCore::TextureManager::lowLimitBytes): ditto
1299         (WebCore::TextureManager::TextureManager): added viewport param
1300         (WebCore::TextureManager::setMaxMemoryLimitBytes): changed name
1301         (WebCore::TextureManager::setPreferredMemoryLimitBytes): added function
1302         (WebCore::TextureManager::requestTexture): added viewport param
1303         * platform/graphics/chromium/TextureManager.h: ditto
1304         (WebCore::TextureManager::create): ditto
1305         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp: ditto
1306         (WebCore::CCLayerTreeHost::initialize): ditto
1307         (WebCore::CCLayerTreeHost::beginCommitOnImplThread): ditto
1308         (WebCore::CCLayerTreeHost::setViewport): ditto
1309         (WebCore::CCLayerTreeHost::setVisible): ditto
1310         (WebCore::CCLayerTreeHost::didBecomeInvisibleOnImplThread): ditto
1311
1312 2011-12-06  Huang Dongsung  <luxtella@company100.net>
1313
1314         [TexMap][QT] Draw the borders of media and webgl elements in TexMap.
1315         https://bugs.webkit.org/show_bug.cgi?id=73817
1316
1317         GraphicsContext3D only draws the content of the WebGL canvas, not the additional
1318         CSS such as the borders. TextureMapper should render the content of a
1319         media/webgl layer before drawing the actual canvas.
1320         This makes LayoutTests/compositing/webgl/webgl-reflection.html work.
1321
1322         Reviewed by Noam Rosenthal.
1323
1324         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
1325         (WebCore::GraphicsLayerTextureMapper::setContentsNeedsDisplay):
1326         * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
1327         * platform/graphics/texmap/TextureMapperNode.cpp:
1328         (WebCore::TextureMapperNode::renderContent):
1329         (WebCore::TextureMapperNode::paintSelf):
1330
1331 2011-12-06  Sheriff Bot  <webkit.review.bot@gmail.com>
1332
1333         Unreviewed, rolling out r102043.
1334         http://trac.webkit.org/changeset/102043
1335         https://bugs.webkit.org/show_bug.cgi?id=73898
1336
1337         Breaks chromium mac-cg compilation. (Requested by vsevik on
1338         #webkit).
1339
1340         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
1341         (WebCore::GraphicsLayerChromium::setContentsToImage):
1342         * platform/graphics/chromium/GraphicsLayerChromium.h:
1343         (WebCore::GraphicsLayerChromium::contentsLayer):
1344         * platform/graphics/chromium/ImageLayerChromium.cpp:
1345         (WebCore::ImageLayerChromium::setContents):
1346
1347 2011-12-06  Shinya Kawanaka  <shinyak@google.com>
1348
1349         Refactoring: Editor::markAllMisspellingsAndBadGrammarInRanges should be refactored.
1350         https://bugs.webkit.org/show_bug.cgi?id=73628
1351
1352         Reviewed by Hajime Morita.
1353
1354         Extracted a code for adding markers and replacing misspelled words from WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges.
1355
1356         No new tests. covered by existing tests.
1357
1358         * editing/Editor.cpp:
1359         (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges):
1360           Extracted a code for adding markers and replacing missplled words, and moved to markAndReplaceFor.
1361         (WebCore::Editor::markAndReplaceFor):
1362         * editing/Editor.h:
1363
1364 2011-12-05  Alexander Pavlov  <apavlov@chromium.org>
1365
1366         Web Inspector: [Audits] Implement "Stop" button and progress bar instead of spinner.
1367         https://bugs.webkit.org/show_bug.cgi?id=73626
1368
1369         Reviewed by Yury Semikhatsky.
1370
1371         * English.lproj/localizedStrings.js:
1372         * inspector/front-end/AuditLauncherView.js:
1373         (WebInspector.AuditLauncherView):
1374         (WebInspector.AuditLauncherView.prototype._setAuditRunning):
1375         (WebInspector.AuditLauncherView.prototype._launchButtonClicked):
1376         (WebInspector.AuditLauncherView.prototype._createLauncherUI):
1377         (WebInspector.AuditLauncherView.prototype._updateResourceProgress):
1378         (WebInspector.AuditLauncherView.prototype._updateButton):
1379         * inspector/front-end/AuditRules.js:
1380         (WebInspector.AuditRules.GzipRule.prototype.doRun):
1381         (WebInspector.AuditRules.CombineExternalResourcesRule.prototype.doRun):
1382         (WebInspector.AuditRules.MinimizeDnsLookupsRule.prototype.doRun):
1383         (WebInspector.AuditRules.UnusedCssRule.prototype.doRun.evalCallback.selectorsCallback):
1384         (WebInspector.AuditRules.UnusedCssRule.prototype.doRun.evalCallback.documentLoaded):
1385         (WebInspector.AuditRules.UnusedCssRule.prototype.doRun.evalCallback):
1386         (WebInspector.AuditRules.UnusedCssRule.prototype.doRun.styleSheetCallback):
1387         (WebInspector.AuditRules.UnusedCssRule.prototype.doRun.allStylesCallback):
1388         (WebInspector.AuditRules.UnusedCssRule.prototype.doRun):
1389         (WebInspector.AuditRules.CacheControlRule.prototype.doRun):
1390         (WebInspector.AuditRules.ImageDimensionsRule.prototype.doRun):
1391         (WebInspector.AuditRules.CssInHeadRule.prototype.doRun):
1392         (WebInspector.AuditRules.CssInHeadRule.prototype.doRun.externalStylesheetsReceived):
1393         (WebInspector.AuditRules.CssInHeadRule.prototype.doRun.inlineStylesReceived):
1394         (WebInspector.AuditRules.CssInHeadRule.prototype.doRun.onDocumentAvailable):
1395         (WebInspector.AuditRules.StylesScriptsOrderRule.prototype.doRun):
1396         (WebInspector.AuditRules.StylesScriptsOrderRule.prototype.doRun.cssBeforeInlineReceived):
1397         (WebInspector.AuditRules.StylesScriptsOrderRule.prototype.doRun.lateStylesReceived):
1398         (WebInspector.AuditRules.StylesScriptsOrderRule.prototype.doRun.onDocumentAvailable):
1399         (WebInspector.AuditRules.CookieRuleBase.prototype.doRun.resultCallback):
1400         (WebInspector.AuditRules.CookieRuleBase.prototype.doRun):
1401         * inspector/front-end/AuditsPanel.js:
1402         (WebInspector.AuditsPanel):
1403         (WebInspector.AuditsPanel.prototype._executeAudit.ruleResultReadyCallback):
1404         (WebInspector.AuditsPanel.prototype._executeAudit):
1405         (WebInspector.AuditsPanel.prototype._auditFinishedCallback):
1406         (WebInspector.AuditsPanel.prototype.terminateAudit):
1407         (WebInspector.AuditCategory.prototype.run):
1408         (WebInspector.AuditRule.prototype.run):
1409         (WebInspector.AuditRule.prototype.doRun):
1410         (WebInspector.AuditProgressMonitor):
1411         (WebInspector.AuditProgressMonitor.prototype.setTotalWork):
1412         (WebInspector.AuditProgressMonitor.prototype.worked):
1413         (WebInspector.AuditProgressMonitor.prototype.get indeterminate):
1414         (WebInspector.AuditProgressMonitor.prototype.done):
1415         (WebInspector.AuditProgressMonitor.prototype.get canceled):
1416         (WebInspector.AuditProgressMonitor.prototype.set canceled):
1417
1418 2011-12-06  Viatcheslav Ostapenko  <ostapenko.viatcheslav@nokia.com>
1419
1420         [Qt] [WK2] MiniBrowser assert on startup in debug build after r101713
1421         https://bugs.webkit.org/show_bug.cgi?id=73874
1422
1423         This change partially reverts r101713 restoring original behaviour for
1424         KUrl creation from empty string and fixes asserts in debug build.
1425
1426         Reviewed by Alexey Proskuryakov.
1427
1428         No new tests. Tests from r101713 pass.
1429
1430         * platform/KURL.cpp:
1431         (WebCore::KURL::init):
1432         (WebCore::KURL::parse):
1433         * platform/KURL.h:
1434
1435 2011-12-06  Andreas Kling  <kling@webkit.org>
1436
1437         Use HashMap<OwnPtr> for EventListenerMap's internal map.
1438         <http://webkit.org/b/73761>
1439
1440         Reviewed by Benjamin Poulain.
1441
1442         Changed the value type of EventListenerMap::m_hashMap to OwnPtr<EventListenerVector>.
1443         This means we no longer need to manually delete the vectors when taking them out of
1444         the map, which makes the code a little prettier.
1445
1446         A few tweaks were necessary; release() instead of leakPtr() when switching modes
1447         and adoptPtr()/get() sprinkled as needed.
1448
1449         * dom/EventListenerMap.h:
1450         * dom/EventListenerMap.cpp:
1451         (WebCore::EventListenerMap::clear):
1452         (WebCore::EventListenerMap::add):
1453         (WebCore::EventListenerMap::remove):
1454         (WebCore::EventListenerMap::find):
1455         (WebCore::EventListenerMap::removeFirstEventListenerCreatedFromMarkup):
1456         (WebCore::EventListenerMap::copyEventListenersNotCreatedFromMarkupToTarget):
1457
1458 2011-12-05  Rafael Weinstein  <rafaelw@chromium.org>
1459
1460         [MutationObservers] Support 'attributes' mutation records for element.removeAttribute
1461         https://bugs.webkit.org/show_bug.cgi?id=73880
1462
1463         Reviewed by Ojan Vafai.
1464
1465         * dom/Element.cpp:
1466         (WebCore::enqueueAttributesMutationRecord):
1467         (WebCore::Element::removeAttribute):
1468
1469 2011-12-05  Dana Jansens  <danakj@chromium.org>
1470
1471         Set opaque flag for WebGLLayerChromium
1472         https://bugs.webkit.org/show_bug.cgi?id=73876
1473
1474         Reviewed by James Robinson.
1475
1476         New unit test in tests/WebGLLayerChromiumTest.cpp
1477
1478         * platform/graphics/chromium/DrawingBufferChromium.cpp:
1479         (WebCore::DrawingBuffer::platformLayer):
1480
1481 2011-12-05  Benjamin Poulain  <bpoulain@apple.com>
1482
1483         Upstream the Cursor implementation of iOS
1484         https://bugs.webkit.org/show_bug.cgi?id=73724
1485
1486         Reviewed by David Kilzer.
1487
1488         iOS does not need to support the Cursor of WebKit. For compatibility, Cursor
1489         is implemented as an empty class on the platform.
1490
1491         * Configurations/WebCore.xcconfig:
1492         * WebCore.xcodeproj/project.pbxproj:
1493         * platform/Cursor.h:
1494         (WebCore::Cursor::Cursor):
1495         * platform/ios/CursorIOS.cpp: Added.
1496         (WebCore::cursor):
1497         (WebCore::pointerCursor):
1498         (WebCore::crossCursor):
1499         (WebCore::handCursor):
1500         (WebCore::moveCursor):
1501         (WebCore::iBeamCursor):
1502         (WebCore::waitCursor):
1503         (WebCore::helpCursor):
1504         (WebCore::eastResizeCursor):
1505         (WebCore::northResizeCursor):
1506         (WebCore::northEastResizeCursor):
1507         (WebCore::northWestResizeCursor):
1508         (WebCore::southResizeCursor):
1509         (WebCore::southEastResizeCursor):
1510         (WebCore::southWestResizeCursor):
1511         (WebCore::westResizeCursor):
1512         (WebCore::northSouthResizeCursor):
1513         (WebCore::eastWestResizeCursor):
1514         (WebCore::northEastSouthWestResizeCursor):
1515         (WebCore::northWestSouthEastResizeCursor):
1516         (WebCore::columnResizeCursor):
1517         (WebCore::rowResizeCursor):
1518         (WebCore::middlePanningCursor):
1519         (WebCore::eastPanningCursor):
1520         (WebCore::northPanningCursor):
1521         (WebCore::northEastPanningCursor):
1522         (WebCore::northWestPanningCursor):
1523         (WebCore::southPanningCursor):
1524         (WebCore::southEastPanningCursor):
1525         (WebCore::southWestPanningCursor):
1526         (WebCore::westPanningCursor):
1527         (WebCore::verticalTextCursor):
1528         (WebCore::cellCursor):
1529         (WebCore::contextMenuCursor):
1530         (WebCore::noDropCursor):
1531         (WebCore::notAllowedCursor):
1532         (WebCore::progressCursor):
1533         (WebCore::aliasCursor):
1534         (WebCore::zoomInCursor):
1535         (WebCore::zoomOutCursor):
1536         (WebCore::copyCursor):
1537         (WebCore::noneCursor):
1538         (WebCore::grabCursor):
1539         (WebCore::grabbingCursor):
1540         (WebCore::determineHotSpot):
1541
1542 2011-12-05  Noel Gordon  <noel.gordon@gmail.com>
1543
1544         [GTK] GIF image test crashes on 32- and 64-bit Release
1545         https://bugs.webkit.org/show_bug.cgi?id=73812
1546
1547         Reviewed by Adam Barth.
1548
1549         Call resize() on the image pixel backing store after allocation to see if
1550         that stops the GIF image decoder animation tests crashes on GTK.
1551
1552         No new tests, covered by exiting tests ...
1553           fast/backgrounds/animated-gif-as-background.html
1554           fast/images/dont-crash-with-null-gif-frames.html
1555           fast/images/gif-loop-count.html
1556
1557         * platform/image-decoders/ImageDecoder.cpp:
1558         (WebCore::ImageFrame::setSize):
1559
1560 2011-12-05  Erik Arvidsson  <arv@chromium.org>
1561
1562         Could save a lot of memory in CharacterData by not always storing a String
1563         https://bugs.webkit.org/show_bug.cgi?id=72404
1564
1565         Reviewed by Ojan Vafai.
1566
1567         When a Text node is created by the parser we check if the string is all whitespace
1568         and if so we put it in the AtomicString table so that all future identical whitespace
1569         strings can share the StringImpl.
1570
1571         No new tests. Covered by existing tests.
1572
1573         * html/parser/HTMLConstructionSite.cpp:
1574         (WebCore::HTMLNames::isAllWhitespace):
1575         (WebCore::HTMLConstructionSite::insertTextNode):
1576
1577             If we do not know whether the string is all whitespace this now checks the string
1578             If the string is all whitespace we create an AtomicString for it.
1579
1580         * html/parser/HTMLConstructionSite.h:
1581         * html/parser/HTMLTreeBuilder.cpp:
1582         (WebCore::HTMLTreeBuilder::ExternalCharacterTokenBuffer::skipLeadingNonWhitespace): We never cared about the return value here.
1583         (WebCore::HTMLTreeBuilder::processCharacterBuffer): Pass WhitespaceMode in the case we know whether the string is all whitespace or not.
1584         (WebCore::HTMLTreeBuilder::defaultForInTableText): Ditto.
1585
1586 2011-12-05  Benjamin Poulain  <benjamin@webkit.org>
1587
1588         Update KURL's copy copyASCII to avoid String::characters()
1589         https://bugs.webkit.org/show_bug.cgi?id=73794
1590
1591         Reviewed by Andreas Kling.
1592
1593         When the String is already on 8 bits, we can simply copy the
1594         data. In the 16 bits case, everything remains the same.
1595
1596         * platform/KURL.cpp:
1597         (WebCore::copyASCII):
1598         (WebCore::appendASCII):
1599         (WebCore::KURL::init):
1600         (WebCore::KURL::parse):
1601         (WebCore::KURL::copyToBuffer):
1602
1603 2011-12-05  Yong Li  <yoli@rim.com>
1604
1605         https://bugs.webkit.org/show_bug.cgi?id=73683
1606         Implement KeyframeValueList::operator=() and KeyframeValueList::swap().
1607
1608         Reviewed by Darin Adler.
1609
1610         No new tests as no functional change.
1611
1612         * platform/graphics/GraphicsLayer.h: 
1613         (WebCore::KeyframeValueList::operator=): Added
1614         (WebCore::KeyframeValueList::swap): Added
1615
1616 2011-12-05  Adrienne Walker  <enne@google.com>
1617
1618         [chromium] setNeedsCommit on non-composited host layers should trigger commit
1619         https://bugs.webkit.org/show_bug.cgi?id=73711
1620
1621         Reviewed by James Robinson.
1622
1623         Pipe non-composited content host syncs to setNeedsCommit.
1624
1625         Since now the NonCompositedContentHost generates setNeedsCommit, don't
1626         call it unnecessarily, e.g. calling setBackgroundColor to the same
1627         color each frame should not retrigger more commits.
1628
1629         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
1630         (WebCore::GraphicsLayerChromium::setAnchorPoint):
1631         (WebCore::GraphicsLayerChromium::setTransform):
1632         (WebCore::GraphicsLayerChromium::setChildrenTransform):
1633         (WebCore::GraphicsLayerChromium::setMasksToBounds):
1634         (WebCore::GraphicsLayerChromium::setBackgroundColor):
1635         (WebCore::GraphicsLayerChromium::clearBackgroundColor):
1636         (WebCore::GraphicsLayerChromium::setContentsOpaque):
1637         (WebCore::GraphicsLayerChromium::setBackfaceVisibility):
1638         (WebCore::GraphicsLayerChromium::setOpacity):
1639         * platform/graphics/chromium/LayerChromium.cpp:
1640         (WebCore::LayerChromium::setNeedsCommit):
1641         (WebCore::LayerChromium::setAnchorPoint):
1642         (WebCore::LayerChromium::setAnchorPointZ):
1643         (WebCore::LayerChromium::setBackgroundColor):
1644         (WebCore::LayerChromium::setMasksToBounds):
1645         (WebCore::LayerChromium::setMaskLayer):
1646         (WebCore::LayerChromium::setOpacity):
1647         (WebCore::LayerChromium::setOpaque):
1648         (WebCore::LayerChromium::setPosition):
1649         (WebCore::LayerChromium::setSublayerTransform):
1650         (WebCore::LayerChromium::setTransform):
1651         (WebCore::LayerChromium::setScrollPosition):
1652         (WebCore::LayerChromium::setScrollable):
1653         (WebCore::LayerChromium::setDoubleSided):
1654         * platform/graphics/chromium/LayerChromium.h:
1655         (WebCore::LayerChromium::setReplicaLayer):
1656         * platform/graphics/chromium/NonCompositedContentHost.cpp:
1657         (WebCore::NonCompositedContentHost::notifySyncRequired):
1658         * platform/graphics/chromium/NonCompositedContentHost.h:
1659
1660 2011-12-05  Tony Chang  <tony@chromium.org>
1661
1662         small refactor of RenderFlexibleBox
1663         https://bugs.webkit.org/show_bug.cgi?id=73854
1664
1665         Reviewed by Darin Adler.
1666
1667         No new tests, just a refactor.
1668
1669         * rendering/RenderFlexibleBox.cpp:
1670         (WebCore::RenderFlexibleBox::isLeftToRightFlow): Inline isReverseFlow since it's only used in one place.
1671         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren): Rename startEdge
1672         to mainAxisOffset.  Rename logicalTop to crossAxisOffset.  Get rid of
1673         logicalLeft local variable since it's confusing.  Move shouldFlipMainAxis
1674         out of the for loop to avoid computing it each iteration.
1675         * rendering/RenderFlexibleBox.h:
1676
1677 2011-12-05  Florin Malita  <fmalita@google.com>
1678
1679         Heap-buffer-overflow in WebCore::HTMLTreeBuilder::processEndTag
1680         https://bugs.webkit.org/show_bug.cgi?id=73765
1681
1682         Reviewed by Adam Barth.
1683
1684         Test: fast/parser/foreign-content-crash.html
1685
1686         Use m_tree.currentNode() instead of m_tree.currentElement() as the top node is not always an Element.
1687
1688         * html/parser/HTMLTreeBuilder.cpp:
1689         (WebCore::HTMLTreeBuilder::processEndTag):
1690
1691 2011-12-05  Stephen White  <senorblanco@chromium.org>
1692
1693         Allow the ImageBuffers used by SVG filters to be accelerated
1694         https://bugs.webkit.org/show_bug.cgi?id=73842
1695
1696         Reviewed by Kenneth Russell.
1697
1698         Regressions covered by existing SVG tests; new functionality to be
1699         tested by the API exposed on Internals.
1700
1701         * page/Settings.cpp:
1702         (WebCore::Settings::Settings):
1703         * page/Settings.h:
1704         (WebCore::Settings::setAcceleratedFiltersEnabled):
1705         (WebCore::Settings::acceleratedFiltersEnabled):
1706         * platform/graphics/filters/FETile.cpp:
1707         (WebCore::FETile::platformApplySoftware):
1708         * platform/graphics/filters/Filter.h:
1709         (WebCore::Filter::Filter):
1710         (WebCore::Filter::renderingMode):
1711         (WebCore::Filter::setRenderingMode):
1712         * platform/graphics/filters/FilterEffect.cpp:
1713         (WebCore::FilterEffect::asImageBuffer):
1714         (WebCore::FilterEffect::createImageBufferResult):
1715         * platform/graphics/skia/ImageBufferSkia.cpp:
1716         (WebCore::ImageBuffer::platformTransformColorSpace):
1717         * rendering/svg/RenderSVGResourceClipper.cpp:
1718         (WebCore::RenderSVGResourceClipper::applyClippingToContext):
1719         * rendering/svg/RenderSVGResourceFilter.cpp:
1720         (WebCore::RenderSVGResourceFilter::applyResource):
1721         * rendering/svg/RenderSVGResourceMasker.cpp:
1722         (WebCore::RenderSVGResourceMasker::applyResource):
1723         * rendering/svg/RenderSVGResourcePattern.cpp:
1724         (WebCore::RenderSVGResourcePattern::createTileImage):
1725         * rendering/svg/SVGImageBufferTools.cpp:
1726         (WebCore::SVGImageBufferTools::createImageBuffer):
1727         * rendering/svg/SVGImageBufferTools.h:
1728         * testing/Internals.cpp:
1729         (WebCore::Internals::setAcceleratedFiltersEnabled):
1730         * testing/Internals.h:
1731         * testing/Internals.idl:
1732
1733 2011-12-05  Benjamin Poulain  <bpoulain@apple.com>
1734
1735         Upstream htmlSelectMultipleItems needed for <select multiple> by iOS
1736         https://bugs.webkit.org/show_bug.cgi?id=73734
1737
1738         Reviewed by David Kilzer.
1739
1740         * platform/DefaultLocalizationStrategy.cpp:
1741         (WebCore::DefaultLocalizationStrategy::htmlSelectMultipleItems):
1742         * platform/DefaultLocalizationStrategy.h:
1743
1744 2011-12-05  Darin Adler  <darin@apple.com>
1745
1746         Use HashMap<OwnPtr> in CrossOriginPreflightResultCache
1747         https://bugs.webkit.org/show_bug.cgi?id=73785
1748
1749         Reviewed by Andreas Kling.
1750
1751         * loader/CrossOriginPreflightResultCache.cpp:
1752         (WebCore::CrossOriginPreflightResultCache::appendEntry): Changed code to use set
1753         instead of add, since it wants to replace existing entries. Also removed leakPtr
1754         and removed the FIXME that documented the memory leak now fixed here.
1755         (WebCore::CrossOriginPreflightResultCache::canSkipPreflight): Removed unneeded
1756         std:: prefix here and also unneeded explicit delete call.
1757         (WebCore::CrossOriginPreflightResultCache::empty): Removed unneeded deleteAllValues
1758         call here.
1759
1760         * loader/CrossOriginPreflightResultCache.h: Make mapped value of the
1761         CrossOriginPreflightResultHashMap be OwnPtr instead of raw pointer.
1762
1763 2011-12-05  Darin Adler  <darin@apple.com>
1764
1765         Some small improvements to ContainerNode.h
1766         https://bugs.webkit.org/show_bug.cgi?id=73786
1767
1768         Reviewed by Alexey Proskuryakov.
1769
1770         * dom/ContainerNode.cpp:
1771         (WebCore::ContainerNode::suspendPostAttachCallbacks): Added a FIXME comment about the
1772         peculiar behavior of this function. Somehow the post-attach suspend state is both
1773         global and specific to a certain Page object. That can't be right. If it was truly
1774         global then this would be a static member function. If it was truly per-page, then
1775         the related functions could not be static.
1776
1777         * dom/ContainerNode.h: Removed some unneeded argument names. Moved the hasChildNodes
1778         function up with the other basic getters. Put the other getters, childNodeCount and
1779         childNode, right after the basic getters. Used ASSERT_NO_EXCEPTION in all the basic
1780         mutation functions so they can be used in a cleaner fashion in C++ code where we have
1781         some reason to know an exception won't occur. Grouped all the overrides of functions
1782         from Node into a single paragraph and used the OVERRIDE macro on all of them. Made the
1783         queuePostAttachCallback and postAttachCallbacksAreSuspended functions protected.
1784
1785         * dom/Element.h: Moved the include of ExceptionCodePlaceholder.h into ContainerNode.h.
1786
1787         * dom/Node.cpp:
1788         (WebCore::Node::lazyAttach): Use hasChildNodes instead of firstChild for clarity.
1789         (WebCore::Node::isDescendantOf): Ditto.
1790
1791 2011-12-05  Benjamin Poulain  <benjamin@webkit.org>
1792
1793         Get rid of KURL::KURL(ParsedURLStringTag, const char*);
1794         https://bugs.webkit.org/show_bug.cgi?id=73792
1795
1796         Reviewed by Andreas Kling.
1797
1798         In all cases where the constructor is used, the constructor
1799         taking a String is as effective because the string is valid and converted
1800         to String for m_string.
1801
1802         This patch remove the constructor KURL::KURL(ParsedURLStringTag, const char*)
1803         and change the call sites that were using that constructor to build
1804         empty URLs.
1805
1806         * dom/Document.cpp:
1807         (WebCore::Document::initSecurityContext):
1808         * loader/FrameLoader.cpp:
1809         (WebCore::FrameLoader::init):
1810         * loader/archive/cf/LegacyWebArchive.cpp:
1811         (WebCore::LegacyWebArchive::create):
1812         * page/DOMWindow.cpp:
1813         (WebCore::DOMWindow::createWindow):
1814         * platform/KURL.cpp:
1815         * platform/KURL.h:
1816         * platform/KURLGoogle.cpp:
1817
1818 2011-12-05  Benjamin Poulain  <benjamin@webkit.org>
1819
1820         Remove methods declared but never implemented with GOOGLEURL
1821         https://bugs.webkit.org/show_bug.cgi?id=73795
1822
1823         Reviewed by Adam Barth.
1824
1825         * platform/KURL.h:
1826
1827 2011-12-05  Darin Adler  <darin@apple.com>
1828
1829         Change CSSFontSelector to use HashMap<OwnPtr>
1830         https://bugs.webkit.org/show_bug.cgi?id=73781
1831
1832         Reviewed by Dan Bernstein.
1833
1834         * css/CSSFontSelector.cpp:
1835         (WebCore::CSSFontSelector::~CSSFontSelector): Removed calls to deleteAllValues.
1836         (WebCore::CSSFontSelector::addFontFaceRule): Updated to use OwnPtr instead of raw
1837         pointer for the entry in m_fontFaces and m_locallyInstalledFontFaces.
1838         (WebCore::CSSFontSelector::getFontData): Updated to use OwnPtr instead of raw
1839         pointer for the entry in m_fonts. Also removed an unneeded std:: prefix.
1840
1841         * css/CSSFontSelector.h: Made m_fontFaces, m_locallyInstalledFontFaces, and m_fonts
1842         be HashMap<OwnPtr>.
1843
1844 2011-12-05  Adam Klein  <adamk@chromium.org>
1845
1846         V8RecursionScope should call didLeaveScriptContext when recursionLevel reaches zero
1847         https://bugs.webkit.org/show_bug.cgi?id=73867
1848
1849         Reviewed by Adam Barth.
1850
1851         Moved V8RecursionScope into its own file, and moved
1852         V8Proxy::didLeaveScriptContext into that file, along with a static
1853         recursionLevel accessor, hiding the V8BindingPerIsolateData methods
1854         from V8Proxy.
1855
1856         This will make it easy and less error-prone to use V8RecursionScope
1857         properly. I plan to make use of it in V8LazyEventListener to fix
1858         https://bugs.webkit.org/show_bug.cgi?id=73492.
1859
1860         No new tests, refactoring only.
1861
1862         * Target.pri:
1863         * UseV8.cmake:
1864         * WebCore.gypi:
1865         * bindings/v8/V8Binding.h:
1866         (WebCore::V8BindingPerIsolateData::incrementRecursionLevel): return the new recursion level.
1867         (WebCore::V8BindingPerIsolateData::decrementRecursionLevel): return the new recursion level.
1868         * bindings/v8/V8Proxy.cpp: remove didLeaveScriptContext.
1869         (WebCore::V8Proxy::runScript): remove explicit call to didLeaveScriptContext.
1870         (WebCore::V8Proxy::instrumentedCallFunction): remove explicit call to didLeaveScriptContext.
1871         * bindings/v8/V8Proxy.h: remove didLeaveScriptContext.
1872         * bindings/v8/V8RecursionScope.cpp: Added.
1873         (WebCore::V8RecursionScope::didLeaveScriptContext): copied from V8Proxy.cpp.
1874         * bindings/v8/V8RecursionScope.h: Added.
1875         (WebCore::V8RecursionScope::V8RecursionScope):
1876         (WebCore::V8RecursionScope::~V8RecursionScope):
1877         (WebCore::V8RecursionScope::recursionLevel):
1878
1879 2011-12-05  Benjamin Poulain  <bpoulain@apple.com>
1880
1881         Build fix for SecurityOrigin.cpp when neither BLOB nor FILE_SYSTEM are defined
1882
1883         Reviewed by David Kilzer.
1884
1885         When neither BLOB nor FILE_SYSTEM are defined, the parameter is unused.
1886
1887         * page/SecurityOrigin.cpp:
1888         (WebCore::shouldUseInnerURL):
1889
1890 2011-12-05  Darin Adler  <darin@apple.com>
1891
1892         Change RuleSet to use HashMap<OwnPtr>
1893         https://bugs.webkit.org/show_bug.cgi?id=73783
1894
1895         Reviewed by Andreas Kling.
1896
1897         * css/CSSStyleSelector.cpp: Make RuleSet::AtomRuleMap use OwnPtr for the mapped values.
1898         (WebCore::RuleSet::addToRuleSet): Use add instead of get/set to set up a new entry in the
1899         map or find the old entry in the map.
1900
1901 2011-12-05  Mario Sanchez Prada  <msanchez@igalia.com>
1902
1903         [GTK] Move emissions of AtkDocument signals down to WebCore
1904         https://bugs.webkit.org/show_bug.cgi?id=73750
1905
1906         Reviewed by Chris Fleizach.
1907
1908         Implement the needed infrastructure to allow notifying
1909         accessibility, in a cross-platform way, when a event related to
1910         the load of a document happens. Added a generic method, which will
1911         be called from the FrameLoader, and platform specific versions of
1912         it so every port has a chance to decide what to do with those
1913         notifications.
1914
1915         This patch doesn't include a new test because the one testing this
1916         functionality is the GTK-specific unit test added along with patch
1917         for bug 73746: testWebkitAtkDocumentLoadingEvents.
1918
1919         * accessibility/AXObjectCache.h:
1920         (WebCore::AXObjectCache::frameLoadingEventNotification): New, called
1921         from the FrameLoader to notify accessibility when an event happens.
1922         (WebCore::AXObjectCache::frameLoadingEventPlatformNotification): New,
1923         platform specific function to let ports decide what to do.
1924         * accessibility/AXObjectCache.cpp:
1925         (WebCore::AXObjectCache::frameLoadingEventNotification): New.
1926         * accessibility/chromium/AXObjectCacheChromium.cpp:
1927         (WebCore::AXObjectCache::frameLoadingEventPlatformNotification): Dummy
1928         implementation of the platform specific function for chromium.
1929         * accessibility/gtk/AXObjectCacheAtk.cpp:
1930         (WebCore::AXObjectCache::frameLoadingEventPlatformNotification):
1931         * accessibility/mac/AXObjectCacheMac.mm:
1932         (WebCore::AXObjectCache::frameLoadingEventPlatformNotification): Dummy
1933         implementation of the platform specific function for the Mac.
1934         * accessibility/win/AXObjectCacheWin.cpp:
1935         (WebCore::AXObjectCache::frameLoadingEventPlatformNotification): Dummy
1936         implementation of the platform specific function for Windows.
1937
1938         * loader/FrameLoader.cpp:
1939         (WebCore::FrameLoader::prepareForLoadStart): Notify accessibility
1940         by calling the new frameLoadingEventNotification() function.
1941         (WebCore::FrameLoader::checkLoadCompleteForThisFrame): Ditto.
1942
1943 2011-12-05  Benjamin Poulain  <benjamin@webkit.org>
1944
1945         Update String::containsOnlyASCII() to handle 8 bits strings
1946         https://bugs.webkit.org/show_bug.cgi?id=73799
1947
1948         Reviewed by Darin Adler.
1949
1950         When possible, change the call sites from charactersAreAllASCII()
1951         to the optimized version String::containsOnlyASCII().
1952
1953         * platform/KURL.cpp:
1954         (WebCore::KURL::init):
1955         * platform/cf/BinaryPropertyList.cpp:
1956         (WebCore::BinaryPropertyListPlan::writeStringObject):
1957         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
1958         (WebCore::FontCodepage::if):
1959
1960 2011-12-01  Vangelis Kokkevis  <vangelis@chromium.org>
1961
1962         [chromium] Use ANGLE's texture_usage and texture_storage extensions when allocating compositor textures
1963         https://bugs.webkit.org/show_bug.cgi?id=73621
1964
1965         When the extensions are available, compositor textures are allocated via
1966         glTexStorage2DEXT instead of glTexImage2D to eliminate creation of unnecessary
1967         mip levels on the service side. In addition, the GL_FRAMEBUFFER_ATTACHMENT_ANGLE
1968         is specified for all textures used by RenderSurfaces to eliminate the need for
1969         a system memory bitmap allocation.
1970
1971         Reviewed by Kenneth Russell.
1972
1973         * platform/graphics/chromium/Extensions3DChromium.h:
1974         * platform/graphics/chromium/LayerRendererChromium.cpp:
1975         (WebCore::LayerRendererChromium::initialize):
1976         (WebCore::LayerRendererChromium::initializeSharedObjects):
1977         * platform/graphics/chromium/TrackingTextureAllocator.cpp:
1978         (WebCore::TrackingTextureAllocator::TrackingTextureAllocator):
1979         (WebCore::textureToStorageFormat):
1980         (WebCore::isTextureFormatSupportedForStorage):
1981         (WebCore::TrackingTextureAllocator::createTexture):
1982         * platform/graphics/chromium/TrackingTextureAllocator.h:
1983         (WebCore::TrackingTextureAllocator::setTextureUsageHint):
1984         (WebCore::TrackingTextureAllocator::setUseTextureStorageExt):
1985         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
1986         (WebCore::LayerRendererCapabilities::LayerRendererCapabilities):
1987
1988 2011-12-05  Chris Fleizach  <cfleizach@apple.com>
1989
1990         AX: aria-hidden doesn't work on iframe elements
1991         https://bugs.webkit.org/show_bug.cgi?id=73857
1992
1993         Reviewed by Darin Adler.
1994
1995         Test: platform/mac/accessibility/iframe-aria-hidden.html
1996
1997         * accessibility/AccessibilityRenderObject.cpp:
1998         (WebCore::AccessibilityRenderObject::addAttachmentChildren):
1999         (WebCore::AccessibilityRenderObject::addChildren):
2000         * accessibility/AccessibilityRenderObject.h:
2001         * accessibility/AccessibilityScrollView.cpp:
2002         (WebCore::AccessibilityScrollView::accessibilityIsIgnored):
2003         (WebCore::AccessibilityScrollView::addChildren):
2004         * accessibility/AccessibilityScrollView.h:
2005
2006 2011-12-05  Chris Fleizach  <cfleizach@apple.com>
2007
2008         AX: web search mechanism does not work with frames
2009         https://bugs.webkit.org/show_bug.cgi?id=73836
2010
2011         Reviewed by Beth Dakin.
2012
2013         This allows searching for, and within, frames for elements using the accessibility
2014         search mechanism.
2015
2016         Test: platform/mac/accessibility/search-with-frames.html
2017
2018         * accessibility/AccessibilityObject.cpp:
2019         (WebCore::AccessibilityObject::isAccessibilityObjectSearchMatch):
2020         (WebCore::appendAccessibilityObject):
2021         (WebCore::appendChildrenToArray):
2022
2023 2011-12-05  Anders Carlsson  <andersca@apple.com>
2024
2025         Make LayerFlushSchedulerClient::flushLayers indicate whether the flush was successful or not
2026         https://bugs.webkit.org/show_bug.cgi?id=73862
2027
2028         Reviewed by Andy Estes.
2029
2030         Change LayerFlushSchedulerClient::flushLayers to return a boolean. If it returns true, the flush was
2031         successful and the run loop observer will be invalidated.
2032
2033         * platform/graphics/ca/LayerFlushScheduler.h:
2034         * platform/graphics/ca/LayerFlushSchedulerClient.h:
2035         * platform/graphics/ca/mac/LayerFlushSchedulerMac.cpp:
2036         (WebCore::LayerFlushScheduler::runLoopObserverCallback):
2037
2038 2011-12-05  Dana Jansens  <danakj@chromium.org>
2039
2040         [chromium] Set opaque flag for ImageLayerChromium
2041         https://bugs.webkit.org/show_bug.cgi?id=72964
2042
2043         Reviewed by James Robinson.
2044
2045         New unit test in tests/ImageLayerChromiumTest.cpp.
2046
2047         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
2048         (WebCore::GraphicsLayerChromium::setContentsToImage):
2049         * platform/graphics/chromium/GraphicsLayerChromium.h:
2050         (WebCore::GraphicsLayerChromium::contentsLayer):
2051         * platform/graphics/chromium/ImageLayerChromium.cpp:
2052         (WebCore::ImageLayerChromium::setContents):
2053
2054 2011-12-05  Julien Chaffraix  <jchaffraix@webkit.org>
2055
2056         TD width in precentage doesn't work.
2057         https://bugs.webkit.org/show_bug.cgi?id=34758
2058
2059         Reviewed by David Hyatt.
2060
2061         Test: fast/table/colspan-with-all-percent-cells.html
2062
2063         * rendering/AutoTableLayout.cpp:
2064         (WebCore::AutoTableLayout::calcEffectiveLogicalWidth):
2065         In the case where all our columns have percent lengths, split the colspan
2066         logical width using the percentages from the lengths. This should be properly
2067         handled by the massive 'else' case but it is not and I did not feel like refactor
2068         that due to massive compatibility issues that would arise.
2069
2070 2011-12-05  Chris Fleizach  <cfleizach@apple.com>
2071
2072         platform/mac/accessibility/search-when-element-starts-in-table.html is failing
2073         https://bugs.webkit.org/show_bug.cgi?id=73751
2074
2075         When encountering a table, the rows() and not the cells() should be queried (otherwise
2076         we can end up finding the element we started with).
2077
2078         When searching in reverse, we also need to account for searching elements within the
2079         parent hierarchy. because technically it is "behind" the start element.
2080
2081         Reviewed by Darin Adler.
2082
2083         * accessibility/AccessibilityObject.cpp:
2084         (WebCore::appendChildrenToArray):
2085         (WebCore::AccessibilityObject::objectMatchesSearchCriteriaWithResultLimit):
2086         (WebCore::AccessibilityObject::findMatchingObjects):
2087         * accessibility/AccessibilityObject.h:
2088
2089 2011-12-02  Jer Noble  <jer.noble@apple.com>
2090
2091         <video> elements should disable the system and display sleep when playing on OS X.
2092         https://bugs.webkit.org/show_bug.cgi?id=73730
2093         <rdar://problem/9502155>
2094
2095         Reviewed by Alexey Proskuryakov.
2096
2097         No new tests; platform specific system behavior only.
2098
2099         Create a new DisplaySleepDisabler object when the playback rate becomes non-zero, and destroy
2100         that object when the playback rate drops back to zero.
2101
2102         * html/HTMLMediaElement.cpp:
2103         (WebCore::HTMLMediaElement::mediaPlayerRateChanged):
2104         * html/HTMLMediaElement.h:
2105
2106 2011-12-05  Peter Beverloo  <peter@chromium.org>
2107
2108         [Chromium] Add Android keycodes and build Linux clipboard/filesystem files.
2109         https://bugs.webkit.org/show_bug.cgi?id=73672
2110
2111         Add the KeyCodeConversionAndroid.cpp file, which is a partial re-land
2112         of an older file from the Android port:
2113         http://trac.webkit.org/browser/trunk/WebCore/platform/android/KeyEventAndroid.cpp?rev=56704
2114
2115         Add IconChromiumAndroid.cpp which nullifies the rendering of icons in
2116         file upload boxes, which is not something we want to support now. Also
2117         include ClipboardChromiumLinux.cpp and FileSystemChromiumLinux.cpp
2118         as their functionality can be re-used for Android.
2119
2120         Reviewed by Adam Barth.
2121
2122         * WebCore.gyp/WebCore.gyp:
2123         * WebCore.gypi:
2124         * platform/chromium/KeyCodeConversionAndroid.cpp: Added.
2125         (WebCore::windowsKeyCodeForKeyEvent):
2126         * platform/graphics/chromium/IconChromiumAndroid.cpp: Added.
2127         (WebCore::Icon::Icon):
2128         (WebCore::Icon::~Icon):
2129         (WebCore::Icon::paint):
2130
2131 2011-12-05  Steve Falkenburg  <sfalken@apple.com>
2132
2133         Reviewed by Sam Weinig.
2134
2135         On Windows, filenames not properly preserved when copied into a file list exposed by Event.dataTransfer
2136         https://bugs.webkit.org/show_bug.cgi?id=73841
2137         <rdar://problem/10521879>
2138
2139         No test since repro case involves dropping a file onto the WebView.
2140         
2141         Calling characters() explicitly causes a non-terminated string buffer to get passed back
2142         to the String() constructor that expects a terminated buffer. The characters() call isn't
2143         necessary at all, since we have a String and the method we're calling expects a String.
2144
2145         * platform/win/ClipboardWin.cpp:
2146         (WebCore::ClipboardWin::files): Remove characters() since it doesn't null terminate.
2147
2148 2011-12-05  Timothy Hatcher  <timothy@apple.com>
2149
2150         Keep both InspectorBackend.js and InspectorBackendStub.js in Release builds after
2151         they have been combined into inspector.js.
2152
2153         The InspectorBackend.js file split out of the generated InspectorBackendStub.js
2154         in r101670, and both files are needed to be useful.
2155
2156         https://webkit.org/b/73839
2157
2158         Reviewed by Joseph Pecoraro and Brian Weinstein.
2159
2160         * WebCore.xcodeproj/project.pbxproj: Pass -not -name "InspectorBackend*.js" to find
2161         instead of -not -name InspectorBackendStub.js.
2162
2163 2011-12-05  Mikhail Naganov  <mnaganov@chromium.org>
2164
2165         Web Inspector: [Chromium] Heap profiler should designate weak references.
2166         https://bugs.webkit.org/show_bug.cgi?id=69948
2167
2168         Weak references are now ignored when tracing paths to GC roots.
2169
2170         Reviewed by Yury Semikhatsky.
2171
2172         * inspector/front-end/HeapSnapshot.js:
2173         (WebInspector.HeapSnapshotEdge.prototype.get isWeak):
2174         (WebInspector.HeapSnapshotEdge.prototype.toString):
2175         (WebInspector.HeapSnapshotEdge.prototype.get _hasStringName):
2176         (WebInspector.HeapSnapshotRetainerEdge.prototype.get isWeak):
2177         (WebInspector.HeapSnapshot.prototype._init):
2178         (WebInspector.HeapSnapshotPathFinder.prototype._fillRootChildren):
2179         (WebInspector.HeapSnapshotPathFinder.prototype._skipEdge):
2180
2181 2011-12-05  Sheriff Bot  <webkit.review.bot@gmail.com>
2182
2183         Unreviewed, rolling out r102004.
2184         http://trac.webkit.org/changeset/102004
2185         https://bugs.webkit.org/show_bug.cgi?id=73835
2186
2187         Breaks qt minimal release compilation (Requested by vsevik on
2188         #webkit).
2189
2190         * inspector/CodeGeneratorInspector.py:
2191         (Capitalizer.upper_camel_case_to_lower):
2192         (RawTypes.get):
2193         (RawTypes.String.get_c_param_type):
2194         (RawTypes.Object.get_c_param_type):
2195         (RawTypes.Object):
2196         (ParamType):
2197         (TypeData.__init__):
2198         (TypeData.get_raw_type):
2199         (TypeMap.__init__):
2200         (InspectorFrontend_h):
2201         (InspectorArray):
2202         (InspectorObject):
2203         (String):
2204         (InspectorBackendDispatcher_h):
2205         (Generator.process_command):
2206         * inspector/InspectorValues.h:
2207
2208 2011-12-05  Peter Rybin  <peter.rybin@gmail.com>
2209
2210         Web Inspector: [protocol] generate C++ classes for protocol JSON named types
2211         https://bugs.webkit.org/show_bug.cgi?id=72835
2212
2213         Reviewed by Yury Semikhatsky.
2214
2215         Extends python generator functionality.
2216         Makes constructor in InspectorObject public.
2217
2218         * inspector/CodeGeneratorInspector.py:
2219         * inspector/InspectorValues.h:
2220
2221 2011-12-05  Pavel Podivilov  <podivilov@chromium.org>
2222
2223         Web Inspector: fix fronted compilation.
2224         https://bugs.webkit.org/show_bug.cgi?id=73831
2225
2226         Reviewed by Yury Semikhatsky.
2227
2228         * inspector/front-end/CompilerSourceMapping.js:
2229         (WebInspector.ClosureCompilerSourceMappingPayload):
2230
2231 2011-12-05  Eric Carlson  <eric.carlson@apple.com>
2232
2233         Out-of-band text tracks may only load from same origin as the media element's Document's origin
2234         https://bugs.webkit.org/show_bug.cgi?id=73184
2235
2236         Reviewed by Sam Weinig.
2237
2238         Test: http/tests/security/text-track-crossorigin.html
2239
2240         * html/HTMLTrackElement.cpp:
2241         (WebCore::urlForLogging): Debug-only function for logging urls.
2242         (WebCore::HTMLTrackElement::scheduleLoad): Call canLoadUrl() before passing control off to
2243             the Track.
2244         (WebCore::HTMLTrackElement::canLoadUrl): Don't ask HTMLMediaElement to validate the url, the
2245             requirements for <track> are different from <video>.
2246         (WebCore::HTMLTrackElement::didCompleteLoad): Change bool param to enum.
2247         (WebCore::HTMLTrackElement::mediaElementCrossOriginAttribute): New, return parent 'crossorigin' 
2248             attribute value.
2249         * html/HTMLTrackElement.h:
2250
2251         * html/LoadableTextTrack.cpp:
2252         (WebCore::LoadableTextTrack::scheduleLoad): Add comments from the spec.
2253         (WebCore::LoadableTextTrack::loadTimerFired): Always cancel pending loads. Let the caller know 
2254             if the loader refuses the url immediately.
2255         (WebCore::LoadableTextTrack::cueLoadingStarted): The <track> deals with readyState.
2256         (WebCore::LoadableTextTrack::cueLoadingCompleted): HTMLTrackElement::didCompleteLoad takes
2257             an enum, not a bool.
2258
2259         * loader/TextTrackLoader.cpp:
2260         (WebCore::TextTrackLoader::corsPolicyPreventedLoad): New, log the error and set m_state.
2261         (WebCore::TextTrackLoader::notifyFinished): Check for CORS failure.
2262         (WebCore::TextTrackLoader::load): Take media element cross-origin attribute as a param so we
2263             can make the correct checks.
2264         * loader/TextTrackLoader.h:
2265
2266 2011-12-05  Roland Steiner  <rolandsteiner@chromium.org>
2267
2268         "Raw" pseudo selectors don't match if immediately after a child or descendant combinator
2269         https://bugs.webkit.org/show_bug.cgi?id=72933
2270
2271         Remove shortcut that prevents universal selectors from being created before shadow pseudo-elements.
2272
2273         Reviewed by Antti Koivisto.
2274
2275         * css/CSSParser.cpp:
2276         (WebCore::CSSParser::updateSpecifiersWithElementName):
2277
2278 2011-12-05  Sheriff Bot  <webkit.review.bot@gmail.com>
2279
2280         Unreviewed, rolling out r101983.
2281         http://trac.webkit.org/changeset/101983
2282         https://bugs.webkit.org/show_bug.cgi?id=73827
2283
2284         It broke all tests on GTK and on Qt in debug mode (Requested
2285         by Ossy on #webkit).
2286
2287         * dom/Document.h:
2288         (WebCore::Node::Node):
2289         * dom/Node.cpp:
2290         (WebCore::Node::~Node):
2291         * dom/Node.h:
2292         (WebCore::Node::inDocument):
2293
2294 2011-12-05  Roland Steiner  <rolandsteiner@chromium.org>
2295
2296         <style scoped>: Add 'scoped' attribute
2297         https://bugs.webkit.org/show_bug.cgi?id=67718
2298
2299         Add 'scoped' attribute to IDL and attribute list,
2300         implement and test setting/resetting of the attribute.
2301
2302         Reviewed by Antti Koivisto.
2303
2304         Test: fast/css/style-scoped/basic-attribute.html
2305
2306         * html/HTMLAttributeNames.in:
2307         * html/HTMLStyleElement.cpp:
2308         (WebCore::HTMLStyleElement::scoped):
2309         (WebCore::HTMLStyleElement::setScoped):
2310         (WebCore::HTMLStyleElement::scopingElement):
2311         * html/HTMLStyleElement.h:
2312         * html/HTMLStyleElement.idl:
2313
2314 2011-12-05  Hajime Morrita  <morrita@chromium.org>
2315
2316         [Refactoring] Accessing Node::m_document should be minimized.
2317         https://bugs.webkit.org/show_bug.cgi?id=73800
2318
2319         Reviewed by Kent Tamura.
2320
2321         No new tests. No behavioral change.
2322
2323         Replaced m_document reference with the document() accessor
2324         or temporaril variables. This is a preparation for using
2325         m_document space to point a shadow root pointer.
2326
2327         * dom/Document.h:
2328         (WebCore::Node::Node):
2329         * dom/Node.cpp:
2330         (WebCore::Node::~Node):
2331         * dom/Node.h:
2332         (WebCore::Node::inDocument):
2333
2334 2011-12-05  Shinya Kawanaka  <shinyak@google.com>
2335
2336         Asynchronous SpellChecker should consider multiple requests.
2337         https://bugs.webkit.org/show_bug.cgi?id=72939
2338
2339         Reviewed by Hajime Morita.
2340
2341         Now SpellChecker saves a request when it is processing the previous spellcheck request.
2342         If there is a request having the same root editable element, the older request is replaced by newer request
2343
2344         Test: editing/spelling/spellcheck-queue.html
2345
2346         * editing/SpellChecker.cpp:
2347         (WebCore::SpellChecker::SpellCheckRequest::SpellCheckRequest):
2348           A structure to have spell check request.
2349         (WebCore::SpellChecker::SpellCheckRequest::sequence):
2350         (WebCore::SpellChecker::SpellCheckRequest::range):
2351         (WebCore::SpellChecker::SpellCheckRequest::text):
2352         (WebCore::SpellChecker::SpellCheckRequest::mask):
2353         (WebCore::SpellChecker::SpellCheckRequest::rootEditableElement):
2354         (WebCore::SpellChecker::SpellChecker):
2355         (WebCore::SpellChecker::createRequest):
2356         (WebCore::SpellChecker::timerFiredToProcessQueuedRequest):
2357           When timer is fired, queued request is processed if any.
2358         (WebCore::SpellChecker::canCheckAsynchronously):
2359         (WebCore::SpellChecker::requestCheckingFor):
2360           When the spellchecker is processing another request, the latest request is queued.
2361         (WebCore::SpellChecker::invokeRequest):
2362         (WebCore::SpellChecker::enqueueRequest):
2363           Enqueues a request. If there is an older request whose root editable element is the same as the request,
2364           it will be replaced.
2365         (WebCore::SpellChecker::didCheck):
2366         * editing/SpellChecker.h:
2367
2368 2011-12-05  Eric Carlson  <eric.carlson@apple.com>
2369
2370         WebCore part of: Add WebKit preferences for text track settings
2371         https://bugs.webkit.org/show_bug.cgi?id=73721
2372
2373         Reviewed by John Sullivan.
2374
2375         No new tests yet, still nothing to test.
2376
2377         * page/Settings.cpp:
2378         (WebCore::Settings::setShouldDisplaySubtitles): Move the setters to the .cpp file so they
2379             aren't inlined.
2380         (WebCore::Settings::setShouldDisplayCaptions): Ditto.
2381         (WebCore::Settings::setShouldDisplayTextDescriptions): Ditto.
2382         * page/Settings.h:
2383
2384 2011-12-05  Noel Gordon  <noel.gordon@gmail.com>
2385
2386         ImageDecoder setSize() should check for backing store allocation failure
2387         https://bugs.webkit.org/show_bug.cgi?id=72864
2388
2389         Reviewed by Adam Barth.
2390
2391         The backing store of a decoded image is a Vector<PixelData> on the affected
2392         ports. And Vector<> provides a resize capacity member that returns false if
2393         memory allocation fails.
2394
2395         setSize() should be called once only during an image decode - add an ASSERT
2396         for that. Resize the backing store capacity to the requested image size and
2397         return false if memory allocation fails.
2398
2399         ImageDecoder::isOverSize(width, height) is called to check that the decoded
2400         width and height won't overflow 'width x height x sizeof(PixelData)' before
2401         calls to setSize(). Refer to http://webkit.org/b/48634
2402
2403         No new tests. Covered by fast/images/size-failure.html
2404
2405         * platform/image-decoders/ImageDecoder.cpp:
2406         (WebCore::ImageFrame::setSize):
2407
2408 2011-12-04  Andreas Kling  <kling@webkit.org>
2409
2410         CSSStyleSheet can't be reparented, enforce this at compile time.
2411         <http://webkit.org/b/73793>
2412
2413         Reviewed by Benjamin Poulain.
2414
2415         * css/StyleSheet.h:
2416         (WebCore::StyleSheet::clearOwnerRule):
2417
2418             Changed setParentRule(CSSImportRule*) to clearOwnerRule() to document and
2419             enforce the fact that style sheets should never be reparented after creation.
2420
2421         (WebCore::StyleSheet::ownerRule):
2422
2423             Renamed parentRule() to ownerRule() to match the CSSOM name.
2424
2425         (WebCore::StyleSheet::ownerNode):
2426         (WebCore::StyleSheet::clearOwnerNode):
2427
2428             Also renamed StyleSheet::m_parentNode to m_ownerNode to match its accessors.
2429
2430         * css/CSSStyleSheet.h:
2431
2432             Removed ownerRule() as we now inherit it from StyleSheet.
2433
2434         * bindings/js/JSDOMBinding.h:
2435         (WebCore::root):
2436         * css/CSSImportRule.cpp:
2437         (WebCore::CSSImportRule::~CSSImportRule):
2438         (WebCore::CSSImportRule::setCSSStyleSheet):
2439         * css/StyleSheet.cpp:
2440         (WebCore::StyleSheet::StyleSheet):
2441         (WebCore::StyleSheet::parentStyleSheet):
2442         (WebCore::StyleSheet::baseURL):
2443         * inspector/InspectorStyleSheet.cpp:
2444         (WebCore::fillMediaListChain):
2445
2446             Update call sites to use the new names.
2447
2448 2011-12-04  Andreas Kling  <kling@webkit.org>
2449
2450         border-width: initial and border-color: initial cannot be removed via CSSOM.
2451         <http://webkit.org/b/68551>
2452
2453         Reviewed by Darin Adler.
2454
2455         Test: fast/css/cssom-remove-shorthand-property.html
2456
2457         When asked to remove a shorthand property, we should toss out both the
2458         sub-properties of that shorthand as well as the shorthand itself, should the
2459         declaration contain it. The latter part was missing in our implementation.
2460
2461         * css/CSSMutableStyleDeclaration.h:
2462         * css/CSSMutableStyleDeclaration.cpp:
2463         (WebCore::CSSMutableStyleDeclaration::removePropertiesInSet):
2464         (WebCore::CSSMutableStyleDeclaration::removeShorthandProperty):
2465
2466             Changed to return true only if something was actually removed.
2467
2468 2011-12-04  Ryosuke Niwa  <rniwa@webkit.org>
2469
2470         HIERARCHY_REQUEST_ERR check in checkAcceptChild should be optimized for newChild without children
2471         https://bugs.webkit.org/show_bug.cgi?id=73737
2472
2473         Reviewed by Darin Adler.
2474
2475         It turned out that 50-70% of nodes inserted by DOM APIs such as insertBefore and appendChild
2476         don't have any descendent nodes. Optimize isDescendantOf which is used by checkAcceptChild for this case.
2477         On a test case attached on the bug, we see a 40% improvement.
2478
2479         Also optimize for cases where either new child or new parent but not both are in document as suggested
2480         by Erik Arvidsson. This appears to happen about 40-70% of the time, and the symmetric difference between
2481         the two cases is about 50% so it's worth implementing both optimizations.
2482
2483         Unfortunately no tests because we still have a O(n) algorithm somewhere.
2484
2485         * dom/Node.cpp:
2486         (WebCore::Node::isDescendantOf):
2487         (WebCore::Node::contains):
2488
2489 2011-12-04  Andreas Kling  <kling@webkit.org>
2490
2491         CSSValuePool: Inline trivial getters.
2492         <http://webkit.org/b/73763>
2493
2494         Reviewed by Anders Carlsson.
2495
2496         * css/CSSValuePool.cpp:
2497         * css/CSSValuePool.h:
2498         (WebCore::CSSValuePool::createInheritedValue): Inlined.
2499         (WebCore::CSSValuePool::createImplicitInitialValue): Ditto.
2500         (WebCore::CSSValuePool::createExplicitInitialValue): Ditto.
2501
2502 2011-12-03  Noel Gordon  <noel.gordon@gmail.com>
2503
2504         Fix WebPImageDecoder decoder leak.
2505         https://bugs.webkit.org/show_bug.cgi?id=73756
2506
2507         Reviewed by Andreas Kling.
2508
2509         Delete the m_decoder member in the destructor if needed with WebPIDelete.
2510
2511         No new tests, it's valgrind territory.
2512
2513         * platform/image-decoders/webp/WEBPImageDecoder.cpp:
2514         (WebCore::WEBPImageDecoder::~WEBPImageDecoder):
2515
2516 2011-12-03  Andreas Kling  <kling@webkit.org>
2517
2518         CSSStyleSheet: Parent rule can only ever be @import, enforce this at compile time.
2519         <http://webkit.org/b/73725>
2520
2521         Reviewed by Darin Adler.
2522
2523         Made StyleSheet::m_parentRule a CSSImportRule* rather than a CSSRule*
2524         and updated getters, setters and constructors accordingly.
2525
2526         There is no change in behavior, this simply enforces the status quo.
2527
2528         * WebCore.xcodeproj/project.pbxproj:
2529         * bindings/js/JSDOMBinding.h:
2530         * bindings/scripts/CodeGeneratorV8.pm:
2531         (AddIncludesForType):
2532         * css/CSSStyleSheet.cpp:
2533         (WebCore::CSSStyleSheet::CSSStyleSheet):
2534         * css/CSSStyleSheet.h:
2535         (WebCore::CSSStyleSheet::create):
2536         (WebCore::CSSStyleSheet::ownerRule):
2537         * css/StyleSheet.cpp:
2538         (WebCore::StyleSheet::StyleSheet):
2539         * css/StyleSheet.h:
2540         (WebCore::StyleSheet::parentRule):
2541         (WebCore::StyleSheet::setParentRule):
2542
2543 2011-12-03  Andreas Kling  <kling@webkit.org>
2544
2545         Unreviewed, revert accidental change from r101932.
2546
2547         * bindings/scripts/CodeGeneratorV8.pm:
2548         (AddIncludesForType):
2549
2550 2011-12-03  Mary Wu  <mary.wu@torchmobile.com.cn>
2551
2552         Upstream 4 files into WebCore/platform/blackberry
2553         https://bugs.webkit.org/show_bug.cgi?id=73614
2554
2555         Reviewed by Eric Seidel.
2556
2557         * platform/blackberry/CursorBlackBerry.cpp: Added.
2558         (WebCore::AllCursors::AllCursors):
2559         (WebCore::getCursor):
2560         (WebCore::Cursor::Cursor):
2561         (WebCore::Cursor::~Cursor):
2562         (WebCore::Cursor::operator=):
2563         (WebCore::aliasCursor):
2564         (WebCore::cellCursor):
2565         (WebCore::columnResizeCursor):
2566         (WebCore::contextMenuCursor):
2567         (WebCore::copyCursor):
2568         (WebCore::crossCursor):
2569         (WebCore::eastResizeCursor):
2570         (WebCore::eastWestResizeCursor):
2571         (WebCore::grabbingCursor):
2572         (WebCore::grabCursor):
2573         (WebCore::handCursor):
2574         (WebCore::helpCursor):
2575         (WebCore::iBeamCursor):
2576         (WebCore::moveCursor):
2577         (WebCore::noDropCursor):
2578         (WebCore::noneCursor):
2579         (WebCore::northEastResizeCursor):
2580         (WebCore::northEastSouthWestResizeCursor):
2581         (WebCore::northResizeCursor):
2582         (WebCore::northSouthResizeCursor):
2583         (WebCore::northWestResizeCursor):
2584         (WebCore::northWestSouthEastResizeCursor):
2585         (WebCore::notAllowedCursor):
2586         (WebCore::pointerCursor):
2587         (WebCore::progressCursor):
2588         (WebCore::rowResizeCursor):
2589         (WebCore::southEastResizeCursor):
2590         (WebCore::southResizeCursor):
2591         (WebCore::southWestResizeCursor):
2592         (WebCore::verticalTextCursor):
2593         (WebCore::waitCursor):
2594         (WebCore::westResizeCursor):
2595         (WebCore::zoomInCursor):
2596         (WebCore::zoomOutCursor):
2597         (WebCore::middlePanningCursor):
2598         (WebCore::eastPanningCursor):
2599         (WebCore::northPanningCursor):
2600         (WebCore::northEastPanningCursor):
2601         (WebCore::northWestPanningCursor):
2602         (WebCore::southPanningCursor):
2603         (WebCore::southEastPanningCursor):
2604         (WebCore::southWestPanningCursor):
2605         (WebCore::westPanningCursor):
2606         * platform/blackberry/DragDataBlackBerry.cpp: Added.
2607         (WebCore::DragData::canSmartReplace):
2608         (WebCore::DragData::containsColor):
2609         (WebCore::DragData::containsCompatibleContent):
2610         (WebCore::DragData::containsFiles):
2611         (WebCore::DragData::containsPlainText):
2612         (WebCore::DragData::containsURL):
2613         (WebCore::DragData::asFilenames):
2614         (WebCore::DragData::asColor):
2615         (WebCore::DragData::asPlainText):
2616         (WebCore::DragData::asURL):
2617         (WebCore::DragData::asFragment):
2618         * platform/blackberry/DragImageBlackBerry.cpp: Added.
2619         (WebCore::createDragImageFromImage):
2620         (WebCore::createDragImageIconForCachedImage):
2621         (WebCore::deleteDragImage):
2622         (WebCore::dissolveDragImageToFraction):
2623         (WebCore::scaleDragImage):
2624         (WebCore::dragImageSize):
2625         * platform/blackberry/EventLoopBlackBerry.cpp: Added.
2626         (WebCore::EventLoop::platformInit):
2627         (WebCore::EventLoop::cycle):
2628
2629 2011-12-03  Andreas Kling  <kling@webkit.org>
2630
2631         Cache CSSInitialValue instances per-document.
2632         <http://webkit.org/b/73745>
2633
2634         Reviewed by Oliver Hunt.
2635
2636         Test: http/tests/security/cross-origin-css-primitive.html
2637
2638         Have CSSValuePool manage the caching of CSSInitialValue objects.
2639
2640         * css/CSSInitialValue.h:
2641         (WebCore::CSSInitialValue::createExplicit):
2642         (WebCore::CSSInitialValue::createImplicit):
2643         (WebCore::CSSInitialValue::CSSInitialValue):
2644         * css/CSSParser.cpp:
2645         (WebCore::CSSParser::parseValue):
2646         (WebCore::CSSParser::parseFillShorthand):
2647         (WebCore::CSSParser::parseAnimationShorthand):
2648         (WebCore::CSSParser::parseTransitionShorthand):
2649         (WebCore::CSSParser::parseShorthand):
2650         * css/CSSValuePool.cpp:
2651         (WebCore::CSSValuePool::CSSValuePool):
2652         (WebCore::CSSValuePool::createImplicitInitialValue):
2653         (WebCore::CSSValuePool::createExplicitInitialValue):
2654         * css/CSSValuePool.h:
2655
2656 2011-12-03  Andreas Kling  <kling@webkit.org>
2657
2658         Keep CSSInheritedValue in the CSS value pool.
2659         <http://webkit.org/b/73747>
2660
2661         Reviewed by Antti Koivisto.
2662
2663         We only need one CSSInheritedValue instance per document, so cache it
2664         in CSSValuePool and have the parser create it through there.
2665
2666         * css/CSSParser.cpp:
2667         (WebCore::CSSParser::parseValue):
2668         * css/CSSValuePool.cpp:
2669         (WebCore::CSSValuePool::CSSValuePool):
2670         (WebCore::CSSValuePool::createInheritedValue):
2671         * css/CSSValuePool.h:
2672
2673 2011-12-03  Andreas Kling  <kling@webkit.org>
2674
2675         Rename CSSPrimitiveValueCache to CSSValuePool.
2676         <http://webkit.org/b/73742>
2677
2678         Reviewed by Antti Koivisto.
2679
2680         CSSPrimitiveValueCache -> CSSValuePool
2681         Document::primitiveValueCache() -> Document::cssValuePool()
2682
2683         This is in preparation for sharing more than just primitive values.
2684
2685         * CMakeLists.txt:
2686         * GNUmakefile.list.am:
2687         * Target.pri:
2688         * WebCore.gypi:
2689         * WebCore.vcproj/WebCore.vcproj:
2690         * WebCore.xcodeproj/project.pbxproj:
2691         * bindings/scripts/CodeGeneratorV8.pm:
2692         (AddIncludesForType):
2693         * css/CSSComputedStyleDeclaration.cpp:
2694         (WebCore::valueForNinePieceImageSlice):
2695         (WebCore::valueForNinePieceImageQuad):
2696         (WebCore::valueForNinePieceImageRepeat):
2697         (WebCore::valueForNinePieceImage):
2698         (WebCore::zoomAdjustedPixelValue):
2699         (WebCore::zoomAdjustedNumberValue):
2700         (WebCore::zoomAdjustedPixelValueForLength):
2701         (WebCore::valueForReflection):
2702         (WebCore::getPositionOffsetValue):
2703         (WebCore::CSSComputedStyleDeclaration::currentColorOrValidColor):
2704         (WebCore::getBorderRadiusCornerValue):
2705         (WebCore::computedTransform):
2706         (WebCore::CSSComputedStyleDeclaration::valueForFilter):
2707         (WebCore::valueForGridTrackList):
2708         (WebCore::getDelayValue):
2709         (WebCore::getDurationValue):
2710         (WebCore::createLineBoxContainValue):
2711         (WebCore::CSSComputedStyleDeclaration::getFontSizeCSSValuePreferringKeyword):
2712         (WebCore::CSSComputedStyleDeclaration::valueForShadow):
2713         (WebCore::valueForFamily):
2714         (WebCore::renderTextDecorationFlagsToCSSValue):
2715         (WebCore::fillRepeatToCSSValue):
2716         (WebCore::fillSizeToCSSValue):
2717         (WebCore::contentToCSSValue):
2718         (WebCore::counterToCSSValue):
2719         (WebCore::fontFamilyFromStyle):
2720         (WebCore::lineHeightFromStyle):
2721         (WebCore::fontSizeFromStyle):
2722         (WebCore::fontStyleFromStyle):
2723         (WebCore::fontVariantFromStyle):
2724         (WebCore::fontWeightFromStyle):
2725         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
2726         * css/CSSParser.cpp:
2727         (WebCore::parseColorValue):
2728         (WebCore::parseSimpleLengthValue):
2729         (WebCore::CSSParser::setStyleSheet):
2730         (WebCore::CSSParser::createPrimitiveNumericValue):
2731         (WebCore::CSSParser::createPrimitiveStringValue):
2732         (WebCore::CSSParser::parseValidPrimitive):
2733         (WebCore::CSSParser::parseValue):
2734         (WebCore::parseBackgroundClip):
2735         (WebCore::CSSParser::parseFillShorthand):
2736         (WebCore::CSSParser::parsePage):
2737         (WebCore::CSSParser::parseSizeParameter):
2738         (WebCore::CSSParser::parseContent):
2739         (WebCore::CSSParser::parseAttr):
2740         (WebCore::CSSParser::parseBackgroundColor):
2741         (WebCore::CSSParser::parseFillPositionX):
2742         (WebCore::CSSParser::parseFillPositionY):
2743         (WebCore::CSSParser::parseFillPositionComponent):
2744         (WebCore::CSSParser::parseFillPosition):
2745         (WebCore::CSSParser::parseFillRepeat):
2746         (WebCore::CSSParser::parseFillSize):
2747         (WebCore::CSSParser::parseFillProperty):
2748         (WebCore::CSSParser::parseAnimationDirection):
2749         (WebCore::CSSParser::parseAnimationFillMode):
2750         (WebCore::CSSParser::parseAnimationIterationCount):
2751         (WebCore::CSSParser::parseAnimationName):
2752         (WebCore::CSSParser::parseAnimationPlayState):
2753         (WebCore::CSSParser::parseAnimationProperty):
2754         (WebCore::CSSParser::parseAnimationTimingFunction):
2755         (WebCore::CSSParser::parseGridTrackList):
2756         (WebCore::CSSParser::parseDashboardRegions):
2757         (WebCore::CSSParser::parseCounterContent):
2758         (WebCore::CSSParser::parseShape):
2759         (WebCore::CSSParser::parseWrapShape):
2760         (WebCore::CSSParser::parseFont):
2761         (WebCore::CSSParser::parseFontFamily):
2762         (WebCore::CSSParser::parseFontStyle):
2763         (WebCore::CSSParser::parseFontVariant):
2764         (WebCore::CSSParser::parseFontWeight):
2765         (WebCore::CSSParser::parseColor):
2766         (WebCore::ShadowParseContext::ShadowParseContext):
2767         (WebCore::ShadowParseContext::commitLength):
2768         (WebCore::ShadowParseContext::commitStyle):
2769         (WebCore::CSSParser::parseShadow):
2770         (WebCore::CSSParser::parseReflect):
2771         (WebCore::CSSParser::parseFlex):
2772         (WebCore::BorderImageParseContext::BorderImageParseContext):
2773         (WebCore::CSSParser::parseBorderImage):
2774         (WebCore::CSSParser::parseBorderImageRepeat):
2775         (WebCore::BorderImageSliceParseContext::BorderImageSliceParseContext):
2776         (WebCore::BorderImageSliceParseContext::commitNumber):
2777         (WebCore::BorderImageSliceParseContext::commitBorderImageSlice):
2778         (WebCore::CSSParser::parseBorderImageSlice):
2779         (WebCore::BorderImageQuadParseContext::BorderImageQuadParseContext):
2780         (WebCore::BorderImageQuadParseContext::commitNumber):
2781         (WebCore::BorderImageQuadParseContext::commitBorderImageQuad):
2782         (WebCore::CSSParser::parseBorderImageQuad):
2783         (WebCore::CSSParser::parseBorderRadius):
2784         (WebCore::CSSParser::parseAspectRatio):
2785         (WebCore::CSSParser::parseCounter):
2786         (WebCore::parseDeprecatedGradientPoint):
2787         (WebCore::parseDeprecatedGradientColorStop):
2788         (WebCore::CSSParser::parseDeprecatedGradient):
2789         (WebCore::valueFromSideKeyword):
2790         (WebCore::parseGradientColorOrKeyword):
2791         (WebCore::CSSParser::parseLinearGradient):
2792         (WebCore::CSSParser::parseRadialGradient):
2793         (WebCore::CSSParser::parseCrossfade):
2794         (WebCore::CSSParser::parseCustomFilter):
2795         (WebCore::CSSParser::parseFilter):
2796         (WebCore::CSSParser::parseFlowThread):
2797         (WebCore::CSSParser::parseRegionThread):
2798         (WebCore::CSSParser::parseTextEmphasisStyle):
2799         (WebCore::CSSParser::parseFontFeatureSettings):
2800         * css/CSSParser.h:
2801         (WebCore::CSSParser::cssValuePool):
2802         * css/CSSValuePool.cpp: Renamed from Source/WebCore/css/CSSPrimitiveValueCache.cpp.
2803         (WebCore::CSSValuePool::CSSValuePool):
2804         (WebCore::CSSValuePool::~CSSValuePool):
2805         (WebCore::CSSValuePool::createIdentifierValue):
2806         (WebCore::CSSValuePool::createColorValue):
2807         (WebCore::CSSValuePool::createValue):
2808         * css/CSSValuePool.h: Renamed from Source/WebCore/css/CSSPrimitiveValueCache.h.
2809         (WebCore::CSSValuePool::create):
2810         (WebCore::CSSValuePool::createValue):
2811         * css/mediaControlsGtk.css:
2812         (audio::-webkit-media-controls-volume-slider, video::-webkit-media-controls-volume-slider):
2813         * dom/Document.cpp:
2814         (WebCore::Document::cssValuePool):
2815         * dom/Document.h:
2816
2817 2011-12-03  Andreas Kling  <kling@webkit.org>
2818
2819         Shrink CSSValueList.
2820         <http://webkit.org/b/73732>
2821
2822         Reviewed by Antti Koivisto.
2823
2824         Packed CSSValueList::m_isSpaceSeparated into the CSSValue bit field
2825         and renamed it to m_isSpaceSeparatedValue, shrinking CSSValueList
2826         by one CPU word.
2827
2828         Also renamed CSSValue::m_isImplicit to m_isImplicitInitialValue
2829         for good measure.
2830
2831         * css/CSSInitialValue.h:
2832         (WebCore::CSSInitialValue::CSSInitialValue):
2833         * css/CSSValue.h:
2834         (WebCore::CSSValue::isImplicitInitialValue):
2835         (WebCore::CSSValue::CSSValue):
2836         * css/CSSValueList.cpp:
2837         (WebCore::CSSValueList::CSSValueList):
2838         (WebCore::CSSValueList::copy):
2839         (WebCore::CSSValueList::customCssText):
2840         * css/CSSValueList.h:
2841         (WebCore::CSSValueList::isSpaceSeparated):
2842
2843 2011-12-02  Philippe Normand  <pnormand@igalia.com>
2844
2845         [GStreamer] Fullscreen controller support for the new WebKit Fullscreen API
2846         https://bugs.webkit.org/show_bug.cgi?id=66968
2847
2848         Reviewed by Martin Robinson.
2849
2850         * GNUmakefile.am: Don't use the Quicktime fullscreen CSS anymore,
2851         it wasn't suited for GTK in the first place anyway.
2852         * platform/gtk/RenderThemeGtk.cpp:
2853         (WebCore::RenderThemeGtk::extraFullScreenStyleSheet): Simply reuse
2854         GTK CSS.
2855
2856 2011-12-03  Alejandro G. Castro  <alex@igalia.com>
2857
2858         [GTK] TextureMapperNode should not use Qt types and functions
2859         https://bugs.webkit.org/show_bug.cgi?id=73713
2860
2861         Replace qreal with double and qMin with std::min.
2862
2863         Reviewed by Noam Rosenthal.
2864
2865         * platform/graphics/texmap/TextureMapperNode.cpp:
2866         (WebCore::solveCubicBezierFunction):
2867         (WebCore::solveStepsFunction):
2868
2869 2011-12-03  Dan Winship  <danw@gnome.org>
2870
2871         [GTK] Remove lots of code that is now unnecessary after
2872         SoupRequestHTTP API changes.
2873         https://bugs.webkit.org/show_bug.cgi?id=71611
2874
2875         Reviewed by Martin Robinson.
2876
2877         No new tests; behavior is unchanged
2878
2879         * platform/network/ResourceHandleInternal.h:
2880         (WebCore::ResourceHandleInternal::ResourceHandleInternal): remove
2881         no-longer-needed fields.
2882         * platform/network/soup/ResourceHandleSoup.cpp:
2883         (WebCore::finishedCallback): remove this, and m_finished, which
2884         we no longer need to explicitly track
2885         (WebCore::statusWillBeHandledBySoup):
2886         (WebCore::soupErrorShouldCauseLoadFailure): No longer needed;
2887         SoupRequestHTTP's logic is now aligned with WebKit's.
2888         (WebCore::gotChunkCallback): remove gotChunkCallback, which
2889         is no longer needed
2890         (WebCore::startHTTPRequest):
2891         (WebCore::sendRequestCallback):
2892         (WebCore::gotHeadersCallback):
2893         (WebCore::contentSniffedCallback): merge the code from
2894         gotHeadersCallback and contentSniffedCallback into
2895         sendRequestCallback
2896         * platform/network/soup/ResourceResponseSoup.cpp:
2897         (WebCore::ResourceResponse::updateFromSoupMessage): move the
2898         sniffing override logic here
2899
2900 2011-12-03  Sheriff Bot  <webkit.review.bot@gmail.com>
2901
2902         Unreviewed, rolling out r101904.
2903         http://trac.webkit.org/changeset/101904
2904         https://bugs.webkit.org/show_bug.cgi?id=73739
2905
2906         It broke zillions of tests on all bot (Requested by
2907         Ossy_weekend on #webkit).
2908
2909         * bindings/js/JSDOMWindowCustom.cpp:
2910         (WebCore::handlePostMessage):
2911
2912 2011-12-02  Kentaro Hara  <haraken@chromium.org>
2913
2914         [Refactoring] Use join(", ", @arguments) to build a method argument string in CodeGenerator*.pm
2915         https://bugs.webkit.org/show_bug.cgi?id=73651
2916
2917         Reviewed by Darin Adler.
2918
2919         The code in CodeGenerator*.pm to build a method argument string is really dirty
2920         and error-prone. It is building an argument string incrementally judging whether
2921         ", " is necessary or not, like this:
2922
2923             my $method = ... ? "func(" : "func(a";
2924             if (...) {
2925                 $method .= $method =~ /\($/ ? "b" : ", b";
2926             }
2927             $method .= ")";
2928
2929         Alternatively, we can refactor the code as follows:
2930
2931             my $funcName = "func";
2932             my @arguments;
2933             push(@arguments, "a") if (...);
2934             push(@arguments, "b") if (...);
2935             my $method = $funcName . "(" . join(", ", @arguments) . ")";
2936
2937         This patch just refactors the code, and generated .h and .cpp files should be
2938         exactly the same as the current .h and .cpp files.
2939
2940         Tests: bindings/scripts/test/*
2941
2942         * bindings/scripts/CodeGenerator.pm:
2943         (GetterExpression):
2944         (SetterExpression):
2945         * bindings/scripts/CodeGeneratorCPP.pm:
2946         (GenerateImplementation):
2947         * bindings/scripts/CodeGeneratorGObject.pm:
2948         ():
2949         * bindings/scripts/CodeGeneratorJS.pm:
2950         (GenerateImplementation):
2951         * bindings/scripts/CodeGeneratorObjC.pm:
2952         (GenerateImplementation):
2953         * bindings/scripts/CodeGeneratorV8.pm:
2954         (GenerateNormalAttrGetter):
2955         (GenerateNormalAttrSetter):
2956
2957 2011-12-02  David Levin  <levin@chromium.org>
2958
2959         Rename WTF class from TemporarilyChange to TemporaryChange.
2960         https://bugs.webkit.org/show_bug.cgi?id=73479
2961
2962         Reviewed by Eric Seidel.
2963
2964         * ForwardingHeaders/wtf/TemporarilyChange.h: Removed.
2965         * ForwardingHeaders/wtf/TemporaryChange.h: Added.
2966         * page/FrameView.cpp:
2967         (WebCore::FrameView::forceLayoutParentViewIfNeeded):
2968         (WebCore::FrameView::layout):
2969         (WebCore::FrameView::setScrollPosition):
2970         (WebCore::FrameView::autoSizeIfEnabled):
2971
2972 2011-12-02  Armand Navabi  <armand.navabi@gmail.com>
2973
2974         ASSERT fails in updateState ACTION_DRAW case
2975         https://bugs.webkit.org/show_bug.cgi?id=73351
2976
2977         Reviewed by James Robinson.
2978
2979         Changed ASSERT in CCSchedulerStateMachine to include ( || !m_visible) as discussed in bug 
2980         report. m_commitState is set to COMMIT_STATE_WAITING_FOR_FIRST_DRAW if m_needsCommit or
2981         !m_visible, so in ACTION_DRAW the assert should have both conditions.
2982
2983         * platform/graphics/chromium/cc/CCSchedulerStateMachine.cpp:
2984         (WebCore::CCSchedulerStateMachine::updateState):
2985
2986 2011-12-02  Shawn Singh  <shawnsingh@chromium.org>
2987
2988         [chromium] Scissor rect optimization for chromium compositor
2989         https://bugs.webkit.org/show_bug.cgi?id=67341
2990
2991         Reviewed by James Robinson.
2992
2993         Mostly covered by damage tracker tests. Currently this relies on
2994         manually running layout tests, because this patch requires partial
2995         swaps that are not supported by DumpRenderTree. The feature
2996         automatically disables if partial swap is not supported.
2997
2998         * platform/graphics/chromium/LayerRendererChromium.cpp:
2999         (WebCore::LayerRendererChromium::initialize):
3000         (WebCore::LayerRendererChromium::trackDamageForAllSurfaces):
3001         (WebCore::LayerRendererChromium::drawLayersOntoRenderSurfaces):
3002         (WebCore::LayerRendererChromium::drawLayersInternal):
3003         (WebCore::LayerRendererChromium::swapBuffers):
3004         (WebCore::LayerRendererChromium::drawLayer):
3005         * platform/graphics/chromium/LayerRendererChromium.h:
3006         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
3007         (WebCore::CCSettings::CCSettings):
3008         (WebCore::LayerRendererCapabilities::LayerRendererCapabilities):
3009         * platform/graphics/chromium/cc/CCRenderSurface.cpp:
3010         (WebCore::CCRenderSurface::draw):
3011         * platform/graphics/chromium/cc/CCRenderSurface.h:
3012
3013 2011-12-02  Dmitry Lomov  <dslomov@google.com>
3014
3015         https://bugs.webkit.org/show_bug.cgi?id=73691
3016         [JSC] Implement correct order of window.postMessage arguments.
3017
3018         Reviewed by Geoffrey Garen.
3019
3020         * bindings/js/JSDOMWindowCustom.cpp:
3021         (WebCore::handlePostMessage):
3022
3023 2011-12-02  Stephen Chenney  <schenney@chromium.org>
3024
3025         REGRESSION (r91125): Polyline tool in google docs is broken
3026         https://bugs.webkit.org/show_bug.cgi?id=65796
3027
3028         Reviewed by Darin Adler.
3029
3030         Work around a bug in CoreGraphics, that caused incorrect bounds for paths
3031         consisting only of move-to elements. This causes problems in SVG, when the enormous
3032         bounds prevented the drawing of things behind.
3033
3034         Tests: svg/custom/path-moveto-only-rendering.svg
3035                svg/custom/subpaths-moveto-only-rendering.svg
3036
3037         * platform/graphics/cg/PathCG.cpp:
3038         (WebCore::PathIsEmptyOrSingleMoveTester::PathIsEmptyOrSingleMoveTester): Class to
3039         test for isEmpty accoridng ot the same rules as other platforms.
3040         (WebCore::PathIsEmptyOrSingleMoveTester::isEmpty): Query the result
3041         (WebCore::PathIsEmptyOrSingleMoveTester::testPathElement): Path iterator method
3042         (WebCore::PathHasOnlyMoveToTester::PathHasOnlyMoveToTester): Class to test whether a
3043         path contains only move-to elements, and hence should have null bounds.
3044         (WebCore::PathHasOnlyMoveToTester::hasOnlyMoveTo): Query the result
3045         (WebCore::PathHasOnlyMoveToTester::testPathElement): Path iterator method.
3046         (WebCore::Path::boundingRect): Modified to check for move-to only paths
3047         (WebCore::Path::fastBoundingRect): Modified to check for move-to only paths
3048         (WebCore::Path::isEmpty): Now uses the method that matches other platforms.
3049         (WebCore::Path::hasCurrentPoint): Now uses CGPathIsEmpty directly
3050         (WebCore::Path::transform) : Now uses CGPathIsEmpty directly
3051
3052 2011-12-02  Mihnea Ovidenie  <mihnea@adobe.com>
3053
3054         [CSSRegions]More renaming for region style rules.
3055         https://bugs.webkit.org/show_bug.cgi?id=73526
3056
3057         Reviewed by Eric Seidel.
3058
3059         Rename isRegionStyleRule() -> isRegionRule()
3060         WEBKIT_REGION_STYLE_RULE -> WEBKIT_REGION_RULE.
3061
3062         * bindings/objc/DOMCSS.mm:
3063         (kitClass):
3064         * bindings/v8/custom/V8CSSRuleCustom.cpp:
3065         (WebCore::toV8):
3066         * css/CSSGrammar.y:
3067         * css/CSSParser.cpp:
3068         (WebCore::CSSParser::createRegionRule):
3069         * css/CSSParser.h:
3070         * css/CSSRule.cpp:
3071         (WebCore::CSSRule::cssText):
3072         (WebCore::CSSRule::destroy):
3073         * css/CSSRule.h:
3074         (WebCore::CSSRule::isRegionRule):
3075         * css/CSSRule.idl:
3076         * css/CSSStyleSelector.cpp:
3077         (WebCore::CSSStyleSelector::addRegionRule):
3078         (WebCore::RuleSet::addRulesFromSheet):
3079         * css/CSSStyleSelector.h:
3080         * css/WebKitCSSRegionRule.cpp:
3081         (WebCore::WebKitCSSRegionRule::WebKitCSSRegionRule):
3082         * css/tokenizer.flex:
3083
3084 2011-12-02  Tom Sepez  <tsepez@chromium.org>
3085
3086         XSSAuditor includes more terminating characters when truncating
3087         attribute values.
3088         https://bugs.webkit.org/show_bug.cgi?id=73684
3089
3090         Reviewed by Daniel Bates.
3091
3092         * html/parser/XSSAuditor.cpp:
3093         (WebCore::isTerminatingCharacter):
3094         (WebCore::XSSAuditor::eraseDangerousAttributesIfInjected):
3095
3096 2011-12-02  Tony Chang  <tony@chromium.org>
3097
3098         Need to implement flex-flow: column-reverse
3099         https://bugs.webkit.org/show_bug.cgi?id=73504
3100
3101         Reviewed by David Hyatt.
3102
3103         We can't just change the direction of the FlexOrderIterator because we want the overflow to be
3104         on the top. We can't just position them in the reverse location since we don't know where the
3105         bottom edge is until we've layed out the flex items. So we do an extra pass, but it should be
3106         fast since we're not laying out, just moving.
3107
3108         * rendering/RenderFlexibleBox.cpp:
3109         (WebCore::RenderFlexibleBox::flowAwareBorderEnd):
3110         (WebCore::RenderFlexibleBox::flowAwarePaddingEnd):
3111         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren):
3112         (WebCore::RenderFlexibleBox::layoutColumnReverse): Do an extra pass to reposition flexitems in the reverse order.
3113         * rendering/RenderFlexibleBox.h:
3114
3115 2011-12-02  Stephen Chenney  <schenney@chromium.org>
3116
3117         Divide by zero for zero-length arcs
3118         https://bugs.webkit.org/show_bug.cgi?id=73021
3119
3120         Reviewed by Nikolas Zimmermann.
3121
3122         A zero-length path produces divide by zero, resulting in nothing being
3123         drawn. This change modifies the behavior to produce a zero-length line
3124         which will generate correct linecaps.
3125
3126         Test: svg/stroke/zero-length-arc-linecaps-rendering.svg
3127
3128         * svg/SVGPathParser.cpp:
3129         (WebCore::SVGPathParser::parseArcToSegment): Catch the case of
3130         zero-length arcs and convert them to lines (the same as would happen
3131         for zero arc radii).
3132
3133 2011-12-02  James Wei <james.wei@intel.com> & Xingnan Wang <xingnan.wang@intel.com>
3134
3135         -Implement the SSE optimization for vsmul and vadd.
3136         https://bugs.webkit.org/show_bug.cgi?id=73182
3137
3138         Reviewed by Kenneth Russell.
3139
3140         * platform/audio/VectorMath.cpp:
3141         (WebCore:VectorMath):
3142
3143 2011-12-02  David Grogan  <dgrogan@chromium.org>
3144
3145         Grant workers experimental access to IndexedDB.
3146         https://bugs.webkit.org/show_bug.cgi?id=73609
3147
3148         Reviewed by Nate Chapin.
3149
3150         No new tests - there will be chromium ui tests that depend on
3151         webkit.org/b/73297.
3152
3153         * storage/IDBFactory.cpp:
3154         (WebCore::IDBFactory::open): Call new function,
3155         IDBFactoryBackendInterface::openFromWorker.
3156         * storage/IDBFactoryBackendImpl.cpp:
3157         (WebCore::IDBFactoryBackendImpl::open):
3158         (WebCore::IDBFactoryBackendImpl::openFromWorker):
3159         (WebCore::IDBFactoryBackendImpl::openInternal):
3160         * storage/IDBFactoryBackendImpl.h:
3161         * storage/IDBFactoryBackendInterface.h:
3162         * workers/WorkerContext.cpp:
3163         (WebCore::WorkerContext::webkitIndexedDB): Stores
3164         IDBFactoryBackendInterface, implemented by IDBFactoryBackendProxy in
3165         chromium, in the WorkerContext.  For the Document case it is stored in
3166         the PageGroup.  Storing it in the WorkerContext causes more memory
3167         churn, but that should be trivial.  I don't know of any better
3168         alternatives.
3169         * workers/WorkerContext.h:
3170         * workers/WorkerContext.idl:
3171
3172 2011-12-02  Aaron Colwell  <acolwell@chromium.org>
3173
3174         Fix mixed content handling for video in Chromium by having
3175         CachedResourceLoader & SubresourceLoader use the 
3176         ResourceRequest::TargetType when determining if a RawResource can
3177         be requested.
3178         https://bugs.webkit.org/show_bug.cgi?id=72178
3179
3180         Reviewed by Adam Barth.
3181
3182         Tests: http/tests/security/mixedContent/insecure-video-in-iframe.html
3183                http/tests/security/mixedContent/insecure-video-in-main-frame.html
3184                http/tests/security/mixedContent/redirect-http-to-https-video-in-main-frame.html
3185                http/tests/security/mixedContent/redirect-https-to-http-video-in-main-frame.html
3186
3187         * loader/SubresourceLoader.cpp:
3188         (WebCore::SubresourceLoader::willSendRequest):
3189         * loader/cache/CachedRawResource.cpp:
3190         (WebCore::CachedRawResource::CachedRawResource):
3191         * loader/cache/CachedRawResource.h:
3192         * loader/cache/CachedResource.cpp:
3193         (WebCore::defaultPriorityForResourceType):
3194         (WebCore::cachedResourceTypeToTargetType):
3195         (WebCore::CachedResource::targetTypeToCachedResourceType):
3196         * loader/cache/CachedResource.h:
3197         * loader/cache/CachedResourceLoader.cpp:
3198         (WebCore::createResource):
3199         (WebCore::CachedResourceLoader::checkInsecureContent):
3200         (WebCore::CachedResourceLoader::canRequest):
3201         (WebCore::CachedResourceLoader::requestResource):
3202
3203 2011-12-02  Sheriff Bot  <webkit.review.bot@gmail.com>
3204
3205         Unreviewed, rolling out r101731.
3206         http://trac.webkit.org/changeset/101731
3207         https://bugs.webkit.org/show_bug.cgi?id=73706
3208
3209         Broke copy and paste in chromium. (Requested by dcheng on #webkit).
3210
3211         * editing/SpellChecker.cpp:
3212         (WebCore::SpellChecker::SpellChecker):
3213         (WebCore::SpellChecker::initRequest):
3214         (WebCore::SpellChecker::clearRequest):
3215         (WebCore::SpellChecker::canCheckAsynchronously):
3216         (WebCore::SpellChecker::isBusy):
3217         (WebCore::SpellChecker::isValid):
3218         (WebCore::SpellChecker::requestCheckingFor):
3219         (WebCore::SpellChecker::doRequestCheckingFor):
3220         (WebCore::SpellChecker::didCheck):
3221         * editing/SpellChecker.h:
3222
3223 2011-12-02  Fady Samuel  <fsamuel@chromium.org>
3224
3225         When page scaling is in use position:fixed has incorrect results
3226         https://bugs.webkit.org/show_bug.cgi?id=68617
3227
3228         Reviewed by Simon Fraser.
3229
3230         Add the option for position:fixed elements to be fixed to the frame
3231         instead of the layout rectangle of the document.
3232
3233         Tests: fast/repaint/fixed-in-page-scale.html
3234                fast/repaint/fixed-right-bottom-in-page-scale.html
3235                fast/repaint/fixed-right-in-page-scale.html
3236
3237         * WebCore.exp.in:
3238         * page/FrameView.cpp:
3239         (WebCore::FrameView::reset):
3240         (WebCore::FrameView::scrollXForFixedPosition):
3241         (WebCore::FrameView::scrollYForFixedPosition):
3242           If position:fixed elements are relative to the frame, disregard the
3243           drag factor.
3244         (WebCore::FrameView::setShouldLayoutFixedElementsRelativeToFrame):
3245         * page/FrameView.h:
3246         (WebCore::FrameView::shouldLayoutFixedElementsRelativeToFrame):
3247         * rendering/RenderBox.cpp:
3248         (WebCore::RenderBox::shouldLayoutFixedElementRelativeToFrame):
3249         (WebCore::RenderBox::containingBlockLogicalWidthForPositioned):
3250         (WebCore::RenderBox::containingBlockLogicalHeightForPositioned):
3251           If position:fixed elements are relative to the frame, their container
3252           is the frame instead of the layout rect of the document. 
3253           This allows proper positioning of these elements to the right and
3254           bottom.
3255         * rendering/RenderBox.h:
3256         * testing/Internals.cpp:
3257         (WebCore::Internals::setShouldLayoutFixedElementsRelativeToFrame):
3258         * testing/Internals.h:
3259         * testing/Internals.idl:
3260           Allow enabling and disabling the new behavior in layout tests.
3261
3262 2011-12-02  Benjamin Poulain  <bpoulain@apple.com>
3263
3264         Build fix for SubresourceLoader when building with Core Foundation
3265         https://bugs.webkit.org/show_bug.cgi?id=73709
3266
3267         Reviewed by David Kilzer.
3268
3269         The patch r100311 removed SubresourceClient and merged it in SubresourceLoader.
3270         Consequently, m_client does not exist anymore and there is no need to do the check
3271         before invoking didReceiveData().
3272
3273         * loader/cf/SubresourceLoaderCF.cpp:
3274         (WebCore::SubresourceLoader::didReceiveDataArray):
3275
3276 2011-12-02  Andreas Kling  <kling@webkit.org>
3277
3278         StyledElement: Simplify addCSSColor().
3279         <http://webkit.org/b/73703>
3280
3281         Reviewed by Darin Adler.
3282
3283         The Color(const String&) constructor handles both named and 3/6-digit
3284         hex colors, so there's no need to handle those separately here.
3285         Also tweaked some comments and minor things.
3286
3287         * dom/StyledElement.cpp:
3288         (WebCore::StyledElement::addCSSColor):
3289
3290 2011-12-02  Benjamin Poulain  <bpoulain@apple.com>
3291
3292         Update platform/iphone to platform/ios
3293         https://bugs.webkit.org/show_bug.cgi?id=73708
3294
3295         Reviewed by Darin Adler.
3296
3297         The platform is now best known as iOS, update the platform layer accordingly.
3298
3299         * Configurations/WebCore.xcconfig:
3300         * WebCore.gypi:
3301         * WebCore.xcodeproj/project.pbxproj:
3302         * platform/cocoa/KeyEventCocoa.mm:
3303         * platform/ios/KeyEventCodesIOS.h: Renamed from Source/WebCore/platform/iphone/KeyEventCodesIPhone.h.
3304         * platform/ios/KeyEventIOS.mm: Renamed from Source/WebCore/platform/iphone/KeyEventIPhone.mm.
3305         (WebCore::keyIdentifierForKeyEvent):
3306         (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
3307         (WebCore::PlatformKeyboardEvent::disambiguateKeyDownEvent):
3308         (WebCore::PlatformKeyboardEvent::currentCapsLockState):
3309         (WebCore::PlatformKeyboardEvent::getCurrentModifierState):
3310
3311 2011-12-02  Jonathan Backer  <backer@chromium.org>
3312
3313         [chromium] Eliminate unnecessary state on previous CL
3314         https://bugs.webkit.org/show_bug.cgi?id=73661
3315
3316         Reviewed by Kenneth Russell.
3317
3318         * platform/graphics/chromium/LayerRendererChromium.cpp:
3319         (WebCore::LayerRendererChromium::initialize):
3320         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
3321         (WebCore::CCLayerTreeHost::initialize):
3322         (WebCore::CCLayerTreeHost::didBecomeInvisibleOnImplThread):
3323         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
3324         (WebCore::CCSettings::CCSettings):
3325         (WebCore::LayerRendererCapabilities::LayerRendererCapabilities):
3326
3327 2011-12-02  Dan Bernstein  <mitz@apple.com>
3328
3329         <rdar://problem/10520670> REGRESSION (r91738): didFinishLoad is called before custom fonts have finished loading
3330         https://bugs.webkit.org/show_bug.cgi?id=73688
3331
3332         Reviewed by Darin Adler.
3333
3334         The problem was that after CSSFontFaceSource::getFontData() had scheduled a 0-delay timer to
3335         begin loading the font, but before that timer fired, the subresource loader appeared to have
3336         had no resources waiting to be loaded, and therefore didFinishLoad could be called. This change
3337         reworks the fix for <http://webkit.org/b/65123> so that while the load is still started on a
3338         0-delay timer, the subresource loader’s request count is incremented immediately, preventing
3339         it from hitting 0 while the font load is scheduled to begin. The delayed load mechanism is
3340         moved from CSSFontFaceSource into CSSFontSelector in order to safely handle the possibility of
3341         the latter being decommissioned while waiting for font loading to begin.
3342
3343         * css/CSSFontFaceSource.cpp:
3344         (WebCore::CSSFontFaceSource::CSSFontFaceSource): Removed initializer for m_loadStartTimer.
3345         (WebCore::CSSFontFaceSource::~CSSFontFaceSource): Removed stopping of m_loadStartTimer.
3346         (WebCore::CSSFontFaceSource::getFontData): Replaced code to schedule loading on a timer with
3347         a call to CSSFontSelector::beginLoadingFontSoon.
3348         * css/CSSFontFaceSource.h: Removed m_loadStartTimer and m_fontSelector member variables.
3349         * css/CSSFontSelector.cpp:
3350         (WebCore::CSSFontSelector::CSSFontSelector): Added initialized for m_beginLoadingTimer.
3351         (WebCore::CSSFontSelector::~CSSFontSelector): Added call to clearDocument(), to deal with
3352         anything remaining in m_fontsToBeginLoading at this time.
3353         (WebCore::CSSFontSelector::clearDocument): Now stops m_beginLoadingTimer and balances
3354         incrementRequestCount() calls for anything remaining in m_fontsToBeginLoading.
3355         (WebCore::CSSFontSelector::beginLoadingFontSoon): Added. Schedules the actual call to
3356         CachedFont::beginLoadingIfNeeded on a 0-delay timer, and meanwhile increments the request count
3357         on the CachedResourceLoader, which ensures that didFinishLoad will not be called while waiting
3358         for the timer to fire.
3359         (WebCore::CSSFontSelector::beginLoadTimerFired): Added. Actually calls
3360         CachedFont::beginLoadIfNeeded and balances the incrementRequestCount() made when the timer was
3361         scheduled.
3362         * css/CSSFontSelector.h:
3363
3364 2011-12-02  David Tseng  <dtseng@google.com>
3365
3366         Send an AXCheckedStateChanged notification when the aria-checked attribute changes.
3367         https://bugs.webkit.org/show_bug.cgi?id=72754
3368
3369         Reviewed by Chris Fleizach.
3370
3371         Test: accessibility/aria-checkbox-sends-notification.html
3372
3373         * accessibility/AXObjectCache.cpp:
3374         (WebCore::AXObjectCache::checkedStateChanged):
3375         * accessibility/AXObjectCache.h:
3376         * dom/Element.cpp:
3377         (WebCore::Element::updateAfterAttributeChanged):
3378         * html/HTMLInputElement.cpp:
3379         (WebCore::HTMLInputElement::setChecked):
3380
3381 2011-12-02  Grace Kloba  <klobag@chromium.org>
3382
3383         [chromium] Recycle tile-sized textures during commit to prevent reallocations
3384         https://bugs.webkit.org/show_bug.cgi?id=70645
3385
3386         Reviewed by James Robinson.
3387
3388         Currently texture request is capped by the high limit while we reclaim the
3389         textures in each commit. This triggers new tiles always allocated when scrolling.
3390         The proposal is to recycle the texture during request if the total used memory
3391         is about to exceed the reclaim limit.
3392
3393         * platform/graphics/chromium/ManagedTexture.cpp:
3394         (WebCore::ManagedTexture::reserve):
3395         * platform/graphics/chromium/TextureManager.cpp:
3396         (WebCore::TextureManager::setMemoryLimitBytes):
3397         (WebCore::TextureManager::replaceTexture):
3398         (WebCore::TextureManager::requestTexture):
3399         * platform/graphics/chromium/TextureManager.h:
3400
3401 2011-12-02  Kent Tamura  <tkent@chromium.org>
3402
3403         [Chromium] Show placeholder even if the element is focused
3404         https://bugs.webkit.org/show_bug.cgi?id=73629
3405
3406         Reviewed by Hajime Morita.
3407
3408         No new tests. Need to update some existing placeholder tests.
3409
3410         * rendering/RenderThemeChromiumMac.h: Add shouldShowPlaceholderWhenFocused().
3411         * rendering/RenderThemeChromiumMac.mm:
3412         (WebCore::RenderThemeChromiumMac::shouldShowPlaceholderWhenFocused):
3413         Returns true.
3414         * rendering/RenderThemeChromiumSkia.cpp:
3415         (WebCore::RenderThemeChromiumSkia::shouldShowPlaceholderWhenFocused): ditto.
3416         * rendering/RenderThemeChromiumSkia.h: Add shouldShowPlaceholderWhenFocused().
3417
3418 2011-12-02  Kent Tamura  <tkent@chromium.org>
3419
3420         [Lion][Windows] Both of placeholder and input text are shown in <input type=number>
3421         https://bugs.webkit.org/show_bug.cgi?id=73615
3422
3423         Reviewed by Joseph Pecoraro.
3424
3425         Placeholder visibility was checked by HTMLInputElement::value
3426         emptiness. It should be innerTextValue emptiness because it is
3427         possible that a number field has empty HTMLInputElement::value and
3428         non-empty innerTextValue.
3429
3430         Tests: fast/forms/number/number-placeholder-with-unacceptable-value.html
3431
3432         * html/HTMLInputElement.cpp:
3433         (WebCore::HTMLInputElement::updateInnerTextValue):
3434         We should update placeholder visiblity when the innerTextValue is updated.
3435         (WebCore::HTMLInputElement::subtreeHasChanged): ditto.
3436         (WebCore::HTMLInputElement::setSuggestedValue):
3437         We don't need to call updatePlaceholderVisibility() because updateInnerTextValue() calls it.
3438         (WebCore::HTMLInputElement::setValueFromRenderer):
3439         We don't need to call updatePlaceholderVisibility() because subtreeHasChanged() calls it.
3440         * html/HTMLInputElement.h: Checks innerTextValue emptiness.
3441         * html/TextFieldInputType.cpp:
3442         (WebCore::TextFieldInputType::setValue):
3443         We don't need to call updatePlaceholderVisibility() because updateInnerTextValue() calls it.
3444
3445 2011-12-01  Alok Priyadarshi  <alokp@chromium.org>
3446
3447         [chromium] CCLayerQuad does not return FloatQuad in correct order
3448         https://bugs.webkit.org/show_bug.cgi?id=73247
3449
3450         Reviewed by James Robinson.
3451
3452         Returned the FloatQuad coordinates in correct order.
3453         
3454         Covered by new unit tests in CCLayerQuadTest.cpp.
3455
3456         * platform/graphics/chromium/cc/CCLayerQuad.cpp:
3457         (WebCore::CCLayerQuad::floatQuad):
3458
3459 2011-12-02  Sheriff Bot  <webkit.review.bot@gmail.com>
3460
3461         Unreviewed, rolling out r101833.
3462         http://trac.webkit.org/changeset/101833
3463         https://bugs.webkit.org/show_bug.cgi?id=73678
3464
3465         test_expectations file invalid: run Tools/Scripts/new-run-
3466         webkit-tests --lint-test-files (Requested by scheib on
3467         #webkit).
3468
3469         * platform/graphics/chromium/cc/CCLayerQuad.cpp:
3470         (WebCore::CCLayerQuad::floatQuad):
3471
3472 2011-12-02  Alok Priyadarshi  <alokp@chromium.org>
3473
3474         [chromium] CCLayerQuad does not return FloatQuad in correct orientation
3475         https://bugs.webkit.org/show_bug.cgi?id=73247
3476
3477         Reviewed by James Robinson.
3478
3479         Returned the FloatQuad coordinates in correct order.
3480         
3481         Covered by new unit tests in CCLayerQuadTest.cpp.
3482
3483         * platform/graphics/chromium/cc/CCLayerQuad.cpp:
3484         (WebCore::CCLayerQuad::floatQuad):
3485
3486 2011-12-01  Dmitry Lomov  <dslomov@google.com>
3487
3488         https://bugs.webkit.org/show_bug.cgi?id=73589
3489         [V8][Chromium] Adjust postMessage to the latest "implementation-ready" spec.
3490         - postMessage should support transfer of MessagePorts
3491         - the order of arguments to Window::postMessage and Window::webkitPostMessage should be (msg, targetOrigin [, transfer])
3492
3493         Reviewed by David Levin.
3494
3495         * bindings/v8/custom/V8DOMWindowCustom.cpp:
3496         (WebCore::handlePostMessageCallback):
3497         * bindings/v8/custom/V8DedicatedWorkerContextCustom.cpp:
3498         (WebCore::handlePostMessageCallback):
3499         * bindings/v8/custom/V8MessagePortCustom.cpp:
3500         (WebCore::handlePostMessageCallback):
3501         * bindings/v8/custom/V8WorkerCustom.cpp:
3502         (WebCore::handlePostMessageCallback):
3503
3504 2011-12-02  Enrica Casucci  <enrica@apple.com>
3505
3506         https://bugs.webkit.org/show_bug.cgi?id=73497
3507         This is a followup to the patch submitted for the bug above.
3508         Tha patch