Reviewed by Adam Roben.
[WebKit-https.git] / WebCore / ChangeLog
1 2008-11-13  Eric Seidel  <eric@webkit.org>
2
3         Reviewed by Adam Roben.
4
5         Add a basic Scons-based build system for building
6         Chromium-Mac WebCore.
7         https://bugs.webkit.org/show_bug.cgi?id=21991
8
9         The build currently fails due to missing files from our
10         platform directory (platform skia and platform chromium)
11         I will be sending those up shortly in separate patches.
12         I expect it will be a while before our WebCore build links.
13
14         * SConstruct: Added.
15         * WebCore.scons: Added.
16
17 2008-11-13  Darin Fisher  <darin@chromium.org>
18
19         Reviewed by Darin Adler.
20
21         https://bugs.webkit.org/show_bug.cgi?id=22248
22         AtomicString.cpp uses JSC types outside of #if USE(JSC)
23
24         * platform/text/AtomicString.cpp:
25         (WebCore::AtomicString::add):
26
27 2008-11-13  Justin Garcia  <justin.garcia@apple.com>
28
29         Reviewed by Darin Adler.
30         
31         https://bugs.webkit.org/show_bug.cgi?id=18620
32         Long hang under TextIterator::advance() when loading http://www.lsvd.de/
33
34         A huge section at the beginning of this document is invisible.  As we iterate through it,
35         we create VisiblePositions unnecessarily.
36
37         * editing/TextIterator.cpp:
38         (WebCore::TextIterator::shouldRepresentNodeOffsetZero): Don't proceed to VisiblePosition 
39         creation if m_node is unrendered or invisible.  The answers wouldn't have much meaning 
40         and would be wasteful.  Also fixed some comments to reflect the fact that this function
41         isn't specifically about emitting a newline.
42
43 2008-11-13  Pierre-Olivier Latour  <pol@apple.com>
44
45         Reviewed by Sam Weinig.
46
47         Remove unused or unnecessary code from AnimationBase class.
48
49         * page/animation/AnimationBase.cpp:
50         (WebCore::AnimationBase::AnimationBase):
51         (WebCore::AnimationBase::playStatePlaying):
52         * page/animation/AnimationBase.h:
53
54 2008-11-12  Tor Arne Vestbø  <tavestbo@trolltech.com>
55
56         Reviewed by Simon Hausmann.
57
58         Inital implementation of PluginPackage and PluginView for Mac NPAPI support in WebCore
59
60         Currently only used by QtWebKit. See also:
61
62         https://bugs.webkit.org/show_bug.cgi?id=21427
63
64         * WebCore.pro:
65         * platform/qt/TemporaryLinkStubs.cpp:
66         (PluginView::userAgentStatic):
67         (PluginView::getValueStatic):
68         * plugins/PluginView.cpp:
69         (WebCore::PluginView::handleEvent):
70         (WebCore::PluginView::setValue):
71         (WebCore::PluginView::PluginView):
72         * plugins/PluginView.h:
73         (WebCore::PluginView::setPlatformPluginWidget):
74         * plugins/mac/PluginPackageMac.cpp: Added.
75         (WebCore::PluginPackage::determineQuirks):
76         (WebCore::readPListFile):
77         (WebCore::stringListFromResourceId):
78         (WebCore::PluginPackage::fetchInfo):
79         (WebCore::PluginPackage::load):
80         (WebCore::PluginPackage::hash):
81         (WebCore::PluginPackage::equal):
82         (WebCore::PluginPackage::compareFileVersion):
83         * plugins/mac/PluginViewMac.cpp: Added.
84         (WebCore::nativeWindowFor):
85         (WebCore::cgHandleFor):
86         (WebCore::topLevelOffsetFor):
87         (WebCore::PluginView::init):
88         (WebCore::PluginView::~PluginView):
89         (WebCore::PluginView::stop):
90         (WebCore::PluginView::getValueStatic):
91         (WebCore::PluginView::getValue):
92         (WebCore::PluginView::setParent):
93         (WebCore::PluginView::show):
94         (WebCore::PluginView::hide):
95         (WebCore::PluginView::setFocus):
96         (WebCore::PluginView::setParentVisible):
97         (WebCore::PluginView::setNPWindowRect):
98         (WebCore::PluginView::setNPWindowIfNeeded):
99         (WebCore::PluginView::updatePluginWidget):
100         (WebCore::PluginView::paint):
101         (WebCore::PluginView::invalidateRect):
102         (WebCore::PluginView::invalidateRegion):
103         (WebCore::PluginView::forceRedraw):
104         (WebCore::PluginView::handleMouseEvent):
105         (WebCore::PluginView::handleKeyboardEvent):
106         (WebCore::PluginView::nullEventTimerFired):
107         (WebCore::modifiersForEvent):
108         (WebCore::PluginView::globalMousePosForPlugin):
109         (WebCore::PluginView::dispatchNPEvent):
110         (WebCore::PluginView::userAgent):
111         (WebCore::PluginView::userAgentStatic):
112         (WebCore::PluginView::handlePostReadFile):
113
114 2008-11-12  Alexey Proskuryakov  <ap@webkit.org>
115
116         Reviewed by Darin Adler.
117
118         https://bugs.webkit.org/show_bug.cgi?id=22200
119         Crash when close event is dispatched to MessagePort due to document destruction
120
121         Test: fast/events/message-port-onclose.html
122
123         * dom/MessagePort.cpp: (WebCore::MessagePort::contextDestroyed):
124         Don't dispatch close event, even though HTML5 currently says that we should. It is not
125         right for GC to have observable effects.
126
127 2008-11-12  Alexey Proskuryakov  <ap@webkit.org>
128
129         Reviewed by Darin Adler.
130
131         https://bugs.webkit.org/show_bug.cgi?id=22203
132         Implement Worker messaging
133
134         No test cases included, because this functionality is disabled by default.
135
136         The implementation is known to still have many race condition, but works quite well for
137         testing.
138
139         * WebCore.xcodeproj/project.pbxproj: Added WorkerTask.{h,cpp}.
140
141         * bindings/js/JSDOMBinding.cpp:
142         (WebCore::markActiveObjectsForContext): Re-worded comments a little.
143         (WebCore::markCrossHeapDependentObjectsForContext): Existing cross-heap GC protocol was
144         incorrect, changed it to a much simpler (but still incorrect) version.
145
146         * dom/WorkerTask.cpp: Added.
147         (WebCore::WorkerTask::~WorkerTask):
148         * dom/WorkerTask.h: Added.
149         Tasks posted to workers implement this new interface.
150
151         * bindings/js/JSDedicatedWorkerCustom.cpp:
152         (WebCore::JSDedicatedWorker::mark):
153         (WebCore::JSDedicatedWorker::connect):
154         * dom/DedicatedWorker.h:
155         * dom/DedicatedWorker.idl:
156         Auto-generate event listener attributes. Renamed startConversation() to connect(), tracking
157         WHATWG discussions.
158
159         * dom/DedicatedWorker.cpp:
160         (WebCore::WorkerConnectTask::WorkerConnectTask): A task that performs worker-side connect()
161         operations.
162         (WebCore::DedicatedWorker::DedicatedWorker): Initialize WorkerThread pointer.
163         (WebCore::DedicatedWorker::connect): Connect() creates a pair of entangled ports, and posts
164         one to worker. Since message port registration in ScriptExecutionContext is not thread safe,
165         this port starts with a null context pointer.
166         (WebCore::DedicatedWorker::notifyFinished): Since Worker methods should work immediately
167         after creation, we have to queue tasks until after a WorkerThread object is created. Then we
168         forward all queued tasks to its queue.
169
170         * dom/EventTarget.cpp: (WebCore::EventTarget::toWorkerContext):
171         * dom/EventTarget.h:
172         * bindings/js/JSEventTarget.cpp: (WebCore::toJS):
173         Added cases for WorkerContext, which is now an EventTarget, too.
174
175         * bindings/js/JSWorkerContext.h: Added JSWorkerContext::put() to make onconnect settable.
176         * bindings/js/JSWorkerContext.cpp:
177         (WebCore::JSWorkerContext::mark): Mark event listeners.
178         (WebCore::JSWorkerContext::createPrototype): Fixed a typo, use the right StructureID.
179         (WebCore::JSWorkerContext::put): Implemented.
180         (WebCore::jsWorkerContextPrototypeFunctionAddEventListener): Added an EventTarget implementation.
181         (WebCore::jsWorkerContextPrototypeFunctionRemoveEventListener): Ditto.
182         (WebCore::jsWorkerContextPrototypeFunctionDispatchEvent): Ditto.
183         (WebCore::jsWorkerContextOnconnect): Added.
184         (WebCore::setJSWorkerContextOnconnect): Added.
185
186         * bindings/js/WorkerScriptController.cpp: (WebCore::WorkerScriptController::evaluate):
187         Made it actually work by adding necessary setup.
188
189         * bindings/js/WorkerScriptController.h: (WebCore::WorkerScriptController::initScriptIfNeeded):
190         Check the right variable - it is the wrapper that may not be initialized yet.
191
192         * dom/ActiveDOMObject.cpp:
193         (WebCore::ActiveDOMObject::ActiveDOMObject):
194         (WebCore::ActiveDOMObject::~ActiveDOMObject):
195         Assert being called from the correct thread, as active DOM object tracking is not thread safe.
196
197         * dom/ScriptExecutionContext.h: Added a Task interface and a postTask() method, to be used
198         for asynchronously executing tasks in context's thread.
199
200         * dom/ScriptExecutionContext.cpp:
201         (WebCore::ProcessMessagesSoonTask): Changed from a Timer to a Task
202         (WebCore::ScriptExecutionContext::ScriptExecutionContext): Removed m_firedMessagePortTimer.
203         It was an optimization that couldn't be easily preserved without introducing race conditions
204         in multithreading case.
205         (WebCore::ScriptExecutionContext::processMessagePortMessagesSoon): Use postTask().
206         (WebCore::ScriptExecutionContext::dispatchMessagePortEvents): Added a comment explaining
207         why it's OK to not ref() ports in a frozen copy.
208         (WebCore::ScriptExecutionContext::createdMessagePort): Assert that we're not being called
209         from a wrong thread.
210         (WebCore::ScriptExecutionContext::destroyedMessagePort): Ditto.
211         (WebCore::ScriptExecutionContextTaskTimer): Part of
212         ScriptExecutionContext::Task implementation - use Timer if posting from main thread to main
213         thread.
214         (WebCore::ScriptExecutionContextTaskWorkerTask): Another part - use WorkerTask if posting
215         to a worker.
216         (WebCore::PerformTaskContext::PerformTaskContext): Finally, use callOnMainThread() if posting
217         to main thread from a secondary one.
218         (WebCore::performTask): A helper function for callOnMainThread().
219         (WebCore::ScriptExecutionContext::postTask): Use one of the above implementations.
220
221         * dom/MessagePort.h: Fixed message queue to keep EventData pointers - otherwise, we would
222         ref/deref EventData::message from different threads, which is not allowed.
223
224         * dom/MessagePort.cpp:
225         (WebCore::MessagePortCloseEventTask): Use a task instead of a timer to work across threads.
226         (WebCore::MessagePort::EventData::create): Updated for EventData being refcountable now.
227         (WebCore::MessagePort::EventData::EventData): Ditto.
228         (WebCore::MessagePort::MessagePort): ScriptExecutionContext is now allowed to be null at
229         first, because we need to create ports for posting to other threads, and it is not possible
230         to register in a context from another thread.
231         (WebCore::MessagePort::clone): Always create ports with null contexts - it is now message
232         receiver's job to set the context.
233         (WebCore::MessagePort::postMessage): Enable posting to ports that are not attached to any
234         context yet.
235         (WebCore::MessagePort::startConversation): Ditto. Data port is always posted unattached.
236         (WebCore::MessagePort::contextDestroyed): Assert that we had a context.
237         (WebCore::MessagePort::attachToContext): Called when receiving a data port to register in
238         context.
239         (WebCore::MessagePort::scriptExecutionContext): Moved from header, as the function is virtual.
240         (WebCore::MessagePort::dispatchMessages): Attach data port to receiving context. Use postTask().
241         (WebCore::MessagePort::queueCloseEvent): Use postTask().
242         (WebCore::MessagePort::hasPendingActivity): Reworded comment a little. As mentioned above,
243         MessagePort cross-heap GC is still quite wrong.
244
245         * dom/WorkerContext.h: Made WorkerContext an event target, added onconnect attribute.
246         * dom/WorkerContext.cpp: Keep a pointer to WorkerThread. It is only used for debug assertions
247         now, but there is no harm in tracking it in release builds, too.
248
249         * dom/WorkerThread.cpp:
250         (WebCore::WorkerThread::create): WorkerThread is refcountable, construct with create().
251         (WebCore::WorkerThread::workerThread): Implemented a message loop.
252         * dom/WorkerThread.h:
253         (WebCore::WorkerThread::threadID): Also only used for assertions.
254         (WebCore::WorkerThread::messageQueue): Return a reference to queue, so clients can post to it.
255
256         * page/DOMWindow.cpp:
257         (WebCore::DOMWindow::postMessage): MessagePort::clone() no longer takes a context, as it
258         always sets it to null.
259         (WebCore::DOMWindow::postMessageTimerFired): Attach data port to receiving context.
260
261 2008-11-12  Dirk Schulze  <vbs85@gmx.de>
262
263         Reviewed Darin Adler.
264
265         use strokeColor.alpha() instead of fillColor.alpha()
266         on GraphicsContext::strokePath()
267
268         [Canvas] Transparent fillStyle stops line rendering
269         https://bugs.webkit.org/show_bug.cgi?id=21888
270
271         Test: fast/canvas/canvas-stroke-empty-fill.html
272
273         * ChangeLog:
274         * platform/graphics/cg/GraphicsContextCG.cpp:
275         (WebCore::GraphicsContext::strokePath):
276
277 2008-11-12  Stephanie  <slewis@apple.com>
278
279         Reviewed by Mark Rowe.
280
281         Fix context leak in XSLStyleSheets.
282         See bug https://bugs.webkit.org/show_bug.cgi?id=15715
283
284         * xml/XSLStyleSheet.cpp:
285         (WebCore::XSLStyleSheet::parseString):
286
287 2008-11-12  Alp Toker  <alp@nuanti.com>
288
289         autotools: List web worker-related headers needed for a successful
290         build. distcheck is passing again with this change.
291
292         * GNUmakefile.am:
293
294 2008-11-12  Alp Toker  <alp@nuanti.com>
295
296         autotools build system fix-up only. Add FloatQuad.h to the source
297         lists and sort them.
298
299         * GNUmakefile.am:
300
301 2008-11-12  Alp Toker  <alp@nuanti.com>
302
303         Build fixes for r38346. FloatQuad.cpp is missing:
304
305         1) #include "config.h"
306         2) #include <algorithm> for various mathematical definitions it uses.
307
308         * platform/graphics/FloatQuad.cpp:
309
310 2008-11-12  Simon Fraser  <simon.fraser@apple.com>
311
312         Reviewed by Dan Bernstein
313
314         https://bugs.webkit.org/show_bug.cgi?id=22212
315
316         Rename absoluteOutlineBox() to absoluteOutlineBounds(), to indicate that
317         it may be the bounding outline box of a transformed element, and fix it
318         to respect transforms by mapping the outline box to an absolute quad and
319         taking the enclosing rect.
320         
321         RenderBox::localToAbsoluteQuad() can no longer assert that there is no
322         LayoutState, but LayoutState cannot be used during quad mapping (it knows
323         nothing about transforms).
324         
325         Finally, fix a bug in RenderBox::localToAbsoluteQuad() which was getting
326         borderTopExtra() from the object, rather than its container (as localToAbsolute()
327         does).
328         
329         Test: fast/repaint/transform-absolute-child.html
330
331         * rendering/RenderBlock.cpp:
332         (WebCore::RenderBlock::layoutBlock):
333         * rendering/RenderBox.cpp:
334         (WebCore::RenderBox::localToAbsoluteQuad):
335         * rendering/RenderFlexibleBox.cpp:
336         (WebCore::RenderFlexibleBox::layoutBlock):
337         * rendering/RenderForeignObject.cpp:
338         (WebCore::RenderForeignObject::layout):
339         * rendering/RenderLayer.cpp:
340         (WebCore::RenderLayer::updateLayerPositions):
341         (WebCore::RenderLayer::setHasVisibleContent):
342         * rendering/RenderObject.cpp:
343         (WebCore::RenderObject::repaintAfterLayoutIfNeeded):
344         (WebCore::RenderObject::absoluteOutlineBounds):
345         * rendering/RenderObject.h:
346         * rendering/RenderPath.cpp:
347         (WebCore::RenderPath::layout):
348         * rendering/RenderReplaced.cpp:
349         (WebCore::RenderReplaced::layout):
350         * rendering/RenderSVGContainer.cpp:
351         (WebCore::RenderSVGContainer::layout):
352         * rendering/RenderSVGImage.cpp:
353         (WebCore::RenderSVGImage::layout):
354         * rendering/RenderSVGRoot.cpp:
355         (WebCore::RenderSVGRoot::layout):
356         * rendering/RenderSVGText.cpp:
357         (WebCore::RenderSVGText::layout):
358         * rendering/RenderSVGViewportContainer.cpp:
359         (WebCore::RenderSVGViewportContainer::layout):
360         * rendering/RenderTable.cpp:
361         (WebCore::RenderTable::layout):
362
363 2008-11-12  Simon Fraser  <simon.fraser@apple.com>
364
365         Reviewed by Dave Hyatt
366
367         https://bugs.webkit.org/show_bug.cgi?id=21942
368         https://bugs.webkit.org/show_bug.cgi?id=18557
369         
370         Add methods which can be used to map renderer-local rectangles
371         to quads in absolute coordinates, taking transforms into account:
372             localToAbsoluteQuad() converts a local rect into an absolute quad.
373             collectAbsoluteLineBoxQuads() is an analogue of addLineBoxRects()
374                 that works with quads.
375             absoluteQuads() is an analogue of absoluteRects(), for quads.
376         
377         Use the quad methods to fix the inspector highlight for transformed
378         elements.
379
380         * GNUmakefile.am:
381         * WebCore.pro:
382         * WebCore.vcproj/WebCore.vcproj:
383         * WebCore.xcodeproj/project.pbxproj:
384         * WebCoreSources.bkl:
385         * inspector/InspectorController.cpp:
386         (WebCore::drawOutlinedQuad):
387         (WebCore::drawHighlightForBoxes):
388         (WebCore::frameToMainFrameOffset):
389         (WebCore::InspectorController::drawNodeHighlight):
390         * platform/graphics/AffineTransform.cpp:
391         (WebCore::AffineTransform::mapQuad):
392         * platform/graphics/AffineTransform.h:
393         * platform/graphics/FloatQuad.cpp: Added.
394         (WebCore::min4):
395         (WebCore::max4):
396         (WebCore::FloatQuad::boundingBox):
397         * platform/graphics/FloatQuad.h: Added.
398         (WebCore::FloatQuad::FloatQuad):
399         (WebCore::FloatQuad::p1):
400         (WebCore::FloatQuad::p2):
401         (WebCore::FloatQuad::p3):
402         (WebCore::FloatQuad::p4):
403         (WebCore::FloatQuad::setP1):
404         (WebCore::FloatQuad::setP2):
405         (WebCore::FloatQuad::setP3):
406         (WebCore::FloatQuad::setP4):
407         (WebCore::FloatQuad::isEmpty):
408         (WebCore::FloatQuad::enclosingBoundingBox):
409         (WebCore::FloatQuad::move):
410         (WebCore::operator+=):
411         (WebCore::operator-=):
412         (WebCore::operator==):
413         (WebCore::operator!=):
414         * rendering/RenderBox.cpp:
415         (WebCore::RenderBox::localToAbsoluteQuad):
416         * rendering/RenderBox.h:
417         * rendering/RenderContainer.cpp:
418         (WebCore::RenderContainer::collectAbsoluteLineBoxQuads):
419         * rendering/RenderContainer.h:
420         * rendering/RenderInline.cpp:
421         (WebCore::RenderInline::absoluteQuads):
422         * rendering/RenderInline.h:
423         * rendering/RenderObject.cpp:
424         (WebCore::RenderObject::absoluteBoundingBoxRect):
425         (WebCore::RenderObject::collectAbsoluteLineBoxQuads):
426         (WebCore::RenderObject::absoluteQuads):
427         (WebCore::RenderObject::localToAbsoluteQuad):
428         (WebCore::RenderObject::absoluteContentQuad):
429         * rendering/RenderObject.h:
430         * rendering/RenderPath.cpp:
431         (WebCore::RenderPath::absoluteQuads):
432         * rendering/RenderPath.h:
433         * rendering/RenderSVGContainer.cpp:
434         (WebCore::RenderSVGContainer::absoluteQuads):
435         * rendering/RenderSVGContainer.h:
436         * rendering/RenderSVGHiddenContainer.cpp:
437         (WebCore::RenderSVGHiddenContainer::absoluteQuads):
438         * rendering/RenderSVGHiddenContainer.h:
439         * rendering/RenderSVGImage.cpp:
440         (WebCore::RenderSVGImage::calculateAbsoluteBounds):
441         (WebCore::RenderSVGImage::absoluteQuads):
442         * rendering/RenderSVGImage.h:
443         * rendering/RenderSVGInlineText.cpp:
444         (WebCore::RenderSVGInlineText::absoluteQuads):
445         (WebCore::RenderSVGInlineText::computeAbsoluteRectForRange):
446         * rendering/RenderSVGInlineText.h:
447         * rendering/RenderSVGRoot.cpp:
448         (WebCore::RenderSVGRoot::absoluteQuads):
449         * rendering/RenderSVGRoot.h:
450         * rendering/RenderSVGTSpan.cpp:
451         (WebCore::RenderSVGTSpan::absoluteRects):
452         (WebCore::RenderSVGTSpan::absoluteQuads):
453         * rendering/RenderSVGTSpan.h:
454         * rendering/RenderSVGText.cpp:
455         (WebCore::RenderSVGText::absoluteRects):
456         (WebCore::RenderSVGText::absoluteQuads):
457         * rendering/RenderSVGText.h:
458         * rendering/RenderSVGTextPath.cpp:
459         (WebCore::RenderSVGTextPath::absoluteRects):
460         (WebCore::RenderSVGTextPath::absoluteQuads):
461         * rendering/RenderSVGTextPath.h:
462         * rendering/RenderTableCell.cpp:
463         (WebCore::RenderTableCell::localToAbsolute):
464         (WebCore::RenderTableCell::localToAbsoluteQuad):
465         * rendering/RenderTableCell.h:
466         * rendering/RenderText.cpp:
467         (WebCore::RenderText::absoluteQuads):
468         (WebCore::RenderText::collectAbsoluteLineBoxQuads):
469         * rendering/RenderText.h:
470         * rendering/RenderView.cpp:
471         (WebCore::RenderView::localToAbsoluteQuad):
472         (WebCore::RenderView::absoluteQuads):
473         * rendering/RenderView.h:
474
475 2008-11-12  Brent Fulgham <bfulgham@gmail.com>
476
477         Fix Bug 22178: Build errors in WebKit Cairo port
478
479         <https://bugs.webkit.org/show_bug.cgi?id=22178>
480
481         Reviewed by Mark Rowe.
482
483         * platform/graphics/cairo/PatternCairo.cpp: Correct build error under
484         Visual Studio.
485         (WebCore::Pattern::createPlatformPattern):
486
487 2008-11-12  Adam Roben  <aroben@apple.com>
488
489         Fix a typo in the include path for the Release_Cairo configuration
490
491         * WebCore.vcproj/WebCore.vcproj: Fixed "caro" -> "cairo" typo.
492
493 2008-11-12  Simon Fraser  <simon.fraser@apple.com>
494
495         Reviewed by Dave Hyatt
496
497         https://bugs.webkit.org/show_bug.cgi?id=17840
498         Patch 2
499         
500         Code cleanup in RenderBox::computeAbsoluteRepaintRect().
501
502         * rendering/RenderBox.cpp:
503         (WebCore::RenderBox::computeAbsoluteRepaintRect):
504
505 2008-11-12  Simon Fraser  <simon.fraser@apple.com>
506
507         Reviewed by Dave Hyatt
508
509         https://bugs.webkit.org/show_bug.cgi?id=17840
510
511         Fix repainting when the transform on a positioned element changes.
512         In computeAbsoluteRepaintRect(), add the offsets due to relative positioning,
513         and being in a positioned container after applying the transform to the local
514         rect.
515
516         Tests: fast/repaint/transform-absolute-in-positioned-container.html
517                fast/repaint/transform-relative-position.html
518
519         * rendering/RenderBox.cpp:
520         (WebCore::RenderBox::computeAbsoluteRepaintRect):
521
522 2008-11-12  Justin Garcia  <justin.garcia@apple.com>
523  
524         Reviewed by Beth Dakin.
525  
526         <rdar://problem/5495723> Selecting and deleting quoted text quotes other text
527         <rdar://problem/4775313> Deleting lines from the bottom of a messages leaves the last blank line quoted
528         
529         We don't want to merge into a block if it will mean changing the quote level of content after deleting 
530         selections that contain a whole number paragraphs plus a line break, since it is unclear to most users 
531         that such a selection actually ends at the start of the next paragraph.  Instead we want to completely
532         remove the selected paragraph(s) and all evidence of the first one's quote level.  This matches TextEdit behavior 
533         for indented paragraphs.
534  
535         * editing/DeleteSelectionCommand.cpp:
536         (WebCore::DeleteSelectionCommand::initializePositionData): For the selections described above, do not
537         try to merge after the deletion.  Instead try and prune the start block or blocks if they've been emptied
538         so that we remove evidence of the deleted paragraphs' quote level.
539         (WebCore::DeleteSelectionCommand::mergeParagraphs): Try and prune the start block(s) if necessary.  Also 
540         make sure that the caret is placed correctly so that it ends up on the same line that the deleted selection 
541         started on, instead of one higher.
542         * editing/DeleteSelectionCommand.h:
543         * editing/htmlediting.cpp:
544         (WebCore::numEnclosingMailBlockquotes): Added.
545         * editing/htmlediting.h:
546
547 2008-11-10  Tor Arne Vestbø  <tavestbo@trolltech.com>
548
549         Reviewed by Simon Hausmann.
550
551         Move _web_encodingForResource from WebKit into WebCore and change return type
552
553         This change is needed to implement NSAPI in WebCore for Mac, see:
554
555         https://bugs.webkit.org/show_bug.cgi?id=21427
556
557         * WebCore.base.exp:
558         * platform/mac/WebCoreNSStringExtras.h:
559         * platform/mac/WebCoreNSStringExtras.mm:
560         (stringEncodingForResource):
561
562 2008-11-10  Tor Arne Vestbø  <tavestbo@trolltech.com>
563
564         Reviewed by Simon Hausmann.
565
566         Moved the implementation of _webkit_isCaseInsensitiveEqualToString to
567         WebCore's WebCoreNSStringExtras as _stringIsCaseInsensitiveEqualToString.
568
569         This change is needed to implement NSAPI in WebCore for Mac, see:
570
571         https://bugs.webkit.org/show_bug.cgi?id=21427
572
573         * WebCore.base.exp:
574         * platform/mac/WebCoreNSStringExtras.h:
575         * platform/mac/WebCoreNSStringExtras.mm:
576         (stringIsCaseInsensitiveEqualToString):
577
578 2008-11-11  Stephanie  <slewis@apple.com>
579
580         Reviewed by Dan Bernstein.
581
582         Null check image data before setting it as image source.
583
584         Test: fast/images/image-empty-data.html
585
586         * platform/graphics/BitmapImage.cpp:
587         (WebCore::BitmapImage::destroyDecodedData):
588
589 2008-11-11  Adele Peterson  <adele@apple.com>
590
591         Reviewed by Tim Hatcher.
592
593         Remove ifdef so future OS versions can use the new delegate method.
594
595         * platform/network/mac/ResourceHandleMac.mm: (WebCore::ResourceHandle::didSendBodyDataDelegateExists):
596
597 2008-11-11  Eric Seidel  <eric@webkit.org>
598
599         Reviewed by Antti Koivisto and Sam Weinig.
600
601         Clean up HTMLTokenizer a litle
602         https://bugs.webkit.org/show_bug.cgi?id=22188
603
604         Rename pendingScripts to m_pendingScripts
605         Rename scriptNode to m_scriptNode make the type specific
606         Rename pendingSrc to m_pendingSrc
607         Rename currentPrependingSrc to m_currentPrependingSrc
608         Rename noMoreData to m_noMoreData and cBuffer to m_cBuffer
609         Remove long-since-dead kdDebug and qDebug calls
610         Rename brokenComments to m_brokenComments
611         Remove HTMLTokenizer includes and document the rest
612         Rename src to m_src
613         Rename parser to m_parser and make it an OwnPtr
614         Rename inWrite to m_inWrite and jsProxy to scriptController
615         Rename brokenServer to m_brokenServer
616         Rename buffer to m_buffer and dest to m_dest
617         Rename size to m_bufferSize
618         Rename attrName to m_attrName
619         Rename searchStopper to m_searchStopper and searchStopperLen to m_searchStopperLen
620         Rename scriptCode* to m_scriptCode* and change scriptCodeMax to m_scriptCodeCapacity
621         Rename scriptStartLineno to m_currentScriptTagStartLineNumber and tagStartLineno to m_currentTagStartLineNumber
622         Rename scriptSrc to m_scriptTagSrcAttrValue and scriptSrcCharset to m_scriptTagCharsetAttrValue -- a bit unwieldy, but more precise
623         Rename flat to selfClosingTag
624         Rename currToken to m_currentToken
625
626         * css/CSSParser.cpp:
627         * dom/XMLTokenizer.cpp:
628         * dom/XMLTokenizerLibxml2.cpp:
629         * html/HTMLDocument.cpp:
630         * html/HTMLElement.cpp:
631         * html/HTMLFormControlElement.cpp:
632         * html/HTMLParser.h:
633         * html/HTMLTokenizer.cpp:
634         (WebCore::Token::addAttribute):
635         (WebCore::HTMLTokenizer::HTMLTokenizer):
636         (WebCore::HTMLTokenizer::reset):
637         (WebCore::HTMLTokenizer::begin):
638         (WebCore::HTMLTokenizer::processListing):
639         (WebCore::HTMLTokenizer::parseSpecial):
640         (WebCore::HTMLTokenizer::scriptHandler):
641         (WebCore::HTMLTokenizer::scriptExecution):
642         (WebCore::HTMLTokenizer::parseComment):
643         (WebCore::HTMLTokenizer::parseServer):
644         (WebCore::HTMLTokenizer::parseProcessingInstruction):
645         (WebCore::HTMLTokenizer::parseText):
646         (WebCore::HTMLTokenizer::parseEntity):
647         (WebCore::HTMLTokenizer::parseTag):
648         (WebCore::HTMLTokenizer::write):
649         (WebCore::HTMLTokenizer::processingData):
650         (WebCore::HTMLTokenizer::end):
651         (WebCore::HTMLTokenizer::finish):
652         (WebCore::HTMLTokenizer::processToken):
653         (WebCore::HTMLTokenizer::processDoctypeToken):
654         (WebCore::HTMLTokenizer::~HTMLTokenizer):
655         (WebCore::HTMLTokenizer::enlargeBuffer):
656         (WebCore::HTMLTokenizer::enlargeScriptBuffer):
657         (WebCore::HTMLTokenizer::notifyFinished):
658         (WebCore::HTMLTokenizer::setSrc):
659         * html/HTMLTokenizer.h:
660         (WebCore::Token::Token):
661         (WebCore::Token::reset):
662         (WebCore::HTMLTokenizer::processingContentWrittenByScript):
663         (WebCore::HTMLTokenizer::htmlParser):
664         (WebCore::HTMLTokenizer::checkBuffer):
665         (WebCore::HTMLTokenizer::checkScriptBuffer):
666         * html/HTMLViewSourceDocument.h:
667         * rendering/RenderBlock.cpp:
668         (WebCore::RenderBlock::leftRelOffset):
669         (WebCore::RenderBlock::rightRelOffset):
670         (WebCore::RenderBlock::lineWidth):
671         * xml/XSLTProcessor.cpp:
672
673 2008-11-11  Sam Weinig  <sam@webkit.org>
674
675         Reviewed by Dan Bernstein.
676
677         Fix for https://bugs.webkit.org/show_bug.cgi?id=22189
678         Track CachedScript decoded data
679
680         We now track the decoded size of CachedScripts in the Cache allowing
681         them to accounted for when deciding when to evict data.  The decoded
682         data itself can be evicted when Cache pressure gets high enough through
683         CachedScript::destroyDecodedData.
684
685         * loader/CachedResource.h:
686         (WebCore::CachedResource::allClientsRemoved):
687         (WebCore::CachedResource::destroyDecodedData):
688         * loader/CachedScript.cpp:
689         (WebCore::CachedScript::script):
690         (WebCore::CachedScript::data):
691         (WebCore::CachedScript::destroyDecodedData):
692         * loader/CachedScript.h:
693
694 2008-11-11  Cameron Zwarich  <zwarich@apple.com>
695
696         Reviewed by Geoff Garen.
697
698         Remove pointless dependencies on the now-deleted kjs directory and
699         mentions of it in comments that are no longer relevant.
700
701         * WebCore.pro:
702         * webcore-base.bkl:
703
704 2008-11-11  Dan Bernstein  <mitz@apple.com>
705
706         Reviewed by Adam Roben.
707
708         WebCore part of adding a master volume control for media elements in a WebView
709
710         * WebCore.base.exp: Exported WebCore::Page::setMediaVolume().
711         * dom/Document.cpp:
712         (WebCore::Document::mediaVolumeDidChange): Added. Called by the Page
713         when the media volume is changed.
714         (WebCore::Document::registerForMediaVolumeCallbacks): Added. Allows
715         elements to register for a callback when the media volume is changed.
716         (WebCore::Document::unregisterForMediaVolumeCallbacks): Added. Allows
717         elements to unregister for the callback.
718         * dom/Document.h:
719         * dom/Element.h:
720         (WebCore::Element::mediaVolumeDidChange): Added an empty implementation.
721         * html/HTMLMediaElement.cpp:
722         (WebCore::HTMLMediaElement::HTMLMediaElement): Added a call to
723         registerForMediaVolumeCallbacks().
724         (WebCore::HTMLMediaElement::~HTMLMediaElement): Added a call to
725         unregisterForMediaVolumeCallbacks().
726         (WebCore::HTMLMediaElement::updateVolume): Changed to multiply the
727         element's intrinsic volume by the master volume from the page.
728         (WebCore::HTMLMediaElement::mediaVolumeDidChange): Added. Calls
729         updateVolume().
730         * html/HTMLMediaElement.h:
731         * page/Page.cpp:
732         (WebCore::Page::Page): Initialize m_mediaVolume to 1.
733         (WebCore::Page::setMediaVolume): Added. Calls mediaVolumeDidChange() on
734         every document in the page when the master volume changes.
735         * page/Page.h:
736         (WebCore::Page::mediaVolume): Added this getter.
737
738 2008-11-11  David Hyatt  <hyatt@apple.com>
739
740         https://bugs.webkit.org/show_bug.cgi?id=22182
741
742         Fix problems with scrollbars when the OS setting for clicks in the track jumping the thumb to that location
743         is turned on.  Make sure to only jump the thumb if the click happens in the track.  Also fix some math
744         errors when jumping the thumb that cause dragging after the jump to incorrectly jump the thumb again.
745
746         Reviewed by Adele
747
748         * platform/Scrollbar.cpp:
749         (WebCore::Scrollbar::mouseDown):
750
751 2008-11-11  Beth Dakin  <bdakin@apple.com>
752
753         Reviewed by Darin Adler.
754
755         Fix for <rdar://problem/5089327> Too much indentation when pasting 
756         quoted paragraphs
757
758         This patch re-addresses pasting blockquotes into blockquotes. It 
759         backs out most of revision 38273. 38273 fixed the bug by inserting 
760         the pasted content as a sibling blockquote node to the pre-existing 
761         blockquote node. The problem with that is that by default, 
762         blockquotes have a giant margin, so visually, this can be weird. 
763         This patch instead inserts the pasted content as siblings of the 
764         the content already inside the outer blockquote, and then removes 
765         the blockquote node from the pasted content itself, so that it 
766         doesn't nest itself into the outer blockquote.
767         * editing/ReplaceSelectionCommand.cpp:
768         (WebCore::ReplaceSelectionCommand::doApply):
769
770         Move contains() from Element to Node since there is nothing 
771         Element-specific about it.
772         * dom/Element.cpp:
773         * dom/Element.h:
774         * dom/Node.cpp:
775         (WebCore::Node::contains):
776         * dom/Node.h:
777
778 2008-11-11  David Hyatt  <hyatt@apple.com>
779
780         https://bugs.webkit.org/show_bug.cgi?id=17997
781
782         Stop using the new Leopard API tiling call for scaled tiles when drawing background images.  The method
783         is buggy.  Fall back to using the slower (and more correct) pattern tiling that Tiger still uses.  This
784         is a Leopard-only workaround, since the API has been fixed on Snow Leopard.
785
786         Reviewed by John Sullivan
787
788         * platform/graphics/cg/ImageCG.cpp:
789         (WebCore::Image::drawPattern):
790
791 2008-11-10  David Hyatt  <hyatt@apple.com>
792
793         Disable the Aqua look for menu lists when full page zoom is turned on.  Because the control is buggy
794         when scaling and because it's impossible to paint into an offscreen bitmap without completely rewriting
795         how we draw the control on Mac, our only real option for now is to just switch to our styled look when zoomed.
796
797         Reviewed by Adam Roben
798
799         * rendering/RenderThemeMac.mm:
800         (WebCore::RenderThemeMac::isControlStyled):
801
802 2008-11-11  Darin Adler  <darin@apple.com>
803
804         Reviewed by Dan Bernstein.
805
806         - https://bugs.webkit.org/show_bug.cgi?id=22160
807         speculative fix for <rdar://problem/5995450> Nil deref because nextLinePosition
808         (previousLinePosition, too) uses a nil node
809
810         * editing/visible_units.cpp:
811         (WebCore::nextLinePosition): Use RenderObject::node instead of RenderObject::element
812         to check editingIgnoresContent. It makes sense to use the associated DOM node for
813         this, even in cases of anonymous content, and it avoids the case where element() can
814         be 0.
815         (WebCore::previousLinePosition): Ditto.
816
817 2008-11-11  Dirk Schulze  <vbs85@gmx.de>
818
819         Reviewed by Darin Adler.
820
821         Removed default: in applySpreadMethod. This causes the problems
822         in radial gradients. We don't need CAIRO_EXTEND_NONE in SVG, Canvas
823         or CSS.
824
825         * platform/graphics/cairo/GraphicsContextCairo.cpp:
826         (WebCore::applySpreadMethod):
827
828 2008-11-11  Ariya Hidayat  <ariya.hidayat@trolltech.com>
829
830         Reviewed by Tor Arne Vestbø.
831
832         Fix crash when rendering the file chooser.
833         Also proper implementation for multi-selected files.
834
835         * platform/qt/FileChooserQt.cpp:
836         (WebCore::FileChooser::basenameForWidth):
837
838 2008-11-11  Dirk Schulze  <vbs85@gmx.de>
839
840         Reviewed by Oliver Hunt.
841
842         PatternCairo needs to invert the pattern matrix because
843         of transformation from user space to pattern space.
844         Give a identity matrix to pattern for Qt and Cairo. Because the 
845         context is transformed already.
846
847         [CAIRO][QT] Canvas transformations applied twice to Patterns
848         https://bugs.webkit.org/show_bug.cgi?id=21555
849
850         * platform/graphics/cairo/GraphicsContextCairo.cpp:
851         (WebCore::GraphicsContext::fillPath):
852         (WebCore::GraphicsContext::strokePath):
853         * platform/graphics/cairo/PatternCairo.cpp:
854         (WebCore::Pattern::createPlatformPattern):
855         * platform/graphics/qt/GraphicsContextQt.cpp:
856         (WebCore::GraphicsContext::strokePath):
857         (WebCore::GraphicsContext::fillRect):
858
859 2008-11-10  Stephanie Lewis  <slewis@apple.com>
860
861         Reviewed by Dan Bernstein.
862
863         Clear the image source cache even if we haven't decoded any of the image data.
864         We use the image source cache when calculating layout.
865
866         * loader/Cache.cpp:
867         (WebCore::Cache::pruneDeadResources):
868         * platform/graphics/BitmapImage.cpp:
869         (WebCore::BitmapImage::destroyDecodedData):
870
871 2008-11-10  Adam Roben  <aroben@apple.com>
872
873         Fix Bug 22161: Assertion failure in RenderThemeWin::systemColor when
874         loading microsoftpdc.com
875
876         <https://bugs.webkit.org/show_bug.cgi?id=22161>
877
878         Reviewed by Dan Bernstein.
879
880         Test: fast/css/outline-invert-assertion.html
881
882         * rendering/RenderThemeWin.cpp:
883         (WebCore::RenderThemeWin::systemColor): If we can't determine a good
884         Win32 system color to use, defer to RenderTheme instead of asserting.
885         This matches what RenderThemeMac does.
886
887 2008-11-10  Justin Garcia  <justin.garcia@apple.com>
888
889         Reviewed by Beth Dakin.
890
891         <rdar://problem/4037481> REGRESSION (Mail): pasting quoted text 
892         into quoted text yields double-quoting
893         
894         Don't nest inserted content in Mail blockquotes.  Perform a 
895         BreakBlockquoteCommand if we're in
896         one and insert the incoming fragment between the split blockquotes.
897
898         * editing/ReplaceSelectionCommand.cpp:
899         (WebCore::ReplaceSelectionCommand::shouldMerge): Renamed from -> 
900         source and to -> destination.
901         (WebCore::ReplaceSelectionCommand::doApply):
902
903 2008-11-10  Adam Roben  <aroben@apple.com>
904
905         Fix Bug 22158: Would like to turn on WebCore logging channels via an
906         environment variable
907
908         <https://bugs.webkit.org/show_bug.cgi?id=22158>
909
910         Logging channels can now be enabled by setting the WebCoreLogLevel
911         environment variable to a hexadecimal number.
912
913         Reviewed by Anders Carlsson.
914
915         * WebCore.vcproj/WebCore.vcproj: Added LoggingWin.cpp.
916         * platform/win/LoggingWin.cpp: Copied from WebCore/platform/mac/LoggingMac.mm.
917         (WebCore::initializeWithUserDefault): Read in the WebCoreLogLevel
918         environment variable, parse its value as a hexadecimal number, and
919         turn the channel on/off based on whether the mask bit is set.
920         (WebCore::InitializeLoggingChannelsIfNecessary): Initialize each
921         logging channel in turn.
922
923 2008-11-10  Darin Adler  <darin@apple.com>
924
925         Reviewed by Adam Roben.
926
927         - fix https://bugs.webkit.org/show_bug.cgi?id=22103
928           Changing fonts in preferences does not immediately update WebViews
929
930         This broke when the meaning of FrameView::invalidate changed.
931         I changed setNeedsReapplyStyles to no longer depend on invalidate.
932
933         * dom/Document.cpp: (WebCore::Document::shouldScheduleLayout):
934         Removed the part of this function that duplicated what's already in
935         FrameView::needsLayout, since the copy here left out a few key things.
936         For example, it didn't handle the fact that "needs reapply styles"
937         counts as needing layout.
938
939         * page/Frame.cpp: (WebCore::Frame::setNeedsReapplyStyles): This called
940         FrameView::invalidate before. There were two things wrong with that.
941         1) It requested that the entire view repaint even if the style change
942         didn't necessitate that. 2) FrameView::invalidate no longer causes any
943         repainting at all in certain cases, because of Hyatt's changes to how
944         widgets and the host window are involved in the repainting process.
945         So call FrameView::scheduleRelayout instead, which is more precisely
946         what we want and need here.
947
948         * page/FrameView.cpp:
949         (WebCore::FrameView::scheduleRelayout): Add a call to needsLayout here
950         so that Document::shouldScheduleLayout doesn't have to replicate the
951         logic that's in needsLayout and can instead rely on the fact that it
952         was already called.
953         (WebCore::FrameView::needsLayout): Tweaked the comments and formatting
954         in this function.
955
956 2008-11-10  Darin Adler  <darin@apple.com>
957
958         Reviewed by Adam Roben.
959
960         - speculative fix for <rdar://problem/5557243> crashes in Safari at
961           WebCore::HTMLSelectElement::updateListBoxSelection + 280
962
963         * html/HTMLSelectElement.cpp:
964         (WebCore::HTMLSelectElement::updateListBoxSelection):
965         Check index against size of vector before indexing into the vector.
966
967 2008-11-10  Tom Cooksey  <thomas.cooksey@trolltech.com>
968
969         Reviewed by Tor Arne Vestbø.
970
971         Fix QtWebkit build failure on arm.
972
973         pen.widthF() is a qreal, which means it's a float on arm.
974
975         * platform/graphics/qt/GraphicsContextQt.cpp:
976         (WebCore::GraphicsContext::setLineDash):
977
978 2008-11-10  Morten Sørvig  <msorvig@trolltech.com>
979
980         Reviewed by Simon Hausmann.
981
982         Improve mouse wheel scolling on Qt/Cocoa.
983         Cocoa differs from Carbon (and other platforms I think) in that the
984         mouse wheel events we get have a much higher acceleration factor.
985
986         This submit switches over to scroll-per-pixel from scroll-per-line
987         for most of our scrolling views. This matches the native views
988         and works well with the increased acceleration.
989
990         * platform/qt/WheelEventQt.cpp:
991
992 2008-11-09  Cameron Zwarich  <zwarich@apple.com>
993
994         Reviewed by Darin Adler.
995
996         Bug 19541: Null pointer in showModalDialog()
997         <https://bugs.webkit.org/show_bug.cgi?id=19541>
998
999         Add null frame->page() checks to JSDOMWindowBase::canShowModalDialog()
1000         and JSDOMWindowBase::canShowModalDialogNow()C
1001
1002         * bindings/js/JSDOMWindowBase.cpp:
1003         (WebCore::canShowModalDialog):
1004         (WebCore::canShowModalDialogNow):
1005
1006 2008-11-09  Darin Adler  <darin@apple.com>
1007
1008         - try to fix Windows build
1009
1010         * platform/graphics/Color.cpp: For some reason MSVC doesn't follow the rules
1011         about needed a separate definition for static const integer data members.
1012         Until I get to the bottom of this, put the definitions inside an ifdef.
1013
1014 2008-11-09  David Kilzer  <ddkilzer@apple.com>
1015
1016         BUILD FIX: Qt build broke after r38235.
1017
1018         Added HAVE(ACCESSIBILITY) header guards to platform implementation
1019         source files.
1020
1021         * page/gtk/AccessibilityObjectAtk.cpp: Added HAVE(ACCESSIBILITY)
1022         guards.
1023         * page/gtk/AccessibilityObjectWrapperAtk.cpp: Ditto.
1024         * page/qt/AccessibilityObjectQt.cpp: Ditto.
1025         * page/win/AccessibilityObjectWin.cpp: Ditto.
1026         * page/wx/AccessibilityObjectWx.cpp: Ditto.
1027
1028 2008-11-09  Alexey Proskuryakov  <ap@webkit.org>
1029
1030         Reviewed by Darin Adler.
1031
1032         https://bugs.webkit.org/show_bug.cgi?id=22104
1033         Javascript URL percent encoding/decoding broken by some characters
1034
1035         Test: fast/loader/javascript-url-encoding-2.html
1036
1037         * platform/KURL.cpp: (WebCore::encodeRelativeString): Don't try to break down javascript URLs.
1038
1039 2008-11-09  Holger Hans Peter Freyther  <zecke@selfish.org>
1040
1041         Reviewed and tweaked by Darin Adler.
1042
1043         * platform/graphics/Color.cpp: Added definitions for the static data members
1044         in this class. Static data members need a definition, even when they are the
1045         simple integer constant kind that can be initialized in the header.
1046
1047 2008-11-08  Antti Koivisto  <antti@apple.com>
1048
1049         Reviewed by Sam Weinig.
1050         
1051         Fix https://bugs.webkit.org/show_bug.cgi?id=22141
1052         REGRESSION: Safari error page is not fully styled when loaded from cache
1053         
1054         Reset text decoder on flush so it does not pass through the BOM when it is reused.
1055
1056         Test: fast/encoding/css-cached-bom.html
1057
1058         * loader/TextResourceDecoder.cpp:
1059         (WebCore::TextResourceDecoder::flush):
1060
1061 2008-11-08  Kevin Ollivier  <kevino@theolliviers.com>
1062  
1063         Reviewed by Mark Rowe.
1064
1065         Send URL errors to stderr rather than stdout. While debugging wx DumpRenderTree,
1066         it was causing these errors to end up in the page's text representation.
1067
1068         * platform/network/curl/ResourceHandleManager.cpp:
1069         (WebCore::ResourceHandleManager::downloadTimerCallback):
1070
1071 2008-11-08  Kevin Ollivier  <kevino@theolliviers.com>
1072
1073         wx build fixes after addition of JSCore parser and bycompiler dirs. 
1074
1075         * webcore-base.bkl:
1076         * webcore-wx.bkl:
1077
1078 2008-11-08  Simon Fraser  <simon.fraser@apple.com>
1079
1080         Reviewed by Dan Bernstein
1081
1082         https://bugs.webkit.org/show_bug.cgi?id=21906
1083         
1084         Override addFocusRingRects() in RenderTextControl to avoid
1085         the RenderFlow behavior of recursing on descendent renderers.
1086         RenderTextControl should only ever need a simple focus rect.
1087         
1088         This fixes focus ring issues with transforms on text controls.
1089         
1090         Test: fast/transforms/transformed-focused-text-input.html
1091
1092         * rendering/RenderTextControl.cpp:
1093         (WebCore::RenderTextControl::addFocusRingRects):
1094         * rendering/RenderTextControl.h:
1095
1096 2008-11-08  Dimitri Dupuis-Latour  <dupuislatour@apple.com>
1097
1098         Make sure the icon thumbnail width/height is at least 1px in
1099         the Web Inspector's resource panel.
1100
1101         <rdar://problem/5988888>
1102
1103         Reviewed by Tim Hatcher.
1104
1105         * inspector/front-end/inspector.css:
1106
1107 2008-11-08  David Kilzer  <ddkilzer@apple.com>
1108
1109         Bug 22137: PLATFORM(MAC) build broken with HAVE(ACCESSIBILITY) disabled
1110
1111         <https://bugs.webkit.org/show_bug.cgi?id=22137>
1112
1113         Reviewed by Darin Adler.
1114
1115         * page/AccessibilityObject.h:
1116         (WebCore::AccessibilityObject::accessibilityIgnoreAttachment):
1117         Provide a default implementation when HAVE(ACCESSIBILITY) is false.
1118         * page/mac/AXObjectCacheMac.mm: Added HAVE(ACCESSIBILITY) guard.
1119         * page/mac/AccessibilityObjectMac.mm: Ditto.
1120         * page/mac/AccessibilityObjectWrapper.mm: Ditto.
1121
1122 2008-11-08  Dan Bernstein  <mitz@apple.com>
1123
1124         Reviewed by Darin Adler.
1125
1126         - WebCore part of adding WebPreferences for controlling databases and local storage
1127
1128         * WebCore.base.exp: Exported Settings::setDatabasesEnabled() and
1129         Settings::setLocalStorageEnabled().
1130         * page/DOMWindow.cpp:
1131         (WebCore::DOMWindow::localStorage): Changed to return 0 if local storage
1132         is disabled in settings.
1133         (WebCore::DOMWindow::openDatabase): Changed to return 0 if databases
1134         are disabled in settings.
1135         * page/Settings.cpp:
1136         (WebCore::Settings::Settings): Initialize m_databasesEnabled and
1137         m_localStorageEnabled.
1138         (WebCore::Settings::setDatabasesEnabled): Added.
1139         (WebCore::Settings::setLocalStorageEnabled): Added.
1140         * page/Settings.h:
1141         (WebCore::Settings::databasesEnabled): Added.
1142         (WebCore::Settings::localStorageEnabled): Added.
1143
1144 2008-11-07  Alp Toker  <alp@nuanti.com>
1145
1146         Fix build with bleeding edge GTK+ versions. GTK+ and other libraries
1147         now require that only their top-level header file is included.
1148
1149         Patch tested and still builds fine with older GTK+ versions (back to
1150         2.8).
1151
1152         Future WebKit GTK+ contributions are required to adhere to this
1153         policy.
1154
1155         * platform/gtk/FileSystemGtk.cpp:
1156         * platform/gtk/KeyEventGtk.cpp:
1157         * platform/gtk/MouseEventGtk.cpp:
1158         * platform/gtk/WheelEventGtk.cpp:
1159         * platform/gtk/gtkdrawing.h:
1160         * plugins/gtk/gtk2xtbin.c:
1161         * plugins/gtk/gtk2xtbin.h:
1162
1163 2008-11-07  Anders Carlsson  <andersca@apple.com>
1164
1165         Reviewed by Kevin Decker
1166
1167         Explicitly initialize the NPDrawingModelCoreAnimation.
1168
1169         * bridge/npapi.h:
1170
1171 2008-11-07  Alp Toker  <alp@nuanti.com>
1172
1173         autotools fix. Always use the configured perl binary (which may be
1174         different to the one in $PATH) when generating sources.
1175
1176         * GNUmakefile.am:
1177
1178 2008-11-07  Simon Fraser  <simon.fraser@apple.com>
1179
1180         Reviewed by Dan Bernstein
1181
1182         https://bugs.webkit.org/show_bug.cgi?id=22122
1183         
1184         Use a stack-based object to simplify the pushLayoutState/popLayoutState
1185         code. LayoutStateMaintainer either pushes in the constructor, or allows
1186         an explicit push() later. Both cases require an explicit pop().
1187
1188         * rendering/RenderBlock.cpp:
1189         (WebCore::RenderBlock::layoutBlock):
1190         (WebCore::RenderBlock::layoutOnlyPositionedObjects):
1191         * rendering/RenderContainer.cpp:
1192         (WebCore::RenderContainer::layout):
1193         * rendering/RenderFlexibleBox.cpp:
1194         (WebCore::RenderFlexibleBox::layoutBlock):
1195         * rendering/RenderTable.cpp:
1196         (WebCore::RenderTable::layout):
1197         * rendering/RenderTableRow.cpp:
1198         (WebCore::RenderTableRow::layout):
1199         * rendering/RenderTableSection.cpp:
1200         (WebCore::RenderTableSection::setCellWidths):
1201         (WebCore::RenderTableSection::calcRowHeight):
1202         (WebCore::RenderTableSection::layoutRows):
1203         * rendering/RenderView.h:
1204         (WebCore::LayoutStateMaintainer::LayoutStateMaintainer):
1205         (WebCore::LayoutStateMaintainer::~LayoutStateMaintainer):
1206         (WebCore::LayoutStateMaintainer::pop):
1207         (WebCore::LayoutStateMaintainer::push):
1208         (WebCore::LayoutStateMaintainer::didPush):
1209
1210 2008-11-07  Tor Arne Vestbø  <tavestbo@trolltech.com>
1211
1212         Fix the QtWebKit build on Mac
1213
1214         * platform/qt/TemporaryLinkStubs.cpp:
1215         (PluginView::invalidateRect):
1216
1217 2008-11-07  Tor Arne Vestbø  <tavestbo@trolltech.com>
1218
1219         Rubber-stamped by Simon Hausmann.
1220
1221         Don't allow Phonon's invisible video widget to keep the app running
1222
1223         * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
1224         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
1225
1226 2008-11-07  Henrik Hartz  <henrik.hartz@nokia.com>
1227
1228         Reviewed by Simon Hausmann.
1229
1230         Fix valgrind warning about uninitialized lastStop variable.
1231
1232         * platform/graphics/qt/GradientQt.cpp:
1233         (WebCore::Gradient::platformGradient):
1234
1235 2008-11-07  Alexey Proskuryakov  <ap@webkit.org>
1236
1237         Reviewed by Maciej Stachowiak.
1238
1239         Fix layout test brokenness following r38211.
1240
1241         * page/EventHandler.cpp: (WebCore::EventHandler::handleAccessKey):
1242         Restore old Shift key behavior. We ignore Shift key state when matching access keys (which
1243         matches neither IE nor Firefox), and this patch made WebKit behave like Firefox
1244         inadvertently. This may or may not be a good thing, but it's certainly not something that
1245         should change by accident.
1246
1247 2008-11-06  Antti Koivisto  <antti@apple.com>
1248
1249         Eh, this trivial last minute change was wrong.
1250
1251         * loader/CachedCSSStyleSheet.cpp:
1252         (WebCore::CachedCSSStyleSheet::sheetText):
1253
1254 2008-11-06  Antti Koivisto  <antti@apple.com>
1255
1256         Reviewed by Dan Bernstein.
1257
1258         https://bugs.webkit.org/show_bug.cgi?id=22093
1259         
1260         Delaying the text decoding caused regression since the decoding
1261         also determines the encoding in case of @charset rule. 
1262         
1263         Decode immediately in data() and keep the decoded string around
1264         during the checkNotify().
1265
1266         * loader/CachedCSSStyleSheet.cpp:
1267         (WebCore::CachedCSSStyleSheet::sheetText):
1268         (WebCore::CachedCSSStyleSheet::data):
1269         * loader/CachedCSSStyleSheet.h:
1270
1271 2008-11-06  Alexey Proskuryakov  <ap@webkit.org>
1272
1273         Reviewed by Darin Adler.
1274
1275         https://bugs.webkit.org/show_bug.cgi?id=22097
1276         Expose MessageEvent constructor on WorkerContext
1277
1278         * bindings/js/JSWorkerContext.cpp:
1279         (WebCore::jsWorkerContextMessageEvent):
1280         (WebCore::setJSWorkerContextMessageEvent):
1281
1282 2008-11-06  Alexey Proskuryakov  <ap@webkit.org>
1283
1284         Reviewed by Darin Adler.
1285
1286         https://bugs.webkit.org/show_bug.cgi?id=21107
1287         <rdar://problem/6264219> New access key combination conflicts with VoiceOver
1288
1289         * page/EventHandler.h:
1290         * page/gtk/EventHandlerGtk.cpp:
1291         (WebCore::EventHandler::accessKeyModifiers):
1292         * page/qt/EventHandlerQt.cpp:
1293         (WebCore::EventHandler::accessKeyModifiers):
1294         * page/win/EventHandlerWin.cpp:
1295         (WebCore::EventHandler::accessKeyModifiers):
1296         * page/wx/EventHandlerWx.cpp:
1297         (WebCore::EventHandler::accessKeyModifiers):
1298         Access access key modifiers via a function, not a static variable.
1299
1300         * page/mac/EventHandlerMac.mm: (WebCore::EventHandler::accessKeyModifiers):
1301         Use Ctrl when VoiceOver is enabled, because a conflict with Emacs-style key bindings is
1302         less troublesome than one with VO keys.
1303
1304         * page/EventHandler.cpp: (WebCore::EventHandler::handleAccessKey):
1305         Also fix an access key matching bug introduced in r32424 - Any superset of specified
1306         modifier set invoked access keys. We can use simple equality comparison instead because
1307         CapsLock is not part of modifiers(), so it doesn't need to be ignored explicitly.
1308
1309 2008-11-06  Anders Carlsson  <andersca@apple.com>
1310
1311         Reviewed by Kevin Decker.
1312
1313         https://bugs.webkit.org/show_bug.cgi?id=22115
1314         NPN_HasPropertyUPP and NPN_HasMethodUPP entries in NPNetscapeFuncs are NULL
1315
1316         Export _NPN_HasMethod and _NPN_HasProperty.
1317         
1318         * WebCore.NPAPI.exp:
1319
1320 2008-11-06  Simon Fraser  <simon.fraser@apple.com>
1321
1322         Reviewed by Antti Koivisto
1323
1324         https://bugs.webkit.org/show_bug.cgi?id=15678
1325         
1326         Fix transformed menu selects to show the popup in the correct
1327         location.
1328
1329         * rendering/RenderMenuList.cpp:
1330         (WebCore::RenderMenuList::showPopup):
1331
1332 2008-11-06  David Kilzer  <ddkilzer@apple.com>
1333
1334         BUILD FIX: Backed out r38189 (and r38203) for Xcode 3.0.
1335
1336         Apparently older versions of gcc have issues with this patch.
1337         Backing out a second time until the issues are resolved.
1338
1339 2008-11-06  Julien Chaffraix  <jchaffraix@pleyo.com>
1340
1341         Reviewed by Maciej Stachowiak.
1342
1343         Bug 21106: .in format discussed changes
1344         https://bugs.webkit.org/show_bug.cgi?id=21106
1345
1346         Include the namespace into the interfaceName.
1347
1348         * dom/make_names.pl: Do not append the namespace when
1349         using the interfaceName.
1350         * html/HTMLTagNames.in: Added namespace prefix for custom
1351         interfaceName.
1352         * svg/svgtags.in: Ditto.
1353
1354 2008-11-06  Cameron Zwarich  <zwarich@apple.com>
1355
1356         Reviewed by Geoff Garen.
1357
1358         Move the remaining files in the kjs subdirectory of JavaScriptCore to
1359         a new parser subdirectory, and remove the kjs subdirectory entirely.
1360
1361         * ForwardingHeaders/kjs: Removed.
1362         * ForwardingHeaders/kjs/Parser.h: Removed.
1363         * ForwardingHeaders/kjs/SavedBuiltins.h: Removed.
1364         * ForwardingHeaders/kjs/SourceCode.h: Removed.
1365         * ForwardingHeaders/kjs/SourceProvider.h: Removed.
1366         * ForwardingHeaders/parser: Added.
1367         * ForwardingHeaders/parser/Parser.h: Copied from ForwardingHeaders/kjs/Parser.h.
1368         * ForwardingHeaders/parser/SourceCode.h: Copied from ForwardingHeaders/kjs/SourceCode.h.
1369         * ForwardingHeaders/parser/SourceProvider.h: Copied from ForwardingHeaders/kjs/SourceProvider.h.
1370         * WebCore.pro:
1371         * WebCore.vcproj/WebCore.vcproj:
1372         * bindings/js/StringSourceProvider.h:
1373         * bindings/js/WorkerScriptController.cpp:
1374         * bridge/NP_jsobject.cpp:
1375         * bridge/jni/jni_jsobject.mm:
1376         * bridge/testbindings.pro:
1377         * inspector/JavaScriptDebugServer.cpp:
1378
1379 2008-11-06  David Kilzer  <ddkilzer@apple.com>
1380
1381         BUILD WAS NOT BROKEN: Rolling r38189 back in.
1382
1383         Please perform a clean build if you see crashes.
1384
1385 2008-11-06  David Kilzer  <ddkilzer@apple.com>
1386
1387         BUILD FIX: Backed out r38189 since it apparently broke the world.
1388
1389 2008-11-06  Chris Fleizach  <cfleizach@apple.com>
1390
1391         Reviewed by Beth Dakin.
1392
1393         Bug 22112: if a <body> has contenteditable=true, it should report a writable AXValue
1394         https://bugs.webkit.org/show_bug.cgi?id=22112
1395
1396         Test: accessibility/content-editable.html
1397
1398         * page/AccessibilityRenderObject.cpp:
1399         (WebCore::AccessibilityRenderObject::isReadOnly):
1400
1401 2008-11-06  Sam Weinig  <sam@webkit.org>
1402
1403         Reviewed by Alice Liu.
1404
1405         Fix failed assert at launch caused by unintialized data member on the mac.
1406
1407         * platform/network/mac/NetworkStateNotifierMac.cpp:
1408         (WebCore::NetworkStateNotifier::NetworkStateNotifier):
1409
1410 2008-11-06  Steve Falkenburg  <sfalken@apple.com>
1411
1412         Fix failed assert at launch caused by unintialized data member.
1413         
1414         Reviewed by Maciej Stachowiak.
1415
1416         * platform/network/win/NetworkStateNotifierWin.cpp:
1417         (WebCore::NetworkStateNotifier::NetworkStateNotifier):
1418
1419 2008-11-06  Simon Fraser  <simon.fraser@apple.com>
1420
1421         Reviewed by Antti Koivisto
1422
1423         https://bugs.webkit.org/show_bug.cgi?id=22109
1424         Make <input type="range"> work correctly with transforms
1425
1426         Test: fast/forms/slider-transformed.html
1427
1428         * html/HTMLInputElement.cpp:
1429         (WebCore::HTMLInputElement::defaultEventHandler):
1430             Compute a correct local point when the event is retargeted
1431         * rendering/RenderSlider.cpp:
1432         (WebCore::HTMLSliderThumbElement::defaultEventHandler):
1433             Compute m_initialClickPoint in slider-local coords, so that
1434             deltas are computed correctly with transforms
1435         (WebCore::RenderSlider::mouseEventIsInThumb):
1436             Rather than computing an absolute bounds for the thumb,
1437             convert the point to local coords and compare it with the border box.
1438
1439 2008-11-06  Greg Bolsinga  <bolsinga@apple.com>
1440
1441         Reviewed by Darin Adler.
1442
1443         Bug 21810: Remove use of static C++ objects that are destroyed at exit time (destructors)
1444         https://bugs.webkit.org/show_bug.cgi?id=21810
1445
1446         * bindings/js/GCController.cpp:
1447         (WebCore::gcController): Changed to leak an object to avoid an exit-time destructor.
1448         * bindings/js/JSDOMBinding.cpp:
1449         (WebCore::wrapperSet): Ditto
1450         * bindings/js/JSInspectedObjectWrapper.cpp:
1451         (WebCore::wrappers): Ditto
1452         * bindings/js/JSInspectorCallbackWrapper.cpp:
1453         (WebCore::wrappers): Ditto
1454         * bridge/runtime_root.cpp:
1455         (JSC::Bindings::rootObjectSet): Ditto
1456         * css/CSSMutableStyleDeclaration.cpp:
1457         (WebCore::CSSMutableStyleDeclaration::removeProperty): Ditto
1458         * css/CSSPrimitiveValue.cpp:
1459         (WebCore::CSSPrimitiveValue::cssText): Ditto
1460         * css/CSSSelector.cpp:
1461         (WebCore::CSSSelector::extractPseudoType): Ditto
1462         * css/CSSStyleSelector.cpp:
1463         (WebCore::screenEval): Ditto
1464         (WebCore::printEval): Ditto
1465         * dom/DOMImplementation.cpp:
1466         (WebCore::isSVG10Feature): Ditto
1467         (WebCore::isSVG11Feature): Ditto
1468         (WebCore::DOMImplementation::isXMLMIMEType): Ditto
1469         * dom/Document.cpp:
1470         (WebCore::Document::hasPrefixNamespaceMismatch): Ditto
1471         * dom/ScriptElement.cpp:
1472         (WebCore::isSupportedJavaScriptLanguage): Ditto
1473         * editing/ApplyStyleCommand.cpp:
1474         (WebCore::styleSpanClassString): Ditto
1475         * editing/HTMLInterchange.cpp:
1476         (WebCore::): Ditto
1477         * editing/IndentOutdentCommand.cpp:
1478         (WebCore::indentBlockquoteString): Ditto
1479         * editing/ReplaceSelectionCommand.cpp:
1480         (WebCore::isInterchangeNewlineNode): Ditto
1481         (WebCore::isInterchangeConvertedSpaceSpan): Ditto
1482         * editing/htmlediting.cpp:
1483         (WebCore::stringWithRebalancedWhitespace): Ditto
1484         (WebCore::nonBreakingSpaceString): Ditto
1485         * editing/markup.cpp:
1486         (WebCore::appendAttributeValue): Ditto
1487         (WebCore::appendEscapedContent): Ditto
1488         (WebCore::shouldAddNamespaceAttr): Ditto
1489         (WebCore::appendNamespace): Ditto
1490         (WebCore::appendStartMarkup): Ditto
1491         (WebCore::createMarkup): Ditto
1492         * html/HTMLButtonElement.cpp:
1493         (WebCore::HTMLButtonElement::type): Ditto
1494         * html/HTMLElement.cpp:
1495         (WebCore::HTMLElement::isRecognizedTagName): Ditto
1496         (WebCore::inlineTagList): Ditto
1497         (WebCore::blockTagList): Ditto
1498         * html/HTMLFieldSetElement.cpp:
1499         (WebCore::HTMLFieldSetElement::type): Ditto
1500         * html/HTMLInputElement.cpp:
1501         (WebCore::HTMLInputElement::type): Ditto
1502         * html/HTMLKeygenElement.cpp:
1503         (WebCore::HTMLKeygenElement::type): Ditto
1504         * html/HTMLLegendElement.cpp:
1505         (WebCore::HTMLLegendElement::type): Ditto
1506         * html/HTMLOptGroupElement.cpp:
1507         (WebCore::HTMLOptGroupElement::type): Ditto
1508         * html/HTMLOptionElement.cpp:
1509         (WebCore::HTMLOptionElement::type): Ditto
1510         * html/HTMLParser.cpp:
1511         (WebCore::HTMLParser::getNode): Ditto
1512         (WebCore::HTMLParser::isHeaderTag): Ditto
1513         (WebCore::HTMLParser::isResidualStyleTag): Ditto
1514         (WebCore::HTMLParser::isAffectedByResidualStyle): Ditto
1515         * html/HTMLSelectElement.cpp:
1516         (WebCore::HTMLSelectElement::type): Ditto
1517         * html/HTMLTextAreaElement.cpp:
1518         (WebCore::HTMLTextAreaElement::type): Ditto
1519         * inspector/InspectorController.cpp:
1520         (WebCore::platform): Ditto
1521         * inspector/JavaScriptDebugServer.cpp:
1522         (WebCore::JavaScriptDebugServer::shared): Ditto
1523         * inspector/JavaScriptProfile.cpp:
1524         (WebCore::profileCache): Ditto
1525         * inspector/JavaScriptProfileNode.cpp:
1526         (WebCore::profileNodeCache): Ditto
1527         * loader/FrameLoader.cpp:
1528         (WebCore::localSchemes): Ditto
1529         * loader/appcache/ApplicationCacheStorage.cpp:
1530         (WebCore::cacheStorage): Ditto
1531         * loader/archive/ArchiveFactory.cpp:
1532         (WebCore::archiveMIMETypes): Ditto
1533         * loader/icon/IconDatabase.cpp:
1534         (WebCore::IconDatabase::defaultDatabaseFilename): Ditto
1535         * page/EventHandler.cpp:
1536         (WebCore::EventHandler::dragState): Ditto
1537         * page/Frame.cpp:
1538         (WebCore::createRegExpForLabels): Ditto
1539         (WebCore::keepAliveSet): Ditto
1540         * page/Page.cpp:
1541         (WebCore::Page::groupName): Ditto
1542         * page/SecurityOrigin.cpp:
1543         (WebCore::isDefaultPortForProtocol): Ditto
1544         (WebCore::SecurityOrigin::databaseIdentifier): Ditto
1545         * page/mac/FrameMac.mm:
1546         (WebCore::regExpForLabels): Ditto
1547         * platform/KURL.cpp:
1548         (WebCore::blankURL): Ditto
1549         * platform/graphics/FontCache.cpp:
1550         (WebCore::alternateFamilyName): Ditto
1551         * platform/graphics/mac/FontCacheMac.mm:
1552         (WebCore::FontCache::getSimilarFontPlatformData): Ditto
1553         (WebCore::FontCache::getLastResortFallbackFont): Ditto
1554         * platform/mac/ScrollbarThemeMac.mm:
1555         (WebCore::ScrollbarTheme::nativeTheme): Ditto
1556         * platform/mac/ThemeMac.mm:
1557         (WebCore::platformTheme): Ditto
1558         * platform/mac/ThreadCheck.mm:
1559         (WebCoreReportThreadViolation): Ditto
1560         * platform/network/NetworkStateNotifier.cpp:
1561         (WebCore::networkStateNotifier): Ditto
1562         * platform/network/mac/FormDataStreamMac.mm:
1563         (WebCore::getStreamFormDataMap): Ditto
1564         (WebCore::getStreamResourceHandleMap): Ditto
1565         * platform/network/mac/ResourceResponseMac.mm:
1566         (WebCore::ResourceResponse::platformLazyInit): Ditto
1567         * platform/text/TextEncoding.cpp:
1568         (WebCore::TextEncoding::isJapanese): Ditto
1569         * rendering/RenderBlock.cpp:
1570         (WebCore::continuationOutlineTable): Ditto
1571         * rendering/RenderCounter.cpp:
1572         (WebCore::counterMaps): Ditto
1573         * rendering/RenderFlexibleBox.cpp:
1574         (WebCore::RenderFlexibleBox::layoutVerticalBox): Ditto
1575         * rendering/RenderListItem.cpp:
1576         (WebCore::RenderListItem::markerText): Ditto
1577         * rendering/RenderScrollbarTheme.cpp:
1578         (WebCore::RenderScrollbarTheme::renderScrollbarTheme): Ditto
1579         * rendering/RenderThemeMac.mm:
1580         (WebCore::RenderThemeMac::systemFont): Ditto
1581         * rendering/bidi.cpp:
1582         (WebCore::RenderBlock::checkLinesForTextOverflow): Ditto
1583         * rendering/style/RenderStyle.cpp:
1584         (WebCore::RenderStyle::initialDashboardRegions): Ditto
1585         (WebCore::RenderStyle::noneDashboardRegions): Ditto
1586         * storage/LocalStorage.cpp:
1587         (WebCore::localStorageMap): Ditto
1588         * svg/SVGAnimateMotionElement.cpp:
1589         (WebCore::SVGAnimateMotionElement::rotateMode): Ditto
1590         * svg/SVGAnimationElement.cpp:
1591         (WebCore::SVGAnimationElement::calcMode): Ditto
1592         (WebCore::SVGAnimationElement::attributeType): Ditto
1593         (WebCore::SVGAnimationElement::isAdditive): Ditto
1594         (WebCore::SVGAnimationElement::isAccumulated): Ditto
1595         * svg/SVGLangSpace.cpp:
1596         (WebCore::SVGLangSpace::xmlspace): Ditto
1597         * svg/SVGSVGElement.cpp:
1598         (WebCore::SVGSVGElement::contentScriptType): Ditto
1599         (WebCore::SVGSVGElement::contentStyleType): Ditto
1600         * svg/SVGStyleElement.cpp:
1601         (WebCore::SVGStyleElement::type): Ditto
1602         (WebCore::SVGStyleElement::media): Ditto
1603         * svg/SVGTextContentElement.cpp:
1604         (WebCore::SVGTextContentElement::parseMappedAttribute): Ditto
1605         * svg/animation/SVGSMILElement.cpp:
1606         (WebCore::SVGSMILElement::parseClockValue): Ditto
1607         (WebCore::SVGSMILElement::restart): Ditto
1608         (WebCore::SVGSMILElement::fill): Ditto
1609         (WebCore::SVGSMILElement::repeatCount): Ditto
1610         (WebCore::SVGSMILElement::notifyDependentsIntervalChanged): Ditto
1611         * svg/graphics/SVGResource.cpp:
1612         (WebCore::clientMap): Ditto
1613         * svg/graphics/SVGResourceMarker.cpp:
1614         (WebCore::SVGResourceMarker::draw): Ditto
1615         * xml/XMLHttpRequest.cpp:
1616         (WebCore::preflightResultCache): Ditto
1617         (WebCore::isSafeRequestHeader): Ditto
1618         (WebCore::isOnAccessControlResponseHeaderWhitelist): Ditto
1619         * xml/XPathExpressionNode.cpp:
1620         (WebCore::XPath::Expression::evaluationContext): Ditto
1621         * xml/XPathParser.cpp:
1622         (WebCore::XPath::isAxisName): Ditto
1623         (WebCore::XPath::isNodeTypeName): Ditto
1624         * xml/XPathValue.cpp:
1625         (WebCore::XPath::Value::toNodeSet): Ditto
1626
1627 2008-11-06  Tor Arne Vestbø  <tavestbo@trolltech.com>
1628
1629         Rubber-stamped by Simon Hausmann.
1630
1631         Remove a bunch of unused methods in the Qt media element implementation
1632
1633         * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
1634         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
1635         * platform/graphics/qt/MediaPlayerPrivatePhonon.h:
1636
1637 2008-11-05  Simon Fraser  <simon.fraser@apple.com>
1638
1639         Reviewed by Dave Hyatt
1640
1641         https://bugs.webkit.org/show_bug.cgi?id=21870
1642         
1643         Implement absoluteToLocal() to convert a point from absolute
1644         to local coordinates, optionally taking transforms into account.
1645         
1646         Use this to set offsetX/offsetY in mouse events, thus fixing
1647         offsetX/offsetY in events on elements with transforms.
1648
1649         Test: fast/events/offsetX-offsetY.html
1650
1651         * dom/MouseRelatedEvent.cpp:
1652         (WebCore::MouseRelatedEvent::receivedTarget):
1653         * rendering/RenderBox.cpp:
1654         (WebCore::RenderBox::localToAbsolute):
1655         (WebCore::RenderBox::absoluteToLocal):
1656         (WebCore::RenderBox::offsetFromContainer):
1657         * rendering/RenderBox.h:
1658         * rendering/RenderObject.cpp:
1659         (WebCore::RenderObject::absoluteToLocal):
1660         * rendering/RenderObject.h:
1661         * rendering/RenderTableCell.cpp:
1662         (WebCore::RenderTableCell::localToAbsolute):
1663         (WebCore::RenderTableCell::absoluteToLocal):
1664         * rendering/RenderTableCell.h:
1665         * rendering/RenderView.cpp:
1666         (WebCore::RenderView::absoluteToLocal):
1667         * rendering/RenderView.h:
1668
1669 2008-11-06  Alp Toker  <alp@nuanti.com>
1670
1671         Reviewed by Cameron Zwarich.
1672
1673         https://bugs.webkit.org/show_bug.cgi?id=22067
1674         [GTK] Sun Java plugin segfaults at PluginPackage::createPackage()
1675
1676         null-check symbols loaded from plugin modules, initialize the function
1677         table (like Win already does) and update it with the latest
1678         additions. Adjust whitespace for easy diff'ing with the Win port code
1679         from which it was forked.
1680
1681         This fixes crashes with libnspr4.so and any other plugins that don't
1682         provide the symbols we expect.
1683
1684         * plugins/gtk/PluginPackageGtk.cpp:
1685         (WebCore::PluginPackage::fetchInfo):
1686         (WebCore::PluginPackage::load):
1687
1688 2008-11-06  Kristian Amlie  <kristian.amlie@nokia.com>
1689
1690         Reviewed by Simon Hausmann.
1691
1692         Removed dead (and broken) code from an ancient Symbian port.
1693
1694         * config.h:
1695         * platform/text/AtomicString.h:
1696         * platform/text/PlatformString.h:
1697
1698 2008-11-06  Kristian Amlie  <kristian.amlie@nokia.com>
1699
1700         Reviewed by Simon Hausmann.
1701
1702         Use QLibrary as PlatformModule when compiling with Qt for S60.
1703
1704         * platform/FileSystem.h:
1705
1706 2008-11-06  Kristian Amlie  <kristian.amlie@nokia.com>
1707
1708         Reviewed by Simon Hausmann.
1709
1710         Compile fix for Symbian.
1711         The snprintf function is defined in stdio.h, the inclusion
1712         of snprintf.h inside this PLATFORM(SYMBIAN) block does not
1713         compile.
1714
1715         * config.h:
1716
1717 2008-11-06  Kristian Amlie  <kristian.amlie@nokia.com>
1718
1719         Reviewed by Simon Hausmann.
1720
1721         Disable webkit plugins for Symbian.
1722
1723         * WebCore.pro:
1724
1725 2008-11-06  Tor Arne Vestbø  <tavestbo@trolltech.com>
1726
1727         Fix build break in debug mode when XSLT is not enabled
1728
1729         * loader/Cache.cpp:
1730         (WebCore::Cache::dumpStats):
1731
1732 2008-11-06  Tor Arne Vestbø  <tavestbo@trolltech.com>
1733
1734         Reviewed by Simon Hausmann.
1735
1736         Repaint video on UpdateRequest to prevent recursive painting
1737
1738         Calling QWidget::render() to update the video generates a paint
1739         event that's then picked up by the event filter once more :(
1740
1741         We're really only interested in updates from Phonon, which we
1742         get through the UpdateRequest for each new frame.
1743
1744         * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
1745         (WebCore::MediaPlayerPrivate::eventFilter):
1746
1747 2008-11-06  Cameron Zwarich  <zwarich@apple.com>
1748
1749         Not reviewed.
1750
1751         Fix the WebCore build for some platforms by changing build scripts to
1752         account for the recent move of the create_hash_table script from the kjs
1753         subdirectory of JavaScriptCore to the root directory.
1754
1755         * WebCore.pro:
1756         * make-generated-sources.sh:
1757
1758 2008-11-06  Cameron Zwarich  <zwarich@apple.com>
1759
1760         Not reviewed.
1761
1762         Fix a case-sensitivity issue in Mac forwarding headers. Strangely
1763         enough, this does not always cause the build to break, even with a
1764         case-sensitive filesystem.
1765
1766         * ForwardingHeaders/runtime/Interpreter.h:
1767
1768 2008-11-05  Alexey Proskuryakov  <ap@webkit.org>
1769
1770         Reviewed by Maciej Stachowiak.
1771
1772         https://bugs.webkit.org/show_bug.cgi?id=22083
1773         MessageEvents cannot be used across threads
1774
1775         * dom/Event.idl:
1776         * dom/MessageEvent.idl:
1777         Add a NoStaticTables attribute - MessageEvent is used in worker threads, so static tables
1778         won't work.
1779
1780         * dom/MessagePort.cpp:
1781         (WebCore::MessagePort::EventData::EventData):
1782         (WebCore::MessagePort::EventData::~EventData):
1783         (WebCore::MessagePort::clone):
1784         (WebCore::MessagePort::postMessage):
1785         (WebCore::MessagePort::startConversation):
1786         (WebCore::MessagePort::dispatchMessages):
1787         * dom/MessagePort.h:
1788         Don't create a MessageEvent until dispatch time - messages can be posted across threads,
1789         but MessageEvents are tied to the thread that they were created in.
1790
1791 2008-11-05  Alexey Proskuryakov  <ap@webkit.org>
1792
1793         Reviewed by Darin Adler.
1794
1795         https://bugs.webkit.org/show_bug.cgi?id=22066
1796         Implement Worker global object
1797
1798         * DerivedSources.make: Added WorkerLocation IDL and JSWorkerContext lookup table.
1799
1800         * WebCore.xcodeproj/project.pbxproj: Only adding files to Mac project for now, as Worker
1801         support is still disabled by default.
1802
1803         * bindings/js/JSDOMGlobalObject.cpp: (WebCore::toJSDOMGlobalObject): Implemented Worker case.
1804
1805         * bindings/js/JSMessageChannelConstructor.cpp:
1806         (WebCore::JSMessageChannelConstructor::JSMessageChannelConstructor): Ditto.
1807
1808         * bindings/js/JSWorkerContext.cpp: Added.
1809         * bindings/js/JSWorkerContext.h: Added.
1810         * bindings/js/WorkerScriptController.cpp: Added.
1811         * bindings/js/WorkerScriptController.h: Added.
1812         * dom/WorkerContext.cpp: Added.
1813         * dom/WorkerContext.h: Added.
1814         Added an implementation of worker contexts.
1815
1816         * dom/DedicatedWorker.cpp:
1817         (WebCore::DedicatedWorker::startLoad): Fixed a lifetime bug I saw on my tests.
1818         (WebCore::DedicatedWorker::notifyFinished): Create a thread. Currently, object ownership
1819         and lifetime is not clear at all.
1820
1821         * dom/WorkerLocation.cpp: Added.
1822         * dom/WorkerLocation.h: Added.
1823         * dom/WorkerLocation.idl: Added.
1824         Added WorkerLocation, which is one of the objects available to workers.
1825
1826         * dom/WorkerThread.cpp: Added.
1827         (WebCore::WorkerThread::WorkerThread):
1828         (WebCore::WorkerThread::start):
1829         (WebCore::WorkerThread::workerThreadStart):
1830         (WebCore::WorkerThread::workerThread):
1831         * dom/WorkerThread.h: Added.
1832         (WebCore::WorkerThread::create):
1833         Run some code in a worker thread (no message loop yet).
1834
1835 2008-11-05  Antti Koivisto  <antti@apple.com>
1836
1837         Reviewed by Dan Bernstein.
1838         
1839         https://bugs.webkit.org/show_bug.cgi?id=22093
1840         Don't keep decoded stylesheet data in cache
1841         
1842         <rdar://problem/6343588>
1843
1844         Don't keep decoded stylesheet string around in the cache. There are no sharing benefits and
1845         performance benefits are negligible (no measured PLT impact). Reduces memory consumption of
1846         style sheet data in cache by 2/3 in common case.  
1847
1848         * loader/CachedCSSStyleSheet.cpp:
1849         (WebCore::CachedCSSStyleSheet::sheetText):
1850         (WebCore::CachedCSSStyleSheet::data):
1851         * loader/CachedCSSStyleSheet.h:
1852
1853 2008-11-05  David Kilzer  <ddkilzer@apple.com>
1854
1855         Bug 21596: WebCore::Cache should use parsed Pragma and Cache-Control headers
1856
1857         <https://bugs.webkit.org/show_bug.cgi?id=21596>
1858
1859         Reviewed by Antti.
1860
1861         This patch adds real parsing for Pragma and Cache-Control headers
1862         based on RFC 2616, Sections 2, 14.9 and 14.32.  It also adds some
1863         new String and StringImpl methods to assist with the parsing.
1864
1865         * loader/Cache.cpp:
1866         (WebCore::Cache::dumpStats): Added.  Convenience method for dumping
1867         stats outside of Safari.
1868         * loader/Cache.h: Declared dumpStats().
1869
1870         * loader/CachedResource.cpp:
1871         (WebCore::CachedResource::mustRevalidate): Updated to use
1872         ResourceResponseBase::cacheControlDirectives() instead of substring
1873         matching of the entire Cache-Control header.
1874
1875         * loader/loader.cpp:
1876         (WebCore::Loader::Host::didReceiveResponse): Used the local
1877         'resource' variable instead of 'request->cachedResource()'.
1878
1879         * platform/network/ResourceResponseBase.cpp:
1880         (WebCore::ResourceResponseBase::setHTTPHeaderField): Set
1881         m_haveParsedCacheControlHeader to false when a "Cache-Control"
1882         header is set.  Ditto for m_haveParsedPragmaHeader and "Pragma".
1883         (WebCore::ResourceResponseBase::parsePragmaDirectives): Added.
1884         Provides parsed Pragma header directives.
1885         (WebCore::ResourceResponseBase::parseCacheControlDirectives): Added.
1886         Provides parsed Cache-Control header directives.
1887         (WebCore::isCacheHeaderSeparator): Added.  Returns true if a
1888         character is a separator character per RFC 2616, Section 2.2, else
1889         returns false.
1890         (WebCore::isControlCharacter): Added.  Returns true if a character
1891         is a control character per RFC 2616 Section 2.2, else returns false.
1892         (WebCore::trimToNextSeparator): Added.  Returns a string truncated
1893         at the first separator character per isCacheHeaderSeparator().
1894         (WebCore::parseCacheHeader): Added.  This is the main parsing
1895         routine for both Cache-Control and Pragma headers.
1896         (WebCore::parseCacheControlDirectiveValues): Added.  This splits
1897         certain Cache-Control directive values into a vector of strings.
1898         * platform/network/ResourceResponseBase.h:
1899         (WebCore::CacheControlDirectiveMap): Added.  Typedef for a parsed
1900         Cache-Control header.
1901         (WebCore::PragmaDirectiveMap): Added.  Typedef for a parsed Pragma
1902         header.
1903         (WebCore::ResourceResponseBase::parsePragmaDirectives): Added
1904         declaration.
1905         (WebCore::ResourceResponseBase::parseCacheControlDirectives): Ditto.
1906         (WebCore::ResourceResponseBase::m_haveParsedCacheControlHeader):
1907         Added.  Boolean to describe when the "Cache-Control" header needs to
1908         be reparsed.
1909         (WebCore::ResourceResponseBase::m_haveParsedPragmaHeader):  Added.
1910         Boolean to describe when the "Pragma" header needs to be reparsed.
1911         (WebCore::ResourceResponseBase::m_cacheControlDirectiveMap): Added.
1912         Cached map to hold parsed "Cache-Control" headers.
1913         (WebCore::ResourceResponseBase::m_pragmaDirectiveMap): Added.
1914         Cached map to hold parsed "Pragma" headers.
1915
1916         * platform/text/PlatformString.h:
1917         (WebCore::String::find): Added.  Returns the first match based on
1918         the character-matching function pointer passed in.
1919         (WebCore::String::removeCharacters): Added declaration.
1920         (WebCore::find): Added.  Inline method that takes a character-
1921         matching function pointer.  Called by StringImpl::find().
1922         * platform/text/String.cpp:
1923         (WebCore::String::removeCharacters): Added.  Calls
1924         StringImpl::removeCharacters().
1925         * platform/text/StringImpl.cpp:
1926         (WebCore::StringImpl::removeCharacters): Added.  Returns a string
1927         with all characters removed that match the character-matching
1928         function pointer passed in.  If there is no change to the string, it
1929         returns itself.  Based heavily on StringImpl::simplifyWhitespace().
1930         (WebCore::StringImpl::find): Added.  Calls WebCore::find().
1931         * platform/text/StringImpl.h:
1932         (WebCore::FindMatchFunctionPtr): Added.  Typedef for a character-
1933         matching function pointer.
1934         (WebCore::StringImpl::removeCharacters): Added declaration.
1935         (WebCore::StringImpl::find): Ditto.
1936
1937 2008-11-05  Justin Garcia  <justin.garcia@apple.com>
1938
1939         Reviewed by Beth Dakin.
1940
1941         <rdar://problem/5480736> In Mail and Gmail, copied indented text pastes with line break
1942         
1943         As a rule, we don't allow merges out of blockquotes.  In the bug, we are inserting a text node 
1944         between two blockquotes.  Because the start merge moves the text node into a blockquote, when we
1945         determine whether or not we should do the end merge, it incorrectly appears as though the end merge 
1946         is merging out of a blockquote.  The fix is to determine whether or not we should do the end merge
1947         before we do the start merge, so that the start merge doesn't effect our decision.
1948
1949         * editing/ReplaceSelectionCommand.cpp:
1950         (WebCore::ReplaceSelectionCommand::ReplaceSelectionCommand): Initialize the new boolean.
1951         (WebCore::ReplaceSelectionCommand::mergeEndIfNeeded): Moved code from doApply() here for clarity.
1952         (WebCore::ReplaceSelectionCommand::doApply): Set m_shouldMergeEnd before we do the start merge.
1953         * editing/ReplaceSelectionCommand.h: Added m_shouldMergeEnd.
1954
1955 2008-11-05  Cameron Zwarich  <zwarich@apple.com>
1956
1957         Not reviewed.
1958
1959         Speculatively fix the Windows build, even though these changes may not
1960         actually matter for anything in the build, because the Windows bots are
1961         behind.
1962
1963         * WebCore.vcproj/WebCore.vcproj:
1964
1965 2008-11-05  Cameron Zwarich  <zwarich@apple.com>
1966
1967         Not reviewed.
1968
1969         Fix the Qt build.
1970
1971         * bridge/qt/qt_class.cpp:
1972         * bridge/qt/qt_runtime.h:
1973
1974 2008-11-05  Cameron Zwarich  <zwarich@apple.com>
1975
1976         Rubber-stamped by Sam Weinig.
1977
1978         Move more files to the runtime subdirectory of JavaScriptCore.
1979
1980         * ForwardingHeaders/kjs/collector.h: Removed.
1981         * ForwardingHeaders/kjs/completion.h: Removed.
1982         * ForwardingHeaders/kjs/identifier.h: Removed.
1983         * ForwardingHeaders/kjs/interpreter.h: Removed.
1984         * ForwardingHeaders/kjs/lookup.h: Removed.
1985         * ForwardingHeaders/kjs/operations.h: Removed.
1986         * ForwardingHeaders/kjs/protect.h: Removed.
1987         * ForwardingHeaders/kjs/ustring.h: Removed.
1988         * ForwardingHeaders/runtime/Collector.h: Copied from ForwardingHeaders/kjs/collector.h.
1989         * ForwardingHeaders/runtime/Completion.h: Copied from ForwardingHeaders/kjs/completion.h.
1990         * ForwardingHeaders/runtime/Identifier.h: Copied from ForwardingHeaders/kjs/identifier.h.
1991         * ForwardingHeaders/runtime/Interpreter.h: Copied from ForwardingHeaders/kjs/interpreter.h.
1992         * ForwardingHeaders/runtime/Lookup.h: Copied from ForwardingHeaders/kjs/lookup.h.
1993         * ForwardingHeaders/runtime/Operations.h: Copied from ForwardingHeaders/kjs/operations.h.
1994         * ForwardingHeaders/runtime/Protect.h: Copied from ForwardingHeaders/kjs/protect.h.
1995         * ForwardingHeaders/runtime/UString.h: Copied from ForwardingHeaders/kjs/ustring.h.
1996         * bindings/js/GCController.cpp:
1997         * bindings/js/JSCustomPositionCallback.h:
1998         * bindings/js/JSCustomPositionErrorCallback.h:
1999         * bindings/js/JSCustomSQLStatementCallback.h:
2000         * bindings/js/JSCustomSQLStatementErrorCallback.h:
2001         * bindings/js/JSCustomSQLTransactionErrorCallback.h:
2002         * bindings/js/JSCustomVoidCallback.h:
2003         * bindings/js/JSDOMBinding.h:
2004         * bindings/js/JSDOMWindowBase.h:
2005         * bindings/js/JSEventListener.h:
2006         * bindings/js/ScheduledAction.h:
2007         * bindings/js/ScriptController.cpp:
2008         * bindings/js/ScriptController.h:
2009         * bindings/objc/WebScriptObject.mm:
2010         * bindings/scripts/CodeGeneratorJS.pm:
2011         * bridge/NP_jsobject.cpp:
2012         * bridge/c/c_class.cpp:
2013         * bridge/jni/jni_class.cpp:
2014         * bridge/jni/jni_jsobject.mm:
2015         * bridge/npruntime.cpp:
2016         * bridge/runtime_root.h:
2017         * history/CachedPage.h:
2018         * html/CanvasRenderingContext2D.cpp:
2019         * html/HTMLCanvasElement.cpp:
2020         * inspector/InspectorController.cpp:
2021         * inspector/JavaScriptCallFrame.cpp:
2022         * page/Console.cpp:
2023         * page/Page.cpp:
2024         * platform/text/AtomicString.cpp:
2025         * platform/text/PlatformString.h:
2026
2027 2008-11-05  Sam Weinig  <sam@webkit.org>
2028
2029         Reviewed by Anders Carlsson.
2030
2031         Fix https://bugs.webkit.org/show_bug.cgi?id=22085
2032         The Plugin JS object should expose item() and namedItem() methods to match Firefox
2033
2034         * bindings/js/JSPluginCustom.cpp:
2035         (WebCore::JSPlugin::nameGetter):
2036         * plugins/Plugin.cpp:
2037         (WebCore::Plugin::namedItem):
2038         * plugins/Plugin.h:
2039         * plugins/Plugin.idl:
2040
2041 2008-11-05  Alexey Proskuryakov  <ap@webkit.org>
2042
2043         Reviewed by Maciej Stachowiak.
2044
2045         https://bugs.webkit.org/show_bug.cgi?id=21060
2046         Range#surroundContents incorrectly throws BAD_BOUNDARYPOINTS_ERR
2047
2048         Test: fast/dom/Range/surroundContents-check-boundary-points.html
2049
2050         * dom/Range.cpp: (WebCore::Range::surroundContents): Fix BAD_BOUNDARYPOINTS_ERR checks.
2051
2052 2008-11-05  Anders Carlsson  <andersca@apple.com>
2053
2054         Reviewed by Dan Bernstein.
2055
2056         Remove two global destructors from CoreTextController.
2057         
2058         * platform/graphics/mac/CoreTextController.cpp:
2059         (WebCore::CoreTextController::collectCoreTextRunsForCharacters):
2060
2061 2008-11-05  Darin Fisher  <darin@chromium.org>
2062
2063         Reviewed by Darin Adler.
2064
2065         CRASH at Scrollbar::invalidateRect due to null m_client
2066         https://bugs.webkit.org/show_bug.cgi?id=22080
2067
2068         * platform/Scrollbar.cpp:
2069         (WebCore::Scrollbar::isWindowActive):
2070         (WebCore::Scrollbar::invalidateRect):
2071
2072 2008-11-04  Sam Weinig  <sam@webkit.org>
2073
2074         Reviewed by Simon Hausmann.
2075
2076         Fix https://bugs.webkit.org/show_bug.cgi?id=21648
2077         navigator.mimeTypes and navigator.plugins don't expose item and namedItem to JS
2078
2079         - Also adds constructors for Plugin, PluginArray, MimeType and MimeTypeArray.
2080
2081         * bindings/js/JSMimeTypeArrayCustom.cpp:
2082         (WebCore::JSMimeTypeArray::nameGetter):
2083         * bindings/js/JSPluginArrayCustom.cpp:
2084         (WebCore::JSPluginArray::nameGetter):
2085         * page/DOMWindow.idl:
2086         * plugins/MimeType.idl:
2087         * plugins/MimeTypeArray.cpp:
2088         (WebCore::MimeTypeArray::namedItem):
2089         * plugins/MimeTypeArray.h:
2090         * plugins/MimeTypeArray.idl:
2091         * plugins/Plugin.idl:
2092         * plugins/PluginArray.cpp:
2093         (WebCore::PluginArray::namedItem):
2094         * plugins/PluginArray.h:
2095         * plugins/PluginArray.idl:
2096
2097 2008-11-05  Steve Falkenburg  <sfalken@apple.com>
2098
2099         Build fix.
2100
2101         * plugins/PluginPackage.cpp:
2102
2103 2008-11-05  Jeff Cook  <cookiecaper@gmail.com>
2104
2105         Reviewed by Simon Hausmann and Tor Arne.
2106
2107         Fix crash in the Qt port when unloading swfdec and Flash 10
2108         by reordering window destruction and plugin stop.
2109
2110         See https://bugs.webkit.org/show_bug.cgi?id=20779
2111
2112         * plugins/qt/PluginViewQt.cpp:
2113         (WebCore::PluginView::stop):
2114
2115 2008-11-05  Simon Hausmann  <hausmann@webkit.org>
2116
2117         Reviewed by Tor Arne Vestbø
2118
2119         Fix loading of Flash 10 in the Qt port by faking the toolkit to be Gtk.
2120
2121         Otherwise Flash refuses to load and function :(
2122
2123         * plugins/PluginPackage.cpp:
2124         (WebCore::PluginPackage::determineQuirks):
2125         * plugins/PluginQuirkSet.h:
2126         (WebCore::):
2127         * plugins/qt/PluginViewQt.cpp:
2128         (WebCore::PluginView::getValue):
2129
2130 2008-11-05  Simon Hausmann  <hausmann@webkit.org>
2131
2132         Reviewed by Tor Arne Vestbø
2133
2134         Unify determineQuirks between the Qt and the Gtk PluginPackage.
2135         Share the code for parsing the module version from the description.
2136         This is currently used to determine Flash based quirks.
2137
2138         * plugins/PluginPackage.cpp:
2139         (WebCore::PluginPackage::createPackage):
2140         (WebCore::PluginPackage::determineQuirks):
2141         (WebCore::PluginPackage::determineModuleVersionFromDescription):
2142         * plugins/PluginPackage.h:
2143         * plugins/gtk/PluginPackageGtk.cpp:
2144         (WebCore::PluginPackage::fetchInfo):
2145         * plugins/qt/PluginPackageQt.cpp:
2146         (WebCore::PluginPackage::fetchInfo):
2147
2148 2008-11-04  Cameron Zwarich  <zwarich@apple.com>
2149
2150         Rubber-stamped by Sam Weinig.
2151
2152         Move kjs/dtoa.h to the wtf subdirectory of JavaScriptCore.
2153
2154         * ForwardingHeaders/kjs/dtoa.h: Removed.
2155         * ForwardingHeaders/wtf/dtoa.h: Copied from ForwardingHeaders/kjs/dtoa.h.
2156         * css/CSSParser.cpp:
2157         * platform/text/String.cpp:
2158         * platform/text/StringImpl.cpp:
2159
2160 2008-11-04  Jonathan Haas  <myrdred@gmail.com>
2161
2162         Addiitonal tweaks and patch prep by Pamela Greene <pam@chromium.org>
2163
2164         Reviewed by Darin Adler.
2165
2166         Fixed an issue which could cause memory corruption using ToT libxml.
2167         See https://bugs.webkit.org/show_bug.cgi?id=15715
2168
2169         Test: fast/xsl/xslt-nested-stylesheets.xml
2170
2171         * xml/XSLImportRule.cpp:
2172         (WebCore::XSLImportRule::setXSLStyleSheet): Set parent rather than owner document
2173         * xml/XSLStyleSheet.cpp:
2174         (WebCore::XSLStyleSheet::XSLStyleSheet): Initialize m_parentStyleSheet
2175         (WebCore::XSLStyleSheet::parseString): Make all child stylesheets use parent's dictionary
2176         (WebCore::XSLStyleSheet::setParentStyleSheet): Added
2177         * xml/XSLStyleSheet.h: Added m_parentStyleSheet member
2178
2179 2008-11-04  Simon Fraser  <simon.fraser@apple.com>
2180
2181         No review.
2182
2183         Improved buid fix: include MathExtras.h to get roundf on all platforms.
2184
2185         * platform/graphics/FloatPoint.h:
2186
2187 2008-11-04  Brady Eidson  <beidson@apple.com>
2188
2189         Reviewed by John Sullivan
2190
2191         Add a simple "visited" method to HistoryItem for use by global history
2192
2193         * WebCore.base.exp:
2194
2195         * history/HistoryItem.cpp:
2196         (WebCore::HistoryItem::visited):  Update the title on the item, set last visited time,
2197           and bump the visit count.  All things that should happen when a url is visited again!
2198         * history/HistoryItem.h:
2199
2200 2008-11-04  Jan Michael Alonzo  <jmalonzo@webkit.org>
2201
2202         Build fix. Not reviewed.
2203
2204         * platform/graphics/FloatPoint.h: include math.h.
2205         reported by zdobersek in #webkit.
2206
2207 2008-11-04  Darin Fisher  <darin@chromium.org>
2208  
2209         Reviewed by Anders Carlsson.
2210  
2211         No need to clobber all ResourceRequest fields in FrameLoader::reload()
2212         https://bugs.webkit.org/show_bug.cgi?id=21949
2213  
2214         * loader/FrameLoader.cpp:
2215         (WebCore::FrameLoader::reload):
2216
2217 2008-11-04  Darin Adler  <darin@apple.com>
2218
2219         Reviewed by Tim Hatcher.
2220
2221         * storage/Database.cpp:
2222         (WebCore::databaseVersionKey): Tweaked formatting.
2223
2224 2008-11-03  Darin Adler  <darin@apple.com>
2225
2226         Reviewed by Tim Hatcher.
2227
2228         - https://bugs.webkit.org/show_bug.cgi?id=22061
2229           create script to check for exit-time destructors
2230
2231         * WebCore.xcodeproj/project.pbxproj: Added a script
2232         phase that runs the check-for-exit-time-destructors script.
2233
2234         * html/HTMLAttributeNames.in: Removed some unused attribute names.
2235
2236         * html/HTMLEmbedElement.cpp:
2237         (WebCore::HTMLEmbedElement::parseMappedAttribute): Removed code that
2238         sets the write-only m_pluginPage.
2239         * html/HTMLEmbedElement.h: Ditto.
2240
2241         * platform/mac/CursorMac.mm:
2242         (WebCore::leakNamedCursor): Changed to return a Cursor&.
2243         (WebCore::pointerCursor): Changed to leak an object to avoid an
2244         exit-time destructor.
2245         (WebCore::crossCursor): Ditto.
2246         (WebCore::handCursor): Ditto.
2247         (WebCore::moveCursor): Ditto.
2248         (WebCore::verticalTextCursor): Ditto.
2249         (WebCore::cellCursor): Ditto.
2250         (WebCore::contextMenuCursor): Ditto.
2251         (WebCore::aliasCursor): Ditto.
2252         (WebCore::zoomInCursor): Ditto.
2253         (WebCore::zoomOutCursor): Ditto.
2254         (WebCore::copyCursor): Ditto.
2255         (WebCore::noneCursor): Ditto.
2256         (WebCore::progressCursor): Ditto.
2257         (WebCore::noDropCursor): Ditto.
2258         (WebCore::notAllowedCursor): Ditto.
2259         (WebCore::iBeamCursor): Ditto.
2260         (WebCore::waitCursor): Ditto.
2261         (WebCore::helpCursor): Ditto.
2262         (WebCore::eastResizeCursor): Ditto.
2263         (WebCore::northResizeCursor): Ditto.
2264         (WebCore::northEastResizeCursor): Ditto.
2265         (WebCore::northWestResizeCursor): Ditto.
2266         (WebCore::southResizeCursor): Ditto.
2267         (WebCore::southEastResizeCursor): Ditto.
2268         (WebCore::southWestResizeCursor): Ditto.
2269         (WebCore::westResizeCursor): Ditto.
2270         (WebCore::northSouthResizeCursor): Ditto.
2271         (WebCore::eastWestResizeCursor): Ditto.
2272         (WebCore::northEastSouthWestResizeCursor): Ditto.
2273         (WebCore::northWestSouthEastResizeCursor): Ditto.
2274         (WebCore::columnResizeCursor): Ditto.
2275         (WebCore::rowResizeCursor): Ditto.
2276         (WebCore::grabCursor): Ditto.
2277         (WebCore::grabbingCursor): Ditto.
2278
2279         * storage/Database.cpp:
2280         (WebCore::guidMutex): Changed to leak an object to avoid an
2281         exit-time destructor. Also added a comment explaining why it's
2282         thread safe.
2283         (WebCore::guidToVersionMap): Ditto.
2284         (WebCore::guidToDatabaseMap): Ditto.
2285         (WebCore::Database::databaseInfoTableName): Ditto.
2286         (WebCore::databaseVersionKey): Ditto.
2287         (WebCore::Database::getVersionFromDatabase): Ditto.
2288         (WebCore::Database::setVersionInDatabase): Ditto.
2289         (WebCore::guidForOriginAndName): Ditto.
2290         * storage/DatabaseTracker.cpp:
2291         (WebCore::DatabaseTracker::tracker): Ditto.
2292         (WebCore::notificationMutex): Ditto.
2293         (WebCore::notificationQueue): Ditto.
2294         (WebCore::DatabaseTracker::notifyDatabasesChanged): Ditto.
2295
2296 2008-11-04  Simon Fraser  <simon.fraser@apple.com>
2297
2298         Reviewed by Dave Hyatt
2299
2300         https://bugs.webkit.org/show_bug.cgi?id=21941
2301
2302         Rename absolutePosition() to localToAbsolute(), and add the ability
2303         to optionally take transforms into account (which will eventually be the
2304         default behavior).
2305
2306         * WebCore.base.exp:
2307         * WebCore.xcodeproj/project.pbxproj:
2308         * dom/ContainerNode.cpp:
2309         (WebCore::ContainerNode::getUpperLeftCorner):
2310         (WebCore::ContainerNode::getLowerRightCorner):
2311         (WebCore::ContainerNode::getRect):
2312         * dom/ContainerNode.h:
2313         * dom/MouseRelatedEvent.cpp:
2314         (WebCore::MouseRelatedEvent::receivedTarget):
2315         * dom/Node.cpp:
2316         (WebCore::Node::getRect):
2317         * editing/SelectionController.cpp:
2318         (WebCore::SelectionController::layout):
2319         (WebCore::SelectionController::caretRect):
2320         * editing/visible_units.cpp:
2321         (WebCore::previousLinePosition):
2322         (WebCore::nextLinePosition):
2323         * html/HTMLAnchorElement.cpp:
2324         (WebCore::HTMLAnchorElement::isKeyboardFocusable):
2325         (WebCore::HTMLAnchorElement::defaultEventHandler):
2326         * html/HTMLAreaElement.cpp:
2327         (WebCore::HTMLAreaElement::getRect):
2328         * html/HTMLImageElement.cpp:
2329         (WebCore::HTMLImageElement::x):
2330         (WebCore::HTMLImageElement::y):
2331         * html/HTMLInputElement.cpp:
2332         (WebCore::HTMLInputElement::defaultEventHandler):
2333         * html/HTMLInputElement.h:
2334         * page/AccessibilityRenderObject.cpp:
2335         (WebCore::AccessibilityRenderObject::boundingBoxRect):
2336         * page/EventHandler.cpp:
2337         (WebCore::EventHandler::handleDrag):
2338         * platform/graphics/FloatPoint.h:
2339         (WebCore::roundedIntPoint):
2340         * platform/graphics/IntSize.h:
2341         (WebCore::IntSize::expand):
2342         * rendering/LayoutState.cpp:
2343         (WebCore::LayoutState::LayoutState):
2344         * rendering/RenderBlock.cpp:
2345         (WebCore::RenderBlock::layoutBlock):
2346         (WebCore::RenderBlock::paintObject):
2347         (WebCore::RenderBlock::selectionGapRects):
2348         (WebCore::RenderBlock::fillBlockSelectionGaps):
2349         (WebCore::RenderBlock::nodeAtPoint):
2350         (WebCore::RenderBlock::positionForCoordinates):
2351         * rendering/RenderBox.cpp:
2352         (WebCore::RenderBox::localToAbsolute):
2353         (WebCore::RenderBox::computeAbsoluteRepaintRect):
2354         (WebCore::RenderBox::caretRect):
2355         * rendering/RenderBox.h:
2356         (WebCore::RenderBox::relativePositionOffset):
2357         * rendering/RenderContainer.cpp:
2358         (WebCore::RenderContainer::addLineBoxRects):
2359         * rendering/RenderFlow.cpp:
2360         (WebCore::RenderFlow::absoluteClippedOverflowRect):
2361         (WebCore::RenderFlow::caretRect):
2362         (WebCore::RenderFlow::addFocusRingRects):
2363         * rendering/RenderLayer.cpp:
2364         (WebCore::RenderLayer::updateLayerPosition):
2365         (WebCore::RenderLayer::convertToLayerCoords):
2366         (WebCore::RenderLayer::addScrolledContentOffset):
2367         (WebCore::RenderLayer::subtractScrolledContentOffset):
2368         (WebCore::RenderLayer::scrollRectToVisible):
2369         * rendering/RenderLayer.h:
2370         (WebCore::RenderLayer::scrolledContentOffset):
2371         (WebCore::RenderLayer::relativePositionOffset):
2372         * rendering/RenderListBox.cpp:
2373         (WebCore::RenderListBox::panScroll):
2374         (WebCore::RenderListBox::scrollToward):
2375         * rendering/RenderListMarker.cpp:
2376         (WebCore::RenderListMarker::selectionRect):
2377         * rendering/RenderObject.cpp:
2378         (WebCore::RenderObject::absoluteBoundingBoxRect):
2379         (WebCore::RenderObject::computeAbsoluteRepaintRect):
2380         (WebCore::RenderObject::localToAbsolute):
2381         (WebCore::RenderObject::addDashboardRegions):
2382         (WebCore::RenderObject::absoluteContentBox):
2383         (WebCore::RenderObject::absoluteOutlineBox):
2384         * rendering/RenderObject.h:
2385         (WebCore::RenderObject::localToAbsoluteForContent):
2386         * rendering/RenderPart.cpp:
2387         (WebCore::RenderPart::updateWidgetPosition):
2388         * rendering/RenderReplaced.cpp:
2389         (WebCore::RenderReplaced::selectionRect):
2390         * rendering/RenderSVGInlineText.cpp:
2391         (WebCore::RenderSVGInlineText::computeAbsoluteRectForRange):
2392         * rendering/RenderSVGText.cpp:
2393         (WebCore::RenderSVGText::absoluteRects):
2394         * rendering/RenderTableCell.cpp:
2395         (WebCore::RenderTableCell::localToAbsolute):
2396         * rendering/RenderTableCell.h:
2397         * rendering/RenderText.cpp:
2398         (WebCore::RenderText::addLineBoxRects):
2399         (WebCore::RenderText::caretRect):
2400         (WebCore::RenderText::selectionRect):
2401         * rendering/RenderVideo.cpp:
2402         (WebCore::RenderVideo::updatePlayer):
2403         * rendering/RenderView.cpp:
2404         (WebCore::RenderView::localToAbsolute):
2405         * rendering/RenderView.h:
2406         * rendering/RenderWidget.cpp:
2407         (WebCore::RenderWidget::updateWidgetPosition):
2408         * svg/SVGSVGElement.cpp:
2409         (WebCore::SVGSVGElement::getScreenCTM):
2410
2411 2008-11-03  Yael Aharon  <yael.aharon@nokia.com>
2412
2413         Reviewed by Simon Hausmann.
2414
2415         Add methods for getting and setting user data on History Item.
2416         This change is limited to QT port only. Tests were added in
2417         the patch for https://bugs.webkit.org/show_bug.cgi?id=21864.
2418
2419         Minor change by Simon: made the functions inline and added a missing
2420         const.
2421
2422         * history/HistoryItem.h:
2423
2424 2008-11-01  Alexey Proskuryakov  <ap@webkit.org>
2425
2426         Reviewed by Darin Adler.
2427
2428         https://bugs.webkit.org/show_bug.cgi?id=22030
2429         Make EventNames usable from multiple threads
2430
2431         * platform/text/AtomicString.cpp:
2432         (WebCore::stringTable):
2433         (WebCore::AtomicString::add):
2434         (WebCore::AtomicString::remove):
2435         (WebCore::AtomicString::find):
2436         (WebCore::AtomicString::init):
2437         * platform/text/AtomicString.h:
2438         Atomic string table is now per-thread. Individual strings cannot be shared between threads,
2439         so global AtomicString constants cannot be used from threads other than the main one.
2440
2441         * dom/EventNames.cpp:
2442         (WebCore::EventNames::EventNames):
2443         (WebCore::eventNames):
2444         (WebCore::EventNames::init):
2445         * dom/EventNames.h:
2446         Made EventNames a ThreadSpecific struct. Individual event names are now accessed as
2447         eventNames().fooEvent, not EventNames::fooEvent. This makes EventNames usable from all
2448         threads.
2449
2450         * WebCore.base.exp:
2451         * bindings/js/JSDOMWindowBase.cpp:
2452         * bindings/js/JSEventListener.cpp:
2453         * bindings/js/ScriptController.cpp:
2454         (WebCore::ScriptController::processingUserGesture):
2455         * dom/BeforeTextInsertedEvent.cpp:
2456         (WebCore::BeforeTextInsertedEvent::BeforeTextInsertedEvent):
2457         * dom/BeforeUnloadEvent.cpp:
2458         (WebCore::BeforeUnloadEvent::BeforeUnloadEvent):
2459         * dom/CharacterData.cpp:
2460         (WebCore::CharacterData::dispatchModifiedEvent):
2461         * dom/ContainerNode.cpp:
2462         (WebCore::dispatchChildInsertionEvents):
2463         (WebCore::dispatchChildRemovalEvents):
2464         * dom/DedicatedWorker.cpp:
2465         (WebCore::DedicatedWorker::dispatchErrorEvent):
2466         * dom/Document.cpp:
2467         (WebCore::Document::implicitClose):
2468         (WebCore::Document::setFocusedNode):
2469         (WebCore::Document::addListenerTypeIfNeeded):
2470         (WebCore::Document::removeWindowInlineEventListenerForType):
2471         (WebCore::Document::addWindowEventListener):
2472         (WebCore::Document::removeWindowEventListener):
2473         (WebCore::Document::finishedParsing):
2474         * dom/EventTargetNode.cpp:
2475         (WebCore::EventTargetNode::dispatchGenericEvent):
2476         (WebCore::EventTargetNode::dispatchSubtreeModifiedEvent):
2477         (WebCore::EventTargetNode::dispatchWindowEvent):
2478         (WebCore::EventTargetNode::dispatchUIEvent):
2479         (WebCore::EventTargetNode::dispatchSimulatedClick):
2480         (WebCore::EventTargetNode::dispatchMouseEvent):
2481         (WebCore::EventTargetNode::dispatchFocusEvent):
2482         (WebCore::EventTargetNode::dispatchBlurEvent):
2483         (WebCore::EventTargetNode::defaultEventHandler):
2484         (WebCore::EventTargetNode::on*): (multiple methods)
2485         (WebCore::EventTargetNode::setOn*): (multiple methods)
2486         * dom/KeyboardEvent.cpp:
2487         (WebCore::eventTypeForKeyboardEventType):
2488         (WebCore::KeyboardEvent::keyCode):
2489         (WebCore::KeyboardEvent::charCode):
2490         * dom/MessageEvent.cpp:
2491         (WebCore::MessageEvent::MessageEvent):
2492         * dom/MessagePort.cpp:
2493         (WebCore::MessagePort::dispatchMessages):
2494         (WebCore::MessagePort::dispatchCloseEvent):
2495         * dom/MouseEvent.cpp:
2496         (WebCore::MouseEvent::isDragEvent):
2497         (WebCore::MouseEvent::toElement):
2498         (WebCore::MouseEvent::fromElement):
2499         * dom/OverflowEvent.cpp:
2500         (WebCore::OverflowEvent::OverflowEvent):
2501         * dom/TextEvent.cpp:
2502         (WebCore::TextEvent::TextEvent):
2503         * dom/WebKitAnimationEvent.cpp:
2504         (WebCore::WebKitAnimationEvent::WebKitAnimationEvent):
2505         (WebCore::WebKitAnimationEvent::~WebKitAnimationEvent):
2506         (WebCore::WebKitAnimationEvent::initWebKitAnimationEvent):
2507         (WebCore::WebKitAnimationEvent::animationName):
2508         (WebCore::WebKitAnimationEvent::elapsedTime):
2509         * dom/WebKitTransitionEvent.cpp:
2510         (WebCore::WebKitTransitionEvent::WebKitTransitionEvent):
2511         (WebCore::WebKitTransitionEvent::~WebKitTransitionEvent):
2512         (WebCore::WebKitTransitionEvent::initWebKitTransitionEvent):
2513         (WebCore::WebKitTransitionEvent::propertyName):
2514         (WebCore::WebKitTransitionEvent::elapsedTime):
2515         * dom/WheelEvent.cpp:
2516         (WebCore::WheelEvent::WheelEvent):
2517         (WebCore::WheelEvent::initWheelEvent):
2518         * dom/XMLTokenizerLibxml2.cpp:
2519         * dom/XMLTokenizerQt.cpp:
2520         * editing/DeleteButton.cpp:
2521         (WebCore::DeleteButton::defaultEventHandler):
2522         * editing/EditCommand.cpp:
2523         * editing/Editor.cpp:
2524         (WebCore::Editor::canDHTMLCut):
2525         (WebCore::Editor::canDHTMLCopy):
2526         (WebCore::Editor::canDHTMLPaste):
2527         (WebCore::Editor::tryDHTMLCopy):
2528         (WebCore::Editor::tryDHTMLCut):
2529         (WebCore::Editor::tryDHTMLPaste):
2530         (WebCore::dispatchEditableContentChangedEvents):
2531         * editing/ReplaceSelectionCommand.cpp:
2532         (WebCore::ReplacementFragment::ReplacementFragment):
2533         * editing/SelectionController.cpp:
2534         (WebCore::SelectionController::setFocused):
2535         * html/HTMLAnchorElement.cpp:
2536         (WebCore::HTMLAnchorElement::defaultEventHandler):
2537         * html/HTMLBodyElement.cpp:
2538         (WebCore::HTMLBodyElement::parseMappedAttribute):
2539         * html/HTMLButtonElement.cpp:
2540         (WebCore::HTMLButtonElement::parseMappedAttribute):
2541         (WebCore::HTMLButtonElement::defaultEventHandler):
2542         * html/HTMLElement.cpp:
2543         (WebCore::HTMLElement::parseMappedAttribute):
2544         * html/HTMLFormControlElement.cpp:
2545         (WebCore::HTMLFormControlElement::onChange):
2546         * html/HTMLFormElement.cpp:
2547         (WebCore::HTMLFormElement::handleLocalEvents):
2548         (WebCore::HTMLFormElement::prepareSubmit):
2549         (WebCore::HTMLFormElement::reset):
2550         (WebCore::HTMLFormElement::parseMappedAttribute):
2551         * html/HTMLFrameElementBase.cpp:
2552         (WebCore::HTMLFrameElementBase::parseMappedAttribute):
2553         * html/HTMLFrameSetElement.cpp:
2554         (WebCore::HTMLFrameSetElement::parseMappedAttribute):
2555         * html/HTMLImageElement.cpp:
2556         (WebCore::HTMLImageElement::parseMappedAttribute):
2557         * html/HTMLImageLoader.cpp:
2558         (WebCore::HTMLImageLoader::dispatchLoadEvent):
2559         * html/HTMLInputElement.cpp:
2560         (WebCore::HTMLInputElement::parseMappedAttribute):
2561         (WebCore::HTMLInputElement::setValueFromRenderer):
2562         (WebCore::HTMLInputElement::preDispatchEventHandler):
2563         (WebCore::HTMLInputElement::postDispatchEventHandler):
2564         (WebCore::HTMLInputElement::defaultEventHandler):
2565         (WebCore::HTMLInputElement::onSearch):
2566         * html/HTMLLabelElement.cpp:
2567         (WebCore::HTMLLabelElement::defaultEventHandler):
2568         * html/HTMLMediaElement.cpp:
2569         (WebCore::HTMLMediaElement::load):
2570         (WebCore::HTMLMediaElement::mediaPlayerNetworkStateChanged):
2571         (WebCore::HTMLMediaElement::setReadyState):
2572         (WebCore::HTMLMediaElement::progressEventTimerFired):
2573         (WebCore::HTMLMediaElement::seek):
2574         (WebCore::HTMLMediaElement::setDefaultPlaybackRate):
2575         (WebCore::HTMLMediaElement::setPlaybackRate):
2576         (WebCore::HTMLMediaElement::play):
2577         (WebCore::HTMLMediaElement::pause):
2578         (WebCore::HTMLMediaElement::setVolume):
2579         (WebCore::HTMLMediaElement::setMuted):
2580         (WebCore::HTMLMediaElement::mediaPlayerTimeChanged):
2581         (WebCore::HTMLMediaElement::documentWillBecomeInactive):
2582         * html/HTMLObjectElement.cpp:
2583         (WebCore::HTMLObjectElement::parseMappedAttribute):
2584         * html/HTMLOptionElement.cpp:
2585         * html/HTMLScriptElement.cpp:
2586         (WebCore::HTMLScriptElement::parseMappedAttribute):
2587         (WebCore::HTMLScriptElement::dispatchLoadEvent):
2588         (WebCore::HTMLScriptElement::dispatchErrorEvent):
2589         * html/HTMLSelectElement.cpp:
2590         (WebCore::HTMLSelectElement::parseMappedAttribute):
2591         (WebCore::HTMLSelectElement::defaultEventHandler):
2592         (WebCore::HTMLSelectElement::menuListDefaultEventHandler):
2593         (WebCore::HTMLSelectElement::listBoxDefaultEventHandler):
2594         * html/HTMLTextAreaElement.cpp:
2595         (WebCore::HTMLTextAreaElement::parseMappedAttribute):
2596         (WebCore::HTMLTextAreaElement::defaultEventHandler):
2597         * html/HTMLTokenizer.cpp:
2598         (WebCore::HTMLTokenizer::notifyFinished):
2599         * loader/FrameLoader.cpp:
2600         (WebCore::FrameLoader::stopLoading):
2601         (WebCore::FrameLoader::canCachePage):
2602         * loader/ImageDocument.cpp:
2603         (WebCore::ImageEventListener::handleEvent):
2604         * loader/ImageLoader.cpp:
2605         * loader/MediaDocument.cpp:
2606         (WebCore::MediaDocument::defaultEventHandler):
2607         * loader/appcache/DOMApplicationCache.cpp:
2608         (WebCore::DOMApplicationCache::callCheckingListener):
2609         (WebCore::DOMApplicationCache::callErrorListener):
2610         (WebCore::DOMApplicationCache::callNoUpdateListener):
2611         (WebCore::DOMApplicationCache::callDownloadingListener):
2612         (WebCore::DOMApplicationCache::callProgressListener):
2613         (WebCore::DOMApplicationCache::callUpdateReadyListener):
2614         (WebCore::DOMApplicationCache::callCachedListener):
2615         * page/AccessibilityObject.cpp:
2616         * page/AccessibilityRenderObject.cpp:
2617         (WebCore::AccessibilityRenderObject::mouseButtonListener):
2618         * page/ContextMenuController.cpp:
2619         (WebCore::ContextMenuController::handleContextMenuEvent):
2620         * page/DOMWindow.cpp:
2621         (WebCore::DOMWindow::on*): (multiple methods)
2622         (WebCore::DOMWindow::setOn*): (multiple methods)
2623         * page/EventHandler.cpp:
2624         (WebCore::EventHandler::handleMousePressEvent):
2625         (WebCore::EventHandler::handleMouseDoubleClickEvent):
2626         (WebCore::EventHandler::handleMouseMoveEvent):
2627         (WebCore::EventHandler::handleMouseReleaseEvent):
2628         (WebCore::EventHandler::updateDragAndDrop):
2629         (WebCore::EventHandler::cancelDragAndDrop):
2630         (WebCore::EventHandler::performDragAndDrop):
2631         (WebCore::EventHandler::updateMouseEventTargetNode):
2632         (WebCore::EventHandler::dispatchMouseEvent):
2633         (WebCore::EventHandler::sendContextMenuEvent):
2634         (WebCore::EventHandler::canMouseDownStartSelect):
2635         (WebCore::EventHandler::canMouseDragExtendSelect):
2636         (WebCore::EventHandler::defaultKeyboardEventHandler):
2637         (WebCore::EventHandler::dragSourceMovedTo):
2638         (WebCore::EventHandler::dragSourceEndedAt):
2639         (WebCore::EventHandler::handleDrag):
2640         (WebCore::EventHandler::handleTextInputEvent):
2641         * page/FocusController.cpp:
2642         * page/Frame.cpp:
2643         (WebCore::Frame::sendResizeEvent):
2644         (WebCore::Frame::sendScrollEvent):
2645         * page/Page.cpp:
2646         (WebCore::networkStateChanged):
2647         * page/animation/AnimationBase.cpp:
2648         (WebCore::AnimationBase::updateStateMachine):
2649         (WebCore::AnimationBase::animationTimerCallbackFired):
2650         (WebCore::AnimationBase::primeEventTimers):
2651         * page/animation/ImplicitAnimation.cpp:
2652         (WebCore::ImplicitAnimation::onAnimationEnd):
2653         (WebCore::ImplicitAnimation::sendTransitionEvent):
2654         * page/animation/KeyframeAnimation.cpp:
2655         (WebCore::KeyframeAnimation::onAnimationStart):
2656         (WebCore::KeyframeAnimation::onAnimationIteration):
2657         (WebCore::KeyframeAnimation::onAnimationEnd):
2658         (WebCore::KeyframeAnimation::sendAnimationEvent):
2659         * page/gtk/EventHandlerGtk.cpp:
2660         * page/mac/EventHandlerMac.mm:
2661         (WebCore::isKeyboardOptionTab):
2662         * page/mac/FrameMac.mm:
2663         * page/qt/EventHandlerQt.cpp:
2664         (WebCore::isKeyboardOptionTab):
2665         * plugins/PluginView.cpp:
2666         * plugins/gtk/PluginViewGtk.cpp:
2667         * plugins/qt/PluginViewQt.cpp:
2668         * plugins/win/PluginViewWin.cpp:
2669         (WebCore::PluginView::handleKeyboardEvent):
2670         (WebCore::PluginView::handleMouseEvent):
2671         * rendering/MediaControlElements.cpp:
2672         (WebCore::MediaControlMuteButtonElement::defaultEventHandler):
2673         (WebCore::MediaControlPlayButtonElement::defaultEventHandler):
2674         (WebCore::MediaControlSeekButtonElement::defaultEventHandler):
2675         (WebCore::MediaControlTimelineElement::defaultEventHandler):
2676         (WebCore::MediaControlFullscreenButtonElement::defaultEventHandler):
2677         * rendering/RenderFrameSet.cpp:
2678         (WebCore::RenderFrameSet::userResize):
2679         * rendering/RenderLayer.cpp:
2680         (WebCore::RenderLayer::scrollToOffset):
2681         * rendering/RenderListBox.cpp:
2682         (WebCore::RenderListBox::valueChanged):
2683         * rendering/RenderMedia.cpp:
2684         (WebCore::RenderMedia::forwardEvent):
2685         * rendering/RenderObject.cpp:
2686         * rendering/RenderSlider.cpp:
2687         (WebCore::HTMLSliderThumbElement::defaultEventHandler):
2688         * rendering/RenderTextControl.cpp:
2689         (WebCore::RenderTextControl::forwardEvent):
2690         (WebCore::RenderTextControl::selectionChanged):
2691         * rendering/RenderWidget.cpp:
2692         * rendering/TextControlInnerElements.cpp:
2693         (WebCore::TextControlInnerTextElement::defaultEventHandler):
2694         (WebCore::SearchFieldResultsButtonElement::defaultEventHandler):
2695         (WebCore::SearchFieldCancelButtonElement::defaultEventHandler):
2696         * storage/LocalStorageArea.cpp:
2697         (WebCore::LocalStorageArea::dispatchStorageEvent):
2698         * storage/SessionStorageArea.cpp:
2699         (WebCore::SessionStorageArea::dispatchStorageEvent):
2700         * svg/SVGAElement.cpp:
2701         (WebCore::SVGAElement::defaultEventHandler):
2702         * svg/SVGDocument.cpp:
2703         (WebCore::SVGDocument::dispatchZoomEvent):
2704         (WebCore::SVGDocument::dispatchScrollEvent):
2705         * svg/SVGElement.cpp:
2706         (WebCore::SVGElement::parseMappedAttribute):
2707         (WebCore::hasLoadListener):
2708         (WebCore::SVGElement::sendSVGLoadEventIfPossible):
2709         * svg/SVGElementInstance.cpp:
2710         (WebCore::SVGElementInstance::on*): (multiple methods)
2711         (WebCore::SVGElementInstance::setOn*): (multiple methods)
2712         * svg/SVGImageLoader.cpp:
2713         (WebCore::SVGImageLoader::dispatchLoadEvent):
2714         * svg/SVGSVGElement.cpp:
2715         (WebCore::SVGSVGElement::parseMappedAttribute):
2716         * svg/SVGScriptElement.cpp:
2717         (WebCore::SVGScriptElement::dispatchErrorEvent):
2718         * xml/XMLHttpRequest.cpp:
2719         (WebCore::XMLHttpRequest::dispatchReadyStateChangeEvent):
2720         (WebCore::XMLHttpRequest::dispatchAbortEvent):
2721         (WebCore::XMLHttpRequest::dispatchErrorEvent):
2722         (WebCore::XMLHttpRequest::dispatchLoadEvent):
2723         (WebCore::XMLHttpRequest::dispatchLoadStartEvent):
2724         (WebCore::XMLHttpRequest::dispatchProgressEvent):
2725         * xml/XMLHttpRequestUpload.cpp:
2726         (WebCore::XMLHttpRequestUpload::dispatchAbortEvent):
2727         (WebCore::XMLHttpRequestUpload::dispatchErrorEvent):
2728         (WebCore::XMLHttpRequestUpload::dispatchLoadEvent):
2729         (WebCore::XMLHttpRequestUpload::dispatchLoadStartEvent):
2730         (WebCore::XMLHttpRequestUpload::dispatchProgressEvent):
2731         * xml/XPathResult.cpp:
2732         (WebCore::XPathResult::XPathResult):
2733         (WebCore::XPathResult::~XPathResult):
2734         (WebCore::XPathResult::invalidateIteratorState):
2735         Access event names via eventNames() function.
2736
2737 2008-11-04  Cameron Zwarich  <zwarich@apple.com>
2738
2739         Reviewed by Mark Rowe.
2740
2741         Delete unused forwarding headers.
2742
2743         * ForwardingHeaders/kjs/Activation.h: Removed.
2744         * ForwardingHeaders/kjs/Register.h: Removed.
2745         * ForwardingHeaders/kjs/RegisterID.h: Removed.
2746
2747 2008-11-04  Cameron Zwarich  <zwarich@apple.com>
2748
2749         Not reviewed.
2750
2751         Fix stupid typo in previous build fix.
2752
2753         * bindings/js/JSStorageCustom.cpp:
2754         * bindings/scripts/CodeGeneratorJS.pm:
2755         * bridge/NP_jsobject.cpp:
2756
2757 2008-11-03  Cameron Zwarich  <zwarich@apple.com>
2758
2759         Not reviewed.
2760
2761         Fix the build for all non-Mac platforms.
2762
2763         * ForwardingHeaders/kjs/PropertyNameArray.h: Removed.
2764         * ForwardingHeaders/runtime/PropertyNameArray.h: Copied from ForwardingHeaders/kjs/PropertyNameArray.h.
2765         * bindings/js/JSStorageCustom.cpp:
2766         * bindings/scripts/CodeGeneratorJS.pm:
2767         * bridge/NP_jsobject.cpp:
2768
2769 2008-11-03  Cameron Zwarich  <zwarich@apple.com>
2770
2771         Not reviewed.
2772
2773         Fix the wxWindows build.
2774
2775         * bridge/c/c_instance.cpp:
2776
2777 2008-11-03  Cameron Zwarich  <zwarich@apple.com>
2778
2779         Rubber-stamped by Maciej Stachowiak.
2780
2781         Move more files into the runtime subdirectory of JavaScriptCore.
2782
2783         * ForwardingHeaders/kjs/ArgList.h: Removed.
2784         * ForwardingHeaders/kjs/CollectorHeapIterator.h: Removed.
2785         * ForwardingHeaders/kjs/ExecState.h: Removed.
2786         * ForwardingHeaders/kjs/InitializeThreading.h: Removed.
2787         * ForwardingHeaders/kjs/JSGlobalData.h: Removed.
2788         * ForwardingHeaders/kjs/JSLock.h: Removed.
2789         * ForwardingHeaders/kjs/SymbolTable.h: Removed.
2790         * ForwardingHeaders/runtime/ArgList.h: Copied from ForwardingHeaders/kjs/ArgList.h.
2791         * ForwardingHeaders/runtime/CollectorHeapIterator.h: Copied from ForwardingHeaders/kjs/CollectorHeapIterator.h.
2792         * ForwardingHeaders/runtime/ExecState.h: Copied from ForwardingHeaders/kjs/ExecState.h.
2793         * ForwardingHeaders/runtime/InitializeThreading.h: Copied from ForwardingHeaders/kjs/InitializeThreading.h.
2794         * ForwardingHeaders/runtime/JSGlobalData.h: Copied from ForwardingHeaders/kjs/JSGlobalData.h.
2795         * ForwardingHeaders/runtime/JSLock.h: Copied from ForwardingHeaders/kjs/JSLock.h.
2796         * ForwardingHeaders/runtime/SymbolTable.h: Copied from ForwardingHeaders/kjs/SymbolTable.h.
2797         * bindings/js/GCController.cpp:
2798         * bindings/js/JSCustomPositionCallback.cpp:
2799         * bindings/js/JSCustomPositionErrorCallback.cpp:
2800         * bindings/js/JSCustomSQLStatementCallback.cpp:
2801         * bindings/js/JSCustomSQLStatementErrorCallback.cpp:
2802         * bindings/js/JSCustomSQLTransactionCallback.cpp:
2803         * bindings/js/JSCustomSQLTransactionErrorCallback.cpp:
2804         * bindings/js/JSCustomVoidCallback.cpp:
2805         * bindings/js/JSCustomXPathNSResolver.cpp:
2806         * bindings/js/JSDOMWindowBase.cpp:
2807         * bindings/js/JSEventCustom.cpp:
2808         * bindings/js/JSEventListener.cpp:
2809         * bindings/js/JSNodeFilterCondition.cpp:
2810         * bindings/js/ScheduledAction.cpp:
2811         * bindings/js/ScriptController.cpp:
2812         * bindings/js/ScriptControllerMac.mm:
2813         * bindings/objc/WebScriptObject.mm:
2814         * bridge/NP_jsobject.cpp:
2815         * bridge/c/c_class.cpp:
2816         * bridge/c/c_instance.cpp:
2817         * bridge/c/c_runtime.cpp:
2818         * bridge/c/c_utility.cpp:
2819         * bridge/jni/jni_class.cpp:
2820         * bridge/jni/jni_instance.cpp:
2821         * bridge/jni/jni_jsobject.mm:
2822         * bridge/jni/jni_objc.mm:
2823         * bridge/jni/jni_runtime.cpp:
2824         * bridge/jni/jni_runtime.h:
2825         * bridge/jni/jni_utility.cpp:
2826         * bridge/npruntime.cpp:
2827         * bridge/objc/objc_instance.mm:
2828         * bridge/objc/objc_runtime.mm:
2829         * bridge/objc/objc_utility.mm:
2830         * bridge/runtime.cpp:
2831         * dom/Document.cpp:
2832         * dom/Node.cpp:
2833         * dom/NodeFilter.cpp:
2834         * dom/NodeIterator.cpp:
2835         * dom/TreeWalker.cpp:
2836         * history/CachedPage.cpp:
2837         * inspector/InspectorController.cpp:
2838         * inspector/JavaScriptCallFrame.cpp:
2839         * inspector/JavaScriptCallFrame.h:
2840         * inspector/JavaScriptDebugServer.cpp:
2841         * inspector/JavaScriptProfileNode.cpp:
2842         * loader/FrameLoader.cpp:
2843         * loader/icon/IconDatabase.cpp:
2844         * page/Console.cpp:
2845         * page/Page.cpp:
2846         * page/mac/FrameMac.mm:
2847         * plugins/PluginView.cpp:
2848         * plugins/gtk/PluginViewGtk.cpp:
2849         * plugins/qt/PluginViewQt.cpp:
2850         * plugins/win/PluginViewWin.cpp:
2851         * storage/Database.cpp:
2852         * xml/XMLHttpRequest.cpp:
2853
2854 2008-11-03  Cameron Zwarich  <zwarich@apple.com>
2855
2856         Reviewed by Sam Weinig.
2857
2858         Remove the forwarding header for FunctionCallProfile, because it was
2859         renamed to ProfileNode in r33466.
2860
2861         * ForwardingHeaders/kjs/FunctionCallProfile.h: Removed.
2862
2863 2008-11-03  Simon Fraser  <simon.fraser@apple.com>
2864
2865         Reviewed by Dave Hyatt
2866
2867         https://bugs.webkit.org/show_bug.cgi?id=22026
2868
2869         When computing the bounds of the transparency layer, we need to
2870         map the clipRect through the enclosing transform.
2871         
2872         Test: fast/layers/opacity-transforms.html
2873
2874         * rendering/RenderLayer.cpp:
2875         (WebCore::transparencyClipBox):
2876
2877 2008-11-03  Kevin Decker  <kdecker@apple.com>
2878
2879         Reviewed by Anders Carlsson.
2880
2881         https://bugs.webkit.org/show_bug.cgi?id=22053
2882
2883         Added additional support needed for the NPDrawingModelCoreAnimation drawing model. 
2884
2885         * bridge/npapi.h:
2886
2887 2008-11-03  Xan Lopez  <xan@gnome.org>
2888
2889         Reviewed by Alp Toker.
2890
2891         Update parseDataUrl() function in the libsoup http backend with
2892         the one from the curl backend which has recent correctness and crash
2893         fixes.
2894
2895         * platform/network/soup/ResourceHandleSoup.cpp:
2896         (WebCore::parseDataUrl):
2897
2898 2008-11-03  Holger Hans Peter Freyther  <zecke@selfish.org>
2899
2900         Reviewed by Alp Toker.
2901
2902         https://bugs.webkit.org/show_bug.cgi?id=22041
2903         Fix CURL crashes on the test suite
2904
2905         Fix segfault with setDefersLoading(). Do not call into curl when we
2906         don't have a CURL handle.
2907
2908         It is attempted to defer the loading before the load has been
2909         started (no curl handle was allocated yet). If that happens then
2910         just remember that. ResourceHandleManager::startJob is already taking
2911         care of this and in initResourceHandle the the downloading will
2912         be paused if needed.
2913
2914         Fixes fast/loader/simultaneous-reloads-assert.html
2915
2916         * platform/network/curl/ResourceHandleCurl.cpp:
2917         (WebCore::ResourceHandle::setDefersLoading):
2918
2919 2008-11-03  Holger Hans Peter Freyther  <zecke@selfish.org>
2920
2921         Reviewed by Alp Toker.
2922
2923         https://bugs.webkit.org/show_bug.cgi?id=22041
2924         Fix CURL crashes on the test suite
2925
2926         Do not send "no data" to WebCore in parseDataUrl().
2927
2928         Fixes assert on fast/tokenizer/image-empty-crash.html
2929
2930         * platform/network/curl/ResourceHandleManager.cpp:
2931         (WebCore::parseDataUrl):
2932
2933 2008-11-02  Xan Lopez  <xan@gnome.org>
2934
2935         Reviewed by Holger Freyther.
2936
2937         https://bugs.webkit.org/show_bug.cgi?id=22009
2938         HTML5 Video with GStreamer pulls gnome-vfs without using it
2939
2940         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
2941         Remove gnome-vfs include.
2942
2943 2008-11-01  Adam Barth  <abarth@webkit.org>
2944
2945         Reviewed by Sam Weinig.
2946
2947         Be sure to check the final URLs of requested resources to make sure we
2948         don't get fooled by HTTP redirects.
2949
2950         https://bugs.webkit.org/show_bug.cgi?id=21963
2951
2952         Tests: http/tests/security/xss-DENIED-xsl-document-redirect.xml
2953                http/tests/security/xss-DENIED-xsl-external-entity-redirect.xml
2954
2955         * dom/XMLTokenizerLibxml2.cpp:
2956         (WebCore::openFunc):
2957         * loader/DocLoader.cpp:
2958         (WebCore::DocLoader::canRequest):
2959         (WebCore::DocLoader::requestResource):
2960         * loader/DocLoader.h:
2961         * xml/XSLTProcessor.cpp:
2962         (WebCore::docLoaderFunc):
2963
2964 2008-11-01  Alexey Proskuryakov  <ap@webkit.org>
2965
2966         Reviewed by Darin Adler.
2967
2968         https://bugs.webkit.org/show_bug.cgi?id=22001
2969         AtomicStringImpl* keys of event listener maps can outlive their strings
2970
2971         Test: fast/events/destroyed-atomic-string.html
2972
2973         * dom/MessagePort.cpp:
2974         (WebCore::MessagePort::addEventListener):
2975         (WebCore::MessagePort::removeEventListener):
2976         (WebCore::MessagePort::dispatchEvent):
2977         * dom/MessagePort.h:
2978         * loader/appcache/DOMApplicationCache.cpp:
2979         (WebCore::DOMApplicationCache::addEventListener):
2980         (WebCore::DOMApplicationCache::removeEventListener):
2981         (WebCore::DOMApplicationCache::dispatchEvent):
2982         * loader/appcache/DOMApplicationCache.h:
2983         * xml/XMLHttpRequest.cpp:
2984         (WebCore::XMLHttpRequest::addEventListener):
2985         (WebCore::XMLHttpRequest::removeEventListener):
2986         (WebCore::XMLHttpRequest::dispatchEvent):
2987         * xml/XMLHttpRequest.h:
2988         * xml/XMLHttpRequestUpload.cpp:
2989         (WebCore::XMLHttpRequestUpload::addEventListener):
2990         (WebCore::XMLHttpRequestUpload::removeEventListener):
2991         (WebCore::XMLHttpRequestUpload::dispatchEvent):
2992         * xml/XMLHttpRequestUpload.h:
2993         Changed EventListenersMap to use AtomicString as key (instead of AtomicStringImpl*).
2994
2995 2008-10-31  Alexey Proskuryakov  <ap@webkit.org>
2996
2997         Reviewed by Darin Adler.
2998
2999         https://bugs.webkit.org/show_bug.cgi?id=21998
3000         Use JSDOMGlobalObject in EventListener-related bindings
3001
3002         * dom/MessagePort.idl: Auto-generate bindings for onclose and onmessage.
3003
3004         * bindings/scripts/CodeGeneratorJS.pm: Use JSDOMGlobalObject instead of JSDOMWindow in JS
3005         bindings for inline event handlers.
3006
3007         * bindings/js/JSDOMApplicationCacheCustom.cpp:
3008         (WebCore::JSDOMApplicationCache::addEventListener):
3009         (WebCore::JSDOMApplicationCache::removeEventListener):
3010         * bindings/js/JSEventTargetNodeCustom.cpp:
3011         (WebCore::JSEventTargetNode::addEventListener):
3012         (WebCore::JSEventTargetNode::removeEventListener):
3013         * bindings/js/JSMessagePortCustom.cpp:
3014         (WebCore::JSMessagePort::removeEventListener):
3015         * bindings/js/JSSVGElementInstanceCustom.cpp:
3016         (WebCore::JSSVGElementInstance::addEventListener):
3017         (WebCore::JSSVGElementInstance::removeEventListener):
3018         * bindings/js/JSXMLHttpRequestCustom.cpp:
3019         (WebCore::JSXMLHttpRequest::addEventListener):
3020         (WebCore::JSXMLHttpRequest::removeEventListener):
3021         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
3022         (WebCore::JSXMLHttpRequestUpload::addEventListener):
3023         (WebCore::JSXMLHttpRequestUpload::removeEventListener):
3024         Use ScriptExecutionContext and JSDOMGlobalObject in bindings.
3025
3026         * dom/EventTarget.h:
3027         * dom/EventTargetNode.cpp:
3028         (WebCore::EventTargetNode::scriptExecutionContext):
3029         * dom/EventTargetNode.h:
3030         * dom/MessagePort.cpp:
3031         * dom/MessagePort.h:
3032         (WebCore::MessagePort::scriptExecutionContext):
3033         * loader/appcache/DOMApplicationCache.cpp:
3034         (WebCore::DOMApplicationCache::scriptExecutionContext):
3035         * loader/appcache/DOMApplicationCache.h:
3036         * svg/SVGElementInstance.cpp:
3037         (WebCore::SVGElementInstance::scriptExecutionContext):
3038         * svg/SVGElementInstance.h:
3039         * xml/XMLHttpRequest.cpp:
3040         (WebCore::XMLHttpRequest::scriptExecutionContext):
3041         * xml/XMLHttpRequest.h:
3042         * xml/XMLHttpRequestUpload.cpp:
3043         (WebCore::XMLHttpRequestUpload::scriptExecutionContext):
3044         * xml/XMLHttpRequestUpload.h:
3045         Remove associatedFrame() method, and provide scriptExecutionContext() where it wasn't
3046         available yet.
3047
3048 2008-10-31  Cameron Zwarich  <zwarich@apple.com>
3049
3050         Rubber-stamped by Geoff Garen.
3051
3052         Rename SourceRange.h to SourceCode.h.
3053
3054         * ForwardingHeaders/kjs/SourceCode.h: Copied from ForwardingHeaders/kjs/SourceRange.h.
3055         * ForwardingHeaders/kjs/SourceRange.h: Removed.
3056         * bindings/js/StringSourceProvider.h:
3057         * bridge/NP_jsobject.cpp:
3058
3059 2008-10-31  Cameron Zwarich  <zwarich@apple.com>
3060
3061         Reviewed by Darin Adler.
3062
3063         Bug 22019: Move JSC::Interpreter::shouldPrintExceptions() to WebCore::Console
3064         <https://bugs.webkit.org/show_bug.cgi?id=22019>
3065
3066         * WebCore.base.exp:
3067         * page/Console.cpp:
3068         (WebCore::printToStandardOut):
3069         (WebCore::Console::shouldPrintExceptions):
3070         (WebCore::Console::setShouldPrintExceptions):
3071         * page/Console.h:
3072
3073 2008-10-31  Dan Bernstein  <mitz@apple.com>
3074
3075         Reviewed by John Sullivan.
3076
3077         - WebCore part of <rdar://problem/6334641> Add WebView SPI for disabling document.cookie
3078
3079         * dom/Document.cpp:
3080         (WebCore::Document::cookie): Added checking if cookies are disabled.
3081         (WebCore::Document::setCookie): Ditto.
3082         * page/Navigator.cpp:
3083         (WebCore::Navigator::cookieEnabled): Ditto.
3084         * page/Page.cpp:
3085         (WebCore::Page::Page): Initialize m_cookieEnabled to true.
3086         * page/Page.h:
3087         (WebCore::Page::cookieEnabled): Added.
3088         (WebCore::Page::setCookieEnabled): Added.
3089
3090 2008-10-31  Adele Peterson  <adele@apple.com>
3091
3092         Reviewed by Darin Adler.
3093
3094         WebCore Windows part of fix for <rdar://problem/5839256> FILE CONTROL: multi-file upload.
3095         https://bugs.webkit.org/show_bug.cgi?id=22008
3096
3097         * platform/FileChooser.cpp: (WebCore::FileChooser::chooseIcon): 
3098         Rename newIconForFile and newIconForFiles to createIconForFile and createIconForFiles.
3099         * platform/graphics/Icon.h: ditto.
3100         * platform/graphics/gtk/IconGtk.cpp:
3101         (WebCore::Icon::createIconForFile): ditto.
3102         (WebCore::Icon::createIconForFiles): ditto.
3103         * platform/graphics/mac/IconMac.mm:
3104         (WebCore::Icon::createIconForFile): ditto.
3105         (WebCore::Icon::createIconForFiles): ditto.
3106         * platform/graphics/qt/IconQt.cpp:
3107         (WebCore::Icon::createIconForFile): ditto.
3108         (WebCore::Icon::createIconForFiles): ditto.
3109         * platform/wx/TemporaryLinkStubs.cpp:
3110         (Icon::createIconForFile): ditto.
3111         (Icon::createIconForFiles): ditto.
3112         * platform/graphics/win/IconWin.cpp:
3113         (WebCore::Icon::createIconForFile): ditto.
3114         (WebCore::Icon::createIconForFiles): Add creation of an icon for multiple files.
3115
3116         * rendering/RenderThemeWin.cpp: (WebCore::RenderThemeWin::paintSearchFieldResultsDecoration):        
3117         Improve icon creation code to match new code in Icon::createIconForFiles
3118         
3119 2008-10-31  Timothy Hatcher  <timothy@apple.com>
3120
3121         Add manual tests that check breakpoints on a blockless body of "for" loops.
3122
3123         https://bugs.webkit.org/show_bug.cgi?id=22004
3124
3125         Reviewed by Darin Adler.
3126
3127         * manual-tests/inspector/debugger-pause-on-for-in-statements.html: Added.
3128         * manual-tests/inspector/debugger-pause-on-for-statements.html: Added.
3129
3130 2008-10-31  Darin Adler  <darin@apple.com>
3131
3132         - fix build
3133
3134         * platform/win/WCDataObject.cpp: Added missing include of "config.h".
3135
3136 2008-10-30  Alexey Proskuryakov  <ap@webkit.org>
3137
3138         Reviewed by Darin Adler.
3139
3140         https://bugs.webkit.org/show_bug.cgi?id=21970
3141         Make MessagePort event dispatch work in workers
3142
3143         * bindings/js/JSDOMGlobalObject.cpp:
3144         (WebCore::JSDOMGlobalObject::JSDOMGlobalObjectData::JSDOMGlobalObjectData):
3145         (WebCore::JSDOMGlobalObject::~JSDOMGlobalObject):
3146         (WebCore::JSDOMGlobalObject::findJSEventListener):
3147         (WebCore::JSDOMGlobalObject::findOrCreateJSEventListener):
3148         (WebCore::JSDOMGlobalObject::findJSUnprotectedEventListener):
3149         (WebCore::JSDOMGlobalObject::findOrCreateJSUnprotectedEventListener):
3150         (WebCore::JSDOMGlobalObject::jsEventListeners):
3151         (WebCore::JSDOMGlobalObject::jsInlineEventListeners):
3152         (WebCore::JSDOMGlobalObject::jsUnprotectedEventListeners):
3153         (WebCore::JSDOMGlobalObject::jsUnprotectedInlineEventListeners):
3154         (WebCore::JSDOMGlobalObject::setCurrentEvent):
3155         (WebCore::JSDOMGlobalObject::currentEvent):
3156         (WebCore::toJSDOMGlobalObject):
3157         * bindings/js/JSDOMGlobalObject.h:
3158         * bindings/js/JSDOMWindowBase.cpp:
3159         (WebCore::JSDOMWindowBase::JSDOMWindowBaseData::JSDOMWindowBaseData):
3160         (WebCore::JSDOMWindowBase::~JSDOMWindowBase):
3161         (WebCore::JSDOMWindowBase::clearHelperObjectProperties):
3162         * bindings/js/JSDOMWindowBase.h:
3163         Moved event listener tracking from JSDOMWindow to JSDOMGlobalObject.
3164
3165         * bindings/js/JSEventListener.cpp:
3166         (WebCore::JSAbstractEventListener::handleEvent):
3167         (WebCore::JSUnprotectedEventListener::JSUnprotectedEventListener):
3168         (WebCore::JSUnprotectedEventListener::~JSUnprotectedEventListener):
3169         (WebCore::JSUnprotectedEventListener::globalObject):
3170         (WebCore::JSUnprotectedEventListener::clearGlobalObject):
3171         (WebCore::JSEventListener::JSEventListener):
3172         (WebCore::JSEventListener::~JSEventListener):
3173         (WebCore::JSEventListener::globalObject):
3174         (WebCore::JSEventListener::clearGlobalObject):
3175         (WebCore::JSLazyEventListener::JSLazyEventListener):
3176         (WebCore::JSLazyEventListener::parseCode):
3177         * bindings/js/JSEventListener.h:
3178         (WebCore::JSUnprotectedEventListener::create):
3179         (WebCore::JSEventListener::create):
3180         (WebCore::JSLazyEventListener::create):
3181         Changed to use JSDOMGlobalObject and ScriptExecutionContext.
3182
3183         * bindings/js/JSMessagePortCustom.cpp:
3184         (WebCore::JSMessagePort::startConversation):
3185         (WebCore::JSMessagePort::addEventListener):
3186         (WebCore::JSMessagePort::removeEventListener):
3187         (WebCore::JSMessagePort::setOnmessage):
3188         (WebCore::JSMessagePort::setOnclose):
3189         Updated bindings to work with JSDOMGlobalObject. Next step is to make code generator emit
3190         such code, and stop using a custom implementation for JSMessagePort inline event handler
3191         getters and setters.
3192
3193         * dom/Document.cpp:
3194         (WebCore::Document::virtualURL):
3195         * dom/Document.h:
3196         * dom/ScriptExecutionContext.h:
3197         Expose url() method on ScriptExecutionContext (necessary for compiling scripts in
3198         JSLazyEventListener).
3199
3200 2008-10-31  Cameron Zwarich  <zwarich@apple.com>
3201
3202         Not reviewed.
3203
3204         Speculative wxWindows build fix.
3205
3206         * webcore-base.bkl:
3207
3208 2008-10-30  Mark Rowe  <mrowe@apple.com>
3209
3210         Reviewed by Jon Homeycutt.
3211
3212         Explicitly default to building for only the native architecture in debug and release builds.
3213
3214         * Configurations/DebugRelease.xcconfig:
3215
3216 2008-10-30  Cameron Zwarich  <zwarich@apple.com>
3217
3218         Rubber-stamped by Sam Weinig.
3219
3220         Create a debugger directory in JavaScriptCore and move the relevant
3221         files to it.
3222
3223         * ForwardingHeaders/debugger: Added.
3224         * ForwardingHeaders/debugger/Debugger.h: Copied from ForwardingHeaders/kjs/debugger.h.
3225         * ForwardingHeaders/debugger/DebuggerCallFrame.h: Copied from ForwardingHeaders/kjs/DebuggerCallFrame.h.
3226         * ForwardingHeaders/kjs/DebuggerCallFrame.h: Removed.
3227         * ForwardingHeaders/kjs/debugger.h: Removed.
3228         * WebCore.pro:
3229         * bindings/js/ScriptController.cpp:
3230         * inspector/JavaScriptCallFrame.cpp:
3231         * inspector/JavaScriptCallFrame.h:
3232         * inspector/JavaScriptDebugServer.cpp:
3233         * inspector/JavaScriptDebugServer.h:
3234
3235 2008-10-30  Tony Chang <tony@chromium.org>
3236
3237         Fix 2 Windows theme bugs:
3238         1) Checkboxes marked readonly were rendered incorrectly
3239         2) If a button has focus and is pressed, it was rendered
3240            as focused rather than pressed.
3241
3242         https://bugs.webkit.org/show_bug.cgi?id=21859
3243
3244         Reviewed by Dave Hyatt.
3245
3246         * rendering/RenderThemeWin.cpp:
3247         (WebCore::RenderThemeWin::determineState):
3248         (WebCore::RenderThemeWin::determineButtonState):
3249
3250 2008-10-30  Benjamin K. Stuhl  <bks24@cornell.edu>
3251
3252         gcc 4.3.3/linux-x86 generates "suggest parentheses around && within ||"
3253         warnings; add some parentheses to disambiguate things. No functional
3254         changes, so no tests.
3255
3256         https://bugs.webkit.org/show_bug.cgi?id=21973
3257         Add parentheses to clean up some gcc warnings
3258
3259         Reviewed by Dan Bernstein.
3260
3261         * platform/graphics/Font.h:
3262         (WebCore::Font::treatAsZeroWidthSpace):
3263
3264 2008-10-30  Aaron Boodman  <aa@chromium.org>
3265
3266         Added an explicit dependency on HashMap.h. It was getting pulled in via
3267         <kjs/identifier.h> in the case of JSC, causing errors for the Chromium port.
3268
3269         Reviewed by Darin Adler.
3270
3271         * platform/text/PlatformString.h:
3272
3273 2008-10-30  Greg Bolsinga  <bolsinga@apple.com>
3274
3275         Reviewed by Sam Weinig
3276
3277         https://bugs.webkit.org/show_bug.cgi?id=21967
3278         
3279         For some platforms the GeolocationService must be suspended and resumed.
3280
3281         * page/Geolocation.cpp:
3282         (WebCore::Geolocation::clearWatch): now uses Geolocation::hasListeners()
3283         (WebCore::Geolocation::suspend): calls GeolocationService::suspend() if there are listeners
3284         (WebCore::Geolocation::resume): calls GeolocationService::resume() if there are listeners
3285         (WebCore::Geolocation::geolocationServicePositionChanged): now uses Geolocation::hasListeners()
3286         * page/Geolocation.h:
3287         (WebCore::Geolocation::hasListeners): Indicates of the Geolocation has interested GeolocationService listeners
3288         * platform/GeolocationService.h:
3289         (WebCore::GeolocationService::suspend): empty implementation
3290         (WebCore::GeolocationService::resume): empty implementation
3291
3292 2008-10-30  Greg Bolsinga  <bolsinga@apple.com>
3293
3294         Reviewed by Sam Weinig
3295
3296         https://bugs.webkit.org/show_bug.cgi?id=21966
3297         
3298         The Geolocation spec was updated on 10/27/2008. This brings WebCore up to date.
3299         http://dev.w3.org/geo/api/spec-source.html
3300
3301         * page/Geolocation.cpp:
3302         (WebCore::Geolocation::GeoNotifier::GeoNotifier): PositionOptions' timeout now unsigned
3303         * page/Geoposition.cpp: velocity is now called speed
3304         (WebCore::Geoposition::toString):
3305         * page/Geoposition.h: velocity is now called speed
3306         (WebCore::Geoposition::create):
3307         (WebCore::Geoposition::speed):
3308         (WebCore::Geoposition::Geoposition):
3309         * page/Geoposition.idl: velocity is now called speed
3310         * page/PositionOptions.h: timeout is now unsigned
3311         (WebCore::PositionOptions::create):
3312         (WebCore::PositionOptions::timeout):
3313         (WebCore::PositionOptions::setTimeout):
3314         (WebCore::PositionOptions::PositionOptions):
3315         * page/PositionOptions.idl: timeout is now unsigned long
3316
3317 2008-10-30  Justin Garcia  <justin.garcia@apple.com>
3318
3319         Also handle preserved newlines.
3320
3321         * editing/BreakBlockquoteCommand.cpp:
3322         (WebCore::BreakBlockquoteCommand::doApply):
3323
3324 2008-10-30  Justin Garcia  <justin.garcia@apple.com>
3325
3326         Reviewed by Beth Dakin.
3327
3328         <rdar://problem/6104369> Hitting return at the end of a quoted line creates an extraneous quoted line
3329
3330         * editing/BreakBlockquoteCommand.cpp:
3331         (WebCore::BreakBlockquoteCommand::doApply): 
3332         Don't store the endingSelection() in selection, just call endingSelection() in the few places it's 
3333         needed.  This function is cheap since it just returns a reference to a Selection instead of creating one.
3334         Don't store an affinity.  In the one place that it was used, isLastVisiblePositionInNode(VisiblePosition(pos, affinity), topBlockquote),
3335         we now use visiblePos (in order to avoid VisiblePosition creation).
3336         Set pos after we delete the current selection (if there is one), and be consistent about what we set 
3337         pos to.  Before, we upstream()ed it if there was a selection to delete and left it alone otherwise.  In fact...
3338         ...we need to use downstream() for pos so that when a caret is at the boundary between two nodes, pos is 
3339         in the first node that we want to move.  This fixes the bug, since it lets code that checks for the case 
3340         where the caret is between text and a br work correctly.
3341
3342 2008-10-30  Yael Aharon  <yael.aharon@nokia.com>
3343
3344         Reviewed by Darin Adler.
3345
3346         Fix the Qt build.
3347
3348         https://bugs.webkit.org/show_bug.cgi?id=21969
3349
3350         * inspector/front-end/WebKit.qrc:
3351         * platform/graphics/qt/ImageBufferQt.cpp:
3352         (WebCore::ImageBufferData::ImageBufferData):
3353         (WebCore::ImageBuffer::ImageBuffer):
3354         (WebCore::ImageBuffer::context):
3355         (WebCore::ImageBuffer::image):
3356         (WebCore::ImageBuffer::toDataURL):
3357
3358 2008-10-30  Justin Garcia  <justin.garcia@apple.com>
3359
3360         Reviewed by Darin Adler.
3361
3362         More preparation for:
3363         <rdar://problem/6104369> Hitting return at the end of a quoted line creates an extraneous quoted line
3364
3365         * editing/BreakBlockquoteCommand.cpp:
3366         (WebCore::BreakBlockquoteCommand::doApply): Added comments.  Don't need to use newStartNode.  If the 
3367         startNode needs to change, change it.  Afterwords, check to make sure that it hasn't left topBlockquote.  
3368         This is slightly stricter than before, where we just made sure that it still had a topBlockquote.  This 
3369         doesn't really fix a bug, since we can't really get into a situation where we move to a different 
3370         topBlockquote, but it simplifies the code.
3371
3372 2008-10-30  Dirk Schulze  <vbs85@gmx.de>
3373
3374         Reviewed by Alp Toker.
3375
3376         https://bugs.webkit.org/show_bug.cgi?id=21883
3377         [CAIRO] globalAlpha has to be stored and restored
3378
3379         Cairo's globalAlpha has to be stored and reloaded on calling
3380         save() and restore(). We use the power of GraphicsContextState for this.
3381
3382         * platform/graphics/GraphicsContextPrivate.h:
3383         (WebCore::GraphicsContextState::GraphicsContextState):
3384         * platform/graphics/cairo/GraphicsContextCairo.cpp:
3385         (WebCore::GraphicsContext::fillPath):
3386         (WebCore::GraphicsContext::strokePath):
3387         (WebCore::GraphicsContext::setAlpha):
3388         (WebCore::GraphicsContext::getAlpha):
3389         * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h:
3390         (WebCore::GraphicsContextPlatformPrivate::GraphicsContextPlatformPrivate):
3391
3392 2008-10-29  Alexey Proskuryakov  <ap@webkit.org>
3393
3394         Reviewed by Maciej Stachowiak.
3395
3396         Rename "attachedToEventTargetNode" to "isInline".
3397
3398         Inline (onXXX) attributes are used not just with event target nodes, but also with Window,
3399         XMLHttpRequest, MessagePort et al.
3400
3401         Also renamed createHTMLEventHandler() (which was a leftover from earlier isHTMLEvent ->
3402         attachedToEventTargetNode rename made for SVG) to createInlineEventListener().
3403         And also renamed EventTargetNode, Document and Window "eventListenerForType" methods to
3404         "inlineEventListenerForType", as they work with inline listeners.
3405
3406         * bindings/js/JSDOMApplicationCacheCustom.cpp:
3407         (WebCore::JSDOMApplicationCache::addEventListener):
3408         (WebCore::JSDOMApplicationCache::removeEventListener):
3409         * bindings/js/JSMessagePortCustom.cpp:
3410         (WebCore::JSMessagePort::setOnmessage):
3411         (WebCore::JSMessagePort::setOnclose):
3412         * bindings/js/JSXMLHttpRequestCustom.cpp:
3413         (WebCore::JSXMLHttpRequest::addEventListener):
3414         (WebCore::JSXMLHttpRequest::removeEventListener):
3415         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
3416         (WebCore::JSXMLHttpRequestUpload::addEventListener):
3417         (WebCore::JSXMLHttpRequestUpload::removeEventListener):
3418         Pass a correct value for this argument - callers used to be confused, because they didn't
3419         consider themselves event target nodes. This doesn't affect behavior however, as the only
3420         difference between inline and non-inline event handlers is that the former treat
3421         "return false" as "event.preventDefault()", which is not important to any of these objects.
3422
3423         * bindings/js/JSEventListener.cpp: (WebCore::JSLazyEventListener::parseCode):
3424         Assert that isInline is true instead of checking its value, as the constructor of this class
3425         always sets it to true.
3426
3427         * bindings/js/JSDOMWindowBase.cpp:
3428         (WebCore::JSDOMWindowBase::~JSDOMWindowBase):
3429         (WebCore::JSDOMWindowBase::findJSEventListener):
3430         (WebCore::JSDOMWindowBase::findOrCreateJSEventListener):
3431         (WebCore::JSDOMWindowBase::findJSUnprotectedEventListener):
3432         (WebCore::JSDOMWindowBase::findOrCreateJSUnprotectedEventListener):
3433         (WebCore::JSDOMWindowBase::jsInlineEventListeners):
3434         (WebCore::JSDOMWindowBase::jsUnprotectedInlineEventListeners):
3435         * bindings/js/JSDOMWindowBase.h:
3436         * bindings/js/JSEventListener.cpp:
3437         (WebCore::JSAbstractEventListener::handleEvent):
3438         (WebCore::JSAbstractEventListener::isInline):
3439         (WebCore::JSUnprotectedEventListener::JSUnprotectedEventListener):
3440         (WebCore::JSUnprotectedEventListener::~JSUnprotectedEventListener):
3441         (WebCore::JSEventListener::JSEventListener):
3442         (WebCore::JSEventListener::~JSEventListener):
3443         (WebCore::JSLazyEventListener::parseCode):
3444         * bindings/js/JSEventListener.h:
3445         (WebCore::JSAbstractEventListener::JSAbstractEventListener):
3446         (WebCore::JSUnprotectedEventListener::create):
3447         (WebCore::JSEventListener::create):
3448         * bindings/js/ScriptController.cpp:
3449         (WebCore::ScriptController::createInlineEventHandler):
3450         * bindings/js/ScriptController.h:
3451         * dom/Document.cpp:
3452         (WebCore::Document::setWindowInlineEventListenerForType):
3453         (WebCore::Document::windowInlineEventListenerForType):
3454         (WebCore::Document::removeWindowInlineEventListenerForType):
3455         (WebCore::Document::createEventListener):
3456         (WebCore::Document::setWindowInlineEventListenerForTypeAndAttribute):
3457         * dom/Document.h:
3458         * dom/EventListener.h:
3459         (WebCore::EventListener::isInline):
3460         * dom/EventTargetNode.cpp:
3461         (WebCore::EventTargetNode::removeInlineEventListenerForType):
3462         (WebCore::EventTargetNode::setInlineEventListenerForType):
3463         (WebCore::EventTargetNode::setInlineEventListenerForTypeAndAttribute):
3464         (WebCore::EventTargetNode::inlineEventListenerForType):
3465         (WebCore::EventTargetNode::on*): (many methods)
3466         (WebCore::EventTargetNode::setOn*): (many methods)
3467         * dom/EventTargetNode.h:
3468         * editing/ReplaceSelectionCommand.cpp:
3469         (WebCore::ReplacementFragment::ReplacementFragment):
3470         * html/HTMLBodyElement.cpp:
3471         (WebCore::HTMLBodyElement::parseMappedAttribute):
3472         * html/HTMLButtonElement.cpp:
3473         (WebCore::HTMLButtonElement::parseMappedAttribute):
3474         * html/HTMLElement.cpp:
3475         (WebCore::HTMLElement::parseMappedAttribute):
3476         * html/HTMLFormElement.cpp:
3477         (WebCore::HTMLFormElement::parseMappedAttribute):
3478         * html/HTMLFrameElementBase.cpp:
3479         (WebCore::HTMLFrameElementBase::parseMappedAttribute):
3480         * html/HTMLFrameSetElement.cpp:
3481         (WebCore::HTMLFrameSetElement::parseMappedAttribute):
3482         * html/HTMLImageElement.cpp:
3483         (WebCore::HTMLImageElement::parseMappedAttribute):
3484         * html/HTMLInputElement.cpp:
3485         (WebCore::HTMLInputElement::parseMappedAttribute):
3486         * html/HTMLObjectElement.cpp:
3487         (WebCore::HTMLObjectElement::parseMappedAttribute):
3488         * html/HTMLScriptElement.cpp:
3489         (WebCore::HTMLScriptElement::parseMappedAttribute):
3490         * html/HTMLSelectElement.cpp:
3491         (WebCore::HTMLSelectElement::parseMappedAttribute):
3492         * html/HTMLTextAreaElement.cpp:
3493         (WebCore::HTMLTextAreaElement::parseMappedAttribute):
3494         * page/AccessibilityRenderObject.cpp:
3495         (WebCore::AccessibilityRenderObject::mouseButtonListener):
3496         * page/DOMWindow.cpp:
3497         (WebCore::DOMWindow::setInlineEventListenerForType):
3498         (WebCore::DOMWindow::inlineEventListenerForType):
3499         (WebCore::DOMWindow::on*): (many methods)
3500         (WebCore::DOMWindow::setOn*): (many methods)
3501         * page/DOMWindow.h:
3502         * svg/SVGElement.cpp:
3503         (WebCore::SVGElement::parseMappedAttribute):
3504         * svg/SVGElementInstance.cpp:
3505         (WebCore::SVGElementInstance::on*): (many methods)
3506         (WebCore::SVGElementInstance::setOn*): (many methods)
3507         * svg/SVGSVGElement.cpp:
3508         (WebCore::SVGSVGElement::parseMappedAttribute):
3509         Rename things, as described above.
3510
3511 2008-10-29  Gustavo Noronha Silva  <gns@gnome.org>
3512
3513         Reviewed and slightly changed by Holger Freyther.
3514
3515         Added all the files that need to be installed for the Inspector to
3516         work.
3517
3518         * GNUmakefile.am: Invoke the shell to get the files.
3519
3520 2008-10-29  Andrew Scherkus  <scherkus@chromium.org>
3521
3522         Reviewed by Darin Adler
3523
3524         Add MediaPlayerPrivateChromium to MediaPlayer
3525         https://bugs.webkit.org/show_bug.cgi?id=21930
3526
3527         * platform/graphics/MediaPlayer.cpp:
3528
3529 2008-10-29  Justin Garcia  <justin.garcia@apple.com>
3530
3531         Reviewed by Darin Adler.
3532
3533         Some preparation for:
3534         <rdar://problem/6104369> Hitting return at the end of a quoted line creates an extraneous quoted line
3535         
3536         Added an early return to avoid a level of if-nesting.  No other changes.  We probably don't
3537         need to rebalance whitespace before the early return but for now don't risk any change in behavior
3538         I'll revisit that later.
3539
3540         * editing/BreakBlockquoteCommand.cpp:
3541         (WebCore::BreakBlockquoteCommand::doApply):
3542
3543 2008-10-29  Kevin Ollivier  <kevino@theolliviers.com>
3544
3545         wx build fixes after addition of runtime and ImageBuffer changes.
3546         
3547         * platform/graphics/wx/ImageBufferData.h: Added.
3548         * platform/graphics/wx/ImageBufferWx.cpp:
3549         (WebCore::ImageBufferData::ImageBufferData):
3550         (WebCore::ImageBuffer::ImageBuffer):
3551         (WebCore::ImageBuffer::context):
3552         * webcore-base.bkl:
3553
3554 2008-10-29  Brett Wilson  <brettw@chromium.org>
3555
3556         Reviewed by Darin Adler
3557         https://bugs.webkit.org/attachment.cgi?id=24745
3558
3559         Allow Skia implementations to get text style changed notifications.
3560
3561         * platform/graphics/GraphicsContext.cpp:
3562
3563 2008-10-29  Timothy Hatcher  <timothy@apple.com>
3564
3565         Add a manual test that checks breakpoints on a blockless body of
3566         an "else" statement.
3567
3568         https://bugs.webkit.org/show_bug.cgi?id=21944
3569
3570         Reviewed by Maciej Stachowiak.
3571
3572         * manual-tests/inspector/debugger-pause-on-else-statements.html: Added.
3573
3574 2008-10-29  Alexey Proskuryakov  <ap@webkit.org>
3575
3576         Reviewed by Darin Adler.
3577
3578         https://bugs.webkit.org/show_bug.cgi?id=21921
3579         MessagePort messages are dispatched to documents that are not fully active
3580
3581         Covered by corrected fast/events/message-port-inactive-document.html
3582
3583         * bindings/js/JSEventListener.cpp:
3584         (WebCore::JSAbstractEventListener::handleEvent): Don't dispatch messages to contexts
3585         that are not fully active.
3586
3587 2008-10-29  Alexey Proskuryakov  <ap@webkit.org>
3588
3589         Reviewed by Sam Weinig.
3590
3591         https://bugs.webkit.org/show_bug.cgi?id=21922
3592         Expose MessagePort global constructor
3593
3594         Covered by existing dumper tests.
3595
3596         * dom/MessagePort.idl:
3597         * page/DOMWindow.idl:
3598
3599 2008-10-29  Alexey Proskuryakov  <ap@webkit.org>
3600
3601         Reviewed by Darin Adler.
3602
3603         https://bugs.webkit.org/show_bug.cgi?id=21924
3604         HashTable internal index is not always deleted
3605
3606         * bindings/js/JSDOMBinding.cpp: (WebCore::DOMObjectHashTableMap::~DOMObjectHashTableMap):
3607         Call deleteTable for HashTables that are being deleted.
3608
3609 2008-10-28  Alexey Proskuryakov  <ap@webkit.org>
3610
3611         Reviewed by Darin Adler.
3612
3613         https://bugs.webkit.org/show_bug.cgi?id=21923
3614         Create an abstraction for script execution context
3615
3616         * GNUmakefile.am:
3617         * WebCore.pro:
3618         * WebCore.vcproj/WebCore.vcproj:
3619         * WebCore.xcodeproj/project.pbxproj:
3620         * WebCoreSources.bkl:
3621         Added ScriptExecutionContext.{h,cpp}.
3622
3623         * bindings/js/JSAudioConstructor.cpp:
3624         (WebCore::JSAudioConstructor::JSAudioConstructor):
3625         * bindings/js/JSAudioConstructor.h:
3626         * bindings/js/JSImageConstructor.cpp:
3627         (WebCore::JSImageConstructor::JSImageConstructor):
3628         * bindings/js/JSImageConstructor.h:
3629         * bindings/js/JSOptionConstructor.cpp:
3630         (WebCore::JSOptionConstructor::JSOptionConstructor):
3631         * bindings/js/JSOptionConstructor.h:
3632         * bindings/js/JSXMLHttpRequestConstructor.cpp:
3633         (WebCore::JSXMLHttpRequestConstructor::JSXMLHttpRequestConstructor):
3634         * bindings/js/JSXMLHttpRequestConstructor.h:
3635         Pass ScriptExecutionContext instead of Document to make getDOMConstructor() happy.
3636         Since these objects can only work within documents now, it is immediately converted back
3637         to Document.
3638
3639         * bindings/js/JSMessageChannelConstructor.cpp:
3640         (WebCore::JSMessageChannelConstructor::JSMessageChannelConstructor):
3641         (WebCore::JSMessageChannelConstructor::construct):
3642         * bindings/js/JSMessageChannelConstructor.h:
3643         (WebCore::JSMessageChannelConstructor::scriptExecutionContext):
3644         MessageChannel needs to be supported in workers right away, so the constructor operates with
3645         it directly.
3646
3647         * dom/ActiveDOMObject.cpp:
3648         (WebCore::ActiveDOMObject::ActiveDOMObject):
3649         (WebCore::ActiveDOMObject::~ActiveDOMObject):
3650         (WebCore::ActiveDOMObject::contextDestroyed):
3651         * dom/ActiveDOMObject.h:
3652         (WebCore::ActiveDOMObject::scriptExecutionContext):
3653         * bindings/js/JSDOMBinding.cpp:
3654         (WebCore::markActiveObjectsForContext):
3655         (WebCore::markCrossHeapDependentObjectsForContext):
3656         Use ScriptExecutionContext instead of Document, now that ActiveDOMObject and MessagePort
3657         tracking is handled by ScriptExecutionContext.
3658
3659         * bindings/js/JSDOMBinding.h: (WebCore::getDOMPrototype): Moved to JSDOMGlobalObject.
3660
3661         * bindings/js/JSDOMGlobalObject.h:
3662         (WebCore::getDOMConstructor): Moved to this file, as constructors live in JSDOMGlobalObject.
3663         Also, the two-argument version that used to be in JSDOMWindowBase.cpp need to be accessible
3664         to worker context implementation.
3665         (WebCore::scriptExecutionContext): Added a pure virtual method to access
3666         ScriptExecutionContext, implemented by subclasses.
3667
3668         * bindings/js/JSDOMWindowBase.h:
3669         * bindings/js/JSDOMWindowBase.cpp: (WebCore::JSDOMWindowBase::scriptExecutionContext):
3670         Implement by returning the associated document. Note that this method currently gives bogus
3671         results after navigation - DOMWindow Frame reference is not zeroed out, so we get a document
3672         that is currently in the frame, not the one associated with this window.
3673
3674         * bindings/js/JSDedicatedWorkerConstructor.cpp: Removed unnecessary include of DOMWindow.h.
3675
3676         * bindings/js/JSDocumentCustom.cpp: (WebCore::JSDocument::mark):
3677         Call markActiveObjectsForContext() by its new name.
3678
3679         * dom/DedicatedWorker.cpp:
3680         (WebCore::DedicatedWorker::DedicatedWorker):
3681         (WebCore::DedicatedWorker::document):
3682         * dom/DedicatedWorker.h:
3683         * xml/XMLHttpRequest.cpp:
3684         (WebCore::XMLHttpRequest::document):
3685         * xml/XMLHttpRequest.h:
3686         Added a document() function that upcasts ScriptExecutionContext, as these objects only work
3687         within documents currently (at least for XMLHttpRequest, this will change soon though).
3688
3689         * dom/Document.cpp:
3690         (WebCore::Document::Document):
3691         (WebCore::Document::~Document):
3692         Moved active object and MessagePort tracking up to ScriptExecutionContext, to share code
3693         with workers.
3694         
3695         * dom/Document.h:
3696         (WebCore::Document::isDocument):
3697         (WebCore::Document::refScriptExecutionContext):
3698         (WebCore::Document::derefScriptExecutionContext):
3699         Inherit from ScriptExecutionContext.
3700
3701         * dom/MessageChannel.cpp:
3702         (WebCore::MessageChannel::MessageChannel):
3703         * dom/MessageChannel.h:
3704         (WebCore::MessageChannel::create):
3705         Use ScriptExecutionContext instead of Document.
3706
3707         * dom/MessagePort.cpp:
3708         (WebCore::CloseMessagePortTimer::CloseMessagePortTimer): Make m_port a RefPtr, because
3709         MessagePort doesn't ref() itself when posting this event any more (this is a fix for an
3710         unrelated issue that was causing random crashes in layout tests).
3711         (WebCore::MessagePort::MessagePort):
3712         (WebCore::MessagePort::~MessagePort):
3713         (WebCore::MessagePort::associatedFrame):
3714         (WebCore::MessagePort::clone):
3715         (WebCore::MessagePort::postMessage):
3716         (WebCore::MessagePort::startConversation):
3717         (WebCore::MessagePort::start):
3718         (WebCore::MessagePort::contextDestroyed):
3719         (WebCore::MessagePort::dispatchMessages):
3720         * dom/MessagePort.h:
3721         (WebCore::MessagePort::create):
3722         (WebCore::MessagePort::scriptExecutionContext):
3723         Use ScriptExecutionContext instead of Document. This is a step toward making MessagePort
3724         work in worker contexts - we need to also make some its method thread safe for cross-thread
3725         messaging, and make event dispatching thread safe.
3726
3727         * dom/ScriptExecutionContext.cpp: Added.
3728         * dom/ScriptExecutionContext.h: Added.
3729         ActiveDOMObject and MessagePort tracking is moved from Document.
3730         It is debatable whether ScriptExecutionContext should be a parent of Document or DOMWindow,
3731         but as I'm just moving Document code, and it is Document that is the main context object
3732         in our implementation currently.
3733         Changing ScriptExecutionContext to be a parent of DOMWindow causes a number of bugs that
3734         seem non-trivial to fix, and isn't really a part of this task.
3735
3736 2008-10-28  Alp Toker  <alp@nuanti.com>
3737
3738         List newly-added ImageBufferData.h in build system.
3739
3740         * GNUmakefile.am:
3741
3742 2008-10-28  Alp Toker  <alp@nuanti.com>
3743
3744         Reviewed by Cameron Zwarich.
3745
3746         De-list unused WebCore ForwardingHeaders to fix the dist target.
3747
3748         * GNUmakefile.am:
3749
3750 2008-10-28  Cameron Zwarich  <zwarich@apple.com>
3751
3752         Not reviewed.
3753
3754         Attempt to fix the Windows build by generating Forwardingheaders for the
3755         runtime directory in JavaScriptCore.
3756
3757         * WebCore.vcproj/WebCore.vcproj:
3758
3759 2008-10-28  Justin Garcia  <justin.garcia@apple.com>
3760
3761         Reviewed by Darin Adler.
3762
3763         <rdar://problem/5188560> REGRESSION: Spell checker doesn't clear spelling/grammar marker after error is marked as Ignored
3764
3765         * editing/Editor.cpp:
3766         (WebCore::Editor::ignoreSpelling): Remove misspelling markers from the word.
3767         (WebCore::Editor::learnSpelling): Added a FIXME about <rdar://problem/5396072>, which 
3768         will probably require a change more complicated than just marking the learned word as 
3769         misspelled.  I'll address it with a separate patch.
3770         * editing/EditorCommand.cpp:
3771         (WebCore::executeIgnoreSpelling): Added.
3772         (WebCore::CommandEntry::): Added an entry for IgnoreSpelling.
3773
3774 2008-10-28  Cameron Zwarich  <zwarich@apple.com>
3775
3776         Reviewed by Mark Rowe.
3777
3778         Move ForwardingHeaders to their correct location after the creation of
3779         the runtime directory in JavaScriptCore.
3780
3781         * ForwardingHeaders/kjs/ArrayPrototype.h: Removed.
3782         * ForwardingHeaders/kjs/BooleanObject.h: Removed.
3783         * ForwardingHeaders/kjs/CallData.h: Removed.
3784         * ForwardingHeaders/kjs/ConstructData.h: Removed.
3785         * ForwardingHeaders/kjs/DateInstance.h: Removed.
3786         * ForwardingHeaders/kjs/Error.h: Removed.
3787         * ForwardingHeaders/kjs/FunctionConstructor.h: Removed.
3788         * ForwardingHeaders/kjs/FunctionPrototype.h: Removed.
3789         * ForwardingHeaders/kjs/InternalFunction.h: Removed.
3790         * ForwardingHeaders/kjs/JSArray.h: Removed.
3791         * ForwardingHeaders/kjs/JSFunction.h: Removed.
3792         * ForwardingHeaders/kjs/JSGlobalObject.h: Removed.
3793         * ForwardingHeaders/kjs/JSNumberCell.h: Removed.
3794         * ForwardingHeaders/kjs/JSObject.h: Removed.
3795         * ForwardingHeaders/kjs/JSString.h: Removed.
3796         * ForwardingHeaders/kjs/JSValue.h: Removed.
3797         * ForwardingHeaders/kjs/ObjectPrototype.h: Removed.
3798         * ForwardingHeaders/kjs/PropertyMap.h: Removed.
3799         * ForwardingHeaders/kjs/PrototypeFunction.h: Removed.
3800         * ForwardingHeaders/kjs/StringObject.h: Removed.
3801         * ForwardingHeaders/kjs/StringObjectThatMasqueradesAsUndefined.h: Removed.
3802         * ForwardingHeaders/kjs/StringPrototype.h: Removed.
3803         * ForwardingHeaders/kjs/StructureID.h: Removed.
3804         * ForwardingHeaders/runtime: Added.
3805         * ForwardingHeaders/runtime/ArrayPrototype.h: Copied from ForwardingHeaders/kjs/ArrayPrototype.h.
3806         * ForwardingHeaders/runtime/BooleanObject.h: Copied from ForwardingHeaders/kjs/BooleanObject.h.
3807         * ForwardingHeaders/runtime/CallData.h: Copied from ForwardingHeaders/kjs/CallData.h.
3808         * ForwardingHeaders/runtime/ConstructData.h: Copied from ForwardingHeaders/kjs/ConstructData.h.
3809         * ForwardingHeaders/runtime/DateInstance.h: Copied from ForwardingHeaders/kjs/DateInstance.h.
3810         * ForwardingHeaders/runtime/Error.h: Copied from ForwardingHeaders/kjs/Error.h.
3811         * ForwardingHeaders/runtime/FunctionConstructor.h: Copied from ForwardingHeaders/kjs/FunctionConstructor.h.
3812         * ForwardingHeaders/runtime/FunctionPrototype.h: Copied from ForwardingHeaders/kjs/FunctionPrototype.h.
3813         * ForwardingHeaders/runtime/InternalFunction.h: Copied from ForwardingHeaders/kjs/InternalFunction.h.
3814         * ForwardingHeaders/runtime/JSArray.h: Copied from ForwardingHeaders/kjs/JSArray.h.
3815         * ForwardingHeaders/runtime/JSFunction.h: Copied from ForwardingHeaders/kjs/JSFunction.h.
3816         * ForwardingHeaders/runtime/JSGlobalObject.h: Copied from ForwardingHeaders/kjs/JSGlobalObject.h.
3817         * ForwardingHeaders/runtime/JSNumberCell.h: Copied from ForwardingHeaders/kjs/JSNumberCell.h.
3818         * ForwardingHeaders/runtime/JSObject.h: Copied from ForwardingHeaders/kjs/JSObject.h.
3819         * ForwardingHeaders/runtime/JSString.h: Copied from ForwardingHeaders/kjs/JSString.h.
3820         * ForwardingHeaders/runtime/JSValue.h: Copied from ForwardingHeaders/kjs/JSValue.h.
3821         * ForwardingHeaders/runtime/ObjectPrototype.h: Copied from ForwardingHeaders/kjs/ObjectPrototype.h.
3822         * ForwardingHeaders/runtime/PropertyMap.h: Copied from ForwardingHeaders/kjs/PropertyMap.h.
3823         * ForwardingHeaders/runtime/PrototypeFunction.h: Copied from ForwardingHeaders/kjs/PrototypeFunction.h.
3824         * ForwardingHeaders/runtime/StringObject.h: Copied from ForwardingHeaders/kjs/StringObject.h.
3825         * ForwardingHeaders/runtime/StringObjectThatMasqueradesAsUndefined.h: Copied from ForwardingHeaders/kjs/StringObjectThatMasqueradesAsUndefined.h.
3826         * ForwardingHeaders/runtime/StringPrototype.h: Copied from ForwardingHeaders/kjs/StringPrototype.h.
3827         * ForwardingHeaders/runtime/StructureID.h: Copied from ForwardingHeaders/kjs/StructureID.h.
3828         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
3829         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
3830         * bindings/js/JSClipboardCustom.cpp:
3831         * bindings/js/JSConsoleCustom.cpp:
3832         * bindings/js/JSCustomPositionCallback.h:
3833         * bindings/js/JSCustomPositionErrorCallback.h:
3834         * bindings/js/JSCustomSQLStatementCallback.h:
3835         * bindings/js/JSCustomSQLStatementErrorCallback.h:
3836         * bindings/js/JSCustomSQLTransactionErrorCallback.h:
3837         * bindings/js/JSCustomVoidCallback.h:
3838         * bindings/js/JSCustomXPathNSResolver.h:
3839         * bindings/js/JSDOMBinding.cpp:
3840         * bindings/js/JSDOMBinding.h:
3841         * bindings/js/JSDOMGlobalObject.h:
3842         * bindings/js/JSDOMWindowBase.cpp:
3843         * bindings/js/JSDOMWindowCustom.cpp:
3844         * bindings/js/JSDOMWindowShell.cpp:
3845         * bindings/js/JSDatabaseCustom.cpp:
3846         * bindings/js/JSEventListener.cpp:
3847         * bindings/js/JSEventTarget.h:
3848         * bindings/js/JSHTMLDocumentCustom.cpp:
3849         * bindings/js/JSHistoryCustom.cpp:
3850         * bindings/js/JSInspectedObjectWrapper.cpp:
3851         * bindings/js/JSJavaScriptCallFrameCustom.cpp:
3852         * bindings/js/JSLocationCustom.cpp:
3853         * bindings/js/JSNodeFilterCondition.h:
3854         * bindings/js/JSQuarantinedObjectWrapper.cpp:
3855         * bindings/js/JSQuarantinedObjectWrapper.h:
3856         * bindings/js/JSXMLHttpRequestCustom.cpp:
3857         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
3858         * bindings/objc/WebScriptObject.mm:
3859         * bindings/objc/WebScriptObjectPrivate.h:
3860         * bindings/scripts/CodeGeneratorJS.pm:
3861         * bridge/NP_jsobject.cpp:
3862         * bridge/c/c_instance.cpp:
3863         * bridge/c/c_utility.cpp:
3864         * bridge/c/c_utility.h:
3865         * bridge/jni/jni_instance.cpp:
3866         * bridge/jni/jni_jsobject.h:
3867         * bridge/jni/jni_jsobject.mm:
3868         * bridge/jni/jni_runtime.cpp:
3869         * bridge/jni/jni_utility.cpp:
3870         * bridge/jni/jni_utility.h:
3871         * bridge/objc/objc_instance.mm:
3872         * bridge/objc/objc_runtime.h:
3873         * bridge/objc/objc_runtime.mm:
3874         * bridge/objc/objc_utility.h:
3875         * bridge/objc/objc_utility.mm:
3876         * bridge/runtime.h:
3877         * bridge/runtime_array.cpp:
3878         * bridge/runtime_array.h:
3879         * bridge/runtime_method.cpp:
3880         * bridge/runtime_method.h:
3881         * bridge/runtime_object.cpp:
3882         * bridge/runtime_object.h:
3883         * bridge/runtime_root.cpp:
3884         * inspector/JavaScriptCallFrame.cpp:
3885         * inspector/JavaScriptProfile.cpp:
3886         * inspector/JavaScriptProfile.h:
3887         * inspector/JavaScriptProfileNode.cpp:
3888         * inspector/JavaScriptProfileNode.h:
3889         * loader/FrameLoader.cpp:
3890         * page/Console.cpp:
3891         * plugins/PluginView.cpp:
3892         * plugins/gtk/PluginViewGtk.cpp:
3893         * plugins/qt/PluginViewQt.cpp:
3894         * plugins/win/PluginViewWin.cpp:
3895
3896 2008-10-28  Adele Peterson  <adele@apple.com>
3897
3898         Windows build fix.  This removes Cairo include directories from non-Cairbo build configurations.
3899
3900         * WebCore.vcproj/WebCore.vcproj:
3901
3902 2008-10-28  Adele Peterson  <adele@apple.com>
3903
3904         Windows build fix.
3905
3906         * platform/graphics/ImageBuffer.h:
3907         (WebCore::ImageBuffer::create):
3908
3909 2008-10-28  Cameron Zwarich  <zwarich@apple.com>
3910
3911         Not reviewed.
3912
3913         Roll out a mistaken attempt at fixing the GTK build in r37947.
3914
3915         * GNUmakefile.am:
3916
3917 2008-10-28  Adele Peterson  <adele@apple.com>
3918
3919         Reviewed by John Sullivan.
3920
3921         Fix for https://bugs.webkit.org/show_bug.cgi?id=21880
3922         "files" string for multifile uploads needs to be localized
3923
3924         * page/mac/WebCoreViewFactory.h:
3925         * platform/LocalizedStrings.h:
3926         * platform/gtk/FileChooserGtk.cpp: (WebCore::FileChooser::basenameForWidth):
3927         * platform/gtk/LocalizedStringsGtk.cpp: (WebCore::multipleFileUploadText):
3928         * platform/mac/FileChooserMac.mm: (WebCore::FileChooser::basenameForWidth):
3929         * platform/mac/LocalizedStringsMac.mm: (WebCore::multipleFileUploadText):
3930         * platform/qt/Localizations.cpp: (WebCore::multipleFileUploadText):
3931         * platform/wx/LocalizedStringsWx.cpp: (WebCore::multipleFileUploadText):
3932
3933 2008-10-28  Brett Wilson  <brettw@chromium.org>
3934
3935         Reviewed by Darin Adler.
3936
3937         https://bugs.webkit.org/show_bug.cgi?id=21816
3938
3939         Remove platform ifdefs in ImageBuffer.h by moving platform specific code
3940         into a new PlatformImageBuffer class. Move the static create function
3941         into the header because it can be cross-platform. Initialization now
3942         happens in the cunstructor which sets a flag that create uses to know
3943         whether it should return null or not. I also made passing of IntSize
3944         more consistent (always by reference).
3945
3946         This change also changes the ifdefs in GraphicsContext to allow Skia
3947         ports to implement text drawing modes.
3948
3949         * platform/graphics/ImageBuffer.h:
3950         (WebCore::ImageBuffer::create):
3951         (WebCore::ImageBuffer::size):
3952         * platform/graphics/cairo/ImageBufferCairo.cpp:
3953         (WebCore::ImageBufferData::ImageBufferData):
3954         (WebCore::ImageBuffer::ImageBuffer):
3955         (WebCore::ImageBuffer::~ImageBuffer):
3956         (WebCore::ImageBuffer::image):
3957         (WebCore::ImageBuffer::getImageData):
3958         (WebCore::ImageBuffer::putImageData):
3959         * platform/graphics/cairo/ImageBufferData.h:
3960         * platform/graphics/cg/ImageBufferCG.cpp:
3961         (WebCore::ImageBufferData::ImageBufferData):
3962         (WebCore::ImageBuffer::ImageBuffer):
3963         (WebCore::ImageBuffer::~ImageBuffer):
3964         (WebCore::ImageBuffer::getImageData):
3965         (WebCore::ImageBuffer::putImageData):
3966         * platform/graphics/cg/ImageBufferData.h:
3967         * platform/graphics/qt/ImageBufferData.h:
3968         * platform/graphics/qt/ImageBufferQt.cpp:
3969         (WebCore::ImageBufferData::ImageBufferData):
3970         (WebCore::ImageBuffer::ImageBuffer):
3971         (WebCore::ImageBuffer::~ImageBuffer):
3972
3973 2008-10-28  Cameron Zwarich  <zwarich@apple.com>
3974
3975         Not reviewed.
3976
3977         Fix the GTK build.
3978
3979         * GNUmakefile.am:
3980
3981 2008-10-28  Cameron Zwarich  <zwarich@apple.com>
3982
3983         Not reviewed.
3984
3985         Another Qt build fix.
3986
3987         * WebCore.pro:
3988
3989 2008-10-28  Greg Bolsinga  <bolsinga@apple.com>
3990
3991         Reviewed by David Kilzer.
3992
3993         https://bugs.webkit.org/show_bug.cgi?id=21932
3994         Add non-pointer constant lookups to SoftLinking.h
3995
3996         * platform/mac/SoftLinking.h:
3997
3998 2008-10-28  Greg Bolsinga  <bolsinga@apple.com>
3999
4000         Reviewed by David Kilzer.
4001
4002         https://bugs.webkit.org/show_bug.cgi?id=2192
4003         Missing semi-colons in Geoposition.idl
4004
4005         * page/Geoposition.idl: Add missing semi-colons
4006
4007 2008-10-28  Timothy Hatcher  <timothy@apple.com>
4008
4009         Make the Profiles panel in the Web Inspector have an enable screen.
4010         Profiling now needs to be enabled before console.profile() works.
4011
4012         <rdar://problem/6211578> Make the JavaScript profiler opt-in, so it does
4013         not slow down JavaScript all the time
4014
4015         Reviewed by Darin Adler and Kevin McCullough.
4016
4017         * English.lproj/localizedStrings.js: New strings.
4018         * WebCore.base.exp: New and changed exports.
4019         * WebCore.vcproj/WebCore.vcproj: Add the PanelEnablerView.js file.
4020         * bindings/js/JSDOMWindowBase.cpp:
4021         (WebCore::JSDOMWindowBase::supportsProfiling): Call InspectorController:profilerEnabled.
4022         * inspector/InspectorController.cpp:
4023         (WebCore::InspectorController::InspectorController): Initialize the m_startProfiling
4024         Timer to call InspectorController::startUserInitiatedProfiling.
4025         (WebCore::InspectorController::startUserInitiatedProfilingSoon): Start a one-shot timer
4026         that calls InspectorController::startUserInitiatedProfiling.
4027         (WebCore::InspectorController::startUserInitiatedProfiling): Recompile all JavaScript
4028         and enable the profiler if the profiler was not enabled.
4029         (WebCore::InspectorController::stopUserInitiatedProfiling): Rearrange code for readability.
4030         (WebCore::InspectorController::enableProfiler): Recompile all the JavaScript functions
4031         if the skipRecompile argument is false. Call the profilerWasEnabled script function.
4032         (WebCore::InspectorController::disableProfiler): Recompile all the JavaScript functions.
4033         Call the profilerWasEnabled script function.
4034         (WebCore::InspectorController::disableDebugger): Set m_attachDebuggerWhenShown to false,
4035         so it won't be started later.
4036         * inspector/InspectorController.h:
4037         (WebCore::InspectorController::profilerEnabled): Return enabled() && m_profilerEnabled.
4038         * inspector/front-end/Images/debuggingButtons.png: Remove.
4039         * inspector/front-end/Images/enableButtons.png: Added.
4040         * inspector/front-end/Images/profilesSilhouette.png: Added.
4041         * inspector/front-end/Images/scriptsSilhouette.png: Added.
4042         * inspector/front-end/PanelEnablerView.js: Added.
4043         (WebInspector.PanelEnablerView):
4044         (WebInspector.PanelEnablerView.prototype._enableButtonCicked): Fire the "enable clicked"
4045         event so listeners can do their thing.
4046         (WebInspector.PanelEnablerView.prototype._windowResized): Test if the icon should be hidden.
4047         * inspector/front-end/ProfilesPanel.js:
4048         (WebInspector.ProfilesPanel): Create the PanelEnablerView and the strings needed for it.
4049         (WebInspector.ProfilesPanel.prototype.get statusBarItems): Include the enableToggleButton.
4050         (WebInspector.ProfilesPanel.prototype.profilerWasEnabled): Call reset and populateInterface.
4051         (WebInspector.ProfilesPanel.prototype.profilerWasDisabled): Call reset.
4052         (WebInspector.ProfilesPanel.prototype.reset): Call _updateInterface.
4053         (WebInspector.ProfilesPanel.prototype.setRecordingProfile): Moved in the code, no changes.
4054         (WebInspector.ProfilesPanel.prototype._updateInterface): Update the toggle button and
4055         show/hide other buttons. Also show/hide the PanelEnablerView.
4056         (WebInspector.ProfilesPanel.prototype._enableProfiling): Call _toggleProfiling if not enabled.
4057         (WebInspector.ProfilesPanel.prototype._toggleProfiling): Call InspectorController's
4058         disableProfiler or enableProfiler.
4059         * inspector/front-end/ScriptsPanel.js:
4060         (WebInspector.ScriptsPanel): Replace the overlay element with a PanelEnablerView. Replace the
4061         debuggingButton with the enableToggleButton.
4062         (WebInspector.ScriptsPanel.prototype.get statusBarItems): Replace the debuggingButton with
4063         the enableToggleButton.
4064         (WebInspector.ScriptsPanel.prototype._updateDebuggerButtons): Hide/show the pauseOnExceptionButton
4065         when needed. Replace the overlay element with a PanelEnablerView. Replace the debuggingButton
4066         with the enableToggleButton.
4067         (WebInspector.ScriptsPanel.prototype._enableDebugging): Call _toggleDebugging when not enabled.
4068         (WebInspector.ScriptsPanel.prototype._toggleDebugging): Remove the call to _clearInterface,
4069         since reset is called from debuggerWasEnabled and debuggerWasDisabled.
4070         * inspector/front-end/View.js: Inherit from WebInspector.Object.
4071         * inspector/front-end/WebKit.qrc: Add the PanelEnablerView.js file.
4072         * inspector/front-end/inspector.css: New styles for the PanelEnablerView.
4073         * inspector/front-end/inspector.html: Add the PanelEnablerView.js file.
4074         * inspector/front-end/inspector.js:
4075         (WebInspector.profilerWasEnabled): Added. Calls the ProfilesPanel.
4076         (WebInspector.profilerWasDisabled): Ditto.
4077         * page/Console.cpp:
4078         (WebCore::Console::error): Remove null check for m_frame, since m_frame isn't used.
4079         (WebCore::Console::info): Ditto.
4080         (WebCore::Console::log): Ditto.
4081         (WebCore::Console::assertCondition): Ditto.
4082         (WebCore::Console::dirxml): Remove null check for m_frame and use this->page().
4083         (WebCore::Console::count): Ditto.
4084         (WebCore::Console::profile): Return early if InspectorController::profilerEnabled is false.
4085         (WebCore::Console::profileEnd): Ditto.
4086         (WebCore::Console::warn): Remove null check for m_frame, since m_frame isn't used.
4087         * page/Settings.cpp:
4088         (WebCore::Settings::Settings): Remove initialization of m_didInitializeDeveloperExtrasEnabled.
4089         (WebCore::Settings::setDeveloperExtrasEnabled): Remove code that recompiled functions.
4090         Now just sets the member boolean.
4091         * page/Settings.h: Remove m_didInitializeDeveloperExtrasEnabled.
4092
4093 2008-10-28  Timothy Hatcher  <timothy@apple.com>
4094
4095         Rename a few methods related to attaching and detaching the debugger. Also
4096         adds stub methods for enabling and disabling the profiler.
4097
4098         * Rename attachDebugger to enableDebugger.
4099         * Rename detachDebugger to disableDebugger.
4100         * Rename the debuggerAttached getter to debuggerEnabled.
4101         * Rename the debuggerAttached callback to debuggerWasEnabled.
4102         * Rename the debuggerDetached callback to debuggerWasDisabled.
4103
4104         Reviewed by Darin Adler.
4105
4106         * WebCore.base.exp:
4107         * inspector/InspectorController.cpp:
4108         (WebCore::InspectorController::InspectorController):
4109         (WebCore::InspectorController::setWindowVisible):
4110         (WebCore::InspectorController::windowScriptObjectAvailable):
4111         (WebCore::InspectorController::close):
4112         (WebCore::InspectorController::enableProfiler):
4113         (WebCore::InspectorController::disableProfiler):
4114         (WebCore::InspectorController::enableDebugger):
4115         (WebCore::InspectorController::disableDebugger):
4116         (WebCore::InspectorController::pauseInDebugger):
4117         (WebCore::InspectorController::resumeDebugger):
4118         (WebCore::InspectorController::stepOverStatementInDebugger):
4119         (WebCore::InspectorController::stepIntoStatementInDebugger):
4120         (WebCore::InspectorController::stepOutOfFunctionInDebugger):
4121         * inspector/InspectorController.h:
4122         (WebCore::InspectorController::profilerEnabled):
4123         (WebCore::InspectorController::debuggerEnabled):
4124         * inspector/front-end/BreakpointsSidebarPane.js:
4125         (WebInspector.BreakpointsSidebarPane.prototype.addBreakpoint):
4126         (WebInspector.BreakpointsSidebarPane.prototype.removeBreakpoint):
4127         (WebInspector.BreakpointsSidebarPane.prototype._breakpointEnableChanged):
4128         * inspector/front-end/Object.js:
4129         * inspector/front-end/ProfilesPanel.js:
4130         (WebInspector.ProfilesPanel):
4131         * inspector/front-end/ScriptsPanel.js:
4132         (WebInspector.ScriptsPanel):
4133         (WebInspector.ScriptsPanel.prototype.get statusBarItems):
4134         (WebInspector.ScriptsPanel.prototype.debuggerWasEnabled):
4135         (WebInspector.ScriptsPanel.prototype.debuggerWasDetached):
4136         (WebInspector.ScriptsPanel.prototype.reset):
4137         (WebInspector.ScriptsPanel.prototype.canShowResource):
4138         (WebInspector.ScriptsPanel.prototype._updatePauseOnExceptionsButton):
4139         (WebInspector.ScriptsPanel.prototype._updateDebuggerButtons):
4140         (WebInspector.ScriptsPanel.prototype._toggleDebugging):
4141         * inspector/front-end/View.js:
4142         * inspector/front-end/inspector.css:
4143         * inspector/front-end/inspector.html:
4144         * inspector/front-end/inspector.js:
4145         (WebInspector.addResource):
4146         (WebInspector.debuggerWasEnabled):
4147         (WebInspector.debuggerWasDisabled):
4148
4149 2008-10-28  Timothy Hatcher  <timothy@apple.com>
4150
4151         Fix an exception when searching the Resources panel while there
4152         and resources queued to be added to the list.
4153
4154         Reviewed by Kevin McCullough.
4155
4156         * inspector/front-end/ResourcesPanel.js:
4157         (WebInspector.ResourcesPanel.prototype.searchCanceled): Null check
4158         the _resourcesTreeElement property.
4159         (WebInspector.ResourcesPanel.prototype.performSearch): Ditto.
4160
4161 2008-10-28  Alp Toker  <alp@nuanti.com>
4162
4163         GTK+ build fix for older versions of Pango where PANGO_VERSION_CHECK
4164         isn't defined.
4165
4166         * platform/graphics/gtk/FontGtk.cpp:
4167         (WebCore::getDefaultPangoLayout):
4168         * platform/graphics/gtk/FontPlatformDataPango.cpp:
4169
4170 2008-10-28  Alexey Proskuryakov  <ap@webkit.org>
4171
4172         Reviewed by Darin Adler.
4173
4174         https://bugs.webkit.org/show_bug.cgi?id=21893
4175         Character set is incorrect for external scripts in XHTML pages
4176
4177         <rdar://problem/6317451> Incorrect encoding for text in a popup at http://xpoint.ru/
4178
4179         Test: fast/encoding/external-script-charset.xhtml
4180
4181         Expose scriptCharset() function on all ScriptElements, and call it from XML tokenizer.
4182
4183         * dom/ScriptElement.h:
4184         * dom/XMLTokenizerLibxml2.cpp:
4185         (WebCore::