2008-11-18 Dimitri Glazkov <dglazkov@chromium.org>
[WebKit-https.git] / WebCore / ChangeLog
1 2008-11-18  Dimitri Glazkov  <dglazkov@chromium.org>
2
3         Reviewed by Darin Adler.
4
5         https://bugs.webkit.org/show_bug.cgi?id=22346
6         PlatformString should also include HashSet.h for non-JSC builds
7
8         * platform/text/PlatformString.h:
9
10 2008-11-18  Adele Peterson  <adele@apple.com>
11
12         Reviewed by Holger Hans Peter Freyther.
13
14         Flip check added in recent refactoring so the background gets updated when the background color is valid, not invalid.
15
16         * loader/FrameLoaderClient.cpp: (WebCore::FrameLoaderClient::transitionToCommittedForNewPage):
17
18 2008-11-18  Dimitri Glazkov  <dglazkov@chromium.org>
19
20         Reviewed by Sam Weinig.
21
22         https://bugs.webkit.org/show_bug.cgi?id=22343
23         Remove unused runtime/Collector, JSLock includes in Page.cpp
24
25         * page/Page.cpp:
26
27 2008-11-18  Ada Chan  <adachan@apple.com>
28
29         Bug 22344: Make select popup window opaque
30         https://bugs.webkit.org/show_bug.cgi?id=22344
31
32         Reviewed by Steve Falkenburg.
33
34         * platform/win/PopupMenuWin.cpp:
35         (WebCore::PopupMenu::show):
36
37 2008-11-18  Dimitri Glazkov  <dglazkov@chromium.org>
38
39         Reviewed by Sam Weinig.
40
41         https://bugs.webkit.org/show_bug.cgi?id=22342
42         Remove unused JSLock.h include
43
44         * dom/Document.cpp:
45
46 2008-11-18  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
47
48         Reviewed by Sam Weinig.
49
50         Fixes: https://bugs.webkit.org/show_bug.cgi?id=22334
51
52         Add WMLBRElement, correcting <br/> behaviour in WML.
53         Enable entity replacment for WML documents.
54         Handle WML specific <p> 'mode' attribute.
55
56         Generate layout tests results for fast/wml.
57
58         Tests cases that pass now:
59         fast/wml/br-element-in-table.wml
60         fast/wml/br-element-in-text.wml
61         fast/wml/case-sensitivity.wml
62         fast/wml/cdata-section.wml
63         fast/wml/comment.wml
64         fast/wml/entity.wml
65         fast/wml/p-align.wml
66         fast/wml/p-mode.wml
67         fast/wml/text-emphasis.wml
68         fast/wml/validate-dtd.wml
69
70         * GNUmakefile.am:
71         * WebCore.pro:
72         * WebCore.xcodeproj/project.pbxproj:
73         * dom/XMLTokenizer.cpp:
74         (WebCore::XMLTokenizer::isWMLDocument):
75         (WebCore::XMLTokenizer::insertErrorMessageBlock):
76         * dom/XMLTokenizer.h:
77         * dom/XMLTokenizerLibxml2.cpp:
78         (WebCore::XMLTokenizer::internalSubset):
79         (WebCore::getEntityHandler):
80         * dom/XMLTokenizerQt.cpp:
81         (WebCore::XMLTokenizer::parse):
82         * wml/WMLBRElement.cpp: Added.
83         (WebCore::WMLBRElement::WMLBRElement):
84         (WebCore::WMLBRElement::mapToEntry):
85         (WebCore::WMLBRElement::parseMappedAttribute):
86         (WebCore::WMLBRElement::createRenderer):
87         * wml/WMLBRElement.h: Added.
88         * wml/WMLPElement.cpp:
89         (WebCore::WMLPElement::parseMappedAttribute):
90         (WebCore::WMLPElement::insertedIntoDocument):
91         * wml/WMLPElement.h:
92         * wml/WMLTagNames.in:
93
94 2008-11-18  Alexey Proskuryakov  <ap@webkit.org>
95
96         Windows build fix.
97
98         * WebCore.vcproj/WebCore.vcproj: Fix relative paths to use $(WebKitOutputDir).
99
100 2008-11-18  Darin Adler  <darin@apple.com>
101
102         - try to fix Wx build
103
104         * WebCoreSources.bkl: Added FrameLoaderClient.cpp.
105
106 2008-11-18  Alexey Proskuryakov  <ap@webkit.org>
107
108         Reviewed by Darin Adler.
109
110         https://bugs.webkit.org/show_bug.cgi?id=22337
111         Enable workers by default
112
113         Tests: fast/workers/worker-constructor.html
114                fast/workers/worker-event-listener.html
115                fast/workers/worker-gc.html
116                fast/workers/worker-location.html
117
118         * Configurations/WebCore.xcconfig:
119         * WebCore.vcproj/WebCore.vcproj:
120         * WebCore.vcproj/build-generated-files.sh:
121         Define ENABLE_WORKERS.
122
123 2008-11-18  Darin Adler  <darin@apple.com>
124
125         Reviewed by Alexey Proskuryakov.
126
127         - first cut at https://bugs.webkit.org/show_bug.cgi?id=10957
128           <rdar://problem/5516594> please add support for HTTP-only cookies
129
130         Test: http/tests/xmlhttprequest/get-dangerous-headers.html
131
132         No test for HTTP-only support in JavaScript yet, since the Mac and Win changes
133         require an updated CFNetwork.
134
135         * platform/mac/CookieJar.mm:
136         (WebCore::isHTTPOnly): Added.
137         (WebCore::filterCookies): Added.
138         (WebCore::cookies): Use filterCookies to prevent getting HTTP-only cookies.
139         (WebCore::setCookies): Use filterCookies to prevent setting HTTP-only cookies.
140
141         * platform/network/win/CookieJarCFNetWin.cpp:
142         (WebCore::isHTTPOnly): Added.
143         (WebCore::filterCookies): Added.
144         (WebCore::setCookies): Use filterCookies to prevent getting HTTP-only cookies.
145         (WebCore::cookies): Use filterCookies to prevent getting HTTP-only cookies.
146
147         * xml/XMLHttpRequest.cpp:
148         (WebCore::isSetCookieHeader): Added.
149         (WebCore::XMLHttpRequest::getAllResponseHeaders): Hide Set-Cookie headers from
150         clients that don't have local-resource privileges.
151         (WebCore::XMLHttpRequest::getResponseHeader): Ditto.
152
153         - clean soup-specific details out of shared cookie jar header
154
155         * platform/CookieJar.h: Removed the soup-specific parts of this.
156         * platform/network/soup/CookieJarSoup.cpp: Changed to include
157         CookieJarSoup.h. Tweaked implementation a bit to handle UTF-8 better.
158         * platform/network/soup/CookieJarSoup.h: Added. Has the Soup-specified
159         part of CookieJar.h.
160         * platform/network/soup/ResourceHandleSoup.cpp: Changed to include
161         CookieJarSoup.h.
162
163 2008-11-18  Steve Falkenburg  <sfalken@apple.com>
164
165         https://bugs.webkit.org/show_bug.cgi?id=22329
166         Improper bitwise and tests against 0 in Windows context menu code
167
168         Reviewed by John Sullivan.
169
170         * platform/win/ContextMenuItemWin.cpp:
171         (WebCore::ContextMenuItem::type):
172         (WebCore::ContextMenuItem::enabled):
173
174 2008-11-18  John Sullivan  <sullivan@apple.com>
175
176         Yet more Mac build fixing
177
178         * WebCore.base.exp: Export __ZTVN7WebCore17FrameLoaderClientE
179
180 2008-11-18  Tor Arne Vestbø  <tavestbo@trolltech.com>
181
182         Reviewed by Simon Hausmann.
183
184         React properly to frame rect changes for QWidget based plugins
185
186         We now set the geometry of the QWidget in frameRectsChanged,
187         intead of setFrameRect, which means we pick up the changes to
188         the frame rect when scrolling. We also set a mask on the
189         widget to keep it from painting over scrollbars and the like
190
191         * platform/qt/WidgetQt.cpp:
192         (WebCore::Widget::setFrameRect):
193
194 2008-11-18  Tor Arne Vestbø  <tavestbo@trolltech.com>
195
196         Rubber-stamped by Simon Hausmann.
197
198         Don't mark scrollbars as focused in QtWebKit
199
200         When initing from the widget we also got the focus state,
201         but this does not make sense for scrollbars.
202
203         * platform/qt/ScrollbarThemeQt.cpp:
204         (WebCore::styleOptionSlider):
205
206 2008-11-18  Alexey Proskuryakov  <ap@webkit.org>
207
208         More Mac build fixing.
209
210         * WebCore.base.exp: Export FrameLoaderClient destructor.
211
212 2008-11-18  Alexey Proskuryakov  <ap@webkit.org>
213
214         Mac build fix.
215
216         * WebCore.xcodeproj/project.pbxproj: Add FrameLoaderClient.cpp for now.
217
218 2008-11-18  Holger Hans Peter Freyther  <zecke@selfish.org>
219
220         Reviewed by Simon Hausmann.
221
222         https://bugs.webkit.org/show_bug.cgi?id=22056
223
224         Attempt to share transitionToCommittedForNewPage of FrameLoaderClient with the different ports
225
226         After Hyatt's work on Widget and ScrollView there is little difference
227         between the implementation of Qt, Gtk+ and Win. In fact any kind of
228         difference is mostly a bug. Alp has fixed two of such errors for the Gtk+
229         port and the Qt port has at least one of them left.
230
231         The only difference between the implementations is in getting the the
232         IntSize for the new FrameView, the background color to be applied and
233         eventually some post processing.
234
235         Unify the implementations by providing a static helper function that
236         takes a Frame, IntSize, color and transparency bit and calling it from
237         the Gtk+, the Qt and the Windows port.
238
239         * GNUmakefile.am:
240         * WebCore.pro:
241         * WebCore.vcproj/WebCore.vcproj:
242         * loader/FrameLoaderClient.cpp: Added.
243         (WebCore::FrameLoaderClient::~FrameLoaderClient):
244         (WebCore::FrameLoaderClient::transitionToCommittedForNewPage):
245         * loader/FrameLoaderClient.h:
246
247 2008-11-18  Holger Hans Peter Freyther  <zecke@selfish.org>
248
249         Reviewed by Simon Hausmann.
250
251         https://bugs.webkit.org/show_bug.cgi?id=22056
252
253         Move setting the background color and transparency from WebKit/win
254         to WebCore. This allows WebKit/win, WebKit/Qt and WebKit/Gtk+
255         to share this code.
256
257         * page/FrameView.cpp:
258         (WebCore::FrameView::updateBackgroundRecursively):
259         * page/FrameView.h:
260
261 2008-11-18  Ariya Hidayat  <ariya.hidayat@trolltech.com>
262
263         Reviewed by Tor Arne Vestbø.
264
265         Fix the bug where select elements are painted without border.
266         http://trolltech.com/developer/task-tracker/index_html?id=218957&method=entry
267
268         * platform/qt/RenderThemeQt.cpp:
269         (WebCore::RenderThemeQt::paintMenuList):
270
271 2008-11-18  Jan Michael Alonzo  <jmalonzo@webkit.org>
272
273         Gtk build fix. Not reviewed.
274
275         * GNUmakefile.am: Fix USER_AGENT_STYLESHEETS, wml.css is in css/,
276         not in wml/.
277
278 2008-11-18  Alexey Proskuryakov  <ap@webkit.org>
279
280         Reviewed by Darin Adler.
281
282         https://bugs.webkit.org/show_bug.cgi?id=22308
283         Improve Worker GC behavior
284
285         * dom/ActiveDOMObject.cpp: (WebCore::ActiveDOMObject::hasPendingActivity):
286         * dom/ActiveDOMObject.h:
287         Made hasPendingActivity() virtual, letting Worker add behavior to it.
288
289         * bindings/js/WorkerScriptController.cpp: (WebCore::WorkerScriptController::evaluate):
290         * dom/WorkerThread.cpp: (WebCore::WorkerThread::workerThread):
291         Tell message proxy whether there are active objects in the worker whenever JS execution
292         finishes.
293
294         * dom/ScriptExecutionContext.h: (WebCore::ScriptExecutionContext::activeDOMObjects):
295         Added a typedef for activeDOMObjects() return type, necessary to declare iterators.
296
297         * dom/Worker.h:
298         * dom/Worker.cpp: (WebCore::Worker::hasPendingActivity): A Worker is active if it is still
299         loading, or if it has unconfirmed messages, or it the worker thread has pending activity.
300
301         * dom/WorkerContext.h:
302         * dom/WorkerContext.cpp: (WebCore::WorkerContext::hasPendingActivity): Check all registered
303         active objects for pending activity.
304
305         * dom/WorkerMessagingProxy.cpp:
306         (WebCore::MessageWorkerContextTask::performTask):
307         (WebCore::WorkerThreadActivityReportTask::create):
308         (WebCore::WorkerThreadActivityReportTask::WorkerThreadActivityReportTask):
309         (WebCore::WorkerThreadActivityReportTask::performTask):
310         (WebCore::WorkerMessagingProxy::WorkerMessagingProxy):
311         (WebCore::WorkerMessagingProxy::postMessageToWorkerContext):
312         (WebCore::WorkerMessagingProxy::workerObjectDestroyed):
313         (WebCore::WorkerMessagingProxy::workerContextDestroyedInternal):
314         (WebCore::WorkerMessagingProxy::confirmWorkerThreadMessage):
315         (WebCore::WorkerMessagingProxy::reportWorkerThreadActivity):
316         (WebCore::WorkerMessagingProxy::reportWorkerThreadActivityInternal):
317         (WebCore::WorkerMessagingProxy::workerThreadHasPendingActivity):
318         * dom/WorkerMessagingProxy.h:
319         Track outstanding messages, and activity reported by worker thread.
320
321 2008-11-18  Alexey Proskuryakov  <ap@webkit.org>
322
323         Rubber-stamped by Darin Adler.
324
325         https://bugs.webkit.org/show_bug.cgi?id=22306
326         Disable channel messaging support
327
328         * bindings/js/JSDOMWindowBase.cpp:
329         (jsDOMWindowBaseMessageChannel):
330         * page/DOMWindow.idl:
331         Hide MesssagePort and MessageChannel global constructors. Due to the way MessageChannel
332         constructor is added, it remains enumerable, but undefined.
333
334 2008-11-17  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
335
336         Reviewed by Mark Rowe.
337
338         Remove WBXML code. MainResourceLoader is not an appropriate location.
339         Revert until we find a better place.
340
341         The mime type which belongs to wmlc should be enabled anyway so WML documents get build.
342         Remove the ENABLE(WBXML) blocks around these types in MIMETypeRegistry / DOMImplementation.
343
344         * WebCore.pro:
345         * dom/DOMImplementation.cpp:
346         (WebCore::DOMImplementation::createDocument):
347         * loader/MainResourceLoader.cpp:
348         (WebCore::MainResourceLoader::addData):
349         * platform/MIMETypeRegistry.cpp:
350         (WebCore::initializeSupportedNonImageMimeTypes):
351
352 2008-11-17  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
353
354         Not reviewed. Build fix.
355
356         Oops, disable WML by default on Qt.
357
358         * WebCore.pro:
359
360 2008-11-17  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
361
362         Reviewed by George Staikos.
363
364         Fixes: https://bugs.webkit.org/show_bug.cgi?id=22324 (Add basic subset of WML elements)
365
366         Add first bits of WML support. Only <card> & <p> and <a> elements are supported in this first patch.
367         Support for most other elements will be added step-by-step (merging in small chunks from a big patch).
368
369         WML is not build by default.
370
371         * DerivedSources.make: Handle WMLNames/WMLElementFactory generation.
372         * GNUmakefile.am: Add new files and generator hooks.
373         * WebCore.pro: Ditto.
374         * WebCore.xcodeproj/project.pbxproj: Ditto.
375         * css/CSSStyleSelector.cpp: Load wml.css on demand, just like it's done for SVG.
376         (WebCore::linkAttribute):
377         (WebCore::CSSStyleSelector::styleForElement):c
378         * css/wml.css: Added.
379         * dom/DOMImplementation.cpp: Handle WMLDocument creation
380         (WebCore::DOMImplementation::createDocument):
381         * dom/Document.cpp: Handle WMLElement creation.
382         (WebCore::Document::createElement):
383         * dom/Document.h: Add helper function identifying WML documents.
384         (WebCore::Document::isWMLDocument):
385         * dom/Node.h: Add heper function identifying WML elements.
386         (WebCore::Node::isWMLElement):
387         * dom/XMLTokenizer.cpp: Handle errors in WML documents
388         (WebCore::XMLTokenizer::insertErrorMessageBlock):
389         * dom/XMLTokenizerLibxml2.cpp: Add WML DTD checks.
390         (WebCore::XMLTokenizer::internalSubset):
391         * dom/XMLTokenizerQt.cpp: Ditto.
392         (WebCore::):
393         * dom/make_names.pl: Force internal linkage for the "tagConstructor" functions, avoiding SVG<->WML clashes.
394         * history/BackForwardList.cpp: Add WML specific function for clearing the history.
395         (WebCore::BackForwardList::clearWmlPageHistory):
396         * history/BackForwardList.h:
397         * loader/FrameLoader.cpp: Add WML specific 'shouldReload' logic.
398         (WebCore::FrameLoader::FrameLoader):
399         (WebCore::FrameLoader::setForceReloadWmlDeck):
400         (WebCore::FrameLoader::shouldReload):
401         (WebCore::FrameLoader::loadItem):
402         * loader/FrameLoader.h:
403         * loader/MainResourceLoader.cpp: Add WBXML support (only enabled on Linux/Qt at the moment)
404         (WebCore::MainResourceLoader::addData):
405         * page/Frame.cpp: Initialize WMLNames.
406         (WebCore::Frame::Frame):
407         * page/Page.cpp: Maintain WMLPageState object per Page.
408         (WebCore::Page::Page):
409         (WebCore::Page::setWMLPageState):
410         (WebCore::Page::wmlPageState):
411         * page/Page.h:
412         * platform/MIMETypeRegistry.cpp: Recognize WML extensions.
413         (WebCore::initializeSupportedNonImageMimeTypes):
414         * platform/gtk/MIMETypeRegistryGtk.cpp: Ditto.
415         (WebCore::MIMETypeRegistry::getMIMETypeForExtension):
416         * platform/qt/MIMETypeRegistryQt.cpp: Ditto.
417         (WebCore::):
418         * platform/win/MIMETypeRegistryWin.cpp: Ditto.
419         (WebCore::MIMETypeRegistry::getMIMETypeForExtension):
420         * manual-tests/wml: Added.
421         * manual-tests/wml/a-br-element.wml: Added.
422         * manual-tests/wml/a-element.wml: Added.
423         * manual-tests/wml/a-img-element.wml: Added.
424         * manual-tests/wml/access-target.wml: Added.
425         * manual-tests/wml/anchor-br-element.wml: Added.
426         * manual-tests/wml/anchor-element.wml: Added.
427         * manual-tests/wml/anchor-img-element.wml: Added.
428         * manual-tests/wml/card-newcontext-attr.wml: Added.
429         * manual-tests/wml/card-onenterbackward.wml: Added.
430         * manual-tests/wml/card-onenterforward.wml: Added.
431         * manual-tests/wml/card-ontimer.wml: Added.
432         * manual-tests/wml/deck-access-control.wml: Added.
433         * manual-tests/wml/go-element.wml: Added.
434         * manual-tests/wml/input-emptyok.wml: Added.
435         * manual-tests/wml/input-format.wml: Added.
436         * manual-tests/wml/onevent-go.wml: Added.
437         * manual-tests/wml/onevent-noop.wml: Added.
438         * manual-tests/wml/onevent-prev.wml: Added.
439         * manual-tests/wml/onevent-refresh.wml: Added.
440         * manual-tests/wml/onevent-shadow.wml: Added.
441         * manual-tests/wml/postfield-get.wml: Added.
442         * manual-tests/wml/postfield-post.wml: Added.
443         * manual-tests/wml/select-element.wml: Added.
444         * manual-tests/wml/select-onpick-event.wml: Added.
445         * manual-tests/wml/setvar-element.wml: Added.
446         * manual-tests/wml/targetdeck.wml: Added.
447         * manual-tests/wml/task-go-in-anchor.wml: Added.
448         * manual-tests/wml/task-noop-in-do.wml: Added.
449         * manual-tests/wml/task-noop-in-onevent.wml: Added.
450         * manual-tests/wml/task-prev-in-anchor.wml: Added.
451         * manual-tests/wml/task-refresh-in-anchor.wml: Added.
452         * manual-tests/wml/template-go.wml: Added.
453         * manual-tests/wml/template-onevent.wml: Added.
454         * manual-tests/wml/template-ontimer.wml: Added.
455         * manual-tests/wml/timer.wml: Added.
456         * manual-tests/wml/variable-substitution.wml: Added.
457         * wml: Added.
458         * wml/WMLAElement.cpp: Added.
459         (WebCore::WMLAElement::WMLAElement):
460         (WebCore::WMLAElement::parseMappedAttribute):
461         (WebCore::WMLAElement::supportsFocus):
462         (WebCore::WMLAElement::isFocusable):
463         (WebCore::WMLAElement::isMouseFocusable):
464         (WebCore::WMLAElement::isKeyboardFocusable):
465         (WebCore::WMLAElement::defaultEventHandler):
466         (WebCore::WMLAElement::accessKeyAction):
467         (WebCore::WMLAElement::isURLAttribute):
468         (WebCore::WMLAElement::target):
469         * wml/WMLAElement.h: Added.
470         * wml/WMLAttributeNames.in: Added.
471         * wml/WMLCardElement.cpp: Added.
472         (WebCore::WMLCardElement::WMLCardElement):
473         * wml/WMLCardElement.h: Added.
474         * wml/WMLDocument.cpp: Added.
475         (WebCore::WMLDocument::WMLDocument):
476         (WebCore::WMLDocument::~WMLDocument):
477         * wml/WMLDocument.h: Added.
478         (WebCore::WMLDocument::create):
479         (WebCore::WMLDocument::isWMLDocument):
480         * wml/WMLElement.cpp: Added.
481         (WebCore::WMLElement::WMLElement):
482         (WebCore::WMLElement::mapToEntry):
483         (WebCore::WMLElement::parseMappedAttribute):
484         (WebCore::WMLElement::rendererIsNeeded):
485         (WebCore::WMLElement::createRenderer):
486         * wml/WMLElement.h: Added.
487         (WebCore::WMLElement::isWMLElement):
488         * wml/WMLPElement.cpp: Added.
489         (WebCore::WMLPElement::WMLPElement):
490         (WebCore::WMLPElement::mapToEntry):
491         (WebCore::WMLPElement::parseMappedAttribute):
492         * wml/WMLPElement.h: Added.
493         * wml/WMLPageState.cpp: Added.
494         (WebCore::WMLPageState::WMLPageState):
495         (WebCore::WMLPageState::~WMLPageState):
496         (WebCore::WMLPageState::reset):
497         (WebCore::WMLPageState::setNeedCheckDeckAccess):
498         (WebCore::WMLPageState::isDeckAccessible):
499         * wml/WMLPageState.h: Added.
500         (WebCore::WMLPageState::storeVariable):
501         (WebCore::WMLPageState::storeVariables):
502         (WebCore::WMLPageState::getVaribale):
503         (WebCore::WMLPageState::hasVariables):
504         (WebCore::WMLPageState::historyLength):
505         (WebCore::WMLPageState::setHistoryLength):
506         (WebCore::WMLPageState::page):
507         (WebCore::WMLPageState::activeCard):
508         (WebCore::WMLPageState::setActiveCard):
509         (WebCore::WMLPageState::setDeckAccessDomain):
510         (WebCore::WMLPageState::setDeckAccessPath):
511         (WebCore::WMLPageState::hasDeckAccess):
512         * wml/WMLTagNames.in: Added.
513
514 2008-11-17  Geoffrey Garen  <ggaren@apple.com>
515
516         Reviewed by Sam Weinig.
517         
518         Updated for JavaScriptCore renames.
519
520         * WebCore.pro:
521         * webcore-base.bkl:
522
523 2008-11-17  Justin Garcia  <justin.garcia@apple.com>
524
525         Reviewed by Beth Dakin.
526
527         <rdar://problem/4922709> Copying less than a paragraph of quoted text and pasting it doesn't retain quote level
528         
529         There was code to intentionally avoid quoting pasted content if less than a paragraph of 
530         it was copied.  That was added for <rdar://problem/5006779>, but was unnecessary because
531         that bug was about Paste and Match style for single paragraphs.  And quote stripping for
532         Paste and Match style is handled elsewhere.
533
534         * editing/markup.cpp:
535         (WebCore::createMarkup):
536
537 2008-11-17  Geoffrey Garen  <ggaren@apple.com>
538
539         Reviewed by Sam Weinig.
540         
541         Updated for JavaScriptCore rename.
542
543         * ForwardingHeaders/interpreter/CallFrame.h: Copied from WebCore/ForwardingHeaders/runtime/ExecState.h.
544         * ForwardingHeaders/runtime/ExecState.h: Removed.
545         * bindings/objc/WebScriptObject.mm:
546         * bridge/c/c_instance.cpp:
547         * bridge/jni/jni_jsobject.mm:
548         * dom/Node.cpp:
549         * dom/NodeFilter.cpp:
550         * dom/NodeIterator.cpp:
551         * dom/TreeWalker.cpp:
552         * inspector/JavaScriptCallFrame.h:
553
554 2008-11-17  Pierre-Olivier Latour  <pol@apple.com>
555
556         Reviewed by Sam Weinig.
557
558         Added functionality to AnimationController to allow pausing a running
559         animation or transition at a given time for testing purposes.
560
561         https://bugs.webkit.org/show_bug.cgi?id=21261
562
563         Tests: animations/animation-drt-api.html
564                transitions/transition-drt-api.html
565
566         * WebCore.base.exp:
567         * WebCore.xcodeproj/project.pbxproj:
568         * page/animation/AnimationBase.cpp:
569         (WebCore::AnimationBase::updateStateMachine):
570         (WebCore::AnimationBase::progress):
571         (WebCore::AnimationBase::pauseAtTime):
572         * page/animation/AnimationBase.h:
573         * page/animation/AnimationController.cpp:
574         (WebCore::AnimationControllerPrivate::pauseAnimationAtTime):
575         (WebCore::AnimationControllerPrivate::pauseTransitionAtTime):
576         (WebCore::AnimationController::pauseAnimationAtTime):
577         (WebCore::AnimationController::pauseTransitionAtTime):
578         * page/animation/AnimationController.h:
579         * page/animation/CompositeAnimation.cpp:
580         (WebCore::CompositeAnimationPrivate::isAnimating):
581         (WebCore::CompositeAnimationPrivate::pauseAnimationAtTime):
582         (WebCore::CompositeAnimationPrivate::pauseTransitionAtTime):
583         (WebCore::CompositeAnimation::pauseAnimationAtTime):
584         (WebCore::CompositeAnimation::pauseTransitionAtTime):
585         * page/animation/CompositeAnimation.h:
586         * page/animation/ImplicitAnimation.cpp:
587         (WebCore::ImplicitAnimation::animate):
588
589 2008-11-17  Geoffrey Garen  <ggaren@apple.com>
590
591         Reviewed by Sam Weinig.
592         
593         Updated for JavaScriptCore renames.
594
595         * ForwardingHeaders/VM: Removed.
596         * ForwardingHeaders/VM/Machine.h: Removed.
597         * ForwardingHeaders/interpreter: Added.
598         * ForwardingHeaders/interpreter/Interpreter.h: Copied from ForwardingHeaders/VM/Machine.h.
599         * WebCore.pro:
600         * bindings/js/JSXMLHttpRequestCustom.cpp:
601         * page/Console.cpp:
602         * webcore-base.bkl:
603
604 2008-11-17  Geoffrey Garen  <ggaren@apple.com>
605
606         Reviewed by Sam Weinig.
607
608         Updated for JavaScriptCore renames.
609
610         * ForwardingHeaders/runtime/Interpreter.h: Removed.
611         * WebCore.vcproj/WebCore.vcproj:
612         * bindings/js/JSDOMBinding.h:
613         * bindings/js/WorkerScriptController.cpp:
614         * bindings/objc/WebScriptObject.mm:
615         * bridge/NP_jsobject.cpp:
616         * bridge/jni/jni_jsobject.mm:
617         * html/CanvasRenderingContext2D.cpp:
618         * inspector/JavaScriptCallFrame.cpp:
619         * page/Console.cpp:
620
621 2008-11-17  Geoffrey Garen  <ggaren@apple.com>
622
623         Not reviewed.
624
625         Try to fix wx build.
626
627         * webcore-base.bkl:
628
629 2008-11-17  Greg Bolsinga  <bolsinga@apple.com>
630
631         Reviewed by Darin Adler.
632
633         https://bugs.webkit.org/show_bug.cgi?id=21810
634         Remove use of static C++ objects that are destroyed at exit time (destructors)
635
636         Find some missing DEFINE_STATIC_LOCAL use cases.
637         
638         * bindings/js/JSSVGPODTypeWrapper.h:
639         (WebCore::PODTypeWrapperCacheInfoTraits::emptyValue):
640         (WebCore::JSSVGDynamicPODTypeWrapperCache::dynamicWrapperHashMap):
641         * dom/make_names.pl: Generate code to use DEFINE_STATIC_LOCAL.
642         * page/AccessibilityRenderObject.cpp:
643         (WebCore::RoleEntry::): This method is only called once, so the array does not have to be static.
644         * platform/graphics/FontCache.cpp:
645         (WebCore::FontPlatformDataCacheKeyTraits::emptyValue):
646         (WebCore::FontDataCacheKeyTraits::emptyValue):
647         * rendering/style/RenderStyle.h:
648         (WebCore::InheritedFlags::initialTransform):
649
650 2008-11-17  Geoffrey Garen  <ggaren@apple.com>
651
652         Not reviewed.
653
654         Try to fix Qt build.
655
656         * WebCore.pro:
657
658 2008-11-16  Simon Fraser  <simon.fraser@apple.com>
659
660         Reviewed by Dan Bernstein
661
662         https://bugs.webkit.org/show_bug.cgi?id=22118
663         
664         Fix resize corner tracking in transformed elements by using 
665         mapping the point into local coords using absoluteToLocal,
666         rather than convertToLayerCoords.
667         
668         Test: fast/css/resize-corner-tracking-transformed.html
669
670         * page/EventHandler.h:
671         * rendering/RenderLayer.cpp:
672         (WebCore::RenderLayer::absoluteToContents):
673         (WebCore::RenderLayer::offsetFromResizeCorner):
674         (WebCore::RenderLayer::isPointInResizeControl):
675         * rendering/RenderLayer.h:
676
677 2008-11-16  Geoffrey Garen  <ggaren@apple.com>
678
679         Not reviewed.
680
681         Try to fix Qt build.
682
683         * WebCore.pro:
684
685 2008-11-16  Greg Bolsinga  <bolsinga@apple.com>
686
687         Reviewed by Geoffrey Garen.
688
689         Use RefPtr and PassRefPtr where appropriate.
690
691         * loader/FTPDirectoryDocument.cpp:
692         (WebCore::createTemplateDocumentData):
693
694 2008-11-16  Greg Bolsinga  <bolsinga@apple.com>
695
696         Fix build break for real.
697
698         * loader/FTPDirectoryDocument.cpp:
699         (WebCore::createTemplateDocumentData):
700
701 2008-11-16  Greg Bolsinga  <bolsinga@apple.com>
702
703         Fix build break and bug.
704
705         * loader/FTPDirectoryDocument.cpp:
706         (WebCore::createTemplateDocumentData):
707
708 2008-11-16  Greg Bolsinga  <bolsinga@apple.com>
709
710         Reviewed by Darin Adler.
711
712         https://bugs.webkit.org/show_bug.cgi?id=21810
713         Remove use of static C++ objects that are destroyed at exit time (destructors)
714
715         Use DEFINE_STATIC_LOCAL for static RetainPtr<T>, RefPtr<T>. Add additional
716         uses of DEFINE_STATIC_LOCAL where appropriate.
717
718         * html/HTMLTableElement.cpp:
719         (WebCore::HTMLTableElement::addSharedCellBordersDecl): new the AtomicStrings
720         * loader/CachedImage.cpp:
721         (WebCore::brokenImage):
722         (WebCore::nullImage):
723         * loader/FTPDirectoryDocument.cpp:
724         (WebCore::_createTemplateDocumentData): Created so accessor has one line initialization
725         (WebCore::FTPDirectoryTokenizer::loadDocumentTemplate):
726         * loader/icon/IconDatabase.cpp:
727         (WebCore::loadDefaultIconRecord):
728         * page/AccessibilityObject.cpp:
729         (WebCore::AccessibilityObject::actionVerb):
730         * page/AccessibilityRenderObject.cpp:
731         (WebCore::AccessibilityRenderObject::actionVerb):
732         * page/mac/EventHandlerMac.mm:
733         (WebCore::currentEvent):
734         * platform/ScrollView.cpp:
735         (WebCore::ScrollView::paint):
736         * platform/graphics/Image.cpp:
737         (WebCore::Image::nullImage):
738         * platform/graphics/mac/ColorMac.mm:
739         (WebCore::nsColor):
740         * platform/graphics/mac/FontCacheMac.mm: new the Strings
741         (WebCore::FontCache::getSimilarFontPlatformData):
742         * platform/graphics/mac/GraphicsContextMac.mm:
743         (WebCore::_createPatternColor): Created so accessor has one line initialization
744         (WebCore::GraphicsContext::drawLineForMisspellingOrBadGrammar):
745         * platform/graphics/mac/SimpleFontDataMac.mm:
746         (WebCore::webFallbackFontFamily):
747         * platform/mac/PasteboardMac.mm:
748         (WebCore::writableTypesForURL):
749         (WebCore::createWritableTypesForImage): Created so accessor has one line initialization
750         (WebCore::writableTypesForImage):
751         (WebCore::stripAttachmentCharacters):
752         * rendering/RenderLayer.cpp:
753         (WebCore::RenderLayer::paintResizer):
754
755 2008-11-16  Holger Hans Peter Freyther  <zecke@selfish.org>
756
757         Reviewed by Darin Adler.
758
759         Do not spit Curl errors into the stdout as this is used by DRT
760
761         We have failing tests results due the curl errors printed to stdout,
762         move them to stderr to be able to pass those tests.
763
764         * platform/network/curl/ResourceHandleManager.cpp:
765         (WebCore::ResourceHandleManager::startJob):
766
767 2008-11-16  Holger Hans Peter Freyther  <zecke@selfish.org>
768
769         - fix the Gtk+ build
770
771         * GNUmakefile.am:
772
773 2008-11-16  Darin Adler  <darin@apple.com>
774
775         - try to fix Qt build
776
777         * WebCore.pro: Add the worker-related source files.
778
779 2008-11-16  Darin Adler  <darin@apple.com>
780
781         Suggested by Alexey Proskuryakov.
782
783         - fix the GTK build another way
784
785         * GNUmakefile.am: Add the worker-related source files.
786         * bindings/js/JSEventTarget.cpp: Take the #if back out.
787
788 2008-11-16  Darin Adler  <darin@apple.com>
789
790         - try to fix GTK build
791
792         * bindings/js/JSEventTarget.cpp: Put worker includes inside an #if.
793
794 2008-11-16  Darin Adler  <darin@apple.com>
795
796         Reviewed by Dan Bernstein.
797
798         - https://bugs.webkit.org/show_bug.cgi?id=22295
799           track which history items are from page load failures
800
801         * history/HistoryItem.cpp: Sort includes, add newly needed ones, and remove
802         no-longer-needed ones.
803         (WebCore::HistoryItem::HistoryItem): Initialize m_lastVisitWasFailure to false.
804         (WebCore::HistoryItem::showTreeWithIndent): Rewrote to avoid appending to a
805         String, since that's not efficient.
806
807         * history/HistoryItem.h: Removed unneeded includes. Added lastVisitWasFailure,
808         setLastVisitWasFailure, and m_lastVisitWasFailure.
809
810         * history/mac/HistoryItemMac.mm: Add newly-needed include
811         (WebCore::HistoryItem::setTransientProperty): Rewrote to avoid keeping a
812         m_transientProperties map around when it is empty.
813
814         * loader/FrameLoader.cpp:
815         (WebCore::FrameLoader::createHistoryItem): Call setLastVisitWasFailure when
816         the page was unreachable or an HTTP page with a status code that indicates
817         failure.
818
819 2008-11-16  Yong Li  <yong.li@torchmobile.com>
820
821         Reviewed by Timothy Hatcher.
822         Landed by George Staikos.
823
824         Optimization: don't relayout, repaint, or emit a DOM event if the
825         scroll event didn't scroll anywhere.
826
827         * rendering/RenderLayer.cpp:
828         (WebCore::RenderLayer::scrollToOffset): add early exit
829
830 2008-11-16  Alexey Proskuryakov  <ap@webkit.org>
831
832         Reviewed by Dan Bernstein.
833
834         https://bugs.webkit.org/show_bug.cgi?id=22290
835         Remove cross-heap GC and MessagePort multi-threading support
836
837         It is broken (and may not be implementable at all), and no longer needed, as we
838         don't use MessagePorts for communication with workers any more.
839
840         * bindings/js/JSDOMBinding.cpp:
841         * bindings/js/JSDOMBinding.h:
842         * bindings/js/JSDOMWindowBase.cpp:
843         * bindings/js/JSDOMWindowBase.h:
844         Removed cross-heap GC implementation.
845
846         * dom/MessagePort.cpp:
847         (WebCore::MessagePort::hasPendingActivity):
848         * dom/MessagePort.h:
849         Made objects RefCounted instead of ThreadSafeShared, added FIXME comments for code that is
850         unnecessarily complicated for single threaded case.
851
852 2008-11-14  Alexey Proskuryakov  <ap@webkit.org>
853
854         Reviewed by Maciej Stachowiak.
855
856         https://bugs.webkit.org/show_bug.cgi?id=22266
857         Stop using MessagePort for communication with workers
858
859         The current MessagePort specification is not well suited for being implemented in a
860         multi-threaded or multi-process environment, and this doesn't appear to be easily fixable.
861         This patch implements a simpler Mozilla API for workers instead.
862
863         * WebCore.xcodeproj/project.pbxproj:
864         * DerivedSources.make:
865         * bindings/js/JSDOMWindowBase.cpp: (jsDOMWindowBaseWorker):
866         * bindings/js/JSDedicatedWorkerConstructor.cpp: Removed.
867         * bindings/js/JSDedicatedWorkerConstructor.h: Removed.
868         * bindings/js/JSDedicatedWorkerCustom.cpp: Removed.
869         * bindings/js/JSWorkerConstructor.cpp: Copied from WebCore/bindings/js/JSDedicatedWorkerConstructor.cpp.
870         * bindings/js/JSWorkerConstructor.h: Copied from WebCore/bindings/js/JSDedicatedWorkerConstructor.h.
871         * bindings/js/JSWorkerCustom.cpp: Copied from WebCore/bindings/js/JSDedicatedWorkerCustom.cpp.
872         * dom/DedicatedWorker.cpp: Removed.
873         * dom/DedicatedWorker.h: Removed.
874         * dom/DedicatedWorker.idl: Removed.
875         Renamed DedicatedWorker to Worker to match Mozilla and current WHATWG cpec.
876
877         * bindings/js/JSEventListener.cpp: (WebCore::JSAbstractEventListener::handleEvent):
878         Clear worker exceptions to avoid hitting an assertion.
879
880         * dom/EventTarget.cpp: (WebCore::EventTarget::toWorker):
881         * dom/EventTarget.h:
882         * bindings/js/JSEventTarget.cpp: (WebCore::toJS):
883         WorkerContext is now an EventTarget, too.
884
885         * bindings/js/JSWorkerContext.cpp: Removed onconnect, constructors for MessageChannel and
886         MessagePort. Added postMessage() and onmessage.
887
888         * dom/ScriptExecutionContext.cpp: (WebCore::performTask): Do not reference ScriptExecutionContext
889         when posting a task - this operation is not thread safe. It is also not necessary any more,
890         as the context is kept alive by WorkerMessagingProxy.
891
892         * dom/Worker.cpp: Copied from WebCore/dom/DedicatedWorker.cpp.
893         (WebCore::Worker::Worker): Start loading the script right away - there is no reason to do
894         that on a timer.
895         (WebCore::Worker::~Worker): Notify messaging proxy.
896         (WebCore::Worker::postMessage): Just ask the proxy to post the message.
897         (WebCore::Worker::notifyFinished): Notify messaging proxy when a thread object becomes
898         available. Also, it is now safe to unsetPendingActivity(), making the object collectable.
899         I'm not sure if this is the right lifetime for workers, as unreachable workers with event
900         listeners should probably be kept alive, but it at least lets the object be collected.
901         (WebCore::Worker::addEventListener): Added an EventTarget implementation.
902         (WebCore::Worker::removeEventListener): Added an EventTarget implementation.
903         (WebCore::Worker::dispatchEvent): Added an EventTarget implementation.
904
905         * dom/Worker.h: Copied from WebCore/dom/DedicatedWorker.h.
906         * dom/Worker.idl: Copied from WebCore/dom/DedicatedWorker.idl.
907         Removed onclose, made an EventListener. Actual messaging is now handled by WorkerMessagingProxy.
908
909         * dom/WorkerContext.cpp:
910         (WebCore::WorkerContext::~WorkerContext): Notify messaging proxy that the context was shut
911         down successfully.
912         (WebCore::WorkerContext::postMessage): Added. Post the message via messaging proxy.
913
914         * dom/WorkerContext.h: Added postMessage and onmessage, removed onconnect.
915
916         * dom/WorkerMessagingProxy.cpp: Added.
917         * dom/WorkerMessagingProxy.h: Added.
918         This new class implements actual messaging. It is notified when a Worker is garbage collected,
919         and asks the thread to shut down. It also owns the thread object, and references script
920         execution context, making it safe to post messages to it remotely.
921
922         * dom/WorkerThread.cpp:
923         * dom/WorkerThread.h:
924         Keep a reference to messaging proxy, not to Worker itself. Also, the thread object no longer
925         keeps itself alive - it is now the job of messaging proxy.
926
927 2008-11-15  Darin Adler  <darin@apple.com>
928
929         Rubber stamped by Geoff Garen.
930
931         - do the long-planned StructureID -> Structure rename
932
933         * ForwardingHeaders/runtime/Structure.h: Copied from WebCore/ForwardingHeaders/runtime/StructureID.h.
934         * ForwardingHeaders/runtime/StructureID.h: Removed.
935         * bindings/js/JSAudioConstructor.cpp:
936         (WebCore::JSAudioConstructor::JSAudioConstructor):
937         * bindings/js/JSDOMBinding.cpp:
938         (WebCore::getCachedDOMStructure):
939         (WebCore::cacheDOMStructure):
940         * bindings/js/JSDOMBinding.h:
941         (WebCore::DOMObject::DOMObject):
942         (WebCore::getDOMStructure):
943         * bindings/js/JSDOMGlobalObject.cpp:
944         (WebCore::JSDOMGlobalObject::JSDOMGlobalObject):
945         * bindings/js/JSDOMGlobalObject.h:
946         * bindings/js/JSDOMWindowBase.cpp:
947         (WebCore::JSDOMWindowBase::JSDOMWindowBase):
948         * bindings/js/JSDOMWindowBase.h:
949         * bindings/js/JSDOMWindowShell.cpp:
950         (WebCore::JSDOMWindowShell::JSDOMWindowShell):
951         (WebCore::JSDOMWindowShell::setWindow):
952         * bindings/js/JSDOMWindowShell.h:
953         (WebCore::JSDOMWindowShell::createStructure):
954         * bindings/js/JSDedicatedWorkerConstructor.cpp:
955         (WebCore::JSDedicatedWorkerConstructor::JSDedicatedWorkerConstructor):
956         * bindings/js/JSHTMLAllCollection.h:
957         (WebCore::JSHTMLAllCollection::JSHTMLAllCollection):
958         (WebCore::JSHTMLAllCollection::createStructure):
959         * bindings/js/JSImageConstructor.cpp:
960         (WebCore::JSImageConstructor::JSImageConstructor):
961         * bindings/js/JSInspectedObjectWrapper.cpp:
962         (WebCore::JSInspectedObjectWrapper::wrap):
963         (WebCore::JSInspectedObjectWrapper::JSInspectedObjectWrapper):
964         * bindings/js/JSInspectedObjectWrapper.h:
965         * bindings/js/JSInspectorCallbackWrapper.cpp:
966         (WebCore::leakInspectorCallbackWrapperStructure):
967         (WebCore::JSInspectorCallbackWrapper::wrap):
968         (WebCore::JSInspectorCallbackWrapper::JSInspectorCallbackWrapper):
969         * bindings/js/JSInspectorCallbackWrapper.h:
970         * bindings/js/JSMessageChannelConstructor.cpp:
971         (WebCore::JSMessageChannelConstructor::JSMessageChannelConstructor):
972         * bindings/js/JSNamedNodesCollection.h:
973         (WebCore::JSNamedNodesCollection::createStructure):
974         * bindings/js/JSOptionConstructor.cpp:
975         (WebCore::JSOptionConstructor::JSOptionConstructor):
976         * bindings/js/JSQuarantinedObjectWrapper.cpp:
977         (WebCore::JSQuarantinedObjectWrapper::JSQuarantinedObjectWrapper):
978         * bindings/js/JSQuarantinedObjectWrapper.h:
979         (WebCore::JSQuarantinedObjectWrapper::createStructure):
980         * bindings/js/JSRGBColor.h:
981         (WebCore::JSRGBColor::createStructure):
982         * bindings/js/JSWorkerContext.cpp:
983         (WebCore::createJSWorkerContextStructure):
984         (WebCore::JSWorkerContext::JSWorkerContext):
985         (WebCore::JSWorkerContext::createPrototype):
986         * bindings/js/JSWorkerContext.h:
987         (WebCore::JSWorkerContext::createStructure):
988         (WebCore::JSWorkerContextPrototype::JSWorkerContextPrototype):
989         (WebCore::JSWorkerContextPrototype::createStructure):
990         * bindings/js/JSXMLHttpRequestConstructor.cpp:
991         (WebCore::JSXMLHttpRequestConstructor::JSXMLHttpRequestConstructor):
992         * bindings/js/JSXSLTProcessorConstructor.cpp:
993         (WebCore::JSXSLTProcessorConstructor::JSXSLTProcessorConstructor):
994         * bindings/scripts/CodeGeneratorJS.pm:
995         * bridge/objc/objc_runtime.h:
996         (JSC::Bindings::ObjcFallbackObjectImp::createStructure):
997         * bridge/qt/qt_runtime.cpp:
998         (JSC::Bindings::QtConnectionObject::execute):
999         * bridge/qt/qt_runtime.h:
1000         (JSC::Bindings::QtRuntimeMethod::createStructure):
1001         * bridge/runtime_array.h:
1002         (JSC::RuntimeArray::createStructure):
1003         * bridge/runtime_method.h:
1004         (JSC::RuntimeMethod::createStructure):
1005         * bridge/runtime_object.cpp:
1006         (JSC::RuntimeObjectImp::RuntimeObjectImp):
1007         * bridge/runtime_object.h:
1008         (JSC::RuntimeObjectImp::createStructure):
1009
1010 2008-11-15  Darin Adler  <darin@apple.com>
1011
1012         Reviewed by Dan Bernstein.
1013
1014         - fix just-introduced crash in the svg/custom/svg-fonts-in-html.html test
1015
1016         This gets rid of the crash. It restores the behavior of the CG case from before Dirk
1017         Shulze removed the platorm-dependent code, but perhaps it should be changed further
1018         in the future so that the default for no style is "no stroke". I think the patch is
1019         fine for fill.
1020
1021         * svg/graphics/SVGPaintServerSolid.cpp:
1022         (WebCore::SVGPaintServerSolid::setup): Added null checks for svgStyle.
1023         (WebCore::SVGPaintServerSolid::renderPath): Added null checks for style and svgStyle.
1024
1025 2008-11-15  Kevin Ollivier  <kevino@theolliviers.com>
1026
1027         Reviewed by Timothy Hatcher.
1028
1029         Initialize m_networkStateChangedFunction to 0 as otherwise the check for null will fail.
1030         
1031         https://bugs.webkit.org/show_bug.cgi?id=22284
1032
1033         * platform/network/NetworkStateNotifier.h:
1034         (WebCore::NetworkStateNotifier::NetworkStateNotifier):
1035
1036 2008-11-15  Dirk Schulze  <krit@webkit.org>
1037
1038         Reviewed by Geoffrey Garen.
1039
1040         r38426 caused a wrong drawing of a LayoutTest. Use another
1041         way to set the color to pass this test again.
1042
1043         * svg/graphics/SVGPaintServerSolid.cpp:
1044         (WebCore::SVGPaintServerSolid::setup):
1045
1046 2008-11-15  Dirk Schulze  <krit@webkit.org>
1047
1048         Reviewed by Darin Adler.
1049
1050         Removed platform dependent code on SVGPaintServerSolid.
1051
1052         * GNUmakefile.am:
1053         * WebCore.pro:
1054         * WebCore.vcproj/WebCore.vcproj:
1055         * WebCore.xcodeproj/project.pbxproj:
1056         * svg/graphics/SVGPaintServerSolid.cpp:
1057         (WebCore::SVGPaintServerSolid::setup):
1058         (WebCore::SVGPaintServerSolid::renderPath):
1059         * svg/graphics/SVGPaintServerSolid.h:
1060         * svg/graphics/cairo/SVGPaintServerSolidCairo.cpp: Removed.
1061         * svg/graphics/cg/SVGPaintServerSolidCg.cpp: Removed.
1062         * svg/graphics/qt/SVGPaintServerSolidQt.cpp: Removed.
1063
1064 2008-11-15  Geoffrey Garen  <ggaren@apple.com>
1065
1066         Reviewed by Sam Weinig.
1067         
1068         Updated for JavaScriptCore renames.
1069
1070         * bindings/js/JSNodeCustom.cpp:
1071         (WebCore::JSNode::mark):
1072         * bindings/js/JSXMLHttpRequestCustom.cpp:
1073         (WebCore::JSXMLHttpRequest::send):
1074         * bindings/js/ScriptController.cpp:
1075         (WebCore::ScriptController::evaluate):
1076         * bindings/js/WorkerScriptController.cpp:
1077         (WebCore::WorkerScriptController::evaluate):
1078         * bindings/objc/WebScriptObject.mm:
1079         (-[WebScriptObject evaluateWebScript:]):
1080         * bridge/NP_jsobject.cpp:
1081         (_NPN_Evaluate):
1082         * bridge/jni/jni_jsobject.mm:
1083         (JavaJSObject::eval):
1084         * page/Console.cpp:
1085         (WebCore::retrieveLastCaller):
1086         (WebCore::Console::trace):
1087
1088 2008-11-14  Greg Bolsinga  <bolsinga@apple.com>
1089
1090         Reviewed by Darin Adler.
1091
1092         https://bugs.webkit.org/show_bug.cgi?id=21810
1093         Remove use of static C++ objects that are destroyed at exit time (destructors)
1094
1095         Create DEFINE_STATIC_LOCAL macro. Change static local objects to leak to avoid 
1096         exit-time destructor. Update code that was changed to fix this issue that ran 
1097         into a gcc bug (<rdar://problem/6354696> Codegen issue with C++ static reference 
1098         in gcc build 5465). Also typdefs for template types needed to be added in some 
1099         cases so the type could make it through the macro successfully.
1100
1101         Basically code of the form:
1102         static T m;
1103         becomes:
1104         DEFINE_STATIC_LOCAL(T, m, ());
1105
1106         Also any code of the form:
1107         static T& m = *new T;
1108         also becomes:
1109         DEFINE_STATIC_LOCAL(T, m, ());
1110
1111         * ForwardingHeaders/wtf/StdLibExtras.h: Added.
1112         * bindings/js/GCController.cpp:
1113         (WebCore::gcController):
1114         * bindings/js/JSDOMBinding.cpp:
1115         (WebCore::wrapperSet):
1116         * bindings/js/JSInspectedObjectWrapper.cpp:
1117         (WebCore::wrappers):
1118         * bindings/js/JSInspectorCallbackWrapper.cpp:
1119         (WebCore::wrappers):
1120         * bindings/js/JSNavigatorCustom.cpp:
1121         (WebCore::needsYouTubeQuirk):
1122         * bridge/runtime_root.cpp:
1123         (JSC::Bindings::rootObjectSet):
1124         * css/CSSMutableStyleDeclaration.cpp:
1125         (WebCore::initShorthandMap):
1126         (WebCore::CSSMutableStyleDeclaration::removeProperty):
1127         * css/CSSPrimitiveValue.cpp:
1128         (WebCore::CSSPrimitiveValue::cssText):
1129         * css/CSSSelector.cpp:
1130         (WebCore::CSSSelector::extractPseudoType):
1131         * css/CSSStyleSelector.cpp:
1132         (WebCore::screenEval):
1133         (WebCore::printEval):
1134         * dom/DOMImplementation.cpp:
1135         (WebCore::addString):
1136         (WebCore::isSVG10Feature):
1137         (WebCore::isSVG11Feature):
1138         (WebCore::DOMImplementation::isXMLMIMEType):
1139         * dom/Document.cpp:
1140         (WebCore::Document::hasPrefixNamespaceMismatch):
1141         * dom/ScriptElement.cpp:
1142         (WebCore::isSupportedJavaScriptLanguage):
1143         * editing/ApplyStyleCommand.cpp:
1144         (WebCore::styleSpanClassString):
1145         * editing/HTMLInterchange.cpp:
1146         (WebCore::):
1147         * editing/IndentOutdentCommand.cpp:
1148         (WebCore::indentBlockquoteString):
1149         * editing/ReplaceSelectionCommand.cpp:
1150         (WebCore::isInterchangeNewlineNode):
1151         (WebCore::isInterchangeConvertedSpaceSpan):
1152         * editing/htmlediting.cpp:
1153         (WebCore::stringWithRebalancedWhitespace):
1154         (WebCore::nonBreakingSpaceString):
1155         * editing/markup.cpp:
1156         (WebCore::appendAttributeValue):
1157         (WebCore::appendEscapedContent):
1158         (WebCore::shouldAddNamespaceAttr):
1159         (WebCore::appendNamespace):
1160         (WebCore::appendStartMarkup):
1161         (WebCore::createMarkup):
1162         * html/HTMLButtonElement.cpp:
1163         (WebCore::HTMLButtonElement::type):
1164         * html/HTMLElement.cpp:
1165         (WebCore::HTMLElement::isRecognizedTagName):
1166         (WebCore::inlineTagList):
1167         (WebCore::blockTagList):
1168         * html/HTMLFieldSetElement.cpp:
1169         (WebCore::HTMLFieldSetElement::type):
1170         * html/HTMLInputElement.cpp:
1171         (WebCore::HTMLInputElement::type):
1172         * html/HTMLKeygenElement.cpp:
1173         (WebCore::HTMLKeygenElement::type):
1174         * html/HTMLLegendElement.cpp:
1175         (WebCore::HTMLLegendElement::type):
1176         * html/HTMLOptGroupElement.cpp:
1177         (WebCore::HTMLOptGroupElement::type):
1178         * html/HTMLOptionElement.cpp:
1179         (WebCore::HTMLOptionElement::type):
1180         * html/HTMLParser.cpp:
1181         (WebCore::HTMLParser::getNode):
1182         (WebCore::HTMLParser::isHeaderTag):
1183         (WebCore::HTMLParser::isResidualStyleTag):
1184         (WebCore::HTMLParser::isAffectedByResidualStyle):
1185         * html/HTMLSelectElement.cpp:
1186         (WebCore::HTMLSelectElement::type):
1187         * html/HTMLTextAreaElement.cpp:
1188         (WebCore::HTMLTextAreaElement::type):
1189         * inspector/InspectorController.cpp:
1190         (WebCore::platform):
1191         * inspector/JavaScriptDebugServer.cpp:
1192         (WebCore::JavaScriptDebugServer::shared):
1193         * inspector/JavaScriptProfile.cpp:
1194         (WebCore::profileCache):
1195         * inspector/JavaScriptProfileNode.cpp:
1196         (WebCore::profileNodeCache):
1197         * loader/FrameLoader.cpp:
1198         (WebCore::localSchemes):
1199         * loader/appcache/ApplicationCacheStorage.cpp:
1200         (WebCore::cacheStorage):
1201         * loader/archive/ArchiveFactory.cpp:
1202         (WebCore::archiveMIMETypes):
1203         (WebCore::ArchiveFactory::registerKnownArchiveMIMETypes):
1204         * loader/icon/IconDatabase.cpp:
1205         (WebCore::IconDatabase::defaultDatabaseFilename):
1206         * page/EventHandler.cpp:
1207         (WebCore::EventHandler::dragState):
1208         * page/Frame.cpp:
1209         (WebCore::createRegExpForLabels):
1210         (WebCore::keepAliveSet):
1211         * page/Page.cpp:
1212         (WebCore::Page::groupName):
1213         * page/SecurityOrigin.cpp:
1214         (WebCore::isDefaultPortForProtocol):
1215         (WebCore::SecurityOrigin::databaseIdentifier):
1216         * page/mac/FrameMac.mm:
1217         (WebCore::regExpForLabels):
1218         * platform/KURL.cpp:
1219         (WebCore::blankURL):
1220         * platform/graphics/FontCache.cpp:
1221         (WebCore::alternateFamilyName):
1222         * platform/graphics/mac/FontCacheMac.mm:
1223         (WebCore::FontCache::getSimilarFontPlatformData):
1224         (WebCore::FontCache::getLastResortFallbackFont):
1225         * platform/mac/CursorMac.mm:
1226         (WebCore::leakNamedCursor):
1227         (WebCore::pointerCursor):
1228         (WebCore::crossCursor):
1229         (WebCore::handCursor):
1230         (WebCore::moveCursor):
1231         (WebCore::verticalTextCursor):
1232         (WebCore::cellCursor):
1233         (WebCore::contextMenuCursor):
1234         (WebCore::aliasCursor):
1235         (WebCore::zoomInCursor):
1236         (WebCore::zoomOutCursor):
1237         (WebCore::copyCursor):
1238         (WebCore::noneCursor):
1239         (WebCore::progressCursor):
1240         (WebCore::noDropCursor):
1241         (WebCore::notAllowedCursor):
1242         (WebCore::iBeamCursor):
1243         (WebCore::waitCursor):
1244         (WebCore::helpCursor):
1245         (WebCore::eastResizeCursor):
1246         (WebCore::northResizeCursor):
1247         (WebCore::northEastResizeCursor):
1248         (WebCore::northWestResizeCursor):
1249         (WebCore::southResizeCursor):
1250         (WebCore::southEastResizeCursor):
1251         (WebCore::southWestResizeCursor):
1252         (WebCore::westResizeCursor):
1253         (WebCore::northSouthResizeCursor):
1254         (WebCore::eastWestResizeCursor):
1255         (WebCore::northEastSouthWestResizeCursor):
1256         (WebCore::northWestSouthEastResizeCursor):
1257         (WebCore::columnResizeCursor):
1258         (WebCore::rowResizeCursor):
1259         (WebCore::grabCursor):
1260         (WebCore::grabbingCursor):
1261         * platform/mac/ScrollbarThemeMac.mm:
1262         (WebCore::ScrollbarTheme::nativeTheme):
1263         * platform/mac/ThemeMac.mm:
1264         (WebCore::platformTheme):
1265         * platform/mac/ThreadCheck.mm:
1266         (WebCoreReportThreadViolation):
1267         * platform/network/NetworkStateNotifier.cpp:
1268         (WebCore::networkStateNotifier):
1269         * platform/network/mac/FormDataStreamMac.mm:
1270         (WebCore::getStreamFormDataMap):
1271         (WebCore::getStreamResourceHandleMap):
1272         * platform/network/mac/ResourceResponseMac.mm:
1273         (WebCore::ResourceResponse::platformLazyInit):
1274         * platform/text/TextEncoding.cpp:
1275         (WebCore::TextEncoding::isJapanese):
1276         * plugins/PluginMainThreadScheduler.cpp:
1277         (WebCore::PluginMainThreadScheduler::scheduler):
1278         * rendering/RenderBlock.cpp:
1279         (WebCore::continuationOutlineTable):
1280         (WebCore::RenderBlock::addContinuationWithOutline):
1281         (WebCore::RenderBlock::paintContinuationOutlines):
1282         * rendering/RenderCounter.cpp:
1283         (WebCore::counterMaps):
1284         * rendering/RenderFlexibleBox.cpp:
1285         (WebCore::RenderFlexibleBox::layoutVerticalBox):
1286         * rendering/RenderListItem.cpp:
1287         (WebCore::RenderListItem::markerText):
1288         * rendering/RenderScrollbarTheme.cpp:
1289         (WebCore::RenderScrollbarTheme::renderScrollbarTheme):
1290         * rendering/RenderThemeMac.mm:
1291         (WebCore::RenderThemeMac::systemFont):
1292         * rendering/bidi.cpp:
1293         (WebCore::RenderBlock::checkLinesForTextOverflow):
1294         * rendering/style/RenderStyle.cpp:
1295         (WebCore::RenderStyle::initialDashboardRegions):
1296         (WebCore::RenderStyle::noneDashboardRegions):
1297         * storage/Database.cpp:
1298         (WebCore::guidMutex):
1299         (WebCore::guidToVersionMap):
1300         (WebCore::guidToDatabaseMap):
1301         (WebCore::Database::databaseInfoTableName):
1302         (WebCore::databaseVersionKey):
1303         (WebCore::Database::getVersionFromDatabase):
1304         (WebCore::Database::setVersionInDatabase):
1305         (WebCore::guidForOriginAndName):
1306         * storage/DatabaseTracker.cpp:
1307         (WebCore::DatabaseTracker::tracker):
1308         (WebCore::notificationMutex):
1309         (WebCore::notificationQueue):
1310         * storage/LocalStorage.cpp:
1311         (WebCore::localStorageMap):
1312         * svg/SVGAnimateMotionElement.cpp:
1313         (WebCore::SVGAnimateMotionElement::rotateMode):
1314         * svg/SVGAnimationElement.cpp:
1315         (WebCore::SVGAnimationElement::calcMode):
1316         (WebCore::SVGAnimationElement::attributeType):
1317         (WebCore::SVGAnimationElement::isAdditive):
1318         (WebCore::SVGAnimationElement::isAccumulated):
1319         * svg/SVGLangSpace.cpp:
1320         (WebCore::SVGLangSpace::xmlspace):
1321         * svg/SVGSVGElement.cpp:
1322         (WebCore::SVGSVGElement::contentScriptType):
1323         (WebCore::SVGSVGElement::contentStyleType):
1324         * svg/SVGStyleElement.cpp:
1325         (WebCore::SVGStyleElement::type):
1326         (WebCore::SVGStyleElement::media):
1327         * svg/SVGTextContentElement.cpp:
1328         (WebCore::SVGTextContentElement::parseMappedAttribute):
1329         * svg/animation/SVGSMILElement.cpp:
1330         (WebCore::SVGSMILElement::parseClockValue):
1331         (WebCore::SVGSMILElement::restart):
1332         (WebCore::SVGSMILElement::fill):
1333         (WebCore::SVGSMILElement::repeatCount):
1334         (WebCore::SVGSMILElement::notifyDependentsIntervalChanged):
1335         * svg/graphics/SVGResource.cpp:
1336         (WebCore::clientMap):
1337         (WebCore::SVGResource::removeClient):
1338         * svg/graphics/SVGResourceMarker.cpp:
1339         (WebCore::SVGResourceMarker::draw):
1340         * xml/XMLHttpRequest.cpp:
1341         (WebCore::PreflightResultCacheItem::PreflightResultCacheItem):
1342         (WebCore::preflightResultCache):
1343         (WebCore::appendPreflightResultCacheEntry):
1344         (WebCore::isSafeRequestHeader):
1345         (WebCore::isOnAccessControlResponseHeaderWhitelist):
1346         (WebCore::XMLHttpRequest::didReceiveResponsePreflight):
1347         * xml/XPathExpressionNode.cpp:
1348         (WebCore::XPath::Expression::evaluationContext):
1349         * xml/XPathParser.cpp:
1350         (WebCore::XPath::setUpAxisNamesMap):
1351         (WebCore::XPath::isAxisName):
1352         (WebCore::XPath::isNodeTypeName):
1353         * xml/XPathValue.cpp:
1354         (WebCore::XPath::Value::toNodeSet):
1355
1356 2008-11-14  Dan Bernstein  <mitz@apple.com>
1357
1358         - attempt to fix the Qt build
1359
1360         * platform/qt/Localizations.cpp:
1361         (WebCore::contextMenuItemTagTextDirectionMenu): Added. Maybe this string
1362         needs to go somewhere else in addition to here.
1363
1364 2008-11-14  Kevin Ollivier  <kevino@theolliviers.com>
1365
1366         wx build fix.
1367
1368         * platform/wx/LocalizedStringsWx.cpp:
1369         (WebCore::contextMenuItemTagTextDirectionMenu):
1370
1371 2008-11-14  Dan Bernstein  <mitz@apple.com>
1372
1373         Reviewed by Darin Adler.
1374
1375         - <rdar://problem/6234307> Support action methods for setting and clearing character-level directionality
1376         - WebCore part of <rdar://problem/6234337> Add a Text Direction menu to the default context menu when appropriate
1377
1378         * WebCore.base.exp: Exported
1379         WebCore::Settings::setTextDirectionSubmenuInclusionBehavior().
1380
1381         * editing/ApplyStyleCommand.cpp:
1382         (StyleChange::init): Changed to always include the direction property
1383         in the result if the unicode-bidi property is included.
1384         (ApplyStyleCommand::splitAncestorsWithUnicodeBidi): Added. Finds the
1385         highest ancestor of the given node that establishes bidi embedding. If
1386         that embedding agrees with the given allowed direction, finds the
1387         second-highest embedding ancestor. Splits all nodes through that
1388         ancestor. If the highest embedding ancestor did not need to be split,
1389         it is returned.
1390         (ApplyStyleCommand::removeEmbeddingUpToEnclosingBlock): Added. Removes
1391         bidi embedding attributes and styles from all ancestors of the given
1392         node up to its enclosing block or the given node.
1393         (ApplyStyleCommand::applyInlineStyle): Added code to handle the
1394         unicode-bidi property. Applying style the includes this property
1395         involves removing all bidi embedding in effect, except  for one-level
1396         embedding that agrees with the desired embedding, then applying the
1397         desired embedding where it is not already in effect.
1398         (ApplyStyleCommand::applyInlineStyleToRange): Factored out from
1399         applyInlineStyle().
1400         (ApplyStyleCommand::removeHTMLBidiEmbeddingStyle): Added. Removed the
1401         "dir" attribute if necessary and the element if it becomes an unstyled
1402         style span.
1403         (ApplyStyleCommand::removeCSSStyle): Changed to remove the direction
1404         property when removing the unicode-bidi property.
1405         (ApplyStyleCommand::removeInlineStyle): Added a call to
1406         removeHTMLBidiEmbeddingStyle().
1407
1408         * editing/ApplyStyleCommand.h:
1409         * editing/Editor.cpp:
1410         (Editor::textDirectionForSelection): Added. Returns the character-level
1411         writing direction of the selection if it is uniform and simple (at most
1412         one level of embedding).
1413         (Editor::hasBidiSelection): Added. Returns true if the selection lies
1414         entirely within a single block, and that block has direction:rtl or
1415         contains any inline boxes with non-zero bidi embedding level.
1416
1417         * editing/Editor.h:
1418         * editing/EditorCommand.cpp:
1419         (stateTextWritingDirection): Added this helper function for deciding
1420         the state of Text Direction submenu items.
1421         (executeMakeTextWritingDirectionLeftToRight): Added. Applies
1422         "unicode-bidi: embed; direction: ltr;".
1423         (executeMakeTextWritingDirectionNatural): Added. Applies
1424         "unicode-bidi: normal;"
1425         (executeMakeTextWritingDirectionRightToLeft): Added. Applies
1426         "unicode-bidi: embed; direction: rtl;".
1427         (stateTextWritingDirectionLeftToRight): Added.
1428         (stateTextWritingDirectionNatural): Added.
1429         (stateTextWritingDirectionRightToLeft): Added.
1430         (createCommandMap): Added "MakeTextWritingDirectionLeftToRight",
1431         "MakeTextWritingDirectionNatural",
1432         and "MakeTextWritingDirectionRightToLeft".
1433
1434         * editing/InsertTextCommand.cpp:
1435         (InsertTextCommand::input): Added code to maintain the unicode-bidi
1436         and direction properties in the typing style. Even if they have the
1437         same values as the computed style at the caret, they need to be included
1438         in the typing style so that inserted text will not inherit any nested
1439         embedding.
1440
1441         * page/ContextMenuController.cpp:
1442         (ContextMenuController::contextMenuItemSelected): Added calls to
1443         the editor for the text direction menu items.
1444
1445         * page/Frame.cpp
1446         (Frame::computeAndSetTypingStyle): Added code to maintain the
1447         unicode-bidi and direction properties in the typing style.
1448
1449         * page/Settings.cpp:
1450         (Settings::setTextDirectionSubmenuInclusionBehavior): Added this setter.
1451
1452         * page/Settings.h: Added a TextDirectionSubmenuInclusionBehavior enum,
1453         an m_textDirectionSubmenuInclusionBehavior member, and accessors.
1454
1455         * page/mac/WebCoreViewFactory.h:
1456         * platform/ContextMenu.cpp:
1457         (WebCore::createAndAppendTextDirectionSubMenu): Added.
1458         (ContextMenu::populate): Added the Text Direction submenu item based on
1459         the inclusion behavior and the existence of a bidi selection.
1460         (ContextMenu::checkOrEnableIfNeeded): Added code for the text direction
1461         menu items.
1462
1463         * platform/ContextMenuItem.h:
1464         * platform/LocalizedStrings.h: Declared
1465         contextMenuItemTagTextDirectionMenu().
1466
1467         * platform/mac/LocalizedStringsMac.mm: Defined
1468         contextMenuItemTagTextDirectionMenu().
1469
1470         * rendering/RenderBlock.cpp:
1471         (RenderBlock::containsNonZeroBidiLevel): Added.
1472         * rendering/RenderBlock.h:
1473
1474 2008-11-14  Greg Bolsinga  <bolsinga@apple.com>
1475
1476         Reviewed by Darin Adler.
1477
1478         https://bugs.webkit.org/show_bug.cgi?id=22264
1479         Need to update to latest Geolocation spec (13 November 2008)
1480         
1481         Update to new error code constants and values.
1482
1483         * page/Geolocation.cpp: Use new named ErrorCode enums
1484         (WebCore::Geolocation::GeoNotifier::timerFired):
1485         (WebCore::Geolocation::getCurrentPosition):
1486         (WebCore::Geolocation::watchPosition):
1487         * page/PositionError.h: Have ErrorCode enum names match new error constant names and values
1488         (WebCore::PositionError::):
1489         * page/PositionError.idl: Add new named error constants
1490
1491 2008-11-14  Beth Dakin  <bdakin@apple.com>
1492
1493         Reviewed by Justin Garcia.
1494
1495         Fix (again) for <rdar://problem/5089327> Too much indentation when 
1496         pasting quoted paragraphs
1497
1498         This patch goes back to Justin's original approach to fix this bug, 
1499         written in revision 38273. That fix was mostly rolled out by 
1500         revision 38310 because of styling issues created by the addition of 
1501         extra blockquote nodes. This patch again goes back to Justin's 
1502         original fix because of cases we discovered the newer fix could not 
1503         possibly cover. This version of the patch minimizes the styling 
1504         issues of extra blockquotes by opting into the merge start code. 
1505
1506         * editing/ReplaceSelectionCommand.cpp:
1507         (WebCore::hasMatchingQuoteLevel): We want shouldMergeStart to 
1508         return true when the quoting level of the end of the inserted 
1509         content matches the quoting level of the end of the existing 
1510         content.
1511         (WebCore::ReplaceSelectionCommand::shouldMergeStart): Now calls 
1512         hasMatchingQuoteLevel
1513         (WebCore::ReplaceSelectionCommand::doApply):
1514
1515 2008-11-14  Dirk Schulze  <vbs85@gmx.de>
1516
1517         Reviewed by Eric Seidel.
1518
1519         Made SVGResourceClipper platform independent.
1520         https://bugs.webkit.org/show_bug.cgi?id=21444
1521
1522         * GNUmakefile.am:
1523         * WebCore.pro:
1524         * WebCore.vcproj/WebCore.vcproj:
1525         * WebCore.xcodeproj/project.pbxproj:
1526         * platform/graphics/GraphicsContext.h:
1527         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1528         (WebCore::GraphicsContext::clipPath):
1529         * platform/graphics/cg/GraphicsContextCG.cpp:
1530         (WebCore::GraphicsContext::clipPath):
1531         * platform/graphics/qt/GraphicsContextQt.cpp:
1532         (WebCore::GraphicsContext::addPath):
1533         (WebCore::GraphicsContext::clipPath):
1534         * svg/graphics/SVGResourceClipper.cpp:
1535         (WebCore::SVGResourceClipper::applyClip):
1536         * svg/graphics/cairo/SVGResourceClipperCairo.cpp: Removed.
1537         * svg/graphics/cg/SVGResourceClipperCg.cpp: Removed.
1538         * svg/graphics/qt/SVGResourceClipperQt.cpp: Removed.
1539
1540 2008-11-14  Antti Koivisto  <antti@apple.com>
1541
1542         Reviewed by Anders Carlsson.
1543
1544         Combine loadFrameRequestWithFormState to loadFrameRequestWithFormAndValues.
1545
1546         * loader/FrameLoader.cpp:
1547         (WebCore::FrameLoader::loadFrameRequestWithFormAndValues):
1548         * loader/FrameLoader.h:
1549
1550 2008-11-14  Sam Weinig  <sam@webkit.org>
1551
1552         Reviewed by Eric Seidel.
1553
1554         Remove unneeded forward declaration.
1555
1556         * plugins/Plugin.h:
1557
1558 2008-11-14  Darin Fisher  <darin@chromium.org>
1559
1560         Reviewed by Darin Adler.
1561
1562         https://bugs.webkit.org/show_bug.cgi?id=22251
1563         HTMLCanvasElement.cpp unnecessarily includes runtime/Interpreter.h
1564
1565         * html/HTMLCanvasElement.cpp:
1566
1567 2008-11-14  Yael Aharon  <yael.aharon@nokia.com>
1568
1569         Reviewed by Simon Hausmann.
1570
1571         Add new files from the Qt port to the build.
1572
1573         * WebCore.pro:
1574
1575 2008-11-14  Yael Aharon  <yael.aharon@nokia.com>
1576
1577         Reviewed by Simon Hausmann.
1578
1579         Made DatabaseTracker::hasEntryForOrigin() public. This allows the Qt
1580         port to apply a default quota only if there is no entry in the
1581         database for a given origin yet.
1582
1583         * storage/DatabaseTracker.h:
1584
1585 2008-11-14  Yael Aharon  <yael.aharon@nokia.com>
1586
1587         Reviewed by Simon Hausmann.
1588
1589         Make it possible to get the cache directory set in the application
1590         cache storage.
1591
1592         * loader/appcache/ApplicationCacheStorage.cpp:
1593         (WebCore::ApplicationCacheStorage::cacheDirectory): Added.
1594         * loader/appcache/ApplicationCacheStorage.h:
1595
1596 2008-11-14  Justin Garcia  <justin.garcia@apple.com>
1597
1598         Reviewed by Beth Dakin.
1599
1600         <rdar://problem/4230923> "Make Plain Text" doesn't reset text alignment in single paragraph messages
1601         
1602         When applying block styles, we would add block properties to the body element, and Mail's
1603         Make Plain Text feature isn't equipped to remove those.  This could have been fixed on our side,
1604         but this change has the advantage that it fixes the bug on Tiger, where Mail does not plan future updates.
1605         
1606         We have code that puts the paragraphs that we're operating on into blocks of their own before
1607         adding or removing block properties from the blocks that enclose them.  We need to run this code 
1608         when the enclosing block is the body element.
1609         
1610         * editing/CompositeEditCommand.cpp:
1611         (WebCore::CompositeEditCommand::insertNewDefaultParagraphElementAt): Added, moved code from moveParagraphContents
1612         to here.
1613         (WebCore::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary): Renamed some variables for clarity.
1614         Added a few comments.  Fixed bug by not bailing out when the block about to be used is the body element.
1615         * editing/CompositeEditCommand.h:
1616
1617 2008-11-14  Cameron Zwarich  <zwarich@apple.com>
1618
1619         Reviewed by Darin Adler.
1620
1621         Bug 22245: Move wtf/dtoa.h into the WTF namespace
1622         <https://bugs.webkit.org/show_bug.cgi?id=22245>
1623
1624         Move wtf/dtoa.h into the WTF namespace from the JSC namespace.
1625
1626         * platform/text/String.cpp:
1627         (WebCore::charactersToDouble):
1628
1629 2008-11-14  Tor Arne Vestbø  <tavestbo@trolltech.com>
1630
1631         Rubber-stamped by Simon Hausmann.
1632
1633         Make sure Qt scrollbars follow the style with regard to context menus
1634
1635         * platform/qt/ScrollbarQt.cpp:
1636         (WebCore::Scrollbar::contextMenu):
1637
1638 2008-11-14  Tor Arne Vestbø  <tavestbo@trolltech.com>
1639
1640         Rubber-stamped by Simon Hausmann.
1641
1642         Make scrollbar look active when the window is active on Qt/Mac
1643
1644         * platform/qt/ScrollbarThemeQt.cpp:
1645         (WebCore::styleOptionSlider):
1646         (WebCore::ScrollbarThemeQt::paint):
1647
1648 2008-11-13  Eric Seidel  <eric@webkit.org>
1649
1650         Reviewed by Adam Roben.
1651
1652         Add a basic Scons-based build system for building
1653         Chromium-Mac WebCore.
1654         https://bugs.webkit.org/show_bug.cgi?id=21991
1655
1656         The build currently fails due to missing files from our
1657         platform directory (platform skia and platform chromium)
1658         I will be sending those up shortly in separate patches.
1659         I expect it will be a while before our WebCore build links.
1660
1661         * SConstruct: Added.
1662         * WebCore.scons: Added.
1663
1664 2008-11-13  Darin Fisher  <darin@chromium.org>
1665
1666         Reviewed by Darin Adler.
1667
1668         https://bugs.webkit.org/show_bug.cgi?id=22248
1669         AtomicString.cpp uses JSC types outside of #if USE(JSC)
1670
1671         * platform/text/AtomicString.cpp:
1672         (WebCore::AtomicString::add):
1673         
1674 2008-11-13  Justin Garcia  <justin.garcia@apple.com>
1675
1676         Reviewed by Darin Adler.
1677         
1678         https://bugs.webkit.org/show_bug.cgi?id=18620
1679         Long hang under TextIterator::advance() when loading http://www.lsvd.de/
1680
1681         A huge section at the beginning of this document is invisible.  As we iterate through it,
1682         we create VisiblePositions unnecessarily.
1683
1684         * editing/TextIterator.cpp:
1685         (WebCore::TextIterator::shouldRepresentNodeOffsetZero): Don't proceed to VisiblePosition 
1686         creation if m_node is unrendered or invisible.  The answers wouldn't have much meaning 
1687         and would be wasteful.  Also fixed some comments to reflect the fact that this function
1688         isn't specifically about emitting a newline.
1689
1690 2008-11-13  Pierre-Olivier Latour  <pol@apple.com>
1691
1692         Reviewed by Sam Weinig.
1693
1694         Remove unused or unnecessary code from AnimationBase class.
1695
1696         * page/animation/AnimationBase.cpp:
1697         (WebCore::AnimationBase::AnimationBase):
1698         (WebCore::AnimationBase::playStatePlaying):
1699         * page/animation/AnimationBase.h:
1700
1701 2008-11-12  Tor Arne Vestbø  <tavestbo@trolltech.com>
1702
1703         Reviewed by Simon Hausmann.
1704
1705         Inital implementation of PluginPackage and PluginView for Mac NPAPI support in WebCore
1706
1707         Currently only used by QtWebKit. See also:
1708
1709         https://bugs.webkit.org/show_bug.cgi?id=21427
1710
1711         * WebCore.pro:
1712         * platform/qt/TemporaryLinkStubs.cpp:
1713         (PluginView::userAgentStatic):
1714         (PluginView::getValueStatic):
1715         * plugins/PluginView.cpp:
1716         (WebCore::PluginView::handleEvent):
1717         (WebCore::PluginView::setValue):
1718         (WebCore::PluginView::PluginView):
1719         * plugins/PluginView.h:
1720         (WebCore::PluginView::setPlatformPluginWidget):
1721         * plugins/mac/PluginPackageMac.cpp: Added.
1722         (WebCore::PluginPackage::determineQuirks):
1723         (WebCore::readPListFile):
1724         (WebCore::stringListFromResourceId):
1725         (WebCore::PluginPackage::fetchInfo):
1726         (WebCore::PluginPackage::load):
1727         (WebCore::PluginPackage::hash):
1728         (WebCore::PluginPackage::equal):
1729         (WebCore::PluginPackage::compareFileVersion):
1730         * plugins/mac/PluginViewMac.cpp: Added.
1731         (WebCore::nativeWindowFor):
1732         (WebCore::cgHandleFor):
1733         (WebCore::topLevelOffsetFor):
1734         (WebCore::PluginView::init):
1735         (WebCore::PluginView::~PluginView):
1736         (WebCore::PluginView::stop):
1737         (WebCore::PluginView::getValueStatic):
1738         (WebCore::PluginView::getValue):
1739         (WebCore::PluginView::setParent):
1740         (WebCore::PluginView::show):
1741         (WebCore::PluginView::hide):
1742         (WebCore::PluginView::setFocus):
1743         (WebCore::PluginView::setParentVisible):
1744         (WebCore::PluginView::setNPWindowRect):
1745         (WebCore::PluginView::setNPWindowIfNeeded):
1746         (WebCore::PluginView::updatePluginWidget):
1747         (WebCore::PluginView::paint):
1748         (WebCore::PluginView::invalidateRect):
1749         (WebCore::PluginView::invalidateRegion):
1750         (WebCore::PluginView::forceRedraw):
1751         (WebCore::PluginView::handleMouseEvent):
1752         (WebCore::PluginView::handleKeyboardEvent):
1753         (WebCore::PluginView::nullEventTimerFired):
1754         (WebCore::modifiersForEvent):
1755         (WebCore::PluginView::globalMousePosForPlugin):
1756         (WebCore::PluginView::dispatchNPEvent):
1757         (WebCore::PluginView::userAgent):
1758         (WebCore::PluginView::userAgentStatic):
1759         (WebCore::PluginView::handlePostReadFile):
1760
1761 2008-11-12  Alexey Proskuryakov  <ap@webkit.org>
1762
1763         Reviewed by Darin Adler.
1764
1765         https://bugs.webkit.org/show_bug.cgi?id=22200
1766         Crash when close event is dispatched to MessagePort due to document destruction
1767
1768         Test: fast/events/message-port-onclose.html
1769
1770         * dom/MessagePort.cpp: (WebCore::MessagePort::contextDestroyed):
1771         Don't dispatch close event, even though HTML5 currently says that we should. It is not
1772         right for GC to have observable effects.
1773
1774 2008-11-12  Alexey Proskuryakov  <ap@webkit.org>
1775
1776         Reviewed by Darin Adler.
1777
1778         https://bugs.webkit.org/show_bug.cgi?id=22203
1779         Implement Worker messaging
1780
1781         No test cases included, because this functionality is disabled by default.
1782
1783         The implementation is known to still have many race condition, but works quite well for
1784         testing.
1785
1786         * WebCore.xcodeproj/project.pbxproj: Added WorkerTask.{h,cpp}.
1787
1788         * bindings/js/JSDOMBinding.cpp:
1789         (WebCore::markActiveObjectsForContext): Re-worded comments a little.
1790         (WebCore::markCrossHeapDependentObjectsForContext): Existing cross-heap GC protocol was
1791         incorrect, changed it to a much simpler (but still incorrect) version.
1792
1793         * dom/WorkerTask.cpp: Added.
1794         (WebCore::WorkerTask::~WorkerTask):
1795         * dom/WorkerTask.h: Added.
1796         Tasks posted to workers implement this new interface.
1797
1798         * bindings/js/JSDedicatedWorkerCustom.cpp:
1799         (WebCore::JSDedicatedWorker::mark):
1800         (WebCore::JSDedicatedWorker::connect):
1801         * dom/DedicatedWorker.h:
1802         * dom/DedicatedWorker.idl:
1803         Auto-generate event listener attributes. Renamed startConversation() to connect(), tracking
1804         WHATWG discussions.
1805
1806         * dom/DedicatedWorker.cpp:
1807         (WebCore::WorkerConnectTask::WorkerConnectTask): A task that performs worker-side connect()
1808         operations.
1809         (WebCore::DedicatedWorker::DedicatedWorker): Initialize WorkerThread pointer.
1810         (WebCore::DedicatedWorker::connect): Connect() creates a pair of entangled ports, and posts
1811         one to worker. Since message port registration in ScriptExecutionContext is not thread safe,
1812         this port starts with a null context pointer.
1813         (WebCore::DedicatedWorker::notifyFinished): Since Worker methods should work immediately
1814         after creation, we have to queue tasks until after a WorkerThread object is created. Then we
1815         forward all queued tasks to its queue.
1816
1817         * dom/EventTarget.cpp: (WebCore::EventTarget::toWorkerContext):
1818         * dom/EventTarget.h:
1819         * bindings/js/JSEventTarget.cpp: (WebCore::toJS):
1820         Added cases for WorkerContext, which is now an EventTarget, too.
1821
1822         * bindings/js/JSWorkerContext.h: Added JSWorkerContext::put() to make onconnect settable.
1823         * bindings/js/JSWorkerContext.cpp:
1824         (WebCore::JSWorkerContext::mark): Mark event listeners.
1825         (WebCore::JSWorkerContext::createPrototype): Fixed a typo, use the right StructureID.
1826         (WebCore::JSWorkerContext::put): Implemented.
1827         (WebCore::jsWorkerContextPrototypeFunctionAddEventListener): Added an EventTarget implementation.
1828         (WebCore::jsWorkerContextPrototypeFunctionRemoveEventListener): Ditto.
1829         (WebCore::jsWorkerContextPrototypeFunctionDispatchEvent): Ditto.
1830         (WebCore::jsWorkerContextOnconnect): Added.
1831         (WebCore::setJSWorkerContextOnconnect): Added.
1832
1833         * bindings/js/WorkerScriptController.cpp: (WebCore::WorkerScriptController::evaluate):
1834         Made it actually work by adding necessary setup.
1835
1836         * bindings/js/WorkerScriptController.h: (WebCore::WorkerScriptController::initScriptIfNeeded):
1837         Check the right variable - it is the wrapper that may not be initialized yet.
1838
1839         * dom/ActiveDOMObject.cpp:
1840         (WebCore::ActiveDOMObject::ActiveDOMObject):
1841         (WebCore::ActiveDOMObject::~ActiveDOMObject):
1842         Assert being called from the correct thread, as active DOM object tracking is not thread safe.
1843
1844         * dom/ScriptExecutionContext.h: Added a Task interface and a postTask() method, to be used
1845         for asynchronously executing tasks in context's thread.
1846
1847         * dom/ScriptExecutionContext.cpp:
1848         (WebCore::ProcessMessagesSoonTask): Changed from a Timer to a Task
1849         (WebCore::ScriptExecutionContext::ScriptExecutionContext): Removed m_firedMessagePortTimer.
1850         It was an optimization that couldn't be easily preserved without introducing race conditions
1851         in multithreading case.
1852         (WebCore::ScriptExecutionContext::processMessagePortMessagesSoon): Use postTask().
1853         (WebCore::ScriptExecutionContext::dispatchMessagePortEvents): Added a comment explaining
1854         why it's OK to not ref() ports in a frozen copy.
1855         (WebCore::ScriptExecutionContext::createdMessagePort): Assert that we're not being called
1856         from a wrong thread.
1857         (WebCore::ScriptExecutionContext::destroyedMessagePort): Ditto.
1858         (WebCore::ScriptExecutionContextTaskTimer): Part of
1859         ScriptExecutionContext::Task implementation - use Timer if posting from main thread to main
1860         thread.
1861         (WebCore::ScriptExecutionContextTaskWorkerTask): Another part - use WorkerTask if posting
1862         to a worker.
1863         (WebCore::PerformTaskContext::PerformTaskContext): Finally, use callOnMainThread() if posting
1864         to main thread from a secondary one.
1865         (WebCore::performTask): A helper function for callOnMainThread().
1866         (WebCore::ScriptExecutionContext::postTask): Use one of the above implementations.
1867
1868         * dom/MessagePort.h: Fixed message queue to keep EventData pointers - otherwise, we would
1869         ref/deref EventData::message from different threads, which is not allowed.
1870
1871         * dom/MessagePort.cpp:
1872         (WebCore::MessagePortCloseEventTask): Use a task instead of a timer to work across threads.
1873         (WebCore::MessagePort::EventData::create): Updated for EventData being refcountable now.
1874         (WebCore::MessagePort::EventData::EventData): Ditto.
1875         (WebCore::MessagePort::MessagePort): ScriptExecutionContext is now allowed to be null at
1876         first, because we need to create ports for posting to other threads, and it is not possible
1877         to register in a context from another thread.
1878         (WebCore::MessagePort::clone): Always create ports with null contexts - it is now message
1879         receiver's job to set the context.
1880         (WebCore::MessagePort::postMessage): Enable posting to ports that are not attached to any
1881         context yet.
1882         (WebCore::MessagePort::startConversation): Ditto. Data port is always posted unattached.
1883         (WebCore::MessagePort::contextDestroyed): Assert that we had a context.
1884         (WebCore::MessagePort::attachToContext): Called when receiving a data port to register in
1885         context.
1886         (WebCore::MessagePort::scriptExecutionContext): Moved from header, as the function is virtual.
1887         (WebCore::MessagePort::dispatchMessages): Attach data port to receiving context. Use postTask().
1888         (WebCore::MessagePort::queueCloseEvent): Use postTask().
1889         (WebCore::MessagePort::hasPendingActivity): Reworded comment a little. As mentioned above,
1890         MessagePort cross-heap GC is still quite wrong.
1891
1892         * dom/WorkerContext.h: Made WorkerContext an event target, added onconnect attribute.
1893         * dom/WorkerContext.cpp: Keep a pointer to WorkerThread. It is only used for debug assertions
1894         now, but there is no harm in tracking it in release builds, too.
1895
1896         * dom/WorkerThread.cpp:
1897         (WebCore::WorkerThread::create): WorkerThread is refcountable, construct with create().
1898         (WebCore::WorkerThread::workerThread): Implemented a message loop.
1899         * dom/WorkerThread.h:
1900         (WebCore::WorkerThread::threadID): Also only used for assertions.
1901         (WebCore::WorkerThread::messageQueue): Return a reference to queue, so clients can post to it.
1902
1903         * page/DOMWindow.cpp:
1904         (WebCore::DOMWindow::postMessage): MessagePort::clone() no longer takes a context, as it
1905         always sets it to null.
1906         (WebCore::DOMWindow::postMessageTimerFired): Attach data port to receiving context.
1907
1908 2008-11-12  Dirk Schulze  <vbs85@gmx.de>
1909
1910         Reviewed Darin Adler.
1911
1912         use strokeColor.alpha() instead of fillColor.alpha()
1913         on GraphicsContext::strokePath()
1914
1915         [Canvas] Transparent fillStyle stops line rendering
1916         https://bugs.webkit.org/show_bug.cgi?id=21888
1917
1918         Test: fast/canvas/canvas-stroke-empty-fill.html
1919
1920         * ChangeLog:
1921         * platform/graphics/cg/GraphicsContextCG.cpp:
1922         (WebCore::GraphicsContext::strokePath):
1923
1924 2008-11-12  Stephanie  <slewis@apple.com>
1925
1926         Reviewed by Mark Rowe.
1927
1928         Fix context leak in XSLStyleSheets.
1929         See bug https://bugs.webkit.org/show_bug.cgi?id=15715
1930
1931         * xml/XSLStyleSheet.cpp:
1932         (WebCore::XSLStyleSheet::parseString):
1933
1934 2008-11-12  Alp Toker  <alp@nuanti.com>
1935
1936         autotools: List web worker-related headers needed for a successful
1937         build. distcheck is passing again with this change.
1938
1939         * GNUmakefile.am:
1940
1941 2008-11-12  Alp Toker  <alp@nuanti.com>
1942
1943         autotools build system fix-up only. Add FloatQuad.h to the source
1944         lists and sort them.
1945
1946         * GNUmakefile.am:
1947
1948 2008-11-12  Alp Toker  <alp@nuanti.com>
1949
1950         Build fixes for r38346. FloatQuad.cpp is missing:
1951
1952         1) #include "config.h"
1953         2) #include <algorithm> for various mathematical definitions it uses.
1954
1955         * platform/graphics/FloatQuad.cpp:
1956
1957 2008-11-12  Simon Fraser  <simon.fraser@apple.com>
1958
1959         Reviewed by Dan Bernstein
1960
1961         https://bugs.webkit.org/show_bug.cgi?id=22212
1962
1963         Rename absoluteOutlineBox() to absoluteOutlineBounds(), to indicate that
1964         it may be the bounding outline box of a transformed element, and fix it
1965         to respect transforms by mapping the outline box to an absolute quad and
1966         taking the enclosing rect.
1967         
1968         RenderBox::localToAbsoluteQuad() can no longer assert that there is no
1969         LayoutState, but LayoutState cannot be used during quad mapping (it knows
1970         nothing about transforms).
1971         
1972         Finally, fix a bug in RenderBox::localToAbsoluteQuad() which was getting
1973         borderTopExtra() from the object, rather than its container (as localToAbsolute()
1974         does).
1975         
1976         Test: fast/repaint/transform-absolute-child.html
1977
1978         * rendering/RenderBlock.cpp:
1979         (WebCore::RenderBlock::layoutBlock):
1980         * rendering/RenderBox.cpp:
1981         (WebCore::RenderBox::localToAbsoluteQuad):
1982         * rendering/RenderFlexibleBox.cpp:
1983         (WebCore::RenderFlexibleBox::layoutBlock):
1984         * rendering/RenderForeignObject.cpp:
1985         (WebCore::RenderForeignObject::layout):
1986         * rendering/RenderLayer.cpp:
1987         (WebCore::RenderLayer::updateLayerPositions):
1988         (WebCore::RenderLayer::setHasVisibleContent):
1989         * rendering/RenderObject.cpp:
1990         (WebCore::RenderObject::repaintAfterLayoutIfNeeded):
1991         (WebCore::RenderObject::absoluteOutlineBounds):
1992         * rendering/RenderObject.h:
1993         * rendering/RenderPath.cpp:
1994         (WebCore::RenderPath::layout):
1995         * rendering/RenderReplaced.cpp:
1996         (WebCore::RenderReplaced::layout):
1997         * rendering/RenderSVGContainer.cpp:
1998         (WebCore::RenderSVGContainer::layout):
1999         * rendering/RenderSVGImage.cpp:
2000         (WebCore::RenderSVGImage::layout):
2001         * rendering/RenderSVGRoot.cpp:
2002         (WebCore::RenderSVGRoot::layout):
2003         * rendering/RenderSVGText.cpp:
2004         (WebCore::RenderSVGText::layout):
2005         * rendering/RenderSVGViewportContainer.cpp:
2006         (WebCore::RenderSVGViewportContainer::layout):
2007         * rendering/RenderTable.cpp:
2008         (WebCore::RenderTable::layout):
2009
2010 2008-11-12  Simon Fraser  <simon.fraser@apple.com>
2011
2012         Reviewed by Dave Hyatt
2013
2014         https://bugs.webkit.org/show_bug.cgi?id=21942
2015         https://bugs.webkit.org/show_bug.cgi?id=18557
2016         
2017         Add methods which can be used to map renderer-local rectangles
2018         to quads in absolute coordinates, taking transforms into account:
2019             localToAbsoluteQuad() converts a local rect into an absolute quad.
2020             collectAbsoluteLineBoxQuads() is an analogue of addLineBoxRects()
2021                 that works with quads.
2022             absoluteQuads() is an analogue of absoluteRects(), for quads.
2023         
2024         Use the quad methods to fix the inspector highlight for transformed
2025         elements.
2026
2027         * GNUmakefile.am:
2028         * WebCore.pro:
2029         * WebCore.vcproj/WebCore.vcproj:
2030         * WebCore.xcodeproj/project.pbxproj:
2031         * WebCoreSources.bkl:
2032         * inspector/InspectorController.cpp:
2033         (WebCore::drawOutlinedQuad):
2034         (WebCore::drawHighlightForBoxes):
2035         (WebCore::frameToMainFrameOffset):
2036         (WebCore::InspectorController::drawNodeHighlight):
2037         * platform/graphics/AffineTransform.cpp:
2038         (WebCore::AffineTransform::mapQuad):
2039         * platform/graphics/AffineTransform.h:
2040         * platform/graphics/FloatQuad.cpp: Added.
2041         (WebCore::min4):
2042         (WebCore::max4):
2043         (WebCore::FloatQuad::boundingBox):
2044         * platform/graphics/FloatQuad.h: Added.
2045         (WebCore::FloatQuad::FloatQuad):
2046         (WebCore::FloatQuad::p1):
2047         (WebCore::FloatQuad::p2):
2048         (WebCore::FloatQuad::p3):
2049         (WebCore::FloatQuad::p4):
2050         (WebCore::FloatQuad::setP1):
2051         (WebCore::FloatQuad::setP2):
2052         (WebCore::FloatQuad::setP3):
2053         (WebCore::FloatQuad::setP4):
2054         (WebCore::FloatQuad::isEmpty):
2055         (WebCore::FloatQuad::enclosingBoundingBox):
2056         (WebCore::FloatQuad::move):
2057         (WebCore::operator+=):
2058         (WebCore::operator-=):
2059         (WebCore::operator==):
2060         (WebCore::operator!=):
2061         * rendering/RenderBox.cpp:
2062         (WebCore::RenderBox::localToAbsoluteQuad):
2063         * rendering/RenderBox.h:
2064         * rendering/RenderContainer.cpp:
2065         (WebCore::RenderContainer::collectAbsoluteLineBoxQuads):
2066         * rendering/RenderContainer.h:
2067         * rendering/RenderInline.cpp:
2068         (WebCore::RenderInline::absoluteQuads):
2069         * rendering/RenderInline.h:
2070         * rendering/RenderObject.cpp:
2071         (WebCore::RenderObject::absoluteBoundingBoxRect):
2072         (WebCore::RenderObject::collectAbsoluteLineBoxQuads):
2073         (WebCore::RenderObject::absoluteQuads):
2074         (WebCore::RenderObject::localToAbsoluteQuad):
2075         (WebCore::RenderObject::absoluteContentQuad):
2076         * rendering/RenderObject.h:
2077         * rendering/RenderPath.cpp:
2078         (WebCore::RenderPath::absoluteQuads):
2079         * rendering/RenderPath.h:
2080         * rendering/RenderSVGContainer.cpp:
2081         (WebCore::RenderSVGContainer::absoluteQuads):
2082         * rendering/RenderSVGContainer.h:
2083         * rendering/RenderSVGHiddenContainer.cpp:
2084         (WebCore::RenderSVGHiddenContainer::absoluteQuads):
2085         * rendering/RenderSVGHiddenContainer.h:
2086         * rendering/RenderSVGImage.cpp:
2087         (WebCore::RenderSVGImage::calculateAbsoluteBounds):
2088         (WebCore::RenderSVGImage::absoluteQuads):
2089         * rendering/RenderSVGImage.h:
2090         * rendering/RenderSVGInlineText.cpp:
2091         (WebCore::RenderSVGInlineText::absoluteQuads):
2092         (WebCore::RenderSVGInlineText::computeAbsoluteRectForRange):
2093         * rendering/RenderSVGInlineText.h:
2094         * rendering/RenderSVGRoot.cpp:
2095         (WebCore::RenderSVGRoot::absoluteQuads):
2096         * rendering/RenderSVGRoot.h:
2097         * rendering/RenderSVGTSpan.cpp:
2098         (WebCore::RenderSVGTSpan::absoluteRects):
2099         (WebCore::RenderSVGTSpan::absoluteQuads):
2100         * rendering/RenderSVGTSpan.h:
2101         * rendering/RenderSVGText.cpp:
2102         (WebCore::RenderSVGText::absoluteRects):
2103         (WebCore::RenderSVGText::absoluteQuads):
2104         * rendering/RenderSVGText.h:
2105         * rendering/RenderSVGTextPath.cpp:
2106         (WebCore::RenderSVGTextPath::absoluteRects):
2107         (WebCore::RenderSVGTextPath::absoluteQuads):
2108         * rendering/RenderSVGTextPath.h:
2109         * rendering/RenderTableCell.cpp:
2110         (WebCore::RenderTableCell::localToAbsolute):
2111         (WebCore::RenderTableCell::localToAbsoluteQuad):
2112         * rendering/RenderTableCell.h:
2113         * rendering/RenderText.cpp:
2114         (WebCore::RenderText::absoluteQuads):
2115         (WebCore::RenderText::collectAbsoluteLineBoxQuads):
2116         * rendering/RenderText.h:
2117         * rendering/RenderView.cpp:
2118         (WebCore::RenderView::localToAbsoluteQuad):
2119         (WebCore::RenderView::absoluteQuads):
2120         * rendering/RenderView.h:
2121
2122 2008-11-12  Brent Fulgham <bfulgham@gmail.com>
2123
2124         Fix Bug 22178: Build errors in WebKit Cairo port
2125
2126         <https://bugs.webkit.org/show_bug.cgi?id=22178>
2127
2128         Reviewed by Mark Rowe.
2129
2130         * platform/graphics/cairo/PatternCairo.cpp: Correct build error under
2131         Visual Studio.
2132         (WebCore::Pattern::createPlatformPattern):
2133
2134 2008-11-12  Adam Roben  <aroben@apple.com>
2135
2136         Fix a typo in the include path for the Release_Cairo configuration
2137
2138         * WebCore.vcproj/WebCore.vcproj: Fixed "caro" -> "cairo" typo.
2139
2140 2008-11-12  Simon Fraser  <simon.fraser@apple.com>
2141
2142         Reviewed by Dave Hyatt
2143
2144         https://bugs.webkit.org/show_bug.cgi?id=17840
2145         Patch 2
2146         
2147         Code cleanup in RenderBox::computeAbsoluteRepaintRect().
2148
2149         * rendering/RenderBox.cpp:
2150         (WebCore::RenderBox::computeAbsoluteRepaintRect):
2151
2152 2008-11-12  Simon Fraser  <simon.fraser@apple.com>
2153
2154         Reviewed by Dave Hyatt
2155
2156         https://bugs.webkit.org/show_bug.cgi?id=17840
2157
2158         Fix repainting when the transform on a positioned element changes.
2159         In computeAbsoluteRepaintRect(), add the offsets due to relative positioning,
2160         and being in a positioned container after applying the transform to the local
2161         rect.
2162
2163         Tests: fast/repaint/transform-absolute-in-positioned-container.html
2164                fast/repaint/transform-relative-position.html
2165
2166         * rendering/RenderBox.cpp:
2167         (WebCore::RenderBox::computeAbsoluteRepaintRect):
2168
2169 2008-11-12  Justin Garcia  <justin.garcia@apple.com>
2170  
2171         Reviewed by Beth Dakin.
2172  
2173         <rdar://problem/5495723> Selecting and deleting quoted text quotes other text
2174         <rdar://problem/4775313> Deleting lines from the bottom of a messages leaves the last blank line quoted
2175         
2176         We don't want to merge into a block if it will mean changing the quote level of content after deleting 
2177         selections that contain a whole number paragraphs plus a line break, since it is unclear to most users 
2178         that such a selection actually ends at the start of the next paragraph.  Instead we want to completely
2179         remove the selected paragraph(s) and all evidence of the first one's quote level.  This matches TextEdit behavior 
2180         for indented paragraphs.
2181  
2182         * editing/DeleteSelectionCommand.cpp:
2183         (WebCore::DeleteSelectionCommand::initializePositionData): For the selections described above, do not
2184         try to merge after the deletion.  Instead try and prune the start block or blocks if they've been emptied
2185         so that we remove evidence of the deleted paragraphs' quote level.
2186         (WebCore::DeleteSelectionCommand::mergeParagraphs): Try and prune the start block(s) if necessary.  Also 
2187         make sure that the caret is placed correctly so that it ends up on the same line that the deleted selection 
2188         started on, instead of one higher.
2189         * editing/DeleteSelectionCommand.h:
2190         * editing/htmlediting.cpp:
2191         (WebCore::numEnclosingMailBlockquotes): Added.
2192         * editing/htmlediting.h:
2193
2194 2008-11-10  Tor Arne Vestbø  <tavestbo@trolltech.com>
2195
2196         Reviewed by Simon Hausmann.
2197
2198         Move _web_encodingForResource from WebKit into WebCore and change return type
2199
2200         This change is needed to implement NSAPI in WebCore for Mac, see:
2201
2202         https://bugs.webkit.org/show_bug.cgi?id=21427
2203
2204         * WebCore.base.exp:
2205         * platform/mac/WebCoreNSStringExtras.h:
2206         * platform/mac/WebCoreNSStringExtras.mm:
2207         (stringEncodingForResource):
2208
2209 2008-11-10  Tor Arne Vestbø  <tavestbo@trolltech.com>
2210
2211         Reviewed by Simon Hausmann.
2212
2213         Moved the implementation of _webkit_isCaseInsensitiveEqualToString to
2214         WebCore's WebCoreNSStringExtras as _stringIsCaseInsensitiveEqualToString.
2215
2216         This change is needed to implement NSAPI in WebCore for Mac, see:
2217
2218         https://bugs.webkit.org/show_bug.cgi?id=21427
2219
2220         * WebCore.base.exp:
2221         * platform/mac/WebCoreNSStringExtras.h:
2222         * platform/mac/WebCoreNSStringExtras.mm:
2223         (stringIsCaseInsensitiveEqualToString):
2224
2225 2008-11-11  Stephanie  <slewis@apple.com>
2226
2227         Reviewed by Dan Bernstein.
2228
2229         Null check image data before setting it as image source.
2230
2231         Test: fast/images/image-empty-data.html
2232
2233         * platform/graphics/BitmapImage.cpp:
2234         (WebCore::BitmapImage::destroyDecodedData):
2235
2236 2008-11-11  Adele Peterson  <adele@apple.com>
2237
2238         Reviewed by Tim Hatcher.
2239
2240         Remove ifdef so future OS versions can use the new delegate method.
2241
2242         * platform/network/mac/ResourceHandleMac.mm: (WebCore::ResourceHandle::didSendBodyDataDelegateExists):
2243
2244 2008-11-11  Eric Seidel  <eric@webkit.org>
2245
2246         Reviewed by Antti Koivisto and Sam Weinig.
2247
2248         Clean up HTMLTokenizer a litle
2249         https://bugs.webkit.org/show_bug.cgi?id=22188
2250
2251         Rename pendingScripts to m_pendingScripts
2252         Rename scriptNode to m_scriptNode make the type specific
2253         Rename pendingSrc to m_pendingSrc
2254         Rename currentPrependingSrc to m_currentPrependingSrc
2255         Rename noMoreData to m_noMoreData and cBuffer to m_cBuffer
2256         Remove long-since-dead kdDebug and qDebug calls
2257         Rename brokenComments to m_brokenComments
2258         Remove HTMLTokenizer includes and document the rest
2259         Rename src to m_src
2260         Rename parser to m_parser and make it an OwnPtr
2261         Rename inWrite to m_inWrite and jsProxy to scriptController
2262         Rename brokenServer to m_brokenServer
2263         Rename buffer to m_buffer and dest to m_dest
2264         Rename size to m_bufferSize
2265         Rename attrName to m_attrName
2266         Rename searchStopper to m_searchStopper and searchStopperLen to m_searchStopperLen
2267         Rename scriptCode* to m_scriptCode* and change scriptCodeMax to m_scriptCodeCapacity
2268         Rename scriptStartLineno to m_currentScriptTagStartLineNumber and tagStartLineno to m_currentTagStartLineNumber
2269         Rename scriptSrc to m_scriptTagSrcAttrValue and scriptSrcCharset to m_scriptTagCharsetAttrValue -- a bit unwieldy, but more precise
2270         Rename flat to selfClosingTag
2271         Rename currToken to m_currentToken
2272
2273         * css/CSSParser.cpp:
2274         * dom/XMLTokenizer.cpp:
2275         * dom/XMLTokenizerLibxml2.cpp:
2276         * html/HTMLDocument.cpp:
2277         * html/HTMLElement.cpp:
2278         * html/HTMLFormControlElement.cpp:
2279         * html/HTMLParser.h:
2280         * html/HTMLTokenizer.cpp:
2281         (WebCore::Token::addAttribute):
2282         (WebCore::HTMLTokenizer::HTMLTokenizer):
2283         (WebCore::HTMLTokenizer::reset):
2284         (WebCore::HTMLTokenizer::begin):
2285         (WebCore::HTMLTokenizer::processListing):
2286         (WebCore::HTMLTokenizer::parseSpecial):
2287         (WebCore::HTMLTokenizer::scriptHandler):
2288         (WebCore::HTMLTokenizer::scriptExecution):
2289         (WebCore::HTMLTokenizer::parseComment):
2290         (WebCore::HTMLTokenizer::parseServer):
2291         (WebCore::HTMLTokenizer::parseProcessingInstruction):
2292         (WebCore::HTMLTokenizer::parseText):
2293         (WebCore::HTMLTokenizer::parseEntity):
2294         (WebCore::HTMLTokenizer::parseTag):
2295         (WebCore::HTMLTokenizer::write):
2296         (WebCore::HTMLTokenizer::processingData):
2297         (WebCore::HTMLTokenizer::end):
2298         (WebCore::HTMLTokenizer::finish):
2299         (WebCore::HTMLTokenizer::processToken):
2300         (WebCore::HTMLTokenizer::processDoctypeToken):
2301         (WebCore::HTMLTokenizer::~HTMLTokenizer):
2302         (WebCore::HTMLTokenizer::enlargeBuffer):
2303         (WebCore::HTMLTokenizer::enlargeScriptBuffer):
2304         (WebCore::HTMLTokenizer::notifyFinished):
2305         (WebCore::HTMLTokenizer::setSrc):
2306         * html/HTMLTokenizer.h:
2307         (WebCore::Token::Token):
2308         (WebCore::Token::reset):
2309         (WebCore::HTMLTokenizer::processingContentWrittenByScript):
2310         (WebCore::HTMLTokenizer::htmlParser):
2311         (WebCore::HTMLTokenizer::checkBuffer):
2312         (WebCore::HTMLTokenizer::checkScriptBuffer):
2313         * html/HTMLViewSourceDocument.h:
2314         * rendering/RenderBlock.cpp:
2315         (WebCore::RenderBlock::leftRelOffset):
2316         (WebCore::RenderBlock::rightRelOffset):
2317         (WebCore::RenderBlock::lineWidth):
2318         * xml/XSLTProcessor.cpp:
2319
2320 2008-11-11  Sam Weinig  <sam@webkit.org>
2321
2322         Reviewed by Dan Bernstein.
2323
2324         Fix for https://bugs.webkit.org/show_bug.cgi?id=22189
2325         Track CachedScript decoded data
2326
2327         We now track the decoded size of CachedScripts in the Cache allowing
2328         them to accounted for when deciding when to evict data.  The decoded
2329         data itself can be evicted when Cache pressure gets high enough through
2330         CachedScript::destroyDecodedData.
2331
2332         * loader/CachedResource.h:
2333         (WebCore::CachedResource::allClientsRemoved):
2334         (WebCore::CachedResource::destroyDecodedData):
2335         * loader/CachedScript.cpp:
2336         (WebCore::CachedScript::script):
2337         (WebCore::CachedScript::data):
2338         (WebCore::CachedScript::destroyDecodedData):
2339         * loader/CachedScript.h:
2340
2341 2008-11-11  Cameron Zwarich  <zwarich@apple.com>
2342
2343         Reviewed by Geoff Garen.
2344
2345         Remove pointless dependencies on the now-deleted kjs directory and
2346         mentions of it in comments that are no longer relevant.
2347
2348         * WebCore.pro:
2349         * webcore-base.bkl:
2350
2351 2008-11-11  Dan Bernstein  <mitz@apple.com>
2352
2353         Reviewed by Adam Roben.
2354
2355         WebCore part of adding a master volume control for media elements in a WebView
2356
2357         * WebCore.base.exp: Exported WebCore::Page::setMediaVolume().
2358         * dom/Document.cpp:
2359         (WebCore::Document::mediaVolumeDidChange): Added. Called by the Page
2360         when the media volume is changed.
2361         (WebCore::Document::registerForMediaVolumeCallbacks): Added. Allows
2362         elements to register for a callback when the media volume is changed.
2363         (WebCore::Document::unregisterForMediaVolumeCallbacks): Added. Allows
2364         elements to unregister for the callback.
2365         * dom/Document.h:
2366         * dom/Element.h:
2367         (WebCore::Element::mediaVolumeDidChange): Added an empty implementation.
2368         * html/HTMLMediaElement.cpp:
2369         (WebCore::HTMLMediaElement::HTMLMediaElement): Added a call to
2370         registerForMediaVolumeCallbacks().
2371         (WebCore::HTMLMediaElement::~HTMLMediaElement): Added a call to
2372         unregisterForMediaVolumeCallbacks().
2373         (WebCore::HTMLMediaElement::updateVolume): Changed to multiply the
2374         element's intrinsic volume by the master volume from the page.
2375         (WebCore::HTMLMediaElement::mediaVolumeDidChange): Added. Calls
2376         updateVolume().
2377         * html/HTMLMediaElement.h:
2378         * page/Page.cpp:
2379         (WebCore::Page::Page): Initialize m_mediaVolume to 1.
2380         (WebCore::Page::setMediaVolume): Added. Calls mediaVolumeDidChange() on
2381         every document in the page when the master volume changes.
2382         * page/Page.h:
2383         (WebCore::Page::mediaVolume): Added this getter.
2384
2385 2008-11-11  David Hyatt  <hyatt@apple.com>
2386
2387         https://bugs.webkit.org/show_bug.cgi?id=22182
2388
2389         Fix problems with scrollbars when the OS setting for clicks in the track jumping the thumb to that location
2390         is turned on.  Make sure to only jump the thumb if the click happens in the track.  Also fix some math
2391         errors when jumping the thumb that cause dragging after the jump to incorrectly jump the thumb again.
2392
2393         Reviewed by Adele
2394
2395         * platform/Scrollbar.cpp:
2396         (WebCore::Scrollbar::mouseDown):
2397
2398 2008-11-11  Beth Dakin  <bdakin@apple.com>
2399
2400         Reviewed by Darin Adler.
2401
2402         Fix for <rdar://problem/5089327> Too much indentation when pasting 
2403         quoted paragraphs
2404
2405         This patch re-addresses pasting blockquotes into blockquotes. It 
2406         backs out most of revision 38273. 38273 fixed the bug by inserting 
2407         the pasted content as a sibling blockquote node to the pre-existing 
2408         blockquote node. The problem with that is that by default, 
2409         blockquotes have a giant margin, so visually, this can be weird. 
2410         This patch instead inserts the pasted content as siblings of the 
2411         the content already inside the outer blockquote, and then removes 
2412         the blockquote node from the pasted content itself, so that it 
2413         doesn't nest itself into the outer blockquote.
2414         * editing/ReplaceSelectionCommand.cpp:
2415         (WebCore::ReplaceSelectionCommand::doApply):
2416
2417         Move contains() from Element to Node since there is nothing 
2418         Element-specific about it.
2419         * dom/Element.cpp:
2420         * dom/Element.h:
2421         * dom/Node.cpp:
2422         (WebCore::Node::contains):
2423         * dom/Node.h:
2424
2425 2008-11-11  David Hyatt  <hyatt@apple.com>
2426
2427         https://bugs.webkit.org/show_bug.cgi?id=17997
2428
2429         Stop using the new Leopard API tiling call for scaled tiles when drawing background images.  The method
2430         is buggy.  Fall back to using the slower (and more correct) pattern tiling that Tiger still uses.  This
2431         is a Leopard-only workaround, since the API has been fixed on Snow Leopard.
2432
2433         Reviewed by John Sullivan
2434
2435         * platform/graphics/cg/ImageCG.cpp:
2436         (WebCore::Image::drawPattern):
2437
2438 2008-11-10  David Hyatt  <hyatt@apple.com>
2439
2440         Disable the Aqua look for menu lists when full page zoom is turned on.  Because the control is buggy
2441         when scaling and because it's impossible to paint into an offscreen bitmap without completely rewriting
2442         how we draw the control on Mac, our only real option for now is to just switch to our styled look when zoomed.
2443
2444         Reviewed by Adam Roben
2445
2446         * rendering/RenderThemeMac.mm:
2447         (WebCore::RenderThemeMac::isControlStyled):
2448
2449 2008-11-11  Darin Adler  <darin@apple.com>
2450
2451         Reviewed by Dan Bernstein.
2452
2453         - https://bugs.webkit.org/show_bug.cgi?id=22160
2454         speculative fix for <rdar://problem/5995450> Nil deref because nextLinePosition
2455         (previousLinePosition, too) uses a nil node
2456
2457         * editing/visible_units.cpp:
2458         (WebCore::nextLinePosition): Use RenderObject::node instead of RenderObject::element
2459         to check editingIgnoresContent. It makes sense to use the associated DOM node for
2460         this, even in cases of anonymous content, and it avoids the case where element() can
2461         be 0.
2462         (WebCore::previousLinePosition): Ditto.
2463
2464 2008-11-11  Dirk Schulze  <vbs85@gmx.de>
2465
2466         Reviewed by Darin Adler.
2467
2468         Removed default: in applySpreadMethod. This causes the problems
2469         in radial gradients. We don't need CAIRO_EXTEND_NONE in SVG, Canvas
2470         or CSS.
2471
2472         * platform/graphics/cairo/GraphicsContextCairo.cpp:
2473         (WebCore::applySpreadMethod):
2474
2475 2008-11-11  Ariya Hidayat  <ariya.hidayat@trolltech.com>
2476
2477         Reviewed by Tor Arne Vestbø.
2478
2479         Fix crash when rendering the file chooser.
2480         Also proper implementation for multi-selected files.
2481
2482         * platform/qt/FileChooserQt.cpp:
2483         (WebCore::FileChooser::basenameForWidth):
2484
2485 2008-11-11  Dirk Schulze  <vbs85@gmx.de>
2486
2487         Reviewed by Oliver Hunt.
2488
2489         PatternCairo needs to invert the pattern matrix because
2490         of transformation from user space to pattern space.
2491         Give a identity matrix to pattern for Qt and Cairo. Because the 
2492         context is transformed already.
2493
2494         [CAIRO][QT] Canvas transformations applied twice to Patterns
2495         https://bugs.webkit.org/show_bug.cgi?id=21555
2496
2497         * platform/graphics/cairo/GraphicsContextCairo.cpp:
2498         (WebCore::GraphicsContext::fillPath):
2499         (WebCore::GraphicsContext::strokePath):
2500         * platform/graphics/cairo/PatternCairo.cpp:
2501         (WebCore::Pattern::createPlatformPattern):
2502         * platform/graphics/qt/GraphicsContextQt.cpp:
2503         (WebCore::GraphicsContext::strokePath):
2504         (WebCore::GraphicsContext::fillRect):
2505
2506 2008-11-10  Stephanie Lewis  <slewis@apple.com>
2507
2508         Reviewed by Dan Bernstein.
2509
2510         Clear the image source cache even if we haven't decoded any of the image data.
2511         We use the image source cache when calculating layout.
2512
2513         * loader/Cache.cpp:
2514         (WebCore::Cache::pruneDeadResources):
2515         * platform/graphics/BitmapImage.cpp:
2516         (WebCore::BitmapImage::destroyDecodedData):
2517
2518 2008-11-10  Adam Roben  <aroben@apple.com>
2519
2520         Fix Bug 22161: Assertion failure in RenderThemeWin::systemColor when
2521         loading microsoftpdc.com
2522
2523         <https://bugs.webkit.org/show_bug.cgi?id=22161>
2524
2525         Reviewed by Dan Bernstein.
2526
2527         Test: fast/css/outline-invert-assertion.html
2528
2529         * rendering/RenderThemeWin.cpp:
2530         (WebCore::RenderThemeWin::systemColor): If we can't determine a good
2531         Win32 system color to use, defer to RenderTheme instead of asserting.
2532         This matches what RenderThemeMac does.
2533
2534 2008-11-10  Justin Garcia  <justin.garcia@apple.com>
2535
2536         Reviewed by Beth Dakin.
2537
2538         <rdar://problem/4037481> REGRESSION (Mail): pasting quoted text 
2539         into quoted text yields double-quoting
2540         
2541         Don't nest inserted content in Mail blockquotes.  Perform a 
2542         BreakBlockquoteCommand if we're in
2543         one and insert the incoming fragment between the split blockquotes.
2544
2545         * editing/ReplaceSelectionCommand.cpp:
2546         (WebCore::ReplaceSelectionCommand::shouldMerge): Renamed from -> 
2547         source and to -> destination.
2548         (WebCore::ReplaceSelectionCommand::doApply):
2549
2550 2008-11-10  Adam Roben  <aroben@apple.com>
2551
2552         Fix Bug 22158: Would like to turn on WebCore logging channels via an
2553         environment variable
2554
2555         <https://bugs.webkit.org/show_bug.cgi?id=22158>
2556
2557         Logging channels can now be enabled by setting the WebCoreLogLevel
2558         environment variable to a hexadecimal number.
2559
2560         Reviewed by Anders Carlsson.
2561
2562         * WebCore.vcproj/WebCore.vcproj: Added LoggingWin.cpp.
2563         * platform/win/LoggingWin.cpp: Copied from WebCore/platform/mac/LoggingMac.mm.
2564         (WebCore::initializeWithUserDefault): Read in the WebCoreLogLevel
2565         environment variable, parse its value as a hexadecimal number, and
2566         turn the channel on/off based on whether the mask bit is set.
2567         (WebCore::InitializeLoggingChannelsIfNecessary): Initialize each
2568         logging channel in turn.
2569
2570 2008-11-10  Darin Adler  <darin@apple.com>
2571
2572         Reviewed by Adam Roben.
2573
2574         - fix https://bugs.webkit.org/show_bug.cgi?id=22103
2575           Changing fonts in preferences does not immediately update WebViews
2576
2577         This broke when the meaning of FrameView::invalidate changed.
2578         I changed setNeedsReapplyStyles to no longer depend on invalidate.
2579
2580         * dom/Document.cpp: (WebCore::Document::shouldScheduleLayout):
2581         Removed the part of this function that duplicated what's already in
2582         FrameView::needsLayout, since the copy here left out a few key things.
2583         For example, it didn't handle the fact that "needs reapply styles"
2584         counts as needing layout.
2585
2586         * page/Frame.cpp: (WebCore::Frame::setNeedsReapplyStyles): This called
2587         FrameView::invalidate before. There were two things wrong with that.
2588         1) It requested that the entire view repaint even if the style change
2589         didn't necessitate that. 2) FrameView::invalidate no longer causes any
2590         repainting at all in certain cases, because of Hyatt's changes to how
2591         widgets and the host window are involved in the repainting process.
2592         So call FrameView::scheduleRelayout instead, which is more precisely
2593         what we want and need here.
2594
2595         * page/FrameView.cpp:
2596         (WebCore::FrameView::scheduleRelayout): Add a call to needsLayout here
2597         so that Document::shouldScheduleLayout doesn't have to replicate the
2598         logic that's in needsLayout and can instead rely on the fact that it
2599         was already called.
2600         (WebCore::FrameView::needsLayout): Tweaked the comments and formatting
2601         in this function.
2602
2603 2008-11-10  Darin Adler  <darin@apple.com>
2604
2605         Reviewed by Adam Roben.
2606
2607         - speculative fix for <rdar://problem/5557243> crashes in Safari at
2608           WebCore::HTMLSelectElement::updateListBoxSelection + 280
2609
2610         * html/HTMLSelectElement.cpp:
2611         (WebCore::HTMLSelectElement::updateListBoxSelection):
2612         Check index against size of vector before indexing into the vector.
2613
2614 2008-11-10  Tom Cooksey  <thomas.cooksey@trolltech.com>
2615
2616         Reviewed by Tor Arne Vestbø.
2617
2618         Fix QtWebkit build failure on arm.
2619
2620         pen.widthF() is a qreal, which means it's a float on arm.
2621
2622         * platform/graphics/qt/GraphicsContextQt.cpp:
2623         (WebCore::GraphicsContext::setLineDash):
2624
2625 2008-11-10  Morten Sørvig  <msorvig@trolltech.com>
2626
2627         Reviewed by Simon Hausmann.
2628
2629         Improve mouse wheel scolling on Qt/Cocoa.
2630         Cocoa differs from Carbon (and other platforms I think) in that the
2631         mouse wheel events we get have a much higher acceleration factor.
2632
2633         This submit switches over to scroll-per-pixel from scroll-per-line
2634         for most of our scrolling views. This matches the native views
2635         and works well with the increased acceleration.
2636
2637         * platform/qt/WheelEventQt.cpp:
2638
2639 2008-11-09  Cameron Zwarich  <zwarich@apple.com>
2640
2641         Reviewed by Darin Adler.
2642
2643         Bug 19541: Null pointer in showModalDialog()
2644         <https://bugs.webkit.org/show_bug.cgi?id=19541>
2645
2646         Add null frame->page() checks to JSDOMWindowBase::canShowModalDialog()
2647         and JSDOMWindowBase::canShowModalDialogNow()C
2648
2649         * bindings/js/JSDOMWindowBase.cpp:
2650         (WebCore::canShowModalDialog):
2651         (WebCore::canShowModalDialogNow):
2652
2653 2008-11-09  Darin Adler  <darin@apple.com>
2654
2655         - try to fix Windows build
2656
2657         * platform/graphics/Color.cpp: For some reason MSVC doesn't follow the rules
2658         about needed a separate definition for static const integer data members.
2659         Until I get to the bottom of this, put the definitions inside an ifdef.
2660
2661 2008-11-09  David Kilzer  <ddkilzer@apple.com>
2662
2663         BUILD FIX: Qt build broke after r38235.
2664
2665         Added HAVE(ACCESSIBILITY) header guards to platform implementation
2666         source files.
2667
2668         * page/gtk/AccessibilityObjectAtk.cpp: Added HAVE(ACCESSIBILITY)
2669         guards.
2670         * page/gtk/AccessibilityObjectWrapperAtk.cpp: Ditto.
2671         * page/qt/AccessibilityObjectQt.cpp: Ditto.
2672         * page/win/AccessibilityObjectWin.cpp: Ditto.
2673         * page/wx/AccessibilityObjectWx.cpp: Ditto.
2674
2675 2008-11-09  Alexey Proskuryakov  <ap@webkit.org>
2676
2677         Reviewed by Darin Adler.
2678
2679         https://bugs.webkit.org/show_bug.cgi?id=22104
2680         Javascript URL percent encoding/decoding broken by some characters
2681
2682         Test: fast/loader/javascript-url-encoding-2.html
2683
2684         * platform/KURL.cpp: (WebCore::encodeRelativeString): Don't try to break down javascript URLs.
2685
2686 2008-11-09  Holger Hans Peter Freyther  <zecke@selfish.org>
2687
2688         Reviewed and tweaked by Darin Adler.
2689
2690         * platform/graphics/Color.cpp: Added definitions for the static data members
2691         in this class. Static data members need a definition, even when they are the
2692         simple integer constant kind that can be initialized in the header.
2693
2694 2008-11-08  Antti Koivisto  <antti@apple.com>
2695
2696         Reviewed by Sam Weinig.
2697         
2698         Fix https://bugs.webkit.org/show_bug.cgi?id=22141
2699         REGRESSION: Safari error page is not fully styled when loaded from cache
2700         
2701         Reset text decoder on flush so it does not pass through the BOM when it is reused.
2702
2703         Test: fast/encoding/css-cached-bom.html
2704
2705         * loader/TextResourceDecoder.cpp:
2706         (WebCore::TextResourceDecoder::flush):
2707
2708 2008-11-08  Kevin Ollivier  <kevino@theolliviers.com>
2709  
2710         Reviewed by Mark Rowe.
2711
2712         Send URL errors to stderr rather than stdout. While debugging wx DumpRenderTree,
2713         it was causing these errors to end up in the page's text representation.
2714
2715         * platform/network/curl/ResourceHandleManager.cpp:
2716         (WebCore::ResourceHandleManager::downloadTimerCallback):
2717
2718 2008-11-08  Kevin Ollivier  <kevino@theolliviers.com>
2719
2720         wx build fixes after addition of JSCore parser and bycompiler dirs. 
2721
2722         * webcore-base.bkl:
2723         * webcore-wx.bkl:
2724
2725 2008-11-08  Simon Fraser  <simon.fraser@apple.com>
2726
2727         Reviewed by Dan Bernstein
2728
2729         https://bugs.webkit.org/show_bug.cgi?id=21906
2730         
2731         Override addFocusRingRects() in RenderTextControl to avoid
2732         the RenderFlow behavior of recursing on descendent renderers.
2733         RenderTextControl should only ever need a simple focus rect.
2734         
2735         This fixes focus ring issues with transforms on text controls.
2736         
2737         Test: fast/transforms/transformed-focused-text-input.html
2738
2739         * rendering/RenderTextControl.cpp:
2740         (WebCore::RenderTextControl::addFocusRingRects):
2741         * rendering/RenderTextControl.h:
2742
2743 2008-11-08  Dimitri Dupuis-Latour  <dupuislatour@apple.com>
2744
2745         Make sure the icon thumbnail width/height is at least 1px in
2746         the Web Inspector's resource panel.
2747
2748         <rdar://problem/5988888>
2749
2750         Reviewed by Tim Hatcher.
2751
2752         * inspector/front-end/inspector.css:
2753
2754 2008-11-08  David Kilzer  <ddkilzer@apple.com>
2755
2756         Bug 22137: PLATFORM(MAC) build broken with HAVE(ACCESSIBILITY) disabled
2757
2758         <https://bugs.webkit.org/show_bug.cgi?id=22137>
2759
2760         Reviewed by Darin Adler.
2761
2762         * page/AccessibilityObject.h:
2763         (WebCore::AccessibilityObject::accessibilityIgnoreAttachment):
2764         Provide a default implementation when HAVE(ACCESSIBILITY) is false.
2765         * page/mac/AXObjectCacheMac.mm: Added HAVE(ACCESSIBILITY) guard.
2766         * page/mac/AccessibilityObjectMac.mm: Ditto.
2767         * page/mac/AccessibilityObjectWrapper.mm: Ditto.
2768
2769 2008-11-08  Dan Bernstein  <mitz@apple.com>
2770
2771         Reviewed by Darin Adler.
2772
2773         - WebCore part of adding WebPreferences for controlling databases and local storage
2774
2775         * WebCore.base.exp: Exported Settings::setDatabasesEnabled() and
2776         Settings::setLocalStorageEnabled().
2777         * page/DOMWindow.cpp:
2778         (WebCore::DOMWindow::localStorage): Changed to return 0 if local storage
2779         is disabled in settings.
2780         (WebCore::DOMWindow::openDatabase): Changed to return 0 if databases
2781         are disabled in settings.
2782         * page/Settings.cpp:
2783         (WebCore::Settings::Settings): Initialize m_databasesEnabled and
2784         m_localStorageEnabled.
2785         (WebCore::Settings::setDatabasesEnabled): Added.
2786         (WebCore::Settings::setLocalStorageEnabled): Added.
2787         * page/Settings.h:
2788         (WebCore::Settings::databasesEnabled): Added.
2789         (WebCore::Settings::localStorageEnabled): Added.
2790
2791 2008-11-07  Alp Toker  <alp@nuanti.com>
2792
2793         Fix build with bleeding edge GTK+ versions. GTK+ and other libraries
2794         now require that only their top-level header file is included.
2795
2796         Patch tested and still builds fine with older GTK+ versions (back to
2797         2.8).
2798
2799         Future WebKit GTK+ contributions are required to adhere to this
2800         policy.
2801
2802         * platform/gtk/FileSystemGtk.cpp:
2803         * platform/gtk/KeyEventGtk.cpp:
2804         * platform/gtk/MouseEventGtk.cpp:
2805         * platform/gtk/WheelEventGtk.cpp:
2806         * platform/gtk/gtkdrawing.h:
2807         * plugins/gtk/gtk2xtbin.c:
2808         * plugins/gtk/gtk2xtbin.h:
2809
2810 2008-11-07  Anders Carlsson  <andersca@apple.com>
2811
2812         Reviewed by Kevin Decker
2813
2814         Explicitly initialize the NPDrawingModelCoreAnimation.
2815
2816         * bridge/npapi.h:
2817
2818 2008-11-07  Alp Toker  <alp@nuanti.com>
2819
2820         autotools fix. Always use the configured perl binary (which may be
2821         different to the one in $PATH) when generating sources.
2822
2823         * GNUmakefile.am:
2824
2825 2008-11-07  Simon Fraser  <simon.fraser@apple.com>
2826
2827         Reviewed by Dan Bernstein
2828
2829         https://bugs.webkit.org/show_bug.cgi?id=22122
2830         
2831         Use a stack-based object to simplify the pushLayoutState/popLayoutState
2832         code. LayoutStateMaintainer either pushes in the constructor, or allows
2833         an explicit push() later. Both cases require an explicit pop().
2834
2835         * rendering/RenderBlock.cpp:
2836         (WebCore::RenderBlock::layoutBlock):
2837         (WebCore::RenderBlock::layoutOnlyPositionedObjects):
2838         * rendering/RenderContainer.cpp:
2839         (WebCore::RenderContainer::layout):
2840         * rendering/RenderFlexibleBox.cpp:
2841         (WebCore::RenderFlexibleBox::layoutBlock):
2842         * rendering/RenderTable.cpp:
2843         (WebCore::RenderTable::layout):
2844         * rendering/RenderTableRow.cpp:
2845         (WebCore::RenderTableRow::layout):
2846         * rendering/RenderTableSection.cpp:
2847         (WebCore::RenderTableSection::setCellWidths):
2848         (WebCore::RenderTableSection::calcRowHeight):
2849         (WebCore::RenderTableSection::layoutRows):
2850         * rendering/RenderView.h:
2851         (WebCore::LayoutStateMaintainer::LayoutStateMaintainer):
2852         (WebCore::LayoutStateMaintainer::~LayoutStateMaintainer):
2853         (WebCore::LayoutStateMaintainer::pop):
2854         (WebCore::LayoutStateMaintainer::push):
2855         (WebCore::LayoutStateMaintainer::didPush):
2856
2857 2008-11-07  Tor Arne Vestbø  <tavestbo@trolltech.com>
2858
2859         Fix the QtWebKit build on Mac
2860
2861         * platform/qt/TemporaryLinkStubs.cpp:
2862         (PluginView::invalidateRect):
2863
2864 2008-11-07  Tor Arne Vestbø  <tavestbo@trolltech.com>
2865
2866         Rubber-stamped by Simon Hausmann.
2867
2868         Don't allow Phonon's invisible video widget to keep the app running
2869
2870         * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
2871         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
2872
2873 2008-11-07  Henrik Hartz  <henrik.hartz@nokia.com>
2874
2875         Reviewed by Simon Hausmann.
2876
2877         Fix valgrind warning about uninitialized lastStop variable.
2878
2879         * platform/graphics/qt/GradientQt.cpp:
2880         (WebCore::Gradient::platformGradient):
2881
2882 2008-11-07  Alexey Proskuryakov  <ap@webkit.org>
2883
2884         Reviewed by Maciej Stachowiak.
2885
2886         Fix layout test brokenness following r38211.
2887
2888         * page/EventHandler.cpp: (WebCore::EventHandler::handleAccessKey):
2889         Restore old Shift key behavior. We ignore Shift key state when matching access keys (which
2890         matches neither IE nor Firefox), and this patch made WebKit behave like Firefox
2891         inadvertently. This may or may not be a good thing, but it's certainly not something that
2892         should change by accident.
2893
2894 2008-11-06  Antti Koivisto  <antti@apple.com>
2895
2896         Eh, this trivial last minute change was wrong.
2897
2898         * loader/CachedCSSStyleSheet.cpp:
2899         (WebCore::CachedCSSStyleSheet::sheetText):
2900
2901 2008-11-06  Antti Koivisto  <antti@apple.com>
2902
2903         Reviewed by Dan Bernstein.
2904
2905         https://bugs.webkit.org/show_bug.cgi?id=22093
2906         
2907         Delaying the text decoding caused regression since the decoding
2908         also determines the encoding in case of @charset rule. 
2909         
2910         Decode immediately in data() and keep the decoded string around
2911         during the checkNotify().
2912
2913         * loader/CachedCSSStyleSheet.cpp:
2914         (WebCore::CachedCSSStyleSheet::sheetText):
2915         (WebCore::CachedCSSStyleSheet::data):
2916         * loader/CachedCSSStyleSheet.h:
2917
2918 2008-11-06  Alexey Proskuryakov  <ap@webkit.org>
2919
2920         Reviewed by Darin Adler.
2921
2922         https://bugs.webkit.org/show_bug.cgi?id=22097
2923         Expose MessageEvent constructor on WorkerContext
2924
2925         * bindings/js/JSWorkerContext.cpp:
2926         (WebCore::jsWorkerContextMessageEvent):
2927         (WebCore::setJSWorkerContextMessageEvent):
2928
2929 2008-11-06  Alexey Proskuryakov  <ap@webkit.org>
2930
2931         Reviewed by Darin Adler.
2932
2933         https://bugs.webkit.org/show_bug.cgi?id=21107
2934         <rdar://problem/6264219> New access key combination conflicts with VoiceOver
2935
2936         * page/EventHandler.h:
2937         * page/gtk/EventHandlerGtk.cpp:
2938         (WebCore::EventHandler::accessKeyModifiers):
2939         * page/qt/EventHandlerQt.cpp:
2940         (WebCore::EventHandler::accessKeyModifiers):
2941         * page/win/EventHandlerWin.cpp:
2942         (WebCore::EventHandler::accessKeyModifiers):
2943         * page/wx/EventHandlerWx.cpp:
2944         (WebCore::EventHandler::accessKeyModifiers):
2945         Access access key modifiers via a function, not a static variable.
2946
2947         * page/mac/EventHandlerMac.mm: (WebCore::EventHandler::accessKeyModifiers):
2948         Use Ctrl when VoiceOver is enabled, because a conflict with Emacs-style key bindings is
2949         less troublesome than one with VO keys.
2950
2951         * page/EventHandler.cpp: (WebCore::EventHandler::handleAccessKey):
2952         Also fix an access key matching bug introduced in r32424 - Any superset of specified
2953         modifier set invoked access keys. We can use simple equality comparison instead because
2954         CapsLock is not part of modifiers(), so it doesn't need to be ignored explicitly.
2955
2956 2008-11-06  Anders Carlsson  <andersca@apple.com>
2957
2958         Reviewed by Kevin Decker.
2959
2960         https://bugs.webkit.org/show_bug.cgi?id=22115
2961         NPN_HasPropertyUPP and NPN_HasMethodUPP entries in NPNetscapeFuncs are NULL
2962
2963         Export _NPN_HasMethod and _NPN_HasProperty.
2964         
2965         * WebCore.NPAPI.exp:
2966
2967 2008-11-06  Simon Fraser  <simon.fraser@apple.com>
2968
2969         Reviewed by Antti Koivisto
2970
2971         https://bugs.webkit.org/show_bug.cgi?id=15678
2972         
2973         Fix transformed menu selects to show the popup in the correct
2974         location.
2975
2976         * rendering/RenderMenuList.cpp:
2977         (WebCore::RenderMenuList::showPopup):
2978
2979 2008-11-06  David Kilzer  <ddkilzer@apple.com>
2980
2981         BUILD FIX: Backed out r38189 (and r38203) for Xcode 3.0.
2982
2983         Apparently older versions of gcc have issues with this patch.
2984         Backing out a second time until the issues are resolved.
2985
2986 2008-11-06  Julien Chaffraix  <jchaffraix@pleyo.com>
2987
2988         Reviewed by Maciej Stachowiak.
2989
2990         Bug 21106: .in format discussed changes
2991         https://bugs.webkit.org/show_bug.cgi?id=21106
2992
2993         Include the namespace into the interfaceName.
2994
2995         * dom/make_names.pl: Do not append the namespace when
2996         using the interfaceName.
2997         * html/HTMLTagNames.in: Added namespace prefix for custom
2998         interfaceName.
2999         * svg/svgtags.in: Ditto.
3000
3001 2008-11-06  Cameron Zwarich  <zwarich@apple.com>
3002
3003         Reviewed by Geoff Garen.
3004
3005         Move the remaining files in the kjs subdirectory of JavaScriptCore to
3006         a new parser subdirectory, and remove the kjs subdirectory entirely.
3007
3008         * ForwardingHeaders/kjs: Removed.
3009         * ForwardingHeaders/kjs/Parser.h: Removed.
3010         * ForwardingHeaders/kjs/SavedBuiltins.h: Removed.
3011         * ForwardingHeaders/kjs/SourceCode.h: Removed.
3012         * ForwardingHeaders/kjs/SourceProvider.h: Removed.
3013         * ForwardingHeaders/parser: Added.
3014         * ForwardingHeaders/parser/Parser.h: Copied from ForwardingHeaders/kjs/Parser.h.
3015         * ForwardingHeaders/parser/SourceCode.h: Copied from ForwardingHeaders/kjs/SourceCode.h.
3016         * ForwardingHeaders/parser/SourceProvider.h: Copied from ForwardingHeaders/kjs/SourceProvider.h.
3017         * WebCore.pro:
3018         * WebCore.vcproj/WebCore.vcproj:
3019         * bindings/js/StringSourceProvider.h:
3020         * bindings/js/WorkerScriptController.cpp:
3021         * bridge/NP_jsobject.cpp:
3022         * bridge/jni/jni_jsobject.mm:
3023         * bridge/testbindings.pro:
3024         * inspector/JavaScriptDebugServer.cpp:
3025
3026 2008-11-06  David Kilzer  <ddkilzer@apple.com>
3027
3028         BUILD WAS NOT BROKEN: Rolling r38189 back in.
3029
3030         Please perform a clean build if you see crashes.
3031
3032 2008-11-06  David Kilzer  <ddkilzer@apple.com>
3033
3034         BUILD FIX: Backed out r38189 since it apparently broke the world.
3035
3036 2008-11-06  Chris Fleizach  <cfleizach@apple.com>
3037
3038         Reviewed by Beth Dakin.
3039
3040         Bug 22112: if a <body> has contenteditable=true, it should report a writable AXValue
3041         https://bugs.webkit.org/show_bug.cgi?id=22112
3042
3043         Test: accessibility/content-editable.html
3044
3045         * page/AccessibilityRenderObject.cpp:
3046         (WebCore::AccessibilityRenderObject::isReadOnly):
3047
3048 2008-11-06  Sam Weinig  <sam@webkit.org>
3049
3050         Reviewed by Alice Liu.
3051
3052         Fix failed assert at launch caused by unintialized data member on the mac.
3053
3054         * platform/network/mac/NetworkStateNotifierMac.cpp:
3055         (WebCore::NetworkStateNotifier::NetworkStateNotifier):
3056
3057 2008-11-06  Steve Falkenburg  <sfalken@apple.com>
3058
3059         Fix failed assert at launch caused by unintialized data member.
3060         
3061         Reviewed by Maciej Stachowiak.
3062
3063         * platform/network/win/NetworkStateNotifierWin.cpp:
3064         (WebCore::NetworkStateNotifier::NetworkStateNotifier):
3065
3066 2008-11-06  Simon Fraser  <simon.fraser@apple.com>
3067
3068         Reviewed by Antti Koivisto
3069
3070         https://bugs.webkit.org/show_bug.cgi?id=22109
3071         Make <input type="range"> work correctly with transforms
3072
3073         Test: fast/forms/slider-transformed.html
3074
3075         * html/HTMLInputElement.cpp:
3076         (WebCore::HTMLInputElement::defaultEventHandler):
3077             Compute a correct local point when the event is retargeted
3078         * rendering/RenderSlider.cpp:
3079         (WebCore::HTMLSliderThumbElement::defaultEventHandler):
3080             Compute m_initialClickPoint in slider-local coords, so that
3081             deltas are computed correctly with transforms
3082         (WebCore::RenderSlider::mouseEventIsInThumb):
3083             Rather than computing an absolute bounds for the thumb,
3084             convert the point to local coords and compare it with the border box.
3085
3086 2008-11-06  Greg Bolsinga  <bolsinga@apple.com>
3087
3088         Reviewed by Darin Adler.
3089
3090         Bug 21810: Remove use of static C++ objects that are destroyed at exit time (destructors)
3091         https://bugs.webkit.org/show_bug.cgi?id=21810
3092
3093         * bindings/js/GCController.cpp:
3094         (WebCore::gcController): Changed to leak an object to avoid an exit-time destructor.
3095         * bindings/js/JSDOMBinding.cpp:
3096         (WebCore::wrapperSet): Ditto
3097         * bindings/js/JSInspectedObjectWrapper.cpp:
3098         (WebCore::wrappers): Ditto
3099         * bindings/js/JSInspectorCallbackWrapper.cpp:
3100         (WebCore::wrappers): Ditto
3101         * bridge/runtime_root.cpp:
3102         (JSC::Bindings::rootObjectSet): Ditto
3103         * css/CSSMutableStyleDeclaration.cpp:
3104         (WebCore::CSSMutableStyleDeclaration::removeProperty): Ditto
3105         * css/CSSPrimitiveValue.cpp:
3106         (WebCore::CSSPrimitiveValue::cssText): Ditto
3107         * css/CSSSelector.cpp:
3108         (WebCore::CSSSelector::extractPseudoType): Ditto
3109         * css/CSSStyleSelector.cpp:
3110         (WebCore::screenEval): Ditto
3111         (WebCore::printEval): Ditto
3112         * dom/DOMImplementation.cpp:
3113         (WebCore::isSVG10Feature): Ditto
3114         (WebCore::isSVG11Feature): Ditto
3115         (WebCore::DOMImplementation::isXMLMIMEType): Ditto
3116         * dom/Document.cpp:
3117         (WebCore::Document::hasPrefixNamespaceMismatch): Ditto
3118         * dom/ScriptElement.cpp:
3119         (WebCore::isSupportedJavaScriptLanguage): Ditto
3120         * editing/ApplyStyleCommand.cpp:
3121         (WebCore::styleSpanClassString): Ditto
3122         * editing/HTMLInterchange.cpp:
3123         (WebCore::): Ditto
3124         * editing/IndentOutdentCommand.cpp:
3125         (WebCore::indentBlockquoteString): Ditto
3126         * editing/ReplaceSelectionCommand.cpp:
3127         (WebCore::isInterchangeNewlineNode): Ditto
3128         (WebCore::isInterchangeConvertedSpaceSpan): Ditto
3129         * editing/htmlediting.cpp:
3130         (WebCore::stringWithRebalancedWhitespace): Ditto
3131         (WebCore::nonBreakingSpaceString): Ditto
3132         * editing/markup.cpp:
3133         (WebCore::appendAttributeValue): Ditto
3134         (WebCore::appendEscapedContent): Ditto
3135         (WebCore::shouldAddNamespaceAttr): Ditto
3136         (WebCore::appendNamespace): Ditto
3137         (WebCore::appendStartMarkup): Ditto
3138         (WebCore::createMarkup): Ditto
3139         * html/HTMLButtonElement.cpp:
3140         (WebCore::HTMLButtonElement::type): Ditto
3141         * html/HTMLElement.cpp:
3142         (WebCore::HTMLElement::isRecognizedTagName): Ditto
3143         (WebCore::inlineTagList): Ditto
3144         (WebCore::blockTagList): Ditto
3145         * html/HTMLFieldSetElement.cpp:
3146         (WebCore::HTMLFieldSetElement::type): Ditto
3147         * html/HTMLInputElement.cpp:
3148         (WebCore::HTMLInputElement::type): Ditto
3149         * html/HTMLKeygenElement.cpp:
3150         (WebCore::HTMLKeygenElement::type): Ditto
3151         * html/HTMLLegendElement.cpp:
3152         (WebCore::HTMLLegendElement::type): Ditto
3153         * html/HTMLOptGroupElement.cpp:
3154         (WebCore::HTMLOptGroupElement::type): Ditto
3155         * html/HTMLOptionElement.cpp:
3156         (WebCore::HTMLOptionElement::type): Ditto
3157         * html/HTMLParser.cpp:
3158         (WebCore::HTMLParser::getNode): Ditto
3159         (WebCore::HTMLParser::isHeaderTag): Ditto
3160         (WebCore::HTMLParser::isResidualStyleTag): Ditto
3161         (WebCore::HTMLParser::isAffectedByResidualStyle): Ditto
3162         * html/HTMLSelectElement.cpp:
3163         (WebCore::HTMLSelectElement::type): Ditto
3164         * html/HTMLTextAreaElement.cpp:
3165         (WebCore::HTMLTextAreaElement::type): Ditto
3166         * inspector/InspectorController.cpp:
3167         (WebCore::platform): Ditto
3168         * inspector/JavaScriptDebugServer.cpp:
3169         (WebCore::JavaScriptDebugServer::shared): Ditto
3170         * inspector/JavaScriptProfile.cpp:
3171         (WebCore::profileCache): Ditto
3172         * inspector/JavaScriptProfileNode.cpp:
3173         (WebCore::profileNodeCache): Ditto
3174         * loader/FrameLoader.cpp:
3175         (WebCore::localSchemes): Ditto
3176         * loader/appcache/ApplicationCacheStorage.cpp:
3177         (WebCore::cacheStorage): Ditto
3178         * loader/archive/ArchiveFactory.cpp:
3179         (WebCore::archiveMIMETypes): Ditto
3180         * loader/icon/IconDatabase.cpp:
3181         (WebCore::IconDatabase::defaultDatabaseFilename): Ditto
3182         * page/EventHandler.cpp:
3183         (WebCore::EventHandler::dragState): Ditto
3184         * page/Frame.cpp:
3185         (WebCore::createRegExpForLabels): Ditto
3186         (WebCore::keepAliveSet): Ditto
3187         * page/Page.cpp:
3188         (WebCore::Page::groupName): Ditto
3189         * page/SecurityOrigin.cpp:
3190         (WebCore::isDefaultPortForProtocol): Ditto
3191         (WebCore::SecurityOrigin::databaseIdentifier): Ditto
3192         * page/mac/FrameMac.mm:
3193         (WebCore::regExpForLabels): Ditto
3194         * platform/KURL.cpp:
3195         (WebCore::blankURL): Ditto
3196         * platform/graphics/FontCache.cpp:
3197         (WebCore::alternateFamilyName): Ditto
3198         * platform/graphics/mac/FontCacheMac.mm:
3199         (WebCore::FontCache::getSimilarFontPlatformData): Ditto
3200         (WebCore::FontCache::getLastResortFallbackFont): Ditto
3201         * platform/mac/ScrollbarThemeMac.mm:
3202         (WebCore::ScrollbarTheme::nativeTheme): Ditto
3203         * platform/mac/ThemeMac.mm:
3204         (WebCore::platformTheme): Ditto
3205         * platform/mac/ThreadCheck.mm:
3206         (WebCoreReportThreadViolation): Ditto
3207         * platform/network/NetworkStateNotifier.cpp:
3208         (WebCore::networkStateNotifier): Ditto
3209         * platform/network/mac/FormDataStreamMac.mm:
3210         (WebCore::getStreamFormDataMap): Ditto
3211         (WebCore::getStreamResourceHandleMap): Ditto
3212         * platform/network/mac/ResourceResponseMac.mm:
3213         (WebCore::ResourceResponse::platformLazyInit): Ditto
3214         * platform/text/TextEncoding.cpp:
3215         (WebCore::TextEncoding::isJapanese): Ditto
3216         * rendering/RenderBlock.cpp:
3217         (WebCore::continuationOutlineTable): Ditto
3218         * rendering/RenderCounter.cpp:
3219         (WebCore::counterMaps): Ditto
3220         * rendering/RenderFlexibleBox.cpp:
3221         (WebCore::RenderFlexibleBox::layoutVerticalBox): Ditto
3222         * rendering/RenderListItem.cpp:
3223         (WebCore::RenderListItem::markerText): Ditto
3224         * rendering/RenderScrollbarTheme.cpp:
3225         (WebCore::RenderScrollbarTheme::renderScrollbarTheme): Ditto
3226         * rendering/RenderThemeMac.mm:
3227         (WebCore::RenderThemeMac::systemFont): Ditto
3228         * rendering/bidi.cpp:
3229         (WebCore::RenderBlock::checkLinesForTextOverflow): Ditto
3230         * rendering/style/RenderStyle.cpp:
3231         (WebCore::RenderStyle::initialDashboardRegions): Ditto
3232         (WebCore::RenderStyle::noneDashboardRegions): Ditto
3233         * storage/LocalStorage.cpp:
3234         (WebCore::localStorageMap): Ditto
3235         * svg/SVGAnimateMotionElement.cpp:
3236         (WebCore::SVGAnimateMotionElement::rotateMode): Ditto
3237         * svg/SVGAnimationElement.cpp:
3238         (WebCore::SVGAnimationElement::calcMode): Ditto
3239         (WebCore::SVGAnimationElement::attributeType): Ditto
3240         (WebCore::SVGAnimationElement::isAdditive): Ditto
3241         (WebCore::SVGAnimationElement::isAccumulated): Ditto
3242         * svg/SVGLangSpace.cpp:
3243         (WebCore::SVGLangSpace::xmlspace): Ditto
3244         * svg/SVGSVGElement.cpp:
3245         (WebCore::SVGSVGElement::contentScriptType): Ditto
3246         (WebCore::SVGSVGElement::contentStyleType): Ditto
3247         * svg/SVGStyleElement.cpp:
3248         (WebCore::SVGStyleElement::type): Ditto
3249         (WebCore::SVGStyleElement::media): Ditto
3250         * svg/SVGTextContentElement.cpp:
3251         (WebCore::SVGTextContentElement::parseMappedAttribute): Ditto
3252         * svg/animation/SVGSMILElement.cpp:
3253         (WebCore::SVGSMILElement::parseClockValue): Ditto
3254         (WebCore::SVGSMILElement::restart): Ditto
3255         (WebCore::SVGSMILElement::fill): Ditto
3256         (WebCore::SVGSMILElement::repeatCount): Ditto
3257         (WebCore::SVGSMILElement::notifyDependentsIntervalChanged): Ditto
3258         * svg/graphics/SVGResource.cpp:
3259         (WebCore::clientMap): Ditto
3260         * svg/graphics/SVGResourceMarker.cpp:
3261         (WebCore::SVGResourceMarker::draw): Ditto
3262         * xml/XMLHttpRequest.cpp:
3263         (WebCore::preflightResultCache): Ditto
3264         (WebCore::isSafeRequestHeader): Ditto
3265         (WebCore::isOnAccessControlResponseHeaderWhitelist): Ditto
3266         * xml/XPathExpressionNode.cpp:
3267         (WebCore::XPath::Expression::evaluationContext): Ditto
3268         * xml/XPathParser.cpp:
3269         (WebCore::XPath::isAxisName): Ditto
3270         (WebCore::XPath::isNodeTypeName): Ditto
3271         * xml/XPathValue.cpp:
3272         (WebCore::XPath::Value::toNodeSet): Ditto
3273
3274 2008-11-06  Tor Arne Vestbø  <tavestbo@trolltech.com>
3275
3276         Rubber-stamped by Simon Hausmann.
3277
3278         Remove a bunch of unused methods in the Qt media element implementation
3279
3280         * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
3281         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
3282         * platform/graphics/qt/MediaPlayerPrivatePhonon.h:
3283
3284 2008-11-05  Simon Fraser  <simon.fraser@apple.com>
3285
3286         Reviewed by Dave Hyatt
3287
3288         https://bugs.webkit.org/show_bug.cgi?id=21870
3289         
3290         Implement absoluteToLocal() to convert a point from absolute
3291         to local coordinates, optionally taking transforms into account.
3292         
3293         Use this to set offsetX/offsetY in mouse events, thus fixing
3294         offsetX/offsetY in events on elements with transforms.
3295
3296         Test: fast/events/offsetX-offsetY.html
3297
3298         * dom/MouseRelatedEvent.cpp:
3299         (WebCore::MouseRelatedEvent::receivedTarget):
3300         * rendering/RenderBox.cpp:
3301         (WebCore::RenderBox::localToAbsolute):
3302         (WebCore::RenderBox::absoluteToLocal):
3303         (WebCore::RenderBox::offsetFromContainer):
3304         * rendering/RenderBox.h:
3305         * rendering/RenderObject.cpp:
3306         (WebCore::RenderObject::absoluteToLocal):
3307         * rendering/RenderObject.h:
3308         * rendering/RenderTableCell.cpp:
3309         (WebCore::RenderTableCell::localToAbsolute):
3310         (WebCore::RenderTableCell::absoluteToLocal):
3311         * rendering/RenderTableCell.h:
3312         * rendering/RenderView.cpp:
3313         (WebCore::RenderView::absoluteToLocal):
3314         * rendering/RenderView.h:
3315
3316 2008-11-06  Alp Toker  <alp@nuanti.com>
3317
3318         Reviewed by Cameron Zwarich.
3319
3320         https://bugs.webkit.org/show_bug.cgi?id=22067
3321         [GTK] Sun Java plugin segfaults at PluginPackage::createPackage()
3322
3323         null-check symbols loaded from plugin modules, initialize the function
3324         table (like Win already does) and update it with the latest
3325         additions. Adjust whitespace for easy diff'ing with the Win port code
3326         from which it was forked.
3327
3328         This fixes crashes with libnspr4.so and any other plugins that don't
3329         provide the symbols we expect.
3330
3331         * plugins/gtk/PluginPackageGtk.cpp:
3332         (WebCore::PluginPackage::fetchInfo):
3333         (WebCore::PluginPackage::load):
3334
3335 2008-11-06  Kristian Amlie  <kristian.amlie@nokia.com>
3336
3337         Reviewed by Simon Hausmann.
3338
3339         Removed dead (and broken) code from an ancient Symbian port.
3340
3341         * config.h:
3342         * platform/text/AtomicString.h:
3343         * platform/text/PlatformString.h:
3344
3345 2008-11-06  Kristian Amlie  <kristian.amlie@nokia.com>
3346
3347         Reviewed by Simon Hausmann.
3348
3349         Use QLibrary as PlatformModule when compiling with Qt for S60.
3350
3351         * platform/FileSystem.h:
3352
3353 2008-11-06  Kristian Amlie  <kristian.amlie@nokia.com>
3354
3355         Reviewed by Simon Hausmann.
3356
3357         Compile fix for Symbian.
3358         The snprintf function is defined in stdio.h, the inclusion
3359         of snprintf.h inside this PLATFORM(SYMBIAN) block does not
3360         compile.
3361
3362         * config.h:
3363
3364 2008-11-06  Kristian Amlie  <kristian.amlie@nokia.com>
3365
3366         Reviewed by Simon Hausmann.
3367
3368         Disable webkit plugins for Symbian.
3369
3370         * WebCore.pro:
3371
3372 2008-11-06  Tor Arne Vestbø  <tavestbo@trolltech.com>
3373
3374         Fix build break in debug mode when XSLT is not enabled
3375
3376         * loader/Cache.cpp:
3377         (WebCore::Cache::dumpStats):
3378
3379 2008-11-06  Tor Arne Vestbø  <tavestbo@trolltech.com>
3380
3381         Reviewed by Simon Hausmann.
3382
3383         Repaint video on UpdateRequest to prevent recursive painting
3384
3385         Calling QWidget::render() to update the video generates a paint
3386         event that's then picked up by the event filter once more :(
3387
3388         We're really only interested in updates from Phonon, which we
3389         get through the UpdateRequest for each new frame.
3390
3391         * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
3392         (WebCore::MediaPlayerPrivate::eventFilter):
3393
3394 2008-11-06  Cameron Zwarich  <zwarich@apple.com>
3395
3396         Not reviewed.
3397
3398         Fix the WebCore build for some platforms by changing build scripts to
3399         account for the recent move of the create_hash_table script from the kjs
3400         subdirectory of JavaScriptCore to the root directory.
3401
3402         * WebCore.pro:
3403         * make-generated-sources.sh:
3404
3405 2008-11-06  Cameron Zwarich  <zwarich@apple.com>
3406
3407         Not reviewed.
3408
3409         Fix a case-sensitivity issue in Mac forwarding headers. Strangely
3410         enough, this does not always cause the build to break, even with a
3411         case-sensitive filesystem.
3412
3413         * ForwardingHeaders/runtime/Interpreter.h:
3414
3415 2008-11-05  Alexey Proskuryakov  <ap@webkit.org>
3416
3417         Reviewed by Maciej Stachowiak.
3418
3419         https://bugs.webkit.org/show_bug.cgi?id=22083
3420         MessageEvents cannot be used across threads
3421
3422         * dom/Event.idl:
3423         * dom/MessageEvent.idl:
3424         Add a NoStaticTables attribute - MessageEvent is used in worker threads, so static tables
3425         won't work.
3426
3427         * dom/MessagePort.cpp:
3428         (WebCore::MessagePort::EventData::EventData):
3429         (WebCore::MessagePort::EventData::~EventData):
3430         (WebCore::MessagePort::clone):
3431         (WebCore::MessagePort::postMessage):
3432         (WebCore::MessagePort::startConversation):
3433         (WebCore::MessagePort::dispatchMessages):
3434         * dom/MessagePort.h:
3435         Don't create a MessageEvent until dispatch time - messages can be posted across threads,
3436         but MessageEvents are tied to the thread that they were created in.
3437
3438 2008-11-05  Alexey Proskuryakov  <ap@webkit.org>
3439
3440         Reviewed by Darin Adler.
3441
3442         https://bugs.webkit.org/show_bug.cgi?id=22066
3443         Implement Worker global object
3444
3445         * DerivedSources.make: Added WorkerLocation IDL and JSWorkerContext lookup table.
3446
3447         * WebCore.xcodeproj/project.pbxproj: Only adding files to Mac project for now, as Worker
3448         support is still disabled by default.
3449
3450         * bindings/js/JSDOMGlobalObject.cpp: (WebCore::toJSDOMGlobalObject): Implemented Worker case.
3451
3452         * bindings/js/JSMessageChannelConstructor.cpp:
3453         (WebCore::JSMessageChannelConstructor::JSMessageChannelConstructor): Ditto.
3454
3455         * bindings/js/JSWorkerContext.cpp: Added.
3456         * bindings/js/JSWorkerContext.h: Added.
3457         * bindings/js/WorkerScriptController.cpp: Added.
3458         * bindings/js/WorkerScriptController.h: Added.
3459         * dom/WorkerContext.cpp: Added.
3460         * dom/WorkerContext.h: Added.
3461         Added an implementation of worker contexts.
3462
3463         * dom/DedicatedWorker.cpp:
3464         (WebCore::DedicatedWorker::startLoad): Fixed a lifetime bug I saw on my tests.
3465         (WebCore::DedicatedWorker::notifyFinished): Create a thread. Currently, object ownership
3466         and lifetime is not clear at all.
3467
3468         * dom/WorkerLocation.cpp: Added.
3469         * dom/WorkerLocation.h: Added.
3470         * dom/WorkerLocation.idl: Added.
3471         Added WorkerLocation, which is one of the objects available to workers.
3472
3473         * dom/WorkerThread.cpp: Added.
3474         (WebCore::WorkerThread::WorkerThread):
3475         (WebCore::WorkerThread::start):
3476         (WebCore::WorkerThread::workerThreadStart):
3477         (WebCore::WorkerThread::workerThread):
3478         * dom/WorkerThread.h: Added.
3479         (WebCore::WorkerThread::create):
3480         Run some code in a worker thread (no message loop yet).
3481
3482 2008-11-05  Antti Koivisto  <antti@apple.com>
3483
3484         Reviewed by Dan Bernstein.
3485         
3486         https://bugs.webkit.org/show_bug.cgi?id=22093
3487         Don't keep decoded stylesheet data in cache
3488         
3489         <rdar://problem/6343588>
3490
3491         Don't keep decoded stylesheet string around in the cache. There are no sharing benefits and
3492         performance benefits are negligible (no measured PLT impact). Reduces memory consumption of
3493         style sheet data in cache by 2/3 in common case.  
3494
3495         * loader/CachedCSSStyleSheet.cpp:
3496         (WebCore::CachedCSSStyleSheet::sheetText):
3497         (WebCore::CachedCSSStyleSheet::data):
3498         * loader/CachedCSSStyleSheet.h:
3499
3500 2008-11-05  David Kilzer  <ddkilzer@apple.com>
3501
3502         Bug 21596: WebCore::Cache should use parsed Pragma and Cache-Control headers
3503
3504         <https://bugs.webkit.org/show_bug.cgi?id=21596>
3505
3506         Reviewed by Antti.
3507
3508         This patch adds real parsing for Pragma and Cache-Control headers
3509         based on RFC 2616, Sections 2, 14.9 and 14.32.  It also adds some
3510         new String and StringImpl methods to assist with the parsing.
3511
3512         * loader/Cache.cpp:
3513         (WebCore::Cache::dumpStats): Added.  Convenience method for dumping
3514         stats outside of Safari.
3515         * loader/Cache.h: Declared dumpStats().
3516
3517         * loader/CachedResource.cpp:
3518         (WebCore::CachedResource::mustRevalidate): Updated to use
3519         ResourceResponseBase::cacheControlDirectives() instead of substring
3520         matching of the entire Cache-Control header.
3521
3522         * loader/loader.cpp:
3523         (WebCore::Loader::Host::didReceiveResponse): Used the local
3524         'resource' variable instead of 'request->cachedResource()'.
3525
3526         * platform/network/ResourceResponseBase.cpp:
3527         (WebCore::ResourceResponseBase::setHTTPHeaderField): Set
3528         m_haveParsedCacheControlHeader to false when a "Cache-Control"
3529         header is set.  Ditto for m_haveParsedPragmaHeader and "Pragma".
3530         (WebCore::ResourceResponseBase::parsePragmaDirectives): Added.
3531         Provides parsed Pragma header directives.
3532         (WebCore::ResourceResponseBase::parseCacheControlDirectives): Added.
3533         Provides parsed Cache-Control header directives.
3534         (WebCore::isCacheHeaderSeparator): Added.  Returns true if a
3535         character is a separator character per RFC 2616, Section 2.2, else
3536         returns false.
3537         (WebCore::isControlCharacter): Added.  Returns true if a character
3538         is a control character per RFC 2616 Section 2.2, else returns false.
3539         (WebCore::trimToNextSeparator): Added.  Returns a string truncated
3540         at the first separator character per isCacheHeaderSeparator().
3541         (WebCore::parseCacheHeader): Added.  This is the main parsing
3542         routine for both Cache-Control and Pragma headers.
3543         (WebCore::parseCacheControlDirectiveValues): Added.  This splits
3544         certain Cache-Control directive values into a vector of strings.
3545         * platform/network/ResourceResponseBase.h:
3546         (WebCore::CacheControlDirectiveMap): Added.  Typedef for a parsed
3547         Cache-Control header.
3548         (WebCore::PragmaDirectiveMap): Added.  Typedef for a parsed Pragma
3549         header.
3550         (WebCore::ResourceResponseBase::parsePragmaDirectives): Added
3551         declaration.
3552         (WebCore::ResourceResponseBase::parseCacheControlDirectives): Ditto.
3553         (WebCore::ResourceResponseBase::m_haveParsedCacheControlHeader):
3554         Added.  Boolean to describe when the "Cache-Control" header needs to
3555         be reparsed.
3556         (WebCore::ResourceResponseBase::m_haveParsedPragmaHeader):  Added.
3557         Boolean to describe when the "Pragma" header needs to be reparsed.
3558         (WebCore::ResourceResponseBase::m_cacheControlDirectiveMap): Added.
3559         Cached map to hold parsed "Cache-Control" headers.
3560         (WebCore::ResourceResponseBase::m_pragmaDirectiveMap): Added.
3561         Cached map to hold parsed "Pragma" headers.
3562
3563         * platform/text/PlatformString.h:
3564         (WebCore::String::find): Added.  Returns the first match based on
3565         the character-matching function pointer passed in.
3566         (WebCore::String::removeCharacters): Added declaration.
3567         (WebCore::find): Added.  Inline method that takes a character-
3568         matching function pointer.  Called by StringImpl::find().
3569         * platform/text/String.cpp:
3570         (WebCore::String::removeCharacters): Added.  Calls
3571         StringImpl::removeCharacters().
3572         * platform/text/StringImpl.cpp:
3573         (WebCore::StringImpl::removeCharacters): Added.  Returns a string
3574         with all characters removed that match the character-matching
3575         function pointer passed in.  If there is no change to the string, it
3576         returns itself.  Based heavily on StringImpl::simplifyWhitespace().
3577         (WebCore::StringImpl::find): Added.  Calls WebCore::find().
3578         * platform/text/StringImpl.h:
3579         (WebCore::FindMatchFunctionPtr): Added.  Typedef for a character-
3580         matching function pointer.
3581         (WebCore::StringImpl::removeCharacters): Added declaration.
3582         (WebCore::StringImpl::find): Ditto.
3583
3584 2008-11-05  Justin Garcia  <justin.garcia@apple.com>
3585
3586         Reviewed by Beth Dakin.
3587
3588     &