Reviewed by Darin Adler.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-01-26  Alexey Proskuryakov  <ap@apple.com>
2
3         Reviewed by Darin Adler.
4
5         https://bugs.webkit.org/show_bug.cgi?id=53197
6         <rdar://problem/8895682> Make WebKit2 printing asynchronous
7
8         * WebCore.exp.in: Export more PrintContext methods that we didn't use on Mac before.
9
10         * page/PrintContext.cpp: (WebCore::PrintContext::spoolRect): Changed to make the same
11         transformation as spoolPages does for consistency.
12
13 2011-01-27  David Grogan  <dgrogan@google.com>
14
15         Reviewed by Jeremy Orlow.
16
17         initial support for close() in indexeddb backend
18         https://bugs.webkit.org/show_bug.cgi?id=53150
19
20         Test: storage/indexeddb/transaction-after-close.html
21
22         * storage/IDBDatabase.cpp:
23         (WebCore::IDBDatabase::IDBDatabase):
24         (WebCore::IDBDatabase::transaction):
25         (WebCore::IDBDatabase::close):
26         * storage/IDBDatabase.h:
27         * storage/IDBDatabase.idl:
28         * storage/IDBDatabaseBackendImpl.cpp:
29         (WebCore::IDBDatabaseBackendImpl::transaction):
30         (WebCore::IDBDatabaseBackendImpl::close):
31
32 2011-01-27  Dirk Schulze  <krit@webkit.org>
33
34         Reviewed by Nikolas Zimmermann.
35
36         SVG animation doesn't support calcMode discrete for number and color values.
37         https://bugs.webkit.org/show_bug.cgi?id=53189
38
39         Add support for calcMode discrete on number and color animation.
40
41         Tests: svg/animations/animate-color-calcMode-discrete.html
42                svg/animations/animate-number-calcMode-discrete.html
43
44         * svg/SVGAnimateElement.cpp:
45         (WebCore::SVGAnimateElement::calculateAnimatedValue):
46
47 2011-01-26  Zhenyao Mo  <zmo@google.com>
48
49         Reviewed by Kenneth Russell.
50
51         shaderSource needs to preserve original source
52         https://bugs.webkit.org/show_bug.cgi?id=52833
53
54         Test: fast/canvas/webgl/gl-getshadersource.html
55
56         * html/canvas/WebGLRenderingContext.cpp:
57         (WebCore::WebGLRenderingContext::getShaderParameter): Intercept SHADER_SOURCE_LENGTH.
58         (WebCore::WebGLRenderingContext::getShaderSource): Intercept the call.
59         (WebCore::WebGLRenderingContext::shaderSource): Cache the source.
60         * html/canvas/WebGLShader.cpp: Cache shader source.
61         (WebCore::WebGLShader::WebGLShader):
62         * html/canvas/WebGLShader.h: Ditto.
63         (WebCore::WebGLShader::getSource):
64         (WebCore::WebGLShader::setSource):
65
66 2011-01-27  Patrick Gansterer  <paroga@webkit.org>
67
68         Unreviewed WinCE build fix for r76743.
69
70         * platform/graphics/wince/FontWinCE.cpp:
71         (WebCore::TextRunComponent::TextRunComponent):
72
73 2011-01-27  Pavel Podivilov  <podivilov@chromium.org>
74
75         Reviewed by Pavel Feldman.
76
77         Web Inspector: Closure and Global variable details automatically collapsing on each step through JavaScript code.
78         https://bugs.webkit.org/show_bug.cgi?id=53234
79
80         * inspector/front-end/ScopeChainSidebarPane.js:
81         (WebInspector.ScopeChainSidebarPane):
82         (WebInspector.ScopeChainSidebarPane.prototype.update):
83
84 2011-01-27  Sheriff Bot  <webkit.review.bot@gmail.com>
85
86         Unreviewed, rolling out r76789.
87         http://trac.webkit.org/changeset/76789
88         https://bugs.webkit.org/show_bug.cgi?id=53238
89
90         Broke GTK layout tests (Requested by podivilov on #webkit).
91
92         * inspector/front-end/ScopeChainSidebarPane.js:
93         (WebInspector.ScopeChainSidebarPane):
94         (WebInspector.ScopeChainSidebarPane.prototype.update):
95
96 2011-01-27  Yury Semikhatsky  <yurys@chromium.org>
97
98         Reviewed by Pavel Feldman.
99
100         Web Inspector: store all settings related to the agents on the frontend side
101         https://bugs.webkit.org/show_bug.cgi?id=53174
102
103         * CMakeLists.txt:
104         * GNUmakefile.am:
105         * WebCore.exp.in:
106         * WebCore.gypi:
107         * WebCore.pro:
108         * WebCore.vcproj/WebCore.vcproj:
109         * WebCore.xcodeproj/project.pbxproj:
110         * bindings/js/ScriptDebugServer.cpp:
111         * bindings/js/ScriptDebugServer.h:
112         * bindings/js/ScriptProfiler.cpp:
113         * bindings/js/ScriptProfiler.h:
114         * bindings/v8/ScriptDebugServer.cpp:
115         * bindings/v8/ScriptDebugServer.h:
116         * bindings/v8/ScriptProfiler.cpp:
117         * bindings/v8/ScriptProfiler.h:
118         * inspector/Inspector.idl:
119         * inspector/InspectorAgent.cpp: profiler and debugger enablement state is now stored
120         on the front-end side and will be pushed to the backend when the frontend is loaded.
121         (WebCore::InspectorAgent::InspectorAgent):
122         (WebCore::InspectorAgent::disconnectFrontend):
123         (WebCore::InspectorAgent::restoreDebugger):
124         (WebCore::InspectorAgent::restoreProfiler):
125         (WebCore::InspectorAgent::enableProfiler):
126         (WebCore::InspectorAgent::disableProfiler):
127         (WebCore::InspectorAgent::showAndEnableDebugger):
128         (WebCore::InspectorAgent::enableDebugger):
129         (WebCore::InspectorAgent::disableDebugger):
130         * inspector/InspectorAgent.h:
131         * inspector/InspectorConsoleAgent.cpp: XHR failures will be logged to the console only
132         if the front-end was opened during current browser session and XHR logging is turned on
133         there.
134         (WebCore::InspectorConsoleAgent::setMonitoringXHREnabled):
135         (WebCore::InspectorConsoleAgent::setConsoleMessagesEnabled):
136         * inspector/InspectorDebuggerAgent.cpp:
137         * inspector/InspectorDebuggerAgent.h:
138         * inspector/InspectorInstrumentation.cpp:
139         (WebCore::InspectorInstrumentation::identifierForInitialRequestImpl):
140         (WebCore::InspectorInstrumentation::didLoadResourceFromMemoryCacheImpl):
141         * inspector/InspectorProfilerAgent.cpp:
142         (WebCore::InspectorProfilerAgent::InspectorProfilerAgent):
143         (WebCore::InspectorProfilerAgent::startUserInitiatedProfiling):
144         * inspector/InspectorSettings.cpp: Removed.
145         * inspector/InspectorSettings.h: Removed.
146         * inspector/InspectorState.cpp:
147         (WebCore::InspectorState::InspectorState):
148         * inspector/InspectorState.h:
149         * inspector/front-end/ConsoleView.js:
150         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher.dispatcher.consoleMessagesCleared):
151         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher):
152         (WebInspector.ConsoleView.prototype._handleContextMenuEvent.itemAction):
153         (WebInspector.ConsoleView.prototype._handleContextMenuEvent):
154         * inspector/front-end/ProfilesPanel.js:
155         (WebInspector.ProfilesPanel.prototype._toggleProfiling):
156         * inspector/front-end/ScriptsPanel.js:
157         (WebInspector.ScriptsPanel.prototype._toggleDebugging):
158         * inspector/front-end/Settings.js:
159         (WebInspector.Settings):
160         * inspector/front-end/inspector.js:
161
162 2011-01-27  Pavel Podivilov  <podivilov@chromium.org>
163
164         Reviewed by Pavel Feldman.
165
166         Web Inspector: Closure and Global variable details automatically collapsing on each step through JavaScript code.
167         https://bugs.webkit.org/show_bug.cgi?id=53234
168
169         * inspector/front-end/ScopeChainSidebarPane.js:
170         (WebInspector.ScopeChainSidebarPane):
171         (WebInspector.ScopeChainSidebarPane.prototype.update):
172
173 2011-01-27  Alexander Pavlov  <apavlov@chromium.org>
174
175         Reviewed by Pavel Feldman.
176
177         Web Inspector: [Elements panel] Tooltip for relative links incorrectly identifies current URL
178         https://bugs.webkit.org/show_bug.cgi?id=53171
179
180         * inspector/front-end/inspector.js:
181         (WebInspector.completeURL): Taught to understand partial href's that start with "?" (contain GET parameters only)
182
183 2011-01-27  Yury Semikhatsky  <yurys@chromium.org>
184
185         Reviewed by Pavel Feldman.
186
187         [V8] Crash in WebCore::addMessageToConsole
188         https://bugs.webkit.org/show_bug.cgi?id=53227
189
190         * bindings/v8/V8Proxy.cpp: check that the Frame where the error
191         occured still has a page before getting a console object from it.
192         (WebCore::V8Proxy::reportUnsafeAccessTo):
193
194 2011-01-27  Hans Wennborg  <hans@chromium.org>
195
196         Reviewed by Jeremy Orlow.
197
198         IndexedDB: Remove IDBCallbacks::onSuccess() used for null values.
199         https://bugs.webkit.org/show_bug.cgi?id=53178
200
201         Remove the IDBCallbacks::onSuccess() function that was used for
202         null values, and replace such calls with calls to
203         IDBCallBacks::onSuccess(SerializedScriptValue::nullValue())
204         instead.
205
206         No new functionality, so no new tests.
207
208         * storage/IDBCallbacks.h:
209         * storage/IDBCursorBackendImpl.cpp:
210         (WebCore::IDBCursorBackendImpl::updateInternal):
211         (WebCore::IDBCursorBackendImpl::continueFunctionInternal):
212         * storage/IDBIndexBackendImpl.cpp:
213         (WebCore::IDBIndexBackendImpl::openCursorInternal):
214         * storage/IDBObjectStoreBackendImpl.cpp:
215         (WebCore::IDBObjectStoreBackendImpl::deleteInternal):
216         (WebCore::IDBObjectStoreBackendImpl::openCursorInternal):
217         * storage/IDBRequest.cpp:
218         * storage/IDBRequest.h:
219
220 2011-01-27  Sheriff Bot  <webkit.review.bot@gmail.com>
221
222         Unreviewed, rolling out r76773.
223         http://trac.webkit.org/changeset/76773
224         https://bugs.webkit.org/show_bug.cgi?id=53230
225
226         breaks multiple GTK media tests (Requested by philn-tp on
227         #webkit).
228
229         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
230         (WebCore::mimeTypeCache):
231
232 2011-01-27  Sheriff Bot  <webkit.review.bot@gmail.com>
233
234         Unreviewed, rolling out r76770.
235         http://trac.webkit.org/changeset/76770
236         https://bugs.webkit.org/show_bug.cgi?id=53229
237
238         Some inspector tests fail (Requested by yurys on #webkit).
239
240         * CMakeLists.txt:
241         * GNUmakefile.am:
242         * WebCore.exp.in:
243         * WebCore.gypi:
244         * WebCore.pro:
245         * WebCore.vcproj/WebCore.vcproj:
246         * WebCore.xcodeproj/project.pbxproj:
247         * bindings/js/ScriptDebugServer.cpp:
248         (WebCore::ScriptDebugServer::isDebuggerAlwaysEnabled):
249         * bindings/js/ScriptDebugServer.h:
250         * bindings/js/ScriptProfiler.cpp:
251         (WebCore::ScriptProfiler::isProfilerAlwaysEnabled):
252         * bindings/js/ScriptProfiler.h:
253         * bindings/v8/ScriptDebugServer.cpp:
254         (WebCore::ScriptDebugServer::isDebuggerAlwaysEnabled):
255         * bindings/v8/ScriptDebugServer.h:
256         * bindings/v8/ScriptProfiler.cpp:
257         (WebCore::ScriptProfiler::isProfilerAlwaysEnabled):
258         * bindings/v8/ScriptProfiler.h:
259         * inspector/Inspector.idl:
260         * inspector/InspectorAgent.cpp:
261         (WebCore::InspectorAgent::InspectorAgent):
262         (WebCore::InspectorAgent::disconnectFrontend):
263         (WebCore::InspectorAgent::restoreDebugger):
264         (WebCore::InspectorAgent::restoreProfiler):
265         (WebCore::InspectorAgent::ensureSettingsLoaded):
266         (WebCore::InspectorAgent::enableProfiler):
267         (WebCore::InspectorAgent::disableProfiler):
268         (WebCore::InspectorAgent::showAndEnableDebugger):
269         (WebCore::InspectorAgent::enableDebugger):
270         (WebCore::InspectorAgent::disableDebugger):
271         * inspector/InspectorAgent.h:
272         (WebCore::InspectorAgent::settings):
273         * inspector/InspectorConsoleAgent.cpp:
274         (WebCore::InspectorConsoleAgent::setMonitoringXHREnabled):
275         (WebCore::InspectorConsoleAgent::setConsoleMessagesEnabled):
276         * inspector/InspectorDebuggerAgent.cpp:
277         (WebCore::InspectorDebuggerAgent::isDebuggerAlwaysEnabled):
278         * inspector/InspectorDebuggerAgent.h:
279         * inspector/InspectorInstrumentation.cpp:
280         (WebCore::InspectorInstrumentation::identifierForInitialRequestImpl):
281         (WebCore::InspectorInstrumentation::didLoadResourceFromMemoryCacheImpl):
282         * inspector/InspectorProfilerAgent.cpp:
283         (WebCore::InspectorProfilerAgent::InspectorProfilerAgent):
284         (WebCore::InspectorProfilerAgent::startUserInitiatedProfiling):
285         * inspector/InspectorSettings.cpp: Added.
286         (WebCore::InspectorSettings::InspectorSettings):
287         (WebCore::InspectorSettings::getBoolean):
288         (WebCore::InspectorSettings::setBoolean):
289         (WebCore::InspectorSettings::getLong):
290         (WebCore::InspectorSettings::setLong):
291         (WebCore::InspectorSettings::registerBoolean):
292         (WebCore::InspectorSettings::registerLong):
293         * inspector/InspectorSettings.h: Copied from Source/WebCore/bindings/v8/ScriptProfiler.h.
294         * inspector/InspectorState.cpp:
295         (WebCore::InspectorState::InspectorState):
296         * inspector/InspectorState.h:
297         * inspector/front-end/ConsoleView.js:
298         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher.dispatcher.monitoringXHRStateChanged):
299         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher):
300         (WebInspector.ConsoleView.prototype._handleContextMenuEvent):
301         * inspector/front-end/ProfilesPanel.js:
302         (WebInspector.ProfilesPanel.prototype._toggleProfiling):
303         * inspector/front-end/ScriptsPanel.js:
304         (WebInspector.ScriptsPanel.prototype._toggleDebugging):
305         * inspector/front-end/Settings.js:
306         (WebInspector.Settings):
307         * inspector/front-end/inspector.js:
308
309 2011-01-26  Philippe Normand  <pnormand@igalia.com>
310
311         Reviewed by Martin Robinson.
312
313         [GTK] LayoutTests/media/audio-mpeg4-supported.html fails
314         https://bugs.webkit.org/show_bug.cgi?id=53125
315
316         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
317         (WebCore::mimeTypeCache): Add audio/x-m4a mimetype in the cache.
318
319 2011-01-26  Yury Semikhatsky  <yurys@chromium.org>
320
321         Reviewed by Pavel Feldman.
322
323         Web Inspector: store all settings related to the agents on the frontend side
324         https://bugs.webkit.org/show_bug.cgi?id=53174
325
326         * CMakeLists.txt:
327         * GNUmakefile.am:
328         * WebCore.exp.in:
329         * WebCore.gypi:
330         * WebCore.pro:
331         * WebCore.vcproj/WebCore.vcproj:
332         * WebCore.xcodeproj/project.pbxproj:
333         * inspector/Inspector.idl:
334         * inspector/InspectorAgent.cpp: profiler and debugger enablement state is now stored
335         on the front-end side and will be pushed to the backend when the frontend is loaded.
336         (WebCore::InspectorAgent::InspectorAgent):
337         (WebCore::InspectorAgent::disconnectFrontend):
338         (WebCore::InspectorAgent::restoreDebugger):
339         (WebCore::InspectorAgent::restoreProfiler):
340         (WebCore::InspectorAgent::enableProfiler):
341         (WebCore::InspectorAgent::disableProfiler):
342         (WebCore::InspectorAgent::showAndEnableDebugger):
343         (WebCore::InspectorAgent::enableDebugger):
344         (WebCore::InspectorAgent::disableDebugger):
345         * inspector/InspectorAgent.h:
346         * inspector/InspectorConsoleAgent.cpp: XHR failures will be logged to the console only
347         if the front-end was opened during current browser session and XHR logging is turned on
348         there.
349         (WebCore::InspectorConsoleAgent::setMonitoringXHREnabled):
350         (WebCore::InspectorConsoleAgent::setConsoleMessagesEnabled):
351         * inspector/InspectorInstrumentation.cpp:
352         (WebCore::InspectorInstrumentation::identifierForInitialRequestImpl):
353         (WebCore::InspectorInstrumentation::didLoadResourceFromMemoryCacheImpl):
354         * inspector/InspectorProfilerAgent.cpp:
355         (WebCore::InspectorProfilerAgent::enable):
356         (WebCore::InspectorProfilerAgent::startUserInitiatedProfiling):
357         * inspector/InspectorProfilerAgent.h:
358         * inspector/InspectorSettings.cpp: Removed.
359         * inspector/InspectorSettings.h: Removed.
360         * inspector/InspectorState.cpp:
361         (WebCore::InspectorState::InspectorState):
362         * inspector/InspectorState.h:
363         * inspector/front-end/ConsoleView.js:
364         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher.dispatcher.consoleMessagesCleared):
365         (WebInspector.ConsoleView.prototype._registerConsoleDomainDispatcher):
366         (WebInspector.ConsoleView.prototype._handleContextMenuEvent.itemAction):
367         (WebInspector.ConsoleView.prototype._handleContextMenuEvent):
368         * inspector/front-end/ProfilesPanel.js:
369         (WebInspector.ProfilesPanel.prototype._toggleProfiling):
370         * inspector/front-end/ScriptsPanel.js:
371         (WebInspector.ScriptsPanel.prototype._toggleDebugging):
372         * inspector/front-end/Settings.js:
373         (WebInspector.Settings):
374         * inspector/front-end/inspector.js:
375
376 2011-01-27  Dan Bernstein  <mitz@apple.com>
377
378         Reviewed by Sam Weinig.
379
380         REGRESSION (r76743): Uneven spacing in right-to-left justified text
381         https://bugs.webkit.org/show_bug.cgi?id=53225
382
383         Fixes failure in fast/text/atsui-spacing-features.html
384
385         There was an inconsistency between rendering code and font code in the interpretation of
386         'after expansion' and 'trailing expansion'. Changed all code to interpret these in terms of
387         visual order rather than logical.
388
389         * platform/graphics/Font.cpp:
390         (WebCore::Font::expansionOpportunityCount): Added a text direction parameter and changed to
391         iterate in visual order accordingly.
392         * platform/graphics/Font.h:
393         * platform/graphics/WidthIterator.cpp:
394         (WebCore::WidthIterator::WidthIterator): Pass the run direction to expansionOpportunityCount().
395         (WebCore::WidthIterator::advance): For right-to-left runs, evaluate the trailing expansion
396         condition with respect to the first character, which is the trailing character in visual order.
397         * platform/graphics/mac/ComplexTextController.cpp:
398         (WebCore::ComplexTextController::ComplexTextController): Pass the run direction to
399         expansionOpportunityCount().
400         * rendering/RenderBlockLineLayout.cpp:
401         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine): Ditto.
402
403 2011-01-26  Adam Roben  <aroben@apple.com>
404
405         Don't create the Direct3D device before it's first needed
406
407         We only need the device once we decide to render. There's no point in creating it before
408         then.
409
410         Reviewed by Sam Weinig.
411
412         * platform/graphics/ca/win/CACFLayerTreeHost.cpp:
413         (WebCore::CACFLayerTreeHost::setWindow): Removed the call to createRenderer() from here.
414         We already have code to create it when we first try to draw.
415         (WebCore::CACFLayerTreeHost::createRenderer): Flush the context after we set our layer's
416         bounds so that the bounds will take effect the next time we render (which could be just
417         after this function returns).
418
419 2011-01-26  Adam Roben  <aroben@apple.com>
420
421         Add assertions that CACFLayerTreeHost gains and loses an HWND only once
422
423         CACFLayerTreeHost doesn't support any other use pattern.
424
425         Reviewed by Sam Weinig.
426
427         * platform/graphics/ca/win/CACFLayerTreeHost.cpp:
428         (WebCore::CACFLayerTreeHost::CACFLayerTreeHost): Initialize new member.
429         (WebCore::CACFLayerTreeHost::setWindow): Assert that we transition from not having a window,
430         to having a window, to not having a window just once over the lifetime of this object.
431
432         * platform/graphics/ca/win/CACFLayerTreeHost.h: Added m_state.
433
434 2011-01-26  Adam Roben  <aroben@apple.com>
435
436         Notify layers that their animations have started when we flush the context, not when we
437         render
438
439         r76372 separated context flushing from rendering, but this bit of code got left behind.
440
441         Reviewed by Sam Weinig.
442
443         * platform/graphics/ca/win/CACFLayerTreeHost.cpp:
444         (WebCore::CACFLayerTreeHost::render): Moved code to notify the layers from here to
445         notifyAnimationsStarted.
446         (WebCore::CACFLayerTreeHost::flushPendingLayerChangesNow): Added a call to
447         notifyAnimationsStarted after we flush the context.
448         (WebCore::CACFLayerTreeHost::notifyAnimationsStarted): Added. Code came from render. Changed
449         to call PlatformCALayer::animationStarted rather than calling through to the client
450         directly.
451
452         * platform/graphics/ca/win/CACFLayerTreeHost.h: Added notifyAniamtionsStarted.
453
454 2011-01-26  Adam Roben  <aroben@apple.com>
455
456         Small cleanup in MediaPlayerPrivateFullscreenWindow
457
458         Reviewed by Sam Weinig.
459
460         * platform/graphics/win/MediaPlayerPrivateFullscreenWindow.cpp:
461         (WebCore::MediaPlayerPrivateFullscreenWindow::~MediaPlayerPrivateFullscreenWindow): Moved
462         code here from close(), since this was the only place that called it after the following
463         change to createWindow.
464         (WebCore::MediaPlayerPrivateFullscreenWindow::createWindow): Replaced code that handled the
465         case where we had already created the window with an assertion that we have not already done
466         so. Our single caller (FullscreenVideoController) did not require this behavior.
467
468         * platform/graphics/win/MediaPlayerPrivateFullscreenWindow.h: Removed layerView.
469
470 2011-01-26  Sam Weinig  <sam@webkit.org>
471
472         Reviewed by Adam Roben.
473
474         Move ScrollView scroll wheel code to ScrollAnimator.
475
476         * platform/ScrollAnimator.cpp:
477         (WebCore::ScrollAnimator::handleWheelEvent):
478         * platform/ScrollAnimator.h:
479         Moved implementation of handleWheelEvent from ScrollView::wheelEvent.
480
481         * platform/ScrollView.cpp:
482         (WebCore::ScrollView::wheelEvent):
483         Call down to the ScrollableArea.
484
485         * platform/ScrollableArea.cpp:
486         (WebCore::ScrollableArea::handleWheelEvent):
487         Call down to the ScrollAnimator.
488
489         * platform/ScrollableArea.h:
490         (WebCore::ScrollableArea::scrollPosition):
491         (WebCore::ScrollableArea::minimumScrollPosition):
492         (WebCore::ScrollableArea::maximumScrollPosition):
493         (WebCore::ScrollableArea::visibleContentRect):
494         (WebCore::ScrollableArea::visibleHeight):
495         (WebCore::ScrollableArea::visibleWidth):
496         Add functions needed to implement wheel event in the animator.
497
498 2011-01-26  David Kilzer  <ddkilzer@apple.com>
499
500         <http://webkit.org/b/53192> Add experimental support for HTTP pipelining in CFNetwork
501         <rdar://problem/8821760>
502
503         Reviewed by Antti Koivisto.
504
505         This adds support for HTTP pipelining in CFNetwork, but does not
506         enable it.  To enable it post-SnowLeopard, use this command:
507
508             defaults write BUNDLE.ID WebKitEnableHTTPPipelining -bool YES
509
510         Once enabled, it is possible to force the same load priority
511         (high) to be sent to CFNetwork to allow WebCore to handle the
512         scheduling:
513
514             defaults write BUNDLE.ID WebKitForceHTTPPipeliningPriorityHigh -bool YES
515
516         * WebCore.exp.in: Export _wkGetHTTPPipeliningPriority and
517         _wkSetHTTPPipeliningPriority.
518
519         * loader/DocumentThreadableLoader.cpp:
520         (WebCore::DocumentThreadableLoader::makeCrossOriginAccessRequestWithPreflight):
521         Copy the priority to preflightRequest.
522
523         * loader/ResourceLoadScheduler.cpp:
524         (WebCore::ResourceLoadScheduler::scheduleLoad): Refactored code
525         at the end of the method to use an early return.
526
527         * loader/cache/CachedResourceRequest.cpp:
528         (WebCore::CachedResourceRequest::load): Set the priority on the
529         ResourceRequest object based on the priority of the
530         CachedResourceRequest before calling
531         ResourceLoadScheduler::scheduleSubresourceLoad().
532
533         * loader/icon/IconLoader.cpp:
534         (WebCore::IconLoader::startLoading): Create a ResourceRequest
535         object and set its priority to ResourceLoadPriorityLow before
536         passing it to ResourceLoadScheduler::scheduleSubresourceLoad().
537
538         * platform/mac/WebCoreSystemInterface.h:
539         (wkGetHTTPPipeliningPriority): Added.
540         (wkSetHTTPPipeliningPriority): Added.
541         * platform/mac/WebCoreSystemInterface.mm:
542         (wkGetHTTPPipeliningPriority): Added.
543         (wkSetHTTPPipeliningPriority): Added.
544
545         * platform/network/ResourceRequestBase.cpp:
546         (WebCore::ResourceRequestBase::adopt): Set m_priority when
547         adopting a CrossThreadResourceRequestData.
548         (WebCore::ResourceRequestBase::copyData): Set m_priority when
549         creating a CrossThreadResourceRequestData.
550         (WebCore::ResourceRequestBase::priority): Added.
551         (WebCore::ResourceRequestBase::setPriority): Added.
552         (WebCore::equalIgnoringHeaderFields): Priorities must match when
553         comparing two ResourceRequest objects.
554
555         * platform/network/ResourceRequestBase.h:
556         (WebCore::ResourceRequestBase::ResourceRequestBase): Set default
557         priority of new objects to ResourceLoadPriorityLow.
558         (WebCore::ResourceRequestBase::priority): Added declaration.
559         (WebCore::ResourceRequestBase::setPriority): Added declaration.
560         (WebCore::isHTTPPipeliningEnabled): Added.
561         (WebCore::shouldUseHTTPPipeliningPriority): Added.
562
563         * platform/network/cf/ResourceRequestCFNet.cpp: Updated so that
564         Mac OS X and Windows share code.
565         (WebCore::initializeMaximumHTTPConnectionCountPerHost): Always
566         set the HTTP connection count per host, but return an
567         'unlimited' value when using HTTP pipelining.  This method used
568         to be defined in ResourceRequestMac.mm for Mac OS X.
569         (WebCore::readBooleanPreference): Added.  Helper method for
570         reading boolean user defaults.
571         (WebCore::isHTTPPipeliningEnabled): Returns value of user
572         default key WebKitEnableHTTPPipelining, or false if not set.
573         (WebCore::shouldUseHTTPPipeliningPriority): Returns value of
574         user default key WebKitForceHTTPPipeliningPriorityHigh, or false
575         if not set.
576         * platform/network/cf/ResourceRequestCFNet.h: Updated so that
577         Mac OS X and Windows share code.  Fixed indentation.
578         (WebCore::mapHTTPPipeliningPriorityToResourceLoadPriority): Added.
579         (WebCore::mapResourceLoadPriorityToHTTPPipeliningPriority): Added.
580
581         * platform/network/mac/ResourceRequestMac.mm:
582         (WebCore::ResourceRequest::doUpdatePlatformRequest): Update
583         HTTP pipelining priority on NSMutableFURLRequest object.
584         (WebCore::ResourceRequest::doUpdateResourceRequest): Update
585         m_priority from the NSURLRequest object.
586         (WebCore::initializeMaximumHTTPConnectionCountPerHost): Removed.
587         Code is now shared with Windows in ResourceRequestCFNet.cpp.
588
589 2011-01-26  Beth Dakin  <bdakin@apple.com>
590
591         Reviewed by Darin Adler.
592
593         Fix for <rdar://problem/8895140> Adopt WKScrollbar metrics 
594         when using WKScrollbars.
595
596         New WebKitSystemInterface Functionality.
597         * WebCore.exp.in:
598         * platform/mac/WebCoreSystemInterface.h:
599         * platform/mac/WebCoreSystemInterface.mm:
600
601         Some of the terrible static arrays are now only needed in the 
602         old non-WK code, so they are if-def'd now.
603         * platform/mac/ScrollbarThemeMac.mm:
604         
605         Just patching this function in a better way than I did
606         before.
607         (WebCore::updateArrowPlacement):
608         
609         Call into WK for the right values.
610         (WebCore::ScrollbarThemeMac::scrollbarThickness):
611         (WebCore::ScrollbarThemeMac::hasThumb):
612         (WebCore::ScrollbarThemeMac::minimumThumbLength):
613         
614         Return false if there are no buttons.
615         (WebCore::ScrollbarThemeMac::hasButtons):
616
617         Return an empty IntRect if there are not buttons.
618         (WebCore::buttonRepaintRect):
619
620 2011-01-26  Sam Weinig  <sam@webkit.org>
621
622         Reviewed by Maciej Stachowiak.
623
624         Add events to represent the start/end of a gesture scroll
625         https://bugs.webkit.org/show_bug.cgi?id=53215
626
627         * WebCore.exp.in: 
628         Add new file.
629
630         * WebCore.xcodeproj/project.pbxproj:
631         Add new file.
632
633         * page/EventHandler.cpp:
634         (WebCore::EventHandler::handleGestureEvent):
635         * page/EventHandler.h:
636         Add entry point for handling gesture events.
637
638         * platform/PlatformGestureEvent.h: Added.
639         (WebCore::PlatformGestureEvent::PlatformGestureEvent):
640         (WebCore::PlatformGestureEvent::type):
641         (WebCore::PlatformGestureEvent::position):
642         (WebCore::PlatformGestureEvent::globalPosition):
643         (WebCore::PlatformGestureEvent::timestamp):
644         Add platform agnostic representation of a gesture event.
645
646 2011-01-26  Dan Bernstein  <mitz@apple.com>
647
648         Reviewed by Dave Hyatt.
649
650         <rdar://problem/8446709> Allow inter-ideograph justification for CJK
651         https://bugs.webkit.org/show_bug.cgi?id=53184
652
653         Tests: fast/text/justify-ideograph-complex.html
654                fast/text/justify-ideograph-simple.html
655                fast/text/justify-ideograph-vertical.html
656
657         * html/canvas/CanvasRenderingContext2D.cpp:
658         (WebCore::CanvasRenderingContext2D::drawTextInternal): Corrected the type of the third parameter
659         passed to the TextRun constructor and added the trailingExpansionBehavior parameter.
660         * platform/graphics/Font.cpp:
661         (WebCore::Font::expansionOpportunityCount): Added. Returns the number of expansion opportunities
662         for text justification. On entry, isAfterExpansion says whether an expansion opportunity exists
663         before the first character. On return, isAfterExpansion says whether an expansion opportunity
664         exists after the last character.
665         * platform/graphics/Font.h: 
666         * platform/graphics/GlyphBuffer.h:
667         (WebCore::GlyphBuffer::expandLastAdvance): Added.
668         * platform/graphics/TextRun.h:
669         (WebCore::TextRun::TextRun): Added a TrailingExpansionBehavior parameter to the constructors.
670         Renamed padding to expansion.
671         (WebCore::TextRun::expansion): Renamed padding() to this.
672         (WebCore::TextRun::allowsTrailingExpansion): Added this accessor.
673         * platform/graphics/WidthIterator.cpp:
674         (WebCore::WidthIterator::WidthIterator): Initialize m_isAfterExpansion. Use Font::expansionOpportunityCount()
675         and adjust the count if it includes a trailing expansion opportunity but the run disallows trailing
676         expansion.
677         (WebCore::WidthIterator::advance): Apply expansion before and after CJK ideographs.
678         (WebCore::WidthIterator::advanceOneCharacter): Changed to not clear the GlyphBuffer so that advance()
679         can expand the last advance if it is followed by a CJK ideograph.
680         * platform/graphics/WidthIterator.h: Renamed m_padding to m_expansion and m_padPerSpace
681         to m_expansionPerOpportunity.
682         * platform/graphics/chromium/FontChromiumWin.cpp:
683         (WebCore::Font::canExpandAroundIdeographsInComplexText): Added.
684         * platform/graphics/chromium/FontLinux.cpp:
685         (WebCore::Font::canExpandAroundIdeographsInComplexText): Added.
686         * platform/graphics/efl/FontEfl.cpp:
687         (WebCore::Font::canExpandAroundIdeographsInComplexText): Added.
688         * platform/graphics/gtk/FontGtk.cpp:
689         (WebCore::Font::canExpandAroundIdeographsInComplexText): Added.
690         * platform/graphics/haiku/FontHaiku.cpp:
691         (WebCore::Font::canExpandAroundIdeographsInComplexText): Added.
692         * platform/graphics/mac/ComplexTextController.cpp:
693         (WebCore::ComplexTextController::ComplexTextController): Initialize m_isAfterExpansion. Use
694         Font::expansionOpportunityCount() and adjust the count if it includes a trailing expansion
695         opportunity but the run disallows trailing expansion.
696         (WebCore::ComplexTextController::adjustGlyphsAndAdvances): Moved the definition and initialization
697         of hasExtraSpacing outside the loop. Apply expansion before and after CJK ideographs.
698         * platform/graphics/mac/ComplexTextController.h: Renamed m_padding to m_expansion and m_padPerSpace
699         to m_expansionPerOpportunity.
700         * platform/graphics/mac/FontMac.mm:
701         (WebCore::Font::canExpandAroundIdeographsInComplexText): Added.
702         * platform/graphics/qt/FontQt.cpp:
703         (WebCore::Font::canExpandAroundIdeographsInComplexText): Added.
704         * platform/graphics/win/FontWin.cpp:
705         (WebCore::Font::canExpandAroundIdeographsInComplexText): Added.
706         * platform/graphics/win/UniscribeController.cpp:
707         (WebCore::UniscribeController::UniscribeController): Updated for rename.
708         * platform/graphics/wince/FontWinCE.cpp:
709         (WebCore::Font::canExpandAroundIdeographsInComplexText): Added.
710         * platform/graphics/wx/FontWx.cpp:
711         (WebCore::Font::canExpandAroundIdeographsInComplexText): Added.
712         * rendering/EllipsisBox.cpp:
713         (WebCore::EllipsisBox::paint): Pass a TrailingExpansionBehavior to the TextRun constructor.
714         (WebCore::EllipsisBox::selectionRect): Ditto.
715         (WebCore::EllipsisBox::paintSelection): Ditto.
716         * rendering/InlineBox.h:
717         (WebCore::InlineBox::InlineBox): Renamed m_toAdd to m_expansion.
718         (WebCore::InlineBox::expansion): Renamed toAdd() to this.
719         * rendering/InlineTextBox.cpp:
720         (WebCore::InlineTextBox::selectionRect): Pass a TrailingExpansionBehavior to the TextRun constructor.
721         (WebCore::InlineTextBox::paint): Ditto.
722         (WebCore::InlineTextBox::paintSelection): Ditto.
723         (WebCore::InlineTextBox::paintCompositionBackground): Ditto.
724         (WebCore::InlineTextBox::paintSpellingOrGrammarMarker): Ditto.
725         (WebCore::InlineTextBox::paintTextMatchMarker): Ditto.
726         (WebCore::InlineTextBox::computeRectForReplacementMarker): Ditto.
727         (WebCore::InlineTextBox::offsetForPosition): Ditto.
728         (WebCore::InlineTextBox::positionForOffset): Ditto.
729         * rendering/InlineTextBox.h:
730         (WebCore::InlineTextBox::setExpansion): Renamed setSpaceAdd() to this.
731         (WebCore::InlineTextBox::trailingExpansionBehavior): Added. Trailing expansion is allowed if this
732         is not the last leaf box on the line.
733         * rendering/RenderBlockLineLayout.cpp:
734         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine): Keep expansion opportunity counts
735         in a vector instead of computing them twice. Discard the trailing expansion opportunity in the
736         last text box.
737         * rendering/RenderFileUploadControl.cpp:
738         (WebCore::RenderFileUploadControl::paintObject): Pass a TrailingExpansionBehavior to the TextRun constructor.
739         (WebCore::RenderFileUploadControl::computePreferredLogicalWidths): Ditto.
740         * rendering/RenderListBox.cpp:
741         (WebCore::RenderListBox::updateFromElement): Ditto.
742         (WebCore::RenderListBox::paintItemForeground): Ditto. Also corrected the type of the second parameter.
743         * rendering/RenderTextControl.cpp:
744         (WebCore::RenderTextControl::getAvgCharWidth): Ditto.
745         (WebCore::RenderTextControl::paintPlaceholder): Ditto.
746         * rendering/svg/SVGInlineTextBox.cpp:
747         (WebCore::SVGInlineTextBox::constructTextRun): Ditto.
748
749 2011-01-26  Andy Estes  <aestes@apple.com>
750
751         Rubber-stamped by Darin Adler.
752
753         Inline HTMLObjectElement::hasValidClassId().
754
755         * html/HTMLObjectElement.cpp:
756         (WebCore::HTMLObjectElement::hasValidClassId):
757
758 2011-01-26  Evan Martin  <evan@chromium.org>
759
760         Reviewed by Tony Chang.
761
762         [chromium] crash on getBoundingClientRect in complex text
763         https://bugs.webkit.org/show_bug.cgi?id=53199
764
765         Use the correct array bound; we want the number of characters processed by
766         the shaper, not the longest continuous script run length.
767
768         Test: platform/chromium-linux/fast/text/international/complex-text-rectangle.html
769
770         * platform/graphics/chromium/ComplexTextControllerLinux.cpp:
771         (WebCore::ComplexTextController::nextScriptRun):
772         * platform/graphics/chromium/ComplexTextControllerLinux.h:
773         (WebCore::ComplexTextController::numCodePoints):
774
775 2011-01-26  Emil A Eklund  <eae@chromium.org>
776
777         Reviewed by Alexey Proskuryakov.
778
779         Remove cached document reference from CSSStyleSheet and XSLStyleSheet.
780         https://bugs.webkit.org/show_bug.cgi?id=52084
781
782         Test: fast/dom/css-delete-doc.html
783
784         * css/CSSMediaRule.cpp:
785         (WebCore::CSSMediaRule::insertRule):
786         (WebCore::CSSMediaRule::deleteRule):
787         * css/CSSStyleSheet.cpp:
788         (WebCore::CSSStyleSheet::CSSStyleSheet):
789         (WebCore::CSSStyleSheet::document):
790         * css/CSSStyleSheet.h:
791         * xml/XSLStyleSheet.h:
792         (WebCore::XSLStyleSheet::parentStyleSheet):
793         * xml/XSLStyleSheetLibxslt.cpp:
794         (WebCore::XSLStyleSheet::XSLStyleSheet):
795         (WebCore::XSLStyleSheet::cachedResourceLoader):
796         (WebCore::XSLStyleSheet::setParentStyleSheet):
797         (WebCore::XSLStyleSheet::ownerDocument):
798         * xml/XSLStyleSheetQt.cpp:
799         (WebCore::XSLStyleSheet::XSLStyleSheet):
800         (WebCore::XSLStyleSheet::cachedResourceLoader):
801         (WebCore::XSLStyleSheet::ownerDocument):
802
803 2011-01-25  Dimitri Glazkov  <dglazkov@chromium.org>
804
805         Reviewed by Kent Tamura.
806
807         Reduce ref-count churn in shadowPseudoId.
808         https://bugs.webkit.org/show_bug.cgi?id=53136
809
810         Refactoring, so no new tests.
811
812         * dom/Element.h:
813         (WebCore::Element::shadowPseudoId): Changed signature to use const AtomicString&
814         * html/ValidationMessage.cpp:
815         (WebCore::ElementWithPseudoId::shadowPseudoId): Ditto.
816         * html/shadow/SliderThumbElement.cpp:
817         (WebCore::SliderThumbElement::shadowPseudoId): Ditto, plus moved from the header file.
818         * html/shadow/SliderThumbElement.h: Ditto.
819         * rendering/MediaControlElements.cpp:
820         (WebCore::MediaControlMuteButtonElement::shadowPseudoId): Ditto.
821         (WebCore::MediaControlVolumeSliderMuteButtonElement::shadowPseudoId): Ditto.
822         (WebCore::MediaControlPlayButtonElement::shadowPseudoId): Ditto.
823         (WebCore::MediaControlSeekForwardButtonElement::shadowPseudoId): Ditto.
824         (WebCore::MediaControlSeekBackButtonElement::shadowPseudoId): Ditto.
825         (WebCore::MediaControlRewindButtonElement::shadowPseudoId): Ditto.
826         (WebCore::MediaControlReturnToRealtimeButtonElement::shadowPseudoId): Ditto.
827         (WebCore::MediaControlToggleClosedCaptionsButtonElement::shadowPseudoId): Ditto.
828         (WebCore::MediaControlTimelineElement::shadowPseudoId): Ditto.
829         (WebCore::MediaControlVolumeSliderElement::shadowPseudoId): Ditto.
830         (WebCore::MediaControlFullscreenButtonElement::shadowPseudoId): Ditto.
831         * rendering/MediaControlElements.h: Ditto.
832
833 2011-01-26  Dave Hyatt  <hyatt@apple.com>
834
835         Reviewed by Dan Bernstein.
836
837         https://bugs.webkit.org/show_bug.cgi?id=46421, make multi-column layout work with vertical text.
838
839         Added new tests in fast/multicol/vertical-lr and fast/multicol/vertical-rl.
840
841         * css/html.css:
842         Update p, blockquote and h1-h6 to respect directionality so that column layout tests that use those
843         elements work properly.
844
845         * rendering/InlineFlowBox.cpp:
846         (WebCore::InlineFlowBox::placeBoxesInBlockDirection):
847         Fix a flipping bug with the computation of lineTopIncludingMargins where it could be incorrectly shrunk
848         in some cases (causing lines to all stack on top of one another).
849
850         * rendering/InlineTextBox.h:
851         (WebCore::InlineTextBox::calculateBoundaries):
852         Fix calculateBoundaries to be physical rather than logical.
853
854         * rendering/LayoutState.cpp:
855         (WebCore::LayoutState::addForcedColumnBreak):
856         * rendering/LayoutState.h:
857         Rename childY to childLogicalOffset.
858
859         * rendering/RenderBlock.cpp:
860         (WebCore::RenderBlock::layoutBlock):
861         (WebCore::RenderBlock::addOverflowFromChildren):
862         (WebCore::RenderBlock::addOverflowFromFloats):
863         (WebCore::RenderBlock::collapseMargins):
864         (WebCore::RenderBlock::estimateLogicalTopPosition):
865         (WebCore::RenderBlock::layoutBlockChild):
866         (WebCore::RenderBlock::markForPaginationRelayoutIfNeeded):
867         (WebCore::RenderBlock::paintColumnRules):
868         (WebCore::RenderBlock::paintColumnContents):
869         (WebCore::RenderBlock::paintFloats):
870         (WebCore::RenderBlock::selectionGaps):
871         (WebCore::RenderBlock::removeFloatingObjectsBelow):
872         (WebCore::RenderBlock::addOverhangingFloats):
873         (WebCore::RenderBlock::hitTestFloats):
874         (WebCore::RenderBlock::hitTestColumns):
875         (WebCore::RenderBlock::calcColumnWidth):
876         (WebCore::RenderBlock::desiredColumnWidth):
877         (WebCore::RenderBlock::columnRectAt):
878         (WebCore::RenderBlock::layoutColumns):
879         (WebCore::RenderBlock::adjustPointToColumnContents):
880         (WebCore::RenderBlock::adjustRectForColumns):
881         (WebCore::RenderBlock::flipForWritingModeIncludingColumns):
882         (WebCore::RenderBlock::adjustForColumns):
883         (WebCore::RenderBlock::adjustForBorderFit):
884         (WebCore::RenderBlock::nextPageLogicalTop):
885         (WebCore::RenderBlock::applyBeforeBreak):
886         (WebCore::RenderBlock::applyAfterBreak):
887         (WebCore::RenderBlock::adjustForUnsplittableChild):
888         (WebCore::RenderBlock::adjustLinePositionForPagination):
889         * rendering/RenderBlock.h:
890         (WebCore::RenderBlock::logicalRightOffsetForContent):
891         (WebCore::RenderBlock::logicalLeftOffsetForContent):
892         (WebCore::RenderBlock::leftForFloatIncludingMargin):
893         (WebCore::RenderBlock::topForFloatIncludingMargin):
894         * rendering/RenderBlockLineLayout.cpp:
895         (WebCore::RenderBlock::layoutInlineChildren):
896         (WebCore::RenderBlock::determineStartPosition):
897         Reworking of all the RenderBlock column functions to support flipping and vertical modes.
898
899         * rendering/RenderBox.cpp:
900         (WebCore::RenderBox::offsetFromContainer):
901         (WebCore::RenderBox::flipForWritingModeIncludingColumns):
902         Patch offsetFromContainer to be aware of flipped block writing modes when dealing with column layouts.
903
904         * rendering/RenderBox.h:
905         (WebCore::RenderBox::clientLogicalBottom):
906         Fix a bug in clientLogicalBottom where it didn't add in the right border/padding.
907         
908         * rendering/RenderFlexibleBox.cpp:
909         (WebCore::RenderFlexibleBox::layoutBlock):
910         Better terminology for pagination.
911
912         * rendering/RenderInline.cpp:
913         (WebCore::RenderInline::offsetFromContainer):
914         (WebCore::RenderInline::mapLocalToContainer):
915         * rendering/RenderLayer.cpp:
916         (WebCore::RenderLayer::paintChildLayerIntoColumns):
917         (WebCore::RenderLayer::hitTestChildLayerColumns):
918         (WebCore::RenderLayer::localBoundingBox):
919         (WebCore::RenderLayer::boundingBox):
920         Patch painting in RenderLayers to be vertical-text-aware.
921     
922         * rendering/RenderObject.cpp:
923         (WebCore::RenderObject::mapLocalToContainer):
924         Add code to be flipped block-aware with columns.
925
926         * rendering/RenderTable.cpp:
927         (WebCore::RenderTable::layout):
928         * rendering/RenderTableRow.cpp:
929         (WebCore::RenderTableRow::layout):
930         * rendering/RenderTableSection.cpp:
931         (WebCore::RenderTableSection::layoutRows):
932         Fix pagination to use better terminology.
933         
934         * rendering/RenderText.cpp:
935         (WebCore::RenderText::absoluteQuads):
936         (WebCore::RenderText::absoluteQuadsForRange):
937         Fix a bug where vertical text wasn't taken into account.
938
939 2011-01-26  Dimitri Glazkov  <dglazkov@chromium.org>
940
941         Unreviewed, rolling out r76719.
942         http://trac.webkit.org/changeset/76719
943         https://bugs.webkit.org/show_bug.cgi?id=53122
944
945         Broke a bunch of media tests in Chromium/Qt/GTK.
946
947 2011-01-26  Tony Chang  <tony@chromium.org>
948
949         Reviewed by Ryosuke Niwa.
950
951         [gtk] strip NUL characters when copying text/html on GTK+
952         https://bugs.webkit.org/show_bug.cgi?id=52508
953
954         Putting NUL characters in the text/html clipboard doesn't work in
955         WebKit GTK+ (the pasted value is truncated at the NUL).  Since we're
956         already stripping this character for plain text (for Windows), strip
957         it in text/html too.
958
959         * editing/MarkupAccumulator.h: mark function as virtual
960         * editing/markup.cpp:
961         (WebCore::StyledMarkupAccumulator::appendString):
962         (WebCore::StyledMarkupAccumulator::takeResults): strip nulls
963
964 2011-01-26  Mario Sanchez Prada  <msanchez@igalia.com>
965
966         Reviewed by Martin Robinson.
967
968         [GTK] Reliable crash with getTextAtOffset()
969         https://bugs.webkit.org/show_bug.cgi?id=53131
970
971         Properly calculate length in bytes for a UTF8 substring.
972
973         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
974         (utf8Substr): Use character instead of bytes as units to
975         calculate the length in bytes for the UTF8 string.
976
977 2011-01-25  Dimitri Glazkov  <dglazkov@chromium.org>
978
979         Reviewed by Kent Tamura.
980
981         Change HTMLInputElement-derived parts of media element shadow DOM to use shadowPseudoId.
982         https://bugs.webkit.org/show_bug.cgi?id=53122
983
984         This is the first step in converting HTMLMediaElement to the new shadow DOM.
985
986         Should not regress any existing tests. No observable change in behavior.
987
988         * css/CSSSelector.cpp:
989         (WebCore::CSSSelector::pseudoId): Removed now-unnecessary hard-coded pseudo-element selectors.
990         (WebCore::nameToPseudoTypeMap): Ditto.
991         (WebCore::CSSSelector::extractPseudoType): Ditto.
992         * css/CSSSelector.h: Ditto.
993         * css/mediaControls.css: Added proper initial values, now that elements use the proper selector pipeline.
994         * rendering/MediaControlElements.cpp:
995         (WebCore::MediaControlInputElement::MediaControlInputElement): Removed the switch statement,
996             which is now replaced with virtual shadowPseudoId on each corresponding class.
997         (WebCore::MediaControlInputElement::styleForElement): Changed to use element pipeline.
998         (WebCore::MediaControlMuteButtonElement::MediaControlMuteButtonElement): Changed to set
999             display type in constructor.
1000         (WebCore::MediaControlMuteButtonElement::create): Changed to not take PseudoId as
1001             constructor argument.
1002         (WebCore::MediaControlMuteButtonElement::shadowPseudoId): Added.
1003         (WebCore::MediaControlVolumeSliderMuteButtonElement::MediaControlVolumeSliderMuteButtonElement): Added
1004             to disambiguate from the MediaControlMuteButtonElement.
1005         (WebCore::MediaControlVolumeSliderMuteButtonElement::create): Added.
1006         (WebCore::MediaControlVolumeSliderMuteButtonElement::shadowPseudoId): Added.
1007         (WebCore::MediaControlPlayButtonElement::MediaControlPlayButtonElement): Changed to not take PseudoId as
1008             constructor argument.
1009         (WebCore::MediaControlPlayButtonElement::shadowPseudoId): Added.
1010         (WebCore::MediaControlSeekButtonElement::MediaControlSeekButtonElement): Changed to not take PseudoId as
1011             constructor argument.
1012         (WebCore::MediaControlSeekForwardButtonElement::MediaControlSeekForwardButtonElement): Added.
1013         (WebCore::MediaControlSeekForwardButtonElement::create): Added.
1014         (WebCore::MediaControlSeekForwardButtonElement::shadowPseudoId): Added.
1015         (WebCore::MediaControlSeekBackButtonElement::MediaControlSeekBackButtonElement): Added.
1016         (WebCore::MediaControlSeekBackButtonElement::create): Added.
1017         (WebCore::MediaControlSeekBackButtonElement::shadowPseudoId): Added.
1018         (WebCore::MediaControlRewindButtonElement::MediaControlRewindButtonElement): Added.
1019         (WebCore::MediaControlRewindButtonElement::shadowPseudoId): Added.
1020         (WebCore::MediaControlReturnToRealtimeButtonElement::MediaControlReturnToRealtimeButtonElement): Changed to not take PseudoId as
1021             constructor argument.
1022         (WebCore::MediaControlReturnToRealtimeButtonElement::shadowPseudoId): Added.
1023         (WebCore::MediaControlToggleClosedCaptionsButtonElement::MediaControlToggleClosedCaptionsButtonElement): Changed to not take PseudoId as
1024             constructor argument.
1025         (WebCore::MediaControlToggleClosedCaptionsButtonElement::shadowPseudoId): Added.
1026         (WebCore::MediaControlTimelineElement::MediaControlTimelineElement): Changed to not take PseudoId as
1027             constructor argument.
1028         (WebCore::MediaControlTimelineElement::shadowPseudoId): Added.
1029         (WebCore::MediaControlVolumeSliderElement::MediaControlVolumeSliderElement): Changed to not take PseudoId as
1030             constructor argument.
1031         (WebCore::MediaControlVolumeSliderElement::shadowPseudoId): Added.
1032         (WebCore::MediaControlFullscreenButtonElement::MediaControlFullscreenButtonElement): Changed to not take PseudoId as
1033             constructor argument.
1034         (WebCore::MediaControlFullscreenButtonElement::shadowPseudoId): Added.
1035         * rendering/MediaControlElements.h:
1036         (WebCore::MediaControlSeekForwardButtonElement::isForwardButton): Added.
1037         (WebCore::MediaControlSeekBackButtonElement::isForwardButton): Added.
1038         * rendering/RenderMedia.cpp:
1039         (WebCore::RenderMedia::createMuteButton): Changed to use new constructor.
1040         (WebCore::RenderMedia::createSeekBackButton): Ditto.
1041         (WebCore::RenderMedia::createSeekForwardButton): Ditto.
1042         (WebCore::RenderMedia::createVolumeSliderMuteButton): Ditto.
1043         * rendering/style/RenderStyleConstants.h: Removed constants that are no longer used.
1044
1045 2011-01-26  Kenneth Russell  <kbr@google.com>
1046
1047         Reviewed by James Robinson.
1048
1049         Fix multisampling support in DrawingBuffer
1050         https://bugs.webkit.org/show_bug.cgi?id=53154
1051
1052         In DrawingBuffer's multisampling code path, fixed enum usage and a
1053         bug where it would incorrectly redefine the depth and stencil
1054         buffers. Hooked up multisampling code path in Chromium port.
1055
1056         Tested manually with some accelerated 2D canvas content.
1057         Multisampling isn't being switched on for the accelerated 2D
1058         canvas at the current time because it will increase fill rate
1059         requirements and cause a large number of rebaselines.
1060
1061         * platform/graphics/Extensions3D.h:
1062         * platform/graphics/chromium/DrawingBufferChromium.cpp:
1063         (WebCore::DrawingBuffer::publishToPlatformLayer):
1064         * platform/graphics/chromium/Extensions3DChromium.h:
1065         * platform/graphics/gpu/DrawingBuffer.cpp:
1066         (WebCore::DrawingBuffer::create):
1067         (WebCore::DrawingBuffer::reset):
1068         * platform/graphics/opengl/Extensions3DOpenGL.cpp:
1069         (WebCore::Extensions3DOpenGL::supports):
1070
1071 2011-01-26  Tony Chang  <tony@chromium.org>
1072
1073         Unreviewed.
1074
1075         [chromium] revert r68310 because of race conditions detected by tsans
1076         https://bugs.webkit.org/show_bug.cgi?id=53185
1077
1078         Causes stability problems for Chromium, http://crbug.com/70589
1079
1080         * platform/sql/chromium/SQLiteFileSystemChromiumPosix.cpp:
1081         (WebCore::SQLiteFileSystem::registerSQLiteVFS):
1082
1083 2011-01-26  Justin Schuh  <jschuh@chromium.org>
1084
1085         Reviewed by Adam Barth.
1086
1087         Make fireEventsAndUpdateStyle use stack local vectors. 
1088         https://bugs.webkit.org/show_bug.cgi?id=46760
1089
1090         Test: animations/animation-add-events-in-handler.html
1091
1092         * page/animation/AnimationController.cpp:
1093         (WebCore::AnimationControllerPrivate::fireEventsAndUpdateStyle):
1094
1095 2011-01-26  Nate Chapin  <japhet@chromium.org>
1096
1097         Reviewed by Adam Barth.
1098
1099         Remove m_URL from FrameLoader and depend on Document::url()
1100         instead. FrameLoader::url() will be removed in a followup patch.
1101         https://bugs.webkit.org/show_bug.cgi?id=41165
1102
1103         Refactor only, no new tests.
1104
1105         * WebCore.exp.in:
1106         * dom/Document.cpp:
1107         (WebCore::Document::Document):
1108         (WebCore::Document::updateURLForPushOrReplaceState):
1109         * loader/DocumentWriter.cpp:
1110         (WebCore::DocumentWriter::begin):
1111         * loader/FrameLoader.cpp:
1112         (WebCore::FrameLoader::iconURL):
1113         (WebCore::FrameLoader::didOpenURL):
1114         (WebCore::FrameLoader::didExplicitOpen):
1115         (WebCore::FrameLoader::receivedFirstData):
1116         (WebCore::FrameLoader::url):
1117         (WebCore::FrameLoader::setOutgoingReferrer):
1118         (WebCore::FrameLoader::startIconLoader):
1119         (WebCore::FrameLoader::commitIconURLToIconDatabase):
1120         (WebCore::FrameLoader::finishedParsing):
1121         (WebCore::FrameLoader::checkIfDisplayInsecureContent):
1122         (WebCore::FrameLoader::checkIfRunInsecureContent):
1123         (WebCore::FrameLoader::updateFirstPartyForCookies):
1124         (WebCore::FrameLoader::loadInSameDocument):
1125         (WebCore::FrameLoader::commitProvisionalLoad):
1126         (WebCore::FrameLoader::open):
1127         (WebCore::FrameLoader::shouldScrollToAnchor):
1128         * loader/FrameLoader.h: Rename setURL() to setOutgoingReferrer().
1129
1130 2011-01-25  Brian Weinstein  <bweinstein@apple.com>
1131
1132         Reviewed by Antti Koivisto.
1133
1134         Crashes loading pages when cancelling subresource loads through WebKit
1135         https://bugs.webkit.org/show_bug.cgi?id=53123
1136         <rdar://problem/8914361>
1137         
1138         Fix a crash that happened when cancelling subresource loads through WebKit.
1139         
1140         When a load is cancelled synchronously (via the WebKit client), CachedResourceLoader::requestResource 
1141         can be called recursively on the same function, either leading to infinite recursion, or deleting 
1142         an object when it is not done being used.
1143         
1144         The fix for this was to call checkForPendingPreloads and servePendingRequests asynchronously when 
1145         CachedResourceLoader::loadDone was called synchronously (due to the load being cancelled synchronously).
1146
1147         Test: fast/loader/willSendRequest-null-for-preload.html
1148
1149         * loader/DocumentLoader.cpp:
1150         (WebCore::DocumentLoader::setRequest): Only dispatch didReceiveServerRedirectForProvisionalLoadForFrame 
1151             if our new URL is non-null.
1152         * loader/cache/CachedResourceLoader.cpp:
1153         (WebCore::CachedResourceLoader::CachedResourceLoader): Initialize our timer.
1154         (WebCore::CachedResourceLoader::loadDone): If the CachedResource we were passed in was 0, that means this 
1155             function was called synchronously
1156             from CachedResourceRequest::load, and we don't want to call into checkForPendingPreloads synchronously, 
1157             so put it on a 0-delay timer to make the calls to checkForPendingPreloads and servePendingRequests asynchronous.
1158         (WebCore::CachedResourceLoader::loadDonePendingActionTimerFired): Call checkForPendingPreloads and servePendingRequests.
1159         (WebCore::CachedResourceLoader::checkForPendingPreloads): m_pendingPreloads is now a Deque instead of a Vector, 
1160             so use Deque methods.
1161         * loader/cache/CachedResourceLoader.h: Add the timer, the timer callback function, and make m_pendingPreloads a Deque.
1162
1163 2011-01-25  Pavel Podivilov  <podivilov@chromium.org>
1164
1165         Reviewed by Pavel Feldman.
1166
1167         Web Inspector: evaluate in console may not work when window.console is substituted or deleted.
1168         https://bugs.webkit.org/show_bug.cgi?id=53072
1169
1170         Test: inspector/console-substituted.html
1171
1172         * inspector/InjectedScriptSource.js:
1173         (.):
1174
1175 2011-01-26  Carlos Garcia Campos  <cgarcia@igalia.com>
1176
1177         Reviewed by Martin Robinson.
1178
1179         [cairo] Use CAIRO_OPERATOR_DARKEN when available
1180         https://bugs.webkit.org/show_bug.cgi?id=53084
1181
1182         Use CAIRO_OPERATOR_DARKEN for CompositePlusDarker instead of
1183         CAIRO_OPERATOR_SATURATE when building with cairo version >= 1.10.
1184
1185         * platform/graphics/cairo/CairoUtilities.cpp:
1186         (WebCore::toCairoOperator):
1187
1188 2011-01-26  Pavel Feldman  <pfeldman@chromium.org>
1189
1190         Reviewed by Yury Semikhatsky.
1191
1192         Web Inspector: visualize \n in strings as unicode cr
1193         symbol in stack variables sidebar.
1194         https://bugs.webkit.org/show_bug.cgi?id=53162
1195
1196         * inspector/front-end/ObjectPropertiesSection.js:
1197         (WebInspector.ObjectPropertyTreeElement.prototype.update):
1198
1199 2011-01-26  Andrey Kosyakov  <caseq@chromium.org>
1200
1201         Reviewed by Pavel Feldman.
1202
1203         Web Inspector: size is wrong for cached resources in Network panel
1204         - Set the size for 304/not modified resources from cached resource.
1205         - Add response headers size to resource transfer size.
1206         https://bugs.webkit.org/show_bug.cgi?id=52886
1207
1208         * inspector/InspectorResourceAgent.cpp:
1209         (WebCore::InspectorResourceAgent::didReceiveResponse):
1210         * inspector/front-end/Resource.js:
1211         (WebInspector.Resource):
1212         (WebInspector.Resource.prototype.get transferSize):
1213         (WebInspector.Resource.prototype.set responseHeaders):
1214         (WebInspector.Resource.prototype._headersSize):
1215         (WebInspector.Resource.prototype._mimeTypeIsConsistentWithType):
1216
1217 2011-01-26  Carol Szabo  <carol.szabo@nokia.com>
1218
1219         Reviewed by Simon Hausmann.
1220
1221         Fixed TiledBacking store to take into account new dirty regions caused by
1222         paint time layouts.
1223
1224         Flawed rendering design for QtWebKit resulting in artifacts being displayed
1225         https://bugs.webkit.org/show_bug.cgi?id=49184
1226
1227         There are no new tests as this patch aims at fixing flicker that
1228         happen randomly, mostly on slow hardware, thus are hard to reproduce
1229         consistently in an automated test.
1230
1231         This patch does not fully address the said bug but it is a step in the
1232         right direction. A full solution to the bug, as currently perceived,
1233         requires either a Qt GUI API change, a performance hit for QtWebKit,
1234         or a hack, until a full solution is provided this patch is progress.
1235
1236         * platform/graphics/TiledBackingStore.cpp:
1237         (WebCore::TiledBackingStore::updateTileBuffers):
1238         Changed to take into account newly dirtied areas created during
1239         tile update initiated layouts during the same update.
1240
1241 2011-01-26  Patrick Gansterer  <paroga@webkit.org>
1242
1243         Reviewed by Andreas Kling.
1244
1245         [SKIA] Remove "current path" of GraphicsContext
1246         https://bugs.webkit.org/show_bug.cgi?id=53124
1247
1248         * platform/graphics/GraphicsContext.h:
1249         * platform/graphics/skia/GraphicsContextSkia.cpp:
1250         (WebCore::GraphicsContext::clipPath):
1251         (WebCore::GraphicsContext::fillPath):
1252         (WebCore::GraphicsContext::strokePath):
1253         * platform/graphics/skia/PathSkia.cpp:
1254         (WebCore::Path::strokeBoundingRect):
1255         * platform/graphics/skia/PlatformContextSkia.cpp:
1256         * platform/graphics/skia/PlatformContextSkia.h:
1257
1258 2011-01-26  Zalan Bujtas <zbujtas@gmail.com>
1259
1260         Reviewed by Andreas Kling.
1261
1262         [Qt] Path::normalAngleAtLength() returns incorrect value on ACID3.
1263
1264         QPainterPath returns angle values with the origo being at the top left corner,
1265         we need to account for this in normalAngleAtLength().
1266         This Regressed with r66979.
1267
1268         No new tests as this is already covered by ACID3.
1269
1270         * platform/graphics/qt/PathQt.cpp:
1271         (WebCore::Path::normalAngleAtLength):
1272
1273 2011-01-26  Pavel Feldman  <pfeldman@chromium.org>
1274
1275         Reviewed by Yury Semikhatsky.
1276
1277         Web Inspector: live edit does not update source snippet.
1278         https://bugs.webkit.org/show_bug.cgi?id=53097
1279
1280         * inspector/front-end/ScriptsPanel.js:
1281         (WebInspector.ScriptsPanel.prototype._scriptSourceChanged):
1282
1283 2011-01-26  Pavel Feldman  <pfeldman@chromium.org>
1284
1285         Reviewed by Yury Semikhatsky.
1286
1287         Web Inspector: Incorrect on-hover evaluation of a variable named 'profile'.
1288         https://bugs.webkit.org/show_bug.cgi?id=53018
1289
1290         * inspector/InjectedScript.cpp:
1291         (WebCore::InjectedScript::evaluate):
1292         (WebCore::InjectedScript::evaluateOnCallFrame):
1293         (WebCore::InjectedScript::getCompletions):
1294         (WebCore::InjectedScript::getCompletionsOnCallFrame):
1295         * inspector/InjectedScript.h:
1296         * inspector/InjectedScriptSource.js:
1297         (.):
1298         * inspector/Inspector.idl:
1299         * inspector/InspectorDebuggerAgent.cpp:
1300         (WebCore::InspectorDebuggerAgent::evaluateOnCallFrame):
1301         (WebCore::InspectorDebuggerAgent::getCompletionsOnCallFrame):
1302         * inspector/InspectorDebuggerAgent.h:
1303         * inspector/InspectorRuntimeAgent.cpp:
1304         (WebCore::InspectorRuntimeAgent::evaluate):
1305         (WebCore::InspectorRuntimeAgent::getCompletions):
1306         * inspector/InspectorRuntimeAgent.h:
1307         * inspector/front-end/ConsoleView.js:
1308         (WebInspector.ConsoleView.prototype.completions):
1309         (WebInspector.ConsoleView.prototype.evalInInspectedWindow):
1310         (WebInspector.ConsoleView.prototype._enterKeyPressed):
1311         * inspector/front-end/ScriptsPanel.js:
1312         (WebInspector.ScriptsPanel.prototype.evaluateInSelectedCallFrame.updatingCallbackWrapper):
1313         (WebInspector.ScriptsPanel.prototype.evaluateInSelectedCallFrame):
1314         * inspector/front-end/SourceFrame.js:
1315         (WebInspector.SourceFrame.prototype._showPopup):
1316         * inspector/front-end/WatchExpressionsSidebarPane.js:
1317         (WebInspector.WatchExpressionsSection.prototype.update):
1318
1319 2011-01-26  Hironori Bono  <hbono@chromium.org>
1320
1321         Reviewed by Kent Tamura.
1322
1323         A speculative fix for Bug 52422 - [chromium] More crash in
1324         FontFallbackList::determinePitch(const Font* font)
1325         https://bugs.webkit.org/show_bug.cgi?id=52422
1326
1327         My previous change may not work on non-US Windows whose system fonts
1328         have localized aliases matching to the system locale because of a
1329         font-name mismatch in createFontIndirectAndGetWinName(). This change
1330         tries all the fonts installed in a PC and returns the first font that we
1331         can create without errors.
1332
1333         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
1334         (WebCore::GetLastResortFallbackFontProcData::GetLastResortFallbackFontProcData):
1335         Added a struct used for getLastResortFallbackFontProc().
1336         (WebCore::getLastResortFallbackFontProc): Added a callback for EnumFontFamilies().
1337         (WebCore::FontCache::getLastResortFallbackFont): Use EnumFontFamilies() to find a last-resort font.
1338
1339 2011-01-26  James Robinson  <jamesr@chromium.org>
1340
1341         Reviewed by Nate Chapin.
1342
1343         Add a DOMTimeStamp parameter to the requestAnimationFrame callback
1344         https://bugs.webkit.org/show_bug.cgi?id=53142
1345
1346         This adds a DOMTimeStamp parameter to the requestAnimationFrame callback to more
1347         closely match mozilla's proposal.  This is useful if the page has multiple imperative animations
1348         and wants to ensure that they all remain synchronized.  If each callback used Date.now() to
1349         update its animation state, they would potentially be out of sync with each other.  If they use
1350         the timestamp then all callbacks for the same "frame" will update to the same state.
1351
1352         Test: fast/animation/request-animation-frame-timestamps.html
1353
1354         * bindings/scripts/CodeGeneratorV8.pm:
1355         * bindings/scripts/test/V8/V8TestCallback.cpp:
1356         (WebCore::V8TestCallback::callbackWithClass2Param):
1357         * dom/Document.cpp:
1358         (WebCore::Document::serviceScriptedAnimations):
1359         * dom/Document.h:
1360         * dom/RequestAnimationFrameCallback.h:
1361         * dom/RequestAnimationFrameCallback.idl:
1362         * page/FrameView.cpp:
1363         (WebCore::FrameView::serviceScriptedAnimations):
1364         * page/FrameView.h:
1365
1366 2011-01-25  Yuzo Fujishima  <yuzo@google.com>
1367
1368         Unreviewed attempt to fix compilation error for Chromium Clang.
1369
1370         * platform/graphics/mac/ComplexTextController.cpp:
1371         (WebCore::ComplexTextController::advance):
1372
1373 2011-01-25  Ned Holbrook  <nholbrook@apple.com>
1374
1375         Reviewed by Dan Bernstein.
1376
1377         ComplexTextController incorrectly conflates string length and range of indexes
1378         https://bugs.webkit.org/show_bug.cgi?id=52760
1379
1380         Test: fast/text/offsetForPosition-complex-fallback.html
1381
1382         * platform/graphics/mac/ComplexTextController.cpp:
1383         (WebCore::ComplexTextController::offsetForPosition):
1384         (WebCore::ComplexTextController::ComplexTextRun::ComplexTextRun):
1385         (WebCore::ComplexTextController::ComplexTextRun::setIsNonMonotonic):
1386         (WebCore::ComplexTextController::advance):
1387         * platform/graphics/mac/ComplexTextController.h:
1388         (WebCore::ComplexTextController::ComplexTextRun::create):
1389         (WebCore::ComplexTextController::ComplexTextRun::indexEnd):
1390         * platform/graphics/mac/ComplexTextControllerATSUI.cpp:
1391         (WebCore::ComplexTextController::ComplexTextRun::ComplexTextRun):
1392         * platform/graphics/mac/ComplexTextControllerCoreText.cpp:
1393         (WebCore::ComplexTextController::ComplexTextRun::ComplexTextRun):
1394         (WebCore::ComplexTextController::collectComplexTextRunsForCharactersCoreText):
1395
1396 2011-01-25  Sam Weinig  <sam@webkit.org>
1397
1398         Reviewed by David Hyatt.
1399
1400         Scrollbars don't work correctly for top-to-bottom text in an overflow: scroll area
1401         https://bugs.webkit.org/show_bug.cgi?id=53048
1402
1403         Test: fast/overflow/overflow-rtl-vertical-origin.html
1404
1405         * rendering/RenderLayer.cpp:
1406         (WebCore::RenderLayer::scrollPosition):
1407         (WebCore::RenderLayer::updateScrollInfoAfterLayout):
1408         Take the scroll origin into account when calculating scrollbars in more places.
1409
1410 2011-01-25  Steve Falkenburg  <sfalken@apple.com>
1411
1412         Windows production build fix.
1413         Use correct configuration-specific path in makefile.
1414
1415         * WebCore.vcproj/WebCore.make:
1416
1417 2011-01-25  Kent Tamura  <tkent@chromium.org>
1418
1419         Reviewed by Dimitri Glazkov.
1420
1421         Radio button group state is not restored correctly
1422         https://bugs.webkit.org/show_bug.cgi?id=50442
1423
1424         Fixes a bug that radio button states are not restored correctly in
1425         a case that non-first radio button in a group is checked.
1426
1427         If "checked" attribute is present, the radio button is checked and
1428         other radio buttons in the group are unchecked. This behavior
1429         disturbs form state restoring. This patch changes this behavior so
1430         that the "checked" attribute handling is delayed after form state
1431         restoring.
1432
1433         Test: fast/forms/state-restore-radio-group.html
1434
1435         * html/HTMLFormControlElement.h:
1436          Make finishParsingChildren() protected so that HTMLInpuElement can call it.
1437         * html/HTMLInputElement.cpp:
1438         (WebCore::HTMLInputElement::HTMLInputElement):
1439          - Add createdByParser parameter.
1440          - Initialize m_stateRestored and m_parsingInProgress.
1441         (WebCore::HTMLInputElement::create): Sync with the constructor.
1442         (WebCore::HTMLInputElement::restoreFormControlState):
1443          Set m_stateRestored in order to refer it in finishParsingChildren().
1444         (WebCore::HTMLInputElement::parseMappedAttribute):
1445          Don't call setChecked() during parsing. Move setNeedsValidityCheck()
1446          to setChecked().
1447         (WebCore::HTMLInputElement::finishParsingChildren):
1448          Call setChecked() if form state is not restored.
1449         (WebCore::HTMLInputElement::setChecked):
1450          Move setNeedsValidityCheck() from parseMappedAttribute() because
1451          finishParsingChildren() also needs to call setNeedsValidityCheck().
1452         * html/HTMLInputElement.h:
1453          - Remove the default value of HTMLFormElement* of the HTMLInputElement
1454            constructor, and add createdByParser parameter.
1455          - Introduce m_parsingInProgress and m_stateRestored.
1456         * html/HTMLIsIndexElement.cpp:
1457         (WebCore::HTMLIsIndexElement::HTMLIsIndexElement):
1458          Sync with the HTMLInputElement constructor change.
1459         * html/HTMLTagNames.in: Add constructorNeedsCreatedByParser flag.
1460         * rendering/MediaControlElements.cpp:
1461         (WebCore::MediaControlInputElement::MediaControlInputElement):
1462          Sync with the HTMLInputElement constructor change.
1463         * rendering/ShadowElement.cpp:
1464         (WebCore::ShadowInputElement::ShadowInputElement): ditto.
1465         * rendering/ShadowElement.h:
1466         (WebCore::ShadowElement::ShadowElement): ditto.
1467
1468 2011-01-25  Kent Tamura  <tkent@chromium.org>
1469
1470         Reviewed by Dimitri Glazkov.
1471
1472         HTMLFormElement::checkValidity() returns incorrect result if 'invalid' events are canceled.
1473         https://bugs.webkit.org/show_bug.cgi?id=52565
1474
1475         * html/HTMLFormElement.cpp:
1476         (WebCore::HTMLFormElement::validateInteractively):
1477           Check checkInvalidControlsAndCollectUnhandled() result instead of
1478           checking emptiness of unhandled invalid controls list.
1479         (WebCore::HTMLFormElement::checkValidity): ditto.
1480         (WebCore::HTMLFormElement::checkInvalidControlsAndCollectUnhandled):
1481           Renamed from collectUnhandledInvalidControls().
1482           Returns true if there is any invalid control regardless of event canceling.
1483         * html/HTMLFormElement.h: Rename collectUnhandledInvalidControls() to
1484           checkInvalidControlsAndCollectUnhandled().
1485
1486 2011-01-25  Kent Tamura  <tkent@chromium.org>
1487
1488         Reviewed by Dimitri Glazkov.
1489
1490         Range and number inputs should reject increment and decrement by
1491         keyboard or mouse wheel if they are disabled or read-only
1492         https://bugs.webkit.org/show_bug.cgi?id=53151
1493
1494         * html/RangeInputType.cpp:
1495         (WebCore::RangeInputType::handleKeydownEvent): Check disabled() and readOnly().
1496         * html/TextFieldInputType.cpp:
1497         (WebCore::TextFieldInputType::handleKeydownEventForSpinButton): ditto.
1498         (WebCore::TextFieldInputType::handleWheelEventForSpinButton): ditto.
1499
1500 2011-01-25  Kent Tamura  <tkent@chromium.org>
1501
1502         Reviewed by Dimitri Glazkov.
1503
1504         API to support localized numbers for <input type=number>
1505         https://bugs.webkit.org/show_bug.cgi?id=45730
1506
1507         Introduce platform/text/LocalizedNumber.h, and
1508         LocalizedNumberNone.cpp, which is an empty implementation of the
1509         functions in LocalizedNumber.h.  We use LocalizedNumberNone.cpp in
1510         all platforms for now.
1511
1512         A string in a type=number field is parsed as a localized number
1513         first. If the parsing fails, it is parsed as the HTML5 number.
1514
1515         We introduce HTMLInputElement::visibleValue(). It represents a value
1516         which should be drawn by a renderer. HTMLInputElement::value() always
1517         returns a number formatted for HTML5, and visibleValue() may return a
1518         localized number.
1519
1520         No new tests because this doesn't change any behavior.
1521
1522         * Android.mk: Add LocalizedNumber.h and/or LocalizedNumberNone.cpp.
1523         * CMakeLists.txt: ditto.
1524         * GNUmakefile.am: ditto.
1525         * WebCore.gypi: ditto.
1526         * WebCore.pro: ditto.
1527         * WebCore.vcproj/WebCore.vcproj: ditto.
1528         * WebCore.xcodeproj/project.pbxproj: ditto.
1529         * dom/InputElement.h: Add visibleValue().
1530         * html/HTMLInputElement.cpp:
1531         (WebCore::HTMLInputElement::visibleValue): Added.  Just call InputType::visibleValue().
1532         * html/HTMLInputElement.h: Declare visibleValue().
1533         * html/InputType.cpp:
1534         (WebCore::InputType::visibleValue): Add the default implementation of
1535           visibleValue(), which returns HTMLInputElement::value().
1536         * html/InputType.h: Add declarations.
1537         * html/NumberInputType.cpp:
1538         (WebCore::isHTMLNumberCharacter): Renamed from isNumberCharacter().
1539         (WebCore::isNumberCharacter): Calls isLocalizedNumberCharacter() and isHTMLNumberCharacter().
1540         (WebCore::NumberInputType::visibleValue):
1541           Returns a localized number string produced by formatLocalizedNumber().
1542         (WebCore::NumberInputType::isAcceptableValue): Calls parseLocalizedNumber().
1543         (WebCore::NumberInputType::sanitizeValue): Calls parseLocalizedNumber().
1544         * html/NumberInputType.h: Add declarations.
1545         * platform/text/LocalizedNumber.h: Added.
1546         * platform/text/LocalizedNumberNone.cpp: Added.
1547         (WebCore::parseLocalizedNumber):
1548         (WebCore::formatLocalizedNumber):
1549         (WebCore::isLocalizedNumberCharacter):
1550         * rendering/RenderTextControlSingleLine.cpp:
1551         (WebCore::RenderTextControlSingleLine::updateFromElement):
1552           Calls InputElement::visibleValue() instead of value().
1553         * wml/WMLInputElement.h:
1554         (WebCore::WMLInputElement::visibleValue): Added. It just calls value().
1555
1556 2011-01-25  Alexey Proskuryakov  <ap@apple.com>
1557
1558         Reviewed by Darin Adler.
1559
1560         https://bugs.webkit.org/show_bug.cgi?id=53143
1561         Add IntRectHash
1562
1563         * WebCore.xcodeproj/project.pbxproj:
1564         * platform/graphics/IntRectHash.h: Added.
1565
1566         * platform/graphics/IntSizeHash.h: Don't do "using WebCore::IntSize"!
1567
1568 2011-01-25  Ilya Sherman  <isherman@chromium.org>
1569
1570         Reviewed by Ryosuke Niwa.
1571
1572         Remove trailing whitespace in HTMLInputElement.cpp
1573         https://bugs.webkit.org/show_bug.cgi?id=53152
1574
1575         * html/HTMLInputElement.cpp:
1576         (WebCore::HTMLInputElement::updateCheckedRadioButtons):
1577         (WebCore::HTMLInputElement::applyStep):
1578         (WebCore::HTMLInputElement::updateFocusAppearance):
1579         (WebCore::HTMLInputElement::mapToEntry):
1580         (WebCore::HTMLInputElement::setAutofilled):
1581         (WebCore::HTMLInputElement::willMoveToNewOwnerDocument):
1582         (WebCore::HTMLInputElement::didMoveToNewOwnerDocument):
1583
1584 2011-01-25  Mike Reed  <reed@google.com>
1585
1586         Reviewed by James Robinson.
1587
1588         DrawingBufer::reset() today checks if the new size is the same as its
1589         m_size, and if so, returns immediately. This does not match the
1590         semantics of <canvas>, which wants to clear its contents anytime the
1591         size is specified.
1592         https://bugs.webkit.org/show_bug.cgi?id=53149
1593
1594         Test: Covered by existing <canvas> tests using gpu.
1595
1596         * platform/graphics/chromium/DrawingBufferChromium.cpp:
1597         (WebCore::DrawingBuffer::DrawingBuffer):
1598         * platform/graphics/gpu/DrawingBuffer.cpp:
1599         (WebCore::DrawingBuffer::reset):
1600
1601 2011-01-25  Cris Neckar  <cdn@chromium.org>
1602
1603         Reviewed by Adam Barth.
1604
1605         Add a hashset of DOMURLs to ScriptExecutionContext to track back references.
1606         https://bugs.webkit.org/show_bug.cgi?id=53038
1607
1608         Test: fast/dom/window-domurl-crash.html
1609
1610         * dom/ScriptExecutionContext.cpp:
1611         (WebCore::ScriptExecutionContext::~ScriptExecutionContext):
1612         (WebCore::ScriptExecutionContext::createdDomUrl):
1613         (WebCore::ScriptExecutionContext::destroyedDomUrl):
1614         * dom/ScriptExecutionContext.h:
1615         (WebCore::ScriptExecutionContext::domUrls):
1616         * html/DOMURL.cpp:
1617         (WebCore::DOMURL::DOMURL):
1618         (WebCore::DOMURL::~DOMURL):
1619         (WebCore::DOMURL::contextDestroyed):
1620         * html/DOMURL.h:
1621         (WebCore::DOMURL::scriptExecutionContext):
1622
1623 2011-01-23  Antti Koivisto  <antti@apple.com>
1624
1625         Reviewed by Darin Adler.
1626
1627         https://bugs.webkit.org/show_bug.cgi?id=52983
1628         Eliminate m_tagHistory pointer from CSSSelector
1629
1630         Keep the component selectors in the array in CSSSelectorList instead
1631         of maintaining a linked list between them. This allows eliminating
1632         m_tagHistory pointer, shrinking CSSSelector by 25% (selection performance
1633         seems to improve some too due to better locality).
1634
1635         * WebCore.xcodeproj/project.pbxproj:
1636         
1637             Make CSSSelector.h a private header.
1638         
1639         * css/CSSGrammar.y:
1640         
1641             Use CSSParserSelector during parsing to keep the tag history in 
1642             a linked list. This is flattened to an array after parsing.
1643             Use accessors for setting selector values.
1644             Use OwnPtr in selector vector.
1645             
1646         * css/CSSPageRule.cpp:
1647         (WebCore::CSSPageRule::CSSPageRule):
1648         * css/CSSPageRule.h:
1649         (WebCore::CSSPageRule::create):
1650         
1651             Simplify.
1652     
1653         * css/CSSParser.cpp:
1654         (WebCore::CSSParser::~CSSParser):
1655         (WebCore::CSSParser::createFloatingSelector):
1656         (WebCore::CSSParser::sinkFloatingSelector):
1657         (WebCore::CSSParser::createStyleRule):
1658         (WebCore::CSSParser::updateSpecifiersWithElementName):
1659         (WebCore::CSSParser::createPageRule):
1660         * css/CSSParser.h:
1661         (WebCore::CSSParser::reusableSelectorVector):
1662         
1663             CSSSelector -> CSSParserSelector.
1664             Use OwnPtr in selector vector.
1665             
1666         * css/CSSParserValues.cpp:
1667         (WebCore::CSSParserSelector::CSSParserSelector):
1668         (WebCore::CSSParserSelector::~CSSParserSelector):
1669         * css/CSSParserValues.h:
1670         (WebCore::CSSParserSelector::releaseSelector):
1671         (WebCore::CSSParserSelector::setTag):
1672         (WebCore::CSSParserSelector::setValue):
1673         (WebCore::CSSParserSelector::setAttribute):
1674         (WebCore::CSSParserSelector::setArgument):
1675         (WebCore::CSSParserSelector::setSimpleSelector):
1676         (WebCore::CSSParserSelector::setMatch):
1677         (WebCore::CSSParserSelector::setRelation):
1678         (WebCore::CSSParserSelector::setForPage):
1679         (WebCore::CSSParserSelector::pseudoType):
1680         (WebCore::CSSParserSelector::isUnknownPseudoElement):
1681         (WebCore::CSSParserSelector::isSimple):
1682         (WebCore::CSSParserSelector::tagHistory):
1683         (WebCore::CSSParserSelector::setTagHistory):
1684         
1685             Linked list used during parsing.
1686             Avoid recursive destruction.
1687
1688         * css/CSSSelector.cpp:
1689         (WebCore::CSSSelector::extractPseudoType):
1690         (WebCore::CSSSelector::operator==):
1691         (WebCore::CSSSelector::selectorText):
1692         (WebCore::CSSSelector::setSimpleSelector):
1693         * css/CSSSelector.h:
1694         (WebCore::CSSSelector::CSSSelector):
1695         (WebCore::CSSSelector::~CSSSelector):
1696         (WebCore::CSSSelector::tagHistory):
1697         (WebCore::CSSSelector::tag):
1698         (WebCore::CSSSelector::value):
1699         (WebCore::CSSSelector::setTag):
1700         (WebCore::CSSSelector::isLastInTagHistory):
1701         (WebCore::CSSSelector::setNotLastInTagHistory):
1702         (WebCore::CSSSelector::RareData::RareData):
1703         (WebCore::CSSSelector::RareData::~RareData):
1704         (WebCore::CSSSelector::createRareData):
1705         (WebCore::CSSSelector::setValue):
1706         
1707             Remove m_tagHistory.
1708             Keep m_value in the union with the rare data pointer instead.
1709             Make m_value and m_tag private, implement accessors.
1710             Add a new bit to indicate end of the tag history (multipart selector).
1711             Eliminate complex destruction. Selectors are now deleted as an array or by a CSSParserSelector chain.
1712             
1713         * css/CSSSelectorList.cpp:
1714         (WebCore::CSSSelectorList::adoptSelectorVector):
1715         
1716             Flatten everything to an array.
1717         
1718         (WebCore::SelectorNeedsNamespaceResolutionFunctor::operator()):
1719         * css/CSSSelectorList.h:
1720         (WebCore::CSSSelectorList::hasOneSelector):
1721         (WebCore::CSSSelectorList::next):
1722         
1723             Skip over the subparts of multipart selectors to find the next selector.
1724     
1725         * css/CSSStyleRule.h:
1726         (WebCore::CSSStyleRule::adoptSelectorVector):
1727         
1728             CSSSelector -> CSSParserSelector.
1729             
1730         * css/CSSStyleSelector.cpp:
1731         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector):
1732         (WebCore::CSSRuleSet::addRule):
1733         (WebCore::collectIdsAndSiblingRulesFromList):
1734         (WebCore::CSSStyleSelector::matchPageRulesForList):
1735         * dom/Node.cpp:
1736         (WebCore::Node::querySelector):
1737         * dom/SelectorNodeList.cpp:
1738         (WebCore::createSelectorNodeList):
1739         
1740             Use accessors.
1741
1742 2011-01-25  James Simonsen  <simonjam@chromium.org>
1743
1744         Reviewed by Tony Chang.
1745
1746         [Chromium] Support small caps in complex text on linux
1747         https://bugs.webkit.org/show_bug.cgi?id=53051
1748
1749         * platform/graphics/chromium/ComplexTextControllerLinux.cpp:
1750         (WebCore::ComplexTextController::nextScriptRun): Break runs at small caps boundaries.
1751         (WebCore::ComplexTextController::setupFontForScriptRun): Setup small caps font data if needed.
1752         * platform/graphics/chromium/ComplexTextControllerLinux.h: Store small caps text in separate string.
1753
1754 2011-01-25  Steve Falkenburg  <sfalken@apple.com>
1755
1756         Rubber-stamped by Adam Roben.
1757
1758         Windows production build fix.
1759         Use correct environment variable escaping
1760
1761         * WebCore.vcproj/WebCore.make:
1762
1763 2011-01-25  Adam Barth  <abarth@webkit.org>
1764
1765         Reviewed by Eric Seidel.
1766
1767         Empty URLs are never display isolated
1768         https://bugs.webkit.org/show_bug.cgi?id=53053
1769
1770         This check mirrors the check in the local case.  There isn't a good way
1771         to test this with a LayoutTest, but it is tested in Chromium (where
1772         this registry is used).
1773
1774         * platform/SchemeRegistry.cpp:
1775         (WebCore::SchemeRegistry::shouldTreatURLSchemeAsDisplayIsolated):
1776
1777 2011-01-25  Sam Weinig  <sam@webkit.org>
1778
1779         Reviewed by Anders Carlsson.
1780
1781         Pipe a timestamp down into the PlatformWheelEvent for the Mac.
1782         https://bugs.webkit.org/show_bug.cgi?id=53111
1783
1784         * platform/PlatformWheelEvent.h:
1785         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1786         (WebCore::PlatformWheelEvent::timestamp):
1787         Add timestamp member.
1788
1789         * platform/mac/WheelEventMac.mm:
1790         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1791         Initialize the timestamp from the event.
1792
1793 2011-01-25  Sheriff Bot  <webkit.review.bot@gmail.com>
1794
1795         Unreviewed, rolling out r76625.
1796         http://trac.webkit.org/changeset/76625
1797         https://bugs.webkit.org/show_bug.cgi?id=53119
1798
1799         "incorrect pixel test results" (Requested by rniwa on
1800         #webkit).
1801
1802         * rendering/RenderBox.cpp:
1803         (WebCore::RenderBox::localCaretRect):
1804
1805 2011-01-25  Patrick Gansterer  <paroga@webkit.org>
1806
1807         Unreviewed WinCE build fix for r76614.
1808
1809         * platform/FileSystem.h:
1810
1811 2011-01-21  Levi Weintraub  <leviw@chromium.org>
1812
1813         Reviewed by Darin Adler.
1814
1815         Adding border and padding to the calculation of the local caret rect for RenderBoxes.
1816
1817         Undo moves caret to invalid position
1818         https://bugs.webkit.org/show_bug.cgi?id=49744
1819
1820         Tests: editing/selection/caret-painting-after-paste-undo-rtl.html
1821                editing/selection/caret-painting-after-paste-undo.html
1822
1823         * rendering/RenderBox.cpp:
1824         (WebCore::RenderBox::localCaretRect):
1825
1826 2011-01-25  Sam Weinig  <sam@webkit.org>
1827
1828         Reviewed by Anders Carlsson.
1829
1830         Add hasPreciseScrollingDeltas bit to PlatformWheelEvent on the Mac.
1831         https://bugs.webkit.org/show_bug.cgi?id=53107
1832
1833         * platform/PlatformWheelEvent.h:
1834         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1835         (WebCore::PlatformWheelEvent::hasPreciseScrollingDeltas):
1836         * platform/mac/WheelEventMac.mm:
1837         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1838
1839 2011-01-20  Jer Noble  <jer.noble@apple.com>
1840
1841         Reviewed by Eric Carlson.
1842
1843         REGRESSION (r72119): Audio never plays on Star Wars intro animation
1844         https://bugs.webkit.org/show_bug.cgi?id=52467
1845         
1846         QuickTime's eat/m4a movie importer compontent doesn't list audio/m4a as a mime
1847         type which it supports, though it handles .m4a files just fine.  Change the way
1848         we build the list of supported MIME Types through a new WebKitSystemInterface
1849         function.
1850         
1851         Caused by r72119, which adds system-specific extension->MIME entries to the cache
1852         before global entries, and the system-specific entries include QuickTime's registry 
1853         entries which contain the audio/m4a MIME type, while its components do not.
1854
1855         Test: media/audio-mpeg4-supported.html
1856
1857         * WebCore.vcproj/QTMovieWinCommon.vsprops:
1858         * platform/graphics/win/QTMovie.cpp:
1859         (getMIMETypeCallBack):
1860         (initializeSupportedTypes):
1861         (QTMovie::countSupportedTypes): gSupportedTypes is now a CFArrayRef.
1862         (QTMovie::getSupportedType): Ditto.
1863
1864 2011-01-25  Hans Wennborg  <hans@chromium.org>
1865
1866         Reviewed by Jeremy Orlow.
1867
1868         IndexedDB: Remove PlatformBridge::idbShutdown()
1869         https://bugs.webkit.org/show_bug.cgi?id=53077
1870
1871         Since Chromium r72157, this is not used anymore. The previous use was
1872         to signal to the embedder that IndexedDB was shutting down, but we
1873         agreed it is better if the embedder keeps track of that itself.
1874
1875         No new tests: this does not change any functionality.
1876
1877         * platform/chromium/PlatformBridge.h:
1878         * storage/IDBFactoryBackendInterface.cpp:
1879         * storage/IDBFactoryBackendInterface.h:
1880         (WebCore::IDBFactoryBackendInterface::~IDBFactoryBackendInterface):
1881         * storage/chromium/IDBFactoryBackendInterface.cpp:
1882
1883 2011-01-25  Darin Adler  <darin@apple.com>
1884
1885         Reviewed by Anders Carlsson.
1886
1887         WebKit is using CSBackupSetItemExcluded incorrectly
1888         https://bugs.webkit.org/show_bug.cgi?id=53095
1889         rdar://problem/8790540
1890
1891         * loader/icon/IconDatabase.cpp:
1892         (WebCore::IconDatabase::performOpenInitialization): Added code to
1893         exclude the database from backup one time, and record inside the
1894         database that this has been done.
1895         (WebCore::IconDatabase::wasExcludedFromBackup): Added.
1896         (WebCore::IconDatabase::setWasExcludedFromBackup): Added.
1897         * loader/icon/IconDatabase.h: Added new functions above.
1898
1899         * platform/FileSystem.cpp:
1900         (WebCore::canExcludeFromBackup): Added.
1901         (WebCore::excludeFromBackup): Added.
1902
1903         * platform/FileSystem.h: Added canExcludeFromBackup, excludeFromBackup,
1904         and pathAsURL functions. Cleaned up ifdefs and comments a bit and sorted
1905         things alphabetically, particularly platform-specific sections.
1906
1907         * platform/cf/FileSystemCF.cpp:
1908         (WebCore::pathAsURL): Added.
1909
1910         * platform/mac/FileSystemMac.mm:
1911         (WebCore::canExcludeFromBackup): Added.
1912         (WebCore::excludeFromBackup): Added.
1913
1914         * platform/network/cf/FormDataStreamCFNet.cpp:
1915         (WebCore::advanceCurrentStream): Changed to call pathAsURL.
1916         * platform/network/mac/FormDataStreamMac.mm:
1917         (WebCore::advanceCurrentStream): Ditto.
1918
1919 2011-01-25  Helder Correia  <helder@sencha.com>
1920
1921         Reviewed by Dirk Schulze.
1922
1923         REGRESSION(75139): SVG gradients are not applied to texts
1924         https://bugs.webkit.org/show_bug.cgi?id=52531
1925
1926         CGContextConcatCTM should use the CGLayer context, not the
1927         GraphicsContext. Also, the CTM needs to be adjusted (translated).
1928         This fixes SVG text gradient fill.
1929
1930         Test: svg/css/composite-shadow-text.svg
1931
1932         * platform/graphics/cg/GraphicsContextCG.cpp:
1933         (WebCore::GraphicsContext::fillRect):
1934
1935 2011-01-25  Benjamin Kalman  <kalman@chromium.org>
1936
1937         Reviewed by Ryosuke Niwa.
1938
1939         Cannot extend or modify forward by word over a non-contenteditable region
1940         https://bugs.webkit.org/show_bug.cgi?id=53070
1941
1942         Test: editing/selection/extend-forward-by-word-over-non-editable.html
1943
1944         Change all instances of honorEditableBoundaryAtOrAfter to honorEditableBoundaryAtOrBefore and vice versa in the
1945         functions which determine the end/start of words/lines/sentences in visible_units.cpp.
1946
1947         This fixes the bug where moving forwards by a word over a non-contenteditable region would place the cursor
1948         inside that region, and then get moved back to the start of the word due to honorEditableBoundaryAtOrBefore.
1949         The cursor is now moved to the end of the region (which is effectively a noop in this case).
1950
1951         * editing/visible_units.cpp: Change all instances of honorEditableBoundaryAtOrAfter to
1952         honorEditableBoundaryAtOrBefore and vice versa.
1953         (WebCore::previousWordPosition):
1954         (WebCore::nextWordPosition):
1955         (WebCore::startOfLine):
1956         (WebCore::endOfLine):
1957         (WebCore::previousSentencePosition):
1958         (WebCore::nextSentencePosition):
1959         (WebCore::logicalStartOfLine):
1960         (WebCore::logicalEndOfLine):
1961
1962 2011-01-25  Yael Aharon  <yael.aharon@nokia.com>
1963
1964         Unreviewed build fix.
1965         After r76466, efsrv.lib is used unconditionally.
1966         Don't guard it with ENABLE_NETSCAPE_PLUGIN_API.
1967
1968         * WebCore.pro:
1969
1970 2011-01-24  Zhenyao Mo  <zmo@google.com>
1971
1972         Reviewed by Kenneth Russell.
1973
1974         Style cleanup for WebGLRenderingContext
1975         https://bugs.webkit.org/show_bug.cgi?id=52352
1976
1977         * html/canvas/WebGLBuffer.cpp:
1978         * html/canvas/WebGLBuffer.h:
1979         * html/canvas/WebGLObject.cpp:
1980         * html/canvas/WebGLProgram.cpp:
1981         * html/canvas/WebGLRenderbuffer.cpp:
1982         * html/canvas/WebGLRenderingContext.cpp:
1983         (WebCore::WebGLRenderingContext::create):
1984         (WebCore::WebGLRenderingContext::blendFunc):
1985         (WebCore::WebGLRenderingContext::createShader):
1986         (WebCore::WebGLRenderingContext::deleteBuffer):
1987         (WebCore::WebGLRenderingContext::deleteShader):
1988         (WebCore::WebGLRenderingContext::deleteTexture):
1989         (WebCore::WebGLRenderingContext::disableVertexAttribArray):
1990         (WebCore::WebGLRenderingContext::validateIndexArrayPrecise):
1991         (WebCore::WebGLRenderingContext::validateRenderingState):
1992         (WebCore::WebGLRenderingContext::enableVertexAttribArray):
1993         (WebCore::WebGLRenderingContext::getUniform):
1994         (WebCore::WebGLRenderingContext::detachAndRemoveAllObjects):
1995         * html/canvas/WebGLRenderingContext.h:
1996         * html/canvas/WebGLShader.cpp:
1997         * html/canvas/WebGLTexture.cpp:
1998         * html/canvas/WebGLUniformLocation.cpp:
1999         * html/canvas/WebGLUniformLocation.h:
2000
2001 2011-01-24  Chris Marrin  <cmarrin@apple.com>
2002
2003         Reviewed by Eric Seidel.
2004
2005         Change ENABLE_3D_CANVAS to ENABLE_WEBGL
2006         https://bugs.webkit.org/show_bug.cgi?id=53041
2007
2008         * Configurations/FeatureDefines.xcconfig:
2009         * DerivedSources.cpp:
2010         * GNUmakefile.am:
2011         * WebCore.pro:
2012         * bindings/generic/RuntimeEnabledFeatures.h:
2013         * bindings/js/JSArrayBufferCustom.cpp:
2014         * bindings/js/JSCanvasRenderingContextCustom.cpp:
2015         (WebCore::toJS):
2016         * bindings/js/JSDOMWindowCustom.cpp:
2017         * bindings/js/JSDataViewCustom.cpp:
2018         * bindings/js/JSDocumentCustom.cpp:
2019         * bindings/js/JSFloat32ArrayCustom.cpp:
2020         * bindings/js/JSHTMLCanvasElementCustom.cpp:
2021         (WebCore::JSHTMLCanvasElement::getContext):
2022         * bindings/js/JSInt16ArrayCustom.cpp:
2023         * bindings/js/JSInt32ArrayCustom.cpp:
2024         * bindings/js/JSInt8ArrayCustom.cpp:
2025         * bindings/js/JSUint16ArrayCustom.cpp:
2026         * bindings/js/JSUint32ArrayCustom.cpp:
2027         * bindings/js/JSUint8ArrayCustom.cpp:
2028         * bindings/js/JSWebGLRenderingContextCustom.cpp:
2029         * bindings/js/JSXMLHttpRequestCustom.cpp:
2030         (WebCore::JSXMLHttpRequest::markChildren):
2031         (WebCore::JSXMLHttpRequest::send):
2032         (WebCore::JSXMLHttpRequest::response):
2033         * bindings/v8/custom/V8ArrayBufferCustom.cpp:
2034         * bindings/v8/custom/V8ArrayBufferViewCustom.h:
2035         * bindings/v8/custom/V8DataViewCustom.cpp:
2036         * bindings/v8/custom/V8DocumentCustom.cpp:
2037         (WebCore::V8Document::getCSSCanvasContextCallback):
2038         * bindings/v8/custom/V8Float32ArrayCustom.cpp:
2039         * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
2040         (WebCore::V8HTMLCanvasElement::getContextCallback):
2041         * bindings/v8/custom/V8Int16ArrayCustom.cpp:
2042         * bindings/v8/custom/V8Int32ArrayCustom.cpp:
2043         * bindings/v8/custom/V8Int8ArrayCustom.cpp:
2044         * bindings/v8/custom/V8Uint16ArrayCustom.cpp:
2045         * bindings/v8/custom/V8Uint32ArrayCustom.cpp:
2046         * bindings/v8/custom/V8Uint8ArrayCustom.cpp:
2047         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
2048         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
2049         (WebCore::V8XMLHttpRequest::responseAccessorGetter):
2050         (WebCore::V8XMLHttpRequest::sendCallback):
2051         * features.pri:
2052         * html/HTMLCanvasElement.cpp:
2053         (WebCore::HTMLCanvasElement::getContext):
2054         (WebCore::HTMLCanvasElement::reset):
2055         * html/HTMLCanvasElement.h:
2056         * html/canvas/ArrayBuffer.cpp:
2057         * html/canvas/ArrayBuffer.idl:
2058         * html/canvas/ArrayBufferView.cpp:
2059         * html/canvas/ArrayBufferView.idl:
2060         * html/canvas/DataView.cpp:
2061         * html/canvas/DataView.idl:
2062         * html/canvas/Float32Array.cpp:
2063         * html/canvas/Float32Array.idl:
2064         * html/canvas/Int16Array.cpp:
2065         * html/canvas/Int16Array.idl:
2066         * html/canvas/Int32Array.cpp:
2067         * html/canvas/Int32Array.idl:
2068         * html/canvas/Int8Array.cpp:
2069         * html/canvas/Int8Array.idl:
2070         * html/canvas/OESStandardDerivatives.cpp:
2071         * html/canvas/OESStandardDerivatives.idl:
2072         * html/canvas/OESTextureFloat.cpp:
2073         * html/canvas/OESTextureFloat.idl:
2074         * html/canvas/Uint16Array.cpp:
2075         * html/canvas/Uint16Array.idl:
2076         * html/canvas/Uint32Array.cpp:
2077         * html/canvas/Uint32Array.idl:
2078         * html/canvas/Uint8Array.cpp:
2079         * html/canvas/Uint8Array.idl:
2080         * html/canvas/WebGLActiveInfo.idl:
2081         * html/canvas/WebGLBuffer.cpp:
2082         * html/canvas/WebGLBuffer.idl:
2083         * html/canvas/WebGLContextAttributes.cpp:
2084         * html/canvas/WebGLContextAttributes.idl:
2085         * html/canvas/WebGLContextEvent.idl:
2086         * html/canvas/WebGLExtension.cpp:
2087         * html/canvas/WebGLFramebuffer.cpp:
2088         * html/canvas/WebGLFramebuffer.idl:
2089         * html/canvas/WebGLGetInfo.cpp:
2090         * html/canvas/WebGLObject.cpp:
2091         * html/canvas/WebGLProgram.cpp:
2092         * html/canvas/WebGLProgram.idl:
2093         * html/canvas/WebGLRenderbuffer.cpp:
2094         * html/canvas/WebGLRenderbuffer.idl:
2095         * html/canvas/WebGLRenderingContext.cpp:
2096         * html/canvas/WebGLRenderingContext.idl:
2097         * html/canvas/WebGLShader.cpp:
2098         * html/canvas/WebGLShader.idl:
2099         * html/canvas/WebGLTexture.cpp:
2100         * html/canvas/WebGLTexture.idl:
2101         * html/canvas/WebGLUniformLocation.cpp:
2102         * html/canvas/WebGLUniformLocation.idl:
2103         * html/canvas/WebKitLoseContext.cpp:
2104         * html/canvas/WebKitLoseContext.idl:
2105         * page/DOMWindow.idl:
2106         * platform/graphics/ANGLEWebKitBridge.cpp:
2107         * platform/graphics/GraphicsContext3D.cpp:
2108         * platform/graphics/cg/GraphicsContext3DCG.cpp:
2109         * platform/graphics/gpu/DrawingBuffer.cpp:
2110         * platform/graphics/gpu/mac/DrawingBufferMac.mm:
2111         * platform/graphics/mac/GraphicsContext3DMac.mm:
2112         * platform/graphics/mac/WebGLLayer.mm:
2113         * platform/graphics/opengl/Extensions3DOpenGL.cpp:
2114         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
2115         * platform/graphics/qt/Extensions3DQt.cpp:
2116         * platform/graphics/qt/GraphicsContext3DQt.cpp:
2117         * platform/graphics/qt/GraphicsLayerQt.cpp:
2118         (WebCore::GraphicsLayerQtImpl::GraphicsLayerQtImpl):
2119         (WebCore::GraphicsLayerQtImpl::paint):
2120         (WebCore::GraphicsLayerQtImpl::flushChanges):
2121         * platform/graphics/qt/GraphicsLayerQt.h:
2122         * platform/graphics/skia/GraphicsContext3DSkia.cpp:
2123         * platform/graphics/texmap/GraphicsLayerTextureMapper.h:
2124         * rendering/RenderLayerBacking.cpp:
2125         (WebCore::isAcceleratedCanvas):
2126         (WebCore::RenderLayerBacking::updateGraphicsLayerConfiguration):
2127         (WebCore::RenderLayerBacking::containsPaintedContent):
2128         (WebCore::RenderLayerBacking::contentChanged):
2129         * webaudio/AudioBuffer.cpp:
2130         * webaudio/AudioBuffer.idl:
2131         * webaudio/RealtimeAnalyser.cpp:
2132         * webaudio/RealtimeAnalyser.h:
2133         * webaudio/RealtimeAnalyserNode.h:
2134         * webaudio/RealtimeAnalyserNode.idl:
2135         * xml/XMLHttpRequest.cpp:
2136         (WebCore::XMLHttpRequest::setResponseType):
2137         (WebCore::XMLHttpRequest::clearResponse):
2138         (WebCore::XMLHttpRequest::didReceiveData):
2139         * xml/XMLHttpRequest.h:
2140
2141 2011-01-25  Mikhail Naganov  <mnaganov@chromium.org>
2142
2143         Reviewed by Pavel Feldman.
2144
2145         Web Inspector: [Chromium] Prepare for landing of detailed heap snapshots.
2146
2147         - Introduce Preferences.detailedHeapProfiles flag for controlling
2148           querying of detailed heap snapshots.
2149         - Add boilerplate code for the new view.
2150         - Factor out common code.
2151
2152         https://bugs.webkit.org/show_bug.cgi?id=52624
2153
2154         * WebCore.gypi:
2155         * WebCore.vcproj/WebCore.vcproj:
2156         * bindings/js/ScriptProfiler.h:
2157         (WebCore::ScriptProfiler::HeapSnapshotControl::~HeapSnapshotControl):
2158         (WebCore::ScriptProfiler::takeHeapSnapshot):
2159         * bindings/v8/ScriptProfiler.cpp:
2160         (WebCore::ScriptProfiler::takeHeapSnapshot):
2161         * bindings/v8/ScriptProfiler.h:
2162         (WebCore::ScriptProfiler::HeapSnapshotControl::~HeapSnapshotControl):
2163         * inspector/Inspector.idl:
2164         * inspector/InspectorProfilerAgent.cpp:
2165         (WebCore::InspectorProfilerAgent::takeHeapSnapshot):
2166         * inspector/InspectorProfilerAgent.h:
2167         * inspector/front-end/DetailedHeapshotView.js: Added.
2168         (WebInspector.DetailedHeapshotView):
2169         (WebInspector.DetailedHeapshotView.prototype.get statusBarItems):
2170         (WebInspector.DetailedHeapshotView.prototype.get profile):
2171         (WebInspector.DetailedHeapshotView.prototype.set profile):
2172         (WebInspector.DetailedHeapshotView.prototype.show):
2173         (WebInspector.DetailedHeapshotView.prototype.hide):
2174         (WebInspector.DetailedHeapshotProfileType):
2175         (WebInspector.DetailedHeapshotProfileType.prototype.get buttonTooltip):
2176         (WebInspector.DetailedHeapshotProfileType.prototype.get buttonStyle):
2177         (WebInspector.DetailedHeapshotProfileType.prototype.buttonClicked):
2178         (WebInspector.DetailedHeapshotProfileType.prototype.get welcomeMessage):
2179         (WebInspector.DetailedHeapshotProfileType.prototype.createSidebarTreeElementForProfile):
2180         (WebInspector.DetailedHeapshotProfileType.prototype.createView):
2181         * inspector/front-end/HeapSnapshot.js: Added.
2182         (WebInspector.HeapSnapshotEdgesIterator):
2183         (WebInspector.HeapSnapshotEdgesIterator.prototype.get done):
2184         (WebInspector.HeapSnapshotEdgesIterator.prototype.get isElement):
2185         (WebInspector.HeapSnapshotEdgesIterator.prototype.get isHidden):
2186         (WebInspector.HeapSnapshotEdgesIterator.prototype.get name):
2187         (WebInspector.HeapSnapshotEdgesIterator.prototype.next):
2188         (WebInspector.HeapSnapshotEdgesIterator.prototype.get node):
2189         (WebInspector.HeapSnapshotEdgesIterator.prototype.get nodeIndex):
2190         (WebInspector.HeapSnapshotEdgesIterator.prototype._getNameOrIndex):
2191         (WebInspector.HeapSnapshotEdgesIterator.prototype._getType):
2192         (WebInspector.HeapSnapshotNodeWrapper):
2193         (WebInspector.HeapSnapshotNodeWrapper.prototype.get edges):
2194         (WebInspector.HeapSnapshotNodeWrapper.prototype.get edgesCount):
2195         (WebInspector.HeapSnapshotNodeWrapper.prototype.get instancesCount):
2196         (WebInspector.HeapSnapshotNodeWrapper.prototype.get isHidden):
2197         (WebInspector.HeapSnapshotNodeWrapper.prototype.get name):
2198         (WebInspector.HeapSnapshotNodeWrapper.prototype.get selfSize):
2199         (WebInspector.HeapSnapshotNodeWrapper.prototype._getName):
2200         (WebInspector.HeapSnapshotNodeWrapper.prototype._getEdges):
2201         (WebInspector.HeapSnapshotNodeWrapper.prototype._getType):
2202         (WebInspector.HeapSnapshot):
2203         (WebInspector.HeapSnapshot.prototype._init):
2204         (WebInspector.HeapSnapshot.prototype.get rootEdges):
2205         * inspector/front-end/HeapSnapshotView.js:
2206         (WebInspector.HeapSnapshotProfileType.prototype.buttonClicked):
2207         * inspector/front-end/ProfilesPanel.js:
2208         (WebInspector.ProfilesPanel.prototype._setRecordingProfile):
2209         (WebInspector.ProfilesPanel.prototype._reportHeapSnapshotProgress):
2210         (WebInspector.ProfilerDispatcher.prototype.setRecordingProfile):
2211         (WebInspector.ProfilerDispatcher.prototype.reportHeapSnapshotProgress):
2212         * inspector/front-end/Settings.js:
2213         * inspector/front-end/WebKit.qrc:
2214         * inspector/front-end/inspector.html:
2215         * inspector/front-end/inspector.js:
2216         (WebInspector._createPanels):
2217
2218 2011-01-25  Yury Semikhatsky  <yurys@chromium.org>
2219
2220         Reviewed by Pavel Feldman.
2221
2222         Web Inspector: remove "attached" state related methods from InspectorAgent
2223         https://bugs.webkit.org/show_bug.cgi?id=53086
2224
2225         * WebCore.exp.in:
2226         * inspector/InspectorAgent.cpp:
2227         * inspector/InspectorAgent.h:
2228         * inspector/InspectorFrontendClientLocal.cpp:
2229         (WebCore::InspectorFrontendClientLocal::changeAttachedWindowHeight):
2230         (WebCore::InspectorFrontendClientLocal::restoreAttachedWindowHeight):
2231         * inspector/InspectorSettings.cpp:
2232         (WebCore::InspectorSettings::InspectorSettings):
2233         * inspector/InspectorSettings.h:
2234
2235 2011-01-25  Qi Zhang  <qi.2.zhang@nokia.com>
2236
2237         Reviewed by Laszlo Gombos.
2238
2239         [Symbian] RVCT fails to compile [U|I]nt[8|16|32]Array.h
2240         https://bugs.webkit.org/show_bug.cgi?id=51873
2241         
2242         Replace the using declaration, because it doesn't compile on RVCT, and WINSCW has the same issue.
2243         No new functionality so no new tests.
2244
2245         * html/canvas/Int32Array.h:
2246         (WebCore::Int32Array::set):
2247         * html/canvas/Int8Array.h:
2248         (WebCore::Int8Array::set):
2249         * html/canvas/Uint16Array.h:
2250         (WebCore::Uint16Array::set):
2251         * html/canvas/Uint32Array.h:
2252         (WebCore::Uint32Array::set):
2253         * html/canvas/Uint8Array.h:
2254         (WebCore::Uint8Array::set):
2255
2256 2011-01-25  Zoltan Herczeg  <zherczeg@webkit.org>
2257
2258         Reviewed by Dirk Schulze.
2259
2260         Repaint SVG elements with filter instead of relayout where possible
2261         https://bugs.webkit.org/show_bug.cgi?id=52200
2262
2263         This patch allows repainting of filters, when their
2264         attribute changes does not require relayout.
2265
2266         Existing dynamic-update tests cover this feature.
2267
2268         * platform/graphics/filters/FilterEffect.cpp:
2269         (WebCore::FilterEffect::clearResult): Clearing the currently stored image
2270         before repainting.
2271         * platform/graphics/filters/FilterEffect.h:
2272         * rendering/RenderObject.h:
2273         (WebCore::RenderObject::isSVGResourceFilter): Not only the filter primitives,
2274         but filters should also be detected to allow safe testing and casting.
2275         * rendering/svg/RenderSVGResourceFilter.cpp:
2276         (WebCore::RenderSVGResourceFilter::buildPrimitives): Passing the renderer.
2277         (WebCore::RenderSVGResourceFilter::applyResource):
2278         determineFilterPrimitiveSubregion does not require the filter anymore.
2279         (WebCore::RenderSVGResourceFilter::postApplyResource): Repaint
2280         if lastEffect->hasResult() is false.
2281         (WebCore::RenderSVGResourceFilter::primitiveAttributeChanged):
2282         Searching for all FilterEffects, whose created by the current FilterElement,
2283         and clearing all resulting images depending on those FilterEffects.
2284         * rendering/svg/RenderSVGResourceFilter.h:
2285         (WebCore::RenderSVGResourceFilter::isSVGResourceFilter):
2286         * rendering/svg/RenderSVGResourceFilterPrimitive.cpp:
2287         (WebCore::RenderSVGResourceFilterPrimitive::determineFilterPrimitiveSubregion):
2288         The filter argument is unnecessary anymore. But is is still kept as a static
2289         member, since the primitive renderer still does not know about the
2290         FilterEffect objects.
2291         * rendering/svg/RenderSVGResourceFilterPrimitive.h:
2292         (WebCore::RenderSVGResourceFilterPrimitive::RenderSVGResourceFilterPrimitive):
2293         (WebCore::RenderSVGResourceFilterPrimitive::primitiveAttributeChanged):
2294         Calls RenderSVGResourceFilter::primitiveAttributeChanged.
2295         * svg/SVGFEDiffuseLightingElement.cpp:
2296         (WebCore::SVGFEDiffuseLightingElement::setFilterEffectAttribute):
2297         Setting the new attribute value for each FilterEffect.
2298         (WebCore::SVGFEDiffuseLightingElement::svgAttributeChanged):
2299         * svg/SVGFEDiffuseLightingElement.h:
2300         Calling primitiveAttributeChanged.
2301         * svg/SVGFilterPrimitiveStandardAttributes.cpp:
2302         (WebCore::SVGFilterPrimitiveStandardAttributes::setFilterEffectAttribute):
2303         This function will be removed when all FilterElement implements
2304         their setFilterEffectAttribute
2305         * svg/SVGFilterPrimitiveStandardAttributes.h:
2306         (WebCore::SVGFilterPrimitiveStandardAttributes::primitiveAttributeChanged):
2307         * svg/graphics/filters/SVGFilterBuilder.cpp:
2308         (WebCore::SVGFilterBuilder::appendEffectToEffectReferences): The
2309         renderers are assigned to the filter effects.
2310         (WebCore::SVGFilterBuilder::clearEffects):
2311         (WebCore::SVGFilterBuilder::clearResultsRecursive): Recursively
2312         clearing the result images for those filters, whose depend on
2313         the starting filter.
2314         * svg/graphics/filters/SVGFilterBuilder.h:
2315         (WebCore::SVGFilterBuilder::effectReferences): 'get' is unnecessary
2316         (WebCore::SVGFilterBuilder::effectByRenderer): returns the
2317         FilterEffect belongs to this RenderObject.
2318
2319 2011-01-25  Dirk Schulze  <krit@webkit.org>
2320
2321         Reviewed by Nikolas Zimmermann.
2322
2323         SVG is missing to-animation support for Path
2324         https://bugs.webkit.org/show_bug.cgi?id=52982
2325
2326         SVG was missing 'to' animation support for SVG paths. Even the fallback to discrete
2327         animation did not work and an assert was thrown, because of the missing m_fromPath.
2328         This also influences a test of the W3C test suite. Subtest 2 of animate-elem-83-t.svg passes now.
2329
2330         Test: svg/animations/animate-path-to-animation.html
2331
2332         * svg/SVGAnimateElement.cpp:
2333         (WebCore::SVGAnimateElement::calculateAnimatedValue): Take the value of the last SVGAnimateElement for
2334         m_fromPath, since 'to' animations are accumulative.
2335         (WebCore::SVGAnimateElement::calculateFromAndToValues): Added support for 'to' animations.
2336         (WebCore::SVGAnimateElement::resetToBaseValue): Set m_animatedPath on the first animation element to baseVal.
2337         * svg/SVGPathByteStream.h:
2338         (WebCore::SVGPathByteStream::copySVGPathByteStream): Return copy of current byte stream.
2339
2340 2011-01-25  Pavel Feldman  <pfeldman@chromium.org>
2341
2342         Reviewed by Yury Semikhatsky.
2343
2344         Web Inspector: bind resources to URLs upon adding them into the tree.
2345         https://bugs.webkit.org/show_bug.cgi?id=53013
2346
2347         * inspector/front-end/AuditRules.js:
2348         (WebInspector.AuditRules.UnusedCssRule.prototype.doRun.evalCallback.selectorsCallback):
2349         * inspector/front-end/CSSStyleModel.js:
2350         (WebInspector.CSSStyleModel.prototype._styleSheetChanged.callback):
2351         (WebInspector.CSSStyleModel.prototype._styleSheetChanged):
2352         * inspector/front-end/DebuggerModel.js:
2353         (WebInspector.DebuggerModel.prototype._parsedScriptSource):
2354         * inspector/front-end/NetworkManager.js:
2355         (WebInspector.NetworkManager.prototype._processCachedResources):
2356         (WebInspector.NetworkManager.prototype.inflightResourceForURL):
2357         (WebInspector.NetworkDispatcher):
2358         (WebInspector.NetworkDispatcher.prototype.willSendRequest):
2359         (WebInspector.NetworkDispatcher.prototype.markResourceAsCached):
2360         (WebInspector.NetworkDispatcher.prototype.didReceiveResponse):
2361         (WebInspector.NetworkDispatcher.prototype.didReceiveContentLength):
2362         (WebInspector.NetworkDispatcher.prototype.didFinishLoading):
2363         (WebInspector.NetworkDispatcher.prototype.didFailLoading):
2364         (WebInspector.NetworkDispatcher.prototype.willSendWebSocketHandshakeRequest):
2365         (WebInspector.NetworkDispatcher.prototype.didReceiveWebSocketHandshakeResponse):
2366         (WebInspector.NetworkDispatcher.prototype.didCloseWebSocket):
2367         (WebInspector.NetworkDispatcher.prototype._appendRedirect):
2368         (WebInspector.NetworkDispatcher.prototype._startResource):
2369         (WebInspector.NetworkDispatcher.prototype._finishResource):
2370         (WebInspector.NetworkDispatcher.prototype._createResource):
2371         * inspector/front-end/ResourceTreeModel.js:
2372         (WebInspector.ResourceTreeModel.prototype.addResourceToFrame):
2373         (WebInspector.ResourceTreeModel.prototype._bindResourceURL):
2374         (WebInspector.ResourceTreeModel.prototype._clearResources):
2375         (WebInspector.ResourceTreeModel.prototype._unbindResourceURL):
2376         * inspector/front-end/ResourcesPanel.js:
2377         (WebInspector.ResourcesPanel.prototype.canShowSourceLine):
2378         (WebInspector.ResourcesPanel.prototype.showSourceLine):
2379         * inspector/front-end/ScriptsPanel.js:
2380         (WebInspector.ScriptsPanel.prototype._parsedScriptSource):
2381         (WebInspector.ScriptsPanel.prototype._addScript):
2382
2383 2011-01-25  Nikolas Zimmermann  <nzimmermann@rim.com>
2384
2385         Reviewed by Dirk Schulze.
2386
2387         Introduce FontMetrics abstraction
2388         https://bugs.webkit.org/show_bug.cgi?id=51456
2389
2390         Use accurate floating-point metrics for SVG Font calculations instead of casting float -> integer.
2391         This hopefully fixes differences between 32/64 bit bots.
2392
2393         Needs new layout test results for several platforms, which need to be taken from the bots landing afterwards.
2394
2395         * platform/graphics/SimpleFontData.cpp:
2396         (WebCore::SimpleFontData::SimpleFontData):
2397         (WebCore::SimpleFontData::initCharWidths):
2398
2399 2011-01-24  Pavel Podivilov  <podivilov@chromium.org>
2400
2401         Reviewed by Pavel Feldman.
2402
2403         Web Inspector: debugger and browser debugger agents should manage sticky breakpoints independently.
2404         https://bugs.webkit.org/show_bug.cgi?id=52999
2405
2406         * inspector/Inspector.idl:
2407         * inspector/InspectorAgent.cpp:
2408         (WebCore::InspectorAgent::didCommitLoad):
2409         (WebCore::InspectorAgent::enableDebugger):
2410         (WebCore::InspectorAgent::inspectedURLWithoutFragment):
2411         * inspector/InspectorAgent.h:
2412         * inspector/InspectorBrowserDebuggerAgent.cpp:
2413         (WebCore::InspectorBrowserDebuggerAgent::setAllBrowserBreakpoints):
2414         (WebCore::InspectorBrowserDebuggerAgent::inspectedURLChanged):
2415         (WebCore::InspectorBrowserDebuggerAgent::restoreStickyBreakpoint):
2416         * inspector/InspectorBrowserDebuggerAgent.h:
2417         * inspector/InspectorDebuggerAgent.cpp:
2418         (WebCore::InspectorDebuggerAgent::InspectorDebuggerAgent):
2419         (WebCore::InspectorDebuggerAgent::setAllJavaScriptBreakpoints):
2420         (WebCore::InspectorDebuggerAgent::inspectedURLChanged):
2421         (WebCore::InspectorDebuggerAgent::restoreBreakpoints):
2422         * inspector/InspectorDebuggerAgent.h:
2423         * inspector/InspectorState.cpp:
2424         (WebCore::InspectorState::InspectorState):
2425         * inspector/InspectorState.h:
2426         * inspector/front-end/BreakpointManager.js:
2427         (WebInspector.BreakpointManager):
2428         (WebInspector.BreakpointManager.prototype._projectChanged):
2429         (WebInspector.BreakpointManager.prototype._saveBreakpoints):
2430         (WebInspector.BreakpointManager.prototype._pushBreakpointsToBackend):
2431
2432 2011-01-25  Carlos Garcia Campos  <cgarcia@igalia.com>
2433
2434         Reviewed by Martin Robinson.
2435
2436         [GTK] Crash in some pages containing flash
2437         https://bugs.webkit.org/show_bug.cgi?id=53016
2438
2439         Flash plugin can produce X errors that are handled by the GDK X
2440         error handler, which exits the process. Since we don't want to
2441         crash due to flash bugs, we install a custom error handler to show
2442         a warning when a X error happens without aborting.
2443
2444         * plugins/gtk/PluginPackageGtk.cpp:
2445         (WebCore::webkitgtkXError):
2446         (WebCore::PluginPackage::load):
2447
2448 2011-01-25  Carlos Garcia Campos  <cgarcia@igalia.com>
2449
2450         Reviewed by Martin Robinson.
2451
2452         [GTK] Implement spin buttons in RenderThemeGtk
2453         https://bugs.webkit.org/show_bug.cgi?id=51454
2454
2455         Paint inner up/down buttons for spin button elements when building
2456         with GTK+ 3.x.
2457
2458         Test results will land with the GTK+ 2.x version of this patch.
2459
2460         * platform/gtk/RenderThemeGtk.h:
2461         * platform/gtk/RenderThemeGtk2.cpp:
2462         (WebCore::RenderThemeGtk::adjustInnerSpinButtonStyle):
2463         (WebCore::RenderThemeGtk::paintInnerSpinButton):
2464         * platform/gtk/RenderThemeGtk3.cpp:
2465         (WebCore::spinButtonArrowSize):
2466         (WebCore::RenderThemeGtk::adjustInnerSpinButtonStyle):
2467         (WebCore::paintSpinArrowButton):
2468         (WebCore::RenderThemeGtk::paintInnerSpinButton):
2469
2470 2011-01-24  Mihai Parparita  <mihaip@chromium.org>
2471
2472         Unreviewed. Missed move of one m_deleted use to be outside NDEBUG block
2473         in r76575.
2474
2475         * loader/cache/CachedResource.cpp:
2476         (WebCore::CachedResource::~CachedResource):
2477
2478 2011-01-24  Mihai Parparita  <mihaip@chromium.org>
2479
2480         Reviewed by Tony Chang.
2481
2482         Add runtime checks for invariants in memory cache
2483         https://bugs.webkit.org/show_bug.cgi?id=53059
2484         
2485         To help track down bug 53045, add some CRASH calls in addition to
2486         ASSERTs, so that we can track down failures in reliability bots.
2487
2488         Just some checks, no new tests necessary.
2489         
2490         * css/CSSImageValue.cpp:
2491         (WebCore::CSSImageValue::cachedImage):
2492         * loader/cache/CachedResource.h:
2493         * loader/cache/CachedResource.cpp:
2494         (WebCore::CachedResource::~CachedResource):
2495
2496 2011-01-24  Simon Fraser  <simon.fraser@apple.com>
2497
2498         Reviewed by Dan Bernstein.
2499
2500         Leaking CSSRuleDataList objects
2501         https://bugs.webkit.org/show_bug.cgi?id=53062
2502
2503         Fix leaked CSSRuleDataLists added to the m_pseudoRules hash.
2504
2505         * css/CSSStyleSelector.cpp:
2506         (WebCore::CSSRuleSet::~CSSRuleSet):
2507
2508 2011-01-24  Simon Fraser  <simon.fraser@apple.com>
2509
2510         Reviewed by Eric Seidel.
2511
2512         Refcount Images used in rendering code
2513         https://bugs.webkit.org/show_bug.cgi?id=52701
2514
2515         Change StyleImage::image(RenderObject*, const IntSize&) and
2516         CSSImageGeneratorValue::image(RenderObject*, const IntSize&) to
2517         return PassRefPtr<Image>, and adjust other code accordingly.
2518         
2519         This allows us to return one-time images, for example for CSS gradients
2520         whose appearance may change depending on factors other than the renderer
2521         and the destination size.
2522
2523         * css/CSSCanvasValue.cpp:
2524         (WebCore::CSSCanvasValue::image):
2525         * css/CSSCanvasValue.h:
2526         * css/CSSGradientValue.cpp:
2527         (WebCore::CSSGradientValue::image):
2528         * css/CSSGradientValue.h:
2529         * css/CSSImageGeneratorValue.h:
2530         * rendering/RenderBoxModelObject.cpp:
2531         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
2532         (WebCore::RenderBoxModelObject::paintNinePieceImage):
2533         * rendering/RenderImage.cpp:
2534         (WebCore::RenderImage::paintReplaced):
2535         (WebCore::RenderImage::paintIntoRect):
2536         * rendering/RenderImageResource.h:
2537         (WebCore::RenderImageResource::image):
2538         * rendering/RenderImageResourceStyleImage.h:
2539         (WebCore::RenderImageResourceStyleImage::image):
2540         * rendering/RenderListMarker.cpp:
2541         (WebCore::RenderListMarker::paint):
2542         * rendering/style/StyleCachedImage.cpp:
2543         (WebCore::StyleCachedImage::image):
2544         * rendering/style/StyleCachedImage.h:
2545         * rendering/style/StyleGeneratedImage.cpp:
2546         (WebCore::StyleGeneratedImage::image):
2547         * rendering/style/StyleGeneratedImage.h:
2548         * rendering/style/StyleImage.h:
2549         * rendering/style/StylePendingImage.h:
2550         (WebCore::StylePendingImage::image):
2551         * rendering/svg/RenderSVGImage.cpp:
2552         (WebCore::RenderSVGImage::paint):
2553
2554 2011-01-24  Tony Chang  <tony@chromium.org>
2555
2556         Unreviewed, round ascent and descent to match old code.
2557
2558         * platform/graphics/chromium/SimpleFontDataLinux.cpp:
2559         (WebCore::SimpleFontData::platformInit):
2560
2561 2011-01-24  Simon Fraser  <simon.fraser@apple.com>
2562
2563         Reviewed by Chris Marrin.
2564
2565         perspective() transform function should take lengths
2566         https://bugs.webkit.org/show_bug.cgi?id=52683
2567         
2568         The argument to the perspective() transform function should
2569         be a Length, rather than a bare number. Bare numbers are still
2570         accepted (and treated as px), but this behavior is deprecated.
2571
2572         Test: animations/3d/transform-perspective.html
2573               transforms/3d/general/3dtransform-values.html
2574
2575         * css/CSSParser.cpp:
2576         (WebCore::CSSParser::parseTransform): Check the units for the perspective()
2577         function. Allow bare numbers for backwards compatibility.
2578         * css/CSSStyleSelector.cpp:
2579         (WebCore::CSSStyleSelector::createTransformOperations): Convert
2580         value to Length.
2581         * platform/graphics/transforms/PerspectiveTransformOperation.cpp:
2582         (WebCore::clampToPostiveInteger): Helper.
2583         (WebCore::PerspectiveTransformOperation::blend): Blend via Lengths.
2584         * platform/graphics/transforms/PerspectiveTransformOperation.h:
2585         (WebCore::PerspectiveTransformOperation::create): double -> Length.
2586         (WebCore::PerspectiveTransformOperation::perspective): Ditto.
2587         (WebCore::PerspectiveTransformOperation::isIdentity): Ditto.
2588         (WebCore::PerspectiveTransformOperation::apply): Ditto.
2589         (WebCore::PerspectiveTransformOperation::PerspectiveTransformOperation): Assert
2590         that the Length is a fixed type.
2591
2592 2011-01-24  Kent Tamura  <tkent@chromium.org>
2593
2594         Reviewed by Dimitri Glazkov.
2595
2596         [Windows] Textfield <input>s have different widths.
2597         https://bugs.webkit.org/show_bug.cgi?id=48405
2598
2599         - Apply the padding override for type=text to other textfield types too.
2600         - Reset margin value of outer spin button, which is not used in Windows.
2601         - Don't add inner spin button width to the preferred text field width.
2602           Text fields should have the identical widths regardless of the
2603           existence of spin buttons.
2604
2605         Test: fast/forms/input-widths.html
2606
2607         * css/themeWin.css:
2608         (input[type="week"]):
2609         (input[type="week"]:disabled):
2610         (input[type="search"]::-webkit-search-cancel-button):
2611         (input::-webkit-outer-spin-button):
2612         * rendering/RenderTextControlSingleLine.cpp:
2613         (WebCore::RenderTextControlSingleLine::preferredContentWidth):
2614         Don't add inner spin button width to the preferred width.
2615
2616 2011-01-24  Kent Tamura  <tkent@chromium.org>
2617
2618         Reviewed by Dimitri Glazkov.
2619
2620         Some bugs of search cancel button and spin button about state change in
2621         an event handler.
2622         https://bugs.webkit.org/show_bug.cgi?id=46950
2623
2624         Fix the following problems:
2625          * Type=search field didn't release event capturing
2626          * Assertion failure when an input field with spin buttons was changed
2627            to another type on focus event.
2628          * A input field with spin button didn't release event capturing when it
2629            was changed to another type on focus event.
2630
2631         Tests: fast/forms/input-number-change-type-on-focus.html
2632                fast/forms/search-hide-cancel-on-cancel.html
2633
2634         * rendering/TextControlInnerElements.cpp:
2635         (WebCore::SearchFieldCancelButtonElement::defaultEventHandler):
2636          - Make the variable 'input' RefPtr.  It makes the code simpler.
2637          - Remove visibility check on mouseup event. We should release capturing
2638            anyway because the cancel button may be invisible if JavaScript code
2639            called by the focus event removes the input value.
2640         (WebCore::SpinButtonElement::detach):
2641          - Release capturing on detach because it is possible that a spin button
2642            node is detached while it is capturing events.
2643         (WebCore::SpinButtonElement::defaultEventHandler):
2644           Take a reference to this and check renderer() after some functions which
2645           may run JavaScript code.
2646         (WebCore::InputFieldSpeechButtonElement::defaultEventHandler):
2647           Make the variable 'input' RefPtr to align other functions in this file.
2648         (WebCore::InputFieldSpeechButtonElement::setRecognitionResult): ditto.
2649         * rendering/TextControlInnerElements.h: Declare SpinButtonElement::detach().
2650
2651 2011-01-24  Ryosuke Niwa  <rniwa@webkit.org>
2652
2653         Reviewed by Ojan Vafai.
2654
2655         Inserting multiple whitespace using text composition (IME) should insert interleaved nbsp and whitespace.
2656         https://bugs.webkit.org/show_bug.cgi?id=52781
2657
2658         The bug was caused by stringWithRebalancedWhitespace's replacing the space at the beginning of a paragraph
2659         and the end of a paragraph by a non-breaking space after it replaced two consecutive spaces by a space and
2660         non-breaking space pattern, thereby replacing more spaces by non-breaking spaces than needed.
2661
2662         Rewrote the function using Vector<UChar> to fix the bug. New function no longer calls String::replace
2663         multiple times but instead it traverses through the string and replaces a space that immediately follows
2664         another space or appears at the beginning of a paragraph or at the end of a paragraph by a non-break space.
2665
2666         * editing/CompositeEditCommand.cpp:
2667         * editing/htmlediting.cpp:
2668         (WebCore::stringWithRebalancedWhitespace): Written.
2669         * editing/htmlediting.h:
2670         (WebCore::isWhitespace): Removed from CompositeEditCommand.cpp
2671
2672 2011-01-24  Kenneth Russell  <kbr@google.com>
2673
2674         Reviewed by James Robinson.
2675
2676         Web Audio API: port FFTFrame to FFTW
2677         https://bugs.webkit.org/show_bug.cgi?id=52989
2678
2679         Ported FFTFrame class to the open-source FFTW library. Tested with
2680         unit tests from Chris Rogers. Made preliminary changes to GYP
2681         files for conditional compilation of these files; will need to be
2682         adjusted once FFTW is integrated as third-party source.
2683
2684         * WebCore.gyp/WebCore.gyp:
2685         * WebCore.gypi:
2686         * platform/audio/FFTFrame.h:
2687         * platform/audio/fftw: Added.
2688         * platform/audio/fftw/FFTFrameFFTW.cpp: Added.
2689         (WebCore::FFTFrame::FFTFrame):
2690         (WebCore::FFTFrame::~FFTFrame):
2691         (WebCore::FFTFrame::multiply):
2692         (WebCore::FFTFrame::doFFT):
2693         (WebCore::FFTFrame::doInverseFFT):
2694         (WebCore::FFTFrame::cleanup):
2695         (WebCore::FFTFrame::realData):
2696         (WebCore::FFTFrame::imagData):
2697         (WebCore::FFTFrame::fftwPlanForSize):
2698
2699 2011-01-24  Anders Carlsson  <andersca@apple.com>
2700
2701         Reviewed by Dan Bernstein.
2702
2703         Reset the page scale factor on standard frame loads
2704         https://bugs.webkit.org/show_bug.cgi?id=53058
2705         <rdar://problem/8908844>
2706
2707         Add a symbol needed by WebKit2.
2708
2709         * WebCore.exp.in:
2710
2711 2011-01-24  Ryosuke Niwa  <rniwa@webkit.org>
2712
2713         Reviewed by Eric Seidel.
2714
2715         Stop instantiating legacy editing positions in InsertTextCommand, MoveSelectionCommand,
2716         ReplaceSelectionCommand, SelectionController, SpellChecker, TypingCommand, and markup.cpp
2717         https://bugs.webkit.org/show_bug.cgi?id=52676
2718
2719         Stop instantiating legacy editing positions in the following files.
2720
2721         * editing/InsertTextCommand.cpp:
2722         (WebCore::InsertTextCommand::prepareForTextInsertion):
2723         (WebCore::InsertTextCommand::performTrivialReplace):
2724         (WebCore::InsertTextCommand::input):
2725         (WebCore::InsertTextCommand::insertTab):
2726         * editing/MoveSelectionCommand.cpp:
2727         (WebCore::MoveSelectionCommand::doApply):
2728         * editing/ReplaceSelectionCommand.cpp:
2729         (WebCore::ReplaceSelectionCommand::removeUnrenderedTextNodesAtEnds):
2730         (WebCore::ReplaceSelectionCommand::mergeEndIfNeeded):
2731         (WebCore::ReplaceSelectionCommand::doApply):
2732         (WebCore::ReplaceSelectionCommand::shouldRemoveEndBR):
2733         (WebCore::ReplaceSelectionCommand::performTrivialReplace):
2734         * editing/SelectionController.cpp:
2735         (WebCore::SelectionController::setSelectionFromNone):
2736         * editing/SpellChecker.cpp:
2737         (WebCore::SpellChecker::didCheck):
2738         * editing/TypingCommand.cpp:
2739         (WebCore::TypingCommand::makeEditableRootEmpty):
2740         (WebCore::TypingCommand::deleteKeyPressed):
2741         (WebCore::TypingCommand::forwardDeleteKeyPressed):
2742         * editing/markup.cpp:
2743         (WebCore::StyledMarkupAccumulator::appendText):
2744         (WebCore::StyledMarkupAccumulator::serializeNodes):
2745         (WebCore::highestAncestorToWrapMarkup):
2746         (WebCore::createMarkup):
2747
2748 2011-01-24  Peter Kasting  <pkasting@google.com>
2749
2750         Reviewed by Darin Adler.
2751
2752         Roll back r67261 ("Don't fire onclick on middle clicks") due to
2753         regressions.
2754         https://bugs.webkit.org/show_bug.cgi?id=46733
2755
2756         * html/HTMLAnchorElement.cpp:
2757         (WebCore::isLinkClick):
2758         * html/HTMLInputElement.cpp:
2759         (WebCore::HTMLInputElement::preDispatchEventHandler):
2760         (WebCore::HTMLInputElement::postDispatchEventHandler):
2761         (WebCore::HTMLInputElement::defaultEventHandler):
2762         * page/EventHandler.cpp:
2763         (WebCore::EventHandler::handleMouseDoubleClickEvent):
2764         (WebCore::EventHandler::handleMouseReleaseEvent):
2765
2766 2011-01-24  Martin Robinson  <mrobinson@igalia.com>
2767
2768         Reviewed by Eric Seidel.
2769
2770         [GTK] Many DOM XHTML tests time out
2771         https://bugs.webkit.org/show_bug.cgi?id=52553
2772
2773         Properly handle the situation where a synchronous load fails before the inner
2774         event loop has started. In this case, we simply do not run the inner event loop,
2775         or else it will block indefinitely (since no GIO or libsoup callbacks will fire).
2776
2777         * platform/network/soup/ResourceHandleSoup.cpp:
2778         (WebCore::ResourceHandle::loadResourceSynchronously): Bail out of a synchronous
2779         load if it fails up front.
2780
2781 2011-01-24  Zhenyao Mo  <zmo@google.com>
2782
2783         Reviewed by Eric Seidel.
2784
2785         Cleanup WebGLGetInfo and related get*Parameter helpers in WebGLRenderingContext
2786         https://bugs.webkit.org/show_bug.cgi?id=52338
2787
2788         Removed the long/unsigned long types and corresponding get functions
2789         and use int/unsigned int instead.
2790
2791         * bindings/js/JSWebGLRenderingContextCustom.cpp:
2792         (WebCore::toJS):
2793         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
2794         (WebCore::toV8Object):
2795         * html/canvas/WebGLGetInfo.cpp:
2796         (WebCore::WebGLGetInfo::WebGLGetInfo):
2797         (WebCore::WebGLGetInfo::getInt):
2798         (WebCore::WebGLGetInfo::getUnsignedInt):
2799         * html/canvas/WebGLGetInfo.h:
2800         * html/canvas/WebGLRenderingContext.cpp:
2801         (WebCore::WebGLRenderingContext::getBufferParameter):
2802         (WebCore::WebGLRenderingContext::getFramebufferAttachmentParameter):
2803         (WebCore::WebGLRenderingContext::getParameter):
2804         (WebCore::WebGLRenderingContext::getProgramParameter):
2805         (WebCore::WebGLRenderingContext::getRenderbufferParameter):
2806         (WebCore::WebGLRenderingContext::getShaderParameter):
2807         (WebCore::WebGLRenderingContext::getTexParameter):
2808         (WebCore::WebGLRenderingContext::getUniform):
2809         (WebCore::WebGLRenderingContext::getVertexAttrib):
2810         (WebCore::WebGLRenderingContext::getIntParameter):
2811         (WebCore::WebGLRenderingContext::getUnsignedIntParameter):
2812         * html/canvas/WebGLRenderingContext.h:
2813
2814 2011-01-24  Zhenyao Mo  <zmo@google.com>
2815
2816         Reviewed by Darin Adler.
2817
2818         Remove sizeInBytes from GraphicsContext3D's various implementations
2819         https://bugs.webkit.org/show_bug.cgi?id=52339
2820
2821         * html/canvas/WebGLRenderingContext.cpp:
2822         (WebCore::WebGLRenderingContext::sizeInBytes):
2823         * platform/graphics/GraphicsContext3D.h:
2824         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
2825         * platform/graphics/qt/GraphicsContext3DQt.cpp:
2826
2827 2011-01-24  Adam Roben  <aroben@apple.com>
2828
2829         Windows Production build fix
2830
2831         * WebCore.vcproj/WebCore.make: Update for move of WebCore into Source.
2832
2833 2011-01-24  Anton Muhin  <antonm@chromium.org>
2834
2835         Reviewed by Nate Chapin.
2836
2837         [v8] Refactoring: extract IntrusiveDOMWrapperMap into a seprate class and files.
2838         https://bugs.webkit.org/show_bug.cgi?id=52911
2839
2840         Plain refactoring, covered by the existing tests.
2841
2842         * WebCore.gypi: IntrusiveDOMWrapperMap.h added.
2843         * bindings/v8/DOMDataStore.cpp: IntrusiveDOMWrapperMap is moved out of DOMDataStore class.
2844         * bindings/v8/DOMDataStore.h: IntrusiveDOMWrapperMap is moved out of DOMDataStore class.
2845         * bindings/v8/IntrusiveDOMWrapperMap.h: Added.
2846         (WebCore::ChunkedTable::ChunkedTable):
2847         (WebCore::ChunkedTable::add):
2848         (WebCore::ChunkedTable::remove):
2849         (WebCore::ChunkedTable::clear):
2850         (WebCore::ChunkedTable::visit):
2851         (WebCore::ChunkedTable::Chunk::Chunk):
2852         (WebCore::ChunkedTable::clearEntries):
2853         (WebCore::ChunkedTable::visitEntries):
2854         (WebCore::IntrusiveDOMWrapperMap::IntrusiveDOMWrapperMap):
2855         (WebCore::IntrusiveDOMWrapperMap::get):
2856         (WebCore::IntrusiveDOMWrapperMap::set):
2857         (WebCore::IntrusiveDOMWrapperMap::contains):
2858         (WebCore::IntrusiveDOMWrapperMap::visit):
2859         (WebCore::IntrusiveDOMWrapperMap::removeIfPresent):
2860         (WebCore::IntrusiveDOMWrapperMap::clear):
2861         (WebCore::IntrusiveDOMWrapperMap::ChunkedTableTraits::move):
2862         (WebCore::IntrusiveDOMWrapperMap::ChunkedTableTraits::clear):
2863         (WebCore::IntrusiveDOMWrapperMap::ChunkedTableTraits::visit):
2864         * bindings/v8/StaticDOMDataStore.h: include added.
2865
2866 2011-01-24  Shane Stephens  <shanestephens@google.com>
2867
2868         Reviewed by Chris Marrin.
2869
2870         TransformationMatrix multiply operations apply operands in wrong order.
2871         https://bugs.webkit.org/show_bug.cgi?id=52780
2872
2873         Rename TranformationMatrix::multLeft into multiply (the method does a multRight,
2874         not a multLeft).
2875
2876         Remove TransformationMatrix::multiply, which was actually doing a multLeft.
2877
2878         Fix TransformationMatrix::operator* and operator*= such that the operand is
2879         applied to the right-hand side of the matrix that the method is called on.
2880         i.e., previously "a * b" used to compute "b * a", and "a *= b" used to store
2881         "b * a" in "a".  This has now been fixed so "a * b" computes "a * b" and
2882         "a *= b" stores "a * b" in "a".
2883
2884         Convert all call sites for these methods to provide operands in the correct order.
2885
2886         No new tests as patch adds no new functionality.
2887
2888         * css/WebKitCSSMatrix.cpp:
2889         (WebCore::WebKitCSSMatrix::multiply):
2890         * platform/graphics/transforms/Matrix3DTransformOperation.h:
2891         (WebCore::Matrix3DTransformOperation::apply):
2892         * platform/graphics/transforms/MatrixTransformOperation.h:
2893         (WebCore::MatrixTransformOperation::apply):
2894         * platform/graphics/transforms/TransformationMatrix.cpp:
2895         (WebCore::TransformationMatrix::scaleNonUniform):
2896         (WebCore::TransformationMatrix::scale3d):
2897         (WebCore::TransformationMatrix::rotate3d):
2898         (WebCore::TransformationMatrix::skew):
2899         (WebCore::TransformationMatrix::applyPerspective):
2900         (WebCore::TransformationMatrix::multiply):
2901         (WebCore::TransformationMatrix::recompose):
2902         * platform/graphics/transforms/TransformationMatrix.h:
2903         (WebCore::TransformationMatrix::operator*=):
2904         (WebCore::TransformationMatrix::operator*):
2905         * rendering/RenderLayer.cpp:
2906         (WebCore::transparencyClipBox):
2907         * rendering/RenderObject.cpp:
2908         (WebCore::RenderObject::getTransformFromContainer):
2909         * rendering/TransformState.cpp:
2910         (WebCore::TransformState::applyTransform):
2911         (WebCore::HitTestingTransformState::applyTransform):
2912
2913 2011-01-24  Andrei Popescu  <andreip@google.com>
2914
2915         Reviewed by Nate Chapin.
2916
2917         IndexedDatabase methods should not take arguments of type OptionsObject
2918         https://bugs.webkit.org/show_bug.cgi?id=53012
2919
2920         This patch reverts all IDB methods, except IDBDatabase::createObjectStore and
2921         IDBObjectStore::createIndex, to using a plain list of arguments instead of
2922         grouping the various parameters inside a single OptionsObject argument.
2923         This decision was made on public-webapps@w3.org mailing list.
2924
2925         We also add support (v8 only for now) for passing DOMStringList objects as arguments to native
2926         methods. The code for obtaining a DOMStringList object from a JS array of strings existed already
2927         in OptionsObject.cpp, I just copied it to V8Bindings.cpp and taught the v8 code generator how to
2928         use it.
2929
2930         * bindings/scripts/CodeGeneratorV8.pm:
2931         * bindings/v8/V8Binding.cpp:
2932         (WebCore::v8ValueToWebCoreDOMStringList):
2933         * bindings/v8/V8Binding.h:
2934         * storage/IDBDatabase.cpp:
2935         (WebCore::IDBDatabase::transaction):
2936         * storage/IDBDatabase.h:
2937         (WebCore::IDBDatabase::transaction):
2938         * storage/IDBDatabase.idl:
2939         * storage/IDBIndex.cpp:
2940         (WebCore::IDBIndex::openCursor):
2941         (WebCore::IDBIndex::openKeyCursor):
2942         * storage/IDBIndex.h:
2943         (WebCore::IDBIndex::openCursor):
2944         (WebCore::IDBIndex::openKeyCursor):
2945         * storage/IDBIndex.idl:
2946         * storage/IDBObjectStore.cpp:
2947         (WebCore::IDBObjectStore::openCursor):
2948         * storage/IDBObjectStore.h:
2949         (WebCore::IDBObjectStore::openCursor):
2950         * storage/IDBObjectStore.idl:
2951
2952 2011-01-24  Pavel Feldman  <pfeldman@chromium.org>
2953
2954         Reviewed by Yury Semikhatsky.
2955
2956         Web Inspector: extract dispatch API from network manager.
2957         https://bugs.webkit.org/show_bug.cgi?id=53009
2958
2959         * WebCore.xcodeproj/project.pbxproj:
2960         * inspector/front-end/NetworkManager.js:
2961         (WebInspector.NetworkManager):
2962         (WebInspector.NetworkManager.prototype.reset):
2963         (WebInspector.NetworkManager.prototype.requestContent):
2964         (WebInspector.NetworkManager.prototype._processCachedResources):
2965         (WebInspector.NetworkDispatcher):
2966         (WebInspector.NetworkDispatcher.prototype._updateResourceWithRequest):
2967         (WebInspector.NetworkDispatcher.prototype._updateResourceWithResponse):
2968         (WebInspector.NetworkDispatcher.prototype._updateResourceWithCachedResource):
2969         (WebInspector.NetworkDispatcher.prototype.identifierForInitialRequest):
2970         (WebInspector.NetworkDispatcher.prototype.willSendRequest):
2971         (WebInspector.NetworkDispatcher.prototype.didReceiveResponse):
2972         (WebInspector.NetworkDispatcher.prototype.didLoadResourceFromMemoryCache):
2973         (WebInspector.NetworkDispatcher.prototype.didCommitLoadForFrame):
2974         (WebInspector.NetworkDispatcher.prototype.didCreateWebSocket):
2975         (WebInspector.NetworkDispatcher.prototype._appendRedirect):
2976         (WebInspector.NetworkDispatcher.prototype._startResource):
2977         (WebInspector.NetworkDispatcher.prototype._updateResource):
2978         (WebInspector.NetworkDispatcher.prototype._finishResource):
2979         (WebInspector.NetworkDispatcher.prototype._addFramesRecursively):
2980         (WebInspector.NetworkDispatcher.prototype._dispatchEventToListeners):
2981         (WebInspector.NetworkDispatcher.prototype._createResource):
2982         * inspector/front-end/Resource.js:
2983         (WebInspector.Resource.prototype._innerRequestContent):
2984         * inspector/front-end/ResourceTreeModel.js:
2985         (WebInspector.ResourceTreeModel):
2986         (WebInspector.ResourceTreeModel.prototype.reset):
2987         (WebInspector.ResourceTreeModel.prototype.unbindResourceURL):
2988
2989 2011-01-24  Yury Semikhatsky  <yurys@chromium.org>
2990
2991         Reviewed by Pavel Feldman.
2992
2993         Web Inspector: [JSC] remove ScriptDebugServer::pageCreated
2994         https://bugs.webkit.org/show_bug.cgi?id=53007
2995
2996         It's impossible to create "provisional" inspector for pages which are
2997         not yet created so there is no need to listen for page creation in ScriptDebugServer.
2998
2999         * bindings/js/ScriptDebugServer.cpp:
3000         * bindings/js/ScriptDebugServer.h:
3001         * page/Page.cpp:
3002         (WebCore::Page::Page):
3003
3004 2011-01-24  Pavel Podivilov  <podivilov@chromium.org>
3005
3006         Reviewed by Pavel Feldman.
3007
3008         Web Inspector: [REGRESSION] AppCache view on resources panel is broken.
3009         https://bugs.webkit.org/show_bug.cgi?id=53002
3010
3011
3012         * inspector/front-end/ApplicationCacheItemsView.js:
3013         (WebInspector.ApplicationCacheItemsView.prototype._update):
3014         * inspector/front-end/DOMAgent.js:
3015         (WebInspector.ApplicationCacheDispatcher.getApplicationCachesAsync):
3016
3017 2011-01-24  Andreas Kling  <kling@webkit.org>
3018
3019         Reviewed by Kenneth Rohde Christiansen.
3020
3021         [Qt] Fix warnings about unregistering an invalid timer
3022         https://bugs.webkit.org/show_bug.cgi?id=53006
3023
3024         The ShadowBuffer's purge timer ID was initialized with 0 which lead
3025         to us calling QObject::killTimer(0), causing some qWarnings.
3026
3027         * platform/graphics/qt/ContextShadowQt.cpp:
3028         (WebCore::ShadowBuffer::ShadowBuffer):
3029         (WebCore::ShadowBuffer::schedulePurge):
3030
3031 2011-01-21  Mikhail Naganov  <mnaganov@chromium.org>
3032
3033         Reviewed by Pavel Feldman.
3034
3035         Web Inspector: [Chromium] Fix heap snapshot table sorting.
3036
3037         Fix table sorting to avoid qsort instability artefacts.
3038
3039         https://bugs.webkit.org/show_bug.cgi?id=52914
3040
3041         * inspector/front-end/HeapSnapshotView.js:
3042         (WebInspector.HeapSnapshotView.prototype._sortData):
3043         (WebInspector.HeapSnapshotDataGridList.propertyComparator.comparator):
3044         (WebInspector.HeapSnapshotDataGridList.propertyComparator):
3045
3046 2011-01-24  Mikhail Naganov  <mnaganov@chromium.org>
3047
3048         Reviewed by Yury Semikhatsky.
3049
3050         Web Inspector: Find duplicate strings in localizedStrings.js, update it.
3051
3052         https://bugs.webkit.org/show_bug.cgi?id=53005
3053
3054         * English.lproj/localizedStrings.js:
3055
3056 2011-01-24  Pavel Podivilov  <podivilov@chromium.org>
3057
3058         Unreviewed, build fix  for r76509.
3059
3060         * inspector/InspectorDebuggerAgent.cpp:
3061         (WebCore::InspectorDebuggerAgent::setBreakpoint):
3062
3063 2011-01-24  Pavel Podivilov  <podivilov@chromium.org>
3064
3065         Unreviewed, build fix  for r76509.
3066
3067         * bindings/js/ScriptDebugServer.h:
3068
3069 2011-01-24  Pavel Podivilov  <podivilov@chromium.org>
3070
3071         Reviewed by Yury Semikhatsky.
3072
3073         Web Inspector: set breakpoints by line:column.
3074         https://bugs.webkit.org/show_bug.cgi?id=52615
3075
3076         * CMakeLists.txt:
3077         * GNUmakefile.am:
3078         * WebCore.gypi:
3079         * WebCore.pro:
3080         * WebCore.vcproj/WebCore.vcproj:
3081         * WebCore.xcodeproj/project.pbxproj:
3082         * bindings/js/ScriptDebugServer.cpp:
3083         (WebCore::ScriptDebugServer::setBreakpoint):
3084         (WebCore::ScriptDebugServer::removeBreakpoint):
3085         (WebCore::ScriptDebugServer::hasBreakpoint):
3086         (WebCore::ScriptDebugServer::clearBreakpoints):
3087         * bindings/js/ScriptDebugServer.h:
3088         * bindings/v8/DebuggerScript.js:
3089         ():
3090         * bindings/v8/ScriptDebugServer.cpp:
3091         (WebCore::ScriptDebugServer::setBreakpoint):
3092         * bindings/v8/ScriptDebugServer.h:
3093         * inspector/Inspector.idl:
3094         * inspector/InspectorBrowserDebuggerAgent.cpp:
3095         (WebCore::InspectorBrowserDebuggerAgent::restoreStickyBreakpoint):
3096         * inspector/InspectorDebuggerAgent.cpp:
3097         (WebCore::InspectorDebuggerAgent::setStickyBreakpoint):
3098         (WebCore::InspectorDebuggerAgent::setBreakpoint):
3099         (WebCore::InspectorDebuggerAgent::restoreBreakpoint):
3100         (WebCore::InspectorDebuggerAgent::didParseSource):
3101         * inspector/InspectorDebuggerAgent.h:
3102         * inspector/ScriptBreakpoint.cpp: Removed.
3103         * inspector/ScriptBreakpoint.h:
3104         (WebCore::ScriptBreakpoint::ScriptBreakpoint):
3105         * inspector/front-end/Breakpoint.js:
3106         (WebInspector.Breakpoint):
3107         (WebInspector.Breakpoint.prototype.get url):
3108         * inspector/front-end/BreakpointManager.js:
3109         (WebInspector.JavaScriptBreakpoint.prototype._serializeToJSON):
3110         * inspector/front-end/DebuggerModel.js:
3111         (WebInspector.DebuggerModel.prototype.continueToLine):
3112         (WebInspector.DebuggerModel.prototype.setBreakpoint):
3113         (WebInspector.DebuggerModel.prototype._breakpointSetOnBackend):
3114         (WebInspector.DebuggerDispatcher.prototype.breakpointResolved):
3115
3116 2011-01-24  Peter Beverloo  <peter@chromium.org>
3117
3118         Reviewed by Pavel Feldman.
3119
3120         Web Inspector: recognize application/x-font-woff as a valid mime-type.
3121         https://bugs.webkit.org/show_bug.cgi?id=52977
3122
3123         No new tests.
3124
3125         * inspector/front-end/inspector.js:
3126
3127 2011-01-24  Pavel Podivilov  <podivilov@chromium.org>
3128
3129         Unreviewed, fix for r76497.
3130
3131         * inspector/front-end/ResourcesPanel.js:
3132         (WebInspector.ResourcesPanel.prototype.show):
3133
3134 2011-01-24  Andreas Kling  <kling@webkit.org>
3135
3136         Reviewed by Tor Arne Vestbø.
3137
3138         [Qt] Use rad2deg() from WTF instead of rolling our own.
3139         https://bugs.webkit.org/show_bug.cgi?id=52993
3140
3141         * platform/graphics/qt/GraphicsContextQt.cpp:
3142         (WebCore::GraphicsContext::rotate):
3143         * platform/graphics/qt/PathQt.cpp:
3144         (WebCore::Path::addArc):
3145
3146 2011-01-24  Sergio Villar Senin  <svillar@igalia.com>
3147
3148         Reviewed by Martin Robinson.
3149
3150         [Gtk] ResourceHandleSoup: do not wait for streams to close to issue didFinishLoading
3151         https://bugs.webkit.org/show_bug.cgi?id=52885
3152
3153         No new tests as it does not change functionality. We will not wait for
3154         the the input stream to close to issue didFinishLoading to
3155         WebCore. We expect a subtle performance improvement with this
3156         patch when loading complex web pages, as we wouldn't have to wait
3157         for the stream to close (which involves creating a thread among
3158         other things).
3159
3160         * platform/network/soup/ResourceHandleSoup.cpp:
3161         (WebCore::closeCallback):
3162         (WebCore::readCallback):
3163
3164 2011-01-21  Pavel Podivilov  <podivilov@chromium.org>
3165
3166         Reviewed by Pavel Feldman.
3167
3168         Web Inspector: eliminate SourceView and ScriptView classes.
3169         https://bugs.webkit.org/show_bug.cgi?id=52896
3170
3171         SourceView and ScriptView delegate everything to SourceFrame and should be eliminated.
3172
3173         * WebCore.gypi:
3174         * WebCore.vcproj/WebCore.vcproj:
3175         * inspector/front-end/GoToLineDialog.js:
3176         (WebInspector.GoToLineDialog.prototype._highlightSelectedLine):
3177         * inspector/front-end/ResourceView.js:
3178         (WebInspector.ResourceView.createResourceView):
3179         (WebInspector.ResourceView.resourceViewTypeMatchesResource):
3180         (WebInspector.SourceFrameContentProviderForResource):  Moved from SourceView.
3181         * inspector/front-end/ResourcesPanel.js:
3182         (WebInspector.ResourcesPanel.prototype.show):
3183         (WebInspector.ResourcesPanel.prototype._applyDiffMarkup):
3184         (WebInspector.FrameResourceTreeElement.prototype._errorsWarningsUpdated):
3185         * inspector/front-end/ScriptView.js: Removed.
3186         * inspector/front-end/ScriptsPanel.js:
3187         (WebInspector.ScriptsPanel.prototype._scriptSourceChanged):
3188         (WebInspector.ScriptsPanel.prototype._sourceFrameForScriptOrResource):
3189         (WebInspector.ScriptsPanel.prototype._showScriptOrResource):
3190         (WebInspector.ScriptsPanel.prototype._setPauseOnExceptions):
3191         (WebInspector.ScriptsPanel.prototype._formatScript):
3192         (WebInspector.SourceFrameContentProviderForScript): Moved from ScriptView.
3193         * inspector/front-end/SourceFrame.js:
3194         (WebInspector.SourceFrame):
3195         (WebInspector.SourceFrame.prototype.show):
3196         (WebInspector.SourceFrame.prototype.hide):
3197         (WebInspector.SourceFrame.prototype.hasContent):
3198         (WebInspector.SourceFrame.prototype._createTextViewer):
3199         (WebInspector.SourceFrame.prototype.performSearch.doFindSearchMatches):
3200         (WebInspector.SourceFrame.prototype.performSearch):
3201         * inspector/front-end/SourceView.js: Removed.
3202         * inspector/front-end/WebKit.qrc:
3203         * inspector/front-end/inspector.html:
3204
3205 2011-01-24  Andras Becsi  <abecsi@webkit.org>
3206
3207         Reviewed by Csaba Osztrogonác.
3208
3209         [Qt] Move project files into Source
3210         https://bugs.webkit.org/show_bug.cgi?id=52891
3211
3212         No new tests needed.
3213
3214         * WebCore.pri:
3215         * WebCore.pro:
3216
3217 2011-01-24  Kent Tamura  <tkent@chromium.org>
3218
3219         Unreviewed, trivial fix.
3220
3221         Fix a Chromium-only assertion failure by r76491.
3222         https://bugs.webkit.org/show_bug.cgi?id=38982
3223
3224         Separate icon loading from the FileChooser constructor in order to avoid
3225         ref() before adoptRef().
3226
3227         * platform/FileChooser.cpp:
3228         (WebCore::FileChooser::FileChooser):
3229         (WebCore::FileChooser::initialize):
3230         (WebCore::FileChooser::create):
3231         * platform/FileChooser.h:
3232
3233 2011-01-24  MORITA Hajime  <morrita@google.com>
3234
3235         Reviewed by Kent Tamura.
3236
3237         TextControlInnerElement::m_shadowParent should be removed.
3238         https://bugs.webkit.org/show_bug.cgi?id=52998
3239
3240         No new tests. No behavioral change.
3241
3242         * rendering/TextControlInnerElements.cpp:
3243         (WebCore::TextControlInnerElement::TextControlInnerElement):
3244         * rendering/TextControlInnerElements.h:
3245
3246 2011-01-24  Yury Semikhatsky  <yurys@chromium.org>
3247
3248         Reviewed by Pavel Feldman.
3249
3250         REGRESSION (r72895): console.trace crashes
3251         https://bugs.webkit.org/show_bug.cgi?id=52981
3252
3253         - Use local RefPtr variable for accessing PassRefPtr arguments to make sure the PassRefPtr has
3254         non-null value.
3255         - Use PassRefPtr for objects whos ownership is passed to the inspector.
3256
3257         * GNUmakefile.am:
3258         * WebCore.gypi:
3259         * WebCore.pro:
3260         * WebCore.vcproj/WebCore.vcproj:
3261         * WebCore.xcodeproj/project.pbxproj:
3262         * inspector/InspectorConsoleInstrumentation.h: Added. Extract inline methods called from the console into their
3263         own header to reduce compilation time of other classes that depend on the inspector instrumentation.
3264         (WebCore::InspectorInstrumentation::addMessageToConsole):
3265         (WebCore::InspectorInstrumentation::consoleCount):
3266         (WebCore::InspectorInstrumentation::startConsoleTiming):
3267         (WebCore::InspectorInstrumentation::stopConsoleTiming):
3268         (WebCore::InspectorInstrumentation::consoleMarkTimeline):
3269         (WebCore::InspectorInstrumentation::addStartProfilingMessageToConsole):
3270         (WebCore::InspectorInstrumentation::addProfile):
3271         (WebCore::InspectorInstrumentation::profilerEnabled):
3272         (WebCore::InspectorInstrumentation::getCurrentUserInitiatedProfileName):
3273         * inspector/InspectorDatabaseInstrumentation.h: Added. Extract inline methods called from the datanase code into their
3274         own header to reduce compilation time of other classes that depend on the inspector instrumentation.
3275         (WebCore::InspectorInstrumentation::didOpenDatabase):
3276         * inspector/InspectorInstrumentation.cpp:
3277         (WebCore::InspectorInstrumentation::addMessageToConsoleImpl):
3278         (WebCore::InspectorInstrumentation::consoleCountImpl):
3279         (WebCore::InspectorInstrumentation::stopConsoleTimingImpl):
3280         (WebCore::InspectorInstrumentation::consoleMarkTimelineImpl):
3281         (WebCore::InspectorInstrumentation::addProfileImpl):
3282         (WebCore::InspectorInstrumentation::didOpenDatabaseImpl):
3283         * inspector/InspectorInstrumentation.h:
3284         * page/Console.cpp: use RefPtr local variable instead of accessing PassRefPtr argument directly.
3285         (WebCore::Console::addMessage):
3286         (WebCore::Console::trace):
3287         (WebCore::Console::count):
3288         (WebCore::Console::markTimeline):
3289         (WebCore::Console::profileEnd):
3290         (WebCore::Console::timeEnd):
3291         (WebCore::Console::group):
3292         (WebCore::Console::groupCollapsed):
3293         * storage/Database.cpp:
3294         (WebCore::Database::openDatabase):
3295
3296 2010-01-24  Kent Tamura  <tkent@chromium.org>
3297
3298         Reviewed by Darin Fisher.
3299
3300         [Chromium] Support icon loading for <input type=file>
3301         https://bugs.webkit.org/show_bug.cgi?id=38982
3302
3303         An icon data in Chromium port is represented as WebCore::Image. We
3304         don't need OS-specific code anymore.
3305
3306         * WebCore.gypi:
3307         * platform/graphics/Icon.h:
3308         (WebCore::Icon::create): Add Chromium-specific factory.
3309         * platform/graphics/chromium/IconChromium.cpp: Added.
3310         * platform/graphics/chromium/IconChromiumLinux.cpp: Removed.
3311         * platform/graphics/chromium/IconChromiumMac.cpp: Removed.
3312         * platform/graphics/chromium/IconChromiumWin.cpp: Removed.
3313         * platform/graphics/chromium/PlatformIcon.h:
3314
3315 2011-01-21  Pavel Podivilov  <podivilov@chromium.org>
3316
3317         Reviewed by Pavel Feldman.
3318
3319         Web Inspector: move search functions from SourceView to SourceFrame.
3320         https://bugs.webkit.org/show_bug.cgi?id=52895
3321
3322         This is the last step before eliminating SourceView and ScriptView since
3323         this classes just delegate everything to SourceFrame.
3324
3325         * inspector/front-end/SourceFrame.js:
3326         (WebInspector.SourceFrame.prototype.set visible):
3327         (WebInspector.SourceFrame.prototype._clearLineHighlight):
3328         (WebInspector.SourceFrame.prototype._createTextViewer):
3329         (WebInspector.SourceFrame.prototype.performSearch.doFindSearchMatches):
3330         (WebInspector.SourceFrame.prototype.performSearch):
3331         (WebInspector.SourceFrame.prototype.searchCanceled):
3332         (WebInspector.SourceFrame.prototype.jumpToFirstSearchResult):
3333         (WebInspector.SourceFrame.prototype.jumpToLastSearchResult):
3334         (WebInspector.SourceFrame.prototype.jumpToNextSearchResult):
3335         (WebInspector.SourceFrame.prototype.jumpToPreviousSearchResult):
3336         (WebInspector.SourceFrame.prototype.showingFirstSearchResult):
3337         (WebInspector.SourceFrame.prototype.showingLastSearchResult):
3338         (WebInspector.SourceFrame.prototype._jumpToSearchResult):
3339         * inspector/front-end/SourceView.js:
3340         (WebInspector.SourceView.prototype.hide):
3341         (WebInspector.SourceView.prototype.searchCanceled):
3342         (WebInspector.SourceView.prototype.performSearch):
3343         (WebInspector.SourceView.prototype.jumpToFirstSearchResult):
3344         (WebInspector.SourceView.prototype.jumpToLastSearchResult):
3345         (WebInspector.SourceView.prototype.jumpToNextSearchResult):
3346         (WebInspector.SourceView.prototype.jumpToPreviousSearchResult):
3347         (WebInspector.SourceView.prototype.showingFirstSearchResult):
3348         (WebInspector.SourceView.prototype.showingLastSearchResult):
3349         (WebInspector.SourceView.prototype.clearMessages):
3350
3351 2011-01-24  Sheriff Bot  <webkit.review.bot@gmail.com>
3352
3353         Unreviewed, rolling out r76463.
3354         http://trac.webkit.org/changeset/76463
3355         https://bugs.webkit.org/show_bug.cgi?id=52993
3356
3357         It broke canvas/philip/tests/2d.path.stroke.skew.html
3358         (Requested by Ossy on #webkit).
3359
3360         * platform/graphics/qt/GraphicsContextQt.cpp:
3361         (WebCore::GraphicsContext::rotate):
3362         * platform/graphics/qt/PathQt.cpp:
3363         (WebCore::Path::addArc):
3364
3365 2011-01-23  Andrey Kosyakov  <caseq@chromium.org>
3366
3367         Reviewed by Pavel Feldman.
3368
3369         Web Inspector: summary bar is not resized properly with the rest of network panel
3370         https://bugs.webkit.org/show_bug.cgi?id=52881
3371
3372         * inspector/front-end/NetworkPanel.js:
3373         (WebInspector.NetworkPanel.prototype.updateSidebarWidth):
3374         (WebInspector.NetworkPanel.prototype._positionSummaryBar):
3375         (WebInspector.NetworkPanel.prototype._toggleGridMode):
3376
3377 2011-01-19  MORITA Hajime  <morrita@google.com>
3378
3379         Reviewed by Ryosuke Niwa.
3380
3381         Space and tab characters "sent" by an input method give totally different results than typing them directly
3382         https://bugs.webkit.org/show_bug.cgi?id=5241
3383         
3384         * Introduced TextEvent::InputTypeComposition and TypingCommand::TextCompositionType to 
3385           distinguish text input which is originated by composition.
3386         * Generalized rebalanceWhitespaceAt() to rebalanceWhitespaceOnTextSubstring() to rebalancing 
3387           range of string on text node, instead of surrounding part of that.
3388
3389         Test: editing/inserting/insert-composition-whitespace.html
3390
3391         * dom/TextEvent.h:
3392         (WebCore::TextEvent::isComposition):
3393         * dom/TextEventInputType.h: Added TextEventInputComposition as a member of TextEvent::InputType
3394         * editing/CompositeEditCommand.cpp:
3395         (WebCore::containsOnlyWhitespace):
3396         (WebCore::CompositeEditCommand::shouldRebalanceLeadingWhitespaceFor):
3397         (WebCore::CompositeEditCommand::canRebalance):
3398         (WebCore::CompositeEditCommand::rebalanceWhitespaceAt):
3399         (WebCore::CompositeEditCommand::rebalanceWhitespaceOnTextSubstring): Added: A generalized version of rebalanceWhitespaceAt(), which takes a range inside Text string.
3400         * editing/CompositeEditCommand.h:
3401         * editing/Editor.cpp:
3402         (WebCore::Editor::insertTextForConfirmedComposition): Added.
3403         (WebCore::Editor::insertTextWithoutSendingTextEvent):
3404         (WebCore::Editor::confirmComposition): Now uses insertTextForConfirmedComposition().
3405         (WebCore::Editor::setComposition):
3406         * editing/Editor.h:
3407         * editing/InsertTextCommand.cpp:
3408         (WebCore::InsertTextCommand::input):
3409         * editing/InsertTextCommand.h:
3410         * editing/TypingCommand.cpp:
3411         (WebCore::TypingCommand::TypingCommand):
3412         (WebCore::TypingCommand::insertText):
3413         (WebCore::TypingCommand::insertTextRunWithoutNewlines):
3414         * editing/TypingCommand.h: Added TypingCommand::m_compositionType and TypingCommand::TextCompositionType
3415         (WebCore::TypingCommand::setCompositionType): Added.
3416         (WebCore::TypingCommand::create):
3417
3418 2011-01-23  Mark Rowe  <mrowe@apple.com>
3419
3420         Follow-up to r76477.
3421
3422         Fix the scripts that detect problematic code such as static initializers
3423         and destructors, weak vtables, inappropriate files in the framework wrappers,
3424         and public headers including private headers. These had all been broken
3425         since the projects were moved in to the Source directory as the paths to the
3426         scripts were not updated at that time.
3427
3428         Stop copying an IDL file in to the framework wrapper. Doing that doesn't even make sense.
3429
3430         * WebCore.xcodeproj/project.pbxproj:
3431
3432 2011-01-23  Mark Rowe  <mrowe@apple.com>
3433
3434         Build fix after r76459.
3435
3436         Static member variables or globals of types that have constructors or destructors are bad as
3437         they generate static initializers and destructors. This is code that is run either at link time
3438         when the library is loaded in to memory or at application termination time. Both of these are
3439         terrible for performance and are thus outlawed in WebKit code.
3440
3441         The typical solution is to replace the static member or global with a function that allocates
3442         the necessary variable on the heap. The variable is leaked to prevent it from being destroyed
3443         at application termination time. The DEFINE_STATIC_LOCAL macro wraps this in to a concise little
3444         package, but sadly fails to work in this case due to the type containing multiple template
3445         parameters.
3446         
3447         * inspector/InspectorInstrumentation.cpp:
3448         (WebCore::InspectorInstrumentation::inspectorAgents):
3449         * inspector/InspectorInstrumentation.h:
3450         (WebCore::InspectorInstrumentation::bindInspectorAgent):
3451         (WebCore::InspectorInstrumentation::unbindInspectorAgent):
3452         (WebCore::InspectorInstrumentation::inspectorAgentForPage):
3453
3454 2011-01-21  Vangelis Kokkevis  <vangelis@chromium.org>
3455
3456         Reviewed by Kenneth Russell.
3457
3458         [chromium] Add support for -webkit-mask properties to the
3459         accelerated compositing path.
3460         https://bugs.webkit.org/show_bug.cgi?id=49780
3461          
3462         Tests: Existing tests in LayoutTests/compositing/masks
3463
3464         * platform/graphics/chromium/ContentLayerChromium.cpp:
3465         (WebCore::ContentLayerChromium::draw):
3466         (WebCore::ContentLayerChromium::unreserveContentsTexture):
3467         (WebCore::ContentLayerChromium::bindContentsTexture):
3468         * platform/graphics/chromium/ContentLayerChromium.h:
3469         * platform/graphics/chromium/GraphicsLayerChromium.cpp:
3470         (WebCore::GraphicsLayerChromium::setMaskLayer):
3471         * platform/graphics/chromium/GraphicsLayerChromium.h:
3472         * platform/graphics/chromium/LayerChromium.cpp:
3473         (WebCore::LayerChromium::LayerChromium):
3474         * platform/graphics/chromium/LayerChromium.h:
3475         (WebCore::LayerChromium::setMaskLayer):
3476         (WebCore::LayerChromium::maskLayer):
3477         (WebCore::LayerChromium::unreserveContentsTexture):
3478         (WebCore::LayerChromium::bindContentsTexture):
3479         * platform/graphics/chromium/LayerRendererChromium.cpp:
3480         (WebCore::LayerRendererChromium::updateLayersRecursive):
3481         * platform/graphics/chromium/LayerTexture.cpp:
3482         (WebCore::LayerTexture::bindTexture):
3483         * platform/graphics/chromium/RenderSurfaceChromium.cpp:
3484         (WebCore::RenderSurfaceChromium::SharedValues::SharedValues):
3485         (WebCore::RenderSurfaceChromium::SharedValues::~SharedValues):
3486         (WebCore::RenderSurfaceChromium::RenderSurfaceChromium):
3487         (WebCore::RenderSurfaceChromium::draw):
3488         * platform/graphics/chromium/RenderSurfaceChromium.h:
3489         (WebCore::RenderSurfaceChromium::SharedValues::maskShaderProgram):
3490         (WebCore::RenderSurfaceChromium::SharedValues::maskShaderSamplerLocation):
3491         (WebCore::RenderSurfaceChromium::SharedValues::maskShaderMaskSamplerLocation):
3492         (WebCore::RenderSurfaceChromium::SharedValues::maskShaderMatrixLocation):
3493         (WebCore::RenderSurfaceChromium::SharedValues::maskShaderAlphaLocation):
3494
3495 2011-01-23  Patrick Gansterer  <paroga@webkit.org>
3496
3497         Reviewed by Darin Adler.
3498
3499         Use WTF::StringHasher in WebCore
3500         https://bugs.webkit.org/show_bug.cgi?id=52934
3501
3502         * loader/appcache/ApplicationCacheStorage.cpp:
3503         (WebCore::urlHostHash):
3504         * platform/LinkHash.cpp:
3505         (WebCore::visitedLinkHashInline):
3506         * platform/cf/BinaryPropertyList.cpp:
3507         (WebCore::IntegerArrayHash::hash):
3508         * platform/graphics/wx/FontPlatformDataWx.cpp:
3509         (WebCore::FontPlatformData::computeHash):
3510         * platform/network/ProtectionSpaceHash.h:
3511         (WebCore::ProtectionSpaceHash::hash):
3512
3513 2011-01-23  Patrick Gansterer  <paroga@webkit.org>
3514
3515         Reviewed by David Kilzer.
3516
3517         Add an overload to base64Encode with String output
3518         https://bugs.webkit.org/show_bug.cgi?id=50122
3519
3520         This change removes duplicated code.
3521
3522         * inspector/InspectorResourceAgent.cpp:
3523         (WebCore::InspectorResourceAgent::resourceContentBase64):
3524         * page/DOMWindow.cpp:
3525         (WebCore::DOMWindow::btoa):
3526         * platform/graphics/skia/FontCustomPlatformData.cpp:
3527         (WebCore::createUniqueFontName):
3528         * platform/graphics/win/FontCustomPlatformData.cpp:
3529         (WebCore::createUniqueFontName):
3530         * platform/graphics/wince/FontCustomPlatformData.cpp:
3531         (WebCore::createUniqueFontName):
3532         * platform/network/cf/ResourceHandleCFNet.cpp:
3533         (WebCore::encodeBasicAuthorization):
3534         * platform/network/mac/ResourceHandleMac.mm:
3535         (WebCore::encodeBasicAuthorization):
3536         * platform/text/Base64.cpp:
3537         (WebCore::base64Encode):
3538         * platform/text/Base64.h:
3539         (WebCore::base64Encode):
3540         * platform/wince/KeygenWinCE.cpp:
3541         (WebCore::WebCore::signedPublicKeyAndChallengeString):
3542
3543 2011-01-23  Patrick Gansterer  <paroga@webkit.org>
3544
3545         Reviewed by David Kilzer.
3546
3547         Add String::containsOnlyLatin1()
3548         https://bugs.webkit.org/show_bug.cgi?id=52979
3549
3550         Use String::containsOnlyLatin1() instead of isSafeToConvertCharList().
3551
3552         * page/DOMWindow.cpp:
3553         (WebCore::DOMWindow::btoa):
3554         (WebCore::DOMWindow::atob):
3555
3556 2011-01-23  Patrick Gansterer  <paroga@webkit.org>
3557
3558         Reviewed by Andreas Kling.
3559
3560         [CMake] Add missing CodeGenerator dependencies
3561         https://bugs.webkit.org/show_bug.cgi?id=52976
3562
3563         * CMakeLists.txt:
3564
3565 2011-01-23  Yael Aharon  <yael.aharon@nokia.com>
3566
3567         Reviewed by Kenneth Rohde Christiansen.
3568
3569         [Qt][Symbian] Fix --minimal build
3570         https://bugs.webkit.org/show_bug.cgi?id=52839
3571
3572         Some of the plugins' functionality is reimplemented in
3573         Symbian specific files.
3574         Some of this functionality should be compiled in even if 
3575         the guard NETSCAPE_PLUGIN_API is turned off.
3576         This patch moves that functionality out of the
3577         NETSCAPE_PLUGIN_API guard.
3578
3579         Build fix so no new tests.
3580
3581         * WebCore.pro:
3582         * plugins/symbian/PluginPackageSymbian.cpp:
3583
3584 2011-01-23  Andreas Kling  <kling@webkit.org>
3585
3586         Reviewed by Tor Arne Vestbø.
3587
3588         [Qt] Use rad2deg() from WTF instead of rolling our own.
3589
3590         * platform/graphics/qt/GraphicsContextQt.cpp:
3591         (WebCore::GraphicsContext::rotate):
3592         * platform/graphics/qt/PathQt.cpp:
3593         (WebCore::Path::addArc):
3594
3595 2011-01-23  Kenneth Rohde Christiansen <kenneth@webkit.org>
3596
3597         Reviewed by Andreas Kling.
3598
3599         Viewport meta: Always adjust device dimensions to the device pixel ratio.
3600
3601         * dom/ViewportArguments.cpp:
3602         (WebCore::computeViewportAttributes):
3603
3604 2011-01-23  Andreas Kling  <kling@webkit.org>
3605
3606         Reviewed by Kenneth Rohde Christiansen.
3607
3608         Don't scale absolute geometry specified by viewport meta tag.
3609
3610         * dom/ViewportArguments.cpp:
3611         (WebCore::computeViewportAttributes):
3612
3613 2011-01-23  Ilya Tikhonovsky  <loislo@chromium.org>
3614
3615         Unreviewed build fix.
3616
3617         Web Inspector: looks like efl doesn't regenerate InspectorBackendDispatcher.
3618
3619         Touch Inspector.idl.
3620
3621         * inspector/Inspector.idl:
3622
3623 2011-01-22  Ilya Tikhonovsky  <loislo@chromium.org>
3624
3625         Reviewed by Pavel Feldman.
3626
3627         Web Inspector: next step in splitting InspectorController.
3628
3629         Splitting InspectorController is a bit tricky process.
3630
3631         As a first step I'll do the next things:
3632         1) rename existing InspectorController to InspectorAgent;
3633         2) s/nspectorController/nspectorAgent/g everywhere in WebCore/inspector but InspectorInstrumentation;
3634         3) create a fake InspectorController derived from the InspectorAgent for the rest of WebCore and WebKit;
3635
3636         The second step is a migration of a small set of functions described in bug 52510 from InspectorAgent to InspectorController.
3637
3638         As far as the second step will have significant changes in the functions' implementation I'll do it as a separate patch.
3639
3640         https://bugs.webkit.org/show_bug.cgi?id=52955
3641
3642         * CMakeLists.txt:
3643         * GNUmakefile.am:
3644         * WebCore.exp.in:
3645         * WebCore.gypi:
3646         * WebCore.pro:
3647         * WebCore.vcproj/WebCore.vcproj:
3648         * WebCore.xcodeproj/project.pbxproj:
3649         * bindings/js/JSInjectedScriptHostCustom.cpp:
3650         (WebCore::JSInjectedScriptHost::nodeForId):
3651         (WebCore::JSInjectedScriptHost::selectDOMStorage):
3652         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
3653         (WebCore::V8InjectedScriptHost::nodeForIdCallback):
3654         * inspector/CodeGeneratorInspector.pm:
3655         * inspector/InjectedScriptHost.cpp:
3656         (WebCore::InjectedScriptHost::InjectedScriptHost):
3657         (WebCore::InjectedScriptHost::clearConsoleMessages):
3658         (WebCore::InjectedScriptHost::databaseForId):
3659         (WebCore::InjectedScriptHost::selectDatabase):
3660         (WebCore::InjectedScriptHost::selectDOMStorage):
3661         (WebCore::InjectedScriptHost::injectedScriptForMainFrame):
3662         (WebCore::InjectedScriptHost::inspectorDOMAgent):
3663         (WebCore::InjectedScriptHost::frontend):
3664         (WebCore::InjectedScriptHost::didCreateWorker):
3665         (WebCore::InjectedScriptHost::didDestroyWorker):
3666         * inspector/InjectedScriptHost.h:
3667         (WebCore::InjectedScriptHost::create):
3668         (WebCore::InjectedScriptHost::inspectorAgent):
3669         (WebCore::InjectedScriptHost::disconnectController):
3670         * inspector/InspectorAgent.cpp: Copied from Source/WebCore/inspector/InspectorController.cpp.
3671         (WebCore::InspectorAgent::InspectorAgent):
3672         (WebCore::InspectorAgent::~InspectorAgent):
3673         (WebCore::InspectorAgent::inspectedPageDestroyed):
3674         (WebCore::InspectorAgent::enabled):
3675         (WebCore::InspectorAgent::inspectorStartsAttached):
3676         (WebCore::InspectorAgent::setInspectorStartsAttached):
3677         (WebCore::InspectorAgent::setInspectorAttachedHeight):
3678         (WebCore::InspectorAgent::inspectorAttachedHeight):
3679         (WebCore::InspectorAgent::searchingForNodeInPage):
3680         (WebCore::InspectorAgent::restoreInspectorStateFromCookie):
3681         (WebCore::InspectorAgent::inspect):
3682         (WebCore::InspectorAgent::focusNode):
3683         (WebCore::InspectorAgent::highlight):
3684         (WebCore::InspectorAgent::highlightDOMNode):
3685         (WebCore::InspectorAgent::highlightFrame):
3686         (WebCore::InspectorAgent::hideHighlight):
3687         (WebCore::InspectorAgent::mouseDidMoveOverElement):
3688         (WebCore::InspectorAgent::handleMousePress):
3689         (WebCore::InspectorAgent::setInspectorFrontendClient):
3690         (WebCore::InspectorAgent::didClearWindowObjectInWorld):
3691         (WebCore::InspectorAgent::setSearchingForNode):
3692         (WebCore::InspectorAgent::connectFrontend):
3693         (WebCore::InspectorAgent::show):
3694         (WebCore::InspectorAgent::showPanel):
3695         (WebCore::InspectorAgent::close):
3696         (WebCore::InspectorAgent::disconnectFrontend):
3697         (WebCore::InspectorAgent::resourceAgent):
3698         (WebCore::InspectorAgent::releaseFrontendLifetimeAgents):
3699         (WebCore::InspectorAgent::populateScriptObjects):
3700         (WebCore::InspectorAgent::pushDataCollectedOffline):
3701         (WebCore::InspectorAgent::restoreDebugger):
3702         (WebCore::InspectorAgent::restoreProfiler):
3703         (WebCore::InspectorAgent::unbindAllResources):
3704         (WebCore::InspectorAgent::didCommitLoad):
3705         (WebCore::InspectorAgent::mainResourceFiredDOMContentEvent):
3706         (WebCore::InspectorAgent::mainResourceFiredLoadEvent):
3707         (WebCore::InspectorAgent::isMainResourceLoader):
3708         (WebCore::InspectorAgent::willSendRequest):
3709         (WebCore::InspectorAgent::ensureSettingsLoaded):
3710         (WebCore::InspectorAgent::startTimelineProfiler):
3711         (WebCore::InspectorAgent::stopTimelineProfiler):
3712         (WebCore::PostWorkerNotificationToFrontendTask::create):
3713         (WebCore::PostWorkerNotificationToFrontendTask::PostWorkerNotificationToFrontendTask):
3714         (WebCore::PostWorkerNotificationToFrontendTask::performTask):
3715         (WebCore::InspectorAgent::postWorkerNotificationToFrontend):
3716         (WebCore::InspectorAgent::didCreateWorker):
3717         (WebCore::InspectorAgent::didDestroyWorker):
3718         (WebCore::InspectorAgent::didOpenDatabase):
3719         (WebCore::InspectorAgent::getCookies):
3720         (WebCore::InspectorAgent::buildArrayForCookies):
3721         (WebCore::InspectorAgent::buildObjectForCookie):
3722         (WebCore::InspectorAgent::deleteCookie):
3723         (WebCore::InspectorAgent::didUseDOMStorage):
3724         (WebCore::InspectorAgent::didCreateWebSocket):
3725         (WebCore::InspectorAgent::willSendWebSocketHandshakeRequest):
3726         (WebCore::InspectorAgent::didReceiveWebSocketHandshakeResponse):
3727         (WebCore::InspectorAgent::didCloseWebSocket):
3728         (WebCore::InspectorAgent::isRecordingUserInitiatedProfile):
3729         (WebCore::InspectorAgent::startUserInitiatedProfiling):
3730         (WebCore::InspectorAgent::stopUserInitiatedProfiling):
3731         (WebCore::InspectorAgent::profilerEnabled):
3732         (WebCore::InspectorAgent::enableProfiler):
3733         (WebCore::InspectorAgent::disableProfiler):
3734         (WebCore::InspectorAgent::showAndEnableDebugger):
3735         (WebCore::InspectorAgent::enableDebugger):
3736         (WebCore::InspectorAgent::disableDebugger):
3737         (WebCore::InspectorAgent::resume):
3738         (WebCore::InspectorAgent::setAllBrowserBreakpoints):
3739         (WebCore::InspectorAgent::evaluateForTestInFrontend):
3740         (WebCore::InspectorAgent::didEvaluateForTestInFrontend):
3741         (WebCore::quadToPath):
3742         (WebCore::drawOutlinedQuad):
3743         (WebCore::drawOutlinedQuadWithClip):
3744         (WebCore::drawHighlightForBox):
3745         (WebCore::drawHighlightForLineBoxesOrSVGRenderer):
3746         (WebCore::convertFromFrameToMainFrame):
3747         (WebCore::frameToMainFrameOffset):
3748         (WebCore::InspectorAgent::drawNodeHighlight):
3749         (WebCore::InspectorAgent::drawElementTitle):
3750         (WebCore::InspectorAgent::openInInspectedWindow):
3751         (WebCore::InspectorAgent::addScriptToEvaluateOnLoad):
3752         (WebCore::InspectorAgent::removeAllScriptsToEvaluateOnLoad):
3753         (WebCore::InspectorAgent::setInspectorExtensionAPI):
3754         (WebCore::InspectorAgent::inspectedURL):
3755         (WebCore::InspectorAgent::reloadPage):
3756         (WebCore::InspectorAgent::setExtraHeaders):
3757         * inspector/InspectorAgent.h: Copied from Source/WebCore/inspector/InspectorController.h.
3758         (WebCore::InspectorAgent::inspectorBackendDispatcher):
3759         (WebCore::InspectorAgent::inspectorClient):
3760         (WebCore::InspectorAgent::injectedScriptHost):
3761         (WebCore::InspectorAgent::inspectedPage):
3762         (WebCore::InspectorAgent::hideDOMNodeHighlight):
3763         (WebCore::InspectorAgent::hideFrameHighlight):
3764         (WebCore::InspectorAgent::frontend):
3765         (WebCore::InspectorAgent::inspectorController):
3766         (WebCore::InspectorAgent::inspectorAgent):
3767         (WebCore::InspectorAgent::consoleAgent):
3768         (WebCore::InspectorAgent::cssAgent):
3769         (WebCore::InspectorAgent::domAgent):
3770         (WebCore::InspectorAgent::injectedScriptAgent):
3771         (WebCore::InspectorAgent::runtimeAgent):
3772         (WebCore::InspectorAgent::timelineAgent):
3773         (WebCore::InspectorAgent::databaseAgent):
3774         (WebCore::InspectorAgent::domStorageAgent):
3775         (WebCore::InspectorAgent::fileSystemAgent):
3776         (WebCore::InspectorAgent::browserDebuggerAgent):
3777         (WebCore::InspectorAgent::debuggerAgent):
3778         (WebCore::InspectorAgent::profilerAgent):
3779         (WebCore::InspectorAgent::applicationCacheAgent):
3780         (WebCore::InspectorAgent::hasInspectorFrontendClient):
3781         (WebCore::InspectorAgent::hasFrontend):
3782         (WebCore::InspectorAgent::startProfiling):
3783         (WebCore::InspectorAgent::stopProfiling):
3784         (WebCore::InspectorAgent::debuggerEnabled):
3785         (WebCore::InspectorAgent::state):
3786         (WebCore::InspectorAgent::settings):
3787         * inspector/InspectorApplicationCacheAgent.cpp:
3788         (WebCore::InspectorApplicationCacheAgent::InspectorApplicationCacheAgent):
3789         (WebCore::InspectorApplicationCacheAgent::getApplicationCaches):
3790         * inspector/InspectorApplicationCacheAgent.h:
3791         * inspector/InspectorBrowserDebuggerAgent.cpp:
3792         (WebCore::InspectorBrowserDebuggerAgent::InspectorBrowserDebuggerAgent):
3793         (WebCore::InspectorBrowserDebuggerAgent::inspectedURLChanged):
3794         (WebCore::InspectorBrowserDebuggerAgent::restoreStickyBreakpoint):
3795         (WebCore::InspectorBrowserDebuggerAgent::setDOMBreakpoint):
3796         (WebCore::InspectorBrowserDebuggerAgent::removeDOMBreakpoint):
3797         (WebCore::InspectorBrowserDebuggerAgent::willInsertDOMNode):
3798         (WebCore::InspectorBrowserDebuggerAgent::willRemoveDOMNode):
3799         (WebCore::InspectorBrowserDebuggerAgent::willModifyDOMAttr):
3800         (WebCore::InspectorBrowserDebuggerAgent::descriptionForDOMEvent):
3801         (WebCore::InspectorBrowserDebuggerAgent::pauseOnNativeEventIfNeeded):
3802         (WebCore::InspectorBrowserDebuggerAgent::willSendXMLHttpRequest):
3803         * inspector/InspectorBrowserDebuggerAgent.h:
3804         (WebCore::InspectorBrowserDebuggerAgent::create):
3805         * inspector/InspectorConsoleAgent.cpp:
3806         (WebCore::InspectorConsoleAgent::InspectorConsoleAgent):
3807         (WebCore::InspectorConsoleAgent::~InspectorConsoleAgent):
3808         (WebCore::InspectorConsoleAgent::clearConsoleMessages):
3809         (WebCore::InspectorConsoleAgent::addMessageToConsole):
3810         (WebCore::InspectorConsoleAgent::resourceRetrievedByXMLHttpRequest):
3811         (WebCore::InspectorConsoleAgent::didReceiveResponse):
3812         (WebCore::InspectorConsoleAgent::didFailLoading):
3813         (WebCore::InspectorConsoleAgent::setMonitoringXHREnabled):
3814         (WebCore::InspectorConsoleAgent::setConsoleMessagesEnabled):
3815         (WebCore::InspectorConsoleAgent::addConsoleMessage):
3816         * inspector/InspectorConsoleAgent.h:
3817         * inspector/InspectorController.cpp:
3818         (WebCore::InspectorController::InspectorController):
3819         * inspector/InspectorController.h:
3820         * inspector/InspectorDatabaseAgent.cpp:
3821         * inspector/InspectorDebuggerAgent.cpp:
3822         (WebCore::InspectorDebuggerAgent::create):
3823         (WebCore::InspectorDebuggerAgent::InspectorDebuggerAgent):
3824         (WebCore::InspectorDebuggerAgent::~InspectorDebuggerAgent):
3825         (WebCore::InspectorDebuggerAgent::evaluateOnCallFrame):
3826         (WebCore::InspectorDebuggerAgent::getCompletionsOnCallFrame):
3827         (WebCore::InspectorDebuggerAgent::currentCallFrames):
3828         * inspector/InspectorDebuggerAgent.h:
3829         * inspector/InspectorFileSystemAgent.cpp:
3830         (WebCore::InspectorFileSystemAgentCallbacks::didOpenFileSystem):
3831         (WebCore::InspectorFileSystemAgent::InspectorFileSystemAgent):
3832         (WebCore::InspectorFileSystemAgent::stop):
3833         (WebCore::InspectorFileSystemAgent::getFileSystemPathAsync):
3834         (WebCore::InspectorFileSystemAgent::didGetFileSystemPath):
3835         (WebCore::InspectorFileSystemAgent::didGetFileSystemError):
3836         * inspector/InspectorFileSystemAgent.h:
3837         (WebCore::InspectorFileSystemAgent::create):
3838         * inspector/InspectorFrontendHost.cpp:
3839         (WebCore::InspectorFrontendHost::setExtensionAPI):
3840         * inspector/InspectorProfilerAgent.cpp:
3841         (WebCore::InspectorProfilerAgent::create):
3842         (WebCore::InspectorProfilerAgent::InspectorProfilerAgent):
3843         (WebCore::InspectorProfilerAgent::addProfileFinishedMessageToConsole):
3844         (WebCore::InspectorProfilerAgent::addStartProfilingMessageToConsole):
3845         (WebCore::InspectorProfilerAgent::startUserInitiatedProfiling):
3846         (WebCore::InspectorProfilerAgent::stopUserInitiatedProfiling):
3847         * inspector/InspectorProfilerAgent.h:
3848
3849 2011-01-22  Chris Rogers  <crogers@google.com>
3850
3851         Rubber-stamped by Anders Carlsson.
3852
3853         Fix FFTFrameStub to compile properly
3854         https://bugs.webkit.org/show_bug.cgi?id=52969
3855
3856         No new tests since this is a build fix.
3857
3858         * platform/audio/FFTFrameStub.cpp:
3859         (WebCore::FFTFrame::FFTFrame):
3860
3861 2011-01-22  Andrei Popescu  <andreip@google.com>
3862
3863         Reviewed by Jeremy Orlow.
3864
3865         IndexedDB corrupts data on disk
3866         https://bugs.webkit.org/show_bug.cgi?id=52890
3867
3868         We need to store the SerializedScriptValues on disk in a BLOB column rather than TEXT.
3869         Test: storage/indexeddb/data-corruption.html
3870
3871         * platform/sql/SQLiteStatement.cpp:
3872         (WebCore::SQLiteStatement::bindBlob):
3873         (WebCore::SQLiteStatement::getColumnBlobAsString):
3874         (WebCore::SQLiteStatement::getColumnBlobAsVector):
3875         * platform/sql/SQLiteStatement.h:
3876         * storage/IDBCursorBackendImpl.cpp:
3877         (WebCore::IDBCursorBackendImpl::loadCurrentRow):
3878         * storage/IDBFactoryBackendImpl.cpp:
3879         (WebCore::runCommands):
3880         (WebCore::createTables):
3881         (WebCore::createMetaDataTable):
3882         (WebCore::migrateDatabase):
3883         * storage/IDBObjectStoreBackendImpl.cpp:
3884         (WebCore::IDBObjectStoreBackendImpl::getInternal):
3885         (WebCore::putObjectStoreData):
3886
3887 2011-01-22  Nikolas Zimmermann  <nzimmermann@rim.com>
3888
3889         Not reviewed. Fix WinCE build.
3890
3891         * platform/graphics/wince/GraphicsContextWinCE.cpp:
3892         (WebCore::GraphicsContext::drawText):
3893         * rendering/RenderThemeWinCE.cpp:
3894         (WebCore::RenderThemeWinCE::adjustMenuListButtonStyle):
3895
3896 2011-01-22  Nikolas Zimmermann  <nzimmermann@rim.com>
3897
3898         Reviewed by Dirk Schulze.
3899
3900         REGRESSION: Vertical line metrics incorrect
3901         https://bugs.webkit.org/show_bug.cgi?id=52960
3902
3903         SimpleFontDataMac.mm contains a hack to modifiy lineGap/descent for the 'Hiragino' font.
3904         That didn't influence the lineSpacing so far, but does now, causing regressions.
3905
3906         Restore old line spacing behaviour to fix the regression.
3907         Covered by existing fast/blockflow, fast/repaint and fast/text/international test cases.
3908
3909         * platform/graphics/FontMetrics.h:
3910         (WebCore::FontMetrics::FontMetrics):
3911         (WebCore::FontMetrics::floatLineSpacing):
3912         (WebCore::FontMetrics::setLineSpacing):
3913         (WebCore::FontMetrics::lineSpacing):
3914         (WebCore::FontMetrics::reset):
3915         * platform/graphics/SimpleFontData.cpp:
3916         (WebCore::SimpleFontData::SimpleFontData):
3917         * platform/graphics/chromium/SimpleFontDataChromiumWin.cpp:
3918         (WebCore::SimpleFontData::platformInit):
3919         * platform/graphics/chromium/SimpleFontDataLinux.cpp:
3920         (WebCore::SimpleFontData::platformInit):
3921         * platform/graphics/freetype/SimpleFontDataFreeType.cpp:
3922         (WebCore::SimpleFontData::platformInit):
3923         * platform/graphics/haiku/SimpleFontDataHaiku.cpp:
3924         (WebCore::SimpleFontData::platformInit):
3925         * platform/graphics/mac/SimpleFontDataMac.mm:
3926         (WebCore::SimpleFontData::platformInit):
3927         * platform/graphics/pango/SimpleFontDataPango.cpp:
3928         (WebCore::SimpleFontData::platformInit):
3929         * platform/graphics/qt/SimpleFontDataQt.cpp:
3930         (WebCore::SimpleFontData::platformInit):
3931         * platform/graphics/win/SimpleFontDataCGWin.cpp:
3932         (WebCore::SimpleFontData::platformInit):
3933         * platform/graphics/win/SimpleFontDataCairoWin.cpp:
3934         (WebCore::SimpleFontData::platformInit):
3935         * platform/graphics/win/SimpleFontDataWin.cpp:
3936         (WebCore::SimpleFontData::initGDIFont):
3937         * platform/graphics/wince/SimpleFontDataWinCE.cpp:
3938         (WebCore::SimpleFontData::platformInit):
3939         * platform/graphics/wx/SimpleFontDataWx.cpp:
3940         (WebCore::SimpleFontData::platformInit):
3941
3942 2011-01-22  Andreas Kling  <kling@webkit.org>
3943
3944         Reviewed by Kenneth Rohde Christiansen.
3945
3946         [Qt] fast/backgrounds/svg-as-mask.html fails
3947         https://bugs.webkit.org/show_bug.cgi?id=52906
3948
3949         Transparency layers should start out with in SourceOver mode with
3950         alpha 1.0 (modeled after CGContextBeginTransparencyLayer.)
3951
3952         * platform/graphics/qt/TransparencyLayer.h:
3953         (WebCore::TransparencyLayer::TransparencyLayer):
3954
3955 2011-01-22  Nikolas Zimmermann  <nzimmermann@rim.com>
3956
3957         Not reviewed.
3958
3959         Introduce FontMetrics abstraction
3960         https://bugs.webkit.org/show_bug.cgi?id=51456
3961
3962         Fix Chromium/Win build.
3963
3964         * platform/graphics/chromium/UniscribeHelperTextRun.cpp: s/->/./
3965         (WebCore::UniscribeHelperTextRun::UniscribeHelperTextRun):
3966
3967 2011-01-21  Nikolas Zimmermann  <nzimmermann@rim.com>
3968
3969         Reviewed by Dirk Schulze.
3970
3971         Introduce FontMetrics abstraction
3972         https://bugs.webkit.org/show_bug.cgi?id=51456
3973
3974         Encapsulate ascent/descent/lineHeight/lineGap methods in a single FontMetrics class, instead of
3975         having to define them in both Font & SimpleFontData. Changed to store floating point values
3976         as default, in order to get accurate information for small sized fonts. All these methods
3977         now have floating-point and integer versions. Whenever an integer variant of these functions
3978         is called, lroundf() is used to round the value.
3979
3980         This makes it possible to support small font-sizes for SVG in a follow-up patch, as well
3981         as fixing rounding issues when using SVG Fonts.
3982         
3983         Shouldn't affect existing tests.
3984
3985         * GNUmakefile.am: Add FontMetrics.h to build. 
3986         * WebCore.gypi: Ditto.
3987         * WebCore.pro: Ditto.
3988         * WebCore.vcproj/WebCore.vcproj: Ditto.
3989         * WebCore.xcodeproj/project.pbxproj: Ditto.
3990         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp: Use style->fontMetrics() instead of style->font() to access the metrics.
3991         (baselinePositionForAccessibilityRenderObject):
3992         * css/CSSPrimitiveValue.cpp:         
3993         (WebCore::CSSPrimitiveValue::computeLengthDouble):
3994         * html/canvas/CanvasRenderingContext2D.cpp: Ditto.
3995         (WebCore::CanvasRenderingContext2D::drawTextInternal):
3996         * inspector/InspectorController.cpp: Ditto.
3997         (WebCore::InspectorController::drawElementTitle):
3998         * platform/chromium/PopupMenuChromium.cpp: Ditto.
3999         (WebCore::PopupListBox::paintRow):
4000         (WebCore::PopupListBox::getRowHeight):
4001         * platform/graphics/Font.h: Remove ascent/descent/height/lineGap/lineSpacing/xHeight/unitsPerEm accessor...
4002         (WebCore::Font::fontMetrics): ... and only expose a single FontMetrics object here.
4003         * platform/graphics/FontFastPath.cpp: Use fontMetrics() to query metrics information.
4004         (WebCore::Font::emphasisMarkAscent):
4005         (WebCore::Font::emphasisMarkDescent):
4006         (WebCore::Font::emphasisMarkHeight):
4007         (WebCore::Font::floatWidthForSimpleText):
4008         * platform/graphics/FontMetrics.h: Added.
4009         (WebCore::FontMetrics::FontMetrics): Creates a FontMetrics object, stored in SimpleFontData.
4010         (WebCore::FontMetrics::unitsPerEm): Returns an unsigned describing the unitsPerEm.
4011         (WebCore::FontMetrics::setUnitsPerEm): Sets the unitsPerEm value.
4012         (WebCore::FontMetrics::floatAscent): Returns the stored m_ascent float.
4013         (WebCore::FontMetrics::setAscent): Sets the stored m_ascent float.
4014         (WebCore::FontMetrics::floatDescent): Returns the stored m_descent float.
4015         (WebCore::FontMetrics::setDescent): Sets the stored m_descent float.
4016         (WebCore::FontMetrics::floatHeight): Returns floatAscent() + floatDescent().
4017         (WebCore::FontMetrics::floatLineGap): Returns the stored m_lineGap float.
4018         (WebCore::FontMetrics::setLineGap): Sets the stored m_lineGap float.
4019         (WebCore::FontMetrics::floatLineSpacing): Returns the stored m_lineSpacing float.
4020         (WebCore::FontMetrics::setLineSpacing): Sets the stored m_lineSpacing float.
4021         (WebCore::FontMetrics::xHeight): Returns the stored m_xHeight float (no integer version available, hence no 'float' prefix).
4022         (WebCore::FontMetrics::setXHeight): Sets the stored m_xHeight float.
4023         (WebCore::FontMetrics::ascent): Returns a rounded version of ascent().
4024         (WebCore::FontMetrics::descent): Ditto (for descent).
4025         (WebCore::FontMetrics::height): Returns ascent() + descent().
4026         (WebCore::FontMetrics::lineGap): Returns a rounded version of lineGap().
4027        &