1beb98b1b7382919a63cfae308dd5cf5416a83bd
[WebKit.git] / Source / WebCore / ChangeLog
1 2011-12-14  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
2
3         [Qt] Get rid of layering violation in PluginViewQt
4
5         PluginViewQt has a layering violation in relying on QWebPagePrivate for
6         the check if running under DRT. We remove this and add a specific flag
7         in the PluginView for this check, enabled from DRTSupport. This isn't
8         pretty, but an improvement over what's currently there.
9
10         Reviewed by Simon Hausmann.
11
12         * plugins/PluginView.h:
13         * plugins/qt/PluginViewQt.cpp:
14         (WebCore::PluginView::updatePluginWidget):
15         (WebCore::setXKeyEventSpecificFields):
16
17 2011-12-14  Vsevolod Vlasov  <vsevik@chromium.org>
18
19         Web Inspector: Console should show network messages origins.
20         https://bugs.webkit.org/show_bug.cgi?id=74521
21
22         Reviewed by Pavel Feldman.
23
24         * inspector/front-end/ConsoleMessage.js:
25         (WebInspector.ConsoleMessageImpl.prototype._formatMessage):
26
27 2011-12-15  Rakesh KN  <rakesh.kn@motorola.com>
28
29         "user-select none" causes selection to incorrectly escape from clicked container
30         https://bugs.webkit.org/show_bug.cgi?id=57289
31
32         Reviewed by Ryosuke Niwa.
33
34         Not selecting the nearest word from the target node if target node has -webkit-user-select:none
35
36         Test: fast/events/mouse-double-triple-click-should-not-select-next-node-for-user-select-none.html
37
38         * page/EventHandler.cpp:
39         (WebCore::EventHandler::updateSelectionForMouseDownDispatchingSelectStart):
40         If target node has webkit-user-select:none style then do not update the selection.
41
42 2011-12-13  Andrey Kosyakov  <caseq@chromium.org>
43
44         Web Inspector: Generated HAR is missing pages.startedDateTime
45         https://bugs.webkit.org/show_bug.cgi?id=74188
46
47         Reviewed by Pavel Feldman.
48
49         * inspector/front-end/HAREntry.js:
50         (WebInspector.HARLog.prototype._buildPages):
51         * inspector/front-end/NetworkLog.js:
52         (WebInspector.NetworkLog):
53         (WebInspector.NetworkLog.prototype.get mainResourceStartTime):
54         (WebInspector.NetworkLog.prototype._mainFrameNavigated):
55         * inspector/front-end/NetworkPanel.js:
56         (WebInspector.NetworkLogView.prototype._updateSummaryBar):
57
58 2011-12-15  Kenichi Ishibashi  <bashi@chromium.org>
59
60         Supports Unicode variation selector
61         https://bugs.webkit.org/show_bug.cgi?id=50999
62
63         Reviewed by Nikolas Zimmermann.
64
65         Adds SimpleFontData::updateGlyphWithVariationSelector() which substitutes the
66         glyph in question based on the selector. WidthIterator::advance() calls it
67         when an unicode variation selector follows the character.
68
69         Test: fast/text/unicode-variation-selector.html
70
71         * platform/graphics/SimpleFontData.h: Added updateGlyphWithVariationSelector().
72         * platform/graphics/SurrogatePairAwareTextIterator.cpp:
73         (WebCore::isUnicodeBMPVariationSelector): Added.
74         (WebCore::isUnicodeSupplementaryVariationSelector): Added.
75         (WebCore::SurrogatePairAwareTextIterator::hasTrailingVariationSelector): Added.
76         * platform/graphics/SurrogatePairAwareTextIterator.h:
77         * platform/graphics/WidthIterator.cpp:
78         (WebCore::WidthIterator::advance): Changed to detect variation selectors.
79         * platform/graphics/chromium/SimpleFontDataChromiumWin.cpp:
80         (WebCore::SimpleFontData::updateGlyphWithVariationSelector): Added.
81         * platform/graphics/chromium/SimpleFontDataLinux.cpp:
82         (WebCore::SimpleFontData::updateGlyphWithVariationSelector): Ditto.
83         * platform/graphics/freetype/SimpleFontDataFreeType.cpp:
84         (WebCore::SimpleFontData::updateGlyphWithVariationSelector): Ditto.
85         * platform/graphics/mac/SimpleFontDataMac.mm:
86         (WebCore::decomposeToUTF16): Ditto.
87         (WebCore::SimpleFontData::updateGlyphWithVariationSelector): Ditto.
88         * platform/graphics/pango/SimpleFontDataPango.cpp:
89         (WebCore::SimpleFontData::updateGlyphWithVariationSelector): Ditto.
90         * platform/graphics/qt/SimpleFontDataQt.cpp:
91         (WebCore::SimpleFontData::updateGlyphWithVariationSelector): Ditto.
92         * platform/graphics/win/SimpleFontDataWin.cpp:
93         (WebCore::SimpleFontData::updateGlyphWithVariationSelector): Ditto.
94         * platform/graphics/wince/SimpleFontDataWinCE.cpp:
95         (WebCore::SimpleFontData::updateGlyphWithVariationSelector): Ditto.
96         * platform/graphics/wx/SimpleFontDataWx.cpp:
97         (WebCore::SimpleFontData::updateGlyphWithVariationSelector): Ditto.
98
99 2011-12-15  Alexander Pavlov  <apavlov@chromium.org>
100
101         [v8] Expose the "filter" property in V8CSSStyleDeclaration
102         https://bugs.webkit.org/show_bug.cgi?id=73426
103
104         Reviewed by Adam Barth.
105
106         Test: fast/css/style-enumerate-properties.html
107
108         The "filter" CSS property used to be masked to be compliant with JSC, but JSC has supported
109         this property for quite a while.
110
111         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp:
112         (WebCore::hasCSSPropertyNamePrefix): clean up WTF prefixes
113         (WebCore::cssPropertyInfo): remove the "wasFilter" flag
114         (WebCore::V8CSSStyleDeclaration::namedPropertyEnumerator): remove the "filter" check
115         (WebCore::V8CSSStyleDeclaration::namedPropertyGetter): return the "filter" value as v8String
116
117 2011-12-15  Hajime Morrita  <morrita@chromium.org>
118
119         Unreviewed build fix attempt for Chromium Mac.
120
121         * page/PerformanceTiming.h:
122
123 2011-12-15  Alexander Pavlov  <apavlov@chromium.org>
124
125         Unreviewed, build fix after r102906 (poor merge).
126
127         * inspector/front-end/ProfileView.js:
128         (WebInspector.CPUProfileType.prototype.buttonClicked):
129
130 2011-12-15  Vsevolod Vlasov  <vsevik@chromium.org>
131
132         Unreviewed revert of r102696 ([Navigation Timing] Use monotonicallyIncreasingTime() instead of currentTime()).
133         Breaks inspector's network panel timeline on chromium.
134
135         * CMakeLists.txt:
136         * GNUmakefile.list.am:
137         * Target.pri:
138         * WebCore.gypi:
139         * WebCore.vcproj/WebCore.vcproj:
140         * WebCore.xcodeproj/project.pbxproj:
141         * dom/Document.cpp:
142         (WebCore::Document::setReadyState):
143         (WebCore::Document::finishedParsing):
144         * inspector/InspectorInstrumentation.cpp:
145         (WebCore::InspectorInstrumentation::didFinishLoadingImpl):
146         * inspector/InspectorResourceAgent.cpp:
147         (WebCore::buildObjectForTiming):
148         (WebCore::buildObjectForResourceResponse):
149         (WebCore::buildObjectForCachedResource):
150         (WebCore::InspectorResourceAgent::willSendRequest):
151         (WebCore::InspectorResourceAgent::didReceiveResponse):
152         (WebCore::InspectorResourceAgent::didLoadResourceFromMemoryCache):
153         * loader/DocumentLoadTiming.cpp: Removed.
154         * loader/DocumentLoadTiming.h:
155         (WebCore::DocumentLoadTiming::DocumentLoadTiming):
156         * loader/FrameLoader.cpp:
157         (WebCore::FrameLoader::stopLoading):
158         (WebCore::FrameLoader::commitProvisionalLoad):
159         (WebCore::FrameLoader::continueLoadAfterWillSubmitForm):
160         (WebCore::FrameLoader::loadProvisionalItemFromCachedPage):
161         * loader/MainResourceLoader.cpp:
162         (WebCore::MainResourceLoader::continueAfterNavigationPolicy):
163         (WebCore::MainResourceLoader::willSendRequest):
164         (WebCore::MainResourceLoader::didReceiveData):
165         (WebCore::MainResourceLoader::didFinishLoading):
166         (WebCore::MainResourceLoader::load):
167         * page/DOMWindow.cpp:
168         (WebCore::DOMWindow::dispatchLoadEvent):
169         (WebCore::DOMWindow::dispatchTimedEvent):
170         * page/DOMWindow.h:
171         * page/PerformanceNavigation.cpp:
172         (WebCore::PerformanceNavigation::redirectCount):
173         * page/PerformanceTiming.cpp:
174         (WebCore::getPossiblySkewedTimeInKnownRange):
175         (WebCore::PerformanceTiming::navigationStart):
176         (WebCore::PerformanceTiming::unloadEventStart):
177         (WebCore::PerformanceTiming::unloadEventEnd):
178         (WebCore::PerformanceTiming::redirectStart):
179         (WebCore::PerformanceTiming::redirectEnd):
180         (WebCore::PerformanceTiming::fetchStart):
181         (WebCore::PerformanceTiming::responseEnd):
182         (WebCore::PerformanceTiming::domLoading):
183         (WebCore::PerformanceTiming::domInteractive):
184         (WebCore::PerformanceTiming::domContentLoadedEventStart):
185         (WebCore::PerformanceTiming::domContentLoadedEventEnd):
186         (WebCore::PerformanceTiming::domComplete):
187         (WebCore::PerformanceTiming::loadEventStart):
188         (WebCore::PerformanceTiming::loadEventEnd):
189         (WebCore::PerformanceTiming::resourceLoadTimeRelativeToAbsolute):
190         * page/PerformanceTiming.h:
191         * platform/network/ResourceLoadTiming.cpp: Removed.
192         * platform/network/ResourceLoadTiming.h:
193
194 2011-12-15  Alexander Pavlov  <apavlov@chromium.org>
195
196         Unreviewed, fix Closure compiler warnings after r102905.
197
198         * inspector/front-end/CSSStyleModel.js: Add JSDoc annotations
199
200 2011-12-14  Alexander Pavlov  <apavlov@chromium.org>
201
202         Web Inspector: make ProfilesPanel scale as the number of ProfileTypes grows
203         https://bugs.webkit.org/show_bug.cgi?id=74391
204
205         Reviewed by Pavel Feldman.
206
207         Whenever a profile is started, this change disables all profile recording buttons, except the one
208         that correponds to the running profile. Once the profiling is finished, all buttons get enabled back again.
209
210         * English.lproj/localizedStrings.js:
211         * inspector/front-end/ProfileView.js:
212         (WebInspector.CPUProfileView.profileCallback):
213         (WebInspector.CPUProfileType.prototype.get buttonTooltip):
214         (WebInspector.CPUProfileType.prototype.get buttonStyle):
215         (WebInspector.CPUProfileType.prototype.buttonClicked):
216         * inspector/front-end/ProfilesPanel.js:
217         (WebInspector.ProfilesPanel.prototype.get statusBarItems.clickHandler):
218         (WebInspector.ProfilesPanel.prototype.get statusBarItems):
219         (WebInspector.ProfilesPanel.prototype._addProfileHeader):
220         (WebInspector.ProfilesPanel.prototype.updateProfileTypeButtons):
221         (WebInspector.ProfilesPanel.prototype._updateInterface):
222         (WebInspector.ProfilesPanel.prototype.setRecordingProfile):
223         (WebInspector.ProfilesPanel.prototype.takeHeapSnapshot):
224         (WebInspector.ProfilesPanel.prototype._reportHeapSnapshotProgress):
225         (WebInspector.ProfilerDispatcher.prototype.setRecordingProfile):
226         * inspector/front-end/inspector.css:
227         (.record-cpu-profile-status-bar-item .glyph):
228         (.record-cpu-profile-status-bar-item.toggled-on .glyph):
229
230 2011-12-15  Alexander Pavlov  <apavlov@chromium.org>
231
232         Web Inspector: [Styles] Update selected DOM element styles whenever applicable media queries change
233         https://bugs.webkit.org/show_bug.cgi?id=74292
234
235         The change introduces and handles in the frontend a new event type for the CSS domain,
236         "mediaQueryResultChanged", which gets fired every time a viewport-dependent media feature
237         changes its value. This allows users to see live changes of the (media-dependent) matched
238         rules for inspected elements.
239
240         Reviewed by Pavel Feldman.
241
242         * inspector/CodeGeneratorInspector.py:
243         (DomainNameFixes):
244         * inspector/Inspector.json:
245         * inspector/InspectorCSSAgent.cpp:
246         (WebCore::InspectorCSSAgent::InspectorCSSAgent):
247         (WebCore::InspectorCSSAgent::setFrontend):
248         (WebCore::InspectorCSSAgent::clearFrontend):
249         (WebCore::InspectorCSSAgent::restore):
250         (WebCore::InspectorCSSAgent::enable):
251         (WebCore::InspectorCSSAgent::disable):
252         (WebCore::InspectorCSSAgent::mediaQueryResultChanged):
253         * inspector/InspectorCSSAgent.h:
254         * inspector/InspectorInstrumentation.cpp:
255         (WebCore::InspectorInstrumentation::mediaQueryResultChangedImpl):
256         * inspector/InspectorInstrumentation.h:
257         (WebCore::InspectorInstrumentation::mediaQueryResultChanged):
258         * inspector/front-end/CSSStyleModel.js:
259         (WebInspector.CSSStyleModel):
260         (WebInspector.CSSStyleModel.prototype.mediaQueryResultChanged):
261         (WebInspector.CSSDispatcher):
262         (WebInspector.CSSDispatcher.prototype.mediaQueryResultChanged):
263         * inspector/front-end/MetricsSidebarPane.js:
264         (WebInspector.MetricsSidebarPane):
265         (WebInspector.MetricsSidebarPane.prototype._styleSheetOrMediaQueryResultChanged):
266         * inspector/front-end/StylesSidebarPane.js:
267         (WebInspector.StylesSidebarPane):
268         (WebInspector.StylesSidebarPane.prototype._styleSheetOrMediaQueryResultChanged):
269         * page/FrameView.cpp:
270         (WebCore::FrameView::layout):
271
272 2011-12-14  Vsevolod Vlasov  <vsevik@chromium.org>
273
274         Web Inspector: [Regression] Network manager fails to show resource type and MIME type in incorrect MIME type console message.
275         https://bugs.webkit.org/show_bug.cgi?id=74516
276
277         Reviewed by Pavel Feldman.
278
279         Test: http/tests/inspector/network/script-as-text-loading.html
280
281         * inspector/front-end/ConsoleMessage.js:
282         (WebInspector.ConsoleMessageImpl.prototype._formatMessage):
283         * inspector/front-end/NetworkManager.js:
284         (WebInspector.NetworkDispatcher.prototype._updateResourceWithResponse):
285
286 2011-11-03  Kent Tamura  <tkent@chromium.org>
287
288         A spin button changes the value incorrectly if it is clicked after touch events.
289         https://bugs.webkit.org/show_bug.cgi?id=71181
290
291         Reviewed by Ryosuke Niwa.
292
293         SpinButtonElement assumed setHovered(true) was always called before a
294         mousemove event in the element. It is not true for touch events.
295
296         We should not reset m_upDownState to Indetermiante in setHovered(true),
297         and should reset it when the mouse pointer moves out.
298
299         This change fixes the flakiness of fast/forms/input-step-as-double.html.
300
301         Test: fast/events/touch/touch-before-pressing-spin-button.html
302
303         * html/shadow/TextControlInnerElements.cpp:
304         (WebCore::SpinButtonElement::defaultEventHandler):
305         Add an assertion that m_upDownState should not be Indetermiante.
306         Reset m_upDownState to Indeterminate when the mouse pointer moves out
307         from the element.
308         (WebCore::SpinButtonElement::setHovered):
309         Reset m_upDownState to Indeterminate when the element becomes unhovered.
310
311 2011-12-14  Lucas Forschler  <lforschler@apple.com>
312     
313         https://bugs.webkit.org/show_bug.cgi?id=74543
314         Add CSS*.cpp to a new CSSAllInOne.cpp file with two exceptions:
315             CSSProperty.cpp
316             CSSPrimitiveValue.cpp
317         Adding these two broke things with a templates problem that was not easily fixable.
318
319         Reviewed by Steve Falkenburg.
320
321         * WebCore.vcproj/WebCore.vcproj:
322         * css/CSSAllInOne.cpp: Added.
323
324 2011-12-14  Tim Horton  <timothy_horton@apple.com>
325
326         Generated images should respect the accelerated state of the context they're going to be drawn into
327         https://bugs.webkit.org/show_bug.cgi?id=74577
328         <rdar://problem/10584392>
329
330         Reviewed by Simon Fraser.
331
332         The tiled code path for GeneratorGeneratedImage and CrossfadeGeneratedImage blindly creates
333         an unaccelerated ImageBuffer. Instead, take into account the accelerated state of the destination context.
334
335         No new tests, as this is a simple performance improvement.
336
337         * platform/graphics/CrossfadeGeneratedImage.cpp:
338         (WebCore::CrossfadeGeneratedImage::drawPattern):
339         * platform/graphics/GeneratorGeneratedImage.cpp:
340         (WebCore::GeneratorGeneratedImage::drawPattern):
341
342 2011-12-14  Ilya Tikhonovsky  <loislo@chromium.org>
343
344         Web Inspector: cleanup unused variable introduced at r102803
345
346         * inspector/front-end/NetworkManager.js:
347         (WebInspector.NetworkManager.prototype.enableResourceTracking):
348         (WebInspector.NetworkManager.prototype.disableResourceTracking):
349
350 2011-12-14  Wei James  <james.wei@intel.com>
351
352         fast path to accelerate processing in AudioBus::processWithGainFromMonoStereo
353         https://bugs.webkit.org/show_bug.cgi?id=74054
354
355         Reviewed by Kenneth Russell.
356
357         Avoid de-zippering when the gain has converged on the targetGain. 
358         It can get about 75% performance gain at most when all frames don't need
359         de-zippering.
360
361         * platform/audio/AudioBus.cpp:
362         (WebCore::AudioBus::processWithGainFromMonoStereo):
363
364 2011-12-14  Adam Klein  <adamk@chromium.org>
365
366         Optimize MutationObserverInterestGroup construction
367         https://bugs.webkit.org/show_bug.cgi?id=74563
368
369         Reviewed by Ojan Vafai.
370
371         Inline MutationObserverInterestGroup's creation methods and fix an
372         accidental pass-by-value in an attempt to further reduce the CPU
373         footprint of MutationObservers.
374
375         No new tests, refactor only.
376
377         * dom/WebKitMutationObserver.cpp:
378         (WebCore::MutationObserverInterestGroup::MutationObserverInterestGroup): Pass observers HashMap by reference.
379         * dom/WebKitMutationObserver.h:
380         (WebCore::MutationObserverInterestGroup::createForChildListMutation): Inline.
381         (WebCore::MutationObserverInterestGroup::createForCharacterDataMutation): Inline.
382         (WebCore::MutationObserverInterestGroup::createForAttributesMutation): Inline.
383         (WebCore::MutationObserverInterestGroup::hasOldValue): Remove spurious inline keyword.
384
385 2011-12-14  Dominic Mazzoni  <dmazzoni@google.com>
386
387         Seeing crash in DRT after loading-iframe-sends-notification.html land
388         https://bugs.webkit.org/show_bug.cgi?id=72624
389
390         When an iframe finishes loading, send an accessibility notification
391         on the renderer, rather than on a parent node. The only reason it was
392         being posted on a parent before was because there was no way to detect
393         that in a test. This is simpler and now covered by the test.
394
395         Reviewed by Chris Fleizach.
396
397         Updates existing test:
398         accessibility/loading-iframe-sends-notification.html
399
400         * dom/Document.cpp:
401         (WebCore::Document::implicitClose):
402
403 2011-12-14  Nat Duca  <nduca@chromium.org>
404
405         [chromium] Add inhibitDraw to CCScheduler and drop root impl to prevent background flash on tab restore
406         https://bugs.webkit.org/show_bug.cgi?id=74351
407
408         Reviewed by James Robinson.
409
410         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
411         (WebCore::CCLayerTreeHost::setNeedsCommit):
412         (WebCore::CCLayerTreeHost::didBecomeInvisibleOnImplThread):
413         * platform/graphics/chromium/cc/CCScheduler.cpp:
414         (WebCore::CCScheduler::getNextAction):
415         (WebCore::CCScheduler::processScheduledActions):
416         * platform/graphics/chromium/cc/CCScheduler.h:
417         * platform/graphics/chromium/cc/CCSchedulerStateMachine.cpp:
418         (WebCore::CCSchedulerStateMachine::CCSchedulerStateMachine):
419         (WebCore::CCSchedulerStateMachine::nextAction):
420         * platform/graphics/chromium/cc/CCSchedulerStateMachine.h:
421         (WebCore::CCSchedulerStateMachine::setInhibitDraw):
422         * platform/graphics/chromium/cc/CCThreadProxy.cpp:
423         (WebCore::CCThreadProxy::setVisibleOnImplThread):
424         (WebCore::CCThreadProxy::inhibitDraw):
425         * platform/graphics/chromium/cc/CCThreadProxy.h:
426
427 2011-12-14  Ken Buchanan  <kenrb@chromium.org>
428
429         Crash due to incorrect parsing of isolates
430         https://bugs.webkit.org/show_bug.cgi?id=74311
431         When <bdi> content is wrapped, all hell breaks loose
432         https://bugs.webkit.org/show_bug.cgi?id=74396
433
434         Reviewed by Eric Seidel.
435
436         When an isolate was encountered during run layout, the entire isolate
437         would be parsed, even if the run started in the middle of the isolate.
438         This would sometimes cause parts of the isolate to be added multiple
439         times as runs. This patch marks the starting position within the
440         isolate so nothing is parsed twice.
441
442         This patch changes appendRun() so that when a run is added that is
443         inside an isolate, it saves the start position of the run rather than
444         the root. This allows constructBidiRuns() to resume parsing the
445         isolate from the correct position.
446
447         The change to RenderBox partially reverts a previous change I had
448         done. It makes sense to screen for the condition, as was previously
449         the case.
450
451         This patch does not add the test case from 74396 because a separate
452         bug is preventing it from rendering correctly.
453
454         * rendering/InlineIterator.h:
455         (WebCore::addPlaceholderRunForIsolatedInline)
456         (WebCore::IsolateTracker::addFakeRunIfNecessary)
457         (WebCore::InlineBidiResolver::appendRun)
458         * rendering/RenderBlockLineLayout.cpp:
459         (WebCore::RenderBlockLineLayout::constructBidiRuns)
460         * rendering/RenderBox.cpp:
461         (WebCore::RenderBox::positionLineBox)
462
463 2011-12-14  Jing Zhao  <jingzhao@chromium.org>
464
465         Opening two popup menus by dispatchEvent() makes problems.
466         https://bugs.webkit.org/show_bug.cgi?id=73304
467
468         Reviewed by Kent Tamura.
469
470         By using element.dispatchEvent(), a user written script can open two
471         popup menus, which causes various problems in different platforms.
472
473         Add a hasOpenedPopup() method in ChromeClient and a wrapper in Chrome.
474         In RenderMenuList::showPopup(), check if there is an opened popup menu
475         before opening a new popup menu.
476
477         Test: fast/forms/select-popup-crash.html
478
479         * loader/EmptyClients.h: Overrides hasOpenedPopup().
480         (WebCore::EmptyChromeClient::hasOpenedPopup): Returns false as a default case.
481         * page/Chrome.cpp:
482         (WebCore::Chrome::hasOpenedPopup): Calls ChromeClient::hasOpenedPopup().
483         * page/Chrome.h: Declares hasOpenedPopup().
484         * page/ChromeClient.h: Declares hasOpenedPopup() as a pure virtual function.
485         * rendering/RenderMenuList.cpp:
486         (WebCore::RenderMenuList::showPopup): Calls Chrome::hasOpenedPopup() before opening a new popup menu.
487
488 2011-12-14  Tony Chang  <tony@chromium.org>
489
490         Clean up style in CSSStyleSelector.cpp
491         https://bugs.webkit.org/show_bug.cgi?id=74548
492
493         Reviewed by Ojan Vafai.
494
495         * css/CSSStyleSelector.cpp:
496         (WebCore::CSSStyleSelector::styleForElement):
497         (WebCore::CSSStyleSelector::pseudoStyleForElement):
498
499 2011-12-14  Kenneth Russell  <kbr@google.com>
500
501         Unreviewed, rolling out r102794.
502         http://trac.webkit.org/changeset/102794
503         https://bugs.webkit.org/show_bug.cgi?id=74220
504
505         Reapplying patch since it is not the cause of the problems
506         described in bug 74220.
507
508         * bindings/v8/V8Proxy.cpp:
509         (WebCore::V8Proxy::reportUnsafeAccessTo):
510         * bindings/v8/V8Proxy.h:
511         * bindings/v8/custom/V8CustomXPathNSResolver.cpp:
512         (WebCore::V8CustomXPathNSResolver::lookupNamespaceURI):
513
514 2011-12-14  Sam Weinig  <weinig@apple.com>
515
516         Remove whitespace from InheritedPropertySheets attributes in
517         vsprops files to appease the Visual Studio project migrator.
518
519         Reviewed by Adam Roben.
520
521         * WebCore.vcproj/QTMovieWinDebug.vsprops:
522         * WebCore.vcproj/QTMovieWinDebugAll.vsprops:
523         * WebCore.vcproj/QTMovieWinDebugCairoCFLite.vsprops:
524         * WebCore.vcproj/QTMovieWinProduction.vsprops:
525         * WebCore.vcproj/QTMovieWinRelease.vsprops:
526         * WebCore.vcproj/QTMovieWinReleaseCairoCFLite.vsprops:
527         * WebCore.vcproj/WebCoreDebug.vsprops:
528         * WebCore.vcproj/WebCoreDebugAll.vsprops:
529         * WebCore.vcproj/WebCoreDebugCairoCFLite.vsprops:
530         * WebCore.vcproj/WebCoreProduction.vsprops:
531         * WebCore.vcproj/WebCoreRelease.vsprops:
532         * WebCore.vcproj/WebCoreReleaseCairoCFLite.vsprops:
533
534 2011-12-14  Enrica Casucci  <enrica@apple.com>
535
536         One more attempt to fix the release build (hopefully the last)
537
538         Unreviewed.
539
540         * editing/ReplaceSelectionCommand.cpp: Added NodeRenderStyle.h
541
542 2011-12-14  Kenneth Russell  <kbr@google.com>
543
544         Unreviewed, rolling out r102816.
545         http://trac.webkit.org/changeset/102816
546         https://bugs.webkit.org/show_bug.cgi?id=74415
547
548         Implicated in font-related crashes on Chromium canaries.
549
550         * platform/graphics/chromium/FontChromiumWin.cpp:
551         (WebCore::TransparencyAwareFontPainter::TransparencyAwareGlyphPainter::drawGlyphs):
552         (WebCore::Font::drawGlyphs):
553         * platform/graphics/chromium/FontPlatformDataChromiumWin.cpp:
554         (WebCore::FontPlatformData::FontPlatformData):
555         (WebCore::FontPlatformData::operator=):
556         (WebCore::FontPlatformData::~FontPlatformData):
557         * platform/graphics/chromium/FontPlatformDataChromiumWin.h:
558         (WebCore::FontPlatformData::size):
559         (WebCore::FontPlatformData::hash):
560         * platform/graphics/skia/SkiaFontWin.cpp:
561         (WebCore::setupPaintForFont):
562         (WebCore::paintSkiaText):
563         * platform/graphics/skia/SkiaFontWin.h:
564
565 2011-12-14  Simon Fraser  <simon.fraser@apple.com>
566
567         Filter amounts should accept percentages
568         https://bugs.webkit.org/show_bug.cgi?id=74531
569
570         Reviewed by Chris Marrin.
571         
572         Support percentage arguments for some filter functions, using the FPercent flag
573         to validUnit(). Fix CSSStyleSelector::createFilterOperations() to do the divide by 100
574         for percentages.
575         
576         Replaced isValidFilterArgument(), which just tested arguments one by one for validity, with
577         parseBuiltinFilterArguments() which tests and creates the CSSValues at the same time, which
578         is a little more efficient. It also allows filter-specific behavior to be more localized in this
579         method.
580
581         Covered by existing tests.
582
583         * css/CSSParser.cpp:
584         (WebCore::CSSParser::parseBuiltinFilterArguments):
585         (WebCore::CSSParser::parseFilter):
586         * css/CSSParser.h:
587         * css/CSSStyleSelector.cpp:
588         (WebCore::CSSStyleSelector::createFilterOperations):
589
590 2011-12-14  Enrica Casucci  <enrica@apple.com>
591
592         Build fix.
593
594         Unreviewed.
595
596         * editing/ReplaceSelectionCommand.cpp: Added include RenderStyle.h
597
598 2011-12-14  Hajime Morrita  <morrita@chromium.org>
599
600         JS_INLINE and WTF_INLINE should be visible from WebCore
601         https://bugs.webkit.org/show_bug.cgi?id=73191
602
603         Reviewed by Kevin Ollivier.
604
605         - Moved export related definitions from config.h
606           to ExportMacros.h, JSExportMacros.h and PlatformExportMacros.h
607         - Added forwarding headers which are referred from config.h
608
609         No new tests. Only build related changes.
610
611         * ForwardingHeaders/runtime/JSExportMacros.h: Added.
612         * ForwardingHeaders/wtf/ExportMacros.h: Added.
613         * WebCore.xcodeproj/project.pbxproj:
614         * config.h:
615         * platform/PlatformExportMacros.h: Copied from Source/JavaScriptCore/wtf/ExportMacros.h.
616
617 2011-12-14  Enrica Casucci  <enrica@apple.com>
618
619         Need a way to produce leaner markup when pasting a fragment containing verbose markup
620         https://bugs.webkit.org/show_bug.cgi?id=74514
621         <rdar://problem/10208653>
622
623         Reviewed by Ryosuke Niwa.
624
625         This patch is another step in the direction of reducing the verbosity of the markup
626         produced with editing operations.
627         After the copied fragment is inserted in the document, it is analyzed to remove all
628         the elements that don't contribute to the style. The decision is made comparing the
629         render styles. As part of the cleanup, unstyled divs with single child element are
630         removed. The logic to determine the blocks that can be removed is the same used in
631         DeleteSelectionCommand and has been moved in CompositeEditCommand.
632         
633         Test: editing/pasteboard/paste-and-sanitize.html
634
635         * editing/CompositeEditCommand.cpp:
636         (WebCore::CompositeEditCommand::isRemovableBlock): Implements logic to determine
637         if a block can be removed.
638         * editing/CompositeEditCommand.h: Added isRemovableBlock declaration.
639         * editing/DeleteSelectionCommand.cpp:
640         (WebCore::DeleteSelectionCommand::removeRedundantBlocks): Implemented using
641         isRemovableBlock from CompositeEditCommand.
642         * editing/Editor.cpp:
643         (WebCore::Editor::replaceSelectionWithFragment): Added SanitizeFragment option.
644         * editing/ReplaceSelectionCommand.cpp:
645         (WebCore::ReplaceSelectionCommand::ReplaceSelectionCommand): Added initialization
646         of m_sanitizeFragment member.
647         (WebCore::ReplaceSelectionCommand::removeRedundantMarkup): New method implementing
648         the cleanup logic.
649         (WebCore::ReplaceSelectionCommand::doApply): Added call to removeRedundantMarkup
650         after the fragment is inserted in the document.
651         * editing/ReplaceSelectionCommand.h: Added new value to the enum CommandOption,
652         a new member variable and the new method declaration.
653
654 2011-12-14  Adrienne Walker  <enne@google.com>
655
656         [chromium] Refactor tile drawing to be more data-driven
657         https://bugs.webkit.org/show_bug.cgi?id=73059
658
659         Reviewed by James Robinson.
660
661         Partially tested by compositor layout tests. Debug borders and
662         checkerboarding tested manually.
663
664         This is the first part of a move towards rendering quads on screen
665         from a bag of data rather than in virtual CCLayerImpl::draw functions.
666
667         CCDrawQuad-derived classes store material-specific pieces of data to
668         use when rendering. CCLayerImpl classes now create these CCDrawQuad
669         objects rather than issuing direct GL commands. Where this data is
670         shared between quads that come from the same layer, that data is
671         stored in a CCSharedQuadState object rather than duplicated.
672
673         CCRenderPass is the class that holds the list of quads and the target
674         surface that they draw into. Drawing a frame consists of drawing a
675         series of render passes onto their respective surfaces.
676
677         CCLayerTreeHostImpl constructs these render passes from the output of
678         calculateDrawTransformsAndVisibility by asking each layer to insert
679         quads into a list and hands them off to LayerRendererChromium for
680         rendering.
681
682         * WebCore.gypi:
683         * platform/graphics/chromium/LayerRendererChromium.cpp:
684         (WebCore::LayerRendererChromium::clearSurfaceForDebug):
685         (WebCore::LayerRendererChromium::beginDrawingFrame):
686         (WebCore::LayerRendererChromium::drawRenderPass):
687         (WebCore::LayerRendererChromium::drawQuad):
688         (WebCore::LayerRendererChromium::drawDebugBorderQuad):
689         (WebCore::LayerRendererChromium::drawRenderSurfaceQuad):
690         (WebCore::LayerRendererChromium::drawSolidColorQuad):
691         (WebCore::tileUniformLocation):
692         (WebCore::findTileProgramUniforms):
693         (WebCore::LayerRendererChromium::drawTileQuad):
694         (WebCore::LayerRendererChromium::drawCustomLayerQuad):
695         (WebCore::LayerRendererChromium::finishDrawingFrame):
696         (WebCore::LayerRendererChromium::useRenderSurface):
697         * platform/graphics/chromium/LayerRendererChromium.h:
698         * platform/graphics/chromium/ShaderChromium.h:
699         (WebCore::FragmentTexAlphaBinding::edgeLocation):
700         (WebCore::FragmentTexAlphaBinding::fragmentTexTransformLocation):
701         (WebCore::FragmentTexOpaqueBinding::edgeLocation):
702         (WebCore::FragmentTexOpaqueBinding::fragmentTexTransformLocation):
703         * platform/graphics/chromium/TiledLayerChromium.cpp:
704         (WebCore::TiledLayerChromium::pushPropertiesTo):
705         * platform/graphics/chromium/cc/CCCustomLayerDrawQuad.cpp: Added.
706         (WebCore::CCCustomLayerDrawQuad::create):
707         (WebCore::CCCustomLayerDrawQuad::CCCustomLayerDrawQuad):
708         * platform/graphics/chromium/cc/CCCustomLayerDrawQuad.h: Added.
709         (WebCore::CCCustomLayerDrawQuad::layer):
710         * platform/graphics/chromium/cc/CCDebugBorderDrawQuad.cpp: Added.
711         (WebCore::CCDebugBorderDrawQuad::create):
712         (WebCore::CCDebugBorderDrawQuad::CCDebugBorderDrawQuad):
713         * platform/graphics/chromium/cc/CCDebugBorderDrawQuad.h: Added.
714         (WebCore::CCDebugBorderDrawQuad::color):
715         (WebCore::CCDebugBorderDrawQuad::width):
716         * platform/graphics/chromium/cc/CCDrawQuad.cpp: Added.
717         (WebCore::CCDrawQuad::CCDrawQuad):
718         (WebCore::CCDrawQuad::toDebugBorderDrawQuad):
719         (WebCore::CCDrawQuad::toRenderSurfaceDrawQuad):
720         (WebCore::CCDrawQuad::toSolidColorDrawQuad):
721         (WebCore::CCDrawQuad::toTileDrawQuad):
722         (WebCore::CCDrawQuad::toCustomLayerDrawQuad):
723         * platform/graphics/chromium/cc/CCDrawQuad.h: Added.
724         (WebCore::CCDrawQuad::quadRect):
725         (WebCore::CCDrawQuad::quadTransform):
726         (WebCore::CCDrawQuad::layerTransform):
727         (WebCore::CCDrawQuad::layerRect):
728         (WebCore::CCDrawQuad::clipRect):
729         (WebCore::CCDrawQuad::opacity):
730         (WebCore::CCDrawQuad::drawsOpaque):
731         (WebCore::CCDrawQuad::needsBlending):
732         (WebCore::CCDrawQuad::isLayerAxisAlignedIntRect):
733         (WebCore::CCDrawQuad::material):
734         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
735         (WebCore::CCLayerImpl::createSharedQuadState):
736         (WebCore::CCLayerImpl::appendQuads):
737         (WebCore::CCLayerImpl::appendDebugBorderQuad):
738         (WebCore::CCLayerImpl::quadTransform):
739         * platform/graphics/chromium/cc/CCLayerImpl.h:
740         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
741         (WebCore::CCLayerTreeHostImpl::trackDamageForAllSurfaces):
742         (WebCore::computeScreenSpaceTransformForSurface):
743         (WebCore::damageInSurfaceSpace):
744         (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
745         (WebCore::CCLayerTreeHostImpl::drawLayers):
746         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
747         * platform/graphics/chromium/cc/CCRenderPass.cpp: Added.
748         (WebCore::CCRenderPass::create):
749         (WebCore::CCRenderPass::CCRenderPass):
750         (WebCore::CCRenderPass::appendQuadsForLayer):
751         (WebCore::CCRenderPass::appendQuadsForRenderSurfaceLayer):
752         * platform/graphics/chromium/cc/CCRenderPass.h: Added.
753         (WebCore::CCRenderPass::quadList):
754         (WebCore::CCRenderPass::targetSurface):
755         (WebCore::CCRenderPass::setSurfaceDamageRect):
756         (WebCore::CCRenderPass::surfaceDamageRect):
757         * platform/graphics/chromium/cc/CCRenderSurfaceDrawQuad.cpp: Added.
758         (WebCore::CCRenderSurfaceDrawQuad::create):
759         (WebCore::CCRenderSurfaceDrawQuad::CCRenderSurfaceDrawQuad):
760         * platform/graphics/chromium/cc/CCRenderSurfaceDrawQuad.h: Added.
761         (WebCore::CCRenderSurfaceDrawQuad::layer):
762         (WebCore::CCRenderSurfaceDrawQuad::surfaceDamageRect):
763         * platform/graphics/chromium/cc/CCSharedQuadState.cpp: Added.
764         (WebCore::CCSharedQuadState::create):
765         (WebCore::CCSharedQuadState::CCSharedQuadState):
766         (WebCore::CCSharedQuadState::isLayerAxisAlignedIntRect):
767         * platform/graphics/chromium/cc/CCSharedQuadState.h: Added.
768         (WebCore::CCSharedQuadState::quadTransform):
769         (WebCore::CCSharedQuadState::layerTransform):
770         (WebCore::CCSharedQuadState::layerRect):
771         (WebCore::CCSharedQuadState::clipRect):
772         (WebCore::CCSharedQuadState::opacity):
773         (WebCore::CCSharedQuadState::isOpaque):
774         * platform/graphics/chromium/cc/CCSolidColorDrawQuad.cpp: Added.
775         (WebCore::CCSolidColorDrawQuad::create):
776         (WebCore::CCSolidColorDrawQuad::CCSolidColorDrawQuad):
777         * platform/graphics/chromium/cc/CCSolidColorDrawQuad.h: Added.
778         (WebCore::CCSolidColorDrawQuad::color):
779         * platform/graphics/chromium/cc/CCTileDrawQuad.cpp: Added.
780         (WebCore::CCTileDrawQuad::create):
781         (WebCore::CCTileDrawQuad::CCTileDrawQuad):
782         * platform/graphics/chromium/cc/CCTileDrawQuad.h: Added.
783         (WebCore::CCTileDrawQuad::textureId):
784         (WebCore::CCTileDrawQuad::textureOffset):
785         (WebCore::CCTileDrawQuad::textureSize):
786         (WebCore::CCTileDrawQuad::textureFilter):
787         (WebCore::CCTileDrawQuad::swizzleContents):
788         (WebCore::CCTileDrawQuad::leftEdgeAA):
789         (WebCore::CCTileDrawQuad::topEdgeAA):
790         (WebCore::CCTileDrawQuad::rightEdgeAA):
791         (WebCore::CCTileDrawQuad::bottomEdgeAA):
792         (WebCore::CCTileDrawQuad::isAntialiased):
793         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
794         (WebCore::CCTiledLayerImpl::CCTiledLayerImpl):
795         (WebCore::CCTiledLayerImpl::quadTransform):
796         (WebCore::CCTiledLayerImpl::appendQuads):
797         * platform/graphics/chromium/cc/CCTiledLayerImpl.h:
798         (WebCore::CCTiledLayerImpl::setContentsSwizzled):
799         (WebCore::CCTiledLayerImpl::contentsSwizzled):
800
801 2011-12-14  Ojan Vafai  <ojan@chromium.org>
802
803         Implement flexDirection and flexWrap and make flexFlow a proper shorthand.
804         https://bugs.webkit.org/show_bug.cgi?id=74542
805
806         Reviewed by Tony Chang.
807
808         In a followup patch, I'll cleanup all the *Flow methods in RenderFlexibleBox.
809
810         Existing tests cover all the rendering behaviors, so only need to test
811         the css property parsing.
812
813         * css/CSSComputedStyleDeclaration.cpp:
814         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
815         * css/CSSMutableStyleDeclaration.cpp:
816         (WebCore::CSSMutableStyleDeclaration::getPropertyValue):
817         * css/CSSParser.cpp:
818         (WebCore::CSSParser::parseValue):
819         * css/CSSPrimitiveValueMappings.h:
820         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
821         (WebCore::CSSPrimitiveValue::operator EFlexDirection):
822         * css/CSSProperty.cpp:
823         (WebCore::CSSProperty::isInheritedProperty):
824         * css/CSSPropertyLonghand.cpp:
825         (WebCore::initShorthandMap):
826         * css/CSSPropertyNames.in:
827         * css/CSSStyleApplyProperty.cpp:
828         (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):
829         * css/CSSStyleSelector.cpp:
830         (WebCore::CSSStyleSelector::applyProperty):
831         * rendering/RenderBox.cpp:
832         (WebCore::RenderBox::sizesToIntrinsicLogicalWidth):
833         * rendering/RenderFlexibleBox.cpp:
834         (WebCore::RenderFlexibleBox::isColumnFlow):
835         (WebCore::RenderFlexibleBox::isLeftToRightFlow):
836         (WebCore::RenderFlexibleBox::layoutAndPlaceChildren):
837         (WebCore::RenderFlexibleBox::alignChildren):
838         * rendering/style/RenderStyle.h:
839         (WebCore::InheritedFlags::flexDirection):
840         (WebCore::InheritedFlags::isColumnFlexDirection):
841         (WebCore::InheritedFlags::setFlexDirection):
842         (WebCore::InheritedFlags::initialFlexDirection):
843         * rendering/style/RenderStyleConstants.h:
844         * rendering/style/StyleFlexibleBoxData.cpp:
845         (WebCore::StyleFlexibleBoxData::StyleFlexibleBoxData):
846         (WebCore::StyleFlexibleBoxData::operator==):
847         * rendering/style/StyleFlexibleBoxData.h:
848
849 2011-12-13  Jon Lee  <jonlee@apple.com>
850
851         Enable notifications on Mac.
852
853         Reviewed by Sam Weinig.
854
855         * Configurations/FeatureDefines.xcconfig:
856
857 2011-12-14  Ryosuke Niwa  <rniwa@webkit.org>
858
859         COMPILE_ASSERT in CSSStyleSelector.cpp doesn't compile on Windows
860         https://bugs.webkit.org/show_bug.cgi?id=74327
861
862         Reviewed by Darin Adler.
863
864         Always use unsigned instead of bool and unsigned in the bitfields of RuleData to shrink
865         its size under MSVC.
866
867         Unlike gcc and clang, MSVC pads each consecutive member variables of the same type
868         in bitfields. e.g. if you have:
869         sturct AB {
870             unsigned m_1 : 31;
871             bool m_2 : 1;
872         }
873         then MSVC pads m_1 and allocates sizeof(unsigned) * 2 for AB whereas gcc and clang
874         only allocate sizeof(unsigned) * 1 for AB.
875
876         * css/CSSStyleSelector.cpp:
877         (WebCore::RuleData::RuleData):
878
879 2011-12-14  Ryosuke Niwa  <rniwa@webkit.org>
880
881         NodeChildList shouldn't be in NodeListNodeData
882         https://bugs.webkit.org/show_bug.cgi?id=73969
883
884         Reviewed by Sam Weinig.
885
886         Move NodeChildList out of NodeListNodeData to separate it from the other node lists in order to
887         resolve the bug 73853. Unlike other DynamicNodeList, we don't need to invalidate NodeChildList
888         on ancestors when children change. Moving ChildNodeList out of NodeListNodeData makes this difference
889         apparent and makes DynamicNodeList::Caches in NodeListNodeData always held by a DynamicSubtreeNodeList,
890         eliminating the need for hasOwnCaches() checks in various places.
891
892         Also renamed the existing DynamicNodeList to DynamicSubtreeNodeList and re-introduced DynamicNodeList
893         from which DynamicSubtreeNodeList and ChildNodeList both inherit to share the code for itemWithName.
894
895         In addition, renamed registerDynamicNodeList and unregisterDynamicNodeList, which updates a counter for
896         TreeScope::hasNodeListCaches, to registerDynamicSubtreeNodeList and unregisterDynamicSubtreeNodeList
897         respectively. They are no longer called by ChildNodeList in order to avoid walking up the DOM tree
898         inside invalidateNodeListsCacheAfterAttributeChanged and invalidateNodeListsCacheAfterChildrenChanged.
899
900         Test: fast/dom/childnode-item-after-itemname.html
901
902         * bindings/js/JSNodeListCustom.cpp:
903         (WebCore::JSNodeListOwner::isReachableFromOpaqueRoots):
904         * dom/ChildNodeList.cpp:
905         (WebCore::ChildNodeList::ChildNodeList):
906         (WebCore::ChildNodeList::length):
907         (WebCore::ChildNodeList::item):
908         (WebCore::ChildNodeList::nodeMatches):
909         * dom/ChildNodeList.h:
910         * dom/ClassNodeList.cpp:
911         (WebCore::ClassNodeList::ClassNodeList):
912         (WebCore::ClassNodeList::~ClassNodeList):
913         * dom/ClassNodeList.h:
914         * dom/ContainerNode.cpp:
915         (WebCore::ContainerNode::childrenChanged):
916         * dom/DynamicNodeList.cpp:
917         (WebCore::DynamicSubtreeNodeList::DynamicSubtreeNodeList):
918         (WebCore::DynamicSubtreeNodeList::~DynamicSubtreeNodeList):
919         (WebCore::DynamicSubtreeNodeList::length):
920         (WebCore::DynamicSubtreeNodeList::itemForwardsFromCurrent):
921         (WebCore::DynamicSubtreeNodeList::itemBackwardsFromCurrent):
922         (WebCore::DynamicSubtreeNodeList::item):
923         (WebCore::DynamicNodeList::itemWithName):
924         (WebCore::DynamicSubtreeNodeList::isDynamicNodeList):
925         (WebCore::DynamicSubtreeNodeList::invalidateCache):
926         (WebCore::DynamicSubtreeNodeList::Caches::Caches):
927         (WebCore::DynamicSubtreeNodeList::Caches::create):
928         (WebCore::DynamicSubtreeNodeList::Caches::reset):
929         * dom/DynamicNodeList.h:
930         (WebCore::DynamicNodeList::DynamicNodeList):
931         (WebCore::DynamicNodeList::~DynamicNodeList):
932         (WebCore::DynamicNodeList::node):
933         (WebCore::DynamicSubtreeNodeList::rootNode):
934         * dom/NameNodeList.cpp:
935         (WebCore::NameNodeList::NameNodeList):
936         (WebCore::NameNodeList::~NameNodeList):
937         * dom/NameNodeList.h:
938         * dom/Node.cpp:
939         (WebCore::Node::childNodes):
940         (WebCore::Node::registerDynamicSubtreeNodeList):
941         (WebCore::Node::unregisterDynamicSubtreeNodeList):
942         (WebCore::Node::invalidateNodeListsCacheAfterAttributeChanged):
943         (WebCore::Node::invalidateNodeListsCacheAfterChildrenChanged):
944         (WebCore::Node::removeCachedClassNodeList):
945         (WebCore::Node::removeCachedNameNodeList):
946         (WebCore::Node::removeCachedTagNodeList):
947         (WebCore::Node::removeCachedLabelsNodeList):
948         (WebCore::NodeListsNodeData::invalidateCaches):
949         (WebCore::NodeListsNodeData::isEmpty):
950         (WebCore::NodeRareData::clearChildNodeListCache):
951         * dom/Node.h:
952         * dom/NodeRareData.h:
953         (WebCore::NodeRareData::nodeLists):
954         (WebCore::NodeRareData::ensureChildNodeListCache):
955         * dom/TagNodeList.cpp:
956         (WebCore::TagNodeList::TagNodeList):
957         (WebCore::TagNodeList::~TagNodeList):
958         * dom/TagNodeList.h:
959         * html/LabelsNodeList.cpp:
960         (WebCore::LabelsNodeList::LabelsNodeList):
961         * html/LabelsNodeList.h:
962
963 2011-12-14  Ryosuke Niwa  <rniwa@webkit.org>
964
965         Push more member functions from EditCommand to CompositeEditCommand
966         https://bugs.webkit.org/show_bug.cgi?id=74249
967
968         Reviewed by Enrica Casucci.
969
970         Moved startingRootEditableElement and endingRootEditableElement from EditCommand to EditCommandComposition,
971         and isTypingCommand, preservesTypingStyle, shouldRetainAutocorrectionIndicator,
972         setShouldRetainAutocorrectionIndicator, and shouldStopCaretBlinking from EditCommand to CompositeEditCommand.
973         Also removed EditCommand::updateLayout().
974
975         * editing/ApplyBlockElementCommand.cpp:
976         (WebCore::ApplyBlockElementCommand::doApply):
977         * editing/ApplyStyleCommand.cpp:
978         (WebCore::ApplyStyleCommand::applyBlockStyle):
979         (WebCore::ApplyStyleCommand::applyInlineStyle):
980         * editing/CompositeEditCommand.cpp:
981         (WebCore::EditCommandComposition::EditCommandComposition):
982         (WebCore::EditCommandComposition::setStartingSelection):
983         (WebCore::EditCommandComposition::setEndingSelection):
984         (WebCore::CompositeEditCommand::preservesTypingStyle):
985         (WebCore::CompositeEditCommand::isTypingCommand):
986         (WebCore::CompositeEditCommand::shouldRetainAutocorrectionIndicator):
987         (WebCore::CompositeEditCommand::setShouldRetainAutocorrectionIndicator):
988         (WebCore::CompositeEditCommand::addBlockPlaceholderIfNeeded):
989         (WebCore::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary):
990         (WebCore::CompositeEditCommand::moveParagraphs):
991         * editing/CompositeEditCommand.h:
992         (WebCore::EditCommandComposition::startingRootEditableElement):
993         (WebCore::EditCommandComposition::endingRootEditableElement):
994         (WebCore::CompositeEditCommand::shouldStopCaretBlinking):
995         * editing/DeleteSelectionCommand.cpp:
996         (WebCore::DeleteSelectionCommand::removeNode):
997         (WebCore::DeleteSelectionCommand::fixupWhitespace):
998         * editing/EditCommand.cpp:
999         (WebCore::EditCommand::apply):
1000         (WebCore::EditCommand::unapply):
1001         (WebCore::EditCommand::reapply):
1002         (WebCore::EditCommand::setStartingSelection):
1003         (WebCore::EditCommand::setEndingSelection):
1004         (WebCore::EditCommand::setParent):
1005         * editing/EditCommand.h:
1006         (WebCore::EditCommand::isEditCommandComposition):
1007         * editing/Editor.cpp:
1008         (WebCore::dispatchEditableContentChangedEvents):
1009         (WebCore::Editor::appliedEditing):
1010         (WebCore::Editor::unappliedEditing):
1011         (WebCore::Editor::reappliedEditing):
1012         * editing/Editor.h:
1013         (WebCore::Editor::lastEditCommand):
1014         * editing/FrameSelection.cpp:
1015         (WebCore::FrameSelection::updateAppearance):
1016         * editing/IndentOutdentCommand.cpp:
1017         (WebCore::IndentOutdentCommand::outdentParagraph):
1018         * editing/InsertLineBreakCommand.cpp:
1019         (WebCore::InsertLineBreakCommand::doApply):
1020         * editing/InsertParagraphSeparatorCommand.cpp:
1021         (WebCore::InsertParagraphSeparatorCommand::doApply):
1022         * editing/TypingCommand.cpp:
1023         (WebCore::TypingCommand::lastTypingCommandIfStillOpenForTyping):
1024         * editing/TypingCommand.h:
1025         (WebCore::TypingCommand::shouldRetainAutocorrectionIndicator):
1026
1027 2011-12-14  Tony Chang  <tony@chromium.org>
1028
1029         Fix compile on gcc on Mac.
1030
1031         css/CSSStyleSelector.cpp:1254:166: error: unused parameter 'regionForStyling' [-Werror,-Wunused-parameter,3]
1032         css/CSSStyleSelector.cpp:1425:134: error: unused parameter 'regionForStyling' [-Werror,-Wunused-parameter,3]
1033
1034         * css/CSSStyleSelector.cpp:
1035         (WebCore::CSSStyleSelector::styleForElement):
1036         (WebCore::CSSStyleSelector::pseudoStyleForElement):
1037
1038 2011-12-14  Brady Eidson  <beidson@apple.com>
1039
1040         <rdar://problem/10576732> and https://bugs.webkit.org/show_bug.cgi?id=74533
1041         REGRESSION(r102619): Reproducible crash closing window with video + poster image inside an object element
1042
1043         Reviewed by Darin Adler.
1044
1045         Test: media/crash-closing-page-with-media-as-plugin-fallback.html
1046
1047         Switch HTMLPlugInImageElement from using document activation callbacks to using the ActiveDOMObject
1048         mechanism which will prevent the unnecessary (and crashy) work at Document teardown:
1049         * html/HTMLPlugInImageElement.cpp:
1050         (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement):
1051         (WebCore::HTMLPlugInImageElement::canSuspend):
1052         (WebCore::HTMLPlugInImageElement::suspend):
1053         (WebCore::HTMLPlugInImageElement::resume):
1054         * html/HTMLPlugInImageElement.h:
1055
1056 2011-12-14  Adrienne Walker  <enne@google.com>
1057
1058         [chromium] Compositor needs to set texture filtering on canvas layers
1059         https://bugs.webkit.org/show_bug.cgi?id=74530
1060
1061         Reviewed by James Robinson.
1062
1063         * platform/graphics/chromium/cc/CCCanvasLayerImpl.cpp:
1064         (WebCore::CCCanvasLayerImpl::draw):
1065
1066 2011-12-14  Tony Chang  <tony@chromium.org>
1067
1068         Remove added calls to CSSStyleSelector to gain back another 2% in page cyclers
1069         https://bugs.webkit.org/show_bug.cgi?id=74537
1070
1071         Reviewed by Ojan Vafai.
1072
1073         In r102234, calls to initForRegionStyling() were added in CSSStyleSelector.
1074         There's still a 2% perf regression in chromium page cyclers, so try removing
1075         these calls.
1076
1077         * css/CSSStyleSelector.cpp:
1078         (WebCore::CSSStyleSelector::styleForElement):
1079         (WebCore::CSSStyleSelector::pseudoStyleForElement):
1080
1081 2011-12-14  Jonathan Backer  <backer@chromium.org>
1082
1083         [chromium] Plumb through flag for enabling partial swap
1084         https://bugs.webkit.org/show_bug.cgi?id=74513
1085
1086         Reviewed by James Robinson.
1087
1088         * page/Settings.h:
1089         (WebCore::Settings::setPartialSwapEnabled):
1090         (WebCore::Settings::partialSwapEnabled):
1091         * platform/graphics/chromium/LayerRendererChromium.cpp:
1092         (WebCore::LayerRendererChromium::initialize):
1093         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
1094         (WebCore::CCSettings::CCSettings):
1095
1096 2011-12-14  Mike Reed  <reed@google.com>
1097
1098         [skia] cache typeface in FontPlatformData
1099         https://bugs.webkit.org/show_bug.cgi?id=74415
1100
1101         Reviewed by Stephen White.
1102
1103         No new tests. Existing tests apply, this is just an optimization
1104         to avoid looking up the typeface on each drawText call.
1105
1106         * platform/graphics/chromium/FontChromiumWin.cpp:
1107         (WebCore::TransparencyAwareFontPainter::TransparencyAwareGlyphPainter::drawGlyphs):
1108         (WebCore::Font::drawGlyphs):
1109         * platform/graphics/chromium/FontPlatformDataChromiumWin.cpp:
1110         (WebCore::createTypefaceFromHFont):
1111         (WebCore::FontPlatformData::FontPlatformData):
1112         (WebCore::FontPlatformData::operator=):
1113         (WebCore::FontPlatformData::~FontPlatformData):
1114         * platform/graphics/chromium/FontPlatformDataChromiumWin.h:
1115         (WebCore::FontPlatformData::typeface):
1116         (WebCore::FontPlatformData::lfQuality):
1117         (WebCore::FontPlatformData::hash):
1118         (WebCore::FontPlatformData::operator==):
1119         * platform/graphics/skia/SkiaFontWin.cpp:
1120         (WebCore::setupPaintForFont):
1121         (WebCore::paintSkiaText):
1122         * platform/graphics/skia/SkiaFontWin.h:
1123
1124 2011-12-14  Simon Fraser  <simon.fraser@apple.com>
1125
1126         Make -webkit-filter animatable
1127         https://bugs.webkit.org/show_bug.cgi?id=68476
1128
1129         Reviewed by Chris Marrin.
1130         
1131         Add -webkit-filter to the list of CSS properties that are animatable. Animate
1132         it like we do transforms, by looking for matching lists of filter functions.
1133         Each kind of filter operation has a blend() method that handles blending
1134         for that filter.
1135
1136         Test: css3/filters/filter-animation.html
1137
1138         * GNUmakefile.list.am: Add FilterOperation.cpp to the build.
1139         * Target.pri: Ditto
1140         * WebCore.gypi: Ditto
1141         * WebCore.vcproj/WebCore.vcproj: Ditto
1142         * WebCore.xcodeproj/project.pbxproj: Ditto
1143         * page/animation/AnimationBase.cpp:
1144         (WebCore::blendFunc): New blendFunc() for FilterOperations, which does per-filter blending.
1145         (WebCore::AnimationBase::ensurePropertyMap): Make PropertyWrapper for filters.
1146         (WebCore::AnimationBase::AnimationBase): Adjust initialization order.
1147         * page/animation/AnimationBase.h: Adjusted the member variable order to minimize padding.
1148         (WebCore::AnimationBase::filterFunctionListsMatch): Accessor for the flag.
1149         * page/animation/ImplicitAnimation.cpp:
1150         (WebCore::ImplicitAnimation::reset):
1151         (WebCore::ImplicitAnimation::validateTransformFunctionList): Adjust comment. The "is valid" terminology is confusing.
1152         (WebCore::ImplicitAnimation::checkForMatchingFilterFunctionLists): New method to check for matching lists
1153         of filter functions.
1154         * page/animation/ImplicitAnimation.h:
1155         * page/animation/KeyframeAnimation.cpp:
1156         (WebCore::KeyframeAnimation::KeyframeAnimation):
1157         (WebCore::KeyframeAnimation::checkForMatchingFilterFunctionLists): New method to check for matching lists
1158         of filter functions.
1159         * page/animation/KeyframeAnimation.h:
1160         * rendering/style/FilterOperation.cpp: Added.
1161         (WebCore::BasicColorMatrixFilterOperation::blend):
1162         (WebCore::BasicColorMatrixFilterOperation::passthroughAmount):
1163         (WebCore::BasicComponentTransferFilterOperation::blend):
1164         (WebCore::BasicComponentTransferFilterOperation::passthroughAmount): Different filters have
1165         different values for m_amount for the "passthrough" behavior. This method returns the appropriate value.
1166         (WebCore::GammaFilterOperation::blend):
1167         (WebCore::BlurFilterOperation::blend):
1168         (WebCore::DropShadowFilterOperation::blend):
1169         * rendering/style/FilterOperation.h:
1170         (WebCore::FilterOperation::blend):
1171         (WebCore::PassthroughFilterOperation::create): New "no-op" filter.
1172         (WebCore::PassthroughFilterOperation::operator==):
1173         (WebCore::PassthroughFilterOperation::PassthroughFilterOperation):
1174         * rendering/style/FilterOperations.cpp:
1175         (WebCore::FilterOperations::operationsMatch):
1176         * rendering/style/FilterOperations.h:
1177
1178 2011-12-14  Adam Klein  <adamk@chromium.org>
1179
1180         Broaden support for mutation observation of attributes
1181         https://bugs.webkit.org/show_bug.cgi?id=74448
1182
1183         Reviewed by Ryosuke Niwa.
1184
1185         The previously-landed MutationObserver support for attributes was incomplete:
1186         it didn't support mutations related to Attr nodes (methods on Attrs,
1187         setAttributeNode/removeAttributeNode on Element, or methods on NamedNodeMap).
1188
1189         This patch adds full support of mutation observation for all these cases,
1190         and adds test cases for all these situations.
1191
1192         * dom/Attr.cpp:
1193         (WebCore::Attr::setValue): Enqueue a mutation record when Attr.value is set from JS.
1194         (WebCore::Attr::childrenChanged): Enqueue a mutation record when an Attr's value
1195         changes to due additions/removals of Text children.
1196         * dom/Element.cpp:
1197         (WebCore::Element::enqueueAttributesMutationRecordIfRequested): Previously a static,
1198         expose as part of Element's interface to allow it to be re-used by NamedNodeMap and Attr.
1199         (WebCore::Element::removeAttribute): Remove enqueue call now handled by NamedNodeMap.
1200         (WebCore::Element::setAttributeInternal): Fixup call of enqueueAttributesMutationRecordIfRequested.
1201         * dom/Element.h:
1202         * dom/NamedNodeMap.cpp:
1203         (WebCore::NamedNodeMap::setNamedItem): Enqueue a mutation record when an attribute
1204         is changed via Element.attributes.setNamedItem from JS.
1205         (WebCore::NamedNodeMap::removeNamedItem): Enqueue a mutation record when an
1206         attribute is removed, either via Element.attributes.removeNamedItem or Element.removeAttribute.
1207
1208 2011-12-14  Raymond Toy  <rtoy@google.com>
1209
1210         * platform/audio/Distance.h (WebCore): 
1211
1212         Incorrect calculation for DistanceEffect linearGain
1213         https://bugs.webkit.org/show_bug.cgi?id=72871
1214
1215         Reviewed by Kenneth Russell.
1216
1217         Tests still need to be written for all distance models.  This
1218         does not add a new API and just corrects an implementation error. 
1219
1220         * platform/audio/Distance.cpp:
1221         (WebCore::DistanceEffect::linearGain): Implement correct
1222         linearGain function.  (Fix proposed by davidgaleano@hotmail.com.)
1223         * platform/audio/Distance.h: Add link to Open AL specification. 
1224         
1225
1226 2011-12-14  Ilya Tikhonovsky  <loislo@chromium.org>
1227
1228         Web Inspector: consider disabling network tracking while running the CPU profile.
1229         https://bugs.webkit.org/show_bug.cgi?id=74221
1230
1231         The WebCore instrumentation on the backend affects the performance of inspected page.
1232         As the result the CPU profiler's stats data are far away from the reality.
1233         Solution: the profiler code will temporary disable the resource tracking on backend.
1234         Side effect: the resource tree gets out of sinc because it uses Network Agent's notifications for updating the resource tree.
1235         Solution: NetworkManager will report about the changes of the resource tracking state and ResourcePanel will re-fetch the resources tree.
1236
1237         Reviewed by Pavel Feldman.
1238
1239         * inspector/front-end/NetworkManager.js:
1240         (WebInspector.NetworkManager.prototype.enableResourceTracking.networkAgentEnabled):
1241         (WebInspector.NetworkManager.prototype.enableResourceTracking):
1242         (WebInspector.NetworkManager.prototype.disableResourceTracking.networkAgentDisabled):
1243         (WebInspector.NetworkManager.prototype.disableResourceTracking):
1244         (WebInspector.NetworkManager.prototype.inflightResourceForURL):
1245         * inspector/front-end/ProfileView.js:
1246         (WebInspector.CPUProfileType.prototype.buttonClicked):
1247         * inspector/front-end/ResourceTreeModel.js:
1248         (WebInspector.ResourceTreeModel):
1249         (WebInspector.ResourceTreeModel.prototype._onResourceTrackingEnabled):
1250
1251 2011-12-14  Carlos Garcia Campos  <cgarcia@igalia.com>
1252
1253         [GTK] Fix PlatformScreen::screenAvailableRect when there's no view widget
1254         https://bugs.webkit.org/show_bug.cgi?id=74520
1255
1256         Reviewed by Martin Robinson.
1257
1258         Use the default screen to get the available screen area instead of
1259         just returning an empty rectangle. This is useful for WebKit2,
1260         since there's no view widget in the web process.
1261
1262         * platform/gtk/PlatformScreenGtk.cpp:
1263         (WebCore::screenAvailableRect):
1264
1265 2011-12-14  Eric Carlson  <eric.carlson@apple.com>
1266
1267         Media url with fragment may not load
1268         https://bugs.webkit.org/show_bug.cgi?id=74443
1269
1270         Reviewed by Darin Adler.
1271
1272         Test: media/media-extension-with-fragment.html
1273
1274         * html/HTMLMediaElement.cpp:
1275         (WebCore::HTMLMediaElement::loadResource): Pass the KURL to MediaPlayer, let it extract a
1276             String when it needs it.
1277
1278         * platform/graphics/MediaPlayer.cpp:
1279         (WebCore::MediaPlayer::load): Take a KURL, not a String. Look for the file extension in the 
1280             last path component so we don't examine fragments and/or queries.
1281         * platform/graphics/MediaPlayer.h:
1282
1283 2011-12-14  Jacky Jiang  <zhajiang@rim.com>
1284
1285         [BlackBerry] Remove some duplicate entries in Source/WebCore/PlatformBlackBerry.cmake
1286         https://bugs.webkit.org/show_bug.cgi?id=74484
1287
1288         Reviewed by Daniel Bates.
1289
1290         Trivial fix, so no new tests.
1291
1292         * PlatformBlackBerry.cmake:
1293
1294 2011-12-14  Anders Carlsson  <andersca@apple.com>
1295
1296         Add back the callOnMainThread overload that takes a WTF::Function
1297         https://bugs.webkit.org/show_bug.cgi?id=74512
1298
1299         Reviewed by Darin Adler.
1300
1301         Explicitly qualify the Function enum flag, since MSVC2005 is too stupid to disambiguate
1302         the Function class template and the enum flag.
1303
1304         * bindings/js/JSDOMWindowCustom.cpp:
1305         (WebCore::JSDOMWindow::getOwnPropertySlot):
1306         (WebCore::JSDOMWindow::getOwnPropertyDescriptor):
1307         * bindings/js/JSHistoryCustom.cpp:
1308         (WebCore::JSHistory::getOwnPropertySlotDelegate):
1309         (WebCore::JSHistory::getOwnPropertyDescriptorDelegate):
1310         * bindings/js/JSLocationCustom.cpp:
1311         (WebCore::JSLocation::getOwnPropertySlotDelegate):
1312         (WebCore::JSLocation::getOwnPropertyDescriptorDelegate):
1313
1314 2011-12-14  Kenneth Russell  <kbr@google.com>
1315
1316         Unreviewed, rolling out r102688.
1317         http://trac.webkit.org/changeset/102688
1318         https://bugs.webkit.org/show_bug.cgi?id=74220
1319
1320         Under the hypothesis that it might be the cause of
1321         browser_tests and ui_tests crashes on Chromium canaries --
1322         will reland if not.
1323
1324         * bindings/v8/V8Proxy.cpp:
1325         (WebCore::addMessageToConsole):
1326         (WebCore::logInfo):
1327         (WebCore::V8Proxy::reportUnsafeAccessTo):
1328         * bindings/v8/V8Proxy.h:
1329         * bindings/v8/custom/V8CustomXPathNSResolver.cpp:
1330         (WebCore::V8CustomXPathNSResolver::lookupNamespaceURI):
1331
1332 2011-12-14  Vsevolod Vlasov  <vsevik@chromium.org>
1333
1334         Web Inspector: DatabaseTableView should escape table name.
1335         https://bugs.webkit.org/show_bug.cgi?id=74503
1336
1337         Reviewed by Pavel Feldman.
1338
1339         Test: inspector/database-table-name-excaping.html
1340
1341         * inspector/front-end/DatabaseTableView.js:
1342         (WebInspector.DatabaseTableView.prototype._escapeTableName):
1343         (WebInspector.DatabaseTableView.prototype.update):
1344
1345 2011-12-14  Philippe Normand  <pnormand@igalia.com>
1346
1347         [GStreamer] padTemplate leak in webkitwebaudiosrc
1348         https://bugs.webkit.org/show_bug.cgi?id=74495
1349
1350         Reviewed by Martin Robinson.
1351
1352         Use a GstPadTemplate smart pointer in webkit_web_audio_src_init to
1353         avoid a memory leak after the ghost pad creation.
1354
1355         * platform/audio/gstreamer/WebKitWebAudioSourceGStreamer.cpp:
1356         (webkit_web_audio_src_init):
1357         * platform/graphics/gstreamer/GRefPtrGStreamer.cpp:
1358         (WTF::adoptGRef):
1359         (WTF::GstPadTemplate):
1360         * platform/graphics/gstreamer/GRefPtrGStreamer.h:
1361
1362 2011-12-14  Julien Chaffraix  <jchaffraix@webkit.org>
1363
1364         Crash in RenderBox::paintBoxDecorations when documentElement has no renderer
1365         https://bugs.webkit.org/show_bug.cgi?id=64284
1366
1367         Reviewed by Ryosuke Niwa.
1368
1369         Test: fast/dynamic/crash-paint-no-documentElement-renderer.html
1370
1371         * rendering/RenderBox.cpp:
1372         (WebCore::RenderBox::paintBackground): Check the documentElement's
1373         renderer before using it which matches what RenderView does.
1374
1375 2011-12-14  Tom Sepez  <tsepez@chromium.org>
1376
1377         DocumentLoader should ref its mainResourceLoader.
1378         https://bugs.webkit.org/show_bug.cgi?id=74424
1379
1380         Reviewed by Adam Barth.
1381
1382         Tests: platform/chromium/http/tests/security/mixedContent/insecure-iframe-in-main-frame-allowed.html
1383                platform/chromium/http/tests/security/mixedContent/insecure-iframe-in-main-frame-blocked.html
1384
1385         * loader/DocumentLoader.cpp:
1386         (WebCore::DocumentLoader::startLoadingMainResource):
1387         * loader/MainResourceLoader.cpp:
1388         (WebCore::MainResourceLoader::loadNow):
1389
1390 2011-12-14  Stephen White  <senorblanco@chromium.org>
1391
1392         CSS Filters should support GPU acceleration
1393         https://bugs.webkit.org/show_bug.cgi?id=74441
1394
1395         Reviewed by Darin Adler.
1396
1397         Will be covered by existing CSS filters tests, when run in GPU mode.
1398
1399         * rendering/FilterEffectRenderer.cpp:
1400         (WebCore::FilterEffectRenderer::prepare):
1401         * rendering/RenderLayer.cpp:
1402         (WebCore::RenderLayer::updateOrRemoveFilterEffect):
1403
1404 2011-12-14  Brian Salomon  <bsalomon@google.com>
1405
1406         [CHROMIUM/SKIA] Handle put[Un/Pre]multipliedImageData conversions in Skia rather than ImageBuffer
1407         https://bugs.webkit.org/show_bug.cgi?id=73953
1408
1409         Reviewed by Stephen White.
1410
1411         Tested by existing canvas2d layout tests.
1412
1413         * platform/graphics/skia/ImageBufferSkia.cpp:
1414         (WebCore::putImageData):
1415         (WebCore::ImageBuffer::putUnmultipliedImageData):
1416         (WebCore::ImageBuffer::putPremultipliedImageData):
1417
1418 2011-12-14  Mary Wu  <mary.wu@torchmobile.com.cn>
1419
1420         Remove SharedBufferBlackBerry.cpp from WebCore/platform/blackberry
1421         https://bugs.webkit.org/show_bug.cgi?id=74488
1422
1423         Reviewed by Rob Buis.
1424
1425         Remove dead code, no new tests.
1426
1427         * platform/blackberry/SharedBufferBlackBerry.cpp: Removed.
1428
1429 2011-12-14  Kentaro Hara  <haraken@chromium.org>
1430
1431         Use [Supplemental] IDL in WebSocket
1432         https://bugs.webkit.org/show_bug.cgi?id=74160
1433
1434         Reviewed by Adam Barth.
1435
1436         By using the [Supplemental] IDL, this patch moves declarations of WebSocket
1437         attributes from DOMWindow.idl to websocket/DOMWindowWebSocket.idl,
1438         which helps make WebSocket a self-contained module.
1439
1440         No new tests, no change in behavior.
1441         Confirm that http/tests/websocket/* pass.
1442
1443         * WebCore.gypi: Added DOMWindowWebSocket.idl.
1444         * page/DOMWindow.idl: Added the [Supplemented] IDL to WebSocket-related attributes. This [Supplemented] IDL will be removed after all platforms support the [Supplemental] IDL (See bug 73394 for more details).
1445         * websockets/DOMWindowWebSocket.idl: Added. Used the [Supplemental=DOMWindow] IDL. The attributes in this IDL file are treated as if they are described in DOMWindow.idl.
1446
1447 2011-12-14  Pierre Rossi  <pierre.rossi@gmail.com>
1448
1449         Unreviewed fix. Broke qt minimal release compilation.
1450
1451         * platform/qt/RenderThemeQtMobile.cpp:
1452
1453 2011-12-14  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
1454
1455         Add different salt to different types of selectors. So the CSS fast
1456         path can tell the different between tags and class attributes with
1457         otherwise identical values.
1458         https://bugs.webkit.org/show_bug.cgi?id=74284
1459
1460         Reviewed by Antti Koivisto.
1461
1462         * css/SelectorChecker.cpp:
1463         (WebCore::collectElementIdentifierHashes):
1464         (WebCore::collectDescendantSelectorIdentifierHashes):
1465         * css/SelectorChecker.h:
1466
1467 2011-12-14  Pierre Rossi  <pierre.rossi@gmail.com>
1468
1469         [Qt] Mobile theme could use a little refresh
1470         https://bugs.webkit.org/show_bug.cgi?id=74293
1471
1472         The look and feel of the "mobile theme" we're
1473         using in QtWebKit dates back to the maemo 5 days.
1474         This is an attempt at making it look less out of
1475         place, and also support progress and range.
1476
1477         Reviewed by Kenneth Rohde Christiansen.
1478
1479         No new tests, this is still not the default theme
1480         for tests.
1481
1482         * DerivedSources.pri:
1483         * css/mobileThemeQt.css: Added.
1484         (input[type="submit"], select):
1485         (input[type="submit"]:disabled, input[type="submit"]:disabled:active, select:disabled, input[type="text"]:disabled):
1486         (input[type="submit"]:active):
1487         * platform/qt/RenderThemeQt.cpp:
1488         (WebCore::RenderThemeQt::extraDefaultStyleSheet):
1489         (WebCore::StylePainter::StylePainter):
1490         (WebCore::StylePainter::init):
1491         (WebCore::StylePainter::~StylePainter):
1492         * platform/qt/RenderThemeQt.h:
1493         * platform/qt/RenderThemeQtMobile.cpp:
1494         (WebCore::drawRectangularControlBackground):
1495         (WebCore::shrinkRectToSquare):
1496         (WebCore::StylePainterMobile::StylePainterMobile):
1497         (WebCore::StylePainterMobile::~StylePainterMobile):
1498         (WebCore::StylePainterMobile::drawCheckableBackground):
1499         (WebCore::StylePainterMobile::sizeForPainterScale):
1500         (WebCore::StylePainterMobile::drawChecker):
1501         (WebCore::StylePainterMobile::findCheckBox):
1502         (WebCore::StylePainterMobile::drawRadio):
1503         (WebCore::StylePainterMobile::findRadio):
1504         (WebCore::StylePainterMobile::drawMultipleComboButton):
1505         (WebCore::StylePainterMobile::drawSimpleComboButton):
1506         (WebCore::StylePainterMobile::getButtonImageSize):
1507         (WebCore::StylePainterMobile::findComboButton):
1508         (WebCore::StylePainterMobile::drawLineEdit):
1509         (WebCore::StylePainterMobile::drawCheckBox):
1510         (WebCore::StylePainterMobile::drawRadioButton):
1511         (WebCore::StylePainterMobile::drawPushButton):
1512         (WebCore::StylePainterMobile::drawComboBox):
1513         (WebCore::StylePainterMobile::drawProgress):
1514         (WebCore::StylePainterMobile::drawSliderThumb):
1515         (WebCore::RenderThemeQtMobile::paintButton):
1516         (WebCore::RenderThemeQtMobile::paintTextField):
1517         (WebCore::RenderThemeQtMobile::setPopupPadding):
1518         (WebCore::RenderThemeQtMobile::paintMenuList):
1519         (WebCore::RenderThemeQtMobile::paintMenuListButton):
1520         (WebCore::RenderThemeQtMobile::animationDurationForProgressBar):
1521         (WebCore::RenderThemeQtMobile::paintProgressBar):
1522         (WebCore::RenderThemeQtMobile::paintSliderTrack):
1523         (WebCore::RenderThemeQtMobile::paintSliderThumb):
1524         (WebCore::RenderThemeQtMobile::adjustSliderThumbSize):
1525         * platform/qt/RenderThemeQtMobile.h:
1526
1527 2011-12-14  Rakesh KN  <rakesh.kn@motorola.com>
1528
1529         [Non-Mac] Change event should be fired when changing option by using keyboard.
1530         https://bugs.webkit.org/show_bug.cgi?id=74384
1531
1532         Reviewed by Kent Tamura.
1533
1534         Fire onchange event when option is changed using up/down/right/left/pageup/pagedown/home/end keys.
1535
1536         Test: fast/forms/select/menulist-onchange-fired-with-key-up-down.html
1537
1538         * html/HTMLSelectElement.cpp:
1539         (WebCore::HTMLSelectElement::menuListDefaultEventHandler):
1540         Setting the DispatchChangeEvent selection option flag when the option is selected using
1541         up/down/right/left/pageup/pagedown/home/end keys.
1542
1543 2011-12-13  Vsevolod Vlasov  <vsevik@chromium.org>
1544
1545         Web Inspector: TreeOutline's is broken when li elements have padding-left different from 14px.
1546         https://bugs.webkit.org/show_bug.cgi?id=74445
1547
1548         Reviewed by Pavel Feldman.
1549
1550         * inspector/front-end/treeoutline.js:
1551         (TreeElement.prototype.isEventWithinDisclosureTriangle):
1552
1553 2011-12-13  Vsevolod Vlasov  <vsevik@chromium.org>
1554
1555         Web Inspector: [Regression] Scripts panel debug sidebar toolbar should not be scrolled out of the screen.
1556         https://bugs.webkit.org/show_bug.cgi?id=74447
1557
1558         Reviewed by Pavel Feldman.
1559
1560         * inspector/front-end/ScriptsPanel.js:
1561         (WebInspector.ScriptsPanel.prototype.wasShown):
1562         * inspector/front-end/scriptsPanel.css:
1563         (#scripts-debug-toolbar):
1564         (#scripts-debug-sidebar-contents):
1565
1566 2011-12-14  Alexander Færøy  <alexander.faeroy@nokia.com>
1567
1568         [Qt] DeviceOrientationClientMockQt should be removed in favor of DeviceOrientationClientMock
1569         https://bugs.webkit.org/show_bug.cgi?id=74417
1570
1571         Reviewed by Simon Hausmann.
1572
1573         Based on original patch by Kenneth Christiansen.
1574
1575         Already covered by current tests.
1576
1577         * dom/DeviceOrientationController.h:
1578         (WebCore::DeviceOrientationController::client):
1579
1580 2011-12-14  Jacky Jiang  <zhajiang@rim.com>
1581
1582         [BlackBerry] Switch to libjpeg for decoding
1583         https://bugs.webkit.org/show_bug.cgi?id=74475
1584
1585         Reviewed by Daniel Bates.
1586
1587         Switch to cross platform JPEG image decoder for decoding as this keeps
1588         us inline with other ports and less to maintain.
1589
1590         * PlatformBlackBerry.cmake:
1591
1592 2011-12-03  Philippe Normand  <pnormand@igalia.com>
1593
1594         [GTK] Bad text rendering since r101343
1595         https://bugs.webkit.org/show_bug.cgi?id=73744
1596
1597         Reviewed by Martin Robinson.
1598
1599         * platform/graphics/freetype/FontPlatformDataFreeType.cpp:
1600         (WebCore::setCairoFontOptionsFromFontConfigPattern): Keep Cairo
1601         hint metrics unchanged for better visual font rendering results.
1602
1603 2011-12-13  Hajime Morrita  <morrita@chromium.org>
1604
1605         Unreviewed attempt for fixing windows build.
1606
1607         - Included <wtf/MathExtras.h> which defined portable version of lround().
1608         - Add some static_cast<> to suppress warnings.
1609
1610         * platform/animation/AnimationUtilities.h:
1611         (WebCore::blend):
1612
1613 2011-12-13  Wei Charles  <charles.wei@torchmobile.com.cn>
1614
1615         [BlackBerry] Add the new plugin files into the build system.
1616         https://bugs.webkit.org/show_bug.cgi?id=74483
1617
1618         Reviewed by Daniel Bates.
1619
1620         No new tests, just add new files to the build system.
1621
1622         * PlatformBlackBerry.cmake:
1623
1624 2011-12-13  Yosifumi Inoue  <yosin@chromium.org>
1625
1626         [Forms] Default selection of select(menulist) should not be disabled
1627         https://bugs.webkit.org/show_bug.cgi?id=74270
1628
1629         Reviewed by Kent Tamura.
1630
1631         This patch changes default selection of select(menulist) element to
1632           1. Selected option element. If there are multiple options which have
1633              selected state, we pick the largest index option up. (same as current)
1634           2. Non-disabled option element (new behavior)
1635           3. The first option if all options are disabled. (new behavior)
1636
1637         Tests: fast/forms/select/menulist-disabled-option-expected.html
1638                fast/forms/select/menulist-disabled-option.html
1639
1640         * html/HTMLSelectElement.cpp:
1641         (WebCore::HTMLSelectElement::recalcListItems): Implement new logic for selection.
1642
1643 2011-12-13  Simon Fraser  <simon.fraser@apple.com>
1644
1645         Share blend progress code
1646         https://bugs.webkit.org/show_bug.cgi?id=74464
1647
1648         Reviewed by Dean Jackson.
1649         
1650         Lots of places in the code had copies of the animation interpolation
1651         logic "from + (to - from) * progress", in various forms.
1652         
1653         Coalesce all these into calls to a few new inline functions in a new
1654         AnimationUtilities.h header. Color and Length get their own blend fuctions
1655         in their respective headers.
1656
1657         Covered by existing tests.
1658
1659         * GNUmakefile.list.am:
1660         * Target.pri:
1661         * WebCore.gypi:
1662         * WebCore.vcproj/WebCore.vcproj:
1663         * WebCore.xcodeproj/project.pbxproj:
1664         * css/CSSGradientValue.cpp:
1665         * page/animation/AnimationBase.cpp:
1666         (WebCore::blendFunc):
1667         * platform/Length.h:
1668         (WebCore::Length::blend):
1669         * platform/animation/AnimationUtilities.h: Added.
1670         (WebCore::blend):
1671         * platform/graphics/Color.h:
1672         (WebCore::blend):
1673         * platform/graphics/transforms/PerspectiveTransformOperation.cpp:
1674         (WebCore::PerspectiveTransformOperation::blend):
1675         * platform/graphics/transforms/RotateTransformOperation.cpp:
1676         (WebCore::RotateTransformOperation::blend):
1677         * platform/graphics/transforms/ScaleTransformOperation.cpp:
1678         (WebCore::ScaleTransformOperation::blend):
1679         * platform/graphics/transforms/SkewTransformOperation.cpp:
1680         (WebCore::SkewTransformOperation::blend):
1681         * platform/graphics/transforms/TranslateTransformOperation.cpp:
1682         (WebCore::TranslateTransformOperation::blend):
1683         * svg/SVGLength.h:
1684         (WebCore::SVGLength::blend):
1685         * svg/SVGPathBlender.cpp:
1686         (WebCore::blendFloatPoint):
1687         (WebCore::SVGPathBlender::blendAnimatedDimensonalFloat):
1688         (WebCore::SVGPathBlender::blendArcToSegment):
1689
1690 2011-12-13  Mary Wu  <mary.wu@torchmobile.com.cn>
1691
1692         Upstream 3 files into WebCore/platform/blackberry
1693         ClipboardBlackBerry.cpp/h, PasteboardBlackBerry.cpp
1694         https://bugs.webkit.org/show_bug.cgi?id=74381
1695
1696         Reviewed by Rob Buis.
1697
1698         Main contributor:
1699         Mike Fenton <mifenton@rim.com>
1700
1701         Initial upstream, no new tests.
1702
1703         * platform/blackberry/ClipboardBlackBerry.cpp: Added.
1704         * platform/blackberry/ClipboardBlackBerry.h: Added.
1705         * platform/blackberry/PasteboardBlackBerry.cpp: Added.
1706
1707 2011-12-13  James Robinson  <jamesr@chromium.org>
1708
1709         Unreviewed, rolling out r102726.
1710         http://trac.webkit.org/changeset/102726
1711         https://bugs.webkit.org/show_bug.cgi?id=74154
1712
1713         Does not compile on clang
1714
1715         * platform/graphics/chromium/TiledLayerChromium.cpp:
1716         (WebCore::UpdatableTile::UpdatableTile):
1717         (WebCore::TiledLayerChromium::createTile):
1718         * platform/graphics/chromium/cc/CCLayerTilingData.cpp:
1719         (WebCore::CCLayerTilingData::addTile):
1720         (WebCore::CCLayerTilingData::takeTile):
1721         (WebCore::CCLayerTilingData::tileAt):
1722         * platform/graphics/chromium/cc/CCLayerTilingData.h:
1723         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
1724         (WebCore::DrawableTile::DrawableTile):
1725         (WebCore::CCTiledLayerImpl::createTile):
1726
1727 2011-12-13  Hajime Morrita  <morrita@chromium.org>
1728
1729         Unreviewed, rolling out r102732.
1730         http://trac.webkit.org/changeset/102732
1731
1732         The last fix makes no sense...
1733
1734         * platform/graphics/chromium/cc/CCLayerTilingData.h:
1735
1736 2011-12-13  Hajime Morrita  <morrita@chromium.org>
1737
1738         HTML details summary not working with form controls
1739         https://bugs.webkit.org/show_bug.cgi?id=74398
1740
1741         Reviewed by Kent Tamura.
1742
1743         Allowed HTMLSummaryElement to skip the toggle logic if the event
1744         target is a form control.
1745
1746         Test: fast/html/details-click-controls.html
1747
1748         * html/HTMLSummaryElement.cpp:
1749         (WebCore::isClickableControl):
1750         (WebCore::HTMLSummaryElement::defaultEventHandler):
1751
1752 2011-12-13  James Wei <james.wei@intel.com> 
1753
1754         Optimize to not use pow() in the inner loop in AudioParamTimeline
1755         https://bugs.webkit.org/show_bug.cgi?id=73530
1756
1757         Reviewed by Kenneth Russell.
1758
1759         No new tests.
1760
1761         * webaudio/AudioParamTimeline.cpp:
1762         (WebCore:AudioParamTimeline:valuesForTimeRangeImpl):
1763
1764 2011-12-13  Hajime Morrita  <morrita@chromium.org>
1765
1766         Unreviewed Chromium-Mac build fix trial.
1767
1768         * platform/graphics/chromium/cc/CCLayerTilingData.h:
1769
1770 2011-12-13  David Reveman  <reveman@chromium.org>
1771
1772         [Chromium] Initialize Settings::m_perTileDrawingEnabled properly.
1773         https://bugs.webkit.org/show_bug.cgi?id=74476
1774
1775         Reviewed by James Robinson.
1776
1777         Add m_perTileDrawingEnabled(false) to WebCore::Settings initialize list.
1778
1779         No new tests.
1780
1781         * page/Settings.cpp:
1782         (WebCore::Settings::Settings):
1783
1784 2011-12-13  Anders Carlsson  <andersca@apple.com>
1785
1786         Add a very bare-bones implementation of bind and Function to WTF
1787         https://bugs.webkit.org/show_bug.cgi?id=74462
1788
1789         Reviewed by Sam Weinig.
1790
1791         Add a forwarding header for Functional.h.
1792
1793         * ForwardingHeaders/wtf/Functional.h: Added.
1794
1795 2011-12-13  Adrienne Walker  <enne@google.com>
1796
1797         [chromium] Use HashMap<..., OwnPtr<Tile>> for compositor tilemap
1798         https://bugs.webkit.org/show_bug.cgi?id=74154
1799
1800         Reviewed by James Robinson.
1801
1802         After r102410 landed, it's now possible to properly use an OwnPtr to
1803         store tiles rather than hackily use a RefPtr.
1804
1805         Covered by the compositing/ layout tests.
1806
1807         * platform/graphics/chromium/TiledLayerChromium.cpp:
1808         (WebCore::UpdatableTile::create):
1809         (WebCore::UpdatableTile::UpdatableTile):
1810         (WebCore::TiledLayerChromium::createTile):
1811         * platform/graphics/chromium/cc/CCLayerTilingData.cpp:
1812         (WebCore::CCLayerTilingData::addTile):
1813         (WebCore::CCLayerTilingData::takeTile):
1814         (WebCore::CCLayerTilingData::tileAt):
1815         * platform/graphics/chromium/cc/CCLayerTilingData.h:
1816         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
1817         (WebCore::DrawableTile::create):
1818         (WebCore::DrawableTile::DrawableTile):
1819         (WebCore::CCTiledLayerImpl::createTile):
1820
1821 2011-12-13  Dmitry Lomov  <dslomov@google.com>
1822
1823         https://bugs.webkit.org/show_bug.cgi?id=73691
1824         [JSC] Implement correct order of window.postMessage arguments.
1825         This change supports a new signature of windowPostMessage:
1826           postMessage(message, targetOrigin[, transferrables])
1827         as well as the legacy webkit-proprietary:
1828           postMessage(message, [transferrables,] targetOrigin)
1829         The latter is only supported for cases when targetOrigin is a String.
1830
1831         Reviewed by David Levin.
1832
1833         * bindings/js/JSDOMWindowCustom.cpp:
1834         (WebCore::handlePostMessage):
1835         * page/DOMWindow.idl:
1836
1837 2011-12-13  Rafael Weinstein  <rafaelw@chromium.org>
1838
1839         [MutationObservers] Avoid allocations if no observers are present
1840         https://bugs.webkit.org/show_bug.cgi?id=74423
1841
1842         Reviewed by Ojan Vafai.
1843
1844         This patch adds Node::mayHaveMutationObserversOfType which can be used to check
1845         if there are any observers at all which could receive a give type of mutation.
1846         MutationObserverInterestGroup uses this to possibly exit early (returning
1847         null) if no observers are present.
1848
1849         No tests needed. This patch is just a refactor.
1850
1851         * css/CSSMutableStyleDeclaration.cpp:
1852         * dom/CharacterData.cpp:
1853         (WebCore::CharacterData::dispatchModifiedEvent):
1854         * dom/ChildListMutationScope.cpp:
1855         (WebCore::ChildListMutationAccumulator::MutationAccumulationRouter::incrementScopingLevel):
1856         * dom/Element.cpp:
1857         (WebCore::enqueueAttributesMutationRecord):
1858         * dom/Node.cpp:
1859         (WebCore::Node::mayHaveMutationObserversOfType):
1860         * dom/Node.h:
1861         * dom/WebKitMutationObserver.cpp:
1862         (WebCore::MutationObserverInterestGroup::createIfNeeded):
1863         (WebCore::MutationObserverInterestGroup::createForChildListMutation):
1864         (WebCore::MutationObserverInterestGroup::createForCharacterDataMutation):
1865         (WebCore::MutationObserverInterestGroup::createForAttributesMutation):
1866         (WebCore::MutationObserverInterestGroup::MutationObserverInterestGroup):
1867         (WebCore::MutationObserverInterestGroup::enqueueMutationRecord):
1868         * dom/WebKitMutationObserver.h:
1869
1870 2011-12-13  Robin Dunn  <robin@alldunn.com>
1871
1872         Don't make the bitmap transparent when using theme drawing
1873         calls that don't support transparent bitmaps.
1874         https://bugs.webkit.org/show_bug.cgi?id=74319
1875
1876         Reviewed by Kevin Ollivier.
1877
1878         * platform/wx/LocalDC.h:
1879         (WebCore::LocalDC::LocalDC):
1880         * platform/wx/RenderThemeWx.cpp:
1881         (WebCore::RenderThemeWx::paintButton):
1882
1883 2011-12-13  Tony Chang  <tony@chromium.org>
1884
1885         Inline all of initForRegionStyling except for the rarely used part for non-null regions.
1886         https://bugs.webkit.org/show_bug.cgi?id=74435
1887
1888         Reviewed by Andreas Kling.
1889
1890         * css/CSSStyleSelector.cpp:
1891         (WebCore::CSSStyleSelector::initForRegionStyling): Inline setting of m_regionForStyling
1892         (WebCore::CSSStyleSelector::initRegionRules): Move code that only
1893         applies to CSSRegions into non-inlined code.
1894         * css/CSSStyleSelector.h:
1895
1896 2011-12-13  James Simonsen  <simonjam@chromium.org>
1897
1898         Unreviewed, Chromium Mac build fix.
1899
1900         * page/PerformanceTiming.h:
1901
1902 2011-12-13  Adam Klein  <adamk@chromium.org>
1903
1904         Update variable names in NamedNodeMap methods to match WebKit style
1905         https://bugs.webkit.org/show_bug.cgi?id=74437
1906
1907         Reviewed by Ojan Vafai.
1908
1909         While reading these methods in preparation for a refactor, I found
1910         them hard to understand due to short or confusing variable names.
1911         I think the new names are much clearer, and match WebKit style.
1912
1913         * dom/NamedNodeMap.cpp:
1914         (WebCore::NamedNodeMap::setNamedItem):
1915         (WebCore::NamedNodeMap::removeNamedItem):
1916
1917 2011-12-13  Xingnan Wang  <xingnan.wang@intel.com>
1918
1919         Implement a function of vector multiply with SSE2 optimization in VectorMath.cpp.
1920         https://bugs.webkit.org/show_bug.cgi?id=74048
1921
1922         Reviewed by Benjamin Poulain.
1923
1924         The vmul is a function for an element-by-element multiply of two float vectors and we 
1925         get about 3.4x performance improvement with SSE2 optimization compared with the common 
1926         multiply.
1927
1928         Use vmul in AudioBus::copyWithSampleAccurateGainValuesFrom().
1929
1930         * platform/audio/AudioBus.cpp:
1931         (WebCore::AudioBus::copyWithSampleAccurateGainValuesFrom):
1932         * platform/audio/VectorMath.cpp:
1933         (WebCore::VectorMath::vmul):
1934         * platform/audio/VectorMath.h:
1935
1936 2011-12-13  Vsevolod Vlasov  <vsevik@chromium.org>
1937
1938         Web Inspector: [Regression] ResourceHeadersView sections should be expanded by default.
1939         https://bugs.webkit.org/show_bug.cgi?id=74434
1940
1941         Reviewed by Pavel Feldman.
1942
1943         * inspector/front-end/treeoutline.js:
1944
1945 2011-12-13  Vsevolod Vlasov  <vsevik@chromium.org>
1946
1947         Web Inspector: Network item view does not correctly decode "+" in request parameters.
1948         https://bugs.webkit.org/show_bug.cgi?id=74422
1949
1950         Reviewed by Pavel Feldman.
1951
1952         Test: http/tests/inspector/network/request-parameters-decoding.html
1953
1954         * inspector/front-end/ResourceHeadersView.js:
1955         (WebInspector.ResourceHeadersView.prototype._formatParameter):
1956         (WebInspector.ResourceHeadersView.prototype._refreshParms):
1957
1958 2011-12-13  Alok Priyadarshi  <alokp@chromium.org>
1959
1960         [chromium] compositing/masks layout tests fail with accelerated drawing
1961         https://bugs.webkit.org/show_bug.cgi?id=72760
1962
1963         Reviewed by Stephen White.
1964
1965         Accelerated drawing path used to render bottom-up upright textures, which was opposite of what the software path rendered.
1966         The textures produced by the accelerated path was flipped along Y in the shader to make it upside down as expected by the compositor.
1967         This strategy does not work in case of masks which do not go through a shader and hence do not get flipped,
1968         which results in a case where texture in the render surface is top-down, while that in the mask is bottom-up.
1969         This patch makes accelerated drawing path render textures in the same orientation as the software path.
1970         LayerTextureUpdater::Orientation was added to support the difference in texture orientation between software and accelerated paths.
1971         Now that both paths produce textures in the same orientation, there is no need for it.
1972
1973         No new tests needed. Covered by existing compositing tests.
1974
1975         * platform/graphics/chromium/BitmapCanvasLayerTextureUpdater.h:
1976         * platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.h:
1977         * platform/graphics/chromium/FrameBufferSkPictureCanvasLayerTextureUpdater.cpp:
1978         (WebCore::FrameBufferSkPictureCanvasLayerTextureUpdater::updateTextureRect):
1979         * platform/graphics/chromium/FrameBufferSkPictureCanvasLayerTextureUpdater.h:
1980         * platform/graphics/chromium/ImageLayerChromium.cpp:
1981         * platform/graphics/chromium/LayerTextureUpdater.h:
1982         * platform/graphics/chromium/TiledLayerChromium.cpp:
1983         (WebCore::TiledLayerChromium::TiledLayerChromium):
1984         (WebCore::TiledLayerChromium::setLayerTreeHost):
1985         (WebCore::TiledLayerChromium::pushPropertiesTo):
1986         * platform/graphics/chromium/TiledLayerChromium.h:
1987         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
1988         (WebCore::CCTiledLayerImpl::drawTiles):
1989         * platform/graphics/chromium/cc/CCTiledLayerImpl.h:
1990         (WebCore::CCTiledLayerImpl::setSkipsDraw):
1991
1992 2011-12-09  Zhenyao Mo  <zmo@google.com>
1993
1994         Implement GLES2 CheckFramebufferStatus() behavior
1995         https://bugs.webkit.org/show_bug.cgi?id=74228
1996
1997         Reviewed by Kenneth Russell.
1998
1999         * html/canvas/WebGLFramebuffer.cpp:
2000         (WebCore::WebGLFramebuffer::getColorBufferWidth): Add ColorBuffer to the function name - this is more accurate.
2001         (WebCore::WebGLFramebuffer::getColorBufferHeight): Ditto.
2002         (WebCore::WebGLFramebuffer::checkStatus): Implement full semantics of GLES2 glCheckFramebufferStatus().
2003         (WebCore::WebGLFramebuffer::onAccess): Call checkStatus().
2004         * html/canvas/WebGLFramebuffer.h:
2005         * html/canvas/WebGLRenderingContext.cpp:
2006         (WebCore::WebGLRenderingContext::checkFramebufferStatus): Call checkStatus().
2007         (WebCore::WebGLRenderingContext::getFramebufferAttachmentParameter): No longer check framebuffer status.
2008         (WebCore::WebGLRenderingContext::getBoundFramebufferWidth): Call getColorBufferWidth.
2009         (WebCore::WebGLRenderingContext::getBoundFramebufferHeight): Call getColorBufferHeight.
2010
2011 2011-12-13  James Simonsen  <simonjam@chromium.org>
2012
2013         [Navigation Timing] Use monotonicallyIncreasingTime() instead of currentTime()
2014         https://bugs.webkit.org/show_bug.cgi?id=58354
2015
2016         Reviewed by Pavel Feldman.
2017
2018         No new tests. Relies on existing webtiming-* tests.
2019
2020         * CMakeLists.txt:
2021         * GNUmakefile.list.am:
2022         * WebCore.gypi:
2023         * WebCore.pro:
2024         * WebCore.vcproj/WebCore.vcproj:
2025         * WebCore.xcodeproj/project.pbxproj:
2026         * dom/Document.cpp: Use monotonic times.
2027         (WebCore::Document::setReadyState):
2028         (WebCore::Document::finishedParsing):
2029         * inspector/InspectorInstrumentation.cpp:
2030         (WebCore::InspectorInstrumentation::didFinishLoadingImpl): Convert monotonicFinishTime to wall time if needed.
2031         * inspector/InspectorResourceAgent.cpp:
2032         (WebCore::buildObjectForTiming): Convert monotonic requestTime to wall time.
2033         (WebCore::buildObjectForResourceResponse): Plumbing for above.
2034         (WebCore::buildObjectForCachedResource): Ditto.
2035         (WebCore::InspectorResourceAgent::willSendRequest): Ditto.
2036         (WebCore::InspectorResourceAgent::didReceiveResponse): Ditto.
2037         (WebCore::InspectorResourceAgent::didLoadResourceFromMemoryCache): Ditto.
2038         * loader/DocumentLoadTiming.cpp: Added.
2039         (WebCore::DocumentLoadTiming::DocumentLoadTiming):
2040         (WebCore::DocumentLoadTiming::setNavigationStart): Determine reference time and root reference time.
2041         (WebCore::DocumentLoadTiming::addRedirect): Moved logic from MainResourceLoader.
2042         (WebCore::DocumentLoadTiming::convertMonotonicTimeToDocumentTime): Helper to compute wall time from monotonic time.
2043         * loader/DocumentLoadTiming.h: Turned into class. Made times monotonic.
2044         (WebCore::DocumentLoadTiming::setUnloadEventStart):
2045         (WebCore::DocumentLoadTiming::setUnloadEventEnd):
2046         (WebCore::DocumentLoadTiming::setRedirectStart):
2047         (WebCore::DocumentLoadTiming::setRedirectEnd):
2048         (WebCore::DocumentLoadTiming::setFetchStart):
2049         (WebCore::DocumentLoadTiming::setResponseEnd):
2050         (WebCore::DocumentLoadTiming::setLoadEventStart):
2051         (WebCore::DocumentLoadTiming::setLoadEventEnd):
2052         (WebCore::DocumentLoadTiming::setHasSameOriginAsPreviousDocument):
2053         (WebCore::DocumentLoadTiming::navigationStart):
2054         (WebCore::DocumentLoadTiming::unloadEventStart):
2055         (WebCore::DocumentLoadTiming::unloadEventEnd):
2056         (WebCore::DocumentLoadTiming::redirectStart):
2057         (WebCore::DocumentLoadTiming::redirectEnd):
2058         (WebCore::DocumentLoadTiming::redirectCount):
2059         (WebCore::DocumentLoadTiming::fetchStart):
2060         (WebCore::DocumentLoadTiming::responseEnd):
2061         (WebCore::DocumentLoadTiming::loadEventStart):
2062         (WebCore::DocumentLoadTiming::loadEventEnd):
2063         (WebCore::DocumentLoadTiming::hasCrossOriginRedirect):
2064         (WebCore::DocumentLoadTiming::hasSameOriginAsPreviousDocument):
2065         * loader/FrameLoader.cpp:
2066         (WebCore::FrameLoader::stopLoading):
2067         (WebCore::FrameLoader::commitProvisionalLoad):
2068         (WebCore::FrameLoader::continueLoadAfterWillSubmitForm):
2069         (WebCore::FrameLoader::loadProvisionalItemFromCachedPage):
2070         * loader/MainResourceLoader.cpp:
2071         (WebCore::MainResourceLoader::continueAfterNavigationPolicy):
2072         (WebCore::MainResourceLoader::willSendRequest): Moved logic to DocumentLoadTiming.
2073         (WebCore::MainResourceLoader::didReceiveData): Use monotonic time.
2074         (WebCore::MainResourceLoader::didFinishLoading): Ditto.
2075         (WebCore::MainResourceLoader::load):
2076         * page/DOMWindow.cpp:
2077         (WebCore::DOMWindow::dispatchLoadEvent):
2078         * page/DOMWindow.h: Removed dispatchTimedEvent. It doesn't really help in the new model.
2079         * page/PerformanceNavigation.cpp:
2080         (WebCore::PerformanceNavigation::redirectCount):
2081         * page/PerformanceTiming.cpp: Removed skew correction code. This should never happen now.
2082         (WebCore::PerformanceTiming::navigationStart):
2083         (WebCore::PerformanceTiming::unloadEventStart):
2084         (WebCore::PerformanceTiming::unloadEventEnd):
2085         (WebCore::PerformanceTiming::redirectStart):
2086         (WebCore::PerformanceTiming::redirectEnd):
2087         (WebCore::PerformanceTiming::fetchStart):
2088         (WebCore::PerformanceTiming::responseEnd):
2089         (WebCore::PerformanceTiming::domLoading):
2090         (WebCore::PerformanceTiming::domInteractive):
2091         (WebCore::PerformanceTiming::domContentLoadedEventStart):
2092         (WebCore::PerformanceTiming::domContentLoadedEventEnd):
2093         (WebCore::PerformanceTiming::domComplete):
2094         (WebCore::PerformanceTiming::loadEventStart):
2095         (WebCore::PerformanceTiming::loadEventEnd):
2096         (WebCore::PerformanceTiming::resourceLoadTimeRelativeToAbsolute): Used for ResourceLoadTiming.
2097         (WebCore::PerformanceTiming::monotonicTimeToIntegerMilliseconds): Used for DocumentTiming and DocumentLoadTiming.
2098         * page/PerformanceTiming.h:
2099         * platform/network/ResourceLoadTiming.cpp:
2100         (WebCore::ResourceLoadTiming::convertResourceLoadTimeToDocumentTime):
2101         * platform/network/ResourceLoadTiming.h: Added helper function to convert to wall times. Added instructions for use.
2102
2103 2011-12-13  Adam Klein  <adamk@chromium.org>
2104
2105         Reduce code duplication in Element::setAttribute methods
2106         https://bugs.webkit.org/show_bug.cgi?id=74425
2107
2108         Reviewed by Ryosuke Niwa.
2109
2110         Two overloads of Element::setAttribute share almost all their code,
2111         including tricky logic around updating the appropriate Attribute and
2112         Attr objects and notifying the Inspector and MutationObservers.
2113
2114         This patch puts the common logic in a new setAttributeInternal method
2115         which is called by the other two.
2116
2117         No new tests, refactoring only.
2118
2119         * dom/Element.cpp:
2120         (WebCore::Element::setAttribute):
2121         (WebCore::Element::setAttributeInternal):
2122         * dom/Element.h:
2123
2124 2011-12-13  Brady Eidson  <beidson@apple.com>
2125
2126         <http://webkit.org/b/74420> Disable deprecation warnings around more code where we 
2127         cannot easily switch away from the deprecated APIs.
2128
2129         Reviewed by Mark Rowe.
2130
2131         * bindings/objc/DOMInternal.mm:
2132         * bridge/objc/objc_instance.mm:
2133
2134 2011-12-12  Robert Hogan  <robert@webkit.org>
2135
2136         CSS 2.1 failure: eof-002.htm fails
2137         https://bugs.webkit.org/show_bug.cgi?id=74309
2138
2139         Reviewed by Dean Jackson.
2140
2141         Test: css2.1/20110323/eof-002-expected.html
2142
2143         * css/CSSGrammar.y: Treat EOF during a function expression with an open parenthesis as a close parenthesis.
2144
2145 2011-12-13  Adam Klein  <adamk@chromium.org>
2146
2147         V8Proxy cleanup: replace custom logging methods with standard WebCore calls
2148         https://bugs.webkit.org/show_bug.cgi?id=74220
2149
2150         Reviewed by Adam Barth.
2151
2152         * bindings/v8/V8Proxy.cpp:
2153         (WebCore::V8Proxy::reportUnsafeAccessTo):
2154         * bindings/v8/V8Proxy.h:
2155         * bindings/v8/custom/V8CustomXPathNSResolver.cpp:
2156         (WebCore::V8CustomXPathNSResolver::lookupNamespaceURI):
2157
2158 2011-12-13  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
2159
2160         [Qt] Get rid of layering violations in includes
2161
2162         WebKit/qt/API and WebKit/qt/WebCoreSupport should not be included
2163         in the webcore.prf, but rather in each target that specificly needs
2164         headers in these location. We used to include them directly in webcore
2165         since we had layering violations between WebCore and WebKit, but now
2166         that they are gone there's no reason to do that.
2167
2168         Reviewed by Simon Hausmann.
2169
2170         * bridge/qt/qt_instance.cpp:
2171         * platform/graphics/qt/GraphicsContext3DQt.cpp:
2172         * platform/graphics/qt/ImageQt.cpp:
2173         * platform/network/qt/QNetworkReplyHandler.cpp:
2174         * platform/network/qt/ResourceHandleQt.cpp:
2175         * platform/qt/CookieJarQt.cpp:
2176         * platform/qt/RenderThemeQStyle.cpp:
2177         * platform/qt/RenderThemeQt.cpp:
2178
2179 2011-12-13  Vsevolod Vlasov  <vsevik@chromium.org>
2180
2181         Web Inspector: Add scripts navigator sidebar to scripts panel.
2182         https://bugs.webkit.org/show_bug.cgi?id=73086
2183
2184         Reviewed by Pavel Feldman.
2185
2186         * WebCore.gypi:
2187         * WebCore.vcproj/WebCore.vcproj:
2188         * inspector/compile-front-end.sh:
2189         * inspector/front-end/Images/domain.png: Added.
2190         * inspector/front-end/JavaScriptSourceFrame.js:
2191         (WebInspector.JavaScriptSourceFrame.prototype.suggestedFileName):
2192         * inspector/front-end/ScriptsNavigator.js: Added.
2193         * inspector/front-end/ScriptsPanel.js:
2194         (WebInspector.ScriptsPanel.prototype._uiSourceCodeAdded.get if):
2195         (WebInspector.ScriptsPanel.prototype._uiSourceCodeRemoved):
2196         (WebInspector.ScriptsPanel.prototype._addOptionToFilesSelect):
2197         (WebInspector.ScriptsPanel.prototype._reset):
2198         (WebInspector.ScriptsPanel.prototype._removeSourceFrame):
2199         (WebInspector.ScriptsPanel.prototype._uiSourceCodeReplaced):
2200         (WebInspector.ScriptsPanel.prototype._sourceFrameLoaded):
2201         (WebInspector.ScriptsPanel.prototype._updateExecutionLine):
2202         (WebInspector.ScriptsPanel.prototype._scriptSelectedInNavigator):
2203         (WebInspector.ScriptsPanel.prototype._createDebugToolbar):
2204         * inspector/front-end/Settings.js:
2205         * inspector/front-end/TabbedPane.js:
2206         (WebInspector.TabbedPane.prototype.appendTab):
2207         (WebInspector.TabbedPane.prototype.selectTab):
2208         (WebInspector.TabbedPane.prototype.highlightLine):
2209         (WebInspector.TabbedPane.prototype.elementsToRestoreScrollPositionsFor):
2210         * inspector/front-end/UISourceCode.js:
2211         (WebInspector.UISourceCode.prototype.get domain):
2212         (WebInspector.UISourceCode.prototype.get folderName):
2213         (WebInspector.UISourceCode.prototype.get displayName):
2214         (WebInspector.UISourceCode.prototype._parseURL):
2215         * inspector/front-end/WebKit.qrc:
2216         * inspector/front-end/inspector.css:
2217         (.tabbed-pane):
2218         (.tabbed-pane-content):
2219         * inspector/front-end/inspector.html:
2220         * inspector/front-end/networkPanel.css:
2221         * inspector/front-end/scriptsPanel.css:
2222         (#scripts-navigator-resizer-widget):
2223         (.scripts-navigator-domain-tree-item .icon):
2224         (.scripts-navigator-folder-tree-item .icon):
2225         (.scripts-navigator-script-tree-item .icon):
2226         (.scripts.panel .navigator):
2227         (#scripts-navigator-tabbed-pane .tabbed-pane-header):
2228         (#scripts-navigator-tabbed-pane .tabbed-pane-content):
2229         (.scripts.panel .navigator li):
2230         (.scripts.panel .navigator :focus li.selected):
2231         (.scripts.panel .navigator li.selected .selection):
2232         (.scripts.panel .navigator :focus li.selected .selection):
2233         (.scripts.panel .navigator .icon):
2234         (.scripts.panel .base-navigator-tree-element-title):
2235         * inspector/front-end/treeoutline.js:
2236         (TreeOutline):
2237         (TreeOutline.prototype.appendChild):
2238
2239 2011-12-12  Andreas Kling  <kling@webkit.org>
2240
2241         CollectionCache: Remove unused copy constructor and make it noncopyable.
2242         <http://webkit.org/b/74378>
2243
2244         Reviewed by Simon Hausmann.
2245
2246         * html/CollectionCache.cpp:
2247         * html/CollectionCache.h:
2248
2249 2011-12-13  Jarred Nicholls  <jarred@sencha.com>
2250
2251         XHR should use m_responseTypeCode internally to be consistent with WebKit coding style
2252         https://bugs.webkit.org/show_bug.cgi?id=74330
2253
2254         Reviewed by Alexey Proskuryakov.
2255
2256         No new tests needed, no behavioral changes.
2257
2258         * xml/XMLHttpRequest.cpp:
2259         (WebCore::XMLHttpRequest::responseText):
2260         (WebCore::XMLHttpRequest::responseXML):
2261         (WebCore::XMLHttpRequest::responseBlob):
2262         (WebCore::XMLHttpRequest::didReceiveData):
2263         * xml/XMLHttpRequest.h:
2264         (WebCore::XMLHttpRequest::asBlob):
2265
2266 2011-12-13  Kentaro Hara  <haraken@chromium.org>
2267
2268         Use the [Supplemental] IDL for webaudio attributes in Chromium
2269         https://bugs.webkit.org/show_bug.cgi?id=73394
2270
2271         Reviewed by Adam Barth.
2272
2273         - Overview: Using the [Supplemental] IDL, this patch moves the attribute
2274         declarations of webaudio from DOMWindow.idl into a new IDL file
2275         webaudio/DOMWindowWebAudio.idl, which helps make webaudio a self-contained
2276         feature (aka a module).
2277
2278         - This patch changes the build flow of WebCore.gyp as follows:
2279
2280             Previous build flow:
2281                 foreach $idl (all IDL files) {
2282                     generate-bindings.pl depends on $idl;
2283                     generate-bindings.pl reads $idl;
2284                     generate-bindings.pl generates .h and .cpp files for $idl;
2285                 }
2286
2287             New build flow (See the discussions in bug 72138 for more details):
2288                 resolve-supplemental.pl depends on all IDL files;
2289                 resolve-supplemental.pl reads all IDL files;
2290                 resolve-supplemental.pl resolves the dependency of [Supplemental=XXXX];
2291                 resolve-supplemental.pl outputs supplemental_dependency.tmp;
2292                 foreach $idl (all IDL files) {
2293                     generate-bindings.pl depends on $idl and supplemental_dependency.tmp;
2294                     generate-bindings.pl reads $idl;
2295                     generate-bindings.pl reads supplemental_dependency.tmp;
2296                     generate-bindings.pl generates .h and .cpp files for $idl, including all attributes in IDL files whilementing $idl;
2297                 }
2298
2299         - This patch introduces a temporary IDL, [Supplemented]. The [Supplemented] IDL
2300         will be removed after build scripts for all platforms support the [Supplemental] IDL.
2301         The motivation for the [Supplemented] IDL is as follows:
2302
2303         In order to support the [Supplemental] IDL, we need to
2304         (1) run resolve-supplemental.pl and generate supplemental_dependency.tmp
2305         (2) and run generate-bindings.pl with the supplemental_dependency.tmp.
2306
2307         This build flow requires a change on the following build scripts,
2308         but changing all the build scripts all at once without any regression is too difficult:
2309
2310             - DerivedSources.make
2311             - DerivedSources.pri
2312             - GNUmakefile.am
2313             - PlatformBlackBerry.cmake
2314             - UseJSC.cmake
2315             - UseV8.cmake
2316             - WebCore.vcproj/MigrateScripts
2317             - WebCore.vcproj/WebCore.vcproj
2318             - bindings/gobject/GNUmakefile.am
2319             - WebCore.gyp/WebCore.gyp
2320
2321         Thus, we are planning to change the build scripts one by one, which implies that
2322         we need to allow the temporary state in which some build scripts support [Supplemental] IDL
2323         but others do not. To accomplish this, we introduce a temporary IDL, [Supplemented].
2324         The [Supplemented] IDL on an attribute means that the attribute is marked with [Supplemental]
2325         in another IDL file somewhere, like this:
2326
2327             DOMWindowWebAudio.idl:
2328                 interface [
2329                     Supplemental=DOMWindow
2330                 ] DOMWindowWebAudio {
2331                     attribute attr1;
2332                     attribute attr2;
2333                 };
2334
2335             DOMWindow.idl:
2336                 interface [
2337                 ] DOMWindow {
2338                     attribute [Supplemented] attr1; // This line will be removed after all build scripts support the [Su IDL
2339                     attribute [Supplemented] attr2; // This line will be removed after all build scripts support the [Su IDL.
2340                     attribute attr3;
2341                     attribute attr4;
2342                 };
2343
2344         Assuming these IDL files, this patch implements the following logic in generate-bindings.pl:
2345
2346             - If a given build script supports the [Supplemental] IDL,
2347             generate-bindings.pl ignores all attributes with the [Supplemented] IDL.
2348             - Otherwise, generate-bindings.pl treats all attributes with the [Supplemented] IDL
2349             as normal attributes and instead ignores all attributes with the [Supplemental] IDL
2350             (i.e. generate-bindings.pl generates nothing from the IDL file with the [Supplemental] IDL).
2351
2352         Tests: webaudio/*
2353
2354         * WebCore.gyp/WebCore.gyp: Describes the build flow that I described above.
2355         * WebCore.gyp/scripts/action_derivedsourcesallinone.py:
2356         (main): Reads the IDL file names from the input file (i.e. supplemental_dependency.tmp),
2357         which are described at the first column of each line in the input file.
2358         If the file name is a "/cygdrive/c/..."-style path, it is converted to a "C:\cygwin\..."-style
2359         path by the cygpath command.
2360         * WebCore.gypi: Added DOMWindowWebAudio.idl.
2361         * bindings/scripts/generate-bindings.pl: As a temporary solution, if the platform does not
2362         support the [Supplemental] IDL, the perl script ignores the [Supplemental] IDL and instead
2363         uses the [Supplemented] IDL. Otherwise, the perl script ignores the [Supplemented] IDL and
2364         instead uses the [Supplemental] IDL.
2365         Added the --additionalIdlFilesList option to specify the IDL files that are not listed in
2366         supplemental-dependency.tmp but should generate .h and .cpp files.
2367         * page/DOMWindow.idl: Added the [Supplemented] IDL to webaudio-related attributes.
2368         As I described above, the [Supplemented] IDL will be removed after all platforms support
2369         the [Supplemental] IDL.
2370         * webaudio/DOMWindowWebAudio.idl: Added. Describes the [Supplemental=DOMWindow] IDL.
2371         The attributes in this IDL file should be treated as if they are written in DOMWindow.idl.
2372
2373 2011-12-13  Yosifumi Inoue  <yosin@chromium.org>
2374
2375         RenderTheme should have a function for disabled text color adjustment
2376         https://bugs.webkit.org/show_bug.cgi?id=74143
2377
2378         Change disabledTextColor to private method.
2379
2380         Reviewed by Kent Tamura.
2381
2382         No new tests / existing tests cover this change.
2383
2384         * rendering/RenderThemeChromiumMac.h: Change disabledTextColor to private.
2385         * rendering/RenderThemeChromiumSkia.h: Change disabledTextColor to private.
2386
2387 2011-12-12  Daniel Bates  <dbates@webkit.org>
2388
2389         Unreviewed, rolling out r102656.
2390         http://trac.webkit.org/changeset/102656
2391         https://bugs.webkit.org/show_bug.cgi?id=74313
2392
2393         Broke the Mac, Windows and WinCairo builds. We need to look
2394         into this patch some more.
2395
2396         * bindings/js/ScriptEventListener.cpp:
2397         (WebCore::eventListenerHandlerLocation):
2398
2399 2011-12-12  Konrad Piascik  <kpiascik@rim.com>
2400
2401         2011-12-12  Konrad Piascik  <kpiascik@rim.com>
2402
2403         Implement the JavaScriptCore bindings for eventListenerHandlerLocation
2404         https://bugs.webkit.org/show_bug.cgi?id=74313
2405
2406         Reviewed by Geoffrey Garen.
2407
2408         Open any page in Web Inspector and look at the event listeners. They should now
2409         link to the script which created them.
2410
2411         * bindings/js/ScriptEventListener.cpp:
2412         (WebCore::eventListenerHandlerLocation):
2413
2414 2011-12-12  Yosifumi Inoue  <yosin@chromium.org>
2415
2416         RenderTheme should have a function for disabled text color adjustment
2417         https://bugs.webkit.org/show_bug.cgi?id=74143
2418
2419         Reviewed by Kent Tamura.
2420
2421         No new tests / existing tests cover this change.
2422
2423         * rendering/RenderTextControl.cpp:
2424         (WebCore::RenderTextControl::adjustInnerTextStyle): Use RenderTheme::disabledTextColor instead of PLATFORM wraped static function. 
2425         * rendering/RenderTheme.cpp:
2426         (WebCore::RenderTheme::disabledTextColor): Moved from RenderTextControl.cpp. This method implements for non-Chromium color.
2427         * rendering/RenderTheme.h: Add new virtual method disabledTextColor.
2428         * rendering/RenderThemeChromiumMac.h: Implementation of RenderTheme::disabledTextColor for Chrimium Mac.
2429         * rendering/RenderThemeChromiumSkia.h: Implementation of RenderTheme::disabledTextColor for Chrimium.
2430
2431 2011-12-12  Kenneth Russell  <kbr@google.com>
2432
2433         Unreviewed, rolling out r102648.
2434         http://trac.webkit.org/changeset/102648
2435         https://bugs.webkit.org/show_bug.cgi?id=74313
2436
2437         Broke the Snow Leopard and Windows builds
2438
2439         * bindings/js/ScriptEventListener.cpp:
2440         (WebCore::eventListenerHandlerLocation):
2441
2442 2011-12-12  Andreas Kling  <kling@webkit.org>
2443
2444         Resizing Cappuccino is very laggy on WebKit since Safari 5.1
2445         <http://webkit.org/b/71354> and <rdar://problem/10565998>
2446
2447         Reviewed by Anders Carlsson.
2448
2449         * WebCore.exp.in: Export FloatPoint(const NSPoint&)
2450
2451 2011-12-12  Jarred Nicholls  <jarred@sencha.com>
2452
2453         [Qt] QTKIT-based video support must target OS X 10.5 or higher
2454         https://bugs.webkit.org/show_bug.cgi?id=74294
2455
2456         WebCore on OS X Lion fails to build when QTKIT video support is enabled, unless a
2457         deployment target of 10.5+ is specified explicitly.
2458
2459         Reviewed by Noam Rosenthal.
2460
2461         No new tests as this is a build issue.
2462
2463         * Target.pri:
2464
2465 2011-12-12  Luke Macpherson   <macpherson@chromium.org>
2466
2467         Implement CSS text-decoration property in CSSStyleApplyProperty.
2468         https://bugs.webkit.org/show_bug.cgi?id=74258
2469
2470         Reviewed by Andreas Kling.
2471
2472         No new tests / refactoring only.
2473
2474         * css/CSSStyleApplyProperty.cpp:
2475         (WebCore::ApplyPropertyTextDecoration::applyValue):
2476         (WebCore::ApplyPropertyTextDecoration::createHandler):
2477         (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):
2478         * css/CSSStyleSelector.cpp:
2479         (WebCore::CSSStyleSelector::applyProperty):
2480
2481 2011-12-12  Adrienne Walker  <enne@google.com>
2482
2483         iframe fails to scroll in composited page
2484         https://bugs.webkit.org/show_bug.cgi?id=72682
2485
2486         Reviewed by Simon Fraser.
2487
2488         FrameView::scrollContentsSlowPath only was catching the case where a
2489         child iframe had a composited parent. Now detect if the child iframe
2490         has any composited ancestor.
2491
2492         Test: compositing/iframes/scroll-grandchild-iframe.html
2493
2494         * page/FrameView.cpp:
2495         (WebCore::FrameView::scrollContentsSlowPath):
2496
2497 2011-12-12  Konrad Piascik  <kpiascik@rim.com>
2498
2499         Implement the JavaScriptCore bindings for eventListenerHandlerLocation
2500         https://bugs.webkit.org/show_bug.cgi?id=74313
2501
2502         Reviewed by Geoffrey Garen. 
2503
2504         Open any page in Web Inspector and look at the event listeners. They should now
2505         link to the script which created them.
2506
2507         * bindings/js/ScriptEventListener.cpp:
2508         (WebCore::eventListenerHandlerLocation):
2509
2510 2011-12-12  Erik Arvidsson  <arv@chromium.org>
2511
2512         [V8] CodeGeneratorV8.pm does not correctly work with inherited HasIndexGetter
2513         https://bugs.webkit.org/show_bug.cgi?id=74027
2514
2515         Reviewed by Adam Barth.
2516
2517         Instead of having to write a custom indexer when the interface has an inherited indexer
2518         we get the signature from the super interface.
2519
2520         Tested by existing tests.
2521
2522         * Target.pri: Remove V8DOMSettableTokenListCustom.cpp and V8WebKitCSSFilterValueCustom.cpp.
2523         * UseV8.cmake: Ditto.
2524         * WebCore.gypi: Ditto.
2525         * bindings/scripts/CodeGenerator.pm:
2526         (FindSuperMethod): Returns the first matching function in one of the ancestor interfaces.
2527         * bindings/scripts/CodeGeneratorV8.pm:
2528         (GenerateImplementationIndexer): If the current interface has no indexer try to find an
2529                                          indexer in one of the super interfaces.
2530         (GenerateImplementationNamedPropertyGetter): Ditto for named property getter.
2531         * bindings/v8/custom/V8DOMSettableTokenListCustom.cpp: Removed.
2532         * bindings/v8/custom/V8WebKitCSSFilterValueCustom.cpp: Removed.
2533
2534 2011-12-12  Simon Fraser  <simon.fraser@apple.com>
2535
2536         Make it possible to substitute a different CALayer implementation for the main root layer
2537         https://bugs.webkit.org/show_bug.cgi?id=74369
2538
2539         Reviewed by Anders Carlsson.
2540         
2541         Some platforms may wish to have the main root layer (which corresponds with
2542         the main frame's RenderView's layer) implemented by a custom platform layer,
2543         for example to contain a cache of tiles.
2544         
2545         Make this possible on Mac by adding a new method to GraphicsLayerClient(),
2546         and implementing it in RenderLayerBacking. This new behavior is not yet enabled.
2547         
2548         Also clean up some WebLayer/WebTiledLayer code.
2549
2550         * WebCore.xcodeproj/project.pbxproj:
2551         * platform/graphics/GraphicsLayerClient.h:
2552         (WebCore::GraphicsLayerClient::shouldUseTileCache): New client method that indicates that the GraphicsLayer
2553         should host a tile cache layer instead of a normal layer.
2554         * platform/graphics/ca/GraphicsLayerCA.cpp:
2555         (WebCore::GraphicsLayerCA::GraphicsLayerCA): Ask the client, if any, whether to create a tile cache layer.
2556         * platform/graphics/ca/PlatformCALayer.h:
2557         * platform/graphics/ca/mac/PlatformCALayerMac.mm: NSClassFromString(@"CATransformLayer") was for Leopard;
2558         we can just use the classname now. Handle LayerTypeTileCacheLayer.
2559         (PlatformCALayer::PlatformCALayer):
2560         * platform/graphics/ca/mac/WebTileCacheLayer.h: Copied from Source/WebCore/platform/graphics/mac/WebLayer.h.
2561         * platform/graphics/ca/mac/WebTileCacheLayer.mm: Copied from Source/WebCore/platform/graphics/mac/WebLayer.h.
2562         * platform/graphics/mac/WebLayer.h: Remove the setLayerNeedsDisplayInRect() hackery.
2563         * platform/graphics/mac/WebLayer.mm: setLayerNeedsDisplayInRect() tried to share code between WebLayer and WebTiledLayer
2564         by using Obj-C runtime methods to find the superclass. This causes infinite recursion if Web[Tiled]Layer is subclassed,
2565         so remove it.
2566         (-[WebLayer setNeedsDisplayInRect:]): Code moved here from setLayerNeedsDisplayInRect.
2567         * platform/graphics/mac/WebTiledLayer.mm:
2568         (-[WebTiledLayer setNeedsDisplayInRect:]): Code copied here from setLayerNeedsDisplayInRect.
2569         * rendering/RenderLayerBacking.cpp:
2570         (WebCore::RenderLayerBacking::RenderLayerBacking): Find out, and cache if we're the main frame's layer.
2571         (WebCore::RenderLayerBacking::shouldUseTileCache): Return m_usingTiledCacheLayer, which is always false for now.
2572         (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer): Use m_isMainFrameRenderViewLayer.
2573         (WebCore::RenderLayerBacking::paintingGoesToWindow): The tile cache layer needs to paint itself.
2574         * rendering/RenderLayerBacking.h:
2575         * rendering/RenderLayerCompositor.h: m_compositeForFixedPosition was unused.
2576
2577 2011-12-12  Ryosuke Niwa  <rniwa@webkit.org>
2578
2579         REGRESSION(r102357): respondToUnappliedEditing exits early for CreateLinkCommand
2580         https://bugs.webkit.org/show_bug.cgi?id=74356
2581
2582         Reviewed by Enrica Casucci.
2583
2584         The problem was that isCreateLinkCommand was called on EditCommandComposition by respondToUnappliedEditing.
2585         Fixed the bug by propagating the value of isCreteLinkCommand from CompositeEditCommand to
2586         EditCommandComposition via wasCreateLinkCommand.
2587
2588         Also move isCreateLinkCommand from EditCommand to CompositeEditCommand to prevent this mistake in the future.
2589
2590         * editing/CompositeEditCommand.cpp:
2591         (WebCore::EditCommandComposition::create):
2592         (WebCore::EditCommandComposition::EditCommandComposition):
2593         (WebCore::CompositeEditCommand::ensureComposition):
2594         (WebCore::CompositeEditCommand::isCreateLinkCommand):
2595         * editing/CompositeEditCommand.h:
2596         (WebCore::EditCommandComposition::wasCreateLinkCommand):
2597         * editing/SpellingCorrectionController.cpp:
2598         (WebCore::SpellingCorrectionController::respondToUnappliedEditing):
2599         * editing/SpellingCorrectionController.h:
2600
2601 2011-12-12  Mihnea Ovidenie  <mihnea@adobe.com>
2602
2603         [CSSRegions]Revert RenderObject::style() to its state before region styling
2604         https://bugs.webkit.org/show_bug.cgi?id=74315
2605
2606         Reviewed by Tony Chang.
2607
2608         * rendering/RenderObject.h:
2609         (WebCore::RenderObject::style):
2610
2611 2011-12-12  Adam Klein  <adamk@chromium.org>
2612
2613         Don't crash in StyleAttributeMutationScope if the style declaration's element has been GCed
2614         https://bugs.webkit.org/show_bug.cgi?id=74321
2615
2616         Reviewed by Ryosuke Niwa.
2617
2618         In r101101, Rafael Weinstein added code to CSSMutableStyleDeclaration.cpp
2619         which depended on isInlineStyleDeclaration returning true iff the
2620         element it pointed to was non-null (it will be nulled-out if the
2621         element is garbage collected).
2622
2623         Then, in r101172, Andreas Kling changed the semantics so that
2624         isInlineStyleDeclaration only described the type of the declaration,
2625         not the state of the related element.
2626
2627         This change updates Rafael's code with an explicit check that the
2628         element is still alive.
2629
2630         Test: fast/dom/css-inline-style-declaration-crash.html
2631
2632         * css/CSSMutableStyleDeclaration.cpp:
2633
2634 2011-12-12  Chris Fleizach  <cfleizach@apple.com>
2635
2636         AX: aria-hidden inheritance broken when applying to some descendants
2637         https://bugs.webkit.org/show_bug.cgi?id=73940
2638
2639         Reviewed by Darin Adler.
2640
2641         When adding children, we were not updating the children cache for direct AX descendants.
2642         This meant that toggling aria-hidden could result in a stale cache where elements would not be reachable.
2643
2644         Making this fix also exposed a problem in AccessibilityTable where the AccessibilityHeaderObject was not
2645         being managed correctly as a mock element.
2646
2647         Test: platform/mac/accessibility/aria-hidden-changes-for-non-ignored-elements.html
2648
2649         * accessibility/AccessibilityRenderObject.cpp:
2650         (WebCore::AccessibilityRenderObject::addChildren):
2651         * accessibility/AccessibilityTable.cpp:
2652         (WebCore::AccessibilityTable::clearChildren):
2653         (WebCore::AccessibilityTable::headerContainer):
2654         * accessibility/AccessibilityTable.h:
2655
2656 2011-12-12  Jeremy Apthorp  <jeremya@chromium.org>
2657
2658         When the mouse is dragged out of an :active element, it should lose :hover.
2659         https://bugs.webkit.org/show_bug.cgi?id=57206
2660
2661         Reviewed by Ryosuke Niwa.
2662
2663         Test: fast/css/hover-active-drag.html
2664
2665         * page/EventHandler.cpp:
2666         (WebCore::EventHandler::handleMouseMoveEvent): Don't mark mouse-drag hit tests read-only, since they no longer are.
2667         (WebCore::EventHandler::dragSourceEndedAt): Send a hit test request when the mouse goes up after a drag, so
2668         RenderLayer has a chance to update the hover/active status.
2669         * rendering/RenderLayer.cpp:
2670         (WebCore::RenderLayer::updateHoverActiveState): Only allow the :active state to change on mouse down or mouse up.
2671
2672 2011-12-12  Kenneth Russell  <kbr@google.com>
2673
2674         Unreviewed Windows build fix after http://trac.webkit.org/changeset/102619 .
2675         Remove OVERRIDE specifier from virtual destructor.
2676
2677         * html/HTMLPlugInImageElement.h:
2678
2679 2011-12-12  Ryosuke Niwa  <rniwa@webkit.org>
2680
2681         WebKit code shouldn't be calling applyCommand directly
2682         https://bugs.webkit.org/show_bug.cgi?id=74337
2683
2684         Reviewed by Darin Adler.
2685
2686         Make WebKit-layer code call Editor::replaceSelectionWithFragment and Editor::replaceSelectionWithText
2687         instead of manually creating and applying ReplaceSelectionCommand.
2688
2689         The only behavioral difference is that new code will end up checking for spell checks. However, this
2690         difference appears to be unintentional since the code predates http://trac.webkit.org/changeset/73886,
2691         which introduced an invocation of spellcheck code.
2692
2693         Unfortunately no tests since there doesn't seem to be anyway to test this change.
2694
2695         * WebCore.exp.in:
2696         * editing/EditCommand.cpp:
2697         (WebCore::applyCommand):
2698         * editing/EditCommand.h:
2699         * editing/Editor.h:
2700
2701 2011-11-26  Adam Barth  <abarth@webkit.org>
2702
2703         Remove platform/audio/fftw
2704         https://bugs.webkit.org/show_bug.cgi?id=73163
2705
2706         Reviewed by Eric Seidel.
2707
2708         The FFTW library is GPL, not LGPL, like WebKit.  This patch removes the
2709         integration with the library so folks who use WebAudio don't
2710         accidentially violate the GPL by linking in FFTW.
2711
2712         * GNUmakefile.am:
2713         * WebCore.gyp/WebCore.gyp:
2714         * WebCore.gypi:
2715         * platform/audio/FFTFrame.h:
2716         * platform/audio/FFTFrameStub.cpp:
2717         * platform/audio/fftw: Removed.
2718         * platform/audio/fftw/FFTFrameFFTW.cpp: Removed.
2719
2720 2011-12-12  Kenneth Russell  <kbr@google.com>
2721
2722         COMPILE_ASSERT in CSSStyleSelector.cpp doesn't compile on Windows
2723         https://bugs.webkit.org/show_bug.cgi?id=74327
2724
2725         Unreviewed build fix. True fix should follow under above bug.
2726
2727         * css/CSSStyleSelector.cpp:
2728
2729 2011-12-12  David Grogan  <dgrogan@chromium.org>
2730
2731         Fix compilation error when !ENABLE(WORKERS)
2732         https://bugs.webkit.org/show_bug.cgi?id=74029
2733
2734         Reviewed by Yury Semikhatsky.
2735
2736         * storage/IDBFactory.cpp:
2737         (WebCore::IDBFactory::open): add #if ENABLE(WORKERS) guard
2738
2739 2011-12-12  Brady Eidson  <beidson@apple.com>
2740
2741         Page cache should support pages with plugins.
2742         <rdar://problem/5190122> and https://bugs.webkit.org/show_bug.cgi?id=13634
2743
2744         Reviewed by Anders Carlsson.
2745
2746         By making plugin elements renderers go display:none when entering the page cache,
2747         we destroy the plug-in in a cross platform way as well as handle invalidating script
2748         objects created by that plugin.
2749
2750         By restoring the original style when leaving the page cache and forcing a style recalc
2751         on the plugin element, the plugin is gracefully reinstantiated when the user goes back.
2752
2753         Test: plugins/netscape-plugin-page-cache-works.html
2754
2755         * dom/Document.cpp:
2756         (WebCore::Document::documentDidBecomeActive): Copy this collection before iterating over
2757           it, as the callbacks might result in mutating the set.
2758
2759         * dom/Node.h:
2760         (WebCore::Node::setHasCustomStyleForRenderer):
2761         (WebCore::Node::clearHasCustomStyleForRenderer): Expose the ability to stop using a 
2762           custom renderer and go back to the default renderer.
2763
2764         * history/CachedFrame.cpp:
2765         (WebCore::CachedFrame::CachedFrame): Move the document inactivation call to the same place
2766           we suspend active DOM objects. It is important this call be *after* the beforeunload event
2767           is dispatched, and was coincidental non of the elements that using Document activation
2768           had run in to this problem yet.
2769
2770         * history/PageCache.cpp:
2771         (WebCore::logCanCacheFrameDecision):
2772         (WebCore::PageCache::canCachePageContainingThisFrame): If the page contains plugins but
2773           the PageCacheSupportsPlugins setting is true, allow this page.
2774
2775         Kill and recreate the plugin by listening for Document activation callbacks and setting a custom
2776         display:none render style:
2777         * html/HTMLPlugInImageElement.cpp:
2778         (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement):
2779         (WebCore::HTMLPlugInImageElement::~HTMLPlugInImageElement): Unregister for document activation
2780           callbacks.
2781         (WebCore::HTMLPlugInImageElement::createRenderer): Once a renderer (ie. plugin instance) is
2782           created, this element needs Document (in)activation callbacks.
2783         (WebCore::HTMLPlugInImageElement::willMoveToNewOwnerDocument): Manage Document activation 
2784           callback registration.
2785         (WebCore::HTMLPlugInImageElement::didMoveToNewOwnerDocument): Ditto.
2786         (WebCore::HTMLPlugInImageElement::documentWillBecomeInactive): Clone the element's current style
2787           and set the clone's display value to None. Start using this custom style and force a style
2788           recall. This destroys the renderer and therefore the plugin instance.
2789         (WebCore::HTMLPlugInImageElement::documentDidBecomeActive): Stop using the custom style and
2790           force a style recall to reinstantiate the plugin.
2791         (WebCore::HTMLPlugInImageElement::customStyleForRenderer): Return the stand-in style that has
2792           display:none set.
2793         * html/HTMLPlugInImageElement.h:
2794
2795         Add a setting that allows runtime configuration of whether or not the page cache supports plugins:
2796         * page/Settings.cpp:
2797         (WebCore::Settings::Settings):
2798         * page/Settings.h:
2799         (WebCore::Settings::setPageCacheSupportsPlugins):
2800         (WebCore::Settings::pageCacheSupportsPlugins):
2801
2802 2011-12-12  Ojan Vafai  <ojan@chromium.org>
2803
2804         r102234 caused RuleData to use 33 bits in its bitmask
2805         https://bugs.webkit.org/show_bug.cgi?id=74314
2806
2807         Reviewed by Antti Koivisto.
2808
2809         Lower m_position to something more reasonable. A million
2810         should be plenty. Current large sites (e.g. gmail) seem to use
2811         tens of thousands.
2812
2813         Added a COMPILE_ASSERT to ensure this doesn't regress.
2814
2815         No new tests.
2816
2817         * css/CSSStyleSelector.cpp:
2818
2819 2011-12-12  James Robinson  <jamesr@chromium.org>
2820
2821         Rename webkitCancelRequestAnimationFrame to webkitCancelAnimationFrame to match spec change
2822         https://bugs.webkit.org/show_bug.cgi?id=74231
2823
2824         Reviewed by Simon Fraser.
2825
2826         The RequestAnimationFrame spec has renamed cancelRequestAnimationFrame to cancelAnimationFrame in response to
2827         feedback from Mozilla and Microsoft that the old name was too long and didn't parallel setTimeout/clearTimeout
2828         and setInterval/clearInterval very well. This updates our IDL to match, while preserving the old name as an
2829         alias to be compatible with current content.
2830
2831         * dom/Document.cpp:
2832         (WebCore::Document::webkitCancelAnimationFrame):
2833         * dom/Document.h:
2834         * page/DOMWindow.cpp:
2835         (WebCore::DOMWindow::webkitCancelAnimationFrame):
2836         * page/DOMWindow.h:
2837         (WebCore::DOMWindow::webkitCancelRequestAnimationFrame):
2838         * page/DOMWindow.idl:
2839
2840 2011-12-12  Shawn Singh  <shawnsingh@chromium.org>
2841
2842         [chromium] Remove assumption that empty surface is always at end of list
2843         https://bugs.webkit.org/show_bug.cgi?id=74037
2844
2845         Reviewed by James Robinson.
2846
2847         Test case added to CCLayerTreeHostCommonTest.cpp, which reproduces
2848         a crash reported in http://code.google.com/p/chromium/issues/detail?id=106734
2849
2850         This patch fixes the crash in a less risky way to be merged into
2851         m17, but the root of the issue needs to be addressed in a
2852         follow-up patch.
2853
2854         * platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
2855         (WebCore::calculateDrawTransformsAndVisibilityInternal):
2856
2857 2011-12-12  Simon Fraser  <simon.fraser@apple.com>
2858
2859         Share code that checks for matching sets of transform operations
2860         https://bugs.webkit.org/show_bug.cgi?id=74265
2861
2862         Reviewed by Dan Bernstein.
2863         
2864         Add TransformOperations::operationsMatch() and call it from the
2865         three places that used this same code.
2866         
2867         Tested by existing tests.
2868
2869         * page/animation/ImplicitAnimation.cpp:
2870         (WebCore::ImplicitAnimation::validateTransformFunctionList):
2871         * page/animation/KeyframeAnimation.cpp:
2872         (WebCore::KeyframeAnimation::validateTransformFunctionList):
2873         * platform/graphics/GraphicsLayer.cpp:
2874         (WebCore::GraphicsLayer::fetchTransformOperationList):
2875         * platform/graphics/transforms/TransformOperations.cpp:
2876         (WebCore::TransformOperations::operationsMatch):
2877         * platform/graphics/transforms/TransformOperations.h:
2878
2879 2011-12-12  Antti Koivisto  <antti@apple.com>
2880
2881         Cache visited link hash
2882         https://bugs.webkit.org/show_bug.cgi?id=74095
2883
2884         Reviewed by Darin Adler.
2885
2886         Visited link hash is relatively expensive to compute. We can cache it for anchor elements
2887         with minimal relative memory cost for faster style resolve.
2888         
2889         On my machine this speeds up style matching on full HTML spec by ~100ms or ~1% of the total
2890         CPU usage. It makes link elements 8 bytes larger, a relatively minor increase to their overall size.
2891         
2892         Invalidate the hashes on base URL for completeness sake (lack of style invalidation means
2893         that this scenario is not properly supported currently).
2894
2895         Covered by existing tests. No specific test for visited hash invalidation on dynamic base URL 
2896         change as the effect is not testable due to lack of style invalidation.
2897
2898         * css/SelectorChecker.cpp:
2899         (WebCore::SelectorChecker::determineLinkStateSlowCase):
2900         (WebCore::SelectorChecker::visitedStateChanged):
2901         * html/Document.cpp:
2902         * html/HTMLAnchorElement.cpp:
2903         (WebCore::HTMLAnchorElement::HTMLAnchorElement):
2904         (WebCore::HTMLAnchorElement::parseMappedAttribute):
2905         * html/HTMLAnchorElement.h:
2906         (WebCore::HTMLAnchorElement::visitedLinkHash):
2907
2908 2011-12-12  Martin Robinson  <mrobinson@igalia.com>
2909
2910         [GTK] gtk_widget_size_allocate for plugin widgets should happen in the WebView size-allocate method
2911         https://bugs.webkit.org/show_bug.cgi?id=72805
2912
2913         Reviewed by Gustavo Noronha Silva.
2914
2915         No new tests. This is only a performance tweak.
2916
2917         Instead of immediately calling gtk_widget_size during painting, defer
2918         this until the size-allocate method of the WebView.
2919
2920         * plugins/gtk/PluginViewGtk.cpp:
2921         (WebCore::PluginView::updateWidgetAllocationAndClip): Instead of immediately changing
2922         the widget allocation, just record it in a GObject data attachment.
2923
2924 2011-12-12  Nate Chapin  <japhet@chromium.org>
2925
2926         A SubresourceLoader in the middle of revalidating
2927         a resource should be treated as finishing (similar to
2928         didFinishLoading and didFail) to ensure that willCancel()
2929         doesn't declare the revalidation as having failed reentrantly.
2930         https://bugs.webkit.org/show_bug.cgi?id=72762
2931
2932         Reviewed by Adam Barth.
2933
2934         Test: http/tests/cache/cancel-during-revalidation-succeeded.html
2935
2936         * loader/SubresourceLoader.cpp:
2937         (WebCore::SubresourceLoader::didReceiveResponse):
2938
2939 2011-12-12  Mary Wu  <mary.wu@torchmobile.com.cn>
2940
2941         Upstream 3 files into WebCore/platform/blackberry
2942         https://bugs.webkit.org/show_bug.cgi?id=74275
2943
2944         Reviewed by Rob Buis.
2945
2946         Initial upstream, no new tests.
2947
2948         * platform/blackberry/ContextMenuBlackBerry.cpp: Added.
2949         * platform/blackberry/ContextMenuItemBlackBerry.cpp: Added.
2950         * platform/blackberry/TemporaryLinkStubs.cpp: Added.
2951
2952 2011-12-12  Pierre Rossi  <pierre.rossi@gmail.com>
2953
2954         [Qt] Rendering issues with sliders and QStyle
2955         https://bugs.webkit.org/show_bug.cgi?id=73921
2956
2957         With QStyle's origins being deeply rooted with widgets,
2958         several styles make wrong assumptions, leading to sliders
2959         not being painted properly in WebKit. We can solve a lot
2960         of problems by systematically translating the painter to
2961         the top left corner of the render object.
2962
2963         Reviewed by Simon Hausmann.
2964
2965         No new tests. The Qt tests are ran with the Windows
2966         style, this fixes some quirks affecting other styles.
2967
2968         * platform/qt/RenderThemeQStyle.cpp:
2969         (WebCore::RenderThemeQStyle::paintSliderTrack):
2970         (WebCore::RenderThemeQStyle::paintSliderThumb):
2971
2972 2011-12-12  Mary Wu  <mary.wu@torchmobile.com.cn>
2973
2974         Upstream 5 files into WebCore/platform/blackberry
2975         https://bugs.webkit.org/show_bug.cgi?id=73798
2976
2977         Reviewed by Rob Buis.
2978
2979         Main contributors:
2980         Genevieve Mak <gmak@rim.com>
2981         Mike Lattanzio  <mlattanzio@rim.com>
2982         George Staikos <gstaikos@rim.com> 
2983
2984         Initial upstream, no new tests.
2985
2986         * platform/blackberry/PlatformTouchEventBlackBerry.cpp: Added.
2987         (WebCore::PlatformTouchEvent::PlatformTouchEvent):
2988         * platform/blackberry/PlatformTouchPointBlackBerry.cpp: Added.
2989         (WebCore::PlatformTouchPoint::PlatformTouchPoint):
2990         * platform/blackberry/SharedBufferBlackBerry.cpp: Added.
2991         (WebCore::SharedBuffer::createWithContentsOfFile):
2992         * platform/blackberry/SharedTimerBlackBerry.cpp: Added.
2993         (WebCore::SharedTimerBlackBerry::SharedTimerBlackBerry):
2994         (WebCore::SharedTimerBlackBerry::~SharedTimerBlackBerry):
2995         (WebCore::SharedTimerBlackBerry::instance):
2996         (WebCore::SharedTimerBlackBerry::start):
2997         (WebCore::SharedTimerBlackBerry::stop):
2998         (WebCore::setSharedTimerFiredFunction):
2999         (WebCore::setSharedTimerFireInterval):
3000         (WebCore::stopSharedTimer):
3001         * platform/blackberry/SystemTimeBlackBerry.cpp: Added.
3002         (WebCore::userIdleTime):
3003
3004 2011-12-12  Alexander Pavlov  <apavlov@chromium.org>
3005
3006         Implement a cache for CSSStyleRule::selectorText()
3007         https://bugs.webkit.org/show_bug.cgi?id=74269
3008
3009         This change is geared towards speeding up the CSS selector profiler,
3010         its implementation tracked at https://bugs.webkit.org/show_bug.cgi?id=74004.
3011         Using a proof-of-concept implementation of the profiler, this change reduces
3012         the profiler temporal overhead on PerformanceTests/Parser/html5-full-render.html
3013         roughly by 86% (from ~72 seconds down to ~10 seconds). This change also does not
3014         considerably increase average memory usage, as reading selectorText is a relatively
3015         rare case during normal web browsing.
3016
3017         Reviewed by Andreas Kling.
3018
3019         No new tests, as this functionality is covered by existing tests.
3020
3021         * css/CSSRule.h:
3022         * css/CSSStyleRule.cpp:
3023         (WebCore::CSSStyleRule::~CSSStyleRule):
3024         (WebCore::selectorTextCache):
3025         (WebCore::CSSStyleRule::cleanup):
3026         (WebCore::CSSStyleRule::generateSelectorText):
3027         (WebCore::CSSStyleRule::selectorText):
3028         (WebCore::CSSStyleRule::setSelectorText):
3029         * css/CSSStyleRule.h:
3030
3031 2011-12-12  Alexander Pavlov  <apavlov@chromium.org>
3032
3033         Web Inspector: [Styles] Modified selector text needs sanitization
3034         https://bugs.webkit.org/show_bug.cgi?id=74291
3035
3036         Reviewed by Yury Semikhatsky.
3037
3038         * inspector/front-end/StylesSidebarPane.js:
3039
3040 2011-12-12  Renata Hodovan  <reni@webkit.org>
3041
3042         Fulfill FIXME in  HTMLLinkElement.h.
3043         https://bugs.webkit.org/show_bug.cgi?id=74278
3044
3045         Rename HTMLLinkElement::isLoading() to isStyleSheetLoading().
3046
3047         Reviewed by Andreas Kling.
3048
3049         No new tests because the functionality remains the same.
3050
3051         * dom/Document.cpp:
3052         (WebCore::Document::recalcStyleSelector):
3053         * html/HTMLLinkElement.cpp:
3054         (WebCore::HTMLLinkElement::setDisabledState):
3055         (WebCore::HTMLLinkElement::isStyleSheetLoading):
3056         (WebCore::HTMLLinkElement::sheetLoaded):
3057         * html/HTMLLinkElement.h:
3058
3059 2011-11-25  Alexander Pavlov  <apavlov@chromium.org>
3060
3061         WebKit does not enumerate over CSS properties in HTMLElement.style
3062         https://bugs.webkit.org/show_bug.cgi?id=23946
3063
3064         Reviewed by Darin Adler.
3065
3066         This change generates a list of JavaScript mirrors of the CSS properties and allows to enumerate them
3067         using the "in" operator on the CSSStyleDeclaration object.
3068
3069         Test: fast/css/style-enumerate-properties.html
3070
3071         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
3072         (WebCore::JSCSSStyleDeclaration::getOwnPropertyNames): Added.
3073         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp:
3074         (WebCore::V8CSSStyleDeclaration::namedPropertyEnumerator): Added.
3075         (WebCore::V8CSSStyleDeclaration::namedPropertyQuery): Added.
3076         (WebCore::V8CSSStyleDeclaration::namedPropertyGetter): A small drive-by optimization (local initialization moved down).
3077         * css/CSSStyleDeclaration.idl: Use a custom property enumerator.
3078         * css/makeprop.pl: Add a function to convert CSS property names into JS ones.
3079
3080 2011-12-12  Alexander Pavlov  <apavlov@chromium.org>
3081
3082         Unreviewed, build fix.
3083
3084         Revert r102570 which broke SnowLeopard builders.
3085
3086         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
3087         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp:
3088         (WebCore::V8CSSStyleDeclaration::namedPropertyGetter):
3089         * css/CSSStyleDeclaration.idl:
3090         * css/makeprop.pl:
3091
3092 2011-12-12  Ilya Tikhonovsky  <loislo@chromium.org>
3093
3094         Web Inspector: chromium: UI: Detailed Heap snapshot shows too many objects' hidden properties.
3095         https://bugs.webkit.org/show_bug.cgi?id=74289
3096
3097         WebCore objects have many hidden properties.
3098         The Detailed Heap shapshot view shows all these props for a selected object.
3099         The result view looks too heavy and users usually failed to find a useful information about the object.
3100         Looks like such ability is unnecessary in the most cases.
3101         I'd like to introduce a configurable property that will show/hide these props from the view.
3102
3103         Reviewed by Yury Semikhatsky.
3104
3105         * English.lproj/localizedStrings.js:
3106         * inspector/front-end/DetailedHeapshotGridNodes.js:
3107         * inspector/front-end/DetailedHeapshotView.js:
3108         * inspector/front-end/HeapSnapshotProxy.js:
3109         (WebInspector.HeapSnapshotProxy.prototype.createPathFinder):
3110         * inspector/front-end/SettingsScreen.js:
3111         (WebInspector.SettingsScreen):
3112
3113 2011-12-12  Kentaro Hara  <haraken@chromium.org>
3114
3115         Unreviewed, rolling out r102556.
3116         http://trac.webkit.org/changeset/102556
3117         https://bugs.webkit.org/show_bug.cgi?id=73394
3118
3119         clobber build failure
3120
3121         * WebCore.gyp/WebCore.gyp:
3122         * WebCore.gyp/scripts/action_derivedsourcesallinone.py:
3123         (main):
3124         * WebCore.gypi:
3125         * bindings/scripts/generate-bindings.pl:
3126         * page/DOMWindow.idl:
3127         * webaudio/DOMWindowWebAudio.idl: Removed.
3128
3129 2011-12-12  Kentaro Hara  <haraken@chromium.org>
3130
3131         Unreviewed, rolling out r102558.
3132         http://trac.webkit.org/changeset/102558
3133         https://bugs.webkit.org/show_bug.cgi?id=74160
3134
3135         clobber build failure
3136
3137         * WebCore.gypi:
3138         * page/DOMWindow.idl:
3139         * websockets/DOMWindowWebSocket.idl: Removed.
3140
3141 2011-11-25  Alexander Pavlov  <apavlov@chromium.org>
3142
3143         WebKit does not enumerate over CSS properties in HTMLElement.style
3144         https://bugs.webkit.org/show_bug.cgi?id=23946
3145
3146         Reviewed by Darin Adler.
3147
3148         This change generates a list of JavaScript mirrors of the CSS properties and allows to enumerate them
3149         using the "in" operator on the CSSStyleDeclaration object.
3150
3151         Test: fast/css/style-enumerate-properties.html
3152
3153         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
3154         (WebCore::JSCSSStyleDeclaration::getOwnPropertyNames): Added.
3155         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp:
3156         (WebCore::V8CSSStyleDeclaration::namedPropertyEnumerator): Added.
3157         (WebCore::V8CSSStyleDeclaration::namedPropertyQuery): Added.
3158         (WebCore::V8CSSStyleDeclaration::namedPropertyGetter): A small drive-by optimization (local initialization moved down).
3159         * css/CSSStyleDeclaration.idl: Use a custom property enumerator.
3160         * css/makeprop.pl: Add a function to convert CSS property names into JS ones, and a string comparator.
3161
3162 2011-12-09  Yury Semikhatsky  <yurys@chromium.org>
3163
3164         Web Inspector: provide per Document Node count statistics
3165         https://bugs.webkit.org/show_bug.cgi?id=74100
3166
3167         Memory agent now returns counters for nodes with given names. For each
3168         object group root user will see total number of its descendtants and per
3169         tag name counts.
3170
3171         This patch also moves generic CounterVisitor code out of V8 bindings. It
3172         may well be used with both JS engines.
3173
3174         Reviewed by Pavel Feldman.
3175
3176         * GNUmakefile.list.am:
3177         * Target.pri:
3178         * WebCore.gypi:
3179         * WebCore.vcproj/WebCore.vcproj:
3180         * WebCore.xcodeproj/project.pbxproj:
3181         * bindings/js/ScriptProfiler.h:
3182         (WebCore::ScriptProfiler::visitJSDOMWrappers):
3183         * bindings/v8/ScriptProfiler.cpp:
3184         (WebCore::ScriptProfiler::visitJSDOMWrappers):
3185         * bindings/v8/ScriptProfiler.h:
3186         * inspector/DOMWrapperVisitor.h: Added.
3187         (WebCore::DOMWrapperVisitor::~DOMWrapperVisitor):
3188         * inspector/Inspector.json:
3189         * inspector/InspectorMemoryAgent.cpp:
3190         (WebCore::InspectorMemoryAgent::getDOMNodeCount):
3191         * inspector/InspectorMemoryAgent.h:
3192
3193 2011-12-12  Noel Gordon  <noel.gordon@gmail.com>
3194
3195         WebPImageDecoder: Increase image/webp decoding performance 10-20%
3196         https://bugs.webkit.org/show_bug.cgi?id=74263
3197
3198         Reviewed by Adam Barth.
3199
3200         Avoid copying data from the RGB buffer of decoded image output to the
3201         backing pixel store. That is slow - costs 10% of the overall decoding
3202         time at libwebp 0.1.2, and 20% at libwebp 0.1.3.
3203
3204         Instead, instruct the decoder to write the decoded pixels directly to
3205         the backing pixel store.
3206
3207         No new tests. Covered by existing tests. No progressive decoding test
3208         exists in DRT, see https://bugs.webkit.org/show_bug.cgi?id=74062
3209
3210         * platform/image-decoders/webp/WEBPImageDecoder.cpp:
3211         (outputMode):  Define output pixel format. On little-endian machines,
3212         output BGRA pixels to the backing store, for example.
3213         (WebCore::WEBPImageDecoder::WEBPImageDecoder):
3214         (WebCore::WEBPImageDecoder::decode):
3215         * platform/image-decoders/webp/WEBPImageDecoder.h:
3216
3217 2011-12-11  Zoltan Herczeg  <zherczeg@webkit.org>
3218
3219         Add new CSS nth-children parsing tests
3220         https://bugs.webkit.org/show_bug.cgi?id=74178
3221
3222         Reviewed by Darin Adler.
3223
3224         Test: fast/css/parsing-css-nth-child.html
3225
3226         * css/CSSParser.cpp:
3227         (WebCore::isValidNthToken): Add "-n" to the possible identifiers.
3228
3229 2011-12-11  Kentaro Hara  <haraken@chromium.org>
3230
3231         Use [Supplemental] IDL in WebSocket
3232         https://bugs.webkit.org/show_bug.cgi?id=74160
3233
3234         Reviewed by Adam Barth.
3235
3236         By using the [Supplemental] IDL, this patch moves declarations of WebSocket
3237         attributes from DOMWindow.idl to websocket/DOMWindowWebSocket.idl,
3238         which helps make WebSocket a self-contained module.
3239
3240         No new tests, no change in behavior.
3241         Confirm that http/tests/websocket/* pass.
3242
3243         * WebCore.gypi: Added DOMWindowWebSocket.idl.
3244         * page/DOMWindow.idl: Added the [Supplemented] IDL to WebSocket-related attributes. This [Supplemented] IDL will be removed after all platforms support the [Supplemental] IDL (See bug 73394 for more details).
3245         * websockets/DOMWindowWebSocket.idl: Added. Used the [Supplemental=DOMWindow] IDL. The attributes in this IDL file are treated as if they are described in DOMWindow.idl.
3246
3247 2011-12-11  Luke Macpherson   <macpherson@chromium.org>
3248
3249         Implement webkit-line-grid and webkit-line-grid-snap CSS properties in CSSStyleApplyProperty.
3250         https://bugs.webkit.org/show_bug.cgi?id=74262
3251
3252         Reviewed by Andreas Kling.
3253
3254         No new tests / refactoring only.
3255
3256         * css/CSSStyleApplyProperty.cpp:
3257         (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):
3258         * css/CSSStyleSelector.cpp:
3259         (WebCore::CSSStyleSelector::applyProperty):
3260
3261 2011-12-11  Kentaro Hara  <haraken@chromium.org>
3262
3263         Use the [Supplemental] IDL for webaudio attributes in Chromium
3264         https://bugs.webkit.org/show_bug.cgi?id=73394
3265
3266         Reviewed by Adam Barth.
3267
3268         - Overview: Using the [Supplemental] IDL, this patch moves the attribute
3269         declarations of webaudio from DOMWindow.idl into a new IDL file
3270         webaudio/DOMWindowWebAudio.idl, which helps make webaudio a self-contained
3271         feature (aka a module).
3272
3273         - This patch changes the build flow of WebCore.gyp as follows:
3274
3275             Previous build flow:
3276                 foreach $idl (all IDL files) {
3277                     generate-bindings.pl depends on $idl;
3278                     generate-bindings.pl reads $idl;
3279                     generate-bindings.pl generates .h and .cpp files for $idl;
3280                 }
3281
3282             New build flow (See the discussions in bug 72138 for more details):
3283                 resolve-supplemental.pl depends on all IDL files;
3284                 resolve-supplemental.pl reads all IDL files;
3285                 resolve-supplemental.pl resolves the dependency of [Supplemental=XXXX];
3286                 resolve-supplemental.pl outputs supplemental_dependency.tmp;
3287                 foreach $idl (all IDL files) {
3288                     generate-bindings.pl depends on $idl and supplemental_dependency.tmp;
3289                     generate-bindings.pl reads $idl;
3290                     generate-bindings.pl reads supplemental_dependency.tmp;
3291                     generate-bindings.pl generates .h and .cpp files for $idl, including all attributes in IDL files whilementing $idl;
3292                 }
3293
3294         - This patch introduces a temporary IDL, [Supplemented]. The [Supplemented] IDL
3295         will be removed after build scripts for all platforms support the [Supplemental] IDL.
3296         The motivation for the [Supplemented] IDL is as follows:
3297
3298         In order to support the [Supplemental] IDL, we need to
3299         (1) run resolve-supplemental.pl and generate supplemental_dependency.tmp
3300         (2) and run generate-bindings.pl with the supplemental_dependency.tmp.
3301
3302         This build flow requires a change on the following build scripts,
3303         but changing all the build scripts all at once without any regression is too difficult:
3304
3305             - DerivedSources.make
3306             - DerivedSources.pri
3307             - GNUmakefile.am
3308             - PlatformBlackBerry.cmake
3309             - UseJSC.cmake
3310             - UseV8.cmake
3311             - WebCore.vcproj/MigrateScripts
3312             - WebCore.vcproj/WebCore.vcproj
3313             - bindings/gobject/GNUmakefile.am
3314             - WebCore.gyp/WebCore.gyp
3315
3316         Thus, we are planning to change the build scripts one by one, which implies that
3317         we need to allow the temporary state in which some build scripts support [Supplemental] IDL
3318         but others do not. To accomplish this, we introduce a temporary IDL, [Supplemented].
3319         The [Supplemented] IDL on an attribute means that the attribute is marked with [Supplemental]
3320         in another IDL file somewhere, like this:
3321
3322             DOMWindowWebAudio.idl:
3323                 interface [
3324                     Supplemental=DOMWindow
3325                 ] DOMWindowWebAudio {
3326                     attribute attr1;
3327                     attribute attr2;
3328                 };
3329
3330             DOMWindow.idl:
3331                 interface [
3332                 ] DOMWindow {
3333                     attribute [Supplemented] attr1; // This line will be removed after all build scripts support the [Su IDL
3334                     attribute [Supplemented] attr2; // This line will be removed after all build scripts support the [Su IDL.
3335                     attribute attr3;
3336                     attribute attr4;
3337                 };
3338
3339         Assuming these IDL files, this patch implements the following logic in generate-bindings.pl:
3340
3341             - If a given build script supports the [Supplemental] IDL,
3342             generate-bindings.pl ignores all attributes with the [Supplemented] IDL.
3343             - Otherwise, generate-bindings.pl treats all attributes with the [Supplemented] IDL
3344             as normal attributes and instead ignores all attributes with the [Supplemental] IDL
3345             (i.e. generate-bindings.pl generates nothing from the IDL file with the [Supplemental] IDL).
3346
3347         Tests: webaudio/*
3348
3349         * WebCore.gyp/WebCore.gyp: Describes the build flow that I described above.
3350         * WebCore.gyp/scripts/action_derivedsourcesallinone.py:
3351         (main): Reads the IDL file names from the input file (i.e. supplemental_dependency.tmp), which are described at the first column of each line in the input file. If the file name is a "/cygdrive/c/..."-style path, it is converted to a "C:\cygwin\..."-style path by the cygpath command.
3352         * WebCore.gypi: Added DOMWindowWebAudio.idl.
3353         * bindings/scripts/generate-bindings.pl: As a temporary solution, if the platform does not support the [Supplemental] IDL, the perl script ignores the [Supplemental] IDL and instead uses the [Supplemented] IDL. Otherwise, the perl script ignores the [Supplemented] IDL and instead uses the [Supplemental] IDL.
3354         * page/DOMWindow.idl: Added the [Supplemented] IDL to webaudio-related attributes. As I described above, the [Supplemented] IDL will be removed after all platforms support the [Supplemental] IDL.
3355         * webaudio/DOMWindowWebAudio.idl: Added. Describes the [Supplemental=DOMWindow] IDL. The attributes in this IDL file should be treated as if they are written in DOMWindow.idl.
3356
3357 2011-12-11  Andreas Kling  <kling@webkit.org>
3358
3359         Micro-optimize CSSStyleSelector::findSiblingForStyleSharing().
3360         <http://webkit.org/b/74261>
3361
3362         Reviewed by Antti Koivisto.
3363
3364         Move the isStyledElement() check from canShareStyleWithElement() into the
3365         loop in findSiblingForStyleSharing(), and tighten up the argument/return
3366         types to StyledElement* as appropriate.
3367
3368         * css/CSSStyleSelector.cpp:
3369         (WebCore::CSSStyleSelector::canShareStyleWithElement):
3370         (WebCore::CSSStyleSelector::findSiblingForStyleSharing):
3371         (WebCore::CSSStyleSelector::locateSharedStyle):
3372         * css/CSSStyleSelector.h:
3373
3374 2011-12-11  Shinya Kawanaka  <shinyak@google.com>
3375
3376         Asynchronous path synchronous path of SpellChecker should share the code to mark misspellings.
3377         https://bugs.webkit.org/show_bug.cgi?id=73616
3378
3379         Reviewed by Hajime Morita.
3380
3381         Asynchronous spellchecking path should call the same method for the synchronous spellchecking path
3382         to mark misspellings.
3383
3384         No new tests. Covered by existing tests.
3385
3386         * editing/Editor.cpp:
3387         (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges):
3388         (WebCore::Editor::markAndReplaceFor):
3389           Takes SpellCheckRequest object.
3390         * editing/Editor.h:
3391         * editing/SpellChecker.cpp:
3392         (WebCore::SpellChecker::didCheck):
3393           Calls the same method of synchronous spellchecking path.
3394
3395 2011-12-11  Luke Macpherson   <macpherson@chromium.org>
3396
3397         Implement CSS display property in CSSStyleApplyProperty.
3398         https://bugs.webkit.org/show_bug.cgi?id=73500
3399
3400         Reviewed by Andreas Kling.
3401
3402         Refactoring only / no functionality changed.
3403
3404         * css/CSSStyleApplyProperty.cpp:
3405         (WebCore::ApplyPropertyDisplay::isValidDisplayValue):
3406         (WebCore::ApplyPropertyDisplay::applyInheritValue):
3407         (WebCore::ApplyPropertyDisplay::applyInitialValue):
3408         (WebCore::ApplyPropertyDisplay::applyValue):
3409         (WebCore::ApplyPropertyDisplay::createHandler):
3410         (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):
3411         * css/CSSStyleSelector.cpp:
3412         (WebCore::CSSStyleSelector::applyProperty):
3413
3414 2011-12-11  Geoffrey Garen  <ggaren@apple.com>
3415
3416         Try to fix the Qt build.
3417
3418         Unreviewed.
3419
3420         * css/CSSStyleDeclaration.cpp: Maybe an #include will solve our problem?
3421         Someday, compiler error messages will not suck. Today is not that day.
3422
3423 2011-12-11  Luke Macpherson   <macpherson@chromium.org>
3424
3425         Implement CSS resize property in CSSStyleApplyProperty.
3426         https://bugs.webkit.org/show_bug.cgi?id=74162
3427
3428         Reviewed by Julien Chaffraix.
3429
3430         No new tests / refactoring only.
3431
3432         * css/CSSStyleApplyProperty.cpp:
3433         (WebCore::ApplyPropertyResize::applyValue):
3434         (WebCore::ApplyPropertyResize::createHandler):
3435         (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):
3436         * css/CSSStyleSelector.cpp:
3437         (WebCore::CSSStyleSelector::applyProperty):
3438
3439 2011-12-11  Andreas Kling  <kling@webkit.org>
3440
3441         Move CSSElementStyleDeclaration to its own cpp/h files.
3442         <http://webkit.org/b/74256>
3443
3444         Reviewed by Sam Weinig.
3445
3446         CSSElementStyleDeclaration is old enough to move out of CSSMutableStyleDeclaration's
3447         attic and into her own apartment. 
3448
3449         * CMakeLists.txt:
3450         * GNUmakefile.list.am:
3451         * Target.pri:
3452         * WebCore.gypi:
3453         * WebCore.vcproj/WebCore.vcproj:
3454         * WebCore.xcodeproj/project.pbxproj:
3455         * bindings/js/JSDOMBinding.h:
3456         * css/CSSElementStyleDeclaration.cpp: Added.
3457         (WebCore::CSSElementStyleDeclaration::styleSheet):
3458         * css/CSSElementStyleDeclaration.h: Added.
3459         (WebCore::CSSElementStyleDeclaration::element):
3460         (WebCore::CSSElementStyleDeclaration::setElement):
3461         (WebCore::CSSElementStyleDeclaration::CSSElementStyleDeclaration):
3462         (WebCore::CSSElementStyleDeclaration::~CSSElementStyleDeclaration):
3463         * css/CSSInlineStyleDeclaration.h:
3464         * css/CSSMutableStyleDeclaration.cpp:
3465         * css/CSSMutableStyleDeclaration.h:
3466         * dom/CSSMappedAttributeDeclaration.h:
3467
3468 2011-12-11  Benjamin Poulain  <bpoulain@apple.com>
3469
3470         Add KillRingNone.cpp to Mac build system
3471         https://bugs.webkit.org/show_bug.cgi?id=74168
3472
3473         Reviewed by David Kilzer.
3474
3475         Add KillRingNone.cpp so it can be used on iOS, but
3476         blacklist the file from the build in order to avoid
3477         conflicts with KillRingMac.
3478
3479         * Configurations/WebCore.xcconfig:
3480         * WebCore.xcodeproj/project.pbxproj:
3481
3482 2011-12-11  Peter Rybin  <peter.rybin@gmail.com>
3483
3484         Web Inspector: [protocol] alter some type names generated from Inspector.json
3485         https://bugs.webkit.org/show_bug.cgi?id=74247
3486
3487         Reviewed by Pavel Feldman.
3488
3489         Manually-filled map added that contains problem type names and its replacement.
3490
3491         * inspector/CodeGeneratorInspector.py:
3492         (fix_type_name.Result):
3493         (fix_type_name.Result.output_comment):
3494         (fix_type_name):
3495         (TypeBindings.create_for_named_type_declaration.write_doc):
3496         (TypeBindings.create_for_named_type_declaration.EnumBinding.generate_type_builder):
3497         (TypeBindings.create_for_named_type_declaration.PlainString.generate_type_builder):
3498         (TypeBindings):
3499         (TypeBindings.create_for_named_type_declaration.ClassBinding.generate_type_builder):
3500         (Generator.process_types):
3501
3502 2011-12-11  Andreas Kling  <kling@webkit.org>
3503
3504         WK2/NetscapePlugin: Incorrect mouse event coordinates when frameScaleFactor != 1.
3505         <http://webkit.org/b/74209> and <rdar://problem/10438197>
3506
3507         Reviewed by Anders Carlsson.
3508
3509         * WebCore.exp.in: Export AffineTransform::scale(double).
3510
3511 2011-12-10  Andreas Kling  <kling@webkit.org>
3512
3513         Remove OS(SYMBIAN) block from Settings constructor.
3514         <http://webkit.org/b/74248>
3515
3516         Reviewed by Benjamin Poulain.
3517
3518         Kill the last OS(SYMBIAN) block in WebKit!
3519
3520         * page/Settings.cpp:
3521         (WebCore::Settings::Settings):
3522
3523 2011-12-11  Dan Bernstein  <mitz@apple.com>
3524
3525         <rdar://problem/10561285> REGRESSION (r80438): First word on a line or after collapsed space may not be hyphenated even though it should
3526         https://bugs.webkit.org/show_bug.cgi?id=74239
3527
3528         Reviewed by Anders Carlsson.
3529
3530         Tests: fast/text/hyphenate-first-word-after-skipped-space-expected.html
3531                fast/text/hyphenate-first-word-after-skipped-space.html
3532
3533         * rendering/RenderBlockLineLayout.cpp:
3534         (WebCore::tryHyphenating): Replaced the assumption that the character at lastSpace is a space
3535         iff lastSpace is non-zero with a test of whether it is a space, in the sense that it should
3536         not be counted as part of the prefix when comparing it to the value of hyphenate-limit-before.
3537
3538 2011-12-10  Benjamin Poulain  <bpoulain@apple.com>
3539
3540         #ifdef the parts of the Mac platform which should not be used on iOS
3541         https://bugs.webkit.org/show_bug.cgi?id=74246
3542
3543         Reviewed by David Kilzer.
3544
3545         * Configurations/WebCore.xcconfig:
3546         * platform/FileSystem.cpp:
3547         * platform/mac/FileSystemMac.mm:
3548         * platform/mac/Language.mm:
3549         (+[WebLanguageChangeObserver _webkit_languagePreferencesDidChange]):
3550         (WebCore::createHTTPStyleLanguageCode):
3551         (WebCore::platformDefaultLanguage):
3552         * platform/mac/LocalizedStringsMac.mm:
3553         (WebCore::localizedString):
3554         (+[WebCoreSharedBufferData initialize]):
3555         * platform/mac/WebCoreNSStringExtras.h:
3556         * platform/mac/WebCoreNSStringExtras.mm:
3557         * platform/mac/WebFontCache.mm:
3558         * platform/mac/WebNSAttributedStringExtras.mm: The value NSAttachmentCharacter is
3559         not defined in the iOS SDK so we add it here.
3560
3561 2011-12-10  Ryosuke Niwa  <rniwa@webkit.org>
3562
3563         The previous fix broke Lion release build. Fix that.
3564
3565         * editing/SpellingCorrectionCommand.cpp:
3566
3567 2011-12-10  Ryosuke Niwa  <rniwa@webkit.org>
3568
3569         Lion build fix attempt after r102527.
3570
3571         * editing/SpellingCorrectionCommand.cpp:
3572
3573 2011-12-10  Kevin Ollivier  <kevino@theolliviers.com>
3574
3575         [wx] Unreviewed build fixes. Add missing header for CPP
3576         DOM bindings and add stubs for new DPI methods.
3577         
3578         * bindings/scripts/CodeGeneratorCPP.pm:
3579         (AddIncludesForType):
3580         * platform/wx/ScreenWx.cpp:
3581         (WebCore::screenHorizontalDPI):
3582         (WebCore::screenVerticalDPI):
3583
3584 2011-12-10  Ryosuke Niwa  <rniwa@webkit.org>
3585
3586         Mac build fix. Remove an erroneous OVERRIDE.
3587
3588         * editing/CompositeEditCommand.h:
3589
3590 2011-12-09  Robert Hogan  <robert@webkit.org>
3591
3592         CSS 2.1 failure: numerous counter-increment-* tests fail
3593         https://bugs.webkit.org/show_bug.cgi?id=73360
3594
3595         Reviewed by Julien Chaffraix.
3596
3597         Allow counter-increment to handle integer underflow and overflow.
3598         Also allow 'counter' to inherit.
3599
3600         * css/CSSStyleApplyProperty.cpp:
3601         (WebCore::ApplyPropertyCounter::applyInheritValue):
3602         (WebCore::ApplyPropertyCounter::applyValue):
3603         (WebCore::ApplyPropertyCounter::createHandler):
3604
3605 2011-12-09  Ryosuke Niwa  <rniwa@webkit.org>
3606
3607         There should be a way to count the number of nodes held by undo stack
3608         https://bugs.webkit.org/show_bug.cgi?id=74099
3609
3610         Reviewed by Enrica Casucci.
3611
3612         Add getNodesInCommand to all SimpleEditCommands and EditCommandComposition in debug builds.
3613         We can easily aggregate the number of nodes held by the undo stack by calling
3614         this function on each item in the undo stack.
3615
3616         * editing/AppendNodeCommand.cpp:
3617         (WebCore::AppendNodeCommand::getNodesInCommand):
3618         * editing/AppendNodeCommand.h:
3619         * editing/CompositeEditCommand.cpp:
3620         (WebCore::EditCommandComposition::getNodesInCommand):
3621         * editing/CompositeEditCommand.h:
3622         * editing/DeleteFromTextNodeCommand.cpp:
3623         (WebCore::DeleteFromTextNodeCommand::getNodesInCommand):
3624         * editing/DeleteFromTextNodeCommand.h:
3625         * editing/EditCommand.cpp:
3626         (WebCore::SimpleEditCommand::addNodeAndDescedents):
3627         * editing/EditCommand.h:
3628         * editing/Editor.cpp:
3629         (WebCore::Editor::appliedEditing):
3630         * editing/InsertIntoTextNodeCommand.cpp:
3631         (WebCore::InsertIntoTextNodeCommand::getNodesInCommand):
3632         * editing/InsertIntoTextNodeCommand.h:
3633         * editing/InsertNodeBeforeCommand.cpp:
3634         (WebCore::InsertNodeBeforeCommand::getNodesInCommand):
3635         * editing/InsertNodeBeforeCommand.h:
3636         * editing/MergeIdenticalElementsCommand.cpp:
3637         (WebCore::MergeIdenticalElementsCommand::getNodesInCommand):
3638         * editing/MergeIdenticalElementsCommand.h:
3639         * editing/RemoveCSSPropertyCommand.cpp:
3640         (WebCore::RemoveCSSPropertyCommand::getNodesInCommand):
3641         * editing/RemoveCSSPropertyCommand.h:
3642         * editing/RemoveNodeCommand.cpp:
3643         (WebCore::RemoveNodeCommand::getNodesInCommand):
3644         * editing/RemoveNodeCommand.h:
3645         * editing/ReplaceNodeWithSpanCommand.cpp:
3646         (WebCore::ReplaceNodeWithSpanCommand::getNodesInCommand):
3647         * editing/ReplaceNodeWithSpanCommand.h:
3648         * editing/SetNodeAttributeCommand.cpp:
3649         (WebCore::SetNodeAttributeCommand::getNodesInCommand):
3650         * editing/SetNodeAttributeCommand.h:
3651         * editing/SetSelectionCommand.h:
3652         * editing/SplitElementCommand.cpp:
3653         (WebCore::SplitElementCommand::getNodesInCommand):
3654         * editing/SplitElementCommand.h:
3655         * editing/SplitTextNodeCommand.cpp:
3656         (WebCore::SplitTextNodeCommand::getNodesInCommand):
3657         * editing/SplitTextNodeCommand.h:
3658         * editing/WrapContentsInDummySpanCommand.cpp:
3659         (WebCore::WrapContentsInDummySpanCommand::getNodesInCommand):
3660         * editing/WrapContentsInDummySpanCommand.h:
3661
3662 2011-11-09  Robert Hogan  <robert@webkit.org>
3663
3664         CSS 2.1 failure: outline-color-* tests fail
3665         https://bugs.webkit.org/show_bug.cgi?id=71931
3666
3667         Reviewed by Julien Chaffraix.
3668
3669         Test: css2.1/20110323/outline-color-001.html
3670
3671         WebKit didn't paint the top block in this series of tests because it ignored the outline
3672         of objects with a zero size. Fix this by taking account of both offset and width of the
3673         outline when deciding whether to paint it. 
3674
3675         * rendering/RenderObject.cpp:
3676         (WebCore::RenderObject::paintOutline): paint the outline even when the block has zero size
3677
3678 2011-12-10   Arko Saha  <arko@motorola.com>
3679
3680         Microdata: Fix compilation error in MICRODATA enabled build.
3681         https://bugs.webkit.org/show_bug.cgi?id=74235
3682
3683         Reviewed by Andreas Kling.
3684
3685         * dom/Document.cpp:
3686         (WebCore::Document::getItems):
3687
3688 2011-12-10  Jarred Nicholls  <jarred@sencha.com>
3689
3690         [V8] Remove old ArrayBuffer guards from V8XMLHttpRequestCustom.cpp
3691         https://bugs.webkit.org/show_bug.cgi?id=74234
3692
3693         Reviewed by Adam Barth.
3694
3695         No new tests are necessary.
3696
3697         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
3698         (WebCore::V8XMLHttpRequest::responseAccessorGetter):
3699
3700 2011-12-10  Noel Gordon  <noel.gordon@gmail.com>
3701
3702         WebPImageDecoder progressive decodes fail to decode valid images
3703         https://bugs.webkit.org/show_bug.cgi?id=74062
3704
3705         Reviewed by Adam Barth.
3706
3707         The WEBP header is followed by a so-called P0 header, then some data to
3708         decode.  If a partial P0 header is received during progressive decodes,
3709         WebPIDecGetRGB() returns false; that makes the decoder enter the failed
3710         state, no image appears on the page.
3711
3712         James Zern (webp) recommended the following via e-mail:
3713
3714         WebPIUpdate() validates input data, and will return an error status for
3715         malformed data (bit-stream error, invalid data).  Otherwise, it returns
3716         OK or SUSPENDED.  OK means that decoding is done/complete/no-error, and
3717         SUSPENDED means more input data is needed to complete decoding.  A NULL
3718         return from WebPIDecGetRGB() is valid at this time due to a partial P0,
3719         and should not be interpreted as a decoding failure.
3720
3721         No new tests. Not something DumpRenderTree can easily test.
3722
3723         * platform/image-decoders/webp/WEBPImageDecoder.cpp:
3724         (WebCore::WEBPImageDecoder::decode):  A NULL WebPIDecGetRGB() return is
3725         acceptable here.  Return false instead of failing the decoder.
3726
3727 2011-12-09  Benjamin Poulain  <bpoulain@apple.com>
3728
3729         Add the FileSystem functions of iOS
3730         https://bugs.webkit.org/show_bug.cgi?id=74164
3731
3732         Reviewed by David Kilzer.
3733
3734         Two functions are needed on iOS for temporary files and directories.
3735
3736         * WebCore.exp.in:
3737         * WebCore.xcodeproj/project.pbxproj:
3738         * platform/ios/FileSystemIOS.h: Added.
3739         * platform/ios/FileSystemIOS.mm: Added.
3740         (WebCore::createTemporaryDirectory):
3741         (WebCore::createTemporaryFile):
3742
3743 2011-12-09  Jacky Jiang  <zhajiang@rim.com>
3744
3745         Remove ResourceHandle::bufferedData() from ResourceHandleBlackBerry.cpp
3746         https://bugs.webkit.org/show_bug.cgi?id=74197
3747
3748         The bufferedData() was removed in r95120.
3749
3750         Reviewed by Rob Buis.
3751
3752         Trivial fix, so no new tests.
3753
3754         * platform/network/blackberry/ResourceHandleBlackBerry.cpp:
3755
3756 2011-12-09  Eric Penner  <epenner@google.com>
3757
3758         [chromium] Prevent ASSERT in legitimate out-of-memory case.
3759         https://bugs.webkit.org/show_bug.cgi?id=74215
3760
3761         Reviewed by James Robinson.
3762
3763         * platform/graphics/chromium/TiledLayerChromium.cpp:
3764         (WebCore::TiledLayerChromium::updateCompositorResources):
3765
3766 2011-12-09   Arko Saha  <arko@motorola.com>
3767
3768         NameNodeListCache should be invalidated when name attribute changes/modified.
3769         https://bugs.webkit.org/show_bug.cgi?id=70810
3770
3771         Reviewed by Ryosuke Niwa.
3772
3773         Test: fast/dom/getelementsbyname-invalidation-cache.html
3774
3775         * html/HTMLAnchorElement.cpp:
3776         (WebCore::HTMLAnchorElement::parseMappedAttribute):
3777         * html/HTMLAppletElement.cpp:
3778         (WebCore::HTMLAppletElement::parseMappedAttribute):
3779         * html/HTMLElement.cpp:
3780         (WebCore::HTMLElement::parseMappedAttribute):
3781         * html/HTMLEmbedElement.cpp:
3782         (WebCore::HTMLEmbedElement::parseMappedAttribute):
3783         * html/HTMLFormElement.cpp:
3784         (WebCore::HTMLFormElement::parseMappedAttribute):
3785         * html/HTMLFrameElementBase.cpp:
3786         (WebCore::HTMLFrameElementBase::parseMappedAttribute):
3787         * html/HTMLIFrameElement.cpp:
3788         (WebCore::HTMLIFrameElement::parseMappedAttribute):
3789         * html/HTMLImageElement.cpp:
3790         (WebCore::HTMLImageElement::parseMappedAttribute):
3791         * html/HTMLMapElement.cpp:
3792         (WebCore::HTMLMapElement::parseMappedAttribute):
3793         * html/HTMLMetaElement.cpp:
3794         (WebCore::HTMLMetaElement::parseMappedAttribute):
3795         * html/HTMLObjectElement.cpp:
3796         (WebCore::HTMLObjectElement::parseMappedAttribute):
3797         * html/HTMLParamElement.cpp:
3798         (WebCore::HTMLParamElement::parseMappedAttribute):
3799
3800 2011-12-09  Anders Carlsson  <andersca@apple.com>
3801
3802         Fix Lion release build.
3803
3804         * platform/mac/ScrollAnimatorMac.mm:
3805         (-[WebScrollbarPainterDelegate mouseLocationInScrollerForScrollerImp:]):
3806
3807 2011-12-09  Mark Pilgrim  <pilgrim@chromium.org>
3808
3809         [FileSystem API] Entry.remove successCallback is required
3810         https://bugs.webkit.org/show_bug.cgi?id=69639
3811
3812         Reviewed by Adam Barth.
3813
3814         Test: fast/filesystem/simple-required-arguments-remove.html
3815
3816         * fileapi/Entry.idl: remove [Optional] flag from Entry.remove.successCallback parameter
3817
3818 2011-12-09  Tim Horton  <timothy_horton@apple.com>
3819
3820         background-image transitions trigger between equivalent images
3821         https://bugs.webkit.org/show_bug.cgi?id=74229
3822         <rdar://problem/10558627>
3823
3824         Reviewed by Darin Adler.
3825         Patch by Simon Fraser.
3826
3827         For animation property wrappers around StyleImage properties,
3828         test the equivalence of the image itself, instead of equality of
3829         the StyleImage pointer.
3830
3831         Test: transitions/equivalent-background-image-no-transition.html
3832
3833         * page/animation/AnimationBase.cpp:
3834         (WebCore::StyleImagePropertyWrapper::StyleImagePropertyWrapper):
3835         (WebCore::StyleImagePropertyWrapper::equals):
3836         (WebCore::FillLayerStyleImagePropertyWrapper::FillLayerStyleImagePropertyWrapper):
3837         (WebCore::FillLayerStyleImagePropertyWrapper::equals):
3838         (WebCore::FillLayersPropertyWrapper::FillLayersPropertyWrapper):
3839         (WebCore::AnimationBase::ensurePropertyMap):
3840
3841 2011-12-09  Mary Wu  <mary.wu@torchmobile.com.cn>
3842
3843         Small style fix on DragDataBlackBerry.cpp
3844         https://bugs.webkit.org/show_bug.cgi?id=74171
3845
3846         Reviewed by Rob Buis.
3847
3848         Style fix, no function impact, no new tests.
3849
3850         * platform/blackberry/DragDataBlackBerry.cpp:
3851         (WebCore::DragData::containsURL):
3852         (WebCore::DragData::asFilenames):
3853         (WebCore::DragData::asURL):
3854         (WebCore::DragData::asFragment):
3855
3856 2011-12-09  Tony Chang  <tony@chromium.org>
3857
3858         add css parsing for flex-flow: wrap and wrap-reverse
3859         https://bugs.webkit.org/show_bug.cgi?id=74008
3860
3861         Reviewed by Ojan Vafai.
3862
3863         Also save 2 bits in StyleFlexibleBoxData by changing the size of m_flexFlow (there are only 4 enum values).
3864
3865         * css/CSSComputedStyleDeclaration.cpp:
3866         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): Print the wrap value if it exists.
3867         * css/CSSParser.cpp:
3868         (WebCore::CSSParser::parseValue): Parse a second token and put the values into a CSSValueList.
3869         * css/CSSPrimitiveValueMappings.h:
3870         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
3871         (WebCore::CSSPrimitiveValue::operator EFlexWrap):
3872         * css/CSSStyleApplyProperty.cpp:
3873         (WebCore::ApplyPropertyFlexFlow::applyInheritValue): Does not inherit.
3874         (WebCore::ApplyPropertyFlexFlow::applyInitialValue):
3875         (WebCore::ApplyPropertyFlexFlow::applyValue): Special handler for setting two render style values from one
3876         CSS property.
3877         (WebCore::ApplyPropertyFlexFlow::createHandler):
3878         (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):
3879         * css/CSSValueKeywords.in:
3880         * rendering/style/RenderStyle.h:
3881         (WebCore::InheritedFlags::flexWrap):
3882         (WebCore::InheritedFlags::setFlexWrap):
3883         (WebCore::InheritedFlags::initialFlexWrap):
3884         * rendering/style/RenderStyleConstants.h: EFlexWrap to hold flex wrap values.
3885         * rendering/style/StyleFlexibleBoxData.cpp:
3886         (WebCore::StyleFlexibleBoxData::StyleFlexibleBoxData):
3887         (WebCore::StyleFlexibleBoxData::operator==):
3888         * rendering/style/StyleFlexibleBoxData.h: 2 bits is enough to hold the 4 flexFlow values.
3889
3890 2011-12-09  KwangHyuk Kim  <hyuki.kim@samsung.com>
3891
3892         [EFL] Add RefPtrEfl specialization for evas_object.
3893         https://bugs.webkit.org/show_bug.cgi?id=73790
3894
3895         Reviewed by Ryosuke Niwa.
3896
3897         As evas_object is also based on reference count, RefPtr is applied for evas_object.
3898
3899         * PlatformEfl.cmake:
3900         * platform/efl/RefPtrEfl.cpp: Added.
3901         (WTF::refIfNotNull):
3902         (WTF::derefIfNotNull):
3903         * platform/efl/RefPtrEfl.h: Added.
3904
3905 2011-12-09  Tony Chang  <tony@chromium.org>
3906
3907         REGRESSION(102234): 2-3% layout regression
3908         https://bugs.webkit.org/show_bug.cgi?id=74141
3909
3910         Reviewed by David Hyatt.
3911
3912         Don't allocate a RuleSet when there are no regions.
3913
3914         * css/CSSStyleSelector.cpp:
3915         (WebCore::CSSStyleSelector::initForRegionStyling):
3916
3917 2011-12-09  Anders Carlsson  <andersca@apple.com>
3918
3919         Fix assertion failure in ScrollAnimatorMac
3920         https://bugs.webkit.org/show_bug.cgi?id=74222
3921
3922         Reviewed by Andreas Kling.
3923
3924         * platform/mac/ScrollAnimatorMac.mm:
3925         (-[WebScrollbarPainterControllerDelegate scrollerImpPair:convertContentPoint:toScrollerImp:]):
3926         This can be called with a nil scrollerImp, just return NSZeroPoint when that happens.
3927
3928 2011-12-09  Anders Carlsson  <andersca@apple.com>
3929
3930         Move the "is currently drawing into layer" flag out into ScrollbarThemeMac
3931         https://bugs.webkit.org/show_bug.cgi?id=74217
3932
3933         Reviewed by Beth Dakin.
3934
3935         There's no need to store this flag inside ScrollAnimatorMac, just make it a global and put it in ScrollbarThemeMac instead.
3936
3937         * platform/mac/ScrollAnimatorMac.h:
3938         * platform/mac/ScrollAnimatorMac.mm:
3939         (-[WebScrollbarPainterDelegate layer]):
3940         (WebCore::ScrollAnimatorMac::ScrollAnimatorMac):
3941         * platform/mac/ScrollbarThemeMac.h:
3942         * platform/mac/ScrollbarThemeMac.mm:
3943         (WebCore::ScrollbarThemeMac::isCurrentlyDrawingIntoLayer):
3944         (WebCore::ScrollbarThemeMac::paint):
3945
3946 2011-12-09  Anders Carlsson  <andersca@apple.com>
3947
3948         Minor cleanup in ScrollAnimatorMac.mm
3949         https://bugs.webkit.org/show_bug.cgi?id=74211
3950
3951         Reviewed by Andreas Kling.
3952
3953         * platform/mac/ScrollAnimatorMac.mm:
3954         (-[WebScrollbarPainterDelegate mouseLocationInScrollerForScrollerImp:]):
3955         No need to get the scrollbar from the scroll animator anymore.
3956
3957         (-[WebScrollbarPainterDelegate setUpAlphaAnimation:scrollerPainter:part:WebCore::animateAlphaTo:duration:]):
3958         (-[WebScrollbarPainterDelegate scrollerImp:animateUIStateTransitionWithDuration:]):
3959         Try to get data from the scrollbar and/or the scrollable area instead of the scrollbar painter.
3960
3961 2011-12-09  David Levin  <levin@chromium.org>
3962
3963         Regression(r53595): Sync xhr requests in workers aren't terminated on worker close.
3964         https://bugs.webkit.org/show_bug.cgi?id=71695
3965
3966         Reviewed by Zoltan Herczeg.
3967
3968         Overview: Message loops rely on the message queue being killed in order
3969         to exit. r53595 stopped this from happening because killing a message loop
3970         would also stop it from doing database clean up tasks. The database clean up
3971         tasks needed to be tasks due to ordering issues. (They wanted to run after
3972         certain order tasks were run.) This was solved by once again terminating
3973         the message queue but then still runnning clean-up tasks from the killed
3974         message queue.
3975
3976         * workers/WorkerRunLoop.cpp:
3977         (WebCore::WorkerRunLoop::run): Added the call to run clean-up tasks.
3978         (WebCore::WorkerRunLoop::runInMode):
3979         (WebCore::WorkerRunLoop::runCleanupTasks): Loop to simply clear out all clean up tasks.
3980         (WebCore::WorkerRunLoop::Task::performTask): Stop non-clean up tasks
3981         from running after the loop has been terminated.
3982         * workers/WorkerRunLoop.h:
3983         (WebCore::WorkerRunLoop::terminated): Just made it const.
3984         * workers/WorkerThread.cpp:
3985         (WebCore::WorkerThreadShutdownFinishTask::performTask): Removed
3986         the terminate clause since it was put back in stop.
3987         (WebCore::WorkerThread::stop): Terminate the run loop so
3988         that all loops will exit and clean up tasks will run. Also removed a comment
3989         about nested workers because nested workers are no longer imminent and the
3990         issue mentioned is one of many that should logically be investigated -- behavior correctness
3991         in the face of different orderings of shutdown between the document and each worker --
3992         when implementing them.
3993
3994 2011-12-09  Tony Chang  <tony@chromium.org>
3995
3996         Unreviewed, rolling out r102416.
3997         http://trac.webkit.org/changeset/102416
3998         https://bugs.webkit.org/show_bug.cgi?id=73394
3999
4000         Chromium Win clobber builds are failing.
4001
4002         * WebCore.gyp/WebCore.gyp:
4003         * WebCore.gyp/scripts/action_derivedsourcesallinone.py:
4004         (main):
4005         * WebCore.gypi:
4006         * bindings/scripts/generate-bindings.pl:
4007         * page/DOMWindow.idl:
4008         * webaudio/DOMWindowWebAudio.idl: Removed.
4009
4010 2011-12-09  Eric Carlson  <eric.carlson@apple.com>
4011
4012         JSC wrappers for TextTrack and TextTrackCue should not be collected during event dispatch or when owner is reachable
4013         https://bugs.webkit.org/show_bug.cgi?id=72179
4014
4015         Reviewed by Geoff Garen.
4016
4017         Tests: media/track/text-track-cue-is-reachable.html
4018                media/track/text-track-is-reachable.html
4019
4020         * GNUmakefile.list.am: Add JSTextTrackCueCustom.cpp and JSTextTrackCustom.cpp.
4021         * Target.pri: Ditto.
4022         * WebCore.gypi: Ditto.
4023         * WebCore.xcodeproj/project.pbxproj: Ditto
4024         * bindings/js/JSBindingsAllInOne.cpp: Ditto.
4025
4026         * bindings/js/JSTextTrackCueCustom.cpp: Added.
4027         (WebCore::JSTextTrackCueOwner::isReachableFromOpaqueRoots): New.
4028         (WebCore::JSTextTrackCueOwner::visitChildren): New.
4029
4030         * bindings/js/JSTextTrackCustom.cpp: Added.
4031         (WebCore::JSTextTrackOwner::isReachableFromOpaqueRoots): New.
4032         (WebCore::JSTextTrack::visitChildren): New, mark all cues.
4033         * bindings/js/JSTextTrackCustom.h: Added.
4034         (WebCore::root): New.
4035
4036         * bindings/js/JSTextTrackListCustom.cpp:
4037         (WebCore::JSTextTrackList::visitChildren): New, mark all tracks.
4038
4039         * html/HTMLMediaElement.cpp:
4040         (WebCore::HTMLMediaElement::trackWillBeRemoved): TextTracks::remove now takes a TextTrack*.
4041
4042         * html/LoadableTextTrack.h:
4043         (WebCore::LoadableTextTrack::trackElement): New, return the <track>.
4044
4045         * html/TextTrack.cpp:
4046         (WebCore::TextTrack::TextTrack): Initialize m_mediaElement.
4047         * html/TextTrack.h:
4048         (WebCore::TextTrack::setMediaElement): New.
4049         (WebCore::TextTrack::mediaElement): Ditto.
4050
4051         * html/TextTrack.idl: Add CustomIsReachable and CustomMarkFunction.
4052
4053         * html/TextTrackCue.idl: Add CustomIsReachable.
4054
4055         * html/track/TextTrackList.cpp:
4056         (TextTrackList::append): Set track's media element.
4057         (TextTrackList::remove): Clear track's media element. Take a raw ptr, not a PassRefPtr.
4058         * html/track/TextTrackList.h:
4059         * html/track/TextTrackList.idl: Add CustomMarkFunction
4060
4061 2011-12-09  Chris Fleizach  <cfleizach@apple.com>
4062
4063         WebKit should ignore images with @alt matching only whitespace
4064         https://bugs.webkit.org/show_bug.cgi?id=74189
4065
4066         Reviewed by Darin Adler.
4067
4068         Test: accessibility/img-alt-tag-only-whitespace.html
4069
4070         * accessibility/AccessibilityRenderObject.cpp:
4071         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
4072
4073 2011-12-09  Anders Carlsson  <andersca@apple.com>
4074
4075         Remove NSAnimationContext calls
4076         https://bugs.webkit.org/show_bug.cgi?id=74207
4077
4078         Reviewed by Sam Weinig.
4079
4080         NSAnimationContext is not used for NSAnimation subclasses, so the calls to beginGrouping/endGrouping and setDuration:
4081         are essentially no-ops. Remove them.
4082
4083         * platform/mac/ScrollAnimatorMac.mm:
4084         (-[WebScrollbarPainterDelegate setUpAlphaAnimation:scrollerPainter:part:WebCore::animateAlphaTo:duration:]):
4085         (-[WebScrollbarPainterDelegate scrollerImp:animateUIStateTransitionWithDuration:]):
4086
4087 2011-12-09  Anders Carlsson  <andersca@apple.com>
4088
4089         Rename scrollAnimatorDestroyed to invalidate
4090         https://bugs.webkit.org/show_bug.cgi?id=74206
4091
4092         Reviewed by Sam Weinig.
4093
4094         Since these methods can be called when both scrollbars are destroyed and the scroll animator itself is
4095         destroyed, rename it to something more neutral.
4096
4097         * platform/mac/ScrollAnimatorMac.mm:
4098         (-[WebScrollAnimationHelperDelegate invalidate]):
4099         (-[WebScrollbarPartAnimation invalidate]):
4100         (-[WebScrollbarPainterDelegate invalidate]):
4101         (WebCore::ScrollAnimatorMac::~ScrollAnimatorMac):
4102         (WebCore::ScrollAnimatorMac::willRemoveVerticalScrollbar):
4103         (WebCore::ScrollAnimatorMac::willRemoveHorizontalScrollbar):
4104
4105 2011-12-09  Anders Carlsson  <andersca@apple.com>
4106
4107         WebScrollbarPainterControllerDelegate should know about the ScrollableArea, not the ScrollAnimatorMac
4108         https://bugs.webkit.org/show_bug.cgi?id=74204
4109
4110         Reviewed by Sam Weinig.
4111
4112         It makes more logical sense to associate the WebScrollbarPainterControllerDelegate object with its ScrollableArea, since
4113         painting has nothing to do with animation.
4114
4115         * platform/mac/ScrollAnimatorMac.mm:
4116         (-[WebScrollbarPainterControllerDelegate initWithScrollableArea:]):
4117         (-[WebScrollbarPainterControllerDelegate invalidate]):
4118         (-[WebScrollbarPainterControllerDelegate contentAreaRectForScrollerImpPair:]):
4119         (-[WebScrollbarPainterControllerDelegate inLiveResizeForScrollerImpPair:]):
4120         (-[WebScrollbarPainterControllerDelegate mouseLocationInContentAreaForScrollerImpPair:]):
4121         (-[WebScrollbarPainterControllerDelegate scrollerImpPair:convertContentPoint:toScrollerImp:]):
4122         (-[WebScrollbarPainterControllerDelegate scrollerImpPair:updateScrollerStyleForNewRecommendedScrollerStyle:]):
4123         (WebCore::ScrollAnimatorMac::ScrollAnimatorMac):
4124         (WebCore::ScrollAnimatorMac::~ScrollAnimatorMac):
4125
4126 2011-12-09  Jarred Nicholls  <jarred@sencha.com>
4127
4128         [JSC] Allow cached attributes in bindings that declare a custom mark function
4129         https://bugs.webkit.org/show_bug.cgi?id=74187
4130
4131         Reviewed by Oliver Hunt.
4132
4133         No new tests, current binding tests are sufficient.
4134
4135         * bindings/scripts/CodeGeneratorJS.pm:
4136         (GenerateImplementation):
4137
4138 2011-12-09  Anders Carlsson  <andersca@apple.com>
4139
4140         Remove duplicate animation ivars
4141         https://bugs.webkit.org/show_bug.cgi?id=74194
4142
4143         Reviewed by Sam Weinig.
4144
4145         Since we now have one WebScrollbarPainterDelegate for each scrollbar, we no longer need separate
4146         vertical/horizontal animation objects, so get rid of them.
4147
4148         * platform/mac/ScrollAnimatorMac.mm:
4149         (-[WebScrollbarPainterDelegate cancelAnimations]):
4150         (-[WebScrollbarPainterDelegate scrollerImp:animateKnobAlphaTo:duration:]):
4151         (-[WebScrollbarPainterDelegate scrollerImp:animateTrackAlphaTo:duration:]):
4152         (-[WebScrollbarPainterDelegate scrollerImp:animateUIStateTransitionWithDuration:]):
4153         (-[WebScrollbarPainterDelegate scrollAnimatorDestroyed]):
4154
4155 2011-12-09  Anders Carlsson  <andersca@apple.com>
4156
4157         WebScrollbarPartAnimation should only know about the scrollbar it's animating
4158         https://bugs.webkit.org/show_bug.cgi?id=74192
4159
4160         Reviewed by Sam Weinig.
4161
4162         * platform/mac/ScrollAnimatorMac.mm:
4163         (-[WebScrollbarPartAnimation initWithScrollbar:featureToAnimate:animateFrom:animateTo:duration:]):