Emit the WillExecuteStatement debugger hook before the for loop body when the stateme...
[WebKit-https.git] / WebCore / ChangeLog
1 2008-10-31  Timothy Hatcher  <timothy@apple.com>
2
3         Add manual tests that check breakpoints on a blockless body of "for" loops.
4
5         https://bugs.webkit.org/show_bug.cgi?id=22004
6
7         Reviewed by Darin Adler.
8
9         * manual-tests/inspector/debugger-pause-on-for-in-statements.html: Added.
10         * manual-tests/inspector/debugger-pause-on-for-statements.html: Added.
11
12 2008-10-31  Darin Adler  <darin@apple.com>
13
14         - fix build
15
16         * platform/win/WCDataObject.cpp: Added missing include of "config.h".
17
18 2008-10-30  Alexey Proskuryakov  <ap@webkit.org>
19
20         Reviewed by Darin Adler.
21
22         https://bugs.webkit.org/show_bug.cgi?id=21970
23         Make MessagePort event dispatch work in workers
24
25         * bindings/js/JSDOMGlobalObject.cpp:
26         (WebCore::JSDOMGlobalObject::JSDOMGlobalObjectData::JSDOMGlobalObjectData):
27         (WebCore::JSDOMGlobalObject::~JSDOMGlobalObject):
28         (WebCore::JSDOMGlobalObject::findJSEventListener):
29         (WebCore::JSDOMGlobalObject::findOrCreateJSEventListener):
30         (WebCore::JSDOMGlobalObject::findJSUnprotectedEventListener):
31         (WebCore::JSDOMGlobalObject::findOrCreateJSUnprotectedEventListener):
32         (WebCore::JSDOMGlobalObject::jsEventListeners):
33         (WebCore::JSDOMGlobalObject::jsInlineEventListeners):
34         (WebCore::JSDOMGlobalObject::jsUnprotectedEventListeners):
35         (WebCore::JSDOMGlobalObject::jsUnprotectedInlineEventListeners):
36         (WebCore::JSDOMGlobalObject::setCurrentEvent):
37         (WebCore::JSDOMGlobalObject::currentEvent):
38         (WebCore::toJSDOMGlobalObject):
39         * bindings/js/JSDOMGlobalObject.h:
40         * bindings/js/JSDOMWindowBase.cpp:
41         (WebCore::JSDOMWindowBase::JSDOMWindowBaseData::JSDOMWindowBaseData):
42         (WebCore::JSDOMWindowBase::~JSDOMWindowBase):
43         (WebCore::JSDOMWindowBase::clearHelperObjectProperties):
44         * bindings/js/JSDOMWindowBase.h:
45         Moved event listener tracking from JSDOMWindow to JSDOMGlobalObject.
46
47         * bindings/js/JSEventListener.cpp:
48         (WebCore::JSAbstractEventListener::handleEvent):
49         (WebCore::JSUnprotectedEventListener::JSUnprotectedEventListener):
50         (WebCore::JSUnprotectedEventListener::~JSUnprotectedEventListener):
51         (WebCore::JSUnprotectedEventListener::globalObject):
52         (WebCore::JSUnprotectedEventListener::clearGlobalObject):
53         (WebCore::JSEventListener::JSEventListener):
54         (WebCore::JSEventListener::~JSEventListener):
55         (WebCore::JSEventListener::globalObject):
56         (WebCore::JSEventListener::clearGlobalObject):
57         (WebCore::JSLazyEventListener::JSLazyEventListener):
58         (WebCore::JSLazyEventListener::parseCode):
59         * bindings/js/JSEventListener.h:
60         (WebCore::JSUnprotectedEventListener::create):
61         (WebCore::JSEventListener::create):
62         (WebCore::JSLazyEventListener::create):
63         Changed to use JSDOMGlobalObject and ScriptExecutionContext.
64
65         * bindings/js/JSMessagePortCustom.cpp:
66         (WebCore::JSMessagePort::startConversation):
67         (WebCore::JSMessagePort::addEventListener):
68         (WebCore::JSMessagePort::removeEventListener):
69         (WebCore::JSMessagePort::setOnmessage):
70         (WebCore::JSMessagePort::setOnclose):
71         Updated bindings to work with JSDOMGlobalObject. Next step is to make code generator emit
72         such code, and stop using a custom implementation for JSMessagePort inline event handler
73         getters and setters.
74
75         * dom/Document.cpp:
76         (WebCore::Document::virtualURL):
77         * dom/Document.h:
78         * dom/ScriptExecutionContext.h:
79         Expose url() method on ScriptExecutionContext (necessary for compiling scripts in
80         JSLazyEventListener).
81
82 2008-10-31  Cameron Zwarich  <zwarich@apple.com>
83
84         Not reviewed.
85
86         Speculative wxWindows build fix.
87
88         * webcore-base.bkl:
89
90 2008-10-30  Mark Rowe  <mrowe@apple.com>
91
92         Reviewed by Jon Homeycutt.
93
94         Explicitly default to building for only the native architecture in debug and release builds.
95
96         * Configurations/DebugRelease.xcconfig:
97
98 2008-10-30  Cameron Zwarich  <zwarich@apple.com>
99
100         Rubber-stamped by Sam Weinig.
101
102         Create a debugger directory in JavaScriptCore and move the relevant
103         files to it.
104
105         * ForwardingHeaders/debugger: Added.
106         * ForwardingHeaders/debugger/Debugger.h: Copied from ForwardingHeaders/kjs/debugger.h.
107         * ForwardingHeaders/debugger/DebuggerCallFrame.h: Copied from ForwardingHeaders/kjs/DebuggerCallFrame.h.
108         * ForwardingHeaders/kjs/DebuggerCallFrame.h: Removed.
109         * ForwardingHeaders/kjs/debugger.h: Removed.
110         * WebCore.pro:
111         * bindings/js/ScriptController.cpp:
112         * inspector/JavaScriptCallFrame.cpp:
113         * inspector/JavaScriptCallFrame.h:
114         * inspector/JavaScriptDebugServer.cpp:
115         * inspector/JavaScriptDebugServer.h:
116
117 2008-10-30  Tony Chang <tony@chromium.org>
118
119         Fix 2 Windows theme bugs:
120         1) Checkboxes marked readonly were rendered incorrectly
121         2) If a button has focus and is pressed, it was rendered
122            as focused rather than pressed.
123
124         https://bugs.webkit.org/show_bug.cgi?id=21859
125
126         Reviewed by Dave Hyatt.
127
128         * rendering/RenderThemeWin.cpp:
129         (WebCore::RenderThemeWin::determineState):
130         (WebCore::RenderThemeWin::determineButtonState):
131
132 2008-10-30  Benjamin K. Stuhl  <bks24@cornell.edu>
133
134         gcc 4.3.3/linux-x86 generates "suggest parentheses around && within ||"
135         warnings; add some parentheses to disambiguate things. No functional
136         changes, so no tests.
137
138         https://bugs.webkit.org/show_bug.cgi?id=21973
139         Add parentheses to clean up some gcc warnings
140
141         Reviewed by Dan Bernstein.
142
143         * platform/graphics/Font.h:
144         (WebCore::Font::treatAsZeroWidthSpace):
145
146 2008-10-30  Aaron Boodman  <aa@chromium.org>
147
148         Added an explicit dependency on HashMap.h. It was getting pulled in via
149         <kjs/identifier.h> in the case of JSC, causing errors for the Chromium port.
150
151         Reviewed by Darin Adler.
152
153         * platform/text/PlatformString.h:
154
155 2008-10-30  Greg Bolsinga  <bolsinga@apple.com>
156
157         Reviewed by Sam Weinig
158
159         https://bugs.webkit.org/show_bug.cgi?id=21967
160         
161         For some platforms the GeolocationService must be suspended and resumed.
162
163         * page/Geolocation.cpp:
164         (WebCore::Geolocation::clearWatch): now uses Geolocation::hasListeners()
165         (WebCore::Geolocation::suspend): calls GeolocationService::suspend() if there are listeners
166         (WebCore::Geolocation::resume): calls GeolocationService::resume() if there are listeners
167         (WebCore::Geolocation::geolocationServicePositionChanged): now uses Geolocation::hasListeners()
168         * page/Geolocation.h:
169         (WebCore::Geolocation::hasListeners): Indicates of the Geolocation has interested GeolocationService listeners
170         * platform/GeolocationService.h:
171         (WebCore::GeolocationService::suspend): empty implementation
172         (WebCore::GeolocationService::resume): empty implementation
173
174 2008-10-30  Greg Bolsinga  <bolsinga@apple.com>
175
176         Reviewed by Sam Weinig
177
178         https://bugs.webkit.org/show_bug.cgi?id=21966
179         
180         The Geolocation spec was updated on 10/27/2008. This brings WebCore up to date.
181         http://dev.w3.org/geo/api/spec-source.html
182
183         * page/Geolocation.cpp:
184         (WebCore::Geolocation::GeoNotifier::GeoNotifier): PositionOptions' timeout now unsigned
185         * page/Geoposition.cpp: velocity is now called speed
186         (WebCore::Geoposition::toString):
187         * page/Geoposition.h: velocity is now called speed
188         (WebCore::Geoposition::create):
189         (WebCore::Geoposition::speed):
190         (WebCore::Geoposition::Geoposition):
191         * page/Geoposition.idl: velocity is now called speed
192         * page/PositionOptions.h: timeout is now unsigned
193         (WebCore::PositionOptions::create):
194         (WebCore::PositionOptions::timeout):
195         (WebCore::PositionOptions::setTimeout):
196         (WebCore::PositionOptions::PositionOptions):
197         * page/PositionOptions.idl: timeout is now unsigned long
198
199 2008-10-30  Justin Garcia  <justin.garcia@apple.com>
200
201         Also handle preserved newlines.
202
203         * editing/BreakBlockquoteCommand.cpp:
204         (WebCore::BreakBlockquoteCommand::doApply):
205
206 2008-10-30  Justin Garcia  <justin.garcia@apple.com>
207
208         Reviewed by Beth Dakin.
209
210         <rdar://problem/6104369> Hitting return at the end of a quoted line creates an extraneous quoted line
211
212         * editing/BreakBlockquoteCommand.cpp:
213         (WebCore::BreakBlockquoteCommand::doApply): 
214         Don't store the endingSelection() in selection, just call endingSelection() in the few places it's 
215         needed.  This function is cheap since it just returns a reference to a Selection instead of creating one.
216         Don't store an affinity.  In the one place that it was used, isLastVisiblePositionInNode(VisiblePosition(pos, affinity), topBlockquote),
217         we now use visiblePos (in order to avoid VisiblePosition creation).
218         Set pos after we delete the current selection (if there is one), and be consistent about what we set 
219         pos to.  Before, we upstream()ed it if there was a selection to delete and left it alone otherwise.  In fact...
220         ...we need to use downstream() for pos so that when a caret is at the boundary between two nodes, pos is 
221         in the first node that we want to move.  This fixes the bug, since it lets code that checks for the case 
222         where the caret is between text and a br work correctly.
223
224 2008-10-30  Yael Aharon  <yael.aharon@nokia.com>
225
226         Reviewed by Darin Adler.
227
228         Fix the Qt build.
229
230         https://bugs.webkit.org/show_bug.cgi?id=21969
231
232         * inspector/front-end/WebKit.qrc:
233         * platform/graphics/qt/ImageBufferQt.cpp:
234         (WebCore::ImageBufferData::ImageBufferData):
235         (WebCore::ImageBuffer::ImageBuffer):
236         (WebCore::ImageBuffer::context):
237         (WebCore::ImageBuffer::image):
238         (WebCore::ImageBuffer::toDataURL):
239
240 2008-10-30  Justin Garcia  <justin.garcia@apple.com>
241
242         Reviewed by Darin Adler.
243
244         More preparation for:
245         <rdar://problem/6104369> Hitting return at the end of a quoted line creates an extraneous quoted line
246
247         * editing/BreakBlockquoteCommand.cpp:
248         (WebCore::BreakBlockquoteCommand::doApply): Added comments.  Don't need to use newStartNode.  If the 
249         startNode needs to change, change it.  Afterwords, check to make sure that it hasn't left topBlockquote.  
250         This is slightly stricter than before, where we just made sure that it still had a topBlockquote.  This 
251         doesn't really fix a bug, since we can't really get into a situation where we move to a different 
252         topBlockquote, but it simplifies the code.
253
254 >>>>>>> .r38031
255 2008-10-30  Dirk Schulze  <vbs85@gmx.de>
256
257         Reviewed by Alp Toker.
258
259         https://bugs.webkit.org/show_bug.cgi?id=21883
260         [CAIRO] globalAlpha has to be stored and restored
261
262         Cairo's globalAlpha has to be stored and reloaded on calling
263         save() and restore(). We use the power of GraphicsContextState for this.
264
265         * platform/graphics/GraphicsContextPrivate.h:
266         (WebCore::GraphicsContextState::GraphicsContextState):
267         * platform/graphics/cairo/GraphicsContextCairo.cpp:
268         (WebCore::GraphicsContext::fillPath):
269         (WebCore::GraphicsContext::strokePath):
270         (WebCore::GraphicsContext::setAlpha):
271         (WebCore::GraphicsContext::getAlpha):
272         * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h:
273         (WebCore::GraphicsContextPlatformPrivate::GraphicsContextPlatformPrivate):
274
275 2008-10-29  Alexey Proskuryakov  <ap@webkit.org>
276
277         Reviewed by Maciej Stachowiak.
278
279         Rename "attachedToEventTargetNode" to "isInline".
280
281         Inline (onXXX) attributes are used not just with event target nodes, but also with Window,
282         XMLHttpRequest, MessagePort et al.
283
284         Also renamed createHTMLEventHandler() (which was a leftover from earlier isHTMLEvent ->
285         attachedToEventTargetNode rename made for SVG) to createInlineEventListener().
286         And also renamed EventTargetNode, Document and Window "eventListenerForType" methods to
287         "inlineEventListenerForType", as they work with inline listeners.
288
289         * bindings/js/JSDOMApplicationCacheCustom.cpp:
290         (WebCore::JSDOMApplicationCache::addEventListener):
291         (WebCore::JSDOMApplicationCache::removeEventListener):
292         * bindings/js/JSMessagePortCustom.cpp:
293         (WebCore::JSMessagePort::setOnmessage):
294         (WebCore::JSMessagePort::setOnclose):
295         * bindings/js/JSXMLHttpRequestCustom.cpp:
296         (WebCore::JSXMLHttpRequest::addEventListener):
297         (WebCore::JSXMLHttpRequest::removeEventListener):
298         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
299         (WebCore::JSXMLHttpRequestUpload::addEventListener):
300         (WebCore::JSXMLHttpRequestUpload::removeEventListener):
301         Pass a correct value for this argument - callers used to be confused, because they didn't
302         consider themselves event target nodes. This doesn't affect behavior however, as the only
303         difference between inline and non-inline event handlers is that the former treat
304         "return false" as "event.preventDefault()", which is not important to any of these objects.
305
306         * bindings/js/JSEventListener.cpp: (WebCore::JSLazyEventListener::parseCode):
307         Assert that isInline is true instead of checking its value, as the constructor of this class
308         always sets it to true.
309
310         * bindings/js/JSDOMWindowBase.cpp:
311         (WebCore::JSDOMWindowBase::~JSDOMWindowBase):
312         (WebCore::JSDOMWindowBase::findJSEventListener):
313         (WebCore::JSDOMWindowBase::findOrCreateJSEventListener):
314         (WebCore::JSDOMWindowBase::findJSUnprotectedEventListener):
315         (WebCore::JSDOMWindowBase::findOrCreateJSUnprotectedEventListener):
316         (WebCore::JSDOMWindowBase::jsInlineEventListeners):
317         (WebCore::JSDOMWindowBase::jsUnprotectedInlineEventListeners):
318         * bindings/js/JSDOMWindowBase.h:
319         * bindings/js/JSEventListener.cpp:
320         (WebCore::JSAbstractEventListener::handleEvent):
321         (WebCore::JSAbstractEventListener::isInline):
322         (WebCore::JSUnprotectedEventListener::JSUnprotectedEventListener):
323         (WebCore::JSUnprotectedEventListener::~JSUnprotectedEventListener):
324         (WebCore::JSEventListener::JSEventListener):
325         (WebCore::JSEventListener::~JSEventListener):
326         (WebCore::JSLazyEventListener::parseCode):
327         * bindings/js/JSEventListener.h:
328         (WebCore::JSAbstractEventListener::JSAbstractEventListener):
329         (WebCore::JSUnprotectedEventListener::create):
330         (WebCore::JSEventListener::create):
331         * bindings/js/ScriptController.cpp:
332         (WebCore::ScriptController::createInlineEventHandler):
333         * bindings/js/ScriptController.h:
334         * dom/Document.cpp:
335         (WebCore::Document::setWindowInlineEventListenerForType):
336         (WebCore::Document::windowInlineEventListenerForType):
337         (WebCore::Document::removeWindowInlineEventListenerForType):
338         (WebCore::Document::createEventListener):
339         (WebCore::Document::setWindowInlineEventListenerForTypeAndAttribute):
340         * dom/Document.h:
341         * dom/EventListener.h:
342         (WebCore::EventListener::isInline):
343         * dom/EventTargetNode.cpp:
344         (WebCore::EventTargetNode::removeInlineEventListenerForType):
345         (WebCore::EventTargetNode::setInlineEventListenerForType):
346         (WebCore::EventTargetNode::setInlineEventListenerForTypeAndAttribute):
347         (WebCore::EventTargetNode::inlineEventListenerForType):
348         (WebCore::EventTargetNode::on*): (many methods)
349         (WebCore::EventTargetNode::setOn*): (many methods)
350         * dom/EventTargetNode.h:
351         * editing/ReplaceSelectionCommand.cpp:
352         (WebCore::ReplacementFragment::ReplacementFragment):
353         * html/HTMLBodyElement.cpp:
354         (WebCore::HTMLBodyElement::parseMappedAttribute):
355         * html/HTMLButtonElement.cpp:
356         (WebCore::HTMLButtonElement::parseMappedAttribute):
357         * html/HTMLElement.cpp:
358         (WebCore::HTMLElement::parseMappedAttribute):
359         * html/HTMLFormElement.cpp:
360         (WebCore::HTMLFormElement::parseMappedAttribute):
361         * html/HTMLFrameElementBase.cpp:
362         (WebCore::HTMLFrameElementBase::parseMappedAttribute):
363         * html/HTMLFrameSetElement.cpp:
364         (WebCore::HTMLFrameSetElement::parseMappedAttribute):
365         * html/HTMLImageElement.cpp:
366         (WebCore::HTMLImageElement::parseMappedAttribute):
367         * html/HTMLInputElement.cpp:
368         (WebCore::HTMLInputElement::parseMappedAttribute):
369         * html/HTMLObjectElement.cpp:
370         (WebCore::HTMLObjectElement::parseMappedAttribute):
371         * html/HTMLScriptElement.cpp:
372         (WebCore::HTMLScriptElement::parseMappedAttribute):
373         * html/HTMLSelectElement.cpp:
374         (WebCore::HTMLSelectElement::parseMappedAttribute):
375         * html/HTMLTextAreaElement.cpp:
376         (WebCore::HTMLTextAreaElement::parseMappedAttribute):
377         * page/AccessibilityRenderObject.cpp:
378         (WebCore::AccessibilityRenderObject::mouseButtonListener):
379         * page/DOMWindow.cpp:
380         (WebCore::DOMWindow::setInlineEventListenerForType):
381         (WebCore::DOMWindow::inlineEventListenerForType):
382         (WebCore::DOMWindow::on*): (many methods)
383         (WebCore::DOMWindow::setOn*): (many methods)
384         * page/DOMWindow.h:
385         * svg/SVGElement.cpp:
386         (WebCore::SVGElement::parseMappedAttribute):
387         * svg/SVGElementInstance.cpp:
388         (WebCore::SVGElementInstance::on*): (many methods)
389         (WebCore::SVGElementInstance::setOn*): (many methods)
390         * svg/SVGSVGElement.cpp:
391         (WebCore::SVGSVGElement::parseMappedAttribute):
392         Rename things, as described above.
393
394 2008-10-29  Gustavo Noronha Silva  <gns@gnome.org>
395
396         Reviewed and slightly changed by Holger Freyther.
397
398         Added all the files that need to be installed for the Inspector to
399         work.
400
401         * GNUmakefile.am: Invoke the shell to get the files.
402
403 2008-10-29  Andrew Scherkus  <scherkus@chromium.org>
404
405         Reviewed by Darin Adler
406
407         Add MediaPlayerPrivateChromium to MediaPlayer
408         https://bugs.webkit.org/show_bug.cgi?id=21930
409
410         * platform/graphics/MediaPlayer.cpp:
411
412 2008-10-29  Justin Garcia  <justin.garcia@apple.com>
413
414         Reviewed by Darin Adler.
415
416         Some preparation for:
417         <rdar://problem/6104369> Hitting return at the end of a quoted line creates an extraneous quoted line
418         
419         Added an early return to avoid a level of if-nesting.  No other changes.  We probably don't
420         need to rebalance whitespace before the early return but for now don't risk any change in behavior
421         I'll revisit that later.
422
423         * editing/BreakBlockquoteCommand.cpp:
424         (WebCore::BreakBlockquoteCommand::doApply):
425
426 2008-10-29  Kevin Ollivier  <kevino@theolliviers.com>
427
428         wx build fixes after addition of runtime and ImageBuffer changes.
429         
430         * platform/graphics/wx/ImageBufferData.h: Added.
431         * platform/graphics/wx/ImageBufferWx.cpp:
432         (WebCore::ImageBufferData::ImageBufferData):
433         (WebCore::ImageBuffer::ImageBuffer):
434         (WebCore::ImageBuffer::context):
435         * webcore-base.bkl:
436
437 2008-10-29  Brett Wilson  <brettw@chromium.org>
438
439         Reviewed by Darin Adler
440         https://bugs.webkit.org/attachment.cgi?id=24745
441
442         Allow Skia implementations to get text style changed notifications.
443
444         * platform/graphics/GraphicsContext.cpp:
445
446 2008-10-29  Timothy Hatcher  <timothy@apple.com>
447
448         Add a manual test that checks breakpoints on a blockless body of
449         an "else" statement.
450
451         https://bugs.webkit.org/show_bug.cgi?id=21944
452
453         Reviewed by Maciej Stachowiak.
454
455         * manual-tests/inspector/debugger-pause-on-else-statements.html: Added.
456
457 2008-10-29  Alexey Proskuryakov  <ap@webkit.org>
458
459         Reviewed by Darin Adler.
460
461         https://bugs.webkit.org/show_bug.cgi?id=21921
462         MessagePort messages are dispatched to documents that are not fully active
463
464         Covered by corrected fast/events/message-port-inactive-document.html
465
466         * bindings/js/JSEventListener.cpp:
467         (WebCore::JSAbstractEventListener::handleEvent): Don't dispatch messages to contexts
468         that are not fully active.
469
470 2008-10-29  Alexey Proskuryakov  <ap@webkit.org>
471
472         Reviewed by Sam Weinig.
473
474         https://bugs.webkit.org/show_bug.cgi?id=21922
475         Expose MessagePort global constructor
476
477         Covered by existing dumper tests.
478
479         * dom/MessagePort.idl:
480         * page/DOMWindow.idl:
481
482 2008-10-29  Alexey Proskuryakov  <ap@webkit.org>
483
484         Reviewed by Darin Adler.
485
486         https://bugs.webkit.org/show_bug.cgi?id=21924
487         HashTable internal index is not always deleted
488
489         * bindings/js/JSDOMBinding.cpp: (WebCore::DOMObjectHashTableMap::~DOMObjectHashTableMap):
490         Call deleteTable for HashTables that are being deleted.
491
492 2008-10-28  Alexey Proskuryakov  <ap@webkit.org>
493
494         Reviewed by Darin Adler.
495
496         https://bugs.webkit.org/show_bug.cgi?id=21923
497         Create an abstraction for script execution context
498
499         * GNUmakefile.am:
500         * WebCore.pro:
501         * WebCore.vcproj/WebCore.vcproj:
502         * WebCore.xcodeproj/project.pbxproj:
503         * WebCoreSources.bkl:
504         Added ScriptExecutionContext.{h,cpp}.
505
506         * bindings/js/JSAudioConstructor.cpp:
507         (WebCore::JSAudioConstructor::JSAudioConstructor):
508         * bindings/js/JSAudioConstructor.h:
509         * bindings/js/JSImageConstructor.cpp:
510         (WebCore::JSImageConstructor::JSImageConstructor):
511         * bindings/js/JSImageConstructor.h:
512         * bindings/js/JSOptionConstructor.cpp:
513         (WebCore::JSOptionConstructor::JSOptionConstructor):
514         * bindings/js/JSOptionConstructor.h:
515         * bindings/js/JSXMLHttpRequestConstructor.cpp:
516         (WebCore::JSXMLHttpRequestConstructor::JSXMLHttpRequestConstructor):
517         * bindings/js/JSXMLHttpRequestConstructor.h:
518         Pass ScriptExecutionContext instead of Document to make getDOMConstructor() happy.
519         Since these objects can only work within documents now, it is immediately converted back
520         to Document.
521
522         * bindings/js/JSMessageChannelConstructor.cpp:
523         (WebCore::JSMessageChannelConstructor::JSMessageChannelConstructor):
524         (WebCore::JSMessageChannelConstructor::construct):
525         * bindings/js/JSMessageChannelConstructor.h:
526         (WebCore::JSMessageChannelConstructor::scriptExecutionContext):
527         MessageChannel needs to be supported in workers right away, so the constructor operates with
528         it directly.
529
530         * dom/ActiveDOMObject.cpp:
531         (WebCore::ActiveDOMObject::ActiveDOMObject):
532         (WebCore::ActiveDOMObject::~ActiveDOMObject):
533         (WebCore::ActiveDOMObject::contextDestroyed):
534         * dom/ActiveDOMObject.h:
535         (WebCore::ActiveDOMObject::scriptExecutionContext):
536         * bindings/js/JSDOMBinding.cpp:
537         (WebCore::markActiveObjectsForContext):
538         (WebCore::markCrossHeapDependentObjectsForContext):
539         Use ScriptExecutionContext instead of Document, now that ActiveDOMObject and MessagePort
540         tracking is handled by ScriptExecutionContext.
541
542         * bindings/js/JSDOMBinding.h: (WebCore::getDOMPrototype): Moved to JSDOMGlobalObject.
543
544         * bindings/js/JSDOMGlobalObject.h:
545         (WebCore::getDOMConstructor): Moved to this file, as constructors live in JSDOMGlobalObject.
546         Also, the two-argument version that used to be in JSDOMWindowBase.cpp need to be accessible
547         to worker context implementation.
548         (WebCore::scriptExecutionContext): Added a pure virtual method to access
549         ScriptExecutionContext, implemented by subclasses.
550
551         * bindings/js/JSDOMWindowBase.h:
552         * bindings/js/JSDOMWindowBase.cpp: (WebCore::JSDOMWindowBase::scriptExecutionContext):
553         Implement by returning the associated document. Note that this method currently gives bogus
554         results after navigation - DOMWindow Frame reference is not zeroed out, so we get a document
555         that is currently in the frame, not the one associated with this window.
556
557         * bindings/js/JSDedicatedWorkerConstructor.cpp: Removed unnecessary include of DOMWindow.h.
558
559         * bindings/js/JSDocumentCustom.cpp: (WebCore::JSDocument::mark):
560         Call markActiveObjectsForContext() by its new name.
561
562         * dom/DedicatedWorker.cpp:
563         (WebCore::DedicatedWorker::DedicatedWorker):
564         (WebCore::DedicatedWorker::document):
565         * dom/DedicatedWorker.h:
566         * xml/XMLHttpRequest.cpp:
567         (WebCore::XMLHttpRequest::document):
568         * xml/XMLHttpRequest.h:
569         Added a document() function that upcasts ScriptExecutionContext, as these objects only work
570         within documents currently (at least for XMLHttpRequest, this will change soon though).
571
572         * dom/Document.cpp:
573         (WebCore::Document::Document):
574         (WebCore::Document::~Document):
575         Moved active object and MessagePort tracking up to ScriptExecutionContext, to share code
576         with workers.
577         
578         * dom/Document.h:
579         (WebCore::Document::isDocument):
580         (WebCore::Document::refScriptExecutionContext):
581         (WebCore::Document::derefScriptExecutionContext):
582         Inherit from ScriptExecutionContext.
583
584         * dom/MessageChannel.cpp:
585         (WebCore::MessageChannel::MessageChannel):
586         * dom/MessageChannel.h:
587         (WebCore::MessageChannel::create):
588         Use ScriptExecutionContext instead of Document.
589
590         * dom/MessagePort.cpp:
591         (WebCore::CloseMessagePortTimer::CloseMessagePortTimer): Make m_port a RefPtr, because
592         MessagePort doesn't ref() itself when posting this event any more (this is a fix for an
593         unrelated issue that was causing random crashes in layout tests).
594         (WebCore::MessagePort::MessagePort):
595         (WebCore::MessagePort::~MessagePort):
596         (WebCore::MessagePort::associatedFrame):
597         (WebCore::MessagePort::clone):
598         (WebCore::MessagePort::postMessage):
599         (WebCore::MessagePort::startConversation):
600         (WebCore::MessagePort::start):
601         (WebCore::MessagePort::contextDestroyed):
602         (WebCore::MessagePort::dispatchMessages):
603         * dom/MessagePort.h:
604         (WebCore::MessagePort::create):
605         (WebCore::MessagePort::scriptExecutionContext):
606         Use ScriptExecutionContext instead of Document. This is a step toward making MessagePort
607         work in worker contexts - we need to also make some its method thread safe for cross-thread
608         messaging, and make event dispatching thread safe.
609
610         * dom/ScriptExecutionContext.cpp: Added.
611         * dom/ScriptExecutionContext.h: Added.
612         ActiveDOMObject and MessagePort tracking is moved from Document.
613         It is debatable whether ScriptExecutionContext should be a parent of Document or DOMWindow,
614         but as I'm just moving Document code, and it is Document that is the main context object
615         in our implementation currently.
616         Changing ScriptExecutionContext to be a parent of DOMWindow causes a number of bugs that
617         seem non-trivial to fix, and isn't really a part of this task.
618
619 2008-10-28  Alp Toker  <alp@nuanti.com>
620
621         List newly-added ImageBufferData.h in build system.
622
623         * GNUmakefile.am:
624
625 2008-10-28  Alp Toker  <alp@nuanti.com>
626
627         Reviewed by Cameron Zwarich.
628
629         De-list unused WebCore ForwardingHeaders to fix the dist target.
630
631         * GNUmakefile.am:
632
633 2008-10-28  Cameron Zwarich  <zwarich@apple.com>
634
635         Not reviewed.
636
637         Attempt to fix the Windows build by generating Forwardingheaders for the
638         runtime directory in JavaScriptCore.
639
640         * WebCore.vcproj/WebCore.vcproj:
641
642 2008-10-28  Justin Garcia  <justin.garcia@apple.com>
643
644         Reviewed by Darin Adler.
645
646         <rdar://problem/5188560> REGRESSION: Spell checker doesn't clear spelling/grammar marker after error is marked as Ignored
647
648         * editing/Editor.cpp:
649         (WebCore::Editor::ignoreSpelling): Remove misspelling markers from the word.
650         (WebCore::Editor::learnSpelling): Added a FIXME about <rdar://problem/5396072>, which 
651         will probably require a change more complicated than just marking the learned word as 
652         misspelled.  I'll address it with a separate patch.
653         * editing/EditorCommand.cpp:
654         (WebCore::executeIgnoreSpelling): Added.
655         (WebCore::CommandEntry::): Added an entry for IgnoreSpelling.
656
657 2008-10-28  Cameron Zwarich  <zwarich@apple.com>
658
659         Reviewed by Mark Rowe.
660
661         Move ForwardingHeaders to their correct location after the creation of
662         the runtime directory in JavaScriptCore.
663
664         * ForwardingHeaders/kjs/ArrayPrototype.h: Removed.
665         * ForwardingHeaders/kjs/BooleanObject.h: Removed.
666         * ForwardingHeaders/kjs/CallData.h: Removed.
667         * ForwardingHeaders/kjs/ConstructData.h: Removed.
668         * ForwardingHeaders/kjs/DateInstance.h: Removed.
669         * ForwardingHeaders/kjs/Error.h: Removed.
670         * ForwardingHeaders/kjs/FunctionConstructor.h: Removed.
671         * ForwardingHeaders/kjs/FunctionPrototype.h: Removed.
672         * ForwardingHeaders/kjs/InternalFunction.h: Removed.
673         * ForwardingHeaders/kjs/JSArray.h: Removed.
674         * ForwardingHeaders/kjs/JSFunction.h: Removed.
675         * ForwardingHeaders/kjs/JSGlobalObject.h: Removed.
676         * ForwardingHeaders/kjs/JSNumberCell.h: Removed.
677         * ForwardingHeaders/kjs/JSObject.h: Removed.
678         * ForwardingHeaders/kjs/JSString.h: Removed.
679         * ForwardingHeaders/kjs/JSValue.h: Removed.
680         * ForwardingHeaders/kjs/ObjectPrototype.h: Removed.
681         * ForwardingHeaders/kjs/PropertyMap.h: Removed.
682         * ForwardingHeaders/kjs/PrototypeFunction.h: Removed.
683         * ForwardingHeaders/kjs/StringObject.h: Removed.
684         * ForwardingHeaders/kjs/StringObjectThatMasqueradesAsUndefined.h: Removed.
685         * ForwardingHeaders/kjs/StringPrototype.h: Removed.
686         * ForwardingHeaders/kjs/StructureID.h: Removed.
687         * ForwardingHeaders/runtime: Added.
688         * ForwardingHeaders/runtime/ArrayPrototype.h: Copied from ForwardingHeaders/kjs/ArrayPrototype.h.
689         * ForwardingHeaders/runtime/BooleanObject.h: Copied from ForwardingHeaders/kjs/BooleanObject.h.
690         * ForwardingHeaders/runtime/CallData.h: Copied from ForwardingHeaders/kjs/CallData.h.
691         * ForwardingHeaders/runtime/ConstructData.h: Copied from ForwardingHeaders/kjs/ConstructData.h.
692         * ForwardingHeaders/runtime/DateInstance.h: Copied from ForwardingHeaders/kjs/DateInstance.h.
693         * ForwardingHeaders/runtime/Error.h: Copied from ForwardingHeaders/kjs/Error.h.
694         * ForwardingHeaders/runtime/FunctionConstructor.h: Copied from ForwardingHeaders/kjs/FunctionConstructor.h.
695         * ForwardingHeaders/runtime/FunctionPrototype.h: Copied from ForwardingHeaders/kjs/FunctionPrototype.h.
696         * ForwardingHeaders/runtime/InternalFunction.h: Copied from ForwardingHeaders/kjs/InternalFunction.h.
697         * ForwardingHeaders/runtime/JSArray.h: Copied from ForwardingHeaders/kjs/JSArray.h.
698         * ForwardingHeaders/runtime/JSFunction.h: Copied from ForwardingHeaders/kjs/JSFunction.h.
699         * ForwardingHeaders/runtime/JSGlobalObject.h: Copied from ForwardingHeaders/kjs/JSGlobalObject.h.
700         * ForwardingHeaders/runtime/JSNumberCell.h: Copied from ForwardingHeaders/kjs/JSNumberCell.h.
701         * ForwardingHeaders/runtime/JSObject.h: Copied from ForwardingHeaders/kjs/JSObject.h.
702         * ForwardingHeaders/runtime/JSString.h: Copied from ForwardingHeaders/kjs/JSString.h.
703         * ForwardingHeaders/runtime/JSValue.h: Copied from ForwardingHeaders/kjs/JSValue.h.
704         * ForwardingHeaders/runtime/ObjectPrototype.h: Copied from ForwardingHeaders/kjs/ObjectPrototype.h.
705         * ForwardingHeaders/runtime/PropertyMap.h: Copied from ForwardingHeaders/kjs/PropertyMap.h.
706         * ForwardingHeaders/runtime/PrototypeFunction.h: Copied from ForwardingHeaders/kjs/PrototypeFunction.h.
707         * ForwardingHeaders/runtime/StringObject.h: Copied from ForwardingHeaders/kjs/StringObject.h.
708         * ForwardingHeaders/runtime/StringObjectThatMasqueradesAsUndefined.h: Copied from ForwardingHeaders/kjs/StringObjectThatMasqueradesAsUndefined.h.
709         * ForwardingHeaders/runtime/StringPrototype.h: Copied from ForwardingHeaders/kjs/StringPrototype.h.
710         * ForwardingHeaders/runtime/StructureID.h: Copied from ForwardingHeaders/kjs/StructureID.h.
711         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
712         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
713         * bindings/js/JSClipboardCustom.cpp:
714         * bindings/js/JSConsoleCustom.cpp:
715         * bindings/js/JSCustomPositionCallback.h:
716         * bindings/js/JSCustomPositionErrorCallback.h:
717         * bindings/js/JSCustomSQLStatementCallback.h:
718         * bindings/js/JSCustomSQLStatementErrorCallback.h:
719         * bindings/js/JSCustomSQLTransactionErrorCallback.h:
720         * bindings/js/JSCustomVoidCallback.h:
721         * bindings/js/JSCustomXPathNSResolver.h:
722         * bindings/js/JSDOMBinding.cpp:
723         * bindings/js/JSDOMBinding.h:
724         * bindings/js/JSDOMGlobalObject.h:
725         * bindings/js/JSDOMWindowBase.cpp:
726         * bindings/js/JSDOMWindowCustom.cpp:
727         * bindings/js/JSDOMWindowShell.cpp:
728         * bindings/js/JSDatabaseCustom.cpp:
729         * bindings/js/JSEventListener.cpp:
730         * bindings/js/JSEventTarget.h:
731         * bindings/js/JSHTMLDocumentCustom.cpp:
732         * bindings/js/JSHistoryCustom.cpp:
733         * bindings/js/JSInspectedObjectWrapper.cpp:
734         * bindings/js/JSJavaScriptCallFrameCustom.cpp:
735         * bindings/js/JSLocationCustom.cpp:
736         * bindings/js/JSNodeFilterCondition.h:
737         * bindings/js/JSQuarantinedObjectWrapper.cpp:
738         * bindings/js/JSQuarantinedObjectWrapper.h:
739         * bindings/js/JSXMLHttpRequestCustom.cpp:
740         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
741         * bindings/objc/WebScriptObject.mm:
742         * bindings/objc/WebScriptObjectPrivate.h:
743         * bindings/scripts/CodeGeneratorJS.pm:
744         * bridge/NP_jsobject.cpp:
745         * bridge/c/c_instance.cpp:
746         * bridge/c/c_utility.cpp:
747         * bridge/c/c_utility.h:
748         * bridge/jni/jni_instance.cpp:
749         * bridge/jni/jni_jsobject.h:
750         * bridge/jni/jni_jsobject.mm:
751         * bridge/jni/jni_runtime.cpp:
752         * bridge/jni/jni_utility.cpp:
753         * bridge/jni/jni_utility.h:
754         * bridge/objc/objc_instance.mm:
755         * bridge/objc/objc_runtime.h:
756         * bridge/objc/objc_runtime.mm:
757         * bridge/objc/objc_utility.h:
758         * bridge/objc/objc_utility.mm:
759         * bridge/runtime.h:
760         * bridge/runtime_array.cpp:
761         * bridge/runtime_array.h:
762         * bridge/runtime_method.cpp:
763         * bridge/runtime_method.h:
764         * bridge/runtime_object.cpp:
765         * bridge/runtime_object.h:
766         * bridge/runtime_root.cpp:
767         * inspector/JavaScriptCallFrame.cpp:
768         * inspector/JavaScriptProfile.cpp:
769         * inspector/JavaScriptProfile.h:
770         * inspector/JavaScriptProfileNode.cpp:
771         * inspector/JavaScriptProfileNode.h:
772         * loader/FrameLoader.cpp:
773         * page/Console.cpp:
774         * plugins/PluginView.cpp:
775         * plugins/gtk/PluginViewGtk.cpp:
776         * plugins/qt/PluginViewQt.cpp:
777         * plugins/win/PluginViewWin.cpp:
778
779 2008-10-28  Adele Peterson  <adele@apple.com>
780
781         Windows build fix.  This removes Cairo include directories from non-Cairbo build configurations.
782
783         * WebCore.vcproj/WebCore.vcproj:
784
785 2008-10-28  Adele Peterson  <adele@apple.com>
786
787         Windows build fix.
788
789         * platform/graphics/ImageBuffer.h:
790         (WebCore::ImageBuffer::create):
791
792 2008-10-28  Cameron Zwarich  <zwarich@apple.com>
793
794         Not reviewed.
795
796         Roll out a mistaken attempt at fixing the GTK build in r37947.
797
798         * GNUmakefile.am:
799
800 2008-10-28  Adele Peterson  <adele@apple.com>
801
802         Reviewed by John Sullivan.
803
804         Fix for https://bugs.webkit.org/show_bug.cgi?id=21880
805         "files" string for multifile uploads needs to be localized
806
807         * page/mac/WebCoreViewFactory.h:
808         * platform/LocalizedStrings.h:
809         * platform/gtk/FileChooserGtk.cpp: (WebCore::FileChooser::basenameForWidth):
810         * platform/gtk/LocalizedStringsGtk.cpp: (WebCore::multipleFileUploadText):
811         * platform/mac/FileChooserMac.mm: (WebCore::FileChooser::basenameForWidth):
812         * platform/mac/LocalizedStringsMac.mm: (WebCore::multipleFileUploadText):
813         * platform/qt/Localizations.cpp: (WebCore::multipleFileUploadText):
814         * platform/wx/LocalizedStringsWx.cpp: (WebCore::multipleFileUploadText):
815
816 2008-10-28  Brett Wilson  <brettw@chromium.org>
817
818         Reviewed by Darin Adler.
819
820         https://bugs.webkit.org/show_bug.cgi?id=21816
821
822         Remove platform ifdefs in ImageBuffer.h by moving platform specific code
823         into a new PlatformImageBuffer class. Move the static create function
824         into the header because it can be cross-platform. Initialization now
825         happens in the cunstructor which sets a flag that create uses to know
826         whether it should return null or not. I also made passing of IntSize
827         more consistent (always by reference).
828
829         This change also changes the ifdefs in GraphicsContext to allow Skia
830         ports to implement text drawing modes.
831
832         * platform/graphics/ImageBuffer.h:
833         (WebCore::ImageBuffer::create):
834         (WebCore::ImageBuffer::size):
835         * platform/graphics/cairo/ImageBufferCairo.cpp:
836         (WebCore::ImageBufferData::ImageBufferData):
837         (WebCore::ImageBuffer::ImageBuffer):
838         (WebCore::ImageBuffer::~ImageBuffer):
839         (WebCore::ImageBuffer::image):
840         (WebCore::ImageBuffer::getImageData):
841         (WebCore::ImageBuffer::putImageData):
842         * platform/graphics/cairo/ImageBufferData.h:
843         * platform/graphics/cg/ImageBufferCG.cpp:
844         (WebCore::ImageBufferData::ImageBufferData):
845         (WebCore::ImageBuffer::ImageBuffer):
846         (WebCore::ImageBuffer::~ImageBuffer):
847         (WebCore::ImageBuffer::getImageData):
848         (WebCore::ImageBuffer::putImageData):
849         * platform/graphics/cg/ImageBufferData.h:
850         * platform/graphics/qt/ImageBufferData.h:
851         * platform/graphics/qt/ImageBufferQt.cpp:
852         (WebCore::ImageBufferData::ImageBufferData):
853         (WebCore::ImageBuffer::ImageBuffer):
854         (WebCore::ImageBuffer::~ImageBuffer):
855
856 2008-10-28  Cameron Zwarich  <zwarich@apple.com>
857
858         Not reviewed.
859
860         Fix the GTK build.
861
862         * GNUmakefile.am:
863
864 2008-10-28  Cameron Zwarich  <zwarich@apple.com>
865
866         Not reviewed.
867
868         Another Qt build fix.
869
870         * WebCore.pro:
871
872 2008-10-28  Greg Bolsinga  <bolsinga@apple.com>
873
874         Reviewed by David Kilzer.
875
876         https://bugs.webkit.org/show_bug.cgi?id=21932
877         Add non-pointer constant lookups to SoftLinking.h
878
879         * platform/mac/SoftLinking.h:
880
881 2008-10-28  Greg Bolsinga  <bolsinga@apple.com>
882
883         Reviewed by David Kilzer.
884
885         https://bugs.webkit.org/show_bug.cgi?id=2192
886         Missing semi-colons in Geoposition.idl
887
888         * page/Geoposition.idl: Add missing semi-colons
889
890 2008-10-28  Timothy Hatcher  <timothy@apple.com>
891
892         Make the Profiles panel in the Web Inspector have an enable screen.
893         Profiling now needs to be enabled before console.profile() works.
894
895         <rdar://problem/6211578> Make the JavaScript profiler opt-in, so it does
896         not slow down JavaScript all the time
897
898         Reviewed by Darin Adler and Kevin McCullough.
899
900         * English.lproj/localizedStrings.js: New strings.
901         * WebCore.base.exp: New and changed exports.
902         * WebCore.vcproj/WebCore.vcproj: Add the PanelEnablerView.js file.
903         * bindings/js/JSDOMWindowBase.cpp:
904         (WebCore::JSDOMWindowBase::supportsProfiling): Call InspectorController:profilerEnabled.
905         * inspector/InspectorController.cpp:
906         (WebCore::InspectorController::InspectorController): Initialize the m_startProfiling
907         Timer to call InspectorController::startUserInitiatedProfiling.
908         (WebCore::InspectorController::startUserInitiatedProfilingSoon): Start a one-shot timer
909         that calls InspectorController::startUserInitiatedProfiling.
910         (WebCore::InspectorController::startUserInitiatedProfiling): Recompile all JavaScript
911         and enable the profiler if the profiler was not enabled.
912         (WebCore::InspectorController::stopUserInitiatedProfiling): Rearrange code for readability.
913         (WebCore::InspectorController::enableProfiler): Recompile all the JavaScript functions
914         if the skipRecompile argument is false. Call the profilerWasEnabled script function.
915         (WebCore::InspectorController::disableProfiler): Recompile all the JavaScript functions.
916         Call the profilerWasEnabled script function.
917         (WebCore::InspectorController::disableDebugger): Set m_attachDebuggerWhenShown to false,
918         so it won't be started later.
919         * inspector/InspectorController.h:
920         (WebCore::InspectorController::profilerEnabled): Return enabled() && m_profilerEnabled.
921         * inspector/front-end/Images/debuggingButtons.png: Remove.
922         * inspector/front-end/Images/enableButtons.png: Added.
923         * inspector/front-end/Images/profilesSilhouette.png: Added.
924         * inspector/front-end/Images/scriptsSilhouette.png: Added.
925         * inspector/front-end/PanelEnablerView.js: Added.
926         (WebInspector.PanelEnablerView):
927         (WebInspector.PanelEnablerView.prototype._enableButtonCicked): Fire the "enable clicked"
928         event so listeners can do their thing.
929         (WebInspector.PanelEnablerView.prototype._windowResized): Test if the icon should be hidden.
930         * inspector/front-end/ProfilesPanel.js:
931         (WebInspector.ProfilesPanel): Create the PanelEnablerView and the strings needed for it.
932         (WebInspector.ProfilesPanel.prototype.get statusBarItems): Include the enableToggleButton.
933         (WebInspector.ProfilesPanel.prototype.profilerWasEnabled): Call reset and populateInterface.
934         (WebInspector.ProfilesPanel.prototype.profilerWasDisabled): Call reset.
935         (WebInspector.ProfilesPanel.prototype.reset): Call _updateInterface.
936         (WebInspector.ProfilesPanel.prototype.setRecordingProfile): Moved in the code, no changes.
937         (WebInspector.ProfilesPanel.prototype._updateInterface): Update the toggle button and
938         show/hide other buttons. Also show/hide the PanelEnablerView.
939         (WebInspector.ProfilesPanel.prototype._enableProfiling): Call _toggleProfiling if not enabled.
940         (WebInspector.ProfilesPanel.prototype._toggleProfiling): Call InspectorController's
941         disableProfiler or enableProfiler.
942         * inspector/front-end/ScriptsPanel.js:
943         (WebInspector.ScriptsPanel): Replace the overlay element with a PanelEnablerView. Replace the
944         debuggingButton with the enableToggleButton.
945         (WebInspector.ScriptsPanel.prototype.get statusBarItems): Replace the debuggingButton with
946         the enableToggleButton.
947         (WebInspector.ScriptsPanel.prototype._updateDebuggerButtons): Hide/show the pauseOnExceptionButton
948         when needed. Replace the overlay element with a PanelEnablerView. Replace the debuggingButton
949         with the enableToggleButton.
950         (WebInspector.ScriptsPanel.prototype._enableDebugging): Call _toggleDebugging when not enabled.
951         (WebInspector.ScriptsPanel.prototype._toggleDebugging): Remove the call to _clearInterface,
952         since reset is called from debuggerWasEnabled and debuggerWasDisabled.
953         * inspector/front-end/View.js: Inherit from WebInspector.Object.
954         * inspector/front-end/WebKit.qrc: Add the PanelEnablerView.js file.
955         * inspector/front-end/inspector.css: New styles for the PanelEnablerView.
956         * inspector/front-end/inspector.html: Add the PanelEnablerView.js file.
957         * inspector/front-end/inspector.js:
958         (WebInspector.profilerWasEnabled): Added. Calls the ProfilesPanel.
959         (WebInspector.profilerWasDisabled): Ditto.
960         * page/Console.cpp:
961         (WebCore::Console::error): Remove null check for m_frame, since m_frame isn't used.
962         (WebCore::Console::info): Ditto.
963         (WebCore::Console::log): Ditto.
964         (WebCore::Console::assertCondition): Ditto.
965         (WebCore::Console::dirxml): Remove null check for m_frame and use this->page().
966         (WebCore::Console::count): Ditto.
967         (WebCore::Console::profile): Return early if InspectorController::profilerEnabled is false.
968         (WebCore::Console::profileEnd): Ditto.
969         (WebCore::Console::warn): Remove null check for m_frame, since m_frame isn't used.
970         * page/Settings.cpp:
971         (WebCore::Settings::Settings): Remove initialization of m_didInitializeDeveloperExtrasEnabled.
972         (WebCore::Settings::setDeveloperExtrasEnabled): Remove code that recompiled functions.
973         Now just sets the member boolean.
974         * page/Settings.h: Remove m_didInitializeDeveloperExtrasEnabled.
975
976 2008-10-28  Timothy Hatcher  <timothy@apple.com>
977
978         Rename a few methods related to attaching and detaching the debugger. Also
979         adds stub methods for enabling and disabling the profiler.
980
981         * Rename attachDebugger to enableDebugger.
982         * Rename detachDebugger to disableDebugger.
983         * Rename the debuggerAttached getter to debuggerEnabled.
984         * Rename the debuggerAttached callback to debuggerWasEnabled.
985         * Rename the debuggerDetached callback to debuggerWasDisabled.
986
987         Reviewed by Darin Adler.
988
989         * WebCore.base.exp:
990         * inspector/InspectorController.cpp:
991         (WebCore::InspectorController::InspectorController):
992         (WebCore::InspectorController::setWindowVisible):
993         (WebCore::InspectorController::windowScriptObjectAvailable):
994         (WebCore::InspectorController::close):
995         (WebCore::InspectorController::enableProfiler):
996         (WebCore::InspectorController::disableProfiler):
997         (WebCore::InspectorController::enableDebugger):
998         (WebCore::InspectorController::disableDebugger):
999         (WebCore::InspectorController::pauseInDebugger):
1000         (WebCore::InspectorController::resumeDebugger):
1001         (WebCore::InspectorController::stepOverStatementInDebugger):
1002         (WebCore::InspectorController::stepIntoStatementInDebugger):
1003         (WebCore::InspectorController::stepOutOfFunctionInDebugger):
1004         * inspector/InspectorController.h:
1005         (WebCore::InspectorController::profilerEnabled):
1006         (WebCore::InspectorController::debuggerEnabled):
1007         * inspector/front-end/BreakpointsSidebarPane.js:
1008         (WebInspector.BreakpointsSidebarPane.prototype.addBreakpoint):
1009         (WebInspector.BreakpointsSidebarPane.prototype.removeBreakpoint):
1010         (WebInspector.BreakpointsSidebarPane.prototype._breakpointEnableChanged):
1011         * inspector/front-end/Object.js:
1012         * inspector/front-end/ProfilesPanel.js:
1013         (WebInspector.ProfilesPanel):
1014         * inspector/front-end/ScriptsPanel.js:
1015         (WebInspector.ScriptsPanel):
1016         (WebInspector.ScriptsPanel.prototype.get statusBarItems):
1017         (WebInspector.ScriptsPanel.prototype.debuggerWasEnabled):
1018         (WebInspector.ScriptsPanel.prototype.debuggerWasDetached):
1019         (WebInspector.ScriptsPanel.prototype.reset):
1020         (WebInspector.ScriptsPanel.prototype.canShowResource):
1021         (WebInspector.ScriptsPanel.prototype._updatePauseOnExceptionsButton):
1022         (WebInspector.ScriptsPanel.prototype._updateDebuggerButtons):
1023         (WebInspector.ScriptsPanel.prototype._toggleDebugging):
1024         * inspector/front-end/View.js:
1025         * inspector/front-end/inspector.css:
1026         * inspector/front-end/inspector.html:
1027         * inspector/front-end/inspector.js:
1028         (WebInspector.addResource):
1029         (WebInspector.debuggerWasEnabled):
1030         (WebInspector.debuggerWasDisabled):
1031
1032 2008-10-28  Timothy Hatcher  <timothy@apple.com>
1033
1034         Fix an exception when searching the Resources panel while there
1035         and resources queued to be added to the list.
1036
1037         Reviewed by Kevin McCullough.
1038
1039         * inspector/front-end/ResourcesPanel.js:
1040         (WebInspector.ResourcesPanel.prototype.searchCanceled): Null check
1041         the _resourcesTreeElement property.
1042         (WebInspector.ResourcesPanel.prototype.performSearch): Ditto.
1043
1044 2008-10-28  Alp Toker  <alp@nuanti.com>
1045
1046         GTK+ build fix for older versions of Pango where PANGO_VERSION_CHECK
1047         isn't defined.
1048
1049         * platform/graphics/gtk/FontGtk.cpp:
1050         (WebCore::getDefaultPangoLayout):
1051         * platform/graphics/gtk/FontPlatformDataPango.cpp:
1052
1053 2008-10-28  Alexey Proskuryakov  <ap@webkit.org>
1054
1055         Reviewed by Darin Adler.
1056
1057         https://bugs.webkit.org/show_bug.cgi?id=21893
1058         Character set is incorrect for external scripts in XHTML pages
1059
1060         <rdar://problem/6317451> Incorrect encoding for text in a popup at http://xpoint.ru/
1061
1062         Test: fast/encoding/external-script-charset.xhtml
1063
1064         Expose scriptCharset() function on all ScriptElements, and call it from XML tokenizer.
1065
1066         * dom/ScriptElement.h:
1067         * dom/XMLTokenizerLibxml2.cpp:
1068         (WebCore::XMLTokenizer::endElementNs):
1069         * dom/XMLTokenizerQt.cpp:
1070         (WebCore::XMLTokenizer::parseEndElement):
1071         * html/HTMLScriptElement.h:
1072         * svg/SVGScriptElement.cpp:
1073         (WebCore::SVGScriptElement::scriptCharset):
1074         * svg/SVGScriptElement.h:
1075
1076 2008-10-28  Alp Toker  <alp@nuanti.com>
1077
1078         Include copyright license files in the autotools dist target and
1079         exclude unused zlib headers.
1080
1081         Change suggested by Mike Hommey.
1082
1083         * GNUmakefile.am:
1084
1085 2008-10-27  Sam Weinig  <sam@webkit.org>
1086
1087         Reviewed by Maciej Stachowiak.
1088
1089         Clear the window shell when destroying a page to allow documents
1090         which have no way of being reached anymore, to be torn down.
1091
1092         * page/Frame.cpp:
1093         (WebCore::Frame::pageDestroyed):
1094
1095 2008-10-27  Kevin Watters  <kevinwatters@gmail.com>
1096
1097         Reviewed by Kevin Ollivier.
1098         
1099         Update the active state as well as the focused state as both need to be true
1100         for the caret to be drawn.
1101         
1102         https://bugs.webkit.org/show_bug.cgi?id=21900
1103
1104         * WebView.cpp:
1105         (wxWebView::OnSetFocus):
1106         (wxWebView::OnKillFocus):
1107
1108 2008-10-27  Kevin Ollivier  <kevino@theolliviers.com>
1109
1110         wx build fix on Linux/GTK. Enable support for #include <JavaScriptCore/XYZ.h> style includes.
1111
1112         * webcore-wx.bkl:
1113
1114 2008-10-27  Michael Knaup  <michael.knaup@mac.com>
1115
1116         Reviewed and tweaked by Darin Adler.
1117
1118         - https://bugs.webkit.org/show_bug.cgi?id=8988
1119
1120         Bug 8988: Add support for Mozilla CSS custom cursors.
1121         Added -webkit-grab and -webkit-grabbing cursor suppport
1122         for the Mac, dummy implementations for other platforms.
1123
1124         * css/CSSParser.cpp:
1125         (WebCore::CSSParser::parseValue): Updated since the
1126         -webkit-grabbing cursor is now the last one.
1127
1128         * css/CSSPrimitiveValueMappings.h:
1129         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Added
1130         CURSOR_WEBKIT_GRAB and CURSOR_WEBKIT_GRABBING.
1131
1132         * css/CSSValueKeywords.in: Added -webkit-grab and
1133         -webkit-grabbing.
1134
1135         * manual-tests/cursor.html: Added -webkit-zoom-in,
1136         webkit-zoom-out, -webkit-grab, and -webkit-grabbing.
1137
1138         * page/EventHandler.cpp:
1139         (WebCore::EventHandler::selectCursor): Added
1140         CURSOR_WEBKIT_GRAB and CURSOR_WEBKIT_GRABBING.
1141
1142         * platform/Cursor.h: Added grabCursor and grabbingCursor.
1143
1144         * platform/gtk/CursorGtk.cpp:
1145         (WebCore::grabCursor): Added.
1146         (WebCore::grabbingCursor): Added.
1147         * platform/mac/CursorMac.mm:
1148         (WebCore::grabCursor): Added.
1149         (WebCore::grabbingCursor): Added.
1150         * platform/qt/CursorQt.cpp:
1151         (WebCore::grabCursor): Added.
1152         (WebCore::grabbingCursor): Added.
1153         * platform/win/CursorWin.cpp:
1154         (WebCore::grabCursor): Added.
1155         (WebCore::grabbingCursor): Added.
1156         * platform/wx/CursorWx.cpp:
1157         (WebCore::grabCursor): Added.
1158         (WebCore::grabbingCursor): Added.
1159
1160         * rendering/style/RenderStyleConstants.h:
1161         Added CURSOR_WEBKIT_GRAB and CURSOR_WEBKIT_GRABBING.
1162         Also broke ECursor out into a single constant per line.
1163         Also added a couple of comments.
1164
1165 2008-10-27  Dimitri Glazkov  <dglazkov@chromium.org>
1166
1167         Reviewed by Darin Adler.
1168
1169         * svg/SVGAnimatedTemplate.h: needed a HashMap define
1170
1171 2008-10-21  Eric Seidel  <eric@webkit.org>
1172
1173         Reviewed by Dave Hyatt.
1174
1175         Infinite recursion crash in WebCore::RenderSVGRoot::absoluteClippedOverflowRect on a <stop> element outside of a gradient block
1176         https://bugs.webkit.org/show_bug.cgi?id=20400
1177
1178         Test: svg/custom/stop-crash.svg
1179
1180         * WebCore.xcodeproj/project.pbxproj:
1181         * rendering/RenderSVGGradientStop.h:
1182         (WebCore::RenderSVGGradientStop::absoluteClippedOverflowRect):
1183
1184 2008-10-27  Anders Carlsson  <andersca@apple.com>
1185
1186         Reviewed by Sam Weinig.
1187
1188         No need to call release if the connection is null.
1189         
1190         * platform/network/mac/ResourceHandleMac.mm:
1191         (WebCore::ResourceHandle::start):
1192
1193 2008-10-27  Anders Carlsson  <andersca@apple.com>
1194
1195         Reviewed by Kevin Decker.
1196
1197         <rdar://problem/6322650> Crash in fast/loader/simultaneous-reloads-assert.html
1198         
1199         Make sure to null check the NSURLConnection object.
1200         
1201         * platform/network/mac/ResourceHandleMac.mm:
1202         (WebCore::ResourceHandle::start):
1203         (WebCore::ResourceHandle::setDefersLoading):
1204
1205 2008-10-27  Alexey Proskuryakov  <ap@webkit.org>
1206
1207         Fix non-Mac builds.
1208
1209         * GNUmakefile.am:
1210         * WebCore.pro:
1211         * WebCore.vcproj/WebCore.vcproj:
1212         * WebCoreSources.bkl:
1213         Renamed JSHTMLOptionElementConstructor to JSOptionConstructor.
1214
1215 2008-10-26  Alexey Proskuryakov  <ap@webkit.org>
1216
1217         Reviewed by Sam Weinig.
1218
1219         https://bugs.webkit.org/show_bug.cgi?id=21886
1220         window.HTMLOptionElement == "[object HTMLElementConstructor]" instead of HTMLOptionElementConstructor
1221
1222         Test: fast/dom/HTMLOptionElement/option-prototype.html
1223
1224         We now have separate objects for window.Option and window.HTMLOptionElement - the latter
1225         "constructor" cannot be used to construct anything. This matches Firefox behavior.
1226
1227         * WebCore.xcodeproj/project.pbxproj:
1228         * bindings/js/JSDOMWindowBase.cpp:
1229         (jsDOMWindowBaseOption):
1230         * bindings/js/JSHTMLOptionElementConstructor.cpp: Removed.
1231         * bindings/js/JSHTMLOptionElementConstructor.h: Removed.
1232         * bindings/js/JSOptionConstructor.cpp: Copied from WebCore/bindings/js/JSHTMLOptionElementConstructor.cpp.
1233         * bindings/js/JSOptionConstructor.h: Copied from WebCore/bindings/js/JSHTMLOptionElementConstructor.h.
1234         * html/HTMLOptionElement.idl:
1235         Renamed JSHTMLOptionElementConstructor to JSOptionConstructor.
1236
1237         * html/HTMLOptionElement.idl: Generate a constructor.
1238
1239 2008-10-25  Geoffrey Garen  <ggaren@apple.com>
1240
1241         Not reviewed.
1242         
1243         Try to fix Mac debug build on the buildbot.
1244
1245         * platform/FileChooser.cpp:
1246         (WebCore::FileChooserClient::~FileChooserClient):
1247         * platform/FileChooser.h: Moved destructor to .cpp file, to avoid a
1248         weak exported symbol.
1249
1250 2008-10-25  Jade Han  <jade.han@nokia.com>
1251
1252         Reviewed by Anders.
1253
1254         Enable custom properties for Qt runtime objects in QtWebKit
1255
1256         https://bugs.webkit.org/show_bug.cgi?id=21813
1257
1258         * bridge/runtime_object.cpp:
1259         (JSC::RuntimeObjectImp::getOwnPropertySlot):
1260         (JSC::RuntimeObjectImp::put):
1261
1262 2008-10-24  Sam Weinig  <sam@webkit.org>
1263
1264         Fix windows build.
1265
1266         * page/Chrome.cpp:
1267         * page/Chrome.h:
1268
1269 2008-10-24  Sam Weinig  <sam@webkit.org>
1270
1271         Fix Qt build.
1272
1273         * platform/qt/FileChooserQt.cpp:
1274
1275 2008-10-24  Sam Weinig  <sam@webkit.org>
1276
1277         Reviewed by Dan Bernstein.
1278
1279         Fix https://bugs.webkit.org/show_bug.cgi?id=21759
1280         Layering violation: FileChooser should not depend on Document/Frame/Page
1281
1282         Move file choosing into WebKit ChromeClient.
1283
1284         * loader/EmptyClients.h:
1285         (WebCore::EmptyChromeClient::runOpenPanel):
1286         * page/Chrome.cpp:
1287         (WebCore::Chrome::runOpenPanel):
1288         * page/Chrome.h:
1289         * page/ChromeClient.h:
1290         * page/mac/ChromeMac.mm:
1291         * platform/FileChooser.h:
1292         * platform/mac/FileChooserMac.mm:
1293         * platform/qt/FileChooserQt.cpp:
1294         * platform/win/FileChooserWin.cpp:
1295         * platform/wx/TemporaryLinkStubs.cpp:
1296         * rendering/RenderFileUploadControl.cpp:
1297         (WebCore::RenderFileUploadControl::click):
1298
1299 2008-10-24  Kevin Ollivier  <kevino@theolliviers.com>
1300
1301         wx build fix - add newIconForFiles stub.
1302
1303         * platform/wx/TemporaryLinkStubs.cpp:
1304         (Icon::newIconForFiles):
1305
1306 2008-10-24  Kevin Watters  <kevinwatters@gmail.com>
1307
1308         Reviewed by Kevin Ollivier.
1309
1310         Use the CGFont metrics APIs for more accurate measurements, and tweak the y
1311         value the text is drawn at (it was a couple pixels off before because wx
1312         internally adds to the y value.
1313
1314         https://bugs.webkit.org/show_bug.cgi?id=21853
1315
1316         * platform/wx/wxcode/mac/carbon/fontprops.cpp:
1317         (wxFontProperties::wxFontProperties):
1318         * platform/wx/wxcode/mac/carbon/non-kerned-drawing.cpp:
1319         (WebCore::drawTextWithSpacing):
1320
1321 2008-10-24  Eric Seidel  <eric@webkit.org>
1322
1323         Reviewed by Sam Weinig.
1324
1325         Generate missing constructors and add test to prevent missing ones in the future
1326         https://bugs.webkit.org/show_bug.cgi?id=21846
1327
1328         Test: fast/js/global-constructors.html
1329
1330         * css/CSSStyleSheet.idl:
1331         * css/RGBColor.idl:
1332         * dom/NodeIterator.idl:
1333         * dom/TreeWalker.idl:
1334         * xml/XPathExpression.idl:
1335
1336 2008-10-24  Alexey Proskuryakov  <ap@webkit.org>
1337
1338         Reviewed by Darin Adler.
1339
1340         https://bugs.webkit.org/show_bug.cgi?id=21836
1341         REGRESSION: Sign-in on Fancast.com causes crash in Webkit nightly
1342
1343         Test: http/tests/xmlhttprequest/detaching-frame.html
1344
1345         * xml/XMLHttpRequest.cpp: (WebCore::XMLHttpRequest::dropProtection): Null check the window -
1346         even though XHR needs a context (AKA frame) to be serviced, the frame may be disconnected
1347         when dispatching the same callback that results in this function being called.
1348
1349 2008-10-24  David Kilzer  <ddkilzer@apple.com>
1350
1351         Gtk build fix.
1352
1353         * platform/gtk/TemporaryLinkStubs.cpp:
1354         (WebCore::setFocusRingColorChangeFunction): Removed in r37858.
1355
1356 2008-10-24  Mark Rowe  <mrowe@apple.com>
1357
1358         Reviewed by Sam Weinig.
1359
1360         <rdar://problem/6164952> Use constant kCGInterpolationMedium in GraphicsContextCG.cpp rather than hard-coded values.
1361
1362         * platform/graphics/cg/GraphicsContextCG.cpp:
1363         (WebCore::GraphicsContext::setImageInterpolationQuality):
1364         (WebCore::GraphicsContext::imageInterpolationQuality):
1365
1366 2008-10-24  Anders Carlsson  <andersca@apple.com>
1367
1368         Reviewed by Sam Weinig.
1369
1370         <rdar://problem/5440917> Support NPN_Construct
1371                 
1372         * WebCore.NPAPI.exp:
1373         Export _NPN_Construct.
1374         
1375         * bridge/NP_jsobject.cpp:
1376         (_NPN_Construct):
1377         Implement this.
1378         
1379         * bridge/c/c_instance.cpp:
1380         (JSC::Bindings::CInstance::supportsConstruct):
1381         (JSC::Bindings::CInstance::invokeConstruct):
1382         Have this call the appropriate NPClass method.
1383         
1384         * bridge/npruntime.h:
1385         Add NPN_Construct.
1386
1387         * bridge/npruntime_impl.h:
1388         Add _NPN_Construct.
1389         
1390         * bridge/runtime.h:
1391         (JSC::Bindings::Instance::supportsConstruct):
1392         (JSC::Bindings::Instance::invokeConstruct):
1393         New methods.
1394         
1395         * bridge/runtime_object.cpp:
1396         (JSC::callRuntimeConstructor):
1397         Call the native instance.
1398         
1399         (JSC::RuntimeObjectImp::getConstructData):
1400         Implement this.
1401         
1402         * bridge/runtime_object.h:
1403         Add new method declarations.
1404         
1405         * plugins/gtk/PluginPackageGtk.cpp:
1406         (WebCore::PluginPackage::load):
1407         * plugins/qt/PluginPackageQt.cpp:
1408         (WebCore::PluginPackage::load):
1409         * plugins/win/PluginPackageWin.cpp:
1410         (WebCore::PluginPackage::load):
1411         Initialize m_pluginFuncs.construct.
1412
1413 2008-10-24  Adele Peterson  <adele@apple.com>
1414
1415         Build fix.
1416
1417         * platform/FileChooser.h: (WebCore::FileChooserClient::~FileChooserClient):
1418         * platform/graphics/mac/IconMac.mm: (WebCore::Icon::newIconForFiles):
1419
1420 2008-10-24  Greg Bolsinga  <bolsinga@apple.com>
1421
1422         Fix GTK build break.
1423
1424         Reviewed by David Kilzer.
1425
1426         * GNUmakefile.am: Do not include .idl files whose generated files should not be
1427         compiled.
1428
1429 2008-10-24  David Kilzer  <ddkilzer@apple.com>
1430
1431         Wx build fix.
1432
1433         * platform/wx/TemporaryLinkStubs.cpp:
1434         (WebCore::setFocusRingColorChangeFunction): Removed in r37858.
1435
1436 2008-10-24  Adele Peterson  <adele@apple.com>
1437
1438         Reviewed by Sam Weinig.
1439
1440         WebCore part of fix for <rdar://problem/5839256> FILE CONTROL: multi-file upload.
1441
1442         This change adds support for multiple file selection in an <input type="file"> control when the "multiple" attribute is used.
1443         This is consistent with the direction HTML5 will be going in the future.
1444
1445         The initial implementation here will show "n files" as the text next to the control when multiple files are selected.  You can view
1446         the individual files in a tooltip for now.  Improvements to this control will come later.  
1447
1448         Web developers will be able to access the FileList from the HTMLInputElement element, where they can get a base name and a size for each file.  
1449         These FileList Files can also be sent in an XMLHTTPRequest.
1450
1451         * manual-tests/post-multi-file-upload.html: Added.
1452         * manual-tests/resources/multiFileResources: Added.
1453         * manual-tests/resources/multiFileResources/post-echo-and-notify-done.cgi: Added.
1454         * manual-tests/resources/multiFileResources/testFile1.html: Added.
1455         * manual-tests/resources/multiFileResources/testFile2.html: Added.
1456         * manual-tests/resources/multiFileResources/testFile3.html: Added.
1457
1458         * WebCore.base.exp: Added support to export the new "chooseFilenames" method to be used in WebKit.
1459
1460         * html/HTMLInputElement.cpp:
1461         (WebCore::HTMLInputElement::parseMappedAttribute): Add support for the multiple attribute.
1462         (WebCore::HTMLInputElement::value): Added comments.  The HTML5 spec says that value shouldn't apply for the file upload control,
1463         but we don't want to break the behavior for existing websites that may rely on this.
1464         (WebCore::HTMLInputElement::setValue): ditto.
1465         (WebCore::HTMLInputElement::setValueFromRenderer): This is no longer used for file upload controls. setFileListFromRenderer is used instead.
1466         (WebCore::HTMLInputElement::setFileListFromRenderer): Added. 
1467         * html/HTMLInputElement.h:
1468
1469         * page/Chrome.cpp: (WebCore::Chrome::setToolTip): Show a tooltip with the file name list for the multi-file upload control.
1470
1471         * page/DragController.cpp: (WebCore::DragController::concludeDrag): Updated to support multiple files.
1472
1473         * platform/FileChooser.cpp: Add support for maintaining a list of file paths that can be retrieved by the renderer.
1474         (WebCore::FileChooser::FileChooser):
1475         (WebCore::FileChooser::create):
1476         (WebCore::FileChooser::clear):
1477         (WebCore::FileChooser::chooseFile):
1478         (WebCore::FileChooser::chooseFiles):
1479         (WebCore::FileChooser::chooseIcon):
1480         * platform/FileChooser.h:
1481         (WebCore::FileChooser::filePaths):
1482         (WebCore::FileChooser::allowsMultipleFiles):
1483
1484         * platform/graphics/Icon.h:
1485         * platform/graphics/mac/IconMac.mm: (WebCore::Icon::newIconForFiles): Returns a generic icon for multiple files.
1486         * platform/graphics/gtk/IconGtk.cpp: (WebCore::Icon::newIconForFiles): stubbed out.
1487         * platform/graphics/qt/IconQt.cpp: (WebCore::Icon::newIconForFiles): ditto.
1488         * platform/graphics/win/IconWin.cpp: (WebCore::Icon::newIconForFiles): ditto.
1489
1490         * platform/gtk/FileChooserGtk.cpp: (WebCore::FileChooser::basenameForWidth):  Updated to deal with new filenames vector.
1491         * platform/mac/FileChooserMac.mm: (WebCore::FileChooser::basenameForWidth): ditto.
1492         * platform/qt/FileChooserQt.cpp:
1493         (WebCore::FileChooser::openFileChooser):
1494         (WebCore::FileChooser::basenameForWidth):
1495         * platform/win/FileChooserWin.cpp: (WebCore::FileChooser::basenameForWidth):
1496
1497         * platform/network/mac/FormDataStreamMac.mm: (WebCore::disassociateStreamWithResourceHandle):
1498         Removed unnecessary assertion.  This can get hit when connectionDidFinishLoading and cancel
1499         both get called for the same ResourceHandle.  This getting called twice has no negative effect.
1500
1501         * rendering/RenderFileUploadControl.cpp:
1502         (WebCore::RenderFileUploadControl::valueChanged):  Calls setFileListFromRenderer.
1503         (WebCore::RenderFileUploadControl::allowsMultipleFiles):  Added.
1504         (WebCore::RenderFileUploadControl::updateFromElement):  Uses the new filenames call from FileChooser.
1505         (WebCore::RenderFileUploadControl::receiveDroppedFiles):  Updated to support multiple files.
1506         * rendering/RenderFileUploadControl.h:
1507
1508 2008-10-23  Peter Kasting  <pkasting@google.com>
1509
1510         Reviewed by David Hyatt.
1511
1512         https://bugs.webkit.org/show_bug.cgi?id=21844
1513         Remove setFocusRingColorChangeFunction.
1514
1515         * page/Page.cpp:
1516         (WebCore::Page::Page):
1517         * platform/graphics/Color.h:
1518         * platform/graphics/mac/ColorMac.mm:
1519         (WebCore::focusRingColor):
1520         * platform/graphics/qt/GraphicsContextQt.cpp:
1521         * platform/graphics/win/ColorSafari.cpp:
1522
1523 2008-10-24  David Kilzer  <ddkilzer@apple.com>
1524
1525         Build fix for Qt.
1526
1527         Reviewed by Greg.
1528
1529         * WebCore.pro: Added missing *.idl files.
1530
1531 2008-10-24  Greg Bolsinga  <bolsinga@apple.com>
1532
1533         Reviewed by Sam Weinig.
1534
1535         https://bugs.webkit.org/show_bug.cgi?id=21475
1536         
1537         Provide support for the Geolocation API
1538         
1539         http://dev.w3.org/geo/api/spec-source.html
1540
1541         Test: geolocation/geolocation-not-implemented.html
1542
1543         * DerivedSources.make:
1544         * GNUmakefile.am: Added Geolocation support
1545         * WebCore.pro: Added Geolocation support
1546         * WebCore.vcproj/WebCore.vcproj: Added Geolocation support
1547         * WebCore.xcodeproj/project.pbxproj: Added Geolocation support
1548         * WebCoreSources.bkl: Added Geolocation support
1549         * bindings/js/JSCustomPositionCallback.cpp: Added.
1550         (WebCore::JSCustomPositionCallback::JSCustomPositionCallback):
1551         (WebCore::JSCustomPositionCallback::handleEvent):
1552         * bindings/js/JSCustomPositionCallback.h: Added.
1553         (WebCore::JSCustomPositionCallback::create):
1554         * bindings/js/JSCustomPositionErrorCallback.cpp: Added.
1555         (WebCore::JSCustomPositionErrorCallback::JSCustomPositionErrorCallback):
1556         (WebCore::JSCustomPositionErrorCallback::handleEvent):
1557         * bindings/js/JSCustomPositionErrorCallback.h: Added.
1558         (WebCore::JSCustomPositionErrorCallback::create):
1559         * bindings/js/JSDOMBinding.cpp: move markDOMObjectWrapper here from JSDOMWindowCustom
1560         (WebCore::markDOMObjectWrapper):
1561         * bindings/js/JSDOMBinding.h: move markDOMObjectWrapper here from JSDOMWindowCustom
1562         * bindings/js/JSDOMWindowCustom.cpp: move markDOMObjectWrapper to JSDOMBinding
1563         * bindings/js/JSGeolocationCustom.cpp: Added.
1564         (WebCore::JSGeolocation::getCurrentPosition):
1565         (WebCore::JSGeolocation::watchPosition):
1566         * bindings/js/JSNavigatorCustom.cpp: handle marking Geolocation
1567         (WebCore::JSNavigator::mark):
1568         * dom/Document.cpp:
1569         (WebCore::Document::Document):
1570         * dom/Document.h:
1571         (WebCore::Document::setUsingGeolocation):
1572         (WebCore::Document::usingGeolocation):
1573         * loader/FrameLoader.cpp: don't add to back forward cache if using Geolocation
1574         (WebCore::FrameLoader::canCachePage):
1575         * page/Geolocation.cpp: Added.
1576         (WebCore::Geolocation::GeoNotifier::GeoNotifier):
1577         (WebCore::Geolocation::GeoNotifier::timerFired):
1578         (WebCore::Geolocation::Geolocation):
1579         (WebCore::Geolocation::disconnectFrame):
1580         (WebCore::Geolocation::getCurrentPosition):
1581         (WebCore::Geolocation::watchPosition):
1582         (WebCore::Geolocation::clearWatch):
1583         (WebCore::Geolocation::stopUpdatingIfEmpty):
1584         (WebCore::Geolocation::sendErrorToOneShots):
1585         (WebCore::Geolocation::sendErrorToWatchers):
1586         (WebCore::Geolocation::sendPositionToOneShots):
1587         (WebCore::Geolocation::sendPositionToWatchers):
1588         (WebCore::Geolocation::handleError):
1589         (WebCore::Geolocation::geolocationServicePositionChanged):
1590         (WebCore::Geolocation::geolocationServiceErrorOccurred):
1591         * page/Geolocation.h: Added.
1592         (WebCore::Geolocation::create):
1593         (WebCore::Geolocation::~Geolocation):
1594         (WebCore::Geolocation::lastPosition):
1595         (WebCore::Geolocation::GeoNotifier::create):
1596         * page/Geolocation.idl: Added.
1597         * page/Geoposition.cpp: Added.
1598         (WebCore::Geoposition::toString):
1599         * page/Geoposition.h: Added.
1600         (WebCore::Geoposition::create):
1601         (WebCore::Geoposition::latitude):
1602         (WebCore::Geoposition::longitude):
1603         (WebCore::Geoposition::altitude):
1604         (WebCore::Geoposition::accuracy):
1605         (WebCore::Geoposition::altitudeAccuracy):
1606         (WebCore::Geoposition::heading):
1607         (WebCore::Geoposition::velocity):
1608         (WebCore::Geoposition::timestamp):
1609         (WebCore::Geoposition::Geoposition):
1610         * page/Geoposition.idl: Added.
1611         * page/Navigator.cpp:
1612         (WebCore::Navigator::disconnectFrame): disconnect Geolocation
1613         (WebCore::Navigator::geolocation): accessor for Geolocation
1614         * page/Navigator.h:
1615         (WebCore::Navigator::optionalGeolocation): accessor for Geolocation
1616         * page/Navigator.idl: accessor for Geolocation
1617         * page/PositionCallback.h: Added.
1618         (WebCore::PositionCallback::~PositionCallback):
1619         * page/PositionCallback.idl: Added.
1620         * page/PositionError.h: Added.
1621         (WebCore::PositionError::):
1622         (WebCore::PositionError::create):
1623         (WebCore::PositionError::code):
1624         (WebCore::PositionError::message):
1625         (WebCore::PositionError::PositionError):
1626         * page/PositionError.idl: Added.
1627         * page/PositionErrorCallback.h: Added.
1628         (WebCore::PositionErrorCallback::~PositionErrorCallback):
1629         * page/PositionErrorCallback.idl: Added.
1630         * page/PositionOptions.h: Added.
1631         (WebCore::PositionOptions::create):
1632         (WebCore::PositionOptions::enableHighAccuracy):
1633         (WebCore::PositionOptions::setEnableHighAccuracy):
1634         (WebCore::PositionOptions::timeout):
1635         (WebCore::PositionOptions::setTimeout):
1636         (WebCore::PositionOptions::PositionOptions):
1637         * page/PositionOptions.idl: Added.
1638         * platform/GeolocationService.cpp: Added.
1639         (WebCore::GeolocationService::GeolocationService):
1640         (WebCore::GeolocationService::positionChanged):
1641         (WebCore::GeolocationService::errorOccurred):
1642         * platform/GeolocationService.h: Added.
1643         (WebCore::GeolocationServiceClient::~GeolocationServiceClient):
1644         (WebCore::GeolocationServiceClient::geolocationServicePositionChanged):
1645         (WebCore::GeolocationServiceClient::geolocationServiceErrorOccurred):
1646         (WebCore::GeolocationService::~GeolocationService):
1647
1648 2008-10-24  Simon Fraser  <simon.fraser@apple.com>
1649
1650         Reviewed by Darin Adler
1651
1652         https://bugs.webkit.org/show_bug.cgi?id=21818
1653         
1654         Add HashTraits for AtomicString so that AtomicString can be used as
1655         the key for a HashMap or HashSet.
1656
1657         * GNUmakefile.am: add AtomicStringHash.h
1658         * WebCore.vcproj/WebCore.vcproj: add AtomicStringHash.h
1659         * WebCore.xcodeproj/project.pbxproj: add AtomicStringHash.h
1660         * platform/text/AtomicString.h:
1661         (WebCore::AtomicString::AtomicString):
1662         (WebCore::AtomicString::isHashTableDeletedValue):
1663             specialize DefaultHash for AtomicString to use AtomicStringHash
1664         * platform/text/AtomicStringHash.h: Added.
1665         * platform/text/StringImpl.cpp:
1666         (WebCore::StringImpl::StringImpl):
1667             compute the hash up-front for the empty string
1668         * platform/text/StringImpl.h:
1669         (WebCore::StringImpl::existingHash):
1670             method to get the hash without a test and branch, for callers like
1671             AtomicStringHash who can guarantee that the hash has already been computed.
1672
1673 2008-10-24  Simon Fraser  <simon.fraser@apple.com>
1674
1675         Reviewed by Sam Weinig
1676
1677         https://bugs.webkit.org/show_bug.cgi?id=21857
1678
1679         Add WebKitCSSKeyframeRule and WebKitCSSKeyframesRule to the
1680         switch in _wrapCSSRule.
1681         
1682         * bindings/objc/DOMCSS.mm:
1683         (+[DOMCSSRule _wrapCSSRule:WebCore::]):
1684
1685 2008-10-24  Adam Roben  <aroben@apple.com>
1686
1687         Windows build fix
1688
1689         * plugins/PluginView.cpp:
1690
1691 2008-10-24  Dan Bernstein  <mitz@apple.com>
1692
1693         Reviewed by Sam Weinig.
1694
1695         - fix https://bugs.webkit.org/show_bug.cgi?id=21851
1696           <rdar://problem/6304151> REGRESSION (r36513): Crash when removing a widget with percent height
1697
1698         Test: fast/replaced/percent-height-in-anonymous-block-widget.html
1699
1700         * rendering/RenderWidget.cpp:
1701         (WebCore::RenderWidget::destroy): Copied code added to
1702         RenderBox::destroy() in r36513 into this function.
1703
1704 2008-10-24  Timothy Hatcher  <timothy@apple.com>
1705
1706         Add a mechanism to ask the InspectorClient for key/value setting pairs.
1707         These settings can be strings, numbers, booleans or string vectors. The
1708         settings are also bridged to and from JavaScript.
1709
1710         https://bugs.webkit.org/show_bug.cgi?id=21856
1711
1712         Reviewed by Darin Adler.
1713
1714         * WebCore.base.exp: Expose the String CFStringRef constructor.
1715         * inspector/InspectorClient.h:
1716         (WebCore::InspectorClient::populateSetting): Added, pure virtual.
1717         (WebCore::InspectorClient::storeSetting): Ditto.
1718         (WebCore::InspectorClient::removeSetting): Ditto.
1719         * inspector/InspectorController.cpp:
1720         (WebCore::setting): Calls InspectorController::setting and wraps the result in script types.
1721         (WebCore::setSetting): Calls InspectorController::setSetting after converting from script types.
1722         (WebCore::InspectorController::InspectorController): Increment a global static
1723         to track the number of live InspectorControllers.
1724         (WebCore::InspectorController::~InspectorController): Decrement the global static
1725         that tracks the number of live InspectorControllers. Delete the setting cache if there
1726         are no more live controllers.
1727         (WebCore::InspectorController::setting): Check the cache and return the setting from there,
1728         otherwise make a new Setting and ask the client to populate it.
1729         (WebCore::InspectorController::setSetting): Change the cache and ask the client to store it.
1730         (WebCore::InspectorController::windowScriptObjectAvailable): Add setting and setSetting
1731         to the InspectorController script class.
1732         * inspector/InspectorController.h:
1733         (WebCore::InspectorController::Setting::Setting):
1734         (WebCore::InspectorController::Setting::operator=):
1735         (WebCore::InspectorController::Setting::type): Return m_type.
1736         (WebCore::InspectorController::Setting::string): Return m_string. Assert the type is correct.
1737         (WebCore::InspectorController::Setting::stringVector): Return m_stringVector.
1738         Assert the type is correct.
1739         (WebCore::InspectorController::Setting::doubleValue): Return m_simpleContent.m_double.
1740         Assert the type is correct.
1741         (WebCore::InspectorController::Setting::integerValue): Return m_simpleContent.m_integer.
1742         Assert the type is correct.
1743         (WebCore::InspectorController::Setting::booleanValue): Return m_simpleContent.m_boolean.
1744         Assert the type is correct.
1745         (WebCore::InspectorController::Setting::set): Overloaded for each data type, sets the right
1746         field and the type.
1747         * loader/EmptyClients.h:
1748         (WebCore::EmptyInspectorClient::populateSetting): Added, empty method.
1749         (WebCore::EmptyInspectorClient::storeSetting): Ditto.
1750         (WebCore::EmptyInspectorClient::removeSetting): Ditto.
1751
1752 2008-10-24  Cameron Zwarich  <zwarich@apple.com>
1753
1754         Reviewed by Sam Weinig.
1755
1756         Remove some C-style casts.
1757
1758         * html/HTMLViewSourceDocument.cpp:
1759         (WebCore::HTMLViewSourceDocument::addViewSourceToken):
1760
1761 2008-10-24  Darin Adler  <darin@apple.com>
1762
1763         - finish rolling out https://bugs.webkit.org/show_bug.cgi?id=21732
1764
1765         * bindings/js/JSAttrCustom.cpp:
1766         * bindings/js/JSCSSRuleCustom.cpp:
1767         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
1768         * bindings/js/JSCSSValueCustom.cpp:
1769         * bindings/js/JSCanvasPixelArrayCustom.h:
1770         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
1771         * bindings/js/JSClipboardCustom.cpp:
1772         * bindings/js/JSConsoleCustom.cpp:
1773         * bindings/js/JSCustomSQLStatementCallback.cpp:
1774         * bindings/js/JSCustomSQLStatementErrorCallback.cpp:
1775         * bindings/js/JSCustomSQLTransactionCallback.cpp:
1776         * bindings/js/JSCustomSQLTransactionErrorCallback.cpp:
1777         * bindings/js/JSCustomVoidCallback.cpp:
1778         * bindings/js/JSCustomVoidCallback.h:
1779         * bindings/js/JSCustomXPathNSResolver.cpp:
1780         * bindings/js/JSCustomXPathNSResolver.h:
1781         * bindings/js/JSDOMApplicationCacheCustom.cpp:
1782         * bindings/js/JSDOMBinding.cpp:
1783         * bindings/js/JSDOMBinding.h:
1784         * bindings/js/JSDOMWindowBase.cpp:
1785         * bindings/js/JSDOMWindowBase.h:
1786         * bindings/js/JSDOMWindowCustom.cpp:
1787         * bindings/js/JSDOMWindowCustom.h:
1788         * bindings/js/JSDOMWindowShell.cpp:
1789         * bindings/js/JSDOMWindowShell.h:
1790         * bindings/js/JSDatabaseCustom.cpp:
1791         * bindings/js/JSDedicatedWorkerCustom.cpp:
1792         * bindings/js/JSDocumentCustom.cpp:
1793         * bindings/js/JSElementCustom.cpp:
1794         * bindings/js/JSEventCustom.cpp:
1795         * bindings/js/JSEventListener.cpp:
1796         * bindings/js/JSEventTarget.cpp:
1797         * bindings/js/JSEventTarget.h:
1798         * bindings/js/JSEventTargetBase.h:
1799         * bindings/js/JSEventTargetNodeCustom.cpp:
1800         * bindings/js/JSHTMLAllCollection.h:
1801         * bindings/js/JSHTMLAppletElementCustom.cpp:
1802         * bindings/js/JSHTMLCollectionCustom.cpp:
1803         * bindings/js/JSHTMLDocumentCustom.cpp:
1804         * bindings/js/JSHTMLEmbedElementCustom.cpp:
1805         * bindings/js/JSHTMLFormElementCustom.cpp:
1806         * bindings/js/JSHTMLFrameElementCustom.cpp:
1807         * bindings/js/JSHTMLFrameSetElementCustom.cpp:
1808         * bindings/js/JSHTMLIFrameElementCustom.cpp:
1809         * bindings/js/JSHTMLInputElementCustom.cpp:
1810         * bindings/js/JSHTMLObjectElementCustom.cpp:
1811         * bindings/js/JSHTMLOptionsCollectionCustom.cpp:
1812         * bindings/js/JSHTMLSelectElementCustom.cpp:
1813         * bindings/js/JSHTMLSelectElementCustom.h:
1814         * bindings/js/JSHistoryCustom.cpp:
1815         * bindings/js/JSImageDataCustom.cpp:
1816         * bindings/js/JSInspectedObjectWrapper.cpp:
1817         * bindings/js/JSInspectedObjectWrapper.h:
1818         * bindings/js/JSInspectorCallbackWrapper.cpp:
1819         * bindings/js/JSInspectorCallbackWrapper.h:
1820         * bindings/js/JSJavaScriptCallFrameCustom.cpp:
1821         * bindings/js/JSLocationCustom.cpp:
1822         * bindings/js/JSMessagePortCustom.cpp:
1823         * bindings/js/JSMimeTypeArrayCustom.cpp:
1824         * bindings/js/JSNamedNodeMapCustom.cpp:
1825         * bindings/js/JSNamedNodesCollection.cpp:
1826         * bindings/js/JSNamedNodesCollection.h:
1827         * bindings/js/JSNavigatorCustom.cpp:
1828         * bindings/js/JSNodeCustom.cpp:
1829         * bindings/js/JSNodeFilterCondition.cpp:
1830         * bindings/js/JSNodeFilterCondition.h:
1831         * bindings/js/JSNodeFilterCustom.cpp:
1832         * bindings/js/JSNodeIteratorCustom.cpp:
1833         * bindings/js/JSNodeListCustom.cpp:
1834         * bindings/js/JSPluginArrayCustom.cpp:
1835         * bindings/js/JSPluginCustom.cpp:
1836         * bindings/js/JSPluginElementFunctions.cpp:
1837         * bindings/js/JSPluginElementFunctions.h:
1838         * bindings/js/JSQuarantinedObjectWrapper.cpp:
1839         * bindings/js/JSQuarantinedObjectWrapper.h:
1840         * bindings/js/JSRGBColor.cpp:
1841         * bindings/js/JSRGBColor.h:
1842         * bindings/js/JSSQLResultSetRowListCustom.cpp:
1843         * bindings/js/JSSQLTransactionCustom.cpp:
1844         * bindings/js/JSSVGElementInstanceCustom.cpp:
1845         * bindings/js/JSSVGLengthCustom.cpp:
1846         * bindings/js/JSSVGMatrixCustom.cpp:
1847         * bindings/js/JSSVGPathSegCustom.cpp:
1848         * bindings/js/JSSVGPathSegListCustom.cpp:
1849         * bindings/js/JSSVGPointListCustom.cpp:
1850         * bindings/js/JSSVGTransformListCustom.cpp:
1851         * bindings/js/JSStorageCustom.cpp:
1852         * bindings/js/JSStyleSheetCustom.cpp:
1853         * bindings/js/JSStyleSheetListCustom.cpp:
1854         * bindings/js/JSTextCustom.cpp:
1855         * bindings/js/JSTreeWalkerCustom.cpp:
1856         * bindings/js/JSXMLHttpRequestCustom.cpp:
1857         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
1858         * bindings/js/JSXSLTProcessorCustom.cpp:
1859         * bindings/js/ScheduledAction.cpp:
1860         * bindings/js/ScheduledAction.h:
1861         * bindings/js/ScriptController.cpp:
1862         * bindings/js/ScriptController.h:
1863         * bindings/objc/WebScriptObject.mm:
1864         * bindings/objc/WebScriptObjectPrivate.h:
1865         * bindings/scripts/CodeGeneratorJS.pm:
1866         * bridge/NP_jsobject.cpp:
1867         * bridge/c/c_instance.cpp:
1868         * bridge/c/c_instance.h:
1869         * bridge/c/c_runtime.cpp:
1870         * bridge/c/c_runtime.h:
1871         * bridge/c/c_utility.cpp:
1872         * bridge/c/c_utility.h:
1873         * bridge/jni/jni_instance.cpp:
1874         * bridge/jni/jni_instance.h:
1875         * bridge/jni/jni_jsobject.h:
1876         * bridge/jni/jni_jsobject.mm:
1877         * bridge/jni/jni_objc.mm:
1878         * bridge/jni/jni_runtime.cpp:
1879         * bridge/jni/jni_runtime.h:
1880         * bridge/jni/jni_utility.cpp:
1881         * bridge/jni/jni_utility.h:
1882         * bridge/objc/WebScriptObject.h:
1883         * bridge/objc/objc_class.h:
1884         * bridge/objc/objc_class.mm:
1885         * bridge/objc/objc_instance.h:
1886         * bridge/objc/objc_instance.mm:
1887         * bridge/objc/objc_runtime.h:
1888         * bridge/objc/objc_runtime.mm:
1889         * bridge/objc/objc_utility.h:
1890         * bridge/objc/objc_utility.mm:
1891         * bridge/qt/qt_class.cpp:
1892         * bridge/qt/qt_class.h:
1893         * bridge/qt/qt_instance.cpp:
1894         * bridge/qt/qt_instance.h:
1895         * bridge/qt/qt_runtime.cpp:
1896         * bridge/qt/qt_runtime.h:
1897         * bridge/runtime.cpp:
1898         * bridge/runtime.h:
1899         * bridge/runtime_array.cpp:
1900         * bridge/runtime_array.h:
1901         * bridge/runtime_method.cpp:
1902         * bridge/runtime_method.h:
1903         * bridge/runtime_object.cpp:
1904         * bridge/runtime_object.h:
1905         * bridge/testqtbindings.cpp:
1906         * inspector/JavaScriptCallFrame.cpp:
1907         * inspector/JavaScriptCallFrame.h:
1908         * inspector/JavaScriptProfile.cpp:
1909         * inspector/JavaScriptProfile.h:
1910         * inspector/JavaScriptProfileNode.cpp:
1911         * inspector/JavaScriptProfileNode.h:
1912         * loader/FrameLoader.cpp:
1913         * loader/FrameLoader.h:
1914         * page/Console.cpp:
1915         * page/Console.h:
1916         * plugins/MimeTypeArray.h:
1917         * plugins/Plugin.h:
1918         * plugins/PluginArray.h:
1919         * plugins/PluginView.cpp:
1920         * xml/XMLHttpRequest.cpp:
1921         Use JSValue* instead of JSValuePtr.
1922
1923 2008-10-24  Simon Hausmann  <hausmann@webkit.org>
1924
1925         Fix the Qt build.
1926
1927         * bridge/qt/qt_instance.cpp:
1928         (JSC::Bindings::QtField::valueFromInstance):
1929
1930 2008-10-24  David Kilzer  <ddkilzer@apple.com>
1931
1932         Rolled out r37840 and r37841.
1933
1934         * DerivedSources.make:
1935         * GNUmakefile.am:
1936         * WebCore.pro:
1937         * WebCore.vcproj/WebCore.vcproj:
1938         * WebCore.xcodeproj/project.pbxproj:
1939         * WebCoreSources.bkl:
1940         * bindings/js/JSCustomPositionCallback.cpp: Removed.
1941         * bindings/js/JSCustomPositionCallback.h: Removed.
1942         * bindings/js/JSCustomPositionErrorCallback.cpp: Removed.
1943         * bindings/js/JSCustomPositionErrorCallback.h: Removed.
1944         * bindings/js/JSDOMBinding.cpp:
1945         * bindings/js/JSDOMBinding.h:
1946         * bindings/js/JSDOMWindowCustom.cpp:
1947         (WebCore::markDOMObjectWrapper):
1948         * bindings/js/JSGeolocationCustom.cpp: Removed.
1949         * bindings/js/JSNavigatorCustom.cpp:
1950         * dom/Document.cpp:
1951         (WebCore::Document::Document):
1952         * dom/Document.h:
1953         * loader/FrameLoader.cpp:
1954         (WebCore::FrameLoader::canCachePage):
1955         * page/Geolocation.cpp: Removed.
1956         * page/Geolocation.h: Removed.
1957         * page/Geolocation.idl: Removed.
1958         * page/Geoposition.cpp: Removed.
1959         * page/Geoposition.h: Removed.
1960         * page/Geoposition.idl: Removed.
1961         * page/Navigator.cpp:
1962         (WebCore::Navigator::disconnectFrame):
1963         * page/Navigator.h:
1964         * page/Navigator.idl:
1965         * page/PositionCallback.h: Removed.
1966         * page/PositionCallback.idl: Removed.
1967         * page/PositionError.h: Removed.
1968         * page/PositionError.idl: Removed.
1969         * page/PositionErrorCallback.h: Removed.
1970         * page/PositionErrorCallback.idl: Removed.
1971         * page/PositionOptions.h: Removed.
1972         * page/PositionOptions.idl: Removed.
1973         * platform/GeolocationService.cpp: Removed.
1974         * platform/GeolocationService.h: Removed.
1975
1976 2008-10-23  David Kilzer  <ddkilzer@apple.com>
1977
1978         Attempt to fix GTK build.
1979
1980         * GNUmakefile.am: Added new *.idl files that were missing.
1981
1982 2008-10-23  Greg Bolsinga  <bolsinga@apple.com>
1983
1984         Reviewed by Sam Weinig.
1985
1986         https://bugs.webkit.org/show_bug.cgi?id=21475
1987         
1988         Provide support for the Geolocation API
1989         
1990         http://dev.w3.org/geo/api/spec-source.html
1991
1992         Test: geolocation/geolocation-not-implemented.html
1993
1994         * DerivedSources.make:
1995         * GNUmakefile.am: Added Geolocation support
1996         * WebCore.pro: Added Geolocation support
1997         * WebCore.vcproj/WebCore.vcproj: Added Geolocation support
1998         * WebCore.xcodeproj/project.pbxproj: Added Geolocation support
1999         * WebCoreSources.bkl: Added Geolocation support
2000         * bindings/js/JSCustomPositionCallback.cpp: Added.
2001         (WebCore::JSCustomPositionCallback::JSCustomPositionCallback):
2002         (WebCore::JSCustomPositionCallback::handleEvent):
2003         * bindings/js/JSCustomPositionCallback.h: Added.
2004         (WebCore::JSCustomPositionCallback::create):
2005         * bindings/js/JSCustomPositionErrorCallback.cpp: Added.
2006         (WebCore::JSCustomPositionErrorCallback::JSCustomPositionErrorCallback):
2007         (WebCore::JSCustomPositionErrorCallback::handleEvent):
2008         * bindings/js/JSCustomPositionErrorCallback.h: Added.
2009         (WebCore::JSCustomPositionErrorCallback::create):
2010         * bindings/js/JSDOMBinding.cpp: move markDOMObjectWrapper here from JSDOMWindowCustom
2011         (WebCore::markDOMObjectWrapper):
2012         * bindings/js/JSDOMBinding.h: move markDOMObjectWrapper here from JSDOMWindowCustom
2013         * bindings/js/JSDOMWindowCustom.cpp: move markDOMObjectWrapper to JSDOMBinding
2014         * bindings/js/JSGeolocationCustom.cpp: Added.
2015         (WebCore::JSGeolocation::getCurrentPosition):
2016         (WebCore::JSGeolocation::watchPosition):
2017         * bindings/js/JSNavigatorCustom.cpp: handle marking Geolocation
2018         (WebCore::JSNavigator::mark):
2019         * dom/Document.cpp:
2020         (WebCore::Document::Document):
2021         * dom/Document.h:
2022         (WebCore::Document::setUsingGeolocation):
2023         (WebCore::Document::usingGeolocation):
2024         * loader/FrameLoader.cpp: don't add to back forward cache if using Geolocation
2025         (WebCore::FrameLoader::canCachePage):
2026         * page/Geolocation.cpp: Added.
2027         (WebCore::Geolocation::GeoNotifier::GeoNotifier):
2028         (WebCore::Geolocation::GeoNotifier::timerFired):
2029         (WebCore::Geolocation::Geolocation):
2030         (WebCore::Geolocation::disconnectFrame):
2031         (WebCore::Geolocation::getCurrentPosition):
2032         (WebCore::Geolocation::watchPosition):
2033         (WebCore::Geolocation::clearWatch):
2034         (WebCore::Geolocation::stopUpdatingIfEmpty):
2035         (WebCore::Geolocation::sendErrorToOneShots):
2036         (WebCore::Geolocation::sendErrorToWatchers):
2037         (WebCore::Geolocation::sendPositionToOneShots):
2038         (WebCore::Geolocation::sendPositionToWatchers):
2039         (WebCore::Geolocation::handleError):
2040         (WebCore::Geolocation::geolocationServicePositionChanged):
2041         (WebCore::Geolocation::geolocationServiceErrorOccurred):
2042         * page/Geolocation.h: Added.
2043         (WebCore::Geolocation::create):
2044         (WebCore::Geolocation::~Geolocation):
2045         (WebCore::Geolocation::lastPosition):
2046         (WebCore::Geolocation::GeoNotifier::create):
2047         * page/Geolocation.idl: Added.
2048         * page/Geoposition.cpp: Added.
2049         (WebCore::Geoposition::toString):
2050         * page/Geoposition.h: Added.
2051         (WebCore::Geoposition::create):
2052         (WebCore::Geoposition::latitude):
2053         (WebCore::Geoposition::longitude):
2054         (WebCore::Geoposition::altitude):
2055         (WebCore::Geoposition::accuracy):
2056         (WebCore::Geoposition::altitudeAccuracy):
2057         (WebCore::Geoposition::heading):
2058         (WebCore::Geoposition::velocity):
2059         (WebCore::Geoposition::timestamp):
2060         (WebCore::Geoposition::Geoposition):
2061         * page/Geoposition.idl: Added.
2062         * page/Navigator.cpp:
2063         (WebCore::Navigator::disconnectFrame): disconnect Geolocation
2064         (WebCore::Navigator::geolocation): accessor for Geolocation
2065         * page/Navigator.h:
2066         (WebCore::Navigator::optionalGeolocation): accessor for Geolocation
2067         * page/Navigator.idl: accessor for Geolocation
2068         * page/PositionCallback.h: Added.
2069         (WebCore::PositionCallback::~PositionCallback):
2070         * page/PositionCallback.idl: Added.
2071         * page/PositionError.h: Added.
2072         (WebCore::PositionError::):
2073         (WebCore::PositionError::create):
2074         (WebCore::PositionError::code):
2075         (WebCore::PositionError::message):
2076         (WebCore::PositionError::PositionError):
2077         * page/PositionError.idl: Added.
2078         * page/PositionErrorCallback.h: Added.
2079         (WebCore::PositionErrorCallback::~PositionErrorCallback):
2080         * page/PositionErrorCallback.idl: Added.
2081         * page/PositionOptions.h: Added.
2082         (WebCore::PositionOptions::create):
2083         (WebCore::PositionOptions::enableHighAccuracy):
2084         (WebCore::PositionOptions::setEnableHighAccuracy):
2085         (WebCore::PositionOptions::timeout):
2086         (WebCore::PositionOptions::setTimeout):
2087         (WebCore::PositionOptions::PositionOptions):
2088         * page/PositionOptions.idl: Added.
2089         * platform/GeolocationService.cpp: Added.
2090         (WebCore::GeolocationService::GeolocationService):
2091         (WebCore::GeolocationService::positionChanged):
2092         (WebCore::GeolocationService::errorOccurred):
2093         * platform/GeolocationService.h: Added.
2094         (WebCore::GeolocationServiceClient::~GeolocationServiceClient):
2095         (WebCore::GeolocationServiceClient::geolocationServicePositionChanged):
2096         (WebCore::GeolocationServiceClient::geolocationServiceErrorOccurred):
2097         (WebCore::GeolocationService::~GeolocationService):
2098
2099 2008-10-23  Alp Toker  <alp@nuanti.com>
2100
2101         Fix typo in comment in previous commit. GTK -> GLIB
2102
2103         * platform/gtk/guriescape.c:
2104
2105 2008-10-23  Kalle Vahlman  <kalle.vahlman@movial.com>
2106
2107         Reviewed by Alp Toker.
2108
2109         https://bugs.webkit.org/show_bug.cgi?id=21824
2110         [GTK] FileSystem abstraction uses features from Glib 2.16
2111
2112         Wrap g_uri_unescape_string() to fix building with pre-2.16 Glib
2113
2114         * platform/gtk/guriescape.c:
2115         (unescape_character):
2116         (_webcore_g_uri_unescape_segment):
2117         (_webcore_g_uri_unescape_string):
2118         * platform/gtk/guriescape.h:
2119
2120 2008-10-23  Jan Michael Alonzo  <jmalonzo@webkit.org>
2121
2122         Fix Gtk build typo introduced in http://trac.webkit.org/changeset/37826.
2123
2124         * GNUmakefile.am:
2125
2126 2008-10-23  Darin Fisher  <darin@chromium.org>
2127
2128         Reviewed by Eric Seidel.
2129
2130         m_frame null checked but then dereferenced
2131         https://bugs.webkit.org/show_bug.cgi?id=21845
2132
2133         This error was found using a static analysis tool, and so I do not know
2134         how to produce a null m_frame on entry to this method.  Hence, I have
2135         not included a regression test.
2136
2137         * page/EventHandler.cpp:
2138         (WebCore::EventHandler::allowDHTMLDrag): Add an early return.
2139
2140 2008-10-23  Dan Bernstein  <mitz@apple.com>
2141
2142         Reviewed by Sam Weinig with no hesitation.
2143
2144         - fix the HTML/CSS case of https://bugs.webkit.org/show_bug.cgi?id=19839
2145           <rdar://problem/6304805> A PDF,RLE sequence that should be a no-op affects bidi reordering
2146
2147         Test: fast/text/bidi-embedding-pop-and-push-same.html
2148
2149         * platform/text/BidiResolver.h:
2150         (WebCore::BidiResolver::embed): Changed to only add the embedding
2151         operation to a vector of pending operations.
2152
2153         (WebCore::BidiResolver::lowerExplicitEmbeddingLevel): Added. Moved the
2154         code that used to be in the PDF case of embed() here, except the part
2155         that sets the context.
2156
2157         (WebCore::BidiResolver::raiseExplicitEmbeddingLevel): Added. Moved the
2158         code that used to be in the non-PDF case of embed() here, except the
2159         part the sets the context.
2160
2161         (WebCore::BidiResolver::commitExplicitEmbedding): Added. Processes the
2162         explicit embedding operations in the vector by creating an updated
2163         context and determining the old and new embedding levels. If the levels
2164         are not the same, calls {lower,raise}ExplicitEmbeddingLevel(). Always
2165         sets the context to the new one.
2166
2167         (WebCore::BidiResolver::createBidiRunsForLine): Added calls to
2168         commitExplicitEmbedding() after calling embed() and after calling
2169         increment().
2170
2171         * rendering/bidi.cpp:
2172         (WebCore::bidiFirst): Added calls to commitExplicitEmbedding() because
2173         this function increments the resolver.
2174
2175         (WebCore::RenderBlock::skipLeadingWhitespace): Ditto.
2176
2177 2008-10-23  Jan Michael Alonzo  <jmalonzo@webkit.org>
2178
2179         Gtk build fix. Not reviewed.
2180
2181         Add DNSCurl and DNSSoup to the Gtk build
2182
2183         * GNUmakefile.am:
2184         * platform/gtk/TemporaryLinkStubs.cpp:
2185         * platform/network/soup/DNSSoup.cpp: Copied from WebCore/platform/network/curl/DNSCurl.cpp.
2186         (WebCore::prefetchDNS):
2187
2188 2008-10-23  Eric Seidel  <eric@webkit.org>
2189
2190         Reviewed by Sam Weinig.
2191
2192         Un-break the Darwin build.
2193
2194         * platform/graphics/cg/GraphicsContextPlatformPrivateCG.h:
2195         * platform/graphics/cg/ImageCG.cpp:
2196
2197 2008-10-23  Darin Fisher  <darin@chromium.org>
2198
2199         Reviewed by Eric Seidel.
2200
2201         Fix forward decls to be struct instead of class.
2202         https://bugs.webkit.org/show_bug.cgi?id=21838
2203
2204         * rendering/style/StyleRareInheritedData.h:
2205         * rendering/style/StyleRareNonInheritedData.h:
2206
2207 2008-10-23  Brent Fulgham  <bfulgham@gmail.com>
2208
2209         Reviewed by Oliver Hunt.
2210
2211         * platform/network/curl/ResourceRequest.h:  A better implementation
2212           of CFURLRequest, rather than void*.  This gives better compatibility 
2213           with the WebKit.idl interface.
2214         (WebCore::ResourceRequest::cfURLRequest):
2215
2216 2008-10-23  Mike Pinkerton  <pinkerton@chromium.org>
2217
2218         Reviewed by Eric Seidel.
2219
2220         PLATFORM(CHROMIUM) uses CG the same way PLATFORM(MAC) does so fix
2221         ifdefs to reflect that.
2222
2223         * platform/graphics/cg/GraphicsContextPlatformPrivateCG.h:
2224         * platform/graphics/cg/ImageCG.cpp:
2225
2226 2008-10-23  Peter Kasting  <pkasting@google.com>
2227
2228         Reviewed by Adam Roben.
2229
2230         https://bugs.webkit.org/show_bug.cgi?id=21833
2231         Place JavaScript Debugger hooks under #if ENABLE(JAVASCRIPT_DEBUGGER).
2232
2233         * inspector/InspectorController.cpp:
2234         (WebCore::InspectorController::InspectorController):
2235         (WebCore::InspectorController::setWindowVisible):
2236         (WebCore::InspectorController::windowScriptObjectAvailable):
2237         (WebCore::InspectorController::close):
2238         * inspector/InspectorController.h:
2239         * page/Page.cpp:
2240         (WebCore::Page::Page):
2241
2242 2008-10-23  Kevin McCullough  <kmccullough@apple.com>
2243
2244         Reviewed by Tim Hatcher.
2245
2246         https://bugs.webkit.org/show_bug.cgi?id=21817
2247         Bug 21817: Manual profiler tests should be made into layout tests
2248
2249         -Moving the tests before diffing so that it's clear what changed.
2250
2251         * manual-tests/inspector/profiler-test-anonymous-event-handler.html: Removed.
2252         * manual-tests/inspector/profiler-test-anonymous-function-called-from-different-contexts.html: Removed.
2253         * manual-tests/inspector/profiler-test-anonymous-function-calls-built-in-functions.html: Removed.
2254         * manual-tests/inspector/profiler-test-anonymous-function-calls-eval.html: Removed.
2255         * manual-tests/inspector/profiler-test-apply.html: Removed.
2256         * manual-tests/inspector/profiler-test-built-in-function-calls-anonymous.html: Removed.
2257         * manual-tests/inspector/profiler-test-built-in-function-calls-user-defined-function.html: Removed.
2258         * manual-tests/inspector/profiler-test-call-nodelist-as-function.html: Removed.
2259         * manual-tests/inspector/profiler-test-calling-the-function-that-started-the-profiler-from-another-scope.html: Removed.
2260         * manual-tests/inspector/profiler-test-compare-multiple-profiles.html: Removed.
2261         * manual-tests/inspector/profiler-test-constructor.html: Removed.
2262         * manual-tests/inspector/profiler-test-dead-time.html: Removed.
2263         * manual-tests/inspector/profiler-test-deep-recursion.html: Removed.
2264         * manual-tests/inspector/profiler-test-document-dot-write.html: Removed.
2265         * manual-tests/inspector/profiler-test-event-handler.html: Removed.
2266         * manual-tests/inspector/profiler-test-execution-context-and-eval-on-same-line.html: Removed.
2267         * manual-tests/inspector/profiler-test-heavy-view.html: Removed.
2268         * manual-tests/inspector/profiler-test-inline-event-handler.html: Removed.
2269         * manual-tests/inspector/profiler-test-multiple-and-different-scoped-anonymous-function-calls.html: Removed.
2270         * manual-tests/inspector/profiler-test-multiple-and-different-scoped-function-calls.html: Removed.
2271         * manual-tests/inspector/profiler-test-multiple-frames.html: Removed.
2272         * manual-tests/inspector/profiler-test-multiple-windows.html: Removed.
2273         * manual-tests/inspector/profiler-test-nested-anonymous-functon.html: Removed.
2274         * manual-tests/inspector/profiler-test-nested-start-and-stop-profiler.html: Removed.
2275         * manual-tests/inspector/profiler-test-no-execution-context.html: Removed.
2276         * manual-tests/inspector/profiler-test-one-execution-context.html: Removed.
2277         * manual-tests/inspector/profiler-test-profile-calls-in-included-file.html: Removed.
2278         * manual-tests/inspector/profiler-test-profiling-from-a-nested-location-but-stop-profiling-outside-the-nesting.html: Removed.
2279         * manual-tests/inspector/profiler-test-profiling-from-a-nested-location.html: Removed.
2280         * manual-tests/inspector/profiler-test-simple-event-call.html: Removed.
2281         * manual-tests/inspector/profiler-test-simple-no-level-change.html: Removed.
2282         * manual-tests/inspector/profiler-test-start-and-stop-profiler-multiple-times.html: Removed.
2283         * manual-tests/inspector/profiler-test-start-and-stop-profiling-in-the-same-function.html: Removed.
2284         * manual-tests/inspector/profiler-test-start-but-dont-stop-profiling.html: Removed.
2285         * manual-tests/inspector/profiler-test-stop-profiling-after-setTimeout.html: Removed.
2286         * manual-tests/inspector/profiler-test-stop-then-function-call.html: Removed.
2287         * manual-tests/inspector/profiler-test-throw-exception-from-eval.html: Removed.
2288         * manual-tests/inspector/profiler-test-two-execution-contexts.html: Removed.
2289         * manual-tests/inspector/profiler-test-user-defined-function-calls-built-in-functions.html: Removed.
2290         * manual-tests/inspector/profiler-test-window-dot-eval.html: Removed.
2291         * manual-tests/inspector/resources/other-frame.html: Removed.
2292         * manual-tests/inspector/resources/other-window.html: Removed.
2293         * manual-tests/inspector/resources/profiler-test-JS-resources.js: Removed.
2294
2295 2008-10-23  Adam Barth  <abarth@webkit.org>
2296
2297         Reviewed by Sam Weinig.
2298
2299         https://bugs.webkit.org/show_bug.cgi?id=21826
2300
2301         Add accessor for SecurityOrigin::m_domainWasSetInDOM.
2302
2303         * page/SecurityOrigin.h:
2304         (WebCore::SecurityOrigin::domainWasSetInDOM):
2305
2306 2008-10-23  Darin Adler  <darin@apple.com>
2307
2308         - roll out https://bugs.webkit.org/show_bug.cgi?id=21732
2309
2310         * bindings/js/ScheduledAction.h:
2311         * inspector/InspectorController.cpp:
2312         ProtectedPtr<JSValue> instead of ProtectedPtr<JSValuePtr>.
2313
2314 2008-10-23  Simon Hausmann  <hausmann@webkit.org>
2315
2316         Fix the Qt build.
2317
2318         * bridge/qt/qt_runtime.cpp:
2319         (JSC::Bindings::QtConnectionObject::execute):
2320         * bridge/qt/qt_runtime.h:
2321         (JSC::Bindings::QtRuntimeMethod::createStructureID):
2322
2323 2008-10-23  Alexey Proskuryakov  <ap@webkit.org>
2324
2325         Reviewed by Maciej Stachowiak.
2326
2327         https://bugs.webkit.org/show_bug.cgi?id=21825
2328         JSDOMBinding should not blindly cast the global object to JSDOMWindow
2329
2330         * bindings/js/JSDOMGlobalObject.cpp:
2331         * bindings/js/JSDOMGlobalObject.h:
2332         * GNUmakefile.am:
2333         * WebCore.pro:
2334         * WebCore.vcproj/WebCore.vcproj:
2335         * WebCore.xcodeproj/project.pbxproj:
2336         * WebCoreSources.bkl:
2337         Added JSDOMGlobalObject, a base class to be used by both Window and worker contexts.
2338
2339         * bindings/js/JSDOMBinding.cpp:
2340         (WebCore::getCachedDOMStructure):
2341         (WebCore::cacheDOMStructure):
2342         (WebCore::getCachedDOMConstructor):
2343         (WebCore::cacheDOMConstructor):
2344         Cast to JSDOMGlobalObject, as DOM objects live in DOM global objects.
2345
2346         * bindings/js/JSDOMWindowBase.cpp:
2347         (WebCore::JSDOMWindowBase::JSDOMWindowBase):
2348         * bindings/js/JSDOMWindowBase.h:
2349         * bindings/js/JSDOMWindowCustom.cpp:
2350         (WebCore::JSDOMWindow::mark):
2351         Moved constructor and structure tracking to JSDOMGlobalObject.
2352
2353 2008-10-23  Adam Barth  <abarth@webkit.org>
2354
2355         Reviewed by Sam Weinig.
2356
2357         https://bugs.webkit.org/show_bug.cgi?id=21787
2358
2359         Update postMessage to send origin = "null" for non-serializable
2360         origins to match latest spec.  Merge SecurityOrigin::toString and
2361         SecurityOrigin::toHTTPOrigin because they are now the same.
2362
2363         Test: http/tests/security/postMessage/data-url-sends-null-origin.html
2364
2365         * loader/FrameLoader.cpp:
2366         (WebCore::FrameLoader::outgoingOrigin):
2367         (WebCore::FrameLoader::loadURL):
2368         (WebCore::FrameLoader::addHTTPOriginIfNeeded):
2369         (WebCore::FrameLoader::loadItem):
2370         * loader/loader.cpp:
2371         (WebCore::Loader::Host::servePendingRequests):
2372         * page/SecurityOrigin.cpp:
2373         (WebCore::SecurityOrigin::toString):
2374         * page/SecurityOrigin.h:
2375         * xml/XMLHttpRequest.cpp:
2376         (WebCore::XMLHttpRequest::makeSimpleCrossSiteAccessRequest):
2377         (WebCore::XMLHttpRequest::makeCrossSiteAccessRequestWithPreflight):
2378         (WebCore::XMLHttpRequest::handleAsynchronousPreflightResult):
2379         (WebCore::XMLHttpRequest::didReceiveResponsePreflight):
2380
2381 2008-10-22  David Kilzer  <ddkilzer@apple.com>
2382
2383         Bug 21781: WebCore::Settings should have a maximum decoded image size setting
2384
2385         <https://bugs.webkit.org/show_bug.cgi?id=21781>
2386
2387         Reviewed by Antti.
2388
2389         No tests since there is no change in behavior.
2390
2391         * loader/CachedImage.cpp:
2392         (WebCore::CachedImage::maximumDecodedImageSize): Added.  Returns
2393         WebCore::Settings::maximumDecodedImageSize() or 0 on error.
2394         (WebCore::CachedImage::data): Flag an error if the image being
2395         loaded is too big.
2396         * loader/CachedImage.h:
2397         (WebCore::CachedImage::maximumDecodedImageSize): Added declaration.
2398         * page/Settings.cpp:
2399         (WebCore::Settings::Settings): Initialize m_maximumDecodedImageSize
2400         to the maximum value of size_t.
2401         * page/Settings.h:
2402         (WebCore::Settings::setMaximumDecodedImageSize): Added method.
2403         (WebCore::Settings::maximumDecodedImageSize): Ditto.
2404
2405 2008-10-22  Mike Pinkerton  <pinkerton@chromium.org>
2406
2407         Reviewed by Dan Bernstein.
2408         Landed and tweaked a bit by Darin Adler.
2409
2410         - fix https://bugs.webkit.org/show_bug.cgi?id=21809
2411
2412         Remove PLATFORM(MAC) wrapping USE(ATSUI). It's redundant and inhibits 
2413         its use for PLATFORM(CHROMIUM) in the future.
2414
2415         * platform/graphics/SimpleFontData.h:
2416
2417 2008-10-22  David Smith  <catfish.man@gmail.com>
2418
2419         Reviewed by Anders Carlsson.
2420                
2421         https://bugs.webkit.org/show_bug.cgi?id=19974
2422         getElementsByClassName not live enough
2423
2424         Test: fast/dom/getElementsByClassName/015.html
2425
2426         * dom/StyledElement.cpp:
2427         (WebCore::StyledElement::classAttributeChanged): call dispatchSubtreeModifiedEvent()
2428
2429 2008-10-22  Darin Adler  <darin@apple.com>
2430
2431         Reviewed by Sam Weinig.
2432
2433         - fix https://bugs.webkit.org/show_bug.cgi?id=21294
2434           Bug 21294: Devirtualize getOwnPropertySlot()
2435
2436         * bindings/js/JSDOMWindowShell.h:
2437         (WebCore::JSDOMWindowShell::createStructureID): Added. Returns a structure without
2438         HasStandardGetOwnPropertySlot since this class overrides getOwnPropertySlot.
2439
2440         * bindings/js/JSInspectorCallbackWrapper.cpp:
2441         (WebCore::JSInspectorCallbackWrapper::wrap): Change to use a unique structure
2442         for this class rather than sharing nullProtoStructureID, which no longer exists.
2443
2444         * bindings/js/JSNamedNodesCollection.h:
2445         (WebCore::JSNamedNodesCollection::createStructureID): Added. Returns a structure without
2446         HasStandardGetOwnPropertySlot since this class overrides getOwnPropertySlot.
2447         * bindings/js/JSRGBColor.h:
2448         (WebCore::JSRGBColor::createStructureID): Ditto.
2449
2450         * bindings/scripts/CodeGeneratorJS.pm: Added createStructureID functions for the wrappers,
2451         constructors, and prototypes in any case where they override getOwnPropertySlot, without
2452         HasStandardGetOwnPropertySlot.
2453
2454         * bridge/objc/objc_runtime.h:
2455         (JSC::Bindings::ObjcFallbackObjectImp::createStructureID): Added. Returns a structure
2456         without HasStandardGetOwnPropertySlot since this class overrides getOwnPropertySlot.
2457         * bridge/qt/qt_runtime.h:
2458         (JSC::Bindings::QtRuntimeMethod::createStructureID): Ditto.
2459         * bridge/runtime_array.h:
2460         (JSC::RuntimeArray::createStructureID): Ditto.
2461         * bridge/runtime_method.h:
2462         (JSC::RuntimeMethod::createStructureID): Ditto.
2463         * bridge/runtime_object.h:
2464         (JSC::RuntimeObjectImp::createStructureID): Ditto.
2465
2466 2008-10-22  Brent Fulgham  <bfulgham@gmail.com>
2467
2468         Bring Windows Cairo Port's font handling in line with CG.
2469         http://bugs.webkit.org/show_bug.cgi?id=21812.
2470
2471         Reviewed by Adam Roben.
2472
2473         * platform/graphics/win/FontCacheWin.cpp:
2474         (WebCore::createGDIFont): Remove unnecessary special-case for Cairo
2475         TrueType font search. It should match CG in all font selections.
2476
2477 2008-10-22  Brent Fulgham  <bfulgham@gmail.com>
2478
2479         http://bugs.webkit.org/show_bug.cgi?id=21812.
2480         Bring Windows Cairo Port's font handling in line with CG.
2481
2482         Reviewed by David Hyatt.
2483
2484         * platform/graphics/win/FontCacheWin.cpp:
2485         (WebCore::createGDIFont):  Remove unnecessary special-case for Cairo TrueType font search.  It should match CG in all font selections.
2486
2487 2008-10-22  Brady Eidson  <beidson@apple.com>
2488
2489         Reviewed by Adam Roben
2490
2491         <rdar://6261773> - autocomplete="off" doesn't work on Windows
2492
2493         Visual Studio makes a poor decision regarding the combination of enums and bitfields, such that a 
2494         statement like "m_autocomplete = Off" followed by "return m_autocomplete == Off" would return "false" 
2495         instead of the much more correct "true."
2496         
2497         In the past we have worked around this by declaring the bitfield member as an unsigned instead 
2498         of the enum type.
2499
2500         For more discussion, see http://trac.webkit.org/changeset/25329
2501
2502         * html/HTMLInputElement.h:  Work around insane Visual Studio enum issue  *sigh*
2503
2504 2008-10-22  Kevin McCullough  <kmccullough@apple.com>
2505
2506         Reviewed by Oliver Hunt and Tim Hatcher.
2507
2508         https://bugs.webkit.org/show_bug.cgi?id=19225
2509         Bug 19225: JSProfiler: Create automated profiler tests
2510         - This change exports profiles on the console object so that they can be
2511         iterated over via JavaScript, and thus can be used in automated tests.
2512
2513         * bindings/js/JSConsoleCustom.cpp: Get the profiles and return an array
2514         that JS can use.
2515         (WebCore::JSConsole::profiles):
2516         * inspector/InspectorController.h: Use the new typedef.
2517         (WebCore::InspectorController::profiles):
2518         * page/Console.cpp: Keep our own array of profile objects.
2519         (WebCore::Console::profileEnd):
2520         * page/Console.h: Ditto.
2521         (WebCore::Console::profiles):
2522         * page/Console.idl: Expose the profiles to JS.
2523
2524 2008-10-22  David Hyatt  <hyatt@apple.com>
2525
2526         https://bugs.webkit.org/show_bug.cgi?id=21775
2527
2528         Convert buttons over to use the new Theme API on OS X.
2529
2530         Reviewed by Adam Roben
2531
2532         * platform/LengthBox.h:
2533         (WebCore::LengthBox::LengthBox):
2534         * platform/Theme.cpp:
2535         (WebCore::Theme::controlBorder):
2536         (WebCore::Theme::controlPadding):
2537         * platform/Theme.h:
2538         (WebCore::Theme::controlFont):
2539         (WebCore::Theme::controlSize):
2540         (WebCore::Theme::minControlSize):
2541         (WebCore::Theme::controlRequiresPreWhiteSpace):
2542         * platform/mac/ThemeMac.h:
2543         (WebCore::ThemeMac::controlRequiresPreWhiteSpace):
2544         * platform/mac/ThemeMac.mm:
2545         (WebCore::checkboxSize):
2546         (WebCore::radioSize):
2547         (WebCore::buttonSizes):
2548         (WebCore::buttonMargins):
2549         (WebCore::button):
2550         (WebCore::paintButton):
2551         (WebCore::ThemeMac::controlFont):
2552         (WebCore::ThemeMac::controlSize):
2553         (WebCore::ThemeMac::minControlSize):
2554         (WebCore::ThemeMac::controlBorder):
2555         (WebCore::ThemeMac::controlPadding):
2556         (WebCore::ThemeMac::inflateControlPaintRect):
2557         (WebCore::ThemeMac::paint):
2558         * rendering/RenderTheme.cpp:
2559         (WebCore::RenderTheme::adjustStyle):
2560         (WebCore::RenderTheme::paint):
2561         (WebCore::RenderTheme::controlStatesForRenderer):
2562         (WebCore::RenderTheme::isDefault):
2563         (WebCore::RenderTheme::adjustRadioStyle):
2564         * rendering/RenderTheme.h:
2565         (WebCore::RenderTheme::setRadioSize):
2566         * rendering/RenderThemeMac.h:
2567         * rendering/RenderThemeMac.mm:
2568         (WebCore::RenderThemeMac::adjustRepaintRect):
2569         (WebCore::menuListButtonSizes):
2570         (WebCore::RenderThemeMac::adjustMenuListStyle):
2571         * rendering/style/RenderStyle.h:
2572         (WebCore::InheritedFlags::paddingBox):
2573         (WebCore::InheritedFlags::setPaddingBox):
2574
2575 2008-10-22  Chris Marrin  <cmarrin@apple.com>
2576
2577         Reviewed by Dave Hyatt
2578
2579         Make sure that the AtomicString that identifies a set of animation keyframes
2580         stays live by keeping a copy in the WebKitCSSKeyframesRule.
2581         
2582         Also call styleSheetChanged() when the keyframes name changes, but
2583         add an internal method that doesn't call styleSheetChanged() for use
2584         during normal stylesheet parsing.
2585         
2586         Test: animations/change-keyframes-name.html
2587
2588         * css/CSSGrammar.y:
2589         * css/WebKitCSSKeyframesRule.cpp:
2590         (WebCore::WebKitCSSKeyframesRule::setName):
2591         * css/WebKitCSSKeyframesRule.h:
2592         (WebCore::WebKitCSSKeyframesRule::setNameInternal):
2593
2594 2008-10-22  Alexey Proskuryakov  <ap@webkit.org>
2595
2596         Reviewed by Sam Weinig.
2597
2598         https://bugs.webkit.org/show_bug.cgi?id=21791
2599         WebCore JS bindings should be able to use non-static hash tables for properties
2600
2601         Add a map for HashTables to WebCore JS client data.
2602
2603         This makes property access noticeably slower, so it is an opt-in. For classes that need to be
2604         supported in workers in forseeable future this is not critical.
2605
2606         * bindings/js/JSDOMBinding.cpp:
2607         (WebCore::DOMObjectHashTableMap::get):
2608         (WebCore::DOMObjectHashTableMap::mapFor):
2609         (WebCore::getHashTableForGlobalData):
2610         (WebCore::DOMObjectWrapperMap::mapFor):
2611         WebCore client data is now a class that contains both a DOM wrapper map and a property hash
2612         table one.
2613
2614         * bindings/js/JSDOMBinding.h: Added getHashTableForGlobalData() to query the hash table map.
2615
2616         * bindings/scripts/CodeGeneratorJS.pm: If the class has a NoStaticTables attribute, use
2617         JSDOMBinding map to access its property hash tables.
2618
2619         * dom/MessageChannel.idl:
2620         * dom/MessagePort.idl:
2621         Added NoStaticTables attribute.
2622
2623 2008-10-22  Gustavo Noronha Silva  <gns@gnome.org>
2624
2625         Reviewed by Timothy Hatcher.
2626
2627         Build failure because of missing include
2628         https://bugs.webkit.org/show_bug.cgi?id=21765
2629
2630         Build failure fix for WebKit/GTK+; added missing
2631         include (GOwnPtr.h)
2632
2633         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
2634
2635 2008-10-22  Alp Toker  <alp@nuanti.com>
2636
2637         Reviewed by Adam Roben.
2638
2639         Fix crashes on older GTK+ versions (2.8). gtk_widget_style_get()
2640         doesn't initialize values if the requested property doesn't exist, so
2641         initialize the values to the documented defaults before calling it
2642         where necessary. Additionally, avoid critical warnings by not calling
2643         gtk_widget_style_get() when we know the property isn't available.
2644
2645         Note that this is an imported source file which doesn't follow the
2646         WebKit coding style.
2647
2648         * platform/gtk/gtk2drawing.c:
2649         (moz_gtk_init):
2650         (moz_gtk_button_get_inner_border):
2651         (moz_gtk_combo_box_paint):
2652         (moz_gtk_toolbar_separator_paint):
2653         (moz_gtk_menu_separator_paint):
2654         (moz_gtk_get_widget_border):
2655         (moz_gtk_get_tab_scroll_arrow_size):
2656         (moz_gtk_get_toolbar_separator_width):
2657         (moz_gtk_get_menu_separator_height):
2658
2659 2008-10-22  Alp Toker  <alp@nuanti.com>
2660
2661         Fix build for Cairo 1.2.
2662
2663         * platform/graphics/cairo/GraphicsContextCairo.cpp:
2664         (WebCore::GraphicsContext::clipOut):
2665         * platform/gtk/RenderThemeGtk.cpp:
2666         (WebCore::paintMozWidget):
2667
2668 2008-10-22  Darin Fisher  <darin@chromium.org>
2669
2670         Reviewed by Eric Seidel.
2671
2672         A little more PLATFORM(CHROMIUM) in WebCore
2673         https://bugs.webkit.org/show_bug.cgi?id=21758
2674
2675         * page/AccessibilityObject.h:
2676         * platform/graphics/Icon.h:
2677
2678 2008-10-21  Alexey Proskuryakov  <ap@webkit.org>
2679
2680         Reviewed by Darin Adler.
2681
2682         Test: fast/events/message-channel-gc-3.html
2683
2684         https://bugs.webkit.org/show_bug.cgi?id=21769
2685         MessagePort should be GC protected if there are messages to be delivered
2686
2687         * dom/MessagePort.h: Removed pending activity count. Now we track if a close event is
2688         pending, and check if the queue is non-empty.
2689         (WebCore::MessagePort::workerContext): Added a stub implementation for a cross-heap GC bug
2690         fix (below).
2691
2692         * dom/MessagePort.cpp:
2693         (WebCore::CloseMessagePortTimer::fired):
2694         (WebCore::MessagePort::MessagePort):
2695         (WebCore::MessagePort::queueCloseEvent):
2696         (WebCore::MessagePort::dispatchCloseEvent):
2697         (WebCore::MessagePort::hasPendingActivity):
2698         Track message and close event activity separately.
2699
2700         * bindings/js/JSDOMBinding.cpp:
2701         (WebCore::markCrossHeapDependentObjectsForDocument): Fixed a bug in cross-heap GC that was
2702         causing same-heap ports to never be deleted.
2703
2704 2008-10-21  Dan Bernstein  <mitz@apple.com>
2705
2706         Reviewed by Sam Weinig.
2707
2708         - remove unreachable code
2709
2710         * platform/text/BidiResolver.h:
2711         (WebCore::::embed):
2712
2713 2008-10-21  Beth Dakin  <bdakin@apple.com>
2714
2715         Reviewed by Darin Adler.
2716
2717         Fix for https://bugs.webkit.org/show_bug.cgi?id=20352 
2718         REGRESSION(r31030-31055): Choosing "Print window" from frame set 
2719         prints blank page
2720         and corresponding: <rdar://problem/6142398>
2721
2722         viewHeight() and viewWidth() only return valuable information if we 
2723         are not printing. Everywhere else in the code, we make sure we are 
2724         not printing before we call these functions. Adding a check for 
2725         printing here fixes this bug, and framesets print again.
2726
2727         * rendering/RenderFrameSet.cpp:
2728         (WebCore::RenderFrameSet::layout):
2729
2730 2008-10-21  Yael Aharon <yael.aharon@nokia.com>
2731
2732         Reviewed by Simon.
2733
2734         Pixmap in canvas tag was not getting initialized.
2735
2736         See https://bugs.webkit.org/show_bug.cgi?id=21771
2737
2738         * platform/graphics/qt/ImageBufferQt.cpp:
2739         (WebCore::ImageBuffer::create):
2740
2741 2008-10-20  Simon Fraser  <simon.fraser@apple.com>
2742
2743         Reviewed by Dan Bernstein
2744
2745         Add a comment explaining layoutDelta(), and an assertion
2746         that checks that delta changes were correctly paired during layout.
2747         
2748         * rendering/RenderView.cpp:
2749         (WebCore::RenderView::layout):
2750         * rendering/RenderView.h:
2751
2752 2008-10-20  Timothy Hatcher  <timothy@apple.com>
2753
2754         Make auto-complete only suggest properties that are valid syntax
2755         when using dot-notation. Also when completing numeric properties,
2756         the quotes are omitted inside the brackets.
2757
2758         https://bugs.webkit.org/show_bug.cgi?id=21760
2759         https://bugs.webkit.org/show_bug.cgi?id=21761
2760
2761         Reviewed by Oliver Hunt.
2762
2763         * inspector/front-end/Console.js:
2764         (WebInspector.Console.prototype.completions): Skip properties that
2765         are not valid identifies when using dot-notation. And omit the quotes
2766         when completing numbers in bracket-notation.
2767
2768 2008-10-20  Timothy Hatcher  <timothy@apple.com>
2769
2770         Fixes the Profiles panel in the Web Inspector, which was broken by
2771         the JSValue base-class changes. Also renames some functions and
2772         variables in JavaScriptProfileNode.cpp that where title case.
2773
2774         https://bugs.webkit.org/show_bug.cgi?id=21764
2775
2776         Reviewed by Oliver Hunt.
2777
2778         * inspector/JavaScriptProfile.cpp:
2779         (WebCore::toJS): Use a JSObject pointer instead of JSValuePtr so the
2780         returned JSValuePtr will be treated as an object and not a value.
2781         * inspector/JavaScriptProfileNode.cpp:
2782         (WebCore::toJS): Ditto.
2783
2784 2008-10-20  Sam Weinig  <sam@webkit.org>
2785
2786         Reviewed by Anders Carlsson.
2787
2788         Remove FrameLoaderClient::detachedFromParent4.  It is no longer used by any port.
2789
2790         * loader/EmptyClients.h:
2791         (WebCore::EmptyFrameLoaderClient::detachedFromParent4):.
2792         * loader/FrameLoader.cpp:
2793         (WebCore::FrameLoader::detachFromParent):
2794         * loader/FrameLoaderClient.h:
2795
2796 2008-10-20  Antti Koivisto  <antti@apple.com>
2797
2798         Reviewed by Adele Peterson.
2799
2800         Fix https://bugs.webkit.org/show_bug.cgi?id=21763
2801         REGRESSION (r36108-r36113): Can't load picture content on wired.com galleries
2802         <rdar://problem/6285025
2803         
2804         If we get 304 response we need to explicitly check if that completes the frame load.
2805         
2806         No test case, simulating the condition is pretty difficult.
2807
2808         * loader/loader.cpp:
2809         (WebCore::Loader::Host::didReceiveResponse):
2810
2811 2008-10-20  Anders Carlsson  <andersca@apple.com>
2812
2813         Reviewed by Mark Rowe.
2814
2815         Work around <rdar://problem/6301728>.
2816         
2817         Don't assert that loads are deferred when we're using CFNetwork on Mac or Windows.
2818         
2819         * loader/MainResourceLoader.cpp:
2820         (WebCore::MainResourceLoader::didReceiveResponse):
2821         (WebCore::MainResourceLoader::didReceiveData):
2822         (WebCore::MainResourceLoader::didFinishLoading):
2823         (WebCore::MainResourceLoader::didFail):
2824
2825 2008-10-20  Beth Dakin  <bdakin@apple.com>
2826
2827         Reviewed by Adele Peterson.
2828
2829         Speculative fix for <rdar://problem/6242585> CrashTracer: [USER] 19 
2830         crashes in Safari at com.apple.WebCore
2831         WebCore::ScrollView::visibleContentRect const + 153
2832
2833         d->m_view can be null and is null-checked at other points in the 
2834         code. The logs indicate that this crash occurs when closing a 
2835         window containing a PDF, so in case where we crash, the PDF's view 
2836         is probably already null. So the fix is to simply add a null-check.
2837
2838         * page/Frame.cpp:
2839         (WebCore::Frame::selectionRect):
2840
2841 2008-10-20  Adele Peterson  <adele@apple.com>
2842
2843         Reviewed by Darin Adler.
2844
2845         * html/HTMLFormElement.cpp: (WebCore::HTMLFormElement::formData):
2846         Removed stray increment that would screw up any form with multiple files in it.
2847
2848 2008-10-20  Sam Weinig  <sam@webkit.org>
2849
2850         Rubber-stamped by David Hyatt.
2851
2852         Split LengthBox and LengthSize into their own files.
2853
2854         * GNUmakefile.am:
2855         * WebCore.vcproj/WebCore.vcproj:
2856         * WebCore.xcodeproj/project.pbxproj:
2857         * platform/Length.h:
2858         (WebCore::Length::blend):
2859         * platform/LengthBox.h: Copied from platform/Length.h.
2860         (WebCore::LengthBox::LengthBox):
2861         (WebCore::LengthBox::nonZero):
2862         * platform/LengthSize.h: Copied from platform/Length.h.
2863         (WebCore::LengthSize::LengthSize):
2864         (WebCore::LengthSize::setWidth):
2865         (WebCore::LengthSize::setHeight):
2866         (WebCore::LengthSize::height):
2867         * platform/Theme.h:
2868         * rendering/style/FillLayer.h:
2869         * rendering/style/NinePieceImage.h:
2870         (WebCore::NinePieceImage::NinePieceImage):
2871         * rendering/style/RenderStyle.h:
2872         * rendering/style/StyleDashboardRegion.h:
2873         * rendering/style/StyleSurroundData.h:
2874         * rendering/style/StyleVisualData.h:
2875
2876 2008-10-20  Dan Bernstein  <mitz@apple.com>
2877
2878         - Mac build fix
2879
2880         * WebCore.xcodeproj/project.pbxproj:
2881
2882 2008-10-20  Alp Toker  <alp@nuanti.com>
2883
2884         Fix autotools dist build target by listing recently added header
2885         files only. Not reviewed.
2886
2887         * GNUmakefile.am:
2888
2889 2008-10-20  David Hyatt  <hyatt@apple.com>
2890
2891         Clean up some USE(NEW_THEME) ifdefs (I botched one of them and have broken non-Mac platforms).  Also
2892         refactor some of the code that I put in ThemeMac to be cross-platform, since it was in RenderTheme.cpp
2893         originally.
2894
2895         ifdef some methods in RenderTheme.cpp also that are no longer needed with the new Theme.
2896
2897         Reviewed by Adam Roben
2898
2899         * WebCore.xcodeproj/project.pbxproj:
2900         * platform/Theme.cpp: Added.
2901         (WebCore::Theme::controlSupportsBorder):
2902         (WebCore::Theme::controlSupportsPadding):
2903         * platform/Theme.h:
2904         * platform/mac/ThemeMac.h:
2905         * platform/mac/ThemeMac.mm:
2906         * rendering/RenderTheme.cpp:
2907         (WebCore::RenderTheme::adjustStyle):
2908         * rendering/RenderTheme.h:
2909
2910 2008-10-20  David Hyatt  <hyatt@apple.com>
2911
2912         Rename LengthBox's members to have m_ in front of them.
2913
2914         Reviewed by Sam Weinig
2915
2916         * css/CSSComputedStyleDeclaration.cpp:
2917         (WebCore::valueForNinePieceImage):
2918         (WebCore::getPositionOffsetValue):
2919         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
2920         * css/CSSStyleSelector.cpp:
2921         (WebCore::CSSStyleSelector::mapNinePieceImage):
2922         * platform/Length.h:
2923         (WebCore::LengthBox::LengthBox):
2924         (WebCore::LengthBox::left):
2925         (WebCore::LengthBox::right):
2926         (WebCore::LengthBox::top):
2927         (WebCore::LengthBox::bottom):
2928         (WebCore::LengthBox::operator==):
2929         (WebCore::LengthBox::nonZero):
2930         * rendering/RenderObject.cpp:
2931         (WebCore::RenderObject::paintNinePieceImage):
2932         (WebCore::RenderObject::addDashboardRegions):
2933         * rendering/style/RenderStyle.cpp:
2934         (WebCore::positionedObjectMoved):
2935         (WebCore::RenderStyle::setClip):
2936         (WebCore::RenderStyle::noneDashboardRegions):
2937         * rendering/style/RenderStyle.h:
2938         (WebCore::InheritedFlags::left):
2939         (WebCore::InheritedFlags::right):
2940         (WebCore::InheritedFlags::top):
2941         (WebCore::InheritedFlags::bottom):
2942         (WebCore::InheritedFlags::clipLeft):
2943         (WebCore::InheritedFlags::clipRight):
2944         (WebCore::InheritedFlags::clipTop):
2945         (WebCore::InheritedFlags::clipBottom):
2946         (WebCore::InheritedFlags::marginTop):
2947         (WebCore::InheritedFlags::marginBottom):
2948         (WebCore::InheritedFlags::marginLeft):
2949         (WebCore::InheritedFlags::marginRight):
2950         (WebCore::InheritedFlags::paddingTop):
2951         (WebCore::InheritedFlags::paddingBottom):
2952         (WebCore::InheritedFlags::paddingLeft):
2953         (WebCore::InheritedFlags::paddingRight):
2954         (WebCore::InheritedFlags::setLeft):
2955         (WebCore::InheritedFlags::setRight):
2956         (WebCore::InheritedFlags::setTop):
2957         (WebCore::InheritedFlags::setBottom):
2958         (WebCore::InheritedFlags::setDashboardRegion):
2959         (WebCore::InheritedFlags::setClipLeft):
2960         (WebCore::InheritedFlags::setClipRight):
2961         (WebCore::InheritedFlags::setClipTop):
2962         (WebCore::InheritedFlags::setClipBottom):
2963         (WebCore::InheritedFlags::setMarginTop):
2964         (WebCore::InheritedFlags::setMarginBottom):
2965         (WebCore::InheritedFlags::setMarginLeft):
2966         (WebCore::InheritedFlags::setMarginRight):
2967         (WebCore::InheritedFlags::setPaddingTop):
2968         (WebCore::InheritedFlags::setPaddingBottom):
2969         (WebCore::InheritedFlags::setPaddingLeft):
2970         (WebCore::InheritedFlags::setPaddingRight):
2971
2972 2008-10-20  Timothy Hatcher  <timothy@apple.com>
2973
2974         Make the Resource panel perform graph updates atomically, so when resources
2975         are added the graph and summary graph update at the same time.
2976
2977         https://bugs.webkit.org/show_bug.cgi?id=21755
2978
2979         Reviewed by Kevin McCullough.
2980
2981         * inspector/front-end/Resource.js:
2982         (WebInspector.Resource.prototype.get startTime): Return -1 if the _startTime
2983         property is undefined, null or 0. This allows callers to check for -1 and not
2984         the other values when there is no startTime yet.
2985         (WebInspector.Resource.prototype.get responseReceivedTime): Ditto.
2986         (WebInspector.Resource.prototype.get endTime): Ditto.
2987         (WebInspector.Resource.prototype.get duration): Remove an extra empty line.
2988         (WebInspector.Resource.prototype.get latency): Ditto.
2989         (WebInspector.Resource.prototype.get contentLength): Return 0 if the _duration
2990         property is undefined or null. This allows callers to always assume a number.
2991         (WebInspector.Resource.prototype.get expectedContentLength): Ditto.
2992         (WebInspector.Resource.prototype.get errors): Simplify the case where there is
2993         no _errors property yet.
2994         (WebInspector.Resource.prototype.set errors): Remove the check if the new value
2995         if the same as the previous value, since there is no work to guard.
2996         (WebInspector.Resource.prototype.get warnings): Simplify the case where there is
2997         no _warnings property yet.
2998         (WebInspector.Resource.prototype.set warnings): Remove the check if the new value
2999         if the same as the previous value, since there is no work to guard.
3000         (WebInspector.Resource.CompareByResponseReceivedTime): Add cases for when the
3001         responseReceivedTime is -1.
3002         (WebInspector.Resource.CompareByEndTime): Add cases for when the endTime is -1.
3003         * inspector/front-end/ResourcesPanel.js:
3004         (WebInspector.ResourcesPanel.prototype.get searchableViews): If a resource does not
3005         have a _resourcesTreeElement yet, exclude it from the searchable views.
3006         (WebInspector.ResourcesPanel.prototype.set calculator): Set _staleResource to _resources
3007         and call refresh to refresh the entire graph.
3008         (WebInspector.ResourcesPanel.prototype.set needsRefresh): Set a timeout if the panel
3009         is visible that calls refresh.
3010         (WebInspector.ResourcesPanel.prototype.refresh): Create the resource tree element and
3011         graph for a resource if it hasn't been created yet. If the boundaries changed during
3012         the first stale resource pass, do a full pass of all resources when updating the graphs.
3013         (WebInspector.ResourcesPanel.prototype.reset): Remove the legend items.
3014         (WebInspector.ResourcesPanel.prototype.addResource): Don't create the tree element and
3015         graph, these are now created during the first refresh.
3016         (WebInspector.ResourcesPanel.prototype.removeResource): Null check _resourcesTreeElement.
3017         (WebInspector.ResourcesPanel.prototype.addMessageToResource): Ditto.
3018         (WebInspector.ResourcesPanel.prototype.clearMessages): Ditto.
3019         (WebInspector.ResourcesPanel.prototype.refreshResource): Remove most of the work, just
3020         add the resource to the _staleResources and set needsRefresh.
3021         (WebInspector.ResourcesPanel.prototype.recreateViewForResourceIfNeeded): Null check
3022         _resourcesTreeElement.
3023         (WebInspector.ResourcesPanel.prototype._sortResourcesIfNeeded): Remove code to clear
3024         the timeout used by the deleted _sortResourcesSoonIfNeeded. Remove call to removeChild
3025         since the insertBefore call will do it if needed.
3026         (WebInspector.ResourcesPanel.prototype._updateGraphDividersIfNeeded): Remove code to
3027         clear the timeout used by the deleted _updateGraphDividersSoonIfNeeded.
3028         (WebInspector.ResourcesPanel.prototype._updateSummaryGraph): Remove code to clear the
3029         timeout used by the deleted _updateSummaryGraphSoon. No need to remove the totalLegendLabel,
3030         since all the legend items are removed in one pass right before.
3031         (WebInspector.ResourcesPanel.prototype._changeSortingFunction): Set the sortingFunction
3032         before the calculator so the correct sortingFunction is there when a refresh happens.
3033         (WebInspector.ResourceTimeCalculator.prototype.computeBarGraphPercentages): Set start to 0
3034         when the startTime is -1, since that looks best visually. Also set middle and end
3035         to the start and middle (respectfully) when startAtZero. This looks best visually.
3036         (WebInspector.ResourceGraph): Start the graph as hidden until the first refresh.
3037         (WebInspector.ResourceGraph.prototype.refresh): Remove the hidden class.
3038
3039 2008-10-20  David Hyatt  <hyatt@apple.com>
3040
3041         https://bugs.webkit.org/show_bug.cgi?id=21733
3042
3043         Make sure that the haveMetadata flag is set to true for generated images from image buffers, so that
3044         no attempt is made to re-cache the frame from a non-existent image source.
3045
3046         Reviewed by Sam Weinig
3047
3048         * platform/graphics/cairo/ImageCairo.cpp:
3049         (WebCore::BitmapImage::BitmapImage):
3050         * platform/graphics/cg/ImageCG.cpp:
3051         (WebCore::BitmapImage::BitmapImage):
3052
3053 2008-10-20  Dan Bernstein  <mitz@apple.com>
3054
3055         Reviewed by John Sullivan.
3056
3057         - make hasARenderedDescendant() have internal linkage
3058
3059         * editing/CompositeEditCommand.cpp:
3060         (WebCore::hasARenderedDescendant):
3061
3062 2008-10-20  Chris Fleizach  <cfleizach@apple.com>
3063
3064         Reviewed by Jon Honeycutt
3065
3066         Fix a crash in Accessibility where a table section was being 
3067         referenced without first checking if it was null
3068
3069         https://bugs.webkit.org/show_bug.cgi?id=21721
3070
3071         Test: accessibility/table-nofirstbody.html
3072
3073         * page/AccessibilityTable.cpp:
3074         (WebCore::AccessibilityTable::addChildren):
3075
3076 2008-10-20  David Hyatt  <hyatt@apple.com>
3077
3078         Avoid some stderr spew from CG by checking if we have a decoder yet in ImageSourceCG.
3079
3080         Reviewed by Darin Adler
3081
3082         * platform/graphics/cg/ImageSourceCG.cpp:
3083         (WebCore::ImageSource::repetitionCount):
3084         (WebCore::ImageSource::frameDurationAtIndex):
3085
3086 2008-10-20  Alp Toker  <alp@nuanti.com>
3087
3088         Reviewed by Mark Rowe.
3089
3090         Fix the pthread conditionals in the FTP code to correctly define
3091         threadsafe *_r functions on Windows. Partly fixes the GTK+/Win32
3092         build.
3093
3094         * loader/FTPDirectoryDocument.cpp:
3095         * loader/FTPDirectoryParser.cpp:
3096
3097 2008-10-20  David Hyatt  <hyatt@apple.com>
3098
3099         https://bugs.webkit.org/show_bug.cgi?id=21751
3100
3101         Convert checkboxes and radio buttons on OS X over to the new Theme API.
3102
3103         Reviewed by Adam Roben
3104
3105         * css/CSSComputedStyleDeclaration.cpp:
3106         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
3107         * css/CSSStyleSelector.cpp:
3108         (WebCore::CSSStyleSelector::mapFillSize):
3109         * platform/Length.h:
3110         (WebCore::LengthSize::LengthSize):
3111         (WebCore::LengthSize::operator==):
3112         (WebCore::LengthSize::width):
3113         (WebCore::LengthSize::height):
3114         (WebCore::LengthSize::setWidth):
3115         (WebCore::LengthSize::setHeight):
3116         * platform/Theme.h:
3117         (WebCore::Theme::controlSize):
3118         (WebCore::Theme::controlSupportsBorder):
3119         (WebCore::Theme::controlSupportsPadding):
3120         (WebCore::Theme::paint):
3121         (WebCore::Theme::inflateControlPaintRect):
3122         * platform/ThemeTypes.h:
3123         (WebCore::):
3124         * platform/mac/ThemeMac.h:
3125         * platform/mac/ThemeMac.mm:
3126         (WebCore::):
3127         (WebCore::controlSizeForFont):
3128         (WebCore::sizeFromFont):
3129         (WebCore::setControlSize):
3130         (WebCore::updateStates):
3131         (WebCore::inflateRect):
3132         (WebCore::checkboxSizes):
3133         (WebCore::checkboxMargins):
3134         (WebCore::checkboxSize):
3135         (WebCore::checkbox):
3136         (WebCore::paintCheckbox):
3137         (WebCore::radioSizes):
3138         (WebCore::radioMargins):
3139         (WebCore::radioSize):
3140         (WebCore::radio):
3141         (WebCore::paintRadio):
3142         (WebCore::ThemeMac::baselinePositionAdjustment):
3143         (WebCore::ThemeMac::controlSize):
3144         (WebCore::ThemeMac::controlSupportsBorder):
3145         (WebCore::ThemeMac::controlSupportsPadding):
3146         (WebCore::ThemeMac::inflateControlPaintRect):
3147         (WebCore::ThemeMac::paint):
3148         * rendering/RenderBox.cpp:
3149         (WebCore::RenderBox::calculateBackgroundSize):
3150         * rendering/RenderObject.cpp:
3151         (WebCore::mustRepaintFillLayers):
3152         * rendering/RenderTheme.cpp:
3153         (WebCore::RenderTheme::adjustStyle):
3154         (WebCore::RenderTheme::paint):
3155         (WebCore::RenderTheme::baselinePosition):
3156         (WebCore::RenderTheme::adjustRepaintRect):
3157         (WebCore::RenderTheme::controlStatesForRenderer):
3158         (WebCore::RenderTheme::isFocused):
3159         * rendering/RenderTheme.h:
3160         * rendering/RenderThemeMac.h:
3161         * rendering/RenderThemeMac.mm:
3162         (WebCore::RenderThemeMac::adjustRepaintRect):
3163         * rendering/style/FillLayer.cpp:
3164         (WebCore::FillLayer::operator==):
3165
3166 2008-10-18  Geoffrey Garen  <ggaren@apple.com>
3167
3168         Reviewed by Darin Adler.
3169
3170         Fixed https://bugs.webkit.org/show_bug.cgi?id=21735
3171         Emit profiling instrumentation only if the Web Inspector's profiling
3172         feature is enabled
3173
3174         * bindings/js/JSDOMWindowBase.cpp:
3175         (WebCore::JSDOMWindowBase::supportsProfiling):
3176         * bindings/js/JSDOMWindowBase.h: Implemented the interface for specifying
3177         whether a target global object has the Web Inspector's profiling feature
3178         enabled.
3179
3180         * inspector/JavaScriptDebugServer.cpp:
3181         (WebCore::JavaScriptDebugServer::recompileAllJSFunctionsSoon):
3182         (WebCore::JavaScriptDebugServer::didAddListener):
3183         (WebCore::JavaScriptDebugServer::didRemoveListener):
3184         * inspector/JavaScriptDebugServer.h: Exported an API for recompiling, 
3185         used by the Settings object.
3186
3187         * page/Settings.cpp:
3188         (WebCore::Settings::Settings):
3189         (WebCore::Settings::setDeveloperExtrasEnabled):
3190         * page/Settings.h: Recompile when the developer menu is enabled/disabled
3191         for the first time, to add/remove profiling hooks. In the future, with
3192         better Web Inspector UI, we can do this on a page-by-page basis,
3193         instead of a global basis.
3194
3195 2008-10-20  David Hyatt  <hyatt@apple.com>
3196
3197         Move Length to platform/.
3198
3199         Reviewed by Adam Roben
3200
3201         * GNUmakefile.am:
3202         * WebCore.pro:
3203         * WebCore.vcproj/WebCore.vcproj:
3204         * WebCore.xcodeproj/project.pbxproj:
3205         * WebCoreSources.bkl:
3206         * platform/Length.cpp: Copied from rendering/Length.cpp.
3207         * platform/Length.h: Copied from rendering/Length.h.
3208
3209 2008-10-20  Darin Adler  <darin@apple.com>
3210
3211         - try to fix Qt build
3212
3213         * bridge/qt/qt_runtime.cpp:
3214         (JSC::Bindings::QtRuntimeMetaMethod::connectGetter): Add asObject calls.
3215         (JSC::Bindings::QtRuntimeMetaMethod::disconnectGetter): Ditto.
3216
3217 2008-10-20  Darin Adler  <darin@apple.com>
3218
3219         - try to fix Qt build
3220
3221         * bridge/qt/qt_instance.cpp:
3222         (JSC::Bindings::QtInstance::mark): Use JSValue* instead of JSValuePtr.
3223         (JSC::Bindings::QtField::valueFromInstance): Ditto.
3224         * bridge/qt/qt_instance.h: Ditto.
3225
3226 2008-10-20  Darin Adler  <darin@apple.com>
3227
3228         - try to fix Tiger build
3229
3230         * bridge/objc/objc_instance.mm:
3231         (ObjcInstance::invokeMethod): Add a const_cast to remove the unwanted
3232         volatile qualifier.
3233         (ObjcInstance::invokeDefaultMethod): Ditto.
3234         (ObjcInstance::getValueOfUndefinedField): Ditto.
3235         * bridge/objc/objc_runtime.mm:
3236         (JSC::Bindings::ObjcField::valueFromInstance): Ditto.
3237
3238 2008-10-20  Alexey Proskuryakov  <ap@webkit.org>
3239
3240         Reviewed by Darin Adler.
3241
3242         https://bugs.webkit.org/show_bug.cgi?id=21750
3243         Eliminate the notion of "temporary events"
3244
3245         We mark some events as temporary when dispatching, for the sole reason of
3246         manually calling forgetDOMObject when done dispatching.
3247
3248         There doesn't seem to be any reason to call it manually, as JSEvent destructor
3249         will do this automatically right away.
3250
3251         * bindings/js/ScriptController.cpp:
3252         * bindings/js/ScriptController.h:
3253         Removed ScriptController::finishedWithEvent(), which was called after dispatching
3254         a temporary event.
3255
3256         * dom/ContainerNode.cpp:
3257         (WebCore::dispatchChildInsertionEvents):
3258         (WebCore::dispatchChildRemovalEvents):
3259         * dom/EventTarget.h:
3260         * dom/EventTargetNode.cpp:
3261         (WebCore::EventTargetNode::dispatchEvent):
3262         (WebCore::EventTargetNode::dispatchGenericEvent):
3263         (WebCore::EventTargetNode::dispatchSubtreeModifiedEvent):
3264         (WebCore::EventTargetNode::dispatchWindowEvent):
3265         (WebCore::EventTargetNode::dispatchUIEvent):
3266         (WebCore::EventTargetNode::dispatchKeyEvent):
3267         (WebCore::EventTargetNode::dispatchMouseEvent):
3268         (WebCore::EventTargetNode::dispatchWheelEvent):
3269         (WebCore::EventTargetNode::dispatchWebKitAnimationEvent):
3270         (WebCore::EventTargetNode::dispatchWebKitTransitionEvent):
3271         (WebCore::EventTargetNode::dispatchEventForType):
3272         (WebCore::EventTargetNode::dispatchProgressEvent):
3273         (WebCore::EventTargetNode::dispatchStorageEvent):
3274         * dom/EventTargetNode.h:
3275         * dom/MessagePort.cpp:
3276         (WebCore::MessagePort::dispatchMessages):
3277         (WebCore::MessagePort::dispatchCloseEvent):
3278         (WebCore::MessagePort::dispatchEvent):
3279         * dom/MessagePort.h:
3280         * editing/Editor.cpp:
3281         (WebCore::Editor::dispatchCPPEvent):
3282         (WebCore::dispatchEditableContentChangedEvents):
3283         * editing/ReplaceSelectionCommand.cpp:
3284         (WebCore::ReplacementFragment::ReplacementFragment):
3285         * editing/TypingCommand.cpp:
3286         (WebCore::TypingCommand::insertText):
3287         * loader/appcache/DOMApplicationCache.cpp:
3288         (WebCore::DOMApplicationCache::dispatchEvent):
3289         (WebCore::DOMApplicationCache::callListener):
3290         * loader/appcache/DOMApplicationCache.h:
3291         * page/EventHandler.cpp:
3292         (WebCore::EventHandler::dispatchDragEvent):
3293         (WebCore::EventHandler::keyEvent):
3294         (WebCore::EventHandler::handleTextInputEvent):
3295         * page/FrameView.cpp:
3296         (WebCore::FrameView::scheduleEvent):
3297         (WebCore::FrameView::updateOverflowStatus):
3298         (WebCore::FrameView::dispatchScheduledEvents):
3299         * page/FrameView.h:
3300         * rendering/RenderLayer.cpp:
3301         (WebCore::RenderLayer::scrollToOffset):
3302         (WebCore::RenderLayer::updateOverflowStatus):
3303         * svg/SVGElement.cpp:
3304         (WebCore::SVGElement::sendSVGLoadEventIfPossible):
3305         * svg/SVGElementInstance.cpp:
3306         (WebCore::SVGElementInstance::dispatchEvent):
3307         * svg/SVGElementInstance.h:
3308         * xml/XMLHttpRequest.cpp:
3309         (WebCore::XMLHttpRequest::dispatchEvent):
3310         (WebCore::XMLHttpRequest::dispatchReadyStateChangeEvent):
3311         (WebCore::XMLHttpRequest::dispatchXMLHttpRequestProgressEvent):
3312         * xml/XMLHttpRequest.h:
3313         * xml/XMLHttpRequestUpload.cpp:
3314         (WebCore::XMLHttpRequestUpload::dispatchEvent):
3315         (WebCore::XMLHttpRequestUpload::dispatchXMLHttpRequestProgressEvent):
3316         * xml/XMLHttpRequestUpload.h:
3317         Don't pass the tempEvent boolean around.
3318
3319 2008-10-20  Alp Toker  <alp@nuanti.com>
3320
3321         Remove unused includes only. Partial GTK+/Win build fix.
3322
3323         * platform/graphics/gtk/SimpleFontDataPango.cpp:
3324
3325 2008-10-20  Alexey Proskuryakov  <ap@webkit.org>
3326
3327         Reviewed by Oliver Hunt.
3328
3329         https://bugs.webkit.org/show_bug.cgi?id=21705
3330         Implement Web Workers client-side API
3331
3332         The implementation is experimental, and disabled by default. It doesn't quite match the
3333         published draft, being influenced by further WHATWG discussions.
3334
3335         This only implements the client-side API, and does not actually create any threads or
3336         global contexts yet.
3337
3338         * DerivedSources.make: Added DedicatedWorker. SharedWorker is not implemented yet, as I'm
3339         still not sure if having separate classes for these helps at all.
3340
3341         * WebCore.xcodeproj/project.pbxproj: Added new files.
3342
3343         * bindings/js/JSDOMWindowBase.cpp:
3344         (jsDOMWindowBaseWorker):
3345         (WebCore::JSDOMWindowBase::put):
3346         (setJSDOMWindowBaseWorker):
3347         Added window.Worker constructor. Moved JSXSLTProcessorConstructor.h include out of ifdef
3348         to match prevailing style.
3349
3350         * bindings/js/JSDedicatedWorkerConstructor.cpp: Added.
3351         * bindings/js/JSDedicatedWorkerConstructor.h: Added.
3352         * bindings/js/JSDedicatedWorkerCustom.cpp: Added.
3353         The implementation of event listeners are left custom intentionally, for easier implementation
3354         of listeners that are not tied to any Document in the future.
3355
3356         * dom/DedicatedWorker.cpp: Added.
3357         * dom/DedicatedWorker.h: Added.
3358         * dom/DedicatedWorker.idl: Added.
3359         Added an implementation that can only load requested scripts for now.
3360
3361 2008-10-19  Darin Adler  <darin@apple.com>
3362
3363         Reviewed by Dan Bernstein.
3364
3365         - fix assertion seen when opening inspector
3366
3367         * bindings/js/JSQuarantinedObjectWrapper.cpp:
3368         (WebCore::JSQuarantinedObjectWrapper::getOwnPropertySlot):
3369         Removed unneeded asObject cast.
3370
3371 2008-10-19  Dan Bernstein  <mitz@apple.com>
3372
3373         Rubber-stamped by Timothy Hatcher.
3374
3375         - remove empty directories and correct the MIME type of inspector images
3376
3377         * page/inspector: Removed.
3378         * page/inspector/Images: Removed.
3379
3380 2008-10-19  Timothy Hatcher  <timothy@apple.com>
3381
3382         Make the Web Inspector Resources panel open quicker and change graphs
3383         faster. There was some accidental n^2 logic at fault when updating the
3384         graph boundaries.
3385
3386         https://bugs.webkit.org/show_bug.cgi?id=21742
3387
3388         Reviewed by Darin Adler.
3389
3390         * inspector/front-end/ResourcesPanel.js:
3391         (WebInspector.ResourcesPanel.prototype.set calculator): Return early for
3392         a null calculator. Remove the second argument passed to _refreshAllResources.
3393         (WebInspector.ResourcesPanel.prototype.refresh): Call updateBoundaries on
3394         the calculator for all the stale resources before calling refreshResource.
3395         Pass true for the first argument of refreshResource to skip the boundary update.
3396         (WebInspector.ResourcesPanel.prototype._updateGraphBoundariesIfNeeded): Remove
3397         the second argument passed to _refreshAllResources.
3398         (WebInspector.ResourcesPanel.prototype._refreshAllResourcesSoon): Remove the
3399         skipSort argument since every passed true, and it would be bad to pass false.
3400         (WebInspector.ResourcesPanel.prototype._refreshAllResources): Ditto. And if
3401         skipBoundaryUpdate is false, call updateBoundaries on the calculator for all
3402         the resources before calling refreshResource. Pass true for the first argument
3403         of refreshResource to skip the boundary update.
3404
3405 2008-10-19  Timothy Hatcher  <timothy@apple.com>
3406
3407         Visually distinguish resources that loaded from the memory cache.
3408
3409         https://bugs.webkit.org/show_bug.cgi?id=14279
3410
3411         Reviewed by Dan Bernstein.
3412
3413         * English.lproj/localizedStrings.js: New string.
3414         * inspector/front-end/Images/timelineHollowPillBlue.png: Added.
3415         * inspector/front-end/Images/timelineHollowPillGray.png: Added.
3416         * inspector/front-end/Images/timelineHollowPillGreen.png: Added.
3417         * inspector/front-end/Images/timelineHollowPillOrange.png: Added.
3418         * inspector/front-end/Images/timelineHollowPillPurple.png: Added.
3419         * inspector/front-end/Images/timelineHollowPillRed.png: Added.
3420         * inspector/front-end/Images/timelineHollowPillYellow.png: Added.
3421         * inspector/front-end/ResourcesPanel.js:
3422         (WebInspector.ResourceCalculator.prototype.computeBarGraphLabels):
3423         Add the "(from cache)" suffix to the tooltip.
3424         (WebInspector.ResourceTimeCalculator.prototype.computeBarGraphLabels):
3425         Add the "(from cache)" suffix to the tooltip.
3426         (WebInspector.ResourceGraph): Add the "resource-cached" class.
3427         * inspector/front-end/inspector.css: New styles to make the timeline
3428         bars use the hollow pill images.
3429
3430 2008-10-19  Timothy Hatcher  <timothy@apple.com>
3431
3432         Update the scroll position in the Resources panel when loading
3433         a new page or toggling on small resource rows.
3434
3435         https://bugs.webkit.org/show_bug.cgi?id=20114
3436
3437         Reviewed by Darin Adler.
3438
3439         * inspector/front-end/ResourcesPanel.js:
3440         (WebInspector.ResourcesPanel.prototype.reset): Scroll to the top,
3441         since all the resource are being removed.
3442         (WebInspector.ResourcesPanel.prototype.removeResource): Call
3443         _adjustScrollPosition in case the view is shorter and needs scrolled.
3444         (WebInspector.ResourcesPanel.prototype._toggleLargerResources): Ditto.
3445         (WebInspector.ResourcesPanel.prototype._adjustScrollPosition): Check
3446         the height of the sidebar against the scrollTop and height of the
3447         resourcesContainerElement. If the sidebar is shorter, scroll up
3448         so the last resource is at the bottom again.
3449
3450 2008-10-19  Timothy Hatcher  <timothy@apple.com>
3451
3452         Show per resource times and sizes when hovering over the bar graph for a resource.
3453
3454         https://bugs.webkit.org/show_bug.cgi?id=14300
3455         rdar://problem/5712802
3456
3457         Reviewed by Cameron Zwarich.
3458
3459         * English.lproj/localizedStrings.js: Add new strings.
3460         * inspector/front-end/Images/graphLabelCalloutLeft.png: Added.
3461         * inspector/front-end/Images/graphLabelCalloutRight.png: Added.
3462         * inspector/front-end/ResourcesPanel.js:
3463         (WebInspector.ResourcesPanel.prototype.refreshResource): Pass the calculator to the
3464         ResourceGraph.refresh function.
3465         (WebInspector.ResourceCalculator.prototype.computeBarGraphLabels): Default implementation
3466         returns the formatted value.
3467         (WebInspector.ResourceTimeCalculator.prototype.computeBarGraphLabels): Return discrete values
3468         for the latency and download times. Also generate a custom tooltip.
3469         (WebInspector.ResourceGraph): Add a mouseover event listener that calls refreshLabelPositions.
3470         (WebInspector.ResourceGraph.prototype.refreshLabelPositions): Added. Updates the label positions
3471         in case the bar has changed size.
3472         (WebInspector.ResourceGraph.prototype.refresh): Set the label text and tooltips.
3473         * inspector/front-end/inspector.css: New styles for the labels.
3474
3475 2008-10-19  Darin Adler  <darin@apple.com>
3476
3477         Reviewed by Oliver Hunt.
3478
3479         - next step of https://bugs.webkit.org/show_bug.cgi?id=21732
3480           improve performance by eliminating JSValue as a base class for JSCell
3481
3482         Remove most uses of JSValue, which will be removed in a future patch.
3483
3484         * bindings/js/JSCustomXPathNSResolver.h: Removed declaration of JSValue
3485         and used JSValuePtr instead.
3486         * bindings/js/JSEventTarget.h: Ditto.
3487         * bindings/js/JSNodeFilterCondition.h: Ditto.
3488         * bindings/js/ScheduledAction.h: Ditto.
3489         * bindings/js/ScriptController.h: Ditto.
3490         * bindings/objc/WebScriptObjectPrivate.h: Ditto.
3491         * bridge/c/c_utility.h: Ditto.
3492         * bridge/jni/jni_jsobject.h: Ditto.
3493         * bridge/jni/jni_utility.h: Ditto.
3494         * bridge/objc/WebScriptObject.h: Ditto.
3495         * dom/Traversal.h: Ditto.
3496         * inspector/InspectorController.cpp: Ditto.
3497         * inspector/JavaScriptProfile.h: Ditto.
3498         * inspector/JavaScriptProfileNode.h: Ditto.
3499         * loader/FrameLoader.h: Ditto.
3500         * page/Console.h: Ditto.
3501         * plugins/MimeTypeArray.h: Ditto.
3502         * plugins/Plugin.h: Ditto.
3503         * plugins/PluginArray.h: Ditto.
3504         * plugins/PluginView.cpp:
3505         (WebCore::getString): Ditto.
3506         (WebCore::PluginView::performRequest): Ditto.
3507         * plugins/gtk/PluginViewGtk.cpp: Ditto.
3508         * plugins/qt/PluginViewQt.cpp: Ditto.
3509         * plugins/win/PluginViewWin.cpp: Ditto.
3510
3511         * bridge/qt/qt_class.cpp:
3512         (JSC::Bindings::QtClass::fallbackObject): Use JSValuePtr and JSObject*
3513         instead of JSValue*.
3514         * bridge/qt/qt_class.h: Ditto.
3515         * bridge/qt/qt_instance.cpp:
3516         (JSC::Bindings::QtInstance::mark): Ditto.
3517         (JSC::Bindings::QtInstance::invokeMethod): Ditto.
3518         (JSC::Bindings::QtInstance::defaultValue): Ditto.
3519         (JSC::Bindings::QtInstance::stringValue): Ditto.
3520         (JSC::Bindings::QtInstance::numberValue): Ditto.
3521         (JSC::Bindings::QtInstance::booleanValue): Ditto.
3522         (JSC::Bindings::QtInstance::valueOf): Ditto.
3523         (JSC::Bindings::QtField::valueFromInstance): Ditto.
3524         (JSC::Bindings::QtField::setValueToInstance): Ditto.
3525         * bridge/qt/qt_instance.h: Ditto.
3526         * bridge/qt/qt_runtime.cpp: Ditto.
3527         (JSC::Bindings::valueRealType): Ditto.
3528         (JSC::Bindings::convertValueToQVariant): Ditto.
3529         (JSC::Bindings::convertQVariantToValue): Ditto.
3530         (JSC::Bindings::findMethodIndex): Ditto.
3531         (JSC::Bindings::QtRuntimeMetaMethod::call): Ditto.
3532         (JSC::Bindings::QtRuntimeMetaMethod::lengthGetter): Ditto.
3533         (JSC::Bindings::QtRuntimeMetaMethod::connectGetter): Ditto.
3534         (JSC::Bindings::QtRuntimeMetaMethod::disconnectGetter): Ditto.
3535         (JSC::Bindings::QtRuntimeConnectionMethod::call): Ditto.
3536         (JSC::Bindings::QtRuntimeConnectionMethod::lengthGetter): Ditto.
3537         (JSC::Bindings::QtArray::setValueAt): Ditto.
3538         (JSC::Bindings::QtArray::valueAt): Ditto.
3539         * bridge/qt/qt_runtime.h: Ditto.
3540
3541         * bridge/testqtbindings.cpp:
3542         (main): Use JSValuePtr.
3543
3544 2008-10-18  Darin Adler  <darin@apple.com>
3545
3546         Reviewed by Oliver Hunt.
3547
3548         - next step of https://bugs.webkit.org/show_bug.cgi?id=21732
3549           improve performance by eliminating JSValue as a base class for JSCell
3550
3551         Tweak a little more to get closer to where we can make JSValuePtr a class.
3552
3553         * bindings/js/JSAudioConstructor.cpp:
3554         (WebCore::JSAudioConstructor::JSAudioConstructor): Use asObject.
3555         (WebCore::constructAudio): Ditto.
3556         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
3557         (WebCore::JSCSSStyleDeclaration::nameGetter): Ditto.
3558
3559         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
3560         (WebCore::toHTMLCanvasStyle): Use asString and asObject.
3561         (WebCore::JSCanvasRenderingContext2D::setFillColor): Ditto.
3562         (WebCore::JSCanvasRenderingContext2D::setStrokeColor): Ditto.
3563         (WebCore::JSCanvasRenderingContext2D::drawImage): Ditto.