Revert r94355 because it caused bunch of builds to break.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-09-01  Ryosuke Niwa  <rniwa@webkit.org>
2
3         Revert r94355 because it caused bunch of builds to break.
4
5         * page/DOMWindow.idl:
6
7 2011-09-01  Mark Rowe  <mrowe@apple.com>
8
9         <rdar://problem/10063411> WebScriptObject.h declares an Objective-C method without a return type.
10
11         Rubber-stamped by Anders Carlsson.
12
13         * bridge/objc/WebScriptObject.h:
14
15 2011-09-01  Mark Hahnenberg  <mhahnenberg@apple.com>
16
17         Unzip initialization lists and constructors in JSCell hierarchy (4/7)
18         https://bugs.webkit.org/show_bug.cgi?id=67174
19
20         Reviewed by Oliver Hunt.
21
22         No new tests.
23
24         Completed the fourth level of the refactoring to add finishCreation() 
25         methods to all classes within the JSCell hierarchy with non-trivial 
26         constructor bodies.
27
28         This primarily consists of pushing the calls to finishCreation() down 
29         into the constructors of the subclasses of the second level of the hierarchy 
30         as well as pulling the finishCreation() calls out into the class's corresponding
31         create() method if it has one.  Doing both simultaneously allows us to 
32         maintain the invariant that the finishCreation() method chain is called exactly 
33         once during the creation of an object, since calling it any other number of 
34         times (0, 2, or more) will cause an assertion failure.
35
36         * bindings/js/JSDOMWindowShell.cpp:
37         (WebCore::JSDOMWindowShell::JSDOMWindowShell):
38         (WebCore::JSDOMWindowShell::create):
39         * bindings/js/JSDOMWindowShell.h:
40         * bindings/js/JSDOMWrapper.h:
41         (WebCore::JSDOMWrapper::JSDOMWrapper):
42         * bindings/js/ScriptController.cpp:
43         (WebCore::ScriptController::createWindowShell):
44         * bindings/scripts/CodeGeneratorJS.pm:
45         (GenerateHeader):
46         * bindings/scripts/test/JS/JSTestInterface.h:
47         (WebCore::JSTestInterfacePrototype::JSTestInterfacePrototype):
48         * bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
49         (WebCore::JSTestMediaQueryListListenerPrototype::JSTestMediaQueryListListenerPrototype):
50         * bindings/scripts/test/JS/JSTestObj.h:
51         (WebCore::JSTestObjPrototype::JSTestObjPrototype):
52         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
53         (WebCore::JSTestSerializedScriptValueInterfacePrototype::JSTestSerializedScriptValueInterfacePrototype):
54         * bridge/objc/objc_runtime.h:
55         * bridge/objc/objc_runtime.mm:
56         (JSC::Bindings::ObjcFallbackObjectImp::ObjcFallbackObjectImp):
57         (JSC::Bindings::ObjcFallbackObjectImp::finishCreation):
58         * bridge/runtime_array.cpp:
59         (JSC::RuntimeArray::RuntimeArray):
60         (JSC::RuntimeArray::finishCreation):
61         * bridge/runtime_array.h:
62         * bridge/runtime_object.cpp:
63         (JSC::Bindings::RuntimeObject::RuntimeObject):
64         (JSC::Bindings::RuntimeObject::finishCreation):
65         * bridge/runtime_object.h:
66
67 2011-08-31  Adrienne Walker  <enne@google.com>
68
69         [chromium] Remove unsafe raw GraphicsContext3D pointer from ProgramBinding
70         https://bugs.webkit.org/show_bug.cgi?id=67003
71
72         Reviewed by James Robinson.
73
74         ProgramBinding now takes an explicit cleanup call to destroy its
75         resources. This will assert if it is not called and will leak no
76         longer potentially dereference a dead pointer.
77
78         * platform/graphics/chromium/LayerRendererChromium.cpp:
79         (WebCore::LayerRendererChromium::borderProgram):
80         (WebCore::LayerRendererChromium::headsUpDisplayProgram):
81         (WebCore::LayerRendererChromium::renderSurfaceProgram):
82         (WebCore::LayerRendererChromium::renderSurfaceMaskProgram):
83         (WebCore::LayerRendererChromium::tilerProgram):
84         (WebCore::LayerRendererChromium::tilerProgramSwizzle):
85         (WebCore::LayerRendererChromium::tilerProgramAA):
86         (WebCore::LayerRendererChromium::tilerProgramSwizzleAA):
87         (WebCore::LayerRendererChromium::canvasLayerProgram):
88         (WebCore::LayerRendererChromium::pluginLayerProgram):
89         (WebCore::LayerRendererChromium::videoLayerRGBAProgram):
90         (WebCore::LayerRendererChromium::videoLayerYUVProgram):
91         (WebCore::LayerRendererChromium::cleanupSharedObjects):
92         * platform/graphics/chromium/ProgramBinding.cpp:
93         (WebCore::ProgramBindingBase::ProgramBindingBase):
94         (WebCore::ProgramBindingBase::~ProgramBindingBase):
95         (WebCore::ProgramBindingBase::init):
96         (WebCore::ProgramBindingBase::cleanup):
97         (WebCore::ProgramBindingBase::loadShader):
98         (WebCore::ProgramBindingBase::createShaderProgram):
99         * platform/graphics/chromium/ProgramBinding.h:
100         (WebCore::ProgramBinding::ProgramBinding):
101         (WebCore::ProgramBinding::initialize):
102
103 2011-09-01  Patrick Gansterer  <paroga@webkit.org>
104
105         Don't include unnecessary headers in V8 bindings
106         https://bugs.webkit.org/show_bug.cgi?id=67435
107
108         Reviewed by Darin Adler.
109
110         When an IDL attribue is Conditonal the corresponding headers
111         need to be surrounded with the correct #if ENABLE().
112
113         * bindings/scripts/CodeGeneratorV8.pm:
114         * bindings/scripts/test/CPP/WebDOMTestObj.cpp:
115         * bindings/scripts/test/CPP/WebDOMTestObj.h:
116         * bindings/scripts/test/JS/JSTestObj.cpp:
117         * bindings/scripts/test/JS/JSTestObj.h:
118         * bindings/scripts/test/ObjC/DOMTestObj.h:
119         * bindings/scripts/test/ObjC/DOMTestObj.mm:
120         * bindings/scripts/test/TestObj.idl:
121         * bindings/scripts/test/V8/V8TestObj.cpp:
122
123 2011-09-01  Pratik Solanki  <psolanki@apple.com>
124
125         Rename CFNETWORK_DATA_ARRAY_CALLBACK to NETWORK_CFDATA_ARRAY_CALLBACK
126         https://bugs.webkit.org/show_bug.cgi?id=67348
127
128         Reviewed by Alexey Proskuryakov.
129
130         * loader/ResourceLoader.h:
131         * loader/SubresourceLoader.h:
132         * loader/cf/SubresourceLoaderCF.cpp:
133         * loader/mac/ResourceLoaderMac.mm:
134         * platform/SharedBuffer.cpp:
135         (WebCore::SharedBuffer::clear):
136         (WebCore::SharedBuffer::buffer):
137         * platform/SharedBuffer.h:
138         * platform/cf/SharedBufferCF.cpp:
139         * platform/network/ResourceHandle.h:
140         * platform/network/ResourceHandleClient.h:
141         * platform/network/cf/ResourceHandleCFNet.cpp:
142         (WebCore::ResourceHandle::createCFURLConnection):
143         * platform/network/mac/ResourceHandleMac.mm:
144
145 2011-09-01  Kentaro Hara  <haraken@google.com>
146
147         TypeError should be thrown when a constructor is called as a normal function.
148         https://bugs.webkit.org/show_bug.cgi?id=67381
149
150         Reviewed by Darin Adler.
151
152         The spec is here: http://www.w3.org/TR/WebIDL/#es-interface-call
153         For example, "Image()" or "XMLHttpRequest()" should throw TypeError.
154
155         Test: fast/dom/call-a-constructor-as-a-function.html
156
157         * bindings/v8/custom/V8ArrayBufferCustom.cpp:
158         (WebCore::V8ArrayBuffer::constructorCallback): Throws TypeError if args.IsConstructCall() is false.
159         * bindings/v8/custom/V8ArrayBufferViewCustom.h:
160         (WebCore::constructWebGLArray): Ditto.
161         * bindings/v8/custom/V8AudioContextCustom.cpp:
162         (WebCore::V8AudioContext::constructorCallback): Ditto.
163         * bindings/v8/custom/V8DOMFormDataCustom.cpp:
164         (WebCore::V8DOMFormData::constructorCallback): Ditto.
165         * bindings/v8/custom/V8HTMLAudioElementConstructor.cpp:
166         (WebCore::v8HTMLAudioElementConstructorCallback): Ditto.
167         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
168         (WebCore::v8HTMLImageElementConstructorCallback): Ditto.
169         * bindings/v8/custom/V8HTMLOptionElementConstructor.cpp:
170         (WebCore::v8HTMLOptionElementConstructorCallback): Ditto.
171         * bindings/v8/custom/V8MessageChannelConstructor.cpp:
172         (WebCore::V8MessageChannel::constructorCallback): Ditto.
173         * bindings/v8/custom/V8SharedWorkerCustom.cpp:
174         (WebCore::V8SharedWorker::constructorCallback): Ditto.
175         * bindings/v8/custom/V8WebKitCSSMatrixConstructor.cpp:
176         (WebCore::V8WebKitCSSMatrix::constructorCallback): Ditto.
177         * bindings/v8/custom/V8WebKitPointConstructor.cpp:
178         (WebCore::V8WebKitPoint::constructorCallback): Ditto.
179         * bindings/v8/custom/V8WebSocketCustom.cpp:
180         (WebCore::V8WebSocket::constructorCallback): Ditto.
181         * bindings/v8/custom/V8WorkerCustom.cpp:
182         (WebCore::V8Worker::constructorCallback): Ditto.
183
184 2011-08-31  Adrienne Walker  <enne@google.com>
185
186         [chromium] TextureManager overestimates the size of non-RGBA texture formats
187         https://bugs.webkit.org/show_bug.cgi?id=66917
188
189         Reviewed by James Robinson.
190
191         Use GraphicsContext3D to determine the size of a given texture format.
192         Also, make TextureManager use more GraphicsContext3D types.
193
194         * platform/graphics/GraphicsContext3D.h:
195         * platform/graphics/chromium/TextureManager.cpp:
196         (WebCore::memoryUseBytes):
197         * platform/graphics/chromium/TextureManager.h:
198
199 2011-09-01  Sam Weinig  <sam@webkit.org>
200
201         Add missing Event constructors to DOMWindow.idl
202         https://bugs.webkit.org/show_bug.cgi?id=67449
203
204         Reviewed by Anders Carlsson.
205
206         Covered by existing tests.
207
208         * page/DOMWindow.idl:
209
210 2011-09-01  Patrick Gansterer  <paroga@webkit.org>
211
212         Consider Conditional attribute in CodeGenerator for methods
213         https://bugs.webkit.org/show_bug.cgi?id=67409
214
215         Reviewed by Darin Adler.
216
217         This change adds appropriate #if ENABLE() lines for the preprocessor around the
218         generated functions depending on the Conditional attribute in the IDL file.
219
220         * bindings/scripts/CodeGeneratorCPP.pm:
221         (GenerateImplementation):
222         * bindings/scripts/CodeGeneratorJS.pm:
223         (GenerateImplementation):
224         * bindings/scripts/CodeGeneratorObjC.pm:
225         (GenerateImplementation):
226         * bindings/scripts/CodeGeneratorV8.pm:
227         (GenerateImplementation):
228         * bindings/scripts/test/CPP/WebDOMTestObj.cpp:
229         * bindings/scripts/test/CPP/WebDOMTestObj.h:
230         * bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
231         * bindings/scripts/test/GObject/WebKitDOMTestObj.h:
232         * bindings/scripts/test/JS/JSTestObj.cpp:
233         * bindings/scripts/test/JS/JSTestObj.h:
234         * bindings/scripts/test/ObjC/DOMTestObj.h:
235         * bindings/scripts/test/ObjC/DOMTestObj.mm:
236         * bindings/scripts/test/TestObj.idl:
237         * bindings/scripts/test/V8/V8TestObj.cpp:
238
239 2011-08-29  Nat Duca  <nduca@chromium.org>
240
241         [chromium] Introduce CCSingleThreadProxy in order to move LayerRenderer to CCLayerTreeHostImpl
242         https://bugs.webkit.org/show_bug.cgi?id=66807
243
244         Reviewed by James Robinson.
245
246         * WebCore.gypi:
247         * platform/graphics/chromium/ContentLayerChromium.cpp:
248         (WebCore::ContentLayerChromium::createTextureUpdater):
249         * platform/graphics/chromium/ImageLayerChromium.cpp:
250         (WebCore::ImageLayerChromium::createTextureUpdater):
251         * platform/graphics/chromium/LayerChromium.cpp:
252         (WebCore::LayerChromium::setLayerRendererRecursive):
253         * platform/graphics/chromium/LayerChromium.h:
254         * platform/graphics/chromium/LayerRendererChromium.cpp:
255         (WebCore::LayerRendererChromium::create):
256         (WebCore::LayerRendererChromium::LayerRendererChromium):
257         (WebCore::LayerRendererChromium::initialize):
258         (WebCore::LayerRendererChromium::close):
259         (WebCore::LayerRendererChromium::updateLayers):
260         (WebCore::LayerRendererChromium::drawLayers):
261         (WebCore::LayerRendererChromium::drawLayersInternal):
262         (WebCore::LayerRendererChromium::getOffscreenLayerTexture):
263         (WebCore::LayerRendererChromium::isContextLost):
264         * platform/graphics/chromium/LayerRendererChromium.h:
265         (WebCore::LayerRendererChromium::capabilities):
266         (WebCore::LayerRendererChromium::rootLayerImpl):
267         (WebCore::LayerRendererChromium::contextSupportsMapSub):
268         (WebCore::LayerRendererChromium::viewportSize):
269         * platform/graphics/chromium/LayerTextureUpdaterCanvas.h:
270         * platform/graphics/chromium/TiledLayerChromium.cpp:
271         (WebCore::TiledLayerChromium::setLayerTreeHost):
272         * platform/graphics/chromium/VideoLayerChromium.cpp:
273         (WebCore::VideoLayerChromium::reserveTextures):
274         * platform/graphics/chromium/cc/CCCanvasLayerImpl.cpp:
275         (WebCore::CCCanvasLayerImpl::draw):
276         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
277         (WebCore::CCLayerTreeHost::CCLayerTreeHost):
278         (WebCore::CCLayerTreeHost::initialize):
279         (WebCore::CCLayerTreeHost::~CCLayerTreeHost):
280         (WebCore::CCLayerTreeHost::animateAndLayout):
281         (WebCore::CCLayerTreeHost::preCommit):
282         (WebCore::CCLayerTreeHost::commitTo):
283         (WebCore::CCLayerTreeHost::createCompositorThread):
284         (WebCore::CCLayerTreeHost::createLayerTreeHostContext3D):
285         (WebCore::CCLayerTreeHost::createLayerTreeHostImpl):
286         (WebCore::CCLayerTreeHost::didRecreateGraphicsContext):
287         (WebCore::CCLayerTreeHost::scheduleComposite):
288         (WebCore::CCLayerTreeHost::context):
289         (WebCore::CCLayerTreeHost::compositeAndReadback):
290         (WebCore::CCLayerTreeHost::finishAllRendering):
291         (WebCore::CCLayerTreeHost::layerRendererCapabilities):
292         (WebCore::CCLayerTreeHost::setRootLayer):
293         (WebCore::CCLayerTreeHost::skiaContext):
294         (WebCore::CCLayerTreeHost::setViewport):
295         (WebCore::CCLayerTreeHost::setVisible):
296         (WebCore::CCLayerTreeHost::loseCompositorContext):
297         (WebCore::CCLayerTreeHost::contentsTextureManager):
298         (WebCore::CCLayerTreeHost::composite):
299         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
300         (WebCore::CCSettings::CCSettings):
301         (WebCore::LayerRendererCapabilities::LayerRendererCapabilities):
302         * platform/graphics/chromium/cc/CCLayerTreeHostCommitter.h: Removed.
303         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
304         (WebCore::CCLayerTreeHostImpl::create):
305         (WebCore::CCLayerTreeHostImpl::CCLayerTreeHostImpl):
306         (WebCore::CCLayerTreeHostImpl::~CCLayerTreeHostImpl):
307         (WebCore::CCLayerTreeHostImpl::commitComplete):
308         (WebCore::CCLayerTreeHostImpl::context):
309         (WebCore::CCLayerTreeHostImpl::drawLayers):
310         (WebCore::CCLayerTreeHostImpl::finishAllRendering):
311         (WebCore::CCLayerTreeHostImpl::isContextLost):
312         (WebCore::CCLayerTreeHostImpl::layerRendererCapabilities):
313         (WebCore::CCLayerTreeHostImpl::present):
314         (WebCore::CCLayerTreeHostImpl::readback):
315         (WebCore::CCLayerTreeHostImpl::setRootLayer):
316         (WebCore::CCLayerTreeHostImpl::setVisible):
317         (WebCore::CCLayerTreeHostImpl::initializeLayerRenderer):
318         (WebCore::CCLayerTreeHostImpl::updateLayers):
319         (WebCore::CCLayerTreeHostImpl::setViewport):
320         * platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
321         (WebCore::CCLayerTreeHostImpl::layerRenderer):
322         (WebCore::CCLayerTreeHostImpl::rootLayer):
323         (WebCore::CCLayerTreeHostImpl::viewportSize):
324         * platform/graphics/chromium/cc/CCLayerTreeHostImplProxy.cpp: Removed.
325         * platform/graphics/chromium/cc/CCMainThreadTask.h:
326         (WebCore::MainThreadTask4::create):
327         (WebCore::MainThreadTask4::MainThreadTask4):
328         (WebCore::MainThreadTask4::performTask):
329         (WebCore::MainThreadTask5::create):
330         (WebCore::MainThreadTask5::MainThreadTask5):
331         (WebCore::MainThreadTask5::performTask):
332         (WebCore::createMainThreadTask):
333         * platform/graphics/chromium/cc/CCPluginLayerImpl.cpp:
334         (WebCore::CCPluginLayerImpl::draw):
335         * platform/graphics/chromium/cc/CCProxy.cpp: Renamed from Source/WebCore/platform/graphics/chromium/cc/CCLayerTreeHostCommitter.cpp.
336         (WebCore::CCProxy::isMainThread):
337         (WebCore::CCProxy::isImplThread):
338         (WebCore::CCProxy::setImplThread):
339         * platform/graphics/chromium/cc/CCProxy.h: Added.
340         (WebCore::CCProxy::~CCProxy):
341         (WebCore::CCProxy::CCProxy):
342         * platform/graphics/chromium/cc/CCSingleThreadProxy.cpp: Added.
343         (WebCore::ScopedSetImplThread::ScopedSetImplThread):
344         (WebCore::ScopedSetImplThread::~ScopedSetImplThread):
345         (WebCore::CCSingleThreadProxy::create):
346         (WebCore::CCSingleThreadProxy::CCSingleThreadProxy):
347         (WebCore::CCSingleThreadProxy::start):
348         (WebCore::CCSingleThreadProxy::~CCSingleThreadProxy):
349         (WebCore::CCSingleThreadProxy::compositeAndReadback):
350         (WebCore::CCSingleThreadProxy::context):
351         (WebCore::CCSingleThreadProxy::finishAllRendering):
352         (WebCore::CCSingleThreadProxy::isStarted):
353         (WebCore::CCSingleThreadProxy::initializeLayerRenderer):
354         (WebCore::CCSingleThreadProxy::layerRendererCapabilities):
355         (WebCore::CCSingleThreadProxy::loseCompositorContext):
356         (WebCore::CCSingleThreadProxy::setNeedsCommitAndRedraw):
357         (WebCore::CCSingleThreadProxy::setNeedsRedraw):
358         (WebCore::CCSingleThreadProxy::stop):
359         (WebCore::CCSingleThreadProxy::skiaContext):
360         (WebCore::CCSingleThreadProxy::contentsTextureManager):
361         (WebCore::CCSingleThreadProxy::compositeImmediately):
362         (WebCore::CCSingleThreadProxy::compositeIfNeeded):
363         (WebCore::CCSingleThreadProxy::doComposite):
364         * platform/graphics/chromium/cc/CCSingleThreadProxy.h: Copied from Source/WebCore/platform/graphics/chromium/cc/CCLayerTreeHostImplProxy.h.
365         * platform/graphics/chromium/cc/CCThreadProxy.cpp: Added.
366         (WebCore::CCThreadProxy::create):
367         (WebCore::CCThreadProxy::CCThreadProxy):
368         (WebCore::CCThreadProxy::~CCThreadProxy):
369         (WebCore::CCThreadProxy::compositeAndReadback):
370         (WebCore::CCThreadProxy::context):
371         (WebCore::CCThreadProxy::finishAllRendering):
372         (WebCore::CCThreadProxy::isStarted):
373         (WebCore::CCThreadProxy::initializeLayerRenderer):
374         (WebCore::CCThreadProxy::layerRendererCapabilities):
375         (WebCore::CCThreadProxy::loseCompositorContext):
376         (WebCore::CCThreadProxy::setNeedsCommitAndRedraw):
377         (WebCore::CCThreadProxy::setNeedsRedraw):
378         (WebCore::CCThreadProxy::start):
379         (WebCore::CCThreadProxy::stop):
380         (WebCore::CCThreadProxy::skiaContext):
381         (WebCore::CCThreadProxy::contentsTextureManager):
382         (WebCore::CCThreadProxy::beginFrameAndCommitOnCCThread):
383         (WebCore::CCThreadProxy::beginFrameAndCommit):
384         (WebCore::CCThreadProxy::commitOnCCThread):
385         (WebCore::CCThreadProxy::drawLayersOnCCThread):
386         (WebCore::CCThreadProxy::setNeedsCommitAndRedrawOnCCThread):
387         (WebCore::CCThreadProxy::setNeedsRedrawOnCCThread):
388         (WebCore::CCThreadProxy::initializeImplOnCCThread):
389         (WebCore::CCThreadProxy::initializeLayerRendererOnCCThread):
390         (WebCore::CCThreadProxy::layerTreeHostClosedOnCCThread):
391         * platform/graphics/chromium/cc/CCThreadProxy.h: Renamed from Source/WebCore/platform/graphics/chromium/cc/CCLayerTreeHostImplProxy.h.
392         * platform/graphics/chromium/cc/CCThreadTask.h:
393         (WebCore::CCThreadTask5::create):
394         (WebCore::CCThreadTask5::CCThreadTask5):
395         (WebCore::CCThreadTask5::performTask):
396         (WebCore::createCCThreadTask):
397         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
398         * platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:
399         (WebCore::CCVideoLayerImpl::draw):
400
401 2011-09-01  Dan Bernstein  <mitz@apple.com>
402
403         <rdar://problem/9528843> STIX glyphs not rendered on this stackoverflow answer
404         https://bugs.webkit.org/show_bug.cgi?id=67444
405
406         Reviewed by Darin Adler.
407
408         Test: fast/text/fallback-traits-fixup.html
409
410         After obtaining STIX Regular as a fallback font for some characters, getFontDataForCharacters()
411         proceeded to ask for a font from the same family having the desired traits and weight (because
412         wkGetFontInLanguageForRange() does not preserve traits and weight). The returned font was different
413         and happened to not contain the desired character.
414
415         * platform/graphics/mac/FontCacheMac.mm:
416         (WebCore::FontCache::getFontDataForCharacters): Only ask for a family member with the desired
417         traits and weight if the substitute font does not already have them, and only use the returned
418         member if it actually contains the desired character.
419
420 2011-09-01  Kentaro Hara  <haraken@google.com>
421
422         Generate an XSLTProcessor constructor of V8 using the IDL 'Constructor' extended attribute
423         https://bugs.webkit.org/show_bug.cgi?id=67414
424
425         Reviewed by Dimitri Glazkov.
426
427         Test: fast/dom/Window/custom-constructors.html
428               fast/xsl/default-html.html
429
430         * bindings/v8/custom/V8XSLTProcessorCustom.cpp: Removed constructorCallback().
431         * xml/XSLTProcessor.idl: Added the 'Constructor' extended attribute.
432
433 2011-09-01  Eric Carlson  <eric.carlson@apple.com>
434
435         HTMLMediaElement should use fastHasAttribute instead of hasAttribute
436         https://bugs.webkit.org/show_bug.cgi?id=67421
437
438         Reviewed by Simon Fraser.
439
440         Use fastHasAttribute instead of hasAttribute because it is faster, and HTMLMediaElement
441         doesn't ever need to check style or SVG animated attributes.
442
443         No new tests required, this is just an optimization.
444
445         * html/HTMLMediaElement.cpp:
446         (WebCore::HTMLMediaElement::selectMediaResource): hasAttribute -> fastHasAttribute.
447         (WebCore::HTMLMediaElement::loadResource): Ditto.
448         (WebCore::HTMLMediaElement::autoplay): Ditto.
449         (WebCore::HTMLMediaElement::loop): Ditto.
450         (WebCore::HTMLMediaElement::controls): Ditto.
451         (WebCore::HTMLMediaElement::selectNextSourceChild): Ditto.
452         (WebCore::HTMLMediaElement::sourceWasAdded): Ditto.
453
454 2011-09-01  Dominic Mazzoni  <dmazzoni@google.com>
455
456         Add API functions to enable starting and stopping speech input,
457         and checking the current speech input state.
458         https://bugs.webkit.org/show_bug.cgi?id=60170
459
460         Reviewed by Dimitri Glazkov.
461
462         Test: fast/speech/input-text-speechstart.html
463
464         * html/shadow/TextControlInnerElements.cpp:
465         (WebCore::InputFieldSpeechButtonElement::defaultEventHandler):
466         (WebCore::InputFieldSpeechButtonElement::startSpeechInput):
467         (WebCore::InputFieldSpeechButtonElement::stopSpeechInput):
468         * html/shadow/TextControlInnerElements.h:
469         * rendering/RenderTextControlSingleLine.cpp:
470         (WebCore::RenderTextControlSingleLine::speechButtonElement):
471         * rendering/RenderTextControlSingleLine.h:
472
473 2011-09-01  Tim Horton  <timothy_horton@apple.com>
474
475         REGRESSION: Rendering artifacts on a rotated, pattern filled SVG shape
476         https://bugs.webkit.org/show_bug.cgi?id=53055
477         <rdar://problem/8910917>
478
479         Reviewed by Simon Fraser.
480
481         Make use of wkCGPatternCreateWithImageAndTransform
482         when tiling patterns in both directions. This helps to avoid
483         pixel-cracking along pattern tiling boundaries.
484
485         Ignore 2D rotation when computing the size of a pattern's tile image,
486         as it artificially inflates the size of the tile, which can cause
487         pixel-cracking.
488
489         Test: svg/custom/pattern-rotate-gaps.svg
490
491         * platform/graphics/cg/PatternCG.cpp:
492         (WebCore::Pattern::createPlatformPattern):
493         * rendering/svg/RenderSVGResourcePattern.cpp:
494         * rendering/svg/SVGImageBufferTools.cpp:
495         (WebCore::SVGImageBufferTools::roundedImageBufferSize):
496         * rendering/svg/SVGImageBufferTools.h:
497
498 2011-09-01  Patrick Gansterer  <paroga@webkit.org>
499
500         Unreviewed, rolling out r94284.
501         http://trac.webkit.org/changeset/94284
502         https://bugs.webkit.org/show_bug.cgi?id=65050
503
504         Broke building without SVG enabled on Chromium.
505
506         * page/DOMWindow.idl:
507
508 2011-09-01  Alexey Proskuryakov  <ap@apple.com>
509
510         REGRESSION (r93247): 2 http/tests/misc tests failing on SnowLeopard Intel Release (Tests)
511         https://bugs.webkit.org/show_bug.cgi?id=67374
512
513         Reviewed by Simon Fraser.
514
515         * platform/network/cf/ResourceHandleCFNet.cpp:
516         (WebCore::applyBasicAuthorizationHeader):
517         * platform/network/mac/ResourceHandleMac.mm:
518         (WebCore::applyBasicAuthorizationHeader):
519         Some versions of CFNetwork carry along an Authorization header, some don't. We shouldn't
520         repeat its value twice, this is not one of those headers that allow comma separated lists
521         of values.
522
523 2011-09-01  Noel Gordon  <noel.gordon@gmail.com>
524
525         [chromium] Move ImageBuffer::platformLayer()
526         https://bugs.webkit.org/show_bug.cgi?id=67372
527
528         Reviewed by Kenneth Russell.
529
530         No new tests: refactoring only, covered by existting tests.
531
532         * platform/graphics/skia/ImageBufferSkia.cpp:
533         (WebCore::ImageBuffer::platformLayer):  Move it away from the toDataURL code.
534
535 2011-09-01  Kulanthaivel Palanichamy  <kulanthaivel@codeaurora.org>
536
537         Focus ring is rendered incorrectly for a block with -webkit-writing-mode
538         https://bugs.webkit.org/show_bug.cgi?id=62915
539
540         Reviewed by Simon Fraser.
541
542         RenderBlock::addFocusRingRects() should consider physical box position and
543         dimension instead of logical values for focus ring rects calculation.
544
545         Test: fast/css/focus-ring-multiline-writingmode-vertical.html
546
547         * rendering/RenderBlock.cpp:
548         (WebCore::RenderBlock::addFocusRingRects):
549
550 2011-09-01  Philippe Normand  <pnormand@igalia.com>
551
552         Unreviewed, GTK build fix after r94299.
553
554         * GNUmakefile.list.am:
555
556 2011-09-01  Brian Salomon  <bsalomon@google.com>
557
558         [Chromium/Skia] Use GraphicsContext3D::grContext() to create GrContext for accelerated drawing
559         https://bugs.webkit.org/show_bug.cgi?id=67419
560
561         Reviewed by James Robinson.
562
563         Accelerated drawing is not enabled in layout tests. However, once it is this change will be tested by every test.
564
565         * platform/graphics/chromium/ContentLayerChromium.cpp:
566         (WebCore::ContentLayerChromium::createTextureUpdater):
567         * platform/graphics/chromium/LayerRendererChromium.cpp:
568         (WebCore::contextSupportsAcceleratedPainting):
569         (WebCore::LayerRendererChromium::initialize):
570         * platform/graphics/chromium/LayerRendererChromium.h:
571         * platform/graphics/chromium/LayerTextureUpdaterCanvas.cpp:
572         (WebCore::LayerTextureUpdaterSkPicture::create):
573         (WebCore::LayerTextureUpdaterSkPicture::LayerTextureUpdaterSkPicture):
574         (WebCore::LayerTextureUpdaterSkPicture::updateTextureRect):
575         (WebCore::LayerTextureUpdaterSkPicture::createFrameBuffer):
576         * platform/graphics/chromium/LayerTextureUpdaterCanvas.h:
577
578 2011-09-01  Dominik Röttsches  <dominik.rottsches@linux.intel.com>
579
580         Rename GraphicsContext3DInternal to GraphicsContext3DPrivate and add a dummy version of this class for Mac
581         https://bugs.webkit.org/show_bug.cgi?id=67172
582
583         Build fix, completing rename for GTK file.
584
585         Reviewed by Chris Marrin.
586
587         * platform/graphics/gtk/GraphicsContext3DPrivate.cpp: Renamed from Source/WebCore/platform/graphics/gtk/GraphicsContext3DInternal.cpp.
588         (sharedDisplay):
589         (WebCore::activeGraphicsContexts):
590         (WebCore::GraphicsContext3DPrivate::addActiveGraphicsContext):
591         (WebCore::GraphicsContext3DPrivate::removeActiveGraphicsContext):
592         (WebCore::GraphicsContext3DPrivate::cleanupActiveContextsAtExit):
593         (WebCore::GraphicsContext3DPrivate::create):
594         (WebCore::GraphicsContext3DPrivate::createPbufferContext):
595         (WebCore::GraphicsContext3DPrivate::createPixmapContext):
596         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
597         (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
598         (WebCore::GraphicsContext3DPrivate::makeContextCurrent):
599
600 2011-09-01  Simon Fraser  <simon.fraser@apple.com>
601
602         REGRESSION (r94259): Two tests doing hit testing were broken by this change.
603         https://bugs.webkit.org/show_bug.cgi?id=67353
604
605         Reviewed by Chris Marrin.
606
607         Fix a regression from r94259; that change missed a fix in RenderView,
608         which affects coordinate transforms in position:fixed elements.
609         
610         This fixes these tests:
611             fast/events/document-elementFromPoint.html
612             fast/events/offsetX-offsetY.html
613             plugins/mouse-events-fixedpos.html
614
615         * rendering/RenderView.cpp:
616         (WebCore::RenderView::mapAbsoluteToLocalPoint):
617
618 2011-09-01  Tony Gentilcore  <tonyg@chromium.org>
619
620         [chromium] Fonts returned by FontCache::getFontDataForCharacters() are never released
621         https://bugs.webkit.org/show_bug.cgi?id=66673
622
623         Reviewed by James Robinson.
624
625         This was fixed for other ports in http://trac.webkit.org/changeset/88260.
626         However, it was missed in FontCacheLinux likely due to similar param in the nested call to getCachedFontPlatformData().
627
628         No new tests because no directly observable change in behavior.
629
630         * platform/graphics/chromium/FontCacheLinux.cpp:
631         (WebCore::FontCache::getFontDataForCharacters):
632
633 2011-08-31  Mikhail Naganov  <mnaganov@chromium.org>
634
635         Web Inspector: [Chromium] Perform a more effective JS GC
636         https://bugs.webkit.org/show_bug.cgi?id=67304
637
638         Reviewed by Pavel Feldman.
639
640         * bindings/v8/ScriptProfiler.cpp:
641         (WebCore::ScriptProfiler::collectGarbage):
642
643 2011-09-01  Sam Weinig  <sam@webkit.org>
644
645         WebGLContextEvent should have its own JS wrapper
646         https://bugs.webkit.org/show_bug.cgi?id=67352
647
648         Reviewed by Anders Carlsson.
649
650         The WebGLContextEvent was missing a proper JS wrapper, and thus
651         anyone using one in an EventListener was actually just getting
652         a plain old Event. Rectify this by generating the wrapper and 
653         wrapping it on creating.
654
655         Test: fast/canvas/webgl/WebGLContextEvent.html
656
657         * CodeGenerators.pri:
658         Add WebGLContextEvent.idl
659
660         * DerivedSources.make:
661         Add WebGLContextEvent and sort.
662
663         * WebCore.xcodeproj/project.pbxproj:
664         Add generated JSWebGLContextEvent.h/cpp.
665
666         * bindings/js/JSEventCustom.cpp:
667         (WebCore::toJS):
668         Wrap WebGLContextEvents as JSWebGLContextEvents.
669
670         * dom/Event.cpp:
671         (WebCore::Event::isWebGLContextEvent):
672         * dom/Event.h:
673         * html/canvas/WebGLContextEvent.cpp:
674         (WebCore::WebGLContextEvent::isWebGLContextEvent):
675         * html/canvas/WebGLContextEvent.h:
676         Add predicate for WebGLContextEvent.
677
678 2011-09-01  Eric Carlson  <eric.carlson@apple.com>
679
680         Add 'muted' content attribute to HTMLMediaElement
681         https://bugs.webkit.org/show_bug.cgi?id=58369
682
683         Reviewed by Darin Adler.
684
685         Test: media/video-defaultmuted.html
686
687         * html/HTMLAttributeNames.in: Add muted.
688         * html/HTMLMediaElement.cpp:
689         (WebCore::HTMLMediaElement::loadResource): Deal with the 'muted' attribute.
690         * html/HTMLMediaElement.idl: Add defaultMuted.
691
692 2011-09-01  Tim Horton  <timothy_horton@apple.com>
693
694         REGRESSION: Rendering artifacts on a rotated, pattern filled shape
695         https://bugs.webkit.org/show_bug.cgi?id=53055
696         <rdar://problem/8910917>
697
698         Reviewed by Simon Fraser.
699
700         Introduce wkCGPatternCreateWithImageAndTransform.
701
702         * WebCore.exp.in:
703         * platform/mac/WebCoreSystemInterface.h:
704         * platform/mac/WebCoreSystemInterface.mm:
705
706 2011-08-30  Adrienne Walker  <enne@google.com>
707
708         [chromium] Fix scissor rects on clipped nested iframes
709         https://bugs.webkit.org/show_bug.cgi?id=67221
710
711         Reviewed by James Robinson.
712
713         Layers that mask to bounds (like iframes) weren't being properly
714         clipped if their parent scissor rect was empty. This case happens
715         when a parent iframe is clipped. Fixed by propagating the empty
716         scissor rect to child layers rather than ignoring it.
717
718         Test: compositing/iframes/nested-composited-iframe.html
719
720         * platform/graphics/chromium/LayerRendererChromium.cpp:
721
722 2011-08-31  Yury Semikhatsky  <yurys@chromium.org>
723
724         Web Inspector: close dedicated worker inspectors when page inspector is closing
725         https://bugs.webkit.org/show_bug.cgi?id=67366
726
727         Close all dedicated worker inspector windows when page inspector is closing.
728
729         Reviewed by Pavel Feldman.
730
731         * inspector/front-end/WorkerManager.js:
732         (WebInspector.WorkerManager.prototype._openInspectorWindow):
733         (WebInspector.WorkerManager.prototype._pageInspectorClosing):
734         (WebInspector.WorkerManager.prototype._workerInspectorClosing):
735         * inspector/front-end/inspector.js:
736         (WebInspector.close):
737
738 2011-08-31  Yury Semikhatsky  <yurys@chromium.org>
739
740         [Chromium] Web Inspector: dedicated worker inspection is broken
741         https://bugs.webkit.org/show_bug.cgi?id=67279
742
743         Provide transport for inspector messages between Page and DedicatedWorker inspectors
744         in case of in-process workers.
745
746         Reviewed by Pavel Feldman.
747
748         * inspector/CodeGeneratorInspector.pm: sendMessageObjectToBackend should accept message
749         object which is ready for sending to backend. This method is overriden in WorkerManager
750         for dedicated workers and we don't want to replicate request id assignment there.
751         * workers/WorkerMessagingProxy.cpp:
752         (WebCore::PostMessageToPageInspectorTask::create):
753         (WebCore::PostMessageToPageInspectorTask::PostMessageToPageInspectorTask):
754         (WebCore::PostMessageToPageInspectorTask::performTask):
755         (WebCore::WorkerMessagingProxy::WorkerMessagingProxy):
756         (WebCore::connectToWorkerContextInspectorTask):
757         (WebCore::WorkerMessagingProxy::connectToInspector):
758         (WebCore::disconnectFromWorkerContextInspectorTask):
759         (WebCore::WorkerMessagingProxy::disconnectFromInspector):
760         (WebCore::dispatchOnInspectorBackendTask):
761         (WebCore::WorkerMessagingProxy::sendMessageToInspector):
762         (WebCore::WorkerMessagingProxy::postMessageToPageInspector):
763         * workers/WorkerMessagingProxy.h:
764
765 2011-09-01  Csaba Osztrogonác  <ossy@webkit.org>
766
767         [CSS3 Backgrounds and Borders] Implement border-image-slice
768         https://bugs.webkit.org/show_bug.cgi?id=67321
769
770         * WebCore.pro: Unreviewed buildfix after Dave "scattered" Hyatt (r94299).
771
772 2011-09-01  Ned Holbrook  <nholbrook@apple.com>
773
774         Typesetting features need not force complex for single-character runs
775         https://bugs.webkit.org/show_bug.cgi?id=66498
776
777         Typesetting features have no effect on a solitary character, so they shouldn't enable complex layout
778         unless multiple characters are present.
779
780         Reviewed by Dan Bernstein.
781
782         No new tests, this is merely a performance optimization.
783
784         * platform/graphics/Font.cpp:
785         (WebCore::Font::codePath): typesettingFeatures() only forces Complex for multiple-character runs.
786
787 2011-08-31  Jeff Miller  <jeffm@apple.com>
788
789         Defer creating AVPlayer and AVPlayerItem in MediaPlayerPrivateAVFoundation::setPreload()
790         https://bugs.webkit.org/show_bug.cgi?id=66253
791
792         Reviewed by Jon Honeycutt.
793
794         No new tests, should be covered by existing media tests.
795
796         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
797         (WebCore::MediaPlayerPrivateAVFoundation::setPreload): Use the same code on Mac and Windows to only create the AVPlayer and AVPlayerItem when needed.
798
799         * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
800         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer): Assign any existing AVPlayerItem to the new AVPlayer.
801         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem): Allow creation of the AVPlayerItem before the AVPlayer.
802
803 2011-08-31  David Hyatt  <hyatt@apple.com>
804
805         https://bugs.webkit.org/show_bug.cgi?id=67321
806
807         Implement border-image-slice. This will eventually be a component of the new border-image shorthand
808         property. It holds the cuts that you make into the border image along with a new optional "fill"
809         keyword that indicates whether or not the center should be filled with the middle slice of the image.
810         
811         By default -webkit-border-image has always filled, but this does not match the specification. To preserve
812         backwards compatibility, -webkit-border-image will continue to fill by default, but this does slightly affect
813         computed style results, since the "fill" keyword will now be included in property dumps.
814
815         Reviewed by Beth Dakin.
816
817         Added fast/borders/border-image-slices.html.
818
819         * CMakeLists.txt:
820         * WebCore.gypi:
821         * WebCore.pro:
822         * WebCore.vcproj/WebCore.vcproj:
823         * WebCore.xcodeproj/project.pbxproj:
824         * css/CSSBorderImageSliceValue.cpp: Added.
825         (WebCore::CSSBorderImageSliceValue::CSSBorderImageSliceValue):
826         (WebCore::CSSBorderImageSliceValue::~CSSBorderImageSliceValue):
827         (WebCore::CSSBorderImageSliceValue::cssText):
828         * css/CSSBorderImageSliceValue.h: Added.
829         (WebCore::CSSBorderImageSliceValue::create):
830         (WebCore::CSSBorderImageSliceValue::isBorderImageSliceValue):
831         Add a new CSSBorderImageSliceValue that holds both the four slices (as a CSS rect) and the
832         fill keyword (as a boolean). Note that the cssText() dumping of the slices has been refined
833         to be smarter, and it will no longer dump repeating values.
834
835         * css/CSSBorderImageValue.cpp:
836         (WebCore::CSSBorderImageValue::CSSBorderImageValue):
837         (WebCore::CSSBorderImageValue::cssText):
838         * css/CSSBorderImageValue.h:
839         (WebCore::CSSBorderImageValue::create):
840         CSSBorderImageValue now owns a CSSBorderImageSliceValue instead of just a CSS rect.
841
842         * css/CSSComputedStyleDeclaration.cpp:
843         (WebCore::valueForNinePieceImageSlice):
844         (WebCore::valueForNinePieceImage):
845         Add a new method, valueForNinePieceImageSlice, for getting the slices plus the fill value
846         from the NinePieceImage and putting it into a CSSBorderImageSliceValue. This method is now used by
847         valueForNinePieceImage to get the CSSBorderImageSliceValue that is part of the overall
848         CSSBorderImageValue.
849     
850         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
851         Adding support for the new properties: border-image-slice and -webkit-mask-box-image-slice.
852
853         * css/CSSParser.cpp:
854         (WebCore::CSSParser::parseValue):
855         (WebCore::BorderImageParseContext::BorderImageParseContext):
856         (WebCore::BorderImageParseContext::allowBreak):
857         (WebCore::BorderImageParseContext::commitImage):
858         (WebCore::BorderImageParseContext::commitSlice):
859         (WebCore::BorderImageParseContext::commitSlash):
860         (WebCore::BorderImageParseContext::commitBorderImage):
861         (WebCore::CSSParser::parseBorderImage):
862         Modify parseBorderImage to no longer parse the slices itself. Instead it farms out the parsing
863         to parseBorderImageSlice.
864
865         (WebCore::BorderImageSliceParseContext::BorderImageSliceParseContext):
866         (WebCore::BorderImageSliceParseContext::allowNumber):
867         (WebCore::BorderImageSliceParseContext::allowFill):
868         (WebCore::BorderImageSliceParseContext::allowFinalCommit):
869         (WebCore::BorderImageSliceParseContext::top):
870         (WebCore::BorderImageSliceParseContext::commitNumber):
871         (WebCore::BorderImageSliceParseContext::commitFill):
872         (WebCore::BorderImageSliceParseContext::setAllowFinalCommit):
873         (WebCore::BorderImageSliceParseContext::setTop):
874         (WebCore::BorderImageSliceParseContext::commitBorderImageSlice):
875         (WebCore::CSSParser::parseBorderImageSlice):
876         Slice parsing has now been broken out so that it can be parsed as a single property. In addition
877         support for the "fill" keyword has been added to control image filling.
878
879         * css/CSSParser.h:
880         Modified to add the new parseBorderImageSlice method.
881
882         * css/CSSPropertyNames.in:
883         Add the new properties: border-image-slice and -webkit-mask-box-image-slice.
884
885         * css/CSSStyleSelector.cpp:
886         (WebCore::CSSStyleSelector::applyProperty):
887         (WebCore::CSSStyleSelector::mapNinePieceImage):
888         Rework mapNinePieceImage to call mapNinePieceImageSlice so that the mapping can be done just for
889         the slices.
890
891         (WebCore::CSSStyleSelector::mapNinePieceImageSlice):
892         A new method that handles mapping just the slices into the front-end NinePieceImage.
893
894         (WebCore::CSSStyleSelector::loadPendingImages):
895         Modified to ensure the fill value is preserved when box-reflect makes a new NinePieceImage.
896
897         * css/CSSStyleSelector.h:
898         Added the new mapNinePieceImageSlice method.
899
900         * css/CSSValue.h:
901         (WebCore::CSSValue::isBorderImageSliceValue):
902         Virtual function for identifying border image slice values.
903
904         * rendering/RenderBoxModelObject.cpp:
905         (WebCore::RenderBoxModelObject::paintNinePieceImage):
906         The painting of the nine piece image has been modified to match the specification. The "fill"
907         keyword controls whether or not the middle is painted.
908
909         * rendering/style/NinePieceImage.cpp:
910         (WebCore::NinePieceImage::operator==):
911         The fill keyword has to be checked now for equality.
912
913         * rendering/style/NinePieceImage.h:
914         (WebCore::NinePieceImage::NinePieceImage):
915         (WebCore::NinePieceImage::fill):
916         (WebCore::NinePieceImage::setFill):
917         Added the fill keyword to the front end NinePieceImage.
918
919         (WebCore::NinePieceImage::copySlicesFrom):
920         Added a helper to copy only the slices over from another NinePieceImage. Used when inheriting
921         the border-image-slice property from a parent style.
922
923 2011-09-01  Vsevolod Vlasov  <vsevik@chromium.org>
924
925         Web Inspector: Decode query/form parameters names as well as values.
926         https://bugs.webkit.org/show_bug.cgi?id=67393
927
928         Reviewed by Yury Semikhatsky.
929
930         * inspector/front-end/ResourceHeadersView.js:
931         (WebInspector.ResourceHeadersView.prototype._decodeURIComponent):
932         (WebInspector.ResourceHeadersView.prototype._refreshParms):
933
934 2011-08-31  Pavel Podivilov  <podivilov@chromium.org>
935
936         Web Inspector: remove PresentationBreakpoint class.
937         https://bugs.webkit.org/show_bug.cgi?id=67275
938
939         Reviewed by Yury Semikhatsky.
940
941         * inspector/front-end/BreakpointsSidebarPane.js:
942         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype.addBreakpoint.didRequestContent):
943         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype.addBreakpoint):
944         * inspector/front-end/DebuggerPresentationModel.js:
945         (WebInspector.DebuggerPresentationModel.prototype._breakpointAdded):
946         (WebInspector.DebuggerPresentationModel.prototype._breakpointRemoved):
947
948 2011-08-31  Steve Block  <steveblock@google.com>
949
950         Clean up all mentions of Android in comments
951         https://bugs.webkit.org/show_bug.cgi?id=67303
952
953         Also removes some superfluous guards and methods added for Android.
954
955         Reviewed by Darin Adler.
956
957         No new tests, removing dead code only.
958
959         * WebCorePrefix.h:
960           Chromium uses this file only on Mac, so these Android guards are no
961           longer required.
962         * bindings/v8/NPV8Object.cpp:
963         * bindings/v8/NPV8Object.h:
964           Including npruntime.h for non-Chromium ports was added in
965           http://trac.webkit.org/changeset/53634 for Android. However, this
966           file is included in WebCore.pro, so leaving the guard in place.
967         * bindings/v8/ScriptCachedFrameData.h:
968           This code was added for Android in
969           http://trac.webkit.org/changeset/56716 but is now also used by QT. The
970           comment should have been removed in
971           http://trac.webkit.org/changeset/93573.
972         * dom/Document.cpp:
973         (WebCore::Document::Document):
974         (WebCore::Document::isLayoutTimerActive):
975         (WebCore::Document::minimumLayoutDelay):
976         * dom/Document.h:
977           This method was added for Android in
978           http://trac.webkit.org/changeset/52919 and modified in
979           http://trac.webkit.org/changeset/79775. It is no longer needed.
980
981 2011-09-01  Kristóf Kosztyó  <kkristof@inf.u-szeged.hu>
982
983         [Qt] Build dependency problems
984         https://bugs.webkit.org/show_bug.cgi?id=38054
985
986         Make clean build after the defines are changed.
987
988         Reviewed by Csaba Osztrogonác.
989
990         * features.pri:
991
992 2011-09-01  Vsevolod Vlasov  <vsevik@chromium.org>
993
994         Web Inspector: Network error messages in console should link to the respective request in network panel if there is one.
995         https://bugs.webkit.org/show_bug.cgi?id=65550
996
997         Reviewed by Yury Semikhatsky.
998
999         * inspector/front-end/ConsoleMessage.js:
1000         (WebInspector.ConsoleMessage.prototype._formatMessage):
1001         * inspector/front-end/NetworkPanel.js:
1002         (WebInspector.NetworkLogView.prototype.refresh):
1003         (WebInspector.NetworkLogView.prototype.switchToBriefView):
1004         (WebInspector.NetworkLogView.prototype.searchCanceled):
1005         (WebInspector.NetworkLogView.prototype.revealAndHighlightResource):
1006         (WebInspector.NetworkLogView.prototype._removeAllNodeHighlights):
1007         (WebInspector.NetworkLogView.prototype._highlightNode):
1008         (WebInspector.NetworkPanel.prototype._resourceByAnchor):
1009         (WebInspector.NetworkPanel.prototype.canShowAnchorLocation):
1010         (WebInspector.NetworkPanel.prototype.showAnchorLocation):
1011         * inspector/front-end/networkLogView.css:
1012         (.network-log-grid tr.highlighted-row):
1013         (from):
1014         (to):
1015
1016 2011-09-01  Patrick Gansterer  <paroga@webkit.org>
1017
1018         Replace preprocessor statements in DOMWindow.idl with Conditional attribute
1019         https://bugs.webkit.org/show_bug.cgi?id=65050
1020
1021         Reviewed by Brent Fulgham.
1022
1023         Many attributes use the [Conditional=XXX] syntax already.
1024         Unify the declaration of conditional attributes of DOMWindow
1025         with the corresponding Conditional attribute.
1026         This reduces the need of the preprocessor which is the
1027         the source of much pain on native windows.
1028
1029         * page/DOMWindow.idl:
1030
1031 2011-09-01  Yuta Kitamura  <yutak@chromium.org>
1032
1033         WebSocket: Fix bufferedAmount after WebSocket is closed
1034         https://bugs.webkit.org/show_bug.cgi?id=67363
1035
1036         Reviewed by Kent Tamura.
1037
1038         Test: http/tests/websocket/tests/hybi/bufferedAmount-after-close.html (updated)
1039
1040         * websockets/WebSocket.cpp:
1041         (WebCore::WebSocket::send):
1042         (WebCore::WebSocket::getFramingOverhead):
1043         * websockets/WebSocket.h:
1044
1045 2011-09-01  Keishi Hattori  <keishi@webkit.org>
1046
1047         Rename colorSelected to didChooseColor
1048         https://bugs.webkit.org/show_bug.cgi?id=67271
1049
1050         Reviewed by Kent Tamura.
1051
1052         * WebCore.exp.in:
1053         * html/ColorInputType.cpp:
1054         (WebCore::ColorInputType::didChooseColor): Renamed colorSelected to didChooseColor so it follows common naming practice.
1055         * html/ColorInputType.h:
1056         * platform/ColorChooser.cpp:
1057         (WebCore::ColorChooser::didChooseColor): Renamed.
1058         * platform/ColorChooser.h:
1059
1060 2011-09-01  Adam Barth  <abarth@webkit.org>
1061
1062         Attempt to fix Windows build.
1063
1064         * platform/graphics/chromium/FontPlatformDataChromiumWin.cpp:
1065
1066 2011-08-31  Adam Barth  <abarth@webkit.org>
1067
1068         [Chromium] Rename PlatformBridge to PlatformSupport
1069         https://bugs.webkit.org/show_bug.cgi?id=67349
1070
1071         Reviewed by Darin Fisher.
1072
1073         This matches the WebKitPlatformSupport embedder API.
1074
1075         * WebCore.gypi:
1076         * WebCore.pro:
1077         * bindings/v8/NPV8Object.cpp:
1078         (_NPN_Evaluate):
1079         * bindings/v8/ScriptController.cpp:
1080         (WebCore::ScriptController::createScriptInstanceForWidget):
1081         * bindings/v8/V8DOMWindowShell.cpp:
1082         (WebCore::reportFatalErrorInV8):
1083         * bindings/v8/V8GCController.cpp:
1084         * bindings/v8/V8Proxy.cpp:
1085         (WebCore::V8Proxy::handleOutOfMemory):
1086         (WebCore::V8Proxy::evaluate):
1087         * bindings/v8/V8Proxy.h:
1088         * bindings/v8/custom/V8InspectorFrontendHostCustom.cpp:
1089         (WebCore::histogramEnumeration):
1090         * page/PageGroup.cpp:
1091         (WebCore::PageGroup::isLinkVisited):
1092         * platform/audio/chromium/AudioBusChromium.cpp:
1093         (WebCore::AudioBus::loadPlatformResource):
1094         (WebCore::createBusFromInMemoryAudioFile):
1095         * platform/chromium/ChromiumDataObject.cpp:
1096         (WebCore::ChromiumDataObject::types):
1097         (WebCore::ChromiumDataObject::getData):
1098         (WebCore::ChromiumDataObject::getSequenceNumber):
1099         (WebCore::ChromiumDataObject::containsFilenames):
1100         * platform/chromium/DataTransferItemChromium.cpp:
1101         (WebCore::DataTransferItemChromium::getAsString):
1102         (WebCore::DataTransferItemChromium::getAsFile):
1103         * platform/chromium/DragDataChromium.cpp:
1104         (WebCore::DragData::asURL):
1105         * platform/chromium/FileSystemChromium.cpp:
1106         (WebCore::deleteFile):
1107         (WebCore::deleteEmptyDirectory):
1108         (WebCore::getFileSize):
1109         (WebCore::getFileModificationTime):
1110         (WebCore::revealFolderInOS):
1111         (WebCore::directoryName):
1112         (WebCore::pathByAppendingComponent):
1113         (WebCore::makeAllDirectories):
1114         (WebCore::fileExists):
1115         (WebCore::openFile):
1116         (WebCore::closeFile):
1117         (WebCore::seekFile):
1118         (WebCore::truncateFile):
1119         (WebCore::readFromFile):
1120         (WebCore::writeToFile):
1121         * platform/chromium/LanguageChromium.cpp:
1122         (WebCore::platformDefaultLanguage):
1123         * platform/chromium/LinkHashChromium.cpp:
1124         (WebCore::visitedLinkHash):
1125         * platform/chromium/MIMETypeRegistryChromium.cpp:
1126         (WebCore::MIMETypeRegistry::getMIMETypeForExtension):
1127         (WebCore::MIMETypeRegistry::getWellKnownMIMETypeForExtension):
1128         (WebCore::MIMETypeRegistry::getPreferredExtensionForMIMEType):
1129         (WebCore::MIMETypeRegistry::isSupportedImageMIMEType):
1130         (WebCore::MIMETypeRegistry::isSupportedJavaScriptMIMEType):
1131         (WebCore::MIMETypeRegistry::isSupportedNonImageMIMEType):
1132         * platform/chromium/PasteboardChromium.cpp:
1133         (WebCore::Pasteboard::writeSelection):
1134         (WebCore::Pasteboard::writePlainText):
1135         (WebCore::Pasteboard::writeURL):
1136         (WebCore::Pasteboard::writeImage):
1137         (WebCore::Pasteboard::canSmartReplace):
1138         (WebCore::Pasteboard::plainText):
1139         (WebCore::Pasteboard::documentFragment):
1140         * platform/chromium/PlatformBridge.h: Removed.
1141         * platform/chromium/PlatformScreenChromium.cpp:
1142         (WebCore::screenDepth):
1143         (WebCore::screenDepthPerComponent):
1144         (WebCore::screenIsMonochrome):
1145         (WebCore::screenRect):
1146         (WebCore::screenAvailableRect):
1147         * platform/chromium/PlatformSupport.h: Copied from Source/WebCore/platform/chromium/PlatformBridge.h.
1148         * platform/chromium/SSLKeyGeneratorChromium.cpp:
1149         (WebCore::signedPublicKeyAndChallengeString):
1150         * platform/chromium/ScrollbarThemeChromium.cpp:
1151         * platform/chromium/ScrollbarThemeChromiumLinux.cpp:
1152         (WebCore::ScrollbarThemeChromiumLinux::scrollbarThickness):
1153         (WebCore::ScrollbarThemeChromiumLinux::paintTrackPiece):
1154         (WebCore::ScrollbarThemeChromiumLinux::paintButton):
1155         (WebCore::ScrollbarThemeChromiumLinux::paintThumb):
1156         (WebCore::ScrollbarThemeChromiumLinux::buttonSize):
1157         (WebCore::ScrollbarThemeChromiumLinux::minimumThumbLength):
1158         * platform/chromium/ScrollbarThemeChromiumMac.mm:
1159         (WebCore::scrollbarStateToThemeState):
1160         (WebCore::ScrollbarThemeChromiumMac::paint):
1161         * platform/chromium/ScrollbarThemeChromiumWin.cpp:
1162         (WebCore::ScrollbarThemeChromiumWin::scrollbarThickness):
1163         (WebCore::ScrollbarThemeChromiumWin::paintTrackPiece):
1164         (WebCore::ScrollbarThemeChromiumWin::paintButton):
1165         (WebCore::ScrollbarThemeChromiumWin::paintThumb):
1166         (WebCore::ScrollbarThemeChromiumWin::buttonSize):
1167         * platform/chromium/SharedTimerChromium.cpp:
1168         (WebCore::setSharedTimerFiredFunction):
1169         (WebCore::setSharedTimerFireInterval):
1170         (WebCore::stopSharedTimer):
1171         * platform/chromium/SuddenTerminationChromium.cpp:
1172         (WebCore::disableSuddenTermination):
1173         (WebCore::enableSuddenTermination):
1174         * platform/chromium/TraceEvent.h:
1175         (WebCore::internal::ScopeTracer::ScopeTracer):
1176         (WebCore::internal::ScopeTracer::~ScopeTracer):
1177         * platform/graphics/chromium/ContentLayerChromium.cpp:
1178         (WebCore::ContentLayerPainter::paint):
1179         * platform/graphics/chromium/CrossProcessFontLoading.mm:
1180         * platform/graphics/chromium/FontCacheChromiumWin.cpp:
1181         (WebCore::fontContainsCharacter):
1182         (WebCore::FillLogFont):
1183         * platform/graphics/chromium/FontCacheLinux.cpp:
1184         (WebCore::FontCache::getFontDataForCharacters):
1185         * platform/graphics/chromium/FontChromiumWin.cpp:
1186         (WebCore::drawGlyphsWin):
1187         * platform/graphics/chromium/FontPlatformDataChromiumWin.cpp:
1188         (WebCore::FontPlatformData::scriptFontProperties):
1189         * platform/graphics/chromium/FontPlatformDataLinux.cpp:
1190         (WebCore::FontPlatformData::querySystemForRenderStyle):
1191         * platform/graphics/chromium/GlyphPageTreeNodeChromiumWin.cpp:
1192         (WebCore::fillBMPGlyphs):
1193         * platform/graphics/chromium/ImageChromium.cpp:
1194         (WebCore::Image::loadPlatformResource):
1195         * platform/graphics/chromium/ImageChromiumMac.mm:
1196         (WebCore::Image::loadPlatformResource):
1197         * platform/graphics/chromium/SimpleFontDataChromiumWin.cpp:
1198         (WebCore::SimpleFontData::platformInit):
1199         (WebCore::SimpleFontData::determinePitch):
1200         (WebCore::SimpleFontData::platformWidthForGlyph):
1201         * platform/graphics/chromium/UniscribeHelperTextRun.cpp:
1202         (WebCore::UniscribeHelperTextRun::tryToPreloadFont):
1203         * platform/graphics/skia/FontCustomPlatformData.cpp:
1204         (WebCore::FontCustomPlatformData::fontPlatformData):
1205         * platform/network/chromium/CookieJarChromium.cpp:
1206         (WebCore::setCookies):
1207         (WebCore::cookies):
1208         (WebCore::cookieRequestHeaderFieldValue):
1209         (WebCore::cookiesEnabled):
1210         (WebCore::getRawCookies):
1211         (WebCore::deleteCookie):
1212         * platform/network/chromium/DNSChromium.cpp:
1213         (WebCore::prefetchDNS):
1214         * platform/qt/PlatformBridge.h: Removed.
1215         * platform/qt/PlatformBridgeQt.cpp: Removed.
1216         * platform/qt/PlatformSupport.h: Copied from Source/WebCore/platform/qt/PlatformBridge.h.
1217         * platform/qt/PlatformSupportQt.cpp: Copied from Source/WebCore/platform/qt/PlatformBridgeQt.cpp.
1218         (WebCore::PlatformSupport::popupsAllowed):
1219         (WebCore::PlatformSupport::pluginScriptableObject):
1220         * platform/sql/chromium/SQLiteFileSystemChromium.cpp:
1221         (WebCore::SQLiteFileSystem::deleteDatabaseFile):
1222         (WebCore::SQLiteFileSystem::getDatabaseFileSize):
1223         * platform/sql/chromium/SQLiteFileSystemChromiumPosix.cpp:
1224         * platform/sql/chromium/SQLiteFileSystemChromiumWin.cpp:
1225         * plugins/chromium/PluginDataChromium.cpp:
1226         (WebCore::PluginCache::plugins):
1227         * rendering/RenderThemeChromiumLinux.cpp:
1228         (WebCore::getWebThemeState):
1229         (WebCore::RenderThemeChromiumLinux::adjustSliderThumbSize):
1230         (WebCore::RenderThemeChromiumLinux::paintCheckbox):
1231         (WebCore::RenderThemeChromiumLinux::setCheckboxSize):
1232         (WebCore::RenderThemeChromiumLinux::paintRadio):
1233         (WebCore::RenderThemeChromiumLinux::setRadioSize):
1234         (WebCore::RenderThemeChromiumLinux::paintButton):
1235         (WebCore::RenderThemeChromiumLinux::paintTextField):
1236         (WebCore::RenderThemeChromiumLinux::paintMenuList):
1237         (WebCore::RenderThemeChromiumLinux::paintSliderTrack):
1238         (WebCore::RenderThemeChromiumLinux::paintSliderThumb):
1239         (WebCore::RenderThemeChromiumLinux::adjustInnerSpinButtonStyle):
1240         (WebCore::RenderThemeChromiumLinux::paintInnerSpinButton):
1241         (WebCore::RenderThemeChromiumLinux::paintProgressBar):
1242         * rendering/RenderThemeChromiumMac.mm:
1243         (WebCore::RenderThemeChromiumMac::usesTestModeFocusRingColor):
1244         * rendering/RenderThemeChromiumSkia.cpp:
1245         (WebCore::RenderThemeChromiumSkia::caretBlinkInterval):
1246         * rendering/RenderThemeChromiumWin.cpp:
1247         (WebCore::RenderThemeChromiumWin::platformActiveSelectionBackgroundColor):
1248         (WebCore::RenderThemeChromiumWin::platformInactiveSelectionBackgroundColor):
1249         (WebCore::RenderThemeChromiumWin::platformActiveSelectionForegroundColor):
1250         (WebCore::RenderThemeChromiumWin::systemColor):
1251         (WebCore::RenderThemeChromiumWin::paintButton):
1252         (WebCore::RenderThemeChromiumWin::paintSliderTrack):
1253         (WebCore::menuListButtonWidth):
1254         (WebCore::RenderThemeChromiumWin::paintMenuList):
1255         (WebCore::RenderThemeChromiumWin::paintTextFieldInternal):
1256         (WebCore::RenderThemeChromiumWin::paintInnerSpinButton):
1257         (WebCore::RenderThemeChromiumWin::paintProgressBar):
1258         * storage/chromium/IDBFactoryBackendInterface.cpp:
1259         (WebCore::IDBFactoryBackendInterface::create):
1260         * storage/chromium/IDBKeyPathBackendImpl.cpp:
1261         (WebCore::IDBKeyPathBackendImpl::createIDBKeysFromSerializedValuesAndKeyPath):
1262         (WebCore::IDBKeyPathBackendImpl::injectIDBKeyIntoSerializedValue):
1263         * storage/chromium/QuotaTracker.cpp:
1264         (WebCore::QuotaTracker::getDatabaseSizeAndSpaceAvailableToOrigin):
1265
1266 2011-08-31  Ryosuke Niwa  <rniwa@webkit.org>
1267
1268         Crash when inserting text with a trailing newline into a textarea via JS
1269         https://bugs.webkit.org/show_bug.cgi?id=66241
1270
1271         Reviewed by Darin Adler and Kent Tamura.
1272
1273         The crash was caused by updateFromElement biting on the editing code.
1274
1275         When there is a style rule that applies on text nodes inside the shadow DOM, DOM modifications made
1276         by the editing code may trigger style recalculation on input or textarea elements in the midst of editing
1277         commands. In response to this style recalculation, HTMLInputElement::updateFromElement and
1278         HTMLTextAreaElement::updateFromElement call setInnerTextValue to re-create the text nodes in the
1279         shadow DOM. The editing code blows up because setInnerTextValue detaches old text nodes referenced by
1280         Positions and VisiblePositions held by the editing commands in progress.
1281
1282         Fixed the crash by stop calling setInnerTextValue in updateFromElement. Instead, WebKit now creates
1283         the text nodes when attributes, descendent nodes, etc... of input or textarea element changes.
1284
1285         Tests: fast/forms/update-from-element-during-editing-crash-1.html
1286                fast/forms/update-from-element-during-editing-crash-2.html
1287
1288         * html/HTMLInputElement.cpp:
1289         (WebCore::HTMLInputElement::updateType): Force calling setInnerTextValue when input type changes.
1290         (WebCore::HTMLInputElement::updateInnerTextValue): Extracted from RenderTextControlSingleLine's
1291         updateElement.
1292         (WebCore::HTMLInputElement::parseMappedAttribute): Calls updateInnerTextValue; force calling
1293         setInnerTextValue when -webkit-speech attribute changes. In the theory, we should be able to call it less
1294         frequently but there are too many cases to consider at the moment.
1295         (WebCore::HTMLInputElement::setValue): Calls updateInnerTextValue when the value actually changed.
1296         Note we need to call it before we set or restore selection.
1297         * html/HTMLInputElement.h:
1298         * html/HTMLTextAreaElement.cpp:
1299         (WebCore::HTMLTextAreaElement::childrenChanged): Calls updateInnerTextValue when textarea's descendants
1300         nodes are changed by parser or scripts.
1301         (WebCore::HTMLTextAreaElement::setValueCommon): Calls updateInnerTextValue when the value changes.
1302         * html/HTMLTextFormControlElement.h:
1303         * html/NumberInputType.cpp:
1304         (WebCore::NumberInputType::willBlur): Calls updateInnerTextValue because input[type=number] forces
1305         the value to be valid on blur.
1306         * rendering/RenderTextControlMultiLine.cpp: Removed RenderTextControlMultiLine::updateFromElement.
1307         * rendering/RenderTextControlMultiLine.h: Ditto.
1308         * rendering/RenderTextControlSingleLine.cpp:
1309         (WebCore::RenderTextControlSingleLine::updateFromElement):
1310
1311 2011-08-31  Tom Zakrajsek  <tomz@codeaurora.org>
1312
1313         Fix snow-leopard regression caused by r93982
1314         https://bugs.webkit.org/show_bug.cgi?id=67301
1315
1316         Reviewed by Kenneth Russell.
1317
1318         Test: canvas/philip/tests/2d.path.stroke.prune.arc.html
1319
1320         * html/canvas/CanvasRenderingContext2D.cpp:
1321         (WebCore::CanvasRenderingContext2D::arc):
1322
1323 2011-08-31  Keishi Hattori  <keishi@webkit.org>
1324
1325         Rename closeColorChooser to cleanupColorChooser
1326         https://bugs.webkit.org/show_bug.cgi?id=67270
1327
1328         Reviewed by Kent Tamura.
1329
1330         * html/ColorInputType.cpp:
1331         (WebCore::ColorInputType::~ColorInputType):
1332         (WebCore::ColorInputType::detach):
1333         (WebCore::ColorInputType::cleanupColorChooserIfCurrentClient): NSColorPanel shouldn't be closed but the color
1334         chooser listeners need to be taken care of. Therefore closeColorChooser will be renamed to cleanupColorChooser.
1335         This will close the color chooser on platforms where appropriate.
1336         * html/ColorInputType.h:
1337         * loader/EmptyClients.h:
1338         (WebCore::EmptyChromeClient::cleanupColorChooser): Rename.
1339         * page/Chrome.cpp:
1340         (WebCore::Chrome::cleanupColorChooser): Rename.
1341         * page/Chrome.h:
1342         * page/ChromeClient.h:
1343
1344 2011-08-31  Kent Tamura  <tkent@chromium.org>
1345
1346         REGRESSION(r88115): "Choose File" button doesn't respect font-size property for the <input>
1347         https://bugs.webkit.org/show_bug.cgi?id=67181
1348
1349         Reviewed by Dimitri Glazkov.
1350
1351         r88115 removed the code to make inherited style of the owner input
1352         element, and html.css contains "font: -webkit-small-control" for
1353         input element. So -webkit-file-upload-button always had
1354         -webkit-small-control font.
1355
1356         Test: fast/forms/file/file-style-inheritance.html
1357
1358         * css/html.css:
1359         (input[type="file"]::-webkit-file-upload-button):
1360         Specify font-size:inherit explicitly.
1361
1362 2011-08-31  Chris Rogers  <crogers@google.com>
1363
1364         Do more rigorous bounds checking in AudioBufferSourceNode::renderFromBuffer()
1365         https://bugs.webkit.org/show_bug.cgi?id=67351
1366
1367         Reviewed by Dirk Pranke.
1368
1369         No new tests since this does not change JavaScript API.
1370
1371         * webaudio/AudioBufferSourceNode.cpp:
1372         (WebCore::AudioBufferSourceNode::renderFromBuffer):
1373
1374 2011-08-31  Keishi Hattori  <keishi@webkit.org>
1375
1376         Remove closeColorChooser call from FrameLoader::transitionToCommitted
1377         https://bugs.webkit.org/show_bug.cgi?id=67267
1378
1379         Reviewed by Darin Adler.
1380
1381         * html/ColorInputType.cpp:
1382         (WebCore::ColorInputType::closeColorChooserIfCurrentClient): Moved order to match header.
1383         * html/ColorInputType.h:
1384         * loader/FrameLoader.cpp:
1385         (WebCore::FrameLoader::transitionToCommitted): Remove ColorInputType::closeColorChooserIfCurrentClient call.
1386         It wasn't the right place to directly manipulate the UI.
1387
1388 2011-08-31  Chris Rogers  <crogers@google.com>
1389
1390         Add defensive bounds checking for AudioNode methods
1391         https://bugs.webkit.org/show_bug.cgi?id=67346
1392
1393         Reviewed by Anders Carlsson.
1394
1395         No new tests since this does not change JavaScript API.
1396
1397         * webaudio/AudioNode.cpp:
1398         (WebCore::AudioNode::input):
1399         (WebCore::AudioNode::output):
1400
1401 2011-08-31  Simon Fraser  <simon.fraser@apple.com>
1402
1403         TransformState.move() should be negated in the unapply code path
1404         https://bugs.webkit.org/show_bug.cgi?id=66246
1405
1406         Reviewed by Chris Marrin.
1407
1408         Code using TransformState was confused about when to negate the arguments
1409         to move() in the "UnapplyInverseTransform" direction (used by mapAbsoluteToLocal).
1410         
1411         Made the move() path equivalent to the applyTransform() path by not requiring
1412         the caller to negate, and instead negating inside move().
1413         
1414         Fixed the erroneous negation in TransformState::move() when accumulating;
1415         that negation will happen later via matrix inversion.
1416
1417         No behavior change.
1418
1419         * platform/graphics/ca/GraphicsLayerCA.cpp:
1420         (WebCore::GraphicsLayerCA::recursiveCommitChanges):
1421         * platform/graphics/transforms/TransformState.cpp:
1422         (WebCore::TransformState::move):
1423         * rendering/RenderBox.cpp:
1424         (WebCore::RenderBox::mapAbsoluteToLocalPoint):
1425         * rendering/RenderInline.cpp:
1426         (WebCore::RenderInline::mapAbsoluteToLocalPoint):
1427
1428 2011-08-31  Pratik Solanki  <psolanki@apple.com>
1429
1430         Fix compile issues when enabling HAVE(CFNETWORK_DATA_ARRAY_CALLBACK)
1431         https://bugs.webkit.org/show_bug.cgi?id=67332
1432
1433         Reviewed by Darin Adler.
1434
1435         * loader/mac/ResourceLoaderMac.mm:
1436         (WebCore::ResourceLoader::didReceiveDataArray):
1437         * platform/network/cf/ResourceHandleCFNet.cpp:
1438
1439 2011-08-31  Dan Bernstein  <mitz@apple.com>
1440
1441         Refined the heuristic introduced to fix <rdar://problem/10002140> Text gets clipped in
1442         multi-column layouts when overflow:auto is used.
1443         https://bugs.webkit.org/show_bug.cgi?id=67212
1444
1445         Reviewed by Dave Hyatt.
1446
1447         Test: fast/multicol/overflow-across-columns-percent-height.html
1448
1449         * rendering/RenderBox.cpp:
1450         (WebCore::percentageLogicalHeightIsResolvable): Added. This follows logic similar to the one
1451         in computePercentageLogicalHeight() to determine whether percentage values for height properties
1452         are resolved or treated as "auto".
1453         (WebCore::RenderBox::hasUnsplittableScrollingOverflow): If min-height or max-height are specified
1454         as a percentage but actually resolve to "auto", don’t let that prevent splitting.
1455
1456 2011-08-31  Ryosuke Niwa  <rniwa@webkit.org>
1457
1458         Move text() and textWithHardLineBreaks() from RenderTextControl to HTMLTextFormControlElement
1459         https://bugs.webkit.org/show_bug.cgi?id=67320
1460
1461         Reviewed by Darin Adler.
1462
1463         Moved and renamed RenderText::text and RenderText::textWithHardLineBreaks to
1464         HTMLTextFormControlElement::innerTextValue and HTMLTextFormControlElement::valueWithHardLineBreaks.
1465
1466         * accessibility/AccessibilityRenderObject.cpp:
1467         (WebCore::AccessibilityRenderObject::text):
1468         * html/HTMLInputElement.cpp:
1469         (WebCore::HTMLInputElement::subtreeHasChanged):
1470         * html/HTMLTextAreaElement.cpp:
1471         (WebCore::HTMLTextAreaElement::appendFormData): Calls valueWithHardLineBreaks. It doesn't have to check
1472         the existence of renderer anymore because valueWithHardLineBreaks returns value() when renderer do not
1473         exist unlike RenderText::textWithHardLineBreaks returned emptyString() in such cases. This is the only place
1474         valueWithHardLineBreaks is ever called; but we can't move valueWithHardLineBreaks because it calls
1475         finishText.
1476         (WebCore::HTMLTextAreaElement::handleBeforeTextInsertedEvent):
1477         (WebCore::HTMLTextAreaElement::updateValue):
1478         * html/HTMLTextFormControlElement.cpp:
1479         (WebCore::HTMLTextFormControlElement::selectedText):
1480         (WebCore::HTMLTextFormControlElement::setInnerTextValue):
1481         (WebCore::finishText): Moved from RenderText.cpp
1482         (WebCore::HTMLTextFormControlElement::innerTextValue): Ditto.
1483         (WebCore::getNextSoftBreak): Ditto.
1484         (WebCore::HTMLTextFormControlElement::valueWithHardLineBreaks): Ditto; this function returns value()
1485         when there are no renderers or root inline boxes instead of emptyString().
1486         * html/HTMLTextFormControlElement.h:
1487         * html/NumberInputType.cpp:
1488         (WebCore::NumberInputType::hasUnacceptableValue):
1489         * html/SearchInputType.cpp:
1490         (WebCore::SearchInputType::startSearchEventTimer):
1491         * html/TextFieldInputType.cpp:
1492         (WebCore::TextFieldInputType::handleBeforeTextInsertedEvent):
1493         * rendering/RenderTextControl.cpp:
1494         * rendering/RenderTextControl.h:
1495
1496 2011-08-31  Jeff Miller  <jeffm@apple.com>
1497
1498         REGRESSION(92210): AVFoundation media engine is disabled on OS X
1499         https://bugs.webkit.org/show_bug.cgi?id=67316
1500         
1501         Move the definition of WTF_USE_AVFOUNDATION on the Mac back to JavaScriptCore/wtf/Platform.h,
1502         since WebKit2 doesn't have access to WebCore/config.h on this platform. This reverts the
1503         changes that were made in r92210.
1504
1505         Reviewed by Darin Adler.
1506
1507         No new tests, covered by existing media tests.
1508
1509         * config.h: Removed definition of WTF_USE_AVFOUNDATION on the Mac, add a comment about fixing this on Windows in the future.
1510
1511 2011-08-31  Sailesh Agrawal  <sail@chromium.org>
1512
1513         [Chromium] Switching between overlay and opaque scrollbars causes glitches
1514         https://bugs.webkit.org/show_bug.cgi?id=62686
1515
1516         Reviewed by Beth Dakin.
1517
1518         When switching from opaque scrollbars to overlay scrollbars the page content size wouldn't change leaving a empty region under the overlay scrollbar.
1519
1520         The problem was that we were relying on ScrollView::updateScrollbars() to kick off a layout. Unfortunately this doesn't happen because updateScrollbars doesn't distinguish between overlay and opaque scrollbars.
1521
1522         To fix this I'm explicitly invalidating the layout when ScrollView::scrollbarStyleChanged() is called.
1523
1524         No tests because there are no Mac 10.7 chromium bots yet. Bug 66504 will track the work to add these tests once the bots are in place.
1525
1526         * platform/ScrollView.cpp:
1527         (WebCore::ScrollView::scrollbarStyleChanged):
1528
1529 2011-08-31  Alexey Proskuryakov  <ap@apple.com>
1530
1531         http/tests/eventsource/workers/eventsource-simple.html is a flaky crash because of
1532         eventsource-status-error-iframe-crash.html
1533         https://bugs.webkit.org/show_bug.cgi?id=61523
1534
1535         Reviewed by Nate Chapin.
1536
1537         The problem here was that canceling EventSource during frame removal erroneously resulted
1538         in event dispatch, and event handler re-entered frame destruction code.
1539
1540         * page/EventSource.h: Renamed endRequest() to networkRequestEnded(), because this method
1541         doesn't end request. It implements "reestablish the connection" or "fail the connection"
1542         algotithms from the spec, depending on current state.
1543         Removed m_failSilently, since we can make this decision with existing data, and want to
1544         fail silently by default (e.g. when detaching a frame cancels all loads).
1545
1546         * page/EventSource.cpp:
1547         (WebCore::EventSource::EventSource): Don't initialize m_failSilently.
1548         (WebCore::EventSource::~EventSource): Assert taht we are in a correct state.
1549         (WebCore::EventSource::connect): Ditto.
1550         (WebCore::EventSource::networkRequestEnded): Moved errorevent dispatch elsewhere.
1551         (WebCore::EventSource::scheduleReconnect): Error event should always be queued when
1552         reconnecting; firing it synchronously after starting m_reconnectTimer implements that.
1553         (WebCore::EventSource::reconnectTimerFired): Assert that state is correct (the timer is
1554         stopped if EventSource is stopped while waiting on the timer).
1555         (WebCore::EventSource::close): Don't set m_state before calling cancel() - it will indirectly
1556         call didFail(), which asserts that EventSource is not stopped yet.
1557         (WebCore::EventSource::didReceiveResponse): Explicitly dispatch an error event, since it
1558         is no longer dispatched when canceling, and canceling is the only way to stop a ThreadableLoader.
1559         Removed a special case for 2xx responses, since it's no longer in the spec.
1560         (WebCore::EventSource::didReceiveData): Assert that state is correct.
1561         (WebCore::EventSource::didFinishLoading): Don't set state to CONNECTING after parsing remaining
1562         response bytes - that may well result in dispatching an event whose handler calls close().
1563         (WebCore::EventSource::didFail): It's simple now - we always reconnect unless the request
1564         got canceled.
1565         (WebCore::EventSource::didFailRedirectCheck): Dispatch error event explicitly, as we are
1566         not going to attempt reconnecting.
1567
1568 2011-08-31  Sheriff Bot  <webkit.review.bot@gmail.com>
1569
1570         Unreviewed, rolling out r94116.
1571         http://trac.webkit.org/changeset/94116
1572         https://bugs.webkit.org/show_bug.cgi?id=67323
1573
1574         caused a lot of tests failures (Requested by thorton on
1575         #webkit).
1576
1577         * platform/graphics/cg/PathCG.cpp:
1578         (WebCore::Path::boundingRect):
1579
1580 2011-08-31  Alexei Svitkine  <asvitkine@chromium.org>
1581
1582         Chromium Mac: Tweak rubber banding overhang shadows. Add a drop shadow from the browser's toolbar.
1583         https://bugs.webkit.org/show_bug.cgi?id=67289
1584
1585         Chromium bug: http://crbug.com/93228
1586
1587         Reviewed by Dimitri Glazkov.
1588
1589         No new tests, since this merely tweaks Chromium overhang area appearance.
1590
1591         * platform/chromium/ScrollbarThemeChromiumMac.mm:
1592         (WebCore::ScrollbarThemeChromiumMac::paintGivenTickmarks):
1593         (WebCore::ScrollbarThemeChromiumMac::paintOverhangAreas):
1594
1595 2011-08-31  Tony Chang  <tony@chromium.org>
1596
1597         Remove webcore_bindings (including DerivedSources##.cpp) from the critical path
1598         https://bugs.webkit.org/show_bug.cgi?id=67168
1599
1600         Reviewed by Adam Barth.
1601
1602         webcore_bindings_sources, debugger_script_source, injected_script_source, and
1603         inspector_protocol_sources generates various files (e.g., CSSPropertyNames,
1604         DerivedSources, HTMLNames, etc).  webcore_bindings depends on *_sources and compiles
1605         these files.  Previously, the other webcore libs (webcore_svg, webcore_html,
1606         webcore_remaining, etc) depended on webcore_bindings.  This moves the *_sources
1607         dependencies from webcore_bindings to the other webcore libs so the build can
1608         parallelize the compile of webcore_bindings and the other webcore_* libs.
1609
1610         Also copy over the include dirs that we used to get from webcore_bindings'
1611         direct_dependent_settings.
1612
1613         No new tests, just changing the build dependencies.
1614
1615         * WebCore.gyp/WebCore.gyp:
1616
1617 2011-08-31  Tony Gentilcore  <tonyg@chromium.org>
1618
1619         Minor cleanup: remove inScriptExecution()
1620         https://bugs.webkit.org/show_bug.cgi?id=67276
1621
1622         Reviewed by Adam Barth.
1623
1624         At one point inScriptExecution() existed as a non-virtual duplicate of isExecutingScript()
1625         to avoid virtual method calls from a tight loop. Now we aren't calling it anywhere perf
1626         sensitive, so remove the duplication.
1627
1628         No new tests because no change in functionality.
1629
1630         * html/parser/HTMLDocumentParser.cpp:
1631         (WebCore::HTMLDocumentParser::isExecutingScript):
1632         (WebCore::HTMLDocumentParser::resumeParsingAfterScriptExecution):
1633         (WebCore::HTMLDocumentParser::notifyFinished):
1634         * html/parser/HTMLDocumentParser.h:
1635         (WebCore::HTMLDocumentParser::shouldDelayEnd):
1636
1637 2011-08-31  Tom Sepez  <tsepez@chromium.org>
1638
1639         Fix XSS filter bypass by multiply decoding both the URL and the body
1640         snippet until they are in the most minimal form before comparison.
1641         https://bugs.webkit.org/show_bug.cgi?id=66585
1642
1643         Reviewed by Adam Barth.
1644
1645         * html/parser/XSSAuditor.cpp:
1646         (WebCore::fullyDecodeString):
1647         (WebCore::XSSAuditor::init):
1648         (WebCore::XSSAuditor::filterToken):
1649         (WebCore::XSSAuditor::isContainedInRequest):
1650
1651 2011-08-31  Simon Fraser  <simon.fraser@apple.com>
1652
1653         Crash with -webkit-radial-gradient(top) gradient
1654         https://bugs.webkit.org/show_bug.cgi?id=66686
1655
1656         Reviewed by Darin Adler.
1657         
1658         Null-check the current value after calling parseFillPosition(),
1659         since it may be null for gradients with degenerate arguments.
1660
1661         Test: fast/gradients/css3-radial-gradient-crash.html
1662
1663         * css/CSSParser.cpp:
1664         (WebCore::CSSParser::parseRadialGradient):
1665
1666 2011-08-31  Nico Weber  <thakis@chromium.org>
1667
1668         Make ScrollAnimator(Chromium)?Mac check scrollAnimatorEnabled()
1669         https://bugs.webkit.org/show_bug.cgi?id=67297
1670
1671         Reviewed by Tony Chang.
1672
1673         I need this to disable smooth scrolling in chromium tests. I'm making
1674         the change to ScrollAnimatorMac to make unforking the file easier. I
1675         changed scrollAnimatorEnabled() to default to true so that this change
1676         is a no-op for Safari; in chromium the flag is set explicitly to true
1677         or false anyway.
1678
1679         * page/Settings.cpp:
1680         (WebCore::Settings::Settings):
1681         * platform/chromium/ScrollAnimatorChromiumMac.mm:
1682         (WebCore::ScrollAnimatorChromiumMac::scroll):
1683         * platform/mac/ScrollAnimatorMac.mm:
1684         (WebCore::ScrollAnimatorMac::scroll):
1685
1686 2011-08-31  Nate Chapin  <japhet@chromium.org>
1687
1688         Don't load resources with empty urls, since this
1689         will resolve to the current document.
1690         https://bugs.webkit.org/show_bug.cgi?id=30303
1691
1692         Reviewed by Darin Adler.
1693
1694         Test: http/tests/loading/empty-urls.html
1695
1696         * dom/ScriptElement.cpp:
1697         (WebCore::ScriptElement::requestScript): If src="", fail through
1698             to the error event case.
1699         * html/HTMLLinkElement.cpp:
1700         (WebCore::HTMLLinkElement::parseMappedAttribute): Ensure the url
1701             stays empty if we try to resolve an empty href.
1702         * loader/ImageLoader.cpp:
1703         (WebCore::ImageLoader::updateFromElement): Throw an error instead of
1704             loading if the src is empty in all cases, not just local files.
1705
1706 2011-08-28  Robert Hogan  <robert@webkit.org>
1707
1708         CSS 2.1 failure: margin-applies-to-015 fails, WebKit does not respect top margin for table captions
1709         https://bugs.webkit.org/show_bug.cgi?id=34763
1710
1711         Reviewed by Simon Fraser.
1712
1713         * rendering/RenderTable.cpp:
1714         (WebCore::RenderTable::adjustLogicalHeightForCaption): Added the caption's margin to the position calculation.
1715
1716 2011-08-30  Oliver Hunt  <oliver@apple.com>
1717
1718         Add support for checked arithmetic
1719         https://bugs.webkit.org/show_bug.cgi?id=67095
1720
1721         Reviewed by Sam Weinig.
1722
1723         Add a forwarding header for CheckedArithmetic.h
1724
1725         * ForwardingHeaders/wtf/CheckedArithmetic.h: Added.
1726
1727 2011-08-31  David Hyatt  <hyatt@apple.com>
1728
1729         https://bugs.webkit.org/show_bug.cgi?id=67300
1730         
1731         Add the new border-image-source property (and its corresponding analogue for masks, mask-box-image-source).
1732         Change the border-image parsing code to no longer consider "none" to represent the entire border-image
1733         expression, but instead to just mean "none" for the image component of the expression.
1734         
1735         Change the pending image code for border-image and mask-box-image to use the new *-source properties when
1736         loading the image so that they're considered the same.
1737         
1738         This is the first step towards eliminating the border-image parsing code in favor of just parsing it as
1739         a shorthand instead, but for now I'm implementing each property one by one, and once they're all there,
1740         we can cut over to border-image as a true shorthand.
1741
1742         Reviewed by Beth Dakin.
1743
1744         Added fast/borders/border-image-source.html.
1745
1746         * css/CSSComputedStyleDeclaration.cpp:
1747         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1748         * css/CSSParser.cpp:
1749         (WebCore::CSSParser::parseValue):
1750         (WebCore::CSSParser::parseBorderImage):
1751         * css/CSSPropertyNames.in:
1752         * css/CSSStyleSelector.cpp:
1753         (WebCore::CSSStyleSelector::applyProperty):
1754         (WebCore::CSSStyleSelector::mapNinePieceImage):
1755         (WebCore::CSSStyleSelector::loadPendingImages):
1756         * rendering/style/NinePieceImage.h:
1757         (WebCore::NinePieceImage::setImage):
1758         * rendering/style/RenderStyle.h:
1759         (WebCore::InheritedFlags::borderImageSource):
1760         (WebCore::InheritedFlags::maskBoxImageSource):
1761         (WebCore::InheritedFlags::setBorderImageSource):
1762         (WebCore::InheritedFlags::setMaskBoxImageSource):
1763         (WebCore::InheritedFlags::initialBorderImageSource):
1764         (WebCore::InheritedFlags::initialMaskBoxImageSource):
1765
1766 2011-08-31  Stephen White  <senorblanco@chromium.org>
1767
1768         [chromium] Set the GrContext before SkGpuDevice is destroyed.
1769         https://bugs.webkit.org/show_bug.cgi?id=67296
1770
1771         When SkGpuDevice is destroyed, it frees the FBO used for accelerated
1772         rendering.  If the wrong context is set (e.g., compositor context),
1773         a crash may result.
1774
1775         Reviewed by Kenneth Russell.
1776
1777         No new tests.  (Unfortunately, wrong-context bugs are difficult to
1778         express in a layout test).
1779
1780         * platform/graphics/skia/ImageBufferSkia.cpp:
1781         (WebCore::ImageBuffer::~ImageBuffer):
1782
1783 2011-08-31  Eric Carlson  <eric.carlson@apple.com>
1784
1785         Clean up HTMLMediaElement behavior restrictions
1786         https://bugs.webkit.org/show_bug.cgi?id=67231
1787
1788         Reviewed by Darin Adler.
1789
1790         No new tests, cleanup only.
1791
1792         * html/HTMLMediaElement.cpp:
1793         (WebCore::HTMLMediaElement::HTMLMediaElement): Deal with enum and function renaming.
1794         (WebCore::HTMLMediaElement::load): Call userGestureRequiredForLoad() instead of testing bits
1795             directly.
1796         (WebCore::HTMLMediaElement::loadInternal): Deal with enum and function renaming.
1797         (WebCore::HTMLMediaElement::play): Call userGestureRequiredForRateChange() instead of testing bits
1798             directly.
1799         (WebCore::HTMLMediaElement::pause): Ditto.
1800         * html/HTMLMediaElement.h:
1801         (WebCore::HTMLMediaElement::userGestureRequiredForLoad): Renamed.
1802         (WebCore::HTMLMediaElement::userGestureRequiredForRateChange):
1803         (WebCore::HTMLMediaElement::userGestureRequiredForFullscreen):
1804         (WebCore::HTMLMediaElement::pageConsentRequiredForLoad):
1805         (WebCore::HTMLMediaElement::addBehaviorRestriction):
1806         (WebCore::HTMLMediaElement::removeBehaviorRestriction):
1807
1808         * html/HTMLVideoElement.cpp:
1809         (WebCore::HTMLVideoElement::webkitEnterFullscreen): requireUserGestureForFullScreen renamed to
1810             userGestureRequiredForFullscreen.
1811
1812 2011-08-31  Andrei Popescu  <andreip@google.com>
1813
1814         Investigate current uses of OS(ANDROID)
1815         https://bugs.webkit.org/show_bug.cgi?id=66761
1816
1817         Reviewed by Darin Adler.
1818
1819         Remove the last legacy Android code.
1820
1821         No new tests needed as the code wasn't tested in the first place.
1822
1823         * bridge/jni/JNIUtility.cpp:
1824         (JSC::Bindings::getJNIEnv):
1825
1826 2011-08-31  Sheriff Bot  <webkit.review.bot@gmail.com>
1827
1828         Unreviewed, rolling out r94082.
1829         http://trac.webkit.org/changeset/94082
1830         https://bugs.webkit.org/show_bug.cgi?id=67291
1831
1832         Breaks trunk (not canary) Chromium Mac builders upon WebKit
1833         roll (Requested by apavlov on #webkit).
1834
1835         * WebCore.gyp/WebCore.gyp:
1836
1837 2011-08-31  No'am Rosenthal  <noam.rosenthal@nokia.com>
1838
1839         [Qt] Add a convenience function to cast a QTransform to TransformationMatrix
1840         https://bugs.webkit.org/show_bug.cgi?id=67246
1841
1842         Reviewed by Andreas Kling.
1843
1844         No new functionality so no new tests.
1845
1846         * platform/graphics/qt/TransformationMatrixQt.cpp:
1847         (WebCore::TransformationMatrix::TransformationMatrix):
1848         * platform/graphics/transforms/TransformationMatrix.h:
1849
1850 2011-08-31  Sheriff Bot  <webkit.review.bot@gmail.com>
1851
1852         Unreviewed, rolling out r94176.
1853         http://trac.webkit.org/changeset/94176
1854         https://bugs.webkit.org/show_bug.cgi?id=67290
1855
1856         This does not fix the build failure on Macs (Requested by
1857         apavlov on #webkit).
1858
1859         * WebCore.gyp/WebCore.gyp:
1860
1861 2011-08-31  Mike Reed  <reed@google.com>
1862
1863         [skia] antialias images if we're rotated
1864         https://bugs.webkit.org/show_bug.cgi?id=67207
1865
1866         Reviewed by Stephen White.
1867
1868         * platform/graphics/skia/ImageSkia.cpp:
1869         (WebCore::hasNon90rotation):
1870         (WebCore::paintSkBitmap):
1871
1872 2011-08-31  Alexander Pavlov  <apavlov@chromium.org>
1873
1874         Web Inspector: Having the "Metrics" pane open affects the node highlight display
1875         https://bugs.webkit.org/show_bug.cgi?id=67278
1876
1877         Reviewed by Yury Semikhatsky.
1878
1879         * inspector/front-end/MetricsSidebarPane.js:
1880         (WebInspector.MetricsSidebarPane.prototype._updateMetrics):
1881
1882 2011-08-31  Ilya Tikhonovsky  <loislo@chromium.org>
1883
1884         Web Inspector: console view does a style recalculation per each addMessage call.
1885         https://bugs.webkit.org/show_bug.cgi?id=67198
1886
1887         It is bad from the performance point of view.
1888
1889         Reviewed by Yury Semikhatsky.
1890
1891         * inspector/front-end/ConsoleView.js:
1892         (WebInspector.ConsoleView.prototype._isScrollIntoViewScheduled):
1893         (WebInspector.ConsoleView.prototype._appendConsoleMessage):
1894
1895 2011-08-31  Alexander Pavlov  <apavlov@chromium.org>
1896
1897         [Chromium] Unreviewed build fix. Restore debugger_script_source target dependency
1898         broken in http://trac.webkit.org/changeset/94082.
1899
1900         * WebCore.gyp/WebCore.gyp:
1901
1902 2011-08-30  Alexander Pavlov  <apavlov@chromium.org>
1903
1904         Early return in CSSPrimitiveValue::getDoubleValueInternal() omits additional invalid enums
1905         https://bugs.webkit.org/show_bug.cgi?id=67139
1906
1907         Reviewed by Darin Adler.
1908
1909         * css/CSSPrimitiveValue.cpp:
1910         (WebCore::isValidCSSUnitTypeForDoubleConversion): Check if a given unit type can be converted to a double.
1911         (WebCore::CSSPrimitiveValue::getDoubleValueInternal): Make use of the new method that explicitly lists all unit types.
1912
1913 2011-08-30  Pavel Podivilov  <podivilov@chromium.org>
1914
1915         Web Inspector: rename sourceFile to uiSourceCode and get rid of sourceFileId where possible.
1916         https://bugs.webkit.org/show_bug.cgi?id=67136
1917
1918         Reviewed by Yury Semikhatsky.
1919
1920         * inspector/front-end/BreakpointManager.js:
1921         (WebInspector.BreakpointManager.prototype.uiSourceCodeAdded):
1922         (WebInspector.BreakpointManager.prototype.breakpointsForUISourceCode):
1923         (WebInspector.BreakpointManager.prototype.setBreakpoint):
1924         (WebInspector.BreakpointManager.prototype._materializeBreakpoint):
1925         (WebInspector.BreakpointManager.prototype._breakpointDebuggerLocationChanged):
1926         (WebInspector.BreakpointManager.prototype._addBreakpointToUI):
1927         (WebInspector.BreakpointManager.prototype._deleteBreakpointFromUI):
1928         (WebInspector.BreakpointManager.prototype.set reset):
1929         (WebInspector.BreakpointManager.prototype.debuggerReset):
1930         * inspector/front-end/BreakpointsSidebarPane.js:
1931         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype.addBreakpoint):
1932         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype.removeBreakpoint):
1933         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype.highlightBreakpoint):
1934         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._createBreakpointItemId):
1935         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointClicked):
1936         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointCheckboxClicked):
1937         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._contextMenu):
1938         * inspector/front-end/CallStackSidebarPane.js:
1939         (WebInspector.CallStackSidebarPane.prototype.update.didGetSourceLine):
1940         (WebInspector.CallStackSidebarPane.prototype.update):
1941         * inspector/front-end/DebuggerPresentationModel.js:
1942         (WebInspector.DebuggerPresentationModel.prototype.linkifyLocation.updateAnchor.didGetLocation):
1943         (WebInspector.DebuggerPresentationModel.prototype.linkifyLocation.updateAnchor):
1944         (WebInspector.DebuggerPresentationModel.prototype.linkifyLocation):
1945         (WebInspector.DebuggerPresentationModel.prototype._addScript.didCreateSourceMapping):
1946         (WebInspector.DebuggerPresentationModel.prototype._addScript):
1947         (WebInspector.DebuggerPresentationModel.prototype._uiSourceCodeReplaced):
1948         (WebInspector.DebuggerPresentationModel.prototype.canEditScriptSource):
1949         (WebInspector.DebuggerPresentationModel.prototype._updateBreakpointsAfterLiveEdit):
1950         (WebInspector.DebuggerPresentationModel.prototype.setFormatSource):
1951         (WebInspector.DebuggerPresentationModel.prototype._addConsoleMessage.didGetUILocation):
1952         (WebInspector.DebuggerPresentationModel.prototype._addConsoleMessage):
1953         (WebInspector.DebuggerPresentationModel.prototype.continueToLine):
1954         (WebInspector.DebuggerPresentationModel.prototype.breakpointsForUISourceCode):
1955         (WebInspector.DebuggerPresentationModel.prototype.setBreakpoint):
1956         (WebInspector.DebuggerPresentationModel.prototype.setBreakpointEnabled):
1957         (WebInspector.DebuggerPresentationModel.prototype.updateBreakpoint):
1958         (WebInspector.DebuggerPresentationModel.prototype.removeBreakpoint):
1959         (WebInspector.DebuggerPresentationModel.prototype.findBreakpoint):
1960         (WebInspector.DebuggerPresentationModel.prototype._breakpointAdded):
1961         (WebInspector.DebuggerPresentationModel.prototype._breakpointRemoved):
1962         (WebInspector.PresentationBreakpoint):
1963         (WebInspector.PresentationBreakpoint.prototype.get url):
1964         (WebInspector.PresentationBreakpoint.prototype.loadSnippet):
1965         (WebInspector.PresenationCallFrame):
1966         (WebInspector.PresenationCallFrame.prototype.get url):
1967         (WebInspector.PresenationCallFrame.prototype.select):
1968         (WebInspector.PresenationCallFrame.prototype.sourceLine):
1969         * inspector/front-end/ScriptsPanel.js:
1970         (WebInspector.ScriptsPanel.prototype.get statusBarItems):
1971         (WebInspector.ScriptsPanel.prototype._uiSourceCodeAdded.get if):
1972         (WebInspector.ScriptsPanel.prototype._showScriptFoldersSettingChanged):
1973         (WebInspector.ScriptsPanel.prototype._addOptionToFilesSelect):
1974         (WebInspector.ScriptsPanel.prototype.setScriptSourceIsBeingEdited):
1975         (WebInspector.ScriptsPanel.prototype._consoleMessagesCleared):
1976         (WebInspector.ScriptsPanel.prototype._consoleMessageAdded):
1977         (WebInspector.ScriptsPanel.prototype._breakpointAdded):
1978         (WebInspector.ScriptsPanel.prototype._breakpointRemoved):
1979         (WebInspector.ScriptsPanel.prototype._debuggerPaused.else.didGetSourceLocation):
1980         (WebInspector.ScriptsPanel.prototype._debuggerPaused):
1981         (WebInspector.ScriptsPanel.prototype.reset):
1982         (WebInspector.ScriptsPanel.prototype._resetFilesSelect):
1983         (WebInspector.ScriptsPanel.prototype.showAnchorLocation):
1984         (WebInspector.ScriptsPanel.prototype._showSourceLine):
1985         (WebInspector.ScriptsPanel.prototype._showSourceFrameAndAddToHistory):
1986         (WebInspector.ScriptsPanel.prototype._createSourceFrame):
1987         (WebInspector.ScriptsPanel.prototype._removeSourceFrame):
1988         (WebInspector.ScriptsPanel.prototype._uiSourceCodeReplaced):
1989         (WebInspector.ScriptsPanel.prototype._sourceFrameLoaded):
1990         (WebInspector.ScriptsPanel.prototype._callFrameSelected.didGetSourceLocation):
1991         (WebInspector.ScriptsPanel.prototype._callFrameSelected):
1992         (WebInspector.ScriptsPanel.prototype._filesSelectChanged):
1993         (WebInspector.ScriptsPanel.prototype._toggleFormatSource):
1994         (WebInspector.SourceFrameDelegateForScriptsPanel):
1995         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.requestContent):
1996         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.setBreakpoint):
1997         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.updateBreakpoint):
1998         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.removeBreakpoint):
1999         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.findBreakpoint):
2000         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.continueToLine):
2001         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.canEditScriptSource):
2002         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.setScriptSource):
2003         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.setScriptSourceIsBeingEdited):
2004         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.suggestedFileName):
2005
2006 2011-08-31  Yuta Kitamura  <yutak@chromium.org>
2007
2008         WebSocket: Load Blob in WebSocketChannel
2009         https://bugs.webkit.org/show_bug.cgi?id=67013
2010
2011         Reviewed by Kent Tamura.
2012
2013         Add WebSocketChannel::enqueueBlobFrame(). It makes WebSocketChannel start loading a Blob
2014         and send a WebSocket frame after the Blob is loaded.
2015
2016         While a Blob is being loaded, subsequent send() requests cannot be processed and are blocked.
2017         Pending requests are stored in m_outgoingFrameQueue. When we have finished loading a Blob,
2018         requests in the queue are allowed to get processed.
2019
2020         No new tests are added, because nobody uses enqueueBlobFrame() yet. New tests will be added
2021         when WebSocket.send(Blob) is implemented, and they will cover this code change.
2022
2023         * websockets/WebSocketChannel.cpp:
2024         ref() is called when m_blobLoader is allocated, and deref() is called in didFinishLoading()
2025         or didFail(). This is necessary because WebSocketChannel must be able to receive callbacks
2026         from FileReaderLoader even if the channel is referred from no other objects.
2027         (WebCore::WebSocketChannel::WebSocketChannel):
2028         (WebCore::WebSocketChannel::didStartLoading):
2029         (WebCore::WebSocketChannel::didReceiveData):
2030         (WebCore::WebSocketChannel::didFinishLoading):
2031         (WebCore::WebSocketChannel::didFail):
2032         When we have failed to load a Blob, fail() is called, and eventually didCloseSocketStream()
2033         will be called. It will clean up the pending requests in the queue.
2034         (WebCore::WebSocketChannel::enqueueBlobFrame):
2035         (WebCore::WebSocketChannel::processOutgoingFrameQueue):
2036         (WebCore::WebSocketChannel::abortOutgoingFrameQueue):
2037         Cancel the Blob loader when the outgoing request queue is about to be aborted. The loader
2038         will not invoke didFail() callback once it is canceled, thus we need to call didFail()
2039         manually so that we can free up the loader and decrement the reference count.
2040
2041 2011-08-31  Yuta Kitamura  <yutak@chromium.org>
2042
2043         WebSocket: Receive binary message as ArrayBuffer
2044         https://bugs.webkit.org/show_bug.cgi?id=67180
2045
2046         Reviewed by Kent Tamura.
2047
2048         Tests: http/tests/websocket/tests/hybi/receive-arraybuffer.html
2049                http/tests/websocket/tests/hybi/workers/receive-arraybuffer.html
2050
2051         * bindings/js/JSMessageEventCustom.cpp:
2052         (WebCore::JSMessageEvent::data): Convert ArrayBuffer to JSValue.
2053         * bindings/v8/custom/V8MessageEventCustom.cpp:
2054         (WebCore::V8MessageEvent::dataAccessorGetter): Convert ArrayBuffer to v8::Value.
2055         * dom/MessageEvent.cpp:
2056         (WebCore::MessageEvent::MessageEvent):
2057         * dom/MessageEvent.h:
2058         Added DataTypeArrayBuffer and ArrayBuffer-related functions.
2059         (WebCore::MessageEvent::create):
2060         (WebCore::MessageEvent::dataAsArrayBuffer):
2061         * websockets/WebSocket.cpp:
2062         (WebCore::WebSocket::didReceiveBinaryData):
2063         Construct an ArrayBuffer from binaryData and raise MessageEvent.
2064
2065 2011-08-31  Keishi Hattori  <keishi@webkit.org>
2066
2067         input color: onchange event is not fired when changing color from color chooser
2068         https://bugs.webkit.org/show_bug.cgi?id=66848
2069
2070         Reviewed by Kent Tamura.
2071
2072         Test: fast/forms/color/input-color-onchange-event.html
2073
2074         * WebCore.exp.in: Added calls used in Internals.cpp.
2075         * html/ColorInputType.cpp:
2076         (WebCore::ColorInputType::colorSelected): Dispatch change event.
2077         * html/HTMLInputElement.cpp:
2078         (WebCore::HTMLInputElement::connectToColorChooser): Added. Called from Internals::connectColorChooserClient.
2079         * html/HTMLInputElement.h:
2080         * testing/Internals.cpp:
2081         (WebCore::Internals::connectColorChooserClient): Added. Connects element as client to color chooser.
2082         (WebCore::Internals::selectColorInColorChooser): Added. Simulate color selection in color chooser.
2083         * testing/Internals.h:
2084         * testing/Internals.idl:
2085
2086 2011-08-31  Kentaro Hara  <haraken@google.com>
2087
2088         Implement Web IDL Constructor extended attribute in IDLParser.pm and CodeGeneratorV8.pm.
2089         https://bugs.webkit.org/show_bug.cgi?id=66536
2090
2091         Reviewed by Adam Barth.
2092
2093         The spec is here: http://www.w3.org/TR/WebIDL/#Constructor
2094
2095         [1] Introduced Web IDL 'Constructor' extended attribute.
2096
2097         [2] Added 'ConstructorWith=ScriptExecutionContext' extended attribute.
2098         - The constructor passes ScriptExecutionContext to a XXX::create() method,
2099         like XXX::create(..., context, ...).
2100
2101         [3] Added 'V8ConstructorSetsActiveDOMWrapper' extended attribute.
2102         - The constructor calls V8DOMWrapper::setJSWrapperForActiveDOMObject()
2103         instead of V8DOMWrapper::setJSWrapperForDOMObject().
2104
2105         [4] Added 'ConstructorRaisesException' extended attribute.
2106         - A placeholder for ExceptionCode is passed to a XXX::create() method,
2107         like XXX::create(..., ec).
2108         - We can use 'ConstructorRaisesException' and 'ConstructorWith=ScriptExecutionContext' together.
2109
2110         Note:
2111         - Constructor overloading is not yet implemented.
2112         - We cannot yet specify [Optional] without CallWithDefaultValue.
2113
2114         Test: Source/WebCore/bindings/scripts/test/TestInterface.idl
2115               Source/WebCore/bindings/scripts/test/TestObj.idl
2116
2117         * bindings/scripts/CodeGeneratorV8.pm:
2118         (GenerateHeader): Generates constructorCallback() header, if 'Constructor' is specified.
2119         (GenerateFunctionCallback): Uses GenerateArgumentsCountCheck() and GenerateParametersCheck().
2120         (GenerateArgumentsCountCheck): Splits out of GenerateFunctionCallback() for reuse.
2121         (GenerateParametersCheck): Ditto.
2122         (GenerateConstructorCallback): Generates constructorCallback() definition.
2123         (GenerateImplementation):
2124         * bindings/scripts/IDLParser.pm:
2125         (parseExtendedAttributes): Previously, only a string in the "A=B, C, D, E=F" format can be parsed. This patch enables to parse a string in the "A=B, C, D, E=F, G(in DOMString s, in [H, I, J] DOMString t)" format.
2126         (parseParameters): Splits out of ParseInterface() for reuse.
2127         (ParseInterface): Uses parseParameters().
2128         * bindings/scripts/IDLStructure.pm: Added domClass{constructor}. Changed the regular expression to extract the list of extended attributes.
2129         * bindings/scripts/test/TestInterface.idl: Added all the extended attributes that this patch is going to introduce.
2130         * bindings/scripts/test/TestObj.idl: Added 'Constructor'.
2131         * bindings/scripts/test/V8/V8TestInterface.cpp: Updated the test result.
2132         (WebCore::V8TestInterface::constructorCallback):
2133         (WebCore::ConfigureV8TestInterfaceTemplate):
2134         * bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp: Ditto.
2135         * bindings/scripts/test/V8/V8TestObj.cpp: Ditto.
2136         (WebCore::V8TestObj::constructorCallback):
2137         * bindings/scripts/test/V8/V8TestObj.h: Ditto.
2138
2139 2011-08-30  Philippe Normand  <pnormand@igalia.com>
2140
2141         [GTK] gstreamer/ files directly related to the MediaPlayer need VIDEO guards
2142         https://bugs.webkit.org/show_bug.cgi?id=67196
2143
2144         Reviewed by Martin Robinson.
2145
2146         Guard those files with ENABLE(VIDEO) so other features using
2147         GStreamer can be built even with VIDEO disabled.
2148
2149         * platform/graphics/gstreamer/GStreamerGWorld.cpp:
2150         * platform/graphics/gstreamer/GStreamerGWorld.h:
2151         * platform/graphics/gstreamer/ImageGStreamer.h:
2152         * platform/graphics/gstreamer/ImageGStreamerCG.mm:
2153         * platform/graphics/gstreamer/ImageGStreamerCairo.cpp:
2154         * platform/graphics/gstreamer/ImageGStreamerQt.cpp:
2155         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
2156         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
2157         * platform/graphics/gstreamer/PlatformVideoWindow.h:
2158         * platform/graphics/gstreamer/PlatformVideoWindowGtk.cpp:
2159         * platform/graphics/gstreamer/VideoSinkGStreamer.cpp:
2160         * platform/graphics/gstreamer/VideoSinkGStreamer.h:
2161         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
2162         * platform/graphics/gstreamer/WebKitWebSourceGStreamer.h:
2163
2164 2011-08-30  Sheriff Bot  <webkit.review.bot@gmail.com>
2165
2166         Unreviewed, rolling out r94142, r94144, r94145, and r94148.
2167         http://trac.webkit.org/changeset/94142
2168         http://trac.webkit.org/changeset/94144
2169         http://trac.webkit.org/changeset/94145
2170         http://trac.webkit.org/changeset/94148
2171         https://bugs.webkit.org/show_bug.cgi?id=67262
2172
2173         Broke isindex element (Requested by rniwa on #webkit).
2174
2175         * WebCore.order:
2176         * accessibility/AXObjectCache.cpp:
2177         (WebCore::AXObjectCache::textMarkerDataForVisiblePosition):
2178         * accessibility/AccessibilityRenderObject.cpp:
2179         (WebCore::AccessibilityRenderObject::isPasswordField):
2180         (WebCore::AccessibilityRenderObject::isIndeterminate):
2181         (WebCore::AccessibilityRenderObject::isNativeCheckboxOrRadio):
2182         (WebCore::AccessibilityRenderObject::isChecked):
2183         * css/CSSStyleSelector.cpp:
2184         (WebCore::CSSStyleSelector::canShareStyleWithControl):
2185         (WebCore::CSSStyleSelector::adjustRenderStyle):
2186         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector):
2187         (WebCore::CSSStyleSelector::applyProperty):
2188         * dom/CheckedRadioButtons.cpp:
2189         (WebCore::CheckedRadioButtons::addButton):
2190         (WebCore::CheckedRadioButtons::removeButton):
2191         * dom/Node.cpp:
2192         (WebCore::Node::toInputElement):
2193         * dom/Node.h:
2194         * editing/FrameSelection.cpp:
2195         (WebCore::FrameSelection::isInPasswordField):
2196         * html/HTMLInputElement.h:
2197         (WebCore::HTMLInputElement::toInputElement):
2198         * html/shadow/SliderThumbElement.cpp:
2199         (WebCore::sliderThumbElementOf):
2200         (WebCore::RenderSliderThumb::layout):
2201         (WebCore::RenderSliderContainer::layout):
2202         (WebCore::SliderThumbElement::hostInput):
2203         (WebCore::trackLimiterElementOf):
2204         * html/shadow/TextControlInnerElements.cpp:
2205         (WebCore::SearchFieldResultsButtonElement::shadowPseudoId):
2206         (WebCore::SearchFieldResultsButtonElement::defaultEventHandler):
2207         (WebCore::SearchFieldCancelButtonElement::defaultEventHandler):
2208         (WebCore::SpinButtonElement::defaultEventHandler):
2209         (WebCore::SpinButtonElement::repeatingTimerFired):
2210         (WebCore::InputFieldSpeechButtonElement::defaultEventHandler):
2211         (WebCore::InputFieldSpeechButtonElement::setRecognitionResult):
2212         * page/DragController.cpp:
2213         (WebCore::asFileInput):
2214         * platform/efl/RenderThemeEfl.cpp:
2215         (WebCore::RenderThemeEfl::paintThemePart):
2216         * rendering/RenderTextControlSingleLine.cpp:
2217         (WebCore::RenderTextControlSingleLine::RenderTextControlSingleLine):
2218         (WebCore::RenderTextControlSingleLine::inputElement):
2219         * rendering/RenderTheme.cpp:
2220         (WebCore::RenderTheme::isChecked):
2221         (WebCore::RenderTheme::isIndeterminate):
2222
2223 2011-08-30  David Levin  <levin@chromium.org>
2224
2225         Quick fix for crashing tests caused by r94142.
2226
2227         Tests:
2228           editing/execCommand/remove-format-elements.html
2229           fast/block/child-not-removed-from-parent-lineboxes-crash.html
2230           fast/forms/implicit-submission.html
2231
2232         * rendering/RenderTextControlSingleLine.cpp:
2233         (WebCore::RenderTextControlSingleLine::RenderTextControlSingleLine): Allow
2234         for isIndex element which is derived from HTMLInputElement.
2235
2236 2011-08-30  Sam Weinig  <sam@webkit.org>
2237
2238         Add constructor for CustomEvent
2239         https://bugs.webkit.org/show_bug.cgi?id=67248
2240
2241         Reviewed by Dan Bernstein.
2242
2243         Test: fast/events/constructors/custom-event-constructor.html
2244
2245         * bindings/generic/EventConstructors.h:
2246         Add definition for CustomEvent constructor.
2247
2248         * bindings/js/JSEventConstructors.cpp:
2249         Add CustomEvent #includes.
2250
2251         * dom/CustomEvent.cpp:
2252         (WebCore::CustomEventInit::CustomEventInit):
2253         (WebCore::CustomEvent::CustomEvent):
2254         * dom/CustomEvent.h:
2255         (WebCore::CustomEvent::create):
2256         Add Initializer./
2257
2258         * dom/CustomEvent.idl:
2259         Make constructible.
2260
2261         * page/DOMWindow.idl:
2262         Add CustomEvent attribute.
2263
2264 2011-08-30  Ryosuke Niwa  <rniwa@webkit.org>
2265
2266         Get rid of toInputElement()
2267         https://bugs.webkit.org/show_bug.cgi?id=67175
2268
2269         Reviewed by Darin Adler.
2270
2271         Got rid of Node::toInputElement and HTMLInputElement::toInputElement and replaced them by
2272         a global toHTMLInputElement.
2273
2274         * WebCore.order:
2275         * accessibility/AXObjectCache.cpp:
2276         (WebCore::AXObjectCache::textMarkerDataForVisiblePosition):
2277         * accessibility/AccessibilityRenderObject.cpp:
2278         (WebCore::AccessibilityRenderObject::isPasswordField):
2279         (WebCore::AccessibilityRenderObject::isIndeterminate):
2280         (WebCore::AccessibilityRenderObject::isNativeCheckboxOrRadio):
2281         (WebCore::AccessibilityRenderObject::isChecked):
2282         * css/CSSStyleSelector.cpp:
2283         (WebCore::CSSStyleSelector::canShareStyleWithControl):
2284         (WebCore::CSSStyleSelector::adjustRenderStyle):
2285         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector):
2286         (WebCore::CSSStyleSelector::applyProperty):
2287         * dom/CheckedRadioButtons.cpp:
2288         (WebCore::CheckedRadioButtons::addButton):
2289         (WebCore::CheckedRadioButtons::removeButton):
2290         * dom/Node.cpp:
2291         * dom/Node.h:
2292         * editing/FrameSelection.cpp:
2293         (WebCore::FrameSelection::isInPasswordField):
2294         * html/HTMLInputElement.h:
2295         (WebCore::toHTMLInputElement):
2296         * html/shadow/SliderThumbElement.cpp:
2297         (WebCore::sliderThumbElementOf):
2298         (WebCore::RenderSliderThumb::layout):
2299         (WebCore::RenderSliderContainer::layout):
2300         (WebCore::SliderThumbElement::hostInput):
2301         (WebCore::trackLimiterElementOf):
2302         * html/shadow/TextControlInnerElements.cpp:
2303         (WebCore::SearchFieldResultsButtonElement::shadowPseudoId):
2304         (WebCore::SearchFieldResultsButtonElement::defaultEventHandler):
2305         (WebCore::SearchFieldCancelButtonElement::defaultEventHandler):
2306         (WebCore::SpinButtonElement::defaultEventHandler):
2307         (WebCore::SpinButtonElement::repeatingTimerFired):
2308         (WebCore::InputFieldSpeechButtonElement::defaultEventHandler):
2309         (WebCore::InputFieldSpeechButtonElement::setRecognitionResult):
2310         * page/DragController.cpp:
2311         (WebCore::asFileInput):
2312         * platform/efl/RenderThemeEfl.cpp:
2313         (WebCore::RenderThemeEfl::paintThemePart):
2314         * rendering/RenderTextControlSingleLine.cpp:
2315         (WebCore::RenderTextControlSingleLine::RenderTextControlSingleLine):
2316         (WebCore::RenderTextControlSingleLine::inputElement):
2317         * rendering/RenderTheme.cpp:
2318         (WebCore::RenderTheme::isChecked):
2319         (WebCore::RenderTheme::isIndeterminate):
2320
2321 2011-08-30  Ryosuke Niwa  <rniwa@webkit.org>
2322
2323         Speculative WinCairo build fix after r94093.
2324
2325         * platform/network/ResourceHandle.h:
2326
2327 2011-08-30  Ryosuke Niwa  <rniwa@webkit.org>
2328
2329         Mac build fix after r94128.
2330
2331         * WebCore.xcodeproj/project.pbxproj:
2332
2333 2011-08-30  Alice Boxhall  <aboxhall@chromium.org>
2334
2335         Correctly report selected text range for accessibility APIs for role=textbox
2336         https://bugs.webkit.org/show_bug.cgi?id=65900
2337
2338         Reviewed by Chris Fleizach.
2339
2340         Test: accessibility/textbox-role-reports-selection.html
2341
2342         * accessibility/AccessibilityRenderObject.cpp:
2343         (WebCore::AccessibilityRenderObject::indexForVisiblePosition):
2344         (WebCore::AccessibilityRenderObject::rootEditableElementForPosition):
2345         (WebCore::AccessibilityRenderObject::nodeIsTextControl):
2346         (WebCore::AccessibilityRenderObject::determineAriaRoleAttribute):
2347         * accessibility/AccessibilityRenderObject.h:
2348
2349 2011-08-30  Rachel Blum  <groby@chromium.org>
2350
2351         The "port" property of an <a> whose href does not specify a port returns the wrong value
2352         https://bugs.webkit.org/show_bug.cgi?id=66081
2353
2354         HTMLAnchorElement now returns "" instead of "0" for unset port
2355         Fixed KURLGoogle.cpp to have same behavior as KURL.cpp when setting port 0
2356         Fixed Location.cpp to have same behavior as KURL.cpp when setting port 0
2357         
2358         Reviewed by Adam Barth.
2359
2360         Tests: fast/dom/HTMLAnchorElement/get-href-attribute-port.html
2361                fast/dom/HTMLAnchorElement/set-href-attribute-port.html
2362                fast/loader/location-port.html
2363                fast/url/segments-from-data-url.html
2364                fast/url/segments.html
2365                fast/url/trivial-segments.html
2366                platform/chromium/fast/dom/HTMLAnchorElement/set-href-attribute-port.html
2367                
2368         * html/HTMLAnchorElement.cpp:
2369         (WebCore::HTMLAnchorElement::port):
2370         * page/Location.cpp:
2371         (WebCore::Location::host):
2372         (WebCore::Location::port):
2373         (WebCore::Location::setPort):
2374         * platform/KURLGoogle.cpp:
2375         (WebCore::KURL::setPort):
2376
2377 2011-08-30  Scott Byer  <scottbyer@chromium.org>
2378
2379         Fix pan scrolling on Windows to be clamped
2380         https://bugs.webkit.org/show_bug.cgi?id=66910
2381
2382         With the recent change to support rubberband scrolling on the Mac, pan
2383         scrolling of overflow divs became unclamped and would scroll infinitely
2384         and along an axis without a scrollbar.
2385
2386         Reviewed by Simon Fraser
2387
2388         Test: platform/win/fast/events/panScroll-correct-direction.html
2389
2390         * rendering/RenderLayer.cpp:
2391         (WebCore::RenderLayer::panScrollFromPoint):
2392         (WebCore::RenderLayer::scrollByRecursively):
2393         * rendering/RenderLayer.h:
2394
2395 2011-08-30  Bill Budge  <bbudge@chromium.org>
2396
2397         This patch makes the XMLHttpRequest method/header validation logic available as
2398         static methods so URL loaders can perform the same checks for untrusted HTTP requests
2399         coming from plugins. 
2400         https://bugs.webkit.org/show_bug.cgi?id=66909
2401
2402         Reviewed by David Levin.
2403
2404         No new tests. Exposes no new functionality.
2405
2406         * CMakeLists.txt:
2407         * GNUmakefile.list.am:
2408         * WebCore.gypi:
2409         * WebCore.pro:
2410         * WebCore.vcproj/WebCore.vcproj:
2411         * platform/network/HTTPValidation.cpp: Added.
2412         (WebCore::isValidHTTPToken):
2413         (WebCore::isValidHTTPHeaderValue):
2414         * platform/network/HTTPValidation.h: Added.
2415         * xml/XMLHttpRequest.cpp:
2416         (WebCore::XMLHttpRequest::isAllowedHTTPMethod):
2417         (WebCore::XMLHttpRequest::uppercaseKnownHTTPMethod):
2418         (WebCore::XMLHttpRequest::isAllowedHTTPHeader):
2419         (WebCore::XMLHttpRequest::open):
2420         (WebCore::XMLHttpRequest::setRequestHeader):
2421         * xml/XMLHttpRequest.h:
2422
2423 2011-08-30  Chris Rogers  <crogers@google.com>
2424
2425         Don't allow nodes of one context to be connected to nodes of another context
2426         https://bugs.webkit.org/show_bug.cgi?id=67245
2427
2428         Reviewed by Dimitri Glazkov.
2429         
2430         Tests: updated webaudio/audionode.html
2431
2432         * webaudio/AudioNode.cpp:
2433         (WebCore::AudioNode::connect):
2434         
2435 2011-08-30  Dan Bernstein  <mitz@apple.com>
2436
2437         WebCore part of <rdar://problem/9281695> Add text search API for getting the DOM range of a text match
2438         https://bugs.webkit.org/show_bug.cgi?id=67230
2439
2440         Reviewed by Darin Adler.
2441
2442         Test: TestWebKitAPI/Tests/mac/DOMRangeOfString.
2443
2444         * WebCore.exp.in: Export Page::rangeOfString().
2445         * dom/Range.h: Added a default ASSERT_NO_EXCEPTION to a few more member functions.
2446         * editing/Editor.cpp:
2447         (WebCore::Editor::findString): Moved most of the logic into rangeOfString(), which this function
2448         now calls, passing in the current selection as the reference range and setting the selection to
2449         the returned range.
2450         (WebCore::Editor::rangeOfString): Added. Contains the find logic from findString().
2451         * editing/Editor.h:
2452         * page/Page.cpp:
2453         (WebCore::Page::rangeOfString): Added. This function is similar to findString(), but it takes an optional
2454         reference range and returns a Range, rather than using the current selection as the reference range and setting the
2455         selection to the next match.
2456         * page/Page.h:
2457
2458 2011-08-30  Sam Weinig  <sam@webkit.org>
2459
2460         Add additional convertValue overloads to JSDictionary
2461         https://bugs.webkit.org/show_bug.cgi?id=67244
2462
2463         Reviewed by Darin Adler.
2464
2465         Add overloads for convertValue that will be needed for Event
2466         constructors.
2467
2468         * bindings/js/JSDictionary.cpp:
2469         (WebCore::JSDictionary::convertValue):
2470         * bindings/js/JSDictionary.h:
2471         Add overloads.  Remove #include of <runtime/Error.h> and just include
2472         <interpreter/CallFrame.h>
2473
2474         * bindings/js/JSEventConstructors.cpp:
2475         Add now necessary #include of <runtime/Error.h>.
2476
2477 2011-08-30  Aaron Colwell  <acolwell@chromium.org>
2478
2479         Add MediaSource API to HTMLMediaElement
2480         https://bugs.webkit.org/show_bug.cgi?id=64731
2481
2482         Reviewed by Eric Carlson.
2483
2484         Tests: http/tests/media/media-source/webm/video-media-source-errors.html
2485                http/tests/media/media-source/webm/video-media-source-play.html
2486                http/tests/media/media-source/webm/video-media-source-seek.html
2487                http/tests/media/media-source/webm/video-media-source-state-changes.html
2488
2489         * Configurations/FeatureDefines.xcconfig:
2490         * GNUmakefile.am:
2491         * dom/EventNames.h:
2492         * features.pri:
2493         * html/HTMLMediaElement.cpp:
2494         (WebCore::HTMLMediaElement::HTMLMediaElement): Added initializers for new member variables.
2495         (WebCore::HTMLMediaElement::prepareForLoad): Close the media source before starting a new load.
2496         (WebCore::HTMLMediaElement::loadResource):
2497             Fail loading if the media source url from another media element is used.
2498         (WebCore::HTMLMediaElement::mediaEngineError):
2499             Make sure the source is in the closed state before firing an emptied event.
2500         (WebCore::HTMLMediaElement::mediaPlayerSourceOpened):
2501             New method called by WebCore::MediaPlayer to signal when the source is open.
2502         (WebCore::HTMLMediaElement::mediaPlayerSourceURL):
2503             New method called by the WebCore::MediaPlayer to determine what the media source URL is for this
2504             HTMLMediaElement instance.
2505         (WebCore::HTMLMediaElement::seek):
2506             Disabled noSeekRequired optimization if a media source is open and resets the source state to SOURCE_OPEN if
2507             it was in the SOURCE_ENDED state when seek() was called.
2508         (WebCore::HTMLMediaElement::webkitSourceAppend):
2509             New method for passing media data from JavaScript to the WebCore::MediaPlayer.
2510         (WebCore::HTMLMediaElement::webkitSourceEndOfStream):
2511             New method that allows JavaScript to signal the end of the stream.
2512         (WebCore::HTMLMediaElement::webkitSourceState): New method allowing JavaScript to read the current source state.
2513         (WebCore::HTMLMediaElement::setSourceState): New method for updating the current source state.
2514         (WebCore::HTMLMediaElement::userCancelledLoad):
2515             Transitions an open source to the closed state before firing an emptied event.
2516         * html/HTMLMediaElement.h:
2517         (WebCore::HTMLMediaElement::webkitMediaSourceURL):
2518             New method providing the media source URL to JavaScript for this HTMLMediaElement instance.
2519         * html/HTMLMediaElement.idl: Added new methods, attributes, and constants for the media source api.
2520         * platform/graphics/MediaPlayer.cpp:
2521         (WebCore::NullMediaPlayerPrivate::sourceAppend):
2522             Stub implementation of new WebCore::MediaPlayerPrivateInterface::sourceAppend.
2523         (WebCore::NullMediaPlayerPrivate::sourceEndOfStream):
2524             Stub implementation of new WebCore::MediaPlayerPrivateInterface::sourceEndOfStream.
2525         (WebCore::MediaPlayer::sourceAppend): New method for receiving media data from WebCore::HTMLMediaElement.
2526         (WebCore::MediaPlayer::sourceEndOfStream): New method for receiving end of stream from WebCore::HTMLMediaElement.
2527         (WebCore::MediaPlayer::sourceOpened):
2528             New method called by the MediaPlayerPrivate object to notify the MediaPlayer when the source has opened.
2529         (WebCore::MediaPlayer::sourceURL):
2530             New method called by the MediaPlayerPrivate implementation to get the media source URL from the MediaPlayer.
2531         * platform/graphics/MediaPlayer.h:
2532         (WebCore::MediaPlayerClient::mediaPlayerSourceOpened):
2533             Interface method used by the MediaPlayer to tell the HTMLMediaElement when the media source has been opened.
2534         (WebCore::MediaPlayerClient::mediaPlayerSourceURL):
2535             Interface method used by the MediaPlayer to get the media source URL from the HTMLMediaElement.
2536         * platform/graphics/MediaPlayerPrivate.h:
2537         (WebCore::MediaPlayerPrivateInterface::sourceAppend):
2538             Interface method used by the MediaPlayer to pass media data to the MediaPlayerPrivate object.
2539         (WebCore::MediaPlayerPrivateInterface::sourceEndOfStream):
2540             Interface method used by the MediaPlayer to pass end of stream information to the MediaPlayerPrivate object.
2541
2542 2011-08-30  Sam Weinig  <sam@webkit.org>
2543
2544         Refactor JS dictionary code into helper class and covert geolocation code to use it
2545         https://bugs.webkit.org/show_bug.cgi?id=67213
2546
2547         Reviewed by Darin Adler.
2548
2549         * GNUmakefile.list.am:
2550         * UseJSC.cmake:
2551         * WebCore.gypi:
2552         * WebCore.pro:
2553         * WebCore.vcproj/WebCore.vcproj:
2554         * WebCore.xcodeproj/project.pbxproj:
2555         * bindings/js/JSBindingsAllInOne.cpp:
2556         Add new files.
2557
2558         * bindings/js/JSDictionary.cpp: Added.
2559         (WebCore::JSDictionary::convertValue):
2560         * bindings/js/JSDictionary.h: Added.
2561         (WebCore::JSDictionary::JSDictionary):
2562         (WebCore::JSDictionary::tryGetProperty):
2563         Encapsulate dictionary initialization code into JSDictionary class.
2564
2565         * bindings/js/JSEventConstructors.cpp:
2566         (WebCore::constructJSEventWithInitializer):
2567         Use JSDictionary.
2568
2569         * bindings/js/JSGeolocationCustom.cpp:
2570         (WebCore::setEnableHighAccuracy):
2571         (WebCore::setTimeout):
2572         (WebCore::setMaximumAge):
2573         (WebCore::createPositionOptions):
2574         Use JSDictionary.
2575
2576 2011-08-30  Scott Byer  <scottbyer@chromium.org>
2577
2578         Switch chromium to use ScrollAnimatorNone on Windows.
2579         https://bugs.webkit.org/show_bug.cgi?id=67000
2580
2581         Reviewed by Adam Barth.
2582
2583         Testing covered by Chromium webkit_unit_tests ScrollAnimatorNoneTest.*
2584
2585         * WebCore.gyp/WebCore.gyp:
2586         * WebCore.gypi:
2587
2588 2011-08-30  Tony Chang  <tony@chromium.org>
2589
2590         refactor and cleanup RenderFlexibleBox
2591         https://bugs.webkit.org/show_bug.cgi?id=67165
2592
2593         Reviewed by Ojan Vafai.
2594
2595         No new tests, just refactoring code.
2596
2597         * rendering/RenderFlexibleBox.cpp:
2598         (WebCore::RenderFlexibleBox::layoutHorizontalBlock):
2599         (WebCore::RenderFlexibleBox::runFreeSpaceAllocationAlgorithmHorizontal): Make childSizes a param so we can pass the results to layoutAndPlaceChildrenHorizontal.
2600         (WebCore::hasPackingSpace): Move closer to where it's used.
2601         (WebCore::RenderFlexibleBox::layoutAndPlaceChildrenHorizontal):
2602             Pull this code out into its own function because it's not part of running the free space allocation algorithm.
2603         * rendering/RenderFlexibleBox.h:
2604
2605 2011-08-30  Tim Horton  <timothy_horton@apple.com>
2606
2607         getBBox() on a SVGPathElement with curves incorrectly includes control points
2608         https://bugs.webkit.org/show_bug.cgi?id=53512
2609         <rdar://problem/9861154>
2610
2611         Reviewed by Dirk Schulze.
2612
2613         The CoreGraphics implementation of Path::boundingRect() called
2614         CGPathGetBoundingBox, which includes the path's control points in its
2615         calculations. Snow Leopard added CGPathGetPathBoundingBox, which
2616         finds the bounding box of only points within the path, and does not
2617         include control points. On Snow Leopard and above, we now use the latter.
2618
2619         Test: svg/custom/getBBox-path.svg
2620
2621         * platform/graphics/cg/PathCG.cpp:
2622         (WebCore::Path::boundingRect):
2623
2624 2011-08-30  Tim Horton  <timothy_horton@apple.com>
2625
2626         SVG panning y-axis is flipped in WebKit2
2627         https://bugs.webkit.org/show_bug.cgi?id=65800
2628         <rdar://problem/9908012>
2629
2630         Reviewed by Darin Adler.
2631
2632         We previously were not transforming the pointer coordinates passed
2633         to SVGDocument's panning implementation into the coordinate space of
2634         the contents, so on different platforms, the drag direction was different.
2635
2636         Test: svg/custom/pan-direction.svg
2637
2638         * page/EventHandler.cpp:
2639         (WebCore::EventHandler::handleMousePressEvent):
2640         (WebCore::EventHandler::handleMouseMoveEvent):
2641         (WebCore::EventHandler::handleMouseReleaseEvent):
2642         * svg/SVGDocument.cpp:
2643         (WebCore::SVGDocument::startPan):
2644         (WebCore::SVGDocument::updatePan):
2645
2646 2011-08-30  Adam Barth  <abarth@webkit.org>
2647
2648         Flaky crash with JavaScript URLs
2649         https://bugs.webkit.org/show_bug.cgi?id=66360
2650
2651         Reviewed by Nate Chapin.
2652
2653         This patch teaches DocumentWriter::begin to make a copy of the URL
2654         before beginning a new document to avoid a crash.
2655
2656         Test: fast/loader/javascript-url-iframe-crash.html
2657
2658         * loader/DocumentWriter.cpp:
2659         (WebCore::DocumentWriter::begin):
2660
2661 2011-08-30  Tony Gentilcore  <tonyg@chromium.org>
2662
2663         PreloadScanner shouldn't load images inside noscript via doc.write
2664         https://bugs.webkit.org/show_bug.cgi?id=67214
2665
2666         Reviewed by Adam Barth.
2667
2668         The problem was that the tokenizer state was lost between each call to document.write.
2669         This works around that bug by making all document.write()s in the same script block share
2670         the same tokenizer state.
2671
2672         Test: fast/preloader/document-write-noscript.html
2673
2674         * html/parser/HTMLDocumentParser.cpp:
2675         (WebCore::HTMLDocumentParser::~HTMLDocumentParser):
2676         (WebCore::HTMLDocumentParser::detach):
2677         (WebCore::HTMLDocumentParser::insert):
2678         * html/parser/HTMLDocumentParser.h:
2679
2680 2011-08-30  Dmitry Titov  <dimich@chromium.org>
2681
2682         https://bugs.webkit.org/show_bug.cgi?id=67210
2683         [Chromium] Use after free in ScheduledAction::execute(WebCore::V8Proxy*)
2684
2685         Reviewed by David Levin.
2686
2687         * bindings/v8/ScheduledAction.cpp:
2688         (WebCore::ScheduledAction::execute):
2689         Removed usage of V8Proxy instance after it could have been deleted.
2690
2691         * bindings/v8/V8Proxy.cpp:
2692         (WebCore::V8Proxy::V8Proxy):
2693         * bindings/v8/V8Proxy.h:
2694         Removed unused timerCallback() and setTimerCallback().
2695
2696 2011-08-30  Abhishek Arya  <inferno@chromium.org>
2697
2698         Style not updated for table parts in :before, :after content.
2699         https://bugs.webkit.org/show_bug.cgi?id=66141        
2700
2701         Reviewed by Dave Hyatt.
2702
2703         Tests: fast/table/table-before-child-style-update.html
2704                fast/table/table-row-before-child-style-update.html
2705
2706         * rendering/RenderObjectChildList.cpp:
2707         (WebCore::RenderObjectChildList::updateBeforeAfterContent):
2708
2709 2011-08-30  Tony Chang  <tony@chromium.org>
2710
2711         refactor box-ordinal-group handling so we don't timeout on large values
2712         https://bugs.webkit.org/show_bug.cgi?id=65783
2713
2714         Reviewed by David Hyatt.
2715
2716         The old code walked from 1 to the last box-ordinal-group while
2717         iterating over each flex item.  The new code collects ordinals as
2718         we do the first walk and sorts them.  Each additional iteration
2719         through the flex items gets the next oridnal from the sorted list.
2720
2721         This maintains the single pass for the common case of no
2722         box-ordinal-groups specified.  If there are ordinal groups,
2723         the runtime is O(n*m + m lg m) where n is the # of flex items and
2724         m is the number of unique box-ordinal-group values.  The memory
2725         usage is O(2m).
2726
2727         Test: fast/flexbox/box-ordinal-group.html
2728
2729         * rendering/RenderDeprecatedFlexibleBox.cpp:
2730         (WebCore::FlexBoxIterator::FlexBoxIterator):
2731         (WebCore::FlexBoxIterator::reset):
2732         (WebCore::FlexBoxIterator::next):
2733         (WebCore::FlexBoxIterator::compareFlexOrder):
2734
2735 2011-08-30  Abhishek Arya  <inferno@chromium.org>
2736
2737         Removed m_owner accessed in custom scrollbars.
2738         https://bugs.webkit.org/show_bug.cgi?id=64737
2739
2740         Reviewed by David Hyatt.
2741
2742         Problem does not reproduce in DRT, even with Eventhandler tricks
2743         and gc(). So, adding a manual test.
2744
2745         * manual-tests/custom-scrollbar-renderer-removed-crash.html: Added.
2746         * page/FrameView.cpp:
2747         (WebCore::FrameView::clearOwningRendererForCustomScrollbars):
2748         * page/FrameView.h:
2749         * rendering/RenderBox.cpp:
2750         (WebCore::RenderBox::willBeDestroyed): when this renderbox is getting
2751         destroyed, clear the custom scrollbar in this frameview having this renderbox
2752         as its owning renderer.
2753         * rendering/RenderScrollbar.cpp:
2754         (WebCore::RenderScrollbar::getScrollbarPseudoStyle): fix the null check.
2755
2756 2011-08-30  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
2757
2758         Emit last progress notification before calling dispatchDidFinishLoad
2759         https://bugs.webkit.org/show_bug.cgi?id=28851
2760
2761         Reviewed by Adam Barth.
2762
2763         Original patch by Xan Lopez. Change FrameLoader to dispatch the notifications in
2764         a more natural sequence.
2765
2766         Test: http/tests/loading/progress-finished-callback.html
2767
2768         * loader/FrameLoader.cpp:
2769         (WebCore::FrameLoader::checkLoadCompleteForThisFrame):
2770
2771 2011-08-30  Ojan Vafai  <ojan@chromium.org>
2772
2773         CSS parsing for -webkit-flex-flow
2774         https://bugs.webkit.org/show_bug.cgi?id=67224
2775
2776         Reviewed by Tony Chang.
2777         
2778         Adds support for the first value of -webkit-flex-flow.
2779         Later we'll need to add support for the second "wrap" value,
2780         but that can wait until we are ready to implement multiline
2781         flex and the spec has stabilized a bit.
2782
2783         * css/CSSComputedStyleDeclaration.cpp:
2784         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
2785         * css/CSSParser.cpp:
2786         (WebCore::CSSParser::parseValue):
2787         * css/CSSPrimitiveValueMappings.h:
2788         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
2789         (WebCore::CSSPrimitiveValue::operator EFlexFlow):
2790         * css/CSSPropertyNames.in:
2791         * css/CSSStyleApplyProperty.cpp:
2792         (WebCore::CSSStyleApplyProperty::CSSStyleApplyProperty):
2793         * css/CSSStyleSelector.cpp:
2794         (WebCore::CSSStyleSelector::applyProperty):
2795         * css/CSSValueKeywords.in:
2796         * rendering/style/RenderStyle.h:
2797         (WebCore::InheritedFlags::flexFlow):
2798         (WebCore::InheritedFlags::setFlexFlow):
2799         (WebCore::InheritedFlags::initialFlexFlow):
2800         * rendering/style/RenderStyleConstants.h:
2801         * rendering/style/StyleFlexibleBoxData.cpp:
2802         (WebCore::StyleFlexibleBoxData::StyleFlexibleBoxData):
2803         (WebCore::StyleFlexibleBoxData::operator==):
2804         * rendering/style/StyleFlexibleBoxData.h:
2805
2806 2011-08-30  Dawit Alemayehu  <adawit@kde.org>
2807
2808         [Qt] Replace QLibrary("libgtk-x11-2.0.so.0") with QLibrary("libgtk-x11-2.0", 0)
2809         https://bugs.webkit.org/show_bug.cgi?id=66627
2810
2811         Reviewed by Simon Hausmann.
2812
2813         * plugins/qt/PluginPackageQt.cpp:
2814         (WebCore::initializeGtk):
2815
2816 2011-08-29  Oliver Hunt  <oliver@apple.com>
2817
2818         TypedArrays don't ensure that denormalised values are normalised
2819         https://bugs.webkit.org/show_bug.cgi?id=67178
2820
2821         Reviewed by Gavin Barraclough.
2822
2823         Ensure that we convert singaling nans to silent nans when loading
2824         from a typed array. 
2825
2826         * bindings/scripts/CodeGeneratorJS.pm:
2827         (GenerateImplementation):
2828
2829 2011-08-29  Alexey Proskuryakov  <ap@apple.com>
2830
2831         DumpRenderTree should begin each test with an empty cookie store
2832         https://bugs.webkit.org/show_bug.cgi?id=63545
2833         <rdar://problem/5666907>
2834
2835         Reviewed by Darin Adler.
2836
2837         Use a clean CFURLStorageSession when this functionality is available.
2838
2839         * WebCore.exp.in: Added exports.
2840
2841         * WebCore.xcodeproj/project.pbxproj: Made CookieStorageCFNet.h private, as currentCFHTTPCookieStorage
2842         is used in WebKit.
2843
2844         * platform/mac/CookieJar.mm:
2845         (WebCore::cookies):
2846         (WebCore::cookieRequestHeaderFieldValue):
2847         (WebCore::setCookies):
2848         (WebCore::cookiesEnabled):
2849         (WebCore::getRawCookies):
2850         (WebCore::deleteCookie):
2851         Updated to use currentCFHTTPCookieStorage().
2852
2853         * platform/network/CookieStorage.h: Moved CFNetwork specific declarations to CookieStorageCFNet.h.
2854
2855         * platform/network/ResourceHandle.cpp: Moved CFNetwork specific code to ResourceHandleCFNet.cpp.
2856
2857         * platform/network/ResourceHandle.h: Exposed default session support on Mac, too. Made
2858         privateBrowsingStorageSession() private, as callers shouldn't be concerned about where the
2859         current sssion came from.
2860
2861         * platform/network/cf/CookieJarCFNet.cpp:
2862         (WebCore::setCookies):
2863         (WebCore::cookies):
2864         (WebCore::cookieRequestHeaderFieldValue):
2865         (WebCore::cookiesEnabled):
2866         (WebCore::getRawCookies):
2867         (WebCore::deleteCookie):
2868         (WebCore::getHostnamesWithCookies):
2869         (WebCore::deleteCookiesForHostname):
2870         (WebCore::deleteAllCookies):
2871         Updated to use currentCFHTTPCookieStorage().
2872
2873         * platform/network/cf/CookieStorageCFNet.cpp:
2874         (WebCore::cookieStorageOverride): Make it clear that this override is only for a Windows API.
2875         (WebCore::overrideCookieStorage): Ditto.
2876         (WebCore::currentCFHTTPCookieStorage): We no longer store a cookie storage in a static variable,
2877         unless it has been overridden on Windows. We can always get it from a session.
2878         (WebCore::setCookieStoragePrivateBrowsingEnabled): There is nothing to do here - we'll just
2879         use private session's storage. Note that Mac has a separate code path for OS versions that
2880         don't support sessions.
2881         (WebCore::startObservingCookieChanges): Updated to use currentCFHTTPCookieStorage().
2882         (WebCore::stopObservingCookieChanges): Ditto.
2883
2884         * platform/network/cf/CookieStorageCFNet.h: Changed exposed methods for more clarity.
2885
2886         * platform/network/cf/ResourceHandleCFNet.cpp:
2887         (WebCore::makeFinalRequest): Updated for currentCookieStorage->currentCFHTTPCookieStorage change.
2888         (WebCore::ResourceHandle::createPrivateBrowsingStorageSession): Moved out of USE(CFNETWORK),
2889         as this function is also used with NSURLConnection when sessions are enabled.
2890         (WebCore::ResourceHandle::currentStorageSession): Ditto. Removed an #if since default session
2891         is now supported on Mac, too.
2892         (WebCore::defaultCFURLStorageSession): Moved out of USE(CFNETWORK).
2893         (WebCore::ResourceHandle::setDefaultStorageSession): Moved out of USE(CFNETWORK). No longer
2894         adopt the session, because nothing in method name says that it will steal a reference from
2895         the caller.
2896         (WebCore::ResourceHandle::defaultStorageSession): Moved out of USE(CFNETWORK).
2897         (WebCore::privateStorageSession): Moved from ResourceHandle.cpp.
2898         (WebCore::privateBrowsingStorageSessionIdentifierBase): Moved from ResourceHandle.cpp.
2899         (WebCore::ResourceHandle::setPrivateBrowsingEnabled): Moved from ResourceHandle.cpp.
2900         (WebCore::ResourceHandle::privateBrowsingStorageSession): Moved from ResourceHandle.cpp.
2901         (WebCore::ResourceHandle::setPrivateBrowsingStorageSessionIdentifierBase): Moved from ResourceHandle.cpp.
2902         (WebCore::ResourceHandle::privateBrowsingStorageSessionIdentifierDefaultBase): Moved from ResourceHandle.cpp.
2903
2904         * platform/network/mac/CookieStorageMac.mm: (WebCore::setCookieStoragePrivateBrowsingEnabled):
2905         We no longer store a reference to cookie storage in a static variable, so nothing to do here.
2906         On older OS versiosn, we still need to enable legacy private browsing mode.
2907
2908         * platform/network/mac/ResourceHandleMac.mm:
2909         (WebCore::shouldRelaxThirdPartyCookiePolicy): Updated to use the new currentCFHTTPCookieStorage function.
2910         (WebCore::ResourceHandle::createNSURLConnection): Updated to use currentStorageSession()
2911         instead of privateBrowsingStorageSession().
2912         (WebCore::ResourceHandle::willSendRequest): Ditto.
2913
2914 2011-08-30  David Hyatt  <hyatt@apple.com>
2915
2916         <rdar://problem/10002140> 9A309: Text gets clipped in book because of overflow:auto
2917         
2918         https://bugs.webkit.org/show_bug.cgi?id=67212 - Text gets clipped in multi-column layouts when overflow:auto
2919         is used.
2920         
2921         Revise our overflow:auto pagination behavior. If the overflow block doesn't specify any logical height
2922         information, then we'll just assume the plan is for it to enclose its contents, and we will be willing
2923         to paginate in those circumstances.
2924
2925         Reviewed by Dan Bernstein.
2926
2927         Added overflow-across-columns.html and overflow-unsplittable.html
2928
2929         * rendering/LayoutState.cpp:
2930         (WebCore::LayoutState::LayoutState):
2931         * rendering/RenderBlock.cpp:
2932         (WebCore::RenderBlock::adjustForUnsplittableChild):
2933         * rendering/RenderBox.cpp:
2934         (WebCore::RenderBox::hasUnsplittableScrollingOverflow):
2935         * rendering/RenderBox.h:
2936
2937 2011-08-30  Antti Koivisto  <antti@apple.com>
2938
2939         querySelector/querySelectorAll should use selector checker fast path 
2940         https://bugs.webkit.org/show_bug.cgi?id=67161
2941
2942         Reviewed by Sam Weinig.
2943
2944         Descendant and child selectors can be matches substantially faster using
2945         SelectorChecker::fastCheckSelector() path. Currently it is used for style matching only.  
2946         
2947         Add SelectorQuery class that can do both querySelector and querySelectorAll efficiently using
2948         fast path. Use inlined loop for DOM traversal.
2949         
2950         The patch is ~25% speedup in the overall native score of http://www.webkit.org/perf/slickspeed/.
2951         Some individual subtests (using child or descendant selectors) execute twice as fast.
2952
2953         * CMakeLists.txt:
2954         * GNUmakefile.list.am:
2955         * WebCore.gypi:
2956         * WebCore.pro:
2957         * WebCore.vcproj/WebCore.vcproj:
2958         * WebCore.xcodeproj/project.pbxproj:
2959         * css/CSSStyleSelector.cpp:
2960         (WebCore::CSSStyleSelector::SelectorChecker::checkSelector):
2961         (WebCore::CSSStyleSelector::SelectorChecker::isFastCheckableSelector):
2962         (WebCore::RuleData::RuleData):
2963         * css/CSSStyleSelector.h:
2964         
2965             Make fast path checking available outside CSSStyleSelector.
2966             
2967         * dom/DOMAllInOne.cpp:
2968         * dom/Node.cpp:
2969         (WebCore::Node::querySelector):
2970         (WebCore::Node::querySelectorAll):
2971         
2972             Switch to SelectorQuery.
2973         
2974         * dom/SelectorNodeList.cpp: Removed.
2975         * dom/SelectorNodeList.h: Removed.
2976         
2977             SelectorQuery makes these obsolete.
2978
2979         * dom/SelectorQuery.cpp: Added.
2980         (WebCore::SelectorQuery::SelectorQuery):
2981         (WebCore::SelectorQuery::queryAll):
2982         (WebCore::SelectorQuery::queryFirst):
2983         (WebCore::SelectorQuery::canUseIdLookup):
2984         (WebCore::SelectorQuery::execute):
2985         * dom/SelectorQuery.h: Added.
2986         
2987             Class for selector matching in tree.
2988     
2989 2011-08-30  Dmitry Titov  <dimich@chromium.org>
2990
2991         REGRESSION (r93913): Failures in fast/replaced/frame-removed-during-resize.html and scrollbars/scrollable-iframe-remove-crash.html
2992         https://bugs.webkit.org/show_bug.cgi?id=67074
2993
2994         Reviewed by Darin Adler.
2995
2996         Added flag m_isClosed to prevent events that cause Frame to be destroyed
2997         from posting more events into EventQueue of a dying Document.
2998
2999         The tests mentioned above should now pass.
3000
3001         * dom/Document.cpp:
3002         (WebCore::Document::detach):
3003         * dom/EventQueue.cpp:
3004         (WebCore::EventQueue::EventQueue):
3005         (WebCore::EventQueue::enqueueEvent):
3006         (WebCore::EventQueue::close): Renamed method to reflect better what it does.
3007         * dom/EventQueue.h:
3008
3009 2011-08-30  Tony Chang  <tony@chromium.org>
3010
3011         Fix compile warning on clang:
3012         error: 'WebKit::ChromeClientImpl::scrollRectIntoView' hides overloaded virtual function [-Werror,-Woverloaded-virtual]
3013             virtual void scrollRectIntoView(
3014                              ^
3015         ../../WebCore/page/ChromeClient.h:171:22: note: hidden overloaded virtual function 'WebCore::ChromeClient::scrollRectIntoView' declared here
3016             virtual void scrollRectIntoView(const IntRect&) { }; // Currently only Mac has a non empty implementation.
3017
3018         * page/ChromeClient.h:
3019         (WebCore::ChromeClient::scrollRectIntoView):
3020
3021 2011-08-30  David Hyatt  <hyatt@apple.com>
3022
3023         <rdar://problem/8832814> With large line-height, column break can happen anywhere in the
3024         inter-line gap, causing staggered lines.
3025         
3026         https://bugs.webkit.org/show_bug.cgi?id=67202 Handle positive leading when paginating lines.
3027         
3028         Technically we should paginate lines based solely off their line top and line bottom with
3029         leading included. However there are two issues with always doing so. The first is that overflow
3030         can cause lines to overlap, and the second is that negative leading can cause lines to overlap.
3031
3032         Since we're incapable of dealing with overlap until we stop clipping column boxes and allow them
3033         to have a form of specialized overflow, we still have to at least factor in overflow and ignore
3034         negative leading for now. However we can at least honor positive leading when the lines don't
3035         overlap. This patch provides basic support for paginating when positive leading is involved.
3036
3037         Reviewed by Dan Bernstein.
3038
3039         Added fast/multicol/positive-leading.html.
3040
3041         * rendering/RenderBlock.cpp:
3042         (WebCore::RenderBlock::markLinesDirtyInBlockRange):
3043         Renamed blockLogicalHeight() to lineBottomWithLeading(). The value is the same.
3044
3045         (WebCore::RenderBlock::adjustLinePositionForPagination):
3046         Grow the top and extent of the line to include our leading when deciding how to paginate
3047         the line.
3048
3049         * rendering/RenderBlockLineLayout.cpp:
3050         (WebCore::RenderBlock::computeBlockDirectionPositionsForLine):
3051         (WebCore::RenderBlock::layoutRunsAndFloatsInRange):
3052         (WebCore::RenderBlock::linkToEndLineIfNeeded):
3053         (WebCore::RenderBlock::checkFloatsInCleanLine):
3054         (WebCore::RenderBlock::determineStartPosition):
3055         (WebCore::RenderBlock::determineEndPosition):
3056         (WebCore::RenderBlock::matchedEndLine):
3057         Renamed blockLogicalHeight() to lineBottomWithLeading(). The value is the same.
3058
3059         * rendering/RootInlineBox.cpp:
3060         (WebCore::RootInlineBox::RootInlineBox):
3061         (WebCore::RootInlineBox::adjustPosition):
3062         (WebCore::RootInlineBox::alignBoxesInBlockDirection):
3063         * rendering/RootInlineBox.h:
3064         (WebCore::RootInlineBox::lineTopWithLeading):
3065         (WebCore::RootInlineBox::lineBottomWithLeading):
3066         (WebCore::RootInlineBox::setLineTopBottomPositions):
3067         Instead of one member variable, blockLogicalHeight(), RootInlineBoxes now know both their top and
3068         bottom including leading. These values are obtainable using lineTopWithLeading() and lineBottomWithLeading().
3069         Add these two values to the setLineTopBottomPositions setter and remove setBlockLogicalHeight.
3070
3071         * rendering/svg/SVGRootInlineBox.cpp:
3072         (WebCore::SVGRootInlineBox::layoutRootBox):
3073         Renamed blockLogicalHeight() to lineBottomWithLeading(). The value is the same.
3074
3075 2011-08-29  Chris Marrin  <cmarrin@apple.com>
3076
3077         Rename GraphicsContext3DInternal to GraphicsContext3DPrivate and add a dummy version of this class for Mac
3078         https://bugs.webkit.org/show_bug.cgi?id=67172
3079
3080         Reviewed by Kenneth Russell.
3081
3082         * GNUmakefile.list.am:
3083         * platform/graphics/GraphicsContext3D.h:
3084         * platform/graphics/chromium/Extensions3DChromium.h:
3085         * platform/graphics/gtk/GraphicsContext3DGtk.cpp:
3086         (WebCore::GraphicsContext3D::create):
3087         (WebCore::GraphicsContext3D::GraphicsContext3D):
3088         (WebCore::GraphicsContext3D::~GraphicsContext3D):
3089         (WebCore::GraphicsContext3D::makeContextCurrent):
3090         (WebCore::GraphicsContext3D::platformGraphicsContext3D):
3091         * platform/graphics/gtk/GraphicsContext3DInternal.h: Removed.
3092         * platform/graphics/gtk/GraphicsContext3DPrivate.h: Copied from Source/WebCore/platform/graphics/gtk/GraphicsContext3DInternal.h.
3093         * platform/graphics/mac/GraphicsContext3DMac.mm:
3094         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
3095         (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
3096         (WebCore::GraphicsContext3D::GraphicsContext3D):
3097         * platform/graphics/qt/GraphicsContext3DQt.cpp:
3098         (WebCore::GraphicsContext3DPrivate::GraphicsContext3DPrivate):
3099         (WebCore::GraphicsContext3DPrivate::~GraphicsContext3DPrivate):
3100         (WebCore::GraphicsContext3DPrivate::getViewportGLWidget):
3101         (WebCore::GraphicsContext3DPrivate::paintToTextureMapper):
3102         (WebCore::GraphicsContext3DPrivate::boundingRect):
3103         (WebCore::GraphicsContext3DPrivate::paint):
3104         (WebCore::GraphicsContext3DPrivate::blitMultisampleFramebuffer):
3105         (WebCore::GraphicsContext3DPrivate::blitMultisampleFramebufferAndRestoreContext):
3106         (WebCore::GraphicsContext3D::create):
3107         (WebCore::GraphicsContext3D::GraphicsContext3D):
3108         (WebCore::GraphicsContext3D::~GraphicsContext3D):
3109         (WebCore::GraphicsContext3D::platformGraphicsContext3D):
3110         (WebCore::GraphicsContext3D::platformLayer):
3111         (WebCore::GraphicsContext3D::makeContextCurrent):
3112         (WebCore::GraphicsContext3D::paintRenderingResultsToCanvas):
3113         (WebCore::GraphicsContext3D::reshape):
3114         (WebCore::GraphicsContext3D::activeTexture):
3115         (WebCore::GraphicsContext3D::attachShader):
3116         (WebCore::GraphicsContext3D::getAttachedShaders):
3117         (WebCore::GraphicsContext3D::bindAttribLocation):
3118         (WebCore::GraphicsContext3D::bindBuffer):
3119         (WebCore::GraphicsContext3D::bindFramebuffer):
3120         (WebCore::GraphicsContext3D::bindRenderbuffer):
3121         (WebCore::GraphicsContext3D::bindTexture):
3122         (WebCore::GraphicsContext3D::blendColor):
3123         (WebCore::GraphicsContext3D::blendEquation):
3124         (WebCore::GraphicsContext3D::blendEquationSeparate):
3125         (WebCore::GraphicsContext3D::blendFunc):
3126         (WebCore::GraphicsContext3D::blendFuncSeparate):
3127         (WebCore::GraphicsContext3D::bufferData):
3128         (WebCore::GraphicsContext3D::bufferSubData):
3129         (WebCore::GraphicsContext3D::checkFramebufferStatus):
3130         (WebCore::GraphicsContext3D::clearColor):
3131         (WebCore::GraphicsContext3D::clear):
3132         (WebCore::GraphicsContext3D::clearDepth):
3133         (WebCore::GraphicsContext3D::clearStencil):
3134         (WebCore::GraphicsContext3D::colorMask):
3135         (WebCore::GraphicsContext3D::compileShader):
3136         (WebCore::GraphicsContext3D::copyTexImage2D):
3137         (WebCore::GraphicsContext3D::copyTexSubImage2D):
3138         (WebCore::GraphicsContext3D::cullFace):
3139         (WebCore::GraphicsContext3D::depthFunc):
3140         (WebCore::GraphicsContext3D::depthMask):
3141         (WebCore::GraphicsContext3D::depthRange):
3142         (WebCore::GraphicsContext3D::detachShader):
3143         (WebCore::GraphicsContext3D::disable):
3144         (WebCore::GraphicsContext3D::disableVertexAttribArray):
3145         (WebCore::GraphicsContext3D::drawArrays):
3146         (WebCore::GraphicsContext3D::drawElements):
3147         (WebCore::GraphicsContext3D::enable):
3148         (WebCore::GraphicsContext3D::enableVertexAttribArray):
3149         (WebCore::GraphicsContext3D::finish):
3150         (WebCore::GraphicsContext3D::flush):
3151         (WebCore::GraphicsContext3D::framebufferRenderbuffer):
3152         (WebCore::GraphicsContext3D::framebufferTexture2D):
3153         (WebCore::GraphicsContext3D::frontFace):
3154         (WebCore::GraphicsContext3D::generateMipmap):
3155         (WebCore::GraphicsContext3D::getActiveAttrib):
3156         (WebCore::GraphicsContext3D::getActiveUniform):
3157         (WebCore::GraphicsContext3D::getAttribLocation):
3158         (WebCore::GraphicsContext3D::getError):
3159         (WebCore::GraphicsContext3D::getString):
3160         (WebCore::GraphicsContext3D::hint):
3161         (WebCore::GraphicsContext3D::isBuffer):
3162         (WebCore::GraphicsContext3D::isEnabled):
3163         (WebCore::GraphicsContext3D::isFramebuffer):
3164         (WebCore::GraphicsContext3D::isProgram):
3165         (WebCore::GraphicsContext3D::isRenderbuffer):
3166         (WebCore::GraphicsContext3D::isShader):
3167         (WebCore::GraphicsContext3D::isTexture):
3168         (WebCore::GraphicsContext3D::lineWidth):
3169         (WebCore::GraphicsContext3D::linkProgram):
3170         (WebCore::GraphicsContext3D::pixelStorei):
3171         (WebCore::GraphicsContext3D::polygonOffset):
3172         (WebCore::GraphicsContext3D::readPixels):
3173         (WebCore::GraphicsContext3D::releaseShaderCompiler):
3174         (WebCore::GraphicsContext3D::renderbufferStorage):
3175         (WebCore::GraphicsContext3D::sampleCoverage):
3176         (WebCore::GraphicsContext3D::scissor):
3177         (WebCore::GraphicsContext3D::shaderSource):
3178         (WebCore::GraphicsContext3D::stencilFunc):
3179         (WebCore::GraphicsContext3D::stencilFuncSeparate):
3180         (WebCore::GraphicsContext3D::stencilMask):
3181         (WebCore::GraphicsContext3D::stencilMaskSeparate):
3182         (WebCore::GraphicsContext3D::stencilOp):
3183         (WebCore::GraphicsContext3D::stencilOpSeparate):
3184         (WebCore::GraphicsContext3D::texParameterf):
3185         (WebCore::GraphicsContext3D::texParameteri):
3186         (WebCore::GraphicsContext3D::uniform1f):
3187         (WebCore::GraphicsContext3D::uniform1fv):
3188         (WebCore::GraphicsContext3D::uniform2f):
3189         (WebCore::GraphicsContext3D::uniform2fv):
3190         (WebCore::GraphicsContext3D::uniform3f):
3191         (WebCore::GraphicsContext3D::uniform3fv):
3192         (WebCore::GraphicsContext3D::uniform4f):
3193         (WebCore::GraphicsContext3D::uniform4fv):
3194         (WebCore::GraphicsContext3D::uniform1i):
3195         (WebCore::GraphicsContext3D::uniform1iv):
3196         (WebCore::GraphicsContext3D::uniform2i):
3197         (WebCore::GraphicsContext3D::uniform2iv):
3198         (WebCore::GraphicsContext3D::uniform3i):
3199         (WebCore::GraphicsContext3D::uniform3iv):
3200         (WebCore::GraphicsContext3D::uniform4i):
3201         (WebCore::GraphicsContext3D::uniform4iv):
3202         (WebCore::GraphicsContext3D::uniformMatrix2fv):
3203         (WebCore::GraphicsContext3D::uniformMatrix3fv):
3204         (WebCore::GraphicsContext3D::uniformMatrix4fv):
3205         (WebCore::GraphicsContext3D::useProgram):
3206         (WebCore::GraphicsContext3D::validateProgram):
3207         (WebCore::GraphicsContext3D::vertexAttrib1f):
3208         (WebCore::GraphicsContext3D::vertexAttrib1fv):
3209         (WebCore::GraphicsContext3D::vertexAttrib2f):
3210         (WebCore::GraphicsContext3D::vertexAttrib2fv):
3211         (WebCore::GraphicsContext3D::vertexAttrib3f):
3212         (WebCore::GraphicsContext3D::vertexAttrib3fv):
3213         (WebCore::GraphicsContext3D::vertexAttrib4f):
3214         (WebCore::GraphicsContext3D::vertexAttrib4fv):
3215         (WebCore::GraphicsContext3D::vertexAttribPointer):
3216         (WebCore::GraphicsContext3D::viewport):
3217         (WebCore::GraphicsContext3D::getBooleanv):
3218         (WebCore::GraphicsContext3D::getBufferParameteriv):
3219         (WebCore::GraphicsContext3D::getFloatv):
3220         (WebCore::GraphicsContext3D::getFramebufferAttachmentParameteriv):
3221         (WebCore::GraphicsContext3D::getIntegerv):
3222         (WebCore::GraphicsContext3D::getProgramiv):
3223         (WebCore::GraphicsContext3D::getProgramInfoLog):
3224         (WebCore::GraphicsContext3D::getRenderbufferParameteriv):
3225         (WebCore::GraphicsContext3D::getShaderiv):
3226         (WebCore::GraphicsContext3D::getShaderInfoLog):
3227         (WebCore::GraphicsContext3D::getShaderSource):
3228         (WebCore::GraphicsContext3D::getTexParameterfv):
3229         (WebCore::GraphicsContext3D::getTexParameteriv):
3230         (WebCore::GraphicsContext3D::getUniformfv):
3231         (WebCore::GraphicsContext3D::getUniformiv):
3232         (WebCore::GraphicsContext3D::getUniformLocation):
3233         (WebCore::GraphicsContext3D::getVertexAttribfv):
3234         (WebCore::GraphicsContext3D::getVertexAttribiv):
3235         (WebCore::GraphicsContext3D::getVertexAttribOffset):
3236         (WebCore::GraphicsContext3D::texImage2D):
3237         (WebCore::GraphicsContext3D::texSubImage2D):
3238         (WebCore::GraphicsContext3D::createBuffer):
3239         (WebCore::GraphicsContext3D::createFramebuffer):
3240         (WebCore::GraphicsContext3D::createProgram):
3241         (WebCore::GraphicsContext3D::createRenderbuffer):
3242         (WebCore::GraphicsContext3D::createShader):
3243         (WebCore::GraphicsContext3D::createTexture):
3244         (WebCore::GraphicsContext3D::deleteBuffer):
3245         (WebCore::GraphicsContext3D::deleteFramebuffer):
3246         (WebCore::GraphicsContext3D::deleteProgram):
3247         (WebCore::GraphicsContext3D::deleteRenderbuffer):
3248         (WebCore::GraphicsContext3D::deleteShader):
3249         (WebCore::GraphicsContext3D::deleteTexture):
3250
3251 2011-08-30  Tony Chang  <tony@chromium.org>
3252
3253         Remove webcore_bindings (including DerivedSources##.cpp) from the critical path
3254         https://bugs.webkit.org/show_bug.cgi?id=67168
3255
3256         Reviewed by Adam Barth.
3257
3258         webcore_bindings_sources generates various files (e.g., CSSPropertyNames,
3259         DerivedSources, HTMLNames, etc).  webcore_bindings depends on webcore_bindings_sources
3260         and compiles these files.  Previously, the other webcore libs (webcore_svg,
3261         webcore_html, webcore_remaining, etc) depended on webcore_bindings.  This changes the
3262         dependency on webocre_bindings_sources so the build can parallelize the compile of
3263         webcore_bindings and the other webcore_* libs.
3264
3265         No new tests, just changing the build dependencies.  Manually copy over the
3266         include dirs that we used to get from webcore_bindings' direct_dependent_settings.
3267
3268         * WebCore.gyp/WebCore.gyp:
3269
3270 2011-08-30  Kaustubh Atrawalkar  <kaustubh@motorola.com>
3271
3272         The unused ScrollView* argument can and should be removed from
3273         scrollRectIntoView.
3274         https://bugs.webkit.org/show_bug.cgi?id=67117
3275
3276         Reviewed by Darin Adler.
3277
3278         * loader/EmptyClients.h:
3279         (WebCore::EmptyChromeClient::scrollRectIntoView):
3280         * page/Chrome.cpp:
3281         (WebCore::Chrome::scrollRectIntoView):
3282         * page/ChromeClient.h:
3283         (WebCore::ChromeClient::scrollRectIntoView):
3284
3285 2011-08-30  Ben Wells  <benwells@chromium.org>
3286
3287         Update registerProtocolHandler scheme whitelist to match spec
3288         https://bugs.webkit.org/show_bug.cgi?id=67104
3289
3290         Reviewed by Darin Adler.
3291
3292         * page/Navigator.cpp:
3293         (WebCore::initProtocolHandlerWhitelist):
3294
3295 2011-08-30  Vsevolod Vlasov  <vsevik@chromium.org>
3296
3297         Web Inspector: Inspected page sometimes crashes in InspectorResourceAgent::didFailLoading
3298         https://bugs.webkit.org/show_bug.cgi?id=67193
3299
3300         Reviewed by Pavel Feldman.
3301
3302         * inspector/InspectorResourceAgent.cpp:
3303         (WebCore::InspectorResourceAgent::didFailLoading):
3304
3305 2011-08-30  Ademar de Souza Reis Jr.  <ademar.reis@openbossa.org>
3306
3307         [Qt] Do not unconditionally use pkg-config in .pro files
3308         https://bugs.webkit.org/show_bug.cgi?id=67055
3309
3310         Reviewed by Andreas Kling.
3311
3312         Original patch from Rohan McGovern <rohan.mcgovern@nokia.com>
3313
3314         Using the first pkg-config in PATH is prone to errors when cross
3315         compiling inside the Qt repository (using Qt's build-system).
3316
3317         This patch protect calls for pkg-config with
3318         !contains(QT_CONFIG, no-pkg-config). no-pkg-config is added to
3319         QT_CONFIG by Qt's 'configure' when cross-compiling on systems
3320         without pkg-config.
3321
3322         The respective change in Qt's configure has been submited already.
3323
3324         No new tests as this is just a build change.
3325
3326         * features.pri: protect pkg-config calls
3327
3328 2011-08-30  Andreas Kling  <kling@webkit.org>
3329
3330         HTMLImageElement: Don't cache "ismap" and "usemap" attributes.
3331         https://bugs.webkit.org/show_bug.cgi?id=66784
3332
3333         Reviewed by Darin Adler.
3334
3335         * html/HTMLImageElement.h: Remove the "ismap" and "usemap" members,
3336         shrinking HTMLImageElement by 16 bytes (on 64-bit.)
3337         * html/HTMLImageElement.cpp:
3338         (WebCore::HTMLImageElement::HTMLImageElement):
3339         (WebCore::HTMLImageElement::parseMappedAttribute): Most of the logic
3340         for "ismap" and "usemap" moved into isServerMap().
3341         (WebCore::HTMLImageElement::isServerMap): Out-of-lined and implemented
3342         using fast*Attribute().
3343
3344 2011-08-30  Ryosuke Niwa  <rniwa@webkit.org>
3345
3346         lastChangeWasUserEdit continues to return true when innerText or textContent is modified
3347         https://bugs.webkit.org/show_bug.cgi?id=67183
3348
3349         Reviewed by Kent Tamura.
3350
3351         Fixed the bug by calling setLastChangeWasNotUserEdit in HTMLTextAreaElement::childrenChanged.
3352
3353         Also got rid of HTMLTextFormControlElement::subtreeHasChanged because it was a needless indirection.
3354
3355         * html/HTMLInputElement.cpp:
3356         (WebCore::HTMLInputElement::subtreeHasChanged): No longer calls HTMLTextFormControlElement::subtreeHasChanged.
3357         * html/HTMLTextAreaElement.cpp:
3358         (WebCore::HTMLTextAreaElement::childrenChanged): Calls setLastChangeWasNotUserEdit.
3359         (WebCore::HTMLTextAreaElement::subtreeHasChanged): No longer calls HTMLTextFormControlElement::subtreeHasChanged.
3360         * html/HTMLTextFormControlElement.cpp:
3361         (WebCore::HTMLTextFormControlElement::defaultEventHandler): Merged subtreeHasChanged.
3362         (WebCore::HTMLTextFormControlElement::setInnerTextValue): No longer set m_lastChangeWasUserEdit to false
3363         since this is now done when renderers are set dirty.
3364         * html/HTMLTextFormControlElement.h: Made subtreeHasChanged a pure virtual function.
3365
3366 2011-08-29  Yury Semikhatsky  <yurys@chromium.org>
3367
3368         Web Inspector: wrong script display name when there is a slash in its URL query parameters
3369         https://bugs.webkit.org/show_bug.cgi?id=67120
3370
3371         Fixed folder name computation in ScriptsPanel. Now search query is ignored
3372         when searching for the script folder name.
3373
3374         Reviewed by Pavel Feldman.
3375
3376         * inspector/front-end/ScriptsPanel.js:
3377         (WebInspector.ScriptsPanel.prototype._folderAndDisplayNameForScriptURL):
3378
3379 2011-08-29  Yury Semikhatsky  <yurys@chromium.org>
3380
3381         Return value of window.onerror has inverted semantics
3382         https://bugs.webkit.org/show_bug.cgi?id=67119
3383
3384         Error is now treated as handled only when window.onerror function returns true.
3385
3386         Reviewed by Darin Adler.
3387
3388         Test: fast/events/window-onerror13.html
3389
3390         * bindings/js/JSErrorHandler.cpp:
3391         (WebCore::JSErrorHandler::handleEvent):
3392         * bindings/v8/V8WindowErrorHandler.cpp:
3393         (WebCore::V8WindowErrorHandler::callListenerFunction):
3394         * bindings/v8/V8WorkerContextErrorHandler.cpp:
3395         (WebCore::V8WorkerContextErrorHandler::callListenerFunction):
3396
3397 2011-08-29  Ryosuke Niwa  <rniwa@webkit.org>
3398
3399         Touch Internals.cpp in an attempt to fix GTK+ build.
3400
3401         * testing/Internals.cpp:
3402
3403 2011-08-29  Ryosuke Niwa  <rniwa@webkit.org>
3404
3405         Move setInnerTextValue from RenderTextControl to HTMLTextFormControlElement
3406         https://bugs.webkit.org/show_bug.cgi?id=67152
3407
3408         Reviewed by Darin Adler.
3409
3410         Moved setInnerTextValue from RenderTextControl to HTMLTextFormControlElement.
3411
3412         Also moved m_lastChangeWasUserEdit from RenderTextControl to HTMLTextFormControlElement
3413         and related inline functions from RenderTextControl to HTMLTextFormControlElement.
3414         Because m_lastChangeWasUserEdit is no longer reset when RenderTextControl is recreated,
3415         added explicit calls to setLastChangeWasNotUserEdit in setValue functions of HTMLInputElement
3416         and HTMLTextAreaElement.
3417
3418         This patch also fixes the bug that lastChangeWasUserEdit() incorrectly returns false
3419         when input or textarea don't have renderer (e.g. invisible).
3420
3421         Unfortunately, there is no way to test this behavioral change from layout tests.
3422
3423         * WebCore.exp.in: Exports lastChangeWasUserEdit in HTMLTextFormControlElement instead of
3424         that of HTMLInputElement and HTMLTextAreaElement.
3425         * html/HTMLInputElement.cpp:
3426         (WebCore::HTMLInputElement::setValue): Explicitly calls setLastChangeWasNotUserEdit.
3427         * html/HTMLInputElement.h:
3428         * html/HTMLTextAreaElement.cpp:
3429         (WebCore::HTMLTextAreaElement::setValueCommon): Ditto.
3430         * html/HTMLTextAreaElement.h:
3431         * html/HTMLTextFormControlElement.cpp:
3432         (WebCore::HTMLTextFormControlElement::HTMLTextFormControlElement):
3433         (WebCore::HTMLTextFormControlElement::subtreeHasChanged): Sets m_lastChangeWasUserEdit true
3434         as it used to do via respondToChangeByUser.
3435         (WebCore::HTMLTextFormControlElement::lastChangeWasUserEdit): Moved from HTMLInputElement
3436         and HTMLTextAreaElement.
3437         (WebCore::HTMLTextFormControlElement::setInnerTextValue): Moved from RenderTextControl.
3438         * html/HTMLTextFormControlElement.h:
3439         (WebCore::HTMLTextFormControlElement::setLastChangeWasNotUserEdit): Added.
3440         * rendering/RenderTextControl.cpp:
3441         (WebCore::RenderTextControl::RenderTextControl): No longer initializes m_lastChangeWasUserEdit.
3442         * rendering/RenderTextControl.h: